@xqmsg/ui-core 0.16.2 → 0.16.3
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/ui-core.cjs.development.js +8 -2
- package/dist/ui-core.cjs.development.js.map +1 -1
- package/dist/ui-core.cjs.production.min.js +1 -1
- package/dist/ui-core.cjs.production.min.js.map +1 -1
- package/dist/ui-core.esm.js +8 -2
- package/dist/ui-core.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/input/StackedMultiSelect/index.tsx +8 -1
|
@@ -975,9 +975,15 @@ var StackedMultiSelect = /*#__PURE__*/React__default.forwardRef(function (_ref2,
|
|
|
975
975
|
return options.find(function (option) {
|
|
976
976
|
return option.value === value;
|
|
977
977
|
});
|
|
978
|
-
}));
|
|
978
|
+
})); // Filter out options that are already selected
|
|
979
|
+
|
|
980
|
+
setLocalOptions(function (prevLocalOptions) {
|
|
981
|
+
return prevLocalOptions.filter(function (localOption) {
|
|
982
|
+
return !localValues.includes(localOption);
|
|
983
|
+
});
|
|
984
|
+
});
|
|
979
985
|
}
|
|
980
|
-
}, [options, shouldSideScroll, watchedValue]);
|
|
986
|
+
}, [localValues, options, shouldSideScroll, watchedValue]);
|
|
981
987
|
|
|
982
988
|
var handleChange = function handleChange(option) {
|
|
983
989
|
setShouldSideScroll(true);
|