@steroidsjs/core 2.2.77 → 2.2.78
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/hooks/useDataSelect.js +2 -1
- package/package.json +1 -1
package/hooks/useDataSelect.js
CHANGED
|
@@ -158,6 +158,7 @@ function useDataSelect(config) {
|
|
|
158
158
|
if ([9, 27].includes(e.which)) {
|
|
159
159
|
e.preventDefault();
|
|
160
160
|
setIsOpened(false);
|
|
161
|
+
setIsFocused(false);
|
|
161
162
|
}
|
|
162
163
|
// Keys: enter (select and close)
|
|
163
164
|
if (e.which === 13 && isOpened) {
|
|
@@ -178,8 +179,8 @@ function useDataSelect(config) {
|
|
|
178
179
|
}
|
|
179
180
|
// Keys: space (toggle select)
|
|
180
181
|
if (e.which === 32 && isOpened) {
|
|
181
|
-
e.preventDefault();
|
|
182
182
|
if (hoveredId) {
|
|
183
|
+
e.preventDefault();
|
|
183
184
|
// Select hovered
|
|
184
185
|
setSelectedIds(hoveredId);
|
|
185
186
|
}
|