@swisspost/design-system-components 10.0.0-next.55 → 10.0.0-next.57

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 (443) hide show
  1. package/dist/{components/react/p-CJ80BZ06.js → cjs/breakpoints-Df03Ct7n.js} +103 -5
  2. package/dist/cjs/debounce-BsIBi_-2.js +13 -0
  3. package/dist/cjs/environment-BQE9Unf_.js +52 -0
  4. package/dist/cjs/{event-from-CLvtSUKf.js → event-from-CwMw19f8.js} +2 -2
  5. package/dist/cjs/fade-CPQhl1fP.js +26 -0
  6. package/dist/cjs/fade-slide-dPhQa-I1.js +38 -0
  7. package/dist/cjs/{get-focusable-children-Bx63XUQg.js → get-focusable-children-ChETM1wK.js} +29 -21
  8. package/dist/cjs/{get-root-CyMf3Vsd.js → get-root-CUAv4k4C.js} +2 -2
  9. package/dist/cjs/{index-B4gYpuJF.js → index-B4rc1pqu.js} +2150 -292
  10. package/dist/cjs/loader.cjs.js +2 -2
  11. package/dist/cjs/{package-DkJrv93P.js → package-uQ5oiSiN.js} +1 -1
  12. package/dist/cjs/post-accordion_2.cjs.entry.js +19 -15
  13. package/dist/cjs/post-avatar.cjs.entry.js +27 -17
  14. package/dist/cjs/post-back-to-top.cjs.entry.js +23 -43
  15. package/dist/cjs/post-banner.cjs.entry.js +15 -12
  16. package/dist/cjs/post-breadcrumb-item_2.cjs.entry.js +14 -12
  17. package/dist/cjs/post-breadcrumbs.cjs.entry.js +33 -34
  18. package/dist/cjs/post-card-control.cjs.entry.js +42 -26
  19. package/dist/cjs/{post-closebutton_15.cjs.entry.js → post-closebutton_13.cjs.entry.js} +618 -531
  20. package/dist/cjs/post-collapsible_2.cjs.entry.js +41 -37
  21. package/dist/cjs/post-components.cjs.js +3 -3
  22. package/dist/cjs/post-env-test.cjs.entry.js +15 -0
  23. package/dist/cjs/post-footer.cjs.entry.js +24 -20
  24. package/dist/cjs/post-linkarea.cjs.entry.js +5 -5
  25. package/dist/cjs/post-pagination.cjs.entry.js +615 -0
  26. package/dist/cjs/post-popover-trigger.cjs.entry.js +54 -34
  27. package/dist/cjs/post-popover.cjs.entry.js +26 -17
  28. package/dist/cjs/post-rating.cjs.entry.js +24 -18
  29. package/dist/cjs/post-stepper-item.cjs.entry.js +5 -5
  30. package/dist/cjs/post-stepper.cjs.entry.js +40 -29
  31. package/dist/cjs/post-tab-item.cjs.entry.js +51 -0
  32. package/dist/cjs/post-tab-panel.cjs.entry.js +13 -11
  33. package/dist/cjs/post-tabs.cjs.entry.js +195 -40
  34. package/dist/cjs/post-tooltip-trigger.cjs.entry.js +13 -11
  35. package/dist/cjs/post-tooltip.cjs.entry.js +14 -12
  36. package/dist/cjs/utils-s05L2ulk.js +26 -0
  37. package/dist/collection/animations/collapse.js +3 -3
  38. package/dist/collection/animations/fade-slide.js +33 -0
  39. package/dist/collection/animations/fade.js +19 -7
  40. package/dist/collection/animations/index.js +2 -0
  41. package/dist/collection/animations/slide.js +25 -21
  42. package/dist/collection/animations/types.js +14 -0
  43. package/dist/collection/animations/utils.js +8 -0
  44. package/dist/collection/collection-manifest.json +8 -8
  45. package/dist/collection/components/post-accordion/post-accordion.css +1 -1
  46. package/dist/collection/components/post-accordion/post-accordion.js +5 -4
  47. package/dist/collection/components/post-accordion-item/post-accordion-item.css +1 -1
  48. package/dist/collection/components/post-accordion-item/post-accordion-item.js +9 -8
  49. package/dist/collection/components/post-avatar/post-avatar.js +11 -11
  50. package/dist/collection/components/post-back-to-top/post-back-to-top.js +15 -15
  51. package/dist/collection/components/post-banner/post-banner.css +4 -1
  52. package/dist/collection/components/post-banner/post-banner.js +6 -5
  53. package/dist/collection/components/post-breadcrumb-item/post-breadcrumb-item.js +3 -3
  54. package/dist/collection/components/post-breadcrumbs/post-breadcrumbs.js +29 -29
  55. package/dist/collection/components/post-card-control/post-card-control.js +18 -18
  56. package/dist/collection/components/post-closebutton/post-closebutton.css +1 -1
  57. package/dist/collection/components/post-closebutton/post-closebutton.js +4 -3
  58. package/dist/collection/components/post-collapsible/post-collapsible.js +28 -28
  59. package/dist/collection/components/post-collapsible-trigger/post-collapsible-trigger.js +3 -3
  60. package/dist/collection/components/post-footer/post-footer.css +1 -1
  61. package/dist/collection/components/post-footer/post-footer.js +18 -16
  62. package/dist/collection/components/post-header/post-header.css +1 -1
  63. package/dist/collection/components/post-header/post-header.js +144 -82
  64. package/dist/collection/components/post-icon/post-icon.js +18 -16
  65. package/dist/collection/components/post-language-menu/post-language-menu.css +1 -0
  66. package/dist/collection/components/{post-language-switch/post-language-switch.js → post-language-menu/post-language-menu.js} +45 -36
  67. package/dist/collection/components/post-language-menu-item/post-language-menu-item.css +1 -0
  68. package/dist/collection/components/{post-language-option/post-language-option.js → post-language-menu-item/post-language-menu-item.js} +24 -23
  69. package/dist/collection/components/post-linkarea/post-linkarea.js +1 -1
  70. package/dist/collection/components/post-logo/post-logo.css +3 -1
  71. package/dist/collection/components/post-logo/post-logo.js +3 -3
  72. package/dist/collection/components/post-mainnavigation/post-mainnavigation.css +1 -1
  73. package/dist/collection/components/post-mainnavigation/post-mainnavigation.js +41 -29
  74. package/dist/collection/components/post-megadropdown/post-megadropdown.css +1 -1
  75. package/dist/collection/components/post-megadropdown/post-megadropdown.js +183 -74
  76. package/dist/collection/components/post-megadropdown-trigger/post-megadropdown-trigger.css +3 -1
  77. package/dist/collection/components/post-megadropdown-trigger/post-megadropdown-trigger.js +81 -75
  78. package/dist/collection/components/post-menu/post-menu.css +1 -1
  79. package/dist/collection/components/post-menu/post-menu.js +39 -38
  80. package/dist/collection/components/post-menu-item/post-menu-item.js +1 -1
  81. package/dist/collection/components/post-menu-trigger/post-menu-trigger.js +3 -3
  82. package/dist/collection/components/post-pagination/post-pagination.css +1 -0
  83. package/dist/collection/components/post-pagination/post-pagination.js +838 -0
  84. package/dist/collection/components/post-popover/post-popover.js +22 -16
  85. package/dist/collection/components/post-popover-trigger/post-popover-trigger.js +45 -29
  86. package/dist/collection/components/post-popovercontainer/post-popovercontainer.css +1 -1
  87. package/dist/collection/components/post-popovercontainer/post-popovercontainer.js +82 -131
  88. package/dist/collection/components/post-rating/post-rating.js +7 -7
  89. package/dist/collection/components/post-stepper/post-stepper.js +38 -35
  90. package/dist/collection/components/post-stepper-item/post-stepper-item.css +2 -2
  91. package/dist/collection/components/post-stepper-item/post-stepper-item.js +1 -1
  92. package/dist/collection/components/post-tab-item/post-tab-item.css +1 -0
  93. package/dist/collection/components/post-tab-item/post-tab-item.js +86 -0
  94. package/dist/collection/components/post-tab-panel/post-tab-panel.js +10 -10
  95. package/dist/collection/components/post-tabs/post-tabs.js +232 -59
  96. package/dist/collection/components/post-togglebutton/post-togglebutton.js +2 -2
  97. package/dist/collection/components/post-tooltip/post-tooltip.js +9 -27
  98. package/dist/collection/components/post-tooltip-trigger/post-tooltip-trigger.js +4 -4
  99. package/dist/collection/utils/environment.js +47 -2
  100. package/dist/collection/utils/event-from.js +2 -2
  101. package/dist/collection/utils/get-focusable-children.js +29 -21
  102. package/dist/collection/utils/is-motion-reduced.js +1 -1
  103. package/dist/collection/utils/tests/environment/hydrate-app-helper.js +16 -0
  104. package/dist/collection/utils/tests/environment/post-env-test.js +9 -0
  105. package/dist/component-names.json +4 -5
  106. package/dist/components/breakpoints.js +1 -178
  107. package/dist/components/debounce.js +1 -0
  108. package/dist/components/environment.js +1 -0
  109. package/dist/components/event-from.js +1 -119
  110. package/dist/components/fade-slide.js +1 -0
  111. package/dist/components/fade.js +1 -11
  112. package/dist/components/focusable.js +1 -5018
  113. package/dist/components/get-focusable-children.js +1 -64
  114. package/dist/components/get-root.js +1 -15
  115. package/dist/components/heading-levels.js +1 -3
  116. package/dist/components/index.browser.js +1 -14
  117. package/dist/components/index.d.ts +11 -10
  118. package/dist/components/index.js +1 -39
  119. package/dist/components/long-press-event.js +1 -257
  120. package/dist/components/package.js +1 -3
  121. package/dist/components/post-accordion-item.js +1 -6
  122. package/dist/components/post-accordion-item2.js +1 -113
  123. package/dist/components/post-accordion.js +1 -6
  124. package/dist/components/post-accordion2.js +1 -138
  125. package/dist/components/post-avatar.js +1 -217
  126. package/dist/components/post-back-to-top.js +1 -144
  127. package/dist/components/post-banner.js +1 -98
  128. package/dist/components/post-breadcrumb-item.js +1 -6
  129. package/dist/components/post-breadcrumb-item2.js +1 -79
  130. package/dist/components/post-breadcrumbs.js +1 -196
  131. package/dist/components/post-card-control.js +1 -326
  132. package/dist/components/post-closebutton.js +1 -6
  133. package/dist/components/post-closebutton2.js +1 -77
  134. package/dist/components/post-collapsible-trigger.js +1 -6
  135. package/dist/components/post-collapsible-trigger2.js +1 -136
  136. package/dist/components/post-collapsible.js +1 -6
  137. package/dist/components/post-collapsible2.js +1 -110
  138. package/dist/components/{post-list.d.ts → post-env-test.d.ts} +4 -4
  139. package/dist/components/post-env-test.js +1 -0
  140. package/dist/components/post-footer.js +1 -116
  141. package/dist/components/post-header.js +1 -372
  142. package/dist/components/post-icon.js +1 -6
  143. package/dist/components/post-icon2.js +1 -159
  144. package/dist/components/post-language-menu-item.d.ts +11 -0
  145. package/dist/components/post-language-menu-item.js +1 -0
  146. package/dist/components/{post-language-switch.d.ts → post-language-menu.d.ts} +4 -4
  147. package/dist/components/post-language-menu.js +1 -0
  148. package/dist/components/post-linkarea.js +1 -58
  149. package/dist/components/post-logo.js +1 -58
  150. package/dist/components/post-mainnavigation.js +1 -180
  151. package/dist/components/post-megadropdown-trigger.js +1 -136
  152. package/dist/components/post-megadropdown.js +1 -267
  153. package/dist/components/post-menu-item.js +1 -6
  154. package/dist/components/post-menu-item2.js +1 -30
  155. package/dist/components/post-menu-trigger.js +1 -6
  156. package/dist/components/post-menu-trigger2.js +1 -110
  157. package/dist/components/post-menu.js +1 -6
  158. package/dist/components/post-menu2.js +1 -242
  159. package/dist/components/{post-tab-header.d.ts → post-pagination.d.ts} +4 -4
  160. package/dist/components/post-pagination.js +1 -0
  161. package/dist/components/post-popover-trigger.js +1 -132
  162. package/dist/components/post-popover.js +1 -118
  163. package/dist/components/post-popovercontainer.js +1 -6
  164. package/dist/components/post-popovercontainer2.js +1 -3127
  165. package/dist/components/post-rating.js +1 -148
  166. package/dist/components/post-stepper-item.js +1 -33
  167. package/dist/components/post-stepper.js +1 -134
  168. package/dist/components/{post-list-item.d.ts → post-tab-item.d.ts} +4 -4
  169. package/dist/components/post-tab-item.js +1 -0
  170. package/dist/components/post-tab-panel.js +1 -54
  171. package/dist/components/post-tabs.js +1 -196
  172. package/dist/components/post-togglebutton.js +1 -56
  173. package/dist/components/post-togglebutton2.js +1 -0
  174. package/dist/components/post-tooltip-trigger.js +1 -206
  175. package/dist/components/post-tooltip.js +1 -114
  176. package/dist/components/react/index.d.ts +2 -0
  177. package/dist/components/react/index.js +1 -2315
  178. package/dist/components/react/p-B8YiQ3mz.js +1 -0
  179. package/dist/components/react/p-BC5nlBvn.js +1 -0
  180. package/dist/components/react/p-BLchVpF6.js +1 -14
  181. package/dist/components/react/p-BVCjnh6Q.js +1 -0
  182. package/dist/{post-components/p-CBFgkSgY.js → components/react/p-BVGcVycs.js} +1 -1
  183. package/dist/components/react/p-B_XPj2c8.js +1 -0
  184. package/dist/components/react/p-BllOMLDs.js +1 -0
  185. package/dist/components/react/p-BmRNjQUZ.js +1 -0
  186. package/dist/components/react/p-ByFh05IW.js +1 -0
  187. package/dist/components/react/p-C9hMpmsD.js +1 -0
  188. package/dist/components/react/p-CJ13r5fi.js +1 -0
  189. package/dist/components/react/p-CZvbetqX.js +1 -0
  190. package/dist/components/react/p-C_2k3G1c.js +1 -257
  191. package/dist/components/react/p-CoDiS_Ik.js +1 -0
  192. package/dist/components/react/p-Cou17ld8.js +1 -0
  193. package/dist/components/react/p-D5knoiyy.js +1 -0
  194. package/dist/components/react/p-D9DDtvFM.js +1 -0
  195. package/dist/components/react/p-DY2U5CQt.js +1 -0
  196. package/dist/components/react/p-DjIHLduJ.js +1 -3
  197. package/dist/components/react/p-DpATRD2W.js +1 -0
  198. package/dist/components/react/p-FxUVQ4Tx.js +1 -0
  199. package/dist/components/react/p-HygIVKXC.js +1 -5018
  200. package/dist/components/react/p-YR7U0Z_g.js +1 -0
  201. package/dist/components/react/p-ZeKXASQs.js +1 -0
  202. package/dist/components/react/p-r4txK0AC.js +1 -3
  203. package/dist/components/react/p-sSn0kXFi.js +1 -0
  204. package/dist/components/react/post-accordion-item.js +1 -6
  205. package/dist/components/react/post-accordion.js +1 -6
  206. package/dist/components/react/post-avatar.js +1 -218
  207. package/dist/components/react/post-back-to-top.js +1 -145
  208. package/dist/components/react/post-banner.js +1 -99
  209. package/dist/components/react/post-breadcrumb-item.js +1 -6
  210. package/dist/components/react/post-breadcrumbs.js +1 -197
  211. package/dist/components/react/post-card-control.js +1 -327
  212. package/dist/components/react/post-closebutton.js +1 -6
  213. package/dist/components/react/post-collapsible-trigger.js +1 -6
  214. package/dist/components/react/post-collapsible.js +1 -6
  215. package/dist/components/react/{post-list.d.ts → post-env-test.d.ts} +4 -4
  216. package/dist/components/react/post-env-test.js +1 -0
  217. package/dist/components/react/post-footer.js +1 -117
  218. package/dist/components/react/post-header.js +1 -373
  219. package/dist/components/react/post-icon.js +1 -6
  220. package/dist/components/react/post-language-menu-item.d.ts +11 -0
  221. package/dist/components/react/post-language-menu-item.js +1 -0
  222. package/dist/components/react/{post-language-option.d.ts → post-language-menu.d.ts} +4 -4
  223. package/dist/components/react/post-language-menu.js +1 -0
  224. package/dist/components/react/post-linkarea.js +1 -59
  225. package/dist/components/react/post-logo.js +1 -59
  226. package/dist/components/react/post-mainnavigation.js +1 -181
  227. package/dist/components/react/post-megadropdown-trigger.js +1 -137
  228. package/dist/components/react/post-megadropdown.js +1 -268
  229. package/dist/components/react/post-menu-item.js +1 -6
  230. package/dist/components/react/post-menu-trigger.js +1 -6
  231. package/dist/components/react/post-menu.js +1 -6
  232. package/dist/components/react/{post-tab-header.d.ts → post-pagination.d.ts} +4 -4
  233. package/dist/components/react/post-pagination.js +1 -0
  234. package/dist/components/react/post-popover-trigger.js +1 -133
  235. package/dist/components/react/post-popover.js +1 -119
  236. package/dist/components/react/post-popovercontainer.js +1 -6
  237. package/dist/components/react/post-rating.js +1 -149
  238. package/dist/components/react/post-stepper-item.js +1 -34
  239. package/dist/components/react/post-stepper.js +1 -135
  240. package/dist/components/react/{post-list-item.d.ts → post-tab-item.d.ts} +4 -4
  241. package/dist/components/react/post-tab-item.js +1 -0
  242. package/dist/components/react/post-tab-panel.js +1 -55
  243. package/dist/components/react/post-tabs.js +1 -197
  244. package/dist/components/react/post-togglebutton.js +1 -57
  245. package/dist/components/react/post-tooltip-trigger.js +1 -207
  246. package/dist/components/react/post-tooltip.js +1 -115
  247. package/dist/components/switch-variants.js +1 -3
  248. package/dist/components/utils.js +1 -0
  249. package/dist/docs.d.ts +11 -0
  250. package/dist/docs.json +873 -631
  251. package/dist/{cjs/breakpoints-CEkeixld.js → esm/breakpoints-DYoSKGHO.js} +89 -6
  252. package/dist/esm/debounce-C9hMpmsD.js +11 -0
  253. package/dist/esm/environment-CEmnRoA6.js +49 -0
  254. package/dist/{components/react/p-CzIKqBrS.js → esm/event-from-rEfV4v4a.js} +2 -2
  255. package/dist/esm/fade-DsgPYmAa.js +24 -0
  256. package/dist/esm/fade-slide-CvOvauo9.js +36 -0
  257. package/dist/esm/{get-focusable-children-D9ZHp2FP.js → get-focusable-children-BXNs2_sw.js} +29 -21
  258. package/dist/{components/react/p-CBFgkSgY.js → esm/get-root-CXfAA093.js} +1 -1
  259. package/dist/esm/{index-wEFJ-c34.js → index-CDZBzSdV.js} +2150 -292
  260. package/dist/esm/loader.js +3 -3
  261. package/dist/esm/package-CZvbetqX.js +3 -0
  262. package/dist/esm/post-accordion_2.entry.js +17 -13
  263. package/dist/esm/post-avatar.entry.js +22 -12
  264. package/dist/esm/post-back-to-top.entry.js +23 -43
  265. package/dist/esm/post-banner.entry.js +14 -11
  266. package/dist/esm/post-breadcrumb-item_2.entry.js +13 -11
  267. package/dist/esm/post-breadcrumbs.entry.js +31 -32
  268. package/dist/esm/post-card-control.entry.js +32 -16
  269. package/dist/esm/{post-closebutton_15.entry.js → post-closebutton_13.entry.js} +599 -510
  270. package/dist/esm/post-collapsible_2.entry.js +38 -34
  271. package/dist/esm/post-components.js +4 -4
  272. package/dist/esm/post-env-test.entry.js +13 -0
  273. package/dist/esm/post-footer.entry.js +21 -17
  274. package/dist/esm/post-linkarea.entry.js +5 -5
  275. package/dist/esm/post-pagination.entry.js +613 -0
  276. package/dist/esm/post-popover-trigger.entry.js +52 -32
  277. package/dist/esm/post-popover.entry.js +25 -16
  278. package/dist/esm/post-rating.entry.js +16 -10
  279. package/dist/esm/post-stepper-item.entry.js +5 -5
  280. package/dist/esm/post-stepper.entry.js +39 -28
  281. package/dist/esm/post-tab-item.entry.js +49 -0
  282. package/dist/esm/post-tab-panel.entry.js +13 -11
  283. package/dist/esm/post-tabs.entry.js +195 -40
  284. package/dist/esm/post-tooltip-trigger.entry.js +10 -8
  285. package/dist/esm/post-tooltip.entry.js +13 -11
  286. package/dist/esm/utils-CoDiS_Ik.js +24 -0
  287. package/dist/post-components/p-09ba7cf9.entry.js +1 -0
  288. package/dist/post-components/p-0c091898.entry.js +1 -0
  289. package/dist/post-components/{p-cd03e6f2.entry.js → p-0e97fcfd.entry.js} +1 -1
  290. package/dist/post-components/p-296f1dd5.entry.js +1 -0
  291. package/dist/post-components/p-32ad2b21.entry.js +1 -0
  292. package/dist/post-components/p-366c28cb.entry.js +1 -0
  293. package/dist/post-components/p-41ae68d5.entry.js +1 -0
  294. package/dist/post-components/p-448e7265.entry.js +1 -0
  295. package/dist/post-components/p-554da188.entry.js +1 -0
  296. package/dist/post-components/p-5912f8f1.entry.js +1 -0
  297. package/dist/post-components/p-790f300d.entry.js +1 -0
  298. package/dist/post-components/p-7ed5a493.entry.js +1 -0
  299. package/dist/post-components/p-85bea1b6.entry.js +1 -0
  300. package/dist/post-components/p-8bcff4d2.entry.js +1 -0
  301. package/dist/post-components/p-9dc9c245.entry.js +1 -0
  302. package/dist/post-components/p-B7ebLhHc.js +1 -0
  303. package/dist/post-components/p-BVCjnh6Q.js +1 -0
  304. package/dist/post-components/p-BXNs2_sw.js +1 -0
  305. package/dist/post-components/p-C9hMpmsD.js +1 -0
  306. package/dist/post-components/p-CDZBzSdV.js +2 -0
  307. package/dist/post-components/p-CEmnRoA6.js +1 -0
  308. package/dist/post-components/p-CZvbetqX.js +1 -0
  309. package/dist/post-components/p-CoDiS_Ik.js +1 -0
  310. package/dist/post-components/p-D5knoiyy.js +1 -0
  311. package/dist/post-components/p-DI-h_mEL.js +1 -0
  312. package/dist/post-components/p-a06f9695.entry.js +1 -0
  313. package/dist/post-components/p-a191f1df.entry.js +1 -0
  314. package/dist/post-components/p-c5d19d62.entry.js +1 -0
  315. package/dist/post-components/{p-24dc54d1.entry.js → p-c8c4d05b.entry.js} +1 -1
  316. package/dist/post-components/{p-57288cb2.entry.js → p-d1a5c980.entry.js} +1 -1
  317. package/dist/post-components/p-d4e2c556.entry.js +1 -0
  318. package/dist/post-components/p-f96a310c.entry.js +1 -0
  319. package/dist/post-components/p-fab2327d.entry.js +1 -0
  320. package/dist/post-components/p-rEfV4v4a.js +1 -0
  321. package/dist/post-components/post-components.css +1 -1
  322. package/dist/post-components/post-components.esm.js +1 -1
  323. package/dist/prebuild.js +46 -0
  324. package/dist/types/animations/collapse.d.ts +1 -0
  325. package/dist/types/animations/fade-slide.d.ts +11 -0
  326. package/dist/types/animations/fade.d.ts +2 -2
  327. package/dist/types/animations/index.d.ts +2 -0
  328. package/dist/types/animations/slide.d.ts +9 -2
  329. package/dist/types/animations/types.d.ts +13 -0
  330. package/dist/types/animations/utils.d.ts +2 -0
  331. package/dist/types/components/post-accordion-item/heading-levels.d.ts +1 -1
  332. package/dist/types/components/post-accordion-item/post-accordion-item.d.ts +2 -2
  333. package/dist/types/components/post-back-to-top/post-back-to-top.d.ts +2 -2
  334. package/dist/types/components/post-breadcrumbs/post-breadcrumbs.d.ts +6 -6
  335. package/dist/types/components/post-collapsible/post-collapsible.d.ts +4 -5
  336. package/dist/types/components/post-footer/post-footer.d.ts +4 -4
  337. package/dist/types/components/post-header/post-header.d.ts +23 -13
  338. package/dist/types/components/{post-language-switch/post-language-switch.d.ts → post-language-menu/post-language-menu.d.ts} +12 -11
  339. package/dist/types/components/{post-language-option/post-language-option.d.ts → post-language-menu-item/post-language-menu-item.d.ts} +5 -5
  340. package/dist/types/components/post-mainnavigation/post-mainnavigation.d.ts +6 -5
  341. package/dist/types/components/post-megadropdown/post-megadropdown.d.ts +20 -2
  342. package/dist/types/components/post-megadropdown-trigger/post-megadropdown-trigger.d.ts +17 -23
  343. package/dist/types/components/post-menu/post-menu.d.ts +4 -4
  344. package/dist/types/components/post-pagination/post-pagination.d.ts +224 -0
  345. package/dist/types/components/post-popover/post-popover.d.ts +4 -3
  346. package/dist/types/components/post-popover-trigger/post-popover-trigger.d.ts +2 -1
  347. package/dist/types/components/post-popovercontainer/post-popovercontainer.d.ts +23 -21
  348. package/dist/types/components/post-rating/post-rating.d.ts +1 -1
  349. package/dist/types/components/post-stepper/post-stepper.d.ts +9 -8
  350. package/dist/types/components/post-tab-item/post-tab-item.d.ts +19 -0
  351. package/dist/types/components/post-tab-panel/post-tab-panel.d.ts +3 -3
  352. package/dist/types/components/post-tabs/post-tabs.d.ts +33 -12
  353. package/dist/types/components/post-tooltip/post-tooltip.d.ts +1 -5
  354. package/dist/types/components.d.ts +322 -219
  355. package/dist/types/home/runner/work/design-system/design-system/packages/components/.stencil/prebuild.d.ts +9 -0
  356. package/dist/types/stencil-public-runtime.d.ts +147 -10
  357. package/dist/types/types/heading-levels.d.ts +1 -1
  358. package/dist/types/utils/environment.d.ts +25 -1
  359. package/dist/types/utils/get-focusable-children.d.ts +2 -2
  360. package/dist/types/utils/tests/environment/hydrate-app-helper.d.ts +5 -0
  361. package/dist/types/utils/tests/environment/post-env-test.d.ts +3 -0
  362. package/hydrate/index.d.ts +14 -0
  363. package/hydrate/index.js +7494 -2714
  364. package/hydrate/index.mjs +7493 -2715
  365. package/package.json +7 -8
  366. package/dist/cjs/fade-nS5zzDQS.js +0 -14
  367. package/dist/cjs/index-UFKR6Ok0.js +0 -98
  368. package/dist/cjs/post-tab-header.cjs.entry.js +0 -31
  369. package/dist/collection/animations/slide-and-fade.js +0 -25
  370. package/dist/collection/components/post-language-option/post-language-option.css +0 -1
  371. package/dist/collection/components/post-language-switch/post-language-switch.css +0 -1
  372. package/dist/collection/components/post-list/post-list.css +0 -1
  373. package/dist/collection/components/post-list/post-list.js +0 -97
  374. package/dist/collection/components/post-list-item/post-list-item.css +0 -1
  375. package/dist/collection/components/post-list-item/post-list-item.js +0 -26
  376. package/dist/collection/components/post-tab-header/post-tab-header.css +0 -1
  377. package/dist/collection/components/post-tab-header/post-tab-header.js +0 -65
  378. package/dist/components/index2.js +0 -89
  379. package/dist/components/post-language-option.d.ts +0 -11
  380. package/dist/components/post-language-option.js +0 -99
  381. package/dist/components/post-language-switch.js +0 -157
  382. package/dist/components/post-list-item.js +0 -38
  383. package/dist/components/post-list.js +0 -61
  384. package/dist/components/post-tab-header.js +0 -52
  385. package/dist/components/react/p-BVXiQdHq.js +0 -64
  386. package/dist/components/react/p-BhxZzOEC.js +0 -3
  387. package/dist/components/react/p-CSAMO7iJ.js +0 -243
  388. package/dist/components/react/p-CYkf_7Y5.js +0 -89
  389. package/dist/components/react/p-Ccrl2AQn.js +0 -111
  390. package/dist/components/react/p-CewRvBtg.js +0 -139
  391. package/dist/components/react/p-Cwiv86_f.js +0 -111
  392. package/dist/components/react/p-D2waO0Zc.js +0 -31
  393. package/dist/components/react/p-DBPOV12C.js +0 -160
  394. package/dist/components/react/p-DVGEExot.js +0 -3128
  395. package/dist/components/react/p-Djvj8fd2.js +0 -80
  396. package/dist/components/react/p-LtiDhYis.js +0 -137
  397. package/dist/components/react/p-SbIC4aZX.js +0 -11
  398. package/dist/components/react/p-XrZzCOKT.js +0 -78
  399. package/dist/components/react/p-v3pOrMNQ.js +0 -114
  400. package/dist/components/react/post-language-option.js +0 -100
  401. package/dist/components/react/post-language-switch.d.ts +0 -11
  402. package/dist/components/react/post-language-switch.js +0 -158
  403. package/dist/components/react/post-list-item.js +0 -39
  404. package/dist/components/react/post-list.js +0 -62
  405. package/dist/components/react/post-tab-header.js +0 -53
  406. package/dist/esm/breakpoints-CJ80BZ06.js +0 -178
  407. package/dist/esm/event-from-CzIKqBrS.js +0 -119
  408. package/dist/esm/fade-SbIC4aZX.js +0 -11
  409. package/dist/esm/get-root-BkQ3CrLq.js +0 -15
  410. package/dist/esm/index-Beaz8wEe.js +0 -89
  411. package/dist/esm/package-BhxZzOEC.js +0 -3
  412. package/dist/esm/post-tab-header.entry.js +0 -29
  413. package/dist/post-components/p-01e678c9.entry.js +0 -1
  414. package/dist/post-components/p-034a453f.entry.js +0 -1
  415. package/dist/post-components/p-15a4cdbf.entry.js +0 -1
  416. package/dist/post-components/p-2a2030bf.entry.js +0 -1
  417. package/dist/post-components/p-2ed84cc3.entry.js +0 -1
  418. package/dist/post-components/p-3228968f.entry.js +0 -1
  419. package/dist/post-components/p-3c01ddfe.entry.js +0 -1
  420. package/dist/post-components/p-748b1f01.entry.js +0 -1
  421. package/dist/post-components/p-7745e46e.entry.js +0 -1
  422. package/dist/post-components/p-7f635728.entry.js +0 -1
  423. package/dist/post-components/p-82c178a3.entry.js +0 -1
  424. package/dist/post-components/p-9b5f8319.entry.js +0 -1
  425. package/dist/post-components/p-Beaz8wEe.js +0 -1
  426. package/dist/post-components/p-BhxZzOEC.js +0 -1
  427. package/dist/post-components/p-CJ80BZ06.js +0 -1
  428. package/dist/post-components/p-D9ZHp2FP.js +0 -1
  429. package/dist/post-components/p-SbIC4aZX.js +0 -1
  430. package/dist/post-components/p-a9644e54.entry.js +0 -1
  431. package/dist/post-components/p-af030a3a.entry.js +0 -1
  432. package/dist/post-components/p-b8ba8139.entry.js +0 -1
  433. package/dist/post-components/p-db935e8e.entry.js +0 -1
  434. package/dist/post-components/p-e62e1f57.entry.js +0 -1
  435. package/dist/post-components/p-fb4b1641.entry.js +0 -1
  436. package/dist/post-components/p-wEFJ-c34.js +0 -2
  437. package/dist/types/animations/slide-and-fade.d.ts +0 -2
  438. package/dist/types/components/post-list/post-list.d.ts +0 -24
  439. package/dist/types/components/post-list-item/post-list-item.d.ts +0 -8
  440. package/dist/types/components/post-tab-header/post-tab-header.d.ts +0 -14
  441. /package/dist/collection/components/{post-language-switch → post-language-menu}/switch-variants.js +0 -0
  442. /package/dist/{post-components/p-CzIKqBrS.js → components/react/p-rEfV4v4a.js} +0 -0
  443. /package/dist/types/components/{post-language-switch → post-language-menu}/switch-variants.d.ts +0 -0
@@ -0,0 +1 @@
1
+ import{a as t}from"./p-FxUVQ4Tx.js";const o=[void 0,null,"",NaN];function e(t){return o.some((o=>o===t))}function n(t){return(o,n,...i)=>{const s=o.host.localName,c=o[n],r=`The prop \`${String(n)}\` of the \`${s}\` component is not defined.`;if(e(c))throw new Error(r);t(o,n,...i)}}function i(t,o,e){const n=t.host.localName,i=t[o],s=`The prop \`${String(o)}\` of the \`${n}\` component must be one of the following values: ${e.join(", ")}.`;e.includes(i)||console.error(s)}function s(t,o,e){const n=t.host.localName,i=t[o],s=`The prop \`${String(o)}\` of the \`${n}\` component must follow the format \`${e}\`.`;"string"==typeof i&&e.test(i)||console.error(s)}function c(t,o,e){const n=t.host.localName,i=t[o],s="array"===e,c=Array.isArray(i),r=`The prop \`${String(o)}\` of the \`${n}\` component must be of type \`${e}\`.`;s||c?c!==s&&console.error(r):typeof i!==e&&console.error(r)}function r(t,o){const e=t.host.localName,n=t[o],i=`The prop \`${String(o)}\` of the \`${e}\` component is invalid.`;if("string"==typeof n||n instanceof URL)try{new URL(n,"https://www.post.ch")}catch{console.error(i)}else console.error(i)}function a(t){return(o,n,...i)=>{e(o[n])||t(o,n,...i)}}const h=a(i),f=a(s),d=a(c),p=a(r),u=n(i),m=n(s),v=n(c),l=n(r);function w(t,o){var e,n={},i=n.noTrailing,s=void 0!==i&&i,c=n.noLeading,r=void 0!==c&&c,a=n.debounceMode,h=void 0===a?void 0:a,f=!1,d=0;function p(){e&&clearTimeout(e)}function u(){for(var n=arguments.length,i=new Array(n),c=0;c<n;c++)i[c]=arguments[c];var a=this,u=Date.now()-d;function m(){d=Date.now(),o.apply(a,i)}function v(){e=void 0}f||(r||!h||e||m(),p(),void 0===h&&u>t?r?(d=Date.now(),s||(e=setTimeout(h?v:m,t))):m():!0!==s&&(e=setTimeout(h?v:m,void 0===h?t-u:t)))}return u.cancel=function(t){var o=(t||{}).upcomingOnly,e=void 0!==o&&o;p(),f=!e},u}const $=new class{constructor(){this.breakpoints=[{key:"xl",device:"desktop",minWidth:1280},{key:"lg",device:"desktop",minWidth:1024},{key:"md",device:"tablet",minWidth:780},{key:"sm",device:"tablet",minWidth:600},{key:"xs",device:"mobile",minWidth:0}],this.updateCurrentBreakpoint=w(50,((t={emitEvents:!0})=>{const o=this.currentBreakpoint,e=this.breakpoints.find((t=>t.minWidth<=innerWidth));e&&(this.currentBreakpoint=e,t.emitEvents&&Object.keys(this.currentBreakpoint).filter((t=>!o||this.currentBreakpoint[t]!==o[t])).forEach((t=>this.dispatchEvent(t))))})),t||(this.updateCurrentBreakpoint({emitEvents:!1}),window.addEventListener("resize",(()=>this.updateCurrentBreakpoint()),{passive:!0}))}dispatchEvent(o){t||window.dispatchEvent(new CustomEvent(`postBreakpoint:${o}`,{detail:this.currentBreakpoint[o]}))}get(t){return this.updateCurrentBreakpoint({emitEvents:!1}),this.currentBreakpoint[t]}};export{p as a,u as b,v as c,h as d,d as e,l as f,$ as g,m as h,f as i,w as t}
@@ -0,0 +1 @@
1
+ import{t,p as s,H as i,h as e,a as o}from"./index.js";import{v as n}from"./p-CZvbetqX.js";import{c as r}from"./p-B8YiQ3mz.js";import{g as a}from"./p-BVGcVycs.js";const h=s(class extends i{constructor(t){super(),!1!==t&&this.__registerHost(),this.ariaExpanded=!1,this.slottedButton=null,this.handleKeyDown=t=>{"ArrowUp"!==t.key&&"ArrowDown"!==t.key||(t.preventDefault(),this.handleToggle())}}validateControlFor(){r(this,"for","string")}get menu(){const t=this.root.getElementById(this.for);return t&&"post-menu"===t.localName?t:null}handleToggle(){this.menu?this.menu.toggle(this.host):console.warn(`No post-menu found with ID: ${this.for}`)}connectedCallback(){this.root=a(this.host)}componentDidLoad(){if(this.validateControlFor(),this.slottedButton=this.host.querySelector("button"),!this.slottedButton){const t=this.host.querySelector(".menu-trigger-webc");if(t?.shadowRoot){const s=t.shadowRoot.querySelector("button");s&&(this.slottedButton=s)}}this.slottedButton?(this.slottedButton.setAttribute("aria-haspopup","menu"),this.menu&&this.slottedButton&&this.menu.addEventListener("toggleMenu",(t=>{this.ariaExpanded=t.detail,this.slottedButton.setAttribute("aria-expanded",this.ariaExpanded.toString())})),this.slottedButton.addEventListener("click",(()=>{this.handleToggle()})),this.slottedButton.addEventListener("keydown",this.handleKeyDown)):console.warn("No button found within post-menu-trigger")}render(){return e(o,{key:"13701a50f739c2252ab296e13c657e1d4c51444b","data-version":n,"tab-index":"-1"},e("slot",{key:"dc5fd68d917d3cfe2a9703553b1fba4047770260"}))}get host(){return this}static get watchers(){return{for:[{validateControlFor:0}]}}static get style(){return":host{display:inline-block}"}},[260,"post-menu-trigger",{for:[513],ariaExpanded:[32]},void 0,{for:[{validateControlFor:0}]}]);function c(){"undefined"!=typeof customElements&&["post-menu-trigger"].forEach((s=>{"post-menu-trigger"===s&&(customElements.get(t(s))||customElements.define(t(s),h))}))}c();export{h as P,c as d}
@@ -1,14 +1 @@
1
- const urlAlphabet =
2
- 'useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict';
3
-
4
- /* @ts-self-types="./index.d.ts" */
5
- let nanoid = (size = 21) => {
6
- let id = '';
7
- let bytes = crypto.getRandomValues(new Uint8Array((size |= 0)));
8
- while (size--) {
9
- id += urlAlphabet[bytes[size] & 63];
10
- }
11
- return id
12
- };
13
-
14
- export { nanoid as n };
1
+ let r=(r=21)=>{let t="",e=crypto.getRandomValues(new Uint8Array(r|=0));for(;r--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[63&e[r]];return t};export{r as n}
@@ -0,0 +1 @@
1
+ import{r as n}from"./p-CoDiS_Ik.js";const t={duration:500,easing:"ease",fill:"none",translate:-100};function a(a,r,i){if(!a)return;const o=i,{translate:s}=o,e=[{opacity:"0",transform:`translateY(${s}px)`},{opacity:"1",transform:"translateY(0px)"}];return function(a,r,i){const{duration:o,easing:s,fill:e}={...t,...i};return a.animate(r,{duration:o,easing:n(s),fill:e})}(a,"in"===r?e:[...e].reverse(),i)}export{a as f}
@@ -1 +1 @@
1
- import{I as t}from"./p-CJ80BZ06.js";function o(o){const e=t?o.getRootNode():o;if(e instanceof Document||e instanceof ShadowRoot)return e;throw new Error("Attempting to access root node before the element is attached to the document or shadow tree.")}export{o as g}
1
+ import{I as t}from"./p-FxUVQ4Tx.js";function o(o){const e=t?o.getRootNode():o;if(e instanceof Document||e instanceof ShadowRoot)return e;throw new Error("Attempting to access root node before the element is attached to the document or shadow tree.")}export{o as g}
@@ -0,0 +1 @@
1
+ import{p as o,H as e,h as t,a as i,t as c}from"./index.js";import{v as a}from"./p-CZvbetqX.js";import{H as s}from"./p-r4txK0AC.js";import{d as r}from"./p-B8YiQ3mz.js";import{E as n}from"./p-rEfV4v4a.js";import{n as d}from"./p-BLchVpF6.js";import{d as l}from"./p-sSn0kXFi.js";import{d as p}from"./p-BmRNjQUZ.js";import{d as b}from"./p-DY2U5CQt.js";const h=o(class extends e{constructor(o){super(),!1!==o&&this.__registerHost(),this.__attachShadow(),this.collapsed=!1}validateHeadingLevel(){r(this,"headingLevel",s)}componentWillLoad(){this.id=this.host.id||`p${d(6)}`}componentDidLoad(){this.validateHeadingLevel()}onCollapseToggle(o){this.collapsed=!o.detail}async toggle(o){return this.collapsible.toggle(o)}onSlotLogoChange(){this.slottedLogo=this.host.querySelector('img[slot="logo"]')}componentWillRender(){this.slottedLogo=this.host.querySelector('img[slot="logo"]')}render(){const o=this.host.closest("post-accordion")?.getAttribute("heading-level");return t(i,{key:"03e6974f6d2f02e0d9240c84516f6538a2a96c9a",id:this.id,"data-version":a},t("post-collapsible-trigger",{key:"de3fe01f5fdc4394d6ba0163313850a60b0134ec",for:`${this.id}--collapse`},t(`h${o??this.headingLevel??2}`,{key:"abc8ccd196030b90f800ffca0075f0a99a70229d",class:"accordion-header",id:`${this.id}--header`},t("button",{key:"422fb7f22228706ca0d07f07241ec72fab6387b7",type:"button",class:"accordion-button"+(this.collapsed?" collapsed":""),part:"post-accordion-button"},t("span",{key:"1b2bec5bf36707656ac92f65f99d2e1c5f1d44c3",class:{"logo-container":!0,"has-image":!!this.slottedLogo}},t("slot",{key:"717d1393ab1277a0f141c7a978585d288ab9359b",name:"logo",onSlotchange:this.onSlotLogoChange.bind(this)})),t("slot",{key:"6c7f506f051b96f07991cd4c56c884527e736eb5",name:"header"}),t("post-icon",{key:"e77b71473bcf619b1083dfea8b87d219489f774e",name:"chevronup"})))),t("post-collapsible",{key:"020481b62323ea8719cd8289c6b402611a83944b",id:`${this.id}--collapse`,collapsed:this.collapsed,ref:o=>this.collapsible=o},t("div",{key:"99bdc90c6a557958d1ecb73860b9f6c904165496",class:"accordion-body",part:"post-accordion-body"},t("slot",{key:"0a10be7f2b7fb61614fec92a5306372ada0dcf62"}))))}get host(){return this}static get watchers(){return{headingLevel:[{validateHeadingLevel:0}]}}static get style(){return':host{display:block;border-block-end:var(--post-device-border-width-default) var(--post-core-border-style-solid) var(--post-scheme-color-interactive-primary-enabled-stroke)}:host:has(.accordion-button:hover){border-block-end-color:var(--post-scheme-color-interactive-primary-hover-stroke)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host:has(.accordion-button:hover){border-block-end-color:Highlight}}.accordion-header{color:var(--post-scheme-color-interactive-primary-enabled-fg1);font-size:var(--post-device-font-size-5);margin:0;line-height:var(--post-device-line-height-heading);font-weight:var(--post-device-font-weight-extra-black)}.accordion-button{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;display:flex;position:relative;width:100%;align-items:center;text-align:start;gap:var(--post-device-spacing-gap-7);padding-block:var(--post-device-spacing-padding-19);padding-inline:var(--post-device-spacing-padding-5);border-block-end:var(--post-device-border-width-default) var(--post-core-border-style-solid) rgba(0,0,0,0);cursor:pointer;outline:none !important}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.accordion-button{background-color:ButtonFace !important}.accordion-button:hover{background-color:Highlight !important}}.accordion-button::before{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}.accordion-button:is(:focus-visible,:has(:focus-visible),.pretend-focus)::before{outline-style:var(--post-core-border-style-solid) !important;display:block;content:"";position:absolute;inset:calc(var(--post-device-border-width-default)*-1) 0 calc(var(--post-device-border-width-default)*-1);border-radius:var(--post-device-border-radius-focus)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.accordion-button:is(:focus-visible,:has(:focus-visible),.pretend-focus)::before{outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){.accordion-button:is(:focus-visible,:focus-within,.pretend-focus)::before{outline-style:var(--post-core-border-style-solid) !important;display:block;content:"";position:absolute;inset:calc(var(--post-device-border-width-default)*-1) 0 calc(var(--post-device-border-width-default)*-1);border-radius:var(--post-device-border-radius-focus)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.accordion-button:is(:focus-visible,:focus-within,.pretend-focus)::before{outline-color:Highlight !important}}}.accordion-button slot::slotted(span[slot=header]){flex-grow:1}.accordion-button post-icon{flex:none;width:var(--post-core-dimension-24);aspect-ratio:1;transition:transform 250ms cubic-bezier(0.4, 0, 0.2, 1)}.accordion-button.collapsed{padding-block-start:var(--post-device-spacing-padding-19);padding-block-end:var(--post-device-spacing-padding-19)}.accordion-button.collapsed post-icon{transform:rotate(-180deg)}.accordion-button:hover{color:var(--post-scheme-color-interactive-primary-hover-fg1)}.accordion-button>::slotted(.text-truncate){display:block}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.accordion-button:hover,.accordion-button:focus-visible{color:Highlight}}post-collapsible{margin-block-end:calc(var(--post-device-border-width-default)*-1)}.accordion-body{padding-block-start:var(--post-device-spacing-padding-15);padding-block-end:var(--post-device-spacing-padding-block-25);padding-inline:var(--post-device-spacing-padding-5)}.logo-container{display:none;width:var(--post-device-sizing-logo-1);aspect-ratio:1}.logo-container.has-image{display:block}.logo-container slot::slotted(img){display:block;width:100%;height:100%;object-fit:cover}.accordion-button>::slotted(:first-child),.accordion-body>::slotted(:first-child){margin-block-start:0 !important}.accordion-button>::slotted(:last-child),.accordion-body>::slotted(:last-child){margin-block-end:0 !important}'}},[257,"post-accordion-item",{collapsed:[1028],headingLevel:[2,"heading-level"],id:[32],slottedLogo:[32],toggle:[64]},[[2,"postToggle","onCollapseToggle"]],{headingLevel:[{validateHeadingLevel:0}]}]);function g(){"undefined"!=typeof customElements&&["post-accordion-item","post-collapsible","post-collapsible-trigger","post-icon"].forEach((o=>{switch(o){case"post-accordion-item":customElements.get(c(o))||customElements.define(c(o),h);break;case"post-collapsible":customElements.get(c(o))||l();break;case"post-collapsible-trigger":customElements.get(c(o))||p();break;case"post-icon":customElements.get(c(o))||b()}}))}(function(o,e,t,i){var c,a=arguments.length,s=a<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,t):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(o,e,t,i);else for(var r=o.length-1;r>=0;r--)(c=o[r])&&(s=(a<3?c(s):a>3?c(e,t,s):c(e,t))||s);a>3&&s&&Object.defineProperty(e,t,s)})([n("post-accordion-item")],h.prototype,"onCollapseToggle",null),g();export{h as P,g as d}
@@ -0,0 +1 @@
1
+ import{t,p as e,H as s,h as o,a as i}from"./index.js";import{v as a}from"./p-CZvbetqX.js";const r=e(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.toggled=!1,this.handleClick=()=>{this.toggled=!this.toggled},this.handleKeydown=t=>{"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),this.host.click())}}componentWillLoad(){this.host.addEventListener("click",(()=>this.handleClick())),this.host.addEventListener("keydown",(t=>this.handleKeydown(t)))}render(){return o(i,{key:"e0708bda008257aeab8e9ad82c33c66eff4aedb6","data-version":a,role:"button",tabindex:"0","aria-pressed":this.toggled.toString()},o("slot",{key:"a10862573155edbef1a88bd8a1f9f8abf9dbe4c0"}))}get host(){return this}static get style(){return":host{cursor:pointer;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}:host(:focus-visible){outline-style:var(--post-core-border-style-solid) !important}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host(:focus-visible){outline-color:Highlight !important}}:host([aria-pressed=true]) ::slotted([data-showwhen=untoggled]){display:none}:host([aria-pressed=false]) ::slotted([data-showwhen=toggled]){display:none}"}},[257,"post-togglebutton",{toggled:[1028]}]);function n(){"undefined"!=typeof customElements&&["post-togglebutton"].forEach((e=>{"post-togglebutton"===e&&(customElements.get(t(e))||customElements.define(t(e),r))}))}n();export{r as P,n as d}
@@ -0,0 +1 @@
1
+ import{p as t,H as s,h as i,a as e,t as o}from"./index.js";import{v as a}from"./p-CZvbetqX.js";import{c as r}from"./p-B8YiQ3mz.js";import{E as l}from"./p-rEfV4v4a.js";import{g as c}from"./p-BVGcVycs.js";const n=t(class extends s{validateAriaAttributes(){r(this,"for","string")}constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.observer=new MutationObserver((()=>this.setTrigger())),this.handlePostToggle=this.handlePostToggle.bind(this)}connectedCallback(){this.root=c(this.host),this.root.addEventListener("postToggle",this.handlePostToggle),this.observer.observe(this.host,{childList:!0,subtree:!0})}componentDidLoad(){this.setTrigger(),this.trigger||console.warn("The post-collapsible-trigger must contain a button."),this.validateAriaAttributes()}disconnectedCallback(){this.observer.disconnect(),this.root?.removeEventListener("postToggle",this.handlePostToggle)}async update(){this.updateAriaAttributes()}handlePostToggle(t){this.trigger&&this.trigger.setAttribute("aria-expanded",`${t.detail}`)}updateAriaAttributes(){if(!this.trigger)return;const t=this.trigger.getAttribute("aria-controls");t?.includes(this.for)||this.trigger.setAttribute("aria-controls",t?`${t} ${this.for}`:this.for);const s=this.collapsible?.collapsed;this.trigger.setAttribute("aria-expanded",`${void 0!==s?!s:void 0}`)}async toggleCollapsible(){await(this.collapsible?.toggle())}get collapsible(){const t=this.root.getElementById(this.for);return t&&"post-collapsible"===t.localName?t:null}setTrigger(){const t=this.host.querySelector("button");!t||this.trigger&&t.isEqualNode(this.trigger)||(this.trigger=t,this.trigger.addEventListener("click",(()=>this.toggleCollapsible())),this.updateAriaAttributes())}render(){return i(e,{key:"f5055d5970eb900d345957f306c9a373680f257a","data-version":a},i("slot",{key:"cf63bdbca00602b9c4e2a81f28723bd274561045"}))}get host(){return this}static get watchers(){return{for:[{validateAriaAttributes:0}]}}},[257,"post-collapsible-trigger",{for:[513],update:[64]},void 0,{for:[{validateAriaAttributes:0}]}]);function h(){"undefined"!=typeof customElements&&["post-collapsible-trigger"].forEach((t=>{"post-collapsible-trigger"===t&&(customElements.get(o(t))||customElements.define(o(t),n))}))}(function(t,s,i,e){var o,a=arguments.length,r=a<3?s:null===e?e=Object.getOwnPropertyDescriptor(s,i):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,s,i,e);else for(var l=t.length-1;l>=0;l--)(o=t[l])&&(r=(a<3?o(r):a>3?o(s,i,r):o(s,i))||r);a>3&&r&&Object.defineProperty(s,i,r)})([l("post-collapsible")],n.prototype,"handlePostToggle",null),h();export{n as P,h as d}
@@ -0,0 +1 @@
1
+ import{t,p as e,H as o,h as s,a as i}from"./index.js";import{v as n}from"./p-CZvbetqX.js";import{d as c}from"./p-B8YiQ3mz.js";import{d as r}from"./p-DY2U5CQt.js";const a=["button","submit","reset"],d=e(class extends o{constructor(t){super(),!1!==t&&this.__registerHost(),this.mutationObserver=new MutationObserver(this.checkContent.bind(this)),this.buttonType="button"}validateButtonType(){c(this,"buttonType",a)}componentDidLoad(){this.checkContent()}connectedCallback(){this.mutationObserver.observe(this.host,{childList:!0,characterData:!0,subtree:!0})}disconnectedCallback(){this.mutationObserver&&this.mutationObserver.disconnect()}checkContent(){this.validateButtonType(),this.host.querySelector(".visually-hidden").textContent||console.error(`The \`${this.host.localName}\` component requires content for accessibility.`)}render(){return s(i,{key:"6965a8cb5fb765b4fcec0439ceeafe19d34970c2","data-version":n},s("button",{key:"7e718f70b0a4ac79e9439784dac46bd1ffd60fd1",class:"btn",type:this.buttonType},s("post-icon",{key:"70acda3fbe6c9420f0be708fde6b29a7d5337d13","aria-hidden":"true",name:"closex"}),s("span",{key:"899b3814c0898b521e4166e1cd951af628558e78",class:"visually-hidden"},s("slot",{key:"b13d0e95fd567c86e93e5185389909c7c0e7107d"}))))}get host(){return this}static get watchers(){return{buttonType:[{validateButtonType:0}]}}static get style(){return".visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0}post-closebutton .btn{padding:0;border:unset;min-height:unset;min-width:unset;width:var(--post-device-sizing-notification-1);height:var(--post-device-sizing-notification-1);border-radius:var(--post-device-border-radius-round);background-color:var(--post-scheme-color-interactive-button-tertiary-enabled-bg);color:var(--post-scheme-color-interactive-button-tertiary-enabled-fg);display:flex;align-items:center;justify-content:center}post-closebutton .btn>post-icon{min-width:var(--post-device-sizing-interactive-icon-size4);width:var(--post-device-sizing-interactive-icon-size4);height:var(--post-device-sizing-interactive-icon-size4)}post-closebutton .btn{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-closebutton .btn: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-closebutton .btn:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){post-closebutton .btn: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-closebutton .btn:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}post-closebutton .btn:not(:disabled):hover,post-closebutton .btn.pretend-hover{cursor:pointer;background-color:var(--post-scheme-color-interactive-button-tertiary-hover-bg);color:var(--post-scheme-color-interactive-button-tertiary-hover-fg)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){post-closebutton .btn:not(:disabled):hover,post-closebutton .btn.pretend-hover{color:HighlightText !important}}"}},[260,"post-closebutton",{buttonType:[1,"button-type"]},void 0,{buttonType:[{validateButtonType:0}]}]);function l(){"undefined"!=typeof customElements&&["post-closebutton","post-icon"].forEach((e=>{switch(e){case"post-closebutton":customElements.get(t(e))||customElements.define(t(e),d);break;case"post-icon":customElements.get(t(e))||r()}}))}l();export{d as P,l as d}
@@ -0,0 +1 @@
1
+ function e(e,t=200){let o;return(...r)=>{o&&clearTimeout(o),o=setTimeout(e,t,...r)}}export{e as d}
@@ -0,0 +1 @@
1
+ const e=`:where(${["button",'input:not([type="hidden"])',"[tabindex]","select","textarea","[contenteditable]","a[href]","iframe","audio[controls]","video[controls]","area[href]","details > summary:first-of-type"].join(",")})`,t=`:where(${["[inert]","[inert] *",":disabled","dialog:not([open]) *","[popover]:not(:popover-open) *","details:not([open]) > *:not(details > summary:first-of-type)","details:not([open]) > *:not(details > summary:first-of-type) *",'[tabindex^="-"]','[hidden]:not([hidden="false"])'].join(",")})`;function n(n){const o=n.querySelectorAll(`${e}:not(${t})`);return Array.from(o).filter(r)}function o(e,t,n=new Set){if(n.has(e))return[];n.add(e);let r=[];if(e instanceof HTMLSlotElement){const t=e.assignedElements({flatten:!0});r=t.length?t:Array.from(e.children)}else e instanceof HTMLElement&&e.shadowRoot?r=Array.from(e.shadowRoot.children):e instanceof Element&&(r=Array.from(e.children));t&&(r=r.filter(t));const a=[];for(const e of r)i(e)?a.push(e):a.push(...o(e,t,n));return a}function r(e){const t=window.getComputedStyle(e);return"none"!==t.display&&"hidden"!==t.visibility}function i(n){return n instanceof HTMLElement&&n.matches(`${e}:not(${t})`)&&r(n)}export{o as a,n as g}
@@ -0,0 +1 @@
1
+ const t="10.0.0-next.57";export{t as v}
@@ -5,260 +5,4 @@
5
5
  * @author John Doherty <www.johndoherty.info>
6
6
  * @license MIT
7
7
  */
8
- (function (window, document) {
9
-
10
- // local timer object based on rAF
11
- var timer = null;
12
-
13
- // check if we're using a touch screen
14
- var hasPointerEvents = (('PointerEvent' in window) || (window.navigator && 'msPointerEnabled' in window.navigator));
15
- var isTouch = (('ontouchstart' in window) || (navigator.MaxTouchPoints > 0) || (navigator.msMaxTouchPoints > 0));
16
-
17
- // switch to pointer events or touch events if using a touch screen
18
- var mouseDown = hasPointerEvents ? 'pointerdown' : isTouch ? 'touchstart' : 'mousedown';
19
- var mouseUp = hasPointerEvents ? 'pointerup' : isTouch ? 'touchend' : 'mouseup';
20
- var mouseMove = hasPointerEvents ? 'pointermove' : isTouch ? 'touchmove' : 'mousemove';
21
- var mouseLeave = hasPointerEvents ? 'pointerleave' : isTouch ? 'touchleave' : 'mouseleave';
22
-
23
- // track number of pixels the mouse moves during long press
24
- var startX = 0; // mouse x position when timer started
25
- var startY = 0; // mouse y position when timer started
26
- var maxDiffX = 10; // max number of X pixels the mouse can move during long press before it is canceled
27
- var maxDiffY = 10; // max number of Y pixels the mouse can move during long press before it is canceled
28
-
29
- // patch CustomEvent to allow constructor creation (IE/Chrome)
30
- if (typeof window.CustomEvent !== 'function') {
31
-
32
- window.CustomEvent = function (event, params) {
33
-
34
- params = params || { bubbles: false, cancelable: false, detail: undefined };
35
-
36
- var evt = document.createEvent('CustomEvent');
37
- evt.initCustomEvent(event, params.bubbles, params.cancelable, params.detail);
38
- return evt;
39
- };
40
-
41
- window.CustomEvent.prototype = window.Event.prototype;
42
- }
43
-
44
- // requestAnimationFrame() shim by Paul Irish
45
- window.requestAnimFrame = (function () {
46
- return window.requestAnimationFrame ||
47
- window.webkitRequestAnimationFrame ||
48
- window.mozRequestAnimationFrame ||
49
- window.oRequestAnimationFrame ||
50
- window.msRequestAnimationFrame || function (callback) {
51
- window.setTimeout(callback, 1000 / 60);
52
- };
53
- })();
54
-
55
- /**
56
- * Behaves the same as setTimeout except uses requestAnimationFrame() where possible for better performance
57
- * @param {function} fn The callback function
58
- * @param {int} delay The delay in milliseconds
59
- * @returns {object} handle to the timeout object
60
- */
61
- function requestTimeout(fn, delay) {
62
-
63
- if (!window.requestAnimationFrame && !window.webkitRequestAnimationFrame &&
64
- !(window.mozRequestAnimationFrame && window.mozCancelRequestAnimationFrame) && // Firefox 5 ships without cancel support
65
- !window.oRequestAnimationFrame && !window.msRequestAnimationFrame) return window.setTimeout(fn, delay);
66
-
67
- var start = new Date().getTime();
68
- var handle = {};
69
-
70
- var loop = function () {
71
- var current = new Date().getTime();
72
- var delta = current - start;
73
-
74
- if (delta >= delay) {
75
- fn.call();
76
- }
77
- else {
78
- handle.value = requestAnimFrame(loop);
79
- }
80
- };
81
-
82
- handle.value = requestAnimFrame(loop);
83
-
84
- return handle;
85
- }
86
-
87
- /**
88
- * Behaves the same as clearTimeout except uses cancelRequestAnimationFrame() where possible for better performance
89
- * @param {object} handle The callback function
90
- * @returns {void}
91
- */
92
- function clearRequestTimeout(handle) {
93
- if (handle) {
94
- window.cancelAnimationFrame ? window.cancelAnimationFrame(handle.value) :
95
- window.webkitCancelAnimationFrame ? window.webkitCancelAnimationFrame(handle.value) :
96
- window.webkitCancelRequestAnimationFrame ? window.webkitCancelRequestAnimationFrame(handle.value) : /* Support for legacy API */
97
- window.mozCancelRequestAnimationFrame ? window.mozCancelRequestAnimationFrame(handle.value) :
98
- window.oCancelRequestAnimationFrame ? window.oCancelRequestAnimationFrame(handle.value) :
99
- window.msCancelRequestAnimationFrame ? window.msCancelRequestAnimationFrame(handle.value) :
100
- clearTimeout(handle);
101
- }
102
- }
103
-
104
- /**
105
- * Fires the 'long-press' event on element
106
- * @param {MouseEvent|PointerEvent|TouchEvent} originalEvent The original event being fired
107
- * @returns {void}
108
- */
109
- function fireLongPressEvent(originalEvent) {
110
-
111
- clearLongPressTimer();
112
-
113
- originalEvent = unifyEvent(originalEvent);
114
-
115
- // fire the long-press event
116
- var allowClickEvent = this.dispatchEvent(new CustomEvent('long-press', {
117
- bubbles: true,
118
- cancelable: true,
119
-
120
- // custom event data (legacy)
121
- detail: {
122
- clientX: originalEvent.clientX,
123
- clientY: originalEvent.clientY,
124
- offsetX: originalEvent.offsetX,
125
- offsetY: originalEvent.offsetY,
126
- pageX: originalEvent.pageX,
127
- pageY: originalEvent.pageY
128
- },
129
-
130
- // add coordinate data that would typically acompany a touch/click event
131
- clientX: originalEvent.clientX,
132
- clientY: originalEvent.clientY,
133
- offsetX: originalEvent.offsetX,
134
- offsetY: originalEvent.offsetY,
135
- pageX: originalEvent.pageX,
136
- pageY: originalEvent.pageY,
137
- screenX: originalEvent.screenX,
138
- screenY: originalEvent.screenY
139
- }));
140
-
141
- if (!allowClickEvent) {
142
- // suppress the next click event if e.preventDefault() was called in long-press handler
143
- document.addEventListener('click', function suppressEvent(e) {
144
- document.removeEventListener('click', suppressEvent, true);
145
- cancelEvent(e);
146
- }, true);
147
- }
148
- }
149
-
150
- /**
151
- * consolidates mouse, touch, and Pointer events
152
- * @param {MouseEvent|PointerEvent|TouchEvent} e The original event being fired
153
- * @returns {MouseEvent|PointerEvent|Touch}
154
- */
155
- function unifyEvent(e) {
156
- if (e.changedTouches !== undefined) {
157
- return e.changedTouches[0];
158
- }
159
- return e;
160
- }
161
-
162
- /**
163
- * method responsible for starting the long press timer
164
- * @param {event} e - event object
165
- * @returns {void}
166
- */
167
- function startLongPressTimer(e) {
168
-
169
- clearLongPressTimer();
170
-
171
- var el = e.target;
172
-
173
- // get delay from html attribute if it exists, otherwise default to 1500
174
- var longPressDelayInMs = parseInt(getNearestAttribute(el, 'data-long-press-delay', '1500'), 10); // default 1500
175
-
176
- // start the timer
177
- timer = requestTimeout(fireLongPressEvent.bind(el, e), longPressDelayInMs);
178
- }
179
-
180
- /**
181
- * method responsible for clearing a pending long press timer
182
- * @param {event} e - event object
183
- * @returns {void}
184
- */
185
- function clearLongPressTimer(e) {
186
- clearRequestTimeout(timer);
187
- timer = null;
188
- }
189
-
190
- /**
191
- * Cancels the current event
192
- * @param {object} e - browser event object
193
- * @returns {void}
194
- */
195
- function cancelEvent(e) {
196
- e.stopImmediatePropagation();
197
- e.preventDefault();
198
- e.stopPropagation();
199
- }
200
-
201
- /**
202
- * Starts the timer on mouse down and logs current position
203
- * @param {object} e - browser event object
204
- * @returns {void}
205
- */
206
- function mouseDownHandler(e) {
207
- startX = e.clientX;
208
- startY = e.clientY;
209
- startLongPressTimer(e);
210
- }
211
-
212
- /**
213
- * If the mouse moves n pixels during long-press, cancel the timer
214
- * @param {object} e - browser event object
215
- * @returns {void}
216
- */
217
- function mouseMoveHandler(e) {
218
-
219
- // calculate total number of pixels the pointer has moved
220
- var diffX = Math.abs(startX - e.clientX);
221
- var diffY = Math.abs(startY - e.clientY);
222
-
223
- // if pointer has moved more than allowed, cancel the long-press timer and therefore the event
224
- if (diffX >= maxDiffX || diffY >= maxDiffY) {
225
- clearLongPressTimer();
226
- }
227
- }
228
-
229
- /**
230
- * Gets attribute off HTML element or nearest parent
231
- * @param {object} el - HTML element to retrieve attribute from
232
- * @param {string} attributeName - name of the attribute
233
- * @param {any} defaultValue - default value to return if no match found
234
- * @returns {any} attribute value or defaultValue
235
- */
236
- function getNearestAttribute(el, attributeName, defaultValue) {
237
-
238
- // walk up the dom tree looking for data-action and data-trigger
239
- while (el && el !== document.documentElement) {
240
-
241
- var attributeValue = el.getAttribute(attributeName);
242
-
243
- if (attributeValue) {
244
- return attributeValue;
245
- }
246
-
247
- el = el.parentNode;
248
- }
249
-
250
- return defaultValue;
251
- }
252
-
253
- // hook events that clear a pending long press event
254
- document.addEventListener(mouseUp, clearLongPressTimer, true);
255
- document.addEventListener(mouseLeave, clearLongPressTimer, true);
256
- document.addEventListener(mouseMove, mouseMoveHandler, true);
257
- document.addEventListener('wheel', clearLongPressTimer, true);
258
- document.addEventListener('scroll', clearLongPressTimer, true);
259
- document.addEventListener('contextmenu', clearLongPressTimer, true);
260
-
261
- // hook events that can trigger a long press event
262
- document.addEventListener(mouseDown, mouseDownHandler, true); // <- start
263
-
264
- }(window, document));
8
+ !function(e,n){var t=null,o="PointerEvent"in e||e.navigator&&"msPointerEnabled"in e.navigator,i="ontouchstart"in e||navigator.MaxTouchPoints>0||navigator.msMaxTouchPoints>0,u=o?"pointerdown":i?"touchstart":"mousedown",r=o?"pointerup":i?"touchend":"mouseup",a=o?"pointermove":i?"touchmove":"mousemove",c=o?"pointerleave":i?"touchleave":"mouseleave",l=0,f=0;function s(e){var t;m(),e=void 0!==(t=e).changedTouches?t.changedTouches[0]:t,this.dispatchEvent(new CustomEvent("long-press",{bubbles:!0,cancelable:!0,detail:{clientX:e.clientX,clientY:e.clientY,offsetX:e.offsetX,offsetY:e.offsetY,pageX:e.pageX,pageY:e.pageY},clientX:e.clientX,clientY:e.clientY,offsetX:e.offsetX,offsetY:e.offsetY,pageX:e.pageX,pageY:e.pageY,screenX:e.screenX,screenY:e.screenY}))||n.addEventListener("click",(function e(t){n.removeEventListener("click",e,!0),function(e){e.stopImmediatePropagation(),e.preventDefault(),e.stopPropagation()}(t)}),!0)}function v(o){m();var i=o.target,u=parseInt(function(e){for(;e&&e!==n.documentElement;){var t=e.getAttribute("data-long-press-delay");if(t)return t;e=e.parentNode}return"1500"}(i),10);t=function(n,t){if(!(e.requestAnimationFrame||e.webkitRequestAnimationFrame||e.mozRequestAnimationFrame&&e.mozCancelRequestAnimationFrame||e.oRequestAnimationFrame||e.msRequestAnimationFrame))return e.setTimeout(n,t);var o=(new Date).getTime(),i={},u=function(){(new Date).getTime()-o>=t?n.call():i.value=requestAnimFrame(u)};return i.value=requestAnimFrame(u),i}(s.bind(i,o),u)}function m(){var n;(n=t)&&(e.cancelAnimationFrame?e.cancelAnimationFrame(n.value):e.webkitCancelAnimationFrame?e.webkitCancelAnimationFrame(n.value):e.webkitCancelRequestAnimationFrame?e.webkitCancelRequestAnimationFrame(n.value):e.mozCancelRequestAnimationFrame?e.mozCancelRequestAnimationFrame(n.value):e.oCancelRequestAnimationFrame?e.oCancelRequestAnimationFrame(n.value):e.msCancelRequestAnimationFrame?e.msCancelRequestAnimationFrame(n.value):clearTimeout(n)),t=null}"function"!=typeof e.CustomEvent&&(e.CustomEvent=function(e,t){t=t||{bubbles:!1,cancelable:!1,detail:void 0};var o=n.createEvent("CustomEvent");return o.initCustomEvent(e,t.bubbles,t.cancelable,t.detail),o},e.CustomEvent.prototype=e.Event.prototype),e.requestAnimFrame=e.requestAnimationFrame||e.webkitRequestAnimationFrame||e.mozRequestAnimationFrame||e.oRequestAnimationFrame||e.msRequestAnimationFrame||function(n){e.setTimeout(n,1e3/60)},n.addEventListener(r,m,!0),n.addEventListener(c,m,!0),n.addEventListener(a,(function(e){var n=Math.abs(l-e.clientX),t=Math.abs(f-e.clientY);(n>=10||t>=10)&&m()}),!0),n.addEventListener("wheel",m,!0),n.addEventListener("scroll",m,!0),n.addEventListener("contextmenu",m,!0),n.addEventListener(u,(function(e){l=e.clientX,f=e.clientY,v(e)}),!0)}(window,document);
@@ -0,0 +1 @@
1
+ const e={linear:"linear",ease:"ease","ease-in":"ease-in","ease-out":"ease-out","ease-in-out":"ease-in-out",headerEase:{x1:.8,y1:.2,x2:.8,y2:.7}};function n(n){const s="string"==typeof n?e[n]??n:n;if("string"==typeof s)return s;const{x1:t,y1:a,x2:i,y2:r}=s;return`cubic-bezier(${t}, ${a}, ${i}, ${r})`}export{n as r}
@@ -0,0 +1 @@
1
+ import{p as e,t,H as s,h as o,a as i}from"./index.js";import{v as a}from"./p-CZvbetqX.js";import{H as l}from"./p-r4txK0AC.js";import{b as r}from"./p-B8YiQ3mz.js";import{E as c}from"./p-rEfV4v4a.js";const n=e(class extends s{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.expandedItems=new Set,this.multiple=!1}validateHeadingLevel(){r(this,"headingLevel",l),this.accordionItems.forEach((e=>{e.setAttribute("heading-level",String(this.headingLevel))}))}componentWillLoad(){this.registerAccordionItems()}componentDidLoad(){this.validateHeadingLevel()}collapseToggleHandler(e){const t=e.target,s=this.expandedItems.has(t);s?this.expandedItems.delete(t):this.expandedItems.add(t),this.multiple||s||Array.from(this.expandedItems.values()).filter((e=>e!==t)).forEach((e=>{e.toggle(!1)}))}async toggle(e){const t=this.accordionItems.find((t=>t.id===e));if(!t)throw new Error(`No post-accordion-item found with id #${e}.`);await t.toggle()}async expandAll(){this.multiple?await Promise.all(this.accordionItems.map((e=>e.toggle(!0)))):this.expandedItems.size||await this.accordionItems[0].toggle(!0)}async collapseAll(){await Promise.all(this.accordionItems.map((e=>e.toggle(!1))))}registerAccordionItems(){this.accordionItems=Array.from(this.host.querySelectorAll("post-accordion-item")),this.accordionItems.filter((e=>!e.collapsed||this.expandedItems.has(e))).forEach(((e,t)=>{this.multiple||0===t?this.expandedItems.add(e):e.setAttribute("collapsed","")}))}render(){return o(i,{key:"470d8a7646796044df8f9cf1ebfc113e5c8db960","data-version":a},o("div",{key:"360ad1fe885dbb3c61a5c026ea253e7fba81ef9e",class:"accordion"},o("slot",{key:"9e14d7906cba560a848986787159f56c961c78db",onSlotchange:()=>this.registerAccordionItems()})))}get host(){return this}static get watchers(){return{headingLevel:[{validateHeadingLevel:0}]}}static get style(){return":host{display:block;border-block-start:var(--post-device-border-width-default) var(--post-core-border-style-solid) var(--post-scheme-color-interactive-primary-enabled-stroke)}"}},[257,"post-accordion",{headingLevel:[514,"heading-level"],multiple:[4],toggle:[64],expandAll:[64],collapseAll:[64]},[[0,"postToggle","collapseToggleHandler"]],{headingLevel:[{validateHeadingLevel:0}]}]);function d(){"undefined"!=typeof customElements&&["post-accordion"].forEach((e=>{"post-accordion"===e&&(customElements.get(t(e))||customElements.define(t(e),n))}))}(function(e,t,s,o){var i,a=arguments.length,l=a<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,s):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)l=Reflect.decorate(e,t,s,o);else for(var r=e.length-1;r>=0;r--)(i=e[r])&&(l=(a<3?i(l):a>3?i(t,s,l):i(t,s))||l);a>3&&l&&Object.defineProperty(t,s,l)})([c("post-accordion-item")],n.prototype,"collapseToggleHandler",null),d();export{n as P,d}
@@ -0,0 +1 @@
1
+ import{r as i}from"./p-CoDiS_Ik.js";const n={duration:200,easing:"linear",fill:"forwards"};function r(r,o,t={}){if(!r)return;const a=[{opacity:"0"},{opacity:"1"}];return function(r,o,t={}){const{duration:a,easing:s,fill:f}={...n,...t};return r.animate(o,{duration:a,easing:i(s),fill:f})}(r,"in"===o?a:[...a].reverse(),t)}export{r as f}
@@ -0,0 +1 @@
1
+ import{p as t,H as e,c as n,h as o,a as r,t as i}from"./index.js";import{I as s}from"./p-FxUVQ4Tx.js";import{d as a,e as c}from"./p-B8YiQ3mz.js";import{v as p}from"./p-CZvbetqX.js";const l=["top","right","bottom","left","top-start","top-end","right-start","right-end","bottom-start","bottom-end","left-start","left-end"],u=Math.min,f=Math.max,h=Math.round,d=Math.floor,m=t=>({x:t,y:t}),g={left:"right",right:"left",bottom:"top",top:"bottom"},v={start:"end",end:"start"};function w(t,e,n){return f(t,u(e,n))}function x(t,e){return"function"==typeof t?t(e):t}function y(t){return t.split("-")[0]}function b(t){return t.split("-")[1]}function S(t){return"x"===t?"y":"x"}function E(t){return"y"===t?"height":"width"}const k=new Set(["top","bottom"]);function T(t){return k.has(y(t))?"y":"x"}function M(t){return S(T(t))}function A(t){return t.replace(/start|end/g,(t=>v[t]))}const O=["left","right"],H=["right","left"],L=["top","bottom"],$=["bottom","top"];function D(t){return t.replace(/left|right|bottom|top/g,(t=>g[t]))}function z(t){return"number"!=typeof t?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(t):{top:t,right:t,bottom:t,left:t}}function F(t){const{x:e,y:n,width:o,height:r}=t;return{width:o,height:r,top:n,left:e,right:e+o,bottom:n+r,x:e,y:n}}function P(t,e,n){let{reference:o,floating:r}=t;const i=T(e),s=M(e),a=E(s),c=y(e),p="y"===i,l=o.x+o.width/2-r.width/2,u=o.y+o.height/2-r.height/2,f=o[a]/2-r[a]/2;let h;switch(c){case"top":h={x:l,y:o.y-r.height};break;case"bottom":h={x:l,y:o.y+o.height};break;case"right":h={x:o.x+o.width,y:u};break;case"left":h={x:o.x-r.width,y:u};break;default:h={x:o.x,y:o.y}}switch(b(e)){case"start":h[s]-=f*(n&&p?-1:1);break;case"end":h[s]+=f*(n&&p?-1:1)}return h}async function C(t,e){var n;void 0===e&&(e={});const{x:o,y:r,platform:i,rects:s,elements:a,strategy:c}=t,{boundary:p="clippingAncestors",rootBoundary:l="viewport",elementContext:u="floating",altBoundary:f=!1,padding:h=0}=x(e,t),d=z(h),m=a[f?"floating"===u?"reference":"floating":u],g=F(await i.getClippingRect({element:null==(n=await(null==i.isElement?void 0:i.isElement(m)))||n?m:m.contextElement||await(null==i.getDocumentElement?void 0:i.getDocumentElement(a.floating)),boundary:p,rootBoundary:l,strategy:c})),v="floating"===u?{x:o,y:r,width:s.floating.width,height:s.floating.height}:s.reference,w=await(null==i.getOffsetParent?void 0:i.getOffsetParent(a.floating)),y=await(null==i.isElement?void 0:i.isElement(w))&&await(null==i.getScale?void 0:i.getScale(w))||{x:1,y:1},b=F(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:v,offsetParent:w,strategy:c}):v);return{top:(g.top-b.top+d.top)/y.y,bottom:(b.bottom-g.bottom+d.bottom)/y.y,left:(g.left-b.left+d.left)/y.x,right:(b.right-g.right+d.right)/y.x}}function R(t){const e=u(...t.map((t=>t.left))),n=u(...t.map((t=>t.top)));return{x:e,y:n,width:f(...t.map((t=>t.right)))-e,height:f(...t.map((t=>t.bottom)))-n}}const j=new Set(["left","top"]);function W(){return"undefined"!=typeof window}function B(t){return I(t)?(t.nodeName||"").toLowerCase():"#document"}function q(t){var e;return(null==t||null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function G(t){var e;return null==(e=(I(t)?t.ownerDocument:t.document)||window.document)?void 0:e.documentElement}function I(t){return!!W()&&(t instanceof Node||t instanceof q(t).Node)}function N(t){return!!W()&&(t instanceof Element||t instanceof q(t).Element)}function Q(t){return!!W()&&(t instanceof HTMLElement||t instanceof q(t).HTMLElement)}function V(t){return!(!W()||"undefined"==typeof ShadowRoot)&&(t instanceof ShadowRoot||t instanceof q(t).ShadowRoot)}const X=new Set(["inline","contents"]);function Y(t){const{overflow:e,overflowX:n,overflowY:o,display:r}=st(t);return/auto|scroll|overlay|hidden|clip/.test(e+o+n)&&!X.has(r)}const U=new Set(["table","td","th"]);function Z(t){return U.has(B(t))}const _=[":popover-open",":modal"];function J(t){return _.some((e=>{try{return t.matches(e)}catch(t){return!1}}))}const K=["transform","translate","scale","rotate","perspective"],tt=["transform","translate","scale","rotate","perspective","filter"],et=["paint","layout","strict","content"];function nt(t){const e=ot(),n=N(t)?st(t):t;return K.some((t=>!!n[t]&&"none"!==n[t]))||!!n.containerType&&"normal"!==n.containerType||!e&&!!n.backdropFilter&&"none"!==n.backdropFilter||!e&&!!n.filter&&"none"!==n.filter||tt.some((t=>(n.willChange||"").includes(t)))||et.some((t=>(n.contain||"").includes(t)))}function ot(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}const rt=new Set(["html","body","#document"]);function it(t){return rt.has(B(t))}function st(t){return q(t).getComputedStyle(t)}function at(t){return N(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function ct(t){if("html"===B(t))return t;const e=t.assignedSlot||t.parentNode||V(t)&&t.host||G(t);return V(e)?e.host:e}function pt(t){const e=ct(t);return it(e)?t.ownerDocument?t.ownerDocument.body:t.body:Q(e)&&Y(e)?e:pt(e)}function lt(t,e,n){var o;void 0===e&&(e=[]),void 0===n&&(n=!0);const r=pt(t),i=r===(null==(o=t.ownerDocument)?void 0:o.body),s=q(r);if(i){const t=ut(s);return e.concat(s,s.visualViewport||[],Y(r)?r:[],t&&n?lt(t):[])}return e.concat(r,lt(r,[],n))}function ut(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function ft(t){const e=st(t);let n=parseFloat(e.width)||0,o=parseFloat(e.height)||0;const r=Q(t),i=r?t.offsetWidth:n,s=r?t.offsetHeight:o,a=h(n)!==i||h(o)!==s;return a&&(n=i,o=s),{width:n,height:o,$:a}}function ht(t){return N(t)?t:t.contextElement}function dt(t){const e=ht(t);if(!Q(e))return m(1);const n=e.getBoundingClientRect(),{width:o,height:r,$:i}=ft(e);let s=(i?h(n.width):n.width)/o,a=(i?h(n.height):n.height)/r;return s&&Number.isFinite(s)||(s=1),a&&Number.isFinite(a)||(a=1),{x:s,y:a}}const mt=m(0);function gt(t){const e=q(t);return ot()&&e.visualViewport?{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}:mt}function vt(t,e,n,o){void 0===e&&(e=!1),void 0===n&&(n=!1);const r=t.getBoundingClientRect(),i=ht(t);let s=m(1);e&&(o?N(o)&&(s=dt(o)):s=dt(t));const a=function(t,e,n){return void 0===e&&(e=!1),!(!n||e&&n!==q(t))&&e}(i,n,o)?gt(i):m(0);let c=(r.left+a.x)/s.x,p=(r.top+a.y)/s.y,l=r.width/s.x,u=r.height/s.y;if(i){const t=q(i),e=o&&N(o)?q(o):o;let n=t,r=ut(n);for(;r&&o&&e!==n;){const t=dt(r),e=r.getBoundingClientRect(),o=st(r),i=e.left+(r.clientLeft+parseFloat(o.paddingLeft))*t.x,s=e.top+(r.clientTop+parseFloat(o.paddingTop))*t.y;c*=t.x,p*=t.y,l*=t.x,u*=t.y,c+=i,p+=s,n=q(r),r=ut(n)}}return F({width:l,height:u,x:c,y:p})}function wt(t,e){const n=at(t).scrollLeft;return e?e.left+n:vt(G(t)).left+n}function xt(t,e){const n=t.getBoundingClientRect();return{x:n.left+e.scrollLeft-wt(t,n),y:n.top+e.scrollTop}}const yt=new Set(["absolute","fixed"]);function bt(t,e,n){let o;if("viewport"===e)o=function(t,e){const n=q(t),o=G(t),r=n.visualViewport;let i=o.clientWidth,s=o.clientHeight,a=0,c=0;if(r){i=r.width,s=r.height;const t=ot();(!t||t&&"fixed"===e)&&(a=r.offsetLeft,c=r.offsetTop)}const p=wt(o);if(p<=0){const t=o.ownerDocument,e=t.body,n=getComputedStyle(e),r="CSS1Compat"===t.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,s=Math.abs(o.clientWidth-e.clientWidth-r);s<=25&&(i-=s)}else p<=25&&(i+=p);return{width:i,height:s,x:a,y:c}}(t,n);else if("document"===e)o=function(t){const e=G(t),n=at(t),o=t.ownerDocument.body,r=f(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),i=f(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight);let s=-n.scrollLeft+wt(t);const a=-n.scrollTop;return"rtl"===st(o).direction&&(s+=f(e.clientWidth,o.clientWidth)-r),{width:r,height:i,x:s,y:a}}(G(t));else if(N(e))o=function(t,e){const n=vt(t,!0,"fixed"===e),o=n.top+t.clientTop,r=n.left+t.clientLeft,i=Q(t)?dt(t):m(1);return{width:t.clientWidth*i.x,height:t.clientHeight*i.y,x:r*i.x,y:o*i.y}}(e,n);else{const n=gt(t);o={x:e.x-n.x,y:e.y-n.y,width:e.width,height:e.height}}return F(o)}function St(t,e){const n=ct(t);return!(n===e||!N(n)||it(n))&&("fixed"===st(n).position||St(n,e))}function Et(t,e,n){const o=Q(e),r=G(e),i="fixed"===n,s=vt(t,!0,i,e);let a={scrollLeft:0,scrollTop:0};const c=m(0);function p(){c.x=wt(r)}if(o||!o&&!i)if(("body"!==B(e)||Y(r))&&(a=at(e)),o){const t=vt(e,!0,i,e);c.x=t.x+e.clientLeft,c.y=t.y+e.clientTop}else r&&p();i&&!o&&r&&p();const l=!r||o||i?m(0):xt(r,a);return{x:s.left+a.scrollLeft-c.x-l.x,y:s.top+a.scrollTop-c.y-l.y,width:s.width,height:s.height}}function kt(t){return"static"===st(t).position}function Tt(t,e){if(!Q(t)||"fixed"===st(t).position)return null;if(e)return e(t);let n=t.offsetParent;return G(t)===n&&(n=n.ownerDocument.body),n}function Mt(t,e){const n=q(t);if(J(t))return n;if(!Q(t)){let e=ct(t);for(;e&&!it(e);){if(N(e)&&!kt(e))return e;e=ct(e)}return n}let o=Tt(t,e);for(;o&&Z(o)&&kt(o);)o=Tt(o,e);return o&&it(o)&&kt(o)&&!nt(o)?n:o||function(t){let e=ct(t);for(;Q(e)&&!it(e);){if(nt(e))return e;if(J(e))return null;e=ct(e)}return null}(t)||n}const At={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{elements:e,rect:n,offsetParent:o,strategy:r}=t;const i="fixed"===r,s=G(o),a=!!e&&J(e.floating);if(o===s||a&&i)return n;let c={scrollLeft:0,scrollTop:0},p=m(1);const l=m(0),u=Q(o);if((u||!u&&!i)&&(("body"!==B(o)||Y(s))&&(c=at(o)),Q(o))){const t=vt(o);p=dt(o),l.x=t.x+o.clientLeft,l.y=t.y+o.clientTop}const f=!s||u||i?m(0):xt(s,c);return{width:n.width*p.x,height:n.height*p.y,x:n.x*p.x-c.scrollLeft*p.x+l.x+f.x,y:n.y*p.y-c.scrollTop*p.y+l.y+f.y}},getDocumentElement:G,getClippingRect:function(t){let{element:e,boundary:n,rootBoundary:o,strategy:r}=t;const i=[..."clippingAncestors"===n?J(e)?[]:function(t,e){const n=e.get(t);if(n)return n;let o=lt(t,[],!1).filter((t=>N(t)&&"body"!==B(t))),r=null;const i="fixed"===st(t).position;let s=i?ct(t):t;for(;N(s)&&!it(s);){const e=st(s),n=nt(s);n||"fixed"!==e.position||(r=null),(i?!n&&!r:!n&&"static"===e.position&&r&&yt.has(r.position)||Y(s)&&!n&&St(t,s))?o=o.filter((t=>t!==s)):r=e,s=ct(s)}return e.set(t,o),o}(e,this._c):[].concat(n),o],s=i.reduce(((t,n)=>{const o=bt(e,n,r);return t.top=f(o.top,t.top),t.right=u(o.right,t.right),t.bottom=u(o.bottom,t.bottom),t.left=f(o.left,t.left),t}),bt(e,i[0],r));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:Mt,getElementRects:async function(t){const e=this.getOffsetParent||Mt,n=this.getDimensions,o=await n(t.floating);return{reference:Et(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}},getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){const{width:e,height:n}=ft(t);return{width:e,height:n}},getScale:dt,isElement:N,isRTL:function(t){return"rtl"===st(t).direction}};function Ot(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}const Ht=function(t){return void 0===t&&(t=0),{name:"offset",options:t,async fn(e){var n,o;const{x:r,y:i,placement:s,middlewareData:a}=e,c=await async function(t,e){const{placement:n,platform:o,elements:r}=t,i=await(null==o.isRTL?void 0:o.isRTL(r.floating)),s=y(n),a=b(n),c="y"===T(n),p=j.has(s)?-1:1,l=i&&c?-1:1,u=x(e,t);let{mainAxis:f,crossAxis:h,alignmentAxis:d}="number"==typeof u?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return a&&"number"==typeof d&&(h="end"===a?-1*d:d),c?{x:h*l,y:f*p}:{x:f*p,y:h*l}}(e,t);return s===(null==(n=a.offset)?void 0:n.placement)&&null!=(o=a.arrow)&&o.alignmentOffset?{}:{x:r+c.x,y:i+c.y,data:{...c,placement:s}}}}},Lt=function(t){return void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:o,placement:r}=e,{mainAxis:i=!0,crossAxis:s=!1,limiter:a={fn:t=>{let{x:e,y:n}=t;return{x:e,y:n}}},...c}=x(t,e),p={x:n,y:o},l=await C(e,c),u=T(y(r)),f=S(u);let h=p[f],d=p[u];i&&(h=w(h+l["y"===f?"top":"left"],h,h-l["y"===f?"bottom":"right"])),s&&(d=w(d+l["y"===u?"top":"left"],d,d-l["y"===u?"bottom":"right"]));const m=a.fn({...e,[f]:h,[u]:d});return{...m,data:{x:m.x-n,y:m.y-o,enabled:{[f]:i,[u]:s}}}}}},$t=function(t){return void 0===t&&(t={}),{name:"flip",options:t,async fn(e){var n,o;const{placement:r,middlewareData:i,rects:s,initialPlacement:a,platform:c,elements:p}=e,{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:f,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:d="none",flipAlignment:m=!0,...g}=x(t,e);if(null!=(n=i.arrow)&&n.alignmentOffset)return{};const v=y(r),w=T(a),S=y(a)===a,k=await(null==c.isRTL?void 0:c.isRTL(p.floating)),z=f||(S||!m?[D(a)]:function(t){const e=D(t);return[A(t),e,A(e)]}(a)),F="none"!==d;!f&&F&&z.push(...function(t,e,n,o){const r=b(t);let i=function(t,e,n){switch(t){case"top":case"bottom":return n?e?H:O:e?O:H;case"left":case"right":return e?L:$;default:return[]}}(y(t),"start"===n,o);return r&&(i=i.map((t=>t+"-"+r)),e&&(i=i.concat(i.map(A)))),i}(a,m,d,k));const P=[a,...z],R=await C(e,g),j=[];let W=(null==(o=i.flip)?void 0:o.overflows)||[];if(l&&j.push(R[v]),u){const t=function(t,e,n){void 0===n&&(n=!1);const o=b(t),r=M(t),i=E(r);let s="x"===r?o===(n?"end":"start")?"right":"left":"start"===o?"bottom":"top";return e.reference[i]>e.floating[i]&&(s=D(s)),[s,D(s)]}(r,s,k);j.push(R[t[0]],R[t[1]])}if(W=[...W,{placement:r,overflows:j}],!j.every((t=>t<=0))){var B,q;const t=((null==(B=i.flip)?void 0:B.index)||0)+1,e=P[t];if(e&&("alignment"!==u||w===T(e)||W.every((t=>T(t.placement)!==w||t.overflows[0]>0))))return{data:{index:t,overflows:W},reset:{placement:e}};let n=null==(q=W.filter((t=>t.overflows[0]<=0)).sort(((t,e)=>t.overflows[1]-e.overflows[1]))[0])?void 0:q.placement;if(!n)switch(h){case"bestFit":{var G;const t=null==(G=W.filter((t=>{if(F){const e=T(t.placement);return e===w||"y"===e}return!0})).map((t=>[t.placement,t.overflows.filter((t=>t>0)).reduce(((t,e)=>t+e),0)])).sort(((t,e)=>t[1]-e[1]))[0])?void 0:G[0];t&&(n=t);break}case"initialPlacement":n=a}if(r!==n)return{reset:{placement:n}}}return{}}}},Dt=function(t){return void 0===t&&(t={}),{name:"size",options:t,async fn(e){var n,o;const{placement:r,rects:i,platform:s,elements:a}=e,{apply:c=()=>{},...p}=x(t,e),l=await C(e,p),h=y(r),d=b(r),m="y"===T(r),{width:g,height:v}=i.floating;let w,S;"top"===h||"bottom"===h?(w=h,S=d===(await(null==s.isRTL?void 0:s.isRTL(a.floating))?"start":"end")?"left":"right"):(S=h,w="end"===d?"top":"bottom");const E=v-l.top-l.bottom,k=g-l.left-l.right;let M=u(v-l[w],E),A=u(g-l[S],k);if(null!=(n=e.middlewareData.shift)&&n.enabled.x&&(A=k),null!=(o=e.middlewareData.shift)&&o.enabled.y&&(M=E),!e.middlewareData.shift&&!d){const t=f(l.left,0),e=f(l.right,0),n=f(l.top,0),o=f(l.bottom,0);m?A=g-2*(0!==t||0!==e?t+e:f(l.left,l.right)):M=v-2*(0!==n||0!==o?n+o:f(l.top,l.bottom))}await c({...e,availableWidth:A,availableHeight:M});const O=await s.getDimensions(a.floating);return g!==O.width||v!==O.height?{reset:{rects:!0}}:{}}}},zt=function(t){return void 0===t&&(t={}),{options:t,fn(e){const{x:n,y:o,placement:r,rects:i,middlewareData:s}=e,{offset:a=0,mainAxis:c=!0,crossAxis:p=!0}=x(t,e),l={x:n,y:o},u=T(r),f=S(u);let h=l[f],d=l[u];const m=x(a,e),g="number"==typeof m?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(c){const t="y"===f?"height":"width",e=i.reference[f]-i.floating[t]+g.mainAxis,n=i.reference[f]+i.reference[t]-g.mainAxis;h<e?h=e:h>n&&(h=n)}if(p){var v,w;const t="y"===f?"width":"height",e=j.has(y(r)),n=i.reference[u]-i.floating[t]+(e&&(null==(v=s.offset)?void 0:v[u])||0)+(e?0:g.crossAxis),o=i.reference[u]+i.reference[t]+(e?0:(null==(w=s.offset)?void 0:w[u])||0)-(e?g.crossAxis:0);d<n?d=n:d>o&&(d=o)}return{[f]:h,[u]:d}}}};var Ft=class extends Event{oldState;newState;constructor(t,{oldState:e="",newState:n="",...o}={}){super(t,o),this.oldState=String(e||""),this.newState=String(n||"")}},Pt=new WeakMap;function Ct(t,e,n){Pt.set(t,setTimeout((()=>{Pt.has(t)&&t.dispatchEvent(new Ft("toggle",{cancelable:!1,oldState:e,newState:n}))}),0))}var Rt=globalThis.ShadowRoot||function(){},jt=globalThis.HTMLDialogElement||function(){},Wt=new WeakMap,Bt=new WeakMap,qt=new WeakMap,Gt=new WeakMap;function It(t){return Gt.get(t)||"hidden"}var Nt=new WeakMap;function Qt(t){return[...t].pop()}function Vt(t,e){return!("auto"!==t.popover&&"manual"!==t.popover&&"hint"!==t.popover||!t.isConnected||e&&"showing"!==It(t)||!e&&"hidden"!==It(t)||t instanceof jt&&t.hasAttribute("open")||document.fullscreenElement===t)}function Xt(t){if(!t)return 0;const e=Bt.get(document)||new Set,n=qt.get(document)||new Set;return n.has(t)?[...n].indexOf(t)+e.size+1:e.has(t)?[...e].indexOf(t)+1:0}function Yt(t){let e;const n=qt.get(t)||new Set,o=Bt.get(t)||new Set,r=n.size>0?n:o.size>0?o:null;return r?(e=Qt(r),e.isConnected?e:(r.delete(e),Yt(t))):null}function Ut(t){for(const e of t||[]){if(e.isConnected)return e;t.delete(e)}return null}function Zt(t){return"function"==typeof t.getRootNode?t.getRootNode():t.parentNode?Zt(t.parentNode):t}function _t(t){for(;t;){if(t instanceof HTMLElement&&"auto"===t.popover&&"showing"===Gt.get(t))return t;if((t=t instanceof Element&&t.assignedSlot||t.parentElement||Zt(t))instanceof Rt&&(t=t.host),t instanceof Document)return}}function Jt(t,e){const n=new Map;let o=0;for(const t of e||[])n.set(t,o),o+=1;n.set(t,o),o+=1;let r=null;return function(e){if(!e)return;let o=!1,i=null,s=null;for(;!o;){if(i=_t(e)||null,null===i)return;if(!n.has(i))return;"hint"!==t.popover&&"auto"!==i.popover||(o=!0),o||(e=i.parentElement)}s=n.get(i),(null===r||n.get(r)<s)&&(r=i)}(t.parentElement||Zt(t)),r}function Kt(t){return!(t.hidden||t instanceof Rt||(t instanceof HTMLButtonElement||t instanceof HTMLInputElement||t instanceof HTMLSelectElement||t instanceof HTMLTextAreaElement||t instanceof HTMLOptGroupElement||t instanceof HTMLOptionElement||t instanceof HTMLFieldSetElement)&&t.disabled||t instanceof HTMLInputElement&&"hidden"===t.type||t instanceof HTMLAnchorElement&&""===t.href||"number"!=typeof t.tabIndex||-1===t.tabIndex)}var te=new WeakMap;function ee(t){if(!Vt(t,!1))return;const e=t.ownerDocument;if(!t.dispatchEvent(new Ft("beforetoggle",{cancelable:!0,oldState:"closed",newState:"open"})))return;if(!Vt(t,!1))return;let n=!1;const o=t.popover;let r=null;const i=Jt(t,Bt.get(e)||new Set),s=Jt(t,qt.get(e)||new Set);if("auto"===o&&(oe(qt.get(e)||new Set,n,!0),ie(i||e,n,!0),r="auto"),"hint"===o&&(s?(ie(s,n,!0),r="hint"):(oe(qt.get(e)||new Set,n,!0),i?(ie(i,n,!0),r="auto"):r="hint")),"auto"===o||"hint"===o){if(o!==t.popover||!Vt(t,!1))return;Yt(e)||(n=!0),"auto"===r?(Bt.has(e)||Bt.set(e,new Set),Bt.get(e).add(t)):"hint"===r&&(qt.has(e)||qt.set(e,new Set),qt.get(e).add(t))}te.delete(t);const a=e.activeElement;var c;t.classList.add(":popover-open"),Gt.set(t,"showing"),Wt.has(e)||Wt.set(e,new Set),Wt.get(e).add(t),pe(Nt.get(t),!0),c=t,function(t){if(t.shadowRoot&&!0!==t.shadowRoot.delegatesFocus)return null;let e=t;e.shadowRoot&&(e=e.shadowRoot);let n=e.querySelector("[autofocus]");if(n)return n;{const t=e.querySelectorAll("slot");for(const e of t){const t=e.assignedElements({flatten:!0});for(const e of t){if(e.hasAttribute("autofocus"))return e;if(n=e.querySelector("[autofocus]"),n)return n}}}const o=t.ownerDocument.createTreeWalker(e,NodeFilter.SHOW_ELEMENT);let r=o.currentNode;for(;r;){if(Kt(r))return r;r=o.nextNode()}}(c)?.focus(),n&&a&&"auto"===t.popover&&te.set(t,a),Ct(t,"closed","open")}function ne(t,e=!1,n=!1){if(!Vt(t,!0))return;const o=t.ownerDocument;if(["auto","hint"].includes(t.popover)&&(ie(t,e,n),!Vt(t,!0)))return;const r=Bt.get(o)||new Set,i=r.has(t)&&Qt(r)===t;if(pe(Nt.get(t),!1),Nt.delete(t),n&&(t.dispatchEvent(new Ft("beforetoggle",{oldState:"open",newState:"closed"})),i&&Qt(r)!==t&&ie(t,e,n),!Vt(t,!0)))return;Wt.get(o)?.delete(t),r.delete(t),qt.get(o)?.delete(t),t.classList.remove(":popover-open"),Gt.set(t,"hidden"),n&&Ct(t,"open","closed");const s=te.get(t);s&&(te.delete(t),e&&s.focus())}function oe(t,e=!1,n=!1){let o=Ut(t);for(;o;)ne(o,e,n),o=Ut(t)}function re(t,e,n,o){let r=!1,i=!1;for(;r||!i;){i=!0;let s=null,a=!1;for(const n of e)if(n===t)a=!0;else if(a){s=n;break}if(!s)return;for(;"showing"===It(s)&&e.size;)ne(Qt(e),n,o);e.has(t)&&Qt(e)!==t&&(r=!0),r&&(o=!1)}}function ie(t,e,n){const o=t.ownerDocument||t;if(t instanceof Document)return function(t,e=!1,n=!1){let o=Yt(t);for(;o;)ne(o,e,n),o=Yt(t)}(o,e,n);qt.get(o)?.has(t)?re(t,qt.get(o),e,n):(oe(qt.get(o)||new Set,e,n),Bt.get(o)?.has(t)&&re(t,Bt.get(o),e,n))}var se=new WeakMap;function ae(t){if(!t.isTrusted)return;const e=t.composedPath()[0];if(!e)return;const n=e.ownerDocument;if(!Yt(n))return;const o=function(t){const e=_t(t),n=function(t){for(;t;){const e=t.popoverTargetElement;if(e instanceof HTMLElement)return e;if((t=t.parentElement||Zt(t))instanceof Rt&&(t=t.host),t instanceof Document)return}}(t);return Xt(e)>Xt(n)?e:n}(e);if(o&&"pointerdown"===t.type)se.set(n,o);else if("pointerup"===t.type){const t=se.get(n)===o;se.delete(n),t&&ie(o||n,!1,!0)}}var ce=new WeakMap;function pe(t,e=!1){if(!t)return;ce.has(t)||ce.set(t,t.getAttribute("aria-expanded"));const n=t.popoverTargetElement;if(n instanceof HTMLElement&&"auto"===n.popover)t.setAttribute("aria-expanded",String(e));else{const e=ce.get(t);e?t.setAttribute("aria-expanded",e):t.removeAttribute("aria-expanded")}}var le=globalThis.ShadowRoot||function(){};function ue(t,e,n){const o=t[e];Object.defineProperty(t,e,{value(t){return o.call(this,n(t))}})}var fe=/(^|[^\\]):popover-open\b/g;var he=null;function de(t){const e=function(){const t="function"==typeof globalThis.CSSLayerBlockRule;return`\n${t?"@layer popover-polyfill {":""}\n :where([popover]) {\n position: fixed;\n z-index: 2147483647;\n inset: 0;\n padding: 0.25em;\n width: fit-content;\n height: fit-content;\n border-width: initial;\n border-color: initial;\n border-image: initial;\n border-style: solid;\n background-color: canvas;\n color: canvastext;\n overflow: auto;\n margin: auto;\n }\n\n :where([popover]:not(.\\:popover-open)) {\n display: none;\n }\n\n :where(dialog[popover].\\:popover-open) {\n display: block;\n }\n\n :where(dialog[popover][open]) {\n display: revert;\n }\n\n :where([anchor].\\:popover-open) {\n inset: auto;\n }\n\n :where([anchor]:popover-open) {\n inset: auto;\n }\n\n @supports not (background-color: canvas) {\n :where([popover]) {\n background-color: white;\n color: black;\n }\n }\n\n @supports (width: -moz-fit-content) {\n :where([popover]) {\n width: -moz-fit-content;\n height: -moz-fit-content;\n }\n }\n\n @supports not (inset: 0) {\n :where([popover]) {\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n }\n }\n${t?"}":""}\n`}();if(null===he)try{(he=new CSSStyleSheet).replaceSync(e)}catch{he=!1}if(!1===he){const n=document.createElement("style");n.textContent=e,t instanceof Document?t.head.prepend(n):t.prepend(n)}else t.adoptedStyleSheets=[he,...t.adoptedStyleSheets]}const me={"pop-in":function(t){if(t)return t.animate([{transform:"scale(0.9)",opacity:0},{transform:"scale(1)",opacity:1}],{duration:250,easing:"ease-out",fill:"forwards"})}},ge=t(class t extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.postBeforeShow=n(this,"postBeforeShow"),this.postShow=n(this,"postShow"),this.postHide=n(this,"postHide"),this.postBeforeToggle=n(this,"postBeforeToggle"),this.postToggle=n(this,"postToggle"),this.hasOpenedOnce=!0,this.placement="top",this.edgeGap=8,this.arrow=!1,this.animation="pop-in",this.currentAnimation=null}validatePlacement(){a(this,"placement",l)}validateEdgeGap(){c(this,"edgeGap","number")}validateSafeSpace(){a(this,"safeSpace",["triangle","trapezoid"])}mouseTrackingHandler(t){this.host.style.setProperty("--post-safe-space-cursor-x",`${t.clientX}px`),this.host.style.setProperty("--post-safe-space-cursor-y",`${t.clientY}px`)}connectedCallback(){!s||"undefined"!=typeof HTMLElement&&"object"==typeof HTMLElement.prototype&&"popover"in HTMLElement.prototype||function(){if("undefined"==typeof window)return;function t(t){return t?.includes(":popover-open")&&(t=t.replace(fe,"$1.\\:popover-open")),t}window.ToggleEvent=window.ToggleEvent||Ft,ue(Document.prototype,"querySelector",t),ue(Document.prototype,"querySelectorAll",t),ue(Element.prototype,"querySelector",t),ue(Element.prototype,"querySelectorAll",t),ue(Element.prototype,"matches",t),ue(Element.prototype,"closest",t),ue(DocumentFragment.prototype,"querySelectorAll",t),Object.defineProperties(HTMLElement.prototype,{popover:{enumerable:!0,configurable:!0,get(){if(!this.hasAttribute("popover"))return null;const t=(this.getAttribute("popover")||"").toLowerCase();return""===t||"auto"==t?"auto":"hint"==t?"hint":"manual"},set(t){null===t?this.removeAttribute("popover"):this.setAttribute("popover",t)}},showPopover:{enumerable:!0,configurable:!0,value(t={}){ee(this)}},hidePopover:{enumerable:!0,configurable:!0,value(){ne(this,!0,!0)}},togglePopover:{enumerable:!0,configurable:!0,value(t={}){return"boolean"==typeof t&&(t={force:t}),"showing"===Gt.get(this)&&void 0===t.force||!1===t.force?ne(this,!0,!0):void 0!==t.force&&!0!==t.force||ee(this),"showing"===Gt.get(this)}}});const e=Element.prototype.attachShadow;e&&Object.defineProperties(Element.prototype,{attachShadow:{enumerable:!0,configurable:!0,writable:!0,value(t){const n=e.call(this,t);return de(n),n}}});const n=HTMLElement.prototype.attachInternals;n&&Object.defineProperties(HTMLElement.prototype,{attachInternals:{enumerable:!0,configurable:!0,writable:!0,value(){const t=n.call(this);return t.shadowRoot&&de(t.shadowRoot),t}}});const o=new WeakMap;function r(t){Object.defineProperties(t.prototype,{popoverTargetElement:{enumerable:!0,configurable:!0,set(t){if(null===t)this.removeAttribute("popovertarget"),o.delete(this);else{if(!(t instanceof Element))throw new TypeError("popoverTargetElement must be an element or null");this.setAttribute("popovertarget",""),o.set(this,t)}},get(){if("button"!==this.localName&&"input"!==this.localName)return null;if("input"===this.localName&&"reset"!==this.type&&"image"!==this.type&&"button"!==this.type)return null;if(this.disabled)return null;if(this.form&&"submit"===this.type)return null;const t=o.get(this);if(t&&t.isConnected)return t;if(t&&!t.isConnected)return o.delete(this),null;const e=Zt(this),n=this.getAttribute("popovertarget");return(e instanceof Document||e instanceof le)&&n&&e.getElementById(n)||null}},popoverTargetAction:{enumerable:!0,configurable:!0,get(){const t=(this.getAttribute("popovertargetaction")||"").toLowerCase();return"show"===t||"hide"===t?t:"toggle"},set(t){this.setAttribute("popovertargetaction",t)}}})}var i;r(HTMLButtonElement),r(HTMLInputElement),(i=document).addEventListener("click",(t=>{const e=t.composedPath(),n=e[0];if(!(n instanceof Element)||n?.shadowRoot)return;const o=Zt(n);if(!(o instanceof le||o instanceof Document))return;const r=e.find((t=>t.matches?.("[popovertargetaction],[popovertarget]")));return r?(function(t){const e=t.popoverTargetElement;if(!(e instanceof HTMLElement))return;const n=It(e);"show"===t.popoverTargetAction&&"showing"===n||"hide"===t.popoverTargetAction&&"hidden"===n||("showing"===n?ne(e,!0,!0):Vt(e,!1)&&(Nt.set(e,t),ee(e)))}(r),void t.preventDefault()):void 0})),i.addEventListener("keydown",(t=>{const e=t.key,n=t.target;t.defaultPrevented||!n||"Escape"!==e&&"Esc"!==e||ie(n.ownerDocument,!0,!0)})),i.addEventListener("pointerdown",ae),i.addEventListener("pointerup",ae),de(document)}()}componentDidLoad(){this.validatePlacement(),this.validateEdgeGap(),this.validateSafeSpace(),this.host.addEventListener("beforetoggle",this.handleToggle.bind(this))}disconnectedCallback(){"function"==typeof this.clearAutoUpdate&&this.clearAutoUpdate(),this.host.removeEventListener("beforetoggle",this.handleToggle.bind(this))}async show(t){this.toggleTimeoutId||(this.eventTarget=t,this.calculatePosition(),this.host.showPopover())}async hide(){this.toggleTimeoutId||(this.eventTarget=null,this.host.hidePopover(),this.postHide.emit())}async toggle(t,e){return this.eventTarget=t,this.toggleTimeoutId||(this.calculatePosition(),this.host.togglePopover(e),this.toggleTimeoutId=null),this.host.matches(":where(:popover-open, .popover-open)")}open(){const t=this.host.querySelector(".popover-content");if(this.startAutoupdates(),t){const e=me[this.animation];"function"==typeof e?this.runOpenAnimation(e,t):(this.postBeforeToggle.emit({willOpen:!0}),this.postBeforeShow.emit({first:this.hasOpenedOnce}),this.postToggle.emit({isOpen:!0}),this.postShow.emit({first:this.hasOpenedOnce}),this.hasOpenedOnce&&(this.hasOpenedOnce=!1))}this.safeSpace&&window.addEventListener("mousemove",this.mouseTrackingHandler.bind(this))}close(){"function"==typeof this.clearAutoUpdate&&this.clearAutoUpdate(),this.safeSpace&&window.removeEventListener("mousemove",this.mouseTrackingHandler.bind(this)),this.currentAnimation&&(this.currentAnimation.cancel(),this.currentAnimation=null),this.postBeforeToggle.emit({willOpen:!1}),this.postToggle.emit({isOpen:!1}),this.postHide.emit()}async runOpenAnimation(t,e){let n;try{if(n=t(e),!n)return this.postBeforeToggle.emit({willOpen:!0}),this.postBeforeShow.emit({first:this.hasOpenedOnce}),this.postToggle.emit({isOpen:!0}),void this.postShow.emit({first:this.hasOpenedOnce});this.currentAnimation=n,"running"===n.playState&&(this.postBeforeToggle.emit({willOpen:!0}),this.postBeforeShow.emit({first:this.hasOpenedOnce})),await n.finished,this.postToggle.emit({isOpen:!0}),this.postShow.emit({first:this.hasOpenedOnce}),this.hasOpenedOnce=!0}catch(t){console.warn("Animation failed or was interrupted:",t),this.postBeforeToggle.emit({willOpen:!1}),this.postBeforeShow.emit({first:this.hasOpenedOnce}),this.postToggle.emit({isOpen:!1})}finally{this.currentAnimation===n&&(this.currentAnimation=null)}}handleToggle(t){this.toggleTimeoutId=window.setTimeout((()=>this.toggleTimeoutId=null),10),"open"===t.newState?this.open():this.close()}startAutoupdates(){this.eventTarget&&this.host&&(this.clearAutoUpdate=function(t,e,n,o){void 0===o&&(o={});const{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:s="function"==typeof ResizeObserver,layoutShift:a="function"==typeof IntersectionObserver,animationFrame:c=!1}=o,p=ht(t),l=r||i?[...p?lt(p):[],...lt(e)]:[];l.forEach((t=>{r&&t.addEventListener("scroll",n,{passive:!0}),i&&t.addEventListener("resize",n)}));const h=p&&a?function(t,e){let n,o=null;const r=G(t);function i(){var t;clearTimeout(n),null==(t=o)||t.disconnect(),o=null}return function s(a,c){void 0===a&&(a=!1),void 0===c&&(c=1),i();const p=t.getBoundingClientRect(),{left:l,top:h,width:m,height:g}=p;if(a||e(),!m||!g)return;const v={rootMargin:-d(h)+"px "+-d(r.clientWidth-(l+m))+"px "+-d(r.clientHeight-(h+g))+"px "+-d(l)+"px",threshold:f(0,u(1,c))||1};let w=!0;function x(e){const o=e[0].intersectionRatio;if(o!==c){if(!w)return s();o?s(!1,o):n=setTimeout((()=>{s(!1,1e-7)}),1e3)}1!==o||Ot(p,t.getBoundingClientRect())||s(),w=!1}try{o=new IntersectionObserver(x,{...v,root:r.ownerDocument})}catch(t){o=new IntersectionObserver(x,v)}o.observe(t)}(!0),i}(p,n):null;let m,g=-1,v=null;s&&(v=new ResizeObserver((t=>{let[o]=t;o&&o.target===p&&v&&(v.unobserve(e),cancelAnimationFrame(g),g=requestAnimationFrame((()=>{var t;null==(t=v)||t.observe(e)}))),n()})),p&&!c&&v.observe(p),v.observe(e));let w=c?vt(t):null;return c&&function e(){const o=vt(t);w&&!Ot(w,o)&&n(),w=o,m=requestAnimationFrame(e)}(),n(),()=>{var t;l.forEach((t=>{r&&t.removeEventListener("scroll",n),i&&t.removeEventListener("resize",n)})),null==h||h(),null==(t=v)||t.disconnect(),v=null,c&&cancelAnimationFrame(m)}}(this.eventTarget,this.host,this.calculatePosition.bind(this)))}getHeaderHeight(){const t=document.querySelector("post-header");return t?parseFloat(getComputedStyle(t).height):0}async calculatePosition(){const{x:e,y:n,middlewareData:o,placement:r}=await this.computeMainPosition(),i=r.split("-")[0];if(this.dynamicPlacement=i,this.host.style.left=`${e}px`,this.host.style.top=`${n}px`,this.arrow&&o.arrow){const{x:e,y:n}=o.arrow,r=t.STATIC_SIDES[i],s=Number.parseFloat(getComputedStyle(document.documentElement).fontSize),a=getComputedStyle(this.arrowRef).getPropertyValue("--arrow-size").trim(),c=-.5*(a.endsWith("rem")?Number.parseFloat(a)*s:Number.parseFloat(a));r&&Object.assign(this.arrowRef.style,{left:e?`${e}px`:"",top:n?`${n}px`:"",[r]:`${c}px`})}this.safeSpace&&this.eventTarget&&await this.updateSafeSpaceBoundaries(i)}async computeMainPosition(){const t=this.edgeGap,e=[$t({padding:this.getHeaderHeight()}),(void 0===n&&(n={}),{name:"inline",options:n,async fn(t){const{placement:e,elements:o,rects:r,platform:i,strategy:s}=t,{padding:a=2,x:c,y:p}=x(n,t),l=Array.from(await(null==i.getClientRects?void 0:i.getClientRects(o.reference))||[]),h=function(t){const e=t.slice().sort(((t,e)=>t.y-e.y)),n=[];let o=null;for(let t=0;t<e.length;t++){const r=e[t];!o||r.y-o.y>o.height/2?n.push([r]):n[n.length-1].push(r),o=r}return n.map((t=>F(R(t))))}(l),d=F(R(l)),m=z(a),g=await i.getElementRects({reference:{getBoundingClientRect:function(){if(2===h.length&&h[0].left>h[1].right&&null!=c&&null!=p)return h.find((t=>c>t.left-m.left&&c<t.right+m.right&&p>t.top-m.top&&p<t.bottom+m.bottom))||d;if(h.length>=2){if("y"===T(e)){const t=h[0],n=h[h.length-1],o="top"===y(e),r=t.top,i=n.bottom,s=o?t.left:n.left,a=o?t.right:n.right;return{top:r,bottom:i,left:s,right:a,width:a-s,height:i-r,x:s,y:r}}const t="left"===y(e),n=f(...h.map((t=>t.right))),o=u(...h.map((t=>t.left))),r=h.filter((e=>t?e.left===o:e.right===n)),i=r[0].top,s=r[r.length-1].bottom;return{top:i,bottom:s,left:o,right:n,width:n-o,height:s-i,x:o,y:i}}return d}},floating:o.floating,strategy:s});return r.reference.x!==g.reference.x||r.reference.y!==g.reference.y||r.reference.width!==g.reference.width||r.reference.height!==g.reference.height?{reset:{rects:g}}:{}}}),Lt({padding:t,limiter:zt({offset:32})}),Dt({apply({availableWidth:e,elements:n}){Object.assign(n.floating.style,{maxWidth:e-2*t+"px"})}}),Ht(this.arrow?t+4:t)];var n;return this.arrow&&e.push((t=>({name:"arrow",options:t,async fn(e){const{x:n,y:o,placement:r,rects:i,platform:s,elements:a,middlewareData:c}=e,{element:p,padding:l=0}=x(t,e)||{};if(null==p)return{};const f=z(l),h={x:n,y:o},d=M(r),m=E(d),g=await s.getDimensions(p),v="y"===d,y=v?"top":"left",S=v?"bottom":"right",k=v?"clientHeight":"clientWidth",T=i.reference[m]+i.reference[d]-h[d]-i.floating[m],A=h[d]-i.reference[d],O=await(null==s.getOffsetParent?void 0:s.getOffsetParent(p));let H=O?O[k]:0;H&&await(null==s.isElement?void 0:s.isElement(O))||(H=a.floating[k]||i.floating[m]);const L=T/2-A/2,$=H/2-g[m]/2-1,D=u(f[y],$),F=u(f[S],$),P=D,C=H-g[m]-F,R=H/2-g[m]/2+L,j=w(P,R,C),W=!c.arrow&&null!=b(r)&&R!==j&&i.reference[m]/2-(R<P?D:F)-g[m]/2<0,B=W?R<P?R-P:R-C:0;return{[d]:h[d]+B,data:{[d]:j,centerOffset:R-j-B,...W&&{alignmentOffset:B}},reset:W}}}))({element:this.arrowRef,padding:t})),((t,e,n)=>{const o=new Map,r={platform:At,...n},i={...r.platform,_c:o};return(async(t,e,n)=>{const{placement:o="bottom",strategy:r="absolute",middleware:i=[],platform:s}=n,a=i.filter(Boolean),c=await(null==s.isRTL?void 0:s.isRTL(e));let p=await s.getElementRects({reference:t,floating:e,strategy:r}),{x:l,y:u}=P(p,o,c),f=o,h={},d=0;for(let n=0;n<a.length;n++){const{name:i,fn:m}=a[n],{x:g,y:v,data:w,reset:x}=await m({x:l,y:u,initialPlacement:o,placement:f,strategy:r,middlewareData:h,rects:p,platform:s,elements:{reference:t,floating:e}});l=null!=g?g:l,u=null!=v?v:u,h={...h,[i]:{...h[i],...w}},x&&d<=50&&(d++,"object"==typeof x&&(x.placement&&(f=x.placement),x.rects&&(p=!0===x.rects?await s.getElementRects({reference:t,floating:e,strategy:r}):x.rects),({x:l,y:u}=P(p,f,c))),n=-1)}return{x:l,y:u,placement:f,strategy:r,middlewareData:h}})(t,e,{...r,platform:i})})(this.eventTarget,this.host,{placement:this.placement||"top",strategy:"fixed",middleware:e})}async updateSafeSpaceBoundaries(e){const n=this.eventTarget.getBoundingClientRect(),o="top"===e||"bottom"===e,r=((t,e,n)=>"top"===t||"bottom"===t?{popover:{y:"top"===t?e.bottom:e.top,xStart:e.left,xEnd:e.right},trigger:{y:"top"===t?n.top:n.bottom,xStart:n.left,xEnd:n.right}}:{popover:{x:"left"===t?e.right:e.left,yStart:e.top,yEnd:e.bottom},trigger:{x:"left"===t?n.left:n.right,yStart:n.top,yEnd:n.bottom}})(e,this.host.getBoundingClientRect(),n);t.PROPERTIES_TO_CLEAR.forEach((t=>{this.host.style.removeProperty(t)})),o?(this.host.style.setProperty("--post-safe-space-popover-y",`${r.popover.y}px`),this.host.style.setProperty("--post-safe-space-popover-x-start",`${r.popover.xStart}px`),this.host.style.setProperty("--post-safe-space-popover-x-end",`${r.popover.xEnd}px`),this.host.style.setProperty("--post-safe-space-trigger-y",`${r.trigger.y}px`),this.host.style.setProperty("--post-safe-space-trigger-x-start",`${r.trigger.xStart}px`),this.host.style.setProperty("--post-safe-space-trigger-x-end",`${r.trigger.xEnd}px`)):(this.host.style.setProperty("--post-safe-space-popover-x",`${r.popover.x}px`),this.host.style.setProperty("--post-safe-space-popover-y-start",`${r.popover.yStart}px`),this.host.style.setProperty("--post-safe-space-popover-y-end",`${r.popover.yEnd}px`),this.host.style.setProperty("--post-safe-space-trigger-x",`${r.trigger.x}px`),this.host.style.setProperty("--post-safe-space-trigger-y-start",`${r.trigger.yStart}px`),this.host.style.setProperty("--post-safe-space-trigger-y-end",`${r.trigger.yEnd}px`))}render(){return o(r,{key:"f675b14ed97d7f2931781549df8aafd9072faa96","data-version":p,popover:"auto"},o("div",{key:"f66186a7448f60b9f9dcb1b3cbe047a74a85dc7b",class:"popover-content"},this.arrow&&o("span",{key:"d0f8f2baa005522140ac1ef49a0bccc13be72c72","dynamic-placement":this.dynamicPlacement,class:"arrow",ref:t=>{this.arrowRef=t}}),o("slot",{key:"5fbdad6fa76951f4d886ef0ab57e7471ac38c59d"})))}get host(){return this}static get watchers(){return{placement:[{validatePlacement:0}],edgeGap:[{validateEdgeGap:0}],safeSpace:[{validateSafeSpace:0}]}}static get style(){return'@layer polyfill{@supports not selector(:popover-open){[popover]:not(.\\:popover-open){display:none}}}:where(post-popovercontainer){background-color:rgba(0,0,0,0);border:rgba(0,0,0,0);position:fixed;margin:0;padding:0;overflow:visible}:where(post-popovercontainer)>div{box-shadow:var(--post-device-elevation-300);width:max-content;max-width:100%;color:var(--post-current-fg);background-color:var(--post-current-bg);border-radius:4px}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:where(post-popovercontainer)>div{border:2px solid rgba(0,0,0,0)}}:where(post-popovercontainer)[tooltip]{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0}:where(post-popovercontainer)[safe-space]::after{content:"";position:fixed;inset:0;z-index:-1;pointer-events:auto}:where(post-popovercontainer)[safe-space=triangle]::after{clip-path:polygon(var(--post-safe-space-cursor-x, 0) var(--post-safe-space-cursor-y, 0), var(--post-safe-space-popover-x-start, var(--post-safe-space-popover-x, 0)) var(--post-safe-space-popover-y, var(--post-safe-space-popover-y-start, 0)), var(--post-safe-space-popover-x-end, var(--post-safe-space-popover-x, 0)) var(--post-safe-space-popover-y, var(--post-safe-space-popover-y-end, 0)))}:where(post-popovercontainer)[safe-space=trapezoid]::after{clip-path:polygon(var(--post-safe-space-trigger-x-start, var(--post-safe-space-trigger-x, 0)) var(--post-safe-space-trigger-y, var(--post-safe-space-trigger-y-start, 0)), var(--post-safe-space-trigger-x-end, var(--post-safe-space-trigger-x, 0)) var(--post-safe-space-trigger-y, var(--post-safe-space-trigger-y-end, 0)), var(--post-safe-space-popover-x-end, var(--post-safe-space-popover-x, 0)) var(--post-safe-space-popover-y, var(--post-safe-space-popover-y-end, 0)), var(--post-safe-space-popover-x-start, var(--post-safe-space-popover-x, 0)) var(--post-safe-space-popover-y, var(--post-safe-space-popover-y-start, 0)))}:where(post-popovercontainer):not(:has(.arrow))>div{box-shadow:var(--post-device-elevation-300)}:where(post-popovercontainer):has(.arrow)>div{filter:drop-shadow(1px 2px 3px hsla(216, 9%, 11%, 0.15)) drop-shadow(2px 4px 6px hsla(225, 17%, 9%, 0.15)) drop-shadow(4px 8px 12px hsla(225, 7%, 11%, 0.15))}:where(post-popovercontainer):has(.arrow.top)>div{filter:drop-shadow(0px -2px 3px hsla(216, 9%, 11%, 0.15)) drop-shadow(0px -4px 6px hsla(225, 17%, 9%, 0.15)) drop-shadow(0px -8px 12px hsla(225, 7%, 11%, 0.15))}:where(post-popovercontainer):has(.arrow.left)>div{filter:drop-shadow(-2px 0px 3px hsla(216, 9%, 11%, 0.15)) drop-shadow(-4px 0px 6px hsla(225, 17%, 9%, 0.15)) drop-shadow(-8px 0px 12px hsla(225, 7%, 11%, 0.15))}:where(post-popovercontainer):has(.arrow.right)>div{filter:drop-shadow(2px 0px 3px hsla(216, 9%, 11%, 0.15)) drop-shadow(4px 0px 6px hsla(225, 17%, 9%, 0.15)) drop-shadow(8px 0px 12px hsla(225, 7%, 11%, 0.15))}:where(post-popovercontainer) .arrow{--arrow-size: 0.5825rem;position:absolute;width:.5825rem;height:.5825rem;background-color:inherit;rotate:45deg;pointer-events:none;z-index:-1}:where(post-popovercontainer) .arrow[dynamic-placement=top]{border-bottom-right-radius:2px}:where(post-popovercontainer) .arrow[dynamic-placement=right]{border-bottom-left-radius:2px}:where(post-popovercontainer) .arrow[dynamic-placement=bottom]{border-top-left-radius:2px}:where(post-popovercontainer) .arrow[dynamic-placement=left]{border-top-right-radius:2px}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:where(post-popovercontainer) .arrow[dynamic-placement=top]{border-block-end:2px solid rgba(0,0,0,0);border-inline-end:2px solid rgba(0,0,0,0);bottom:-0.3796735336rem !important}:where(post-popovercontainer) .arrow[dynamic-placement=left]{border-block-start:2px solid rgba(0,0,0,0);border-inline-end:2px solid rgba(0,0,0,0);right:-0.3796735336rem !important}:where(post-popovercontainer) .arrow[dynamic-placement=right]{border-block-end:2px solid rgba(0,0,0,0);border-inline-start:2px solid rgba(0,0,0,0);left:-0.3796735336rem !important}:where(post-popovercontainer) .arrow[dynamic-placement=bottom]{border-block-start:2px solid rgba(0,0,0,0);border-inline-start:2px solid rgba(0,0,0,0);top:-0.3796735336rem !important}}'}},[260,"post-popovercontainer",{placement:[1],edgeGap:[2,"edge-gap"],arrow:[4],safeSpace:[513,"safe-space"],dynamicPlacement:[32],show:[64],hide:[64],toggle:[64]},void 0,{placement:[{validatePlacement:0}],edgeGap:[{validateEdgeGap:0}],safeSpace:[{validateSafeSpace:0}]}]);function ve(){"undefined"!=typeof customElements&&["post-popovercontainer"].forEach((t=>{"post-popovercontainer"===t&&(customElements.get(i(t))||customElements.define(i(t),ge))}))}ge.STATIC_SIDES={top:"bottom",right:"left",bottom:"top",left:"right"},ge.PROPERTIES_TO_CLEAR=["--post-safe-space-popover-x","--post-safe-space-popover-y","--post-safe-space-popover-x-start","--post-safe-space-popover-x-end","--post-safe-space-popover-y-start","--post-safe-space-popover-y-end","--post-safe-space-trigger-x","--post-safe-space-trigger-y","--post-safe-space-trigger-x-start","--post-safe-space-trigger-x-end","--post-safe-space-trigger-y-start","--post-safe-space-trigger-y-end"],ve();export{ge as P,l as a,ve as d}
@@ -0,0 +1 @@
1
+ import{t,p as a,H as i,h as e,a as n}from"./index.js";import{I as s}from"./p-FxUVQ4Tx.js";import{d as o,e as r,c as m}from"./p-B8YiQ3mz.js";import{v as l}from"./p-CZvbetqX.js";const c=`https://unpkg.com/@swisspost/design-system-icons@${l}/public/post-icons/`,f=["cylon","cylon-vertical","spin","spin-reverse","fade","throb"],h=a(class extends i{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.flipH=!1,this.flipV=!1}validateAnimation(){o(this,"animation",f)}validateBase(){r(this,"base","string")}validateName(){m(this,"name","string")}validateRotate(){r(this,"rotate","number")}validateScale(){r(this,"scale","number")}getUrl(){const t=`${this.name}.svg`;if(!s&&!this.base)return`${c}${t}`;const a=t=>/^https?:\/\//.test(t),i=t=>t&&!t.endsWith("/")?`${t}/`:t,e=t=>t.replace(/([^:])\/\//g,"$1/"),n=s?window.location.origin:"",o=s&&document.querySelector("base[href]")?.getAttribute("href")||"";let r="";if(s){const t=document.querySelector('meta[name="design-system-settings"]');r=t?.getAttribute("data-post-icon-base")||""}const m=t=>{const e=i(o),s=i(t);return a(e)?`${e}${s}`:`${n}${e}${s}`};let l;return this.base?(l=a(this.base)?`${i(this.base)}${t}`:`${m(this.base)}${t}`,e(l)):r?(l=a(r)?`${i(r)}${t}`:`${m(r)}${t}`,e(l)):e(`${c}${t}`)}getStyles(){const t=this.getUrl();return Object.entries({"-webkit-mask-image":`url(${t})`,"mask-image":`url('${t}')`,transform:(this.scale&&!isNaN(Number(this.scale))?"scale("+this.scale+")":"")+(this.rotate&&!isNaN(Number(this.rotate))?" rotate("+this.rotate+"deg)":"")}).filter((([t,a])=>null!==a)).reduce(((t,[a,i])=>Object.assign(t,{[a]:i})),{})}componentDidLoad(){this.validateBase(),this.validateName(),this.validateScale(),this.validateRotate(),this.validateAnimation()}render(){return e(n,{key:"fe1b4d0541c75c1ed0adb92111d106ed874a9b2f","data-version":l},e("span",{key:"ca2b749e407d9ec54eb881c6662b59626e16083d",style:this.getStyles()}))}get host(){return this}static get watchers(){return{animation:[{validateAnimation:0}],base:[{validateBase:0}],name:[{validateName:0}],rotate:[{validateRotate:0}],scale:[{validateScale:0}]}}static get style(){return":host{display:inline-block;width:1em;height:1em;vertical-align:-0.15em}span{display:block;width:100%;height:100%;fill:currentColor;forced-color-adjust:preserve-parent-color;background-color:currentColor;-webkit-mask-position:center center;mask-position:center center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-size:100%;mask-size:100%}:host([flip-h]:not([flip-h=false])){scale:-1 1}:host([flip-v]:not([flip-v=false])){scale:1 -1}:host([flip-h][flip-v]:not([flip-h=false],[flip-v=false])){scale:-1}:host([animation]){transform-origin:center}:host([animation=cylon]){animation:icon-animation-cylon .75s ease-in-out infinite alternate}:host([animation=cylon-vertical]){animation:icon-animation-cylon-vertical .75s ease-in-out infinite alternate}:host([animation=spin]){animation:icon-animation-spin 2s linear infinite normal}:host([animation=spin-reverse]){animation:icon-animation-spin 2s linear infinite reverse}:host([animation=fade]){animation:icon-animation-fade .75s ease-in-out infinite alternate}:host([animation=throb]){animation:icon-animation-throb .75s ease-in-out infinite alternate}@keyframes icon-animation-cylon{from{transform:translateX(-25%)}to{transform:translateX(25%)}}@keyframes icon-animation-cylon-vertical{from{transform:translateY(25%)}to{transform:translateY(-25%)}}@keyframes icon-animation-fade{from{opacity:.1}to{opacity:1}}@keyframes icon-animation-spin{from{transform:rotate(0deg)}to{transform:rotate(359deg)}}@keyframes icon-animation-throb{from{opacity:.5;transform:scale(0.5)}to{opacity:1;transform:scale(1)}}"}},[1,"post-icon",{animation:[1],base:[1],flipH:[4,"flip-h"],flipV:[4,"flip-v"],name:[513],rotate:[2],scale:[2]},void 0,{animation:[{validateAnimation:0}],base:[{validateBase:0}],name:[{validateName:0}],rotate:[{validateRotate:0}],scale:[{validateScale:0}]}]);function p(){"undefined"!=typeof customElements&&["post-icon"].forEach((a=>{"post-icon"===a&&(customElements.get(t(a))||customElements.define(t(a),h))}))}p();export{h as P,p as d}
@@ -1,3 +1 @@
1
- const SWITCH_VARIANTS = ['list', 'menu'];
2
-
3
- export { SWITCH_VARIANTS as S };
1
+ const s=["list","menu"];export{s as S}
@@ -0,0 +1 @@
1
+ import{p as e,H as t,c as s,h as i,a as o,t as a}from"./index.js";import{a as n,d as r}from"./p-D9DDtvFM.js";import{v as l}from"./p-CZvbetqX.js";import{g as c}from"./p-CJ13r5fi.js";import{d as h,c as d}from"./p-B8YiQ3mz.js";import{E as p}from"./p-rEfV4v4a.js";import{g as m}from"./p-BVGcVycs.js";var f=function(e,t,s,i){var o,a=arguments.length,n=a<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,s,i);else for(var r=e.length-1;r>=0;r--)(o=e[r])&&(n=(a<3?o(n):a>3?o(t,s,n):o(t,s))||n);return a>3&&n&&Object.defineProperty(t,s,n),n};const b=e(class extends t{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.toggleMenu=s(this,"toggleMenu"),this.lastFocusedElement=null,this.KEYCODES={SPACE:" ",ENTER:"Enter",UP:"ArrowUp",DOWN:"ArrowDown",TAB:"Tab",HOME:"Home",END:"End",ESCAPE:"Escape"},this.placement="bottom",this.isVisible=!1,this.handleKeyDown=e=>{e.stopPropagation(),e.key!==this.KEYCODES.ESCAPE?Object.values(this.KEYCODES).includes(e.key)&&this.controlKeyDownHandler(e):this.toggle(this.host)},this.handleClick=e=>{["BUTTON","A","INPUT","SELECT","TEXTAREA"].includes(e.target.tagName)&&this.toggle(this.host)}}validatePlacement(){h(this,"placement",n)}validateLabel(){d(this,"label","string")}connectedCallback(){this.root=m(this.host),this.host.addEventListener("keydown",this.handleKeyDown),this.host.addEventListener("click",this.handleClick)}disconnectedCallback(){this.host.removeEventListener("keydown",this.handleKeyDown),this.host.removeEventListener("click",this.handleClick)}componentDidLoad(){this.validatePlacement(),this.validateLabel()}async toggle(e){this.popoverRef?await this.popoverRef.toggle(e):console.error("toggle: popoverRef is null or undefined")}async show(e){this.popoverRef?await this.popoverRef.show(e):console.error("show: popoverRef is null or undefined")}async hide(){this.popoverRef?await this.popoverRef.hide():console.error("hide: popoverRef is null or undefined")}handlePostShown(e){if(e.detail.first){this.host.setAttribute("role","menu");const e=this.getSlottedItems();for(const t of e)t.setAttribute("role","menuitem");this.label&&this.host.setAttribute("aria-label",this.label)}}handlePostBeforeToggle(e){this.isVisible=e.detail.willOpen,this.toggleMenu.emit(this.isVisible),this.isVisible?(this.lastFocusedElement=this.root?.activeElement,requestAnimationFrame((()=>{const e=this.getSlottedItems();e.length>0&&e[0].focus()}))):this.lastFocusedElement&&this.lastFocusedElement.focus()}controlKeyDownHandler(e){const t=this.getSlottedItems();if(!t.length)return;let s=t.findIndex((e=>e===m(e).activeElement));switch(e.key){case this.KEYCODES.UP:e.preventDefault(),s=(s-1+t.length)%t.length;break;case this.KEYCODES.DOWN:e.preventDefault(),s=(s+1)%t.length;break;case this.KEYCODES.HOME:s=0;break;case this.KEYCODES.END:e.preventDefault(),s=t.length-1;break;case this.KEYCODES.SPACE:return void this.toggle(this.host);case this.KEYCODES.TAB:this.toggle(this.host)}t[s]&&t[s].focus()}getSlottedItems(){const e=this.host.shadowRoot.querySelectorAll("slot"),t=[];return e.forEach((e=>t.push(...e.assignedElements()))),t.flatMap((e=>e instanceof HTMLSlotElement?e.assignedElements():e)).flatMap((e=>Array.from(c(e))))}render(){return i(o,{key:"b8eed085445b840a741ee5115c10ef4e9b3fb387","data-version":l},i("post-popovercontainer",{key:"4d885d0d4a23c5b29312588bccdc0cbbf7e3da23",onPostShow:this.handlePostShown.bind(this),onPostBeforeToggle:this.handlePostBeforeToggle.bind(this),placement:this.placement,ref:e=>this.popoverRef=e},i("div",{key:"69ed7ce44051026ca85f6a6cd25aeb1f2ef56a3c",part:"post-menu"},i("slot",{key:"431d56f067986a0eded7b15c6dbc4ab0662a5b86",name:"header"}),i("slot",{key:"3b906c3a19cce7372de493b5dfe90d1587925a2c"}))))}get host(){return this}static get watchers(){return{placement:[{validatePlacement:0}],label:[{validateLabel:0}]}}static get style(){return":host{display:block}:where([part=post-menu]){display:flex;flex-direction:column;padding-block:.5rem}::slotted([slot=header]){margin-top:-0.5rem;padding:1rem;display:flex;align-items:center;gap:.5rem;border-block-end:1px solid #050400;font-weight:700}@media screen and (max-width: 1023.98px){::slotted([slot=header]){padding:.75rem 1rem}}@media screen and (max-width: 779.98px){::slotted([slot=header]){padding:.5rem 1rem}}"}},[257,"post-menu",{placement:[1],label:[513],isVisible:[32],toggle:[64],show:[64],hide:[64]},void 0,{placement:[{validatePlacement:0}],label:[{validateLabel:0}]}]);function u(){"undefined"!=typeof customElements&&["post-menu","post-popovercontainer"].forEach((e=>{switch(e){case"post-menu":customElements.get(a(e))||customElements.define(a(e),b);break;case"post-popovercontainer":customElements.get(a(e))||r()}}))}f([p("post-popovercontainer")],b.prototype,"handlePostShown",null),f([p("post-popovercontainer")],b.prototype,"handlePostBeforeToggle",null),u();export{b as P,u as d}
@@ -0,0 +1 @@
1
+ const o="undefined"!=typeof global,n="undefined"!=typeof window,d=n&&"MockNavigator"===window.navigator.userAgent,e=n&&"http://mockdoc.stenciljs.com"===window.location.origin,t=o&&d&&global.IS_HYDRATEAPP_SERVERTEST,a=n&&!(o&&d&&e||t),i=!a;export{a as I,i as a}