linear-react-components-ui 1.0.10-beta.1 → 1.0.10-beta.11

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 (446) hide show
  1. package/demo/06c001f4d19c06397d470bb43ff3fe49.png +0 -0
  2. package/demo/270084ef02ed3bddc3f735fd91ee3cae.png +0 -0
  3. package/demo/882f8e819d18f5f2dc08d23ebd28a7d5.png +0 -0
  4. package/demo/bundle.js +2 -0
  5. package/demo/bundle.js.LICENSE.txt +65 -0
  6. package/demo/cbc3b4bd6342c551db7afafe26dc458c.jpg +0 -0
  7. package/demo/edc9476523b940deab91951066981a31.png +0 -0
  8. package/demo/fb44e7c36db6d95bb85a745d4f060fb2.png +0 -0
  9. package/demo/fonts/Roboto-Black.woff +0 -0
  10. package/demo/fonts/Roboto-Black.woff2 +0 -0
  11. package/demo/fonts/Roboto-Bold.woff +0 -0
  12. package/demo/fonts/Roboto-Bold.woff2 +0 -0
  13. package/demo/fonts/Roboto-Light.woff +0 -0
  14. package/demo/fonts/Roboto-Light.woff2 +0 -0
  15. package/demo/fonts/Roboto-Medium.woff +0 -0
  16. package/demo/fonts/Roboto-Medium.woff2 +0 -0
  17. package/demo/fonts/Roboto-Regular.woff +0 -0
  18. package/demo/fonts/Roboto-Regular.woff2 +0 -0
  19. package/demo/fonts/Roboto-Thin.woff +0 -0
  20. package/demo/fonts/Roboto-Thin.woff2 +0 -0
  21. package/demo/fonts/TitilliumWeb-Black.woff +0 -0
  22. package/demo/fonts/TitilliumWeb-Black.woff2 +0 -0
  23. package/demo/fonts/TitilliumWeb-Bold.woff +0 -0
  24. package/demo/fonts/TitilliumWeb-Bold.woff2 +0 -0
  25. package/demo/fonts/TitilliumWeb-ExtraLight.woff +0 -0
  26. package/demo/fonts/TitilliumWeb-ExtraLight.woff2 +0 -0
  27. package/demo/fonts/TitilliumWeb-Light.woff +0 -0
  28. package/demo/fonts/TitilliumWeb-Light.woff2 +0 -0
  29. package/demo/fonts/TitilliumWeb-Regular.woff +0 -0
  30. package/demo/fonts/TitilliumWeb-Regular.woff2 +0 -0
  31. package/demo/fonts/TitilliumWeb-SemiBold.woff +0 -0
  32. package/demo/fonts/TitilliumWeb-SemiBold.woff2 +0 -0
  33. package/demo/index.html +1 -0
  34. package/lib/@types/Align.d.ts +3 -2
  35. package/lib/@types/ButtonTypes.d.ts +1 -1
  36. package/lib/@types/ColorStyles.d.ts +1 -1
  37. package/lib/@types/DataCombo.d.ts +1 -1
  38. package/lib/@types/Icon.d.ts +1 -1
  39. package/lib/@types/LabelStyles.d.ts +1 -1
  40. package/lib/@types/Period.d.ts +1 -1
  41. package/lib/@types/PermissionAttr.d.ts +2 -2
  42. package/lib/@types/PointerEvents.d.ts +1 -1
  43. package/lib/@types/Position.d.ts +1 -1
  44. package/lib/@types/PositionAlert.d.ts +1 -1
  45. package/lib/@types/Size.d.ts +1 -1
  46. package/lib/@types/SizePixels.d.ts +1 -1
  47. package/lib/alerts/AlertContainer.d.ts +2 -0
  48. package/lib/alerts/AlertContainer.js +21 -5
  49. package/lib/alerts/AlertProvider.d.ts +2 -0
  50. package/lib/alerts/AlertProvider.js +45 -15
  51. package/lib/alerts/BaseAlert.d.ts +2 -0
  52. package/lib/alerts/BaseAlert.js +20 -4
  53. package/lib/alerts/Message.d.ts +2 -0
  54. package/lib/alerts/Message.js +32 -21
  55. package/lib/alerts/helpers.d.ts +2 -0
  56. package/lib/alerts/helpers.js +2 -0
  57. package/lib/alerts/index.d.ts +3 -4
  58. package/lib/alerts/index.js +4 -0
  59. package/lib/alerts/types.d.ts +7 -5
  60. package/lib/alerts/withAlert.d.ts +2 -0
  61. package/lib/alerts/withAlert.js +12 -1
  62. package/lib/assets/styles/dialog.scss +0 -2
  63. package/lib/assets/styles/drawers.scss +9 -0
  64. package/lib/assets/styles/table.scss +30 -0
  65. package/lib/assets/styles/tooltip.scss +42 -2
  66. package/lib/avatar/index.js +35 -20
  67. package/lib/badge/index.js +14 -9
  68. package/lib/buttons/ActivateButton.d.ts +2 -0
  69. package/lib/buttons/ActivateButton.js +6 -0
  70. package/lib/buttons/AddButton.d.ts +2 -0
  71. package/lib/buttons/AddButton.js +7 -0
  72. package/lib/buttons/Button.d.ts +2 -0
  73. package/lib/buttons/Button.js +15 -2
  74. package/lib/buttons/ButtonGroups.js +4 -0
  75. package/lib/buttons/CancelButton.d.ts +2 -0
  76. package/lib/buttons/CancelButton.js +11 -1
  77. package/lib/buttons/DangerButton.d.ts +2 -0
  78. package/lib/buttons/DangerButton.js +11 -1
  79. package/lib/buttons/DefaultButton.d.ts +2 -0
  80. package/lib/buttons/DefaultButton.js +97 -49
  81. package/lib/buttons/DestroyButton.d.ts +2 -0
  82. package/lib/buttons/DestroyButton.js +12 -1
  83. package/lib/buttons/EditButton.d.ts +2 -0
  84. package/lib/buttons/EditButton.js +6 -0
  85. package/lib/buttons/InactivateButton.d.ts +2 -0
  86. package/lib/buttons/InactivateButton.js +6 -0
  87. package/lib/buttons/InfoButton.d.ts +2 -0
  88. package/lib/buttons/InfoButton.js +11 -1
  89. package/lib/buttons/PrimaryButton.d.ts +2 -0
  90. package/lib/buttons/PrimaryButton.js +11 -1
  91. package/lib/buttons/RestoreButton.d.ts +2 -0
  92. package/lib/buttons/RestoreButton.js +6 -0
  93. package/lib/buttons/SaveButton.d.ts +2 -0
  94. package/lib/buttons/SaveButton.js +11 -1
  95. package/lib/buttons/SuccessButton.d.ts +2 -0
  96. package/lib/buttons/SuccessButton.js +11 -1
  97. package/lib/buttons/WarningButton.d.ts +2 -0
  98. package/lib/buttons/WarningButton.js +11 -1
  99. package/lib/buttons/button_container/index.js +11 -5
  100. package/lib/buttons/index.d.ts +3 -4
  101. package/lib/buttons/index.js +18 -0
  102. package/lib/buttons/split_button/index.d.ts +2 -0
  103. package/lib/buttons/split_button/index.js +17 -11
  104. package/lib/buttons/types.d.ts +6 -2
  105. package/lib/calendar/DangerCalendar.js +11 -1
  106. package/lib/calendar/InfoCalendar.js +11 -1
  107. package/lib/calendar/PrimaryCalendar.js +11 -1
  108. package/lib/calendar/SuccessCalendar.js +11 -1
  109. package/lib/calendar/WarningCalendar.js +11 -1
  110. package/lib/calendar/base/Day.js +13 -2
  111. package/lib/calendar/base/Month.js +18 -1
  112. package/lib/calendar/base/Week.js +18 -2
  113. package/lib/calendar/base/helpers.js +24 -8
  114. package/lib/calendar/base/index.js +37 -13
  115. package/lib/calendar/index.d.ts +1 -4
  116. package/lib/calendar/index.js +8 -0
  117. package/lib/checkbox/Label.js +7 -1
  118. package/lib/checkbox/index.js +54 -28
  119. package/lib/checkbox/types.d.ts +2 -2
  120. package/lib/dialog/Alert.d.ts +3 -0
  121. package/lib/dialog/Alert.js +8 -0
  122. package/lib/dialog/Custom.d.ts +3 -0
  123. package/lib/dialog/Custom.js +17 -5
  124. package/lib/dialog/Error.d.ts +3 -0
  125. package/lib/dialog/Error.js +8 -0
  126. package/lib/dialog/Information.d.ts +3 -0
  127. package/lib/dialog/Information.js +8 -0
  128. package/lib/dialog/Question.d.ts +3 -0
  129. package/lib/dialog/Question.js +15 -4
  130. package/lib/dialog/Warning.d.ts +3 -0
  131. package/lib/dialog/Warning.js +8 -0
  132. package/lib/dialog/base/Content.d.ts +3 -0
  133. package/lib/dialog/base/Content.js +6 -1
  134. package/lib/dialog/base/Footer.d.ts +3 -0
  135. package/lib/dialog/base/Footer.js +4 -0
  136. package/lib/dialog/base/Header.d.ts +3 -0
  137. package/lib/dialog/base/Header.js +13 -5
  138. package/lib/dialog/base/index.d.ts +3 -0
  139. package/lib/dialog/base/index.js +33 -9
  140. package/lib/dialog/base/style.js +2 -0
  141. package/lib/dialog/form/index.d.ts +3 -0
  142. package/lib/dialog/form/index.js +29 -9
  143. package/lib/dialog/index.d.ts +4 -4
  144. package/lib/dialog/index.js +9 -0
  145. package/lib/dialog/types.d.ts +6 -3
  146. package/lib/drawer/Content.d.ts +2 -0
  147. package/lib/drawer/Content.js +13 -2
  148. package/lib/drawer/Drawer.d.ts +3 -1
  149. package/lib/drawer/Drawer.js +83 -24
  150. package/lib/drawer/Header.d.ts +2 -0
  151. package/lib/drawer/Header.js +27 -10
  152. package/lib/drawer/helpers.d.ts +2 -0
  153. package/lib/drawer/helpers.js +4 -0
  154. package/lib/drawer/index.d.ts +2 -0
  155. package/lib/drawer/index.js +8 -0
  156. package/lib/drawer/types.d.ts +4 -1
  157. package/lib/dropdown/Popup.js +39 -19
  158. package/lib/dropdown/helper.js +4 -0
  159. package/lib/dropdown/withDropdown.js +47 -18
  160. package/lib/fieldset/index.js +46 -21
  161. package/lib/form/Field.d.ts +6 -0
  162. package/lib/form/Field.js +60 -25
  163. package/lib/form/FieldArray.d.ts +6 -0
  164. package/lib/form/FieldArray.js +32 -15
  165. package/lib/form/FieldNumber.d.ts +6 -0
  166. package/lib/form/FieldNumber.js +20 -6
  167. package/lib/form/FieldPeriod.d.ts +6 -0
  168. package/lib/form/FieldPeriod.js +21 -9
  169. package/lib/form/helpers.d.ts +6 -0
  170. package/lib/form/helpers.js +30 -5
  171. package/lib/form/index.d.ts +8 -1
  172. package/lib/form/index.js +101 -37
  173. package/lib/form/types.d.ts +16 -6
  174. package/lib/form/withFieldHOC.d.ts +6 -0
  175. package/lib/form/withFieldHOC.js +34 -15
  176. package/lib/form/withFormSecurity.d.ts +6 -0
  177. package/lib/form/withFormSecurity.js +30 -6
  178. package/lib/gridlayout/GridCol.js +11 -5
  179. package/lib/gridlayout/GridRow.js +9 -3
  180. package/lib/gridlayout/index.d.ts +1 -4
  181. package/lib/gridlayout/index.js +4 -0
  182. package/lib/hint/index.js +11 -6
  183. package/lib/icons/index.d.ts +2 -0
  184. package/lib/icons/index.js +26 -16
  185. package/lib/icons/types.d.ts +4 -2
  186. package/lib/index.d.ts +4 -1
  187. package/lib/index.js +10 -0
  188. package/lib/inputs/base/InputTextBase.d.ts +1 -0
  189. package/lib/inputs/base/InputTextBase.js +85 -51
  190. package/lib/inputs/base/helpers.d.ts +2 -1
  191. package/lib/inputs/base/helpers.js +19 -6
  192. package/lib/inputs/base/types.d.ts +2 -1
  193. package/lib/inputs/color/index.js +38 -11
  194. package/lib/inputs/date/Dialog.d.ts +1 -0
  195. package/lib/inputs/date/Dialog.js +7 -2
  196. package/lib/inputs/date/Dropdown.d.ts +1 -0
  197. package/lib/inputs/date/Dropdown.js +8 -1
  198. package/lib/inputs/date/helpers.d.ts +1 -0
  199. package/lib/inputs/date/helpers.js +11 -2
  200. package/lib/inputs/date/index.d.ts +1 -0
  201. package/lib/inputs/date/index.js +101 -48
  202. package/lib/inputs/date/types.d.ts +1 -0
  203. package/lib/inputs/file/DefaultFile.d.ts +1 -0
  204. package/lib/inputs/file/DefaultFile.js +42 -13
  205. package/lib/inputs/file/DragDropFile.d.ts +1 -0
  206. package/lib/inputs/file/DragDropFile.js +90 -37
  207. package/lib/inputs/file/File.d.ts +1 -0
  208. package/lib/inputs/file/File.js +25 -4
  209. package/lib/inputs/file/FileButtonSettings.d.ts +1 -0
  210. package/lib/inputs/file/FileButtonSettings.js +11 -5
  211. package/lib/inputs/file/helpers.d.ts +1 -0
  212. package/lib/inputs/file/helpers.js +5 -0
  213. package/lib/inputs/file/index.d.ts +2 -4
  214. package/lib/inputs/file/index.js +6 -0
  215. package/lib/inputs/file/types.d.ts +2 -1
  216. package/lib/inputs/inputHOC.d.ts +3 -0
  217. package/lib/inputs/inputHOC.js +34 -10
  218. package/lib/inputs/mask/BaseMask.d.ts +1 -0
  219. package/lib/inputs/mask/BaseMask.js +17 -1
  220. package/lib/inputs/mask/Cnpj.d.ts +1 -0
  221. package/lib/inputs/mask/Cnpj.js +37 -12
  222. package/lib/inputs/mask/Cpf.d.ts +1 -0
  223. package/lib/inputs/mask/Cpf.js +33 -10
  224. package/lib/inputs/mask/Phone.d.ts +1 -0
  225. package/lib/inputs/mask/Phone.js +6 -0
  226. package/lib/inputs/mask/ZipCode.d.ts +1 -0
  227. package/lib/inputs/mask/ZipCode.js +6 -0
  228. package/lib/inputs/mask/helpers.d.ts +3 -0
  229. package/lib/inputs/mask/helpers.js +20 -8
  230. package/lib/inputs/mask/imaskHOC.d.ts +3 -0
  231. package/lib/inputs/mask/imaskHOC.js +83 -52
  232. package/lib/inputs/mask/index.d.ts +2 -4
  233. package/lib/inputs/mask/index.js +7 -0
  234. package/lib/inputs/mask/types.d.ts +2 -1
  235. package/lib/inputs/multiSelect/ActionButtons.d.ts +2 -1
  236. package/lib/inputs/multiSelect/ActionButtons.js +16 -4
  237. package/lib/inputs/multiSelect/Dropdown.d.ts +1 -0
  238. package/lib/inputs/multiSelect/Dropdown.js +46 -23
  239. package/lib/inputs/multiSelect/helper.d.ts +8 -6
  240. package/lib/inputs/multiSelect/helper.js +11 -3
  241. package/lib/inputs/multiSelect/index.d.ts +1 -0
  242. package/lib/inputs/multiSelect/index.js +108 -41
  243. package/lib/inputs/multiSelect/types.d.ts +12 -3
  244. package/lib/inputs/number/BaseNumber.d.ts +3 -0
  245. package/lib/inputs/number/BaseNumber.js +16 -3
  246. package/lib/inputs/number/Currency.d.ts +3 -0
  247. package/lib/inputs/number/Currency.js +7 -1
  248. package/lib/inputs/number/Decimal.d.ts +3 -0
  249. package/lib/inputs/number/Decimal.js +5 -0
  250. package/lib/inputs/number/format_number.js +7 -0
  251. package/lib/inputs/number/index.d.ts +3 -0
  252. package/lib/inputs/number/index.js +13 -3
  253. package/lib/inputs/number/types.d.ts +3 -1
  254. package/lib/inputs/period/Dialog.d.ts +1 -0
  255. package/lib/inputs/period/Dialog.js +7 -2
  256. package/lib/inputs/period/Dropdown.d.ts +1 -0
  257. package/lib/inputs/period/Dropdown.js +7 -0
  258. package/lib/inputs/period/PeriodList.d.ts +1 -0
  259. package/lib/inputs/period/PeriodList.js +7 -1
  260. package/lib/inputs/period/helper.d.ts +1 -0
  261. package/lib/inputs/period/helper.js +12 -2
  262. package/lib/inputs/period/index.d.ts +1 -0
  263. package/lib/inputs/period/index.js +120 -49
  264. package/lib/inputs/period/types.d.ts +4 -3
  265. package/lib/inputs/search/index.d.ts +3 -0
  266. package/lib/inputs/search/index.js +63 -18
  267. package/lib/inputs/select/ActionButtons.d.ts +3 -0
  268. package/lib/inputs/select/ActionButtons.js +12 -4
  269. package/lib/inputs/select/Dropdown.d.ts +3 -0
  270. package/lib/inputs/select/Dropdown.js +49 -29
  271. package/lib/inputs/select/helper.d.ts +7 -9
  272. package/lib/inputs/select/helper.js +41 -11
  273. package/lib/inputs/select/index.d.ts +1 -0
  274. package/lib/inputs/select/index.js +24 -8
  275. package/lib/inputs/select/multiple/Selecteds.d.ts +1 -0
  276. package/lib/inputs/select/multiple/Selecteds.js +8 -4
  277. package/lib/inputs/select/multiple/index.d.ts +1 -0
  278. package/lib/inputs/select/multiple/index.js +109 -47
  279. package/lib/inputs/select/simple/index.d.ts +1 -0
  280. package/lib/inputs/select/simple/index.js +157 -69
  281. package/lib/inputs/select/types.d.ts +28 -12
  282. package/lib/inputs/text/index.d.ts +1 -0
  283. package/lib/inputs/text/index.js +5 -1
  284. package/lib/inputs/text/types.d.ts +2 -2
  285. package/lib/inputs/textarea/index.d.ts +1 -0
  286. package/lib/inputs/textarea/index.js +10 -4
  287. package/lib/inputs/textarea/types.d.ts +1 -0
  288. package/lib/inputs/types.d.ts +7 -3
  289. package/lib/internals/types.d.ts +1 -0
  290. package/lib/internals/withTooltip.js +82 -30
  291. package/lib/labelMessages/index.d.ts +2 -0
  292. package/lib/labelMessages/index.js +46 -27
  293. package/lib/labelMessages/types.d.ts +3 -1
  294. package/lib/labels/DangerLabel.d.ts +2 -0
  295. package/lib/labels/DangerLabel.js +11 -1
  296. package/lib/labels/DefaultLabel.d.ts +2 -0
  297. package/lib/labels/DefaultLabel.js +41 -19
  298. package/lib/labels/InfoLabel.d.ts +2 -0
  299. package/lib/labels/InfoLabel.js +11 -1
  300. package/lib/labels/PrimaryLabel.d.ts +2 -0
  301. package/lib/labels/PrimaryLabel.js +11 -1
  302. package/lib/labels/SuccessLabel.d.ts +2 -0
  303. package/lib/labels/SuccessLabel.js +11 -1
  304. package/lib/labels/WarningLabel.d.ts +2 -0
  305. package/lib/labels/WarningLabel.js +11 -1
  306. package/lib/labels/index.d.ts +3 -4
  307. package/lib/labels/index.js +10 -0
  308. package/lib/labels/label_container/index.js +7 -3
  309. package/lib/labels/types.d.ts +3 -1
  310. package/lib/list/Header.d.ts +2 -0
  311. package/lib/list/Header.js +7 -3
  312. package/lib/list/Item.d.ts +2 -0
  313. package/lib/list/Item.js +68 -33
  314. package/lib/list/Separator.js +4 -0
  315. package/lib/list/helpers.d.ts +2 -0
  316. package/lib/list/helpers.js +4 -0
  317. package/lib/list/index.d.ts +2 -0
  318. package/lib/list/index.js +60 -25
  319. package/lib/list/types.d.ts +5 -3
  320. package/lib/menus/float/MenuItem.d.ts +2 -0
  321. package/lib/menus/float/MenuItem.js +26 -9
  322. package/lib/menus/float/SubMenuContainer.js +17 -5
  323. package/lib/menus/float/helpers.d.ts +2 -0
  324. package/lib/menus/float/helpers.js +4 -0
  325. package/lib/menus/float/index.d.ts +2 -0
  326. package/lib/menus/float/index.js +21 -8
  327. package/lib/menus/float/types.d.ts +3 -1
  328. package/lib/menus/index.d.ts +3 -4
  329. package/lib/menus/index.js +3 -0
  330. package/lib/menus/sidenav/ExpandMenu.d.ts +2 -0
  331. package/lib/menus/sidenav/ExpandMenu.js +7 -2
  332. package/lib/menus/sidenav/MenuLink.d.ts +2 -0
  333. package/lib/menus/sidenav/MenuLink.js +12 -3
  334. package/lib/menus/sidenav/NavMenuGroup.d.ts +2 -0
  335. package/lib/menus/sidenav/NavMenuGroup.js +12 -3
  336. package/lib/menus/sidenav/NavMenuItem.d.ts +2 -0
  337. package/lib/menus/sidenav/NavMenuItem.js +56 -27
  338. package/lib/menus/sidenav/NavSubMenuItem.d.ts +2 -0
  339. package/lib/menus/sidenav/NavSubMenuItem.js +27 -8
  340. package/lib/menus/sidenav/helpers.d.ts +2 -0
  341. package/lib/menus/sidenav/helpers.js +9 -0
  342. package/lib/menus/sidenav/index.d.ts +2 -0
  343. package/lib/menus/sidenav/index.js +75 -26
  344. package/lib/menus/sidenav/popup_menu_search/EmptyList.d.ts +2 -0
  345. package/lib/menus/sidenav/popup_menu_search/EmptyList.js +7 -2
  346. package/lib/menus/sidenav/popup_menu_search/index.d.ts +2 -0
  347. package/lib/menus/sidenav/popup_menu_search/index.js +45 -15
  348. package/lib/menus/sidenav/types.d.ts +5 -3
  349. package/lib/noPermission/index.js +6 -0
  350. package/lib/panel/Content.d.ts +3 -1
  351. package/lib/panel/Content.js +22 -7
  352. package/lib/panel/DangerPanel.d.ts +3 -1
  353. package/lib/panel/DangerPanel.js +7 -0
  354. package/lib/panel/Default.d.ts +3 -1
  355. package/lib/panel/Default.js +44 -20
  356. package/lib/panel/Header.d.ts +3 -1
  357. package/lib/panel/Header.js +29 -15
  358. package/lib/panel/InfoPanel.d.ts +3 -1
  359. package/lib/panel/InfoPanel.js +7 -0
  360. package/lib/panel/PrimaryPanel.d.ts +3 -1
  361. package/lib/panel/PrimaryPanel.js +7 -0
  362. package/lib/panel/SuccessPanel.d.ts +3 -1
  363. package/lib/panel/SuccessPanel.js +7 -0
  364. package/lib/panel/ToolBar.d.ts +3 -1
  365. package/lib/panel/ToolBar.js +5 -0
  366. package/lib/panel/WarningPanel.d.ts +3 -1
  367. package/lib/panel/WarningPanel.js +7 -0
  368. package/lib/panel/helpers.d.ts +3 -1
  369. package/lib/panel/helpers.js +10 -2
  370. package/lib/panel/index.d.ts +4 -5
  371. package/lib/panel/index.js +11 -0
  372. package/lib/panel/types.d.ts +3 -1
  373. package/lib/permissionValidations.js +15 -3
  374. package/lib/popover/PopoverText.d.ts +2 -0
  375. package/lib/popover/PopoverText.js +4 -0
  376. package/lib/popover/PopoverTitle.d.ts +2 -0
  377. package/lib/popover/PopoverTitle.js +4 -0
  378. package/lib/popover/index.d.ts +2 -0
  379. package/lib/popover/index.js +22 -12
  380. package/lib/popover/types.d.ts +3 -1
  381. package/lib/progress/Bar.js +33 -20
  382. package/lib/progress/index.js +14 -5
  383. package/lib/radio/index.js +46 -23
  384. package/lib/skeleton/SkeletonContainer.js +9 -3
  385. package/lib/skeleton/index.js +22 -10
  386. package/lib/spinner/SpinnerLoading.js +7 -3
  387. package/lib/spinner/index.js +40 -18
  388. package/lib/split/Split.js +83 -32
  389. package/lib/split/SplitSide.js +18 -6
  390. package/lib/split/helpers.d.ts +1 -1
  391. package/lib/split/helpers.js +4 -0
  392. package/lib/split/index.d.ts +1 -4
  393. package/lib/split/index.js +5 -0
  394. package/lib/table/Body.js +29 -15
  395. package/lib/table/Header.js +26 -5
  396. package/lib/table/HeaderColumn.js +21 -10
  397. package/lib/table/Row.js +47 -20
  398. package/lib/table/RowColumn.js +29 -12
  399. package/lib/table/helpers.js +7 -0
  400. package/lib/table/index.js +62 -32
  401. package/lib/table/types.d.ts +6 -1
  402. package/lib/tabs/DropdownItems.d.ts +2 -0
  403. package/lib/tabs/DropdownItems.js +21 -12
  404. package/lib/tabs/Menu.d.ts +2 -0
  405. package/lib/tabs/Menu.js +15 -5
  406. package/lib/tabs/MenuItems.d.ts +2 -0
  407. package/lib/tabs/MenuItems.js +33 -23
  408. package/lib/tabs/Panel.d.ts +2 -0
  409. package/lib/tabs/Panel.js +39 -14
  410. package/lib/tabs/index.d.ts +2 -0
  411. package/lib/tabs/index.js +113 -46
  412. package/lib/tabs/tabHelpers.d.ts +2 -0
  413. package/lib/tabs/tabHelpers.js +16 -3
  414. package/lib/tabs/types.d.ts +3 -1
  415. package/lib/toolbar/ButtonBar.d.ts +2 -0
  416. package/lib/toolbar/ButtonBar.js +29 -13
  417. package/lib/toolbar/LabelBar.d.ts +2 -0
  418. package/lib/toolbar/LabelBar.js +28 -11
  419. package/lib/toolbar/Separator.js +4 -0
  420. package/lib/toolbar/ToolBarGroup.d.ts +2 -0
  421. package/lib/toolbar/ToolBarGroup.js +6 -2
  422. package/lib/toolbar/helpers.d.ts +2 -0
  423. package/lib/toolbar/helpers.js +2 -0
  424. package/lib/toolbar/index.d.ts +2 -0
  425. package/lib/toolbar/index.js +23 -7
  426. package/lib/toolbar/types.d.ts +4 -2
  427. package/lib/tooltip/index.d.ts +1 -1
  428. package/lib/tooltip/index.js +30 -11
  429. package/lib/tooltip/types.d.ts +2 -1
  430. package/lib/treetable/Body.js +27 -9
  431. package/lib/treetable/Header.js +11 -1
  432. package/lib/treetable/Row.js +113 -58
  433. package/lib/treetable/helpers.js +10 -0
  434. package/lib/treetable/index.js +11 -0
  435. package/lib/treeview/Header.js +6 -2
  436. package/lib/treeview/Node.js +111 -47
  437. package/lib/treeview/constants.js +4 -0
  438. package/lib/treeview/index.js +134 -54
  439. package/lib/treeview/types.d.ts +2 -2
  440. package/lib/treeview_old/Header.js +6 -1
  441. package/lib/treeview_old/Node.js +32 -5
  442. package/lib/treeview_old/index.js +9 -1
  443. package/lib/{types-90c43ae1.d.ts → types-c1d83632.d.ts} +3 -2
  444. package/lib/uitour/index.js +73 -33
  445. package/lib/uitour/types.d.ts +1 -1
  446. package/package.json +1 -1
@@ -1,95 +1,130 @@
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
+
4
5
  Object.defineProperty(exports, "__esModule", {
5
6
  value: true
6
7
  });
7
8
  exports.default = void 0;
9
+
8
10
  var _react = _interopRequireWildcard(require("react"));
11
+
9
12
  var _tooltip = _interopRequireDefault(require("../tooltip"));
13
+
10
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
+
11
16
  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); }
17
+
12
18
  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; }
19
+
13
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); }
21
+
14
22
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
23
+
15
24
  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."); }
25
+
16
26
  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); }
17
- 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; }
18
- 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; } }
27
+
28
+ 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; }
29
+
30
+ 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; }
31
+
19
32
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
33
+
20
34
  var TOOLTIP_INITIAL_HEIGHT = 40;
35
+
21
36
  var hasTooltip = function hasTooltip(_ref) {
22
37
  var tooltip = _ref.tooltip;
23
38
  return tooltip;
24
39
  };
40
+
25
41
  var getDisplayName = function getDisplayName(_ref2) {
26
42
  var displayName = _ref2.displayName,
27
- name = _ref2.name;
43
+ name = _ref2.name;
28
44
  return displayName || name || 'Component';
29
45
  };
46
+
30
47
  var withTooltip = function withTooltip(WrappedComponent) {
31
48
  var EnhancedComponent = function EnhancedComponent(props) {
32
49
  var tooltip = props.tooltip,
33
- _props$tooltipWidth = props.tooltipWidth,
34
- tooltipWidth = _props$tooltipWidth === void 0 ? 'auto' : _props$tooltipWidth,
35
- _props$space = props.space,
36
- space = _props$space === void 0 ? 20 : _props$space,
37
- _props$tooltipPositio = props.tooltipPosition,
38
- tooltipPosition = _props$tooltipPositio === void 0 ? 'bottom' : _props$tooltipPositio;
50
+ _props$tooltipWidth = props.tooltipWidth,
51
+ tooltipWidth = _props$tooltipWidth === void 0 ? 'auto' : _props$tooltipWidth,
52
+ _props$space = props.space,
53
+ space = _props$space === void 0 ? 20 : _props$space,
54
+ _props$tooltipPositio = props.tooltipPosition,
55
+ tooltipPosition = _props$tooltipPositio === void 0 ? 'bottom' : _props$tooltipPositio,
56
+ errorMessage = props.errorMessage;
57
+
39
58
  var _useState = (0, _react.useState)(tooltipPosition),
40
- _useState2 = _slicedToArray(_useState, 2),
41
- stateTooltipPosition = _useState2[0],
42
- setStateTooltipPosition = _useState2[1];
59
+ _useState2 = _slicedToArray(_useState, 2),
60
+ stateTooltipPosition = _useState2[0],
61
+ setStateTooltipPosition = _useState2[1];
62
+
43
63
  var _useState3 = (0, _react.useState)(''),
44
- _useState4 = _slicedToArray(_useState3, 2),
45
- tooltipStyle = _useState4[0],
46
- setTooltipStyle = _useState4[1];
64
+ _useState4 = _slicedToArray(_useState3, 2),
65
+ tooltipStyle = _useState4[0],
66
+ setTooltipStyle = _useState4[1];
67
+
47
68
  var _useState5 = (0, _react.useState)(false),
48
- _useState6 = _slicedToArray(_useState5, 2),
49
- showTooltip = _useState6[0],
50
- setShowTooltip = _useState6[1];
69
+ _useState6 = _slicedToArray(_useState5, 2),
70
+ showTooltip = _useState6[0],
71
+ setShowTooltip = _useState6[1];
72
+
51
73
  var _useState7 = (0, _react.useState)({
52
- width: tooltipWidth,
53
- height: TOOLTIP_INITIAL_HEIGHT
54
- }),
55
- _useState8 = _slicedToArray(_useState7, 2),
56
- tooltipDimensions = _useState8[0],
57
- setTooltipDimensions = _useState8[1];
74
+ width: tooltipWidth,
75
+ height: TOOLTIP_INITIAL_HEIGHT
76
+ }),
77
+ _useState8 = _slicedToArray(_useState7, 2),
78
+ tooltipDimensions = _useState8[0],
79
+ setTooltipDimensions = _useState8[1];
80
+
58
81
  var targetElement = (0, _react.useRef)(null);
59
82
  var tooltipElement = (0, _react.useRef)(null);
83
+
60
84
  var onMouseOver = function onMouseOver(e) {
61
85
  if (targetElement.current && targetElement.current.contains(e.target)) {
62
86
  setShowTooltip(true);
63
87
  } else setShowTooltip(false);
64
88
  };
89
+
65
90
  var onMouseOut = function onMouseOut() {
66
91
  setShowTooltip(false);
67
92
  };
93
+
68
94
  var onAnyScroll = function onAnyScroll() {
69
95
  setShowTooltip(false);
70
96
  };
97
+
71
98
  (0, _react.useEffect)(function () {
72
99
  if (hasTooltip(props)) {
73
- document.addEventListener('mouseover', onMouseOver);
74
- document.addEventListener('scroll', onAnyScroll, true);
75
- if (targetElement && targetElement.current) {
76
- targetElement.current.addEventListener('mouseout', onMouseOut);
100
+ if (errorMessage) {
101
+ setShowTooltip(true);
102
+ } else {
103
+ setShowTooltip(false);
104
+ document.addEventListener('mouseover', onMouseOver);
105
+ document.addEventListener('scroll', onAnyScroll, true);
106
+
107
+ if (targetElement && targetElement.current) {
108
+ targetElement.current.addEventListener('mouseout', onMouseOut);
109
+ }
77
110
  }
78
111
  }
112
+
79
113
  return function () {
80
114
  if (hasTooltip(props)) {
81
115
  document.removeEventListener('mouseover', onMouseOver);
82
116
  document.removeEventListener('scroll', onAnyScroll, true);
117
+
83
118
  if (targetElement && targetElement.current) {
84
119
  targetElement.current.removeEventListener('mouseout', onMouseOut);
85
120
  }
86
121
  }
87
122
  };
88
- }, []);
123
+ }, [errorMessage]);
89
124
  (0, _react.useEffect)(function () {
90
125
  if (targetElement.current && tooltipElement.current) {
91
126
  var width = tooltipDimensions.width,
92
- height = tooltipDimensions.height;
127
+ height = tooltipDimensions.height;
93
128
  var targetDimensions = targetElement.current.getBoundingClientRect();
94
129
  var targetVerticalCenter = (targetDimensions.top + targetDimensions.bottom) / 2;
95
130
  var tooltipClientWidth = tooltipElement.current.clientWidth;
@@ -97,6 +132,7 @@ var withTooltip = function withTooltip(WrappedComponent) {
97
132
  var left = targetDimensions.left + targetDimensions.width / 2 - tooltipClientWidth / 2;
98
133
  left = Math.min(left, document.body.clientWidth - tooltipClientWidth - space);
99
134
  style += "; left: ".concat(Math.max(space, left), "px");
135
+
100
136
  switch (stateTooltipPosition) {
101
137
  case 'top':
102
138
  if (targetDimensions.top < height) {
@@ -104,14 +140,18 @@ var withTooltip = function withTooltip(WrappedComponent) {
104
140
  } else {
105
141
  style += "; top: ".concat(targetDimensions.top + window.scrollY - height - 5, "px");
106
142
  }
143
+
107
144
  break;
145
+
108
146
  case 'bottom':
109
147
  if (window.innerHeight - targetDimensions.bottom < height) {
110
148
  setStateTooltipPosition('top');
111
149
  } else {
112
150
  style += "; top: ".concat(targetDimensions.top + window.scrollY + targetDimensions.height + 5, "px");
113
151
  }
152
+
114
153
  break;
154
+
115
155
  case 'left':
116
156
  if (targetDimensions.left < tooltipClientWidth) {
117
157
  setStateTooltipPosition('right');
@@ -119,7 +159,9 @@ var withTooltip = function withTooltip(WrappedComponent) {
119
159
  style += "; top: ".concat(targetVerticalCenter + window.scrollY - height / 2, "px");
120
160
  style += "; left: ".concat(targetDimensions.left - tooltipClientWidth - 6, "px");
121
161
  }
162
+
122
163
  break;
164
+
123
165
  case 'right':
124
166
  if (window.innerWidth - targetDimensions.right < tooltipClientWidth) {
125
167
  setStateTooltipPosition('left');
@@ -127,20 +169,25 @@ var withTooltip = function withTooltip(WrappedComponent) {
127
169
  style += "; top: ".concat(targetVerticalCenter + window.scrollY - height / 2, "px");
128
170
  style += "; left: ".concat(targetDimensions.left + targetDimensions.width + 5, "px");
129
171
  }
172
+
130
173
  break;
174
+
131
175
  default:
132
176
  style += '';
133
177
  }
178
+
134
179
  setTooltipStyle(style);
135
180
  }
136
181
  }, [tooltipDimensions, tooltipElement.current, targetElement.current, stateTooltipPosition]);
137
182
  (0, _react.useEffect)(function () {
138
183
  setStateTooltipPosition(tooltipPosition);
139
184
  }, [window.scrollY, window.scrollX, window.innerWidth]);
185
+
140
186
  var getTooltip = function getTooltip() {
141
187
  if (tooltip) {
142
188
  return /*#__PURE__*/_react.default.createElement(_tooltip.default, {
143
189
  text: tooltip,
190
+ textError: errorMessage,
144
191
  tooltipRef: tooltipElement,
145
192
  style: tooltipStyle,
146
193
  className: stateTooltipPosition,
@@ -148,18 +195,23 @@ var withTooltip = function withTooltip(WrappedComponent) {
148
195
  handlerSetDimensions: setTooltipDimensions
149
196
  });
150
197
  }
198
+
151
199
  return null;
152
200
  };
201
+
153
202
  var getTarget = function getTarget(targetEl) {
154
203
  if (!targetElement.current) targetElement.current = targetEl;
155
204
  };
205
+
156
206
  if (!hasTooltip(props)) return /*#__PURE__*/_react.default.createElement(WrappedComponent, props);
157
207
  return /*#__PURE__*/_react.default.createElement(_react.Fragment, null, /*#__PURE__*/_react.default.createElement(WrappedComponent, _extends({}, props, {
158
208
  targetRef: getTarget
159
209
  })), showTooltip && getTooltip());
160
210
  };
211
+
161
212
  EnhancedComponent.displayName = "withTooltip(".concat(getDisplayName(WrappedComponent), ")");
162
213
  return EnhancedComponent;
163
214
  };
215
+
164
216
  var _default = withTooltip;
165
217
  exports.default = _default;
@@ -1,6 +1,8 @@
1
1
  import { ILabelMessagesProps } from './types.js';
2
2
  import 'react';
3
3
  import '../@types/LabelStyles.js';
4
+ import '../@types/Icon.js';
5
+ import '../icons/helper.js';
4
6
 
5
7
  declare const LabelMessages: ({ style, icon, flat, iconName, handlerClosed, square, visible, children, customClass, type, showCloseButton }: ILabelMessagesProps) => JSX.Element | null;
6
8
 
@@ -1,55 +1,71 @@
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
+
4
5
  Object.defineProperty(exports, "__esModule", {
5
6
  value: true
6
7
  });
7
8
  exports.default = void 0;
9
+
8
10
  var _react = _interopRequireWildcard(require("react"));
11
+
9
12
  var _icons = _interopRequireDefault(require("../icons"));
13
+
10
14
  require("../assets/styles/labelMessages.scss");
15
+
11
16
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
17
+
12
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); }
19
+
13
20
  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; }
21
+
14
22
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
23
+
15
24
  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."); }
25
+
16
26
  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); }
17
- 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; }
18
- 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; } }
27
+
28
+ 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; }
29
+
30
+ 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; }
31
+
19
32
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
33
+
20
34
  var LabelMessages = function LabelMessages(_ref) {
21
35
  var _ref$style = _ref.style,
22
- style = _ref$style === void 0 ? {} : _ref$style,
23
- _ref$icon = _ref.icon,
24
- icon = _ref$icon === void 0 ? null : _ref$icon,
25
- _ref$flat = _ref.flat,
26
- flat = _ref$flat === void 0 ? false : _ref$flat,
27
- _ref$iconName = _ref.iconName,
28
- iconName = _ref$iconName === void 0 ? '' : _ref$iconName,
29
- handlerClosed = _ref.handlerClosed,
30
- _ref$square = _ref.square,
31
- square = _ref$square === void 0 ? true : _ref$square,
32
- _ref$visible = _ref.visible,
33
- visible = _ref$visible === void 0 ? true : _ref$visible,
34
- _ref$children = _ref.children,
35
- children = _ref$children === void 0 ? null : _ref$children,
36
- _ref$customClass = _ref.customClass,
37
- customClass = _ref$customClass === void 0 ? '' : _ref$customClass,
38
- _ref$type = _ref.type,
39
- type = _ref$type === void 0 ? 'default' : _ref$type,
40
- _ref$showCloseButton = _ref.showCloseButton,
41
- showCloseButton = _ref$showCloseButton === void 0 ? false : _ref$showCloseButton;
36
+ style = _ref$style === void 0 ? {} : _ref$style,
37
+ _ref$icon = _ref.icon,
38
+ icon = _ref$icon === void 0 ? null : _ref$icon,
39
+ _ref$flat = _ref.flat,
40
+ flat = _ref$flat === void 0 ? false : _ref$flat,
41
+ iconName = _ref.iconName,
42
+ handlerClosed = _ref.handlerClosed,
43
+ _ref$square = _ref.square,
44
+ square = _ref$square === void 0 ? true : _ref$square,
45
+ _ref$visible = _ref.visible,
46
+ visible = _ref$visible === void 0 ? true : _ref$visible,
47
+ _ref$children = _ref.children,
48
+ children = _ref$children === void 0 ? null : _ref$children,
49
+ _ref$customClass = _ref.customClass,
50
+ customClass = _ref$customClass === void 0 ? '' : _ref$customClass,
51
+ _ref$type = _ref.type,
52
+ type = _ref$type === void 0 ? 'default' : _ref$type,
53
+ _ref$showCloseButton = _ref.showCloseButton,
54
+ showCloseButton = _ref$showCloseButton === void 0 ? false : _ref$showCloseButton;
55
+
42
56
  var _useState = (0, _react.useState)(false),
43
- _useState2 = _slicedToArray(_useState, 2),
44
- closed = _useState2[0],
45
- setClosed = _useState2[1];
57
+ _useState2 = _slicedToArray(_useState, 2),
58
+ closed = _useState2[0],
59
+ setClosed = _useState2[1];
60
+
46
61
  var getClass = function getClass() {
47
62
  return "labelmessages-component -".concat(type, " ").concat(customClass, "\n ").concat(square && '-square', " ").concat(flat && '-flat');
48
63
  };
64
+
49
65
  var getIcon = function getIcon() {
50
- if (icon !== null) {
66
+ if (icon) {
51
67
  return icon;
52
- } else if (iconName !== null) {
68
+ } else if (iconName) {
53
69
  return /*#__PURE__*/_react.default.createElement(_icons.default, {
54
70
  name: iconName,
55
71
  size: 16,
@@ -57,8 +73,10 @@ var LabelMessages = function LabelMessages(_ref) {
57
73
  customClass: "-".concat(type, "svg")
58
74
  });
59
75
  }
76
+
60
77
  return null;
61
78
  };
79
+
62
80
  if (closed || !visible) return null;
63
81
  return /*#__PURE__*/_react.default.createElement(_react.Fragment, null, /*#__PURE__*/_react.default.createElement("div", {
64
82
  className: "".concat(getClass(), " ").concat(customClass),
@@ -76,5 +94,6 @@ var LabelMessages = function LabelMessages(_ref) {
76
94
  }
77
95
  }, "x")));
78
96
  };
97
+
79
98
  var _default = LabelMessages;
80
99
  exports.default = _default;
@@ -1,10 +1,12 @@
1
1
  import { CSSProperties, ReactNode } from 'react';
2
2
  import { LabelStyles } from '../@types/LabelStyles.js';
3
+ import { IconNames } from '../@types/Icon.js';
4
+ import '../icons/helper.js';
3
5
 
4
6
  interface ILabelMessagesProps {
5
7
  style?: CSSProperties;
6
8
  type?: LabelStyles;
7
- iconName?: string;
9
+ iconName?: IconNames;
8
10
  icon?: ReactNode | null;
9
11
  children?: ReactNode;
10
12
  customClass?: string;
@@ -3,6 +3,8 @@ import 'react';
3
3
  import '../@types/PermissionAttr.js';
4
4
  import '../@types/Position.js';
5
5
  import '../@types/Size.js';
6
+ import '../@types/Icon.js';
7
+ import '../icons/helper.js';
6
8
 
7
9
  declare const DangerLabel: ({ className, ...rest }: ILabelProps) => JSX.Element;
8
10
 
@@ -4,19 +4,29 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
+
7
8
  var _react = _interopRequireDefault(require("react"));
9
+
8
10
  var _DefaultLabel = _interopRequireDefault(require("./DefaultLabel"));
11
+
9
12
  var _excluded = ["className"];
13
+
10
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
+
11
16
  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); }
17
+
12
18
  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; }
19
+
13
20
  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; }
21
+
14
22
  var DangerLabel = function DangerLabel(_ref) {
15
23
  var className = _ref.className,
16
- rest = _objectWithoutProperties(_ref, _excluded);
24
+ rest = _objectWithoutProperties(_ref, _excluded);
25
+
17
26
  return /*#__PURE__*/_react.default.createElement(_DefaultLabel.default, _extends({
18
27
  className: "-danger"
19
28
  }, rest));
20
29
  };
30
+
21
31
  var _default = DangerLabel;
22
32
  exports.default = _default;
@@ -3,6 +3,8 @@ import 'react';
3
3
  import '../@types/PermissionAttr.js';
4
4
  import '../@types/Position.js';
5
5
  import '../@types/Size.js';
6
+ import '../@types/Icon.js';
7
+ import '../icons/helper.js';
6
8
 
7
9
  declare const _default: {
8
10
  (props: ILabelProps): JSX.Element;
@@ -1,47 +1,65 @@
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
+
4
5
  Object.defineProperty(exports, "__esModule", {
5
6
  value: true
6
7
  });
7
8
  exports.default = void 0;
9
+
8
10
  var _react = _interopRequireWildcard(require("react"));
11
+
9
12
  var _icons = _interopRequireDefault(require("../icons"));
13
+
10
14
  var _withTooltip = _interopRequireDefault(require("../internals/withTooltip"));
15
+
11
16
  var _permissionValidations = require("../permissionValidations");
17
+
12
18
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
+
13
20
  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); }
21
+
14
22
  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; }
23
+
15
24
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
25
+
16
26
  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."); }
27
+
17
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); }
18
- 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; }
19
- 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; } }
29
+
30
+ 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; }
31
+
32
+ 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; }
33
+
20
34
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
35
+
21
36
  var DefaultLabel = function DefaultLabel(_ref) {
22
37
  var style = _ref.style,
23
- targetRef = _ref.targetRef,
24
- iconName = _ref.iconName,
25
- icon = _ref.icon,
26
- children = _ref.children,
27
- _ref$visible = _ref.visible,
28
- visible = _ref$visible === void 0 ? true : _ref$visible,
29
- customClass = _ref.customClass,
30
- className = _ref.className,
31
- disabled = _ref.disabled,
32
- size = _ref.size,
33
- _ref$iconAlign = _ref.iconAlign,
34
- iconAlign = _ref$iconAlign === void 0 ? 'left' : _ref$iconAlign,
35
- bordered = _ref.bordered,
36
- permissionAttr = _ref.permissionAttr,
37
- skeletonize = _ref.skeletonize;
38
+ targetRef = _ref.targetRef,
39
+ iconName = _ref.iconName,
40
+ icon = _ref.icon,
41
+ children = _ref.children,
42
+ _ref$visible = _ref.visible,
43
+ visible = _ref$visible === void 0 ? true : _ref$visible,
44
+ customClass = _ref.customClass,
45
+ className = _ref.className,
46
+ disabled = _ref.disabled,
47
+ size = _ref.size,
48
+ _ref$iconAlign = _ref.iconAlign,
49
+ iconAlign = _ref$iconAlign === void 0 ? 'left' : _ref$iconAlign,
50
+ bordered = _ref.bordered,
51
+ permissionAttr = _ref.permissionAttr,
52
+ skeletonize = _ref.skeletonize;
38
53
  var options = [_permissionValidations.OPTIONS_ON_DENIED.disabled, _permissionValidations.OPTIONS_ON_DENIED.unvisible];
54
+
39
55
  var _useState = (0, _react.useState)((0, _permissionValidations.actionsOnPermissionDenied)(options, permissionAttr)),
40
- _useState2 = _slicedToArray(_useState, 1),
41
- onDenied = _useState2[0];
56
+ _useState2 = _slicedToArray(_useState, 1),
57
+ onDenied = _useState2[0];
58
+
42
59
  var getClass = function getClass() {
43
60
  return "label-component ".concat(className, " ").concat(customClass, " ").concat(bordered ? '-bordered' : '', " ").concat(disabled ? '-disabled' : '', "\n ").concat(skeletonize ? '-skeletonized' : '', "\n ").concat(size ? "-".concat(size) : '', "\n ").concat(iconAlign ? "icon-".concat(iconAlign) : '');
44
61
  };
62
+
45
63
  var getIcon = function getIcon() {
46
64
  if (icon) {
47
65
  return icon;
@@ -51,8 +69,10 @@ var DefaultLabel = function DefaultLabel(_ref) {
51
69
  size: 16
52
70
  });
53
71
  }
72
+
54
73
  return null;
55
74
  };
75
+
56
76
  if (!visible || onDenied.unvisible) return null;
57
77
  return /*#__PURE__*/_react.default.createElement("div", {
58
78
  style: style,
@@ -62,5 +82,7 @@ var DefaultLabel = function DefaultLabel(_ref) {
62
82
  }
63
83
  }, getIcon(), children);
64
84
  };
85
+
65
86
  var _default = (0, _withTooltip.default)(DefaultLabel);
87
+
66
88
  exports.default = _default;
@@ -3,6 +3,8 @@ import 'react';
3
3
  import '../@types/PermissionAttr.js';
4
4
  import '../@types/Position.js';
5
5
  import '../@types/Size.js';
6
+ import '../@types/Icon.js';
7
+ import '../icons/helper.js';
6
8
 
7
9
  declare const InfoLabel: ({ className, ...rest }: ILabelProps) => JSX.Element;
8
10
 
@@ -4,19 +4,29 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
+
7
8
  var _react = _interopRequireDefault(require("react"));
9
+
8
10
  var _DefaultLabel = _interopRequireDefault(require("./DefaultLabel"));
11
+
9
12
  var _excluded = ["className"];
13
+
10
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
+
11
16
  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); }
17
+
12
18
  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; }
19
+
13
20
  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; }
21
+
14
22
  var InfoLabel = function InfoLabel(_ref) {
15
23
  var className = _ref.className,
16
- rest = _objectWithoutProperties(_ref, _excluded);
24
+ rest = _objectWithoutProperties(_ref, _excluded);
25
+
17
26
  return /*#__PURE__*/_react.default.createElement(_DefaultLabel.default, _extends({
18
27
  className: "-info"
19
28
  }, rest));
20
29
  };
30
+
21
31
  var _default = InfoLabel;
22
32
  exports.default = _default;
@@ -3,6 +3,8 @@ import 'react';
3
3
  import '../@types/PermissionAttr.js';
4
4
  import '../@types/Position.js';
5
5
  import '../@types/Size.js';
6
+ import '../@types/Icon.js';
7
+ import '../icons/helper.js';
6
8
 
7
9
  declare const PrimaryLabel: ({ className, ...rest }: ILabelProps) => JSX.Element;
8
10
 
@@ -4,19 +4,29 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
+
7
8
  var _react = _interopRequireDefault(require("react"));
9
+
8
10
  var _DefaultLabel = _interopRequireDefault(require("./DefaultLabel"));
11
+
9
12
  var _excluded = ["className"];
13
+
10
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
+
11
16
  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); }
17
+
12
18
  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; }
19
+
13
20
  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; }
21
+
14
22
  var PrimaryLabel = function PrimaryLabel(_ref) {
15
23
  var className = _ref.className,
16
- rest = _objectWithoutProperties(_ref, _excluded);
24
+ rest = _objectWithoutProperties(_ref, _excluded);
25
+
17
26
  return /*#__PURE__*/_react.default.createElement(_DefaultLabel.default, _extends({
18
27
  className: "-primary"
19
28
  }, rest));
20
29
  };
30
+
21
31
  var _default = PrimaryLabel;
22
32
  exports.default = _default;