@true-engineering/true-react-common-ui-kit 1.0.1 → 1.0.2

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.
Files changed (136) hide show
  1. package/LICENSE +1 -1
  2. package/dist/components/AccountInfo/AccountInfo.d.ts +4 -4
  3. package/dist/components/AccountInfo/AccountInfo.styles.d.ts +56 -60
  4. package/dist/components/AddButton/AddButton.d.ts +6 -6
  5. package/dist/components/AddButton/AddButton.styles.d.ts +23 -23
  6. package/dist/components/Button/Button.d.ts +33 -19
  7. package/dist/components/Button/Button.styles.d.ts +144 -144
  8. package/dist/components/Checkbox/Checkbox.d.ts +27 -16
  9. package/dist/components/Checkbox/Checkbox.styles.d.ts +42 -39
  10. package/dist/components/CloseButton/CloseButton.d.ts +4 -4
  11. package/dist/components/CloseButton/CloseButton.styles.d.ts +22 -22
  12. package/dist/components/Colors/Colors.styles.d.ts +28 -28
  13. package/dist/components/CssBaseline/CssBaseline.d.ts +1 -1
  14. package/dist/components/CssBaseline/CssBaseline.styles.d.ts +7 -7
  15. package/dist/components/DateInput/DateInput.d.ts +9 -8
  16. package/dist/components/DateInput/DateInput.styles.d.ts +7 -7
  17. package/dist/components/DatePicker/DatePicker.d.ts +36 -29
  18. package/dist/components/DatePicker/DatePicker.styles.d.ts +34 -38
  19. package/dist/components/DatePicker/DatePickerHeader/DatePickerHeader.d.ts +9 -9
  20. package/dist/components/DatePicker/DatePickerHeader/DatePickerHeader.styles.d.ts +59 -59
  21. package/dist/components/DatePicker/DatePickerInput/DatePickerInput.d.ts +9 -7
  22. package/dist/components/DatePicker/DatePickerInput/DatePickerInput.styles.d.ts +16 -16
  23. package/dist/components/Description/Description.d.ts +6 -6
  24. package/dist/components/Description/Description.styles.d.ts +18 -18
  25. package/dist/components/FiltersPane/FilterInterval/FilterInterval.d.ts +19 -19
  26. package/dist/components/FiltersPane/FilterInterval/FilterInterval.styles.d.ts +44 -44
  27. package/dist/components/FiltersPane/FilterMultiSelect/FilterMultiSelect.d.ts +8 -2
  28. package/dist/components/FiltersPane/FilterSelect/FilterSelect.d.ts +35 -17
  29. package/dist/components/FiltersPane/FilterSelect/FilterSelect.styles.d.ts +111 -111
  30. package/dist/components/FiltersPane/FilterSelect/locales.d.ts +10 -6
  31. package/dist/components/FiltersPane/FilterValueView/FilterValueView.d.ts +9 -1
  32. package/dist/components/FiltersPane/FilterValueView/FilterValueView.styles.d.ts +8 -8
  33. package/dist/components/FiltersPane/FilterWithDates/FilterWithDates.d.ts +21 -13
  34. package/dist/components/FiltersPane/FilterWithDates/FilterWithDates.styles.d.ts +41 -41
  35. package/dist/components/FiltersPane/FilterWithPeriod/FilterWithPeriod.d.ts +8 -8
  36. package/dist/components/FiltersPane/FilterWithPeriod/FilterWithPeriod.styles.d.ts +7 -7
  37. package/dist/components/FiltersPane/FilterWrapper/FilterWrapper.d.ts +41 -18
  38. package/dist/components/FiltersPane/FilterWrapper/FilterWrapper.styles.d.ts +92 -92
  39. package/dist/components/FiltersPane/FiltersPane.d.ts +34 -15
  40. package/dist/components/FiltersPane/FiltersPane.styles.d.ts +50 -50
  41. package/dist/components/FiltersPane/FiltersPaneSearch/FiltersPaneSearch.d.ts +37 -18
  42. package/dist/components/FiltersPane/FiltersPaneSearch/FiltersPaneSearch.styles.d.ts +82 -82
  43. package/dist/components/FiltersPane/locales.d.ts +28 -22
  44. package/dist/components/FiltersPane/types.d.ts +65 -38
  45. package/dist/components/Flag/Flag.d.ts +2 -2
  46. package/dist/components/Flag/Flag.styles.d.ts +8 -8
  47. package/dist/components/FlexibleTable/FlexibleTable.d.ts +45 -20
  48. package/dist/components/FlexibleTable/FlexibleTable.styles.d.ts +93 -93
  49. package/dist/components/FlexibleTable/TableRow.d.ts +38 -21
  50. package/dist/components/FlexibleTable/TableValue.d.ts +28 -16
  51. package/dist/components/FlexibleTable/types.d.ts +37 -31
  52. package/dist/components/Icon/ComplexIconBoilerplate.d.ts +1 -1
  53. package/dist/components/Icon/Icon.d.ts +2 -2
  54. package/dist/components/Icon/Icon.styles.d.ts +4 -4
  55. package/dist/components/Icon/IconBoilerplate.d.ts +1 -1
  56. package/dist/components/Icon/complexIcons/icons.d.ts +1 -1
  57. package/dist/components/Icon/icons/icons.d.ts +97 -5
  58. package/dist/components/IncrementInput/ChangeButton.d.ts +5 -5
  59. package/dist/components/IncrementInput/IncrementInput.d.ts +4 -3
  60. package/dist/components/IncrementInput/IncrementInput.styles.d.ts +52 -52
  61. package/dist/components/Input/Input.d.ts +48 -37
  62. package/dist/components/Input/Input.styles.d.ts +242 -242
  63. package/dist/components/List/List.d.ts +12 -12
  64. package/dist/components/List/List.styles.d.ts +35 -35
  65. package/dist/components/Modal/Modal.d.ts +19 -19
  66. package/dist/components/Modal/Modal.styles.d.ts +235 -235
  67. package/dist/components/MoreMenu/MoreMenu.d.ts +7 -7
  68. package/dist/components/MoreMenu/MoreMenu.styles.d.ts +45 -44
  69. package/dist/components/MultiSelect/MultiSelect.d.ts +28 -13
  70. package/dist/components/MultiSelect/MultiSelect.styles.d.ts +38 -38
  71. package/dist/components/MultiSelect/MultiSelectInput/MultiSelectInput.d.ts +12 -6
  72. package/dist/components/MultiSelect/MultiSelectInput/MultiSelectInput.styles.d.ts +58 -58
  73. package/dist/components/MultiSelectList/MultiSelectList.d.ts +43 -20
  74. package/dist/components/MultiSelectList/MultiSelectList.styles.d.ts +90 -90
  75. package/dist/components/MultiSelectList/locales.d.ts +10 -6
  76. package/dist/components/Notification/Notification.d.ts +14 -9
  77. package/dist/components/Notification/Notification.styles.d.ts +33 -30
  78. package/dist/components/NumberInput/NumberInput.d.ts +16 -10
  79. package/dist/components/NumberInput/helpers.d.ts +10 -2
  80. package/dist/components/PhoneInput/PhoneInput.d.ts +14 -7
  81. package/dist/components/PhoneInput/PhoneInput.styles.d.ts +60 -60
  82. package/dist/components/PhoneInput/PhoneInputCountryList/PhoneInputCountryList.d.ts +7 -7
  83. package/dist/components/PhoneInput/PhoneInputCountryList/PhoneInputCountryList.styles.d.ts +78 -74
  84. package/dist/components/PhoneInput/types.d.ts +11 -11
  85. package/dist/components/RadioButton/RadioButton.d.ts +18 -8
  86. package/dist/components/RadioButton/RadioButton.styles.d.ts +25 -25
  87. package/dist/components/ScrollIntoViewIfNeeded/ScrollIntoViewIfNeeded.d.ts +634 -374
  88. package/dist/components/SearchInput/SearchInput.d.ts +12 -2
  89. package/dist/components/SearchInput/SearchInput.styles.d.ts +32 -32
  90. package/dist/components/Select/Select.d.ts +50 -21
  91. package/dist/components/Select/Select.styles.d.ts +53 -53
  92. package/dist/components/Select/SelectList/SelectList.d.ts +30 -15
  93. package/dist/components/Select/SelectList/SelectList.styles.d.ts +37 -35
  94. package/dist/components/Select/helpers.d.ts +9 -2
  95. package/dist/components/SmartInput/SmartInput.d.ts +28 -16
  96. package/dist/components/SmartInput/helpers.d.ts +8 -4
  97. package/dist/components/Switch/Switch.d.ts +26 -13
  98. package/dist/components/Switch/Switch.styles.d.ts +58 -58
  99. package/dist/components/TextArea/TextArea.d.ts +26 -23
  100. package/dist/components/TextArea/TextArea.styles.d.ts +124 -124
  101. package/dist/components/TextWithInfo/TextWithInfo.d.ts +9 -9
  102. package/dist/components/TextWithInfo/TextWithInfo.styles.d.ts +40 -40
  103. package/dist/components/TextWithTooltip/TextWithTooltip.d.ts +12 -12
  104. package/dist/components/TextWithTooltip/TextWithTooltip.styles.d.ts +10 -10
  105. package/dist/components/ThemedPreloader/ThemedPreloader.d.ts +4 -4
  106. package/dist/components/ThemedPreloader/ThemedPreloader.styles.d.ts +10 -10
  107. package/dist/components/ThemedPreloader/components/DotsPreloader/DotsPreloader.d.ts +1 -1
  108. package/dist/components/ThemedPreloader/components/DotsPreloader/DotsPreloader.styles.d.ts +35 -35
  109. package/dist/components/ThemedPreloader/components/SvgPreloader/SvgPreloader.d.ts +2 -2
  110. package/dist/components/ThemedPreloader/components/SvgPreloader/SvgPreloader.styles.d.ts +5 -5
  111. package/dist/components/Toaster/Toaster.d.ts +16 -11
  112. package/dist/components/Toaster/Toaster.styles.d.ts +41 -41
  113. package/dist/components/Tooltip/Tooltip.d.ts +4 -4
  114. package/dist/components/Tooltip/Tooltip.styles.d.ts +25 -27
  115. package/dist/helpers/data-attributes.d.ts +11 -4
  116. package/dist/helpers/phone.d.ts +28 -8
  117. package/dist/helpers/utils.d.ts +28 -7
  118. package/dist/hooks/use-did-mount-effect.d.ts +4 -1
  119. package/dist/hooks/use-dropdown.d.ts +14 -7
  120. package/dist/hooks/use-is-mounted.d.ts +1 -1
  121. package/dist/hooks/use-on-click-outside.d.ts +25 -4
  122. package/dist/hooks/use-theme.d.ts +10 -5
  123. package/dist/hooks/use-tweak-styles.d.ts +5 -1
  124. package/dist/style.css +205 -90
  125. package/dist/theme.d.ts +51 -55
  126. package/dist/true-react-common-ui-kit.js +24375 -16679
  127. package/dist/true-react-common-ui-kit.js.map +1 -1
  128. package/dist/true-react-common-ui-kit.umd.cjs +300 -211
  129. package/dist/true-react-common-ui-kit.umd.cjs.map +1 -1
  130. package/dist/types.d.ts +77 -23
  131. package/package.json +1 -1
  132. package/src/components/List/List.tsx +9 -2
  133. package/src/components/Modal/Modal.tsx +1 -1
  134. package/src/components/MoreMenu/MoreMenu.styles.ts +2 -0
  135. package/src/components/MoreMenu/MoreMenu.tsx +35 -24
  136. package/src/types.ts +1 -1
@@ -246,28 +246,28 @@
246
246
  return null;
247
247
  }
248
248
  var ReactSharedInternals = React$1.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
249
- function error(format) {
249
+ function error(format2) {
250
250
  {
251
251
  {
252
252
  for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
253
253
  args[_key2 - 1] = arguments[_key2];
254
254
  }
255
- printWarning("error", format, args);
255
+ printWarning("error", format2, args);
256
256
  }
257
257
  }
258
258
  }
259
- function printWarning(level, format, args) {
259
+ function printWarning(level, format2, args) {
260
260
  {
261
261
  var ReactDebugCurrentFrame2 = ReactSharedInternals.ReactDebugCurrentFrame;
262
262
  var stack = ReactDebugCurrentFrame2.getStackAddendum();
263
263
  if (stack !== "") {
264
- format += "%s";
264
+ format2 += "%s";
265
265
  args = args.concat([stack]);
266
266
  }
267
267
  var argsWithFormat = args.map(function(item) {
268
268
  return String(item);
269
269
  });
270
- argsWithFormat.unshift("Warning: " + format);
270
+ argsWithFormat.unshift("Warning: " + format2);
271
271
  Function.prototype.apply.call(console[level], console, argsWithFormat);
272
272
  }
273
273
  }
@@ -1396,8 +1396,7 @@
1396
1396
  };
1397
1397
  var _phone_dialCode, _phone_phoneNumber;
1398
1398
  var getFullPhone = function(phone) {
1399
- var _phone, _phone1;
1400
- return ((_phone_dialCode = (_phone = phone) === null || _phone === void 0 ? void 0 : _phone.dialCode) !== null && _phone_dialCode !== void 0 ? _phone_dialCode : "") + ((_phone_phoneNumber = (_phone1 = phone) === null || _phone1 === void 0 ? void 0 : _phone1.phoneNumber) !== null && _phone_phoneNumber !== void 0 ? _phone_phoneNumber : "");
1399
+ return ((_phone_dialCode = phone === null || phone === void 0 ? void 0 : phone.dialCode) !== null && _phone_dialCode !== void 0 ? _phone_dialCode : "") + ((_phone_phoneNumber = phone === null || phone === void 0 ? void 0 : phone.phoneNumber) !== null && _phone_phoneNumber !== void 0 ? _phone_phoneNumber : "");
1401
1400
  };
1402
1401
  var getCountryCodeFromPhone = function(phoneWithCode) {
1403
1402
  var _phoneInfo_find;
@@ -1418,10 +1417,10 @@
1418
1417
  return countryCode;
1419
1418
  };
1420
1419
  var getPhoneObjFromString = function(fullPhone, countryCode) {
1421
- var _findCountryByCode, _dialCode;
1420
+ var _findCountryByCode;
1422
1421
  var newCountryCode = countryCode !== null && countryCode !== void 0 ? countryCode : getCountryCodeFromPhone(fullPhone);
1423
1422
  var dialCode = (_findCountryByCode = findCountryByCode(newCountryCode)) === null || _findCountryByCode === void 0 ? void 0 : _findCountryByCode.dialCode;
1424
- var phoneNumber = fullPhone.slice((_dialCode = dialCode) === null || _dialCode === void 0 ? void 0 : _dialCode.length);
1423
+ var phoneNumber = fullPhone.slice(dialCode === null || dialCode === void 0 ? void 0 : dialCode.length);
1425
1424
  return {
1426
1425
  dialCode,
1427
1426
  phoneNumber,
@@ -1508,16 +1507,14 @@
1508
1507
  theme: commonTheme
1509
1508
  });
1510
1509
  var useTheme = function(componentName, styles2, tweakStyles, options) {
1511
- var _components;
1512
1510
  var theme = React.useContext(ThemeContext).theme;
1513
1511
  var components = theme.components;
1514
1512
  var _components_componentName;
1515
1513
  var newStyles = React.useMemo(function() {
1516
- var _components2;
1517
- return lodash.merge({}, styles2, (_components_componentName = (_components2 = components) === null || _components2 === void 0 ? void 0 : _components2[componentName]) !== null && _components_componentName !== void 0 ? _components_componentName : {}, tweakStyles);
1514
+ return lodash.merge({}, styles2, (_components_componentName = components === null || components === void 0 ? void 0 : components[componentName]) !== null && _components_componentName !== void 0 ? _components_componentName : {}, tweakStyles);
1518
1515
  }, [
1519
1516
  styles2,
1520
- (_components = components) === null || _components === void 0 ? void 0 : _components[componentName],
1517
+ components === null || components === void 0 ? void 0 : components[componentName],
1521
1518
  tweakStyles
1522
1519
  ]);
1523
1520
  return {
@@ -1554,19 +1551,21 @@
1554
1551
  return target;
1555
1552
  }
1556
1553
  function useMounted() {
1557
- const mounted = React.useRef(true);
1558
- const isMounted = React.useRef(() => mounted.current);
1559
- React.useEffect(() => {
1554
+ var mounted = React.useRef(true);
1555
+ var isMounted = React.useRef(function() {
1556
+ return mounted.current;
1557
+ });
1558
+ React.useEffect(function() {
1560
1559
  mounted.current = true;
1561
- return () => {
1560
+ return function() {
1562
1561
  mounted.current = false;
1563
1562
  };
1564
1563
  }, []);
1565
1564
  return isMounted.current;
1566
1565
  }
1567
1566
  function useSafeState(state) {
1568
- const isMounted = useMounted();
1569
- return [state[0], React.useCallback((nextState) => {
1567
+ var isMounted = useMounted();
1568
+ return [state[0], React.useCallback(function(nextState) {
1570
1569
  if (!isMounted())
1571
1570
  return;
1572
1571
  return state[1](nextState);
@@ -1850,7 +1849,15 @@
1850
1849
  return;
1851
1850
  }
1852
1851
  }
1852
+ if (process.env.NODE_ENV !== "production") {
1853
+ if (!isHTMLElement(arrowElement)) {
1854
+ console.error(['Popper: "arrow" element must be an HTMLElement (not an SVGElement).', "To use an SVG arrow, wrap it in an HTMLElement that will be used as", "the arrow."].join(" "));
1855
+ }
1856
+ }
1853
1857
  if (!contains(state.elements.popper, arrowElement)) {
1858
+ if (process.env.NODE_ENV !== "production") {
1859
+ console.error(['Popper: "arrow" modifier\'s `element` must be a child of the popper', "element."].join(" "));
1860
+ }
1854
1861
  return;
1855
1862
  }
1856
1863
  state.elements.arrow = arrowElement;
@@ -1951,6 +1958,14 @@
1951
1958
  function computeStyles(_ref5) {
1952
1959
  var state = _ref5.state, options = _ref5.options;
1953
1960
  var _options$gpuAccelerat = options.gpuAcceleration, gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat, _options$adaptive = options.adaptive, adaptive = _options$adaptive === void 0 ? true : _options$adaptive, _options$roundOffsets = options.roundOffsets, roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;
1961
+ if (process.env.NODE_ENV !== "production") {
1962
+ var transitionProperty = getComputedStyle$1(state.elements.popper).transitionProperty || "";
1963
+ if (adaptive && ["transform", "top", "right", "bottom", "left"].some(function(property) {
1964
+ return transitionProperty.indexOf(property) >= 0;
1965
+ })) {
1966
+ console.warn(["Popper: Detected CSS transitions on at least one of the following", 'CSS properties: "transform", "top", "right", "bottom", "left".', "\n\n", 'Disable the "computeStyles" modifier\'s `adaptive` option to allow', "for smooth transitions, or remove these properties from the CSS", "transition declaration on the popper element if only transitioning", "opacity or background-color for example.", "\n\n", "We recommend using the popper element as a wrapper around an inner", "element that can have any CSS property transitioned for animations."].join(" "));
1967
+ }
1968
+ }
1954
1969
  var commonStyles = {
1955
1970
  placement: getBasePlacement(state.placement),
1956
1971
  variation: getVariation(state.placement),
@@ -2279,6 +2294,9 @@
2279
2294
  });
2280
2295
  if (allowedPlacements.length === 0) {
2281
2296
  allowedPlacements = placements$1;
2297
+ if (process.env.NODE_ENV !== "production") {
2298
+ console.error(["Popper: The `allowedAutoPlacements` option did not allow any", "placements. Ensure the `placement` option matches the variation", "of the allowed placements.", 'For example, "auto" cannot be used to allow "bottom-start".', 'Use "auto-start" instead.'].join(" "));
2299
+ }
2282
2300
  }
2283
2301
  var overflows = allowedPlacements.reduce(function(acc, placement2) {
2284
2302
  acc[placement2] = detectOverflow(state, {
@@ -2700,6 +2718,86 @@
2700
2718
  return pending;
2701
2719
  };
2702
2720
  }
2721
+ function format(str) {
2722
+ for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
2723
+ args[_key - 1] = arguments[_key];
2724
+ }
2725
+ return [].concat(args).reduce(function(p, c) {
2726
+ return p.replace(/%s/, c);
2727
+ }, str);
2728
+ }
2729
+ var INVALID_MODIFIER_ERROR = 'Popper: modifier "%s" provided an invalid %s property, expected %s but got %s';
2730
+ var MISSING_DEPENDENCY_ERROR = 'Popper: modifier "%s" requires "%s", but "%s" modifier is not available';
2731
+ var VALID_PROPERTIES = ["name", "enabled", "phase", "fn", "effect", "requires", "options"];
2732
+ function validateModifiers(modifiers) {
2733
+ modifiers.forEach(function(modifier) {
2734
+ [].concat(Object.keys(modifier), VALID_PROPERTIES).filter(function(value, index, self2) {
2735
+ return self2.indexOf(value) === index;
2736
+ }).forEach(function(key) {
2737
+ switch (key) {
2738
+ case "name":
2739
+ if (typeof modifier.name !== "string") {
2740
+ console.error(format(INVALID_MODIFIER_ERROR, String(modifier.name), '"name"', '"string"', '"' + String(modifier.name) + '"'));
2741
+ }
2742
+ break;
2743
+ case "enabled":
2744
+ if (typeof modifier.enabled !== "boolean") {
2745
+ console.error(format(INVALID_MODIFIER_ERROR, modifier.name, '"enabled"', '"boolean"', '"' + String(modifier.enabled) + '"'));
2746
+ }
2747
+ break;
2748
+ case "phase":
2749
+ if (modifierPhases.indexOf(modifier.phase) < 0) {
2750
+ console.error(format(INVALID_MODIFIER_ERROR, modifier.name, '"phase"', "either " + modifierPhases.join(", "), '"' + String(modifier.phase) + '"'));
2751
+ }
2752
+ break;
2753
+ case "fn":
2754
+ if (typeof modifier.fn !== "function") {
2755
+ console.error(format(INVALID_MODIFIER_ERROR, modifier.name, '"fn"', '"function"', '"' + String(modifier.fn) + '"'));
2756
+ }
2757
+ break;
2758
+ case "effect":
2759
+ if (modifier.effect != null && typeof modifier.effect !== "function") {
2760
+ console.error(format(INVALID_MODIFIER_ERROR, modifier.name, '"effect"', '"function"', '"' + String(modifier.fn) + '"'));
2761
+ }
2762
+ break;
2763
+ case "requires":
2764
+ if (modifier.requires != null && !Array.isArray(modifier.requires)) {
2765
+ console.error(format(INVALID_MODIFIER_ERROR, modifier.name, '"requires"', '"array"', '"' + String(modifier.requires) + '"'));
2766
+ }
2767
+ break;
2768
+ case "requiresIfExists":
2769
+ if (!Array.isArray(modifier.requiresIfExists)) {
2770
+ console.error(format(INVALID_MODIFIER_ERROR, modifier.name, '"requiresIfExists"', '"array"', '"' + String(modifier.requiresIfExists) + '"'));
2771
+ }
2772
+ break;
2773
+ case "options":
2774
+ case "data":
2775
+ break;
2776
+ default:
2777
+ console.error('PopperJS: an invalid property has been provided to the "' + modifier.name + '" modifier, valid properties are ' + VALID_PROPERTIES.map(function(s) {
2778
+ return '"' + s + '"';
2779
+ }).join(", ") + '; but "' + key + '" was provided.');
2780
+ }
2781
+ modifier.requires && modifier.requires.forEach(function(requirement) {
2782
+ if (modifiers.find(function(mod) {
2783
+ return mod.name === requirement;
2784
+ }) == null) {
2785
+ console.error(format(MISSING_DEPENDENCY_ERROR, String(modifier.name), requirement, requirement));
2786
+ }
2787
+ });
2788
+ });
2789
+ });
2790
+ }
2791
+ function uniqueBy(arr, fn) {
2792
+ var identifiers = /* @__PURE__ */ new Set();
2793
+ return arr.filter(function(item) {
2794
+ var identifier = fn(item);
2795
+ if (!identifiers.has(identifier)) {
2796
+ identifiers.add(identifier);
2797
+ return true;
2798
+ }
2799
+ });
2800
+ }
2703
2801
  function mergeByName(modifiers) {
2704
2802
  var merged = modifiers.reduce(function(merged2, current) {
2705
2803
  var existing = merged2[current.name];
@@ -2713,6 +2811,8 @@
2713
2811
  return merged[key];
2714
2812
  });
2715
2813
  }
2814
+ var INVALID_ELEMENT_ERROR = "Popper: Invalid reference or popper argument provided. They must be either a DOM element or virtual element.";
2815
+ var INFINITE_LOOP_ERROR = "Popper: An infinite loop in the modifiers cycle has been detected! The cycle has been interrupted to prevent a browser crash.";
2716
2816
  var DEFAULT_OPTIONS = {
2717
2817
  placement: "bottom",
2718
2818
  modifiers: [],
@@ -2763,6 +2863,28 @@
2763
2863
  state.orderedModifiers = orderedModifiers.filter(function(m) {
2764
2864
  return m.enabled;
2765
2865
  });
2866
+ if (process.env.NODE_ENV !== "production") {
2867
+ var modifiers = uniqueBy([].concat(orderedModifiers, state.options.modifiers), function(_ref) {
2868
+ var name = _ref.name;
2869
+ return name;
2870
+ });
2871
+ validateModifiers(modifiers);
2872
+ if (getBasePlacement(state.options.placement) === auto) {
2873
+ var flipModifier = state.orderedModifiers.find(function(_ref2) {
2874
+ var name = _ref2.name;
2875
+ return name === "flip";
2876
+ });
2877
+ if (!flipModifier) {
2878
+ console.error(['Popper: "auto" placements require the "flip" modifier be', "present and enabled to work."].join(" "));
2879
+ }
2880
+ }
2881
+ var _getComputedStyle = getComputedStyle$1(popper2), marginTop = _getComputedStyle.marginTop, marginRight = _getComputedStyle.marginRight, marginBottom = _getComputedStyle.marginBottom, marginLeft = _getComputedStyle.marginLeft;
2882
+ if ([marginTop, marginRight, marginBottom, marginLeft].some(function(margin) {
2883
+ return parseFloat(margin);
2884
+ })) {
2885
+ console.warn(['Popper: CSS "margin" styles cannot be used to apply padding', "between the popper and its reference element or boundary.", "To replicate margin, use the `offset` modifier, as well as", "the `padding` option in the `preventOverflow` and `flip`", "modifiers."].join(" "));
2886
+ }
2887
+ }
2766
2888
  runModifierEffects();
2767
2889
  return instance.update();
2768
2890
  },
@@ -2777,6 +2899,9 @@
2777
2899
  }
2778
2900
  var _state$elements = state.elements, reference3 = _state$elements.reference, popper3 = _state$elements.popper;
2779
2901
  if (!areValidElements(reference3, popper3)) {
2902
+ if (process.env.NODE_ENV !== "production") {
2903
+ console.error(INVALID_ELEMENT_ERROR);
2904
+ }
2780
2905
  return;
2781
2906
  }
2782
2907
  state.rects = {
@@ -2788,7 +2913,15 @@
2788
2913
  state.orderedModifiers.forEach(function(modifier) {
2789
2914
  return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);
2790
2915
  });
2916
+ var __debug_loops__ = 0;
2791
2917
  for (var index = 0; index < state.orderedModifiers.length; index++) {
2918
+ if (process.env.NODE_ENV !== "production") {
2919
+ __debug_loops__ += 1;
2920
+ if (__debug_loops__ > 100) {
2921
+ console.error(INFINITE_LOOP_ERROR);
2922
+ break;
2923
+ }
2924
+ }
2792
2925
  if (state.reset === true) {
2793
2926
  state.reset = false;
2794
2927
  index = -1;
@@ -2819,6 +2952,9 @@
2819
2952
  }
2820
2953
  };
2821
2954
  if (!areValidElements(reference2, popper2)) {
2955
+ if (process.env.NODE_ENV !== "production") {
2956
+ console.error(INVALID_ELEMENT_ERROR);
2957
+ }
2822
2958
  return instance;
2823
2959
  }
2824
2960
  instance.setOptions(options).then(function(state2) {
@@ -2827,8 +2963,8 @@
2827
2963
  }
2828
2964
  });
2829
2965
  function runModifierEffects() {
2830
- state.orderedModifiers.forEach(function(_ref) {
2831
- var name = _ref.name, _ref$options = _ref.options, options2 = _ref$options === void 0 ? {} : _ref$options, effect2 = _ref.effect;
2966
+ state.orderedModifiers.forEach(function(_ref3) {
2967
+ var name = _ref3.name, _ref3$options = _ref3.options, options2 = _ref3$options === void 0 ? {} : _ref3$options, effect2 = _ref3.effect;
2832
2968
  if (typeof effect2 === "function") {
2833
2969
  var cleanupFn = effect2({
2834
2970
  state,
@@ -3093,20 +3229,17 @@
3093
3229
  }
3094
3230
  React.useEffect(function() {
3095
3231
  if (dependenciesForPositionUpdating.length !== 0) {
3096
- var _popperData;
3097
- (_popperData = popperData) === null || _popperData === void 0 ? void 0 : _popperData.update();
3232
+ popperData === null || popperData === void 0 ? void 0 : popperData.update();
3098
3233
  }
3099
3234
  }, dependenciesForPositionUpdating);
3100
3235
  return popperData;
3101
3236
  };
3102
3237
  var useTweakStyles = function() {
3103
3238
  var componentStyles = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, tweakStyles = arguments.length > 1 ? arguments[1] : void 0, className = arguments.length > 2 ? arguments[2] : void 0;
3104
- var _tweakStyles;
3105
3239
  return React.useMemo(function() {
3106
- var _tweakStyles2;
3107
- return lodash.merge({}, componentStyles[className], (_tweakStyles2 = tweakStyles) === null || _tweakStyles2 === void 0 ? void 0 : _tweakStyles2[className]);
3240
+ return lodash.merge({}, componentStyles[className], tweakStyles === null || tweakStyles === void 0 ? void 0 : tweakStyles[className]);
3108
3241
  }, [
3109
- (_tweakStyles = tweakStyles) === null || _tweakStyles === void 0 ? void 0 : _tweakStyles[className]
3242
+ tweakStyles === null || tweakStyles === void 0 ? void 0 : tweakStyles[className]
3110
3243
  ]);
3111
3244
  };
3112
3245
  var useDidMountEffect = function(effect2, dependencies) {
@@ -4318,10 +4451,10 @@
4318
4451
  var items = param.items, testId = param.testId, data = param.data, tweakStyles = param.tweakStyles, onClick = param.onClick;
4319
4452
  var classes = useTheme("List", styles$J, tweakStyles).classes;
4320
4453
  var handleItemClick = function(item) {
4321
- var _onClick;
4322
4454
  item.onClick();
4323
- (_onClick = onClick) === null || _onClick === void 0 ? void 0 : _onClick();
4455
+ onClick === null || onClick === void 0 ? void 0 : onClick();
4324
4456
  };
4457
+ var _item_testId;
4325
4458
  return /* @__PURE__ */ jsx("div", _object_spread_props$z(_object_spread$I({
4326
4459
  className: classes.root
4327
4460
  }, addDataTestId(testId), addDataAttributes(data)), {
@@ -4334,7 +4467,9 @@
4334
4467
  }),
4335
4468
  /* @__PURE__ */ jsxs("div", _object_spread_props$z(_object_spread$I({
4336
4469
  className: clsx(classes.item, (_obj = {}, _define_property$K(_obj, classes.disabledItem, item.disabled), _define_property$K(_obj, classes.withIconGap, item.withIconGap), _obj))
4337
- }, addDataTestId(testId, "item-".concat(idx))), {
4470
+ }, addDataTestId((_item_testId = item.testId) !== null && _item_testId !== void 0 ? _item_testId : getTestId(testId, "item-".concat(idx))), item.disabled && addDataAttributes({
4471
+ disabled: item.disabled
4472
+ })), {
4338
4473
  onClick: item.disabled ? void 0 : function() {
4339
4474
  return handleItemClick(item);
4340
4475
  },
@@ -5178,13 +5313,11 @@
5178
5313
  ];
5179
5314
  var Button = function(param) {
5180
5315
  var _param_type = param.type, type = _param_type === void 0 ? "button" : _param_type, children = param.children, _param_size = param.size, size = _param_size === void 0 ? "l" : _param_size, _param_view = param.view, view = _param_view === void 0 ? "primary" : _param_view, _param_isFullWidth = param.isFullWidth, isFullWidth = _param_isFullWidth === void 0 ? false : _param_isFullWidth, _param_isInline = param.isInline, isInline = _param_isInline === void 0 ? false : _param_isInline, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, _param_isActive = param.isActive, isActive = _param_isActive === void 0 ? false : _param_isActive, _param_isLoading = param.isLoading, isLoading = _param_isLoading === void 0 ? false : _param_isLoading, _param_shouldSkipTabNavigation = param.shouldSkipTabNavigation, shouldSkipTabNavigation = _param_shouldSkipTabNavigation === void 0 ? false : _param_shouldSkipTabNavigation, data = param.data, testId = param.testId, tweakStyles = param.tweakStyles, icon = param.icon, _param_iconPosition = param.iconPosition, iconPosition = _param_iconPosition === void 0 ? "left" : _param_iconPosition, _param_preloaderType = param.preloaderType, preloaderType = _param_preloaderType === void 0 ? "dots" : _param_preloaderType, onClick = param.onClick, onMouseDown = param.onMouseDown;
5181
- var _tweakStyles;
5182
5316
  var _useTheme = useTheme("Button", styles$D, tweakStyles), classes = _useTheme.classes, componentStyles = _useTheme.componentStyles;
5183
5317
  var tweakPreloaderStyles = React.useMemo(function() {
5184
- var _tweakStyles2;
5185
- return lodash.merge({}, size === "s" || size === "m" ? dotsPreloaderStyles : void 0, componentStyles.tweakPreloader, (_tweakStyles2 = tweakStyles) === null || _tweakStyles2 === void 0 ? void 0 : _tweakStyles2.tweakPreloader);
5318
+ return lodash.merge({}, size === "s" || size === "m" ? dotsPreloaderStyles : void 0, componentStyles.tweakPreloader, tweakStyles === null || tweakStyles === void 0 ? void 0 : tweakStyles.tweakPreloader);
5186
5319
  }, [
5187
- (_tweakStyles = tweakStyles) === null || _tweakStyles === void 0 ? void 0 : _tweakStyles.tweakPreloader,
5320
+ tweakStyles === null || tweakStyles === void 0 ? void 0 : tweakStyles.tweakPreloader,
5188
5321
  size
5189
5322
  ]);
5190
5323
  var hasIcon = isNotEmpty(icon);
@@ -6108,7 +6241,7 @@
6108
6241
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
6109
6242
  return _array_like_to_array$k(o, minLen);
6110
6243
  }
6111
- function _ts_generator$5(thisArg, body) {
6244
+ var __generator$5 = globalThis && globalThis.__generator || function(thisArg, body) {
6112
6245
  var f, y, t, g, _ = {
6113
6246
  label: 0,
6114
6247
  sent: function() {
@@ -6209,7 +6342,7 @@
6209
6342
  done: true
6210
6343
  };
6211
6344
  }
6212
- }
6345
+ };
6213
6346
  var DEFAULT_SIZE = 6;
6214
6347
  var Input = /* @__PURE__ */ React.forwardRef(function(param, ref) {
6215
6348
  var _param_value = param.value, value = _param_value === void 0 ? "" : _param_value, label = param.label, placeholder = param.placeholder, _param_type = param.type, type = _param_type === void 0 ? "text" : _param_type, isDisabled = param.isDisabled, isReadonly = param.isReadonly, _param_hasFloatingLabel = param.hasFloatingLabel, hasFloatingLabel = _param_hasFloatingLabel === void 0 ? true : _param_hasFloatingLabel, _param_isInvalid = param.isInvalid, isInvalid = _param_isInvalid === void 0 ? false : _param_isInvalid, _param_isActive = param.isActive, isActive = _param_isActive === void 0 ? false : _param_isActive, _param_isClearable = param.isClearable, isClearable = _param_isClearable === void 0 ? false : _param_isClearable, infoMessage = param.infoMessage, errorMessage = param.errorMessage, _param_errorPosition = param.errorPosition, errorPosition = _param_errorPosition === void 0 ? "bottom" : _param_errorPosition, inlineStyle = param.inlineStyle, border = param.border, isRequired = param.isRequired, isLoading = param.isLoading, isAutoSizeable = param.isAutoSizeable, _param_defaultSize = param.defaultSize, defaultSize = _param_defaultSize === void 0 ? DEFAULT_SIZE : _param_defaultSize, iconType = param.iconType, name = param.name, mask = param.mask, maskPlaceholder = param.maskPlaceholder, hasRequiredLabel = param.hasRequiredLabel, data = param.data, tweakStyles = param.tweakStyles, maxLength = param.maxLength, shouldFocusOnMount = param.shouldFocusOnMount, units = param.units, testId = param.testId, tabIndex = param.tabIndex, onChange = param.onChange, onPaste = param.onPaste, onFocus = param.onFocus, onBlur = param.onBlur, onIconClick = param.onIconClick, onKeyDown = param.onKeyDown;
@@ -6220,19 +6353,17 @@
6220
6353
  onChange(event.currentTarget.value, event);
6221
6354
  };
6222
6355
  var handleFocus = function(event) {
6223
- var _onFocus;
6224
6356
  setFocused(true);
6225
- (_onFocus = onFocus) === null || _onFocus === void 0 ? void 0 : _onFocus(event);
6357
+ onFocus === null || onFocus === void 0 ? void 0 : onFocus(event);
6226
6358
  };
6227
6359
  var handleBlur = function(event) {
6228
- var _onBlur;
6229
6360
  setFocused(false);
6230
- (_onBlur = onBlur) === null || _onBlur === void 0 ? void 0 : _onBlur(event);
6361
+ onBlur === null || onBlur === void 0 ? void 0 : onBlur(event);
6231
6362
  };
6232
6363
  var handleOnInputClear = function() {
6233
6364
  var _ref = _async_to_generator$5(function(event) {
6234
6365
  var _input_current, input;
6235
- return _ts_generator$5(this, function(_state) {
6366
+ return __generator$5(this, function(_state) {
6236
6367
  switch (_state.label) {
6237
6368
  case 0:
6238
6369
  return [
@@ -6823,9 +6954,8 @@
6823
6954
  return obj;
6824
6955
  }
6825
6956
  function isOptionDisabled(option) {
6826
- var _option;
6827
6957
  var _option_isDisabled;
6828
- return typeof option === "object" && option !== null && ((_option_isDisabled = (_option = option) === null || _option === void 0 ? void 0 : _option.isDisabled) !== null && _option_isDisabled !== void 0 ? _option_isDisabled : false);
6958
+ return typeof option === "object" && option !== null && ((_option_isDisabled = option === null || option === void 0 ? void 0 : option.isDisabled) !== null && _option_isDisabled !== void 0 ? _option_isDisabled : false);
6829
6959
  }
6830
6960
  var DEFAULT_OPTION_INDEX = -1;
6831
6961
  function SelectList(param) {
@@ -7137,7 +7267,7 @@
7137
7267
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
7138
7268
  return _array_like_to_array$j(o, minLen);
7139
7269
  }
7140
- function _ts_generator$4(thisArg, body) {
7270
+ var __generator$4 = globalThis && globalThis.__generator || function(thisArg, body) {
7141
7271
  var f, y, t, g, _ = {
7142
7272
  label: 0,
7143
7273
  sent: function() {
@@ -7238,7 +7368,7 @@
7238
7368
  done: true
7239
7369
  };
7240
7370
  }
7241
- }
7371
+ };
7242
7372
  function Select(_param) {
7243
7373
  var options = _param.options, value = _param.value, onChange = _param.onChange, _param_compareValuesOnChange = _param.compareValuesOnChange, compareValuesOnChange = _param_compareValuesOnChange === void 0 ? defaultCompareFunction : _param_compareValuesOnChange, _param_convertValueToString = _param.convertValueToString, convertValueToString = _param_convertValueToString === void 0 ? defaultConvertFunction$2 : _param_convertValueToString, convertValueToId = _param.convertValueToId, convertValueToReactNode = _param.convertValueToReactNode, defaultOptionLabel = _param.defaultOptionLabel, onFocus = _param.onFocus, onBlur = _param.onBlur, onType = _param.onType, onOpen = _param.onOpen, _param_debounceTime = _param.debounceTime, debounceTime = _param_debounceTime === void 0 ? 400 : _param_debounceTime, _param_optionsMode = _param.optionsMode, optionsMode = _param_optionsMode === void 0 ? "normal" : _param_optionsMode, optionsFilter = _param.optionsFilter, noMatchesLabel = _param.noMatchesLabel, loadingLabel = _param.loadingLabel, tweakStyles = _param.tweakStyles, testId = _param.testId, isDisabled = _param.isDisabled, dropdownOptions = _param.dropdownOptions, _param_minSymbolsCountToOpenList = _param.minSymbolsCountToOpenList, minSymbolsCountToOpenList = _param_minSymbolsCountToOpenList === void 0 ? 0 : _param_minSymbolsCountToOpenList, _param_dropdownIcon = _param.dropdownIcon, dropdownIcon = _param_dropdownIcon === void 0 ? "chevron-down" : _param_dropdownIcon, inputProps = _object_without_properties$6(_param, [
7244
7374
  "options",
@@ -7265,7 +7395,6 @@
7265
7395
  "minSymbolsCountToOpenList",
7266
7396
  "dropdownIcon"
7267
7397
  ]);
7268
- var _tweakStyles, _popperData, _popperData1, _tweakStyles1;
7269
7398
  var _useTheme = useTheme("Select", styles$u, tweakStyles), classes = _useTheme.classes, componentStyles = _useTheme.componentStyles;
7270
7399
  var isMounted = useIsMounted();
7271
7400
  var _useState = _sliced_to_array$j(React.useState(false), 2), isListOpen = _useState[0], setIsListOpen = _useState[1];
@@ -7278,14 +7407,13 @@
7278
7407
  var list = React.useRef(null);
7279
7408
  var input = React.useRef(null);
7280
7409
  var filteredOptions = React.useMemo(function() {
7281
- var _searchValue;
7282
7410
  if (optionsMode !== "search") {
7283
7411
  return options;
7284
7412
  }
7285
7413
  if (optionsFilter) {
7286
7414
  return optionsFilter(options, searchValue);
7287
7415
  }
7288
- var lowerCaseValue = (_searchValue = searchValue) === null || _searchValue === void 0 ? void 0 : _searchValue.toLowerCase();
7416
+ var lowerCaseValue = searchValue === null || searchValue === void 0 ? void 0 : searchValue.toLowerCase();
7289
7417
  return options.filter(function(option) {
7290
7418
  var convertedOption = convertValueToString(option);
7291
7419
  return convertedOption !== void 0 && convertedOption.toLowerCase().includes(lowerCaseValue);
@@ -7311,7 +7439,7 @@
7311
7439
  };
7312
7440
  var handleListOpen = function() {
7313
7441
  var _ref2 = _async_to_generator$4(function() {
7314
- return _ts_generator$4(this, function(_state) {
7442
+ return __generator$4(this, function(_state) {
7315
7443
  if (isListOpen) {
7316
7444
  return [
7317
7445
  2
@@ -7363,7 +7491,7 @@
7363
7491
  ]);
7364
7492
  var handleOnType = React.useCallback(function() {
7365
7493
  var _ref2 = _async_to_generator$4(function(v) {
7366
- return _ts_generator$4(this, function(_state) {
7494
+ return __generator$4(this, function(_state) {
7367
7495
  switch (_state.label) {
7368
7496
  case 0:
7369
7497
  if (onType === void 0) {
@@ -7481,14 +7609,13 @@
7481
7609
  var _inputProps_isReadonly = inputProps.isReadonly, isReadonly = _inputProps_isReadonly === void 0 ? true : _inputProps_isReadonly;
7482
7610
  var shouldUsePointerCursor = optionsMode === "normal" && isReadonly;
7483
7611
  var tweakInputStyles = React.useMemo(function() {
7484
- var _tweakStyles2;
7485
7612
  return lodash.merge({}, componentStyles.tweakInput, _object_spread$v({}, shouldUsePointerCursor ? {
7486
7613
  input: {
7487
7614
  cursor: "pointer"
7488
7615
  }
7489
- } : void 0), (_tweakStyles2 = tweakStyles) === null || _tweakStyles2 === void 0 ? void 0 : _tweakStyles2.tweakInput);
7616
+ } : void 0), tweakStyles === null || tweakStyles === void 0 ? void 0 : tweakStyles.tweakInput);
7490
7617
  }, [
7491
- (_tweakStyles = tweakStyles) === null || _tweakStyles === void 0 ? void 0 : _tweakStyles.tweakInput,
7618
+ tweakStyles === null || tweakStyles === void 0 ? void 0 : tweakStyles.tweakInput,
7492
7619
  shouldUsePointerCursor
7493
7620
  ]);
7494
7621
  var _ref = dropdownOptions !== null && dropdownOptions !== void 0 ? dropdownOptions : {}, _ref_shouldUsePopper = _ref.shouldUsePopper, shouldUsePopper = _ref_shouldUsePopper === void 0 ? false : _ref_shouldUsePopper, _ref_shouldRenderInBody = _ref.shouldRenderInBody, shouldRenderInBody = _ref_shouldRenderInBody === void 0 ? false : _ref_shouldRenderInBody, _ref_shouldHideOnScroll = _ref.shouldHideOnScroll, shouldHideOnScroll = _ref_shouldHideOnScroll === void 0 ? false : _ref_shouldHideOnScroll;
@@ -7555,8 +7682,8 @@
7555
7682
  onMouseDown: function(event) {
7556
7683
  return event.preventDefault();
7557
7684
  },
7558
- style: (_popperData = popperData) === null || _popperData === void 0 ? void 0 : _popperData.styles.popper
7559
- }, (_popperData1 = popperData) === null || _popperData1 === void 0 ? void 0 : _popperData1.attributes.popper), {
7685
+ style: popperData === null || popperData === void 0 ? void 0 : popperData.styles.popper
7686
+ }, popperData === null || popperData === void 0 ? void 0 : popperData.attributes.popper), {
7560
7687
  children: isOpen && /* @__PURE__ */ jsx(SelectList, {
7561
7688
  options: filteredOptions,
7562
7689
  convertValueToString,
@@ -7569,7 +7696,7 @@
7569
7696
  activeValue: value,
7570
7697
  isLoading: inputProps.isLoading,
7571
7698
  loadingLabel,
7572
- tweakStyles: (_tweakStyles1 = tweakStyles) === null || _tweakStyles1 === void 0 ? void 0 : _tweakStyles1.tweakSelectList,
7699
+ tweakStyles: tweakStyles === null || tweakStyles === void 0 ? void 0 : tweakStyles.tweakSelectList,
7573
7700
  testId: testId !== void 0 ? "".concat(testId, "-list") : void 0,
7574
7701
  shouldScrollToList: !shouldUsePopper && !shouldHideOnScroll
7575
7702
  })
@@ -8874,7 +9001,7 @@
8874
9001
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
8875
9002
  return _array_like_to_array$g(o, minLen);
8876
9003
  }
8877
- function _ts_generator$3(thisArg, body) {
9004
+ var __generator$3 = globalThis && globalThis.__generator || function(thisArg, body) {
8878
9005
  var f, y, t, g, _ = {
8879
9006
  label: 0,
8880
9007
  sent: function() {
@@ -8975,7 +9102,7 @@
8975
9102
  done: true
8976
9103
  };
8977
9104
  }
8978
- }
9105
+ };
8979
9106
  var defaultConvertFunction$1 = function(val) {
8980
9107
  return String(val);
8981
9108
  };
@@ -9002,8 +9129,8 @@
9002
9129
  var hasFooter = isNotEmpty(footer);
9003
9130
  var handleSearchInputChange = React.useCallback(function() {
9004
9131
  var _ref = _async_to_generator$3(function(inputValue) {
9005
- var _inputValue, _inputValue_trim, response;
9006
- return _ts_generator$3(this, function(_state) {
9132
+ var _inputValue_trim, response;
9133
+ return __generator$3(this, function(_state) {
9007
9134
  switch (_state.label) {
9008
9135
  case 0:
9009
9136
  if (fetchOptions === void 0) {
@@ -9022,7 +9149,7 @@
9022
9149
  ]);
9023
9150
  return [
9024
9151
  4,
9025
- fetchOptions((_inputValue_trim = (_inputValue = inputValue) === null || _inputValue === void 0 ? void 0 : _inputValue.trim()) !== null && _inputValue_trim !== void 0 ? _inputValue_trim : "")
9152
+ fetchOptions((_inputValue_trim = inputValue === null || inputValue === void 0 ? void 0 : inputValue.trim()) !== null && _inputValue_trim !== void 0 ? _inputValue_trim : "")
9026
9153
  ];
9027
9154
  case 2:
9028
9155
  response = _state.sent();
@@ -9082,8 +9209,8 @@
9082
9209
  };
9083
9210
  var handleLoadItemsOnScroll = React.useCallback(function() {
9084
9211
  var _ref = _async_to_generator$3(function(inputValue, page) {
9085
- var _inputValue, _inputValue_trim, response;
9086
- return _ts_generator$3(this, function(_state) {
9212
+ var _inputValue_trim, response;
9213
+ return __generator$3(this, function(_state) {
9087
9214
  switch (_state.label) {
9088
9215
  case 0:
9089
9216
  if (fetchOptions === void 0) {
@@ -9102,7 +9229,7 @@
9102
9229
  ]);
9103
9230
  return [
9104
9231
  4,
9105
- fetchOptions((_inputValue_trim = (_inputValue = inputValue) === null || _inputValue === void 0 ? void 0 : _inputValue.trim()) !== null && _inputValue_trim !== void 0 ? _inputValue_trim : "", page !== null && page !== void 0 ? page : 0)
9232
+ fetchOptions((_inputValue_trim = inputValue === null || inputValue === void 0 ? void 0 : inputValue.trim()) !== null && _inputValue_trim !== void 0 ? _inputValue_trim : "", page !== null && page !== void 0 ? page : 0)
9106
9233
  ];
9107
9234
  case 2:
9108
9235
  response = _state.sent();
@@ -9148,7 +9275,7 @@
9148
9275
  }
9149
9276
  observer.current = new IntersectionObserver(function() {
9150
9277
  var _ref = _async_to_generator$3(function(entries) {
9151
- return _ts_generator$3(this, function(_state) {
9278
+ return __generator$3(this, function(_state) {
9152
9279
  switch (_state.label) {
9153
9280
  case 0:
9154
9281
  if (!entries[0].isIntersecting)
@@ -9197,7 +9324,7 @@
9197
9324
  var doFetchOptions = function() {
9198
9325
  var _ref = _async_to_generator$3(function() {
9199
9326
  var response;
9200
- return _ts_generator$3(this, function(_state) {
9327
+ return __generator$3(this, function(_state) {
9201
9328
  switch (_state.label) {
9202
9329
  case 0:
9203
9330
  setIsLoading(true);
@@ -10150,7 +10277,7 @@
10150
10277
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
10151
10278
  return _array_like_to_array$e(o, minLen);
10152
10279
  }
10153
- function _ts_generator$2(thisArg, body) {
10280
+ var __generator$2 = globalThis && globalThis.__generator || function(thisArg, body) {
10154
10281
  var f, y, t, g, _ = {
10155
10282
  label: 0,
10156
10283
  sent: function() {
@@ -10251,7 +10378,7 @@
10251
10378
  done: true
10252
10379
  };
10253
10380
  }
10254
- }
10381
+ };
10255
10382
  var NumberInput = /* @__PURE__ */ React.forwardRef(function(_param, ref) {
10256
10383
  var value = _param.value, _param_canBeFloat = _param.canBeFloat, canBeFloat = _param_canBeFloat === void 0 ? false : _param_canBeFloat, defaultValue = _param.defaultValue, _param_precision = _param.precision, precision = _param_precision === void 0 ? 3 : _param_precision, _param_intPartPrecision = _param.intPartPrecision, intPartPrecision = _param_intPartPrecision === void 0 ? 7 : _param_intPartPrecision, onChange = _param.onChange, onBlur = _param.onBlur, min2 = _param.min, max2 = _param.max, props = _object_without_properties$3(_param, [
10257
10384
  "value",
@@ -10277,7 +10404,7 @@
10277
10404
  var handleChange = function() {
10278
10405
  var _ref = _async_to_generator$2(function(inputValue, event) {
10279
10406
  var oldValue, target, _target_selectionStart, defaultCaretPos, numString, intRegexp, floatRegexp, numberRegexp, hasDot, formattedValue, newValue;
10280
- return _ts_generator$2(this, function(_state) {
10407
+ return __generator$2(this, function(_state) {
10281
10408
  switch (_state.label) {
10282
10409
  case 0:
10283
10410
  oldValue = showedValue;
@@ -10472,7 +10599,6 @@
10472
10599
  };
10473
10600
  var FilterInterval = function(param) {
10474
10601
  var data = param.data, tweakStyles = param.tweakStyles, value = param.value, labelName = param.labelName, withFieldNameInLabel = param.withFieldNameInLabel, localeKey = param.localeKey, locale2 = param.locale, canBeFloat = param.canBeFloat, onChange = param.onChange, fromInput = param.fromInput, toInput = param.toInput, testId = param.testId;
10475
- var _value, _fromInput, _fromInput1, _fromInput2, _value1, _toInput, _toInput1, _toInput2;
10476
10602
  var _useTheme = useTheme("FilterInterval", styles$l, tweakStyles), classes = _useTheme.classes, componentStyles = _useTheme.componentStyles;
10477
10603
  var translates = React.useMemo(function() {
10478
10604
  return getLocale$1(localeKey, locale2);
@@ -10484,24 +10610,22 @@
10484
10610
  onChange(void 0);
10485
10611
  };
10486
10612
  var handleFromChange = function(v) {
10487
- var _value2, _value12;
10488
- if (v === void 0 && ((_value2 = value) === null || _value2 === void 0 ? void 0 : _value2[1]) === void 0) {
10613
+ if (v === void 0 && (value === null || value === void 0 ? void 0 : value[1]) === void 0) {
10489
10614
  onChange(void 0);
10490
10615
  return;
10491
10616
  }
10492
10617
  onChange(sortValues([
10493
10618
  v,
10494
- (_value12 = value) === null || _value12 === void 0 ? void 0 : _value12[1]
10619
+ value === null || value === void 0 ? void 0 : value[1]
10495
10620
  ]));
10496
10621
  };
10497
10622
  var handleToChange = function(v) {
10498
- var _value2, _value12;
10499
- if (v === void 0 && ((_value2 = value) === null || _value2 === void 0 ? void 0 : _value2[0]) === void 0) {
10623
+ if (v === void 0 && (value === null || value === void 0 ? void 0 : value[0]) === void 0) {
10500
10624
  onChange(void 0);
10501
10625
  return;
10502
10626
  }
10503
10627
  onChange(sortValues([
10504
- (_value12 = value) === null || _value12 === void 0 ? void 0 : _value12[0],
10628
+ value === null || value === void 0 ? void 0 : value[0],
10505
10629
  v
10506
10630
  ]));
10507
10631
  };
@@ -10518,14 +10642,14 @@
10518
10642
  children: [
10519
10643
  /* @__PURE__ */ jsx(NumberInput, {
10520
10644
  onChange: handleFromChange,
10521
- value: (_value = value) === null || _value === void 0 ? void 0 : _value[0],
10645
+ value: value === null || value === void 0 ? void 0 : value[0],
10522
10646
  label: withFieldNameInLabel ? "".concat(labelName, " ").concat(translates.from.toLocaleLowerCase()) : translates.from,
10523
10647
  border: "bottom",
10524
10648
  canBeFloat,
10525
10649
  isClearable: true,
10526
- min: (_fromInput = fromInput) === null || _fromInput === void 0 ? void 0 : _fromInput.min,
10527
- max: (_fromInput1 = fromInput) === null || _fromInput1 === void 0 ? void 0 : _fromInput1.max,
10528
- maxLength: (_fromInput2 = fromInput) === null || _fromInput2 === void 0 ? void 0 : _fromInput2.maxLength,
10650
+ min: fromInput === null || fromInput === void 0 ? void 0 : fromInput.min,
10651
+ max: fromInput === null || fromInput === void 0 ? void 0 : fromInput.max,
10652
+ maxLength: fromInput === null || fromInput === void 0 ? void 0 : fromInput.maxLength,
10529
10653
  tweakStyles: tweakInputStyles,
10530
10654
  testId: testId !== void 0 ? "".concat(testId, "-start") : void 0
10531
10655
  }),
@@ -10543,14 +10667,14 @@
10543
10667
  children: [
10544
10668
  /* @__PURE__ */ jsx(NumberInput, {
10545
10669
  onChange: handleToChange,
10546
- value: (_value1 = value) === null || _value1 === void 0 ? void 0 : _value1[1],
10670
+ value: value === null || value === void 0 ? void 0 : value[1],
10547
10671
  label: withFieldNameInLabel ? "".concat(labelName, " ").concat(translates.to.toLocaleLowerCase()) : translates.to,
10548
10672
  border: "bottom",
10549
10673
  canBeFloat,
10550
10674
  isClearable: true,
10551
- min: (_toInput = toInput) === null || _toInput === void 0 ? void 0 : _toInput.min,
10552
- max: (_toInput1 = toInput) === null || _toInput1 === void 0 ? void 0 : _toInput1.max,
10553
- maxLength: (_toInput2 = toInput) === null || _toInput2 === void 0 ? void 0 : _toInput2.maxLength,
10675
+ min: toInput === null || toInput === void 0 ? void 0 : toInput.min,
10676
+ max: toInput === null || toInput === void 0 ? void 0 : toInput.max,
10677
+ maxLength: toInput === null || toInput === void 0 ? void 0 : toInput.maxLength,
10554
10678
  tweakStyles: tweakInputStyles,
10555
10679
  testId: testId !== void 0 ? "".concat(testId, "-end") : void 0
10556
10680
  }),
@@ -10902,7 +11026,7 @@
10902
11026
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
10903
11027
  return _array_like_to_array$d(o, minLen);
10904
11028
  }
10905
- function _ts_generator$1(thisArg, body) {
11029
+ var __generator$1 = globalThis && globalThis.__generator || function(thisArg, body) {
10906
11030
  var f, y, t, g, _ = {
10907
11031
  label: 0,
10908
11032
  sent: function() {
@@ -11003,7 +11127,7 @@
11003
11127
  done: true
11004
11128
  };
11005
11129
  }
11006
- }
11130
+ };
11007
11131
  var defaultConvertFunction = function(val) {
11008
11132
  return String(val);
11009
11133
  };
@@ -11023,7 +11147,6 @@
11023
11147
  changeSearchValue(inputValue);
11024
11148
  }
11025
11149
  };
11026
- var _value, _chosenValues;
11027
11150
  var isMounted = useIsMounted();
11028
11151
  var _useTheme = useTheme("MultiSelectList", styles$k, tweakStyles, {
11029
11152
  width
@@ -11037,10 +11160,9 @@
11037
11160
  localeKey,
11038
11161
  locale2
11039
11162
  ]);
11040
- var chosenValues = (_value = value) === null || _value === void 0 ? void 0 : _value.include;
11163
+ var chosenValues = value === null || value === void 0 ? void 0 : value.include;
11041
11164
  var chosenValuesIds = React.useMemo(function() {
11042
- var _chosenValues2;
11043
- return (_chosenValues2 = chosenValues) === null || _chosenValues2 === void 0 ? void 0 : _chosenValues2.map(getValueId);
11165
+ return chosenValues === null || chosenValues === void 0 ? void 0 : chosenValues.map(getValueId);
11044
11166
  }, [
11045
11167
  getValueId,
11046
11168
  chosenValues
@@ -11055,8 +11177,7 @@
11055
11177
  var observer = React.useRef();
11056
11178
  var unchosenOptions = React.useMemo(function() {
11057
11179
  return allOptions.filter(function(v) {
11058
- var _chosenValuesIds;
11059
- return !((_chosenValuesIds = chosenValuesIds) === null || _chosenValuesIds === void 0 ? void 0 : _chosenValuesIds.includes(getValueId(v)));
11180
+ return !(chosenValuesIds === null || chosenValuesIds === void 0 ? void 0 : chosenValuesIds.includes(getValueId(v)));
11060
11181
  });
11061
11182
  }, [
11062
11183
  getValueId,
@@ -11065,8 +11186,8 @@
11065
11186
  ]);
11066
11187
  var handleSearchInputChange = React.useCallback(function() {
11067
11188
  var _ref = _async_to_generator$1(function(inputValue) {
11068
- var _inputValue, _inputValue_trim, response;
11069
- return _ts_generator$1(this, function(_state) {
11189
+ var _inputValue_trim, response;
11190
+ return __generator$1(this, function(_state) {
11070
11191
  switch (_state.label) {
11071
11192
  case 0:
11072
11193
  if (fetchOptions === void 0) {
@@ -11085,7 +11206,7 @@
11085
11206
  ]);
11086
11207
  return [
11087
11208
  4,
11088
- fetchOptions((_inputValue_trim = (_inputValue = inputValue) === null || _inputValue === void 0 ? void 0 : _inputValue.trim()) !== null && _inputValue_trim !== void 0 ? _inputValue_trim : "")
11209
+ fetchOptions((_inputValue_trim = inputValue === null || inputValue === void 0 ? void 0 : inputValue.trim()) !== null && _inputValue_trim !== void 0 ? _inputValue_trim : "")
11089
11210
  ];
11090
11211
  case 2:
11091
11212
  response = _state.sent();
@@ -11135,11 +11256,10 @@
11135
11256
  onChange(void 0);
11136
11257
  };
11137
11258
  var onSelect = function(val) {
11138
- var _chosenValues2;
11139
11259
  var _chosenValues_filter;
11140
11260
  handleSelectValue(val.isSelected ? _to_consumable_array$2(chosenValues !== null && chosenValues !== void 0 ? chosenValues : []).concat([
11141
11261
  val.value
11142
- ]) : (_chosenValues_filter = (_chosenValues2 = chosenValues) === null || _chosenValues2 === void 0 ? void 0 : _chosenValues2.filter(function(v) {
11262
+ ]) : (_chosenValues_filter = chosenValues === null || chosenValues === void 0 ? void 0 : chosenValues.filter(function(v) {
11143
11263
  return getValueId(v) !== getValueId(val.value);
11144
11264
  })) !== null && _chosenValues_filter !== void 0 ? _chosenValues_filter : []);
11145
11265
  };
@@ -11151,9 +11271,8 @@
11151
11271
  }
11152
11272
  }
11153
11273
  if (event.code === "ArrowDown") {
11154
- var _value2;
11155
11274
  var _value_include_length;
11156
- if (keyCursorOn < unchosenOptions.length + ((_value_include_length = (_value2 = value) === null || _value2 === void 0 ? void 0 : _value2.include.length) !== null && _value_include_length !== void 0 ? _value_include_length : 0) - 1) {
11275
+ if (keyCursorOn < unchosenOptions.length + ((_value_include_length = value === null || value === void 0 ? void 0 : value.include.length) !== null && _value_include_length !== void 0 ? _value_include_length : 0) - 1) {
11157
11276
  setKeyCursorOn(keyCursorOn + 1);
11158
11277
  }
11159
11278
  }
@@ -11191,15 +11310,14 @@
11191
11310
  }
11192
11311
  };
11193
11312
  var getIsValueChosen = function(id) {
11194
- var _chosenValues2;
11195
- return (_chosenValues2 = chosenValues) === null || _chosenValues2 === void 0 ? void 0 : _chosenValues2.some(function(v) {
11313
+ return chosenValues === null || chosenValues === void 0 ? void 0 : chosenValues.some(function(v) {
11196
11314
  return getValueId(v) === id;
11197
11315
  });
11198
11316
  };
11199
11317
  var handleLoadItemsOnScroll = React.useCallback(function() {
11200
11318
  var _ref = _async_to_generator$1(function(inputValue, page) {
11201
11319
  var response;
11202
- return _ts_generator$1(this, function(_state) {
11320
+ return __generator$1(this, function(_state) {
11203
11321
  switch (_state.label) {
11204
11322
  case 0:
11205
11323
  if (fetchOptions === void 0) {
@@ -11266,7 +11384,7 @@
11266
11384
  }
11267
11385
  observer.current = new IntersectionObserver(function() {
11268
11386
  var _ref = _async_to_generator$1(function(entries) {
11269
- return _ts_generator$1(this, function(_state) {
11387
+ return __generator$1(this, function(_state) {
11270
11388
  switch (_state.label) {
11271
11389
  case 0:
11272
11390
  if (!entries[0].isIntersecting)
@@ -11315,7 +11433,7 @@
11315
11433
  var doFetchOptions = function() {
11316
11434
  var _ref = _async_to_generator$1(function() {
11317
11435
  var response;
11318
- return _ts_generator$1(this, function(_state) {
11436
+ return __generator$1(this, function(_state) {
11319
11437
  switch (_state.label) {
11320
11438
  case 0:
11321
11439
  setIsLoading(true);
@@ -11401,7 +11519,7 @@
11401
11519
  className: clsx(classes.label, classes.labelChosen, !isSearchEnabled && classes.withoutTopGap),
11402
11520
  children: translates.chosen
11403
11521
  }),
11404
- (_chosenValues = chosenValues) === null || _chosenValues === void 0 ? void 0 : _chosenValues.map(function(val) {
11522
+ chosenValues === null || chosenValues === void 0 ? void 0 : chosenValues.map(function(val) {
11405
11523
  var id = getValueId(val);
11406
11524
  var view = getValueView(val);
11407
11525
  return /* @__PURE__ */ jsx("div", {
@@ -11734,8 +11852,8 @@
11734
11852
  return function() {
11735
11853
  var options = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
11736
11854
  var width = options.width ? String(options.width) : args.defaultWidth;
11737
- var format = args.formats[width] || args.formats[args.defaultWidth];
11738
- return format;
11855
+ var format2 = args.formats[width] || args.formats[args.defaultWidth];
11856
+ return format2;
11739
11857
  };
11740
11858
  }
11741
11859
  var dateFormats$1 = {
@@ -11898,11 +12016,11 @@
11898
12016
  other: "P"
11899
12017
  };
11900
12018
  var formatRelative$2 = function formatRelative2(token, date, baseDate, options) {
11901
- var format = formatRelativeLocale$1[token];
11902
- if (typeof format === "function") {
11903
- return format(date, baseDate, options);
12019
+ var format2 = formatRelativeLocale$1[token];
12020
+ if (typeof format2 === "function") {
12021
+ return format2(date, baseDate, options);
11904
12022
  }
11905
- return format;
12023
+ return format2;
11906
12024
  };
11907
12025
  const formatRelative$3 = formatRelative$2;
11908
12026
  function buildLocalizeFn(args) {
@@ -12755,7 +12873,6 @@
12755
12873
  var DATE_FORMAT = "dd.MM.yyyy";
12756
12874
  var FilterWithDates = function(param) {
12757
12875
  var value = param.value, onChange = param.onChange, localeKey = param.localeKey, locale2 = param.locale, onStartBtnSubmit = param.onStartBtnSubmit, onEndBtnSubmit = param.onEndBtnSubmit, data = param.data, tweakStyles = param.tweakStyles, testId = param.testId, _param_startPickerProps = param.startPickerProps, startPickerProps = _param_startPickerProps === void 0 ? emptyPickerProps : _param_startPickerProps, _param_endPickerProps = param.endPickerProps, endPickerProps = _param_endPickerProps === void 0 ? emptyPickerProps : _param_endPickerProps, _param_isClearable = param.isClearable, isClearable = _param_isClearable === void 0 ? true : _param_isClearable;
12758
- var _value, _value1, _value2, _value3, _value4, _value5;
12759
12876
  var _useTheme = useTheme("FilterWithDates", styles$j, tweakStyles), classes = _useTheme.classes, componentStyles = _useTheme.componentStyles;
12760
12877
  var _useState = _sliced_to_array$c(React.useState(false), 2), isOpenFrom = _useState[0], setOpenFrom = _useState[1];
12761
12878
  var _useState1 = _sliced_to_array$c(React.useState(false), 2), isOpenTo = _useState1[0], setOpenTo = _useState1[1];
@@ -12775,19 +12892,17 @@
12775
12892
  var ref = React.useRef(null);
12776
12893
  var isOpenCalendar = isOpenFrom || isOpenTo;
12777
12894
  var handleFromSelected = function(val) {
12778
- var _value6;
12779
12895
  var _value_to2;
12780
12896
  onChange({
12781
12897
  from: val,
12782
- to: (_value_to2 = (_value6 = value) === null || _value6 === void 0 ? void 0 : _value6.to) !== null && _value_to2 !== void 0 ? _value_to2 : null
12898
+ to: (_value_to2 = value === null || value === void 0 ? void 0 : value.to) !== null && _value_to2 !== void 0 ? _value_to2 : null
12783
12899
  });
12784
12900
  setOpenFrom(false);
12785
12901
  };
12786
12902
  var handleToSelected = function(val) {
12787
- var _value6;
12788
12903
  var _value_from2;
12789
12904
  onChange({
12790
- from: (_value_from2 = (_value6 = value) === null || _value6 === void 0 ? void 0 : _value6.from) !== null && _value_from2 !== void 0 ? _value_from2 : null,
12905
+ from: (_value_from2 = value === null || value === void 0 ? void 0 : value.from) !== null && _value_from2 !== void 0 ? _value_from2 : null,
12791
12906
  to: val
12792
12907
  });
12793
12908
  setOpenTo(false);
@@ -12799,11 +12914,10 @@
12799
12914
  to: val
12800
12915
  });
12801
12916
  } else {
12802
- var _value6;
12803
12917
  var _value_to2;
12804
12918
  onChange({
12805
12919
  from: val,
12806
- to: (_value_to2 = (_value6 = value) === null || _value6 === void 0 ? void 0 : _value6.to) !== null && _value_to2 !== void 0 ? _value_to2 : null
12920
+ to: (_value_to2 = value === null || value === void 0 ? void 0 : value.to) !== null && _value_to2 !== void 0 ? _value_to2 : null
12807
12921
  });
12808
12922
  }
12809
12923
  };
@@ -12814,10 +12928,9 @@
12814
12928
  to: value.from
12815
12929
  });
12816
12930
  } else {
12817
- var _value6;
12818
12931
  var _value_from2;
12819
12932
  onChange({
12820
- from: (_value_from2 = (_value6 = value) === null || _value6 === void 0 ? void 0 : _value6.from) !== null && _value_from2 !== void 0 ? _value_from2 : null,
12933
+ from: (_value_from2 = value === null || value === void 0 ? void 0 : value.from) !== null && _value_from2 !== void 0 ? _value_from2 : null,
12821
12934
  to: val
12822
12935
  });
12823
12936
  }
@@ -12835,8 +12948,8 @@
12835
12948
  /* @__PURE__ */ jsx("div", {
12836
12949
  className: classes.containerItem,
12837
12950
  children: /* @__PURE__ */ jsx(DatePicker, _object_spread$j({
12838
- selectedDate: (_value_from = (_value = value) === null || _value === void 0 ? void 0 : _value.from) !== null && _value_from !== void 0 ? _value_from : null,
12839
- maxDate: (_value1 = value) === null || _value1 === void 0 ? void 0 : _value1.to,
12951
+ selectedDate: (_value_from = value === null || value === void 0 ? void 0 : value.from) !== null && _value_from !== void 0 ? _value_from : null,
12952
+ maxDate: value === null || value === void 0 ? void 0 : value.to,
12840
12953
  label: translates.from,
12841
12954
  months: translates.months,
12842
12955
  locale: dateLocale,
@@ -12852,10 +12965,10 @@
12852
12965
  /* @__PURE__ */ jsx("div", {
12853
12966
  className: classes.containerItem,
12854
12967
  children: /* @__PURE__ */ jsx(DatePicker, _object_spread$j({
12855
- selectedDate: (_value_to = (_value2 = value) === null || _value2 === void 0 ? void 0 : _value2.to) !== null && _value_to !== void 0 ? _value_to : null,
12968
+ selectedDate: (_value_to = value === null || value === void 0 ? void 0 : value.to) !== null && _value_to !== void 0 ? _value_to : null,
12856
12969
  label: translates.to,
12857
12970
  months: translates.months,
12858
- minDate: (_value3 = value) === null || _value3 === void 0 ? void 0 : _value3.from,
12971
+ minDate: value === null || value === void 0 ? void 0 : value.from,
12859
12972
  locale: dateLocale,
12860
12973
  onChangeDate: handleChangeTo,
12861
12974
  topPosition,
@@ -12898,7 +13011,7 @@
12898
13011
  ref,
12899
13012
  className: classes.datepicker,
12900
13013
  children: /* @__PURE__ */ jsx(DatePicker, {
12901
- selectedDate: (_ref = isOpenFrom ? (_value4 = value) === null || _value4 === void 0 ? void 0 : _value4.from : (_value5 = value) === null || _value5 === void 0 ? void 0 : _value5.to) !== null && _ref !== void 0 ? _ref : null,
13014
+ selectedDate: (_ref = isOpenFrom ? value === null || value === void 0 ? void 0 : value.from : value === null || value === void 0 ? void 0 : value.to) !== null && _ref !== void 0 ? _ref : null,
12902
13015
  label: "",
12903
13016
  locale: dateLocale,
12904
13017
  months: translates.months,
@@ -13086,7 +13199,6 @@
13086
13199
  };
13087
13200
  var FilterWithPeriod = function(param) {
13088
13201
  var value = param.value, localeKey = param.localeKey, locale2 = param.locale, onChange = param.onChange, onClose = param.onClose, periods = param.periods, tweakStyles = param.tweakStyles, testId = param.testId;
13089
- var _value, _value1, _value2, _value3, _value4, _period;
13090
13202
  var _useTheme = useTheme("FilterWithPeriod", styles$i, tweakStyles), classes = _useTheme.classes, componentStyles = _useTheme.componentStyles;
13091
13203
  var translates = React.useMemo(function() {
13092
13204
  return getLocale$1(localeKey, locale2);
@@ -13094,13 +13206,12 @@
13094
13206
  localeKey,
13095
13207
  locale2
13096
13208
  ]);
13097
- var _useState = _sliced_to_array$b(React.useState(((_value = value) === null || _value === void 0 ? void 0 : _value.periodType) !== "CUSTOM"), 2), isPeriodPickerShown = _useState[0], setIsPeriodPickerShown = _useState[1];
13098
- var _useState1 = _sliced_to_array$b(React.useState(((_value1 = value) === null || _value1 === void 0 ? void 0 : _value1.periodType) === "CUSTOM"), 2), isDatePickerShown = _useState1[0], setIsDatePickerShown = _useState1[1];
13209
+ var _useState = _sliced_to_array$b(React.useState((value === null || value === void 0 ? void 0 : value.periodType) !== "CUSTOM"), 2), isPeriodPickerShown = _useState[0], setIsPeriodPickerShown = _useState[1];
13210
+ var _useState1 = _sliced_to_array$b(React.useState((value === null || value === void 0 ? void 0 : value.periodType) === "CUSTOM"), 2), isDatePickerShown = _useState1[0], setIsDatePickerShown = _useState1[1];
13099
13211
  var _useState2 = _sliced_to_array$b(React.useState(value), 2), period = _useState2[0], setPeriod = _useState2[1];
13100
13212
  var periodGetters = React.useMemo(function() {
13101
- var _periods;
13102
13213
  var result = _object_spread$i({}, PERIODS_GETTERS);
13103
- (_periods = periods) === null || _periods === void 0 ? void 0 : _periods.forEach(function(p) {
13214
+ periods === null || periods === void 0 ? void 0 : periods.forEach(function(p) {
13104
13215
  if (Array.isArray(p)) {
13105
13216
  result[p[0]] = p[1];
13106
13217
  }
@@ -13173,8 +13284,7 @@
13173
13284
  }
13174
13285
  };
13175
13286
  useOnClickOutside(refDatePicker, function() {
13176
- var _period2, _period1;
13177
- if (!((_period2 = period) === null || _period2 === void 0 ? void 0 : _period2.from) && !((_period1 = period) === null || _period1 === void 0 ? void 0 : _period1.to)) {
13287
+ if (!(period === null || period === void 0 ? void 0 : period.from) && !(period === null || period === void 0 ? void 0 : period.to)) {
13178
13288
  setPeriod(void 0);
13179
13289
  }
13180
13290
  setIsDatePickerShown(false);
@@ -13183,9 +13293,9 @@
13183
13293
  setPeriod(value);
13184
13294
  }, [
13185
13295
  value,
13186
- (_value2 = value) === null || _value2 === void 0 ? void 0 : _value2.from,
13187
- (_value3 = value) === null || _value3 === void 0 ? void 0 : _value3.to,
13188
- (_value4 = value) === null || _value4 === void 0 ? void 0 : _value4.periodType
13296
+ value === null || value === void 0 ? void 0 : value.from,
13297
+ value === null || value === void 0 ? void 0 : value.to,
13298
+ value === null || value === void 0 ? void 0 : value.periodType
13189
13299
  ]);
13190
13300
  var tweakSelectStyles = useTweakStyles(componentStyles, tweakStyles, "tweakSelect");
13191
13301
  return /* @__PURE__ */ jsxs("div", {
@@ -13196,7 +13306,7 @@
13196
13306
  ref: refPeriodPicker,
13197
13307
  children: /* @__PURE__ */ jsx(FilterSelect, {
13198
13308
  options: periodsList,
13199
- value: (_period = period) === null || _period === void 0 ? void 0 : _period.periodType,
13309
+ value: period === null || period === void 0 ? void 0 : period.periodType,
13200
13310
  onChange: onPeriodChange,
13201
13311
  localeKey,
13202
13312
  locale: translates,
@@ -13579,8 +13689,7 @@
13579
13689
  }
13580
13690
  }, parentRef);
13581
13691
  React.useLayoutEffect(function() {
13582
- var _filtersPaneRef;
13583
- if (ref.current === null || filtersPaneRef === void 0 || filtersPaneRef === null || ((_filtersPaneRef = filtersPaneRef) === null || _filtersPaneRef === void 0 ? void 0 : _filtersPaneRef.current) === null) {
13692
+ if (ref.current === null || filtersPaneRef === void 0 || filtersPaneRef === null || (filtersPaneRef === null || filtersPaneRef === void 0 ? void 0 : filtersPaneRef.current) === null) {
13584
13693
  return;
13585
13694
  }
13586
13695
  var _ref_current_getBoundingClientRect = ref.current.getBoundingClientRect(), width = _ref_current_getBoundingClientRect.width, left2 = _ref_current_getBoundingClientRect.left;
@@ -13807,7 +13916,7 @@
13807
13916
  testId: testId !== void 0 ? "".concat(testId, "-search") : void 0
13808
13917
  })),
13809
13918
  filtersKeys.map(function(key, index) {
13810
- var _filter_requiredFilledFilters, _filter;
13919
+ var _filter_requiredFilledFilters;
13811
13920
  var isLast = index === filtersKeys.length - 1;
13812
13921
  var currentValue = values[key];
13813
13922
  var filter = filtersConfig[key];
@@ -13826,7 +13935,7 @@
13826
13935
  return onChangeFilters(_object_spread_props$e(_object_spread$g({}, values), _define_property$h({}, key, value)));
13827
13936
  },
13828
13937
  value: currentValue,
13829
- isDisabled: isDisabled || ((_filter = filter) === null || _filter === void 0 ? void 0 : (_filter_requiredFilledFilters = _filter.requiredFilledFilters) === null || _filter_requiredFilledFilters === void 0 ? void 0 : _filter_requiredFilledFilters.some(function(item) {
13938
+ isDisabled: isDisabled || (filter === null || filter === void 0 ? void 0 : (_filter_requiredFilledFilters = filter.requiredFilledFilters) === null || _filter_requiredFilledFilters === void 0 ? void 0 : _filter_requiredFilledFilters.some(function(item) {
13830
13939
  return !values[item];
13831
13940
  })),
13832
13941
  filtersPaneRef: ref,
@@ -19995,13 +20104,11 @@
19995
20104
  var DEFAULT_DATE_FORMAT = "dd.MM.yyyy";
19996
20105
  function TableValue(param) {
19997
20106
  var item = param.item, columnName = param.columnName, config = param.config, classes = param.classes, isFocusedRow = param.isFocusedRow, isSecond = param.isSecond, isSticky = param.isSticky, isNestedComponentExpanded = param.isNestedComponentExpanded, isRowNestedComponentExpanded = param.isRowNestedComponentExpanded, onSetNestedComponent = param.onSetNestedComponent;
19998
- var _config, _itemConfig, _itemConfig1, _itemConfig2, _itemConfig3, _itemConfig4, _itemConfig5;
19999
- var itemConfig = (_config = config) === null || _config === void 0 ? void 0 : _config[columnName];
20107
+ var itemConfig = config === null || config === void 0 ? void 0 : config[columnName];
20000
20108
  var value = item[columnName];
20001
20109
  var content = null;
20002
- if ((_itemConfig = itemConfig) === null || _itemConfig === void 0 ? void 0 : _itemConfig.component) {
20003
- var _itemConfig6;
20004
- var ValueComponent = (_itemConfig6 = itemConfig) === null || _itemConfig6 === void 0 ? void 0 : _itemConfig6.component;
20110
+ if (itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.component) {
20111
+ var ValueComponent = itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.component;
20005
20112
  content = /* @__PURE__ */ jsx(ValueComponent, {
20006
20113
  value,
20007
20114
  row: item,
@@ -20013,17 +20120,16 @@
20013
20120
  } else if (typeof value === "string" || typeof value === "number") {
20014
20121
  content = value;
20015
20122
  } else if (_instanceof(value, Date)) {
20016
- var _itemConfig7;
20017
- content = dateFns.format(value, ((_itemConfig7 = itemConfig) === null || _itemConfig7 === void 0 ? void 0 : _itemConfig7.dateFormat) || DEFAULT_DATE_FORMAT);
20123
+ content = dateFns.format(value, (itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.dateFormat) || DEFAULT_DATE_FORMAT);
20018
20124
  }
20019
20125
  return /* @__PURE__ */ jsx("td", {
20020
20126
  className: clsx(classes.root, isSticky && classes.sticky, isSecond && classes.second),
20021
20127
  style: {
20022
- textAlign: (_itemConfig1 = itemConfig) === null || _itemConfig1 === void 0 ? void 0 : _itemConfig1.cellAlign,
20023
- position: isSticky ? "sticky" : (_itemConfig2 = itemConfig) === null || _itemConfig2 === void 0 ? void 0 : _itemConfig2.position,
20024
- right: (_itemConfig3 = itemConfig) === null || _itemConfig3 === void 0 ? void 0 : _itemConfig3.right,
20025
- left: isSticky ? 0 : (_itemConfig4 = itemConfig) === null || _itemConfig4 === void 0 ? void 0 : _itemConfig4.left,
20026
- verticalAlign: (_itemConfig5 = itemConfig) === null || _itemConfig5 === void 0 ? void 0 : _itemConfig5.cellVerticalAlign
20128
+ textAlign: itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.cellAlign,
20129
+ position: isSticky ? "sticky" : itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.position,
20130
+ right: itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.right,
20131
+ left: isSticky ? 0 : itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.left,
20132
+ verticalAlign: itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.cellVerticalAlign
20027
20133
  },
20028
20134
  children: content
20029
20135
  }, columnName);
@@ -20140,12 +20246,11 @@
20140
20246
  }
20141
20247
  function TableRow(param) {
20142
20248
  var item = param.item, uniqueField = param.uniqueField, isFirstColumnSticky = param.isFirstColumnSticky, isActive = param.isActive, config = param.config, enabledColumns = param.enabledColumns, onRowHover = param.onRowHover, onRowClick = param.onRowClick, rowAttributes = param.rowAttributes, expandableRowComponent = param.expandableRowComponent, classes = param.classes;
20143
- var _rowAttributes;
20144
20249
  var _useState = _sliced_to_array$9(React.useState(false), 2), isFocused = _useState[0], setFocused = _useState[1];
20145
20250
  var _useState1 = _sliced_to_array$9(React.useState({
20146
20251
  isOpen: false
20147
20252
  }), 2), nestedComponent = _useState1[0], setNestedComponent = _useState1[1];
20148
- var rowData = (_rowAttributes = rowAttributes) === null || _rowAttributes === void 0 ? void 0 : _rowAttributes.reduce(function(acc, cur) {
20253
+ var rowData = rowAttributes === null || rowAttributes === void 0 ? void 0 : rowAttributes.reduce(function(acc, cur) {
20149
20254
  var val = item[cur];
20150
20255
  if (val !== void 0) {
20151
20256
  acc[cur] = String(item[cur]);
@@ -20174,8 +20279,7 @@
20174
20279
  };
20175
20280
  var handleRowClick = function() {
20176
20281
  if (uniqueField !== void 0) {
20177
- var _onRowClick;
20178
- (_onRowClick = onRowClick) === null || _onRowClick === void 0 ? void 0 : _onRowClick(item[uniqueField]);
20282
+ onRowClick === null || onRowClick === void 0 ? void 0 : onRowClick(item[uniqueField]);
20179
20283
  }
20180
20284
  if (expandableRowComponent !== void 0) {
20181
20285
  var newNestedComponent = expandableRowComponent(item, true, closeNestedComponent);
@@ -20467,7 +20571,6 @@
20467
20571
  }
20468
20572
  function FlexibleTable(param) {
20469
20573
  var data = param.data, tweakStyles = param.tweakStyles, content = param.content, headerContent = param.headerContent, config = param.config, activeRows = param.activeRows, enabledColumns = param.enabledColumns, isHorizontallyScrollable = param.isHorizontallyScrollable, isFirstColumnSticky = param.isFirstColumnSticky, infinityScrollConfig = param.infinityScrollConfig, uniqueField = param.uniqueField, onHeadClick = param.onHeadClick, onRowHover = param.onRowHover, onRowClick = param.onRowClick, refForScroll = param.refForScroll, rowAttributes = param.rowAttributes, nothingFoundContent = param.nothingFoundContent, testId = param.testId, expandableRowComponent = param.expandableRowComponent;
20470
- var _infinityScrollConfig, _infinityScrollConfig1, _infinityScrollConfig2, _infinityScrollConfig3, _infinityScrollConfig4;
20471
20574
  var classes = useTheme("FlexibleTable", styles$f, tweakStyles).classes;
20472
20575
  var observer = React.useRef();
20473
20576
  var scrollRef = React.useRef(null);
@@ -20490,9 +20593,9 @@
20490
20593
  }
20491
20594
  }
20492
20595
  }, [
20493
- (_infinityScrollConfig = infinityScrollConfig) === null || _infinityScrollConfig === void 0 ? void 0 : _infinityScrollConfig.activePage,
20494
- (_infinityScrollConfig1 = infinityScrollConfig) === null || _infinityScrollConfig1 === void 0 ? void 0 : _infinityScrollConfig1.totalPages,
20495
- (_infinityScrollConfig2 = infinityScrollConfig) === null || _infinityScrollConfig2 === void 0 ? void 0 : _infinityScrollConfig2.onInfinityScroll
20596
+ infinityScrollConfig === null || infinityScrollConfig === void 0 ? void 0 : infinityScrollConfig.activePage,
20597
+ infinityScrollConfig === null || infinityScrollConfig === void 0 ? void 0 : infinityScrollConfig.totalPages,
20598
+ infinityScrollConfig === null || infinityScrollConfig === void 0 ? void 0 : infinityScrollConfig.onInfinityScroll
20496
20599
  ]);
20497
20600
  var tableRowClasses = React.useMemo(function() {
20498
20601
  return {
@@ -20536,25 +20639,23 @@
20536
20639
  children: /* @__PURE__ */ jsx("tr", {
20537
20640
  className: clsx(classes.row, classes.headerRow),
20538
20641
  children: (enabledColumns || Object.keys(content[0])).map(function(key, idx) {
20539
- var _config, _itemConfig, _itemConfig1, _itemConfig2, _itemConfig3, _itemConfig4, _itemConfig5;
20540
- var itemConfig = (_config = config) === null || _config === void 0 ? void 0 : _config[key];
20642
+ var itemConfig = config === null || config === void 0 ? void 0 : config[key];
20541
20643
  var _itemConfig_title;
20542
- var titleContent = (_itemConfig_title = (_itemConfig = itemConfig) === null || _itemConfig === void 0 ? void 0 : _itemConfig.title) !== null && _itemConfig_title !== void 0 ? _itemConfig_title : "";
20543
- if (((_itemConfig1 = itemConfig) === null || _itemConfig1 === void 0 ? void 0 : _itemConfig1.titleComponent) !== void 0) {
20544
- var _itemConfig6, _headerContent;
20545
- var TitleComponent = (_itemConfig6 = itemConfig) === null || _itemConfig6 === void 0 ? void 0 : _itemConfig6.titleComponent;
20644
+ var titleContent = (_itemConfig_title = itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.title) !== null && _itemConfig_title !== void 0 ? _itemConfig_title : "";
20645
+ if ((itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.titleComponent) !== void 0) {
20646
+ var TitleComponent = itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.titleComponent;
20546
20647
  titleContent = /* @__PURE__ */ jsx(TitleComponent, {
20547
- value: (_headerContent = headerContent) === null || _headerContent === void 0 ? void 0 : _headerContent[key]
20648
+ value: headerContent === null || headerContent === void 0 ? void 0 : headerContent[key]
20548
20649
  });
20549
20650
  }
20550
20651
  var _itemConfig_titleAlign;
20551
20652
  return /* @__PURE__ */ jsx("th", {
20552
20653
  className: clsx(classes.header, isFirstColumnSticky && idx === 0 && classes.headerSticky, isFirstColumnSticky && idx === 1 && classes.headerSecond),
20553
20654
  style: {
20554
- minWidth: (_itemConfig2 = itemConfig) === null || _itemConfig2 === void 0 ? void 0 : _itemConfig2.minWidth,
20555
- width: (_itemConfig3 = itemConfig) === null || _itemConfig3 === void 0 ? void 0 : _itemConfig3.width,
20556
- maxWidth: (_itemConfig4 = itemConfig) === null || _itemConfig4 === void 0 ? void 0 : _itemConfig4.maxWidth,
20557
- textAlign: (_itemConfig_titleAlign = (_itemConfig5 = itemConfig) === null || _itemConfig5 === void 0 ? void 0 : _itemConfig5.titleAlign) !== null && _itemConfig_titleAlign !== void 0 ? _itemConfig_titleAlign : "left"
20655
+ minWidth: itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.minWidth,
20656
+ width: itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.width,
20657
+ maxWidth: itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.maxWidth,
20658
+ textAlign: (_itemConfig_titleAlign = itemConfig === null || itemConfig === void 0 ? void 0 : itemConfig.titleAlign) !== null && _itemConfig_titleAlign !== void 0 ? _itemConfig_titleAlign : "left"
20558
20659
  },
20559
20660
  onClick: function() {
20560
20661
  return onHeadClick ? onHeadClick(key) : void 0;
@@ -20566,18 +20667,17 @@
20566
20667
  }),
20567
20668
  /* @__PURE__ */ jsxs("tbody", {
20568
20669
  children: [
20569
- content.length === 0 && nothingFoundContent !== void 0 && !((_infinityScrollConfig3 = infinityScrollConfig) === null || _infinityScrollConfig3 === void 0 ? void 0 : _infinityScrollConfig3.isLoading) && (((_infinityScrollConfig4 = infinityScrollConfig) === null || _infinityScrollConfig4 === void 0 ? void 0 : _infinityScrollConfig4.isLastPage) === void 0 || infinityScrollConfig.isLastPage) && /* @__PURE__ */ jsx("tr", {
20670
+ content.length === 0 && nothingFoundContent !== void 0 && !(infinityScrollConfig === null || infinityScrollConfig === void 0 ? void 0 : infinityScrollConfig.isLoading) && ((infinityScrollConfig === null || infinityScrollConfig === void 0 ? void 0 : infinityScrollConfig.isLastPage) === void 0 || infinityScrollConfig.isLastPage) && /* @__PURE__ */ jsx("tr", {
20570
20671
  children: /* @__PURE__ */ jsx("td", {
20571
20672
  colSpan: (enabledColumns || Object.keys(content[0])).length,
20572
20673
  children: nothingFoundContent
20573
20674
  })
20574
20675
  }),
20575
20676
  content.map(function(item, idx) {
20576
- var _activeRows;
20577
- return /* @__PURE__ */ jsx(TableRow$1, {
20677
+ return jsx(TableRow$1, {
20578
20678
  item,
20579
20679
  uniqueField,
20580
- isActive: (_activeRows_includes = (_activeRows = activeRows) === null || _activeRows === void 0 ? void 0 : _activeRows.includes(idx)) !== null && _activeRows_includes !== void 0 ? _activeRows_includes : false,
20680
+ isActive: (_activeRows_includes = activeRows === null || activeRows === void 0 ? void 0 : activeRows.includes(idx)) !== null && _activeRows_includes !== void 0 ? _activeRows_includes : false,
20581
20681
  isFirstColumnSticky,
20582
20682
  onRowClick,
20583
20683
  onRowHover,
@@ -21353,7 +21453,8 @@
21353
21453
  top: "100%",
21354
21454
  right: 0,
21355
21455
  marginTop: 6
21356
- }
21456
+ },
21457
+ tweakList: {}
21357
21458
  };
21358
21459
  function _array_like_to_array$6(arr, len) {
21359
21460
  if (len == null || len > arr.length)
@@ -21466,43 +21567,37 @@
21466
21567
  return _array_like_to_array$6(o, minLen);
21467
21568
  }
21468
21569
  var MoreMenu = function(param) {
21469
- var items = param.items, isDisabled = param.isDisabled, data = param.data, tweakStyles = param.tweakStyles, onMenuOpen = param.onMenuOpen, onMenuClose = param.onMenuClose, _param_hasDefaultStateBackground = param.hasDefaultStateBackground, hasDefaultStateBackground = _param_hasDefaultStateBackground === void 0 ? true : _param_hasDefaultStateBackground, testId = param.testId;
21470
- var classes = useTheme("MoreMenu", styles$c, tweakStyles).classes;
21570
+ var items = param.items, isDisabled = param.isDisabled, _param_hasDefaultStateBackground = param.hasDefaultStateBackground, hasDefaultStateBackground = _param_hasDefaultStateBackground === void 0 ? true : _param_hasDefaultStateBackground, data = param.data, testId = param.testId, tweakStyles = param.tweakStyles, onMenuOpen = param.onMenuOpen, onMenuClose = param.onMenuClose;
21571
+ var _useTheme = useTheme("MoreMenu", styles$c, tweakStyles), classes = _useTheme.classes, componentStyles = _useTheme.componentStyles;
21572
+ var tweakListStyles = useTweakStyles(componentStyles, tweakStyles, "tweakList");
21471
21573
  var _useState = _sliced_to_array$6(React.useState(false), 2), isMenuShown = _useState[0], setIsMenuShown = _useState[1];
21472
21574
  var list = React.useRef(null);
21473
21575
  var button = React.useRef(null);
21576
+ var isButtonDisabled = isDisabled || items.length === 0;
21474
21577
  var toggleMenu = function(event) {
21475
21578
  var isShown = !isMenuShown;
21476
21579
  event.stopPropagation();
21477
21580
  setIsMenuShown(isShown);
21478
21581
  if (isShown) {
21479
- if (onMenuOpen !== void 0) {
21480
- onMenuOpen();
21481
- }
21582
+ onMenuOpen === null || onMenuOpen === void 0 ? void 0 : onMenuOpen();
21482
21583
  } else {
21483
- if (onMenuClose !== void 0) {
21484
- onMenuClose();
21485
- }
21584
+ onMenuClose === null || onMenuClose === void 0 ? void 0 : onMenuClose();
21486
21585
  }
21487
21586
  };
21488
21587
  var handleCloseMenu = function() {
21489
21588
  setIsMenuShown(false);
21490
- if (onMenuClose !== void 0) {
21491
- onMenuClose();
21492
- }
21589
+ onMenuClose === null || onMenuClose === void 0 ? void 0 : onMenuClose();
21493
21590
  };
21494
21591
  useOnClickOutsideWithRef(list, handleCloseMenu, button);
21495
- var isButtonDisabled = isDisabled || items.length === 0;
21496
21592
  var _obj;
21497
21593
  return /* @__PURE__ */ jsxs("div", {
21498
21594
  className: classes.root,
21499
21595
  children: [
21500
21596
  /* @__PURE__ */ jsx("button", _object_spread_props$9(_object_spread$b({
21501
- className: clsx(classes.button, (_obj = {}, _define_property$c(_obj, classes.hasCircle, hasDefaultStateBackground), _define_property$c(_obj, classes.disabled, isButtonDisabled), _define_property$c(_obj, classes.active, isMenuShown), _obj)),
21502
- onClick: !isButtonDisabled ? toggleMenu : void 0,
21503
21597
  ref: button,
21504
- "data-testid": testId
21505
- }, addDataAttributes(data)), {
21598
+ className: clsx(classes.button, (_obj = {}, _define_property$c(_obj, classes.hasCircle, hasDefaultStateBackground), _define_property$c(_obj, classes.disabled, isButtonDisabled), _define_property$c(_obj, classes.active, isMenuShown), _obj))
21599
+ }, addDataTestId(testId), addDataAttributes(data)), {
21600
+ onClick: !isButtonDisabled ? toggleMenu : void 0,
21506
21601
  children: /* @__PURE__ */ jsx("div", {
21507
21602
  className: classes.icon,
21508
21603
  children: /* @__PURE__ */ jsx(Icon, {
@@ -21515,8 +21610,9 @@
21515
21610
  ref: list,
21516
21611
  children: /* @__PURE__ */ jsx(List, {
21517
21612
  items,
21518
- onClick: handleCloseMenu,
21519
- testId: testId !== void 0 ? "".concat(testId, "-list") : void 0
21613
+ testId: getTestId(testId, "list"),
21614
+ tweakStyles: tweakListStyles,
21615
+ onClick: handleCloseMenu
21520
21616
  })
21521
21617
  })
21522
21618
  ]
@@ -21590,9 +21686,8 @@
21590
21686
  };
21591
21687
  function MultiSelectInput(param) {
21592
21688
  var v = param.value, isOpen = param.isOpen, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, _param_placeholder = param.placeholder, placeholder = _param_placeholder === void 0 ? "" : _param_placeholder, onToggle = param.onToggle;
21593
- var _v;
21594
21689
  var classes = useTheme("MultiSelectInput", styles$b).classes;
21595
- var value = (_v = v) === null || _v === void 0 ? void 0 : _v.include;
21690
+ var value = v === null || v === void 0 ? void 0 : v.include;
21596
21691
  return /* @__PURE__ */ jsxs("div", {
21597
21692
  className: classes.root,
21598
21693
  onClick: function() {
@@ -22157,7 +22252,6 @@
22157
22252
  value
22158
22253
  ]);
22159
22254
  var handleChange = function(str, event) {
22160
- var _event;
22161
22255
  var mappedValue = str.split("").map(function(symbol) {
22162
22256
  return regex.test(symbol) ? symbol : transformCaseSensitive(smartType, smartType !== "email" ? CharactersMap : _object_spread_props$7(_object_spread$9({}, CharactersMap), {
22163
22257
  '"': "@"
@@ -22165,7 +22259,7 @@
22165
22259
  }).filter(function(symbol) {
22166
22260
  return regex.test(symbol);
22167
22261
  }).join("");
22168
- var domElement = (_event = event) === null || _event === void 0 ? void 0 : _event.currentTarget;
22262
+ var domElement = event === null || event === void 0 ? void 0 : event.currentTarget;
22169
22263
  if (domElement) {
22170
22264
  if (!input) {
22171
22265
  setInput(domElement);
@@ -22180,7 +22274,6 @@
22180
22274
  }
22181
22275
  };
22182
22276
  var handlePaste = function(event) {
22183
- var _currentValue, _currentValue1;
22184
22277
  var str = event.clipboardData.getData("text/plain").split("").join("");
22185
22278
  var domElement = event.currentTarget;
22186
22279
  if (!input) {
@@ -22201,7 +22294,7 @@
22201
22294
  var validMappedValueLength = mappedValue.length - (newValueLength - maxLength);
22202
22295
  mappedValue = mappedValue.substring(0, validMappedValueLength);
22203
22296
  }
22204
- var newValue = getUpperCaseIfNeeded("".concat((_currentValue = currentValue) === null || _currentValue === void 0 ? void 0 : _currentValue.substring(0, selectionStart)).concat(mappedValue).concat((_currentValue1 = currentValue) === null || _currentValue1 === void 0 ? void 0 : _currentValue1.substring(selectionEnd)));
22297
+ var newValue = getUpperCaseIfNeeded("".concat(currentValue === null || currentValue === void 0 ? void 0 : currentValue.substring(0, selectionStart)).concat(mappedValue).concat(currentValue === null || currentValue === void 0 ? void 0 : currentValue.substring(selectionEnd)));
22205
22298
  setCaretPosition2(selectionStart + mappedValue.length);
22206
22299
  setCurrentValue(newValue);
22207
22300
  onChange(newValue);
@@ -25359,8 +25452,7 @@
25359
25452
  var phoneWithCode = getFullPhone(value);
25360
25453
  var _value_countryCode;
25361
25454
  var countryCode = React.useMemo(function() {
25362
- var _value;
25363
- return (_value_countryCode = (_value = value) === null || _value === void 0 ? void 0 : _value.countryCode) !== null && _value_countryCode !== void 0 ? _value_countryCode : getCountryCodeFromPhone(phoneWithCode);
25455
+ return (_value_countryCode = value === null || value === void 0 ? void 0 : value.countryCode) !== null && _value_countryCode !== void 0 ? _value_countryCode : getCountryCodeFromPhone(phoneWithCode);
25364
25456
  }, [
25365
25457
  value.dialCode,
25366
25458
  value.phoneNumber
@@ -25390,7 +25482,6 @@
25390
25482
  }
25391
25483
  };
25392
25484
  var handleSelect = function(newPhoneInfo, event) {
25393
- var _inputRef;
25394
25485
  if (newPhoneInfo.countryCode !== countryCode) {
25395
25486
  onChange({
25396
25487
  phoneNumber: "",
@@ -25399,7 +25490,7 @@
25399
25490
  }, event);
25400
25491
  }
25401
25492
  handleClose();
25402
- var input = (_inputRef = inputRef) === null || _inputRef === void 0 ? void 0 : _inputRef.current;
25493
+ var input = inputRef === null || inputRef === void 0 ? void 0 : inputRef.current;
25403
25494
  if (input !== null) {
25404
25495
  input.focus();
25405
25496
  }
@@ -25407,15 +25498,13 @@
25407
25498
  var handleFocus = function(event) {
25408
25499
  setFocused(true);
25409
25500
  if (inputProps.onFocus !== void 0) {
25410
- var _inputProps;
25411
- (_inputProps = inputProps) === null || _inputProps === void 0 ? void 0 : _inputProps.onFocus(event);
25501
+ inputProps === null || inputProps === void 0 ? void 0 : inputProps.onFocus(event);
25412
25502
  }
25413
25503
  };
25414
25504
  var handleBlur = function(event) {
25415
25505
  setFocused(false);
25416
25506
  if (inputProps.onBlur !== void 0) {
25417
- var _inputProps;
25418
- (_inputProps = inputProps) === null || _inputProps === void 0 ? void 0 : _inputProps.onBlur(event);
25507
+ inputProps === null || inputProps === void 0 ? void 0 : inputProps.onBlur(event);
25419
25508
  }
25420
25509
  };
25421
25510
  useOnClickOutsideWithRef(list, handleClose, inputWrapper);
@@ -26670,7 +26759,7 @@
26670
26759
  }
26671
26760
  return target;
26672
26761
  }
26673
- function _ts_generator(thisArg, body) {
26762
+ var __generator = globalThis && globalThis.__generator || function(thisArg, body) {
26674
26763
  var f, y, t, g, _ = {
26675
26764
  label: 0,
26676
26765
  sent: function() {
@@ -26771,7 +26860,7 @@
26771
26860
  done: true
26772
26861
  };
26773
26862
  }
26774
- }
26863
+ };
26775
26864
  var DEFAULT_TIMEOUT = 7 * 1e3;
26776
26865
  var Toaster = function(param) {
26777
26866
  var title = param.title, _param_type = param.type, type = _param_type === void 0 ? "error" : _param_type, text = param.text, _param_timeout = param.timeout, timeout = _param_timeout === void 0 ? DEFAULT_TIMEOUT : _param_timeout, data = param.data, tweakStyles = param.tweakStyles, _param_hasCloseButton = param.hasCloseButton, hasCloseButton = _param_hasCloseButton === void 0 ? false : _param_hasCloseButton, _param_shouldCloseOnClick = param.shouldCloseOnClick, shouldCloseOnClick = _param_shouldCloseOnClick === void 0 ? false : _param_shouldCloseOnClick, children = param.children, onClose = param.onClose, onTimeEnd = param.onTimeEnd;
@@ -26783,7 +26872,7 @@
26783
26872
  }
26784
26873
  var disappear = function() {
26785
26874
  var _ref = _async_to_generator(function() {
26786
- return _ts_generator(this, function(_state) {
26875
+ return __generator(this, function(_state) {
26787
26876
  switch (_state.label) {
26788
26877
  case 0:
26789
26878
  return [