@thecb/components 9.4.0-beta.6 → 9.4.0
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/dist/index.cjs.js +3 -9
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +3 -9
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/searchable-select/SearchableSelect.js +7 -8
- package/src/components/atoms/searchable-select/SearchableSelect.stories.js +0 -1
package/dist/index.esm.js
CHANGED
|
@@ -27546,15 +27546,9 @@ var SearchableSelect = function SearchableSelect(_ref) {
|
|
|
27546
27546
|
itemList = _useState2[0],
|
|
27547
27547
|
setItemList = _useState2[1];
|
|
27548
27548
|
|
|
27549
|
-
var
|
|
27550
|
-
return
|
|
27551
|
-
});
|
|
27552
|
-
|
|
27553
|
-
var completeOptionsList = [_objectSpread2({}, selectAllOption || {})].concat(_toConsumableArray(itemList.filter(function (item) {
|
|
27554
|
-
return item.name !== SELECT_ALL;
|
|
27555
|
-
}).sort(function (a, b) {
|
|
27556
|
-
return a.name.toLowerCase().localeCompare(b.name.toLowerCase());
|
|
27557
|
-
})));
|
|
27549
|
+
var completeOptionsList = itemList.sort(function (a, b) {
|
|
27550
|
+
return a.name == SELECT_ALL ? -1 : b.name === SELECT_ALL ? 1 : a.name.toLowerCase().localeCompare(b.name.toLowerCase());
|
|
27551
|
+
});
|
|
27558
27552
|
useEffect$1(function () {
|
|
27559
27553
|
return setItemList(items);
|
|
27560
27554
|
}, [items, selectedItems]);
|