@swisspost/design-system-components 9.0.0-next.3 → 9.0.0-next.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (539) hide show
  1. package/dist/.config/bindings.angular.js +4 -0
  2. package/dist/cjs/{attribute-observer-10f08c04.js → attribute-observer-6d8b886b.js} +4 -4
  3. package/dist/cjs/breakpoints-c6247c71.js +54 -0
  4. package/dist/cjs/check-non-empty-bd99d236.js +15 -0
  5. package/dist/cjs/check-one-of-75d270b5.js +13 -0
  6. package/dist/cjs/check-type-cdbf6d29.js +21 -0
  7. package/dist/cjs/check-url-220a286c.js +19 -0
  8. package/dist/cjs/debounce-158fd76f.js +13 -0
  9. package/dist/cjs/fade-72d5ef55.js +14 -0
  10. package/dist/cjs/get-root-7a3498ef.js +11 -0
  11. package/dist/cjs/index-23e36ff7.js +37 -0
  12. package/dist/cjs/{index-e1f32cce.js → index-d6bf2c66.js} +30 -18
  13. package/dist/cjs/index.browser-2f65f583.js +15 -0
  14. package/dist/cjs/index.cjs.js +56 -30
  15. package/dist/cjs/loader.cjs.js +2 -2
  16. package/dist/cjs/{package-ef26e62c.js → package-c3dbd35b.js} +1 -1
  17. package/dist/cjs/{post-accordion-3878bf43.js → post-accordion-2108bc31.js} +9 -8
  18. package/dist/cjs/post-accordion-item-64051590.js +64 -0
  19. package/dist/cjs/post-accordion-item.cjs.entry.js +8 -5
  20. package/dist/cjs/post-accordion.cjs.entry.js +4 -4
  21. package/dist/cjs/{post-avatar-2bcfc016.js → post-avatar-2db58753.js} +10 -14
  22. package/dist/cjs/post-avatar.cjs.entry.js +4 -4
  23. package/dist/cjs/post-back-to-top-e64d70c8.js +76 -0
  24. package/dist/cjs/post-back-to-top.cjs.entry.js +15 -0
  25. package/dist/cjs/post-banner-caa5e06d.js +96 -0
  26. package/dist/cjs/post-banner.cjs.entry.js +19 -0
  27. package/dist/cjs/post-breadcrumb-acb6890e.js +112 -0
  28. package/dist/cjs/post-breadcrumb-item_2.cjs.entry.js +17 -0
  29. package/dist/cjs/post-breadcrumb.cjs.entry.js +13 -0
  30. package/dist/cjs/post-card-control-e2421427.js +283 -0
  31. package/dist/cjs/post-card-control.cjs.entry.js +5 -5
  32. package/dist/cjs/post-closebutton_15.cjs.entry.js +35 -0
  33. package/dist/cjs/{post-collapsible-trigger-6ae59c64.js → post-collapsible-trigger-13b87403.js} +50 -56
  34. package/dist/cjs/post-collapsible_2.cjs.entry.js +10 -6
  35. package/dist/cjs/post-components.cjs.js +2 -2
  36. package/dist/cjs/post-footer-057ce0a8.js +38 -0
  37. package/dist/cjs/post-footer.cjs.entry.js +12 -0
  38. package/dist/cjs/post-linkarea-e2b39f1a.js +30 -0
  39. package/dist/cjs/post-linkarea.cjs.entry.js +11 -0
  40. package/dist/cjs/post-menu-item-3f6c1fcb.js +68 -0
  41. package/dist/cjs/post-popover-dccede57.js +106 -0
  42. package/dist/cjs/post-popover.cjs.entry.js +4 -4
  43. package/dist/cjs/{post-rating-1d2c59b7.js → post-rating-bec67143.js} +16 -6
  44. package/dist/cjs/post-rating.cjs.entry.js +3 -3
  45. package/dist/cjs/post-tab-header-d32947dc.js +33 -0
  46. package/dist/cjs/post-tab-header.cjs.entry.js +5 -4
  47. package/dist/cjs/{post-tab-panel-80b1f3ee.js → post-tab-panel-07d462ac.js} +6 -5
  48. package/dist/cjs/post-tab-panel.cjs.entry.js +4 -3
  49. package/dist/cjs/{post-tabs-c2d42035.js → post-tabs-e5e71053.js} +23 -16
  50. package/dist/cjs/post-tabs.cjs.entry.js +4 -4
  51. package/dist/cjs/post-tag-380a1bf0.js +47 -0
  52. package/dist/cjs/post-tag.cjs.entry.js +3 -3
  53. package/dist/cjs/post-togglebutton-553316f3.js +3965 -0
  54. package/dist/cjs/{post-tooltip-9a120b2e.js → post-tooltip-40812a6b.js} +38 -25
  55. package/dist/cjs/post-tooltip.cjs.entry.js +8 -6
  56. package/dist/cjs/slide-cd1f09b3.js +28 -0
  57. package/dist/collection/animations/collapse.js +5 -5
  58. package/dist/collection/animations/fade.js +6 -2
  59. package/dist/collection/animations/slide.js +23 -0
  60. package/dist/collection/collection-manifest.json +20 -3
  61. package/dist/collection/components/post-accordion/post-accordion.css +1 -1
  62. package/dist/collection/components/post-accordion/post-accordion.js +5 -3
  63. package/dist/collection/components/post-accordion-item/post-accordion-item.css +1 -1
  64. package/dist/collection/components/post-accordion-item/post-accordion-item.js +26 -9
  65. package/dist/collection/components/post-avatar/post-avatar.js +8 -11
  66. package/dist/collection/components/post-back-to-top/post-back-to-top.css +1 -0
  67. package/dist/collection/components/post-back-to-top/post-back-to-top.js +109 -0
  68. package/dist/collection/components/post-banner/banner-types.js +1 -0
  69. package/dist/collection/components/post-banner/post-banner.css +3 -0
  70. package/dist/collection/components/{post-alert/post-alert.js → post-banner/post-banner.js} +50 -72
  71. package/dist/collection/components/post-breadcrumb/post-breadcrumb.css +3 -0
  72. package/dist/collection/components/post-breadcrumb/post-breadcrumb.js +163 -0
  73. package/dist/collection/components/post-breadcrumb-item/post-breadcrumb-item.css +1 -0
  74. package/dist/collection/components/post-breadcrumb-item/post-breadcrumb-item.js +98 -0
  75. package/dist/collection/components/post-card-control/post-card-control.css +1 -1
  76. package/dist/collection/components/post-card-control/post-card-control.js +55 -43
  77. package/dist/collection/components/post-closebutton/post-closebutton.js +13 -0
  78. package/dist/collection/components/post-collapsible/post-collapsible.css +1 -1
  79. package/dist/collection/components/post-collapsible/post-collapsible.js +15 -6
  80. package/dist/collection/components/post-collapsible-trigger/post-collapsible-trigger.js +21 -20
  81. package/dist/collection/components/post-footer/post-footer.css +1 -0
  82. package/dist/collection/components/post-footer/post-footer.js +76 -0
  83. package/dist/collection/components/post-header/post-header.css +1 -0
  84. package/dist/collection/components/post-header/post-header.js +323 -0
  85. package/dist/collection/components/post-icon/post-icon.js +79 -46
  86. package/dist/collection/components/post-language-option/post-language-option.css +1 -1
  87. package/dist/collection/components/post-language-option/post-language-option.js +65 -10
  88. package/dist/collection/components/post-language-switch/post-language-switch.css +1 -0
  89. package/dist/collection/components/post-language-switch/post-language-switch.js +192 -0
  90. package/dist/collection/components/post-language-switch/switch-variants.js +1 -0
  91. package/dist/collection/components/post-linkarea/post-linkarea.css +1 -0
  92. package/dist/collection/components/post-linkarea/post-linkarea.js +30 -0
  93. package/dist/collection/components/post-list/post-list.css +3 -0
  94. package/dist/collection/components/post-list/post-list.js +90 -0
  95. package/dist/collection/components/post-list-item/post-list-item.css +1 -0
  96. package/dist/collection/components/post-list-item/post-list-item.js +26 -0
  97. package/dist/collection/components/post-logo/post-logo.css +1 -1
  98. package/dist/collection/components/post-logo/post-logo.js +3 -2
  99. package/dist/collection/components/post-mainnavigation/post-mainnavigation.css +1 -0
  100. package/dist/collection/components/post-mainnavigation/post-mainnavigation.js +267 -0
  101. package/dist/collection/components/post-megadropdown/post-megadropdown.css +1 -0
  102. package/dist/collection/components/post-megadropdown/post-megadropdown.js +284 -0
  103. package/dist/collection/components/post-megadropdown-trigger/post-megadropdown-trigger.css +1 -0
  104. package/dist/collection/components/post-megadropdown-trigger/post-megadropdown-trigger.js +127 -0
  105. package/dist/collection/components/post-menu/post-menu.css +3 -0
  106. package/dist/collection/components/post-menu/post-menu.js +297 -0
  107. package/dist/collection/components/post-menu-item/post-menu-item.js +8 -0
  108. package/dist/collection/components/post-menu-trigger/post-menu-trigger.css +1 -0
  109. package/dist/collection/components/post-menu-trigger/post-menu-trigger.js +122 -0
  110. package/dist/collection/components/post-popover/post-popover.css +1 -1
  111. package/dist/collection/components/post-popover/post-popover.js +6 -3
  112. package/dist/collection/components/post-popovercontainer/post-popovercontainer.css +1 -1
  113. package/dist/collection/components/post-popovercontainer/post-popovercontainer.js +203 -39
  114. package/dist/collection/components/post-rating/post-rating.css +1 -1
  115. package/dist/collection/components/post-rating/post-rating.js +13 -2
  116. package/dist/collection/components/post-tab-header/post-tab-header.css +2 -2
  117. package/dist/collection/components/post-tab-header/post-tab-header.js +6 -4
  118. package/dist/collection/components/post-tab-panel/post-tab-panel.js +4 -2
  119. package/dist/collection/components/post-tabs/post-tabs.css +1 -1
  120. package/dist/collection/components/post-tabs/post-tabs.js +17 -14
  121. package/dist/collection/components/post-tag/post-tag.css +1 -1
  122. package/dist/collection/components/post-tag/post-tag.js +3 -2
  123. package/dist/collection/components/post-togglebutton/post-togglebutton.css +1 -0
  124. package/dist/collection/components/post-togglebutton/post-togglebutton.js +75 -0
  125. package/dist/collection/components/post-tooltip/post-tooltip.css +1 -1
  126. package/dist/collection/components/post-tooltip/post-tooltip.js +35 -17
  127. package/dist/collection/index.js +19 -2
  128. package/dist/collection/utils/attribute-observer.js +4 -4
  129. package/dist/collection/utils/breakpoints.js +50 -0
  130. package/dist/collection/utils/component-on-ready.js +4 -4
  131. package/dist/collection/utils/debounce.js +2 -1
  132. package/dist/collection/utils/get-focusable-children.js +33 -0
  133. package/dist/collection/utils/property-checkers/check-non-empty.js +6 -2
  134. package/dist/collection/utils/property-checkers/check-one-of.js +8 -3
  135. package/dist/collection/utils/property-checkers/check-pattern.js +8 -3
  136. package/dist/collection/utils/property-checkers/check-type.js +11 -6
  137. package/dist/collection/utils/property-checkers/check-url.js +11 -6
  138. package/dist/collection/utils/property-checkers/empty-or.js +5 -2
  139. package/dist/collection/utils/sass-export.js +8 -5
  140. package/dist/components/attribute-observer.js +4 -4
  141. package/dist/components/breakpoints.js +52 -0
  142. package/dist/components/check-non-empty.js +6 -2
  143. package/dist/components/check-one-of.js +8 -3
  144. package/dist/components/check-type.js +11 -6
  145. package/dist/components/debounce.js +11 -0
  146. package/dist/components/fade.js +6 -2
  147. package/dist/components/get-focusable-children.js +35 -0
  148. package/dist/components/get-root.js +9 -0
  149. package/dist/components/index.browser.js +13 -0
  150. package/dist/components/index.js +19 -2
  151. package/dist/components/index2.js +25 -12
  152. package/dist/components/package.js +1 -1
  153. package/dist/components/post-accordion-item2.js +33 -14
  154. package/dist/components/post-accordion2.js +6 -5
  155. package/dist/components/post-avatar2.js +7 -11
  156. package/dist/components/post-back-to-top.d.ts +11 -0
  157. package/dist/components/post-back-to-top.js +6 -0
  158. package/dist/components/post-back-to-top2.js +101 -0
  159. package/dist/components/post-banner.d.ts +11 -0
  160. package/dist/components/post-banner.js +6 -0
  161. package/dist/components/post-banner2.js +131 -0
  162. package/dist/components/post-breadcrumb-item.d.ts +11 -0
  163. package/dist/components/post-breadcrumb-item.js +6 -0
  164. package/dist/components/post-breadcrumb-item2.js +82 -0
  165. package/dist/components/post-breadcrumb.d.ts +11 -0
  166. package/dist/components/post-breadcrumb.js +6 -0
  167. package/dist/components/post-breadcrumb2.js +169 -0
  168. package/dist/components/post-card-control2.js +50 -39
  169. package/dist/components/post-closebutton.d.ts +11 -0
  170. package/dist/components/post-closebutton.js +6 -0
  171. package/dist/components/post-closebutton2.js +34 -0
  172. package/dist/components/post-collapsible-trigger2.js +23 -38
  173. package/dist/components/post-collapsible2.js +22 -14
  174. package/dist/components/post-footer.d.ts +11 -0
  175. package/dist/components/post-footer.js +6 -0
  176. package/dist/components/post-footer2.js +78 -0
  177. package/dist/components/post-header.d.ts +11 -0
  178. package/dist/components/post-header.js +6 -0
  179. package/dist/components/post-header2.js +401 -0
  180. package/dist/components/post-icon2.js +81 -45
  181. package/dist/components/post-language-option2.js +32 -14
  182. package/dist/components/post-language-switch.d.ts +11 -0
  183. package/dist/components/post-language-switch.js +6 -0
  184. package/dist/components/post-language-switch2.js +148 -0
  185. package/dist/components/post-linkarea.d.ts +11 -0
  186. package/dist/components/post-linkarea.js +6 -0
  187. package/dist/components/post-linkarea2.js +42 -0
  188. package/dist/components/post-list-item.d.ts +11 -0
  189. package/dist/components/post-list-item.js +6 -0
  190. package/dist/components/post-list-item2.js +35 -0
  191. package/dist/components/{post-alert.d.ts → post-list.d.ts} +4 -4
  192. package/dist/components/post-list.js +6 -0
  193. package/dist/components/post-list2.js +55 -0
  194. package/dist/components/post-logo2.js +4 -4
  195. package/dist/components/post-mainnavigation.d.ts +11 -0
  196. package/dist/components/post-mainnavigation.js +6 -0
  197. package/dist/components/post-mainnavigation2.js +270 -0
  198. package/dist/components/post-megadropdown-trigger.d.ts +11 -0
  199. package/dist/components/post-megadropdown-trigger.js +6 -0
  200. package/dist/components/post-megadropdown-trigger2.js +113 -0
  201. package/dist/components/post-megadropdown.d.ts +11 -0
  202. package/dist/components/post-megadropdown.js +6 -0
  203. package/dist/components/post-megadropdown2.js +198 -0
  204. package/dist/components/post-menu-item.d.ts +11 -0
  205. package/dist/components/post-menu-item.js +6 -0
  206. package/dist/components/post-menu-item2.js +27 -0
  207. package/dist/components/post-menu-trigger.d.ts +11 -0
  208. package/dist/components/post-menu-trigger.js +6 -0
  209. package/dist/components/post-menu-trigger2.js +109 -0
  210. package/dist/components/post-menu.d.ts +11 -0
  211. package/dist/components/post-menu.js +6 -0
  212. package/dist/components/post-menu2.js +193 -0
  213. package/dist/components/post-popover2.js +6 -4
  214. package/dist/components/post-popovercontainer2.js +249 -72
  215. package/dist/components/post-rating2.js +14 -4
  216. package/dist/components/post-tab-header2.js +7 -6
  217. package/dist/components/post-tab-panel2.js +4 -3
  218. package/dist/components/post-tabs2.js +20 -13
  219. package/dist/components/post-tag2.js +3 -3
  220. package/dist/components/post-togglebutton.d.ts +11 -0
  221. package/dist/components/post-togglebutton.js +6 -0
  222. package/dist/components/post-togglebutton2.js +61 -0
  223. package/dist/components/post-tooltip2.js +35 -22
  224. package/dist/components/slide.js +25 -0
  225. package/dist/docs.json +1653 -186
  226. package/dist/esm/{attribute-observer-37fa950a.js → attribute-observer-2f203993.js} +4 -4
  227. package/dist/esm/breakpoints-bbe0c54e.js +52 -0
  228. package/dist/esm/check-non-empty-258a56b3.js +13 -0
  229. package/dist/esm/check-one-of-0bee20f5.js +11 -0
  230. package/dist/esm/check-type-37d5d307.js +19 -0
  231. package/dist/esm/check-url-17962bc8.js +17 -0
  232. package/dist/esm/debounce-e54c7131.js +11 -0
  233. package/dist/esm/fade-1f3cacf4.js +11 -0
  234. package/dist/esm/get-root-7af2e0d1.js +9 -0
  235. package/dist/esm/{index-e1b64755.js → index-3419e46d.js} +30 -18
  236. package/dist/esm/index-8f8fe5b0.js +32 -0
  237. package/dist/esm/index.browser-51485f85.js +13 -0
  238. package/dist/esm/index.js +33 -24
  239. package/dist/esm/loader.js +3 -3
  240. package/dist/esm/package-da1ccbc7.js +3 -0
  241. package/dist/esm/{post-accordion-01d49d83.js → post-accordion-f5e449c0.js} +9 -8
  242. package/dist/esm/post-accordion-item-1195d94a.js +62 -0
  243. package/dist/esm/post-accordion-item.entry.js +8 -5
  244. package/dist/esm/post-accordion.entry.js +4 -4
  245. package/dist/esm/{post-avatar-6f24d1ab.js → post-avatar-9b85c11c.js} +10 -14
  246. package/dist/esm/post-avatar.entry.js +4 -4
  247. package/dist/esm/post-back-to-top-335075d4.js +74 -0
  248. package/dist/esm/post-back-to-top.entry.js +7 -0
  249. package/dist/esm/post-banner-6b939740.js +94 -0
  250. package/dist/esm/post-banner.entry.js +11 -0
  251. package/dist/esm/post-breadcrumb-5a61269c.js +110 -0
  252. package/dist/esm/post-breadcrumb-item_2.entry.js +8 -0
  253. package/dist/esm/post-breadcrumb.entry.js +5 -0
  254. package/dist/esm/post-card-control-7fe3804c.js +281 -0
  255. package/dist/esm/post-card-control.entry.js +5 -5
  256. package/dist/esm/post-closebutton_15.entry.js +13 -0
  257. package/dist/esm/{post-collapsible-trigger-654bf2b0.js → post-collapsible-trigger-e3ef47ff.js} +49 -55
  258. package/dist/esm/post-collapsible_2.entry.js +10 -6
  259. package/dist/esm/post-components.js +3 -3
  260. package/dist/esm/post-footer-e68c21a1.js +36 -0
  261. package/dist/esm/post-footer.entry.js +4 -0
  262. package/dist/esm/post-linkarea-bc607c52.js +28 -0
  263. package/dist/esm/post-linkarea.entry.js +3 -0
  264. package/dist/esm/post-menu-item-ab01683c.js +65 -0
  265. package/dist/esm/{post-popover-7d44a85c.js → post-popover-7427bb6d.js} +9 -7
  266. package/dist/esm/post-popover.entry.js +4 -4
  267. package/dist/esm/{post-rating-3cd3e97b.js → post-rating-16c9ada8.js} +16 -6
  268. package/dist/esm/post-rating.entry.js +3 -3
  269. package/dist/esm/post-tab-header-e0f39999.js +31 -0
  270. package/dist/esm/post-tab-header.entry.js +5 -4
  271. package/dist/esm/{post-tab-panel-163e6c99.js → post-tab-panel-9a8b852c.js} +6 -5
  272. package/dist/esm/post-tab-panel.entry.js +4 -3
  273. package/dist/esm/{post-tabs-8cb1bce9.js → post-tabs-34f70c88.js} +23 -16
  274. package/dist/esm/post-tabs.entry.js +4 -4
  275. package/dist/esm/post-tag-ec5578c2.js +45 -0
  276. package/dist/esm/post-tag.entry.js +3 -3
  277. package/dist/esm/post-togglebutton-5fb5e500.js +3949 -0
  278. package/dist/esm/{post-tooltip-dc7e1a21.js → post-tooltip-c201c4db.js} +38 -25
  279. package/dist/esm/post-tooltip.entry.js +8 -6
  280. package/dist/esm/slide-cd2850ee.js +25 -0
  281. package/dist/post-components/index.esm.js +1 -1
  282. package/dist/post-components/p-02f1cb03.js +1 -0
  283. package/dist/post-components/p-037755f5.js +1 -0
  284. package/dist/post-components/p-11cac89a.js +1 -0
  285. package/dist/post-components/p-181c73d5.js +1 -0
  286. package/dist/post-components/p-2995938c.entry.js +1 -0
  287. package/dist/post-components/p-2adbc7bf.js +1 -0
  288. package/dist/post-components/p-2ea2ced2.js +1 -0
  289. package/dist/post-components/p-2ff7f948.js +1 -0
  290. package/dist/post-components/p-32815e91.js +1 -0
  291. package/dist/post-components/{p-0ad93d89.js → p-33a5eac4.js} +3 -3
  292. package/dist/post-components/p-38c39936.js +1 -0
  293. package/dist/post-components/p-3a9ddb5a.entry.js +1 -0
  294. package/dist/post-components/p-3dbda892.entry.js +1 -0
  295. package/dist/post-components/p-3ea156c8.js +1 -0
  296. package/dist/post-components/p-4620784a.entry.js +1 -0
  297. package/dist/post-components/p-52231570.entry.js +1 -0
  298. package/dist/post-components/p-54ecbfaf.entry.js +1 -0
  299. package/dist/post-components/p-5959f2bd.js +1 -0
  300. package/dist/post-components/p-5aeb3656.js +1 -0
  301. package/dist/post-components/{p-3eab790d.js → p-5c758f41.js} +1 -1
  302. package/dist/post-components/p-61946a7e.js +1 -0
  303. package/dist/post-components/p-64e3de38.js +1 -0
  304. package/dist/post-components/p-66f2e7cb.js +1 -0
  305. package/dist/post-components/p-6912bf0f.entry.js +1 -0
  306. package/dist/post-components/p-691c07e3.entry.js +1 -0
  307. package/dist/post-components/p-6ed2e162.js +1 -0
  308. package/dist/post-components/p-712670a6.js +1 -0
  309. package/dist/post-components/p-7709c14a.js +1 -0
  310. package/dist/post-components/p-7f695ad8.js +1 -0
  311. package/dist/post-components/p-804c1f5f.entry.js +1 -0
  312. package/dist/post-components/p-85fdc2d3.js +1 -0
  313. package/dist/post-components/p-8779d765.entry.js +1 -0
  314. package/dist/post-components/p-8d625b78.entry.js +1 -0
  315. package/dist/post-components/p-9748a355.js +1 -0
  316. package/dist/post-components/p-9b052461.js +1 -0
  317. package/dist/post-components/p-a205b34d.entry.js +1 -0
  318. package/dist/post-components/p-b21729d2.entry.js +1 -0
  319. package/dist/post-components/p-b240727d.js +1 -0
  320. package/dist/post-components/p-b5318286.js +1 -0
  321. package/dist/post-components/p-be16b84d.entry.js +1 -0
  322. package/dist/post-components/p-c222539e.js +1 -0
  323. package/dist/post-components/p-c8afafa1.js +1 -0
  324. package/dist/post-components/p-d295b769.entry.js +1 -0
  325. package/dist/post-components/p-d45df336.js +1 -0
  326. package/dist/post-components/p-d58f5eaf.js +1 -0
  327. package/dist/post-components/p-e1baac59.js +1 -0
  328. package/dist/post-components/p-e585c6fe.js +1 -0
  329. package/dist/post-components/p-e644a698.entry.js +1 -0
  330. package/dist/post-components/p-e689bfbb.entry.js +1 -0
  331. package/dist/post-components/p-f17be52c.entry.js +1 -0
  332. package/dist/post-components/p-f4850dea.entry.js +1 -0
  333. package/dist/post-components/p-fc91cbc2.js +1 -0
  334. package/dist/post-components/post-components.esm.js +1 -1
  335. package/dist/types/animations/collapse.d.ts +2 -2
  336. package/dist/types/animations/fade.d.ts +2 -2
  337. package/dist/types/animations/slide.d.ts +2 -0
  338. package/dist/types/components/post-accordion-item/post-accordion-item.d.ts +8 -2
  339. package/dist/types/components/post-avatar/post-avatar.d.ts +1 -1
  340. package/dist/types/components/post-back-to-top/post-back-to-top.d.ts +19 -0
  341. package/dist/types/components/post-banner/banner-types.d.ts +2 -0
  342. package/dist/types/components/post-banner/post-banner.d.ts +49 -0
  343. package/dist/types/components/post-breadcrumb/post-breadcrumb.d.ts +30 -0
  344. package/dist/types/components/post-breadcrumb-item/post-breadcrumb-item.d.ts +20 -0
  345. package/dist/types/components/post-card-control/post-card-control.d.ts +9 -9
  346. package/dist/types/components/post-closebutton/post-closebutton.d.ts +7 -0
  347. package/dist/types/components/post-footer/post-footer.d.ts +23 -0
  348. package/dist/types/components/post-header/post-header.d.ts +51 -0
  349. package/dist/types/components/post-icon/post-icon.d.ts +13 -11
  350. package/dist/types/components/post-language-option/post-language-option.d.ts +13 -4
  351. package/dist/types/components/post-language-switch/post-language-switch.d.ts +39 -0
  352. package/dist/types/components/post-language-switch/switch-variants.d.ts +2 -0
  353. package/dist/types/components/post-linkarea/post-linkarea.d.ts +5 -0
  354. package/dist/types/components/post-list/post-list.d.ts +24 -0
  355. package/dist/types/components/post-list-item/post-list-item.d.ts +8 -0
  356. package/dist/types/components/post-mainnavigation/post-mainnavigation.d.ts +71 -0
  357. package/dist/types/components/post-megadropdown/post-megadropdown.d.ts +59 -0
  358. package/dist/types/components/post-megadropdown-trigger/post-megadropdown-trigger.d.ts +31 -0
  359. package/dist/types/components/post-menu/post-menu.d.ts +48 -0
  360. package/dist/types/components/post-menu-item/post-menu-item.d.ts +3 -0
  361. package/dist/types/components/post-menu-trigger/post-menu-trigger.d.ts +28 -0
  362. package/dist/types/components/post-popovercontainer/post-popovercontainer.d.ts +27 -1
  363. package/dist/types/components/post-tab-header/post-tab-header.d.ts +1 -1
  364. package/dist/types/components/post-tabs/post-tabs.d.ts +1 -1
  365. package/dist/types/components/post-tag/post-tag.d.ts +1 -1
  366. package/dist/types/components/post-togglebutton/post-togglebutton.d.ts +15 -0
  367. package/dist/types/components.d.ts +532 -76
  368. package/dist/types/home/runner/work/design-system/design-system/packages/components/.stencil/.config/bindings.angular.d.ts +2 -0
  369. package/dist/types/index.d.ts +20 -3
  370. package/dist/types/utils/attribute-observer.d.ts +1 -1
  371. package/dist/types/utils/breakpoints.d.ts +12 -0
  372. package/dist/types/utils/component-on-ready.d.ts +1 -1
  373. package/dist/types/utils/get-focusable-children.d.ts +1 -0
  374. package/dist/types/utils/get-root.d.ts +1 -1
  375. package/dist/types/utils/property-checkers/check-non-empty.d.ts +3 -1
  376. package/dist/types/utils/property-checkers/check-one-of.d.ts +3 -1
  377. package/dist/types/utils/property-checkers/check-pattern.d.ts +3 -1
  378. package/dist/types/utils/property-checkers/check-type.d.ts +3 -1
  379. package/dist/types/utils/property-checkers/check-url.d.ts +3 -1
  380. package/dist/types/utils/property-checkers/index.d.ts +12 -4
  381. package/dist/types/utils/sass-export.d.ts +5 -1
  382. package/loaders/attribute-observer.js +4 -4
  383. package/loaders/breakpoints.js +52 -0
  384. package/loaders/check-non-empty.js +6 -2
  385. package/loaders/check-one-of.js +8 -3
  386. package/loaders/check-type.js +11 -6
  387. package/loaders/debounce.js +11 -0
  388. package/loaders/fade.js +6 -2
  389. package/loaders/get-focusable-children.js +35 -0
  390. package/loaders/get-root.js +9 -0
  391. package/loaders/index.browser.js +13 -0
  392. package/loaders/index.d.ts +36 -2
  393. package/loaders/index.js +20 -2
  394. package/loaders/index2.js +25 -12
  395. package/loaders/package.js +1 -1
  396. package/loaders/post-accordion-item.js +1 -82
  397. package/loaders/post-accordion-item2.js +103 -0
  398. package/loaders/post-accordion.js +6 -5
  399. package/loaders/post-avatar.js +7 -11
  400. package/loaders/post-back-to-top.d.ts +11 -0
  401. package/loaders/post-back-to-top.js +104 -0
  402. package/loaders/post-banner.d.ts +11 -0
  403. package/loaders/post-banner.js +134 -0
  404. package/loaders/post-breadcrumb-item.d.ts +11 -0
  405. package/loaders/post-breadcrumb-item.js +6 -0
  406. package/loaders/post-breadcrumb-item2.js +82 -0
  407. package/loaders/post-breadcrumb.d.ts +11 -0
  408. package/loaders/post-breadcrumb.js +172 -0
  409. package/loaders/post-card-control.js +50 -39
  410. package/loaders/post-closebutton.d.ts +11 -0
  411. package/loaders/post-closebutton.js +37 -0
  412. package/loaders/post-collapsible-trigger2.js +23 -38
  413. package/loaders/post-collapsible2.js +21 -13
  414. package/loaders/post-footer.d.ts +11 -0
  415. package/loaders/post-footer.js +81 -0
  416. package/loaders/post-header.d.ts +11 -0
  417. package/loaders/post-header.js +404 -0
  418. package/loaders/post-icon2.js +81 -45
  419. package/loaders/post-language-option.js +31 -13
  420. package/loaders/post-language-switch.d.ts +11 -0
  421. package/loaders/post-language-switch.js +151 -0
  422. package/loaders/post-linkarea.d.ts +11 -0
  423. package/loaders/post-linkarea.js +45 -0
  424. package/loaders/post-list-item.d.ts +11 -0
  425. package/loaders/post-list-item.js +38 -0
  426. package/loaders/{post-alert.d.ts → post-list.d.ts} +4 -4
  427. package/loaders/post-list.js +58 -0
  428. package/loaders/post-logo.js +5 -5
  429. package/loaders/post-mainnavigation.d.ts +11 -0
  430. package/loaders/post-mainnavigation.js +273 -0
  431. package/loaders/post-megadropdown-trigger.d.ts +11 -0
  432. package/loaders/post-megadropdown-trigger.js +116 -0
  433. package/loaders/post-megadropdown.d.ts +11 -0
  434. package/loaders/post-megadropdown.js +201 -0
  435. package/loaders/post-menu-item.d.ts +11 -0
  436. package/loaders/post-menu-item.js +6 -0
  437. package/loaders/post-menu-item2.js +27 -0
  438. package/loaders/post-menu-trigger.d.ts +11 -0
  439. package/loaders/post-menu-trigger.js +6 -0
  440. package/loaders/post-menu-trigger2.js +109 -0
  441. package/loaders/post-menu.d.ts +11 -0
  442. package/loaders/post-menu.js +6 -0
  443. package/loaders/post-menu2.js +193 -0
  444. package/loaders/post-popover.js +6 -4
  445. package/loaders/post-popovercontainer2.js +249 -72
  446. package/loaders/post-rating.js +14 -4
  447. package/loaders/post-tab-header.js +7 -6
  448. package/loaders/post-tab-panel.js +4 -3
  449. package/loaders/post-tabs.js +20 -13
  450. package/loaders/post-tag.js +3 -3
  451. package/loaders/post-togglebutton.d.ts +11 -0
  452. package/loaders/post-togglebutton.js +64 -0
  453. package/loaders/post-tooltip.js +34 -21
  454. package/loaders/slide.js +25 -0
  455. package/package.json +26 -20
  456. package/dist/cjs/check-non-empty-eeaa8f77.js +0 -11
  457. package/dist/cjs/check-one-of-f4f5d0c0.js +0 -8
  458. package/dist/cjs/fade-35a3633a.js +0 -10
  459. package/dist/cjs/index-01f30442.js +0 -52
  460. package/dist/cjs/post-accordion-item-0278e6e2.js +0 -52
  461. package/dist/cjs/post-alert-5f795d9c.js +0 -98
  462. package/dist/cjs/post-alert.cjs.entry.js +0 -16
  463. package/dist/cjs/post-card-control-5ffcd201.js +0 -272
  464. package/dist/cjs/post-icon-1f71aa0f.js +0 -104
  465. package/dist/cjs/post-icon.cjs.entry.js +0 -15
  466. package/dist/cjs/post-language-option-4a3ecaeb.js +0 -67
  467. package/dist/cjs/post-language-option.cjs.entry.js +0 -14
  468. package/dist/cjs/post-logo-7070d727.js +0 -39
  469. package/dist/cjs/post-logo.cjs.entry.js +0 -14
  470. package/dist/cjs/post-popover-de1b8d95.js +0 -104
  471. package/dist/cjs/post-popovercontainer-6a25713a.js +0 -2186
  472. package/dist/cjs/post-popovercontainer.cjs.entry.js +0 -11
  473. package/dist/cjs/post-tab-header-877676bf.js +0 -32
  474. package/dist/cjs/post-tag-5e2c7798.js +0 -47
  475. package/dist/collection/components/post-alert/alert-types.js +0 -1
  476. package/dist/collection/components/post-alert/post-alert.css +0 -7
  477. package/dist/components/post-alert.js +0 -6
  478. package/dist/components/post-alert2.js +0 -136
  479. package/dist/esm/check-non-empty-58bd6b17.js +0 -9
  480. package/dist/esm/check-one-of-6b3ef8eb.js +0 -6
  481. package/dist/esm/fade-7fd71785.js +0 -7
  482. package/dist/esm/index-f41b763f.js +0 -46
  483. package/dist/esm/package-0311770e.js +0 -3
  484. package/dist/esm/post-accordion-item-366f385b.js +0 -50
  485. package/dist/esm/post-alert-5a69f40d.js +0 -96
  486. package/dist/esm/post-alert.entry.js +0 -8
  487. package/dist/esm/post-card-control-2a7939c3.js +0 -270
  488. package/dist/esm/post-icon-885f17e9.js +0 -102
  489. package/dist/esm/post-icon.entry.js +0 -7
  490. package/dist/esm/post-language-option-0c2818aa.js +0 -65
  491. package/dist/esm/post-language-option.entry.js +0 -6
  492. package/dist/esm/post-logo-dd425f2e.js +0 -37
  493. package/dist/esm/post-logo.entry.js +0 -6
  494. package/dist/esm/post-popovercontainer-e6d11d81.js +0 -2184
  495. package/dist/esm/post-popovercontainer.entry.js +0 -3
  496. package/dist/esm/post-tab-header-776a991a.js +0 -30
  497. package/dist/esm/post-tag-deefcc86.js +0 -45
  498. package/dist/post-components/p-048538ea.js +0 -1
  499. package/dist/post-components/p-0a1f5e13.entry.js +0 -1
  500. package/dist/post-components/p-0a4318ff.js +0 -1
  501. package/dist/post-components/p-0d64ef0c.entry.js +0 -1
  502. package/dist/post-components/p-1198a5f2.entry.js +0 -1
  503. package/dist/post-components/p-13d1bef7.entry.js +0 -1
  504. package/dist/post-components/p-16d057a6.js +0 -1
  505. package/dist/post-components/p-1a091fca.entry.js +0 -1
  506. package/dist/post-components/p-1f35b0ba.entry.js +0 -1
  507. package/dist/post-components/p-246a6d28.js +0 -1
  508. package/dist/post-components/p-2737eaf5.js +0 -1
  509. package/dist/post-components/p-3aa5e1e5.js +0 -1
  510. package/dist/post-components/p-3d3795f9.js +0 -1
  511. package/dist/post-components/p-3fabf6e4.entry.js +0 -1
  512. package/dist/post-components/p-4f0617e6.js +0 -1
  513. package/dist/post-components/p-53bacbbc.js +0 -1
  514. package/dist/post-components/p-5c8cb76f.entry.js +0 -1
  515. package/dist/post-components/p-5eee8d31.entry.js +0 -1
  516. package/dist/post-components/p-60e72b25.js +0 -1
  517. package/dist/post-components/p-611b3c41.js +0 -1
  518. package/dist/post-components/p-66ed33a9.js +0 -1
  519. package/dist/post-components/p-681b751d.entry.js +0 -1
  520. package/dist/post-components/p-6adeaa6c.js +0 -1
  521. package/dist/post-components/p-6b6a1e82.entry.js +0 -1
  522. package/dist/post-components/p-752e6a98.entry.js +0 -1
  523. package/dist/post-components/p-8734876e.js +0 -1
  524. package/dist/post-components/p-9ac2a947.js +0 -1
  525. package/dist/post-components/p-9d211a45.js +0 -1
  526. package/dist/post-components/p-b095519d.js +0 -1
  527. package/dist/post-components/p-b38eaabf.js +0 -1
  528. package/dist/post-components/p-cdfcc758.entry.js +0 -1
  529. package/dist/post-components/p-d50d4ec1.entry.js +0 -1
  530. package/dist/post-components/p-d785856c.js +0 -1
  531. package/dist/post-components/p-deb4131c.js +0 -1
  532. package/dist/post-components/p-e18f3639.js +0 -1
  533. package/dist/post-components/p-f1b7797f.entry.js +0 -1
  534. package/dist/post-components/p-f6efc76b.entry.js +0 -1
  535. package/dist/post-components/p-f825d681.js +0 -1
  536. package/dist/post-components/p-fff1c2ee.entry.js +0 -1
  537. package/dist/types/components/post-alert/alert-types.d.ts +0 -2
  538. package/dist/types/components/post-alert/post-alert.d.ts +0 -54
  539. package/loaders/post-alert.js +0 -139
@@ -0,0 +1,3 @@
1
+ .banner,.alert{min-height:calc(var(--post-device-sizing-notification-icon-2) + (2 * var(--post-device-spacing-padding-10)));box-sizing:border-box;box-shadow:var(--post-device-elevation-100);border-radius:var(--post-device-border-radius-2);padding:var(--post-device-spacing-padding-10) var(--post-device-spacing-padding-10);padding-inline-start:calc(var(--post-device-spacing-padding-10) + var(--post-device-sizing-notification-icon-2) + var(--post-device-spacing-gap-inline-6));font-weight:var(--post-core-font-weight-400);border-style:var(--post-core-border-style-solid);border-width:var(--post-device-border-width-default);position:relative;color:var(--post-scheme-color-surface-default-fg);background-color:var(--post-scheme-color-signal-neutral);border-color:var(--post-scheme-color-signal-neutral-dark);color-scheme:var(--post-core-bg-scheme-light)}.banner:not(.no-icon)::before,.alert:not(.no-icon)::before{mask-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M31.986 15.73c-.503.16-1.03.27-1.586.27a5.24 5.24 0 0 1-4.43-2.448c-.73.382-1.547.62-2.427.62a5.257 5.257 0 0 1-5.257-5.258c0-.88.237-1.698.62-2.427a5.24 5.24 0 0 1-2.449-4.43c0-.714.145-1.393.403-2.014C16.574.028 16.29 0 16 0 7.163 0 0 7.163 0 16s7.163 16 16 16 16-7.163 16-16c0-.091-.012-.18-.014-.27M16 30.667c-8.087 0-14.667-6.58-14.667-14.667 0-7.806 6.13-14.207 13.828-14.643a6.54 6.54 0 0 0 2.116 5.56 6.3 6.3 0 0 0-.325 1.997 6.6 6.6 0 0 0 6.59 6.59c.677 0 1.346-.108 1.998-.324a6.54 6.54 0 0 0 5.067 2.15C29.933 24.796 23.639 30.667 16 30.667M11.352 14.17a2.667 2.667 0 1 0-5.333 0 2.667 2.667 0 0 0 5.333 0m-4 0a1.335 1.335 0 1 1 1.334 1.334 1.336 1.336 0 0 1-1.334-1.334m13.981 8.496a2.667 2.667 0 1 0-5.333 0 2.667 2.667 0 0 0 5.333 0m-4 0a1.335 1.335 0 0 1 2.667 0c0 .735-.598 1.333-1.333 1.333a1.335 1.335 0 0 1-1.334-1.333m-7.276-1.829a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0 2.667a.667.667 0 1 1 .002-1.335.667.667 0 0 1-.002 1.335m7.772-6a2 2 0 1 0-4 0 2 2 0 0 0 4 0m-2 .666a.667.667 0 1 1 .001-1.334.667.667 0 0 1-.001 1.334M11.505 5.505a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0 2.666a.667.667 0 1 1 .001-1.334.667.667 0 0 1-.001 1.334M28.93 18.548a13.2 13.2 0 0 1-4.335 7.357.663.663 0 0 1-.94-.073.666.666 0 0 1 .073-.94 11.84 11.84 0 0 0 3.894-6.61.668.668 0 0 1 1.307.266m-6.668 8.212a.667.667 0 0 1-.295.896c-.837.423-1.722.757-2.63.99a.665.665 0 1 1-.33-1.292 11.7 11.7 0 0 0 2.359-.888.67.67 0 0 1 .896.294M4 15.921a.666.666 0 1 1-1.333 0 13.13 13.13 0 0 1 4.597-9.984.666.666 0 1 1 .867 1.013A11.8 11.8 0 0 0 4 15.92'/%3E%3C/svg%3E");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-signal-neutral-dark)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner:not(.no-icon)::before,.alert:not(.no-icon)::before{color:CanvasText}}.banner:has(>post-icon)::before,.alert:has(>post-icon)::before{content:none}.banner>post-icon,.alert>post-icon{background-color:var(--post-scheme-color-signal-neutral);color:var(--post-scheme-color-signal-neutral-dark)}.banner::before,.alert::before{content:"";display:block}.banner::before,.banner>post-icon,.alert::before,.alert>post-icon{position:absolute;height:var(--post-device-sizing-notification-icon-2);width:var(--post-device-sizing-notification-icon-2);left:var(--post-device-spacing-padding-10);top:var(--post-device-spacing-padding-10)}.banner.no-icon,.alert.no-icon{min-height:calc(2*var(--post-device-spacing-padding-10) + var(--post-core-dimension-24));padding-inline-start:var(--post-device-spacing-padding-10)}.banner.no-icon::before,.alert.no-icon::before{content:unset}.banner.no-icon>post-icon,.alert.no-icon>post-icon{display:none}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner,.alert{filter:none !important;border:2px solid CanvasText}}.banner:not(.banner-action):not(.alert-action),.alert:not(.banner-action):not(.alert-action){display:flex;flex-direction:column;justify-content:center;gap:var(--post-core-dimension-4)}.banner:not(.banner-action):not(.alert-action) a,.alert:not(.banner-action):not(.alert-action) a{font-weight:var(--post-core-font-weight-400)}.banner:not(.banner-action):not(.alert-action) hr,.alert:not(.banner-action):not(.alert-action) hr{margin-block:var(--post-core-dimension-8) var(--post-core-dimension-12) !important}.banner:not(.banner-action):not(.alert-action)>*,.alert:not(.banner-action):not(.alert-action)>*{margin:0}.banner-container{border:unset;background-color:rgba(0,0,0,0)}.banner-dismissible,.alert-dismissible{pointer-events:auto;position:relative}.banner-dismissible:not(.banner-action):not(.alert-action),.alert-dismissible:not(.banner-action):not(.alert-action){padding-inline-end:calc(var(--post-device-spacing-padding-10) + var(--post-device-spacing-gap-inline-6) + var(--post-core-dimension-24))}.banner-dismissible>.btn-close,.alert-dismissible>.btn-close{position:absolute;inset-block-start:1rem;inset-inline-end:var(--post-device-spacing-padding-10)}.banner-buttons,.alert-buttons{display:flex;align-items:center;justify-content:flex-start;flex-direction:row-reverse;margin-block-start:var(--post-device-spacing-padding-block-10);gap:var(--post-device-spacing-gap-1)}@media(max-width: 779.98px){.banner-buttons,.alert-buttons{flex-direction:column}}.banner-action>.banner-content,.banner-action>.alert-content,.alert-action>.banner-content,.alert-action>.alert-content{display:flex;flex-direction:column;justify-content:center;gap:var(--post-core-dimension-4)}.banner-action>.banner-content a,.banner-action>.alert-content a,.alert-action>.banner-content a,.alert-action>.alert-content a{font-weight:var(--post-core-font-weight-400)}.banner-action>.banner-content hr,.banner-action>.alert-content hr,.alert-action>.banner-content hr,.alert-action>.alert-content hr{margin-block:var(--post-core-dimension-8) var(--post-core-dimension-12) !important}.banner-action>.banner-content>*,.banner-action>.alert-content>*,.alert-action>.banner-content>*,.alert-action>.alert-content>*{margin:0}@media(max-width: 779.98px){.banner-action,.alert-action{flex-direction:column;align-items:stretch}.banner-action>.banner-content,.banner-action>.alert-content,.alert-action>.banner-content,.alert-action>.alert-content{padding-inline-start:var(--post-device-spacing-gap-inline-6)var(--post-device-sizing-notification-icon-2);padding-inline-end:var(--post-device-spacing-gap-inline-6)var(--post-core-dimension-24)}.banner-action.no-icon>.banner-content,.banner-action.no-icon>.alert-content,.alert-action.no-icon>.banner-content,.alert-action.no-icon>.alert-content{padding-inline-start:0}.banner-action>.banner-buttons,.banner-action>.alert-buttons,.alert-action>.banner-buttons,.alert-action>.alert-buttons{display:flex}.banner-action>.banner-buttons>.btn,.banner-action>.banner-buttons>::slotted(.btn),.banner-action>.alert-buttons>.btn,.banner-action>.alert-buttons>::slotted(.btn),.alert-action>.banner-buttons>.btn,.alert-action>.banner-buttons>::slotted(.btn),.alert-action>.alert-buttons>.btn,.alert-action>.alert-buttons>::slotted(.btn){flex:1 0 0;width:100%}.banner-action>.banner-buttons>.btn:first-child,.banner-action>.banner-buttons>::slotted(.btn:first-child),.banner-action>.alert-buttons>.btn:first-child,.banner-action>.alert-buttons>::slotted(.btn:first-child),.alert-action>.banner-buttons>.btn:first-child,.alert-action>.banner-buttons>::slotted(.btn:first-child),.alert-action>.alert-buttons>.btn:first-child,.alert-action>.alert-buttons>::slotted(.btn:first-child){margin-inline-start:0}}.banner-neutral,.alert-neutral{background-color:var(--post-scheme-color-signal-neutral);border-color:var(--post-scheme-color-signal-neutral-dark);color-scheme:var(--post-core-bg-scheme-light)}.banner-neutral:not(.no-icon)::before,.alert-neutral:not(.no-icon)::before{mask-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M31.986 15.73c-.503.16-1.03.27-1.586.27a5.24 5.24 0 0 1-4.43-2.448c-.73.382-1.547.62-2.427.62a5.257 5.257 0 0 1-5.257-5.258c0-.88.237-1.698.62-2.427a5.24 5.24 0 0 1-2.449-4.43c0-.714.145-1.393.403-2.014C16.574.028 16.29 0 16 0 7.163 0 0 7.163 0 16s7.163 16 16 16 16-7.163 16-16c0-.091-.012-.18-.014-.27M16 30.667c-8.087 0-14.667-6.58-14.667-14.667 0-7.806 6.13-14.207 13.828-14.643a6.54 6.54 0 0 0 2.116 5.56 6.3 6.3 0 0 0-.325 1.997 6.6 6.6 0 0 0 6.59 6.59c.677 0 1.346-.108 1.998-.324a6.54 6.54 0 0 0 5.067 2.15C29.933 24.796 23.639 30.667 16 30.667M11.352 14.17a2.667 2.667 0 1 0-5.333 0 2.667 2.667 0 0 0 5.333 0m-4 0a1.335 1.335 0 1 1 1.334 1.334 1.336 1.336 0 0 1-1.334-1.334m13.981 8.496a2.667 2.667 0 1 0-5.333 0 2.667 2.667 0 0 0 5.333 0m-4 0a1.335 1.335 0 0 1 2.667 0c0 .735-.598 1.333-1.333 1.333a1.335 1.335 0 0 1-1.334-1.333m-7.276-1.829a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0 2.667a.667.667 0 1 1 .002-1.335.667.667 0 0 1-.002 1.335m7.772-6a2 2 0 1 0-4 0 2 2 0 0 0 4 0m-2 .666a.667.667 0 1 1 .001-1.334.667.667 0 0 1-.001 1.334M11.505 5.505a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0 2.666a.667.667 0 1 1 .001-1.334.667.667 0 0 1-.001 1.334M28.93 18.548a13.2 13.2 0 0 1-4.335 7.357.663.663 0 0 1-.94-.073.666.666 0 0 1 .073-.94 11.84 11.84 0 0 0 3.894-6.61.668.668 0 0 1 1.307.266m-6.668 8.212a.667.667 0 0 1-.295.896c-.837.423-1.722.757-2.63.99a.665.665 0 1 1-.33-1.292 11.7 11.7 0 0 0 2.359-.888.67.67 0 0 1 .896.294M4 15.921a.666.666 0 1 1-1.333 0 13.13 13.13 0 0 1 4.597-9.984.666.666 0 1 1 .867 1.013A11.8 11.8 0 0 0 4 15.92'/%3E%3C/svg%3E");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-signal-neutral-dark)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-neutral:not(.no-icon)::before,.alert-neutral:not(.no-icon)::before{color:CanvasText}}.banner-neutral:has(>post-icon)::before,.alert-neutral:has(>post-icon)::before{content:none}.banner-neutral>post-icon,.alert-neutral>post-icon{background-color:var(--post-scheme-color-signal-neutral);color:var(--post-scheme-color-signal-neutral-dark)}.banner-success,.alert-success{background-color:var(--post-scheme-color-interactive-notification-success-bg);border-color:var(--post-scheme-color-interactive-notification-success-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-success:not(.no-icon)::before,.alert-success:not(.no-icon)::before{mask-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m12.667 24.533-7.6-7.6 1.867-1.867 5.733 5.733 12.4-12.4 1.867 1.867z'/%3E%3C/svg%3E");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-success-icon)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-success:not(.no-icon)::before,.alert-success:not(.no-icon)::before{color:CanvasText}}.banner-success:has(>post-icon)::before,.alert-success:has(>post-icon)::before{content:none}.banner-success>post-icon,.alert-success>post-icon{background-color:var(--post-scheme-color-interactive-notification-success-bg);color:var(--post-scheme-color-interactive-notification-success-icon)}.banner-warning,.alert-warning{background-color:var(--post-scheme-color-interactive-notification-warning-bg);border-color:var(--post-scheme-color-interactive-notification-warning-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-warning:not(.no-icon)::before,.alert-warning:not(.no-icon)::before{mask-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M14.67 4h2.67v18.67h-2.67zm0 21.33h2.67V28h-2.67z'/%3E%3C/svg%3E");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-warning-icon)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-warning:not(.no-icon)::before,.alert-warning:not(.no-icon)::before{color:CanvasText}}.banner-warning:has(>post-icon)::before,.alert-warning:has(>post-icon)::before{content:none}.banner-warning>post-icon,.alert-warning>post-icon{background-color:var(--post-scheme-color-interactive-notification-warning-bg);color:var(--post-scheme-color-interactive-notification-warning-icon)}.banner-error,.alert-error{background-color:var(--post-scheme-color-interactive-notification-error-bg);border-color:var(--post-scheme-color-interactive-notification-error-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-error:not(.no-icon)::before,.alert-error:not(.no-icon)::before{mask-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M14.67 4h2.67v18.67h-2.67zm0 21.33h2.67V28h-2.67z'/%3E%3C/svg%3E");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-error-icon)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-error:not(.no-icon)::before,.alert-error:not(.no-icon)::before{color:CanvasText}}.banner-error:has(>post-icon)::before,.alert-error:has(>post-icon)::before{content:none}.banner-error>post-icon,.alert-error>post-icon{background-color:var(--post-scheme-color-interactive-notification-error-bg);color:var(--post-scheme-color-interactive-notification-error-icon)}.banner-info,.alert-info{background-color:var(--post-scheme-color-interactive-notification-info-bg);border-color:var(--post-scheme-color-interactive-notification-info-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-info:not(.no-icon)::before,.alert-info:not(.no-icon)::before{mask-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M17.33 25.33v-16h-4.67V12h2v13.33h-2V28h6.67v-2.67zM14.67 4h2.67v2.67h-2.67z'/%3E%3C/svg%3E");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-info-icon)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-info:not(.no-icon)::before,.alert-info:not(.no-icon)::before{color:CanvasText}}.banner-info:has(>post-icon)::before,.alert-info:has(>post-icon)::before{content:none}.banner-info>post-icon,.alert-info>post-icon{background-color:var(--post-scheme-color-interactive-notification-info-bg);color:var(--post-scheme-color-interactive-notification-info-icon)}.banner-danger,.alert-danger{background-color:var(--post-scheme-color-interactive-notification-error-bg);border-color:var(--post-scheme-color-interactive-notification-error-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-danger:not(.no-icon)::before,.alert-danger:not(.no-icon)::before{mask-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M14.67 4h2.67v18.67h-2.67zm0 21.33h2.67V28h-2.67z'/%3E%3C/svg%3E");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-error-icon)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-danger:not(.no-icon)::before,.alert-danger:not(.no-icon)::before{color:CanvasText}}.banner-danger:has(>post-icon)::before,.alert-danger:has(>post-icon)::before{content:none}.banner-danger>post-icon,.alert-danger>post-icon{background-color:var(--post-scheme-color-interactive-notification-error-bg);color:var(--post-scheme-color-interactive-notification-error-icon)}.btn-close{padding:0;overflow:visible;border:0;background:none;color:var(--post-scheme-color-interactive-button-secondary-enabled-fg);font:inherit;-webkit-user-select:none;user-select:none;appearance:button;border-radius:var(--post-device-border-radius-round);color:#000;transition:opacity 250ms,border-color 250ms,background-color 250ms,color 250ms;cursor:pointer}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close{background-color:ButtonFace !important}.btn-close:hover{background-color:Highlight !important}}.btn-close{outline-offset:var(--post-device-spacing-padding-2) !important;outline:var(--post-scheme-color-interactive-focus-stroke) none var(--post-device-border-width-focus) !important}.btn-close:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-style:var(--post-core-border-style-solid) !important;border-radius:4px}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){.btn-close:is(:focus-visible,:focus-within,.pretend-focus){outline-style:var(--post-core-border-style-solid) !important;border-radius:4px}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}.btn-close::before{mask-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m16.267 16.667 6.667-6.533-.933-1.067-6.667 6.667-6.667-6.667-.933 1.067 6.667 6.533-6.667 6.667 1.067.933 6.533-6.667 6.667 6.667.933-1.067z'/%3E%3C/svg%3E");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;content:"";display:block;height:var(--post-core-dimension-24);width:var(--post-core-dimension-24)}.btn-close:focus,.btn-close:not(:disabled):hover,.pretend-hover.btn-close{color:#000}.btn-close:disabled{color:#999}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close{color:CanvasText;forced-color-adjust:none}.btn-close:focus,.btn-close:not(:disabled):hover,.pretend-hover.btn-close{color:Highlight}}.btn-close-white{color:#e6e6e6}.btn-close-white:focus,.btn-close-white:not(:disabled):hover,.btn-close-white.pretend-hover{color:#fff}.btn-close-white:disabled{color:#999}/*!
2
+ * Copyright 2021 by Swiss Post, Information Technology
3
+ */:host{display:block}:host ::slotted(*){margin:0 !important}.visually-hidden{width:1px !important;height:1px !important;padding:0 !important;margin:-1px !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;white-space:nowrap !important;border:0 !important}.visually-hidden:not(caption){position:absolute !important}
@@ -1,66 +1,65 @@
1
- import { h, Host, } from "@stencil/core";
1
+ import { Host, h, } from "@stencil/core";
2
2
  import { version } from "../../../../package";
3
3
  import { fadeOut } from "../../animations/index";
4
4
  import { checkEmptyOrOneOf, checkEmptyOrPattern, checkNonEmpty, checkType } from "../../utils/index";
5
- import { ALERT_TYPES } from "./alert-types";
5
+ import { BANNER_TYPES } from "./banner-types";
6
+ import { nanoid } from "nanoid";
6
7
  /**
7
- * @slot heading - Slot for placing custom content within the alert's heading.
8
- * @slot actions - Slot for placing custom actions (buttons, links, etc.) within the alert.
9
- * @slot default - Slot for placing the main content/message of the alert.
8
+ * @slot heading - Slot for placing custom content within the banner's heading.
9
+ * @slot actions - Slot for placing custom actions (buttons, links, etc.) within the banner.
10
+ * @slot default - Slot for placing the main content/message of the banner.
10
11
  */
11
- export class PostAlert {
12
+ export class PostBanner {
12
13
  constructor() {
13
- this.alertId = crypto.randomUUID();
14
+ this.bannerId = `p${nanoid(6)}`;
14
15
  this.classes = undefined;
15
16
  this.hasActions = undefined;
16
17
  this.hasHeading = undefined;
17
18
  this.onDismissButtonClick = () => this.dismiss();
18
19
  this.dismissible = false;
19
20
  this.dismissLabel = undefined;
20
- this.fixed = false;
21
21
  this.icon = undefined;
22
- this.type = 'primary';
22
+ this.type = 'neutral';
23
23
  }
24
- validateDismissible(isDismissible = this.dismissible) {
25
- checkType(isDismissible, 'boolean', 'The post-alert "dismissible" prop should be a boolean.');
24
+ host;
25
+ validateDismissible() {
26
+ checkType(this, 'dismissible', 'boolean');
26
27
  setTimeout(() => this.validateDismissLabel());
27
28
  }
28
- validateDismissLabel(dismissLabel = this.dismissLabel) {
29
+ validateDismissLabel() {
29
30
  if (this.dismissible) {
30
- checkNonEmpty(dismissLabel, 'Dismissible post-alert\'s require a "dismiss-label" prop.');
31
+ checkNonEmpty(this, 'dismissLabel', 'Dismissible post-banner\'s require a "dismiss-label" prop.');
31
32
  }
32
33
  }
33
- validateFixed(isFixed = this.fixed) {
34
- checkType(isFixed, 'boolean', 'The post-alert "fixed" prop should be a boolean.');
34
+ validateIcon() {
35
+ checkEmptyOrPattern(this, 'icon', /\d{4}|none/, 'The post-banner "icon" prop should be a 4-digit string.');
35
36
  }
36
- validateIcon(icon = this.icon) {
37
- checkEmptyOrPattern(icon, /\d{4}|none/, 'The post-alert "icon" prop should be a 4-digits string.');
38
- }
39
- validateType(type = this.type) {
40
- checkEmptyOrOneOf(type, ALERT_TYPES, `The post-alert requires a type form: ${ALERT_TYPES.join(', ')}`);
37
+ validateType() {
38
+ checkEmptyOrOneOf(this, 'type', BANNER_TYPES);
41
39
  }
40
+ /**
41
+ * An event emitted when the banner element is dismissed, after the transition.
42
+ * It has no payload and only relevant for dismissible banners.
43
+ */
44
+ postDismissed;
42
45
  componentDidLoad() {
43
46
  this.validateDismissible();
44
- this.validateFixed();
45
47
  this.validateIcon();
46
48
  this.validateType();
47
49
  }
48
50
  componentWillRender() {
49
- var _a;
50
51
  this.hasHeading = this.host.querySelectorAll('[slot=heading]').length > 0;
51
52
  this.hasActions = this.host.querySelectorAll('[slot=actions]').length > 0;
52
- this.classes = `alert alert-${(_a = this.type) !== null && _a !== void 0 ? _a : 'primary'}`;
53
+ this.classes = `banner ${this.type ? 'banner-' + this.type : ''}`;
53
54
  if (this.dismissible)
54
- this.classes += ' alert-dismissible';
55
+ this.classes += ' banner-dismissible';
55
56
  if (this.hasActions)
56
- this.classes += ' alert-action';
57
- if (this.fixed)
58
- this.classes += ' alert-fixed-bottom';
57
+ this.classes += ' banner-action';
59
58
  if (this.icon === 'none')
60
59
  this.classes += ' no-icon';
61
60
  }
62
61
  /**
63
- * Triggers alert dismissal programmatically (same as clicking on the close button (×)).
62
+ * Triggers banner dismissal programmatically (same as clicking on the close button (×)).
64
63
  */
65
64
  async dismiss() {
66
65
  const dismissal = fadeOut(this.host);
@@ -69,26 +68,26 @@ export class PostAlert {
69
68
  this.postDismissed.emit();
70
69
  }
71
70
  render() {
72
- const defaultAlertContent = [
73
- this.hasHeading && (h("div", { key: `${this.alertId}-heading`, class: "alert-heading" }, h("slot", { key: 'a3404eee0322cc2b50125bf4ca08969e33d15763', name: "heading" }))),
74
- h("slot", { key: `${this.alertId}-message` }),
71
+ const defaultBannerContent = [
72
+ this.hasHeading && (h("div", { key: `${this.bannerId}-heading`, class: "banner-heading" }, h("slot", { key: 'd4b29e3591f026b880c4b859a47bcbc3e3b11ced', name: "heading" }))),
73
+ h("slot", { key: `${this.bannerId}-message` }),
75
74
  ];
76
- const actionAlertContent = [
77
- h("div", { key: `${this.alertId}-content`, class: "alert-content" }, defaultAlertContent),
78
- h("div", { key: `${this.alertId}-buttons`, class: "alert-buttons" }, h("slot", { key: '50941abd468008cd58a1e05577243d1046a0e20e', name: "actions" })),
75
+ const actionBannerContent = [
76
+ h("div", { key: `${this.bannerId}-content`, class: "banner-content" }, defaultBannerContent),
77
+ h("div", { key: `${this.bannerId}-buttons`, class: "banner-buttons" }, h("slot", { key: '2f1461a2374d736cb3b72641aa150bc611082f56', name: "actions" })),
79
78
  ];
80
- return (h(Host, { key: '99c1e3b4cc943d8be2d5abe7b2b27dce03548d15', "data-version": version }, h("div", { key: 'a290771bcc1234684502f524fe6e7e44501fc004', role: "alert", class: this.classes, part: this.classes }, this.dismissible && (h("button", { key: '57c9cdbec53430b0fc6e121b5928bb14b86c37e0', class: "btn-close", onClick: this.onDismissButtonClick }, h("span", { key: '82d59b6deb736b4053b2b0876c87456c160928ee', class: "visually-hidden" }, this.dismissLabel))), this.icon && this.icon !== 'none' && (h("post-icon", { key: `${this.alertId}-icon`, name: this.icon })), this.hasActions ? actionAlertContent : defaultAlertContent)));
79
+ return (h(Host, { key: 'ec72012fa82e03b0dca2368025449e1942731c21', "data-version": version }, h("div", { key: 'acae7ac34af951ca9176769ab4bcdc388d769931', role: "alert", class: this.classes, part: this.classes }, this.dismissible && (h("button", { key: '23cc4d77c2825bc76cedcdc321b80b9b0f333e71', class: "btn-close", onClick: this.onDismissButtonClick }, h("span", { key: '2f0753d49fc86f19df743f33a086c14b2a0686f7', class: "visually-hidden" }, this.dismissLabel))), this.icon && this.icon !== 'none' && (h("post-icon", { key: `${this.bannerId}-icon`, name: this.icon })), this.hasActions ? actionBannerContent : defaultBannerContent)));
81
80
  }
82
- static get is() { return "post-alert"; }
81
+ static get is() { return "post-banner"; }
83
82
  static get encapsulation() { return "shadow"; }
84
83
  static get originalStyleUrls() {
85
84
  return {
86
- "$": ["post-alert.scss"]
85
+ "$": ["post-banner.scss"]
87
86
  };
88
87
  }
89
88
  static get styleUrls() {
90
89
  return {
91
- "$": ["post-alert.css"]
90
+ "$": ["post-banner.css"]
92
91
  };
93
92
  }
94
93
  static get properties() {
@@ -105,7 +104,7 @@ export class PostAlert {
105
104
  "optional": false,
106
105
  "docs": {
107
106
  "tags": [],
108
- "text": "If `true`, a close button (\u00D7) is displayed and the alert can be dismissed by the user."
107
+ "text": "If `true`, a close button (\u00D7) is displayed and the banner can be dismissed by the user."
109
108
  },
110
109
  "attribute": "dismissible",
111
110
  "reflect": false,
@@ -123,29 +122,11 @@ export class PostAlert {
123
122
  "optional": false,
124
123
  "docs": {
125
124
  "tags": [],
126
- "text": "The label to use for the close button of a dismissible alert."
125
+ "text": "The label to use for the close button of a dismissible banner."
127
126
  },
128
127
  "attribute": "dismiss-label",
129
128
  "reflect": false
130
129
  },
131
- "fixed": {
132
- "type": "boolean",
133
- "mutable": false,
134
- "complexType": {
135
- "original": "boolean",
136
- "resolved": "boolean",
137
- "references": {}
138
- },
139
- "required": false,
140
- "optional": false,
141
- "docs": {
142
- "tags": [],
143
- "text": "If `true`, the alert is positioned at the bottom of the window, from edge to edge."
144
- },
145
- "attribute": "fixed",
146
- "reflect": false,
147
- "defaultValue": "false"
148
- },
149
130
  "icon": {
150
131
  "type": "string",
151
132
  "mutable": false,
@@ -158,7 +139,7 @@ export class PostAlert {
158
139
  "optional": false,
159
140
  "docs": {
160
141
  "tags": [],
161
- "text": "The icon to display in the alert. By default, the icon depends on the alert type.\n\nIf `none`, no icon is displayed."
142
+ "text": "The icon to display in the banner. By default, the icon depends on the banner type.\n\nIf `none`, no icon is displayed."
162
143
  },
163
144
  "attribute": "icon",
164
145
  "reflect": false
@@ -167,13 +148,13 @@ export class PostAlert {
167
148
  "type": "string",
168
149
  "mutable": false,
169
150
  "complexType": {
170
- "original": "AlertType",
171
- "resolved": "\"danger\" | \"gray\" | \"info\" | \"primary\" | \"success\" | \"warning\"",
151
+ "original": "BannerType",
152
+ "resolved": "\"danger\" | \"info\" | \"neutral\" | \"success\" | \"warning\"",
172
153
  "references": {
173
- "AlertType": {
154
+ "BannerType": {
174
155
  "location": "import",
175
- "path": "./alert-types",
176
- "id": "src/components/post-alert/alert-types.ts::AlertType"
156
+ "path": "./banner-types",
157
+ "id": "src/components/post-banner/banner-types.ts::BannerType"
177
158
  }
178
159
  }
179
160
  },
@@ -181,17 +162,17 @@ export class PostAlert {
181
162
  "optional": false,
182
163
  "docs": {
183
164
  "tags": [],
184
- "text": "The type of the alert."
165
+ "text": "The type of the banner."
185
166
  },
186
167
  "attribute": "type",
187
168
  "reflect": false,
188
- "defaultValue": "'primary'"
169
+ "defaultValue": "'neutral'"
189
170
  }
190
171
  };
191
172
  }
192
173
  static get states() {
193
174
  return {
194
- "alertId": {},
175
+ "bannerId": {},
195
176
  "classes": {},
196
177
  "hasActions": {},
197
178
  "hasHeading": {},
@@ -207,7 +188,7 @@ export class PostAlert {
207
188
  "composed": true,
208
189
  "docs": {
209
190
  "tags": [],
210
- "text": "An event emitted when the alert element is dismissed, after the transition.\nIt has no payload and only relevant for dismissible alerts."
191
+ "text": "An event emitted when the banner element is dismissed, after the transition.\nIt has no payload and only relevant for dismissible banners."
211
192
  },
212
193
  "complexType": {
213
194
  "original": "void",
@@ -231,7 +212,7 @@ export class PostAlert {
231
212
  "return": "Promise<void>"
232
213
  },
233
214
  "docs": {
234
- "text": "Triggers alert dismissal programmatically (same as clicking on the close button (\u00D7)).",
215
+ "text": "Triggers banner dismissal programmatically (same as clicking on the close button (\u00D7)).",
235
216
  "tags": []
236
217
  }
237
218
  }
@@ -245,9 +226,6 @@ export class PostAlert {
245
226
  }, {
246
227
  "propName": "dismissLabel",
247
228
  "methodName": "validateDismissLabel"
248
- }, {
249
- "propName": "fixed",
250
- "methodName": "validateFixed"
251
229
  }, {
252
230
  "propName": "icon",
253
231
  "methodName": "validateIcon"
@@ -0,0 +1,3 @@
1
+ /*!
2
+ * Copyright 2021 by Swiss Post, Information Technology
3
+ */:host{display:flex;align-items:center}.breadcrumbs-nav{display:flex;align-items:center}.hidden-items{gap:var(--post-device-spacing-gap-inline-4);position:absolute;height:0;overflow:hidden;white-space:nowrap}.breadcrumbs-list{display:flex;flex-wrap:nowrap;position:relative;margin:0;padding:0;list-style:none;align-items:center;height:100%;gap:var(--post-device-spacing-gap-inline-4)}post-icon{display:inline-block;box-sizing:border-box;color:var(--post-scheme-color-interactive-primary-enabled-fg1);height:var(--post-core-dimension-24);width:var(--post-core-dimension-24)}.breadcrumb-item-icon{padding-block:var(--post-core-dimension-4);padding-inline:var(--post-core-dimension-4)}li a{display:flex;align-items:center}li a{outline-offset:var(--post-device-spacing-padding-2) !important;outline:var(--post-scheme-color-interactive-focus-stroke) none var(--post-device-border-width-focus) !important}li a:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-style:var(--post-core-border-style-solid) !important}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){li a:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){li a:is(:focus-visible,:focus-within,.pretend-focus){outline-style:var(--post-core-border-style-solid) !important}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){li a:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}li a:focus{border-radius:var(--post-device-border-radius-focus)}li a .home-icon{padding-block:var(--post-device-spacing-padding-4);padding-inline:var(--post-device-spacing-padding-4)}li a .home-icon:hover{color:var(--post-scheme-color-interactive-primary-hover-fg1)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){li a .home-icon a,li a .home-icon:focus,li a .home-icon:hover{color:CanvasText !important}}.menu-trigger-wrapper{display:flex;align-items:center;gap:var(--post-device-spacing-gap-inline-5)}.actual-menu{display:flex;align-items:center}post-menu-trigger{display:flex;align-items:center;padding-block:var(--post-device-spacing-padding-block-7)}post-menu-trigger{outline-offset:var(--post-device-spacing-padding-2) !important;outline:var(--post-scheme-color-interactive-focus-stroke) none var(--post-device-border-width-focus) !important}post-menu-trigger:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-style:var(--post-core-border-style-solid) !important}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){post-menu-trigger:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){post-menu-trigger:is(:focus-visible,:focus-within,.pretend-focus){outline-style:var(--post-core-border-style-solid) !important}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){post-menu-trigger:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}post-menu-trigger:focus{border-radius:var(--post-device-border-radius-focus)}post-menu-trigger button{background:none;border:none;line-height:150%;font-size:var(--post-device-font-size-6);cursor:pointer;padding:0;color:var(--post-scheme-color-interactive-primary-enabled-fg1)}post-menu-trigger button:hover{color:var(--post-scheme-color-interactive-primary-hover-fg1)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){post-menu-trigger button a,post-menu-trigger button:focus,post-menu-trigger button:hover{color:LinkText !important}}post-menu::part(popover-container){display:flex;flex-direction:column;align-items:start;padding:.6rem;gap:var(--post-device-spacing-gap-inline-4)}post-menu::part(popover-container) ::slotted(post-menu-item:not(:last-child)){margin-bottom:var(--post-device-spacing-gap-inline-4)}.breadcrumb-item{display:flex;align-items:center;justify-content:center;gap:var(--post-device-spacing-gap-inline-5)}.breadcrumb-item a{text-decoration:none;color:inherit;line-height:150%;padding-block:var(--post-device-spacing-padding-block-7);font-size:var(--post-device-font-size-6)}.breadcrumb-item a{outline-offset:var(--post-device-spacing-padding-2) !important;outline:var(--post-scheme-color-interactive-focus-stroke) none var(--post-device-border-width-focus) !important}.breadcrumb-item a:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-style:var(--post-core-border-style-solid) !important}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.breadcrumb-item a:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){.breadcrumb-item a:is(:focus-visible,:focus-within,.pretend-focus){outline-style:var(--post-core-border-style-solid) !important}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.breadcrumb-item a:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}.breadcrumb-item a:hover{color:var(--post-scheme-color-interactive-primary-hover-fg1);text-decoration:var(--post-core-text-decoration-underline)}.breadcrumb-item a:focus-visible{border-radius:var(--post-device-border-radius-focus)}.breadcrumb-item span:hover{color:var(--post-scheme-color-interactive-primary-hover-fg1);text-decoration:var(--post-core-text-decoration-underline)}.breadcrumb-item span:focus-visible{border-radius:var(--post-device-border-radius-focus)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.breadcrumb-item a,.breadcrumb-item:focus,.breadcrumb-item:hover{color:LinkText !important}.breadcrumb-item:visited{color:VisitedText !important}}post-breadcrumb-item:last-of-type{pointer-events:none;color:var(--post-scheme-color-interactive-primary-selected-fg1);font-weight:var(--post-device-font-weight-bold);text-decoration:var(--post-core-text-decoration-none)}post-breadcrumb-item:last-of-type:hover{color:var(--post-scheme-color-interactive-primary-selected-fg1);text-decoration:none}.visually-hidden{width:1px !important;height:1px !important;padding:0 !important;margin:-1px !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;white-space:nowrap !important;border:0 !important}.visually-hidden:not(caption){position:absolute !important}
@@ -0,0 +1,163 @@
1
+ import { h, Host } from "@stencil/core";
2
+ import { version } from "../../../../package";
3
+ import { checkUrl, debounce } from "../../utils/index";
4
+ export class PostBreadcrumb {
5
+ constructor() {
6
+ this.homeUrl = undefined;
7
+ this.homeText = 'Home';
8
+ this.breadcrumbItems = [];
9
+ this.isConcatenated = undefined;
10
+ this.lastWindowWidth = undefined;
11
+ }
12
+ host;
13
+ breadcrumbNavRef;
14
+ lastItem;
15
+ validateUrl() {
16
+ checkUrl(this, 'homeUrl');
17
+ }
18
+ componentWillLoad() {
19
+ this.updateBreadcrumbItems();
20
+ }
21
+ componentDidLoad() {
22
+ window.addEventListener('resize', this.handleResize);
23
+ this.waitForBreadcrumbRef();
24
+ }
25
+ disconnectedCallback() {
26
+ window.removeEventListener('resize', this.handleResize);
27
+ }
28
+ // Waits for breadcrumb navigation reference to be available
29
+ waitForBreadcrumbRef = debounce(() => {
30
+ if (this.breadcrumbNavRef?.clientWidth > 0) {
31
+ this.checkConcatenation();
32
+ }
33
+ else {
34
+ this.waitForBreadcrumbRef();
35
+ }
36
+ }, 50);
37
+ // Updates breadcrumb items and sets the last item
38
+ updateBreadcrumbItems() {
39
+ this.breadcrumbItems = Array.from(this.host.querySelectorAll('post-breadcrumb-item')).map(item => ({
40
+ text: item.textContent || '',
41
+ url: item.getAttribute('url') || '',
42
+ }));
43
+ this.lastItem = this.breadcrumbItems[this.breadcrumbItems.length - 1];
44
+ }
45
+ // Handles resizing to check concatenation
46
+ handleResize = () => {
47
+ if (window.innerWidth === this.lastWindowWidth)
48
+ return;
49
+ this.lastWindowWidth = window.innerWidth;
50
+ this.checkConcatenation();
51
+ };
52
+ // Determines parent width for concatenation logic
53
+ getParentWidth() {
54
+ let parent = this.host.parentNode;
55
+ while (parent && !(parent instanceof HTMLElement)) {
56
+ parent = parent.parentNode;
57
+ }
58
+ return parent instanceof HTMLElement ? parent.clientWidth : window.innerWidth;
59
+ }
60
+ checkConcatenation() {
61
+ if (!this.breadcrumbNavRef)
62
+ return;
63
+ const visibleWidth = this.getParentWidth();
64
+ // Measure all hidden breadcrumb items
65
+ const hiddenItems = Array.from(this.host.shadowRoot?.querySelectorAll('.hidden-breadcrumb-item') || []);
66
+ const totalWidth = hiddenItems.reduce((accum, element) => {
67
+ const rect = element.getBoundingClientRect();
68
+ return accum + rect.width;
69
+ }, 0);
70
+ this.isConcatenated = totalWidth > visibleWidth;
71
+ }
72
+ // Handles breadcrumb item click to open the menu
73
+ handleBreadcrumbItemClick() {
74
+ if (this.host.shadowRoot) {
75
+ const menuTrigger = this.host.shadowRoot
76
+ ?.querySelector('.menu-trigger-wrapper')
77
+ ?.querySelector('button');
78
+ if (menuTrigger) {
79
+ menuTrigger.click();
80
+ }
81
+ }
82
+ }
83
+ render() {
84
+ const visibleItems = this.breadcrumbItems.slice(0, -1);
85
+ return (h(Host, { key: 'd2fd5b6f8319124fa17649c8c5e479e727fc069a', "data-version": version }, h("nav", { key: 'a5f9b38fa054ad46d8972c28d175f864bed3c365', "aria-label": "Breadcrumb", class: "breadcrumbs-nav", ref: el => (this.breadcrumbNavRef = el) }, h("ol", { key: 'ac7ca9a80315ce6ba70e1aaaae6202fbb1a6933e', class: "no-list breadcrumbs-list" }, h("li", { key: '9927b293673f16bbe837419baf7d4a8f97885bc0' }, h("a", { key: '2b2de9924472a3da00f843c7b569358b60d43539', href: this.homeUrl, class: "breadcrumb-link" }, h("span", { key: '540a16d9673e9c423493597468a3db00b7d75cef', class: "visually-hidden" }, this.homeText), h("post-icon", { key: '73fad27cd72f18bb5ea281c88ff2c184d7d8187d', name: "home", class: "home-icon" }))), this.isConcatenated ? (h("div", { class: "menu-trigger-wrapper", "aria-label": "More breadcrumbs", onKeyDown: e => {
86
+ if (e.key === 'Enter' || e.key === ' ') {
87
+ e.preventDefault();
88
+ this.handleBreadcrumbItemClick();
89
+ }
90
+ } }, h("post-icon", { name: "2111", class: "breadcrumb-item-icon" }), h("div", { class: "actual-menu" }, h("post-menu-trigger", { for: "breadcrumb-menu", tabIndex: 0 }, h("button", { class: "btn test", tabIndex: -1 }, "...")), h("post-menu", { id: "breadcrumb-menu" }, visibleItems.map(item => (h("post-menu-item", { key: item.url || item.text, class: "breadcrumb-item", onKeyDown: e => {
91
+ if (e.key === 'Enter' || e.key === ' ') {
92
+ const linkElement = e.currentTarget.querySelector('a');
93
+ linkElement?.click();
94
+ e.preventDefault();
95
+ }
96
+ } }, item.url ? h("a", { href: item.url }, item.text) : h("span", null, item.text)))))))) : (visibleItems.map(item => (h("post-breadcrumb-item", { url: item.url, key: item.url || item.text }, item.text)))), this.lastItem && (h("post-breadcrumb-item", { key: '31d86d933720b5f6f6928ccfd251443261e9479e', url: this.lastItem.url, "aria-current": "page", tabindex: -1 }, this.lastItem.text))), h("div", { key: '3248d32aa6a73c97c3071be85174fb8634d4e722', class: "hidden-items" }, h("a", { key: '05b0231d3a5793588aa9ede628a7b1e6d2e2faf0', href: this.homeUrl, class: "hidden-breadcrumb-item" }, h("span", { key: '15a63a894124717cfb2be61779c3971772c38397', class: "visually-hidden" }, this.homeText), h("post-icon", { key: '6c893c56b6a34f311fa66d71c4cb523b00535458', name: "home", class: "home-icon" })), this.breadcrumbItems.map(item => (h("post-breadcrumb-item", { url: item.url, key: `hidden-${item.url || item.text}`, class: "hidden-breadcrumb-item" }, item.text)))))));
97
+ }
98
+ static get is() { return "post-breadcrumb"; }
99
+ static get encapsulation() { return "shadow"; }
100
+ static get originalStyleUrls() {
101
+ return {
102
+ "$": ["post-breadcrumb.scss"]
103
+ };
104
+ }
105
+ static get styleUrls() {
106
+ return {
107
+ "$": ["post-breadcrumb.css"]
108
+ };
109
+ }
110
+ static get properties() {
111
+ return {
112
+ "homeUrl": {
113
+ "type": "string",
114
+ "mutable": false,
115
+ "complexType": {
116
+ "original": "string",
117
+ "resolved": "string",
118
+ "references": {}
119
+ },
120
+ "required": false,
121
+ "optional": false,
122
+ "docs": {
123
+ "tags": [],
124
+ "text": "The URL for the home breadcrumb item."
125
+ },
126
+ "attribute": "home-url",
127
+ "reflect": false
128
+ },
129
+ "homeText": {
130
+ "type": "string",
131
+ "mutable": false,
132
+ "complexType": {
133
+ "original": "string",
134
+ "resolved": "string",
135
+ "references": {}
136
+ },
137
+ "required": false,
138
+ "optional": false,
139
+ "docs": {
140
+ "tags": [],
141
+ "text": "The text label for the home breadcrumb item."
142
+ },
143
+ "attribute": "home-text",
144
+ "reflect": false,
145
+ "defaultValue": "'Home'"
146
+ }
147
+ };
148
+ }
149
+ static get states() {
150
+ return {
151
+ "breadcrumbItems": {},
152
+ "isConcatenated": {},
153
+ "lastWindowWidth": {}
154
+ };
155
+ }
156
+ static get elementRef() { return "host"; }
157
+ static get watchers() {
158
+ return [{
159
+ "propName": "homeUrl",
160
+ "methodName": "validateUrl"
161
+ }];
162
+ }
163
+ }
@@ -0,0 +1 @@
1
+ :host{display:flex;align-items:center;justify-content:start;gap:var(--post-device-spacing-gap-inline-5)}:host post-icon{box-sizing:border-box;height:var(--post-core-dimension-24);width:var(--post-core-dimension-24);padding-block:var(--post-core-dimension-4);padding-inline:var(--post-core-dimension-4)}.breadcrumb-item{white-space:nowrap;line-height:150%;padding-block:var(--post-device-spacing-padding-block-7);color:var(--post-scheme-color-interactive-primary-enabled-fg1);text-decoration:var(--post-core-text-decoration-none)}.breadcrumb-item{outline-offset:var(--post-device-spacing-padding-2) !important;outline:var(--post-scheme-color-interactive-focus-stroke) none var(--post-device-border-width-focus) !important}.breadcrumb-item:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-style:var(--post-core-border-style-solid) !important}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.breadcrumb-item:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){.breadcrumb-item:is(:focus-visible,:focus-within,.pretend-focus){outline-style:var(--post-core-border-style-solid) !important}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.breadcrumb-item:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}.breadcrumb-item:hover{color:var(--post-scheme-color-interactive-primary-hover-fg1);text-decoration:var(--post-core-text-decoration-underline)}.breadcrumb-item:focus-visible{border-radius:var(--post-device-border-radius-focus)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.breadcrumb-item,.breadcrumb-item:focus,.breadcrumb-item:hover{color:LinkText !important}.breadcrumb-item:visited{color:VisitedText !important}}
@@ -0,0 +1,98 @@
1
+ import { h, Host } from "@stencil/core";
2
+ import { version } from "../../../../package";
3
+ import { checkEmptyOrUrl } from "../../utils/index";
4
+ /**
5
+ * @slot default - Slot for placing the text inside the breadcrumb item.
6
+ */
7
+ export class PostBreadcrumbItem {
8
+ constructor() {
9
+ this.url = undefined;
10
+ this.fullUrl = undefined;
11
+ }
12
+ host;
13
+ validUrl;
14
+ validateUrl() {
15
+ try {
16
+ this.validUrl = this.constructUrl(this.url);
17
+ }
18
+ catch (error) {
19
+ this.validUrl = undefined;
20
+ }
21
+ }
22
+ // Helper to construct a valid URL string or return undefined
23
+ constructUrl(value) {
24
+ const hasBaseURL = /^https?:\/\//.test(String(this.url));
25
+ if (typeof value === 'string') {
26
+ this.fullUrl = hasBaseURL ? value : `${window.location.origin}${value}`;
27
+ checkEmptyOrUrl(this, 'fullUrl');
28
+ return this.fullUrl;
29
+ }
30
+ return undefined;
31
+ }
32
+ connectedCallback() {
33
+ this.validateUrl();
34
+ }
35
+ handleKeyDown(event) {
36
+ if (event.key === 'Enter' || event.key === ' ') {
37
+ const linkElement = this.host.shadowRoot?.querySelector('a');
38
+ if (linkElement) {
39
+ event.preventDefault();
40
+ linkElement.click();
41
+ }
42
+ }
43
+ }
44
+ render() {
45
+ const BreadcrumbTag = this.validUrl ? 'a' : 'span';
46
+ return (h(Host, { key: 'd0444118aa031f4cf6f5161d7aa21900e9768348', "data-version": version }, h("post-icon", { key: '719a76e6e86bbb02526c4610acefb3ad253454af', name: "2111", class: "breadcrumb-item-icon" }), h(BreadcrumbTag, { key: '3f5ffb9c77567dba35efa7938029cd519de55474', class: "breadcrumb-item", ...(this.validUrl ? { href: this.validUrl } : {}), onKeyDown: event => this.handleKeyDown(event) }, h("slot", { key: 'bb1be29905c1533f2238a47a346fb35d6a7645fd' }))));
47
+ }
48
+ static get is() { return "post-breadcrumb-item"; }
49
+ static get encapsulation() { return "shadow"; }
50
+ static get originalStyleUrls() {
51
+ return {
52
+ "$": ["post-breadcrumb-item.scss"]
53
+ };
54
+ }
55
+ static get styleUrls() {
56
+ return {
57
+ "$": ["post-breadcrumb-item.css"]
58
+ };
59
+ }
60
+ static get properties() {
61
+ return {
62
+ "url": {
63
+ "type": "string",
64
+ "mutable": false,
65
+ "complexType": {
66
+ "original": "string | URL",
67
+ "resolved": "URL | string",
68
+ "references": {
69
+ "URL": {
70
+ "location": "global",
71
+ "id": "global::URL"
72
+ }
73
+ }
74
+ },
75
+ "required": false,
76
+ "optional": true,
77
+ "docs": {
78
+ "tags": [],
79
+ "text": "The optional URL to which the breadcrumb item will link."
80
+ },
81
+ "attribute": "url",
82
+ "reflect": false
83
+ }
84
+ };
85
+ }
86
+ static get states() {
87
+ return {
88
+ "fullUrl": {}
89
+ };
90
+ }
91
+ static get elementRef() { return "host"; }
92
+ static get watchers() {
93
+ return [{
94
+ "propName": "url",
95
+ "methodName": "validateUrl"
96
+ }];
97
+ }
98
+ }