@swisspost/internet-header 10.7.0 → 10.8.0

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 (310) hide show
  1. package/dist/cjs/index-B5ypPkK3.js +4 -4
  2. package/dist/cjs/index.cjs.js +1 -1
  3. package/dist/cjs/is-focus-visible-B3CqVQsX.js +19 -0
  4. package/dist/cjs/loader.cjs.js +1 -1
  5. package/dist/cjs/{package-BtKYhTNj.js → package-DAEQGHsE.js} +1 -1
  6. package/dist/cjs/{package-BWgt2bx3.js → package-DV0YNR6p.js} +1 -1
  7. package/dist/cjs/post-accordion_4.cjs.entry.js +11 -5
  8. package/dist/cjs/post-autocomplete.cjs.entry.js +1 -1
  9. package/dist/cjs/post-avatar.cjs.entry.js +80 -56
  10. package/dist/cjs/post-back-to-top.cjs.entry.js +2 -2
  11. package/dist/cjs/post-banner.cjs.entry.js +2 -2
  12. package/dist/cjs/post-breadcrumb-item.cjs.entry.js +2 -2
  13. package/dist/cjs/post-breadcrumbs.cjs.entry.js +2 -2
  14. package/dist/cjs/post-closebutton.cjs.entry.js +2 -2
  15. package/dist/cjs/post-date-picker.cjs.entry.js +18 -4
  16. package/dist/cjs/post-footer.cjs.entry.js +1 -1
  17. package/dist/cjs/post-header.cjs.entry.js +33 -14
  18. package/dist/cjs/post-icon.cjs.entry.js +1 -1
  19. package/dist/cjs/post-language-menu-item.cjs.entry.js +1 -1
  20. package/dist/cjs/post-language-menu.cjs.entry.js +2 -2
  21. package/dist/cjs/post-linkarea.cjs.entry.js +1 -1
  22. package/dist/cjs/post-listbox-option.cjs.entry.js +1 -1
  23. package/dist/cjs/post-listbox.cjs.entry.js +1 -1
  24. package/dist/cjs/post-logo.cjs.entry.js +2 -2
  25. package/dist/cjs/post-mainnavigation.cjs.entry.js +1 -1
  26. package/dist/cjs/post-megadropdown-trigger.cjs.entry.js +2 -2
  27. package/dist/cjs/post-megadropdown.cjs.entry.js +36 -18
  28. package/dist/cjs/post-menu-item.cjs.entry.js +2 -2
  29. package/dist/cjs/post-menu_2.cjs.entry.js +5 -15
  30. package/dist/cjs/post-number-input.cjs.entry.js +2 -2
  31. package/dist/cjs/post-pagination.cjs.entry.js +2 -2
  32. package/dist/cjs/post-popover-trigger.cjs.entry.js +1 -1
  33. package/dist/cjs/post-popover.cjs.entry.js +4 -4
  34. package/dist/cjs/post-popovercontainer.cjs.entry.js +387 -536
  35. package/dist/cjs/post-rating.cjs.entry.js +1 -1
  36. package/dist/cjs/post-side-navigation-trigger.cjs.entry.js +1 -1
  37. package/dist/cjs/post-side-navigation.cjs.entry.js +9 -4
  38. package/dist/cjs/post-stepper-item.cjs.entry.js +1 -1
  39. package/dist/cjs/post-stepper.cjs.entry.js +1 -1
  40. package/dist/cjs/post-tab-item.cjs.entry.js +1 -1
  41. package/dist/cjs/post-tab-panel.cjs.entry.js +1 -1
  42. package/dist/cjs/post-tabs.cjs.entry.js +4 -4
  43. package/dist/cjs/post-togglebutton.cjs.entry.js +1 -1
  44. package/dist/cjs/post-tooltip-trigger.cjs.entry.js +2 -2
  45. package/dist/cjs/post-tooltip.cjs.entry.js +5 -3
  46. package/dist/cjs/swisspost-internet-footer.cjs.entry.js +1 -1
  47. package/dist/cjs/swisspost-internet-header.cjs.entry.js +9 -7
  48. package/dist/cjs/swisspost-internet-header.cjs.js +1 -1
  49. package/dist/collection/components/internal/UserMenu.js +8 -6
  50. package/dist/components/is-focus-visible.js +1 -0
  51. package/dist/components/package.js +1 -1
  52. package/dist/components/package2.js +1 -1
  53. package/dist/components/post-accordion-item2.js +1 -1
  54. package/dist/components/post-avatar.js +1 -1
  55. package/dist/components/post-back-to-top.js +1 -1
  56. package/dist/components/post-banner.js +1 -1
  57. package/dist/components/post-breadcrumb-item.js +1 -1
  58. package/dist/components/post-breadcrumbs.js +1 -1
  59. package/dist/components/post-closebutton2.js +1 -1
  60. package/dist/components/post-collapsible2.js +1 -1
  61. package/dist/components/post-date-picker.js +1 -1
  62. package/dist/components/post-header2.js +1 -1
  63. package/dist/components/post-language-menu2.js +1 -1
  64. package/dist/components/post-logo2.js +1 -1
  65. package/dist/components/post-megadropdown-trigger.js +1 -1
  66. package/dist/components/post-megadropdown.js +1 -1
  67. package/dist/components/post-menu-item2.js +1 -1
  68. package/dist/components/post-menu2.js +1 -1
  69. package/dist/components/post-number-input.js +1 -1
  70. package/dist/components/post-pagination.js +1 -1
  71. package/dist/components/post-popover.js +1 -1
  72. package/dist/components/post-popovercontainer2.js +1 -1
  73. package/dist/components/post-side-navigation.js +1 -1
  74. package/dist/components/post-tabs.js +1 -1
  75. package/dist/components/post-tooltip-trigger.js +1 -1
  76. package/dist/components/post-tooltip.js +1 -1
  77. package/dist/components/swisspost-internet-header.js +1 -1
  78. package/dist/docs.json +1 -1
  79. package/dist/esm/index-h3opCZqH.js +4 -4
  80. package/dist/esm/index.js +1 -1
  81. package/dist/esm/is-focus-visible-BWwWKRO5.js +17 -0
  82. package/dist/esm/loader.js +1 -1
  83. package/dist/esm/{package-DRoYikPQ.js → package--a_K3g1E.js} +1 -1
  84. package/dist/esm/{package-BBz9PVf0.js → package-BdiQsTQm.js} +1 -1
  85. package/dist/esm/post-accordion_4.entry.js +11 -5
  86. package/dist/esm/post-autocomplete.entry.js +1 -1
  87. package/dist/esm/post-avatar.entry.js +80 -56
  88. package/dist/esm/post-back-to-top.entry.js +2 -2
  89. package/dist/esm/post-banner.entry.js +2 -2
  90. package/dist/esm/post-breadcrumb-item.entry.js +2 -2
  91. package/dist/esm/post-breadcrumbs.entry.js +2 -2
  92. package/dist/esm/post-closebutton.entry.js +2 -2
  93. package/dist/esm/post-date-picker.entry.js +18 -4
  94. package/dist/esm/post-footer.entry.js +1 -1
  95. package/dist/esm/post-header.entry.js +33 -14
  96. package/dist/esm/post-icon.entry.js +1 -1
  97. package/dist/esm/post-language-menu-item.entry.js +1 -1
  98. package/dist/esm/post-language-menu.entry.js +2 -2
  99. package/dist/esm/post-linkarea.entry.js +1 -1
  100. package/dist/esm/post-listbox-option.entry.js +1 -1
  101. package/dist/esm/post-listbox.entry.js +1 -1
  102. package/dist/esm/post-logo.entry.js +2 -2
  103. package/dist/esm/post-mainnavigation.entry.js +1 -1
  104. package/dist/esm/post-megadropdown-trigger.entry.js +2 -2
  105. package/dist/esm/post-megadropdown.entry.js +36 -18
  106. package/dist/esm/post-menu-item.entry.js +2 -2
  107. package/dist/esm/post-menu_2.entry.js +5 -15
  108. package/dist/esm/post-number-input.entry.js +2 -2
  109. package/dist/esm/post-pagination.entry.js +2 -2
  110. package/dist/esm/post-popover-trigger.entry.js +1 -1
  111. package/dist/esm/post-popover.entry.js +4 -4
  112. package/dist/esm/post-popovercontainer.entry.js +387 -536
  113. package/dist/esm/post-rating.entry.js +1 -1
  114. package/dist/esm/post-side-navigation-trigger.entry.js +1 -1
  115. package/dist/esm/post-side-navigation.entry.js +9 -4
  116. package/dist/esm/post-stepper-item.entry.js +1 -1
  117. package/dist/esm/post-stepper.entry.js +1 -1
  118. package/dist/esm/post-tab-item.entry.js +1 -1
  119. package/dist/esm/post-tab-panel.entry.js +1 -1
  120. package/dist/esm/post-tabs.entry.js +4 -4
  121. package/dist/esm/post-togglebutton.entry.js +1 -1
  122. package/dist/esm/post-tooltip-trigger.entry.js +2 -2
  123. package/dist/esm/post-tooltip.entry.js +5 -3
  124. package/dist/esm/swisspost-internet-footer.entry.js +1 -1
  125. package/dist/esm/swisspost-internet-header.entry.js +9 -7
  126. package/dist/esm/swisspost-internet-header.js +1 -1
  127. package/dist/esm-es5/index-h3opCZqH.js +1 -1
  128. package/dist/esm-es5/index.js +1 -1
  129. package/dist/esm-es5/is-focus-visible-BWwWKRO5.js +1 -0
  130. package/dist/esm-es5/loader.js +1 -1
  131. package/dist/esm-es5/{package-DRoYikPQ.js → package--a_K3g1E.js} +1 -1
  132. package/dist/esm-es5/package-BdiQsTQm.js +1 -0
  133. package/dist/esm-es5/post-accordion_4.entry.js +1 -1
  134. package/dist/esm-es5/post-autocomplete.entry.js +1 -1
  135. package/dist/esm-es5/post-avatar.entry.js +1 -1
  136. package/dist/esm-es5/post-back-to-top.entry.js +1 -1
  137. package/dist/esm-es5/post-banner.entry.js +1 -1
  138. package/dist/esm-es5/post-breadcrumb-item.entry.js +1 -1
  139. package/dist/esm-es5/post-breadcrumbs.entry.js +1 -1
  140. package/dist/esm-es5/post-closebutton.entry.js +1 -1
  141. package/dist/esm-es5/post-date-picker.entry.js +1 -1
  142. package/dist/esm-es5/post-footer.entry.js +1 -1
  143. package/dist/esm-es5/post-header.entry.js +1 -1
  144. package/dist/esm-es5/post-icon.entry.js +1 -1
  145. package/dist/esm-es5/post-language-menu-item.entry.js +1 -1
  146. package/dist/esm-es5/post-language-menu.entry.js +1 -1
  147. package/dist/esm-es5/post-linkarea.entry.js +1 -1
  148. package/dist/esm-es5/post-listbox-option.entry.js +1 -1
  149. package/dist/esm-es5/post-listbox.entry.js +1 -1
  150. package/dist/esm-es5/post-logo.entry.js +1 -1
  151. package/dist/esm-es5/post-mainnavigation.entry.js +1 -1
  152. package/dist/esm-es5/post-megadropdown-trigger.entry.js +1 -1
  153. package/dist/esm-es5/post-megadropdown.entry.js +1 -1
  154. package/dist/esm-es5/post-menu-item.entry.js +1 -1
  155. package/dist/esm-es5/post-menu_2.entry.js +1 -1
  156. package/dist/esm-es5/post-number-input.entry.js +1 -1
  157. package/dist/esm-es5/post-pagination.entry.js +1 -1
  158. package/dist/esm-es5/post-popover-trigger.entry.js +1 -1
  159. package/dist/esm-es5/post-popover.entry.js +1 -1
  160. package/dist/esm-es5/post-popovercontainer.entry.js +1 -1
  161. package/dist/esm-es5/post-rating.entry.js +1 -1
  162. package/dist/esm-es5/post-side-navigation-trigger.entry.js +1 -1
  163. package/dist/esm-es5/post-side-navigation.entry.js +1 -1
  164. package/dist/esm-es5/post-stepper-item.entry.js +1 -1
  165. package/dist/esm-es5/post-stepper.entry.js +1 -1
  166. package/dist/esm-es5/post-tab-item.entry.js +1 -1
  167. package/dist/esm-es5/post-tab-panel.entry.js +1 -1
  168. package/dist/esm-es5/post-tabs.entry.js +1 -1
  169. package/dist/esm-es5/post-togglebutton.entry.js +1 -1
  170. package/dist/esm-es5/post-tooltip-trigger.entry.js +1 -1
  171. package/dist/esm-es5/post-tooltip.entry.js +1 -1
  172. package/dist/esm-es5/swisspost-internet-footer.entry.js +1 -1
  173. package/dist/esm-es5/swisspost-internet-header.entry.js +1 -1
  174. package/dist/esm-es5/swisspost-internet-header.js +1 -1
  175. package/dist/swisspost-internet-header/index.esm.js +1 -1
  176. package/dist/swisspost-internet-header/{p-7e8c8743.entry.js → p-0c6839cd.entry.js} +1 -1
  177. package/dist/swisspost-internet-header/{p-c28020b7.entry.js → p-148cfacf.entry.js} +1 -1
  178. package/dist/swisspost-internet-header/p-1617517b.entry.js +1 -0
  179. package/dist/swisspost-internet-header/{p-dbcd6fb9.entry.js → p-174e2b92.entry.js} +1 -1
  180. package/dist/swisspost-internet-header/{p-12cb6db2.entry.js → p-1ab10b94.entry.js} +1 -1
  181. package/dist/swisspost-internet-header/{p-79f2d9ef.entry.js → p-1d145a3d.entry.js} +1 -1
  182. package/dist/swisspost-internet-header/p-1df3d147.entry.js +1 -0
  183. package/dist/swisspost-internet-header/{p-d9c1046b.entry.js → p-22da79ea.entry.js} +1 -1
  184. package/dist/swisspost-internet-header/{p-68898c0b.system.entry.js → p-238c919d.system.entry.js} +1 -1
  185. package/dist/swisspost-internet-header/p-26ac0464.entry.js +1 -0
  186. package/dist/swisspost-internet-header/{p-d91f90a1.entry.js → p-2d56ef1f.entry.js} +1 -1
  187. package/dist/swisspost-internet-header/{p-d7b33964.system.entry.js → p-3124582e.system.entry.js} +1 -1
  188. package/dist/swisspost-internet-header/{p-35ddf3ca.system.entry.js → p-36232387.system.entry.js} +1 -1
  189. package/dist/swisspost-internet-header/{p-ef16275c.entry.js → p-381ac502.entry.js} +1 -1
  190. package/dist/swisspost-internet-header/{p-1bb3ad80.system.entry.js → p-3995eead.system.entry.js} +1 -1
  191. package/dist/swisspost-internet-header/p-3afac939.entry.js +1 -0
  192. package/dist/swisspost-internet-header/{p-c1db8f13.entry.js → p-3ef5a7c0.entry.js} +1 -1
  193. package/dist/swisspost-internet-header/{p-9c09cf8b.system.entry.js → p-42fe4c65.system.entry.js} +1 -1
  194. package/dist/swisspost-internet-header/{p-8943e2e2.entry.js → p-4466ee14.entry.js} +1 -1
  195. package/dist/swisspost-internet-header/p-45398826.entry.js +1 -0
  196. package/dist/swisspost-internet-header/p-45d989e5.system.entry.js +1 -0
  197. package/dist/swisspost-internet-header/{p-06f12978.system.entry.js → p-49c132a1.system.entry.js} +1 -1
  198. package/dist/swisspost-internet-header/p-4ab5590e.system.entry.js +1 -0
  199. package/dist/swisspost-internet-header/{p-36be4427.system.entry.js → p-4b39fa0b.system.entry.js} +1 -1
  200. package/dist/swisspost-internet-header/{p-3ca53634.entry.js → p-4d94cb9d.entry.js} +1 -1
  201. package/dist/swisspost-internet-header/{p-b3481769.entry.js → p-518f5952.entry.js} +1 -1
  202. package/dist/swisspost-internet-header/{p-32fd1973.entry.js → p-546f0429.entry.js} +1 -1
  203. package/dist/swisspost-internet-header/p-5550933f.entry.js +1 -0
  204. package/dist/swisspost-internet-header/p-576e3b55.system.entry.js +1 -0
  205. package/dist/swisspost-internet-header/{p-5971e15b.entry.js → p-57b73dd7.entry.js} +1 -1
  206. package/dist/swisspost-internet-header/{p-97727574.entry.js → p-5a929d5c.entry.js} +1 -1
  207. package/dist/swisspost-internet-header/{p-94c6710f.system.entry.js → p-5aa3e212.system.entry.js} +1 -1
  208. package/dist/swisspost-internet-header/{p-990da9f3.system.entry.js → p-5ac46ce3.system.entry.js} +1 -1
  209. package/dist/swisspost-internet-header/{p-9e85063a.entry.js → p-5e112c81.entry.js} +1 -1
  210. package/dist/swisspost-internet-header/p-61e37660.entry.js +1 -0
  211. package/dist/swisspost-internet-header/p-629dfdba.entry.js +1 -0
  212. package/dist/swisspost-internet-header/{p-d6e0e5f2.system.entry.js → p-62a14cc2.system.entry.js} +1 -1
  213. package/dist/swisspost-internet-header/p-62b7473b.entry.js +1 -0
  214. package/dist/swisspost-internet-header/{p-c6672194.system.entry.js → p-65fb1a64.system.entry.js} +1 -1
  215. package/dist/swisspost-internet-header/p-6c284cd6.system.entry.js +1 -0
  216. package/dist/swisspost-internet-header/p-6f0c2a5c.system.entry.js +1 -0
  217. package/dist/swisspost-internet-header/p-745c3c76.system.entry.js +1 -0
  218. package/dist/swisspost-internet-header/{p-db3f471b.system.entry.js → p-74b8b73a.system.entry.js} +1 -1
  219. package/dist/swisspost-internet-header/{p-ec7c0b5e.system.entry.js → p-79dc7e1b.system.entry.js} +1 -1
  220. package/dist/swisspost-internet-header/p-7a8d9175.system.entry.js +1 -0
  221. package/dist/swisspost-internet-header/p-7f953da2.system.entry.js +1 -0
  222. package/dist/swisspost-internet-header/{p-4d9971e2.entry.js → p-80ce5ec8.entry.js} +1 -1
  223. package/dist/swisspost-internet-header/p-851c2112.system.entry.js +1 -0
  224. package/dist/swisspost-internet-header/p-8b90f7d2.system.entry.js +1 -0
  225. package/dist/swisspost-internet-header/p-8ff4691a.entry.js +1 -0
  226. package/dist/swisspost-internet-header/p-925203fb.system.entry.js +1 -0
  227. package/dist/swisspost-internet-header/{p-46dc968c.entry.js → p-94aae5c3.entry.js} +1 -1
  228. package/dist/swisspost-internet-header/{p-4889abef.entry.js → p-94c7624f.entry.js} +1 -1
  229. package/dist/swisspost-internet-header/{p-c0c10b63.system.entry.js → p-9ac136f3.system.entry.js} +1 -1
  230. package/dist/swisspost-internet-header/{p-DHWj-DKi.system.js → p-B1oFB_zk.system.js} +1 -1
  231. package/dist/swisspost-internet-header/p-BVux4d1J.system.js +1 -0
  232. package/dist/swisspost-internet-header/p-BWwWKRO5.js +1 -0
  233. package/dist/swisspost-internet-header/{p-IHvD9UqE.js → p-BXoqlxOG.js} +1 -1
  234. package/dist/swisspost-internet-header/p-BdiQsTQm.js +1 -0
  235. package/dist/swisspost-internet-header/{p-DHpwVMSs.system.js → p-CYBchhbg.system.js} +1 -1
  236. package/dist/swisspost-internet-header/{p-B6etRRpy.system.js → p-Ctf1S46w.system.js} +1 -1
  237. package/dist/swisspost-internet-header/p-R5BnOD0U.system.js +1 -1
  238. package/dist/swisspost-internet-header/p-a00eb4a0.entry.js +1 -0
  239. package/dist/swisspost-internet-header/p-a1237171.system.entry.js +1 -0
  240. package/dist/swisspost-internet-header/p-a12be1fd.system.entry.js +1 -0
  241. package/dist/swisspost-internet-header/p-a1ed3c1d.system.entry.js +1 -0
  242. package/dist/swisspost-internet-header/p-a21c305f.entry.js +1 -0
  243. package/dist/swisspost-internet-header/p-a4bfe46c.entry.js +1 -0
  244. package/dist/swisspost-internet-header/p-a9045c62.system.entry.js +1 -0
  245. package/dist/swisspost-internet-header/p-ac9d7b3f.system.entry.js +1 -0
  246. package/dist/swisspost-internet-header/p-bc0fcd50.entry.js +1 -0
  247. package/dist/swisspost-internet-header/p-bc30850c.system.entry.js +1 -0
  248. package/dist/swisspost-internet-header/p-bf861c95.entry.js +1 -0
  249. package/dist/swisspost-internet-header/{p-82b18f9d.entry.js → p-c36c9d88.entry.js} +1 -1
  250. package/dist/swisspost-internet-header/{p-6f3ba321.entry.js → p-cd3f5447.entry.js} +1 -1
  251. package/dist/swisspost-internet-header/p-d1eab2a3.entry.js +1 -0
  252. package/dist/swisspost-internet-header/p-d28a58ec.entry.js +1 -0
  253. package/dist/swisspost-internet-header/p-d390eac9.system.entry.js +1 -0
  254. package/dist/swisspost-internet-header/{p-9e6a4c52.system.entry.js → p-d52b2e2e.system.entry.js} +1 -1
  255. package/dist/swisspost-internet-header/p-d8384d86.system.entry.js +1 -0
  256. package/dist/swisspost-internet-header/p-dae00825.system.entry.js +1 -0
  257. package/dist/swisspost-internet-header/p-dcc3e62f.entry.js +1 -0
  258. package/dist/swisspost-internet-header/{p-a41bdf7a.entry.js → p-de1eae9a.entry.js} +1 -1
  259. package/dist/swisspost-internet-header/{p-d6b85bbe.system.entry.js → p-ef4aec35.system.entry.js} +1 -1
  260. package/dist/swisspost-internet-header/{p-c785b2d8.system.entry.js → p-f2794080.system.entry.js} +1 -1
  261. package/dist/swisspost-internet-header/{p-3975075b.system.entry.js → p-f78ac8af.system.entry.js} +1 -1
  262. package/dist/swisspost-internet-header/{p-6c9cb3b7.system.entry.js → p-f8f292cf.system.entry.js} +1 -1
  263. package/dist/swisspost-internet-header/p-fb0e4425.system.entry.js +1 -0
  264. package/dist/swisspost-internet-header/p-fd8106f1.system.entry.js +1 -0
  265. package/dist/swisspost-internet-header/p-fea21512.entry.js +1 -0
  266. package/dist/swisspost-internet-header/swisspost-internet-header.esm.js +1 -1
  267. package/package.json +9 -9
  268. package/dist/esm-es5/package-BBz9PVf0.js +0 -1
  269. package/dist/swisspost-internet-header/p-110f7b07.entry.js +0 -1
  270. package/dist/swisspost-internet-header/p-1587ba27.system.entry.js +0 -1
  271. package/dist/swisspost-internet-header/p-17c15d71.system.entry.js +0 -1
  272. package/dist/swisspost-internet-header/p-1d5fca41.system.entry.js +0 -1
  273. package/dist/swisspost-internet-header/p-211fa616.entry.js +0 -1
  274. package/dist/swisspost-internet-header/p-317104a6.system.entry.js +0 -1
  275. package/dist/swisspost-internet-header/p-34c89f09.system.entry.js +0 -1
  276. package/dist/swisspost-internet-header/p-370ecda3.entry.js +0 -1
  277. package/dist/swisspost-internet-header/p-429c457a.entry.js +0 -1
  278. package/dist/swisspost-internet-header/p-47cd54ff.entry.js +0 -1
  279. package/dist/swisspost-internet-header/p-495d1a20.system.entry.js +0 -1
  280. package/dist/swisspost-internet-header/p-5915d0c4.system.entry.js +0 -1
  281. package/dist/swisspost-internet-header/p-65457750.system.entry.js +0 -1
  282. package/dist/swisspost-internet-header/p-65f9efeb.entry.js +0 -1
  283. package/dist/swisspost-internet-header/p-6a35fb20.entry.js +0 -1
  284. package/dist/swisspost-internet-header/p-77a5472c.system.entry.js +0 -1
  285. package/dist/swisspost-internet-header/p-7949ff33.system.entry.js +0 -1
  286. package/dist/swisspost-internet-header/p-81a2ec15.system.entry.js +0 -1
  287. package/dist/swisspost-internet-header/p-85f59fc3.entry.js +0 -1
  288. package/dist/swisspost-internet-header/p-895b1160.system.entry.js +0 -1
  289. package/dist/swisspost-internet-header/p-8bce262b.entry.js +0 -1
  290. package/dist/swisspost-internet-header/p-8d9023ce.entry.js +0 -1
  291. package/dist/swisspost-internet-header/p-9dc1ecd1.entry.js +0 -1
  292. package/dist/swisspost-internet-header/p-9f0ff23c.entry.js +0 -1
  293. package/dist/swisspost-internet-header/p-BBz9PVf0.js +0 -1
  294. package/dist/swisspost-internet-header/p-a0ee4b1e.system.entry.js +0 -1
  295. package/dist/swisspost-internet-header/p-a41bc8b4.system.entry.js +0 -1
  296. package/dist/swisspost-internet-header/p-aa5d0b16.system.entry.js +0 -1
  297. package/dist/swisspost-internet-header/p-bdd376c5.system.entry.js +0 -1
  298. package/dist/swisspost-internet-header/p-c5e6949c.entry.js +0 -1
  299. package/dist/swisspost-internet-header/p-c6659dca.entry.js +0 -1
  300. package/dist/swisspost-internet-header/p-cc4571a9.entry.js +0 -1
  301. package/dist/swisspost-internet-header/p-cde7b565.system.entry.js +0 -1
  302. package/dist/swisspost-internet-header/p-cfd1f343.entry.js +0 -1
  303. package/dist/swisspost-internet-header/p-d35adc7b.system.entry.js +0 -1
  304. package/dist/swisspost-internet-header/p-d61814f0.system.entry.js +0 -1
  305. package/dist/swisspost-internet-header/p-d9741ab5.system.entry.js +0 -1
  306. package/dist/swisspost-internet-header/p-df83b4ce.entry.js +0 -1
  307. package/dist/swisspost-internet-header/p-e0f04375.entry.js +0 -1
  308. package/dist/swisspost-internet-header/p-e67350dd.entry.js +0 -1
  309. package/dist/swisspost-internet-header/p-eb76e336.system.entry.js +0 -1
  310. package/dist/swisspost-internet-header/p-fc08fd7d.system.entry.js +0 -1
@@ -1 +1 @@
1
- import{proxyCustomElement as t,HTMLElement as e,h as o,Host as s,transformTag as i}from"@stencil/core/internal/client";import{v as r}from"./package.js";import{d as a}from"./post-closebutton2.js";import{d as n}from"./post-icon2.js";import{d as c,P as p}from"./post-popovercontainer2.js";import{a as l}from"./get-focusable-children.js";import{O as d}from"./one-of.js";import{R as f}from"./required.js";import{T as m}from"./type.js";var h=function(t,e,o,s){var i,r=arguments.length,a=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,o):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,o,s);else for(var n=t.length-1;n>=0;n--)(i=t[n])&&(a=(r<3?i(a):r>3?i(e,o,a):i(e,o))||a);return r>3&&a&&Object.defineProperty(e,o,a),a};const b=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.placement="top",this.arrow=!0,this.breakpointChange=()=>{requestAnimationFrame((()=>this.updateEdgeGap()))}}async show(t){await this.popoverRef.show(t),this.focusFirstEl(),this.updateEdgeGap()}async hide(){this.popoverRef.hide()}async toggle(t,e){await this.popoverRef.toggle(t,e)&&(this.updateEdgeGap(),this.focusFirstEl())}connectedCallback(){globalThis.addEventListener("postBreakpoint:device",this.breakpointChange)}disconnectedCallback(){globalThis.removeEventListener("postBreakpoint:device",this.breakpointChange)}updateEdgeGap(){const t=this.host.shadowRoot?.querySelector("post-closebutton");if(!t)return;const e=t.getBoundingClientRect().width;e&&!Number.isNaN(e)&&(this.edgeGap=e/2)}focusFirstEl(){const t=l(this.host)[0];t&&t.focus()}render(){return o(s,{key:"0e57981004d99d528a4652598739afbf1208376c","data-version":r},o("post-popovercontainer",{key:"380838970ed2c62f9e21e95da6957e9ff36db31a",arrow:this.arrow,placement:this.placement,edgeGap:this.edgeGap,autoHide:!0,ref:t=>{t&&(this.popoverRef=t)}},o("div",{key:"77465a8e943f61492869a3e05cf03f90b9fd553c",class:"popover-container"},o("div",{key:"0ab4e621ecc58a9775c4a9b8dfba3d26eb577878",class:"popover-content"},o("slot",{key:"1b2d37d50ef23edad118abc5949686e59e15b931"})),o("post-closebutton",{key:"8c2138b22f49681d37d2f38f6fb6331c730849f3"},this.textClose))))}get host(){return this}static get style(){return"*{-webkit-box-sizing:border-box;box-sizing:border-box}:host{display:contents}.visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0}.popover-container{color:var(--post-current-fg);background-color:var(--post-current-bg);display:-ms-flexbox;display:flex;-ms-flex-align:self-start;align-items:self-start;padding:8px;min-width:160px;max-width:var(--post-popover-max-width, 280px)}.popover-content{padding:8px;-ms-flex-positive:1;flex-grow:1}post-closebutton{color-scheme:light}"}},[257,"post-popover",{placement:[1],textClose:[513,"text-close"],arrow:[4],edgeGap:[32],show:[64],hide:[64],toggle:[64]}]);h([d(p)],b.prototype,"placement",void 0),h([f(),m("string")],b.prototype,"textClose",void 0);const u=b,v=function(){"undefined"!=typeof customElements&&["post-popover","post-closebutton","post-icon","post-popovercontainer"].forEach((t=>{switch(t){case"post-popover":customElements.get(i(t))||customElements.define(i(t),b);break;case"post-closebutton":customElements.get(i(t))||a();break;case"post-icon":customElements.get(i(t))||n();break;case"post-popovercontainer":customElements.get(i(t))||c()}}))};export{u as PostPopover,v as defineCustomElement}
1
+ import{proxyCustomElement as r,HTMLElement as e,h as o,Host as t,transformTag as c}from"@stencil/core/internal/client";import{v as a}from"./package.js";import{d as s}from"./post-closebutton2.js";import{d as i}from"./post-icon2.js";import{d as l,P as n}from"./post-popovercontainer2.js";import{a as p}from"./get-focusable-children.js";import{O as h}from"./one-of.js";import{R as v}from"./required.js";import{T as g}from"./type.js";var b=function(r,e,o,t){var c,a=arguments.length,s=a<3?e:null===t?t=Object.getOwnPropertyDescriptor(e,o):t;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(r,e,o,t);else for(var i=r.length-1;i>=0;i--)(c=r[i])&&(s=(a<3?c(s):a>3?c(e,o,s):c(e,o))||s);return a>3&&s&&Object.defineProperty(e,o,s),s};const d=r(class extends e{constructor(r){super(),!1!==r&&this.__registerHost(),this.__attachShadow(),this.placement="top",this.arrow=!0,this.breakpointChange=()=>{requestAnimationFrame((()=>this.updateEdgeGap()))}}async show(r){await this.popoverRef.show(r),this.focusFirstEl(),this.updateEdgeGap()}async hide(){this.popoverRef.hide()}async toggle(r,e){await this.popoverRef.toggle(r,e)&&(this.updateEdgeGap(),this.focusFirstEl())}connectedCallback(){globalThis.addEventListener("postBreakpoint:device",this.breakpointChange)}disconnectedCallback(){globalThis.removeEventListener("postBreakpoint:device",this.breakpointChange)}updateEdgeGap(){const r=this.host.shadowRoot?.querySelector("post-closebutton");if(!r)return;const e=r.getBoundingClientRect().width;e&&!Number.isNaN(e)&&(this.edgeGap=e/2)}focusFirstEl(){const r=p(this.host)[0];r&&r.focus()}render(){return o(t,{key:"0e57981004d99d528a4652598739afbf1208376c","data-version":a},o("post-popovercontainer",{key:"cfa3e03284033c19317fab6a565cbcef0d4aa458",arrow:this.arrow,placement:this.placement,edgeGap:this.edgeGap,autoHide:!0,autoResize:!0,ref:r=>{r&&(this.popoverRef=r)}},o("div",{key:"758a7d16666581674c48043aaaf4b266c3d754b8",class:"popover-container"},o("div",{key:"60ab881499fa6cc016dc285f962f2dbee884adee",class:"popover-content"},o("slot",{key:"78b457120894b4117a7f4008f313e9a346f539ab"})),o("post-closebutton",{key:"5cc2cc1e36e8840f2e2729dcf8c15a211c95ec12"},this.textClose))))}get host(){return this}static get style(){return"@supports not (color: light-dark(black, white)){post-closebutton{--post-scheme-color-body-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-002);--post-scheme-color-body-bg:var(--post-scheme-color-body-bg-light, var(--post-core-color-sandgrey-080));--post-scheme-color-body-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-body-fg:var(--post-scheme-color-body-fg-light, var(--post-core-color-brand-white));--post-scheme-color-signal-success-dark-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-green);--post-scheme-color-signal-success-dark:var(--post-scheme-color-signal-success-dark-light, var(--post-core-color-notification-green));--post-scheme-color-signal-success-light-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-green-light);--post-scheme-color-signal-success-light:var(--post-scheme-color-signal-success-light-light, var(--post-core-color-notification-green-light));--post-scheme-color-signal-error-dark-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-red);--post-scheme-color-signal-error-dark:var(--post-scheme-color-signal-error-dark-light, var(--post-core-color-notification-red));--post-scheme-color-signal-error-light-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-red-light);--post-scheme-color-signal-error-light:var(--post-scheme-color-signal-error-light-light, var(--post-core-color-notification-red-light));--post-scheme-color-signal-warning-dark-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-orange);--post-scheme-color-signal-warning-dark:var(--post-scheme-color-signal-warning-dark-light, var(--post-core-color-notification-orange));--post-scheme-color-signal-warning-light-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-orange-light);--post-scheme-color-signal-warning-light:var(--post-scheme-color-signal-warning-light-light, var(--post-core-color-notification-orange-light));--post-scheme-color-signal-information-dark-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-blue);--post-scheme-color-signal-information-dark:var(--post-scheme-color-signal-information-dark-light, var(--post-core-color-notification-blue));--post-scheme-color-signal-information-light-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-blue-light);--post-scheme-color-signal-information-light:var(--post-scheme-color-signal-information-light-light, var(--post-core-color-notification-blue-light));--post-scheme-color-signal-success-solo-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-green);--post-scheme-color-signal-success-solo:var(--post-scheme-color-signal-success-solo-light, var(--post-core-color-notification-green-night));--post-scheme-color-signal-error-solo-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-red);--post-scheme-color-signal-error-solo:var(--post-scheme-color-signal-error-solo-light, var(--post-core-color-notification-red-night));--post-scheme-color-signal-info-solo-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-blue);--post-scheme-color-signal-info-solo:var(--post-scheme-color-signal-info-solo-light, var(--post-core-color-notification-blue-night));--post-scheme-color-signal-warning-solo-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-orange);--post-scheme-color-signal-warning-solo:var(--post-scheme-color-signal-warning-solo-light, var(--post-core-color-notification-orange-night));--post-scheme-color-interactive-button-primary-enabled-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-primary-enabled-fg:var(--post-scheme-color-interactive-button-primary-enabled-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-button-primary-enabled-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-button-primary-enabled-bg:var(--post-scheme-color-interactive-button-primary-enabled-bg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-primary-enabled-stroke-light:var(--post-fallback-prefers-light) var(--post-scheme-color-interactive-button-primary-enabled-bg);--post-scheme-color-interactive-button-primary-enabled-stroke:var(--post-scheme-color-interactive-button-primary-enabled-stroke-light, var(--post-scheme-color-interactive-button-primary-enabled-bg));--post-scheme-color-interactive-button-primary-enabled-fg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-button-primary-enabled-fg-inverted:var(--post-scheme-color-interactive-button-primary-enabled-fg-inverted-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-primary-enabled-bg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-primary-enabled-bg-inverted:var(--post-scheme-color-interactive-button-primary-enabled-bg-inverted-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-button-primary-enabled-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-primary-enabled-stroke-inverted:var(--post-scheme-color-interactive-button-primary-enabled-stroke-inverted-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-button-primary-hover-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-primary-hover-fg:var(--post-scheme-color-interactive-button-primary-hover-fg-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-button-primary-hover-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-button-primary-hover-bg:var(--post-scheme-color-interactive-button-primary-hover-bg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-primary-hover-stroke-light:var(--post-fallback-prefers-light) var(--post-scheme-color-interactive-button-primary-hover-bg);--post-scheme-color-interactive-button-primary-hover-stroke:var(--post-scheme-color-interactive-button-primary-hover-stroke-light, var(--post-scheme-color-interactive-button-primary-hover-bg));--post-scheme-color-interactive-button-primary-hover-fg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-button-primary-hover-fg-inverted:var(--post-scheme-color-interactive-button-primary-hover-fg-inverted-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-primary-hover-bg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-primary-hover-bg-inverted:var(--post-scheme-color-interactive-button-primary-hover-bg-inverted-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-button-primary-hover-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-primary-hover-stroke-inverted:var(--post-scheme-color-interactive-button-primary-hover-stroke-inverted-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-button-primary-disabled-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-button-primary-disabled-fg:var(--post-scheme-color-interactive-button-primary-disabled-fg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-primary-disabled-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-primary-disabled-bg:var(--post-scheme-color-interactive-button-primary-disabled-bg-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-button-primary-disabled-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-button-primary-disabled-stroke:var(--post-scheme-color-interactive-button-primary-disabled-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-primary-disabled-fg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-primary-disabled-fg-inverted:var(--post-scheme-color-interactive-button-primary-disabled-fg-inverted-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-button-primary-disabled-bg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-button-primary-disabled-bg-inverted:var(--post-scheme-color-interactive-button-primary-disabled-bg-inverted-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-primary-disabled-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-primary-disabled-stroke-inverted:var(--post-scheme-color-interactive-button-primary-disabled-stroke-inverted-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-button-secondary-enabled-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-button-secondary-enabled-fg:var(--post-scheme-color-interactive-button-secondary-enabled-fg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-secondary-enabled-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-secondary-enabled-bg:var(--post-scheme-color-interactive-button-secondary-enabled-bg-light, var(--post-core-color-colorless));--post-scheme-color-interactive-button-secondary-enabled-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-button-secondary-enabled-stroke:var(--post-scheme-color-interactive-button-secondary-enabled-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-secondary-enabled-fg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-secondary-enabled-fg-inverted:var(--post-scheme-color-interactive-button-secondary-enabled-fg-inverted-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-button-secondary-enabled-bg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-button-secondary-enabled-bg-inverted:var(--post-scheme-color-interactive-button-secondary-enabled-bg-inverted-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-secondary-enabled-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-secondary-enabled-stroke-inverted:var(--post-scheme-color-interactive-button-secondary-enabled-stroke-inverted-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-button-secondary-hover-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-button-secondary-hover-fg:var(--post-scheme-color-interactive-button-secondary-hover-fg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-secondary-hover-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-secondary-hover-bg:var(--post-scheme-color-interactive-button-secondary-hover-bg-light, var(--post-core-color-sandgrey-alpha-lightsand-10));--post-scheme-color-interactive-button-secondary-hover-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-button-secondary-hover-stroke:var(--post-scheme-color-interactive-button-secondary-hover-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-secondary-hover-fg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-secondary-hover-fg-inverted:var(--post-scheme-color-interactive-button-secondary-hover-fg-inverted-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-button-secondary-hover-bg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-alpha-lightsand-10);--post-scheme-color-interactive-button-secondary-hover-bg-inverted:var(--post-scheme-color-interactive-button-secondary-hover-bg-inverted-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-secondary-hover-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-secondary-hover-stroke-inverted:var(--post-scheme-color-interactive-button-secondary-hover-stroke-inverted-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-button-secondary-disabled-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-button-secondary-disabled-fg:var(--post-scheme-color-interactive-button-secondary-disabled-fg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-secondary-disabled-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-secondary-disabled-bg:var(--post-scheme-color-interactive-button-secondary-disabled-bg-light, var(--post-core-color-sandgrey-alpha-lightsand-30));--post-scheme-color-interactive-button-secondary-disabled-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-button-secondary-disabled-stroke:var(--post-scheme-color-interactive-button-secondary-disabled-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-secondary-disabled-fg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-secondary-disabled-fg-inverted:var(--post-scheme-color-interactive-button-secondary-disabled-fg-inverted-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-button-secondary-disabled-bg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-alpha-lightsand-30);--post-scheme-color-interactive-button-secondary-disabled-bg-inverted:var(--post-scheme-color-interactive-button-secondary-disabled-bg-inverted-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-secondary-disabled-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-secondary-disabled-stroke-inverted:var(--post-scheme-color-interactive-button-secondary-disabled-stroke-inverted-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-button-tertiary-enabled-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-button-tertiary-enabled-fg:var(--post-scheme-color-interactive-button-tertiary-enabled-fg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-tertiary-enabled-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-button-tertiary-enabled-bg:var(--post-scheme-color-interactive-button-tertiary-enabled-bg-light, var(--post-core-color-colorless));--post-scheme-color-interactive-button-tertiary-enabled-stroke-light:var(--post-fallback-prefers-light) var(--post-scheme-color-interactive-button-tertiary-enabled-bg);--post-scheme-color-interactive-button-tertiary-enabled-stroke:var(--post-scheme-color-interactive-button-tertiary-enabled-stroke-light, var(--post-scheme-color-interactive-button-tertiary-enabled-bg));--post-scheme-color-interactive-button-tertiary-enabled-fg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-tertiary-enabled-fg-inverted:var(--post-scheme-color-interactive-button-tertiary-enabled-fg-inverted-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-button-tertiary-enabled-bg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-button-tertiary-enabled-bg-inverted:var(--post-scheme-color-interactive-button-tertiary-enabled-bg-inverted-light, var(--post-core-color-colorless));--post-scheme-color-interactive-button-tertiary-enabled-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-button-tertiary-enabled-stroke-inverted:var(--post-scheme-color-interactive-button-tertiary-enabled-stroke-inverted-light, var(--post-core-color-colorless));--post-scheme-color-interactive-button-tertiary-hover-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-button-tertiary-hover-fg:var(--post-scheme-color-interactive-button-tertiary-hover-fg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-tertiary-hover-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-button-tertiary-hover-bg:var(--post-scheme-color-interactive-button-tertiary-hover-bg-light, var(--post-core-color-sandgrey-alpha-lightsand-10));--post-scheme-color-interactive-button-tertiary-hover-stroke-light:var(--post-fallback-prefers-light) var(--post-scheme-color-interactive-button-tertiary-hover-bg);--post-scheme-color-interactive-button-tertiary-hover-stroke:var(--post-scheme-color-interactive-button-tertiary-hover-stroke-light, var(--post-core-color-colorless));--post-scheme-color-interactive-button-tertiary-hover-fg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-tertiary-hover-fg-inverted:var(--post-scheme-color-interactive-button-tertiary-hover-fg-inverted-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-button-tertiary-hover-bg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-alpha-lightsand-10);--post-scheme-color-interactive-button-tertiary-hover-bg-inverted:var(--post-scheme-color-interactive-button-tertiary-hover-bg-inverted-light, var(--post-core-color-colorless));--post-scheme-color-interactive-button-tertiary-hover-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-button-tertiary-hover-stroke-inverted:var(--post-scheme-color-interactive-button-tertiary-hover-stroke-inverted-light, var(--post-core-color-colorless));--post-scheme-color-interactive-button-tertiary-disabled-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-button-tertiary-disabled-fg:var(--post-scheme-color-interactive-button-tertiary-disabled-fg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-tertiary-disabled-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-button-tertiary-disabled-bg:var(--post-scheme-color-interactive-button-tertiary-disabled-bg-light, var(--post-core-color-sandgrey-alpha-lightsand-30));--post-scheme-color-interactive-button-tertiary-disabled-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-button-tertiary-disabled-stroke:var(--post-scheme-color-interactive-button-tertiary-disabled-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-button-tertiary-disabled-fg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-tertiary-disabled-fg-inverted:var(--post-scheme-color-interactive-button-tertiary-disabled-fg-inverted-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-button-tertiary-disabled-bg-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-alpha-lightsand-30);--post-scheme-color-interactive-button-tertiary-disabled-bg-inverted:var(--post-scheme-color-interactive-button-tertiary-disabled-bg-inverted-light, var(--post-core-color-colorless));--post-scheme-color-interactive-button-tertiary-disabled-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-button-tertiary-disabled-stroke-inverted:var(--post-scheme-color-interactive-button-tertiary-disabled-stroke-inverted-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-focus-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-focus-stroke:var(--post-scheme-color-interactive-focus-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-focus-stroke-inverted-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-focus-stroke-inverted:var(--post-scheme-color-interactive-focus-stroke-inverted-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-primary-enabled-bg1-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-enabled-bg1:var(--post-scheme-color-interactive-primary-enabled-bg1-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-primary-enabled-fg1-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-primary-enabled-fg1:var(--post-scheme-color-interactive-primary-enabled-fg1-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-enabled-fg2-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-primary-enabled-fg2:var(--post-scheme-color-interactive-primary-enabled-fg2-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-primary-enabled-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-primary-enabled-stroke:var(--post-scheme-color-interactive-primary-enabled-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-enabled-fg3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-enabled-fg3:var(--post-scheme-color-interactive-primary-enabled-fg3-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-primary-enabled-bg2-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-primary-enabled-bg2:var(--post-scheme-color-interactive-primary-enabled-bg2-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-enabled-stroke3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-enabled-stroke3:var(--post-scheme-color-interactive-primary-enabled-stroke3-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-primary-enabled-bg3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-enabled-bg3:var(--post-scheme-color-interactive-primary-enabled-bg3-light, var(--post-core-color-colorless));--post-scheme-color-interactive-primary-enabled-stroke4-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-030);--post-scheme-color-interactive-primary-enabled-stroke4:var(--post-scheme-color-interactive-primary-enabled-stroke4-light, var(--post-core-color-sandgrey-030));--post-scheme-color-interactive-primary-enabled-bg4-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-primary-enabled-bg4:var(--post-scheme-color-interactive-primary-enabled-bg4-light, var(--post-core-color-colorless));--post-scheme-color-interactive-primary-enabled-stroke5-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-primary-enabled-stroke5:var(--post-scheme-color-interactive-primary-enabled-stroke5-light, var(--post-core-color-colorless));--post-scheme-color-interactive-primary-enabled-bg5-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-enabled-bg5:var(--post-scheme-color-interactive-primary-enabled-bg5-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-enabled-fg5-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-primary-enabled-fg5:var(--post-scheme-color-interactive-primary-enabled-fg5-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-primary-enabled-fg6-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-enabled-fg6:var(--post-scheme-color-interactive-primary-enabled-fg6-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-enabled-bg6-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-primary-enabled-bg6:var(--post-scheme-color-interactive-primary-enabled-bg6-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-primary-hover-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-hover-bg:var(--post-scheme-color-interactive-primary-hover-bg-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-primary-hover-fg1-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-primary-hover-fg1:var(--post-scheme-color-interactive-primary-hover-fg1-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-hover-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-primary-hover-stroke:var(--post-scheme-color-interactive-primary-hover-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-hover-fg3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-hover-fg3:var(--post-scheme-color-interactive-primary-hover-fg3-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-primary-hover-bg2-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-primary-hover-bg2:var(--post-scheme-color-interactive-primary-hover-bg2-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-hover-stroke3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-hover-stroke3:var(--post-scheme-color-interactive-primary-hover-stroke3-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-primary-hover-bg3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-hover-bg3:var(--post-scheme-color-interactive-primary-hover-bg3-light, var(--post-core-color-sandgrey-alpha-lightsand-20));--post-scheme-color-interactive-primary-hover-bg4-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-006);--post-scheme-color-interactive-primary-hover-bg4:var(--post-scheme-color-interactive-primary-hover-bg4-light, var(--post-core-color-sandgrey-006));--post-scheme-color-interactive-primary-hover-bg5-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-primary-hover-bg5:var(--post-scheme-color-interactive-primary-hover-bg5-light, var(--post-core-color-colorless));--post-scheme-color-interactive-primary-hover-bg7-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-006);--post-scheme-color-interactive-primary-hover-bg7:var(--post-scheme-color-interactive-primary-hover-bg7-light, var(--post-core-color-sandgrey-alpha-lightsand-10));--post-scheme-color-interactive-primary-hover-bg8-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-hover-bg8:var(--post-scheme-color-interactive-primary-hover-bg8-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-hover-fg4-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-primary-hover-fg4:var(--post-scheme-color-interactive-primary-hover-fg4-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-primary-disabled-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-disabled-bg:var(--post-scheme-color-interactive-primary-disabled-bg-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-primary-disabled-fg1-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-primary-disabled-fg1:var(--post-scheme-color-interactive-primary-disabled-fg1-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-disabled-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-primary-disabled-stroke:var(--post-scheme-color-interactive-primary-disabled-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-disabled-fg3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-disabled-fg3:var(--post-scheme-color-interactive-primary-disabled-fg3-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-primary-disabled-stroke2-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-primary-disabled-stroke2:var(--post-scheme-color-interactive-primary-disabled-stroke2-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-disabled-bg4-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-primary-disabled-bg4:var(--post-scheme-color-interactive-primary-disabled-bg4-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-disabled-stroke3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-disabled-stroke3:var(--post-scheme-color-interactive-primary-disabled-stroke3-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-primary-disabled-bg5-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-012);--post-scheme-color-interactive-primary-disabled-bg5:var(--post-scheme-color-interactive-primary-disabled-bg5-light, var(--post-core-color-sandgrey-alpha-lightsand-10));--post-scheme-color-interactive-primary-disabled-fg4-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-primary-disabled-fg4:var(--post-scheme-color-interactive-primary-disabled-fg4-light, var(--post-core-color-sandgrey-alpha-lightsand-60));--post-scheme-color-interactive-primary-disabled-stroke4-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-primary-disabled-stroke4:var(--post-scheme-color-interactive-primary-disabled-stroke4-light, var(--post-core-color-sandgrey-alpha-lightsand-60));--post-scheme-color-interactive-primary-disabled-bg6-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-disabled-bg6:var(--post-scheme-color-interactive-primary-disabled-bg6-light, var(--post-core-color-colorless));--post-scheme-color-interactive-primary-selected-bg1-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-selected-bg1:var(--post-scheme-color-interactive-primary-selected-bg1-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-primary-selected-fg1-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-primary-selected-fg1:var(--post-scheme-color-interactive-primary-selected-fg1-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-selected-stroke1-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-primary-selected-stroke1:var(--post-scheme-color-interactive-primary-selected-stroke1-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-selected-fg3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-selected-fg3:var(--post-scheme-color-interactive-primary-selected-fg3-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-primary-selected-bg2-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-green);--post-scheme-color-interactive-primary-selected-bg2:var(--post-scheme-color-interactive-primary-selected-bg2-light, var(--post-core-color-notification-green-light));--post-scheme-color-interactive-primary-selected-stroke4-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-green);--post-scheme-color-interactive-primary-selected-stroke4:var(--post-scheme-color-interactive-primary-selected-stroke4-light, var(--post-core-color-notification-green-light));--post-scheme-color-interactive-primary-selected-stroke3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-primary-selected-stroke3:var(--post-scheme-color-interactive-primary-selected-stroke3-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-primary-selected-bg4-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-primary-selected-bg4:var(--post-scheme-color-interactive-primary-selected-bg4-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-primary-selected-bg3-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-postyellow);--post-scheme-color-interactive-primary-selected-bg3:var(--post-scheme-color-interactive-primary-selected-bg3-light, var(--post-core-color-brand-postyellow));--post-scheme-color-interactive-notification-info-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-notification-info-fg:var(--post-scheme-color-interactive-notification-info-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-notification-info-bg-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-information-light);--post-scheme-color-interactive-notification-info-bg:var(--post-scheme-color-interactive-notification-info-bg-light, var(--post-scheme-color-signal-information-light));--post-scheme-color-interactive-notification-info-icon-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-information-dark);--post-scheme-color-interactive-notification-info-icon:var(--post-scheme-color-interactive-notification-info-icon-light, var(--post-scheme-color-signal-information-dark));--post-scheme-color-interactive-notification-info-stroke-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-information-dark);--post-scheme-color-interactive-notification-info-stroke:var(--post-scheme-color-interactive-notification-info-stroke-light, var(--post-scheme-color-signal-information-dark));--post-scheme-color-interactive-notification-success-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-notification-success-fg:var(--post-scheme-color-interactive-notification-success-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-notification-success-bg-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-success-light);--post-scheme-color-interactive-notification-success-bg:var(--post-scheme-color-interactive-notification-success-bg-light, var(--post-scheme-color-signal-success-light));--post-scheme-color-interactive-notification-success-icon-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-success-dark);--post-scheme-color-interactive-notification-success-icon:var(--post-scheme-color-interactive-notification-success-icon-light, var(--post-scheme-color-signal-success-dark));--post-scheme-color-interactive-notification-success-stroke-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-success-dark);--post-scheme-color-interactive-notification-success-stroke:var(--post-scheme-color-interactive-notification-success-stroke-light, var(--post-scheme-color-signal-success-dark));--post-scheme-color-interactive-notification-warning-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-notification-warning-fg:var(--post-scheme-color-interactive-notification-warning-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-notification-warning-bg-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-warning-light);--post-scheme-color-interactive-notification-warning-bg:var(--post-scheme-color-interactive-notification-warning-bg-light, var(--post-scheme-color-signal-warning-light));--post-scheme-color-interactive-notification-warning-icon-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-warning-dark);--post-scheme-color-interactive-notification-warning-icon:var(--post-scheme-color-interactive-notification-warning-icon-light, var(--post-scheme-color-signal-warning-dark));--post-scheme-color-interactive-notification-warning-stroke-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-warning-dark);--post-scheme-color-interactive-notification-warning-stroke:var(--post-scheme-color-interactive-notification-warning-stroke-light, var(--post-scheme-color-signal-warning-dark));--post-scheme-color-interactive-notification-error-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-notification-error-fg:var(--post-scheme-color-interactive-notification-error-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-notification-error-bg-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-error-light);--post-scheme-color-interactive-notification-error-bg:var(--post-scheme-color-interactive-notification-error-bg-light, var(--post-scheme-color-signal-error-light));--post-scheme-color-interactive-notification-error-icon-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-error-dark);--post-scheme-color-interactive-notification-error-icon:var(--post-scheme-color-interactive-notification-error-icon-light, var(--post-scheme-color-signal-error-dark));--post-scheme-color-interactive-notification-error-stroke-light:var(--post-fallback-prefers-light) var(--post-scheme-color-signal-error-dark);--post-scheme-color-interactive-notification-error-stroke:var(--post-scheme-color-interactive-notification-error-stroke-light, var(--post-scheme-color-signal-error-dark));--post-scheme-color-interactive-input-enabled-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-input-enabled-bg:var(--post-scheme-color-interactive-input-enabled-bg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-input-enabled-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-input-enabled-fg:var(--post-scheme-color-interactive-input-enabled-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-input-enabled-border-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-input-enabled-border:var(--post-scheme-color-interactive-input-enabled-border-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-input-hover-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-interactive-input-hover-bg:var(--post-scheme-color-interactive-input-hover-bg-light, var(--post-core-color-brand-white));--post-scheme-color-interactive-input-hover-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-input-hover-fg:var(--post-scheme-color-interactive-input-hover-fg-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-input-hover-border-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-input-hover-border:var(--post-scheme-color-interactive-input-hover-border-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-input-disabled-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-colorless);--post-scheme-color-interactive-input-disabled-bg:var(--post-scheme-color-interactive-input-disabled-bg-light, var(--post-core-color-colorless));--post-scheme-color-interactive-input-disabled-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-input-disabled-fg:var(--post-scheme-color-interactive-input-disabled-fg-light, var(--post-core-color-sandgrey-alpha-lightsand-60));--post-scheme-color-interactive-input-disabled-border-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-input-disabled-border:var(--post-scheme-color-interactive-input-disabled-border-light, var(--post-core-color-sandgrey-alpha-lightsand-60));--post-scheme-color-interactive-card-hover-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-020);--post-scheme-color-interactive-card-hover-bg:var(--post-scheme-color-interactive-card-hover-bg-light, var(--post-core-color-sandgrey-020));--post-scheme-color-interactive-card-hover-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-card-hover-fg:var(--post-scheme-color-interactive-card-hover-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-tabs-selected-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-interactive-tabs-selected-fg:var(--post-scheme-color-interactive-tabs-selected-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-interactive-tabs-disabled-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-tabs-disabled-fg:var(--post-scheme-color-interactive-tabs-disabled-fg-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-tabs-disabled-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-interactive-tabs-disabled-stroke:var(--post-scheme-color-interactive-tabs-disabled-stroke-light, var(--post-core-color-sandgrey-060));--post-scheme-color-interactive-tabs-selected-hovered-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-tabs-selected-hovered-fg:var(--post-scheme-color-interactive-tabs-selected-hovered-fg-light, var(--post-core-color-sandgrey-070));--post-scheme-color-interactive-tabs-selected-hovered-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-070);--post-scheme-color-interactive-tabs-selected-hovered-stroke:var(--post-scheme-color-interactive-tabs-selected-hovered-stroke-light, var(--post-core-color-sandgrey-002));--post-scheme-color-surface-default-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-002);--post-scheme-color-surface-default-bg:var(--post-scheme-color-surface-default-bg-light, var(--post-core-color-sandgrey-080));--post-scheme-color-surface-default-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-surface-default-fg:var(--post-scheme-color-surface-default-fg-light, var(--post-core-color-brand-white));--post-scheme-color-surface-default-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-surface-default-stroke:var(--post-scheme-color-surface-default-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-surface-accent1-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-surface-accent1-bg:var(--post-scheme-color-surface-accent1-bg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-surface-accent1-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-surface-accent1-fg:var(--post-scheme-color-surface-accent1-fg-light, var(--post-core-color-brand-white));--post-scheme-color-surface-alternate-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-006);--post-scheme-color-surface-alternate-bg:var(--post-scheme-color-surface-alternate-bg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-surface-alternate-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-surface-alternate-fg:var(--post-scheme-color-surface-alternate-fg-light, var(--post-core-color-brand-white));--post-scheme-color-surface-alternate-secondary-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-surface-alternate-secondary-bg:var(--post-scheme-color-surface-alternate-secondary-bg-light, var(--post-core-color-brand-white));--post-scheme-color-surface-brand-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-postyellow);--post-scheme-color-surface-brand-bg:var(--post-scheme-color-surface-brand-bg-light, var(--post-core-color-brand-postyellow));--post-scheme-color-surface-brand-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-surface-brand-fg:var(--post-scheme-color-surface-brand-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-surface-brand-fg-accent-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-scheme-color-surface-brand-fg-accent:var(--post-scheme-color-surface-brand-fg-accent-light, var(--post-core-color-sandgrey-100));--post-scheme-color-surface-brand-secondary-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-surface-brand-secondary-bg:var(--post-scheme-color-surface-brand-secondary-bg-light, var(--post-core-color-brand-white));--post-scheme-color-surface-accent-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-080);--post-scheme-color-surface-accent-bg:var(--post-scheme-color-surface-accent-bg-light, var(--post-core-color-sandgrey-002));--post-scheme-color-surface-accent-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-surface-accent-fg:var(--post-scheme-color-surface-accent-fg-light, var(--post-core-color-sandgrey-100));--post-scheme-color-surface-accent-fg-accent-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-postyellow);--post-scheme-color-surface-accent-fg-accent:var(--post-scheme-color-surface-accent-fg-accent-light, var(--post-core-color-sandgrey-100));--post-scheme-color-badge-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-notification-red);--post-scheme-color-badge-bg:var(--post-scheme-color-badge-bg-light, var(--post-core-color-notification-red));--post-scheme-color-badge-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-badge-fg:var(--post-scheme-color-badge-fg-light, var(--post-core-color-brand-white));--post-scheme-color-badge-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-scheme-color-badge-stroke:var(--post-scheme-color-badge-stroke-light, var(--post-core-color-brand-white));--post-scheme-color-popover-hover-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-020);--post-scheme-color-popover-hover:var(--post-scheme-color-popover-hover-light, var(--post-core-color-sandgrey-020));--post-scheme-color-divider-border-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-060);--post-scheme-color-divider-border:var(--post-scheme-color-divider-border-light, var(--post-core-color-sandgrey-050));--post-scheme-color-backdrop-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-alpha-darksand-80);--post-scheme-color-backdrop-bg:var(--post-scheme-color-backdrop-bg-light, var(--post-core-color-sandgrey-alpha-darksand-80));--post-scheme-color-datepicker-header-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-012);--post-scheme-color-datepicker-header-bg:var(--post-scheme-color-datepicker-header-bg-light, var(--post-core-color-sandgrey-070));--post-cargo-scheme-color-surface-default-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-002);--post-cargo-scheme-color-surface-default-bg:var(--post-cargo-scheme-color-surface-default-bg-light, var(--post-core-color-sandgrey-080));--post-cargo-scheme-color-surface-default-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-cargo-scheme-color-surface-default-fg:var(--post-cargo-scheme-color-surface-default-fg-light, var(--post-core-color-brand-white));--post-cargo-scheme-color-surface-default-stroke-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-cargo-scheme-color-surface-default-stroke:var(--post-cargo-scheme-color-surface-default-stroke-light, var(--post-core-color-brand-white));--post-cargo-scheme-color-surface-accent1-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-cargo-scheme-color-surface-accent1-bg:var(--post-cargo-scheme-color-surface-accent1-bg-light, var(--post-core-color-sandgrey-100));--post-cargo-scheme-color-surface-accent1-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-cargo-scheme-color-surface-accent1-fg:var(--post-cargo-scheme-color-surface-accent1-fg-light, var(--post-core-color-brand-white));--post-cargo-scheme-color-surface-alternate-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-006);--post-cargo-scheme-color-surface-alternate-bg:var(--post-cargo-scheme-color-surface-alternate-bg-light, var(--post-core-color-sandgrey-100));--post-cargo-scheme-color-surface-alternate-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-cargo-scheme-color-surface-alternate-fg:var(--post-cargo-scheme-color-surface-alternate-fg-light, var(--post-core-color-brand-white));--post-cargo-scheme-color-surface-brand-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-cargo-green);--post-cargo-scheme-color-surface-brand-bg:var(--post-cargo-scheme-color-surface-brand-bg-light, var(--post-core-color-cargo-green));--post-cargo-scheme-color-surface-brand-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-cargo-scheme-color-surface-brand-fg:var(--post-cargo-scheme-color-surface-brand-fg-light, var(--post-core-color-brand-white));--post-cargo-scheme-color-surface-brand-fg-accent-light:var(--post-fallback-prefers-light) var(--post-core-color-cargo-blue);--post-cargo-scheme-color-surface-brand-fg-accent:var(--post-cargo-scheme-color-surface-brand-fg-accent-light, var(--post-core-color-cargo-blue));--post-cargo-scheme-color-surface-brand-secondary-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-cargo-scheme-color-surface-brand-secondary-bg:var(--post-cargo-scheme-color-surface-brand-secondary-bg-light, var(--post-core-color-brand-white));--post-cargo-scheme-color-surface-accent-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-cargo-blue);--post-cargo-scheme-color-surface-accent-bg:var(--post-cargo-scheme-color-surface-accent-bg-light, var(--post-core-color-cargo-blue));--post-cargo-scheme-color-surface-accent-fg-light:var(--post-fallback-prefers-light) var(--post-core-color-sandgrey-100);--post-cargo-scheme-color-surface-accent-fg:var(--post-cargo-scheme-color-surface-accent-fg-light, var(--post-core-color-sandgrey-100));--post-cargo-scheme-color-surface-accent-fg-accent-light:var(--post-fallback-prefers-light) var(--post-core-color-cargo-green);--post-cargo-scheme-color-surface-accent-fg-accent:var(--post-cargo-scheme-color-surface-accent-fg-accent-light, var(--post-core-color-cargo-green));--post-cargo-scheme-color-surface-accent-secondary-bg-light:var(--post-fallback-prefers-light) var(--post-core-color-brand-white);--post-cargo-scheme-color-surface-accent-secondary-bg:var(--post-cargo-scheme-color-surface-accent-secondary-bg-light, var(--post-core-color-brand-white))}}*{-webkit-box-sizing:border-box;box-sizing:border-box}:host{display:contents}.visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0}.popover-container{color:var(--post-current-fg);background-color:var(--post-current-bg);display:-ms-flexbox;display:flex;-ms-flex-align:self-start;align-items:self-start;padding:8px;max-width:var(--post-popover-max-width, 280px);max-height:100%;overflow-y:auto;-ms-scroll-chaining:none;overscroll-behavior:contain}.popover-content{padding:8px;-ms-flex-positive:1;flex-grow:1}@supports (color: light-dark(black, white)){post-closebutton{color-scheme:light}}@supports not (color: light-dark(black, white)){post-closebutton{}}post-popovercontainer::part(post-popovercontainer-content){min-width:160px}"}},[257,"post-popover",{placement:[1],textClose:[513,"text-close"],arrow:[4],edgeGap:[32],show:[64],hide:[64],toggle:[64]}]);b([h(n)],d.prototype,"placement",void 0),b([v(),g("string")],d.prototype,"textClose",void 0);const m=d,f=function(){"undefined"!=typeof customElements&&["post-popover","post-closebutton","post-icon","post-popovercontainer"].forEach((r=>{switch(r){case"post-popover":customElements.get(c(r))||customElements.define(c(r),d);break;case"post-closebutton":customElements.get(c(r))||s();break;case"post-icon":customElements.get(c(r))||i();break;case"post-popovercontainer":customElements.get(c(r))||l()}}))};export{m as PostPopover,f as defineCustomElement}
@@ -1 +1 @@
1
- import{proxyCustomElement as t,HTMLElement as e,createEvent as o,Build as n,h as r,Host as s,transformTag as i}from"@stencil/core/internal/client";import{v as a}from"./package.js";import{O as p}from"./one-of.js";import{T as c}from"./type.js";const l=["top","right","bottom","left","top-start","top-end","right-start","right-end","bottom-start","bottom-end","left-start","left-end"],f=["top","right","bottom","left"],u=Math.min,d=Math.max,h=Math.round,v=Math.floor,m=t=>({x:t,y:t}),g={left:"right",right:"left",bottom:"top",top:"bottom"};function x(t,e,o){return d(t,u(e,o))}function w(t,e){return"function"==typeof t?t(e):t}function b(t){return t.split("-")[0]}function y(t){return t.split("-")[1]}function S(t){return"x"===t?"y":"x"}function k(t){return"y"===t?"height":"width"}function E(t){const e=t[0];return"t"===e||"b"===e?"y":"x"}function T(t){return S(E(t))}function M(t){return t.includes("start")?t.replace("start","end"):t.replace("end","start")}const A=["left","right"],O=["right","left"],H=["top","bottom"],L=["bottom","top"];function $(t){const e=b(t);return g[e]+t.slice(e.length)}function C(t){return"number"!=typeof t?function(t){var e,o,n,r;return{top:null!=(e=t.top)?e:0,right:null!=(o=t.right)?o:0,bottom:null!=(n=t.bottom)?n:0,left:null!=(r=t.left)?r:0}}(t):{top:t,right:t,bottom:t,left:t}}function D(t){const{x:e,y:o,width:n,height:r}=t;return{width:n,height:r,top:o,left:e,right:e+n,bottom:o+r,x:e,y:o}}function R(t,e,o){let{reference:n,floating:r}=t;const s=E(e),i=T(e),a=k(i),p=b(e),c="y"===s,l=n.x+n.width/2-r.width/2,f=n.y+n.height/2-r.height/2,u=n[a]/2-r[a]/2;let d;switch(p){case"top":d={x:l,y:n.y-r.height};break;case"bottom":d={x:l,y:n.y+n.height};break;case"right":d={x:n.x+n.width,y:f};break;case"left":d={x:n.x-r.width,y:f};break;default:d={x:n.x,y:n.y}}const h=y(e);return h&&(d[i]+=u*("end"===h?1:-1)*(o&&c?-1:1)),d}async function z(t,e){var o;void 0===e&&(e={});const{x:n,y:r,platform:s,rects:i,elements:a,strategy:p}=t,{boundary:c="clippingAncestors",rootBoundary:l="viewport",elementContext:f="floating",altBoundary:u=!1,padding:d=0}=w(e,t),h=C(d),v=a[u?"floating"===f?"reference":"floating":f],m=D(await s.getClippingRect({element:null==(o=await(null==s.isElement?void 0:s.isElement(v)))||o?v:v.contextElement||await(null==s.getDocumentElement?void 0:s.getDocumentElement(a.floating)),boundary:c,rootBoundary:l,strategy:p})),g="floating"===f?{x:n,y:r,width:i.floating.width,height:i.floating.height}:i.reference,x=await(null==s.getOffsetParent?void 0:s.getOffsetParent(a.floating)),b=await(null==s.isElement?void 0:s.isElement(x))&&await(null==s.getScale?void 0:s.getScale(x))||{x:1,y:1},y=D(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:g,offsetParent:x,strategy:p}):g);return{top:(m.top-y.top+h.top)/b.y,bottom:(y.bottom-m.bottom+h.bottom)/b.y,left:(m.left-y.left+h.left)/b.x,right:(y.right-m.right+h.right)/b.x}}function j(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function F(t){return f.some((e=>t[e]>=0))}function P(t){const e=u(...t.map((t=>t.left))),o=u(...t.map((t=>t.top)));return{x:e,y:o,width:d(...t.map((t=>t.right)))-e,height:d(...t.map((t=>t.bottom)))-o}}const W=new Set(["left","top"]);function B(){return"undefined"!=typeof window}function q(t){return G(t)?(t.nodeName||"").toLowerCase():"#document"}function I(t){var e;return(null==t||null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function N(t){var e;return null==(e=(G(t)?t.ownerDocument:t.document)||window.document)?void 0:e.documentElement}function G(t){return!!B()&&(t instanceof Node||t instanceof I(t).Node)}function V(t){return!!B()&&(t instanceof Element||t instanceof I(t).Element)}function X(t){return!!B()&&(t instanceof HTMLElement||t instanceof I(t).HTMLElement)}function Y(t){return!(!B()||"undefined"==typeof ShadowRoot)&&(t instanceof ShadowRoot||t instanceof I(t).ShadowRoot)}function _(t){const{overflow:e,overflowX:o,overflowY:n,display:r}=rt(t);return/auto|scroll|overlay|hidden|clip/.test(e+n+o)&&"inline"!==r&&"contents"!==r}function J(t){return/^(table|td|th)$/.test(q(t))}function K(t){try{if(t.matches(":popover-open"))return!0}catch(t){}try{return t.matches(":modal")}catch(t){return!1}}const Q=/transform|translate|scale|rotate|perspective|filter/,U=/paint|layout|strict|content/,Z=t=>!!t&&"none"!==t;let tt;function et(t){const e=V(t)?rt(t):t;return Z(e.transform)||Z(e.translate)||Z(e.scale)||Z(e.rotate)||Z(e.perspective)||!ot()&&(Z(e.backdropFilter)||Z(e.filter))||Q.test(e.willChange||"")||U.test(e.contain||"")}function ot(){return null==tt&&(tt="undefined"!=typeof CSS&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),tt}function nt(t){return/^(html|body|#document)$/.test(q(t))}function rt(t){return I(t).getComputedStyle(t)}function st(t){return V(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function it(t){if("html"===q(t))return t;const e=t.assignedSlot||t.parentNode||Y(t)&&t.host||N(t);return Y(e)?e.host:e}function at(t){const e=it(t);return nt(e)?(t.ownerDocument||t).body:X(e)&&_(e)?e:at(e)}function pt(t,e,o){var n;void 0===e&&(e=[]),void 0===o&&(o=!0);const r=at(t),s=r===(null==(n=t.ownerDocument)?void 0:n.body),i=I(r);if(s){const t=ct(i);return e.concat(i,i.visualViewport||[],_(r)?r:[],t&&o?pt(t):[])}return e.concat(r,pt(r,[],o))}function ct(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function lt(t){const e=rt(t);let o=parseFloat(e.width)||0,n=parseFloat(e.height)||0;const r=X(t),s=r?t.offsetWidth:o,i=r?t.offsetHeight:n,a=h(o)!==s||h(n)!==i;return a&&(o=s,n=i),{width:o,height:n,$:a}}function ft(t){return V(t)?t:t.contextElement}function ut(t){const e=ft(t);if(!X(e))return m(1);const o=e.getBoundingClientRect(),{width:n,height:r,$:s}=lt(e);let i=(s?h(o.width):o.width)/n,a=(s?h(o.height):o.height)/r;return i&&Number.isFinite(i)||(i=1),a&&Number.isFinite(a)||(a=1),{x:i,y:a}}const dt=m(0);function ht(t){const e=I(t);return ot()&&e.visualViewport?{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}:dt}function vt(t,e,o,n){void 0===e&&(e=!1),void 0===o&&(o=!1);const r=t.getBoundingClientRect(),s=ft(t);let i=m(1);e&&(n?V(n)&&(i=ut(n)):i=ut(t));const a=function(t,e,o){return void 0===e&&(e=!1),!!o&&e&&o===I(t)}(s,o,n)?ht(s):m(0);let p=(r.left+a.x)/i.x,c=(r.top+a.y)/i.y,l=r.width/i.x,f=r.height/i.y;if(s&&n){const t=I(s),e=V(n)?I(n):n;let o=t,r=ct(o);for(;r&&e!==o;){const t=ut(r),e=r.getBoundingClientRect(),n=rt(r),s=e.left+(r.clientLeft+parseFloat(n.paddingLeft))*t.x,i=e.top+(r.clientTop+parseFloat(n.paddingTop))*t.y;p*=t.x,c*=t.y,l*=t.x,f*=t.y,p+=s,c+=i,o=I(r),r=ct(o)}}return D({width:l,height:f,x:p,y:c})}function mt(t,e){const o=st(t).scrollLeft;return e?e.left+o:vt(N(t)).left+o}function gt(t,e){const o=t.getBoundingClientRect();return{x:o.left+e.scrollLeft-mt(t,o),y:o.top+e.scrollTop}}function xt(t,e,o){let n;if("viewport"===e||"layoutViewport"===e)n=function(t,e,o){void 0===o&&(o="viewport");const n="layoutViewport"===o,r=I(t),s=N(t),i=r.visualViewport;let a=s.clientWidth,p=s.clientHeight,c=0,l=0;if(i){const t=!ot()||"fixed"===e;n?t||(c=-i.offsetLeft,l=-i.offsetTop):(a=i.width,p=i.height,t&&(c=i.offsetLeft,l=i.offsetTop))}if(mt(s)<=0){const t=s.ownerDocument,e=t.body,o=getComputedStyle(e),n="CSS1Compat"===t.compatMode&&parseFloat(o.marginLeft)+parseFloat(o.marginRight)||0,r=Math.abs(s.clientWidth-e.clientWidth-n),i="stable both-edges"===getComputedStyle(s).scrollbarGutter?r/2:r;i<=25&&(a-=i)}return{width:a,height:p,x:c,y:l}}(t,o,e);else if("document"===e)n=function(t){const e=st(t),o=t.ownerDocument.body,n=d(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),r=d(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let s=-e.scrollLeft+mt(t);const i=-e.scrollTop;return"rtl"===rt(o).direction&&(s+=d(t.clientWidth,o.clientWidth)-n),{width:n,height:r,x:s,y:i}}(N(t));else if(V(e))n=function(t,e){const o=vt(t,!0,"fixed"===e),n=o.top+t.clientTop,r=o.left+t.clientLeft,s=ut(t);return{width:t.clientWidth*s.x,height:t.clientHeight*s.y,x:r*s.x,y:n*s.y}}(e,o);else{const o=ht(t);n={x:e.x-o.x,y:e.y-o.y,width:e.width,height:e.height}}return D(n)}function wt(t,e,o){const n=X(e),r=N(e),s="fixed"===o,i=vt(t,!0,s,e);let a={scrollLeft:0,scrollTop:0};const p=m(0);if((n||!s)&&(("body"!==q(e)||_(r))&&(a=st(e)),n)){const t=vt(e,!0,s,e);p.x=t.x+e.clientLeft,p.y=t.y+e.clientTop}!n&&r&&(p.x=mt(r));const c=!r||n||s?m(0):gt(r,a);return{x:i.left+a.scrollLeft-p.x-c.x,y:i.top+a.scrollTop-p.y-c.y,width:i.width,height:i.height}}function bt(t){return"static"===rt(t).position}function yt(t,e){if(!X(t)||"fixed"===rt(t).position)return null;if(e)return e(t);let o=t.offsetParent;return N(t)===o&&(o=o.ownerDocument.body),o}function St(t,e){const o=I(t);if(K(t))return o;if(!X(t)){let e=it(t);for(;e&&!nt(e);){if(V(e)&&!bt(e))return e;e=it(e)}return o}let n=yt(t,e);for(;n&&J(n)&&bt(n);)n=yt(n,e);return n&&nt(n)&&bt(n)&&!et(n)?o:n||function(t){let e=it(t);for(;X(e)&&!nt(e);){if(et(e))return e;if(K(e))return null;e=it(e)}return null}(t)||o}const kt={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{elements:e,rect:o,offsetParent:n,strategy:r}=t;const s="fixed"===r,i=N(n),a=!!e&&K(e.floating);if(n===i||a&&s)return o;let p={scrollLeft:0,scrollTop:0},c=m(1);const l=m(0),f=X(n);if((f||!s)&&(("body"!==q(n)||_(i))&&(p=st(n)),f)){const t=vt(n);c=ut(n),l.x=t.x+n.clientLeft,l.y=t.y+n.clientTop}const u=!i||f||s?m(0):gt(i,p);return{width:o.width*c.x,height:o.height*c.y,x:o.x*c.x-p.scrollLeft*c.x+l.x+u.x,y:o.y*c.y-p.scrollTop*c.y+l.y+u.y}},getDocumentElement:N,getClippingRect:function(t){let{element:e,boundary:o,rootBoundary:n,strategy:r}=t;const s=[..."clippingAncestors"===o?K(e)?[]:function(t,e){const o=e.get(t);if(o)return o;let n=pt(t,[],!1).filter((t=>V(t)&&"body"!==q(t))),r=null;const s="fixed"===rt(t).position;let i=s?it(t):t;for(;V(i)&&!nt(i);){const t=rt(i),e=et(i),o=r?r.position:s?"fixed":"";e||"fixed"!==o&&("absolute"!==o||"static"!==t.position)?r=t:n=n.filter((t=>t!==i)),i=it(i)}return e.set(t,n),n}(e,this._c):[].concat(o),n],i=xt(e,s[0],r);let a=i.top,p=i.right,c=i.bottom,l=i.left;for(let t=1;t<s.length;t++){const o=xt(e,s[t],r);a=d(o.top,a),p=u(o.right,p),c=u(o.bottom,c),l=d(o.left,l)}return{width:p-l,height:c-a,x:l,y:a}},getOffsetParent:St,getElementRects:async function(t){const e=this.getOffsetParent||St,o=this.getDimensions,n=await o(t.floating);return{reference:wt(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}},getClientRects:function(t){return t.getClientRects?Array.from(t.getClientRects()):[]},getDimensions:function(t){const{width:e,height:o}=lt(t);return{width:e,height:o}},getScale:ut,isElement:V,isRTL:function(t){return"rtl"===rt(t).direction}};function Et(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}const Tt=function(t){return void 0===t&&(t=0),{name:"offset",options:t,async fn(e){var o,n;const{x:r,y:s,placement:i,middlewareData:a}=e,p=await async function(t,e){const{placement:o,platform:n,elements:r}=t,s=await(null==n.isRTL?void 0:n.isRTL(r.floating)),i=b(o),a=y(o),p="y"===E(o),c=W.has(i)?-1:1,l=s&&p?-1:1,f=w(e,t);let{mainAxis:u,crossAxis:d,alignmentAxis:h}="number"==typeof f?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return a&&"number"==typeof h&&(d="end"===a?-1*h:h),p?{x:d*l,y:u*c}:{x:u*c,y:d*l}}(e,t);return i===(null==(o=a.offset)?void 0:o.placement)&&null!=(n=a.arrow)&&n.alignmentOffset?{}:{x:r+p.x,y:s+p.y,data:{...p,placement:i}}}}},Mt=function(t){return void 0===t&&(t={}),{name:"flip",options:t,async fn(e){var o,n;const{placement:r,middlewareData:s,rects:i,initialPlacement:a,platform:p,elements:c}=e,{mainAxis:l=!0,crossAxis:f=!0,fallbackPlacements:u,fallbackStrategy:d="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:v=!0,...m}=w(t,e);if(null!=(o=s.arrow)&&o.alignmentOffset)return{};const g=b(r),x=E(a),S=b(a)===a,C=await(null==p.isRTL?void 0:p.isRTL(c.floating)),D=u||(S||!v?[$(a)]:function(t){const e=$(t);return[M(t),e,M(e)]}(a)),R="none"!==h;!u&&R&&D.push(...function(t,e,o,n){const r=y(t);let s=function(t,e,o){switch(t){case"top":case"bottom":return o?e?O:A:e?A:O;case"left":case"right":return e?H:L;default:return[]}}(b(t),"start"===o,n);return r&&(s=s.map((t=>t+"-"+r)),e&&(s=s.concat(s.map(M)))),s}(a,v,h,C));const z=[a,...D],j=await p.detectOverflow(e,m),F=[];let P=(null==(n=s.flip)?void 0:n.overflows)||[];if(l&&F.push(j[g]),f){const t=function(t,e,o){void 0===o&&(o=!1);const n=y(t),r=T(t),s=k(r);let i="x"===r?n===(o?"end":"start")?"right":"left":"start"===n?"bottom":"top";return e.reference[s]>e.floating[s]&&(i=$(i)),[i,$(i)]}(r,i,C);F.push(j[t[0]],j[t[1]])}if(P=[...P,{placement:r,overflows:F}],!F.every((t=>t<=0))){var W,B;const t=((null==(W=s.flip)?void 0:W.index)||0)+1,e=z[t];if(e&&("alignment"!==f||x===E(e)||P.every((t=>E(t.placement)!==x||t.overflows[0]>0))))return{data:{index:t,overflows:P},reset:{placement:e}};let o=null==(B=P.filter((t=>t.overflows[0]<=0)).sort(((t,e)=>t.overflows[1]-e.overflows[1]))[0])?void 0:B.placement;if(!o)switch(d){case"bestFit":{var q;const t=null==(q=P.filter((t=>{if(R){const e=E(t.placement);return e===x||"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:q[0];t&&(o=t);break}case"initialPlacement":o=a}if(r!==o)return{reset:{placement:o}}}return{}}}},At=function(t){return void 0===t&&(t={}),{name:"size",options:t,async fn(e){const{placement:o,rects:n,platform:r,elements:s}=e,{apply:i=()=>{},...a}=w(t,e),p=await r.detectOverflow(e,a),c=b(o),l=y(o),f="y"===E(o),{width:h,height:v}=n.floating;let m,g;"top"===c||"bottom"===c?(m=c,g=l===(await(null==r.isRTL?void 0:r.isRTL(s.floating))?"start":"end")?"left":"right"):(g=c,m="end"===l?"top":"bottom");const x=v-p.top-p.bottom,S=h-p.left-p.right,k=u(v-p[m],x),T=u(h-p[g],S),M=e.middlewareData.shift;let A=k,O=T;null!=M&&M.enabled.x&&(O=S),null!=M&&M.enabled.y&&(A=x),!M&&!l&&(f?O=h-2*d(p.left,p.right):A=v-2*d(p.top,p.bottom)),await i({...e,availableWidth:O,availableHeight:A});const H=await r.getDimensions(s.floating);return h!==H.width||v!==H.height?{reset:{rects:!0}}:{}}}},Ot=function(t){return void 0===t&&(t={}),{name:"inline",options:t,async fn(e){const{placement:o,elements:n,rects:r,platform:s,strategy:i}=e,{padding:a=2,x:p,y:c}=w(t,e),l=Array.from(await(null==s.getClientRects?void 0:s.getClientRects(n.reference))||[]);if(!l.length)return{};const f=function(t){const e=t.slice().sort(((t,e)=>t.y-e.y)),o=[];let n=null;for(let t=0;t<e.length;t++){const r=e[t];!n||r.y-n.y>n.height/2?o.push([r]):o[o.length-1].push(r),n=r}return o.map((t=>D(P(t))))}(l),h=D(P(l)),v=C(a),m=await s.getElementRects({reference:{getBoundingClientRect:function(){if(2===f.length&&(f[0].left>f[1].right||f[1].left>f[0].right)&&null!=p&&null!=c)return f.find((t=>p>t.left-v.left&&p<t.right+v.right&&c>t.top-v.top&&c<t.bottom+v.bottom))||h;if(f.length>=2){if("y"===E(o)){const t=f[0],e=f[f.length-1],n="top"===b(o),r=t.top,s=n?t.left:e.left;return D({x:s,y:r,width:(n?t.right:e.right)-s,height:e.bottom-r})}const t="left"===b(o),e=d(...f.map((t=>t.right))),n=u(...f.map((t=>t.left))),r=f.filter((o=>t?o.left===n:o.right===e)),s=r[0].top;return D({x:n,y:s,width:e-n,height:r[r.length-1].bottom-s})}return h}},floating:n.floating,strategy:i});return r.reference.x!==m.reference.x||r.reference.y!==m.reference.y||r.reference.width!==m.reference.width||r.reference.height!==m.reference.height?{reset:{rects:m}}:{}}}},Ht=function(t){return void 0===t&&(t={}),{options:t,fn(e){var o,n;const{x:r,y:s,placement:i,rects:a,middlewareData:p}=e,{offset:c=0,mainAxis:l=!0,crossAxis:f=!0}=w(t,e),u={x:r,y:s},d=E(i),h=S(d);let v=u[h],m=u[d];const g=w(c,e),x="number"==typeof g?{mainAxis:g,crossAxis:0}:{mainAxis:null!=(o=g.mainAxis)?o:0,crossAxis:null!=(n=g.crossAxis)?n:0};if(l){const t="y"===h?"height":"width",e=a.reference[h]-a.floating[t]+x.mainAxis,o=a.reference[h]+a.reference[t]-x.mainAxis;v<e?v=e:v>o&&(v=o)}if(f){var y,k;const t="y"===h?"width":"height",e=W.has(b(i)),o=a.reference[d]-a.floating[t]+(e&&(null==(y=p.offset)?void 0:y[d])||0)+(e?0:x.crossAxis),n=a.reference[d]+a.reference[t]+(e?0:(null==(k=p.offset)?void 0:k[d])||0)-(e?x.crossAxis:0);m<o?m=o:m>n&&(m=n)}return{[h]:v,[d]:m}}}};var Lt=class extends Event{oldState;newState;constructor(t,{oldState:e="",newState:o="",...n}={}){super(t,n),this.oldState=String(e||""),this.newState=String(o||"")}},$t=new WeakMap;function Ct(t,e,o){$t.set(t,setTimeout((()=>{$t.has(t)&&t.dispatchEvent(new Lt("toggle",{cancelable:!1,oldState:e,newState:o}))}),0))}var Dt=globalThis.ShadowRoot||function(){},Rt=globalThis.HTMLDialogElement||function(){},zt=new WeakMap,jt=new WeakMap,Ft=new WeakMap,Pt=new WeakMap;function Wt(t){return Pt.get(t)||"hidden"}var Bt=new WeakMap;function qt(t){return[...t].pop()}function It(t,e){return!("auto"!==t.popover&&"manual"!==t.popover&&"hint"!==t.popover||!t.isConnected||e&&"showing"!==Wt(t)||!e&&"hidden"!==Wt(t)||t instanceof Rt&&t.hasAttribute("open")||document.fullscreenElement===t)}function Nt(t){if(!t)return 0;const e=jt.get(document)||new Set,o=Ft.get(document)||new Set;return o.has(t)?[...o].indexOf(t)+e.size+1:e.has(t)?[...e].indexOf(t)+1:0}function Gt(t){let e;const o=Ft.get(t)||new Set,n=jt.get(t)||new Set,r=o.size>0?o:n.size>0?n:null;return r?(e=qt(r),e.isConnected?e:(r.delete(e),Gt(t))):null}function Vt(t){for(const e of t||[]){if(e.isConnected)return e;t.delete(e)}return null}function Xt(t){return"function"==typeof t.getRootNode?t.getRootNode():t.parentNode?Xt(t.parentNode):t}function Yt(t){for(;t;){if(t instanceof HTMLElement&&"auto"===t.popover&&"showing"===Pt.get(t))return t;if((t=t instanceof Element&&t.assignedSlot||t.parentElement||Xt(t))instanceof Dt&&(t=t.host),t instanceof Document)return}}function _t(t,e){const o=new Map;let n=0;for(const t of e||[])o.set(t,n),n+=1;o.set(t,n),n+=1;let r=null;return function(e){if(!e)return;let n=!1,s=null,i=null;for(;!n;){if(s=Yt(e)||null,null===s)return;if(!o.has(s))return;"hint"!==t.popover&&"auto"!==s.popover||(n=!0),n||(e=s.parentElement)}i=o.get(s),(null===r||o.get(r)<i)&&(r=s)}(t.parentElement||Xt(t)),r}function Jt(t){return!(t.hidden||t instanceof Dt||(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 Kt=new WeakMap;function Qt(t){if(!It(t,!1))return;const e=t.ownerDocument;if(!t.dispatchEvent(new Lt("beforetoggle",{cancelable:!0,oldState:"closed",newState:"open"})))return;if(!It(t,!1))return;let o=!1;const n=t.popover;let r=null;const s=_t(t,jt.get(e)||new Set),i=_t(t,Ft.get(e)||new Set);if("auto"===n&&(Zt(Ft.get(e)||new Set,o,!0),ee(s||e,o,!0),r="auto"),"hint"===n&&(i?(ee(i,o,!0),r="hint"):(Zt(Ft.get(e)||new Set,o,!0),s?(ee(s,o,!0),r="auto"):r="hint")),"auto"===n||"hint"===n){if(n!==t.popover||!It(t,!1))return;Gt(e)||(o=!0),"auto"===r?(jt.has(e)||jt.set(e,new Set),jt.get(e).add(t)):"hint"===r&&(Ft.has(e)||Ft.set(e,new Set),Ft.get(e).add(t))}Kt.delete(t);const a=e.activeElement;var p;t.classList.add(":popover-open"),Pt.set(t,"showing"),zt.has(e)||zt.set(e,new Set),zt.get(e).add(t),se(Bt.get(t),!0),p=t,function(t){if(t.shadowRoot&&!0!==t.shadowRoot.delegatesFocus)return null;let e=t;e.shadowRoot&&(e=e.shadowRoot);let o=e.querySelector("[autofocus]");if(o)return o;{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(o=e.querySelector("[autofocus]"),o)return o}}}const n=t.ownerDocument.createTreeWalker(e,NodeFilter.SHOW_ELEMENT);let r=n.currentNode;for(;r;){if(Jt(r))return r;r=n.nextNode()}}(p)?.focus(),o&&a&&"auto"===t.popover&&Kt.set(t,a),Ct(t,"closed","open")}function Ut(t,e=!1,o=!1){if(!It(t,!0))return;const n=t.ownerDocument;if(["auto","hint"].includes(t.popover)&&(ee(t,e,o),!It(t,!0)))return;const r=jt.get(n)||new Set,s=r.has(t)&&qt(r)===t;if(se(Bt.get(t),!1),Bt.delete(t),o&&(t.dispatchEvent(new Lt("beforetoggle",{oldState:"open",newState:"closed"})),s&&qt(r)!==t&&ee(t,e,o),!It(t,!0)))return;zt.get(n)?.delete(t),r.delete(t),Ft.get(n)?.delete(t),t.classList.remove(":popover-open"),Pt.set(t,"hidden"),o&&Ct(t,"open","closed");const i=Kt.get(t);i&&(Kt.delete(t),e&&i.focus())}function Zt(t,e=!1,o=!1){let n=Vt(t);for(;n;)Ut(n,e,o),n=Vt(t)}function te(t,e,o,n){let r=!1,s=!1;for(;r||!s;){s=!0;let i=null,a=!1;for(const o of e)if(o===t)a=!0;else if(a){i=o;break}if(!i)return;for(;"showing"===Wt(i)&&e.size;)Ut(qt(e),o,n);e.has(t)&&qt(e)!==t&&(r=!0),r&&(n=!1)}}function ee(t,e,o){const n=t.ownerDocument||t;if(t instanceof Document)return function(t,e=!1,o=!1){let n=Gt(t);for(;n;)Ut(n,e,o),n=Gt(t)}(n,e,o);Ft.get(n)?.has(t)?te(t,Ft.get(n),e,o):(Zt(Ft.get(n)||new Set,e,o),jt.get(n)?.has(t)&&te(t,jt.get(n),e,o))}var oe=new WeakMap;function ne(t){if(!t.isTrusted)return;const e=t.composedPath()[0];if(!e)return;const o=e.ownerDocument;if(!Gt(o))return;const n=function(t){const e=Yt(t),o=function(t){for(;t;){const e=t.popoverTargetElement;if(e instanceof HTMLElement)return e;if((t=t.parentElement||Xt(t))instanceof Dt&&(t=t.host),t instanceof Document)return}}(t);return Nt(e)>Nt(o)?e:o}(e);if(n&&"pointerdown"===t.type)oe.set(o,n);else if("pointerup"===t.type){const t=oe.get(o)===n;oe.delete(o),t&&ee(n||o,!1,!0)}}var re=new WeakMap;function se(t,e=!1){if(!t)return;re.has(t)||re.set(t,t.getAttribute("aria-expanded"));const o=t.popoverTargetElement;if(o instanceof HTMLElement&&"auto"===o.popover)t.setAttribute("aria-expanded",String(e));else{const e=re.get(t);e?t.setAttribute("aria-expanded",e):t.removeAttribute("aria-expanded")}}var ie=globalThis.ShadowRoot||function(){};function ae(t,e,o){const n=t[e];Object.defineProperty(t,e,{value(t){return n.call(this,o(t))}})}var pe=/(^|[^\\]):popover-open\b/g;var ce=null;function le(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===ce)try{(ce=new CSSStyleSheet).replaceSync(e)}catch{ce=!1}if(!1===ce){const o=document.createElement("style");o.textContent=e,t instanceof Document?t.head.prepend(o):t.prepend(o)}else t.adoptedStyleSheets=[ce,...t.adoptedStyleSheets]}const fe=Symbol("Clipping Rect Cache"),ue={...kt,getClippingRect:async function(...t){const e=t[0].element,o=this[fe].get(e);if(o)return o;const n=await kt.getClippingRect.apply(this,t);return function(t,e){const o=e.ownerDocument.querySelector("post-header");if(null===o)return;let n=e;for(;!nt(n);)if(n=it(n),X(n)&&(K(n)||n===o))return;const r=o.getBoundingClientRect(),s=Math.max(t.y,r.bottom);t.height-=s-t.y,t.y=s}(n,e),this[fe].set(e,n),n}};var de=function(t,e,o,n){var r,s=arguments.length,i=s<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(t,e,o,n);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(i=(s<3?r(i):s>3?r(e,o,i):r(e,o))||i);return s>3&&i&&Object.defineProperty(e,o,i),i};const he={"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"})}},ve=t(class t extends e{static{this.STATIC_SIDES={top:"bottom",right:"left",bottom:"top",left:"right"}}static{this.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"]}constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.postBeforeShow=o(this,"postBeforeShow",7),this.postShow=o(this,"postShow",7),this.postHide=o(this,"postHide",7),this.postBeforeToggle=o(this,"postBeforeToggle",7),this.postToggle=o(this,"postToggle",7),this.toggleTimeoutId=null,this.hasOpenedOnce=!0,this.placement="top",this.edgeGap=8,this.arrow=!1,this.animation="pop-in",this.currentAnimation=null,this.boundMouseTrackingHandler=this.mouseTrackingHandler.bind(this)}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(){!n.isBrowser||"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(pe,"$1.\\:popover-open")),t}window.ToggleEvent=window.ToggleEvent||Lt,ae(Document.prototype,"querySelector",t),ae(Document.prototype,"querySelectorAll",t),ae(Element.prototype,"querySelector",t),ae(Element.prototype,"querySelectorAll",t),ae(Element.prototype,"matches",t),ae(Element.prototype,"closest",t),ae(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={}){Qt(this)}},hidePopover:{enumerable:!0,configurable:!0,value(){Ut(this,!0,!0)}},togglePopover:{enumerable:!0,configurable:!0,value(t={}){return"boolean"==typeof t&&(t={force:t}),"showing"===Pt.get(this)&&void 0===t.force||!1===t.force?Ut(this,!0,!0):void 0!==t.force&&!0!==t.force||Qt(this),"showing"===Pt.get(this)}}});const e=Element.prototype.attachShadow;e&&Object.defineProperties(Element.prototype,{attachShadow:{enumerable:!0,configurable:!0,writable:!0,value(t){const o=e.call(this,t);return le(o),o}}});const o=HTMLElement.prototype.attachInternals;o&&Object.defineProperties(HTMLElement.prototype,{attachInternals:{enumerable:!0,configurable:!0,writable:!0,value(){const t=o.call(this);return t.shadowRoot&&le(t.shadowRoot),t}}});const n=new WeakMap;function r(t){Object.defineProperties(t.prototype,{popoverTargetElement:{enumerable:!0,configurable:!0,set(t){if(null===t)this.removeAttribute("popovertarget"),n.delete(this);else{if(!(t instanceof Element))throw new TypeError("popoverTargetElement must be an element or null");this.setAttribute("popovertarget",""),n.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=n.get(this);if(t&&t.isConnected)return t;if(t&&!t.isConnected)return n.delete(this),null;const e=Xt(this),o=this.getAttribute("popovertarget");return(e instanceof Document||e instanceof ie)&&o&&e.getElementById(o)||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 s;r(HTMLButtonElement),r(HTMLInputElement),(s=document).addEventListener("click",(t=>{const e=t.composedPath(),o=e[0];if(!(o instanceof Element)||o?.shadowRoot)return;const n=Xt(o);if(!(n instanceof ie||n 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 o=Wt(e);"show"===t.popoverTargetAction&&"showing"===o||"hide"===t.popoverTargetAction&&"hidden"===o||("showing"===o?Ut(e,!0,!0):It(e,!1)&&(Bt.set(e,t),Qt(e)))}(r),void t.preventDefault()):void 0})),s.addEventListener("keydown",(t=>{const e=t.key,o=t.target;t.defaultPrevented||!o||"Escape"!==e&&"Esc"!==e||ee(o.ownerDocument,!0,!0)})),s.addEventListener("pointerdown",ne),s.addEventListener("pointerup",ne),le(document)}()}componentDidLoad(){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&&t&&(this.eventTarget=t,this.updatePosition(),this.host.showPopover())}async hide(){this.toggleTimeoutId||(this.eventTarget=null,this.host.hidePopover(),this.postHide.emit())}async toggle(t,e){const o=this.host.matches(":where(:popover-open, .popover-open)");return!0!==e&&(void 0!==e||o)||t?(this.eventTarget=t,this.toggleTimeoutId||(this.updatePosition(),this.host.togglePopover(e),this.toggleTimeoutId=null),this.host.matches(":where(:popover-open, .popover-open)")):o}open(){const t=this.host.shadowRoot?.querySelector(".popover-content");if(this.startAutoupdates(),t){const e=he[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&&globalThis.addEventListener("mousemove",this.boundMouseTrackingHandler)}close(){"function"==typeof this.clearAutoUpdate&&this.clearAutoUpdate(),this.safeSpace&&globalThis.removeEventListener("mousemove",this.boundMouseTrackingHandler),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 o;try{if(o=t(e),!o)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=o,"running"===o.playState&&(this.postBeforeToggle.emit({willOpen:!0}),this.postBeforeShow.emit({first:this.hasOpenedOnce})),await o.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===o&&(this.currentAnimation=null)}}handleToggle(t){this.toggleTimeoutId=globalThis.setTimeout((()=>this.toggleTimeoutId=null),10),"open"===t.newState?this.open():this.close()}startAutoupdates(){this.eventTarget&&this.host&&(this.clearAutoUpdate=function(t,e,o,n){void 0===n&&(n={});const{ancestorScroll:r=!0,ancestorResize:s=!0,elementResize:i="function"==typeof ResizeObserver,layoutShift:a="function"==typeof IntersectionObserver,animationFrame:p=!1}=n,c=ft(t),l=r||s?[...c?pt(c):[],...e?pt(e):[]]:[];l.forEach((t=>{r&&t.addEventListener("scroll",o),s&&t.addEventListener("resize",o)}));const f=c&&a?function(t,e,o){let n,r=null;const s=N(t);function i(){var t;clearTimeout(n),null==(t=r)||t.disconnect(),r=null}function a(o,p){void 0===o&&(o=!1),void 0===p&&(p=1),i();const c=t.getBoundingClientRect(),{left:l,top:f,width:h,height:m}=c;if(o||e(),!h||!m)return;const g={rootMargin:-v(f)+"px "+-v(s.clientWidth-(l+h))+"px "+-v(s.clientHeight-(f+m))+"px "+-v(l)+"px",threshold:d(0,u(1,p))||1};let x=!0;function w(e){const o=e[0].intersectionRatio;if(!Et(c,t.getBoundingClientRect()))return a();if(o!==p){if(!x)return a();o?a(!1,o):n=setTimeout((()=>{a(!1,1e-7)}),1e3)}x=!1}try{r=new IntersectionObserver(w,{...g,root:s.ownerDocument})}catch(t){r=new IntersectionObserver(w,g)}r.observe(t)}const p=I(t),c=()=>a(o);return p.addEventListener("resize",c),a(!0),()=>{p.removeEventListener("resize",c),i()}}(c,o,s):null;let h,m=-1,g=null;i&&(g=new ResizeObserver((t=>{let[n]=t;n&&n.target===c&&g&&e&&(g.unobserve(e),cancelAnimationFrame(m),m=requestAnimationFrame((()=>{var t;null==(t=g)||t.observe(e)}))),o()})),c&&!p&&g.observe(c),e&&g.observe(e));let x=p?vt(t):null;return p&&function e(){const n=vt(t);x&&!Et(x,n)&&o(),x=n,h=requestAnimationFrame(e)}(),o(),()=>{var t;l.forEach((t=>{r&&t.removeEventListener("scroll",o),s&&t.removeEventListener("resize",o)})),null==f||f(),null==(t=g)||t.disconnect(),g=null,p&&cancelAnimationFrame(h)}}(this.eventTarget,this.host,this.updatePosition.bind(this)))}async updatePosition(){const{x:e,y:o,middlewareData:n,placement:r}=await this.calculatePosition();n.hide?.referenceHidden&&this.host.hidePopover();const s=r.split("-")[0];if(this.dynamicPlacement=s,this.host.style.left=`${e}px`,this.host.style.top=`${o}px`,this.arrow&&n.arrow){const{x:e,y:o}=n.arrow,r=t.STATIC_SIDES[s],i=-.5*this.arrowRef.offsetWidth;r&&Object.assign(this.arrowRef.style,{left:e?`${e}px`:"",top:o?`${o}px`:"",[r]:`${i}px`})}this.safeSpace&&this.eventTarget&&await this.updateSafeSpaceBoundaries(s)}async calculatePosition(){const t=this.edgeGap,e=(this.placement||"top").includes("-"),o=[Mt({elementContext:"reference",crossAxis:!1}),Mt({elementContext:"floating",crossAxis:!1})],n=function(t){return void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:o,y:n,placement:r,platform:s}=e,{mainAxis:i=!0,crossAxis:a=!1,limiter:p={fn:t=>{let{x:e,y:o}=t;return{x:e,y:o}}},...c}=w(t,e),l={x:o,y:n},f=await s.detectOverflow(e,c),u=E(r),d=S(u);let h=l[d],v=l[u];const m=(t,e)=>x(e+f["y"===t?"top":"left"],e,e-f["y"===t?"bottom":"right"]);i&&(h=m(d,h)),a&&(v=m(u,v));const g=p.fn({...e,[d]:h,[u]:v});return{...g,data:{x:g.x-o,y:g.y-n,enabled:{[d]:i,[u]:a}}}}}}({padding:t,limiter:Ht({offset:32})}),r=[Tt(this.offset??(this.arrow?t+4:t)),Ot(),...e?[...o,n]:[n,...o],At({apply({availableWidth:e,elements:o}){Object.assign(o.floating.style,{maxWidth:e-2*t+"px"})}})];return this.arrow&&r.push((t=>({name:"arrow",options:t,async fn(e){const{x:o,y:n,placement:r,rects:s,platform:i,elements:a,middlewareData:p}=e,{element:c,padding:l=0}=w(t,e)||{};if(null==c)return{};const f=C(l),d={x:o,y:n},h=T(r),v=k(h),m=await i.getDimensions(c),g="y"===h,b=g?"top":"left",S=g?"bottom":"right",E=g?"clientHeight":"clientWidth",M=s.reference[v]+s.reference[h]-d[h]-s.floating[v],A=d[h]-s.reference[h],O=await(null==i.getOffsetParent?void 0:i.getOffsetParent(c));let H=O?O[E]:0;H&&await(null==i.isElement?void 0:i.isElement(O))||(H=a.floating[E]||s.floating[v]);const L=M/2-A/2,$=H/2-m[v]/2-1,D=u(f[b],$),R=u(f[S],$),z=H-m[v]-R,j=H/2-m[v]/2+L,F=x(D,j,z),P=!p.arrow&&null!=y(r)&&j!==F&&s.reference[v]/2-(j<D?D:R)-m[v]/2<0,W=P?j<D?j-D:j-z:0;return{[h]:d[h]+W,data:{[h]:F,centerOffset:j-F-W,...P&&{alignmentOffset:W}},reset:P}}}))({element:this.arrowRef,padding:t})),this.autoHide&&r.push(function(t){return void 0===t&&(t={}),{name:"hide",options:t,async fn(e){const{rects:o,platform:n}=e,{strategy:r="referenceHidden",...s}=w(t,e);switch(r){case"referenceHidden":{const t=j(await n.detectOverflow(e,{...s,elementContext:"reference"}),o.reference);return{data:{referenceHiddenOffsets:t,referenceHidden:F(t)}}}case"escaped":{const t=j(await n.detectOverflow(e,{...s,altBoundary:!0}),o.floating);return{data:{escapedOffsets:t,escaped:F(t)}}}default:return{}}}}}({strategy:"referenceHidden"})),s=this.eventTarget,i=this.host,a={placement:this.placement||"top",strategy:"fixed",middleware:r},a??={},((t,e,o)=>{const n=new Map,r=null!=o?o:{},s={...kt,...r.platform,_c:n};return(async(t,e,o)=>{const{placement:n="bottom",strategy:r="absolute",middleware:s=[],platform:i}=o,a=i.detectOverflow?i:{...i,detectOverflow:z},p=await(null==i.isRTL?void 0:i.isRTL(e));let c=await i.getElementRects({reference:t,floating:e,strategy:r}),{x:l,y:f}=R(c,n,p),u=n,d=0;const h={};for(let o=0;o<s.length;o++){const v=s[o];if(!v)continue;const{name:m,fn:g}=v,{x,y:w,data:b,reset:y}=await g({x:l,y:f,initialPlacement:n,placement:u,strategy:r,middlewareData:h,rects:c,platform:a,elements:{reference:t,floating:e}});l=null!=x?x:l,f=null!=w?w:f,h[m]={...h[m],...b},y&&d<50&&(d++,"object"==typeof y&&(y.placement&&(u=y.placement),y.rects&&(c=!0===y.rects?await i.getElementRects({reference:t,floating:e,strategy:r}):y.rects),({x:l,y:f}=R(c,u,p))),o=-1)}return{x:l,y:f,placement:u,strategy:r,middlewareData:h}})(t,e,{...r,platform:s})})(s,i,{...a,platform:{...ue,...a.platform,[fe]:new Map}});var s,i,a}async updateSafeSpaceBoundaries(e){const o=this.eventTarget.getBoundingClientRect(),n="top"===e||"bottom"===e,r=((t,e,o)=>"top"===t||"bottom"===t?{popover:{y:"top"===t?e.bottom:e.top,xStart:e.left,xEnd:e.right},trigger:{y:"top"===t?o.top:o.bottom,xStart:o.left,xEnd:o.right}}:{popover:{x:"left"===t?e.right:e.left,yStart:e.top,yEnd:e.bottom},trigger:{x:"left"===t?o.left:o.right,yStart:o.top,yEnd:o.bottom}})(e,this.host.getBoundingClientRect(),o);t.PROPERTIES_TO_CLEAR.forEach((t=>{this.host.style.removeProperty(t)})),n?(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 r(s,{key:"f3ea4bfc9a59faa2fbf1e413a1ec648f598a6779","data-version":a,popover:"auto"},r("div",{key:"a328c73c7e08eca1e423fcbe736798188cca2a87",part:"post-popovercontainer-content",class:"popover-content"},this.arrow&&r("span",{key:"8fad0095fb8d8c903ba84a639b4efc3e321c6aef","dynamic-placement":this.dynamicPlacement,class:"arrow",ref:t=>{this.arrowRef=t}}),r("span",{key:"deadbcc5892ed545a64b4a0e5e0936e0dd1feb70",part:"post-popovercontainer-border-mask"}),r("slot",{key:"48c4db7ab222f3ef18157ce19d8ba15d75441f98"})))}get host(){return this}static get style(){return'@layer polyfill{@supports not selector(:popover-open){:host([popover]:not(.\\:popover-open)){display:none}}}:host{background-color:rgba(0,0,0,0);border:rgba(0,0,0,0);position:fixed;margin:0;padding:0;overflow:visible}:host>div{-webkit-box-shadow:var(--post-device-elevation-300);box-shadow:var(--post-device-elevation-300);width:-webkit-max-content;width:-moz-max-content;width:max-content;max-width:100%;color:var(--post-current-fg);background-color:var(--post-current-bg);border-radius:4px;position:relative}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host>div{border:2px solid rgba(0,0,0,0)}}:host [part=post-popovercontainer-border-mask]{display:none;position:absolute;inset:0;border-radius:4px;pointer-events:none}:host .arrow{--post-popovercontainer-arrow-border: var(--post-popovercontainer-arrow-border-width, 0px) solid var(--post-popovercontainer-arrow-border-color, transparent);position:absolute;width:.5825rem;height:.5825rem;background-color:inherit;rotate:45deg;pointer-events:none;z-index:-1}:host .arrow[dynamic-placement=top]{border-bottom-right-radius:2px;border-bottom:var(--post-popovercontainer-arrow-border);border-right:var(--post-popovercontainer-arrow-border)}:host .arrow[dynamic-placement=right]{border-bottom-left-radius:2px;border-bottom:var(--post-popovercontainer-arrow-border);border-left:var(--post-popovercontainer-arrow-border)}:host .arrow[dynamic-placement=bottom]{border-top-left-radius:2px;border-top:var(--post-popovercontainer-arrow-border);border-left:var(--post-popovercontainer-arrow-border)}:host .arrow[dynamic-placement=left]{border-top-right-radius:2px;border-top:var(--post-popovercontainer-arrow-border);border-right:var(--post-popovercontainer-arrow-border)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .arrow[dynamic-placement=top]{-webkit-border-after:2px solid rgba(0,0,0,0);border-block-end:2px solid rgba(0,0,0,0);-webkit-border-end:2px solid rgba(0,0,0,0);border-inline-end:2px solid rgba(0,0,0,0);bottom:-0.3796735336rem !important}:host .arrow[dynamic-placement=left]{-webkit-border-before:2px solid rgba(0,0,0,0);border-block-start:2px solid rgba(0,0,0,0);-webkit-border-end:2px solid rgba(0,0,0,0);border-inline-end:2px solid rgba(0,0,0,0);right:-0.3796735336rem !important}:host .arrow[dynamic-placement=right]{-webkit-border-after:2px solid rgba(0,0,0,0);border-block-end:2px solid rgba(0,0,0,0);-webkit-border-start:2px solid rgba(0,0,0,0);border-inline-start:2px solid rgba(0,0,0,0);left:-0.3796735336rem !important}:host .arrow[dynamic-placement=bottom]{-webkit-border-before:2px solid rgba(0,0,0,0);border-block-start:2px solid rgba(0,0,0,0);-webkit-border-start:2px solid rgba(0,0,0,0);border-inline-start:2px solid rgba(0,0,0,0);top:-0.3796735336rem !important}}:host([tooltip]){position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0}:host([safe-space])::after{content:"";position:fixed;inset:0;z-index:-1;pointer-events:auto}:host([safe-space=triangle])::after{-webkit-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)));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)))}:host([safe-space=trapezoid])::after{-webkit-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)));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)))}:host(:not(:has(.arrow)))>div{-webkit-box-shadow:var(--post-device-elevation-300);box-shadow:var(--post-device-elevation-300)}:host(:has(.arrow))>div{-webkit-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));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))}:host(:has(.arrow[dynamic-placement=top]))>div{-webkit-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));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))}:host(:has(.arrow[dynamic-placement=left]))>div{-webkit-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));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))}:host(:has(.arrow[dynamic-placement=right]))>div{-webkit-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));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))}'}},[257,"post-popovercontainer",{placement:[1],edgeGap:[2,"edge-gap"],offset:[2],arrow:[4],safeSpace:[513,"safe-space"],autoHide:[4,"auto-hide"],dynamicPlacement:[32],show:[64],hide:[64],toggle:[64]}]);function me(){"undefined"!=typeof customElements&&["post-popovercontainer"].forEach((t=>{"post-popovercontainer"===t&&(customElements.get(i(t))||customElements.define(i(t),ve))}))}de([p(l)],ve.prototype,"placement",void 0),de([c("number")],ve.prototype,"edgeGap",void 0),de([p(["triangle","trapezoid"])],ve.prototype,"safeSpace",void 0);export{l as P,ve as a,me as d}
1
+ import{proxyCustomElement as t,HTMLElement as e,createEvent as n,Build as o,h as r,Host as i,transformTag as a}from"@stencil/core/internal/client";import{v as s}from"./package.js";import{O as l}from"./one-of.js";import{T as c}from"./type.js";const p=["top","right","bottom","left","top-start","top-end","right-start","right-end","bottom-start","bottom-end","left-start","left-end"],u=["top","right","bottom","left"],f=Math.min,d=Math.max,h=Math.round,m=Math.floor,w=t=>({x:t,y:t}),b={left:"right",right:"left",bottom:"top",top:"bottom"};function g(t,e,n){return d(t,f(e,n))}function x(t,e){return"function"==typeof t?t(e):t}function v(t){return t.split("-")[0]}function y(t){return t.split("-")[1]}function S(t){return"x"===t?"y":"x"}function k(t){return"y"===t?"height":"width"}function M(t){const e=t[0];return"t"===e||"b"===e?"y":"x"}function T(t){return S(M(t))}function E(t){return t.includes("start")?t.replace("start","end"):t.replace("end","start")}const H=["left","right"],A=["right","left"],O=["top","bottom"],L=["bottom","top"];function z(t){const e=v(t);return b[e]+t.slice(e.length)}function C(t){return"number"!=typeof t?function(t){var e,n,o,r;return{top:null!=(e=t.top)?e:0,right:null!=(n=t.right)?n:0,bottom:null!=(o=t.bottom)?o:0,left:null!=(r=t.left)?r:0}}(t):{top:t,right:t,bottom:t,left:t}}function R(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 D(t,e,n){let{reference:o,floating:r}=t;const i=M(e),a=T(e),s=k(a),l=v(e),c="y"===i,p=o.x+o.width/2-r.width/2,u=o.y+o.height/2-r.height/2,f=o[s]/2-r[s]/2;let d;switch(l){case"top":d={x:p,y:o.y-r.height};break;case"bottom":d={x:p,y:o.y+o.height};break;case"right":d={x:o.x+o.width,y:u};break;case"left":d={x:o.x-r.width,y:u};break;default:d={x:o.x,y:o.y}}const h=y(e);return h&&(d[a]+=f*("end"===h?1:-1)*(n&&c?-1:1)),d}async function $(t,e){var n;void 0===e&&(e={});const{x:o,y:r,platform:i,rects:a,elements:s,strategy:l}=t,{boundary:c="clippingAncestors",rootBoundary:p="viewport",elementContext:u="floating",altBoundary:f=!1,padding:d=0}=x(e,t),h=C(d),m=s[f?"floating"===u?"reference":"floating":u],w=R(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(s.floating)),boundary:c,rootBoundary:p,strategy:l})),b="floating"===u?{x:o,y:r,width:a.floating.width,height:a.floating.height}:a.reference,g=await(null==i.getOffsetParent?void 0:i.getOffsetParent(s.floating)),v=await(null==i.isElement?void 0:i.isElement(g))&&await(null==i.getScale?void 0:i.getScale(g))||{x:1,y:1},y=R(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:b,offsetParent:g,strategy:l}):b);return{top:(w.top-y.top+h.top)/v.y,bottom:(y.bottom-w.bottom+h.bottom)/v.y,left:(w.left-y.left+h.left)/v.x,right:(y.right-w.right+h.right)/v.x}}function j(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function F(t){return u.some((e=>t[e]>=0))}function W(t){const e=f(...t.map((t=>t.left))),n=f(...t.map((t=>t.top)));return{x:e,y:n,width:d(...t.map((t=>t.right)))-e,height:d(...t.map((t=>t.bottom)))-n}}const P=new Set(["left","top"]);function B(){return"undefined"!=typeof window}function q(t){return G(t)?(t.nodeName||"").toLowerCase():"#document"}function I(t){var e;return(null==t||null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function N(t){var e;return null==(e=(G(t)?t.ownerDocument:t.document)||window.document)?void 0:e.documentElement}function G(t){return!!B()&&(t instanceof Node||t instanceof I(t).Node)}function V(t){return!!B()&&(t instanceof Element||t instanceof I(t).Element)}function U(t){return!!B()&&(t instanceof HTMLElement||t instanceof I(t).HTMLElement)}function X(t){return!(!B()||"undefined"==typeof ShadowRoot)&&(t instanceof ShadowRoot||t instanceof I(t).ShadowRoot)}function Y(t){const{overflow:e,overflowX:n,overflowY:o,display:r}=rt(t);return/auto|scroll|overlay|hidden|clip/.test(e+o+n)&&"inline"!==r&&"contents"!==r}function _(t){return/^(table|td|th)$/.test(q(t))}function J(t){try{if(t.matches(":popover-open"))return!0}catch(t){}try{return t.matches(":modal")}catch(t){return!1}}const K=/transform|translate|scale|rotate|perspective|filter/,Q=/paint|layout|strict|content/,Z=t=>!!t&&"none"!==t;let tt;function et(t){const e=V(t)?rt(t):t;return Z(e.transform)||Z(e.translate)||Z(e.scale)||Z(e.rotate)||Z(e.perspective)||!nt()&&(Z(e.backdropFilter)||Z(e.filter))||K.test(e.willChange||"")||Q.test(e.contain||"")}function nt(){return null==tt&&(tt="undefined"!=typeof CSS&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),tt}function ot(t){return/^(html|body|#document)$/.test(q(t))}function rt(t){return I(t).getComputedStyle(t)}function it(t){return V(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function at(t){if("html"===q(t))return t;const e=t.assignedSlot||t.parentNode||X(t)&&t.host||N(t);return X(e)?e.host:e}function st(t){const e=at(t);return ot(e)?(t.ownerDocument||t).body:U(e)&&Y(e)?e:st(e)}function lt(t,e,n){var o;void 0===e&&(e=[]),void 0===n&&(n=!0);const r=st(t),i=r===(null==(o=t.ownerDocument)?void 0:o.body),a=I(r);if(i){const t=ct(a);return e.concat(a,a.visualViewport||[],Y(r)?r:[],t&&n?lt(t):[])}return e.concat(r,lt(r,[],n))}function ct(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function pt(t){const e=rt(t);let n=parseFloat(e.width)||0,o=parseFloat(e.height)||0;const r=U(t),i=r?t.offsetWidth:n,a=r?t.offsetHeight:o,s=h(n)!==i||h(o)!==a;return s&&(n=i,o=a),{width:n,height:o,$:s}}function ut(t){return V(t)?t:t.contextElement}function ft(t){const e=ut(t);if(!U(e))return w(1);const n=e.getBoundingClientRect(),{width:o,height:r,$:i}=pt(e);let a=(i?h(n.width):n.width)/o,s=(i?h(n.height):n.height)/r;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const dt=w(0);function ht(t){const e=I(t);return nt()&&e.visualViewport?{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}:dt}function mt(t,e,n,o){void 0===e&&(e=!1),void 0===n&&(n=!1);const r=t.getBoundingClientRect(),i=ut(t);let a=w(1);e&&(o?V(o)&&(a=ft(o)):a=ft(t));const s=function(t,e,n){return void 0===e&&(e=!1),!!n&&e&&n===I(t)}(i,n,o)?ht(i):w(0);let l=(r.left+s.x)/a.x,c=(r.top+s.y)/a.y,p=r.width/a.x,u=r.height/a.y;if(i&&o){const t=I(i),e=V(o)?I(o):o;let n=t,r=ct(n);for(;r&&e!==n;){const t=ft(r),e=r.getBoundingClientRect(),o=rt(r),i=e.left+(r.clientLeft+parseFloat(o.paddingLeft))*t.x,a=e.top+(r.clientTop+parseFloat(o.paddingTop))*t.y;l*=t.x,c*=t.y,p*=t.x,u*=t.y,l+=i,c+=a,n=I(r),r=ct(n)}}return R({width:p,height:u,x:l,y:c})}function wt(t,e){const n=it(t).scrollLeft;return e?e.left+n:mt(N(t)).left+n}function bt(t,e){const n=t.getBoundingClientRect();return{x:n.left+e.scrollLeft-wt(t,n),y:n.top+e.scrollTop}}function gt(t,e,n){let o;if("viewport"===e||"layoutViewport"===e)o=function(t,e,n){void 0===n&&(n="viewport");const o="layoutViewport"===n,r=I(t),i=N(t),a=r.visualViewport;let s=i.clientWidth,l=i.clientHeight,c=0,p=0;if(a){const t=!nt()||"fixed"===e;o?t||(c=-a.offsetLeft,p=-a.offsetTop):(s=a.width,l=a.height,t&&(c=a.offsetLeft,p=a.offsetTop))}if(wt(i)<=0){const t=i.ownerDocument,e=t.body,n=getComputedStyle(e),o="CSS1Compat"===t.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,r=Math.abs(i.clientWidth-e.clientWidth-o),a="stable both-edges"===getComputedStyle(i).scrollbarGutter?r/2:r;a<=25&&(s-=a)}return{width:s,height:l,x:c,y:p}}(t,n,e);else if("document"===e)o=function(t){const e=it(t),n=t.ownerDocument.body,o=d(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),r=d(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let i=-e.scrollLeft+wt(t);const a=-e.scrollTop;return"rtl"===rt(n).direction&&(i+=d(t.clientWidth,n.clientWidth)-o),{width:o,height:r,x:i,y:a}}(N(t));else if(V(e))o=function(t,e){const n=mt(t,!0,"fixed"===e),o=n.top+t.clientTop,r=n.left+t.clientLeft,i=ft(t);return{width:t.clientWidth*i.x,height:t.clientHeight*i.y,x:r*i.x,y:o*i.y}}(e,n);else{const n=ht(t);o={x:e.x-n.x,y:e.y-n.y,width:e.width,height:e.height}}return R(o)}function xt(t,e,n){const o=U(e),r=N(e),i="fixed"===n,a=mt(t,!0,i,e);let s={scrollLeft:0,scrollTop:0};const l=w(0);if((o||!i)&&(("body"!==q(e)||Y(r))&&(s=it(e)),o)){const t=mt(e,!0,i,e);l.x=t.x+e.clientLeft,l.y=t.y+e.clientTop}!o&&r&&(l.x=wt(r));const c=!r||o||i?w(0):bt(r,s);return{x:a.left+s.scrollLeft-l.x-c.x,y:a.top+s.scrollTop-l.y-c.y,width:a.width,height:a.height}}function vt(t){return"static"===rt(t).position}function yt(t,e){if(!U(t)||"fixed"===rt(t).position)return null;if(e)return e(t);let n=t.offsetParent;return N(t)===n&&(n=n.ownerDocument.body),n}function St(t,e){const n=I(t);if(J(t))return n;if(!U(t)){let e=at(t);for(;e&&!ot(e);){if(V(e)&&!vt(e))return e;e=at(e)}return n}let o=yt(t,e);for(;o&&_(o)&&vt(o);)o=yt(o,e);return o&&ot(o)&&vt(o)&&!et(o)?n:o||function(t){let e=at(t);for(;U(e)&&!ot(e);){if(et(e))return e;if(J(e))return null;e=at(e)}return null}(t)||n}const kt={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{elements:e,rect:n,offsetParent:o,strategy:r}=t;const i="fixed"===r,a=N(o),s=!!e&&J(e.floating);if(o===a||s&&i)return n;let l={scrollLeft:0,scrollTop:0},c=w(1);const p=w(0),u=U(o);if((u||!i)&&(("body"!==q(o)||Y(a))&&(l=it(o)),u)){const t=mt(o);c=ft(o),p.x=t.x+o.clientLeft,p.y=t.y+o.clientTop}const f=!a||u||i?w(0):bt(a,l);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+p.x+f.x,y:n.y*c.y-l.scrollTop*c.y+p.y+f.y}},getDocumentElement:N,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=>V(t)&&"body"!==q(t))),r=null;const i="fixed"===rt(t).position;let a=i?at(t):t;for(;V(a)&&!ot(a);){const t=rt(a),e=et(a),n=r?r.position:i?"fixed":"";e||"fixed"!==n&&("absolute"!==n||"static"!==t.position)?r=t:o=o.filter((t=>t!==a)),a=at(a)}return e.set(t,o),o}(e,this._c):[].concat(n),o],a=gt(e,i[0],r);let s=a.top,l=a.right,c=a.bottom,p=a.left;for(let t=1;t<i.length;t++){const n=gt(e,i[t],r);s=d(n.top,s),l=f(n.right,l),c=f(n.bottom,c),p=d(n.left,p)}return{width:l-p,height:c-s,x:p,y:s}},getOffsetParent:St,getElementRects:async function(t){const e=this.getOffsetParent||St,n=this.getDimensions,o=await n(t.floating);return{reference:xt(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}},getClientRects:function(t){return t.getClientRects?Array.from(t.getClientRects()):[]},getDimensions:function(t){const{width:e,height:n}=pt(t);return{width:e,height:n}},getScale:ft,isElement:V,isRTL:function(t){return"rtl"===rt(t).direction}};function Mt(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}const Tt=$,Et=function(t){return void 0===t&&(t=0),{name:"offset",options:t,async fn(e){var n,o;const{x:r,y:i,placement:a,middlewareData:s}=e,l=await async function(t,e){const{placement:n,platform:o,elements:r}=t,i=await(null==o.isRTL?void 0:o.isRTL(r.floating)),a=v(n),s=y(n),l="y"===M(n),c=P.has(a)?-1:1,p=i&&l?-1:1,u=x(e,t);let{mainAxis:f,crossAxis:d,alignmentAxis:h}="number"==typeof u?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return s&&"number"==typeof h&&(d="end"===s?-1*h:h),l?{x:d*p,y:f*c}:{x:f*c,y:d*p}}(e,t);return a===(null==(n=s.offset)?void 0:n.placement)&&null!=(o=s.arrow)&&o.alignmentOffset?{}:{x:r+l.x,y:i+l.y,data:{...l,placement:a}}}}},Ht=function(t){return void 0===t&&(t={}),{name:"inline",options:t,async fn(e){const{placement:n,elements:o,rects:r,platform:i,strategy:a}=e,{padding:s=2,x:l,y:c}=x(t,e),p=Array.from(await(null==i.getClientRects?void 0:i.getClientRects(o.reference))||[]);if(!p.length)return{};const u=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=>R(W(t))))}(p),h=R(W(p)),m=C(s),w=await i.getElementRects({reference:{getBoundingClientRect:function(){if(2===u.length&&(u[0].left>u[1].right||u[1].left>u[0].right)&&null!=l&&null!=c)return u.find((t=>l>t.left-m.left&&l<t.right+m.right&&c>t.top-m.top&&c<t.bottom+m.bottom))||h;if(u.length>=2){if("y"===M(n)){const t=u[0],e=u[u.length-1],o="top"===v(n),r=t.top,i=o?t.left:e.left;return R({x:i,y:r,width:(o?t.right:e.right)-i,height:e.bottom-r})}const t="left"===v(n),e=d(...u.map((t=>t.right))),o=f(...u.map((t=>t.left))),r=u.filter((n=>t?n.left===o:n.right===e)),i=r[0].top;return R({x:o,y:i,width:e-o,height:r[r.length-1].bottom-i})}return h}},floating:o.floating,strategy:a});return r.reference.x!==w.reference.x||r.reference.y!==w.reference.y||r.reference.width!==w.reference.width||r.reference.height!==w.reference.height?{reset:{rects:w}}:{}}}},At=function(t){return void 0===t&&(t={}),{options:t,fn(e){var n,o;const{x:r,y:i,placement:a,rects:s,middlewareData:l}=e,{offset:c=0,mainAxis:p=!0,crossAxis:u=!0}=x(t,e),f={x:r,y:i},d=M(a),h=S(d);let m=f[h],w=f[d];const b=x(c,e),g="number"==typeof b?{mainAxis:b,crossAxis:0}:{mainAxis:null!=(n=b.mainAxis)?n:0,crossAxis:null!=(o=b.crossAxis)?o:0};if(p){const t="y"===h?"height":"width",e=s.reference[h]-s.floating[t]+g.mainAxis,n=s.reference[h]+s.reference[t]-g.mainAxis;m<e?m=e:m>n&&(m=n)}if(u){var y,k;const t="y"===h?"width":"height",e=P.has(v(a)),n=s.reference[d]-s.floating[t]+(e&&(null==(y=l.offset)?void 0:y[d])||0)+(e?0:g.crossAxis),o=s.reference[d]+s.reference[t]+(e?0:(null==(k=l.offset)?void 0:k[d])||0)-(e?g.crossAxis:0);w<n?w=n:w>o&&(w=o)}return{[h]:m,[d]:w}}}};function Ot(t,e){return u[(u.indexOf(t)+e)%4]}const Lt=t=>Ot(t,2),zt="post-flip";function Ct(t={}){return{name:zt,options:t,async fn(e){const{middlewareData:n,placement:o}=e;if(n.arrow?.alignmentOffset)return{};const{minSize:r={},...i}=x(t,e),a=Math.abs(n.offset?.[M(o)]??0),s=v(o),l=await Tt(e,{...i,elementContext:"reference"}),c=await Tt(e,{...i,elementContext:"floating"});if(Math.max(l[s],c[s])<=0)return{};const p=n[zt],u={overflow:l,minSize:r,gap:a};let f=p?.deficits??[];const d=p?.placements??await async function(t,e){const{placement:n,platform:o,elements:r}=t,{overflow:i}=e,a=v(n),s=[n,z(n)];if(Math.min(Rt(a,e),Rt(Lt(a),e))<=0)return s;const l=function(t,e,n,o){const r=y(t);let i=function(t,e,n){switch(t){case"top":case"bottom":return n?e?A:H:e?H:A;case"left":case"right":return e?O:L;default:return[]}}(v(t),"start"===n,o);return r&&(i=i.map((t=>t+"-"+r)),i=i.concat(i.map(E))),i}(n,0,"start",await(o.isRTL?.(r.floating))??!1);return l.sort(((t,e)=>i[v(t)]-i[v(e)])),[...s,...l]}(e,u);f.length<d.length&&(f=[...f,Rt(s,u)]);const h={placements:d,deficits:f};if(f.length<d.length)return{data:h,reset:{placement:d[f.length]}};const m=h.placements[h.deficits.indexOf(Math.min(...h.deficits))];return m===o?{data:h}:{data:h,reset:{placement:m}}}}}function Rt(t,{minSize:e,overflow:n,gap:o}){return o+(e[k(M(t))]??0)+n[t]}const Dt=Symbol("Clipping Rect Cache"),$t={...kt,getClippingRect:async function(...t){const e=t[0].element,n=this[Dt].get(e);if(n)return n;const o=await kt.getClippingRect.apply(this,t);return function(t,e){const n=e.ownerDocument.querySelector("post-header");if(null===n)return;let o=e;for(;!ot(o);)if(o=at(o),U(o)&&(J(o)||o===n))return;const r=n.getBoundingClientRect(),i=Math.max(t.y,r.bottom);t.height-=i-t.y,t.y=i}(o,e),this[Dt].set(e,o),o}};const jt="post-safe-space";async function Ft({elements:t,platform:e,strategy:n},o){return R(await(e.convertOffsetParentRelativeRectToViewportRelativeRect?.({offsetParent:await(e.getOffsetParent?.(t.floating)),rect:o,elements:t,strategy:n}))??o)}function Wt(t,e){const n=t[e],o=t[(t=>Ot(t,3))(e)],r=t[(t=>Ot(t,1))(e)];return"x"===M(e)?[n,o,n,r]:[o,n,r,n]}var Pt=class extends Event{oldState;newState;constructor(t,{oldState:e="",newState:n="",...o}={}){super(t,o),this.oldState=String(e||""),this.newState=String(n||"")}},Bt=new WeakMap;function qt(t,e,n){Bt.set(t,setTimeout((()=>{Bt.has(t)&&t.dispatchEvent(new Pt("toggle",{cancelable:!1,oldState:e,newState:n}))}),0))}var It=globalThis.ShadowRoot||function(){},Nt=globalThis.HTMLDialogElement||function(){},Gt=new WeakMap,Vt=new WeakMap,Ut=new WeakMap,Xt=new WeakMap;function Yt(t){return Xt.get(t)||"hidden"}var _t=new WeakMap;function Jt(t){return[...t].pop()}function Kt(t,e){return!("auto"!==t.popover&&"manual"!==t.popover&&"hint"!==t.popover||!t.isConnected||e&&"showing"!==Yt(t)||!e&&"hidden"!==Yt(t)||t instanceof Nt&&t.hasAttribute("open")||document.fullscreenElement===t)}function Qt(t){if(!t)return 0;const e=Vt.get(document)||new Set,n=Ut.get(document)||new Set;return n.has(t)?[...n].indexOf(t)+e.size+1:e.has(t)?[...e].indexOf(t)+1:0}function Zt(t){let e;const n=Ut.get(t)||new Set,o=Vt.get(t)||new Set,r=n.size>0?n:o.size>0?o:null;return r?(e=Jt(r),e.isConnected?e:(r.delete(e),Zt(t))):null}function te(t){for(const e of t||[]){if(e.isConnected)return e;t.delete(e)}return null}function ee(t){return"function"==typeof t.getRootNode?t.getRootNode():t.parentNode?ee(t.parentNode):t}function ne(t){for(;t;){if(t instanceof HTMLElement&&"auto"===t.popover&&"showing"===Xt.get(t))return t;if((t=t instanceof Element&&t.assignedSlot||t.parentElement||ee(t))instanceof It&&(t=t.host),t instanceof Document)return}}function oe(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,a=null;for(;!o;){if(i=ne(e)||null,null===i)return;if(!n.has(i))return;"hint"!==t.popover&&"auto"!==i.popover||(o=!0),o||(e=i.parentElement)}a=n.get(i),(null===r||n.get(r)<a)&&(r=i)}(t.parentElement||ee(t)),r}function re(t){return!(t.hidden||t instanceof It||(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 ie=new WeakMap;function ae(t){if(!Kt(t,!1))return;const e=t.ownerDocument;if(!t.dispatchEvent(new Pt("beforetoggle",{cancelable:!0,oldState:"closed",newState:"open"})))return;if(!Kt(t,!1))return;let n=!1;const o=t.popover;let r=null;const i=oe(t,Vt.get(e)||new Set),a=oe(t,Ut.get(e)||new Set);if("auto"===o&&(le(Ut.get(e)||new Set,n,!0),pe(i||e,n,!0),r="auto"),"hint"===o&&(a?(pe(a,n,!0),r="hint"):(le(Ut.get(e)||new Set,n,!0),i?(pe(i,n,!0),r="auto"):r="hint")),"auto"===o||"hint"===o){if(o!==t.popover||!Kt(t,!1))return;Zt(e)||(n=!0),"auto"===r?(Vt.has(e)||Vt.set(e,new Set),Vt.get(e).add(t)):"hint"===r&&(Ut.has(e)||Ut.set(e,new Set),Ut.get(e).add(t))}ie.delete(t);const s=e.activeElement;var l;t.classList.add(":popover-open"),Xt.set(t,"showing"),Gt.has(e)||Gt.set(e,new Set),Gt.get(e).add(t),he(_t.get(t),!0),l=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(re(r))return r;r=o.nextNode()}}(l)?.focus(),n&&s&&"auto"===t.popover&&ie.set(t,s),qt(t,"closed","open")}function se(t,e=!1,n=!1){if(!Kt(t,!0))return;const o=t.ownerDocument;if(["auto","hint"].includes(t.popover)&&(pe(t,e,n),!Kt(t,!0)))return;const r=Vt.get(o)||new Set,i=r.has(t)&&Jt(r)===t;if(he(_t.get(t),!1),_t.delete(t),n&&(t.dispatchEvent(new Pt("beforetoggle",{oldState:"open",newState:"closed"})),i&&Jt(r)!==t&&pe(t,e,n),!Kt(t,!0)))return;Gt.get(o)?.delete(t),r.delete(t),Ut.get(o)?.delete(t),t.classList.remove(":popover-open"),Xt.set(t,"hidden"),n&&qt(t,"open","closed");const a=ie.get(t);a&&(ie.delete(t),e&&a.focus())}function le(t,e=!1,n=!1){let o=te(t);for(;o;)se(o,e,n),o=te(t)}function ce(t,e,n,o){let r=!1,i=!1;for(;r||!i;){i=!0;let a=null,s=!1;for(const n of e)if(n===t)s=!0;else if(s){a=n;break}if(!a)return;for(;"showing"===Yt(a)&&e.size;)se(Jt(e),n,o);e.has(t)&&Jt(e)!==t&&(r=!0),r&&(o=!1)}}function pe(t,e,n){const o=t.ownerDocument||t;if(t instanceof Document)return function(t,e=!1,n=!1){let o=Zt(t);for(;o;)se(o,e,n),o=Zt(t)}(o,e,n);Ut.get(o)?.has(t)?ce(t,Ut.get(o),e,n):(le(Ut.get(o)||new Set,e,n),Vt.get(o)?.has(t)&&ce(t,Vt.get(o),e,n))}var ue=new WeakMap;function fe(t){if(!t.isTrusted)return;const e=t.composedPath()[0];if(!e)return;const n=e.ownerDocument;if(!Zt(n))return;const o=function(t){const e=ne(t),n=function(t){for(;t;){const e=t.popoverTargetElement;if(e instanceof HTMLElement)return e;if((t=t.parentElement||ee(t))instanceof It&&(t=t.host),t instanceof Document)return}}(t);return Qt(e)>Qt(n)?e:n}(e);if(o&&"pointerdown"===t.type)ue.set(n,o);else if("pointerup"===t.type){const t=ue.get(n)===o;ue.delete(n),t&&pe(o||n,!1,!0)}}var de=new WeakMap;function he(t,e=!1){if(!t)return;de.has(t)||de.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=de.get(t);e?t.setAttribute("aria-expanded",e):t.removeAttribute("aria-expanded")}}var me=globalThis.ShadowRoot||function(){};function we(t,e,n){const o=t[e];Object.defineProperty(t,e,{value(t){return o.call(this,n(t))}})}var be=/(^|[^\\]):popover-open\b/g;var ge=null;function xe(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===ge)try{(ge=new CSSStyleSheet).replaceSync(e)}catch{ge=!1}if(!1===ge){const n=document.createElement("style");n.textContent=e,t instanceof Document?t.head.prepend(n):t.prepend(n)}else t.adoptedStyleSheets=[ge,...t.adoptedStyleSheets]}var ve=function(t,e,n,o){var r,i=arguments.length,a=i<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,o);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(i<3?r(a):i>3?r(e,n,a):r(e,n))||a);return i>3&&a&&Object.defineProperty(e,n,a),a};const ye="--post-popovercontainer-available-width",Se="--post-popovercontainer-available-height",ke="--post-popovercontainer-safe-space",Me=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.postBeforeShow=n(this,"postBeforeShow",7),this.postShow=n(this,"postShow",7),this.postHide=n(this,"postHide",7),this.postBeforeToggle=n(this,"postBeforeToggle",7),this.postToggle=n(this,"postToggle",7),this.anchorRef=null,this.arrowRef=null,this.hasBeenOpened=!1,this.toggleTimeoutId=null,this.runningAnimation=null,this.stopAutoUpdate=null,this.placement="top",this.edgeGap=8,this.arrow=!1}connectedCallback(){!o.isBrowser||"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(be,"$1.\\:popover-open")),t}window.ToggleEvent=window.ToggleEvent||Pt,we(Document.prototype,"querySelector",t),we(Document.prototype,"querySelectorAll",t),we(Element.prototype,"querySelector",t),we(Element.prototype,"querySelectorAll",t),we(Element.prototype,"matches",t),we(Element.prototype,"closest",t),we(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={}){ae(this)}},hidePopover:{enumerable:!0,configurable:!0,value(){se(this,!0,!0)}},togglePopover:{enumerable:!0,configurable:!0,value(t={}){return"boolean"==typeof t&&(t={force:t}),"showing"===Xt.get(this)&&void 0===t.force||!1===t.force?se(this,!0,!0):void 0!==t.force&&!0!==t.force||ae(this),"showing"===Xt.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 xe(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&&xe(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=ee(this),n=this.getAttribute("popovertarget");return(e instanceof Document||e instanceof me)&&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=ee(n);if(!(o instanceof me||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=Yt(e);"show"===t.popoverTargetAction&&"showing"===n||"hide"===t.popoverTargetAction&&"hidden"===n||("showing"===n?se(e,!0,!0):Kt(e,!1)&&(_t.set(e,t),ae(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||pe(n.ownerDocument,!0,!0)})),i.addEventListener("pointerdown",fe),i.addEventListener("pointerup",fe),xe(document)}()}componentDidLoad(){this.host.addEventListener("beforetoggle",this.handleToggle.bind(this))}disconnectedCallback(){this.cleanup(),this.host.removeEventListener("beforetoggle",this.handleToggle.bind(this))}cleanup(){this.stopAutoUpdate?.(),this.runningAnimation&&(this.runningAnimation.cancel(),this.runningAnimation=null)}isOpen(){return this.host?.matches(":where(:popover-open, .popover-open)")}getContent(){return this.host?.shadowRoot.querySelector('[part="post-popovercontainer-content"]')}getContentMinSize(){const t=this.getContent();if(!t)return{};const{minWidth:e,minHeight:n}=getComputedStyle(t);return{width:Number.parseFloat(e)||0,height:Number.parseFloat(n)||0}}async show(t){this.toggleTimeoutId||!t||this.isOpen()||(this.anchorRef=t,this.host.showPopover())}async hide(){!this.toggleTimeoutId&&this.isOpen()&&(this.anchorRef=null,this.host.hidePopover(),this.postHide.emit())}async toggle(t,e){const n=this.isOpen();if(!this.host||this.toggleTimeoutId)return n;const o=!0===e||void 0===e&&!n;return n===o||o&&!t?n:(this.anchorRef=o?t:null,this.host.togglePopover(e),this.toggleTimeoutId=null,this.isOpen())}async handleToggle(t){this.toggleTimeoutId=globalThis.setTimeout((()=>this.toggleTimeoutId=null),10),"open"===t.newState?await this.handleOpen():await this.handleClose()}async handleOpen(){this.postBeforeToggle.emit({willOpen:!0}),this.postBeforeShow.emit({first:!this.hasBeenOpened}),await this.updatePosition(!0),this.startAutoUpdate();try{await this.runOpenAnimation()}catch{return}this.postToggle.emit({isOpen:!0}),this.postShow.emit({first:!this.hasBeenOpened}),this.hasBeenOpened=!0}async runOpenAnimation(){const t=this.getContent();t&&(this.runningAnimation=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"})}(t),await this.runningAnimation.finished)}async handleClose(){this.postBeforeToggle.emit({willOpen:!1}),this.cleanup(),this.host.style.removeProperty(ye),this.host.style.removeProperty(Se),this.host.style.removeProperty(ke),this.postToggle.emit({isOpen:!1}),this.postHide.emit()}startAutoUpdate(){this.host&&this.anchorRef&&(this.stopAutoUpdate=function(t,e,n,o){void 0===o&&(o={});const{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=o,c=ut(t),p=r||i?[...c?lt(c):[],...e?lt(e):[]]:[];p.forEach((t=>{r&&t.addEventListener("scroll",n),i&&t.addEventListener("resize",n)}));const u=c&&s?function(t,e,n){let o,r=null;const i=N(t);function a(){var t;clearTimeout(o),null==(t=r)||t.disconnect(),r=null}function s(n,l){void 0===n&&(n=!1),void 0===l&&(l=1),a();const c=t.getBoundingClientRect(),{left:p,top:u,width:h,height:w}=c;if(n||e(),!h||!w)return;const b={rootMargin:-m(u)+"px "+-m(i.clientWidth-(p+h))+"px "+-m(i.clientHeight-(u+w))+"px "+-m(p)+"px",threshold:d(0,f(1,l))||1};let g=!0;function x(e){const n=e[0].intersectionRatio;if(!Mt(c,t.getBoundingClientRect()))return s();if(n!==l){if(!g)return s();n?s(!1,n):o=setTimeout((()=>{s(!1,1e-7)}),1e3)}g=!1}try{r=new IntersectionObserver(x,{...b,root:i.ownerDocument})}catch(t){r=new IntersectionObserver(x,b)}r.observe(t)}const l=I(t),c=()=>s(n);return l.addEventListener("resize",c),s(!0),()=>{l.removeEventListener("resize",c),a()}}(c,n,i):null;let h,w=-1,b=null;a&&(b=new ResizeObserver((t=>{let[o]=t;o&&o.target===c&&b&&e&&(b.unobserve(e),cancelAnimationFrame(w),w=requestAnimationFrame((()=>{var t;null==(t=b)||t.observe(e)}))),n()})),c&&!l&&b.observe(c),e&&b.observe(e));let g=l?mt(t):null;return l&&function e(){const o=mt(t);g&&!Mt(g,o)&&n(),g=o,h=requestAnimationFrame(e)}(),n(),()=>{var t;p.forEach((t=>{r&&t.removeEventListener("scroll",n),i&&t.removeEventListener("resize",n)})),null==u||u(),null==(t=b)||t.disconnect(),b=null,l&&cancelAnimationFrame(h)}}(this.anchorRef,this.host,(()=>this.updatePosition(this.autoResize))))}async updatePosition(t=!1){const{x:e,y:n,middlewareData:o,placement:r}=await this.computePosition(t);o.hide?.referenceHidden?this.host.hidePopover():(this.side=v(r),this.host.style.left=`${e}px`,this.host.style.top=`${n}px`,o.arrow&&(this.arrowRef.style.left=o.arrow.x?`${o.arrow.x}px`:"",this.arrowRef.style.top=o.arrow.y?`${o.arrow.y}px`:"",this.arrowRef.style[Lt(this.side)]=`-${this.arrowRef.offsetWidth/2}px`),o[jt]&&this.host.style.setProperty(ke,o[jt].polygon))}async computePosition(t){const e=this.edgeGap??0,n=[Et(this.offset??(this.arrow?e+4:e)),Ht()],o=Ct({padding:e,minSize:this.getContentMinSize()}),r=function(t){return void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:o,placement:r,platform:i}=e,{mainAxis:a=!0,crossAxis:s=!1,limiter:l={fn:t=>{let{x:e,y:n}=t;return{x:e,y:n}}},...c}=x(t,e),p={x:n,y:o},u=await i.detectOverflow(e,c),f=M(r),d=S(f);let h=p[d],m=p[f];const w=(t,e)=>g(e+u["y"===t?"top":"left"],e,e-u["y"===t?"bottom":"right"]);a&&(h=w(d,h)),s&&(m=w(f,m));const b=l.fn({...e,[d]:h,[f]:m});return{...b,data:{x:b.x-n,y:b.y-o,enabled:{[d]:a,[f]:s}}}}}}({limiter:At({offset:32}),padding:e});return this.placement?.includes("-")?n.push(o,r):n.push(r,o),t&&n.push(function(t){return void 0===t&&(t={}),{name:"size",options:t,async fn(e){const{placement:n,rects:o,platform:r,elements:i}=e,{apply:a=()=>{},...s}=x(t,e),l=await r.detectOverflow(e,s),c=v(n),p=y(n),u="y"===M(n),{width:h,height:m}=o.floating;let w,b;"top"===c||"bottom"===c?(w=c,b=p===(await(null==r.isRTL?void 0:r.isRTL(i.floating))?"start":"end")?"left":"right"):(b=c,w="end"===p?"top":"bottom");const g=m-l.top-l.bottom,S=h-l.left-l.right,k=f(m-l[w],g),T=f(h-l[b],S),E=e.middlewareData.shift;let H=k,A=T;null!=E&&E.enabled.x&&(A=S),null!=E&&E.enabled.y&&(H=g),!E&&!p&&(u?A=h-2*d(l.left,l.right):H=m-2*d(l.top,l.bottom)),await a({...e,availableWidth:A,availableHeight:H});const O=await r.getDimensions(i.floating);return h!==O.width||m!==O.height?{reset:{rects:!0}}:{}}}}({padding:e,apply({availableWidth:t,availableHeight:e,elements:n}){n.floating.style.setProperty(ye,`${Math.max(0,t)}px`),n.floating.style.setProperty(Se,`${Math.max(0,e)}px`)}})),this.arrow&&n.push((t=>({name:"arrow",options:t,async fn(e){const{x:n,y:o,placement:r,rects:i,platform:a,elements:s,middlewareData:l}=e,{element:c,padding:p=0}=x(t,e)||{};if(null==c)return{};const u=C(p),d={x:n,y:o},h=T(r),m=k(h),w=await a.getDimensions(c),b="y"===h,v=b?"top":"left",S=b?"bottom":"right",M=b?"clientHeight":"clientWidth",E=i.reference[m]+i.reference[h]-d[h]-i.floating[m],H=d[h]-i.reference[h],A=await(null==a.getOffsetParent?void 0:a.getOffsetParent(c));let O=A?A[M]:0;O&&await(null==a.isElement?void 0:a.isElement(A))||(O=s.floating[M]||i.floating[m]);const L=E/2-H/2,z=O/2-w[m]/2-1,R=f(u[v],z),D=f(u[S],z),$=O-w[m]-D,j=O/2-w[m]/2+L,F=g(R,j,$),W=!l.arrow&&null!=y(r)&&j!==F&&i.reference[m]/2-(j<R?R:D)-w[m]/2<0,P=W?j<R?j-R:j-$:0;return{[h]:d[h]+P,data:{[h]:F,centerOffset:j-F-P,...W&&{alignmentOffset:P}},reset:W}}}))({element:this.arrowRef,padding:e})),this.safeSpace&&n.push({name:jt,async fn(t){const{placement:e,rects:n,x:o,y:r}=t,i=v(e),a=await Ft(t,n.reference),s=[...Wt(await Ft(t,{...n.floating,x:o,y:r}),Lt(i)),...Wt(a,i)],l=[];for(let t=0;t<s.length;t+=2)l.push(`${s[t]}px ${s[t+1]}px`);return{data:{polygon:`polygon(${l.join(", ")})`}}}}),this.autoHide&&n.push(function(t){return void 0===t&&(t={}),{name:"hide",options:t,async fn(e){const{rects:n,platform:o}=e,{strategy:r="referenceHidden",...i}=x(t,e);switch(r){case"referenceHidden":{const t=j(await o.detectOverflow(e,{...i,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:t,referenceHidden:F(t)}}}case"escaped":{const t=j(await o.detectOverflow(e,{...i,altBoundary:!0}),n.floating);return{data:{escapedOffsets:t,escaped:F(t)}}}default:return{}}}}}({strategy:"referenceHidden"})),i=this.anchorRef,a=this.host,s={placement:this.placement??"top",strategy:"fixed",middleware:n},s??={},((t,e,n)=>{const o=new Map,r=null!=n?n:{},i={...kt,...r.platform,_c:o};return(async(t,e,n)=>{const{placement:o="bottom",strategy:r="absolute",middleware:i=[],platform:a}=n,s=a.detectOverflow?a:{...a,detectOverflow:$},l=await(null==a.isRTL?void 0:a.isRTL(e));let c=await a.getElementRects({reference:t,floating:e,strategy:r}),{x:p,y:u}=D(c,o,l),f=o,d=0;const h={};for(let n=0;n<i.length;n++){const m=i[n];if(!m)continue;const{name:w,fn:b}=m,{x:g,y:x,data:v,reset:y}=await b({x:p,y:u,initialPlacement:o,placement:f,strategy:r,middlewareData:h,rects:c,platform:s,elements:{reference:t,floating:e}});p=null!=g?g:p,u=null!=x?x:u,h[w]={...h[w],...v},y&&d<50&&(d++,"object"==typeof y&&(y.placement&&(f=y.placement),y.rects&&(c=!0===y.rects?await a.getElementRects({reference:t,floating:e,strategy:r}):y.rects),({x:p,y:u}=D(c,f,l))),n=-1)}return{x:p,y:u,placement:f,strategy:r,middlewareData:h}})(t,e,{...r,platform:i})})(i,a,{...s,platform:{...$t,...s.platform,[Dt]:new Map}});var i,a,s}render(){return r(i,{key:"d48b21174f74b790f8a72b4294e9f741c3b64d14","data-version":s,popover:"auto"},r("div",{key:"455e84294ecb36e25cc62582eb6c41058f24f6bc",part:"post-popovercontainer-content"},this.arrow&&r("span",{key:"9d11f2596443876123eeaf5a02430d049c1c8b25","data-side":this.side,class:"arrow",ref:t=>this.arrowRef=t}),r("span",{key:"a562460cdfa5539e7d9c23f1d044a2c045df5b9f",part:"post-popovercontainer-border-mask"}),r("slot",{key:"5aa546bbdf6c70e2a0afabf818d421581060f8a7"})))}get host(){return this}static get style(){return'@layer polyfill{@supports not selector(:popover-open){:host([popover]:not(.\\:popover-open)){display:none}}}:host{background-color:rgba(0,0,0,0);border:rgba(0,0,0,0);position:fixed;margin:0;padding:0;overflow:visible}:host [part=post-popovercontainer-content]{-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-box-shadow:var(--post-device-elevation-300);box-shadow:var(--post-device-elevation-300);width:-webkit-max-content;width:-moz-max-content;width:max-content;max-width:var(--post-popovercontainer-available-width);max-height:var(--post-popovercontainer-available-height);color:var(--post-current-fg);background-color:var(--post-current-bg);border-radius:4px;position:relative;display:-ms-flexbox;display:flex}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host [part=post-popovercontainer-content]{border:2px solid rgba(0,0,0,0)}}:host [part=post-popovercontainer-border-mask]{display:none;position:absolute;inset:0;border-radius:4px;pointer-events:none}:host .arrow{--post-popovercontainer-arrow-border: var(--post-popovercontainer-arrow-border-width, 0px) solid var(--post-popovercontainer-arrow-border-color, transparent);position:absolute;width:.5825rem;height:.5825rem;background-color:inherit;rotate:45deg;pointer-events:none;z-index:-1}:host .arrow[data-side=top]{border-bottom-right-radius:2px;border-bottom:var(--post-popovercontainer-arrow-border);border-right:var(--post-popovercontainer-arrow-border)}:host .arrow[data-side=right]{border-bottom-left-radius:2px;border-bottom:var(--post-popovercontainer-arrow-border);border-left:var(--post-popovercontainer-arrow-border)}:host .arrow[data-side=bottom]{border-top-left-radius:2px;border-top:var(--post-popovercontainer-arrow-border);border-left:var(--post-popovercontainer-arrow-border)}:host .arrow[data-side=left]{border-top-right-radius:2px;border-top:var(--post-popovercontainer-arrow-border);border-right:var(--post-popovercontainer-arrow-border)}@media(forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .arrow[data-side=top]{-webkit-border-after:2px solid rgba(0,0,0,0);border-block-end:2px solid rgba(0,0,0,0);-webkit-border-end:2px solid rgba(0,0,0,0);border-inline-end:2px solid rgba(0,0,0,0);bottom:-0.3796735336rem !important}:host .arrow[data-side=left]{-webkit-border-before:2px solid rgba(0,0,0,0);border-block-start:2px solid rgba(0,0,0,0);-webkit-border-end:2px solid rgba(0,0,0,0);border-inline-end:2px solid rgba(0,0,0,0);right:-0.3796735336rem !important}:host .arrow[data-side=right]{-webkit-border-after:2px solid rgba(0,0,0,0);border-block-end:2px solid rgba(0,0,0,0);-webkit-border-start:2px solid rgba(0,0,0,0);border-inline-start:2px solid rgba(0,0,0,0);left:-0.3796735336rem !important}:host .arrow[data-side=bottom]{-webkit-border-before:2px solid rgba(0,0,0,0);border-block-start:2px solid rgba(0,0,0,0);-webkit-border-start:2px solid rgba(0,0,0,0);border-inline-start:2px solid rgba(0,0,0,0);top:-0.3796735336rem !important}}:host([tooltip]){position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0}:host([safe-space])::after{content:"";position:fixed;inset:0;z-index:-1;pointer-events:auto;-webkit-clip-path:var(--post-popovercontainer-safe-space, polygon(0 0, 0 0, 0 0));clip-path:var(--post-popovercontainer-safe-space, polygon(0 0, 0 0, 0 0))}:host(:not(:has(.arrow)))>div{-webkit-box-shadow:var(--post-device-elevation-300);box-shadow:var(--post-device-elevation-300)}:host(:has(.arrow))>div{-webkit-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));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))}:host(:has(.arrow[data-side=top]))>div{-webkit-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));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))}:host(:has(.arrow[data-side=left]))>div{-webkit-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));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))}:host(:has(.arrow[data-side=right]))>div{-webkit-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));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))}'}},[257,"post-popovercontainer",{placement:[1],edgeGap:[2,"edge-gap"],offset:[2],arrow:[4],safeSpace:[516,"safe-space"],autoHide:[4,"auto-hide"],autoResize:[4,"auto-resize"],side:[32],show:[64],hide:[64],toggle:[64]}]);function Te(){"undefined"!=typeof customElements&&["post-popovercontainer"].forEach((t=>{"post-popovercontainer"===t&&(customElements.get(a(t))||customElements.define(a(t),Me))}))}ve([l(p)],Me.prototype,"placement",void 0),ve([c("number")],Me.prototype,"edgeGap",void 0);export{p as P,Me as a,Te as d}
@@ -1 +1 @@
1
- import{proxyCustomElement as t,HTMLElement as e,createEvent as s,h as o,Host as i,transformTag as r}from"@stencil/core/internal/client";import{v as n}from"./package.js";import{b as a}from"./breakpoints.js";import{d as l}from"./post-closebutton2.js";import{d as c}from"./post-icon2.js";import{g as d}from"./get-focusable-children.js";import{R as h}from"./required.js";import{T as p}from"./type.js";import{O as m}from"./one-of.js";var b=function(t,e,s,o){var i,r=arguments.length,n=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,s):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,o);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(n=(r<3?i(n):r>3?i(e,s,n):i(e,s))||n);return r>3&&n&&Object.defineProperty(e,s,n),n};const f=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.postToggle=s(this,"postToggle",7),this.device=a.get("device"),this.size="large",this.breakpointChange=t=>{this.device=t.detail,"desktop"===this.device&&(this.dialog?.open&&this.dialog.close(),this.postToggle.emit(!1))},this.handleKeyDown=t=>{if("Escape"!==t.key)return;const e=this.collapsible;e&&!e.collapsed&&(t.preventDefault(),t.stopPropagation(),e.toggle(!1),this.collapsibleTrigger?.querySelector("button")?.focus())},this.handleDialogClick=t=>{t.composedPath().some((t=>t instanceof HTMLAnchorElement))&&this.dialog.close()}}connectedCallback(){globalThis.addEventListener("postBreakpoint:device",this.breakpointChange),this.host.addEventListener("keydown",this.handleKeyDown)}disconnectedCallback(){globalThis.removeEventListener("postBreakpoint:device",this.breakpointChange),this.host.removeEventListener("keydown",this.handleKeyDown)}get dialog(){return this.host.shadowRoot?.querySelector("dialog")}get collapsibleTrigger(){return document.activeElement?.closest("post-collapsible-trigger")??null}get collapsible(){return this.collapsibleTrigger?.querySelector(":scope > post-collapsible")??null}async toggle(){if("desktop"!==this.device)return this.dialog?.open?this.hide():this.show()}async show(){"desktop"!==this.device&&(this.dialog.showModal(),this.postToggle.emit(!0),this.focusNav())}async hide(){"desktop"!==this.device&&this.dialog.close()}focusNav(){const t=this.host.shadowRoot?.querySelector("slot"),e=t?.assignedElements({flatten:!0})[0];if(!e)return;const[s]=d(e);s?.focus()}renderNav(){return o("slot",null)}renderDialog(){return o("dialog",{onClick:this.handleDialogClick,onClose:()=>{this.postToggle.emit(!1)}},o("slot",null),o("post-closebutton",{onClick:()=>this.hide()},this.textClose))}render(){return o(i,{key:"f7d9b4e515e5085d78e452298bdfbfb2325e7422","data-version":n},"desktop"===this.device?this.renderNav():this.renderDialog())}get host(){return this}static get style(){return":host{display:-ms-flexbox;display:flex}:host,:host dialog{background-color:var(--post-scheme-color-palette-bg-2);-webkit-border-end:var(--post-device-border-width-alternative1) solid var(--post-scheme-color-interactive-primary-enabled-stroke4);border-inline-end:var(--post-device-border-width-alternative1) solid var(--post-scheme-color-interactive-primary-enabled-stroke4)}:host dialog{overflow:visible;width:var(--post-core-dimension-296);bottom:auto;right:auto;border:none;padding:0;max-height:100dvh;-webkit-transform:translateX(-100%);transform:translateX(-100%);-webkit-transition-property:overlay,display,-webkit-transform;transition-property:overlay,display,-webkit-transform;transition-property:transform,overlay,display;transition-property:transform,overlay,display,-webkit-transform;transition-behavior:allow-discrete;-webkit-transition-duration:350ms;transition-duration:350ms;-webkit-box-shadow:var(--post-device-elevation-300);box-shadow:var(--post-device-elevation-300)}:host dialog[open]{-webkit-transform:translateX(0);transform:translateX(0)}@starting-style{:host dialog[open]{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}@media (prefers-reduced-motion: reduce){:host dialog{-webkit-transition:none;transition:none}}:host post-closebutton{-webkit-transform:translate(50%, 0);transform:translate(50%, 0)}"}},[257,"post-side-navigation",{textClose:[513,"text-close"],size:[1],device:[32],toggle:[64],show:[64],hide:[64]}]);b([h(),p("string")],f.prototype,"textClose",void 0),b([m(["large","small"])],f.prototype,"size",void 0);const u=f,v=function(){"undefined"!=typeof customElements&&["post-side-navigation","post-closebutton","post-icon"].forEach((t=>{switch(t){case"post-side-navigation":customElements.get(r(t))||customElements.define(r(t),f);break;case"post-closebutton":customElements.get(r(t))||l();break;case"post-icon":customElements.get(r(t))||c()}}))};export{u as PostSideNavigation,v as defineCustomElement}
1
+ import{proxyCustomElement as t,HTMLElement as e,createEvent as o,h as s,Host as i,transformTag as r}from"@stencil/core/internal/client";import{v as n}from"./package.js";import{b as a}from"./breakpoints.js";import{d as l}from"./post-closebutton2.js";import{d as c}from"./post-icon2.js";import{i as d}from"./is-focus-visible.js";import{g as h}from"./get-focusable-children.js";import{R as p}from"./required.js";import{T as m}from"./type.js";import{O as b}from"./one-of.js";var f=function(t,e,o,s){var i,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,o):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,o,s);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(n=(r<3?i(n):r>3?i(e,o,n):i(e,o))||n);return r>3&&n&&Object.defineProperty(e,o,n),n};const u=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.postToggle=o(this,"postToggle",7),this.device=a.get("device"),this.size="large",this.breakpointChange=t=>{this.device=t.detail,"desktop"===this.device&&(this.dialog?.open&&this.dialog.close(),this.postToggle.emit(!1))},this.handleKeyDown=t=>{if("Escape"!==t.key)return;const e=this.collapsible;e&&!e.collapsed&&(t.preventDefault(),t.stopPropagation(),e.toggle(!1),this.collapsibleTrigger?.querySelector("button")?.focus())},this.handleDialogClick=t=>{t.composedPath().some((t=>t instanceof HTMLAnchorElement))&&this.dialog.close()}}connectedCallback(){globalThis.addEventListener("postBreakpoint:device",this.breakpointChange),this.host.addEventListener("keydown",this.handleKeyDown)}disconnectedCallback(){globalThis.removeEventListener("postBreakpoint:device",this.breakpointChange),this.host.removeEventListener("keydown",this.handleKeyDown)}get dialog(){return this.host.shadowRoot?.querySelector("dialog")}get collapsibleTrigger(){return document.activeElement?.closest("post-collapsible-trigger")??null}get collapsible(){return this.collapsibleTrigger?.querySelector(":scope > post-collapsible")??null}async toggle(){if("desktop"!==this.device)return this.dialog?.open?this.hide():this.show()}async show(){if("desktop"===this.device)return;const t=d(document.activeElement);this.dialog.showModal(),this.postToggle.emit(!0),t&&this.focusNav()}async hide(){"desktop"!==this.device&&this.dialog.close()}focusNav(){const t=this.host.shadowRoot?.querySelector("slot"),e=t?.assignedElements({flatten:!0})[0];if(!e)return;const[o]=h(e);o?.focus()}renderNav(){return s("slot",null)}renderDialog(){return s("dialog",{onClick:this.handleDialogClick,onClose:()=>{this.postToggle.emit(!1)}},s("slot",null),s("post-closebutton",{onClick:()=>this.hide()},this.textClose))}render(){return s(i,{key:"742833fbbbc716630d5fc5cc6289e44e3d05ee17","data-version":n},"desktop"===this.device?this.renderNav():this.renderDialog())}get host(){return this}static get style(){return":host{display:-ms-flexbox;display:flex}:host,:host dialog{background-color:var(--post-scheme-color-palette-bg-2);-webkit-border-end:var(--post-device-border-width-alternative1) solid var(--post-scheme-color-interactive-primary-enabled-stroke4);border-inline-end:var(--post-device-border-width-alternative1) solid var(--post-scheme-color-interactive-primary-enabled-stroke4)}:host dialog{overflow:visible;width:var(--post-core-dimension-296);bottom:auto;right:auto;border:none;padding:0;max-height:100dvh;-webkit-transform:translateX(-100%);transform:translateX(-100%);-webkit-transition-property:overlay,display,-webkit-transform;transition-property:overlay,display,-webkit-transform;transition-property:transform,overlay,display;transition-property:transform,overlay,display,-webkit-transform;transition-behavior:allow-discrete;-webkit-transition-duration:350ms;transition-duration:350ms;-webkit-box-shadow:var(--post-device-elevation-300);box-shadow:var(--post-device-elevation-300)}:host dialog:focus,:host dialog:focus-visible{outline:none}:host dialog[open]{-webkit-transform:translateX(0);transform:translateX(0)}@starting-style{:host dialog[open]{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}@media (prefers-reduced-motion: reduce){:host dialog{-webkit-transition:none;transition:none}}:host post-closebutton{-webkit-transform:translate(50%, 0);transform:translate(50%, 0)}"}},[257,"post-side-navigation",{textClose:[513,"text-close"],size:[1],device:[32],toggle:[64],show:[64],hide:[64]}]);f([p(),m("string")],u.prototype,"textClose",void 0),f([b(["large","small"])],u.prototype,"size",void 0);const v=u,g=function(){"undefined"!=typeof customElements&&["post-side-navigation","post-closebutton","post-icon"].forEach((t=>{switch(t){case"post-side-navigation":customElements.get(r(t))||customElements.define(r(t),u);break;case"post-closebutton":customElements.get(r(t))||l();break;case"post-icon":customElements.get(r(t))||c()}}))};export{v as PostSideNavigation,g as defineCustomElement}
@@ -1 +1 @@
1
- import{proxyCustomElement as t,HTMLElement as e,createEvent as s,h as i,Host as o,transformTag as a,Build as r}from"@stencil/core/internal/client";import{v as n}from"./package.js";import{d as c}from"./post-icon2.js";import{c as l}from"./component-on-ready.js";import{f as h}from"./fade.js";import{O as b}from"./one-of.js";import{T as p}from"./type.js";var d=function(t,e,s,i){var o,a=arguments.length,r=a<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,s,i);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(r=(a<3?o(r):a>3?o(e,s,r):o(e,s))||r);return a>3&&r&&Object.defineProperty(e,s,r),r};const v=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.postChange=s(this,"postChange",7),this.showing=null,this.hiding=null,this.isLoaded=!1,this.isPagesVariant=!1,this.showLeftScrollButton=!1,this.showRightScrollButton=!1,this.textPrevTabItems="Previous tab items",this.textNextTabItems="Next tab items",this.size="large",this.updateScrollButtons=()=>{if(!this.tabsContainer)return;const t=getComputedStyle(this.tabsContainer),e=Number.parseFloat(t.paddingInlineStart)||0,s=Number.parseFloat(t.paddingInlineEnd)||0,i=this.tabsContainer.clientWidth-e-s,o=this.tabsContainer.scrollWidth-e-s;this.showLeftScrollButton=this.tabsContainer.scrollLeft>0,this.showRightScrollButton=this.tabsContainer.scrollLeft+i<o}}get tabs(){return Array.from(this.host.querySelectorAll("post-tab-item")).filter((t=>t.closest("post-tabs")===this.host))}get panels(){return Array.from(this.host.querySelectorAll("post-tab-panel")).filter((t=>t.closest("post-tabs")===this.host))}validateLabel(){this.isPagesVariant&&!this.label&&console.error(`[${this.host.localName}] Property "label" is required in Pages variant. Received: ${JSON.stringify(this.label)}.`,this.host)}componentWillRender(){this.detectVariant()}componentDidLoad(){if(this.leftScrollButton.ariaControlsElements=[this.tabsContainer],this.rightScrollButton.ariaControlsElements=[this.tabsContainer],this.moveMisplacedTabs(),this.moveMisplacedPanels(),this.enableTabs(),this.handleScrollButtons(),this.setupContentObserver(),this.setupResizeObserver(),this.validateLabel(),this.isPagesVariant){const t=this.findActivePagesTab();t&&(this.activateTab(t),this.scrollTabIntoView(t))}else{const t=this.activeTab||this.tabs[0]?.name;if(t){this.show(t);const e=this.tabs.find((e=>e.name===t));e&&this.scrollTabIntoView(e)}}this.isLoaded=!0}disconnectedCallback(){this.showing&&(this.showing.cancel(),this.showing=null),this.hiding&&(this.hiding.cancel(),this.hiding=null),this.contentObserver&&this.contentObserver?.disconnect(),this.resizeObserver?.disconnect(),this.tabsContainer?.removeEventListener("scroll",this.updateScrollButtons)}setupContentObserver(){this.contentObserver=new MutationObserver(this.handleContentChange.bind(this)),this.contentObserver?.observe(this.host,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["data-pages-variant","aria-current"]})}setupResizeObserver(){this.resizeObserver=new ResizeObserver(this.updateScrollButtons),this.resizeObserver.observe(this.tabsContainer)}handleContentChange(t){const e=this.shouldRedetectVariant(t);this.hasAriaCurrentChanged(t)&&this.isPagesVariant&&this.updateActivePagesTab(),e&&this.handleVariantChange(),this.updateScrollButtons()}shouldRedetectVariant(t){return t.some((t=>"childList"===t.type?t.addedNodes.length>0||t.removedNodes.length>0:"attributes"===t.type&&"data-pages-variant"===t.attributeName))}hasAriaCurrentChanged(t){return t.some((t=>"attributes"===t.type&&"aria-current"===t.attributeName))}updateActivePagesTab(){const t=this.findActivePagesTab();t&&t!==this.currentActiveTab&&(this.activateTab(t),this.scrollTabIntoView(t,"smooth"))}handleVariantChange(){const t=this.isPagesVariant;this.detectVariant(),t!==this.isPagesVariant&&(this.enableTabs(),this.initializeActiveTab())}initializeActiveTab(){if(this.isPagesVariant){const t=this.findActivePagesTab();t&&(this.activateTab(t),this.scrollTabIntoView(t))}else{const t=this.activeTab||this.tabs[0]?.name;t&&this.show(t)}}detectVariant(){const t=this.tabs.some((t=>null!==t.querySelector("a")||"true"===t.dataset.pagesVariant));if(t&&this.panels.length>0)throw Error("PostTabs: Mixed mode detected. Cannot use both Page Tabs (anchor elements) and Content Tabs (post-tab-panel elements) variants at the same time.");this.isPagesVariant=t,this.host.classList.remove("page-tabs","content-tabs"),this.host.classList.add(this.isPagesVariant?"page-tabs":"content-tabs")}findActivePagesTab(){return this.tabs.find((t=>null!==t.querySelector('a[aria-current="page"]')))||null}async show(t){try{if(t===this.currentActiveTab?.name)return;const e=this.currentActiveTab,s=this.host.querySelector(`post-tab-item[name="${t}"]`);if(!s)return;if(this.activateTab(s),this.scrollTabIntoView(s,"smooth"),this.showing&&(this.showing.finish(),this.showing=null),!e||this.showing||this.hiding||this.hidePanel(e.name),await this.awaitAnimation(this.hiding))return;if(this.showSelectedPanel(),await this.awaitAnimation(this.showing))return;this.isLoaded&&this.currentActiveTab&&this.postChange.emit(this.currentActiveTab.name)}catch(t){if(this.isAbortError(t))return;throw t}}async awaitAnimation(t){if(!t)return!1;try{return await t.finished,!1}catch(t){if(this.isAbortError(t))return!0;throw t}}isAbortError(t){return(t instanceof DOMException||t instanceof Error)&&"AbortError"===t.name}moveMisplacedTabs(){this.tabs&&this.tabs.forEach((t=>{t.getAttribute("slot")&&t.removeAttribute("slot")}))}moveMisplacedPanels(){this.panels&&this.panels.forEach((t=>{"panels"!==t.getAttribute("slot")&&t.setAttribute("slot","panels")}))}enableTabs(){this.tabs&&(this.tabs.forEach((async t=>{if(await l(t),this.isPagesVariant)return;if(t.getAttribute("aria-controls"))return;const e=this.getPanel(t.name);e&&(t.setAttribute("aria-controls",e.id),e.setAttribute("aria-labelledby",t.id)),t.addEventListener("click",(()=>{this.show(t.name)})),t.addEventListener("keydown",(e=>{if("Enter"!==e.key&&" "!==e.key||(e.preventDefault(),this.show(t.name)),"Home"!==e.key&&"End"!==e.key)return;e.preventDefault();const s=this.tabs.filter((t=>!t.hasAttribute("disabled")));if(0===s.length)return;const i="Home"===e.key?s[0]:s.at(-1);i&&(i?.focus(),this.show(i.name))})),t.addEventListener("keydown",(e=>{"ArrowRight"!==e.key&&"ArrowLeft"!==e.key||this.navigateTabs(t,e.key)}))})),this.currentActiveTab&&!this.currentActiveTab.isConnected&&this.show(this.tabs[0]?.name))}activateTab(t){this.currentActiveTab&&(this.isPagesVariant||(this.currentActiveTab.setAttribute("aria-selected","false"),this.currentActiveTab.setAttribute("tabindex","-1"))),this.isPagesVariant||(t.setAttribute("aria-selected","true"),t.setAttribute("tabindex","0")),this.currentActiveTab=t}hidePanel(t){const e=this.getPanel(t);e&&(this.hiding=h(e,"out"),this.hiding.onfinish=()=>{e.style.display="none",this.hiding=null})}showSelectedPanel(){if(!this.currentActiveTab)return;const t=this.getPanel(this.currentActiveTab.name);t&&(t.style.display="block",this.isLoaded&&(this.showing=h(t,"in"),this.showing.onfinish=()=>{this.showing=null}))}getPanel(t){return this.host.querySelector(`post-tab-panel[for=${t}]`)}navigateTabs(t,e){const s=Array.from(this.tabs).indexOf(t);let i;i="ArrowRight"===e?this.tabs[s+1]||this.tabs[0]:this.tabs[s-1]||this.tabs.at(-1),i&&(i.focus(),this.show(i.name))}scrollTabs(t){const e="prev"===t?-1:1,s=getComputedStyle(this.tabsContainer),i=Number.parseFloat(s.paddingInlineStart)||0,o=Number.parseFloat(s.paddingInlineEnd)||0;this.tabsContainer.scrollBy({left:e*(this.tabsContainer.clientWidth-i-o),behavior:"smooth"})}scrollTabIntoView(t,e="instant"){const s=this.tabsContainer,i=getComputedStyle(s),o=Number.parseFloat(i.paddingInlineStart)||0,a=Number.parseFloat(i.paddingInlineEnd)||0,r=t.offsetLeft,n=r+t.offsetWidth,c=s.scrollLeft+o,l=c+s.clientWidth-o-a;r<c?s.scrollTo({left:r-o,behavior:e}):n>l&&s.scrollTo({left:n-s.clientWidth+a,behavior:e})}handleScrollButtons(){this.updateScrollButtons(),this.tabsContainer.addEventListener("scroll",this.updateScrollButtons)}render(){const t=this.activeTab??this.tabs[0]?.name,e=this.isPagesVariant?"nav":"div";return i(o,{key:"fb65fd2589517dd6d86e86435ec6b3a3b64b093d","data-version":n,style:r.isServer&&!this.isPagesVariant&&t?{["--post-tab-panel-"+t]:"block",["--post-tab-item-"+t]:"1"}:void 0},i("div",{key:"dbcdd791af381ccc23953acb38a8e71527a804ee",class:"tabs-wrapper",part:"post-tabs"},i("button",{key:"20ce30515d80b282aa93f20a1f3281a1ef0f6359",ref:t=>this.leftScrollButton=t,class:"scroll-btn scroll-btn-left",type:"button","aria-label":this.textPrevTabItems,tabindex:this.showLeftScrollButton?0:-1,hidden:!this.showLeftScrollButton,onClick:()=>this.scrollTabs("prev")},i("post-icon",{key:"9a5402a28656d7a4459b9b848425bd15a45a0fce",name:"chevronleft"})),i(e,{key:"e821db02fd66aef6cf7a9fb5d925b0906571f3b6",ref:t=>this.tabsContainer=t,class:"tabs",role:this.isPagesVariant?void 0:"tablist","aria-label":this.isPagesVariant?this.label:void 0},i("slot",{key:"e3650e43ac269173cb58f1624f02778bf094573c",onSlotchange:()=>{this.moveMisplacedTabs(),this.enableTabs()}})),i("button",{key:"4345a9bc121ce187022cddf019d5c86d875a70e9",ref:t=>this.rightScrollButton=t,class:"scroll-btn scroll-btn-right",type:"button","aria-label":this.textNextTabItems,tabindex:this.showRightScrollButton?0:-1,hidden:!this.showRightScrollButton,onClick:()=>this.scrollTabs("next")},i("post-icon",{key:"2df749c1a4e506d9940ce61e077d0f0f330b7342",name:"chevronright"}))),!this.isPagesVariant&&i("div",{key:"184db29a5826af78d142ed1489be33c45831970b",class:"tab-content",part:"post-tabs-content"},i("slot",{key:"4a984c7de97f2f89e7fd0f829f5bc62e2323f056",name:"panels",onSlotchange:()=>this.moveMisplacedPanels()})))}get host(){return this}static get watchers(){return{label:[{validateLabel:0}]}}static get style(){return':host{display:block}:host .tabs-wrapper{position:relative;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}:host .tabs-wrapper button.scroll-btn{padding:0;overflow:visible;border:0;background:none;color:var(--post-scheme-color-interactive-button-secondary-enabled-fg);font:inherit;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:button;-moz-appearance:button;appearance:button;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;-webkit-transition:background-color 100ms,border-color 100ms,color 100ms;transition:background-color 100ms,border-color 100ms,color 100ms;cursor:pointer}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn{background-color:ButtonFace !important}:host .tabs-wrapper button.scroll-btn:hover{background-color:Highlight !important}}:host .tabs-wrapper button.scroll-btn post-icon{color:currentColor}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn post-icon{color:Highlight}}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn:hover post-icon{color:canvas}}:host .tabs-wrapper button.scroll-btn[hidden]{display:none}:host .tabs-wrapper button.scroll-btn{outline-offset:var(--post-device-spacing-padding-44) !important;outline:var(--post-scheme-color-interactive-focus-stroke) none var(--post-device-border-width-focus) !important}:host .tabs-wrapper button.scroll-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){:host .tabs-wrapper button.scroll-btn:is(:focus-visible,:has(:focus-visible),.pretend-focus){-webkit-transition:none;transition:none}:host .tabs-wrapper button.scroll-btn:is(:focus-visible,:has(:focus-visible),.pretend-focus):hover{color:HighlightText;border-color:HighlightText}}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){:host .tabs-wrapper button.scroll-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){:host .tabs-wrapper button.scroll-btn:is(:focus-visible,:focus-within,.pretend-focus){-webkit-transition:none;transition:none}:host .tabs-wrapper button.scroll-btn:is(:focus-visible,:focus-within,.pretend-focus):hover{color:HighlightText;border-color:HighlightText}}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}:host .tabs-wrapper .tabs{overflow-x:hidden;background-color:rgba(0,0,0,0) !important;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-ms-flex-align:end;align-items:end;overscroll-behavior-x:contain;white-space:nowrap;margin-block:0;-webkit-padding-start:0;padding-inline-start:0;list-style:none}:host(.page-tabs){overflow:visible !important}:host(.page-tabs) .tabs-wrapper{margin-inline:calc(-1*(var(--post-container-offset)))}@media screen and (min-width: 1024px){:host(.page-tabs) .tabs-wrapper{margin-inline:calc(-1 * (var(--post-container-offset)) + 20px)}:host(.page-tabs) .tabs-wrapper::after{-webkit-box-shadow:20px 0 0 var(--post-palette-color-nested-tabs-page-stroke),-20px 0 0 var(--post-palette-color-nested-tabs-page-stroke);box-shadow:20px 0 0 var(--post-palette-color-nested-tabs-page-stroke),-20px 0 0 var(--post-palette-color-nested-tabs-page-stroke)}}@media screen and (min-width: 1024px)and (forced-colors: active),screen and (min-width: 1024px)and (-ms-high-contrast: active),screen and (min-width: 1024px)and (-ms-high-contrast: white-on-black){:host(.page-tabs) .tabs-wrapper::after{-webkit-box-shadow:20px 0 0 LinkText,-20px 0 0 LinkText;box-shadow:20px 0 0 LinkText,-20px 0 0 LinkText}}:host(.page-tabs) .tabs-wrapper button.scroll-btn{color:var(--post-scheme-color-interactive-primary-enabled-fg5);background-color:var(--post-scheme-color-interactive-primary-enabled-bg5);border:var(--post-device-border-width-default) solid var(--post-scheme-color-interactive-primary-enabled-stroke);position:absolute;z-index:2;-webkit-box-shadow:var(--post-device-elevation-200);box-shadow:var(--post-device-elevation-200);border-radius:var(--post-device-border-radius-2)}:host(.page-tabs) .tabs-wrapper button.scroll-btn:hover{border-color:var(--post-scheme-color-interactive-primary-hover-stroke) !important;color:var(--post-scheme-color-interactive-primary-hover-fg4);background-color:var(--post-scheme-color-interactive-primary-hover-bg8)}:host(.page-tabs) .tabs-wrapper button.scroll-btn.scroll-btn-left{inset-inline-start:0;-webkit-border-start:none;border-inline-start:none;border-radius:0 var(--post-device-border-radius-2) var(--post-device-border-radius-2) 0}:host(.page-tabs) .tabs-wrapper button.scroll-btn.scroll-btn-right{inset-inline-end:0;-webkit-border-end:none;border-inline-end:none;border-radius:var(--post-device-border-radius-2) 0 0 var(--post-device-border-radius-2)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host(.page-tabs) .tabs-wrapper button.scroll-btn.scroll-btn{background-color:Highlight;color:HighlightText}}:host(.page-tabs) .tabs-wrapper::after{content:"";position:absolute;inset-block-end:0;inset-inline-start:0;width:100%;height:var(--post-device-border-width-default);background-color:var(--post-palette-color-nested-tabs-page-stroke)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host(.page-tabs) .tabs-wrapper::after{background-color:LinkText}}:host(.page-tabs) .tabs-wrapper .tabs{padding-inline:calc(var(--post-container-offset));gap:var(--post-device-spacing-gap-inline-5);scrollbar-width:none}:host(.page-tabs) .tabs-wrapper .tabs::-webkit-scrollbar{display:none}:host(.page-tabs:not([size=small])) button.scroll-btn{top:var(--post-device-spacing-padding-36)}:host(.page-tabs[size=small]) button.scroll-btn{top:var(--post-device-spacing-padding-36)}:host(.content-tabs) .tabs-wrapper button.scroll-btn{-ms-flex-negative:0;flex-shrink:0;color:var(--post-scheme-color-interactive-button-tertiary-enabled-fg)}:host(.content-tabs) .tabs-wrapper button.scroll-btn:hover{border-color:var(--post-scheme-color-interactive-primary-hover-stroke) !important;color:var(--post-scheme-color-interactive-button-tertiary-hover-fg)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host(.content-tabs) .tabs-wrapper button.scroll-btn:hover{color:HighlightText}}:host(post-tabs:not([size=small])) button.scroll-btn{height:var(--post-device-sizing-interactive-button-height-10);width:var(--post-device-sizing-interactive-button-width-1);border-radius:var(--post-device-border-radius-2)}:host(post-tabs:not([size=small])) button.scroll-btn post-icon{height:var(--post-device-sizing-interactive-icon-size5);width:var(--post-device-sizing-interactive-icon-size5)}:host(.page-tabs:not([size=small])) button.scroll-btn-left{padding-inline:var(--post-device-spacing-padding-39) var(--post-device-spacing-padding-40)}:host(.page-tabs:not([size=small])) button.scroll-btn-right{padding-inline:var(--post-device-spacing-padding-40) var(--post-device-spacing-padding-39)}:host([size=small]) button.scroll-btn{height:var(--post-device-sizing-interactive-button-size-1);width:var(--post-device-sizing-interactive-button-size-1);border-radius:var(--post-device-border-radius-2)}:host([size=small]) button.scroll-btn post-icon{height:var(--post-device-sizing-interactive-icon-size4);width:var(--post-device-sizing-interactive-icon-size4)}:host(.page-tabs[size=small]) button.scroll-btn-left{padding-inline:var(--post-device-spacing-padding-42) var(--post-device-spacing-padding-43)}:host(.page-tabs[size=small]) button.scroll-btn-right{padding-inline:var(--post-device-spacing-padding-43) var(--post-device-spacing-padding-42)}'}},[257,"post-tabs",{textPrevTabItems:[513,"text-prev-tab-items"],textNextTabItems:[513,"text-next-tab-items"],activeTab:[513,"active-tab"],size:[513],label:[513],isPagesVariant:[32],showLeftScrollButton:[32],showRightScrollButton:[32],show:[64]},void 0,{label:[{validateLabel:0}]}]);d([b(["small","large"])],v.prototype,"size",void 0),d([p("string")],v.prototype,"label",void 0);const u=v,g=function(){"undefined"!=typeof customElements&&["post-tabs","post-icon"].forEach((t=>{switch(t){case"post-tabs":customElements.get(a(t))||customElements.define(a(t),v);break;case"post-icon":customElements.get(a(t))||c()}}))};export{u as PostTabs,g as defineCustomElement}
1
+ import{proxyCustomElement as t,HTMLElement as e,createEvent as s,h as i,Host as o,transformTag as r,Build as a}from"@stencil/core/internal/client";import{v as n}from"./package.js";import{d as c}from"./post-icon2.js";import{c as l}from"./component-on-ready.js";import{f as h}from"./fade.js";import{O as b}from"./one-of.js";import{T as p}from"./type.js";var d=function(t,e,s,i){var o,r=arguments.length,a=r<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,s,i);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(a=(r<3?o(a):r>3?o(e,s,a):o(e,s))||a);return r>3&&a&&Object.defineProperty(e,s,a),a};const v=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.postChange=s(this,"postChange",7),this.showing=null,this.hiding=null,this.isLoaded=!1,this.isPagesVariant=!1,this.showLeftScrollButton=!1,this.showRightScrollButton=!1,this.textPrevTabItems="Previous tab items",this.textNextTabItems="Next tab items",this.size="large",this.updateScrollButtons=()=>{if(!this.tabsContainer)return;const t=getComputedStyle(this.tabsContainer),e=Number.parseFloat(t.paddingInlineStart)||0,s=Number.parseFloat(t.paddingInlineEnd)||0,i=this.tabsContainer.clientWidth-e-s,o=this.tabsContainer.scrollWidth-e-s;this.showLeftScrollButton=this.tabsContainer.scrollLeft>0,this.showRightScrollButton=this.tabsContainer.scrollLeft+i<o}}get tabs(){return Array.from(this.host.querySelectorAll("post-tab-item")).filter((t=>t.closest("post-tabs")===this.host))}get panels(){return Array.from(this.host.querySelectorAll("post-tab-panel")).filter((t=>t.closest("post-tabs")===this.host))}validateLabel(){this.isPagesVariant&&!this.label&&console.error(`[${this.host.localName}] Property "label" is required in Pages variant. Received: ${JSON.stringify(this.label)}.`,this.host)}componentWillRender(){this.detectVariant()}componentDidLoad(){if(this.leftScrollButton.ariaControlsElements=[this.tabsContainer],this.rightScrollButton.ariaControlsElements=[this.tabsContainer],this.moveMisplacedTabs(),this.moveMisplacedPanels(),this.enableTabs(),this.handleScrollButtons(),this.setupContentObserver(),this.setupResizeObserver(),this.validateLabel(),this.isPagesVariant){const t=this.findActivePagesTab();t&&(this.activateTab(t),this.scrollTabIntoView(t))}else{const t=this.activeTab||this.tabs[0]?.name;if(t){this.show(t);const e=this.tabs.find((e=>e.name===t));e&&this.scrollTabIntoView(e)}}this.isLoaded=!0}disconnectedCallback(){this.showing&&(this.showing.cancel(),this.showing=null),this.hiding&&(this.hiding.cancel(),this.hiding=null),this.contentObserver&&this.contentObserver?.disconnect(),this.resizeObserver?.disconnect(),this.tabsContainer?.removeEventListener("scroll",this.updateScrollButtons)}setupContentObserver(){this.contentObserver=new MutationObserver(this.handleContentChange.bind(this)),this.contentObserver?.observe(this.host,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["data-pages-variant","aria-current"]})}setupResizeObserver(){this.resizeObserver=new ResizeObserver(this.updateScrollButtons),this.resizeObserver.observe(this.tabsContainer)}handleContentChange(t){const e=this.shouldRedetectVariant(t);this.hasAriaCurrentChanged(t)&&this.isPagesVariant&&this.updateActivePagesTab(),e&&this.handleVariantChange(),this.updateScrollButtons()}shouldRedetectVariant(t){return t.some((t=>"childList"===t.type?t.addedNodes.length>0||t.removedNodes.length>0:"attributes"===t.type&&"data-pages-variant"===t.attributeName))}hasAriaCurrentChanged(t){return t.some((t=>"attributes"===t.type&&"aria-current"===t.attributeName))}updateActivePagesTab(){const t=this.findActivePagesTab();t&&t!==this.currentActiveTab&&(this.activateTab(t),this.scrollTabIntoView(t,"smooth"))}handleVariantChange(){const t=this.isPagesVariant;this.detectVariant(),t!==this.isPagesVariant&&(this.enableTabs(),this.initializeActiveTab())}initializeActiveTab(){if(this.isPagesVariant){const t=this.findActivePagesTab();t&&(this.activateTab(t),this.scrollTabIntoView(t))}else{const t=this.activeTab||this.tabs[0]?.name;t&&this.show(t)}}detectVariant(){const t=this.tabs.some((t=>null!==t.querySelector("a")||"true"===t.dataset.pagesVariant));if(t&&this.panels.length>0)throw Error("PostTabs: Mixed mode detected. Cannot use both Page Tabs (anchor elements) and Content Tabs (post-tab-panel elements) variants at the same time.");this.isPagesVariant=t,this.host.classList.remove("page-tabs","content-tabs"),this.host.classList.add(this.isPagesVariant?"page-tabs":"content-tabs")}findActivePagesTab(){return this.tabs.find((t=>null!==t.querySelector('a[aria-current="page"]')))||null}async show(t){try{if(t===this.currentActiveTab?.name)return;const e=this.currentActiveTab,s=this.host.querySelector(`post-tab-item[name="${t}"]`);if(!s)return;if(this.activateTab(s),this.scrollTabIntoView(s,"smooth"),this.showing&&(this.showing.finish(),this.showing=null),!e||this.showing||this.hiding||this.hidePanel(e.name),await this.awaitAnimation(this.hiding))return;if(this.showSelectedPanel(),await this.awaitAnimation(this.showing))return;this.isLoaded&&this.currentActiveTab&&this.postChange.emit(this.currentActiveTab.name)}catch(t){if(this.isAbortError(t))return;throw t}}async awaitAnimation(t){if(!t)return!1;try{return await t.finished,!1}catch(t){if(this.isAbortError(t))return!0;throw t}}isAbortError(t){return(t instanceof DOMException||t instanceof Error)&&"AbortError"===t.name}moveMisplacedTabs(){this.tabs&&this.tabs.forEach((t=>{t.getAttribute("slot")&&t.removeAttribute("slot")}))}moveMisplacedPanels(){this.panels&&this.panels.forEach((t=>{"panels"!==t.getAttribute("slot")&&t.setAttribute("slot","panels")}))}enableTabs(){this.tabs&&(this.tabs.forEach((async t=>{if(await l(t),this.isPagesVariant)return;if(t.getAttribute("aria-controls"))return;const e=this.getPanel(t.name);e&&(t.setAttribute("aria-controls",e.id),e.setAttribute("aria-labelledby",t.id)),t.addEventListener("click",(()=>{this.show(t.name)})),t.addEventListener("keydown",(e=>{if("Enter"!==e.key&&" "!==e.key||(e.preventDefault(),this.show(t.name)),"Home"!==e.key&&"End"!==e.key)return;e.preventDefault();const s=this.tabs.filter((t=>!t.hasAttribute("disabled")));if(0===s.length)return;const i="Home"===e.key?s[0]:s.at(-1);i&&(i?.focus(),this.show(i.name))})),t.addEventListener("keydown",(e=>{"ArrowRight"!==e.key&&"ArrowLeft"!==e.key||this.navigateTabs(t,e.key)}))})),this.currentActiveTab&&!this.currentActiveTab.isConnected&&this.show(this.tabs[0]?.name))}activateTab(t){this.currentActiveTab&&(this.isPagesVariant||(this.currentActiveTab.setAttribute("aria-selected","false"),this.currentActiveTab.setAttribute("tabindex","-1"))),this.isPagesVariant||(t.setAttribute("aria-selected","true"),t.setAttribute("tabindex","0")),this.currentActiveTab=t}hidePanel(t){const e=this.getPanel(t);e&&(this.hiding=h(e,"out"),this.hiding.onfinish=()=>{e.style.display="none",this.hiding=null})}showSelectedPanel(){if(!this.currentActiveTab)return;const t=this.getPanel(this.currentActiveTab.name);t&&(t.style.display="block",this.isLoaded&&(this.showing=h(t,"in"),this.showing.onfinish=()=>{this.showing=null}))}getPanel(t){return this.host.querySelector(`post-tab-panel[for=${t}]`)}navigateTabs(t,e){const s=Array.from(this.tabs).indexOf(t);let i;i="ArrowRight"===e?this.tabs[s+1]||this.tabs[0]:this.tabs[s-1]||this.tabs.at(-1),i&&(i.focus(),this.show(i.name))}scrollTabs(t){const e="prev"===t?-1:1,s=getComputedStyle(this.tabsContainer),i=Number.parseFloat(s.paddingInlineStart)||0,o=Number.parseFloat(s.paddingInlineEnd)||0;this.tabsContainer.scrollBy({left:e*(this.tabsContainer.clientWidth-i-o),behavior:"smooth"})}scrollTabIntoView(t,e="instant"){const s=this.tabsContainer,i=getComputedStyle(s),o=Number.parseFloat(i.paddingInlineStart)||0,r=Number.parseFloat(i.paddingInlineEnd)||0,a=t.offsetLeft,n=a+t.offsetWidth,c=s.scrollLeft+o,l=c+s.clientWidth-o-r;a<c?s.scrollTo({left:a-o,behavior:e}):n>l&&s.scrollTo({left:n-s.clientWidth+r,behavior:e})}handleScrollButtons(){this.updateScrollButtons(),this.tabsContainer.addEventListener("scroll",this.updateScrollButtons)}render(){const t=this.activeTab??this.tabs[0]?.name,e=this.isPagesVariant?"nav":"div";return i(o,{key:"fb65fd2589517dd6d86e86435ec6b3a3b64b093d","data-version":n,style:a.isServer&&!this.isPagesVariant&&t?{["--post-tab-panel-"+t]:"block",["--post-tab-item-"+t]:"1"}:void 0},i("div",{key:"dbcdd791af381ccc23953acb38a8e71527a804ee",class:"tabs-wrapper",part:"post-tabs"},i("button",{key:"e14933611fd38f647219a6885b879f93e7bdd4d7",ref:t=>this.leftScrollButton=t,class:"scroll-btn scroll-btn-left",type:"button","aria-label":this.textPrevTabItems,tabindex:-1,hidden:!this.showLeftScrollButton,onClick:()=>this.scrollTabs("prev")},i("post-icon",{key:"c1bf9a6f438f2b6519a90b20c26c292143239323",name:"chevronleft"})),i(e,{key:"b7f3357cdab40e7e0d9c290c922803eccb00ec81",ref:t=>this.tabsContainer=t,class:"tabs",role:this.isPagesVariant?void 0:"tablist","aria-label":this.isPagesVariant?this.label:void 0},i("slot",{key:"4e4487253b64f4ec1f0454e711de7b1d3240dc32",onSlotchange:()=>{this.moveMisplacedTabs(),this.enableTabs()}})),i("button",{key:"415ca5611f57f8af18135ae3cdd18ca33964aba5",ref:t=>this.rightScrollButton=t,class:"scroll-btn scroll-btn-right",type:"button","aria-label":this.textNextTabItems,tabindex:-1,hidden:!this.showRightScrollButton,onClick:()=>this.scrollTabs("next")},i("post-icon",{key:"42e4d6ff41b39a94b9480d3ec477a2f93e876d4f",name:"chevronright"}))),!this.isPagesVariant&&i("div",{key:"5c529d848c9bb7221d06324c03e98c55a3ef61b6",class:"tab-content",part:"post-tabs-content"},i("slot",{key:"76c701c2ecb17d762bdf96c2970f5b69a6871301",name:"panels",onSlotchange:()=>this.moveMisplacedPanels()})))}get host(){return this}static get watchers(){return{label:[{validateLabel:0}]}}static get style(){return':host{display:block}:host .tabs-wrapper{position:relative;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}:host .tabs-wrapper button.scroll-btn{padding:0;overflow:visible;border:0;background:none;color:var(--post-scheme-color-interactive-button-secondary-enabled-fg);font:inherit;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:button;-moz-appearance:button;appearance:button;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;-webkit-transition:background-color 100ms,border-color 100ms,color 100ms;transition:background-color 100ms,border-color 100ms,color 100ms;cursor:pointer}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn{background-color:ButtonFace !important}:host .tabs-wrapper button.scroll-btn:hover{background-color:Highlight !important}}:host .tabs-wrapper button.scroll-btn post-icon{color:currentColor}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn post-icon{color:Highlight}}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn:hover post-icon{color:canvas}}:host .tabs-wrapper button.scroll-btn[hidden]{display:none}:host .tabs-wrapper button.scroll-btn{outline-offset:var(--post-device-spacing-padding-44) !important;outline:var(--post-scheme-color-interactive-focus-stroke) none var(--post-device-border-width-focus) !important}:host .tabs-wrapper button.scroll-btn: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 .tabs-wrapper button.scroll-btn:focus-visible{-webkit-transition:none;transition:none}:host .tabs-wrapper button.scroll-btn:focus-visible:hover{color:HighlightText;border-color:HighlightText}}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn:focus-visible{outline-color:Highlight !important}}:host .tabs-wrapper button.scroll-btn.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){:host .tabs-wrapper button.scroll-btn.pretend-focus{-webkit-transition:none;transition:none}:host .tabs-wrapper button.scroll-btn.pretend-focus:hover{color:HighlightText;border-color:HighlightText}}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn.pretend-focus{outline-color:Highlight !important}}:host .tabs-wrapper button.scroll-btn:has(: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 .tabs-wrapper button.scroll-btn:has(:focus-visible){-webkit-transition:none;transition:none}:host .tabs-wrapper button.scroll-btn:has(:focus-visible):hover{color:HighlightText;border-color:HighlightText}}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn:has(:focus-visible){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){:host .tabs-wrapper button.scroll-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){:host .tabs-wrapper button.scroll-btn:is(:focus-visible,:focus-within,.pretend-focus){-webkit-transition:none;transition:none}:host .tabs-wrapper button.scroll-btn:is(:focus-visible,:focus-within,.pretend-focus):hover{color:HighlightText;border-color:HighlightText}}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host .tabs-wrapper button.scroll-btn:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}:host .tabs-wrapper .tabs{overflow-x:hidden;background-color:rgba(0,0,0,0) !important;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-ms-flex-align:end;align-items:end;overscroll-behavior-x:contain;white-space:nowrap;margin-block:0;-webkit-padding-start:0;padding-inline-start:0;list-style:none}:host(.page-tabs){overflow:visible !important}:host(.page-tabs) .tabs-wrapper{margin-inline:calc(-1*(var(--post-container-offset)))}@media screen and (min-width: 1024px){:host(.page-tabs) .tabs-wrapper{margin-inline:calc(-1 * (var(--post-container-offset)) + 20px)}:host(.page-tabs) .tabs-wrapper::after{-webkit-box-shadow:20px 0 0 var(--post-palette-color-nested-tabs-page-stroke),-20px 0 0 var(--post-palette-color-nested-tabs-page-stroke);box-shadow:20px 0 0 var(--post-palette-color-nested-tabs-page-stroke),-20px 0 0 var(--post-palette-color-nested-tabs-page-stroke)}}@media screen and (min-width: 1024px)and (forced-colors: active),screen and (min-width: 1024px)and (-ms-high-contrast: active),screen and (min-width: 1024px)and (-ms-high-contrast: white-on-black){:host(.page-tabs) .tabs-wrapper::after{-webkit-box-shadow:20px 0 0 LinkText,-20px 0 0 LinkText;box-shadow:20px 0 0 LinkText,-20px 0 0 LinkText}}:host(.page-tabs) .tabs-wrapper button.scroll-btn{color:var(--post-scheme-color-interactive-primary-enabled-fg5);background-color:var(--post-scheme-color-interactive-primary-enabled-bg5);border:var(--post-device-border-width-default) solid var(--post-scheme-color-interactive-primary-enabled-stroke);position:absolute;z-index:2;-webkit-box-shadow:var(--post-device-elevation-200);box-shadow:var(--post-device-elevation-200);border-radius:var(--post-device-border-radius-2)}:host(.page-tabs) .tabs-wrapper button.scroll-btn:hover{border-color:var(--post-scheme-color-interactive-primary-hover-stroke) !important;color:var(--post-scheme-color-interactive-primary-hover-fg4);background-color:var(--post-scheme-color-interactive-primary-hover-bg8)}:host(.page-tabs) .tabs-wrapper button.scroll-btn.scroll-btn-left{inset-inline-start:0;-webkit-border-start:none;border-inline-start:none;border-radius:0 var(--post-device-border-radius-2) var(--post-device-border-radius-2) 0}:host(.page-tabs) .tabs-wrapper button.scroll-btn.scroll-btn-right{inset-inline-end:0;-webkit-border-end:none;border-inline-end:none;border-radius:var(--post-device-border-radius-2) 0 0 var(--post-device-border-radius-2)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host(.page-tabs) .tabs-wrapper button.scroll-btn.scroll-btn{background-color:Highlight;color:HighlightText}}:host(.page-tabs) .tabs-wrapper::after{content:"";position:absolute;inset-block-end:0;inset-inline-start:0;width:100%;height:var(--post-device-border-width-default);background-color:var(--post-palette-color-nested-tabs-page-stroke)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host(.page-tabs) .tabs-wrapper::after{background-color:LinkText}}:host(.page-tabs) .tabs-wrapper .tabs{padding-inline:calc(var(--post-container-offset));gap:var(--post-device-spacing-gap-inline-5);scrollbar-width:none}:host(.page-tabs) .tabs-wrapper .tabs::-webkit-scrollbar{display:none}:host(.page-tabs:not([size=small])) button.scroll-btn{top:var(--post-device-spacing-padding-36)}:host(.page-tabs[size=small]) button.scroll-btn{top:var(--post-device-spacing-padding-36)}:host(.content-tabs) .tabs-wrapper button.scroll-btn{-ms-flex-negative:0;flex-shrink:0;color:var(--post-scheme-color-interactive-button-tertiary-enabled-fg)}:host(.content-tabs) .tabs-wrapper button.scroll-btn:hover{border-color:var(--post-scheme-color-interactive-primary-hover-stroke) !important;color:var(--post-scheme-color-interactive-button-tertiary-hover-fg)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host(.content-tabs) .tabs-wrapper button.scroll-btn:hover{color:HighlightText}}:host(post-tabs:not([size=small])) button.scroll-btn{height:var(--post-device-sizing-interactive-button-height-10);width:var(--post-device-sizing-interactive-button-width-1);border-radius:var(--post-device-border-radius-2)}:host(post-tabs:not([size=small])) button.scroll-btn post-icon{height:var(--post-device-sizing-interactive-icon-size5);width:var(--post-device-sizing-interactive-icon-size5)}:host(.page-tabs:not([size=small])) button.scroll-btn-left{padding-inline:var(--post-device-spacing-padding-39) var(--post-device-spacing-padding-40)}:host(.page-tabs:not([size=small])) button.scroll-btn-right{padding-inline:var(--post-device-spacing-padding-40) var(--post-device-spacing-padding-39)}:host([size=small]) button.scroll-btn{height:var(--post-device-sizing-interactive-button-size-1);width:var(--post-device-sizing-interactive-button-size-1);border-radius:var(--post-device-border-radius-2)}:host([size=small]) button.scroll-btn post-icon{height:var(--post-device-sizing-interactive-icon-size4);width:var(--post-device-sizing-interactive-icon-size4)}:host(.page-tabs[size=small]) button.scroll-btn-left{padding-inline:var(--post-device-spacing-padding-42) var(--post-device-spacing-padding-43)}:host(.page-tabs[size=small]) button.scroll-btn-right{padding-inline:var(--post-device-spacing-padding-43) var(--post-device-spacing-padding-42)}'}},[257,"post-tabs",{textPrevTabItems:[513,"text-prev-tab-items"],textNextTabItems:[513,"text-next-tab-items"],activeTab:[513,"active-tab"],size:[513],label:[513],isPagesVariant:[32],showLeftScrollButton:[32],showRightScrollButton:[32],show:[64]},void 0,{label:[{validateLabel:0}]}]);d([b(["small","large"])],v.prototype,"size",void 0),d([p("string")],v.prototype,"label",void 0);const u=v,g=function(){"undefined"!=typeof customElements&&["post-tabs","post-icon"].forEach((t=>{switch(t){case"post-tabs":customElements.get(r(t))||customElements.define(r(t),v);break;case"post-icon":customElements.get(r(t))||c()}}))};export{u as PostTabs,g as defineCustomElement}
@@ -1 +1 @@
1
- import{proxyCustomElement as t,HTMLElement as e,Build as i,h as s,Host as o,transformTag as n}from"@stencil/core/internal/client";import{v as r}from"./package.js";import{R as h}from"./required.js";import{T as a}from"./type.js";const l=["pointerenter","pointerleave","focusin","focusout"];let c;const p=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.delay=0,this.trigger=null,this.delayTimeout=null,this.boundTriggerHandler=this.handleTriggerEvent.bind(this),this.boundTooltipHandler=this.handleTooltipEvent.bind(this)}get tooltip(){if(i.isServer)return null;const t=document.getElementById(this.for);return"post-tooltip"===t?.localName?t:null}componentWillLoad(){i.isBrowser&&import("./focusable.js").then((function(t){return t.f})).then((t=>{c??=t.default}))}componentDidLoad(){this.setupTrigger(),this.attachListeners(),this.attachTooltipListeners()}disconnectedCallback(){this.removeListeners(),this.removeTooltipListeners(),this.cleanupTrigger(),this.delayTimeout&&(clearTimeout(this.delayTimeout),this.delayTimeout=null)}handleSlotChange(){this.cleanupTrigger(),this.setupTrigger()}cleanupTrigger(){if(this.trigger){const t=this.trigger.getAttribute("aria-describedby")||"";if(t.includes(this.for)){const e=t.split(" ").filter((t=>t!==this.for)).join(" ");e?this.trigger.setAttribute("aria-describedby",e):this.trigger.removeAttribute("aria-describedby")}this.trigger=null}}setupTrigger(){if(this.trigger=this.host.querySelector("*"),this.trigger){c?.(this.trigger)||this.trigger.setAttribute("tabindex","0");const t=this.trigger.getAttribute("aria-describedby")||"";t.includes(this.for)||this.trigger.setAttribute("aria-describedby",`${t} ${this.for}`.trim())}else console.warn("No content found in the post-tooltip-trigger slot. Please insert a focusable element or content that can receive focus.")}attachListeners(){l.forEach((t=>{this.host.addEventListener(t,this.boundTriggerHandler)}))}removeListeners(){l.forEach((t=>{this.host.removeEventListener(t,this.boundTriggerHandler)}))}attachTooltipListeners(){this.tooltip&&(this.tooltip.addEventListener("pointerenter",this.boundTooltipHandler),this.tooltip.addEventListener("pointerleave",this.boundTooltipHandler))}removeTooltipListeners(){this.tooltip&&(this.tooltip.removeEventListener("pointerenter",this.boundTooltipHandler),this.tooltip.removeEventListener("pointerleave",this.boundTooltipHandler))}handleTriggerEvent(t){switch(t.type){case"pointerenter":case"focusin":case"long-press":this.handleEnter();break;case"pointerleave":case"focusout":this.handleLeave(t)}}handleTooltipEvent(t){switch(t.type){case"pointerenter":this.handleEnter();break;case"pointerleave":this.handleLeave(t)}}handleEnter(){this.delayTimeout&&(clearTimeout(this.delayTimeout),this.delayTimeout=null),this.interestHandler()}handleLeave(t){const e=t.relatedTarget;this.tooltip&&e&&this.tooltip.contains(e)||e===this.trigger||this.interestLostHandler()}interestHandler(){this.trigger&&(this.delay>0?this.delayTimeout=globalThis.setTimeout((()=>{this.tooltip?.show(this.trigger),this.delayTimeout=null}),this.delay):this.tooltip?.show(this.trigger))}interestLostHandler(){this.delayTimeout&&(clearTimeout(this.delayTimeout),this.delayTimeout=null),this.tooltip?.hide()}render(){return s(o,{key:"55adc12f457aa8a5dd4357ed27876b0e526f7ae3","data-version":r},s("slot",{key:"84da1734ae1c1ac9376caa693108e3ed54bf176f",onSlotchange:()=>this.handleSlotChange()}))}get host(){return this}static get style(){return"post-tooltip-trigger{vertical-align:top}:host{cursor:pointer}"}},[257,"post-tooltip-trigger",{for:[513],delay:[2]}]);!function(t,e,i,s){var o,n=arguments.length,r=n<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var h=t.length-1;h>=0;h--)(o=t[h])&&(r=(n<3?o(r):n>3?o(e,i,r):o(e,i))||r);n>3&&r&&Object.defineProperty(e,i,r)}([h(),a("string")],p.prototype,"for",void 0);const u=p,d=function(){"undefined"!=typeof customElements&&["post-tooltip-trigger"].forEach((t=>{"post-tooltip-trigger"===t&&(customElements.get(n(t))||customElements.define(n(t),p))}))};export{u as PostTooltipTrigger,d as defineCustomElement}
1
+ import{proxyCustomElement as t,HTMLElement as e,Build as i,h as s,Host as o,transformTag as n}from"@stencil/core/internal/client";import{v as r}from"./package.js";import{R as h}from"./required.js";import{T as l}from"./type.js";const c=["pointerenter","pointerleave","focusin","focusout"];let a;const p=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.delay=0,this.trigger=null,this.delayTimeout=null,this.boundTriggerHandler=this.handleTriggerEvent.bind(this),this.boundTooltipHandler=this.handleTooltipEvent.bind(this)}get tooltip(){if(i.isServer)return null;const t=document.getElementById(this.for);return"post-tooltip"===t?.localName?t:null}componentWillLoad(){i.isBrowser&&import("./focusable.js").then((function(t){return t.f})).then((t=>{a??=t.default}))}componentDidLoad(){this.setupTrigger(),this.attachListeners(),this.attachTooltipListeners()}disconnectedCallback(){this.removeListeners(),this.removeTooltipListeners(),this.cleanupTrigger(),this.delayTimeout&&(clearTimeout(this.delayTimeout),this.delayTimeout=null)}handleSlotChange(){this.cleanupTrigger(),this.setupTrigger()}cleanupTrigger(){if(this.trigger){const t=this.trigger.getAttribute("aria-describedby")||"";if(t.includes(this.for)){const e=t.split(" ").filter((t=>t!==this.for)).join(" ");e?this.trigger.setAttribute("aria-describedby",e):this.trigger.removeAttribute("aria-describedby")}this.trigger=null}}setupTrigger(){if(this.trigger=this.host.querySelector("*"),this.trigger){a?.(this.trigger)||this.trigger.setAttribute("tabindex","0");const t=this.trigger.getAttribute("aria-describedby")||"";t.includes(this.for)||this.trigger.setAttribute("aria-describedby",`${t} ${this.for}`.trim())}else console.warn("No content found in the post-tooltip-trigger slot. Please insert a focusable element or content that can receive focus.")}attachListeners(){c.forEach((t=>{this.host.addEventListener(t,this.boundTriggerHandler)}))}removeListeners(){c.forEach((t=>{this.host.removeEventListener(t,this.boundTriggerHandler)}))}attachTooltipListeners(){this.tooltip&&(this.tooltip.addEventListener("pointerenter",this.boundTooltipHandler),this.tooltip.addEventListener("pointerleave",this.boundTooltipHandler))}removeTooltipListeners(){this.tooltip&&(this.tooltip.removeEventListener("pointerenter",this.boundTooltipHandler),this.tooltip.removeEventListener("pointerleave",this.boundTooltipHandler))}handleTriggerEvent(t){switch(t.type){case"pointerenter":case"focusin":case"long-press":this.handleEnter();break;case"pointerleave":case"focusout":this.handleLeave(t)}}handleTooltipEvent(t){switch(t.type){case"pointerenter":this.handleEnter();break;case"pointerleave":this.handleLeave(t)}}handleEnter(){this.delayTimeout&&(clearTimeout(this.delayTimeout),this.delayTimeout=null),this.interestHandler()}handleLeave(t){const e=t.relatedTarget;this.tooltip&&e&&this.tooltip.contains(e)||e===this.trigger||this.interestLostHandler()}interestHandler(){this.trigger&&(this.delay>0?this.delayTimeout=globalThis.setTimeout((()=>{this.tooltip?.show(this.trigger),this.delayTimeout=null}),this.delay):this.tooltip?.show(this.trigger))}interestLostHandler(){this.delayTimeout&&(clearTimeout(this.delayTimeout),this.delayTimeout=null),this.tooltip?.hide()}render(){return s(o,{key:"37f835a46c96f1f97019b611da8b6be2d6e1a8d7","data-version":r},s("slot",{key:"c2fc3d9080948fdcfbd8b2866730e76b770b87ba",onSlotchange:()=>this.handleSlotChange()}))}get host(){return this}static get style(){return"post-tooltip-trigger{vertical-align:top}:host{cursor:pointer}"}},[257,"post-tooltip-trigger",{for:[513],delay:[2]}]);!function(t,e,i,s){var o,n=arguments.length,r=n<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var h=t.length-1;h>=0;h--)(o=t[h])&&(r=(n<3?o(r):n>3?o(e,i,r):o(e,i))||r);n>3&&r&&Object.defineProperty(e,i,r)}([h(),l("string")],p.prototype,"for",void 0);const u=p,d=function(){"undefined"!=typeof customElements&&["post-tooltip-trigger"].forEach((t=>{"post-tooltip-trigger"===t&&(customElements.get(n(t))||customElements.define(n(t),p))}))};export{u as PostTooltipTrigger,d as defineCustomElement}
@@ -1 +1 @@
1
- import{proxyCustomElement as e,HTMLElement as o,h as t,Host as s,transformTag as r}from"@stencil/core/internal/client";import{d as a,P as c}from"./post-popovercontainer2.js";import{v as i}from"./package.js";import{O as n}from"./one-of.js";const p=e(class extends o{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.placement="top",this.arrow=!1,this.open=!1}componentDidLoad(){this.host.id||console.error("No id set: <post-tooltip> must have an id, linking it to it's target element with a <post-tooltip-trigger> element.")}async show(e){this.open||await this.popoverRef.show(e)}async hide(){this.popoverRef.hide()}async toggle(e,o){this.popoverRef.toggle(e,o)}handleBeforeToggle(e){this.open=e.detail.willOpen}render(){return t(s,{key:"62d5983e0ef32f851166d0c1d2c457cac0809fdf","data-version":i},t("post-popovercontainer",{key:"10150540956510724ab4832ecceb421a7013d983",safeSpace:"trapezoid",class:this.arrow?"has-arrow":"",role:"tooltip",arrow:this.arrow,placement:this.placement,autoHide:!0,onPostBeforeToggle:e=>this.handleBeforeToggle(e),ref:e=>this.popoverRef=e},t("slot",{key:"cdfaf0e916afa55ec3f1a7f64003101985560e27"})))}get host(){return this}static get style(){return':host{display:none}:host([open]){display:contents}post-popovercontainer[arrow]::after{position:absolute;content:"";inset:-13px;z-index:-1}post-popovercontainer{--post-current-bg:var(--post-scheme-color-surface-accent-bg);--post-current-fg:var(--post-scheme-color-surface-accent-fg);--post-popovercontainer-arrow-border-width:var(--post-device-border-width-alternative1);--post-popovercontainer-arrow-border-color:var(--post-scheme-color-surface-accent-fg)}post-popovercontainer::part(post-popovercontainer-border-mask){display:block;-webkit-box-shadow:inset 0 0 0 var(--post-device-spacing-padding-14) var(--post-scheme-color-surface-accent-bg);box-shadow:inset 0 0 0 var(--post-device-spacing-padding-14) var(--post-scheme-color-surface-accent-bg)}post-popovercontainer::part(post-popovercontainer-content){border:var(--post-device-border-width-alternative1) solid var(--post-scheme-color-surface-accent-fg);border-radius:var(--post-device-border-radius-1);padding:var(--post-device-spacing-padding-14) var(--post-device-spacing-padding-15);font-size:var(--post-device-font-size-9);max-width:var(--post-tooltip-max-width, 280px);word-wrap:break-word;white-space:normal}'}},[257,"post-tooltip",{placement:[1],arrow:[4],open:[1540],show:[64],hide:[64],toggle:[64]}]);!function(e,o,t,s){var r,a=arguments.length,c=a<3?o:null===s?s=Object.getOwnPropertyDescriptor(o,t):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)c=Reflect.decorate(e,o,t,s);else for(var i=e.length-1;i>=0;i--)(r=e[i])&&(c=(a<3?r(c):a>3?r(o,t,c):r(o,t))||c);a>3&&c&&Object.defineProperty(o,t,c)}([n(c)],p.prototype,"placement",void 0);const d=p,l=function(){"undefined"!=typeof customElements&&["post-tooltip","post-popovercontainer"].forEach((e=>{switch(e){case"post-tooltip":customElements.get(r(e))||customElements.define(r(e),p);break;case"post-popovercontainer":customElements.get(r(e))||a()}}))};export{d as PostTooltip,l as defineCustomElement}
1
+ import{proxyCustomElement as o,HTMLElement as e,h as t,Host as s,transformTag as r}from"@stencil/core/internal/client";import{d as a,P as i}from"./post-popovercontainer2.js";import{v as c}from"./package.js";import{O as n}from"./one-of.js";const p=o(class extends e{constructor(o){super(),!1!==o&&this.__registerHost(),this.__attachShadow(),this.placement="top",this.arrow=!1,this.open=!1}componentDidLoad(){this.host.id||console.error("No id set: <post-tooltip> must have an id, linking it to it's target element with a <post-tooltip-trigger> element.")}async show(o){this.open||await this.popoverRef.show(o)}async hide(){this.popoverRef.hide()}async toggle(o,e){this.popoverRef.toggle(o,e)}handleBeforeToggle(o){this.host.toggleAttribute("open",o.detail.willOpen),this.open=o.detail.willOpen}render(){return t(s,{key:"c592afd24bbaf57999ca40b9558746a5a4490362","data-version":c},t("post-popovercontainer",{key:"c66e0c89228fed51a0affa4788a3e6c32f3196ae",safeSpace:!0,class:this.arrow?"has-arrow":"",role:"tooltip",arrow:this.arrow,placement:this.placement,autoHide:!0,onPostBeforeToggle:o=>this.handleBeforeToggle(o),ref:o=>this.popoverRef=o},t("div",{key:"fc57d4457c4910aab1bfae2558cf78ae9a253552",class:"tooltip-content"},t("slot",{key:"316a52bf1a1763b2510270e9ab5bc26ca8e5e53f"}))))}get host(){return this}static get style(){return":host{display:none}:host([open]){display:contents}post-popovercontainer{--post-current-bg:var(--post-scheme-color-surface-accent-bg);--post-current-fg:var(--post-scheme-color-surface-accent-fg);--post-popovercontainer-arrow-border-width:var(--post-device-border-width-alternative1);--post-popovercontainer-arrow-border-color:var(--post-scheme-color-surface-accent-fg)}post-popovercontainer::part(post-popovercontainer-border-mask){display:block;-webkit-box-shadow:inset 0 0 0 var(--post-device-spacing-padding-14) var(--post-scheme-color-surface-accent-bg);box-shadow:inset 0 0 0 var(--post-device-spacing-padding-14) var(--post-scheme-color-surface-accent-bg)}post-popovercontainer::part(post-popovercontainer-content){border:var(--post-device-border-width-alternative1) solid var(--post-scheme-color-surface-accent-fg);border-radius:var(--post-device-border-radius-1)}.tooltip-content{-webkit-box-sizing:border-box;box-sizing:border-box;padding:var(--post-device-spacing-padding-14) var(--post-device-spacing-padding-15);font-size:var(--post-device-font-size-9);max-width:var(--post-tooltip-max-width, 280px);word-wrap:break-word;white-space:normal;overflow:hidden}"}},[257,"post-tooltip",{placement:[1],arrow:[4],open:[1540],show:[64],hide:[64],toggle:[64]}]);!function(o,e,t,s){var r,a=arguments.length,i=a<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,t):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(o,e,t,s);else for(var c=o.length-1;c>=0;c--)(r=o[c])&&(i=(a<3?r(i):a>3?r(e,t,i):r(e,t))||i);a>3&&i&&Object.defineProperty(e,t,i)}([n(i)],p.prototype,"placement",void 0);const d=p,l=function(){"undefined"!=typeof customElements&&["post-tooltip","post-popovercontainer"].forEach((o=>{switch(o){case"post-tooltip":customElements.get(r(o))||customElements.define(r(o),p);break;case"post-popovercontainer":customElements.get(r(o))||a()}}))};export{d as PostTooltip,l as defineCustomElement}