@ukic/canary-web-components 2.0.0-canary.21 → 2.0.0-canary.22

Sign up to get free protection for your applications and to get access to all the features.
Files changed (398) hide show
  1. package/dist/cjs/core.cjs.js +1 -1
  2. package/dist/cjs/{helpers-081d6031.js → helpers-093368be.js} +3 -1
  3. package/dist/cjs/helpers-093368be.js.map +1 -0
  4. package/dist/cjs/{helpers-261701cd.js → helpers-85c5ca15.js} +14 -1
  5. package/dist/cjs/helpers-85c5ca15.js.map +1 -0
  6. package/dist/cjs/ic-accordion-group.cjs.entry.js +1 -1
  7. package/dist/cjs/ic-accordion.cjs.entry.js +1 -1
  8. package/dist/cjs/ic-alert.cjs.entry.js +1 -1
  9. package/dist/cjs/ic-back-to-top.cjs.entry.js +1 -1
  10. package/dist/cjs/ic-badge.cjs.entry.js +1 -1
  11. package/dist/cjs/ic-breadcrumb-group.cjs.entry.js +1 -1
  12. package/dist/cjs/ic-breadcrumb.cjs.entry.js +1 -1
  13. package/dist/cjs/ic-button_3.cjs.entry.js +11 -6
  14. package/dist/cjs/ic-button_3.cjs.entry.js.map +1 -1
  15. package/dist/cjs/ic-card-horizontal.cjs.entry.js +1 -1
  16. package/dist/cjs/ic-card.cjs.entry.js +1 -1
  17. package/dist/cjs/ic-checkbox-group.cjs.entry.js +1 -1
  18. package/dist/cjs/ic-checkbox.cjs.entry.js +1 -1
  19. package/dist/cjs/ic-chip.cjs.entry.js +9 -3
  20. package/dist/cjs/ic-chip.cjs.entry.js.map +1 -1
  21. package/dist/cjs/ic-data-row.cjs.entry.js +1 -1
  22. package/dist/cjs/ic-data-table-title-bar.cjs.entry.js +1 -1
  23. package/dist/cjs/ic-data-table.cjs.entry.js +526 -71
  24. package/dist/cjs/ic-data-table.cjs.entry.js.map +1 -1
  25. package/dist/cjs/ic-date-input.cjs.entry.js +4 -3
  26. package/dist/cjs/ic-date-input.cjs.entry.js.map +1 -1
  27. package/dist/cjs/ic-date-picker.cjs.entry.js +5 -1
  28. package/dist/cjs/ic-date-picker.cjs.entry.js.map +1 -1
  29. package/dist/cjs/ic-dialog.cjs.entry.js +1 -1
  30. package/dist/cjs/ic-divider.cjs.entry.js +1 -1
  31. package/dist/cjs/ic-empty-state_2.cjs.entry.js +2 -2
  32. package/dist/cjs/ic-footer-link-group.cjs.entry.js +1 -1
  33. package/dist/cjs/ic-footer-link.cjs.entry.js +1 -1
  34. package/dist/cjs/ic-footer.cjs.entry.js +1 -1
  35. package/dist/cjs/ic-hero.cjs.entry.js +1 -1
  36. package/dist/cjs/ic-horizontal-scroll.cjs.entry.js +1 -1
  37. package/dist/cjs/ic-input-component-container_4.cjs.entry.js +1 -1
  38. package/dist/cjs/ic-link.cjs.entry.js +1 -1
  39. package/dist/cjs/ic-menu-group.cjs.entry.js +1 -1
  40. package/dist/cjs/ic-menu-item.cjs.entry.js +1 -1
  41. package/dist/cjs/ic-menu-with-multi.cjs.entry.js +1 -1
  42. package/dist/cjs/ic-menu.cjs.entry.js +1 -1
  43. package/dist/cjs/ic-navigation-button.cjs.entry.js +1 -1
  44. package/dist/cjs/ic-navigation-group.cjs.entry.js +1 -1
  45. package/dist/cjs/ic-navigation-item.cjs.entry.js +1 -1
  46. package/dist/cjs/ic-navigation-menu.cjs.entry.js +1 -1
  47. package/dist/cjs/ic-page-header.cjs.entry.js +1 -1
  48. package/dist/cjs/ic-pagination_4.cjs.entry.js +1 -1
  49. package/dist/cjs/ic-popover-menu.cjs.entry.js +1 -1
  50. package/dist/cjs/ic-radio-group.cjs.entry.js +41 -22
  51. package/dist/cjs/ic-radio-group.cjs.entry.js.map +1 -1
  52. package/dist/cjs/ic-radio-option.cjs.entry.js +1 -1
  53. package/dist/cjs/ic-search-bar.cjs.entry.js +1 -1
  54. package/dist/cjs/ic-select-with-multi.cjs.entry.js +1 -1
  55. package/dist/cjs/ic-side-navigation.cjs.entry.js +1 -1
  56. package/dist/cjs/ic-status-tag.cjs.entry.js +1 -1
  57. package/dist/cjs/ic-step.cjs.entry.js +1 -1
  58. package/dist/cjs/ic-stepper.cjs.entry.js +1 -1
  59. package/dist/cjs/ic-switch.cjs.entry.js +1 -1
  60. package/dist/cjs/ic-tab-group.cjs.entry.js +1 -1
  61. package/dist/cjs/ic-tab-panel.cjs.entry.js +1 -1
  62. package/dist/cjs/ic-tab.cjs.entry.js +1 -1
  63. package/dist/cjs/ic-theme.cjs.entry.js +1 -1
  64. package/dist/cjs/ic-toast.cjs.entry.js +1 -1
  65. package/dist/cjs/ic-toggle-button.cjs.entry.js +1 -1
  66. package/dist/cjs/ic-top-navigation.cjs.entry.js +1 -1
  67. package/dist/cjs/ic-tree-item.cjs.entry.js +241 -0
  68. package/dist/cjs/ic-tree-item.cjs.entry.js.map +1 -0
  69. package/dist/cjs/ic-tree-view.cjs.entry.js +203 -0
  70. package/dist/cjs/ic-tree-view.cjs.entry.js.map +1 -0
  71. package/dist/cjs/ic-typography.cjs.entry.js +47 -12
  72. package/dist/cjs/ic-typography.cjs.entry.js.map +1 -1
  73. package/dist/cjs/index-4cf27b16.js +8 -0
  74. package/dist/cjs/loader.cjs.js +1 -1
  75. package/dist/collection/assets/arrow-dropdown.svg +3 -0
  76. package/dist/collection/collection-manifest.json +3 -1
  77. package/dist/collection/components/ic-data-table/ic-data-table.css +55 -5
  78. package/dist/collection/components/ic-data-table/ic-data-table.js +570 -77
  79. package/dist/collection/components/ic-data-table/ic-data-table.js.map +1 -1
  80. package/dist/collection/components/ic-data-table/ic-data-table.types.js.map +1 -1
  81. package/dist/collection/components/ic-data-table/story-data.js +364 -21
  82. package/dist/collection/components/ic-data-table/story-data.js.map +1 -1
  83. package/dist/collection/components/ic-data-table/test/basic/ic-data-table.spec.js +1 -1
  84. package/dist/collection/components/ic-data-table/test/basic/ic-data-table.spec.js.map +1 -1
  85. package/dist/collection/components/ic-date-input/ic-date-input.js +21 -2
  86. package/dist/collection/components/ic-date-input/ic-date-input.js.map +1 -1
  87. package/dist/collection/components/ic-date-input/test/basic/ic-date-input.spec.js +7 -0
  88. package/dist/collection/components/ic-date-input/test/basic/ic-date-input.spec.js.map +1 -1
  89. package/dist/collection/components/ic-date-picker/ic-date-picker.js +22 -0
  90. package/dist/collection/components/ic-date-picker/ic-date-picker.js.map +1 -1
  91. package/dist/collection/components/ic-tree-item/ic-tree-item.css +150 -0
  92. package/dist/collection/components/ic-tree-item/ic-tree-item.js +592 -0
  93. package/dist/collection/components/ic-tree-item/ic-tree-item.js.map +1 -0
  94. package/dist/collection/components/ic-tree-item/test/basic/ic-tree-item.spec.js +114 -0
  95. package/dist/collection/components/ic-tree-item/test/basic/ic-tree-item.spec.js.map +1 -0
  96. package/dist/collection/components/ic-tree-view/ic-tree-view.css +56 -0
  97. package/dist/collection/components/ic-tree-view/ic-tree-view.js +296 -0
  98. package/dist/collection/components/ic-tree-view/ic-tree-view.js.map +1 -0
  99. package/dist/collection/components/ic-tree-view/test/basic/ic-tree-view.spec.js +85 -0
  100. package/dist/collection/components/ic-tree-view/test/basic/ic-tree-view.spec.js.map +1 -0
  101. package/dist/components/helpers.js +2 -1
  102. package/dist/components/helpers.js.map +1 -1
  103. package/dist/components/helpers2.js +11 -1
  104. package/dist/components/helpers2.js.map +1 -1
  105. package/dist/components/ic-alert2.js +1 -1
  106. package/dist/components/ic-back-to-top.js +1 -1
  107. package/dist/components/ic-badge.js +1 -1
  108. package/dist/components/ic-breadcrumb-group.js +1 -1
  109. package/dist/components/ic-breadcrumb2.js +1 -1
  110. package/dist/components/ic-button2.js +1 -1
  111. package/dist/components/ic-card.js +1 -1
  112. package/dist/components/ic-checkbox-group.js +1 -1
  113. package/dist/components/ic-checkbox.js +1 -1
  114. package/dist/components/ic-chip.js +9 -3
  115. package/dist/components/ic-chip.js.map +1 -1
  116. package/dist/components/ic-data-row.js +1 -1
  117. package/dist/components/ic-data-table.js +531 -72
  118. package/dist/components/ic-data-table.js.map +1 -1
  119. package/dist/components/ic-date-input2.js +5 -3
  120. package/dist/components/ic-date-input2.js.map +1 -1
  121. package/dist/components/ic-date-picker.js +6 -1
  122. package/dist/components/ic-date-picker.js.map +1 -1
  123. package/dist/components/ic-dialog.js +1 -1
  124. package/dist/components/ic-divider2.js +1 -1
  125. package/dist/components/ic-empty-state2.js +1 -1
  126. package/dist/components/ic-footer-link-group.js +1 -1
  127. package/dist/components/ic-footer-link.js +1 -1
  128. package/dist/components/ic-footer.js +1 -1
  129. package/dist/components/ic-hero.js +1 -1
  130. package/dist/components/ic-horizontal-scroll2.js +1 -1
  131. package/dist/components/ic-input-component-container2.js +1 -1
  132. package/dist/components/ic-input-label2.js +1 -1
  133. package/dist/components/ic-input-validation2.js +1 -1
  134. package/dist/components/ic-link2.js +1 -1
  135. package/dist/components/ic-loading-indicator2.js +1 -1
  136. package/dist/components/ic-menu-group.js +1 -1
  137. package/dist/components/ic-menu-item2.js +1 -1
  138. package/dist/components/ic-menu3.js +1 -1
  139. package/dist/components/ic-navigation-button.js +1 -1
  140. package/dist/components/ic-navigation-group.js +1 -1
  141. package/dist/components/ic-navigation-item.js +1 -1
  142. package/dist/components/ic-navigation-menu2.js +1 -1
  143. package/dist/components/ic-page-header.js +1 -1
  144. package/dist/components/ic-pagination-bar2.js +1 -1
  145. package/dist/components/ic-pagination-item2.js +1 -1
  146. package/dist/components/ic-popover-menu.js +1 -1
  147. package/dist/components/ic-radio-group.js +41 -22
  148. package/dist/components/ic-radio-group.js.map +1 -1
  149. package/dist/components/ic-radio-option.js +1 -1
  150. package/dist/components/ic-search-bar.js +1 -1
  151. package/dist/components/ic-select-with-multi.js +1 -1
  152. package/dist/components/ic-select2.js +1 -1
  153. package/dist/components/ic-side-navigation.js +1 -1
  154. package/dist/components/ic-step.js +1 -1
  155. package/dist/components/ic-stepper.js +1 -1
  156. package/dist/components/ic-switch.js +1 -1
  157. package/dist/components/ic-tab-panel.js +1 -1
  158. package/dist/components/ic-text-field2.js +1 -1
  159. package/dist/components/ic-theme.js +1 -1
  160. package/dist/components/ic-toast.js +1 -1
  161. package/dist/components/ic-tooltip2.js +12 -5
  162. package/dist/components/ic-tooltip2.js.map +1 -1
  163. package/dist/components/ic-top-navigation.js +1 -1
  164. package/dist/components/ic-tree-item.d.ts +11 -0
  165. package/dist/components/ic-tree-item.js +286 -0
  166. package/dist/components/ic-tree-item.js.map +1 -0
  167. package/dist/components/ic-tree-view.d.ts +11 -0
  168. package/dist/components/ic-tree-view.js +237 -0
  169. package/dist/components/ic-tree-view.js.map +1 -0
  170. package/dist/components/ic-typography2.js +53 -15
  171. package/dist/components/ic-typography2.js.map +1 -1
  172. package/dist/core/core.esm.js +1 -1
  173. package/dist/core/core.esm.js.map +1 -1
  174. package/dist/core/{p-e5b1dd58.entry.js → p-0180e00a.entry.js} +2 -2
  175. package/dist/core/{p-7f690fa3.entry.js → p-046f4de6.entry.js} +2 -2
  176. package/dist/core/{p-d5d36143.entry.js → p-06732eaf.entry.js} +2 -2
  177. package/dist/core/p-0ec04c16.entry.js +2 -0
  178. package/dist/core/p-0ec04c16.entry.js.map +1 -0
  179. package/dist/core/{p-01297278.entry.js → p-13993bf3.entry.js} +2 -2
  180. package/dist/core/{p-693a77bb.entry.js → p-16a48a63.entry.js} +2 -2
  181. package/dist/core/{p-d91428b4.entry.js → p-216fbd5e.entry.js} +2 -2
  182. package/dist/core/{p-a8c97918.entry.js → p-2d063032.entry.js} +2 -2
  183. package/dist/core/{p-2647931d.entry.js → p-2ee5d3fb.entry.js} +2 -2
  184. package/dist/core/p-355c8532.entry.js +2 -0
  185. package/dist/core/p-355c8532.entry.js.map +1 -0
  186. package/dist/core/p-3a59391f.entry.js +2 -0
  187. package/dist/core/{p-66595f5f.entry.js.map → p-3a59391f.entry.js.map} +1 -1
  188. package/dist/core/{p-007da09d.entry.js → p-3f2723aa.entry.js} +2 -2
  189. package/dist/core/p-401d0c66.entry.js +2 -0
  190. package/dist/core/p-401d0c66.entry.js.map +1 -0
  191. package/dist/core/p-413e68be.entry.js +2 -0
  192. package/dist/core/{p-a4585c7e.entry.js.map → p-413e68be.entry.js.map} +1 -1
  193. package/dist/core/{p-a970d653.entry.js → p-418a84d4.entry.js} +2 -2
  194. package/dist/core/{p-354e5dbe.entry.js → p-41916ef7.entry.js} +2 -2
  195. package/dist/core/p-4309460f.entry.js +2 -0
  196. package/dist/core/p-4309460f.entry.js.map +1 -0
  197. package/dist/core/{p-6f8fd43e.entry.js → p-486a6957.entry.js} +2 -2
  198. package/dist/core/{p-b3ed5423.entry.js → p-5348af01.entry.js} +2 -2
  199. package/dist/core/p-57043b1e.entry.js +2 -0
  200. package/dist/core/{p-d68e0c94.entry.js.map → p-57043b1e.entry.js.map} +1 -1
  201. package/dist/core/{p-6b74397a.entry.js → p-59993f36.entry.js} +2 -2
  202. package/dist/core/{p-be4c0cc8.entry.js → p-6398a726.entry.js} +2 -2
  203. package/dist/core/{p-9e7a5c72.entry.js → p-648fb902.entry.js} +2 -2
  204. package/dist/core/{p-d3ea79e1.entry.js → p-673a4a62.entry.js} +2 -2
  205. package/dist/core/{p-fb4219d6.entry.js → p-67ae9d37.entry.js} +2 -2
  206. package/dist/core/{p-0ea28e7a.entry.js → p-6b01e096.entry.js} +2 -2
  207. package/dist/core/{p-40fc7162.entry.js → p-6b1fcf87.entry.js} +2 -2
  208. package/dist/core/{p-1d0cff8a.entry.js → p-6fb3d61e.entry.js} +2 -2
  209. package/dist/core/{p-1733278a.entry.js → p-789ae7f5.entry.js} +2 -2
  210. package/dist/core/{p-45ebcb74.js → p-8128572e.js} +2 -2
  211. package/dist/{esm/helpers-d41662f3.js.map → core/p-8128572e.js.map} +1 -1
  212. package/dist/core/p-84eaa486.entry.js +2 -0
  213. package/dist/core/p-84eaa486.entry.js.map +1 -0
  214. package/dist/core/{p-0944d33b.entry.js → p-89c7ea3e.entry.js} +2 -2
  215. package/dist/core/{p-96670e29.entry.js → p-8d276e8f.entry.js} +2 -2
  216. package/dist/core/{p-569a68c0.entry.js → p-91cf89c8.entry.js} +2 -2
  217. package/dist/core/p-91cf89c8.entry.js.map +1 -0
  218. package/dist/core/p-969cadfa.entry.js +2 -0
  219. package/dist/core/p-969cadfa.entry.js.map +1 -0
  220. package/dist/core/{p-d44b7f21.entry.js → p-97f141a6.entry.js} +2 -2
  221. package/dist/core/{p-9f8ef2bc.entry.js → p-99185fd5.entry.js} +2 -2
  222. package/dist/core/{p-1ac733c1.entry.js → p-99f96c33.entry.js} +2 -2
  223. package/dist/core/{p-4e6f7cfe.entry.js → p-a052bb95.entry.js} +2 -2
  224. package/dist/core/{p-9e69f517.entry.js → p-a72af8db.entry.js} +2 -2
  225. package/dist/core/{p-ae7c2c39.entry.js → p-a787bba7.entry.js} +2 -2
  226. package/dist/core/{p-e393e53c.entry.js → p-aa72f551.entry.js} +2 -2
  227. package/dist/core/{p-3d9eca50.entry.js → p-aaaa9261.entry.js} +2 -2
  228. package/dist/core/p-adbe0d89.js +2 -0
  229. package/dist/core/p-adbe0d89.js.map +1 -0
  230. package/dist/core/{p-a589ead8.entry.js → p-b29e96b5.entry.js} +2 -2
  231. package/dist/core/p-b97eba08.entry.js +2 -0
  232. package/dist/core/p-b97eba08.entry.js.map +1 -0
  233. package/dist/core/{p-fab8da25.entry.js → p-bfc5f3f4.entry.js} +2 -2
  234. package/dist/core/{p-e2421111.entry.js → p-cb3afdbf.entry.js} +2 -2
  235. package/dist/core/{p-d06c0049.entry.js → p-ccf72538.entry.js} +2 -2
  236. package/dist/core/{p-0551f0cf.entry.js → p-ce0999f1.entry.js} +2 -2
  237. package/dist/core/{p-01008e8d.entry.js → p-d02a4d1b.entry.js} +2 -2
  238. package/dist/core/{p-ffeca3c7.entry.js → p-d8322108.entry.js} +2 -2
  239. package/dist/core/{p-fdacc7f7.entry.js → p-d86cdbc8.entry.js} +2 -2
  240. package/dist/core/{p-59d9ea22.entry.js → p-da8255b8.entry.js} +2 -2
  241. package/dist/core/{p-6e697a16.entry.js → p-e9f5ebb3.entry.js} +2 -2
  242. package/dist/core/p-e9f5ebb3.entry.js.map +1 -0
  243. package/dist/core/{p-145c8074.entry.js → p-ede631c5.entry.js} +2 -2
  244. package/dist/core/{p-d39239be.entry.js → p-f09b2041.entry.js} +2 -2
  245. package/dist/core/{p-169bcf0f.entry.js → p-f1044e4d.entry.js} +2 -2
  246. package/dist/core/{p-3be4aae0.entry.js → p-f10f7f37.entry.js} +2 -2
  247. package/dist/core/{p-a6d3743c.entry.js → p-fa77211d.entry.js} +2 -2
  248. package/dist/esm/core.js +1 -1
  249. package/dist/esm/{helpers-d41662f3.js → helpers-886489d5.js} +3 -2
  250. package/dist/esm/helpers-886489d5.js.map +1 -0
  251. package/dist/esm/{helpers-e75fd113.js → helpers-f543bc77.js} +12 -2
  252. package/dist/esm/helpers-f543bc77.js.map +1 -0
  253. package/dist/esm/ic-accordion-group.entry.js +1 -1
  254. package/dist/esm/ic-accordion.entry.js +1 -1
  255. package/dist/esm/ic-alert.entry.js +1 -1
  256. package/dist/esm/ic-back-to-top.entry.js +1 -1
  257. package/dist/esm/ic-badge.entry.js +1 -1
  258. package/dist/esm/ic-breadcrumb-group.entry.js +1 -1
  259. package/dist/esm/ic-breadcrumb.entry.js +1 -1
  260. package/dist/esm/ic-button_3.entry.js +11 -6
  261. package/dist/esm/ic-button_3.entry.js.map +1 -1
  262. package/dist/esm/ic-card-horizontal.entry.js +1 -1
  263. package/dist/esm/ic-card.entry.js +1 -1
  264. package/dist/esm/ic-checkbox-group.entry.js +1 -1
  265. package/dist/esm/ic-checkbox.entry.js +1 -1
  266. package/dist/esm/ic-chip.entry.js +9 -3
  267. package/dist/esm/ic-chip.entry.js.map +1 -1
  268. package/dist/esm/ic-data-row.entry.js +1 -1
  269. package/dist/esm/ic-data-table-title-bar.entry.js +1 -1
  270. package/dist/esm/ic-data-table.entry.js +526 -71
  271. package/dist/esm/ic-data-table.entry.js.map +1 -1
  272. package/dist/esm/ic-date-input.entry.js +4 -3
  273. package/dist/esm/ic-date-input.entry.js.map +1 -1
  274. package/dist/esm/ic-date-picker.entry.js +5 -1
  275. package/dist/esm/ic-date-picker.entry.js.map +1 -1
  276. package/dist/esm/ic-dialog.entry.js +1 -1
  277. package/dist/esm/ic-divider.entry.js +1 -1
  278. package/dist/esm/ic-empty-state_2.entry.js +2 -2
  279. package/dist/esm/ic-footer-link-group.entry.js +1 -1
  280. package/dist/esm/ic-footer-link.entry.js +1 -1
  281. package/dist/esm/ic-footer.entry.js +1 -1
  282. package/dist/esm/ic-hero.entry.js +1 -1
  283. package/dist/esm/ic-horizontal-scroll.entry.js +1 -1
  284. package/dist/esm/ic-input-component-container_4.entry.js +1 -1
  285. package/dist/esm/ic-link.entry.js +1 -1
  286. package/dist/esm/ic-menu-group.entry.js +1 -1
  287. package/dist/esm/ic-menu-item.entry.js +1 -1
  288. package/dist/esm/ic-menu-with-multi.entry.js +1 -1
  289. package/dist/esm/ic-menu.entry.js +1 -1
  290. package/dist/esm/ic-navigation-button.entry.js +1 -1
  291. package/dist/esm/ic-navigation-group.entry.js +1 -1
  292. package/dist/esm/ic-navigation-item.entry.js +1 -1
  293. package/dist/esm/ic-navigation-menu.entry.js +1 -1
  294. package/dist/esm/ic-page-header.entry.js +1 -1
  295. package/dist/esm/ic-pagination_4.entry.js +1 -1
  296. package/dist/esm/ic-popover-menu.entry.js +1 -1
  297. package/dist/esm/ic-radio-group.entry.js +41 -22
  298. package/dist/esm/ic-radio-group.entry.js.map +1 -1
  299. package/dist/esm/ic-radio-option.entry.js +1 -1
  300. package/dist/esm/ic-search-bar.entry.js +1 -1
  301. package/dist/esm/ic-select-with-multi.entry.js +1 -1
  302. package/dist/esm/ic-side-navigation.entry.js +1 -1
  303. package/dist/esm/ic-status-tag.entry.js +1 -1
  304. package/dist/esm/ic-step.entry.js +1 -1
  305. package/dist/esm/ic-stepper.entry.js +1 -1
  306. package/dist/esm/ic-switch.entry.js +1 -1
  307. package/dist/esm/ic-tab-group.entry.js +1 -1
  308. package/dist/esm/ic-tab-panel.entry.js +1 -1
  309. package/dist/esm/ic-tab.entry.js +1 -1
  310. package/dist/esm/ic-theme.entry.js +1 -1
  311. package/dist/esm/ic-toast.entry.js +1 -1
  312. package/dist/esm/ic-toggle-button.entry.js +1 -1
  313. package/dist/esm/ic-top-navigation.entry.js +1 -1
  314. package/dist/esm/ic-tree-item.entry.js +237 -0
  315. package/dist/esm/ic-tree-item.entry.js.map +1 -0
  316. package/dist/esm/ic-tree-view.entry.js +199 -0
  317. package/dist/esm/ic-tree-view.entry.js.map +1 -0
  318. package/dist/esm/ic-typography.entry.js +48 -13
  319. package/dist/esm/ic-typography.entry.js.map +1 -1
  320. package/dist/esm/index-93509377.js +8 -0
  321. package/dist/esm/loader.js +1 -1
  322. package/dist/types/components/ic-data-table/ic-data-table.d.ts +68 -7
  323. package/dist/types/components/ic-data-table/ic-data-table.types.d.ts +9 -0
  324. package/dist/types/components/ic-data-table/story-data.d.ts +112 -0
  325. package/dist/types/components/ic-date-input/ic-date-input.d.ts +4 -0
  326. package/dist/types/components/ic-date-picker/ic-date-picker.d.ts +4 -0
  327. package/dist/types/components/ic-tree-item/ic-tree-item.d.ts +95 -0
  328. package/dist/types/components/ic-tree-view/ic-tree-view.d.ts +40 -0
  329. package/dist/types/components.d.ts +173 -6
  330. package/hydrate/index.js +1175 -161
  331. package/package.json +3 -3
  332. package/dist/cjs/helpers-081d6031.js.map +0 -1
  333. package/dist/cjs/helpers-261701cd.js.map +0 -1
  334. package/dist/core/p-32a3b6c8.entry.js +0 -2
  335. package/dist/core/p-32a3b6c8.entry.js.map +0 -1
  336. package/dist/core/p-45ebcb74.js.map +0 -1
  337. package/dist/core/p-569a68c0.entry.js.map +0 -1
  338. package/dist/core/p-66595f5f.entry.js +0 -2
  339. package/dist/core/p-6e697a16.entry.js.map +0 -1
  340. package/dist/core/p-a4585c7e.entry.js +0 -2
  341. package/dist/core/p-c04f1bfb.entry.js +0 -2
  342. package/dist/core/p-c04f1bfb.entry.js.map +0 -1
  343. package/dist/core/p-d448bdbd.entry.js +0 -2
  344. package/dist/core/p-d448bdbd.entry.js.map +0 -1
  345. package/dist/core/p-d68e0c94.entry.js +0 -2
  346. package/dist/core/p-e191290c.entry.js +0 -2
  347. package/dist/core/p-e191290c.entry.js.map +0 -1
  348. package/dist/core/p-f6735e4a.js +0 -2
  349. package/dist/core/p-f6735e4a.js.map +0 -1
  350. package/dist/core/p-fc0eac8b.entry.js +0 -2
  351. package/dist/core/p-fc0eac8b.entry.js.map +0 -1
  352. package/dist/esm/helpers-e75fd113.js.map +0 -1
  353. /package/dist/core/{p-e5b1dd58.entry.js.map → p-0180e00a.entry.js.map} +0 -0
  354. /package/dist/core/{p-7f690fa3.entry.js.map → p-046f4de6.entry.js.map} +0 -0
  355. /package/dist/core/{p-d5d36143.entry.js.map → p-06732eaf.entry.js.map} +0 -0
  356. /package/dist/core/{p-01297278.entry.js.map → p-13993bf3.entry.js.map} +0 -0
  357. /package/dist/core/{p-693a77bb.entry.js.map → p-16a48a63.entry.js.map} +0 -0
  358. /package/dist/core/{p-d91428b4.entry.js.map → p-216fbd5e.entry.js.map} +0 -0
  359. /package/dist/core/{p-a8c97918.entry.js.map → p-2d063032.entry.js.map} +0 -0
  360. /package/dist/core/{p-2647931d.entry.js.map → p-2ee5d3fb.entry.js.map} +0 -0
  361. /package/dist/core/{p-007da09d.entry.js.map → p-3f2723aa.entry.js.map} +0 -0
  362. /package/dist/core/{p-a970d653.entry.js.map → p-418a84d4.entry.js.map} +0 -0
  363. /package/dist/core/{p-354e5dbe.entry.js.map → p-41916ef7.entry.js.map} +0 -0
  364. /package/dist/core/{p-6f8fd43e.entry.js.map → p-486a6957.entry.js.map} +0 -0
  365. /package/dist/core/{p-b3ed5423.entry.js.map → p-5348af01.entry.js.map} +0 -0
  366. /package/dist/core/{p-6b74397a.entry.js.map → p-59993f36.entry.js.map} +0 -0
  367. /package/dist/core/{p-be4c0cc8.entry.js.map → p-6398a726.entry.js.map} +0 -0
  368. /package/dist/core/{p-9e7a5c72.entry.js.map → p-648fb902.entry.js.map} +0 -0
  369. /package/dist/core/{p-d3ea79e1.entry.js.map → p-673a4a62.entry.js.map} +0 -0
  370. /package/dist/core/{p-fb4219d6.entry.js.map → p-67ae9d37.entry.js.map} +0 -0
  371. /package/dist/core/{p-0ea28e7a.entry.js.map → p-6b01e096.entry.js.map} +0 -0
  372. /package/dist/core/{p-40fc7162.entry.js.map → p-6b1fcf87.entry.js.map} +0 -0
  373. /package/dist/core/{p-1d0cff8a.entry.js.map → p-6fb3d61e.entry.js.map} +0 -0
  374. /package/dist/core/{p-1733278a.entry.js.map → p-789ae7f5.entry.js.map} +0 -0
  375. /package/dist/core/{p-0944d33b.entry.js.map → p-89c7ea3e.entry.js.map} +0 -0
  376. /package/dist/core/{p-96670e29.entry.js.map → p-8d276e8f.entry.js.map} +0 -0
  377. /package/dist/core/{p-d44b7f21.entry.js.map → p-97f141a6.entry.js.map} +0 -0
  378. /package/dist/core/{p-9f8ef2bc.entry.js.map → p-99185fd5.entry.js.map} +0 -0
  379. /package/dist/core/{p-1ac733c1.entry.js.map → p-99f96c33.entry.js.map} +0 -0
  380. /package/dist/core/{p-4e6f7cfe.entry.js.map → p-a052bb95.entry.js.map} +0 -0
  381. /package/dist/core/{p-9e69f517.entry.js.map → p-a72af8db.entry.js.map} +0 -0
  382. /package/dist/core/{p-ae7c2c39.entry.js.map → p-a787bba7.entry.js.map} +0 -0
  383. /package/dist/core/{p-e393e53c.entry.js.map → p-aa72f551.entry.js.map} +0 -0
  384. /package/dist/core/{p-3d9eca50.entry.js.map → p-aaaa9261.entry.js.map} +0 -0
  385. /package/dist/core/{p-a589ead8.entry.js.map → p-b29e96b5.entry.js.map} +0 -0
  386. /package/dist/core/{p-fab8da25.entry.js.map → p-bfc5f3f4.entry.js.map} +0 -0
  387. /package/dist/core/{p-e2421111.entry.js.map → p-cb3afdbf.entry.js.map} +0 -0
  388. /package/dist/core/{p-d06c0049.entry.js.map → p-ccf72538.entry.js.map} +0 -0
  389. /package/dist/core/{p-0551f0cf.entry.js.map → p-ce0999f1.entry.js.map} +0 -0
  390. /package/dist/core/{p-01008e8d.entry.js.map → p-d02a4d1b.entry.js.map} +0 -0
  391. /package/dist/core/{p-ffeca3c7.entry.js.map → p-d8322108.entry.js.map} +0 -0
  392. /package/dist/core/{p-fdacc7f7.entry.js.map → p-d86cdbc8.entry.js.map} +0 -0
  393. /package/dist/core/{p-59d9ea22.entry.js.map → p-da8255b8.entry.js.map} +0 -0
  394. /package/dist/core/{p-145c8074.entry.js.map → p-ede631c5.entry.js.map} +0 -0
  395. /package/dist/core/{p-d39239be.entry.js.map → p-f09b2041.entry.js.map} +0 -0
  396. /package/dist/core/{p-169bcf0f.entry.js.map → p-f1044e4d.entry.js.map} +0 -0
  397. /package/dist/core/{p-3be4aae0.entry.js.map → p-f10f7f37.entry.js.map} +0 -0
  398. /package/dist/core/{p-a6d3743c.entry.js.map → p-fa77211d.entry.js.map} +0 -0
@@ -0,0 +1,203 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ const index = require('./index-4cf27b16.js');
6
+ const helpers = require('./helpers-85c5ca15.js');
7
+
8
+ const icTreeViewCss = ":host{display:block;width:var(--tree-view-width, 100%)}:host .heading-area-container{border-bottom:var(--ic-border-default);display:flex;align-items:center;height:calc(var(--ic-space-xl) + var(--ic-space-xs) - var(--ic-space-1px));padding:0 var(--ic-space-xs)}:host(.ic-tree-view-small) .heading-area-container{height:calc(var(--ic-space-xl) - var(--ic-space-1px))}:host(.ic-tree-view-large) .heading-area-container{height:calc(var(--ic-space-xxl) - var(--ic-space-1px))}:host(.ic-tree-view-light) .heading-area-container{color:var(--ic-architectural-white);fill:var(--ic-architectural-white)}.icon-container{width:var(--ic-space-lg);height:var(--ic-space-lg);margin:0 var(--ic-space-xs) 0 0}:host(.ic-tree-view-small) .icon-container{margin:0 var(--ic-space-xxs) 0 0}.ic-text-overflow{white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.ic-tooltip-overflow{overflow:hidden}@media (forced-colors: active){::slotted([slot=\"icon\"]){fill:currentcolor}}";
9
+
10
+ let treeViewIds = 0;
11
+ const TreeView = class {
12
+ constructor(hostRef) {
13
+ index.registerInstance(this, hostRef);
14
+ this.treeViewId = `ic-tree-view-${treeViewIds++}`;
15
+ this.treeItemTag = "IC-TREE-ITEM";
16
+ this.hostMutationObserver = null;
17
+ this.handleKeyDown = (event) => {
18
+ var _a;
19
+ const focussedChild = this.treeItems.indexOf(this.treeItems.filter((el) => el === document.activeElement)[0]);
20
+ const expanded = (_a = this.treeItems[focussedChild]) === null || _a === void 0 ? void 0 : _a.expanded;
21
+ switch (event.key) {
22
+ case "ArrowDown":
23
+ this.treeItems[this.getNextItemToSelect(focussedChild, true)].setFocus();
24
+ if (focussedChild !== this.treeItems.length - 1) {
25
+ event.preventDefault();
26
+ }
27
+ break;
28
+ case "ArrowUp":
29
+ this.treeItems[this.getNextItemToSelect(focussedChild, false)].setFocus();
30
+ if (focussedChild !== 0) {
31
+ event.preventDefault();
32
+ }
33
+ break;
34
+ case "ArrowRight":
35
+ if (this.treeItems[focussedChild].isParent && !expanded) {
36
+ this.treeItems[focussedChild].expanded = true;
37
+ this.treeItems[focussedChild].hasParentExpanded = true;
38
+ this.treeItems[focussedChild].updateAriaLabel();
39
+ }
40
+ else if (this.treeItems[focussedChild].isParent && expanded) {
41
+ this.treeItems[focussedChild].children[0].setFocus();
42
+ }
43
+ event.preventDefault();
44
+ break;
45
+ case "ArrowLeft":
46
+ if (this.treeItems[focussedChild].isParent && expanded) {
47
+ this.treeItems[focussedChild].expanded = false;
48
+ this.treeItems[focussedChild].hasParentExpanded = false;
49
+ this.treeItems[focussedChild].updateAriaLabel();
50
+ }
51
+ else if (this.treeItems[focussedChild].parentElement.tagName ===
52
+ this.treeItemTag) {
53
+ this.treeItems[focussedChild].parentElement.setFocus();
54
+ }
55
+ event.preventDefault();
56
+ break;
57
+ }
58
+ };
59
+ this.getNextItemToSelect = (currentItem, movingDown) => {
60
+ const numItems = this.treeItems.length - 1;
61
+ if (currentItem < 1) {
62
+ currentItem = 0;
63
+ }
64
+ let nextItem = movingDown ? currentItem + 1 : currentItem - 1;
65
+ if (nextItem < 0) {
66
+ nextItem = 0;
67
+ }
68
+ else if (nextItem > numItems) {
69
+ nextItem = numItems;
70
+ }
71
+ const maxAttempts = numItems + 1;
72
+ let attempts = 0;
73
+ while (attempts < maxAttempts) {
74
+ if (nextItem < 0 || nextItem > numItems) {
75
+ return currentItem;
76
+ }
77
+ if (!this.treeItems[nextItem].disabled &&
78
+ (this.treeItems[nextItem].parentElement.tagName !== this.treeItemTag ||
79
+ this.treeItems[nextItem].parentElement
80
+ .expanded)) {
81
+ return nextItem;
82
+ }
83
+ if (nextItem === numItems && this.treeItems[nextItem].disabled) {
84
+ return currentItem;
85
+ }
86
+ nextItem = movingDown ? nextItem + 1 : nextItem - 1;
87
+ attempts++;
88
+ }
89
+ return currentItem;
90
+ };
91
+ this.linkTreeItems = () => {
92
+ this.treeItems.forEach((treeItem) => {
93
+ treeItem.setAttribute("context-id", this.treeViewId);
94
+ });
95
+ };
96
+ this.setTreeItems = () => {
97
+ this.treeItems = this.getAllTreeItems(this.el);
98
+ this.linkTreeItems();
99
+ };
100
+ this.addSlotChangeListener = () => {
101
+ this.el.addEventListener("slotchange", this.setTreeItems);
102
+ };
103
+ this.truncateTreeViewHeading = () => {
104
+ const typographyEl = this.el.shadowRoot.querySelector(".tree-view-header");
105
+ const tooltip = typographyEl.closest("ic-tooltip");
106
+ const headingContainer = this.el.shadowRoot.querySelector(".heading-area-container");
107
+ if ((typographyEl === null || typographyEl === void 0 ? void 0 : typographyEl.scrollHeight) > (headingContainer === null || headingContainer === void 0 ? void 0 : headingContainer.clientHeight)) {
108
+ typographyEl.classList.add("ic-text-overflow");
109
+ if (!tooltip) {
110
+ const tooltipEl = document.createElement("ic-tooltip");
111
+ tooltipEl.setAttribute("target", this.el.id);
112
+ tooltipEl.setAttribute("label", typographyEl.textContent);
113
+ tooltipEl.classList.add("ic-tooltip-overflow");
114
+ tooltipEl.setAttribute("placement", "right");
115
+ headingContainer.appendChild(tooltipEl);
116
+ tooltipEl.appendChild(typographyEl);
117
+ }
118
+ }
119
+ };
120
+ this.hostMutationCallback = (mutationList) => {
121
+ if (mutationList.some(({ type, addedNodes, removedNodes }) => type === "childList"
122
+ ? helpers.checkSlotInChildMutations(addedNodes, removedNodes, "icon")
123
+ : false)) {
124
+ index.forceUpdate(this);
125
+ }
126
+ };
127
+ this.isHeadingDefined = () => helpers.isPropDefined(this.heading) && this.heading !== null;
128
+ this.hasHeadingAreaContent = () => {
129
+ return (helpers.isSlotUsed(this.el, "heading") ||
130
+ this.isHeadingDefined() ||
131
+ helpers.isSlotUsed(this.el, "icon"));
132
+ };
133
+ this.treeItems = undefined;
134
+ this.appearance = "dark";
135
+ this.heading = "";
136
+ this.size = "default";
137
+ }
138
+ watchAppearanceHandler() {
139
+ this.treeItems.forEach((treeItem) => {
140
+ treeItem.appearance = this.appearance;
141
+ });
142
+ }
143
+ watchSizeHandler() {
144
+ this.treeItems.forEach((treeItem) => {
145
+ treeItem.size = this.size;
146
+ });
147
+ }
148
+ disconnectedCallback() {
149
+ var _a, _b;
150
+ (_a = this.el) === null || _a === void 0 ? void 0 : _a.removeEventListener("slotchange", this.setTreeItems);
151
+ (_b = this.hostMutationObserver) === null || _b === void 0 ? void 0 : _b.disconnect();
152
+ }
153
+ componentDidLoad() {
154
+ this.setTreeItems();
155
+ this.watchAppearanceHandler();
156
+ this.watchSizeHandler();
157
+ setTimeout(() => {
158
+ this.truncateTreeViewHeading();
159
+ }, 100);
160
+ this.addSlotChangeListener();
161
+ this.hostMutationObserver = new MutationObserver(this.hostMutationCallback);
162
+ this.hostMutationObserver.observe(this.el, {
163
+ childList: true,
164
+ });
165
+ }
166
+ handleTreeItemSelected(event) {
167
+ this.treeItems.forEach((treeItem) => {
168
+ if (treeItem.selected && treeItem.id !== event.detail.id) {
169
+ treeItem.selected = false;
170
+ }
171
+ });
172
+ }
173
+ getAllTreeItems(element) {
174
+ const treeItems = [];
175
+ const collectTreeItems = (el) => {
176
+ Array.from(el.children).forEach((child) => {
177
+ if (child.tagName === this.treeItemTag) {
178
+ treeItems.push(child);
179
+ }
180
+ collectTreeItems(child);
181
+ });
182
+ };
183
+ collectTreeItems(element);
184
+ return treeItems;
185
+ }
186
+ render() {
187
+ const { appearance, heading, size } = this;
188
+ return (index.h(index.Host, { "context-id": this.treeViewId, class: {
189
+ [`ic-tree-view-${appearance}`]: true,
190
+ [`ic-tree-view-${size}`]: size !== "default",
191
+ }, onKeyDown: this.handleKeyDown, "aria-label": this.isHeadingDefined() ? heading : null }, this.hasHeadingAreaContent() && (index.h("div", { class: "heading-area-container" }, helpers.isSlotUsed(this.el, "icon") && (index.h("div", { class: "icon-container" }, index.h("slot", { name: "icon" }))), index.h("ic-typography", { variant: "subtitle-large", class: "tree-view-header" }, helpers.isSlotUsed(this.el, "heading") ? (index.h("slot", { name: "heading" })) : (heading)))), index.h("slot", null)));
192
+ }
193
+ get el() { return index.getElement(this); }
194
+ static get watchers() { return {
195
+ "appearance": ["watchAppearanceHandler"],
196
+ "size": ["watchSizeHandler"]
197
+ }; }
198
+ };
199
+ TreeView.style = icTreeViewCss;
200
+
201
+ exports.ic_tree_view = TreeView;
202
+
203
+ //# sourceMappingURL=ic-tree-view.cjs.entry.js.map
@@ -0,0 +1 @@
1
+ {"file":"ic-tree-view.entry.cjs.js","mappings":";;;;;;;AAAA,MAAM,aAAa,GAAG,g8BAAg8B;;ACkBt9B,IAAI,WAAW,GAAG,CAAC,CAAC;MAYP,QAAQ;;;QACX,eAAU,GAAG,gBAAgB,WAAW,EAAE,EAAE,CAAC;QAC7C,gBAAW,GAAG,cAAc,CAAC;QAC7B,yBAAoB,GAAqB,IAAI,CAAC;QAiE9C,kBAAa,GAAG,CAAC,KAAoB;;YAC3C,MAAM,aAAa,GAAG,IAAI,CAAC,SAAS,CAAC,OAAO,CAC1C,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,EAAE,KAAK,EAAE,KAAK,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,CAChE,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,IAAI,EAAC,SAAS,GAAG,KAEvB,OAAO,CACR,CACa,CACZ,CACP,EACDA,qBAAa,CACR,EACP;KACH;;;;;;;;;;;","names":["checkSlotInChildMutations","forceUpdate","isPropDefined","isSlotUsed","h","Host"],"sources":["src/components/ic-tree-view/ic-tree-view.css?tag=ic-tree-view&encapsulation=shadow","src/components/ic-tree-view/ic-tree-view.tsx"],"sourcesContent":["/**\n* @prop --tree-view-width: Width of the tree view\n*/\n\n:host {\n display: block;\n width: var(--tree-view-width, 100%);\n}\n\n:host .heading-area-container {\n border-bottom: var(--ic-border-default);\n display: flex;\n align-items: center;\n height: calc(var(--ic-space-xl) + var(--ic-space-xs) - var(--ic-space-1px));\n padding: 0 var(--ic-space-xs);\n}\n\n:host(.ic-tree-view-small) .heading-area-container {\n height: calc(var(--ic-space-xl) - var(--ic-space-1px));\n}\n\n:host(.ic-tree-view-large) .heading-area-container {\n height: calc(var(--ic-space-xxl) - var(--ic-space-1px));\n}\n\n:host(.ic-tree-view-light) .heading-area-container {\n color: var(--ic-architectural-white);\n fill: var(--ic-architectural-white);\n}\n\n.icon-container {\n width: var(--ic-space-lg);\n height: var(--ic-space-lg);\n margin: 0 var(--ic-space-xs) 0 0;\n}\n\n:host(.ic-tree-view-small) .icon-container {\n margin: 0 var(--ic-space-xxs) 0 0;\n}\n\n.ic-text-overflow {\n white-space: nowrap;\n text-overflow: ellipsis;\n overflow: hidden;\n}\n\n.ic-tooltip-overflow {\n overflow: hidden;\n}\n\n/** High Contrast **/\n@media (forced-colors: active) {\n ::slotted([slot=\"icon\"]) {\n fill: currentcolor;\n }\n}\n","import {\n Component,\n h,\n Prop,\n Element,\n Host,\n Watch,\n State,\n Listen,\n forceUpdate,\n} from \"@stencil/core\";\nimport { IcSizes, IcThemeForegroundNoDefault } from \"../../utils/types\";\nimport {\n isPropDefined,\n isSlotUsed,\n checkSlotInChildMutations,\n} from \"../../utils/helpers\";\n\nlet treeViewIds = 0;\n\n/**\n * @slot heading - Content is set as the tree view heading.\n * @slot icon - Content is placed to the left of the heading.\n */\n\n@Component({\n tag: \"ic-tree-view\",\n styleUrl: \"ic-tree-view.css\",\n shadow: true,\n})\nexport class TreeView {\n private treeViewId = `ic-tree-view-${treeViewIds++}`;\n private treeItemTag = \"IC-TREE-ITEM\";\n private hostMutationObserver: MutationObserver = null;\n\n @Element() el: HTMLIcTreeViewElement;\n\n @State() treeItems: HTMLIcTreeItemElement[];\n\n /**\n * The appearance of the tree view, e.g. dark, or light.\n */\n @Prop() appearance?: IcThemeForegroundNoDefault = \"dark\";\n @Watch(\"appearance\")\n watchAppearanceHandler() {\n this.treeItems.forEach((treeItem) => {\n treeItem.appearance = this.appearance;\n });\n }\n\n /**\n * The heading of the tree view.\n */\n @Prop() heading?: string = \"\";\n\n /**\n * The size of the tree view.\n */\n @Prop() size?: IcSizes = \"default\";\n @Watch(\"size\")\n watchSizeHandler() {\n this.treeItems.forEach((treeItem) => {\n treeItem.size = this.size;\n });\n }\n\n disconnectedCallback(): void {\n this.el?.removeEventListener(\"slotchange\", this.setTreeItems);\n\n this.hostMutationObserver?.disconnect();\n }\n\n componentDidLoad(): void {\n this.setTreeItems();\n\n this.watchAppearanceHandler();\n this.watchSizeHandler();\n setTimeout(() => {\n this.truncateTreeViewHeading();\n }, 100);\n\n this.addSlotChangeListener();\n\n this.hostMutationObserver = new MutationObserver(this.hostMutationCallback);\n this.hostMutationObserver.observe(this.el, {\n childList: true,\n });\n }\n\n @Listen(\"icTreeItemSelected\")\n handleTreeItemSelected(event: CustomEvent): void {\n this.treeItems.forEach((treeItem) => {\n if (treeItem.selected && treeItem.id !== event.detail.id) {\n treeItem.selected = false;\n }\n });\n }\n\n private handleKeyDown = (event: KeyboardEvent): void => {\n const focussedChild = this.treeItems.indexOf(\n this.treeItems.filter((el) => el === document.activeElement)[0]\n );\n const expanded = this.treeItems[focussedChild]?.expanded;\n switch (event.key) {\n case \"ArrowDown\":\n this.treeItems[\n this.getNextItemToSelect(focussedChild, true)\n ].setFocus();\n if (focussedChild !== this.treeItems.length - 1) {\n event.preventDefault();\n }\n break;\n case \"ArrowUp\":\n this.treeItems[\n this.getNextItemToSelect(focussedChild, false)\n ].setFocus();\n if (focussedChild !== 0) {\n event.preventDefault();\n }\n break;\n case \"ArrowRight\":\n if (this.treeItems[focussedChild].isParent && !expanded) {\n this.treeItems[focussedChild].expanded = true;\n this.treeItems[focussedChild].hasParentExpanded = true;\n this.treeItems[focussedChild].updateAriaLabel();\n } else if (this.treeItems[focussedChild].isParent && expanded) {\n (\n this.treeItems[focussedChild].children[0] as HTMLIcTreeItemElement\n ).setFocus();\n }\n event.preventDefault();\n break;\n case \"ArrowLeft\":\n if (this.treeItems[focussedChild].isParent && expanded) {\n this.treeItems[focussedChild].expanded = false;\n this.treeItems[focussedChild].hasParentExpanded = false;\n this.treeItems[focussedChild].updateAriaLabel();\n } else if (\n this.treeItems[focussedChild].parentElement.tagName ===\n this.treeItemTag\n ) {\n (\n this.treeItems[focussedChild].parentElement as HTMLIcTreeItemElement\n ).setFocus();\n }\n event.preventDefault();\n break;\n }\n };\n\n private getNextItemToSelect = (\n currentItem: number,\n movingDown: boolean\n ): number => {\n const numItems = this.treeItems.length - 1;\n\n if (currentItem < 1) {\n currentItem = 0;\n }\n\n let nextItem = movingDown ? currentItem + 1 : currentItem - 1;\n if (nextItem < 0) {\n nextItem = 0;\n } else if (nextItem > numItems) {\n nextItem = numItems;\n }\n\n const maxAttempts = numItems + 1;\n let attempts = 0;\n\n while (attempts < maxAttempts) {\n if (nextItem < 0 || nextItem > numItems) {\n return currentItem;\n }\n\n if (\n !this.treeItems[nextItem].disabled &&\n (this.treeItems[nextItem].parentElement.tagName !== this.treeItemTag ||\n (this.treeItems[nextItem].parentElement as HTMLIcTreeItemElement)\n .expanded)\n ) {\n return nextItem;\n }\n\n if (nextItem === numItems && this.treeItems[nextItem].disabled) {\n return currentItem;\n }\n\n nextItem = movingDown ? nextItem + 1 : nextItem - 1;\n attempts++;\n }\n\n return currentItem;\n };\n\n private linkTreeItems = () => {\n this.treeItems.forEach((treeItem) => {\n treeItem.setAttribute(\"context-id\", this.treeViewId);\n });\n };\n\n private setTreeItems = () => {\n this.treeItems = this.getAllTreeItems(this.el as HTMLElement);\n\n this.linkTreeItems();\n };\n\n private getAllTreeItems(element: HTMLElement): HTMLIcTreeItemElement[] {\n const treeItems: HTMLIcTreeItemElement[] = [];\n\n const collectTreeItems = (el: HTMLElement) => {\n Array.from(el.children).forEach((child) => {\n if (child.tagName === this.treeItemTag) {\n treeItems.push(child as HTMLIcTreeItemElement);\n }\n\n collectTreeItems(child as HTMLElement);\n });\n };\n\n collectTreeItems(element);\n return treeItems;\n }\n\n private addSlotChangeListener = () => {\n this.el.addEventListener(\"slotchange\", this.setTreeItems);\n };\n\n private truncateTreeViewHeading = () => {\n const typographyEl: HTMLIcTypographyElement =\n this.el.shadowRoot.querySelector(\".tree-view-header\");\n const tooltip = typographyEl.closest(\"ic-tooltip\");\n const headingContainer: HTMLElement = this.el.shadowRoot.querySelector(\n \".heading-area-container\"\n );\n\n if (typographyEl?.scrollHeight > headingContainer?.clientHeight) {\n typographyEl.classList.add(\"ic-text-overflow\");\n\n if (!tooltip) {\n const tooltipEl = document.createElement(\"ic-tooltip\");\n tooltipEl.setAttribute(\"target\", this.el.id);\n tooltipEl.setAttribute(\"label\", typographyEl.textContent);\n tooltipEl.classList.add(\"ic-tooltip-overflow\");\n tooltipEl.setAttribute(\"placement\", \"right\");\n headingContainer.appendChild(tooltipEl);\n tooltipEl.appendChild(typographyEl);\n }\n }\n };\n\n private hostMutationCallback = (mutationList: MutationRecord[]): void => {\n if (\n mutationList.some(({ type, addedNodes, removedNodes }) =>\n type === \"childList\"\n ? checkSlotInChildMutations(addedNodes, removedNodes, \"icon\")\n : false\n )\n ) {\n forceUpdate(this);\n }\n };\n\n private isHeadingDefined = () =>\n isPropDefined(this.heading) && this.heading !== null;\n\n private hasHeadingAreaContent = (): boolean => {\n return (\n isSlotUsed(this.el, \"heading\") ||\n this.isHeadingDefined() ||\n isSlotUsed(this.el, \"icon\")\n );\n };\n\n render() {\n const { appearance, heading, size } = this;\n\n return (\n <Host\n context-id={this.treeViewId}\n class={{\n [`ic-tree-view-${appearance}`]: true,\n [`ic-tree-view-${size}`]: size !== \"default\",\n }}\n onKeyDown={this.handleKeyDown}\n aria-label={this.isHeadingDefined() ? heading : null}\n >\n {this.hasHeadingAreaContent() && (\n <div class=\"heading-area-container\">\n {isSlotUsed(this.el, \"icon\") && (\n <div class=\"icon-container\">\n <slot name=\"icon\" />\n </div>\n )}\n <ic-typography variant=\"subtitle-large\" class=\"tree-view-header\">\n {isSlotUsed(this.el, \"heading\") ? (\n <slot name=\"heading\" />\n ) : (\n heading\n )}\n </ic-typography>\n </div>\n )}\n <slot></slot>\n </Host>\n );\n }\n}\n"],"version":3}
@@ -3,30 +3,28 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-4cf27b16.js');
6
- const helpers = require('./helpers-081d6031.js');
6
+ const helpers = require('./helpers-093368be.js');
7
7
  require('./types-17dba796.js');
8
8
 
9
- const icTypographyCss = "/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type=\"button\"],[type=\"reset\"],[type=\"submit\"]{-webkit-appearance:button}button::-moz-focus-inner,[type=\"button\"]::-moz-focus-inner,[type=\"reset\"]::-moz-focus-inner,[type=\"submit\"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type=\"button\"]:-moz-focusring,[type=\"reset\"]:-moz-focusring,[type=\"submit\"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type=\"checkbox\"],[type=\"radio\"]{box-sizing:border-box;padding:0;}[type=\"number\"]::-webkit-inner-spin-button,[type=\"number\"]::-webkit-outer-spin-button{height:auto}[type=\"search\"]{-webkit-appearance:textfield;outline-offset:-2px;}[type=\"search\"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block;position:relative}:host(.ic-typography-vertical-margins-h1){margin:0 0 var(--ic-space-xl)}:host(.ic-typography-vertical-margins-h2){margin:var(--ic-space-xxl) 0 var(--ic-space-lg)}:host(.ic-typography-vertical-margins-h3){margin:var(--ic-space-xl) 0 var(--ic-space-md)}:host(.ic-typography-vertical-margins-h4){margin:var(--ic-space-lg) 0 var(--ic-space-md)}:host(.ic-typography-vertical-margins-subtitle-large),:host(.ic-typography-vertical-margins-subtitle-small),:host(.ic-typography-vertical-margins-body),:host(.ic-typography-vertical-margins-code-large),:host(.ic-typography-vertical-margins-code-small),:host(.ic-typography-vertical-margins-code-extra-small){margin:0 0 var(--ic-space-md)}:host(.ic-typography-vertical-margins-caption),:host(.ic-typography-vertical-margins-caption-uppercase){margin:0 0 var(--ic-space-xs)}:host(.ic-typography-vertical-margins-h2:first-child),:host(.ic-typography-vertical-margins-h3:first-child),:host(.ic-typography-vertical-margins-h4:first-child){margin-top:0}:host(.ic-typography-h1){font:var(--ic-font-h1) !important}:host(.ic-typography-h2){font:var(--ic-font-h2);letter-spacing:var(--ic-font-letter-spacing-0pt0025)}:host(.ic-typography-h3){font:var(--ic-font-h3)}:host(.ic-typography-h4){font:var(--ic-font-h4);letter-spacing:var(--ic-font-letter-spacing-0pt0015)}:host(.ic-typography-subtitle-large){font:var(--ic-font-subtitle-large);letter-spacing:var(--ic-font-letter-spacing-0pt0015)}:host(.ic-typography-subtitle-small){font:var(--ic-font-subtitle-small);letter-spacing:var(--ic-font-letter-spacing-0pt0015)}:host(.ic-typography-body){font:var(--ic-font-body);letter-spacing:var(--ic-font-letter-spacing-0pt005)}:host(.ic-typography-caption){font:var(--ic-font-caption);letter-spacing:var(--ic-font-letter-spacing-0pt0025)}:host(.ic-typography-caption-uppercase){font:var(--ic-font-caption);letter-spacing:var(--ic-font-letter-spacing-0pt0025);text-transform:uppercase}:host(.ic-typography-label){font:var(--ic-font-label);letter-spacing:var(--ic-font-letter-spacing-0pt025)}:host(.ic-typography-label-uppercase){font:var(--ic-font-label);letter-spacing:var(--ic-font-letter-spacing-0pt025);text-transform:uppercase}:host(.ic-typography-code-large){font:var(--ic-font-code-large);letter-spacing:var(--ic-font-letter-spacing-0pt025)}:host(.ic-typography-code-small){font:var(--ic-font-code-small);letter-spacing:var(--ic-font-letter-spacing-0pt005)}:host(.ic-typography-code-extra-small){font:var(--ic-font-code-extra-small);letter-spacing:var(--ic-font-letter-spacing-0pt025)}:host(.ic-typography-badge){font:var(--ic-font-badge);letter-spacing:var(--ic-font-letter-spacing-0pt0025)}:host(.ic-typography-badge-small){font:var(--ic-font-badge-small);letter-spacing:var(--ic-font-letter-spacing-0pt0025)}:host(.ic-typography-no-wrap){white-space:nowrap}:host ::slotted(h1),:host ::slotted(h2),:host ::slotted(h3),:host ::slotted(h4),:host ::slotted(h5),:host ::slotted(h6),:host ::slotted(p),:host ::slotted(label){font:inherit;letter-spacing:inherit}.trunc-wrapper{display:-webkit-box;-webkit-box-orient:vertical;line-clamp:var(--truncation-max-lines, initial);-webkit-line-clamp:var(--truncation-max-lines, initial);overflow:hidden}.trunc-btn{border:none;background:none;padding:0;color:var(--ic-color-primary-text);text-decoration:underline;font-weight:var(--ic-font-weight-bold);transition:var(--ic-easing-transition-fast)}.trunc-btn:hover,.trunc-btn.focus{outline:none;border-bottom:0.25rem solid !important;margin-bottom:-0.25rem !important;text-decoration:none;cursor:pointer}:host(.strikethrough){text-decoration:line-through}:host(.underline){text-decoration:underline}:host(.underline.strikethrough){text-decoration:line-through underline}:host(.italic){font-style:italic !important}:host(.bold){font-weight:var(--ic-font-weight-bold)}@supports (text-underline-offset: 25%){.trunc-btn:hover,.trunc-btn.focus{text-decoration-line:underline;text-decoration-thickness:25%;text-underline-offset:25%;border-bottom:0 !important;margin-bottom:0 !important}}";
9
+ const icTypographyCss = "/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type=\"button\"],[type=\"reset\"],[type=\"submit\"]{-webkit-appearance:button}button::-moz-focus-inner,[type=\"button\"]::-moz-focus-inner,[type=\"reset\"]::-moz-focus-inner,[type=\"submit\"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type=\"button\"]:-moz-focusring,[type=\"reset\"]:-moz-focusring,[type=\"submit\"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type=\"checkbox\"],[type=\"radio\"]{box-sizing:border-box;padding:0;}[type=\"number\"]::-webkit-inner-spin-button,[type=\"number\"]::-webkit-outer-spin-button{height:auto}[type=\"search\"]{-webkit-appearance:textfield;outline-offset:-2px;}[type=\"search\"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block;position:relative}:host(.ic-typography-vertical-margins-h1){margin:0 0 var(--ic-space-xl)}:host(.ic-typography-vertical-margins-h2){margin:var(--ic-space-xxl) 0 var(--ic-space-lg)}:host(.ic-typography-vertical-margins-h3){margin:var(--ic-space-xl) 0 var(--ic-space-md)}:host(.ic-typography-vertical-margins-h4){margin:var(--ic-space-lg) 0 var(--ic-space-md)}:host(.ic-typography-vertical-margins-subtitle-large),:host(.ic-typography-vertical-margins-subtitle-small),:host(.ic-typography-vertical-margins-body),:host(.ic-typography-vertical-margins-code-large),:host(.ic-typography-vertical-margins-code-small),:host(.ic-typography-vertical-margins-code-extra-small){margin:0 0 var(--ic-space-md)}:host(.ic-typography-vertical-margins-caption),:host(.ic-typography-vertical-margins-caption-uppercase){margin:0 0 var(--ic-space-xs)}:host(.ic-typography-vertical-margins-h2:first-child),:host(.ic-typography-vertical-margins-h3:first-child),:host(.ic-typography-vertical-margins-h4:first-child){margin-top:0}:host(.ic-typography-h1){font:var(--ic-font-h1) !important}:host(.ic-typography-h2){font:var(--ic-font-h2);letter-spacing:var(--ic-font-letter-spacing-0pt0025)}:host(.ic-typography-h3){font:var(--ic-font-h3)}:host(.ic-typography-h4){font:var(--ic-font-h4);letter-spacing:var(--ic-font-letter-spacing-0pt0015)}:host(.ic-typography-subtitle-large){font:var(--ic-font-subtitle-large);letter-spacing:var(--ic-font-letter-spacing-0pt0015)}:host(.ic-typography-subtitle-small){font:var(--ic-font-subtitle-small);letter-spacing:var(--ic-font-letter-spacing-0pt0015)}:host(.ic-typography-body){font:var(--ic-font-body);letter-spacing:var(--ic-font-letter-spacing-0pt005)}:host(.ic-typography-caption){font:var(--ic-font-caption);letter-spacing:var(--ic-font-letter-spacing-0pt0025)}:host(.ic-typography-caption-uppercase){font:var(--ic-font-caption);letter-spacing:var(--ic-font-letter-spacing-0pt0025);text-transform:uppercase}:host(.ic-typography-label){font:var(--ic-font-label);letter-spacing:var(--ic-font-letter-spacing-0pt025)}:host(.ic-typography-label-uppercase){font:var(--ic-font-label);letter-spacing:var(--ic-font-letter-spacing-0pt025);text-transform:uppercase}:host(.ic-typography-code-large){font:var(--ic-font-code-large);letter-spacing:var(--ic-font-letter-spacing-0pt025)}:host(.ic-typography-code-small){font:var(--ic-font-code-small);letter-spacing:var(--ic-font-letter-spacing-0pt005)}:host(.ic-typography-code-extra-small){font:var(--ic-font-code-extra-small);letter-spacing:var(--ic-font-letter-spacing-0pt025)}:host(.ic-typography-badge){font:var(--ic-font-badge);letter-spacing:var(--ic-font-letter-spacing-0pt0025)}:host(.ic-typography-badge-small){font:var(--ic-font-badge-small);letter-spacing:var(--ic-font-letter-spacing-0pt0025)}:host(.ic-typography-no-wrap){white-space:nowrap}:host ::slotted(h1),:host ::slotted(h2),:host ::slotted(h3),:host ::slotted(h4),:host ::slotted(h5),:host ::slotted(h6),:host ::slotted(p),:host ::slotted(label){font:inherit;letter-spacing:inherit}.trunc-wrapper{display:-webkit-box;-webkit-box-orient:vertical;line-clamp:var(--truncation-max-lines, initial);-webkit-line-clamp:var(--truncation-max-lines, initial);overflow:hidden;padding-right:var(--ellipsis-padding-right, 0)}.trunc-btn{border:none;background:none;padding:0;color:var(--ic-color-primary-text);text-decoration:underline;font-weight:var(--ic-font-weight-bold);transition:var(--ic-easing-transition-fast)}.trunc-btn:hover,.trunc-btn.focus{outline:none;border-bottom:0.25rem solid !important;margin-bottom:-0.25rem !important;text-decoration:none;cursor:pointer}:host(.strikethrough){text-decoration:line-through}:host(.underline){text-decoration:underline}:host(.underline.strikethrough){text-decoration:line-through underline}:host(.italic){font-style:italic !important}:host(.bold){font-weight:var(--ic-font-weight-bold)}:host(.in-ag-grid),:host(.in-ag-grid) ::slotted(*){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}@supports (text-underline-offset: 25%){.trunc-btn:hover,.trunc-btn.focus{text-decoration-line:underline;text-decoration-thickness:25%;text-underline-offset:25%;border-bottom:0 !important;margin-bottom:0 !important}}";
10
10
 
11
11
  const Typography = class {
12
12
  constructor(hostRef) {
13
13
  index.registerInstance(this, hostRef);
14
+ this.typographyTruncationExpandToggle = index.createEvent(this, "typographyTruncationExpandToggle", 7);
14
15
  this.focusBtnFromKeyboard = true;
16
+ this.inAGGrid = false;
15
17
  this.lastMarkerTop = 0;
16
18
  this.lastWidth = 0;
17
19
  this.resizeObserver = null;
18
20
  this.truncatedHeight = 0;
19
- this.toggleExpanded = () => {
21
+ this.toggleExpanded = (ev) => {
22
+ ev.stopPropagation();
20
23
  this.expanded = !this.expanded;
21
- };
22
- this.checkMaxLines = (height) => {
23
- //24 is the height of a single line
24
- const numLines = Math.floor(height / 24);
25
- if (numLines > this.maxLines) {
26
- this.el.setAttribute("style", `--truncation-max-lines: ${this.maxLines}`);
27
- this.truncatedHeight = this.el.clientHeight;
28
- this.truncated = true;
29
- }
24
+ this.typographyTruncationExpandToggle.emit({
25
+ expanded: this.expanded,
26
+ typographyEl: this.el,
27
+ });
30
28
  };
31
29
  this.checkMarkerPosition = (elTop, markerTop) => {
32
30
  if (markerTop - elTop < this.truncatedHeight) {
@@ -94,6 +92,18 @@ const Typography = class {
94
92
  this.resizeObserver.disconnect();
95
93
  }
96
94
  }
95
+ /**
96
+ * @internal This is used by data table to remove all truncation in certain events
97
+ */
98
+ async resetTruncation() {
99
+ if (this.truncated) {
100
+ this.truncated = false;
101
+ this.maxLines = 0;
102
+ this.el.removeAttribute("max-lines");
103
+ this.expanded = false;
104
+ this.el.removeAttribute("style");
105
+ }
106
+ }
97
107
  componentDidLoad() {
98
108
  var _a, _b;
99
109
  if ((this.variant === "body" ||
@@ -109,6 +119,30 @@ const Typography = class {
109
119
  helpers.checkResizeObserver(this.runResizeObserver);
110
120
  }
111
121
  }
122
+ componentWillRender() {
123
+ if (helpers.isElInAGGrid(this.el)) {
124
+ this.inAGGrid = true;
125
+ }
126
+ }
127
+ /**
128
+ * @internal This checks if the number of lines of text exceeds the maxLines prop. If so, set the line clamp CSS to the max lines
129
+ * @param height - text container height
130
+ */
131
+ async checkMaxLines(height) {
132
+ //24 is the height of a single line
133
+ const numLines = Math.floor(height / 24);
134
+ if (numLines > this.maxLines) {
135
+ this.el.setAttribute("style", `--truncation-max-lines: ${this.maxLines}`);
136
+ this.truncatedHeight = this.el.clientHeight;
137
+ this.truncated = true;
138
+ }
139
+ }
140
+ /**
141
+ * @internal This method makes it possible to set the expanded status of truncated text outside of ic-typography component
142
+ */
143
+ async setShowHideExpanded(expanded) {
144
+ this.expanded = expanded;
145
+ }
112
146
  render() {
113
147
  var _a, _b;
114
148
  const { variant, applyVerticalMargins, maxLines, truncated, expanded, strikethrough, underline, italic, bold, } = this;
@@ -119,6 +153,7 @@ const Typography = class {
119
153
  ["italic"]: italic,
120
154
  ["strikethrough"]: strikethrough,
121
155
  ["underline"]: underline,
156
+ ["in-ag-grid"]: this.inAGGrid,
122
157
  } }, (variant === "body" ||
123
158
  ((_b = (_a = this.el.getRootNode()) === null || _a === void 0 ? void 0 : _a.host) === null || _b === void 0 ? void 0 : _b.tagName) ===
124
159
  "IC-TOOLTIP") &&
@@ -1 +1 @@
1
- {"file":"ic-typography.entry.cjs.js","mappings":";;;;;;;;AAAA,MAAM,eAAe,GAAG,m0MAAm0M;;MCE90M,UAAU;IACnB;;QACI,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC;QACjC,IAAI,CAAC,aAAa,GAAG,CAAC,CAAC;QACvB,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC;QACnB,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC;QAC3B,IAAI,CAAC,eAAe,GAAG,CAAC,CAAC;QACzB,IAAI,CAAC,cAAc,GAAG;YAClB,IAAI,CAAC,QAAQ,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC;SAClC,CAAC;QACF,IAAI,CAAC,aAAa,GAAG,CAAC,MAAM;;YAExB,MAAM,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,EAAE,CAAC,CAAC;YACzC,IAAI,QAAQ,GAAG,IAAI,CAAC,QAAQ,EAAE;gBAC1B,IAAI,CAAC,EAAE,CAAC,YAAY,CAAC,OAAO,EAAE,2BAA2B,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;gBAC1E,IAAI,CAAC,eAAe,GAAG,IAAI,CAAC,EAAE,CAAC,YAAY,CAAC;gBAC5C,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC;aACzB;SACJ,CAAC;QACF,IAAI,CAAC,mBAAmB,GA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AC,eAAe,GAAG,aAAa;gBAChC,CAAC,WAAW,GAAG,SAAS;aAC3B,EAAE,EAAE,CAAC,OAAO,KAAK,MAAM;YACxB,CAAC,CAAC,EAAE,GAAG,CAAC,EAAE,GAAG,IAAI,CAAC,EAAE,CAAC,WAAW,EAAE,MAAM,IAAI,IAAI,EAAE,KAAK,KAAK,CAAC,GAAG,KAAK,CAAC,GAAG,EAAE,CAAC,IAAI,MAAM,IAAI,IAAI,EAAE,KAAK,KAAK,CAAC,GAAG,KAAK,CAAC,GAAG,EAAE,CAAC,OAAO;gBAC7H,YAAY;YAChB,QAAQ,GAAG,CAAC,IAAID,OAAC,CAAC,KAAK,EAAE,EAAE,KAAK,EAAE,eAAe,EAAE,GAAG,EAAE,CAAC,EAAE,MAAM,IAAI,CAAC,cAAc,GAAG,EAAE,CAAC,EAAE,EAAEA,OAAC,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC,KAAKA,OAAC,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC,EAAE,OAAO,KAAK,MAAM,IAAI,QAAQ,GAAG,CAAC,IAAI,SAAS,KAAKA,OAAC,CAAC,QAAQ,EAAE,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,CAAC,mBAAmB,EAAE,EAAE,OAAO,EAAE,IAAI,CAAC,gBAAgB,EAAE,MAAM,EAAE,IAAI,CAAC,eAAe,EAAE,WAAW,EAAE,IAAI,CAAC,yBAAyB,EAAE,OAAO,EAAE,IAAI,CAAC,cAAc,EAAE,EAAE,QAAQ,GAAG,UAAU,GAAG,UAAU,CAAC,CAAC,CAAC,EAAE;KAC/b;;;;;;;;;;","names":["checkResizeObserver","h","Host"],"sources":["../web-components/dist/collection/components/ic-typography/ic-typography.css?tag=ic-typography&encapsulation=shadow","../web-components/dist/collection/components/ic-typography/ic-typography.js"],"sourcesContent":["/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */\n\n/* Document\n ========================================================================== */\n\n/**\n * 1. Correct the line height in all browsers.\n * 2. Prevent adjustments of font size after orientation changes in iOS.\n */\n\nhtml {\n line-height: 1.15; /* 1 */\n -webkit-text-size-adjust: 100%; /* 2 */\n}\n\n/* Sections\n ========================================================================== */\n\n/**\n * Remove the margin in all browsers.\n */\n\nbody {\n margin: 0;\n}\n\n/**\n * Render the `main` element consistently in IE.\n */\n\nmain {\n display: block;\n}\n\n/**\n * Correct the font size and margin on `h1` elements within `section` and\n * `article` contexts in Chrome, Firefox, and Safari.\n */\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\n/* Grouping content\n ========================================================================== */\n\n/**\n * 1. Add the correct box sizing in Firefox.\n * 2. Show the overflow in Edge and IE.\n */\n\nhr {\n box-sizing: content-box; /* 1 */\n height: 0; /* 1 */\n overflow: visible; /* 2 */\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\n\npre {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/* Text-level semantics\n ========================================================================== */\n\n/**\n * Remove the gray background on active links in IE 10.\n */\n\na {\n background-color: transparent;\n}\n\n/**\n * 1. Remove the bottom border in Chrome 57-\n * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.\n */\n\nabbr[title] {\n border-bottom: none; /* 1 */\n text-decoration: underline; /* 2 */\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted; /* 2 */\n}\n\n/**\n * Add the correct font weight in Chrome, Edge, and Safari.\n */\n\nb,\nstrong {\n font-weight: bolder;\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/**\n * Add the correct font size in all browsers.\n */\n\nsmall {\n font-size: 80%;\n}\n\n/**\n * Prevent `sub` and `sup` elements from affecting the line height in\n * all browsers.\n */\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\n/* Embedded content\n ========================================================================== */\n\n/**\n * Remove the border on images inside links in IE 10.\n */\n\nimg {\n border-style: none;\n}\n\n/* Forms\n ========================================================================== */\n\n/**\n * 1. Change the font styles in all browsers.\n * 2. Remove the margin in Firefox and Safari.\n */\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: inherit; /* 1 */\n font-size: 100%; /* 1 */\n line-height: 1.15; /* 1 */\n margin: 0; /* 2 */\n}\n\n/**\n * Show the overflow in IE.\n * 1. Show the overflow in Edge.\n */\n\nbutton,\ninput {\n /* 1 */\n overflow: visible;\n}\n\n/**\n * Remove the inheritance of text transform in Edge, Firefox, and IE.\n * 1. Remove the inheritance of text transform in Firefox.\n */\n\nbutton,\nselect {\n /* 1 */\n text-transform: none;\n}\n\n/**\n * Correct the inability to style clickable types in iOS and Safari.\n */\n\nbutton,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\n/**\n * Remove the inner border and padding in Firefox.\n */\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\n/**\n * Restore the focus styles unset by the previous rule.\n */\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\n/**\n * Correct the padding in Firefox.\n */\n\nfieldset {\n padding: 0.35em 0.75em 0.625em;\n}\n\n/**\n * 1. Correct the text wrapping in Edge and IE.\n * 2. Correct the color inheritance from `fieldset` elements in IE.\n * 3. Remove the padding so developers are not caught out when they zero out\n * `fieldset` elements in all browsers.\n */\n\nlegend {\n box-sizing: border-box; /* 1 */\n color: inherit; /* 2 */\n display: table; /* 1 */\n max-width: 100%; /* 1 */\n padding: 0; /* 3 */\n white-space: normal; /* 1 */\n}\n\n/**\n * Add the correct vertical alignment in Chrome, Firefox, and Opera.\n */\n\nprogress {\n vertical-align: baseline;\n}\n\n/**\n * Remove the default vertical scrollbar in IE 10+.\n */\n\ntextarea {\n overflow: auto;\n}\n\n/**\n * 1. Add the correct box sizing in IE 10.\n * 2. Remove the padding in IE 10.\n */\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n box-sizing: border-box; /* 1 */\n padding: 0; /* 2 */\n}\n\n/**\n * Correct the cursor style of increment and decrement buttons in Chrome.\n */\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n/**\n * 1. Correct the odd appearance in Chrome and Safari.\n * 2. Correct the outline style in Safari.\n */\n\n[type=\"search\"] {\n -webkit-appearance: textfield; /* 1 */\n outline-offset: -2px; /* 2 */\n}\n\n/**\n * Remove the inner padding in Chrome and Safari on macOS.\n */\n\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n/**\n * 1. Correct the inability to style clickable types in iOS and Safari.\n * 2. Change font properties to `inherit` in Safari.\n */\n\n::-webkit-file-upload-button {\n -webkit-appearance: button; /* 1 */\n font: inherit; /* 2 */\n}\n\n/* Interactive\n ========================================================================== */\n\n/*\n * Add the correct display in Edge, IE 10+, and Firefox.\n */\n\ndetails {\n display: block;\n}\n\n/*\n * Add the correct display in all browsers.\n */\n\nsummary {\n display: list-item;\n}\n\n/* Misc\n ========================================================================== */\n\n/**\n * Add the correct display in IE 10+.\n */\n\ntemplate {\n display: none;\n}\n\n/**\n * Add the correct display in IE 10.\n */\n\n[hidden] {\n display: none;\n}\n\nhtml,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo {\n margin: 0;\n padding: 0;\n border: 0;\n font-size: 100%;\n font-style: inherit;\n vertical-align: baseline;\n}\n\n\n:host {\n display: block;\n position: relative;\n}\n\n:host(.ic-typography-vertical-margins-h1) {\n margin: 0 0 var(--ic-space-xl);\n}\n\n:host(.ic-typography-vertical-margins-h2) {\n margin: var(--ic-space-xxl) 0 var(--ic-space-lg);\n}\n\n:host(.ic-typography-vertical-margins-h3) {\n margin: var(--ic-space-xl) 0 var(--ic-space-md);\n}\n\n:host(.ic-typography-vertical-margins-h4) {\n margin: var(--ic-space-lg) 0 var(--ic-space-md);\n}\n\n:host(.ic-typography-vertical-margins-subtitle-large),\n:host(.ic-typography-vertical-margins-subtitle-small),\n:host(.ic-typography-vertical-margins-body),\n:host(.ic-typography-vertical-margins-code-large),\n:host(.ic-typography-vertical-margins-code-small),\n:host(.ic-typography-vertical-margins-code-extra-small) {\n margin: 0 0 var(--ic-space-md);\n}\n\n:host(.ic-typography-vertical-margins-caption),\n:host(.ic-typography-vertical-margins-caption-uppercase) {\n margin: 0 0 var(--ic-space-xs);\n}\n\n:host(.ic-typography-vertical-margins-h2:first-child),\n:host(.ic-typography-vertical-margins-h3:first-child),\n:host(.ic-typography-vertical-margins-h4:first-child) {\n margin-top: 0;\n}\n\n:host(.ic-typography-h1) {\n font: var(--ic-font-h1) !important;\n}\n\n:host(.ic-typography-h2) {\n font: var(--ic-font-h2);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n}\n\n:host(.ic-typography-h3) {\n font: var(--ic-font-h3);\n}\n\n:host(.ic-typography-h4) {\n font: var(--ic-font-h4);\n letter-spacing: var(--ic-font-letter-spacing-0pt0015);\n}\n\n:host(.ic-typography-subtitle-large) {\n font: var(--ic-font-subtitle-large);\n letter-spacing: var(--ic-font-letter-spacing-0pt0015);\n}\n\n:host(.ic-typography-subtitle-small) {\n font: var(--ic-font-subtitle-small);\n letter-spacing: var(--ic-font-letter-spacing-0pt0015);\n}\n\n:host(.ic-typography-body) {\n font: var(--ic-font-body);\n letter-spacing: var(--ic-font-letter-spacing-0pt005);\n}\n\n:host(.ic-typography-caption) {\n font: var(--ic-font-caption);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n}\n\n:host(.ic-typography-caption-uppercase) {\n font: var(--ic-font-caption);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n text-transform: uppercase;\n}\n\n:host(.ic-typography-label) {\n font: var(--ic-font-label);\n letter-spacing: var(--ic-font-letter-spacing-0pt025);\n}\n\n:host(.ic-typography-label-uppercase) {\n font: var(--ic-font-label);\n letter-spacing: var(--ic-font-letter-spacing-0pt025);\n text-transform: uppercase;\n}\n\n:host(.ic-typography-code-large) {\n font: var(--ic-font-code-large);\n letter-spacing: var(--ic-font-letter-spacing-0pt025);\n}\n\n:host(.ic-typography-code-small) {\n font: var(--ic-font-code-small);\n letter-spacing: var(--ic-font-letter-spacing-0pt005);\n}\n\n:host(.ic-typography-code-extra-small) {\n font: var(--ic-font-code-extra-small);\n letter-spacing: var(--ic-font-letter-spacing-0pt025);\n}\n\n:host(.ic-typography-badge) {\n font: var(--ic-font-badge);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n}\n\n:host(.ic-typography-badge-small) {\n font: var(--ic-font-badge-small);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n}\n\n:host(.ic-typography-no-wrap) {\n white-space: nowrap;\n}\n\n:host ::slotted(h1),\n:host ::slotted(h2),\n:host ::slotted(h3),\n:host ::slotted(h4),\n:host ::slotted(h5),\n:host ::slotted(h6),\n:host ::slotted(p),\n:host ::slotted(label) {\n font: inherit;\n letter-spacing: inherit;\n}\n\n.trunc-wrapper {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n line-clamp: var(--truncation-max-lines, initial);\n -webkit-line-clamp: var(--truncation-max-lines, initial);\n overflow: hidden;\n}\n\n.trunc-btn {\n border: none;\n background: none;\n padding: 0;\n color: var(--ic-color-primary-text);\n text-decoration: underline;\n font-weight: var(--ic-font-weight-bold);\n transition: var(--ic-easing-transition-fast);\n}\n\n.trunc-btn:hover,\n.trunc-btn.focus {\n outline: none;\n border-bottom: 0.25rem solid !important;\n margin-bottom: -0.25rem !important;\n text-decoration: none;\n cursor: pointer;\n}\n\n:host(.strikethrough) {\n text-decoration: line-through;\n}\n\n:host(.underline) {\n text-decoration: underline;\n}\n\n:host(.underline.strikethrough) {\n text-decoration: line-through underline;\n}\n\n:host(.italic) {\n font-style: italic !important;\n}\n\n:host(.bold) {\n font-weight: var(--ic-font-weight-bold);\n}\n\n@supports (text-underline-offset: 25%) {\n .trunc-btn:hover,\n .trunc-btn.focus {\n text-decoration-line: underline;\n text-decoration-thickness: 25%;\n text-underline-offset: 25%;\n border-bottom: 0 !important;\n margin-bottom: 0 !important;\n }\n}\n\n/* Add back in after storybook has the `color-scheme: light dark` code */\n\n/* @media (prefers-color-scheme: dark) and (not (forced-colors: active)) {\n :host,\n .trunc-btn {\n color: var(--ic-architectural-white);\n }\n} */\n","import { h, Host } from \"@stencil/core\";\nimport { checkResizeObserver } from \"../../utils/helpers\";\nexport class Typography {\n constructor() {\n this.focusBtnFromKeyboard = true;\n this.lastMarkerTop = 0;\n this.lastWidth = 0;\n this.resizeObserver = null;\n this.truncatedHeight = 0;\n this.toggleExpanded = () => {\n this.expanded = !this.expanded;\n };\n this.checkMaxLines = (height) => {\n //24 is the height of a single line\n const numLines = Math.floor(height / 24);\n if (numLines > this.maxLines) {\n this.el.setAttribute(\"style\", `--truncation-max-lines: ${this.maxLines}`);\n this.truncatedHeight = this.el.clientHeight;\n this.truncated = true;\n }\n };\n this.checkMarkerPosition = (elTop, markerTop) => {\n if (markerTop - elTop < this.truncatedHeight) {\n this.truncated = false;\n this.expanded = false;\n }\n else {\n this.truncated = true;\n }\n };\n this.getElementTop = (el) => {\n return el.getClientRects ? el.getClientRects()[0].top : 0;\n };\n this.runResizeObserver = () => {\n this.resizeObserver = new ResizeObserver(() => {\n clearTimeout(this.resizeInterval);\n this.resizeInterval = window.setTimeout(this.resizeObserverCallback, 50);\n });\n this.resizeObserver.observe(this.truncWrapperEl);\n };\n this.resizeObserverCallback = () => {\n if (this.lastWidth === this.el.clientWidth) {\n return;\n }\n if (this.truncatedHeight === 0) {\n this.checkMaxLines(this.el.clientHeight);\n return;\n }\n const markerTop = this.getElementTop(this.marker);\n if (markerTop === this.lastMarkerTop) {\n return;\n }\n this.checkMarkerPosition(this.getElementTop(this.el), markerTop);\n this.lastMarkerTop = markerTop;\n this.lastWidth = this.el.clientWidth;\n };\n this.truncButtonFocus = () => {\n if (this.focusBtnFromKeyboard) {\n this.truncButtonFocussed = true;\n }\n };\n this.truncButtonBlur = () => {\n this.focusBtnFromKeyboard = true;\n this.truncButtonFocussed = false;\n };\n this.truncButtonFocusFromMouse = () => {\n this.focusBtnFromKeyboard = false;\n };\n this.truncated = false;\n this.truncButtonFocussed = false;\n this.applyVerticalMargins = false;\n this.bold = false;\n this.italic = false;\n this.maxLines = undefined;\n this.strikethrough = false;\n this.underline = false;\n this.variant = \"body\";\n this.expanded = false;\n }\n watchExpandedHandler() {\n this.el.setAttribute(\"style\", `--truncation-max-lines: ${this.expanded ? \"initial\" : this.maxLines}`);\n }\n disconnectedCallback() {\n if (this.resizeObserver !== null) {\n this.resizeObserver.disconnect();\n }\n }\n componentDidLoad() {\n var _a, _b;\n if ((this.variant === \"body\" ||\n ((_b = (_a = this.el.getRootNode()) === null || _a === void 0 ? void 0 : _a.host) === null || _b === void 0 ? void 0 : _b.tagName) ===\n \"IC-TOOLTIP\") &&\n this.maxLines > 0) {\n const marker = document.createElement(\"span\");\n marker.style.visibility = \"hidden\";\n this.el.appendChild(marker);\n this.marker = marker;\n this.lastWidth = this.el.clientWidth;\n this.checkMaxLines(this.el.clientHeight);\n checkResizeObserver(this.runResizeObserver);\n }\n }\n render() {\n var _a, _b;\n const { variant, applyVerticalMargins, maxLines, truncated, expanded, strikethrough, underline, italic, bold, } = this;\n return (h(Host, { class: {\n [`ic-typography-${variant}`]: true,\n [`ic-typography-vertical-margins-${variant}`]: applyVerticalMargins,\n [\"bold\"]: bold,\n [\"italic\"]: italic,\n [\"strikethrough\"]: strikethrough,\n [\"underline\"]: underline,\n } }, (variant === \"body\" ||\n ((_b = (_a = this.el.getRootNode()) === null || _a === void 0 ? void 0 : _a.host) === null || _b === void 0 ? void 0 : _b.tagName) ===\n \"IC-TOOLTIP\") &&\n maxLines > 0 ? (h(\"div\", { class: \"trunc-wrapper\", ref: (el) => (this.truncWrapperEl = el) }, h(\"slot\", null))) : (h(\"slot\", null)), variant === \"body\" && maxLines > 0 && truncated && (h(\"button\", { class: { \"trunc-btn\": true, focus: this.truncButtonFocussed }, onFocus: this.truncButtonFocus, onBlur: this.truncButtonBlur, onMouseDown: this.truncButtonFocusFromMouse, onClick: this.toggleExpanded }, expanded ? \"See less\" : \"See more\"))));\n }\n static get is() { return \"ic-typography\"; }\n static get encapsulation() { return \"shadow\"; }\n static get originalStyleUrls() {\n return {\n \"$\": [\"ic-typography.css\"]\n };\n }\n static get styleUrls() {\n return {\n \"$\": [\"ic-typography.css\"]\n };\n }\n static get properties() {\n return {\n \"applyVerticalMargins\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, appropriate top and bottom margins will be applied to the typography.\"\n },\n \"attribute\": \"apply-vertical-margins\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"bold\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the typography will have a bold font weight.\\nNote: This will have no impact on variants that already use an equivalent or higher font weight (h1, h2, and subtitle-large).\"\n },\n \"attribute\": \"bold\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"italic\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the typography will have an italic font style.\"\n },\n \"attribute\": \"italic\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"maxLines\": {\n \"type\": \"number\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"number\",\n \"resolved\": \"number\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"The number of lines to display before truncating the text, only used for the 'body' variant.\"\n },\n \"attribute\": \"max-lines\",\n \"reflect\": false\n },\n \"strikethrough\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the typography will have a line through it.\"\n },\n \"attribute\": \"strikethrough\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"underline\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the typography will have a line under it.\"\n },\n \"attribute\": \"underline\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"variant\": {\n \"type\": \"string\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"IcTypographyVariants\",\n \"resolved\": \"\\\"badge\\\" | \\\"badge-small\\\" | \\\"body\\\" | \\\"caption\\\" | \\\"caption-uppercase\\\" | \\\"code-extra-small\\\" | \\\"code-large\\\" | \\\"code-small\\\" | \\\"h1\\\" | \\\"h2\\\" | \\\"h3\\\" | \\\"h4\\\" | \\\"label\\\" | \\\"label-uppercase\\\" | \\\"subtitle-large\\\" | \\\"subtitle-small\\\"\",\n \"references\": {\n \"IcTypographyVariants\": {\n \"location\": \"import\",\n \"path\": \"../../utils/types\",\n \"id\": \"src/utils/types.ts::IcTypographyVariants\"\n }\n }\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"The ICDS typography style to use.\"\n },\n \"attribute\": \"variant\",\n \"reflect\": false,\n \"defaultValue\": \"\\\"body\\\"\"\n }\n };\n }\n static get states() {\n return {\n \"truncated\": {},\n \"truncButtonFocussed\": {},\n \"expanded\": {}\n };\n }\n static get elementRef() { return \"el\"; }\n static get watchers() {\n return [{\n \"propName\": \"expanded\",\n \"methodName\": \"watchExpandedHandler\"\n }];\n }\n}\n//# sourceMappingURL=ic-typography.js.map\n"],"version":3}
1
+ {"file":"ic-typography.entry.cjs.js","mappings":";;;;;;;;AAAA,MAAM,eAAe,GAAG,+9MAA+9M;;MCE1+M,UAAU;IACnB;;;QACI,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC;QACjC,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;QACtB,IAAI,CAAC,aAAa,GAAG,CAAC,CAAC;QACvB,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC;QACnB,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC;QAC3B,IAAI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gBACd,CAAC,QAAQ,GAAG,MAAM;gBAClB,CAAC,eAAe,GAAG,aAAa;gBAChC,CAAC,WAAW,GAAG,SAAS;gBACxB,CAAC,YAAY,GAAG,IAAI,CAAC,QAAQ;aAChC,EAAE,EAAE,CAAC,OAAO,KAAK,MAAM;YACxB,CAAC,CAAC,EAAE,GAAG,CAAC,EAAE,GAAG,IAAI,CAAC,EAAE,CAAC,WAAW,EAAE,MAAM,IAAI,IAAI,EAAE,KAAK,KAAK,CAAC,GAAG,KAAK,CAAC,GAAG,EAAE,CAAC,IAAI,MAAM,IAAI,IAAI,EAAE,KAAK,KAAK,CAAC,GAAG,KAAK,CAAC,GAAG,EAAE,CAAC,OAAO;gBAC7H,YAAY;YAChB,QAAQ,GAAG,CAAC,IAAID,OAAC,CAAC,KAAK,EAAE,EAAE,KAAK,EAAE,eAAe,EAAE,GAAG,EAAE,CAAC,EAAE,MAAM,IAAI,CAAC,cAAc,GAAG,EAAE,CAAC,EAAE,EAAEA,OAAC,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC,KAAKA,OAAC,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC,EAAE,OAAO,KAAK,MAAM,IAAI,QAAQ,GAAG,CAAC,IAAI,SAAS,KAAKA,OAAC,CAAC,QAAQ,EAAE,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,CAAC,mBAAmB,EAAE,EAAE,OAAO,EAAE,IAAI,CAAC,gBAAgB,EAAE,MAAM,EAAE,IAAI,CAAC,eAAe,EAAE,WAAW,EAAE,IAAI,CAAC,yBAAyB,EAAE,OAAO,EAAE,IAAI,CAAC,cAAc,EAAE,EAAE,QAAQ,GAAG,UAAU,GAAG,UAAU,CAAC,CAAC,CAAC,EAAE;KAC/b;;;;;;;;;;","names":["checkResizeObserver","isElInAGGrid","h","Host"],"sources":["../web-components/dist/collection/components/ic-typography/ic-typography.css?tag=ic-typography&encapsulation=shadow","../web-components/dist/collection/components/ic-typography/ic-typography.js"],"sourcesContent":["/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */\n\n/* Document\n ========================================================================== */\n\n/**\n * 1. Correct the line height in all browsers.\n * 2. Prevent adjustments of font size after orientation changes in iOS.\n */\n\nhtml {\n line-height: 1.15; /* 1 */\n -webkit-text-size-adjust: 100%; /* 2 */\n}\n\n/* Sections\n ========================================================================== */\n\n/**\n * Remove the margin in all browsers.\n */\n\nbody {\n margin: 0;\n}\n\n/**\n * Render the `main` element consistently in IE.\n */\n\nmain {\n display: block;\n}\n\n/**\n * Correct the font size and margin on `h1` elements within `section` and\n * `article` contexts in Chrome, Firefox, and Safari.\n */\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\n/* Grouping content\n ========================================================================== */\n\n/**\n * 1. Add the correct box sizing in Firefox.\n * 2. Show the overflow in Edge and IE.\n */\n\nhr {\n box-sizing: content-box; /* 1 */\n height: 0; /* 1 */\n overflow: visible; /* 2 */\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\n\npre {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/* Text-level semantics\n ========================================================================== */\n\n/**\n * Remove the gray background on active links in IE 10.\n */\n\na {\n background-color: transparent;\n}\n\n/**\n * 1. Remove the bottom border in Chrome 57-\n * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.\n */\n\nabbr[title] {\n border-bottom: none; /* 1 */\n text-decoration: underline; /* 2 */\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted; /* 2 */\n}\n\n/**\n * Add the correct font weight in Chrome, Edge, and Safari.\n */\n\nb,\nstrong {\n font-weight: bolder;\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/**\n * Add the correct font size in all browsers.\n */\n\nsmall {\n font-size: 80%;\n}\n\n/**\n * Prevent `sub` and `sup` elements from affecting the line height in\n * all browsers.\n */\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\n/* Embedded content\n ========================================================================== */\n\n/**\n * Remove the border on images inside links in IE 10.\n */\n\nimg {\n border-style: none;\n}\n\n/* Forms\n ========================================================================== */\n\n/**\n * 1. Change the font styles in all browsers.\n * 2. Remove the margin in Firefox and Safari.\n */\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: inherit; /* 1 */\n font-size: 100%; /* 1 */\n line-height: 1.15; /* 1 */\n margin: 0; /* 2 */\n}\n\n/**\n * Show the overflow in IE.\n * 1. Show the overflow in Edge.\n */\n\nbutton,\ninput {\n /* 1 */\n overflow: visible;\n}\n\n/**\n * Remove the inheritance of text transform in Edge, Firefox, and IE.\n * 1. Remove the inheritance of text transform in Firefox.\n */\n\nbutton,\nselect {\n /* 1 */\n text-transform: none;\n}\n\n/**\n * Correct the inability to style clickable types in iOS and Safari.\n */\n\nbutton,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\n/**\n * Remove the inner border and padding in Firefox.\n */\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\n/**\n * Restore the focus styles unset by the previous rule.\n */\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\n/**\n * Correct the padding in Firefox.\n */\n\nfieldset {\n padding: 0.35em 0.75em 0.625em;\n}\n\n/**\n * 1. Correct the text wrapping in Edge and IE.\n * 2. Correct the color inheritance from `fieldset` elements in IE.\n * 3. Remove the padding so developers are not caught out when they zero out\n * `fieldset` elements in all browsers.\n */\n\nlegend {\n box-sizing: border-box; /* 1 */\n color: inherit; /* 2 */\n display: table; /* 1 */\n max-width: 100%; /* 1 */\n padding: 0; /* 3 */\n white-space: normal; /* 1 */\n}\n\n/**\n * Add the correct vertical alignment in Chrome, Firefox, and Opera.\n */\n\nprogress {\n vertical-align: baseline;\n}\n\n/**\n * Remove the default vertical scrollbar in IE 10+.\n */\n\ntextarea {\n overflow: auto;\n}\n\n/**\n * 1. Add the correct box sizing in IE 10.\n * 2. Remove the padding in IE 10.\n */\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n box-sizing: border-box; /* 1 */\n padding: 0; /* 2 */\n}\n\n/**\n * Correct the cursor style of increment and decrement buttons in Chrome.\n */\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n/**\n * 1. Correct the odd appearance in Chrome and Safari.\n * 2. Correct the outline style in Safari.\n */\n\n[type=\"search\"] {\n -webkit-appearance: textfield; /* 1 */\n outline-offset: -2px; /* 2 */\n}\n\n/**\n * Remove the inner padding in Chrome and Safari on macOS.\n */\n\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n/**\n * 1. Correct the inability to style clickable types in iOS and Safari.\n * 2. Change font properties to `inherit` in Safari.\n */\n\n::-webkit-file-upload-button {\n -webkit-appearance: button; /* 1 */\n font: inherit; /* 2 */\n}\n\n/* Interactive\n ========================================================================== */\n\n/*\n * Add the correct display in Edge, IE 10+, and Firefox.\n */\n\ndetails {\n display: block;\n}\n\n/*\n * Add the correct display in all browsers.\n */\n\nsummary {\n display: list-item;\n}\n\n/* Misc\n ========================================================================== */\n\n/**\n * Add the correct display in IE 10+.\n */\n\ntemplate {\n display: none;\n}\n\n/**\n * Add the correct display in IE 10.\n */\n\n[hidden] {\n display: none;\n}\n\nhtml,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo {\n margin: 0;\n padding: 0;\n border: 0;\n font-size: 100%;\n font-style: inherit;\n vertical-align: baseline;\n}\n\n\n:host {\n display: block;\n position: relative;\n}\n\n:host(.ic-typography-vertical-margins-h1) {\n margin: 0 0 var(--ic-space-xl);\n}\n\n:host(.ic-typography-vertical-margins-h2) {\n margin: var(--ic-space-xxl) 0 var(--ic-space-lg);\n}\n\n:host(.ic-typography-vertical-margins-h3) {\n margin: var(--ic-space-xl) 0 var(--ic-space-md);\n}\n\n:host(.ic-typography-vertical-margins-h4) {\n margin: var(--ic-space-lg) 0 var(--ic-space-md);\n}\n\n:host(.ic-typography-vertical-margins-subtitle-large),\n:host(.ic-typography-vertical-margins-subtitle-small),\n:host(.ic-typography-vertical-margins-body),\n:host(.ic-typography-vertical-margins-code-large),\n:host(.ic-typography-vertical-margins-code-small),\n:host(.ic-typography-vertical-margins-code-extra-small) {\n margin: 0 0 var(--ic-space-md);\n}\n\n:host(.ic-typography-vertical-margins-caption),\n:host(.ic-typography-vertical-margins-caption-uppercase) {\n margin: 0 0 var(--ic-space-xs);\n}\n\n:host(.ic-typography-vertical-margins-h2:first-child),\n:host(.ic-typography-vertical-margins-h3:first-child),\n:host(.ic-typography-vertical-margins-h4:first-child) {\n margin-top: 0;\n}\n\n:host(.ic-typography-h1) {\n font: var(--ic-font-h1) !important;\n}\n\n:host(.ic-typography-h2) {\n font: var(--ic-font-h2);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n}\n\n:host(.ic-typography-h3) {\n font: var(--ic-font-h3);\n}\n\n:host(.ic-typography-h4) {\n font: var(--ic-font-h4);\n letter-spacing: var(--ic-font-letter-spacing-0pt0015);\n}\n\n:host(.ic-typography-subtitle-large) {\n font: var(--ic-font-subtitle-large);\n letter-spacing: var(--ic-font-letter-spacing-0pt0015);\n}\n\n:host(.ic-typography-subtitle-small) {\n font: var(--ic-font-subtitle-small);\n letter-spacing: var(--ic-font-letter-spacing-0pt0015);\n}\n\n:host(.ic-typography-body) {\n font: var(--ic-font-body);\n letter-spacing: var(--ic-font-letter-spacing-0pt005);\n}\n\n:host(.ic-typography-caption) {\n font: var(--ic-font-caption);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n}\n\n:host(.ic-typography-caption-uppercase) {\n font: var(--ic-font-caption);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n text-transform: uppercase;\n}\n\n:host(.ic-typography-label) {\n font: var(--ic-font-label);\n letter-spacing: var(--ic-font-letter-spacing-0pt025);\n}\n\n:host(.ic-typography-label-uppercase) {\n font: var(--ic-font-label);\n letter-spacing: var(--ic-font-letter-spacing-0pt025);\n text-transform: uppercase;\n}\n\n:host(.ic-typography-code-large) {\n font: var(--ic-font-code-large);\n letter-spacing: var(--ic-font-letter-spacing-0pt025);\n}\n\n:host(.ic-typography-code-small) {\n font: var(--ic-font-code-small);\n letter-spacing: var(--ic-font-letter-spacing-0pt005);\n}\n\n:host(.ic-typography-code-extra-small) {\n font: var(--ic-font-code-extra-small);\n letter-spacing: var(--ic-font-letter-spacing-0pt025);\n}\n\n:host(.ic-typography-badge) {\n font: var(--ic-font-badge);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n}\n\n:host(.ic-typography-badge-small) {\n font: var(--ic-font-badge-small);\n letter-spacing: var(--ic-font-letter-spacing-0pt0025);\n}\n\n:host(.ic-typography-no-wrap) {\n white-space: nowrap;\n}\n\n:host ::slotted(h1),\n:host ::slotted(h2),\n:host ::slotted(h3),\n:host ::slotted(h4),\n:host ::slotted(h5),\n:host ::slotted(h6),\n:host ::slotted(p),\n:host ::slotted(label) {\n font: inherit;\n letter-spacing: inherit;\n}\n\n.trunc-wrapper {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n line-clamp: var(--truncation-max-lines, initial);\n -webkit-line-clamp: var(--truncation-max-lines, initial);\n overflow: hidden;\n padding-right: var(--ellipsis-padding-right, 0);\n}\n\n.trunc-btn {\n border: none;\n background: none;\n padding: 0;\n color: var(--ic-color-primary-text);\n text-decoration: underline;\n font-weight: var(--ic-font-weight-bold);\n transition: var(--ic-easing-transition-fast);\n}\n\n.trunc-btn:hover,\n.trunc-btn.focus {\n outline: none;\n border-bottom: 0.25rem solid !important;\n margin-bottom: -0.25rem !important;\n text-decoration: none;\n cursor: pointer;\n}\n\n:host(.strikethrough) {\n text-decoration: line-through;\n}\n\n:host(.underline) {\n text-decoration: underline;\n}\n\n:host(.underline.strikethrough) {\n text-decoration: line-through underline;\n}\n\n:host(.italic) {\n font-style: italic !important;\n}\n\n:host(.bold) {\n font-weight: var(--ic-font-weight-bold);\n}\n\n:host(.in-ag-grid),\n:host(.in-ag-grid) ::slotted(*) {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n@supports (text-underline-offset: 25%) {\n .trunc-btn:hover,\n .trunc-btn.focus {\n text-decoration-line: underline;\n text-decoration-thickness: 25%;\n text-underline-offset: 25%;\n border-bottom: 0 !important;\n margin-bottom: 0 !important;\n }\n}\n\n/* Add back in after storybook has the `color-scheme: light dark` code */\n\n/* @media (prefers-color-scheme: dark) and (not (forced-colors: active)) {\n :host,\n .trunc-btn {\n color: var(--ic-architectural-white);\n }\n} */\n","import { h, Host, } from \"@stencil/core\";\nimport { checkResizeObserver, isElInAGGrid } from \"../../utils/helpers\";\nexport class Typography {\n constructor() {\n this.focusBtnFromKeyboard = true;\n this.inAGGrid = false;\n this.lastMarkerTop = 0;\n this.lastWidth = 0;\n this.resizeObserver = null;\n this.truncatedHeight = 0;\n this.toggleExpanded = (ev) => {\n ev.stopPropagation();\n this.expanded = !this.expanded;\n this.typographyTruncationExpandToggle.emit({\n expanded: this.expanded,\n typographyEl: this.el,\n });\n };\n this.checkMarkerPosition = (elTop, markerTop) => {\n if (markerTop - elTop < this.truncatedHeight) {\n this.truncated = false;\n this.expanded = false;\n }\n else {\n this.truncated = true;\n }\n };\n this.getElementTop = (el) => {\n return el.getClientRects ? el.getClientRects()[0].top : 0;\n };\n this.runResizeObserver = () => {\n this.resizeObserver = new ResizeObserver(() => {\n clearTimeout(this.resizeInterval);\n this.resizeInterval = window.setTimeout(this.resizeObserverCallback, 50);\n });\n this.resizeObserver.observe(this.truncWrapperEl);\n };\n this.resizeObserverCallback = () => {\n if (this.lastWidth === this.el.clientWidth) {\n return;\n }\n if (this.truncatedHeight === 0) {\n this.checkMaxLines(this.el.clientHeight);\n return;\n }\n const markerTop = this.getElementTop(this.marker);\n if (markerTop === this.lastMarkerTop) {\n return;\n }\n this.checkMarkerPosition(this.getElementTop(this.el), markerTop);\n this.lastMarkerTop = markerTop;\n this.lastWidth = this.el.clientWidth;\n };\n this.truncButtonFocus = () => {\n if (this.focusBtnFromKeyboard) {\n this.truncButtonFocussed = true;\n }\n };\n this.truncButtonBlur = () => {\n this.focusBtnFromKeyboard = true;\n this.truncButtonFocussed = false;\n };\n this.truncButtonFocusFromMouse = () => {\n this.focusBtnFromKeyboard = false;\n };\n this.truncated = false;\n this.truncButtonFocussed = false;\n this.applyVerticalMargins = false;\n this.bold = false;\n this.italic = false;\n this.maxLines = undefined;\n this.strikethrough = false;\n this.underline = false;\n this.variant = \"body\";\n this.expanded = false;\n }\n watchExpandedHandler() {\n this.el.setAttribute(\"style\", `--truncation-max-lines: ${this.expanded ? \"initial\" : this.maxLines}`);\n }\n disconnectedCallback() {\n if (this.resizeObserver !== null) {\n this.resizeObserver.disconnect();\n }\n }\n /**\n * @internal This is used by data table to remove all truncation in certain events\n */\n async resetTruncation() {\n if (this.truncated) {\n this.truncated = false;\n this.maxLines = 0;\n this.el.removeAttribute(\"max-lines\");\n this.expanded = false;\n this.el.removeAttribute(\"style\");\n }\n }\n componentDidLoad() {\n var _a, _b;\n if ((this.variant === \"body\" ||\n ((_b = (_a = this.el.getRootNode()) === null || _a === void 0 ? void 0 : _a.host) === null || _b === void 0 ? void 0 : _b.tagName) ===\n \"IC-TOOLTIP\") &&\n this.maxLines > 0) {\n const marker = document.createElement(\"span\");\n marker.style.visibility = \"hidden\";\n this.el.appendChild(marker);\n this.marker = marker;\n this.lastWidth = this.el.clientWidth;\n this.checkMaxLines(this.el.clientHeight);\n checkResizeObserver(this.runResizeObserver);\n }\n }\n componentWillRender() {\n if (isElInAGGrid(this.el)) {\n this.inAGGrid = true;\n }\n }\n /**\n * @internal This checks if the number of lines of text exceeds the maxLines prop. If so, set the line clamp CSS to the max lines\n * @param height - text container height\n */\n async checkMaxLines(height) {\n //24 is the height of a single line\n const numLines = Math.floor(height / 24);\n if (numLines > this.maxLines) {\n this.el.setAttribute(\"style\", `--truncation-max-lines: ${this.maxLines}`);\n this.truncatedHeight = this.el.clientHeight;\n this.truncated = true;\n }\n }\n /**\n * @internal This method makes it possible to set the expanded status of truncated text outside of ic-typography component\n */\n async setShowHideExpanded(expanded) {\n this.expanded = expanded;\n }\n render() {\n var _a, _b;\n const { variant, applyVerticalMargins, maxLines, truncated, expanded, strikethrough, underline, italic, bold, } = this;\n return (h(Host, { class: {\n [`ic-typography-${variant}`]: true,\n [`ic-typography-vertical-margins-${variant}`]: applyVerticalMargins,\n [\"bold\"]: bold,\n [\"italic\"]: italic,\n [\"strikethrough\"]: strikethrough,\n [\"underline\"]: underline,\n [\"in-ag-grid\"]: this.inAGGrid,\n } }, (variant === \"body\" ||\n ((_b = (_a = this.el.getRootNode()) === null || _a === void 0 ? void 0 : _a.host) === null || _b === void 0 ? void 0 : _b.tagName) ===\n \"IC-TOOLTIP\") &&\n maxLines > 0 ? (h(\"div\", { class: \"trunc-wrapper\", ref: (el) => (this.truncWrapperEl = el) }, h(\"slot\", null))) : (h(\"slot\", null)), variant === \"body\" && maxLines > 0 && truncated && (h(\"button\", { class: { \"trunc-btn\": true, focus: this.truncButtonFocussed }, onFocus: this.truncButtonFocus, onBlur: this.truncButtonBlur, onMouseDown: this.truncButtonFocusFromMouse, onClick: this.toggleExpanded }, expanded ? \"See less\" : \"See more\"))));\n }\n static get is() { return \"ic-typography\"; }\n static get encapsulation() { return \"shadow\"; }\n static get originalStyleUrls() {\n return {\n \"$\": [\"ic-typography.css\"]\n };\n }\n static get styleUrls() {\n return {\n \"$\": [\"ic-typography.css\"]\n };\n }\n static get properties() {\n return {\n \"applyVerticalMargins\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, appropriate top and bottom margins will be applied to the typography.\"\n },\n \"attribute\": \"apply-vertical-margins\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"bold\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the typography will have a bold font weight.\\nNote: This will have no impact on variants that already use an equivalent or higher font weight (h1, h2, and subtitle-large).\"\n },\n \"attribute\": \"bold\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"italic\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the typography will have an italic font style.\"\n },\n \"attribute\": \"italic\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"maxLines\": {\n \"type\": \"number\",\n \"mutable\": true,\n \"complexType\": {\n \"original\": \"number\",\n \"resolved\": \"number\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"The number of lines to display before truncating the text, only used for the 'body' variant.\"\n },\n \"attribute\": \"max-lines\",\n \"reflect\": false\n },\n \"strikethrough\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the typography will have a line through it.\"\n },\n \"attribute\": \"strikethrough\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"underline\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the typography will have a line under it.\"\n },\n \"attribute\": \"underline\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"variant\": {\n \"type\": \"string\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"IcTypographyVariants\",\n \"resolved\": \"\\\"badge\\\" | \\\"badge-small\\\" | \\\"body\\\" | \\\"caption\\\" | \\\"caption-uppercase\\\" | \\\"code-extra-small\\\" | \\\"code-large\\\" | \\\"code-small\\\" | \\\"h1\\\" | \\\"h2\\\" | \\\"h3\\\" | \\\"h4\\\" | \\\"label\\\" | \\\"label-uppercase\\\" | \\\"subtitle-large\\\" | \\\"subtitle-small\\\"\",\n \"references\": {\n \"IcTypographyVariants\": {\n \"location\": \"import\",\n \"path\": \"../../utils/types\",\n \"id\": \"src/utils/types.ts::IcTypographyVariants\"\n }\n }\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"The ICDS typography style to use.\"\n },\n \"attribute\": \"variant\",\n \"reflect\": false,\n \"defaultValue\": \"\\\"body\\\"\"\n }\n };\n }\n static get states() {\n return {\n \"truncated\": {},\n \"truncButtonFocussed\": {},\n \"expanded\": {}\n };\n }\n static get events() {\n return [{\n \"method\": \"typographyTruncationExpandToggle\",\n \"name\": \"typographyTruncationExpandToggle\",\n \"bubbles\": true,\n \"cancelable\": true,\n \"composed\": true,\n \"docs\": {\n \"tags\": [{\n \"name\": \"internal\",\n \"text\": \"Emits and event when the typography truncation button has been clicked.\"\n }],\n \"text\": \"\"\n },\n \"complexType\": {\n \"original\": \"{\\n expanded: boolean;\\n typographyEl: HTMLIcTypographyElement;\\n }\",\n \"resolved\": \"{ expanded: boolean; typographyEl: HTMLIcTypographyElement; }\",\n \"references\": {\n \"HTMLIcTypographyElement\": {\n \"location\": \"global\",\n \"id\": \"global::HTMLIcTypographyElement\"\n }\n }\n }\n }];\n }\n static get methods() {\n return {\n \"resetTruncation\": {\n \"complexType\": {\n \"signature\": \"() => Promise<void>\",\n \"parameters\": [],\n \"references\": {\n \"Promise\": {\n \"location\": \"global\",\n \"id\": \"global::Promise\"\n }\n },\n \"return\": \"Promise<void>\"\n },\n \"docs\": {\n \"text\": \"\",\n \"tags\": [{\n \"name\": \"internal\",\n \"text\": \"This is used by data table to remove all truncation in certain events\"\n }]\n }\n },\n \"checkMaxLines\": {\n \"complexType\": {\n \"signature\": \"(height: number) => Promise<void>\",\n \"parameters\": [{\n \"name\": \"height\",\n \"type\": \"number\",\n \"docs\": \"- text container height\"\n }],\n \"references\": {\n \"Promise\": {\n \"location\": \"global\",\n \"id\": \"global::Promise\"\n }\n },\n \"return\": \"Promise<void>\"\n },\n \"docs\": {\n \"text\": \"\",\n \"tags\": [{\n \"name\": \"internal\",\n \"text\": \"This checks if the number of lines of text exceeds the maxLines prop. If so, set the line clamp CSS to the max lines\"\n }, {\n \"name\": \"param\",\n \"text\": \"height - text container height\"\n }]\n }\n },\n \"setShowHideExpanded\": {\n \"complexType\": {\n \"signature\": \"(expanded: boolean) => Promise<void>\",\n \"parameters\": [{\n \"name\": \"expanded\",\n \"type\": \"boolean\",\n \"docs\": \"\"\n }],\n \"references\": {\n \"Promise\": {\n \"location\": \"global\",\n \"id\": \"global::Promise\"\n }\n },\n \"return\": \"Promise<void>\"\n },\n \"docs\": {\n \"text\": \"\",\n \"tags\": [{\n \"name\": \"internal\",\n \"text\": \"This method makes it possible to set the expanded status of truncated text outside of ic-typography component\"\n }]\n }\n }\n };\n }\n static get elementRef() { return \"el\"; }\n static get watchers() {\n return [{\n \"propName\": \"expanded\",\n \"methodName\": \"watchExpandedHandler\"\n }];\n }\n}\n//# sourceMappingURL=ic-typography.js.map\n"],"version":3}
@@ -2915,6 +2915,14 @@ const loadModule = (cmpMeta, hostRef, hmrVersionId) => {
2915
2915
  return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
2916
2916
  /* webpackMode: "lazy" */
2917
2917
  './ic-top-navigation.cjs.entry.js')); }).then(processMod, consoleError);
2918
+ case 'ic-tree-item.cjs':
2919
+ return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
2920
+ /* webpackMode: "lazy" */
2921
+ './ic-tree-item.cjs.entry.js')); }).then(processMod, consoleError);
2922
+ case 'ic-tree-view.cjs':
2923
+ return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
2924
+ /* webpackMode: "lazy" */
2925
+ './ic-tree-view.cjs.entry.js')); }).then(processMod, consoleError);
2918
2926
  case 'ic-alert.cjs':
2919
2927
  return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
2920
2928
  /* webpackMode: "lazy" */