*/
+ inputWrapperRef?: React.Ref
;
+}
+
+const MAX_INPUT_LENGTH = 500;
+
+function InputFieldInner(
+ {
+ id,
+ icon,
+ hasHint = false,
+ hintType,
+ variant = "dense",
+ slotStart,
+ slotEnd,
+ className,
+ inputWrapperRef,
+ maxLength,
+ "aria-label": ariaLabel,
+ "aria-describedby": ariaDescribedby,
+ ...rest
+ }: InputFieldProps,
+ ref: React.Ref,
+) {
+ const wrapperClass = clsx(
+ styles["input-wrapper"],
+ {
+ [styles["has-hint"]]: hasHint,
+ [styles["hint-type-hint"]]: hintType === "hint",
+ [styles["hint-type-warning"]]: hintType === "warning",
+ [styles["hint-type-error"]]: hintType === "error",
+ [styles["variant-seamless"]]: variant === "seamless",
+ [styles["variant-dense"]]: variant === "dense",
+ [styles["variant-comfortable"]]: variant === "comfortable",
+ },
+ className,
+ );
+
+ const inputClass = clsx(styles.input, {
+ [styles["input-with-icon"]]: icon != null,
+ });
+
+ return (
+
+ {slotStart}
+ {icon != null && }
+
+ {slotEnd}
+
+ );
+}
+
+export const InputField = memo(forwardRef(InputFieldInner));