@ukic/web-components 2.3.0 → 2.4.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (656) hide show
  1. package/dist/cjs/{OpenInNew-f9958725.js → OpenInNew-d5d30e77.js} +1 -1
  2. package/dist/cjs/OpenInNew-d5d30e77.js.map +1 -0
  3. package/dist/cjs/{check-icon-b2f60716.js → check-icon-7225d79b.js} +1 -1
  4. package/dist/cjs/check-icon-7225d79b.js.map +1 -0
  5. package/dist/cjs/{chevron-icon-2bb3a907.js → chevron-icon-3bf07531.js} +1 -1
  6. package/dist/cjs/chevron-icon-3bf07531.js.map +1 -0
  7. package/dist/cjs/{close-icon-04be4880.js → close-icon-7f6ef8e4.js} +1 -1
  8. package/dist/cjs/close-icon-7f6ef8e4.js.map +1 -0
  9. package/dist/cjs/core.cjs.js +3 -6
  10. package/dist/cjs/core.cjs.js.map +1 -1
  11. package/dist/cjs/{helpers-3811d14b.js → helpers-d166f875.js} +27 -10
  12. package/dist/cjs/helpers-d166f875.js.map +1 -0
  13. package/dist/cjs/ic-alert.cjs.entry.js +4 -4
  14. package/dist/cjs/ic-alert.cjs.entry.js.map +1 -1
  15. package/dist/cjs/ic-back-to-top.cjs.entry.js +3 -3
  16. package/dist/cjs/ic-back-to-top.cjs.entry.js.map +1 -1
  17. package/dist/cjs/ic-breadcrumb-group.cjs.entry.js +3 -3
  18. package/dist/cjs/ic-breadcrumb-group.cjs.entry.js.map +1 -1
  19. package/dist/cjs/ic-breadcrumb.cjs.entry.js +4 -4
  20. package/dist/cjs/ic-breadcrumb.cjs.entry.js.map +1 -1
  21. package/dist/cjs/ic-button_3.cjs.entry.js +30 -9
  22. package/dist/cjs/ic-button_3.cjs.entry.js.map +1 -1
  23. package/dist/cjs/ic-card.cjs.entry.js +4 -4
  24. package/dist/cjs/ic-card.cjs.entry.js.map +1 -1
  25. package/dist/cjs/ic-checkbox-group.cjs.entry.js +3 -3
  26. package/dist/cjs/ic-checkbox-group.cjs.entry.js.map +1 -1
  27. package/dist/cjs/ic-checkbox.cjs.entry.js +3 -3
  28. package/dist/cjs/ic-checkbox.cjs.entry.js.map +1 -1
  29. package/dist/cjs/ic-chip.cjs.entry.js +3 -3
  30. package/dist/cjs/ic-chip.cjs.entry.js.map +1 -1
  31. package/dist/cjs/ic-classification-banner.cjs.entry.js +1 -1
  32. package/dist/cjs/ic-classification-banner.cjs.entry.js.map +1 -1
  33. package/dist/cjs/ic-data-entity.cjs.entry.js +1 -1
  34. package/dist/cjs/ic-data-entity.cjs.entry.js.map +1 -1
  35. package/dist/cjs/ic-data-row.cjs.entry.js +3 -3
  36. package/dist/cjs/ic-data-row.cjs.entry.js.map +1 -1
  37. package/dist/cjs/ic-dialog.cjs.entry.js +4 -4
  38. package/dist/cjs/ic-dialog.cjs.entry.js.map +1 -1
  39. package/dist/cjs/ic-divider.cjs.entry.js +3 -3
  40. package/dist/cjs/ic-divider.cjs.entry.js.map +1 -1
  41. package/dist/cjs/ic-empty-state.cjs.entry.js +3 -3
  42. package/dist/cjs/ic-empty-state.cjs.entry.js.map +1 -1
  43. package/dist/cjs/ic-footer-link-group.cjs.entry.js +3 -3
  44. package/dist/cjs/ic-footer-link-group.cjs.entry.js.map +1 -1
  45. package/dist/cjs/ic-footer-link.cjs.entry.js +4 -4
  46. package/dist/cjs/ic-footer-link.cjs.entry.js.map +1 -1
  47. package/dist/cjs/ic-footer.cjs.entry.js +3 -3
  48. package/dist/cjs/ic-footer.cjs.entry.js.map +1 -1
  49. package/dist/cjs/ic-hero.cjs.entry.js +3 -3
  50. package/dist/cjs/ic-hero.cjs.entry.js.map +1 -1
  51. package/dist/cjs/ic-horizontal-scroll.cjs.entry.js +3 -3
  52. package/dist/cjs/ic-horizontal-scroll.cjs.entry.js.map +1 -1
  53. package/dist/cjs/ic-input-component-container_3.cjs.entry.js +43 -37
  54. package/dist/cjs/ic-input-component-container_3.cjs.entry.js.map +1 -1
  55. package/dist/cjs/ic-input-label_2.cjs.entry.js +3 -3
  56. package/dist/cjs/ic-input-label_2.cjs.entry.js.map +1 -1
  57. package/dist/cjs/ic-link.cjs.entry.js +4 -4
  58. package/dist/cjs/ic-link.cjs.entry.js.map +1 -1
  59. package/dist/cjs/ic-menu-group.cjs.entry.js +1 -1
  60. package/dist/cjs/ic-menu-group.cjs.entry.js.map +1 -1
  61. package/dist/cjs/ic-menu-item.cjs.entry.js +5 -5
  62. package/dist/cjs/ic-menu-item.cjs.entry.js.map +1 -1
  63. package/dist/cjs/ic-navigation-button.cjs.entry.js +7 -3
  64. package/dist/cjs/ic-navigation-button.cjs.entry.js.map +1 -1
  65. package/dist/cjs/ic-navigation-group.cjs.entry.js +4 -4
  66. package/dist/cjs/ic-navigation-group.cjs.entry.js.map +1 -1
  67. package/dist/cjs/ic-navigation-item.cjs.entry.js +5 -5
  68. package/dist/cjs/ic-navigation-item.cjs.entry.js.map +1 -1
  69. package/dist/cjs/ic-navigation-menu.cjs.entry.js +3 -3
  70. package/dist/cjs/ic-navigation-menu.cjs.entry.js.map +1 -1
  71. package/dist/cjs/ic-page-header.cjs.entry.js +3 -3
  72. package/dist/cjs/ic-page-header.cjs.entry.js.map +1 -1
  73. package/dist/cjs/ic-pagination-item.cjs.entry.js +3 -3
  74. package/dist/cjs/ic-pagination-item.cjs.entry.js.map +1 -1
  75. package/dist/cjs/ic-pagination.cjs.entry.js +3 -3
  76. package/dist/cjs/ic-pagination.cjs.entry.js.map +1 -1
  77. package/dist/cjs/ic-popover-menu.cjs.entry.js +4 -4
  78. package/dist/cjs/ic-popover-menu.cjs.entry.js.map +1 -1
  79. package/dist/cjs/ic-radio-group.cjs.entry.js +3 -3
  80. package/dist/cjs/ic-radio-group.cjs.entry.js.map +1 -1
  81. package/dist/cjs/ic-radio-option.cjs.entry.js +3 -3
  82. package/dist/cjs/ic-radio-option.cjs.entry.js.map +1 -1
  83. package/dist/cjs/ic-search-bar.cjs.entry.js +35 -19
  84. package/dist/cjs/ic-search-bar.cjs.entry.js.map +1 -1
  85. package/dist/cjs/ic-section-container.cjs.entry.js +1 -1
  86. package/dist/cjs/ic-section-container.cjs.entry.js.map +1 -1
  87. package/dist/cjs/ic-select.cjs.entry.js +71 -17
  88. package/dist/cjs/ic-select.cjs.entry.js.map +1 -1
  89. package/dist/cjs/ic-side-navigation.cjs.entry.js +5 -5
  90. package/dist/cjs/ic-side-navigation.cjs.entry.js.map +1 -1
  91. package/dist/cjs/ic-skeleton.cjs.entry.js +1 -1
  92. package/dist/cjs/ic-skeleton.cjs.entry.js.map +1 -1
  93. package/dist/cjs/ic-status-tag.cjs.entry.js +3 -3
  94. package/dist/cjs/ic-status-tag.cjs.entry.js.map +1 -1
  95. package/dist/cjs/ic-step.cjs.entry.js +2 -2
  96. package/dist/cjs/ic-step.cjs.entry.js.map +1 -1
  97. package/dist/cjs/ic-stepper.cjs.entry.js +3 -3
  98. package/dist/cjs/ic-stepper.cjs.entry.js.map +1 -1
  99. package/dist/cjs/ic-switch.cjs.entry.js +3 -3
  100. package/dist/cjs/ic-switch.cjs.entry.js.map +1 -1
  101. package/dist/cjs/ic-tab-context.cjs.entry.js +2 -2
  102. package/dist/cjs/ic-tab-context.cjs.entry.js.map +1 -1
  103. package/dist/cjs/ic-tab-group.cjs.entry.js +3 -3
  104. package/dist/cjs/ic-tab-group.cjs.entry.js.map +1 -1
  105. package/dist/cjs/ic-tab-panel.cjs.entry.js +2 -2
  106. package/dist/cjs/ic-tab-panel.cjs.entry.js.map +1 -1
  107. package/dist/cjs/ic-tab.cjs.entry.js +3 -3
  108. package/dist/cjs/ic-tab.cjs.entry.js.map +1 -1
  109. package/dist/cjs/ic-text-field.cjs.entry.js +3 -3
  110. package/dist/cjs/ic-text-field.cjs.entry.js.map +1 -1
  111. package/dist/cjs/ic-theme.cjs.entry.js +3 -3
  112. package/dist/cjs/ic-theme.cjs.entry.js.map +1 -1
  113. package/dist/cjs/ic-toast-region.cjs.entry.js +1 -1
  114. package/dist/cjs/ic-toast-region.cjs.entry.js.map +1 -1
  115. package/dist/cjs/ic-toast.cjs.entry.js +4 -4
  116. package/dist/cjs/ic-toast.cjs.entry.js.map +1 -1
  117. package/dist/cjs/ic-top-navigation.cjs.entry.js +3 -3
  118. package/dist/cjs/ic-top-navigation.cjs.entry.js.map +1 -1
  119. package/dist/cjs/ic-typography.cjs.entry.js +3 -3
  120. package/dist/cjs/ic-typography.cjs.entry.js.map +1 -1
  121. package/dist/cjs/{index-2a0c6769.js → index-54d2bed9.js} +98 -26
  122. package/dist/cjs/index-54d2bed9.js.map +1 -0
  123. package/dist/cjs/loader.cjs.js +3 -12
  124. package/dist/cjs/loader.cjs.js.map +1 -1
  125. package/dist/cjs/{popper-d7adcfc6.js → popper-31badbf8.js} +1 -1
  126. package/dist/cjs/popper-31badbf8.js.map +1 -0
  127. package/dist/cjs/{types-3eb02246.js → types-7d67439f.js} +1 -1
  128. package/dist/cjs/types-7d67439f.js.map +1 -0
  129. package/dist/collection/collection-manifest.json +61 -61
  130. package/dist/collection/components/ic-alert/ic-alert.js +2 -1
  131. package/dist/collection/components/ic-alert/ic-alert.js.map +1 -1
  132. package/dist/collection/components/ic-breadcrumb/ic-breadcrumb.js +5 -1
  133. package/dist/collection/components/ic-breadcrumb/ic-breadcrumb.js.map +1 -1
  134. package/dist/collection/components/ic-button/ic-button.css +0 -4
  135. package/dist/collection/components/ic-button/ic-button.js +41 -12
  136. package/dist/collection/components/ic-button/ic-button.js.map +1 -1
  137. package/dist/collection/components/ic-card/ic-card.js +4 -2
  138. package/dist/collection/components/ic-card/ic-card.js.map +1 -1
  139. package/dist/collection/components/ic-checkbox/ic-checkbox.js +8 -4
  140. package/dist/collection/components/ic-checkbox/ic-checkbox.js.map +1 -1
  141. package/dist/collection/components/ic-checkbox-group/ic-checkbox-group.js +6 -3
  142. package/dist/collection/components/ic-checkbox-group/ic-checkbox-group.js.map +1 -1
  143. package/dist/collection/components/ic-chip/ic-chip.js +6 -3
  144. package/dist/collection/components/ic-chip/ic-chip.js.map +1 -1
  145. package/dist/collection/components/ic-classification-banner/ic-classification-banner.js +2 -1
  146. package/dist/collection/components/ic-classification-banner/ic-classification-banner.js.map +1 -1
  147. package/dist/collection/components/ic-dialog/ic-dialog.js +13 -4
  148. package/dist/collection/components/ic-dialog/ic-dialog.js.map +1 -1
  149. package/dist/collection/components/ic-empty-state/ic-empty-state.js +4 -2
  150. package/dist/collection/components/ic-empty-state/ic-empty-state.js.map +1 -1
  151. package/dist/collection/components/ic-footer/ic-footer.js +4 -2
  152. package/dist/collection/components/ic-footer/ic-footer.js.map +1 -1
  153. package/dist/collection/components/ic-footer-link/ic-footer-link.js +2 -1
  154. package/dist/collection/components/ic-footer-link/ic-footer-link.js.map +1 -1
  155. package/dist/collection/components/ic-hero/ic-hero.js +4 -2
  156. package/dist/collection/components/ic-hero/ic-hero.js.map +1 -1
  157. package/dist/collection/components/ic-horizontal-scroll/ic-horizontal-scroll.js +4 -2
  158. package/dist/collection/components/ic-horizontal-scroll/ic-horizontal-scroll.js.map +1 -1
  159. package/dist/collection/components/ic-input-component-container/ic-input-component-container.js +2 -1
  160. package/dist/collection/components/ic-input-component-container/ic-input-component-container.js.map +1 -1
  161. package/dist/collection/components/ic-input-validation/ic-input-validation.js +4 -2
  162. package/dist/collection/components/ic-input-validation/ic-input-validation.js.map +1 -1
  163. package/dist/collection/components/ic-link/ic-link.js +6 -3
  164. package/dist/collection/components/ic-link/ic-link.js.map +1 -1
  165. package/dist/collection/components/ic-loading-indicator/ic-loading-indicator.js +6 -3
  166. package/dist/collection/components/ic-loading-indicator/ic-loading-indicator.js.map +1 -1
  167. package/dist/collection/components/ic-menu/ic-menu.css +17 -0
  168. package/dist/collection/components/ic-menu/ic-menu.js +107 -48
  169. package/dist/collection/components/ic-menu/ic-menu.js.map +1 -1
  170. package/dist/collection/components/ic-menu/test/basic/ic-menu.spec.js +13 -2
  171. package/dist/collection/components/ic-menu/test/basic/ic-menu.spec.js.map +1 -1
  172. package/dist/collection/components/ic-menu-item/ic-menu-item.js +4 -2
  173. package/dist/collection/components/ic-menu-item/ic-menu-item.js.map +1 -1
  174. package/dist/collection/components/ic-navigation-button/ic-navigation-button.js +8 -2
  175. package/dist/collection/components/ic-navigation-button/ic-navigation-button.js.map +1 -1
  176. package/dist/collection/components/ic-navigation-group/ic-navigation-group.js +2 -1
  177. package/dist/collection/components/ic-navigation-group/ic-navigation-group.js.map +1 -1
  178. package/dist/collection/components/ic-navigation-item/ic-navigation-item.js +4 -2
  179. package/dist/collection/components/ic-navigation-item/ic-navigation-item.js.map +1 -1
  180. package/dist/collection/components/ic-page-header/ic-page-header.js +2 -1
  181. package/dist/collection/components/ic-page-header/ic-page-header.js.map +1 -1
  182. package/dist/collection/components/ic-pagination/ic-pagination.js +8 -4
  183. package/dist/collection/components/ic-pagination/ic-pagination.js.map +1 -1
  184. package/dist/collection/components/ic-pagination-item/ic-pagination-item.js +4 -2
  185. package/dist/collection/components/ic-pagination-item/ic-pagination-item.js.map +1 -1
  186. package/dist/collection/components/ic-popover-menu/ic-popover-menu.js +6 -3
  187. package/dist/collection/components/ic-popover-menu/ic-popover-menu.js.map +1 -1
  188. package/dist/collection/components/ic-radio-group/ic-radio-group.js +6 -3
  189. package/dist/collection/components/ic-radio-group/ic-radio-group.js.map +1 -1
  190. package/dist/collection/components/ic-radio-option/ic-radio-option.js +8 -4
  191. package/dist/collection/components/ic-radio-option/ic-radio-option.js.map +1 -1
  192. package/dist/collection/components/ic-search-bar/ic-search-bar.js +100 -32
  193. package/dist/collection/components/ic-search-bar/ic-search-bar.js.map +1 -1
  194. package/dist/collection/components/ic-section-container/ic-section-container.js +2 -1
  195. package/dist/collection/components/ic-section-container/ic-section-container.js.map +1 -1
  196. package/dist/collection/components/ic-select/ic-select.js +85 -22
  197. package/dist/collection/components/ic-select/ic-select.js.map +1 -1
  198. package/dist/collection/components/ic-select/test/basic/ic-select.e2e.js +30 -0
  199. package/dist/collection/components/ic-select/test/basic/ic-select.e2e.js.map +1 -1
  200. package/dist/collection/components/ic-select/test/basic/ic-select.spec.js +51 -3
  201. package/dist/collection/components/ic-select/test/basic/ic-select.spec.js.map +1 -1
  202. package/dist/collection/components/ic-skeleton/ic-skeleton.js +2 -1
  203. package/dist/collection/components/ic-skeleton/ic-skeleton.js.map +1 -1
  204. package/dist/collection/components/ic-status-tag/ic-status-tag.js +4 -2
  205. package/dist/collection/components/ic-status-tag/ic-status-tag.js.map +1 -1
  206. package/dist/collection/components/ic-step/ic-step.js +8 -4
  207. package/dist/collection/components/ic-step/ic-step.js.map +1 -1
  208. package/dist/collection/components/ic-stepper/ic-stepper.js +4 -2
  209. package/dist/collection/components/ic-stepper/ic-stepper.js.map +1 -1
  210. package/dist/collection/components/ic-switch/ic-switch.js +4 -2
  211. package/dist/collection/components/ic-switch/ic-switch.js.map +1 -1
  212. package/dist/collection/components/ic-tab/ic-tab.js +10 -5
  213. package/dist/collection/components/ic-tab/ic-tab.js.map +1 -1
  214. package/dist/collection/components/ic-tab-context/ic-tab-context.js +10 -5
  215. package/dist/collection/components/ic-tab-context/ic-tab-context.js.map +1 -1
  216. package/dist/collection/components/ic-tab-group/ic-tab-group.js +2 -1
  217. package/dist/collection/components/ic-tab-group/ic-tab-group.js.map +1 -1
  218. package/dist/collection/components/ic-tab-panel/ic-tab-panel.js +4 -2
  219. package/dist/collection/components/ic-tab-panel/ic-tab-panel.js.map +1 -1
  220. package/dist/collection/components/ic-text-field/ic-text-field.js +26 -13
  221. package/dist/collection/components/ic-text-field/ic-text-field.js.map +1 -1
  222. package/dist/collection/components/ic-theme/ic-theme.js +2 -1
  223. package/dist/collection/components/ic-theme/ic-theme.js.map +1 -1
  224. package/dist/collection/components/ic-toast/ic-toast.js +8 -4
  225. package/dist/collection/components/ic-toast/ic-toast.js.map +1 -1
  226. package/dist/collection/components/ic-toast-region/ic-toast-region.js +4 -2
  227. package/dist/collection/components/ic-toast-region/ic-toast-region.js.map +1 -1
  228. package/dist/collection/components/ic-tooltip/ic-tooltip.js +4 -2
  229. package/dist/collection/components/ic-tooltip/ic-tooltip.js.map +1 -1
  230. package/dist/collection/components/ic-top-navigation/ic-top-navigation.js +2 -1
  231. package/dist/collection/components/ic-top-navigation/ic-top-navigation.js.map +1 -1
  232. package/dist/collection/components/ic-typography/ic-typography.js +2 -1
  233. package/dist/collection/components/ic-typography/ic-typography.js.map +1 -1
  234. package/dist/collection/utils/helpers.js +25 -8
  235. package/dist/collection/utils/helpers.js.map +1 -1
  236. package/dist/collection/utils/types.js.map +1 -1
  237. package/dist/components/helpers.js +25 -8
  238. package/dist/components/helpers.js.map +1 -1
  239. package/dist/components/ic-alert2.js.map +1 -1
  240. package/dist/components/ic-back-to-top.js.map +1 -1
  241. package/dist/components/ic-breadcrumb-group.js.map +1 -1
  242. package/dist/components/ic-breadcrumb2.js.map +1 -1
  243. package/dist/components/ic-button2.js +26 -5
  244. package/dist/components/ic-button2.js.map +1 -1
  245. package/dist/components/ic-card.js.map +1 -1
  246. package/dist/components/ic-checkbox-group.js.map +1 -1
  247. package/dist/components/ic-checkbox.js.map +1 -1
  248. package/dist/components/ic-chip.js.map +1 -1
  249. package/dist/components/ic-classification-banner.js.map +1 -1
  250. package/dist/components/ic-data-entity.js.map +1 -1
  251. package/dist/components/ic-data-row.js.map +1 -1
  252. package/dist/components/ic-dialog.js.map +1 -1
  253. package/dist/components/ic-divider2.js.map +1 -1
  254. package/dist/components/ic-empty-state.js.map +1 -1
  255. package/dist/components/ic-footer-link-group.js.map +1 -1
  256. package/dist/components/ic-footer-link.js.map +1 -1
  257. package/dist/components/ic-footer.js.map +1 -1
  258. package/dist/components/ic-hero.js.map +1 -1
  259. package/dist/components/ic-horizontal-scroll2.js.map +1 -1
  260. package/dist/components/ic-input-component-container2.js.map +1 -1
  261. package/dist/components/ic-input-container2.js.map +1 -1
  262. package/dist/components/ic-input-label2.js.map +1 -1
  263. package/dist/components/ic-input-validation2.js.map +1 -1
  264. package/dist/components/ic-link2.js.map +1 -1
  265. package/dist/components/ic-loading-indicator2.js.map +1 -1
  266. package/dist/components/ic-menu-group.js.map +1 -1
  267. package/dist/components/ic-menu-item2.js.map +1 -1
  268. package/dist/components/ic-menu2.js +40 -32
  269. package/dist/components/ic-menu2.js.map +1 -1
  270. package/dist/components/ic-navigation-button.js +4 -0
  271. package/dist/components/ic-navigation-button.js.map +1 -1
  272. package/dist/components/ic-navigation-group.js.map +1 -1
  273. package/dist/components/ic-navigation-item.js.map +1 -1
  274. package/dist/components/ic-navigation-menu2.js.map +1 -1
  275. package/dist/components/ic-page-header.js.map +1 -1
  276. package/dist/components/ic-pagination-item2.js.map +1 -1
  277. package/dist/components/ic-pagination.js.map +1 -1
  278. package/dist/components/ic-popover-menu.js.map +1 -1
  279. package/dist/components/ic-radio-group.js.map +1 -1
  280. package/dist/components/ic-radio-option.js.map +1 -1
  281. package/dist/components/ic-search-bar.js +34 -16
  282. package/dist/components/ic-search-bar.js.map +1 -1
  283. package/dist/components/ic-section-container2.js.map +1 -1
  284. package/dist/components/ic-select.js +69 -14
  285. package/dist/components/ic-select.js.map +1 -1
  286. package/dist/components/ic-side-navigation.js.map +1 -1
  287. package/dist/components/ic-skeleton.js.map +1 -1
  288. package/dist/components/ic-status-tag.js.map +1 -1
  289. package/dist/components/ic-step.js.map +1 -1
  290. package/dist/components/ic-stepper.js.map +1 -1
  291. package/dist/components/ic-switch.js.map +1 -1
  292. package/dist/components/ic-tab-context.js.map +1 -1
  293. package/dist/components/ic-tab-group.js.map +1 -1
  294. package/dist/components/ic-tab-panel.js.map +1 -1
  295. package/dist/components/ic-tab.js.map +1 -1
  296. package/dist/components/ic-text-field2.js.map +1 -1
  297. package/dist/components/ic-theme.js.map +1 -1
  298. package/dist/components/ic-toast-region.js.map +1 -1
  299. package/dist/components/ic-toast.js.map +1 -1
  300. package/dist/components/ic-tooltip2.js.map +1 -1
  301. package/dist/components/ic-top-navigation.js.map +1 -1
  302. package/dist/components/ic-typography2.js.map +1 -1
  303. package/dist/components/index.d.ts +6 -0
  304. package/dist/components/index.js +1 -1
  305. package/dist/components/types.js.map +1 -1
  306. package/dist/core/core.css +9 -6
  307. package/dist/core/core.esm.js +1 -1
  308. package/dist/core/core.esm.js.map +1 -1
  309. package/dist/core/{p-adf65f4a.entry.js → p-0a30f1e5.entry.js} +2 -2
  310. package/dist/core/p-0a30f1e5.entry.js.map +1 -0
  311. package/dist/core/{p-fbd3c432.entry.js → p-0dcc76b1.entry.js} +2 -2
  312. package/dist/core/p-0dcc76b1.entry.js.map +1 -0
  313. package/dist/core/{p-bbdd9770.entry.js → p-101bce17.entry.js} +2 -2
  314. package/dist/core/p-101bce17.entry.js.map +1 -0
  315. package/dist/core/{p-e2fdb944.entry.js → p-16e8bb5a.entry.js} +2 -2
  316. package/dist/core/p-16e8bb5a.entry.js.map +1 -0
  317. package/dist/core/p-18068237.js +3 -0
  318. package/dist/core/p-18068237.js.map +1 -0
  319. package/dist/core/p-1c54269e.entry.js +2 -0
  320. package/dist/core/p-1c54269e.entry.js.map +1 -0
  321. package/dist/core/{p-389c3913.entry.js → p-27897d29.entry.js} +2 -2
  322. package/dist/core/p-27897d29.entry.js.map +1 -0
  323. package/dist/core/{p-e14bc195.entry.js → p-27bf4783.entry.js} +2 -2
  324. package/dist/core/p-27bf4783.entry.js.map +1 -0
  325. package/dist/core/{p-ab4919d6.entry.js → p-3297713b.entry.js} +2 -2
  326. package/dist/core/p-3297713b.entry.js.map +1 -0
  327. package/dist/core/{p-06321d19.js → p-3b185c32.js} +1 -1
  328. package/dist/core/{p-919059e8.entry.js → p-3fc638fc.entry.js} +2 -2
  329. package/dist/core/p-3fc638fc.entry.js.map +1 -0
  330. package/dist/core/{p-8d4f7027.js → p-426ec638.js} +1 -1
  331. package/dist/core/{p-20fafec4.entry.js → p-433cfd47.entry.js} +2 -2
  332. package/dist/core/p-433cfd47.entry.js.map +1 -0
  333. package/dist/core/{p-da3bd896.entry.js → p-455bfed1.entry.js} +2 -2
  334. package/dist/core/p-455bfed1.entry.js.map +1 -0
  335. package/dist/core/{p-07877eb8.entry.js → p-4c4261e7.entry.js} +2 -2
  336. package/dist/core/p-4c4261e7.entry.js.map +1 -0
  337. package/dist/core/{p-75ac2fbf.entry.js → p-4f7c20b3.entry.js} +2 -2
  338. package/dist/core/p-4f7c20b3.entry.js.map +1 -0
  339. package/dist/core/{p-5e3a09d7.entry.js → p-521c8f40.entry.js} +2 -2
  340. package/dist/core/p-521c8f40.entry.js.map +1 -0
  341. package/dist/core/{p-041604fc.entry.js → p-5b8be53f.entry.js} +2 -2
  342. package/dist/core/p-5b8be53f.entry.js.map +1 -0
  343. package/dist/core/{p-14bea6c0.entry.js → p-5fcbcc3f.entry.js} +2 -2
  344. package/dist/core/p-5fcbcc3f.entry.js.map +1 -0
  345. package/dist/core/{p-3adb1167.entry.js → p-607e7bf2.entry.js} +2 -2
  346. package/dist/core/p-607e7bf2.entry.js.map +1 -0
  347. package/dist/core/{p-6f57b13c.js → p-613aa265.js} +1 -1
  348. package/dist/core/p-613aa265.js.map +1 -0
  349. package/dist/core/{p-c4b81d32.entry.js → p-62499150.entry.js} +2 -2
  350. package/dist/core/p-62499150.entry.js.map +1 -0
  351. package/dist/core/{p-5e685037.entry.js → p-630ae754.entry.js} +2 -2
  352. package/dist/core/p-630ae754.entry.js.map +1 -0
  353. package/dist/core/{p-24b88371.entry.js → p-65df7222.entry.js} +2 -2
  354. package/dist/core/p-65df7222.entry.js.map +1 -0
  355. package/dist/core/{p-8ca80000.entry.js → p-6781620e.entry.js} +2 -2
  356. package/dist/core/p-6781620e.entry.js.map +1 -0
  357. package/dist/core/p-67c18f72.entry.js +2 -0
  358. package/dist/core/p-67c18f72.entry.js.map +1 -0
  359. package/dist/core/{p-7c0dcd00.js → p-68a5aaff.js} +1 -1
  360. package/dist/core/p-68a5aaff.js.map +1 -0
  361. package/dist/core/{p-95992c98.entry.js → p-68fda79a.entry.js} +2 -2
  362. package/dist/core/p-68fda79a.entry.js.map +1 -0
  363. package/dist/core/{p-da5fc036.entry.js → p-7194c255.entry.js} +2 -2
  364. package/dist/core/p-7194c255.entry.js.map +1 -0
  365. package/dist/core/p-77266738.entry.js +2 -0
  366. package/dist/core/p-77266738.entry.js.map +1 -0
  367. package/dist/core/{p-516fd246.entry.js → p-7be2b1fd.entry.js} +2 -2
  368. package/dist/core/p-7be2b1fd.entry.js.map +1 -0
  369. package/dist/core/{p-b5d084c2.entry.js → p-831b0f3f.entry.js} +2 -2
  370. package/dist/core/p-831b0f3f.entry.js.map +1 -0
  371. package/dist/core/{p-2ae7687a.entry.js → p-83e535de.entry.js} +2 -2
  372. package/dist/core/p-83e535de.entry.js.map +1 -0
  373. package/dist/core/{p-441e7d98.entry.js → p-85dd5e5b.entry.js} +2 -2
  374. package/dist/core/p-85dd5e5b.entry.js.map +1 -0
  375. package/dist/core/{p-2f5a9d91.entry.js → p-87149cbd.entry.js} +2 -2
  376. package/dist/core/p-87149cbd.entry.js.map +1 -0
  377. package/dist/core/{p-43b529a5.entry.js → p-8e6169e0.entry.js} +2 -2
  378. package/dist/core/p-8e6169e0.entry.js.map +1 -0
  379. package/dist/core/{p-1b1dbb53.entry.js → p-9248228e.entry.js} +2 -2
  380. package/dist/core/p-9248228e.entry.js.map +1 -0
  381. package/dist/core/{p-8acd7207.entry.js → p-932a67ca.entry.js} +2 -2
  382. package/dist/core/p-932a67ca.entry.js.map +1 -0
  383. package/dist/core/{p-cfb87422.entry.js → p-937ecd5b.entry.js} +2 -2
  384. package/dist/core/p-937ecd5b.entry.js.map +1 -0
  385. package/dist/core/{p-9bde930d.entry.js → p-94903a21.entry.js} +2 -2
  386. package/dist/core/p-94903a21.entry.js.map +1 -0
  387. package/dist/core/{p-4dc6a83d.entry.js → p-96022913.entry.js} +2 -2
  388. package/dist/core/p-96022913.entry.js.map +1 -0
  389. package/dist/core/{p-c3da58eb.entry.js → p-9650e00e.entry.js} +2 -2
  390. package/dist/core/p-9650e00e.entry.js.map +1 -0
  391. package/dist/core/{p-50019c47.entry.js → p-99741b0f.entry.js} +2 -2
  392. package/dist/core/p-99741b0f.entry.js.map +1 -0
  393. package/dist/core/{p-e328bd2d.entry.js → p-a0a02a13.entry.js} +2 -2
  394. package/dist/core/p-a0a02a13.entry.js.map +1 -0
  395. package/dist/core/{p-d2994a71.entry.js → p-a421d3a1.entry.js} +2 -2
  396. package/dist/core/p-a421d3a1.entry.js.map +1 -0
  397. package/dist/core/p-a6f48272.entry.js +2 -0
  398. package/dist/core/p-a6f48272.entry.js.map +1 -0
  399. package/dist/core/{p-e9c864ac.entry.js → p-b0b1de0e.entry.js} +2 -2
  400. package/dist/core/p-b0b1de0e.entry.js.map +1 -0
  401. package/dist/core/{p-fb86da80.entry.js → p-c1859843.entry.js} +2 -2
  402. package/dist/core/p-c1859843.entry.js.map +1 -0
  403. package/dist/core/{p-8c7f4343.js → p-c2e091d7.js} +1 -1
  404. package/dist/core/{p-92868735.entry.js → p-c31e6dbb.entry.js} +2 -2
  405. package/dist/core/p-c31e6dbb.entry.js.map +1 -0
  406. package/dist/core/{p-96bcd466.entry.js → p-c390fbad.entry.js} +2 -2
  407. package/dist/core/p-c390fbad.entry.js.map +1 -0
  408. package/dist/core/{p-c2fc2b77.entry.js → p-cb2c18de.entry.js} +2 -2
  409. package/dist/core/p-cb2c18de.entry.js.map +1 -0
  410. package/dist/core/{p-6bad30aa.entry.js → p-d16100e8.entry.js} +2 -2
  411. package/dist/core/p-d16100e8.entry.js.map +1 -0
  412. package/dist/core/{p-07601b81.entry.js → p-d20917ae.entry.js} +2 -2
  413. package/dist/core/p-d20917ae.entry.js.map +1 -0
  414. package/dist/core/{p-a29fe0c6.entry.js → p-d65ace31.entry.js} +2 -2
  415. package/dist/core/p-d65ace31.entry.js.map +1 -0
  416. package/dist/core/{p-d592006b.entry.js → p-d78c90fe.entry.js} +2 -2
  417. package/dist/core/p-d78c90fe.entry.js.map +1 -0
  418. package/dist/core/{p-4fa9c6eb.entry.js → p-e2d0039d.entry.js} +2 -2
  419. package/dist/core/p-e2d0039d.entry.js.map +1 -0
  420. package/dist/core/{p-98d488aa.entry.js → p-e3923b67.entry.js} +2 -2
  421. package/dist/core/p-e3923b67.entry.js.map +1 -0
  422. package/dist/core/{p-1ac44a4e.entry.js → p-ebd60291.entry.js} +2 -2
  423. package/dist/core/p-ebd60291.entry.js.map +1 -0
  424. package/dist/core/p-ebe76390.js +2 -0
  425. package/dist/core/p-ebe76390.js.map +1 -0
  426. package/dist/core/{p-f2c6a143.js → p-f074ef5b.js} +1 -1
  427. package/dist/core/{p-93ee130d.entry.js → p-fedcfea3.entry.js} +2 -2
  428. package/dist/core/p-fedcfea3.entry.js.map +1 -0
  429. package/dist/esm/{OpenInNew-67a881e0.js → OpenInNew-cdeed5ce.js} +1 -1
  430. package/dist/esm/OpenInNew-cdeed5ce.js.map +1 -0
  431. package/dist/esm/{check-icon-abb210ec.js → check-icon-4a9f8371.js} +1 -1
  432. package/dist/esm/check-icon-4a9f8371.js.map +1 -0
  433. package/dist/esm/{chevron-icon-7927f709.js → chevron-icon-589e3b46.js} +1 -1
  434. package/dist/esm/chevron-icon-589e3b46.js.map +1 -0
  435. package/dist/esm/{close-icon-2ce5d375.js → close-icon-539ec8d1.js} +1 -1
  436. package/dist/esm/close-icon-539ec8d1.js.map +1 -0
  437. package/dist/esm/core.js +4 -7
  438. package/dist/esm/core.js.map +1 -1
  439. package/dist/esm/{helpers-d7d5bd08.js → helpers-b0e80358.js} +27 -10
  440. package/dist/esm/helpers-b0e80358.js.map +1 -0
  441. package/dist/esm/ic-alert.entry.js +4 -4
  442. package/dist/esm/ic-alert.entry.js.map +1 -1
  443. package/dist/esm/ic-back-to-top.entry.js +3 -3
  444. package/dist/esm/ic-back-to-top.entry.js.map +1 -1
  445. package/dist/esm/ic-breadcrumb-group.entry.js +3 -3
  446. package/dist/esm/ic-breadcrumb-group.entry.js.map +1 -1
  447. package/dist/esm/ic-breadcrumb.entry.js +4 -4
  448. package/dist/esm/ic-breadcrumb.entry.js.map +1 -1
  449. package/dist/esm/ic-button_3.entry.js +30 -9
  450. package/dist/esm/ic-button_3.entry.js.map +1 -1
  451. package/dist/esm/ic-card.entry.js +4 -4
  452. package/dist/esm/ic-card.entry.js.map +1 -1
  453. package/dist/esm/ic-checkbox-group.entry.js +3 -3
  454. package/dist/esm/ic-checkbox-group.entry.js.map +1 -1
  455. package/dist/esm/ic-checkbox.entry.js +3 -3
  456. package/dist/esm/ic-checkbox.entry.js.map +1 -1
  457. package/dist/esm/ic-chip.entry.js +3 -3
  458. package/dist/esm/ic-chip.entry.js.map +1 -1
  459. package/dist/esm/ic-classification-banner.entry.js +1 -1
  460. package/dist/esm/ic-classification-banner.entry.js.map +1 -1
  461. package/dist/esm/ic-data-entity.entry.js +1 -1
  462. package/dist/esm/ic-data-entity.entry.js.map +1 -1
  463. package/dist/esm/ic-data-row.entry.js +3 -3
  464. package/dist/esm/ic-data-row.entry.js.map +1 -1
  465. package/dist/esm/ic-dialog.entry.js +4 -4
  466. package/dist/esm/ic-dialog.entry.js.map +1 -1
  467. package/dist/esm/ic-divider.entry.js +3 -3
  468. package/dist/esm/ic-divider.entry.js.map +1 -1
  469. package/dist/esm/ic-empty-state.entry.js +3 -3
  470. package/dist/esm/ic-empty-state.entry.js.map +1 -1
  471. package/dist/esm/ic-footer-link-group.entry.js +3 -3
  472. package/dist/esm/ic-footer-link-group.entry.js.map +1 -1
  473. package/dist/esm/ic-footer-link.entry.js +4 -4
  474. package/dist/esm/ic-footer-link.entry.js.map +1 -1
  475. package/dist/esm/ic-footer.entry.js +3 -3
  476. package/dist/esm/ic-footer.entry.js.map +1 -1
  477. package/dist/esm/ic-hero.entry.js +3 -3
  478. package/dist/esm/ic-hero.entry.js.map +1 -1
  479. package/dist/esm/ic-horizontal-scroll.entry.js +3 -3
  480. package/dist/esm/ic-horizontal-scroll.entry.js.map +1 -1
  481. package/dist/esm/ic-input-component-container_3.entry.js +43 -37
  482. package/dist/esm/ic-input-component-container_3.entry.js.map +1 -1
  483. package/dist/esm/ic-input-label_2.entry.js +3 -3
  484. package/dist/esm/ic-input-label_2.entry.js.map +1 -1
  485. package/dist/esm/ic-link.entry.js +4 -4
  486. package/dist/esm/ic-link.entry.js.map +1 -1
  487. package/dist/esm/ic-menu-group.entry.js +1 -1
  488. package/dist/esm/ic-menu-group.entry.js.map +1 -1
  489. package/dist/esm/ic-menu-item.entry.js +5 -5
  490. package/dist/esm/ic-menu-item.entry.js.map +1 -1
  491. package/dist/esm/ic-navigation-button.entry.js +7 -3
  492. package/dist/esm/ic-navigation-button.entry.js.map +1 -1
  493. package/dist/esm/ic-navigation-group.entry.js +4 -4
  494. package/dist/esm/ic-navigation-group.entry.js.map +1 -1
  495. package/dist/esm/ic-navigation-item.entry.js +5 -5
  496. package/dist/esm/ic-navigation-item.entry.js.map +1 -1
  497. package/dist/esm/ic-navigation-menu.entry.js +3 -3
  498. package/dist/esm/ic-navigation-menu.entry.js.map +1 -1
  499. package/dist/esm/ic-page-header.entry.js +3 -3
  500. package/dist/esm/ic-page-header.entry.js.map +1 -1
  501. package/dist/esm/ic-pagination-item.entry.js +3 -3
  502. package/dist/esm/ic-pagination-item.entry.js.map +1 -1
  503. package/dist/esm/ic-pagination.entry.js +3 -3
  504. package/dist/esm/ic-pagination.entry.js.map +1 -1
  505. package/dist/esm/ic-popover-menu.entry.js +4 -4
  506. package/dist/esm/ic-popover-menu.entry.js.map +1 -1
  507. package/dist/esm/ic-radio-group.entry.js +3 -3
  508. package/dist/esm/ic-radio-group.entry.js.map +1 -1
  509. package/dist/esm/ic-radio-option.entry.js +3 -3
  510. package/dist/esm/ic-radio-option.entry.js.map +1 -1
  511. package/dist/esm/ic-search-bar.entry.js +35 -19
  512. package/dist/esm/ic-search-bar.entry.js.map +1 -1
  513. package/dist/esm/ic-section-container.entry.js +1 -1
  514. package/dist/esm/ic-section-container.entry.js.map +1 -1
  515. package/dist/esm/ic-select.entry.js +71 -17
  516. package/dist/esm/ic-select.entry.js.map +1 -1
  517. package/dist/esm/ic-side-navigation.entry.js +5 -5
  518. package/dist/esm/ic-side-navigation.entry.js.map +1 -1
  519. package/dist/esm/ic-skeleton.entry.js +1 -1
  520. package/dist/esm/ic-skeleton.entry.js.map +1 -1
  521. package/dist/esm/ic-status-tag.entry.js +3 -3
  522. package/dist/esm/ic-status-tag.entry.js.map +1 -1
  523. package/dist/esm/ic-step.entry.js +2 -2
  524. package/dist/esm/ic-step.entry.js.map +1 -1
  525. package/dist/esm/ic-stepper.entry.js +3 -3
  526. package/dist/esm/ic-stepper.entry.js.map +1 -1
  527. package/dist/esm/ic-switch.entry.js +3 -3
  528. package/dist/esm/ic-switch.entry.js.map +1 -1
  529. package/dist/esm/ic-tab-context.entry.js +2 -2
  530. package/dist/esm/ic-tab-context.entry.js.map +1 -1
  531. package/dist/esm/ic-tab-group.entry.js +3 -3
  532. package/dist/esm/ic-tab-group.entry.js.map +1 -1
  533. package/dist/esm/ic-tab-panel.entry.js +2 -2
  534. package/dist/esm/ic-tab-panel.entry.js.map +1 -1
  535. package/dist/esm/ic-tab.entry.js +3 -3
  536. package/dist/esm/ic-tab.entry.js.map +1 -1
  537. package/dist/esm/ic-text-field.entry.js +3 -3
  538. package/dist/esm/ic-text-field.entry.js.map +1 -1
  539. package/dist/esm/ic-theme.entry.js +3 -3
  540. package/dist/esm/ic-theme.entry.js.map +1 -1
  541. package/dist/esm/ic-toast-region.entry.js +1 -1
  542. package/dist/esm/ic-toast-region.entry.js.map +1 -1
  543. package/dist/esm/ic-toast.entry.js +4 -4
  544. package/dist/esm/ic-toast.entry.js.map +1 -1
  545. package/dist/esm/ic-top-navigation.entry.js +3 -3
  546. package/dist/esm/ic-top-navigation.entry.js.map +1 -1
  547. package/dist/esm/ic-typography.entry.js +3 -3
  548. package/dist/esm/ic-typography.entry.js.map +1 -1
  549. package/dist/esm/{index-fd30b77e.js → index-14c9f375.js} +98 -26
  550. package/dist/esm/index-14c9f375.js.map +1 -0
  551. package/dist/esm/loader.js +4 -13
  552. package/dist/esm/loader.js.map +1 -1
  553. package/dist/esm/{popper-15e448b4.js → popper-0fbeff6d.js} +1 -1
  554. package/dist/esm/popper-0fbeff6d.js.map +1 -0
  555. package/dist/esm/{types-dd515332.js → types-b2398b37.js} +1 -1
  556. package/dist/esm/types-b2398b37.js.map +1 -0
  557. package/dist/types/components/ic-breadcrumb/ic-breadcrumb.d.ts +3 -3
  558. package/dist/types/components/ic-button/ic-button.d.ts +4 -0
  559. package/dist/types/components/ic-dialog/ic-dialog.d.ts +5 -5
  560. package/dist/types/components/ic-menu/ic-menu.d.ts +8 -0
  561. package/dist/types/components/ic-navigation-button/ic-navigation-button.d.ts +1 -0
  562. package/dist/types/components/ic-search-bar/ic-search-bar.d.ts +8 -0
  563. package/dist/types/components/ic-select/ic-select.d.ts +14 -0
  564. package/dist/types/components.d.ts +32 -0
  565. package/dist/types/stencil-public-runtime.d.ts +17 -5
  566. package/dist/types/utils/helpers.d.ts +2 -2
  567. package/dist/types/utils/types.d.ts +11 -2
  568. package/hydrate/index.d.ts +6 -6
  569. package/hydrate/index.js +310 -169
  570. package/loader/index.d.ts +1 -1
  571. package/package.json +3 -3
  572. package/dist/cjs/OpenInNew-f9958725.js.map +0 -1
  573. package/dist/cjs/check-icon-b2f60716.js.map +0 -1
  574. package/dist/cjs/chevron-icon-2bb3a907.js.map +0 -1
  575. package/dist/cjs/close-icon-04be4880.js.map +0 -1
  576. package/dist/cjs/helpers-3811d14b.js.map +0 -1
  577. package/dist/cjs/index-2a0c6769.js.map +0 -1
  578. package/dist/cjs/popper-d7adcfc6.js.map +0 -1
  579. package/dist/cjs/types-3eb02246.js.map +0 -1
  580. package/dist/core/p-041604fc.entry.js.map +0 -1
  581. package/dist/core/p-07601b81.entry.js.map +0 -1
  582. package/dist/core/p-07877eb8.entry.js.map +0 -1
  583. package/dist/core/p-103c761f.entry.js +0 -2
  584. package/dist/core/p-103c761f.entry.js.map +0 -1
  585. package/dist/core/p-14bea6c0.entry.js.map +0 -1
  586. package/dist/core/p-1ac44a4e.entry.js.map +0 -1
  587. package/dist/core/p-1b1dbb53.entry.js.map +0 -1
  588. package/dist/core/p-20fafec4.entry.js.map +0 -1
  589. package/dist/core/p-24b88371.entry.js.map +0 -1
  590. package/dist/core/p-2ae7687a.entry.js.map +0 -1
  591. package/dist/core/p-2f5a9d91.entry.js.map +0 -1
  592. package/dist/core/p-389c3913.entry.js.map +0 -1
  593. package/dist/core/p-3adb1167.entry.js.map +0 -1
  594. package/dist/core/p-43b529a5.entry.js.map +0 -1
  595. package/dist/core/p-441e7d98.entry.js.map +0 -1
  596. package/dist/core/p-4dc6a83d.entry.js.map +0 -1
  597. package/dist/core/p-4fa9c6eb.entry.js.map +0 -1
  598. package/dist/core/p-50019c47.entry.js.map +0 -1
  599. package/dist/core/p-516fd246.entry.js.map +0 -1
  600. package/dist/core/p-5e3a09d7.entry.js.map +0 -1
  601. package/dist/core/p-5e685037.entry.js.map +0 -1
  602. package/dist/core/p-69920d86.js +0 -3
  603. package/dist/core/p-69920d86.js.map +0 -1
  604. package/dist/core/p-69c1f172.entry.js +0 -2
  605. package/dist/core/p-69c1f172.entry.js.map +0 -1
  606. package/dist/core/p-6bad30aa.entry.js.map +0 -1
  607. package/dist/core/p-6f57b13c.js.map +0 -1
  608. package/dist/core/p-736489c6.entry.js +0 -2
  609. package/dist/core/p-736489c6.entry.js.map +0 -1
  610. package/dist/core/p-75ac2fbf.entry.js.map +0 -1
  611. package/dist/core/p-7c0dcd00.js.map +0 -1
  612. package/dist/core/p-8acd7207.entry.js.map +0 -1
  613. package/dist/core/p-8ca80000.entry.js.map +0 -1
  614. package/dist/core/p-919059e8.entry.js.map +0 -1
  615. package/dist/core/p-92868735.entry.js.map +0 -1
  616. package/dist/core/p-93ee130d.entry.js.map +0 -1
  617. package/dist/core/p-95992c98.entry.js.map +0 -1
  618. package/dist/core/p-96bcd466.entry.js.map +0 -1
  619. package/dist/core/p-98d488aa.entry.js.map +0 -1
  620. package/dist/core/p-9bde930d.entry.js.map +0 -1
  621. package/dist/core/p-9e896463.entry.js +0 -2
  622. package/dist/core/p-9e896463.entry.js.map +0 -1
  623. package/dist/core/p-a29fe0c6.entry.js.map +0 -1
  624. package/dist/core/p-ab4919d6.entry.js.map +0 -1
  625. package/dist/core/p-adf65f4a.entry.js.map +0 -1
  626. package/dist/core/p-b5d084c2.entry.js.map +0 -1
  627. package/dist/core/p-bbdd9770.entry.js.map +0 -1
  628. package/dist/core/p-c2fc2b77.entry.js.map +0 -1
  629. package/dist/core/p-c3da58eb.entry.js.map +0 -1
  630. package/dist/core/p-c4b81d32.entry.js.map +0 -1
  631. package/dist/core/p-cfb87422.entry.js.map +0 -1
  632. package/dist/core/p-d2994a71.entry.js.map +0 -1
  633. package/dist/core/p-d592006b.entry.js.map +0 -1
  634. package/dist/core/p-da3bd896.entry.js.map +0 -1
  635. package/dist/core/p-da5fc036.entry.js.map +0 -1
  636. package/dist/core/p-dd980be4.js +0 -2
  637. package/dist/core/p-dd980be4.js.map +0 -1
  638. package/dist/core/p-e14bc195.entry.js.map +0 -1
  639. package/dist/core/p-e2fdb944.entry.js.map +0 -1
  640. package/dist/core/p-e328bd2d.entry.js.map +0 -1
  641. package/dist/core/p-e9c864ac.entry.js.map +0 -1
  642. package/dist/core/p-fb86da80.entry.js.map +0 -1
  643. package/dist/core/p-fbd3c432.entry.js.map +0 -1
  644. package/dist/esm/OpenInNew-67a881e0.js.map +0 -1
  645. package/dist/esm/check-icon-abb210ec.js.map +0 -1
  646. package/dist/esm/chevron-icon-7927f709.js.map +0 -1
  647. package/dist/esm/close-icon-2ce5d375.js.map +0 -1
  648. package/dist/esm/helpers-d7d5bd08.js.map +0 -1
  649. package/dist/esm/index-fd30b77e.js.map +0 -1
  650. package/dist/esm/polyfills/css-shim.js +0 -1
  651. package/dist/esm/popper-15e448b4.js.map +0 -1
  652. package/dist/esm/types-dd515332.js.map +0 -1
  653. /package/dist/core/{p-06321d19.js.map → p-3b185c32.js.map} +0 -0
  654. /package/dist/core/{p-8c7f4343.js.map → p-426ec638.js.map} +0 -0
  655. /package/dist/core/{p-8d4f7027.js.map → p-c2e091d7.js.map} +0 -0
  656. /package/dist/core/{p-f2c6a143.js.map → p-f074ef5b.js.map} +0 -0
@@ -1,2 +1,2 @@
1
- import{r as t,c as e,h as i,H as s,g as a}from"./p-69920d86.js";import{a as n}from"./p-6f57b13c.js";import{L as o,e as r,n as l,d as h,r as c,a as d,j as u,f as p,i as m,B as b,p as f}from"./p-dd980be4.js";const y='/*! 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}:host(.fullwidth){width:100%}::-moz-placeholder{color:var(--ic-color-tertiary-text);opacity:1}::placeholder{color:var(--ic-color-tertiary-text);opacity:1}input,textarea{border:0;border-radius:var(--ic-border-radius);background-color:var(--ic-architectural-white);line-height:1.5rem;letter-spacing:0.005rem;width:100%;padding-right:var(--ic-space-xs);padding-left:var(--ic-space-xs)}textarea{min-height:var(--ic-space-lg);resize:vertical;padding-top:0.375rem}input:focus,textarea:focus{border:0;outline:0}input:disabled,textarea:disabled{color:var(--ic-architectural-200)}input.readonly,textarea.readonly{color:var(--ic-color-primary-text)}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}input[type="number"]{-moz-appearance:textfield}textarea.no-resize{resize:none}.maxlengthtext{color:var(--ic-color-secondary-text)}.no-left-pad{padding-left:0}::slotted([slot="icon"]){fill:var(--ic-color-tertiary-text)}.has-value ::slotted([slot="icon"]){fill:var(--ic-color-primary-text)}.charcount{margin-right:calc(-1 * var(--ic-space-xxxs))}input[type="search"]::-webkit-search-cancel-button,input[type="search"]::-webkit-search-decoration,input[type="search"]::-webkit-search-results-button,input[type="search"]::-webkit-search-results-decoration{display:none}input[type="search"].truncate-value{width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}@media (forced-colors: active){input.readonly,textarea.readonly{color:canvastext}.has-value ::slotted([slot="icon"]){fill:currentcolor}}';let x=0;const g=class{constructor(i){t(this,i);this.getValidationText=e(this,"getValidationText",7);this.icBlur=e(this,"icBlur",7);this.icChange=e(this,"icChange",7);this.icFocus=e(this,"icFocus",7);this.icInput=e(this,"icInput",7);this.icKeydown=e(this,"icKeydown",7);this.inheritedAttributes={};this.showLeftIcon=this.hasLeftIconSlot();this.onInput=t=>{this.value=t.target.value;this.icInput.emit({value:this.value})};this.onBlur=t=>{const e=t.target.value;this.icBlur.emit({value:e})};this.onFocus=t=>{const e=t.target.value;this.icFocus.emit({value:e})};this.isTextArea=()=>this.rows>1;this.getInlineValidationText=()=>{this.getValidationText.emit({value:this.validationText})};this.hasStatus=t=>t!==""&&!this.disabled;this.showStatusText=t=>this.hasStatus(t)&&!(t==n.Success&&this.validationInline)&&!this.validationInlineInternal;this.handleFormReset=()=>{this.value=this.initialValue};this.numChars=0;this.maxLengthExceeded=false;this.maxValueExceeded=false;this.minValueUnattained=false;this.ariaActiveDescendant=undefined;this.ariaAutocomplete=undefined;this.ariaExpanded=undefined;this.ariaOwns=undefined;this.autocapitalize="off";this.autocomplete="off";this.autocorrect="off";this.autoFocus=false;this.disabled=false;this.fullWidth=false;this.helperText="";this.hideLabel=false;this.hiddenInput=true;this.inputId=`ic-text-field-input-${x++}`;this.inputmode="text";this.label=undefined;this.max=undefined;this.maxLength=0;this.min=undefined;this.name=this.inputId;this.placeholder="";this.readonly=false;this.required=false;this.resize=false;this.role=undefined;this.rows=1;this.small=false;this.spellcheck=false;this.truncateValue=undefined;this.type="text";this.validationInline=false;this.validationInlineInternal=false;this.validationStatus="";this.validationText="";this.debounce=0;this.value="";this.initialValue=this.value}debounceChanged(){this.icChange=o(this.icChange,this.debounce)}watchValueHandler(t){if(this.inputEl&&this.inputEl.value!==t){this.inputEl.value=t}this.numChars=t.length;if(this.type==="number"){if(t&&Number(t)<Number(this.min)){this.minValueUnattained=true}else{this.minValueUnattained=false}if(Number(t)>Number(this.max)){this.maxValueExceeded=true}else{this.maxValueExceeded=false}}if(this.maxLength>0){if(t.length>this.maxLength){this.maxLengthExceeded=true}else{this.maxLengthExceeded=false}}this.icChange.emit({value:t})}connectedCallback(){this.debounceChanged()}disconnectedCallback(){r(this.el,this.handleFormReset)}componentWillLoad(){this.watchValueHandler(this.value);this.inheritedAttributes=l(this.el,[...f,"title","aria-autocomplete","aria-haspopup"]);if(this.readonly){this.maxLengthExceeded=false;this.maxValueExceeded=false;this.minValueUnattained=false}h(this.el,this.handleFormReset);c(this.disabled,this.el)}componentDidLoad(){d([{prop:this.label,propName:"label"}],"Text Field");if(this.validationInlineInternal){this.getInlineValidationText()}}handleKeyDown(t){this.icKeydown.emit({event:t})}async setFocus(){if(this.inputEl){this.inputEl.focus()}}hasLeftIconSlot(){const t=this.el.querySelector(`[slot="icon"]`);return t!==null}render(){const{inputId:t,name:e,label:a,required:o,small:r,placeholder:l,helperText:h,rows:c,resize:d,disabled:f,value:y,min:x,max:g,maxLength:v,numChars:w,readonly:k,maxLengthExceeded:z,minValueUnattained:I,maxValueExceeded:L,validationStatus:j,validationText:F,validationInline:T,validationInlineInternal:q,spellcheck:C,inputmode:V,fullWidth:B,truncateValue:M,hiddenInput:N}=this;const W=k?true:f;const $=f?"":l;const H=z||L||I?n.Error:j;const S=z?"Maximum length exceeded":L?`Maximum value of ${g} exceeded`:I?`Minimum value of ${x} not met`:F;const D=k?0:v;const E=z||L||I||v===0&&H===n.Error?"assertive":"polite";const K=this.showStatusText(H);const O=this.isTextArea();const _=v>0?t+"-charcount-desc":"";const U=(_+" "+u(t,h!=="",K)).trim();if(this.showLeftIcon&&!k&&W){this.showLeftIcon=false}const A=H===n.Error?"true":"false";const G=W&&!k;if(N){p(true,this.el,e,y,W)}return i(s,{class:{["fullwidth"]:B}},i("ic-input-container",{readonly:k,disabled:W},!this.hideLabel&&i("ic-input-label",{for:t,label:a,helperText:h,required:o,disabled:G,readonly:k}),i("ic-input-component-container",{small:r,validationStatus:H,multiLine:O,disabled:W,readonly:k,validationInline:T,fullWidth:B},this.showLeftIcon&&i("span",{class:{["readonly"]:k,["has-value"]:y.length>0},slot:"left-icon"},i("slot",{name:"icon"})),!O&&i("input",Object.assign({id:t,name:e,ref:t=>this.inputEl=t,type:this.type,min:x,max:g,value:y,class:{["no-left-pad"]:!this.showLeftIcon&&k,["readonly"]:k,["truncate-value"]:M},placeholder:$,required:o,disabled:W,readonly:k,onInput:this.onInput,onBlur:this.onBlur,onFocus:this.onFocus,"aria-label":a,"aria-describedby":U,"aria-invalid":A,"aria-activedescendant":this.ariaActiveDescendant,"aria-expanded":this.ariaExpanded,"aria-owns":this.ariaOwns,autocomplete:this.autocomplete,autocapitalize:this.autocapitalize,autoFocus:this.autoFocus,spellcheck:C,inputmode:V,role:this.role},this.inheritedAttributes)),O&&i("textarea",Object.assign({id:t,class:{["no-resize"]:d===false||k,["no-left-pad"]:!this.showLeftIcon&&k,["readonly"]:k},name:e,ref:t=>this.inputEl=t,value:y,rows:c,required:o,disabled:W,placeholder:$,readonly:k,onInput:this.onInput,onBlur:this.onBlur,onFocus:this.onFocus,"aria-label":a,"aria-describedby":U,"aria-invalid":A,autocapitalize:this.autocapitalize,autoFocus:this.autoFocus,spellcheck:C,inputmode:V},this.inheritedAttributes)),m(this.el,"clear-button")&&i("slot",{name:"clear-button"}),m(this.el,"search-submit-button")&&i("slot",{name:"search-submit-button"})),m(this.el,"menu")&&i("slot",{name:"menu"}),(!b(j)||!b(F)||D>0||L||I)&&!q&&i("ic-input-validation",{status:this.hasStatus(H)===false||H===n.Success&&T||q?"":H,message:K?S:"",ariaLiveMode:E,for:t,fullWidth:B},!k&&D>0&&i("div",{slot:"validation-message-adornment"},i("ic-typography",{variant:"caption",class:{["maxlengthtext"]:true,["error"]:z,["disabled"]:G}},i("span",{"aria-live":"polite",id:`${t}-charcount`,class:"charcount"},w,"/",D),i("span",{hidden:true,id:_},"Field can contain a maximum of ",D," characters."))))))}get el(){return a(this)}static get watchers(){return{debounce:["debounceChanged"],value:["watchValueHandler"]}}};g.style=y;export{g as ic_text_field};
2
- //# sourceMappingURL=p-07877eb8.entry.js.map
1
+ import{r as t,c as e,h as i,H as s,g as a}from"./p-18068237.js";import{a as n}from"./p-613aa265.js";import{L as o,e as r,n as l,d as h,r as c,a as d,j as u,f as p,i as m,B as b,p as f}from"./p-ebe76390.js";const y='/*! 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}:host(.fullwidth){width:100%}::-moz-placeholder{color:var(--ic-color-tertiary-text);opacity:1}::placeholder{color:var(--ic-color-tertiary-text);opacity:1}input,textarea{border:0;border-radius:var(--ic-border-radius);background-color:var(--ic-architectural-white);line-height:1.5rem;letter-spacing:0.005rem;width:100%;padding-right:var(--ic-space-xs);padding-left:var(--ic-space-xs)}textarea{min-height:var(--ic-space-lg);resize:vertical;padding-top:0.375rem}input:focus,textarea:focus{border:0;outline:0}input:disabled,textarea:disabled{color:var(--ic-architectural-200)}input.readonly,textarea.readonly{color:var(--ic-color-primary-text)}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}input[type="number"]{-moz-appearance:textfield}textarea.no-resize{resize:none}.maxlengthtext{color:var(--ic-color-secondary-text)}.no-left-pad{padding-left:0}::slotted([slot="icon"]){fill:var(--ic-color-tertiary-text)}.has-value ::slotted([slot="icon"]){fill:var(--ic-color-primary-text)}.charcount{margin-right:calc(-1 * var(--ic-space-xxxs))}input[type="search"]::-webkit-search-cancel-button,input[type="search"]::-webkit-search-decoration,input[type="search"]::-webkit-search-results-button,input[type="search"]::-webkit-search-results-decoration{display:none}input[type="search"].truncate-value{width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}@media (forced-colors: active){input.readonly,textarea.readonly{color:canvastext}.has-value ::slotted([slot="icon"]){fill:currentcolor}}';let x=0;const g=class{constructor(i){t(this,i);this.getValidationText=e(this,"getValidationText",7);this.icBlur=e(this,"icBlur",7);this.icChange=e(this,"icChange",7);this.icFocus=e(this,"icFocus",7);this.icInput=e(this,"icInput",7);this.icKeydown=e(this,"icKeydown",7);this.inheritedAttributes={};this.showLeftIcon=this.hasLeftIconSlot();this.onInput=t=>{this.value=t.target.value;this.icInput.emit({value:this.value})};this.onBlur=t=>{const e=t.target.value;this.icBlur.emit({value:e})};this.onFocus=t=>{const e=t.target.value;this.icFocus.emit({value:e})};this.isTextArea=()=>this.rows>1;this.getInlineValidationText=()=>{this.getValidationText.emit({value:this.validationText})};this.hasStatus=t=>t!==""&&!this.disabled;this.showStatusText=t=>this.hasStatus(t)&&!(t==n.Success&&this.validationInline)&&!this.validationInlineInternal;this.handleFormReset=()=>{this.value=this.initialValue};this.numChars=0;this.maxLengthExceeded=false;this.maxValueExceeded=false;this.minValueUnattained=false;this.ariaActiveDescendant=undefined;this.ariaAutocomplete=undefined;this.ariaExpanded=undefined;this.ariaOwns=undefined;this.autocapitalize="off";this.autocomplete="off";this.autocorrect="off";this.autoFocus=false;this.disabled=false;this.fullWidth=false;this.helperText="";this.hideLabel=false;this.hiddenInput=true;this.inputId=`ic-text-field-input-${x++}`;this.inputmode="text";this.label=undefined;this.max=undefined;this.maxLength=0;this.min=undefined;this.name=this.inputId;this.placeholder="";this.readonly=false;this.required=false;this.resize=false;this.role=undefined;this.rows=1;this.small=false;this.spellcheck=false;this.truncateValue=undefined;this.type="text";this.validationInline=false;this.validationInlineInternal=false;this.validationStatus="";this.validationText="";this.debounce=0;this.value="";this.initialValue=this.value}debounceChanged(){this.icChange=o(this.icChange,this.debounce)}watchValueHandler(t){if(this.inputEl&&this.inputEl.value!==t){this.inputEl.value=t}this.numChars=t.length;if(this.type==="number"){if(t&&Number(t)<Number(this.min)){this.minValueUnattained=true}else{this.minValueUnattained=false}if(Number(t)>Number(this.max)){this.maxValueExceeded=true}else{this.maxValueExceeded=false}}if(this.maxLength>0){if(t.length>this.maxLength){this.maxLengthExceeded=true}else{this.maxLengthExceeded=false}}this.icChange.emit({value:t})}connectedCallback(){this.debounceChanged()}disconnectedCallback(){r(this.el,this.handleFormReset)}componentWillLoad(){this.watchValueHandler(this.value);this.inheritedAttributes=l(this.el,[...f,"title","aria-autocomplete","aria-haspopup"]);if(this.readonly){this.maxLengthExceeded=false;this.maxValueExceeded=false;this.minValueUnattained=false}h(this.el,this.handleFormReset);c(this.disabled,this.el)}componentDidLoad(){d([{prop:this.label,propName:"label"}],"Text Field");if(this.validationInlineInternal){this.getInlineValidationText()}}handleKeyDown(t){this.icKeydown.emit({event:t})}async setFocus(){if(this.inputEl){this.inputEl.focus()}}hasLeftIconSlot(){const t=this.el.querySelector(`[slot="icon"]`);return t!==null}render(){const{inputId:t,name:e,label:a,required:o,small:r,placeholder:l,helperText:h,rows:c,resize:d,disabled:f,value:y,min:x,max:g,maxLength:v,numChars:w,readonly:k,maxLengthExceeded:z,minValueUnattained:I,maxValueExceeded:L,validationStatus:j,validationText:F,validationInline:T,validationInlineInternal:q,spellcheck:C,inputmode:V,fullWidth:B,truncateValue:M,hiddenInput:N}=this;const W=k?true:f;const $=f?"":l;const H=z||L||I?n.Error:j;const S=z?"Maximum length exceeded":L?`Maximum value of ${g} exceeded`:I?`Minimum value of ${x} not met`:F;const D=k?0:v;const E=z||L||I||v===0&&H===n.Error?"assertive":"polite";const K=this.showStatusText(H);const O=this.isTextArea();const _=v>0?t+"-charcount-desc":"";const U=(_+" "+u(t,h!=="",K)).trim();if(this.showLeftIcon&&!k&&W){this.showLeftIcon=false}const A=H===n.Error?"true":"false";const G=W&&!k;if(N){p(true,this.el,e,y,W)}return i(s,{class:{["fullwidth"]:B}},i("ic-input-container",{readonly:k,disabled:W},!this.hideLabel&&i("ic-input-label",{for:t,label:a,helperText:h,required:o,disabled:G,readonly:k}),i("ic-input-component-container",{small:r,validationStatus:H,multiLine:O,disabled:W,readonly:k,validationInline:T,fullWidth:B},this.showLeftIcon&&i("span",{class:{["readonly"]:k,["has-value"]:y.length>0},slot:"left-icon"},i("slot",{name:"icon"})),!O&&i("input",Object.assign({id:t,name:e,ref:t=>this.inputEl=t,type:this.type,min:x,max:g,value:y,class:{["no-left-pad"]:!this.showLeftIcon&&k,["readonly"]:k,["truncate-value"]:M},placeholder:$,required:o,disabled:W,readonly:k,onInput:this.onInput,onBlur:this.onBlur,onFocus:this.onFocus,"aria-label":a,"aria-describedby":U,"aria-invalid":A,"aria-activedescendant":this.ariaActiveDescendant,"aria-expanded":this.ariaExpanded,"aria-owns":this.ariaOwns,autocomplete:this.autocomplete,autocapitalize:this.autocapitalize,autoFocus:this.autoFocus,spellcheck:C,inputmode:V,role:this.role},this.inheritedAttributes)),O&&i("textarea",Object.assign({id:t,class:{["no-resize"]:d===false||k,["no-left-pad"]:!this.showLeftIcon&&k,["readonly"]:k},name:e,ref:t=>this.inputEl=t,value:y,rows:c,required:o,disabled:W,placeholder:$,readonly:k,onInput:this.onInput,onBlur:this.onBlur,onFocus:this.onFocus,"aria-label":a,"aria-describedby":U,"aria-invalid":A,autocapitalize:this.autocapitalize,autoFocus:this.autoFocus,spellcheck:C,inputmode:V},this.inheritedAttributes)),m(this.el,"clear-button")&&i("slot",{name:"clear-button"}),m(this.el,"search-submit-button")&&i("slot",{name:"search-submit-button"})),m(this.el,"menu")&&i("slot",{name:"menu"}),(!b(j)||!b(F)||D>0||L||I)&&!q&&i("ic-input-validation",{status:this.hasStatus(H)===false||H===n.Success&&T||q?"":H,message:K?S:"",ariaLiveMode:E,for:t,fullWidth:B},!k&&D>0&&i("div",{slot:"validation-message-adornment"},i("ic-typography",{variant:"caption",class:{["maxlengthtext"]:true,["error"]:z,["disabled"]:G}},i("span",{"aria-live":"polite",id:`${t}-charcount`,class:"charcount"},w,"/",D),i("span",{hidden:true,id:_},"Field can contain a maximum of ",D," characters."))))))}get el(){return a(this)}static get watchers(){return{debounce:["debounceChanged"],value:["watchValueHandler"]}}};g.style=y;export{g as ic_text_field};
2
+ //# sourceMappingURL=p-4c4261e7.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["icTextFieldCss","inputIds","TextField","this","inheritedAttributes","showLeftIcon","hasLeftIconSlot","onInput","ev","value","target","icInput","emit","onBlur","icBlur","onFocus","icFocus","isTextArea","rows","getInlineValidationText","getValidationText","validationText","hasStatus","status","disabled","showStatusText","IcInformationStatus","Success","validationInline","validationInlineInternal","handleFormReset","initialValue","undefined","inputId","debounceChanged","icChange","debounceEvent","debounce","watchValueHandler","newValue","inputEl","numChars","length","type","Number","min","minValueUnattained","max","maxValueExceeded","maxLength","maxLengthExceeded","connectedCallback","disconnectedCallback","removeFormResetListener","el","componentWillLoad","inheritAttributes","IC_INHERITED_ARIA","readonly","addFormResetListener","removeDisabledFalse","componentDidLoad","onComponentRequiredPropUndefined","prop","label","propName","handleKeyDown","icKeydown","event","setFocus","focus","iconEl","querySelector","render","name","required","small","placeholder","helperText","resize","validationStatus","spellcheck","inputmode","fullWidth","truncateValue","hiddenInput","disabledMode","placeholderText","currentStatus","Error","currentValidationText","maxNumChars","messageAriaLive","multiline","hiddenCharCountDescId","describedBy","getInputDescribedByText","trim","invalid","disabledText","renderHiddenInput","h","Host","class","hideLabel","for","multiLine","slot","Object","assign","id","ref","ariaActiveDescendant","ariaExpanded","ariaOwns","autocomplete","autocapitalize","autoFocus","role","isSlotUsed","isEmptyString","message","ariaLiveMode","variant","hidden"],"sources":["src/components/ic-text-field/ic-text-field.css?tag=ic-text-field&encapsulation=shadow","src/components/ic-text-field/ic-text-field.tsx"],"sourcesContent":["@import \"../../global/normalize.css\";\n\n:host {\n /**\n * @prop --input-width: Width of the input field\n */\n display: block;\n}\n\n:host(.fullwidth) {\n width: 100%;\n}\n\n::placeholder {\n color: var(--ic-color-tertiary-text);\n opacity: 1;\n}\n\ninput,\ntextarea {\n border: 0;\n border-radius: var(--ic-border-radius);\n background-color: var(--ic-architectural-white);\n line-height: 1.5rem;\n letter-spacing: 0.005rem;\n width: 100%;\n padding-right: var(--ic-space-xs);\n padding-left: var(--ic-space-xs);\n}\n\ntextarea {\n min-height: var(--ic-space-lg);\n resize: vertical;\n padding-top: 0.375rem;\n}\n\ninput:focus,\ntextarea:focus {\n border: 0;\n outline: 0;\n}\n\ninput:disabled,\ntextarea:disabled {\n color: var(--ic-architectural-200);\n}\n\ninput.readonly,\ntextarea.readonly {\n color: var(--ic-color-primary-text);\n}\n\n/* Chrome, Safari, Edge */\ninput::-webkit-outer-spin-button,\ninput::-webkit-inner-spin-button {\n -webkit-appearance: none;\n margin: 0;\n}\n\n/* Firefox */\ninput[type=\"number\"] {\n -moz-appearance: textfield;\n}\n\ntextarea.no-resize {\n resize: none;\n}\n\n.maxlengthtext {\n color: var(--ic-color-secondary-text);\n}\n\n.no-left-pad {\n padding-left: 0;\n}\n\n::slotted([slot=\"icon\"]) {\n fill: var(--ic-color-tertiary-text);\n}\n\n.has-value ::slotted([slot=\"icon\"]) {\n fill: var(--ic-color-primary-text);\n}\n\n.charcount {\n margin-right: calc(-1 * var(--ic-space-xxxs));\n}\n\ninput[type=\"search\"]::-webkit-search-cancel-button,\ninput[type=\"search\"]::-webkit-search-decoration,\ninput[type=\"search\"]::-webkit-search-results-button,\ninput[type=\"search\"]::-webkit-search-results-decoration {\n display: none;\n}\n\ninput[type=\"search\"].truncate-value {\n width: 100%;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n@media (forced-colors: active) {\n input.readonly,\n textarea.readonly {\n color: canvastext;\n }\n\n .has-value ::slotted([slot=\"icon\"]) {\n fill: currentcolor;\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n Host,\n Listen,\n Prop,\n State,\n Watch,\n Method,\n h,\n} from \"@stencil/core\";\nimport {\n IcInformationStatus,\n IcAutocompleteTypes,\n IcAutocorrectStates,\n IcInformationStatusOrEmpty,\n IcValueEventDetail,\n} from \"../../utils/types\";\nimport {\n inheritAttributes,\n debounceEvent,\n getInputDescribedByText,\n renderHiddenInput,\n isEmptyString,\n onComponentRequiredPropUndefined,\n addFormResetListener,\n removeFormResetListener,\n isSlotUsed,\n removeDisabledFalse,\n} from \"../../utils/helpers\";\nimport { IC_INHERITED_ARIA } from \"../../utils/constants\";\nimport {\n IcAriaAutocompleteTypes,\n IcTextFieldInputModes,\n IcTextFieldTypes,\n} from \"./ic-text-field.types\";\n\nlet inputIds = 0;\n\n/**\n * @slot icon - Content will be placed to the left of the text input.\n */\n@Component({\n tag: \"ic-text-field\",\n styleUrl: \"ic-text-field.css\",\n shadow: true,\n})\nexport class TextField {\n private inheritedAttributes: { [k: string]: unknown } = {};\n private inputEl: HTMLInputElement | HTMLTextAreaElement;\n private showLeftIcon: boolean = this.hasLeftIconSlot();\n\n @Element() el: HTMLIcTextFieldElement;\n\n @State() numChars: number = 0;\n @State() maxLengthExceeded: boolean = false;\n @State() maxValueExceeded: boolean = false;\n @State() minValueUnattained: boolean = false;\n\n /**\n * @slot clear-button - an ic-button clear component will render as an end adornment to the input.\n * @slot search-submit-button - an ic-button search submit component will render as an end adornment to the input.\n * @slot menu - an ic-menu component will appear below the input.\n */\n\n /**\n * @internal The active element when focus is on the ic-menu items.\n */\n @Prop() ariaActiveDescendant?: string;\n\n /**\n * @internal Used to identify whether inputting any text triggers more predictions\n */\n @Prop() ariaAutocomplete: IcAriaAutocompleteTypes = undefined;\n\n /**\n * @internal Used to identify if the slotted menu is rendered\n */\n @Prop() ariaExpanded: string;\n\n /**\n * @internal Used to identify any related child component\n */\n @Prop() ariaOwns: string;\n\n /**\n * The automatic capitalisation of the text value as it is entered/edited by the user.\n * Available options: \"off\", \"none\", \"on\", \"sentences\", \"words\", \"characters\".\n */\n @Prop() autocapitalize = \"off\";\n\n /**\n * The state of autocompletion the browser can apply on the text value.\n */\n @Prop() autocomplete: IcAutocompleteTypes = \"off\";\n\n /**\n * The state of autocorrection the browser can apply when the user is entering/editing the text value.\n */\n @Prop() autocorrect: IcAutocorrectStates = \"off\";\n\n /**\n * If `true`, the form control will have input focus when the page loads.\n */\n @Prop() autoFocus = false;\n\n /**\n * If `true`, the disabled state will be set.\n */\n @Prop() disabled: boolean = false;\n\n /**\n * Specify whether the text field fills the full width of the container.\n * If `true`, this overrides the --input-width CSS variable.\n */\n @Prop() fullWidth: boolean = false;\n\n /**\n * The helper text that will be displayed for additional field guidance.\n */\n @Prop() helperText: string = \"\";\n\n /**\n * If `true`, the label will be hidden and the required label value will be applied as an aria-label.\n */\n @Prop() hideLabel: boolean = false;\n\n /**\n * @internal If `true`, the hidden form input will stop rendering for form submission.\n */\n @Prop() hiddenInput: boolean = true;\n\n /**\n * The ID for the input.\n */\n @Prop() inputId?: string = `ic-text-field-input-${inputIds++}`;\n\n /**\n * A hint to the browser for which keyboard to display.\n * Possible values: `\"none\"`, `\"text\"`, `\"tel\"`, `\"url\"`,\n * `\"email\"`, `\"numeric\"`, `\"decimal\"`, and `\"search\"`.\n */\n @Prop() inputmode: IcTextFieldInputModes = \"text\";\n\n /**\n * The label for the input.\n */\n @Prop() label!: string;\n\n /**\n * The maximum number that can be accepted as a value, when `type` is `number` and `rows` is `1`. (NOTE: Ensure to include visual indication of max value in `helperText` or `label`)\n */\n @Prop() max: string | number = undefined;\n\n /**\n * The maximum number of characters that can be entered in the field.\n */\n @Prop() maxLength: number = 0;\n\n /**\n * The minimum number that can be accepted as a value, when `type` is `number` and `rows` is `1`. (NOTE: Ensure to include visual indication of min value in `helperText` or `label`)\n */\n @Prop() min: string | number = undefined;\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name: string = this.inputId;\n\n /**\n * The placeholder value to be displayed.\n */\n @Prop() placeholder: string = \"\";\n\n /**\n * If `true`, the read only state will be set.\n */\n @Prop({ reflect: true }) readonly: boolean = false;\n\n /**\n * If `true`, the input will require a value.\n */\n @Prop() required: boolean = false;\n\n /**\n * If `true`, the multiline text area will be resizeable.\n */\n @Prop() resize: boolean = false;\n\n /**\n * @internal Used to set the role if not default textbox;\n */\n @Prop() role: string;\n\n /**\n * The number of rows to transform the text field into a text area with a specific height.\n */\n @Prop() rows: number = 1;\n\n /**\n * If `true`, the small styling will be applied to the text field.\n */\n @Prop({ reflect: true }) small: boolean = false;\n\n /**\n * If `true`, the value of the text field will have its spelling and grammar checked.\n */\n @Prop() spellcheck: boolean = false;\n /**\n * @internal If `true`, an ellipsis will be displayed at the end of the value if the value is longer than the container.\n */\n @Prop() truncateValue?: boolean;\n\n /**\n * The type of control to display. The default type is text.\n */\n @Prop() type: IcTextFieldTypes = \"text\";\n\n /**\n * If `true`, the icon in input control will be displayed - only applies when validationStatus ='success'.\n */\n @Prop() validationInline: boolean = false;\n\n /**\n * @internal If `true`, the validation will display inline.\n */\n @Prop() validationInlineInternal: boolean = false;\n\n /**\n * The validation state - e.g. 'error' | 'warning' | 'success'.\n */\n @Prop() validationStatus: IcInformationStatusOrEmpty = \"\";\n\n /**\n * The validation state - e.g. 'error' | 'warning' | 'success'.\n */\n @Prop() validationText: string = \"\";\n\n /**\n * The amount of time, in milliseconds, to wait to trigger the `icChange` event after each keystroke.\n */\n @Prop() debounce: number = 0;\n\n @Watch(\"debounce\")\n private debounceChanged() {\n this.icChange = debounceEvent(this.icChange, this.debounce);\n }\n\n /**\n * The value of the text field.\n */\n @Prop({ reflect: true, mutable: true }) value: string = \"\";\n @State() initialValue = this.value;\n\n @Watch(\"value\")\n private watchValueHandler(newValue: string): void {\n if (this.inputEl && this.inputEl.value !== newValue) {\n this.inputEl.value = newValue;\n }\n\n this.numChars = newValue.length;\n\n if (this.type === \"number\") {\n if (newValue && Number(newValue) < Number(this.min)) {\n this.minValueUnattained = true;\n } else {\n this.minValueUnattained = false;\n }\n if (Number(newValue) > Number(this.max)) {\n this.maxValueExceeded = true;\n } else {\n this.maxValueExceeded = false;\n }\n }\n\n if (this.maxLength > 0) {\n if (newValue.length > this.maxLength) {\n this.maxLengthExceeded = true;\n } else {\n this.maxLengthExceeded = false;\n }\n }\n this.icChange.emit({ value: newValue });\n }\n\n /**\n * @internal Emitted when the validationInlineInternal is `true`\n */\n @Event() getValidationText: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when input loses focus.\n */\n @Event() icBlur: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when the value has changed.\n */\n @Event() icChange: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when input gains focus.\n */\n @Event() icFocus: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when a keyboard input occurred.\n */\n @Event() icInput: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when a keydown event occurred.\n */\n @Event() icKeydown: EventEmitter<{ event: KeyboardEvent }>;\n\n connectedCallback(): void {\n this.debounceChanged();\n }\n\n disconnectedCallback(): void {\n removeFormResetListener(this.el, this.handleFormReset);\n }\n\n componentWillLoad(): void {\n this.watchValueHandler(this.value);\n\n this.inheritedAttributes = inheritAttributes(this.el, [\n ...IC_INHERITED_ARIA,\n \"title\",\n \"aria-autocomplete\",\n \"aria-haspopup\",\n ]);\n\n if (this.readonly) {\n this.maxLengthExceeded = false;\n this.maxValueExceeded = false;\n this.minValueUnattained = false;\n }\n\n addFormResetListener(this.el, this.handleFormReset);\n\n removeDisabledFalse(this.disabled, this.el);\n }\n\n componentDidLoad(): void {\n onComponentRequiredPropUndefined(\n [{ prop: this.label, propName: \"label\" }],\n \"Text Field\"\n );\n if (this.validationInlineInternal) {\n this.getInlineValidationText();\n }\n }\n\n @Listen(\"keydown\", {})\n handleKeyDown(ev: KeyboardEvent): void {\n this.icKeydown.emit({ event: ev });\n }\n\n /**\n * Sets focus on the native `input`.\n */\n\n @Method()\n async setFocus(): Promise<void> {\n if (this.inputEl) {\n this.inputEl.focus();\n }\n }\n\n private onInput = (ev: Event) => {\n this.value = (ev.target as HTMLInputElement).value;\n this.icInput.emit({ value: this.value });\n };\n\n private onBlur = (ev: Event) => {\n const value = (ev.target as HTMLInputElement).value;\n this.icBlur.emit({ value: value });\n };\n\n private onFocus = (ev: Event) => {\n const value = (ev.target as HTMLInputElement).value;\n this.icFocus.emit({ value: value });\n };\n\n private isTextArea = (): boolean => {\n return this.rows > 1;\n };\n\n private getInlineValidationText = () => {\n this.getValidationText.emit({ value: this.validationText });\n };\n\n private hasLeftIconSlot(): boolean {\n const iconEl = this.el.querySelector(`[slot=\"icon\"]`);\n return iconEl !== null;\n }\n\n private hasStatus = (status: IcInformationStatusOrEmpty): boolean => {\n return status !== \"\" && !this.disabled;\n };\n\n private showStatusText = (status: IcInformationStatusOrEmpty): boolean => {\n return (\n this.hasStatus(status) &&\n !(status == IcInformationStatus.Success && this.validationInline) &&\n !this.validationInlineInternal\n );\n };\n\n private handleFormReset = (): void => {\n this.value = this.initialValue;\n };\n\n render() {\n const {\n inputId,\n name,\n label,\n required,\n small,\n placeholder,\n helperText,\n rows,\n resize,\n disabled,\n value,\n min,\n max,\n maxLength,\n numChars,\n readonly,\n maxLengthExceeded,\n minValueUnattained,\n maxValueExceeded,\n validationStatus,\n validationText,\n validationInline,\n validationInlineInternal,\n spellcheck,\n inputmode,\n fullWidth,\n truncateValue,\n hiddenInput,\n } = this;\n\n const disabledMode = readonly ? true : disabled;\n\n const placeholderText = disabled ? \"\" : placeholder;\n\n const currentStatus =\n maxLengthExceeded || maxValueExceeded || minValueUnattained\n ? IcInformationStatus.Error\n : validationStatus;\n\n const currentValidationText = maxLengthExceeded\n ? \"Maximum length exceeded\"\n : maxValueExceeded\n ? `Maximum value of ${max} exceeded`\n : minValueUnattained\n ? `Minimum value of ${min} not met`\n : validationText;\n\n const maxNumChars = readonly ? 0 : maxLength;\n\n const messageAriaLive =\n maxLengthExceeded ||\n maxValueExceeded ||\n minValueUnattained ||\n (maxLength === 0 && currentStatus === IcInformationStatus.Error)\n ? \"assertive\"\n : \"polite\";\n\n const showStatusText = this.showStatusText(currentStatus);\n const multiline = this.isTextArea();\n const hiddenCharCountDescId =\n maxLength > 0 ? inputId + \"-charcount-desc\" : \"\";\n const describedBy = (\n hiddenCharCountDescId +\n \" \" +\n getInputDescribedByText(inputId, helperText !== \"\", showStatusText)\n ).trim();\n\n if (this.showLeftIcon && !readonly && disabledMode) {\n this.showLeftIcon = false;\n }\n\n const invalid =\n currentStatus === IcInformationStatus.Error ? \"true\" : \"false\";\n const disabledText = disabledMode && !readonly;\n\n if (hiddenInput) {\n renderHiddenInput(true, this.el, name, value, disabledMode);\n }\n return (\n <Host class={{ [\"fullwidth\"]: fullWidth }}>\n <ic-input-container readonly={readonly} disabled={disabledMode}>\n {!this.hideLabel && (\n <ic-input-label\n for={inputId}\n label={label}\n helperText={helperText}\n required={required}\n disabled={disabledText}\n readonly={readonly}\n ></ic-input-label>\n )}\n\n <ic-input-component-container\n small={small}\n validationStatus={currentStatus}\n multiLine={multiline}\n disabled={disabledMode}\n readonly={readonly}\n validationInline={validationInline}\n fullWidth={fullWidth}\n >\n {this.showLeftIcon && (\n <span\n class={{\n [\"readonly\"]: readonly,\n [\"has-value\"]: value.length > 0,\n }}\n slot=\"left-icon\"\n >\n <slot name=\"icon\" />\n </span>\n )}\n\n {!multiline && (\n <input\n id={inputId}\n name={name}\n ref={(el) => (this.inputEl = el as HTMLInputElement)}\n type={this.type}\n min={min}\n max={max}\n value={value}\n class={{\n [\"no-left-pad\"]: !this.showLeftIcon && readonly,\n [\"readonly\"]: readonly,\n [\"truncate-value\"]: truncateValue,\n }}\n placeholder={placeholderText}\n required={required}\n disabled={disabledMode}\n readonly={readonly}\n onInput={this.onInput}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n aria-label={label}\n aria-describedby={describedBy}\n aria-invalid={invalid}\n aria-activedescendant={this.ariaActiveDescendant}\n aria-expanded={this.ariaExpanded}\n aria-owns={this.ariaOwns}\n autocomplete={this.autocomplete}\n autocapitalize={this.autocapitalize}\n autoFocus={this.autoFocus}\n spellcheck={spellcheck}\n inputmode={inputmode}\n role={this.role}\n {...this.inheritedAttributes}\n ></input>\n )}\n {multiline && (\n <textarea\n id={inputId}\n class={{\n [\"no-resize\"]: resize === false || readonly,\n [\"no-left-pad\"]: !this.showLeftIcon && readonly,\n [\"readonly\"]: readonly,\n }}\n name={name}\n ref={(el) => (this.inputEl = el as HTMLTextAreaElement)}\n value={value}\n rows={rows}\n required={required}\n disabled={disabledMode}\n placeholder={placeholderText}\n readonly={readonly}\n onInput={this.onInput}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n aria-label={label}\n aria-describedby={describedBy}\n aria-invalid={invalid}\n autocapitalize={this.autocapitalize}\n autoFocus={this.autoFocus}\n spellcheck={spellcheck}\n inputmode={inputmode}\n {...this.inheritedAttributes}\n ></textarea>\n )}\n {isSlotUsed(this.el, \"clear-button\") && (\n <slot name=\"clear-button\"></slot>\n )}\n {isSlotUsed(this.el, \"search-submit-button\") && (\n <slot name=\"search-submit-button\"></slot>\n )}\n </ic-input-component-container>\n {isSlotUsed(this.el, \"menu\") && <slot name=\"menu\"></slot>}\n {(!isEmptyString(validationStatus) ||\n !isEmptyString(validationText) ||\n maxNumChars > 0 ||\n maxValueExceeded ||\n minValueUnattained) &&\n !validationInlineInternal && (\n <ic-input-validation\n status={\n this.hasStatus(currentStatus) === false ||\n (currentStatus === IcInformationStatus.Success &&\n validationInline) ||\n validationInlineInternal\n ? \"\"\n : currentStatus\n }\n message={showStatusText ? currentValidationText : \"\"}\n ariaLiveMode={messageAriaLive}\n for={inputId}\n fullWidth={fullWidth}\n >\n {!readonly && maxNumChars > 0 && (\n <div slot=\"validation-message-adornment\">\n <ic-typography\n variant=\"caption\"\n class={{\n [\"maxlengthtext\"]: true,\n [\"error\"]: maxLengthExceeded,\n [\"disabled\"]: disabledText,\n }}\n >\n <span\n aria-live=\"polite\"\n id={`${inputId}-charcount`}\n class=\"charcount\"\n >\n {numChars}/{maxNumChars}\n </span>\n <span hidden={true} id={hiddenCharCountDescId}>\n Field can contain a maximum of {maxNumChars} characters.\n </span>\n </ic-typography>\n </div>\n )}\n </ic-input-validation>\n )}\n </ic-input-container>\n </Host>\n );\n }\n}\n"],"mappings":"8MAAA,MAAMA,EAAiB,+3HCuCvB,IAAIC,EAAW,E,MAUFC,EAAS,M,uPACZC,KAAAC,oBAAgD,GAEhDD,KAAAE,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";import{D as e,g as l,c as a}from"./p-dd980be4.js";import"./p-6f57b13c.js";const r=":host{display:block}:host ol{display:flex;list-style-type:none;align-items:center;flex-wrap:wrap;padding:0;margin:0}:host(.back) ol ::slotted(ic-breadcrumb){display:none}:host(.back) ol ::slotted(ic-breadcrumb.show){display:flex}:host(.collapsed) ol ::slotted(ic-breadcrumb.hide){display:none;opacity:0;visibility:hidden}:host(.collapsed) ol ::slotted(ic-breadcrumb.visuallyhidden){display:block;opacity:0;transition:all var(--ic-easing-transition-slow)}:host(.collapsed) ol ::slotted(ic-breadcrumb.fade){opacity:1}";const o=class{constructor(i){s(this,i);this.ADD_CLASS_DELAY=50;this.IC_BREADCRUMB="ic-breadcrumb";this.resizeObserver=null;this.SHOW_BACK_ICON="show-back-icon";this.setBackBreadcrumb=()=>{if(this.backBreadcrumbOnly){this.setBackBreadcrumbAttr()}};this.setBackBreadcrumbAttr=()=>{if(this.lastParentBreadcrumb){this.lastParentBreadcrumb.classList.add("show");this.lastParentBreadcrumb.setAttribute(this.SHOW_BACK_ICON,"true")}};this.getLastParentBreadcrumb=()=>{const s=Array.from(this.el.querySelectorAll(this.IC_BREADCRUMB));if(s.length===1){return null}this.breadcrumbs=s.filter((s=>!s.getAttribute("current")));this.breadcrumb=this.breadcrumbs[this.breadcrumbs.length-1];return this.breadcrumb};this.lastParentBreadcrumb=this.getLastParentBreadcrumb();this.setDefaultBreadcrumbs=()=>{const s=Array.from(this.el.querySelectorAll(this.IC_BREADCRUMB));s.forEach((s=>{s.setAttribute(this.SHOW_BACK_ICON,"false")}))};this.setCollapsed=()=>{if(this.collapsed){const s=Array.from(this.el.querySelectorAll(this.IC_BREADCRUMB));this.collapsedBreadcrumbs=s.splice(1,s.length-2).filter((s=>!s.classList.contains("collapsed-breadcrumb-wrapper")));this.collapsedBreadcrumbs.forEach((s=>s.classList.add("hide")));const i=s[0];if(i){i.insertAdjacentElement("afterend",this.collapsedBreadcrumbWrapper)}}};this.clickHandler=()=>{this.handleHiddenCollapsedBreadcrumbs(this.collapsedBreadcrumbWrapper)};this.renderCollapsedBreadcrumb=()=>{this.collapsedBreadcrumbWrapper=document.createElement("ic-breadcrumb");this.collapsedBreadcrumbWrapper.classList.add("collapsed-breadcrumb-wrapper");this.collapsedBreadcrumbEl=document.createElement("button");const s=document.createElement("span");s.id="collapsed-button-label";s.innerText="Collapsed breadcrumbs";s.className="hide";this.collapsedBreadcrumbEl.setAttribute("aria-labelledby","collapsed-button-label");const i=document.createElement("span");i.id="collapsed-button-described";i.innerText="Select to view collapsed breadcrumbs";i.className="hide";this.collapsedBreadcrumbEl.setAttribute("aria-describedby","collapsed-button-described");this.collapsedBreadcrumbEl.id="collapsed-ellipsis";this.collapsedBreadcrumbEl.innerText="...";this.collapsedBreadcrumbEl.classList.add("collapsed-breadcrumb");this.collapsedBreadcrumbEl.addEventListener("click",this.clickHandler);this.collapsedBreadcrumbWrapper.append(i);this.collapsedBreadcrumbWrapper.append(s);this.collapsedBreadcrumbWrapper.append(this.collapsedBreadcrumbEl);return this.collapsedBreadcrumbWrapper};this.handleHiddenCollapsedBreadcrumbs=s=>{s.remove();this.collapsedBreadcrumbs.forEach((s=>{s.classList.add("visuallyhidden");s.classList.remove("hide");setTimeout((()=>{s.classList.add("fade")}),this.ADD_CLASS_DELAY);this.removeVisuallyHiddenClass(s)}));this.expandedBreadcrumbs=true};this.transitionendHandler=s=>{if(s.propertyName==="opacity"){s.target.classList.remove("visuallyhidden")}};this.removeVisuallyHiddenClass=s=>{s.addEventListener("transitionend",this.transitionendHandler)};this.setLastParentCollapsedBackBreadcrumb=()=>{this.setBackBreadcrumbAttr();this.lastParentBreadcrumb.classList.remove("hide")};this.revertLastParentCollapsedBreadcrumb=()=>{this.lastParentBreadcrumb.setAttribute(this.SHOW_BACK_ICON,"false")};this.resizeObserverCallback=s=>{if(s!==this.deviceSize){this.deviceSize=s;if(this.deviceSize<=e.S){this.el.setAttribute("back-breadcrumb-only","true");if(this.collapsed){this.setLastParentCollapsedBackBreadcrumb()}else{this.setBackBreadcrumb()}}else{this.el.setAttribute("back-breadcrumb-only","false");if(this.collapsed&&this.breadcrumbs&&this.breadcrumbs.length>2){this.revertLastParentCollapsedBreadcrumb();if(this.expandedBreadcrumbs){this.setDefaultBreadcrumbs()}else{this.setCollapsed()}}else{this.setDefaultBreadcrumbs()}}}};this.runResizeObserver=()=>{this.resizeObserver=new ResizeObserver((()=>{const s=l();this.resizeObserverCallback(s)}));this.resizeObserver.observe(this.el)};this.deviceSize=e.XL;this.expandedBreadcrumbs=false;this.backBreadcrumbOnly=false;this.collapsed=false}componentWillLoad(){const s=Array.from(this.el.querySelectorAll(this.IC_BREADCRUMB));if(this.backBreadcrumbOnly){this.setBackBreadcrumb()}else{a(this.runResizeObserver)}if(this.collapsed){this.collapsedBreadcrumbWrapper=this.renderCollapsedBreadcrumb();if(s.length>2){if(l()===e.S){this.setLastParentCollapsedBackBreadcrumb()}else{this.setCollapsed()}}}}disconnectedCallback(){this.breadcrumb.removeEventListener("transitionend",this.transitionendHandler);this.collapsedBreadcrumbEl.removeEventListener("click",this.clickHandler)}render(){return i(t,{class:{back:this.backBreadcrumbOnly,collapsed:this.collapsed}},i("nav",{"aria-label":"breadcrumbs"},i("ol",null,i("slot",null))))}get el(){return h(this)}};o.style=r;export{o as ic_breadcrumb_group};
2
- //# sourceMappingURL=p-75ac2fbf.entry.js.map
1
+ import{r as s,h as i,H as t,g as h}from"./p-18068237.js";import{D as e,g as l,c as a}from"./p-ebe76390.js";import"./p-613aa265.js";const r=":host{display:block}:host ol{display:flex;list-style-type:none;align-items:center;flex-wrap:wrap;padding:0;margin:0}:host(.back) ol ::slotted(ic-breadcrumb){display:none}:host(.back) ol ::slotted(ic-breadcrumb.show){display:flex}:host(.collapsed) ol ::slotted(ic-breadcrumb.hide){display:none;opacity:0;visibility:hidden}:host(.collapsed) ol ::slotted(ic-breadcrumb.visuallyhidden){display:block;opacity:0;transition:all var(--ic-easing-transition-slow)}:host(.collapsed) ol ::slotted(ic-breadcrumb.fade){opacity:1}";const o=class{constructor(i){s(this,i);this.ADD_CLASS_DELAY=50;this.IC_BREADCRUMB="ic-breadcrumb";this.resizeObserver=null;this.SHOW_BACK_ICON="show-back-icon";this.setBackBreadcrumb=()=>{if(this.backBreadcrumbOnly){this.setBackBreadcrumbAttr()}};this.setBackBreadcrumbAttr=()=>{if(this.lastParentBreadcrumb){this.lastParentBreadcrumb.classList.add("show");this.lastParentBreadcrumb.setAttribute(this.SHOW_BACK_ICON,"true")}};this.getLastParentBreadcrumb=()=>{const s=Array.from(this.el.querySelectorAll(this.IC_BREADCRUMB));if(s.length===1){return null}this.breadcrumbs=s.filter((s=>!s.getAttribute("current")));this.breadcrumb=this.breadcrumbs[this.breadcrumbs.length-1];return this.breadcrumb};this.lastParentBreadcrumb=this.getLastParentBreadcrumb();this.setDefaultBreadcrumbs=()=>{const s=Array.from(this.el.querySelectorAll(this.IC_BREADCRUMB));s.forEach((s=>{s.setAttribute(this.SHOW_BACK_ICON,"false")}))};this.setCollapsed=()=>{if(this.collapsed){const s=Array.from(this.el.querySelectorAll(this.IC_BREADCRUMB));this.collapsedBreadcrumbs=s.splice(1,s.length-2).filter((s=>!s.classList.contains("collapsed-breadcrumb-wrapper")));this.collapsedBreadcrumbs.forEach((s=>s.classList.add("hide")));const i=s[0];if(i){i.insertAdjacentElement("afterend",this.collapsedBreadcrumbWrapper)}}};this.clickHandler=()=>{this.handleHiddenCollapsedBreadcrumbs(this.collapsedBreadcrumbWrapper)};this.renderCollapsedBreadcrumb=()=>{this.collapsedBreadcrumbWrapper=document.createElement("ic-breadcrumb");this.collapsedBreadcrumbWrapper.classList.add("collapsed-breadcrumb-wrapper");this.collapsedBreadcrumbEl=document.createElement("button");const s=document.createElement("span");s.id="collapsed-button-label";s.innerText="Collapsed breadcrumbs";s.className="hide";this.collapsedBreadcrumbEl.setAttribute("aria-labelledby","collapsed-button-label");const i=document.createElement("span");i.id="collapsed-button-described";i.innerText="Select to view collapsed breadcrumbs";i.className="hide";this.collapsedBreadcrumbEl.setAttribute("aria-describedby","collapsed-button-described");this.collapsedBreadcrumbEl.id="collapsed-ellipsis";this.collapsedBreadcrumbEl.innerText="...";this.collapsedBreadcrumbEl.classList.add("collapsed-breadcrumb");this.collapsedBreadcrumbEl.addEventListener("click",this.clickHandler);this.collapsedBreadcrumbWrapper.append(i);this.collapsedBreadcrumbWrapper.append(s);this.collapsedBreadcrumbWrapper.append(this.collapsedBreadcrumbEl);return this.collapsedBreadcrumbWrapper};this.handleHiddenCollapsedBreadcrumbs=s=>{s.remove();this.collapsedBreadcrumbs.forEach((s=>{s.classList.add("visuallyhidden");s.classList.remove("hide");setTimeout((()=>{s.classList.add("fade")}),this.ADD_CLASS_DELAY);this.removeVisuallyHiddenClass(s)}));this.expandedBreadcrumbs=true};this.transitionendHandler=s=>{if(s.propertyName==="opacity"){s.target.classList.remove("visuallyhidden")}};this.removeVisuallyHiddenClass=s=>{s.addEventListener("transitionend",this.transitionendHandler)};this.setLastParentCollapsedBackBreadcrumb=()=>{this.setBackBreadcrumbAttr();this.lastParentBreadcrumb.classList.remove("hide")};this.revertLastParentCollapsedBreadcrumb=()=>{this.lastParentBreadcrumb.setAttribute(this.SHOW_BACK_ICON,"false")};this.resizeObserverCallback=s=>{if(s!==this.deviceSize){this.deviceSize=s;if(this.deviceSize<=e.S){this.el.setAttribute("back-breadcrumb-only","true");if(this.collapsed){this.setLastParentCollapsedBackBreadcrumb()}else{this.setBackBreadcrumb()}}else{this.el.setAttribute("back-breadcrumb-only","false");if(this.collapsed&&this.breadcrumbs&&this.breadcrumbs.length>2){this.revertLastParentCollapsedBreadcrumb();if(this.expandedBreadcrumbs){this.setDefaultBreadcrumbs()}else{this.setCollapsed()}}else{this.setDefaultBreadcrumbs()}}}};this.runResizeObserver=()=>{this.resizeObserver=new ResizeObserver((()=>{const s=l();this.resizeObserverCallback(s)}));this.resizeObserver.observe(this.el)};this.deviceSize=e.XL;this.expandedBreadcrumbs=false;this.backBreadcrumbOnly=false;this.collapsed=false}componentWillLoad(){const s=Array.from(this.el.querySelectorAll(this.IC_BREADCRUMB));if(this.backBreadcrumbOnly){this.setBackBreadcrumb()}else{a(this.runResizeObserver)}if(this.collapsed){this.collapsedBreadcrumbWrapper=this.renderCollapsedBreadcrumb();if(s.length>2){if(l()===e.S){this.setLastParentCollapsedBackBreadcrumb()}else{this.setCollapsed()}}}}disconnectedCallback(){this.breadcrumb.removeEventListener("transitionend",this.transitionendHandler);this.collapsedBreadcrumbEl.removeEventListener("click",this.clickHandler)}render(){return i(t,{class:{back:this.backBreadcrumbOnly,collapsed:this.collapsed}},i("nav",{"aria-label":"breadcrumbs"},i("ol",null,i("slot",null))))}get el(){return h(this)}};o.style=r;export{o as ic_breadcrumb_group};
2
+ //# sourceMappingURL=p-4f7c20b3.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["icBreadcrumbGroupCss","BreadcrumbGroup","this","ADD_CLASS_DELAY","IC_BREADCRUMB","resizeObserver","SHOW_BACK_ICON","setBackBreadcrumb","backBreadcrumbOnly","setBackBreadcrumbAttr","lastParentBreadcrumb","classList","add","setAttribute","getLastParentBreadcrumb","allBreadcrumbs","Array","from","el","querySelectorAll","length","breadcrumbs","filter","breadcrumb","getAttribute","setDefaultBreadcrumbs","forEach","setCollapsed","collapsed","collapsedBreadcrumbs","splice","contains","firstBreadcrumb","insertAdjacentElement","collapsedBreadcrumbWrapper","clickHandler","handleHiddenCollapsedBreadcrumbs","renderCollapsedBreadcrumb","document","createElement","collapsedBreadcrumbEl","ariaLabel","id","innerText","className","ariaDescribed","addEventListener","append","remove","setTimeout","removeVisuallyHiddenClass","expandedBreadcrumbs","transitionendHandler","event","propertyName","target","setLastParentCollapsedBackBreadcrumb","revertLastParentCollapsedBreadcrumb","resizeObserverCallback","currSize","deviceSize","DEVICE_SIZES","S","runResizeObserver","ResizeObserver","getCurrentDeviceSize","observe","XL","componentWillLoad","checkResizeObserver","disconnectedCallback","removeEventListener","render","h","Host","class","back"],"sources":["src/components/ic-breadcrumb-group/ic-breadcrumb-group.css?tag=ic-breadcrumb-group&encapsulation=shadow","src/components/ic-breadcrumb-group/ic-breadcrumb-group.tsx"],"sourcesContent":[":host {\n display: block;\n}\n\n:host ol {\n display: flex;\n list-style-type: none;\n align-items: center;\n flex-wrap: wrap;\n padding: 0;\n margin: 0;\n}\n\n:host(.back) ol ::slotted(ic-breadcrumb) {\n display: none;\n}\n\n:host(.back) ol ::slotted(ic-breadcrumb.show) {\n display: flex;\n}\n\n:host(.collapsed) ol ::slotted(ic-breadcrumb.hide) {\n display: none;\n opacity: 0;\n visibility: hidden;\n}\n\n:host(.collapsed) ol ::slotted(ic-breadcrumb.visuallyhidden) {\n display: block;\n opacity: 0;\n transition: all var(--ic-easing-transition-slow);\n}\n\n:host(.collapsed) ol ::slotted(ic-breadcrumb.fade) {\n opacity: 1;\n}\n","import { Component, Host, h, Element, Prop, State } from \"@stencil/core\";\nimport {\n checkResizeObserver,\n DEVICE_SIZES,\n getCurrentDeviceSize,\n} from \"../../utils/helpers\";\n\n@Component({\n tag: \"ic-breadcrumb-group\",\n styleUrl: \"ic-breadcrumb-group.css\",\n shadow: true,\n})\n\n// Added ResizeObserver to find out width of breadcrumbs and parents. Use side navigation long title for ref.\nexport class BreadcrumbGroup {\n private ADD_CLASS_DELAY = 50;\n private breadcrumb: HTMLIcBreadcrumbElement;\n private breadcrumbs: HTMLIcBreadcrumbElement[];\n private collapsedBreadcrumbEl: HTMLButtonElement;\n private collapsedBreadcrumbs: HTMLIcBreadcrumbElement[];\n private collapsedBreadcrumbWrapper: HTMLIcBreadcrumbElement;\n private IC_BREADCRUMB: string = \"ic-breadcrumb\";\n private resizeObserver: ResizeObserver = null;\n private SHOW_BACK_ICON: string = \"show-back-icon\";\n\n @Element() el: HTMLIcBreadcrumbGroupElement;\n\n @State() deviceSize: number = DEVICE_SIZES.XL;\n @State() expandedBreadcrumbs: boolean = false;\n\n /**\n * If `true`, display only a single breadcrumb for the parent page with a back icon.\n */\n @Prop() backBreadcrumbOnly: boolean = false;\n /**\n * If `true`, all breadcrumbs between the first and last breadcrumb will be collapsed.\n */\n @Prop() collapsed: boolean = false;\n\n componentWillLoad(): void {\n const allBreadcrumbs = Array.from(\n this.el.querySelectorAll(this.IC_BREADCRUMB)\n );\n\n if (this.backBreadcrumbOnly) {\n this.setBackBreadcrumb();\n } else {\n checkResizeObserver(this.runResizeObserver);\n }\n\n if (this.collapsed) {\n this.collapsedBreadcrumbWrapper = this.renderCollapsedBreadcrumb();\n\n if (allBreadcrumbs.length > 2) {\n if (getCurrentDeviceSize() === DEVICE_SIZES.S) {\n this.setLastParentCollapsedBackBreadcrumb();\n } else {\n this.setCollapsed();\n }\n }\n }\n }\n\n disconnectedCallback(): void {\n this.breadcrumb.removeEventListener(\n \"transitionend\",\n this.transitionendHandler\n );\n this.collapsedBreadcrumbEl.removeEventListener(\"click\", this.clickHandler);\n }\n\n private setBackBreadcrumb = () => {\n if (this.backBreadcrumbOnly) {\n this.setBackBreadcrumbAttr();\n }\n };\n\n private setBackBreadcrumbAttr = () => {\n if (this.lastParentBreadcrumb) {\n this.lastParentBreadcrumb.classList.add(\"show\");\n this.lastParentBreadcrumb.setAttribute(this.SHOW_BACK_ICON, \"true\");\n }\n };\n\n private getLastParentBreadcrumb = (): HTMLIcBreadcrumbElement | null => {\n const allBreadcrumbs: HTMLIcBreadcrumbElement[] = Array.from(\n this.el.querySelectorAll(this.IC_BREADCRUMB)\n );\n\n if (allBreadcrumbs.length === 1) {\n return null;\n }\n\n this.breadcrumbs = allBreadcrumbs.filter(\n (breadcrumb) => !breadcrumb.getAttribute(\"current\")\n );\n this.breadcrumb = this.breadcrumbs[this.breadcrumbs.length - 1];\n\n return this.breadcrumb;\n };\n\n private lastParentBreadcrumb = this.getLastParentBreadcrumb();\n\n private setDefaultBreadcrumbs = () => {\n const allBreadcrumbs = Array.from(\n this.el.querySelectorAll(this.IC_BREADCRUMB)\n );\n allBreadcrumbs.forEach((breadcrumb) => {\n breadcrumb.setAttribute(this.SHOW_BACK_ICON, \"false\");\n });\n };\n\n private setCollapsed = () => {\n if (this.collapsed) {\n const allBreadcrumbs: HTMLIcBreadcrumbElement[] = Array.from(\n this.el.querySelectorAll(this.IC_BREADCRUMB)\n );\n this.collapsedBreadcrumbs = allBreadcrumbs\n .splice(1, allBreadcrumbs.length - 2)\n .filter(\n (breadcrumb) =>\n !breadcrumb.classList.contains(\"collapsed-breadcrumb-wrapper\")\n );\n\n this.collapsedBreadcrumbs.forEach((breadcrumb) =>\n breadcrumb.classList.add(\"hide\")\n );\n\n const firstBreadcrumb = allBreadcrumbs[0];\n\n if (firstBreadcrumb) {\n firstBreadcrumb.insertAdjacentElement(\n \"afterend\",\n this.collapsedBreadcrumbWrapper\n );\n }\n }\n };\n\n private clickHandler = () => {\n this.handleHiddenCollapsedBreadcrumbs(this.collapsedBreadcrumbWrapper);\n };\n\n private renderCollapsedBreadcrumb = () => {\n this.collapsedBreadcrumbWrapper = document.createElement(\"ic-breadcrumb\");\n this.collapsedBreadcrumbWrapper.classList.add(\n \"collapsed-breadcrumb-wrapper\"\n );\n this.collapsedBreadcrumbEl = document.createElement(\"button\");\n\n const ariaLabel = document.createElement(\"span\");\n ariaLabel.id = \"collapsed-button-label\";\n ariaLabel.innerText = \"Collapsed breadcrumbs\";\n ariaLabel.className = \"hide\";\n this.collapsedBreadcrumbEl.setAttribute(\n \"aria-labelledby\",\n \"collapsed-button-label\"\n );\n\n const ariaDescribed = document.createElement(\"span\");\n ariaDescribed.id = \"collapsed-button-described\";\n ariaDescribed.innerText = \"Select to view collapsed breadcrumbs\";\n ariaDescribed.className = \"hide\";\n this.collapsedBreadcrumbEl.setAttribute(\n \"aria-describedby\",\n \"collapsed-button-described\"\n );\n\n this.collapsedBreadcrumbEl.id = \"collapsed-ellipsis\";\n this.collapsedBreadcrumbEl.innerText = \"...\";\n this.collapsedBreadcrumbEl.classList.add(\"collapsed-breadcrumb\");\n this.collapsedBreadcrumbEl.addEventListener(\"click\", this.clickHandler);\n\n this.collapsedBreadcrumbWrapper.append(ariaDescribed);\n this.collapsedBreadcrumbWrapper.append(ariaLabel);\n this.collapsedBreadcrumbWrapper.append(this.collapsedBreadcrumbEl);\n\n return this.collapsedBreadcrumbWrapper;\n };\n\n private handleHiddenCollapsedBreadcrumbs = (\n collapsedBreadcrumbWrapper: HTMLIcBreadcrumbElement\n ) => {\n collapsedBreadcrumbWrapper.remove();\n this.collapsedBreadcrumbs.forEach((breadcrumb) => {\n breadcrumb.classList.add(\"visuallyhidden\");\n breadcrumb.classList.remove(\"hide\");\n setTimeout(() => {\n breadcrumb.classList.add(\"fade\");\n }, this.ADD_CLASS_DELAY);\n\n this.removeVisuallyHiddenClass(breadcrumb);\n });\n this.expandedBreadcrumbs = true;\n };\n\n private transitionendHandler = (event: TransitionEvent) => {\n if (event.propertyName === \"opacity\") {\n (event.target as HTMLElement).classList.remove(\"visuallyhidden\");\n }\n };\n\n private removeVisuallyHiddenClass = (breadcrumb: HTMLIcBreadcrumbElement) => {\n breadcrumb.addEventListener(\"transitionend\", this.transitionendHandler);\n };\n\n private setLastParentCollapsedBackBreadcrumb = () => {\n this.setBackBreadcrumbAttr();\n this.lastParentBreadcrumb.classList.remove(\"hide\");\n };\n\n private revertLastParentCollapsedBreadcrumb = () => {\n this.lastParentBreadcrumb.setAttribute(this.SHOW_BACK_ICON, \"false\");\n };\n\n private resizeObserverCallback = (currSize: number) => {\n if (currSize !== this.deviceSize) {\n this.deviceSize = currSize;\n\n if (this.deviceSize <= DEVICE_SIZES.S) {\n this.el.setAttribute(\"back-breadcrumb-only\", \"true\");\n if (this.collapsed) {\n this.setLastParentCollapsedBackBreadcrumb();\n } else {\n this.setBackBreadcrumb();\n }\n } else {\n this.el.setAttribute(\"back-breadcrumb-only\", \"false\");\n if (this.collapsed && this.breadcrumbs && this.breadcrumbs.length > 2) {\n this.revertLastParentCollapsedBreadcrumb();\n if (this.expandedBreadcrumbs) {\n this.setDefaultBreadcrumbs();\n } else {\n this.setCollapsed();\n }\n } else {\n this.setDefaultBreadcrumbs();\n }\n }\n }\n };\n\n private runResizeObserver = () => {\n this.resizeObserver = new ResizeObserver(() => {\n const currSize = getCurrentDeviceSize();\n this.resizeObserverCallback(currSize);\n });\n\n this.resizeObserver.observe(this.el);\n };\n\n render() {\n return (\n <Host\n class={{\n back: this.backBreadcrumbOnly,\n collapsed: this.collapsed,\n }}\n >\n <nav aria-label=\"breadcrumbs\">\n <ol>\n <slot />\n </ol>\n </nav>\n </Host>\n );\n }\n}\n"],"mappings":"mIAAA,MAAMA,EAAuB,sgB,MCchBC,EAAe,M,yBAClBC,KAAAC,gBAAkB,GAMlBD,KAAAE,cAAwB,gBACxBF,KAAAG,eAAiC,KACjCH,KAAAI,eAAyB,iBAgDzBJ,KAAAK,kBAAoB,KAC1B,GAAIL,KAAKM,mBAAoB,CAC3BN,KAAKO,uB,GAIDP,KAAAO,sBAAwB,KAC9B,GAAIP,KAAKQ,qBAAsB,CAC7BR,KAAKQ,qBAAqBC,UAAUC,IAAI,QACxCV,KAAKQ,qBAAqBG,aAAaX,KAAKI,eAAgB,O,GAIxDJ,KAAAY,wBAA0B,KAChC,MAAMC,EAA4CC,MAAMC,KACtDf,KAAKgB,GAAGC,iBAAiBjB,KAAKE,gBAGhC,GAAIW,EAAeK,SAAW,EAAG,CAC/B,OAAO,I,CAGTlB,KAAKmB,YAAcN,EAAeO,QAC/BC,IAAgBA,EAAWC,aAAa,aAE3CtB,KAAKqB,WAAarB,KAAKmB,YAAYnB,KAAKmB,YAAYD,OAAS,GAE7D,OAAOlB,KAAKqB,UAAU,EAGhBrB,KAAAQ,qBAAuBR,KAAKY,0BAE5BZ,KAAAuB,sBAAwB,KAC9B,MAAMV,EAAiBC,MAAMC,KAC3Bf,KAAKgB,GAAGC,iBAAiBjB,KAAKE,gBAEhCW,EAAeW,SAASH,IACtBA,EAAWV,aAAaX,KAAKI,eAAgB,QAAQ,GACrD,EAGIJ,KAAAyB,aA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T,K,CAE7B,iBAAAC,GACE,MAAMrD,EAAiBC,MAAMC,KAC3Bf,KAAKgB,GAAGC,iBAAiBjB,KAAKE,gBAGhC,GAAIF,KAAKM,mBAAoB,CAC3BN,KAAKK,mB,KACA,CACL8D,EAAoBnE,KAAK6D,kB,CAG3B,GAAI7D,KAAK0B,UAAW,CAClB1B,KAAKgC,2BAA6BhC,KAAKmC,4BAEvC,GAAItB,EAAeK,OAAS,EAAG,CAC7B,GAAI6C,MAA2BJ,EAAaC,EAAG,CAC7C5D,KAAKsD,sC,KACA,CACLtD,KAAKyB,c,IAMb,oBAAA2C,GACEpE,KAAKqB,WAAWgD,oBACd,gBACArE,KAAKkD,sBAEPlD,KAAKsC,sBAAsB+B,oBAAoB,QAASrE,KAAKiC,a,CAuL/D,MAAAqC,GACE,OACEC,EAACC,EAAI,CACHC,MAAO,CACLC,KAAM1E,KAAKM,mBACXoB,UAAW1B,KAAK0B,YAGlB6C,EAAA,oBAAgB,eACdA,EAAA,UACEA,EAAA,e"}
@@ -1,2 +1,2 @@
1
- import{r as t,h as i,H as e,g as o}from"./p-69920d86.js";import{c as s}from"./p-dd980be4.js";import"./p-6f57b13c.js";const a='/*! 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-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:var(--ic-space-xxs) solid !important;margin-bottom:calc(-1 * var(--ic-space-xxs)) !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-decoration-thickness: 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}}';const r=class{constructor(i){t(this,i);this.focusBtnFromKeyboard=true;this.lastMarkerTop=0;this.lastWidth=0;this.resizeObserver=null;this.truncatedHeight=0;this.toggleExpanded=()=>{this.expanded=!this.expanded};this.checkMaxLines=t=>{const i=Math.floor(t/24);if(i>this.maxLines){this.el.setAttribute("style",`--truncation-max-lines: ${this.maxLines}`);this.truncatedHeight=this.el.clientHeight;this.truncated=true}};this.checkMarkerPosition=(t,i)=>{if(i-t<this.truncatedHeight){this.truncated=false;this.expanded=false}else{this.truncated=true}};this.getElementTop=t=>t.getClientRects?t.getClientRects()[0].top:0;this.runResizeObserver=()=>{this.resizeObserver=new ResizeObserver((()=>{clearTimeout(this.resizeInterval);this.resizeInterval=window.setTimeout(this.resizeObserverCallback,50)}));this.resizeObserver.observe(this.truncWrapperEl)};this.resizeObserverCallback=()=>{if(this.lastWidth===this.el.clientWidth){return}if(this.truncatedHeight===0){this.checkMaxLines(this.el.clientHeight);return}const t=this.getElementTop(this.marker);if(t===this.lastMarkerTop){return}this.checkMarkerPosition(this.getElementTop(this.el),t);this.lastMarkerTop=t;this.lastWidth=this.el.clientWidth};this.truncButtonFocus=()=>{if(this.focusBtnFromKeyboard){this.truncButtonFocussed=true}};this.truncButtonBlur=()=>{this.focusBtnFromKeyboard=true;this.truncButtonFocussed=false};this.truncButtonFocusFromMouse=()=>{this.focusBtnFromKeyboard=false};this.truncated=false;this.truncButtonFocussed=false;this.applyVerticalMargins=false;this.bold=false;this.italic=false;this.maxLines=undefined;this.strikethrough=false;this.underline=false;this.variant="body";this.expanded=false}watchExpandedHandler(){this.el.setAttribute("style",`--truncation-max-lines: ${this.expanded?"initial":this.maxLines}`)}disconnectedCallback(){if(this.resizeObserver!==null){this.resizeObserver.disconnect()}}componentDidLoad(){if(this.variant==="body"&&this.maxLines>0){const t=document.createElement("span");t.style.visibility="hidden";this.el.appendChild(t);this.marker=t;this.lastWidth=this.el.clientWidth;this.checkMaxLines(this.el.clientHeight);s(this.runResizeObserver)}}render(){const{variant:t,applyVerticalMargins:o,maxLines:s,truncated:a,expanded:r,strikethrough:n,underline:c,italic:l,bold:h}=this;return i(e,{class:{[`ic-typography-${t}`]:true,[`ic-typography-vertical-margins-${t}`]:o,["bold"]:h,["italic"]:l,["strikethrough"]:n,["underline"]:c}},t==="body"&&s>0?i("div",{class:"trunc-wrapper",ref:t=>this.truncWrapperEl=t},i("slot",null)):i("slot",null),t==="body"&&s>0&&a&&i("button",{class:{"trunc-btn":true,focus:this.truncButtonFocussed},onFocus:this.truncButtonFocus,onBlur:this.truncButtonBlur,onMouseDown:this.truncButtonFocusFromMouse,onClick:this.toggleExpanded,"aria-hidden":"true"},r?"See less":"See more"))}get el(){return o(this)}static get watchers(){return{expanded:["watchExpandedHandler"]}}};r.style=a;export{r as ic_typography};
2
- //# sourceMappingURL=p-5e3a09d7.entry.js.map
1
+ import{r as t,h as i,H as e,g as o}from"./p-18068237.js";import{c as a}from"./p-ebe76390.js";import"./p-613aa265.js";const s='/*! 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-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:var(--ic-space-xxs) solid !important;margin-bottom:calc(-1 * var(--ic-space-xxs)) !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-decoration-thickness: 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}}';const r=class{constructor(i){t(this,i);this.focusBtnFromKeyboard=true;this.lastMarkerTop=0;this.lastWidth=0;this.resizeObserver=null;this.truncatedHeight=0;this.toggleExpanded=()=>{this.expanded=!this.expanded};this.checkMaxLines=t=>{const i=Math.floor(t/24);if(i>this.maxLines){this.el.setAttribute("style",`--truncation-max-lines: ${this.maxLines}`);this.truncatedHeight=this.el.clientHeight;this.truncated=true}};this.checkMarkerPosition=(t,i)=>{if(i-t<this.truncatedHeight){this.truncated=false;this.expanded=false}else{this.truncated=true}};this.getElementTop=t=>t.getClientRects?t.getClientRects()[0].top:0;this.runResizeObserver=()=>{this.resizeObserver=new ResizeObserver((()=>{clearTimeout(this.resizeInterval);this.resizeInterval=window.setTimeout(this.resizeObserverCallback,50)}));this.resizeObserver.observe(this.truncWrapperEl)};this.resizeObserverCallback=()=>{if(this.lastWidth===this.el.clientWidth){return}if(this.truncatedHeight===0){this.checkMaxLines(this.el.clientHeight);return}const t=this.getElementTop(this.marker);if(t===this.lastMarkerTop){return}this.checkMarkerPosition(this.getElementTop(this.el),t);this.lastMarkerTop=t;this.lastWidth=this.el.clientWidth};this.truncButtonFocus=()=>{if(this.focusBtnFromKeyboard){this.truncButtonFocussed=true}};this.truncButtonBlur=()=>{this.focusBtnFromKeyboard=true;this.truncButtonFocussed=false};this.truncButtonFocusFromMouse=()=>{this.focusBtnFromKeyboard=false};this.truncated=false;this.truncButtonFocussed=false;this.applyVerticalMargins=false;this.bold=false;this.italic=false;this.maxLines=undefined;this.strikethrough=false;this.underline=false;this.variant="body";this.expanded=false}watchExpandedHandler(){this.el.setAttribute("style",`--truncation-max-lines: ${this.expanded?"initial":this.maxLines}`)}disconnectedCallback(){if(this.resizeObserver!==null){this.resizeObserver.disconnect()}}componentDidLoad(){if(this.variant==="body"&&this.maxLines>0){const t=document.createElement("span");t.style.visibility="hidden";this.el.appendChild(t);this.marker=t;this.lastWidth=this.el.clientWidth;this.checkMaxLines(this.el.clientHeight);a(this.runResizeObserver)}}render(){const{variant:t,applyVerticalMargins:o,maxLines:a,truncated:s,expanded:r,strikethrough:n,underline:c,italic:l,bold:h}=this;return i(e,{class:{[`ic-typography-${t}`]:true,[`ic-typography-vertical-margins-${t}`]:o,["bold"]:h,["italic"]:l,["strikethrough"]:n,["underline"]:c}},t==="body"&&a>0?i("div",{class:"trunc-wrapper",ref:t=>this.truncWrapperEl=t},i("slot",null)):i("slot",null),t==="body"&&a>0&&s&&i("button",{class:{"trunc-btn":true,focus:this.truncButtonFocussed},onFocus:this.truncButtonFocus,onBlur:this.truncButtonBlur,onMouseDown:this.truncButtonFocusFromMouse,onClick:this.toggleExpanded,"aria-hidden":"true"},r?"See less":"See more"))}get el(){return o(this)}static get watchers(){return{expanded:["watchExpandedHandler"]}}};r.style=s;export{r as ic_typography};
2
+ //# sourceMappingURL=p-521c8f40.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["icTypographyCss","Typography","this","focusBtnFromKeyboard","lastMarkerTop","lastWidth","resizeObserver","truncatedHeight","toggleExpanded","expanded","checkMaxLines","height","numLines","Math","floor","maxLines","el","setAttribute","clientHeight","truncated","checkMarkerPosition","elTop","markerTop","getElementTop","getClientRects","top","runResizeObserver","ResizeObserver","clearTimeout","resizeInterval","window","setTimeout","resizeObserverCallback","observe","truncWrapperEl","clientWidth","marker","truncButtonFocus","truncButtonFocussed","truncButtonBlur","truncButtonFocusFromMouse","watchExpandedHandler","disconnectedCallback","disconnect","componentDidLoad","variant","document","createElement","style","visibility","appendChild","checkResizeObserver","render","applyVerticalMargins","strikethrough","underline","italic","bold","h","Host","class","ref","focus","onFocus","onBlur","onMouseDown","onClick"],"sources":["src/components/ic-typography/ic-typography.css?tag=ic-typography&encapsulation=shadow","src/components/ic-typography/ic-typography.tsx"],"sourcesContent":["@import \"../../global/normalize.css\";\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-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: var(--ic-space-xxs) solid !important;\n margin-bottom: calc(-1 * var(--ic-space-xxs)) !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-decoration-thickness: 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","import { Component, Prop, h, Element, Host, State, Watch } from \"@stencil/core\";\n\nimport { IcTypographyVariants } from \"../../utils/types\";\nimport { checkResizeObserver } from \"../../utils/helpers\";\n\n@Component({\n styleUrl: \"ic-typography.css\",\n tag: \"ic-typography\",\n shadow: true,\n})\nexport class Typography {\n private focusBtnFromKeyboard: boolean = true;\n private lastMarkerTop: number = 0;\n private lastWidth: number = 0;\n private marker: HTMLElement;\n private resizeInterval: number;\n private resizeObserver: ResizeObserver = null;\n private truncatedHeight: number = 0;\n private truncWrapperEl: Element;\n\n @Element() el: HTMLIcTypographyElement;\n\n @State() truncated: boolean = false;\n @State() truncButtonFocussed: boolean = false;\n\n /**\n * If `true`, appropriate top and bottom margins will be applied to the typography.\n */\n @Prop() applyVerticalMargins?: boolean = false;\n\n /**\n * If `true`, the typography will have a bold font weight.\n * Note: This will have no impact on variants that already use an equivalent or higher font weight (h1, h2, and subtitle-large).\n */\n @Prop() bold?: boolean = false;\n\n /**\n * If `true`, the typography will have an italic font style.\n */\n @Prop() italic?: boolean = false;\n\n /**\n * The number of lines to display before truncating the text, only used for the 'body' variant.\n */\n @Prop() maxLines?: number;\n\n /**\n * If `true`, the typography will have a line through it.\n */\n @Prop() strikethrough?: boolean = false;\n\n /**\n * If `true`, the typography will have a line under it.\n */\n @Prop() underline?: boolean = false;\n\n /**\n * The ICDS typography style to use.\n */\n @Prop() variant?: IcTypographyVariants = \"body\";\n\n @State() expanded: boolean = false;\n\n @Watch(\"expanded\")\n watchExpandedHandler(): void {\n this.el.setAttribute(\n \"style\",\n `--truncation-max-lines: ${this.expanded ? \"initial\" : this.maxLines}`\n );\n }\n\n disconnectedCallback(): void {\n if (this.resizeObserver !== null) {\n this.resizeObserver.disconnect();\n }\n }\n\n componentDidLoad(): void {\n if (this.variant === \"body\" && 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\n private toggleExpanded = () => {\n this.expanded = !this.expanded;\n };\n\n private checkMaxLines = (height: number) => {\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 private checkMarkerPosition = (elTop: number, markerTop: number) => {\n if (markerTop - elTop < this.truncatedHeight) {\n this.truncated = false;\n this.expanded = false;\n } else {\n this.truncated = true;\n }\n };\n\n private getElementTop = (el: HTMLElement) => {\n return el.getClientRects ? el.getClientRects()[0].top : 0;\n };\n\n private 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\n private resizeObserverCallback = () => {\n if (this.lastWidth === this.el.clientWidth) {\n return;\n }\n\n if (this.truncatedHeight === 0) {\n this.checkMaxLines(this.el.clientHeight);\n return;\n }\n\n const markerTop = this.getElementTop(this.marker);\n if (markerTop === this.lastMarkerTop) {\n return;\n }\n\n this.checkMarkerPosition(this.getElementTop(this.el), markerTop);\n this.lastMarkerTop = markerTop;\n this.lastWidth = this.el.clientWidth;\n };\n\n private truncButtonFocus = (): void => {\n if (this.focusBtnFromKeyboard) {\n this.truncButtonFocussed = true;\n }\n };\n\n private truncButtonBlur = (): void => {\n this.focusBtnFromKeyboard = true;\n this.truncButtonFocussed = false;\n };\n\n private truncButtonFocusFromMouse = (): void => {\n this.focusBtnFromKeyboard = false;\n };\n\n render() {\n const {\n variant,\n applyVerticalMargins,\n maxLines,\n truncated,\n expanded,\n strikethrough,\n underline,\n italic,\n bold,\n } = this;\n\n return (\n <Host\n 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 }}\n >\n {variant === \"body\" && maxLines > 0 ? (\n <div class=\"trunc-wrapper\" ref={(el) => (this.truncWrapperEl = el)}>\n <slot />\n </div>\n ) : (\n <slot />\n )}\n {variant === \"body\" && maxLines > 0 && truncated && (\n <button\n class={{ \"trunc-btn\": true, focus: this.truncButtonFocussed }}\n onFocus={this.truncButtonFocus}\n onBlur={this.truncButtonBlur}\n onMouseDown={this.truncButtonFocusFromMouse}\n onClick={this.toggleExpanded}\n aria-hidden=\"true\"\n >\n {expanded ? \"See less\" : \"See more\"}\n </button>\n )}\n </Host>\n );\n }\n}\n"],"mappings":"qHAAA,MAAMA,EAAkB,0mM,MCUXC,EAAU,M,yBACbC,KAAAC,qBAAgC,KAChCD,KAAAE,cAAwB,EACxBF,KAAAG,UAAoB,EAGpBH,KAAAI,eAAiC,KACjCJ,KAAAK,gBAA0B,EAwE1BL,KAAAM,eAAiB,KACvBN,KAAKO,UAAYP,KAAKO,QAAQ,EAGxBP,KAAAQ,cAAiBC,IAEvB,MAAMC,EAAWC,KAAKC,MAAMH,EAAS,IACrC,GAAIC,EAAWV,KAAKa,SAAU,CAC5Bb,KAAKc,GAAGC,aAAa,QAAS,2BAA2Bf,KAAKa,YAC9Db,KAAKK,gBAAkBL,KAAKc,GAAGE,aAC/BhB,KAAKiB,UAAY,I,GAIbjB,KAAAkB,oBAAsB,CAACC,EAAeC,KAC5C,GAAIA,EAAYD,EAAQnB,KAAKK,gBAAiB,CAC5CL,KAAKiB,UAAY,MACjBjB,KAAKO,SAAW,K,KACX,CACLP,KAAKiB,UAAY,I,GAIbjB,KAAAqB,cAAiBP,GAChBA,EAAGQ,eAAiBR,EAAGQ,iBAAiB,GAAGC,IAAM,EAGlDvB,KAAAwB,kBAAoB,KAC1BxB,KAAKI,eAAiB,IAAIqB,gBAAe,KACvCC,aAAa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cAAcR,KAAKc,GAAGE,cAC3BiC,EAAoBjD,KAAKwB,kB,EA0E7B,MAAA0B,GACE,MAAMP,QACJA,EAAOQ,qBACPA,EAAoBtC,SACpBA,EAAQI,UACRA,EAASV,SACTA,EAAQ6C,cACRA,EAAaC,UACbA,EAASC,OACTA,EAAMC,KACNA,GACEvD,KAEJ,OACEwD,EAACC,EAAI,CACHC,MAAO,CACL,CAAC,iBAAiBf,KAAY,KAC9B,CAAC,kCAAkCA,KAAYQ,EAC/C,CAAC,QAASI,EACV,CAAC,UAAWD,EACZ,CAAC,iBAAkBF,EACnB,CAAC,aAAcC,IAGhBV,IAAY,QAAU9B,EAAW,EAChC2C,EAAA,OAAKE,MAAM,gBAAgBC,IAAM7C,GAAQd,KAAKgC,eAAiBlB,GAC7D0C,EAAA,cAGFA,EAAA,aAEDb,IAAY,QAAU9B,EAAW,GAAKI,GACrCuC,EAAA,UACEE,MAAO,CAAE,YAAa,KAAME,MAAO5D,KAAKoC,qBACxCyB,QAAS7D,KAAKmC,iBACd2B,OAAQ9D,KAAKqC,gBACb0B,YAAa/D,KAAKsC,0BAClB0B,QAAShE,KAAKM,eAAc,cAChB,QAEXC,EAAW,WAAa,Y"}
@@ -1,2 +1,2 @@
1
- import{r as t,c as s,h as i,g as h}from"./p-69920d86.js";import{I as e}from"./p-6f57b13c.js";const a=class{constructor(i){t(this,i);this.icTabSelect=s(this,"icTabSelect",3);this.tabSelect=s(this,"tabSelect",3);this.newTabPanels=[];this.newTabs=[];this.linkTabs=()=>{this.tabs.forEach(((t,s)=>{const i=`ic-tab-${s}-context-${this.contextId}`;const h=`ic-tab-panel-${s}-context-${this.contextId}`;const a=`ic-tab--${s}-context-${this.contextId}`;const c="context-id";t.setAttribute("id",i);t.tabId=a;t.tabPosition=s;t.setAttribute("aria-controls",h);t.setAttribute(c,this.contextId);this.tabGroup.setAttribute(c,this.contextId);this.tabPanels[s].setAttribute("id",h);this.tabPanels[s].panelId=a;this.tabPanels[s].tabPosition=s;this.tabPanels[s].setAttribute("aria-labelledby",i);this.tabPanels[s].setAttribute(c,this.contextId);if(this.appearance===e.Light){t.appearance=this.appearance;this.tabPanels[s].appearance=this.appearance}}));if(this.appearance===e.Light){this.tabGroup.appearance=this.appearance}};this.getChildren=()=>{this.tabGroup=this.host.querySelector("ic-tab-group");this.tabs=Array.from(this.tabGroup.querySelectorAll("ic-tab"));this.tabPanels=Array.from(this.host.children).filter((t=>t.tagName==="IC-TAB-PANEL"));this.enabledTabs=this.getEnabledTabs()};this.keydownHandler=t=>{if(this.activationType==="automatic"){this.handleKeyBoardNavAutomatic(t)}else{this.handleKeyBoardNavManual(t)}};this.attatchEventListeners=()=>{this.tabGroup.addEventListener("keydown",this.keydownHandler)};this.setControlledMode=()=>{if(this.selectedTabIndex!==undefined){this.controlledMode=true;this.selectedTab=this.selectedTabIndex}};this.setInitialTab=()=>{if(this.controlledMode){this.selectedTab=this.selectedTabIndex;this.focusedTabIndex=this.selectedTabIndex}else{const t=this.tabs.findIndex((t=>t.tabId===this.enabledTabs[0].tabId));this.selectedTab=t;this.focusedTabIndex=t}};this.configureTabs=()=>{this.enabledTabs.forEach((t=>{t.selected=t.tabPosition===this.selectedTab}));this.tabPanels.forEach((t=>{t.selectedTab=this.tabs[this.selectedTab].tabId}))};this.getEnabledTabs=()=>Array.from(this.tabs).filter((t=>!t.disabled));this.getIndexOfEnabledTab=t=>this.enabledTabs.findIndex((s=>s.tabId===this.tabs[t].tabId));this.keyboardSelectTab=t=>{const s=this.tabs.findIndex((s=>s.tabId===this.enabledTabs[t].tabId));this.enabledTabs[t].focus();if(!this.controlledMode){this.selectedTab=s}else{this.icTabSelect.emit({tabIndex:s});this.tabSelect.emit({tabIndex:s})}};this.keyboardFocusTab=t=>{const s=this.tabs.findIndex((s=>s.tabId===this.enabledTabs[t].tabId));this.enabledTabs[t].focus();this.focusedTabIndex=s};this.handleKeyBoardNavAutomatic=t=>{const s=t.key;const i=this.getIndexOfEnabledTab(this.selectedTab);let h=true;switch(s){case"Home":this.keyboardSelectTab(0);break;case"End":this.keyboardSelectTab(this.enabledTabs.length-1);break;case"ArrowRight":if(i<this.enabledTabs.length-1){this.keyboardSelectTab(i+1)}else{this.keyboardSelectTab(0)}break;case"ArrowLeft":if(i>0){this.keyboardSelectTab(i-1)}else{this.keyboardSelectTab(this.enabledTabs.length-1)}break;default:h=false}if(h)t.preventDefault()};this.handleKeyBoardNavManual=t=>{const s=t.key;const i=this.getIndexOfEnabledTab(this.focusedTabIndex);let h=true;switch(s){case"Home":this.keyboardFocusTab(0);break;case"End":this.keyboardFocusTab(this.enabledTabs.length-1);break;case"ArrowRight":if(i<this.enabledTabs.length-1){this.keyboardFocusTab(i+1)}else{this.keyboardFocusTab(0)}break;case"ArrowLeft":if(i>0){this.keyboardFocusTab(i-1)}else{this.keyboardFocusTab(this.enabledTabs.length-1)}break;case"Enter":this.keyboardSelectTab(this.focusedTabIndex);break;case" ":this.keyboardSelectTab(this.focusedTabIndex);break;default:h=false}if(h)t.preventDefault()};this.selectedTab=undefined;this.activationType="automatic";this.appearance="dark";this.contextId="default";this.selectedTabIndex=undefined}updateSelectedTab(t){this.selectedTab=t}componentDidLoad(){this.setControlledMode();this.getChildren();this.linkTabs();this.attatchEventListeners();this.setInitialTab();this.configureTabs()}componentWillUpdate(){this.configureTabs()}disconnectedCallback(){this.tabGroup.removeEventListener("keydown",this.keydownHandler)}tabClickHandler(t){if(this.selectedTabIndex===undefined&&t.detail.contextId===this.contextId){this.selectedTab=t.detail.position}this.icTabSelect.emit({tabIndex:t.detail.position});this.tabSelect.emit({tabIndex:t.detail.position});t.stopImmediatePropagation()}tabCreatedHandler(t){if(this.tabs&&this.tabPanels){(t.detail.setFocus?this.newTabs:this.newTabPanels).push(t.detail);if(this.newTabs.length===this.newTabPanels.length){this.tabs.push(...this.newTabs);this.tabPanels.push(...this.newTabPanels);this.enabledTabs=this.getEnabledTabs();this.linkTabs();this.newTabs=[];this.newTabPanels=[]}}}tabEnabledHandler(){this.enabledTabs=this.getEnabledTabs()}async tabRemovedHandler(t){this.getChildren();this.enabledTabs=this.getEnabledTabs();this.linkTabs();if(this.tabs[this.selectedTab]&&this.tabPanels[this.selectedTab]){this.tabs[this.selectedTab].selected=true;this.tabPanels[this.selectedTab].selectedTab=this.tabs[this.selectedTab].tabId}else{this.setInitialTab()}if(t){this.tabs[this.selectedTab].setFocus()}}render(){return i("slot",null)}get host(){return h(this)}static get watchers(){return{selectedTabIndex:["updateSelectedTab"]}}};export{a as ic_tab_context};
2
- //# sourceMappingURL=p-041604fc.entry.js.map
1
+ import{r as t,c as s,h as i,g as h}from"./p-18068237.js";import{I as e}from"./p-613aa265.js";const a=class{constructor(i){t(this,i);this.icTabSelect=s(this,"icTabSelect",3);this.tabSelect=s(this,"tabSelect",3);this.newTabPanels=[];this.newTabs=[];this.linkTabs=()=>{this.tabs.forEach(((t,s)=>{const i=`ic-tab-${s}-context-${this.contextId}`;const h=`ic-tab-panel-${s}-context-${this.contextId}`;const a=`ic-tab--${s}-context-${this.contextId}`;const c="context-id";t.setAttribute("id",i);t.tabId=a;t.tabPosition=s;t.setAttribute("aria-controls",h);t.setAttribute(c,this.contextId);this.tabGroup.setAttribute(c,this.contextId);this.tabPanels[s].setAttribute("id",h);this.tabPanels[s].panelId=a;this.tabPanels[s].tabPosition=s;this.tabPanels[s].setAttribute("aria-labelledby",i);this.tabPanels[s].setAttribute(c,this.contextId);if(this.appearance===e.Light){t.appearance=this.appearance;this.tabPanels[s].appearance=this.appearance}}));if(this.appearance===e.Light){this.tabGroup.appearance=this.appearance}};this.getChildren=()=>{this.tabGroup=this.host.querySelector("ic-tab-group");this.tabs=Array.from(this.tabGroup.querySelectorAll("ic-tab"));this.tabPanels=Array.from(this.host.children).filter((t=>t.tagName==="IC-TAB-PANEL"));this.enabledTabs=this.getEnabledTabs()};this.keydownHandler=t=>{if(this.activationType==="automatic"){this.handleKeyBoardNavAutomatic(t)}else{this.handleKeyBoardNavManual(t)}};this.attatchEventListeners=()=>{this.tabGroup.addEventListener("keydown",this.keydownHandler)};this.setControlledMode=()=>{if(this.selectedTabIndex!==undefined){this.controlledMode=true;this.selectedTab=this.selectedTabIndex}};this.setInitialTab=()=>{if(this.controlledMode){this.selectedTab=this.selectedTabIndex;this.focusedTabIndex=this.selectedTabIndex}else{const t=this.tabs.findIndex((t=>t.tabId===this.enabledTabs[0].tabId));this.selectedTab=t;this.focusedTabIndex=t}};this.configureTabs=()=>{this.enabledTabs.forEach((t=>{t.selected=t.tabPosition===this.selectedTab}));this.tabPanels.forEach((t=>{t.selectedTab=this.tabs[this.selectedTab].tabId}))};this.getEnabledTabs=()=>Array.from(this.tabs).filter((t=>!t.disabled));this.getIndexOfEnabledTab=t=>this.enabledTabs.findIndex((s=>s.tabId===this.tabs[t].tabId));this.keyboardSelectTab=t=>{const s=this.tabs.findIndex((s=>s.tabId===this.enabledTabs[t].tabId));this.enabledTabs[t].focus();if(!this.controlledMode){this.selectedTab=s}else{this.icTabSelect.emit({tabIndex:s});this.tabSelect.emit({tabIndex:s})}};this.keyboardFocusTab=t=>{const s=this.tabs.findIndex((s=>s.tabId===this.enabledTabs[t].tabId));this.enabledTabs[t].focus();this.focusedTabIndex=s};this.handleKeyBoardNavAutomatic=t=>{const s=t.key;const i=this.getIndexOfEnabledTab(this.selectedTab);let h=true;switch(s){case"Home":this.keyboardSelectTab(0);break;case"End":this.keyboardSelectTab(this.enabledTabs.length-1);break;case"ArrowRight":if(i<this.enabledTabs.length-1){this.keyboardSelectTab(i+1)}else{this.keyboardSelectTab(0)}break;case"ArrowLeft":if(i>0){this.keyboardSelectTab(i-1)}else{this.keyboardSelectTab(this.enabledTabs.length-1)}break;default:h=false}if(h)t.preventDefault()};this.handleKeyBoardNavManual=t=>{const s=t.key;const i=this.getIndexOfEnabledTab(this.focusedTabIndex);let h=true;switch(s){case"Home":this.keyboardFocusTab(0);break;case"End":this.keyboardFocusTab(this.enabledTabs.length-1);break;case"ArrowRight":if(i<this.enabledTabs.length-1){this.keyboardFocusTab(i+1)}else{this.keyboardFocusTab(0)}break;case"ArrowLeft":if(i>0){this.keyboardFocusTab(i-1)}else{this.keyboardFocusTab(this.enabledTabs.length-1)}break;case"Enter":this.keyboardSelectTab(this.focusedTabIndex);break;case" ":this.keyboardSelectTab(this.focusedTabIndex);break;default:h=false}if(h)t.preventDefault()};this.selectedTab=undefined;this.activationType="automatic";this.appearance="dark";this.contextId="default";this.selectedTabIndex=undefined}updateSelectedTab(t){this.selectedTab=t}componentDidLoad(){this.setControlledMode();this.getChildren();this.linkTabs();this.attatchEventListeners();this.setInitialTab();this.configureTabs()}componentWillUpdate(){this.configureTabs()}disconnectedCallback(){this.tabGroup.removeEventListener("keydown",this.keydownHandler)}tabClickHandler(t){if(this.selectedTabIndex===undefined&&t.detail.contextId===this.contextId){this.selectedTab=t.detail.position}this.icTabSelect.emit({tabIndex:t.detail.position});this.tabSelect.emit({tabIndex:t.detail.position});t.stopImmediatePropagation()}tabCreatedHandler(t){if(this.tabs&&this.tabPanels){(t.detail.setFocus?this.newTabs:this.newTabPanels).push(t.detail);if(this.newTabs.length===this.newTabPanels.length){this.tabs.push(...this.newTabs);this.tabPanels.push(...this.newTabPanels);this.enabledTabs=this.getEnabledTabs();this.linkTabs();this.newTabs=[];this.newTabPanels=[]}}}tabEnabledHandler(){this.enabledTabs=this.getEnabledTabs()}async tabRemovedHandler(t){this.getChildren();this.enabledTabs=this.getEnabledTabs();this.linkTabs();if(this.tabs[this.selectedTab]&&this.tabPanels[this.selectedTab]){this.tabs[this.selectedTab].selected=true;this.tabPanels[this.selectedTab].selectedTab=this.tabs[this.selectedTab].tabId}else{this.setInitialTab()}if(t){this.tabs[this.selectedTab].setFocus()}}render(){return i("slot",null)}get host(){return h(this)}static get watchers(){return{selectedTabIndex:["updateSelectedTab"]}}};export{a as ic_tab_context};
2
+ //# sourceMappingURL=p-5b8be53f.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["TabContext","this","newTabPanels","newTabs","linkTabs","tabs","forEach","tab","index","tabId","contextId","tabPanelId","shared","contextIdAttr","setAttribute","tabPosition","tabGroup","tabPanels","panelId","appearance","IcThemeForegroundEnum","Light","getChildren","host","querySelector","Array","from","querySelectorAll","children","filter","child","tagName","enabledTabs","getEnabledTabs","keydownHandler","event","activationType","handleKeyBoardNavAutomatic","handleKeyBoardNavManual","attatchEventListeners","addEventListener","setControlledMode","selectedTabIndex","undefined","controlledMode","selectedTab","setInitialTab","focusedTabIndex","firstEnabledTabIndex","findIndex","configureTabs","selected","tabPanel","disabled","getIndexOfEnabledTab","allTabsIndex","keyboardSelectTab","enabledTabIndex","newIndex","focus","icTabSelect","emit","tabIndex","tabSelect","keyboardFocusTab","key","preventDefault","length","updateSelectedTab","newValue","componentDidLoad","componentWillUpdate","disconnectedCallback","removeEventListener","tabClickHandler","detail","position","stopImmediatePropagation","tabCreatedHandler","ev","setFocus","push","tabEnabledHandler","tabRemovedHandler","hadFocus","render","h"],"sources":["src/components/ic-tab-context/ic-tab-context.tsx"],"sourcesContent":["import {\n Component,\n Element,\n Event,\n EventEmitter,\n Listen,\n Prop,\n State,\n h,\n Watch,\n Method,\n} from \"@stencil/core\";\nimport {\n IcActivationTypes,\n IcThemeForegroundNoDefault,\n IcThemeForegroundEnum,\n} from \"../../utils/types\";\n\nimport {\n IcTabClickEventDetail,\n IcTabSelectEventDetail,\n} from \"../ic-tab/ic-tab.types\";\n\n@Component({\n tag: \"ic-tab-context\",\n})\nexport class TabContext {\n private controlledMode: boolean;\n private enabledTabs: HTMLIcTabElement[];\n private focusedTabIndex: number;\n private newTabPanels: HTMLIcTabPanelElement[] = [];\n private newTabs: HTMLIcTabElement[] = [];\n private tabs: HTMLIcTabElement[];\n private tabGroup: HTMLIcTabGroupElement;\n private tabPanels: HTMLIcTabPanelElement[];\n\n @Element() host: HTMLIcTabContextElement;\n\n @State() selectedTab: number | null;\n\n /**\n * Determines whether tabs have to be manually activated (by pressing 'Enter' or 'Space') when they receive focus using keyboard navigation.\n */\n @Prop() activationType?: IcActivationTypes = \"automatic\";\n\n /**\n * The appearance of the tab context, e.g dark, or light.\n */\n @Prop() appearance?: IcThemeForegroundNoDefault = \"dark\";\n\n /**\n * The unique context needed if using multiple tabs inside one another i.e. rendering another set of tabs inside a tab panel.\n */\n @Prop({ reflect: true }) contextId?: string = \"default\";\n\n /**\n * The selected tab to be controlled by the user. Must be used alongside the icTabSelect event to manage tab selection.\n */\n @Prop() selectedTabIndex?: number;\n\n @Watch(\"selectedTabIndex\")\n updateSelectedTab(newValue: number): void {\n this.selectedTab = newValue;\n }\n\n /**\n * Emitted when a user selects a tab.\n */\n @Event({ bubbles: false }) icTabSelect: EventEmitter<IcTabSelectEventDetail>;\n\n /**\n * @deprecated This event should not be used anymore. Use icTabSelect instead.\n */\n @Event({ bubbles: false }) tabSelect: EventEmitter<IcTabSelectEventDetail>;\n\n componentDidLoad(): void {\n this.setControlledMode();\n this.getChildren();\n this.linkTabs();\n this.attatchEventListeners();\n this.setInitialTab();\n this.configureTabs();\n }\n\n componentWillUpdate(): void {\n this.configureTabs();\n }\n\n disconnectedCallback(): void {\n this.tabGroup.removeEventListener(\"keydown\", this.keydownHandler);\n }\n\n @Listen(\"tabClick\")\n tabClickHandler(event: CustomEvent<IcTabClickEventDetail>): void {\n if (\n this.selectedTabIndex === undefined &&\n event.detail.contextId === this.contextId\n ) {\n this.selectedTab = event.detail.position;\n }\n this.icTabSelect.emit({\n tabIndex: event.detail.position,\n });\n this.tabSelect.emit({\n tabIndex: event.detail.position,\n });\n event.stopImmediatePropagation();\n }\n\n @Listen(\"tabCreated\")\n @Listen(\"tabPanelCreated\")\n tabCreatedHandler(ev: CustomEvent): void {\n if (this.tabs && this.tabPanels) {\n (ev.detail.setFocus ? this.newTabs : this.newTabPanels).push(ev.detail);\n if (this.newTabs.length === this.newTabPanels.length) {\n this.tabs.push(...this.newTabs);\n this.tabPanels.push(...this.newTabPanels);\n this.enabledTabs = this.getEnabledTabs();\n this.linkTabs();\n this.newTabs = [];\n this.newTabPanels = [];\n }\n }\n }\n\n @Listen(\"tabEnabled\")\n tabEnabledHandler(): void {\n this.enabledTabs = this.getEnabledTabs();\n }\n\n /**\n * @internal Used to set tab/tab panel IDs when a tab/tab panel has been removed\n */\n @Method()\n async tabRemovedHandler(hadFocus?: boolean): Promise<void> {\n this.getChildren();\n this.enabledTabs = this.getEnabledTabs();\n this.linkTabs();\n if (this.tabs[this.selectedTab] && this.tabPanels[this.selectedTab]) {\n this.tabs[this.selectedTab].selected = true;\n this.tabPanels[this.selectedTab].selectedTab =\n this.tabs[this.selectedTab].tabId;\n } else {\n this.setInitialTab();\n }\n\n if (hadFocus) {\n this.tabs[this.selectedTab].setFocus();\n }\n }\n\n // Sets attributes to link tab-group, tabs and tab-panels\n private linkTabs = () => {\n this.tabs.forEach((tab, index) => {\n const tabId = `ic-tab-${index}-context-${this.contextId}`;\n const tabPanelId = `ic-tab-panel-${index}-context-${this.contextId}`;\n const shared = `ic-tab--${index}-context-${this.contextId}`;\n const contextIdAttr = \"context-id\";\n tab.setAttribute(\"id\", tabId);\n tab.tabId = shared;\n tab.tabPosition = index;\n tab.setAttribute(\"aria-controls\", tabPanelId);\n tab.setAttribute(contextIdAttr, this.contextId);\n this.tabGroup.setAttribute(contextIdAttr, this.contextId);\n this.tabPanels[index].setAttribute(\"id\", tabPanelId);\n this.tabPanels[index].panelId = shared;\n this.tabPanels[index].tabPosition = index;\n this.tabPanels[index].setAttribute(\"aria-labelledby\", tabId);\n this.tabPanels[index].setAttribute(contextIdAttr, this.contextId);\n\n if (this.appearance === IcThemeForegroundEnum.Light) {\n tab.appearance = this.appearance;\n this.tabPanels[index].appearance = this.appearance;\n }\n });\n\n if (this.appearance === IcThemeForegroundEnum.Light) {\n this.tabGroup.appearance = this.appearance;\n }\n };\n\n // Gets tabs and tabpanels with the same context ID\n // Using querySelector to selector the children in relation to the host\n private getChildren = (): void => {\n this.tabGroup = this.host.querySelector(\"ic-tab-group\");\n this.tabs = Array.from(this.tabGroup.querySelectorAll(\"ic-tab\"));\n this.tabPanels = Array.from(this.host.children).filter(\n (child) => child.tagName === \"IC-TAB-PANEL\"\n ) as HTMLIcTabPanelElement[];\n this.enabledTabs = this.getEnabledTabs();\n };\n\n private keydownHandler = (event: KeyboardEvent) => {\n if (this.activationType === \"automatic\") {\n this.handleKeyBoardNavAutomatic(event);\n } else {\n this.handleKeyBoardNavManual(event);\n }\n };\n\n // Determines how keyboard navigation is to be handled based on the activation type\n private attatchEventListeners = (): void => {\n this.tabGroup.addEventListener(\"keydown\", this.keydownHandler);\n };\n\n // Determines whether the selected tab is being controlled within the component\n // or by the user (via selectedTabIndex and onIcTabSelect)\n private setControlledMode = (): void => {\n if (this.selectedTabIndex !== undefined) {\n this.controlledMode = true;\n this.selectedTab = this.selectedTabIndex;\n }\n };\n\n // Sets the tab that is selected on initial render\n private setInitialTab = (): void => {\n if (this.controlledMode) {\n this.selectedTab = this.selectedTabIndex;\n this.focusedTabIndex = this.selectedTabIndex;\n } else {\n const firstEnabledTabIndex = this.tabs.findIndex(\n (tab) => tab.tabId === this.enabledTabs[0].tabId\n );\n this.selectedTab = firstEnabledTabIndex;\n this.focusedTabIndex = firstEnabledTabIndex;\n }\n };\n\n // Passes the selected tab to the tab and tab panel components\n private configureTabs = () => {\n this.enabledTabs.forEach((tab) => {\n tab.selected = tab.tabPosition === this.selectedTab;\n });\n this.tabPanels.forEach((tabPanel) => {\n tabPanel.selectedTab = this.tabs[this.selectedTab].tabId;\n });\n };\n\n private getEnabledTabs = () => {\n return Array.from(this.tabs).filter((child) => !child.disabled);\n };\n\n private getIndexOfEnabledTab = (allTabsIndex: number) => {\n return this.enabledTabs.findIndex(\n (tab) => tab.tabId === this.tabs[allTabsIndex].tabId\n );\n };\n\n // Sets focus on tab and selects it\n private keyboardSelectTab = (enabledTabIndex: number) => {\n const newIndex = this.tabs.findIndex(\n (tab) => tab.tabId === this.enabledTabs[enabledTabIndex].tabId\n );\n this.enabledTabs[enabledTabIndex].focus();\n if (!this.controlledMode) {\n this.selectedTab = newIndex;\n } else {\n this.icTabSelect.emit({ tabIndex: newIndex });\n this.tabSelect.emit({ tabIndex: newIndex });\n }\n };\n\n // Sets focus on tab without selecting it (for manual activation)\n private keyboardFocusTab = (enabledTabIndex: number) => {\n const newIndex = this.tabs.findIndex(\n (tab) => tab.tabId === this.enabledTabs[enabledTabIndex].tabId\n );\n this.enabledTabs[enabledTabIndex].focus();\n this.focusedTabIndex = newIndex;\n };\n\n private handleKeyBoardNavAutomatic = (event: KeyboardEvent) => {\n const key = event.key;\n const enabledTabIndex = this.getIndexOfEnabledTab(this.selectedTab);\n let preventDefault = true;\n switch (key) {\n case \"Home\":\n this.keyboardSelectTab(0);\n break;\n case \"End\":\n this.keyboardSelectTab(this.enabledTabs.length - 1);\n break;\n case \"ArrowRight\":\n if (enabledTabIndex < this.enabledTabs.length - 1) {\n this.keyboardSelectTab(enabledTabIndex + 1);\n } else {\n this.keyboardSelectTab(0);\n }\n break;\n case \"ArrowLeft\":\n if (enabledTabIndex > 0) {\n this.keyboardSelectTab(enabledTabIndex - 1);\n } else {\n this.keyboardSelectTab(this.enabledTabs.length - 1);\n }\n break;\n default:\n preventDefault = false;\n }\n if (preventDefault) event.preventDefault();\n };\n\n private handleKeyBoardNavManual = (event: KeyboardEvent) => {\n const key = event.key;\n const enabledTabIndex = this.getIndexOfEnabledTab(this.focusedTabIndex);\n let preventDefault = true;\n switch (key) {\n case \"Home\":\n this.keyboardFocusTab(0);\n break;\n case \"End\":\n this.keyboardFocusTab(this.enabledTabs.length - 1);\n break;\n case \"ArrowRight\":\n if (enabledTabIndex < this.enabledTabs.length - 1) {\n this.keyboardFocusTab(enabledTabIndex + 1);\n } else {\n this.keyboardFocusTab(0);\n }\n break;\n case \"ArrowLeft\":\n if (enabledTabIndex > 0) {\n this.keyboardFocusTab(enabledTabIndex - 1);\n } else {\n this.keyboardFocusTab(this.enabledTabs.length - 1);\n }\n break;\n case \"Enter\":\n this.keyboardSelectTab(this.focusedTabIndex);\n break;\n case \" \":\n this.keyboardSelectTab(this.focusedTabIndex);\n break;\n default:\n preventDefault = false;\n }\n if (preventDefault) event.preventDefault();\n };\n\n render() {\n return <slot></slot>;\n }\n}\n"],"mappings":"mGA0BaA,EAAU,M,uGAIbC,KAAAC,aAAwC,GACxCD,KAAAE,QAA8B,GAyH9BF,KAAAG,SAAW,KACjBH,KAAKI,KAAKC,SAAQ,CAACC,EAAKC,KACtB,MAAMC,EAAQ,UAAUD,aAAiBP,KAAKS,YAC9C,MAAMC,EAAa,gBAAgBH,aAAiBP,KAAKS,YACzD,MAAME,EAAS,WAAWJ,aAAiBP,KAAKS,YAChD,MAAMG,EAAgB,aACtBN,EAAIO,aAAa,KAAML,GACvBF,EAAIE,MAAQG,EACZL,EAAIQ,YAAcP,EAClBD,EAAIO,aAAa,gBAAiBH,GAClCJ,EAAIO,aAAaD,EAAeZ,KAAKS,WACrCT,KAAKe,SAASF,aAAaD,EAAeZ,KAAKS,WAC/CT,KAAKgB,UAAUT,GAAOM,aAAa,KAAMH,GACzCV,KAAKgB,UAAUT,GAAOU,QAAUN,EAChCX,KAAKgB,UAAUT,GAAOO,YAAcP,EACpCP,KAAKgB,UAAUT,GAAOM,aAAa,kBAAmBL,GACtDR,KAAKgB,UAAUT,GAAOM,aAAaD,EAAeZ,KAAKS,WAEvD,GAAIT,KAAKkB,aAAeC,EAAsBC,MAAO,CACnDd,EAAIY,WAAalB,KAAKkB,WACtBlB,KAAKgB,UAAUT,GAAOW,WAAalB,KAAKkB,U,KAI5C,GAAIlB,KAAKkB,aAAeC,EAAsBC,MAAO,CACnDpB,KAAKe,SAASG,WAAalB,KAAKkB,U,GAM5BlB,KAAAqB,YAAc,KACpBrB,KAAKe,SAAWf,KAAKsB,KAAKC,cAAc,gBACxCvB,KAAKI,KAAOoB,MAAMC,KAAKzB,KAAKe,SAASW,iBAAiB,WACtD1B,KAAKgB,UAAYQ,MAAMC,KAAKzB,KAAKsB,KAAKK,UAAUC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F,KAAKgB,UAAUgE,QAAQhF,KAAKC,cAC5BD,KAAK+B,YAAc/B,KAAKgC,iBACxBhC,KAAKG,WACLH,KAAKE,QAAU,GACfF,KAAKC,aAAe,E,GAM1B,iBAAAgF,GACEjF,KAAK+B,YAAc/B,KAAKgC,gB,CAO1B,uBAAMkD,CAAkBC,GACtBnF,KAAKqB,cACLrB,KAAK+B,YAAc/B,KAAKgC,iBACxBhC,KAAKG,WACL,GAAIH,KAAKI,KAAKJ,KAAK4C,cAAgB5C,KAAKgB,UAAUhB,KAAK4C,aAAc,CACnE5C,KAAKI,KAAKJ,KAAK4C,aAAaM,SAAW,KACvClD,KAAKgB,UAAUhB,KAAK4C,aAAaA,YAC/B5C,KAAKI,KAAKJ,KAAK4C,aAAapC,K,KACzB,CACLR,KAAK6C,e,CAGP,GAAIsC,EAAU,CACZnF,KAAKI,KAAKJ,KAAK4C,aAAamC,U,EAgMhC,MAAAK,GACE,OAAOC,EAAA,Y"}
@@ -1,2 +1,2 @@
1
- import{r as e,c as t,h as o,H as i,g as r}from"./p-69920d86.js";import{g as n,I as a,l as s,c as l,i as c,m as d}from"./p-dd980be4.js";import{I as p}from"./p-6f57b13c.js";const m='/*! 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;--footer-compliance-padding:1rem 0}:host(.footer-sparse){--footer-links-padding:1.5rem 0;--footer-logo-margin-bottom:var(--ic-space-lg);--footer-link-inner-flex-direction:row}:host(.footer-small){--footer-links-padding:0 0;--footer-logo-margin-bottom:var(--ic-space-md);--footer-link-inner-flex-direction:column}:host(.footer-light){--footer-theme-secondary:var(--ic-theme-secondary);--footer-theme-tertiary:var(--ic-theme-tertiary);--footer-keyline:var(--ic-keyline-lighten)}:host(.footer-dark){--footer-theme-secondary:var(--ic-theme-secondary-light);--footer-theme-tertiary:var(--ic-theme-tertiary-light);--footer-keyline:var(--ic-keyline-darken)}:host(.footer-small.footer-ungrouped){--footer-links-padding:var(--ic-space-md) 0 0 0}footer{display:flex;flex-direction:column;width:100%}.footer-description{background-color:var(--footer-theme-secondary);color:var(--ic-theme-text);border-bottom:var(--footer-keyline)}.footer-description-inner{padding:1rem 0}.footer-links{padding:var(--footer-links-padding);background-color:var(--footer-theme-secondary);color:var(--ic-theme-text)}.footer-links-inner{display:flex;flex-direction:var(--footer-link-inner-flex-direction)}.footer-compliance{background-color:var(--footer-theme-tertiary);color:var(--ic-theme-text)}.footer-compliance-inner{padding:var(--footer-compliance-padding)}.footer-logo{margin-bottom:var(--footer-logo-margin-bottom);display:flex;gap:var(--ic-space-xxl)}.footer-logo>::slotted(){margin-right:var(--ic-space-md)}.footer-caption{margin-bottom:var(--ic-space-md)}.classification-spacing{margin-bottom:var(--ic-space-lg)}@media (forced-colors: active){footer{border-top:var(--ic-hc-border)}}';const f=class{constructor(o){e(this,o);this.footerResized=t(this,"footerResized",7);this.resizeObserver=null;this.resizeObserverCallback=e=>{if(e!==this.deviceSize){this.deviceSize=e}this.footerResized.emit()};this.runResizeObserver=()=>{this.resizeObserver=new ResizeObserver((()=>{const e=n();this.resizeObserverCallback(e)}));this.resizeObserver.observe(this.footerEl)};this.deviceSize=a.XL;this.foregroundColor=s();this.aligned="left";this.breakpoint="medium";this.caption=undefined;this.copyright=true;this.description=undefined;this.groupLinks=false}disconnectedCallback(){if(this.resizeObserver!==null){this.resizeObserver.disconnect()}}componentWillLoad(){this.deviceSize=n()}componentDidLoad(){l(this.runResizeObserver)}themeChangeHandler(e){const t=e.detail;this.foregroundColor=t.mode}isSmall(){const e=this.breakpoint;return e==="extra small"?this.deviceSize<a.XS:e==="small"?this.deviceSize<a.S:e==="medium"?this.deviceSize<a.M:e==="large"?this.deviceSize<a.L:e==="extra large"?this.deviceSize<a.XL:false}render(){const{aligned:e,caption:t,copyright:r,description:n,groupLinks:s,foregroundColor:l}=this;const m=this.isSmall();return o(i,{class:{footer:true,[`footer-${m?"small":"sparse"}`]:true,[`footer-${s?"grouped":"ungrouped"}`]:true,[`footer-${l}`]:true,[p.Dark]:l===p.Dark,[p.Light]:l===p.Light}},o("footer",{ref:e=>this.footerEl=e},o("div",{class:"footer-description"},o("ic-section-container",{aligned:e,fullHeight:true},o("div",{class:"footer-description-inner"},o("ic-typography",{variant:"body"},o("slot",{name:"description"},n))))),c(this.el,"link")&&o("div",{class:"footer-links"},s&&m?o("div",{class:"footer-links-inner"},o("slot",{name:"link"})):o("ic-section-container",{fullHeight:true,aligned:e},o("div",{class:"footer-links-inner"},o("slot",{name:"link"})))),o("div",{class:"footer-compliance"},o("ic-section-container",{aligned:e,fullHeight:true},o("div",{class:"footer-compliance-inner"},c(this.el,"logo")&&o("div",{class:"footer-logo"},o("slot",{name:"logo"})),(c(this.el,"caption")||t)&&o("div",{class:"footer-caption"},o("ic-typography",{variant:this.deviceSize<=a.M?"caption":"body"},o("slot",{name:"caption"},t))),r&&o("div",{class:{["footer-copyright"]:true,["classification-spacing"]:d()}},o("ic-typography",{variant:this.deviceSize<=a.M?"caption-uppercase":"label-uppercase"},"© Crown Copyright")))))))}get el(){return r(this)}};f.style=m;export{f as ic_footer};
2
- //# sourceMappingURL=p-14bea6c0.entry.js.map
1
+ import{r as e,c as t,h as o,H as i,g as r}from"./p-18068237.js";import{g as n,I as a,l as s,c as l,i as c,m as d}from"./p-ebe76390.js";import{I as p}from"./p-613aa265.js";const m='/*! 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;--footer-compliance-padding:1rem 0}:host(.footer-sparse){--footer-links-padding:1.5rem 0;--footer-logo-margin-bottom:var(--ic-space-lg);--footer-link-inner-flex-direction:row}:host(.footer-small){--footer-links-padding:0 0;--footer-logo-margin-bottom:var(--ic-space-md);--footer-link-inner-flex-direction:column}:host(.footer-light){--footer-theme-secondary:var(--ic-theme-secondary);--footer-theme-tertiary:var(--ic-theme-tertiary);--footer-keyline:var(--ic-keyline-lighten)}:host(.footer-dark){--footer-theme-secondary:var(--ic-theme-secondary-light);--footer-theme-tertiary:var(--ic-theme-tertiary-light);--footer-keyline:var(--ic-keyline-darken)}:host(.footer-small.footer-ungrouped){--footer-links-padding:var(--ic-space-md) 0 0 0}footer{display:flex;flex-direction:column;width:100%}.footer-description{background-color:var(--footer-theme-secondary);color:var(--ic-theme-text);border-bottom:var(--footer-keyline)}.footer-description-inner{padding:1rem 0}.footer-links{padding:var(--footer-links-padding);background-color:var(--footer-theme-secondary);color:var(--ic-theme-text)}.footer-links-inner{display:flex;flex-direction:var(--footer-link-inner-flex-direction)}.footer-compliance{background-color:var(--footer-theme-tertiary);color:var(--ic-theme-text)}.footer-compliance-inner{padding:var(--footer-compliance-padding)}.footer-logo{margin-bottom:var(--footer-logo-margin-bottom);display:flex;gap:var(--ic-space-xxl)}.footer-logo>::slotted(){margin-right:var(--ic-space-md)}.footer-caption{margin-bottom:var(--ic-space-md)}.classification-spacing{margin-bottom:var(--ic-space-lg)}@media (forced-colors: active){footer{border-top:var(--ic-hc-border)}}';const f=class{constructor(o){e(this,o);this.footerResized=t(this,"footerResized",7);this.resizeObserver=null;this.resizeObserverCallback=e=>{if(e!==this.deviceSize){this.deviceSize=e}this.footerResized.emit()};this.runResizeObserver=()=>{this.resizeObserver=new ResizeObserver((()=>{const e=n();this.resizeObserverCallback(e)}));this.resizeObserver.observe(this.footerEl)};this.deviceSize=a.XL;this.foregroundColor=s();this.aligned="left";this.breakpoint="medium";this.caption=undefined;this.copyright=true;this.description=undefined;this.groupLinks=false}disconnectedCallback(){if(this.resizeObserver!==null){this.resizeObserver.disconnect()}}componentWillLoad(){this.deviceSize=n()}componentDidLoad(){l(this.runResizeObserver)}themeChangeHandler(e){const t=e.detail;this.foregroundColor=t.mode}isSmall(){const e=this.breakpoint;return e==="extra small"?this.deviceSize<a.XS:e==="small"?this.deviceSize<a.S:e==="medium"?this.deviceSize<a.M:e==="large"?this.deviceSize<a.L:e==="extra large"?this.deviceSize<a.XL:false}render(){const{aligned:e,caption:t,copyright:r,description:n,groupLinks:s,foregroundColor:l}=this;const m=this.isSmall();return o(i,{class:{footer:true,[`footer-${m?"small":"sparse"}`]:true,[`footer-${s?"grouped":"ungrouped"}`]:true,[`footer-${l}`]:true,[p.Dark]:l===p.Dark,[p.Light]:l===p.Light}},o("footer",{ref:e=>this.footerEl=e},o("div",{class:"footer-description"},o("ic-section-container",{aligned:e,fullHeight:true},o("div",{class:"footer-description-inner"},o("ic-typography",{variant:"body"},o("slot",{name:"description"},n))))),c(this.el,"link")&&o("div",{class:"footer-links"},s&&m?o("div",{class:"footer-links-inner"},o("slot",{name:"link"})):o("ic-section-container",{fullHeight:true,aligned:e},o("div",{class:"footer-links-inner"},o("slot",{name:"link"})))),o("div",{class:"footer-compliance"},o("ic-section-container",{aligned:e,fullHeight:true},o("div",{class:"footer-compliance-inner"},c(this.el,"logo")&&o("div",{class:"footer-logo"},o("slot",{name:"logo"})),(c(this.el,"caption")||t)&&o("div",{class:"footer-caption"},o("ic-typography",{variant:this.deviceSize<=a.M?"caption":"body"},o("slot",{name:"caption"},t))),r&&o("div",{class:{["footer-copyright"]:true,["classification-spacing"]:d()}},o("ic-typography",{variant:this.deviceSize<=a.M?"caption-uppercase":"label-uppercase"},"© Crown Copyright")))))))}get el(){return r(this)}};f.style=m;export{f as ic_footer};
2
+ //# sourceMappingURL=p-5fcbcc3f.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["icFooterCss","Footer","this","resizeObserver","resizeObserverCallback","currSize","deviceSize","footerResized","emit","runResizeObserver","ResizeObserver","getCurrentDeviceSize","observe","footerEl","IC_DEVICE_SIZES","XL","getThemeForegroundColor","disconnectedCallback","disconnect","componentWillLoad","componentDidLoad","checkResizeObserver","themeChangeHandler","ev","theme","detail","foregroundColor","mode","isSmall","bp","breakpoint","XS","S","M","L","render","aligned","caption","copyright","description","groupLinks","small","h","Host","class","footer","IcThemeForegroundEnum","Dark","Light","ref","fullHeight","variant","name","isSlotUsed","el","hasClassificationBanner"],"sources":["src/components/ic-footer/ic-footer.css?tag=ic-footer&encapsulation=shadow","src/components/ic-footer/ic-footer.tsx"],"sourcesContent":["@import \"../../global/normalize.css\";\n\n:host {\n display: block;\n\n --footer-compliance-padding: 1rem 0;\n}\n\n:host(.footer-sparse) {\n --footer-links-padding: 1.5rem 0;\n --footer-logo-margin-bottom: var(--ic-space-lg);\n --footer-link-inner-flex-direction: row;\n}\n\n:host(.footer-small) {\n --footer-links-padding: 0 0;\n --footer-logo-margin-bottom: var(--ic-space-md);\n --footer-link-inner-flex-direction: column;\n}\n\n:host(.footer-light) {\n --footer-theme-secondary: var(--ic-theme-secondary);\n --footer-theme-tertiary: var(--ic-theme-tertiary);\n --footer-keyline: var(--ic-keyline-lighten);\n}\n\n:host(.footer-dark) {\n --footer-theme-secondary: var(--ic-theme-secondary-light);\n --footer-theme-tertiary: var(--ic-theme-tertiary-light);\n --footer-keyline: var(--ic-keyline-darken);\n}\n\n:host(.footer-small.footer-ungrouped) {\n --footer-links-padding: var(--ic-space-md) 0 0 0;\n}\n\n/* Main inner footer element */\nfooter {\n display: flex;\n flex-direction: column;\n width: 100%;\n}\n\n/* Description */\n\n.footer-description {\n background-color: var(--footer-theme-secondary);\n color: var(--ic-theme-text);\n border-bottom: var(--footer-keyline);\n}\n\n.footer-description-inner {\n padding: 1rem 0;\n}\n\n/* Links */\n\n.footer-links {\n padding: var(--footer-links-padding);\n background-color: var(--footer-theme-secondary);\n color: var(--ic-theme-text);\n}\n\n.footer-links-inner {\n display: flex;\n flex-direction: var(--footer-link-inner-flex-direction);\n}\n\n/* Compliance */\n\n.footer-compliance {\n background-color: var(--footer-theme-tertiary);\n color: var(--ic-theme-text);\n}\n\n.footer-compliance-inner {\n padding: var(--footer-compliance-padding);\n}\n\n.footer-logo {\n margin-bottom: var(--footer-logo-margin-bottom);\n display: flex;\n gap: var(--ic-space-xxl);\n}\n\n.footer-logo > ::slotted() {\n margin-right: var(--ic-space-md);\n}\n\n.footer-caption {\n margin-bottom: var(--ic-space-md);\n}\n\n.classification-spacing {\n margin-bottom: var(--ic-space-lg);\n}\n\n@media (forced-colors: active) {\n footer {\n border-top: var(--ic-hc-border);\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n Prop,\n State,\n h,\n Host,\n Listen,\n} from \"@stencil/core\";\nimport { IC_DEVICE_SIZES } from \"../../utils/constants\";\nimport {\n getCurrentDeviceSize,\n getThemeForegroundColor,\n checkResizeObserver,\n hasClassificationBanner,\n isSlotUsed,\n} from \"../../utils/helpers\";\nimport {\n IcAlignment,\n IcTheme,\n IcThemeForeground,\n IcThemeForegroundEnum,\n} from \"../../utils/types\";\nimport { IcFooterBreakpoints } from \"./ic-footer.types\";\n\n/**\n * @slot description - Content will be rendered at the top of the footer.\n * @slot link - Content will be rendered between description and logos.\n * @slot logo - Content will be rendered underneath footer links.\n * @slot caption - Content will be rendered above Crown Copyright.\n */\n\n@Component({\n tag: \"ic-footer\",\n styleUrl: \"ic-footer.css\",\n shadow: true,\n})\nexport class Footer {\n private footerEl: HTMLElement;\n private resizeObserver: ResizeObserver = null;\n\n @Element() el: HTMLIcFooterElement;\n\n @State() deviceSize: number = IC_DEVICE_SIZES.XL;\n @State() foregroundColor: IcThemeForeground = getThemeForegroundColor();\n\n /**\n * The alignment of the section containers used within the footer.\n */\n @Prop() aligned?: IcAlignment = \"left\";\n\n /**\n * The screen size breakpoint at which to switch to the small layout.\n */\n @Prop() breakpoint?: IcFooterBreakpoints = \"medium\";\n\n /**\n * The caption displayed at the bottom of the footer.\n */\n @Prop() caption: string;\n\n /**\n * If `true`, the footer will display the crown copyright at the bottom.\n */\n @Prop() copyright: boolean = true;\n\n /**\n * The description displayed at the top of the footer.\n */\n @Prop() description: string;\n\n /**\n * If `true`, the footer will be set up to handle link groups instead of standalone links.\n */\n @Prop() groupLinks?: boolean = false;\n\n /**\n * @internal Triggers on page resize and triggers style changes in footer links and link groups\n */\n @Event() footerResized: EventEmitter<void>;\n\n disconnectedCallback(): void {\n if (this.resizeObserver !== null) {\n this.resizeObserver.disconnect();\n }\n }\n\n componentWillLoad(): void {\n this.deviceSize = getCurrentDeviceSize();\n }\n\n componentDidLoad(): void {\n checkResizeObserver(this.runResizeObserver);\n }\n\n @Listen(\"themeChange\", { target: \"document\" })\n themeChangeHandler(ev: CustomEvent): void {\n const theme: IcTheme = ev.detail;\n this.foregroundColor = theme.mode;\n }\n\n private isSmall() {\n const bp = this.breakpoint;\n\n return bp === \"extra small\"\n ? this.deviceSize < IC_DEVICE_SIZES.XS\n : bp === \"small\"\n ? this.deviceSize < IC_DEVICE_SIZES.S\n : bp === \"medium\"\n ? this.deviceSize < IC_DEVICE_SIZES.M\n : bp === \"large\"\n ? this.deviceSize < IC_DEVICE_SIZES.L\n : bp === \"extra large\"\n ? this.deviceSize < IC_DEVICE_SIZES.XL\n : false;\n }\n\n private resizeObserverCallback = (currSize: number) => {\n if (currSize !== this.deviceSize) {\n this.deviceSize = currSize;\n }\n this.footerResized.emit();\n };\n\n private runResizeObserver = () => {\n this.resizeObserver = new ResizeObserver(() => {\n const currSize = getCurrentDeviceSize();\n this.resizeObserverCallback(currSize);\n });\n\n this.resizeObserver.observe(this.footerEl);\n };\n\n render() {\n const {\n aligned,\n caption,\n copyright,\n description,\n groupLinks,\n foregroundColor,\n } = this;\n const small = this.isSmall();\n\n return (\n <Host\n class={{\n footer: true,\n [`footer-${small ? \"small\" : \"sparse\"}`]: true,\n [`footer-${groupLinks ? \"grouped\" : \"ungrouped\"}`]: true,\n [`footer-${foregroundColor}`]: true,\n // Slots will be able to infer their own color\n [IcThemeForegroundEnum.Dark]:\n foregroundColor === IcThemeForegroundEnum.Dark,\n [IcThemeForegroundEnum.Light]:\n foregroundColor === IcThemeForegroundEnum.Light,\n }}\n >\n <footer ref={(footerEl) => (this.footerEl = footerEl)}>\n {/* Description */}\n <div class=\"footer-description\">\n <ic-section-container aligned={aligned} fullHeight={true}>\n <div class=\"footer-description-inner\">\n <ic-typography variant=\"body\">\n <slot name=\"description\">{description}</slot>\n </ic-typography>\n </div>\n </ic-section-container>\n </div>\n\n {/* Links */}\n {isSlotUsed(this.el, \"link\") && (\n <div class=\"footer-links\">\n {groupLinks && small ? (\n <div class=\"footer-links-inner\">\n <slot name=\"link\" />\n </div>\n ) : (\n <ic-section-container fullHeight aligned={aligned}>\n <div class=\"footer-links-inner\">\n <slot name=\"link\" />\n </div>\n </ic-section-container>\n )}\n </div>\n )}\n\n {/* Compliance (logo, caption, copyright) */}\n <div class=\"footer-compliance\">\n <ic-section-container aligned={aligned} fullHeight={true}>\n <div class=\"footer-compliance-inner\">\n {isSlotUsed(this.el, \"logo\") && (\n <div class=\"footer-logo\">\n {/* Logo */}\n <slot name=\"logo\" />\n </div>\n )}\n {(isSlotUsed(this.el, \"caption\") || caption) && (\n <div class=\"footer-caption\">\n <ic-typography\n variant={\n this.deviceSize <= IC_DEVICE_SIZES.M\n ? \"caption\"\n : \"body\"\n }\n >\n <slot name=\"caption\">{caption}</slot>\n </ic-typography>\n </div>\n )}\n {copyright && (\n <div\n class={{\n [\"footer-copyright\"]: true,\n [\"classification-spacing\"]: hasClassificationBanner(),\n }}\n >\n <ic-typography\n variant={\n this.deviceSize <= IC_DEVICE_SIZES.M\n ? \"caption-uppercase\"\n : \"label-uppercase\"\n }\n >\n &copy; Crown Copyright\n </ic-typography>\n </div>\n )}\n </div>\n </ic-section-container>\n </div>\n </footer>\n </Host>\n );\n }\n}\n"],"mappings":"2KAAA,MAAMA,EAAc,o/H,MCuCPC,EAAM,M,sEAETC,KAAAC,eAAiC,KA8EjCD,KAAAE,uBAA0BC,IAChC,GAAIA,IAAaH,KAAKI,WAAY,CAChCJ,KAAKI,WAAaD,C,CAEpBH,KAAKK,cAAcC,MAAM,EAGnBN,KAAAO,kBAAoB,KAC1BP,KAAKC,eAAiB,IAAI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AKE,MAAM,4BACTF,EAAA,iBAAeS,QAAQ,QACrBT,EAAA,QAAMU,KAAK,eAAeb,OAOjCc,EAAWnD,KAAKoD,GAAI,SACnBZ,EAAA,OAAKE,MAAM,gBACRJ,GAAcC,EACbC,EAAA,OAAKE,MAAM,sBACTF,EAAA,QAAMU,KAAK,UAGbV,EAAA,wBAAsBQ,WAAU,KAACd,QAASA,GACxCM,EAAA,OAAKE,MAAM,sBACTF,EAAA,QAAMU,KAAK,YAQrBV,EAAA,OAAKE,MAAM,qBACTF,EAAA,wBAAsBN,QAASA,EAASc,WAAY,MAClDR,EAAA,OAAKE,MAAM,2BACRS,EAAWnD,KAAKoD,GAAI,SACnBZ,EAAA,OAAKE,MAAM,eAETF,EAAA,QAAMU,KAAK,WAGbC,EAAWnD,KAAKoD,GAAI,YAAcjB,IAClCK,EAAA,OAAKE,MAAM,kBACTF,EAAA,iBACES,QACEjD,KAAKI,YAAcQ,EAAgBmB,EAC/B,UACA,QAGNS,EAAA,QAAMU,KAAK,WAAWf,KAI3BC,GACCI,EAAA,OACEE,MAAO,CACL,CAAC,oBAAqB,KACtB,CAAC,0BAA2BW,MAG9Bb,EAAA,iBACES,QACEjD,KAAKI,YAAcQ,EAAgBmB,EAC/B,oBACA,mBAAiB,0B"}
@@ -1,2 +1,2 @@
1
- import{r as e,h as t,H as i}from"./p-69920d86.js";const n='/*! 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}@media only screen and (max-width: 576px){:host{--section-container-margin:var(--ic-space-xs);--section-container-max-width:var(--ic-breakpoint-sm)}}@media only screen and (min-width: 577px){:host{--section-container-margin:var(--ic-space-md);--section-container-max-width:var(--ic-breakpoint-md)}}@media only screen and (min-width: 769px){:host{--section-container-margin:var(--ic-space-md);--section-container-max-width:var(--ic-breakpoint-lg)}}@media only screen and (min-width: 993px){:host{--section-container-margin:var(--ic-space-md);--section-container-max-width:var(--ic-breakpoint-xl)}}@media only screen and (min-width: 1201px){:host{--section-container-margin:var(--ic-space-lg);--section-container-max-width:var(--ic-breakpoint-xl)}}:host{display:block;padding-top:var(--ic-space-md);padding-bottom:var(--ic-space-md);box-sizing:border-box}:host(.aligned-center){max-width:var(--section-container-max-width);margin-left:auto;margin-right:auto;padding-left:var(--section-container-margin);padding-right:var(--section-container-margin)}:host(.aligned-left){max-width:var(--section-container-max-width);margin-left:var(--section-container-margin);margin-right:auto;padding-right:var(--section-container-margin)}:host(.aligned-full-width){margin-left:var(--section-container-margin);margin-right:var(--section-container-margin)}:host(.vertical-padding){padding-top:var(--ic-space-md);padding-bottom:var(--ic-space-md)}:host(.no-vertical-padding){padding-top:0;padding-bottom:0}';const o=class{constructor(t){e(this,t);this.aligned="left";this.fullHeight=false}render(){const{aligned:e,fullHeight:n}=this;return t(i,{class:{["aligned-left"]:e==="left",["aligned-center"]:e==="center",["aligned-full-width"]:e==="full-width",["no-vertical-padding"]:n}},t("slot",null))}};o.style=n;export{o as ic_section_container};
2
- //# sourceMappingURL=p-3adb1167.entry.js.map
1
+ import{r as e,h as t,H as i}from"./p-18068237.js";const n='/*! 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}@media only screen and (max-width: 576px){:host{--section-container-margin:var(--ic-space-xs);--section-container-max-width:var(--ic-breakpoint-sm)}}@media only screen and (min-width: 577px){:host{--section-container-margin:var(--ic-space-md);--section-container-max-width:var(--ic-breakpoint-md)}}@media only screen and (min-width: 769px){:host{--section-container-margin:var(--ic-space-md);--section-container-max-width:var(--ic-breakpoint-lg)}}@media only screen and (min-width: 993px){:host{--section-container-margin:var(--ic-space-md);--section-container-max-width:var(--ic-breakpoint-xl)}}@media only screen and (min-width: 1201px){:host{--section-container-margin:var(--ic-space-lg);--section-container-max-width:var(--ic-breakpoint-xl)}}:host{display:block;padding-top:var(--ic-space-md);padding-bottom:var(--ic-space-md);box-sizing:border-box}:host(.aligned-center){max-width:var(--section-container-max-width);margin-left:auto;margin-right:auto;padding-left:var(--section-container-margin);padding-right:var(--section-container-margin)}:host(.aligned-left){max-width:var(--section-container-max-width);margin-left:var(--section-container-margin);margin-right:auto;padding-right:var(--section-container-margin)}:host(.aligned-full-width){margin-left:var(--section-container-margin);margin-right:var(--section-container-margin)}:host(.vertical-padding){padding-top:var(--ic-space-md);padding-bottom:var(--ic-space-md)}:host(.no-vertical-padding){padding-top:0;padding-bottom:0}';const o=class{constructor(t){e(this,t);this.aligned="left";this.fullHeight=false}render(){const{aligned:e,fullHeight:n}=this;return t(i,{class:{["aligned-left"]:e==="left",["aligned-center"]:e==="center",["aligned-full-width"]:e==="full-width",["no-vertical-padding"]:n}},t("slot",null))}};o.style=n;export{o as ic_section_container};
2
+ //# sourceMappingURL=p-607e7bf2.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["icSectionContainerCss","SectionContainer","render","aligned","fullHeight","this","h","Host","class"],"sources":["src/components/ic-section-container/ic-section-container.css?tag=ic-section-container&encapsulation=shadow","src/components/ic-section-container/ic-section-container.tsx"],"sourcesContent":["@import \"../../global/normalize.css\";\n\n@media only screen and (max-width: 576px) {\n :host {\n --section-container-margin: var(--ic-space-xs);\n --section-container-max-width: var(--ic-breakpoint-sm);\n }\n}\n\n@media only screen and (min-width: 577px) {\n :host {\n --section-container-margin: var(--ic-space-md);\n --section-container-max-width: var(--ic-breakpoint-md);\n }\n}\n\n@media only screen and (min-width: 769px) {\n :host {\n --section-container-margin: var(--ic-space-md);\n --section-container-max-width: var(--ic-breakpoint-lg);\n }\n}\n\n@media only screen and (min-width: 993px) {\n :host {\n --section-container-margin: var(--ic-space-md);\n --section-container-max-width: var(--ic-breakpoint-xl);\n }\n}\n\n@media only screen and (min-width: 1201px) {\n :host {\n --section-container-margin: var(--ic-space-lg);\n --section-container-max-width: var(--ic-breakpoint-xl);\n }\n}\n\n:host {\n display: block;\n padding-top: var(--ic-space-md);\n padding-bottom: var(--ic-space-md);\n box-sizing: border-box;\n}\n\n:host(.aligned-center) {\n max-width: var(--section-container-max-width);\n margin-left: auto;\n margin-right: auto;\n padding-left: var(--section-container-margin);\n padding-right: var(--section-container-margin);\n}\n\n:host(.aligned-left) {\n max-width: var(--section-container-max-width);\n margin-left: var(--section-container-margin);\n margin-right: auto;\n padding-right: var(--section-container-margin);\n}\n\n:host(.aligned-full-width) {\n margin-left: var(--section-container-margin);\n margin-right: var(--section-container-margin);\n}\n\n:host(.vertical-padding) {\n padding-top: var(--ic-space-md);\n padding-bottom: var(--ic-space-md);\n}\n\n:host(.no-vertical-padding) {\n padding-top: 0;\n padding-bottom: 0;\n}\n","import { Component, Prop, Host, h } from \"@stencil/core\";\nimport { IcAlignment } from \"../../utils/types\";\n\n@Component({\n tag: \"ic-section-container\",\n styleUrl: \"ic-section-container.css\",\n shadow: true,\n})\nexport class SectionContainer {\n /**\n * The alignment of the container.\n */\n @Prop() aligned?: IcAlignment = \"left\";\n\n /**\n * If `true`, the standard vertical padding from the container will be removed.\n */\n @Prop() fullHeight?: boolean = false;\n\n render() {\n const { aligned, fullHeight } = this;\n return (\n <Host\n class={{\n [\"aligned-left\"]: aligned === \"left\",\n [\"aligned-center\"]: aligned === \"center\",\n [\"aligned-full-width\"]: aligned === \"full-width\",\n [\"no-vertical-padding\"]: fullHeight,\n }}\n >\n <slot></slot>\n </Host>\n );\n }\n}\n"],"mappings":"kDAAA,MAAMA,EAAwB,kzH,MCQjBC,EAAgB,M,sCAIK,O,gBAKD,K,CAE/B,MAAAC,GACE,MAAMC,QAAEA,EAAOC,WAAEA,GAAeC,KAChC,OACEC,EAACC,EAAI,CACHC,MAAO,CACL,CAAC,gBAAiBL,IAAY,OAC9B,CAAC,kBAAmBA,IAAY,SAChC,CAAC,sBAAuBA,IAAY,aACpC,CAAC,uBAAwBC,IAG3BE,EAAA,a"}
@@ -1,2 +1,2 @@
1
1
  var a;(function(a){a["Warning"]="warning";a["Error"]="error";a["Success"]="success"})(a||(a={}));var r;(function(a){a["Default"]="default";a["Dark"]="dark";a["Light"]="light"})(r||(r={}));export{r as I,a};
2
- //# sourceMappingURL=p-6f57b13c.js.map
2
+ //# sourceMappingURL=p-613aa265.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["IcInformationStatus","IcThemeForegroundEnum"],"sources":["src/utils/types.ts"],"sourcesContent":["export type IcFocusableComponents =\n | HTMLIcBreadcrumbElement\n | HTMLIcButtonElement\n | HTMLIcCardElement\n | HTMLIcCheckboxElement\n | HTMLIcChipElement\n | HTMLIcLinkElement\n | HTMLIcNavigationButtonElement\n | HTMLIcNavigationGroupElement\n | HTMLIcNavigationItemElement\n | HTMLIcRadioOptionElement\n | HTMLIcSearchBarElement\n | HTMLIcSelectElement\n | HTMLIcSwitchElement\n | HTMLIcTabElement\n | HTMLIcTextFieldElement;\n\nexport type IcStatusVariants =\n | \"neutral\"\n | \"info\"\n | \"warning\"\n | \"error\"\n | \"success\";\n\nexport enum IcInformationStatus {\n Warning = \"warning\",\n Error = \"error\",\n Success = \"success\",\n}\n\nexport type IcInformationStatusOrEmpty = \"warning\" | \"error\" | \"success\" | \"\";\n\nexport type IcNavType = \"side\" | \"top\" | \"page-header\";\n\n// From: https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete\nexport type IcAutocompleteTypes =\n | \"on\"\n | \"off\"\n | \"name\"\n | \"honorific-prefix\"\n | \"given-name\"\n | \"additional-name\"\n | \"family-name\"\n | \"honorific-suffix\"\n | \"nickname\"\n | \"email\"\n | \"username\"\n | \"new-password\"\n | \"current-password\"\n | \"one-time-code\"\n | \"organization-title\"\n | \"organization\"\n | \"street-address\"\n | \"address-line1\"\n | \"address-line2\"\n | \"address-line3\"\n | \"address-level4\"\n | \"address-level3\"\n | \"address-level2\"\n | \"address-level1\"\n | \"country\"\n | \"country-name\"\n | \"postal-code\"\n | \"cc-name\"\n | \"cc-given-name\"\n | \"cc-additional-name\"\n | \"cc-family-name\"\n | \"cc-family-name\"\n | \"cc-number\"\n | \"cc-exp\"\n | \"cc-exp-month\"\n | \"cc-exp-year\"\n | \"cc-csc\"\n | \"cc-type\"\n | \"transaction-currency\"\n | \"transaction-amount\"\n | \"language\"\n | \"bday\"\n | \"bday-day\"\n | \"bday-month\"\n | \"bday-year\"\n | \"sex\"\n | \"tel\"\n | \"tel-country-code\"\n | \"tel-national\"\n | \"tel-area-code\"\n | \"tel-local\"\n | \"tel-extension\"\n | \"impp\"\n | \"url\"\n | \"photo\";\n\nexport type IcAlignment = \"left\" | \"center\" | \"full-width\";\n\nexport enum IcThemeForegroundEnum {\n Default = \"default\",\n Dark = \"dark\",\n Light = \"light\",\n}\n\nexport type IcThemeForeground = \"default\" | \"dark\" | \"light\";\n\nexport type IcThemeForegroundNoDefault = \"dark\" | \"light\";\n\nexport type IcTheme = {\n mode: IcThemeForeground;\n color: IcColorRGB;\n};\n\nexport type IcAdditionalFieldTypes = \"static\" | \"dynamic\";\n\nexport type IcColorRGB = {\n r: number;\n g: number;\n b: number;\n};\n\nexport type IcColorRGBA = IcColorRGB & {\n a: number;\n};\n\nexport type IcActivationTypes = \"automatic\" | \"manual\";\n\nexport type IcAutocorrectStates = \"on\" | \"off\";\n\nexport type IcNavParentDetails = {\n navType: IcNavType | \"\";\n parent: HTMLElement;\n};\n\nexport type IcTypographyVariants =\n | \"h1\"\n | \"h2\"\n | \"h3\"\n | \"h4\"\n | \"subtitle-large\"\n | \"subtitle-small\"\n | \"body\"\n | \"label\"\n | \"label-uppercase\"\n | \"caption\"\n | \"caption-uppercase\"\n | \"code-large\"\n | \"code-small\"\n | \"code-extra-small\";\n\n/**\n * @interface IcMenuOption\n * @field {string} A label field to options. Defaults to \"label\", but can have any custom name.\n * @field {string} A value field to options. Defaults to \"value\", but can have any custom name.\n */\nexport interface IcMenuOption {\n description?: string;\n disabled?: boolean;\n recommended?: boolean;\n children?: IcMenuOption[];\n loading?: boolean;\n timedOut?: boolean;\n [key: string]: any;\n element?: {\n component: any;\n ariaLabel: string;\n };\n icon?: any;\n}\n\nexport type IcSearchMatchPositions = \"start\" | \"anywhere\";\n\nexport type IcCallbackFunctionNoReturn = (...args: unknown[]) => void;\n\nexport type IcRequiredPropsTypes =\n | string\n | boolean\n | number\n | HTMLElement\n | IcMenuOption[];\n\nexport type IcPropObject = { prop: IcRequiredPropsTypes; propName: string };\n\nexport type IcRelatedTarget = EventTarget | undefined;\n\nexport type IcOrientation = \"horizontal\" | \"vertical\";\n\nexport type IcSizes = \"default\" | \"large\" | \"small\";\n\nexport interface IcValueEventDetail {\n value: string;\n keyPressed?: string;\n}\nexport interface IcBlurEventDetail {\n relatedTarget: IcRelatedTarget;\n}\n"],"mappings":"IAwBYA,GAAZ,SAAYA,GACVA,EAAA,qBACAA,EAAA,iBACAA,EAAA,oBACD,EAJD,CAAYA,MAAmB,K,IAsEnBC,GAAZ,SAAYA,GACVA,EAAA,qBACAA,EAAA,eACAA,EAAA,gBACD,EAJD,CAAYA,MAAqB,Y"}
@@ -1,2 +1,2 @@
1
- import{r as t,h as e,H as i,g as o}from"./p-69920d86.js";import{u as s}from"./p-dd980be4.js";import{c as n}from"./p-7c0dcd00.js";import"./p-6f57b13c.js";const a='/*! 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}@media (prefers-reduced-motion: no-preference){:host .opening-from-parent{animation:slide-in var(--ic-transition-duration-slow) ease-in-out}:host .opening-from-child{animation:slide-out var(--ic-transition-duration-slow) ease-in-out}}:host{border-radius:var(--ic-border-radius);color:var(--ic-color-primary-text);background-color:var(--ic-architectural-white);position:relative;z-index:var(--ic-z-index-popover);box-sizing:border-box;box-shadow:var(--ic-elevation-overlay);display:none}:host(.on-dialog){inset:auto !important}:host(.on-dialog-fix-translate){transform:translate(0, var(--ic-space-xs)) !important}:host(.on-dialog-translate-y){transform:translate(0, calc(-1 * var(--translate-y))) !important}.menu{border:var(--ic-border-default);border-radius:var(--ic-border-radius);background-color:var(--ic-architectural-white);visibility:hidden;height:0}.button{text-decoration:none;list-style-type:none}:host(:focus-within){box-shadow:var(--ic-border-focus)}.menu:focus-visible{outline:none}:host(.open){display:block;min-width:calc(20rem - var(--ic-space-xl));width:var(--popover-width, 20rem);max-width:calc(100vw - var(--ic-space-xl))}:host(.open) .menu{visibility:visible;height:-moz-fit-content;height:fit-content;max-height:var(--max-height, -moz-fit-content);max-height:var(--max-height, fit-content);overflow-y:auto;overflow-x:hidden}.parent-label{color:var(--ic-color-tertiary-text);margin:var(--ic-space-xs) var(--ic-space-xs) 0}@keyframes slide-in{from{opacity:0;transform:translateX(10rem)}to{opacity:1;transform:translateX(0)}}@keyframes slide-out{from{opacity:0;transform:translateX(-10rem)}to{opacity:1;transform:translateX(0)}}';const r=class{constructor(e){t(this,e);this.ARIA_LABEL="aria-label";this.firstRender=true;this.popoverMenuEls=[];this.setButtonFocus=()=>{var t;(t=this.popoverMenuEls[this.currentFocus])===null||t===void 0?void 0:t.focus()};this.findAnchorEl=t=>{let e=null;if(t===null||t===undefined){this.submenuId===undefined&&console.error("No anchor specified for popover component")}else{e=document.querySelector(t.indexOf("#")===0?t:"#"+t);if(e===null){console.error(`Popover anchor element '${t}' not found`)}}return e};this.isNotPopoverMenuEl=t=>{const e=t.target;return e.id!==this.anchor&&e.tagName!=="IC-MENU-ITEM"&&e.tagName!=="IC-MENU-GROUP"&&e.tagName!=="IC-POPOVER-MENU"};this.closeMenu=()=>{var t;this.open=false;(t=this.anchorEl)===null||t===void 0?void 0:t.focus()};this.getNextItemToSelect=(t,e)=>{const i=this.popoverMenuEls.length-1;if(t<1){t=0}let o=e?t+1:t-1;if(o<0){o=i}else if(o>i){o=0}return o};this.addMenuItems=t=>{for(let e=0;e<t.length;e++){const i=t[e];if(i.tagName==="IC-MENU-ITEM"){this.popoverMenuEls.push(i)}else if(i.tagName==="IC-MENU-GROUP"){const t=i.shadowRoot.querySelector("ul");const e=s(t);this.addMenuItems(e)}}};this.getMenuAriaLabel=()=>{const t=this.host.getAttribute(this.ARIA_LABEL);if(this.submenuId!==undefined){return`${t}, within nested level ${this.submenuLevel} ${this.parentLabel} submenu,`}else{return t}};this.handleBackButtonClick=()=>{this.parentPopover.openFromChild();this.open=false};this.openingFromChild=false;this.openingFromParent=false;this.anchor=undefined;this.parentLabel=undefined;this.parentPopover=undefined;this.submenuId=undefined;this.submenuLevel=1;this.open=undefined}watchOpenHandler(){if(this.open){if(this.parentPopover!==undefined&&!this.popoverMenuEls.some((t=>t.id))){this.popoverMenuEls.unshift(this.backButton)}this.currentFocus=this.submenuId!==undefined?1:0;setTimeout(this.setButtonFocus,50)}}disconnectedCallback(){if(this.popperInstance!==undefined){this.popperInstance.destroy()}}componentDidLoad(){const t=this.host.shadowRoot.querySelector("ul.button");const e=s(t);if(e!==null){this.addMenuItems(e)}if(this.submenuId===undefined&&this.host.getAttribute(this.ARIA_LABEL)===null){console.error(`No aria-label specified for popover menu component - aria-label required`)}}componentWillRender(){this.anchorEl=this.findAnchorEl(this.anchor)}componentDidRender(){if(this.firstRender&&this.open){this.firstRender=false;let t=false;const e=this.host.closest("ic-dialog");const i=e!==null;if(i){this.host.classList.add("on-dialog");const i=this.host.getBoundingClientRect();const o=e.getBoundingClientRect().bottom;const s=this.anchorEl.getBoundingClientRect().height;let n;if(e.getAttribute("data-overflow")==="false"){if(o-i.top<i.height){t=true;n=i.height+s+8}}else{t=true;n=i.height+s+8+100}if(t===false){this.host.classList.add("on-dialog-fix-translate")}else{this.host.style.setProperty("--translate-y",`${n}px`,"important");this.host.classList.add("on-dialog-translate-y")}}if(t){this.popperInstance=n(this.anchorEl,this.host,{placement:"top"})}else{this.popperInstance=n(this.anchorEl,this.host,{placement:"bottom-start",modifiers:[{name:"offset",options:{offset:[0,4]}},{name:"flip",options:{fallbackPlacements:["top-start","top-end","bottom-end"],rootBoundary:"viewport"}}]})}}else if(this.open){this.popperInstance.update()}}handleMenuItemClick(t){if(!t.detail.hasSubMenu&&t.detail.label!=="Back"){this.closeMenu()}}handleSubmenuChange(t){const e=t.target;this.open=false;const i=document.querySelector(`ic-popover-menu[submenu-id=${e.submenuTriggerFor}]`);i.parentPopover=this.host;i.anchor=this.anchor;i.ariaLabel=this.host.getAttribute(this.ARIA_LABEL);i.openFromParent();i.submenuLevel=this.submenuLevel+1;i.parentLabel=e.label}handleClick(t){if(this.open&&this.isNotPopoverMenuEl(t)){this.closeMenu()}}handleKeyDown(t){switch(t.key){case"ArrowDown":t.preventDefault();this.currentFocus=this.getNextItemToSelect(this.currentFocus,true);this.setButtonFocus();break;case"ArrowUp":t.preventDefault();this.currentFocus=this.getNextItemToSelect(this.currentFocus,false);this.setButtonFocus();break;case"Home":this.currentFocus=0;this.setButtonFocus();break;case"End":this.currentFocus=this.popoverMenuEls.length-1;this.setButtonFocus();break;case"Escape":case"Tab":if(this.open){this.closeMenu();this.host.blur()}break}}async openFromChild(){this.open=true;this.openingFromChild=true;setTimeout((()=>this.openingFromChild=false),1e3)}async openFromParent(){this.open=true;this.openingFromParent=true;setTimeout((()=>this.openingFromParent=false),1e3)}render(){return e(i,{class:{open:this.open}},e("div",{id:this.parentPopover===undefined?`ic-popover-submenu-${this.submenuId}`:"",class:{menu:true},tabindex:open?"0":"-1"},e("div",{class:{"opening-from-parent":this.openingFromParent,"opening-from-child":this.openingFromChild}},this.submenuId!==undefined&&e("div",null,e("ic-menu-item",{class:"ic-popover-submenu-back-button",ref:t=>this.backButton=t,label:"Back",onClick:this.handleBackButtonClick,id:`ic-popover-submenu-back-button-${this.submenuLevel}`},e("svg",{slot:"icon",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",class:"submenu-back-icon"},e("path",{d:"M20 11H7.83L13.42 5.41L12 4L4 12L12 20L13.41 18.59L7.83 13H20V11Z",fill:"currentColor"}))),e("ic-typography",{variant:"subtitle-small",class:"parent-label"},this.parentLabel)),e("ul",{class:"button","aria-label":this.getMenuAriaLabel(),role:"menu","aria-owns":this.submenuId!==undefined?`ic-popover-submenu-back-button-${this.submenuLevel}`:false,"aria-controls":this.submenuId!==undefined?`ic-popover-submenu-back-button-${this.submenuLevel}`:false},e("slot",null)))))}static get delegatesFocus(){return true}get host(){return o(this)}static get watchers(){return{open:["watchOpenHandler"]}}};r.style=a;export{r as ic_popover_menu};
2
- //# sourceMappingURL=p-c4b81d32.entry.js.map
1
+ import{r as t,h as e,H as i,g as o}from"./p-18068237.js";import{u as s}from"./p-ebe76390.js";import{c as n}from"./p-68a5aaff.js";import"./p-613aa265.js";const a='/*! 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}@media (prefers-reduced-motion: no-preference){:host .opening-from-parent{animation:slide-in var(--ic-transition-duration-slow) ease-in-out}:host .opening-from-child{animation:slide-out var(--ic-transition-duration-slow) ease-in-out}}:host{border-radius:var(--ic-border-radius);color:var(--ic-color-primary-text);background-color:var(--ic-architectural-white);position:relative;z-index:var(--ic-z-index-popover);box-sizing:border-box;box-shadow:var(--ic-elevation-overlay);display:none}:host(.on-dialog){inset:auto !important}:host(.on-dialog-fix-translate){transform:translate(0, var(--ic-space-xs)) !important}:host(.on-dialog-translate-y){transform:translate(0, calc(-1 * var(--translate-y))) !important}.menu{border:var(--ic-border-default);border-radius:var(--ic-border-radius);background-color:var(--ic-architectural-white);visibility:hidden;height:0}.button{text-decoration:none;list-style-type:none}:host(:focus-within){box-shadow:var(--ic-border-focus)}.menu:focus-visible{outline:none}:host(.open){display:block;min-width:calc(20rem - var(--ic-space-xl));width:var(--popover-width, 20rem);max-width:calc(100vw - var(--ic-space-xl))}:host(.open) .menu{visibility:visible;height:-moz-fit-content;height:fit-content;max-height:var(--max-height, -moz-fit-content);max-height:var(--max-height, fit-content);overflow-y:auto;overflow-x:hidden}.parent-label{color:var(--ic-color-tertiary-text);margin:var(--ic-space-xs) var(--ic-space-xs) 0}@keyframes slide-in{from{opacity:0;transform:translateX(10rem)}to{opacity:1;transform:translateX(0)}}@keyframes slide-out{from{opacity:0;transform:translateX(-10rem)}to{opacity:1;transform:translateX(0)}}';const r=class{constructor(e){t(this,e);this.ARIA_LABEL="aria-label";this.firstRender=true;this.popoverMenuEls=[];this.setButtonFocus=()=>{var t;(t=this.popoverMenuEls[this.currentFocus])===null||t===void 0?void 0:t.focus()};this.findAnchorEl=t=>{let e=null;if(t===null||t===undefined){this.submenuId===undefined&&console.error("No anchor specified for popover component")}else{e=document.querySelector(t.indexOf("#")===0?t:"#"+t);if(e===null){console.error(`Popover anchor element '${t}' not found`)}}return e};this.isNotPopoverMenuEl=t=>{const e=t.target;return e.id!==this.anchor&&e.tagName!=="IC-MENU-ITEM"&&e.tagName!=="IC-MENU-GROUP"&&e.tagName!=="IC-POPOVER-MENU"};this.closeMenu=()=>{var t;this.open=false;(t=this.anchorEl)===null||t===void 0?void 0:t.focus()};this.getNextItemToSelect=(t,e)=>{const i=this.popoverMenuEls.length-1;if(t<1){t=0}let o=e?t+1:t-1;if(o<0){o=i}else if(o>i){o=0}return o};this.addMenuItems=t=>{for(let e=0;e<t.length;e++){const i=t[e];if(i.tagName==="IC-MENU-ITEM"){this.popoverMenuEls.push(i)}else if(i.tagName==="IC-MENU-GROUP"){const t=i.shadowRoot.querySelector("ul");const e=s(t);this.addMenuItems(e)}}};this.getMenuAriaLabel=()=>{const t=this.host.getAttribute(this.ARIA_LABEL);if(this.submenuId!==undefined){return`${t}, within nested level ${this.submenuLevel} ${this.parentLabel} submenu,`}else{return t}};this.handleBackButtonClick=()=>{this.parentPopover.openFromChild();this.open=false};this.openingFromChild=false;this.openingFromParent=false;this.anchor=undefined;this.parentLabel=undefined;this.parentPopover=undefined;this.submenuId=undefined;this.submenuLevel=1;this.open=undefined}watchOpenHandler(){if(this.open){if(this.parentPopover!==undefined&&!this.popoverMenuEls.some((t=>t.id))){this.popoverMenuEls.unshift(this.backButton)}this.currentFocus=this.submenuId!==undefined?1:0;setTimeout(this.setButtonFocus,50)}}disconnectedCallback(){if(this.popperInstance!==undefined){this.popperInstance.destroy()}}componentDidLoad(){const t=this.host.shadowRoot.querySelector("ul.button");const e=s(t);if(e!==null){this.addMenuItems(e)}if(this.submenuId===undefined&&this.host.getAttribute(this.ARIA_LABEL)===null){console.error(`No aria-label specified for popover menu component - aria-label required`)}}componentWillRender(){this.anchorEl=this.findAnchorEl(this.anchor)}componentDidRender(){if(this.firstRender&&this.open){this.firstRender=false;let t=false;const e=this.host.closest("ic-dialog");const i=e!==null;if(i){this.host.classList.add("on-dialog");const i=this.host.getBoundingClientRect();const o=e.getBoundingClientRect().bottom;const s=this.anchorEl.getBoundingClientRect().height;let n;if(e.getAttribute("data-overflow")==="false"){if(o-i.top<i.height){t=true;n=i.height+s+8}}else{t=true;n=i.height+s+8+100}if(t===false){this.host.classList.add("on-dialog-fix-translate")}else{this.host.style.setProperty("--translate-y",`${n}px`,"important");this.host.classList.add("on-dialog-translate-y")}}if(t){this.popperInstance=n(this.anchorEl,this.host,{placement:"top"})}else{this.popperInstance=n(this.anchorEl,this.host,{placement:"bottom-start",modifiers:[{name:"offset",options:{offset:[0,4]}},{name:"flip",options:{fallbackPlacements:["top-start","top-end","bottom-end"],rootBoundary:"viewport"}}]})}}else if(this.open){this.popperInstance.update()}}handleMenuItemClick(t){if(!t.detail.hasSubMenu&&t.detail.label!=="Back"){this.closeMenu()}}handleSubmenuChange(t){const e=t.target;this.open=false;const i=document.querySelector(`ic-popover-menu[submenu-id=${e.submenuTriggerFor}]`);i.parentPopover=this.host;i.anchor=this.anchor;i.ariaLabel=this.host.getAttribute(this.ARIA_LABEL);i.openFromParent();i.submenuLevel=this.submenuLevel+1;i.parentLabel=e.label}handleClick(t){if(this.open&&this.isNotPopoverMenuEl(t)){this.closeMenu()}}handleKeyDown(t){switch(t.key){case"ArrowDown":t.preventDefault();this.currentFocus=this.getNextItemToSelect(this.currentFocus,true);this.setButtonFocus();break;case"ArrowUp":t.preventDefault();this.currentFocus=this.getNextItemToSelect(this.currentFocus,false);this.setButtonFocus();break;case"Home":this.currentFocus=0;this.setButtonFocus();break;case"End":this.currentFocus=this.popoverMenuEls.length-1;this.setButtonFocus();break;case"Escape":case"Tab":if(this.open){this.closeMenu();this.host.blur()}break}}async openFromChild(){this.open=true;this.openingFromChild=true;setTimeout((()=>this.openingFromChild=false),1e3)}async openFromParent(){this.open=true;this.openingFromParent=true;setTimeout((()=>this.openingFromParent=false),1e3)}render(){return e(i,{class:{open:this.open}},e("div",{id:this.parentPopover===undefined?`ic-popover-submenu-${this.submenuId}`:"",class:{menu:true},tabindex:open?"0":"-1"},e("div",{class:{"opening-from-parent":this.openingFromParent,"opening-from-child":this.openingFromChild}},this.submenuId!==undefined&&e("div",null,e("ic-menu-item",{class:"ic-popover-submenu-back-button",ref:t=>this.backButton=t,label:"Back",onClick:this.handleBackButtonClick,id:`ic-popover-submenu-back-button-${this.submenuLevel}`},e("svg",{slot:"icon",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",class:"submenu-back-icon"},e("path",{d:"M20 11H7.83L13.42 5.41L12 4L4 12L12 20L13.41 18.59L7.83 13H20V11Z",fill:"currentColor"}))),e("ic-typography",{variant:"subtitle-small",class:"parent-label"},this.parentLabel)),e("ul",{class:"button","aria-label":this.getMenuAriaLabel(),role:"menu","aria-owns":this.submenuId!==undefined?`ic-popover-submenu-back-button-${this.submenuLevel}`:false,"aria-controls":this.submenuId!==undefined?`ic-popover-submenu-back-button-${this.submenuLevel}`:false},e("slot",null)))))}static get delegatesFocus(){return true}get host(){return o(this)}static get watchers(){return{open:["watchOpenHandler"]}}};r.style=a;export{r as ic_popover_menu};
2
+ //# sourceMappingURL=p-62499150.entry.js.map