@solid-design-system/components 4.3.0 → 4.3.1

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 (235) hide show
  1. package/cdn/chunks/{chunk.NER6LFUE.js → chunk.5YWPH3S7.js} +2 -2
  2. package/cdn/components/carousel/carousel.js +1 -1
  3. package/cdn/custom-elements.json +1 -1
  4. package/cdn/solid-components.bundle.js +1 -1
  5. package/cdn/solid-components.iife.js +1 -1
  6. package/cdn/solid-components.js +1 -1
  7. package/cdn/web-types.json +1 -1
  8. package/cdn-versioned/_components/menu/menu.js +1 -1
  9. package/cdn-versioned/_components/menu/menu.styles.js +1 -1
  10. package/cdn-versioned/_components/menu-item/menu-item.js +2 -2
  11. package/cdn-versioned/chunks/chunk.247MZWMU.js +1 -1
  12. package/cdn-versioned/chunks/chunk.2BLQ3VDT.js +4 -4
  13. package/cdn-versioned/chunks/chunk.2HJF2D4H.js +2 -2
  14. package/cdn-versioned/chunks/chunk.43NFQGWL.js +1 -1
  15. package/cdn-versioned/chunks/chunk.4QAJB6AU.js +1 -1
  16. package/cdn-versioned/chunks/chunk.5AILWWY2.js +1 -1
  17. package/cdn-versioned/chunks/chunk.5TTHL3M2.js +3 -3
  18. package/cdn-versioned/chunks/{chunk.NER6LFUE.js → chunk.5YWPH3S7.js} +2 -2
  19. package/cdn-versioned/chunks/chunk.65NSSTJE.js +1 -1
  20. package/cdn-versioned/chunks/chunk.777DWZOA.js +1 -1
  21. package/cdn-versioned/chunks/chunk.7TRFUW6U.js +1 -1
  22. package/cdn-versioned/chunks/chunk.BHWV44KN.js +1 -1
  23. package/cdn-versioned/chunks/chunk.BWMHPT4Y.js +1 -1
  24. package/cdn-versioned/chunks/chunk.CEVVDV52.js +1 -1
  25. package/cdn-versioned/chunks/chunk.CNGIUOE5.js +1 -1
  26. package/cdn-versioned/chunks/chunk.DDLTKNEO.js +1 -1
  27. package/cdn-versioned/chunks/chunk.DLY5AX2P.js +1 -1
  28. package/cdn-versioned/chunks/chunk.E5FCRWHS.js +1 -1
  29. package/cdn-versioned/chunks/chunk.F45IDVYA.js +1 -1
  30. package/cdn-versioned/chunks/chunk.FHU3KJ7Y.js +1 -1
  31. package/cdn-versioned/chunks/chunk.FVXID42E.js +1 -1
  32. package/cdn-versioned/chunks/chunk.HKGBSLKX.js +1 -1
  33. package/cdn-versioned/chunks/chunk.I2WEQVU3.js +1 -1
  34. package/cdn-versioned/chunks/chunk.IUC5UQ2V.js +1 -1
  35. package/cdn-versioned/chunks/chunk.JCNKLGIS.js +1 -1
  36. package/cdn-versioned/chunks/chunk.JDSUZDP4.js +1 -1
  37. package/cdn-versioned/chunks/chunk.KLNBBP4R.js +4 -4
  38. package/cdn-versioned/chunks/chunk.KV424MMD.js +1 -1
  39. package/cdn-versioned/chunks/chunk.KWNRVZ54.js +1 -1
  40. package/cdn-versioned/chunks/chunk.LET4FMBB.js +1 -1
  41. package/cdn-versioned/chunks/chunk.LKO4ZRE7.js +1 -1
  42. package/cdn-versioned/chunks/chunk.NFQN6UG4.js +1 -1
  43. package/cdn-versioned/chunks/chunk.NLOKZURD.js +1 -1
  44. package/cdn-versioned/chunks/chunk.NOJV6ZZF.js +1 -1
  45. package/cdn-versioned/chunks/chunk.NZT4ORYP.js +1 -1
  46. package/cdn-versioned/chunks/chunk.O3IRROA2.js +1 -1
  47. package/cdn-versioned/chunks/chunk.ONLECFTO.js +1 -1
  48. package/cdn-versioned/chunks/chunk.PDIUABFP.js +1 -1
  49. package/cdn-versioned/chunks/chunk.PGBIGG5I.js +1 -1
  50. package/cdn-versioned/chunks/chunk.QWMQJ6TF.js +1 -1
  51. package/cdn-versioned/chunks/chunk.RCLIOOS5.js +1 -1
  52. package/cdn-versioned/chunks/chunk.RGJXEMYT.js +1 -1
  53. package/cdn-versioned/chunks/chunk.SDZ6E4CH.js +1 -1
  54. package/cdn-versioned/chunks/chunk.V3YHI2G2.js +1 -1
  55. package/cdn-versioned/chunks/chunk.VZSFEHBE.js +1 -1
  56. package/cdn-versioned/chunks/chunk.W7A3TU2Z.js +1 -1
  57. package/cdn-versioned/chunks/chunk.WJ55QSS3.js +1 -1
  58. package/cdn-versioned/chunks/chunk.WMV7GLXF.js +1 -1
  59. package/cdn-versioned/chunks/chunk.WUTY672B.js +1 -1
  60. package/cdn-versioned/chunks/chunk.XYZ5DKTA.js +1 -1
  61. package/cdn-versioned/chunks/chunk.Y4PTSCEB.js +1 -1
  62. package/cdn-versioned/chunks/chunk.ZN24IDXT.js +1 -1
  63. package/cdn-versioned/chunks/chunk.ZVVSLR3B.js +1 -1
  64. package/cdn-versioned/components/accordion/accordion.d.ts +1 -1
  65. package/cdn-versioned/components/accordion-group/accordion-group.d.ts +1 -1
  66. package/cdn-versioned/components/animation/animation.d.ts +1 -1
  67. package/cdn-versioned/components/audio/audio.d.ts +1 -1
  68. package/cdn-versioned/components/badge/badge.d.ts +1 -1
  69. package/cdn-versioned/components/brandshape/brandshape.d.ts +1 -1
  70. package/cdn-versioned/components/button/button.d.ts +1 -1
  71. package/cdn-versioned/components/button-group/button-group.d.ts +1 -1
  72. package/cdn-versioned/components/carousel/carousel.d.ts +1 -1
  73. package/cdn-versioned/components/carousel/carousel.js +1 -1
  74. package/cdn-versioned/components/carousel-item/carousel-item.d.ts +1 -1
  75. package/cdn-versioned/components/checkbox/checkbox.d.ts +1 -1
  76. package/cdn-versioned/components/checkbox-group/checkbox-group.d.ts +1 -1
  77. package/cdn-versioned/components/combobox/combobox.d.ts +4 -4
  78. package/cdn-versioned/components/dialog/dialog.d.ts +1 -1
  79. package/cdn-versioned/components/divider/divider.d.ts +1 -1
  80. package/cdn-versioned/components/drawer/drawer.d.ts +1 -1
  81. package/cdn-versioned/components/dropdown/dropdown.d.ts +1 -1
  82. package/cdn-versioned/components/expandable/expandable.d.ts +1 -1
  83. package/cdn-versioned/components/flipcard/flipcard.d.ts +1 -1
  84. package/cdn-versioned/components/header/header.d.ts +1 -1
  85. package/cdn-versioned/components/icon/icon.d.ts +1 -1
  86. package/cdn-versioned/components/include/include.d.ts +1 -1
  87. package/cdn-versioned/components/input/input.d.ts +1 -1
  88. package/cdn-versioned/components/link/link.d.ts +1 -1
  89. package/cdn-versioned/components/map-marker/map-marker.d.ts +1 -1
  90. package/cdn-versioned/components/navigation-item/navigation-item.d.ts +1 -1
  91. package/cdn-versioned/components/notification/notification.d.ts +1 -1
  92. package/cdn-versioned/components/optgroup/optgroup.d.ts +2 -2
  93. package/cdn-versioned/components/option/option.d.ts +1 -1
  94. package/cdn-versioned/components/popup/popup.d.ts +1 -1
  95. package/cdn-versioned/components/quickfact/quickfact.d.ts +1 -1
  96. package/cdn-versioned/components/radio/radio.d.ts +1 -1
  97. package/cdn-versioned/components/radio-button/radio-button.d.ts +1 -1
  98. package/cdn-versioned/components/radio-group/radio-group.d.ts +2 -2
  99. package/cdn-versioned/components/scrollable/scrollable.d.ts +1 -1
  100. package/cdn-versioned/components/select/select.d.ts +4 -4
  101. package/cdn-versioned/components/spinner/spinner.d.ts +1 -1
  102. package/cdn-versioned/components/step/step.d.ts +1 -1
  103. package/cdn-versioned/components/step-group/step-group.d.ts +1 -1
  104. package/cdn-versioned/components/switch/switch.d.ts +1 -1
  105. package/cdn-versioned/components/tab/tab.d.ts +1 -1
  106. package/cdn-versioned/components/tab-group/tab-group.d.ts +1 -1
  107. package/cdn-versioned/components/tab-panel/tab-panel.d.ts +1 -1
  108. package/cdn-versioned/components/tag/tag.d.ts +1 -1
  109. package/cdn-versioned/components/textarea/textarea.d.ts +1 -1
  110. package/cdn-versioned/components/tooltip/tooltip.d.ts +1 -1
  111. package/cdn-versioned/components/video/video.d.ts +1 -1
  112. package/cdn-versioned/custom-elements.json +202 -202
  113. package/cdn-versioned/internal/form.js +3 -3
  114. package/cdn-versioned/solid-components.bundle.js +16 -16
  115. package/cdn-versioned/solid-components.css +2 -2
  116. package/cdn-versioned/solid-components.iife.js +16 -16
  117. package/cdn-versioned/solid-components.js +1 -1
  118. package/cdn-versioned/vscode.html-custom-data.json +80 -80
  119. package/cdn-versioned/web-types.json +137 -137
  120. package/dist/chunks/{chunk.5R6D4NTV.js → chunk.L5QYLWGO.js} +0 -2
  121. package/dist/components/carousel/carousel.js +1 -1
  122. package/dist/custom-elements.json +1 -1
  123. package/dist/solid-components.js +1 -1
  124. package/dist/web-types.json +1 -1
  125. package/dist-versioned/_components/menu/menu.js +1 -1
  126. package/dist-versioned/_components/menu/menu.styles.js +1 -1
  127. package/dist-versioned/_components/menu-item/menu-item.js +2 -2
  128. package/dist-versioned/chunks/chunk.2LL4ZNH4.js +2 -2
  129. package/dist-versioned/chunks/chunk.35GLHXMN.js +2 -2
  130. package/dist-versioned/chunks/chunk.3UO2LKG5.js +13 -13
  131. package/dist-versioned/chunks/chunk.3YTMF6YZ.js +2 -2
  132. package/dist-versioned/chunks/chunk.5V7TZU4Q.js +5 -5
  133. package/dist-versioned/chunks/chunk.6DKXZWRN.js +4 -4
  134. package/dist-versioned/chunks/chunk.6MMBMCHF.js +9 -9
  135. package/dist-versioned/chunks/chunk.6S3CCHLZ.js +1 -1
  136. package/dist-versioned/chunks/chunk.73HAOWEX.js +2 -2
  137. package/dist-versioned/chunks/chunk.7SZFMAVT.js +1 -1
  138. package/dist-versioned/chunks/chunk.AWASHA2T.js +1 -1
  139. package/dist-versioned/chunks/chunk.BFHRLREK.js +1 -1
  140. package/dist-versioned/chunks/chunk.CVHGDRIM.js +2 -2
  141. package/dist-versioned/chunks/chunk.DI4CIT2A.js +1 -1
  142. package/dist-versioned/chunks/chunk.DNHLNGIL.js +13 -13
  143. package/dist-versioned/chunks/chunk.F4BRIYYD.js +1 -1
  144. package/dist-versioned/chunks/chunk.G6KPFA3G.js +4 -4
  145. package/dist-versioned/chunks/chunk.GQXJC6ZE.js +2 -2
  146. package/dist-versioned/chunks/chunk.GWCHNKGW.js +1 -1
  147. package/dist-versioned/chunks/chunk.H54CZFCF.js +5 -5
  148. package/dist-versioned/chunks/chunk.HJ3ZUH4A.js +1 -1
  149. package/dist-versioned/chunks/chunk.I2JBWY5C.js +2 -2
  150. package/dist-versioned/chunks/chunk.IKWY7WM6.js +3 -3
  151. package/dist-versioned/chunks/chunk.JD5XFZKL.js +2 -2
  152. package/dist-versioned/chunks/chunk.JPGDK3CW.js +2 -2
  153. package/dist-versioned/chunks/chunk.K5MKZJEB.js +5 -5
  154. package/dist-versioned/chunks/chunk.KVKRZJS7.js +3 -3
  155. package/dist-versioned/chunks/{chunk.5R6D4NTV.js → chunk.L5QYLWGO.js} +6 -8
  156. package/dist-versioned/chunks/chunk.LRQ55FZL.js +1 -1
  157. package/dist-versioned/chunks/chunk.LUV3NLSJ.js +3 -3
  158. package/dist-versioned/chunks/chunk.MCUC6LS6.js +2 -2
  159. package/dist-versioned/chunks/chunk.MKZ5TRQH.js +1 -1
  160. package/dist-versioned/chunks/chunk.OENW3EQT.js +5 -5
  161. package/dist-versioned/chunks/chunk.ONBGPY5D.js +5 -5
  162. package/dist-versioned/chunks/chunk.QN2ROZHZ.js +3 -3
  163. package/dist-versioned/chunks/chunk.RFVRT5UG.js +2 -2
  164. package/dist-versioned/chunks/chunk.RI66LCUS.js +2 -2
  165. package/dist-versioned/chunks/chunk.SH45GYZL.js +1 -1
  166. package/dist-versioned/chunks/chunk.T5VRGBLR.js +1 -1
  167. package/dist-versioned/chunks/chunk.UIQBHPD3.js +2 -2
  168. package/dist-versioned/chunks/chunk.UXEDWUMA.js +26 -26
  169. package/dist-versioned/chunks/chunk.WHFYHMF4.js +2 -2
  170. package/dist-versioned/chunks/chunk.WJHCLJNK.js +1 -1
  171. package/dist-versioned/chunks/chunk.WPHOQL7V.js +2 -2
  172. package/dist-versioned/chunks/chunk.WZGJQPPD.js +2 -2
  173. package/dist-versioned/chunks/chunk.X7HEAUGJ.js +2 -2
  174. package/dist-versioned/chunks/chunk.XCNH2K2U.js +5 -5
  175. package/dist-versioned/chunks/chunk.XNH47HGG.js +29 -29
  176. package/dist-versioned/chunks/chunk.Y6WJUTMM.js +6 -6
  177. package/dist-versioned/chunks/chunk.Z3T4BG2M.js +1 -1
  178. package/dist-versioned/chunks/chunk.ZH6BP5XL.js +3 -3
  179. package/dist-versioned/chunks/chunk.ZJGD23K6.js +3 -3
  180. package/dist-versioned/chunks/chunk.ZWJNBDIV.js +11 -11
  181. package/dist-versioned/components/accordion/accordion.d.ts +1 -1
  182. package/dist-versioned/components/accordion-group/accordion-group.d.ts +1 -1
  183. package/dist-versioned/components/animation/animation.d.ts +1 -1
  184. package/dist-versioned/components/audio/audio.d.ts +1 -1
  185. package/dist-versioned/components/badge/badge.d.ts +1 -1
  186. package/dist-versioned/components/brandshape/brandshape.d.ts +1 -1
  187. package/dist-versioned/components/button/button.d.ts +1 -1
  188. package/dist-versioned/components/button-group/button-group.d.ts +1 -1
  189. package/dist-versioned/components/carousel/carousel.d.ts +1 -1
  190. package/dist-versioned/components/carousel/carousel.js +1 -1
  191. package/dist-versioned/components/carousel-item/carousel-item.d.ts +1 -1
  192. package/dist-versioned/components/checkbox/checkbox.d.ts +1 -1
  193. package/dist-versioned/components/checkbox-group/checkbox-group.d.ts +1 -1
  194. package/dist-versioned/components/combobox/combobox.d.ts +4 -4
  195. package/dist-versioned/components/dialog/dialog.d.ts +1 -1
  196. package/dist-versioned/components/divider/divider.d.ts +1 -1
  197. package/dist-versioned/components/drawer/drawer.d.ts +1 -1
  198. package/dist-versioned/components/dropdown/dropdown.d.ts +1 -1
  199. package/dist-versioned/components/expandable/expandable.d.ts +1 -1
  200. package/dist-versioned/components/flipcard/flipcard.d.ts +1 -1
  201. package/dist-versioned/components/header/header.d.ts +1 -1
  202. package/dist-versioned/components/icon/icon.d.ts +1 -1
  203. package/dist-versioned/components/include/include.d.ts +1 -1
  204. package/dist-versioned/components/input/input.d.ts +1 -1
  205. package/dist-versioned/components/link/link.d.ts +1 -1
  206. package/dist-versioned/components/map-marker/map-marker.d.ts +1 -1
  207. package/dist-versioned/components/navigation-item/navigation-item.d.ts +1 -1
  208. package/dist-versioned/components/notification/notification.d.ts +1 -1
  209. package/dist-versioned/components/optgroup/optgroup.d.ts +2 -2
  210. package/dist-versioned/components/option/option.d.ts +1 -1
  211. package/dist-versioned/components/popup/popup.d.ts +1 -1
  212. package/dist-versioned/components/quickfact/quickfact.d.ts +1 -1
  213. package/dist-versioned/components/radio/radio.d.ts +1 -1
  214. package/dist-versioned/components/radio-button/radio-button.d.ts +1 -1
  215. package/dist-versioned/components/radio-group/radio-group.d.ts +2 -2
  216. package/dist-versioned/components/scrollable/scrollable.d.ts +1 -1
  217. package/dist-versioned/components/select/select.d.ts +4 -4
  218. package/dist-versioned/components/spinner/spinner.d.ts +1 -1
  219. package/dist-versioned/components/step/step.d.ts +1 -1
  220. package/dist-versioned/components/step-group/step-group.d.ts +1 -1
  221. package/dist-versioned/components/switch/switch.d.ts +1 -1
  222. package/dist-versioned/components/tab/tab.d.ts +1 -1
  223. package/dist-versioned/components/tab-group/tab-group.d.ts +1 -1
  224. package/dist-versioned/components/tab-panel/tab-panel.d.ts +1 -1
  225. package/dist-versioned/components/tag/tag.d.ts +1 -1
  226. package/dist-versioned/components/textarea/textarea.d.ts +1 -1
  227. package/dist-versioned/components/tooltip/tooltip.d.ts +1 -1
  228. package/dist-versioned/components/video/video.d.ts +1 -1
  229. package/dist-versioned/custom-elements.json +202 -202
  230. package/dist-versioned/internal/form.js +3 -3
  231. package/dist-versioned/solid-components.css +2 -2
  232. package/dist-versioned/solid-components.js +1 -1
  233. package/dist-versioned/vscode.html-custom-data.json +80 -80
  234. package/dist-versioned/web-types.json +137 -137
  235. package/package.json +1 -1
@@ -1,6 +1,6 @@
1
- import{a as k}from"./chunk.CBQWVOOS.js";import{a as T}from"./chunk.EUGX6XW6.js";import{a as L}from"./chunk.NFQN6UG4.js";import{c as M}from"./chunk.RQYP7MH5.js";import{a as m}from"./chunk.E2DRD2OX.js";import{a as $}from"./chunk.TNPIUMKG.js";import{a as n}from"./chunk.26V4EXHB.js";import{a as E,b as g,c as f,d as v,e as A,h as P}from"./chunk.5AILWWY2.js";import{b as x,e as b}from"./chunk.IRWHG2Q4.js";import{e as o}from"./chunk.TJOCV4DC.js";function _(h,d,e){let i=t=>Object.is(t,-0)?0:t;return h<d?i(d):h>e?i(e):i(h)}function*C(h,d){if(h!==void 0){let e=0;for(let i of h)yield d(i,e++)}}function*I(h,d,e=1){let i=d===void 0?0:h;d!=null||(d=h);for(let t=i;e>0?t<d:d<t;t+=e)yield t}var r=class extends P{constructor(){super(...arguments);this.variant="number";this.inverted=!1;this.loop=!1;this.autoplay=!1;this.slidesPerPage=1;this.slidesPerMove=1;this.activeSlide=0;this.currentPage=1;this.pausedAutoplay=!1;this.autoplayController=new k(this,()=>this.next());this.scrollController=new T(this);this.slides=this.getElementsByTagName("sd-carousel-item");this.intersectionObserverEntries=new Map;this.localize=new $(this);this.userInteracted=!1;this.handleUserInteraction=()=>{this.userInteracted=!0};this.handleSlotChange=e=>{e.some(t=>[...t.addedNodes,...t.removedNodes].some(s=>L.isCarouselItem(s)&&!s.hasAttribute("data-clone")))&&this.initializeSlides(),this.requestUpdate()};this.unblockAutoplay=(e,i)=>{e.detail&&i.blur()}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","region"),this.setAttribute("aria-label",this.localize.term("carousel")),["click","keydown"].forEach(i=>this.addEventListener(i,this.handleUserInteraction));let e=new IntersectionObserver(i=>{i.forEach(t=>{this.intersectionObserverEntries.set(t.target,t);let s=t.target;s.toggleAttribute("inert",!t.isIntersecting),s.classList.toggle("--in-view",t.isIntersecting),s.setAttribute("aria-hidden",t.isIntersecting?"false":"true")})},{root:this,threshold:.6});this.intersectionObserver=e,e.takeRecords().forEach(i=>{this.intersectionObserverEntries.set(i.target,i)})}disconnectedCallback(){super.disconnectedCallback(),this.intersectionObserver.disconnect(),this.mutationObserver.disconnect(),["click","keydown"].forEach(e=>this.removeEventListener(e,this.handleUserInteraction))}firstUpdated(){this.initializeSlides(),this.mutationObserver=new MutationObserver(this.handleSlotChange),this.mutationObserver.observe(this,{childList:!0,subtree:!1})}getPageCount(e,i,t){return Math.ceil((e-i)/t)+1>0?Math.ceil((e-i)/t)+1:1}getCurrentPage(e,i,t,s){return Math.ceil((e-t)/s)-Math.ceil((e-t-i)/s)+1}getSlides({excludeClones:e=!0}={}){return[...this.slides].filter(i=>!e||!i.hasAttribute("data-clone"))}handleKeyDown(e){if(["ArrowLeft","ArrowRight","ArrowUp","ArrowDown","Home","End"].includes(e.key)){let i=e.target,t=this.localize.dir()==="rtl",s=i.closest('[part~="pagination-item"]')!==null,l=e.key==="ArrowDown"||!t&&e.key==="ArrowRight"||t&&e.key==="ArrowLeft",c=e.key==="ArrowUp"||!t&&e.key==="ArrowLeft"||t&&e.key==="ArrowRight";e.preventDefault(),c&&this.previous(),l&&this.next(),e.key==="Home"&&this.goToSlide(0),e.key==="End"&&this.goToSlide(this.getSlides().length-1),s&&this.updateComplete.then(()=>{var a;let u=(a=this.shadowRoot)==null?void 0:a.querySelector('[part~="pagination-item--active"]');u&&u.focus()})}}handleScrollEnd(){let e=this.getSlides(),t=[...this.intersectionObserverEntries.values()].find(s=>s.isIntersecting);if(this.loop&&(t!=null&&t.target.hasAttribute("data-clone"))){let s=Number(t.target.getAttribute("data-clone"));this.goToSlide(s,"auto");return}t&&(this.activeSlide=e.indexOf(t.target))}pause(){this.pausedAutoplay=!0}resume(){this.pausedAutoplay=!1}handlePausedAutoplay(){var e,i;this.pausedAutoplay?(this.autoplayController.stop(),(e=this.autoplayControls)==null||e.setAttribute("aria-pressed","false")):this.autoplay&&(this.autoplayController.start(3e3),(i=this.autoplayControls)==null||i.setAttribute("aria-pressed","true"))}initializeSlides(){let e=this.getSlides(),i=this.intersectionObserver;if(this.intersectionObserverEntries.clear(),this.getSlides({excludeClones:!1}).forEach((t,s)=>{i.unobserve(t),t.classList.remove("--in-view"),t.classList.remove("--is-active"),t.setAttribute("aria-label",this.localize.term("slideNum",s+1,e.length)),t.hasAttribute("data-clone")&&t.remove()}),this.loop){let t=this.slidesPerPage,s=e.slice(-t),l=e.slice(0,t);s.reverse().forEach((c,u)=>{let a=c.cloneNode(!0);a.setAttribute("data-clone",String(e.length-u-1)),this.prepend(a)}),l.forEach((c,u)=>{let a=c.cloneNode(!0);a.setAttribute("data-clone",String(u)),this.append(a)})}this.getSlides({excludeClones:!1}).forEach(t=>{i.observe(t)}),this.goToSlide(this.activeSlide,"auto")}handleSlideChange(){let e=this.getSlides();e.forEach((s,l)=>{s.classList.toggle("--is-active",l===this.activeSlide)});let i=this.getCurrentPage(e.length,this.activeSlide,this.slidesPerPage,this.slidesPerMove);this.currentPage!==i&&(this.currentPage=i),this.hasUpdated&&this.emit("sd-slide-change",{detail:{index:this.activeSlide,slide:e[this.activeSlide]}});let t=this.getPageCount(e.length,this.slidesPerPage,this.slidesPerMove);this.currentPage>t&&requestAnimationFrame(()=>{this.nextTillFirst()})}handleSlidesPerMoveChange(){let e=this.getSlides({excludeClones:!1}),i=this.slidesPerMove;e.forEach((t,s)=>{Math.abs(s-i)%i===0?t.style.removeProperty("scroll-snap-align"):t.style.setProperty("scroll-snap-align","none")})}handleAutoplayChange(){this.autoplayController.stop(),this.autoplay&&!this.pausedAutoplay&&this.autoplayController.start(3e3)}previous(e="smooth"){let i=this.activeSlide||this.activeSlide-this.slidesPerMove,t=!1;for(;!t&&i>0;)i-=1,t=Math.abs(i-this.slidesPerMove)%this.slidesPerMove===0;this.currentPage-1===0&&this.loop?this.goToSlide(this.activeSlide-this.slidesPerPage,e):this.goToSlide(i,e)}next(e="smooth"){this.currentPage+1<=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove)?this.goToSlide(this.activeSlide+this.slidesPerMove,e):this.loop&&this.nextTillFirst(e)}nextTillFirst(e="smooth"){for(;this.activeSlide!==0;)this.goToSlide(this.activeSlide+1,e);this.currentPage=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove)}goToSlide(e,i="smooth"){let{slidesPerPage:t,loop:s,scrollContainer:l}=this,c=this.getSlides(),u=this.getSlides({excludeClones:!1}),a=(e+c.length)%c.length;this.activeSlide=a;let p=_(e+(s?t:0),0,u.length+1),y=u[p],w=l.getBoundingClientRect(),S=y.getBoundingClientRect();if(l.scrollTo({left:S.left-w.left+l.scrollLeft,top:S.top-w.top+l.scrollTop,behavior:M()?"auto":i}),this.userInteracted&&!this.loop){let O=this.activeSlide===c.length-1||this.activeSlide===this.slides.length-this.slidesPerPage,B=this.activeSlide===0;O?this.previousButton.focus({preventScroll:!0}):B&&this.nextButton.focus({preventScroll:!0})}}render(){let{scrollController:e,slidesPerMove:i}=this,t=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove),s=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove),l=this.loop||s>1,c=this.loop||s<t,u=this.localize.dir()==="ltr";return b`<div part="base" class="${n("carousel h-full w-full")}"><div id="scroll-container" part="scroll-container" class="${n(`carousel__slides mb-6
1
+ import{a as k}from"./chunk.CBQWVOOS.js";import{a as T}from"./chunk.EUGX6XW6.js";import{a as L}from"./chunk.NFQN6UG4.js";import{c as A}from"./chunk.RQYP7MH5.js";import{a as m}from"./chunk.E2DRD2OX.js";import{a as $}from"./chunk.TNPIUMKG.js";import{a as n}from"./chunk.26V4EXHB.js";import{a as E,b as g,c as f,d as v,e as M,h as P}from"./chunk.5AILWWY2.js";import{b as x,e as b}from"./chunk.IRWHG2Q4.js";import{e as o}from"./chunk.TJOCV4DC.js";function _(h,d,e){let i=t=>Object.is(t,-0)?0:t;return h<d?i(d):h>e?i(e):i(h)}function*C(h,d){if(h!==void 0){let e=0;for(let i of h)yield d(i,e++)}}function*I(h,d,e=1){let i=d===void 0?0:h;d!=null||(d=h);for(let t=i;e>0?t<d:d<t;t+=e)yield t}var r=class extends P{constructor(){super(...arguments);this.variant="number";this.inverted=!1;this.loop=!1;this.autoplay=!1;this.slidesPerPage=1;this.slidesPerMove=1;this.activeSlide=0;this.currentPage=1;this.pausedAutoplay=!1;this.autoplayController=new k(this,()=>this.next());this.scrollController=new T(this);this.slides=this.getElementsByTagName("sd-carousel-item");this.intersectionObserverEntries=new Map;this.localize=new $(this);this.userInteracted=!1;this.handleUserInteraction=()=>{this.userInteracted=!0};this.handleSlotChange=e=>{e.some(t=>[...t.addedNodes,...t.removedNodes].some(s=>L.isCarouselItem(s)&&!s.hasAttribute("data-clone")))&&this.initializeSlides(),this.requestUpdate()};this.unblockAutoplay=(e,i)=>{e.detail&&i.blur()}}connectedCallback(){super.connectedCallback(),["click","keydown"].forEach(i=>this.addEventListener(i,this.handleUserInteraction));let e=new IntersectionObserver(i=>{i.forEach(t=>{this.intersectionObserverEntries.set(t.target,t);let s=t.target;s.toggleAttribute("inert",!t.isIntersecting),s.classList.toggle("--in-view",t.isIntersecting),s.setAttribute("aria-hidden",t.isIntersecting?"false":"true")})},{root:this,threshold:.6});this.intersectionObserver=e,e.takeRecords().forEach(i=>{this.intersectionObserverEntries.set(i.target,i)})}disconnectedCallback(){super.disconnectedCallback(),this.intersectionObserver.disconnect(),this.mutationObserver.disconnect(),["click","keydown"].forEach(e=>this.removeEventListener(e,this.handleUserInteraction))}firstUpdated(){this.initializeSlides(),this.mutationObserver=new MutationObserver(this.handleSlotChange),this.mutationObserver.observe(this,{childList:!0,subtree:!1})}getPageCount(e,i,t){return Math.ceil((e-i)/t)+1>0?Math.ceil((e-i)/t)+1:1}getCurrentPage(e,i,t,s){return Math.ceil((e-t)/s)-Math.ceil((e-t-i)/s)+1}getSlides({excludeClones:e=!0}={}){return[...this.slides].filter(i=>!e||!i.hasAttribute("data-clone"))}handleKeyDown(e){if(["ArrowLeft","ArrowRight","ArrowUp","ArrowDown","Home","End"].includes(e.key)){let i=e.target,t=this.localize.dir()==="rtl",s=i.closest('[part~="pagination-item"]')!==null,l=e.key==="ArrowDown"||!t&&e.key==="ArrowRight"||t&&e.key==="ArrowLeft",c=e.key==="ArrowUp"||!t&&e.key==="ArrowLeft"||t&&e.key==="ArrowRight";e.preventDefault(),c&&this.previous(),l&&this.next(),e.key==="Home"&&this.goToSlide(0),e.key==="End"&&this.goToSlide(this.getSlides().length-1),s&&this.updateComplete.then(()=>{var a;let u=(a=this.shadowRoot)==null?void 0:a.querySelector('[part~="pagination-item--active"]');u&&u.focus()})}}handleScrollEnd(){let e=this.getSlides(),t=[...this.intersectionObserverEntries.values()].find(s=>s.isIntersecting);if(this.loop&&(t!=null&&t.target.hasAttribute("data-clone"))){let s=Number(t.target.getAttribute("data-clone"));this.goToSlide(s,"auto");return}t&&(this.activeSlide=e.indexOf(t.target))}pause(){this.pausedAutoplay=!0}resume(){this.pausedAutoplay=!1}handlePausedAutoplay(){var e,i;this.pausedAutoplay?(this.autoplayController.stop(),(e=this.autoplayControls)==null||e.setAttribute("aria-pressed","false")):this.autoplay&&(this.autoplayController.start(3e3),(i=this.autoplayControls)==null||i.setAttribute("aria-pressed","true"))}initializeSlides(){let e=this.getSlides(),i=this.intersectionObserver;if(this.intersectionObserverEntries.clear(),this.getSlides({excludeClones:!1}).forEach((t,s)=>{i.unobserve(t),t.classList.remove("--in-view"),t.classList.remove("--is-active"),t.setAttribute("aria-label",this.localize.term("slideNum",s+1,e.length)),t.hasAttribute("data-clone")&&t.remove()}),this.loop){let t=this.slidesPerPage,s=e.slice(-t),l=e.slice(0,t);s.reverse().forEach((c,u)=>{let a=c.cloneNode(!0);a.setAttribute("data-clone",String(e.length-u-1)),this.prepend(a)}),l.forEach((c,u)=>{let a=c.cloneNode(!0);a.setAttribute("data-clone",String(u)),this.append(a)})}this.getSlides({excludeClones:!1}).forEach(t=>{i.observe(t)}),this.goToSlide(this.activeSlide,"auto")}handleSlideChange(){let e=this.getSlides();e.forEach((s,l)=>{s.classList.toggle("--is-active",l===this.activeSlide)});let i=this.getCurrentPage(e.length,this.activeSlide,this.slidesPerPage,this.slidesPerMove);this.currentPage!==i&&(this.currentPage=i),this.hasUpdated&&this.emit("sd-slide-change",{detail:{index:this.activeSlide,slide:e[this.activeSlide]}});let t=this.getPageCount(e.length,this.slidesPerPage,this.slidesPerMove);this.currentPage>t&&requestAnimationFrame(()=>{this.nextTillFirst()})}handleSlidesPerMoveChange(){let e=this.getSlides({excludeClones:!1}),i=this.slidesPerMove;e.forEach((t,s)=>{Math.abs(s-i)%i===0?t.style.removeProperty("scroll-snap-align"):t.style.setProperty("scroll-snap-align","none")})}handleAutoplayChange(){this.autoplayController.stop(),this.autoplay&&!this.pausedAutoplay&&this.autoplayController.start(3e3)}previous(e="smooth"){let i=this.activeSlide||this.activeSlide-this.slidesPerMove,t=!1;for(;!t&&i>0;)i-=1,t=Math.abs(i-this.slidesPerMove)%this.slidesPerMove===0;this.currentPage-1===0&&this.loop?this.goToSlide(this.activeSlide-this.slidesPerPage,e):this.goToSlide(i,e)}next(e="smooth"){this.currentPage+1<=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove)?this.goToSlide(this.activeSlide+this.slidesPerMove,e):this.loop&&this.nextTillFirst(e)}nextTillFirst(e="smooth"){for(;this.activeSlide!==0;)this.goToSlide(this.activeSlide+1,e);this.currentPage=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove)}goToSlide(e,i="smooth"){let{slidesPerPage:t,loop:s,scrollContainer:l}=this,c=this.getSlides(),u=this.getSlides({excludeClones:!1}),a=(e+c.length)%c.length;this.activeSlide=a;let p=_(e+(s?t:0),0,u.length+1),y=u[p],w=l.getBoundingClientRect(),S=y.getBoundingClientRect();if(l.scrollTo({left:S.left-w.left+l.scrollLeft,top:S.top-w.top+l.scrollTop,behavior:A()?"auto":i}),this.userInteracted&&!this.loop){let O=this.activeSlide===c.length-1||this.activeSlide===this.slides.length-this.slidesPerPage,B=this.activeSlide===0;O?this.previousButton.focus({preventScroll:!0}):B&&this.nextButton.focus({preventScroll:!0})}}render(){let{scrollController:e,slidesPerMove:i}=this,t=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove),s=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove),l=this.loop||s>1,c=this.loop||s<t,u=this.localize.dir()==="ltr";return b`<div part="base" class="${n("carousel h-full w-full")}"><div id="scroll-container" part="scroll-container" class="${n(`carousel__slides mb-6
2
2
  grid max-h-full w-full items-center justify-items-center overflow-auto`,this.inverted?"focus-visible:focus-outline-inverted":"focus-visible:focus-outline",`overscroll-x-contain grid-flow-col auto-rows-[100%]
3
- snap-x snap-mandatory overflow-y-hidden`)}" style="--slides-per-page:${this.slidesPerPage}" aria-busy="${e.scrolling?"true":"false"}" role="status" tabindex="0" @keydown="${this.handleKeyDown}" @scrollend="${this.handleScrollEnd}"><slot></slot></div><div part="controls" class="${n("w-full flex items-center justify-center relative")}"><div part="navigation" class="${n("carousel__navigation flex items-center justify-center")}"><button part="navigation-button navigation-button--previous" id="carousel__navigation-button--previous" ?disabled="${!l}" class="${n("!mr-6 !rounded-sm sd-interactive",!l&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("previousSlide")}" aria-controls="scroll-container" aria-disabled="${l?"false":"true"}" @click="${l?a=>{this.previous(),this.unblockAutoplay(a,this.previousButton)}:null}"><slot name="previous-icon"><sd-icon class="${n("h-6 w-6 rotate-90 grid place-items-center")}" library="system" name="${u?"chevron-down":"chevron-up"}"></sd-icon></slot></button> ${this.variant==="dot"?b`<div part="pagination-dot" role="tablist" class="${n("carousel__pagination dot flex wrap items-center gap-2")}" aria-controls="scroll-container">${C(I(t),a=>{let p=a+1===s;return b`<button part="pagination-item ${p?"pagination-item--active":""}" class="${n("carousel__pagination-item","block cursor-pointer bg-none border-0 rounded-full",p?"bg-accent":"",this.inverted?"focus-within:focus-outline-inverted":"focus-within:focus-outline")}" role="tab" tabindex="0" aria-selected="${p?"true":"false"}" aria-label="${this.localize.term("goToSlide",a+1,t)}" @click="${y=>{this.goToSlide(a*i),this.unblockAutoplay(y,this.paginationItems[a])}}" @keydown="${this.handleKeyDown}"><span class="${n("h-4 w-4 block border hover:border-primary-500 rounded-full",this.inverted?"border-white hover:border-primary-500":"border-primary",p&&"bg-accent border-none",p?this.inverted?"hover:bg-accent-300":"hover:bg-accent-550":"")}"></span></button>`})}</div>`:b`<span part="pagination-number" class="carousel__pagination number flex gap-0.5 cursor-default select-none" aria-controls="scroll-container"><span part="pagination-item" class="${n("w-5 text-center border-b-2 border-accent",this.inverted?"text-white":"text-black")}">${s}</span> <span part="pagination-divider" class="${n("scale-y-[1.5]","text-center",this.inverted?"text-white":"text-black")}">/</span> <span part="pagination-item" class="${n("w-5 text-center",this.inverted?"text-white":"text-black")}">${t}</span></span>`} <button part="navigation-button navigation-button--next" id="carousel__navigation-button--next" ?disabled="${!c}" class="${n("!ml-6 !rounded-sm sd-interactive ",!c&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("nextSlide")}" aria-controls="scroll-container" aria-disabled="${c?"false":"true"}" @click="${c?a=>{this.next(),this.unblockAutoplay(a,this.nextButton)}:null}"><slot name="next-icon"><sd-icon class="${n("h-6 w-6 rotate-90 grid place-items-center")}" library="system" name="${u?"chevron-up":"chevron-down"}"></sd-icon></slot></button></div><button class="${n("ml-6 !rounded-sm","!absolute !right-0 sd-interactive",this.inverted?"sd-interactive--inverted":"sd-interactive--reset",!this.autoplay&&"!hidden")}" part="autoplay-controls" aria-label="${this.localize.term("autoplay")}" aria-pressed="true" @click="${a=>{this.pausedAutoplay=!this.pausedAutoplay,a.detail&&this.autoplayControls.blur()}}"><slot name="autoplay-start" class="${n(this.pausedAutoplay?"":"hidden")}"><sd-icon class="h-6 w-6 grid place-items-center" library="system" name="start"></sd-icon></slot><slot name="autoplay-pause" class="${n(this.pausedAutoplay?"hidden":"")}"><sd-icon class="h-6 w-6 grid place-items-center" library="system" name="pause"></sd-icon></slot></button></div></div>`}};r.styles=[...P.styles,x`:host{--slide-gap:var(--sl-spacing-medium,1rem);--scroll-hint:0px;display:flex}.carousel{grid-template-areas:". slides ." ". pagination ."}.carousel__pagination{grid-area:pagination}.carousel__slides{grid-area:slides;scrollbar-width:none;--slide-size:calc((100% - (var(--slides-per-page) - 1)*var(--slide-gap))/var(--slides-per-page));-moz-column-gap:var(--slide-gap);column-gap:var(--slide-gap);grid-auto-columns:var(--slide-size);padding-inline:var(--scroll-hint);scroll-padding-inline:var(--scroll-hint)}.carousel__slides::-webkit-scrollbar{display:none}@media (prefers-reduced-motion){:where(.carousel__slides){scroll-behavior:auto}}.carousel__navigation{grid-area:navigation}sd-button::part(label){align-items:center;display:flex;flex:1 1 auto;pointer-events:none}`],o([v('[part~="autoplay-controls"]')],r.prototype,"autoplayControls",2),o([v('[part~="navigation-button--previous"]')],r.prototype,"previousButton",2),o([v('[part~="navigation-button--next"]')],r.prototype,"nextButton",2),o([A('[part~="pagination-item"]')],r.prototype,"paginationItems",2),o([g({type:String,reflect:!0})],r.prototype,"variant",2),o([g({type:Boolean,reflect:!0})],r.prototype,"inverted",2),o([g({type:Boolean,reflect:!0})],r.prototype,"loop",2),o([g({type:Boolean,reflect:!0})],r.prototype,"autoplay",2),o([g({type:Number,attribute:"slides-per-page"})],r.prototype,"slidesPerPage",2),o([g({type:Number,attribute:"slides-per-move"})],r.prototype,"slidesPerMove",2),o([v("slot:not([name])")],r.prototype,"defaultSlot",2),o([v(".carousel__slides")],r.prototype,"scrollContainer",2),o([v(".carousel__pagination")],r.prototype,"paginationContainer",2),o([f()],r.prototype,"activeSlide",2),o([f()],r.prototype,"currentPage",2),o([f()],r.prototype,"pausedAutoplay",2),o([m("pausedAutoplay")],r.prototype,"handlePausedAutoplay",1),o([m("loop",{waitUntilFirstUpdate:!0}),m("slidesPerPage",{waitUntilFirstUpdate:!0})],r.prototype,"initializeSlides",1),o([m("activeSlide")],r.prototype,"handleSlideChange",1),o([m("slidesPerMove")],r.prototype,"handleSlidesPerMoveChange",1),o([m("autoplay")],r.prototype,"handleAutoplayChange",1),r=o([E("sd-carousel")],r);export{r as a};
3
+ snap-x snap-mandatory overflow-y-hidden`)}" style="--slides-per-page:${this.slidesPerPage}" aria-busy="${e.scrolling?"true":"false"}" role="status" tabindex="0" @keydown="${this.handleKeyDown}" @scrollend="${this.handleScrollEnd}"><slot></slot></div><div part="controls" class="${n("w-full flex items-center justify-center relative")}"><div part="navigation" class="${n("carousel__navigation flex items-center justify-center")}"><button part="navigation-button navigation-button--previous" id="carousel__navigation-button--previous" ?disabled="${!l}" class="${n("!mr-6 !rounded-sm sd-interactive",!l&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("previousSlide")}" aria-controls="scroll-container" aria-disabled="${l?"false":"true"}" @click="${l?a=>{this.previous(),this.unblockAutoplay(a,this.previousButton)}:null}"><slot name="previous-icon"><sd-icon class="${n("h-6 w-6 rotate-90 grid place-items-center")}" library="system" name="${u?"chevron-down":"chevron-up"}"></sd-icon></slot></button> ${this.variant==="dot"?b`<div part="pagination-dot" role="tablist" class="${n("carousel__pagination dot flex wrap items-center gap-2")}" aria-controls="scroll-container">${C(I(t),a=>{let p=a+1===s;return b`<button part="pagination-item ${p?"pagination-item--active":""}" class="${n("carousel__pagination-item","block cursor-pointer bg-none border-0 rounded-full",p?"bg-accent":"",this.inverted?"focus-within:focus-outline-inverted":"focus-within:focus-outline")}" role="tab" tabindex="0" aria-selected="${p?"true":"false"}" aria-label="${this.localize.term("goToSlide",a+1,t)}" @click="${y=>{this.goToSlide(a*i),this.unblockAutoplay(y,this.paginationItems[a])}}" @keydown="${this.handleKeyDown}"><span class="${n("h-4 w-4 block border hover:border-primary-500 rounded-full",this.inverted?"border-white hover:border-primary-500":"border-primary",p&&"bg-accent border-none",p?this.inverted?"hover:bg-accent-300":"hover:bg-accent-550":"")}"></span></button>`})}</div>`:b`<span part="pagination-number" class="carousel__pagination number flex gap-0.5 cursor-default select-none" aria-controls="scroll-container"><span part="pagination-item" class="${n("w-5 text-center border-b-2 border-accent",this.inverted?"text-white":"text-black")}">${s}</span> <span part="pagination-divider" class="${n("scale-y-[1.5]","text-center",this.inverted?"text-white":"text-black")}">/</span> <span part="pagination-item" class="${n("w-5 text-center",this.inverted?"text-white":"text-black")}">${t}</span></span>`} <button part="navigation-button navigation-button--next" id="carousel__navigation-button--next" ?disabled="${!c}" class="${n("!ml-6 !rounded-sm sd-interactive ",!c&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("nextSlide")}" aria-controls="scroll-container" aria-disabled="${c?"false":"true"}" @click="${c?a=>{this.next(),this.unblockAutoplay(a,this.nextButton)}:null}"><slot name="next-icon"><sd-icon class="${n("h-6 w-6 rotate-90 grid place-items-center")}" library="system" name="${u?"chevron-up":"chevron-down"}"></sd-icon></slot></button></div><button class="${n("ml-6 !rounded-sm","!absolute !right-0 sd-interactive",this.inverted?"sd-interactive--inverted":"sd-interactive--reset",!this.autoplay&&"!hidden")}" part="autoplay-controls" aria-label="${this.localize.term("autoplay")}" aria-pressed="true" @click="${a=>{this.pausedAutoplay=!this.pausedAutoplay,a.detail&&this.autoplayControls.blur()}}"><slot name="autoplay-start" class="${n(this.pausedAutoplay?"":"hidden")}"><sd-icon class="h-6 w-6 grid place-items-center" library="system" name="start"></sd-icon></slot><slot name="autoplay-pause" class="${n(this.pausedAutoplay?"hidden":"")}"><sd-icon class="h-6 w-6 grid place-items-center" library="system" name="pause"></sd-icon></slot></button></div></div>`}};r.styles=[...P.styles,x`:host{--slide-gap:var(--sl-spacing-medium,1rem);--scroll-hint:0px;display:flex}.carousel{grid-template-areas:". slides ." ". pagination ."}.carousel__pagination{grid-area:pagination}.carousel__slides{grid-area:slides;scrollbar-width:none;--slide-size:calc((100% - (var(--slides-per-page) - 1)*var(--slide-gap))/var(--slides-per-page));-moz-column-gap:var(--slide-gap);column-gap:var(--slide-gap);grid-auto-columns:var(--slide-size);padding-inline:var(--scroll-hint);scroll-padding-inline:var(--scroll-hint)}.carousel__slides::-webkit-scrollbar{display:none}@media (prefers-reduced-motion){:where(.carousel__slides){scroll-behavior:auto}}.carousel__navigation{grid-area:navigation}sd-button::part(label){align-items:center;display:flex;flex:1 1 auto;pointer-events:none}`],o([v('[part~="autoplay-controls"]')],r.prototype,"autoplayControls",2),o([v('[part~="navigation-button--previous"]')],r.prototype,"previousButton",2),o([v('[part~="navigation-button--next"]')],r.prototype,"nextButton",2),o([M('[part~="pagination-item"]')],r.prototype,"paginationItems",2),o([g({type:String,reflect:!0})],r.prototype,"variant",2),o([g({type:Boolean,reflect:!0})],r.prototype,"inverted",2),o([g({type:Boolean,reflect:!0})],r.prototype,"loop",2),o([g({type:Boolean,reflect:!0})],r.prototype,"autoplay",2),o([g({type:Number,attribute:"slides-per-page"})],r.prototype,"slidesPerPage",2),o([g({type:Number,attribute:"slides-per-move"})],r.prototype,"slidesPerMove",2),o([v("slot:not([name])")],r.prototype,"defaultSlot",2),o([v(".carousel__slides")],r.prototype,"scrollContainer",2),o([v(".carousel__pagination")],r.prototype,"paginationContainer",2),o([f()],r.prototype,"activeSlide",2),o([f()],r.prototype,"currentPage",2),o([f()],r.prototype,"pausedAutoplay",2),o([m("pausedAutoplay")],r.prototype,"handlePausedAutoplay",1),o([m("loop",{waitUntilFirstUpdate:!0}),m("slidesPerPage",{waitUntilFirstUpdate:!0})],r.prototype,"initializeSlides",1),o([m("activeSlide")],r.prototype,"handleSlideChange",1),o([m("slidesPerMove")],r.prototype,"handleSlidesPerMoveChange",1),o([m("autoplay")],r.prototype,"handleAutoplayChange",1),r=o([E("sd-carousel")],r);export{r as a};
4
4
  /*! Bundled license information:
5
5
 
6
6
  lit-html/directives/map.js:
@@ -1 +1 @@
1
- import{a}from"../../chunks/chunk.NER6LFUE.js";import"../../chunks/chunk.CBQWVOOS.js";import"../../chunks/chunk.EUGX6XW6.js";import"../../chunks/chunk.MHWW3RZB.js";import"../../chunks/chunk.NFQN6UG4.js";import"../../chunks/chunk.7TRFUW6U.js";import"../../chunks/chunk.SPDB3L7V.js";import"../../chunks/chunk.SNS2IHBI.js";import"../../chunks/chunk.TWZDCIM2.js";import"../../chunks/chunk.MWDEA25W.js";import"../../chunks/chunk.K7HF3VBZ.js";import"../../chunks/chunk.PYHYYOBE.js";import"../../chunks/chunk.EFLL7VXU.js";import"../../chunks/chunk.RQYP7MH5.js";import"../../chunks/chunk.KLRPP4NQ.js";import"../../chunks/chunk.E2DRD2OX.js";import"../../chunks/chunk.TNPIUMKG.js";import"../../chunks/chunk.LO4SY63J.js";import"../../chunks/chunk.O3CT4L2X.js";import"../../chunks/chunk.HJGLYEWV.js";import"../../chunks/chunk.26V4EXHB.js";import"../../chunks/chunk.5AILWWY2.js";import"../../chunks/chunk.IRWHG2Q4.js";import"../../chunks/chunk.TJOCV4DC.js";export{a as default};
1
+ import{a}from"../../chunks/chunk.5YWPH3S7.js";import"../../chunks/chunk.CBQWVOOS.js";import"../../chunks/chunk.EUGX6XW6.js";import"../../chunks/chunk.MHWW3RZB.js";import"../../chunks/chunk.NFQN6UG4.js";import"../../chunks/chunk.7TRFUW6U.js";import"../../chunks/chunk.SPDB3L7V.js";import"../../chunks/chunk.SNS2IHBI.js";import"../../chunks/chunk.TWZDCIM2.js";import"../../chunks/chunk.MWDEA25W.js";import"../../chunks/chunk.K7HF3VBZ.js";import"../../chunks/chunk.PYHYYOBE.js";import"../../chunks/chunk.EFLL7VXU.js";import"../../chunks/chunk.RQYP7MH5.js";import"../../chunks/chunk.KLRPP4NQ.js";import"../../chunks/chunk.E2DRD2OX.js";import"../../chunks/chunk.TNPIUMKG.js";import"../../chunks/chunk.LO4SY63J.js";import"../../chunks/chunk.O3CT4L2X.js";import"../../chunks/chunk.HJGLYEWV.js";import"../../chunks/chunk.26V4EXHB.js";import"../../chunks/chunk.5AILWWY2.js";import"../../chunks/chunk.IRWHG2Q4.js";import"../../chunks/chunk.TJOCV4DC.js";export{a as default};
@@ -16991,7 +16991,7 @@
16991
16991
  "package": {
16992
16992
  "name": "@solid-design-system/components",
16993
16993
  "description": "Solid Design System: Components",
16994
- "version": "4.3.0",
16994
+ "version": "4.3.1",
16995
16995
  "author": "Union Investment",
16996
16996
  "homepage": "https://solid-design-system.fe.union-investment.de/docs/",
16997
16997
  "license": "MIT"
@@ -106,7 +106,7 @@ var tr=Object.defineProperty,go=Object.defineProperties,vo=Object.getOwnProperty
106
106
  disabled:text-neutral-500 disabled:border-neutral-500`,tertiary:this.inverted?`border-transparent ${this.visuallyDisabled?"text-neutral-600 hover:text-neutral-600 active:text-neutral-600":"text-white hover:text-primary-100 hover:bg-primary-500 active:text-primary-200 active:bg-primary-800"}
107
107
  disabled:text-neutral-600`:`border-transparent ${this.visuallyDisabled?"text-neutral-500 hover:text-neutral-500 active:text-neutral-500":"text-primary hover:text-primary-500 hover:bg-primary-100 active:text-primary-800 active:bg-primary-200"}
108
108
  disabled:text-neutral-500`,cta:`text-white ${this.visuallyDisabled?"bg-neutral-500 hover:bg-neutral-500 active:bg-neutral-500":"bg-accent-500 border-transparent hover:bg-accent-550 active:bg-accent-700"}
109
- ${this.inverted?"disabled:bg-neutral-600":"disabled:bg-neutral-500"} disabled:text-white`}[this.variant])}" ?disabled="${E(t?void 0:this.disabled)}" type="${E(t?void 0:this.type)}" title="${this.title}" name="${E(t?void 0:this.name)}" value="${E(t?void 0:this.value)}" href="${E(t?this.href:void 0)}" target="${E(t?this.target:void 0)}" download="${E(t?this.download:void 0)}" rel="${E(t&&this.target?"noreferrer noopener":void 0)}" role="${E(t?void 0:"button")}" aria-disabled="${this.disabled||this.visuallyDisabled?"true":"false"}" aria-labelledby="content" tabindex="${this.disabled?"-1":"0"}" @blur="${this.handleBlur}" @focus="${this.handleFocus}" @invalid="${this.isButton()?this.handleInvalid:null}" @click="${this.handleClick}"><slot name="icon-left" part="icon-left" class="${c("flex flex-auto items-center pointer-events-none",r["icon-only"]&&"hidden",this.loading&&"invisible",r["icon-left"]&&{sm:"mr-1",md:"mr-2",lg:"mr-2"}[this.size])}"></slot><slot part="label" id="content" class="${c(r["icon-only"]?"flex flex-auto items-center pointer-events-none":"inline-block",this.loading&&"invisible")}"></slot><slot name="icon-right" part="icon-right" class="${c("flex flex-auto items-center pointer-events-none",this.loading&&"invisible",r["icon-only"]&&"hidden",r["icon-right"]&&{sm:"ml-1",md:"ml-2",lg:"ml-2"}[this.size])}"></slot>${this.loading?F`<sd-spinner class="${c("absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2")}"></sd-spinner>`:""}</${e}>`}};U.styles=[...m.styles,v`:host{cursor:pointer;display:inline-block;position:relative;width:var(--sd-spacing-auto,auto)}sd-spinner{--indicator-color:currentColor;--track-color:var(--tw-varcolor-200)}::slotted(sd-badge){pointer-events:none;position:absolute;right:var(--sd-spacing-0,0);top:var(--sd-spacing-0,0);--tw-translate-x:50%!important;--tw-translate-y:-50%!important;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}::slotted(sd-icon),sd-spinner{font-size:calc(var(--tw-varspacing)/2)}`],o([g("a, button")],U.prototype,"button",2),o([Ke({selector:"sd-icon"})],U.prototype,"_iconsInDefaultSlot",2),o([C()],U.prototype,"invalid",2),o([l()],U.prototype,"title",2),o([l({reflect:!0})],U.prototype,"variant",2),o([l({type:Boolean,reflect:!0})],U.prototype,"inverted",2),o([l({reflect:!0})],U.prototype,"size",2),o([l({type:Boolean,reflect:!0})],U.prototype,"disabled",2),o([l({type:Boolean,reflect:!0,attribute:"visually-disabled"})],U.prototype,"visuallyDisabled",2),o([l({type:Boolean,reflect:!0})],U.prototype,"loading",2),o([l()],U.prototype,"type",2),o([l()],U.prototype,"name",2),o([l()],U.prototype,"value",2),o([l()],U.prototype,"href",2),o([l()],U.prototype,"target",2),o([l()],U.prototype,"download",2),o([l()],U.prototype,"form",2),o([l({attribute:"formaction"})],U.prototype,"formAction",2),o([l({attribute:"formenctype"})],U.prototype,"formEnctype",2),o([l({attribute:"formmethod"})],U.prototype,"formMethod",2),o([l({attribute:"formnovalidate",type:Boolean})],U.prototype,"formNoValidate",2),o([l({attribute:"formtarget"})],U.prototype,"formTarget",2),o([w("disabled",{waitUntilFirstUpdate:!0})],U.prototype,"handleDisabledChange",1),U=o([y("sd-button")],U);var Fi=class{constructor(i,t){this.timerId=0;this.activeInteractions=0;this.paused=!1;this.stopped=!0;this.pause=()=>{this.activeInteractions++||(this.paused=!0,this.host.requestUpdate())};this.resume=()=>{--this.activeInteractions||(this.paused=!1,this.host.requestUpdate())};i.addController(this),this.host=i,this.tickCallback=t}hostConnected(){this.host.addEventListener("mouseenter",this.pause),this.host.addEventListener("mouseleave",this.resume),this.host.addEventListener("focusin",this.pause),this.host.addEventListener("focusout",this.resume),this.host.addEventListener("touchstart",this.pause,{passive:!0}),this.host.addEventListener("touchend",this.resume)}hostDisconnected(){this.stop(),this.host.removeEventListener("mouseenter",this.pause),this.host.removeEventListener("mouseleave",this.resume),this.host.removeEventListener("focusin",this.pause),this.host.removeEventListener("focusout",this.resume),this.host.removeEventListener("touchstart",this.pause),this.host.removeEventListener("touchend",this.resume)}start(i){this.stop(),this.stopped=!1,this.timerId=window.setInterval(()=>{this.paused||this.tickCallback()},i)}stop(){clearInterval(this.timerId),this.stopped=!0,this.host.requestUpdate()}};function Ts(s,i,t){let e=r=>Object.is(r,-0)?0:r;return s<i?e(i):s>t?e(t):e(s)}function*Ls(s,i){if(s!==void 0){let t=0;for(let e of s)yield i(e,t++)}}function*zs(s,i,t=1){let e=i===void 0?0:s;i!=null||(i=s);for(let r=e;t>0?r<i:i<r;r+=t)yield r}var As=Symbol(),Bi=s=>(i,t,e)=>{let r=e.value;e.value=function(...a){clearTimeout(this[As]),this[As]=window.setTimeout(()=>{r.apply(this,a)},s)}};var ci=class{constructor(i){this.pointers=new Set;this.dragging=!1;this.scrolling=!1;this.mouseDragging=!1;this.handleScroll=()=>{this.scrolling||(this.scrolling=!0,this.host.requestUpdate()),this.handleScrollEnd()};this.handlePointerDown=i=>{if(i.pointerType==="touch")return;this.pointers.add(i.pointerId),this.mouseDragging&&!this.dragging&&i.button===0&&(i.preventDefault(),this.host.scrollContainer.addEventListener("pointermove",this.handlePointerMove))};this.handlePointerMove=i=>{let t=this.host.scrollContainer,e=!!i.movementX||!!i.movementY;!this.dragging&&e?(t.setPointerCapture(i.pointerId),this.handleDragStart()):t.hasPointerCapture(i.pointerId)&&this.handleDrag(i)};this.handlePointerUp=i=>{this.pointers.delete(i.pointerId),this.host.scrollContainer.releasePointerCapture(i.pointerId),this.pointers.size===0&&this.handleDragEnd()};this.handleTouchEnd=i=>{for(let t of i.changedTouches)this.pointers.delete(t.identifier)};this.handleTouchStart=i=>{for(let t of i.touches)this.pointers.add(t.identifier)};this.host=i,i.addController(this)}async hostConnected(){let i=this.host;await i.updateComplete;let t=i.scrollContainer;t.addEventListener("scroll",this.handleScroll,{passive:!0}),t.addEventListener("pointerdown",this.handlePointerDown),t.addEventListener("pointerup",this.handlePointerUp),t.addEventListener("pointercancel",this.handlePointerUp),t.addEventListener("touchstart",this.handleTouchStart,{passive:!0}),t.addEventListener("touchend",this.handleTouchEnd)}hostDisconnected(){let t=this.host.scrollContainer;t.removeEventListener("scroll",this.handleScroll),t.removeEventListener("pointerdown",this.handlePointerDown),t.removeEventListener("pointerup",this.handlePointerUp),t.removeEventListener("pointercancel",this.handlePointerUp),t.removeEventListener("touchstart",this.handleTouchStart),t.removeEventListener("touchend",this.handleTouchEnd)}handleScrollEnd(){this.pointers.size?this.handleScrollEnd():(this.scrolling=!1,this.host.scrollContainer.dispatchEvent(new CustomEvent("scrollend",{bubbles:!1,cancelable:!1})),this.host.requestUpdate())}handleDragStart(){let i=this.host;this.dragging=!0,i.scrollContainer.style.setProperty("scroll-snap-type","unset"),i.requestUpdate()}handleDrag(i){this.host.scrollContainer.scrollBy({left:-i.movementX,top:-i.movementY})}async handleDragEnd(){let i=this.host,t=i.scrollContainer;t.removeEventListener("pointermove",this.handlePointerMove),this.dragging=!1;let e=t.scrollLeft,r=t.scrollTop;t.style.removeProperty("scroll-snap-type");let a=t.scrollLeft,n=t.scrollTop;t.style.setProperty("scroll-snap-type","unset"),t.scrollTo({left:e,top:r,behavior:"auto"}),t.scrollTo({left:a,top:n,behavior:ai()?"auto":"smooth"}),this.scrolling&&await R(t,"scrollend"),t.style.removeProperty("scroll-snap-type"),i.requestUpdate()}};o([Bi(100)],ci.prototype,"handleScrollEnd",1);var ne=class extends m{static isCarouselItem(i){return i instanceof Element&&i.getAttribute("aria-roledescription")==="slide"}connectedCallback(){super.connectedCallback(),this.setAttribute("role","group")}render(){return p`<slot></slot>`}};ne.styles=[...m.styles,v`:host{align-items:center;aspect-ratio:var(--aspect-ratio);display:flex;flex-direction:column;height:100%;justify-content:center;scroll-snap-align:start;scroll-snap-stop:always;width:100%}::slotted(img){height:100%;-o-object-fit:cover;object-fit:cover;width:100%}`],ne=o([y("sd-carousel-item")],ne);var j=class extends m{constructor(){super(...arguments);this.variant="number";this.inverted=!1;this.loop=!1;this.autoplay=!1;this.slidesPerPage=1;this.slidesPerMove=1;this.activeSlide=0;this.currentPage=1;this.pausedAutoplay=!1;this.autoplayController=new Fi(this,()=>this.next());this.scrollController=new ci(this);this.slides=this.getElementsByTagName("sd-carousel-item");this.intersectionObserverEntries=new Map;this.localize=new S(this);this.userInteracted=!1;this.handleUserInteraction=()=>{this.userInteracted=!0};this.handleSlotChange=t=>{t.some(r=>[...r.addedNodes,...r.removedNodes].some(a=>ne.isCarouselItem(a)&&!a.hasAttribute("data-clone")))&&this.initializeSlides(),this.requestUpdate()};this.unblockAutoplay=(t,e)=>{t.detail&&e.blur()}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","region"),this.setAttribute("aria-label",this.localize.term("carousel")),["click","keydown"].forEach(e=>this.addEventListener(e,this.handleUserInteraction));let t=new IntersectionObserver(e=>{e.forEach(r=>{this.intersectionObserverEntries.set(r.target,r);let a=r.target;a.toggleAttribute("inert",!r.isIntersecting),a.classList.toggle("--in-view",r.isIntersecting),a.setAttribute("aria-hidden",r.isIntersecting?"false":"true")})},{root:this,threshold:.6});this.intersectionObserver=t,t.takeRecords().forEach(e=>{this.intersectionObserverEntries.set(e.target,e)})}disconnectedCallback(){super.disconnectedCallback(),this.intersectionObserver.disconnect(),this.mutationObserver.disconnect(),["click","keydown"].forEach(t=>this.removeEventListener(t,this.handleUserInteraction))}firstUpdated(){this.initializeSlides(),this.mutationObserver=new MutationObserver(this.handleSlotChange),this.mutationObserver.observe(this,{childList:!0,subtree:!1})}getPageCount(t,e,r){return Math.ceil((t-e)/r)+1>0?Math.ceil((t-e)/r)+1:1}getCurrentPage(t,e,r,a){return Math.ceil((t-r)/a)-Math.ceil((t-r-e)/a)+1}getSlides({excludeClones:t=!0}={}){return[...this.slides].filter(e=>!t||!e.hasAttribute("data-clone"))}handleKeyDown(t){if(["ArrowLeft","ArrowRight","ArrowUp","ArrowDown","Home","End"].includes(t.key)){let e=t.target,r=this.localize.dir()==="rtl",a=e.closest('[part~="pagination-item"]')!==null,n=t.key==="ArrowDown"||!r&&t.key==="ArrowRight"||r&&t.key==="ArrowLeft",d=t.key==="ArrowUp"||!r&&t.key==="ArrowLeft"||r&&t.key==="ArrowRight";t.preventDefault(),d&&this.previous(),n&&this.next(),t.key==="Home"&&this.goToSlide(0),t.key==="End"&&this.goToSlide(this.getSlides().length-1),a&&this.updateComplete.then(()=>{var u;let h=(u=this.shadowRoot)==null?void 0:u.querySelector('[part~="pagination-item--active"]');h&&h.focus()})}}handleScrollEnd(){let t=this.getSlides(),r=[...this.intersectionObserverEntries.values()].find(a=>a.isIntersecting);if(this.loop&&(r!=null&&r.target.hasAttribute("data-clone"))){let a=Number(r.target.getAttribute("data-clone"));this.goToSlide(a,"auto");return}r&&(this.activeSlide=t.indexOf(r.target))}pause(){this.pausedAutoplay=!0}resume(){this.pausedAutoplay=!1}handlePausedAutoplay(){var t,e;this.pausedAutoplay?(this.autoplayController.stop(),(t=this.autoplayControls)==null||t.setAttribute("aria-pressed","false")):this.autoplay&&(this.autoplayController.start(3e3),(e=this.autoplayControls)==null||e.setAttribute("aria-pressed","true"))}initializeSlides(){let t=this.getSlides(),e=this.intersectionObserver;if(this.intersectionObserverEntries.clear(),this.getSlides({excludeClones:!1}).forEach((r,a)=>{e.unobserve(r),r.classList.remove("--in-view"),r.classList.remove("--is-active"),r.setAttribute("aria-label",this.localize.term("slideNum",a+1,t.length)),r.hasAttribute("data-clone")&&r.remove()}),this.loop){let r=this.slidesPerPage,a=t.slice(-r),n=t.slice(0,r);a.reverse().forEach((d,h)=>{let u=d.cloneNode(!0);u.setAttribute("data-clone",String(t.length-h-1)),this.prepend(u)}),n.forEach((d,h)=>{let u=d.cloneNode(!0);u.setAttribute("data-clone",String(h)),this.append(u)})}this.getSlides({excludeClones:!1}).forEach(r=>{e.observe(r)}),this.goToSlide(this.activeSlide,"auto")}handleSlideChange(){let t=this.getSlides();t.forEach((a,n)=>{a.classList.toggle("--is-active",n===this.activeSlide)});let e=this.getCurrentPage(t.length,this.activeSlide,this.slidesPerPage,this.slidesPerMove);this.currentPage!==e&&(this.currentPage=e),this.hasUpdated&&this.emit("sd-slide-change",{detail:{index:this.activeSlide,slide:t[this.activeSlide]}});let r=this.getPageCount(t.length,this.slidesPerPage,this.slidesPerMove);this.currentPage>r&&requestAnimationFrame(()=>{this.nextTillFirst()})}handleSlidesPerMoveChange(){let t=this.getSlides({excludeClones:!1}),e=this.slidesPerMove;t.forEach((r,a)=>{Math.abs(a-e)%e===0?r.style.removeProperty("scroll-snap-align"):r.style.setProperty("scroll-snap-align","none")})}handleAutoplayChange(){this.autoplayController.stop(),this.autoplay&&!this.pausedAutoplay&&this.autoplayController.start(3e3)}previous(t="smooth"){let e=this.activeSlide||this.activeSlide-this.slidesPerMove,r=!1;for(;!r&&e>0;)e-=1,r=Math.abs(e-this.slidesPerMove)%this.slidesPerMove===0;this.currentPage-1===0&&this.loop?this.goToSlide(this.activeSlide-this.slidesPerPage,t):this.goToSlide(e,t)}next(t="smooth"){this.currentPage+1<=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove)?this.goToSlide(this.activeSlide+this.slidesPerMove,t):this.loop&&this.nextTillFirst(t)}nextTillFirst(t="smooth"){for(;this.activeSlide!==0;)this.goToSlide(this.activeSlide+1,t);this.currentPage=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove)}goToSlide(t,e="smooth"){let{slidesPerPage:r,loop:a,scrollContainer:n}=this,d=this.getSlides(),h=this.getSlides({excludeClones:!1}),u=(t+d.length)%d.length;this.activeSlide=u;let f=Ts(t+(a?r:0),0,h.length+1),b=h[f],k=n.getBoundingClientRect(),x=b.getBoundingClientRect();if(n.scrollTo({left:x.left-k.left+n.scrollLeft,top:x.top-k.top+n.scrollTop,behavior:ai()?"auto":e}),this.userInteracted&&!this.loop){let $=this.activeSlide===d.length-1||this.activeSlide===this.slides.length-this.slidesPerPage,z=this.activeSlide===0;$?this.previousButton.focus({preventScroll:!0}):z&&this.nextButton.focus({preventScroll:!0})}}render(){let{scrollController:t,slidesPerMove:e}=this,r=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove),a=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove),n=this.loop||a>1,d=this.loop||a<r,h=this.localize.dir()==="ltr";return p`<div part="base" class="${c("carousel h-full w-full")}"><div id="scroll-container" part="scroll-container" class="${c(`carousel__slides mb-6
109
+ ${this.inverted?"disabled:bg-neutral-600":"disabled:bg-neutral-500"} disabled:text-white`}[this.variant])}" ?disabled="${E(t?void 0:this.disabled)}" type="${E(t?void 0:this.type)}" title="${this.title}" name="${E(t?void 0:this.name)}" value="${E(t?void 0:this.value)}" href="${E(t?this.href:void 0)}" target="${E(t?this.target:void 0)}" download="${E(t?this.download:void 0)}" rel="${E(t&&this.target?"noreferrer noopener":void 0)}" role="${E(t?void 0:"button")}" aria-disabled="${this.disabled||this.visuallyDisabled?"true":"false"}" aria-labelledby="content" tabindex="${this.disabled?"-1":"0"}" @blur="${this.handleBlur}" @focus="${this.handleFocus}" @invalid="${this.isButton()?this.handleInvalid:null}" @click="${this.handleClick}"><slot name="icon-left" part="icon-left" class="${c("flex flex-auto items-center pointer-events-none",r["icon-only"]&&"hidden",this.loading&&"invisible",r["icon-left"]&&{sm:"mr-1",md:"mr-2",lg:"mr-2"}[this.size])}"></slot><slot part="label" id="content" class="${c(r["icon-only"]?"flex flex-auto items-center pointer-events-none":"inline-block",this.loading&&"invisible")}"></slot><slot name="icon-right" part="icon-right" class="${c("flex flex-auto items-center pointer-events-none",this.loading&&"invisible",r["icon-only"]&&"hidden",r["icon-right"]&&{sm:"ml-1",md:"ml-2",lg:"ml-2"}[this.size])}"></slot>${this.loading?F`<sd-spinner class="${c("absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2")}"></sd-spinner>`:""}</${e}>`}};U.styles=[...m.styles,v`:host{cursor:pointer;display:inline-block;position:relative;width:var(--sd-spacing-auto,auto)}sd-spinner{--indicator-color:currentColor;--track-color:var(--tw-varcolor-200)}::slotted(sd-badge){pointer-events:none;position:absolute;right:var(--sd-spacing-0,0);top:var(--sd-spacing-0,0);--tw-translate-x:50%!important;--tw-translate-y:-50%!important;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}::slotted(sd-icon),sd-spinner{font-size:calc(var(--tw-varspacing)/2)}`],o([g("a, button")],U.prototype,"button",2),o([Ke({selector:"sd-icon"})],U.prototype,"_iconsInDefaultSlot",2),o([C()],U.prototype,"invalid",2),o([l()],U.prototype,"title",2),o([l({reflect:!0})],U.prototype,"variant",2),o([l({type:Boolean,reflect:!0})],U.prototype,"inverted",2),o([l({reflect:!0})],U.prototype,"size",2),o([l({type:Boolean,reflect:!0})],U.prototype,"disabled",2),o([l({type:Boolean,reflect:!0,attribute:"visually-disabled"})],U.prototype,"visuallyDisabled",2),o([l({type:Boolean,reflect:!0})],U.prototype,"loading",2),o([l()],U.prototype,"type",2),o([l()],U.prototype,"name",2),o([l()],U.prototype,"value",2),o([l()],U.prototype,"href",2),o([l()],U.prototype,"target",2),o([l()],U.prototype,"download",2),o([l()],U.prototype,"form",2),o([l({attribute:"formaction"})],U.prototype,"formAction",2),o([l({attribute:"formenctype"})],U.prototype,"formEnctype",2),o([l({attribute:"formmethod"})],U.prototype,"formMethod",2),o([l({attribute:"formnovalidate",type:Boolean})],U.prototype,"formNoValidate",2),o([l({attribute:"formtarget"})],U.prototype,"formTarget",2),o([w("disabled",{waitUntilFirstUpdate:!0})],U.prototype,"handleDisabledChange",1),U=o([y("sd-button")],U);var Fi=class{constructor(i,t){this.timerId=0;this.activeInteractions=0;this.paused=!1;this.stopped=!0;this.pause=()=>{this.activeInteractions++||(this.paused=!0,this.host.requestUpdate())};this.resume=()=>{--this.activeInteractions||(this.paused=!1,this.host.requestUpdate())};i.addController(this),this.host=i,this.tickCallback=t}hostConnected(){this.host.addEventListener("mouseenter",this.pause),this.host.addEventListener("mouseleave",this.resume),this.host.addEventListener("focusin",this.pause),this.host.addEventListener("focusout",this.resume),this.host.addEventListener("touchstart",this.pause,{passive:!0}),this.host.addEventListener("touchend",this.resume)}hostDisconnected(){this.stop(),this.host.removeEventListener("mouseenter",this.pause),this.host.removeEventListener("mouseleave",this.resume),this.host.removeEventListener("focusin",this.pause),this.host.removeEventListener("focusout",this.resume),this.host.removeEventListener("touchstart",this.pause),this.host.removeEventListener("touchend",this.resume)}start(i){this.stop(),this.stopped=!1,this.timerId=window.setInterval(()=>{this.paused||this.tickCallback()},i)}stop(){clearInterval(this.timerId),this.stopped=!0,this.host.requestUpdate()}};function Ts(s,i,t){let e=r=>Object.is(r,-0)?0:r;return s<i?e(i):s>t?e(t):e(s)}function*Ls(s,i){if(s!==void 0){let t=0;for(let e of s)yield i(e,t++)}}function*zs(s,i,t=1){let e=i===void 0?0:s;i!=null||(i=s);for(let r=e;t>0?r<i:i<r;r+=t)yield r}var As=Symbol(),Bi=s=>(i,t,e)=>{let r=e.value;e.value=function(...a){clearTimeout(this[As]),this[As]=window.setTimeout(()=>{r.apply(this,a)},s)}};var ci=class{constructor(i){this.pointers=new Set;this.dragging=!1;this.scrolling=!1;this.mouseDragging=!1;this.handleScroll=()=>{this.scrolling||(this.scrolling=!0,this.host.requestUpdate()),this.handleScrollEnd()};this.handlePointerDown=i=>{if(i.pointerType==="touch")return;this.pointers.add(i.pointerId),this.mouseDragging&&!this.dragging&&i.button===0&&(i.preventDefault(),this.host.scrollContainer.addEventListener("pointermove",this.handlePointerMove))};this.handlePointerMove=i=>{let t=this.host.scrollContainer,e=!!i.movementX||!!i.movementY;!this.dragging&&e?(t.setPointerCapture(i.pointerId),this.handleDragStart()):t.hasPointerCapture(i.pointerId)&&this.handleDrag(i)};this.handlePointerUp=i=>{this.pointers.delete(i.pointerId),this.host.scrollContainer.releasePointerCapture(i.pointerId),this.pointers.size===0&&this.handleDragEnd()};this.handleTouchEnd=i=>{for(let t of i.changedTouches)this.pointers.delete(t.identifier)};this.handleTouchStart=i=>{for(let t of i.touches)this.pointers.add(t.identifier)};this.host=i,i.addController(this)}async hostConnected(){let i=this.host;await i.updateComplete;let t=i.scrollContainer;t.addEventListener("scroll",this.handleScroll,{passive:!0}),t.addEventListener("pointerdown",this.handlePointerDown),t.addEventListener("pointerup",this.handlePointerUp),t.addEventListener("pointercancel",this.handlePointerUp),t.addEventListener("touchstart",this.handleTouchStart,{passive:!0}),t.addEventListener("touchend",this.handleTouchEnd)}hostDisconnected(){let t=this.host.scrollContainer;t.removeEventListener("scroll",this.handleScroll),t.removeEventListener("pointerdown",this.handlePointerDown),t.removeEventListener("pointerup",this.handlePointerUp),t.removeEventListener("pointercancel",this.handlePointerUp),t.removeEventListener("touchstart",this.handleTouchStart),t.removeEventListener("touchend",this.handleTouchEnd)}handleScrollEnd(){this.pointers.size?this.handleScrollEnd():(this.scrolling=!1,this.host.scrollContainer.dispatchEvent(new CustomEvent("scrollend",{bubbles:!1,cancelable:!1})),this.host.requestUpdate())}handleDragStart(){let i=this.host;this.dragging=!0,i.scrollContainer.style.setProperty("scroll-snap-type","unset"),i.requestUpdate()}handleDrag(i){this.host.scrollContainer.scrollBy({left:-i.movementX,top:-i.movementY})}async handleDragEnd(){let i=this.host,t=i.scrollContainer;t.removeEventListener("pointermove",this.handlePointerMove),this.dragging=!1;let e=t.scrollLeft,r=t.scrollTop;t.style.removeProperty("scroll-snap-type");let a=t.scrollLeft,n=t.scrollTop;t.style.setProperty("scroll-snap-type","unset"),t.scrollTo({left:e,top:r,behavior:"auto"}),t.scrollTo({left:a,top:n,behavior:ai()?"auto":"smooth"}),this.scrolling&&await R(t,"scrollend"),t.style.removeProperty("scroll-snap-type"),i.requestUpdate()}};o([Bi(100)],ci.prototype,"handleScrollEnd",1);var ne=class extends m{static isCarouselItem(i){return i instanceof Element&&i.getAttribute("aria-roledescription")==="slide"}connectedCallback(){super.connectedCallback(),this.setAttribute("role","group")}render(){return p`<slot></slot>`}};ne.styles=[...m.styles,v`:host{align-items:center;aspect-ratio:var(--aspect-ratio);display:flex;flex-direction:column;height:100%;justify-content:center;scroll-snap-align:start;scroll-snap-stop:always;width:100%}::slotted(img){height:100%;-o-object-fit:cover;object-fit:cover;width:100%}`],ne=o([y("sd-carousel-item")],ne);var j=class extends m{constructor(){super(...arguments);this.variant="number";this.inverted=!1;this.loop=!1;this.autoplay=!1;this.slidesPerPage=1;this.slidesPerMove=1;this.activeSlide=0;this.currentPage=1;this.pausedAutoplay=!1;this.autoplayController=new Fi(this,()=>this.next());this.scrollController=new ci(this);this.slides=this.getElementsByTagName("sd-carousel-item");this.intersectionObserverEntries=new Map;this.localize=new S(this);this.userInteracted=!1;this.handleUserInteraction=()=>{this.userInteracted=!0};this.handleSlotChange=t=>{t.some(r=>[...r.addedNodes,...r.removedNodes].some(a=>ne.isCarouselItem(a)&&!a.hasAttribute("data-clone")))&&this.initializeSlides(),this.requestUpdate()};this.unblockAutoplay=(t,e)=>{t.detail&&e.blur()}}connectedCallback(){super.connectedCallback(),["click","keydown"].forEach(e=>this.addEventListener(e,this.handleUserInteraction));let t=new IntersectionObserver(e=>{e.forEach(r=>{this.intersectionObserverEntries.set(r.target,r);let a=r.target;a.toggleAttribute("inert",!r.isIntersecting),a.classList.toggle("--in-view",r.isIntersecting),a.setAttribute("aria-hidden",r.isIntersecting?"false":"true")})},{root:this,threshold:.6});this.intersectionObserver=t,t.takeRecords().forEach(e=>{this.intersectionObserverEntries.set(e.target,e)})}disconnectedCallback(){super.disconnectedCallback(),this.intersectionObserver.disconnect(),this.mutationObserver.disconnect(),["click","keydown"].forEach(t=>this.removeEventListener(t,this.handleUserInteraction))}firstUpdated(){this.initializeSlides(),this.mutationObserver=new MutationObserver(this.handleSlotChange),this.mutationObserver.observe(this,{childList:!0,subtree:!1})}getPageCount(t,e,r){return Math.ceil((t-e)/r)+1>0?Math.ceil((t-e)/r)+1:1}getCurrentPage(t,e,r,a){return Math.ceil((t-r)/a)-Math.ceil((t-r-e)/a)+1}getSlides({excludeClones:t=!0}={}){return[...this.slides].filter(e=>!t||!e.hasAttribute("data-clone"))}handleKeyDown(t){if(["ArrowLeft","ArrowRight","ArrowUp","ArrowDown","Home","End"].includes(t.key)){let e=t.target,r=this.localize.dir()==="rtl",a=e.closest('[part~="pagination-item"]')!==null,n=t.key==="ArrowDown"||!r&&t.key==="ArrowRight"||r&&t.key==="ArrowLeft",d=t.key==="ArrowUp"||!r&&t.key==="ArrowLeft"||r&&t.key==="ArrowRight";t.preventDefault(),d&&this.previous(),n&&this.next(),t.key==="Home"&&this.goToSlide(0),t.key==="End"&&this.goToSlide(this.getSlides().length-1),a&&this.updateComplete.then(()=>{var u;let h=(u=this.shadowRoot)==null?void 0:u.querySelector('[part~="pagination-item--active"]');h&&h.focus()})}}handleScrollEnd(){let t=this.getSlides(),r=[...this.intersectionObserverEntries.values()].find(a=>a.isIntersecting);if(this.loop&&(r!=null&&r.target.hasAttribute("data-clone"))){let a=Number(r.target.getAttribute("data-clone"));this.goToSlide(a,"auto");return}r&&(this.activeSlide=t.indexOf(r.target))}pause(){this.pausedAutoplay=!0}resume(){this.pausedAutoplay=!1}handlePausedAutoplay(){var t,e;this.pausedAutoplay?(this.autoplayController.stop(),(t=this.autoplayControls)==null||t.setAttribute("aria-pressed","false")):this.autoplay&&(this.autoplayController.start(3e3),(e=this.autoplayControls)==null||e.setAttribute("aria-pressed","true"))}initializeSlides(){let t=this.getSlides(),e=this.intersectionObserver;if(this.intersectionObserverEntries.clear(),this.getSlides({excludeClones:!1}).forEach((r,a)=>{e.unobserve(r),r.classList.remove("--in-view"),r.classList.remove("--is-active"),r.setAttribute("aria-label",this.localize.term("slideNum",a+1,t.length)),r.hasAttribute("data-clone")&&r.remove()}),this.loop){let r=this.slidesPerPage,a=t.slice(-r),n=t.slice(0,r);a.reverse().forEach((d,h)=>{let u=d.cloneNode(!0);u.setAttribute("data-clone",String(t.length-h-1)),this.prepend(u)}),n.forEach((d,h)=>{let u=d.cloneNode(!0);u.setAttribute("data-clone",String(h)),this.append(u)})}this.getSlides({excludeClones:!1}).forEach(r=>{e.observe(r)}),this.goToSlide(this.activeSlide,"auto")}handleSlideChange(){let t=this.getSlides();t.forEach((a,n)=>{a.classList.toggle("--is-active",n===this.activeSlide)});let e=this.getCurrentPage(t.length,this.activeSlide,this.slidesPerPage,this.slidesPerMove);this.currentPage!==e&&(this.currentPage=e),this.hasUpdated&&this.emit("sd-slide-change",{detail:{index:this.activeSlide,slide:t[this.activeSlide]}});let r=this.getPageCount(t.length,this.slidesPerPage,this.slidesPerMove);this.currentPage>r&&requestAnimationFrame(()=>{this.nextTillFirst()})}handleSlidesPerMoveChange(){let t=this.getSlides({excludeClones:!1}),e=this.slidesPerMove;t.forEach((r,a)=>{Math.abs(a-e)%e===0?r.style.removeProperty("scroll-snap-align"):r.style.setProperty("scroll-snap-align","none")})}handleAutoplayChange(){this.autoplayController.stop(),this.autoplay&&!this.pausedAutoplay&&this.autoplayController.start(3e3)}previous(t="smooth"){let e=this.activeSlide||this.activeSlide-this.slidesPerMove,r=!1;for(;!r&&e>0;)e-=1,r=Math.abs(e-this.slidesPerMove)%this.slidesPerMove===0;this.currentPage-1===0&&this.loop?this.goToSlide(this.activeSlide-this.slidesPerPage,t):this.goToSlide(e,t)}next(t="smooth"){this.currentPage+1<=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove)?this.goToSlide(this.activeSlide+this.slidesPerMove,t):this.loop&&this.nextTillFirst(t)}nextTillFirst(t="smooth"){for(;this.activeSlide!==0;)this.goToSlide(this.activeSlide+1,t);this.currentPage=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove)}goToSlide(t,e="smooth"){let{slidesPerPage:r,loop:a,scrollContainer:n}=this,d=this.getSlides(),h=this.getSlides({excludeClones:!1}),u=(t+d.length)%d.length;this.activeSlide=u;let f=Ts(t+(a?r:0),0,h.length+1),b=h[f],k=n.getBoundingClientRect(),x=b.getBoundingClientRect();if(n.scrollTo({left:x.left-k.left+n.scrollLeft,top:x.top-k.top+n.scrollTop,behavior:ai()?"auto":e}),this.userInteracted&&!this.loop){let $=this.activeSlide===d.length-1||this.activeSlide===this.slides.length-this.slidesPerPage,z=this.activeSlide===0;$?this.previousButton.focus({preventScroll:!0}):z&&this.nextButton.focus({preventScroll:!0})}}render(){let{scrollController:t,slidesPerMove:e}=this,r=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove),a=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove),n=this.loop||a>1,d=this.loop||a<r,h=this.localize.dir()==="ltr";return p`<div part="base" class="${c("carousel h-full w-full")}"><div id="scroll-container" part="scroll-container" class="${c(`carousel__slides mb-6
110
110
  grid max-h-full w-full items-center justify-items-center overflow-auto`,this.inverted?"focus-visible:focus-outline-inverted":"focus-visible:focus-outline",`overscroll-x-contain grid-flow-col auto-rows-[100%]
111
111
  snap-x snap-mandatory overflow-y-hidden`)}" style="--slides-per-page:${this.slidesPerPage}" aria-busy="${t.scrolling?"true":"false"}" role="status" tabindex="0" @keydown="${this.handleKeyDown}" @scrollend="${this.handleScrollEnd}"><slot></slot></div><div part="controls" class="${c("w-full flex items-center justify-center relative")}"><div part="navigation" class="${c("carousel__navigation flex items-center justify-center")}"><button part="navigation-button navigation-button--previous" id="carousel__navigation-button--previous" ?disabled="${!n}" class="${c("!mr-6 !rounded-sm sd-interactive",!n&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("previousSlide")}" aria-controls="scroll-container" aria-disabled="${n?"false":"true"}" @click="${n?u=>{this.previous(),this.unblockAutoplay(u,this.previousButton)}:null}"><slot name="previous-icon"><sd-icon class="${c("h-6 w-6 rotate-90 grid place-items-center")}" library="system" name="${h?"chevron-down":"chevron-up"}"></sd-icon></slot></button> ${this.variant==="dot"?p`<div part="pagination-dot" role="tablist" class="${c("carousel__pagination dot flex wrap items-center gap-2")}" aria-controls="scroll-container">${Ls(zs(r),u=>{let f=u+1===a;return p`<button part="pagination-item ${f?"pagination-item--active":""}" class="${c("carousel__pagination-item","block cursor-pointer bg-none border-0 rounded-full",f?"bg-accent":"",this.inverted?"focus-within:focus-outline-inverted":"focus-within:focus-outline")}" role="tab" tabindex="0" aria-selected="${f?"true":"false"}" aria-label="${this.localize.term("goToSlide",u+1,r)}" @click="${b=>{this.goToSlide(u*e),this.unblockAutoplay(b,this.paginationItems[u])}}" @keydown="${this.handleKeyDown}"><span class="${c("h-4 w-4 block border hover:border-primary-500 rounded-full",this.inverted?"border-white hover:border-primary-500":"border-primary",f&&"bg-accent border-none",f?this.inverted?"hover:bg-accent-300":"hover:bg-accent-550":"")}"></span></button>`})}</div>`:p`<span part="pagination-number" class="carousel__pagination number flex gap-0.5 cursor-default select-none" aria-controls="scroll-container"><span part="pagination-item" class="${c("w-5 text-center border-b-2 border-accent",this.inverted?"text-white":"text-black")}">${a}</span> <span part="pagination-divider" class="${c("scale-y-[1.5]","text-center",this.inverted?"text-white":"text-black")}">/</span> <span part="pagination-item" class="${c("w-5 text-center",this.inverted?"text-white":"text-black")}">${r}</span></span>`} <button part="navigation-button navigation-button--next" id="carousel__navigation-button--next" ?disabled="${!d}" class="${c("!ml-6 !rounded-sm sd-interactive ",!d&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("nextSlide")}" aria-controls="scroll-container" aria-disabled="${d?"false":"true"}" @click="${d?u=>{this.next(),this.unblockAutoplay(u,this.nextButton)}:null}"><slot name="next-icon"><sd-icon class="${c("h-6 w-6 rotate-90 grid place-items-center")}" library="system" name="${h?"chevron-up":"chevron-down"}"></sd-icon></slot></button></div><button class="${c("ml-6 !rounded-sm","!absolute !right-0 sd-interactive",this.inverted?"sd-interactive--inverted":"sd-interactive--reset",!this.autoplay&&"!hidden")}" part="autoplay-controls" aria-label="${this.localize.term("autoplay")}" aria-pressed="true" @click="${u=>{this.pausedAutoplay=!this.pausedAutoplay,u.detail&&this.autoplayControls.blur()}}"><slot name="autoplay-start" class="${c(this.pausedAutoplay?"":"hidden")}"><sd-icon class="h-6 w-6 grid place-items-center" library="system" name="start"></sd-icon></slot><slot name="autoplay-pause" class="${c(this.pausedAutoplay?"hidden":"")}"><sd-icon class="h-6 w-6 grid place-items-center" library="system" name="pause"></sd-icon></slot></button></div></div>`}};j.styles=[...m.styles,v`:host{--slide-gap:var(--sl-spacing-medium,1rem);--scroll-hint:0px;display:flex}.carousel{grid-template-areas:". slides ." ". pagination ."}.carousel__pagination{grid-area:pagination}.carousel__slides{grid-area:slides;scrollbar-width:none;--slide-size:calc((100% - (var(--slides-per-page) - 1)*var(--slide-gap))/var(--slides-per-page));-moz-column-gap:var(--slide-gap);column-gap:var(--slide-gap);grid-auto-columns:var(--slide-size);padding-inline:var(--scroll-hint);scroll-padding-inline:var(--scroll-hint)}.carousel__slides::-webkit-scrollbar{display:none}@media (prefers-reduced-motion){:where(.carousel__slides){scroll-behavior:auto}}.carousel__navigation{grid-area:navigation}sd-button::part(label){align-items:center;display:flex;flex:1 1 auto;pointer-events:none}`],o([g('[part~="autoplay-controls"]')],j.prototype,"autoplayControls",2),o([g('[part~="navigation-button--previous"]')],j.prototype,"previousButton",2),o([g('[part~="navigation-button--next"]')],j.prototype,"nextButton",2),o([us('[part~="pagination-item"]')],j.prototype,"paginationItems",2),o([l({type:String,reflect:!0})],j.prototype,"variant",2),o([l({type:Boolean,reflect:!0})],j.prototype,"inverted",2),o([l({type:Boolean,reflect:!0})],j.prototype,"loop",2),o([l({type:Boolean,reflect:!0})],j.prototype,"autoplay",2),o([l({type:Number,attribute:"slides-per-page"})],j.prototype,"slidesPerPage",2),o([l({type:Number,attribute:"slides-per-move"})],j.prototype,"slidesPerMove",2),o([g("slot:not([name])")],j.prototype,"defaultSlot",2),o([g(".carousel__slides")],j.prototype,"scrollContainer",2),o([g(".carousel__pagination")],j.prototype,"paginationContainer",2),o([C()],j.prototype,"activeSlide",2),o([C()],j.prototype,"currentPage",2),o([C()],j.prototype,"pausedAutoplay",2),o([w("pausedAutoplay")],j.prototype,"handlePausedAutoplay",1),o([w("loop",{waitUntilFirstUpdate:!0}),w("slidesPerPage",{waitUntilFirstUpdate:!0})],j.prototype,"initializeSlides",1),o([w("activeSlide")],j.prototype,"handleSlideChange",1),o([w("slidesPerMove")],j.prototype,"handleSlidesPerMoveChange",1),o([w("autoplay")],j.prototype,"handleAutoplayChange",1),j=o([y("sd-carousel")],j);var Mt=(s="value")=>(i,t)=>{let e=i.constructor,r=e.prototype.attributeChangedCallback;e.prototype.attributeChangedCallback=function(a,n,d){var f;let h=e.getPropertyOptions(s),u=typeof h.attribute=="string"?h.attribute:s;if(a===u){let b=h.converter||ve,x=(typeof b=="function"?b:(f=b==null?void 0:b.fromAttribute)!=null?f:ve.fromAttribute)(d,h.type);this[s]!==x&&(this[t]=x)}r.call(this,a,n,d)}};var{I:o0}=es;var Vi=s=>s.strings===void 0;var Sn={},Os=(s,i=Sn)=>s._$AH=i;var le=oe(class extends we{constructor(s){if(super(s),s.type!==Lt.PROPERTY&&s.type!==Lt.ATTRIBUTE&&s.type!==Lt.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!Vi(s))throw Error("`live` bindings can only contain a single expression")}render(s){return s}update(s,[i]){if(i===bt||i===Y)return i;let t=s.element,e=s.name;if(s.type===Lt.PROPERTY){if(i===t[e])return bt}else if(s.type===Lt.BOOLEAN_ATTRIBUTE){if(!!i===t.hasAttribute(e))return bt}else if(s.type===Lt.ATTRIBUTE&&t.getAttribute(e)===i+"")return bt;return Os(s),i}});var Q=class extends m{constructor(){super(...arguments);this.formControlController=new dt(this,{value:t=>t.checked?t.value||"on":void 0,defaultValue:t=>t.defaultChecked,setValue:(t,e)=>t.checked=e});this.title="";this.name="";this.size="lg";this.disabled=!1;this.visuallyDisabled=!1;this.checked=!1;this.indeterminate=!1;this.defaultChecked=!1;this.form="";this.required=!1;this.showInvalidStyle=!1}get validity(){return this.input.validity}firstUpdated(){this.formControlController.updateValidity()}handleClick(t){if(this.visuallyDisabled){t.preventDefault(),t.stopPropagation();return}this.checked=!this.checked,this.indeterminate=!1,this.emit("sd-change")}handleBlur(){this.emit("sd-blur")}handleInput(){this.emit("sd-input")}handleInvalid(t){this.formControlController.setValidity(!1),this.formControlController.emitInvalidEvent(t),this.invalidMessage.textContent=t.target.validationMessage}handleFocus(){this.emit("sd-focus")}handleDisabledChange(){let t=this.disabled||this.visuallyDisabled;this.setAttribute("aria-disabled",t?"true":"false"),this.formControlController.setValidity(t)}handleStateChange(){this.input.checked=this.checked,this.input.indeterminate=this.indeterminate,this.formControlController.updateValidity()}click(){this.input.click()}focus(t){this.input.focus(t)}blur(){this.input.blur()}checkValidity(){return this.input.checkValidity()}getForm(){return this.formControlController.getForm()}reportValidity(){return this.formControlController.fakeUserInteraction(),this.input.reportValidity()}setCustomValidity(t){this.input.setCustomValidity(t),this.formControlController.updateValidity()}render(){let t=this.disabled&&this.indeterminate?"disabledIndeterminate":this.disabled&&this.checked?"disabledChecked":this.disabled?"disabled":this.visuallyDisabled?"visuallyDisabled":this.showInvalidStyle&&this.indeterminate?"invalidIndeterminate":this.showInvalidStyle?"invalid":this.checked||this.indeterminate?"filled":"default";return p`<label part="base" class="${c("sd-checkbox group flex items-start text-base leading-normal text-black cursor-pointer",(this.disabled||this.visuallyDisabled)&&"hover:cursor-not-allowed",{sm:"text-sm",md:"text-base",lg:"text-base"}[this.size])}"><input class="peer absolute opacity-0 p-0 m-0 pointer-events-none" type="checkbox" title="${this.title}" name="${this.name}" value="${E(this.value)}" .indeterminate="${le(this.indeterminate)}" .checked="${le(this.checked)}" .disabled="${this.disabled}" .required="${this.required}" aria-checked="${this.indeterminate?"mixed":this.checked}" aria-describedby="invalid-message" aria-invalid="${this.showInvalidStyle}" aria-disabled="${this.disabled||this.visuallyDisabled?"true":"false"}" @click="${this.handleClick}" @input="${this.handleInput}" @invalid="${this.handleInvalid}" @blur="${this.handleBlur}" @focus="${this.handleFocus}"> <span id="control" part="control ${this.checked?" control--checked":"control--unchecked"} ${this.indeterminate?" control--indeterminate":""}" class="${c("relative flex flex-shrink-0 items-center justify-center border rounded-sm h-4 w-4",this.visuallyDisabled?"":"peer-focus-visible:outline peer-focus-visible:outline-2 peer-focus-visible:outline-offset-2 peer-focus-visible:outline-primary",{sm:"mt-[2px]",md:"mt-[3px]",lg:"mt-[3px]"}[this.size],{disabledIndeterminate:"border-neutral-500 bg-neutral-500",disabledChecked:"border-neutral-500 bg-neutral-500",disabled:"border-neutral-500",visuallyDisabled:"border-neutral-500",invalidIndeterminate:"border-error bg-error group-hover:bg-error-400",invalid:"border-error group-hover:bg-neutral-200",filled:"border-accent hover:border-accent-550 group-hover:border-accent-550 bg-accent group-hover:bg-accent-550",default:"border-neutral-800 hover:bg-neutral-200 group-hover:bg-neutral-200 bg-white"}[t])}">${this.checked?p`<sd-icon part="checked-icon" class="text-white w-3 h-3" library="system" name="status-check"></sd-icon>`:""} ${!this.checked&&this.indeterminate?p`<sd-icon part="indeterminate-icon" class="text-white w-3 h-3" library="system" name="status-minus"></sd-icon>`:""} </span><span part="label" id="label" class="${c("select-none inline-block ml-2",this.disabled||this.visuallyDisabled?"text-neutral-500":this.showInvalidStyle?"text-error":"text-black")}"><slot></slot></span></label> ${this.formControlController.renderInvalidMessage()}`}};Q.styles=[...m.styles,v`:host{display:block;width:-moz-max-content;width:max-content}:host(:focus-visible){outline-width:0}:host([required]) #label:after{content:" *"}`],o([g('input[type="checkbox"]')],Q.prototype,"input",2),o([g("#invalid-message")],Q.prototype,"invalidMessage",2),o([l()],Q.prototype,"title",2),o([l()],Q.prototype,"name",2),o([l()],Q.prototype,"value",2),o([l({reflect:!0})],Q.prototype,"size",2),o([l({type:Boolean,reflect:!0})],Q.prototype,"disabled",2),o([l({type:Boolean,reflect:!0,attribute:"visually-disabled"})],Q.prototype,"visuallyDisabled",2),o([l({type:Boolean,reflect:!0})],Q.prototype,"checked",2),o([l({type:Boolean,reflect:!0})],Q.prototype,"indeterminate",2),o([Mt("checked")],Q.prototype,"defaultChecked",2),o([l({reflect:!0})],Q.prototype,"form",2),o([l({type:Boolean,reflect:!0})],Q.prototype,"required",2),o([C()],Q.prototype,"showInvalidStyle",2),o([w(["disabled","visually-disabled"],{waitUntilFirstUpdate:!0})],Q.prototype,"handleDisabledChange",1),o([w(["checked","indeterminate"],{waitUntilFirstUpdate:!0})],Q.prototype,"handleStateChange",1),Q=o([y("sd-checkbox")],Q);var zt=class extends m{constructor(){super(...arguments);this.hasSlotController=new D(this,"label","help-text");this.size="lg";this.orientation="vertical";this.label="";this.helpText=""}getAllCheckboxes(){return[...this.querySelectorAll("sd-checkbox")]}async syncCheckboxElements(){let t=this.getAllCheckboxes();await Promise.all(t.map(async e=>{await e.updateComplete,e.size=this.size}))}syncCheckboxes(){customElements.get("sd-checkbox")?this.syncCheckboxElements():customElements.whenDefined("sd-checkbox").then(()=>this.syncCheckboxes())}handleSizeChange(){this.syncCheckboxes()}handleInvalid(){this.syncCheckboxes()}render(){let t=this.hasSlotController.test("label"),e=this.label?!0:t,r=this.hasSlotController.test("help-text"),a=this.helpText?!0:r,n=p`<slot @slotchange="${this.syncCheckboxes}"></slot>`,d=this.hasSlotController.test("tooltip");return p`<fieldset part="form-control" class="${c("border-0 p-0 m-0",{sm:"text-sm",md:"text-base",lg:"text-base"}[this.size])}" role="group" aria-labelledby="label">${e||d?p`<div class="flex items-center gap-1 mb-2"><label part="form-control-label" id="label" class="${c("p-0 font-bold leading-normal text-black",e?"flex":"hidden")}" aria-hidden="${e?"false":"true"}"><slot name="label">${this.label}</slot></label> ${d?p`<slot name="tooltip"></slot>`:""}</div>`:null}<div part="form-control-input" class="${c({vertical:"flex flex-col",horizontal:"flex flex-row"}[this.orientation])}">${n}</div></fieldset><slot name="help-text" part="form-control-help-text" id="help-text" class="${c("text-sm text-neutral-700 mt-2",a?"block":"hidden")}" aria-hidden="${!a}">${this.helpText}</slot>`}};zt.styles=[...m.styles,v`:host{display:block}:host([orientation=vertical]) ::slotted(sd-checkbox){display:flex;margin-bottom:var(--sd-spacing-2,.5rem)}:host([orientation=vertical]) ::slotted(sd-checkbox:last-of-type){margin-bottom:var(--sd-spacing-0,0)}:host([orientation=horizontal]) ::slotted(sd-checkbox){margin-right:var(--sd-spacing-6,1.5rem)}:host([orientation=horizontal]) ::slotted(sd-checkbox:last-of-type){margin-right:var(--sd-spacing-0,0)}:host([orientation=horizontal]):host([size=sm]) ::slotted(sd-checkbox){margin-right:var(--sd-spacing-4,1rem)}:host([orientation=horizontal]):host([size=sm]) ::slotted(sd-checkbox:last-of-type){margin-right:var(--sd-spacing-0,0)}`],o([l({reflect:!0})],zt.prototype,"size",2),o([l({reflect:!0})],zt.prototype,"orientation",2),o([l()],zt.prototype,"label",2),o([l({attribute:"help-text"})],zt.prototype,"helpText",2),o([w("size",{waitUntilFirstUpdate:!0})],zt.prototype,"handleSizeChange",1),o([w("invalid",{waitUntilFirstUpdate:!0})],zt.prototype,"handleInvalid",1),zt=o([y("sd-checkbox-group")],zt);var Ms=s=>s;var Er=s=>Array.from(s.assignedElements({flatten:!0})),Hn=s=>s.tagName.toLocaleLowerCase()==="sd-option"?s:Array.from(s.querySelectorAll(":scope > sd-option")),In=s=>s.tagName.toLocaleLowerCase()==="sd-optgroup",Ds=s=>s.map(Hn),_s=s=>s.filter(In),Ri=s=>s.normalize("NFD").replace(/[\u0300-\u036f]/g,"").toLowerCase();function Ss(s,i){return{top:Math.round(s.getBoundingClientRect().top-i.getBoundingClientRect().top),left:Math.round(s.getBoundingClientRect().left-i.getBoundingClientRect().left)}}var Cr=new Set;function Pn(){let s=document.documentElement.clientWidth;return Math.abs(window.innerWidth-s)}function De(s){if(Cr.add(s),!document.body.classList.contains("sd-scroll-lock")){let i=Pn();document.body.classList.add("sd-scroll-lock"),document.body.style.setProperty("--sd-scroll-lock-size",`${i}px`)}}function _e(s){Cr.delete(s),Cr.size===0&&(document.body.classList.remove("sd-scroll-lock"),document.body.style.removeProperty("--sd-scrollbar-width"))}function Rt(s,i,t="vertical",e="smooth"){let r=Ss(s,i),a=r.top+i.scrollTop,n=r.left+i.scrollLeft,d=i.scrollLeft,h=i.scrollLeft+i.offsetWidth,u=i.scrollTop,f=i.scrollTop+i.offsetHeight;(t==="horizontal"||t==="both")&&(n<d?i.scrollTo({left:n,behavior:e}):n+s.clientWidth>h&&i.scrollTo({left:n-i.offsetWidth+s.clientWidth,behavior:e})),(t==="vertical"||t==="both")&&(a<u?i.scrollTo({top:a,behavior:e}):a+s.clientHeight>f&&i.scrollTo({top:a-i.offsetHeight+s.clientHeight,behavior:e}))}var Jt=Math.min,yt=Math.max,pi=Math.round,ui=Math.floor,Ut=s=>({x:s,y:s}),Fn={left:"right",right:"left",bottom:"top",top:"bottom"},Bn={start:"end",end:"start"};function Ni(s,i,t){return yt(s,Jt(i,t))}function Se(s,i){return typeof s=="function"?s(i):s}function de(s){return s.split("-")[0]}function He(s){return s.split("-")[1]}function $r(s){return s==="x"?"y":"x"}function qi(s){return s==="y"?"height":"width"}function Ee(s){return["top","bottom"].includes(de(s))?"y":"x"}function Ki(s){return $r(Ee(s))}function Hs(s,i,t){t===void 0&&(t=!1);let e=He(s),r=Ki(s),a=qi(r),n=r==="x"?e===(t?"end":"start")?"right":"left":e==="start"?"bottom":"top";return i.reference[a]>i.floating[a]&&(n=hi(n)),[n,hi(n)]}function Is(s){let i=hi(s);return[Ui(s),i,Ui(i)]}function Ui(s){return s.replace(/start|end/g,i=>Bn[i])}function Vn(s,i,t){let e=["left","right"],r=["right","left"],a=["top","bottom"],n=["bottom","top"];switch(s){case"top":case"bottom":return t?i?r:e:i?e:r;case"left":case"right":return i?a:n;default:return[]}}function Ps(s,i,t,e){let r=He(s),a=Vn(de(s),t==="start",e);return r&&(a=a.map(n=>n+"-"+r),i&&(a=a.concat(a.map(Ui)))),a}function hi(s){return s.replace(/left|right|bottom|top/g,i=>Fn[i])}function Rn(s){return O({top:0,right:0,bottom:0,left:0},s)}function Tr(s){return typeof s!="number"?Rn(s):{top:s,right:s,bottom:s,left:s}}function Ie(s){let{x:i,y:t,width:e,height:r}=s;return{width:e,height:r,top:t,left:i,right:i+e,bottom:t+r,x:i,y:t}}function Fs(s,i,t){let{reference:e,floating:r}=s,a=Ee(i),n=Ki(i),d=qi(n),h=de(i),u=a==="y",f=e.x+e.width/2-r.width/2,b=e.y+e.height/2-r.height/2,k=e[d]/2-r[d]/2,x;switch(h){case"top":x={x:f,y:e.y-r.height};break;case"bottom":x={x:f,y:e.y+e.height};break;case"right":x={x:e.x+e.width,y:b};break;case"left":x={x:e.x-r.width,y:b};break;default:x={x:e.x,y:e.y}}switch(He(i)){case"start":x[n]-=k*(t&&u?-1:1);break;case"end":x[n]+=k*(t&&u?-1:1);break}return x}var Bs=async(s,i,t)=>{let{placement:e="bottom",strategy:r="absolute",middleware:a=[],platform:n}=t,d=a.filter(Boolean),h=await(n.isRTL==null?void 0:n.isRTL(i)),u=await n.getElementRects({reference:s,floating:i,strategy:r}),{x:f,y:b}=Fs(u,e,h),k=e,x={},$=0;for(let z=0;z<d.length;z++){let{name:I,fn:_}=d[z],{x:N,y:q,data:J,reset:G}=await _({x:f,y:b,initialPlacement:e,placement:k,strategy:r,middlewareData:x,rects:u,platform:n,elements:{reference:s,floating:i}});f=N!=null?N:f,b=q!=null?q:b,x=it(O({},x),{[I]:O(O({},x[I]),J)}),G&&$<=50&&($++,typeof G=="object"&&(G.placement&&(k=G.placement),G.rects&&(u=G.rects===!0?await n.getElementRects({reference:s,floating:i,strategy:r}):G.rects),{x:f,y:b}=Fs(u,k,h)),z=-1)}return{x:f,y:b,placement:k,strategy:r,middlewareData:x}};async function ji(s,i){var t;i===void 0&&(i={});let{x:e,y:r,platform:a,rects:n,elements:d,strategy:h}=s,{boundary:u="clippingAncestors",rootBoundary:f="viewport",elementContext:b="floating",altBoundary:k=!1,padding:x=0}=Se(i,s),$=Tr(x),I=d[k?b==="floating"?"reference":"floating":b],_=Ie(await a.getClippingRect({element:(t=await(a.isElement==null?void 0:a.isElement(I)))==null||t?I:I.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(d.floating)),boundary:u,rootBoundary:f,strategy:h})),N=b==="floating"?{x:e,y:r,width:n.floating.width,height:n.floating.height}:n.reference,q=await(a.getOffsetParent==null?void 0:a.getOffsetParent(d.floating)),J=await(a.isElement==null?void 0:a.isElement(q))?await(a.getScale==null?void 0:a.getScale(q))||{x:1,y:1}:{x:1,y:1},G=Ie(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:d,rect:N,offsetParent:q,strategy:h}):N);return{top:(_.top-G.top+$.top)/J.y,bottom:(G.bottom-_.bottom+$.bottom)/J.y,left:(_.left-G.left+$.left)/J.x,right:(G.right-_.right+$.right)/J.x}}var Vs=s=>({name:"arrow",options:s,async fn(i){let{x:t,y:e,placement:r,rects:a,platform:n,elements:d,middlewareData:h}=i,{element:u,padding:f=0}=Se(s,i)||{};if(u==null)return{};let b=Tr(f),k={x:t,y:e},x=Ki(r),$=qi(x),z=await n.getDimensions(u),I=x==="y",_=I?"top":"left",N=I?"bottom":"right",q=I?"clientHeight":"clientWidth",J=a.reference[$]+a.reference[x]-k[x]-a.floating[$],G=k[x]-a.reference[x],Pt=await(n.getOffsetParent==null?void 0:n.getOffsetParent(u)),ft=Pt?Pt[q]:0;(!ft||!await(n.isElement==null?void 0:n.isElement(Pt)))&&(ft=d.floating[q]||a.floating[$]);let ee=J/2-G/2,Zt=ft/2-z[$]/2-1,Ft=Jt(b[_],Zt),ue=Jt(b[N],Zt),Xt=Ft,me=ft-z[$]-ue,Tt=ft/2-z[$]/2+ee,Bt=Ni(Xt,Tt,me),Re=!h.arrow&&He(r)!=null&&Tt!==Bt&&a.reference[$]/2-(Tt<Xt?Ft:ue)-z[$]/2<0,ie=Re?Tt<Xt?Tt-Xt:Tt-me:0;return{[x]:k[x]+ie,data:O({[x]:Bt,centerOffset:Tt-Bt-ie},Re&&{alignmentOffset:ie}),reset:Re}}});var Rs=function(s){return s===void 0&&(s={}),{name:"flip",options:s,async fn(i){var t,e;let{placement:r,middlewareData:a,rects:n,initialPlacement:d,platform:h,elements:u}=i,Tt=Se(s,i),{mainAxis:f=!0,crossAxis:b=!0,fallbackPlacements:k,fallbackStrategy:x="bestFit",fallbackAxisSideDirection:$="none",flipAlignment:z=!0}=Tt,I=wi(Tt,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((t=a.arrow)!=null&&t.alignmentOffset)return{};let _=de(r),N=Ee(d),q=de(d)===d,J=await(h.isRTL==null?void 0:h.isRTL(u.floating)),G=k||(q||!z?[hi(d)]:Is(d)),Pt=$!=="none";!k&&Pt&&G.push(...Ps(d,z,$,J));let ft=[d,...G],ee=await ji(i,I),Zt=[],Ft=((e=a.flip)==null?void 0:e.overflows)||[];if(f&&Zt.push(ee[_]),b){let Bt=Hs(r,n,J);Zt.push(ee[Bt[0]],ee[Bt[1]])}if(Ft=[...Ft,{placement:r,overflows:Zt}],!Zt.every(Bt=>Bt<=0)){var ue,Xt;let Bt=(((ue=a.flip)==null?void 0:ue.index)||0)+1,Re=ft[Bt];if(Re)return{data:{index:Bt,overflows:Ft},reset:{placement:Re}};let ie=(Xt=Ft.filter(Ue=>Ue.overflows[0]<=0).sort((Ue,fe)=>Ue.overflows[1]-fe.overflows[1])[0])==null?void 0:Xt.placement;if(!ie)switch(x){case"bestFit":{var me;let Ue=(me=Ft.filter(fe=>{if(Pt){let be=Ee(fe.placement);return be===N||be==="y"}return!0}).map(fe=>[fe.placement,fe.overflows.filter(be=>be>0).reduce((be,bo)=>be+bo,0)]).sort((fe,be)=>fe[1]-be[1])[0])==null?void 0:me[0];Ue&&(ie=Ue);break}case"initialPlacement":ie=d;break}if(r!==ie)return{reset:{placement:ie}}}return{}}}};async function Un(s,i){let{placement:t,platform:e,elements:r}=s,a=await(e.isRTL==null?void 0:e.isRTL(r.floating)),n=de(t),d=He(t),h=Ee(t)==="y",u=["left","top"].includes(n)?-1:1,f=a&&h?-1:1,b=Se(i,s),{mainAxis:k,crossAxis:x,alignmentAxis:$}=typeof b=="number"?{mainAxis:b,crossAxis:0,alignmentAxis:null}:{mainAxis:b.mainAxis||0,crossAxis:b.crossAxis||0,alignmentAxis:b.alignmentAxis};return d&&typeof $=="number"&&(x=d==="end"?$*-1:$),h?{x:x*f,y:k*u}:{x:k*u,y:x*f}}var Us=function(s){return s===void 0&&(s=0),{name:"offset",options:s,async fn(i){var t,e;let{x:r,y:a,placement:n,middlewareData:d}=i,h=await Un(i,s);return n===((t=d.offset)==null?void 0:t.placement)&&(e=d.arrow)!=null&&e.alignmentOffset?{}:{x:r+h.x,y:a+h.y,data:it(O({},h),{placement:n})}}}},Ns=function(s){return s===void 0&&(s={}),{name:"shift",options:s,async fn(i){let{x:t,y:e,placement:r}=i,I=Se(s,i),{mainAxis:a=!0,crossAxis:n=!1,limiter:d={fn:_=>{let{x:N,y:q}=_;return{x:N,y:q}}}}=I,h=wi(I,["mainAxis","crossAxis","limiter"]),u={x:t,y:e},f=await ji(i,h),b=Ee(de(r)),k=$r(b),x=u[k],$=u[b];if(a){let _=k==="y"?"top":"left",N=k==="y"?"bottom":"right",q=x+f[_],J=x-f[N];x=Ni(q,x,J)}if(n){let _=b==="y"?"top":"left",N=b==="y"?"bottom":"right",q=$+f[_],J=$-f[N];$=Ni(q,$,J)}let z=d.fn(it(O({},i),{[k]:x,[b]:$}));return it(O({},z),{data:{x:z.x-t,y:z.y-e,enabled:{[k]:a,[b]:n}}})}}};var qs=function(s){return s===void 0&&(s={}),{name:"size",options:s,async fn(i){var t,e;let{placement:r,rects:a,platform:n,elements:d}=i,Ft=Se(s,i),{apply:h=()=>{}}=Ft,u=wi(Ft,["apply"]),f=await ji(i,u),b=de(r),k=He(r),x=Ee(r)==="y",{width:$,height:z}=a.floating,I,_;b==="top"||b==="bottom"?(I=b,_=k===(await(n.isRTL==null?void 0:n.isRTL(d.floating))?"start":"end")?"left":"right"):(_=b,I=k==="end"?"top":"bottom");let N=z-f.top-f.bottom,q=$-f.left-f.right,J=Jt(z-f[I],N),G=Jt($-f[_],q),Pt=!i.middlewareData.shift,ft=J,ee=G;if((t=i.middlewareData.shift)!=null&&t.enabled.x&&(ee=q),(e=i.middlewareData.shift)!=null&&e.enabled.y&&(ft=N),Pt&&!k){let ue=yt(f.left,0),Xt=yt(f.right,0),me=yt(f.top,0),Tt=yt(f.bottom,0);x?ee=$-2*(ue!==0||Xt!==0?ue+Xt:yt(f.left,f.right)):ft=z-2*(me!==0||Tt!==0?me+Tt:yt(f.top,f.bottom))}await h(it(O({},i),{availableWidth:ee,availableHeight:ft}));let Zt=await n.getDimensions(d.floating);return $!==Zt.width||z!==Zt.height?{reset:{rects:!0}}:{}}}};function Yi(){return typeof window!="undefined"}function Pe(s){return js(s)?(s.nodeName||"").toLowerCase():"#document"}function kt(s){var i;return(s==null||(i=s.ownerDocument)==null?void 0:i.defaultView)||window}function Nt(s){var i;return(i=(js(s)?s.ownerDocument:s.document)||window.document)==null?void 0:i.documentElement}function js(s){return Yi()?s instanceof Node||s instanceof kt(s).Node:!1}function Dt(s){return Yi()?s instanceof Element||s instanceof kt(s).Element:!1}function qt(s){return Yi()?s instanceof HTMLElement||s instanceof kt(s).HTMLElement:!1}function Ks(s){return!Yi()||typeof ShadowRoot=="undefined"?!1:s instanceof ShadowRoot||s instanceof kt(s).ShadowRoot}function Xe(s){let{overflow:i,overflowX:t,overflowY:e,display:r}=_t(s);return/auto|scroll|overlay|hidden|clip/.test(i+e+t)&&!["inline","contents"].includes(r)}function Ys(s){return["table","td","th"].includes(Pe(s))}function mi(s){return[":popover-open",":modal"].some(i=>{try{return s.matches(i)}catch(t){return!1}})}function Zi(s){let i=Xi(),t=Dt(s)?_t(s):s;return["transform","translate","scale","rotate","perspective"].some(e=>t[e]?t[e]!=="none":!1)||(t.containerType?t.containerType!=="normal":!1)||!i&&(t.backdropFilter?t.backdropFilter!=="none":!1)||!i&&(t.filter?t.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(e=>(t.willChange||"").includes(e))||["paint","layout","strict","content"].some(e=>(t.contain||"").includes(e))}function Zs(s){let i=ce(s);for(;qt(i)&&!Fe(i);){if(Zi(i))return i;if(mi(i))return null;i=ce(i)}return null}function Xi(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Fe(s){return["html","body","#document"].includes(Pe(s))}function _t(s){return kt(s).getComputedStyle(s)}function fi(s){return Dt(s)?{scrollLeft:s.scrollLeft,scrollTop:s.scrollTop}:{scrollLeft:s.scrollX,scrollTop:s.scrollY}}function ce(s){if(Pe(s)==="html")return s;let i=s.assignedSlot||s.parentNode||Ks(s)&&s.host||Nt(s);return Ks(i)?i.host:i}function Xs(s){let i=ce(s);return Fe(i)?s.ownerDocument?s.ownerDocument.body:s.body:qt(i)&&Xe(i)?i:Xs(i)}function Ze(s,i,t){var e;i===void 0&&(i=[]),t===void 0&&(t=!0);let r=Xs(s),a=r===((e=s.ownerDocument)==null?void 0:e.body),n=kt(r);if(a){let d=Wi(n);return i.concat(n,n.visualViewport||[],Xe(r)?r:[],d&&t?Ze(d):[])}return i.concat(r,Ze(r,[],t))}function Wi(s){return s.parent&&Object.getPrototypeOf(s.parent)?s.frameElement:null}function Js(s){let i=_t(s),t=parseFloat(i.width)||0,e=parseFloat(i.height)||0,r=qt(s),a=r?s.offsetWidth:t,n=r?s.offsetHeight:e,d=pi(t)!==a||pi(e)!==n;return d&&(t=a,e=n),{width:t,height:e,$:d}}function zr(s){return Dt(s)?s:s.contextElement}function We(s){let i=zr(s);if(!qt(i))return Ut(1);let t=i.getBoundingClientRect(),{width:e,height:r,$:a}=Js(i),n=(a?pi(t.width):t.width)/e,d=(a?pi(t.height):t.height)/r;return(!n||!Number.isFinite(n))&&(n=1),(!d||!Number.isFinite(d))&&(d=1),{x:n,y:d}}var Nn=Ut(0);function Gs(s){let i=kt(s);return!Xi()||!i.visualViewport?Nn:{x:i.visualViewport.offsetLeft,y:i.visualViewport.offsetTop}}function qn(s,i,t){return i===void 0&&(i=!1),!t||i&&t!==kt(s)?!1:i}function Be(s,i,t,e){i===void 0&&(i=!1),t===void 0&&(t=!1);let r=s.getBoundingClientRect(),a=zr(s),n=Ut(1);i&&(e?Dt(e)&&(n=We(e)):n=We(s));let d=qn(a,t,e)?Gs(a):Ut(0),h=(r.left+d.x)/n.x,u=(r.top+d.y)/n.y,f=r.width/n.x,b=r.height/n.y;if(a){let k=kt(a),x=e&&Dt(e)?kt(e):e,$=k,z=Wi($);for(;z&&e&&x!==$;){let I=We(z),_=z.getBoundingClientRect(),N=_t(z),q=_.left+(z.clientLeft+parseFloat(N.paddingLeft))*I.x,J=_.top+(z.clientTop+parseFloat(N.paddingTop))*I.y;h*=I.x,u*=I.y,f*=I.x,b*=I.y,h+=q,u+=J,$=kt(z),z=Wi($)}}return Ie({width:f,height:b,x:h,y:u})}function Ar(s,i){let t=fi(s).scrollLeft;return i?i.left+t:Be(Nt(s)).left+t}function to(s,i,t){t===void 0&&(t=!1);let e=s.getBoundingClientRect(),r=e.left+i.scrollLeft-(t?0:Ar(s,e)),a=e.top+i.scrollTop;return{x:r,y:a}}function Kn(s){let{elements:i,rect:t,offsetParent:e,strategy:r}=s,a=r==="fixed",n=Nt(e),d=i?mi(i.floating):!1;if(e===n||d&&a)return t;let h={scrollLeft:0,scrollTop:0},u=Ut(1),f=Ut(0),b=qt(e);if((b||!b&&!a)&&((Pe(e)!=="body"||Xe(n))&&(h=fi(e)),qt(e))){let x=Be(e);u=We(e),f.x=x.x+e.clientLeft,f.y=x.y+e.clientTop}let k=n&&!b&&!a?to(n,h,!0):Ut(0);return{width:t.width*u.x,height:t.height*u.y,x:t.x*u.x-h.scrollLeft*u.x+f.x+k.x,y:t.y*u.y-h.scrollTop*u.y+f.y+k.y}}function jn(s){return Array.from(s.getClientRects())}function Yn(s){let i=Nt(s),t=fi(s),e=s.ownerDocument.body,r=yt(i.scrollWidth,i.clientWidth,e.scrollWidth,e.clientWidth),a=yt(i.scrollHeight,i.clientHeight,e.scrollHeight,e.clientHeight),n=-t.scrollLeft+Ar(s),d=-t.scrollTop;return _t(e).direction==="rtl"&&(n+=yt(i.clientWidth,e.clientWidth)-r),{width:r,height:a,x:n,y:d}}function Zn(s,i){let t=kt(s),e=Nt(s),r=t.visualViewport,a=e.clientWidth,n=e.clientHeight,d=0,h=0;if(r){a=r.width,n=r.height;let u=Xi();(!u||u&&i==="fixed")&&(d=r.offsetLeft,h=r.offsetTop)}return{width:a,height:n,x:d,y:h}}function Xn(s,i){let t=Be(s,!0,i==="fixed"),e=t.top+s.clientTop,r=t.left+s.clientLeft,a=qt(s)?We(s):Ut(1),n=s.clientWidth*a.x,d=s.clientHeight*a.y,h=r*a.x,u=e*a.y;return{width:n,height:d,x:h,y:u}}function Ws(s,i,t){let e;if(i==="viewport")e=Zn(s,t);else if(i==="document")e=Yn(Nt(s));else if(Dt(i))e=Xn(i,t);else{let r=Gs(s);e={x:i.x-r.x,y:i.y-r.y,width:i.width,height:i.height}}return Ie(e)}function eo(s,i){let t=ce(s);return t===i||!Dt(t)||Fe(t)?!1:_t(t).position==="fixed"||eo(t,i)}function Wn(s,i){let t=i.get(s);if(t)return t;let e=Ze(s,[],!1).filter(d=>Dt(d)&&Pe(d)!=="body"),r=null,a=_t(s).position==="fixed",n=a?ce(s):s;for(;Dt(n)&&!Fe(n);){let d=_t(n),h=Zi(n);!h&&d.position==="fixed"&&(r=null),(a?!h&&!r:!h&&d.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||Xe(n)&&!h&&eo(s,n))?e=e.filter(f=>f!==n):r=d,n=ce(n)}return i.set(s,e),e}function Qn(s){let{element:i,boundary:t,rootBoundary:e,strategy:r}=s,n=[...t==="clippingAncestors"?mi(i)?[]:Wn(i,this._c):[].concat(t),e],d=n[0],h=n.reduce((u,f)=>{let b=Ws(i,f,r);return u.top=yt(b.top,u.top),u.right=Jt(b.right,u.right),u.bottom=Jt(b.bottom,u.bottom),u.left=yt(b.left,u.left),u},Ws(i,d,r));return{width:h.right-h.left,height:h.bottom-h.top,x:h.left,y:h.top}}function Jn(s){let{width:i,height:t}=Js(s);return{width:i,height:t}}function Gn(s,i,t){let e=qt(i),r=Nt(i),a=t==="fixed",n=Be(s,!0,a,i),d={scrollLeft:0,scrollTop:0},h=Ut(0);if(e||!e&&!a)if((Pe(i)!=="body"||Xe(r))&&(d=fi(i)),e){let k=Be(i,!0,a,i);h.x=k.x+i.clientLeft,h.y=k.y+i.clientTop}else r&&(h.x=Ar(r));let u=r&&!e&&!a?to(r,d):Ut(0),f=n.left+d.scrollLeft-h.x-u.x,b=n.top+d.scrollTop-h.y-u.y;return{x:f,y:b,width:n.width,height:n.height}}function Lr(s){return _t(s).position==="static"}function Qs(s,i){if(!qt(s)||_t(s).position==="fixed")return null;if(i)return i(s);let t=s.offsetParent;return Nt(s)===t&&(t=t.ownerDocument.body),t}function io(s,i){let t=kt(s);if(mi(s))return t;if(!qt(s)){let r=ce(s);for(;r&&!Fe(r);){if(Dt(r)&&!Lr(r))return r;r=ce(r)}return t}let e=Qs(s,i);for(;e&&Ys(e)&&Lr(e);)e=Qs(e,i);return e&&Fe(e)&&Lr(e)&&!Zi(e)?t:e||Zs(s)||t}var tl=async function(s){let i=this.getOffsetParent||io,t=this.getDimensions,e=await t(s.floating);return{reference:Gn(s.reference,await i(s.floating),s.strategy),floating:{x:0,y:0,width:e.width,height:e.height}}};function el(s){return _t(s).direction==="rtl"}var il={convertOffsetParentRelativeRectToViewportRelativeRect:Kn,getDocumentElement:Nt,getClippingRect:Qn,getOffsetParent:io,getElementRects:tl,getClientRects:jn,getDimensions:Jn,getScale:We,isElement:Dt,isRTL:el};function ro(s,i){return s.x===i.x&&s.y===i.y&&s.width===i.width&&s.height===i.height}function rl(s,i){let t=null,e,r=Nt(s);function a(){var d;clearTimeout(e),(d=t)==null||d.disconnect(),t=null}function n(d,h){d===void 0&&(d=!1),h===void 0&&(h=1),a();let u=s.getBoundingClientRect(),{left:f,top:b,width:k,height:x}=u;if(d||i(),!k||!x)return;let $=ui(b),z=ui(r.clientWidth-(f+k)),I=ui(r.clientHeight-(b+x)),_=ui(f),q={rootMargin:-$+"px "+-z+"px "+-I+"px "+-_+"px",threshold:yt(0,Jt(1,h))||1},J=!0;function G(Pt){let ft=Pt[0].intersectionRatio;if(ft!==h){if(!J)return n();ft?n(!1,ft):e=setTimeout(()=>{n(!1,1e-7)},1e3)}ft===1&&!ro(u,s.getBoundingClientRect())&&n(),J=!1}try{t=new IntersectionObserver(G,it(O({},q),{root:r.ownerDocument}))}catch(Pt){t=new IntersectionObserver(G,q)}t.observe(s)}return n(!0),a}function so(s,i,t,e){e===void 0&&(e={});let{ancestorScroll:r=!0,ancestorResize:a=!0,elementResize:n=typeof ResizeObserver=="function",layoutShift:d=typeof IntersectionObserver=="function",animationFrame:h=!1}=e,u=zr(s),f=r||a?[...u?Ze(u):[],...Ze(i)]:[];f.forEach(_=>{r&&_.addEventListener("scroll",t,{passive:!0}),a&&_.addEventListener("resize",t)});let b=u&&d?rl(u,t):null,k=-1,x=null;n&&(x=new ResizeObserver(_=>{let[N]=_;N&&N.target===u&&x&&(x.unobserve(i),cancelAnimationFrame(k),k=requestAnimationFrame(()=>{var q;(q=x)==null||q.observe(i)})),t()}),u&&!h&&x.observe(u),x.observe(i));let $,z=h?Be(s):null;h&&I();function I(){let _=Be(s);z&&!ro(z,_)&&t(),z=_,$=requestAnimationFrame(I)}return t(),()=>{var _;f.forEach(N=>{r&&N.removeEventListener("scroll",t),a&&N.removeEventListener("resize",t)}),b==null||b(),(_=x)==null||_.disconnect(),x=null,h&&cancelAnimationFrame($)}}var oo=Us;var ao=Ns,no=Rs,Or=qs;var lo=Vs;var co=(s,i,t)=>{let e=new Map,r=O({platform:il},t),a=it(O({},r.platform),{_c:e});return Bs(s,i,it(O({},r),{platform:a}))};var P=class extends m{constructor(){super(...arguments);this.active=!1;this.placement="top";this.strategy="absolute";this.distance=0;this.skidding=0;this.arrow=!1;this.arrowPlacement="anchor";this.arrowPadding=10;this.flip=!1;this.flipFallbackPlacements="";this.flipFallbackStrategy="best-fit";this.flipPadding=0;this.shift=!1;this.shiftPadding=0;this.autoSizePadding=0}async connectedCallback(){super.connectedCallback(),await this.updateComplete,this.start(),this.setupMutationObserver()}disconnectedCallback(){this.stop(),this.mutationObserver&&this.mutationObserver.disconnect()}async updated(t){super.updated(t),t.has("active")&&(this.active?this.start():this.stop()),t.has("anchor")&&this.handleAnchorChange(),this.active&&(await this.updateComplete,this.reposition())}setupMutationObserver(){this.mutationObserver=new MutationObserver(e=>this.handleCurrentPlacementChange(e));let t={attributes:!0};this.mutationObserver.observe(this,t)}handleCurrentPlacementChange(t){return t.forEach(e=>{if(e.attributeName==="data-current-placement"){let r=this.getAttribute("data-current-placement");this.emit("sd-current-placement",{detail:r})}})}async handleAnchorChange(){if(await this.stop(),this.anchor&&typeof this.anchor=="string"){let t=this.getRootNode();this.anchorEl=t.getElementById(this.anchor)}else this.anchor instanceof HTMLElement?this.anchorEl=this.anchor:this.anchorEl=this.querySelector('[slot="anchor"]');if(this.anchorEl instanceof HTMLSlotElement&&(this.anchorEl=this.anchorEl.assignedElements({flatten:!0})[0]),!this.anchorEl)throw new Error("Invalid anchor element: no anchor could be found using the anchor slot or the anchor attribute.");this.start()}start(){this.anchorEl&&(this.cleanup=so(this.anchorEl,this.popup,()=>{this.reposition()}))}async stop(){return new Promise(t=>{this.cleanup?(this.cleanup(),this.cleanup=void 0,this.removeAttribute("data-current-placement"),this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height"),requestAnimationFrame(()=>t())):t()})}reposition(){if(!this.active||!this.anchorEl)return;let t=[oo({mainAxis:this.distance,crossAxis:this.skidding})];this.sync?t.push(Or({apply:({rects:e})=>{let r=this.sync==="width"||this.sync==="both",a=this.sync==="height"||this.sync==="both";this.popup.style.width=r?`${e.reference.width}px`:"",this.popup.style.height=a?`${e.reference.height}px`:""}})):(this.popup.style.width="",this.popup.style.height=""),this.flip&&t.push(no({boundary:this.flipBoundary,fallbackPlacements:this.flipFallbackPlacements,fallbackStrategy:this.flipFallbackStrategy==="best-fit"?"bestFit":"initialPlacement",padding:this.flipPadding})),this.shift&&t.push(ao({boundary:this.shiftBoundary,padding:this.shiftPadding})),this.autoSize?t.push(Or({boundary:this.autoSizeBoundary,padding:this.autoSizePadding,apply:({availableWidth:e,availableHeight:r})=>{this.autoSize==="vertical"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-height",`${r}px`):this.style.removeProperty("--auto-size-available-height"),this.autoSize==="horizontal"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-width",`${e}px`):this.style.removeProperty("--auto-size-available-width")}})):(this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height")),this.arrow&&t.push(lo({element:this.arrowEl,padding:this.arrowPadding})),co(this.anchorEl,this.popup,{placement:this.placement,middleware:t,strategy:this.strategy}).then(({x:e,y:r,middlewareData:a,placement:n})=>{let d=getComputedStyle(this).direction==="rtl",h={top:"bottom",right:"left",bottom:"top",left:"right"}[n.split("-")[0]];if(this.setAttribute("data-current-placement",n),Object.assign(this.popup.style,{left:`${e}px`,top:`${r}px`}),this.arrow){let u=a.arrow.x,f=a.arrow.y,b="",k="",x="",$="";if(this.arrowPlacement==="start"){let z=typeof u=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";b=typeof f=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"",k=d?z:"",$=d?"":z}else if(this.arrowPlacement==="end"){let z=typeof u=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";k=d?"":z,$=d?z:"",x=typeof f=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:""}else this.arrowPlacement==="center"?($=typeof u=="number"?"calc(50% - var(--arrow-size-diagonal))":"",b=typeof f=="number"?"calc(50% - var(--arrow-size-diagonal))":""):($=typeof u=="number"?`${u}px`:"",b=typeof f=="number"?`${f}px`:"");Object.assign(this.arrowEl.style,{top:b,right:k,bottom:x,left:$,[h]:"calc(var(--arrow-size-diagonal) * -1)"})}}),this.emit("sd-reposition")}render(){return p`<slot name="anchor" @slotchange="${this.handleAnchorChange}"></slot><div part="popup" class="${c("isolate",this.strategy!=="fixed"?"absolute":"fixed",!this.active&&"hidden")}"><slot></slot>${this.arrow?p`<div part="arrow" class="absolute rotate-45 -z-10" role="presentation"></div>`:""}</div>`}};P.styles=[...m.styles,v`:host{--arrow-color:var(--sd-color-neutral-1000);--arrow-size:6px;--arrow-size-diagonal:calc(var(--arrow-size)*0.7071);--arrow-padding-offset:calc(var(--arrow-size-diagonal) - var(--arrow-size));display:contents}[part=popup]{max-height:var(--auto-size-available-height,none);max-width:var(--auto-size-available-width,none)}[part=arrow]{background:var(--arrow-color);height:calc(var(--arrow-size-diagonal)*2);width:calc(var(--arrow-size-diagonal)*2)}`],o([g('[part="popup"]')],P.prototype,"popup",2),o([g('[part="arrow"]')],P.prototype,"arrowEl",2),o([l()],P.prototype,"anchor",2),o([l({type:Boolean,reflect:!0})],P.prototype,"active",2),o([l({reflect:!0})],P.prototype,"placement",2),o([l({reflect:!0})],P.prototype,"strategy",2),o([l({type:Number})],P.prototype,"distance",2),o([l({type:Number})],P.prototype,"skidding",2),o([l({type:Boolean})],P.prototype,"arrow",2),o([l({attribute:"arrow-placement"})],P.prototype,"arrowPlacement",2),o([l({attribute:"arrow-padding",type:Number})],P.prototype,"arrowPadding",2),o([l({type:Boolean})],P.prototype,"flip",2),o([l({attribute:"flip-fallback-placements",converter:{fromAttribute:t=>t.split(" ").map(e=>e.trim()).filter(e=>e!==""),toAttribute:t=>t.join(" ")}})],P.prototype,"flipFallbackPlacements",2),o([l({attribute:"flip-fallback-strategy"})],P.prototype,"flipFallbackStrategy",2),o([l({type:Object})],P.prototype,"flipBoundary",2),o([l({attribute:"flip-padding",type:Number})],P.prototype,"flipPadding",2),o([l({type:Boolean})],P.prototype,"shift",2),o([l({type:Object})],P.prototype,"shiftBoundary",2),o([l({attribute:"shift-padding",type:Number})],P.prototype,"shiftPadding",2),o([l({attribute:"auto-size"})],P.prototype,"autoSize",2),o([l()],P.prototype,"sync",2),o([l({type:Object})],P.prototype,"autoSizeBoundary",2),o([l({attribute:"auto-size-padding",type:Number})],P.prototype,"autoSizePadding",2),P=o([y("sd-popup")],P);var st=class extends m{constructor(){super(...arguments);this.size="lg";this.selected=!1;this.toggleable=!1;this.removable=!1;this.disabled=!1;this.href=""}handleBlur(){this.emit("sd-blur")}handleFocus(){this.emit("sd-focus")}handleRemoveClick(){this.emit("sd-remove")}isLink(){return!!this.href}click(){this.tag.click()}focus(t){this.tag.focus(t)}blur(){this.tag.blur()}render(){let t=this.isLink(),e=t?X`a`:X`button`;return F`<${e} part="base" type="${E(t?void 0:"button")}" href="${E(t?this.href:void 0)}" rel="${E(t&&this.target?"noreferrer noopener":void 0)}" target="${E(t?this.target:void 0)}" download="${E(t?this.download:void 0)}" ?disabled="${E(t?void 0:this.disabled)}" aria-disabled="${this.disabled?"true":"false"}" aria-pressed="${E(this.toggleable?this.selected:void 0)}" tabindex="${this.disabled?"-1":"0"}" @blur="${this.handleBlur}" @focus="${this.handleFocus}" class="${c("inline-flex border box-border rounded-full items-center leading-none whitespace-nowrap focus-visible:focus-outline",{lg:"h-8 text-base gap-2",sm:"h-6 text-sm gap-1"}[this.size],{lg:this.removable?"pl-4 pr-3 py-2":"px-4 py-2",sm:this.removable?"pl-3 pr-2 py-2":"px-3 py-[5px]"}[this.size],this.selected?"bg-primary border-primary text-white hover:bg-primary-500 hover:border-primary-500 disabled:bg-neutral-500 disabled:border-neutral-500":"border-primary text-primary hover:border-primary-500 hover:bg-neutral-100 hover:text-primary-500 disabled:border-neutral-500 disabled:text-neutral-500",this.disabled&&!t&&"cursor-not-allowed")}"><slot part="content"></slot>${this.removable?F`<slot part="removable-indicator" name="removable-indicator" @click="${this.handleRemoveClick}" class="${c({lg:"text-base",sm:"text-[12px]"}[this.size])}"><sd-icon library="system" name="close" label="remove"></sd-icon></slot>`:""}</${e}>`}};st.styles=[...m.styles,v`:host{display:inline-block}`],o([g("a, button")],st.prototype,"tag",2),o([l({reflect:!0})],st.prototype,"size",2),o([l({type:Boolean,reflect:!0})],st.prototype,"selected",2),o([l({type:Boolean,reflect:!0})],st.prototype,"toggleable",2),o([l({type:Boolean,reflect:!0})],st.prototype,"removable",2),o([l({type:Boolean,reflect:!0})],st.prototype,"disabled",2),o([l()],st.prototype,"href",2),o([l()],st.prototype,"target",2),o([l()],st.prototype,"download",2),st=o([y("sd-tag")],st);var T=class extends m{constructor(){super(...arguments);this.formControlController=new dt(this,{assumeInteractionOn:["sd-blur","sd-input"]});this.hasSlotController=new D(this,"help-text","label");this.localize=new S(this);this.hasHover=!1;this.hasFocus=!1;this.displayInputValue="";this.selectedTextLabel="";this.selectedOptions=[];this.filteredOptions=[];this.allOptions=[];this.showValidStyle=!1;this.showInvalidStyle=!1;this.name="";this.value="";this.defaultValue="";this.size="lg";this.placeholder="";this.maxOptionsTagLabel="";this.disabled=!1;this.visuallyDisabled=!1;this.clearable=!1;this.open=!1;this.hoist=!1;this.label="";this.placement="bottom";this.helpText="";this.form="";this.required=!1;this.currentPlacement=this.placement;this.getOption=Ms;this.multiple=!1;this.useTags=!0;this.maxOptionsVisible=3;this.styleOnValid=!1;this.filter=(t,e)=>{let r=Ri(t.value),a=Ri(t.getTextLabel()),n=Ri(e);return r.includes(n)||a.includes(n)};this.getTag=t=>p`<sd-tag ?disabled="${this.disabled}" part="tag" exportparts="
112
112
  base:tag__base,
@@ -106,7 +106,7 @@
106
106
  disabled:text-neutral-500 disabled:border-neutral-500`,tertiary:this.inverted?`border-transparent ${this.visuallyDisabled?"text-neutral-600 hover:text-neutral-600 active:text-neutral-600":"text-white hover:text-primary-100 hover:bg-primary-500 active:text-primary-200 active:bg-primary-800"}
107
107
  disabled:text-neutral-600`:`border-transparent ${this.visuallyDisabled?"text-neutral-500 hover:text-neutral-500 active:text-neutral-500":"text-primary hover:text-primary-500 hover:bg-primary-100 active:text-primary-800 active:bg-primary-200"}
108
108
  disabled:text-neutral-500`,cta:`text-white ${this.visuallyDisabled?"bg-neutral-500 hover:bg-neutral-500 active:bg-neutral-500":"bg-accent-500 border-transparent hover:bg-accent-550 active:bg-accent-700"}
109
- ${this.inverted?"disabled:bg-neutral-600":"disabled:bg-neutral-500"} disabled:text-white`}[this.variant])}" ?disabled="${E(t?void 0:this.disabled)}" type="${E(t?void 0:this.type)}" title="${this.title}" name="${E(t?void 0:this.name)}" value="${E(t?void 0:this.value)}" href="${E(t?this.href:void 0)}" target="${E(t?this.target:void 0)}" download="${E(t?this.download:void 0)}" rel="${E(t&&this.target?"noreferrer noopener":void 0)}" role="${E(t?void 0:"button")}" aria-disabled="${this.disabled||this.visuallyDisabled?"true":"false"}" aria-labelledby="content" tabindex="${this.disabled?"-1":"0"}" @blur="${this.handleBlur}" @focus="${this.handleFocus}" @invalid="${this.isButton()?this.handleInvalid:null}" @click="${this.handleClick}"><slot name="icon-left" part="icon-left" class="${c("flex flex-auto items-center pointer-events-none",r["icon-only"]&&"hidden",this.loading&&"invisible",r["icon-left"]&&{sm:"mr-1",md:"mr-2",lg:"mr-2"}[this.size])}"></slot><slot part="label" id="content" class="${c(r["icon-only"]?"flex flex-auto items-center pointer-events-none":"inline-block",this.loading&&"invisible")}"></slot><slot name="icon-right" part="icon-right" class="${c("flex flex-auto items-center pointer-events-none",this.loading&&"invisible",r["icon-only"]&&"hidden",r["icon-right"]&&{sm:"ml-1",md:"ml-2",lg:"ml-2"}[this.size])}"></slot>${this.loading?F`<sd-spinner class="${c("absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2")}"></sd-spinner>`:""}</${e}>`}};B.styles=[...m.styles,v`:host{cursor:pointer;display:inline-block;position:relative;width:var(--sd-spacing-auto,auto)}sd-spinner{--indicator-color:currentColor;--track-color:var(--tw-varcolor-200)}::slotted(sd-badge){pointer-events:none;position:absolute;right:var(--sd-spacing-0,0);top:var(--sd-spacing-0,0);--tw-translate-x:50%!important;--tw-translate-y:-50%!important;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}::slotted(sd-icon),sd-spinner{font-size:calc(var(--tw-varspacing)/2)}`],o([g("a, button")],B.prototype,"button",2),o([Ke({selector:"sd-icon"})],B.prototype,"_iconsInDefaultSlot",2),o([C()],B.prototype,"invalid",2),o([l()],B.prototype,"title",2),o([l({reflect:!0})],B.prototype,"variant",2),o([l({type:Boolean,reflect:!0})],B.prototype,"inverted",2),o([l({reflect:!0})],B.prototype,"size",2),o([l({type:Boolean,reflect:!0})],B.prototype,"disabled",2),o([l({type:Boolean,reflect:!0,attribute:"visually-disabled"})],B.prototype,"visuallyDisabled",2),o([l({type:Boolean,reflect:!0})],B.prototype,"loading",2),o([l()],B.prototype,"type",2),o([l()],B.prototype,"name",2),o([l()],B.prototype,"value",2),o([l()],B.prototype,"href",2),o([l()],B.prototype,"target",2),o([l()],B.prototype,"download",2),o([l()],B.prototype,"form",2),o([l({attribute:"formaction"})],B.prototype,"formAction",2),o([l({attribute:"formenctype"})],B.prototype,"formEnctype",2),o([l({attribute:"formmethod"})],B.prototype,"formMethod",2),o([l({attribute:"formnovalidate",type:Boolean})],B.prototype,"formNoValidate",2),o([l({attribute:"formtarget"})],B.prototype,"formTarget",2),o([w("disabled",{waitUntilFirstUpdate:!0})],B.prototype,"handleDisabledChange",1),B=o([y("sd-button")],B);var Bi=class{constructor(i,t){this.timerId=0;this.activeInteractions=0;this.paused=!1;this.stopped=!0;this.pause=()=>{this.activeInteractions++||(this.paused=!0,this.host.requestUpdate())};this.resume=()=>{--this.activeInteractions||(this.paused=!1,this.host.requestUpdate())};i.addController(this),this.host=i,this.tickCallback=t}hostConnected(){this.host.addEventListener("mouseenter",this.pause),this.host.addEventListener("mouseleave",this.resume),this.host.addEventListener("focusin",this.pause),this.host.addEventListener("focusout",this.resume),this.host.addEventListener("touchstart",this.pause,{passive:!0}),this.host.addEventListener("touchend",this.resume)}hostDisconnected(){this.stop(),this.host.removeEventListener("mouseenter",this.pause),this.host.removeEventListener("mouseleave",this.resume),this.host.removeEventListener("focusin",this.pause),this.host.removeEventListener("focusout",this.resume),this.host.removeEventListener("touchstart",this.pause),this.host.removeEventListener("touchend",this.resume)}start(i){this.stop(),this.stopped=!1,this.timerId=window.setInterval(()=>{this.paused||this.tickCallback()},i)}stop(){clearInterval(this.timerId),this.stopped=!0,this.host.requestUpdate()}};function As(s,i,t){let e=r=>Object.is(r,-0)?0:r;return s<i?e(i):s>t?e(t):e(s)}function*Os(s,i){if(s!==void 0){let t=0;for(let e of s)yield i(e,t++)}}function*Ms(s,i,t=1){let e=i===void 0?0:s;i!=null||(i=s);for(let r=e;t>0?r<i:i<r;r+=t)yield r}var Ds=Symbol(),Vi=s=>(i,t,e)=>{let r=e.value;e.value=function(...a){clearTimeout(this[Ds]),this[Ds]=window.setTimeout(()=>{r.apply(this,a)},s)}};var hi=class{constructor(i){this.pointers=new Set;this.dragging=!1;this.scrolling=!1;this.mouseDragging=!1;this.handleScroll=()=>{this.scrolling||(this.scrolling=!0,this.host.requestUpdate()),this.handleScrollEnd()};this.handlePointerDown=i=>{if(i.pointerType==="touch")return;this.pointers.add(i.pointerId),this.mouseDragging&&!this.dragging&&i.button===0&&(i.preventDefault(),this.host.scrollContainer.addEventListener("pointermove",this.handlePointerMove))};this.handlePointerMove=i=>{let t=this.host.scrollContainer,e=!!i.movementX||!!i.movementY;!this.dragging&&e?(t.setPointerCapture(i.pointerId),this.handleDragStart()):t.hasPointerCapture(i.pointerId)&&this.handleDrag(i)};this.handlePointerUp=i=>{this.pointers.delete(i.pointerId),this.host.scrollContainer.releasePointerCapture(i.pointerId),this.pointers.size===0&&this.handleDragEnd()};this.handleTouchEnd=i=>{for(let t of i.changedTouches)this.pointers.delete(t.identifier)};this.handleTouchStart=i=>{for(let t of i.touches)this.pointers.add(t.identifier)};this.host=i,i.addController(this)}async hostConnected(){let i=this.host;await i.updateComplete;let t=i.scrollContainer;t.addEventListener("scroll",this.handleScroll,{passive:!0}),t.addEventListener("pointerdown",this.handlePointerDown),t.addEventListener("pointerup",this.handlePointerUp),t.addEventListener("pointercancel",this.handlePointerUp),t.addEventListener("touchstart",this.handleTouchStart,{passive:!0}),t.addEventListener("touchend",this.handleTouchEnd)}hostDisconnected(){let t=this.host.scrollContainer;t.removeEventListener("scroll",this.handleScroll),t.removeEventListener("pointerdown",this.handlePointerDown),t.removeEventListener("pointerup",this.handlePointerUp),t.removeEventListener("pointercancel",this.handlePointerUp),t.removeEventListener("touchstart",this.handleTouchStart),t.removeEventListener("touchend",this.handleTouchEnd)}handleScrollEnd(){this.pointers.size?this.handleScrollEnd():(this.scrolling=!1,this.host.scrollContainer.dispatchEvent(new CustomEvent("scrollend",{bubbles:!1,cancelable:!1})),this.host.requestUpdate())}handleDragStart(){let i=this.host;this.dragging=!0,i.scrollContainer.style.setProperty("scroll-snap-type","unset"),i.requestUpdate()}handleDrag(i){this.host.scrollContainer.scrollBy({left:-i.movementX,top:-i.movementY})}async handleDragEnd(){let i=this.host,t=i.scrollContainer;t.removeEventListener("pointermove",this.handlePointerMove),this.dragging=!1;let e=t.scrollLeft,r=t.scrollTop;t.style.removeProperty("scroll-snap-type");let a=t.scrollLeft,n=t.scrollTop;t.style.setProperty("scroll-snap-type","unset"),t.scrollTo({left:e,top:r,behavior:"auto"}),t.scrollTo({left:a,top:n,behavior:ni()?"auto":"smooth"}),this.scrolling&&await U(t,"scrollend"),t.style.removeProperty("scroll-snap-type"),i.requestUpdate()}};o([Vi(100)],hi.prototype,"handleScrollEnd",1);var ee=class extends m{static isCarouselItem(i){return i instanceof Element&&i.getAttribute("aria-roledescription")==="slide"}connectedCallback(){super.connectedCallback(),this.setAttribute("role","group")}render(){return p`<slot></slot>`}};ee.styles=[...m.styles,v`:host{align-items:center;aspect-ratio:var(--aspect-ratio);display:flex;flex-direction:column;height:100%;justify-content:center;scroll-snap-align:start;scroll-snap-stop:always;width:100%}::slotted(img){height:100%;-o-object-fit:cover;object-fit:cover;width:100%}`],ee=o([y("sd-carousel-item")],ee);var N=class extends m{constructor(){super(...arguments);this.variant="number";this.inverted=!1;this.loop=!1;this.autoplay=!1;this.slidesPerPage=1;this.slidesPerMove=1;this.activeSlide=0;this.currentPage=1;this.pausedAutoplay=!1;this.autoplayController=new Bi(this,()=>this.next());this.scrollController=new hi(this);this.slides=this.getElementsByTagName("sd-carousel-item");this.intersectionObserverEntries=new Map;this.localize=new _(this);this.userInteracted=!1;this.handleUserInteraction=()=>{this.userInteracted=!0};this.handleSlotChange=t=>{t.some(r=>[...r.addedNodes,...r.removedNodes].some(a=>ee.isCarouselItem(a)&&!a.hasAttribute("data-clone")))&&this.initializeSlides(),this.requestUpdate()};this.unblockAutoplay=(t,e)=>{t.detail&&e.blur()}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","region"),this.setAttribute("aria-label",this.localize.term("carousel")),["click","keydown"].forEach(e=>this.addEventListener(e,this.handleUserInteraction));let t=new IntersectionObserver(e=>{e.forEach(r=>{this.intersectionObserverEntries.set(r.target,r);let a=r.target;a.toggleAttribute("inert",!r.isIntersecting),a.classList.toggle("--in-view",r.isIntersecting),a.setAttribute("aria-hidden",r.isIntersecting?"false":"true")})},{root:this,threshold:.6});this.intersectionObserver=t,t.takeRecords().forEach(e=>{this.intersectionObserverEntries.set(e.target,e)})}disconnectedCallback(){super.disconnectedCallback(),this.intersectionObserver.disconnect(),this.mutationObserver.disconnect(),["click","keydown"].forEach(t=>this.removeEventListener(t,this.handleUserInteraction))}firstUpdated(){this.initializeSlides(),this.mutationObserver=new MutationObserver(this.handleSlotChange),this.mutationObserver.observe(this,{childList:!0,subtree:!1})}getPageCount(t,e,r){return Math.ceil((t-e)/r)+1>0?Math.ceil((t-e)/r)+1:1}getCurrentPage(t,e,r,a){return Math.ceil((t-r)/a)-Math.ceil((t-r-e)/a)+1}getSlides({excludeClones:t=!0}={}){return[...this.slides].filter(e=>!t||!e.hasAttribute("data-clone"))}handleKeyDown(t){if(["ArrowLeft","ArrowRight","ArrowUp","ArrowDown","Home","End"].includes(t.key)){let e=t.target,r=this.localize.dir()==="rtl",a=e.closest('[part~="pagination-item"]')!==null,n=t.key==="ArrowDown"||!r&&t.key==="ArrowRight"||r&&t.key==="ArrowLeft",d=t.key==="ArrowUp"||!r&&t.key==="ArrowLeft"||r&&t.key==="ArrowRight";t.preventDefault(),d&&this.previous(),n&&this.next(),t.key==="Home"&&this.goToSlide(0),t.key==="End"&&this.goToSlide(this.getSlides().length-1),a&&this.updateComplete.then(()=>{var u;let h=(u=this.shadowRoot)==null?void 0:u.querySelector('[part~="pagination-item--active"]');h&&h.focus()})}}handleScrollEnd(){let t=this.getSlides(),r=[...this.intersectionObserverEntries.values()].find(a=>a.isIntersecting);if(this.loop&&(r!=null&&r.target.hasAttribute("data-clone"))){let a=Number(r.target.getAttribute("data-clone"));this.goToSlide(a,"auto");return}r&&(this.activeSlide=t.indexOf(r.target))}pause(){this.pausedAutoplay=!0}resume(){this.pausedAutoplay=!1}handlePausedAutoplay(){var t,e;this.pausedAutoplay?(this.autoplayController.stop(),(t=this.autoplayControls)==null||t.setAttribute("aria-pressed","false")):this.autoplay&&(this.autoplayController.start(3e3),(e=this.autoplayControls)==null||e.setAttribute("aria-pressed","true"))}initializeSlides(){let t=this.getSlides(),e=this.intersectionObserver;if(this.intersectionObserverEntries.clear(),this.getSlides({excludeClones:!1}).forEach((r,a)=>{e.unobserve(r),r.classList.remove("--in-view"),r.classList.remove("--is-active"),r.setAttribute("aria-label",this.localize.term("slideNum",a+1,t.length)),r.hasAttribute("data-clone")&&r.remove()}),this.loop){let r=this.slidesPerPage,a=t.slice(-r),n=t.slice(0,r);a.reverse().forEach((d,h)=>{let u=d.cloneNode(!0);u.setAttribute("data-clone",String(t.length-h-1)),this.prepend(u)}),n.forEach((d,h)=>{let u=d.cloneNode(!0);u.setAttribute("data-clone",String(h)),this.append(u)})}this.getSlides({excludeClones:!1}).forEach(r=>{e.observe(r)}),this.goToSlide(this.activeSlide,"auto")}handleSlideChange(){let t=this.getSlides();t.forEach((a,n)=>{a.classList.toggle("--is-active",n===this.activeSlide)});let e=this.getCurrentPage(t.length,this.activeSlide,this.slidesPerPage,this.slidesPerMove);this.currentPage!==e&&(this.currentPage=e),this.hasUpdated&&this.emit("sd-slide-change",{detail:{index:this.activeSlide,slide:t[this.activeSlide]}});let r=this.getPageCount(t.length,this.slidesPerPage,this.slidesPerMove);this.currentPage>r&&requestAnimationFrame(()=>{this.nextTillFirst()})}handleSlidesPerMoveChange(){let t=this.getSlides({excludeClones:!1}),e=this.slidesPerMove;t.forEach((r,a)=>{Math.abs(a-e)%e===0?r.style.removeProperty("scroll-snap-align"):r.style.setProperty("scroll-snap-align","none")})}handleAutoplayChange(){this.autoplayController.stop(),this.autoplay&&!this.pausedAutoplay&&this.autoplayController.start(3e3)}previous(t="smooth"){let e=this.activeSlide||this.activeSlide-this.slidesPerMove,r=!1;for(;!r&&e>0;)e-=1,r=Math.abs(e-this.slidesPerMove)%this.slidesPerMove===0;this.currentPage-1===0&&this.loop?this.goToSlide(this.activeSlide-this.slidesPerPage,t):this.goToSlide(e,t)}next(t="smooth"){this.currentPage+1<=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove)?this.goToSlide(this.activeSlide+this.slidesPerMove,t):this.loop&&this.nextTillFirst(t)}nextTillFirst(t="smooth"){for(;this.activeSlide!==0;)this.goToSlide(this.activeSlide+1,t);this.currentPage=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove)}goToSlide(t,e="smooth"){let{slidesPerPage:r,loop:a,scrollContainer:n}=this,d=this.getSlides(),h=this.getSlides({excludeClones:!1}),u=(t+d.length)%d.length;this.activeSlide=u;let f=As(t+(a?r:0),0,h.length+1),b=h[f],k=n.getBoundingClientRect(),x=b.getBoundingClientRect();if(n.scrollTo({left:x.left-k.left+n.scrollLeft,top:x.top-k.top+n.scrollTop,behavior:ni()?"auto":e}),this.userInteracted&&!this.loop){let $=this.activeSlide===d.length-1||this.activeSlide===this.slides.length-this.slidesPerPage,z=this.activeSlide===0;$?this.previousButton.focus({preventScroll:!0}):z&&this.nextButton.focus({preventScroll:!0})}}render(){let{scrollController:t,slidesPerMove:e}=this,r=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove),a=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove),n=this.loop||a>1,d=this.loop||a<r,h=this.localize.dir()==="ltr";return p`<div part="base" class="${c("carousel h-full w-full")}"><div id="scroll-container" part="scroll-container" class="${c(`carousel__slides mb-6
109
+ ${this.inverted?"disabled:bg-neutral-600":"disabled:bg-neutral-500"} disabled:text-white`}[this.variant])}" ?disabled="${E(t?void 0:this.disabled)}" type="${E(t?void 0:this.type)}" title="${this.title}" name="${E(t?void 0:this.name)}" value="${E(t?void 0:this.value)}" href="${E(t?this.href:void 0)}" target="${E(t?this.target:void 0)}" download="${E(t?this.download:void 0)}" rel="${E(t&&this.target?"noreferrer noopener":void 0)}" role="${E(t?void 0:"button")}" aria-disabled="${this.disabled||this.visuallyDisabled?"true":"false"}" aria-labelledby="content" tabindex="${this.disabled?"-1":"0"}" @blur="${this.handleBlur}" @focus="${this.handleFocus}" @invalid="${this.isButton()?this.handleInvalid:null}" @click="${this.handleClick}"><slot name="icon-left" part="icon-left" class="${c("flex flex-auto items-center pointer-events-none",r["icon-only"]&&"hidden",this.loading&&"invisible",r["icon-left"]&&{sm:"mr-1",md:"mr-2",lg:"mr-2"}[this.size])}"></slot><slot part="label" id="content" class="${c(r["icon-only"]?"flex flex-auto items-center pointer-events-none":"inline-block",this.loading&&"invisible")}"></slot><slot name="icon-right" part="icon-right" class="${c("flex flex-auto items-center pointer-events-none",this.loading&&"invisible",r["icon-only"]&&"hidden",r["icon-right"]&&{sm:"ml-1",md:"ml-2",lg:"ml-2"}[this.size])}"></slot>${this.loading?F`<sd-spinner class="${c("absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2")}"></sd-spinner>`:""}</${e}>`}};B.styles=[...m.styles,v`:host{cursor:pointer;display:inline-block;position:relative;width:var(--sd-spacing-auto,auto)}sd-spinner{--indicator-color:currentColor;--track-color:var(--tw-varcolor-200)}::slotted(sd-badge){pointer-events:none;position:absolute;right:var(--sd-spacing-0,0);top:var(--sd-spacing-0,0);--tw-translate-x:50%!important;--tw-translate-y:-50%!important;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}::slotted(sd-icon),sd-spinner{font-size:calc(var(--tw-varspacing)/2)}`],o([g("a, button")],B.prototype,"button",2),o([Ke({selector:"sd-icon"})],B.prototype,"_iconsInDefaultSlot",2),o([C()],B.prototype,"invalid",2),o([l()],B.prototype,"title",2),o([l({reflect:!0})],B.prototype,"variant",2),o([l({type:Boolean,reflect:!0})],B.prototype,"inverted",2),o([l({reflect:!0})],B.prototype,"size",2),o([l({type:Boolean,reflect:!0})],B.prototype,"disabled",2),o([l({type:Boolean,reflect:!0,attribute:"visually-disabled"})],B.prototype,"visuallyDisabled",2),o([l({type:Boolean,reflect:!0})],B.prototype,"loading",2),o([l()],B.prototype,"type",2),o([l()],B.prototype,"name",2),o([l()],B.prototype,"value",2),o([l()],B.prototype,"href",2),o([l()],B.prototype,"target",2),o([l()],B.prototype,"download",2),o([l()],B.prototype,"form",2),o([l({attribute:"formaction"})],B.prototype,"formAction",2),o([l({attribute:"formenctype"})],B.prototype,"formEnctype",2),o([l({attribute:"formmethod"})],B.prototype,"formMethod",2),o([l({attribute:"formnovalidate",type:Boolean})],B.prototype,"formNoValidate",2),o([l({attribute:"formtarget"})],B.prototype,"formTarget",2),o([w("disabled",{waitUntilFirstUpdate:!0})],B.prototype,"handleDisabledChange",1),B=o([y("sd-button")],B);var Bi=class{constructor(i,t){this.timerId=0;this.activeInteractions=0;this.paused=!1;this.stopped=!0;this.pause=()=>{this.activeInteractions++||(this.paused=!0,this.host.requestUpdate())};this.resume=()=>{--this.activeInteractions||(this.paused=!1,this.host.requestUpdate())};i.addController(this),this.host=i,this.tickCallback=t}hostConnected(){this.host.addEventListener("mouseenter",this.pause),this.host.addEventListener("mouseleave",this.resume),this.host.addEventListener("focusin",this.pause),this.host.addEventListener("focusout",this.resume),this.host.addEventListener("touchstart",this.pause,{passive:!0}),this.host.addEventListener("touchend",this.resume)}hostDisconnected(){this.stop(),this.host.removeEventListener("mouseenter",this.pause),this.host.removeEventListener("mouseleave",this.resume),this.host.removeEventListener("focusin",this.pause),this.host.removeEventListener("focusout",this.resume),this.host.removeEventListener("touchstart",this.pause),this.host.removeEventListener("touchend",this.resume)}start(i){this.stop(),this.stopped=!1,this.timerId=window.setInterval(()=>{this.paused||this.tickCallback()},i)}stop(){clearInterval(this.timerId),this.stopped=!0,this.host.requestUpdate()}};function As(s,i,t){let e=r=>Object.is(r,-0)?0:r;return s<i?e(i):s>t?e(t):e(s)}function*Os(s,i){if(s!==void 0){let t=0;for(let e of s)yield i(e,t++)}}function*Ms(s,i,t=1){let e=i===void 0?0:s;i!=null||(i=s);for(let r=e;t>0?r<i:i<r;r+=t)yield r}var Ds=Symbol(),Vi=s=>(i,t,e)=>{let r=e.value;e.value=function(...a){clearTimeout(this[Ds]),this[Ds]=window.setTimeout(()=>{r.apply(this,a)},s)}};var hi=class{constructor(i){this.pointers=new Set;this.dragging=!1;this.scrolling=!1;this.mouseDragging=!1;this.handleScroll=()=>{this.scrolling||(this.scrolling=!0,this.host.requestUpdate()),this.handleScrollEnd()};this.handlePointerDown=i=>{if(i.pointerType==="touch")return;this.pointers.add(i.pointerId),this.mouseDragging&&!this.dragging&&i.button===0&&(i.preventDefault(),this.host.scrollContainer.addEventListener("pointermove",this.handlePointerMove))};this.handlePointerMove=i=>{let t=this.host.scrollContainer,e=!!i.movementX||!!i.movementY;!this.dragging&&e?(t.setPointerCapture(i.pointerId),this.handleDragStart()):t.hasPointerCapture(i.pointerId)&&this.handleDrag(i)};this.handlePointerUp=i=>{this.pointers.delete(i.pointerId),this.host.scrollContainer.releasePointerCapture(i.pointerId),this.pointers.size===0&&this.handleDragEnd()};this.handleTouchEnd=i=>{for(let t of i.changedTouches)this.pointers.delete(t.identifier)};this.handleTouchStart=i=>{for(let t of i.touches)this.pointers.add(t.identifier)};this.host=i,i.addController(this)}async hostConnected(){let i=this.host;await i.updateComplete;let t=i.scrollContainer;t.addEventListener("scroll",this.handleScroll,{passive:!0}),t.addEventListener("pointerdown",this.handlePointerDown),t.addEventListener("pointerup",this.handlePointerUp),t.addEventListener("pointercancel",this.handlePointerUp),t.addEventListener("touchstart",this.handleTouchStart,{passive:!0}),t.addEventListener("touchend",this.handleTouchEnd)}hostDisconnected(){let t=this.host.scrollContainer;t.removeEventListener("scroll",this.handleScroll),t.removeEventListener("pointerdown",this.handlePointerDown),t.removeEventListener("pointerup",this.handlePointerUp),t.removeEventListener("pointercancel",this.handlePointerUp),t.removeEventListener("touchstart",this.handleTouchStart),t.removeEventListener("touchend",this.handleTouchEnd)}handleScrollEnd(){this.pointers.size?this.handleScrollEnd():(this.scrolling=!1,this.host.scrollContainer.dispatchEvent(new CustomEvent("scrollend",{bubbles:!1,cancelable:!1})),this.host.requestUpdate())}handleDragStart(){let i=this.host;this.dragging=!0,i.scrollContainer.style.setProperty("scroll-snap-type","unset"),i.requestUpdate()}handleDrag(i){this.host.scrollContainer.scrollBy({left:-i.movementX,top:-i.movementY})}async handleDragEnd(){let i=this.host,t=i.scrollContainer;t.removeEventListener("pointermove",this.handlePointerMove),this.dragging=!1;let e=t.scrollLeft,r=t.scrollTop;t.style.removeProperty("scroll-snap-type");let a=t.scrollLeft,n=t.scrollTop;t.style.setProperty("scroll-snap-type","unset"),t.scrollTo({left:e,top:r,behavior:"auto"}),t.scrollTo({left:a,top:n,behavior:ni()?"auto":"smooth"}),this.scrolling&&await U(t,"scrollend"),t.style.removeProperty("scroll-snap-type"),i.requestUpdate()}};o([Vi(100)],hi.prototype,"handleScrollEnd",1);var ee=class extends m{static isCarouselItem(i){return i instanceof Element&&i.getAttribute("aria-roledescription")==="slide"}connectedCallback(){super.connectedCallback(),this.setAttribute("role","group")}render(){return p`<slot></slot>`}};ee.styles=[...m.styles,v`:host{align-items:center;aspect-ratio:var(--aspect-ratio);display:flex;flex-direction:column;height:100%;justify-content:center;scroll-snap-align:start;scroll-snap-stop:always;width:100%}::slotted(img){height:100%;-o-object-fit:cover;object-fit:cover;width:100%}`],ee=o([y("sd-carousel-item")],ee);var N=class extends m{constructor(){super(...arguments);this.variant="number";this.inverted=!1;this.loop=!1;this.autoplay=!1;this.slidesPerPage=1;this.slidesPerMove=1;this.activeSlide=0;this.currentPage=1;this.pausedAutoplay=!1;this.autoplayController=new Bi(this,()=>this.next());this.scrollController=new hi(this);this.slides=this.getElementsByTagName("sd-carousel-item");this.intersectionObserverEntries=new Map;this.localize=new _(this);this.userInteracted=!1;this.handleUserInteraction=()=>{this.userInteracted=!0};this.handleSlotChange=t=>{t.some(r=>[...r.addedNodes,...r.removedNodes].some(a=>ee.isCarouselItem(a)&&!a.hasAttribute("data-clone")))&&this.initializeSlides(),this.requestUpdate()};this.unblockAutoplay=(t,e)=>{t.detail&&e.blur()}}connectedCallback(){super.connectedCallback(),["click","keydown"].forEach(e=>this.addEventListener(e,this.handleUserInteraction));let t=new IntersectionObserver(e=>{e.forEach(r=>{this.intersectionObserverEntries.set(r.target,r);let a=r.target;a.toggleAttribute("inert",!r.isIntersecting),a.classList.toggle("--in-view",r.isIntersecting),a.setAttribute("aria-hidden",r.isIntersecting?"false":"true")})},{root:this,threshold:.6});this.intersectionObserver=t,t.takeRecords().forEach(e=>{this.intersectionObserverEntries.set(e.target,e)})}disconnectedCallback(){super.disconnectedCallback(),this.intersectionObserver.disconnect(),this.mutationObserver.disconnect(),["click","keydown"].forEach(t=>this.removeEventListener(t,this.handleUserInteraction))}firstUpdated(){this.initializeSlides(),this.mutationObserver=new MutationObserver(this.handleSlotChange),this.mutationObserver.observe(this,{childList:!0,subtree:!1})}getPageCount(t,e,r){return Math.ceil((t-e)/r)+1>0?Math.ceil((t-e)/r)+1:1}getCurrentPage(t,e,r,a){return Math.ceil((t-r)/a)-Math.ceil((t-r-e)/a)+1}getSlides({excludeClones:t=!0}={}){return[...this.slides].filter(e=>!t||!e.hasAttribute("data-clone"))}handleKeyDown(t){if(["ArrowLeft","ArrowRight","ArrowUp","ArrowDown","Home","End"].includes(t.key)){let e=t.target,r=this.localize.dir()==="rtl",a=e.closest('[part~="pagination-item"]')!==null,n=t.key==="ArrowDown"||!r&&t.key==="ArrowRight"||r&&t.key==="ArrowLeft",d=t.key==="ArrowUp"||!r&&t.key==="ArrowLeft"||r&&t.key==="ArrowRight";t.preventDefault(),d&&this.previous(),n&&this.next(),t.key==="Home"&&this.goToSlide(0),t.key==="End"&&this.goToSlide(this.getSlides().length-1),a&&this.updateComplete.then(()=>{var u;let h=(u=this.shadowRoot)==null?void 0:u.querySelector('[part~="pagination-item--active"]');h&&h.focus()})}}handleScrollEnd(){let t=this.getSlides(),r=[...this.intersectionObserverEntries.values()].find(a=>a.isIntersecting);if(this.loop&&(r!=null&&r.target.hasAttribute("data-clone"))){let a=Number(r.target.getAttribute("data-clone"));this.goToSlide(a,"auto");return}r&&(this.activeSlide=t.indexOf(r.target))}pause(){this.pausedAutoplay=!0}resume(){this.pausedAutoplay=!1}handlePausedAutoplay(){var t,e;this.pausedAutoplay?(this.autoplayController.stop(),(t=this.autoplayControls)==null||t.setAttribute("aria-pressed","false")):this.autoplay&&(this.autoplayController.start(3e3),(e=this.autoplayControls)==null||e.setAttribute("aria-pressed","true"))}initializeSlides(){let t=this.getSlides(),e=this.intersectionObserver;if(this.intersectionObserverEntries.clear(),this.getSlides({excludeClones:!1}).forEach((r,a)=>{e.unobserve(r),r.classList.remove("--in-view"),r.classList.remove("--is-active"),r.setAttribute("aria-label",this.localize.term("slideNum",a+1,t.length)),r.hasAttribute("data-clone")&&r.remove()}),this.loop){let r=this.slidesPerPage,a=t.slice(-r),n=t.slice(0,r);a.reverse().forEach((d,h)=>{let u=d.cloneNode(!0);u.setAttribute("data-clone",String(t.length-h-1)),this.prepend(u)}),n.forEach((d,h)=>{let u=d.cloneNode(!0);u.setAttribute("data-clone",String(h)),this.append(u)})}this.getSlides({excludeClones:!1}).forEach(r=>{e.observe(r)}),this.goToSlide(this.activeSlide,"auto")}handleSlideChange(){let t=this.getSlides();t.forEach((a,n)=>{a.classList.toggle("--is-active",n===this.activeSlide)});let e=this.getCurrentPage(t.length,this.activeSlide,this.slidesPerPage,this.slidesPerMove);this.currentPage!==e&&(this.currentPage=e),this.hasUpdated&&this.emit("sd-slide-change",{detail:{index:this.activeSlide,slide:t[this.activeSlide]}});let r=this.getPageCount(t.length,this.slidesPerPage,this.slidesPerMove);this.currentPage>r&&requestAnimationFrame(()=>{this.nextTillFirst()})}handleSlidesPerMoveChange(){let t=this.getSlides({excludeClones:!1}),e=this.slidesPerMove;t.forEach((r,a)=>{Math.abs(a-e)%e===0?r.style.removeProperty("scroll-snap-align"):r.style.setProperty("scroll-snap-align","none")})}handleAutoplayChange(){this.autoplayController.stop(),this.autoplay&&!this.pausedAutoplay&&this.autoplayController.start(3e3)}previous(t="smooth"){let e=this.activeSlide||this.activeSlide-this.slidesPerMove,r=!1;for(;!r&&e>0;)e-=1,r=Math.abs(e-this.slidesPerMove)%this.slidesPerMove===0;this.currentPage-1===0&&this.loop?this.goToSlide(this.activeSlide-this.slidesPerPage,t):this.goToSlide(e,t)}next(t="smooth"){this.currentPage+1<=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove)?this.goToSlide(this.activeSlide+this.slidesPerMove,t):this.loop&&this.nextTillFirst(t)}nextTillFirst(t="smooth"){for(;this.activeSlide!==0;)this.goToSlide(this.activeSlide+1,t);this.currentPage=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove)}goToSlide(t,e="smooth"){let{slidesPerPage:r,loop:a,scrollContainer:n}=this,d=this.getSlides(),h=this.getSlides({excludeClones:!1}),u=(t+d.length)%d.length;this.activeSlide=u;let f=As(t+(a?r:0),0,h.length+1),b=h[f],k=n.getBoundingClientRect(),x=b.getBoundingClientRect();if(n.scrollTo({left:x.left-k.left+n.scrollLeft,top:x.top-k.top+n.scrollTop,behavior:ni()?"auto":e}),this.userInteracted&&!this.loop){let $=this.activeSlide===d.length-1||this.activeSlide===this.slides.length-this.slidesPerPage,z=this.activeSlide===0;$?this.previousButton.focus({preventScroll:!0}):z&&this.nextButton.focus({preventScroll:!0})}}render(){let{scrollController:t,slidesPerMove:e}=this,r=this.getPageCount(this.getSlides().length,this.slidesPerPage,this.slidesPerMove),a=this.getCurrentPage(this.getSlides().length,this.activeSlide,this.slidesPerPage,this.slidesPerMove),n=this.loop||a>1,d=this.loop||a<r,h=this.localize.dir()==="ltr";return p`<div part="base" class="${c("carousel h-full w-full")}"><div id="scroll-container" part="scroll-container" class="${c(`carousel__slides mb-6
110
110
  grid max-h-full w-full items-center justify-items-center overflow-auto`,this.inverted?"focus-visible:focus-outline-inverted":"focus-visible:focus-outline",`overscroll-x-contain grid-flow-col auto-rows-[100%]
111
111
  snap-x snap-mandatory overflow-y-hidden`)}" style="--slides-per-page:${this.slidesPerPage}" aria-busy="${t.scrolling?"true":"false"}" role="status" tabindex="0" @keydown="${this.handleKeyDown}" @scrollend="${this.handleScrollEnd}"><slot></slot></div><div part="controls" class="${c("w-full flex items-center justify-center relative")}"><div part="navigation" class="${c("carousel__navigation flex items-center justify-center")}"><button part="navigation-button navigation-button--previous" id="carousel__navigation-button--previous" ?disabled="${!n}" class="${c("!mr-6 !rounded-sm sd-interactive",!n&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("previousSlide")}" aria-controls="scroll-container" aria-disabled="${n?"false":"true"}" @click="${n?u=>{this.previous(),this.unblockAutoplay(u,this.previousButton)}:null}"><slot name="previous-icon"><sd-icon class="${c("h-6 w-6 rotate-90 grid place-items-center")}" library="system" name="${h?"chevron-down":"chevron-up"}"></sd-icon></slot></button> ${this.variant==="dot"?p`<div part="pagination-dot" role="tablist" class="${c("carousel__pagination dot flex wrap items-center gap-2")}" aria-controls="scroll-container">${Os(Ms(r),u=>{let f=u+1===a;return p`<button part="pagination-item ${f?"pagination-item--active":""}" class="${c("carousel__pagination-item","block cursor-pointer bg-none border-0 rounded-full",f?"bg-accent":"",this.inverted?"focus-within:focus-outline-inverted":"focus-within:focus-outline")}" role="tab" tabindex="0" aria-selected="${f?"true":"false"}" aria-label="${this.localize.term("goToSlide",u+1,r)}" @click="${b=>{this.goToSlide(u*e),this.unblockAutoplay(b,this.paginationItems[u])}}" @keydown="${this.handleKeyDown}"><span class="${c("h-4 w-4 block border hover:border-primary-500 rounded-full",this.inverted?"border-white hover:border-primary-500":"border-primary",f&&"bg-accent border-none",f?this.inverted?"hover:bg-accent-300":"hover:bg-accent-550":"")}"></span></button>`})}</div>`:p`<span part="pagination-number" class="carousel__pagination number flex gap-0.5 cursor-default select-none" aria-controls="scroll-container"><span part="pagination-item" class="${c("w-5 text-center border-b-2 border-accent",this.inverted?"text-white":"text-black")}">${a}</span> <span part="pagination-divider" class="${c("scale-y-[1.5]","text-center",this.inverted?"text-white":"text-black")}">/</span> <span part="pagination-item" class="${c("w-5 text-center",this.inverted?"text-white":"text-black")}">${r}</span></span>`} <button part="navigation-button navigation-button--next" id="carousel__navigation-button--next" ?disabled="${!d}" class="${c("!ml-6 !rounded-sm sd-interactive ",!d&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("nextSlide")}" aria-controls="scroll-container" aria-disabled="${d?"false":"true"}" @click="${d?u=>{this.next(),this.unblockAutoplay(u,this.nextButton)}:null}"><slot name="next-icon"><sd-icon class="${c("h-6 w-6 rotate-90 grid place-items-center")}" library="system" name="${h?"chevron-up":"chevron-down"}"></sd-icon></slot></button></div><button class="${c("ml-6 !rounded-sm","!absolute !right-0 sd-interactive",this.inverted?"sd-interactive--inverted":"sd-interactive--reset",!this.autoplay&&"!hidden")}" part="autoplay-controls" aria-label="${this.localize.term("autoplay")}" aria-pressed="true" @click="${u=>{this.pausedAutoplay=!this.pausedAutoplay,u.detail&&this.autoplayControls.blur()}}"><slot name="autoplay-start" class="${c(this.pausedAutoplay?"":"hidden")}"><sd-icon class="h-6 w-6 grid place-items-center" library="system" name="start"></sd-icon></slot><slot name="autoplay-pause" class="${c(this.pausedAutoplay?"hidden":"")}"><sd-icon class="h-6 w-6 grid place-items-center" library="system" name="pause"></sd-icon></slot></button></div></div>`}};N.styles=[...m.styles,v`:host{--slide-gap:var(--sl-spacing-medium,1rem);--scroll-hint:0px;display:flex}.carousel{grid-template-areas:". slides ." ". pagination ."}.carousel__pagination{grid-area:pagination}.carousel__slides{grid-area:slides;scrollbar-width:none;--slide-size:calc((100% - (var(--slides-per-page) - 1)*var(--slide-gap))/var(--slides-per-page));-moz-column-gap:var(--slide-gap);column-gap:var(--slide-gap);grid-auto-columns:var(--slide-size);padding-inline:var(--scroll-hint);scroll-padding-inline:var(--scroll-hint)}.carousel__slides::-webkit-scrollbar{display:none}@media (prefers-reduced-motion){:where(.carousel__slides){scroll-behavior:auto}}.carousel__navigation{grid-area:navigation}sd-button::part(label){align-items:center;display:flex;flex:1 1 auto;pointer-events:none}`],o([g('[part~="autoplay-controls"]')],N.prototype,"autoplayControls",2),o([g('[part~="navigation-button--previous"]')],N.prototype,"previousButton",2),o([g('[part~="navigation-button--next"]')],N.prototype,"nextButton",2),o([bs('[part~="pagination-item"]')],N.prototype,"paginationItems",2),o([l({type:String,reflect:!0})],N.prototype,"variant",2),o([l({type:Boolean,reflect:!0})],N.prototype,"inverted",2),o([l({type:Boolean,reflect:!0})],N.prototype,"loop",2),o([l({type:Boolean,reflect:!0})],N.prototype,"autoplay",2),o([l({type:Number,attribute:"slides-per-page"})],N.prototype,"slidesPerPage",2),o([l({type:Number,attribute:"slides-per-move"})],N.prototype,"slidesPerMove",2),o([g("slot:not([name])")],N.prototype,"defaultSlot",2),o([g(".carousel__slides")],N.prototype,"scrollContainer",2),o([g(".carousel__pagination")],N.prototype,"paginationContainer",2),o([C()],N.prototype,"activeSlide",2),o([C()],N.prototype,"currentPage",2),o([C()],N.prototype,"pausedAutoplay",2),o([w("pausedAutoplay")],N.prototype,"handlePausedAutoplay",1),o([w("loop",{waitUntilFirstUpdate:!0}),w("slidesPerPage",{waitUntilFirstUpdate:!0})],N.prototype,"initializeSlides",1),o([w("activeSlide")],N.prototype,"handleSlideChange",1),o([w("slidesPerMove")],N.prototype,"handleSlidesPerMoveChange",1),o([w("autoplay")],N.prototype,"handleAutoplayChange",1),N=o([y("sd-carousel")],N);var Ht=(s="value")=>(i,t)=>{let e=i.constructor,r=e.prototype.attributeChangedCallback;e.prototype.attributeChangedCallback=function(a,n,d){var f;let h=e.getPropertyOptions(s),u=typeof h.attribute=="string"?h.attribute:s;if(a===u){let b=h.converter||we,x=(typeof b=="function"?b:(f=b==null?void 0:b.fromAttribute)!=null?f:we.fromAttribute)(d,h.type);this[s]!==x&&(this[t]=x)}r.call(this,a,n,d)}};var{I:c0}=ss;var Ri=s=>s.strings===void 0;var Pn={},_s=(s,i=Pn)=>s._$AH=i;var he=de(class extends ke{constructor(s){if(super(s),s.type!==Ot.PROPERTY&&s.type!==Ot.ATTRIBUTE&&s.type!==Ot.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!Ri(s))throw Error("`live` bindings can only contain a single expression")}render(s){return s}update(s,[i]){if(i===vt||i===Y)return i;let t=s.element,e=s.name;if(s.type===Ot.PROPERTY){if(i===t[e])return vt}else if(s.type===Ot.BOOLEAN_ATTRIBUTE){if(!!i===t.hasAttribute(e))return vt}else if(s.type===Ot.ATTRIBUTE&&t.getAttribute(e)===i+"")return vt;return _s(s),i}});var Q=class extends m{constructor(){super(...arguments);this.formControlController=new pt(this,{value:t=>t.checked?t.value||"on":void 0,defaultValue:t=>t.defaultChecked,setValue:(t,e)=>t.checked=e});this.title="";this.name="";this.size="lg";this.disabled=!1;this.visuallyDisabled=!1;this.checked=!1;this.indeterminate=!1;this.defaultChecked=!1;this.form="";this.required=!1;this.showInvalidStyle=!1}get validity(){return this.input.validity}firstUpdated(){this.formControlController.updateValidity()}handleClick(t){if(this.visuallyDisabled){t.preventDefault(),t.stopPropagation();return}this.checked=!this.checked,this.indeterminate=!1,this.emit("sd-change")}handleBlur(){this.emit("sd-blur")}handleInput(){this.emit("sd-input")}handleInvalid(t){this.formControlController.setValidity(!1),this.formControlController.emitInvalidEvent(t),this.invalidMessage.textContent=t.target.validationMessage}handleFocus(){this.emit("sd-focus")}handleDisabledChange(){let t=this.disabled||this.visuallyDisabled;this.setAttribute("aria-disabled",t?"true":"false"),this.formControlController.setValidity(t)}handleStateChange(){this.input.checked=this.checked,this.input.indeterminate=this.indeterminate,this.formControlController.updateValidity()}click(){this.input.click()}focus(t){this.input.focus(t)}blur(){this.input.blur()}checkValidity(){return this.input.checkValidity()}getForm(){return this.formControlController.getForm()}reportValidity(){return this.formControlController.fakeUserInteraction(),this.input.reportValidity()}setCustomValidity(t){this.input.setCustomValidity(t),this.formControlController.updateValidity()}render(){let t=this.disabled&&this.indeterminate?"disabledIndeterminate":this.disabled&&this.checked?"disabledChecked":this.disabled?"disabled":this.visuallyDisabled?"visuallyDisabled":this.showInvalidStyle&&this.indeterminate?"invalidIndeterminate":this.showInvalidStyle?"invalid":this.checked||this.indeterminate?"filled":"default";return p`<label part="base" class="${c("sd-checkbox group flex items-start text-base leading-normal text-black cursor-pointer",(this.disabled||this.visuallyDisabled)&&"hover:cursor-not-allowed",{sm:"text-sm",md:"text-base",lg:"text-base"}[this.size])}"><input class="peer absolute opacity-0 p-0 m-0 pointer-events-none" type="checkbox" title="${this.title}" name="${this.name}" value="${E(this.value)}" .indeterminate="${he(this.indeterminate)}" .checked="${he(this.checked)}" .disabled="${this.disabled}" .required="${this.required}" aria-checked="${this.indeterminate?"mixed":this.checked}" aria-describedby="invalid-message" aria-invalid="${this.showInvalidStyle}" aria-disabled="${this.disabled||this.visuallyDisabled?"true":"false"}" @click="${this.handleClick}" @input="${this.handleInput}" @invalid="${this.handleInvalid}" @blur="${this.handleBlur}" @focus="${this.handleFocus}"> <span id="control" part="control ${this.checked?" control--checked":"control--unchecked"} ${this.indeterminate?" control--indeterminate":""}" class="${c("relative flex flex-shrink-0 items-center justify-center border rounded-sm h-4 w-4",this.visuallyDisabled?"":"peer-focus-visible:outline peer-focus-visible:outline-2 peer-focus-visible:outline-offset-2 peer-focus-visible:outline-primary",{sm:"mt-[2px]",md:"mt-[3px]",lg:"mt-[3px]"}[this.size],{disabledIndeterminate:"border-neutral-500 bg-neutral-500",disabledChecked:"border-neutral-500 bg-neutral-500",disabled:"border-neutral-500",visuallyDisabled:"border-neutral-500",invalidIndeterminate:"border-error bg-error group-hover:bg-error-400",invalid:"border-error group-hover:bg-neutral-200",filled:"border-accent hover:border-accent-550 group-hover:border-accent-550 bg-accent group-hover:bg-accent-550",default:"border-neutral-800 hover:bg-neutral-200 group-hover:bg-neutral-200 bg-white"}[t])}">${this.checked?p`<sd-icon part="checked-icon" class="text-white w-3 h-3" library="system" name="status-check"></sd-icon>`:""} ${!this.checked&&this.indeterminate?p`<sd-icon part="indeterminate-icon" class="text-white w-3 h-3" library="system" name="status-minus"></sd-icon>`:""} </span><span part="label" id="label" class="${c("select-none inline-block ml-2",this.disabled||this.visuallyDisabled?"text-neutral-500":this.showInvalidStyle?"text-error":"text-black")}"><slot></slot></span></label> ${this.formControlController.renderInvalidMessage()}`}};Q.styles=[...m.styles,v`:host{display:block;width:-moz-max-content;width:max-content}:host(:focus-visible){outline-width:0}:host([required]) #label:after{content:" *"}`],o([g('input[type="checkbox"]')],Q.prototype,"input",2),o([g("#invalid-message")],Q.prototype,"invalidMessage",2),o([l()],Q.prototype,"title",2),o([l()],Q.prototype,"name",2),o([l()],Q.prototype,"value",2),o([l({reflect:!0})],Q.prototype,"size",2),o([l({type:Boolean,reflect:!0})],Q.prototype,"disabled",2),o([l({type:Boolean,reflect:!0,attribute:"visually-disabled"})],Q.prototype,"visuallyDisabled",2),o([l({type:Boolean,reflect:!0})],Q.prototype,"checked",2),o([l({type:Boolean,reflect:!0})],Q.prototype,"indeterminate",2),o([Ht("checked")],Q.prototype,"defaultChecked",2),o([l({reflect:!0})],Q.prototype,"form",2),o([l({type:Boolean,reflect:!0})],Q.prototype,"required",2),o([C()],Q.prototype,"showInvalidStyle",2),o([w(["disabled","visually-disabled"],{waitUntilFirstUpdate:!0})],Q.prototype,"handleDisabledChange",1),o([w(["checked","indeterminate"],{waitUntilFirstUpdate:!0})],Q.prototype,"handleStateChange",1),Q=o([y("sd-checkbox")],Q);var $t=class extends m{constructor(){super(...arguments);this.hasSlotController=new D(this,"label","help-text");this.size="lg";this.orientation="vertical";this.label="";this.helpText=""}getAllCheckboxes(){return[...this.querySelectorAll("sd-checkbox")]}async syncCheckboxElements(){let t=this.getAllCheckboxes();await Promise.all(t.map(async e=>{await e.updateComplete,e.size=this.size}))}syncCheckboxes(){customElements.get("sd-checkbox")?this.syncCheckboxElements():customElements.whenDefined("sd-checkbox").then(()=>this.syncCheckboxes())}handleSizeChange(){this.syncCheckboxes()}handleInvalid(){this.syncCheckboxes()}render(){let t=this.hasSlotController.test("label"),e=this.label?!0:t,r=this.hasSlotController.test("help-text"),a=this.helpText?!0:r,n=p`<slot @slotchange="${this.syncCheckboxes}"></slot>`,d=this.hasSlotController.test("tooltip");return p`<fieldset part="form-control" class="${c("border-0 p-0 m-0",{sm:"text-sm",md:"text-base",lg:"text-base"}[this.size])}" role="group" aria-labelledby="label">${e||d?p`<div class="flex items-center gap-1 mb-2"><label part="form-control-label" id="label" class="${c("p-0 font-bold leading-normal text-black",e?"flex":"hidden")}" aria-hidden="${e?"false":"true"}"><slot name="label">${this.label}</slot></label> ${d?p`<slot name="tooltip"></slot>`:""}</div>`:null}<div part="form-control-input" class="${c({vertical:"flex flex-col",horizontal:"flex flex-row"}[this.orientation])}">${n}</div></fieldset><slot name="help-text" part="form-control-help-text" id="help-text" class="${c("text-sm text-neutral-700 mt-2",a?"block":"hidden")}" aria-hidden="${!a}">${this.helpText}</slot>`}};$t.styles=[...m.styles,v`:host{display:block}:host([orientation=vertical]) ::slotted(sd-checkbox){display:flex;margin-bottom:var(--sd-spacing-2,.5rem)}:host([orientation=vertical]) ::slotted(sd-checkbox:last-of-type){margin-bottom:var(--sd-spacing-0,0)}:host([orientation=horizontal]) ::slotted(sd-checkbox){margin-right:var(--sd-spacing-6,1.5rem)}:host([orientation=horizontal]) ::slotted(sd-checkbox:last-of-type){margin-right:var(--sd-spacing-0,0)}:host([orientation=horizontal]):host([size=sm]) ::slotted(sd-checkbox){margin-right:var(--sd-spacing-4,1rem)}:host([orientation=horizontal]):host([size=sm]) ::slotted(sd-checkbox:last-of-type){margin-right:var(--sd-spacing-0,0)}`],o([l({reflect:!0})],$t.prototype,"size",2),o([l({reflect:!0})],$t.prototype,"orientation",2),o([l()],$t.prototype,"label",2),o([l({attribute:"help-text"})],$t.prototype,"helpText",2),o([w("size",{waitUntilFirstUpdate:!0})],$t.prototype,"handleSizeChange",1),o([w("invalid",{waitUntilFirstUpdate:!0})],$t.prototype,"handleInvalid",1),$t=o([y("sd-checkbox-group")],$t);var Ss=s=>s;var $r=s=>Array.from(s.assignedElements({flatten:!0})),Fn=s=>s.tagName.toLocaleLowerCase()==="sd-option"?s:Array.from(s.querySelectorAll(":scope > sd-option")),Bn=s=>s.tagName.toLocaleLowerCase()==="sd-optgroup",Hs=s=>s.map(Fn),Is=s=>s.filter(Bn),Ui=s=>s.normalize("NFD").replace(/[\u0300-\u036f]/g,"").toLowerCase();function Ps(s,i){return{top:Math.round(s.getBoundingClientRect().top-i.getBoundingClientRect().top),left:Math.round(s.getBoundingClientRect().left-i.getBoundingClientRect().left)}}var Tr=new Set;function Vn(){let s=document.documentElement.clientWidth;return Math.abs(window.innerWidth-s)}function De(s){if(Tr.add(s),!document.body.classList.contains("sd-scroll-lock")){let i=Vn();document.body.classList.add("sd-scroll-lock"),document.body.style.setProperty("--sd-scroll-lock-size",`${i}px`)}}function _e(s){Tr.delete(s),Tr.size===0&&(document.body.classList.remove("sd-scroll-lock"),document.body.style.removeProperty("--sd-scrollbar-width"))}function qt(s,i,t="vertical",e="smooth"){let r=Ps(s,i),a=r.top+i.scrollTop,n=r.left+i.scrollLeft,d=i.scrollLeft,h=i.scrollLeft+i.offsetWidth,u=i.scrollTop,f=i.scrollTop+i.offsetHeight;(t==="horizontal"||t==="both")&&(n<d?i.scrollTo({left:n,behavior:e}):n+s.clientWidth>h&&i.scrollTo({left:n-i.offsetWidth+s.clientWidth,behavior:e})),(t==="vertical"||t==="both")&&(a<u?i.scrollTo({top:a,behavior:e}):a+s.clientHeight>f&&i.scrollTo({top:a-i.offsetHeight+s.clientHeight,behavior:e}))}var ie=Math.min,xt=Math.max,ui=Math.round,mi=Math.floor,Kt=s=>({x:s,y:s}),Rn={left:"right",right:"left",bottom:"top",top:"bottom"},Un={start:"end",end:"start"};function qi(s,i,t){return xt(s,ie(i,t))}function Se(s,i){return typeof s=="function"?s(i):s}function pe(s){return s.split("-")[0]}function He(s){return s.split("-")[1]}function Lr(s){return s==="x"?"y":"x"}function Ki(s){return s==="y"?"height":"width"}function Ce(s){return["top","bottom"].includes(pe(s))?"y":"x"}function ji(s){return Lr(Ce(s))}function Fs(s,i,t){t===void 0&&(t=!1);let e=He(s),r=ji(s),a=Ki(r),n=r==="x"?e===(t?"end":"start")?"right":"left":e==="start"?"bottom":"top";return i.reference[a]>i.floating[a]&&(n=pi(n)),[n,pi(n)]}function Bs(s){let i=pi(s);return[Ni(s),i,Ni(i)]}function Ni(s){return s.replace(/start|end/g,i=>Un[i])}function Nn(s,i,t){let e=["left","right"],r=["right","left"],a=["top","bottom"],n=["bottom","top"];switch(s){case"top":case"bottom":return t?i?r:e:i?e:r;case"left":case"right":return i?a:n;default:return[]}}function Vs(s,i,t,e){let r=He(s),a=Nn(pe(s),t==="start",e);return r&&(a=a.map(n=>n+"-"+r),i&&(a=a.concat(a.map(Ni)))),a}function pi(s){return s.replace(/left|right|bottom|top/g,i=>Rn[i])}function qn(s){return M({top:0,right:0,bottom:0,left:0},s)}function zr(s){return typeof s!="number"?qn(s):{top:s,right:s,bottom:s,left:s}}function Ie(s){let{x:i,y:t,width:e,height:r}=s;return{width:e,height:r,top:t,left:i,right:i+e,bottom:t+r,x:i,y:t}}function Rs(s,i,t){let{reference:e,floating:r}=s,a=Ce(i),n=ji(i),d=Ki(n),h=pe(i),u=a==="y",f=e.x+e.width/2-r.width/2,b=e.y+e.height/2-r.height/2,k=e[d]/2-r[d]/2,x;switch(h){case"top":x={x:f,y:e.y-r.height};break;case"bottom":x={x:f,y:e.y+e.height};break;case"right":x={x:e.x+e.width,y:b};break;case"left":x={x:e.x-r.width,y:b};break;default:x={x:e.x,y:e.y}}switch(He(i)){case"start":x[n]-=k*(t&&u?-1:1);break;case"end":x[n]+=k*(t&&u?-1:1);break}return x}var Us=async(s,i,t)=>{let{placement:e="bottom",strategy:r="absolute",middleware:a=[],platform:n}=t,d=a.filter(Boolean),h=await(n.isRTL==null?void 0:n.isRTL(i)),u=await n.getElementRects({reference:s,floating:i,strategy:r}),{x:f,y:b}=Rs(u,e,h),k=e,x={},$=0;for(let z=0;z<d.length;z++){let{name:P,fn:S}=d[z],{x:q,y:K,data:tt,reset:et}=await S({x:f,y:b,initialPlacement:e,placement:k,strategy:r,middlewareData:x,rects:u,platform:n,elements:{reference:s,floating:i}});f=q!=null?q:f,b=K!=null?K:b,x=rt(M({},x),{[P]:M(M({},x[P]),tt)}),et&&$<=50&&($++,typeof et=="object"&&(et.placement&&(k=et.placement),et.rects&&(u=et.rects===!0?await n.getElementRects({reference:s,floating:i,strategy:r}):et.rects),{x:f,y:b}=Rs(u,k,h)),z=-1)}return{x:f,y:b,placement:k,strategy:r,middlewareData:x}};async function Yi(s,i){var t;i===void 0&&(i={});let{x:e,y:r,platform:a,rects:n,elements:d,strategy:h}=s,{boundary:u="clippingAncestors",rootBoundary:f="viewport",elementContext:b="floating",altBoundary:k=!1,padding:x=0}=Se(i,s),$=zr(x),P=d[k?b==="floating"?"reference":"floating":b],S=Ie(await a.getClippingRect({element:(t=await(a.isElement==null?void 0:a.isElement(P)))==null||t?P:P.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(d.floating)),boundary:u,rootBoundary:f,strategy:h})),q=b==="floating"?{x:e,y:r,width:n.floating.width,height:n.floating.height}:n.reference,K=await(a.getOffsetParent==null?void 0:a.getOffsetParent(d.floating)),tt=await(a.isElement==null?void 0:a.isElement(K))?await(a.getScale==null?void 0:a.getScale(K))||{x:1,y:1}:{x:1,y:1},et=Ie(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:d,rect:q,offsetParent:K,strategy:h}):q);return{top:(S.top-et.top+$.top)/tt.y,bottom:(et.bottom-S.bottom+$.bottom)/tt.y,left:(S.left-et.left+$.left)/tt.x,right:(et.right-S.right+$.right)/tt.x}}var Ns=s=>({name:"arrow",options:s,async fn(i){let{x:t,y:e,placement:r,rects:a,platform:n,elements:d,middlewareData:h}=i,{element:u,padding:f=0}=Se(s,i)||{};if(u==null)return{};let b=zr(f),k={x:t,y:e},x=ji(r),$=Ki(x),z=await n.getDimensions(u),P=x==="y",S=P?"top":"left",q=P?"bottom":"right",K=P?"clientHeight":"clientWidth",tt=a.reference[$]+a.reference[x]-k[x]-a.floating[$],et=k[x]-a.reference[x],Vt=await(n.getOffsetParent==null?void 0:n.getOffsetParent(u)),gt=Vt?Vt[K]:0;(!gt||!await(n.isElement==null?void 0:n.isElement(Vt)))&&(gt=d.floating[K]||a.floating[$]);let oe=tt/2-et/2,Qt=gt/2-z[$]/2-1,Rt=ie(b[S],Qt),fe=ie(b[q],Qt),Jt=Rt,be=gt-z[$]-fe,At=gt/2-z[$]/2+oe,Ut=qi(Jt,At,be),Re=!h.arrow&&He(r)!=null&&At!==Ut&&a.reference[$]/2-(At<Jt?Rt:fe)-z[$]/2<0,ae=Re?At<Jt?At-Jt:At-be:0;return{[x]:k[x]+ae,data:M({[x]:Ut,centerOffset:At-Ut-ae},Re&&{alignmentOffset:ae}),reset:Re}}});var qs=function(s){return s===void 0&&(s={}),{name:"flip",options:s,async fn(i){var t,e;let{placement:r,middlewareData:a,rects:n,initialPlacement:d,platform:h,elements:u}=i,At=Se(s,i),{mainAxis:f=!0,crossAxis:b=!0,fallbackPlacements:k,fallbackStrategy:x="bestFit",fallbackAxisSideDirection:$="none",flipAlignment:z=!0}=At,P=xi(At,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((t=a.arrow)!=null&&t.alignmentOffset)return{};let S=pe(r),q=Ce(d),K=pe(d)===d,tt=await(h.isRTL==null?void 0:h.isRTL(u.floating)),et=k||(K||!z?[pi(d)]:Bs(d)),Vt=$!=="none";!k&&Vt&&et.push(...Vs(d,z,$,tt));let gt=[d,...et],oe=await Yi(i,P),Qt=[],Rt=((e=a.flip)==null?void 0:e.overflows)||[];if(f&&Qt.push(oe[S]),b){let Ut=Fs(r,n,tt);Qt.push(oe[Ut[0]],oe[Ut[1]])}if(Rt=[...Rt,{placement:r,overflows:Qt}],!Qt.every(Ut=>Ut<=0)){var fe,Jt;let Ut=(((fe=a.flip)==null?void 0:fe.index)||0)+1,Re=gt[Ut];if(Re)return{data:{index:Ut,overflows:Rt},reset:{placement:Re}};let ae=(Jt=Rt.filter(Ue=>Ue.overflows[0]<=0).sort((Ue,ge)=>Ue.overflows[1]-ge.overflows[1])[0])==null?void 0:Jt.placement;if(!ae)switch(x){case"bestFit":{var be;let Ue=(be=Rt.filter(ge=>{if(Vt){let ve=Ce(ge.placement);return ve===q||ve==="y"}return!0}).map(ge=>[ge.placement,ge.overflows.filter(ve=>ve>0).reduce((ve,yo)=>ve+yo,0)]).sort((ge,ve)=>ge[1]-ve[1])[0])==null?void 0:be[0];Ue&&(ae=Ue);break}case"initialPlacement":ae=d;break}if(r!==ae)return{reset:{placement:ae}}}return{}}}};async function Kn(s,i){let{placement:t,platform:e,elements:r}=s,a=await(e.isRTL==null?void 0:e.isRTL(r.floating)),n=pe(t),d=He(t),h=Ce(t)==="y",u=["left","top"].includes(n)?-1:1,f=a&&h?-1:1,b=Se(i,s),{mainAxis:k,crossAxis:x,alignmentAxis:$}=typeof b=="number"?{mainAxis:b,crossAxis:0,alignmentAxis:null}:{mainAxis:b.mainAxis||0,crossAxis:b.crossAxis||0,alignmentAxis:b.alignmentAxis};return d&&typeof $=="number"&&(x=d==="end"?$*-1:$),h?{x:x*f,y:k*u}:{x:k*u,y:x*f}}var Ks=function(s){return s===void 0&&(s=0),{name:"offset",options:s,async fn(i){var t,e;let{x:r,y:a,placement:n,middlewareData:d}=i,h=await Kn(i,s);return n===((t=d.offset)==null?void 0:t.placement)&&(e=d.arrow)!=null&&e.alignmentOffset?{}:{x:r+h.x,y:a+h.y,data:rt(M({},h),{placement:n})}}}},js=function(s){return s===void 0&&(s={}),{name:"shift",options:s,async fn(i){let{x:t,y:e,placement:r}=i,P=Se(s,i),{mainAxis:a=!0,crossAxis:n=!1,limiter:d={fn:S=>{let{x:q,y:K}=S;return{x:q,y:K}}}}=P,h=xi(P,["mainAxis","crossAxis","limiter"]),u={x:t,y:e},f=await Yi(i,h),b=Ce(pe(r)),k=Lr(b),x=u[k],$=u[b];if(a){let S=k==="y"?"top":"left",q=k==="y"?"bottom":"right",K=x+f[S],tt=x-f[q];x=qi(K,x,tt)}if(n){let S=b==="y"?"top":"left",q=b==="y"?"bottom":"right",K=$+f[S],tt=$-f[q];$=qi(K,$,tt)}let z=d.fn(rt(M({},i),{[k]:x,[b]:$}));return rt(M({},z),{data:{x:z.x-t,y:z.y-e,enabled:{[k]:a,[b]:n}}})}}};var Ys=function(s){return s===void 0&&(s={}),{name:"size",options:s,async fn(i){var t,e;let{placement:r,rects:a,platform:n,elements:d}=i,Rt=Se(s,i),{apply:h=()=>{}}=Rt,u=xi(Rt,["apply"]),f=await Yi(i,u),b=pe(r),k=He(r),x=Ce(r)==="y",{width:$,height:z}=a.floating,P,S;b==="top"||b==="bottom"?(P=b,S=k===(await(n.isRTL==null?void 0:n.isRTL(d.floating))?"start":"end")?"left":"right"):(S=b,P=k==="end"?"top":"bottom");let q=z-f.top-f.bottom,K=$-f.left-f.right,tt=ie(z-f[P],q),et=ie($-f[S],K),Vt=!i.middlewareData.shift,gt=tt,oe=et;if((t=i.middlewareData.shift)!=null&&t.enabled.x&&(oe=K),(e=i.middlewareData.shift)!=null&&e.enabled.y&&(gt=q),Vt&&!k){let fe=xt(f.left,0),Jt=xt(f.right,0),be=xt(f.top,0),At=xt(f.bottom,0);x?oe=$-2*(fe!==0||Jt!==0?fe+Jt:xt(f.left,f.right)):gt=z-2*(be!==0||At!==0?be+At:xt(f.top,f.bottom))}await h(rt(M({},i),{availableWidth:oe,availableHeight:gt}));let Qt=await n.getDimensions(d.floating);return $!==Qt.width||z!==Qt.height?{reset:{rects:!0}}:{}}}};function Zi(){return typeof window!="undefined"}function Pe(s){return Xs(s)?(s.nodeName||"").toLowerCase():"#document"}function Tt(s){var i;return(s==null||(i=s.ownerDocument)==null?void 0:i.defaultView)||window}function jt(s){var i;return(i=(Xs(s)?s.ownerDocument:s.document)||window.document)==null?void 0:i.documentElement}function Xs(s){return Zi()?s instanceof Node||s instanceof Tt(s).Node:!1}function It(s){return Zi()?s instanceof Element||s instanceof Tt(s).Element:!1}function Yt(s){return Zi()?s instanceof HTMLElement||s instanceof Tt(s).HTMLElement:!1}function Zs(s){return!Zi()||typeof ShadowRoot=="undefined"?!1:s instanceof ShadowRoot||s instanceof Tt(s).ShadowRoot}function Xe(s){let{overflow:i,overflowX:t,overflowY:e,display:r}=Pt(s);return/auto|scroll|overlay|hidden|clip/.test(i+e+t)&&!["inline","contents"].includes(r)}function Ws(s){return["table","td","th"].includes(Pe(s))}function fi(s){return[":popover-open",":modal"].some(i=>{try{return s.matches(i)}catch(t){return!1}})}function Xi(s){let i=Wi(),t=It(s)?Pt(s):s;return["transform","translate","scale","rotate","perspective"].some(e=>t[e]?t[e]!=="none":!1)||(t.containerType?t.containerType!=="normal":!1)||!i&&(t.backdropFilter?t.backdropFilter!=="none":!1)||!i&&(t.filter?t.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(e=>(t.willChange||"").includes(e))||["paint","layout","strict","content"].some(e=>(t.contain||"").includes(e))}function Qs(s){let i=ue(s);for(;Yt(i)&&!Fe(i);){if(Xi(i))return i;if(fi(i))return null;i=ue(i)}return null}function Wi(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Fe(s){return["html","body","#document"].includes(Pe(s))}function Pt(s){return Tt(s).getComputedStyle(s)}function bi(s){return It(s)?{scrollLeft:s.scrollLeft,scrollTop:s.scrollTop}:{scrollLeft:s.scrollX,scrollTop:s.scrollY}}function ue(s){if(Pe(s)==="html")return s;let i=s.assignedSlot||s.parentNode||Zs(s)&&s.host||jt(s);return Zs(i)?i.host:i}function Js(s){let i=ue(s);return Fe(i)?s.ownerDocument?s.ownerDocument.body:s.body:Yt(i)&&Xe(i)?i:Js(i)}function Ze(s,i,t){var e;i===void 0&&(i=[]),t===void 0&&(t=!0);let r=Js(s),a=r===((e=s.ownerDocument)==null?void 0:e.body),n=Tt(r);if(a){let d=Qi(n);return i.concat(n,n.visualViewport||[],Xe(r)?r:[],d&&t?Ze(d):[])}return i.concat(r,Ze(r,[],t))}function Qi(s){return s.parent&&Object.getPrototypeOf(s.parent)?s.frameElement:null}function eo(s){let i=Pt(s),t=parseFloat(i.width)||0,e=parseFloat(i.height)||0,r=Yt(s),a=r?s.offsetWidth:t,n=r?s.offsetHeight:e,d=ui(t)!==a||ui(e)!==n;return d&&(t=a,e=n),{width:t,height:e,$:d}}function Or(s){return It(s)?s:s.contextElement}function We(s){let i=Or(s);if(!Yt(i))return Kt(1);let t=i.getBoundingClientRect(),{width:e,height:r,$:a}=eo(i),n=(a?ui(t.width):t.width)/e,d=(a?ui(t.height):t.height)/r;return(!n||!Number.isFinite(n))&&(n=1),(!d||!Number.isFinite(d))&&(d=1),{x:n,y:d}}var jn=Kt(0);function io(s){let i=Tt(s);return!Wi()||!i.visualViewport?jn:{x:i.visualViewport.offsetLeft,y:i.visualViewport.offsetTop}}function Yn(s,i,t){return i===void 0&&(i=!1),!t||i&&t!==Tt(s)?!1:i}function Be(s,i,t,e){i===void 0&&(i=!1),t===void 0&&(t=!1);let r=s.getBoundingClientRect(),a=Or(s),n=Kt(1);i&&(e?It(e)&&(n=We(e)):n=We(s));let d=Yn(a,t,e)?io(a):Kt(0),h=(r.left+d.x)/n.x,u=(r.top+d.y)/n.y,f=r.width/n.x,b=r.height/n.y;if(a){let k=Tt(a),x=e&&It(e)?Tt(e):e,$=k,z=Qi($);for(;z&&e&&x!==$;){let P=We(z),S=z.getBoundingClientRect(),q=Pt(z),K=S.left+(z.clientLeft+parseFloat(q.paddingLeft))*P.x,tt=S.top+(z.clientTop+parseFloat(q.paddingTop))*P.y;h*=P.x,u*=P.y,f*=P.x,b*=P.y,h+=K,u+=tt,$=Tt(z),z=Qi($)}}return Ie({width:f,height:b,x:h,y:u})}function Mr(s,i){let t=bi(s).scrollLeft;return i?i.left+t:Be(jt(s)).left+t}function ro(s,i,t){t===void 0&&(t=!1);let e=s.getBoundingClientRect(),r=e.left+i.scrollLeft-(t?0:Mr(s,e)),a=e.top+i.scrollTop;return{x:r,y:a}}function Zn(s){let{elements:i,rect:t,offsetParent:e,strategy:r}=s,a=r==="fixed",n=jt(e),d=i?fi(i.floating):!1;if(e===n||d&&a)return t;let h={scrollLeft:0,scrollTop:0},u=Kt(1),f=Kt(0),b=Yt(e);if((b||!b&&!a)&&((Pe(e)!=="body"||Xe(n))&&(h=bi(e)),Yt(e))){let x=Be(e);u=We(e),f.x=x.x+e.clientLeft,f.y=x.y+e.clientTop}let k=n&&!b&&!a?ro(n,h,!0):Kt(0);return{width:t.width*u.x,height:t.height*u.y,x:t.x*u.x-h.scrollLeft*u.x+f.x+k.x,y:t.y*u.y-h.scrollTop*u.y+f.y+k.y}}function Xn(s){return Array.from(s.getClientRects())}function Wn(s){let i=jt(s),t=bi(s),e=s.ownerDocument.body,r=xt(i.scrollWidth,i.clientWidth,e.scrollWidth,e.clientWidth),a=xt(i.scrollHeight,i.clientHeight,e.scrollHeight,e.clientHeight),n=-t.scrollLeft+Mr(s),d=-t.scrollTop;return Pt(e).direction==="rtl"&&(n+=xt(i.clientWidth,e.clientWidth)-r),{width:r,height:a,x:n,y:d}}function Qn(s,i){let t=Tt(s),e=jt(s),r=t.visualViewport,a=e.clientWidth,n=e.clientHeight,d=0,h=0;if(r){a=r.width,n=r.height;let u=Wi();(!u||u&&i==="fixed")&&(d=r.offsetLeft,h=r.offsetTop)}return{width:a,height:n,x:d,y:h}}function Jn(s,i){let t=Be(s,!0,i==="fixed"),e=t.top+s.clientTop,r=t.left+s.clientLeft,a=Yt(s)?We(s):Kt(1),n=s.clientWidth*a.x,d=s.clientHeight*a.y,h=r*a.x,u=e*a.y;return{width:n,height:d,x:h,y:u}}function Gs(s,i,t){let e;if(i==="viewport")e=Qn(s,t);else if(i==="document")e=Wn(jt(s));else if(It(i))e=Jn(i,t);else{let r=io(s);e={x:i.x-r.x,y:i.y-r.y,width:i.width,height:i.height}}return Ie(e)}function so(s,i){let t=ue(s);return t===i||!It(t)||Fe(t)?!1:Pt(t).position==="fixed"||so(t,i)}function Gn(s,i){let t=i.get(s);if(t)return t;let e=Ze(s,[],!1).filter(d=>It(d)&&Pe(d)!=="body"),r=null,a=Pt(s).position==="fixed",n=a?ue(s):s;for(;It(n)&&!Fe(n);){let d=Pt(n),h=Xi(n);!h&&d.position==="fixed"&&(r=null),(a?!h&&!r:!h&&d.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||Xe(n)&&!h&&so(s,n))?e=e.filter(f=>f!==n):r=d,n=ue(n)}return i.set(s,e),e}function tl(s){let{element:i,boundary:t,rootBoundary:e,strategy:r}=s,n=[...t==="clippingAncestors"?fi(i)?[]:Gn(i,this._c):[].concat(t),e],d=n[0],h=n.reduce((u,f)=>{let b=Gs(i,f,r);return u.top=xt(b.top,u.top),u.right=ie(b.right,u.right),u.bottom=ie(b.bottom,u.bottom),u.left=xt(b.left,u.left),u},Gs(i,d,r));return{width:h.right-h.left,height:h.bottom-h.top,x:h.left,y:h.top}}function el(s){let{width:i,height:t}=eo(s);return{width:i,height:t}}function il(s,i,t){let e=Yt(i),r=jt(i),a=t==="fixed",n=Be(s,!0,a,i),d={scrollLeft:0,scrollTop:0},h=Kt(0);if(e||!e&&!a)if((Pe(i)!=="body"||Xe(r))&&(d=bi(i)),e){let k=Be(i,!0,a,i);h.x=k.x+i.clientLeft,h.y=k.y+i.clientTop}else r&&(h.x=Mr(r));let u=r&&!e&&!a?ro(r,d):Kt(0),f=n.left+d.scrollLeft-h.x-u.x,b=n.top+d.scrollTop-h.y-u.y;return{x:f,y:b,width:n.width,height:n.height}}function Ar(s){return Pt(s).position==="static"}function to(s,i){if(!Yt(s)||Pt(s).position==="fixed")return null;if(i)return i(s);let t=s.offsetParent;return jt(s)===t&&(t=t.ownerDocument.body),t}function oo(s,i){let t=Tt(s);if(fi(s))return t;if(!Yt(s)){let r=ue(s);for(;r&&!Fe(r);){if(It(r)&&!Ar(r))return r;r=ue(r)}return t}let e=to(s,i);for(;e&&Ws(e)&&Ar(e);)e=to(e,i);return e&&Fe(e)&&Ar(e)&&!Xi(e)?t:e||Qs(s)||t}var rl=async function(s){let i=this.getOffsetParent||oo,t=this.getDimensions,e=await t(s.floating);return{reference:il(s.reference,await i(s.floating),s.strategy),floating:{x:0,y:0,width:e.width,height:e.height}}};function sl(s){return Pt(s).direction==="rtl"}var ol={convertOffsetParentRelativeRectToViewportRelativeRect:Zn,getDocumentElement:jt,getClippingRect:tl,getOffsetParent:oo,getElementRects:rl,getClientRects:Xn,getDimensions:el,getScale:We,isElement:It,isRTL:sl};function ao(s,i){return s.x===i.x&&s.y===i.y&&s.width===i.width&&s.height===i.height}function al(s,i){let t=null,e,r=jt(s);function a(){var d;clearTimeout(e),(d=t)==null||d.disconnect(),t=null}function n(d,h){d===void 0&&(d=!1),h===void 0&&(h=1),a();let u=s.getBoundingClientRect(),{left:f,top:b,width:k,height:x}=u;if(d||i(),!k||!x)return;let $=mi(b),z=mi(r.clientWidth-(f+k)),P=mi(r.clientHeight-(b+x)),S=mi(f),K={rootMargin:-$+"px "+-z+"px "+-P+"px "+-S+"px",threshold:xt(0,ie(1,h))||1},tt=!0;function et(Vt){let gt=Vt[0].intersectionRatio;if(gt!==h){if(!tt)return n();gt?n(!1,gt):e=setTimeout(()=>{n(!1,1e-7)},1e3)}gt===1&&!ao(u,s.getBoundingClientRect())&&n(),tt=!1}try{t=new IntersectionObserver(et,rt(M({},K),{root:r.ownerDocument}))}catch(Vt){t=new IntersectionObserver(et,K)}t.observe(s)}return n(!0),a}function no(s,i,t,e){e===void 0&&(e={});let{ancestorScroll:r=!0,ancestorResize:a=!0,elementResize:n=typeof ResizeObserver=="function",layoutShift:d=typeof IntersectionObserver=="function",animationFrame:h=!1}=e,u=Or(s),f=r||a?[...u?Ze(u):[],...Ze(i)]:[];f.forEach(S=>{r&&S.addEventListener("scroll",t,{passive:!0}),a&&S.addEventListener("resize",t)});let b=u&&d?al(u,t):null,k=-1,x=null;n&&(x=new ResizeObserver(S=>{let[q]=S;q&&q.target===u&&x&&(x.unobserve(i),cancelAnimationFrame(k),k=requestAnimationFrame(()=>{var K;(K=x)==null||K.observe(i)})),t()}),u&&!h&&x.observe(u),x.observe(i));let $,z=h?Be(s):null;h&&P();function P(){let S=Be(s);z&&!ao(z,S)&&t(),z=S,$=requestAnimationFrame(P)}return t(),()=>{var S;f.forEach(q=>{r&&q.removeEventListener("scroll",t),a&&q.removeEventListener("resize",t)}),b==null||b(),(S=x)==null||S.disconnect(),x=null,h&&cancelAnimationFrame($)}}var lo=Ks;var co=js,ho=qs,Dr=Ys;var po=Ns;var uo=(s,i,t)=>{let e=new Map,r=M({platform:ol},t),a=rt(M({},r.platform),{_c:e});return Us(s,i,rt(M({},r),{platform:a}))};var I=class extends m{constructor(){super(...arguments);this.active=!1;this.placement="top";this.strategy="absolute";this.distance=0;this.skidding=0;this.arrow=!1;this.arrowPlacement="anchor";this.arrowPadding=10;this.flip=!1;this.flipFallbackPlacements="";this.flipFallbackStrategy="best-fit";this.flipPadding=0;this.shift=!1;this.shiftPadding=0;this.autoSizePadding=0}async connectedCallback(){super.connectedCallback(),await this.updateComplete,this.start(),this.setupMutationObserver()}disconnectedCallback(){this.stop(),this.mutationObserver&&this.mutationObserver.disconnect()}async updated(t){super.updated(t),t.has("active")&&(this.active?this.start():this.stop()),t.has("anchor")&&this.handleAnchorChange(),this.active&&(await this.updateComplete,this.reposition())}setupMutationObserver(){this.mutationObserver=new MutationObserver(e=>this.handleCurrentPlacementChange(e));let t={attributes:!0};this.mutationObserver.observe(this,t)}handleCurrentPlacementChange(t){return t.forEach(e=>{if(e.attributeName==="data-current-placement"){let r=this.getAttribute("data-current-placement");this.emit("sd-current-placement",{detail:r})}})}async handleAnchorChange(){if(await this.stop(),this.anchor&&typeof this.anchor=="string"){let t=this.getRootNode();this.anchorEl=t.getElementById(this.anchor)}else this.anchor instanceof HTMLElement?this.anchorEl=this.anchor:this.anchorEl=this.querySelector('[slot="anchor"]');if(this.anchorEl instanceof HTMLSlotElement&&(this.anchorEl=this.anchorEl.assignedElements({flatten:!0})[0]),!this.anchorEl)throw new Error("Invalid anchor element: no anchor could be found using the anchor slot or the anchor attribute.");this.start()}start(){this.anchorEl&&(this.cleanup=no(this.anchorEl,this.popup,()=>{this.reposition()}))}async stop(){return new Promise(t=>{this.cleanup?(this.cleanup(),this.cleanup=void 0,this.removeAttribute("data-current-placement"),this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height"),requestAnimationFrame(()=>t())):t()})}reposition(){if(!this.active||!this.anchorEl)return;let t=[lo({mainAxis:this.distance,crossAxis:this.skidding})];this.sync?t.push(Dr({apply:({rects:e})=>{let r=this.sync==="width"||this.sync==="both",a=this.sync==="height"||this.sync==="both";this.popup.style.width=r?`${e.reference.width}px`:"",this.popup.style.height=a?`${e.reference.height}px`:""}})):(this.popup.style.width="",this.popup.style.height=""),this.flip&&t.push(ho({boundary:this.flipBoundary,fallbackPlacements:this.flipFallbackPlacements,fallbackStrategy:this.flipFallbackStrategy==="best-fit"?"bestFit":"initialPlacement",padding:this.flipPadding})),this.shift&&t.push(co({boundary:this.shiftBoundary,padding:this.shiftPadding})),this.autoSize?t.push(Dr({boundary:this.autoSizeBoundary,padding:this.autoSizePadding,apply:({availableWidth:e,availableHeight:r})=>{this.autoSize==="vertical"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-height",`${r}px`):this.style.removeProperty("--auto-size-available-height"),this.autoSize==="horizontal"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-width",`${e}px`):this.style.removeProperty("--auto-size-available-width")}})):(this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height")),this.arrow&&t.push(po({element:this.arrowEl,padding:this.arrowPadding})),uo(this.anchorEl,this.popup,{placement:this.placement,middleware:t,strategy:this.strategy}).then(({x:e,y:r,middlewareData:a,placement:n})=>{let d=getComputedStyle(this).direction==="rtl",h={top:"bottom",right:"left",bottom:"top",left:"right"}[n.split("-")[0]];if(this.setAttribute("data-current-placement",n),Object.assign(this.popup.style,{left:`${e}px`,top:`${r}px`}),this.arrow){let u=a.arrow.x,f=a.arrow.y,b="",k="",x="",$="";if(this.arrowPlacement==="start"){let z=typeof u=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";b=typeof f=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"",k=d?z:"",$=d?"":z}else if(this.arrowPlacement==="end"){let z=typeof u=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";k=d?"":z,$=d?z:"",x=typeof f=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:""}else this.arrowPlacement==="center"?($=typeof u=="number"?"calc(50% - var(--arrow-size-diagonal))":"",b=typeof f=="number"?"calc(50% - var(--arrow-size-diagonal))":""):($=typeof u=="number"?`${u}px`:"",b=typeof f=="number"?`${f}px`:"");Object.assign(this.arrowEl.style,{top:b,right:k,bottom:x,left:$,[h]:"calc(var(--arrow-size-diagonal) * -1)"})}}),this.emit("sd-reposition")}render(){return p`<slot name="anchor" @slotchange="${this.handleAnchorChange}"></slot><div part="popup" class="${c("isolate",this.strategy!=="fixed"?"absolute":"fixed",!this.active&&"hidden")}"><slot></slot>${this.arrow?p`<div part="arrow" class="absolute rotate-45 -z-10" role="presentation"></div>`:""}</div>`}};I.styles=[...m.styles,v`:host{--arrow-color:var(--sd-color-neutral-1000);--arrow-size:6px;--arrow-size-diagonal:calc(var(--arrow-size)*0.7071);--arrow-padding-offset:calc(var(--arrow-size-diagonal) - var(--arrow-size));display:contents}[part=popup]{max-height:var(--auto-size-available-height,none);max-width:var(--auto-size-available-width,none)}[part=arrow]{background:var(--arrow-color);height:calc(var(--arrow-size-diagonal)*2);width:calc(var(--arrow-size-diagonal)*2)}`],o([g('[part="popup"]')],I.prototype,"popup",2),o([g('[part="arrow"]')],I.prototype,"arrowEl",2),o([l()],I.prototype,"anchor",2),o([l({type:Boolean,reflect:!0})],I.prototype,"active",2),o([l({reflect:!0})],I.prototype,"placement",2),o([l({reflect:!0})],I.prototype,"strategy",2),o([l({type:Number})],I.prototype,"distance",2),o([l({type:Number})],I.prototype,"skidding",2),o([l({type:Boolean})],I.prototype,"arrow",2),o([l({attribute:"arrow-placement"})],I.prototype,"arrowPlacement",2),o([l({attribute:"arrow-padding",type:Number})],I.prototype,"arrowPadding",2),o([l({type:Boolean})],I.prototype,"flip",2),o([l({attribute:"flip-fallback-placements",converter:{fromAttribute:t=>t.split(" ").map(e=>e.trim()).filter(e=>e!==""),toAttribute:t=>t.join(" ")}})],I.prototype,"flipFallbackPlacements",2),o([l({attribute:"flip-fallback-strategy"})],I.prototype,"flipFallbackStrategy",2),o([l({type:Object})],I.prototype,"flipBoundary",2),o([l({attribute:"flip-padding",type:Number})],I.prototype,"flipPadding",2),o([l({type:Boolean})],I.prototype,"shift",2),o([l({type:Object})],I.prototype,"shiftBoundary",2),o([l({attribute:"shift-padding",type:Number})],I.prototype,"shiftPadding",2),o([l({attribute:"auto-size"})],I.prototype,"autoSize",2),o([l()],I.prototype,"sync",2),o([l({type:Object})],I.prototype,"autoSizeBoundary",2),o([l({attribute:"auto-size-padding",type:Number})],I.prototype,"autoSizePadding",2),I=o([y("sd-popup")],I);var st=class extends m{constructor(){super(...arguments);this.size="lg";this.selected=!1;this.toggleable=!1;this.removable=!1;this.disabled=!1;this.href=""}handleBlur(){this.emit("sd-blur")}handleFocus(){this.emit("sd-focus")}handleRemoveClick(){this.emit("sd-remove")}isLink(){return!!this.href}click(){this.tag.click()}focus(t){this.tag.focus(t)}blur(){this.tag.blur()}render(){let t=this.isLink(),e=t?X`a`:X`button`;return F`<${e} part="base" type="${E(t?void 0:"button")}" href="${E(t?this.href:void 0)}" rel="${E(t&&this.target?"noreferrer noopener":void 0)}" target="${E(t?this.target:void 0)}" download="${E(t?this.download:void 0)}" ?disabled="${E(t?void 0:this.disabled)}" aria-disabled="${this.disabled?"true":"false"}" aria-pressed="${E(this.toggleable?this.selected:void 0)}" tabindex="${this.disabled?"-1":"0"}" @blur="${this.handleBlur}" @focus="${this.handleFocus}" class="${c("inline-flex border box-border rounded-full items-center leading-none whitespace-nowrap focus-visible:focus-outline",{lg:"h-8 text-base gap-2",sm:"h-6 text-sm gap-1"}[this.size],{lg:this.removable?"pl-4 pr-3 py-2":"px-4 py-2",sm:this.removable?"pl-3 pr-2 py-2":"px-3 py-[5px]"}[this.size],this.selected?"bg-primary border-primary text-white hover:bg-primary-500 hover:border-primary-500 disabled:bg-neutral-500 disabled:border-neutral-500":"border-primary text-primary hover:border-primary-500 hover:bg-neutral-100 hover:text-primary-500 disabled:border-neutral-500 disabled:text-neutral-500",this.disabled&&!t&&"cursor-not-allowed")}"><slot part="content"></slot>${this.removable?F`<slot part="removable-indicator" name="removable-indicator" @click="${this.handleRemoveClick}" class="${c({lg:"text-base",sm:"text-[12px]"}[this.size])}"><sd-icon library="system" name="close" label="remove"></sd-icon></slot>`:""}</${e}>`}};st.styles=[...m.styles,v`:host{display:inline-block}`],o([g("a, button")],st.prototype,"tag",2),o([l({reflect:!0})],st.prototype,"size",2),o([l({type:Boolean,reflect:!0})],st.prototype,"selected",2),o([l({type:Boolean,reflect:!0})],st.prototype,"toggleable",2),o([l({type:Boolean,reflect:!0})],st.prototype,"removable",2),o([l({type:Boolean,reflect:!0})],st.prototype,"disabled",2),o([l()],st.prototype,"href",2),o([l()],st.prototype,"target",2),o([l()],st.prototype,"download",2),st=o([y("sd-tag")],st);var T=class extends m{constructor(){super(...arguments);this.formControlController=new pt(this,{assumeInteractionOn:["sd-blur","sd-input"]});this.hasSlotController=new D(this,"help-text","label");this.localize=new _(this);this.hasHover=!1;this.hasFocus=!1;this.displayInputValue="";this.selectedTextLabel="";this.selectedOptions=[];this.filteredOptions=[];this.allOptions=[];this.showValidStyle=!1;this.showInvalidStyle=!1;this.name="";this.value="";this.defaultValue="";this.size="lg";this.placeholder="";this.maxOptionsTagLabel="";this.disabled=!1;this.visuallyDisabled=!1;this.clearable=!1;this.open=!1;this.hoist=!1;this.label="";this.placement="bottom";this.helpText="";this.form="";this.required=!1;this.currentPlacement=this.placement;this.getOption=Ss;this.multiple=!1;this.useTags=!0;this.maxOptionsVisible=3;this.styleOnValid=!1;this.filter=(t,e)=>{let r=Ui(t.value),a=Ui(t.getTextLabel()),n=Ui(e);return r.includes(n)||a.includes(n)};this.getTag=t=>p`<sd-tag ?disabled="${this.disabled}" part="tag" exportparts="
112
112
  base:tag__base,
@@ -1 +1 @@
1
- import{a as Z}from"./chunks/chunk.CEVVDV52.js";import"./chunks/chunk.HAL7R4WT.js";import{a as q}from"./chunks/chunk.F45IDVYA.js";import{a as y}from"./chunks/chunk.JDSUZDP4.js";import{a as z}from"./chunks/chunk.WMV7GLXF.js";import{a as J}from"./chunks/chunk.RCLIOOS5.js";import{a as K}from"./chunks/chunk.2HJF2D4H.js";import{a as U}from"./chunks/chunk.RGJXEMYT.js";import{a as E}from"./chunks/chunk.LET4FMBB.js";import{a as F}from"./chunks/chunk.KLNBBP4R.js";import{a as H}from"./chunks/chunk.HKGBSLKX.js";import{a as L}from"./chunks/chunk.NLOKZURD.js";import{a as Q}from"./chunks/chunk.V3YHI2G2.js";import{a as V}from"./chunks/chunk.DDLTKNEO.js";import{a as j}from"./chunks/chunk.ZVVSLR3B.js";import{a as w}from"./chunks/chunk.O3IRROA2.js";import{a as R}from"./chunks/chunk.WUTY672B.js";import{a as M}from"./chunks/chunk.Y4PTSCEB.js";import{a as v}from"./chunks/chunk.5TTHL3M2.js";import{a as O}from"./chunks/chunk.BWMHPT4Y.js";import{a as P}from"./chunks/chunk.CNGIUOE5.js";import{a as N}from"./chunks/chunk.NOJV6ZZF.js";import{a as I}from"./chunks/chunk.43NFQGWL.js";import{a as h}from"./chunks/chunk.I2WEQVU3.js";import{a as A}from"./chunks/chunk.KWNRVZ54.js";import{a as B}from"./chunks/chunk.4QAJB6AU.js";import{a as D}from"./chunks/chunk.KV424MMD.js";import{a as g}from"./chunks/chunk.SDZ6E4CH.js";import{a as k}from"./chunks/chunk.PDIUABFP.js";import{a as C}from"./chunks/chunk.LKO4ZRE7.js";import{a as G}from"./chunks/chunk.VZSFEHBE.js";import{a as m}from"./chunks/chunk.247MZWMU.js";import"./chunks/chunk.5CK64GWQ.js";import{a as S}from"./chunks/chunk.WJ55QSS3.js";import{a as n}from"./chunks/chunk.2BLQ3VDT.js";import{a as i}from"./chunks/chunk.FVXID42E.js";import{a as s}from"./chunks/chunk.E5FCRWHS.js";import"./chunks/chunk.D7TMPF3D.js";import"./chunks/chunk.X2GM34WQ.js";import"./chunks/chunk.W7A3TU2Z.js";import{a as c}from"./chunks/chunk.QWMQJ6TF.js";import{a as b}from"./chunks/chunk.IUC5UQ2V.js";import{a as T}from"./chunks/chunk.777DWZOA.js";import"./chunks/chunk.X2O263YD.js";import"./chunks/chunk.64UNKF45.js";import"./chunks/chunk.3L472FD4.js";import{a as d}from"./chunks/chunk.BHWV44KN.js";import{a as f}from"./chunks/chunk.NZT4ORYP.js";import{a as u}from"./chunks/chunk.ZN24IDXT.js";import{a as p}from"./chunks/chunk.DLY5AX2P.js";import"./chunks/chunk.65NSSTJE.js";import"./chunks/chunk.HE2LNCWW.js";import"./chunks/chunk.JCNKLGIS.js";import{a as x}from"./chunks/chunk.NER6LFUE.js";import"./chunks/chunk.CBQWVOOS.js";import"./chunks/chunk.EUGX6XW6.js";import"./chunks/chunk.MHWW3RZB.js";import{a as l}from"./chunks/chunk.NFQN6UG4.js";import{a}from"./chunks/chunk.XYZ5DKTA.js";import{a as e}from"./chunks/chunk.ONLECFTO.js";import"./chunks/chunk.A3DKF5BY.js";import"./chunks/chunk.5ZILM4TA.js";import{b as o}from"./chunks/chunk.7TRFUW6U.js";import"./chunks/chunk.SPDB3L7V.js";import{d as W,e as X}from"./chunks/chunk.SNS2IHBI.js";import"./chunks/chunk.TWZDCIM2.js";import"./chunks/chunk.MWDEA25W.js";import"./chunks/chunk.K7HF3VBZ.js";import"./chunks/chunk.PYHYYOBE.js";import"./chunks/chunk.EFLL7VXU.js";import"./chunks/chunk.RQYP7MH5.js";import"./chunks/chunk.KLRPP4NQ.js";import{a as t}from"./chunks/chunk.FHU3KJ7Y.js";import"./chunks/chunk.E2DRD2OX.js";import"./chunks/chunk.XR2KNB36.js";import{a as r}from"./chunks/chunk.PGBIGG5I.js";import"./chunks/chunk.6HO6CE4A.js";import{a as Y}from"./chunks/chunk.TNPIUMKG.js";import"./chunks/chunk.LO4SY63J.js";import"./chunks/chunk.O3CT4L2X.js";import"./chunks/chunk.HJGLYEWV.js";import"./chunks/chunk.26V4EXHB.js";import"./chunks/chunk.5AILWWY2.js";import"./chunks/chunk.IRWHG2Q4.js";import"./chunks/chunk.WNP2V63C.js";import"./chunks/chunk.TJOCV4DC.js";export{Y as LocalizeController,e as SdAccordion,a as SdAccordionGroup,t as SdAnimation,r as SdAudio,d as SdBadge,f as SdBrandshape,u as SdButton,x as SdCarousel,l as SdCarouselItem,m as SdCheckbox,S as SdCheckboxGroup,n as SdCombobox,c as SdDialog,b as SdDivider,T as SdDrawer,g as SdDropdown,k as SdExpandable,C as SdFlipcard,G as SdHeader,o as SdIcon,I as SdInclude,h as SdInput,A as SdLink,B as SdMapMarker,D as SdNavigationItem,w as SdNotification,R as SdOptgroup,M as SdOption,s as SdPopup,v as SdQuickfact,N as SdRadio,O as SdRadioButton,P as SdRadioGroup,E as SdScrollable,F as SdSelect,p as SdSpinner,H as SdStep,L as SdStepGroup,Q as SdSwitch,V as SdTab,j as SdTabGroup,q as SdTabPanel,i as SdTag,y as SdTeaser,z as SdTeaserMedia,J as SdTextarea,K as SdTooltip,U as SdVideo,W as registerIconLibrary,Z as setupAutocomplete,X as unregisterIconLibrary};
1
+ import{a as Z}from"./chunks/chunk.CEVVDV52.js";import"./chunks/chunk.HAL7R4WT.js";import{a as q}from"./chunks/chunk.F45IDVYA.js";import{a as y}from"./chunks/chunk.JDSUZDP4.js";import{a as z}from"./chunks/chunk.WMV7GLXF.js";import{a as J}from"./chunks/chunk.RCLIOOS5.js";import{a as K}from"./chunks/chunk.2HJF2D4H.js";import{a as U}from"./chunks/chunk.RGJXEMYT.js";import{a as E}from"./chunks/chunk.LET4FMBB.js";import{a as F}from"./chunks/chunk.KLNBBP4R.js";import{a as H}from"./chunks/chunk.HKGBSLKX.js";import{a as L}from"./chunks/chunk.NLOKZURD.js";import{a as Q}from"./chunks/chunk.V3YHI2G2.js";import{a as V}from"./chunks/chunk.DDLTKNEO.js";import{a as j}from"./chunks/chunk.ZVVSLR3B.js";import{a as w}from"./chunks/chunk.O3IRROA2.js";import{a as R}from"./chunks/chunk.WUTY672B.js";import{a as M}from"./chunks/chunk.Y4PTSCEB.js";import{a as v}from"./chunks/chunk.5TTHL3M2.js";import{a as O}from"./chunks/chunk.BWMHPT4Y.js";import{a as P}from"./chunks/chunk.CNGIUOE5.js";import{a as N}from"./chunks/chunk.NOJV6ZZF.js";import{a as I}from"./chunks/chunk.43NFQGWL.js";import{a as h}from"./chunks/chunk.I2WEQVU3.js";import{a as A}from"./chunks/chunk.KWNRVZ54.js";import{a as B}from"./chunks/chunk.4QAJB6AU.js";import{a as D}from"./chunks/chunk.KV424MMD.js";import{a as g}from"./chunks/chunk.SDZ6E4CH.js";import{a as k}from"./chunks/chunk.PDIUABFP.js";import{a as C}from"./chunks/chunk.LKO4ZRE7.js";import{a as G}from"./chunks/chunk.VZSFEHBE.js";import{a as m}from"./chunks/chunk.247MZWMU.js";import"./chunks/chunk.5CK64GWQ.js";import{a as S}from"./chunks/chunk.WJ55QSS3.js";import{a as n}from"./chunks/chunk.2BLQ3VDT.js";import{a as i}from"./chunks/chunk.FVXID42E.js";import{a as s}from"./chunks/chunk.E5FCRWHS.js";import"./chunks/chunk.D7TMPF3D.js";import"./chunks/chunk.X2GM34WQ.js";import"./chunks/chunk.W7A3TU2Z.js";import{a as c}from"./chunks/chunk.QWMQJ6TF.js";import{a as b}from"./chunks/chunk.IUC5UQ2V.js";import{a as T}from"./chunks/chunk.777DWZOA.js";import"./chunks/chunk.X2O263YD.js";import"./chunks/chunk.64UNKF45.js";import"./chunks/chunk.3L472FD4.js";import{a as d}from"./chunks/chunk.BHWV44KN.js";import{a as f}from"./chunks/chunk.NZT4ORYP.js";import{a as u}from"./chunks/chunk.ZN24IDXT.js";import{a as p}from"./chunks/chunk.DLY5AX2P.js";import"./chunks/chunk.65NSSTJE.js";import"./chunks/chunk.HE2LNCWW.js";import"./chunks/chunk.JCNKLGIS.js";import{a as x}from"./chunks/chunk.5YWPH3S7.js";import"./chunks/chunk.CBQWVOOS.js";import"./chunks/chunk.EUGX6XW6.js";import"./chunks/chunk.MHWW3RZB.js";import{a as l}from"./chunks/chunk.NFQN6UG4.js";import{a}from"./chunks/chunk.XYZ5DKTA.js";import{a as e}from"./chunks/chunk.ONLECFTO.js";import"./chunks/chunk.A3DKF5BY.js";import"./chunks/chunk.5ZILM4TA.js";import{b as o}from"./chunks/chunk.7TRFUW6U.js";import"./chunks/chunk.SPDB3L7V.js";import{d as W,e as X}from"./chunks/chunk.SNS2IHBI.js";import"./chunks/chunk.TWZDCIM2.js";import"./chunks/chunk.MWDEA25W.js";import"./chunks/chunk.K7HF3VBZ.js";import"./chunks/chunk.PYHYYOBE.js";import"./chunks/chunk.EFLL7VXU.js";import"./chunks/chunk.RQYP7MH5.js";import"./chunks/chunk.KLRPP4NQ.js";import{a as t}from"./chunks/chunk.FHU3KJ7Y.js";import"./chunks/chunk.E2DRD2OX.js";import"./chunks/chunk.XR2KNB36.js";import{a as r}from"./chunks/chunk.PGBIGG5I.js";import"./chunks/chunk.6HO6CE4A.js";import{a as Y}from"./chunks/chunk.TNPIUMKG.js";import"./chunks/chunk.LO4SY63J.js";import"./chunks/chunk.O3CT4L2X.js";import"./chunks/chunk.HJGLYEWV.js";import"./chunks/chunk.26V4EXHB.js";import"./chunks/chunk.5AILWWY2.js";import"./chunks/chunk.IRWHG2Q4.js";import"./chunks/chunk.WNP2V63C.js";import"./chunks/chunk.TJOCV4DC.js";export{Y as LocalizeController,e as SdAccordion,a as SdAccordionGroup,t as SdAnimation,r as SdAudio,d as SdBadge,f as SdBrandshape,u as SdButton,x as SdCarousel,l as SdCarouselItem,m as SdCheckbox,S as SdCheckboxGroup,n as SdCombobox,c as SdDialog,b as SdDivider,T as SdDrawer,g as SdDropdown,k as SdExpandable,C as SdFlipcard,G as SdHeader,o as SdIcon,I as SdInclude,h as SdInput,A as SdLink,B as SdMapMarker,D as SdNavigationItem,w as SdNotification,R as SdOptgroup,M as SdOption,s as SdPopup,v as SdQuickfact,N as SdRadio,O as SdRadioButton,P as SdRadioGroup,E as SdScrollable,F as SdSelect,p as SdSpinner,H as SdStep,L as SdStepGroup,Q as SdSwitch,V as SdTab,j as SdTabGroup,q as SdTabPanel,i as SdTag,y as SdTeaser,z as SdTeaserMedia,J as SdTextarea,K as SdTooltip,U as SdVideo,W as registerIconLibrary,Z as setupAutocomplete,X as unregisterIconLibrary};
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json",
3
3
  "name": "@solid-design-system/components",
4
- "version": "4.3.0",
4
+ "version": "4.3.1",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -32,7 +32,7 @@ let SdMenu = class SdMenu extends SolidElement {
32
32
  if (item.type === 'checkbox') {
33
33
  item.checked = !item.checked;
34
34
  }
35
- this.emit('sd-4-3-0-select', { detail: { item } });
35
+ this.emit('sd-4-3-1-select', { detail: { item } });
36
36
  }
37
37
  handleKeyDown(event) {
38
38
  if (event.key === 'Enter') {