fix(ui): Fix SearchField focus change listener bug.

Signed-off-by: Johan Persson <johanopersson@gmail.com>
This commit is contained in:
Johan Persson
2025-12-17 11:25:02 +01:00
parent 42536b4512
commit 85fec2b6ba
@@ -84,10 +84,6 @@ export const SearchField = forwardRef<HTMLDivElement, SearchFieldProps>(
inputRef.current?.focus();
};
const handleChange = (value: string) => {
props.onChange?.(value);
};
const hasInputRef = !!inputRef.current;
const hasValue = !!inputRef.current?.value;
@@ -102,10 +98,9 @@ export const SearchField = forwardRef<HTMLDivElement, SearchFieldProps>(
aria-label={ariaLabel}
aria-labelledby={ariaLabelledBy}
data-collapsed={isCollapsed}
onFocusChange={handleFocusChange}
onChange={handleChange}
style={style}
{...rest}
onFocusChange={handleFocusChange}
ref={ref}
>
<FieldLabel