next-helios-fe 1.7.4 → 1.7.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
@@ -107,15 +107,6 @@ export const Autocomplete: React.FC<AutocompleteProps> = ({
|
|
107
107
|
}
|
108
108
|
}, [rest.value, rest.defaultValue]);
|
109
109
|
|
110
|
-
useEffect(() => {
|
111
|
-
if (tempValue) {
|
112
|
-
rest.onChange &&
|
113
|
-
rest.onChange({
|
114
|
-
target: { value: tempValue } as HTMLSelectElement,
|
115
|
-
} as any);
|
116
|
-
}
|
117
|
-
}, [tempValue]);
|
118
|
-
|
119
110
|
return (
|
120
111
|
<label className={`grid gap-2 ${width}`}>
|
121
112
|
{(label || description) && (
|
@@ -196,6 +187,11 @@ export const Autocomplete: React.FC<AutocompleteProps> = ({
|
|
196
187
|
disabled={tempValue === item.value}
|
197
188
|
onMouseDown={() => {
|
198
189
|
setTempValue(item.value);
|
190
|
+
if (rest.onChange) {
|
191
|
+
rest.onChange({
|
192
|
+
target: { value: item.value } as HTMLSelectElement,
|
193
|
+
} as any);
|
194
|
+
}
|
199
195
|
setTempFilter(item.label);
|
200
196
|
setOpenDropdown(false);
|
201
197
|
}}
|