diff --git a/web/core/src/jsMain/kotlin/org/jetbrains/compose/web/attributes/Attrs.kt b/web/core/src/jsMain/kotlin/org/jetbrains/compose/web/attributes/Attrs.kt index 8cac1bd7d4a..472b3e13733 100644 --- a/web/core/src/jsMain/kotlin/org/jetbrains/compose/web/attributes/Attrs.kt +++ b/web/core/src/jsMain/kotlin/org/jetbrains/compose/web/attributes/Attrs.kt @@ -194,9 +194,17 @@ fun AttrsScope.placeholder(value: String) = fun AttrsScope.readOnly() = attr("readonly", "") +@Deprecated( + message = "Please use `required()` without parameters. Use if..else.. if conditional behaviour required.", + replaceWith = ReplaceWith("required()", "org.jetbrains.compose.web.attributes.required"), + level = DeprecationLevel.WARNING +) fun AttrsScope.required(value: Boolean = true) = attr("required", value.toString()) +fun AttrsScope.required() = + attr("required", "") + fun AttrsScope.size(value: Int) = attr("size", value.toString())