@ukic/canary-web-components 2.0.0-canary.8 → 3.0.0-canary.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (853) hide show
  1. package/dist/cjs/core.cjs.js +1 -1
  2. package/dist/cjs/date-helpers-c9551119.js +150 -0
  3. package/dist/cjs/date-helpers-c9551119.js.map +1 -0
  4. package/dist/cjs/{helpers-b525d45a.js → helpers-33b42cd6.js} +101 -102
  5. package/dist/cjs/helpers-33b42cd6.js.map +1 -0
  6. package/dist/cjs/{helpers-93c5fc92.js → helpers-6817cfbb.js} +209 -12
  7. package/dist/cjs/helpers-6817cfbb.js.map +1 -0
  8. package/dist/cjs/ic-accordion-group.cjs.entry.js +31 -9
  9. package/dist/cjs/ic-accordion-group.cjs.entry.js.map +1 -1
  10. package/dist/cjs/ic-accordion.cjs.entry.js +7 -8
  11. package/dist/cjs/ic-accordion.cjs.entry.js.map +1 -1
  12. package/dist/cjs/ic-alert.cjs.entry.js +28 -10
  13. package/dist/cjs/ic-alert.cjs.entry.js.map +1 -1
  14. package/dist/cjs/ic-back-to-top.cjs.entry.js +17 -8
  15. package/dist/cjs/ic-back-to-top.cjs.entry.js.map +1 -1
  16. package/dist/cjs/ic-badge.cjs.entry.js +67 -117
  17. package/dist/cjs/ic-badge.cjs.entry.js.map +1 -1
  18. package/dist/cjs/ic-breadcrumb-group.cjs.entry.js +37 -11
  19. package/dist/cjs/ic-breadcrumb-group.cjs.entry.js.map +1 -1
  20. package/dist/cjs/ic-breadcrumb.cjs.entry.js +8 -7
  21. package/dist/cjs/ic-breadcrumb.cjs.entry.js.map +1 -1
  22. package/dist/cjs/ic-button_3.cjs.entry.js +121 -128
  23. package/dist/cjs/ic-button_3.cjs.entry.js.map +1 -1
  24. package/dist/cjs/ic-card-horizontal.cjs.entry.js +131 -0
  25. package/dist/cjs/ic-card-horizontal.cjs.entry.js.map +1 -0
  26. package/dist/cjs/ic-card-vertical.cjs.entry.js +149 -0
  27. package/dist/cjs/ic-card-vertical.cjs.entry.js.map +1 -0
  28. package/dist/cjs/ic-checkbox-group.cjs.entry.js +27 -20
  29. package/dist/cjs/ic-checkbox-group.cjs.entry.js.map +1 -1
  30. package/dist/cjs/ic-checkbox.cjs.entry.js +45 -40
  31. package/dist/cjs/ic-checkbox.cjs.entry.js.map +1 -1
  32. package/dist/cjs/ic-chip.cjs.entry.js +40 -29
  33. package/dist/cjs/ic-chip.cjs.entry.js.map +1 -1
  34. package/dist/cjs/ic-classification-banner.cjs.entry.js +14 -5
  35. package/dist/cjs/ic-classification-banner.cjs.entry.js.map +1 -1
  36. package/dist/cjs/ic-data-list.cjs.entry.js +32 -0
  37. package/dist/cjs/ic-data-list.cjs.entry.js.map +1 -0
  38. package/dist/cjs/ic-data-row.cjs.entry.js +12 -12
  39. package/dist/cjs/ic-data-row.cjs.entry.js.map +1 -1
  40. package/dist/cjs/ic-data-table-title-bar.cjs.entry.js +57 -0
  41. package/dist/cjs/ic-data-table-title-bar.cjs.entry.js.map +1 -0
  42. package/dist/cjs/ic-data-table.cjs.entry.js +805 -65
  43. package/dist/cjs/ic-data-table.cjs.entry.js.map +1 -1
  44. package/dist/cjs/ic-date-input.cjs.entry.js +1110 -0
  45. package/dist/cjs/ic-date-input.cjs.entry.js.map +1 -0
  46. package/dist/cjs/ic-date-picker.cjs.entry.js +1069 -0
  47. package/dist/cjs/ic-date-picker.cjs.entry.js.map +1 -0
  48. package/dist/cjs/ic-dialog.cjs.entry.js +27 -101
  49. package/dist/cjs/ic-dialog.cjs.entry.js.map +1 -1
  50. package/dist/cjs/ic-divider.cjs.entry.js +2 -3
  51. package/dist/cjs/ic-divider.cjs.entry.js.map +1 -1
  52. package/dist/cjs/ic-empty-state_2.cjs.entry.js +317 -0
  53. package/dist/cjs/ic-empty-state_2.cjs.entry.js.map +1 -0
  54. package/dist/cjs/ic-footer-link-group.cjs.entry.js +9 -10
  55. package/dist/cjs/ic-footer-link-group.cjs.entry.js.map +1 -1
  56. package/dist/cjs/ic-footer-link.cjs.entry.js +6 -8
  57. package/dist/cjs/ic-footer-link.cjs.entry.js.map +1 -1
  58. package/dist/cjs/ic-footer.cjs.entry.js +9 -10
  59. package/dist/cjs/ic-footer.cjs.entry.js.map +1 -1
  60. package/dist/cjs/ic-hero.cjs.entry.js +27 -12
  61. package/dist/cjs/ic-hero.cjs.entry.js.map +1 -1
  62. package/dist/cjs/ic-horizontal-scroll.cjs.entry.js +6 -8
  63. package/dist/cjs/ic-horizontal-scroll.cjs.entry.js.map +1 -1
  64. package/dist/cjs/ic-input-component-container_4.cjs.entry.js +156 -0
  65. package/dist/cjs/ic-input-component-container_4.cjs.entry.js.map +1 -0
  66. package/dist/cjs/ic-link.cjs.entry.js +51 -24
  67. package/dist/cjs/ic-link.cjs.entry.js.map +1 -1
  68. package/dist/cjs/ic-menu-group.cjs.entry.js +2 -3
  69. package/dist/cjs/ic-menu-group.cjs.entry.js.map +1 -1
  70. package/dist/cjs/ic-menu-item.cjs.entry.js +6 -13
  71. package/dist/cjs/ic-menu-item.cjs.entry.js.map +1 -1
  72. package/dist/cjs/ic-menu-with-multi.cjs.entry.js +186 -47
  73. package/dist/cjs/ic-menu-with-multi.cjs.entry.js.map +1 -1
  74. package/dist/cjs/{ic-input-component-container_3.cjs.entry.js → ic-menu.cjs.entry.js} +17 -86
  75. package/dist/cjs/ic-menu.cjs.entry.js.map +1 -0
  76. package/dist/cjs/ic-navigation-button.cjs.entry.js +28 -8
  77. package/dist/cjs/ic-navigation-button.cjs.entry.js.map +1 -1
  78. package/dist/cjs/ic-navigation-group.cjs.entry.js +23 -21
  79. package/dist/cjs/ic-navigation-group.cjs.entry.js.map +1 -1
  80. package/dist/cjs/ic-navigation-item.cjs.entry.js +33 -38
  81. package/dist/cjs/ic-navigation-item.cjs.entry.js.map +1 -1
  82. package/dist/cjs/ic-navigation-menu.cjs.entry.js +3 -4
  83. package/dist/cjs/ic-navigation-menu.cjs.entry.js.map +1 -1
  84. package/dist/cjs/ic-page-header.cjs.entry.js +10 -12
  85. package/dist/cjs/ic-page-header.cjs.entry.js.map +1 -1
  86. package/dist/cjs/ic-pagination_4.cjs.entry.js +226 -185
  87. package/dist/cjs/ic-pagination_4.cjs.entry.js.map +1 -1
  88. package/dist/cjs/ic-popover-menu.cjs.entry.js +15 -21
  89. package/dist/cjs/ic-popover-menu.cjs.entry.js.map +1 -1
  90. package/dist/cjs/ic-radio-group.cjs.entry.js +75 -51
  91. package/dist/cjs/ic-radio-group.cjs.entry.js.map +1 -1
  92. package/dist/cjs/ic-radio-option.cjs.entry.js +44 -53
  93. package/dist/cjs/ic-radio-option.cjs.entry.js.map +1 -1
  94. package/dist/cjs/ic-search-bar.cjs.entry.js +23 -30
  95. package/dist/cjs/ic-search-bar.cjs.entry.js.map +1 -1
  96. package/dist/cjs/ic-section-container.cjs.entry.js +1 -1
  97. package/dist/cjs/ic-section-container.cjs.entry.js.map +1 -1
  98. package/dist/cjs/ic-select-with-multi.cjs.entry.js +20 -69
  99. package/dist/cjs/ic-select-with-multi.cjs.entry.js.map +1 -1
  100. package/dist/cjs/ic-side-navigation.cjs.entry.js +8 -9
  101. package/dist/cjs/ic-side-navigation.cjs.entry.js.map +1 -1
  102. package/dist/cjs/ic-skeleton.cjs.entry.js +17 -37
  103. package/dist/cjs/ic-skeleton.cjs.entry.js.map +1 -1
  104. package/dist/cjs/ic-status-tag.cjs.entry.js +7 -15
  105. package/dist/cjs/ic-status-tag.cjs.entry.js.map +1 -1
  106. package/dist/cjs/ic-step.cjs.entry.js +42 -43
  107. package/dist/cjs/ic-step.cjs.entry.js.map +1 -1
  108. package/dist/cjs/ic-stepper.cjs.entry.js +45 -24
  109. package/dist/cjs/ic-stepper.cjs.entry.js.map +1 -1
  110. package/dist/cjs/ic-switch.cjs.entry.js +7 -9
  111. package/dist/cjs/ic-switch.cjs.entry.js.map +1 -1
  112. package/dist/cjs/ic-tab-context.cjs.entry.js +35 -18
  113. package/dist/cjs/ic-tab-context.cjs.entry.js.map +1 -1
  114. package/dist/cjs/ic-tab-group.cjs.entry.js +25 -11
  115. package/dist/cjs/ic-tab-group.cjs.entry.js.map +1 -1
  116. package/dist/cjs/ic-tab-panel.cjs.entry.js +6 -13
  117. package/dist/cjs/ic-tab-panel.cjs.entry.js.map +1 -1
  118. package/dist/cjs/ic-tab.cjs.entry.js +10 -9
  119. package/dist/cjs/ic-tab.cjs.entry.js.map +1 -1
  120. package/dist/cjs/ic-theme.cjs.entry.js +39 -25
  121. package/dist/cjs/ic-theme.cjs.entry.js.map +1 -1
  122. package/dist/cjs/ic-toast-region.cjs.entry.js +6 -7
  123. package/dist/cjs/ic-toast-region.cjs.entry.js.map +1 -1
  124. package/dist/cjs/ic-toast.cjs.entry.js +88 -35
  125. package/dist/cjs/ic-toast.cjs.entry.js.map +1 -1
  126. package/dist/cjs/ic-toggle-button-group.cjs.entry.js +17 -17
  127. package/dist/cjs/ic-toggle-button-group.cjs.entry.js.map +1 -1
  128. package/dist/cjs/ic-toggle-button.cjs.entry.js +15 -14
  129. package/dist/cjs/ic-toggle-button.cjs.entry.js.map +1 -1
  130. package/dist/cjs/ic-top-navigation.cjs.entry.js +62 -86
  131. package/dist/cjs/ic-top-navigation.cjs.entry.js.map +1 -1
  132. package/dist/cjs/ic-tree-item.cjs.entry.js +241 -0
  133. package/dist/cjs/ic-tree-item.cjs.entry.js.map +1 -0
  134. package/dist/cjs/ic-tree-view.cjs.entry.js +203 -0
  135. package/dist/cjs/ic-tree-view.cjs.entry.js.map +1 -0
  136. package/dist/cjs/ic-typography.cjs.entry.js +55 -19
  137. package/dist/cjs/ic-typography.cjs.entry.js.map +1 -1
  138. package/dist/cjs/index-4cf27b16.js +38 -18
  139. package/dist/cjs/loader.cjs.js +1 -1
  140. package/dist/collection/assets/arrow-dropdown.svg +3 -0
  141. package/dist/collection/assets/calendar.svg +3 -0
  142. package/dist/collection/collection-manifest.json +9 -3
  143. package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.css +661 -0
  144. package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.js +373 -0
  145. package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.js.map +1 -0
  146. package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.types.js +2 -0
  147. package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.types.js.map +1 -0
  148. package/dist/collection/components/ic-card-horizontal/test/basic/ic-card-horizontal.spec.js +130 -0
  149. package/dist/collection/components/ic-card-horizontal/test/basic/ic-card-horizontal.spec.js.map +1 -0
  150. package/dist/collection/components/ic-data-table/ic-data-table.css +155 -10
  151. package/dist/collection/components/ic-data-table/ic-data-table.js +1174 -90
  152. package/dist/collection/components/ic-data-table/ic-data-table.js.map +1 -1
  153. package/dist/collection/components/ic-data-table/ic-data-table.types.js.map +1 -1
  154. package/dist/collection/components/ic-data-table/story-data.js +758 -40
  155. package/dist/collection/components/ic-data-table/story-data.js.map +1 -1
  156. package/dist/collection/components/ic-data-table/test/basic/ic-data-table.spec.js +339 -3
  157. package/dist/collection/components/ic-data-table/test/basic/ic-data-table.spec.js.map +1 -1
  158. package/dist/collection/components/ic-data-table-title-bar/ic-data-table-title-bar.css +93 -0
  159. package/dist/collection/components/ic-data-table-title-bar/ic-data-table-title-bar.js +160 -0
  160. package/dist/collection/components/ic-data-table-title-bar/ic-data-table-title-bar.js.map +1 -0
  161. package/dist/collection/components/ic-data-table-title-bar/test/a11y/ic-data-table-title-bar.test.a11y.js +11 -0
  162. package/dist/collection/components/ic-data-table-title-bar/test/a11y/ic-data-table-title-bar.test.a11y.js.map +1 -0
  163. package/dist/collection/components/ic-data-table-title-bar/test/basic/ic-data-table-title-bar.spec.js +70 -0
  164. package/dist/collection/components/ic-data-table-title-bar/test/basic/ic-data-table-title-bar.spec.js.map +1 -0
  165. package/dist/collection/components/ic-date-input/ic-date-input.css +560 -0
  166. package/dist/collection/components/ic-date-input/ic-date-input.js +1775 -0
  167. package/dist/collection/components/ic-date-input/ic-date-input.js.map +1 -0
  168. package/dist/collection/components/ic-date-input/story-data.js +28 -0
  169. package/dist/collection/components/ic-date-input/story-data.js.map +1 -0
  170. package/dist/collection/components/ic-date-input/test/basic/ic-date-input.spec.js +1158 -0
  171. package/dist/collection/components/ic-date-input/test/basic/ic-date-input.spec.js.map +1 -0
  172. package/dist/collection/components/ic-date-input/test/helpers/ic-date-input.js +42 -0
  173. package/dist/collection/components/ic-date-input/test/helpers/ic-date-input.js.map +1 -0
  174. package/dist/collection/components/ic-date-picker/ic-date-picker.css +880 -0
  175. package/dist/collection/components/ic-date-picker/ic-date-picker.js +1566 -0
  176. package/dist/collection/components/ic-date-picker/ic-date-picker.js.map +1 -0
  177. package/dist/collection/components/ic-date-picker/ic-day-button.js +36 -0
  178. package/dist/collection/components/ic-date-picker/ic-day-button.js.map +1 -0
  179. package/dist/collection/components/ic-date-picker/ic-month-picker.js +29 -0
  180. package/dist/collection/components/ic-date-picker/ic-month-picker.js.map +1 -0
  181. package/dist/collection/components/ic-date-picker/ic-year-picker.js +39 -0
  182. package/dist/collection/components/ic-date-picker/ic-year-picker.js.map +1 -0
  183. package/dist/collection/components/ic-date-picker/story-data.js +148 -0
  184. package/dist/collection/components/ic-date-picker/story-data.js.map +1 -0
  185. package/dist/collection/components/ic-date-picker/test/a11y/ic-date-picker.test.a11y.js +13 -0
  186. package/dist/collection/components/ic-date-picker/test/a11y/ic-date-picker.test.a11y.js.map +1 -0
  187. package/dist/collection/components/ic-date-picker/test/basic/ic-date-picker-utils.spec.js +207 -0
  188. package/dist/collection/components/ic-date-picker/test/basic/ic-date-picker-utils.spec.js.map +1 -0
  189. package/dist/collection/components/ic-date-picker/test/basic/ic-date-picker.spec.js +1030 -0
  190. package/dist/collection/components/ic-date-picker/test/basic/ic-date-picker.spec.js.map +1 -0
  191. package/dist/collection/components/ic-menu-with-multi/ic-menu.css +25 -14
  192. package/dist/collection/components/ic-menu-with-multi/ic-menu.js +189 -71
  193. package/dist/collection/components/ic-menu-with-multi/ic-menu.js.map +1 -1
  194. package/dist/collection/components/ic-menu-with-multi/test/basic/ic-menu.spec.js +229 -52
  195. package/dist/collection/components/ic-menu-with-multi/test/basic/ic-menu.spec.js.map +1 -1
  196. package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.css +1 -1
  197. package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.js +173 -158
  198. package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.js.map +1 -1
  199. package/dist/collection/components/ic-pagination-bar/test/basic/ic-pagination-bar.spec.js +56 -11
  200. package/dist/collection/components/ic-pagination-bar/test/basic/ic-pagination-bar.spec.js.map +1 -1
  201. package/dist/collection/components/ic-select-with-multi/ic-select.css +14 -12
  202. package/dist/collection/components/ic-select-with-multi/ic-select.js +18 -147
  203. package/dist/collection/components/ic-select-with-multi/ic-select.js.map +1 -1
  204. package/dist/collection/components/ic-select-with-multi/test/basic/ic-select.spec.js +7 -7
  205. package/dist/collection/components/ic-select-with-multi/test/basic/ic-select.spec.js.map +1 -1
  206. package/dist/collection/components/ic-tree-item/ic-tree-item.css +172 -0
  207. package/dist/collection/components/ic-tree-item/ic-tree-item.js +592 -0
  208. package/dist/collection/components/ic-tree-item/ic-tree-item.js.map +1 -0
  209. package/dist/collection/components/ic-tree-item/test/basic/ic-tree-item.spec.js +114 -0
  210. package/dist/collection/components/ic-tree-item/test/basic/ic-tree-item.spec.js.map +1 -0
  211. package/dist/collection/components/ic-tree-view/ic-tree-view.css +59 -0
  212. package/dist/collection/components/ic-tree-view/ic-tree-view.js +296 -0
  213. package/dist/collection/components/ic-tree-view/ic-tree-view.js.map +1 -0
  214. package/dist/collection/components/ic-tree-view/test/basic/ic-tree-view.spec.js +85 -0
  215. package/dist/collection/components/ic-tree-view/test/basic/ic-tree-view.spec.js.map +1 -0
  216. package/dist/collection/utils/constants.js +55 -0
  217. package/dist/collection/utils/constants.js.map +1 -1
  218. package/dist/collection/utils/date-helpers.js +133 -0
  219. package/dist/collection/utils/date-helpers.js.map +1 -0
  220. package/dist/collection/utils/helpers.js +302 -10
  221. package/dist/collection/utils/helpers.js.map +1 -1
  222. package/dist/collection/utils/types.js +45 -0
  223. package/dist/collection/utils/types.js.map +1 -1
  224. package/dist/components/helpers.js +90 -91
  225. package/dist/components/helpers.js.map +1 -1
  226. package/dist/components/helpers2.js +197 -12
  227. package/dist/components/helpers2.js.map +1 -1
  228. package/dist/components/ic-accordion-group.js +39 -13
  229. package/dist/components/ic-accordion-group.js.map +1 -1
  230. package/dist/components/ic-accordion.js +6 -6
  231. package/dist/components/ic-accordion.js.map +1 -1
  232. package/dist/components/ic-alert.js +132 -1
  233. package/dist/components/ic-alert.js.map +1 -1
  234. package/dist/components/ic-back-to-top.js +37 -8
  235. package/dist/components/ic-back-to-top.js.map +1 -1
  236. package/dist/components/ic-badge.js +75 -121
  237. package/dist/components/ic-badge.js.map +1 -1
  238. package/dist/components/ic-breadcrumb-group.js +42 -10
  239. package/dist/components/ic-breadcrumb-group.js.map +1 -1
  240. package/dist/components/ic-breadcrumb2.js +10 -7
  241. package/dist/components/ic-breadcrumb2.js.map +1 -1
  242. package/dist/components/ic-button2.js +74 -102
  243. package/dist/components/ic-button2.js.map +1 -1
  244. package/dist/components/ic-card-horizontal.d.ts +11 -0
  245. package/dist/components/ic-card-horizontal.js +167 -0
  246. package/dist/components/ic-card-horizontal.js.map +1 -0
  247. package/dist/components/ic-card-vertical.js +194 -0
  248. package/dist/components/ic-card-vertical.js.map +1 -0
  249. package/dist/components/ic-checkbox-group.js +31 -21
  250. package/dist/components/ic-checkbox-group.js.map +1 -1
  251. package/dist/components/ic-checkbox.js +52 -47
  252. package/dist/components/ic-checkbox.js.map +1 -1
  253. package/dist/components/ic-chip.js +45 -31
  254. package/dist/components/ic-chip.js.map +1 -1
  255. package/dist/components/ic-classification-banner.js +14 -5
  256. package/dist/components/ic-classification-banner.js.map +1 -1
  257. package/dist/components/ic-data-list.js +56 -0
  258. package/dist/components/ic-data-list.js.map +1 -0
  259. package/dist/components/ic-data-row.js +14 -13
  260. package/dist/components/ic-data-row.js.map +1 -1
  261. package/dist/components/ic-data-table-title-bar.d.ts +11 -0
  262. package/dist/components/ic-data-table-title-bar.js +136 -0
  263. package/dist/components/ic-data-table-title-bar.js.map +1 -0
  264. package/dist/components/ic-data-table.js +841 -72
  265. package/dist/components/ic-data-table.js.map +1 -1
  266. package/dist/components/ic-date-input.d.ts +11 -0
  267. package/dist/components/ic-date-input.js +8 -0
  268. package/dist/components/ic-date-input.js.map +1 -0
  269. package/dist/components/ic-date-input2.js +1344 -0
  270. package/dist/components/ic-date-input2.js.map +1 -0
  271. package/dist/components/ic-date-picker.d.ts +11 -0
  272. package/dist/components/ic-date-picker.js +1194 -0
  273. package/dist/components/ic-date-picker.js.map +1 -0
  274. package/dist/components/ic-dialog.js +29 -115
  275. package/dist/components/ic-dialog.js.map +1 -1
  276. package/dist/components/ic-divider2.js +1 -2
  277. package/dist/components/ic-divider2.js.map +1 -1
  278. package/dist/components/ic-empty-state.js +1 -57
  279. package/dist/components/ic-empty-state.js.map +1 -1
  280. package/dist/components/ic-empty-state2.js +80 -0
  281. package/dist/components/ic-empty-state2.js.map +1 -0
  282. package/dist/components/ic-footer-link-group.js +10 -10
  283. package/dist/components/ic-footer-link-group.js.map +1 -1
  284. package/dist/components/ic-footer-link.js +13 -8
  285. package/dist/components/ic-footer-link.js.map +1 -1
  286. package/dist/components/ic-footer.js +9 -10
  287. package/dist/components/ic-footer.js.map +1 -1
  288. package/dist/components/ic-hero.js +28 -14
  289. package/dist/components/ic-hero.js.map +1 -1
  290. package/dist/components/ic-horizontal-scroll2.js +6 -8
  291. package/dist/components/ic-horizontal-scroll2.js.map +1 -1
  292. package/dist/components/ic-input-component-container2.js +26 -21
  293. package/dist/components/ic-input-component-container2.js.map +1 -1
  294. package/dist/components/ic-input-label2.js +9 -11
  295. package/dist/components/ic-input-label2.js.map +1 -1
  296. package/dist/components/ic-input-validation2.js +4 -5
  297. package/dist/components/ic-input-validation2.js.map +1 -1
  298. package/dist/components/ic-link2.js +54 -27
  299. package/dist/components/ic-link2.js.map +1 -1
  300. package/dist/components/ic-loading-indicator2.js +23 -19
  301. package/dist/components/ic-loading-indicator2.js.map +1 -1
  302. package/dist/components/ic-menu-group.js +2 -2
  303. package/dist/components/ic-menu-group.js.map +1 -1
  304. package/dist/components/ic-menu-item2.js +6 -12
  305. package/dist/components/ic-menu-item2.js.map +1 -1
  306. package/dist/components/ic-menu2.js +15 -20
  307. package/dist/components/ic-menu2.js.map +1 -1
  308. package/dist/components/ic-menu3.js +187 -49
  309. package/dist/components/ic-menu3.js.map +1 -1
  310. package/dist/components/ic-navigation-button.js +28 -8
  311. package/dist/components/ic-navigation-button.js.map +1 -1
  312. package/dist/components/ic-navigation-group.js +23 -20
  313. package/dist/components/ic-navigation-group.js.map +1 -1
  314. package/dist/components/ic-navigation-item.js +33 -37
  315. package/dist/components/ic-navigation-item.js.map +1 -1
  316. package/dist/components/ic-navigation-menu2.js +3 -3
  317. package/dist/components/ic-navigation-menu2.js.map +1 -1
  318. package/dist/components/ic-page-header.js +9 -11
  319. package/dist/components/ic-page-header.js.map +1 -1
  320. package/dist/components/ic-pagination-bar2.js +154 -143
  321. package/dist/components/ic-pagination-bar2.js.map +1 -1
  322. package/dist/components/ic-pagination-item2.js +22 -12
  323. package/dist/components/ic-pagination-item2.js.map +1 -1
  324. package/dist/components/ic-pagination2.js +50 -33
  325. package/dist/components/ic-pagination2.js.map +1 -1
  326. package/dist/components/ic-popover-menu.js +15 -20
  327. package/dist/components/ic-popover-menu.js.map +1 -1
  328. package/dist/components/ic-radio-group.js +76 -51
  329. package/dist/components/ic-radio-group.js.map +1 -1
  330. package/dist/components/ic-radio-option.js +47 -60
  331. package/dist/components/ic-radio-option.js.map +1 -1
  332. package/dist/components/ic-search-bar.js +21 -29
  333. package/dist/components/ic-search-bar.js.map +1 -1
  334. package/dist/components/ic-section-container2.js +1 -1
  335. package/dist/components/ic-section-container2.js.map +1 -1
  336. package/dist/components/ic-select-with-multi.js +15 -71
  337. package/dist/components/ic-select-with-multi.js.map +1 -1
  338. package/dist/components/ic-select2.js +59 -42
  339. package/dist/components/ic-select2.js.map +1 -1
  340. package/dist/components/ic-side-navigation.js +8 -9
  341. package/dist/components/ic-side-navigation.js.map +1 -1
  342. package/dist/components/ic-skeleton.js +18 -43
  343. package/dist/components/ic-skeleton.js.map +1 -1
  344. package/dist/components/ic-status-tag.js +7 -15
  345. package/dist/components/ic-status-tag.js.map +1 -1
  346. package/dist/components/ic-step.js +48 -48
  347. package/dist/components/ic-step.js.map +1 -1
  348. package/dist/components/ic-stepper.js +49 -23
  349. package/dist/components/ic-stepper.js.map +1 -1
  350. package/dist/components/ic-switch.js +7 -9
  351. package/dist/components/ic-switch.js.map +1 -1
  352. package/dist/components/ic-tab-context.js +40 -20
  353. package/dist/components/ic-tab-context.js.map +1 -1
  354. package/dist/components/ic-tab-group.js +27 -13
  355. package/dist/components/ic-tab-group.js.map +1 -1
  356. package/dist/components/ic-tab-panel.js +9 -16
  357. package/dist/components/ic-tab-panel.js.map +1 -1
  358. package/dist/components/ic-tab.js +12 -10
  359. package/dist/components/ic-tab.js.map +1 -1
  360. package/dist/components/ic-text-field2.js +104 -113
  361. package/dist/components/ic-text-field2.js.map +1 -1
  362. package/dist/components/ic-theme.js +45 -28
  363. package/dist/components/ic-theme.js.map +1 -1
  364. package/dist/components/ic-toast-region.js +7 -9
  365. package/dist/components/ic-toast-region.js.map +1 -1
  366. package/dist/components/ic-toast.js +93 -36
  367. package/dist/components/ic-toast.js.map +1 -1
  368. package/dist/components/ic-toggle-button-group.js +17 -17
  369. package/dist/components/ic-toggle-button-group.js.map +1 -1
  370. package/dist/components/ic-toggle-button.js +16 -14
  371. package/dist/components/ic-toggle-button.js.map +1 -1
  372. package/dist/components/ic-tooltip2.js +31 -9
  373. package/dist/components/ic-tooltip2.js.map +1 -1
  374. package/dist/components/ic-top-navigation.js +63 -87
  375. package/dist/components/ic-top-navigation.js.map +1 -1
  376. package/dist/components/ic-tree-item.d.ts +11 -0
  377. package/dist/components/ic-tree-item.js +286 -0
  378. package/dist/components/ic-tree-item.js.map +1 -0
  379. package/dist/components/ic-tree-view.d.ts +11 -0
  380. package/dist/components/ic-tree-view.js +237 -0
  381. package/dist/components/ic-tree-view.js.map +1 -0
  382. package/dist/components/ic-typography2.js +62 -21
  383. package/dist/components/ic-typography2.js.map +1 -1
  384. package/dist/core/core.css +38 -20
  385. package/dist/core/core.esm.js +1 -1
  386. package/dist/core/core.esm.js.map +1 -1
  387. package/dist/core/p-06eeb7f2.entry.js +2 -0
  388. package/dist/core/p-06eeb7f2.entry.js.map +1 -0
  389. package/dist/core/p-0922c552.entry.js +2 -0
  390. package/dist/core/p-0922c552.entry.js.map +1 -0
  391. package/dist/core/p-0bc0e852.entry.js +2 -0
  392. package/dist/core/p-0bc0e852.entry.js.map +1 -0
  393. package/dist/core/p-108a9029.entry.js +2 -0
  394. package/dist/core/p-108a9029.entry.js.map +1 -0
  395. package/dist/core/p-13100d3c.entry.js +2 -0
  396. package/dist/core/p-13100d3c.entry.js.map +1 -0
  397. package/dist/core/p-1769df1d.entry.js +2 -0
  398. package/dist/core/p-1769df1d.entry.js.map +1 -0
  399. package/dist/core/p-202bc922.entry.js +2 -0
  400. package/dist/core/p-202bc922.entry.js.map +1 -0
  401. package/dist/core/p-266341f5.entry.js +2 -0
  402. package/dist/core/p-266341f5.entry.js.map +1 -0
  403. package/dist/core/p-297e99cf.js +2 -0
  404. package/dist/core/p-297e99cf.js.map +1 -0
  405. package/dist/core/p-306def43.entry.js +2 -0
  406. package/dist/core/p-306def43.entry.js.map +1 -0
  407. package/dist/core/p-30b046b2.entry.js +2 -0
  408. package/dist/core/p-30b046b2.entry.js.map +1 -0
  409. package/dist/core/p-33dd24eb.js +2 -0
  410. package/dist/core/p-33dd24eb.js.map +1 -0
  411. package/dist/core/p-3778cc5e.entry.js +2 -0
  412. package/dist/core/p-3778cc5e.entry.js.map +1 -0
  413. package/dist/core/p-383a5a76.entry.js +2 -0
  414. package/dist/core/p-383a5a76.entry.js.map +1 -0
  415. package/dist/core/p-3a0510e2.entry.js +2 -0
  416. package/dist/core/p-3a0510e2.entry.js.map +1 -0
  417. package/dist/core/p-3ace51f5.entry.js +2 -0
  418. package/dist/core/p-3ace51f5.entry.js.map +1 -0
  419. package/dist/core/p-3ef28704.entry.js +2 -0
  420. package/dist/core/p-3ef28704.entry.js.map +1 -0
  421. package/dist/core/p-3f0391c1.entry.js +2 -0
  422. package/dist/core/p-3f0391c1.entry.js.map +1 -0
  423. package/dist/core/p-41fecc61.entry.js +2 -0
  424. package/dist/core/p-41fecc61.entry.js.map +1 -0
  425. package/dist/core/p-46cb94a2.entry.js +2 -0
  426. package/dist/core/p-46cb94a2.entry.js.map +1 -0
  427. package/dist/core/p-4e67f127.entry.js +2 -0
  428. package/dist/core/p-4e67f127.entry.js.map +1 -0
  429. package/dist/core/p-505250cf.entry.js +2 -0
  430. package/dist/core/p-505250cf.entry.js.map +1 -0
  431. package/dist/core/p-50e48f4d.entry.js +2 -0
  432. package/dist/core/p-50e48f4d.entry.js.map +1 -0
  433. package/dist/core/p-56e7459a.entry.js +2 -0
  434. package/dist/core/p-56e7459a.entry.js.map +1 -0
  435. package/dist/core/p-59028160.entry.js +2 -0
  436. package/dist/core/p-59028160.entry.js.map +1 -0
  437. package/dist/core/p-5cfb5821.entry.js +2 -0
  438. package/dist/core/p-5cfb5821.entry.js.map +1 -0
  439. package/dist/core/p-5e6fd734.entry.js +2 -0
  440. package/dist/core/p-5e6fd734.entry.js.map +1 -0
  441. package/dist/core/p-5f313e1a.entry.js +2 -0
  442. package/dist/core/p-5f313e1a.entry.js.map +1 -0
  443. package/dist/core/{p-c2b5e7b1.entry.js → p-5f5403e2.entry.js} +2 -2
  444. package/dist/core/{p-c2b5e7b1.entry.js.map → p-5f5403e2.entry.js.map} +1 -1
  445. package/dist/core/p-710c6a42.entry.js +2 -0
  446. package/dist/core/p-710c6a42.entry.js.map +1 -0
  447. package/dist/core/p-73b40c79.entry.js +2 -0
  448. package/dist/core/p-73b40c79.entry.js.map +1 -0
  449. package/dist/core/p-77a32de5.entry.js +2 -0
  450. package/dist/core/p-77a32de5.entry.js.map +1 -0
  451. package/dist/core/p-7a9de008.entry.js +2 -0
  452. package/dist/core/p-7a9de008.entry.js.map +1 -0
  453. package/dist/core/p-801414e2.entry.js +2 -0
  454. package/dist/core/p-801414e2.entry.js.map +1 -0
  455. package/dist/core/p-82ba744d.entry.js +2 -0
  456. package/dist/core/p-82ba744d.entry.js.map +1 -0
  457. package/dist/core/p-897b8d16.entry.js +2 -0
  458. package/dist/core/p-897b8d16.entry.js.map +1 -0
  459. package/dist/core/p-9397b15b.js +2 -0
  460. package/dist/core/p-9397b15b.js.map +1 -0
  461. package/dist/core/p-9af6adb1.entry.js +2 -0
  462. package/dist/core/p-9af6adb1.entry.js.map +1 -0
  463. package/dist/core/p-9b54feca.entry.js +2 -0
  464. package/dist/core/p-9b54feca.entry.js.map +1 -0
  465. package/dist/core/{p-356b8a4c.entry.js → p-9f3cf053.entry.js} +2 -2
  466. package/dist/core/{p-356b8a4c.entry.js.map → p-9f3cf053.entry.js.map} +1 -1
  467. package/dist/core/p-a57cd616.entry.js +2 -0
  468. package/dist/core/p-a57cd616.entry.js.map +1 -0
  469. package/dist/core/p-a5eaed1a.entry.js +2 -0
  470. package/dist/core/p-a5eaed1a.entry.js.map +1 -0
  471. package/dist/core/p-a78cf2cb.entry.js +2 -0
  472. package/dist/core/p-a78cf2cb.entry.js.map +1 -0
  473. package/dist/core/p-a91340b4.entry.js +2 -0
  474. package/dist/core/p-a91340b4.entry.js.map +1 -0
  475. package/dist/core/p-aee8d45b.entry.js +2 -0
  476. package/dist/core/p-aee8d45b.entry.js.map +1 -0
  477. package/dist/core/{p-452985d9.entry.js → p-b40ecaef.entry.js} +2 -2
  478. package/dist/core/p-b40ecaef.entry.js.map +1 -0
  479. package/dist/core/p-badd4c8d.entry.js +2 -0
  480. package/dist/core/p-badd4c8d.entry.js.map +1 -0
  481. package/dist/core/p-bf670360.entry.js +2 -0
  482. package/dist/core/{p-a434c3d4.entry.js.map → p-bf670360.entry.js.map} +1 -1
  483. package/dist/core/p-c033e7d6.entry.js +2 -0
  484. package/dist/core/p-c033e7d6.entry.js.map +1 -0
  485. package/dist/core/p-c07af2d8.entry.js +2 -0
  486. package/dist/core/p-c07af2d8.entry.js.map +1 -0
  487. package/dist/core/p-c21d0db8.entry.js +2 -0
  488. package/dist/core/p-c21d0db8.entry.js.map +1 -0
  489. package/dist/core/p-c678f73d.entry.js +2 -0
  490. package/dist/core/p-c678f73d.entry.js.map +1 -0
  491. package/dist/core/p-c6ae9bad.entry.js +2 -0
  492. package/dist/core/p-c6ae9bad.entry.js.map +1 -0
  493. package/dist/core/p-c6c1e08e.entry.js +2 -0
  494. package/dist/core/p-c6c1e08e.entry.js.map +1 -0
  495. package/dist/core/p-cb6cebdd.entry.js +2 -0
  496. package/dist/core/p-cb6cebdd.entry.js.map +1 -0
  497. package/dist/core/p-d03374fc.entry.js +2 -0
  498. package/dist/core/p-d03374fc.entry.js.map +1 -0
  499. package/dist/core/p-d16f364a.entry.js +2 -0
  500. package/dist/core/p-d16f364a.entry.js.map +1 -0
  501. package/dist/core/p-d239c33b.entry.js +2 -0
  502. package/dist/core/p-d239c33b.entry.js.map +1 -0
  503. package/dist/core/p-d8563643.entry.js +2 -0
  504. package/dist/core/p-d8563643.entry.js.map +1 -0
  505. package/dist/core/p-da40757f.entry.js +2 -0
  506. package/dist/core/p-da40757f.entry.js.map +1 -0
  507. package/dist/core/p-de052137.entry.js +2 -0
  508. package/dist/core/p-de052137.entry.js.map +1 -0
  509. package/dist/core/p-e5d99316.entry.js +2 -0
  510. package/dist/core/p-e5d99316.entry.js.map +1 -0
  511. package/dist/core/p-e89bb650.entry.js +2 -0
  512. package/dist/core/p-e89bb650.entry.js.map +1 -0
  513. package/dist/core/{p-baf81f30.entry.js → p-f1072c28.entry.js} +2 -2
  514. package/dist/core/{p-452985d9.entry.js.map → p-f1072c28.entry.js.map} +1 -1
  515. package/dist/core/p-f37df214.entry.js +2 -0
  516. package/dist/core/{p-c34848da.entry.js.map → p-f37df214.entry.js.map} +1 -1
  517. package/dist/core/p-f743b0eb.entry.js +2 -0
  518. package/dist/core/p-f743b0eb.entry.js.map +1 -0
  519. package/dist/core/p-f98b1afc.entry.js +2 -0
  520. package/dist/core/p-f98b1afc.entry.js.map +1 -0
  521. package/dist/core/p-fe13f1ba.entry.js +2 -0
  522. package/dist/core/p-fe13f1ba.entry.js.map +1 -0
  523. package/dist/esm/core.js +1 -1
  524. package/dist/esm/date-helpers-0e5e32a7.js +136 -0
  525. package/dist/esm/date-helpers-0e5e32a7.js.map +1 -0
  526. package/dist/esm/helpers-5bd2012a.js +368 -0
  527. package/dist/esm/helpers-5bd2012a.js.map +1 -0
  528. package/dist/esm/{helpers-12b4266a.js → helpers-dab8ddfe.js} +91 -92
  529. package/dist/esm/helpers-dab8ddfe.js.map +1 -0
  530. package/dist/esm/ic-accordion-group.entry.js +31 -9
  531. package/dist/esm/ic-accordion-group.entry.js.map +1 -1
  532. package/dist/esm/ic-accordion.entry.js +7 -8
  533. package/dist/esm/ic-accordion.entry.js.map +1 -1
  534. package/dist/esm/ic-alert.entry.js +27 -9
  535. package/dist/esm/ic-alert.entry.js.map +1 -1
  536. package/dist/esm/ic-back-to-top.entry.js +17 -8
  537. package/dist/esm/ic-back-to-top.entry.js.map +1 -1
  538. package/dist/esm/ic-badge.entry.js +67 -117
  539. package/dist/esm/ic-badge.entry.js.map +1 -1
  540. package/dist/esm/ic-breadcrumb-group.entry.js +37 -11
  541. package/dist/esm/ic-breadcrumb-group.entry.js.map +1 -1
  542. package/dist/esm/ic-breadcrumb.entry.js +8 -7
  543. package/dist/esm/ic-breadcrumb.entry.js.map +1 -1
  544. package/dist/esm/ic-button_3.entry.js +118 -125
  545. package/dist/esm/ic-button_3.entry.js.map +1 -1
  546. package/dist/esm/ic-card-horizontal.entry.js +127 -0
  547. package/dist/esm/ic-card-horizontal.entry.js.map +1 -0
  548. package/dist/esm/ic-card-vertical.entry.js +145 -0
  549. package/dist/esm/ic-card-vertical.entry.js.map +1 -0
  550. package/dist/esm/ic-checkbox-group.entry.js +27 -20
  551. package/dist/esm/ic-checkbox-group.entry.js.map +1 -1
  552. package/dist/esm/ic-checkbox.entry.js +45 -40
  553. package/dist/esm/ic-checkbox.entry.js.map +1 -1
  554. package/dist/esm/ic-chip.entry.js +40 -29
  555. package/dist/esm/ic-chip.entry.js.map +1 -1
  556. package/dist/esm/ic-classification-banner.entry.js +14 -5
  557. package/dist/esm/ic-classification-banner.entry.js.map +1 -1
  558. package/dist/esm/ic-data-list.entry.js +28 -0
  559. package/dist/esm/ic-data-list.entry.js.map +1 -0
  560. package/dist/esm/ic-data-row.entry.js +12 -12
  561. package/dist/esm/ic-data-row.entry.js.map +1 -1
  562. package/dist/esm/ic-data-table-title-bar.entry.js +53 -0
  563. package/dist/esm/ic-data-table-title-bar.entry.js.map +1 -0
  564. package/dist/esm/ic-data-table.entry.js +806 -66
  565. package/dist/esm/ic-data-table.entry.js.map +1 -1
  566. package/dist/esm/ic-date-input.entry.js +1106 -0
  567. package/dist/esm/ic-date-input.entry.js.map +1 -0
  568. package/dist/esm/ic-date-picker.entry.js +1065 -0
  569. package/dist/esm/ic-date-picker.entry.js.map +1 -0
  570. package/dist/esm/ic-dialog.entry.js +27 -101
  571. package/dist/esm/ic-dialog.entry.js.map +1 -1
  572. package/dist/esm/ic-divider.entry.js +1 -2
  573. package/dist/esm/ic-divider.entry.js.map +1 -1
  574. package/dist/esm/ic-empty-state_2.entry.js +312 -0
  575. package/dist/esm/ic-empty-state_2.entry.js.map +1 -0
  576. package/dist/esm/ic-footer-link-group.entry.js +9 -10
  577. package/dist/esm/ic-footer-link-group.entry.js.map +1 -1
  578. package/dist/esm/ic-footer-link.entry.js +6 -8
  579. package/dist/esm/ic-footer-link.entry.js.map +1 -1
  580. package/dist/esm/ic-footer.entry.js +9 -10
  581. package/dist/esm/ic-footer.entry.js.map +1 -1
  582. package/dist/esm/ic-hero.entry.js +28 -13
  583. package/dist/esm/ic-hero.entry.js.map +1 -1
  584. package/dist/esm/ic-horizontal-scroll.entry.js +6 -8
  585. package/dist/esm/ic-horizontal-scroll.entry.js.map +1 -1
  586. package/dist/esm/ic-input-component-container_4.entry.js +149 -0
  587. package/dist/esm/ic-input-component-container_4.entry.js.map +1 -0
  588. package/dist/esm/ic-link.entry.js +52 -25
  589. package/dist/esm/ic-link.entry.js.map +1 -1
  590. package/dist/esm/ic-menu-group.entry.js +2 -3
  591. package/dist/esm/ic-menu-group.entry.js.map +1 -1
  592. package/dist/esm/ic-menu-item.entry.js +6 -13
  593. package/dist/esm/ic-menu-item.entry.js.map +1 -1
  594. package/dist/esm/ic-menu-with-multi.entry.js +186 -47
  595. package/dist/esm/ic-menu-with-multi.entry.js.map +1 -1
  596. package/dist/esm/{ic-input-component-container_3.entry.js → ic-menu.entry.js} +19 -86
  597. package/dist/esm/ic-menu.entry.js.map +1 -0
  598. package/dist/esm/ic-navigation-button.entry.js +28 -8
  599. package/dist/esm/ic-navigation-button.entry.js.map +1 -1
  600. package/dist/esm/ic-navigation-group.entry.js +23 -21
  601. package/dist/esm/ic-navigation-group.entry.js.map +1 -1
  602. package/dist/esm/ic-navigation-item.entry.js +33 -38
  603. package/dist/esm/ic-navigation-item.entry.js.map +1 -1
  604. package/dist/esm/ic-navigation-menu.entry.js +3 -4
  605. package/dist/esm/ic-navigation-menu.entry.js.map +1 -1
  606. package/dist/esm/ic-page-header.entry.js +10 -12
  607. package/dist/esm/ic-page-header.entry.js.map +1 -1
  608. package/dist/esm/ic-pagination_4.entry.js +219 -178
  609. package/dist/esm/ic-pagination_4.entry.js.map +1 -1
  610. package/dist/esm/ic-popover-menu.entry.js +15 -21
  611. package/dist/esm/ic-popover-menu.entry.js.map +1 -1
  612. package/dist/esm/ic-radio-group.entry.js +75 -51
  613. package/dist/esm/ic-radio-group.entry.js.map +1 -1
  614. package/dist/esm/ic-radio-option.entry.js +44 -53
  615. package/dist/esm/ic-radio-option.entry.js.map +1 -1
  616. package/dist/esm/ic-search-bar.entry.js +19 -26
  617. package/dist/esm/ic-search-bar.entry.js.map +1 -1
  618. package/dist/esm/ic-section-container.entry.js +1 -1
  619. package/dist/esm/ic-section-container.entry.js.map +1 -1
  620. package/dist/esm/ic-select-with-multi.entry.js +14 -63
  621. package/dist/esm/ic-select-with-multi.entry.js.map +1 -1
  622. package/dist/esm/ic-side-navigation.entry.js +8 -9
  623. package/dist/esm/ic-side-navigation.entry.js.map +1 -1
  624. package/dist/esm/ic-skeleton.entry.js +17 -37
  625. package/dist/esm/ic-skeleton.entry.js.map +1 -1
  626. package/dist/esm/ic-status-tag.entry.js +7 -15
  627. package/dist/esm/ic-status-tag.entry.js.map +1 -1
  628. package/dist/esm/ic-step.entry.js +42 -43
  629. package/dist/esm/ic-step.entry.js.map +1 -1
  630. package/dist/esm/ic-stepper.entry.js +45 -24
  631. package/dist/esm/ic-stepper.entry.js.map +1 -1
  632. package/dist/esm/ic-switch.entry.js +7 -9
  633. package/dist/esm/ic-switch.entry.js.map +1 -1
  634. package/dist/esm/ic-tab-context.entry.js +35 -18
  635. package/dist/esm/ic-tab-context.entry.js.map +1 -1
  636. package/dist/esm/ic-tab-group.entry.js +25 -11
  637. package/dist/esm/ic-tab-group.entry.js.map +1 -1
  638. package/dist/esm/ic-tab-panel.entry.js +6 -13
  639. package/dist/esm/ic-tab-panel.entry.js.map +1 -1
  640. package/dist/esm/ic-tab.entry.js +10 -9
  641. package/dist/esm/ic-tab.entry.js.map +1 -1
  642. package/dist/esm/ic-theme.entry.js +39 -25
  643. package/dist/esm/ic-theme.entry.js.map +1 -1
  644. package/dist/esm/ic-toast-region.entry.js +6 -7
  645. package/dist/esm/ic-toast-region.entry.js.map +1 -1
  646. package/dist/esm/ic-toast.entry.js +88 -35
  647. package/dist/esm/ic-toast.entry.js.map +1 -1
  648. package/dist/esm/ic-toggle-button-group.entry.js +17 -17
  649. package/dist/esm/ic-toggle-button-group.entry.js.map +1 -1
  650. package/dist/esm/ic-toggle-button.entry.js +15 -14
  651. package/dist/esm/ic-toggle-button.entry.js.map +1 -1
  652. package/dist/esm/ic-top-navigation.entry.js +62 -86
  653. package/dist/esm/ic-top-navigation.entry.js.map +1 -1
  654. package/dist/esm/ic-tree-item.entry.js +237 -0
  655. package/dist/esm/ic-tree-item.entry.js.map +1 -0
  656. package/dist/esm/ic-tree-view.entry.js +199 -0
  657. package/dist/esm/ic-tree-view.entry.js.map +1 -0
  658. package/dist/esm/ic-typography.entry.js +56 -20
  659. package/dist/esm/ic-typography.entry.js.map +1 -1
  660. package/dist/esm/index-93509377.js +38 -18
  661. package/dist/esm/loader.js +1 -1
  662. package/dist/types/components/ic-card-horizontal/ic-card-horizontal.d.ts +71 -0
  663. package/dist/types/components/ic-card-horizontal/ic-card-horizontal.types.d.ts +1 -0
  664. package/dist/types/components/ic-data-table/ic-data-table.d.ts +176 -19
  665. package/dist/types/components/ic-data-table/ic-data-table.types.d.ts +30 -0
  666. package/dist/types/components/ic-data-table/story-data.d.ts +236 -3
  667. package/dist/types/components/ic-data-table-title-bar/ic-data-table-title-bar.d.ts +36 -0
  668. package/dist/types/components/ic-date-input/ic-date-input.d.ts +259 -0
  669. package/dist/types/components/ic-date-input/story-data.d.ts +1 -0
  670. package/dist/types/components/ic-date-input/test/helpers/ic-date-input.d.ts +23 -0
  671. package/dist/types/components/ic-date-picker/ic-date-picker.d.ts +240 -0
  672. package/dist/types/components/ic-date-picker/ic-day-button.d.ts +16 -0
  673. package/dist/types/components/ic-date-picker/ic-month-picker.d.ts +14 -0
  674. package/dist/types/components/ic-date-picker/ic-year-picker.d.ts +16 -0
  675. package/dist/types/components/ic-date-picker/story-data.d.ts +22 -0
  676. package/dist/types/components/ic-date-picker/test/a11y/ic-date-picker.test.a11y.d.ts +1 -0
  677. package/dist/types/components/ic-menu-with-multi/ic-menu.d.ts +12 -6
  678. package/dist/types/components/ic-pagination-bar/ic-pagination-bar.d.ts +37 -18
  679. package/dist/types/components/ic-select-with-multi/ic-select.d.ts +3 -33
  680. package/dist/types/components/ic-tree-item/ic-tree-item.d.ts +95 -0
  681. package/dist/types/components/ic-tree-view/ic-tree-view.d.ts +40 -0
  682. package/dist/types/components.d.ts +978 -114
  683. package/dist/types/interface.d.ts +1 -0
  684. package/dist/types/utils/constants.d.ts +37 -0
  685. package/dist/types/utils/date-helpers.d.ts +22 -0
  686. package/dist/types/utils/helpers.d.ts +92 -11
  687. package/dist/types/utils/types.d.ts +108 -1
  688. package/hydrate/index.js +6683 -2381
  689. package/package.json +6 -6
  690. package/dist/cjs/helpers-93c5fc92.js.map +0 -1
  691. package/dist/cjs/helpers-b525d45a.js.map +0 -1
  692. package/dist/cjs/ic-card.cjs.entry.js +0 -126
  693. package/dist/cjs/ic-card.cjs.entry.js.map +0 -1
  694. package/dist/cjs/ic-data-entity.cjs.entry.js +0 -29
  695. package/dist/cjs/ic-data-entity.cjs.entry.js.map +0 -1
  696. package/dist/cjs/ic-empty-state.cjs.entry.js +0 -38
  697. package/dist/cjs/ic-empty-state.cjs.entry.js.map +0 -1
  698. package/dist/cjs/ic-input-component-container_3.cjs.entry.js.map +0 -1
  699. package/dist/cjs/ic-input-label_2.cjs.entry.js +0 -86
  700. package/dist/cjs/ic-input-label_2.cjs.entry.js.map +0 -1
  701. package/dist/cjs/ic-pagination-bar.cjs.entry.js +0 -269
  702. package/dist/cjs/ic-pagination-bar.cjs.entry.js.map +0 -1
  703. package/dist/cjs/types-17dba796.js +0 -16
  704. package/dist/cjs/types-17dba796.js.map +0 -1
  705. package/dist/collection/components/ic-pagination/ic-pagination.types.js +0 -2
  706. package/dist/collection/components/ic-pagination/ic-pagination.types.js.map +0 -1
  707. package/dist/collection/components/ic-select-with-multi/test/a11y/ic-select.test.a11y.js +0 -146
  708. package/dist/collection/components/ic-select-with-multi/test/a11y/ic-select.test.a11y.js.map +0 -1
  709. package/dist/collection/components/ic-select-with-multi/test/basic/ic-select.e2e.js +0 -2040
  710. package/dist/collection/components/ic-select-with-multi/test/basic/ic-select.e2e.js.map +0 -1
  711. package/dist/components/ic-alert2.js +0 -117
  712. package/dist/components/ic-alert2.js.map +0 -1
  713. package/dist/components/ic-card.js +0 -171
  714. package/dist/components/ic-card.js.map +0 -1
  715. package/dist/components/ic-data-entity.js +0 -53
  716. package/dist/components/ic-data-entity.js.map +0 -1
  717. package/dist/components/types.js +0 -16
  718. package/dist/components/types.js.map +0 -1
  719. package/dist/core/p-045359e1.entry.js +0 -2
  720. package/dist/core/p-045359e1.entry.js.map +0 -1
  721. package/dist/core/p-10fb4c46.entry.js +0 -2
  722. package/dist/core/p-10fb4c46.entry.js.map +0 -1
  723. package/dist/core/p-169bfa51.entry.js +0 -2
  724. package/dist/core/p-169bfa51.entry.js.map +0 -1
  725. package/dist/core/p-1ca332ca.entry.js +0 -2
  726. package/dist/core/p-1ca332ca.entry.js.map +0 -1
  727. package/dist/core/p-204ace96.entry.js +0 -2
  728. package/dist/core/p-204ace96.entry.js.map +0 -1
  729. package/dist/core/p-21150122.entry.js +0 -2
  730. package/dist/core/p-21150122.entry.js.map +0 -1
  731. package/dist/core/p-2eac7dcc.entry.js +0 -2
  732. package/dist/core/p-2eac7dcc.entry.js.map +0 -1
  733. package/dist/core/p-3803a5b5.entry.js +0 -2
  734. package/dist/core/p-3803a5b5.entry.js.map +0 -1
  735. package/dist/core/p-4753bac8.entry.js +0 -2
  736. package/dist/core/p-4753bac8.entry.js.map +0 -1
  737. package/dist/core/p-4baa0916.entry.js +0 -2
  738. package/dist/core/p-4baa0916.entry.js.map +0 -1
  739. package/dist/core/p-4f413fc0.entry.js +0 -2
  740. package/dist/core/p-4f413fc0.entry.js.map +0 -1
  741. package/dist/core/p-595be57d.entry.js +0 -2
  742. package/dist/core/p-595be57d.entry.js.map +0 -1
  743. package/dist/core/p-5ae93c16.entry.js +0 -2
  744. package/dist/core/p-5ae93c16.entry.js.map +0 -1
  745. package/dist/core/p-5e0c830b.entry.js +0 -2
  746. package/dist/core/p-5e0c830b.entry.js.map +0 -1
  747. package/dist/core/p-624d4f5f.entry.js +0 -2
  748. package/dist/core/p-624d4f5f.entry.js.map +0 -1
  749. package/dist/core/p-6933f8e9.entry.js +0 -2
  750. package/dist/core/p-6933f8e9.entry.js.map +0 -1
  751. package/dist/core/p-6c3044b6.entry.js +0 -2
  752. package/dist/core/p-6c3044b6.entry.js.map +0 -1
  753. package/dist/core/p-73be1251.entry.js +0 -2
  754. package/dist/core/p-73be1251.entry.js.map +0 -1
  755. package/dist/core/p-75dac3d1.entry.js +0 -2
  756. package/dist/core/p-75dac3d1.entry.js.map +0 -1
  757. package/dist/core/p-76915584.entry.js +0 -2
  758. package/dist/core/p-76915584.entry.js.map +0 -1
  759. package/dist/core/p-7ef8d616.entry.js +0 -2
  760. package/dist/core/p-7ef8d616.entry.js.map +0 -1
  761. package/dist/core/p-81ddc39d.entry.js +0 -2
  762. package/dist/core/p-81ddc39d.entry.js.map +0 -1
  763. package/dist/core/p-869954a2.entry.js +0 -2
  764. package/dist/core/p-869954a2.entry.js.map +0 -1
  765. package/dist/core/p-88d54b72.entry.js +0 -2
  766. package/dist/core/p-88d54b72.entry.js.map +0 -1
  767. package/dist/core/p-8b08d8fe.entry.js +0 -2
  768. package/dist/core/p-8b08d8fe.entry.js.map +0 -1
  769. package/dist/core/p-917c5721.entry.js +0 -2
  770. package/dist/core/p-917c5721.entry.js.map +0 -1
  771. package/dist/core/p-942282cd.entry.js +0 -2
  772. package/dist/core/p-942282cd.entry.js.map +0 -1
  773. package/dist/core/p-9777ebb1.entry.js +0 -2
  774. package/dist/core/p-9777ebb1.entry.js.map +0 -1
  775. package/dist/core/p-99cad6c2.js +0 -2
  776. package/dist/core/p-99cad6c2.js.map +0 -1
  777. package/dist/core/p-9caf19eb.js +0 -2
  778. package/dist/core/p-9caf19eb.js.map +0 -1
  779. package/dist/core/p-a0f8efb2.entry.js +0 -2
  780. package/dist/core/p-a0f8efb2.entry.js.map +0 -1
  781. package/dist/core/p-a31031a5.entry.js +0 -2
  782. package/dist/core/p-a31031a5.entry.js.map +0 -1
  783. package/dist/core/p-a434c3d4.entry.js +0 -2
  784. package/dist/core/p-a43c12cd.entry.js +0 -2
  785. package/dist/core/p-a43c12cd.entry.js.map +0 -1
  786. package/dist/core/p-a50c3b9e.entry.js +0 -2
  787. package/dist/core/p-a50c3b9e.entry.js.map +0 -1
  788. package/dist/core/p-ab09986c.entry.js +0 -2
  789. package/dist/core/p-ab09986c.entry.js.map +0 -1
  790. package/dist/core/p-ac4e40a7.entry.js +0 -2
  791. package/dist/core/p-ac4e40a7.entry.js.map +0 -1
  792. package/dist/core/p-b2aa3d7c.entry.js +0 -2
  793. package/dist/core/p-b2aa3d7c.entry.js.map +0 -1
  794. package/dist/core/p-b82dcc29.entry.js +0 -2
  795. package/dist/core/p-b82dcc29.entry.js.map +0 -1
  796. package/dist/core/p-ba86928c.entry.js +0 -2
  797. package/dist/core/p-ba86928c.entry.js.map +0 -1
  798. package/dist/core/p-baf81f30.entry.js.map +0 -1
  799. package/dist/core/p-c125b65a.entry.js +0 -2
  800. package/dist/core/p-c125b65a.entry.js.map +0 -1
  801. package/dist/core/p-c34848da.entry.js +0 -2
  802. package/dist/core/p-d8469ac0.entry.js +0 -2
  803. package/dist/core/p-d8469ac0.entry.js.map +0 -1
  804. package/dist/core/p-db9c03c0.entry.js +0 -2
  805. package/dist/core/p-db9c03c0.entry.js.map +0 -1
  806. package/dist/core/p-e0462b23.entry.js +0 -2
  807. package/dist/core/p-e0462b23.entry.js.map +0 -1
  808. package/dist/core/p-e0a94f2d.entry.js +0 -2
  809. package/dist/core/p-e0a94f2d.entry.js.map +0 -1
  810. package/dist/core/p-e189f1d0.entry.js +0 -2
  811. package/dist/core/p-e189f1d0.entry.js.map +0 -1
  812. package/dist/core/p-e3997d60.entry.js +0 -2
  813. package/dist/core/p-e3997d60.entry.js.map +0 -1
  814. package/dist/core/p-e79e0292.entry.js +0 -2
  815. package/dist/core/p-e79e0292.entry.js.map +0 -1
  816. package/dist/core/p-e834344e.entry.js +0 -2
  817. package/dist/core/p-e834344e.entry.js.map +0 -1
  818. package/dist/core/p-f14454b1.entry.js +0 -2
  819. package/dist/core/p-f14454b1.entry.js.map +0 -1
  820. package/dist/core/p-f3c840cd.entry.js +0 -2
  821. package/dist/core/p-f3c840cd.entry.js.map +0 -1
  822. package/dist/core/p-f6888309.entry.js +0 -2
  823. package/dist/core/p-f6888309.entry.js.map +0 -1
  824. package/dist/core/p-f74a8752.entry.js +0 -2
  825. package/dist/core/p-f74a8752.entry.js.map +0 -1
  826. package/dist/core/p-f7a14c01.entry.js +0 -2
  827. package/dist/core/p-f7a14c01.entry.js.map +0 -1
  828. package/dist/core/p-f843da01.entry.js +0 -2
  829. package/dist/core/p-f843da01.entry.js.map +0 -1
  830. package/dist/core/p-fc5611e2.entry.js +0 -2
  831. package/dist/core/p-fc5611e2.entry.js.map +0 -1
  832. package/dist/core/p-fd186591.js +0 -2
  833. package/dist/core/p-fd186591.js.map +0 -1
  834. package/dist/core/p-fde45b29.entry.js +0 -2
  835. package/dist/core/p-fde45b29.entry.js.map +0 -1
  836. package/dist/esm/helpers-12b4266a.js.map +0 -1
  837. package/dist/esm/helpers-5271897c.js +0 -183
  838. package/dist/esm/helpers-5271897c.js.map +0 -1
  839. package/dist/esm/ic-card.entry.js +0 -122
  840. package/dist/esm/ic-card.entry.js.map +0 -1
  841. package/dist/esm/ic-data-entity.entry.js +0 -25
  842. package/dist/esm/ic-data-entity.entry.js.map +0 -1
  843. package/dist/esm/ic-empty-state.entry.js +0 -34
  844. package/dist/esm/ic-empty-state.entry.js.map +0 -1
  845. package/dist/esm/ic-input-component-container_3.entry.js.map +0 -1
  846. package/dist/esm/ic-input-label_2.entry.js +0 -81
  847. package/dist/esm/ic-input-label_2.entry.js.map +0 -1
  848. package/dist/esm/ic-pagination-bar.entry.js +0 -265
  849. package/dist/esm/ic-pagination-bar.entry.js.map +0 -1
  850. package/dist/esm/types-f605c21c.js +0 -16
  851. package/dist/esm/types-f605c21c.js.map +0 -1
  852. package/dist/types/components/ic-pagination/ic-pagination.types.d.ts +0 -6
  853. /package/dist/types/components/{ic-select-with-multi/test/a11y/ic-select.test.a11y.d.ts → ic-data-table-title-bar/test/a11y/ic-data-table-title-bar.test.a11y.d.ts} +0 -0
@@ -1,5 +1,7 @@
1
- import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
2
- import { d as defineCustomElement$g } from './ic-button2.js';
1
+ import { proxyCustomElement, HTMLElement, createEvent, h, Fragment, Host } from '@stencil/core/internal/client';
2
+ import { d as dynamicDebounce, a as isEmptyString, p as pxToRem, i as isSlotUsed, b as addDataToPosition } from './helpers2.js';
3
+ import { d as defineCustomElement$h } from './ic-button2.js';
4
+ import { d as defineCustomElement$g } from './ic-empty-state2.js';
3
5
  import { d as defineCustomElement$f } from './ic-input-component-container2.js';
4
6
  import { d as defineCustomElement$e } from './ic-input-container2.js';
5
7
  import { d as defineCustomElement$d } from './ic-input-label2.js';
@@ -27,18 +29,182 @@ const descendingIcon = `<svg focusable="false" aria-hidden="true" viewBox="0 0 2
27
29
  <path d="M16.01 11H4v2h12.01v3L20 12l-3.99-4z"></path>
28
30
  </svg>`;
29
31
 
30
- const icDataTableCss = ":host{position:relative;display:block;height:100%;max-height:100%}.table-container{position:relative;height:calc(100% - var(--ic-space-xxxs))}.table-row-container{position:relative;height:100%;overflow:auto;transition:var(--ic-easing-transition-fast);overflow-anchor:none}:host([show-pagination=\"true\"]) .table-row-container{height:calc(100% - 3.5625rem)}table{table-layout:fixed;border-spacing:0;width:100%}.table-row-container:focus{outline:none;box-shadow:var(--ic-border-focus);border-radius:var(--ic-border-radius);transition:var(--ic-easing-transition-fast);z-index:1}:host([embedded=\"true\"]) .table-container{border:var(--ic-border-light)}.column-header-sticky{position:sticky;top:0;z-index:1}.column-header-overlay{position:sticky;top:0;z-index:1;box-shadow:0 0.375rem var(--ic-space-xs) calc(var(--ic-space-xxs * -1))\n rgb(0 0 0 / 20%)}.row-header-sticky{position:sticky;left:0}.column-header,.table-row{box-sizing:border-box}.table-row-selected{background-color:var(--ic-table-row-selected) !important}.sort-button{margin-left:auto}.sort-button:hover{background-color:var(--ic-action-dark-bg-hover)}.sort-button:active{background-color:var(--ic-action-dark-bg-active)}.sort-button svg{color:var(--ic-architectural-black)}.sort-button-unsorted svg{color:var(--ic-color-tertiary-text)}.table-density-dense{padding:var(--ic-space-xxs) var(--ic-space-xs) !important}.text-dense{font-size:var(--ic-font-size-label)}.table-density-spacious{padding:0.625rem var(--ic-space-xs) !important}.text-spacious{font-size:1.125rem}.column-header-text{font-weight:var(--ic-font-weight-bold)}.column-header,.row-header{text-align:left;padding:var(--ic-space-xs);background-color:var(--ic-architectural-40);border-right:var(--ic-border-light);border-bottom:var(--ic-border-light)}.column-header:last-child{border-right:none}.scrollable .column-header:last-child{border-right:var(--ic-border-light) !important}:host([embedded=\"true\"]) tr:last-child .table-cell,:host([embedded=\"true\"]) tr:last-child .row-header{border-bottom:none}.column-header-alignment-left,.row-header-alignment-left,.cell-alignment-left{text-align:left !important}.column-header-alignment-right,.row-header-alignment-right,.cell-alignment-right{text-align:right !important}.column-header-alignment-center,.row-header-alignment-center,.cell-alignment-center{text-align:center !important}.table-row:nth-child(even){background-color:var(--ic-architectural-20)}.table-cell{padding:var(--ic-space-xs);border-bottom:solid var(--ic-architectural-100) var(--ic-space-1px)}.data-type-string{text-align:left;vertical-align:top}.data-type-number,.data-type-date{text-align:right;vertical-align:top}.cell-alignment-top{vertical-align:top}.cell-alignment-middle{vertical-align:middle}.cell-alignment-bottom{vertical-align:bottom}.cell-emphasis-low{color:var(--ic-color-secondary-text)}.cell-emphasis-high{font-weight:var(--ic-font-weight-bold)}.pagination-container{background-color:var(--ic-architectural-40);border-top:var(--ic-border-light)}.screen-reader-sort-text,.table-caption{position:absolute;left:-100rem}.table-cell,.column-header,.row-header{word-wrap:break-word;white-space:pre-wrap}@media screen and (min-width: 576px){.column-header-inner-container{display:flex;align-items:center}}";
32
+ const icDataTableCss = ":host{position:relative;display:inline-flex;max-height:100%;width:var(--table-width, 100%);height:100%;min-width:var(--table-min-width);max-width:var(--table-max-width)}tbody{vertical-align:top}.table-container{position:relative;height:calc(100% - var(--ic-space-xxxs));display:flex;flex-direction:column;width:100%}.cell-container{display:flex;min-height:1.5rem;overflow-y:hidden;height:var(--row-height)}.truncation-show-hide{overflow:visible;display:block}.cell-icon.truncation-show-hide{display:flex}.cell-container:not(.data-type-element,.truncation-show-hide){overflow-x:hidden}ic-loading-indicator{position:sticky;top:20px}.table-row-container{position:relative;height:100%;overflow:auto;transition:var(--ic-easing-transition-fast);overflow-anchor:none}:host([show-pagination=\"true\"]) .table-row-container{height:calc(100% - 3.5625rem)}table{table-layout:var(--table-layout, \"fixed\");border-spacing:0;width:100%;height:var(--table-height, auto)}.table-row-container:focus{outline:none;box-shadow:var(--ic-border-focus);border-radius:var(--ic-border-radius);transition:var(--ic-easing-transition-fast);z-index:1}:host([embedded=\"true\"]) .table-row-container{border:var(--ic-border-light)}.column-header-inner-container{padding:var(--ic-space-xs);box-sizing:border-box}.column-header-sticky{position:sticky;top:0;z-index:1}.column-header-overlay{position:sticky;top:0;z-index:1;box-shadow:0 0.375rem var(--ic-space-xs) calc(var(--ic-space-xxs * -1))\n rgb(0 0 0 / 20%)}.row-header-sticky{position:sticky;left:0}.column-header,.table-row{box-sizing:border-box}.table-row-selected{background-color:var(--ic-table-row-selected) !important}.sort-button{margin-left:auto}.sort-button:hover{background-color:var(--ic-action-dark-bg-hover)}.sort-button:active{background-color:var(--ic-action-dark-bg-active)}.sort-button svg{color:var(--ic-architectural-black)}.sort-button-unsorted svg{color:var(--ic-color-tertiary-text)}.table-density-dense .column-header-inner-container,td.table-density-dense{padding:var(--ic-space-xxs) var(--ic-space-xs) !important}.text-dense{font-size:var(--ic-font-size-label)}.table-density-spacious .column-header-inner-container,td.table-density-spacious{padding:0.625rem var(--ic-space-xs) !important}.text-spacious{font-size:1.125rem}.column-header-text{font-weight:var(--ic-font-weight-bold)}.row-header,.column-header{text-align:left;padding:var(--ic-space-xs);background-color:var(--ic-architectural-40);border-right:var(--ic-border-light);border-bottom:var(--ic-border-light)}.column-header{padding:0;width:var(--column-width);min-width:var(--column-min-width, 4rem);max-width:var(--column-max-width)}.column-header:last-child{border-right:none}.scrollable .column-header:last-child{border-right:var(--ic-border-light) !important}:host([embedded=\"true\"]) tr:last-child .table-cell,:host([embedded=\"true\"]) tr:last-child .row-header{border-bottom:none}.column-header-alignment-left,.row-header-alignment-left,.cell-alignment-left{text-align:left !important;justify-content:start !important}.column-header-alignment-right,.row-header-alignment-right,.cell-alignment-right{text-align:right !important;justify-content:end !important}.cell-alignment-right.truncation-tooltip ic-tooltip ic-typography{padding-right:calc(var(--ic-space-xxs) + var(--ic-space-xs))}.cell-alignment-right.truncation-show-hide ic-typography{--ellipsis-padding-right:calc(var(--ic-space-xxs) + var(--ic-space-xs))}.column-header-alignment-center,.row-header-alignment-center,.cell-alignment-center{text-align:center !important;justify-content:center !important}.table-row:nth-child(even){background-color:var(--ic-architectural-20)}.table-cell{padding:var(--ic-space-xs);border-bottom:solid var(--ic-architectural-100) var(--ic-space-1px);overflow:hidden;box-sizing:border-box;max-width:var(--column-max-width);min-width:var(--column-min-width)}.data-type-string,.data-type-address{text-align:left;vertical-align:top}.data-type-number,.data-type-date{text-align:right;justify-content:end;vertical-align:top}.cell-alignment-top{vertical-align:top;align-items:flex-start}.cell-alignment-middle{vertical-align:middle;align-items:center}.cell-alignment-bottom{vertical-align:bottom;align-items:flex-end}.cell-emphasis-low{--ic-typography-color:var(--ic-color-secondary-text)}.cell-emphasis-high{font-weight:var(--ic-font-weight-bold)}.pagination-container{background-color:var(--ic-architectural-40);border-top:var(--ic-border-light)}.screen-reader-sort-text,.table-caption{position:absolute;left:-100rem}.table-cell,.column-header,.row-header{word-wrap:break-word;white-space:pre-wrap}.loading-empty{padding:var(--ic-space-xl) var(--ic-space-xxl);margin-top:var(--ic-space-xl)}.updating-state{padding:0;border-bottom:var(--ic-border-light)}.updating-state-headers{border-bottom:none}.loading{position:absolute;left:calc(50% - 5.9741rem);opacity:0;transition:opacity var(--ic-transition-duration-slow)}.loading.show-background{background-color:var(--ic-architectural-white);border:var(--ic-border-light)}.loading.show{opacity:1}.icon,::slotted(svg){height:var(--ic-space-lg);width:var(--ic-space-lg);margin-right:var(--ic-space-xxs)}.column-header-alignment-right>.icon,.row-header-alignment-right>.icon,.cell-alignment-right>.icon,.column-header-alignment-right>::slotted(svg),.row-header-alignment-right>::slotted(svg),.cell-alignment-right>::slotted(svg){margin-right:auto}.column-header-alignment-center>ic-typography,.row-header-alignment-right>ic-typography,.cell-alignment-center>ic-typography{flex:1}.icon>svg{height:var(--ic-space-lg);width:var(--ic-space-lg);display:inline-block}.truncation-tooltip ic-typography{display:-webkit-box;-webkit-line-clamp:var(--ic-line-clamp, 0);-webkit-box-orient:vertical;overflow:hidden}.truncation-tooltip ic-typography,.truncation-show-hide ic-typography{white-space:normal}.ic-tooltip-overflow{overflow:hidden;width:100%}@media screen and (min-width: 576px){.column-header-inner-container{display:flex;align-items:center}}";
31
33
 
32
34
  const DataTable = /*@__PURE__*/ proxyCustomElement(class DataTable extends HTMLElement {
33
35
  constructor() {
34
36
  super();
35
37
  this.__registerHost();
36
38
  this.__attachShadow();
39
+ this.icRowHeightChange = createEvent(this, "icRowHeightChange", 7);
40
+ this.icSortChange = createEvent(this, "icSortChange", 7);
41
+ this.DENSITY_HEIGHT_MULTIPLIER = {
42
+ dense: 0.8,
43
+ default: 1,
44
+ spacious: 1.2,
45
+ };
46
+ this.DENSITY_PADDING_HEIGHT_DIFF = {
47
+ dense: 8,
48
+ default: 16,
49
+ spacious: 20,
50
+ };
37
51
  this.SORT_ICONS = {
38
52
  unsorted: unsortedIcon,
39
53
  ascending: ascendingIcon,
40
54
  descending: descendingIcon,
41
55
  };
56
+ this.hasLoadedForOneSecond = true;
57
+ this.resizeObserver = null;
58
+ this.SHOW_HIDE_STRING = "show-hide";
59
+ this.SHOW_HIDE_CSS_CLASS = `${this.SHOW_HIDE_STRING}-wrap`;
60
+ this.TOOLTIP_STRING = "tooltip";
61
+ this.TOOLTIP = `ic-${this.TOOLTIP_STRING}`;
62
+ this.TEXT_WRAP_STRING = "text-wrap";
63
+ this.TEXT_WRAP_CLASS = `.${this.TEXT_WRAP_STRING}`;
64
+ this.dataUpdated = false;
65
+ this.rowHeightSet = false;
66
+ this.initialLoad = false;
67
+ this.icPageChangeEvent = false;
68
+ this.itemsPerPageChange = false;
69
+ this.DATA_ROW_HEIGHT_STRING = "data-row-height";
70
+ this.ROW_HEIGHT_CSS_VARIABLE = "--row-height";
71
+ this.DEFAULT_LINE_HEIGHT = 24;
72
+ this.densityUpdate = false;
73
+ this.truncationPatternUpdated = false;
74
+ this.isNewDebounceDelaySet = false;
75
+ this.updateSetRowHeight = (typographyEl) => {
76
+ const fontSize = parseInt(getComputedStyle(document.documentElement).fontSize);
77
+ if (typographyEl) {
78
+ const cellContainer = this.getCellContainer(typographyEl);
79
+ const rowHeight = fontSize *
80
+ parseFloat(cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));
81
+ if (typographyEl.scrollHeight > rowHeight) {
82
+ cellContainer.style.removeProperty(this.ROW_HEIGHT_CSS_VARIABLE);
83
+ }
84
+ }
85
+ else {
86
+ this.getTypographyElements().forEach((typographyEl) => {
87
+ const cellContainer = this.getCellContainer(typographyEl);
88
+ const rowHeight = fontSize *
89
+ parseFloat(cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));
90
+ if (typographyEl.scrollHeight > rowHeight) {
91
+ cellContainer.style.removeProperty(this.ROW_HEIGHT_CSS_VARIABLE);
92
+ }
93
+ });
94
+ }
95
+ };
96
+ this.debounceDataTruncation = () => {
97
+ this.getTypographyElements().forEach((typographyEl) => {
98
+ const cellContainer = this.getCellContainer(typographyEl);
99
+ if (!cellContainer.classList.contains(this.TEXT_WRAP_STRING)) {
100
+ this.resizeObserver = new ResizeObserver(
101
+ // This gets triggered twice due to updated data and see more/see less button
102
+ dynamicDebounce(() => {
103
+ this.dataTruncation(typographyEl);
104
+ if (!this.isNewDebounceDelaySet) {
105
+ this.setNewDebounceDelay(200);
106
+ }
107
+ }, () => this.debounceDelay));
108
+ this.resizeObserver.observe(typographyEl);
109
+ }
110
+ });
111
+ };
112
+ this.setNewDebounceDelay = (delay) => {
113
+ this.debounceDelay = delay;
114
+ this.isNewDebounceDelaySet = true;
115
+ };
116
+ this.getLines = (height) => Math.floor(height / this.DEFAULT_LINE_HEIGHT);
117
+ this.truncate = (typographyEl, cellContainer, tooltip) => {
118
+ if ((typographyEl === null || typographyEl === void 0 ? void 0 : typographyEl.scrollHeight) > (cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight)) {
119
+ //24 is the height of a single line
120
+ if (!typographyEl.closest(this.TEXT_WRAP_CLASS)) {
121
+ if (this.truncationPattern === this.TOOLTIP_STRING) {
122
+ this.addTooltipTruncation(typographyEl, cellContainer, tooltip);
123
+ }
124
+ if (this.truncationPattern === this.SHOW_HIDE_STRING) {
125
+ this.addShowHideTruncation(cellContainer, typographyEl);
126
+ }
127
+ }
128
+ }
129
+ else {
130
+ if (this.truncationPattern === this.TOOLTIP_STRING && tooltip) {
131
+ typographyEl.setAttribute("style", `--ic-line-clamp: 0`);
132
+ cellContainer.appendChild(typographyEl);
133
+ tooltip.remove();
134
+ }
135
+ if (this.truncationPattern === this.SHOW_HIDE_STRING &&
136
+ !isEmptyString(typographyEl.getAttribute("max-lines"))) {
137
+ this.resetShowHideTruncation(typographyEl);
138
+ }
139
+ }
140
+ };
141
+ this.dataTruncation = (typographyEl) => {
142
+ // Tooltip truncation mentioned in AC. Will need revisiting
143
+ const tooltip = this.getTooltip(typographyEl);
144
+ const cellContainer = this.getCellContainer(typographyEl);
145
+ if ((cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.classList.contains("data-type-element")) ||
146
+ this.dataUpdated) {
147
+ return;
148
+ }
149
+ if (this.truncationPattern === this.SHOW_HIDE_STRING &&
150
+ typographyEl.shadowRoot.querySelector("button")) {
151
+ const showHideBtn = typographyEl.shadowRoot.querySelector("button");
152
+ // If the see more/see less is present and the max lines is equal to the cell container
153
+ // remove the see more/see less button
154
+ if (showHideBtn) {
155
+ const truncWrapper = this.getTruncWrapper(typographyEl);
156
+ if (this.getLines(truncWrapper.scrollHeight) ===
157
+ +typographyEl.getAttribute("max-lines")) {
158
+ this.resetShowHideTruncation(typographyEl);
159
+ }
160
+ }
161
+ }
162
+ // Deals with setting and resetting row height and re-truncating data
163
+ if (this.rowHeightSet && this.truncationPattern === this.SHOW_HIDE_STRING) {
164
+ const truncWrapper = this.getTruncWrapper(typographyEl);
165
+ // cellContainer.clientHeight - 24 removes the extra line by see more/see less
166
+ if (truncWrapper &&
167
+ cellContainer.clientHeight - this.DEFAULT_LINE_HEIGHT >
168
+ truncWrapper.scrollHeight) {
169
+ this.resetShowHideTruncation(typographyEl);
170
+ return;
171
+ }
172
+ if (typographyEl.scrollHeight > cellContainer.clientHeight) {
173
+ this.addShowHideTruncation(cellContainer, typographyEl);
174
+ return;
175
+ }
176
+ }
177
+ if ((typographyEl === null || typographyEl === void 0 ? void 0 : typographyEl.scrollHeight) > 0 &&
178
+ (cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight) > 0 &&
179
+ (typographyEl === null || typographyEl === void 0 ? void 0 : typographyEl.scrollHeight) === (cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight)) {
180
+ if (tooltip) {
181
+ this.removeTooltip(cellContainer, typographyEl, tooltip);
182
+ }
183
+ return;
184
+ }
185
+ this.truncate(typographyEl, cellContainer, tooltip);
186
+ };
187
+ this.removeTextWrap = () => {
188
+ this.getTypographyElements().forEach((typographyEl) => {
189
+ const tableCell = typographyEl.closest("td");
190
+ if (tableCell.classList.contains(this.TEXT_WRAP_STRING)) {
191
+ tableCell.classList.remove(this.TEXT_WRAP_STRING);
192
+ }
193
+ });
194
+ };
195
+ this.getCellContainer = (typographyEl) => {
196
+ return typographyEl.closest(".cell-container");
197
+ };
198
+ this.deleteTextWrapDataKey = (array) => Array.isArray(array) &&
199
+ array.forEach((val) => val.textWrap && delete val.textWrap);
200
+ this.startLoadingTimer = () => {
201
+ this.hasLoadedForOneSecond = false;
202
+ this.timerStarted = Date.now();
203
+ setTimeout(() => {
204
+ this.hasLoadedForOneSecond = true;
205
+ this.timerStarted = null;
206
+ }, this.minimumLoadingDisplayDuration);
207
+ };
42
208
  this.isObject = (value) => typeof value === "object";
43
209
  this.notDefaultDensity = () => this.density !== "default";
44
210
  this.getCellContent = (cell, dataType) => {
@@ -56,9 +222,60 @@ const DataTable = /*@__PURE__*/ proxyCustomElement(class DataTable extends HTMLE
56
222
  return this.getObjectValue(this.getObjectValue(cell, "cellAlignment"), alignment);
57
223
  }
58
224
  };
59
- this.createCells = (row) => {
225
+ this.getCellOptions = (cell, key) => {
226
+ if (!(this.isObject(cell) && Object.keys(cell).includes(key)))
227
+ return;
228
+ return this.getObjectValue(cell, key);
229
+ };
230
+ this.createUpdatingIndicator = () => {
231
+ const { appearance, description, max, min, progress } = this.updatingOptions || {};
232
+ return (h("th", { colSpan: this.columns.length, class: "updating-state" }, h("ic-loading-indicator", { appearance: appearance, description: description || "Updating table data", fullWidth: true, max: max, min: min, progress: progress, type: "linear", size: "small" })));
233
+ };
234
+ this.setRowHeight = (height) => {
235
+ return pxToRem(`${height * this.DENSITY_HEIGHT_MULTIPLIER[this.density] -
236
+ this.DENSITY_PADDING_HEIGHT_DIFF[this.density]}px`);
237
+ };
238
+ this.setTruncationClass = () => {
239
+ if (this.truncationPattern) {
240
+ return { [`truncation-${this.truncationPattern}`]: true };
241
+ }
242
+ return {};
243
+ };
244
+ this.getColumnWidth = (columnWidth) => {
245
+ // TODO: Setting max width on columns
246
+ let columnWidthStyling = {};
247
+ if (columnWidth) {
248
+ if (typeof columnWidth === "string") {
249
+ columnWidthStyling = Object.assign(Object.assign({}, columnWidthStyling), { ["--column-width"]: columnWidth });
250
+ }
251
+ if (typeof columnWidth === "object" && !!Object.keys(columnWidth)) {
252
+ if (columnWidth === null || columnWidth === void 0 ? void 0 : columnWidth.minWidth) {
253
+ columnWidthStyling = Object.assign(Object.assign({}, columnWidthStyling), { ["--column-min-width"]: columnWidth === null || columnWidth === void 0 ? void 0 : columnWidth.minWidth });
254
+ }
255
+ if (columnWidth === null || columnWidth === void 0 ? void 0 : columnWidth.maxWidth) {
256
+ columnWidthStyling = Object.assign(Object.assign({}, columnWidthStyling), { ["--column-max-width"]: columnWidth === null || columnWidth === void 0 ? void 0 : columnWidth.maxWidth });
257
+ }
258
+ }
259
+ }
260
+ return columnWidthStyling;
261
+ };
262
+ this.getRowHeight = (currentRowHeight, columnProps, rowTextWrap, cell) => {
263
+ if ((this.truncationPattern || currentRowHeight) &&
264
+ !(columnProps === null || columnProps === void 0 ? void 0 : columnProps.textWrap) &&
265
+ !rowTextWrap &&
266
+ !this.getCellOptions(cell, "textWrap") &&
267
+ (columnProps === null || columnProps === void 0 ? void 0 : columnProps.dataType) !== "element") {
268
+ return {
269
+ [this.ROW_HEIGHT_CSS_VARIABLE]: this.setRowHeight(currentRowHeight),
270
+ };
271
+ }
272
+ return {};
273
+ };
274
+ this.createCells = (row, rowIndex) => {
275
+ var _a;
60
276
  const rowValues = Object.values(row);
61
277
  const rowKeys = Object.keys(row);
278
+ const rowOptions = this.getRowOptions(rowKeys, rowValues);
62
279
  let rowAlignment;
63
280
  let rowEmphasis;
64
281
  const headerIndex = rowKeys.indexOf("header");
@@ -66,44 +283,70 @@ const DataTable = /*@__PURE__*/ proxyCustomElement(class DataTable extends HTMLE
66
283
  rowAlignment = this.getObjectValue(rowValues[headerIndex], "rowAlignment");
67
284
  rowEmphasis = this.getObjectValue(rowValues[headerIndex], "emphasis");
68
285
  }
286
+ const variableRowHeightVal = (_a = this.variableRowHeight) === null || _a === void 0 ? void 0 : _a.call(this, Object.assign(Object.assign({}, row), { index: rowIndex }));
287
+ const currentRowHeight = variableRowHeightVal
288
+ ? variableRowHeightVal !== "auto" && variableRowHeightVal
289
+ : this.globalRowHeight !== "auto" && this.globalRowHeight;
69
290
  return rowValues.map((cell, index) => {
70
- const { columnAlignment, dataType, emphasis } = this.columns[index];
291
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
292
+ const columnProps = this.columns[index];
293
+ const cellSlotName = `${columnProps === null || columnProps === void 0 ? void 0 : columnProps.key}-${rowIndex}`;
294
+ const hasIcon = this.isObject(cell) && Object.keys(cell).includes("icon");
71
295
  const cellValue = (key) => this.getObjectValue(cell, key);
72
- return rowKeys[index] === "header" ? (h("th", { scope: "row", colSpan: cellValue("colspan"), class: {
73
- ["row-header"]: true,
74
- [`row-header-alignment-${cellValue("cellAlignment")}`]: !!cellValue("cellAlignment"),
75
- ["row-header-sticky"]: this.stickyRowHeaders,
76
- } }, cellValue("title"))) : (h("td", { innerHTML: dataType === "element" ? cell : null, class: {
77
- ["table-cell"]: true,
78
- [`table-density-${this.density}`]: this.notDefaultDensity(),
79
- [`data-type-${dataType}`]: true,
80
- [`cell-alignment-${(columnAlignment === null || columnAlignment === void 0 ? void 0 : columnAlignment.horizontal) ||
81
- this.getCellAlignment(cell, "horizontal")}`]: !!(columnAlignment === null || columnAlignment === void 0 ? void 0 : columnAlignment.horizontal) ||
82
- !!this.getCellAlignment(cell, "horizontal"),
83
- [`cell-alignment-${(columnAlignment === null || columnAlignment === void 0 ? void 0 : columnAlignment.vertical) ||
84
- rowAlignment ||
85
- this.getCellAlignment(cell, "vertical")}`]: !!(columnAlignment === null || columnAlignment === void 0 ? void 0 : columnAlignment.vertical) ||
86
- !!rowAlignment ||
87
- !!this.getCellAlignment(cell, "vertical"),
88
- } }, h("ic-typography", { variant: "body", class: {
89
- [`cell-emphasis-${(this.isObject(cell) && cellValue("emphasis")) ||
90
- emphasis ||
91
- rowEmphasis}`]: (this.isObject(cell) && !!cellValue("emphasis")) ||
92
- !!emphasis ||
93
- !!rowEmphasis,
94
- [`text-${this.density}`]: this.notDefaultDensity(),
95
- } }, this.isObject(cell) && dataType !== "date" ? (Object.keys(cell).includes("href") ? (h("ic-link", { href: cellValue("href") }, cellValue("data"))) : (cellValue("data"))) : (this.getCellContent(cell, dataType)))));
296
+ if (rowKeys[index] === "header") {
297
+ return (h("th", { scope: "row", colSpan: cellValue("colspan"), class: {
298
+ ["row-header"]: true,
299
+ [`row-header-alignment-${cellValue("cellAlignment")}`]: !!cellValue("cellAlignment"),
300
+ ["row-header-sticky"]: this.stickyRowHeaders,
301
+ } }, cellValue("title")));
302
+ }
303
+ if (rowKeys[index] !== "rowOptions") {
304
+ return (h("td", { class: {
305
+ ["table-cell"]: true,
306
+ [`table-density-${this.density}`]: this.notDefaultDensity(),
307
+ }, style: Object.assign({}, this.getColumnWidth(columnProps.columnWidth)) }, h("div", { innerHTML: (columnProps === null || columnProps === void 0 ? void 0 : columnProps.dataType) === "element" &&
308
+ !isSlotUsed(this.el, cellSlotName)
309
+ ? cell
310
+ : null, class: Object.assign({ "cell-container": (columnProps === null || columnProps === void 0 ? void 0 : columnProps.dataType) !== "element", [`cell-alignment-${((_a = columnProps === null || columnProps === void 0 ? void 0 : columnProps.columnAlignment) === null || _a === void 0 ? void 0 : _a.vertical) ||
311
+ ((_b = rowOptions === null || rowOptions === void 0 ? void 0 : rowOptions.rowAlignment) === null || _b === void 0 ? void 0 : _b.vertical) ||
312
+ rowAlignment ||
313
+ this.getCellAlignment(cell, "vertical")}`]: !!((_c = columnProps === null || columnProps === void 0 ? void 0 : columnProps.columnAlignment) === null || _c === void 0 ? void 0 : _c.vertical) ||
314
+ !!((_d = rowOptions === null || rowOptions === void 0 ? void 0 : rowOptions.rowAlignment) === null || _d === void 0 ? void 0 : _d.vertical) ||
315
+ !!rowAlignment ||
316
+ !!this.getCellAlignment(cell, "vertical"), [`cell-alignment-${((_e = columnProps === null || columnProps === void 0 ? void 0 : columnProps.columnAlignment) === null || _e === void 0 ? void 0 : _e.horizontal) ||
317
+ ((_f = rowOptions === null || rowOptions === void 0 ? void 0 : rowOptions.rowAlignment) === null || _f === void 0 ? void 0 : _f.horizontal) ||
318
+ this.getCellAlignment(cell, "horizontal")}`]: !!((_g = columnProps === null || columnProps === void 0 ? void 0 : columnProps.columnAlignment) === null || _g === void 0 ? void 0 : _g.horizontal) ||
319
+ !!((_h = rowOptions === null || rowOptions === void 0 ? void 0 : rowOptions.rowAlignment) === null || _h === void 0 ? void 0 : _h.horizontal) ||
320
+ !!this.getCellAlignment(cell, "horizontal"), [`data-type-${columnProps === null || columnProps === void 0 ? void 0 : columnProps.dataType}`]: true, [this.TEXT_WRAP_STRING]: (columnProps === null || columnProps === void 0 ? void 0 : columnProps.textWrap) ||
321
+ (rowOptions === null || rowOptions === void 0 ? void 0 : rowOptions.textWrap) ||
322
+ !!this.getCellOptions(cell, "textWrap"), ["cell-icon"]: hasIcon || !!((_j = columnProps === null || columnProps === void 0 ? void 0 : columnProps.icon) === null || _j === void 0 ? void 0 : _j.icon) }, this.setTruncationClass()), style: Object.assign(Object.assign({}, this.getRowHeight(currentRowHeight, columnProps, rowOptions === null || rowOptions === void 0 ? void 0 : rowOptions.textWrap, cell)), this.getColumnWidth(columnProps === null || columnProps === void 0 ? void 0 : columnProps.columnWidth)), "data-row-height": this.truncationPattern || currentRowHeight
323
+ ? this.setRowHeight(currentRowHeight)
324
+ : null }, isSlotUsed(this.el, cellSlotName) ? (h("slot", { name: cellSlotName })) : (h(Fragment, null, isSlotUsed(this.el, `${cellSlotName}-icon`) ? (h("slot", { name: `${cellSlotName}-icon` })) : ((hasIcon || ((_k = columnProps === null || columnProps === void 0 ? void 0 : columnProps.icon) === null || _k === void 0 ? void 0 : _k.onAllCells)) && (h("span", { class: "icon", innerHTML: cellValue("icon") || (columnProps === null || columnProps === void 0 ? void 0 : columnProps.icon.icon) }))), (columnProps === null || columnProps === void 0 ? void 0 : columnProps.dataType) !== "element" &&
325
+ !isSlotUsed(this.el, cellSlotName) && (h("ic-typography", { variant: "body", class: {
326
+ [`cell-emphasis-${(this.isObject(cell) && cellValue("emphasis")) ||
327
+ (columnProps === null || columnProps === void 0 ? void 0 : columnProps.emphasis) ||
328
+ rowEmphasis}`]: (this.isObject(cell) && !!cellValue("emphasis")) ||
329
+ !!(columnProps === null || columnProps === void 0 ? void 0 : columnProps.emphasis) ||
330
+ !!rowEmphasis,
331
+ [`text-${this.density}`]: this.notDefaultDensity(),
332
+ } }, this.isObject(cell) &&
333
+ (columnProps === null || columnProps === void 0 ? void 0 : columnProps.dataType) !== "date" ? (Object.keys(cell).includes("href") ? (h("ic-link", { href: cellValue("href") }, cellValue("data"))) : (cellValue("data"))) : (this.getCellContent(cell, columnProps === null || columnProps === void 0 ? void 0 : columnProps.dataType)))))))));
334
+ }
96
335
  });
97
336
  };
98
337
  this.createColumnHeaders = () => {
99
- return this.columns.map(({ cellAlignment, colspan, key, title }) => (h("th", { scope: "col", class: {
338
+ return this.columns.map(({ cellAlignment, colspan, icon, key, title, columnWidth }) => (h("th", { scope: "col", class: {
100
339
  ["column-header"]: true,
101
- [`column-header-alignment-${cellAlignment}`]: !!cellAlignment,
102
340
  [`table-density-${this.density}`]: this.notDefaultDensity(),
103
- }, colSpan: colspan }, this.sortable ? (h("div", { class: "column-header-inner-container" }, h("ic-typography", { variant: "body", class: {
341
+ ["updating-state-headers"]: this.updating && !this.loading,
342
+ }, style: Object.assign({}, this.getColumnWidth(columnWidth)), colSpan: colspan }, h("div", { class: {
343
+ "column-header-inner-container": true,
344
+ [`column-header-alignment-${cellAlignment}`]: !!cellAlignment,
345
+ } }, isSlotUsed(this.el, `${key}-column-icon`) ? (h("slot", { name: `${key}-column-icon` })) : (icon &&
346
+ !icon.hideOnHeader && (h("span", { class: "icon", innerHTML: icon.icon }))), h("ic-typography", { variant: "body", class: {
104
347
  ["column-header-text"]: true,
105
348
  [`text-${this.density}`]: this.notDefaultDensity(),
106
- } }, title), h("ic-button", { variant: "icon", id: `sort-button-${key}`, "aria-label": this.getSortButtonLabel(key),
349
+ } }, title), this.sortable && (h("ic-button", { variant: "icon", id: `sort-button-${key}`, "aria-label": this.getSortButtonLabel(key),
107
350
  // eslint-disable-next-line react/jsx-no-bind
108
351
  onClick: () => this.sortRows(key), innerHTML: this.SORT_ICONS[this.sortedColumn === key
109
352
  ? this.sortedColumnOrder
@@ -111,21 +354,41 @@ const DataTable = /*@__PURE__*/ proxyCustomElement(class DataTable extends HTMLE
111
354
  ["sort-button"]: true,
112
355
  ["sort-button-unsorted"]: this.sortedColumn !== key ||
113
356
  this.sortedColumnOrder === "unsorted",
114
- } }))) : (h("ic-typography", { variant: "body", class: {
115
- ["column-header-text"]: true,
116
- [`text-${this.density}`]: this.notDefaultDensity(),
117
- } }, title)))));
357
+ } }))))));
358
+ };
359
+ this.onRowClick = (row) => {
360
+ this.selectedRow =
361
+ this.selectedRow !== row && !this.loading && !this.updating && row;
118
362
  };
119
363
  this.createRows = () => {
120
364
  const data = this.showPagination
121
365
  ? this.data.slice(this.fromRow, this.toRow)
122
366
  : this.data.slice();
123
- return data
367
+ /**
368
+ * Ensures that createCells has a value in data to map over to actually render the slot.
369
+ * Removes the need for the user to add it multiple times.
370
+ * `addDataToPosition` used to add the element in the correct column order.
371
+ * Adding empty string value in to give `createCells` something to loop over.
372
+ */
373
+ const organisedData = data.map((row, rowIndex) => {
374
+ const slottedColumns = this.columns
375
+ .map(({ key }, index) => isSlotUsed(this.el, `${key}-${rowIndex}`) && { key, index })
376
+ .filter((col) => !!col);
377
+ return slottedColumns.length > 0
378
+ ? addDataToPosition(row, slottedColumns, "")
379
+ : row;
380
+ });
381
+ return organisedData
124
382
  .sort(!this.sortable ? undefined : this.getSortFunction())
125
- .map((row) => (h("tr", { onClick: () => (this.selectedRow = this.selectedRow !== row && row), class: {
126
- ["table-row"]: true,
127
- ["table-row-selected"]: this.selectedRow === row,
128
- } }, this.createCells(row))));
383
+ .map((row, index) => {
384
+ return (h("tr", {
385
+ // eslint-disable-next-line react/jsx-no-bind
386
+ onClick: () => this.onRowClick(row), class: {
387
+ ["table-row"]: true,
388
+ ["table-row-selected"]: this.selectedRow === row,
389
+ }
390
+ }, this.createCells(row, index)));
391
+ });
129
392
  };
130
393
  this.getObjectValue = (cell, key) => {
131
394
  return Object.values(cell)[Object.keys(cell).indexOf(key)];
@@ -185,10 +448,49 @@ const DataTable = /*@__PURE__*/ proxyCustomElement(class DataTable extends HTMLE
185
448
  }
186
449
  this.sortedColumnOrder = sortOrders[nextSortOrderIndex];
187
450
  sortButton.setAttribute("aria-label", this.getSortButtonLabel(column));
451
+ this.tableSorted = true;
452
+ this.icSortChange.emit({
453
+ columnName: column,
454
+ sorted: this.sortedColumnOrder,
455
+ });
456
+ };
457
+ this.getTypographyElements = () => {
458
+ return Array.from(this.el.shadowRoot.querySelectorAll("ic-typography:not(.column-header-text)"));
459
+ };
460
+ this.getTooltip = (typographyEl) => {
461
+ return typographyEl.closest(this.TOOLTIP);
462
+ };
463
+ this.updateTruncationTooltip = (removeTooltipOnly = false) => {
464
+ this.getTypographyElements().forEach((typographyEl) => {
465
+ const tooltip = this.getTooltip(typographyEl);
466
+ const cellContainer = this.getCellContainer(typographyEl);
467
+ if (typographyEl.closest(this.TEXT_WRAP_CLASS)) {
468
+ this.removeTooltip(cellContainer, typographyEl, tooltip);
469
+ typographyEl.setAttribute("style", `--ic-line-clamp: 0`);
470
+ return;
471
+ }
472
+ this.regenerateTooltip(cellContainer, typographyEl, tooltip, removeTooltipOnly);
473
+ });
188
474
  };
189
475
  this.updateScrollOffset = () => {
190
476
  this.scrollOffset = this.el.shadowRoot.querySelector(".table-row-container").scrollTop;
191
477
  };
478
+ this.setTableDimensions = () => {
479
+ let tableHostDimensions = {};
480
+ if (this.width) {
481
+ tableHostDimensions = Object.assign(Object.assign({}, tableHostDimensions), { ["--table-width"]: this.width });
482
+ }
483
+ if (this.height) {
484
+ tableHostDimensions = Object.assign(Object.assign({}, tableHostDimensions), { ["--table-height"]: this.height });
485
+ }
486
+ if (this.maxWidth) {
487
+ tableHostDimensions = Object.assign(Object.assign({}, tableHostDimensions), { ["--table-max-width"]: this.maxWidth });
488
+ }
489
+ if (this.minWidth) {
490
+ tableHostDimensions = Object.assign(Object.assign({}, tableHostDimensions), { ["--table-min-width"]: this.minWidth });
491
+ }
492
+ return tableHostDimensions;
493
+ };
192
494
  this.fromRow = 0;
193
495
  this.previousRowsPerPage = undefined;
194
496
  this.rowsPerPage = undefined;
@@ -198,23 +500,36 @@ const DataTable = /*@__PURE__*/ proxyCustomElement(class DataTable extends HTMLE
198
500
  this.sortedColumn = undefined;
199
501
  this.sortedColumnOrder = undefined;
200
502
  this.toRow = undefined;
503
+ this.currentRowHeight = undefined;
504
+ this.debounceDelay = 0;
201
505
  this.caption = undefined;
202
506
  this.columns = undefined;
203
507
  this.data = undefined;
204
508
  this.density = "default";
205
509
  this.embedded = false;
510
+ this.globalRowHeight = "auto";
511
+ this.height = undefined;
206
512
  this.hideColumnHeaders = false;
207
- this.paginationOptions = {
208
- itemsPerPage: [
513
+ this.loading = false;
514
+ this.loadingOptions = undefined;
515
+ this.maxWidth = undefined;
516
+ this.minWidth = undefined;
517
+ this.minimumLoadingDisplayDuration = 1000;
518
+ this.paginationBarOptions = {
519
+ itemsPerPageOptions: [
209
520
  { label: "10", value: "10" },
210
521
  { label: "25", value: "25" },
211
522
  { label: "50", value: "50" },
212
523
  ],
213
- type: "page",
214
- control: "simple",
215
- itemsPerPageControl: true,
216
- goToPageControl: true,
524
+ rangeLabelType: "page",
525
+ type: "simple",
526
+ showItemsPerPageControl: true,
527
+ showGoToPageControl: true,
217
528
  alignment: "right",
529
+ appearance: "default",
530
+ itemLabel: "Item",
531
+ pageLabel: "Page",
532
+ hideRangeLabel: false,
218
533
  };
219
534
  this.showPagination = false;
220
535
  this.sortable = false;
@@ -224,72 +539,511 @@ const DataTable = /*@__PURE__*/ proxyCustomElement(class DataTable extends HTMLE
224
539
  };
225
540
  this.stickyColumnHeaders = false;
226
541
  this.stickyRowHeaders = false;
542
+ this.tableLayout = "fixed";
543
+ this.truncationPattern = undefined;
544
+ this.updating = false;
545
+ this.updatingOptions = undefined;
546
+ this.variableRowHeight = undefined;
547
+ this.width = undefined;
548
+ }
549
+ disconnectedCallback() {
550
+ var _a;
551
+ (_a = this.resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
227
552
  }
228
553
  componentWillLoad() {
229
- this.rowsPerPage = Number(this.paginationOptions.itemsPerPage[0].value);
554
+ var _a;
555
+ this.rowsPerPage = Number(this.paginationBarOptions.itemsPerPageOptions[0].value);
230
556
  this.previousRowsPerPage = this.rowsPerPage;
231
557
  this.toRow = this.rowsPerPage;
232
558
  this.sortedColumn = this.sortOptions.defaultColumn;
233
559
  this.sortedColumnOrder = this.sortOptions.sortOrders[0];
560
+ this.loadingOptions = Object.assign(Object.assign({}, this.loadingOptions), { showBackground: ((_a = this.data) === null || _a === void 0 ? void 0 : _a.length) > 0 });
561
+ this.initialLoad = true;
562
+ this.previousItemsPerPage = this.rowsPerPage;
234
563
  }
235
564
  componentDidLoad() {
236
565
  const tableElement = this.el.shadowRoot.querySelector("table");
237
566
  const tableContainer = this.el.shadowRoot.querySelector(".table-container");
567
+ if (this.dataUpdated) {
568
+ this.dataUpdated = false;
569
+ }
238
570
  if ((tableElement === null || tableElement === void 0 ? void 0 : tableElement.clientHeight) > (tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.clientHeight) ||
239
571
  (tableElement === null || tableElement === void 0 ? void 0 : tableElement.clientWidth) > (tableContainer === null || tableContainer === void 0 ? void 0 : tableContainer.clientWidth)) {
240
572
  this.scrollable = true;
241
573
  }
574
+ if (this.loading) {
575
+ this.startLoadingTimer();
576
+ this.showLoadingIndicator();
577
+ }
578
+ if (this.truncationPattern) {
579
+ this.getTypographyElements().forEach((typographyEl) => {
580
+ const cellContainer = this.getCellContainer(typographyEl);
581
+ if (!cellContainer.classList.contains(this.TEXT_WRAP_STRING)) {
582
+ this.dataTruncation(typographyEl);
583
+ }
584
+ });
585
+ this.debounceDataTruncation();
586
+ }
587
+ if (this.globalRowHeight !== "auto") {
588
+ this.updateSetRowHeight();
589
+ }
242
590
  }
243
- handleItemsPerPageChange(ev) {
244
- this.previousRowsPerPage = this.rowsPerPage;
245
- this.rowsPerPage = ev.detail.value;
591
+ componentDidUpdate() {
592
+ // truncation updates invoked here once new/updated data has
593
+ // rendered to take into account updated .cell-container/ic-typography box model updates.
594
+ if (this.truncationPattern === this.SHOW_HIDE_STRING ||
595
+ this.truncationPattern === this.TOOLTIP_STRING) {
596
+ this.truncateUpdatedData();
597
+ }
246
598
  }
247
- handlePageChange(ev) {
248
- this.fromRow = (ev.detail.value - 1) * this.rowsPerPage;
249
- this.toRow = this.fromRow + this.rowsPerPage;
250
- const tableRowsContainer = this.el.shadowRoot.querySelector(".table-row-container");
251
- if (this.previousRowsPerPage === this.rowsPerPage) {
252
- tableRowsContainer.scrollTop = 0;
599
+ truncateUpdatedData() {
600
+ if (this.dataUpdated) {
601
+ if (this.truncationPattern === this.SHOW_HIDE_STRING) {
602
+ this.getTypographyElements().forEach((typographyEl) => {
603
+ const truncWrapper = this.getTruncWrapper(typographyEl);
604
+ const cellContainer = this.getCellContainer(typographyEl);
605
+ if ((cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight) - this.DEFAULT_LINE_HEIGHT >=
606
+ (truncWrapper === null || truncWrapper === void 0 ? void 0 : truncWrapper.scrollHeight)) {
607
+ this.resetShowHideTruncation(typographyEl);
608
+ return;
609
+ }
610
+ setTimeout(() => {
611
+ // slight delay due to data rendering
612
+ if ((typographyEl === null || typographyEl === void 0 ? void 0 : typographyEl.scrollHeight) > (cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight)) {
613
+ this.addShowHideTruncation(cellContainer, typographyEl);
614
+ }
615
+ }, 150);
616
+ });
617
+ }
618
+ if (this.truncationPattern === this.TOOLTIP_STRING) {
619
+ this.updateTruncationTooltip();
620
+ }
621
+ this.dataUpdated = false;
253
622
  }
254
- else if (this.previousRowsPerPage < this.rowsPerPage) {
255
- tableRowsContainer.scrollTop = this.scrollOffset;
256
- this.previousRowsPerPage = this.rowsPerPage;
623
+ if (this.tableSorted) {
624
+ if (this.truncationPattern === this.TOOLTIP_STRING) {
625
+ this.updateTruncationTooltip();
626
+ }
627
+ if (this.truncationPattern === this.SHOW_HIDE_STRING) {
628
+ this.getTypographyElements().forEach((typographyEl) => {
629
+ const cellContainer = this.getCellContainer(typographyEl);
630
+ if (!cellContainer.classList.contains(this.TEXT_WRAP_STRING)) {
631
+ this.createShowHideTruncation(typographyEl, cellContainer);
632
+ }
633
+ else {
634
+ typographyEl.resetTruncation().then(() => {
635
+ cellContainer.removeAttribute("style");
636
+ });
637
+ }
638
+ });
639
+ }
640
+ this.tableSorted = false;
257
641
  }
258
- else {
642
+ // This function recalculates the tooltip truncation when the rowHeight has been set.
643
+ // This is in componentDidUpdate so a setTimeout is not used to wait for the render to be complete
644
+ if (this.rowHeightSet) {
645
+ const fontSize = parseInt(getComputedStyle(document.documentElement).fontSize);
646
+ const hasAutoRowHeight = this.globalRowHeight === "auto";
647
+ this.getTypographyElements().forEach((typographyEl) => {
648
+ var _a;
649
+ const cellContainer = this.getCellContainer(typographyEl);
650
+ const tooltipEl = this.getTooltip(typographyEl);
651
+ if (hasAutoRowHeight) {
652
+ cellContainer.style.height = null;
653
+ if (this.truncationPattern === this.TOOLTIP_STRING) {
654
+ this.removeTooltip(cellContainer, typographyEl, tooltipEl);
655
+ typographyEl.setAttribute("style", `--ic-line-clamp: 0`);
656
+ }
657
+ else if (this.truncationPattern === this.SHOW_HIDE_STRING) {
658
+ this.resetShowHideTruncation(typographyEl);
659
+ }
660
+ return;
661
+ }
662
+ const rowHeight = fontSize *
663
+ parseFloat(cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));
664
+ // If the set row height is bigger than the cell container even
665
+ // with textWrap, set the row height
666
+ if (!((_a = cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.style) === null || _a === void 0 ? void 0 : _a.height) &&
667
+ rowHeight > cellContainer.clientHeight &&
668
+ !cellContainer.classList.contains(this.TEXT_WRAP_STRING)) {
669
+ cellContainer.style.setProperty(this.ROW_HEIGHT_CSS_VARIABLE, cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));
670
+ }
671
+ if (this.truncationPattern) {
672
+ // If the set row height is bigger than the typography truncation wrapper
673
+ // scroll height, remove see more / see less button
674
+ if (this.truncationPattern === this.SHOW_HIDE_STRING) {
675
+ const truncWrapper = this.getTruncWrapper(typographyEl);
676
+ const showHideBtn = typographyEl.shadowRoot.querySelector("button");
677
+ if (showHideBtn &&
678
+ (truncWrapper === null || truncWrapper === void 0 ? void 0 : truncWrapper.scrollHeight) <= cellContainer.clientHeight) {
679
+ this.resetShowHideTruncation(typographyEl);
680
+ return;
681
+ }
682
+ }
683
+ this.truncate(typographyEl, cellContainer, tooltipEl);
684
+ }
685
+ else {
686
+ this.updateSetRowHeight(typographyEl);
687
+ }
688
+ });
689
+ this.rowHeightSet = false;
690
+ }
691
+ // Only run truncation on the new rows
692
+ // when the number of items per page has increased
693
+ if (this.itemsPerPageChange) {
694
+ const allRows = this.el.shadowRoot.querySelectorAll(".table-row");
695
+ if (this.rowsPerPage > this.previousItemsPerPage) {
696
+ const newRows = Array.from(allRows).slice(this.previousItemsPerPage);
697
+ newRows.forEach((row) => {
698
+ row
699
+ .querySelectorAll("ic-typography")
700
+ .forEach((typographyEl) => {
701
+ const cellContainer = this.getCellContainer(typographyEl);
702
+ const tooltipEl = this.getTooltip(typographyEl);
703
+ this.truncate(typographyEl, cellContainer, tooltipEl);
704
+ });
705
+ });
706
+ }
707
+ this.previousItemsPerPage = this.rowsPerPage;
708
+ this.itemsPerPageChange = false;
709
+ }
710
+ if (!this.initialLoad && this.icPageChangeEvent) {
711
+ if (this.truncationPattern === this.TOOLTIP_STRING) {
712
+ this.updateTruncationTooltip();
713
+ }
714
+ // set truncation to see more if opened and next/previous page is pressed
715
+ if (this.truncationPattern === this.SHOW_HIDE_STRING) {
716
+ this.getTypographyElements().forEach((typographyEl) => {
717
+ const cellContainer = this.getCellContainer(typographyEl);
718
+ const showHideBtn = typographyEl.shadowRoot.querySelector("button");
719
+ if ((typographyEl === null || typographyEl === void 0 ? void 0 : typographyEl.scrollHeight) > cellContainer.clientHeight &&
720
+ !showHideBtn) {
721
+ this.addShowHideTruncation(cellContainer, typographyEl);
722
+ }
723
+ });
724
+ }
725
+ this.icPageChangeEvent = false;
726
+ }
727
+ if (this.densityUpdate) {
728
+ this.getTypographyElements().forEach((typographyEl) => {
729
+ const cellContainer = this.getCellContainer(typographyEl);
730
+ const tooltipEl = this.getTooltip(typographyEl);
731
+ this.truncate(typographyEl, cellContainer, tooltipEl);
732
+ });
733
+ this.densityUpdate = false;
734
+ }
735
+ if (this.truncationPatternUpdated) {
736
+ if (this.truncationPattern === this.TOOLTIP_STRING) {
737
+ this.getTypographyElements().forEach((typographyEl) => {
738
+ const cellContainer = this.getCellContainer(typographyEl);
739
+ const tooltipEl = this.getTooltip(typographyEl);
740
+ if (typographyEl.scrollHeight > cellContainer.clientHeight) {
741
+ this.addTooltipTruncation(typographyEl, cellContainer, tooltipEl);
742
+ }
743
+ });
744
+ }
745
+ else if (this.truncationPattern === this.SHOW_HIDE_STRING) {
746
+ this.getTypographyElements().forEach((typographyEl) => {
747
+ const truncWrapper = this.getTruncWrapper(typographyEl);
748
+ const cellContainer = this.getCellContainer(typographyEl);
749
+ if ((cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight) - this.DEFAULT_LINE_HEIGHT >
750
+ (truncWrapper === null || truncWrapper === void 0 ? void 0 : truncWrapper.scrollHeight)) {
751
+ this.resetShowHideTruncation(typographyEl);
752
+ return;
753
+ }
754
+ if ((typographyEl === null || typographyEl === void 0 ? void 0 : typographyEl.scrollHeight) > (cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight)) {
755
+ this.addShowHideTruncation(cellContainer, typographyEl);
756
+ }
757
+ });
758
+ }
759
+ }
760
+ }
761
+ createShowHideTruncation(typographyEl, cellContainer) {
762
+ typographyEl.checkMaxLines(typographyEl.scrollHeight);
763
+ typographyEl.setAttribute("max-lines", `${Math.floor((cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight) / this.DEFAULT_LINE_HEIGHT)}`);
764
+ typographyEl.setShowHideExpanded(false);
765
+ cellContainer.style.setProperty(this.ROW_HEIGHT_CSS_VARIABLE, null);
766
+ }
767
+ addTooltipTruncation(typographyEl, cellContainer, tooltip) {
768
+ this.addLineClampCSS(typographyEl, cellContainer);
769
+ if (!tooltip) {
770
+ this.createTruncationTooltip(typographyEl, cellContainer);
771
+ }
772
+ }
773
+ addShowHideTruncation(cellContainer, typographyEl) {
774
+ cellContainer.classList.add(this.SHOW_HIDE_CSS_CLASS);
775
+ this.createShowHideTruncation(typographyEl, cellContainer);
776
+ }
777
+ getTruncWrapper(typographyEl) {
778
+ return typographyEl.shadowRoot.querySelector(".trunc-wrapper");
779
+ }
780
+ // Set the height to initial if row height is set and the show / hide truncation
781
+ // is clicked
782
+ handleTypographyTruncationExpandToggle({ detail, }) {
783
+ const { expanded, typographyEl } = detail;
784
+ const cellContainer = this.getCellContainer(typographyEl);
785
+ if (cellContainer.style.getPropertyValue(this.ROW_HEIGHT_CSS_VARIABLE) &&
786
+ expanded) {
787
+ cellContainer.style.setProperty(this.ROW_HEIGHT_CSS_VARIABLE, "inherit");
788
+ }
789
+ }
790
+ handlePageChange({ detail, target }) {
791
+ if (target.parentElement !== this.el) {
792
+ this.fromRow = (detail.value - 1) * this.rowsPerPage;
793
+ this.toRow = this.fromRow + this.rowsPerPage;
794
+ const tableRowsContainer = this.el.shadowRoot.querySelector(".table-row-container");
795
+ if (this.previousRowsPerPage === this.rowsPerPage) {
796
+ tableRowsContainer.scrollTop = 0;
797
+ }
798
+ else if (this.previousRowsPerPage < this.rowsPerPage) {
799
+ tableRowsContainer.scrollTop = this.scrollOffset;
800
+ this.previousRowsPerPage = this.rowsPerPage;
801
+ }
802
+ else {
803
+ this.previousRowsPerPage = this.rowsPerPage;
804
+ }
805
+ }
806
+ if (!this.initialLoad && this.previousPaginationPage !== detail.value) {
807
+ // This is to prevent icPageChange from triggering truncation on first load
808
+ this.icPageChangeEvent = true;
809
+ }
810
+ this.previousPaginationPage = detail.value;
811
+ this.initialLoad = false;
812
+ }
813
+ handleItemsPerPageChange({ detail, target, }) {
814
+ if (target.parentElement !== this.el) {
259
815
  this.previousRowsPerPage = this.rowsPerPage;
816
+ this.rowsPerPage = detail.value;
260
817
  }
818
+ this.itemsPerPageChange = true;
819
+ }
820
+ handleDensityChange(ev) {
821
+ this.density = ev.detail.value;
261
822
  }
262
823
  clickListener(ev) {
263
824
  if (ev.target !== this.el)
264
825
  this.selectedRow = undefined;
265
826
  }
827
+ loadingHandler(newValue) {
828
+ if (newValue)
829
+ this.startLoadingTimer();
830
+ if (this.loading) {
831
+ setTimeout(() => {
832
+ this.showLoadingIndicator();
833
+ }, 500);
834
+ }
835
+ }
836
+ truncationPatternHandler(newValue) {
837
+ if (newValue === this.TOOLTIP_STRING) {
838
+ this.resetShowHideTruncation();
839
+ this.updateTruncationTooltip(true);
840
+ // Not using debounceDataTruncation here due to resizeObserver not being triggered
841
+ this.getTypographyElements().forEach((typographyEl) => {
842
+ const cellContainer = this.getCellContainer(typographyEl);
843
+ const tooltip = this.getTooltip(typographyEl);
844
+ this.truncate(typographyEl, cellContainer, tooltip);
845
+ });
846
+ }
847
+ if (newValue === this.SHOW_HIDE_STRING) {
848
+ // ResizeObserver is trigger here due to the see more/see less links being removed.
849
+ // The resizeObserver will also apply the tooltip where relevant
850
+ this.updateTruncationTooltip(true);
851
+ this.getTypographyElements().forEach((typographyEl) => {
852
+ const truncWrapper = this.getTruncWrapper(typographyEl);
853
+ const cellContainer = this.getCellContainer(typographyEl);
854
+ if ((cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight) - this.DEFAULT_LINE_HEIGHT >
855
+ (truncWrapper === null || truncWrapper === void 0 ? void 0 : truncWrapper.scrollHeight)) {
856
+ this.resetShowHideTruncation(typographyEl);
857
+ return;
858
+ }
859
+ setTimeout(() => {
860
+ // slight delay due to data rendering
861
+ if ((typographyEl === null || typographyEl === void 0 ? void 0 : typographyEl.scrollHeight) > (cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight)) {
862
+ this.addShowHideTruncation(cellContainer, typographyEl);
863
+ }
864
+ }, 150);
865
+ });
866
+ }
867
+ this.truncationPatternUpdated = true;
868
+ }
869
+ async dataHandler(newData) {
870
+ this.loadingOptions = Object.assign(Object.assign({}, this.loadingOptions), { showBackground: (newData === null || newData === void 0 ? void 0 : newData.length) > 0 });
871
+ if (this.loading) {
872
+ !this.hasLoadedForOneSecond
873
+ ? setTimeout(() => (this.loading = false), this.minimumLoadingDisplayDuration -
874
+ (Date.now() - this.timerStarted))
875
+ : (this.loading = false);
876
+ }
877
+ if (this.updating)
878
+ this.updating = false;
879
+ this.dataUpdated = true;
880
+ }
881
+ async densityHandler() {
882
+ this.densityUpdate = true;
883
+ }
884
+ resetShowHideTruncation(typographyEl) {
885
+ if (typographyEl) {
886
+ const truncWrapper = this.getTruncWrapper(typographyEl);
887
+ const cellContainer = this.getCellContainer(typographyEl);
888
+ if ((truncWrapper === null || truncWrapper === void 0 ? void 0 : truncWrapper.scrollHeight) > (cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight) &&
889
+ !isEmptyString(typographyEl.getAttribute("max-lines")) &&
890
+ Math.floor((cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight) / this.DEFAULT_LINE_HEIGHT) !==
891
+ +typographyEl.getAttribute("max-lines")) {
892
+ typographyEl.checkMaxLines(truncWrapper.scrollHeight);
893
+ typographyEl.setAttribute("max-lines", `${Math.floor((cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight) / this.DEFAULT_LINE_HEIGHT)}`);
894
+ typographyEl.setShowHideExpanded(false);
895
+ cellContainer.style.setProperty(this.ROW_HEIGHT_CSS_VARIABLE, null);
896
+ }
897
+ else {
898
+ typographyEl.resetTruncation().then(() => {
899
+ if (!typographyEl.closest(this.TEXT_WRAP_CLASS)) {
900
+ cellContainer.style.setProperty(this.ROW_HEIGHT_CSS_VARIABLE, cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));
901
+ }
902
+ });
903
+ }
904
+ }
905
+ else {
906
+ this.getTypographyElements().forEach((typographyEl) => {
907
+ const cellContainer = this.getCellContainer(typographyEl);
908
+ typographyEl.resetTruncation().then(() => {
909
+ if (!typographyEl.closest(this.TEXT_WRAP_CLASS)) {
910
+ cellContainer.style.setProperty(this.ROW_HEIGHT_CSS_VARIABLE, cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));
911
+ }
912
+ });
913
+ });
914
+ }
915
+ }
916
+ rowHeightChangeHandler(newValue, oldValue) {
917
+ if (+newValue !== +oldValue) {
918
+ this.deleteTextWrapDataKey(this.data);
919
+ this.deleteTextWrapDataKey(this.columns);
920
+ this.removeTextWrap();
921
+ this.icRowHeightChange.emit();
922
+ this.rowHeightSet = true;
923
+ }
924
+ }
925
+ /**
926
+ * Resets the `globalRowHeight` prop to number or auto and sets the `variableRowHeight` prop to `null`.
927
+ */
928
+ async resetRowHeights(rowHeight) {
929
+ this.globalRowHeight = rowHeight || "auto";
930
+ this.variableRowHeight = null;
931
+ }
932
+ showLoadingIndicator() {
933
+ this.loadingIndicator.classList.add("show");
934
+ }
935
+ getRowOptions(rowKeys, rowValues) {
936
+ const rowOptionsIndex = rowKeys.indexOf("rowOptions");
937
+ return rowOptionsIndex > -1 && rowValues[rowOptionsIndex];
938
+ }
939
+ regenerateTooltip(cellContainer, typographyEl, tooltip, removeTooltipOnly) {
940
+ // When sorting the table, instead of regenerating the tooltip,
941
+ // the tooltip details are updated
942
+ if (tooltip) {
943
+ if (this.tableSorted) {
944
+ tooltip.setAttribute("target", typographyEl.id);
945
+ tooltip.setAttribute("label", typographyEl.textContent);
946
+ }
947
+ else {
948
+ this.removeTooltip(cellContainer, typographyEl, tooltip);
949
+ }
950
+ if (removeTooltipOnly) {
951
+ return;
952
+ }
953
+ }
954
+ // This add line clamp to data only when
955
+ // the data object has been updated
956
+ if (!typographyEl.getAttribute("style") && this.dataUpdated) {
957
+ this.addLineClampCSS(typographyEl, cellContainer);
958
+ }
959
+ if ((typographyEl === null || typographyEl === void 0 ? void 0 : typographyEl.scrollHeight) > (cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight) &&
960
+ this.truncationPattern === this.TOOLTIP_STRING) {
961
+ if (!typographyEl.getAttribute("style") ||
962
+ typographyEl.style.cssText.includes("--ic-line-clamp: 0;")) {
963
+ this.addLineClampCSS(typographyEl, cellContainer);
964
+ }
965
+ this.createTruncationTooltip(typographyEl, cellContainer);
966
+ }
967
+ }
968
+ removeTooltip(cellContainer, typographyEl, tooltip) {
969
+ cellContainer.appendChild(typographyEl);
970
+ if (tooltip) {
971
+ tooltip.remove();
972
+ }
973
+ }
974
+ addLineClampCSS(typographyEl, cellContainer) {
975
+ typographyEl.setAttribute("style", `--ic-line-clamp: ${this.getLines(cellContainer === null || cellContainer === void 0 ? void 0 : cellContainer.clientHeight)}`);
976
+ }
977
+ createTruncationTooltip(typographyEl, cellContainer) {
978
+ const tooltipEl = document.createElement("ic-tooltip");
979
+ tooltipEl.setAttribute("target", typographyEl.id);
980
+ tooltipEl.setAttribute("label", typographyEl.textContent);
981
+ tooltipEl.classList.add("ic-tooltip-overflow");
982
+ tooltipEl.setExternalPopperProps({
983
+ // This might need reverting back to absolute if the tooltip doesn't dynamically position itself correctly
984
+ strategy: "fixed",
985
+ });
986
+ cellContainer.appendChild(tooltipEl);
987
+ tooltipEl.appendChild(typographyEl);
988
+ }
266
989
  render() {
267
- const { caption, createColumnHeaders, createRows, data, hideColumnHeaders, paginationOptions, scrollable, scrollOffset, showPagination, sortable, sortedColumnOrder, sortedColumn, stickyColumnHeaders, updateScrollOffset, } = this;
268
- return (h("div", { class: "table-container" }, h("div", { class: {
990
+ const { caption, createColumnHeaders, createRows, createUpdatingIndicator, data, hideColumnHeaders, loading, loadingOptions, paginationBarOptions, scrollable, scrollOffset, showPagination, sortable, sortedColumnOrder, sortedColumn, stickyColumnHeaders, updateScrollOffset, updating, } = this;
991
+ return (h(Host, { style: Object.assign({}, this.setTableDimensions()) }, h("div", { class: "table-container" }, isSlotUsed(this.el, "title-bar") && h("slot", { name: "title-bar" }), h("div", { class: {
269
992
  ["table-row-container"]: true,
270
993
  scrollable,
271
- }, tabIndex: scrollable ? 0 : null, onScroll: updateScrollOffset }, h("table", null, h("caption", { class: "table-caption" }, caption), !hideColumnHeaders && (h("thead", { class: {
994
+ }, tabIndex: scrollable ? 0 : null, onScroll: updateScrollOffset }, isSlotUsed(this.el, "title-bar") && h("slot", { name: "title-bar" }), h("table", { style: {
995
+ ["--table-layout"]: this.tableLayout,
996
+ } }, h("caption", { class: "table-caption" }, caption), !hideColumnHeaders && (h("thead", { class: {
272
997
  ["column-header-sticky"]: stickyColumnHeaders,
273
998
  ["column-header-overlay"]: stickyColumnHeaders && scrollOffset !== 0,
274
- } }, h("tr", null, createColumnHeaders()))), (data === null || data === void 0 ? void 0 : data.length) > 0 && h("tbody", null, createRows()))), showPagination && (h("div", { class: "pagination-container" }, h("ic-pagination-bar", { totalItems: data.length, paginationType: paginationOptions.type, paginationControl: paginationOptions.control, showItemsPerPageControl: paginationOptions.itemsPerPageControl, showGoToPageControl: paginationOptions.goToPageControl, itemsPerPageOptions: paginationOptions.itemsPerPage, alignment: paginationOptions.alignment }))), sortable && (h("div", { class: "screen-reader-sort-text", "aria-live": "polite" }, sortedColumnOrder !== "unsorted" && sortedColumn
999
+ } }, h("tr", null, createColumnHeaders()))), updating &&
1000
+ !loading &&
1001
+ (hideColumnHeaders ? (h("thead", null, createUpdatingIndicator())) : (createUpdatingIndicator())), (data === null || data === void 0 ? void 0 : data.length) > 0 && !loading && h("tbody", null, createRows())), !(data === null || data === void 0 ? void 0 : data.length) &&
1002
+ !loading &&
1003
+ (isSlotUsed(this.el, "empty-state") ? (h("slot", { name: "empty-state" })) : (h("ic-empty-state", { aligned: "center", heading: "No Data", class: "loading-empty" })))), loading && (h("ic-loading-indicator", { appearance: loadingOptions === null || loadingOptions === void 0 ? void 0 : loadingOptions.appearance, class: {
1004
+ "loading-empty": loading,
1005
+ loading: true,
1006
+ "show-background": loadingOptions.showBackground,
1007
+ }, description: loadingOptions.description || "Loading table data", label: loadingOptions.label || "Loading...", labelDuration: loadingOptions === null || loadingOptions === void 0 ? void 0 : loadingOptions.labelDuration, max: loadingOptions === null || loadingOptions === void 0 ? void 0 : loadingOptions.max, min: loadingOptions === null || loadingOptions === void 0 ? void 0 : loadingOptions.min, progress: loadingOptions === null || loadingOptions === void 0 ? void 0 : loadingOptions.progress, ref: (el) => (this.loadingIndicator = el) })), (showPagination || isSlotUsed(this.el, "pagination-bar")) && (h("div", { class: "pagination-container" }, isSlotUsed(this.el, "pagination-bar") ? (h("slot", { name: "pagination-bar" })) : (h("ic-pagination-bar", { totalItems: data.length, type: paginationBarOptions.type, rangeLabelType: paginationBarOptions.rangeLabelType, showItemsPerPageControl: paginationBarOptions.showItemsPerPageControl, showGoToPageControl: paginationBarOptions.showGoToPageControl, itemsPerPageOptions: paginationBarOptions.itemsPerPageOptions, alignment: paginationBarOptions.alignment, appearance: paginationBarOptions.appearance, itemLabel: paginationBarOptions.itemLabel, pageLabel: paginationBarOptions.pageLabel, hideRangeLabel: paginationBarOptions.hideRangeLabel })))), sortable && (h("div", { class: "screen-reader-sort-text", "aria-live": "polite" }, sortedColumnOrder !== "unsorted" && sortedColumn
275
1008
  ? `${sortedColumn} sorted ${sortedColumnOrder}`
276
- : "table unsorted"))));
1009
+ : "table unsorted")))));
277
1010
  }
278
1011
  get el() { return this; }
1012
+ static get watchers() { return {
1013
+ "loading": ["loadingHandler"],
1014
+ "truncationPattern": ["truncationPatternHandler"],
1015
+ "data": ["dataHandler"],
1016
+ "density": ["densityHandler"],
1017
+ "globalRowHeight": ["rowHeightChangeHandler"],
1018
+ "variableRowHeight": ["rowHeightChangeHandler"]
1019
+ }; }
279
1020
  static get style() { return icDataTableCss; }
280
1021
  }, [1, "ic-data-table", {
281
1022
  "caption": [1],
282
1023
  "columns": [16],
283
1024
  "data": [16],
284
- "density": [1],
1025
+ "density": [1025],
285
1026
  "embedded": [4],
1027
+ "globalRowHeight": [1032, "global-row-height"],
1028
+ "height": [1],
286
1029
  "hideColumnHeaders": [4, "hide-column-headers"],
287
- "paginationOptions": [16],
1030
+ "loading": [1028],
1031
+ "loadingOptions": [16],
1032
+ "maxWidth": [1, "max-width"],
1033
+ "minWidth": [1, "min-width"],
1034
+ "minimumLoadingDisplayDuration": [2, "minimum-loading-display-duration"],
1035
+ "paginationBarOptions": [16],
288
1036
  "showPagination": [4, "show-pagination"],
289
1037
  "sortable": [4],
290
1038
  "sortOptions": [16],
291
1039
  "stickyColumnHeaders": [4, "sticky-column-headers"],
292
1040
  "stickyRowHeaders": [4, "sticky-row-headers"],
1041
+ "tableLayout": [1, "table-layout"],
1042
+ "truncationPattern": [1, "truncation-pattern"],
1043
+ "updating": [4],
1044
+ "updatingOptions": [16],
1045
+ "variableRowHeight": [1040],
1046
+ "width": [1],
293
1047
  "fromRow": [32],
294
1048
  "previousRowsPerPage": [32],
295
1049
  "rowsPerPage": [32],
@@ -298,13 +1052,23 @@ const DataTable = /*@__PURE__*/ proxyCustomElement(class DataTable extends HTMLE
298
1052
  "selectedRow": [32],
299
1053
  "sortedColumn": [32],
300
1054
  "sortedColumnOrder": [32],
301
- "toRow": [32]
302
- }, [[0, "icItemsPerPageChange", "handleItemsPerPageChange"], [0, "icPageChange", "handlePageChange"], [8, "click", "clickListener"]]]);
1055
+ "toRow": [32],
1056
+ "currentRowHeight": [32],
1057
+ "debounceDelay": [32],
1058
+ "resetRowHeights": [64]
1059
+ }, [[0, "typographyTruncationExpandToggle", "handleTypographyTruncationExpandToggle"], [0, "icPageChange", "handlePageChange"], [0, "icItemsPerPageChange", "handleItemsPerPageChange"], [0, "icTableDensityUpdate", "handleDensityChange"], [8, "click", "clickListener"]], {
1060
+ "loading": ["loadingHandler"],
1061
+ "truncationPattern": ["truncationPatternHandler"],
1062
+ "data": ["dataHandler"],
1063
+ "density": ["densityHandler"],
1064
+ "globalRowHeight": ["rowHeightChangeHandler"],
1065
+ "variableRowHeight": ["rowHeightChangeHandler"]
1066
+ }]);
303
1067
  function defineCustomElement$1() {
304
1068
  if (typeof customElements === "undefined") {
305
1069
  return;
306
1070
  }
307
- const components = ["ic-data-table", "ic-button", "ic-input-component-container", "ic-input-container", "ic-input-label", "ic-input-validation", "ic-link", "ic-loading-indicator", "ic-menu", "ic-pagination", "ic-pagination-bar", "ic-pagination-item", "ic-select", "ic-text-field", "ic-tooltip", "ic-typography"];
1071
+ const components = ["ic-data-table", "ic-button", "ic-empty-state", "ic-input-component-container", "ic-input-container", "ic-input-label", "ic-input-validation", "ic-link", "ic-loading-indicator", "ic-menu", "ic-pagination", "ic-pagination-bar", "ic-pagination-item", "ic-select", "ic-text-field", "ic-tooltip", "ic-typography"];
308
1072
  components.forEach(tagName => { switch (tagName) {
309
1073
  case "ic-data-table":
310
1074
  if (!customElements.get(tagName)) {
@@ -312,6 +1076,11 @@ function defineCustomElement$1() {
312
1076
  }
313
1077
  break;
314
1078
  case "ic-button":
1079
+ if (!customElements.get(tagName)) {
1080
+ defineCustomElement$h();
1081
+ }
1082
+ break;
1083
+ case "ic-empty-state":
315
1084
  if (!customElements.get(tagName)) {
316
1085
  defineCustomElement$g();
317
1086
  }