@luzmo/lucero 1.0.1-alpha.43 → 1.0.1-alpha.44

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 (136) hide show
  1. package/components/accordion/index.cjs +1 -1
  2. package/components/accordion/index.js +2 -2
  3. package/components/action-bar/index.cjs +1 -1
  4. package/components/action-bar/index.js +5 -5
  5. package/components/action-button/index.cjs +1 -1
  6. package/components/action-button/index.js +1 -1
  7. package/components/action-group/index.cjs +1 -1
  8. package/components/action-group/index.js +1 -1
  9. package/components/{action-group-Bwt9w8Vh.js → action-group-CqAXlI_I.js} +1 -1
  10. package/components/{action-group-D917z7XF.cjs → action-group-_gt0SxJg.cjs} +1 -1
  11. package/components/action-menu/index.cjs +1 -1
  12. package/components/action-menu/index.js +1 -1
  13. package/components/avatar/index.cjs +1 -1
  14. package/components/avatar/index.js +1 -1
  15. package/components/{base-CdYjmV_8.js → base-BUViEg_7.js} +10 -10
  16. package/components/{base-5nDSSNeT.cjs → base-DxRGeCrb.cjs} +1 -1
  17. package/components/button/index.cjs +1 -1
  18. package/components/button/index.js +3 -3
  19. package/components/{button-base-BdzHcHRs.cjs → button-base-D-gp73uZ.cjs} +1 -1
  20. package/components/{button-base-B_SkfcFn.js → button-base-npzdrTiY.js} +1 -1
  21. package/components/button-group/index.cjs +1 -1
  22. package/components/button-group/index.js +1 -1
  23. package/components/calendar/index.cjs +1 -1
  24. package/components/calendar/index.js +1 -1
  25. package/components/chat-message/chat-message.d.ts +5 -0
  26. package/components/chat-message/index.cjs +12 -12
  27. package/components/chat-message/index.js +6 -3
  28. package/components/chat-message-group/index.cjs +1 -1
  29. package/components/chat-message-group/index.js +1 -1
  30. package/components/checkbox/checkbox.d.ts +5 -0
  31. package/components/checkbox/index.cjs +2 -2
  32. package/components/checkbox/index.js +10 -7
  33. package/components/{close-button-Decm0Qbb.cjs → close-button-CSGamYgn.cjs} +1 -1
  34. package/components/{close-button-CGZxCNlI.js → close-button-po7k74tH.js} +1 -1
  35. package/components/color-area/index.cjs +1 -1
  36. package/components/color-area/index.js +2 -2
  37. package/components/color-field/index.cjs +1 -1
  38. package/components/color-field/index.js +1 -1
  39. package/components/color-handle/index.cjs +1 -1
  40. package/components/color-handle/index.js +2 -2
  41. package/components/color-loupe/index.cjs +1 -1
  42. package/components/color-loupe/index.js +1 -1
  43. package/components/{color-loupe-CIEFp7ln.cjs → color-loupe-Dta8u4pX.cjs} +1 -1
  44. package/components/{color-loupe-CLPX6xVb.js → color-loupe-OvalnSmN.js} +1 -1
  45. package/components/color-menu/index.cjs +1 -1
  46. package/components/color-menu/index.js +1 -1
  47. package/components/color-palette/index.cjs +1 -1
  48. package/components/color-palette/index.js +1 -1
  49. package/components/color-palette-group/index.cjs +1 -1
  50. package/components/color-palette-group/index.js +1 -1
  51. package/components/color-picker/index.cjs +1 -1
  52. package/components/color-picker/index.js +1 -1
  53. package/components/color-slider/index.cjs +1 -1
  54. package/components/color-slider/index.js +2 -2
  55. package/components/date-time-picker/index.cjs +1 -1
  56. package/components/date-time-picker/index.js +1 -1
  57. package/components/divider/index.cjs +1 -1
  58. package/components/divider/index.js +1 -1
  59. package/components/field-group/index.cjs +1 -1
  60. package/components/field-group/index.js +1 -1
  61. package/components/{field-group-CHmw159R.js → field-group-GZLR5GAn.js} +1 -1
  62. package/components/{field-group-BYHNJmv0.cjs → field-group-aG9hVBjA.cjs} +1 -1
  63. package/components/field-label/index.cjs +1 -1
  64. package/components/field-label/index.js +1 -1
  65. package/components/{field-label-Cy3xMWZ-.js → field-label-BxW2RJMY.js} +1 -1
  66. package/components/{field-label-DZoeqJJX.cjs → field-label-CYC-u_Cq.cjs} +1 -1
  67. package/components/{focusable-BjvsvVam.js → focusable-BM1nd-dI.js} +1 -1
  68. package/components/{focusable-CbVKgGfS.cjs → focusable-agUxU61W.cjs} +1 -1
  69. package/components/icon/index.cjs +1 -1
  70. package/components/icon/index.js +1 -1
  71. package/components/index.cjs +1 -1
  72. package/components/index.js +12 -12
  73. package/components/infield-button/index.cjs +1 -1
  74. package/components/infield-button/index.js +1 -1
  75. package/components/label/index.cjs +1 -1
  76. package/components/label/index.js +1 -1
  77. package/components/{language-resolution-EUER43cg.cjs → language-resolution-DmX3Wy5I.cjs} +1 -1
  78. package/components/{language-resolution-B-wjV5bb.js → language-resolution-pYd-sAaw.js} +1 -1
  79. package/components/menu/index.cjs +2 -2
  80. package/components/menu/index.js +3 -3
  81. package/components/multi-language-field/index.cjs +1 -1
  82. package/components/multi-language-field/index.js +1 -1
  83. package/components/number-field/index.cjs +1 -1
  84. package/components/number-field/index.js +2 -2
  85. package/components/options/index.cjs +1 -1
  86. package/components/options/index.js +2 -2
  87. package/components/overlay/index.cjs +1 -1
  88. package/components/overlay/index.js +3 -3
  89. package/components/{overlay-BhrVS5h7.cjs → overlay-BTNKxbrJ.cjs} +1 -1
  90. package/components/{overlay-C-No3oJQ.js → overlay-CXkoVtnB.js} +1 -1
  91. package/components/{pending-state-DQctFHI8.cjs → pending-state-DBfiIiwY.cjs} +1 -1
  92. package/components/{pending-state-Dx1u3EXA.js → pending-state-DG9TpsGT.js} +1 -1
  93. package/components/picker/index.cjs +1 -1
  94. package/components/picker/index.js +2 -2
  95. package/components/{picker-DxYgh4LR.cjs → picker-B2_mjftE.cjs} +1 -1
  96. package/components/{picker-Cm6_didQ.js → picker-DbOS1rE7.js} +2 -2
  97. package/components/picker-button/index.cjs +1 -1
  98. package/components/picker-button/index.js +1 -1
  99. package/components/popover/index.cjs +1 -1
  100. package/components/popover/index.js +1 -1
  101. package/components/{popover-lcZnODPK.cjs → popover-CPZ51K_z.cjs} +1 -1
  102. package/components/{popover-ucIgjbQs.js → popover-UFgI7b75.js} +1 -1
  103. package/components/progress-circle/index.cjs +1 -1
  104. package/components/progress-circle/index.js +1 -1
  105. package/components/{progress-circle-DgMbqrzG.cjs → progress-circle-BMRjGc4y.cjs} +1 -1
  106. package/components/{progress-circle-D5J0ZwY0.js → progress-circle-unckklsi.js} +1 -1
  107. package/components/prompt-box/index.cjs +1 -1
  108. package/components/prompt-box/index.js +1 -1
  109. package/components/radio/index.cjs +1 -1
  110. package/components/radio/index.js +2 -2
  111. package/components/search/index.cjs +1 -1
  112. package/components/search/index.js +1 -1
  113. package/components/select/index.cjs +1 -1
  114. package/components/select/index.js +2 -2
  115. package/components/slider/index.cjs +1 -1
  116. package/components/slider/index.js +1 -1
  117. package/components/swatch/index.cjs +1 -1
  118. package/components/swatch/index.js +2 -2
  119. package/components/switch/index.cjs +1 -1
  120. package/components/switch/index.js +1 -1
  121. package/components/tabs/index.cjs +1 -1
  122. package/components/tabs/index.js +2 -2
  123. package/components/tags/index.cjs +4 -4
  124. package/components/tags/index.js +3 -3
  125. package/components/text-field/index.cjs +1 -1
  126. package/components/text-field/index.js +2 -2
  127. package/components/{text-field-DFP7p8Rv.cjs → text-field-CclDsK1X.cjs} +1 -1
  128. package/components/{text-field-BHaLKkf1.js → text-field-Ckbe58fH.js} +1 -1
  129. package/components/toast/index.cjs +1 -1
  130. package/components/toast/index.js +2 -2
  131. package/components/tooltip/index.cjs +1 -1
  132. package/components/tooltip/index.js +1 -1
  133. package/components/utils.cjs +1 -1
  134. package/components/utils.js +2 -2
  135. package/custom-elements.json +1 -1
  136. package/package.json +1 -1
@@ -15,7 +15,7 @@
15
15
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
16
  * SOFTWARE.
17
17
  * */
18
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const h=require("@internationalized/number"),c=require("@luzmo/icons"),b=require("lit"),l=require("lit/decorators.js"),m=require("../platform-BJnOJJag.cjs"),z=require("../language-resolution-EUER43cg.cjs"),y=require("../streaming-listener-D9Wc7skA.cjs");require("../infield-button/index.cjs");const x=require("../text-field-DFP7p8Rv.cjs"),k='#text-field{--stepper-width: calc( var(--luzmo-stepper-height, var(--stepper-height)) * var( --luzmo-stepper-min-width-multiplier, var(--stepper-min-width-multiplier) ) + var(--luzmo-stepper-button-width, var(--stepper-button-width)) + var(--luzmo-stepper-border-width, var(--stepper-border-width)) * 2 );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color, var( --luzmo-stepper-buttons-border-color, var(--stepper-buttons-border-color) ) );--luzmo-infield-button-border-width: var( --luzmo-stepper-button-border-width, var(--stepper-button-border-width) );--luzmo-infield-button-border-radius-reset: var( --stepper-button-border-radius-reset );--luzmo-text-field-border-width: var( --luzmo-stepper-border-width, var(--stepper-border-width) );inline-size:var(--luzmo-stepper-width, var(--stepper-width));block-size:var(--luzmo-stepper-height, var(--stepper-height));border-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));border-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));flex-flow:row;display:inline-flex;position:relative}#text-field:after{content:"";inline-size:100%;block-size:var(--luzmo-stepper-focus-indicator-width, var(--stepper-focus-indicator-width));position:absolute;inset-block-end:calc((var(--luzmo-stepper-focus-indicator-gap, var(--stepper-focus-indicator-gap)) + var(--luzmo-stepper-focus-indicator-width, var(--stepper-focus-indicator-width))) * -1);inset-inline-start:0}:host([focused]) #text-field,#text-field:focus{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-focus, var(--luzmo-stepper-border-color-focus, var(--stepper-border-color-focus)) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus, var( --luzmo-stepper-buttons-border-color-focus, var(--stepper-buttons-border-color-focus) ) )}:host([focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus .input{outline:none}:host([focused]:not([disabled])) #text-field .buttons,:host([focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus .buttons,:host(:not([disabled])) #text-field:focus .input{border-color:var(--highcontrast-stepper-border-color-focus, var(--luzmo-stepper-border-color-focus, var(--stepper-border-color-focus)))}:host([keyboard-focused]) #text-field,#text-field:focus-visible{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-keyboard-focus, var( --luzmo-stepper-buttons-border-color-keyboard-focus, var(--stepper-buttons-border-color-keyboard-focus) ) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-keyboard-focus, var( --luzmo-stepper-buttons-border-color-keyboard-focus, var(--stepper-buttons-border-color-keyboard-focus) ) )}:host([keyboard-focused]:not([disabled])) #text-field,:host(:not([disabled])) #text-field:focus-visible{outline:var(--luzmo-stepper-focus-indicator-width, var(--stepper-focus-indicator-width)) solid;outline-color:var(--highcontrast-stepper-focus-indicator-color, var(--luzmo-stepper-focus-indicator-color, var(--stepper-focus-indicator-color)));outline-offset:var(--luzmo-stepper-focus-indicator-gap, var(--stepper-focus-indicator-gap))}:host([keyboard-focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus-visible .input{outline:none}:host([keyboard-focused]:not([disabled])) #text-field .buttons,:host([keyboard-focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus-visible .buttons,:host(:not([disabled])) #text-field:focus-visible .input{border-color:var(--highcontrast-stepper-border-color-keyboard-focus, var(--luzmo-stepper-border-color-keyboard-focus, var(--stepper-border-color-keyboard-focus)))}:host([invalid]:not([disabled])) #text-field{--luzmo-stepper-border-color: var( --luzmo-stepper-border-color-invalid, var(--stepper-border-color-invalid) );--luzmo-stepper-border-color-hover: var( --luzmo-stepper-border-color-hover-invalid, var(--stepper-border-color-hover-invalid) );--luzmo-stepper-border-color-focus: var( --luzmo-stepper-border-color-focus-invalid, var(--stepper-border-color-focus-invalid) );--luzmo-stepper-border-color-focus-hover: var( --luzmo-stepper-border-color-focus-hover-invalid, var(--stepper-border-color-focus-hover-invalid) );--luzmo-stepper-border-color-keyboard-focus: var( --luzmo-stepper-border-color-keyboard-focus-invalid, var(--stepper-border-color-keyboard-focus-invalid) );--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-invalid, var(--stepper-border-color-invalid) );--luzmo-text-field-icon-spacing-inline-start-invalid: 0}:host([invalid][focused]:not([disabled])) #text-field,:host([invalid]:not([disabled])) #text-field:focus{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-focus-invalid, var(--stepper-border-color-focus-invalid) )}:host([invalid][keyboard-focused]:not([disabled])) #text-field,:host([invalid]:not([disabled])) #text-field:focus-visible{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-keyboard-focus-invalid, var(--stepper-border-color-keyboard-focus-invalid) )}:host([disabled]) #text-field{--luzmo-stepper-border-color: var(--stepper-button-border-color-disabled);--luzmo-stepper-border-color-hover: var( --stepper-button-border-color-disabled );--luzmo-stepper-border-color-focus: var( --stepper-button-border-color-disabled );--luzmo-stepper-border-color-focus-hover: var( --stepper-button-border-color-disabled );--luzmo-stepper-border-color-keyboard-focus: var( --stepper-button-border-color-disabled );--luzmo-stepper-buttons-background-color: var( --stepper-buttons-background-color-disabled );--luzmo-infield-button-border-width: var( --stepper-button-border-width-disabled );--luzmo-infield-button-border-color: var( --stepper-button-border-color-disabled );--luzmo-text-field-border-color-disabled: var( --stepper-button-border-color-disabled )}#text-field .input{border-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));border-inline-end-width:0;border-start-end-radius:0;border-end-end-radius:0}#text-field.hide-stepper .input{border-inline-end-width:var(--luzmo-stepper-border-width, var(--stepper-border-width));border-start-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));border-end-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius))}#text-field .buttons{box-sizing:border-box;font-size:var(--luzmo-stepper-button-font-size, var(--stepper-button-font-size));block-size:var(--luzmo-stepper-height, var(--stepper-height));inline-size:var(--luzmo-stepper-button-width, var(--stepper-button-width));border-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));border-style:var(--luzmo-stepper-buttons-border-style, var(--stepper-buttons-border-style));border-width:var(--highcontrast-stepper-buttons-border-width, var(--luzmo-stepper-buttons-border-width, var(--stepper-buttons-border-width)));background-color:var(--highcontrast-stepper-buttons-background-color, var(--luzmo-stepper-buttons-background-color, var(--stepper-buttons-background-color)));transition:border-color var(--luzmo-stepper-animation-duration, var(--stepper-animation-duration)) ease-in-out;border-inline-start-width:0;border-start-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));border-end-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));flex-direction:column;justify-content:center;display:flex}:host([quiet]) #text-field{border-start-start-radius:0;border-start-end-radius:0;border-end-end-radius:0;border-end-start-radius:0}:host([quiet]) #text-field .input{--luzmo-text-field-focus-indicator-color: transparent}:host([quiet]) #text-field.hide-stepper .input{border-inline-end-width:0;border-end-end-radius:0}:host([quiet]) #text-field .buttons{--luzmo-infield-button-border-color: transparent;border-width:0;border-block-end-width:var(--luzmo-stepper-border-width, var(--stepper-border-width));border-block-end-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));border-block-end-style:solid;border-end-end-radius:0}:host([quiet]) #text-field .button{--luzmo-infield-button-width-stacked: var( --luzmo-stepper-button-width-quiet, var(--stepper-button-width) );--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-quiet, var(--stepper-button-border-color-quiet) );--luzmo-infield-button-stacked-bottom-border-block-end-width: var( --luzmo-stepper-border-width, var(--stepper-border-width) );--luzmo-infield-button-stacked-bottom-border-radius-end-end: 0;--luzmo-infield-button-stacked-bottom-border-radius-end-start: 0;--luzmo-infield-button-fill-justify-content: flex-end;padding:0}:host([quiet]) #text-field .buttons,:host([quiet]) #text-field .input{background-color:initial}:host([quiet][focused]) #text-field,:host([quiet]) #text-field:focus{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus, var(--luzmo-stepper-border-color-focus, var(--stepper-border-color-focus)) )}:host([quiet][keyboard-focused]:not([disabled])) #text-field{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-keyboard-focus, var( --luzmo-stepper-border-color-keyboard-focus, var(--stepper-border-color-keyboard-focus) ) );outline:none}:host([quiet][keyboard-focused]:not([disabled])) #text-field:after{background-color:var(--highcontrast-stepper-focus-indicator-color, var(--luzmo-stepper-focus-indicator-color, var(--stepper-focus-indicator-color)))}@media (hover: hover){:host(:hover:not([disabled])) #text-field{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-hover, var(--luzmo-stepper-border-color-hover, var(--stepper-border-color-hover)) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-hover, var( --luzmo-stepper-buttons-border-color-hover, var(--stepper-buttons-border-color-hover) ) )}:host([focused]:hover) #text-field,:host(:hover) #text-field:focus{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-focus-hover, var( --luzmo-stepper-buttons-border-color-focus-hover, var(--stepper-buttons-border-color-focus-hover) ) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus-hover, var( --luzmo-stepper-buttons-border-color-focus-hover, var(--stepper-buttons-border-color-focus-hover) ) )}:host([focused]:hover) #text-field .buttons,:host([focused]:hover) #text-field .input,:host(:hover) #text-field:focus .buttons,:host(:hover) #text-field:focus .input{border-color:var(--highcontrast-stepper-border-color-focus-hover, var(--luzmo-stepper-border-color-focus-hover, var(--stepper-border-color-focus-hover)))}:host([invalid]:not([disabled]):hover) #text-field{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-hover-invalid, var(--stepper-border-color-hover-invalid) )}:host([invalid][focused]:not([disabled]):hover) #text-field,:host([invalid]:not([disabled]):hover) #text-field:focus{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-focus-hover-invalid, var(--stepper-border-color-focus-hover-invalid) )}:host([quiet]:not([disabled]):hover) #text-field{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-hover, var(--luzmo-stepper-border-color-hover, var(--stepper-border-color-hover)) )}:host([quiet]:not([disabled]):hover) #text-field .buttons{background-color:initial}:host([quiet][focused]:hover) #text-field,:host([quiet]:hover) #text-field:focus{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus-hover, var( --luzmo-stepper-border-color-focus-hover, var(--stepper-border-color-focus-hover) ) )}:host([quiet][keyboard-focused]:not([disabled]):hover) #text-field{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-hover, var(--luzmo-stepper-border-color-hover, var(--stepper-border-color-hover)) )}}:host([invalid]) #text-field .icon,:host([valid]) #text-field .icon{inset-inline-end:calc(var(--stepper-button-width) + var(--luzmo-text-field-icon-spacing-inline-end-invalid, var(--text-field-icon-spacing-inline-end-invalid)))}@media (forced-colors: active){:host{--highcontrast-stepper-border-color: CanvasText;--highcontrast-stepper-border-color-hover: Highlight;--highcontrast-stepper-border-color-focus: Highlight;--highcontrast-stepper-border-color-focus-hover: Highlight;--highcontrast-stepper-border-color-keyboard-focus: CanvasText;--highcontrast-stepper-button-background-color-default: Canvas;--highcontrast-stepper-button-background-color-hover: Canvas;--highcontrast-stepper-button-background-color-focus: Canvas;--highcontrast-stepper-button-background-color-keyboard-focus: Canvas;--highcontrast-stepper-focus-indicator-color: Highlight}:host([invalid]) #text-field{--highcontrast-stepper-border-color: Highlight;--highcontrast-stepper-border-color-hover: Highlight;--highcontrast-stepper-border-color-focus: Highlight;--highcontrast-stepper-border-color-focus-hover: Highlight;--highcontrast-stepper-border-color-keyboard-focus: Highlight;--highcontrast-infield-button-border-color: Highlight}:host([disabled]) #text-field{--highcontrast-stepper-border-color: GrayText;--highcontrast-infield-button-border-color: GrayText;--highcontrast-stepper-buttons-border-width: var( --luzmo-stepper-border-width, var(--stepper-border-width) )}}:host{--text-field-minimum-width-multiplier: 2;--stepper-border-width: var(--luzmo-border-width);--stepper-border-color: var(--luzmo-border-color);--stepper-border-color-hover: var(--luzmo-border-color-full-hover);--stepper-border-color-focus: var(--luzmo-border-color-full-focus);--stepper-border-color-focus-hover: var(--luzmo-border-color-full-focus);--stepper-border-color-keyboard-focus: var(--luzmo-border-color-full-focus);--stepper-border-radius: var(--luzmo-border-radius);--stepper-min-width-multiplier: 1.5;--stepper-animation-duration: var(--luzmo-animation-duration);--stepper-buttons-background-color: var(--luzmo-background-color);--stepper-buttons-border-style: none;--stepper-buttons-border-width: 0;--stepper-buttons-border-color: var(--luzmo-border-color);--stepper-buttons-border-color-hover: var(--luzmo-border-color-full-hover);--stepper-buttons-border-color-focus: var(--luzmo-border-color-full-focus);--stepper-buttons-border-color-keyboard-focus: var( --luzmo-border-color-focus );--stepper-button-font-size: var(--luzmo-font-size);--stepper-button-padding: 0px;--stepper-button-border-radius-reset: 0;--stepper-button-border-width: var(--luzmo-border-width);--stepper-button-background-color-focus: var(--luzmo-background-color-focus);--stepper-button-background-color-keyboard-focus: var( --luzmo-background-color-focus );--stepper-border-color-invalid: var(--luzmo-negative-color);--stepper-border-color-hover-invalid: var(--luzmo-negative-color-hover);--stepper-border-color-focus-invalid: var(--luzmo-negative-color-focus);--stepper-border-color-focus-hover-invalid: var(--luzmo-negative-color-focus);--stepper-border-color-keyboard-focus-invalid: var( --luzmo-negative-color-focus );--stepper-focus-indicator-width: var(--luzmo-indicator-width);--stepper-focus-indicator-gap: calc(-1 * var(--luzmo-border-width));--stepper-focus-indicator-color: var(--luzmo-indicator-color);--stepper-button-border-color-quiet: transparent;--stepper-button-border-color-disabled: var(--luzmo-border-color-disabled);--stepper-button-border-width-disabled: var(--luzmo-border-width);--stepper-buttons-background-color-disabled: var( --luzmo-background-color-disabled );--stepper-button-width: 20px;--stepper-height: var(--luzmo-component-height)}:host([size=s]) #text-field{--stepper-button-width: 16px;--stepper-height: var(--luzmo-component-height-s)}:host([size=m]) #text-field{--stepper-button-width: 20px;--stepper-height: var(--luzmo-component-height)}:host([size=l]) #text-field{--stepper-button-width: 28px;--stepper-height: var(--luzmo-component-height-l)}:host([size=xl]) #text-field{--stepper-button-width: 36px;--stepper-height: var(--luzmo-component-height-xl)}:host{inline-size:var(--luzmo-stepper-width, var(--stepper-width));--number-field-width: calc( var(--luzmo-stepper-height, var(--stepper-height)) * var( --luzmo-stepper-min-width-multiplier, var(--text-field-minimum-width-multiplier) ) + var(--luzmo-stepper-button-width, var(--stepper-button-width)) + var(--luzmo-stepper-border-width, var(--stepper-border-width)) * 2 );--luzmo-infield-button-border-width: var(--unset-value-resets-inheritance);--stepper-width: var(--number-field-width)}:host([size=s]){--stepper-width: calc(var(--number-field-width) / 5 * 4);--stepper-button-font-size: var(--luzmo-font-size-s)}:host([size=l]){--stepper-width: calc(var(--number-field-width) * 1.25);--stepper-button-font-size: var(--luzmo-font-size-l)}:host([size=xl]){--stepper-width: calc(var(--number-field-width) * 1.25 * 1.25);--stepper-button-font-size: var(--luzmo-font-size-xl)}#text-field{inline-size:100%}.input{font-variant-numeric:tabular-nums}:host([readonly]) .buttons{pointer-events:none;visibility:hidden}:host([readonly]:not([disabled],[invalid],[focused],[keyboard-focused])) #text-field:hover .input{border-color:transparent}:host([hide-stepper]:not([quiet])) #text-field input{border:var(--luzmo-stepper-border-width, var(--stepper-border-width)) solid var(--luzmo-stepper-border-color, var(--stepper-border-color));border-radius:var(--luzmo-border-radius)}:host([quiet]) #text-field .button{--luzmo-infield-button-border-color: var( --luzmo-infield-border-color-quiet, transparent );--luzmo-infield-button-edge-to-fill: 0;--luzmo-infield-button-border-width: var( --luzmo-infield-button-border-width-quiet, 0 )}:host([grows]){--number-field-char-count: 1;--number-field-content-width: calc( var(--number-field-char-count) * 1ch + var(--luzmo-text-field-spacing-inline, var(--text-field-spacing-inline)) * 2 );--number-field-grows-width: calc( var(--number-field-content-width) + var(--luzmo-stepper-button-width, var(--stepper-button-width)) + var(--luzmo-stepper-border-width, var(--stepper-border-width)) * 2 );inline-size:var(--number-field-grows-width);min-inline-size:var(--luzmo-stepper-width, var(--stepper-width));max-inline-size:100%}:host([grows]) #text-field{inline-size:100%}:host([grows]) #text-field .input{inline-size:100%;min-inline-size:0}';var F=Object.defineProperty,C=Object.getOwnPropertyDescriptor,n=(v,e,t,o)=>{for(var r=o>1?void 0:o?C(e,t):e,i=v.length-1,u;i>=0;i--)(u=v[i])&&(r=(o?u(e,t,r):u(r))||r);return o&&r&&F(e,t,r),r};const _=5,N=100,f="-",w={"1":"1","2":"2","3":"3","4":"4","5":"5","6":"6","7":"7","8":"8","9":"9","0":"0","、":",",",":",","。":".",".":".","%":"%","+":"+",ー:"-",一:"1",二:"2",三:"3",四:"4",五:"5",六:"6",七:"7",八:"8",九:"9",零:"0"};class s extends x.LuzmoTextFieldBase{constructor(){super(...arguments),this.focused=!1,this._forcedUnit="",this.formatOptions={},this.hideStepper=!1,this.grows=!1,this.indeterminate=!1,this.keyboardFocused=!1,this.managedInput=!1,this.stepModifier=10,this._value=Number.NaN,this._trackingValue="",this.decimalsChars=new Set([".",","]),this.valueBeforeFocus="",this.isIntentDecimal=!1,this.changeCount=0,this.languageResolver=new z.LanguageResolutionController(this),this.wasIndeterminate=!1,this.hasRecentlyReceivedPointerDown=!1,this.applyFocusElementLabel=e=>{this.appliedLabel=e},this.isComposing=!1}static get styles(){return[...super.styles,b.unsafeCSS(k)]}set value(e){const t=this.validateInput(e);if(t===this.value)return;this.lastCommitedValue=t;const o=this._value;this._value=t,this.requestUpdate("value",o)}get value(){return this._value}get inputValue(){return this.indeterminate?this.formattedValue:this.inputElement.value}setValue(e=this.value){const t=this.lastCommitedValue;this.value=e,!(t===void 0||t===this.value)&&(this.lastCommitedValue=this.value,this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0})))}get valueAsString(){return this._value.toString()}set valueAsString(e){this.value=this.numberParser.parse(e)}get formattedValue(){return Number.isNaN(this.value)?"":this.numberFormatter.format(this.value)+(this.focused?"":this._forcedUnit)}convertValueToNumber(e){let t=[...e].map(i=>w[i]||i).join("");const o=[...this.valueBeforeFocus].filter(i=>this.decimalsChars.has(i)),r=new Set(o);if(m.isIOS()&&this.inputElement.inputMode==="decimal"&&t!==this.valueBeforeFocus){const u=this.numberFormatter.formatToParts(1000.1).find(d=>d.type==="decimal").value;for(const d of r)!(d===u)&&!this.isIntentDecimal&&(t=t.replaceAll(new RegExp(d,"g"),""));let p=!1;const a=[...t];for(let d=a.length-1;d>=0;d--){const g=a[d];this.decimalsChars.has(g)&&(p?a[d]="":(a[d]=u,p=!0))}t=a.join("")}return this.numberParser.parse(t)}get _step(){var e;return this.step!==void 0?this.step:((e=this.formatOptions)==null?void 0:e.style)==="percent"?.01:1}handlePointerdown(e){if(e.button!==0){e.preventDefault();return}this.managedInput=!0,this.buttons.setPointerCapture(e.pointerId);const t=this.buttons.children[0].getBoundingClientRect(),o=this.buttons.children[1].getBoundingClientRect();this.findChange=r=>{r.clientX>=t.x&&r.clientY>=t.y&&r.clientX<=t.x+t.width&&r.clientY<=t.y+t.height?this.change=i=>this.increment(i.shiftKey?this.stepModifier:1):r.clientX>=o.x&&r.clientY>=o.y&&r.clientX<=o.x+o.width&&r.clientY<=o.y+o.height&&(this.change=i=>this.decrement(i.shiftKey?this.stepModifier:1))},this.findChange(e),this.startChange(e)}startChange(e){this.changeCount=0,this.doChange(e),this.safty=setTimeout(()=>{this.doNextChange(e)},400)}doChange(e){this.change(e)}handlePointermove(e){this.findChange(e)}handlePointerup(e){this.buttons.releasePointerCapture(e.pointerId),cancelAnimationFrame(this.nextChange),clearTimeout(this.safty),this.managedInput=!1,this.setValue()}doNextChange(e){return this.changeCount+=1,this.changeCount%_===0&&this.doChange(e),requestAnimationFrame(()=>{this.nextChange=this.doNextChange(e)})}stepBy(e){if(this.disabled||this.readonly)return;const t=this.min===void 0?0:this.min;let o=this.value;o+=e*this._step,Number.isNaN(this.value)&&(o=t),o=this.valueWithLimits(o),this.requestUpdate(),this._value=this.validateInput(o),this.inputElement.value=this.numberFormatter.format(o),this.inputElement.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),this.indeterminate=!1,this.focus()}increment(e=1){this.stepBy(1*e)}decrement(e=1){this.stepBy(-1*e)}handleKeydown(e){if(!this.isComposing)switch(e.code){case"ArrowUp":{e.preventDefault(),this.increment(e.shiftKey?this.stepModifier:1),this.setValue();break}case"ArrowDown":{e.preventDefault(),this.decrement(e.shiftKey?this.stepModifier:1),this.setValue();break}}}onScroll(e){e.preventDefault(),this.managedInput=!0;const t=e.shiftKey?e.deltaX/Math.abs(e.deltaX):e.deltaY/Math.abs(e.deltaY);t!==0&&!Number.isNaN(t)&&(this.stepBy(t*(e.shiftKey?this.stepModifier:1)),clearTimeout(this.queuedChangeEvent),this.queuedChangeEvent=setTimeout(()=>{this.setValue()},N)),this.managedInput=!1}onFocus(){super.onFocus(),this._trackingValue=this.inputValue,this.keyboardFocused=!this.readonly&&!0,this.addEventListener("wheel",this.onScroll,{passive:!1}),this.valueBeforeFocus=this.inputElement.value}onBlur(e){super.onBlur(e),this.keyboardFocused=!this.readonly&&!1,this.removeEventListener("wheel",this.onScroll),this.isIntentDecimal=!1}handleFocusin(){this.focused=!this.readonly&&!0,this.keyboardFocused=!this.readonly&&!0}handleFocusout(){this.focused=!this.readonly&&!1,this.keyboardFocused=!this.readonly&&!1}handleChange(){const e=this.convertValueToNumber(this.inputValue);if(this.wasIndeterminate&&(this.wasIndeterminate=!1,this.indeterminateValue=void 0,Number.isNaN(e))){this.indeterminate=!0;return}this.setValue(e),this.inputElement.value=this.formattedValue}handleCompositionStart(){this.isComposing=!0}handleCompositionEnd(){this.isComposing=!1,requestAnimationFrame(()=>{this.inputElement.dispatchEvent(new Event("input",{composed:!0,bubbles:!0}))})}handleInputElementPointerdown(){this.hasRecentlyReceivedPointerDown=!0,this.updateComplete.then(()=>{requestAnimationFrame(()=>{this.hasRecentlyReceivedPointerDown=!1})})}handleInput(e){if(this.isComposing){if(e.data){const a=this.convertValueToNumber(e.data);Number.isNaN(a)&&(this.inputElement.value=this.indeterminate?f:this._trackingValue,this.isComposing=!1)}e.stopPropagation();return}this.indeterminate&&(this.wasIndeterminate=!0,this.indeterminateValue=this.value,this.inputElement.value=this.inputElement.value.replace(f,"")),e.data&&this.decimalsChars.has(e.data)&&(this.isIntentDecimal=!0);const{value:t,selectionStart:o}=this.inputElement,r=[...t].map(a=>w[a]||a).join("");if(this.numberParser.isValidPartialNumber(r)){this.lastCommitedValue=this.lastCommitedValue??this.value;const a=this.convertValueToNumber(r);!r&&this.indeterminateValue?(this.indeterminate=!0,this._value=this.indeterminateValue):(this.indeterminate=!1,this._value=this.validateInput(a)),this._trackingValue=r,this.inputElement.value=r,this.inputElement.setSelectionRange(o,o);return}this.inputElement.value=this.indeterminate?f:this._trackingValue,e.stopPropagation();const i=r.length,u=this._trackingValue.length,p=(o||i)-(i-u);this.inputElement.setSelectionRange(p,p)}valueWithLimits(e){let t=e;return this.min!==void 0&&(t=Math.max(this.min,t)),this.max!==void 0&&(t=Math.min(this.max,t)),t}validateInput(e){e=this.valueWithLimits(e);const t=e<0?-1:1;if(e*=t,this.step){const o=this.min===void 0?0:this.min,r=Number.parseFloat(this.valueFormatter.format((e-o)%this.step));if(r===0||(Math.round(r/this.step)===1?e+=this.step-r:e-=r),this.max!==void 0)for(;e>this.max;)e-=this.step;e=Number.parseFloat(this.valueFormatter.format(e))}return e*=t,e}get displayValue(){const e=this.focused?"":f;return this.indeterminate?e:this.formattedValue}clearNumberFormatterCache(){this._numberFormatter=void 0,this._numberParser=void 0}get numberFormatter(){if(!this._numberFormatter||!this._numberFormatterFocused){const{style:e,unit:t,unitDisplay:o,...r}=this.formatOptions;e!=="unit"&&(r.style=e),this._numberFormatterFocused=new h.NumberFormatter(this.languageResolver.language,r);try{this._numberFormatter=new h.NumberFormatter(this.languageResolver.language,this.formatOptions),this._forcedUnit="",this._numberFormatter.format(1)}catch{e==="unit"&&(this._forcedUnit=t),this._numberFormatter=this._numberFormatterFocused}}return this.focused?this._numberFormatterFocused:this._numberFormatter}clearValueFormatterCache(){this._valueFormatter=void 0}get valueFormatter(){if(!this._valueFormatter){const e=this.step?this.step===Math.floor(this.step)?0:this.step.toString().split(".")[1].length:0;this._valueFormatter=new h.NumberFormatter("en",{useGrouping:!1,maximumFractionDigits:e})}return this._valueFormatter}get numberParser(){if(!this._numberParser||!this._numberParserFocused){const{style:e,unit:t,unitDisplay:o,...r}=this.formatOptions;e!=="unit"&&(r.style=e),this._numberParserFocused=new h.NumberParser(this.languageResolver.language,r);try{this._numberParser=new h.NumberParser(this.languageResolver.language,this.formatOptions),this._forcedUnit="",this._numberParser.parse("0")}catch{e==="unit"&&(this._forcedUnit=t),this._numberParser=this._numberParserFocused}}return this.focused?this._numberParserFocused:this._numberParser}renderField(){return this.autocomplete="off",b.html`
18
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const h=require("@internationalized/number"),c=require("@luzmo/icons"),b=require("lit"),l=require("lit/decorators.js"),m=require("../platform-BJnOJJag.cjs"),z=require("../language-resolution-DmX3Wy5I.cjs"),y=require("../streaming-listener-D9Wc7skA.cjs");require("../infield-button/index.cjs");const x=require("../text-field-CclDsK1X.cjs"),k='#text-field{--stepper-width: calc( var(--luzmo-stepper-height, var(--stepper-height)) * var( --luzmo-stepper-min-width-multiplier, var(--stepper-min-width-multiplier) ) + var(--luzmo-stepper-button-width, var(--stepper-button-width)) + var(--luzmo-stepper-border-width, var(--stepper-border-width)) * 2 );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color, var( --luzmo-stepper-buttons-border-color, var(--stepper-buttons-border-color) ) );--luzmo-infield-button-border-width: var( --luzmo-stepper-button-border-width, var(--stepper-button-border-width) );--luzmo-infield-button-border-radius-reset: var( --stepper-button-border-radius-reset );--luzmo-text-field-border-width: var( --luzmo-stepper-border-width, var(--stepper-border-width) );inline-size:var(--luzmo-stepper-width, var(--stepper-width));block-size:var(--luzmo-stepper-height, var(--stepper-height));border-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));border-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));flex-flow:row;display:inline-flex;position:relative}#text-field:after{content:"";inline-size:100%;block-size:var(--luzmo-stepper-focus-indicator-width, var(--stepper-focus-indicator-width));position:absolute;inset-block-end:calc((var(--luzmo-stepper-focus-indicator-gap, var(--stepper-focus-indicator-gap)) + var(--luzmo-stepper-focus-indicator-width, var(--stepper-focus-indicator-width))) * -1);inset-inline-start:0}:host([focused]) #text-field,#text-field:focus{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-focus, var(--luzmo-stepper-border-color-focus, var(--stepper-border-color-focus)) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus, var( --luzmo-stepper-buttons-border-color-focus, var(--stepper-buttons-border-color-focus) ) )}:host([focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus .input{outline:none}:host([focused]:not([disabled])) #text-field .buttons,:host([focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus .buttons,:host(:not([disabled])) #text-field:focus .input{border-color:var(--highcontrast-stepper-border-color-focus, var(--luzmo-stepper-border-color-focus, var(--stepper-border-color-focus)))}:host([keyboard-focused]) #text-field,#text-field:focus-visible{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-keyboard-focus, var( --luzmo-stepper-buttons-border-color-keyboard-focus, var(--stepper-buttons-border-color-keyboard-focus) ) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-keyboard-focus, var( --luzmo-stepper-buttons-border-color-keyboard-focus, var(--stepper-buttons-border-color-keyboard-focus) ) )}:host([keyboard-focused]:not([disabled])) #text-field,:host(:not([disabled])) #text-field:focus-visible{outline:var(--luzmo-stepper-focus-indicator-width, var(--stepper-focus-indicator-width)) solid;outline-color:var(--highcontrast-stepper-focus-indicator-color, var(--luzmo-stepper-focus-indicator-color, var(--stepper-focus-indicator-color)));outline-offset:var(--luzmo-stepper-focus-indicator-gap, var(--stepper-focus-indicator-gap))}:host([keyboard-focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus-visible .input{outline:none}:host([keyboard-focused]:not([disabled])) #text-field .buttons,:host([keyboard-focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus-visible .buttons,:host(:not([disabled])) #text-field:focus-visible .input{border-color:var(--highcontrast-stepper-border-color-keyboard-focus, var(--luzmo-stepper-border-color-keyboard-focus, var(--stepper-border-color-keyboard-focus)))}:host([invalid]:not([disabled])) #text-field{--luzmo-stepper-border-color: var( --luzmo-stepper-border-color-invalid, var(--stepper-border-color-invalid) );--luzmo-stepper-border-color-hover: var( --luzmo-stepper-border-color-hover-invalid, var(--stepper-border-color-hover-invalid) );--luzmo-stepper-border-color-focus: var( --luzmo-stepper-border-color-focus-invalid, var(--stepper-border-color-focus-invalid) );--luzmo-stepper-border-color-focus-hover: var( --luzmo-stepper-border-color-focus-hover-invalid, var(--stepper-border-color-focus-hover-invalid) );--luzmo-stepper-border-color-keyboard-focus: var( --luzmo-stepper-border-color-keyboard-focus-invalid, var(--stepper-border-color-keyboard-focus-invalid) );--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-invalid, var(--stepper-border-color-invalid) );--luzmo-text-field-icon-spacing-inline-start-invalid: 0}:host([invalid][focused]:not([disabled])) #text-field,:host([invalid]:not([disabled])) #text-field:focus{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-focus-invalid, var(--stepper-border-color-focus-invalid) )}:host([invalid][keyboard-focused]:not([disabled])) #text-field,:host([invalid]:not([disabled])) #text-field:focus-visible{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-keyboard-focus-invalid, var(--stepper-border-color-keyboard-focus-invalid) )}:host([disabled]) #text-field{--luzmo-stepper-border-color: var(--stepper-button-border-color-disabled);--luzmo-stepper-border-color-hover: var( --stepper-button-border-color-disabled );--luzmo-stepper-border-color-focus: var( --stepper-button-border-color-disabled );--luzmo-stepper-border-color-focus-hover: var( --stepper-button-border-color-disabled );--luzmo-stepper-border-color-keyboard-focus: var( --stepper-button-border-color-disabled );--luzmo-stepper-buttons-background-color: var( --stepper-buttons-background-color-disabled );--luzmo-infield-button-border-width: var( --stepper-button-border-width-disabled );--luzmo-infield-button-border-color: var( --stepper-button-border-color-disabled );--luzmo-text-field-border-color-disabled: var( --stepper-button-border-color-disabled )}#text-field .input{border-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));border-inline-end-width:0;border-start-end-radius:0;border-end-end-radius:0}#text-field.hide-stepper .input{border-inline-end-width:var(--luzmo-stepper-border-width, var(--stepper-border-width));border-start-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));border-end-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius))}#text-field .buttons{box-sizing:border-box;font-size:var(--luzmo-stepper-button-font-size, var(--stepper-button-font-size));block-size:var(--luzmo-stepper-height, var(--stepper-height));inline-size:var(--luzmo-stepper-button-width, var(--stepper-button-width));border-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));border-style:var(--luzmo-stepper-buttons-border-style, var(--stepper-buttons-border-style));border-width:var(--highcontrast-stepper-buttons-border-width, var(--luzmo-stepper-buttons-border-width, var(--stepper-buttons-border-width)));background-color:var(--highcontrast-stepper-buttons-background-color, var(--luzmo-stepper-buttons-background-color, var(--stepper-buttons-background-color)));transition:border-color var(--luzmo-stepper-animation-duration, var(--stepper-animation-duration)) ease-in-out;border-inline-start-width:0;border-start-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));border-end-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));flex-direction:column;justify-content:center;display:flex}:host([quiet]) #text-field{border-start-start-radius:0;border-start-end-radius:0;border-end-end-radius:0;border-end-start-radius:0}:host([quiet]) #text-field .input{--luzmo-text-field-focus-indicator-color: transparent}:host([quiet]) #text-field.hide-stepper .input{border-inline-end-width:0;border-end-end-radius:0}:host([quiet]) #text-field .buttons{--luzmo-infield-button-border-color: transparent;border-width:0;border-block-end-width:var(--luzmo-stepper-border-width, var(--stepper-border-width));border-block-end-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));border-block-end-style:solid;border-end-end-radius:0}:host([quiet]) #text-field .button{--luzmo-infield-button-width-stacked: var( --luzmo-stepper-button-width-quiet, var(--stepper-button-width) );--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-quiet, var(--stepper-button-border-color-quiet) );--luzmo-infield-button-stacked-bottom-border-block-end-width: var( --luzmo-stepper-border-width, var(--stepper-border-width) );--luzmo-infield-button-stacked-bottom-border-radius-end-end: 0;--luzmo-infield-button-stacked-bottom-border-radius-end-start: 0;--luzmo-infield-button-fill-justify-content: flex-end;padding:0}:host([quiet]) #text-field .buttons,:host([quiet]) #text-field .input{background-color:initial}:host([quiet][focused]) #text-field,:host([quiet]) #text-field:focus{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus, var(--luzmo-stepper-border-color-focus, var(--stepper-border-color-focus)) )}:host([quiet][keyboard-focused]:not([disabled])) #text-field{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-keyboard-focus, var( --luzmo-stepper-border-color-keyboard-focus, var(--stepper-border-color-keyboard-focus) ) );outline:none}:host([quiet][keyboard-focused]:not([disabled])) #text-field:after{background-color:var(--highcontrast-stepper-focus-indicator-color, var(--luzmo-stepper-focus-indicator-color, var(--stepper-focus-indicator-color)))}@media (hover: hover){:host(:hover:not([disabled])) #text-field{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-hover, var(--luzmo-stepper-border-color-hover, var(--stepper-border-color-hover)) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-hover, var( --luzmo-stepper-buttons-border-color-hover, var(--stepper-buttons-border-color-hover) ) )}:host([focused]:hover) #text-field,:host(:hover) #text-field:focus{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-focus-hover, var( --luzmo-stepper-buttons-border-color-focus-hover, var(--stepper-buttons-border-color-focus-hover) ) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus-hover, var( --luzmo-stepper-buttons-border-color-focus-hover, var(--stepper-buttons-border-color-focus-hover) ) )}:host([focused]:hover) #text-field .buttons,:host([focused]:hover) #text-field .input,:host(:hover) #text-field:focus .buttons,:host(:hover) #text-field:focus .input{border-color:var(--highcontrast-stepper-border-color-focus-hover, var(--luzmo-stepper-border-color-focus-hover, var(--stepper-border-color-focus-hover)))}:host([invalid]:not([disabled]):hover) #text-field{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-hover-invalid, var(--stepper-border-color-hover-invalid) )}:host([invalid][focused]:not([disabled]):hover) #text-field,:host([invalid]:not([disabled]):hover) #text-field:focus{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-focus-hover-invalid, var(--stepper-border-color-focus-hover-invalid) )}:host([quiet]:not([disabled]):hover) #text-field{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-hover, var(--luzmo-stepper-border-color-hover, var(--stepper-border-color-hover)) )}:host([quiet]:not([disabled]):hover) #text-field .buttons{background-color:initial}:host([quiet][focused]:hover) #text-field,:host([quiet]:hover) #text-field:focus{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus-hover, var( --luzmo-stepper-border-color-focus-hover, var(--stepper-border-color-focus-hover) ) )}:host([quiet][keyboard-focused]:not([disabled]):hover) #text-field{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-hover, var(--luzmo-stepper-border-color-hover, var(--stepper-border-color-hover)) )}}:host([invalid]) #text-field .icon,:host([valid]) #text-field .icon{inset-inline-end:calc(var(--stepper-button-width) + var(--luzmo-text-field-icon-spacing-inline-end-invalid, var(--text-field-icon-spacing-inline-end-invalid)))}@media (forced-colors: active){:host{--highcontrast-stepper-border-color: CanvasText;--highcontrast-stepper-border-color-hover: Highlight;--highcontrast-stepper-border-color-focus: Highlight;--highcontrast-stepper-border-color-focus-hover: Highlight;--highcontrast-stepper-border-color-keyboard-focus: CanvasText;--highcontrast-stepper-button-background-color-default: Canvas;--highcontrast-stepper-button-background-color-hover: Canvas;--highcontrast-stepper-button-background-color-focus: Canvas;--highcontrast-stepper-button-background-color-keyboard-focus: Canvas;--highcontrast-stepper-focus-indicator-color: Highlight}:host([invalid]) #text-field{--highcontrast-stepper-border-color: Highlight;--highcontrast-stepper-border-color-hover: Highlight;--highcontrast-stepper-border-color-focus: Highlight;--highcontrast-stepper-border-color-focus-hover: Highlight;--highcontrast-stepper-border-color-keyboard-focus: Highlight;--highcontrast-infield-button-border-color: Highlight}:host([disabled]) #text-field{--highcontrast-stepper-border-color: GrayText;--highcontrast-infield-button-border-color: GrayText;--highcontrast-stepper-buttons-border-width: var( --luzmo-stepper-border-width, var(--stepper-border-width) )}}:host{--text-field-minimum-width-multiplier: 2;--stepper-border-width: var(--luzmo-border-width);--stepper-border-color: var(--luzmo-border-color);--stepper-border-color-hover: var(--luzmo-border-color-full-hover);--stepper-border-color-focus: var(--luzmo-border-color-full-focus);--stepper-border-color-focus-hover: var(--luzmo-border-color-full-focus);--stepper-border-color-keyboard-focus: var(--luzmo-border-color-full-focus);--stepper-border-radius: var(--luzmo-border-radius);--stepper-min-width-multiplier: 1.5;--stepper-animation-duration: var(--luzmo-animation-duration);--stepper-buttons-background-color: var(--luzmo-background-color);--stepper-buttons-border-style: none;--stepper-buttons-border-width: 0;--stepper-buttons-border-color: var(--luzmo-border-color);--stepper-buttons-border-color-hover: var(--luzmo-border-color-full-hover);--stepper-buttons-border-color-focus: var(--luzmo-border-color-full-focus);--stepper-buttons-border-color-keyboard-focus: var( --luzmo-border-color-focus );--stepper-button-font-size: var(--luzmo-font-size);--stepper-button-padding: 0px;--stepper-button-border-radius-reset: 0;--stepper-button-border-width: var(--luzmo-border-width);--stepper-button-background-color-focus: var(--luzmo-background-color-focus);--stepper-button-background-color-keyboard-focus: var( --luzmo-background-color-focus );--stepper-border-color-invalid: var(--luzmo-negative-color);--stepper-border-color-hover-invalid: var(--luzmo-negative-color-hover);--stepper-border-color-focus-invalid: var(--luzmo-negative-color-focus);--stepper-border-color-focus-hover-invalid: var(--luzmo-negative-color-focus);--stepper-border-color-keyboard-focus-invalid: var( --luzmo-negative-color-focus );--stepper-focus-indicator-width: var(--luzmo-indicator-width);--stepper-focus-indicator-gap: calc(-1 * var(--luzmo-border-width));--stepper-focus-indicator-color: var(--luzmo-indicator-color);--stepper-button-border-color-quiet: transparent;--stepper-button-border-color-disabled: var(--luzmo-border-color-disabled);--stepper-button-border-width-disabled: var(--luzmo-border-width);--stepper-buttons-background-color-disabled: var( --luzmo-background-color-disabled );--stepper-button-width: 20px;--stepper-height: var(--luzmo-component-height)}:host([size=s]) #text-field{--stepper-button-width: 16px;--stepper-height: var(--luzmo-component-height-s)}:host([size=m]) #text-field{--stepper-button-width: 20px;--stepper-height: var(--luzmo-component-height)}:host([size=l]) #text-field{--stepper-button-width: 28px;--stepper-height: var(--luzmo-component-height-l)}:host([size=xl]) #text-field{--stepper-button-width: 36px;--stepper-height: var(--luzmo-component-height-xl)}:host{inline-size:var(--luzmo-stepper-width, var(--stepper-width));--number-field-width: calc( var(--luzmo-stepper-height, var(--stepper-height)) * var( --luzmo-stepper-min-width-multiplier, var(--text-field-minimum-width-multiplier) ) + var(--luzmo-stepper-button-width, var(--stepper-button-width)) + var(--luzmo-stepper-border-width, var(--stepper-border-width)) * 2 );--luzmo-infield-button-border-width: var(--unset-value-resets-inheritance);--stepper-width: var(--number-field-width)}:host([size=s]){--stepper-width: calc(var(--number-field-width) / 5 * 4);--stepper-button-font-size: var(--luzmo-font-size-s)}:host([size=l]){--stepper-width: calc(var(--number-field-width) * 1.25);--stepper-button-font-size: var(--luzmo-font-size-l)}:host([size=xl]){--stepper-width: calc(var(--number-field-width) * 1.25 * 1.25);--stepper-button-font-size: var(--luzmo-font-size-xl)}#text-field{inline-size:100%}.input{font-variant-numeric:tabular-nums}:host([readonly]) .buttons{pointer-events:none;visibility:hidden}:host([readonly]:not([disabled],[invalid],[focused],[keyboard-focused])) #text-field:hover .input{border-color:transparent}:host([hide-stepper]:not([quiet])) #text-field input{border:var(--luzmo-stepper-border-width, var(--stepper-border-width)) solid var(--luzmo-stepper-border-color, var(--stepper-border-color));border-radius:var(--luzmo-border-radius)}:host([quiet]) #text-field .button{--luzmo-infield-button-border-color: var( --luzmo-infield-border-color-quiet, transparent );--luzmo-infield-button-edge-to-fill: 0;--luzmo-infield-button-border-width: var( --luzmo-infield-button-border-width-quiet, 0 )}:host([grows]){--number-field-char-count: 1;--number-field-content-width: calc( var(--number-field-char-count) * 1ch + var(--luzmo-text-field-spacing-inline, var(--text-field-spacing-inline)) * 2 );--number-field-grows-width: calc( var(--number-field-content-width) + var(--luzmo-stepper-button-width, var(--stepper-button-width)) + var(--luzmo-stepper-border-width, var(--stepper-border-width)) * 2 );inline-size:var(--number-field-grows-width);min-inline-size:var(--luzmo-stepper-width, var(--stepper-width));max-inline-size:100%}:host([grows]) #text-field{inline-size:100%}:host([grows]) #text-field .input{inline-size:100%;min-inline-size:0}';var F=Object.defineProperty,C=Object.getOwnPropertyDescriptor,n=(v,e,t,o)=>{for(var r=o>1?void 0:o?C(e,t):e,i=v.length-1,u;i>=0;i--)(u=v[i])&&(r=(o?u(e,t,r):u(r))||r);return o&&r&&F(e,t,r),r};const _=5,N=100,f="-",w={"1":"1","2":"2","3":"3","4":"4","5":"5","6":"6","7":"7","8":"8","9":"9","0":"0","、":",",",":",","。":".",".":".","%":"%","+":"+",ー:"-",一:"1",二:"2",三:"3",四:"4",五:"5",六:"6",七:"7",八:"8",九:"9",零:"0"};class s extends x.LuzmoTextFieldBase{constructor(){super(...arguments),this.focused=!1,this._forcedUnit="",this.formatOptions={},this.hideStepper=!1,this.grows=!1,this.indeterminate=!1,this.keyboardFocused=!1,this.managedInput=!1,this.stepModifier=10,this._value=Number.NaN,this._trackingValue="",this.decimalsChars=new Set([".",","]),this.valueBeforeFocus="",this.isIntentDecimal=!1,this.changeCount=0,this.languageResolver=new z.LanguageResolutionController(this),this.wasIndeterminate=!1,this.hasRecentlyReceivedPointerDown=!1,this.applyFocusElementLabel=e=>{this.appliedLabel=e},this.isComposing=!1}static get styles(){return[...super.styles,b.unsafeCSS(k)]}set value(e){const t=this.validateInput(e);if(t===this.value)return;this.lastCommitedValue=t;const o=this._value;this._value=t,this.requestUpdate("value",o)}get value(){return this._value}get inputValue(){return this.indeterminate?this.formattedValue:this.inputElement.value}setValue(e=this.value){const t=this.lastCommitedValue;this.value=e,!(t===void 0||t===this.value)&&(this.lastCommitedValue=this.value,this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0})))}get valueAsString(){return this._value.toString()}set valueAsString(e){this.value=this.numberParser.parse(e)}get formattedValue(){return Number.isNaN(this.value)?"":this.numberFormatter.format(this.value)+(this.focused?"":this._forcedUnit)}convertValueToNumber(e){let t=[...e].map(i=>w[i]||i).join("");const o=[...this.valueBeforeFocus].filter(i=>this.decimalsChars.has(i)),r=new Set(o);if(m.isIOS()&&this.inputElement.inputMode==="decimal"&&t!==this.valueBeforeFocus){const u=this.numberFormatter.formatToParts(1000.1).find(d=>d.type==="decimal").value;for(const d of r)!(d===u)&&!this.isIntentDecimal&&(t=t.replaceAll(new RegExp(d,"g"),""));let p=!1;const a=[...t];for(let d=a.length-1;d>=0;d--){const g=a[d];this.decimalsChars.has(g)&&(p?a[d]="":(a[d]=u,p=!0))}t=a.join("")}return this.numberParser.parse(t)}get _step(){var e;return this.step!==void 0?this.step:((e=this.formatOptions)==null?void 0:e.style)==="percent"?.01:1}handlePointerdown(e){if(e.button!==0){e.preventDefault();return}this.managedInput=!0,this.buttons.setPointerCapture(e.pointerId);const t=this.buttons.children[0].getBoundingClientRect(),o=this.buttons.children[1].getBoundingClientRect();this.findChange=r=>{r.clientX>=t.x&&r.clientY>=t.y&&r.clientX<=t.x+t.width&&r.clientY<=t.y+t.height?this.change=i=>this.increment(i.shiftKey?this.stepModifier:1):r.clientX>=o.x&&r.clientY>=o.y&&r.clientX<=o.x+o.width&&r.clientY<=o.y+o.height&&(this.change=i=>this.decrement(i.shiftKey?this.stepModifier:1))},this.findChange(e),this.startChange(e)}startChange(e){this.changeCount=0,this.doChange(e),this.safty=setTimeout(()=>{this.doNextChange(e)},400)}doChange(e){this.change(e)}handlePointermove(e){this.findChange(e)}handlePointerup(e){this.buttons.releasePointerCapture(e.pointerId),cancelAnimationFrame(this.nextChange),clearTimeout(this.safty),this.managedInput=!1,this.setValue()}doNextChange(e){return this.changeCount+=1,this.changeCount%_===0&&this.doChange(e),requestAnimationFrame(()=>{this.nextChange=this.doNextChange(e)})}stepBy(e){if(this.disabled||this.readonly)return;const t=this.min===void 0?0:this.min;let o=this.value;o+=e*this._step,Number.isNaN(this.value)&&(o=t),o=this.valueWithLimits(o),this.requestUpdate(),this._value=this.validateInput(o),this.inputElement.value=this.numberFormatter.format(o),this.inputElement.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),this.indeterminate=!1,this.focus()}increment(e=1){this.stepBy(1*e)}decrement(e=1){this.stepBy(-1*e)}handleKeydown(e){if(!this.isComposing)switch(e.code){case"ArrowUp":{e.preventDefault(),this.increment(e.shiftKey?this.stepModifier:1),this.setValue();break}case"ArrowDown":{e.preventDefault(),this.decrement(e.shiftKey?this.stepModifier:1),this.setValue();break}}}onScroll(e){e.preventDefault(),this.managedInput=!0;const t=e.shiftKey?e.deltaX/Math.abs(e.deltaX):e.deltaY/Math.abs(e.deltaY);t!==0&&!Number.isNaN(t)&&(this.stepBy(t*(e.shiftKey?this.stepModifier:1)),clearTimeout(this.queuedChangeEvent),this.queuedChangeEvent=setTimeout(()=>{this.setValue()},N)),this.managedInput=!1}onFocus(){super.onFocus(),this._trackingValue=this.inputValue,this.keyboardFocused=!this.readonly&&!0,this.addEventListener("wheel",this.onScroll,{passive:!1}),this.valueBeforeFocus=this.inputElement.value}onBlur(e){super.onBlur(e),this.keyboardFocused=!this.readonly&&!1,this.removeEventListener("wheel",this.onScroll),this.isIntentDecimal=!1}handleFocusin(){this.focused=!this.readonly&&!0,this.keyboardFocused=!this.readonly&&!0}handleFocusout(){this.focused=!this.readonly&&!1,this.keyboardFocused=!this.readonly&&!1}handleChange(){const e=this.convertValueToNumber(this.inputValue);if(this.wasIndeterminate&&(this.wasIndeterminate=!1,this.indeterminateValue=void 0,Number.isNaN(e))){this.indeterminate=!0;return}this.setValue(e),this.inputElement.value=this.formattedValue}handleCompositionStart(){this.isComposing=!0}handleCompositionEnd(){this.isComposing=!1,requestAnimationFrame(()=>{this.inputElement.dispatchEvent(new Event("input",{composed:!0,bubbles:!0}))})}handleInputElementPointerdown(){this.hasRecentlyReceivedPointerDown=!0,this.updateComplete.then(()=>{requestAnimationFrame(()=>{this.hasRecentlyReceivedPointerDown=!1})})}handleInput(e){if(this.isComposing){if(e.data){const a=this.convertValueToNumber(e.data);Number.isNaN(a)&&(this.inputElement.value=this.indeterminate?f:this._trackingValue,this.isComposing=!1)}e.stopPropagation();return}this.indeterminate&&(this.wasIndeterminate=!0,this.indeterminateValue=this.value,this.inputElement.value=this.inputElement.value.replace(f,"")),e.data&&this.decimalsChars.has(e.data)&&(this.isIntentDecimal=!0);const{value:t,selectionStart:o}=this.inputElement,r=[...t].map(a=>w[a]||a).join("");if(this.numberParser.isValidPartialNumber(r)){this.lastCommitedValue=this.lastCommitedValue??this.value;const a=this.convertValueToNumber(r);!r&&this.indeterminateValue?(this.indeterminate=!0,this._value=this.indeterminateValue):(this.indeterminate=!1,this._value=this.validateInput(a)),this._trackingValue=r,this.inputElement.value=r,this.inputElement.setSelectionRange(o,o);return}this.inputElement.value=this.indeterminate?f:this._trackingValue,e.stopPropagation();const i=r.length,u=this._trackingValue.length,p=(o||i)-(i-u);this.inputElement.setSelectionRange(p,p)}valueWithLimits(e){let t=e;return this.min!==void 0&&(t=Math.max(this.min,t)),this.max!==void 0&&(t=Math.min(this.max,t)),t}validateInput(e){e=this.valueWithLimits(e);const t=e<0?-1:1;if(e*=t,this.step){const o=this.min===void 0?0:this.min,r=Number.parseFloat(this.valueFormatter.format((e-o)%this.step));if(r===0||(Math.round(r/this.step)===1?e+=this.step-r:e-=r),this.max!==void 0)for(;e>this.max;)e-=this.step;e=Number.parseFloat(this.valueFormatter.format(e))}return e*=t,e}get displayValue(){const e=this.focused?"":f;return this.indeterminate?e:this.formattedValue}clearNumberFormatterCache(){this._numberFormatter=void 0,this._numberParser=void 0}get numberFormatter(){if(!this._numberFormatter||!this._numberFormatterFocused){const{style:e,unit:t,unitDisplay:o,...r}=this.formatOptions;e!=="unit"&&(r.style=e),this._numberFormatterFocused=new h.NumberFormatter(this.languageResolver.language,r);try{this._numberFormatter=new h.NumberFormatter(this.languageResolver.language,this.formatOptions),this._forcedUnit="",this._numberFormatter.format(1)}catch{e==="unit"&&(this._forcedUnit=t),this._numberFormatter=this._numberFormatterFocused}}return this.focused?this._numberFormatterFocused:this._numberFormatter}clearValueFormatterCache(){this._valueFormatter=void 0}get valueFormatter(){if(!this._valueFormatter){const e=this.step?this.step===Math.floor(this.step)?0:this.step.toString().split(".")[1].length:0;this._valueFormatter=new h.NumberFormatter("en",{useGrouping:!1,maximumFractionDigits:e})}return this._valueFormatter}get numberParser(){if(!this._numberParser||!this._numberParserFocused){const{style:e,unit:t,unitDisplay:o,...r}=this.formatOptions;e!=="unit"&&(r.style=e),this._numberParserFocused=new h.NumberParser(this.languageResolver.language,r);try{this._numberParser=new h.NumberParser(this.languageResolver.language,this.formatOptions),this._forcedUnit="",this._numberParser.parse("0")}catch{e==="unit"&&(this._forcedUnit=t),this._numberParser=this._numberParserFocused}}return this.focused?this._numberParserFocused:this._numberParser}renderField(){return this.autocomplete="off",b.html`
19
19
  ${super.renderField()}
20
20
  ${this.hideStepper?b.nothing:b.html`
21
21
  <span
@@ -20,10 +20,10 @@ import { luzmoIcon as v, luzmoAngleUp as y, luzmoAngleDown as k } from "@luzmo/i
20
20
  import { unsafeCSS as C, nothing as F, html as z } from "lit";
21
21
  import { query as _, property as n } from "lit/decorators.js";
22
22
  import { c as g, a as N, j as V } from "../platform-CqwNrovd.js";
23
- import { L as P, l as S } from "../language-resolution-B-wjV5bb.js";
23
+ import { L as P, l as S } from "../language-resolution-pYd-sAaw.js";
24
24
  import { s as q } from "../streaming-listener-BlWm-XZU.js";
25
25
  import "../infield-button/index.js";
26
- import { a as E } from "../text-field-BHaLKkf1.js";
26
+ import { a as E } from "../text-field-Ckbe58fH.js";
27
27
  const w = () => {
28
28
  if (typeof document < "u" && !document.querySelector("style[data-luzmo-vars]")) {
29
29
  const p = document.createElement("style");
@@ -15,7 +15,7 @@
15
15
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
16
  * SOFTWARE.
17
17
  * */
18
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E=require("@lit-labs/observers/mutation-controller.js"),a=require("lit"),c=require("lit/decorators.js"),_=require("../focusable-CbVKgGfS.cjs"),$=require("../like-anchor-B2EqJPdw.cjs"),L=require("../observe-slot-presence-CNltc0C0.cjs"),U=require("../observe-slot-text-CBMHpuIK.cjs"),j=require("../random-id-CqvckpWe.cjs"),x=require("@luzmo/icons");require("@lit-labs/virtualizer");const q=require("lit/directives/repeat.js"),O=require("../base-5nDSSNeT.cjs"),A=require("../sized-mixin-DcvJLFeo.cjs");require("../progress-circle/index.cjs");const D=require("../divider.module-DDvBo9zo.cjs"),P='#icon{grid-area:iconArea;align-self:start;height:var(--luzmo-option-icon-container-height, var(--option-icon-container-height));display:flex;align-items:center;justify-content:center;color:var(--highcontrast-option-color-default, var(--luzmo-option-label-icon-color-default, var(--option-label-icon-color-default)))}::slotted([slot=icon]){fill:var(--highcontrast-option-color-default, var(--luzmo-option-label-icon-color-default, var(--option-label-icon-color-default)));margin-inline-end:var(--luzmo-option-label-text-to-visual, var(--option-label-text-to-visual));block-size:var(--luzmo-option-icon-size, var(--option-icon-height));inline-size:var(--luzmo-option-icon-width, var(--option-icon-width));font-size:var(--luzmo-option-icon-size, var(--option-icon-height));text-align:center;--luzmo-icon-vertical-align: 0;display:flex;align-items:center;justify-content:center}:host{cursor:pointer;box-sizing:border-box;background-color:var(--highcontrast-option-background-color-default, var(--luzmo-option-background-color-default, var(--option-background-color-default)));line-height:var(--luzmo-option-label-line-height, var(--option-label-line-height));min-block-size:var(--luzmo-option-min-height, var(--option-min-height));padding-block-start:var(--luzmo-option-top-edge-to-text, var(--option-top-edge-to-text));padding-block-end:var(--luzmo-option-bottom-edge-to-text, var(--option-bottom-edge-to-text));padding-inline:var(--luzmo-option-label-inline-edge-to-content, var(--option-label-inline-edge-to-content));grid-template:". . headingIconArea sectionHeadingArea . ." "selectedArea checkArea iconArea labelArea valueArea actionsArea" 1fr ". . . descriptionArea . ." ". . . . . ."/auto auto auto 1fr auto auto;justify-content:start;margin:0;-webkit-text-decoration:none;text-decoration:none;display:grid;outline:none;align-items:center;position:relative;flex-shrink:0}:host:focus-visible{outline:none}#label{grid-area:submenuItemLabelArea}.checkmark,.checkbox{opacity:1;grid-area:checkArea;align-self:start;display:block}.checkmark{font-size:var(--luzmo-option-checkmark-size, var(--option-checkmark-size));fill:var(--highcontrast-options-checkmark-icon-color-default, var(--luzmo-options-checkmark-icon-color-default, var(--options-checkmark-icon-color-default)));color:var(--highcontrast-options-checkmark-icon-color-default, var(--luzmo-options-checkmark-icon-color-default, var(--options-checkmark-icon-color-default)));margin-block-start:calc(var(--luzmo-option-top-to-checkmark, var(--option-top-to-checkmark)) - var(--luzmo-option-top-edge-to-text, var(--option-top-edge-to-text)));margin-inline-end:var(--luzmo-option-text-to-control, var(--option-label-text-to-control))}.checkbox{font-size:var(--luzmo-option-checkbox-size, var(--option-checkbox-size));fill:var(--highcontrast-options-checkbox-icon-color-default, var(--luzmo-options-checkbox-icon-color-default, var(--options-checkbox-icon-color-default)));color:var(--highcontrast-options-checkbox-icon-color-default, var(--luzmo-options-checkbox-icon-color-default, var(--options-checkbox-icon-color-default)));margin-block-start:calc(var(--luzmo-option-top-to-checkbox, var(--option-top-to-checkbox)) - var(--luzmo-option-top-edge-to-text, var(--option-top-edge-to-text)));margin-inline-end:var(--luzmo-option-text-to-control, var(--option-label-text-to-control))}::slotted([slot=value]){grid-area:submenuItemValueArea}:host([focused]){background-color:var(--highcontrast-option-background-color-focus, var(--luzmo-option-background-color-key-focus, var(--option-background-color-key-focus)));outline:none}:host([focused])>#label,:host(:focus)>#label{color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-content-color-focus, var(--option-label-content-color-focus)))}:host([focused])>[name=description]::slotted(*),:host(:focus)>[name=description]::slotted(*){color:var(--highcontrast-option-color-focus, var(--luzmo-option-description-color-focus, var(--option-description-color-focus)))}:host([focused])>::slotted([slot=value]),:host(:focus)>::slotted([slot=value]){color:var(--highcontrast-option-color-focus, var(--luzmo-option-value-color-focus, var(--option-value-color-focus)))}:host([focused])>.icon:not(.checkmark,.checkbox),:host(:focus)>.icon:not(.checkmark,.checkbox){fill:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-focus, var(--option-label-icon-color-focus)));color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-focus, var(--option-label-icon-color-focus)))}:host([focused])>.checkmark,:host(:focus)>.checkmark{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-focus, var(--options-checkmark-icon-color-focus)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-focus, var(--options-checkmark-icon-color-focus)))}:host([focused])>.checkbox,:host(:focus)>.checkbox{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-focus, var(--options-checkbox-icon-color-focus)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-focus, var(--options-checkbox-icon-color-focus)))}:host:dir(rtl),:host([dir=rtl]){--option-focus-indicator-direction-scalar: -1}:host(:is(:active,[active])){background-color:var(--highcontrast-option-background-color-focus, var(--luzmo-option-background-color-down, var(--option-background-color-down)))}:host(:is(:active,[active]))>#label{color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-content-color-down, var(--option-label-content-color-down)))}:host(:is(:active,[active]))>[name=description]::slotted(*){color:var(--highcontrast-option-color-focus, var(--luzmo-option-description-color-down, var(--option-description-color-down)))}:host(:is(:active,[active]))>::slotted([slot=value]){color:var(--highcontrast-option-color-focus, var(--luzmo-option-value-color-down, var(--option-value-color-down)))}:host(:is(:active,[active]))>.icon:not(.checkmark,.checkbox){fill:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-down, var(--option-label-icon-color-down)));color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-down, var(--option-label-icon-color-down)))}:host(:is(:active,[active]))>.checkmark{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-down, var(--options-checkmark-icon-color-down)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-down, var(--options-checkmark-icon-color-down)))}:host(:is(:active,[active]))>.checkbox{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-down, var(--options-checkbox-icon-color-down)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-down, var(--options-checkbox-icon-color-down)))}:host([disabled]),:host([aria-disabled=true]){background-color:initial}:host([disabled]) #label,:host([disabled]) ::slotted([slot=value]),:host([aria-disabled=true]) #label,:host([aria-disabled=true]) ::slotted([slot=value]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-content-color-disabled, var(--option-label-content-color-disabled)))}:host([disabled]) [name=description]::slotted(*),:host([aria-disabled=true]) [name=description]::slotted(*){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-description-color-disabled, var(--option-description-color-disabled)))}:host([disabled]) ::slotted([slot=icon]),:host([aria-disabled=true]) ::slotted([slot=icon]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-icon-color-disabled, var(--option-label-icon-color-disabled)));fill:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-icon-color-disabled, var(--option-label-icon-color-disabled)))}:host([focused]){box-shadow:inset calc(var(--luzmo-option-focus-indicator-width, var(--option-focus-indicator-width)) * 1) 0 0 0 var(--highcontrast-option-focus-indicator-color, var(--luzmo-option-focus-indicator-color, var(--option-focus-indicator-color)));box-shadow:inset calc(var(--luzmo-option-focus-indicator-width, var(--option-focus-indicator-width)) * var(--option-focus-indicator-direction-scalar, 1)) 0 0 0 var(--highcontrast-option-focus-indicator-color, var(--luzmo-option-focus-indicator-color, var(--option-focus-indicator-color)))}#label{font-size:var(--luzmo-option-label-font-size, var(--option-label-font-size));color:var(--highcontrast-option-color-default, var(--luzmo-option-label-content-color-default, var(--option-label-content-color-default)));-webkit-hyphens:auto;hyphens:auto;overflow-wrap:break-word;grid-area:labelArea}:host([variant=highlight][selected]){background-color:var(--luzmo-option-highlight-selected-label-background-color, var(--option-highlight-selected-label-background-color))}:host([variant=highlight][selected]) #label{color:var(--luzmo-option-highlight-selected-label-content-color, var(--option-highlight-selected-label-content-color))}:host([variant=highlight][selected]):hover #label{color:var(--luzmo-option-highlight-selected-label-content-color-hover, var(--option-highlight-selected-label-content-color-hover))}:host([variant=highlight][selected]):active #label{color:var(--luzmo-option-highlight-selected-label-content-color-down, var(--option-highlight-selected-label-content-color-down))}:host([variant=highlight][selected]):focus #label{color:var(--luzmo-option-highlight-selected-label-content-color-focus, var(--option-highlight-selected-label-content-color-focus))}:host([variant=highlight][selected]) ::slotted([slot=icon]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-highlight-selected-label-content-color, var(--option-highlight-selected-label-content-color)));fill:var(--highcontrast-option-color-disabled, var(--luzmo-option-highlight-selected-label-content-color, var(--option-highlight-selected-label-content-color)))}::slotted([slot=value]){color:var(--highcontrast-option-color-default, var(--luzmo-option-value-color-default, var(--option-value-color-default)));font-size:var(--luzmo-option-label-font-size, var(--option-label-font-size));grid-area:valueArea;justify-self:end}[name=description]::slotted(*){color:var(--highcontrast-option-color-default, var(--luzmo-option-description-color-default, var(--option-description-color-default)));font-size:var(--luzmo-option-description-font-size, var(--option-description-font-size));-webkit-hyphens:auto;hyphens:auto;overflow-wrap:break-word;line-height:var(--luzmo-option-description-line-height, var(--option-description-line-height));grid-area:descriptionArea;margin-block-start:var(--luzmo-option-label-to-description-spacing, var(--option-label-to-description-spacing))}:host([no-wrap]) #label{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}@media (hover: hover){:host(:hover){background-color:var(--highcontrast-option-background-color-focus, var(--luzmo-option-background-color-hover, var(--option-background-color-hover)))}:host(:hover)>#label{color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-content-color-hover, var(--option-label-content-color-hover)))}:host([variant=highlight][selected]:hover)>#label{color:var(--luzmo-option-highlight-selected-label-content-color-hover, var(--option-highlight-selected-label-content-color-hover))}:host(:hover)>[name=description]::slotted(*){color:var(--highcontrast-option-color-focus, var(--luzmo-option-description-color-hover, var(--option-description-color-hover)))}:host(:hover)>::slotted([slot=value]){color:var(--highcontrast-option-color-focus, var(--luzmo-option-value-color-hover, var(--option-value-color-hover)))}:host(:hover)>.icon:not(.checkmark,.checkbox){fill:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-hover, var(--option-label-icon-color-hover)));color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-hover, var(--option-label-icon-color-hover)))}:host([variant=highlight][selected]:hover)>.icon:not(.checkmark,.checkbox){fill:var(--luzmo-option-highlight-selected-label-icon-color-hover, var(--option-highlight-selected-label-icon-color-hover))}:host(:hover)>.checkmark{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-hover, var(--options-checkmark-icon-color-hover)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-hover, var(--options-checkmark-icon-color-hover)))}:host(:hover)>.checkbox{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-hover, var(--options-checkbox-icon-color-hover)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-hover, var(--options-checkbox-icon-color-hover)))}:host([disabled]:hover),:host([aria-disabled=true]:hover){cursor:default;background-color:initial}:host([disabled]:hover) #label,:host([disabled]:hover) ::slotted([slot=value]),:host([aria-disabled=true]:hover) #label,:host([aria-disabled=true]:hover) ::slotted([slot=value]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-content-color-disabled, var(--option-label-content-color-disabled)))}:host([disabled]:hover) [name=description]::slotted(*),:host([aria-disabled=true]:hover) [name=description]::slotted(*){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-description-color-disabled, var(--option-description-color-disabled)))}:host([disabled]:hover) ::slotted([slot=icon]),:host([aria-disabled=true]:hover) ::slotted([slot=icon]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-icon-color-disabled, var(--option-label-icon-color-disabled)));fill:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-icon-color-disabled, var(--option-label-icon-color-disabled)))}}:host([emphasized]){--options-checkmark-icon-color-default: var(--luzmo-primary);--options-checkmark-icon-color-hover: var(--luzmo-primary-hover);--options-checkmark-icon-color-down: var(--luzmo-primary-down);--options-checkmark-icon-color-focus: var(--luzmo-primary-focus);--options-checkbox-icon-color-default: var(--luzmo-primary);--options-checkbox-icon-color-hover: var(--luzmo-primary-hover);--options-checkbox-icon-color-down: var(--luzmo-primary-down);--options-checkbox-icon-color-focus: var(--luzmo-primary-focus)}:host{text-align:initial;font-family:var(--luzmo-option-font-family, var(--luzmo-font-family))}:host([hidden]){display:none}:host([disabled]){pointer-events:none}:host([disabled]) [name=value]::slotted(*){color:var(--luzmo-option-label-icon-color-disabled, var(--luzmo-disabled-color))}#button{position:absolute;top:0;right:0;bottom:0;left:0}.icon-container>svg{vertical-align:top}:host([dir=ltr]) [icon-only]::slotted(:last-of-type){margin-right:auto}:host([dir=rtl]) [icon-only]::slotted(:last-of-type){margin-left:auto}@media (forced-colors: active){:host{forced-color-adjust:none}}:host([no-wrap]) #label{display:block}';var F=Object.defineProperty,T=Object.getOwnPropertyDescriptor,m=(s,o,t,i)=>{for(var n=i>1?void 0:i?T(o,t):o,l=s.length-1,r;l>=0;l--)(r=s[l])&&(n=(i?r(o,t,n):r(n))||n);return i&&n&&F(o,t,n),n};const B=s=>a.html`
18
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E=require("@lit-labs/observers/mutation-controller.js"),a=require("lit"),c=require("lit/decorators.js"),_=require("../focusable-agUxU61W.cjs"),$=require("../like-anchor-B2EqJPdw.cjs"),L=require("../observe-slot-presence-CNltc0C0.cjs"),U=require("../observe-slot-text-CBMHpuIK.cjs"),j=require("../random-id-CqvckpWe.cjs"),x=require("@luzmo/icons");require("@lit-labs/virtualizer");const q=require("lit/directives/repeat.js"),O=require("../base-DxRGeCrb.cjs"),A=require("../sized-mixin-DcvJLFeo.cjs");require("../progress-circle/index.cjs");const D=require("../divider.module-DDvBo9zo.cjs"),P='#icon{grid-area:iconArea;align-self:start;height:var(--luzmo-option-icon-container-height, var(--option-icon-container-height));display:flex;align-items:center;justify-content:center;color:var(--highcontrast-option-color-default, var(--luzmo-option-label-icon-color-default, var(--option-label-icon-color-default)))}::slotted([slot=icon]){fill:var(--highcontrast-option-color-default, var(--luzmo-option-label-icon-color-default, var(--option-label-icon-color-default)));margin-inline-end:var(--luzmo-option-label-text-to-visual, var(--option-label-text-to-visual));block-size:var(--luzmo-option-icon-size, var(--option-icon-height));inline-size:var(--luzmo-option-icon-width, var(--option-icon-width));font-size:var(--luzmo-option-icon-size, var(--option-icon-height));text-align:center;--luzmo-icon-vertical-align: 0;display:flex;align-items:center;justify-content:center}:host{cursor:pointer;box-sizing:border-box;background-color:var(--highcontrast-option-background-color-default, var(--luzmo-option-background-color-default, var(--option-background-color-default)));line-height:var(--luzmo-option-label-line-height, var(--option-label-line-height));min-block-size:var(--luzmo-option-min-height, var(--option-min-height));padding-block-start:var(--luzmo-option-top-edge-to-text, var(--option-top-edge-to-text));padding-block-end:var(--luzmo-option-bottom-edge-to-text, var(--option-bottom-edge-to-text));padding-inline:var(--luzmo-option-label-inline-edge-to-content, var(--option-label-inline-edge-to-content));grid-template:". . headingIconArea sectionHeadingArea . ." "selectedArea checkArea iconArea labelArea valueArea actionsArea" 1fr ". . . descriptionArea . ." ". . . . . ."/auto auto auto 1fr auto auto;justify-content:start;margin:0;-webkit-text-decoration:none;text-decoration:none;display:grid;outline:none;align-items:center;position:relative;flex-shrink:0}:host:focus-visible{outline:none}#label{grid-area:submenuItemLabelArea}.checkmark,.checkbox{opacity:1;grid-area:checkArea;align-self:start;display:block}.checkmark{font-size:var(--luzmo-option-checkmark-size, var(--option-checkmark-size));fill:var(--highcontrast-options-checkmark-icon-color-default, var(--luzmo-options-checkmark-icon-color-default, var(--options-checkmark-icon-color-default)));color:var(--highcontrast-options-checkmark-icon-color-default, var(--luzmo-options-checkmark-icon-color-default, var(--options-checkmark-icon-color-default)));margin-block-start:calc(var(--luzmo-option-top-to-checkmark, var(--option-top-to-checkmark)) - var(--luzmo-option-top-edge-to-text, var(--option-top-edge-to-text)));margin-inline-end:var(--luzmo-option-text-to-control, var(--option-label-text-to-control))}.checkbox{font-size:var(--luzmo-option-checkbox-size, var(--option-checkbox-size));fill:var(--highcontrast-options-checkbox-icon-color-default, var(--luzmo-options-checkbox-icon-color-default, var(--options-checkbox-icon-color-default)));color:var(--highcontrast-options-checkbox-icon-color-default, var(--luzmo-options-checkbox-icon-color-default, var(--options-checkbox-icon-color-default)));margin-block-start:calc(var(--luzmo-option-top-to-checkbox, var(--option-top-to-checkbox)) - var(--luzmo-option-top-edge-to-text, var(--option-top-edge-to-text)));margin-inline-end:var(--luzmo-option-text-to-control, var(--option-label-text-to-control))}::slotted([slot=value]){grid-area:submenuItemValueArea}:host([focused]){background-color:var(--highcontrast-option-background-color-focus, var(--luzmo-option-background-color-key-focus, var(--option-background-color-key-focus)));outline:none}:host([focused])>#label,:host(:focus)>#label{color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-content-color-focus, var(--option-label-content-color-focus)))}:host([focused])>[name=description]::slotted(*),:host(:focus)>[name=description]::slotted(*){color:var(--highcontrast-option-color-focus, var(--luzmo-option-description-color-focus, var(--option-description-color-focus)))}:host([focused])>::slotted([slot=value]),:host(:focus)>::slotted([slot=value]){color:var(--highcontrast-option-color-focus, var(--luzmo-option-value-color-focus, var(--option-value-color-focus)))}:host([focused])>.icon:not(.checkmark,.checkbox),:host(:focus)>.icon:not(.checkmark,.checkbox){fill:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-focus, var(--option-label-icon-color-focus)));color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-focus, var(--option-label-icon-color-focus)))}:host([focused])>.checkmark,:host(:focus)>.checkmark{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-focus, var(--options-checkmark-icon-color-focus)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-focus, var(--options-checkmark-icon-color-focus)))}:host([focused])>.checkbox,:host(:focus)>.checkbox{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-focus, var(--options-checkbox-icon-color-focus)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-focus, var(--options-checkbox-icon-color-focus)))}:host:dir(rtl),:host([dir=rtl]){--option-focus-indicator-direction-scalar: -1}:host(:is(:active,[active])){background-color:var(--highcontrast-option-background-color-focus, var(--luzmo-option-background-color-down, var(--option-background-color-down)))}:host(:is(:active,[active]))>#label{color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-content-color-down, var(--option-label-content-color-down)))}:host(:is(:active,[active]))>[name=description]::slotted(*){color:var(--highcontrast-option-color-focus, var(--luzmo-option-description-color-down, var(--option-description-color-down)))}:host(:is(:active,[active]))>::slotted([slot=value]){color:var(--highcontrast-option-color-focus, var(--luzmo-option-value-color-down, var(--option-value-color-down)))}:host(:is(:active,[active]))>.icon:not(.checkmark,.checkbox){fill:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-down, var(--option-label-icon-color-down)));color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-down, var(--option-label-icon-color-down)))}:host(:is(:active,[active]))>.checkmark{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-down, var(--options-checkmark-icon-color-down)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-down, var(--options-checkmark-icon-color-down)))}:host(:is(:active,[active]))>.checkbox{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-down, var(--options-checkbox-icon-color-down)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-down, var(--options-checkbox-icon-color-down)))}:host([disabled]),:host([aria-disabled=true]){background-color:initial}:host([disabled]) #label,:host([disabled]) ::slotted([slot=value]),:host([aria-disabled=true]) #label,:host([aria-disabled=true]) ::slotted([slot=value]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-content-color-disabled, var(--option-label-content-color-disabled)))}:host([disabled]) [name=description]::slotted(*),:host([aria-disabled=true]) [name=description]::slotted(*){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-description-color-disabled, var(--option-description-color-disabled)))}:host([disabled]) ::slotted([slot=icon]),:host([aria-disabled=true]) ::slotted([slot=icon]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-icon-color-disabled, var(--option-label-icon-color-disabled)));fill:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-icon-color-disabled, var(--option-label-icon-color-disabled)))}:host([focused]){box-shadow:inset calc(var(--luzmo-option-focus-indicator-width, var(--option-focus-indicator-width)) * 1) 0 0 0 var(--highcontrast-option-focus-indicator-color, var(--luzmo-option-focus-indicator-color, var(--option-focus-indicator-color)));box-shadow:inset calc(var(--luzmo-option-focus-indicator-width, var(--option-focus-indicator-width)) * var(--option-focus-indicator-direction-scalar, 1)) 0 0 0 var(--highcontrast-option-focus-indicator-color, var(--luzmo-option-focus-indicator-color, var(--option-focus-indicator-color)))}#label{font-size:var(--luzmo-option-label-font-size, var(--option-label-font-size));color:var(--highcontrast-option-color-default, var(--luzmo-option-label-content-color-default, var(--option-label-content-color-default)));-webkit-hyphens:auto;hyphens:auto;overflow-wrap:break-word;grid-area:labelArea}:host([variant=highlight][selected]){background-color:var(--luzmo-option-highlight-selected-label-background-color, var(--option-highlight-selected-label-background-color))}:host([variant=highlight][selected]) #label{color:var(--luzmo-option-highlight-selected-label-content-color, var(--option-highlight-selected-label-content-color))}:host([variant=highlight][selected]):hover #label{color:var(--luzmo-option-highlight-selected-label-content-color-hover, var(--option-highlight-selected-label-content-color-hover))}:host([variant=highlight][selected]):active #label{color:var(--luzmo-option-highlight-selected-label-content-color-down, var(--option-highlight-selected-label-content-color-down))}:host([variant=highlight][selected]):focus #label{color:var(--luzmo-option-highlight-selected-label-content-color-focus, var(--option-highlight-selected-label-content-color-focus))}:host([variant=highlight][selected]) ::slotted([slot=icon]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-highlight-selected-label-content-color, var(--option-highlight-selected-label-content-color)));fill:var(--highcontrast-option-color-disabled, var(--luzmo-option-highlight-selected-label-content-color, var(--option-highlight-selected-label-content-color)))}::slotted([slot=value]){color:var(--highcontrast-option-color-default, var(--luzmo-option-value-color-default, var(--option-value-color-default)));font-size:var(--luzmo-option-label-font-size, var(--option-label-font-size));grid-area:valueArea;justify-self:end}[name=description]::slotted(*){color:var(--highcontrast-option-color-default, var(--luzmo-option-description-color-default, var(--option-description-color-default)));font-size:var(--luzmo-option-description-font-size, var(--option-description-font-size));-webkit-hyphens:auto;hyphens:auto;overflow-wrap:break-word;line-height:var(--luzmo-option-description-line-height, var(--option-description-line-height));grid-area:descriptionArea;margin-block-start:var(--luzmo-option-label-to-description-spacing, var(--option-label-to-description-spacing))}:host([no-wrap]) #label{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}@media (hover: hover){:host(:hover){background-color:var(--highcontrast-option-background-color-focus, var(--luzmo-option-background-color-hover, var(--option-background-color-hover)))}:host(:hover)>#label{color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-content-color-hover, var(--option-label-content-color-hover)))}:host([variant=highlight][selected]:hover)>#label{color:var(--luzmo-option-highlight-selected-label-content-color-hover, var(--option-highlight-selected-label-content-color-hover))}:host(:hover)>[name=description]::slotted(*){color:var(--highcontrast-option-color-focus, var(--luzmo-option-description-color-hover, var(--option-description-color-hover)))}:host(:hover)>::slotted([slot=value]){color:var(--highcontrast-option-color-focus, var(--luzmo-option-value-color-hover, var(--option-value-color-hover)))}:host(:hover)>.icon:not(.checkmark,.checkbox){fill:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-hover, var(--option-label-icon-color-hover)));color:var(--highcontrast-option-color-focus, var(--luzmo-option-label-icon-color-hover, var(--option-label-icon-color-hover)))}:host([variant=highlight][selected]:hover)>.icon:not(.checkmark,.checkbox){fill:var(--luzmo-option-highlight-selected-label-icon-color-hover, var(--option-highlight-selected-label-icon-color-hover))}:host(:hover)>.checkmark{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-hover, var(--options-checkmark-icon-color-hover)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkmark-icon-color-hover, var(--options-checkmark-icon-color-hover)))}:host(:hover)>.checkbox{fill:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-hover, var(--options-checkbox-icon-color-hover)));color:var(--highcontrast-option-color-focus, var(--luzmo-options-checkbox-icon-color-hover, var(--options-checkbox-icon-color-hover)))}:host([disabled]:hover),:host([aria-disabled=true]:hover){cursor:default;background-color:initial}:host([disabled]:hover) #label,:host([disabled]:hover) ::slotted([slot=value]),:host([aria-disabled=true]:hover) #label,:host([aria-disabled=true]:hover) ::slotted([slot=value]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-content-color-disabled, var(--option-label-content-color-disabled)))}:host([disabled]:hover) [name=description]::slotted(*),:host([aria-disabled=true]:hover) [name=description]::slotted(*){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-description-color-disabled, var(--option-description-color-disabled)))}:host([disabled]:hover) ::slotted([slot=icon]),:host([aria-disabled=true]:hover) ::slotted([slot=icon]){color:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-icon-color-disabled, var(--option-label-icon-color-disabled)));fill:var(--highcontrast-option-color-disabled, var(--luzmo-option-label-icon-color-disabled, var(--option-label-icon-color-disabled)))}}:host([emphasized]){--options-checkmark-icon-color-default: var(--luzmo-primary);--options-checkmark-icon-color-hover: var(--luzmo-primary-hover);--options-checkmark-icon-color-down: var(--luzmo-primary-down);--options-checkmark-icon-color-focus: var(--luzmo-primary-focus);--options-checkbox-icon-color-default: var(--luzmo-primary);--options-checkbox-icon-color-hover: var(--luzmo-primary-hover);--options-checkbox-icon-color-down: var(--luzmo-primary-down);--options-checkbox-icon-color-focus: var(--luzmo-primary-focus)}:host{text-align:initial;font-family:var(--luzmo-option-font-family, var(--luzmo-font-family))}:host([hidden]){display:none}:host([disabled]){pointer-events:none}:host([disabled]) [name=value]::slotted(*){color:var(--luzmo-option-label-icon-color-disabled, var(--luzmo-disabled-color))}#button{position:absolute;top:0;right:0;bottom:0;left:0}.icon-container>svg{vertical-align:top}:host([dir=ltr]) [icon-only]::slotted(:last-of-type){margin-right:auto}:host([dir=rtl]) [icon-only]::slotted(:last-of-type){margin-left:auto}@media (forced-colors: active){:host{forced-color-adjust:none}}:host([no-wrap]) #label{display:block}';var F=Object.defineProperty,T=Object.getOwnPropertyDescriptor,m=(s,o,t,i)=>{for(var n=i>1?void 0:i?T(o,t):o,l=s.length-1,r;l>=0;l--)(r=s[l])&&(n=(i?r(o,t,n):r(n))||n);return i&&n&&F(o,t,n),n};const B=s=>a.html`
19
19
  <span class="icon-container icon checkmark ${s.join(" ")}">
20
20
  ${x.luzmoIcon(x.luzmoCheck)}
21
21
  </span>
@@ -18,7 +18,7 @@
18
18
  import { MutationController as $ } from "@lit-labs/observers/mutation-controller.js";
19
19
  import { html as u, unsafeCSS as w, nothing as y } from "lit";
20
20
  import { property as s, query as O, queryAll as U } from "lit/decorators.js";
21
- import { F as L } from "../focusable-BjvsvVam.js";
21
+ import { F as L } from "../focusable-BM1nd-dI.js";
22
22
  import { L as F } from "../like-anchor-CgqCU210.js";
23
23
  import { O as D } from "../observe-slot-presence-DFi6GE3H.js";
24
24
  import { O as j } from "../observe-slot-text-DorVpCL4.js";
@@ -26,7 +26,7 @@ import { r as P } from "../random-id-ByCz1xaq.js";
26
26
  import { luzmoIcon as A, luzmoCheckboxChecked as T, luzmoCheckbox as B, luzmoCheck as H } from "@luzmo/icons";
27
27
  import "@lit-labs/virtualizer";
28
28
  import { repeat as V } from "lit/directives/repeat.js";
29
- import { a as S } from "../base-CdYjmV_8.js";
29
+ import { a as S } from "../base-BUViEg_7.js";
30
30
  import { S as E } from "../sized-mixin-cJbo3PKR.js";
31
31
  import "../progress-circle/index.js";
32
32
  import { d as K } from "../divider.module-DoQWQEIJ.js";
@@ -15,7 +15,7 @@
15
15
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
16
  * SOFTWARE.
17
17
  * */
18
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../overlay-BhrVS5h7.cjs"),h=require("lit"),i=require("lit/decorators.js"),b=require("../base-5nDSSNeT.cjs"),d=require("lit/async-directive.js"),u=require("../slottable-request-event-BfUUt1Mh.cjs"),O=":host([disabled]) ::slotted([slot=trigger]){pointer-events:none}slot[name=longpress-describedby-descriptor]{display:none}";var S=Object.defineProperty,l=(g,e,r,t)=>{for(var n=void 0,a=g.length-1,c;a>=0;a--)(c=g[a])&&(n=c(e,r,n)||n);return n&&S(e,r,n),n};class s extends b.LuzmoElement{constructor(){super(...arguments),this.content="click hover longpress",this.offset=6,this.disabled=!1,this.receivesFocus="auto",this.clickContent=[],this.longpressContent=[],this.hoverContent=[],this.targetContent=[]}static get styles(){return[h.unsafeCSS(O)]}getAssignedElementsFromSlot(e){return e.assignedElements({flatten:!0})}handleTriggerContent(e){this.targetContent=this.getAssignedElementsFromSlot(e.target)}handleSlotContent(e){switch(e.target.name){case"click-content":{this.clickContent=this.getAssignedElementsFromSlot(e.target);break}case"longpress-content":{this.longpressContent=this.getAssignedElementsFromSlot(e.target);break}case"hover-content":{this.hoverContent=this.getAssignedElementsFromSlot(e.target);break}}}handleBeforetoggle(e){const{target:r}=e;let t;if(r===this.clickOverlayElement)t="click";else if(r===this.longpressOverlayElement)t="longpress";else if(r===this.hoverOverlayElement)t="hover";else return;e.newState==="open"?this.open=t:this.open===t&&(this.open=void 0)}update(e){var r,t,n,a,c,p;e.has("clickContent")&&(this.clickPlacement=((r=this.clickContent[0])==null?void 0:r.getAttribute("placement"))||((t=this.clickContent[0])==null?void 0:t.getAttribute("direction"))||void 0),e.has("hoverContent")&&(this.hoverPlacement=((n=this.hoverContent[0])==null?void 0:n.getAttribute("placement"))||((a=this.hoverContent[0])==null?void 0:a.getAttribute("direction"))||void 0),e.has("longpressContent")&&(this.longpressPlacement=((c=this.longpressContent[0])==null?void 0:c.getAttribute("placement"))||((p=this.longpressContent[0])==null?void 0:p.getAttribute("direction"))||void 0),super.update(e)}renderSlot(e){return h.html`
18
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../overlay-BTNKxbrJ.cjs"),h=require("lit"),i=require("lit/decorators.js"),b=require("../base-DxRGeCrb.cjs"),d=require("lit/async-directive.js"),u=require("../slottable-request-event-BfUUt1Mh.cjs"),O=":host([disabled]) ::slotted([slot=trigger]){pointer-events:none}slot[name=longpress-describedby-descriptor]{display:none}";var S=Object.defineProperty,l=(g,e,r,t)=>{for(var n=void 0,a=g.length-1,c;a>=0;a--)(c=g[a])&&(n=c(e,r,n)||n);return n&&S(e,r,n),n};class s extends b.LuzmoElement{constructor(){super(...arguments),this.content="click hover longpress",this.offset=6,this.disabled=!1,this.receivesFocus="auto",this.clickContent=[],this.longpressContent=[],this.hoverContent=[],this.targetContent=[]}static get styles(){return[h.unsafeCSS(O)]}getAssignedElementsFromSlot(e){return e.assignedElements({flatten:!0})}handleTriggerContent(e){this.targetContent=this.getAssignedElementsFromSlot(e.target)}handleSlotContent(e){switch(e.target.name){case"click-content":{this.clickContent=this.getAssignedElementsFromSlot(e.target);break}case"longpress-content":{this.longpressContent=this.getAssignedElementsFromSlot(e.target);break}case"hover-content":{this.hoverContent=this.getAssignedElementsFromSlot(e.target);break}}}handleBeforetoggle(e){const{target:r}=e;let t;if(r===this.clickOverlayElement)t="click";else if(r===this.longpressOverlayElement)t="longpress";else if(r===this.hoverOverlayElement)t="hover";else return;e.newState==="open"?this.open=t:this.open===t&&(this.open=void 0)}update(e){var r,t,n,a,c,p;e.has("clickContent")&&(this.clickPlacement=((r=this.clickContent[0])==null?void 0:r.getAttribute("placement"))||((t=this.clickContent[0])==null?void 0:t.getAttribute("direction"))||void 0),e.has("hoverContent")&&(this.hoverPlacement=((n=this.hoverContent[0])==null?void 0:n.getAttribute("placement"))||((a=this.hoverContent[0])==null?void 0:a.getAttribute("direction"))||void 0),e.has("longpressContent")&&(this.longpressPlacement=((c=this.longpressContent[0])==null?void 0:c.getAttribute("placement"))||((p=this.longpressContent[0])==null?void 0:p.getAttribute("direction"))||void 0),super.update(e)}renderSlot(e){return h.html`
19
19
  <slot name=${e} @slotchange=${this.handleSlotContent}></slot>
20
20
  `}renderClickOverlay(){var t;const e=this.renderSlot("click-content"),r=h.html`
21
21
  <luzmo-overlay
@@ -15,11 +15,11 @@
15
15
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
16
  * SOFTWARE.
17
17
  * */
18
- import { e as f, I as O, s as S, L as $ } from "../overlay-C-No3oJQ.js";
19
- import { C as V, H as j, b as M, c as J, d as K, P as Q, S as W, V as X, g as Y, l as Z, a as ee, n as te, o as oe, p as re } from "../overlay-C-No3oJQ.js";
18
+ import { e as f, I as O, s as S, L as $ } from "../overlay-CXkoVtnB.js";
19
+ import { C as V, H as j, b as M, c as J, d as K, P as Q, S as W, V as X, g as Y, l as Z, a as ee, n as te, o as oe, p as re } from "../overlay-CXkoVtnB.js";
20
20
  import { unsafeCSS as E, html as m, nothing as z, render as v } from "lit";
21
21
  import { property as c, state as g, query as h } from "lit/decorators.js";
22
- import { a as w } from "../base-CdYjmV_8.js";
22
+ import { a as w } from "../base-BUViEg_7.js";
23
23
  import { directive as b, AsyncDirective as A } from "lit/async-directive.js";
24
24
  import { r as y } from "../slottable-request-event-DggLA4Rx.js";
25
25
  import { S as se } from "../slottable-request-event-DggLA4Rx.js";
@@ -15,7 +15,7 @@
15
15
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
16
  * SOFTWARE.
17
17
  * */
18
- "use strict";const O=require("lit"),u=require("lit/decorators.js"),$=require("lit/directives/if-defined.js"),G=require("lit/directives/style-map.js"),M=require("./random-id-CqvckpWe.cjs"),Y=require("./element-resolution-BvRLGqIU.cjs"),le=require("./base-5nDSSNeT.cjs"),S=require("./focusable-selectors-BgFlyFcY.cjs"),b=require("@floating-ui/dom"),J=require("./slottable-request-event-BfUUt1Mh.cjs"),H=require("./condition-attribute-with-id-DrQYZzFS.cjs"),k=require("./platform-BJnOJJag.cjs");function he(a,e,t=[]){for(const[i,s]of e.entries()){const n=a[i],r=n.parentElement||n.getRootNode();t[i]&&t[i](s),r&&r!==n&&n.replaceWith(s),delete a[i]}return e}const ce=(a,e,{position:t,prepareCallback:i}={position:"beforeend"})=>{let{length:s}=a;if(s===0)return()=>a;let n=1,r=0;(t==="afterbegin"||t==="afterend")&&(n=-1,r=s-1);const o=new Array(s),h=new Array(s),p=typeof document<"u"?document.createComment("placeholder for reparented element"):null;do{const l=a[r];i&&(h[r]=i(l)),o[r]=p.cloneNode();const c=l.parentElement||l.getRootNode();c&&c!==l&&c.replaceChild(o[r],l),e.insertAdjacentElement(t,l),r+=n}while(--s>0);return function(){return he(o,a,h)}},pe=1e3,de=1e3;class ue{constructor(e={}){this.warmUpDelay=pe,this.coolDownDelay=de,this.isWarm=!1,this.timeout=0,Object.assign(this,e)}openTimer(e){if(this.cancelCooldownTimer(),!this.component||e!==this.component)return this.component&&(this.close(this.component),this.cancelCooldownTimer()),this.component=e,this.isWarm?Promise.resolve(!1):(this.promise=new Promise(t=>{this.resolve=t,this.timeout=typeof window<"u"?window.setTimeout(()=>{this.resolve&&(this.resolve(!1),this.isWarm=!0)},this.warmUpDelay):0}),this.promise);if(this.promise)return this.promise;throw new Error("Inconsistent state")}close(e){this.component&&this.component===e&&(this.resetCooldownTimer(),this.timeout>0&&(clearTimeout(this.timeout),this.timeout=0),this.resolve&&(this.resolve(!0),delete this.resolve),delete this.promise,delete this.component)}resetCooldownTimer(){this.isWarm&&(this.cooldownTimeout&&typeof window<"u"&&window.clearTimeout(this.cooldownTimeout),this.cooldownTimeout=typeof window<"u"?window.setTimeout(()=>{this.isWarm=!1,delete this.cooldownTimeout},this.coolDownDelay):void 0)}cancelCooldownTimer(){this.cooldownTimeout&&typeof window<"u"&&window.clearTimeout(this.cooldownTimeout),delete this.cooldownTimeout}}const D=new ue,E=()=>{},q=(a,e,t)=>{const i=new AbortController,s=new Map,n=()=>{i.abort(),t()};let r,o;const h=requestAnimationFrame(()=>{r=requestAnimationFrame(()=>{o=requestAnimationFrame(()=>{n()})})}),p=c=>{c.target===a&&(s.set(c.propertyName,s.get(c.propertyName)-1),s.get(c.propertyName)||s.delete(c.propertyName),s.size===0&&n())},l=c=>{c.target===a&&(s.has(c.propertyName)||s.set(c.propertyName,0),s.set(c.propertyName,s.get(c.propertyName)+1),cancelAnimationFrame(h),cancelAnimationFrame(r),cancelAnimationFrame(o))};a.addEventListener("transitionrun",l,{signal:i.signal}),a.addEventListener("transitionend",p,{signal:i.signal}),a.addEventListener("transitioncancel",p,{signal:i.signal}),e()};function f(){return new Promise(a=>requestAnimationFrame(()=>a()))}class C extends le.LuzmoElement{constructor(){super(...arguments),this.dispose=E,this.offset=0,this.willPreventClose=!1}applyFocus(e,t){}get delayed(){return!1}set delayed(e){}get disabled(){return!1}set disabled(e){}get elementResolver(){return this._elementResolver}set elementResolver(e){this._elementResolver=e}ensureOnDOM(e){}makeTransition(e){return null}manageDelay(e){}manageDialogOpen(){}managePopoverOpen(){}managePosition(){}get open(){return!1}set open(e){}get placementController(){return this._placementController}set placementController(e){this._placementController=e}requestSlottable(){}returnFocus(){}get state(){return"closed"}set state(e){}manuallyKeepOpen(){}static update(){const e=new CustomEvent("luzmo-update-overlays",{bubbles:!0,composed:!0,cancelable:!0});document.dispatchEvent(e)}static async open(e,t,i,s){await Promise.resolve().then(()=>N);const n=arguments.length===2,r=i||e,o=new this;let h=!1;const p=ce([r],o,{position:"beforeend",prepareCallback:v=>{const P=v.slot;return v.removeAttribute("slot"),()=>{v.slot=P}}});if(o.dispose=()=>{o.addEventListener("luzmo-closed",()=>{h||(p(),h=!0),requestAnimationFrame(()=>{o.remove()})}),o.open=!1,o.dispose=E},!n&&r&&s){const v=e,P=t,g=s;return C.applyOptions(o,{...g,delayed:g.delayed||r.hasAttribute("delayed"),trigger:g.virtualTrigger||v,type:P==="modal"?"modal":P==="hover"?"hint":"auto"}),v.after(o),await o.updateComplete,o.open=!0,o.dispose}const c=t;return o.append(r),C.applyOptions(o,{...c,delayed:c.delayed||r.hasAttribute("delayed")}),o.updateComplete.then(()=>{o.open=!0}),o}static applyOptions(e,t){e.delayed=!!t.delayed,e.receivesFocus=t.receivesFocus??"auto",e.triggerElement=t.trigger||null,e.type=t.type||"modal",e.offset=t.offset??0,e.placement=t.placement,e.willPreventClose=!!t.notImmediatelyClosable}}const W=a=>a.querySelector(S.userFocusableSelector),B=a=>a.assignedElements().find(t=>t.matches(S.userFocusableSelector));class K extends Event{constructor(){super("beforetoggle",{bubbles:!1,composed:!1}),this.currentState="open",this.newState="closed"}}class j extends Event{constructor(){super("beforetoggle",{bubbles:!1,composed:!1}),this.currentState="closed",this.newState="open"}}class y extends Event{constructor(e,t,{publish:i,interaction:s,reason:n}){super(e,{bubbles:i,composed:i}),this.overlay=t,this.detail={interaction:s,reason:n}}}class x{constructor(e,t){this.x=0,this.y=0,this.x=e,this.y=t}updateBoundingClientRect(e,t){this.x=e,this.y=t,C.update()}getBoundingClientRect(){return{width:0,height:0,top:this.y,right:this.x,y:this.y,x:this.x,bottom:this.y,left:this.x,toJSON(){}}}}function me(a){class e extends a{async manageDialogOpen(){const i=this.open;if(await f(),await this.managePosition(),this.open!==i)return;const s=await this.dialogMakeTransition(i);this.open===i&&await this.dialogApplyFocus(i,s)}dialogMakeTransition(i){let s=null;const n=(o,h)=>()=>{if(o.open=i,!i){const l=()=>{o.removeEventListener("close",l)};o.addEventListener("close",l)}if(h>0)return;const p=i?j:K;this.dispatchEvent(new p),i&&(o.matches(S.userFocusableSelector)&&(s=o),s=s||W(o),s||o.querySelectorAll("slot").forEach(c=>{s||(s=B(c))}),!(!this.isConnected||this.dialogEl.open)&&this.dialogEl.showModal())},r=(o,h)=>()=>{if(this.open!==i)return;const p=i?"luzmo-opened":"luzmo-closed";if(h>0){o.dispatchEvent(new y(p,this,{interaction:this.type,publish:!1}));return}if(!this.isConnected||i!==this.open)return;const l=async()=>{const c=this.triggerElement instanceof x;this.dispatchEvent(new y(p,this,{interaction:this.type,publish:c})),o.dispatchEvent(new y(p,this,{interaction:this.type,publish:!1})),this.triggerElement&&!c&&this.triggerElement.dispatchEvent(new y(p,this,{interaction:this.type,publish:!0})),this.state=i?"opened":"closed",this.returnFocus(),await f(),await f(),i===this.open&&i===!1&&this.requestSlottable()};!i&&this.dialogEl.open?(this.dialogEl.addEventListener("close",()=>{l()},{once:!0}),this.dialogEl.close()):l()};return this.elements.forEach((o,h)=>{q(o,n(o,h),r(o,h))}),s}dialogApplyFocus(i,s){this.applyFocus(i,s)}}return e}function ge(a){class e extends a{async managePopoverOpen(){await this.managePosition()}async manageDelay(i){if(i===!1||i!==this.open){D.close(this);return}this.delayed&&await D.openTimer(this)&&(this.open=!i)}ensureOnDOM(i){document.body.offsetHeight}makeTransition(i){if(this.open!==i)return null;let s=null;const n=(o,h)=>()=>{if(i!==this.open)return;if(o.open=i,h===0){const l=i?j:K;this.dispatchEvent(new l)}if(i!==!0||(o.matches(S.userFocusableSelector)&&(s=o),s=s||W(o),s))return;o.querySelectorAll("slot").forEach(l=>{s||(s=B(l))})},r=(o,h)=>async()=>{if(this.open!==i)return;const p=i?"luzmo-opened":"luzmo-closed";if(o.dispatchEvent(new y(p,this,{interaction:this.type})),h>0)return;const l=this.triggerElement instanceof x;this.dispatchEvent(new y(p,this,{interaction:this.type,publish:l})),this.triggerElement&&!l&&this.triggerElement.dispatchEvent(new y(p,this,{interaction:this.type,publish:!0})),this.state=i?"opened":"closed",this.returnFocus(),await f(),await f(),i===this.open&&i===!1&&this.requestSlottable()};return this.elements.forEach((o,h)=>{q(o,n(o,h),r(o,h))}),s}}return e}const fe=typeof CSS<"u"&&CSS.supports("(overlay: auto)");function Q(a){let e=!1;try{e=a.matches(":popover-open")}catch{}let t=!1;try{t=a.matches(":open")}catch{}return e||t}function ve(a){class e extends a{async manageDelay(i){if(i===!1||i!==this.open){D.close(this);return}this.delayed&&await D.openTimer(this)&&(this.open=!i)}shouldHidePopover(i){if(i&&this.open!==i)return;const s=async({newState:n}={})=>{n!=="open"&&await this.placementController.resetOverlayPosition()};if(!Q(this.dialogEl)){s();return}this.dialogEl.addEventListener("toggle",s,{once:!0})}shouldShowPopover(i){let s=!1;try{s=this.dialogEl.matches(":popover-open")}catch{}let n=!1;try{n=this.dialogEl.matches(":open")}catch{}i&&this.open===i&&!s&&!n&&this.isConnected&&(this.dialogEl.showPopover(),this.managePosition())}async ensureOnDOM(i){fe||await this.shouldHidePopover(i),this.shouldShowPopover(i),await f()}makeTransition(i){if(this.open!==i)return null;let s=null;const n=(o,h)=>()=>{if(o.open=i,h===0){const l=i?j:K;this.dispatchEvent(new l)}if(!i||(o.matches(S.userFocusableSelector)&&(s=o),s=s||W(o),s))return;o.querySelectorAll("slot").forEach(l=>{s||(s=B(l))})},r=(o,h)=>()=>{if(this.open!==i)return;const p=i?"luzmo-opened":"luzmo-closed";if(h>0){o.dispatchEvent(new y(p,this,{interaction:this.type,publish:!1}));return}const l=async()=>{if(this.open!==i)return;await f();const v=this.triggerElement instanceof x;this.dispatchEvent(new y(p,this,{interaction:this.type,publish:v})),o.dispatchEvent(new y(p,this,{interaction:this.type,publish:!1})),this.triggerElement&&!v&&this.triggerElement.dispatchEvent(new y(p,this,{interaction:this.type,publish:!0})),this.state=i?"opened":"closed",this.returnFocus(),await f(),await f(),i===this.open&&i===!1&&this.requestSlottable()};if(this.open!==i)return;const c=Q(this.dialogEl);i!==!0&&c&&this.isConnected?(this.dialogEl.addEventListener("beforetoggle",()=>{l()},{once:!0}),this.dialogEl.hidePopover()):l()};return this.elements.forEach((o,h)=>{q(o,n(o,h),r(o,h))}),s}}return e}const ye=typeof document<"u"&&"showPopover"in document.createElement("div");class be{constructor(){this.root=typeof document>"u"?null:document.body,this.stack=[],this.handleScroll=e=>{typeof document<"u"&&e.target!==document&&e.target!==document.documentElement&&e.target!==document.body||this.stack.forEach(t=>{t.open&&(t.type==="auto"&&t.triggerElement instanceof HTMLElement&&t.triggerElement.closest("luzmo-picker, luzmo-select, luzmo-action-menu")&&e.stopPropagation(),typeof document<"u"&&document.dispatchEvent(new CustomEvent("luzmo-update-overlays",{bubbles:!0,composed:!0,cancelable:!0})))})},this.handlePointerdown=e=>{this.pointerdownPath=e.composedPath(),this.lastOverlay=this.stack.at(-1)},this.handlePointerup=()=>{const e=this.pointerdownPath;if(this.pointerdownPath=void 0,this.stack.length===0||!(e!=null&&e.length))return;const t=this.lastOverlay;this.lastOverlay=void 0;const i=this.stack.length-1,s=this.stack.filter((n,r)=>!e.find(h=>h===n||h===(n==null?void 0:n.triggerElement)&&(n==null?void 0:n.type)==="hint"||r===i&&n!==t&&n.triggerInteraction==="longpress")&&!n.shouldPreventClose()&&n.type!=="manual"&&!(n.type==="modal"&&t!==n));s.reverse(),s.forEach(n=>{this.closeOverlay(n);let r=n.parentOverlayToForceClose;for(;r;)this.closeOverlay(r),r=r.parentOverlayToForceClose})},this.handleBeforetoggle=e=>{const{target:t,newState:i}=e;i!=="open"&&this.closeOverlay(t)},this.handleKeydown=e=>{if(e.code!=="Escape"||this.stack.length===0)return;const t=this.stack.at(-1);if((t==null?void 0:t.type)==="page"){e.preventDefault();return}if((t==null?void 0:t.type)==="manual"){this.closeOverlay(t);return}ye||t&&this.closeOverlay(t)},typeof document<"u"&&this.bindEvents()}get document(){return this.root.ownerDocument||document}bindEvents(){typeof document<"u"&&(this.document.addEventListener("pointerdown",this.handlePointerdown),this.document.addEventListener("pointerup",this.handlePointerup),this.document.addEventListener("keydown",this.handleKeydown),this.document.addEventListener("scroll",this.handleScroll,{capture:!0}))}closeOverlay(e){const t=this.stack.indexOf(e);t!==-1&&this.stack.splice(t,1),e.open=!1}overlaysByTriggerElement(e){return this.stack.filter(t=>t.triggerElement===e)}add(e){if(this.stack.includes(e)){const t=this.stack.indexOf(e);t!==-1&&(this.stack.splice(t,1),this.stack.push(e));return}if(e.type==="auto"||e.type==="modal"||e.type==="page"){const t="luzmo-overlay-query-path",i=new Event(t,{composed:!0,bubbles:!0});e.addEventListener(t,s=>{const n=s.composedPath();this.stack.forEach(r=>{!n.find(h=>h===r)&&r.type!=="manual"&&r.type!=="modal"&&this.closeOverlay(r)})},{once:!0}),e.dispatchEvent(i)}else if(e.type==="hint"){if(this.stack.some(i=>i.type!=="manual"&&i.triggerElement&&i.triggerElement===e.triggerElement)){e.open=!1;return}this.stack.forEach(i=>{i.type==="hint"&&this.closeOverlay(i)})}requestAnimationFrame(()=>{this.stack.push(e),e.addEventListener("beforetoggle",this.handleBeforetoggle,{once:!0})})}remove(e){this.closeOverlay(e)}}const X=new be,we=':host{display:contents;pointer-events:none;--luzmo-overlay-animation-distance: .5rem}:host(:has(> luzmo-tooltip)){--luzmo-overlay-animation-distance: var( --luzmo-tooltip-animation-distance, 4px )}.dialog{margin:0;border:0;background:none;padding:0;position:fixed;overflow:visible;opacity:1!important;box-sizing:border-box;max-height:calc(100vh - 16px);max-height:calc(100dvh - 16px);max-width:calc(100vw - 16px);height:auto;inset:auto;top:0;left:0;display:flex;--luzmo-overlay-open: true}.dialog:not([is-visible]){display:none}.dialog:focus{outline:none}dialog:modal{--luzmo-popover-filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, .15))}:host(:not([open])) .dialog{--luzmo-overlay-open: false}.dialog::backdrop{display:none}.dialog:before{position:absolute;top:-999em;right:-999em;bottom:-999em;left:-999em;content:"";pointer-events:auto!important}.dialog:not(.not-immediately-closable):before{display:none}.dialog>div{width:100%}::slotted(*){pointer-events:auto;visibility:visible!important}::slotted(luzmo-popover){position:static}.dialog:not([actual-placement])[placement*=top]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:var(--luzmo-overlay-animation-distance)}.dialog:not([actual-placement])[placement*=right]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog:not([actual-placement])[placement*=bottom]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog:not([actual-placement])[placement*=left]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:var(--luzmo-overlay-animation-distance)}.dialog[actual-placement*=top]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:var(--luzmo-overlay-animation-distance)}.dialog[actual-placement*=right]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog[actual-placement*=bottom]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog[actual-placement*=left]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:var(--luzmo-overlay-animation-distance)}slot[name=longpress-describedby-descriptor]{display:none}@supports selector(:open){.dialog{opacity:0}.dialog:open{opacity:1;--luzmo-popover-filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, .15))}}@supports selector(:popover-open){.dialog{opacity:0}.dialog:popover-open{opacity:1;--luzmo-popover-filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, .15))}}@supports (overlay: auto){.dialog{display:none;transition:all var(--luzmo-overlay-animation-duration, .13s),translate 0s,display var(--luzmo-overlay-animation-duration, .13s);transition-behavior:allow-discrete}.dialog:popover-open,.dialog:modal{display:flex}}@supports (not selector(:open)) and (not selector(:popover-open)){:host:not([open]) .dialog{pointer-events:none}.dialog[actual-placement]{z-index:calc(var(--luzmo-overlay-z-index-base, 1000) + var(--luzmo-overlay-open-count))}}';function A(a){if(a===void 0)return 0;const e=window.devicePixelRatio||1;return Math.round(a*e)/e}const R=8,Ee=100,Pe=a=>({left:["right","bottom","top"],"left-start":["right-start","bottom","top"],"left-end":["right-end","bottom","top"],right:["left","bottom","top"],"right-start":["left-start","bottom","top"],"right-end":["left-end","bottom","top"],top:["bottom","left","right"],"top-start":["bottom-start","left","right"],"top-end":["bottom-end","left","right"],bottom:["top","left","right"],"bottom-start":["top-start","left","right"],"bottom-end":["top-end","left","right"]})[a]??[a],Ce=Symbol("placement updated");class Z{constructor(e){this.originalPlacements=new WeakMap,this.allowPlacementUpdate=!1,this.closeForAncestorUpdate=()=>{!this.allowPlacementUpdate&&this.options.type!=="modal"&&this.cleanup&&this.target.dispatchEvent(new Event("close",{bubbles:!0})),this.allowPlacementUpdate=!1},this.updatePlacement=()=>{this.computePlacement()},this.resetOverlayPosition=()=>{!this.target||!this.options||(this.clearOverlayPosition(),this.host.offsetHeight,this.computePlacement())},this.host=e,this.host.addController(this)}placeOverlay(e=this.target,t=this.options){if(this.target=e,this.options=t,!e||!t)return;const i=b.autoUpdate(t.trigger,e,this.closeForAncestorUpdate,{ancestorResize:!1,elementResize:!1,layoutShift:!1}),s=b.autoUpdate(t.trigger,e,this.updatePlacement,{ancestorScroll:!1});this.cleanup=()=>{var n;(n=this.host.elements)==null||n.forEach(r=>{r.addEventListener("luzmo-closed",()=>{const o=this.originalPlacements.get(r);o&&r.setAttribute("placement",o),this.originalPlacements.delete(r)},{once:!0})}),i(),s()}}async computePlacement(){var v,P;const{options:e,target:t}=this;await(document.fonts?document.fonts.ready:Promise.resolve());const i=e.trigger instanceof HTMLElement?b.flip():b.flip({padding:R,fallbackPlacements:Pe(e.placement)}),[s=0,n=0]=Array.isArray(e==null?void 0:e.offset)?e.offset:[e.offset,0],r=(v=this.host.elements.find(g=>g.tipElement))==null?void 0:v.tipElement,o=[b.offset({mainAxis:s,crossAxis:n}),b.shift({padding:R}),i,b.size({padding:R,apply:({availableWidth:g,availableHeight:U,rects:{floating:re}})=>{const V=Math.max(Ee,Math.floor(U)),L=re.height;this.initialHeight=this.isConstrained&&this.initialHeight||L,this.isConstrained=L<this.initialHeight||V<=L;const ae=this.isConstrained?`${V}px`:"";Object.assign(t.style,{maxWidth:`${Math.floor(g)}px`,maxHeight:ae})}}),...r?[b.arrow({element:r,padding:e.tipPadding||R})]:[]],{x:h,y:p,placement:l,middlewareData:c}=await b.computePosition(e.trigger,t,{placement:e.placement,middleware:o,strategy:"fixed"});if(Object.assign(t.style,{top:"0px",left:"0px",translate:`${A(h)}px ${A(p)}px`}),t.setAttribute("actual-placement",l),(P=this.host.elements)==null||P.forEach(g=>{this.originalPlacements.has(g)||this.originalPlacements.set(g,g.getAttribute("placement")),g.setAttribute("placement",l)}),r&&c.arrow){const{x:g,y:U}=c.arrow;Object.assign(r.style,{top:l.startsWith("right")||l.startsWith("left")?"0px":"",left:l.startsWith("bottom")||l.startsWith("top")?"0px":"",translate:`${A(g)}px ${A(U)}px`})}}clearOverlayPosition(){this.target&&(this.target.style.removeProperty("max-height"),this.target.style.removeProperty("max-width"),this.initialHeight=void 0,this.isConstrained=!1)}hostConnected(){document.addEventListener("luzmo-update-overlays",this.resetOverlayPosition)}hostUpdated(){var e;this.host.open||((e=this.cleanup)==null||e.call(this),this.cleanup=void 0)}hostDisconnected(){var e;(e=this.cleanup)==null||e.call(this),this.cleanup=void 0,document.removeEventListener("luzmo-update-overlays",this.resetOverlayPosition)}}var T=(a=>(a.click="click",a.hover="hover",a.longpress="longpress",a))(T||{});const _=Symbol("lastInteractionType"),z="remove-focus-ring-safari-hack";class I{constructor(e,{overlay:t,isPersistent:i,handleOverlayReady:s}){this.target=e,this.isLazilyOpen=!1,this.isPersistent=!1,this.isPersistent=!!i,this.handleOverlayReady=s,this.isPersistent&&this.init(),this.overlay=t}get activelyOpening(){return!1}get open(){var e;return((e=this.overlay)==null?void 0:e.open)??this.isLazilyOpen}set open(e){if(e!==this.open){if(this.isLazilyOpen=e,this.overlay){this.overlay.open=e,this.target[_]=this.type;return}e&&(customElements.whenDefined("luzmo-overlay").then(async()=>{const{LuzmoOverlay:t}=await Promise.resolve().then(()=>N);this.overlay=new t,this.overlay.open=!0,this.target[_]=this.type}),Promise.resolve().then(()=>N))}}get overlay(){return this._overlay}set overlay(e){var t;e&&this.overlay!==e&&(this.overlay&&this.overlay.removeController(this),this._overlay=e,this.overlay.addController(this),this.initOverlay(),this.prepareDescription(this.target),(t=this.handleOverlayReady)==null||t.call(this,this.overlay))}prepareDescription(e){}releaseDescription(){}shouldCompleteOpen(){}init(){}initOverlay(){}abort(){var e;this.releaseDescription(),(e=this.abortController)==null||e.abort()}hostConnected(){this.init()}hostDisconnected(){this.isPersistent||this.abort()}}class ee extends I{constructor(){super(...arguments),this.type=T.click,this.preventNextToggle=!1}handleClick(){this.preventNextToggle||(this.open=!this.open),this.preventNextToggle=!1}handlePointerdown(){this.preventNextToggle=this.open}init(){var t;(t=this.abortController)==null||t.abort(),this.abortController=new AbortController;const{signal:e}=this.abortController;this.target.addEventListener("click",()=>this.handleClick(),{signal:e}),this.target.addEventListener("pointerdown",()=>this.handlePointerdown(),{signal:e})}}const Te=300;class te extends I{constructor(){super(...arguments),this.type=T.hover,this.elementIds=[],this.focusedin=!1,this.pointerentered=!1}handleKeyup(e){(e.code==="Tab"||e.code==="Escape")&&(this.open=!0,this.removeSafariFocusRingClass())}handleTargetFocusin(){if(this.target.matches(":focus-visible")){if(k.isWebKit()&&this.target[_]===T.click){this.target.classList.add(z);return}this.open=!0,this.focusedin=!0,this.removeSafariFocusRingClass()}}handleTargetFocusout(){this.removeSafariFocusRingClass(),this.focusedin=!1,!this.pointerentered&&(this.open=!1)}handleTargetPointerenter(){var e;this.hoverTimeout&&(clearTimeout(this.hoverTimeout),this.hoverTimeout=void 0),!((e=this.overlay)!=null&&e.disabled)&&(this.open=!0,this.pointerentered=!0)}handleTargetPointerleave(){this.doPointerleave()}handleHostPointerenter(){this.hoverTimeout&&(clearTimeout(this.hoverTimeout),this.hoverTimeout=void 0)}handleHostPointerleave(){this.doPointerleave()}prepareDescription(){if(this.overlay.elements.length===0)return;const e=this.target.getRootNode(),t=this.overlay.elements[0].getRootNode(),i=this.overlay.getRootNode();e===i?this.prepareOverlayRelativeDescription():e===t&&this.prepareContentRelativeDescription()}prepareOverlayRelativeDescription(){const e=H.conditionAttributeWithId(this.target,"aria-describedby",[this.overlay.id]);this.releaseDescription=()=>{e(),this.releaseDescription=E}}prepareContentRelativeDescription(){const e=[],t=this.overlay.elements.map(s=>(e.push(s.id),s.id||(s.id=`${this.overlay.tagName.toLowerCase()}-helper-${M.randomID()}`),s.id));this.elementIds=e;const i=H.conditionAttributeWithId(this.target,"aria-describedby",t);this.releaseDescription=()=>{i(),this.overlay.elements.map((s,n)=>{s.id=this.elementIds[n]}),this.releaseDescription=E}}doPointerleave(){this.pointerentered=!1;const e=this.target;this.focusedin&&e.matches(":focus-visible")||(this.hoverTimeout=setTimeout(()=>{this.open=!1},Te))}init(){var t;(t=this.abortController)==null||t.abort(),this.abortController=new AbortController;const{signal:e}=this.abortController;this.target.addEventListener("keyup",i=>this.handleKeyup(i),{signal:e}),this.target.addEventListener("focusin",()=>this.handleTargetFocusin(),{signal:e}),this.target.addEventListener("focusout",()=>this.handleTargetFocusout(),{signal:e}),this.target.addEventListener("pointerenter",()=>this.handleTargetPointerenter(),{signal:e}),this.target.addEventListener("pointerleave",()=>this.handleTargetPointerleave(),{signal:e}),this.overlay&&this.initOverlay()}initOverlay(){if(!this.abortController)return;const{signal:e}=this.abortController;this.overlay.addEventListener("pointerenter",()=>this.handleHostPointerenter(),{signal:e}),this.overlay.addEventListener("pointerleave",()=>this.handleHostPointerleave(),{signal:e})}removeSafariFocusRingClass(){k.isWebKit()&&this.target.classList.contains(z)&&this.target.classList.remove(z)}}const Oe=300,ie={touch:"Double tap and long press for additional options",keyboard:"Press Space or Alt+Down Arrow for additional options",mouse:"Click and hold for additional options"};class se extends I{constructor(){super(...arguments),this.type=T.longpress,this.longpressState=null,this.releaseDescription=E,this.handlePointerup=()=>{var e;clearTimeout(this.timeout),this.target&&(this.longpressState=((e=this.overlay)==null?void 0:e.state)==="opening"?"pressed":null,document.removeEventListener("pointerup",this.handlePointerup),document.removeEventListener("pointercancel",this.handlePointerup))}}get activelyOpening(){return this.longpressState==="opening"||this.longpressState==="pressed"}handleLongpress(){this.open=!0,this.longpressState=this.longpressState==="potential"?"opening":"pressed"}handlePointerdown(e){!this.target||e.button!==0||(this.longpressState="potential",document.addEventListener("pointerup",this.handlePointerup),document.addEventListener("pointercancel",this.handlePointerup),"holdAffordance"in this.target)||(this.timeout=setTimeout(()=>{this.target&&this.target.dispatchEvent(new CustomEvent("longpress",{bubbles:!0,composed:!0,detail:{source:"pointer"}}))},Oe))}handleKeydown(e){const{code:t,altKey:i}=e;i&&t==="ArrowDown"&&(e.stopPropagation(),e.stopImmediatePropagation())}handleKeyup(e){const{code:t,altKey:i}=e;if(t==="Space"||i&&t==="ArrowDown"){if(!this.target)return;e.stopPropagation(),this.target.dispatchEvent(new CustomEvent("longpress",{bubbles:!0,composed:!0,detail:{source:"keyboard"}})),setTimeout(()=>{this.longpressState=null})}}prepareDescription(e){if(this.releaseDescription!==E||this.overlay.elements.length===0)return;const t=document.createElement("div");t.id=`longpress-describedby-descriptor-${M.randomID()}`;const i=k.isIOS()||k.isAndroid()?"touch":"keyboard";t.textContent=ie[i],t.slot="longpress-describedby-descriptor";const s=e.getRootNode(),n=this.overlay.getRootNode();s===n?this.overlay.append(t):(t.hidden=!("host"in s),e.after(t));const r=H.conditionAttributeWithId(e,"aria-describedby",[t.id]);this.releaseDescription=()=>{r(),t.remove(),this.releaseDescription=E}}shouldCompleteOpen(){this.longpressState=this.longpressState==="pressed"?null:this.longpressState}init(){var t;(t=this.abortController)==null||t.abort(),this.abortController=new AbortController;const{signal:e}=this.abortController;this.target.addEventListener("longpress",()=>this.handleLongpress(),{signal:e}),this.target.addEventListener("pointerdown",i=>this.handlePointerdown(i),{signal:e}),this.prepareDescription(this.target),!this.target.holdAffordance&&(this.target.addEventListener("keydown",i=>this.handleKeydown(i),{signal:e}),this.target.addEventListener("keyup",i=>this.handleKeyup(i),{signal:e}))}}const oe={click:ee,longpress:se,hover:te};var De=Object.defineProperty,Se=Object.getOwnPropertyDescriptor,m=(a,e,t,i)=>{for(var s=i>1?void 0:i?Se(e,t):e,n=a.length-1,r;n>=0;n--)(r=a[n])&&(s=(i?r(e,t,s):r(s))||s);return i&&s&&De(e,t,s),s};const xe=typeof document<"u"&&"showPopover"in document.createElement("div");let F=me(C);F=xe?ve(F):ge(F);var w;const d=(w=class extends F{constructor(){super(...arguments),this._delayed=!1,this._disabled=!1,this.offset=0,this._open=!1,this.lastRequestSlottableState=!1,this.receivesFocus="auto",this._state="closed",this.triggerElement=null,this.type="auto",this.wasOpen=!1,this.closeOnFocusOut=e=>{if(!e.relatedTarget)return;const t=new Event("overlay-relation-query",{bubbles:!0,composed:!0});e.relatedTarget.addEventListener(t.type,i=>{i.composedPath().includes(this)||(this.open=!1)}),e.relatedTarget.dispatchEvent(t)}}get delayed(){var e;return((e=this.elements.at(-1))==null?void 0:e.hasAttribute("delayed"))||this._delayed}set delayed(e){this._delayed=e}get disabled(){return this._disabled}set disabled(e){var t;this._disabled=e,e?((t=this.strategy)==null||t.abort(),this.wasOpen=this.open,this.open=!1):(this.bindEvents(),this.open=this.open||this.wasOpen,this.wasOpen=!1)}get hasNonVirtualTrigger(){return!!this.triggerElement&&!(this.triggerElement instanceof x)}get placementController(){return this._placementController||(this._placementController=new Z(this)),this._placementController}get open(){return this._open}set open(e){var t;e&&this.disabled||e!==this.open&&((t=this.strategy)!=null&&t.activelyOpening&&!e||(this._open=e,this.open&&(w.openCount+=1),this.requestUpdate("open",!this.open),this.open&&this.requestSlottable()))}get state(){return this._state}set state(e){var i;if(e===this.state)return;const t=this.state;this._state=e,(this.state==="opened"||this.state==="closed")&&((i=this.strategy)==null||i.shouldCompleteOpen()),this.requestUpdate("state",t)}get elementResolver(){return this._elementResolver||(this._elementResolver=new Y.ElementResolutionController(this)),this._elementResolver}get usesDialog(){return this.type==="modal"||this.type==="page"}get popoverValue(){if("popover"in this)switch(this.type){case"modal":case"page":return;case"hint":return"manual";default:return this.type}}get requiresPositioning(){return!(this.type==="page"||!this.open||!this.triggerElement||!this.placement&&this.type!=="hint")}managePosition(){if(!this.requiresPositioning||!this.open)return;const e=this.offset||0,t=this.triggerElement,i=this.placement||"right",s=this.tipPadding;this.placementController.placeOverlay(this.dialogEl,{offset:e,placement:i,tipPadding:s,trigger:t,type:this.type})}async managePopoverOpen(){super.managePopoverOpen();const e=this.open;if(this.open!==e||(await this.manageDelay(e),this.open!==e)||(this.triggerInteraction==="longpress"&&await f(),await this.ensureOnDOM(e),this.open!==e))return;const t=await this.makeTransition(e);this.open===e&&await this.applyFocus(e,t)}async applyFocus(e,t){if(!(this.receivesFocus==="false"||this.type==="hint")){if(await f(),await f(),e===this.open&&!this.open){this.hasNonVirtualTrigger&&this.contains(this.getRootNode().activeElement)&&this.triggerElement.focus();return}t==null||t.focus()}}returnFocus(){var t;if(this.open||this.type==="hint")return;const e=()=>{var n,r;const i=[];let s=typeof document<"u"?document.activeElement:null;for(;(n=s==null?void 0:s.shadowRoot)!=null&&n.activeElement;)s=s.shadowRoot.activeElement;for(;s;){const o=s.assignedSlot||s.parentElement||((r=s.getRootNode())==null?void 0:r.host);o&&i.push(o),s=o}return i};this.receivesFocus!=="false"&&((t=this.triggerElement)!=null&&t.focus)&&(this.contains(this.getRootNode().activeElement)||e().includes(this)||typeof document<"u"&&document.activeElement===document.body)&&this.triggerElement.focus()}async manageOpen(e){if(!(!this.isConnected&&this.open)&&(this.hasUpdated||await this.updateComplete,this.open?(X.add(this),this.willPreventClose&&(document.addEventListener("pointerup",()=>{this.dialogEl.classList.toggle("not-immediately-closable",!1),this.willPreventClose=!1},{once:!0}),this.dialogEl.classList.toggle("not-immediately-closable",!0))):(e&&this.dispose(),X.remove(this)),this.open&&this.state!=="opened"?this.state="opening":!this.open&&this.state!=="closed"&&(this.state="closing"),this.usesDialog?this.manageDialogOpen():this.managePopoverOpen(),this.type==="auto")){const t=this.getRootNode();this.open?t.addEventListener("focusout",this.closeOnFocusOut,{capture:!0}):t.removeEventListener("focusout",this.closeOnFocusOut,{capture:!0})}}bindEvents(){var e;(e=this.strategy)==null||e.abort(),this.strategy=void 0,this.hasNonVirtualTrigger&&this.triggerInteraction&&(this.strategy=new oe[this.triggerInteraction](this.triggerElement,{overlay:this}))}handleBeforetoggle(e){e.newState!=="open"&&this.handleBrowserClose(e)}handleBrowserClose(e){var t;if(e.stopPropagation(),!((t=this.strategy)!=null&&t.activelyOpening)){this.open=!1;return}this.manuallyKeepOpen()}manuallyKeepOpen(){this.open=!0,this.placementController.allowPlacementUpdate=!0,this.manageOpen(!1)}handleSlotchange(){var e,t;this.elements.length===0?(e=this.strategy)==null||e.releaseDescription():this.hasNonVirtualTrigger&&((t=this.strategy)==null||t.prepareDescription(this.triggerElement))}shouldPreventClose(){const e=this.willPreventClose;return this.willPreventClose=!1,e}requestSlottable(){this.lastRequestSlottableState!==this.open&&(this.open||document.body.offsetHeight,this.dispatchEvent(new J.SlottableRequestEvent("overlay-content",this.open?{}:J.removeSlottableRequest)),this.lastRequestSlottableState=this.open)}willUpdate(e){var i;if(this.hasAttribute("id")||this.setAttribute("id",`${this.tagName.toLowerCase()}-${M.randomID()}`),e.has("open")&&(this.hasUpdated||this.open)&&this.manageOpen(e.get("open")),e.has("trigger")){const[s,n]=((i=this.trigger)==null?void 0:i.split("@"))||[];this.elementResolver.selector=s?`#${s}`:"",this.triggerInteraction=n}let t=!1;e.has(Y.elementResolverUpdatedSymbol)&&(t=this.triggerElement,this.triggerElement=this.elementResolver.element),e.has("triggerElement")&&(t=e.get("triggerElement")),t!==!1&&this.bindEvents()}updated(e){super.updated(e),e.has("placement")&&(this.placement?this.dialogEl.setAttribute("actual-placement",this.placement):this.dialogEl.removeAttribute("actual-placement"),this.open&&e.get("placement")!==void 0&&this.placementController.resetOverlayPosition()),e.has("state")&&this.state==="closed"&&e.get("state")!==void 0&&this.placementController.clearOverlayPosition()}renderContent(){return O.html` <slot @slotchange=${this.handleSlotchange}></slot> `}get dialogStyleMap(){return{"--luzmo-overlay-open-count":w.openCount.toString()}}renderDialog(){return O.html`
18
+ "use strict";const O=require("lit"),u=require("lit/decorators.js"),$=require("lit/directives/if-defined.js"),G=require("lit/directives/style-map.js"),M=require("./random-id-CqvckpWe.cjs"),Y=require("./element-resolution-BvRLGqIU.cjs"),le=require("./base-DxRGeCrb.cjs"),S=require("./focusable-selectors-BgFlyFcY.cjs"),b=require("@floating-ui/dom"),J=require("./slottable-request-event-BfUUt1Mh.cjs"),H=require("./condition-attribute-with-id-DrQYZzFS.cjs"),k=require("./platform-BJnOJJag.cjs");function he(a,e,t=[]){for(const[i,s]of e.entries()){const n=a[i],r=n.parentElement||n.getRootNode();t[i]&&t[i](s),r&&r!==n&&n.replaceWith(s),delete a[i]}return e}const ce=(a,e,{position:t,prepareCallback:i}={position:"beforeend"})=>{let{length:s}=a;if(s===0)return()=>a;let n=1,r=0;(t==="afterbegin"||t==="afterend")&&(n=-1,r=s-1);const o=new Array(s),h=new Array(s),p=typeof document<"u"?document.createComment("placeholder for reparented element"):null;do{const l=a[r];i&&(h[r]=i(l)),o[r]=p.cloneNode();const c=l.parentElement||l.getRootNode();c&&c!==l&&c.replaceChild(o[r],l),e.insertAdjacentElement(t,l),r+=n}while(--s>0);return function(){return he(o,a,h)}},pe=1e3,de=1e3;class ue{constructor(e={}){this.warmUpDelay=pe,this.coolDownDelay=de,this.isWarm=!1,this.timeout=0,Object.assign(this,e)}openTimer(e){if(this.cancelCooldownTimer(),!this.component||e!==this.component)return this.component&&(this.close(this.component),this.cancelCooldownTimer()),this.component=e,this.isWarm?Promise.resolve(!1):(this.promise=new Promise(t=>{this.resolve=t,this.timeout=typeof window<"u"?window.setTimeout(()=>{this.resolve&&(this.resolve(!1),this.isWarm=!0)},this.warmUpDelay):0}),this.promise);if(this.promise)return this.promise;throw new Error("Inconsistent state")}close(e){this.component&&this.component===e&&(this.resetCooldownTimer(),this.timeout>0&&(clearTimeout(this.timeout),this.timeout=0),this.resolve&&(this.resolve(!0),delete this.resolve),delete this.promise,delete this.component)}resetCooldownTimer(){this.isWarm&&(this.cooldownTimeout&&typeof window<"u"&&window.clearTimeout(this.cooldownTimeout),this.cooldownTimeout=typeof window<"u"?window.setTimeout(()=>{this.isWarm=!1,delete this.cooldownTimeout},this.coolDownDelay):void 0)}cancelCooldownTimer(){this.cooldownTimeout&&typeof window<"u"&&window.clearTimeout(this.cooldownTimeout),delete this.cooldownTimeout}}const D=new ue,E=()=>{},q=(a,e,t)=>{const i=new AbortController,s=new Map,n=()=>{i.abort(),t()};let r,o;const h=requestAnimationFrame(()=>{r=requestAnimationFrame(()=>{o=requestAnimationFrame(()=>{n()})})}),p=c=>{c.target===a&&(s.set(c.propertyName,s.get(c.propertyName)-1),s.get(c.propertyName)||s.delete(c.propertyName),s.size===0&&n())},l=c=>{c.target===a&&(s.has(c.propertyName)||s.set(c.propertyName,0),s.set(c.propertyName,s.get(c.propertyName)+1),cancelAnimationFrame(h),cancelAnimationFrame(r),cancelAnimationFrame(o))};a.addEventListener("transitionrun",l,{signal:i.signal}),a.addEventListener("transitionend",p,{signal:i.signal}),a.addEventListener("transitioncancel",p,{signal:i.signal}),e()};function f(){return new Promise(a=>requestAnimationFrame(()=>a()))}class C extends le.LuzmoElement{constructor(){super(...arguments),this.dispose=E,this.offset=0,this.willPreventClose=!1}applyFocus(e,t){}get delayed(){return!1}set delayed(e){}get disabled(){return!1}set disabled(e){}get elementResolver(){return this._elementResolver}set elementResolver(e){this._elementResolver=e}ensureOnDOM(e){}makeTransition(e){return null}manageDelay(e){}manageDialogOpen(){}managePopoverOpen(){}managePosition(){}get open(){return!1}set open(e){}get placementController(){return this._placementController}set placementController(e){this._placementController=e}requestSlottable(){}returnFocus(){}get state(){return"closed"}set state(e){}manuallyKeepOpen(){}static update(){const e=new CustomEvent("luzmo-update-overlays",{bubbles:!0,composed:!0,cancelable:!0});document.dispatchEvent(e)}static async open(e,t,i,s){await Promise.resolve().then(()=>N);const n=arguments.length===2,r=i||e,o=new this;let h=!1;const p=ce([r],o,{position:"beforeend",prepareCallback:v=>{const P=v.slot;return v.removeAttribute("slot"),()=>{v.slot=P}}});if(o.dispose=()=>{o.addEventListener("luzmo-closed",()=>{h||(p(),h=!0),requestAnimationFrame(()=>{o.remove()})}),o.open=!1,o.dispose=E},!n&&r&&s){const v=e,P=t,g=s;return C.applyOptions(o,{...g,delayed:g.delayed||r.hasAttribute("delayed"),trigger:g.virtualTrigger||v,type:P==="modal"?"modal":P==="hover"?"hint":"auto"}),v.after(o),await o.updateComplete,o.open=!0,o.dispose}const c=t;return o.append(r),C.applyOptions(o,{...c,delayed:c.delayed||r.hasAttribute("delayed")}),o.updateComplete.then(()=>{o.open=!0}),o}static applyOptions(e,t){e.delayed=!!t.delayed,e.receivesFocus=t.receivesFocus??"auto",e.triggerElement=t.trigger||null,e.type=t.type||"modal",e.offset=t.offset??0,e.placement=t.placement,e.willPreventClose=!!t.notImmediatelyClosable}}const W=a=>a.querySelector(S.userFocusableSelector),B=a=>a.assignedElements().find(t=>t.matches(S.userFocusableSelector));class K extends Event{constructor(){super("beforetoggle",{bubbles:!1,composed:!1}),this.currentState="open",this.newState="closed"}}class j extends Event{constructor(){super("beforetoggle",{bubbles:!1,composed:!1}),this.currentState="closed",this.newState="open"}}class y extends Event{constructor(e,t,{publish:i,interaction:s,reason:n}){super(e,{bubbles:i,composed:i}),this.overlay=t,this.detail={interaction:s,reason:n}}}class x{constructor(e,t){this.x=0,this.y=0,this.x=e,this.y=t}updateBoundingClientRect(e,t){this.x=e,this.y=t,C.update()}getBoundingClientRect(){return{width:0,height:0,top:this.y,right:this.x,y:this.y,x:this.x,bottom:this.y,left:this.x,toJSON(){}}}}function me(a){class e extends a{async manageDialogOpen(){const i=this.open;if(await f(),await this.managePosition(),this.open!==i)return;const s=await this.dialogMakeTransition(i);this.open===i&&await this.dialogApplyFocus(i,s)}dialogMakeTransition(i){let s=null;const n=(o,h)=>()=>{if(o.open=i,!i){const l=()=>{o.removeEventListener("close",l)};o.addEventListener("close",l)}if(h>0)return;const p=i?j:K;this.dispatchEvent(new p),i&&(o.matches(S.userFocusableSelector)&&(s=o),s=s||W(o),s||o.querySelectorAll("slot").forEach(c=>{s||(s=B(c))}),!(!this.isConnected||this.dialogEl.open)&&this.dialogEl.showModal())},r=(o,h)=>()=>{if(this.open!==i)return;const p=i?"luzmo-opened":"luzmo-closed";if(h>0){o.dispatchEvent(new y(p,this,{interaction:this.type,publish:!1}));return}if(!this.isConnected||i!==this.open)return;const l=async()=>{const c=this.triggerElement instanceof x;this.dispatchEvent(new y(p,this,{interaction:this.type,publish:c})),o.dispatchEvent(new y(p,this,{interaction:this.type,publish:!1})),this.triggerElement&&!c&&this.triggerElement.dispatchEvent(new y(p,this,{interaction:this.type,publish:!0})),this.state=i?"opened":"closed",this.returnFocus(),await f(),await f(),i===this.open&&i===!1&&this.requestSlottable()};!i&&this.dialogEl.open?(this.dialogEl.addEventListener("close",()=>{l()},{once:!0}),this.dialogEl.close()):l()};return this.elements.forEach((o,h)=>{q(o,n(o,h),r(o,h))}),s}dialogApplyFocus(i,s){this.applyFocus(i,s)}}return e}function ge(a){class e extends a{async managePopoverOpen(){await this.managePosition()}async manageDelay(i){if(i===!1||i!==this.open){D.close(this);return}this.delayed&&await D.openTimer(this)&&(this.open=!i)}ensureOnDOM(i){document.body.offsetHeight}makeTransition(i){if(this.open!==i)return null;let s=null;const n=(o,h)=>()=>{if(i!==this.open)return;if(o.open=i,h===0){const l=i?j:K;this.dispatchEvent(new l)}if(i!==!0||(o.matches(S.userFocusableSelector)&&(s=o),s=s||W(o),s))return;o.querySelectorAll("slot").forEach(l=>{s||(s=B(l))})},r=(o,h)=>async()=>{if(this.open!==i)return;const p=i?"luzmo-opened":"luzmo-closed";if(o.dispatchEvent(new y(p,this,{interaction:this.type})),h>0)return;const l=this.triggerElement instanceof x;this.dispatchEvent(new y(p,this,{interaction:this.type,publish:l})),this.triggerElement&&!l&&this.triggerElement.dispatchEvent(new y(p,this,{interaction:this.type,publish:!0})),this.state=i?"opened":"closed",this.returnFocus(),await f(),await f(),i===this.open&&i===!1&&this.requestSlottable()};return this.elements.forEach((o,h)=>{q(o,n(o,h),r(o,h))}),s}}return e}const fe=typeof CSS<"u"&&CSS.supports("(overlay: auto)");function Q(a){let e=!1;try{e=a.matches(":popover-open")}catch{}let t=!1;try{t=a.matches(":open")}catch{}return e||t}function ve(a){class e extends a{async manageDelay(i){if(i===!1||i!==this.open){D.close(this);return}this.delayed&&await D.openTimer(this)&&(this.open=!i)}shouldHidePopover(i){if(i&&this.open!==i)return;const s=async({newState:n}={})=>{n!=="open"&&await this.placementController.resetOverlayPosition()};if(!Q(this.dialogEl)){s();return}this.dialogEl.addEventListener("toggle",s,{once:!0})}shouldShowPopover(i){let s=!1;try{s=this.dialogEl.matches(":popover-open")}catch{}let n=!1;try{n=this.dialogEl.matches(":open")}catch{}i&&this.open===i&&!s&&!n&&this.isConnected&&(this.dialogEl.showPopover(),this.managePosition())}async ensureOnDOM(i){fe||await this.shouldHidePopover(i),this.shouldShowPopover(i),await f()}makeTransition(i){if(this.open!==i)return null;let s=null;const n=(o,h)=>()=>{if(o.open=i,h===0){const l=i?j:K;this.dispatchEvent(new l)}if(!i||(o.matches(S.userFocusableSelector)&&(s=o),s=s||W(o),s))return;o.querySelectorAll("slot").forEach(l=>{s||(s=B(l))})},r=(o,h)=>()=>{if(this.open!==i)return;const p=i?"luzmo-opened":"luzmo-closed";if(h>0){o.dispatchEvent(new y(p,this,{interaction:this.type,publish:!1}));return}const l=async()=>{if(this.open!==i)return;await f();const v=this.triggerElement instanceof x;this.dispatchEvent(new y(p,this,{interaction:this.type,publish:v})),o.dispatchEvent(new y(p,this,{interaction:this.type,publish:!1})),this.triggerElement&&!v&&this.triggerElement.dispatchEvent(new y(p,this,{interaction:this.type,publish:!0})),this.state=i?"opened":"closed",this.returnFocus(),await f(),await f(),i===this.open&&i===!1&&this.requestSlottable()};if(this.open!==i)return;const c=Q(this.dialogEl);i!==!0&&c&&this.isConnected?(this.dialogEl.addEventListener("beforetoggle",()=>{l()},{once:!0}),this.dialogEl.hidePopover()):l()};return this.elements.forEach((o,h)=>{q(o,n(o,h),r(o,h))}),s}}return e}const ye=typeof document<"u"&&"showPopover"in document.createElement("div");class be{constructor(){this.root=typeof document>"u"?null:document.body,this.stack=[],this.handleScroll=e=>{typeof document<"u"&&e.target!==document&&e.target!==document.documentElement&&e.target!==document.body||this.stack.forEach(t=>{t.open&&(t.type==="auto"&&t.triggerElement instanceof HTMLElement&&t.triggerElement.closest("luzmo-picker, luzmo-select, luzmo-action-menu")&&e.stopPropagation(),typeof document<"u"&&document.dispatchEvent(new CustomEvent("luzmo-update-overlays",{bubbles:!0,composed:!0,cancelable:!0})))})},this.handlePointerdown=e=>{this.pointerdownPath=e.composedPath(),this.lastOverlay=this.stack.at(-1)},this.handlePointerup=()=>{const e=this.pointerdownPath;if(this.pointerdownPath=void 0,this.stack.length===0||!(e!=null&&e.length))return;const t=this.lastOverlay;this.lastOverlay=void 0;const i=this.stack.length-1,s=this.stack.filter((n,r)=>!e.find(h=>h===n||h===(n==null?void 0:n.triggerElement)&&(n==null?void 0:n.type)==="hint"||r===i&&n!==t&&n.triggerInteraction==="longpress")&&!n.shouldPreventClose()&&n.type!=="manual"&&!(n.type==="modal"&&t!==n));s.reverse(),s.forEach(n=>{this.closeOverlay(n);let r=n.parentOverlayToForceClose;for(;r;)this.closeOverlay(r),r=r.parentOverlayToForceClose})},this.handleBeforetoggle=e=>{const{target:t,newState:i}=e;i!=="open"&&this.closeOverlay(t)},this.handleKeydown=e=>{if(e.code!=="Escape"||this.stack.length===0)return;const t=this.stack.at(-1);if((t==null?void 0:t.type)==="page"){e.preventDefault();return}if((t==null?void 0:t.type)==="manual"){this.closeOverlay(t);return}ye||t&&this.closeOverlay(t)},typeof document<"u"&&this.bindEvents()}get document(){return this.root.ownerDocument||document}bindEvents(){typeof document<"u"&&(this.document.addEventListener("pointerdown",this.handlePointerdown),this.document.addEventListener("pointerup",this.handlePointerup),this.document.addEventListener("keydown",this.handleKeydown),this.document.addEventListener("scroll",this.handleScroll,{capture:!0}))}closeOverlay(e){const t=this.stack.indexOf(e);t!==-1&&this.stack.splice(t,1),e.open=!1}overlaysByTriggerElement(e){return this.stack.filter(t=>t.triggerElement===e)}add(e){if(this.stack.includes(e)){const t=this.stack.indexOf(e);t!==-1&&(this.stack.splice(t,1),this.stack.push(e));return}if(e.type==="auto"||e.type==="modal"||e.type==="page"){const t="luzmo-overlay-query-path",i=new Event(t,{composed:!0,bubbles:!0});e.addEventListener(t,s=>{const n=s.composedPath();this.stack.forEach(r=>{!n.find(h=>h===r)&&r.type!=="manual"&&r.type!=="modal"&&this.closeOverlay(r)})},{once:!0}),e.dispatchEvent(i)}else if(e.type==="hint"){if(this.stack.some(i=>i.type!=="manual"&&i.triggerElement&&i.triggerElement===e.triggerElement)){e.open=!1;return}this.stack.forEach(i=>{i.type==="hint"&&this.closeOverlay(i)})}requestAnimationFrame(()=>{this.stack.push(e),e.addEventListener("beforetoggle",this.handleBeforetoggle,{once:!0})})}remove(e){this.closeOverlay(e)}}const X=new be,we=':host{display:contents;pointer-events:none;--luzmo-overlay-animation-distance: .5rem}:host(:has(> luzmo-tooltip)){--luzmo-overlay-animation-distance: var( --luzmo-tooltip-animation-distance, 4px )}.dialog{margin:0;border:0;background:none;padding:0;position:fixed;overflow:visible;opacity:1!important;box-sizing:border-box;max-height:calc(100vh - 16px);max-height:calc(100dvh - 16px);max-width:calc(100vw - 16px);height:auto;inset:auto;top:0;left:0;display:flex;--luzmo-overlay-open: true}.dialog:not([is-visible]){display:none}.dialog:focus{outline:none}dialog:modal{--luzmo-popover-filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, .15))}:host(:not([open])) .dialog{--luzmo-overlay-open: false}.dialog::backdrop{display:none}.dialog:before{position:absolute;top:-999em;right:-999em;bottom:-999em;left:-999em;content:"";pointer-events:auto!important}.dialog:not(.not-immediately-closable):before{display:none}.dialog>div{width:100%}::slotted(*){pointer-events:auto;visibility:visible!important}::slotted(luzmo-popover){position:static}.dialog:not([actual-placement])[placement*=top]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:var(--luzmo-overlay-animation-distance)}.dialog:not([actual-placement])[placement*=right]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog:not([actual-placement])[placement*=bottom]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog:not([actual-placement])[placement*=left]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:var(--luzmo-overlay-animation-distance)}.dialog[actual-placement*=top]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:var(--luzmo-overlay-animation-distance)}.dialog[actual-placement*=right]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog[actual-placement*=bottom]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog[actual-placement*=left]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:var(--luzmo-overlay-animation-distance)}slot[name=longpress-describedby-descriptor]{display:none}@supports selector(:open){.dialog{opacity:0}.dialog:open{opacity:1;--luzmo-popover-filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, .15))}}@supports selector(:popover-open){.dialog{opacity:0}.dialog:popover-open{opacity:1;--luzmo-popover-filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, .15))}}@supports (overlay: auto){.dialog{display:none;transition:all var(--luzmo-overlay-animation-duration, .13s),translate 0s,display var(--luzmo-overlay-animation-duration, .13s);transition-behavior:allow-discrete}.dialog:popover-open,.dialog:modal{display:flex}}@supports (not selector(:open)) and (not selector(:popover-open)){:host:not([open]) .dialog{pointer-events:none}.dialog[actual-placement]{z-index:calc(var(--luzmo-overlay-z-index-base, 1000) + var(--luzmo-overlay-open-count))}}';function A(a){if(a===void 0)return 0;const e=window.devicePixelRatio||1;return Math.round(a*e)/e}const R=8,Ee=100,Pe=a=>({left:["right","bottom","top"],"left-start":["right-start","bottom","top"],"left-end":["right-end","bottom","top"],right:["left","bottom","top"],"right-start":["left-start","bottom","top"],"right-end":["left-end","bottom","top"],top:["bottom","left","right"],"top-start":["bottom-start","left","right"],"top-end":["bottom-end","left","right"],bottom:["top","left","right"],"bottom-start":["top-start","left","right"],"bottom-end":["top-end","left","right"]})[a]??[a],Ce=Symbol("placement updated");class Z{constructor(e){this.originalPlacements=new WeakMap,this.allowPlacementUpdate=!1,this.closeForAncestorUpdate=()=>{!this.allowPlacementUpdate&&this.options.type!=="modal"&&this.cleanup&&this.target.dispatchEvent(new Event("close",{bubbles:!0})),this.allowPlacementUpdate=!1},this.updatePlacement=()=>{this.computePlacement()},this.resetOverlayPosition=()=>{!this.target||!this.options||(this.clearOverlayPosition(),this.host.offsetHeight,this.computePlacement())},this.host=e,this.host.addController(this)}placeOverlay(e=this.target,t=this.options){if(this.target=e,this.options=t,!e||!t)return;const i=b.autoUpdate(t.trigger,e,this.closeForAncestorUpdate,{ancestorResize:!1,elementResize:!1,layoutShift:!1}),s=b.autoUpdate(t.trigger,e,this.updatePlacement,{ancestorScroll:!1});this.cleanup=()=>{var n;(n=this.host.elements)==null||n.forEach(r=>{r.addEventListener("luzmo-closed",()=>{const o=this.originalPlacements.get(r);o&&r.setAttribute("placement",o),this.originalPlacements.delete(r)},{once:!0})}),i(),s()}}async computePlacement(){var v,P;const{options:e,target:t}=this;await(document.fonts?document.fonts.ready:Promise.resolve());const i=e.trigger instanceof HTMLElement?b.flip():b.flip({padding:R,fallbackPlacements:Pe(e.placement)}),[s=0,n=0]=Array.isArray(e==null?void 0:e.offset)?e.offset:[e.offset,0],r=(v=this.host.elements.find(g=>g.tipElement))==null?void 0:v.tipElement,o=[b.offset({mainAxis:s,crossAxis:n}),b.shift({padding:R}),i,b.size({padding:R,apply:({availableWidth:g,availableHeight:U,rects:{floating:re}})=>{const V=Math.max(Ee,Math.floor(U)),L=re.height;this.initialHeight=this.isConstrained&&this.initialHeight||L,this.isConstrained=L<this.initialHeight||V<=L;const ae=this.isConstrained?`${V}px`:"";Object.assign(t.style,{maxWidth:`${Math.floor(g)}px`,maxHeight:ae})}}),...r?[b.arrow({element:r,padding:e.tipPadding||R})]:[]],{x:h,y:p,placement:l,middlewareData:c}=await b.computePosition(e.trigger,t,{placement:e.placement,middleware:o,strategy:"fixed"});if(Object.assign(t.style,{top:"0px",left:"0px",translate:`${A(h)}px ${A(p)}px`}),t.setAttribute("actual-placement",l),(P=this.host.elements)==null||P.forEach(g=>{this.originalPlacements.has(g)||this.originalPlacements.set(g,g.getAttribute("placement")),g.setAttribute("placement",l)}),r&&c.arrow){const{x:g,y:U}=c.arrow;Object.assign(r.style,{top:l.startsWith("right")||l.startsWith("left")?"0px":"",left:l.startsWith("bottom")||l.startsWith("top")?"0px":"",translate:`${A(g)}px ${A(U)}px`})}}clearOverlayPosition(){this.target&&(this.target.style.removeProperty("max-height"),this.target.style.removeProperty("max-width"),this.initialHeight=void 0,this.isConstrained=!1)}hostConnected(){document.addEventListener("luzmo-update-overlays",this.resetOverlayPosition)}hostUpdated(){var e;this.host.open||((e=this.cleanup)==null||e.call(this),this.cleanup=void 0)}hostDisconnected(){var e;(e=this.cleanup)==null||e.call(this),this.cleanup=void 0,document.removeEventListener("luzmo-update-overlays",this.resetOverlayPosition)}}var T=(a=>(a.click="click",a.hover="hover",a.longpress="longpress",a))(T||{});const _=Symbol("lastInteractionType"),z="remove-focus-ring-safari-hack";class I{constructor(e,{overlay:t,isPersistent:i,handleOverlayReady:s}){this.target=e,this.isLazilyOpen=!1,this.isPersistent=!1,this.isPersistent=!!i,this.handleOverlayReady=s,this.isPersistent&&this.init(),this.overlay=t}get activelyOpening(){return!1}get open(){var e;return((e=this.overlay)==null?void 0:e.open)??this.isLazilyOpen}set open(e){if(e!==this.open){if(this.isLazilyOpen=e,this.overlay){this.overlay.open=e,this.target[_]=this.type;return}e&&(customElements.whenDefined("luzmo-overlay").then(async()=>{const{LuzmoOverlay:t}=await Promise.resolve().then(()=>N);this.overlay=new t,this.overlay.open=!0,this.target[_]=this.type}),Promise.resolve().then(()=>N))}}get overlay(){return this._overlay}set overlay(e){var t;e&&this.overlay!==e&&(this.overlay&&this.overlay.removeController(this),this._overlay=e,this.overlay.addController(this),this.initOverlay(),this.prepareDescription(this.target),(t=this.handleOverlayReady)==null||t.call(this,this.overlay))}prepareDescription(e){}releaseDescription(){}shouldCompleteOpen(){}init(){}initOverlay(){}abort(){var e;this.releaseDescription(),(e=this.abortController)==null||e.abort()}hostConnected(){this.init()}hostDisconnected(){this.isPersistent||this.abort()}}class ee extends I{constructor(){super(...arguments),this.type=T.click,this.preventNextToggle=!1}handleClick(){this.preventNextToggle||(this.open=!this.open),this.preventNextToggle=!1}handlePointerdown(){this.preventNextToggle=this.open}init(){var t;(t=this.abortController)==null||t.abort(),this.abortController=new AbortController;const{signal:e}=this.abortController;this.target.addEventListener("click",()=>this.handleClick(),{signal:e}),this.target.addEventListener("pointerdown",()=>this.handlePointerdown(),{signal:e})}}const Te=300;class te extends I{constructor(){super(...arguments),this.type=T.hover,this.elementIds=[],this.focusedin=!1,this.pointerentered=!1}handleKeyup(e){(e.code==="Tab"||e.code==="Escape")&&(this.open=!0,this.removeSafariFocusRingClass())}handleTargetFocusin(){if(this.target.matches(":focus-visible")){if(k.isWebKit()&&this.target[_]===T.click){this.target.classList.add(z);return}this.open=!0,this.focusedin=!0,this.removeSafariFocusRingClass()}}handleTargetFocusout(){this.removeSafariFocusRingClass(),this.focusedin=!1,!this.pointerentered&&(this.open=!1)}handleTargetPointerenter(){var e;this.hoverTimeout&&(clearTimeout(this.hoverTimeout),this.hoverTimeout=void 0),!((e=this.overlay)!=null&&e.disabled)&&(this.open=!0,this.pointerentered=!0)}handleTargetPointerleave(){this.doPointerleave()}handleHostPointerenter(){this.hoverTimeout&&(clearTimeout(this.hoverTimeout),this.hoverTimeout=void 0)}handleHostPointerleave(){this.doPointerleave()}prepareDescription(){if(this.overlay.elements.length===0)return;const e=this.target.getRootNode(),t=this.overlay.elements[0].getRootNode(),i=this.overlay.getRootNode();e===i?this.prepareOverlayRelativeDescription():e===t&&this.prepareContentRelativeDescription()}prepareOverlayRelativeDescription(){const e=H.conditionAttributeWithId(this.target,"aria-describedby",[this.overlay.id]);this.releaseDescription=()=>{e(),this.releaseDescription=E}}prepareContentRelativeDescription(){const e=[],t=this.overlay.elements.map(s=>(e.push(s.id),s.id||(s.id=`${this.overlay.tagName.toLowerCase()}-helper-${M.randomID()}`),s.id));this.elementIds=e;const i=H.conditionAttributeWithId(this.target,"aria-describedby",t);this.releaseDescription=()=>{i(),this.overlay.elements.map((s,n)=>{s.id=this.elementIds[n]}),this.releaseDescription=E}}doPointerleave(){this.pointerentered=!1;const e=this.target;this.focusedin&&e.matches(":focus-visible")||(this.hoverTimeout=setTimeout(()=>{this.open=!1},Te))}init(){var t;(t=this.abortController)==null||t.abort(),this.abortController=new AbortController;const{signal:e}=this.abortController;this.target.addEventListener("keyup",i=>this.handleKeyup(i),{signal:e}),this.target.addEventListener("focusin",()=>this.handleTargetFocusin(),{signal:e}),this.target.addEventListener("focusout",()=>this.handleTargetFocusout(),{signal:e}),this.target.addEventListener("pointerenter",()=>this.handleTargetPointerenter(),{signal:e}),this.target.addEventListener("pointerleave",()=>this.handleTargetPointerleave(),{signal:e}),this.overlay&&this.initOverlay()}initOverlay(){if(!this.abortController)return;const{signal:e}=this.abortController;this.overlay.addEventListener("pointerenter",()=>this.handleHostPointerenter(),{signal:e}),this.overlay.addEventListener("pointerleave",()=>this.handleHostPointerleave(),{signal:e})}removeSafariFocusRingClass(){k.isWebKit()&&this.target.classList.contains(z)&&this.target.classList.remove(z)}}const Oe=300,ie={touch:"Double tap and long press for additional options",keyboard:"Press Space or Alt+Down Arrow for additional options",mouse:"Click and hold for additional options"};class se extends I{constructor(){super(...arguments),this.type=T.longpress,this.longpressState=null,this.releaseDescription=E,this.handlePointerup=()=>{var e;clearTimeout(this.timeout),this.target&&(this.longpressState=((e=this.overlay)==null?void 0:e.state)==="opening"?"pressed":null,document.removeEventListener("pointerup",this.handlePointerup),document.removeEventListener("pointercancel",this.handlePointerup))}}get activelyOpening(){return this.longpressState==="opening"||this.longpressState==="pressed"}handleLongpress(){this.open=!0,this.longpressState=this.longpressState==="potential"?"opening":"pressed"}handlePointerdown(e){!this.target||e.button!==0||(this.longpressState="potential",document.addEventListener("pointerup",this.handlePointerup),document.addEventListener("pointercancel",this.handlePointerup),"holdAffordance"in this.target)||(this.timeout=setTimeout(()=>{this.target&&this.target.dispatchEvent(new CustomEvent("longpress",{bubbles:!0,composed:!0,detail:{source:"pointer"}}))},Oe))}handleKeydown(e){const{code:t,altKey:i}=e;i&&t==="ArrowDown"&&(e.stopPropagation(),e.stopImmediatePropagation())}handleKeyup(e){const{code:t,altKey:i}=e;if(t==="Space"||i&&t==="ArrowDown"){if(!this.target)return;e.stopPropagation(),this.target.dispatchEvent(new CustomEvent("longpress",{bubbles:!0,composed:!0,detail:{source:"keyboard"}})),setTimeout(()=>{this.longpressState=null})}}prepareDescription(e){if(this.releaseDescription!==E||this.overlay.elements.length===0)return;const t=document.createElement("div");t.id=`longpress-describedby-descriptor-${M.randomID()}`;const i=k.isIOS()||k.isAndroid()?"touch":"keyboard";t.textContent=ie[i],t.slot="longpress-describedby-descriptor";const s=e.getRootNode(),n=this.overlay.getRootNode();s===n?this.overlay.append(t):(t.hidden=!("host"in s),e.after(t));const r=H.conditionAttributeWithId(e,"aria-describedby",[t.id]);this.releaseDescription=()=>{r(),t.remove(),this.releaseDescription=E}}shouldCompleteOpen(){this.longpressState=this.longpressState==="pressed"?null:this.longpressState}init(){var t;(t=this.abortController)==null||t.abort(),this.abortController=new AbortController;const{signal:e}=this.abortController;this.target.addEventListener("longpress",()=>this.handleLongpress(),{signal:e}),this.target.addEventListener("pointerdown",i=>this.handlePointerdown(i),{signal:e}),this.prepareDescription(this.target),!this.target.holdAffordance&&(this.target.addEventListener("keydown",i=>this.handleKeydown(i),{signal:e}),this.target.addEventListener("keyup",i=>this.handleKeyup(i),{signal:e}))}}const oe={click:ee,longpress:se,hover:te};var De=Object.defineProperty,Se=Object.getOwnPropertyDescriptor,m=(a,e,t,i)=>{for(var s=i>1?void 0:i?Se(e,t):e,n=a.length-1,r;n>=0;n--)(r=a[n])&&(s=(i?r(e,t,s):r(s))||s);return i&&s&&De(e,t,s),s};const xe=typeof document<"u"&&"showPopover"in document.createElement("div");let F=me(C);F=xe?ve(F):ge(F);var w;const d=(w=class extends F{constructor(){super(...arguments),this._delayed=!1,this._disabled=!1,this.offset=0,this._open=!1,this.lastRequestSlottableState=!1,this.receivesFocus="auto",this._state="closed",this.triggerElement=null,this.type="auto",this.wasOpen=!1,this.closeOnFocusOut=e=>{if(!e.relatedTarget)return;const t=new Event("overlay-relation-query",{bubbles:!0,composed:!0});e.relatedTarget.addEventListener(t.type,i=>{i.composedPath().includes(this)||(this.open=!1)}),e.relatedTarget.dispatchEvent(t)}}get delayed(){var e;return((e=this.elements.at(-1))==null?void 0:e.hasAttribute("delayed"))||this._delayed}set delayed(e){this._delayed=e}get disabled(){return this._disabled}set disabled(e){var t;this._disabled=e,e?((t=this.strategy)==null||t.abort(),this.wasOpen=this.open,this.open=!1):(this.bindEvents(),this.open=this.open||this.wasOpen,this.wasOpen=!1)}get hasNonVirtualTrigger(){return!!this.triggerElement&&!(this.triggerElement instanceof x)}get placementController(){return this._placementController||(this._placementController=new Z(this)),this._placementController}get open(){return this._open}set open(e){var t;e&&this.disabled||e!==this.open&&((t=this.strategy)!=null&&t.activelyOpening&&!e||(this._open=e,this.open&&(w.openCount+=1),this.requestUpdate("open",!this.open),this.open&&this.requestSlottable()))}get state(){return this._state}set state(e){var i;if(e===this.state)return;const t=this.state;this._state=e,(this.state==="opened"||this.state==="closed")&&((i=this.strategy)==null||i.shouldCompleteOpen()),this.requestUpdate("state",t)}get elementResolver(){return this._elementResolver||(this._elementResolver=new Y.ElementResolutionController(this)),this._elementResolver}get usesDialog(){return this.type==="modal"||this.type==="page"}get popoverValue(){if("popover"in this)switch(this.type){case"modal":case"page":return;case"hint":return"manual";default:return this.type}}get requiresPositioning(){return!(this.type==="page"||!this.open||!this.triggerElement||!this.placement&&this.type!=="hint")}managePosition(){if(!this.requiresPositioning||!this.open)return;const e=this.offset||0,t=this.triggerElement,i=this.placement||"right",s=this.tipPadding;this.placementController.placeOverlay(this.dialogEl,{offset:e,placement:i,tipPadding:s,trigger:t,type:this.type})}async managePopoverOpen(){super.managePopoverOpen();const e=this.open;if(this.open!==e||(await this.manageDelay(e),this.open!==e)||(this.triggerInteraction==="longpress"&&await f(),await this.ensureOnDOM(e),this.open!==e))return;const t=await this.makeTransition(e);this.open===e&&await this.applyFocus(e,t)}async applyFocus(e,t){if(!(this.receivesFocus==="false"||this.type==="hint")){if(await f(),await f(),e===this.open&&!this.open){this.hasNonVirtualTrigger&&this.contains(this.getRootNode().activeElement)&&this.triggerElement.focus();return}t==null||t.focus()}}returnFocus(){var t;if(this.open||this.type==="hint")return;const e=()=>{var n,r;const i=[];let s=typeof document<"u"?document.activeElement:null;for(;(n=s==null?void 0:s.shadowRoot)!=null&&n.activeElement;)s=s.shadowRoot.activeElement;for(;s;){const o=s.assignedSlot||s.parentElement||((r=s.getRootNode())==null?void 0:r.host);o&&i.push(o),s=o}return i};this.receivesFocus!=="false"&&((t=this.triggerElement)!=null&&t.focus)&&(this.contains(this.getRootNode().activeElement)||e().includes(this)||typeof document<"u"&&document.activeElement===document.body)&&this.triggerElement.focus()}async manageOpen(e){if(!(!this.isConnected&&this.open)&&(this.hasUpdated||await this.updateComplete,this.open?(X.add(this),this.willPreventClose&&(document.addEventListener("pointerup",()=>{this.dialogEl.classList.toggle("not-immediately-closable",!1),this.willPreventClose=!1},{once:!0}),this.dialogEl.classList.toggle("not-immediately-closable",!0))):(e&&this.dispose(),X.remove(this)),this.open&&this.state!=="opened"?this.state="opening":!this.open&&this.state!=="closed"&&(this.state="closing"),this.usesDialog?this.manageDialogOpen():this.managePopoverOpen(),this.type==="auto")){const t=this.getRootNode();this.open?t.addEventListener("focusout",this.closeOnFocusOut,{capture:!0}):t.removeEventListener("focusout",this.closeOnFocusOut,{capture:!0})}}bindEvents(){var e;(e=this.strategy)==null||e.abort(),this.strategy=void 0,this.hasNonVirtualTrigger&&this.triggerInteraction&&(this.strategy=new oe[this.triggerInteraction](this.triggerElement,{overlay:this}))}handleBeforetoggle(e){e.newState!=="open"&&this.handleBrowserClose(e)}handleBrowserClose(e){var t;if(e.stopPropagation(),!((t=this.strategy)!=null&&t.activelyOpening)){this.open=!1;return}this.manuallyKeepOpen()}manuallyKeepOpen(){this.open=!0,this.placementController.allowPlacementUpdate=!0,this.manageOpen(!1)}handleSlotchange(){var e,t;this.elements.length===0?(e=this.strategy)==null||e.releaseDescription():this.hasNonVirtualTrigger&&((t=this.strategy)==null||t.prepareDescription(this.triggerElement))}shouldPreventClose(){const e=this.willPreventClose;return this.willPreventClose=!1,e}requestSlottable(){this.lastRequestSlottableState!==this.open&&(this.open||document.body.offsetHeight,this.dispatchEvent(new J.SlottableRequestEvent("overlay-content",this.open?{}:J.removeSlottableRequest)),this.lastRequestSlottableState=this.open)}willUpdate(e){var i;if(this.hasAttribute("id")||this.setAttribute("id",`${this.tagName.toLowerCase()}-${M.randomID()}`),e.has("open")&&(this.hasUpdated||this.open)&&this.manageOpen(e.get("open")),e.has("trigger")){const[s,n]=((i=this.trigger)==null?void 0:i.split("@"))||[];this.elementResolver.selector=s?`#${s}`:"",this.triggerInteraction=n}let t=!1;e.has(Y.elementResolverUpdatedSymbol)&&(t=this.triggerElement,this.triggerElement=this.elementResolver.element),e.has("triggerElement")&&(t=e.get("triggerElement")),t!==!1&&this.bindEvents()}updated(e){super.updated(e),e.has("placement")&&(this.placement?this.dialogEl.setAttribute("actual-placement",this.placement):this.dialogEl.removeAttribute("actual-placement"),this.open&&e.get("placement")!==void 0&&this.placementController.resetOverlayPosition()),e.has("state")&&this.state==="closed"&&e.get("state")!==void 0&&this.placementController.clearOverlayPosition()}renderContent(){return O.html` <slot @slotchange=${this.handleSlotchange}></slot> `}get dialogStyleMap(){return{"--luzmo-overlay-open-count":w.openCount.toString()}}renderDialog(){return O.html`
19
19
  <dialog
20
20
  class="dialog"
21
21
  part="dialog"
@@ -21,7 +21,7 @@ import { ifDefined as k } from "lit/directives/if-defined.js";
21
21
  import { styleMap as V } from "lit/directives/style-map.js";
22
22
  import { r as I } from "./random-id-ByCz1xaq.js";
23
23
  import { E as oe, e as ne } from "./element-resolution-FCUT-wql.js";
24
- import { a as re } from "./base-CdYjmV_8.js";
24
+ import { a as re } from "./base-BUViEg_7.js";
25
25
  import { u as O } from "./focusable-selectors-B4YgbghQ.js";
26
26
  import { autoUpdate as j, flip as G, offset as ae, shift as le, size as he, arrow as ce, computePosition as pe } from "@floating-ui/dom";
27
27
  import { S as de, r as ue } from "./slottable-request-event-DggLA4Rx.js";
@@ -15,7 +15,7 @@
15
15
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
16
  * SOFTWARE.
17
17
  * */
18
- "use strict";const s=require("lit");require("./progress-circle-DgMbqrzG.cjs");class r{constructor(e){this.cachedAriaLabel=null,this.host=e,this.host.addController(this)}renderPendingState(){const e=this.host.pendingLabel||"Pending";return this.host.pending?s.html`
18
+ "use strict";const s=require("lit");require("./progress-circle-BMRjGc4y.cjs");class r{constructor(e){this.cachedAriaLabel=null,this.host=e,this.host.addController(this)}renderPendingState(){const e=this.host.pendingLabel||"Pending";return this.host.pending?s.html`
19
19
  <luzmo-progress-circle
20
20
  id="loader"
21
21
  size="s"
@@ -16,7 +16,7 @@
16
16
  * SOFTWARE.
17
17
  * */
18
18
  import { html as s } from "lit";
19
- import "./progress-circle-D5J0ZwY0.js";
19
+ import "./progress-circle-unckklsi.js";
20
20
  class o {
21
21
  /**
22
22
  * Creates an instance of PendingStateController.
@@ -15,4 +15,4 @@
15
15
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
16
  * SOFTWARE.
17
17
  * */
18
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../picker-DxYgh4LR.cjs");customElements.get("luzmo-picker")||customElements.define("luzmo-picker",e.LuzmoPicker);exports.DESCRIPTION_ID=e.DESCRIPTION_ID;exports.LuzmoPicker=e.LuzmoPicker;exports.LuzmoPickerBase=e.LuzmoPickerBase;
18
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../picker-B2_mjftE.cjs");customElements.get("luzmo-picker")||customElements.define("luzmo-picker",e.LuzmoPicker);exports.DESCRIPTION_ID=e.DESCRIPTION_ID;exports.LuzmoPicker=e.LuzmoPicker;exports.LuzmoPickerBase=e.LuzmoPickerBase;
@@ -15,8 +15,8 @@
15
15
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
16
  * SOFTWARE.
17
17
  * */
18
- import { a as r } from "../picker-Cm6_didQ.js";
19
- import { D as c, L as z } from "../picker-Cm6_didQ.js";
18
+ import { a as r } from "../picker-DbOS1rE7.js";
19
+ import { D as c, L as z } from "../picker-DbOS1rE7.js";
20
20
  const l = () => {
21
21
  if (typeof document < "u" && !document.querySelector("style[data-luzmo-vars]")) {
22
22
  const o = document.createElement("style");