@warp-ds/elements 2.9.1-next.2 → 2.9.1-next.4

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 (168) hide show
  1. package/dist/custom-elements.json +91 -262
  2. package/dist/docs/affix/affix.md +9 -10
  3. package/dist/docs/affix/api.md +9 -10
  4. package/dist/docs/alert/alert.md +4 -2
  5. package/dist/docs/alert/api.md +4 -2
  6. package/dist/docs/attention/api.md +21 -16
  7. package/dist/docs/attention/attention.md +21 -16
  8. package/dist/docs/badge/api.md +5 -6
  9. package/dist/docs/badge/badge.md +5 -6
  10. package/dist/docs/box/api.md +3 -4
  11. package/dist/docs/box/box.md +3 -4
  12. package/dist/docs/breadcrumbs/accessibility.md +46 -0
  13. package/dist/docs/breadcrumbs/api.md +8 -8
  14. package/dist/docs/breadcrumbs/breadcrumbs.md +127 -9
  15. package/dist/docs/breadcrumbs/examples.md +35 -0
  16. package/dist/docs/breadcrumbs/usage.md +36 -0
  17. package/dist/docs/button/api.md +15 -13
  18. package/dist/docs/button/button.md +15 -13
  19. package/dist/docs/card/api.md +5 -6
  20. package/dist/docs/card/card.md +5 -6
  21. package/dist/docs/combobox/api.md +18 -19
  22. package/dist/docs/combobox/combobox.md +18 -19
  23. package/dist/docs/datepicker/api.md +38 -39
  24. package/dist/docs/datepicker/datepicker.md +38 -39
  25. package/dist/docs/expandable/api.md +11 -12
  26. package/dist/docs/expandable/expandable.md +11 -12
  27. package/dist/docs/link/api.md +8 -6
  28. package/dist/docs/link/link.md +8 -6
  29. package/dist/docs/page-indicator/api.md +7 -8
  30. package/dist/docs/page-indicator/page-indicator.md +7 -8
  31. package/dist/docs/pagination/api.md +17 -9
  32. package/dist/docs/pagination/pagination.md +17 -9
  33. package/dist/docs/pill/api.md +30 -17
  34. package/dist/docs/pill/pill.md +30 -17
  35. package/dist/docs/select/api.md +17 -9
  36. package/dist/docs/select/select.md +17 -9
  37. package/dist/docs/slider/api.md +37 -116
  38. package/dist/docs/slider/examples.md +331 -0
  39. package/dist/docs/slider/slider.md +378 -118
  40. package/dist/docs/slider/usage.md +10 -0
  41. package/dist/docs/slider-thumb/api.md +26 -79
  42. package/dist/docs/slider-thumb/slider-thumb.md +26 -81
  43. package/dist/docs/step/api.md +3 -4
  44. package/dist/docs/step/step.md +3 -4
  45. package/dist/docs/step-indicator/api.md +3 -4
  46. package/dist/docs/step-indicator/step-indicator.md +3 -4
  47. package/dist/docs/switch/api.md +13 -5
  48. package/dist/docs/switch/switch.md +13 -5
  49. package/dist/docs/tab/api.md +9 -62
  50. package/dist/docs/tab/tab.md +9 -70
  51. package/dist/docs/tab-panel/api.md +7 -11
  52. package/dist/docs/tab-panel/tab-panel.md +7 -19
  53. package/dist/docs/tabs/accessibility.md +11 -0
  54. package/dist/docs/tabs/api.md +10 -18
  55. package/dist/docs/tabs/examples.md +68 -0
  56. package/dist/docs/tabs/tabs.md +97 -20
  57. package/dist/docs/tabs/usage.md +8 -0
  58. package/dist/docs/textarea/api.md +15 -16
  59. package/dist/docs/textarea/textarea.md +15 -16
  60. package/dist/docs/textfield/api.md +14 -15
  61. package/dist/docs/textfield/textfield.md +14 -15
  62. package/dist/index.d.ts +124 -242
  63. package/dist/packages/affix/affix.js +11 -12
  64. package/dist/packages/affix/affix.js.map +4 -4
  65. package/dist/packages/alert/alert.d.ts +1 -1
  66. package/dist/packages/alert/alert.js.map +1 -1
  67. package/dist/packages/attention/attention.d.ts +3 -2
  68. package/dist/packages/attention/attention.js +27 -28
  69. package/dist/packages/attention/attention.js.map +4 -4
  70. package/dist/packages/breadcrumbs/breadcrumbs.d.ts +7 -1
  71. package/dist/packages/breadcrumbs/breadcrumbs.js +7 -8
  72. package/dist/packages/breadcrumbs/breadcrumbs.js.map +4 -4
  73. package/dist/packages/button/button.d.ts +4 -2
  74. package/dist/packages/button/button.js +14 -15
  75. package/dist/packages/button/button.js.map +4 -4
  76. package/dist/packages/card/card.js +8 -9
  77. package/dist/packages/card/card.js.map +4 -4
  78. package/dist/packages/checkbox/checkbox.d.ts +2 -0
  79. package/dist/packages/checkbox-group/checkbox-group.d.ts +2 -0
  80. package/dist/packages/checkbox-group/checkbox-group.js +15 -16
  81. package/dist/packages/checkbox-group/checkbox-group.js.map +4 -4
  82. package/dist/packages/checkbox-group/locales/da/messages.mjs +1 -1
  83. package/dist/packages/checkbox-group/locales/en/messages.mjs +1 -1
  84. package/dist/packages/checkbox-group/locales/fi/messages.mjs +1 -1
  85. package/dist/packages/checkbox-group/locales/nb/messages.mjs +1 -1
  86. package/dist/packages/checkbox-group/locales/sv/messages.mjs +1 -1
  87. package/dist/packages/combobox/combobox.js +13 -14
  88. package/dist/packages/combobox/combobox.js.map +4 -4
  89. package/dist/packages/combobox/locales/da/messages.mjs +1 -1
  90. package/dist/packages/combobox/locales/en/messages.mjs +1 -1
  91. package/dist/packages/combobox/locales/fi/messages.mjs +1 -1
  92. package/dist/packages/combobox/locales/nb/messages.mjs +1 -1
  93. package/dist/packages/combobox/locales/sv/messages.mjs +1 -1
  94. package/dist/packages/datepicker/datepicker.d.ts +2 -0
  95. package/dist/packages/datepicker/datepicker.js +51 -52
  96. package/dist/packages/datepicker/datepicker.js.map +4 -4
  97. package/dist/packages/datepicker/locales/da/messages.mjs +1 -1
  98. package/dist/packages/datepicker/locales/en/messages.mjs +1 -1
  99. package/dist/packages/datepicker/locales/fi/messages.mjs +1 -1
  100. package/dist/packages/datepicker/locales/nb/messages.mjs +1 -1
  101. package/dist/packages/datepicker/locales/sv/messages.mjs +1 -1
  102. package/dist/packages/link/link.d.ts +2 -0
  103. package/dist/packages/modal-header/modal-header.js +13 -14
  104. package/dist/packages/modal-header/modal-header.js.map +4 -4
  105. package/dist/packages/page-indicator/page-indicator.js +7 -8
  106. package/dist/packages/page-indicator/page-indicator.js.map +4 -4
  107. package/dist/packages/pagination/locales/da/messages.mjs +1 -1
  108. package/dist/packages/pagination/locales/en/messages.mjs +1 -1
  109. package/dist/packages/pagination/locales/fi/messages.mjs +1 -1
  110. package/dist/packages/pagination/locales/nb/messages.mjs +1 -1
  111. package/dist/packages/pagination/locales/sv/messages.mjs +1 -1
  112. package/dist/packages/pagination/pagination.js +31 -32
  113. package/dist/packages/pagination/pagination.js.map +4 -4
  114. package/dist/packages/pagination/pagination.test.js +38 -0
  115. package/dist/packages/pill/pill.js +11 -12
  116. package/dist/packages/pill/pill.js.map +4 -4
  117. package/dist/packages/radio/radio.d.ts +2 -0
  118. package/dist/packages/radio-group/radio-group.d.ts +2 -0
  119. package/dist/packages/radio-group/radio-group.js +17 -18
  120. package/dist/packages/radio-group/radio-group.js.map +4 -4
  121. package/dist/packages/select/select.js +19 -20
  122. package/dist/packages/select/select.js.map +4 -4
  123. package/dist/packages/slider/locales/da/messages.mjs +1 -1
  124. package/dist/packages/slider/locales/en/messages.mjs +1 -1
  125. package/dist/packages/slider/locales/fi/messages.mjs +1 -1
  126. package/dist/packages/slider/locales/nb/messages.mjs +1 -1
  127. package/dist/packages/slider/locales/sv/messages.mjs +1 -1
  128. package/dist/packages/slider/slider.d.ts +36 -45
  129. package/dist/packages/slider/slider.js +22 -23
  130. package/dist/packages/slider/slider.js.map +4 -4
  131. package/dist/packages/slider-thumb/slider-thumb.d.ts +41 -31
  132. package/dist/packages/slider-thumb/slider-thumb.js +33 -34
  133. package/dist/packages/slider-thumb/slider-thumb.js.map +4 -4
  134. package/dist/packages/step/locales/da/messages.mjs +1 -1
  135. package/dist/packages/step/locales/en/messages.mjs +1 -1
  136. package/dist/packages/step/locales/fi/messages.mjs +1 -1
  137. package/dist/packages/step/locales/nb/messages.mjs +1 -1
  138. package/dist/packages/step/locales/sv/messages.mjs +1 -1
  139. package/dist/packages/step/step.js +11 -12
  140. package/dist/packages/step/step.js.map +4 -4
  141. package/dist/packages/switch/switch.d.ts +2 -0
  142. package/dist/packages/tab/tab.d.ts +31 -24
  143. package/dist/packages/tab/tab.js +3 -3
  144. package/dist/packages/tab/tab.js.map +2 -2
  145. package/dist/packages/tab-panel/tab-panel.d.ts +9 -8
  146. package/dist/packages/tab-panel/tab-panel.js +3 -3
  147. package/dist/packages/tab-panel/tab-panel.js.map +2 -2
  148. package/dist/packages/tabs/index.d.ts +1 -0
  149. package/dist/packages/tabs/index.js +0 -1
  150. package/dist/packages/tabs/react.d.ts +4 -3
  151. package/dist/packages/tabs/tabs.d.ts +9 -3
  152. package/dist/packages/tabs/tabs.js +1 -1
  153. package/dist/packages/tabs/tabs.js.map +3 -3
  154. package/dist/packages/tabs/tabs.react.stories.d.ts +2 -2
  155. package/dist/packages/textarea/textarea.d.ts +2 -0
  156. package/dist/packages/textarea/textarea.js +20 -21
  157. package/dist/packages/textarea/textarea.js.map +4 -4
  158. package/dist/packages/textfield/textfield.d.ts +2 -0
  159. package/dist/packages/toast/toast.js +13 -14
  160. package/dist/packages/toast/toast.js.map +4 -4
  161. package/dist/web-types.json +206 -98
  162. package/package.json +20 -19
  163. package/dist/docs/tab/accessibility.md +0 -1
  164. package/dist/docs/tab/examples.md +0 -1
  165. package/dist/docs/tab/usage.md +0 -1
  166. package/dist/docs/tab-panel/accessibility.md +0 -1
  167. package/dist/docs/tab-panel/examples.md +0 -1
  168. package/dist/docs/tab-panel/usage.md +0 -1
@@ -5,55 +5,54 @@ declare const WarpSliderThumb_base: import("@open-wc/form-control").Constructor<
5
5
  /**
6
6
  * Component to place inside a `<w-slider>`.
7
7
  *
8
- * [See Storybook for usage examples](https://warp-ds.github.io/elements/?path=/docs/forms-slider-and-range-slider--docs)
8
+ * @parent w-slider
9
+ * @event {CustomEvent} slidervalidity - Internal event used by (and stopped by) `w-slider`.
10
+ * @event {CustomEvent} thumbreset - Internal event used by (and stopped by) `w-slider`.
9
11
  */
10
12
  declare class WarpSliderThumb extends WarpSliderThumb_base {
11
13
  #private;
14
+ /** @internal */
12
15
  static shadowRootOptions: {
13
16
  delegatesFocus: boolean;
17
+ clonable?: boolean;
18
+ customElementRegistry?: CustomElementRegistry;
14
19
  mode: ShadowRootMode;
15
20
  serializable?: boolean;
16
21
  slotAssignment?: SlotAssignmentMode;
17
22
  };
18
23
  static styles: import("lit").CSSResult[];
19
24
  /**
20
- * @summary
21
- * @description
25
+ * Label for the range input.
26
+ *
27
+ * @default `label` from `w-slider`
22
28
  */
23
29
  ariaLabel: string;
24
30
  /**
25
- * @summary
26
- * @description
31
+ * Contextual information for assistive technology, should it be needed
27
32
  */
28
33
  ariaDescription: string;
29
34
  /**
30
- * @summary
31
- * @description
35
+ * The name of this input field in the form. The canonical source of the value is the text field.
32
36
  */
33
37
  name: string;
34
38
  /**
35
- * @summary
36
- * @description
39
+ * The initial value, if any
37
40
  */
38
41
  value: string;
39
- /** @internal Set by `<w-slider>`
40
- * @summary
41
- * @description
42
+ /**
43
+ * @internal Set by `<w-slider>`
42
44
  */
43
45
  disabled: boolean;
44
- /** @internal Set by `<w-slider>`
45
- * @summary
46
- * @description
46
+ /**
47
+ * @internal Set by `<w-slider>`
47
48
  */
48
49
  invalid: boolean;
49
- /** @internal Set by `<w-slider>`
50
- * @summary
51
- * @description
50
+ /**
51
+ * @internal Set by `<w-slider>`
52
52
  */
53
53
  openEnded: boolean;
54
54
  /**
55
- * @summary
56
- * @description
55
+ * Placeholder in empty text fields
57
56
  */
58
57
  placeholder: string;
59
58
  /** @internal Set by `<w-slider>` */
@@ -68,23 +67,23 @@ declare class WarpSliderThumb extends WarpSliderThumb_base {
68
67
  max: string;
69
68
  /** @internal Set by `<w-slider>` */
70
69
  suffix: string;
71
- /** @internal Formatter for the tooltip and input mask values. Set by `<w-slider>`.
72
- * @summary
73
- * @description
70
+ /**
71
+ * @internal Formatter for the tooltip and input mask values. Set by `<w-slider>`.
74
72
  */
75
73
  valueFormatter: (value: string, slot: SliderSlot) => string;
76
- /** @internal Replaces {@link valueFormatter} for the tooltip. Use in open-ended sliders to show for example "300+ hk" instead of "Max" in the tooltip. Set by `<w-slider>`.
77
- * @summary
78
- * @description
74
+ /**
75
+ * @internal Replaces {@link valueFormatter} for the tooltip. Use in open-ended sliders to show for example "300+ hk" instead of "Max" in the tooltip. Set by `<w-slider>`.
79
76
  */
80
77
  tooltipFormatter: (value: string, slot: SliderSlot) => string;
81
- /** @internal Formatter for the min and max labels below the range. Set by `<w-slider>`.
82
- * @summary
83
- * @description
78
+ /**
79
+ * @internal Formatter for the min and max labels below the range. Set by `<w-slider>`.
84
80
  */
85
81
  labelFormatter: (slot: SliderSlot) => string;
82
+ /** @internal */
86
83
  range: HTMLInputElement;
84
+ /** @internal */
87
85
  tooltipTarget: HTMLOutputElement;
86
+ /** @internal */
88
87
  textfield: WarpTextField;
89
88
  /** @internal */
90
89
  _showTooltip: boolean;
@@ -100,11 +99,22 @@ declare class WarpSliderThumb extends WarpSliderThumb_base {
100
99
  anchorPositioningStyleElement: HTMLStyleElement | null;
101
100
  updateFieldAfterValidation(): Promise<void>;
102
101
  connectedCallback(): Promise<void>;
102
+ /**
103
+ * The boundary value for this thumb (min for 'from', max for 'to' or default)
104
+ * @internal
105
+ */
103
106
  get boundaryValue(): string;
104
- /** Value to display in the textfield (shows boundary when focused on empty value) */
107
+ /**
108
+ * Value to display in the textfield (shows boundary when focused on empty value)
109
+ * @internal
110
+ */
105
111
  get textFieldDisplayValue(): string;
106
- /** Value to display in the tooltip */
112
+ /**
113
+ * Value to display in the tooltip
114
+ * @internal
115
+ */
107
116
  get tooltipDisplayValue(): string | number;
117
+ /** @internal */
108
118
  get ariaDescriptionText(): string;
109
119
  updated(changedProperties: PropertyValues<this>): void;
110
120
  render(): import("lit").TemplateResult<1>;
@@ -1,13 +1,12 @@
1
- var Ue=Object.create;var ie=Object.defineProperty;var we=Object.getOwnPropertyDescriptor;var Re=Object.getOwnPropertyNames;var He=Object.getPrototypeOf,Xe=Object.prototype.hasOwnProperty;var xe=o=>{throw TypeError(o)};var ke=(o,r)=>()=>(r||o((r={exports:{}}).exports,r),r.exports);var qe=(o,r,e,t)=>{if(r&&typeof r=="object"||typeof r=="function")for(let a of Re(r))!Xe.call(o,a)&&a!==e&&ie(o,a,{get:()=>r[a],enumerable:!(t=we(r,a))||t.enumerable});return o};var Ze=(o,r,e)=>(e=o!=null?Ue(He(o)):{},qe(r||!o||!o.__esModule?ie(e,"default",{value:o,enumerable:!0}):e,o));var p=(o,r,e,t)=>{for(var a=t>1?void 0:t?we(r,e):r,i=o.length-1,n;i>=0;i--)(n=o[i])&&(a=(t?n(r,e,a):n(a))||a);return t&&a&&ie(r,e,a),a};var se=(o,r,e)=>r.has(o)||xe("Cannot "+e);var ne=(o,r,e)=>(se(o,r,"read from private field"),e?e.call(o):r.get(o)),le=(o,r,e)=>r.has(o)?xe("Cannot add the same private member more than once"):r instanceof WeakSet?r.add(o):r.set(o,e),de=(o,r,e,t)=>(se(o,r,"write to private field"),t?t.call(o,e):r.set(o,e),e),m=(o,r,e)=>(se(o,r,"access private method"),e);var ye=ke(O=>{"use strict";Object.defineProperty(O,"__esModule",{value:!0});O.errorMessages=O.ErrorType=void 0;var U;(function(o){o.MalformedUnicode="MALFORMED_UNICODE",o.MalformedHexadecimal="MALFORMED_HEXADECIMAL",o.CodePointLimit="CODE_POINT_LIMIT",o.OctalDeprecation="OCTAL_DEPRECATION",o.EndOfString="END_OF_STRING"})(U=O.ErrorType||(O.ErrorType={}));O.errorMessages=new Map([[U.MalformedUnicode,"malformed Unicode character escape sequence"],[U.MalformedHexadecimal,"malformed hexadecimal character escape sequence"],[U.CodePointLimit,"Unicode codepoint must not be greater than 0x10FFFF in escape sequence"],[U.OctalDeprecation,'"0"-prefixed octal literals and octal escape sequences are deprecated; for octal literals use the "0o" prefix instead'],[U.EndOfString,"malformed escape sequence at end of string"]])});var Ee=ke(P=>{"use strict";Object.defineProperty(P,"__esModule",{value:!0});P.unraw=P.errorMessages=P.ErrorType=void 0;var y=ye();Object.defineProperty(P,"ErrorType",{enumerable:!0,get:function(){return y.ErrorType}});Object.defineProperty(P,"errorMessages",{enumerable:!0,get:function(){return y.errorMessages}});function Be(o){return!o.match(/[^a-f0-9]/i)?parseInt(o,16):NaN}function G(o,r,e){let t=Be(o);if(Number.isNaN(t)||e!==void 0&&e!==o.length)throw new SyntaxError(y.errorMessages.get(r));return t}function Ke(o){let r=G(o,y.ErrorType.MalformedHexadecimal,2);return String.fromCharCode(r)}function _e(o,r){let e=G(o,y.ErrorType.MalformedUnicode,4);if(r!==void 0){let t=G(r,y.ErrorType.MalformedUnicode,4);return String.fromCharCode(e,t)}return String.fromCharCode(e)}function Ge(o){return o.charAt(0)==="{"&&o.charAt(o.length-1)==="}"}function Je(o){if(!Ge(o))throw new SyntaxError(y.errorMessages.get(y.ErrorType.MalformedUnicode));let r=o.slice(1,-1),e=G(r,y.ErrorType.MalformedUnicode);try{return String.fromCodePoint(e)}catch(t){throw t instanceof RangeError?new SyntaxError(y.errorMessages.get(y.ErrorType.CodePointLimit)):t}}function Qe(o,r=!1){if(r)throw new SyntaxError(y.errorMessages.get(y.ErrorType.OctalDeprecation));let e=parseInt(o,8);return String.fromCharCode(e)}var We=new Map([["b","\b"],["f","\f"],["n",`
2
- `],["r","\r"],["t"," "],["v","\v"],["0","\0"]]);function er(o){return We.get(o)||o}var rr=/\\(?:(\\)|x([\s\S]{0,2})|u(\{[^}]*\}?)|u([\s\S]{4})\\u([^{][\s\S]{0,3})|u([\s\S]{0,4})|([0-3]?[0-7]{1,2})|([\s\S])|$)/g;function Ce(o,r=!1){return o.replace(rr,function(e,t,a,i,n,s,d,g,_){if(t!==void 0)return"\\";if(a!==void 0)return Ke(a);if(i!==void 0)return Je(i);if(n!==void 0)return _e(n,s);if(d!==void 0)return _e(d);if(g==="0")return"\0";if(g!==void 0)return Qe(g,!r);if(_!==void 0)return er(_);throw new SyntaxError(y.errorMessages.get(y.ErrorType.EndOfString))})}P.unraw=Ce;P.default=Ce});var Fe=Ze(Ee(),1);var L=o=>typeof o=="string",tr=o=>typeof o=="function",ze=new Map,Se="en";function be(o){return[...Array.isArray(o)?o:[o],Se]}function pe(o,r,e){let t=be(o);e||(e="default");let a;if(typeof e=="string")switch(a={day:"numeric",month:"short",year:"numeric"},e){case"full":a.weekday="long";case"long":a.month="long";break;case"short":a.month="numeric";break}else a=e;return J(()=>Q("date",t,e),()=>new Intl.DateTimeFormat(t,a)).format(L(r)?new Date(r):r)}function or(o,r,e){let t;if(e||(e="default"),typeof e=="string")switch(t={second:"numeric",minute:"numeric",hour:"numeric"},e){case"full":case"long":t.timeZoneName="short";break;case"short":delete t.second}else t=e;return pe(o,r,t)}function ce(o,r,e){let t=be(o);return J(()=>Q("number",t,e),()=>new Intl.NumberFormat(t,e)).format(r)}function Me(o,r,e,{offset:t=0,...a}){var s,d;let i=be(o),n=r?J(()=>Q("plural-ordinal",i),()=>new Intl.PluralRules(i,{type:"ordinal"})):J(()=>Q("plural-cardinal",i),()=>new Intl.PluralRules(i,{type:"cardinal"}));return(d=(s=a[e])!=null?s:a[n.select(e-t)])!=null?d:a.other}function J(o,r){let e=o(),t=ze.get(e);return t||(t=r(),ze.set(e,t)),t}function Q(o,r,e){let t=r.join("-");return`${o}-${t}-${JSON.stringify(e)}`}var $e=/\\u[a-fA-F0-9]{4}|\\x[a-fA-F0-9]{2}/,Ve="%__lingui_octothorpe__%",ar=(o,r,e={})=>{let t=r||o,a=n=>typeof n=="object"?n:e[n],i=(n,s)=>{let d=Object.keys(e).length?a("number"):void 0,g=ce(t,n,d);return s.replace(new RegExp(Ve,"g"),g)};return{plural:(n,s)=>{let{offset:d=0}=s,g=Me(t,!1,n,s);return i(n-d,g)},selectordinal:(n,s)=>{let{offset:d=0}=s,g=Me(t,!0,n,s);return i(n-d,g)},select:ir,number:(n,s)=>ce(t,n,a(s)||{style:s}),date:(n,s)=>pe(t,n,a(s)||s),time:(n,s)=>or(t,n,a(s)||s)}},ir=(o,r)=>{var e;return(e=r[o])!=null?e:r.other};function sr(o,r,e){return(t={},a)=>{let i=ar(r,e,a),n=(d,g=!1)=>Array.isArray(d)?d.reduce((_,F)=>{if(F==="#"&&g)return _+Ve;if(L(F))return _+F;let[S,k,C]=F,E={};k==="plural"||k==="selectordinal"||k==="select"?Object.entries(C).forEach(([T,$])=>{E[T]=n($,k==="plural"||k==="selectordinal")}):E=C;let x;if(k){let T=i[k];x=T(t[S],E)}else x=t[S];return x==null?_:_+x},""):d,s=n(o);return L(s)&&$e.test(s)?(0,Fe.unraw)(s):L(s)?s:s?String(s):""}}var nr=Object.defineProperty,lr=(o,r,e)=>r in o?nr(o,r,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[r]=e,dr=(o,r,e)=>(lr(o,typeof r!="symbol"?r+"":r,e),e),he=class{constructor(){dr(this,"_events",{})}on(r,e){var a;var t;return(a=(t=this._events)[r])!=null||(t[r]=[]),this._events[r].push(e),()=>this.removeListener(r,e)}removeListener(r,e){let t=this._getListeners(r);if(!t)return;let a=t.indexOf(e);~a&&t.splice(a,1)}emit(r,...e){let t=this._getListeners(r);t&&t.map(a=>a.apply(this,e))}_getListeners(r){let e=this._events[r];return Array.isArray(e)?e:!1}},cr=Object.defineProperty,hr=(o,r,e)=>r in o?cr(o,r,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[r]=e,I=(o,r,e)=>(hr(o,typeof r!="symbol"?r+"":r,e),e),ue=class extends he{constructor(r){var e;super(),I(this,"_locale",""),I(this,"_locales"),I(this,"_localeData",{}),I(this,"_messages",{}),I(this,"_missing"),I(this,"_messageCompiler"),I(this,"t",this._.bind(this)),r.missing!=null&&(this._missing=r.missing),r.messages!=null&&this.load(r.messages),r.localeData!=null&&this.loadLocaleData(r.localeData),(typeof r.locale=="string"||r.locales)&&this.activate((e=r.locale)!=null?e:Se,r.locales)}get locale(){return this._locale}get locales(){return this._locales}get messages(){var r;return(r=this._messages[this._locale])!=null?r:{}}get localeData(){var r;return(r=this._localeData[this._locale])!=null?r:{}}_loadLocaleData(r,e){let t=this._localeData[r];t?Object.assign(t,e):this._localeData[r]=e}setMessagesCompiler(r){return this._messageCompiler=r,this}loadLocaleData(r,e){typeof r=="string"?this._loadLocaleData(r,e):Object.keys(r).forEach(t=>this._loadLocaleData(t,r[t])),this.emit("change")}_load(r,e){let t=this._messages[r];t?Object.assign(t,e):this._messages[r]=e}load(r,e){typeof r=="string"&&typeof e=="object"?this._load(r,e):Object.entries(r).forEach(([t,a])=>this._load(t,a)),this.emit("change")}loadAndActivate({locale:r,locales:e,messages:t}){this._locale=r,this._locales=e||void 0,this._messages[this._locale]=t,this.emit("change")}activate(r,e){this._locale=r,this._locales=e,this.emit("change")}_(r,e,t){if(!this.locale)throw new Error("Lingui: Attempted to call a translation function without setting a locale.\nMake sure to call `i18n.activate(locale)` before using Lingui functions.\nThis issue may also occur due to a race condition in your initialization logic.");let a=t==null?void 0:t.message;r||(r=""),L(r)||(e=r.values||e,a=r.message,r=r.id);let i=this.messages[r],n=i===void 0,s=this._missing;if(s&&n)return tr(s)?s(this._locale,r):s;n&&this.emit("missing",{id:r,locale:this._locale});let d=i||a||r;return L(d)&&(this._messageCompiler?d=this._messageCompiler(d):console.warn(`Uncompiled message detected! Message:
1
+ var $e=Object.defineProperty;var Se=Object.getOwnPropertyDescriptor;var be=o=>{throw TypeError(o)};var p=(o,r,e,t)=>{for(var a=t>1?void 0:t?Se(r,e):r,i=o.length-1,n;i>=0;i--)(n=o[i])&&(a=(t?n(r,e,a):n(a))||a);return t&&a&&$e(r,e,a),a};var ee=(o,r,e)=>r.has(o)||be("Cannot "+e);var re=(o,r,e)=>(ee(o,r,"read from private field"),e?e.call(o):r.get(o)),te=(o,r,e)=>r.has(o)?be("Cannot add the same private member more than once"):r instanceof WeakSet?r.add(o):r.set(o,e),oe=(o,r,e,t)=>(ee(o,r,"write to private field"),t?t.call(o,e):r.set(o,e),e),m=(o,r,e)=>(ee(o,r,"access private method"),e);var A=o=>typeof o=="string",Pe=o=>typeof o=="function",pe=new Map,ge="en";function ne(o){return[...Array.isArray(o)?o:[o],ge]}function le(o,r,e){let t=ne(o);e||(e="default");let a;if(typeof e=="string")switch(a={day:"numeric",month:"short",year:"numeric"},e){case"full":a.weekday="long";case"long":a.month="long";break;case"short":a.month="numeric";break}else a=e;return H(()=>Z("date",t,e),()=>new Intl.DateTimeFormat(t,a)).format(A(r)?new Date(r):r)}function Ne(o,r,e){let t;if(e||(e="default"),typeof e=="string")switch(t={second:"numeric",minute:"numeric",hour:"numeric"},e){case"full":case"long":t.timeZoneName="short";break;case"short":delete t.second}else t=e;return le(o,r,t)}function ae(o,r,e){let t=ne(o);return H(()=>Z("number",t,e),()=>new Intl.NumberFormat(t,e)).format(r)}function me(o,r,e,{offset:t=0,...a}){var s,c;let i=ne(o),n=r?H(()=>Z("plural-ordinal",i),()=>new Intl.PluralRules(i,{type:"ordinal"})):H(()=>Z("plural-cardinal",i),()=>new Intl.PluralRules(i,{type:"cardinal"}));return(c=(s=a[e])!=null?s:a[n.select(e-t)])!=null?c:a.other}function H(o,r){let e=o(),t=pe.get(e);return t||(t=r(),pe.set(e,t)),t}function Z(o,r,e){let t=r.join("-");return`${o}-${t}-${JSON.stringify(e)}`}var ve=/\\u[a-fA-F0-9]{4}|\\x[a-fA-F0-9]{2}/,fe=o=>o.replace(/\\u([a-fA-F0-9]{4})|\\x([a-fA-F0-9]{2})/g,(r,e,t)=>{if(e){let a=parseInt(e,16);return String.fromCharCode(a)}else{let a=parseInt(t,16);return String.fromCharCode(a)}}),we="%__lingui_octothorpe__%",Ae=(o,r,e={})=>{let t=r||o,a=n=>typeof n=="object"?n:e[n],i=(n,s)=>{let c=Object.keys(e).length?a("number"):void 0,f=ae(t,n,c);return s.replace(new RegExp(we,"g"),f)};return{plural:(n,s)=>{let{offset:c=0}=s,f=me(t,!1,n,s);return i(n-c,f)},selectordinal:(n,s)=>{let{offset:c=0}=s,f=me(t,!0,n,s);return i(n-c,f)},select:Le,number:(n,s)=>ae(t,n,a(s)||{style:s}),date:(n,s)=>le(t,n,a(s)||s),time:(n,s)=>Ne(t,n,a(s)||s)}},Le=(o,r)=>{var e;return(e=r[o])!=null?e:r.other};function De(o,r,e){return(t={},a)=>{let i=Ae(r,e,a),n=(c,f=!1)=>Array.isArray(c)?c.reduce((E,F)=>{if(F==="#"&&f)return E+we;if(A(F))return E+F;let[M,k,y]=F,_={};k==="plural"||k==="selectordinal"||k==="select"?Object.entries(y).forEach(([S,V])=>{_[S]=n(V,k==="plural"||k==="selectordinal")}):_=y;let x;if(k){let S=i[k];x=S(t[M],_)}else x=t[M];return x==null?E:E+x},""):c,s=n(o);return A(s)&&ve.test(s)?fe(s):A(s)?s:s?String(s):""}}var Te=Object.defineProperty,je=(o,r,e)=>r in o?Te(o,r,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[r]=e,Ye=(o,r,e)=>(je(o,typeof r!="symbol"?r+"":r,e),e),ie=class{constructor(){Ye(this,"_events",{})}on(r,e){var a;var t;return(a=(t=this._events)[r])!=null||(t[r]=[]),this._events[r].push(e),()=>this.removeListener(r,e)}removeListener(r,e){let t=this._getListeners(r);if(!t)return;let a=t.indexOf(e);~a&&t.splice(a,1)}emit(r,...e){let t=this._getListeners(r);t&&t.map(a=>a.apply(this,e))}_getListeners(r){let e=this._events[r];return Array.isArray(e)?e:!1}},Ie=Object.defineProperty,Xe=(o,r,e)=>r in o?Ie(o,r,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[r]=e,D=(o,r,e)=>(Xe(o,typeof r!="symbol"?r+"":r,e),e),se=class extends ie{constructor(r){var e;super(),D(this,"_locale",""),D(this,"_locales"),D(this,"_localeData",{}),D(this,"_messages",{}),D(this,"_missing"),D(this,"_messageCompiler"),D(this,"t",this._.bind(this)),r.missing!=null&&(this._missing=r.missing),r.messages!=null&&this.load(r.messages),r.localeData!=null&&this.loadLocaleData(r.localeData),(typeof r.locale=="string"||r.locales)&&this.activate((e=r.locale)!=null?e:ge,r.locales)}get locale(){return this._locale}get locales(){return this._locales}get messages(){var r;return(r=this._messages[this._locale])!=null?r:{}}get localeData(){var r;return(r=this._localeData[this._locale])!=null?r:{}}_loadLocaleData(r,e){let t=this._localeData[r];t?Object.assign(t,e):this._localeData[r]=e}setMessagesCompiler(r){return this._messageCompiler=r,this}loadLocaleData(r,e){typeof r=="string"?this._loadLocaleData(r,e):Object.keys(r).forEach(t=>this._loadLocaleData(t,r[t])),this.emit("change")}_load(r,e){let t=this._messages[r];t?Object.assign(t,e):this._messages[r]=e}load(r,e){typeof r=="string"&&typeof e=="object"?this._load(r,e):Object.entries(r).forEach(([t,a])=>this._load(t,a)),this.emit("change")}loadAndActivate({locale:r,locales:e,messages:t}){this._locale=r,this._locales=e||void 0,this._messages[this._locale]=t,this.emit("change")}activate(r,e){this._locale=r,this._locales=e,this.emit("change")}_(r,e,t){if(!this.locale)throw new Error("Lingui: Attempted to call a translation function without setting a locale.\nMake sure to call `i18n.activate(locale)` before using Lingui functions.\nThis issue may also occur due to a race condition in your initialization logic.");let a=t==null?void 0:t.message;r||(r=""),A(r)||(e=r.values||e,a=r.message,r=r.id);let i=this.messages[r],n=i===void 0,s=this._missing;if(s&&n)return Pe(s)?s(this._locale,r):s;n&&this.emit("missing",{id:r,locale:this._locale});let c=i||a||r;return A(c)&&(this._messageCompiler?c=this._messageCompiler(c):console.warn(`Uncompiled message detected! Message:
3
2
 
4
- > ${d}
3
+ > ${c}
5
4
 
6
5
  That means you use raw catalog or your catalog doesn't have a translation for the message and fallback was used.
7
6
  ICU features such as interpolation and plurals will not work properly for that message.
8
7
 
9
8
  Please compile your catalog first.
10
- `)),L(d)&&$e.test(d)?JSON.parse(`"${d}"`):L(d)?d:sr(d,this._locale,this._locales)(e,t==null?void 0:t.formats)}date(r,e){return pe(this._locales||this._locale,r,e)}number(r,e){return ce(this._locales||this._locale,r,e)}};function ur(o={}){return new ue(o)}var M=ur();var u=function(o,r,e,t){if(e==="a"&&!t)throw new TypeError("Private accessor was defined without a getter");if(typeof r=="function"?o!==r||!t:!r.has(o))throw new TypeError("Cannot read private member from an object whose class did not declare it");return e==="m"?t:e==="a"?t.call(o):t?t.value:r.get(o)},v=function(o,r,e,t,a){if(t==="m")throw new TypeError("Private method is not writable");if(t==="a"&&!a)throw new TypeError("Private accessor was defined without a setter");if(typeof r=="function"?o!==r||!a:!r.has(o))throw new TypeError("Cannot write private member to an object whose class did not declare it");return t==="a"?a.call(o,e):a?a.value=e:r.set(o,e),e};function Te(o){var r,e,t,a,i,n,s,d,g,_,F,S,k,C,E,x,T,$,te;class Ye extends o{constructor(...l){var h,f,w;super(...l),r.add(this),this.internals=this.attachInternals(),e.set(this,!1),t.set(this,!1),a.set(this,!1),i.set(this,void 0),n.set(this,void 0),s.set(this,!0),g.set(this,""),_.set(this,()=>{v(this,a,!0,"f"),v(this,e,!0,"f"),u(this,r,"m",x).call(this)}),F.set(this,()=>{v(this,e,!1,"f"),u(this,r,"m",T).call(this,this.shouldFormValueUpdate()?u(this,g,"f"):""),!this.validity.valid&&u(this,a,"f")&&v(this,t,!0,"f");let N=u(this,r,"m",x).call(this);this.validationMessageCallback&&this.validationMessageCallback(N?this.internals.validationMessage:"")}),S.set(this,()=>{var N;u(this,s,"f")&&this.validationTarget&&(this.internals.setValidity(this.validity,this.validationMessage,this.validationTarget),v(this,s,!1,"f")),v(this,a,!0,"f"),v(this,t,!0,"f"),u(this,r,"m",x).call(this),(N=this===null||this===void 0?void 0:this.validationMessageCallback)===null||N===void 0||N.call(this,this.showError?this.internals.validationMessage:"")}),k.set(this,void 0),C.set(this,!1),E.set(this,Promise.resolve()),(h=this.addEventListener)===null||h===void 0||h.call(this,"focus",u(this,_,"f")),(f=this.addEventListener)===null||f===void 0||f.call(this,"blur",u(this,F,"f")),(w=this.addEventListener)===null||w===void 0||w.call(this,"invalid",u(this,S,"f")),this.setValue(null)}static get formAssociated(){return!0}static get validators(){return this.formControlValidators||[]}static get observedAttributes(){let l=this.validators.map(w=>w.attribute).flat(),h=super.observedAttributes||[];return[...new Set([...h,...l])]}static getValidator(l){return this.validators.find(h=>h.attribute===l)||null}static getValidators(l){return this.validators.filter(h=>{var f;if(h.attribute===l||!((f=h.attribute)===null||f===void 0)&&f.includes(l))return!0})}get form(){return this.internals.form}get showError(){return u(this,r,"m",x).call(this)}checkValidity(){return this.internals.checkValidity()}get validity(){return this.internals.validity}get validationMessage(){return this.internals.validationMessage}attributeChangedCallback(l,h,f){var w;(w=super.attributeChangedCallback)===null||w===void 0||w.call(this,l,h,f);let X=this.constructor.getValidators(l);X!=null&&X.length&&this.validationTarget&&this.setValue(u(this,g,"f"))}setValue(l){var h;v(this,t,!1,"f"),(h=this.validationMessageCallback)===null||h===void 0||h.call(this,""),v(this,g,l,"f");let w=this.shouldFormValueUpdate()?l:null;this.internals.setFormValue(w),u(this,r,"m",T).call(this,w),this.valueChangedCallback&&this.valueChangedCallback(w),u(this,r,"m",x).call(this)}shouldFormValueUpdate(){return!0}get validationComplete(){return new Promise(l=>l(u(this,E,"f")))}formResetCallback(){var l,h;v(this,a,!1,"f"),v(this,t,!1,"f"),u(this,r,"m",x).call(this),(l=this.resetFormControl)===null||l===void 0||l.call(this),(h=this.validationMessageCallback)===null||h===void 0||h.call(this,u(this,r,"m",x).call(this)?this.validationMessage:"")}}return e=new WeakMap,t=new WeakMap,a=new WeakMap,i=new WeakMap,n=new WeakMap,s=new WeakMap,g=new WeakMap,_=new WeakMap,F=new WeakMap,S=new WeakMap,k=new WeakMap,C=new WeakMap,E=new WeakMap,r=new WeakSet,d=function(){let l=this.getRootNode(),h=`${this.localName}[name="${this.getAttribute("name")}"]`;return l.querySelectorAll(h)},x=function(){if(this.hasAttribute("disabled"))return!1;let l=u(this,t,"f")||u(this,a,"f")&&!this.validity.valid&&!u(this,e,"f");return l&&this.internals.states?this.internals.states.add("--show-error"):this.internals.states&&this.internals.states.delete("--show-error"),l},T=function(l){let h=this.constructor,f={},w=h.validators,N=[],X=w.some(z=>z.isValid instanceof Promise);u(this,C,"f")||(v(this,E,new Promise(z=>{v(this,k,z,"f")}),"f"),v(this,C,!0,"f")),u(this,i,"f")&&(u(this,i,"f").abort(),v(this,n,u(this,i,"f"),"f"));let q=new AbortController;v(this,i,q,"f");let Z,ve=!1;w.length&&(w.forEach(z=>{let oe=z.key||"customError",Y=z.isValid(this,l,q.signal);Y instanceof Promise?(N.push(Y),Y.then(ae=>{ae!=null&&(f[oe]=!ae,Z=u(this,r,"m",te).call(this,z,l),u(this,r,"m",$).call(this,f,Z))})):(f[oe]=!Y,this.validity[oe]!==!Y&&(ve=!0),!Y&&!Z&&(Z=u(this,r,"m",te).call(this,z,l)))}),Promise.allSettled(N).then(()=>{var z;q!=null&&q.signal.aborted||(v(this,C,!1,"f"),(z=u(this,k,"f"))===null||z===void 0||z.call(this))}),(ve||!X)&&u(this,r,"m",$).call(this,f,Z))},$=function(l,h){if(this.validationTarget)this.internals.setValidity(l,h,this.validationTarget),v(this,s,!1,"f");else{if(this.internals.setValidity(l,h),this.internals.validity.valid)return;v(this,s,!0,"f")}},te=function(l,h){if(this.validityCallback){let f=this.validityCallback(l.key||"customError");if(f)return f}return l.message instanceof Function?l.message(this,h):l.message},Ye}import{html as B,LitElement as Ae,nothing as A}from"lit";import{property as V,query as me,state as D}from"lit/decorators.js";import{classMap as mr}from"lit/directives/class-map.js";import{ifDefined as W}from"lit/directives/if-defined.js";import{css as br}from"lit";var Ne=br`*,:before,:after{--w-rotate:0;--w-rotate-x:0;--w-rotate-y:0;--w-rotate-z:0;--w-scale-x:1;--w-scale-y:1;--w-scale-z:1;--w-skew-x:0;--w-skew-y:0;--w-translate-x:0;--w-translate-y:0;--w-translate-z:0}.hidden{display:none}.absolute{position:absolute}.relative{position:relative}.static{position:static}.sr-only{clip:rect(0,0,0,0);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}`;import{css as Pe}from"lit";var De=Pe`
9
+ `)),A(c)&&ve.test(c)?fe(c):A(c)?c:De(c,this._locale,this._locales)(e,t==null?void 0:t.formats)}date(r,e){return le(this._locales||this._locale,r,e)}number(r,e){return ae(this._locales||this._locale,r,e)}};function Re(o={}){return new se(o)}var C=Re();var u=function(o,r,e,t){if(e==="a"&&!t)throw new TypeError("Private accessor was defined without a getter");if(typeof r=="function"?o!==r||!t:!r.has(o))throw new TypeError("Cannot read private member from an object whose class did not declare it");return e==="m"?t:e==="a"?t.call(o):t?t.value:r.get(o)},v=function(o,r,e,t,a){if(t==="m")throw new TypeError("Private method is not writable");if(t==="a"&&!a)throw new TypeError("Private accessor was defined without a setter");if(typeof r=="function"?o!==r||!a:!r.has(o))throw new TypeError("Cannot write private member to an object whose class did not declare it");return t==="a"?a.call(o,e):a?a.value=e:r.set(o,e),e};function xe(o){var r,e,t,a,i,n,s,c,f,E,F,M,k,y,_,x,S,V,J;class Ve extends o{constructor(...l){var h,g,w;super(...l),r.add(this),this.internals=this.attachInternals(),e.set(this,!1),t.set(this,!1),a.set(this,!1),i.set(this,void 0),n.set(this,void 0),s.set(this,!0),f.set(this,""),E.set(this,()=>{v(this,a,!0,"f"),v(this,e,!0,"f"),u(this,r,"m",x).call(this)}),F.set(this,()=>{v(this,e,!1,"f"),u(this,r,"m",S).call(this,this.shouldFormValueUpdate()?u(this,f,"f"):""),!this.validity.valid&&u(this,a,"f")&&v(this,t,!0,"f");let P=u(this,r,"m",x).call(this);this.validationMessageCallback&&this.validationMessageCallback(P?this.internals.validationMessage:"")}),M.set(this,()=>{var P;u(this,s,"f")&&this.validationTarget&&(this.internals.setValidity(this.validity,this.validationMessage,this.validationTarget),v(this,s,!1,"f")),v(this,a,!0,"f"),v(this,t,!0,"f"),u(this,r,"m",x).call(this),(P=this===null||this===void 0?void 0:this.validationMessageCallback)===null||P===void 0||P.call(this,this.showError?this.internals.validationMessage:"")}),k.set(this,void 0),y.set(this,!1),_.set(this,Promise.resolve()),(h=this.addEventListener)===null||h===void 0||h.call(this,"focus",u(this,E,"f")),(g=this.addEventListener)===null||g===void 0||g.call(this,"blur",u(this,F,"f")),(w=this.addEventListener)===null||w===void 0||w.call(this,"invalid",u(this,M,"f")),this.setValue(null)}static get formAssociated(){return!0}static get validators(){return this.formControlValidators||[]}static get observedAttributes(){let l=this.validators.map(w=>w.attribute).flat(),h=super.observedAttributes||[];return[...new Set([...h,...l])]}static getValidator(l){return this.validators.find(h=>h.attribute===l)||null}static getValidators(l){return this.validators.filter(h=>{var g;if(h.attribute===l||!((g=h.attribute)===null||g===void 0)&&g.includes(l))return!0})}get form(){return this.internals.form}get showError(){return u(this,r,"m",x).call(this)}checkValidity(){return this.internals.checkValidity()}get validity(){return this.internals.validity}get validationMessage(){return this.internals.validationMessage}attributeChangedCallback(l,h,g){var w;(w=super.attributeChangedCallback)===null||w===void 0||w.call(this,l,h,g);let X=this.constructor.getValidators(l);X!=null&&X.length&&this.validationTarget&&this.setValue(u(this,f,"f"))}setValue(l){var h;v(this,t,!1,"f"),(h=this.validationMessageCallback)===null||h===void 0||h.call(this,""),v(this,f,l,"f");let w=this.shouldFormValueUpdate()?l:null;this.internals.setFormValue(w),u(this,r,"m",S).call(this,w),this.valueChangedCallback&&this.valueChangedCallback(w),u(this,r,"m",x).call(this)}shouldFormValueUpdate(){return!0}get validationComplete(){return new Promise(l=>l(u(this,_,"f")))}formResetCallback(){var l,h;v(this,a,!1,"f"),v(this,t,!1,"f"),u(this,r,"m",x).call(this),(l=this.resetFormControl)===null||l===void 0||l.call(this),(h=this.validationMessageCallback)===null||h===void 0||h.call(this,u(this,r,"m",x).call(this)?this.validationMessage:"")}}return e=new WeakMap,t=new WeakMap,a=new WeakMap,i=new WeakMap,n=new WeakMap,s=new WeakMap,f=new WeakMap,E=new WeakMap,F=new WeakMap,M=new WeakMap,k=new WeakMap,y=new WeakMap,_=new WeakMap,r=new WeakSet,c=function(){let l=this.getRootNode(),h=`${this.localName}[name="${this.getAttribute("name")}"]`;return l.querySelectorAll(h)},x=function(){if(this.hasAttribute("disabled"))return!1;let l=u(this,t,"f")||u(this,a,"f")&&!this.validity.valid&&!u(this,e,"f");return l&&this.internals.states?this.internals.states.add("--show-error"):this.internals.states&&this.internals.states.delete("--show-error"),l},S=function(l){let h=this.constructor,g={},w=h.validators,P=[],X=w.some(z=>z.isValid instanceof Promise);u(this,y,"f")||(v(this,_,new Promise(z=>{v(this,k,z,"f")}),"f"),v(this,y,!0,"f")),u(this,i,"f")&&(u(this,i,"f").abort(),v(this,n,u(this,i,"f"),"f"));let R=new AbortController;v(this,i,R,"f");let O,ue=!1;w.length&&(w.forEach(z=>{let Q=z.key||"customError",j=z.isValid(this,l,R.signal);j instanceof Promise?(P.push(j),j.then(W=>{W!=null&&(g[Q]=!W,O=u(this,r,"m",J).call(this,z,l),u(this,r,"m",V).call(this,g,O))})):(g[Q]=!j,this.validity[Q]!==!j&&(ue=!0),!j&&!O&&(O=u(this,r,"m",J).call(this,z,l)))}),Promise.allSettled(P).then(()=>{var z;R!=null&&R.signal.aborted||(v(this,y,!1,"f"),(z=u(this,k,"f"))===null||z===void 0||z.call(this))}),(ue||!X)&&u(this,r,"m",V).call(this,g,O))},V=function(l,h){if(this.validationTarget)this.internals.setValidity(l,h,this.validationTarget),v(this,s,!1,"f");else{if(this.internals.setValidity(l,h),this.internals.validity.valid)return;v(this,s,!0,"f")}},J=function(l,h){if(this.validityCallback){let g=this.validityCallback(l.key||"customError");if(g)return g}return l.message instanceof Function?l.message(this,h):l.message},Ve}import{html as q,LitElement as Ce,nothing as L}from"lit";import{property as $,query as de,state as N}from"lit/decorators.js";import{classMap as Ue}from"lit/directives/class-map.js";import{ifDefined as K}from"lit/directives/if-defined.js";import{css as Oe}from"lit";var ke=Oe`*,:before,:after{--w-rotate:0;--w-rotate-x:0;--w-rotate-y:0;--w-rotate-z:0;--w-scale-x:1;--w-scale-y:1;--w-scale-z:1;--w-skew-x:0;--w-skew-y:0;--w-translate-x:0;--w-translate-y:0;--w-translate-z:0}.hidden{display:none}.absolute{position:absolute}.relative{position:relative}.static{position:static}.sr-only{clip:rect(0,0,0,0);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}`;import{css as ye}from"lit";var _e=ye`
11
10
  *,
12
11
  :before,
13
12
  :after {
@@ -280,7 +279,7 @@ Please compile your catalog first.
280
279
  svg {
281
280
  pointer-events: none;
282
281
  }
283
- `,Er=Pe`*, :before, :after {
282
+ `,We=ye`*, :before, :after {
284
283
  --w-rotate: 0;
285
284
  --w-rotate-x: 0;
286
285
  --w-rotate-y: 0;
@@ -2446,7 +2445,7 @@ Please compile your catalog first.
2446
2445
  display: none
2447
2446
  }
2448
2447
  }
2449
- `;import{css as pr}from"lit";var Le=pr`
2448
+ `;import{css as qe}from"lit";var ze=qe`
2450
2449
  .w-slider-thumb {
2451
2450
  position: relative;
2452
2451
  display: grid;
@@ -2637,7 +2636,7 @@ Please compile your catalog first.
2637
2636
  w-textfield {
2638
2637
  --w-textfield-placeholder-color-text: var(--w-s-color-text);
2639
2638
  }
2640
- `;var Oe={};var j,c,ee,re,ge,R,K,fe,Ie,je,b=class extends Te(Ae){constructor(){super(...arguments);le(this,c);this.disabled=!1;this.invalid=!1;this.openEnded=!1;this.suffix="";this._showTooltip=!1;this._inputHasFocus=!1;this._hiddenTextfield=!1;le(this,j,null);this.anchorPositioningStyleElement=null}resetFormControl(){this.value=ne(this,j),this.dispatchEvent(new CustomEvent("thumbreset",{bubbles:!0}))}async updateFieldAfterValidation(){let e=this.shadowRoot.querySelector("w-textfield");await m(this,c,K).call(this,e.value,!0)}async connectedCallback(){if(super.connectedCallback(),de(this,j,this.value),this.setValue(this.value),this.slot&&!this.ariaDescription&&(this.slot==="from"?this.ariaDescription=M.t({id:"slider.label.from",comment:"Accessible label for the 'from value' input field in a range slider",message:"From"}):this.slot==="to"&&(this.ariaDescription=M.t({id:"slider.label.to",comment:"Accessible label for the 'to value' input field in a range slider",message:"To"}))),"anchorName"in document.documentElement.style)await this.updateComplete;else{let a=Oe.url.substring(0,Oe.url.lastIndexOf("/"));try{let[{default:i}]=await Promise.all([import(`${a}/oddbird-css-anchor-positioning.js`),this.updateComplete]);this.anchorPositioningStyleElement||(this.anchorPositioningStyleElement=document.createElement("style"),this.shadowRoot.prepend(this.anchorPositioningStyleElement)),this.anchorPositioningStyleElement.textContent=`
2639
+ `;var Ee={};var T,d,B,G,ce,Y,U,he,Fe,Me,b=class extends xe(Ce){constructor(){super(...arguments);te(this,d);this.disabled=!1;this.invalid=!1;this.openEnded=!1;this.suffix="";this._showTooltip=!1;this._inputHasFocus=!1;this._hiddenTextfield=!1;te(this,T,null);this.anchorPositioningStyleElement=null}resetFormControl(){this.value=re(this,T),this.dispatchEvent(new CustomEvent("thumbreset",{bubbles:!0}))}async updateFieldAfterValidation(){let e=this.shadowRoot.querySelector("w-textfield");await m(this,d,U).call(this,e.value,!0)}async connectedCallback(){if(super.connectedCallback(),oe(this,T,this.value),this.setValue(this.value),this.slot&&!this.ariaDescription&&(this.slot==="from"?this.ariaDescription=C.t({id:"slider.label.from",comment:"Accessible label for the 'from value' input field in a range slider",message:"From"}):this.slot==="to"&&(this.ariaDescription=C.t({id:"slider.label.to",comment:"Accessible label for the 'to value' input field in a range slider",message:"To"}))),"anchorName"in document.documentElement.style)await this.updateComplete;else{let a=Ee.url.substring(0,Ee.url.lastIndexOf("/"));try{let[{default:i}]=await Promise.all([import(`${a}/oddbird-css-anchor-positioning.js`),this.updateComplete]);this.anchorPositioningStyleElement||(this.anchorPositioningStyleElement=document.createElement("style"),this.shadowRoot.prepend(this.anchorPositioningStyleElement)),this.anchorPositioningStyleElement.textContent=`
2641
2640
  /*
2642
2641
  * The polyfill can only anchor to ::before and ::after pseudo elements, not the pseudo element slider thumb.
2643
2642
  * We work around that by recreating a transparent version of the active range
@@ -2686,36 +2685,36 @@ Please compile your catalog first.
2686
2685
  left: anchor(--polyfilled-thumb left);
2687
2686
  margin-left: 38px;
2688
2687
  }
2689
- `,await i({roots:[this.shadowRoot],elements:[this.anchorPositioningStyleElement]})}catch(i){console.error(new Error("Error registering the CSS anchor positioning polyfill. The UI will look broken.",{cause:i}))}}let e=window.navigator.userAgent;/WebKit/.test(e)&&!/Chrome/.test(e)&&this.tooltipTarget&&this.tooltipTarget.style.setProperty("--transform-offset","var(--w-slider-thumb-size, 28px)"),m(this,c,ge).call(this)}get boundaryValue(){return this.slot==="from"?this.min:this.max}get textFieldDisplayValue(){var e;return this._inputHasFocus?this.value!==""?this.value:(e=this.range)!=null&&e.value?Math.min(Math.max(Number(this.range.value),Number(this.min)+1),Number(this.max)-1).toString():"":this.value}get tooltipDisplayValue(){var t,a;let e=0;return this.tooltipFormatter?e=this.tooltipFormatter(this.value,this.slot):this.valueFormatter?e=this.valueFormatter(this.value,this.slot):this.value===""?e=(a=(t=this.range)==null?void 0:t.value)!=null?a:this.boundaryValue:e=this.value||0,e}get ariaDescriptionText(){let e="",t=this.ariaDescription||"",a=this.value==="";return this.openEnded&&a&&(e=this.slot==="from"?M.t({id:"slider.placeholder.from",message:"Min"}):M.t({id:"slider.placeholder.to",message:"Max"})),e?`${e}, ${t}`:t}updated(e){e.has("openEnded")&&this.openEnded&&!this.placeholder&&(this.slot==="to"||this.slot===""?this.placeholder=M.t({id:"slider.placeholder.to",message:"Max",comment:"Max as in short for Maximum"}):this.slot==="from"&&(this.placeholder=M.t({id:"slider.placeholder.from",message:"Min",comment:"Min as in short for Minimum"}))),e.has("value")&&(typeof ne(this,j)=="undefined"&&typeof this.value!="undefined"&&de(this,j,this.value),this.setValue(this.value),m(this,c,ge).call(this))}render(){var t,a,i,n;let e=this.placeholder&&!this.value;return B`
2688
+ `,await i({roots:[this.shadowRoot],elements:[this.anchorPositioningStyleElement]})}catch(i){console.error(new Error("Error registering the CSS anchor positioning polyfill. The UI will look broken.",{cause:i}))}}let e=window.navigator.userAgent;/WebKit/.test(e)&&!/Chrome/.test(e)&&this.tooltipTarget&&this.tooltipTarget.style.setProperty("--transform-offset","var(--w-slider-thumb-size, 28px)"),m(this,d,ce).call(this)}get boundaryValue(){return this.slot==="from"?this.min:this.max}get textFieldDisplayValue(){var e;return this._inputHasFocus?this.value!==""?this.value:(e=this.range)!=null&&e.value?Math.min(Math.max(Number(this.range.value),Number(this.min)+1),Number(this.max)-1).toString():"":this.value}get tooltipDisplayValue(){var t,a;let e=0;return this.tooltipFormatter?e=this.tooltipFormatter(this.value,this.slot):this.valueFormatter?e=this.valueFormatter(this.value,this.slot):this.value===""?e=(a=(t=this.range)==null?void 0:t.value)!=null?a:this.boundaryValue:e=this.value||0,e}get ariaDescriptionText(){let e="",t=this.ariaDescription||"",a=this.value==="";return this.openEnded&&a&&(e=this.slot==="from"?C.t({id:"slider.placeholder.from",message:"Min"}):C.t({id:"slider.placeholder.to",message:"Max"})),e?`${e}, ${t}`:t}updated(e){e.has("openEnded")&&this.openEnded&&!this.placeholder&&(this.slot==="to"||this.slot===""?this.placeholder=C.t({id:"slider.placeholder.to",message:"Max",comment:"Max as in short for Maximum"}):this.slot==="from"&&(this.placeholder=C.t({id:"slider.placeholder.from",message:"Min",comment:"Min as in short for Minimum"}))),e.has("value")&&(typeof re(this,T)=="undefined"&&typeof this.value!="undefined"&&oe(this,T,this.value),this.setValue(this.value),m(this,d,ce).call(this))}render(){var t,a,i,n;let e=this.placeholder&&!this.value;return q`
2690
2689
  <div class="w-slider-thumb">
2691
- ${"anchorName"in document.documentElement.style?A:B`<div class="polyfill-range">
2690
+ ${"anchorName"in document.documentElement.style?L:q`<div class="polyfill-range">
2692
2691
  <div class="polyfill-active-range"></div>
2693
2692
  </div>`}
2694
2693
  <input
2695
2694
  id="range"
2696
2695
  aria-label="${this.ariaLabel}"
2697
- aria-describedby="${W(this.ariaDescription?"aria-description":void 0)}"
2696
+ aria-describedby="${K(this.ariaDescription?"aria-description":void 0)}"
2698
2697
  class="w-slider-thumb__range"
2699
2698
  type="range"
2700
2699
  .value="${this.value}"
2701
2700
  min="${this.min}"
2702
2701
  max="${this.max}"
2703
- step="${W(!this.openEnded&&this.step?this.step:void 0)}"
2702
+ step="${K(!this.openEnded&&this.step?this.step:void 0)}"
2704
2703
  ?disabled="${this.disabled}"
2705
- @mousedown="${m(this,c,ee)}"
2706
- @mouseup="${m(this,c,re)}"
2707
- @touchstart="${m(this,c,ee)}"
2708
- @touchend="${m(this,c,re)}"
2709
- @focus="${m(this,c,ee)}"
2710
- @blur="${m(this,c,re)}"
2711
- @input="${m(this,c,fe)}"
2712
- @keydown="${m(this,c,Ie)}"
2704
+ @mousedown="${m(this,d,B)}"
2705
+ @mouseup="${m(this,d,G)}"
2706
+ @touchstart="${m(this,d,B)}"
2707
+ @touchend="${m(this,d,G)}"
2708
+ @focus="${m(this,d,B)}"
2709
+ @blur="${m(this,d,G)}"
2710
+ @input="${m(this,d,he)}"
2711
+ @keydown="${m(this,d,Fe)}"
2713
2712
  />
2714
2713
 
2715
- ${this.slot==="from"||!this.slot?B`
2714
+ ${this.slot==="from"||!this.slot?q`
2716
2715
  <span class="sr-only">
2717
- ${M.t({id:"slider.label.from",message:"From"})+" "+(this.labelFormatter?this.labelFormatter("from"):this.min)+", "+M.t({id:"slider.label.to",message:"To"})+" "+(this.labelFormatter?this.labelFormatter("to"):this.max)}
2718
- </span>`:A}
2716
+ ${C.t({id:"slider.label.from",message:"From"})+" "+(this.labelFormatter?this.labelFormatter("from"):this.min)+", "+C.t({id:"slider.label.to",message:"To"})+" "+(this.labelFormatter?this.labelFormatter("to"):this.max)}
2717
+ </span>`:L}
2719
2718
 
2720
2719
  <span
2721
2720
  aria-hidden="true"
@@ -2732,22 +2731,22 @@ Please compile your catalog first.
2732
2731
 
2733
2732
  <w-textfield
2734
2733
  aria-label="${this.ariaLabel}"
2735
- aria-description="${W(this.ariaDescriptionText)}"
2736
- class="${mr({"w-slider-thumb__textfield":!0,"sr-only":this._hiddenTextfield})}"
2734
+ aria-description="${K(this.ariaDescriptionText)}"
2735
+ class="${Ue({"w-slider-thumb__textfield":!0,"sr-only":this._hiddenTextfield})}"
2737
2736
  type="number"
2738
- tabindex="${this._hiddenTextfield?-1:A}"
2737
+ tabindex="${this._hiddenTextfield?-1:L}"
2739
2738
  placeholder="${this.placeholder}"
2740
2739
  .value="${this.textFieldDisplayValue}"
2741
- .formatter=${this.valueFormatter&&!e?s=>this.valueFormatter(s,this.slot):A}
2742
- min="${this.openEnded?A:this.min}"
2743
- max="${this.openEnded?A:this.max}"
2744
- step="${W(this.step)}"
2740
+ .formatter=${this.valueFormatter&&!e?s=>this.valueFormatter(s,this.slot):L}
2741
+ min="${this.openEnded?L:this.min}"
2742
+ max="${this.openEnded?L:this.max}"
2743
+ step="${K(this.step)}"
2745
2744
  ?invalid="${!!this.invalid}"
2746
- @input="${m(this,c,fe)}"
2747
- @keydown="${m(this,c,je)}"
2745
+ @input="${m(this,d,he)}"
2746
+ @keydown="${m(this,d,Me)}"
2748
2747
  ?disabled="${this.disabled}"
2749
2748
  >
2750
- ${(t=this.suffix)!=null&&t?B`<w-affix slot="suffix" label="${(a=this.suffix)!=null?a:""}"></w-affix>`:A}
2749
+ ${(t=this.suffix)!=null&&t?q`<w-affix slot="suffix" label="${(a=this.suffix)!=null?a:""}"></w-affix>`:L}
2751
2750
  </w-textfield>
2752
2751
  <w-attention
2753
2752
  tooltip
@@ -2762,7 +2761,7 @@ Please compile your catalog first.
2762
2761
  slot="target"
2763
2762
  ></output>
2764
2763
  <span slot="message">
2765
- ${this.tooltipDisplayValue}${(i=this.suffix)!=null&&i?B`&nbsp;${(n=this.suffix)!=null?n:""}`:A}
2764
+ ${this.tooltipDisplayValue}${(i=this.suffix)!=null&&i?q`&nbsp;${(n=this.suffix)!=null?n:""}`:L}
2766
2765
  </span>
2767
2766
  </w-attention>
2768
2767
 
@@ -2771,5 +2770,5 @@ Please compile your catalog first.
2771
2770
  ${this.ariaDescriptionText}
2772
2771
  </span>
2773
2772
  </div>
2774
- `}};j=new WeakMap,c=new WeakSet,ee=function(){this._showTooltip=!0,this.shadowRoot.querySelector("w-attention").handleDone()},re=function(){this._showTooltip=!1},ge=function(){this.range&&(this.value===""?this.range.value=this.boundaryValue:this.value&&(this.range.value=this.value))},R=function(e){this.dispatchEvent(new CustomEvent("slidervalidity",{bubbles:!0,detail:{invalid:e,slot:this.slot}}))},K=async function(e,t){var _;let a=(_=this.suffix)!=null?_:"",i=Number.parseInt(e);if(this.openEnded&&!t&&this.step&&!(this.slot==="to"&&i>=Number(this.max)-1||this.slot==="from"&&i<=Number(this.min)+1)){let S=1/this.step;i=Math.round(i*S)/S,e=i.toString()}let n=Number.parseInt(this.max),s=Number.parseInt(this.min);if(!this.openEnded&&(i>n||i<s))return m(this,c,R).call(this,M.t({id:"slider.error.out_of_bounds",message:"Value must be between {min} and {max}",values:{min:`${this.min} ${a}`.trim(),max:`${this.max} ${a}`.trim()}})),{shouldCancel:!0};e===""&&this.required&&m(this,c,R).call(this,M.t({id:"slider.error.required",message:"This field is required"})),this.value=e;let d=e===this.max||e===this.min,g=!1;if(this.slot){let F=this.parentElement.querySelector('w-slider-thumb[slot="to"]'),S=this.parentElement.querySelector('w-slider-thumb[slot="from"]'),k=F.textfield.value||this.max,C=S.textfield.value||this.min,E=Number.parseInt(k),x=Number.parseInt(C),T=M.t({id:"slider.error.overlap",message:"The maximum value cannot be less than the minimum"});if(this.slot==="from"){let $=this.openEnded&&E>n?E:Math.min(E,this.openEnded?n-1:n);i>$&&(g=!0,this.openEnded&&d?this.value=String($):this.value=k,t&&(m(this,c,R).call(this,T),await this.updateComplete,this.textfield.value=e))}else{let $=this.openEnded&&x<s?x:Math.max(Number.parseInt(C),this.openEnded?s+1:s);i<$&&(g=!0,this.openEnded&&d?this.value=String($):this.value=C,t&&(m(this,c,R).call(this,T),await this.updateComplete,this.textfield.value=e))}}return g?{shouldCancel:!0}:(m(this,c,R).call(this,""),this.range.value=Math.min(Math.max(Number(e),Number(this.min)),Number(this.max)).toString(),this.value=this.openEnded&&!t&&d?"":e,this.shadowRoot.querySelector("w-attention").handleDone(),{shouldCancel:!1})},fe=async function(e){let t=e.currentTarget.tagName==="W-TEXTFIELD";if(e instanceof CustomEvent)return;let a=e.currentTarget.value;return(await m(this,c,K).call(this,a,t)).shouldCancel?(e.preventDefault(),!1):!0},Ie=async function(e){if(e.key==="Enter"&&this.internals.form){this.internals.form.requestSubmit();return}if(!this.openEnded||e.key!=="ArrowLeft"&&e.key!=="ArrowRight")return;let t=Number(this.range.value),a=this.step||1,i;e.key==="ArrowLeft"?i=t-a:i=t+a,i=Math.min(Math.max(i,Number(this.min)),Number(this.max)),(await m(this,c,K).call(this,i.toString(),!1)).shouldCancel&&e.preventDefault()},je=async function(e){if(e.key==="Enter"&&this.internals.form){this.internals.form.requestSubmit();return}if(this.textfield.value)return;e.preventDefault();let t="";this.slot==="from"?e.key==="ArrowUp"?t=String(Number(this.min)+1)||"1":e.key==="ArrowDown"&&(t=String(Number(this.min))||"0"):e.key==="ArrowUp"?t=String(Number(this.max))||"100":e.key==="ArrowDown"&&(t=String(Number(this.max)-1)||"99"),await m(this,c,K).call(this,t,!0)},b.shadowRootOptions={...Ae.shadowRootOptions,delegatesFocus:!0},b.styles=[De,Ne,Le],p([V({attribute:"aria-label"})],b.prototype,"ariaLabel",2),p([V({attribute:"aria-description"})],b.prototype,"ariaDescription",2),p([V({reflect:!0})],b.prototype,"name",2),p([V({reflect:!0})],b.prototype,"value",2),p([V({type:Boolean,reflect:!0})],b.prototype,"disabled",2),p([V({type:Boolean,reflect:!0})],b.prototype,"invalid",2),p([V({attribute:!1,reflect:!1})],b.prototype,"openEnded",2),p([V({reflect:!0})],b.prototype,"placeholder",2),p([D()],b.prototype,"markers",2),p([D()],b.prototype,"required",2),p([D()],b.prototype,"step",2),p([D()],b.prototype,"min",2),p([D()],b.prototype,"max",2),p([D()],b.prototype,"suffix",2),p([V({attribute:!1})],b.prototype,"valueFormatter",2),p([V({attribute:!1})],b.prototype,"tooltipFormatter",2),p([V({attribute:!1})],b.prototype,"labelFormatter",2),p([me('input[type="range"]')],b.prototype,"range",2),p([me(".w-slider-thumb__tooltip-target")],b.prototype,"tooltipTarget",2),p([me("w-textfield")],b.prototype,"textfield",2),p([D()],b.prototype,"_showTooltip",2),p([D()],b.prototype,"_inputHasFocus",2),p([D()],b.prototype,"_hiddenTextfield",2);customElements.get("w-slider-thumb")||customElements.define("w-slider-thumb",b);export{b as WarpSliderThumb};
2773
+ `}};T=new WeakMap,d=new WeakSet,B=function(){this._showTooltip=!0,this.shadowRoot.querySelector("w-attention").handleDone()},G=function(){this._showTooltip=!1},ce=function(){this.range&&(this.value===""?this.range.value=this.boundaryValue:this.value&&(this.range.value=this.value))},Y=function(e){this.dispatchEvent(new CustomEvent("slidervalidity",{bubbles:!0,detail:{invalid:e,slot:this.slot}}))},U=async function(e,t){var E;let a=(E=this.suffix)!=null?E:"",i=Number.parseInt(e);if(this.openEnded&&!t&&this.step&&!(this.slot==="to"&&i>=Number(this.max)-1||this.slot==="from"&&i<=Number(this.min)+1)){let M=1/this.step;i=Math.round(i*M)/M,e=i.toString()}let n=Number.parseInt(this.max),s=Number.parseInt(this.min);if(!this.openEnded&&(i>n||i<s))return m(this,d,Y).call(this,C.t({id:"slider.error.out_of_bounds",message:"Value must be between {min} and {max}",values:{min:`${this.min} ${a}`.trim(),max:`${this.max} ${a}`.trim()}})),{shouldCancel:!0};e===""&&this.required&&m(this,d,Y).call(this,C.t({id:"slider.error.required",message:"This field is required"})),this.value=e;let c=e===this.max||e===this.min,f=!1;if(this.slot){let F=this.parentElement.querySelector('w-slider-thumb[slot="to"]'),M=this.parentElement.querySelector('w-slider-thumb[slot="from"]'),k=F.textfield.value||this.max,y=M.textfield.value||this.min,_=Number.parseInt(k),x=Number.parseInt(y),S=C.t({id:"slider.error.overlap",message:"The maximum value cannot be less than the minimum"});if(this.slot==="from"){let V=this.openEnded&&_>n?_:Math.min(_,this.openEnded?n-1:n);i>V&&(f=!0,this.openEnded&&c?this.value=String(V):this.value=k,t&&(m(this,d,Y).call(this,S),await this.updateComplete,this.textfield.value=e))}else{let V=this.openEnded&&x<s?x:Math.max(Number.parseInt(y),this.openEnded?s+1:s);i<V&&(f=!0,this.openEnded&&c?this.value=String(V):this.value=y,t&&(m(this,d,Y).call(this,S),await this.updateComplete,this.textfield.value=e))}}return f?{shouldCancel:!0}:(m(this,d,Y).call(this,""),this.range.value=Math.min(Math.max(Number(e),Number(this.min)),Number(this.max)).toString(),this.value=this.openEnded&&!t&&c?"":e,this.shadowRoot.querySelector("w-attention").handleDone(),{shouldCancel:!1})},he=async function(e){let t=e.currentTarget.tagName==="W-TEXTFIELD";if(e instanceof CustomEvent)return;let a=e.currentTarget.value;return(await m(this,d,U).call(this,a,t)).shouldCancel?(e.preventDefault(),!1):!0},Fe=async function(e){if(e.key==="Enter"&&this.internals.form){this.internals.form.requestSubmit();return}if(!this.openEnded||e.key!=="ArrowLeft"&&e.key!=="ArrowRight")return;let t=Number(this.range.value),a=this.step||1,i;e.key==="ArrowLeft"?i=t-a:i=t+a,i=Math.min(Math.max(i,Number(this.min)),Number(this.max)),(await m(this,d,U).call(this,i.toString(),!1)).shouldCancel&&e.preventDefault()},Me=async function(e){if(e.key==="Enter"&&this.internals.form){this.internals.form.requestSubmit();return}if(this.textfield.value)return;let t="";this.slot==="from"?e.key==="ArrowUp"?t=String(Number(this.min)+1)||"1":e.key==="ArrowDown"&&(t=String(Number(this.min))||"0"):e.key==="ArrowUp"?t=String(Number(this.max))||"100":e.key==="ArrowDown"&&(t=String(Number(this.max)-1)||"99"),t&&(e.preventDefault(),await m(this,d,U).call(this,t,!0))},b.shadowRootOptions={...Ce.shadowRootOptions,delegatesFocus:!0},b.styles=[_e,ke,ze],p([$({attribute:"aria-label"})],b.prototype,"ariaLabel",2),p([$({attribute:"aria-description"})],b.prototype,"ariaDescription",2),p([$({reflect:!0})],b.prototype,"name",2),p([$({reflect:!0})],b.prototype,"value",2),p([$({type:Boolean,reflect:!0})],b.prototype,"disabled",2),p([$({type:Boolean,reflect:!0})],b.prototype,"invalid",2),p([$({attribute:!1,reflect:!1})],b.prototype,"openEnded",2),p([$({reflect:!0})],b.prototype,"placeholder",2),p([N()],b.prototype,"markers",2),p([N()],b.prototype,"required",2),p([N()],b.prototype,"step",2),p([N()],b.prototype,"min",2),p([N()],b.prototype,"max",2),p([N()],b.prototype,"suffix",2),p([$({attribute:!1})],b.prototype,"valueFormatter",2),p([$({attribute:!1})],b.prototype,"tooltipFormatter",2),p([$({attribute:!1})],b.prototype,"labelFormatter",2),p([de('input[type="range"]')],b.prototype,"range",2),p([de(".w-slider-thumb__tooltip-target")],b.prototype,"tooltipTarget",2),p([de("w-textfield")],b.prototype,"textfield",2),p([N()],b.prototype,"_showTooltip",2),p([N()],b.prototype,"_inputHasFocus",2),p([N()],b.prototype,"_hiddenTextfield",2);customElements.get("w-slider-thumb")||customElements.define("w-slider-thumb",b);export{b as WarpSliderThumb};
2775
2774
  //# sourceMappingURL=slider-thumb.js.map