(
function Input(
{ className, type = 'text', label, hint, error, required, containerClassName, id, ...props },
ref,
) {
const autoId = React.useId()
const inputId = id ?? autoId
const inputEl = (
)
if (!label && !hint && !error) return inputEl
return (
{label && (
)}
{inputEl}
{error ? (
{error}
) : hint ? (
{hint}
) : null}
)
},
)