linear-react-components-ui 1.0.10-beta.12 → 1.0.10-beta.14

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 (386) hide show
  1. package/.eslintrc.json +1 -0
  2. package/README.md +19 -12
  3. package/lib/@types/Align.d.ts +2 -2
  4. package/lib/@types/ButtonTypes.d.ts +1 -1
  5. package/lib/@types/ColorStyles.d.ts +1 -1
  6. package/lib/@types/DataCombo.d.ts +1 -1
  7. package/lib/@types/Icon.d.ts +1 -1
  8. package/lib/@types/LabelStyles.d.ts +1 -1
  9. package/lib/@types/Period.d.ts +1 -1
  10. package/lib/@types/PermissionAttr.d.ts +2 -2
  11. package/lib/@types/PointerEvents.d.ts +1 -1
  12. package/lib/@types/Position.d.ts +1 -1
  13. package/lib/@types/PositionAlert.d.ts +1 -1
  14. package/lib/@types/Size.d.ts +1 -1
  15. package/lib/@types/SizePixels.d.ts +1 -1
  16. package/lib/alerts/AlertContainer.d.ts +2 -0
  17. package/lib/alerts/AlertContainer.js +5 -21
  18. package/lib/alerts/AlertProvider.d.ts +2 -0
  19. package/lib/alerts/AlertProvider.js +15 -45
  20. package/lib/alerts/BaseAlert.d.ts +2 -0
  21. package/lib/alerts/BaseAlert.js +4 -20
  22. package/lib/alerts/Message.d.ts +2 -0
  23. package/lib/alerts/Message.js +21 -32
  24. package/lib/alerts/helpers.d.ts +2 -0
  25. package/lib/alerts/helpers.js +0 -2
  26. package/lib/alerts/index.d.ts +6 -1
  27. package/lib/alerts/index.js +0 -4
  28. package/lib/alerts/types.d.ts +7 -5
  29. package/lib/alerts/withAlert.d.ts +2 -0
  30. package/lib/alerts/withAlert.js +1 -12
  31. package/lib/assets/styles/dialog.scss +9 -6
  32. package/lib/assets/styles/drawers.scss +9 -0
  33. package/lib/assets/styles/effects.scss +2 -2
  34. package/lib/assets/styles/radio.scss +52 -8
  35. package/lib/assets/styles/table.scss +30 -0
  36. package/lib/assets/styles/tooltip.scss +42 -2
  37. package/lib/avatar/index.js +20 -35
  38. package/lib/badge/index.js +9 -14
  39. package/lib/buttons/ActivateButton.d.ts +2 -0
  40. package/lib/buttons/ActivateButton.js +0 -6
  41. package/lib/buttons/AddButton.d.ts +2 -0
  42. package/lib/buttons/AddButton.js +0 -7
  43. package/lib/buttons/Button.d.ts +2 -0
  44. package/lib/buttons/Button.js +2 -15
  45. package/lib/buttons/ButtonGroups.js +0 -4
  46. package/lib/buttons/CancelButton.d.ts +2 -0
  47. package/lib/buttons/CancelButton.js +1 -11
  48. package/lib/buttons/DangerButton.d.ts +2 -0
  49. package/lib/buttons/DangerButton.js +1 -11
  50. package/lib/buttons/DefaultButton.d.ts +2 -0
  51. package/lib/buttons/DefaultButton.js +59 -85
  52. package/lib/buttons/DestroyButton.d.ts +2 -0
  53. package/lib/buttons/DestroyButton.js +1 -12
  54. package/lib/buttons/EditButton.d.ts +2 -0
  55. package/lib/buttons/EditButton.js +0 -6
  56. package/lib/buttons/InactivateButton.d.ts +2 -0
  57. package/lib/buttons/InactivateButton.js +0 -6
  58. package/lib/buttons/InfoButton.d.ts +2 -0
  59. package/lib/buttons/InfoButton.js +1 -11
  60. package/lib/buttons/PrimaryButton.d.ts +2 -0
  61. package/lib/buttons/PrimaryButton.js +1 -11
  62. package/lib/buttons/RestoreButton.d.ts +2 -0
  63. package/lib/buttons/RestoreButton.js +0 -6
  64. package/lib/buttons/SaveButton.d.ts +2 -0
  65. package/lib/buttons/SaveButton.js +1 -11
  66. package/lib/buttons/SuccessButton.d.ts +2 -0
  67. package/lib/buttons/SuccessButton.js +1 -11
  68. package/lib/buttons/WarningButton.d.ts +2 -0
  69. package/lib/buttons/WarningButton.js +1 -11
  70. package/lib/buttons/button_container/index.js +5 -11
  71. package/lib/buttons/index.d.ts +6 -1
  72. package/lib/buttons/index.js +0 -18
  73. package/lib/buttons/split_button/index.d.ts +2 -0
  74. package/lib/buttons/split_button/index.js +11 -17
  75. package/lib/buttons/types.d.ts +6 -2
  76. package/lib/calendar/DangerCalendar.js +1 -11
  77. package/lib/calendar/InfoCalendar.js +1 -11
  78. package/lib/calendar/PrimaryCalendar.js +1 -11
  79. package/lib/calendar/SuccessCalendar.js +1 -11
  80. package/lib/calendar/WarningCalendar.js +1 -11
  81. package/lib/calendar/base/Day.js +2 -13
  82. package/lib/calendar/base/Month.js +1 -18
  83. package/lib/calendar/base/Week.js +2 -18
  84. package/lib/calendar/base/helpers.js +8 -24
  85. package/lib/calendar/base/index.js +13 -37
  86. package/lib/calendar/index.d.ts +4 -1
  87. package/lib/calendar/index.js +0 -8
  88. package/lib/checkbox/Label.js +1 -7
  89. package/lib/checkbox/index.js +28 -54
  90. package/lib/checkbox/types.d.ts +2 -2
  91. package/lib/dialog/Alert.d.ts +2 -0
  92. package/lib/dialog/Alert.js +0 -8
  93. package/lib/dialog/Custom.d.ts +2 -0
  94. package/lib/dialog/Custom.js +5 -17
  95. package/lib/dialog/Error.d.ts +2 -0
  96. package/lib/dialog/Error.js +0 -8
  97. package/lib/dialog/Information.d.ts +2 -0
  98. package/lib/dialog/Information.js +0 -8
  99. package/lib/dialog/Question.d.ts +2 -0
  100. package/lib/dialog/Question.js +4 -15
  101. package/lib/dialog/Warning.d.ts +2 -0
  102. package/lib/dialog/Warning.js +0 -8
  103. package/lib/dialog/base/Content.d.ts +2 -0
  104. package/lib/dialog/base/Content.js +1 -6
  105. package/lib/dialog/base/Footer.d.ts +2 -0
  106. package/lib/dialog/base/Footer.js +0 -4
  107. package/lib/dialog/base/Header.d.ts +2 -0
  108. package/lib/dialog/base/Header.js +17 -14
  109. package/lib/dialog/base/index.d.ts +2 -0
  110. package/lib/dialog/base/index.js +85 -44
  111. package/lib/dialog/base/style.js +0 -2
  112. package/lib/dialog/form/index.d.ts +6 -3
  113. package/lib/dialog/form/index.js +20 -33
  114. package/lib/dialog/index.d.ts +6 -1
  115. package/lib/dialog/index.js +0 -9
  116. package/lib/dialog/types.d.ts +8 -3
  117. package/lib/drawer/Content.d.ts +2 -0
  118. package/lib/drawer/Content.js +2 -13
  119. package/lib/drawer/Drawer.d.ts +3 -1
  120. package/lib/drawer/Drawer.js +44 -60
  121. package/lib/drawer/Header.d.ts +2 -0
  122. package/lib/drawer/Header.js +10 -27
  123. package/lib/drawer/helpers.d.ts +2 -0
  124. package/lib/drawer/helpers.js +0 -4
  125. package/lib/drawer/index.d.ts +2 -0
  126. package/lib/drawer/index.js +0 -8
  127. package/lib/drawer/types.d.ts +4 -1
  128. package/lib/dropdown/Popup.js +24 -32
  129. package/lib/dropdown/helper.js +0 -4
  130. package/lib/dropdown/withDropdown.js +18 -47
  131. package/lib/fieldset/index.js +21 -46
  132. package/lib/form/Field.js +20 -46
  133. package/lib/form/FieldArray.js +15 -32
  134. package/lib/form/FieldNumber.d.ts +2 -2
  135. package/lib/form/FieldNumber.js +6 -20
  136. package/lib/form/FieldPeriod.js +9 -21
  137. package/lib/form/helpers.js +5 -30
  138. package/lib/form/index.d.ts +2 -1
  139. package/lib/form/index.js +45 -92
  140. package/lib/form/types.d.ts +8 -11
  141. package/lib/form/withFieldHOC.js +15 -34
  142. package/lib/form/withFormSecurity.js +7 -29
  143. package/lib/gridlayout/GridCol.js +5 -11
  144. package/lib/gridlayout/GridRow.js +3 -9
  145. package/lib/gridlayout/index.d.ts +4 -1
  146. package/lib/gridlayout/index.js +0 -4
  147. package/lib/hint/index.js +6 -11
  148. package/lib/icons/helper.d.ts +4 -0
  149. package/lib/icons/helper.js +4 -0
  150. package/lib/icons/index.d.ts +2 -0
  151. package/lib/icons/index.js +16 -26
  152. package/lib/icons/types.d.ts +4 -2
  153. package/lib/index.d.ts +3 -1
  154. package/lib/index.js +0 -10
  155. package/lib/inputs/base/InputTextBase.js +55 -75
  156. package/lib/inputs/base/helpers.js +6 -19
  157. package/lib/inputs/color/index.js +11 -38
  158. package/lib/inputs/date/Dialog.js +2 -7
  159. package/lib/inputs/date/Dropdown.js +1 -8
  160. package/lib/inputs/date/helpers.d.ts +1 -1
  161. package/lib/inputs/date/helpers.js +4 -12
  162. package/lib/inputs/date/index.js +65 -104
  163. package/lib/inputs/date/types.d.ts +2 -1
  164. package/lib/inputs/file/DefaultFile.js +13 -42
  165. package/lib/inputs/file/DragDropFile.js +37 -90
  166. package/lib/inputs/file/File.js +4 -25
  167. package/lib/inputs/file/FileButtonSettings.js +5 -11
  168. package/lib/inputs/file/helpers.js +0 -5
  169. package/lib/inputs/file/index.d.ts +4 -1
  170. package/lib/inputs/file/index.js +0 -6
  171. package/lib/inputs/file/types.d.ts +1 -1
  172. package/lib/inputs/inputHOC.d.ts +2 -0
  173. package/lib/inputs/inputHOC.js +10 -34
  174. package/lib/inputs/mask/BaseMask.js +21 -21
  175. package/lib/inputs/mask/Cnpj.js +12 -37
  176. package/lib/inputs/mask/Cpf.js +10 -33
  177. package/lib/inputs/mask/Phone.js +0 -6
  178. package/lib/inputs/mask/ZipCode.js +0 -6
  179. package/lib/inputs/mask/helpers.d.ts +2 -0
  180. package/lib/inputs/mask/helpers.js +9 -21
  181. package/lib/inputs/mask/imaskHOC.d.ts +2 -0
  182. package/lib/inputs/mask/imaskHOC.js +54 -85
  183. package/lib/inputs/mask/index.d.ts +4 -1
  184. package/lib/inputs/mask/index.js +0 -7
  185. package/lib/inputs/mask/types.d.ts +1 -1
  186. package/lib/inputs/multiSelect/ActionButtons.d.ts +1 -1
  187. package/lib/inputs/multiSelect/ActionButtons.js +7 -13
  188. package/lib/inputs/multiSelect/Dropdown.js +26 -49
  189. package/lib/inputs/multiSelect/helper.d.ts +8 -6
  190. package/lib/inputs/multiSelect/helper.js +7 -5
  191. package/lib/inputs/multiSelect/index.js +54 -114
  192. package/lib/inputs/multiSelect/types.d.ts +15 -6
  193. package/lib/inputs/number/BaseNumber.d.ts +2 -0
  194. package/lib/inputs/number/BaseNumber.js +3 -16
  195. package/lib/inputs/number/Currency.d.ts +2 -0
  196. package/lib/inputs/number/Currency.js +1 -7
  197. package/lib/inputs/number/Decimal.d.ts +2 -0
  198. package/lib/inputs/number/Decimal.js +0 -5
  199. package/lib/inputs/number/format_number.d.ts +2 -1
  200. package/lib/inputs/number/format_number.js +6 -9
  201. package/lib/inputs/number/index.d.ts +2 -0
  202. package/lib/inputs/number/index.js +3 -13
  203. package/lib/inputs/number/types.d.ts +4 -2
  204. package/lib/inputs/period/Dialog.js +2 -7
  205. package/lib/inputs/period/Dropdown.js +0 -7
  206. package/lib/inputs/period/PeriodList.js +1 -7
  207. package/lib/inputs/period/helper.js +2 -12
  208. package/lib/inputs/period/index.js +49 -120
  209. package/lib/inputs/period/types.d.ts +3 -3
  210. package/lib/inputs/search/index.d.ts +2 -0
  211. package/lib/inputs/search/index.js +18 -63
  212. package/lib/inputs/select/ActionButtons.d.ts +2 -0
  213. package/lib/inputs/select/ActionButtons.js +4 -12
  214. package/lib/inputs/select/Dropdown.d.ts +2 -0
  215. package/lib/inputs/select/Dropdown.js +29 -49
  216. package/lib/inputs/select/helper.d.ts +6 -9
  217. package/lib/inputs/select/helper.js +20 -27
  218. package/lib/inputs/select/index.js +9 -23
  219. package/lib/inputs/select/multiple/Selecteds.js +4 -8
  220. package/lib/inputs/select/multiple/index.js +50 -106
  221. package/lib/inputs/select/simple/index.js +87 -130
  222. package/lib/inputs/select/types.d.ts +21 -7
  223. package/lib/inputs/text/index.js +1 -5
  224. package/lib/inputs/text/types.d.ts +1 -1
  225. package/lib/inputs/textarea/index.js +5 -11
  226. package/lib/inputs/types.d.ts +5 -2
  227. package/lib/internals/types.d.ts +1 -0
  228. package/lib/internals/withTooltip.js +37 -75
  229. package/lib/labelMessages/index.d.ts +2 -0
  230. package/lib/labelMessages/index.js +26 -47
  231. package/lib/labelMessages/types.d.ts +3 -1
  232. package/lib/labels/DangerLabel.d.ts +2 -0
  233. package/lib/labels/DangerLabel.js +1 -11
  234. package/lib/labels/DefaultLabel.d.ts +2 -0
  235. package/lib/labels/DefaultLabel.js +19 -41
  236. package/lib/labels/InfoLabel.d.ts +2 -0
  237. package/lib/labels/InfoLabel.js +1 -11
  238. package/lib/labels/PrimaryLabel.d.ts +2 -0
  239. package/lib/labels/PrimaryLabel.js +1 -11
  240. package/lib/labels/SuccessLabel.d.ts +2 -0
  241. package/lib/labels/SuccessLabel.js +1 -11
  242. package/lib/labels/WarningLabel.d.ts +2 -0
  243. package/lib/labels/WarningLabel.js +1 -11
  244. package/lib/labels/index.d.ts +6 -1
  245. package/lib/labels/index.js +0 -10
  246. package/lib/labels/label_container/index.js +3 -7
  247. package/lib/labels/types.d.ts +3 -1
  248. package/lib/list/Header.d.ts +2 -0
  249. package/lib/list/Header.js +3 -7
  250. package/lib/list/Item.d.ts +2 -0
  251. package/lib/list/Item.js +33 -68
  252. package/lib/list/Separator.js +0 -4
  253. package/lib/list/helpers.d.ts +2 -0
  254. package/lib/list/helpers.js +0 -4
  255. package/lib/list/index.d.ts +2 -0
  256. package/lib/list/index.js +25 -60
  257. package/lib/list/types.d.ts +5 -3
  258. package/lib/menus/float/MenuItem.d.ts +2 -0
  259. package/lib/menus/float/MenuItem.js +9 -26
  260. package/lib/menus/float/SubMenuContainer.js +5 -17
  261. package/lib/menus/float/helpers.d.ts +2 -0
  262. package/lib/menus/float/helpers.js +0 -4
  263. package/lib/menus/float/index.d.ts +2 -0
  264. package/lib/menus/float/index.js +8 -21
  265. package/lib/menus/float/types.d.ts +3 -1
  266. package/lib/menus/index.d.ts +6 -1
  267. package/lib/menus/index.js +0 -3
  268. package/lib/menus/sidenav/ExpandMenu.d.ts +2 -0
  269. package/lib/menus/sidenav/ExpandMenu.js +2 -7
  270. package/lib/menus/sidenav/MenuLink.d.ts +2 -0
  271. package/lib/menus/sidenav/MenuLink.js +3 -12
  272. package/lib/menus/sidenav/NavMenuGroup.d.ts +2 -0
  273. package/lib/menus/sidenav/NavMenuGroup.js +3 -12
  274. package/lib/menus/sidenav/NavMenuItem.d.ts +2 -0
  275. package/lib/menus/sidenav/NavMenuItem.js +27 -56
  276. package/lib/menus/sidenav/NavSubMenuItem.d.ts +2 -0
  277. package/lib/menus/sidenav/NavSubMenuItem.js +8 -27
  278. package/lib/menus/sidenav/helpers.d.ts +2 -0
  279. package/lib/menus/sidenav/helpers.js +0 -9
  280. package/lib/menus/sidenav/index.d.ts +2 -0
  281. package/lib/menus/sidenav/index.js +26 -75
  282. package/lib/menus/sidenav/popup_menu_search/EmptyList.d.ts +2 -0
  283. package/lib/menus/sidenav/popup_menu_search/EmptyList.js +2 -7
  284. package/lib/menus/sidenav/popup_menu_search/index.d.ts +2 -0
  285. package/lib/menus/sidenav/popup_menu_search/index.js +15 -45
  286. package/lib/menus/sidenav/types.d.ts +5 -3
  287. package/lib/noPermission/index.js +0 -6
  288. package/lib/panel/Content.d.ts +3 -1
  289. package/lib/panel/Content.js +7 -22
  290. package/lib/panel/DangerPanel.d.ts +3 -1
  291. package/lib/panel/DangerPanel.js +0 -7
  292. package/lib/panel/Default.d.ts +3 -1
  293. package/lib/panel/Default.js +20 -44
  294. package/lib/panel/Header.d.ts +3 -1
  295. package/lib/panel/Header.js +14 -30
  296. package/lib/panel/InfoPanel.d.ts +3 -1
  297. package/lib/panel/InfoPanel.js +0 -7
  298. package/lib/panel/PrimaryPanel.d.ts +3 -1
  299. package/lib/panel/PrimaryPanel.js +0 -7
  300. package/lib/panel/SuccessPanel.d.ts +3 -1
  301. package/lib/panel/SuccessPanel.js +0 -7
  302. package/lib/panel/ToolBar.d.ts +3 -1
  303. package/lib/panel/ToolBar.js +0 -5
  304. package/lib/panel/WarningPanel.d.ts +3 -1
  305. package/lib/panel/WarningPanel.js +0 -7
  306. package/lib/panel/helpers.d.ts +3 -1
  307. package/lib/panel/helpers.js +2 -10
  308. package/lib/panel/index.d.ts +7 -2
  309. package/lib/panel/index.js +0 -11
  310. package/lib/panel/types.d.ts +3 -1
  311. package/lib/permissionValidations.js +3 -15
  312. package/lib/popover/PopoverText.d.ts +2 -0
  313. package/lib/popover/PopoverText.js +0 -4
  314. package/lib/popover/PopoverTitle.d.ts +2 -0
  315. package/lib/popover/PopoverTitle.js +0 -4
  316. package/lib/popover/index.d.ts +2 -0
  317. package/lib/popover/index.js +11 -23
  318. package/lib/popover/types.d.ts +3 -1
  319. package/lib/progress/Bar.js +20 -33
  320. package/lib/progress/index.js +5 -14
  321. package/lib/radio/index.d.ts +2 -1
  322. package/lib/radio/index.js +26 -47
  323. package/lib/radio/types.d.ts +2 -0
  324. package/lib/skeleton/SkeletonContainer.js +3 -9
  325. package/lib/skeleton/index.js +10 -22
  326. package/lib/spinner/SpinnerLoading.js +3 -7
  327. package/lib/spinner/index.js +18 -40
  328. package/lib/split/Split.js +32 -83
  329. package/lib/split/SplitSide.js +6 -18
  330. package/lib/split/helpers.d.ts +1 -1
  331. package/lib/split/helpers.js +0 -4
  332. package/lib/split/index.d.ts +4 -1
  333. package/lib/split/index.js +0 -5
  334. package/lib/table/Body.js +22 -39
  335. package/lib/table/Header.js +24 -42
  336. package/lib/table/HeaderColumn.js +10 -21
  337. package/lib/table/Row.js +37 -30
  338. package/lib/table/RowColumn.js +12 -29
  339. package/lib/table/helpers.js +0 -7
  340. package/lib/table/index.js +33 -62
  341. package/lib/table/types.d.ts +8 -1
  342. package/lib/tabs/DropdownItems.d.ts +2 -0
  343. package/lib/tabs/DropdownItems.js +12 -21
  344. package/lib/tabs/Menu.d.ts +2 -0
  345. package/lib/tabs/Menu.js +5 -15
  346. package/lib/tabs/MenuItems.d.ts +2 -0
  347. package/lib/tabs/MenuItems.js +23 -33
  348. package/lib/tabs/Panel.d.ts +2 -0
  349. package/lib/tabs/Panel.js +14 -39
  350. package/lib/tabs/index.d.ts +2 -0
  351. package/lib/tabs/index.js +46 -113
  352. package/lib/tabs/tabHelpers.d.ts +2 -0
  353. package/lib/tabs/tabHelpers.js +3 -16
  354. package/lib/tabs/types.d.ts +3 -1
  355. package/lib/toolbar/ButtonBar.d.ts +2 -0
  356. package/lib/toolbar/ButtonBar.js +13 -29
  357. package/lib/toolbar/LabelBar.d.ts +2 -0
  358. package/lib/toolbar/LabelBar.js +11 -28
  359. package/lib/toolbar/Separator.js +0 -4
  360. package/lib/toolbar/ToolBarGroup.d.ts +2 -0
  361. package/lib/toolbar/ToolBarGroup.js +2 -6
  362. package/lib/toolbar/helpers.d.ts +2 -0
  363. package/lib/toolbar/helpers.js +0 -2
  364. package/lib/toolbar/index.d.ts +2 -0
  365. package/lib/toolbar/index.js +7 -23
  366. package/lib/toolbar/types.d.ts +4 -2
  367. package/lib/tooltip/index.d.ts +1 -1
  368. package/lib/tooltip/index.js +15 -26
  369. package/lib/tooltip/types.d.ts +2 -1
  370. package/lib/treetable/Body.js +9 -27
  371. package/lib/treetable/Header.js +1 -11
  372. package/lib/treetable/Row.js +58 -113
  373. package/lib/treetable/helpers.js +0 -10
  374. package/lib/treetable/index.js +0 -11
  375. package/lib/treeview/Header.js +2 -6
  376. package/lib/treeview/Node.js +47 -111
  377. package/lib/treeview/constants.js +0 -4
  378. package/lib/treeview/index.js +55 -134
  379. package/lib/treeview/types.d.ts +2 -2
  380. package/lib/treeview_old/Header.js +1 -6
  381. package/lib/treeview_old/Node.js +5 -32
  382. package/lib/treeview_old/index.js +1 -9
  383. package/lib/{types-3c6f1c20.d.ts → types-c1e2d0c9.d.ts} +3 -2
  384. package/lib/uitour/index.js +33 -73
  385. package/lib/uitour/types.d.ts +1 -1
  386. package/package.json +6 -3
@@ -1,151 +1,109 @@
1
1
  "use strict";
2
2
 
3
3
  function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
8
7
  exports.default = void 0;
9
-
10
8
  var _react = _interopRequireWildcard(require("react"));
11
-
12
9
  var _lodash = _interopRequireDefault(require("lodash"));
13
-
14
10
  var _uuid = require("uuid");
15
-
16
11
  var _icons = _interopRequireDefault(require("../icons"));
17
-
18
12
  var _SpinnerLoading = _interopRequireDefault(require("../spinner/SpinnerLoading"));
19
-
20
13
  var _table = require("../table");
21
-
22
14
  var _toolbar = _interopRequireWildcard(require("../toolbar"));
23
-
24
15
  var _helpers = require("./helpers");
25
-
26
16
  var _excluded = ["validationKey", "onNodeElementClick"];
27
-
28
17
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
29
-
30
18
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
31
-
32
19
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
33
-
34
20
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
35
-
36
21
  function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
37
-
38
22
  function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
39
-
40
- function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return generator._invoke = function (innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; }(innerFn, self, context), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == _typeof(value) && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; this._invoke = function (method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); }; } function maybeInvokeDelegate(delegate, context) { var method = delegate.iterator[context.method]; if (undefined === method) { if (context.delegate = null, "throw" === context.method) { if (delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method)) return ContinueSentinel; context.method = "throw", context.arg = new TypeError("The iterator does not provide a 'throw' method"); } return ContinueSentinel; } var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) { if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; } return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, define(Gp, "constructor", GeneratorFunctionPrototype), define(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (object) { var keys = []; for (var key in object) { keys.push(key); } return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) { "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); } }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, catch: function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
41
-
23
+ function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == _typeof(value) && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function value(method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, catch: function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
42
24
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
43
-
44
25
  function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
45
-
46
26
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
47
-
48
27
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
49
-
50
28
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
51
-
52
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
53
-
54
- function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
55
-
29
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
30
+ function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
56
31
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
57
-
58
32
  var TreeRow = function TreeRow(props) {
59
33
  var _useContext = (0, _react.useContext)(_helpers.TreeTableContext),
60
- data = _useContext.data,
61
- dataColumns = _useContext.dataColumns,
62
- rootPropName = _useContext.rootPropName,
63
- stylesForRow = _useContext.stylesForRow,
64
- parentPropName = _useContext.parentPropName,
65
- styleForLeftToolbar = _useContext.styleForLeftToolbar,
66
- onClickFirstColumn = _useContext.onClickFirstColumn,
67
- onClickGetChildrens = _useContext.onClickGetChildrens,
68
- leftToolbarElements = _useContext.leftToolbarElements,
69
- rightToolbarElements = _useContext.rightToolbarElements,
70
- styleForRightToolbar = _useContext.styleForRightToolbar,
71
- toolbarElementsValidations = _useContext.toolbarElementsValidations;
72
-
34
+ data = _useContext.data,
35
+ dataColumns = _useContext.dataColumns,
36
+ rootPropName = _useContext.rootPropName,
37
+ stylesForRow = _useContext.stylesForRow,
38
+ parentPropName = _useContext.parentPropName,
39
+ styleForLeftToolbar = _useContext.styleForLeftToolbar,
40
+ onClickFirstColumn = _useContext.onClickFirstColumn,
41
+ onClickGetChildrens = _useContext.onClickGetChildrens,
42
+ leftToolbarElements = _useContext.leftToolbarElements,
43
+ rightToolbarElements = _useContext.rightToolbarElements,
44
+ styleForRightToolbar = _useContext.styleForRightToolbar,
45
+ toolbarElementsValidations = _useContext.toolbarElementsValidations;
73
46
  var rowId = props.rowId,
74
- dataRow = props.dataRow,
75
- rowLevel = props.rowLevel;
76
-
47
+ dataRow = props.dataRow,
48
+ rowLevel = props.rowLevel;
77
49
  var _useState = (0, _react.useState)(false),
78
- _useState2 = _slicedToArray(_useState, 2),
79
- open = _useState2[0],
80
- setOpen = _useState2[1];
81
-
50
+ _useState2 = _slicedToArray(_useState, 2),
51
+ open = _useState2[0],
52
+ setOpen = _useState2[1];
82
53
  var _useState3 = (0, _react.useState)(),
83
- _useState4 = _slicedToArray(_useState3, 2),
84
- childrens = _useState4[0],
85
- setChildrens = _useState4[1];
86
-
54
+ _useState4 = _slicedToArray(_useState3, 2),
55
+ childrens = _useState4[0],
56
+ setChildrens = _useState4[1];
87
57
  var _useState5 = (0, _react.useState)(false),
88
- _useState6 = _slicedToArray(_useState5, 2),
89
- isLoadingChildrens = _useState6[0],
90
- setIsLoadingChildrens = _useState6[1];
91
-
58
+ _useState6 = _slicedToArray(_useState5, 2),
59
+ isLoadingChildrens = _useState6[0],
60
+ setIsLoadingChildrens = _useState6[1];
92
61
  var _useState7 = (0, _react.useState)(false),
93
- _useState8 = _slicedToArray(_useState7, 2),
94
- showToolbarElements = _useState8[0],
95
- setShowToolbarElements = _useState8[1];
96
-
62
+ _useState8 = _slicedToArray(_useState7, 2),
63
+ showToolbarElements = _useState8[0],
64
+ setShowToolbarElements = _useState8[1];
97
65
  var _useState9 = (0, _react.useState)(false),
98
- _useState10 = _slicedToArray(_useState9, 2),
99
- firstRenderingOfChildrens = _useState10[0],
100
- setFirstRenderingOfChildrens = _useState10[1];
101
-
66
+ _useState10 = _slicedToArray(_useState9, 2),
67
+ firstRenderingOfChildrens = _useState10[0],
68
+ setFirstRenderingOfChildrens = _useState10[1];
102
69
  var searchChildrensAndInsertState = function searchChildrensAndInsertState() {
103
70
  var dataChildrens = (0, _helpers.searchChildrensPerRow)(data, parentPropName, rowId, rowLevel);
104
71
  setChildrens(dataChildrens);
105
72
  setIsLoadingChildrens(false);
106
73
  };
107
-
108
74
  var handlerShowChildrens = /*#__PURE__*/function () {
109
75
  var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
110
76
  return _regeneratorRuntime().wrap(function _callee$(_context) {
111
- while (1) {
112
- switch (_context.prev = _context.next) {
113
- case 0:
114
- if (!(!firstRenderingOfChildrens && !open && onClickGetChildrens)) {
115
- _context.next = 8;
116
- break;
117
- }
118
-
119
- setOpen(true);
120
- setIsLoadingChildrens(true);
121
- _context.next = 5;
122
- return onClickGetChildrens(rowId).then(function () {}).catch(function () {}).finally(function () {
123
- searchChildrensAndInsertState();
124
- });
125
-
126
- case 5:
127
- setFirstRenderingOfChildrens(true);
128
- _context.next = 9;
77
+ while (1) switch (_context.prev = _context.next) {
78
+ case 0:
79
+ if (!(!firstRenderingOfChildrens && !open && onClickGetChildrens)) {
80
+ _context.next = 8;
129
81
  break;
130
-
131
- case 8:
132
- setOpen(function (prevState) {
133
- return !prevState;
134
- });
135
-
136
- case 9:
137
- case "end":
138
- return _context.stop();
139
- }
82
+ }
83
+ setOpen(true);
84
+ setIsLoadingChildrens(true);
85
+ _context.next = 5;
86
+ return onClickGetChildrens(rowId).then(function () {}).catch(function () {}).finally(function () {
87
+ searchChildrensAndInsertState();
88
+ });
89
+ case 5:
90
+ setFirstRenderingOfChildrens(true);
91
+ _context.next = 9;
92
+ break;
93
+ case 8:
94
+ setOpen(function (prevState) {
95
+ return !prevState;
96
+ });
97
+ case 9:
98
+ case "end":
99
+ return _context.stop();
140
100
  }
141
101
  }, _callee);
142
102
  }));
143
-
144
103
  return function handlerShowChildrens() {
145
104
  return _ref.apply(this, arguments);
146
105
  };
147
106
  }();
148
-
149
107
  var validateRowElement = function validateRowElement(validationKey) {
150
108
  var validations = toolbarElementsValidations && toolbarElementsValidations[validationKey];
151
109
  var options = {
@@ -157,39 +115,31 @@ var TreeRow = function TreeRow(props) {
157
115
  }
158
116
  };
159
117
  var elementBehavior = {};
160
-
161
118
  if (validations) {
162
119
  validations.forEach(function (validation) {
163
120
  var validator = validation.validator,
164
- onDenied = validation.onDenied;
165
-
121
+ onDenied = validation.onDenied;
166
122
  if (_lodash.default.isEmpty(elementBehavior) && validator && validator(dataRow) && onDenied) {
167
123
  elementBehavior = options[onDenied] || options.unvisible;
168
124
  }
169
125
  });
170
126
  }
171
-
172
127
  return elementBehavior;
173
128
  };
174
-
175
129
  var buildToolbarElements = function buildToolbarElements(elements) {
176
130
  var newElementsWithNewProps = [];
177
-
178
131
  if (elements) {
179
132
  newElementsWithNewProps = _react.default.Children.map(elements, function (element) {
180
133
  if ( /*#__PURE__*/_react.default.isValidElement(element) && element.props) {
181
134
  var _element$props = element.props,
182
- validationKey = _element$props.validationKey,
183
- onNodeElementClick = _element$props.onNodeElementClick,
184
- restProps = _objectWithoutProperties(_element$props, _excluded);
185
-
135
+ validationKey = _element$props.validationKey,
136
+ onNodeElementClick = _element$props.onNodeElementClick,
137
+ restProps = _objectWithoutProperties(_element$props, _excluded);
186
138
  var elementBehavior;
187
139
  var newProps = {};
188
-
189
140
  if (toolbarElementsValidations && validationKey) {
190
141
  elementBehavior = validateRowElement(validationKey);
191
142
  }
192
-
193
143
  if (onNodeElementClick) {
194
144
  newProps = _extends({}, newProps, {
195
145
  onClick: function onClick(e) {
@@ -198,17 +148,13 @@ var TreeRow = function TreeRow(props) {
198
148
  }
199
149
  });
200
150
  }
201
-
202
151
  return /*#__PURE__*/(0, _react.createElement)(element.type, _extends({}, restProps, newProps, elementBehavior));
203
152
  }
204
-
205
153
  return element;
206
154
  });
207
155
  }
208
-
209
156
  return newElementsWithNewProps;
210
157
  };
211
-
212
158
  (0, _react.useEffect)(function () {
213
159
  searchChildrensAndInsertState();
214
160
  }, [data]);
@@ -309,6 +255,5 @@ var TreeRow = function TreeRow(props) {
309
255
  key: "loading-childrens"
310
256
  })))))));
311
257
  };
312
-
313
258
  var _default = TreeRow;
314
259
  exports.default = _default;
@@ -4,16 +4,12 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.searchRootElements = exports.searchChildrensPerRow = exports.TreeTableContext = void 0;
7
-
8
7
  var _react = require("react");
9
-
10
8
  var TreeTableContext = /*#__PURE__*/(0, _react.createContext)({});
11
9
  exports.TreeTableContext = TreeTableContext;
12
-
13
10
  var searchRootElements = function searchRootElements(data, parentPropName) {
14
11
  var rowLevel = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
15
12
  var dataFiltered;
16
-
17
13
  if (data) {
18
14
  dataFiltered = data.filter(function (item) {
19
15
  return !item[parentPropName];
@@ -24,16 +20,12 @@ var searchRootElements = function searchRootElements(data, parentPropName) {
24
20
  });
25
21
  });
26
22
  }
27
-
28
23
  return data;
29
24
  };
30
-
31
25
  exports.searchRootElements = searchRootElements;
32
-
33
26
  var searchChildrensPerRow = function searchChildrensPerRow(data, parentPropName, rowId) {
34
27
  var rowLevel = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 0;
35
28
  var dataFiltered;
36
-
37
29
  if (data && rowId) {
38
30
  dataFiltered = data.filter(function (item) {
39
31
  return item[parentPropName] === Number(rowId);
@@ -44,8 +36,6 @@ var searchChildrensPerRow = function searchChildrensPerRow(data, parentPropName,
44
36
  });
45
37
  });
46
38
  }
47
-
48
39
  return data;
49
40
  };
50
-
51
41
  exports.searchChildrensPerRow = searchChildrensPerRow;
@@ -4,32 +4,21 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _react = _interopRequireDefault(require("react"));
9
-
10
8
  require("../assets/styles/treetable.scss");
11
-
12
9
  var _table = _interopRequireDefault(require("../table"));
13
-
14
10
  var _Body = _interopRequireDefault(require("./Body"));
15
-
16
11
  var _Header = _interopRequireDefault(require("./Header"));
17
-
18
12
  var _helpers = require("./helpers");
19
-
20
13
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
21
-
22
14
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
23
-
24
15
  var TreeTable = function TreeTable(props) {
25
16
  var contextValues = _extends({}, props);
26
-
27
17
  return /*#__PURE__*/_react.default.createElement(_helpers.TreeTableContext.Provider, {
28
18
  value: contextValues
29
19
  }, /*#__PURE__*/_react.default.createElement(_table.default, _extends({}, props, {
30
20
  onColClick: function onColClick() {}
31
21
  }), /*#__PURE__*/_react.default.createElement(_Header.default, null), /*#__PURE__*/_react.default.createElement(_Body.default, null)));
32
22
  };
33
-
34
23
  var _default = TreeTable;
35
24
  exports.default = _default;
@@ -4,21 +4,17 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _react = _interopRequireDefault(require("react"));
9
-
10
8
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
11
-
12
9
  var Header = function Header(props) {
13
10
  var title = props.title,
14
- customClass = props.customClass,
15
- children = props.children;
11
+ customClass = props.customClass,
12
+ children = props.children;
16
13
  return /*#__PURE__*/_react.default.createElement("div", {
17
14
  className: "treeviewheader ".concat(customClass)
18
15
  }, title ? /*#__PURE__*/_react.default.createElement("div", {
19
16
  className: "title"
20
17
  }, title) : children);
21
18
  };
22
-
23
19
  var _default = Header;
24
20
  exports.default = _default;