linear-react-components-ui 1.1.24-beta.0 → 1.1.24-beta.10

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 (265) hide show
  1. package/lib/BaseMask-0c14ef51.d.ts +24 -0
  2. package/lib/Cnpj-bde01dd0.d.ts +18 -0
  3. package/lib/Cpf-3fa496ad.d.ts +18 -0
  4. package/lib/Phone-2bb0b397.d.ts +18 -0
  5. package/lib/ZipCode-09460e18.d.ts +13 -0
  6. package/lib/alerts/AlertProvider.js +1 -2
  7. package/lib/alerts/BaseAlert.js +1 -1
  8. package/lib/alerts/Message.js +2 -3
  9. package/lib/alerts/withAlert.js +1 -2
  10. package/lib/assets/styles/calendar.scss +140 -35
  11. package/lib/assets/styles/datepicker2.scss +3 -9
  12. package/lib/assets/styles/file.scss +8 -0
  13. package/lib/assets/styles/filefield.scss +42 -0
  14. package/lib/assets/styles/numberfield.scss +18 -0
  15. package/lib/assets/styles/periodpicker.scss +1 -1
  16. package/lib/assets/styles/radiofield.scss +185 -0
  17. package/lib/assets/styles/selectfield.scss +1 -3
  18. package/lib/assets/styles/table.scss +6 -0
  19. package/lib/assets/styles/textfield.scss +61 -27
  20. package/lib/avatar/index.js +9 -11
  21. package/lib/badge/index.js +4 -4
  22. package/lib/buttons/Button.js +1 -2
  23. package/lib/buttons/DangerButton.js +1 -1
  24. package/lib/buttons/DefaultButton.js +22 -21
  25. package/lib/buttons/InfoButton.js +1 -1
  26. package/lib/buttons/PrimaryButton.js +1 -1
  27. package/lib/buttons/SuccessButton.js +1 -1
  28. package/lib/buttons/WarningButton.js +1 -1
  29. package/lib/buttons/button_container/index.js +1 -1
  30. package/lib/buttons/split_button/index.js +2 -2
  31. package/lib/calendar/base/helpers.js +2 -2
  32. package/lib/calendar/base/index.js +123 -44
  33. package/lib/checkbox/index.js +2 -3
  34. package/lib/dialog/Custom.js +2 -3
  35. package/lib/dialog/Question.js +5 -4
  36. package/lib/dialog/base/Content.js +5 -6
  37. package/lib/dialog/base/Header.js +3 -4
  38. package/lib/dialog/base/index.js +33 -23
  39. package/lib/dialog/form/index.js +52 -12
  40. package/lib/dialog/types.d.ts +4 -0
  41. package/lib/dialog/wizard/index.js +1 -2
  42. package/lib/dialog/wizard/progressbar.js +1 -1
  43. package/lib/dialog/wizard/step.js +1 -1
  44. package/lib/dialog/wizard/useWizard.js +1 -2
  45. package/lib/drawer/Content.js +1 -2
  46. package/lib/drawer/Drawer.js +6 -7
  47. package/lib/drawer/Header.js +2 -3
  48. package/lib/dropdown/Popup.js +7 -7
  49. package/lib/dropdown/helper.js +1 -1
  50. package/lib/dropdown/withDropdown.js +3 -4
  51. package/lib/fieldset/index.js +8 -9
  52. package/lib/form/Field.js +2 -3
  53. package/lib/form/FieldArray.js +2 -3
  54. package/lib/form/FieldNumber.js +4 -5
  55. package/lib/form/FieldPeriod.js +3 -4
  56. package/lib/form/index.js +3 -4
  57. package/lib/form/withFieldHOC.js +1 -2
  58. package/lib/form/withFormSecurity.js +1 -2
  59. package/lib/form2/helpers.js +1 -1
  60. package/lib/form2/index.d.ts +1 -1
  61. package/lib/form2/types.d.ts +7 -3
  62. package/lib/form2/useForm/index.js +22 -15
  63. package/lib/gridlayout/GridCol.js +5 -5
  64. package/lib/gridlayout/GridRow.js +1 -4
  65. package/lib/hint/index.js +1 -7
  66. package/lib/icons/helper.d.ts +16 -0
  67. package/lib/icons/helper.js +16 -0
  68. package/lib/icons/index.js +9 -9
  69. package/lib/index-208e7f62.d.ts +44 -0
  70. package/lib/index-3b70931d.d.ts +44 -0
  71. package/lib/index-442d51a2.d.ts +15 -0
  72. package/lib/index-4e511971.d.ts +26 -0
  73. package/lib/index-7dfa8924.d.ts +22 -0
  74. package/lib/index-9e576346.d.ts +23 -0
  75. package/lib/index-d3b6a19a.d.ts +41 -0
  76. package/lib/index-ecafc8c6.d.ts +30 -0
  77. package/lib/inputs/base/InputTextBase.js +9 -8
  78. package/lib/inputs/base/helpers.js +3 -7
  79. package/lib/inputs/base/types.d.ts +1 -1
  80. package/lib/inputs/color/index.js +2 -3
  81. package/lib/inputs/date/Dropdown.js +6 -4
  82. package/lib/inputs/date/index.js +34 -22
  83. package/lib/inputs/errorMessage/index.js +2 -3
  84. package/lib/inputs/file/DefaultFile.js +31 -31
  85. package/lib/inputs/file/DragDropFile.js +18 -17
  86. package/lib/inputs/file/File.js +6 -5
  87. package/lib/inputs/file/FileButtonSettings.js +0 -1
  88. package/lib/inputs/file/index.js +0 -1
  89. package/lib/inputs/inputHOC.js +1 -2
  90. package/lib/inputs/mask/BaseMask.js +1 -2
  91. package/lib/inputs/mask/Cnpj.js +1 -2
  92. package/lib/inputs/mask/Cpf.js +1 -2
  93. package/lib/inputs/multiSelect/ActionButtons.js +1 -2
  94. package/lib/inputs/multiSelect/Dropdown.js +11 -11
  95. package/lib/inputs/multiSelect/helper.js +2 -1
  96. package/lib/inputs/multiSelect/index.js +10 -9
  97. package/lib/inputs/number/BaseNumber.js +1 -1
  98. package/lib/inputs/number/index.js +3 -3
  99. package/lib/inputs/period/Dropdown.js +7 -4
  100. package/lib/inputs/period/PeriodList.js +3 -12
  101. package/lib/inputs/period/helper.js +1 -3
  102. package/lib/inputs/period/index.js +116 -113
  103. package/lib/inputs/period/types.d.ts +4 -1
  104. package/lib/inputs/search/index.js +8 -5
  105. package/lib/inputs/select/ActionButtons.js +1 -1
  106. package/lib/inputs/select/Dropdown.js +3 -4
  107. package/lib/inputs/select/helper.js +13 -10
  108. package/lib/inputs/select/multiple/Selecteds.js +2 -2
  109. package/lib/inputs/select/multiple/index.js +14 -11
  110. package/lib/inputs/select/simple/index.js +19 -13
  111. package/lib/inputs/textarea/index.js +1 -1
  112. package/lib/inputs/types.d.ts +1 -0
  113. package/lib/inputs2/checkboxfield/index.d.ts +1 -1
  114. package/lib/inputs2/checkboxfield/index.js +18 -15
  115. package/lib/inputs2/colorfield/index.d.ts +2 -2
  116. package/lib/inputs2/colorfield/index.js +5 -5
  117. package/lib/inputs2/date/base/constants.js +2 -1
  118. package/lib/inputs2/date/base/index.js +6 -8
  119. package/lib/inputs2/date/datefield/calendarbox.d.ts +1 -1
  120. package/lib/inputs2/date/datefield/calendarbox.js +3 -2
  121. package/lib/inputs2/date/datefield/context.d.ts +1 -0
  122. package/lib/inputs2/date/datefield/index.d.ts +1 -0
  123. package/lib/inputs2/date/datefield/index.js +44 -33
  124. package/lib/inputs2/date/datefield/triggers.js +1 -2
  125. package/lib/inputs2/date/datefield/types.d.ts +2 -0
  126. package/lib/inputs2/date/dateperiodfield/calendarbox.d.ts +1 -1
  127. package/lib/inputs2/date/dateperiodfield/calendarbox.js +8 -6
  128. package/lib/inputs2/date/dateperiodfield/context.d.ts +1 -0
  129. package/lib/inputs2/date/dateperiodfield/index.d.ts +1 -0
  130. package/lib/inputs2/date/dateperiodfield/index.js +66 -48
  131. package/lib/inputs2/date/dateperiodfield/triggers.js +19 -14
  132. package/lib/inputs2/date/dateperiodfield/types.d.ts +2 -0
  133. package/lib/inputs2/date/helpers.d.ts +1 -0
  134. package/lib/inputs2/date/types.d.ts +2 -1
  135. package/lib/inputs2/{number/Number.d.ts → filefield/index.d.ts} +2 -2
  136. package/lib/inputs2/filefield/index.js +174 -0
  137. package/lib/inputs2/index.d.ts +20 -14
  138. package/lib/inputs2/index.js +10 -11
  139. package/lib/inputs2/mask/BaseMask.d.ts +2 -2
  140. package/lib/inputs2/mask/BaseMask.js +7 -7
  141. package/lib/inputs2/mask/Cnpj.d.ts +3 -3
  142. package/lib/inputs2/mask/Cnpj.js +4 -5
  143. package/lib/inputs2/mask/Cpf.d.ts +3 -3
  144. package/lib/inputs2/mask/Cpf.js +4 -5
  145. package/lib/inputs2/mask/Phone.d.ts +3 -3
  146. package/lib/inputs2/mask/Phone.js +1 -2
  147. package/lib/inputs2/mask/ZipCode.d.ts +3 -3
  148. package/lib/inputs2/mask/ZipCode.js +1 -2
  149. package/lib/inputs2/numberfield/currency.d.ts +13 -0
  150. package/lib/inputs2/numberfield/currency.js +91 -0
  151. package/lib/inputs2/numberfield/decimal.d.ts +13 -0
  152. package/lib/inputs2/{number/BaseNumber.js → numberfield/decimal.js} +57 -58
  153. package/lib/inputs2/numberfield/helpers.d.ts +30 -0
  154. package/lib/inputs2/numberfield/helpers.js +53 -0
  155. package/lib/inputs2/numberfield/index.d.ts +12 -0
  156. package/lib/inputs2/numberfield/index.js +104 -0
  157. package/lib/inputs2/numberfield/types.d.ts +36 -0
  158. package/lib/inputs2/numberfield/types.js +5 -0
  159. package/lib/inputs2/{number/BaseNumber.d.ts → radiofield/index.d.ts} +4 -5
  160. package/lib/inputs2/radiofield/index.js +144 -0
  161. package/lib/inputs2/radiofield/types.d.ts +33 -0
  162. package/lib/inputs2/radiofield/types.js +5 -0
  163. package/lib/inputs2/selectfield/context.d.ts +1 -0
  164. package/lib/inputs2/selectfield/index.d.ts +2 -1
  165. package/lib/inputs2/selectfield/index.js +118 -58
  166. package/lib/inputs2/selectfield/item.d.ts +2 -1
  167. package/lib/inputs2/selectfield/item.js +8 -4
  168. package/lib/inputs2/selectfield/listbox.d.ts +1 -1
  169. package/lib/inputs2/selectfield/listbox.js +24 -10
  170. package/lib/inputs2/selectfield/options.d.ts +9 -0
  171. package/lib/inputs2/selectfield/options.js +26 -0
  172. package/lib/inputs2/selectfield/search.d.ts +1 -1
  173. package/lib/inputs2/selectfield/search.js +3 -4
  174. package/lib/inputs2/selectfield/selections.d.ts +1 -1
  175. package/lib/inputs2/selectfield/selections.js +3 -2
  176. package/lib/inputs2/selectfield/triggers.js +17 -8
  177. package/lib/inputs2/selectfield/types.d.ts +0 -1
  178. package/lib/inputs2/slot/index.d.ts +2 -2
  179. package/lib/inputs2/{number/Decimal.d.ts → textareafield/index.d.ts} +2 -5
  180. package/lib/inputs2/textareafield/index.js +194 -0
  181. package/lib/inputs2/textfield/index.d.ts +1 -1
  182. package/lib/inputs2/textfield/index.js +18 -17
  183. package/lib/labelMessages/index.js +4 -6
  184. package/lib/labels/DefaultLabel.js +2 -6
  185. package/lib/labels/label_container/index.js +1 -1
  186. package/lib/list/Header.js +1 -1
  187. package/lib/list/Item.js +10 -12
  188. package/lib/list/index.js +2 -4
  189. package/lib/menus/float/MenuItem.js +3 -4
  190. package/lib/menus/float/SubMenuContainer.js +2 -3
  191. package/lib/menus/float/index.js +1 -1
  192. package/lib/menus/sidenav/ExpandMenu.js +1 -1
  193. package/lib/menus/sidenav/MenuLink.js +1 -2
  194. package/lib/menus/sidenav/NavMenuGroup.js +2 -3
  195. package/lib/menus/sidenav/NavMenuItem.js +10 -9
  196. package/lib/menus/sidenav/NavSubMenuItem.js +2 -3
  197. package/lib/menus/sidenav/helpers.js +1 -1
  198. package/lib/menus/sidenav/index.js +6 -7
  199. package/lib/menus/sidenav/popup_menu_search/index.js +1 -2
  200. package/lib/panel/Content.js +9 -8
  201. package/lib/panel/Default.js +3 -4
  202. package/lib/panel/Header.js +4 -5
  203. package/lib/permissionValidations.js +1 -1
  204. package/lib/popover/PopoverText.js +1 -2
  205. package/lib/popover/index.js +2 -1
  206. package/lib/progress/Bar.js +6 -6
  207. package/lib/radio/index.js +3 -4
  208. package/lib/shortcuts/index.js +1 -1
  209. package/lib/skeleton/SkeletonContainer.js +1 -2
  210. package/lib/skeleton/index.js +1 -4
  211. package/lib/spinner/index.js +3 -4
  212. package/lib/split/Split.js +2 -3
  213. package/lib/split/SplitSide.js +4 -5
  214. package/lib/table/Body.js +4 -5
  215. package/lib/table/Header.js +9 -7
  216. package/lib/table/HeaderColumn.js +2 -3
  217. package/lib/table/Row.js +4 -5
  218. package/lib/table/RowColumn.js +2 -3
  219. package/lib/table/index.js +20 -16
  220. package/lib/table/types.d.ts +1 -0
  221. package/lib/tabs/DropdownTabs.js +2 -3
  222. package/lib/tabs/Menu.js +1 -1
  223. package/lib/tabs/MenuTabs.js +4 -9
  224. package/lib/tabs/Panel.js +8 -7
  225. package/lib/tabs/context.js +7 -5
  226. package/lib/tabs/index.js +1 -2
  227. package/lib/textContent/index.js +2 -3
  228. package/lib/toolbar/ButtonBar.js +2 -3
  229. package/lib/toolbar/LabelBar.js +1 -2
  230. package/lib/toolbar/index.js +1 -1
  231. package/lib/tooltip/TooltipContent.js +8 -9
  232. package/lib/tooltip/useTooltip.js +8 -8
  233. package/lib/treetable/Body.js +2 -3
  234. package/lib/treetable/Header.js +3 -4
  235. package/lib/treetable/Row.js +9 -10
  236. package/lib/treeview/Header.js +1 -1
  237. package/lib/treeview/Node.js +5 -6
  238. package/lib/treeview/index.js +5 -6
  239. package/lib/uitour/index.js +9 -8
  240. package/package.json +1 -1
  241. package/lib/BaseMask-3d5d581d.d.ts +0 -24
  242. package/lib/BaseNumber-797088d7.d.ts +0 -23
  243. package/lib/Cnpj-1602be21.d.ts +0 -18
  244. package/lib/Cpf-4d6b9079.d.ts +0 -18
  245. package/lib/Currency-b33d3a22.d.ts +0 -18
  246. package/lib/Decimal-55e836d5.d.ts +0 -13
  247. package/lib/Number-9c6aceff.d.ts +0 -20
  248. package/lib/Phone-79e5e3b4.d.ts +0 -18
  249. package/lib/ZipCode-8c2e9d8b.d.ts +0 -13
  250. package/lib/calendar/base/Day.d.ts +0 -8
  251. package/lib/calendar/base/Day.js +0 -36
  252. package/lib/calendar/base/Month.d.ts +0 -8
  253. package/lib/calendar/base/Month.js +0 -39
  254. package/lib/calendar/base/Week.d.ts +0 -8
  255. package/lib/calendar/base/Week.js +0 -35
  256. package/lib/index-18a64236.d.ts +0 -23
  257. package/lib/index-43ad8140.d.ts +0 -41
  258. package/lib/index-772f9f1a.d.ts +0 -44
  259. package/lib/index-8a59cf4b.d.ts +0 -23
  260. package/lib/inputs2/number/Currency.d.ts +0 -11
  261. package/lib/inputs2/number/Currency.js +0 -47
  262. package/lib/inputs2/number/Decimal.js +0 -36
  263. package/lib/inputs2/number/Number.js +0 -49
  264. package/lib/inputs2/number/format_number.d.ts +0 -5
  265. package/lib/inputs2/number/format_number.js +0 -29
@@ -1,5 +1,5 @@
1
1
  import { Moment } from 'moment';
2
- import { ReactNode, RefObject } from 'react';
2
+ import { ReactNode, RefObject, MouseEvent } from 'react';
3
3
  import { ColorStyles } from '../../@types/ColorStyles.js';
4
4
  import { Period } from '../../@types/Period.js';
5
5
  import { PermissionAttr } from '../../@types/PermissionAttr.js';
@@ -55,11 +55,14 @@ interface IPeriodPickerProps {
55
55
  calendarColorStyle?: ColorStyles;
56
56
  required?: boolean;
57
57
  onChange?: (event?: CustomInputEvent, maskValue?: string, date?: Period) => void;
58
+ onClick?: (event?: MouseEvent) => void;
58
59
  disabled?: boolean;
59
60
  permissionAttr?: PermissionAttr;
60
61
  errorMessages?: string[];
61
62
  name?: string;
62
63
  hint?: string;
64
+ nameDateInitial?: string;
65
+ nameDateFinal?: string;
63
66
  hintPosition?: 'below' | 'onLabelRight';
64
67
  onBlur?: (e: CustomInputEvent) => void;
65
68
  onFocus?: (e: CustomInputEvent) => void;
@@ -12,8 +12,7 @@ require("../../assets/styles/search.scss");
12
12
  var _drawer = _interopRequireWildcard(require("../../drawer"));
13
13
  const _excluded = ["headerTitle", "content", "onStateChange"];
14
14
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
15
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
16
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
15
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
17
16
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
18
17
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
19
18
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
@@ -26,9 +25,10 @@ const SearchField = props => {
26
25
  const {
27
26
  resetButton = true,
28
27
  advancedFilterProps = {},
29
- value
28
+ value,
29
+ drawerFilterIsOpened = false
30
30
  } = props;
31
- const [advancedFilterOpened, setAdvancedFilterOpened] = (0, _react.useState)(false);
31
+ const [advancedFilterOpened, setAdvancedFilterOpened] = (0, _react.useState)(drawerFilterIsOpened);
32
32
  const [valorCampo, setValorCampo] = (0, _react.useState)('');
33
33
  const [onDenied, setOnDenied] = (0, _react.useState)();
34
34
  const {
@@ -49,7 +49,7 @@ const SearchField = props => {
49
49
  };
50
50
  const shouldDisable = () => props.disabled || onDenied && (onDenied.disabled || onDenied.hideContent);
51
51
  const shouldBeReadOnly = () => props.readOnly || onDenied && onDenied.readOnly;
52
- const hideContent = onDenied?.hideContent;
52
+ const hideContent = onDenied === null || onDenied === void 0 ? void 0 : onDenied.hideContent;
53
53
  const buttonProps = () => {
54
54
  const disableCallbacks = shouldBeReadOnly() || shouldDisable() || hideContent;
55
55
  let propsButton = {
@@ -107,6 +107,9 @@ const SearchField = props => {
107
107
  setValorCampo(value);
108
108
  }
109
109
  }, [value]);
110
+ (0, _react.useEffect)(() => {
111
+ setAdvancedFilterOpened(drawerFilterIsOpened);
112
+ }, [drawerFilterIsOpened]);
110
113
  if (onDenied && onDenied.unvisible) {
111
114
  return null;
112
115
  }
@@ -17,7 +17,7 @@ const ActionButtons = props => {
17
17
  customClassForSideButtons
18
18
  } = props;
19
19
  return /*#__PURE__*/_react.default.createElement("div", {
20
- className: `actionbuttonsselect ${customClassForSideButtons}`
20
+ className: "actionbuttonsselect ".concat(customClassForSideButtons)
21
21
  }, showClearButton && /*#__PURE__*/_react.default.createElement("button", {
22
22
  disabled: disabled,
23
23
  tabIndex: -1,
@@ -10,8 +10,7 @@ var _avatar = _interopRequireDefault(require("../../avatar"));
10
10
  var helper = _interopRequireWildcard(require("./helper"));
11
11
  var _Popup = _interopRequireDefault(require("../../dropdown/Popup"));
12
12
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
13
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
14
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
13
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
15
14
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
16
15
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
17
16
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
@@ -50,7 +49,7 @@ const Dropdown = props => {
50
49
  align: "left",
51
50
  leftPosition: dropdownDynamicStyles.left,
52
51
  topPosition: dropdownDynamicStyles.top,
53
- targetRef: selectFieldRef?.current
52
+ targetRef: selectFieldRef === null || selectFieldRef === void 0 ? void 0 : selectFieldRef.current
54
53
  }, /*#__PURE__*/_react.default.createElement("div", {
55
54
  className: "select-dropdown",
56
55
  ref: dropdownRef,
@@ -82,7 +81,7 @@ const Dropdown = props => {
82
81
  const disabled = currents && currents.length > 0 ? currents.some(s => s[idKey] === item[idKey]) : false;
83
82
  const itemSelected = Boolean(selected && selected[idKey] === item[idKey]);
84
83
  return /*#__PURE__*/_react.default.createElement("div", {
85
- key: `dropdowmIten ${item[idKey]}}`,
84
+ key: "dropdowmIten ".concat(item[idKey], "}"),
86
85
  className: helper.getDropdownItemCssClass(itemSelected, disabled, striped)
87
86
  }, /*#__PURE__*/_react.default.createElement("button", {
88
87
  className: "menubutton",
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.returnDropdownDynamicStyles = exports.getFilteredSimpleDataCombo = exports.getFilteredMultipleDataCombo = exports.getDropdownItemCssClass = exports.contentClass = void 0;
7
- const contentClass = props => `content ${props.showClearButton ? '' : 'noclear'}`;
7
+ const contentClass = props => "content ".concat(props.showClearButton ? '' : 'noclear');
8
8
  exports.contentClass = contentClass;
9
9
  const getDropdownItemCssClass = (selected, disabled, striped) => {
10
10
  let className = 'item';
@@ -21,10 +21,12 @@ const getFilteredSimpleDataCombo = _ref => {
21
21
  inputText
22
22
  } = _ref;
23
23
  return dataSource && dataSource.filter(item => {
24
+ var _descriptionKey;
24
25
  if (typeof descriptionKey === 'string') {
25
- return item[descriptionKey]?.toLowerCase().indexOf(inputText?.toString().toLowerCase()) > -1;
26
+ var _item$descriptionKey;
27
+ return ((_item$descriptionKey = item[descriptionKey]) === null || _item$descriptionKey === void 0 ? void 0 : _item$descriptionKey.toLowerCase().indexOf(inputText === null || inputText === void 0 ? void 0 : inputText.toString().toLowerCase())) > -1;
26
28
  }
27
- return descriptionKey(item)?.toLowerCase().indexOf(inputText?.toString().toLowerCase()) > -1;
29
+ return ((_descriptionKey = descriptionKey(item)) === null || _descriptionKey === void 0 ? void 0 : _descriptionKey.toLowerCase().indexOf(inputText === null || inputText === void 0 ? void 0 : inputText.toString().toLowerCase())) > -1;
28
30
  });
29
31
  };
30
32
  exports.getFilteredSimpleDataCombo = getFilteredSimpleDataCombo;
@@ -36,10 +38,11 @@ const getFilteredMultipleDataCombo = _ref2 => {
36
38
  currents
37
39
  } = _ref2;
38
40
  return dataSource.filter(item => {
41
+ var _descriptionKey2;
39
42
  if (typeof descriptionKey === 'string') {
40
- return item[descriptionKey].toLowerCase().indexOf(inputText?.toString().toLowerCase()) > -1 && !currents.includes(item);
43
+ return item[descriptionKey].toLowerCase().indexOf(inputText === null || inputText === void 0 ? void 0 : inputText.toString().toLowerCase()) > -1 && !currents.includes(item);
41
44
  }
42
- return descriptionKey(item)?.toLowerCase().indexOf(inputText?.toString().toLowerCase()) > -1 && !currents.includes(item);
45
+ return ((_descriptionKey2 = descriptionKey(item)) === null || _descriptionKey2 === void 0 ? void 0 : _descriptionKey2.toLowerCase().indexOf(inputText === null || inputText === void 0 ? void 0 : inputText.toString().toLowerCase())) > -1 && !currents.includes(item);
43
46
  });
44
47
  };
45
48
  exports.getFilteredMultipleDataCombo = getFilteredMultipleDataCombo;
@@ -51,7 +54,7 @@ const returnDropdownPosition = function (_ref3) {
51
54
  } = _ref3;
52
55
  let aboveDropdown = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
53
56
  const DEFAULT_MARGIN_BOTTOM = 10;
54
- if (aboveDropdown && dropdownRef?.current && dropdownRects?.height) {
57
+ if (aboveDropdown && dropdownRef !== null && dropdownRef !== void 0 && dropdownRef.current && dropdownRects !== null && dropdownRects !== void 0 && dropdownRects.height) {
55
58
  return selectFieldRects.top + window.scrollY - (dropdownRef.current && dropdownRects.height) - DEFAULT_MARGIN_BOTTOM;
56
59
  }
57
60
  return selectFieldRects.top + window.scrollY + selectFieldRects.height;
@@ -62,10 +65,10 @@ const returnDropdownDynamicStyles = _ref4 => {
62
65
  dropdownMaxHeight,
63
66
  dropdownRef
64
67
  } = _ref4;
65
- const selectFieldRects = selectFieldRef?.current ? selectFieldRef.current.getBoundingClientRect() : undefined;
66
- const dropdownRects = dropdownRef?.current ? dropdownRef.current.getBoundingClientRect() : undefined;
67
- const selectFieldRectsBottom = selectFieldRects ? selectFieldRects?.bottom : 0;
68
- const selectFieldRectsTop = selectFieldRects ? selectFieldRects?.top : 0;
68
+ const selectFieldRects = selectFieldRef !== null && selectFieldRef !== void 0 && selectFieldRef.current ? selectFieldRef.current.getBoundingClientRect() : undefined;
69
+ const dropdownRects = dropdownRef !== null && dropdownRef !== void 0 && dropdownRef.current ? dropdownRef.current.getBoundingClientRect() : undefined;
70
+ const selectFieldRectsBottom = selectFieldRects ? selectFieldRects === null || selectFieldRects === void 0 ? void 0 : selectFieldRects.bottom : 0;
71
+ const selectFieldRectsTop = selectFieldRects ? selectFieldRects === null || selectFieldRects === void 0 ? void 0 : selectFieldRects.top : 0;
69
72
  const dropdownBottomDistance = window.innerHeight - selectFieldRectsBottom;
70
73
  const bottomOffset = 30;
71
74
  let maxDropdownBottomDistance = 200;
@@ -15,8 +15,8 @@ const Selecteds = _ref => {
15
15
  handlerOnUnselect
16
16
  } = _ref;
17
17
  return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, currents.map(selected => /*#__PURE__*/_react.default.createElement("div", {
18
- className: `selecteditem ${disabled ? '-disabled' : ''}`,
19
- key: `selected-${selected[idKey]}`
18
+ className: "selecteditem ".concat(disabled ? '-disabled' : ''),
19
+ key: "selected-".concat(selected[idKey])
20
20
  }, typeof descriptionKey === 'string' ? selected[descriptionKey] : descriptionKey(selected), /*#__PURE__*/_react.default.createElement("button", {
21
21
  disabled: disabled,
22
22
  className: "close",
@@ -15,8 +15,7 @@ var _InputTextBase = _interopRequireDefault(require("../../base/InputTextBase"))
15
15
  var _helper = require("../helper");
16
16
  var _hint = _interopRequireDefault(require("../../../hint"));
17
17
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
18
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
19
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
18
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
20
19
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
21
20
  const MultipleSelect = props => {
22
21
  const {
@@ -45,7 +44,7 @@ const MultipleSelect = props => {
45
44
  const [insideComponent, setInsideComponent] = (0, _react.useState)(false);
46
45
  const [onDenied, setOnDeniedSelect] = (0, _react.useState)();
47
46
  const [valueFromProps, setValueFromProps] = (0, _react.useState)([]);
48
- const componentId = `select-component${uuid.v1()}`;
47
+ const componentId = "select-component".concat(uuid.v1());
49
48
  const componentRef = (0, _react.useRef)(null);
50
49
  const dropdownRef = (0, _react.useRef)(null);
51
50
  const selectWrapper = (0, _react.useRef)();
@@ -65,10 +64,11 @@ const MultipleSelect = props => {
65
64
  }
66
65
  };
67
66
  const onMouseMove = event => {
67
+ var _dropdownRef$current, _dropdownRef$current$;
68
68
  const target = event.target;
69
- const idDropdown = dropdownRef.current?.parentElement?.id || '';
69
+ const idDropdown = ((_dropdownRef$current = dropdownRef.current) === null || _dropdownRef$current === void 0 ? void 0 : (_dropdownRef$current$ = _dropdownRef$current.parentElement) === null || _dropdownRef$current$ === void 0 ? void 0 : _dropdownRef$current$.id) || '';
70
70
  const dropdownElement = document.getElementById(idDropdown);
71
- const keepDropdownOpen = Boolean(dropdownElement?.contains(target));
71
+ const keepDropdownOpen = Boolean(dropdownElement === null || dropdownElement === void 0 ? void 0 : dropdownElement.contains(target));
72
72
  setInsideComponent(keepDropdownOpen);
73
73
  };
74
74
  const onClearClick = () => {
@@ -105,6 +105,7 @@ const MultipleSelect = props => {
105
105
  setDropdownWidth(dropdownWidthFocus);
106
106
  };
107
107
  const onSelect = select => {
108
+ var _dropdownRef$current2;
108
109
  if (select === null) return;
109
110
  const currentsSelect = [...currents, select];
110
111
  setCurrents(currentsSelect);
@@ -112,16 +113,17 @@ const MultipleSelect = props => {
112
113
  setInputValue([]);
113
114
  if (inputTextRef && inputTextRef.current) inputTextRef.current.focus();
114
115
  if (props.onSelect) setSelected(props.onSelect(currentsSelect.map(i => i[idKey])));
115
- dropdownRef.current?.focus();
116
+ (_dropdownRef$current2 = dropdownRef.current) === null || _dropdownRef$current2 === void 0 ? void 0 : _dropdownRef$current2.focus();
116
117
  };
117
118
  const onUnselect = id => {
118
119
  if (currents) {
120
+ var _dropdownRef$current3;
119
121
  const result = currents.filter(item => item[idKey] !== id);
120
122
  setCurrents(result);
121
123
  if (inputTextRef && inputTextRef.current) inputTextRef.current.focus();
122
124
  setOpened(false);
123
125
  if (props.onSelect) setSelected(props.onSelect(result.map(i => i[idKey])));
124
- dropdownRef.current?.focus();
126
+ (_dropdownRef$current3 = dropdownRef.current) === null || _dropdownRef$current3 === void 0 ? void 0 : _dropdownRef$current3.focus();
125
127
  }
126
128
  };
127
129
  const onOpenClose = () => {
@@ -141,7 +143,8 @@ const MultipleSelect = props => {
141
143
  const onInputKeyDown = e => {
142
144
  if (e.keyCode) {
143
145
  if ((e.keyCode === constants.keyCodes.ENTER || e.key === constants.keys.TAB) && selected && opened) {
144
- if (e.keyCode === constants.keyCodes.ENTER) e.preventDefault?.();
146
+ var _e$preventDefault;
147
+ if (e.keyCode === constants.keyCodes.ENTER) (_e$preventDefault = e.preventDefault) === null || _e$preventDefault === void 0 ? void 0 : _e$preventDefault.call(e);
145
148
  if (!currents.some(current => current[idKey] === selected[idKey])) {
146
149
  onSelect(selected);
147
150
  }
@@ -188,7 +191,7 @@ const MultipleSelect = props => {
188
191
  }, []);
189
192
  (0, _react.useEffect)(() => {
190
193
  if (props.gridLayout) {
191
- const gridEl = document.querySelector(`#${componentId}>.-withinput.grid-container`);
194
+ const gridEl = document.querySelector("#".concat(componentId, ">.-withinput.grid-container"));
192
195
  if (gridElRef.current !== gridEl && gridEl) gridElRef.current = gridEl;
193
196
  }
194
197
  }, []);
@@ -241,8 +244,8 @@ const MultipleSelect = props => {
241
244
  onClick: onFocus,
242
245
  onKeyDown: onInputKeyDown,
243
246
  customClassForLabel: customClassForLabel,
244
- customClassForWrapper: `selectwrapper ${(props.readOnly || shouldDisable() || shouldBeReadOnly()) && ' -undigitable'} ${customClassForWrapper}`,
245
- customClassForInputContent: `multiselect ${customClassForInputContent}`,
247
+ customClassForWrapper: "selectwrapper ".concat((props.readOnly || shouldDisable() || shouldBeReadOnly()) && ' -undigitable', " ").concat(customClassForWrapper),
248
+ customClassForInputContent: "multiselect ".concat(customClassForInputContent),
246
249
  inputBaseRef: r => {
247
250
  selectWrapper.current = r;
248
251
  },
@@ -13,8 +13,7 @@ var constants = _interopRequireWildcard(require("../../../internals/constants"))
13
13
  var _helper = require("../helper");
14
14
  var _InputTextBase = _interopRequireDefault(require("../../base/InputTextBase"));
15
15
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
16
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
17
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
16
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
18
17
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
19
18
  const SimpleSelect = props => {
20
19
  const {
@@ -55,7 +54,7 @@ const SimpleSelect = props => {
55
54
  const [onDenied, setOnDeniedSelect] = (0, _react.useState)();
56
55
  const [isTyping, setIsTyping] = (0, _react.useState)(false);
57
56
  const dropdownRef = (0, _react.useRef)(null);
58
- const componentId = `select-component-${name}-${uuid.v1()}`;
57
+ const componentId = "select-component-".concat(name, "-").concat(uuid.v1());
59
58
  const componentRef = (0, _react.useRef)(null);
60
59
  const selectWrapper = (0, _react.useRef)();
61
60
  const gridElement = (0, _react.useRef)();
@@ -64,18 +63,20 @@ const SimpleSelect = props => {
64
63
  if (selectWrapper.current) setDropdownWidth(selectWrapper.current.clientWidth);
65
64
  };
66
65
  const onClickOutside = event => {
66
+ var _selectWrapper$curren, _dropdownRef$current;
67
67
  const {
68
68
  target
69
69
  } = event;
70
- if (target !== selectWrapper.current && !selectWrapper.current?.contains(target) && !dropdownRef.current?.contains(target)) {
70
+ if (target !== selectWrapper.current && !((_selectWrapper$curren = selectWrapper.current) !== null && _selectWrapper$curren !== void 0 && _selectWrapper$curren.contains(target)) && !((_dropdownRef$current = dropdownRef.current) !== null && _dropdownRef$current !== void 0 && _dropdownRef$current.contains(target))) {
71
71
  setOpened(false);
72
72
  }
73
73
  };
74
74
  const onMouseMove = event => {
75
+ var _dropdownRef$current2, _dropdownRef$current3;
75
76
  const target = event.target;
76
- const idDropdown = dropdownRef.current?.parentElement?.id || '';
77
+ const idDropdown = ((_dropdownRef$current2 = dropdownRef.current) === null || _dropdownRef$current2 === void 0 ? void 0 : (_dropdownRef$current3 = _dropdownRef$current2.parentElement) === null || _dropdownRef$current3 === void 0 ? void 0 : _dropdownRef$current3.id) || '';
77
78
  const dropdownElement = document.getElementById(idDropdown);
78
- const keepDropdownOpen = Boolean(dropdownElement?.contains(target));
79
+ const keepDropdownOpen = Boolean(dropdownElement === null || dropdownElement === void 0 ? void 0 : dropdownElement.contains(target));
79
80
  setInsideComponent(keepDropdownOpen);
80
81
  };
81
82
  const getSelectEvent = selectedEvent => ({
@@ -115,6 +116,7 @@ const SimpleSelect = props => {
115
116
  }
116
117
  };
117
118
  const onSelect = selectedDropdown => {
119
+ var _dropdownRef$current4;
118
120
  if (!selectedDropdown) return;
119
121
  setSelected(selectedDropdown);
120
122
  if (descriptionKeyIsString) setInputText(selectedDropdown[descriptionKey]);else setInputText(descriptionKey(selectedDropdown));
@@ -124,7 +126,7 @@ const SimpleSelect = props => {
124
126
  if (inputTextRef && inputTextRef.current) inputTextRef.current.focus();
125
127
  setOpened(false);
126
128
  });
127
- dropdownRef.current?.focus();
129
+ (_dropdownRef$current4 = dropdownRef.current) === null || _dropdownRef$current4 === void 0 ? void 0 : _dropdownRef$current4.focus();
128
130
  };
129
131
  const onOpenClose = () => {
130
132
  setOpened(prevState => !prevState);
@@ -160,7 +162,8 @@ const SimpleSelect = props => {
160
162
  const onInputKeyDown = e => {
161
163
  if (e.keyCode) {
162
164
  if ((e.keyCode === constants.keyCodes.ENTER || e.key === constants.keys.TAB) && selected && opened) {
163
- if (e.keyCode === constants.keyCodes.ENTER) e.preventDefault?.();
165
+ var _e$preventDefault;
166
+ if (e.keyCode === constants.keyCodes.ENTER) (_e$preventDefault = e.preventDefault) === null || _e$preventDefault === void 0 ? void 0 : _e$preventDefault.call(e);
164
167
  onSelect(selected);
165
168
  } else if ([constants.keyCodes.ARROW_UP, constants.keyCodes.ARROW_DOWN].includes(e.keyCode)) {
166
169
  if (!opened) setOpened(true);
@@ -168,7 +171,7 @@ const SimpleSelect = props => {
168
171
  if (e.keyCode === constants.keyCodes.ARROW_DOWN) {
169
172
  index = dataCombo && index === dataCombo.length - 1 ? 0 : index + 1;
170
173
  } else {
171
- index = dataCombo && index === 0 ? dataCombo?.length - 1 : index - 1;
174
+ index = dataCombo && index === 0 ? (dataCombo === null || dataCombo === void 0 ? void 0 : dataCombo.length) - 1 : index - 1;
172
175
  }
173
176
  setSelected(dataCombo[index]);
174
177
  if (descriptionKeyIsString) setInputText(dataCombo[index][descriptionKey]);
@@ -205,7 +208,7 @@ const SimpleSelect = props => {
205
208
  }, []);
206
209
  (0, _react.useEffect)(() => {
207
210
  if (gridLayout) {
208
- const gridEl = document.querySelector(`#${componentId}>.-withinput.grid-container`);
211
+ const gridEl = document.querySelector("#".concat(componentId, ">.-withinput.grid-container"));
209
212
  if (gridElement.current !== gridEl && gridEl) gridElement.current = gridEl;
210
213
  }
211
214
  }, [gridLayout]);
@@ -213,7 +216,10 @@ const SimpleSelect = props => {
213
216
  if (dataSourceWithAllOptions.length > 0) {
214
217
  let newCurrent = null;
215
218
  if (value || value === 0) {
216
- newCurrent = dataSourceWithAllOptions.find(i => (value || value === 0) && i[idKey]?.toString().toLowerCase() === value?.toString().toLowerCase());
219
+ newCurrent = dataSourceWithAllOptions.find(i => {
220
+ var _i$idKey;
221
+ return (value || value === 0) && ((_i$idKey = i[idKey]) === null || _i$idKey === void 0 ? void 0 : _i$idKey.toString().toLowerCase()) === (value === null || value === void 0 ? void 0 : value.toString().toLowerCase());
222
+ });
217
223
  } else if (dataSourceWithAllOptions.length > 0 && selectFirstOnEnter) {
218
224
  newCurrent = dataSourceWithAllOptions[0];
219
225
  }
@@ -270,8 +276,8 @@ const SimpleSelect = props => {
270
276
  onClick: onFocus,
271
277
  onKeyDown: onInputKeyDown,
272
278
  customClassForLabel: customClassForLabel,
273
- customClassForWrapper: `selectwrapper ${(undigitable || searchOnDropdown || shouldBeReadOnly()) && ' -undigitable'} ${customClassForWrapper}`,
274
- customClassForInputContent: `multiselect ${customClassForInputContent}`,
279
+ customClassForWrapper: "selectwrapper ".concat((undigitable || searchOnDropdown || shouldBeReadOnly()) && ' -undigitable', " ").concat(customClassForWrapper),
280
+ customClassForInputContent: "multiselect ".concat(customClassForInputContent),
275
281
  inputBaseRef: r => {
276
282
  selectWrapper.current = r;
277
283
  },
@@ -19,7 +19,7 @@ const TextArea = props => {
19
19
  rows: rows,
20
20
  type: type,
21
21
  cols: cols,
22
- customClass: `textarea-container ${customClass}`
22
+ customClass: "textarea-container ".concat(customClass)
23
23
  }));
24
24
  };
25
25
  var _default = exports.default = TextArea;
@@ -31,6 +31,7 @@ interface ISearchProps extends IBaseProps {
31
31
  rounded?: boolean;
32
32
  inputRef?: MutableRefObject<HTMLInputElement | HTMLTextAreaElement | null>;
33
33
  style?: CSSProperties;
34
+ drawerFilterIsOpened?: boolean;
34
35
  }
35
36
  interface IDropdownProps {
36
37
  children: ReactNode | ReactNode[];
@@ -4,4 +4,4 @@ import '../../@types/ColorStyles.js';
4
4
  import '../../tooltip/types.js';
5
5
  import '../../@types/Position.js';
6
6
  import '../../@types/PermissionAttr.js';
7
- export { C as CheckboxFieldInputProps, I as Input } from '../../index-43ad8140.js';
7
+ export { C as CheckboxFieldInputProps, I as Input } from '../../index-d3b6a19a.js';
@@ -14,14 +14,14 @@ var _popover = _interopRequireWildcard(require("../../popover"));
14
14
  var _tooltip = require("../../tooltip");
15
15
  var _permissionValidations = require("../../permissionValidations");
16
16
  const _excluded = ["name", "label", "errors", "onChange", "size", "onDeniedActions", "permissionAttr", "variant", "customClass", "customClassLabel", "customClassWrapper", "labelUppercase", "rounded", "customClassInputContainer", "skeletonize", "hintPosition", "gridLayout", "themePopover", "popoverAlign", "tooltip", "tooltipPosition", "tooltipWidth"];
17
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
18
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
17
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
19
18
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
20
19
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
21
20
  function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
22
21
  function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
23
22
  const options = [_permissionValidations.OPTIONS_ON_DENIED.disabled, _permissionValidations.OPTIONS_ON_DENIED.unvisible, _permissionValidations.OPTIONS_ON_DENIED.readOnly, _permissionValidations.OPTIONS_ON_DENIED.hideContent];
24
23
  const Input = exports.Input = /*#__PURE__*/_react.default.forwardRef((props, ref) => {
24
+ var _props$checked, _props$hint;
25
25
  const {
26
26
  name,
27
27
  label,
@@ -54,14 +54,14 @@ const Input = exports.Input = /*#__PURE__*/_react.default.forwardRef((props, ref
54
54
  hideContent,
55
55
  unvisible
56
56
  } = onDenied;
57
- const inputId = _react.default.useMemo(() => props.id || `checkboxfield-${name}`, [props.id, name]);
57
+ const inputId = _react.default.useMemo(() => props.id || "checkboxfield-".concat(name), [props.id, name]);
58
58
  const inputRootRef = _react.default.useRef(null);
59
- const isChecked = props.checked ?? Boolean(props.value);
60
- const hasLabel = !_lodash.default.isEmpty(props?.label);
59
+ const isChecked = (_props$checked = props.checked) !== null && _props$checked !== void 0 ? _props$checked : Boolean(props.value);
60
+ const hasLabel = !_lodash.default.isEmpty(props === null || props === void 0 ? void 0 : props.label);
61
61
  const isReadOnly = Boolean(props.readOnly || onDenied.readOnly);
62
62
  const isDisabled = Boolean(props.disabled || onDenied.disabled);
63
- const hasHintMessages = Boolean(props.hint?.length);
64
- const hasValidationErrors = Boolean(errors?.length);
63
+ const hasHintMessages = Boolean((_props$hint = props.hint) === null || _props$hint === void 0 ? void 0 : _props$hint.length);
64
+ const hasValidationErrors = Boolean(errors === null || errors === void 0 ? void 0 : errors.length);
65
65
  const handleOnChange = _react.default.useCallback(event => {
66
66
  if (isReadOnly || isDisabled) return;
67
67
  Object.defineProperty(event.target, 'value', {
@@ -70,18 +70,19 @@ const Input = exports.Input = /*#__PURE__*/_react.default.forwardRef((props, ref
70
70
  enumerable: true,
71
71
  configurable: true
72
72
  });
73
- onChange?.(event);
73
+ onChange === null || onChange === void 0 ? void 0 : onChange(event);
74
74
  }, [isReadOnly, isDisabled, onChange]);
75
75
  if (unvisible || hideContent) return null;
76
76
  return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_gridlayout.default, {
77
77
  cols: gridLayout
78
78
  }, /*#__PURE__*/_react.default.createElement("div", {
79
79
  ref: inputRootRef,
80
- className: `checkbox-field-root ${customClassWrapper}`,
80
+ "data-testid": "test-chebox-field-root",
81
+ className: "checkbox-field-root ".concat(customClassWrapper),
81
82
  "data-state-error": hasValidationErrors
82
83
  }, /*#__PURE__*/_react.default.createElement("div", {
83
84
  "data-state-skeletonize": skeletonize,
84
- className: `container ${customClassInputContainer}`
85
+ className: "container ".concat(customClassInputContainer)
85
86
  }, /*#__PURE__*/_react.default.createElement("div", {
86
87
  className: "input-root"
87
88
  }, /*#__PURE__*/_react.default.createElement("input", _extends({
@@ -90,8 +91,9 @@ const Input = exports.Input = /*#__PURE__*/_react.default.forwardRef((props, ref
90
91
  name: name,
91
92
  readOnly: isReadOnly,
92
93
  disabled: isDisabled,
93
- className: `input ${customClass}`,
94
+ className: "input ".concat(customClass),
94
95
  tabIndex: !isReadOnly ? 0 : -1,
96
+ "data-testid": "test-checkbox-field-input",
95
97
  "data-state-size": size,
96
98
  "data-state-error": hasValidationErrors,
97
99
  "data-state-variant": variant,
@@ -107,11 +109,12 @@ const Input = exports.Input = /*#__PURE__*/_react.default.forwardRef((props, ref
107
109
  name: "checkmark",
108
110
  colorStyle: "default"
109
111
  })), hasLabel && /*#__PURE__*/_react.default.createElement("label", {
110
- className: `label ${customClassLabel}`,
112
+ className: "label ".concat(customClassLabel),
111
113
  title: label,
112
114
  htmlFor: inputId,
113
115
  "aria-readonly": isReadOnly,
114
116
  "aria-disabled": isDisabled,
117
+ "data-testid": "test-checkbox-field-label",
115
118
  "data-state-skeletonize": skeletonize,
116
119
  "data-state-disabled": isDisabled,
117
120
  "data-state-read-only": isReadOnly,
@@ -123,7 +126,7 @@ const Input = exports.Input = /*#__PURE__*/_react.default.forwardRef((props, ref
123
126
  align: popoverAlign,
124
127
  iconColor: "#03bde2"
125
128
  }, /*#__PURE__*/_react.default.createElement(_popover.PopoverText, {
126
- text: props?.hint
129
+ text: props === null || props === void 0 ? void 0 : props.hint
127
130
  }))), hintPosition === 'below' && /*#__PURE__*/_react.default.createElement(_hint.default, {
128
131
  customClass: "hint",
129
132
  description: props.hint,
@@ -134,8 +137,8 @@ const Input = exports.Input = /*#__PURE__*/_react.default.forwardRef((props, ref
134
137
  className: "error",
135
138
  "data-state-skeletonize": skeletonize,
136
139
  "aria-describedby": String(name).concat('-errors')
137
- }, errors?.map((error, index) => /*#__PURE__*/_react.default.createElement(_react.default.Fragment, {
138
- key: `${index + 1}-${error}`
140
+ }, errors === null || errors === void 0 ? void 0 : errors.map((error, index) => /*#__PURE__*/_react.default.createElement(_react.default.Fragment, {
141
+ key: "".concat(index + 1, "-").concat(error)
139
142
  }, error, "\xA0"))))), /*#__PURE__*/_react.default.createElement(_tooltip.Tooltip, {
140
143
  targetRef: inputRootRef,
141
144
  text: tooltip,
@@ -1,7 +1,7 @@
1
1
  import 'react';
2
2
  export { LeftSlot, RightSlot } from '../slot/index.js';
3
- import '../../index-772f9f1a.js';
4
- export { C as ColorFieldInputProps, I as Input } from '../../index-8a59cf4b.js';
3
+ import '../../index-3b70931d.js';
4
+ export { C as ColorFieldInputProps, I as Input } from '../../index-9e576346.js';
5
5
  import '../../@types/Align.js';
6
6
  import '../../@types/ColorStyles.js';
7
7
  import '../../@types/Position.js';
@@ -23,8 +23,7 @@ var TextField = _interopRequireWildcard(require("../textfield"));
23
23
  var _buttons = _interopRequireDefault(require("../../../lib/buttons"));
24
24
  var _permissionValidations = require("../../../lib/permissionValidations");
25
25
  const _excluded = ["name", "isTypeText", "defaultValue", "onChange", "permissionAttr", "onDeniedActions"];
26
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
27
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
26
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
28
27
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
29
28
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
30
29
  function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
@@ -64,15 +63,16 @@ const Input = exports.Input = /*#__PURE__*/_react.default.forwardRef((props, ref
64
63
  const handleTextInputChange = e => {
65
64
  const newValue = e.target.value;
66
65
  syncColorValues(newValue);
67
- onChange?.(e);
66
+ onChange === null || onChange === void 0 ? void 0 : onChange(e);
68
67
  };
69
68
  const handleColorInputChange = e => {
70
69
  const newValue = e.target.value;
71
70
  syncColorValues(newValue);
72
- onChange?.(e);
71
+ onChange === null || onChange === void 0 ? void 0 : onChange(e);
73
72
  };
74
73
  const onPaletteButtonClick = () => {
75
- inputRefColor.current?.click();
74
+ var _inputRefColor$curren;
75
+ (_inputRefColor$curren = inputRefColor.current) === null || _inputRefColor$curren === void 0 ? void 0 : _inputRefColor$curren.click();
76
76
  };
77
77
  _react.default.useLayoutEffect(() => {
78
78
  syncColorValues(String(defaultValue));
@@ -10,7 +10,8 @@ const useCalendarPosition = (calendarBoxOpen, containerRef) => {
10
10
  const [calendarBoxStyles, setCalendarBoxStyles] = _react.default.useState({});
11
11
  _react.default.useEffect(() => {
12
12
  const updatePosition = () => {
13
- const selectPositionOnScreen = containerRef.current?.getBoundingClientRect();
13
+ var _containerRef$current;
14
+ const selectPositionOnScreen = (_containerRef$current = containerRef.current) === null || _containerRef$current === void 0 ? void 0 : _containerRef$current.getBoundingClientRect();
14
15
  if (selectPositionOnScreen) {
15
16
  const {
16
17
  top,