@solid-design-system/components 6.8.0 → 6.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (271) hide show
  1. package/cdn/chunks/{chunk.V4FZAAD4.js → chunk.MV77IJ5K.js} +4 -4
  2. package/cdn/components/combobox/combobox.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/chunks/chunk.25DRFJMC.js +2 -2
  9. package/cdn-versioned/chunks/chunk.2TRMFN6U.js +2 -2
  10. package/cdn-versioned/chunks/chunk.2VGJBR73.js +2 -2
  11. package/cdn-versioned/chunks/chunk.34BRLWBM.js +3 -3
  12. package/cdn-versioned/chunks/chunk.3M4RKO34.js +2 -2
  13. package/cdn-versioned/chunks/chunk.3VYZIXD7.js +2 -2
  14. package/cdn-versioned/chunks/chunk.3YATPZKE.js +1 -1
  15. package/cdn-versioned/chunks/chunk.4AR6H2QH.js +2 -2
  16. package/cdn-versioned/chunks/chunk.4BMBQGU3.js +2 -2
  17. package/cdn-versioned/chunks/chunk.4NKCD6HL.js +2 -2
  18. package/cdn-versioned/chunks/chunk.4YNC3XSD.js +2 -2
  19. package/cdn-versioned/chunks/chunk.6MUTKG7S.js +2 -2
  20. package/cdn-versioned/chunks/chunk.6UVLIGA7.js +1 -1
  21. package/cdn-versioned/chunks/chunk.6WZKUQIK.js +2 -2
  22. package/cdn-versioned/chunks/chunk.AAJIGG4R.js +2 -2
  23. package/cdn-versioned/chunks/chunk.AX6IEBJ2.js +2 -2
  24. package/cdn-versioned/chunks/chunk.B35GXAKI.js +1 -1
  25. package/cdn-versioned/chunks/chunk.CRLGS4QF.js +1 -1
  26. package/cdn-versioned/chunks/chunk.DLO5GMBQ.js +2 -2
  27. package/cdn-versioned/chunks/chunk.DTAYHASV.js +2 -2
  28. package/cdn-versioned/chunks/chunk.EDWO5QHC.js +2 -2
  29. package/cdn-versioned/chunks/chunk.EFO4PKGN.js +2 -2
  30. package/cdn-versioned/chunks/chunk.G4KULB76.js +2 -2
  31. package/cdn-versioned/chunks/chunk.GEGKRESG.js +1 -1
  32. package/cdn-versioned/chunks/chunk.GIP7V3SN.js +2 -2
  33. package/cdn-versioned/chunks/chunk.H3DQRUKN.js +2 -2
  34. package/cdn-versioned/chunks/chunk.HE5IYQC2.js +2 -2
  35. package/cdn-versioned/chunks/chunk.JAV26Y4S.js +2 -2
  36. package/cdn-versioned/chunks/chunk.JSZK2BUE.js +2 -2
  37. package/cdn-versioned/chunks/chunk.LBHLY2UU.js +2 -2
  38. package/cdn-versioned/chunks/chunk.LYNWHGS3.js +2 -2
  39. package/cdn-versioned/chunks/{chunk.V4FZAAD4.js → chunk.MV77IJ5K.js} +5 -5
  40. package/cdn-versioned/chunks/chunk.N3QINXLL.js +2 -2
  41. package/cdn-versioned/chunks/chunk.N7SVA6X3.js +2 -2
  42. package/cdn-versioned/chunks/chunk.NBPJQ3OT.js +2 -2
  43. package/cdn-versioned/chunks/chunk.O3ECZ2CR.js +1 -1
  44. package/cdn-versioned/chunks/chunk.O7PJIDMP.js +2 -2
  45. package/cdn-versioned/chunks/chunk.OJA4LU7S.js +2 -2
  46. package/cdn-versioned/chunks/chunk.PPLEJM75.js +1 -1
  47. package/cdn-versioned/chunks/chunk.PPUIAWDA.js +1 -1
  48. package/cdn-versioned/chunks/chunk.PWJSPZBR.js +3 -3
  49. package/cdn-versioned/chunks/chunk.RAP66B6O.js +1 -1
  50. package/cdn-versioned/chunks/chunk.RXKIZ2UI.js +2 -2
  51. package/cdn-versioned/chunks/chunk.RZLPP7DP.js +2 -2
  52. package/cdn-versioned/chunks/chunk.SA5SIXVH.js +1 -1
  53. package/cdn-versioned/chunks/chunk.TEPKQR4P.js +5 -5
  54. package/cdn-versioned/chunks/chunk.TJA62EZW.js +2 -2
  55. package/cdn-versioned/chunks/chunk.TJZECQLN.js +2 -2
  56. package/cdn-versioned/chunks/chunk.TTU2AZHQ.js +2 -2
  57. package/cdn-versioned/chunks/chunk.V6TDPNCR.js +2 -2
  58. package/cdn-versioned/chunks/chunk.VKDXPIJT.js +2 -2
  59. package/cdn-versioned/chunks/chunk.VQBTMNY2.js +2 -2
  60. package/cdn-versioned/chunks/chunk.VTXEZEW4.js +9 -9
  61. package/cdn-versioned/chunks/chunk.VZJMYD3T.js +2 -2
  62. package/cdn-versioned/chunks/chunk.W2WCYRB2.js +2 -2
  63. package/cdn-versioned/chunks/chunk.W7A3TU2Z.js +1 -1
  64. package/cdn-versioned/chunks/chunk.WRCC4UIS.js +2 -2
  65. package/cdn-versioned/chunks/chunk.WXRHAPLA.js +1 -1
  66. package/cdn-versioned/chunks/chunk.XFHFUV4B.js +1 -1
  67. package/cdn-versioned/chunks/chunk.YAIU6HLJ.js +2 -2
  68. package/cdn-versioned/chunks/chunk.YPTZDABK.js +1 -1
  69. package/cdn-versioned/chunks/chunk.ZBAP3VO3.js +2 -2
  70. package/cdn-versioned/chunks/chunk.ZDHTVWJF.js +1 -1
  71. package/cdn-versioned/chunks/chunk.ZVCMF6VL.js +2 -2
  72. package/cdn-versioned/components/accordion/accordion.d.ts +1 -1
  73. package/cdn-versioned/components/accordion-group/accordion-group.d.ts +1 -1
  74. package/cdn-versioned/components/animation/animation.d.ts +1 -1
  75. package/cdn-versioned/components/audio/audio.d.ts +1 -1
  76. package/cdn-versioned/components/badge/badge.d.ts +1 -1
  77. package/cdn-versioned/components/brandshape/brandshape.d.ts +1 -1
  78. package/cdn-versioned/components/breadcrumb/breadcrumb.d.ts +1 -1
  79. package/cdn-versioned/components/breadcrumb-item/breadcrumb-item.d.ts +1 -1
  80. package/cdn-versioned/components/button/button.d.ts +1 -1
  81. package/cdn-versioned/components/button-group/button-group.d.ts +1 -1
  82. package/cdn-versioned/components/carousel/carousel.d.ts +1 -1
  83. package/cdn-versioned/components/carousel-item/carousel-item.d.ts +1 -1
  84. package/cdn-versioned/components/checkbox/checkbox.d.ts +1 -1
  85. package/cdn-versioned/components/checkbox-group/checkbox-group.d.ts +1 -1
  86. package/cdn-versioned/components/combobox/combobox.d.ts +1 -1
  87. package/cdn-versioned/components/combobox/combobox.js +1 -1
  88. package/cdn-versioned/components/datepicker/datepicker.d.ts +1 -1
  89. package/cdn-versioned/components/dialog/dialog.d.ts +1 -1
  90. package/cdn-versioned/components/divider/divider.d.ts +1 -1
  91. package/cdn-versioned/components/drawer/drawer.d.ts +1 -1
  92. package/cdn-versioned/components/dropdown/dropdown.d.ts +1 -1
  93. package/cdn-versioned/components/expandable/expandable.d.ts +1 -1
  94. package/cdn-versioned/components/flipcard/flipcard.d.ts +1 -1
  95. package/cdn-versioned/components/header/header.d.ts +1 -1
  96. package/cdn-versioned/components/icon/icon.d.ts +1 -1
  97. package/cdn-versioned/components/include/include.d.ts +1 -1
  98. package/cdn-versioned/components/input/input.d.ts +1 -1
  99. package/cdn-versioned/components/link/link.d.ts +1 -1
  100. package/cdn-versioned/components/loader/loader.d.ts +1 -1
  101. package/cdn-versioned/components/map-marker/map-marker.d.ts +1 -1
  102. package/cdn-versioned/components/menu/menu.d.ts +1 -1
  103. package/cdn-versioned/components/menu-item/menu-item.d.ts +1 -1
  104. package/cdn-versioned/components/navigation-item/navigation-item.d.ts +1 -1
  105. package/cdn-versioned/components/notification/notification.d.ts +1 -1
  106. package/cdn-versioned/components/optgroup/optgroup.d.ts +1 -1
  107. package/cdn-versioned/components/option/option.d.ts +1 -1
  108. package/cdn-versioned/components/popup/popup.d.ts +1 -1
  109. package/cdn-versioned/components/quickfact/quickfact.d.ts +1 -1
  110. package/cdn-versioned/components/radio/radio.d.ts +1 -1
  111. package/cdn-versioned/components/radio-button/radio-button.d.ts +1 -1
  112. package/cdn-versioned/components/radio-group/radio-group.d.ts +1 -1
  113. package/cdn-versioned/components/range/range.d.ts +1 -1
  114. package/cdn-versioned/components/range-tick/range-tick.d.ts +1 -1
  115. package/cdn-versioned/components/scrollable/scrollable.d.ts +1 -1
  116. package/cdn-versioned/components/select/select.d.ts +1 -1
  117. package/cdn-versioned/components/skeleton/skeleton.d.ts +1 -1
  118. package/cdn-versioned/components/spinner/spinner.d.ts +1 -1
  119. package/cdn-versioned/components/step/step.d.ts +1 -1
  120. package/cdn-versioned/components/step-group/step-group.d.ts +1 -1
  121. package/cdn-versioned/components/switch/switch.d.ts +1 -1
  122. package/cdn-versioned/components/tab/tab.d.ts +1 -1
  123. package/cdn-versioned/components/tab-group/tab-group.d.ts +1 -1
  124. package/cdn-versioned/components/tab-panel/tab-panel.d.ts +1 -1
  125. package/cdn-versioned/components/tag/tag.d.ts +1 -1
  126. package/cdn-versioned/components/textarea/textarea.d.ts +1 -1
  127. package/cdn-versioned/components/theme-listener/theme-listener.d.ts +1 -1
  128. package/cdn-versioned/components/tooltip/tooltip.d.ts +1 -1
  129. package/cdn-versioned/components/video/video.d.ts +1 -1
  130. package/cdn-versioned/custom-elements.json +244 -244
  131. package/cdn-versioned/internal/form.js +3 -3
  132. package/cdn-versioned/solid-components.bundle.js +80 -80
  133. package/cdn-versioned/solid-components.css +2 -2
  134. package/cdn-versioned/solid-components.iife.js +80 -80
  135. package/cdn-versioned/solid-components.js +1 -1
  136. package/cdn-versioned/vscode.html-custom-data.json +94 -94
  137. package/cdn-versioned/web-types.json +157 -157
  138. package/dist/chunks/{chunk.JKCYKEO5.js → chunk.DJEWCXYR.js} +4 -0
  139. package/dist/components/combobox/combobox.js +1 -1
  140. package/dist/custom-elements.json +1 -1
  141. package/dist/solid-components.js +1 -1
  142. package/dist/web-types.json +1 -1
  143. package/dist-versioned/chunks/chunk.2AIOG6MZ.js +1 -1
  144. package/dist-versioned/chunks/chunk.3AXFD44E.js +1 -1
  145. package/dist-versioned/chunks/chunk.47VYEPC7.js +5 -5
  146. package/dist-versioned/chunks/chunk.55DM73XI.js +1 -1
  147. package/dist-versioned/chunks/chunk.5MCEFEDU.js +2 -2
  148. package/dist-versioned/chunks/chunk.5MPE743H.js +4 -4
  149. package/dist-versioned/chunks/chunk.5OTIJW46.js +12 -12
  150. package/dist-versioned/chunks/chunk.5RQUMMVO.js +28 -28
  151. package/dist-versioned/chunks/chunk.5X6LFFKU.js +1 -1
  152. package/dist-versioned/chunks/chunk.B3QW57TB.js +26 -26
  153. package/dist-versioned/chunks/chunk.B5JP55MU.js +4 -4
  154. package/dist-versioned/chunks/chunk.C3WIBDGG.js +3 -3
  155. package/dist-versioned/chunks/chunk.CGIINI3U.js +2 -2
  156. package/dist-versioned/chunks/chunk.CPWWEXBN.js +14 -14
  157. package/dist-versioned/chunks/chunk.CTTLYNGB.js +5 -5
  158. package/dist-versioned/chunks/chunk.CYUQUE4B.js +2 -2
  159. package/dist-versioned/chunks/chunk.DILSJX2P.js +3 -3
  160. package/dist-versioned/chunks/{chunk.JKCYKEO5.js → chunk.DJEWCXYR.js} +28 -24
  161. package/dist-versioned/chunks/chunk.DZ2VDJQR.js +8 -8
  162. package/dist-versioned/chunks/chunk.EJ7ZDGWQ.js +1 -1
  163. package/dist-versioned/chunks/chunk.F5SY46WN.js +5 -5
  164. package/dist-versioned/chunks/chunk.FCQKJZ3Q.js +3 -3
  165. package/dist-versioned/chunks/chunk.GHCI43SX.js +3 -3
  166. package/dist-versioned/chunks/chunk.GJQGI7TR.js +3 -3
  167. package/dist-versioned/chunks/chunk.GQ5YYHTD.js +4 -4
  168. package/dist-versioned/chunks/chunk.GRANIL4Q.js +6 -6
  169. package/dist-versioned/chunks/chunk.I53S7NHV.js +2 -2
  170. package/dist-versioned/chunks/chunk.IKVZ463R.js +3 -3
  171. package/dist-versioned/chunks/chunk.INHXFMS2.js +11 -11
  172. package/dist-versioned/chunks/chunk.IPCTQ6PF.js +4 -4
  173. package/dist-versioned/chunks/chunk.JQTAMOYF.js +2 -2
  174. package/dist-versioned/chunks/chunk.KCPMJRGB.js +2 -2
  175. package/dist-versioned/chunks/chunk.KEJFWGZI.js +4 -4
  176. package/dist-versioned/chunks/chunk.LIQBUDFE.js +1 -1
  177. package/dist-versioned/chunks/chunk.LZARRB2N.js +6 -6
  178. package/dist-versioned/chunks/chunk.MUI6ZGSD.js +1 -1
  179. package/dist-versioned/chunks/chunk.N6JFPCVN.js +1 -1
  180. package/dist-versioned/chunks/chunk.NHJ6T7AP.js +3 -3
  181. package/dist-versioned/chunks/chunk.NQSFAYCE.js +6 -6
  182. package/dist-versioned/chunks/chunk.OFV5F7EL.js +12 -12
  183. package/dist-versioned/chunks/chunk.PZQ6H5Y4.js +9 -9
  184. package/dist-versioned/chunks/chunk.PZYRZZ2R.js +3 -3
  185. package/dist-versioned/chunks/chunk.QFWRJIAT.js +1 -1
  186. package/dist-versioned/chunks/chunk.RBO5CDRH.js +8 -8
  187. package/dist-versioned/chunks/chunk.RKY7KPDX.js +3 -3
  188. package/dist-versioned/chunks/chunk.SMT5CXN7.js +5 -5
  189. package/dist-versioned/chunks/chunk.SNTZFQ72.js +5 -5
  190. package/dist-versioned/chunks/chunk.SNVCUPPA.js +2 -2
  191. package/dist-versioned/chunks/chunk.T3YIJ2AA.js +4 -4
  192. package/dist-versioned/chunks/chunk.U3G5KSOH.js +10 -10
  193. package/dist-versioned/chunks/chunk.UIQBHPD3.js +2 -2
  194. package/dist-versioned/chunks/chunk.UQT5XXVS.js +5 -5
  195. package/dist-versioned/chunks/chunk.V7GR76PZ.js +7 -7
  196. package/dist-versioned/chunks/chunk.VWORQHO2.js +4 -4
  197. package/dist-versioned/chunks/chunk.W5KWIGMY.js +8 -8
  198. package/dist-versioned/chunks/chunk.WFZUFPF7.js +2 -2
  199. package/dist-versioned/chunks/chunk.WRQJ6H5M.js +3 -3
  200. package/dist-versioned/chunks/chunk.XCFU7XC7.js +4 -4
  201. package/dist-versioned/chunks/chunk.XFYTZRFZ.js +2 -2
  202. package/dist-versioned/chunks/chunk.XPXDWU3H.js +1 -1
  203. package/dist-versioned/chunks/chunk.XRVF3H64.js +2 -2
  204. package/dist-versioned/chunks/chunk.XWLSRHC5.js +4 -4
  205. package/dist-versioned/chunks/chunk.Y5QCYID3.js +5 -5
  206. package/dist-versioned/chunks/chunk.ZNJFZAOB.js +4 -4
  207. package/dist-versioned/components/accordion/accordion.d.ts +1 -1
  208. package/dist-versioned/components/accordion-group/accordion-group.d.ts +1 -1
  209. package/dist-versioned/components/animation/animation.d.ts +1 -1
  210. package/dist-versioned/components/audio/audio.d.ts +1 -1
  211. package/dist-versioned/components/badge/badge.d.ts +1 -1
  212. package/dist-versioned/components/brandshape/brandshape.d.ts +1 -1
  213. package/dist-versioned/components/breadcrumb/breadcrumb.d.ts +1 -1
  214. package/dist-versioned/components/breadcrumb-item/breadcrumb-item.d.ts +1 -1
  215. package/dist-versioned/components/button/button.d.ts +1 -1
  216. package/dist-versioned/components/button-group/button-group.d.ts +1 -1
  217. package/dist-versioned/components/carousel/carousel.d.ts +1 -1
  218. package/dist-versioned/components/carousel-item/carousel-item.d.ts +1 -1
  219. package/dist-versioned/components/checkbox/checkbox.d.ts +1 -1
  220. package/dist-versioned/components/checkbox-group/checkbox-group.d.ts +1 -1
  221. package/dist-versioned/components/combobox/combobox.d.ts +1 -1
  222. package/dist-versioned/components/combobox/combobox.js +1 -1
  223. package/dist-versioned/components/datepicker/datepicker.d.ts +1 -1
  224. package/dist-versioned/components/dialog/dialog.d.ts +1 -1
  225. package/dist-versioned/components/divider/divider.d.ts +1 -1
  226. package/dist-versioned/components/drawer/drawer.d.ts +1 -1
  227. package/dist-versioned/components/dropdown/dropdown.d.ts +1 -1
  228. package/dist-versioned/components/expandable/expandable.d.ts +1 -1
  229. package/dist-versioned/components/flipcard/flipcard.d.ts +1 -1
  230. package/dist-versioned/components/header/header.d.ts +1 -1
  231. package/dist-versioned/components/icon/icon.d.ts +1 -1
  232. package/dist-versioned/components/include/include.d.ts +1 -1
  233. package/dist-versioned/components/input/input.d.ts +1 -1
  234. package/dist-versioned/components/link/link.d.ts +1 -1
  235. package/dist-versioned/components/loader/loader.d.ts +1 -1
  236. package/dist-versioned/components/map-marker/map-marker.d.ts +1 -1
  237. package/dist-versioned/components/menu/menu.d.ts +1 -1
  238. package/dist-versioned/components/menu-item/menu-item.d.ts +1 -1
  239. package/dist-versioned/components/navigation-item/navigation-item.d.ts +1 -1
  240. package/dist-versioned/components/notification/notification.d.ts +1 -1
  241. package/dist-versioned/components/optgroup/optgroup.d.ts +1 -1
  242. package/dist-versioned/components/option/option.d.ts +1 -1
  243. package/dist-versioned/components/popup/popup.d.ts +1 -1
  244. package/dist-versioned/components/quickfact/quickfact.d.ts +1 -1
  245. package/dist-versioned/components/radio/radio.d.ts +1 -1
  246. package/dist-versioned/components/radio-button/radio-button.d.ts +1 -1
  247. package/dist-versioned/components/radio-group/radio-group.d.ts +1 -1
  248. package/dist-versioned/components/range/range.d.ts +1 -1
  249. package/dist-versioned/components/range-tick/range-tick.d.ts +1 -1
  250. package/dist-versioned/components/scrollable/scrollable.d.ts +1 -1
  251. package/dist-versioned/components/select/select.d.ts +1 -1
  252. package/dist-versioned/components/skeleton/skeleton.d.ts +1 -1
  253. package/dist-versioned/components/spinner/spinner.d.ts +1 -1
  254. package/dist-versioned/components/step/step.d.ts +1 -1
  255. package/dist-versioned/components/step-group/step-group.d.ts +1 -1
  256. package/dist-versioned/components/switch/switch.d.ts +1 -1
  257. package/dist-versioned/components/tab/tab.d.ts +1 -1
  258. package/dist-versioned/components/tab-group/tab-group.d.ts +1 -1
  259. package/dist-versioned/components/tab-panel/tab-panel.d.ts +1 -1
  260. package/dist-versioned/components/tag/tag.d.ts +1 -1
  261. package/dist-versioned/components/textarea/textarea.d.ts +1 -1
  262. package/dist-versioned/components/theme-listener/theme-listener.d.ts +1 -1
  263. package/dist-versioned/components/tooltip/tooltip.d.ts +1 -1
  264. package/dist-versioned/components/video/video.d.ts +1 -1
  265. package/dist-versioned/custom-elements.json +244 -244
  266. package/dist-versioned/internal/form.js +3 -3
  267. package/dist-versioned/solid-components.css +2 -2
  268. package/dist-versioned/solid-components.js +1 -1
  269. package/dist-versioned/vscode.html-custom-data.json +94 -94
  270. package/dist-versioned/web-types.json +157 -157
  271. package/package.json +1 -1
@@ -1 +1 @@
1
- import{e as p}from"./chunk.UOAG5PNU.js";import{a as l,b as m}from"./chunk.6EV4YU6C.js";var a=new WeakMap,n=new WeakMap,c=new WeakMap,d=new WeakMap,v=class{constructor(t,e){this.handleFormData=t=>{let e=this.options.disabled(this.host),o=this.options.name(this.host),i=this.options.value(this.host),s=this.host.tagName.toLowerCase()==="sd-6-8-0-button";!e&&!s&&typeof o=="string"&&o.length>0&&typeof i!="undefined"&&(Array.isArray(i)?i.forEach(r=>{t.formData.append(o,r.toString())}):t.formData.append(o,i.toString()))};this.handleFormSubmit=t=>{var i,s;let e=this.options.disabled(this.host),o=this.options.reportValidity;if(this.form&&!this.form.noValidate&&((i=a.get(this.form))==null||i.forEach(r=>{this.setUserInteracted(r,!0)})),this.form&&!this.form.noValidate&&!e&&!o(this.host)){t.preventDefault(),t.stopImmediatePropagation();let r=(s=this.form)==null?void 0:s.querySelectorAll("[data-invalid]");Array.from(r).filter(h=>h.tagName.toLowerCase()==="sd-6-8-0-radio-group").forEach(h=>{var f,u;(u=(f=h.shadowRoot)==null?void 0:f.querySelector("input"))==null||u.dispatchEvent(new Event("invalid"))}),r!=null&&r.length&&r[0].focus()}};this.handleFormReset=()=>{this.options.setValue(this.host,this.options.defaultValue(this.host)),this.setUserInteracted(this.host,!1),d.set(this.host,[])};this.handleInteraction=t=>{let e=d.get(this.host);e.includes(t.type)||e.push(t.type),e.length===this.options.assumeInteractionOn.length&&this.setUserInteracted(this.host,!0)};this.fakeUserInteraction=()=>{this.setUserInteracted(this.host,!0)};(this.host=t).addController(this),this.options=l({form:o=>{if(o.hasAttribute("form")&&o.getAttribute("form")!==""){let i=o.getRootNode(),s=o.getAttribute("form");if(s)return i.getElementById(s)}return o.closest("form")},name:o=>o.name,value:o=>o.value,defaultValue:o=>o.defaultValue,disabled:o=>{var i;return(i=o.disabled)!=null?i:!1},reportValidity:o=>typeof o.reportValidity=="function"?o.reportValidity():!0,setValue:(o,i)=>o.value=i,assumeInteractionOn:["sd-6-8-0-input"]},e)}hostConnected(){let t=this.options.form(this.host);t&&this.attachForm(t),d.set(this.host,[]),this.options.assumeInteractionOn.forEach(e=>{this.host.addEventListener(e,this.handleInteraction)})}hostDisconnected(){this.detachForm(),d.delete(this.host),this.options.assumeInteractionOn.forEach(t=>{this.host.removeEventListener(t,this.handleInteraction)})}hostUpdated(){var e;let t=this.options.form(this.host);t||this.detachForm(),t&&this.form!==t&&(this.detachForm(),this.attachForm(t)),this.host.hasUpdated&&(this.setValidity((e=this.host)==null?void 0:e.validity.valid),this.updateValidityStyle())}attachForm(t){t?(this.form=t,a.has(this.form)?a.get(this.form).add(this.host):a.set(this.form,new Set([this.host])),this.form.addEventListener("formdata",this.handleFormData),this.form.addEventListener("submit",this.handleFormSubmit),this.form.addEventListener("reset",this.handleFormReset),n.has(this.form)||(n.set(this.form,this.form.reportValidity),this.form.reportValidity=()=>this.reportFormValidity())):this.form=void 0}detachForm(){var t;this.form&&((t=a.get(this.form))==null||t.delete(this.host),this.form.removeEventListener("formdata",this.handleFormData),this.form.removeEventListener("submit",this.handleFormSubmit),this.form.removeEventListener("reset",this.handleFormReset),n.has(this.form)&&(this.form.reportValidity=n.get(this.form),n.delete(this.form))),this.form=void 0}reportFormValidity(){if(this.form&&!this.form.noValidate){let t=this.form.querySelectorAll("*");for(let e of t)if(typeof e.reportValidity=="function"&&!e.reportValidity())return!1}return!0}setUserInteracted(t,e){c.set(t,e),t.requestUpdate()}doAction(t,e){if(this.form){let o=document.createElement("button");o.type=t,o.style.position="absolute",o.style.width="0",o.style.height="0",o.style.clipPath="inset(50%)",o.style.overflow="hidden",o.style.whiteSpace="nowrap",e&&(o.name=e.name,o.value=e.value,["formaction","formenctype","formmethod","formnovalidate","formtarget"].forEach(i=>{e.hasAttribute(i)&&o.setAttribute(i,e.getAttribute(i))})),this.form.append(o),o.click(),o.remove()}}updateValidityStyle(){this.host.hasAttribute("data-user-valid")&&this.host.checkValidity()?(this.host.showValidStyle!==void 0&&(this.host.showValidStyle=!0),this.host.showInvalidStyle=!1):this.host.hasAttribute("data-user-invalid")&&!this.host.checkValidity()?(this.host.showValidStyle!==void 0&&(this.host.showValidStyle=!1),this.host.showInvalidStyle=!0):(this.host.showValidStyle!==void 0&&(this.host.showValidStyle=!1),this.host.showInvalidStyle=!1)}getForm(){var t;return(t=this.form)!=null?t:null}renderInvalidMessage(t){let e={sm:"text-sm",md:"text-base",lg:"text-base"}[t];return p`<div id="invalid-message" class="text-error text-left ${e}" part="invalid-message" aria-live="polite" ?hidden="${!this.host.showInvalidStyle}"></div>`}reset(t){this.doAction("reset",t)}submit(t){this.doAction("submit",t)}setValidity(t){var s;let e=this.host,o=!!c.get(e),i=!!e.required;(s=this.form)!=null&&s.noValidate?(e.removeAttribute("data-required"),e.removeAttribute("data-optional"),e.removeAttribute("data-invalid"),e.removeAttribute("data-valid"),e.removeAttribute("data-user-invalid"),e.removeAttribute("data-user-valid"),e.removeAttribute("aria-invalid")):(e.toggleAttribute("data-required",i),e.toggleAttribute("data-optional",!i),e.toggleAttribute("data-invalid",!t),e.toggleAttribute("data-valid",t),e.toggleAttribute("data-user-invalid",!t&&o),e.toggleAttribute("data-user-valid",t&&o),e.setAttribute("aria-invalid",(!t).toString()))}updateValidity(){let t=this.host;this.setValidity(t==null?void 0:t.validity.valid)}emitInvalidEvent(t){t==null||t.preventDefault();let e=new CustomEvent("sd-invalid",{bubbles:!1,composed:!1,cancelable:!0,detail:{}});t||e.preventDefault()}},y=Object.freeze({badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valid:!0,valueMissing:!1}),F=Object.freeze(m(l({},y),{valid:!1,valueMissing:!0})),V=Object.freeze(m(l({},y),{valid:!1,customError:!0}));export{a,v as b,y as c,F as d,V as e};
1
+ import{e as p}from"./chunk.UOAG5PNU.js";import{a as l,b as m}from"./chunk.6EV4YU6C.js";var a=new WeakMap,n=new WeakMap,c=new WeakMap,d=new WeakMap,v=class{constructor(t,e){this.handleFormData=t=>{let e=this.options.disabled(this.host),o=this.options.name(this.host),i=this.options.value(this.host),s=this.host.tagName.toLowerCase()==="sd-6-9-0-button";!e&&!s&&typeof o=="string"&&o.length>0&&typeof i!="undefined"&&(Array.isArray(i)?i.forEach(r=>{t.formData.append(o,r.toString())}):t.formData.append(o,i.toString()))};this.handleFormSubmit=t=>{var i,s;let e=this.options.disabled(this.host),o=this.options.reportValidity;if(this.form&&!this.form.noValidate&&((i=a.get(this.form))==null||i.forEach(r=>{this.setUserInteracted(r,!0)})),this.form&&!this.form.noValidate&&!e&&!o(this.host)){t.preventDefault(),t.stopImmediatePropagation();let r=(s=this.form)==null?void 0:s.querySelectorAll("[data-invalid]");Array.from(r).filter(h=>h.tagName.toLowerCase()==="sd-6-9-0-radio-group").forEach(h=>{var f,u;(u=(f=h.shadowRoot)==null?void 0:f.querySelector("input"))==null||u.dispatchEvent(new Event("invalid"))}),r!=null&&r.length&&r[0].focus()}};this.handleFormReset=()=>{this.options.setValue(this.host,this.options.defaultValue(this.host)),this.setUserInteracted(this.host,!1),d.set(this.host,[])};this.handleInteraction=t=>{let e=d.get(this.host);e.includes(t.type)||e.push(t.type),e.length===this.options.assumeInteractionOn.length&&this.setUserInteracted(this.host,!0)};this.fakeUserInteraction=()=>{this.setUserInteracted(this.host,!0)};(this.host=t).addController(this),this.options=l({form:o=>{if(o.hasAttribute("form")&&o.getAttribute("form")!==""){let i=o.getRootNode(),s=o.getAttribute("form");if(s)return i.getElementById(s)}return o.closest("form")},name:o=>o.name,value:o=>o.value,defaultValue:o=>o.defaultValue,disabled:o=>{var i;return(i=o.disabled)!=null?i:!1},reportValidity:o=>typeof o.reportValidity=="function"?o.reportValidity():!0,setValue:(o,i)=>o.value=i,assumeInteractionOn:["sd-6-9-0-input"]},e)}hostConnected(){let t=this.options.form(this.host);t&&this.attachForm(t),d.set(this.host,[]),this.options.assumeInteractionOn.forEach(e=>{this.host.addEventListener(e,this.handleInteraction)})}hostDisconnected(){this.detachForm(),d.delete(this.host),this.options.assumeInteractionOn.forEach(t=>{this.host.removeEventListener(t,this.handleInteraction)})}hostUpdated(){var e;let t=this.options.form(this.host);t||this.detachForm(),t&&this.form!==t&&(this.detachForm(),this.attachForm(t)),this.host.hasUpdated&&(this.setValidity((e=this.host)==null?void 0:e.validity.valid),this.updateValidityStyle())}attachForm(t){t?(this.form=t,a.has(this.form)?a.get(this.form).add(this.host):a.set(this.form,new Set([this.host])),this.form.addEventListener("formdata",this.handleFormData),this.form.addEventListener("submit",this.handleFormSubmit),this.form.addEventListener("reset",this.handleFormReset),n.has(this.form)||(n.set(this.form,this.form.reportValidity),this.form.reportValidity=()=>this.reportFormValidity())):this.form=void 0}detachForm(){var t;this.form&&((t=a.get(this.form))==null||t.delete(this.host),this.form.removeEventListener("formdata",this.handleFormData),this.form.removeEventListener("submit",this.handleFormSubmit),this.form.removeEventListener("reset",this.handleFormReset),n.has(this.form)&&(this.form.reportValidity=n.get(this.form),n.delete(this.form))),this.form=void 0}reportFormValidity(){if(this.form&&!this.form.noValidate){let t=this.form.querySelectorAll("*");for(let e of t)if(typeof e.reportValidity=="function"&&!e.reportValidity())return!1}return!0}setUserInteracted(t,e){c.set(t,e),t.requestUpdate()}doAction(t,e){if(this.form){let o=document.createElement("button");o.type=t,o.style.position="absolute",o.style.width="0",o.style.height="0",o.style.clipPath="inset(50%)",o.style.overflow="hidden",o.style.whiteSpace="nowrap",e&&(o.name=e.name,o.value=e.value,["formaction","formenctype","formmethod","formnovalidate","formtarget"].forEach(i=>{e.hasAttribute(i)&&o.setAttribute(i,e.getAttribute(i))})),this.form.append(o),o.click(),o.remove()}}updateValidityStyle(){this.host.hasAttribute("data-user-valid")&&this.host.checkValidity()?(this.host.showValidStyle!==void 0&&(this.host.showValidStyle=!0),this.host.showInvalidStyle=!1):this.host.hasAttribute("data-user-invalid")&&!this.host.checkValidity()?(this.host.showValidStyle!==void 0&&(this.host.showValidStyle=!1),this.host.showInvalidStyle=!0):(this.host.showValidStyle!==void 0&&(this.host.showValidStyle=!1),this.host.showInvalidStyle=!1)}getForm(){var t;return(t=this.form)!=null?t:null}renderInvalidMessage(t){let e={sm:"text-sm",md:"text-base",lg:"text-base"}[t];return p`<div id="invalid-message" class="text-error text-left ${e}" part="invalid-message" aria-live="polite" ?hidden="${!this.host.showInvalidStyle}"></div>`}reset(t){this.doAction("reset",t)}submit(t){this.doAction("submit",t)}setValidity(t){var s;let e=this.host,o=!!c.get(e),i=!!e.required;(s=this.form)!=null&&s.noValidate?(e.removeAttribute("data-required"),e.removeAttribute("data-optional"),e.removeAttribute("data-invalid"),e.removeAttribute("data-valid"),e.removeAttribute("data-user-invalid"),e.removeAttribute("data-user-valid"),e.removeAttribute("aria-invalid")):(e.toggleAttribute("data-required",i),e.toggleAttribute("data-optional",!i),e.toggleAttribute("data-invalid",!t),e.toggleAttribute("data-valid",t),e.toggleAttribute("data-user-invalid",!t&&o),e.toggleAttribute("data-user-valid",t&&o),e.setAttribute("aria-invalid",(!t).toString()))}updateValidity(){let t=this.host;this.setValidity(t==null?void 0:t.validity.valid)}emitInvalidEvent(t){t==null||t.preventDefault();let e=new CustomEvent("sd-invalid",{bubbles:!1,composed:!1,cancelable:!0,detail:{}});t||e.preventDefault()}},y=Object.freeze({badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valid:!0,valueMissing:!1}),F=Object.freeze(m(l({},y),{valid:!1,valueMissing:!0})),V=Object.freeze(m(l({},y),{valid:!1,customError:!0}));export{a,v as b,y as c,F as d,V as e};
@@ -1,5 +1,5 @@
1
- import{a as C}from"./chunk.BJBQEPZV.js";import{a as k}from"./chunk.EOXYPQZI.js";import{a as T}from"./chunk.WXRHAPLA.js";import{a as M}from"./chunk.CBQWVOOS.js";import{a as A}from"./chunk.IQPMMUES.js";import{a as n}from"./chunk.YFQFOIEM.js";import{a as v}from"./chunk.NYKJXI3Q.js";import{a as _,b as p,c as m,d as f,e as E,h as w}from"./chunk.CRLGS4QF.js";import{b as P,e as b}from"./chunk.UOAG5PNU.js";import{d as $}from"./chunk.W4QBFD6E.js";import{e as o}from"./chunk.6EV4YU6C.js";function I(u,d,e){let i=t=>Object.is(t,-0)?0:t;return u<d?i(d):u>e?i(e):i(u)}function*L(u,d){if(u!==void 0){let e=0;for(let i of u)yield d(i,e++)}}function*B(u,d,e=1){let i=d===void 0?0:u;d!=null||(d=u);for(let t=i;e>0?t<d:d<t;t+=e)yield t}var r=class extends w{constructor(){super(...arguments);this.variant="number";this.inverted=!1;this.loop=!1;this.autoplay=!1;this.fade=!1;this.slidesPerPage=1;this.slidesPerMove=1;this.activeSlide=0;this.currentPage=1;this.pausedAutoplay=!1;this.autoplayController=new M(this,()=>this.next());this.scrollController=new k(this);this.slides=this.getElementsByTagName("sd-6-8-0-carousel-item");this.intersectionObserverEntries=new Map;this.localize=new A(this);this.userInteracted=!1;this.fadeController=new C(this);this.handleUserInteraction=()=>{this.userInteracted=!0};this.handleSlotChange=e=>{e.some(t=>[...t.addedNodes,...t.removedNodes].some(s=>T.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)),this.fade&&this.fadeController.disable()}async firstUpdated(){if((()=>{let i=this.getSlides({excludeClones:!1});return i.length>0&&i[0].getBoundingClientRect().width>0})())this.initializeSlides();else{let i=new IntersectionObserver(t=>{t.forEach(s=>{s.isIntersecting&&s.target.getBoundingClientRect().width>0&&(this.initializeSlides(),i.disconnect())})});i.observe(this)}this.mutationObserver=new MutationObserver(this.handleSlotChange),this.mutationObserver.observe(this,{childList:!0,subtree:!1}),this.fade&&(await this.updateComplete,this.fadeController.enable())}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",h=e.key==="ArrowUp"||!t&&e.key==="ArrowLeft"||t&&e.key==="ArrowRight";e.preventDefault(),h&&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 c=(a=this.shadowRoot)==null?void 0:a.querySelector('[part~="pagination-item--active"]');c&&c.focus()})}}handleScrollEnd(){if(this.fade)return;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))}handleFocus(){this.autoplay&&this.scrollContainer.setAttribute("aria-live","polite")}handleBlur(){this.autoplay&&this.scrollContainer.setAttribute("aria-live","off")}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"))}handleFadeChange(){this.fade?this.fadeController.enable():this.fadeController.disable()}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&&!this.fade){let t=this.slidesPerPage,s=e.slice(-t),l=e.slice(0,t);s.reverse().forEach((h,c)=>{let a=h.cloneNode(!0);a.setAttribute("data-clone",String(e.length-c-1)),this.prepend(a)}),l.forEach((h,c)=>{let a=h.cloneNode(!0);a.setAttribute("data-clone",String(c)),this.append(a)})}this.getSlides({excludeClones:!1}).forEach(t=>{i.observe(t)}),this.fade&&this.updateComplete.then(()=>{this.fadeController.enable()}),this.fade||this.goToSlide(this.activeSlide,"auto")}handleSlideChange(){let e=this.getSlides();e.forEach((s,l)=>{s.classList.toggle("--is-active",l===this.activeSlide)}),this.fade&&this.fadeController.updateActiveSlide(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(){if(this.fade)return;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"){if(this.fade){let s=this.loop?(this.activeSlide-1+this.getSlides().length)%this.getSlides().length:Math.max(0,this.activeSlide-1);this.goToSlide(s);return}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"){if(this.fade){let i=this.loop?(this.activeSlide+1)%this.getSlides().length:Math.min(this.getSlides().length-1,this.activeSlide+1);this.goToSlide(i);return}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"){if(this.fade){this.goToSlide(0);return}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,fade:h}=this,c=this.getSlides(),a=this.getSlides({excludeClones:!1}),g=(e+c.length)%c.length;if(this.activeSlide=g,h)return;let y=I(e+(s?t:0),0,a.length+1),O=a[y],S=l.getBoundingClientRect(),x=O.getBoundingClientRect();if(l.scrollTo({left:x.left-S.left+l.scrollLeft,top:x.top-S.top+l.scrollTop,behavior:$()?"auto":i}),this.userInteracted&&!this.loop){let z=this.activeSlide===c.length-1||this.activeSlide===this.slides.length-this.slidesPerPage,H=this.activeSlide===0;z?this.previousButton.focus({preventScroll:!0}):H&&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,h=this.loop||s<t,c=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 max-h-full w-full items-center justify-items-center",this.inverted?"focus-visible:focus-outline-inverted":"focus-visible:focus-outline",this.fade?"relative overflow-hidden":"grid overflow-auto overscroll-x-contain grid-flow-col auto-rows-[100%] snap-x snap-mandatory overflow-y-hidden")}" style="--slides-per-page:${this.slidesPerPage}" aria-busy="${e.scrolling?"true":"false"}" aria-label="${this.localize.term("carouselContainer",Array.from(this.slides).filter(a=>!a.hasAttribute("data-clone")).length)}" aria-live="${this.autoplay?"off":"polite"}" tabindex="0" @keydown="${this.handleKeyDown}" @scrollend="${this.handleScrollEnd}" @focus="${this.handleFocus}" @blur="${this.handleBlur}"><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 transition-colors duration-fast ease-in-out",!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"}" @focus="${this.handleFocus}" @blur="${this.handleBlur}" @click="${l?a=>{this.previous(),this.unblockAutoplay(a,this.previousButton)}:null}"><slot name="previous-icon"><sd-6-8-0-icon class="${n("h-6 w-6 rotate-90 grid place-items-center")}" library="_internal" name="${c?"chevron-down":"chevron-up"}"></sd-6-8-0-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">${L(B(t),a=>{let g=a+1===s;return b`<button part="pagination-item ${g?"pagination-item--active":""}" class="${n("carousel__pagination-item","block cursor-pointer bg-none border-0 rounded-full",g?"bg-accent":"",this.inverted?"focus-within:focus-outline-inverted":"focus-within:focus-outline")}" role="tab" tabindex="0" aria-selected="${g?"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 sd-6-8-0-carousel__pager-dot-border-width rounded-full transition-colors duration-slow hover:duration-fast ease-in-out",this.inverted?"sd-6-8-0-carousel__pager-dot--inverted-border hover:border-primary-200":"border-primary hover:border-primary-500",g&&"border-none",g?this.inverted?"sd-6-8-0-carousel__pager-dot--inverted-background hover:sd-6-8-0-carousel__pager-dot--inverted--hovered-background":"sd-6-8-0-carousel__pager-dot-background 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",this.inverted?"text-white sd-6-8-0-carousel--active--inverted-color-border":"text-black sd-6-8-0-carousel--active-color-border")}">${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="${!h}" class="${n("!ml-6 !rounded-sm sd-interactive transition-colors duration-fast ease-in-out",!h&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("nextSlide")}" aria-controls="scroll-container" aria-disabled="${h?"false":"true"}" @focus="${this.handleFocus}" @blur="${this.handleBlur}" @click="${h?a=>{this.next(),this.unblockAutoplay(a,this.nextButton)}:null}"><slot name="next-icon"><sd-6-8-0-icon class="${n("h-6 w-6 rotate-90 grid place-items-center")}" library="_internal" name="${c?"chevron-up":"chevron-down"}"></sd-6-8-0-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-6-8-0-icon class="h-6 w-6 grid place-items-center" library="_internal" name="start"></sd-6-8-0-icon></slot><slot name="autoplay-pause" class="${n(this.pausedAutoplay?"hidden":"")}"><sd-6-8-0-icon class="h-6 w-6 grid place-items-center" library="_internal" name="pause"></sd-6-8-0-icon></slot></button></div></div>`}};r.styles=[...w.styles,P`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
2
- :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));grid-auto-columns:var(--slide-size);-moz-column-gap:var(--slide-gap);column-gap:var(--slide-gap);scroll-padding-inline:var(--scroll-hint);padding-inline:var(--scroll-hint)}.carousel__slides::-webkit-scrollbar{display:none}:host([fade]){--carousel-height:auto}:host([fade]) .carousel__slides{position:relative;display:block;overflow:hidden;height:var(--carousel-height)}@media (prefers-reduced-motion){:where(.carousel__slides){scroll-behavior:auto}}.carousel__navigation{grid-area:navigation}sd-6-8-0-button::part(label){pointer-events:none;display:flex;flex:auto;align-items:center}#carousel__navigation-button--next,#carousel__navigation-button--previous{color:rgba(var(--sd-color-icon-fill-primary))}#carousel__navigation-button--next:disabled,#carousel__navigation-button--previous:disabled{color:rgba(var(--sd-color-icon-fill-neutral-500))}:host([inverted]) #carousel__navigation-button--next,:host([inverted]) #carousel__navigation-button--previous{color:rgba(var(--sd-color-icon-fill-white))}:host([inverted]) #carousel__navigation-button--next:disabled,:host([inverted]) #carousel__navigation-button--previous:disabled{color:rgba(var(--sd-color-icon-fill-neutral-600))}`],o([f('[part~="autoplay-controls"]')],r.prototype,"autoplayControls",2),o([f('[part~="navigation-button--previous"]')],r.prototype,"previousButton",2),o([f('[part~="navigation-button--next"]')],r.prototype,"nextButton",2),o([E('[part~="pagination-item"]')],r.prototype,"paginationItems",2),o([p({type:String,reflect:!0})],r.prototype,"variant",2),o([p({type:Boolean,reflect:!0})],r.prototype,"inverted",2),o([p({type:Boolean,reflect:!0})],r.prototype,"loop",2),o([p({type:Boolean,reflect:!0})],r.prototype,"autoplay",2),o([p({type:Boolean,reflect:!0})],r.prototype,"fade",2),o([p({type:Number,attribute:"slides-per-page",reflect:!0})],r.prototype,"slidesPerPage",2),o([p({type:Number,attribute:"slides-per-move",reflect:!0})],r.prototype,"slidesPerMove",2),o([f("slot:not([name])")],r.prototype,"defaultSlot",2),o([f(".carousel__slides")],r.prototype,"scrollContainer",2),o([f(".carousel__pagination")],r.prototype,"paginationContainer",2),o([m()],r.prototype,"activeSlide",2),o([m()],r.prototype,"currentPage",2),o([m()],r.prototype,"pausedAutoplay",2),o([v("pausedAutoplay")],r.prototype,"handlePausedAutoplay",1),o([v("fade",{waitUntilFirstUpdate:!0})],r.prototype,"handleFadeChange",1),o([v("loop",{waitUntilFirstUpdate:!0}),v("slidesPerPage",{waitUntilFirstUpdate:!0})],r.prototype,"initializeSlides",1),o([v("activeSlide")],r.prototype,"handleSlideChange",1),o([v("slidesPerMove")],r.prototype,"handleSlidesPerMoveChange",1),o([v("autoplay")],r.prototype,"handleAutoplayChange",1),r=o([_("sd-6-8-0-carousel")],r);export{r as a};
1
+ import{a as C}from"./chunk.BJBQEPZV.js";import{a as k}from"./chunk.EOXYPQZI.js";import{a as T}from"./chunk.WXRHAPLA.js";import{a as M}from"./chunk.CBQWVOOS.js";import{a as A}from"./chunk.IQPMMUES.js";import{a as n}from"./chunk.YFQFOIEM.js";import{a as v}from"./chunk.NYKJXI3Q.js";import{a as _,b as p,c as m,d as f,e as E,h as w}from"./chunk.CRLGS4QF.js";import{b as P,e as b}from"./chunk.UOAG5PNU.js";import{d as $}from"./chunk.W4QBFD6E.js";import{e as o}from"./chunk.6EV4YU6C.js";function I(u,d,e){let i=t=>Object.is(t,-0)?0:t;return u<d?i(d):u>e?i(e):i(u)}function*L(u,d){if(u!==void 0){let e=0;for(let i of u)yield d(i,e++)}}function*B(u,d,e=1){let i=d===void 0?0:u;d!=null||(d=u);for(let t=i;e>0?t<d:d<t;t+=e)yield t}var r=class extends w{constructor(){super(...arguments);this.variant="number";this.inverted=!1;this.loop=!1;this.autoplay=!1;this.fade=!1;this.slidesPerPage=1;this.slidesPerMove=1;this.activeSlide=0;this.currentPage=1;this.pausedAutoplay=!1;this.autoplayController=new M(this,()=>this.next());this.scrollController=new k(this);this.slides=this.getElementsByTagName("sd-6-9-0-carousel-item");this.intersectionObserverEntries=new Map;this.localize=new A(this);this.userInteracted=!1;this.fadeController=new C(this);this.handleUserInteraction=()=>{this.userInteracted=!0};this.handleSlotChange=e=>{e.some(t=>[...t.addedNodes,...t.removedNodes].some(s=>T.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)),this.fade&&this.fadeController.disable()}async firstUpdated(){if((()=>{let i=this.getSlides({excludeClones:!1});return i.length>0&&i[0].getBoundingClientRect().width>0})())this.initializeSlides();else{let i=new IntersectionObserver(t=>{t.forEach(s=>{s.isIntersecting&&s.target.getBoundingClientRect().width>0&&(this.initializeSlides(),i.disconnect())})});i.observe(this)}this.mutationObserver=new MutationObserver(this.handleSlotChange),this.mutationObserver.observe(this,{childList:!0,subtree:!1}),this.fade&&(await this.updateComplete,this.fadeController.enable())}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",h=e.key==="ArrowUp"||!t&&e.key==="ArrowLeft"||t&&e.key==="ArrowRight";e.preventDefault(),h&&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 c=(a=this.shadowRoot)==null?void 0:a.querySelector('[part~="pagination-item--active"]');c&&c.focus()})}}handleScrollEnd(){if(this.fade)return;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))}handleFocus(){this.autoplay&&this.scrollContainer.setAttribute("aria-live","polite")}handleBlur(){this.autoplay&&this.scrollContainer.setAttribute("aria-live","off")}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"))}handleFadeChange(){this.fade?this.fadeController.enable():this.fadeController.disable()}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&&!this.fade){let t=this.slidesPerPage,s=e.slice(-t),l=e.slice(0,t);s.reverse().forEach((h,c)=>{let a=h.cloneNode(!0);a.setAttribute("data-clone",String(e.length-c-1)),this.prepend(a)}),l.forEach((h,c)=>{let a=h.cloneNode(!0);a.setAttribute("data-clone",String(c)),this.append(a)})}this.getSlides({excludeClones:!1}).forEach(t=>{i.observe(t)}),this.fade&&this.updateComplete.then(()=>{this.fadeController.enable()}),this.fade||this.goToSlide(this.activeSlide,"auto")}handleSlideChange(){let e=this.getSlides();e.forEach((s,l)=>{s.classList.toggle("--is-active",l===this.activeSlide)}),this.fade&&this.fadeController.updateActiveSlide(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(){if(this.fade)return;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"){if(this.fade){let s=this.loop?(this.activeSlide-1+this.getSlides().length)%this.getSlides().length:Math.max(0,this.activeSlide-1);this.goToSlide(s);return}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"){if(this.fade){let i=this.loop?(this.activeSlide+1)%this.getSlides().length:Math.min(this.getSlides().length-1,this.activeSlide+1);this.goToSlide(i);return}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"){if(this.fade){this.goToSlide(0);return}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,fade:h}=this,c=this.getSlides(),a=this.getSlides({excludeClones:!1}),g=(e+c.length)%c.length;if(this.activeSlide=g,h)return;let y=I(e+(s?t:0),0,a.length+1),O=a[y],S=l.getBoundingClientRect(),x=O.getBoundingClientRect();if(l.scrollTo({left:x.left-S.left+l.scrollLeft,top:x.top-S.top+l.scrollTop,behavior:$()?"auto":i}),this.userInteracted&&!this.loop){let z=this.activeSlide===c.length-1||this.activeSlide===this.slides.length-this.slidesPerPage,H=this.activeSlide===0;z?this.previousButton.focus({preventScroll:!0}):H&&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,h=this.loop||s<t,c=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 max-h-full w-full items-center justify-items-center",this.inverted?"focus-visible:focus-outline-inverted":"focus-visible:focus-outline",this.fade?"relative overflow-hidden":"grid overflow-auto overscroll-x-contain grid-flow-col auto-rows-[100%] snap-x snap-mandatory overflow-y-hidden")}" style="--slides-per-page:${this.slidesPerPage}" aria-busy="${e.scrolling?"true":"false"}" aria-label="${this.localize.term("carouselContainer",Array.from(this.slides).filter(a=>!a.hasAttribute("data-clone")).length)}" aria-live="${this.autoplay?"off":"polite"}" tabindex="0" @keydown="${this.handleKeyDown}" @scrollend="${this.handleScrollEnd}" @focus="${this.handleFocus}" @blur="${this.handleBlur}"><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 transition-colors duration-fast ease-in-out",!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"}" @focus="${this.handleFocus}" @blur="${this.handleBlur}" @click="${l?a=>{this.previous(),this.unblockAutoplay(a,this.previousButton)}:null}"><slot name="previous-icon"><sd-6-9-0-icon class="${n("h-6 w-6 rotate-90 grid place-items-center")}" library="_internal" name="${c?"chevron-down":"chevron-up"}"></sd-6-9-0-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">${L(B(t),a=>{let g=a+1===s;return b`<button part="pagination-item ${g?"pagination-item--active":""}" class="${n("carousel__pagination-item","block cursor-pointer bg-none border-0 rounded-full",g?"bg-accent":"",this.inverted?"focus-within:focus-outline-inverted":"focus-within:focus-outline")}" role="tab" tabindex="0" aria-selected="${g?"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 sd-6-9-0-carousel__pager-dot-border-width rounded-full transition-colors duration-slow hover:duration-fast ease-in-out",this.inverted?"sd-6-9-0-carousel__pager-dot--inverted-border hover:border-primary-200":"border-primary hover:border-primary-500",g&&"border-none",g?this.inverted?"sd-6-9-0-carousel__pager-dot--inverted-background hover:sd-6-9-0-carousel__pager-dot--inverted--hovered-background":"sd-6-9-0-carousel__pager-dot-background 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",this.inverted?"text-white sd-6-9-0-carousel--active--inverted-color-border":"text-black sd-6-9-0-carousel--active-color-border")}">${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="${!h}" class="${n("!ml-6 !rounded-sm sd-interactive transition-colors duration-fast ease-in-out",!h&&"sd-interactive--disabled",this.inverted?"sd-interactive--inverted":"sd-interactive--reset")}" aria-label="${this.localize.term("nextSlide")}" aria-controls="scroll-container" aria-disabled="${h?"false":"true"}" @focus="${this.handleFocus}" @blur="${this.handleBlur}" @click="${h?a=>{this.next(),this.unblockAutoplay(a,this.nextButton)}:null}"><slot name="next-icon"><sd-6-9-0-icon class="${n("h-6 w-6 rotate-90 grid place-items-center")}" library="_internal" name="${c?"chevron-up":"chevron-down"}"></sd-6-9-0-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-6-9-0-icon class="h-6 w-6 grid place-items-center" library="_internal" name="start"></sd-6-9-0-icon></slot><slot name="autoplay-pause" class="${n(this.pausedAutoplay?"hidden":"")}"><sd-6-9-0-icon class="h-6 w-6 grid place-items-center" library="_internal" name="pause"></sd-6-9-0-icon></slot></button></div></div>`}};r.styles=[...w.styles,P`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
2
+ :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));grid-auto-columns:var(--slide-size);-moz-column-gap:var(--slide-gap);column-gap:var(--slide-gap);scroll-padding-inline:var(--scroll-hint);padding-inline:var(--scroll-hint)}.carousel__slides::-webkit-scrollbar{display:none}:host([fade]){--carousel-height:auto}:host([fade]) .carousel__slides{position:relative;display:block;overflow:hidden;height:var(--carousel-height)}@media (prefers-reduced-motion){:where(.carousel__slides){scroll-behavior:auto}}.carousel__navigation{grid-area:navigation}sd-6-9-0-button::part(label){pointer-events:none;display:flex;flex:auto;align-items:center}#carousel__navigation-button--next,#carousel__navigation-button--previous{color:rgba(var(--sd-color-icon-fill-primary))}#carousel__navigation-button--next:disabled,#carousel__navigation-button--previous:disabled{color:rgba(var(--sd-color-icon-fill-neutral-500))}:host([inverted]) #carousel__navigation-button--next,:host([inverted]) #carousel__navigation-button--previous{color:rgba(var(--sd-color-icon-fill-white))}:host([inverted]) #carousel__navigation-button--next:disabled,:host([inverted]) #carousel__navigation-button--previous:disabled{color:rgba(var(--sd-color-icon-fill-neutral-600))}`],o([f('[part~="autoplay-controls"]')],r.prototype,"autoplayControls",2),o([f('[part~="navigation-button--previous"]')],r.prototype,"previousButton",2),o([f('[part~="navigation-button--next"]')],r.prototype,"nextButton",2),o([E('[part~="pagination-item"]')],r.prototype,"paginationItems",2),o([p({type:String,reflect:!0})],r.prototype,"variant",2),o([p({type:Boolean,reflect:!0})],r.prototype,"inverted",2),o([p({type:Boolean,reflect:!0})],r.prototype,"loop",2),o([p({type:Boolean,reflect:!0})],r.prototype,"autoplay",2),o([p({type:Boolean,reflect:!0})],r.prototype,"fade",2),o([p({type:Number,attribute:"slides-per-page",reflect:!0})],r.prototype,"slidesPerPage",2),o([p({type:Number,attribute:"slides-per-move",reflect:!0})],r.prototype,"slidesPerMove",2),o([f("slot:not([name])")],r.prototype,"defaultSlot",2),o([f(".carousel__slides")],r.prototype,"scrollContainer",2),o([f(".carousel__pagination")],r.prototype,"paginationContainer",2),o([m()],r.prototype,"activeSlide",2),o([m()],r.prototype,"currentPage",2),o([m()],r.prototype,"pausedAutoplay",2),o([v("pausedAutoplay")],r.prototype,"handlePausedAutoplay",1),o([v("fade",{waitUntilFirstUpdate:!0})],r.prototype,"handleFadeChange",1),o([v("loop",{waitUntilFirstUpdate:!0}),v("slidesPerPage",{waitUntilFirstUpdate:!0})],r.prototype,"initializeSlides",1),o([v("activeSlide")],r.prototype,"handleSlideChange",1),o([v("slidesPerMove")],r.prototype,"handleSlidesPerMoveChange",1),o([v("autoplay")],r.prototype,"handleAutoplayChange",1),r=o([_("sd-6-9-0-carousel")],r);export{r as a};
3
3
  /*! Bundled license information:
4
4
 
5
5
  lit-html/directives/map.js:
@@ -1,2 +1,2 @@
1
- function h(d,{setValueOnSelection:l,scrollSelectionIntoView:p}={setValueOnSelection:!0,scrollSelectionIntoView:!0}){let r=d?typeof d=="string"?document.querySelector(d):d:document.querySelector("#autoComplete"),n=r.shadowRoot.querySelector("input"),c=e=>e[0];return n.addEventListener("init",()=>{var a,s;let e=(a=r.shadowRoot)==null?void 0:a.querySelector("ul");e==null||e.setAttribute("part","listbox");let t=document.createElement("sd-6-8-0-popup");t.appendChild(e),(s=r.shadowRoot)==null||s.appendChild(t),t==null||t.setAttribute("exportparts","popup__content"),t&&(t.active=!1,t.autoSize="vertical",t.autoSizePadding=16,t.placement="bottom-start",t.anchor=r,t.sync="width");let i=c`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer properties;@layer theme,base,components,utilities;
2
- sd-6-8-0-popup::part(popup){z-index:var(--sd-z-index-dropdown,900);overflow-y:scroll;border-bottom-right-radius:var(--sd-radius);border-bottom-left-radius:var(--sd-radius);border-style:var(--tw-border-style);border-width:var(--sd-border-width-2);border-top-style:var(--tw-border-style);border-top-width:0;border-color:rgba(var(--sd-color-border-primary));background-color:rgba(var(--sd-color-background-white));padding-inline:var(--sd-spacing-2);padding-block:var(--sd-spacing-3);--tw-shadow:var(--sd-shadow);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}sd-6-8-0-popup li{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function,cubic-bezier(.4,0,.2,1)));transition-duration:var(--tw-duration,var(--default-transition-duration,150ms))}sd-6-8-0-popup li:hover:not([disabled]){background-color:rgba(var(--sd-color-background-neutral-100))}sd-6-8-0-popup li{list-style-type:''}sd-6-8-0-popup li mark{background-color:transparent;--tw-font-weight:var(--sd-font-weight-bold);font-weight:var(--sd-font-weight-bold)}sd-6-8-0-popup li:not(:has(sd-6-8-0-option)){cursor:pointer;padding-inline:var(--sd-spacing-4);padding-block:var(--sd-spacing-3);font-size:var(--sd-text-base);line-height:var(--tw-leading,var(--text-base--line-height,calc(1.5 / 1)));color:rgba(var(--sd-color-text-black))}sd-6-8-0-popup li:not(:has(sd-6-8-0-option)):hover{background-color:rgba(var(--sd-color-background-neutral-200))}sd-6-8-0-popup li[aria-selected=true]{background-color:rgba(var(--sd-color-background-neutral-200))}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-font-weight{syntax:"*";inherits:false}`,o=new CSSStyleSheet;o.replaceSync(i),r.shadowRoot.adoptedStyleSheets=[...r.shadowRoot.adoptedStyleSheets,o]}),l&&n.addEventListener("selection",e=>{var t;r.value=(t=e==null?void 0:e.detail)==null?void 0:t.selection.value}),n.addEventListener("open",()=>{var e,t,i,o,a,s;(t=(e=r.shadowRoot)==null?void 0:e.querySelector("sd-6-8-0-popup"))==null||t.setAttribute("active","true"),(o=(i=r.shadowRoot)==null?void 0:i.querySelector('[part="border"]'))==null||o.classList.add("rounded-b-none"),(s=(a=r.shadowRoot)==null?void 0:a.querySelector('[part="form-control"]'))==null||s.classList.add("z-50")}),n.addEventListener("close",()=>{var e,t,i,o,a,s;(t=(e=r.shadowRoot)==null?void 0:e.querySelector("sd-6-8-0-popup"))==null||t.removeAttribute("active"),(o=(i=r.shadowRoot)==null?void 0:i.querySelector('[part="border"]'))==null||o.classList.remove("rounded-b-none"),(s=(a=r.shadowRoot)==null?void 0:a.querySelector('[part="form-control"]'))==null||s.classList.remove("z-50")}),p&&n.addEventListener("navigate",()=>{let e=r.shadowRoot.querySelector('[aria-selected="true"]');e==null||e.scrollIntoView({block:"nearest"})}),{config:{selector:()=>n,resultsList:{tag:"ul"},wrapper:!1}}}export{h as a};
1
+ function h(d,{setValueOnSelection:l,scrollSelectionIntoView:p}={setValueOnSelection:!0,scrollSelectionIntoView:!0}){let r=d?typeof d=="string"?document.querySelector(d):d:document.querySelector("#autoComplete"),n=r.shadowRoot.querySelector("input"),c=e=>e[0];return n.addEventListener("init",()=>{var a,s;let e=(a=r.shadowRoot)==null?void 0:a.querySelector("ul");e==null||e.setAttribute("part","listbox");let t=document.createElement("sd-6-9-0-popup");t.appendChild(e),(s=r.shadowRoot)==null||s.appendChild(t),t==null||t.setAttribute("exportparts","popup__content"),t&&(t.active=!1,t.autoSize="vertical",t.autoSizePadding=16,t.placement="bottom-start",t.anchor=r,t.sync="width");let i=c`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer properties;@layer theme,base,components,utilities;
2
+ sd-6-9-0-popup::part(popup){z-index:var(--sd-z-index-dropdown,900);overflow-y:scroll;border-bottom-right-radius:var(--sd-radius);border-bottom-left-radius:var(--sd-radius);border-style:var(--tw-border-style);border-width:var(--sd-border-width-2);border-top-style:var(--tw-border-style);border-top-width:0;border-color:rgba(var(--sd-color-border-primary));background-color:rgba(var(--sd-color-background-white));padding-inline:var(--sd-spacing-2);padding-block:var(--sd-spacing-3);--tw-shadow:var(--sd-shadow);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}sd-6-9-0-popup li{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function,cubic-bezier(.4,0,.2,1)));transition-duration:var(--tw-duration,var(--default-transition-duration,150ms))}sd-6-9-0-popup li:hover:not([disabled]){background-color:rgba(var(--sd-color-background-neutral-100))}sd-6-9-0-popup li{list-style-type:''}sd-6-9-0-popup li mark{background-color:transparent;--tw-font-weight:var(--sd-font-weight-bold);font-weight:var(--sd-font-weight-bold)}sd-6-9-0-popup li:not(:has(sd-6-9-0-option)){cursor:pointer;padding-inline:var(--sd-spacing-4);padding-block:var(--sd-spacing-3);font-size:var(--sd-text-base);line-height:var(--tw-leading,var(--text-base--line-height,calc(1.5 / 1)));color:rgba(var(--sd-color-text-black))}sd-6-9-0-popup li:not(:has(sd-6-9-0-option)):hover{background-color:rgba(var(--sd-color-background-neutral-200))}sd-6-9-0-popup li[aria-selected=true]{background-color:rgba(var(--sd-color-background-neutral-200))}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-font-weight{syntax:"*";inherits:false}`,o=new CSSStyleSheet;o.replaceSync(i),r.shadowRoot.adoptedStyleSheets=[...r.shadowRoot.adoptedStyleSheets,o]}),l&&n.addEventListener("selection",e=>{var t;r.value=(t=e==null?void 0:e.detail)==null?void 0:t.selection.value}),n.addEventListener("open",()=>{var e,t,i,o,a,s;(t=(e=r.shadowRoot)==null?void 0:e.querySelector("sd-6-9-0-popup"))==null||t.setAttribute("active","true"),(o=(i=r.shadowRoot)==null?void 0:i.querySelector('[part="border"]'))==null||o.classList.add("rounded-b-none"),(s=(a=r.shadowRoot)==null?void 0:a.querySelector('[part="form-control"]'))==null||s.classList.add("z-50")}),n.addEventListener("close",()=>{var e,t,i,o,a,s;(t=(e=r.shadowRoot)==null?void 0:e.querySelector("sd-6-9-0-popup"))==null||t.removeAttribute("active"),(o=(i=r.shadowRoot)==null?void 0:i.querySelector('[part="border"]'))==null||o.classList.remove("rounded-b-none"),(s=(a=r.shadowRoot)==null?void 0:a.querySelector('[part="form-control"]'))==null||s.classList.remove("z-50")}),p&&n.addEventListener("navigate",()=>{let e=r.shadowRoot.querySelector('[aria-selected="true"]');e==null||e.scrollIntoView({block:"nearest"})}),{config:{selector:()=>n,resultsList:{tag:"ul"},wrapper:!1}}}export{h as a};
@@ -1,2 +1,2 @@
1
1
  import{a as kt}from"./chunk.YFQFOIEM.js";import{a as Mt,b as O,d as Et,h as Rt}from"./chunk.CRLGS4QF.js";import{b as zt,e as Ot}from"./chunk.UOAG5PNU.js";import{a as C,b as F,c as dt,e as A}from"./chunk.6EV4YU6C.js";var _=Math.min,T=Math.max,ct=Math.round,ft=Math.floor,$=t=>({x:t,y:t}),me={left:"right",right:"left",bottom:"top",top:"bottom"},pe={start:"end",end:"start"};function pt(t,e,n){return T(t,_(e,n))}function Z(t,e){return typeof t=="function"?t(e):t}function Y(t){return t.split("-")[0]}function tt(t){return t.split("-")[1]}function Ct(t){return t==="x"?"y":"x"}function gt(t){return t==="y"?"height":"width"}var ge=new Set(["top","bottom"]);function j(t){return ge.has(Y(t))?"y":"x"}function wt(t){return Ct(j(t))}function Ft(t,e,n){n===void 0&&(n=!1);let i=tt(t),o=wt(t),s=gt(o),r=o==="x"?i===(n?"end":"start")?"right":"left":i==="start"?"bottom":"top";return e.reference[s]>e.floating[s]&&(r=at(r)),[r,at(r)]}function $t(t){let e=at(t);return[mt(t),e,mt(e)]}function mt(t){return t.replace(/start|end/g,e=>pe[e])}var Dt=["left","right"],Bt=["right","left"],we=["top","bottom"],ye=["bottom","top"];function xe(t,e,n){switch(t){case"top":case"bottom":return n?e?Bt:Dt:e?Dt:Bt;case"left":case"right":return e?we:ye;default:return[]}}function Nt(t,e,n,i){let o=tt(t),s=xe(Y(t),n==="start",i);return o&&(s=s.map(r=>r+"-"+o),e&&(s=s.concat(s.map(mt)))),s}function at(t){return t.replace(/left|right|bottom|top/g,e=>me[e])}function ve(t){return C({top:0,right:0,bottom:0,left:0},t)}function St(t){return typeof t!="number"?ve(t):{top:t,right:t,bottom:t,left:t}}function et(t){let{x:e,y:n,width:i,height:o}=t;return{width:i,height:o,top:n,left:e,right:e+i,bottom:n+o,x:e,y:n}}function Ht(t,e,n){let{reference:i,floating:o}=t,s=j(e),r=wt(e),l=gt(r),c=Y(e),a=s==="y",f=i.x+i.width/2-o.width/2,h=i.y+i.height/2-o.height/2,m=i[l]/2-o[l]/2,u;switch(c){case"top":u={x:f,y:i.y-o.height};break;case"bottom":u={x:f,y:i.y+i.height};break;case"right":u={x:i.x+i.width,y:h};break;case"left":u={x:i.x-o.width,y:h};break;default:u={x:i.x,y:i.y}}switch(tt(e)){case"start":u[r]-=m*(n&&a?-1:1);break;case"end":u[r]+=m*(n&&a?-1:1);break}return u}async function Wt(t,e){var n;e===void 0&&(e={});let{x:i,y:o,platform:s,rects:r,elements:l,strategy:c}=t,{boundary:a="clippingAncestors",rootBoundary:f="viewport",elementContext:h="floating",altBoundary:m=!1,padding:u=0}=Z(e,t),d=St(u),g=l[m?h==="floating"?"reference":"floating":h],w=et(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(g)))==null||n?g:g.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(l.floating)),boundary:a,rootBoundary:f,strategy:c})),y=h==="floating"?{x:i,y:o,width:r.floating.width,height:r.floating.height}:r.reference,v=await(s.getOffsetParent==null?void 0:s.getOffsetParent(l.floating)),b=await(s.isElement==null?void 0:s.isElement(v))?await(s.getScale==null?void 0:s.getScale(v))||{x:1,y:1}:{x:1,y:1},E=et(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:y,offsetParent:v,strategy:c}):y);return{top:(w.top-E.top+d.top)/b.y,bottom:(E.bottom-w.bottom+d.bottom)/b.y,left:(w.left-E.left+d.left)/b.x,right:(E.right-w.right+d.right)/b.x}}var Vt=async(t,e,n)=>{let{placement:i="bottom",strategy:o="absolute",middleware:s=[],platform:r}=n,l=s.filter(Boolean),c=await(r.isRTL==null?void 0:r.isRTL(e)),a=await r.getElementRects({reference:t,floating:e,strategy:o}),{x:f,y:h}=Ht(a,i,c),m=i,u={},d=0;for(let g=0;g<l.length;g++){var p;let{name:w,fn:y}=l[g],{x:v,y:b,data:E,reset:R}=await y({x:f,y:h,initialPlacement:i,placement:m,strategy:o,middlewareData:u,rects:a,platform:F(C({},r),{detectOverflow:(p=r.detectOverflow)!=null?p:Wt}),elements:{reference:t,floating:e}});f=v!=null?v:f,h=b!=null?b:h,u=F(C({},u),{[w]:C(C({},u[w]),E)}),R&&d<=50&&(d++,typeof R=="object"&&(R.placement&&(m=R.placement),R.rects&&(a=R.rects===!0?await r.getElementRects({reference:t,floating:e,strategy:o}):R.rects),{x:f,y:h}=Ht(a,m,c)),g=-1)}return{x:f,y:h,placement:m,strategy:o,middlewareData:u}},_t=t=>({name:"arrow",options:t,async fn(e){let{x:n,y:i,placement:o,rects:s,platform:r,elements:l,middlewareData:c}=e,{element:a,padding:f=0}=Z(t,e)||{};if(a==null)return{};let h=St(f),m={x:n,y:i},u=wt(o),d=gt(u),p=await r.getDimensions(a),g=u==="y",w=g?"top":"left",y=g?"bottom":"right",v=g?"clientHeight":"clientWidth",b=s.reference[d]+s.reference[u]-m[u]-s.floating[d],E=m[u]-s.reference[u],R=await(r.getOffsetParent==null?void 0:r.getOffsetParent(a)),S=R?R[v]:0;(!S||!await(r.isElement==null?void 0:r.isElement(R)))&&(S=l.floating[v]||s.floating[d]);let I=b/2-E/2,W=S/2-p[d]/2-1,z=_(h[w],W),U=_(h[y],W),V=z,K=S-p[d]-U,P=S/2-p[d]/2+I,D=pt(V,P,K),J=!c.arrow&&tt(o)!=null&&P!==D&&s.reference[d]/2-(P<V?z:U)-p[d]/2<0,X=J?P<V?P-V:P-K:0;return{[u]:m[u]+X,data:C({[u]:D,centerOffset:P-D-X},J&&{alignmentOffset:X}),reset:J}}});var jt=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var n,i;let{placement:o,middlewareData:s,rects:r,initialPlacement:l,platform:c,elements:a}=e,P=Z(t,e),{mainAxis:f=!0,crossAxis:h=!0,fallbackPlacements:m,fallbackStrategy:u="bestFit",fallbackAxisSideDirection:d="none",flipAlignment:p=!0}=P,g=dt(P,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((n=s.arrow)!=null&&n.alignmentOffset)return{};let w=Y(o),y=j(l),v=Y(l)===l,b=await(c.isRTL==null?void 0:c.isRTL(a.floating)),E=m||(v||!p?[at(l)]:$t(l)),R=d!=="none";!m&&R&&E.push(...Nt(l,p,d,b));let S=[l,...E],I=await c.detectOverflow(e,g),W=[],z=((i=s.flip)==null?void 0:i.overflows)||[];if(f&&W.push(I[w]),h){let D=Ft(o,r,b);W.push(I[D[0]],I[D[1]])}if(z=[...z,{placement:o,overflows:W}],!W.every(D=>D<=0)){var U,V;let D=(((U=s.flip)==null?void 0:U.index)||0)+1,J=S[D];if(J&&(!(h==="alignment"?y!==j(J):!1)||z.every(B=>j(B.placement)===y?B.overflows[0]>0:!0)))return{data:{index:D,overflows:z},reset:{placement:J}};let X=(V=z.filter(Q=>Q.overflows[0]<=0).sort((Q,B)=>Q.overflows[1]-B.overflows[1])[0])==null?void 0:V.placement;if(!X)switch(u){case"bestFit":{var K;let Q=(K=z.filter(B=>{if(R){let G=j(B.placement);return G===y||G==="y"}return!0}).map(B=>[B.placement,B.overflows.filter(G=>G>0).reduce((G,de)=>G+de,0)]).sort((B,G)=>B[1]-G[1])[0])==null?void 0:K[0];Q&&(X=Q);break}case"initialPlacement":X=l;break}if(o!==X)return{reset:{placement:X}}}return{}}}};var be=new Set(["left","top"]);async function Ae(t,e){let{placement:n,platform:i,elements:o}=t,s=await(i.isRTL==null?void 0:i.isRTL(o.floating)),r=Y(n),l=tt(n),c=j(n)==="y",a=be.has(r)?-1:1,f=s&&c?-1:1,h=Z(e,t),{mainAxis:m,crossAxis:u,alignmentAxis:d}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:h.mainAxis||0,crossAxis:h.crossAxis||0,alignmentAxis:h.alignmentAxis};return l&&typeof d=="number"&&(u=l==="end"?d*-1:d),c?{x:u*f,y:m*a}:{x:m*a,y:u*f}}var It=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var n,i;let{x:o,y:s,placement:r,middlewareData:l}=e,c=await Ae(e,t);return r===((n=l.offset)==null?void 0:n.placement)&&(i=l.arrow)!=null&&i.alignmentOffset?{}:{x:o+c.x,y:s+c.y,data:F(C({},c),{placement:r})}}}},Xt=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){let{x:n,y:i,placement:o,platform:s}=e,w=Z(t,e),{mainAxis:r=!0,crossAxis:l=!1,limiter:c={fn:y=>{let{x:v,y:b}=y;return{x:v,y:b}}}}=w,a=dt(w,["mainAxis","crossAxis","limiter"]),f={x:n,y:i},h=await s.detectOverflow(e,a),m=j(Y(o)),u=Ct(m),d=f[u],p=f[m];if(r){let y=u==="y"?"top":"left",v=u==="y"?"bottom":"right",b=d+h[y],E=d-h[v];d=pt(b,d,E)}if(l){let y=m==="y"?"top":"left",v=m==="y"?"bottom":"right",b=p+h[y],E=p-h[v];p=pt(b,p,E)}let g=c.fn(F(C({},e),{[u]:d,[m]:p}));return F(C({},g),{data:{x:g.x-n,y:g.y-i,enabled:{[u]:r,[m]:l}}})}}};var Yt=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var n,i;let{placement:o,rects:s,platform:r,elements:l}=e,z=Z(t,e),{apply:c=()=>{}}=z,a=dt(z,["apply"]),f=await r.detectOverflow(e,a),h=Y(o),m=tt(o),u=j(o)==="y",{width:d,height:p}=s.floating,g,w;h==="top"||h==="bottom"?(g=h,w=m===(await(r.isRTL==null?void 0:r.isRTL(l.floating))?"start":"end")?"left":"right"):(w=h,g=m==="end"?"top":"bottom");let y=p-f.top-f.bottom,v=d-f.left-f.right,b=_(p-f[g],y),E=_(d-f[w],v),R=!e.middlewareData.shift,S=b,I=E;if((n=e.middlewareData.shift)!=null&&n.enabled.x&&(I=v),(i=e.middlewareData.shift)!=null&&i.enabled.y&&(S=y),R&&!m){let U=T(f.left,0),V=T(f.right,0),K=T(f.top,0),P=T(f.bottom,0);u?I=d-2*(U!==0||V!==0?U+V:T(f.left,f.right)):S=p-2*(K!==0||P!==0?K+P:T(f.top,f.bottom))}await c(F(C({},e),{availableWidth:I,availableHeight:S}));let W=await r.getDimensions(l.floating);return d!==W.width||p!==W.height?{reset:{rects:!0}}:{}}}};function yt(){return typeof window!="undefined"}function nt(t){return Ut(t)?(t.nodeName||"").toLowerCase():"#document"}function L(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function N(t){var e;return(e=(Ut(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function Ut(t){return yt()?t instanceof Node||t instanceof L(t).Node:!1}function M(t){return yt()?t instanceof Element||t instanceof L(t).Element:!1}function H(t){return yt()?t instanceof HTMLElement||t instanceof L(t).HTMLElement:!1}function qt(t){return!yt()||typeof ShadowRoot=="undefined"?!1:t instanceof ShadowRoot||t instanceof L(t).ShadowRoot}var Oe=new Set(["inline","contents"]);function st(t){let{overflow:e,overflowX:n,overflowY:i,display:o}=k(t);return/auto|scroll|overlay|hidden|clip/.test(e+i+n)&&!Oe.has(o)}var Ee=new Set(["table","td","th"]);function Kt(t){return Ee.has(nt(t))}var Re=[":popover-open",":modal"];function ut(t){return Re.some(e=>{try{return t.matches(e)}catch(n){return!1}})}var Ce=["transform","translate","scale","rotate","perspective"],Se=["transform","translate","scale","rotate","perspective","filter"],Te=["paint","layout","strict","content"];function xt(t){let e=vt(),n=M(t)?k(t):t;return Ce.some(i=>n[i]?n[i]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!e&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!e&&(n.filter?n.filter!=="none":!1)||Se.some(i=>(n.willChange||"").includes(i))||Te.some(i=>(n.contain||"").includes(i))}function Gt(t){let e=q(t);for(;H(e)&&!it(e);){if(xt(e))return e;if(ut(e))return null;e=q(e)}return null}function vt(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}var Le=new Set(["html","body","#document"]);function it(t){return Le.has(nt(t))}function k(t){return L(t).getComputedStyle(t)}function ht(t){return M(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function q(t){if(nt(t)==="html")return t;let e=t.assignedSlot||t.parentNode||qt(t)&&t.host||N(t);return qt(e)?e.host:e}function Jt(t){let e=q(t);return it(e)?t.ownerDocument?t.ownerDocument.body:t.body:H(e)&&st(e)?e:Jt(e)}function rt(t,e,n){var i;e===void 0&&(e=[]),n===void 0&&(n=!0);let o=Jt(t),s=o===((i=t.ownerDocument)==null?void 0:i.body),r=L(o);if(s){let l=bt(r);return e.concat(r,r.visualViewport||[],st(o)?o:[],l&&n?rt(l):[])}return e.concat(o,rt(o,[],n))}function bt(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function ee(t){let e=k(t),n=parseFloat(e.width)||0,i=parseFloat(e.height)||0,o=H(t),s=o?t.offsetWidth:n,r=o?t.offsetHeight:i,l=ct(n)!==s||ct(i)!==r;return l&&(n=s,i=r),{width:n,height:i,$:l}}function Lt(t){return M(t)?t:t.contextElement}function lt(t){let e=Lt(t);if(!H(e))return $(1);let n=e.getBoundingClientRect(),{width:i,height:o,$:s}=ee(e),r=(s?ct(n.width):n.width)/i,l=(s?ct(n.height):n.height)/o;return(!r||!Number.isFinite(r))&&(r=1),(!l||!Number.isFinite(l))&&(l=1),{x:r,y:l}}var Pe=$(0);function ne(t){let e=L(t);return!vt()||!e.visualViewport?Pe:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function ze(t,e,n){return e===void 0&&(e=!1),!n||e&&n!==L(t)?!1:e}function ot(t,e,n,i){e===void 0&&(e=!1),n===void 0&&(n=!1);let o=t.getBoundingClientRect(),s=Lt(t),r=$(1);e&&(i?M(i)&&(r=lt(i)):r=lt(t));let l=ze(s,n,i)?ne(s):$(0),c=(o.left+l.x)/r.x,a=(o.top+l.y)/r.y,f=o.width/r.x,h=o.height/r.y;if(s){let m=L(s),u=i&&M(i)?L(i):i,d=m,p=bt(d);for(;p&&i&&u!==d;){let g=lt(p),w=p.getBoundingClientRect(),y=k(p),v=w.left+(p.clientLeft+parseFloat(y.paddingLeft))*g.x,b=w.top+(p.clientTop+parseFloat(y.paddingTop))*g.y;c*=g.x,a*=g.y,f*=g.x,h*=g.y,c+=v,a+=b,d=L(p),p=bt(d)}}return et({width:f,height:h,x:c,y:a})}function At(t,e){let n=ht(t).scrollLeft;return e?e.left+n:ot(N(t)).left+n}function ie(t,e){let n=t.getBoundingClientRect(),i=n.left+e.scrollLeft-At(t,n),o=n.top+e.scrollTop;return{x:i,y:o}}function Me(t){let{elements:e,rect:n,offsetParent:i,strategy:o}=t,s=o==="fixed",r=N(i),l=e?ut(e.floating):!1;if(i===r||l&&s)return n;let c={scrollLeft:0,scrollTop:0},a=$(1),f=$(0),h=H(i);if((h||!h&&!s)&&((nt(i)!=="body"||st(r))&&(c=ht(i)),H(i))){let u=ot(i);a=lt(i),f.x=u.x+i.clientLeft,f.y=u.y+i.clientTop}let m=r&&!h&&!s?ie(r,c):$(0);return{width:n.width*a.x,height:n.height*a.y,x:n.x*a.x-c.scrollLeft*a.x+f.x+m.x,y:n.y*a.y-c.scrollTop*a.y+f.y+m.y}}function ke(t){return Array.from(t.getClientRects())}function De(t){let e=N(t),n=ht(t),i=t.ownerDocument.body,o=T(e.scrollWidth,e.clientWidth,i.scrollWidth,i.clientWidth),s=T(e.scrollHeight,e.clientHeight,i.scrollHeight,i.clientHeight),r=-n.scrollLeft+At(t),l=-n.scrollTop;return k(i).direction==="rtl"&&(r+=T(e.clientWidth,i.clientWidth)-o),{width:o,height:s,x:r,y:l}}var Qt=25;function Be(t,e){let n=L(t),i=N(t),o=n.visualViewport,s=i.clientWidth,r=i.clientHeight,l=0,c=0;if(o){s=o.width,r=o.height;let f=vt();(!f||f&&e==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}let a=At(i);if(a<=0){let f=i.ownerDocument,h=f.body,m=getComputedStyle(h),u=f.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,d=Math.abs(i.clientWidth-h.clientWidth-u);d<=Qt&&(s-=d)}else a<=Qt&&(s+=a);return{width:s,height:r,x:l,y:c}}var Fe=new Set(["absolute","fixed"]);function $e(t,e){let n=ot(t,!0,e==="fixed"),i=n.top+t.clientTop,o=n.left+t.clientLeft,s=H(t)?lt(t):$(1),r=t.clientWidth*s.x,l=t.clientHeight*s.y,c=o*s.x,a=i*s.y;return{width:r,height:l,x:c,y:a}}function Zt(t,e,n){let i;if(e==="viewport")i=Be(t,n);else if(e==="document")i=De(N(t));else if(M(e))i=$e(e,n);else{let o=ne(t);i={x:e.x-o.x,y:e.y-o.y,width:e.width,height:e.height}}return et(i)}function oe(t,e){let n=q(t);return n===e||!M(n)||it(n)?!1:k(n).position==="fixed"||oe(n,e)}function Ne(t,e){let n=e.get(t);if(n)return n;let i=rt(t,[],!1).filter(l=>M(l)&&nt(l)!=="body"),o=null,s=k(t).position==="fixed",r=s?q(t):t;for(;M(r)&&!it(r);){let l=k(r),c=xt(r);!c&&l.position==="fixed"&&(o=null),(s?!c&&!o:!c&&l.position==="static"&&!!o&&Fe.has(o.position)||st(r)&&!c&&oe(t,r))?i=i.filter(f=>f!==r):o=l,r=q(r)}return e.set(t,i),i}function He(t){let{element:e,boundary:n,rootBoundary:i,strategy:o}=t,r=[...n==="clippingAncestors"?ut(e)?[]:Ne(e,this._c):[].concat(n),i],l=r[0],c=r.reduce((a,f)=>{let h=Zt(e,f,o);return a.top=T(h.top,a.top),a.right=_(h.right,a.right),a.bottom=_(h.bottom,a.bottom),a.left=T(h.left,a.left),a},Zt(e,l,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function We(t){let{width:e,height:n}=ee(t);return{width:e,height:n}}function Ve(t,e,n){let i=H(e),o=N(e),s=n==="fixed",r=ot(t,!0,s,e),l={scrollLeft:0,scrollTop:0},c=$(0);function a(){c.x=At(o)}if(i||!i&&!s)if((nt(e)!=="body"||st(o))&&(l=ht(e)),i){let u=ot(e,!0,s,e);c.x=u.x+e.clientLeft,c.y=u.y+e.clientTop}else o&&a();s&&!i&&o&&a();let f=o&&!i&&!s?ie(o,l):$(0),h=r.left+l.scrollLeft-c.x-f.x,m=r.top+l.scrollTop-c.y-f.y;return{x:h,y:m,width:r.width,height:r.height}}function Tt(t){return k(t).position==="static"}function te(t,e){if(!H(t)||k(t).position==="fixed")return null;if(e)return e(t);let n=t.offsetParent;return N(t)===n&&(n=n.ownerDocument.body),n}function re(t,e){let n=L(t);if(ut(t))return n;if(!H(t)){let o=q(t);for(;o&&!it(o);){if(M(o)&&!Tt(o))return o;o=q(o)}return n}let i=te(t,e);for(;i&&Kt(i)&&Tt(i);)i=te(i,e);return i&&it(i)&&Tt(i)&&!xt(i)?n:i||Gt(t)||n}var _e=async function(t){let e=this.getOffsetParent||re,n=this.getDimensions,i=await n(t.floating);return{reference:Ve(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}};function je(t){return k(t).direction==="rtl"}var Ie={convertOffsetParentRelativeRectToViewportRelativeRect:Me,getDocumentElement:N,getClippingRect:He,getOffsetParent:re,getElementRects:_e,getClientRects:ke,getDimensions:We,getScale:lt,isElement:M,isRTL:je};function se(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function Xe(t,e){let n=null,i,o=N(t);function s(){var l;clearTimeout(i),(l=n)==null||l.disconnect(),n=null}function r(l,c){l===void 0&&(l=!1),c===void 0&&(c=1),s();let a=t.getBoundingClientRect(),{left:f,top:h,width:m,height:u}=a;if(l||e(),!m||!u)return;let d=ft(h),p=ft(o.clientWidth-(f+m)),g=ft(o.clientHeight-(h+u)),w=ft(f),v={rootMargin:-d+"px "+-p+"px "+-g+"px "+-w+"px",threshold:T(0,_(1,c))||1},b=!0;function E(R){let S=R[0].intersectionRatio;if(S!==c){if(!b)return r();S?r(!1,S):i=setTimeout(()=>{r(!1,1e-7)},1e3)}S===1&&!se(a,t.getBoundingClientRect())&&r(),b=!1}try{n=new IntersectionObserver(E,F(C({},v),{root:o.ownerDocument}))}catch(R){n=new IntersectionObserver(E,v)}n.observe(t)}return r(!0),s}function le(t,e,n,i){i===void 0&&(i={});let{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:r=typeof ResizeObserver=="function",layoutShift:l=typeof IntersectionObserver=="function",animationFrame:c=!1}=i,a=Lt(t),f=o||s?[...a?rt(a):[],...rt(e)]:[];f.forEach(w=>{o&&w.addEventListener("scroll",n,{passive:!0}),s&&w.addEventListener("resize",n)});let h=a&&l?Xe(a,n):null,m=-1,u=null;r&&(u=new ResizeObserver(w=>{let[y]=w;y&&y.target===a&&u&&(u.unobserve(e),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var v;(v=u)==null||v.observe(e)})),n()}),a&&!c&&u.observe(a),u.observe(e));let d,p=c?ot(t):null;c&&g();function g(){let w=ot(t);p&&!se(p,w)&&n(),p=w,d=requestAnimationFrame(g)}return n(),()=>{var w;f.forEach(y=>{o&&y.removeEventListener("scroll",n),s&&y.removeEventListener("resize",n)}),h==null||h(),(w=u)==null||w.disconnect(),u=null,c&&cancelAnimationFrame(d)}}var ae=It;var ce=Xt,fe=jt,Pt=Yt;var ue=_t;var he=(t,e,n)=>{let i=new Map,o=C({platform:Ie},n),s=F(C({},o.platform),{_c:i});return Vt(t,e,F(C({},o),{platform:s}))};var x=class extends Rt{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(n){super.updated(n),n.has("active")&&(this.active?this.start():this.stop()),n.has("anchor")&&this.handleAnchorChange(),this.active&&(await this.updateComplete,this.reposition())}setupMutationObserver(){this.mutationObserver=new MutationObserver(i=>this.handleCurrentPlacementChange(i));let n={attributes:!0};this.mutationObserver.observe(this,n)}handleCurrentPlacementChange(n){return n.forEach(i=>{if(i.attributeName==="data-current-placement"){let o=this.getAttribute("data-current-placement");this.emit("sd-current-placement",{detail:o})}})}async handleAnchorChange(){if(await this.stop(),this.anchor&&typeof this.anchor=="string"){let n=this.getRootNode();this.anchorEl=n.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=le(this.anchorEl,this.popup,()=>{this.reposition()}))}async stop(){return new Promise(n=>{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(()=>n())):n()})}reposition(){if(!this.active||!this.anchorEl)return;let n=[ae({mainAxis:this.distance,crossAxis:this.skidding})];this.sync?n.push(Pt({apply:({rects:i})=>{let o=this.sync==="width"||this.sync==="both",s=this.sync==="height"||this.sync==="both";this.popup.style.width=o?`${i.reference.width}px`:"",this.popup.style.height=s?`${i.reference.height}px`:""}})):(this.popup.style.width="",this.popup.style.height=""),this.flip&&n.push(fe({boundary:this.flipBoundary,fallbackPlacements:this.flipFallbackPlacements,fallbackStrategy:this.flipFallbackStrategy==="best-fit"?"bestFit":"initialPlacement",padding:this.flipPadding})),this.shift&&n.push(ce({boundary:this.shiftBoundary,padding:this.shiftPadding})),this.autoSize?n.push(Pt({boundary:this.autoSizeBoundary,padding:this.autoSizePadding,apply:({availableWidth:i,availableHeight:o})=>{this.autoSize==="vertical"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-height",`${o}px`):this.style.removeProperty("--auto-size-available-height"),this.autoSize==="horizontal"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-width",`${i}px`):this.style.removeProperty("--auto-size-available-width")}})):(this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height")),this.arrow&&n.push(ue({element:this.arrowEl,padding:this.arrowPadding})),he(this.anchorEl,this.popup,{placement:this.placement,middleware:n,strategy:this.strategy}).then(({x:i,y:o,middlewareData:s,placement:r})=>{let l=getComputedStyle(this).direction==="rtl",c={top:"bottom",right:"left",bottom:"top",left:"right"}[r.split("-")[0]];if(this.setAttribute("data-current-placement",r),Object.assign(this.popup.style,{left:`${i}px`,top:`${o}px`}),this.arrow){let a=s.arrow.x,f=s.arrow.y,h="",m="",u="",d="";if(this.arrowPlacement==="start"){let p=typeof a=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";h=typeof f=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"",m=l?p:"",d=l?"":p}else if(this.arrowPlacement==="end"){let p=typeof a=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";m=l?"":p,d=l?p:"",u=typeof f=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:""}else this.arrowPlacement==="center"?(d=typeof a=="number"?"calc(50% - var(--arrow-size-diagonal))":"",h=typeof f=="number"?"calc(50% - var(--arrow-size-diagonal))":""):(d=typeof a=="number"?`${a}px`:"",h=typeof f=="number"?`${f}px`:"");Object.assign(this.arrowEl.style,{top:h,right:m,bottom:u,left:d,[c]:"calc(var(--arrow-size-diagonal) * -1)"})}}),this.emit("sd-reposition")}render(){return Ot`<slot name="anchor" @slotchange="${this.handleAnchorChange}"></slot><div part="popup" class="${kt("isolate",this.strategy!=="fixed"?"absolute":"fixed",!this.active&&"hidden")}"><slot></slot>${this.arrow?Ot`<div part="arrow" class="absolute rotate-45 -z-10" role="presentation"></div>`:""}</div>`}};x.styles=[...Rt.styles,zt`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
2
- :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-width:var(--auto-size-available-width,none);max-height:var(--auto-size-available-height,none)}[part=arrow]{width:calc(var(--arrow-size-diagonal) * 2);height:calc(var(--arrow-size-diagonal) * 2);background:var(--arrow-color)}`],A([Et('[part="popup"]')],x.prototype,"popup",2),A([Et('[part="arrow"]')],x.prototype,"arrowEl",2),A([O({reflect:!0})],x.prototype,"anchor",2),A([O({type:Boolean,reflect:!0})],x.prototype,"active",2),A([O({type:String,reflect:!0})],x.prototype,"placement",2),A([O({type:String,reflect:!0})],x.prototype,"strategy",2),A([O({type:Number,reflect:!0})],x.prototype,"distance",2),A([O({type:Number,reflect:!0})],x.prototype,"skidding",2),A([O({type:Boolean,reflect:!0})],x.prototype,"arrow",2),A([O({type:String,attribute:"arrow-placement",reflect:!0})],x.prototype,"arrowPlacement",2),A([O({attribute:"arrow-padding",type:Number,reflect:!0})],x.prototype,"arrowPadding",2),A([O({type:Boolean,reflect:!0})],x.prototype,"flip",2),A([O({attribute:"flip-fallback-placements",converter:{fromAttribute:n=>n.split(" ").map(i=>i.trim()).filter(i=>i!==""),toAttribute:n=>n.join(" ")}})],x.prototype,"flipFallbackPlacements",2),A([O({type:String,attribute:"flip-fallback-strategy"})],x.prototype,"flipFallbackStrategy",2),A([O({type:Object})],x.prototype,"flipBoundary",2),A([O({attribute:"flip-padding",type:Number})],x.prototype,"flipPadding",2),A([O({type:Boolean})],x.prototype,"shift",2),A([O({type:Object})],x.prototype,"shiftBoundary",2),A([O({attribute:"shift-padding",type:Number})],x.prototype,"shiftPadding",2),A([O({type:String,attribute:"auto-size"})],x.prototype,"autoSize",2),A([O()],x.prototype,"sync",2),A([O({type:Object})],x.prototype,"autoSizeBoundary",2),A([O({attribute:"auto-size-padding",type:Number})],x.prototype,"autoSizePadding",2),x=A([Mt("sd-6-8-0-popup")],x);export{x as a};
2
+ :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-width:var(--auto-size-available-width,none);max-height:var(--auto-size-available-height,none)}[part=arrow]{width:calc(var(--arrow-size-diagonal) * 2);height:calc(var(--arrow-size-diagonal) * 2);background:var(--arrow-color)}`],A([Et('[part="popup"]')],x.prototype,"popup",2),A([Et('[part="arrow"]')],x.prototype,"arrowEl",2),A([O({reflect:!0})],x.prototype,"anchor",2),A([O({type:Boolean,reflect:!0})],x.prototype,"active",2),A([O({type:String,reflect:!0})],x.prototype,"placement",2),A([O({type:String,reflect:!0})],x.prototype,"strategy",2),A([O({type:Number,reflect:!0})],x.prototype,"distance",2),A([O({type:Number,reflect:!0})],x.prototype,"skidding",2),A([O({type:Boolean,reflect:!0})],x.prototype,"arrow",2),A([O({type:String,attribute:"arrow-placement",reflect:!0})],x.prototype,"arrowPlacement",2),A([O({attribute:"arrow-padding",type:Number,reflect:!0})],x.prototype,"arrowPadding",2),A([O({type:Boolean,reflect:!0})],x.prototype,"flip",2),A([O({attribute:"flip-fallback-placements",converter:{fromAttribute:n=>n.split(" ").map(i=>i.trim()).filter(i=>i!==""),toAttribute:n=>n.join(" ")}})],x.prototype,"flipFallbackPlacements",2),A([O({type:String,attribute:"flip-fallback-strategy"})],x.prototype,"flipFallbackStrategy",2),A([O({type:Object})],x.prototype,"flipBoundary",2),A([O({attribute:"flip-padding",type:Number})],x.prototype,"flipPadding",2),A([O({type:Boolean})],x.prototype,"shift",2),A([O({type:Object})],x.prototype,"shiftBoundary",2),A([O({attribute:"shift-padding",type:Number})],x.prototype,"shiftPadding",2),A([O({type:String,attribute:"auto-size"})],x.prototype,"autoSize",2),A([O()],x.prototype,"sync",2),A([O({type:Object})],x.prototype,"autoSizeBoundary",2),A([O({attribute:"auto-size-padding",type:Number})],x.prototype,"autoSizePadding",2),x=A([Mt("sd-6-9-0-popup")],x);export{x as a};
@@ -1,12 +1,12 @@
1
- import{a as F}from"./chunk.W4EADN3G.js";import{c as A}from"./chunk.3L472FD4.js";import{b as I}from"./chunk.RAP66B6O.js";import{a as M}from"./chunk.CGQ2BPPZ.js";import{a as C,c as $}from"./chunk.B2NUKX6G.js";import{a as T}from"./chunk.KLRPP4NQ.js";import{a as L}from"./chunk.HLDWO3HP.js";import{a as z}from"./chunk.IQPMMUES.js";import{a as h}from"./chunk.YFQFOIEM.js";import{a as m}from"./chunk.NYKJXI3Q.js";import{a as D,b as r,c as u,d as c,g as k,h as O}from"./chunk.CRLGS4QF.js";import{b as E,e as p}from"./chunk.UOAG5PNU.js";import{b as x,e as w}from"./chunk.W4QBFD6E.js";import{e as s}from"./chunk.6EV4YU6C.js";var i=class extends O{constructor(){super(...arguments);this.formControlController=new I(this,{assumeInteractionOn:["sd-blur","sd-6-8-0-input"]});this.hasSlotController=new M(this,"help-text","label");this.localize=new z(this);this.typeToSelectString="";this.deletedTagLabel="";this.hasFocus=!1;this.selectedOptions=[];this.showValidStyle=!1;this.showInvalidStyle=!1;this.defaultValue="";this.open=!1;this.size="lg";this.placement="bottom";this.label="";this.placeholder="";this.maxOptionsTagLabel="";this.disabled=!1;this.visuallyDisabled=!1;this.helpText="";this.currentPlacement=this.placement;this.clearable=!1;this.multiple=!1;this.useTags=!1;this.maxOptionsVisible=3;this.form="";this.name="";this.value="";this.required=!1;this.floatingLabel=!1;this.styleOnValid=!1;this.hoist=!1;this.getTag=t=>p`<sd-6-8-0-tag class="relative z-10 min-w-0 max-w-full" ?disabled="${this.disabled}" part="tag" exportparts="
1
+ import{a as F}from"./chunk.W4EADN3G.js";import{c as A}from"./chunk.3L472FD4.js";import{b as I}from"./chunk.RAP66B6O.js";import{a as M}from"./chunk.CGQ2BPPZ.js";import{a as C,c as $}from"./chunk.B2NUKX6G.js";import{a as T}from"./chunk.KLRPP4NQ.js";import{a as L}from"./chunk.HLDWO3HP.js";import{a as z}from"./chunk.IQPMMUES.js";import{a as h}from"./chunk.YFQFOIEM.js";import{a as m}from"./chunk.NYKJXI3Q.js";import{a as D,b as r,c as u,d as c,g as k,h as O}from"./chunk.CRLGS4QF.js";import{b as E,e as p}from"./chunk.UOAG5PNU.js";import{b as x,e as w}from"./chunk.W4QBFD6E.js";import{e as s}from"./chunk.6EV4YU6C.js";var i=class extends O{constructor(){super(...arguments);this.formControlController=new I(this,{assumeInteractionOn:["sd-blur","sd-6-9-0-input"]});this.hasSlotController=new M(this,"help-text","label");this.localize=new z(this);this.typeToSelectString="";this.deletedTagLabel="";this.hasFocus=!1;this.selectedOptions=[];this.showValidStyle=!1;this.showInvalidStyle=!1;this.defaultValue="";this.open=!1;this.size="lg";this.placement="bottom";this.label="";this.placeholder="";this.maxOptionsTagLabel="";this.disabled=!1;this.visuallyDisabled=!1;this.helpText="";this.currentPlacement=this.placement;this.clearable=!1;this.multiple=!1;this.useTags=!1;this.maxOptionsVisible=3;this.form="";this.name="";this.value="";this.required=!1;this.floatingLabel=!1;this.styleOnValid=!1;this.hoist=!1;this.getTag=t=>p`<sd-6-9-0-tag class="relative z-10 min-w-0 max-w-full" ?disabled="${this.disabled}" part="tag" exportparts="
2
2
  base:tag__base,
3
3
  content:tag__content,
4
4
  removable-indicator:tag__removable-indicator,
5
- " size="${this.size==="sm"?"sm":"lg"}" removable @keydown="${e=>this.handleTagKeyDown(e,t)}" @sd-remove="${e=>this.handleTagRemove(e,t)}">${t.getTextLabel()}</sd-6-8-0-tag>`;this.handleDocumentFocusIn=t=>{let e=t.composedPath();this&&!e.includes(this)&&this.hide()};this.handleDocumentKeyDown=t=>{let e=t.target,o=e.closest(".select__clear")!==null,l=e.closest("sd-6-8-0-icon-button")!==null;if(!(o||l)){if(t.key==="Escape"&&this.open&&(t.preventDefault(),t.stopPropagation(),this.hide(),this.combobox.focus({preventScroll:!0})),t.key==="Enter"||t.key===" "&&this.typeToSelectString===""){if(t.preventDefault(),t.stopImmediatePropagation(),!this.open){this.show(),this.setCurrentOption(this.currentOption||this.getFirstOption(),t);return}this.currentOption&&!this.currentOption.disabled&&(this.multiple?this.toggleOptionSelection(this.currentOption):this.setSelectedOptions(this.currentOption),this.updateComplete.then(()=>{this.emit("sd-input"),this.emit("sd-change")}),this.multiple||(this.hide(),this.combobox.focus({preventScroll:!0})));return}if(["ArrowUp","ArrowDown","Home","End"].includes(t.key)){let d=this.getAllOptions(),n=d.indexOf(this.currentOption),a=Math.max(0,n);if(t.preventDefault(),!this.open&&(this.show(),this.currentOption))return;t.key==="ArrowDown"?(a=n+1,a>d.length-1&&(a=0)):t.key==="ArrowUp"?(a=n-1,a<0&&(a=d.length-1)):t.key==="Home"?a=0:t.key==="End"&&(a=d.length-1),this.setCurrentOption(d[a],t)}if(t.key.length===1||t.key==="Backspace"){let d=this.getAllOptions();if(t.metaKey||t.ctrlKey||t.altKey)return;if(!this.open){if(t.key==="Backspace")return;this.show()}t.stopPropagation(),t.preventDefault(),clearTimeout(this.typeToSelectTimeout),this.typeToSelectTimeout=window.setTimeout(()=>this.typeToSelectString="",1e3),t.key==="Backspace"?this.typeToSelectString=this.typeToSelectString.slice(0,-1):this.typeToSelectString+=t.key.toLowerCase();for(let n of d)if(n.getTextLabel().toLowerCase().startsWith(this.typeToSelectString)){this.setCurrentOption(n);break}}}};this.handleDocumentMouseDown=t=>{let e=t.composedPath();this&&!e.includes(this)&&this.hide()}}get validity(){return this.valueInput.validity}get validationMessage(){return this.valueInput.validationMessage}connectedCallback(){super.connectedCallback(),this.open=!1}firstUpdated(){this.applySizeToOptions()}addOpenListeners(){document.addEventListener("focusin",this.handleDocumentFocusIn),document.addEventListener("keydown",this.handleDocumentKeyDown),document.addEventListener("mousedown",this.handleDocumentMouseDown)}removeOpenListeners(){document.removeEventListener("focusin",this.handleDocumentFocusIn),document.removeEventListener("keydown",this.handleDocumentKeyDown),document.removeEventListener("mousedown",this.handleDocumentMouseDown)}handleFocus(){this.hasFocus=!0,this.displayInput.setSelectionRange(0,0),this.emit("sd-focus")}handleBlur(){this.hasFocus=!1,this.emit("sd-blur")}handleTagKeyDown(t,e){var o,l,d;if((t.key==="Backspace"||t.key==="Enter"||t.key===" ")&&this.multiple){t.preventDefault(),t.stopPropagation();let n=(o=t.currentTarget)==null?void 0:o.parentElement,a=(l=n==null?void 0:n.previousElementSibling)==null?void 0:l.querySelector("sd-6-8-0-tag"),f=(d=n==null?void 0:n.nextElementSibling)==null?void 0:d.querySelector("sd-6-8-0-tag");this.handleTagRemove(new CustomEvent("sd-remove"),e),this.updateComplete.then(()=>{f?f.focus():a?a.focus():this.focus({preventScroll:!0})})}}handleTagMaxOptionsKeyDown(t){(t.key==="Backspace"||t.key==="Enter")&&this.multiple&&(t.preventDefault(),t.stopPropagation(),this.handleTagRemove(new CustomEvent("sd-remove"),this.selectedOptions[this.selectedOptions.length-1]),this.updateComplete.then(()=>{var o;let e=(o=this.shadowRoot)==null?void 0:o.querySelectorAll("sd-6-8-0-tag");e&&e.length>0?e==null||e[(e==null?void 0:e.length)-1].focus():this.focus({preventScroll:!0})}))}handleLabelClick(){this.combobox.focus()}handleComboboxMouseDown(t){let o=t.composedPath().some(l=>l instanceof HTMLSlotElement&&l.name==="removable-indicator");this.disabled||o||this.visuallyDisabled||(t.preventDefault(),this.combobox.focus({preventScroll:!0}),this.open=!this.open,this.setCurrentOption(this.currentOption||this.getFirstOption(),t))}handleComboboxKeyDown(t){t.stopPropagation(),this.handleDocumentKeyDown(t)}handleClearClick(t){t.stopPropagation(),this.clearSelect()}clearSelect(){this.setSelectedOptions([]),this.combobox.focus({preventScroll:!0}),this.updateComplete.then(()=>{this.emit("sd-clear"),this.emit("sd-input"),this.emit("sd-change")})}handleClearMouseDown(t){t.stopPropagation(),t.preventDefault()}handleOptionClick(t){let o=t.target.closest("sd-6-8-0-option"),l=this.value;o&&!o.disabled&&(this.multiple?this.toggleOptionSelection(o):this.setSelectedOptions(o),this.updateComplete.then(()=>this.combobox.focus({preventScroll:!0})),this.value!==l&&this.updateComplete.then(()=>{this.emit("sd-input"),this.emit("sd-change")}),this.multiple||(this.hide(),this.combobox.focus({preventScroll:!0})))}handleDefaultSlotChange(){let t=this.getAllOptions(),e=Array.isArray(this.value)?this.value:[this.value],o=[];customElements.get("sd-6-8-0-option")?(t.forEach(l=>{this.multiple&&(l.checkbox=!0),o.push(l.value)}),this.setSelectedOptions(t.filter(l=>e.includes(l.value)))):customElements.whenDefined("sd-6-8-0-option").then(()=>this.handleDefaultSlotChange())}handleTagRemove(t,e){t.stopPropagation(),e||this.clearSelect(),e&&!this.disabled&&(this.toggleOptionSelection(e,!1),this.deletedTagLabel=this.localize.term("removed",e.textContent),this.updateComplete.then(()=>{this.emit("sd-input"),this.emit("sd-change")}))}getAllOptions(){return[...this.querySelectorAll("sd-6-8-0-option")]}getFirstOption(){return this.querySelector("sd-6-8-0-option")}setCurrentOption(t,e){this.getAllOptions().forEach(l=>{l.current=!1,l.tabIndex=-1,((e==null?void 0:e.type)==="keydown"||(e==null?void 0:e.type)==="mousedown")&&(l.isKeyboardFocus=!1)}),t&&(this.currentOption=t,t.current=!0,t.tabIndex=0,t.focus()),t&&(e==null?void 0:e.type)==="keydown"&&(t.isKeyboardFocus=!0)}setSelectedOptions(t){let e=this.getAllOptions(),o=Array.isArray(t)?t:[t];e.forEach(l=>l.selected=!1),o.length&&o.forEach(l=>l.selected=!0),Array.isArray(t)?this.selectionChanged():this.selectionChanged(t)}toggleOptionSelection(t,e){e===!0||e===!1?t.selected=e:t.selected=!t.selected,Array.isArray(t)?this.selectionChanged():this.selectionChanged(t)}get displayLabel(){var t,e;return this.multiple?this.useTags||this.value.length===0?"":this.localize.term("numOptionsSelected",this.selectedOptions.length):(e=(t=this.selectedOptions[0])==null?void 0:t.getTextLabel())!=null?e:""}selectionChanged(t){var e,o;t&&this.multiple?this.selectedOptions.find(l=>l.value===t.value)?this.selectedOptions=this.selectedOptions.filter(l=>l.value!==t.value):this.selectedOptions=[...this.selectedOptions,t]:this.selectedOptions=this.getAllOptions().filter(l=>l.selected),this.multiple?this.value=this.selectedOptions.map(l=>l.value):this.value=(o=(e=this.selectedOptions[0])==null?void 0:e.value)!=null?o:"",this.updateComplete.then(()=>{this.formControlController.updateValidity()})}get tags(){return this.selectedOptions.length<=this.maxOptionsVisible?this.selectedOptions.map((t,e)=>{if(e<this.maxOptionsVisible||this.maxOptionsVisible<=0){let o=this.getTag(t,e);return p`<div @sd-remove="${l=>this.handleTagRemove(l,t)}" class="max-w-full">${typeof o=="string"?L(o):o}</div>`}return[p``]}):[p`<sd-6-8-0-tag class="z-10 min-w-0 max-w-full" ?disabled="${this.disabled}" part="tag" exportparts="
5
+ " size="${this.size==="sm"?"sm":"lg"}" removable @keydown="${e=>this.handleTagKeyDown(e,t)}" @sd-remove="${e=>this.handleTagRemove(e,t)}">${t.getTextLabel()}</sd-6-9-0-tag>`;this.handleDocumentFocusIn=t=>{let e=t.composedPath();this&&!e.includes(this)&&this.hide()};this.handleDocumentKeyDown=t=>{let e=t.target,o=e.closest(".select__clear")!==null,l=e.closest("sd-6-9-0-icon-button")!==null;if(!(o||l)){if(t.key==="Escape"&&this.open&&(t.preventDefault(),t.stopPropagation(),this.hide(),this.combobox.focus({preventScroll:!0})),t.key==="Enter"||t.key===" "&&this.typeToSelectString===""){if(t.preventDefault(),t.stopImmediatePropagation(),!this.open){this.show(),this.setCurrentOption(this.currentOption||this.getFirstOption(),t);return}this.currentOption&&!this.currentOption.disabled&&(this.multiple?this.toggleOptionSelection(this.currentOption):this.setSelectedOptions(this.currentOption),this.updateComplete.then(()=>{this.emit("sd-input"),this.emit("sd-change")}),this.multiple||(this.hide(),this.combobox.focus({preventScroll:!0})));return}if(["ArrowUp","ArrowDown","Home","End"].includes(t.key)){let d=this.getAllOptions(),n=d.indexOf(this.currentOption),a=Math.max(0,n);if(t.preventDefault(),!this.open&&(this.show(),this.currentOption))return;t.key==="ArrowDown"?(a=n+1,a>d.length-1&&(a=0)):t.key==="ArrowUp"?(a=n-1,a<0&&(a=d.length-1)):t.key==="Home"?a=0:t.key==="End"&&(a=d.length-1),this.setCurrentOption(d[a],t)}if(t.key.length===1||t.key==="Backspace"){let d=this.getAllOptions();if(t.metaKey||t.ctrlKey||t.altKey)return;if(!this.open){if(t.key==="Backspace")return;this.show()}t.stopPropagation(),t.preventDefault(),clearTimeout(this.typeToSelectTimeout),this.typeToSelectTimeout=window.setTimeout(()=>this.typeToSelectString="",1e3),t.key==="Backspace"?this.typeToSelectString=this.typeToSelectString.slice(0,-1):this.typeToSelectString+=t.key.toLowerCase();for(let n of d)if(n.getTextLabel().toLowerCase().startsWith(this.typeToSelectString)){this.setCurrentOption(n);break}}}};this.handleDocumentMouseDown=t=>{let e=t.composedPath();this&&!e.includes(this)&&this.hide()}}get validity(){return this.valueInput.validity}get validationMessage(){return this.valueInput.validationMessage}connectedCallback(){super.connectedCallback(),this.open=!1}firstUpdated(){this.applySizeToOptions()}addOpenListeners(){document.addEventListener("focusin",this.handleDocumentFocusIn),document.addEventListener("keydown",this.handleDocumentKeyDown),document.addEventListener("mousedown",this.handleDocumentMouseDown)}removeOpenListeners(){document.removeEventListener("focusin",this.handleDocumentFocusIn),document.removeEventListener("keydown",this.handleDocumentKeyDown),document.removeEventListener("mousedown",this.handleDocumentMouseDown)}handleFocus(){this.hasFocus=!0,this.displayInput.setSelectionRange(0,0),this.emit("sd-focus")}handleBlur(){this.hasFocus=!1,this.emit("sd-blur")}handleTagKeyDown(t,e){var o,l,d;if((t.key==="Backspace"||t.key==="Enter"||t.key===" ")&&this.multiple){t.preventDefault(),t.stopPropagation();let n=(o=t.currentTarget)==null?void 0:o.parentElement,a=(l=n==null?void 0:n.previousElementSibling)==null?void 0:l.querySelector("sd-6-9-0-tag"),f=(d=n==null?void 0:n.nextElementSibling)==null?void 0:d.querySelector("sd-6-9-0-tag");this.handleTagRemove(new CustomEvent("sd-remove"),e),this.updateComplete.then(()=>{f?f.focus():a?a.focus():this.focus({preventScroll:!0})})}}handleTagMaxOptionsKeyDown(t){(t.key==="Backspace"||t.key==="Enter")&&this.multiple&&(t.preventDefault(),t.stopPropagation(),this.handleTagRemove(new CustomEvent("sd-remove"),this.selectedOptions[this.selectedOptions.length-1]),this.updateComplete.then(()=>{var o;let e=(o=this.shadowRoot)==null?void 0:o.querySelectorAll("sd-6-9-0-tag");e&&e.length>0?e==null||e[(e==null?void 0:e.length)-1].focus():this.focus({preventScroll:!0})}))}handleLabelClick(){this.combobox.focus()}handleComboboxMouseDown(t){let o=t.composedPath().some(l=>l instanceof HTMLSlotElement&&l.name==="removable-indicator");this.disabled||o||this.visuallyDisabled||(t.preventDefault(),this.combobox.focus({preventScroll:!0}),this.open=!this.open,this.setCurrentOption(this.currentOption||this.getFirstOption(),t))}handleComboboxKeyDown(t){t.stopPropagation(),this.handleDocumentKeyDown(t)}handleClearClick(t){t.stopPropagation(),this.clearSelect()}clearSelect(){this.setSelectedOptions([]),this.combobox.focus({preventScroll:!0}),this.updateComplete.then(()=>{this.emit("sd-clear"),this.emit("sd-input"),this.emit("sd-change")})}handleClearMouseDown(t){t.stopPropagation(),t.preventDefault()}handleOptionClick(t){let o=t.target.closest("sd-6-9-0-option"),l=this.value;o&&!o.disabled&&(this.multiple?this.toggleOptionSelection(o):this.setSelectedOptions(o),this.updateComplete.then(()=>this.combobox.focus({preventScroll:!0})),this.value!==l&&this.updateComplete.then(()=>{this.emit("sd-input"),this.emit("sd-change")}),this.multiple||(this.hide(),this.combobox.focus({preventScroll:!0})))}handleDefaultSlotChange(){let t=this.getAllOptions(),e=Array.isArray(this.value)?this.value:[this.value],o=[];customElements.get("sd-6-9-0-option")?(t.forEach(l=>{this.multiple&&(l.checkbox=!0),o.push(l.value)}),this.setSelectedOptions(t.filter(l=>e.includes(l.value)))):customElements.whenDefined("sd-6-9-0-option").then(()=>this.handleDefaultSlotChange())}handleTagRemove(t,e){t.stopPropagation(),e||this.clearSelect(),e&&!this.disabled&&(this.toggleOptionSelection(e,!1),this.deletedTagLabel=this.localize.term("removed",e.textContent),this.updateComplete.then(()=>{this.emit("sd-input"),this.emit("sd-change")}))}getAllOptions(){return[...this.querySelectorAll("sd-6-9-0-option")]}getFirstOption(){return this.querySelector("sd-6-9-0-option")}setCurrentOption(t,e){this.getAllOptions().forEach(l=>{l.current=!1,l.tabIndex=-1,((e==null?void 0:e.type)==="keydown"||(e==null?void 0:e.type)==="mousedown")&&(l.isKeyboardFocus=!1)}),t&&(this.currentOption=t,t.current=!0,t.tabIndex=0,t.focus()),t&&(e==null?void 0:e.type)==="keydown"&&(t.isKeyboardFocus=!0)}setSelectedOptions(t){let e=this.getAllOptions(),o=Array.isArray(t)?t:[t];e.forEach(l=>l.selected=!1),o.length&&o.forEach(l=>l.selected=!0),Array.isArray(t)?this.selectionChanged():this.selectionChanged(t)}toggleOptionSelection(t,e){e===!0||e===!1?t.selected=e:t.selected=!t.selected,Array.isArray(t)?this.selectionChanged():this.selectionChanged(t)}get displayLabel(){var t,e;return this.multiple?this.useTags||this.value.length===0?"":this.localize.term("numOptionsSelected",this.selectedOptions.length):(e=(t=this.selectedOptions[0])==null?void 0:t.getTextLabel())!=null?e:""}selectionChanged(t){var e,o;t&&this.multiple?this.selectedOptions.find(l=>l.value===t.value)?this.selectedOptions=this.selectedOptions.filter(l=>l.value!==t.value):this.selectedOptions=[...this.selectedOptions,t]:this.selectedOptions=this.getAllOptions().filter(l=>l.selected),this.multiple?this.value=this.selectedOptions.map(l=>l.value):this.value=(o=(e=this.selectedOptions[0])==null?void 0:e.value)!=null?o:"",this.updateComplete.then(()=>{this.formControlController.updateValidity()})}get tags(){return this.selectedOptions.length<=this.maxOptionsVisible?this.selectedOptions.map((t,e)=>{if(e<this.maxOptionsVisible||this.maxOptionsVisible<=0){let o=this.getTag(t,e);return p`<div @sd-remove="${l=>this.handleTagRemove(l,t)}" class="max-w-full">${typeof o=="string"?L(o):o}</div>`}return[p``]}):[p`<sd-6-9-0-tag class="z-10 min-w-0 max-w-full" ?disabled="${this.disabled}" part="tag" exportparts="
6
6
  base:tag__base,
7
7
  content:tag__content,
8
8
  removable-indicator:tag__removable-indicator,
9
- " size="${this.size==="sm"?"sm":"lg"}" removable @keydown="${t=>this.handleTagMaxOptionsKeyDown(t)}" @sd-remove="${t=>this.handleTagRemove(t)}">${this.selectedOptions.length} ${this.localize.term("tagsSelected")}</sd-6-8-0-tag>`]}handleInvalid(t){this.formControlController.setValidity(!1),this.formControlController.emitInvalidEvent(t),this.invalidMessage.textContent=t.target.validationMessage}handleCurrentPlacement(t){let e=t.detail;e&&(this.currentPlacement=e)}handleUseTagsChange(){let t=this.getAllOptions();customElements.get("sd-6-8-0-option")&&t.forEach(e=>{e.checkbox=this.multiple})}handleDisabledChange(){(this.disabled||this.visuallyDisabled)&&(this.open=!1,this.handleOpenChange())}async handleOpenChange(){if(this.open&&(!this.disabled||!this.visuallyDisabled)){this.setCurrentOption(this.selectedOptions[0]||this.getFirstOption()),this.emit("sd-show"),this.addOpenListeners(),await w(this),this.listbox.hidden=!1,this.popup.active=!0,requestAnimationFrame(()=>{this.setCurrentOption(this.currentOption)});let{keyframes:t,options:e}=$(this,"select.show",{dir:this.localize.dir()});await x(this.popup.popup,t,e),this.currentOption&&A(this.currentOption,this.listbox,"vertical","auto"),this.emit("sd-after-show")}else{this.emit("sd-hide"),this.removeOpenListeners(),await w(this);let{keyframes:t,options:e}=$(this,"select.hide",{dir:this.localize.dir()});await x(this.popup.popup,t,e),this.listbox.hidden=!0,this.popup.active=!1,this.emit("sd-after-hide")}}applySizeToOptions(){this._optionsInDefaultSlot.forEach(t=>{t.size=this.size})}handleValueChange(){let t=this.value,e=Array.isArray(t)?t:[t],o=this.selectedOptions.map(n=>n.value);if(e.length===o.length&&e.every(n=>o.includes(n)))return;let l=this.getAllOptions(),d=Array.isArray(this.value)?this.value:[this.value];this.setSelectedOptions(l.filter(n=>d.includes(n.value))),this.value=t}handleSizeChange(){this.size=this.floatingLabel&&this.size==="sm"?"md":this.size}async show(){if(this.open||this.disabled||this.visuallyDisabled){this.open=!1;return}return this.open=!0,T(this,"sd-after-show")}async hide(){if(!this.open||this.disabled){this.open=!1;return}return this.open=!1,T(this,"sd-after-hide")}checkValidity(){var t;return(t=this.valueInput)==null?void 0:t.checkValidity()}getForm(){return this.formControlController.getForm()}reportValidity(){return this.formControlController.fakeUserInteraction(),this.valueInput.reportValidity()}setCustomValidity(t){this.valueInput.setCustomValidity(t),this.formControlController.updateValidity()}focus(t){this.combobox.focus(t)}blur(){this.combobox.blur()}render(){let t={default:this.hasSlotController.test("[default]"),label:this.hasSlotController.test("label"),clearIcon:this.hasSlotController.test("clear-icon"),expandIcon:this.hasSlotController.test("expand-icon"),helpText:this.hasSlotController.test("help-text"),tooltip:this.hasSlotController.test("tooltip")},e=this.label?!0:!!t.label,o=this.helpText?!0:!!t.helpText,l=this.clearable&&!this.disabled,d=!!t.tooltip,n=this.value!==null&&String(this.value).length>0,a=this.floatingLabel&&e&&(this.hasFocus&&!this.visuallyDisabled||this.open||n)&&!(this.disabled&&!n),f=this.disabled?"disabled":this.visuallyDisabled&&!this.hasFocus?"visuallyDisabled":this.hasFocus&&this.showInvalidStyle?"activeInvalid":this.hasFocus&&this.styleOnValid&&this.showValidStyle?"activeValid":this.hasFocus||this.open?"active":this.showInvalidStyle?"invalid":this.styleOnValid&&this.showValidStyle?"valid":"default",b=this.disabled||this.visuallyDisabled?"cursor-not-allowed":"cursor-pointer",v={sm:"ml-1",md:"ml-2",lg:"ml-2"}[this.size],g={sm:"text-base",md:"text-lg",lg:"text-xl"}[this.size],V=this.size==="lg"?this.floatingLabel?a?"py-3":"py-4":"py-2":this.floatingLabel?a?"py-2":"py-3":"py-1";return p`<div part="form-control" class="${h("relative text-left",b,this.size==="sm"?"text-sm":"text-base",this.open&&"z-50")}"><span class="sr-only" aria-live="polite">${this.deletedTagLabel}</span> ${e&&!this.floatingLabel||d?p`<div class="flex items-center gap-1 mb-2"><label id="label" part="form-control-label" class="${e&&"inline-block form-control-color-text"}" aria-hidden="${e?"false":"true"}" @click="${this.handleLabelClick}"><slot name="label">${this.label}</slot></label> ${t.tooltip?p`<slot name="tooltip"></slot>`:""}</div>`:null}<div part="form-control-input" class="${h("relative w-full bg-white",f==="disabled"?"text-neutral-500":"form-control-color-text")}">${e&&this.floatingLabel?p`<label id="label" part="form-control-floating-label" class="${h("absolute left-4 z-20 pointer-events-none transition-all duration-200",a?this.size==="lg"?"top-2 text-xs":"top-1 text-xs":"top-1/2 -translate-y-1/2",a&&"mt-1")}" for="input"><span class="${h("leading-none",a&&!this.visuallyDisabled&&!this.disabled&&"form-control--filled__floating-label-color-text")}">${this.label}</span></label>`:null}<div part="border" class="${h("absolute top-0 w-full h-full pointer-events-none border rounded-default z-10 transition-[border] duration-medium ease-in-out",{disabled:"border-neutral-500",visuallyDisabled:"border-neutral-500",readonly:"form-control-color-border",activeInvalid:"border-error border-2",activeValid:"border-success border-2",active:"border-primary border-2",invalid:"border-error",valid:"border-success",default:"form-control-color-border"}[f],this.open&&(this.currentPlacement==="bottom"?"rounded-bl-none rounded-br-none":"rounded-tl-none rounded-tr-none"))}"></div><sd-6-8-0-popup @sd-current-placement="${this.handleCurrentPlacement}" class="${h("inline-flex relative w-full",this.currentPlacement==="bottom"?"origin-top":"origin-bottom")}" placement="${this.placement}" strategy="${this.hoist?"fixed":"absolute"}" flip sync="width" auto-size="vertical" auto-size-padding="10" exportparts="
9
+ " size="${this.size==="sm"?"sm":"lg"}" removable @keydown="${t=>this.handleTagMaxOptionsKeyDown(t)}" @sd-remove="${t=>this.handleTagRemove(t)}">${this.selectedOptions.length} ${this.localize.term("tagsSelected")}</sd-6-9-0-tag>`]}handleInvalid(t){this.formControlController.setValidity(!1),this.formControlController.emitInvalidEvent(t),this.invalidMessage.textContent=t.target.validationMessage}handleCurrentPlacement(t){let e=t.detail;e&&(this.currentPlacement=e)}handleUseTagsChange(){let t=this.getAllOptions();customElements.get("sd-6-9-0-option")&&t.forEach(e=>{e.checkbox=this.multiple})}handleDisabledChange(){(this.disabled||this.visuallyDisabled)&&(this.open=!1,this.handleOpenChange())}async handleOpenChange(){if(this.open&&(!this.disabled||!this.visuallyDisabled)){this.setCurrentOption(this.selectedOptions[0]||this.getFirstOption()),this.emit("sd-show"),this.addOpenListeners(),await w(this),this.listbox.hidden=!1,this.popup.active=!0,requestAnimationFrame(()=>{this.setCurrentOption(this.currentOption)});let{keyframes:t,options:e}=$(this,"select.show",{dir:this.localize.dir()});await x(this.popup.popup,t,e),this.currentOption&&A(this.currentOption,this.listbox,"vertical","auto"),this.emit("sd-after-show")}else{this.emit("sd-hide"),this.removeOpenListeners(),await w(this);let{keyframes:t,options:e}=$(this,"select.hide",{dir:this.localize.dir()});await x(this.popup.popup,t,e),this.listbox.hidden=!0,this.popup.active=!1,this.emit("sd-after-hide")}}applySizeToOptions(){this._optionsInDefaultSlot.forEach(t=>{t.size=this.size})}handleValueChange(){let t=this.value,e=Array.isArray(t)?t:[t],o=this.selectedOptions.map(n=>n.value);if(e.length===o.length&&e.every(n=>o.includes(n)))return;let l=this.getAllOptions(),d=Array.isArray(this.value)?this.value:[this.value];this.setSelectedOptions(l.filter(n=>d.includes(n.value))),this.value=t}handleSizeChange(){this.size=this.floatingLabel&&this.size==="sm"?"md":this.size}async show(){if(this.open||this.disabled||this.visuallyDisabled){this.open=!1;return}return this.open=!0,T(this,"sd-after-show")}async hide(){if(!this.open||this.disabled){this.open=!1;return}return this.open=!1,T(this,"sd-after-hide")}checkValidity(){var t;return(t=this.valueInput)==null?void 0:t.checkValidity()}getForm(){return this.formControlController.getForm()}reportValidity(){return this.formControlController.fakeUserInteraction(),this.valueInput.reportValidity()}setCustomValidity(t){this.valueInput.setCustomValidity(t),this.formControlController.updateValidity()}focus(t){this.combobox.focus(t)}blur(){this.combobox.blur()}render(){let t={default:this.hasSlotController.test("[default]"),label:this.hasSlotController.test("label"),clearIcon:this.hasSlotController.test("clear-icon"),expandIcon:this.hasSlotController.test("expand-icon"),helpText:this.hasSlotController.test("help-text"),tooltip:this.hasSlotController.test("tooltip")},e=this.label?!0:!!t.label,o=this.helpText?!0:!!t.helpText,l=this.clearable&&!this.disabled,d=!!t.tooltip,n=this.value!==null&&String(this.value).length>0,a=this.floatingLabel&&e&&(this.hasFocus&&!this.visuallyDisabled||this.open||n)&&!(this.disabled&&!n),f=this.disabled?"disabled":this.visuallyDisabled&&!this.hasFocus?"visuallyDisabled":this.hasFocus&&this.showInvalidStyle?"activeInvalid":this.hasFocus&&this.styleOnValid&&this.showValidStyle?"activeValid":this.hasFocus||this.open?"active":this.showInvalidStyle?"invalid":this.styleOnValid&&this.showValidStyle?"valid":"default",b=this.disabled||this.visuallyDisabled?"cursor-not-allowed":"cursor-pointer",v={sm:"ml-1",md:"ml-2",lg:"ml-2"}[this.size],g={sm:"text-base",md:"text-lg",lg:"text-xl"}[this.size],V=this.size==="lg"?this.floatingLabel?a?"py-3":"py-4":"py-2":this.floatingLabel?a?"py-2":"py-3":"py-1";return p`<div part="form-control" class="${h("relative text-left",b,this.size==="sm"?"text-sm":"text-base",this.open&&"z-50")}"><span class="sr-only" aria-live="polite">${this.deletedTagLabel}</span> ${e&&!this.floatingLabel||d?p`<div class="flex items-center gap-1 mb-2"><label id="label" part="form-control-label" class="${e&&"inline-block form-control-color-text"}" aria-hidden="${e?"false":"true"}" @click="${this.handleLabelClick}"><slot name="label">${this.label}</slot></label> ${t.tooltip?p`<slot name="tooltip"></slot>`:""}</div>`:null}<div part="form-control-input" class="${h("relative w-full bg-white",f==="disabled"?"text-neutral-500":"form-control-color-text")}">${e&&this.floatingLabel?p`<label id="label" part="form-control-floating-label" class="${h("absolute left-4 z-20 pointer-events-none transition-all duration-200",a?this.size==="lg"?"top-2 text-xs":"top-1 text-xs":"top-1/2 -translate-y-1/2",a&&"mt-1")}" for="input"><span class="${h("leading-none",a&&!this.visuallyDisabled&&!this.disabled&&"form-control--filled__floating-label-color-text")}">${this.label}</span></label>`:null}<div part="border" class="${h("absolute top-0 w-full h-full pointer-events-none border rounded-default z-10 transition-[border] duration-medium ease-in-out",{disabled:"border-neutral-500",visuallyDisabled:"border-neutral-500",readonly:"form-control-color-border",activeInvalid:"border-error border-2",activeValid:"border-success border-2",active:"border-primary border-2",invalid:"border-error",valid:"border-success",default:"form-control-color-border"}[f],this.open&&(this.currentPlacement==="bottom"?"rounded-bl-none rounded-br-none":"rounded-tl-none rounded-tr-none"))}"></div><sd-6-9-0-popup @sd-current-placement="${this.handleCurrentPlacement}" class="${h("inline-flex relative w-full",this.currentPlacement==="bottom"?"origin-top":"origin-bottom")}" placement="${this.placement}" strategy="${this.hoist?"fixed":"absolute"}" flip sync="width" auto-size="vertical" auto-size-padding="10" exportparts="
10
10
  popup:popup__content,
11
- "><div class="${h("relative w-full h-full grid rounded-default transition-colors hover:duration-fast ease-in-out",this.visuallyDisabled||this.disabled?"hover:bg-transparent":"hover:bg-neutral-200",["invalid","activeInvalid"].includes(f)&&"form-control--invalid-color-background")}" slot="anchor"><div class="${h("input-container items-center w-full h-full px-4 flex min-w-0",{sm:"py-1",md:"py-1",lg:"py-2"}[this.size],V)}"><input name="${this.name}" form="${this.form}" part="display-input" class="${h("top-0 left-0 appearance-none outline-none flex-grow bg-transparent flex-1 placeholder:text-neutral-700 min-w-0",b,this.multiple&&this.useTags&&this.value.length>0?"hidden":"",this.size==="sm"?a?"h-4":"h-6":a?"h-6":"h-8",a&&"leading-none mt-4")}" type="text" .disabled="${this.disabled}" placeholder="${!this.floatingLabel||a?this.placeholder||this.localize.term("selectDefaultPlaceholder"):""}" .value="${this.displayLabel}" autocomplete="off" spellcheck="false" autocapitalize="off" readonly="readonly" aria-controls="listbox" aria-expanded="${this.open?"true":"false"}" aria-haspopup="listbox" aria-labelledby="label" aria-disabled="${this.disabled||this.visuallyDisabled?"true":"false"}" aria-invalid="${this.showInvalidStyle}" aria-describedby="help-text invalid-message" role="combobox" tabindex="-1"> ${this.multiple&&this.useTags&&this.tags&&this.tags.length>0?p`<div part="tags" class="${h("flex-grow flex flex-wrap items-center gap-1 min-w-0",this.floatingLabel&&"pt-4")}">${this.tags}</div>`:""}<div aria-live="polite" id="control-value" class="absolute top-0 left-0 opacity-0 -z-10">${this.selectedOptions.map(y=>y==null?void 0:y.getTextLabel()).join(", ")}</div><input class="${h("value-input absolute top-0 left-0 w-full h-full opacity-0 -z-10",b)}" type="text" ?disabled="${this.disabled}" ?required="${this.required}" .value="${Array.isArray(this.value)?this.value.join(", "):this.value}" tabindex="-1" aria-controls="control-value" aria-hidden="true" @focus="${()=>this.focus()}" @invalid="${this.handleInvalid}"> ${l?p`<button part="clear-button" class="${h("select__clear flex justify-center",v,this.value.length>0?"visible":"hidden")}" type="button" aria-label="${this.localize.term("clearEntry")}" @mousedown="${this.handleClearMouseDown}" @click="${this.handleClearClick}" tabindex="-1"><slot name="clear-icon"><sd-6-8-0-icon class="${h("text-neutral-700 z-10",g)}" library="_internal" name="closing-round"></sd-6-8-0-icon></slot></button>`:""} ${this.showInvalidStyle?p`<sd-6-8-0-icon part="invalid-icon" class="${h(v,g,"text-error")}" library="_internal" name="risk"></sd-6-8-0-icon>`:""} ${this.styleOnValid&&this.showValidStyle?p`<sd-6-8-0-icon part="valid-icon" class="${h("flex-shrink-0 text-success",v,g)}" library="_internal" name="confirm-circle"></sd-6-8-0-icon>`:""}<slot name="expand-icon" part="expand-icon" class="${h("inline-flex ml-2 items-center transition-transform duration-medium ease-in-out",this.open?"rotate-180":"rotate-0",this.disabled||this.visuallyDisabled?"text-neutral-500":"text-primary",g)}"><sd-6-8-0-icon name="chevron-down" part="chevron" library="_internal" color="currentColor"></sd-6-8-0-icon></slot></div><button part="combobox" class="${h("relative w-full px-4 flex flex-row items-center rounded-default focus-visible:outline-none",b,this.open&&"shadow transition-shadow duration-medium ease-in-out",{sm:"min-h-[32px]",md:"min-h-[40px]",lg:"min-h-[48px]"}[this.size])}" type="button" @keydown="${this.handleComboboxKeyDown}" @mousedown="${this.handleComboboxMouseDown}" @focus="${this.handleFocus}" @blur="${this.handleBlur}" aria-labelledby="label"></button></div><div id="listbox" role="listbox" aria-expanded="${this.open?"true":"false"}" aria-multiselectable="${this.multiple?"true":"false"}" aria-labelledby="label" part="listbox" class="${h("bg-white px-2 py-3 relative border-primary overflow-y-auto",this.open&&"shadow transition-shadow duration-medium ease-in-out",this.currentPlacement==="bottom"?"border-r-2 border-b-2 border-l-2 rounded-br-default rounded-bl-default":"border-r-2 border-t-2 border-l-2 rounded-tr-default rounded-tl-default")}" tabindex="-1" @mouseup="${this.handleOptionClick}" @slotchange="${this.handleDefaultSlotChange}"><slot></slot></div></sd-6-8-0-popup></div><div class="text-sm text-neutral-700 mt-1" part="form-control-help-text" id="help-text" aria-hidden="${o?"false":"true"}"><slot name="help-text">${this.helpText}</slot></div></div>${this.formControlController.renderInvalidMessage(this.size)}`}};i.styles=[...O.styles,E`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
12
- :host{position:relative;display:block;width:auto}:host([required]) #label::after{content:' *'}:host([disabled]) ::-moz-placeholder,:host([visually-disabled]) ::-moz-placeholder{color:rgba(var(--sd-color-text-neutral-500))}:host([disabled]) ::placeholder,:host([visually-disabled]) ::placeholder{color:rgba(var(--sd-color-text-neutral-500))}[part=listbox]{max-height:var(--auto-size-available-height,auto)}.input-container,[part=combobox]{grid-column:1/1;grid-row:1/1}sd-6-8-0-popup::part(popup){z-index:var(--sd-z-index-dropdown,900)}sd-6-8-0-tag::part(base){border-radius:var(--sd-radius);padding-inline:var(--sd-spacing-1)}sd-6-8-0-tag::part(content){display:inline-block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:var(--tag-max-width,15ch)}sd-6-8-0-tag[size=lg]::part(base){padding-inline:var(--sd-spacing-2)}sd-6-8-0-tag[disabled=false]::part(base):hover{background-color:rgba(var(--sd-color-background-primary-100))}`],s([k({selector:"sd-6-8-0-option"})],i.prototype,"_optionsInDefaultSlot",2),s([c("sd-6-8-0-popup")],i.prototype,"popup",2),s([c('[part="combobox"]')],i.prototype,"combobox",2),s([c('[part="display-input"]')],i.prototype,"displayInput",2),s([c(".value-input")],i.prototype,"valueInput",2),s([c('[part="listbox"]')],i.prototype,"listbox",2),s([c("#invalid-message")],i.prototype,"invalidMessage",2),s([u()],i.prototype,"deletedTagLabel",2),s([u()],i.prototype,"hasFocus",2),s([u()],i.prototype,"currentOption",2),s([u()],i.prototype,"selectedOptions",2),s([u()],i.prototype,"showValidStyle",2),s([u()],i.prototype,"showInvalidStyle",2),s([F()],i.prototype,"defaultValue",2),s([r({type:Boolean,reflect:!0})],i.prototype,"open",2),s([r({type:String,reflect:!0})],i.prototype,"size",2),s([r({type:String,reflect:!0})],i.prototype,"placement",2),s([r({type:String,reflect:!0})],i.prototype,"label",2),s([r({type:String,reflect:!0})],i.prototype,"placeholder",2),s([r({type:String,attribute:"max-options-tag-label",reflect:!0})],i.prototype,"maxOptionsTagLabel",2),s([r({type:Boolean,reflect:!0})],i.prototype,"disabled",2),s([r({type:Boolean,reflect:!0,attribute:"visually-disabled"})],i.prototype,"visuallyDisabled",2),s([r({type:String,attribute:"help-text",reflect:!0})],i.prototype,"helpText",2),s([u()],i.prototype,"currentPlacement",2),s([r({type:Boolean,reflect:!0})],i.prototype,"clearable",2),s([r({type:Boolean,reflect:!0})],i.prototype,"multiple",2),s([r({type:Boolean,reflect:!0})],i.prototype,"useTags",2),s([r({attribute:"max-options-visible",type:Number,reflect:!0})],i.prototype,"maxOptionsVisible",2),s([r({reflect:!0})],i.prototype,"form",2),s([r({reflect:!0})],i.prototype,"name",2),s([r({converter:{fromAttribute:t=>t.split(" "),toAttribute:t=>t.join(" ")}})],i.prototype,"value",2),s([r({type:Boolean,reflect:!0})],i.prototype,"required",2),s([r({attribute:"floating-label",type:Boolean,reflect:!0})],i.prototype,"floatingLabel",2),s([r({type:Boolean,reflect:!0,attribute:"style-on-valid"})],i.prototype,"styleOnValid",2),s([r({type:Boolean,reflect:!0})],i.prototype,"hoist",2),s([r()],i.prototype,"getTag",2),s([m("useTags",{waitUntilFirstUpdate:!0})],i.prototype,"handleUseTagsChange",1),s([m(["disabled","visually-disabled"],{waitUntilFirstUpdate:!0})],i.prototype,"handleDisabledChange",1),s([m("open",{waitUntilFirstUpdate:!0})],i.prototype,"handleOpenChange",1),s([m("size",{waitUntilFirstUpdate:!0})],i.prototype,"applySizeToOptions",1),s([m("value",{waitUntilFirstUpdate:!0})],i.prototype,"handleValueChange",1),s([m(["size","floatingLabel"])],i.prototype,"handleSizeChange",1),i=s([D("sd-6-8-0-select")],i);C("select.show",{keyframes:[{opacity:0},{opacity:1}],options:{duration:"var(--sd-duration-medium, 300)",easing:"ease-in-out"}});C("select.hide",{keyframes:[{opacity:1},{opacity:0}],options:{duration:"var(--sd-duration-fast, 150)",easing:"ease-in-out"}});export{i as a};
11
+ "><div class="${h("relative w-full h-full grid rounded-default transition-colors hover:duration-fast ease-in-out",this.visuallyDisabled||this.disabled?"hover:bg-transparent":"hover:bg-neutral-200",["invalid","activeInvalid"].includes(f)&&"form-control--invalid-color-background")}" slot="anchor"><div class="${h("input-container items-center w-full h-full px-4 flex min-w-0",{sm:"py-1",md:"py-1",lg:"py-2"}[this.size],V)}"><input name="${this.name}" form="${this.form}" part="display-input" class="${h("top-0 left-0 appearance-none outline-none flex-grow bg-transparent flex-1 placeholder:text-neutral-700 min-w-0",b,this.multiple&&this.useTags&&this.value.length>0?"hidden":"",this.size==="sm"?a?"h-4":"h-6":a?"h-6":"h-8",a&&"leading-none mt-4")}" type="text" .disabled="${this.disabled}" placeholder="${!this.floatingLabel||a?this.placeholder||this.localize.term("selectDefaultPlaceholder"):""}" .value="${this.displayLabel}" autocomplete="off" spellcheck="false" autocapitalize="off" readonly="readonly" aria-controls="listbox" aria-expanded="${this.open?"true":"false"}" aria-haspopup="listbox" aria-labelledby="label" aria-disabled="${this.disabled||this.visuallyDisabled?"true":"false"}" aria-invalid="${this.showInvalidStyle}" aria-describedby="help-text invalid-message" role="combobox" tabindex="-1"> ${this.multiple&&this.useTags&&this.tags&&this.tags.length>0?p`<div part="tags" class="${h("flex-grow flex flex-wrap items-center gap-1 min-w-0",this.floatingLabel&&"pt-4")}">${this.tags}</div>`:""}<div aria-live="polite" id="control-value" class="absolute top-0 left-0 opacity-0 -z-10">${this.selectedOptions.map(y=>y==null?void 0:y.getTextLabel()).join(", ")}</div><input class="${h("value-input absolute top-0 left-0 w-full h-full opacity-0 -z-10",b)}" type="text" ?disabled="${this.disabled}" ?required="${this.required}" .value="${Array.isArray(this.value)?this.value.join(", "):this.value}" tabindex="-1" aria-controls="control-value" aria-hidden="true" @focus="${()=>this.focus()}" @invalid="${this.handleInvalid}"> ${l?p`<button part="clear-button" class="${h("select__clear flex justify-center",v,this.value.length>0?"visible":"hidden")}" type="button" aria-label="${this.localize.term("clearEntry")}" @mousedown="${this.handleClearMouseDown}" @click="${this.handleClearClick}" tabindex="-1"><slot name="clear-icon"><sd-6-9-0-icon class="${h("text-neutral-700 z-10",g)}" library="_internal" name="closing-round"></sd-6-9-0-icon></slot></button>`:""} ${this.showInvalidStyle?p`<sd-6-9-0-icon part="invalid-icon" class="${h(v,g,"text-error")}" library="_internal" name="risk"></sd-6-9-0-icon>`:""} ${this.styleOnValid&&this.showValidStyle?p`<sd-6-9-0-icon part="valid-icon" class="${h("flex-shrink-0 text-success",v,g)}" library="_internal" name="confirm-circle"></sd-6-9-0-icon>`:""}<slot name="expand-icon" part="expand-icon" class="${h("inline-flex ml-2 items-center transition-transform duration-medium ease-in-out",this.open?"rotate-180":"rotate-0",this.disabled||this.visuallyDisabled?"text-neutral-500":"text-primary",g)}"><sd-6-9-0-icon name="chevron-down" part="chevron" library="_internal" color="currentColor"></sd-6-9-0-icon></slot></div><button part="combobox" class="${h("relative w-full px-4 flex flex-row items-center rounded-default focus-visible:outline-none",b,this.open&&"shadow transition-shadow duration-medium ease-in-out",{sm:"min-h-[32px]",md:"min-h-[40px]",lg:"min-h-[48px]"}[this.size])}" type="button" @keydown="${this.handleComboboxKeyDown}" @mousedown="${this.handleComboboxMouseDown}" @focus="${this.handleFocus}" @blur="${this.handleBlur}" aria-labelledby="label"></button></div><div id="listbox" role="listbox" aria-expanded="${this.open?"true":"false"}" aria-multiselectable="${this.multiple?"true":"false"}" aria-labelledby="label" part="listbox" class="${h("bg-white px-2 py-3 relative border-primary overflow-y-auto",this.open&&"shadow transition-shadow duration-medium ease-in-out",this.currentPlacement==="bottom"?"border-r-2 border-b-2 border-l-2 rounded-br-default rounded-bl-default":"border-r-2 border-t-2 border-l-2 rounded-tr-default rounded-tl-default")}" tabindex="-1" @mouseup="${this.handleOptionClick}" @slotchange="${this.handleDefaultSlotChange}"><slot></slot></div></sd-6-9-0-popup></div><div class="text-sm text-neutral-700 mt-1" part="form-control-help-text" id="help-text" aria-hidden="${o?"false":"true"}"><slot name="help-text">${this.helpText}</slot></div></div>${this.formControlController.renderInvalidMessage(this.size)}`}};i.styles=[...O.styles,E`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
12
+ :host{position:relative;display:block;width:auto}:host([required]) #label::after{content:' *'}:host([disabled]) ::-moz-placeholder,:host([visually-disabled]) ::-moz-placeholder{color:rgba(var(--sd-color-text-neutral-500))}:host([disabled]) ::placeholder,:host([visually-disabled]) ::placeholder{color:rgba(var(--sd-color-text-neutral-500))}[part=listbox]{max-height:var(--auto-size-available-height,auto)}.input-container,[part=combobox]{grid-column:1/1;grid-row:1/1}sd-6-9-0-popup::part(popup){z-index:var(--sd-z-index-dropdown,900)}sd-6-9-0-tag::part(base){border-radius:var(--sd-radius);padding-inline:var(--sd-spacing-1)}sd-6-9-0-tag::part(content){display:inline-block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:var(--tag-max-width,15ch)}sd-6-9-0-tag[size=lg]::part(base){padding-inline:var(--sd-spacing-2)}sd-6-9-0-tag[disabled=false]::part(base):hover{background-color:rgba(var(--sd-color-background-primary-100))}`],s([k({selector:"sd-6-9-0-option"})],i.prototype,"_optionsInDefaultSlot",2),s([c("sd-6-9-0-popup")],i.prototype,"popup",2),s([c('[part="combobox"]')],i.prototype,"combobox",2),s([c('[part="display-input"]')],i.prototype,"displayInput",2),s([c(".value-input")],i.prototype,"valueInput",2),s([c('[part="listbox"]')],i.prototype,"listbox",2),s([c("#invalid-message")],i.prototype,"invalidMessage",2),s([u()],i.prototype,"deletedTagLabel",2),s([u()],i.prototype,"hasFocus",2),s([u()],i.prototype,"currentOption",2),s([u()],i.prototype,"selectedOptions",2),s([u()],i.prototype,"showValidStyle",2),s([u()],i.prototype,"showInvalidStyle",2),s([F()],i.prototype,"defaultValue",2),s([r({type:Boolean,reflect:!0})],i.prototype,"open",2),s([r({type:String,reflect:!0})],i.prototype,"size",2),s([r({type:String,reflect:!0})],i.prototype,"placement",2),s([r({type:String,reflect:!0})],i.prototype,"label",2),s([r({type:String,reflect:!0})],i.prototype,"placeholder",2),s([r({type:String,attribute:"max-options-tag-label",reflect:!0})],i.prototype,"maxOptionsTagLabel",2),s([r({type:Boolean,reflect:!0})],i.prototype,"disabled",2),s([r({type:Boolean,reflect:!0,attribute:"visually-disabled"})],i.prototype,"visuallyDisabled",2),s([r({type:String,attribute:"help-text",reflect:!0})],i.prototype,"helpText",2),s([u()],i.prototype,"currentPlacement",2),s([r({type:Boolean,reflect:!0})],i.prototype,"clearable",2),s([r({type:Boolean,reflect:!0})],i.prototype,"multiple",2),s([r({type:Boolean,reflect:!0})],i.prototype,"useTags",2),s([r({attribute:"max-options-visible",type:Number,reflect:!0})],i.prototype,"maxOptionsVisible",2),s([r({reflect:!0})],i.prototype,"form",2),s([r({reflect:!0})],i.prototype,"name",2),s([r({converter:{fromAttribute:t=>t.split(" "),toAttribute:t=>t.join(" ")}})],i.prototype,"value",2),s([r({type:Boolean,reflect:!0})],i.prototype,"required",2),s([r({attribute:"floating-label",type:Boolean,reflect:!0})],i.prototype,"floatingLabel",2),s([r({type:Boolean,reflect:!0,attribute:"style-on-valid"})],i.prototype,"styleOnValid",2),s([r({type:Boolean,reflect:!0})],i.prototype,"hoist",2),s([r()],i.prototype,"getTag",2),s([m("useTags",{waitUntilFirstUpdate:!0})],i.prototype,"handleUseTagsChange",1),s([m(["disabled","visually-disabled"],{waitUntilFirstUpdate:!0})],i.prototype,"handleDisabledChange",1),s([m("open",{waitUntilFirstUpdate:!0})],i.prototype,"handleOpenChange",1),s([m("size",{waitUntilFirstUpdate:!0})],i.prototype,"applySizeToOptions",1),s([m("value",{waitUntilFirstUpdate:!0})],i.prototype,"handleValueChange",1),s([m(["size","floatingLabel"])],i.prototype,"handleSizeChange",1),i=s([D("sd-6-9-0-select")],i);C("select.show",{keyframes:[{opacity:0},{opacity:1}],options:{duration:"var(--sd-duration-medium, 300)",easing:"ease-in-out"}});C("select.hide",{keyframes:[{opacity:1},{opacity:0}],options:{duration:"var(--sd-duration-fast, 150)",easing:"ease-in-out"}});export{i as a};
@@ -1,2 +1,2 @@
1
- import{a as N}from"./chunk.RMXFJHN6.js";import{a as B}from"./chunk.YQH4KNT6.js";import{a as A}from"./chunk.W4EADN3G.js";import{b as z}from"./chunk.RAP66B6O.js";import{a as r}from"./chunk.SLXPE3UU.js";import{a as M}from"./chunk.CGQ2BPPZ.js";import{a as P,b as V}from"./chunk.BSPQBW7U.js";import{a as T}from"./chunk.IQPMMUES.js";import{a}from"./chunk.YFQFOIEM.js";import{a as b}from"./chunk.NYKJXI3Q.js";import{a as E,b as s,c as m,d as w,h as $}from"./chunk.CRLGS4QF.js";import{b as D,e as n,h as F,i as L}from"./chunk.UOAG5PNU.js";import{a as k,e as i}from"./chunk.6EV4YU6C.js";var x=class extends N{constructor(e){super(e);this.handlePointerDown=e=>{e.button!==0||this.host.disabled||this.spinOnLongPressCallback(e)};this.handlePointerUp=e=>{e==null||e.preventDefault(),e==null||e.stopPropagation(),this.timeout&&this.callbacks.start(),this.stopSpinningAndCleanUp(),this.callbacks.end(),document.removeEventListener("pointerup",this.handlePointerUp)};if(e.type!==P.ELEMENT||!(e.element instanceof HTMLButtonElement))throw new Error("The `longPress` directive must be used on an HTMLButtonElement.")}render(e){return L}update(e,[l]){return this.callbacks===void 0&&this.host===void 0&&(this.host=e.element,this.callbacks=k({},l),this.host.addEventListener("pointerdown",this.handlePointerDown)),F}disconnected(){this.stopSpinningAndCleanUp(),this.host.removeEventListener("pointerdown",this.handlePointerDown),document.removeEventListener("pointerup",this.handlePointerUp)}spinOnLongPressCallback(e){var l;e.preventDefault(),e.stopPropagation(),this.timeout=setTimeout(()=>{this.timeout=void 0,this.interval=setInterval(()=>{this.callbacks.start()},50)},500),document.addEventListener("pointerup",this.handlePointerUp),(l=this.observer)==null||l.disconnect(),this.observer=new MutationObserver(u=>{u.forEach(p=>{p.attributeName==="disabled"&&this.stopSpinningAndCleanUp()})}),this.observer.observe(this.host,{attributes:!0})}stopSpinningAndCleanUp(){var e;clearInterval(this.interval),clearTimeout(this.timeout),(e=this.observer)==null||e.disconnect()}},C=V(x);var _,R=(_=navigator.userAgentData)==null?void 0:_.brands.some(f=>f.brand.includes("Chromium")),J=R?!1:navigator.userAgent.includes("Firefox"),t=class extends ${constructor(){super(...arguments);this.formControlController=new z(this);this.hasSlotController=new M(this,"help-text","label","left","right","message","placeholder");this.localize=new T(this);this.hasFocus=!1;this.showValidStyle=!1;this.showInvalidStyle=!1;this.isClickableIconFocused=!1;this.type="text";this.size="lg";this.value="";this.defaultValue="";this.placeholder="";this.label="";this.helpText="";this.clearable=!1;this.disabled=!1;this.visuallyDisabled=!1;this.readonly=!1;this.passwordToggle=!1;this.passwordVisible=!1;this.spinButtons=!1;this.form="";this.name="";this.title="";this.required=!1;this.floatingLabel=!1;this.styleOnValid=!1;this.spellcheck=!0}get valueAsDate(){var e,l;return(l=(e=this.input)==null?void 0:e.valueAsDate)!=null?l:null}set valueAsDate(e){let l=document.createElement("input");l.type="date",l.valueAsDate=e,this.value=l.value}get valueAsNumber(){var e,l;return(l=(e=this.input)==null?void 0:e.valueAsNumber)!=null?l:parseFloat(this.value)}set valueAsNumber(e){let l=document.createElement("input");l.type="number",l.valueAsNumber=e,this.value=l.value}get validity(){return this.input.validity}firstUpdated(){this.formControlController.updateValidity()}handleBlur(){this.hasFocus=!1,this.emit("sd-blur")}handleChange(){this.value=this.input.value,this.emit("sd-change")}handleClearClick(e){this.value="",this.emit("sd-clear"),this.emit("sd-input"),this.emit("sd-change"),this.input.focus(),e.stopPropagation()}handleSearchClick(e){this.emit("sd-search"),e.stopPropagation()}handleFocus(){this.hasFocus=!0,this.emit("sd-focus")}handleInput(){if(this.visuallyDisabled){this.input.value=this.value;return}this.value=this.input.value,this.formControlController.updateValidity(),this.emit("sd-input")}handleInvalid(e){this.formControlController.setValidity(!1),this.formControlController.emitInvalidEvent(e),this.invalidMessage.textContent=e.target.validationMessage}handleKeyDown(e){let l=e.metaKey||e.ctrlKey||e.shiftKey||e.altKey;e.key==="Enter"&&!l&&setTimeout(()=>{!e.defaultPrevented&&!e.isComposing&&this.formControlController.submit()})}handlePasswordToggle(){this.passwordVisible=!this.passwordVisible}handleClickableIconFocusIn(){this.isClickableIconFocused=!0}handleClickableIconFocusOut(){this.isClickableIconFocused=!1}isDecrementDisabled(){if(this.disabled||this.readonly)return!0;if(this.min===void 0||this.min===null)return!1;let e=typeof this.min=="string"?parseFloat(this.min):this.min;return this.valueAsNumber<=e}isIncrementDisabled(){if(this.disabled||this.readonly)return!0;if(this.max===void 0||this.max===null)return!1;let e=typeof this.max=="string"?parseFloat(this.max):this.max;return this.valueAsNumber>=e}handleStep(){this.handleInput(),this.input.focus()}handleStepUp(){this.stepUp(),this.handleStep()}handleStepDown(){this.stepDown(),this.handleStep()}handleDisabledChange(){this.formControlController.setValidity(this.disabled)}handleStepChange(){this.input.step=String(this.step),this.formControlController.updateValidity()}async handleValueChange(){await this.updateComplete,this.formControlController.updateValidity()}handleSizeChange(){this.size=this.floatingLabel&&this.size==="sm"?"md":this.size}focus(e){this.input.focus(e)}blur(){this.input.blur()}select(){this.input.select()}setSelectionRange(e,l,u="none"){this.input.setSelectionRange(e,l,u)}setRangeText(e,l,u,p){this.input.setRangeText(e,l,u,p),this.value!==this.input.value&&(this.value=this.input.value)}showPicker(){"showPicker"in HTMLInputElement.prototype&&this.input.showPicker()}stepUp(){this.input.stepUp(),this.value!==this.input.value&&(this.value=this.input.value)}stepDown(){this.input.stepDown(),this.value!==this.input.value&&(this.value=this.input.value)}checkValidity(){var e;return(e=this.input)==null?void 0:e.checkValidity()}reportValidity(){return this.formControlController.fakeUserInteraction(),this.input.reportValidity()}setCustomValidity(e){this.input.setCustomValidity(e),this.formControlController.updateValidity()}render(){let e={label:this.hasSlotController.test("label"),helpText:this.hasSlotController.test("help-text"),description:this.hasSlotController.test("description"),left:this.hasSlotController.test("left"),right:this.hasSlotController.test("right"),tooltip:this.hasSlotController.test("tooltip")},l=this.label?!0:!!e.label,u=this.helpText?!0:!!e.helpText,p=this.clearable&&!this.readonly&&(typeof this.value=="number"||this.value.length>0),O=!!e.tooltip,S=e.left,y=this.value!==null&&String(this.value).length>0,h=this.floatingLabel&&l&&(this.hasFocus||y||this.isClickableIconFocused),v=this.disabled?"disabled":this.visuallyDisabled&&!this.hasFocus?"visuallyDisabled":this.readonly?"readonly":this.hasFocus&&this.showInvalidStyle?"activeInvalid":this.hasFocus&&this.styleOnValid&&this.showValidStyle?"activeValid":this.hasFocus?"active":this.showInvalidStyle?"invalid":this.styleOnValid&&this.showValidStyle?"valid":"default",g=this.size==="sm"?"text-sm":"text-base",U={disabled:"border-neutral-500",visuallyDisabled:"border-neutral-500",readonly:"form-control-color-border",activeInvalid:"border-error border-2",activeValid:"border-success border-2",active:"border-primary border-2",invalid:"border-error",valid:"border-success",default:"form-control-color-border"}[v],c=this.disabled||this.visuallyDisabled?"text-neutral-500":"form-control-color-icon",d={sm:"ml-1",md:"ml-2",lg:"ml-2"}[this.size],o={sm:"text-base",md:"text-lg",lg:"text-xl"}[this.size],K=this.size==="lg"?this.floatingLabel?h?"py-3":"py-4":"py-2":this.floatingLabel?h?"py-2":"py-3":"py-1",q={sm:"left-[36px]",md:"left-[44px]",lg:"left-12"}[this.size];return n`<div part="form-control" class="${a((this.disabled||this.visuallyDisabled)&&"cursor-not-allowed")}">${(l||O)&&!this.floatingLabel?n`<div class="flex items-center gap-1 mb-2"><label part="form-control-label" id="label" class="${a(l?"inline-block form-control-color-text":"hidden",g)}" for="input" aria-hidden="${l?"false":"true"}"><slot name="label">${this.label}</slot></label> ${e.tooltip?n`<slot name="tooltip"></slot>`:""}</div>`:null}<div part="form-control-input" class="${a("relative w-full",this.disabled&&"pointer-events-none",this.visuallyDisabled&&"cursor-not-allowed")}"><div part="border" class="${a("absolute w-full h-full pointer-events-none border rounded-default transition-[border] ease-in-out duration-medium hover:duration-fast",U)}"></div><div part="base" class="${a("px-4 flex flex-row items-center rounded-default transition-colors ease-in-out duration-medium hover:duration-fast",this.floatingLabel&&"has-floating-label",!this.disabled&&!this.readonly&&!this.visuallyDisabled?"hover:bg-neutral-200":"",this.readonly?"bg-neutral-100":"bg-white",["disabled","visuallyDisabled"].includes(v)?"text-neutral-500":"form-control-color-text",["invalid","activeInvalid"].includes(v)&&"form-control--invalid-color-background",K)}">${e.left?n`<slot name="left" part="left" class="${a("inline-flex",this.size==="sm"?"mr-1":"mr-2",c,o)}"></slot>`:""} <input part="input" id="input" class="${a("min-w-0 flex-grow focus:outline-none bg-transparent",this.visuallyDisabled||this.disabled?"placeholder:text-neutral-500 cursor-not-allowed":"placeholder:text-neutral-700",this.size==="sm"?h?"h-4":"h-6":h?"h-6":"h-8",g,h&&"leading-none mt-4")}" type="${this.type==="password"&&this.passwordVisible?"text":this.type}" title="${this.title}" name="${r(this.name)}" ?disabled="${this.disabled}" ?readonly="${this.readonly}" ?required="${this.required}" placeholder="${!this.floatingLabel||h?r(this.placeholder):""}" minlength="${r(this.minlength)}" maxlength="${r(this.maxlength)}" min="${r(this.min)}" max="${r(this.max)}" step="${r(this.step)}" .value="${B(this.value)}" autocapitalize="${r(this.type==="password"?"off":this.autocapitalize)}" autocomplete="${r(this.autocomplete)}" autocorrect="${r(this.type==="password"?"off":this.autocorrect)}" ?autofocus="${this.autofocus}" spellcheck="${this.spellcheck}" pattern="${r(this.pattern)}" enterkeyhint="${r(this.enterkeyhint)}" inputmode="${r(this.inputmode)}" aria-describedby="help-text invalid-message" aria-disabled="${this.visuallyDisabled||this.disabled?"true":"false"}" aria-invalid="${this.showInvalidStyle}" @change="${this.handleChange}" @input="${this.handleInput}" @invalid="${this.handleInvalid}" @keydown="${this.handleKeyDown}" @focus="${this.handleFocus}" @blur="${this.handleBlur}"> ${l&&this.floatingLabel?n`<label part="form-control-floating-label" class="${a("pointer-events-none absolute",S?q:"left-4",!this.readonly&&"transition-all duration-medium ease-out",!h||!y&&(this.readonly||this.visuallyDisabled)?"top-1/2 -translate-y-1/2":this.size==="lg"?"top-2":"top-1")}" for="input" aria-hidden="${l?"false":"true"}"><span id="floating-label" class="${a("pointer-events-none leading-none",!this.readonly&&"transition-all duration-medium ease-out",!h||!y&&(this.readonly||this.visuallyDisabled)?g:"text-xs",(this.visuallyDisabled||this.disabled)&&"text-neutral-500",h&&!this.visuallyDisabled&&!this.disabled&&"form-control--filled__floating-label-color-text")}">${this.label}</span></label>`:null} ${p?n`<button part="clear-button" class="${a("flex justify-center",d)}" type="button" aria-label="${this.localize.term("clearEntry")}" @click="${this.handleClearClick}" tabindex="-1"><slot name="clear-icon"><sd-6-8-0-icon class="${a(this.disabled||this.visuallyDisabled?"text-neutral-500":"text-neutral-700",o)}" library="_internal" name="closing-round"></sd-6-8-0-icon></slot></button>`:""} ${this.passwordToggle&&this.type==="password"?n`<button aria-label="${this.localize.term(this.passwordVisible?"hidePassword":"showPassword")}" part="password-toggle-button" class="${a("flex items-center sd-interactive",d,this.floatingLabel&&!h&&"hide-password-toggle")}" type="button" @click="${this.handlePasswordToggle}" @mousedown="${this.handleClickableIconFocusIn}" @focus="${()=>this.handleClickableIconFocusIn()}" @blur="${this.handleClickableIconFocusOut}">${this.passwordVisible?n`<slot name="show-password-icon"><sd-6-8-0-icon class="${a(c,o)}" library="_internal" name="eye"></sd-6-8-0-icon></slot>`:n`<slot name="hide-password-icon"><sd-6-8-0-icon class="${a(c,o)}" library="_internal" name="eye-crossed-out"></sd-6-8-0-icon></slot>`}</button>`:""} ${(this.type==="date"||this.type==="datetime-local")&&!J?n`<sd-6-8-0-icon class="${a(c,d,o)}" library="_internal" name="calendar"></sd-6-8-0-icon>`:""} ${this.type==="time"?n`<sd-6-8-0-icon class="${a(c,d,o)}" library="_internal" name="clock"></sd-6-8-0-icon>`:""} ${this.type==="search"?n`<button class="${a("flex items-center sd-interactive",d)}" type="button" @click="${this.handleSearchClick}"><sd-6-8-0-icon class="${a(c,o)}" library="_internal" name="magnifying-glass" label="${this.localize.term("search")}"></sd-6-8-0-icon></button>`:""} ${this.showInvalidStyle?n`<sd-6-8-0-icon part="invalid-icon" class="${a("text-error",d,o)}" library="_internal" name="risk"></sd-6-8-0-icon>`:""} ${this.showValidStyle&&this.styleOnValid?n`<sd-6-8-0-icon class="${a("text-success flex-shrink-0",d,o)}" library="_internal" name="confirm-circle" part="valid-icon"></sd-6-8-0-icon>`:""} ${e.right?n`<slot name="right" part="right" class="${a("inline-flex",c,d,o)}"></slot>`:""} ${this.type==="number"&&this.spinButtons?n`<div part="stepper" class="flex items-center"><button part="decrement-number-stepper" class="stepper-button flex" type="button" ?disabled="${this.isDecrementDisabled()}" aria-hidden="true" ${C({start:()=>this.handleStepDown(),end:()=>this.handleChange()})} tabindex="-1" @mousedown="${this.handleClickableIconFocusIn}" @focus="${()=>this.handleClickableIconFocusIn()}" @blur="${this.handleClickableIconFocusOut}"><slot name="decrement-number-stepper"><sd-6-8-0-icon library="_internal" name="minus-circle" label="Decrease value" class="${a(c,d,o)}"></sd-6-8-0-icon></slot></button> <button part="increment-number-stepper" class="stepper-button flex" type="button" ?disabled="${this.isIncrementDisabled()}" aria-hidden="true" ${C({start:()=>this.handleStepUp(),end:()=>this.handleChange()})} tabindex="-1"><slot name="increment-number-stepper"><sd-6-8-0-icon library="_internal" name="plus-circle" label="Decrease value" class="${a(c,d,o)}"></sd-6-8-0-icon></slot></button></div>`:""}</div></div><slot name="help-text" part="form-control-help-text" id="help-text" class="${a("text-sm text-neutral-700 mt-1",u&&!this.showInvalidStyle?"block":"hidden")}" aria-hidden="${!u||this.showInvalidStyle}">${this.helpText}</slot></div>${this.formControlController.renderInvalidMessage(this.size)}`}};t.styles=[...$.styles,D`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
2
- :host{position:relative;box-sizing:border-box;display:inline-block;width:100%;text-align:left}:host([vertical]){display:block}:host([required]) :is(#label,#floating-label)::after{content:' *'}:host([visually-disabled]) input{caret-color:transparent}details summary::-webkit-details-marker{display:none}input::-webkit-inner-spin-button,input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}input[type=time]::-webkit-calendar-picker-indicator{background:0 0;display:none;-webkit-appearance:none}details summary::-webkit-details-marker,input[type=date]::-webkit-calendar-picker-indicator,input[type=datetime-local]::-webkit-calendar-picker-indicator,input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration,input[type=search]::-webkit-search-results-button,input[type=search]::-webkit-search-results-decoration{display:none}.stepper-button[disabled] sd-6-8-0-icon{color:rgba(var(--sd-color-text-neutral-500))}.hide-password-toggle{display:none}.has-floating-label input[type=date]:not(.has-value),.has-floating-label input[type=datetime-local]:not(.has-value),.has-floating-label input[type=time]:not(.has-value){color:transparent}.has-floating-label input[type=date]:focus,.has-floating-label input[type=datetime-local]:focus,.has-floating-label input[type=time]:focus{color:inherit}`],i([w("#input")],t.prototype,"input",2),i([w("#invalid-message")],t.prototype,"invalidMessage",2),i([m()],t.prototype,"hasFocus",2),i([m()],t.prototype,"showValidStyle",2),i([m()],t.prototype,"showInvalidStyle",2),i([m()],t.prototype,"isClickableIconFocused",2),i([s({type:String,reflect:!0})],t.prototype,"type",2),i([s({type:String,reflect:!0})],t.prototype,"size",2),i([s({type:String,reflect:!0})],t.prototype,"inputmode",2),i([s()],t.prototype,"value",2),i([A()],t.prototype,"defaultValue",2),i([s({type:String,reflect:!0})],t.prototype,"placeholder",2),i([s({type:String,reflect:!0})],t.prototype,"label",2),i([s({type:String,attribute:"help-text",reflect:!0})],t.prototype,"helpText",2),i([s({type:Boolean,reflect:!0})],t.prototype,"clearable",2),i([s({type:Boolean,reflect:!0})],t.prototype,"disabled",2),i([s({type:Boolean,reflect:!0,attribute:"visually-disabled"})],t.prototype,"visuallyDisabled",2),i([s({type:Boolean,reflect:!0})],t.prototype,"readonly",2),i([s({attribute:"password-toggle",type:Boolean,reflect:!0})],t.prototype,"passwordToggle",2),i([s({attribute:"password-visible",type:Boolean,reflect:!0})],t.prototype,"passwordVisible",2),i([s({attribute:"spin-buttons",type:Boolean,reflect:!0})],t.prototype,"spinButtons",2),i([s({type:Number,reflect:!0})],t.prototype,"minlength",2),i([s({type:Number,reflect:!0})],t.prototype,"maxlength",2),i([s({reflect:!0})],t.prototype,"min",2),i([s({reflect:!0})],t.prototype,"max",2),i([s({type:String,reflect:!0})],t.prototype,"form",2),i([s({type:String,reflect:!0})],t.prototype,"name",2),i([s({type:String,reflect:!0})],t.prototype,"title",2),i([s({type:Boolean,reflect:!0})],t.prototype,"required",2),i([s({attribute:"floating-label",type:Boolean,reflect:!0})],t.prototype,"floatingLabel",2),i([s()],t.prototype,"pattern",2),i([s({reflect:!0})],t.prototype,"step",2),i([s({type:String,reflect:!0})],t.prototype,"autocapitalize",2),i([s({type:String,reflect:!0})],t.prototype,"autocorrect",2),i([s({reflect:!0})],t.prototype,"autocomplete",2),i([s({type:Boolean,reflect:!0})],t.prototype,"autofocus",2),i([s({type:String,reflect:!0})],t.prototype,"enterkeyhint",2),i([s({type:Boolean,reflect:!0,attribute:"style-on-valid"})],t.prototype,"styleOnValid",2),i([s({type:Boolean,converter:{fromAttribute:e=>!(!e||e==="false"),toAttribute:e=>e?"true":"false"}})],t.prototype,"spellcheck",2),i([b("disabled",{waitUntilFirstUpdate:!0})],t.prototype,"handleDisabledChange",1),i([b("step",{waitUntilFirstUpdate:!0})],t.prototype,"handleStepChange",1),i([b("value",{waitUntilFirstUpdate:!0})],t.prototype,"handleValueChange",1),i([b(["size","floatingLabel"])],t.prototype,"handleSizeChange",1),t=i([E("sd-6-8-0-input")],t);export{t as a};
1
+ import{a as N}from"./chunk.RMXFJHN6.js";import{a as B}from"./chunk.YQH4KNT6.js";import{a as A}from"./chunk.W4EADN3G.js";import{b as z}from"./chunk.RAP66B6O.js";import{a as r}from"./chunk.SLXPE3UU.js";import{a as M}from"./chunk.CGQ2BPPZ.js";import{a as P,b as V}from"./chunk.BSPQBW7U.js";import{a as T}from"./chunk.IQPMMUES.js";import{a}from"./chunk.YFQFOIEM.js";import{a as b}from"./chunk.NYKJXI3Q.js";import{a as E,b as s,c as m,d as w,h as $}from"./chunk.CRLGS4QF.js";import{b as D,e as n,h as F,i as L}from"./chunk.UOAG5PNU.js";import{a as k,e as i}from"./chunk.6EV4YU6C.js";var x=class extends N{constructor(e){super(e);this.handlePointerDown=e=>{e.button!==0||this.host.disabled||this.spinOnLongPressCallback(e)};this.handlePointerUp=e=>{e==null||e.preventDefault(),e==null||e.stopPropagation(),this.timeout&&this.callbacks.start(),this.stopSpinningAndCleanUp(),this.callbacks.end(),document.removeEventListener("pointerup",this.handlePointerUp)};if(e.type!==P.ELEMENT||!(e.element instanceof HTMLButtonElement))throw new Error("The `longPress` directive must be used on an HTMLButtonElement.")}render(e){return L}update(e,[l]){return this.callbacks===void 0&&this.host===void 0&&(this.host=e.element,this.callbacks=k({},l),this.host.addEventListener("pointerdown",this.handlePointerDown)),F}disconnected(){this.stopSpinningAndCleanUp(),this.host.removeEventListener("pointerdown",this.handlePointerDown),document.removeEventListener("pointerup",this.handlePointerUp)}spinOnLongPressCallback(e){var l;e.preventDefault(),e.stopPropagation(),this.timeout=setTimeout(()=>{this.timeout=void 0,this.interval=setInterval(()=>{this.callbacks.start()},50)},500),document.addEventListener("pointerup",this.handlePointerUp),(l=this.observer)==null||l.disconnect(),this.observer=new MutationObserver(u=>{u.forEach(p=>{p.attributeName==="disabled"&&this.stopSpinningAndCleanUp()})}),this.observer.observe(this.host,{attributes:!0})}stopSpinningAndCleanUp(){var e;clearInterval(this.interval),clearTimeout(this.timeout),(e=this.observer)==null||e.disconnect()}},C=V(x);var _,R=(_=navigator.userAgentData)==null?void 0:_.brands.some(f=>f.brand.includes("Chromium")),J=R?!1:navigator.userAgent.includes("Firefox"),t=class extends ${constructor(){super(...arguments);this.formControlController=new z(this);this.hasSlotController=new M(this,"help-text","label","left","right","message","placeholder");this.localize=new T(this);this.hasFocus=!1;this.showValidStyle=!1;this.showInvalidStyle=!1;this.isClickableIconFocused=!1;this.type="text";this.size="lg";this.value="";this.defaultValue="";this.placeholder="";this.label="";this.helpText="";this.clearable=!1;this.disabled=!1;this.visuallyDisabled=!1;this.readonly=!1;this.passwordToggle=!1;this.passwordVisible=!1;this.spinButtons=!1;this.form="";this.name="";this.title="";this.required=!1;this.floatingLabel=!1;this.styleOnValid=!1;this.spellcheck=!0}get valueAsDate(){var e,l;return(l=(e=this.input)==null?void 0:e.valueAsDate)!=null?l:null}set valueAsDate(e){let l=document.createElement("input");l.type="date",l.valueAsDate=e,this.value=l.value}get valueAsNumber(){var e,l;return(l=(e=this.input)==null?void 0:e.valueAsNumber)!=null?l:parseFloat(this.value)}set valueAsNumber(e){let l=document.createElement("input");l.type="number",l.valueAsNumber=e,this.value=l.value}get validity(){return this.input.validity}firstUpdated(){this.formControlController.updateValidity()}handleBlur(){this.hasFocus=!1,this.emit("sd-blur")}handleChange(){this.value=this.input.value,this.emit("sd-change")}handleClearClick(e){this.value="",this.emit("sd-clear"),this.emit("sd-input"),this.emit("sd-change"),this.input.focus(),e.stopPropagation()}handleSearchClick(e){this.emit("sd-search"),e.stopPropagation()}handleFocus(){this.hasFocus=!0,this.emit("sd-focus")}handleInput(){if(this.visuallyDisabled){this.input.value=this.value;return}this.value=this.input.value,this.formControlController.updateValidity(),this.emit("sd-input")}handleInvalid(e){this.formControlController.setValidity(!1),this.formControlController.emitInvalidEvent(e),this.invalidMessage.textContent=e.target.validationMessage}handleKeyDown(e){let l=e.metaKey||e.ctrlKey||e.shiftKey||e.altKey;e.key==="Enter"&&!l&&setTimeout(()=>{!e.defaultPrevented&&!e.isComposing&&this.formControlController.submit()})}handlePasswordToggle(){this.passwordVisible=!this.passwordVisible}handleClickableIconFocusIn(){this.isClickableIconFocused=!0}handleClickableIconFocusOut(){this.isClickableIconFocused=!1}isDecrementDisabled(){if(this.disabled||this.readonly)return!0;if(this.min===void 0||this.min===null)return!1;let e=typeof this.min=="string"?parseFloat(this.min):this.min;return this.valueAsNumber<=e}isIncrementDisabled(){if(this.disabled||this.readonly)return!0;if(this.max===void 0||this.max===null)return!1;let e=typeof this.max=="string"?parseFloat(this.max):this.max;return this.valueAsNumber>=e}handleStep(){this.handleInput(),this.input.focus()}handleStepUp(){this.stepUp(),this.handleStep()}handleStepDown(){this.stepDown(),this.handleStep()}handleDisabledChange(){this.formControlController.setValidity(this.disabled)}handleStepChange(){this.input.step=String(this.step),this.formControlController.updateValidity()}async handleValueChange(){await this.updateComplete,this.formControlController.updateValidity()}handleSizeChange(){this.size=this.floatingLabel&&this.size==="sm"?"md":this.size}focus(e){this.input.focus(e)}blur(){this.input.blur()}select(){this.input.select()}setSelectionRange(e,l,u="none"){this.input.setSelectionRange(e,l,u)}setRangeText(e,l,u,p){this.input.setRangeText(e,l,u,p),this.value!==this.input.value&&(this.value=this.input.value)}showPicker(){"showPicker"in HTMLInputElement.prototype&&this.input.showPicker()}stepUp(){this.input.stepUp(),this.value!==this.input.value&&(this.value=this.input.value)}stepDown(){this.input.stepDown(),this.value!==this.input.value&&(this.value=this.input.value)}checkValidity(){var e;return(e=this.input)==null?void 0:e.checkValidity()}reportValidity(){return this.formControlController.fakeUserInteraction(),this.input.reportValidity()}setCustomValidity(e){this.input.setCustomValidity(e),this.formControlController.updateValidity()}render(){let e={label:this.hasSlotController.test("label"),helpText:this.hasSlotController.test("help-text"),description:this.hasSlotController.test("description"),left:this.hasSlotController.test("left"),right:this.hasSlotController.test("right"),tooltip:this.hasSlotController.test("tooltip")},l=this.label?!0:!!e.label,u=this.helpText?!0:!!e.helpText,p=this.clearable&&!this.readonly&&(typeof this.value=="number"||this.value.length>0),O=!!e.tooltip,S=e.left,y=this.value!==null&&String(this.value).length>0,h=this.floatingLabel&&l&&(this.hasFocus||y||this.isClickableIconFocused),v=this.disabled?"disabled":this.visuallyDisabled&&!this.hasFocus?"visuallyDisabled":this.readonly?"readonly":this.hasFocus&&this.showInvalidStyle?"activeInvalid":this.hasFocus&&this.styleOnValid&&this.showValidStyle?"activeValid":this.hasFocus?"active":this.showInvalidStyle?"invalid":this.styleOnValid&&this.showValidStyle?"valid":"default",g=this.size==="sm"?"text-sm":"text-base",U={disabled:"border-neutral-500",visuallyDisabled:"border-neutral-500",readonly:"form-control-color-border",activeInvalid:"border-error border-2",activeValid:"border-success border-2",active:"border-primary border-2",invalid:"border-error",valid:"border-success",default:"form-control-color-border"}[v],c=this.disabled||this.visuallyDisabled?"text-neutral-500":"form-control-color-icon",d={sm:"ml-1",md:"ml-2",lg:"ml-2"}[this.size],o={sm:"text-base",md:"text-lg",lg:"text-xl"}[this.size],K=this.size==="lg"?this.floatingLabel?h?"py-3":"py-4":"py-2":this.floatingLabel?h?"py-2":"py-3":"py-1",q={sm:"left-[36px]",md:"left-[44px]",lg:"left-12"}[this.size];return n`<div part="form-control" class="${a((this.disabled||this.visuallyDisabled)&&"cursor-not-allowed")}">${(l||O)&&!this.floatingLabel?n`<div class="flex items-center gap-1 mb-2"><label part="form-control-label" id="label" class="${a(l?"inline-block form-control-color-text":"hidden",g)}" for="input" aria-hidden="${l?"false":"true"}"><slot name="label">${this.label}</slot></label> ${e.tooltip?n`<slot name="tooltip"></slot>`:""}</div>`:null}<div part="form-control-input" class="${a("relative w-full",this.disabled&&"pointer-events-none",this.visuallyDisabled&&"cursor-not-allowed")}"><div part="border" class="${a("absolute w-full h-full pointer-events-none border rounded-default transition-[border] ease-in-out duration-medium hover:duration-fast",U)}"></div><div part="base" class="${a("px-4 flex flex-row items-center rounded-default transition-colors ease-in-out duration-medium hover:duration-fast",this.floatingLabel&&"has-floating-label",!this.disabled&&!this.readonly&&!this.visuallyDisabled?"hover:bg-neutral-200":"",this.readonly?"bg-neutral-100":"bg-white",["disabled","visuallyDisabled"].includes(v)?"text-neutral-500":"form-control-color-text",["invalid","activeInvalid"].includes(v)&&"form-control--invalid-color-background",K)}">${e.left?n`<slot name="left" part="left" class="${a("inline-flex",this.size==="sm"?"mr-1":"mr-2",c,o)}"></slot>`:""} <input part="input" id="input" class="${a("min-w-0 flex-grow focus:outline-none bg-transparent",this.visuallyDisabled||this.disabled?"placeholder:text-neutral-500 cursor-not-allowed":"placeholder:text-neutral-700",this.size==="sm"?h?"h-4":"h-6":h?"h-6":"h-8",g,h&&"leading-none mt-4")}" type="${this.type==="password"&&this.passwordVisible?"text":this.type}" title="${this.title}" name="${r(this.name)}" ?disabled="${this.disabled}" ?readonly="${this.readonly}" ?required="${this.required}" placeholder="${!this.floatingLabel||h?r(this.placeholder):""}" minlength="${r(this.minlength)}" maxlength="${r(this.maxlength)}" min="${r(this.min)}" max="${r(this.max)}" step="${r(this.step)}" .value="${B(this.value)}" autocapitalize="${r(this.type==="password"?"off":this.autocapitalize)}" autocomplete="${r(this.autocomplete)}" autocorrect="${r(this.type==="password"?"off":this.autocorrect)}" ?autofocus="${this.autofocus}" spellcheck="${this.spellcheck}" pattern="${r(this.pattern)}" enterkeyhint="${r(this.enterkeyhint)}" inputmode="${r(this.inputmode)}" aria-describedby="help-text invalid-message" aria-disabled="${this.visuallyDisabled||this.disabled?"true":"false"}" aria-invalid="${this.showInvalidStyle}" @change="${this.handleChange}" @input="${this.handleInput}" @invalid="${this.handleInvalid}" @keydown="${this.handleKeyDown}" @focus="${this.handleFocus}" @blur="${this.handleBlur}"> ${l&&this.floatingLabel?n`<label part="form-control-floating-label" class="${a("pointer-events-none absolute",S?q:"left-4",!this.readonly&&"transition-all duration-medium ease-out",!h||!y&&(this.readonly||this.visuallyDisabled)?"top-1/2 -translate-y-1/2":this.size==="lg"?"top-2":"top-1")}" for="input" aria-hidden="${l?"false":"true"}"><span id="floating-label" class="${a("pointer-events-none leading-none",!this.readonly&&"transition-all duration-medium ease-out",!h||!y&&(this.readonly||this.visuallyDisabled)?g:"text-xs",(this.visuallyDisabled||this.disabled)&&"text-neutral-500",h&&!this.visuallyDisabled&&!this.disabled&&"form-control--filled__floating-label-color-text")}">${this.label}</span></label>`:null} ${p?n`<button part="clear-button" class="${a("flex justify-center",d)}" type="button" aria-label="${this.localize.term("clearEntry")}" @click="${this.handleClearClick}" tabindex="-1"><slot name="clear-icon"><sd-6-9-0-icon class="${a(this.disabled||this.visuallyDisabled?"text-neutral-500":"text-neutral-700",o)}" library="_internal" name="closing-round"></sd-6-9-0-icon></slot></button>`:""} ${this.passwordToggle&&this.type==="password"?n`<button aria-label="${this.localize.term(this.passwordVisible?"hidePassword":"showPassword")}" part="password-toggle-button" class="${a("flex items-center sd-interactive",d,this.floatingLabel&&!h&&"hide-password-toggle")}" type="button" @click="${this.handlePasswordToggle}" @mousedown="${this.handleClickableIconFocusIn}" @focus="${()=>this.handleClickableIconFocusIn()}" @blur="${this.handleClickableIconFocusOut}">${this.passwordVisible?n`<slot name="show-password-icon"><sd-6-9-0-icon class="${a(c,o)}" library="_internal" name="eye"></sd-6-9-0-icon></slot>`:n`<slot name="hide-password-icon"><sd-6-9-0-icon class="${a(c,o)}" library="_internal" name="eye-crossed-out"></sd-6-9-0-icon></slot>`}</button>`:""} ${(this.type==="date"||this.type==="datetime-local")&&!J?n`<sd-6-9-0-icon class="${a(c,d,o)}" library="_internal" name="calendar"></sd-6-9-0-icon>`:""} ${this.type==="time"?n`<sd-6-9-0-icon class="${a(c,d,o)}" library="_internal" name="clock"></sd-6-9-0-icon>`:""} ${this.type==="search"?n`<button class="${a("flex items-center sd-interactive",d)}" type="button" @click="${this.handleSearchClick}"><sd-6-9-0-icon class="${a(c,o)}" library="_internal" name="magnifying-glass" label="${this.localize.term("search")}"></sd-6-9-0-icon></button>`:""} ${this.showInvalidStyle?n`<sd-6-9-0-icon part="invalid-icon" class="${a("text-error",d,o)}" library="_internal" name="risk"></sd-6-9-0-icon>`:""} ${this.showValidStyle&&this.styleOnValid?n`<sd-6-9-0-icon class="${a("text-success flex-shrink-0",d,o)}" library="_internal" name="confirm-circle" part="valid-icon"></sd-6-9-0-icon>`:""} ${e.right?n`<slot name="right" part="right" class="${a("inline-flex",c,d,o)}"></slot>`:""} ${this.type==="number"&&this.spinButtons?n`<div part="stepper" class="flex items-center"><button part="decrement-number-stepper" class="stepper-button flex" type="button" ?disabled="${this.isDecrementDisabled()}" aria-hidden="true" ${C({start:()=>this.handleStepDown(),end:()=>this.handleChange()})} tabindex="-1" @mousedown="${this.handleClickableIconFocusIn}" @focus="${()=>this.handleClickableIconFocusIn()}" @blur="${this.handleClickableIconFocusOut}"><slot name="decrement-number-stepper"><sd-6-9-0-icon library="_internal" name="minus-circle" label="Decrease value" class="${a(c,d,o)}"></sd-6-9-0-icon></slot></button> <button part="increment-number-stepper" class="stepper-button flex" type="button" ?disabled="${this.isIncrementDisabled()}" aria-hidden="true" ${C({start:()=>this.handleStepUp(),end:()=>this.handleChange()})} tabindex="-1"><slot name="increment-number-stepper"><sd-6-9-0-icon library="_internal" name="plus-circle" label="Decrease value" class="${a(c,d,o)}"></sd-6-9-0-icon></slot></button></div>`:""}</div></div><slot name="help-text" part="form-control-help-text" id="help-text" class="${a("text-sm text-neutral-700 mt-1",u&&!this.showInvalidStyle?"block":"hidden")}" aria-hidden="${!u||this.showInvalidStyle}">${this.helpText}</slot></div>${this.formControlController.renderInvalidMessage(this.size)}`}};t.styles=[...$.styles,D`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
2
+ :host{position:relative;box-sizing:border-box;display:inline-block;width:100%;text-align:left}:host([vertical]){display:block}:host([required]) :is(#label,#floating-label)::after{content:' *'}:host([visually-disabled]) input{caret-color:transparent}details summary::-webkit-details-marker{display:none}input::-webkit-inner-spin-button,input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}input[type=time]::-webkit-calendar-picker-indicator{background:0 0;display:none;-webkit-appearance:none}details summary::-webkit-details-marker,input[type=date]::-webkit-calendar-picker-indicator,input[type=datetime-local]::-webkit-calendar-picker-indicator,input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration,input[type=search]::-webkit-search-results-button,input[type=search]::-webkit-search-results-decoration{display:none}.stepper-button[disabled] sd-6-9-0-icon{color:rgba(var(--sd-color-text-neutral-500))}.hide-password-toggle{display:none}.has-floating-label input[type=date]:not(.has-value),.has-floating-label input[type=datetime-local]:not(.has-value),.has-floating-label input[type=time]:not(.has-value){color:transparent}.has-floating-label input[type=date]:focus,.has-floating-label input[type=datetime-local]:focus,.has-floating-label input[type=time]:focus{color:inherit}`],i([w("#input")],t.prototype,"input",2),i([w("#invalid-message")],t.prototype,"invalidMessage",2),i([m()],t.prototype,"hasFocus",2),i([m()],t.prototype,"showValidStyle",2),i([m()],t.prototype,"showInvalidStyle",2),i([m()],t.prototype,"isClickableIconFocused",2),i([s({type:String,reflect:!0})],t.prototype,"type",2),i([s({type:String,reflect:!0})],t.prototype,"size",2),i([s({type:String,reflect:!0})],t.prototype,"inputmode",2),i([s()],t.prototype,"value",2),i([A()],t.prototype,"defaultValue",2),i([s({type:String,reflect:!0})],t.prototype,"placeholder",2),i([s({type:String,reflect:!0})],t.prototype,"label",2),i([s({type:String,attribute:"help-text",reflect:!0})],t.prototype,"helpText",2),i([s({type:Boolean,reflect:!0})],t.prototype,"clearable",2),i([s({type:Boolean,reflect:!0})],t.prototype,"disabled",2),i([s({type:Boolean,reflect:!0,attribute:"visually-disabled"})],t.prototype,"visuallyDisabled",2),i([s({type:Boolean,reflect:!0})],t.prototype,"readonly",2),i([s({attribute:"password-toggle",type:Boolean,reflect:!0})],t.prototype,"passwordToggle",2),i([s({attribute:"password-visible",type:Boolean,reflect:!0})],t.prototype,"passwordVisible",2),i([s({attribute:"spin-buttons",type:Boolean,reflect:!0})],t.prototype,"spinButtons",2),i([s({type:Number,reflect:!0})],t.prototype,"minlength",2),i([s({type:Number,reflect:!0})],t.prototype,"maxlength",2),i([s({reflect:!0})],t.prototype,"min",2),i([s({reflect:!0})],t.prototype,"max",2),i([s({type:String,reflect:!0})],t.prototype,"form",2),i([s({type:String,reflect:!0})],t.prototype,"name",2),i([s({type:String,reflect:!0})],t.prototype,"title",2),i([s({type:Boolean,reflect:!0})],t.prototype,"required",2),i([s({attribute:"floating-label",type:Boolean,reflect:!0})],t.prototype,"floatingLabel",2),i([s()],t.prototype,"pattern",2),i([s({reflect:!0})],t.prototype,"step",2),i([s({type:String,reflect:!0})],t.prototype,"autocapitalize",2),i([s({type:String,reflect:!0})],t.prototype,"autocorrect",2),i([s({reflect:!0})],t.prototype,"autocomplete",2),i([s({type:Boolean,reflect:!0})],t.prototype,"autofocus",2),i([s({type:String,reflect:!0})],t.prototype,"enterkeyhint",2),i([s({type:Boolean,reflect:!0,attribute:"style-on-valid"})],t.prototype,"styleOnValid",2),i([s({type:Boolean,converter:{fromAttribute:e=>!(!e||e==="false"),toAttribute:e=>e?"true":"false"}})],t.prototype,"spellcheck",2),i([b("disabled",{waitUntilFirstUpdate:!0})],t.prototype,"handleDisabledChange",1),i([b("step",{waitUntilFirstUpdate:!0})],t.prototype,"handleStepChange",1),i([b("value",{waitUntilFirstUpdate:!0})],t.prototype,"handleValueChange",1),i([b(["size","floatingLabel"])],t.prototype,"handleSizeChange",1),t=i([E("sd-6-9-0-input")],t);export{t as a};
@@ -1,2 +1,2 @@
1
- import{a as s}from"./chunk.SLXPE3UU.js";import{a as S}from"./chunk.IQPMMUES.js";import{a as r}from"./chunk.YFQFOIEM.js";import{a as T,b as h,c as f,d as u,h as y}from"./chunk.CRLGS4QF.js";import{b as k,e as c}from"./chunk.UOAG5PNU.js";import{e as o}from"./chunk.6EV4YU6C.js";var n=class extends y{constructor(){super(...arguments);this.localize=new S(this);this.orientation="horizontal";this.scrollbars=!1;this.buttons=!1;this.shadows=!1;this.inset=!1;this.step=150;this.canScroll={left:!1,right:!1,up:!1,down:!1};this.isScrollHorizontalEnabled=!1;this.isScrollVerticalEnabled=!1}connectedCallback(){super.connectedCallback(),this.updateScrollEnabledFlags(),this.resizeObserver=new ResizeObserver(()=>{this.handleContainerScroll()}),this.updateComplete.then(()=>{this.container&&this.resizeObserver.observe(this.container)})}disconnectedCallback(){super.disconnectedCallback(),this.container&&this.resizeObserver.unobserve(this.container)}updated(t){super.updated(t),(t.has("orientation")||t.has("buttons")||t.has("shadows"))&&(this.updateScrollEnabledFlags(),this.handleContainerScroll())}updateScrollEnabledFlags(){let t=this.orientation;this.isScrollHorizontalEnabled=t==="horizontal"||t==="auto",this.isScrollVerticalEnabled=t==="vertical"||t==="auto"}get scrollButtons(){return{left:this.leftButton,right:this.rightButton,up:this.upButton,down:this.downButton}}handleContainerScroll(){if(!this.container)return;let t=this.container.scrollLeft>0,l=this.container.scrollLeft+this.container.clientWidth<this.container.scrollWidth-1,e=this.container.scrollTop>0,d=this.container.scrollTop+this.container.clientHeight<this.container.scrollHeight-1,a=this.canScroll,i={left:this.isScrollHorizontalEnabled&&t,right:this.isScrollHorizontalEnabled&&l,up:this.isScrollVerticalEnabled&&e,down:this.isScrollVerticalEnabled&&d},v=a.left&&!i.left,m=a.up&&!i.up,E=a.right&&!i.right,b=a.down&&!i.down;(v||m)&&this.dispatchEvent(new CustomEvent("start")),(E||b)&&this.dispatchEvent(new CustomEvent("end")),this.canScroll=i}handleScroll(t,l){var z,x,B;let e=["left","up"].includes(t)?-this.step:this.step,d=["left","right"].includes(t)?"horizontal":"vertical",a=["left","up"].includes(t)?"start":"end",i=!["mouse","touch"].includes((z=l==null?void 0:l.pointerType)!=null?z:""),v=d==="horizontal"?"left":"top";(x=this.container)==null||x.scrollBy({behavior:"smooth",[v]:e});let m=`button-${t}`;this.dispatchEvent(new CustomEvent(m,{bubbles:!0,composed:!0}));let b=(d==="horizontal"?this.container.scrollLeft:this.container.scrollTop)+e,C=d==="horizontal"?this.container.scrollWidth-this.container.clientWidth:this.container.scrollHeight-this.container.clientHeight,$=a==="start"&&b<=0,H=a==="end"&&b>=C-1;if(!($||H)){let w=this.localize.term("scrolled");this.announcementContainer.textContent=this.announcementContainer.textContent===w?`${w}\u200B`:w;return}let g=this.scrollButtons[t],p={left:this.rightButton,right:this.leftButton,up:this.downButton,down:this.upButton}[t],L=$?`${this.localize.term("scrolled")}. ${this.localize.term("scrollToEnd")}`:`${this.localize.term("scrolled")}. ${this.localize.term("scrollToStart")}`;(B=p==null?void 0:p.querySelector("sd-6-8-0-icon"))==null||B.setAttribute("label",L),i?p==null||p.focus():g==null||g.blur()}handleButtonBlur(t,l){var i;let d=(["left","up"].includes(t)?"start":"end")==="start"?this.localize.term("scrollToStart"):this.localize.term("scrollToEnd");(i=l.target.querySelector("sd-6-8-0-icon"))==null||i.setAttribute("label",d)}render(){let t="relative p-0 border-0 bg-transparent cursor-pointer w-5 h-5 flex items-center justify-center sd-interactive rounded-md flex text-lg",l="scroll-shadow absolute z-10 pointer-events-none transition-opacity duration-medium ease-in-out";return c`<div part="base" class="${r("scroll-container flex overflow-hidden flex-1",this.scrollbars?"show-scrollbars":"hide-scrollbars",this.inset&&"p-4",{horizontal:"scroll-horizontal flex-row whitespace-nowrap items-center overflow-x-scroll overflow-y-hidden",vertical:"scroll-vertical justify-items-center overflow-y-scroll overflow-x-hidden",auto:"scroll-auto overflow-auto"}[this.orientation])}" @scroll="${this.handleContainerScroll}" tabindex="0"><div id="announcement-container" role="status" class="sr-only"></div><div part="scroll-content" class="flex-1"><slot></slot></div></div>${this.buttons?c`${this.isScrollHorizontalEnabled?c`<div part="button-left" class="${r("absolute z-10 flex items-center justify-center top-0 left-0 h-full w-8 transition-opacity duration-medium ease-in-out",!this.canScroll.left&&"opacity-0 pointer-events-none")}"><button part="button-start" class="${r(t)}" aria-hidden="${s(!this.canScroll.left||void 0)}" tabindex="${s(this.canScroll.left?void 0:-1)}" @click="${e=>this.handleScroll("left",e)}" @blur="${e=>this.handleButtonBlur("left",e)}"><slot name="icon-start"><sd-6-8-0-icon library="_internal" name="chevron-up" class="rotate-[-90deg]" label="${this.localize.term("scrollToStart")}"></sd-6-8-0-icon></slot></button></div><div part="button-right" class="${r("absolute z-10 flex items-center justify-center top-0 right-0 h-full w-8 transition-opacity duration-medium ease-in-out",!this.canScroll.right&&"opacity-0 pointer-events-none")}"><button part="button-end" class="${r(t)}" aria-hidden="${s(!this.canScroll.right||void 0)}" tabindex="${s(this.canScroll.right?void 0:-1)}" @click="${e=>this.handleScroll("right",e)}" @blur="${e=>this.handleButtonBlur("right",e)}"><slot name="icon-end"><sd-6-8-0-icon library="_internal" name="chevron-down" class="rotate-[-90deg]" label="${this.localize.term("scrollToEnd")}"></sd-6-8-0-icon></slot></button></div>`:null} ${this.isScrollVerticalEnabled?c`<div part="button-top" class="${r("absolute z-10 flex items-center justify-center top-0 left-0 w-full h-8 transition-opacity duration-medium ease-in-out",!this.canScroll.up&&"opacity-0 pointer-events-none")}"><button part="button-start" class="${r(t)}" aria-hidden="${s(!this.canScroll.up||void 0)}" tabindex="${s(this.canScroll.up?void 0:-1)}" @click="${e=>this.handleScroll("up",e)}" @blur="${e=>this.handleButtonBlur("up",e)}"><slot name="icon-start"><sd-6-8-0-icon library="_internal" name="chevron-up" label="${this.localize.term("scrollToStart")}"></sd-6-8-0-icon></slot></button></div><div part="button-bottom" class="${r("absolute z-10 flex items-center justify-center bottom-0 left-0 w-full h-8 transition-opacity duration-medium ease-in-out",!this.canScroll.down&&"opacity-0 pointer-events-none")}"><button part="button-end" class="${r(t)}" aria-hidden="${s(!this.canScroll.down||void 0)}" tabindex="${s(this.canScroll.down?void 0:-1)}" @click="${e=>this.handleScroll("down",e)}" @blur="${e=>this.handleButtonBlur("down",e)}"><slot name="icon-end"><sd-6-8-0-icon library="_internal" name="chevron-down" label="${this.localize.term("scrollToEnd")}"></sd-6-8-0-icon></slot></button></div>`:null}`:null} ${this.shadows?c`${this.isScrollHorizontalEnabled?c`<div part="shadow-left" class="${r("left top-0 left-0 w-[6px] h-full",l,this.canScroll.left?"opacity-100":"opacity-0")}"></div><div part="shadow-right" class="${r("right top-0 right-0 w-[6px] h-full",l,this.canScroll.right?"opacity-100":"opacity-0")}"></div>`:null} ${this.isScrollVerticalEnabled?c`<div part="shadow-top" class="${r("top top-0 left-0 w-full h-[6px]",l,this.canScroll.up?"opacity-100":"opacity-0")}"></div><div part="shadow-bottom" class="${r("bottom bottom-0 left-0 w-full h-[6px]",l,this.canScroll.down?"opacity-100":"opacity-0")}"></div>`:null}`:null}`}};n.styles=[...y.styles,k`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
2
- :host{--gradient-color:transparent;--gradient:var(--gradient-color) 0%,rgba(var(--sd-color-background-white, rgba(var(--sd-color-white)))) 80%,rgba(var(--sd-color-background-white, rgba(var(--sd-color-white)))) 100%;position:relative;display:flex;overflow:hidden}.hide-scrollbars{scrollbar-width:none;-ms-overflow-style:none}.hide-scrollbars::-webkit-scrollbar{display:none}.scroll-container::-webkit-scrollbar-thumb{background-color:transparent}.scroll-container:hover::-webkit-scrollbar-thumb{background:var(--background-neutral-400,#c3c3c3);border-radius:var(--sd-radius-sm)}.scroll-container::-webkit-scrollbar{height:var(--sd-spacing-1);width:var(--sd-spacing-1)}.scroll-auto{overflow:auto}[part=button-left]{background:linear-gradient(270deg,var(--gradient))}[part=button-right]{background:linear-gradient(90deg,var(--gradient))}[part=button-top]{background:linear-gradient(0deg,var(--gradient))}[part=button-bottom]{background:linear-gradient(180deg,var(--gradient))}[part=shadow-left]{background:linear-gradient(270deg,transparent 50%,rgba(24,24,24,.4) 100%)}[part=shadow-right]{background:linear-gradient(90deg,transparent 50%,rgba(24,24,24,.4) 100%)}[part=shadow-top]{background:linear-gradient(0deg,transparent 50%,rgba(24,24,24,.4) 100%)}[part=shadow-bottom]{background:linear-gradient(180deg,transparent 50%,rgba(24,24,24,.4) 100%)}.sd-6-8-0-icon--top{align-self:flex-start}.sd-6-8-0-icon--down{align-self:flex-end}`],o([u('[part="button-right"] button')],n.prototype,"rightButton",2),o([u('[part="button-left"] button')],n.prototype,"leftButton",2),o([u('[part="button-bottom"] button')],n.prototype,"downButton",2),o([u('[part="button-top"] button')],n.prototype,"upButton",2),o([u(".scroll-container")],n.prototype,"container",2),o([u("#announcement-container")],n.prototype,"announcementContainer",2),o([h({type:String,reflect:!0})],n.prototype,"orientation",2),o([h({type:Boolean,reflect:!0})],n.prototype,"scrollbars",2),o([h({type:Boolean,reflect:!0})],n.prototype,"buttons",2),o([h({type:Boolean,reflect:!0})],n.prototype,"shadows",2),o([h({type:Boolean,reflect:!0})],n.prototype,"inset",2),o([h({type:Number,reflect:!0})],n.prototype,"step",2),o([f()],n.prototype,"canScroll",2),o([f()],n.prototype,"isScrollHorizontalEnabled",2),o([f()],n.prototype,"isScrollVerticalEnabled",2),n=o([T("sd-6-8-0-scrollable")],n);export{n as a};
1
+ import{a as s}from"./chunk.SLXPE3UU.js";import{a as S}from"./chunk.IQPMMUES.js";import{a as r}from"./chunk.YFQFOIEM.js";import{a as T,b as h,c as f,d as u,h as y}from"./chunk.CRLGS4QF.js";import{b as k,e as c}from"./chunk.UOAG5PNU.js";import{e as o}from"./chunk.6EV4YU6C.js";var n=class extends y{constructor(){super(...arguments);this.localize=new S(this);this.orientation="horizontal";this.scrollbars=!1;this.buttons=!1;this.shadows=!1;this.inset=!1;this.step=150;this.canScroll={left:!1,right:!1,up:!1,down:!1};this.isScrollHorizontalEnabled=!1;this.isScrollVerticalEnabled=!1}connectedCallback(){super.connectedCallback(),this.updateScrollEnabledFlags(),this.resizeObserver=new ResizeObserver(()=>{this.handleContainerScroll()}),this.updateComplete.then(()=>{this.container&&this.resizeObserver.observe(this.container)})}disconnectedCallback(){super.disconnectedCallback(),this.container&&this.resizeObserver.unobserve(this.container)}updated(t){super.updated(t),(t.has("orientation")||t.has("buttons")||t.has("shadows"))&&(this.updateScrollEnabledFlags(),this.handleContainerScroll())}updateScrollEnabledFlags(){let t=this.orientation;this.isScrollHorizontalEnabled=t==="horizontal"||t==="auto",this.isScrollVerticalEnabled=t==="vertical"||t==="auto"}get scrollButtons(){return{left:this.leftButton,right:this.rightButton,up:this.upButton,down:this.downButton}}handleContainerScroll(){if(!this.container)return;let t=this.container.scrollLeft>0,l=this.container.scrollLeft+this.container.clientWidth<this.container.scrollWidth-1,e=this.container.scrollTop>0,d=this.container.scrollTop+this.container.clientHeight<this.container.scrollHeight-1,a=this.canScroll,i={left:this.isScrollHorizontalEnabled&&t,right:this.isScrollHorizontalEnabled&&l,up:this.isScrollVerticalEnabled&&e,down:this.isScrollVerticalEnabled&&d},v=a.left&&!i.left,m=a.up&&!i.up,E=a.right&&!i.right,b=a.down&&!i.down;(v||m)&&this.dispatchEvent(new CustomEvent("start")),(E||b)&&this.dispatchEvent(new CustomEvent("end")),this.canScroll=i}handleScroll(t,l){var z,x,B;let e=["left","up"].includes(t)?-this.step:this.step,d=["left","right"].includes(t)?"horizontal":"vertical",a=["left","up"].includes(t)?"start":"end",i=!["mouse","touch"].includes((z=l==null?void 0:l.pointerType)!=null?z:""),v=d==="horizontal"?"left":"top";(x=this.container)==null||x.scrollBy({behavior:"smooth",[v]:e});let m=`button-${t}`;this.dispatchEvent(new CustomEvent(m,{bubbles:!0,composed:!0}));let b=(d==="horizontal"?this.container.scrollLeft:this.container.scrollTop)+e,C=d==="horizontal"?this.container.scrollWidth-this.container.clientWidth:this.container.scrollHeight-this.container.clientHeight,$=a==="start"&&b<=0,H=a==="end"&&b>=C-1;if(!($||H)){let w=this.localize.term("scrolled");this.announcementContainer.textContent=this.announcementContainer.textContent===w?`${w}\u200B`:w;return}let g=this.scrollButtons[t],p={left:this.rightButton,right:this.leftButton,up:this.downButton,down:this.upButton}[t],L=$?`${this.localize.term("scrolled")}. ${this.localize.term("scrollToEnd")}`:`${this.localize.term("scrolled")}. ${this.localize.term("scrollToStart")}`;(B=p==null?void 0:p.querySelector("sd-6-9-0-icon"))==null||B.setAttribute("label",L),i?p==null||p.focus():g==null||g.blur()}handleButtonBlur(t,l){var i;let d=(["left","up"].includes(t)?"start":"end")==="start"?this.localize.term("scrollToStart"):this.localize.term("scrollToEnd");(i=l.target.querySelector("sd-6-9-0-icon"))==null||i.setAttribute("label",d)}render(){let t="relative p-0 border-0 bg-transparent cursor-pointer w-5 h-5 flex items-center justify-center sd-interactive rounded-md flex text-lg",l="scroll-shadow absolute z-10 pointer-events-none transition-opacity duration-medium ease-in-out";return c`<div part="base" class="${r("scroll-container flex overflow-hidden flex-1",this.scrollbars?"show-scrollbars":"hide-scrollbars",this.inset&&"p-4",{horizontal:"scroll-horizontal flex-row whitespace-nowrap items-center overflow-x-scroll overflow-y-hidden",vertical:"scroll-vertical justify-items-center overflow-y-scroll overflow-x-hidden",auto:"scroll-auto overflow-auto"}[this.orientation])}" @scroll="${this.handleContainerScroll}" tabindex="0"><div id="announcement-container" role="status" class="sr-only"></div><div part="scroll-content" class="flex-1"><slot></slot></div></div>${this.buttons?c`${this.isScrollHorizontalEnabled?c`<div part="button-left" class="${r("absolute z-10 flex items-center justify-center top-0 left-0 h-full w-8 transition-opacity duration-medium ease-in-out",!this.canScroll.left&&"opacity-0 pointer-events-none")}"><button part="button-start" class="${r(t)}" aria-hidden="${s(!this.canScroll.left||void 0)}" tabindex="${s(this.canScroll.left?void 0:-1)}" @click="${e=>this.handleScroll("left",e)}" @blur="${e=>this.handleButtonBlur("left",e)}"><slot name="icon-start"><sd-6-9-0-icon library="_internal" name="chevron-up" class="rotate-[-90deg]" label="${this.localize.term("scrollToStart")}"></sd-6-9-0-icon></slot></button></div><div part="button-right" class="${r("absolute z-10 flex items-center justify-center top-0 right-0 h-full w-8 transition-opacity duration-medium ease-in-out",!this.canScroll.right&&"opacity-0 pointer-events-none")}"><button part="button-end" class="${r(t)}" aria-hidden="${s(!this.canScroll.right||void 0)}" tabindex="${s(this.canScroll.right?void 0:-1)}" @click="${e=>this.handleScroll("right",e)}" @blur="${e=>this.handleButtonBlur("right",e)}"><slot name="icon-end"><sd-6-9-0-icon library="_internal" name="chevron-down" class="rotate-[-90deg]" label="${this.localize.term("scrollToEnd")}"></sd-6-9-0-icon></slot></button></div>`:null} ${this.isScrollVerticalEnabled?c`<div part="button-top" class="${r("absolute z-10 flex items-center justify-center top-0 left-0 w-full h-8 transition-opacity duration-medium ease-in-out",!this.canScroll.up&&"opacity-0 pointer-events-none")}"><button part="button-start" class="${r(t)}" aria-hidden="${s(!this.canScroll.up||void 0)}" tabindex="${s(this.canScroll.up?void 0:-1)}" @click="${e=>this.handleScroll("up",e)}" @blur="${e=>this.handleButtonBlur("up",e)}"><slot name="icon-start"><sd-6-9-0-icon library="_internal" name="chevron-up" label="${this.localize.term("scrollToStart")}"></sd-6-9-0-icon></slot></button></div><div part="button-bottom" class="${r("absolute z-10 flex items-center justify-center bottom-0 left-0 w-full h-8 transition-opacity duration-medium ease-in-out",!this.canScroll.down&&"opacity-0 pointer-events-none")}"><button part="button-end" class="${r(t)}" aria-hidden="${s(!this.canScroll.down||void 0)}" tabindex="${s(this.canScroll.down?void 0:-1)}" @click="${e=>this.handleScroll("down",e)}" @blur="${e=>this.handleButtonBlur("down",e)}"><slot name="icon-end"><sd-6-9-0-icon library="_internal" name="chevron-down" label="${this.localize.term("scrollToEnd")}"></sd-6-9-0-icon></slot></button></div>`:null}`:null} ${this.shadows?c`${this.isScrollHorizontalEnabled?c`<div part="shadow-left" class="${r("left top-0 left-0 w-[6px] h-full",l,this.canScroll.left?"opacity-100":"opacity-0")}"></div><div part="shadow-right" class="${r("right top-0 right-0 w-[6px] h-full",l,this.canScroll.right?"opacity-100":"opacity-0")}"></div>`:null} ${this.isScrollVerticalEnabled?c`<div part="shadow-top" class="${r("top top-0 left-0 w-full h-[6px]",l,this.canScroll.up?"opacity-100":"opacity-0")}"></div><div part="shadow-bottom" class="${r("bottom bottom-0 left-0 w-full h-[6px]",l,this.canScroll.down?"opacity-100":"opacity-0")}"></div>`:null}`:null}`}};n.styles=[...y.styles,k`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
2
+ :host{--gradient-color:transparent;--gradient:var(--gradient-color) 0%,rgba(var(--sd-color-background-white, rgba(var(--sd-color-white)))) 80%,rgba(var(--sd-color-background-white, rgba(var(--sd-color-white)))) 100%;position:relative;display:flex;overflow:hidden}.hide-scrollbars{scrollbar-width:none;-ms-overflow-style:none}.hide-scrollbars::-webkit-scrollbar{display:none}.scroll-container::-webkit-scrollbar-thumb{background-color:transparent}.scroll-container:hover::-webkit-scrollbar-thumb{background:var(--background-neutral-400,#c3c3c3);border-radius:var(--sd-radius-sm)}.scroll-container::-webkit-scrollbar{height:var(--sd-spacing-1);width:var(--sd-spacing-1)}.scroll-auto{overflow:auto}[part=button-left]{background:linear-gradient(270deg,var(--gradient))}[part=button-right]{background:linear-gradient(90deg,var(--gradient))}[part=button-top]{background:linear-gradient(0deg,var(--gradient))}[part=button-bottom]{background:linear-gradient(180deg,var(--gradient))}[part=shadow-left]{background:linear-gradient(270deg,transparent 50%,rgba(24,24,24,.4) 100%)}[part=shadow-right]{background:linear-gradient(90deg,transparent 50%,rgba(24,24,24,.4) 100%)}[part=shadow-top]{background:linear-gradient(0deg,transparent 50%,rgba(24,24,24,.4) 100%)}[part=shadow-bottom]{background:linear-gradient(180deg,transparent 50%,rgba(24,24,24,.4) 100%)}.sd-6-9-0-icon--top{align-self:flex-start}.sd-6-9-0-icon--down{align-self:flex-end}`],o([u('[part="button-right"] button')],n.prototype,"rightButton",2),o([u('[part="button-left"] button')],n.prototype,"leftButton",2),o([u('[part="button-bottom"] button')],n.prototype,"downButton",2),o([u('[part="button-top"] button')],n.prototype,"upButton",2),o([u(".scroll-container")],n.prototype,"container",2),o([u("#announcement-container")],n.prototype,"announcementContainer",2),o([h({type:String,reflect:!0})],n.prototype,"orientation",2),o([h({type:Boolean,reflect:!0})],n.prototype,"scrollbars",2),o([h({type:Boolean,reflect:!0})],n.prototype,"buttons",2),o([h({type:Boolean,reflect:!0})],n.prototype,"shadows",2),o([h({type:Boolean,reflect:!0})],n.prototype,"inset",2),o([h({type:Number,reflect:!0})],n.prototype,"step",2),o([f()],n.prototype,"canScroll",2),o([f()],n.prototype,"isScrollHorizontalEnabled",2),o([f()],n.prototype,"isScrollVerticalEnabled",2),n=o([T("sd-6-9-0-scrollable")],n);export{n as a};