@m3e/web 2.0.5 → 2.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (137) hide show
  1. package/dist/all.js +801 -473
  2. package/dist/all.js.map +1 -1
  3. package/dist/all.min.js +52 -58
  4. package/dist/all.min.js.map +1 -1
  5. package/dist/autocomplete.js +342 -69
  6. package/dist/autocomplete.js.map +1 -1
  7. package/dist/autocomplete.min.js +1 -1
  8. package/dist/autocomplete.min.js.map +1 -1
  9. package/dist/chips.js +18 -4
  10. package/dist/chips.js.map +1 -1
  11. package/dist/chips.min.js +1 -1
  12. package/dist/chips.min.js.map +1 -1
  13. package/dist/core-a11y.js +3 -118
  14. package/dist/core-a11y.js.map +1 -1
  15. package/dist/core-a11y.min.js +13 -4
  16. package/dist/core-a11y.min.js.map +1 -1
  17. package/dist/core-anchoring.js +193 -1
  18. package/dist/core-anchoring.js.map +1 -1
  19. package/dist/core-anchoring.min.js +1 -1
  20. package/dist/core-anchoring.min.js.map +1 -1
  21. package/dist/core.js +147 -91
  22. package/dist/core.js.map +1 -1
  23. package/dist/core.min.js +1 -1
  24. package/dist/core.min.js.map +1 -1
  25. package/dist/css-custom-data.json +408 -328
  26. package/dist/custom-elements.json +5820 -4150
  27. package/dist/html-custom-data.json +174 -99
  28. package/dist/loading-indicator.js +1 -0
  29. package/dist/loading-indicator.js.map +1 -1
  30. package/dist/loading-indicator.min.js +1 -1
  31. package/dist/loading-indicator.min.js.map +1 -1
  32. package/dist/menu.js +1 -1
  33. package/dist/menu.js.map +1 -1
  34. package/dist/menu.min.js +1 -1
  35. package/dist/menu.min.js.map +1 -1
  36. package/dist/option.js +94 -121
  37. package/dist/option.js.map +1 -1
  38. package/dist/option.min.js +1 -1
  39. package/dist/option.min.js.map +1 -1
  40. package/dist/progress-indicator.js +2 -0
  41. package/dist/progress-indicator.js.map +1 -1
  42. package/dist/progress-indicator.min.js +2 -2
  43. package/dist/progress-indicator.min.js.map +1 -1
  44. package/dist/select.js +59 -23
  45. package/dist/select.js.map +1 -1
  46. package/dist/select.min.js +1 -1
  47. package/dist/select.min.js.map +1 -1
  48. package/dist/src/autocomplete/AutocompleteElement.d.ts +71 -2
  49. package/dist/src/autocomplete/AutocompleteElement.d.ts.map +1 -1
  50. package/dist/src/autocomplete/AutocompleteFilterMode.d.ts +3 -0
  51. package/dist/src/autocomplete/AutocompleteFilterMode.d.ts.map +1 -0
  52. package/dist/src/autocomplete/QueryEventDetail.d.ts +12 -0
  53. package/dist/src/autocomplete/QueryEventDetail.d.ts.map +1 -0
  54. package/dist/src/autocomplete/index.d.ts +2 -0
  55. package/dist/src/autocomplete/index.d.ts.map +1 -1
  56. package/dist/src/chips/ChipElement.d.ts +2 -0
  57. package/dist/src/chips/ChipElement.d.ts.map +1 -1
  58. package/dist/src/chips/InputChipSetChangeEventDetail.d.ts +13 -0
  59. package/dist/src/chips/InputChipSetChangeEventDetail.d.ts.map +1 -0
  60. package/dist/src/chips/InputChipSetElement.d.ts +10 -0
  61. package/dist/src/chips/InputChipSetElement.d.ts.map +1 -1
  62. package/dist/src/chips/index.d.ts +1 -0
  63. package/dist/src/chips/index.d.ts.map +1 -1
  64. package/dist/src/core/a11y/FocusTrapElement.d.ts +1 -1
  65. package/dist/src/core/a11y/list-key/ListKeyManager.d.ts.map +1 -1
  66. package/dist/src/core/a11y/list-key/RadioKeyManager.d.ts +1 -2
  67. package/dist/src/core/a11y/list-key/RadioKeyManager.d.ts.map +1 -1
  68. package/dist/src/core/a11y/list-key/SelectionManager.d.ts +1 -2
  69. package/dist/src/core/a11y/list-key/SelectionManager.d.ts.map +1 -1
  70. package/dist/src/core/a11y/list-key/Typeahead.d.ts.map +1 -1
  71. package/dist/src/core/anchoring/FloatingPanelElement.d.ts +74 -0
  72. package/dist/src/core/anchoring/FloatingPanelElement.d.ts.map +1 -0
  73. package/dist/src/core/anchoring/index.d.ts +1 -0
  74. package/dist/src/core/anchoring/index.d.ts.map +1 -1
  75. package/dist/src/core/shared/controllers/MutationController.d.ts.map +1 -1
  76. package/dist/src/core/shared/controllers/ResizeController.d.ts.map +1 -1
  77. package/dist/src/core/shared/mixins/AttachInternals.d.ts.map +1 -1
  78. package/dist/src/core/shared/primitives/TextHighlightElement.d.ts +9 -2
  79. package/dist/src/core/shared/primitives/TextHighlightElement.d.ts.map +1 -1
  80. package/dist/src/core/shared/primitives/TextHighlightMode.d.ts +3 -0
  81. package/dist/src/core/shared/primitives/TextHighlightMode.d.ts.map +1 -0
  82. package/dist/src/core/shared/primitives/index.d.ts +2 -1
  83. package/dist/src/core/shared/primitives/index.d.ts.map +1 -1
  84. package/dist/src/loading-indicator/LoadingIndicatorElement.d.ts.map +1 -1
  85. package/dist/src/menu/MenuItemElementBase.d.ts.map +1 -1
  86. package/dist/src/option/OptionElement.d.ts +21 -1
  87. package/dist/src/option/OptionElement.d.ts.map +1 -1
  88. package/dist/src/option/OptionPanelElement.d.ts +11 -34
  89. package/dist/src/option/OptionPanelElement.d.ts.map +1 -1
  90. package/dist/src/option/OptionPanelState.d.ts +3 -0
  91. package/dist/src/option/OptionPanelState.d.ts.map +1 -0
  92. package/dist/src/option/index.d.ts +1 -0
  93. package/dist/src/option/index.d.ts.map +1 -1
  94. package/dist/src/progress-indicator/CircularProgressIndicatorElement.d.ts.map +1 -1
  95. package/dist/src/progress-indicator/LinearProgressIndicatorElement.d.ts.map +1 -1
  96. package/dist/src/select/SelectElement.d.ts +3 -2
  97. package/dist/src/select/SelectElement.d.ts.map +1 -1
  98. package/dist/src/toc/TocElement.d.ts.map +1 -1
  99. package/dist/toc.js +0 -1
  100. package/dist/toc.js.map +1 -1
  101. package/dist/toc.min.js +1 -1
  102. package/dist/toc.min.js.map +1 -1
  103. package/package.json +1 -1
  104. package/dist/datepicker.js +0 -2346
  105. package/dist/datepicker.js.map +0 -1
  106. package/dist/datepicker.min.js +0 -102
  107. package/dist/datepicker.min.js.map +0 -1
  108. package/dist/src/core/shared/decorators/component.d.ts +0 -19
  109. package/dist/src/core/shared/decorators/component.d.ts.map +0 -1
  110. package/dist/src/core/shared/decorators/element.d.ts +0 -19
  111. package/dist/src/core/shared/decorators/element.d.ts.map +0 -1
  112. package/dist/src/core/shared/utils/getState.d.ts +0 -15
  113. package/dist/src/core/shared/utils/getState.d.ts.map +0 -1
  114. package/dist/src/datepicker/CalendarElement.d.ts +0 -203
  115. package/dist/src/datepicker/CalendarElement.d.ts.map +0 -1
  116. package/dist/src/datepicker/CalendarView.d.ts +0 -3
  117. package/dist/src/datepicker/CalendarView.d.ts.map +0 -1
  118. package/dist/src/datepicker/CalendarViewElementBase.d.ts +0 -28
  119. package/dist/src/datepicker/CalendarViewElementBase.d.ts.map +0 -1
  120. package/dist/src/datepicker/DateAdapter.d.ts +0 -4
  121. package/dist/src/datepicker/DateAdapter.d.ts.map +0 -1
  122. package/dist/src/datepicker/DatepickerElement.d.ts +0 -180
  123. package/dist/src/datepicker/DatepickerElement.d.ts.map +0 -1
  124. package/dist/src/datepicker/DatepickerToggleElement.d.ts +0 -21
  125. package/dist/src/datepicker/DatepickerToggleElement.d.ts.map +0 -1
  126. package/dist/src/datepicker/DatepickerVariant.d.ts +0 -3
  127. package/dist/src/datepicker/DatepickerVariant.d.ts.map +0 -1
  128. package/dist/src/datepicker/MonthViewElement.d.ts +0 -35
  129. package/dist/src/datepicker/MonthViewElement.d.ts.map +0 -1
  130. package/dist/src/datepicker/MultiYearViewElement.d.ts +0 -27
  131. package/dist/src/datepicker/MultiYearViewElement.d.ts.map +0 -1
  132. package/dist/src/datepicker/YearViewElement.d.ts +0 -27
  133. package/dist/src/datepicker/YearViewElement.d.ts.map +0 -1
  134. package/dist/src/datepicker/index.d.ts +0 -10
  135. package/dist/src/datepicker/index.d.ts.map +0 -1
  136. package/dist/src/datepicker/utils.d.ts +0 -26
  137. package/dist/src/datepicker/utils.d.ts.map +0 -1
@@ -3,7 +3,7 @@
3
3
  * Copyright (c) 2025 matraic
4
4
  * See LICENSE file in the project root for full license text.
5
5
  */
6
- import{property as t,query as e}from"lit/decorators.js";import{isServer as i,html as s,css as n,LitElement as a}from"lit";function r(t,e,i,s){var n,a=arguments.length,r=a<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var o=t.length-1;o>=0;o--)(n=t[o])&&(r=(a<3?n(r):a>3?n(e,i,r):n(e,i))||r);return a>3&&r&&Object.defineProperty(e,i,r),r}function o(t,e,i,s){if("a"===i&&!s)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!s:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===i?s:"a"===i?s.call(t):s?s.value:e.get(t)}function h(t,e,i,s,n){if("m"===s)throw new TypeError("Private method is not writable");if("a"===s&&!n)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof e?t!==e||!n:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===s?n.call(t,i):n?n.value=i:e.set(t,i),i}"function"==typeof SuppressedError&&SuppressedError;const c=["alt","shift","ctrl","meta"];var l,d,u,f,m,p,v,g,w,b,y,A,k,I;function E(t){return t.which||t.charCode||t.keyCode}function S(t,...e){return e.length?e.some(e=>t[`${e}Key`]):t.altKey||t.shiftKey||t.ctrlKey||t.metaKey}function D(t,...e){return c.every(i=>!S(t,i)||e.includes(i))}function N(t,...e){return"object"==typeof t&&null!==t&&e.every(e=>e in t)}!function(t){t[t.Backspace=8]="Backspace",t[t.Tab=9]="Tab",t[t.Enter=13]="Enter",t[t.Shift=16]="Shift",t[t.Ctrl=17]="Ctrl",t[t.Alt=18]="Alt",t[t.PauseBreak=19]="PauseBreak",t[t.CapsLock=20]="CapsLock",t[t.Escape=27]="Escape",t[t.Space=32]="Space",t[t.PageUp=33]="PageUp",t[t.PageDown=34]="PageDown",t[t.End=35]="End",t[t.Home=36]="Home",t[t.LeftArrow=37]="LeftArrow",t[t.UpArrow=38]="UpArrow",t[t.RightArrow=39]="RightArrow",t[t.DownArrow=40]="DownArrow",t[t.Insert=45]="Insert",t[t.Delete=46]="Delete",t[t.Zero=48]="Zero",t[t.ClosedParen=48]="ClosedParen",t[t.One=49]="One",t[t.ExclamationMark=49]="ExclamationMark",t[t.Two=50]="Two",t[t.AtSign=50]="AtSign",t[t.Three=51]="Three",t[t.PoundSign=51]="PoundSign",t[t.Hash=51]="Hash",t[t.Four=52]="Four",t[t.DollarSign=52]="DollarSign",t[t.Five=53]="Five",t[t.PercentSign=53]="PercentSign",t[t.Six=54]="Six",t[t.Caret=54]="Caret",t[t.Hat=54]="Hat",t[t.Seven=55]="Seven",t[t.Ampersand=55]="Ampersand",t[t.Eight=56]="Eight",t[t.Star=56]="Star",t[t.Asterik=56]="Asterik",t[t.Nine=57]="Nine",t[t.OpenParen=57]="OpenParen",t[t.A=65]="A",t[t.B=66]="B",t[t.C=67]="C",t[t.D=68]="D",t[t.E=69]="E",t[t.F=70]="F",t[t.G=71]="G",t[t.H=72]="H",t[t.I=73]="I",t[t.J=74]="J",t[t.K=75]="K",t[t.L=76]="L",t[t.M=77]="M",t[t.N=78]="N",t[t.O=79]="O",t[t.P=80]="P",t[t.Q=81]="Q",t[t.R=82]="R",t[t.S=83]="S",t[t.T=84]="T",t[t.U=85]="U",t[t.V=86]="V",t[t.W=87]="W",t[t.X=88]="X",t[t.Y=89]="Y",t[t.Z=90]="Z",t[t.LeftWindowKey=91]="LeftWindowKey",t[t.RightWindowKey=92]="RightWindowKey",t[t.SelectKey=93]="SelectKey",t[t.Numpad0=96]="Numpad0",t[t.Numpad1=97]="Numpad1",t[t.Numpad2=98]="Numpad2",t[t.Numpad3=99]="Numpad3",t[t.Numpad4=100]="Numpad4",t[t.Numpad5=101]="Numpad5",t[t.Numpad6=102]="Numpad6",t[t.Numpad7=103]="Numpad7",t[t.Numpad8=104]="Numpad8",t[t.Numpad9=105]="Numpad9",t[t.Multiply=106]="Multiply",t[t.Add=107]="Add",t[t.Subtract=109]="Subtract",t[t.DecimalPoint=110]="DecimalPoint",t[t.Divide=111]="Divide",t[t.F1=112]="F1",t[t.F2=113]="F2",t[t.F3=114]="F3",t[t.F4=115]="F4",t[t.F5=116]="F5",t[t.F6=117]="F6",t[t.F7=118]="F7",t[t.F8=119]="F8",t[t.F9=120]="F9",t[t.F10=121]="F10",t[t.F11=122]="F11",t[t.F12=123]="F12",t[t.NumLock=144]="NumLock",t[t.ScrollLock=145]="ScrollLock",t[t.SemiColon=186]="SemiColon",t[t.Equals=187]="Equals",t[t.Comma=188]="Comma",t[t.Dash=189]="Dash",t[t.Period=190]="Period",t[t.UnderScore=189]="UnderScore",t[t.PlusSign=187]="PlusSign",t[t.ForwardSlash=191]="ForwardSlash",t[t.Tilde=192]="Tilde",t[t.GraveAccent=192]="GraveAccent",t[t.OpenBracket=219]="OpenBracket",t[t.ClosedBracket=221]="ClosedBracket",t[t.Quote=222]="Quote"}(l||(l={}));class P{constructor(){d.set(this,new Array),u.set(this,null),f.set(this,void 0)}get items(){return o(this,d,"f")}get activeItem(){return o(this,u,"f")}setItems(t){const e=this.items.filter(e=>!t.includes(e)),i=t.filter(t=>!this.items.includes(t));return h(this,d,t,"f"),this.activeItem&&!this.items.includes(this.activeItem)&&this.updateActiveItem(null),{added:i,removed:e}}setActiveItem(t){this.activeItem!==t&&(this.updateActiveItem(t),o(this,f,"f")?.call(this))}updateActiveItem(t){h(this,u,t??null,"f")}onActiveItemChange(t){return h(this,f,t,"f"),this}}d=new WeakMap,u=new WeakMap,f=new WeakMap;const M=Symbol("typeaheadLabel");function T(t){return N(t,M)}class x{constructor(t){m.add(this),p.set(this,void 0),v.set(this,-1),g.set(this,void 0),w.set(this,void 0),b.set(this,new Array),y.set(this,-1),A.set(this,[]),h(this,p,t.debounceInterval??200,"f"),h(this,g,t.callback,"f"),h(this,w,t.skipPredicate,"f")}get isTyping(){return o(this,b,"f").length>0}setItems(t){h(this,A,t,"f")}setSelectedIndex(t){h(this,y,t,"f")}reset(){o(this,b,"f").length=0}onKeyDown(t){if(t.key&&1===t.key.length)o(this,m,"m",k).call(this,t.key);else{const e=E(t);(e>=l.A&&e<=l.Z||e>=l.Zero&&e<=l.Nine)&&o(this,m,"m",k).call(this,String.fromCharCode(e))}}}
6
+ import{hasKeys as t,isDisabledMixin as e,isCheckedOrSelected as i,checkOrSelect as s,Disabled as n,customElement as a}from"@m3e/web/core";import{isServer as r,LitElement as o,html as h,css as c}from"lit";import{query as l}from"lit/decorators.js";function d(t,e,i,s){var n,a=arguments.length,r=a<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var o=t.length-1;o>=0;o--)(n=t[o])&&(r=(a<3?n(r):a>3?n(e,i,r):n(e,i))||r);return a>3&&r&&Object.defineProperty(e,i,r),r}function u(t,e,i,s){if("a"===i&&!s)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!s:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===i?s:"a"===i?s.call(t):s?s.value:e.get(t)}function m(t,e,i,s,n){if("m"===s)throw new TypeError("Private method is not writable");if("a"===s&&!n)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof e?t!==e||!n:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===s?n.call(t,i):n?n.value=i:e.set(t,i),i}"function"==typeof SuppressedError&&SuppressedError;const f=["alt","shift","ctrl","meta"];var p,v,g,w,b,A,y,k,I,E,S,D,N,P;function M(t){return t.which||t.charCode||t.keyCode}function T(t,...e){return e.length?e.some(e=>t[`${e}Key`]):t.altKey||t.shiftKey||t.ctrlKey||t.metaKey}function x(t,...e){return f.every(i=>!T(t,i)||e.includes(i))}!function(t){t[t.Backspace=8]="Backspace",t[t.Tab=9]="Tab",t[t.Enter=13]="Enter",t[t.Shift=16]="Shift",t[t.Ctrl=17]="Ctrl",t[t.Alt=18]="Alt",t[t.PauseBreak=19]="PauseBreak",t[t.CapsLock=20]="CapsLock",t[t.Escape=27]="Escape",t[t.Space=32]="Space",t[t.PageUp=33]="PageUp",t[t.PageDown=34]="PageDown",t[t.End=35]="End",t[t.Home=36]="Home",t[t.LeftArrow=37]="LeftArrow",t[t.UpArrow=38]="UpArrow",t[t.RightArrow=39]="RightArrow",t[t.DownArrow=40]="DownArrow",t[t.Insert=45]="Insert",t[t.Delete=46]="Delete",t[t.Zero=48]="Zero",t[t.ClosedParen=48]="ClosedParen",t[t.One=49]="One",t[t.ExclamationMark=49]="ExclamationMark",t[t.Two=50]="Two",t[t.AtSign=50]="AtSign",t[t.Three=51]="Three",t[t.PoundSign=51]="PoundSign",t[t.Hash=51]="Hash",t[t.Four=52]="Four",t[t.DollarSign=52]="DollarSign",t[t.Five=53]="Five",t[t.PercentSign=53]="PercentSign",t[t.Six=54]="Six",t[t.Caret=54]="Caret",t[t.Hat=54]="Hat",t[t.Seven=55]="Seven",t[t.Ampersand=55]="Ampersand",t[t.Eight=56]="Eight",t[t.Star=56]="Star",t[t.Asterik=56]="Asterik",t[t.Nine=57]="Nine",t[t.OpenParen=57]="OpenParen",t[t.A=65]="A",t[t.B=66]="B",t[t.C=67]="C",t[t.D=68]="D",t[t.E=69]="E",t[t.F=70]="F",t[t.G=71]="G",t[t.H=72]="H",t[t.I=73]="I",t[t.J=74]="J",t[t.K=75]="K",t[t.L=76]="L",t[t.M=77]="M",t[t.N=78]="N",t[t.O=79]="O",t[t.P=80]="P",t[t.Q=81]="Q",t[t.R=82]="R",t[t.S=83]="S",t[t.T=84]="T",t[t.U=85]="U",t[t.V=86]="V",t[t.W=87]="W",t[t.X=88]="X",t[t.Y=89]="Y",t[t.Z=90]="Z",t[t.LeftWindowKey=91]="LeftWindowKey",t[t.RightWindowKey=92]="RightWindowKey",t[t.SelectKey=93]="SelectKey",t[t.Numpad0=96]="Numpad0",t[t.Numpad1=97]="Numpad1",t[t.Numpad2=98]="Numpad2",t[t.Numpad3=99]="Numpad3",t[t.Numpad4=100]="Numpad4",t[t.Numpad5=101]="Numpad5",t[t.Numpad6=102]="Numpad6",t[t.Numpad7=103]="Numpad7",t[t.Numpad8=104]="Numpad8",t[t.Numpad9=105]="Numpad9",t[t.Multiply=106]="Multiply",t[t.Add=107]="Add",t[t.Subtract=109]="Subtract",t[t.DecimalPoint=110]="DecimalPoint",t[t.Divide=111]="Divide",t[t.F1=112]="F1",t[t.F2=113]="F2",t[t.F3=114]="F3",t[t.F4=115]="F4",t[t.F5=116]="F5",t[t.F6=117]="F6",t[t.F7=118]="F7",t[t.F8=119]="F8",t[t.F9=120]="F9",t[t.F10=121]="F10",t[t.F11=122]="F11",t[t.F12=123]="F12",t[t.NumLock=144]="NumLock",t[t.ScrollLock=145]="ScrollLock",t[t.SemiColon=186]="SemiColon",t[t.Equals=187]="Equals",t[t.Comma=188]="Comma",t[t.Dash=189]="Dash",t[t.Period=190]="Period",t[t.UnderScore=189]="UnderScore",t[t.PlusSign=187]="PlusSign",t[t.ForwardSlash=191]="ForwardSlash",t[t.Tilde=192]="Tilde",t[t.GraveAccent=192]="GraveAccent",t[t.OpenBracket=219]="OpenBracket",t[t.ClosedBracket=221]="ClosedBracket",t[t.Quote=222]="Quote"}(p||(p={}));class F{constructor(){v.set(this,new Array),g.set(this,null),w.set(this,void 0)}get items(){return u(this,v,"f")}get activeItem(){return u(this,g,"f")}setItems(t){const e=this.items.filter(e=>!t.includes(e)),i=t.filter(t=>!this.items.includes(t));return m(this,v,t,"f"),this.activeItem&&!this.items.includes(this.activeItem)&&this.updateActiveItem(null),{added:i,removed:e}}setActiveItem(t){this.activeItem!==t&&(this.updateActiveItem(t),u(this,w,"f")?.call(this))}updateActiveItem(t){m(this,g,t??null,"f")}onActiveItemChange(t){return m(this,w,t,"f"),this}}v=new WeakMap,g=new WeakMap,w=new WeakMap;const C=Symbol("typeaheadLabel");function W(e){return t(e,C)}class L{constructor(t){b.add(this),A.set(this,void 0),y.set(this,-1),k.set(this,void 0),I.set(this,void 0),E.set(this,new Array),S.set(this,-1),D.set(this,[]),m(this,A,t.debounceInterval??200,"f"),m(this,k,t.callback,"f"),m(this,I,t.skipPredicate,"f")}get isTyping(){return u(this,E,"f").length>0}setItems(t){m(this,D,t,"f")}setSelectedIndex(t){m(this,S,t,"f")}reset(){u(this,E,"f").length=0}onKeyDown(t){if(t.key&&1===t.key.length)u(this,b,"m",N).call(this,t.key);else{const e=M(t);(e>=p.A&&e<=p.Z||e>=p.Zero&&e<=p.Nine)&&u(this,b,"m",N).call(this,String.fromCharCode(e))}}}
7
7
  /**
8
8
  * Adapted from Angular Material CDK KeyManager
9
9
  * Source: https://github.com/angular/components/blob/main/src/cdk/a11y/key-manager/list-key-manager.ts
@@ -12,7 +12,7 @@ import{property as t,query as e}from"lit/decorators.js";import{isServer as i,htm
12
12
  * Copyright (c) 2025 Google LLC
13
13
  * See LICENSE file in the project root for full license text.
14
14
  */
15
- var F,C,W,L,R,O,U,K,H,B,j,$,Z,_,G,Q;p=new WeakMap,v=new WeakMap,g=new WeakMap,w=new WeakMap,b=new WeakMap,y=new WeakMap,A=new WeakMap,m=new WeakSet,k=function(t){o(this,b,"f").push(t.toLocaleUpperCase()),clearTimeout(o(this,v,"f")),h(this,v,setTimeout(()=>o(this,m,"m",I).call(this),o(this,p,"f")),"f")},I=function(){const t=o(this,b,"f").join("");for(let e=1;e<o(this,A,"f").length+1;e++){const i=(o(this,y,"f")+e)%o(this,A,"f").length,s=o(this,A,"f")[i],n=s[M]?.().toLocaleUpperCase().trim();if(!o(this,w,"f")?.call(this,s)&&0===n?.indexOf(t)){o(this,g,"f").call(this,s);break}}this.reset()};class q extends P{constructor(){super(...arguments),F.add(this),C.set(this,void 0),this.wrap=!1,this.homeAndEnd=!1,this.pageUpAndDown=!1,this.pageDelta=10,this.vertical=!1,this.allowedModifiers=[],this.skipPredicate=t=>N(t,"disabled")&&t.disabled,this.directionality="ltr"}setItems(t){return o(this,C,"f")?.setItems(t),super.setItems(t)}updateActiveItem(t){super.updateActiveItem(t),o(this,C,"f")&&o(this,C,"f").setSelectedIndex(t?this.items.indexOf(t):-1)}withHomeAndEnd(t=!0){return this.homeAndEnd=t,this}withPageUpAndDown(t=!0,e=10){return this.pageUpAndDown=t,this.pageDelta=e,this}withWrap(t=!0){return this.wrap=t,this}withVerticalOrientation(t=!0){return this.vertical=t,this}withAllowedModifiers(...t){return this.allowedModifiers=t,this}withTypeahead(t=!0){return h(this,C,t?new x({callback:t=>this.setActiveItem(t)}):void 0,"f"),this}withSkipPredicate(t){return this.skipPredicate=t,this}withDirectionality(t){return this.directionality=t,this}onKeyDown(t){if(t.defaultPrevented)return;const e=D(t,...this.allowedModifiers);switch(t.key){case"Left":case"ArrowLeft":if(e&&!this.vertical){t.preventDefault();const e="ltr"===this.directionality?o(this,F,"m",O).call(this):o(this,F,"m",R).call(this);e&&this.setActiveItem(e)}break;case"Up":case"ArrowUp":if(e){t.preventDefault();const e="ltr"===this.directionality?o(this,F,"m",O).call(this):o(this,F,"m",R).call(this);e&&this.setActiveItem(e)}break;case"Right":case"ArrowRight":if(e&&!this.vertical){t.preventDefault();const e="ltr"===this.directionality?o(this,F,"m",R).call(this):o(this,F,"m",O).call(this);e&&this.setActiveItem(e)}break;case"Down":case"ArrowDown":if(e){t.preventDefault();const e="ltr"===this.directionality?o(this,F,"m",R).call(this):o(this,F,"m",O).call(this);e&&this.setActiveItem(e)}break;case"Home":if(e&&this.homeAndEnd){t.preventDefault();const e=o(this,F,"m",W).call(this);e&&this.setActiveItem(e)}break;case"End":if(e&&this.homeAndEnd){t.preventDefault();const e=o(this,F,"m",L).call(this);e&&this.setActiveItem(e)}break;case"PageUp":if(e&&this.pageUpAndDown){t.preventDefault();const e=("ltr"===this.directionality?o(this,F,"m",U):o(this,F,"m",K))(this.activeItem?Math.max(0,this.items.indexOf(this.activeItem)-this.pageDelta):0);e&&this.setActiveItem(e)}break;case"PageDown":if(e&&this.pageUpAndDown){t.preventDefault();const e=("ltr"===this.directionality?o(this,F,"m",K):o(this,F,"m",U))(this.activeItem?Math.min(this.items.length-1,this.items.indexOf(this.activeItem)+this.pageDelta):this.items.length-1);e&&this.setActiveItem(e)}break;default:(e||S(t,"shift"))&&o(this,C,"f")?.onKeyDown(t)}}}C=new WeakMap,F=new WeakSet,W=function(){for(let t=0;t<this.items.length&&this.items[t]!==this.activeItem;t++){const e=this.items[t];if(!this.skipPredicate(e))return e}return null},L=function(){for(let t=this.items.length-1;t>=0&&this.items[t]!==this.activeItem;t--){const e=this.items[t];if(!this.skipPredicate(e))return e}return null},R=function(){for(let t=0;t<this.items.length;t++)if(this.items[t]===this.activeItem){for(let e=t+1;e<this.items.length;e++){const t=this.items[e];if(!this.skipPredicate(t))return t}break}return this.wrap?o(this,F,"m",W).call(this):null},O=function(){for(let t=0;t<this.items.length;t++)if(this.items[t]===this.activeItem){for(let e=t-1;e>=0;e--){const t=this.items[e];if(!this.skipPredicate(t))return t}break}return this.wrap?o(this,F,"m",L).call(this):null},U=function(t){for(let e=t;e>=0;e--){const t=this.items[e];if(!this.skipPredicate(t))return t}return null},K=function(t){for(let e=t;e<this.items.length;e++){const t=this.items[e];if(!this.skipPredicate(t))return t}return null};class V extends q{constructor(){super(...arguments),H.set(this,void 0)}setActiveItem(t){super.setActiveItem(t),t?.focus(o(this,H,"f"))}withOptions(t){return h(this,H,t,"f"),this}}function z(t){return N(t,"checked")}function J(t){return z(t)&&t.checked||N(t,"selected")&&t.selected}function X(t,e){z(t)?t.checked=e:t.selected=e}H=new WeakMap;class Y extends V{constructor(){super(...arguments),B.set(this,!1)}updateActiveItem(t){if(super.updateActiveItem(t),!o(this,B,"f")){t?.setAttribute("tabindex","0");for(const e of this.items)e!==t&&e.hasAttribute("tabindex")&&e.setAttribute("tabindex","-1")}}setItems(t){const e=super.setItems(t);if(!o(this,B,"f"))for(const t of e.added)t===this.activeItem||this.skipPredicate(t)||t.setAttribute("tabindex","-1");return e}disableRovingTabIndex(t=!0){if(t!==o(this,B,"f")){h(this,B,t,"f");for(const t of this.items)this.skipPredicate(t)||t?.setAttribute("tabindex",o(this,B,"f")||t===this.activeItem?"0":"-1")}return this}}B=new WeakMap;class tt extends Y{constructor(){super(...arguments),j.set(this,!1)}get disabled(){return o(this,j,"f")}set disabled(t){h(this,j,t,"f"),this.items.forEach(e=>e.disabled=t)}setItems(t){this.disabled&&t.forEach(t=>t.disabled=!0);const{added:e,removed:i}=super.setItems(t);if((e.length>0||i.length>0)&&(this.activeItem||this.updateActiveItem(e.find(t=>!this.skipPredicate(t))??null),this.activeItem&&(this.activeItem.disabled||!J(this.activeItem)))){const t=e.find(t=>!this.skipPredicate(t)&&J(t));t&&this.updateActiveItem(t)}return{added:e,removed:i}}}j=new WeakMap;const et=Symbol("selectionManager");class it extends tt{constructor(){super(...arguments),$.add(this),Z.set(this,void 0),_.set(this,new Array),G.set(this,!1)}get multi(){return o(this,G,"f")}set multi(t){h(this,G,t,"f"),o(this,$,"m",Q).call(this,!0)}get selectedItems(){return o(this,_,"f")}notifySelectionChange(t){this.items.includes(t)&&(J(t)?this.select(t):this.deselect(t))}deselect(t){if(this.items.includes(t)){J(t)&&X(t,!1);const e=o(this,_,"f").indexOf(t);e>=0&&(o(this,_,"f").splice(e,1),o(this,Z,"f")?.call(this))}}select(t,e=!0){if(!t||this.items.includes(t)){if(!this.multi){for(const e of o(this,_,"f"))e!==t&&X(e,!1);o(this,_,"f").length=0}t&&(o(this,_,"f").push(t),J(t)||X(t,!0)),e&&this.updateActiveItem(t),o(this,Z,"f")?.call(this)}}setItems(t){const{added:e,removed:i}=super.setItems(t);return h(this,_,o(this,_,"f").filter(t=>!i.includes(t)),"f"),o(this,_,"f").push(...e.filter(t=>J(t))),o(this,$,"m",Q).call(this),o(this,Z,"f")?.call(this),{added:e,removed:i}}onSelectedItemsChange(t){return h(this,Z,t,"f"),this}}
15
+ var R,O,U,K,H,B,$,j,Z,_,G,Q,q,V,J,X;A=new WeakMap,y=new WeakMap,k=new WeakMap,I=new WeakMap,E=new WeakMap,S=new WeakMap,D=new WeakMap,b=new WeakSet,N=function(t){u(this,E,"f").push(t.toLocaleUpperCase()),clearTimeout(u(this,y,"f")),m(this,y,setTimeout(()=>u(this,b,"m",P).call(this),u(this,A,"f")),"f")},P=function(){const t=u(this,E,"f").join("");for(let e=1;e<u(this,D,"f").length+1;e++){const i=(u(this,S,"f")+e)%u(this,D,"f").length,s=u(this,D,"f")[i],n=s[C]?.().toLocaleUpperCase().trim();if(!u(this,I,"f")?.call(this,s)&&0===n?.indexOf(t)){u(this,k,"f").call(this,s);break}}this.reset()};class Y extends F{constructor(){super(...arguments),R.add(this),O.set(this,void 0),this.wrap=!1,this.homeAndEnd=!1,this.pageUpAndDown=!1,this.pageDelta=10,this.vertical=!1,this.allowedModifiers=[],this.skipPredicate=t=>e(t)&&t.disabled,this.directionality="ltr"}setItems(t){return u(this,O,"f")?.setItems(t),super.setItems(t)}updateActiveItem(t){super.updateActiveItem(t),u(this,O,"f")&&u(this,O,"f").setSelectedIndex(t?this.items.indexOf(t):-1)}withHomeAndEnd(t=!0){return this.homeAndEnd=t,this}withPageUpAndDown(t=!0,e=10){return this.pageUpAndDown=t,this.pageDelta=e,this}withWrap(t=!0){return this.wrap=t,this}withVerticalOrientation(t=!0){return this.vertical=t,this}withAllowedModifiers(...t){return this.allowedModifiers=t,this}withTypeahead(t=!0){return m(this,O,t?new L({callback:t=>this.setActiveItem(t)}):void 0,"f"),this}withSkipPredicate(t){return this.skipPredicate=t,this}withDirectionality(t){return this.directionality=t,this}onKeyDown(t){if(t.defaultPrevented)return;const e=x(t,...this.allowedModifiers);switch(t.key){case"Left":case"ArrowLeft":if(e&&!this.vertical){t.preventDefault();const e="ltr"===this.directionality?u(this,R,"m",B).call(this):u(this,R,"m",H).call(this);e&&this.setActiveItem(e)}break;case"Up":case"ArrowUp":if(e){t.preventDefault();const e="ltr"===this.directionality?u(this,R,"m",B).call(this):u(this,R,"m",H).call(this);e&&this.setActiveItem(e)}break;case"Right":case"ArrowRight":if(e&&!this.vertical){t.preventDefault();const e="ltr"===this.directionality?u(this,R,"m",H).call(this):u(this,R,"m",B).call(this);e&&this.setActiveItem(e)}break;case"Down":case"ArrowDown":if(e){t.preventDefault();const e="ltr"===this.directionality?u(this,R,"m",H).call(this):u(this,R,"m",B).call(this);e&&this.setActiveItem(e)}break;case"Home":if(e&&this.homeAndEnd){t.preventDefault();const e=u(this,R,"m",U).call(this);e&&this.setActiveItem(e)}break;case"End":if(e&&this.homeAndEnd){t.preventDefault();const e=u(this,R,"m",K).call(this);e&&this.setActiveItem(e)}break;case"PageUp":if(e&&this.pageUpAndDown){t.preventDefault();const e=("ltr"===this.directionality?u(this,R,"m",$):u(this,R,"m",j))(this.activeItem?Math.max(0,this.items.indexOf(this.activeItem)-this.pageDelta):0);e&&this.setActiveItem(e)}break;case"PageDown":if(e&&this.pageUpAndDown){t.preventDefault();const e=("ltr"===this.directionality?u(this,R,"m",j):u(this,R,"m",$))(this.activeItem?Math.min(this.items.length-1,this.items.indexOf(this.activeItem)+this.pageDelta):this.items.length-1);e&&this.setActiveItem(e)}break;default:(e||T(t,"shift"))&&u(this,O,"f")?.onKeyDown(t)}}}O=new WeakMap,R=new WeakSet,U=function(){for(let t=0;t<this.items.length&&this.items[t]!==this.activeItem;t++){const e=this.items[t];if(!this.skipPredicate(e))return e}return null},K=function(){for(let t=this.items.length-1;t>=0&&this.items[t]!==this.activeItem;t--){const e=this.items[t];if(!this.skipPredicate(e))return e}return null},H=function(){for(let t=0;t<this.items.length;t++)if(this.items[t]===this.activeItem){for(let e=t+1;e<this.items.length;e++){const t=this.items[e];if(!this.skipPredicate(t))return t}break}return this.wrap?u(this,R,"m",U).call(this):null},B=function(){for(let t=0;t<this.items.length;t++)if(this.items[t]===this.activeItem){for(let e=t-1;e>=0;e--){const t=this.items[e];if(!this.skipPredicate(t))return t}break}return this.wrap?u(this,R,"m",K).call(this):null},$=function(t){for(let e=t;e>=0;e--){const t=this.items[e];if(!this.skipPredicate(t))return t}return null},j=function(t){for(let e=t;e<this.items.length;e++){const t=this.items[e];if(!this.skipPredicate(t))return t}return null};class z extends Y{constructor(){super(...arguments),Z.set(this,void 0)}setActiveItem(t){super.setActiveItem(t),t?.focus(u(this,Z,"f"))}withOptions(t){return m(this,Z,t,"f"),this}}Z=new WeakMap;class tt extends z{constructor(){super(...arguments),_.set(this,!1)}updateActiveItem(t){if(super.updateActiveItem(t),!u(this,_,"f")){t?.setAttribute("tabindex","0");for(const e of this.items)e!==t&&e.hasAttribute("tabindex")&&e.setAttribute("tabindex","-1")}}setItems(t){const e=super.setItems(t);if(!u(this,_,"f"))for(const t of e.added)t===this.activeItem||this.skipPredicate(t)||t.setAttribute("tabindex","-1");return e}disableRovingTabIndex(t=!0){if(t!==u(this,_,"f")){m(this,_,t,"f");for(const t of this.items)this.skipPredicate(t)||t?.setAttribute("tabindex",u(this,_,"f")||t===this.activeItem?"0":"-1")}return this}}_=new WeakMap;class et extends tt{constructor(){super(...arguments),G.set(this,!1)}get disabled(){return u(this,G,"f")}set disabled(t){m(this,G,t,"f"),this.items.forEach(e=>e.disabled=t)}setItems(t){this.disabled&&t.forEach(t=>t.disabled=!0);const{added:e,removed:s}=super.setItems(t);if((e.length>0||s.length>0)&&(this.activeItem||this.updateActiveItem(e.find(t=>!this.skipPredicate(t))??null),this.activeItem&&(this.activeItem.disabled||!i(this.activeItem)))){const t=e.find(t=>!this.skipPredicate(t)&&i(t));t&&this.updateActiveItem(t)}return{added:e,removed:s}}}G=new WeakMap;const it=Symbol("selectionManager");class st extends et{constructor(){super(...arguments),Q.add(this),q.set(this,void 0),V.set(this,new Array),J.set(this,!1)}get multi(){return u(this,J,"f")}set multi(t){m(this,J,t,"f"),u(this,Q,"m",X).call(this,!0)}get selectedItems(){return u(this,V,"f")}notifySelectionChange(t){this.items.includes(t)&&(i(t)?this.select(t):this.deselect(t))}deselect(t){if(this.items.includes(t)){i(t)&&s(t,!1);const e=u(this,V,"f").indexOf(t);e>=0&&(u(this,V,"f").splice(e,1),u(this,q,"f")?.call(this))}}select(t,e=!0){if(!t||this.items.includes(t)){if(!this.multi){for(const e of u(this,V,"f"))e!==t&&s(e,!1);u(this,V,"f").length=0}t&&(u(this,V,"f").push(t),i(t)||s(t,!0)),e&&this.updateActiveItem(t),u(this,q,"f")?.call(this)}}setItems(t){const{added:e,removed:s}=super.setItems(t);return m(this,V,u(this,V,"f").filter(t=>!s.includes(t)),"f"),u(this,V,"f").push(...e.filter(t=>i(t))),u(this,Q,"m",X).call(this),u(this,q,"f")?.call(this),{added:e,removed:s}}onSelectedItemsChange(t){return m(this,q,t,"f"),this}}
16
16
  /**
17
17
  * Adapted from Angular Material CDK AriaDescriber
18
18
  * Source: https://github.com/angular/components/blob/main/src/cdk/a11y/aria-describer/aria-reference.ts
@@ -21,7 +21,7 @@ var F,C,W,L,R,O,U,K,H,B,j,$,Z,_,G,Q;p=new WeakMap,v=new WeakMap,g=new WeakMap,w=
21
21
  * Copyright (c) 2025 Google LLC
22
22
  * See LICENSE file in the project root for full license text.
23
23
  */
24
- function st(t,e){return t.getAttribute(e)?.match(/\S+/g)??[]}function nt(t,e,i){i=i.trim();const s=st(t,e);s.some(t=>t.trim()===i)||(s.push(i),t.setAttribute(e,s.join(" ")))}function at(t,e,i){i=i.trim();const s=st(t,e).filter(t=>t!==i);s.length>0?t.setAttribute(e,s.join(" ")):t.removeAttribute(e)}function rt(t){t.position="absolute",t.appearance="none",t.visibility="hidden",t.border="0",t.outline="0",t.overflow="hidden",t.left="0",t.height="1px",t.width="1px",t.margin="-1px",t.padding="0",t.whiteSpace="nowrap"}
24
+ function nt(t,e){return t.getAttribute(e)?.match(/\S+/g)??[]}function at(t,e,i){i=i.trim();const s=nt(t,e);s.some(t=>t.trim()===i)||(s.push(i),t.setAttribute(e,s.join(" ")))}function rt(t,e,i){i=i.trim();const s=nt(t,e).filter(t=>t!==i);s.length>0?t.setAttribute(e,s.join(" ")):t.removeAttribute(e)}function ot(t){t.position="absolute",t.appearance="none",t.visibility="hidden",t.border="0",t.outline="0",t.overflow="hidden",t.left="0",t.height="1px",t.width="1px",t.margin="-1px",t.padding="0",t.whiteSpace="nowrap"}
25
25
  /**
26
26
  * Adapted from Angular Material CDK ARIA Describer
27
27
  * Source: https://github.com/angular/components/blob/main/src/cdk/a11y/aria-describer/aria-describer.ts
@@ -29,5 +29,14 @@ function st(t,e){return t.getAttribute(e)?.match(/\S+/g)??[]}function nt(t,e,i){
29
29
  * @license MIT
30
30
  * Copyright (c) 2025 Google LLC
31
31
  * See LICENSE file in the project root for full license text.
32
- */var ot,ht,ct,lt,dt;Z=new WeakMap,_=new WeakMap,G=new WeakMap,$=new WeakSet,Q=function(t=!1){if(!this.multi&&o(this,_,"f").length>1){for(let t=1;t<o(this,_,"f").length;t++)X(o(this,_,"f")[t],!1);o(this,_,"f").length=1,t&&o(this,Z,"f")?.call(this)}};class ut{static describe(t,e,s="tooltip"){if(i)return;const n=t.getRootNode();if(!(n instanceof ShadowRoot||n instanceof Document))return;let a=o(this,ot,"f",ct).get(n);a||(a={containerElement:o(this,ot,"m",lt).call(this),messageRegistry:new Map},(n instanceof Document?n.body:n).appendChild(a.containerElement),o(this,ot,"f",ct).set(n,a));const r=`${s}:${e}`;let h=a.messageRegistry.get(r);h||(h={messageElement:o(this,ot,"m",dt).call(this,e,s),count:0},a.containerElement.appendChild(h.messageElement),a.messageRegistry.set(r,h)),h.count++,nt(t,"aria-describedby",h.messageElement.id)}static removeDescription(t,e,s="tooltip"){if(i)return;const n=t.getRootNode(),a=o(this,ot,"f",ct).get(n);if(!a)return;const r=`${s}:${e}`,h=a.messageRegistry.get(r);h&&(h.count--,at(t,"aria-describedby",h.messageElement.id),h.count<=0&&(h.messageElement.remove(),a.messageRegistry.delete(r)),0==a.messageRegistry.size&&(a.containerElement?.remove(),o(this,ot,"f",ct).delete(n)))}}ot=ut,lt=function(){const t=document.createElement("div");return t.classList.add("m3e-describedby-message-container"),rt(t.style),t},dt=function(t,e){var i,s;const n=document.createElement("span");return n.id=`m3e-describedby-message-${h(this,ot,(s=o(this,ot,"f",ht),i=s++,s),"f",ht),i}`,n.role=e,n.ariaAtomic="true",n.innerText=t.trim(),n},ht={value:0},ct={value:new Map},globalThis.M3eAriaDescriber=ut;var ft,mt,pt,vt,gt,wt,bt,yt;class At{static isFocusable(t,e){return t.matches(":is(button,input,select,textarea,object,:is(a,area)[href],[tabindex],[contenteditable=true]):not(:disabled,[disabled])")?!o(this,ft,"m",mt).call(this,e):!(!t.localName.includes("-")||!t.matches(":not(:disabled,[disabled])")||"true"===t.getAttribute("aria-disabled"))&&(!!t.shadowRoot?.delegatesFocus&&!o(this,ft,"m",mt).call(this,e))}static findInteractiveElements(t){const e=new Array,i=t.ownerDocument.createTreeWalker(t,NodeFilter.SHOW_ELEMENT);for(let t=i.nextNode();t;t=i.nextNode()){const t=i.currentNode;this.isFocusable(t)&&e.push(t)}return e}}ft=At,mt=function(t){return t?.some(t=>t.matches(":is([aria-hidden='true'],:disabled,[disabled])"))??!1},globalThis.M3eInteractivityChecker=At;let kt=class extends(function(e,i=!0){class s extends e{constructor(){super(...arguments),this.disabled=!1}update(t){super.update(t),t.has("disabled")&&this.role&&"none"!==this.role&&"presentation"!==this.role&&(this.ariaDisabled=this.disabled?"true":null)}}return r([t({type:Boolean,reflect:i})],s.prototype,"disabled",void 0),s}(a)){constructor(){super(...arguments),pt.add(this)}render(){const t=s`<div class="trap" .inert="${this.disabled}" tabindex="0" aria-hidden="true" @focus="${o(this,pt,"m",vt)}"></div>`;return s`${t}<slot></slot>${t}`}};var It,Et,St,Dt,Nt,Pt,Mt,Tt;pt=new WeakSet,vt=function(t){function e(t,e){return t===e||t instanceof HTMLElement&&null!==t.shadowRoot&&t.shadowRoot.contains(e)}const[i,s]=o(this,pt,"m",gt).call(this),n=t?.target===this._firstTrap,a=e(t.relatedTarget,i),r=e(t.relatedTarget,s),h=!a&&!r;!n&&r||n&&h?i?.focus():(n&&a||!n&&h)&&s?.focus()},gt=function(){let t=null,e=null;return o(this,pt,"m",wt).call(this,this,[],(i,s)=>{At.isFocusable(i,s)&&i instanceof HTMLElement&&i.tabIndex>=0&&(t=t??i,e=i)}),[t,e]},wt=function t(e,i,s){i=[...i,e];for(const n of e.childNodes){if(n.nodeType!==Node.ELEMENT_NODE)continue;const e=n;s(e,i),e.shadowRoot?o(this,pt,"m",bt).call(this,e,i,s):e instanceof HTMLSlotElement?o(this,pt,"m",yt).call(this,e,i,s):e.hasChildNodes()&&o(this,pt,"m",t).call(this,e,i,s)}},bt=function(t,e,i){for(const s of t.shadowRoot?.childNodes??[]){if(s.nodeType!==Node.ELEMENT_NODE)continue;const t=s;i(t,e),t.hasChildNodes()&&o(this,pt,"m",wt).call(this,t,e,i)}},yt=function(t,e,i){for(const s of t.assignedElements())i(s,e),s.hasChildNodes()&&o(this,pt,"m",wt).call(this,s,e,i)},kt.styles=n`:host { display: contents; } .trap { outline: none; }`,r([e(".trap")],kt.prototype,"_firstTrap",void 0),kt=r([(It="m3e-focus-trap",(t,e)=>{const i=()=>{"undefined"==typeof window||customElements.get(It)||customElements.define(It,t)};e?e.addInitializer(i):i()})],kt);class xt{static announce(t,...e){if(i)return Promise.resolve();let s,n;h(this,Et,o(this,Et,"f",Dt)??o(this,Et,"m",Tt).call(this),"f",Dt),1===e.length&&"number"==typeof e[0]?n=e[0]:[s,n]=e,this.clear(),clearTimeout(o(this,Et,"f",Nt)),o(this,Et,"f",Dt).setAttribute("aria-live",s??"polite");for(const t of document.querySelectorAll("m3e-dialog"))nt(t,"aria-owns",o(this,Et,"f",Dt).id);return h(this,Et,o(this,Et,"f",Pt)??new Promise(t=>h(this,Et,t,"f",Mt)),"f",Pt),clearTimeout(o(this,Et,"f",Nt)),h(this,Et,setTimeout(()=>{o(this,Et,"f",Dt)&&(o(this,Et,"f",Dt).textContent=t,void 0!==n&&h(this,Et,setTimeout(()=>this.clear(),n),"f",Nt),o(this,Et,"f",Mt)?.call(this),h(this,Et,h(this,Et,void 0,"f",Mt),"f",Pt))},100),"f",Nt),o(this,Et,"f",Pt)}static clear(){o(this,Et,"f",Dt)&&(o(this,Et,"f",Dt).textContent="")}}Et=xt,Tt=function(){var t,e;const i=document.getElementsByClassName("m3e-live-announcer");for(let t=0;t<i.length;t++)i[t].remove();const s=document.createElement("div");return s.classList.add("m3e-live-announcer"),s.setAttribute("aria-atomic","true"),s.setAttribute("aria-live","polite"),s.id=`m3e-live-announcer-${h(this,Et,(e=o(this,Et,"f",St),t=e++,e),"f",St),t}`,rt(s.style),document.body.append(s),s},St={value:0},Dt={value:void 0},Nt={value:void 0},Pt={value:void 0},Mt={value:void 0},globalThis.M3eLiveAnnouncer=xt;export{V as FocusKeyManager,l as KeyCode,q as ListKeyManager,P as ListManager,ut as M3eAriaDescriber,kt as M3eFocusTrapElement,At as M3eInteractivityChecker,xt as M3eLiveAnnouncer,c as ModifierKeys,tt as RadioKeyManager,Y as RovingTabIndexManager,it as SelectionManager,x as Typeahead,nt as addAriaReferencedId,st as getAriaReferenceIds,E as getKeyCode,S as hasModifierKey,D as isModifierAllowed,T as isTypeaheadItem,at as removeAriaReferencedId,et as selectionManager,M as typeaheadLabel};
32
+ */var ht,ct,lt,dt,ut,mt,ft,pt,vt,gt,wt,bt,At;q=new WeakMap,V=new WeakMap,J=new WeakMap,Q=new WeakSet,X=function(t=!1){if(!this.multi&&u(this,V,"f").length>1){for(let t=1;t<u(this,V,"f").length;t++)s(u(this,V,"f")[t],!1);u(this,V,"f").length=1,t&&u(this,q,"f")?.call(this)}};class yt{static describe(t,e,i="tooltip"){if(r)return;const s=t.getRootNode();if(!(s instanceof ShadowRoot||s instanceof Document))return;let n=u(this,ht,"f",lt).get(s);n||(n={containerElement:u(this,ht,"m",dt).call(this),messageRegistry:new Map},(s instanceof Document?s.body:s).appendChild(n.containerElement),u(this,ht,"f",lt).set(s,n));const a=`${i}:${e}`;let o=n.messageRegistry.get(a);o||(o={messageElement:u(this,ht,"m",ut).call(this,e,i),count:0},n.containerElement.appendChild(o.messageElement),n.messageRegistry.set(a,o)),o.count++,at(t,"aria-describedby",o.messageElement.id)}static removeDescription(t,e,i="tooltip"){if(r)return;const s=t.getRootNode(),n=u(this,ht,"f",lt).get(s);if(!n)return;const a=`${i}:${e}`,o=n.messageRegistry.get(a);o&&(o.count--,rt(t,"aria-describedby",o.messageElement.id),o.count<=0&&(o.messageElement.remove(),n.messageRegistry.delete(a)),0==n.messageRegistry.size&&(n.containerElement?.remove(),u(this,ht,"f",lt).delete(s)))}}ht=yt,dt=function(){const t=document.createElement("div");return t.classList.add("m3e-describedby-message-container"),ot(t.style),t},ut=function(t,e){var i,s;const n=document.createElement("span");return n.id=`m3e-describedby-message-${m(this,ht,(s=u(this,ht,"f",ct),i=s++,s),"f",ct),i}`,n.role=e,n.ariaAtomic="true",n.innerText=t.trim(),n},ct={value:0},lt={value:new Map},globalThis.M3eAriaDescriber=yt;class kt{static isFocusable(t,e){return t.matches(":is(button,input,select,textarea,object,:is(a,area)[href],[tabindex],[contenteditable=true]):not(:disabled,[disabled])")?!u(this,mt,"m",ft).call(this,e):!(!t.localName.includes("-")||!t.matches(":not(:disabled,[disabled])")||"true"===t.getAttribute("aria-disabled"))&&(!!t.shadowRoot?.delegatesFocus&&!u(this,mt,"m",ft).call(this,e))}static findInteractiveElements(t){const e=new Array,i=t.ownerDocument.createTreeWalker(t,NodeFilter.SHOW_ELEMENT);for(let t=i.nextNode();t;t=i.nextNode()){const t=i.currentNode;this.isFocusable(t)&&e.push(t)}return e}}mt=kt,ft=function(t){return t?.some(t=>t.matches(":is([aria-hidden='true'],:disabled,[disabled])"))??!1},globalThis.M3eInteractivityChecker=kt;let It=class extends(n(o)){constructor(){super(...arguments),pt.add(this)}render(){const t=h`<div class="trap" .inert="${this.disabled}" tabindex="0" aria-hidden="true" @focus="${u(this,pt,"m",vt)}"></div>`;return h`${t}<slot></slot>${t}`}};
33
+ /**
34
+ * Adapted from Angular Material CDK Live Announcer
35
+ * Source: https://github.com/angular/components/blob/main/src/cdk/a11y/live-announcer/live-announcer.ts
36
+ *
37
+ * @license MIT
38
+ * Copyright (c) 2025 Google LLC
39
+ * See LICENSE file in the project root for full license text.
40
+ */
41
+ var Et,St,Dt,Nt,Pt,Mt,Tt;pt=new WeakSet,vt=function(t){function e(t,e){return t===e||t instanceof HTMLElement&&null!==t.shadowRoot&&t.shadowRoot.contains(e)}const[i,s]=u(this,pt,"m",gt).call(this),n=t?.target===this._firstTrap,a=e(t.relatedTarget,i),r=e(t.relatedTarget,s),o=!a&&!r;!n&&r||n&&o?i?.focus():(n&&a||!n&&o)&&s?.focus()},gt=function(){let t=null,e=null;return u(this,pt,"m",wt).call(this,this,[],(i,s)=>{kt.isFocusable(i,s)&&i instanceof HTMLElement&&i.tabIndex>=0&&(t=t??i,e=i)}),[t,e]},wt=function t(e,i,s){i=[...i,e];for(const n of e.childNodes){if(n.nodeType!==Node.ELEMENT_NODE)continue;const e=n;s(e,i),e.shadowRoot?u(this,pt,"m",bt).call(this,e,i,s):e instanceof HTMLSlotElement?u(this,pt,"m",At).call(this,e,i,s):e.hasChildNodes()&&u(this,pt,"m",t).call(this,e,i,s)}},bt=function(t,e,i){for(const s of t.shadowRoot?.childNodes??[]){if(s.nodeType!==Node.ELEMENT_NODE)continue;const t=s;i(t,e),t.hasChildNodes()&&u(this,pt,"m",wt).call(this,t,e,i)}},At=function(t,e,i){for(const s of t.assignedElements())i(s,e),s.hasChildNodes()&&u(this,pt,"m",wt).call(this,s,e,i)},It.styles=c`:host { display: contents; } .trap { outline: none; }`,d([l(".trap")],It.prototype,"_firstTrap",void 0),It=d([a("m3e-focus-trap")],It);class xt{static announce(t,...e){if(r)return Promise.resolve();let i,s;m(this,Et,u(this,Et,"f",Dt)??u(this,Et,"m",Tt).call(this),"f",Dt),1===e.length&&"number"==typeof e[0]?s=e[0]:[i,s]=e,this.clear(),clearTimeout(u(this,Et,"f",Nt)),u(this,Et,"f",Dt).setAttribute("aria-live",i??"polite");for(const t of document.querySelectorAll("m3e-dialog"))at(t,"aria-owns",u(this,Et,"f",Dt).id);return m(this,Et,u(this,Et,"f",Pt)??new Promise(t=>m(this,Et,t,"f",Mt)),"f",Pt),clearTimeout(u(this,Et,"f",Nt)),m(this,Et,setTimeout(()=>{u(this,Et,"f",Dt)&&(u(this,Et,"f",Dt).textContent=t,void 0!==s&&m(this,Et,setTimeout(()=>this.clear(),s),"f",Nt),u(this,Et,"f",Mt)?.call(this),m(this,Et,m(this,Et,void 0,"f",Mt),"f",Pt))},100),"f",Nt),u(this,Et,"f",Pt)}static clear(){u(this,Et,"f",Dt)&&(u(this,Et,"f",Dt).textContent="")}}Et=xt,Tt=function(){var t,e;const i=document.getElementsByClassName("m3e-live-announcer");for(let t=0;t<i.length;t++)i[t].remove();const s=document.createElement("div");return s.classList.add("m3e-live-announcer"),s.setAttribute("aria-atomic","true"),s.setAttribute("aria-live","polite"),s.id=`m3e-live-announcer-${m(this,Et,(e=u(this,Et,"f",St),t=e++,e),"f",St),t}`,ot(s.style),document.body.append(s),s},St={value:0},Dt={value:void 0},Nt={value:void 0},Pt={value:void 0},Mt={value:void 0},globalThis.M3eLiveAnnouncer=xt;export{z as FocusKeyManager,p as KeyCode,Y as ListKeyManager,F as ListManager,yt as M3eAriaDescriber,It as M3eFocusTrapElement,kt as M3eInteractivityChecker,xt as M3eLiveAnnouncer,f as ModifierKeys,et as RadioKeyManager,tt as RovingTabIndexManager,st as SelectionManager,L as Typeahead,at as addAriaReferencedId,nt as getAriaReferenceIds,M as getKeyCode,T as hasModifierKey,x as isModifierAllowed,W as isTypeaheadItem,rt as removeAriaReferencedId,it as selectionManager,C as typeaheadLabel};
33
42
  //# sourceMappingURL=core-a11y.min.js.map