next-helios-fe 1.7.3 → 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
|
}}
|
@@ -58,15 +58,6 @@ export const Select: React.FC<SelectProps> = ({
|
|
58
58
|
}
|
59
59
|
}, [rest.value, rest.defaultValue]);
|
60
60
|
|
61
|
-
useEffect(() => {
|
62
|
-
if (tempValue) {
|
63
|
-
rest.onChange &&
|
64
|
-
rest.onChange({
|
65
|
-
target: { value: tempValue } as HTMLSelectElement,
|
66
|
-
} as any);
|
67
|
-
}
|
68
|
-
}, [tempValue]);
|
69
|
-
|
70
61
|
return (
|
71
62
|
<div className="flex flex-row-reverse items-end">
|
72
63
|
<label className={`grid gap-2 ${width}`}>
|
@@ -161,6 +152,11 @@ export const Select: React.FC<SelectProps> = ({
|
|
161
152
|
disabled={tempValue === item.value}
|
162
153
|
onClick={() => {
|
163
154
|
setTempValue(item.value);
|
155
|
+
if (rest.onChange) {
|
156
|
+
rest.onChange({
|
157
|
+
target: { value: item.value } as HTMLSelectElement,
|
158
|
+
} as any);
|
159
|
+
}
|
164
160
|
}}
|
165
161
|
>
|
166
162
|
{item.label}
|