code7-leia 0.1.131 → 0.1.133

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.
@@ -976,6 +976,9 @@ var MultiSelect = function MultiSelect(_ref) {
976
976
  var _useState2 = React.useState(''),
977
977
  newOption = _useState2[0],
978
978
  setNewOption = _useState2[1];
979
+ React.useEffect(function () {
980
+ setExpanded(false);
981
+ }, []);
979
982
  var handleCheckboxChange = function handleCheckboxChange(value) {
980
983
  setPresset(function (prevPresset) {
981
984
  if (prevPresset.includes(value)) {
@@ -1411,8 +1414,21 @@ var FileArea = function FileArea() {
1411
1414
  value: tag
1412
1415
  };
1413
1416
  });
1414
- setOptionsPresset(options);
1417
+ if (options !== optionsPresset) {
1418
+ setOptionsPresset(options);
1419
+ }
1415
1420
  }, [tags]);
1421
+ React.useEffect(function () {
1422
+ if (!modal) {
1423
+ var options = tags.map(function (tag) {
1424
+ return {
1425
+ label: tag,
1426
+ value: tag
1427
+ };
1428
+ });
1429
+ setOptionsPresset(options);
1430
+ }
1431
+ }, [modal]);
1416
1432
  React.useEffect(function () {
1417
1433
  if (!!initFiles) {
1418
1434
  setFiles(initFiles);
@@ -1443,7 +1459,6 @@ var FileArea = function FileArea() {
1443
1459
  setModalDelete(false);
1444
1460
  };
1445
1461
  var handleUploadFile = function handleUploadFile() {
1446
- console.log('presset: ', presset);
1447
1462
  dispatch(uploadFilesAction(uploadFile, id, presset, language));
1448
1463
  setModal(false);
1449
1464
  setUploadFile(undefined);