@fluentui/web-components 3.0.0-beta.78 → 3.0.0-beta.79

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.
package/CHANGELOG.md CHANGED
@@ -1,12 +1,21 @@
1
1
  # Change Log - @fluentui/web-components
2
2
 
3
- This log was last generated on Tue, 04 Feb 2025 04:07:07 GMT and should not be manually modified.
3
+ This log was last generated on Fri, 07 Feb 2025 04:07:24 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
+ ## [3.0.0-beta.79](https://github.com/microsoft/fluentui/tree/@fluentui/web-components_v3.0.0-beta.79)
8
+
9
+ Fri, 07 Feb 2025 04:07:24 GMT
10
+ [Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/web-components_v3.0.0-beta.78..@fluentui/web-components_v3.0.0-beta.79)
11
+
12
+ ### Changes
13
+
14
+ - remove unnecessary filtering in menu-item ([PR #33795](https://github.com/microsoft/fluentui/pull/33795) by jes@microsoft.com)
15
+
7
16
  ## [3.0.0-beta.78](https://github.com/microsoft/fluentui/tree/@fluentui/web-components_v3.0.0-beta.78)
8
17
 
9
- Tue, 04 Feb 2025 04:07:07 GMT
18
+ Tue, 04 Feb 2025 04:07:18 GMT
10
19
  [Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/web-components_v3.0.0-beta.77..@fluentui/web-components_v3.0.0-beta.78)
11
20
 
12
21
  ### Changes
@@ -1,4 +1,4 @@
1
- import { type ElementsFilter, FASTElement } from '@microsoft/fast-element';
1
+ import { FASTElement } from '@microsoft/fast-element';
2
2
  import type { StartEndOptions } from '../patterns/start-end.js';
3
3
  import { StartEnd } from '../patterns/start-end.js';
4
4
  import type { StaticallyComposableHTML } from '../utils/template-helpers.js';
@@ -13,11 +13,6 @@ export type MenuItemOptions = StartEndOptions<MenuItem> & {
13
13
  indicator?: StaticallyComposableHTML<MenuItem>;
14
14
  submenuGlyph?: StaticallyComposableHTML<MenuItem>;
15
15
  };
16
- /**
17
- * Creates a function that can be used to filter a Node array, selecting only elements with elementInternals role of "menu".
18
- * @public
19
- */
20
- export declare const menuFilter: () => ElementsFilter;
21
16
  /**
22
17
  * A Switch Custom HTML Element.
23
18
  * Implements {@link https://www.w3.org/TR/wai-aria-1.1/#menuitem | ARIA menuitem }, {@link https://www.w3.org/TR/wai-aria-1.1/#menuitemcheckbox | ARIA menuitemcheckbox}, or {@link https://www.w3.org/TR/wai-aria-1.1/#menuitemradio | ARIA menuitemradio }.
@@ -1,4 +1,4 @@
1
1
  import type { ElementViewTemplate } from '@microsoft/fast-element';
2
- import { type MenuItem, type MenuItemOptions } from './menu-item.js';
2
+ import type { MenuItem, MenuItemOptions } from './menu-item.js';
3
3
  export declare function menuItemTemplate<T extends MenuItem>(options?: MenuItemOptions): ElementViewTemplate<T>;
4
4
  export declare const template: ElementViewTemplate<MenuItem>;
@@ -6,11 +6,6 @@ import { applyMixins } from '../utils/apply-mixins.js';
6
6
  import { toggleState } from '../utils/element-internals.js';
7
7
  import { MenuItemRole, roleForMenuItem } from './menu-item.options.js';
8
8
  export { MenuItemRole, roleForMenuItem };
9
- /**
10
- * Creates a function that can be used to filter a Node array, selecting only elements with elementInternals role of "menu".
11
- * @public
12
- */
13
- export const menuFilter = () => value => value.nodeType === 1 && value.elementInternals.role === 'menu';
14
9
  /**
15
10
  * A Switch Custom HTML Element.
16
11
  * Implements {@link https://www.w3.org/TR/wai-aria-1.1/#menuitem | ARIA menuitem }, {@link https://www.w3.org/TR/wai-aria-1.1/#menuitemcheckbox | ARIA menuitemcheckbox}, or {@link https://www.w3.org/TR/wai-aria-1.1/#menuitemradio | ARIA menuitemradio }.
@@ -1 +1 @@
1
- {"version":3,"file":"menu-item.js","sourceRoot":"","sources":["../../../src/menu-item/menu-item.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,IAAI,EAAuB,WAAW,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAC7F,OAAO,EAAE,YAAY,EAAE,aA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AW,GAAG,IAAI,CAAC,IAAI,KAAK,YAAY,CAAC,QAAQ,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC;IACvG,CAAC;CAoJF;AA7PQ;IADN,IAAI,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;0CACA;AAoBnB;IADN,IAAI;sCAC6C;AAmB3C;IADN,IAAI,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;yCACM;AAyBzB;IADN,IAAI,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;wCACF;AAQjB;IADN,UAAU;gDAC2B;AA0B/B;IADN,UAAU;yCAC6B;AAqK1C,WAAW,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC"}
@@ -1,7 +1,6 @@
1
1
  import { html, slotted } from '@microsoft/fast-element';
2
2
  import { staticallyCompose } from '../utils/template-helpers.js';
3
3
  import { endSlotTemplate, startSlotTemplate } from '../patterns/index.js';
4
- import { menuFilter } from './menu-item.js';
5
4
  const Checkmark16Filled = html.partial(`<svg class="indicator" fill="currentColor" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M14.05 3.49c.28.3.27.77-.04 1.06l-7.93 7.47A.85.85 0 014.9 12L2.22 9.28a.75.75 0 111.06-1.06l2.24 2.27 7.47-7.04a.75.75 0 011.06.04z" fill="currentColor"></path></svg>`);
6
5
  const chevronRight16Filled = html.partial(`<svg class="submenu-glyph" fill="currentColor" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.74 3.2a.75.75 0 00-.04 1.06L9.23 8 5.7 11.74a.75.75 0 101.1 1.02l4-4.25a.75.75 0 000-1.02l-4-4.25a.75.75 0 00-1.06-.04z" fill="currentColor"></path></svg>`);
7
6
  export function menuItemTemplate(options = {}) {
@@ -20,7 +19,7 @@ export function menuItemTemplate(options = {}) {
20
19
  </div>
21
20
  ${endSlotTemplate(options)}
22
21
  <slot name="submenu-glyph"> ${staticallyCompose(options.submenuGlyph)} </slot>
23
- <slot name="submenu" ${slotted({ property: 'slottedSubmenu', filter: menuFilter() })}></slot>
22
+ <slot name="submenu" ${slotted({ property: 'slottedSubmenu' })}></slot>
24
23
  </template>
25
24
  `;
26
25
  }
@@ -1 +1 @@
1
- {"version":3,"file":"menu-item.template.js","sourceRoot":"","sources":["../../../src/menu-item/menu-item.template.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,EAAE,eAAe,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAC1E,OAAO,EAAE,UAAU,EAAuC,MAAM,gBAAgB,CAAC;AAEjF,MAAM,iBAAiB,GAAG,IAAI,CAAC,OAAO,CACpC,8TAA8T,CAC/T,CAAC;AACF,MAAM,oBAAoB,GAAG,IAAI,CAAC,OAAO,CACvC,wTAAwT,CACzT,CAAC;AAEF,MAAM,UAAU,gBAAgB,CAAqB,UAA2B,EAAE;IAChF,OAAO,IAAI,CAAG;;kBAEE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,qBAAqB,CAAC,CAAC,CAAC,KAAsB,CAAC;gBAC7D,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,KAAmB,CAAC;oBAClD,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,CAAC,KAAmB,CAAC;mBACnD,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,KAAmB,CAAC;iBACnD,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,a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AAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,KAAmB,CAAC;iBACnD,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,KAAoB,CAAC;;gCAElC,iBAAiB,CAAC,OAAO,CAAC,SAAS,CAAC;QAC5D,iBAAiB,CAAC,OAAO,CAAC;;;;QAI1B,eAAe,CAAC,OAAO,CAAC;oCACI,iBAAiB,CAAC,OAAO,CAAC,YAAY,CAAC;6BAC9C,OAAO,CAAC,EAAE,QAAQ,EAAE,gBAAgB,EAAE,CAAC;;GAEjE,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,QAAQ,GAAkC,gBAAgB,CAAC;IACtE,SAAS,EAAE,iBAAiB;IAC5B,YAAY,EAAE,oBAAoB;CACnC,CAAC,CAAC"}
@@ -8784,7 +8784,6 @@ var __decorateClass$h = (decorators, target, key, kind) => {
8784
8784
  if (kind && result) __defProp$h(target, key, result);
8785
8785
  return result;
8786
8786
  };
8787
- const menuFilter = () => value => value.nodeType === 1 && value.elementInternals.role === "menu";
8788
8787
  class MenuItem extends FASTElement {
8789
8788
  constructor() {
8790
8789
  super(...arguments);
@@ -8995,8 +8994,7 @@ const Checkmark16Filled = html.partial(`<svg class="indicator" fill="currentColo
8995
8994
  const chevronRight16Filled = html.partial(`<svg class="submenu-glyph" fill="currentColor" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.74 3.2a.75.75 0 00-.04 1.06L9.23 8 5.7 11.74a.75.75 0 101.1 1.02l4-4.25a.75.75 0 000-1.02l-4-4.25a.75.75 0 00-1.06-.04z" fill="currentColor"></path></svg>`);
8996
8995
  function menuItemTemplate(options = {}) {
8997
8996
  return html`<template @keydown="${(x, c) => x.handleMenuItemKeyDown(c.event)}" @click="${(x, c) => x.handleMenuItemClick(c.event)}" @mouseover="${(x, c) => x.handleMouseOver(c.event)}" @mouseout="${(x, c) => x.handleMouseOut(c.event)}" @toggle="${(x, c) => x.toggleHandler(c.event)}"><slot name="indicator">${staticallyCompose(options.indicator)}</slot>${startSlotTemplate(options)}<div part="content" class="content"><slot></slot></div>${endSlotTemplate(options)}<slot name="submenu-glyph">${staticallyCompose(options.submenuGlyph)}</slot><slot name="submenu" ${slotted({
8998
- property: "slottedSubmenu",
8999
- filter: menuFilter()
8997
+ property: "slottedSubmenu"
9000
8998
  })}></slot></template>`;
9001
8999
  }
9002
9000
  const template$k = menuItemTemplate({
@@ -451,24 +451,24 @@ const b=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElem
451
451
  <svg slot="end" fill="currentColor" aria-hidden="true" width="1em" height="1em" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
452
452
  <path d="M15.85 7.65c.2.2.2.5 0 .7l-5.46 5.49a.55.55 0 0 1-.78 0L4.15 8.35a.5.5 0 1 1 .7-.7L10 12.8l5.15-5.16c.2-.2.5-.2.7 0Z" fill="currentColor"></path>
453
453
  </svg>
454
- `)}),gg=pg.compose({name:`${b.prefix}-menu-button`,template:bg,styles:Xi});gg.define(b.registry);const he={menuitem:"menuitem",menuitemcheckbox:"menuitemcheckbox",menuitemradio:"menuitemradio"};he.menuitem+"",he.menuitemcheckbox+"",he.menuitemradio+"";var fg=Object.defineProperty,mg=Object.getOwnPropertyDescriptor,$o=(o,e,t,i)=>{for(var s=i>1?void 0:i?mg(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&fg(e,t,s),s};const $g=()=>o=>o.nodeType===1&&o.elementInternals.role==="menu";class je extends w{constructor(){super(...arguments),this.elementInternals=this.attachInternals(),this.role=he.menuitem,this.checked=!1,this.handleMenuItemKeyDown=e=>{if(e.defaultPrevented)return!1;switch(e.key){case xi:case Ps:return this.invoke(),!1;case vi:return this.disabled||(this.submenu?.togglePopover(!0),this.submenu?.focus()),!1;case $i:return this.parentElement?.hasAttribute("popover")&&(this.parentElement.togglePopover(!1),this.parentElement.parentElement?.focus()),!1}return!0},this.handleMenuItemClick=e=>(e.defaultPrevented||this.disabled||this.invoke(),!1),this.handleMouseOver=e=>(this.disabled||this.submenu?.togglePopover(!0),!1),this.handleMouseOut=e=>(this.contains(document.activeElement)||this.submenu?.togglePopover(!1),!1),this.toggleHandler=e=>{e instanceof ToggleEvent&&e.newState==="open"&&(this.setAttribute("tabindex","-1"),this.elementInternals.ariaExpanded="true",this.setSubmenuPosition()),e instanceof ToggleEvent&&e.newState==="closed"&&(this.elementInternals.ariaExpanded="false",this.setAttribute("tabindex","0"))},this.invoke=()=>{if(!this.disabled)switch(this.role){case he.menuitemcheckbox:this.checked=!this.checked;break;case he.menuitem:if(this.submenu){this.submenu.togglePopover(!0),this.submenu.focus();break}this.$emit("change");break;case he.menuitemradio:this.checked||(this.checked=!0);break}},this.setSubmenuPosition=()=>{if(!CSS.supports("anchor-name","--anchor")&&this.submenu){const e=this.getBoundingClientRect(),t=this.submenu.getBoundingClientRect(),i=getComputedStyle(this).direction==="ltr"?"right":"left";if(e.width+t.width>window.innerWidth*.75){this.submenu.style.translate="0 -100%";return}if(e[i]+t.width>window.innerWidth){this.submenu.style.translate="-100% 0";return}this.submenu.style.translate=`${e.width-8}px 0`}}}disabledChanged(e,t){this.elementInternals.ariaDisabled=t?`${t}`:null,v(this.elementInternals,"disabled",t)}roleChanged(e,t){this.elementInternals.role=t??he.menuitem}checkedChanged(e,t){const i=this.role!==he.menuitem;this.elementInternals.ariaChecked=i?`${!!t}`:null,v(this.elementInternals,"checked",i?t:!1),this.$fastController.isConnected&&this.$emit("change",t,{bubbles:!0})}slottedSubmenuChanged(e,t){this.submenu?.removeEventListener("toggle",this.toggleHandler),t.length?(this.submenu=t[0],this.submenu.toggleAttribute("popover",!0),this.submenu.addEventListener("toggle",this.toggleHandler),this.elementInternals.ariaHasPopup="menu",v(this.elementInternals,"submenu",!0)):(this.elementInternals.ariaHasPopup=null,v(this.elementInternals,"submenu",!1))}connectedCallback(){super.connectedCallback(),this.elementInternals.role=this.role??he.menuitem,this.elementInternals.ariaChecked=this.role!==he.menuitem?`${!!this.checked}`:null}}$o([a({mode:"boolean"})],je.prototype,"disabled",2),$o([a],je.prototype,"role",2),$o([a({mode:"boolean"})],je.prototype,"checked",2),$o([a({mode:"boolean"})],je.prototype,"hidden",2),$o([$],je.prototype,"slottedSubmenu",2),$o([$],je.prototype,"submenu",2),nt(je,rt);const vg=p`
454
+ `)}),gg=pg.compose({name:`${b.prefix}-menu-button`,template:bg,styles:Xi});gg.define(b.registry);const he={menuitem:"menuitem",menuitemcheckbox:"menuitemcheckbox",menuitemradio:"menuitemradio"};he.menuitem+"",he.menuitemcheckbox+"",he.menuitemradio+"";var fg=Object.defineProperty,mg=Object.getOwnPropertyDescriptor,$o=(o,e,t,i)=>{for(var s=i>1?void 0:i?mg(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&fg(e,t,s),s};class je extends w{constructor(){super(...arguments),this.elementInternals=this.attachInternals(),this.role=he.menuitem,this.checked=!1,this.handleMenuItemKeyDown=e=>{if(e.defaultPrevented)return!1;switch(e.key){case xi:case Ps:return this.invoke(),!1;case vi:return this.disabled||(this.submenu?.togglePopover(!0),this.submenu?.focus()),!1;case $i:return this.parentElement?.hasAttribute("popover")&&(this.parentElement.togglePopover(!1),this.parentElement.parentElement?.focus()),!1}return!0},this.handleMenuItemClick=e=>(e.defaultPrevented||this.disabled||this.invoke(),!1),this.handleMouseOver=e=>(this.disabled||this.submenu?.togglePopover(!0),!1),this.handleMouseOut=e=>(this.contains(document.activeElement)||this.submenu?.togglePopover(!1),!1),this.toggleHandler=e=>{e instanceof ToggleEvent&&e.newState==="open"&&(this.setAttribute("tabindex","-1"),this.elementInternals.ariaExpanded="true",this.setSubmenuPosition()),e instanceof ToggleEvent&&e.newState==="closed"&&(this.elementInternals.ariaExpanded="false",this.setAttribute("tabindex","0"))},this.invoke=()=>{if(!this.disabled)switch(this.role){case he.menuitemcheckbox:this.checked=!this.checked;break;case he.menuitem:if(this.submenu){this.submenu.togglePopover(!0),this.submenu.focus();break}this.$emit("change");break;case he.menuitemradio:this.checked||(this.checked=!0);break}},this.setSubmenuPosition=()=>{if(!CSS.supports("anchor-name","--anchor")&&this.submenu){const e=this.getBoundingClientRect(),t=this.submenu.getBoundingClientRect(),i=getComputedStyle(this).direction==="ltr"?"right":"left";if(e.width+t.width>window.innerWidth*.75){this.submenu.style.translate="0 -100%";return}if(e[i]+t.width>window.innerWidth){this.submenu.style.translate="-100% 0";return}this.submenu.style.translate=`${e.width-8}px 0`}}}disabledChanged(e,t){this.elementInternals.ariaDisabled=t?`${t}`:null,v(this.elementInternals,"disabled",t)}roleChanged(e,t){this.elementInternals.role=t??he.menuitem}checkedChanged(e,t){const i=this.role!==he.menuitem;this.elementInternals.ariaChecked=i?`${!!t}`:null,v(this.elementInternals,"checked",i?t:!1),this.$fastController.isConnected&&this.$emit("change",t,{bubbles:!0})}slottedSubmenuChanged(e,t){this.submenu?.removeEventListener("toggle",this.toggleHandler),t.length?(this.submenu=t[0],this.submenu.toggleAttribute("popover",!0),this.submenu.addEventListener("toggle",this.toggleHandler),this.elementInternals.ariaHasPopup="menu",v(this.elementInternals,"submenu",!0)):(this.elementInternals.ariaHasPopup=null,v(this.elementInternals,"submenu",!1))}connectedCallback(){super.connectedCallback(),this.elementInternals.role=this.role??he.menuitem,this.elementInternals.ariaChecked=this.role!==he.menuitem?`${!!this.checked}`:null}}$o([a({mode:"boolean"})],je.prototype,"disabled",2),$o([a],je.prototype,"role",2),$o([a({mode:"boolean"})],je.prototype,"checked",2),$o([a({mode:"boolean"})],je.prototype,"hidden",2),$o([$],je.prototype,"slottedSubmenu",2),$o([$],je.prototype,"submenu",2),nt(je,rt);const $g=p`
455
455
  ${I("grid")}
456
456
 
457
457
  :host{--indent:0;align-items:center;background:${E};border-radius:${T};color:${Le};contain:layout;cursor:pointer;flex-shrink:0;font:${R} ${M} / ${j} ${k};grid-gap:4px;grid-template-columns:20px 20px auto 20px;height:32px;overflow:visible;padding:0 10px}:host(:hover){background:${Oi};color:${Fo}}:host(:active){background-color:${Ln};color:${No}}:host(:active) ::slotted([slot='start']){color:${Id}}:host(${_}){background-color:${kt};color:${A}}:host(${_}) ::slotted([slot='start']),:host(${_}) ::slotted([slot='end']){color:${A}}:host(:focus-visible){border-radius:${T};outline:2px solid ${Ve}}.content{white-space:nowrap;flex-grow:1;grid-column:auto / span 2;padding:0 2px}:host(:not(${x})) .indicator,:host(:not(${x})) ::slotted([slot='indicator']),:host(:not(${Bi})) .submenu-glyph,:host(:not(${Bi})) ::slotted([slot='submenu-glyph']){display:none}::slotted([slot='end']){color:${be};font:${R} ${G} / ${ee} ${k};white-space:nowrap}:host([data-indent='1']){--indent:1}:host([data-indent='2']){--indent:2;grid-template-columns:20px 20px auto auto}:host(${Bi}){grid-template-columns:20px auto auto 20px}:host([data-indent='2']${Bi}){grid-template-columns:20px 20px auto auto 20px}.indicator,::slotted([slot='indicator']){grid-column:1 / span 1;width:20px}::slotted([slot='start']){display:inline-flex;grid-column:calc(var(--indent)) / span 1}.content{grid-column:calc(var(--indent) + 1) / span 1}::slotted([slot='end']){grid-column:calc(var(--indent) + 2) / span 1;justify-self:end}.submenu-glyph,::slotted([slot='submenu-glyph']){grid-column:-2 / span 1;justify-self:end}@layer popover{:host{anchor-name:--menu-trigger;position:relative}::slotted([popover]){margin:0;max-height:var(--menu-max-height,auto);position:absolute;position-anchor:--menu-trigger;position-area:inline-end span-block-end;position-try-fallbacks:flip-inline;z-index:1}::slotted([popover]:not(:popover-open)){display:none}::slotted([popover]:popover-open){inset:unset}@supports not (anchor-name:--menu-trigger){::slotted([popover]){align-self:start}}}`.withBehaviors(le(p`
458
- :host(${_}),:host(${_}) ::slotted([slot='start']),:host(${_}) ::slotted([slot='end']){color:GrayText}`)),yg=g.partial('<svg class="indicator" fill="currentColor" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M14.05 3.49c.28.3.27.77-.04 1.06l-7.93 7.47A.85.85 0 014.9 12L2.22 9.28a.75.75 0 111.06-1.06l2.24 2.27 7.47-7.04a.75.75 0 011.06.04z" fill="currentColor"></path></svg>'),kg=g.partial('<svg class="submenu-glyph" fill="currentColor" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.74 3.2a.75.75 0 00-.04 1.06L9.23 8 5.7 11.74a.75.75 0 101.1 1.02l4-4.25a.75.75 0 000-1.02l-4-4.25a.75.75 0 00-1.06-.04z" fill="currentColor"></path></svg>');function xg(o={}){return g`<template @keydown="${(e,t)=>e.handleMenuItemKeyDown(t.event)}" @click="${(e,t)=>e.handleMenuItemClick(t.event)}" @mouseover="${(e,t)=>e.handleMouseOver(t.event)}" @mouseout="${(e,t)=>e.handleMouseOut(t.event)}" @toggle="${(e,t)=>e.toggleHandler(t.event)}"><slot name="indicator">${ve(o.indicator)}</slot>${Ke(o)}<div part="content" class="content"><slot></slot></div>${mt(o)}<slot name="submenu-glyph">${ve(o.submenuGlyph)}</slot><slot name="submenu" ${K({property:"slottedSubmenu",filter:$g()})}></slot></template>`}const wg=xg({indicator:yg,submenuGlyph:kg}),Cg=je.compose({name:`${b.prefix}-menu-item`,template:wg,styles:vg});Cg.define(b.registry);var Sg=Object.defineProperty,Ig=Object.getOwnPropertyDescriptor,zg=(o,e,t,i)=>{for(var s=i>1?void 0:i?Ig(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Sg(e,t,s),s};const ur=class yr extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.focusIndex=-1,this.isNestedMenu=()=>this.parentElement!==null&&Cn(this.parentElement)&&this.parentElement.getAttribute("role")==="menuitem",this.handleFocusOut=e=>{if(!this.contains(e.relatedTarget)&&this.menuItems!==void 0){const t=this.menuItems.findIndex(this.isFocusableElement);this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.menuItems[t].setAttribute("tabindex","0"),this.focusIndex=t}},this.handleItemFocus=e=>{const t=e.target;this.menuItems!==void 0&&t!==this.menuItems[this.focusIndex]&&(this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0"))},this.changedMenuItemHandler=e=>{if(this.menuItems===void 0)return;const t=e.target,i=this.menuItems.indexOf(t);if(i!==-1&&t.role==="menuitemradio"&&t.checked===!0){for(let r=i-1;r>=0;--r){const n=this.menuItems[r],d=n.getAttribute("role");if(d===he.menuitemradio&&(n.checked=!1),d==="separator")break}const s=this.menuItems.length-1;for(let r=i+1;r<=s;++r){const n=this.menuItems[r],d=n.getAttribute("role");if(d===he.menuitemradio&&(n.checked=!1),d==="separator")break}}},this.isMenuItemElement=e=>e instanceof je||Cn(e)&&e.getAttribute("role")in yr.focusableElementRoles,this.isFocusableElement=e=>this.isMenuItemElement(e),this.elementInternals.role="menu"}itemsChanged(e,t){this.$fastController.isConnected&&this.menuItems!==void 0&&this.setItems()}connectedCallback(){super.connectedCallback(),ne.enqueue(()=>{this.setItems()}),this.addEventListener("change",this.changedMenuItemHandler)}disconnectedCallback(){super.disconnectedCallback(),this.removeItemListeners(),this.menuItems=void 0,this.removeEventListener("change",this.changedMenuItemHandler)}focus(){this.setFocus(0,1)}handleMenuKeyDown(e){if(!(e.defaultPrevented||this.menuItems===void 0))switch(e.key){case mi:this.setFocus(this.focusIndex+1,1);return;case yi:this.setFocus(this.focusIndex-1,-1);return;case ki:this.setFocus(this.menuItems.length-1,-1);return;case wi:this.setFocus(0,1);return;default:return!0}}removeItemListeners(e=this.items){e.forEach(t=>{t.removeEventListener("focus",this.handleItemFocus),f.getNotifier(t).unsubscribe(this,"hidden")})}static elementIndent(e){const t=e.getAttribute("role"),i=e.querySelector("[slot=start]");return t&&t!==he.menuitem?i?2:1:i?1:0}setItems(){const e=Array.from(this.children);this.removeItemListeners(e),e.forEach(n=>f.getNotifier(n).subscribe(this,"hidden"));const t=e.filter(n=>!n.hasAttribute("hidden"));this.menuItems=t;const i=this.menuItems.filter(this.isMenuItemElement);i.length&&(this.focusIndex=0),i.forEach((n,d)=>{n.setAttribute("tabindex",d===0?"0":"-1"),n.addEventListener("focus",this.handleItemFocus)});const s=this.menuItems?.filter(this.isMenuItemElement),r=s?.reduce((n,d)=>{const u=yr.elementIndent(d);return Math.max(n,u)},0);s?.forEach(n=>{n instanceof je&&n.setAttribute("data-indent",`${r}`)})}handleChange(e,t){t==="hidden"&&this.setItems()}setFocus(e,t){if(this.menuItems!==void 0)for(;e>=0&&e<this.menuItems.length;){const i=this.menuItems[e];if(this.isFocusableElement(i)){this.focusIndex>-1&&this.menuItems.length>=this.focusIndex-1&&this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=e,i.setAttribute("tabindex","0"),i.focus();break}e+=t}}};ur.focusableElementRoles=he,zg([$],ur.prototype,"items",2);let Pg=ur;const Tg=p`
458
+ :host(${_}),:host(${_}) ::slotted([slot='start']),:host(${_}) ::slotted([slot='end']){color:GrayText}`)),vg=g.partial('<svg class="indicator" fill="currentColor" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M14.05 3.49c.28.3.27.77-.04 1.06l-7.93 7.47A.85.85 0 014.9 12L2.22 9.28a.75.75 0 111.06-1.06l2.24 2.27 7.47-7.04a.75.75 0 011.06.04z" fill="currentColor"></path></svg>'),yg=g.partial('<svg class="submenu-glyph" fill="currentColor" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.74 3.2a.75.75 0 00-.04 1.06L9.23 8 5.7 11.74a.75.75 0 101.1 1.02l4-4.25a.75.75 0 000-1.02l-4-4.25a.75.75 0 00-1.06-.04z" fill="currentColor"></path></svg>');function kg(o={}){return g`<template @keydown="${(e,t)=>e.handleMenuItemKeyDown(t.event)}" @click="${(e,t)=>e.handleMenuItemClick(t.event)}" @mouseover="${(e,t)=>e.handleMouseOver(t.event)}" @mouseout="${(e,t)=>e.handleMouseOut(t.event)}" @toggle="${(e,t)=>e.toggleHandler(t.event)}"><slot name="indicator">${ve(o.indicator)}</slot>${Ke(o)}<div part="content" class="content"><slot></slot></div>${mt(o)}<slot name="submenu-glyph">${ve(o.submenuGlyph)}</slot><slot name="submenu" ${K({property:"slottedSubmenu"})}></slot></template>`}const xg=kg({indicator:vg,submenuGlyph:yg}),wg=je.compose({name:`${b.prefix}-menu-item`,template:xg,styles:$g});wg.define(b.registry);var Cg=Object.defineProperty,Sg=Object.getOwnPropertyDescriptor,Ig=(o,e,t,i)=>{for(var s=i>1?void 0:i?Sg(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Cg(e,t,s),s};const ur=class yr extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.focusIndex=-1,this.isNestedMenu=()=>this.parentElement!==null&&Cn(this.parentElement)&&this.parentElement.getAttribute("role")==="menuitem",this.handleFocusOut=e=>{if(!this.contains(e.relatedTarget)&&this.menuItems!==void 0){const t=this.menuItems.findIndex(this.isFocusableElement);this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.menuItems[t].setAttribute("tabindex","0"),this.focusIndex=t}},this.handleItemFocus=e=>{const t=e.target;this.menuItems!==void 0&&t!==this.menuItems[this.focusIndex]&&(this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0"))},this.changedMenuItemHandler=e=>{if(this.menuItems===void 0)return;const t=e.target,i=this.menuItems.indexOf(t);if(i!==-1&&t.role==="menuitemradio"&&t.checked===!0){for(let r=i-1;r>=0;--r){const n=this.menuItems[r],d=n.getAttribute("role");if(d===he.menuitemradio&&(n.checked=!1),d==="separator")break}const s=this.menuItems.length-1;for(let r=i+1;r<=s;++r){const n=this.menuItems[r],d=n.getAttribute("role");if(d===he.menuitemradio&&(n.checked=!1),d==="separator")break}}},this.isMenuItemElement=e=>e instanceof je||Cn(e)&&e.getAttribute("role")in yr.focusableElementRoles,this.isFocusableElement=e=>this.isMenuItemElement(e),this.elementInternals.role="menu"}itemsChanged(e,t){this.$fastController.isConnected&&this.menuItems!==void 0&&this.setItems()}connectedCallback(){super.connectedCallback(),ne.enqueue(()=>{this.setItems()}),this.addEventListener("change",this.changedMenuItemHandler)}disconnectedCallback(){super.disconnectedCallback(),this.removeItemListeners(),this.menuItems=void 0,this.removeEventListener("change",this.changedMenuItemHandler)}focus(){this.setFocus(0,1)}handleMenuKeyDown(e){if(!(e.defaultPrevented||this.menuItems===void 0))switch(e.key){case mi:this.setFocus(this.focusIndex+1,1);return;case yi:this.setFocus(this.focusIndex-1,-1);return;case ki:this.setFocus(this.menuItems.length-1,-1);return;case wi:this.setFocus(0,1);return;default:return!0}}removeItemListeners(e=this.items){e.forEach(t=>{t.removeEventListener("focus",this.handleItemFocus),f.getNotifier(t).unsubscribe(this,"hidden")})}static elementIndent(e){const t=e.getAttribute("role"),i=e.querySelector("[slot=start]");return t&&t!==he.menuitem?i?2:1:i?1:0}setItems(){const e=Array.from(this.children);this.removeItemListeners(e),e.forEach(n=>f.getNotifier(n).subscribe(this,"hidden"));const t=e.filter(n=>!n.hasAttribute("hidden"));this.menuItems=t;const i=this.menuItems.filter(this.isMenuItemElement);i.length&&(this.focusIndex=0),i.forEach((n,d)=>{n.setAttribute("tabindex",d===0?"0":"-1"),n.addEventListener("focus",this.handleItemFocus)});const s=this.menuItems?.filter(this.isMenuItemElement),r=s?.reduce((n,d)=>{const u=yr.elementIndent(d);return Math.max(n,u)},0);s?.forEach(n=>{n instanceof je&&n.setAttribute("data-indent",`${r}`)})}handleChange(e,t){t==="hidden"&&this.setItems()}setFocus(e,t){if(this.menuItems!==void 0)for(;e>=0&&e<this.menuItems.length;){const i=this.menuItems[e];if(this.isFocusableElement(i)){this.focusIndex>-1&&this.menuItems.length>=this.focusIndex-1&&this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=e,i.setAttribute("tabindex","0"),i.focus();break}e+=t}}};ur.focusableElementRoles=he,Ig([$],ur.prototype,"items",2);let zg=ur;const Pg=p`
459
459
  ${I("flex")}
460
460
 
461
- :host{flex-direction:column;height:fit-content;max-width:300px;min-width:160px;width:auto;background-color:${E};border:1px solid ${ce};border-radius:${T};box-shadow:${Qs};padding:4px;row-gap:2px}`;function Bg(){return g`<template slot="${o=>o.slot?o.slot:o.isNestedMenu()?"submenu":void 0}" @keydown="${(o,e)=>o.handleMenuKeyDown(e.event)}" @focusout="${(o,e)=>o.handleFocusOut(e.event)}"><slot ${K("items")}></slot></template>`}const Ag=Bg(),Eg=Pg.compose({name:`${b.prefix}-menu-list`,template:Ag,styles:Tg});Eg.define(b.registry);var Og=Object.defineProperty,Fg=Object.getOwnPropertyDescriptor,St=(o,e,t,i)=>{for(var s=i>1?void 0:i?Fg(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Og(e,t,s),s};class pt extends w{constructor(){super(...arguments),this.slottedMenuList=[],this.slottedTriggers=[],this._open=!1,this.toggleMenu=()=>{this._menuList?.togglePopover(!this._open)},this.closeMenu=e=>{e?.target instanceof je&&(e.target.getAttribute("role")===he.menuitemcheckbox||e.target.getAttribute("role")===he.menuitemradio)||(this._menuList?.togglePopover(!1),this.closeOnScroll&&document.removeEventListener("scroll",this.closeMenu))},this.openMenu=e=>{this._menuList?.togglePopover(!0),e&&this.openOnContext&&e.preventDefault(),this.closeOnScroll&&document.addEventListener("scroll",this.closeMenu)},this.toggleHandler=e=>{if(e.type==="toggle"&&e.newState){const t=e.newState==="open";this._trigger?.setAttribute("aria-expanded",`${t}`),this._open=t,this.focusMenuList()}},this.triggerKeydownHandler=e=>{if(e.defaultPrevented)return;switch(e.key){case Ps:case xi:e.preventDefault(),this.toggleMenu();break;default:return!0}},this.documentClickHandler=e=>{e.composedPath().some(t=>t===this._trigger||t===this._menuList)||this.closeMenu()}}connectedCallback(){super.connectedCallback(),ne.enqueue(()=>this.setComponent())}disconnectedCallback(){super.disconnectedCallback(),this.removeListeners()}setComponent(){this.$fastController.isConnected&&this.slottedMenuList.length&&this.slottedTriggers.length&&(this._trigger=this.slottedTriggers[0],this._menuList=this.slottedMenuList[0],this._trigger.setAttribute("aria-haspopup","true"),this._trigger.setAttribute("aria-expanded",`${this._open}`),this._menuList.setAttribute("popover",this.openOnContext?"manual":""),this.addListeners())}focusMenuList(){ne.enqueue(()=>{this._menuList.focus()})}focusTrigger(){ne.enqueue(()=>{this._trigger.focus()})}openOnHoverChanged(e,t){t?this._trigger?.addEventListener("mouseover",this.openMenu):this._trigger?.removeEventListener("mouseover",this.openMenu)}persistOnItemClickChanged(e,t){t?this._menuList?.removeEventListener("change",this.closeMenu):this._menuList?.addEventListener("change",this.closeMenu)}openOnContextChanged(e,t){t?this._trigger?.addEventListener("contextmenu",this.openMenu):this._trigger?.removeEventListener("contextmenu",this.openMenu)}closeOnScrollChanged(e,t){t?document.addEventListener("scroll",this.closeMenu):document.removeEventListener("scroll",this.closeMenu)}addListeners(){this._menuList?.addEventListener("toggle",this.toggleHandler),this._trigger?.addEventListener("keydown",this.triggerKeydownHandler),this.persistOnItemClick||this._menuList?.addEventListener("change",this.closeMenu),this.openOnHover?this._trigger?.addEventListener("mouseover",this.openMenu):this.openOnContext?(this._trigger?.addEventListener("contextmenu",this.openMenu),document.addEventListener("click",this.documentClickHandler)):this._trigger?.addEventListener("click",this.toggleMenu)}removeListeners(){this._menuList?.removeEventListener("toggle",this.toggleHandler),this._trigger?.removeEventListener("keydown",this.triggerKeydownHandler),this.persistOnItemClick||this._menuList?.removeEventListener("change",this.closeMenu),this.openOnHover&&this._trigger?.removeEventListener("mouseover",this.openMenu),this.openOnContext?(this._trigger?.removeEventListener("contextmenu",this.openMenu),document.removeEventListener("click",this.documentClickHandler)):this._trigger?.removeEventListener("click",this.toggleMenu)}menuKeydownHandler(e){if(e.defaultPrevented)return;switch(e.key){case Ol:e.preventDefault(),this._open&&(this.closeMenu(),this.focusTrigger());break;case Fl:if(this._open&&this.closeMenu(),e.shiftKey&&e.composedPath()[0]!==this._trigger&&e.composedPath()[0].assignedSlot!==this.primaryAction)this.focusTrigger();else if(e.shiftKey)return!0;default:return!0}}}St([a({attribute:"open-on-hover",mode:"boolean"})],pt.prototype,"openOnHover",2),St([a({attribute:"open-on-context",mode:"boolean"})],pt.prototype,"openOnContext",2),St([a({attribute:"close-on-scroll",mode:"boolean"})],pt.prototype,"closeOnScroll",2),St([a({attribute:"persist-on-item-click",mode:"boolean"})],pt.prototype,"persistOnItemClick",2),St([a({mode:"boolean"})],pt.prototype,"split",2),St([$],pt.prototype,"slottedMenuList",2),St([$],pt.prototype,"slottedTriggers",2),St([$],pt.prototype,"primaryAction",2);const Ng=p`
461
+ :host{flex-direction:column;height:fit-content;max-width:300px;min-width:160px;width:auto;background-color:${E};border:1px solid ${ce};border-radius:${T};box-shadow:${Qs};padding:4px;row-gap:2px}`;function Tg(){return g`<template slot="${o=>o.slot?o.slot:o.isNestedMenu()?"submenu":void 0}" @keydown="${(o,e)=>o.handleMenuKeyDown(e.event)}" @focusout="${(o,e)=>o.handleFocusOut(e.event)}"><slot ${K("items")}></slot></template>`}const Bg=Tg(),Ag=zg.compose({name:`${b.prefix}-menu-list`,template:Bg,styles:Pg});Ag.define(b.registry);var Eg=Object.defineProperty,Og=Object.getOwnPropertyDescriptor,St=(o,e,t,i)=>{for(var s=i>1?void 0:i?Og(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Eg(e,t,s),s};class pt extends w{constructor(){super(...arguments),this.slottedMenuList=[],this.slottedTriggers=[],this._open=!1,this.toggleMenu=()=>{this._menuList?.togglePopover(!this._open)},this.closeMenu=e=>{e?.target instanceof je&&(e.target.getAttribute("role")===he.menuitemcheckbox||e.target.getAttribute("role")===he.menuitemradio)||(this._menuList?.togglePopover(!1),this.closeOnScroll&&document.removeEventListener("scroll",this.closeMenu))},this.openMenu=e=>{this._menuList?.togglePopover(!0),e&&this.openOnContext&&e.preventDefault(),this.closeOnScroll&&document.addEventListener("scroll",this.closeMenu)},this.toggleHandler=e=>{if(e.type==="toggle"&&e.newState){const t=e.newState==="open";this._trigger?.setAttribute("aria-expanded",`${t}`),this._open=t,this.focusMenuList()}},this.triggerKeydownHandler=e=>{if(e.defaultPrevented)return;switch(e.key){case Ps:case xi:e.preventDefault(),this.toggleMenu();break;default:return!0}},this.documentClickHandler=e=>{e.composedPath().some(t=>t===this._trigger||t===this._menuList)||this.closeMenu()}}connectedCallback(){super.connectedCallback(),ne.enqueue(()=>this.setComponent())}disconnectedCallback(){super.disconnectedCallback(),this.removeListeners()}setComponent(){this.$fastController.isConnected&&this.slottedMenuList.length&&this.slottedTriggers.length&&(this._trigger=this.slottedTriggers[0],this._menuList=this.slottedMenuList[0],this._trigger.setAttribute("aria-haspopup","true"),this._trigger.setAttribute("aria-expanded",`${this._open}`),this._menuList.setAttribute("popover",this.openOnContext?"manual":""),this.addListeners())}focusMenuList(){ne.enqueue(()=>{this._menuList.focus()})}focusTrigger(){ne.enqueue(()=>{this._trigger.focus()})}openOnHoverChanged(e,t){t?this._trigger?.addEventListener("mouseover",this.openMenu):this._trigger?.removeEventListener("mouseover",this.openMenu)}persistOnItemClickChanged(e,t){t?this._menuList?.removeEventListener("change",this.closeMenu):this._menuList?.addEventListener("change",this.closeMenu)}openOnContextChanged(e,t){t?this._trigger?.addEventListener("contextmenu",this.openMenu):this._trigger?.removeEventListener("contextmenu",this.openMenu)}closeOnScrollChanged(e,t){t?document.addEventListener("scroll",this.closeMenu):document.removeEventListener("scroll",this.closeMenu)}addListeners(){this._menuList?.addEventListener("toggle",this.toggleHandler),this._trigger?.addEventListener("keydown",this.triggerKeydownHandler),this.persistOnItemClick||this._menuList?.addEventListener("change",this.closeMenu),this.openOnHover?this._trigger?.addEventListener("mouseover",this.openMenu):this.openOnContext?(this._trigger?.addEventListener("contextmenu",this.openMenu),document.addEventListener("click",this.documentClickHandler)):this._trigger?.addEventListener("click",this.toggleMenu)}removeListeners(){this._menuList?.removeEventListener("toggle",this.toggleHandler),this._trigger?.removeEventListener("keydown",this.triggerKeydownHandler),this.persistOnItemClick||this._menuList?.removeEventListener("change",this.closeMenu),this.openOnHover&&this._trigger?.removeEventListener("mouseover",this.openMenu),this.openOnContext?(this._trigger?.removeEventListener("contextmenu",this.openMenu),document.removeEventListener("click",this.documentClickHandler)):this._trigger?.removeEventListener("click",this.toggleMenu)}menuKeydownHandler(e){if(e.defaultPrevented)return;switch(e.key){case Ol:e.preventDefault(),this._open&&(this.closeMenu(),this.focusTrigger());break;case Fl:if(this._open&&this.closeMenu(),e.shiftKey&&e.composedPath()[0]!==this._trigger&&e.composedPath()[0].assignedSlot!==this.primaryAction)this.focusTrigger();else if(e.shiftKey)return!0;default:return!0}}}St([a({attribute:"open-on-hover",mode:"boolean"})],pt.prototype,"openOnHover",2),St([a({attribute:"open-on-context",mode:"boolean"})],pt.prototype,"openOnContext",2),St([a({attribute:"close-on-scroll",mode:"boolean"})],pt.prototype,"closeOnScroll",2),St([a({attribute:"persist-on-item-click",mode:"boolean"})],pt.prototype,"persistOnItemClick",2),St([a({mode:"boolean"})],pt.prototype,"split",2),St([$],pt.prototype,"slottedMenuList",2),St([$],pt.prototype,"slottedTriggers",2),St([$],pt.prototype,"primaryAction",2);const Fg=p`
462
462
  ${I("inline-block")}
463
463
 
464
- ::slotted([slot='trigger']){anchor-name:--menu-trigger}::slotted([popover]){margin:0;max-height:var(--menu-max-height,auto);position-anchor:--menu-trigger;position-area:block-end span-inline-end;position-try-fallbacks:flip-block;position:absolute;z-index:1}:host([split]) ::slotted([popover]){position-area:block-end span-inline-start}::slotted([popover]:popover-open){inset:unset}::slotted([popover]:not(:popover-open)){display:none}:host([split]){display:inline-flex}:host([split]) ::slotted([slot='primary-action']){border-inline-end:${N} solid ${Ze};border-start-end-radius:0;border-end-end-radius:0}:host([split]) ::slotted([slot='primary-action']:focus-visible){z-index:1}:host([split]) ::slotted([slot='primary-action'][appearance='primary']){border-inline-end:${N} solid white}:host([split]) ::slotted([slot='trigger']){border-inline-start:0;border-start-start-radius:0;border-end-start-radius:0}`;function _g(){return g`<template ?open-on-hover="${o=>o.openOnHover}" ?open-on-context="${o=>o.openOnContext}" ?close-on-scroll="${o=>o.closeOnScroll}" ?persist-on-item-click="${o=>o.persistOnItemClick}" @keydown="${(o,e)=>o.menuKeydownHandler(e.event)}"><slot name="primary-action" ${X("primaryAction")}></slot><slot name="trigger" ${K({property:"slottedTriggers",filter:Bt()})}></slot><slot ${K({property:"slottedMenuList",filter:Bt()})}></slot></template>`}const Mg=_g(),Dg=pt.compose({name:`${b.prefix}-menu`,template:Mg,styles:Ng});Dg.define(b.registry);const Lg={multiline:"multiline",singleline:"singleline"},Vg={rounded:"rounded",square:"square"},Hg={success:"success",warning:"warning",error:"error",info:"info"};var Rg=Object.defineProperty,jg=Object.getOwnPropertyDescriptor,pr=(o,e,t,i)=>{for(var s=i>1?void 0:i?jg(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Rg(e,t,s),s};class os extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.dismissMessageBar=()=>{this.$emit("dismiss",{})},this.elementInternals.role="status"}shapeChanged(e,t){y(this.elementInternals,e,t,Vg)}layoutChanged(e,t){y(this.elementInternals,e,t,Lg)}intentChanged(e,t){y(this.elementInternals,e,t,Hg)}}pr([a],os.prototype,"shape",2),pr([a],os.prototype,"layout",2),pr([a],os.prototype,"intent",2);const qg=p`
464
+ ::slotted([slot='trigger']){anchor-name:--menu-trigger}::slotted([popover]){margin:0;max-height:var(--menu-max-height,auto);position-anchor:--menu-trigger;position-area:block-end span-inline-end;position-try-fallbacks:flip-block;position:absolute;z-index:1}:host([split]) ::slotted([popover]){position-area:block-end span-inline-start}::slotted([popover]:popover-open){inset:unset}::slotted([popover]:not(:popover-open)){display:none}:host([split]){display:inline-flex}:host([split]) ::slotted([slot='primary-action']){border-inline-end:${N} solid ${Ze};border-start-end-radius:0;border-end-end-radius:0}:host([split]) ::slotted([slot='primary-action']:focus-visible){z-index:1}:host([split]) ::slotted([slot='primary-action'][appearance='primary']){border-inline-end:${N} solid white}:host([split]) ::slotted([slot='trigger']){border-inline-start:0;border-start-start-radius:0;border-end-start-radius:0}`;function Ng(){return g`<template ?open-on-hover="${o=>o.openOnHover}" ?open-on-context="${o=>o.openOnContext}" ?close-on-scroll="${o=>o.closeOnScroll}" ?persist-on-item-click="${o=>o.persistOnItemClick}" @keydown="${(o,e)=>o.menuKeydownHandler(e.event)}"><slot name="primary-action" ${X("primaryAction")}></slot><slot name="trigger" ${K({property:"slottedTriggers",filter:Bt()})}></slot><slot ${K({property:"slottedMenuList",filter:Bt()})}></slot></template>`}const _g=Ng(),Mg=pt.compose({name:`${b.prefix}-menu`,template:_g,styles:Fg});Mg.define(b.registry);const Dg={multiline:"multiline",singleline:"singleline"},Lg={rounded:"rounded",square:"square"},Vg={success:"success",warning:"warning",error:"error",info:"info"};var Hg=Object.defineProperty,Rg=Object.getOwnPropertyDescriptor,pr=(o,e,t,i)=>{for(var s=i>1?void 0:i?Rg(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Hg(e,t,s),s};class os extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.dismissMessageBar=()=>{this.$emit("dismiss",{})},this.elementInternals.role="status"}shapeChanged(e,t){y(this.elementInternals,e,t,Lg)}layoutChanged(e,t){y(this.elementInternals,e,t,Dg)}intentChanged(e,t){y(this.elementInternals,e,t,Vg)}}pr([a],os.prototype,"shape",2),pr([a],os.prototype,"layout",2),pr([a],os.prototype,"intent",2);const jg=p`
465
465
  :host{display:grid;box-sizing:border-box;font-family:${k};font-size:${G};line-height:${ee};width:100%;background:${_o};border:1px solid ${Ze};padding-inline:${xe};border-radius:${T};min-height:36px;align-items:center;grid-template:'icon body actions dismiss' / auto 1fr auto auto;contain:layout style paint}:host(${Ao}){border-radius:0}:host(${Nt}){background-color:${Qn};border-color:${Wd}}:host(${Mt}){background-color:${Jn};border-color:${ta}}:host(${Ns}){background-color:${Gn};border-color:${Xn}}:host(${Bo}){grid-template-areas:'icon body dismiss'
466
- 'actions actions actions';grid-template-columns:auto 1fr auto;grid-template-rows:auto auto 1fr;padding-block:${uo};padding-inline:${xe}}.content{grid-area:body;max-width:520px;padding-block:${uo};padding-inline:0}:host(${Bo}) .content{padding:0}::slotted([slot='icon']){display:flex;grid-area:icon;flex-direction:column;align-items:center;color:${be};margin-inline-end:${Je}}:host(${Bo}) ::slotted([slot='icon']){align-items:start;height:100%}::slotted([slot='dismiss']){grid-area:dismiss}.actions{grid-area:actions;display:flex;justify-self:end;margin-inline-end:${Je};gap:${Je}}:host(${Bo}) .actions{margin-block-start:${uo};margin-inline-end:0}:host(${Bo}) ::slotted([slot='dismiss']){align-items:start;height:100%;padding-block-start:${oe}}::slotted(*){font-size:inherit}`;function Wg(){return g`<slot name="icon"></slot><div class="content"><slot></slot></div><div class="actions"><slot name="actions"></slot></div><slot name="dismiss"></slot>`}const Gg=Wg(),Ug=os.compose({name:`${b.prefix}-message-bar`,template:Gg,styles:qg,shadowOptions:{mode:b.shadowRootMode}});Ug.define(b.registry);var Xg=Object.defineProperty,Kg=Object.getOwnPropertyDescriptor,Pe=(o,e,t,i)=>{for(var s=i>1?void 0:i?Kg(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Xg(e,t,s),s};class $e extends w{constructor(){super(),this.active=!1,this.id=Wo("option-"),this.initialValue="",this.multiple=!1,this.elementInternals=this.attachInternals(),this._value=this.initialValue,this.elementInternals.role="option"}activeChanged(e,t){v(this.elementInternals,"active",t)}currentSelectedChanged(e,t){this.selected=!!t}defaultSelectedChanged(e,t){this.selected=!!t}descriptionSlotChanged(e,t){v(this.elementInternals,"description",!!t?.length)}disabledChanged(e,t){this.elementInternals.ariaDisabled=this.disabled?"true":"false",v(this.elementInternals,"disabled",this.disabled)}disabledAttributeChanged(e,t){this.disabled=!!t}initialValueChanged(e,t){this._value=t}multipleChanged(e,t){v(this.elementInternals,"multiple",t),this.selected=!1}get form(){return this.elementInternals.form}get labels(){return Object.freeze(Array.from(this.elementInternals.labels))}get selected(){return f.track(this,"selected"),!!this.currentSelected}set selected(e){this.currentSelected=e,ne.enqueue(()=>{this.$fastController.isConnected&&(this.setFormValue(e?this.value:null),this.elementInternals.ariaSelected=e?"true":"false",v(this.elementInternals,"selected",e))}),f.notify(this,"selected")}get text(){return this.freeform?this.value.replace(/\s+/g," ").trim():(this.textAttribute??this.textContent)?.replace(/\s+/g," ").trim()??""}get value(){return f.track(this,"value"),this._value??this.text}set value(e){this._value=e,this.$fastController.isConnected&&(this.setFormValue(this.selected?e:null),this.freeformOutputs?.forEach(t=>{t.value=e}),f.notify(this,"value"))}connectedCallback(){super.connectedCallback(),this.freeform&&(this.value="",this.hidden=!0,this.selected=!1)}setFormValue(e,t){if(this.disabled){this.elementInternals.setFormValue(null);return}this.elementInternals.setFormValue(e,e??t)}toggleSelected(e=!this.selected){this.selected=e}}$e.formAssociated=!0,Pe([$],$e.prototype,"active",2),Pe([a({attribute:"current-selected",mode:"boolean"})],$e.prototype,"currentSelected",2),Pe([a({attribute:"selected",mode:"boolean"})],$e.prototype,"defaultSelected",2),Pe([$],$e.prototype,"descriptionSlot",2),Pe([$],$e.prototype,"disabled",2),Pe([a({attribute:"disabled",mode:"boolean"})],$e.prototype,"disabledAttribute",2),Pe([a({attribute:"form"})],$e.prototype,"formAttribute",2),Pe([a({mode:"boolean"})],$e.prototype,"freeform",2),Pe([a({attribute:"id"})],$e.prototype,"id",2),Pe([a({attribute:"value",mode:"fromView"})],$e.prototype,"initialValue",2),Pe([$],$e.prototype,"multiple",2),Pe([a],$e.prototype,"name",2),Pe([$],$e.prototype,"start",2),Pe([a({attribute:"text",mode:"fromView"})],$e.prototype,"textAttribute",2);const Yg=p`
466
+ 'actions actions actions';grid-template-columns:auto 1fr auto;grid-template-rows:auto auto 1fr;padding-block:${uo};padding-inline:${xe}}.content{grid-area:body;max-width:520px;padding-block:${uo};padding-inline:0}:host(${Bo}) .content{padding:0}::slotted([slot='icon']){display:flex;grid-area:icon;flex-direction:column;align-items:center;color:${be};margin-inline-end:${Je}}:host(${Bo}) ::slotted([slot='icon']){align-items:start;height:100%}::slotted([slot='dismiss']){grid-area:dismiss}.actions{grid-area:actions;display:flex;justify-self:end;margin-inline-end:${Je};gap:${Je}}:host(${Bo}) .actions{margin-block-start:${uo};margin-inline-end:0}:host(${Bo}) ::slotted([slot='dismiss']){align-items:start;height:100%;padding-block-start:${oe}}::slotted(*){font-size:inherit}`;function qg(){return g`<slot name="icon"></slot><div class="content"><slot></slot></div><div class="actions"><slot name="actions"></slot></div><slot name="dismiss"></slot>`}const Wg=qg(),Gg=os.compose({name:`${b.prefix}-message-bar`,template:Wg,styles:jg,shadowOptions:{mode:b.shadowRootMode}});Gg.define(b.registry);var Ug=Object.defineProperty,Xg=Object.getOwnPropertyDescriptor,Pe=(o,e,t,i)=>{for(var s=i>1?void 0:i?Xg(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Ug(e,t,s),s};class $e extends w{constructor(){super(),this.active=!1,this.id=Wo("option-"),this.initialValue="",this.multiple=!1,this.elementInternals=this.attachInternals(),this._value=this.initialValue,this.elementInternals.role="option"}activeChanged(e,t){v(this.elementInternals,"active",t)}currentSelectedChanged(e,t){this.selected=!!t}defaultSelectedChanged(e,t){this.selected=!!t}descriptionSlotChanged(e,t){v(this.elementInternals,"description",!!t?.length)}disabledChanged(e,t){this.elementInternals.ariaDisabled=this.disabled?"true":"false",v(this.elementInternals,"disabled",this.disabled)}disabledAttributeChanged(e,t){this.disabled=!!t}initialValueChanged(e,t){this._value=t}multipleChanged(e,t){v(this.elementInternals,"multiple",t),this.selected=!1}get form(){return this.elementInternals.form}get labels(){return Object.freeze(Array.from(this.elementInternals.labels))}get selected(){return f.track(this,"selected"),!!this.currentSelected}set selected(e){this.currentSelected=e,ne.enqueue(()=>{this.$fastController.isConnected&&(this.setFormValue(e?this.value:null),this.elementInternals.ariaSelected=e?"true":"false",v(this.elementInternals,"selected",e))}),f.notify(this,"selected")}get text(){return this.freeform?this.value.replace(/\s+/g," ").trim():(this.textAttribute??this.textContent)?.replace(/\s+/g," ").trim()??""}get value(){return f.track(this,"value"),this._value??this.text}set value(e){this._value=e,this.$fastController.isConnected&&(this.setFormValue(this.selected?e:null),this.freeformOutputs?.forEach(t=>{t.value=e}),f.notify(this,"value"))}connectedCallback(){super.connectedCallback(),this.freeform&&(this.value="",this.hidden=!0,this.selected=!1)}setFormValue(e,t){if(this.disabled){this.elementInternals.setFormValue(null);return}this.elementInternals.setFormValue(e,e??t)}toggleSelected(e=!this.selected){this.selected=e}}$e.formAssociated=!0,Pe([$],$e.prototype,"active",2),Pe([a({attribute:"current-selected",mode:"boolean"})],$e.prototype,"currentSelected",2),Pe([a({attribute:"selected",mode:"boolean"})],$e.prototype,"defaultSelected",2),Pe([$],$e.prototype,"descriptionSlot",2),Pe([$],$e.prototype,"disabled",2),Pe([a({attribute:"disabled",mode:"boolean"})],$e.prototype,"disabledAttribute",2),Pe([a({attribute:"form"})],$e.prototype,"formAttribute",2),Pe([a({mode:"boolean"})],$e.prototype,"freeform",2),Pe([a({attribute:"id"})],$e.prototype,"id",2),Pe([a({attribute:"value",mode:"fromView"})],$e.prototype,"initialValue",2),Pe([$],$e.prototype,"multiple",2),Pe([a],$e.prototype,"name",2),Pe([$],$e.prototype,"start",2),Pe([a({attribute:"text",mode:"fromView"})],$e.prototype,"textAttribute",2);const Kg=p`
467
467
  ${I("inline-grid")}
468
468
 
469
469
  :host{-webkit-tap-highlight-color:transparent;${Aa}
470
470
  align-items:center;background-color:${E};border-radius:${T};border:${ze} solid ${ce};box-sizing:border-box;color:${Le};column-gap:${Ee};cursor:pointer;grid-template-areas:'indicator start content';grid-template-columns:auto auto 1fr;min-height:32px;padding:${de}}.content{grid-area:content;line-height:1}::slotted([slot='start']){grid-area:start}:host(:hover){background-color:${Oi};color:${Fo}}:host(:active){background-color:${Fi};color:${No}}:host(:disabled){background-color:${E};color:${A};cursor:default}.checkmark-16-filled{fill:currentColor;width:16px}slot[name='checked-indicator'] > *,::slotted([slot='checked-indicator']){aspect-ratio:1;flex:0 0 auto;grid-area:indicator;visibility:hidden}:host(${Ms}) :is(slot[name='checked-indicator'] > *,::slotted([slot='checked-indicator'])){visibility:visible}:host(${so}) .checkmark-16-filled,:host(:not(${so})) .checkmark-12-regular{display:none}:host(${so}) .checkmark-12-regular{background-color:${E};border-radius:${He};border:${N} solid ${Qe};box-sizing:border-box;cursor:pointer;fill:transparent;position:relative;visibility:visible;width:16px}:host(${so}${Ms}) .checkmark-12-regular{background-color:${Lt};border-color:${Rt};fill:${Dt}}:host(:disabled${so}) .checkmark-12-regular{border-color:${Ae}}:host(:disabled${so}${Ms}) .checkmark-12-regular{background-color:${kt}}:host(${Gl}){border:${ze} solid ${Ve}}@supports (selector(:host(:has(*)))){:host(:has([slot='start']:not([size='16']))){column-gap:${de}}}:host(${ac}){column-gap:${de};grid-template-areas:'indicator start content'
471
- 'indicator start description'}::slotted([slot='description']){color:${be};grid-area:description;${Ea}}`,Qg=g.partial(`
471
+ 'indicator start description'}::slotted([slot='description']){color:${be};grid-area:description;${Ea}}`,Yg=g.partial(`
472
472
  <svg aria-hidden="true" class="checkmark-16-filled" viewBox="0 0 16 16">
473
473
  <path
474
474
  d="M14.046 3.486a.75.75 0 0 1-.032 1.06l-7.93 7.474a.85.85 0 0 1-1.188-.022l-2.68-2.72a.75.75 0 1 1 1.068-1.053l2.234 2.267l7.468-7.038a.75.75 0 0 1 1.06.032"
@@ -479,27 +479,27 @@ const b=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElem
479
479
  d="M9.854 3.146a.5.5 0 0 1 0 .708l-4.5 4.5a.5.5 0 0 1-.708 0l-2-2a.5.5 0 1 1 .708-.708L5 7.293l4.146-4.147a.5.5 0 0 1 .708 0"
480
480
  />
481
481
  </svg>
482
- `);function Zg(o={}){return g`<slot name="checked-indicator">${ve(o.checkedIndicator)}</slot>${Ke(o)}<div class="content" part="content"><slot ${K({property:"freeformOutputs",filter:Bt("output")})}></slot></div><div class="description" part="description"><slot name="description" ${K("descriptionSlot")}></slot></div>`}const Jg=Zg({checkedIndicator:Qg}),ef=$e.compose({name:`${b.prefix}-option`,template:Jg,styles:Yg});ef.define(b.registry);const tf={medium:"medium",large:"large"},of={rounded:"rounded",square:"square"},sf={success:"success",warning:"warning",error:"error"};var rf=Object.defineProperty,nf=Object.getOwnPropertyDescriptor,Ut=(o,e,t,i)=>{for(var s=i>1?void 0:i?nf(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&rf(e,t,s),s};class vo extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.validationState=null,this.elementInternals.role="progressbar"}validationStateChanged(e,t){y(this.elementInternals,e,t,sf)}valueChanged(e,t){this.elementInternals.ariaValueNow=typeof t=="number"?`${t}`:null}minChanged(e,t){this.elementInternals.ariaValueMin=typeof t=="number"?`${t}`:null}maxChanged(e,t){this.elementInternals.ariaValueMax=typeof t=="number"?`${t}`:null}get percentComplete(){const e=this.min??0,t=this.max??100,i=this.value??0,s=t-e;return s===0?0:Math.fround((i-e)/s*100)}}Ut([a({attribute:"validation-state"})],vo.prototype,"validationState",2),Ut([a({converter:ae})],vo.prototype,"value",2),Ut([a({converter:ae})],vo.prototype,"min",2),Ut([a({converter:ae})],vo.prototype,"max",2),Ut([fs],vo.prototype,"percentComplete",1);class br extends vo{thicknessChanged(e,t){y(this.elementInternals,e,t,tf)}shapeChanged(e,t){y(this.elementInternals,e,t,of)}}Ut([a],br.prototype,"thickness",2),Ut([a],br.prototype,"shape",2);const af=p`
482
+ `);function Qg(o={}){return g`<slot name="checked-indicator">${ve(o.checkedIndicator)}</slot>${Ke(o)}<div class="content" part="content"><slot ${K({property:"freeformOutputs",filter:Bt("output")})}></slot></div><div class="description" part="description"><slot name="description" ${K("descriptionSlot")}></slot></div>`}const Zg=Qg({checkedIndicator:Yg}),Jg=$e.compose({name:`${b.prefix}-option`,template:Zg,styles:Kg});Jg.define(b.registry);const ef={medium:"medium",large:"large"},tf={rounded:"rounded",square:"square"},of={success:"success",warning:"warning",error:"error"};var sf=Object.defineProperty,rf=Object.getOwnPropertyDescriptor,Ut=(o,e,t,i)=>{for(var s=i>1?void 0:i?rf(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&sf(e,t,s),s};class vo extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.validationState=null,this.elementInternals.role="progressbar"}validationStateChanged(e,t){y(this.elementInternals,e,t,of)}valueChanged(e,t){this.elementInternals.ariaValueNow=typeof t=="number"?`${t}`:null}minChanged(e,t){this.elementInternals.ariaValueMin=typeof t=="number"?`${t}`:null}maxChanged(e,t){this.elementInternals.ariaValueMax=typeof t=="number"?`${t}`:null}get percentComplete(){const e=this.min??0,t=this.max??100,i=this.value??0,s=t-e;return s===0?0:Math.fround((i-e)/s*100)}}Ut([a({attribute:"validation-state"})],vo.prototype,"validationState",2),Ut([a({converter:ae})],vo.prototype,"value",2),Ut([a({converter:ae})],vo.prototype,"min",2),Ut([a({converter:ae})],vo.prototype,"max",2),Ut([fs],vo.prototype,"percentComplete",1);class br extends vo{thicknessChanged(e,t){y(this.elementInternals,e,t,ef)}shapeChanged(e,t){y(this.elementInternals,e,t,tf)}}Ut([a],br.prototype,"thickness",2),Ut([a],br.prototype,"shape",2);const nf=p`
483
483
  ${I("block")}
484
484
 
485
485
  :host{width:100%;height:2px;overflow-x:hidden;background-color:${Ni};border-radius:${T};contain:content}:host(${C}){height:4px}:host(${Ao}){border-radius:${Mi}}.indicator{background-color:${Lt};border-radius:inherit;height:100%}:host([value]) .indicator{transition:all 0.2s ease-in-out}:host(:not([value])) .indicator{position:relative;width:33%;background-image:linear-gradient(
486
486
  to right,${Ni} 0%,${Be} 50%,${Ni} 100%
487
487
  );animation-name:indeterminate;animation-duration:3s;animation-timing-function:linear;animation-iteration-count:infinite}:host(${Ns}) .indicator{background-color:${Un}}:host(${Mt}) .indicator{background-color:${ea}}:host(${Nt}) .indicator{background-color:${Zn}}@layer animations{@media (prefers-reduced-motion:no-preference){:host([value]){transition:none}:host(:not([value])) .indicator{animation-duration:0.01ms;animation-iteration-count:1}}}@keyframes indeterminate{0%{inset-inline-start:-33%}100%{inset-inline-start:100%}}`.withBehaviors(le(p`
488
- :host{background-color:CanvasText}.indicator,:host(:is(${Nt},${Mt},${Ns})) .indicator{background-color:Highlight}`));function lf(){return g`<div class="indicator" part="indicator" style="${o=>typeof o.value=="number"?`width: ${o.percentComplete}%`:void 0}"></div>`}const cf=lf(),df=br.compose({name:`${b.prefix}-progress-bar`,template:cf,styles:af});df.define(b.registry);class Ha extends Fe{connectedCallback(){super.connectedCallback(),this.tabIndex=this.disabled?-1:0}constructor(){super(),this.elementInternals.role="radio"}disabledChanged(e,t){super.disabledChanged(e,t),t&&(this.tabIndex=-1),this.$emit("disabled",t,{bubbles:!0})}requiredChanged(){}setFormValue(){}setValidity(){this.elementInternals.setValidity({})}toggleChecked(e=!0){super.toggleChecked(e)}}function Ra(o){const e=o.getRootNode();return e instanceof ShadowRoot?e.activeElement:document.activeElement}const ja=Ce;var hf=Object.defineProperty,uf=Object.getOwnPropertyDescriptor,Xt=(o,e,t,i)=>{for(var s=i>1?void 0:i?uf(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&hf(e,t,s),s};class bt extends w{constructor(){super(),this.dirtyState=!1,this.disabled=!1,this.elementInternals=this.attachInternals(),this.elementInternals.role="radiogroup",this.elementInternals.ariaOrientation=this.orientation??ja.horizontal}checkedIndexChanged(e,t){this.enabledRadios&&this.checkRadio(t)}disabledChanged(e,t){this.$fastController.isConnected&&(this.checkedIndex=-1,this.radios?.forEach(i=>{i.disabled=i.disabledAttribute||this.disabled}),this.restrictFocus())}initialValueChanged(e,t){this.value=t??""}nameChanged(e,t){this.isConnected&&t&&this.radios?.forEach(i=>{i.name=this.name})}orientationChanged(e,t){this.elementInternals.ariaOrientation=this.orientation??ja.horizontal}radiosChanged(e,t){const i=t?.length;if(!i)return;!this.name&&t.every(n=>n.name===t[0].name)&&(this.name=t[0].name);const s=El(this.enabledRadios,n=>n.initialChecked);t.forEach((n,d)=>{n.ariaPosInSet=`${d+1}`,n.ariaSetSize=`${i}`,this.initialValue&&!this.dirtyState?n.checked=n.value===this.initialValue:n.checked=d===s,n.name=this.name??n.name,n.disabled=this.disabled||n.disabledAttribute}),!this.dirtyState&&this.initialValue&&(this.value=this.initialValue),this.value||(this.checkedIndex=s);const r=t.map(n=>n.id).join(" ").trim();r&&this.setAttribute("aria-owns",r),ne.enqueue(()=>{this.restrictFocus()})}requiredChanged(e,t){this.elementInternals.ariaRequired=t?"true":null,this.setValidity()}get enabledRadios(){return this.disabled?[]:this.radios?.filter(e=>!e.disabled)??[]}get validationMessage(){if(this.elementInternals.validationMessage)return this.elementInternals.validationMessage;if(this.enabledRadios?.[0]?.validationMessage)return this.enabledRadios[0].validationMessage;if(!this._validationFallbackMessage){const e=document.createElement("input");e.type="radio",e.required=!0,e.checked=!1,this._validationFallbackMessage=e.validationMessage}return this._validationFallbackMessage}get validity(){return this.elementInternals.validity}get value(){return f.notify(this,"value"),this.enabledRadios.find(e=>e.checked)?.value??null}set value(e){const t=this.enabledRadios.findIndex(i=>i.value===e);this.checkedIndex=t,this.$fastController.isConnected&&(this.setFormValue(e),this.setValidity()),f.track(this,"value")}changeHandler(e){if(this===e.target)return!0;this.dirtyState=!0;const t=this.enabledRadios.indexOf(e.target);return this.checkRadio(t),this.radios?.filter(i=>i.disabled)?.forEach(i=>{i.checked=!1}),!0}checkRadio(e=this.checkedIndex,t=!1){let i=this.checkedIndex;this.enabledRadios.forEach((s,r)=>{const n=r===e;s.checked=n,n&&(i=r,t&&s.$emit("change"))}),this.checkedIndex=i,this.setFormValue(this.value),this.setValidity()}checkValidity(){return this.elementInternals.checkValidity()}clickHandler(e){return this===e.target&&this.enabledRadios[Math.max(0,this.checkedIndex)]?.focus(),!0}focus(){this.enabledRadios[Math.max(0,this.checkedIndex)]?.focus()}focusinHandler(e){return this.disabled||this.enabledRadios.forEach(t=>{t.tabIndex=0}),!0}focusoutHandler(e){return this.radios?.includes(e.relatedTarget)&&this.radios?.some(t=>t.checked)&&this.restrictFocus(),!0}formResetCallback(){this.dirtyState=!1,this.checkedIndex=-1,this.setFormValue(this.value),this.setValidity()}getEnabledIndexInBounds(e,t=this.enabledRadios.length){return t===0?-1:(e+t)%t}keydownHandler(e){const t=As(this)==="rtl",i=this.enabledRadios.findIndex(n=>n===Ra(this))??this.checkedIndex;let s=0;switch(e.key){case"ArrowLeft":{s=t?1:-1;break}case"ArrowUp":{s=-1;break}case"ArrowRight":{s=t?-1:1;break}case"ArrowDown":{s=1;break}case"Tab":{this.restrictFocus();break}case" ":{this.checkRadio();break}}if(!s)return!0;const r=i+s;this.checkRadio(this.getEnabledIndexInBounds(r),!0),this.enabledRadios[this.checkedIndex]?.focus()}disabledRadioHandler(e){e.detail===!0&&e.target.checked&&(this.checkedIndex=-1)}reportValidity(){return this.elementInternals.reportValidity()}restrictFocus(){let e=Math.max(this.checkedIndex,0);const t=this.enabledRadios.indexOf(Ra(this));t!==-1&&(e=t),e=this.getEnabledIndexInBounds(e),this.enabledRadios.forEach((i,s)=>{i.tabIndex=s===e?0:-1})}setFormValue(e,t){this.elementInternals.setFormValue(e,e??t)}setValidity(e,t,i){if(this.$fastController.isConnected){if(this.disabled||!this.required){this.elementInternals.setValidity({});return}this.elementInternals.setValidity({valueMissing:this.required&&!this.value,...e},t??this.validationMessage,i??this.enabledRadios[0])}}slotchangeHandler(e){ne.enqueue(()=>{this.radios=[...this.querySelectorAll("*")].filter(t=>t instanceof Ha)})}}bt.formAssociated=!0,Xt([$],bt.prototype,"checkedIndex",2),Xt([a({attribute:"disabled",mode:"boolean"})],bt.prototype,"disabled",2),Xt([a({attribute:"value",mode:"fromView"})],bt.prototype,"initialValue",2),Xt([a],bt.prototype,"name",2),Xt([a],bt.prototype,"orientation",2),Xt([$],bt.prototype,"radios",2),Xt([a({mode:"boolean"})],bt.prototype,"required",2);const pf=p`
488
+ :host{background-color:CanvasText}.indicator,:host(:is(${Nt},${Mt},${Ns})) .indicator{background-color:Highlight}`));function af(){return g`<div class="indicator" part="indicator" style="${o=>typeof o.value=="number"?`width: ${o.percentComplete}%`:void 0}"></div>`}const lf=af(),cf=br.compose({name:`${b.prefix}-progress-bar`,template:lf,styles:nf});cf.define(b.registry);class Ha extends Fe{connectedCallback(){super.connectedCallback(),this.tabIndex=this.disabled?-1:0}constructor(){super(),this.elementInternals.role="radio"}disabledChanged(e,t){super.disabledChanged(e,t),t&&(this.tabIndex=-1),this.$emit("disabled",t,{bubbles:!0})}requiredChanged(){}setFormValue(){}setValidity(){this.elementInternals.setValidity({})}toggleChecked(e=!0){super.toggleChecked(e)}}function Ra(o){const e=o.getRootNode();return e instanceof ShadowRoot?e.activeElement:document.activeElement}const ja=Ce;var df=Object.defineProperty,hf=Object.getOwnPropertyDescriptor,Xt=(o,e,t,i)=>{for(var s=i>1?void 0:i?hf(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&df(e,t,s),s};class bt extends w{constructor(){super(),this.dirtyState=!1,this.disabled=!1,this.elementInternals=this.attachInternals(),this.elementInternals.role="radiogroup",this.elementInternals.ariaOrientation=this.orientation??ja.horizontal}checkedIndexChanged(e,t){this.enabledRadios&&this.checkRadio(t)}disabledChanged(e,t){this.$fastController.isConnected&&(this.checkedIndex=-1,this.radios?.forEach(i=>{i.disabled=i.disabledAttribute||this.disabled}),this.restrictFocus())}initialValueChanged(e,t){this.value=t??""}nameChanged(e,t){this.isConnected&&t&&this.radios?.forEach(i=>{i.name=this.name})}orientationChanged(e,t){this.elementInternals.ariaOrientation=this.orientation??ja.horizontal}radiosChanged(e,t){const i=t?.length;if(!i)return;!this.name&&t.every(n=>n.name===t[0].name)&&(this.name=t[0].name);const s=El(this.enabledRadios,n=>n.initialChecked);t.forEach((n,d)=>{n.ariaPosInSet=`${d+1}`,n.ariaSetSize=`${i}`,this.initialValue&&!this.dirtyState?n.checked=n.value===this.initialValue:n.checked=d===s,n.name=this.name??n.name,n.disabled=this.disabled||n.disabledAttribute}),!this.dirtyState&&this.initialValue&&(this.value=this.initialValue),this.value||(this.checkedIndex=s);const r=t.map(n=>n.id).join(" ").trim();r&&this.setAttribute("aria-owns",r),ne.enqueue(()=>{this.restrictFocus()})}requiredChanged(e,t){this.elementInternals.ariaRequired=t?"true":null,this.setValidity()}get enabledRadios(){return this.disabled?[]:this.radios?.filter(e=>!e.disabled)??[]}get validationMessage(){if(this.elementInternals.validationMessage)return this.elementInternals.validationMessage;if(this.enabledRadios?.[0]?.validationMessage)return this.enabledRadios[0].validationMessage;if(!this._validationFallbackMessage){const e=document.createElement("input");e.type="radio",e.required=!0,e.checked=!1,this._validationFallbackMessage=e.validationMessage}return this._validationFallbackMessage}get validity(){return this.elementInternals.validity}get value(){return f.notify(this,"value"),this.enabledRadios.find(e=>e.checked)?.value??null}set value(e){const t=this.enabledRadios.findIndex(i=>i.value===e);this.checkedIndex=t,this.$fastController.isConnected&&(this.setFormValue(e),this.setValidity()),f.track(this,"value")}changeHandler(e){if(this===e.target)return!0;this.dirtyState=!0;const t=this.enabledRadios.indexOf(e.target);return this.checkRadio(t),this.radios?.filter(i=>i.disabled)?.forEach(i=>{i.checked=!1}),!0}checkRadio(e=this.checkedIndex,t=!1){let i=this.checkedIndex;this.enabledRadios.forEach((s,r)=>{const n=r===e;s.checked=n,n&&(i=r,t&&s.$emit("change"))}),this.checkedIndex=i,this.setFormValue(this.value),this.setValidity()}checkValidity(){return this.elementInternals.checkValidity()}clickHandler(e){return this===e.target&&this.enabledRadios[Math.max(0,this.checkedIndex)]?.focus(),!0}focus(){this.enabledRadios[Math.max(0,this.checkedIndex)]?.focus()}focusinHandler(e){return this.disabled||this.enabledRadios.forEach(t=>{t.tabIndex=0}),!0}focusoutHandler(e){return this.radios?.includes(e.relatedTarget)&&this.radios?.some(t=>t.checked)&&this.restrictFocus(),!0}formResetCallback(){this.dirtyState=!1,this.checkedIndex=-1,this.setFormValue(this.value),this.setValidity()}getEnabledIndexInBounds(e,t=this.enabledRadios.length){return t===0?-1:(e+t)%t}keydownHandler(e){const t=As(this)==="rtl",i=this.enabledRadios.findIndex(n=>n===Ra(this))??this.checkedIndex;let s=0;switch(e.key){case"ArrowLeft":{s=t?1:-1;break}case"ArrowUp":{s=-1;break}case"ArrowRight":{s=t?-1:1;break}case"ArrowDown":{s=1;break}case"Tab":{this.restrictFocus();break}case" ":{this.checkRadio();break}}if(!s)return!0;const r=i+s;this.checkRadio(this.getEnabledIndexInBounds(r),!0),this.enabledRadios[this.checkedIndex]?.focus()}disabledRadioHandler(e){e.detail===!0&&e.target.checked&&(this.checkedIndex=-1)}reportValidity(){return this.elementInternals.reportValidity()}restrictFocus(){let e=Math.max(this.checkedIndex,0);const t=this.enabledRadios.indexOf(Ra(this));t!==-1&&(e=t),e=this.getEnabledIndexInBounds(e),this.enabledRadios.forEach((i,s)=>{i.tabIndex=s===e?0:-1})}setFormValue(e,t){this.elementInternals.setFormValue(e,e??t)}setValidity(e,t,i){if(this.$fastController.isConnected){if(this.disabled||!this.required){this.elementInternals.setValidity({});return}this.elementInternals.setValidity({valueMissing:this.required&&!this.value,...e},t??this.validationMessage,i??this.enabledRadios[0])}}slotchangeHandler(e){ne.enqueue(()=>{this.radios=[...this.querySelectorAll("*")].filter(t=>t instanceof Ha)})}}bt.formAssociated=!0,Xt([$],bt.prototype,"checkedIndex",2),Xt([a({attribute:"disabled",mode:"boolean"})],bt.prototype,"disabled",2),Xt([a({attribute:"value",mode:"fromView"})],bt.prototype,"initialValue",2),Xt([a],bt.prototype,"name",2),Xt([a],bt.prototype,"orientation",2),Xt([$],bt.prototype,"radios",2),Xt([a({mode:"boolean"})],bt.prototype,"required",2);const uf=p`
489
489
  ${I("flex")}
490
490
 
491
- :host{-webkit-tap-highlight-color:transparent;cursor:pointer;gap:${ji}}:host(${_}),:host([orientation='vertical']){flex-direction:column;justify-content:flex-start}:host([orientation='horizontal']){flex-direction:row}::slotted(*){color:${be}}::slotted(:hover){color:${Le}}::slotted(:active){color:${O}}::slotted(${_}){color:${A}}::slotted(${x}){color:${O}}`;function bf(){return g`<template @disabled="${(o,e)=>o.disabledRadioHandler(e.event)}" @change="${(o,e)=>o.changeHandler(e.event)}" @click="${(o,e)=>o.clickHandler(e.event)}" @focusin="${(o,e)=>o.focusinHandler(e.event)}" @focusout="${(o,e)=>o.focusoutHandler(e.event)}" @keydown="${(o,e)=>o.keydownHandler(e.event)}"><slot @slotchange="${(o,e)=>o.slotchangeHandler(e.event)}"></slot></template>`}const gf=bf(),ff=bt.compose({name:`${b.prefix}-radio-group`,template:gf,styles:pf});ff.define(b.registry);const mf=p`
491
+ :host{-webkit-tap-highlight-color:transparent;cursor:pointer;gap:${ji}}:host(${_}),:host([orientation='vertical']){flex-direction:column;justify-content:flex-start}:host([orientation='horizontal']){flex-direction:row}::slotted(*){color:${be}}::slotted(:hover){color:${Le}}::slotted(:active){color:${O}}::slotted(${_}){color:${A}}::slotted(${x}){color:${O}}`;function pf(){return g`<template @disabled="${(o,e)=>o.disabledRadioHandler(e.event)}" @change="${(o,e)=>o.changeHandler(e.event)}" @click="${(o,e)=>o.clickHandler(e.event)}" @focusin="${(o,e)=>o.focusinHandler(e.event)}" @focusout="${(o,e)=>o.focusoutHandler(e.event)}" @keydown="${(o,e)=>o.keydownHandler(e.event)}"><slot @slotchange="${(o,e)=>o.slotchangeHandler(e.event)}"></slot></template>`}const bf=pf(),gf=bt.compose({name:`${b.prefix}-radio-group`,template:bf,styles:uf});gf.define(b.registry);const ff=p`
492
492
  ${I("inline-flex")}
493
493
 
494
494
  :host{--size:16px;aspect-ratio:1;background-color:${E};border:${N} solid ${Qe};border-radius:${Se};box-sizing:border-box;position:relative;width:var(--size)}:host([size='large']){--size:20px}.checked-indicator{aspect-ratio:1;border-radius:${Se};color:${Dt};inset:0;margin:auto;position:absolute;width:calc(var(--size) * 0.625)}:host(:not([slot='input']))::after{content:'' / '';position:absolute;display:block;inset:-8px;box-sizing:border-box;outline:none;border:${ze} solid ${ce};border-radius:${T}}:host(:not([slot='input']):focus-visible)::after{border-color:${Ve}}:host(:hover){border-color:${Vt}}:host(${x}){border-color:${Rt}}:host(${x}) .checked-indicator{background-color:${Lt}}:host(${x}:hover) .checked-indicator{background-color:${no}}:host(:active){border-color:${Ht}}:host(${x}:active) .checked-indicator{background-color:${ao}}:host(:focus-visible){outline:none}:host(${_}){background-color:${kt};border-color:${Ae}}:host(${x}${_}) .checked-indicator{background-color:${Ae}}`.withBehaviors(le(p`
495
- :host{border-color:FieldText}:host(:not([slot='input']:focus-visible))::after{border-color:Canvas}:host(:not(${_}):hover),:host(:not([slot='input']):focus-visible)::after{border-color:Highlight}.checked-indicator{color:HighlightText}:host(${x}) .checked-indicator{background-color:FieldText}:host(${x}:not(${_}):hover) .checked-indicator{background-color:Highlight}:host(${_}){border-color:GrayText;color:GrayText}:host(${_}${x}) .checked-indicator{background-color:GrayText}`)),$f=g.partial(`
495
+ :host{border-color:FieldText}:host(:not([slot='input']:focus-visible))::after{border-color:Canvas}:host(:not(${_}):hover),:host(:not([slot='input']):focus-visible)::after{border-color:Highlight}.checked-indicator{color:HighlightText}:host(${x}) .checked-indicator{background-color:FieldText}:host(${x}:not(${_}):hover) .checked-indicator{background-color:Highlight}:host(${_}){border-color:GrayText;color:GrayText}:host(${_}${x}) .checked-indicator{background-color:GrayText}`)),mf=g.partial(`
496
496
  <span part="checked-indicator" class="checked-indicator" role="presentation"></span>
497
- `);function vf(o={}){return g`<template @click="${(e,t)=>e.clickHandler(t.event)}" @keydown="${(e,t)=>e.keydownHandler(t.event)}" @keyup="${(e,t)=>e.keyupHandler(t.event)}"><slot name="checked-indicator">${ve(o.checkedIndicator)}</slot></template>`}const yf=vf({checkedIndicator:$f}),kf=Ha.compose({name:`${b.prefix}-radio`,template:yf,styles:mf});kf.define(b.registry);const xf={neutral:"neutral",brand:"brand",marigold:"marigold"},wf={small:"small",medium:"medium",large:"large"};var Cf=Object.defineProperty,Sf=Object.getOwnPropertyDescriptor,gt=(o,e,t,i)=>{for(var s=i>1?void 0:i?Sf(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Cf(e,t,s),s};class Kt extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.intlNumberFormatter=new Intl.NumberFormat,this.elementInternals.role="img"}slottedIconChanged(){this.$fastController.isConnected&&(this.customIcon=this.slottedIcon[0]?.outerHTML)}get formattedCount(){return this.count?this.intlNumberFormatter.format(this.count):""}getSelectedValue(){return Math.round((this.value??0)*2)/2}getMaxIcons(){return(this.max??5)*2}generateIcons(){let e="",t;this.customIcon&&(t=/<svg[^>]*>([\s\S]*?)<\/svg>/.exec(this.customIcon)?.[1]??"");const i=this.getSelectedValue();for(let s=0;s<this.getMaxIcons();s++){const r=(s+1)/2;e+=`<svg aria-hidden="true" viewBox="${this.iconViewBox??"0 0 20 20"}" ${r===i?"selected":""}>${t??'<use href="#star"></use>'}</svg>`}return e}}gt([a({converter:ae})],Kt.prototype,"count",2),gt([a({attribute:"icon-view-box"})],Kt.prototype,"iconViewBox",2),gt([a({converter:ae})],Kt.prototype,"max",2),gt([a({converter:ae})],Kt.prototype,"value",2),gt([$],Kt.prototype,"slottedIcon",2),gt([$],Kt.prototype,"customIcon",2);class is extends Kt{constructor(){super(...arguments),this.compact=!1}colorChanged(e,t){y(this.elementInternals,e,t,xf)}sizeChanged(e,t){y(this.elementInternals,e,t,wf)}getSelectedValue(){return Math.round((this.compact?1:this.value??0)*2)/2}getMaxIcons(){return(this.compact?1:this.max??5)*2}}gt([a],is.prototype,"color",2),gt([a],is.prototype,"size",2),gt([a({mode:"boolean"})],is.prototype,"compact",2);const If=p`
497
+ `);function $f(o={}){return g`<template @click="${(e,t)=>e.clickHandler(t.event)}" @keydown="${(e,t)=>e.keydownHandler(t.event)}" @keyup="${(e,t)=>e.keyupHandler(t.event)}"><slot name="checked-indicator">${ve(o.checkedIndicator)}</slot></template>`}const vf=$f({checkedIndicator:mf}),yf=Ha.compose({name:`${b.prefix}-radio`,template:vf,styles:ff});yf.define(b.registry);const kf={neutral:"neutral",brand:"brand",marigold:"marigold"},xf={small:"small",medium:"medium",large:"large"};var wf=Object.defineProperty,Cf=Object.getOwnPropertyDescriptor,gt=(o,e,t,i)=>{for(var s=i>1?void 0:i?Cf(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&wf(e,t,s),s};class Kt extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.intlNumberFormatter=new Intl.NumberFormat,this.elementInternals.role="img"}slottedIconChanged(){this.$fastController.isConnected&&(this.customIcon=this.slottedIcon[0]?.outerHTML)}get formattedCount(){return this.count?this.intlNumberFormatter.format(this.count):""}getSelectedValue(){return Math.round((this.value??0)*2)/2}getMaxIcons(){return(this.max??5)*2}generateIcons(){let e="",t;this.customIcon&&(t=/<svg[^>]*>([\s\S]*?)<\/svg>/.exec(this.customIcon)?.[1]??"");const i=this.getSelectedValue();for(let s=0;s<this.getMaxIcons();s++){const r=(s+1)/2;e+=`<svg aria-hidden="true" viewBox="${this.iconViewBox??"0 0 20 20"}" ${r===i?"selected":""}>${t??'<use href="#star"></use>'}</svg>`}return e}}gt([a({converter:ae})],Kt.prototype,"count",2),gt([a({attribute:"icon-view-box"})],Kt.prototype,"iconViewBox",2),gt([a({converter:ae})],Kt.prototype,"max",2),gt([a({converter:ae})],Kt.prototype,"value",2),gt([$],Kt.prototype,"slottedIcon",2),gt([$],Kt.prototype,"customIcon",2);class is extends Kt{constructor(){super(...arguments),this.compact=!1}colorChanged(e,t){y(this.elementInternals,e,t,kf)}sizeChanged(e,t){y(this.elementInternals,e,t,xf)}getSelectedValue(){return Math.round((this.compact?1:this.value??0)*2)/2}getMaxIcons(){return(this.compact?1:this.max??5)*2}}gt([a],is.prototype,"color",2),gt([a],is.prototype,"size",2),gt([a({mode:"boolean"})],is.prototype,"compact",2);const Sf=p`
498
498
  ${I("inline-flex")}
499
499
 
500
500
  :host{--icon-size:16px;--icon-color-filled:${eh};--icon-color-empty:${ia};align-items:center;color:${O};font-family:${k};font-size:${G};line-height:${ee};contain:layout style;user-select:none}:host(${P}){--icon-size:12px}:host(${C}){--icon-size:20px;font-size:${M};line-height:${j}}::slotted([slot='icon']){display:none}svg{width:var(--icon-size);height:var(--icon-size);fill:var(--icon-color-filled);margin-inline-end:${te}}svg:nth-child(odd){clip-path:inset(0 50% 0 0);margin-inline-end:calc(0px - var(--icon-size))}:host(${Pi}) svg{--icon-color-filled:${O}}:host(${Ye}) svg{--icon-color-filled:${qs}}:host(:is([value^='-'],[value='0'])) svg,:host(:not([value])) svg,svg[selected] ~ svg{fill:var(--icon-color-empty)}:host(${Pi}:is([value^='-'],[value='0'])) svg,:host(${Pi}:not([value])) svg,:host(${Pi}) svg[selected] ~ svg{--icon-color-empty:${Fi}}:host(${Ye}:is([value^='-'],[value='0'])) svg,:host(${Ye}:not([value])) svg,:host(${Ye}) svg[selected] ~ svg{--icon-color-empty:${Ws}}.value-label,::slotted([slot='value']){display:block;margin-inline-start:${Ee};font-weight:${U}}:host(${P}) .value-label,:host(${P}) ::slotted([slot='value']){margin-inline-start:${te}}:host(${C}) .value-label,:host(${C}) ::slotted([slot='value']){margin-inline-start:${de}}:host(:not([count])) .count-label{display:none}.count-label::before,::slotted([slot='count'])::before{content:'·';margin-inline:${Ee}}:host(${P}) .count-label::before,:host(${P}) ::slotted([slot='count'])::before{margin-inline:${te}}:host(${C}) .count-label::before,:host(${C}) ::slotted([slot='count'])::before{margin-inline:${de}}`.withBehaviors(le(p`
501
- :host([color]) svg{fill:CanvasText}:host([color]:is([value^='-'],[value='0'])) svg,:host(:not([value])) svg,:host([color]) svg[selected] ~ svg{fill:Canvas;stroke:CanvasText}`)),zf=g`<svg xmlns="http://www.w3.org/2000/svg" style="display: none"><symbol id="star"><path d="M9.10433 2.89874C9.47114 2.15549 10.531 2.1555 10.8978 2.89874L12.8282 6.81024L17.1448 7.43748C17.9651 7.55666 18.2926 8.56464 17.699 9.14317L14.5755 12.1878L15.3129 16.487C15.453 17.3039 14.5956 17.9269 13.8619 17.5412L10.0011 15.5114L6.14018 17.5412C5.40655 17.9269 4.54913 17.3039 4.68924 16.487L5.4266 12.1878L2.30308 9.14317C1.70956 8.56463 2.03708 7.55666 2.8573 7.43748L7.17389 6.81024L9.10433 2.89874Z" /></symbol></svg>`;function Pf(){return g` ${o=>g`${ve(o.generateIcons())}`}<slot name="icon" ${K({property:"slottedIcon",filter:Bt("svg")})}>${zf}</slot><slot name="value"><span class="value-label" aria-hidden="true">${o=>o.value}</span></slot><slot name="count"><span class="count-label" aria-hidden="true">${o=>o.formattedCount}</span></slot>`}const Tf=Pf(),Bf=is.compose({name:`${b.prefix}-rating-display`,template:Tf,styles:If});Bf.define(b.registry);const Af={small:"small",medium:"medium"},Ef=Ce,Of={singleValue:"single-value"};function qa(o,e,t,i){let s=Ts(0,1,(o-e)/(t-e));return i===De.rtl&&(s=1-s),s}var Ff=Object.defineProperty,Nf=Object.getOwnPropertyDescriptor,ue=(o,e,t,i)=>{for(var s=i>1?void 0:i?Nf(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Ff(e,t,s),s};class Z extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.direction=De.ltr,this.isDragging=!1,this.trackWidth=0,this.trackMinWidth=0,this.trackHeight=0,this.trackLeft=0,this.trackMinHeight=0,this.valueTextFormatter=()=>"",this.disabled=!1,this.min="",this.max="",this.step="",this.mode=Of.singleValue,this.keypressHandler=e=>{if(!this.disabled)switch(e.key){case wi:e.preventDefault(),this.value=this.direction!==De.rtl&&this.orientation!==Ce.vertical?`${this.minAsNumber}`:`${this.maxAsNumber}`;break;case ki:e.preventDefault(),this.value=this.direction!==De.rtl&&this.orientation!==Ce.vertical?`${this.maxAsNumber}`:`${this.minAsNumber}`;break;case vi:case yi:e.shiftKey||(e.preventDefault(),this.increment());break;case $i:case mi:e.shiftKey||(e.preventDefault(),this.decrement());break}},this.setupTrackConstraints=()=>{const e=this.track.getBoundingClientRect();this.trackWidth=this.track.clientWidth,this.trackMinWidth=this.track.clientLeft,this.trackHeight=e.top,this.trackMinHeight=e.bottom,this.trackLeft=this.getBoundingClientRect().left,this.trackWidth===0&&(this.trackWidth=1)},this.setupListeners=(e=!1)=>{this.addEventListener("keydown",this.keypressHandler),e&&this.removeEventListener("keydown",this.keypressHandler)},this.handleThumbPointerDown=e=>{const t=e!==null?window.addEventListener:window.removeEventListener;t("pointerup",this.handleWindowPointerUp),t("pointermove",this.handlePointerMove,{passive:!0}),t("touchmove",this.handlePointerMove,{passive:!0}),t("touchend",this.handleWindowPointerUp),this.isDragging=e!==null},this.handlePointerMove=e=>{if(this.disabled||e.defaultPrevented)return;const t=window.TouchEvent&&e instanceof TouchEvent?e.touches[0]:e,i=this.orientation===Ce.vertical?t.pageY-document.documentElement.scrollTop:t.pageX-document.documentElement.scrollLeft-this.trackLeft;this.value=`${this.calculateNewValue(i)}`},this.handleWindowPointerUp=()=>{this.stopDragging()},this.stopDragging=()=>{this.isDragging=!1,this.handlePointerDown(null),this.handleThumbPointerDown(null)},this.handlePointerDown=e=>{if(e===null||!this.disabled){const t=e!==null?window.addEventListener:window.removeEventListener,i=e!==null?document.addEventListener:document.removeEventListener;if(t("pointerup",this.handleWindowPointerUp),i("mouseleave",this.handleWindowPointerUp),t("pointermove",this.handlePointerMove),e){this.setupTrackConstraints();const s=this.orientation===Ce.vertical?e.pageY-document.documentElement.scrollTop:e.pageX-document.documentElement.scrollLeft-this.trackLeft;this.value=`${this.calculateNewValue(s)}`}}},this.elementInternals.role="slider",this.elementInternals.ariaOrientation=this.orientation??Ef.horizontal}get labels(){return Object.freeze(Array.from(this.elementInternals.labels))}sizeChanged(e,t){y(this.elementInternals,e,t,Af)}handleChange(e,t){switch(t){case"min":case"max":this.setSliderPosition(this.direction);case"step":this.handleStepStyles();break}}handleStepStyles(){if(this.step){const e=100/Math.floor((this.maxAsNumber-this.minAsNumber)/this.stepAsNumber);this.stepStyles!==void 0&&this.$fastController.removeStyles(this.stepStyles),this.stepStyles=p`
502
- :host{--step-rate:${e}%}`,this.$fastController.addStyles(this.stepStyles)}else this.stepStyles!==void 0&&this.$fastController.removeStyles(this.stepStyles)}initialValueChanged(e,t){this.$fastController.isConnected?this.value=t:this._value=t}get validity(){return this.elementInternals.validity}get validationMessage(){return this.elementInternals.validationMessage}get willValidate(){return this.elementInternals.willValidate}checkValidity(){return this.elementInternals.checkValidity()}reportValidity(){return this.elementInternals.reportValidity()}setCustomValidity(e){this.setValidity({customError:!!e},e)}setValidity(e,t,i){if(this.$fastController.isConnected){if(this.disabled){this.elementInternals.setValidity({});return}this.elementInternals.setValidity({customError:!!t,...e},t??this.validationMessage,i)}}get value(){return f.track(this,"value"),this._value.toString()}set value(e){if(!this.$fastController.isConnected){this._value=e.toString();return}const t=parseFloat(e),i=Ts(this.minAsNumber,this.maxAsNumber,this.convertToConstrainedValue(t)).toString();if(i!==e){this.value=i;return}this._value=e.toString(),this.elementInternals.ariaValueNow=this._value,this.elementInternals.ariaValueText=this.valueTextFormatter(this._value),this.setSliderPosition(this.direction),this.$emit("change"),this.setFormValue(e),f.notify(this,"value")}formResetCallback(){this.value=this.initialValue??this.midpoint}formDisabledCallback(e){this.setDisabledSideEffect(e)}setFormValue(e,t){this.elementInternals.setFormValue(e,e??t)}get valueAsNumber(){return parseFloat(this.value)}set valueAsNumber(e){this.value=e.toString()}valueTextFormatterChanged(){typeof this.valueTextFormatter=="function"?this.elementInternals.ariaValueText=this.valueTextFormatter(this._value):this.elementInternals.ariaValueText=""}disabledChanged(){this.setDisabledSideEffect(this.disabled)}minChanged(){this.elementInternals.ariaValueMin=`${this.minAsNumber}`,this.$fastController.isConnected&&this.minAsNumber>this.valueAsNumber&&(this.value=this.min)}get minAsNumber(){if(this.min!==void 0){const e=parseFloat(this.min);if(!Number.isNaN(e))return e}return 0}maxChanged(){this.elementInternals.ariaValueMax=`${this.maxAsNumber}`,this.$fastController.isConnected&&this.maxAsNumber<this.valueAsNumber&&(this.value=this.max)}get maxAsNumber(){if(this.max!==void 0){const e=parseFloat(this.max);if(!Number.isNaN(e))return e}return 100}stepChanged(){this.updateStepMultiplier(),this.$fastController.isConnected&&(this.value=this._value)}get stepAsNumber(){if(this.step!==void 0){const e=parseFloat(this.step);if(!Number.isNaN(e)&&e>0)return e}return 1}orientationChanged(e,t){this.elementInternals.ariaOrientation=t??Ce.horizontal,y(this.elementInternals,e,t,Ce),this.$fastController.isConnected&&this.setSliderPosition(this.direction)}connectedCallback(){super.connectedCallback(),this.direction=As(this),this.setDisabledSideEffect(this.disabled),this.updateStepMultiplier(),this.setupTrackConstraints(),this.setupListeners(),this.setupDefaultValue(),this.setSliderPosition(this.direction),f.getNotifier(this).subscribe(this,"max"),f.getNotifier(this).subscribe(this,"min"),f.getNotifier(this).subscribe(this,"step"),this.handleStepStyles()}disconnectedCallback(){super.disconnectedCallback(),this.setupListeners(!0),f.getNotifier(this).unsubscribe(this,"max"),f.getNotifier(this).unsubscribe(this,"min"),f.getNotifier(this).unsubscribe(this,"step")}increment(){const e=this.direction!==De.rtl?Number(this.value)+this.stepAsNumber:Number(this.value)-this.stepAsNumber,t=this.convertToConstrainedValue(e),i=t<this.maxAsNumber?`${t}`:`${this.maxAsNumber}`;this.value=i}decrement(){const e=this.direction!==De.rtl?Number(this.value)-Number(this.stepAsNumber):Number(this.value)+Number(this.stepAsNumber),t=this.convertToConstrainedValue(e),i=t>this.minAsNumber?`${t}`:`${this.minAsNumber}`;this.value=i}setSliderPosition(e){const i=(1-qa(parseFloat(this.value),this.minAsNumber,this.maxAsNumber,e))*100,s=`calc(100% - ${i}%)`,r=this.orientation!==Ce.vertical&&e===De.rtl?`${i}%`:`calc(100% - ${i}%)`;this.position=`--slider-thumb: ${s}; --slider-progress: ${r}`}updateStepMultiplier(){const e=this.stepAsNumber+"",t=this.stepAsNumber%1?e.length-e.indexOf(".")-1:0;this.stepMultiplier=Math.pow(10,t)}get midpoint(){return`${this.convertToConstrainedValue((this.maxAsNumber+this.minAsNumber)/2)}`}setupDefaultValue(){this._value||(this.value=this.initialValue??this.midpoint),!Number.isNaN(this.valueAsNumber)&&(this.valueAsNumber<this.minAsNumber||this.valueAsNumber>this.maxAsNumber)&&(this.value=this.midpoint),this.elementInternals.ariaValueNow=this.value}calculateNewValue(e){this.setupTrackConstraints();const t=qa(e,this.orientation===Ce.vertical?this.trackMinHeight:this.trackMinWidth,this.orientation===Ce.vertical?this.trackHeight:this.trackWidth,this.direction),i=(this.maxAsNumber-this.minAsNumber)*t+this.minAsNumber;return this.convertToConstrainedValue(i)}convertToConstrainedValue(e){isNaN(e)&&(e=this.minAsNumber);let t=e-this.minAsNumber;const i=Math.round(t/this.stepAsNumber),s=t-i*(this.stepMultiplier*this.stepAsNumber)/this.stepMultiplier;return t=s>=Number(this.stepAsNumber)/2?t-s+Number(this.stepAsNumber):t-s,t+this.minAsNumber}setDisabledSideEffect(e){this.$fastController.isConnected&&(this.elementInternals.ariaDisabled=e.toString(),this.tabIndex=e?-1:0)}}Z.formAssociated=!0,ue([a],Z.prototype,"size",2),ue([a({attribute:"value",mode:"fromView"})],Z.prototype,"initialValue",2),ue([$],Z.prototype,"direction",2),ue([$],Z.prototype,"isDragging",2),ue([$],Z.prototype,"position",2),ue([$],Z.prototype,"trackWidth",2),ue([$],Z.prototype,"trackMinWidth",2),ue([$],Z.prototype,"trackHeight",2),ue([$],Z.prototype,"trackLeft",2),ue([$],Z.prototype,"trackMinHeight",2),ue([$],Z.prototype,"valueTextFormatter",2),ue([a({mode:"boolean"})],Z.prototype,"disabled",2),ue([a({converter:Bs})],Z.prototype,"min",2),ue([a({converter:Bs})],Z.prototype,"max",2),ue([a({converter:Bs})],Z.prototype,"step",2),ue([a],Z.prototype,"orientation",2),ue([a],Z.prototype,"mode",2);const _f=p`
501
+ :host([color]) svg{fill:CanvasText}:host([color]:is([value^='-'],[value='0'])) svg,:host(:not([value])) svg,:host([color]) svg[selected] ~ svg{fill:Canvas;stroke:CanvasText}`)),If=g`<svg xmlns="http://www.w3.org/2000/svg" style="display: none"><symbol id="star"><path d="M9.10433 2.89874C9.47114 2.15549 10.531 2.1555 10.8978 2.89874L12.8282 6.81024L17.1448 7.43748C17.9651 7.55666 18.2926 8.56464 17.699 9.14317L14.5755 12.1878L15.3129 16.487C15.453 17.3039 14.5956 17.9269 13.8619 17.5412L10.0011 15.5114L6.14018 17.5412C5.40655 17.9269 4.54913 17.3039 4.68924 16.487L5.4266 12.1878L2.30308 9.14317C1.70956 8.56463 2.03708 7.55666 2.8573 7.43748L7.17389 6.81024L9.10433 2.89874Z" /></symbol></svg>`;function zf(){return g` ${o=>g`${ve(o.generateIcons())}`}<slot name="icon" ${K({property:"slottedIcon",filter:Bt("svg")})}>${If}</slot><slot name="value"><span class="value-label" aria-hidden="true">${o=>o.value}</span></slot><slot name="count"><span class="count-label" aria-hidden="true">${o=>o.formattedCount}</span></slot>`}const Pf=zf(),Tf=is.compose({name:`${b.prefix}-rating-display`,template:Pf,styles:Sf});Tf.define(b.registry);const Bf={small:"small",medium:"medium"},Af=Ce,Ef={singleValue:"single-value"};function qa(o,e,t,i){let s=Ts(0,1,(o-e)/(t-e));return i===De.rtl&&(s=1-s),s}var Of=Object.defineProperty,Ff=Object.getOwnPropertyDescriptor,ue=(o,e,t,i)=>{for(var s=i>1?void 0:i?Ff(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Of(e,t,s),s};class Z extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.direction=De.ltr,this.isDragging=!1,this.trackWidth=0,this.trackMinWidth=0,this.trackHeight=0,this.trackLeft=0,this.trackMinHeight=0,this.valueTextFormatter=()=>"",this.disabled=!1,this.min="",this.max="",this.step="",this.mode=Ef.singleValue,this.keypressHandler=e=>{if(!this.disabled)switch(e.key){case wi:e.preventDefault(),this.value=this.direction!==De.rtl&&this.orientation!==Ce.vertical?`${this.minAsNumber}`:`${this.maxAsNumber}`;break;case ki:e.preventDefault(),this.value=this.direction!==De.rtl&&this.orientation!==Ce.vertical?`${this.maxAsNumber}`:`${this.minAsNumber}`;break;case vi:case yi:e.shiftKey||(e.preventDefault(),this.increment());break;case $i:case mi:e.shiftKey||(e.preventDefault(),this.decrement());break}},this.setupTrackConstraints=()=>{const e=this.track.getBoundingClientRect();this.trackWidth=this.track.clientWidth,this.trackMinWidth=this.track.clientLeft,this.trackHeight=e.top,this.trackMinHeight=e.bottom,this.trackLeft=this.getBoundingClientRect().left,this.trackWidth===0&&(this.trackWidth=1)},this.setupListeners=(e=!1)=>{this.addEventListener("keydown",this.keypressHandler),e&&this.removeEventListener("keydown",this.keypressHandler)},this.handleThumbPointerDown=e=>{const t=e!==null?window.addEventListener:window.removeEventListener;t("pointerup",this.handleWindowPointerUp),t("pointermove",this.handlePointerMove,{passive:!0}),t("touchmove",this.handlePointerMove,{passive:!0}),t("touchend",this.handleWindowPointerUp),this.isDragging=e!==null},this.handlePointerMove=e=>{if(this.disabled||e.defaultPrevented)return;const t=window.TouchEvent&&e instanceof TouchEvent?e.touches[0]:e,i=this.orientation===Ce.vertical?t.pageY-document.documentElement.scrollTop:t.pageX-document.documentElement.scrollLeft-this.trackLeft;this.value=`${this.calculateNewValue(i)}`},this.handleWindowPointerUp=()=>{this.stopDragging()},this.stopDragging=()=>{this.isDragging=!1,this.handlePointerDown(null),this.handleThumbPointerDown(null)},this.handlePointerDown=e=>{if(e===null||!this.disabled){const t=e!==null?window.addEventListener:window.removeEventListener,i=e!==null?document.addEventListener:document.removeEventListener;if(t("pointerup",this.handleWindowPointerUp),i("mouseleave",this.handleWindowPointerUp),t("pointermove",this.handlePointerMove),e){this.setupTrackConstraints();const s=this.orientation===Ce.vertical?e.pageY-document.documentElement.scrollTop:e.pageX-document.documentElement.scrollLeft-this.trackLeft;this.value=`${this.calculateNewValue(s)}`}}},this.elementInternals.role="slider",this.elementInternals.ariaOrientation=this.orientation??Af.horizontal}get labels(){return Object.freeze(Array.from(this.elementInternals.labels))}sizeChanged(e,t){y(this.elementInternals,e,t,Bf)}handleChange(e,t){switch(t){case"min":case"max":this.setSliderPosition(this.direction);case"step":this.handleStepStyles();break}}handleStepStyles(){if(this.step){const e=100/Math.floor((this.maxAsNumber-this.minAsNumber)/this.stepAsNumber);this.stepStyles!==void 0&&this.$fastController.removeStyles(this.stepStyles),this.stepStyles=p`
502
+ :host{--step-rate:${e}%}`,this.$fastController.addStyles(this.stepStyles)}else this.stepStyles!==void 0&&this.$fastController.removeStyles(this.stepStyles)}initialValueChanged(e,t){this.$fastController.isConnected?this.value=t:this._value=t}get validity(){return this.elementInternals.validity}get validationMessage(){return this.elementInternals.validationMessage}get willValidate(){return this.elementInternals.willValidate}checkValidity(){return this.elementInternals.checkValidity()}reportValidity(){return this.elementInternals.reportValidity()}setCustomValidity(e){this.setValidity({customError:!!e},e)}setValidity(e,t,i){if(this.$fastController.isConnected){if(this.disabled){this.elementInternals.setValidity({});return}this.elementInternals.setValidity({customError:!!t,...e},t??this.validationMessage,i)}}get value(){return f.track(this,"value"),this._value.toString()}set value(e){if(!this.$fastController.isConnected){this._value=e.toString();return}const t=parseFloat(e),i=Ts(this.minAsNumber,this.maxAsNumber,this.convertToConstrainedValue(t)).toString();if(i!==e){this.value=i;return}this._value=e.toString(),this.elementInternals.ariaValueNow=this._value,this.elementInternals.ariaValueText=this.valueTextFormatter(this._value),this.setSliderPosition(this.direction),this.$emit("change"),this.setFormValue(e),f.notify(this,"value")}formResetCallback(){this.value=this.initialValue??this.midpoint}formDisabledCallback(e){this.setDisabledSideEffect(e)}setFormValue(e,t){this.elementInternals.setFormValue(e,e??t)}get valueAsNumber(){return parseFloat(this.value)}set valueAsNumber(e){this.value=e.toString()}valueTextFormatterChanged(){typeof this.valueTextFormatter=="function"?this.elementInternals.ariaValueText=this.valueTextFormatter(this._value):this.elementInternals.ariaValueText=""}disabledChanged(){this.setDisabledSideEffect(this.disabled)}minChanged(){this.elementInternals.ariaValueMin=`${this.minAsNumber}`,this.$fastController.isConnected&&this.minAsNumber>this.valueAsNumber&&(this.value=this.min)}get minAsNumber(){if(this.min!==void 0){const e=parseFloat(this.min);if(!Number.isNaN(e))return e}return 0}maxChanged(){this.elementInternals.ariaValueMax=`${this.maxAsNumber}`,this.$fastController.isConnected&&this.maxAsNumber<this.valueAsNumber&&(this.value=this.max)}get maxAsNumber(){if(this.max!==void 0){const e=parseFloat(this.max);if(!Number.isNaN(e))return e}return 100}stepChanged(){this.updateStepMultiplier(),this.$fastController.isConnected&&(this.value=this._value)}get stepAsNumber(){if(this.step!==void 0){const e=parseFloat(this.step);if(!Number.isNaN(e)&&e>0)return e}return 1}orientationChanged(e,t){this.elementInternals.ariaOrientation=t??Ce.horizontal,y(this.elementInternals,e,t,Ce),this.$fastController.isConnected&&this.setSliderPosition(this.direction)}connectedCallback(){super.connectedCallback(),this.direction=As(this),this.setDisabledSideEffect(this.disabled),this.updateStepMultiplier(),this.setupTrackConstraints(),this.setupListeners(),this.setupDefaultValue(),this.setSliderPosition(this.direction),f.getNotifier(this).subscribe(this,"max"),f.getNotifier(this).subscribe(this,"min"),f.getNotifier(this).subscribe(this,"step"),this.handleStepStyles()}disconnectedCallback(){super.disconnectedCallback(),this.setupListeners(!0),f.getNotifier(this).unsubscribe(this,"max"),f.getNotifier(this).unsubscribe(this,"min"),f.getNotifier(this).unsubscribe(this,"step")}increment(){const e=this.direction!==De.rtl?Number(this.value)+this.stepAsNumber:Number(this.value)-this.stepAsNumber,t=this.convertToConstrainedValue(e),i=t<this.maxAsNumber?`${t}`:`${this.maxAsNumber}`;this.value=i}decrement(){const e=this.direction!==De.rtl?Number(this.value)-Number(this.stepAsNumber):Number(this.value)+Number(this.stepAsNumber),t=this.convertToConstrainedValue(e),i=t>this.minAsNumber?`${t}`:`${this.minAsNumber}`;this.value=i}setSliderPosition(e){const i=(1-qa(parseFloat(this.value),this.minAsNumber,this.maxAsNumber,e))*100,s=`calc(100% - ${i}%)`,r=this.orientation!==Ce.vertical&&e===De.rtl?`${i}%`:`calc(100% - ${i}%)`;this.position=`--slider-thumb: ${s}; --slider-progress: ${r}`}updateStepMultiplier(){const e=this.stepAsNumber+"",t=this.stepAsNumber%1?e.length-e.indexOf(".")-1:0;this.stepMultiplier=Math.pow(10,t)}get midpoint(){return`${this.convertToConstrainedValue((this.maxAsNumber+this.minAsNumber)/2)}`}setupDefaultValue(){this._value||(this.value=this.initialValue??this.midpoint),!Number.isNaN(this.valueAsNumber)&&(this.valueAsNumber<this.minAsNumber||this.valueAsNumber>this.maxAsNumber)&&(this.value=this.midpoint),this.elementInternals.ariaValueNow=this.value}calculateNewValue(e){this.setupTrackConstraints();const t=qa(e,this.orientation===Ce.vertical?this.trackMinHeight:this.trackMinWidth,this.orientation===Ce.vertical?this.trackHeight:this.trackWidth,this.direction),i=(this.maxAsNumber-this.minAsNumber)*t+this.minAsNumber;return this.convertToConstrainedValue(i)}convertToConstrainedValue(e){isNaN(e)&&(e=this.minAsNumber);let t=e-this.minAsNumber;const i=Math.round(t/this.stepAsNumber),s=t-i*(this.stepMultiplier*this.stepAsNumber)/this.stepMultiplier;return t=s>=Number(this.stepAsNumber)/2?t-s+Number(this.stepAsNumber):t-s,t+this.minAsNumber}setDisabledSideEffect(e){this.$fastController.isConnected&&(this.elementInternals.ariaDisabled=e.toString(),this.tabIndex=e?-1:0)}}Z.formAssociated=!0,ue([a],Z.prototype,"size",2),ue([a({attribute:"value",mode:"fromView"})],Z.prototype,"initialValue",2),ue([$],Z.prototype,"direction",2),ue([$],Z.prototype,"isDragging",2),ue([$],Z.prototype,"position",2),ue([$],Z.prototype,"trackWidth",2),ue([$],Z.prototype,"trackMinWidth",2),ue([$],Z.prototype,"trackHeight",2),ue([$],Z.prototype,"trackLeft",2),ue([$],Z.prototype,"trackMinHeight",2),ue([$],Z.prototype,"valueTextFormatter",2),ue([a({mode:"boolean"})],Z.prototype,"disabled",2),ue([a({converter:Bs})],Z.prototype,"min",2),ue([a({converter:Bs})],Z.prototype,"max",2),ue([a({converter:Bs})],Z.prototype,"step",2),ue([a],Z.prototype,"orientation",2),ue([a],Z.prototype,"mode",2);const Nf=p`
503
503
  ${I("inline-grid")}
504
504
 
505
505
  :host{--thumb-size:20px;--track-margin-inline:calc(var(--thumb-size) / 2);--track-size:4px;--track-overhang:calc(var(--track-size) / -2);--rail-color:${Lt};--track-color:${Qe};--slider-direction:90deg;--border-radius:${T};--step-marker-inset:var(--track-overhang) -1px;position:relative;align-items:center;justify-content:center;box-sizing:border-box;outline:none;user-select:none;touch-action:none;min-width:120px;min-height:32px;grid-template-rows:1fr var(--thumb-size) 1fr;grid-template-columns:var(--track-margin-inline) 1fr var(--track-margin-inline)}:host(:hover){--rail-color:${no}}:host(:active){--rail-color:${ao}}:host(:disabled){--rail-color:${A};--track-color:${kt}}:host(:not(:disabled)){cursor:pointer}:host(:dir(rtl)){--slider-direction:-90deg}:host(${P}){--thumb-size:16px;--track-overhang:-1px;--track-size:2px;--border-radius:${He}}:host(${z}){--slider-direction:0deg;--step-marker-inset:-1px var(--track-overhang);min-height:120px;grid-template-rows:var(--track-margin-inline) 1fr var(--track-margin-inline);grid-template-columns:1fr var(--thumb-size) 1fr;width:unset;min-width:32px;justify-items:center}:host(:not([slot='input']):focus-visible){box-shadow:0 0 0 2pt ${Ve};outline:1px solid ${Us}}:host:after,.track{height:var(--track-size);width:100%}:host:after{background-image:linear-gradient(
@@ -507,45 +507,45 @@ const b=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElem
507
507
  );border-radius:var(--border-radius);content:'';grid-row:1 / -1;grid-column:1 / -1}.track{position:relative;background-color:var(--track-color);grid-row:2 / 2;grid-column:2 / 2;forced-color-adjust:none;overflow:hidden}:host(${z})::after,:host(${z}) .track{height:100%;width:var(--track-size)}:host(${z}) .track{top:var(--track-overhang);bottom:var(--track-overhang)}.track::before{content:'';position:absolute;height:100%;border-radius:inherit;inset-inline-start:0;width:var(--slider-progress)}:host(${z}) .track::before{width:100%;bottom:0;height:var(--slider-progress)}:host([step]) .track::after{content:'';position:absolute;border-radius:inherit;inset:var(--step-marker-inset);background-image:repeating-linear-gradient(
508
508
  var(--slider-direction),#0000 0%,#0000 calc(var(--step-rate) - 1px),${E} calc(var(--step-rate) - 1px),${E} var(--step-rate)
509
509
  )}.thumb-container{position:absolute;grid-row:2 / 2;grid-column:2 / 2;transform:translateX(-50%);left:var(--slider-thumb)}:host(${z}) .thumb-container{transform:translateY(50%);left:unset;bottom:var(--slider-thumb)}:host(:not(:active)) :is(.thumb-container,.track::before){transition:all 0.2s ease}.thumb{width:var(--thumb-size);height:var(--thumb-size);border-radius:${Se};box-shadow:0 0 0 calc(var(--thumb-size) * 0.2) ${E} inset;border:calc(var(--thumb-size) * 0.05) solid ${Ze};box-sizing:border-box}.thumb,.track::before{background-color:var(--rail-color)}`.withBehaviors(le(p`
510
- .track:hover,.track:active,.track{background:WindowText}.thumb:hover,.thumb:active,.thumb{background:ButtonText}:host(:hover) .track::before,:host(:active) .track::before,.track::before{background:Highlight}`));function Mf(o={}){return g`<template tabindex="${e=>e.disabled?null:0}" @pointerdown="${(e,t)=>e.handlePointerDown(t.event)}"><div ${X("track")} part="track-container" class="track" style="${e=>e.position}"></div><div ${X("thumb")} part="thumb-container" class="thumb-container" style="${e=>e.position}" @pointerdown="${(e,t)=>e.handleThumbPointerDown(t.event)}"><slot name="thumb">${ve(o.thumb)}</slot></div></template>`}const Df=Mf({thumb:'<div class="thumb"></div>'}),Lf=Z.compose({name:`${b.prefix}-slider`,template:Df,styles:_f});Lf.define(b.registry);const Vf={primary:"primary",inverted:"inverted"},Hf={tiny:"tiny",extraSmall:"extra-small",small:"small",medium:"medium",large:"large",extraLarge:"extra-large",huge:"huge"};var Rf=Object.defineProperty,jf=Object.getOwnPropertyDescriptor,Wa=(o,e,t,i)=>{for(var s=i>1?void 0:i?jf(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Rf(e,t,s),s};class qf extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.elementInternals.role="progressbar"}}class gr extends qf{sizeChanged(e,t){y(this.elementInternals,e,t,Hf)}appearanceChanged(e,t){y(this.elementInternals,e,t,Vf)}}Wa([a],gr.prototype,"size",2),Wa([a],gr.prototype,"appearance",2);const Wf=p`
510
+ .track:hover,.track:active,.track{background:WindowText}.thumb:hover,.thumb:active,.thumb{background:ButtonText}:host(:hover) .track::before,:host(:active) .track::before,.track::before{background:Highlight}`));function _f(o={}){return g`<template tabindex="${e=>e.disabled?null:0}" @pointerdown="${(e,t)=>e.handlePointerDown(t.event)}"><div ${X("track")} part="track-container" class="track" style="${e=>e.position}"></div><div ${X("thumb")} part="thumb-container" class="thumb-container" style="${e=>e.position}" @pointerdown="${(e,t)=>e.handleThumbPointerDown(t.event)}"><slot name="thumb">${ve(o.thumb)}</slot></div></template>`}const Mf=_f({thumb:'<div class="thumb"></div>'}),Df=Z.compose({name:`${b.prefix}-slider`,template:Mf,styles:Nf});Df.define(b.registry);const Lf={primary:"primary",inverted:"inverted"},Vf={tiny:"tiny",extraSmall:"extra-small",small:"small",medium:"medium",large:"large",extraLarge:"extra-large",huge:"huge"};var Hf=Object.defineProperty,Rf=Object.getOwnPropertyDescriptor,Wa=(o,e,t,i)=>{for(var s=i>1?void 0:i?Rf(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Hf(e,t,s),s};class jf extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.elementInternals.role="progressbar"}}class gr extends jf{sizeChanged(e,t){y(this.elementInternals,e,t,Vf)}appearanceChanged(e,t){y(this.elementInternals,e,t,Lf)}}Wa([a],gr.prototype,"size",2),Wa([a],gr.prototype,"appearance",2);const qf=p`
511
511
  ${I("inline-flex")}
512
512
 
513
513
  :host{--duration:1.5s;--indicatorSize:${ge};--size:32px;height:var(--size);width:var(--size);contain:strict;content-visibility:auto}:host(${Oo}){--indicatorSize:${ze};--size:20px}:host(${To}){--indicatorSize:${ze};--size:24px}:host(${P}){--indicatorSize:${ze};--size:28px}:host(${C}){--indicatorSize:${ge};--size:36px}:host(${Si}){--indicatorSize:${ge};--size:40px}:host(${vc}){--indicatorSize:${Zs};--size:44px}.progress,.background,.spinner,.start,.end,.indicator{position:absolute;inset:0}.progress,.spinner,.indicator{animation:none var(--duration) infinite ${Gi}}.progress{animation-timing-function:linear;animation-name:spin-linear}.background{border:var(--indicatorSize) solid ${Ws};border-radius:50%}:host(${En}) .background{border-color:rgba(255,255,255,0.2)}.spinner{animation-name:spin-swing}.start{overflow:hidden;right:50%}.end{overflow:hidden;left:50%}.indicator{color:${qn};box-sizing:border-box;border-radius:50%;border:var(--indicatorSize) solid transparent;border-block-start-color:currentcolor;border-right-color:currentcolor}:host(${En}) .indicator{color:${Ld}}.start .indicator{rotate:135deg;inset:0 -100% 0 0;animation-name:spin-start}.end .indicator{rotate:135deg;inset:0 0 0 -100%;animation-name:spin-end}@keyframes spin-linear{100%{transform:rotate(360deg)}}@keyframes spin-swing{0%{transform:rotate(-135deg)}50%{transform:rotate(0deg)}100%{transform:rotate(225deg)}}@keyframes spin-start{0%,100%{transform:rotate(0deg)}50%{transform:rotate(-80deg)}}@keyframes spin-end{0%,100%{transform:rotate(0deg)}50%{transform:rotate(70deg)}}`.withBehaviors(le(p`
514
- .background{display:none}.indicator{border-color:Canvas;border-block-start-color:Highlight;border-right-color:Highlight}`)),Gf=g`<slot name="indicator"><div class="background"></div><div class="progress"><div class="spinner"><div class="start"><div class="indicator"></div></div><div class="end"><div class="indicator"></div></div></div></div></slot>`,Uf=gr.compose({name:`${b.prefix}-spinner`,template:Gf,styles:Wf});Uf.define(b.registry);class Xf extends Fe{constructor(){super(),this.elementInternals.role="switch"}}function Kf(o={}){return g`<template tabindex="${e=>e.disabled?void 0:0}" @click="${(e,t)=>e.clickHandler(t.event)}" @input="${(e,t)=>e.inputHandler(t.event)}" @keydown="${(e,t)=>e.keydownHandler(t.event)}" @keyup="${(e,t)=>e.keyupHandler(t.event)}"><slot name="switch">${ve(o.switch)}</slot></template>`}const Yf=Kf({switch:'<span class="checked-indicator" part="checked-indicator"></span>'}),Qf=p`
514
+ .background{display:none}.indicator{border-color:Canvas;border-block-start-color:Highlight;border-right-color:Highlight}`)),Wf=g`<slot name="indicator"><div class="background"></div><div class="progress"><div class="spinner"><div class="start"><div class="indicator"></div></div><div class="end"><div class="indicator"></div></div></div></div></slot>`,Gf=gr.compose({name:`${b.prefix}-spinner`,template:Wf,styles:qf});Gf.define(b.registry);class Uf extends Fe{constructor(){super(),this.elementInternals.role="switch"}}function Xf(o={}){return g`<template tabindex="${e=>e.disabled?void 0:0}" @click="${(e,t)=>e.clickHandler(t.event)}" @input="${(e,t)=>e.inputHandler(t.event)}" @keydown="${(e,t)=>e.keydownHandler(t.event)}" @keyup="${(e,t)=>e.keyupHandler(t.event)}"><slot name="switch">${ve(o.switch)}</slot></template>`}const Kf=Xf({switch:'<span class="checked-indicator" part="checked-indicator"></span>'}),Yf=p`
515
515
  ${I("inline-flex")}
516
516
 
517
517
  :host{box-sizing:border-box;align-items:center;flex-direction:row;outline:none;user-select:none;contain:content;padding:0 ${te};width:40px;height:20px;background-color:${Be};border:1px solid ${Qe};border-radius:${Se};cursor:pointer}:host(:hover){background:none;border-color:${Vt}}:host(:active){border-color:${Ht}}:host(:disabled),:host([readonly]){border:1px solid ${Ae};background-color:none;pointer:default}:host(${x}){background:${Lt};border-color:${Lt}}:host(${x}:hover){background:${no};border-color:${no}}:host(${x}:active){background:${ao};border-color:${ao}}:host(${x}:disabled){background:${kt};border-color:${Ae}}.checked-indicator{height:14px;width:14px;border-radius:50%;margin-inline-start:0;background-color:${be};transition-duration:${qi};transition-timing-function:${Gi};transition-property:margin-inline-start}:host(${x}) .checked-indicator{background-color:${Dt};margin-inline-start:calc(100% - 14px)}:host(${x}:hover) .checked-indicator{background:${zd}}:host(${x}:active) .checked-indicator{background:${Pd}}:host(:hover) .checked-indicator{background-color:${$d}}:host(:active) .checked-indicator{background-color:${vd}}:host(:disabled) .checked-indicator,:host([readonly]) .checked-indicator{background:${A}}:host(${x}:disabled) .checked-indicator{background:${A}}:host(:focus-visible){outline:none}:host(:not([slot='input']):focus-visible){border-color:${ce};outline:${ze} solid ${ce};box-shadow:${Ri},0 0 0 2px ${Ve}}`.withBehaviors(le(p`
518
- :host{border-color:InactiveBorder}:host(${x}),:host(${x}:active),:host(${x}:hover){background:Highlight;border-color:Highlight}.checked-indicator,:host(:hover) .checked-indicator,:host(:active) .checked-indicator{background-color:ActiveCaption}:host(${x}) .checked-indicator,:host(${x}:hover) .checked-indicator,:host(${x}:active) .checked-indicator{background-color:ButtonFace}:host(:disabled) .checked-indicator,:host(${x}:disabled) .checked-indicator{background-color:GrayText}`)),Zf=Xf.compose({name:`${b.prefix}-switch`,template:Yf,styles:Qf});Zf.define(b.registry);class Jf extends w{}function em(){return g`<template slot="tabpanel" role="tabpanel"><slot></slot></template>`}const tm=em(),om=p`
518
+ :host{border-color:InactiveBorder}:host(${x}),:host(${x}:active),:host(${x}:hover){background:Highlight;border-color:Highlight}.checked-indicator,:host(:hover) .checked-indicator,:host(:active) .checked-indicator{background-color:ActiveCaption}:host(${x}) .checked-indicator,:host(${x}:hover) .checked-indicator,:host(${x}:active) .checked-indicator{background-color:ButtonFace}:host(:disabled) .checked-indicator,:host(${x}:disabled) .checked-indicator{background-color:GrayText}`)),Qf=Uf.compose({name:`${b.prefix}-switch`,template:Kf,styles:Yf});Qf.define(b.registry);class Zf extends w{}function Jf(){return g`<template slot="tabpanel" role="tabpanel"><slot></slot></template>`}const em=Jf(),tm=p`
519
519
  ${I("block")}
520
520
 
521
- :host{box-sizing:border-box;padding:${xe} ${fe}}`,im=Jf.compose({name:`${b.prefix}-tab-panel`,template:tm,styles:om});im.define(b.registry);var sm=Object.defineProperty,rm=Object.getOwnPropertyDescriptor,nm=(o,e,t,i)=>{for(var s=i>1?void 0:i?rm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&sm(e,t,s),s};class fr extends w{connectedCallback(){super.connectedCallback(),this.styles!==void 0&&this.$fastController.removeStyles(this.styles),this.styles=p`
522
- :host{--textContent:'${this.textContent}'}`,this.$fastController.addStyles(this.styles)}}nm([a({mode:"boolean"})],fr.prototype,"disabled",2),nt(fr,rt);function am(o={}){return g`<template slot="tab" role="tab" aria-disabled="${e=>e.disabled}">${Ke(o)}<span class="tab-content"><slot></slot></span>${mt(o)}</template>`}const lm=am({}),cm=p`
521
+ :host{box-sizing:border-box;padding:${xe} ${fe}}`,om=Zf.compose({name:`${b.prefix}-tab-panel`,template:em,styles:tm});om.define(b.registry);var im=Object.defineProperty,sm=Object.getOwnPropertyDescriptor,rm=(o,e,t,i)=>{for(var s=i>1?void 0:i?sm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&im(e,t,s),s};class fr extends w{connectedCallback(){super.connectedCallback(),this.styles!==void 0&&this.$fastController.removeStyles(this.styles),this.styles=p`
522
+ :host{--textContent:'${this.textContent}'}`,this.$fastController.addStyles(this.styles)}}rm([a({mode:"boolean"})],fr.prototype,"disabled",2),nt(fr,rt);function nm(o={}){return g`<template slot="tab" role="tab" aria-disabled="${e=>e.disabled}">${Ke(o)}<span class="tab-content"><slot></slot></span>${mt(o)}</template>`}const am=nm({}),lm=p`
523
523
  ${I("inline-flex")}
524
524
 
525
525
  :host{position:relative;flex-direction:column;cursor:pointer;box-sizing:border-box;justify-content:center;line-height:${j};font-family:${k};font-size:${M};color:${Le};fill:currentcolor;grid-row:1;padding:${xe} ${fe};border-radius:${T}}:host .tab-content{display:inline-flex;flex-direction:column;padding:0 2px}:host([aria-selected='true']){color:${O};font-weight:${U}}:host .tab-content::after{content:var(--textContent);visibility:hidden;height:0;line-height:${j};font-weight:${U}}:host([aria-selected='true'])::after{background-color:${Rt};border-radius:${Se};content:'';inset:0;position:absolute;z-index:2}:host([aria-selected='false']:hover)::after{background-color:${lo};border-radius:${Se};content:'';inset:0;position:absolute;z-index:1}:host([aria-selected='true'][disabled])::after{background-color:${A}}::slotted([slot='start']),::slotted([slot='end']){display:flex}::slotted([slot='start']){margin-inline-end:11px}::slotted([slot='end']){margin-inline-start:11px}:host([disabled]){cursor:not-allowed;fill:${A};color:${A}}:host([disabled]:hover)::after{background-color:unset}:host(:focus){outline:none}:host(:focus-visible){border-radius:${He};box-shadow:0 0 0 3px ${Ve};outline:1px solid ${Us}}`.withBehaviors(le(p`
526
- :host([aria-selected='true'])::after{background-color:Highlight}`)),dm=fr.compose({name:`${b.prefix}-tab`,template:lm,styles:cm});dm.define(b.registry);const hm={subtle:"subtle",transparent:"transparent"},ss=Ce;var um=Object.defineProperty,pm=Object.getOwnPropertyDescriptor,Yt=(o,e,t,i)=>{for(var s=i>1?void 0:i?pm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&um(e,t,s),s};class Qo extends w{constructor(){super(...arguments),this.orientation=ss.horizontal,this.prevActiveTabIndex=0,this.activeTabIndex=0,this.change=()=>{this.$emit("change",this.activetab)},this.isDisabledElement=e=>e.getAttribute("aria-disabled")==="true",this.isHiddenElement=e=>e.hasAttribute("hidden"),this.isFocusableElement=e=>!this.isDisabledElement(e)&&!this.isHiddenElement(e),this.handleTabClick=e=>{const t=e.currentTarget;t.nodeType===1&&this.isFocusableElement(t)&&(this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=this.tabs.indexOf(t),this.setComponent())},this.handleTabKeyDown=e=>{if(this.isHorizontal())switch(e.key){case $i:e.preventDefault(),this.adjustBackward(e);break;case vi:e.preventDefault(),this.adjustForward(e);break}else switch(e.key){case yi:e.preventDefault(),this.adjustBackward(e);break;case mi:e.preventDefault(),this.adjustForward(e);break}switch(e.key){case wi:e.preventDefault(),this.adjust(-this.activeTabIndex);break;case ki:e.preventDefault(),this.adjust(this.tabs.length-this.activeTabIndex-1);break}}}orientationChanged(){this.$fastController.isConnected&&this.setTabs()}activeidChanged(e,t){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.prevActiveTabIndex=this.tabs.findIndex(i=>i.id===e),this.setTabs())}tabsChanged(){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.setTabs())}tabpanelsChanged(){this.$fastController.isConnected&&this.tabpanels.length<=this.tabs.length&&(this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.setTabs())}getActiveIndex(){return this.activeid!==void 0?this.tabIds.indexOf(this.activeid)===-1?0:this.tabIds.indexOf(this.activeid):0}setTabs(){const e="gridColumn",t="gridRow",i=this.isHorizontal()?e:t;this.activeTabIndex=this.getActiveIndex(),this.tabs.forEach((s,r)=>{if(s.slot==="tab"){const n=this.activeTabIndex===r&&this.isFocusableElement(s),d=this.tabIds[r],u=this.tabpanelIds[r];s.setAttribute("id",d),s.setAttribute("aria-selected",n?"true":"false"),s.setAttribute("aria-controls",u),s.addEventListener("click",this.handleTabClick),s.addEventListener("keydown",this.handleTabKeyDown),s.setAttribute("tabindex",n?"0":"-1"),n&&(this.activetab=s,this.activeid=d)}s.style[e]="",s.style[t]="",s.style[i]=`${r+1}`,this.isHorizontal()?s.classList.remove("vertical"):s.classList.add("vertical")}),this.setTabPanels()}setTabPanels(){this.tabpanels.forEach((e,t)=>{const i=this.tabIds[t],s=this.tabpanelIds[t];e.setAttribute("id",s),e.setAttribute("aria-labelledby",i),this.activeTabIndex!==t?e.setAttribute("hidden",""):e.removeAttribute("hidden")})}getTabIds(){return this.tabs.map(e=>e.getAttribute("id")??`tab-${io()}`)}getTabPanelIds(){return this.tabpanels.map(e=>e.getAttribute("id")??`panel-${io()}`)}setComponent(){this.activeTabIndex!==this.prevActiveTabIndex&&(this.activeid=this.tabIds[this.activeTabIndex],this.focusTab(),this.change())}isHorizontal(){return this.orientation===ss.horizontal}adjust(e){const t=this.tabs.filter(n=>this.isFocusableElement(n)),i=t.indexOf(this.activetab),s=Ts(0,t.length-1,i+e),r=this.tabs.indexOf(t[s]);r>-1&&this.moveToTabByIndex(this.tabs,r)}adjustForward(e){const t=this.tabs;let i=0;for(i=this.activetab?t.indexOf(this.activetab)+1:1,i===t.length&&(i=0);i<t.length&&t.length>1;)if(this.isFocusableElement(t[i])){this.moveToTabByIndex(t,i);break}else{if(this.activetab&&i===t.indexOf(this.activetab))break;i+1>=t.length?i=0:i+=1}}adjustBackward(e){const t=this.tabs;let i=0;for(i=this.activetab?t.indexOf(this.activetab)-1:0,i=i<0?t.length-1:i;i>=0&&t.length>1;)if(this.isFocusableElement(t[i])){this.moveToTabByIndex(t,i);break}else i-1<0?i=t.length-1:i-=1}moveToTabByIndex(e,t){const i=e[t];this.activetab=i,this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=t,i.focus(),this.setComponent()}focusTab(){this.tabs[this.activeTabIndex].focus()}connectedCallback(){super.connectedCallback(),this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.activeTabIndex=this.getActiveIndex()}}Yt([a],Qo.prototype,"orientation",2),Yt([a],Qo.prototype,"activeid",2),Yt([$],Qo.prototype,"tabs",2),Yt([$],Qo.prototype,"tabpanels",2);class Zo extends Qo{constructor(){super(...arguments),this.activeTabData={x:0,y:0,height:0,width:0},this.previousActiveTabData={x:0,y:0,height:0,width:0},this.activeTabOffset=0,this.activeTabScale=1,this.appearance=hm.transparent}calculateAnimationProperties(e){this.activeTabOffset=this.getTabPosition(e),this.activeTabScale=this.getTabScale(e)}getTabPosition(e){return this.orientation===ss.horizontal?this.previousActiveTabData.x-(e.getBoundingClientRect().x-this.getBoundingClientRect().x):this.previousActiveTabData.y-(e.getBoundingClientRect().y-this.getBoundingClientRect().y)}getTabScale(e){return this.orientation===ss.horizontal?this.previousActiveTabData.width/e.getBoundingClientRect().width:this.previousActiveTabData.height/e.getBoundingClientRect().height}applyUpdatedCSSValues(e){this.calculateAnimationProperties(e),this.setTabScaleCSSVar(),this.setTabOffsetCSSVar()}animationLoop(e){e.setAttribute("data-animate","false"),this.applyUpdatedCSSValues(e),this.previousActiveTabData=this.activeTabData,this.applyUpdatedCSSValues(e),e.setAttribute("data-animate","true")}setTabData(){if(this.tabs&&this.tabs.length>0){const e=this.tabs,i=(this.activetab||e[0])?.getBoundingClientRect(),s=this.getBoundingClientRect();this.activeTabData={x:i.x-s.x,y:i.y-s.y,height:i.height,width:i.width},this.previousActiveTabData?.x!==this.activeTabData?.x&&this.previousActiveTabData?.y!==this.activeTabData?.y&&(this.previousActiveTabData=this.activeTabData)}}setTabOffsetCSSVar(){this.styles=p`
526
+ :host([aria-selected='true'])::after{background-color:Highlight}`)),cm=fr.compose({name:`${b.prefix}-tab`,template:am,styles:lm});cm.define(b.registry);const dm={subtle:"subtle",transparent:"transparent"},ss=Ce;var hm=Object.defineProperty,um=Object.getOwnPropertyDescriptor,Yt=(o,e,t,i)=>{for(var s=i>1?void 0:i?um(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&hm(e,t,s),s};class Qo extends w{constructor(){super(...arguments),this.orientation=ss.horizontal,this.prevActiveTabIndex=0,this.activeTabIndex=0,this.change=()=>{this.$emit("change",this.activetab)},this.isDisabledElement=e=>e.getAttribute("aria-disabled")==="true",this.isHiddenElement=e=>e.hasAttribute("hidden"),this.isFocusableElement=e=>!this.isDisabledElement(e)&&!this.isHiddenElement(e),this.handleTabClick=e=>{const t=e.currentTarget;t.nodeType===1&&this.isFocusableElement(t)&&(this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=this.tabs.indexOf(t),this.setComponent())},this.handleTabKeyDown=e=>{if(this.isHorizontal())switch(e.key){case $i:e.preventDefault(),this.adjustBackward(e);break;case vi:e.preventDefault(),this.adjustForward(e);break}else switch(e.key){case yi:e.preventDefault(),this.adjustBackward(e);break;case mi:e.preventDefault(),this.adjustForward(e);break}switch(e.key){case wi:e.preventDefault(),this.adjust(-this.activeTabIndex);break;case ki:e.preventDefault(),this.adjust(this.tabs.length-this.activeTabIndex-1);break}}}orientationChanged(){this.$fastController.isConnected&&this.setTabs()}activeidChanged(e,t){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.prevActiveTabIndex=this.tabs.findIndex(i=>i.id===e),this.setTabs())}tabsChanged(){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.setTabs())}tabpanelsChanged(){this.$fastController.isConnected&&this.tabpanels.length<=this.tabs.length&&(this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.setTabs())}getActiveIndex(){return this.activeid!==void 0?this.tabIds.indexOf(this.activeid)===-1?0:this.tabIds.indexOf(this.activeid):0}setTabs(){const e="gridColumn",t="gridRow",i=this.isHorizontal()?e:t;this.activeTabIndex=this.getActiveIndex(),this.tabs.forEach((s,r)=>{if(s.slot==="tab"){const n=this.activeTabIndex===r&&this.isFocusableElement(s),d=this.tabIds[r],u=this.tabpanelIds[r];s.setAttribute("id",d),s.setAttribute("aria-selected",n?"true":"false"),s.setAttribute("aria-controls",u),s.addEventListener("click",this.handleTabClick),s.addEventListener("keydown",this.handleTabKeyDown),s.setAttribute("tabindex",n?"0":"-1"),n&&(this.activetab=s,this.activeid=d)}s.style[e]="",s.style[t]="",s.style[i]=`${r+1}`,this.isHorizontal()?s.classList.remove("vertical"):s.classList.add("vertical")}),this.setTabPanels()}setTabPanels(){this.tabpanels.forEach((e,t)=>{const i=this.tabIds[t],s=this.tabpanelIds[t];e.setAttribute("id",s),e.setAttribute("aria-labelledby",i),this.activeTabIndex!==t?e.setAttribute("hidden",""):e.removeAttribute("hidden")})}getTabIds(){return this.tabs.map(e=>e.getAttribute("id")??`tab-${io()}`)}getTabPanelIds(){return this.tabpanels.map(e=>e.getAttribute("id")??`panel-${io()}`)}setComponent(){this.activeTabIndex!==this.prevActiveTabIndex&&(this.activeid=this.tabIds[this.activeTabIndex],this.focusTab(),this.change())}isHorizontal(){return this.orientation===ss.horizontal}adjust(e){const t=this.tabs.filter(n=>this.isFocusableElement(n)),i=t.indexOf(this.activetab),s=Ts(0,t.length-1,i+e),r=this.tabs.indexOf(t[s]);r>-1&&this.moveToTabByIndex(this.tabs,r)}adjustForward(e){const t=this.tabs;let i=0;for(i=this.activetab?t.indexOf(this.activetab)+1:1,i===t.length&&(i=0);i<t.length&&t.length>1;)if(this.isFocusableElement(t[i])){this.moveToTabByIndex(t,i);break}else{if(this.activetab&&i===t.indexOf(this.activetab))break;i+1>=t.length?i=0:i+=1}}adjustBackward(e){const t=this.tabs;let i=0;for(i=this.activetab?t.indexOf(this.activetab)-1:0,i=i<0?t.length-1:i;i>=0&&t.length>1;)if(this.isFocusableElement(t[i])){this.moveToTabByIndex(t,i);break}else i-1<0?i=t.length-1:i-=1}moveToTabByIndex(e,t){const i=e[t];this.activetab=i,this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=t,i.focus(),this.setComponent()}focusTab(){this.tabs[this.activeTabIndex].focus()}connectedCallback(){super.connectedCallback(),this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.activeTabIndex=this.getActiveIndex()}}Yt([a],Qo.prototype,"orientation",2),Yt([a],Qo.prototype,"activeid",2),Yt([$],Qo.prototype,"tabs",2),Yt([$],Qo.prototype,"tabpanels",2);class Zo extends Qo{constructor(){super(...arguments),this.activeTabData={x:0,y:0,height:0,width:0},this.previousActiveTabData={x:0,y:0,height:0,width:0},this.activeTabOffset=0,this.activeTabScale=1,this.appearance=dm.transparent}calculateAnimationProperties(e){this.activeTabOffset=this.getTabPosition(e),this.activeTabScale=this.getTabScale(e)}getTabPosition(e){return this.orientation===ss.horizontal?this.previousActiveTabData.x-(e.getBoundingClientRect().x-this.getBoundingClientRect().x):this.previousActiveTabData.y-(e.getBoundingClientRect().y-this.getBoundingClientRect().y)}getTabScale(e){return this.orientation===ss.horizontal?this.previousActiveTabData.width/e.getBoundingClientRect().width:this.previousActiveTabData.height/e.getBoundingClientRect().height}applyUpdatedCSSValues(e){this.calculateAnimationProperties(e),this.setTabScaleCSSVar(),this.setTabOffsetCSSVar()}animationLoop(e){e.setAttribute("data-animate","false"),this.applyUpdatedCSSValues(e),this.previousActiveTabData=this.activeTabData,this.applyUpdatedCSSValues(e),e.setAttribute("data-animate","true")}setTabData(){if(this.tabs&&this.tabs.length>0){const e=this.tabs,i=(this.activetab||e[0])?.getBoundingClientRect(),s=this.getBoundingClientRect();this.activeTabData={x:i.x-s.x,y:i.y-s.y,height:i.height,width:i.width},this.previousActiveTabData?.x!==this.activeTabData?.x&&this.previousActiveTabData?.y!==this.activeTabData?.y&&(this.previousActiveTabData=this.activeTabData)}}setTabOffsetCSSVar(){this.styles=p`
527
527
  :host{--tabIndicatorOffset:${this.activeTabOffset.toString()}px}`,this.$fastController.addStyles(this.styles)}setTabScaleCSSVar(){this.styles=p`
528
- :host{--tabIndicatorScale:${this.activeTabScale.toString()}}`,this.$fastController.addStyles(this.styles)}activeidChanged(e,t){super.activeidChanged(e,t),this.setTabData(),this.activetab&&this.animationLoop(this.activetab)}tabsChanged(){super.tabsChanged(),this.setTabData()}}Yt([a],Zo.prototype,"appearance",2),Yt([a({mode:"boolean"})],Zo.prototype,"disabled",2),Yt([a],Zo.prototype,"size",2),nt(Zo,rt);function bm(o={}){return g` ${Ke(o)}<div class="tablist" part="tablist" role="tablist"><slot name="tab" ${K("tabs")}></slot></div>${mt(o)}<div class="tabpanel" part="tabpanel"><slot name="tabpanel" ${K("tabpanels")}></slot></div>`}const gm=bm({}),fm=p`
528
+ :host{--tabIndicatorScale:${this.activeTabScale.toString()}}`,this.$fastController.addStyles(this.styles)}activeidChanged(e,t){super.activeidChanged(e,t),this.setTabData(),this.activetab&&this.animationLoop(this.activetab)}tabsChanged(){super.tabsChanged(),this.setTabData()}}Yt([a],Zo.prototype,"appearance",2),Yt([a({mode:"boolean"})],Zo.prototype,"disabled",2),Yt([a],Zo.prototype,"size",2),nt(Zo,rt);function pm(o={}){return g` ${Ke(o)}<div class="tablist" part="tablist" role="tablist"><slot name="tab" ${K("tabs")}></slot></div>${mt(o)}<div class="tabpanel" part="tabpanel"><slot name="tabpanel" ${K("tabpanels")}></slot></div>`}const bm=pm({}),gm=p`
529
529
  ${I("grid")}
530
530
 
531
- :host{box-sizing:border-box;font-family:${k};font-size:${M};line-height:${j};color:${Le};grid-template-columns:auto 1fr auto;grid-template-rows:auto 1fr}:host([disabled]){cursor:not-allowed;color:${A}}:host([disabled]) ::slotted(fluent-tab){pointer-events:none;cursor:not-allowed;color:${A}}:host([disabled]) ::slotted(fluent-tab:after){background-color:${A}}:host([disabled]) ::slotted(fluent-tab[aria-selected='true'])::after{background-color:${A}}:host([disabled]) ::slotted(fluent-tab:hover):before{content:unset}:host ::slotted(fluent-tab){border-radius:${T}}:host ::slotted(fluent-tab[aria-selected='true'])::before{background-color:${A}}.tablist{display:grid;grid-template-rows:auto auto;grid-template-columns:auto;position:relative;width:max-content;align-self:end;box-sizing:border-box}::slotted([slot='start']),::slotted([slot='end']){display:flex;align-self:center}::slotted([slot='start']){margin-inline-end:11px}::slotted([slot='end']){margin-inline-start:11px}.tabpanel{grid-row:2;grid-column-start:1;grid-column-end:4;position:relative}:host([orientation='vertical']){grid-template-rows:auto 1fr auto;grid-template-columns:auto 1fr}:host([orientation='vertical']) .tablist{grid-row-start:2;grid-row-end:2;display:grid;grid-template-rows:auto;grid-template-columns:auto 1fr;position:relative;width:max-content;justify-self:end;align-self:flex-start;width:100%}:host([orientation='vertical']) .tabpanel{grid-column:2;grid-row-start:1;grid-row-end:4}:host([orientation='vertical']) ::slotted([slot='end']){grid-row:3}:host([appearance='subtle']) ::slotted(fluent-tab:hover){background-color:${_i};color:${Ds};fill:${Mn}}:host([appearance='subtle']) ::slotted(fluent-tab:active){background-color:${ro};fill:${ro};color:${O}}:host([size='small']) ::slotted(fluent-tab){font-size:${M};line-height:${j};padding:${et} ${de}}:host([size='large']) ::slotted(fluent-tab){font-size:${ke};line-height:${Ie};padding:${ji} ${fe}}:host ::slotted(fluent-tab[data-animate='true'])::after{transition-property:transform;transition-duration:${fa};transition-timing-function:${or}}:host ::slotted(fluent-tab)::after{height:${ge};margin-top:auto;transform-origin:left;transform:translateX(var(--tabIndicatorOffset)) scaleX(var(--tabIndicatorScale))}:host([orientation='vertical']) ::slotted(fluent-tab)::after{width:${ge};height:unset;margin-top:unset;transform-origin:top;transform:translateY(var(--tabIndicatorOffset)) scaleY(var(--tabIndicatorScale))}:host ::slotted(fluent-tab)::before{height:${ge};border-radius:${Se};content:'';inset:0;position:absolute;margin-top:auto}:host([orientation='vertical']) ::slotted(fluent-tab)::before{height:unset;width:${ge};margin-inline-end:auto;transform-origin:top}:host ::slotted(fluent-tab[aria-selected='false']:hover)::after{height:${ge};margin-top:auto;transform-origin:left}:host([orientation='vertical']) ::slotted(fluent-tab[aria-selected='false']:hover)::after{height:unset;margin-inline-end:auto;transform-origin:top;width:${ge}}:host([orientation='vertical']) ::slotted(fluent-tab){align-items:flex-start;grid-column:2;padding-top:${et};padding-bottom:${et}}:host([orientation='vertical'][size='small']) ::slotted(fluent-tab){padding-top:${Vo};padding-bottom:${Vo}}:host([orientation='vertical'][size='large']) ::slotted(fluent-tab){padding-top:${oe};padding-bottom:${oe}}:host([size='small']) ::slotted(fluent-tab)::after,:host([size='small']) ::slotted(fluent-tab)::before,:host([size='small']) ::slotted(fluent-tab:hover)::after{right:${de};left:${de}}:host ::slotted(fluent-tab)::after,:host ::slotted(fluent-tab)::before,:host ::slotted(fluent-tab:hover)::after{right:${fe};left:${fe}}:host([size='large']) ::slotted(fluent-tab)::after,:host([size='large']) ::slotted(fluent-tab)::before,:host([size='large']) ::slotted(fluent-tab:hover)::after{right:${fe};left:${fe}}:host([orientation='vertical'][size='small']) ::slotted(fluent-tab)::after,:host([orientation='vertical'][size='small']) ::slotted(fluent-tab)::before,:host([orientation='vertical'][size='small']) ::slotted(fluent-tab:hover)::after{right:0;left:0;top:${et};bottom:${et}}:host([orientation='vertical']) ::slotted(fluent-tab)::after,:host([orientation='vertical']) ::slotted(fluent-tab)::before,:host([orientation='vertical']) ::slotted(fluent-tab:hover)::after{right:0;left:0;top:${oe};bottom:${oe}}:host([orientation='vertical'][size='large']) ::slotted(fluent-tab)::after,:host([orientation='vertical'][size='large']) ::slotted(fluent-tab)::before,:host([orientation='vertical'][size='large']) ::slotted(fluent-tab:hover)::after{right:0;left:0;top:${uo};bottom:${uo}}`,mm=Zo.compose({name:`${b.prefix}-tabs`,template:gm,styles:fm});mm.define(b.registry);const $m=o=>o.getAttribute("aria-disabled")==="true",vm=o=>o.hasAttribute("hidden"),rs=o=>!$m(o)&&!vm(o),Ga={subtle:"subtle",transparent:"transparent"},ym={small:"small",medium:"medium",large:"large"},yo=Ce;var km=Object.defineProperty,xm=Object.getOwnPropertyDescriptor,ko=(o,e,t,i)=>{for(var s=i>1?void 0:i?xm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&km(e,t,s),s};class Jo extends w{constructor(){super(...arguments),this.elementInternals=this.attachInternals(),this.disabled=!1,this.orientation=yo.horizontal,this.prevActiveTabIndex=0,this.activeTabIndex=0,this.change=()=>{this.$emit("change",this.activetab)},this.handleTabClick=e=>{const t=e.currentTarget;t.nodeType===Node.ELEMENT_NODE&&rs(t)&&(this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=this.tabs.indexOf(t),this.setComponent())},this.handleTabKeyDown=e=>{const t=As(this);switch(e.key){case $i:if(!this.isHorizontal())return;e.preventDefault(),this.adjust(t==="ltr"?-1:1);break;case vi:if(!this.isHorizontal())return;e.preventDefault(),this.adjust(t==="ltr"?1:-1);break;case yi:if(this.isHorizontal())return;e.preventDefault(),this.adjust(-1);break;case mi:if(this.isHorizontal())return;e.preventDefault(),this.adjust(1);break;case wi:e.preventDefault(),this.adjust(-this.activeTabIndex);break;case ki:e.preventDefault(),this.adjust(this.tabs.filter(i=>rs(i)).length-this.activeTabIndex-1);break}}}disabledChanged(e,t){v(this.elementInternals,"disabled",t)}orientationChanged(e,t){this.elementInternals.ariaOrientation=t??yo.horizontal,y(this.elementInternals,e,t,yo),this.$fastController.isConnected&&this.setTabs()}activeidChanged(e,t){this.$fastController.isConnected&&this.tabs.length>0&&(this.prevActiveTabIndex=this.tabs.findIndex(i=>i.id===e),this.setTabs())}tabsChanged(){this.$fastController.isConnected&&this.tabs.length>0&&(this.tabIds=this.getTabIds(),this.setTabs())}getActiveIndex(){return this.activeid!==void 0?this.tabIds.indexOf(this.activeid)===-1?0:this.tabIds.indexOf(this.activeid):0}setTabs(){this.activeTabIndex=this.getActiveIndex(),this.tabs.forEach((e,t)=>{if(e.slot==="tab"){const i=this.activeTabIndex===t&&rs(e),s=this.tabIds[t];e.setAttribute("id",s),e.setAttribute("aria-selected",i?"true":"false"),e.addEventListener("click",this.handleTabClick),e.addEventListener("keydown",this.handleTabKeyDown),e.setAttribute("tabindex",i&&!this.disabled?"0":"-1"),i&&(this.activetab=e,this.activeid=s),this.change()}})}getTabIds(){return this.tabs.map(e=>e.getAttribute("id")??`tab-${io()}`)}setComponent(){this.activeTabIndex!==this.prevActiveTabIndex&&(this.activeid=this.tabIds[this.activeTabIndex],this.focusTab(),this.change())}isHorizontal(){return this.orientation===yo.horizontal}adjust(e){const t=this.tabs.filter(n=>rs(n)),i=t.indexOf(this.activetab),s=Nl(0,t.length-1,i+e),r=this.tabs.indexOf(t[s]);r>-1&&this.activateTabByIndex(this.tabs,r)}activateTabByIndex(e,t){const i=e[t];this.activetab=i,this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=t,i.focus(),this.setComponent()}focusTab(){this.tabs[this.activeTabIndex].focus()}connectedCallback(){super.connectedCallback(),this.tabIds=this.getTabIds(),this.activeTabIndex=this.getActiveIndex()}}ko([a({mode:"boolean"})],Jo.prototype,"disabled",2),ko([a],Jo.prototype,"orientation",2),ko([a],Jo.prototype,"activeid",2),ko([$],Jo.prototype,"tabs",2);class mr extends Jo{constructor(){super(...arguments),this.activeTabData={x:0,y:0,height:0,width:0},this.previousActiveTabData={x:0,y:0,height:0,width:0},this.activeTabOffset=0,this.activeTabScale=1,this.appearance=Ga.transparent}appearanceChanged(e,t){y(this.elementInternals,e,t,Ga)}sizeChanged(e,t){y(this.elementInternals,e,t,ym)}calculateAnimationProperties(e){this.activeTabOffset=this.getTabPosition(e),this.activeTabScale=this.getTabScale(e)}getTabPosition(e){return this.orientation===yo.horizontal?this.previousActiveTabData.x-(e.getBoundingClientRect().x-this.getBoundingClientRect().x):this.previousActiveTabData.y-(e.getBoundingClientRect().y-this.getBoundingClientRect().y)}getTabScale(e){return this.orientation===yo.horizontal?this.previousActiveTabData.width/e.getBoundingClientRect().width:this.previousActiveTabData.height/e.getBoundingClientRect().height}applyUpdatedCSSValues(e){this.calculateAnimationProperties(e),this.setAnimationVars()}animationLoop(e){e.setAttribute("data-animate","false"),this.applyUpdatedCSSValues(e),this.previousActiveTabData=this.activeTabData,this.applyUpdatedCSSValues(e),e.setAttribute("data-animate","true")}setTabData(){if(this.tabs&&this.tabs.length>0){const e=this.tabs,i=(this.activetab||e[0])?.getBoundingClientRect(),s=this.getBoundingClientRect();this.activeTabData={x:i.x-s.x,y:i.y-s.y,height:i.height,width:i.width},this.previousActiveTabData?.x!==this.activeTabData?.x&&this.previousActiveTabData?.y!==this.activeTabData?.y&&(this.previousActiveTabData=this.activeTabData)}}setAnimationVars(){this.style.setProperty("--tabIndicatorOffset",`${this.activeTabOffset}px`),this.style.setProperty("--tabIndicatorScale",`${this.activeTabScale}`)}activeidChanged(e,t){super.activeidChanged(e,t),this.setTabData(),this.activetab&&this.animationLoop(this.activetab)}tabsChanged(){super.tabsChanged(),this.setTabData(),this.activetab&&this.animationLoop(this.activetab)}}ko([a],mr.prototype,"appearance",2),ko([a],mr.prototype,"size",2);const wm=g`<template role="tablist"><slot name="tab" ${K("tabs")}></slot></template>`,Cm=p`
531
+ :host{box-sizing:border-box;font-family:${k};font-size:${M};line-height:${j};color:${Le};grid-template-columns:auto 1fr auto;grid-template-rows:auto 1fr}:host([disabled]){cursor:not-allowed;color:${A}}:host([disabled]) ::slotted(fluent-tab){pointer-events:none;cursor:not-allowed;color:${A}}:host([disabled]) ::slotted(fluent-tab:after){background-color:${A}}:host([disabled]) ::slotted(fluent-tab[aria-selected='true'])::after{background-color:${A}}:host([disabled]) ::slotted(fluent-tab:hover):before{content:unset}:host ::slotted(fluent-tab){border-radius:${T}}:host ::slotted(fluent-tab[aria-selected='true'])::before{background-color:${A}}.tablist{display:grid;grid-template-rows:auto auto;grid-template-columns:auto;position:relative;width:max-content;align-self:end;box-sizing:border-box}::slotted([slot='start']),::slotted([slot='end']){display:flex;align-self:center}::slotted([slot='start']){margin-inline-end:11px}::slotted([slot='end']){margin-inline-start:11px}.tabpanel{grid-row:2;grid-column-start:1;grid-column-end:4;position:relative}:host([orientation='vertical']){grid-template-rows:auto 1fr auto;grid-template-columns:auto 1fr}:host([orientation='vertical']) .tablist{grid-row-start:2;grid-row-end:2;display:grid;grid-template-rows:auto;grid-template-columns:auto 1fr;position:relative;width:max-content;justify-self:end;align-self:flex-start;width:100%}:host([orientation='vertical']) .tabpanel{grid-column:2;grid-row-start:1;grid-row-end:4}:host([orientation='vertical']) ::slotted([slot='end']){grid-row:3}:host([appearance='subtle']) ::slotted(fluent-tab:hover){background-color:${_i};color:${Ds};fill:${Mn}}:host([appearance='subtle']) ::slotted(fluent-tab:active){background-color:${ro};fill:${ro};color:${O}}:host([size='small']) ::slotted(fluent-tab){font-size:${M};line-height:${j};padding:${et} ${de}}:host([size='large']) ::slotted(fluent-tab){font-size:${ke};line-height:${Ie};padding:${ji} ${fe}}:host ::slotted(fluent-tab[data-animate='true'])::after{transition-property:transform;transition-duration:${fa};transition-timing-function:${or}}:host ::slotted(fluent-tab)::after{height:${ge};margin-top:auto;transform-origin:left;transform:translateX(var(--tabIndicatorOffset)) scaleX(var(--tabIndicatorScale))}:host([orientation='vertical']) ::slotted(fluent-tab)::after{width:${ge};height:unset;margin-top:unset;transform-origin:top;transform:translateY(var(--tabIndicatorOffset)) scaleY(var(--tabIndicatorScale))}:host ::slotted(fluent-tab)::before{height:${ge};border-radius:${Se};content:'';inset:0;position:absolute;margin-top:auto}:host([orientation='vertical']) ::slotted(fluent-tab)::before{height:unset;width:${ge};margin-inline-end:auto;transform-origin:top}:host ::slotted(fluent-tab[aria-selected='false']:hover)::after{height:${ge};margin-top:auto;transform-origin:left}:host([orientation='vertical']) ::slotted(fluent-tab[aria-selected='false']:hover)::after{height:unset;margin-inline-end:auto;transform-origin:top;width:${ge}}:host([orientation='vertical']) ::slotted(fluent-tab){align-items:flex-start;grid-column:2;padding-top:${et};padding-bottom:${et}}:host([orientation='vertical'][size='small']) ::slotted(fluent-tab){padding-top:${Vo};padding-bottom:${Vo}}:host([orientation='vertical'][size='large']) ::slotted(fluent-tab){padding-top:${oe};padding-bottom:${oe}}:host([size='small']) ::slotted(fluent-tab)::after,:host([size='small']) ::slotted(fluent-tab)::before,:host([size='small']) ::slotted(fluent-tab:hover)::after{right:${de};left:${de}}:host ::slotted(fluent-tab)::after,:host ::slotted(fluent-tab)::before,:host ::slotted(fluent-tab:hover)::after{right:${fe};left:${fe}}:host([size='large']) ::slotted(fluent-tab)::after,:host([size='large']) ::slotted(fluent-tab)::before,:host([size='large']) ::slotted(fluent-tab:hover)::after{right:${fe};left:${fe}}:host([orientation='vertical'][size='small']) ::slotted(fluent-tab)::after,:host([orientation='vertical'][size='small']) ::slotted(fluent-tab)::before,:host([orientation='vertical'][size='small']) ::slotted(fluent-tab:hover)::after{right:0;left:0;top:${et};bottom:${et}}:host([orientation='vertical']) ::slotted(fluent-tab)::after,:host([orientation='vertical']) ::slotted(fluent-tab)::before,:host([orientation='vertical']) ::slotted(fluent-tab:hover)::after{right:0;left:0;top:${oe};bottom:${oe}}:host([orientation='vertical'][size='large']) ::slotted(fluent-tab)::after,:host([orientation='vertical'][size='large']) ::slotted(fluent-tab)::before,:host([orientation='vertical'][size='large']) ::slotted(fluent-tab:hover)::after{right:0;left:0;top:${uo};bottom:${uo}}`,fm=Zo.compose({name:`${b.prefix}-tabs`,template:bm,styles:gm});fm.define(b.registry);const mm=o=>o.getAttribute("aria-disabled")==="true",$m=o=>o.hasAttribute("hidden"),rs=o=>!mm(o)&&!$m(o),Ga={subtle:"subtle",transparent:"transparent"},vm={small:"small",medium:"medium",large:"large"},yo=Ce;var ym=Object.defineProperty,km=Object.getOwnPropertyDescriptor,ko=(o,e,t,i)=>{for(var s=i>1?void 0:i?km(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&ym(e,t,s),s};class Jo extends w{constructor(){super(...arguments),this.elementInternals=this.attachInternals(),this.disabled=!1,this.orientation=yo.horizontal,this.prevActiveTabIndex=0,this.activeTabIndex=0,this.change=()=>{this.$emit("change",this.activetab)},this.handleTabClick=e=>{const t=e.currentTarget;t.nodeType===Node.ELEMENT_NODE&&rs(t)&&(this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=this.tabs.indexOf(t),this.setComponent())},this.handleTabKeyDown=e=>{const t=As(this);switch(e.key){case $i:if(!this.isHorizontal())return;e.preventDefault(),this.adjust(t==="ltr"?-1:1);break;case vi:if(!this.isHorizontal())return;e.preventDefault(),this.adjust(t==="ltr"?1:-1);break;case yi:if(this.isHorizontal())return;e.preventDefault(),this.adjust(-1);break;case mi:if(this.isHorizontal())return;e.preventDefault(),this.adjust(1);break;case wi:e.preventDefault(),this.adjust(-this.activeTabIndex);break;case ki:e.preventDefault(),this.adjust(this.tabs.filter(i=>rs(i)).length-this.activeTabIndex-1);break}}}disabledChanged(e,t){v(this.elementInternals,"disabled",t)}orientationChanged(e,t){this.elementInternals.ariaOrientation=t??yo.horizontal,y(this.elementInternals,e,t,yo),this.$fastController.isConnected&&this.setTabs()}activeidChanged(e,t){this.$fastController.isConnected&&this.tabs.length>0&&(this.prevActiveTabIndex=this.tabs.findIndex(i=>i.id===e),this.setTabs())}tabsChanged(){this.$fastController.isConnected&&this.tabs.length>0&&(this.tabIds=this.getTabIds(),this.setTabs())}getActiveIndex(){return this.activeid!==void 0?this.tabIds.indexOf(this.activeid)===-1?0:this.tabIds.indexOf(this.activeid):0}setTabs(){this.activeTabIndex=this.getActiveIndex(),this.tabs.forEach((e,t)=>{if(e.slot==="tab"){const i=this.activeTabIndex===t&&rs(e),s=this.tabIds[t];e.setAttribute("id",s),e.setAttribute("aria-selected",i?"true":"false"),e.addEventListener("click",this.handleTabClick),e.addEventListener("keydown",this.handleTabKeyDown),e.setAttribute("tabindex",i&&!this.disabled?"0":"-1"),i&&(this.activetab=e,this.activeid=s),this.change()}})}getTabIds(){return this.tabs.map(e=>e.getAttribute("id")??`tab-${io()}`)}setComponent(){this.activeTabIndex!==this.prevActiveTabIndex&&(this.activeid=this.tabIds[this.activeTabIndex],this.focusTab(),this.change())}isHorizontal(){return this.orientation===yo.horizontal}adjust(e){const t=this.tabs.filter(n=>rs(n)),i=t.indexOf(this.activetab),s=Nl(0,t.length-1,i+e),r=this.tabs.indexOf(t[s]);r>-1&&this.activateTabByIndex(this.tabs,r)}activateTabByIndex(e,t){const i=e[t];this.activetab=i,this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=t,i.focus(),this.setComponent()}focusTab(){this.tabs[this.activeTabIndex].focus()}connectedCallback(){super.connectedCallback(),this.tabIds=this.getTabIds(),this.activeTabIndex=this.getActiveIndex()}}ko([a({mode:"boolean"})],Jo.prototype,"disabled",2),ko([a],Jo.prototype,"orientation",2),ko([a],Jo.prototype,"activeid",2),ko([$],Jo.prototype,"tabs",2);class mr extends Jo{constructor(){super(...arguments),this.activeTabData={x:0,y:0,height:0,width:0},this.previousActiveTabData={x:0,y:0,height:0,width:0},this.activeTabOffset=0,this.activeTabScale=1,this.appearance=Ga.transparent}appearanceChanged(e,t){y(this.elementInternals,e,t,Ga)}sizeChanged(e,t){y(this.elementInternals,e,t,vm)}calculateAnimationProperties(e){this.activeTabOffset=this.getTabPosition(e),this.activeTabScale=this.getTabScale(e)}getTabPosition(e){return this.orientation===yo.horizontal?this.previousActiveTabData.x-(e.getBoundingClientRect().x-this.getBoundingClientRect().x):this.previousActiveTabData.y-(e.getBoundingClientRect().y-this.getBoundingClientRect().y)}getTabScale(e){return this.orientation===yo.horizontal?this.previousActiveTabData.width/e.getBoundingClientRect().width:this.previousActiveTabData.height/e.getBoundingClientRect().height}applyUpdatedCSSValues(e){this.calculateAnimationProperties(e),this.setAnimationVars()}animationLoop(e){e.setAttribute("data-animate","false"),this.applyUpdatedCSSValues(e),this.previousActiveTabData=this.activeTabData,this.applyUpdatedCSSValues(e),e.setAttribute("data-animate","true")}setTabData(){if(this.tabs&&this.tabs.length>0){const e=this.tabs,i=(this.activetab||e[0])?.getBoundingClientRect(),s=this.getBoundingClientRect();this.activeTabData={x:i.x-s.x,y:i.y-s.y,height:i.height,width:i.width},this.previousActiveTabData?.x!==this.activeTabData?.x&&this.previousActiveTabData?.y!==this.activeTabData?.y&&(this.previousActiveTabData=this.activeTabData)}}setAnimationVars(){this.style.setProperty("--tabIndicatorOffset",`${this.activeTabOffset}px`),this.style.setProperty("--tabIndicatorScale",`${this.activeTabScale}`)}activeidChanged(e,t){super.activeidChanged(e,t),this.setTabData(),this.activetab&&this.animationLoop(this.activetab)}tabsChanged(){super.tabsChanged(),this.setTabData(),this.activetab&&this.animationLoop(this.activetab)}}ko([a],mr.prototype,"appearance",2),ko([a],mr.prototype,"size",2);const xm=g`<template role="tablist"><slot name="tab" ${K("tabs")}></slot></template>`,wm=p`
532
532
  ${I("flex")}
533
533
 
534
- :host{--tabPaddingInline:inherit;--tabPaddingBlock:inherit;--tabIndicatorInsetInline:0;--tabIndicatorInsetBlock:0;box-sizing:border-box;color:${Le};flex-direction:row}:host(${z}){flex-direction:column}:host ::slotted([role='tab']){align-items:flex-start}:host ::slotted([slot='tab'][data-animate='true'])::after{transition-property:transform;transition-duration:${fa};transition-timing-function:${or}}:host ::slotted([slot='tab'])::after{height:${ge};margin-block-start:auto;transform-origin:left;transform:translateX(var(--tabIndicatorOffset)) scaleX(var(--tabIndicatorScale))}:host(${z}) ::slotted([slot='tab'])::after{width:${ge};height:unset;margin-block-start:unset;transform-origin:top;transform:translateY(var(--tabIndicatorOffset)) scaleY(var(--tabIndicatorScale))}:host ::slotted([slot='tab'])::before{height:${ge};border-radius:${Se};content:'';inset-inline:var(--tabIndicatorInsetInline);inset-block:var(--tabIndicatorInsetBlock);position:absolute;margin-top:auto}:host ::slotted([slot='tab'])::before{inset-inline:var(--tabIndicatorInsetInline);inset-block:var(--tabIndicatorInsetBlock)}:host ::slotted([slot='tab'][aria-selected='true'])::before{background-color:${A}}:host ::slotted([slot='tab'][aria-selected='false']:hover)::after{height:${ge};margin-block-start:auto;transform-origin:left}:host(${z}) ::slotted([slot='tab'])::before,:host(${z}) ::slotted([slot='tab'][aria-selected='false']:hover)::after{height:unset;width:${ge};margin-inline-end:auto;transform-origin:top}:host(:where(${P},${C})) ::slotted([slot='tab']){padding-inline:var(--tabPaddingInline);padding-block:var(--tabPaddingBlock)}:host(${P}) ::slotted([slot='tab']){--tabPaddingBlock:${et};--tabPaddingInline:${de};font-size:${M};line-height:${j}}:host(${C}) ::slotted([slot='tab']){--tabPaddingBlock:${ji};--tabPaddingInline:${fe};font-size:${ke};line-height:${Ie}}:host ::slotted([slot='tab'])::after,:host ::slotted([slot='tab'])::before,:host ::slotted([slot='tab']:hover)::after{inset-inline:var(--tabIndicatorInsetInline)}:host ::slotted([slot='tab']){--tabIndicatorInsetInline:${fe}}:host(${P}) ::slotted([slot='tab']){--tabIndicatorInsetInline:${de}}:host(${C}) ::slotted([slot='tab']){--tabIndicatorInsetInline:${fe}}:host(${z}) ::slotted([slot='tab']){padding-block:var(--tabPaddingBlock)}:host(${z}) ::slotted([slot='tab']){--tabPaddingBlock:${oe}}:host(${z}${P}) ::slotted([slot='tab']){--tabPaddingBlock:${Vo}}:host(${z}${C}) ::slotted([slot='tab']){--tabPaddingBlock:${oe}}:host(${z}) ::slotted([slot='tab'])::after,:host(${z}) ::slotted([slot='tab'])::before,:host(${z}) ::slotted([slot='tab']:hover)::after{inset-inline:0;inset-block:var(--tabIndicatorInsetBlock)}:host(${z}){--tabIndicatorInsetBlock:${oe}}:host(${z}${P}){--tabIndicatorInsetBlock:${et}}:host(${z}${C}){--tabIndicatorInsetBlock:${uo}}:host(${_}){cursor:not-allowed;color:${A}}:host(${_}) ::slotted([slot='tab']){pointer-events:none;cursor:not-allowed;color:${A}}:host(${_}) ::slotted([slot='tab']:after){background-color:${A}}:host(${_}) ::slotted([slot='tab'][aria-selected='true'])::after{background-color:${A}}:host(${_}) ::slotted([slot='tab']:hover):before{content:unset}:host(${B}) ::slotted([slot='tab']:hover){background-color:${_i};color:${Ds};fill:${Mn}}:host(${B}) ::slotted([slot='tab']:active){background-color:${ro};fill:${ro};color:${O}}`,Sm=mr.compose({name:`${b.prefix}-tablist`,template:wm,styles:Cm});Sm.define(b.registry);const Im={small:"small",medium:"medium",large:"large"},ei={outline:"outline",filledLighter:"filled-lighter",filledDarker:"filled-darker"},zm=[ei.filledLighter,ei.filledDarker],ns={none:"none",both:"both",horizontal:"horizontal",vertical:"vertical"};var Pm=Object.defineProperty,Tm=Object.getOwnPropertyDescriptor,J=(o,e,t,i)=>{for(var s=i>1?void 0:i?Tm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Pm(e,t,s),s};class se extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.userInteracted=!1,this.preConnectControlEl=document.createElement("textarea"),this.autoResize=!1,this.disabled=!1,this.displayShadow=!1,this.readOnly=!1,this.required=!1,this.resize=ns.none,this.spellcheck=!1}defaultSlottedNodesChanged(){const e=this.getContent();this.defaultValue=e,this.value=e}labelSlottedNodesChanged(){this.labelEl&&(this.labelEl.hidden=!this.labelSlottedNodes.length),this.labelSlottedNodes.forEach(e=>{e.disabled=this.disabled,e.required=this.required})}autoResizeChanged(){this.maybeCreateAutoSizerEl(),v(this.elementInternals,"auto-resize",this.autoResize)}disabledChanged(){this.setDisabledSideEffect(this.disabled)}get form(){return this.elementInternals.form}get labels(){return this.elementInternals.labels}readOnlyChanged(){this.elementInternals.ariaReadOnly=`${!!this.readOnly}`}requiredChanged(){this.elementInternals.ariaRequired=`${!!this.required}`,this.labelSlottedNodes?.length&&this.labelSlottedNodes.forEach(e=>e.required=this.required)}resizeChanged(e,t){y(this.elementInternals,e,t,ns,"resize-"),v(this.elementInternals,"resize",Fs(ns,t)&&t!==ns.none)}get textLength(){return this.controlEl.textLength}get type(){return"textarea"}get validity(){return this.elementInternals.validity}get validationMessage(){return this.elementInternals.validationMessage||this.controlEl.validationMessage}get willValidate(){return this.elementInternals.willValidate}get defaultValue(){return this.controlEl?.defaultValue??this.preConnectControlEl.defaultValue}set defaultValue(e){const t=this.controlEl??this.preConnectControlEl;t.defaultValue=e,this.controlEl&&!this.userInteracted&&(this.controlEl.value=e)}get value(){return this.controlEl?.value??this.preConnectControlEl.value}set value(e){const t=this.controlEl??this.preConnectControlEl;t.value=e,this.setFormValue(e),this.setValidity()}connectedCallback(){super.connectedCallback(),this.setDefaultValue(),this.maybeCreateAutoSizerEl(),this.bindEvents(),this.observeControlElAttrs()}disconnectedCallback(){super.disconnectedCallback(),this.autoSizerObserver?.disconnect(),this.controlElAttrObserver?.disconnect()}formResetCallback(){this.value=this.defaultValue}formDisabledCallback(e){this.setDisabledSideEffect(e),this.setValidity()}setFormValue(e,t){this.elementInternals.setFormValue(e,e??t)}checkValidity(){return this.elementInternals.checkValidity()}reportValidity(){return this.elementInternals.reportValidity()}setCustomValidity(e){this.elementInternals.setValidity({customError:!!e},e?e.toString():void 0),this.reportValidity()}setValidity(e,t,i){this.$fastController.isConnected&&(this.disabled||this.readOnly?this.elementInternals.setValidity({}):this.elementInternals.setValidity(e??this.controlEl.validity,t??this.controlEl.validationMessage,i??this.controlEl),this.userInteracted&&this.toggleUserValidityState())}select(){this.controlEl.select()}setDefaultValue(){this.defaultValue=this.innerHTML.trim()||this.preConnectControlEl.defaultValue||"",this.value=this.preConnectControlEl.value||this.defaultValue,this.setFormValue(this.value),this.setValidity(),this.preConnectControlEl=null}bindEvents(){this.controlEl.addEventListener("input",()=>this.userInteracted=!0,{once:!0})}getContent(){return this.defaultSlottedNodes.map(e=>{switch(e.nodeType){case Node.ELEMENT_NODE:return e.outerHTML;case Node.TEXT_NODE:return e.textContent.trim();default:return""}}).join("")||""}observeControlElAttrs(){this.controlElAttrObserver=new MutationObserver(()=>{this.setValidity()}),this.controlElAttrObserver.observe(this.controlEl,{attributes:!0,attributeFilter:["disabled","required","readonly","maxlength","minlength"]})}setDisabledSideEffect(e){this.elementInternals.ariaDisabled=`${e}`,this.controlEl&&(this.controlEl.disabled=e),this.labelSlottedNodes?.length&&this.labelSlottedNodes.forEach(t=>t.disabled=this.disabled)}toggleUserValidityState(){v(this.elementInternals,"user-invalid",!this.validity.valid),v(this.elementInternals,"user-valid",this.validity.valid)}maybeCreateAutoSizerEl(){if(!CSS.supports("field-sizing: content")){if(!this.autoResize){this.autoSizerEl?.remove(),this.autoSizerObserver?.disconnect();return}this.autoSizerEl||(this.autoSizerEl=document.createElement("div"),this.autoSizerEl.classList.add("auto-sizer"),this.autoSizerEl.ariaHidden="true"),this.shadowRoot.prepend(this.autoSizerEl),this.autoSizerObserver||(this.autoSizerObserver=new ResizeObserver((e,t)=>{const i=window.getComputedStyle(this).writingMode.startsWith("horizontal")?"height":"width";this.style.getPropertyValue(i)!==""&&(this.autoSizerEl?.remove(),t.disconnect())})),this.autoSizerObserver.observe(this)}}handleControlInput(){this.autoResize&&this.autoSizerEl&&(this.autoSizerEl.textContent=this.value+" "),this.setFormValue(this.value),this.setValidity()}handleControlChange(){this.toggleUserValidityState(),this.$emit("change")}handleControlSelect(){this.$emit("select")}}se.formAssociated=!0,J([$],se.prototype,"defaultSlottedNodes",2),J([$],se.prototype,"labelSlottedNodes",2),J([a],se.prototype,"autocomplete",2),J([a({attribute:"auto-resize",mode:"boolean"})],se.prototype,"autoResize",2),J([a({attribute:"dirname"})],se.prototype,"dirName",2),J([a({mode:"boolean"})],se.prototype,"disabled",2),J([a({attribute:"display-shadow",mode:"boolean"})],se.prototype,"displayShadow",2),J([a({attribute:"form"})],se.prototype,"initialForm",2),J([a({attribute:"maxlength",converter:ae})],se.prototype,"maxLength",2),J([a({attribute:"minlength",converter:ae})],se.prototype,"minLength",2),J([a],se.prototype,"name",2),J([a],se.prototype,"placeholder",2),J([a({attribute:"readonly",mode:"boolean"})],se.prototype,"readOnly",2),J([a({mode:"boolean"})],se.prototype,"required",2),J([a({mode:"fromView"})],se.prototype,"resize",2),J([a({mode:"boolean"})],se.prototype,"spellcheck",2);class as extends se{constructor(){super(...arguments),this.appearance=ei.outline,this.block=!1}labelSlottedNodesChanged(){super.labelSlottedNodesChanged(),this.labelSlottedNodes.forEach(e=>{e.size=this.size})}appearanceChanged(e,t){v(this.elementInternals,e,!1),Fs(ei,t)?v(this.elementInternals,t,!0):this.appearance=ei.outline}blockChanged(){v(this.elementInternals,"block",this.block)}sizeChanged(e,t){y(this.elementInternals,e,t,Im)}handleChange(e,t){switch(t){case"size":this.labelSlottedNodes.forEach(i=>{i.size=this.size});break;case"appearance":case"displayShadow":this.maybeDisplayShadow();break}}connectedCallback(){super.connectedCallback(),this.maybeDisplayShadow(),f.getNotifier(this).subscribe(this,"appearance"),f.getNotifier(this).subscribe(this,"displayShadow"),f.getNotifier(this).subscribe(this,"size")}disconnectedCallback(){super.disconnectedCallback(),f.getNotifier(this).unsubscribe(this,"appearance"),f.getNotifier(this).unsubscribe(this,"displayShadow"),f.getNotifier(this).unsubscribe(this,"size")}maybeDisplayShadow(){v(this.elementInternals,"display-shadow",this.displayShadow&&zm.includes(this.appearance))}}J([a({mode:"fromView"})],as.prototype,"appearance",2),J([a({mode:"boolean"})],as.prototype,"block",2),J([a],as.prototype,"size",2);const Bm=p`
534
+ :host{--tabPaddingInline:inherit;--tabPaddingBlock:inherit;--tabIndicatorInsetInline:0;--tabIndicatorInsetBlock:0;box-sizing:border-box;color:${Le};flex-direction:row}:host(${z}){flex-direction:column}:host ::slotted([role='tab']){align-items:flex-start}:host ::slotted([slot='tab'][data-animate='true'])::after{transition-property:transform;transition-duration:${fa};transition-timing-function:${or}}:host ::slotted([slot='tab'])::after{height:${ge};margin-block-start:auto;transform-origin:left;transform:translateX(var(--tabIndicatorOffset)) scaleX(var(--tabIndicatorScale))}:host(${z}) ::slotted([slot='tab'])::after{width:${ge};height:unset;margin-block-start:unset;transform-origin:top;transform:translateY(var(--tabIndicatorOffset)) scaleY(var(--tabIndicatorScale))}:host ::slotted([slot='tab'])::before{height:${ge};border-radius:${Se};content:'';inset-inline:var(--tabIndicatorInsetInline);inset-block:var(--tabIndicatorInsetBlock);position:absolute;margin-top:auto}:host ::slotted([slot='tab'])::before{inset-inline:var(--tabIndicatorInsetInline);inset-block:var(--tabIndicatorInsetBlock)}:host ::slotted([slot='tab'][aria-selected='true'])::before{background-color:${A}}:host ::slotted([slot='tab'][aria-selected='false']:hover)::after{height:${ge};margin-block-start:auto;transform-origin:left}:host(${z}) ::slotted([slot='tab'])::before,:host(${z}) ::slotted([slot='tab'][aria-selected='false']:hover)::after{height:unset;width:${ge};margin-inline-end:auto;transform-origin:top}:host(:where(${P},${C})) ::slotted([slot='tab']){padding-inline:var(--tabPaddingInline);padding-block:var(--tabPaddingBlock)}:host(${P}) ::slotted([slot='tab']){--tabPaddingBlock:${et};--tabPaddingInline:${de};font-size:${M};line-height:${j}}:host(${C}) ::slotted([slot='tab']){--tabPaddingBlock:${ji};--tabPaddingInline:${fe};font-size:${ke};line-height:${Ie}}:host ::slotted([slot='tab'])::after,:host ::slotted([slot='tab'])::before,:host ::slotted([slot='tab']:hover)::after{inset-inline:var(--tabIndicatorInsetInline)}:host ::slotted([slot='tab']){--tabIndicatorInsetInline:${fe}}:host(${P}) ::slotted([slot='tab']){--tabIndicatorInsetInline:${de}}:host(${C}) ::slotted([slot='tab']){--tabIndicatorInsetInline:${fe}}:host(${z}) ::slotted([slot='tab']){padding-block:var(--tabPaddingBlock)}:host(${z}) ::slotted([slot='tab']){--tabPaddingBlock:${oe}}:host(${z}${P}) ::slotted([slot='tab']){--tabPaddingBlock:${Vo}}:host(${z}${C}) ::slotted([slot='tab']){--tabPaddingBlock:${oe}}:host(${z}) ::slotted([slot='tab'])::after,:host(${z}) ::slotted([slot='tab'])::before,:host(${z}) ::slotted([slot='tab']:hover)::after{inset-inline:0;inset-block:var(--tabIndicatorInsetBlock)}:host(${z}){--tabIndicatorInsetBlock:${oe}}:host(${z}${P}){--tabIndicatorInsetBlock:${et}}:host(${z}${C}){--tabIndicatorInsetBlock:${uo}}:host(${_}){cursor:not-allowed;color:${A}}:host(${_}) ::slotted([slot='tab']){pointer-events:none;cursor:not-allowed;color:${A}}:host(${_}) ::slotted([slot='tab']:after){background-color:${A}}:host(${_}) ::slotted([slot='tab'][aria-selected='true'])::after{background-color:${A}}:host(${_}) ::slotted([slot='tab']:hover):before{content:unset}:host(${B}) ::slotted([slot='tab']:hover){background-color:${_i};color:${Ds};fill:${Mn}}:host(${B}) ::slotted([slot='tab']:active){background-color:${ro};fill:${ro};color:${O}}`,Cm=mr.compose({name:`${b.prefix}-tablist`,template:xm,styles:wm});Cm.define(b.registry);const Sm={small:"small",medium:"medium",large:"large"},ei={outline:"outline",filledLighter:"filled-lighter",filledDarker:"filled-darker"},Im=[ei.filledLighter,ei.filledDarker],ns={none:"none",both:"both",horizontal:"horizontal",vertical:"vertical"};var zm=Object.defineProperty,Pm=Object.getOwnPropertyDescriptor,J=(o,e,t,i)=>{for(var s=i>1?void 0:i?Pm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&zm(e,t,s),s};class se extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.userInteracted=!1,this.preConnectControlEl=document.createElement("textarea"),this.autoResize=!1,this.disabled=!1,this.displayShadow=!1,this.readOnly=!1,this.required=!1,this.resize=ns.none,this.spellcheck=!1}defaultSlottedNodesChanged(){const e=this.getContent();this.defaultValue=e,this.value=e}labelSlottedNodesChanged(){this.labelEl&&(this.labelEl.hidden=!this.labelSlottedNodes.length),this.labelSlottedNodes.forEach(e=>{e.disabled=this.disabled,e.required=this.required})}autoResizeChanged(){this.maybeCreateAutoSizerEl(),v(this.elementInternals,"auto-resize",this.autoResize)}disabledChanged(){this.setDisabledSideEffect(this.disabled)}get form(){return this.elementInternals.form}get labels(){return this.elementInternals.labels}readOnlyChanged(){this.elementInternals.ariaReadOnly=`${!!this.readOnly}`}requiredChanged(){this.elementInternals.ariaRequired=`${!!this.required}`,this.labelSlottedNodes?.length&&this.labelSlottedNodes.forEach(e=>e.required=this.required)}resizeChanged(e,t){y(this.elementInternals,e,t,ns,"resize-"),v(this.elementInternals,"resize",Fs(ns,t)&&t!==ns.none)}get textLength(){return this.controlEl.textLength}get type(){return"textarea"}get validity(){return this.elementInternals.validity}get validationMessage(){return this.elementInternals.validationMessage||this.controlEl.validationMessage}get willValidate(){return this.elementInternals.willValidate}get defaultValue(){return this.controlEl?.defaultValue??this.preConnectControlEl.defaultValue}set defaultValue(e){const t=this.controlEl??this.preConnectControlEl;t.defaultValue=e,this.controlEl&&!this.userInteracted&&(this.controlEl.value=e)}get value(){return this.controlEl?.value??this.preConnectControlEl.value}set value(e){const t=this.controlEl??this.preConnectControlEl;t.value=e,this.setFormValue(e),this.setValidity()}connectedCallback(){super.connectedCallback(),this.setDefaultValue(),this.maybeCreateAutoSizerEl(),this.bindEvents(),this.observeControlElAttrs()}disconnectedCallback(){super.disconnectedCallback(),this.autoSizerObserver?.disconnect(),this.controlElAttrObserver?.disconnect()}formResetCallback(){this.value=this.defaultValue}formDisabledCallback(e){this.setDisabledSideEffect(e),this.setValidity()}setFormValue(e,t){this.elementInternals.setFormValue(e,e??t)}checkValidity(){return this.elementInternals.checkValidity()}reportValidity(){return this.elementInternals.reportValidity()}setCustomValidity(e){this.elementInternals.setValidity({customError:!!e},e?e.toString():void 0),this.reportValidity()}setValidity(e,t,i){this.$fastController.isConnected&&(this.disabled||this.readOnly?this.elementInternals.setValidity({}):this.elementInternals.setValidity(e??this.controlEl.validity,t??this.controlEl.validationMessage,i??this.controlEl),this.userInteracted&&this.toggleUserValidityState())}select(){this.controlEl.select()}setDefaultValue(){this.defaultValue=this.innerHTML.trim()||this.preConnectControlEl.defaultValue||"",this.value=this.preConnectControlEl.value||this.defaultValue,this.setFormValue(this.value),this.setValidity(),this.preConnectControlEl=null}bindEvents(){this.controlEl.addEventListener("input",()=>this.userInteracted=!0,{once:!0})}getContent(){return this.defaultSlottedNodes.map(e=>{switch(e.nodeType){case Node.ELEMENT_NODE:return e.outerHTML;case Node.TEXT_NODE:return e.textContent.trim();default:return""}}).join("")||""}observeControlElAttrs(){this.controlElAttrObserver=new MutationObserver(()=>{this.setValidity()}),this.controlElAttrObserver.observe(this.controlEl,{attributes:!0,attributeFilter:["disabled","required","readonly","maxlength","minlength"]})}setDisabledSideEffect(e){this.elementInternals.ariaDisabled=`${e}`,this.controlEl&&(this.controlEl.disabled=e),this.labelSlottedNodes?.length&&this.labelSlottedNodes.forEach(t=>t.disabled=this.disabled)}toggleUserValidityState(){v(this.elementInternals,"user-invalid",!this.validity.valid),v(this.elementInternals,"user-valid",this.validity.valid)}maybeCreateAutoSizerEl(){if(!CSS.supports("field-sizing: content")){if(!this.autoResize){this.autoSizerEl?.remove(),this.autoSizerObserver?.disconnect();return}this.autoSizerEl||(this.autoSizerEl=document.createElement("div"),this.autoSizerEl.classList.add("auto-sizer"),this.autoSizerEl.ariaHidden="true"),this.shadowRoot.prepend(this.autoSizerEl),this.autoSizerObserver||(this.autoSizerObserver=new ResizeObserver((e,t)=>{const i=window.getComputedStyle(this).writingMode.startsWith("horizontal")?"height":"width";this.style.getPropertyValue(i)!==""&&(this.autoSizerEl?.remove(),t.disconnect())})),this.autoSizerObserver.observe(this)}}handleControlInput(){this.autoResize&&this.autoSizerEl&&(this.autoSizerEl.textContent=this.value+" "),this.setFormValue(this.value),this.setValidity()}handleControlChange(){this.toggleUserValidityState(),this.$emit("change")}handleControlSelect(){this.$emit("select")}}se.formAssociated=!0,J([$],se.prototype,"defaultSlottedNodes",2),J([$],se.prototype,"labelSlottedNodes",2),J([a],se.prototype,"autocomplete",2),J([a({attribute:"auto-resize",mode:"boolean"})],se.prototype,"autoResize",2),J([a({attribute:"dirname"})],se.prototype,"dirName",2),J([a({mode:"boolean"})],se.prototype,"disabled",2),J([a({attribute:"display-shadow",mode:"boolean"})],se.prototype,"displayShadow",2),J([a({attribute:"form"})],se.prototype,"initialForm",2),J([a({attribute:"maxlength",converter:ae})],se.prototype,"maxLength",2),J([a({attribute:"minlength",converter:ae})],se.prototype,"minLength",2),J([a],se.prototype,"name",2),J([a],se.prototype,"placeholder",2),J([a({attribute:"readonly",mode:"boolean"})],se.prototype,"readOnly",2),J([a({mode:"boolean"})],se.prototype,"required",2),J([a({mode:"fromView"})],se.prototype,"resize",2),J([a({mode:"boolean"})],se.prototype,"spellcheck",2);class as extends se{constructor(){super(...arguments),this.appearance=ei.outline,this.block=!1}labelSlottedNodesChanged(){super.labelSlottedNodesChanged(),this.labelSlottedNodes.forEach(e=>{e.size=this.size})}appearanceChanged(e,t){v(this.elementInternals,e,!1),Fs(ei,t)?v(this.elementInternals,t,!0):this.appearance=ei.outline}blockChanged(){v(this.elementInternals,"block",this.block)}sizeChanged(e,t){y(this.elementInternals,e,t,Sm)}handleChange(e,t){switch(t){case"size":this.labelSlottedNodes.forEach(i=>{i.size=this.size});break;case"appearance":case"displayShadow":this.maybeDisplayShadow();break}}connectedCallback(){super.connectedCallback(),this.maybeDisplayShadow(),f.getNotifier(this).subscribe(this,"appearance"),f.getNotifier(this).subscribe(this,"displayShadow"),f.getNotifier(this).subscribe(this,"size")}disconnectedCallback(){super.disconnectedCallback(),f.getNotifier(this).unsubscribe(this,"appearance"),f.getNotifier(this).unsubscribe(this,"displayShadow"),f.getNotifier(this).unsubscribe(this,"size")}maybeDisplayShadow(){v(this.elementInternals,"display-shadow",this.displayShadow&&Im.includes(this.appearance))}}J([a({mode:"fromView"})],as.prototype,"appearance",2),J([a({mode:"boolean"})],as.prototype,"block",2),J([a],as.prototype,"size",2);const Tm=p`
535
535
  ${I("inline-block")}
536
536
 
537
537
  :host{--font-size:${M};--line-height:${j};--padding-inline:${fe};--padding-block:${et};--min-block-size:52px;--block-size:var(--min-block-size);--inline-size:18rem;--border-width:${N};--control-padding-inline:${te};--color:${O};--background-color:${E};--border-color:${Ze};--border-block-end-color:${Qe};--placeholder-color:${Ls};--focus-indicator-color:${Rt};--box-shadow:none;--contain-size:size;--resize:none;color:var(--color);font-family:${k};font-size:var(--font-size);font-weight:${R};line-height:var(--line-height);position:relative}:host(:hover){--border-color:${lo};--border-block-end-color:${Vt}}:host(:active){--border-color:${Mo};--border-block-end-color:${Ht}}:host(:focus-within){outline:none}:host(${zo}:not([hidden])){display:block}:host(${P}){--font-size:${G};--line-height:${ee};--min-block-size:40px;--padding-block:${ho};--padding-inline:${de};--control-padding-inline:${te}}:host(${C}){--font-size:${ke};--line-height:${Ie};--min-block-size:64px;--padding-block:${oe};--padding-inline:${xe};--control-padding-inline:${de}}:host(${Wc}:not(:disabled)){--resize:both}:host(${Gc}:not(:disabled)){--resize:horizontal}:host(${Uc}:not(:disabled)){--resize:vertical}:host(${Tn}){--block-size:auto;--contain-size:inline-size}:host(${$t}){--background-color:${_o};--border-color:var(--background-color);--border-block-end-color:var(--border-color)}:host(${Ot}){--border-color:var(--background-color);--border-block-end-color:var(--border-color)}:host(${$t}${Bn}),:host(${Ot}${Bn}){--box-shadow:${Ys}}:host(${ud}){--border-color:${Xs};--border-block-end-color:${Xs}}:host(:disabled){--color:${A};--background-color:${Be};--border-color:${Ae};--border-block-end-color:var(--border-color);--box-shadow:none;--placeholder-color:${A};cursor:no-drop;user-select:none}.root{background-color:var(--background-color);border:var(--border-width) solid var(--border-color);border-block-end-color:var(--border-block-end-color);border-radius:${T};box-sizing:border-box;box-shadow:var(--box-shadow);contain:paint layout style var(--contain-size);display:grid;grid-template:1fr / 1fr;inline-size:var(--inline-size);min-block-size:var(--min-block-size);block-size:var(--block-size);overflow:hidden;padding:var(--padding-block) var(--padding-inline);position:relative;resize:var(--resize)}:host(${zo}) .root{inline-size:auto}.root::after{border-bottom:2px solid var(--focus-indicator-color);border-radius:0 0 ${T} ${T};box-sizing:border-box;clip-path:inset(calc(100% - 2px) 1px 0px);content:'';height:max(2px,${T});inset:auto -1px 0;position:absolute;transform:scaleX(0);transition-delay:${jt};transition-duration:${Js};transition-property:transform}:host(:focus-within) .root::after{transform:scaleX(1);transition-property:transform;transition-duration:${qi};transition-delay:${qt}}:host([readonly]) .root::after,:host(:disabled) .root::after{content:none}label{color:var(--color);display:flex;inline-size:fit-content;padding-block-end:${ho};padding-inline-end:${Ee}}:host(:empty) label,label[hidden]{display:none}.auto-sizer,.control{box-sizing:border-box;font:inherit;grid-column:1 / -1;grid-row:1 / -1;letter-space:inherit;padding:0 var(--control-padding-inline)}.auto-sizer{display:none;padding-block-end:2px;pointer-events:none;visibility:hidden;white-space:pre-wrap}:host(${Tn}) .auto-sizer{display:block}.control{appearance:none;background-color:transparent;border:0;color:inherit;field-sizing:content;max-block-size:100%;outline:0;resize:none;text-align:inherit}.control:disabled{cursor:inherit}.control::placeholder{color:var(--placeholder-color)}::selection{color:${Dt};background-color:${Vn}}`.withBehaviors(le(p`
538
- :host{--border-color:FieldText;--border-block-end-color:FieldText;--focus-indicator-color:Highlight;--placeholder-color:FieldText}:host(:hover),:host(:active),:host(:focus-within){--border-color:Highlight;--border-block-end-color:Highlight}:host(:disabled){--color:GrayText;--border-color:GrayText;--border-block-end-color:GrayText;--placeholder-color:GrayText}`));function Am(){return g`<template><label ${X("labelEl")} for="control" part="label"><slot name="label" ${K({property:"labelSlottedNodes",filter:Es})}></slot></label><div class="root" part="root"><textarea ${X("controlEl")} id="control" class="control" part="control" ?required="${o=>o.required}" ?disabled="${o=>o.disabled}" ?readonly="${o=>o.readOnly}" ?spellcheck="${o=>o.spellcheck}" autocomplete="${o=>o.autocomplete}" maxlength="${o=>o.maxLength}" minlength="${o=>o.minLength}" placeholder="${o=>o.placeholder}" @change="${o=>o.handleControlChange()}" @select="${o=>o.handleControlSelect()}" @input="${o=>o.handleControlInput()}"></textarea></div><div hidden><slot ${K({property:"defaultSlottedNodes",filter:Es})}></slot></div></template>`}const Em=Am(),Om=as.compose({name:`${b.prefix}-textarea`,template:Em,styles:Bm,shadowOptions:{delegatesFocus:!0}});Om.define(b.registry);const Fm={small:"small",medium:"medium",large:"large"},Nm={outline:"outline",underline:"underline",filledLighter:"filled-lighter",filledDarker:"filled-darker"},_m={email:"email",password:"password",tel:"tel",text:"text",url:"url"},Mm=["date","datetime-local","email","month","number","password","search","tel","text","time","url","week"];var Dm=Object.defineProperty,Lm=Object.getOwnPropertyDescriptor,L=(o,e,t,i)=>{for(var s=i>1?void 0:i?Lm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Dm(e,t,s),s};class V extends w{constructor(){super(...arguments),this.type=_m.text,this.dirtyValue=!1,this.elementInternals=this.attachInternals()}currentValueChanged(e,t){this.value=t}defaultSlottedNodesChanged(e,t){this.$fastController.isConnected&&(this.controlLabel.hidden=!t?.length)}initialValueChanged(){this.dirtyValue||(this.value=this.initialValue)}readOnlyChanged(){this.$fastController.isConnected&&(this.elementInternals.ariaReadOnly=`${!!this.readOnly}`)}requiredChanged(e,t){this.$fastController.isConnected&&(this.elementInternals.ariaRequired=`${!!t}`)}get validity(){return this.elementInternals.validity}get validationMessage(){return this.elementInternals.validationMessage||this.control.validationMessage}get value(){return f.track(this,"value"),this.currentValue}set value(e){this.currentValue=e,this.$fastController.isConnected&&(this.control.value=e??"",this.setFormValue(e),this.setValidity(),f.notify(this,"value"))}get willValidate(){return this.elementInternals.willValidate}get form(){return this.elementInternals.form}beforeinputHandler(e){return e.inputType==="insertLineBreak"&&this.implicitSubmit(),!0}changeHandler(e){return this.setValidity(),this.$emit("change",e,{bubbles:!0,composed:!0}),!0}checkValidity(){return this.elementInternals.checkValidity()}clickHandler(e){return e.target===this&&this.control?.click(),!0}connectedCallback(){super.connectedCallback(),this.setFormValue(this.value),this.setValidity()}focusinHandler(e){return e.target===this&&this.control?.focus(),!0}formResetCallback(){this.value=this.initialValue,this.dirtyValue=!1}implicitSubmit(){if(!this.elementInternals.form)return;if(this.elementInternals.form.elements.length===1){this.elementInternals.form.requestSubmit();return}const e=[...this.elementInternals.form.elements],t=e.find(s=>s.getAttribute("type")==="submit");if(t){t.click();return}e.filter(s=>Mm.includes(s.getAttribute("type")??"")).length>1||this.elementInternals.form.requestSubmit()}inputHandler(e){return this.dirtyValue=!0,this.value=this.control.value,!0}keydownHandler(e){return e.key==="Enter"&&this.implicitSubmit(),!0}select(){this.control.select(),this.$emit("select")}setCustomValidity(e){this.elementInternals.setValidity({customError:!0},e),this.reportValidity()}reportValidity(){return this.elementInternals.reportValidity()}setFormValue(e,t){this.elementInternals.setFormValue(e,e??t)}setValidity(e=this.control.validity,t=this.validationMessage,i=this.control){if(this.$fastController.isConnected){if(this.disabled){this.elementInternals.setValidity({});return}this.elementInternals.setValidity(e,t,i)}}}V.formAssociated=!0,L([a],V.prototype,"autocomplete",2),L([a({mode:"boolean"})],V.prototype,"autofocus",2),L([a({attribute:"current-value"})],V.prototype,"currentValue",2),L([$],V.prototype,"defaultSlottedNodes",2),L([a],V.prototype,"dirname",2),L([a({mode:"boolean"})],V.prototype,"disabled",2),L([a({attribute:"form"})],V.prototype,"formAttribute",2),L([a({attribute:"value",mode:"fromView"})],V.prototype,"initialValue",2),L([a],V.prototype,"list",2),L([a({converter:ae})],V.prototype,"maxlength",2),L([a({converter:ae})],V.prototype,"minlength",2),L([a({mode:"boolean"})],V.prototype,"multiple",2),L([a],V.prototype,"name",2),L([a],V.prototype,"pattern",2),L([a],V.prototype,"placeholder",2),L([a({attribute:"readonly",mode:"boolean"})],V.prototype,"readOnly",2),L([a({mode:"boolean"})],V.prototype,"required",2),L([a({converter:ae})],V.prototype,"size",2),L([a({converter:{fromView:o=>typeof o=="string"?["true",""].includes(o.trim().toLowerCase()):null,toView:o=>o.toString()}})],V.prototype,"spellcheck",2),L([a],V.prototype,"type",2),L([$],V.prototype,"controlLabel",2);class ls extends V{appearanceChanged(e,t){y(this.elementInternals,e,t,Nm)}controlSizeChanged(e,t){y(this.elementInternals,e,t,Fm)}}L([a],ls.prototype,"appearance",2),L([a({attribute:"control-size"})],ls.prototype,"controlSize",2),nt(ls,rt);const Vm=p`
538
+ :host{--border-color:FieldText;--border-block-end-color:FieldText;--focus-indicator-color:Highlight;--placeholder-color:FieldText}:host(:hover),:host(:active),:host(:focus-within){--border-color:Highlight;--border-block-end-color:Highlight}:host(:disabled){--color:GrayText;--border-color:GrayText;--border-block-end-color:GrayText;--placeholder-color:GrayText}`));function Bm(){return g`<template><label ${X("labelEl")} for="control" part="label"><slot name="label" ${K({property:"labelSlottedNodes",filter:Es})}></slot></label><div class="root" part="root"><textarea ${X("controlEl")} id="control" class="control" part="control" ?required="${o=>o.required}" ?disabled="${o=>o.disabled}" ?readonly="${o=>o.readOnly}" ?spellcheck="${o=>o.spellcheck}" autocomplete="${o=>o.autocomplete}" maxlength="${o=>o.maxLength}" minlength="${o=>o.minLength}" placeholder="${o=>o.placeholder}" @change="${o=>o.handleControlChange()}" @select="${o=>o.handleControlSelect()}" @input="${o=>o.handleControlInput()}"></textarea></div><div hidden><slot ${K({property:"defaultSlottedNodes",filter:Es})}></slot></div></template>`}const Am=Bm(),Em=as.compose({name:`${b.prefix}-textarea`,template:Am,styles:Tm,shadowOptions:{delegatesFocus:!0}});Em.define(b.registry);const Om={small:"small",medium:"medium",large:"large"},Fm={outline:"outline",underline:"underline",filledLighter:"filled-lighter",filledDarker:"filled-darker"},Nm={email:"email",password:"password",tel:"tel",text:"text",url:"url"},_m=["date","datetime-local","email","month","number","password","search","tel","text","time","url","week"];var Mm=Object.defineProperty,Dm=Object.getOwnPropertyDescriptor,L=(o,e,t,i)=>{for(var s=i>1?void 0:i?Dm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Mm(e,t,s),s};class V extends w{constructor(){super(...arguments),this.type=Nm.text,this.dirtyValue=!1,this.elementInternals=this.attachInternals()}currentValueChanged(e,t){this.value=t}defaultSlottedNodesChanged(e,t){this.$fastController.isConnected&&(this.controlLabel.hidden=!t?.length)}initialValueChanged(){this.dirtyValue||(this.value=this.initialValue)}readOnlyChanged(){this.$fastController.isConnected&&(this.elementInternals.ariaReadOnly=`${!!this.readOnly}`)}requiredChanged(e,t){this.$fastController.isConnected&&(this.elementInternals.ariaRequired=`${!!t}`)}get validity(){return this.elementInternals.validity}get validationMessage(){return this.elementInternals.validationMessage||this.control.validationMessage}get value(){return f.track(this,"value"),this.currentValue}set value(e){this.currentValue=e,this.$fastController.isConnected&&(this.control.value=e??"",this.setFormValue(e),this.setValidity(),f.notify(this,"value"))}get willValidate(){return this.elementInternals.willValidate}get form(){return this.elementInternals.form}beforeinputHandler(e){return e.inputType==="insertLineBreak"&&this.implicitSubmit(),!0}changeHandler(e){return this.setValidity(),this.$emit("change",e,{bubbles:!0,composed:!0}),!0}checkValidity(){return this.elementInternals.checkValidity()}clickHandler(e){return e.target===this&&this.control?.click(),!0}connectedCallback(){super.connectedCallback(),this.setFormValue(this.value),this.setValidity()}focusinHandler(e){return e.target===this&&this.control?.focus(),!0}formResetCallback(){this.value=this.initialValue,this.dirtyValue=!1}implicitSubmit(){if(!this.elementInternals.form)return;if(this.elementInternals.form.elements.length===1){this.elementInternals.form.requestSubmit();return}const e=[...this.elementInternals.form.elements],t=e.find(s=>s.getAttribute("type")==="submit");if(t){t.click();return}e.filter(s=>_m.includes(s.getAttribute("type")??"")).length>1||this.elementInternals.form.requestSubmit()}inputHandler(e){return this.dirtyValue=!0,this.value=this.control.value,!0}keydownHandler(e){return e.key==="Enter"&&this.implicitSubmit(),!0}select(){this.control.select(),this.$emit("select")}setCustomValidity(e){this.elementInternals.setValidity({customError:!0},e),this.reportValidity()}reportValidity(){return this.elementInternals.reportValidity()}setFormValue(e,t){this.elementInternals.setFormValue(e,e??t)}setValidity(e=this.control.validity,t=this.validationMessage,i=this.control){if(this.$fastController.isConnected){if(this.disabled){this.elementInternals.setValidity({});return}this.elementInternals.setValidity(e,t,i)}}}V.formAssociated=!0,L([a],V.prototype,"autocomplete",2),L([a({mode:"boolean"})],V.prototype,"autofocus",2),L([a({attribute:"current-value"})],V.prototype,"currentValue",2),L([$],V.prototype,"defaultSlottedNodes",2),L([a],V.prototype,"dirname",2),L([a({mode:"boolean"})],V.prototype,"disabled",2),L([a({attribute:"form"})],V.prototype,"formAttribute",2),L([a({attribute:"value",mode:"fromView"})],V.prototype,"initialValue",2),L([a],V.prototype,"list",2),L([a({converter:ae})],V.prototype,"maxlength",2),L([a({converter:ae})],V.prototype,"minlength",2),L([a({mode:"boolean"})],V.prototype,"multiple",2),L([a],V.prototype,"name",2),L([a],V.prototype,"pattern",2),L([a],V.prototype,"placeholder",2),L([a({attribute:"readonly",mode:"boolean"})],V.prototype,"readOnly",2),L([a({mode:"boolean"})],V.prototype,"required",2),L([a({converter:ae})],V.prototype,"size",2),L([a({converter:{fromView:o=>typeof o=="string"?["true",""].includes(o.trim().toLowerCase()):null,toView:o=>o.toString()}})],V.prototype,"spellcheck",2),L([a],V.prototype,"type",2),L([$],V.prototype,"controlLabel",2);class ls extends V{appearanceChanged(e,t){y(this.elementInternals,e,t,Fm)}controlSizeChanged(e,t){y(this.elementInternals,e,t,Om)}}L([a],ls.prototype,"appearance",2),L([a({attribute:"control-size"})],ls.prototype,"controlSize",2),nt(ls,rt);const Lm=p`
539
539
  ${I("block")}
540
540
 
541
- :host{font-family:${k};font-size:${M};font-weight:${R};line-height:${j};max-width:400px}.label{display:flex;color:${O};padding-bottom:${ho};flex-shrink:0;padding-inline-end:${Ee}}.label[hidden],:host(:empty) .label{display:none}.root{align-items:center;background-color:${E};border:${N} solid ${Ze};border-bottom-color:${Qe};border-radius:${T};box-sizing:border-box;height:32px;display:inline-flex;flex-direction:row;gap:${te};padding:0 ${fe};position:relative;width:100%}:has(.control:user-invalid){border-color:${Xs}}.root::after{box-sizing:border-box;content:'';position:absolute;left:-1px;bottom:0px;right:-1px;height:max(2px,${T});border-radius:0 0 ${T} ${T};border-bottom:2px solid ${Rt};clip-path:inset(calc(100% - 2px) 1px 0px);transform:scaleX(0);transition-property:transform;transition-duration:${Js};transition-delay:${jt}}.control{width:100%;height:100%;box-sizing:border-box;color:${O};border-radius:${T};background:${Be};font-family:${k};font-weight:${R};font-size:${M};border:none;vertical-align:center}.control:focus-visible{outline:0;border:0}.control::placeholder{color:${Ls}}:host ::slotted([slot='start']),:host ::slotted([slot='end']){display:flex;align-items:center;justify-content:center;color:${be};font-size:${co}}:host ::slotted([slot='start']){padding-right:${te}}:host ::slotted([slot='end']){padding-left:${te};gap:${Ee}}:host(:hover) .root{border-color:${lo};border-bottom-color:${Vt}}:host(:active) .root{border-color:${Mo}}:host(:focus-within) .root{outline:transparent solid 2px;border-bottom:0}:host(:focus-within) .root::after{transform:scaleX(1);transition-property:transform;transition-duration:${qi};transition-delay:${qt}}:host(:focus-within:active) .root:after{border-bottom-color:${Wn}}:host(${F}:focus-within) .root{border:${N} solid ${Ze}}:host(:focus-within) .control{color:${O}}:host([disabled]) .root{background:${Be};border:${N} solid ${Ae}}:host([disabled]) .control::placeholder,:host([disabled]) ::slotted([slot='start']),:host([disabled]) ::slotted([slot='end']){color:${A}}::selection{color:${Dt};background-color:${Vn}}:host(${P}) .control{font-size:${G};font-weight:${R};line-height:${ee}}:host(${P}) .root{height:24px;gap:${te};padding:0 ${de}}:host(${P}) ::slotted([slot='start']),:host(${P}) ::slotted([slot='end']){font-size:${ke}}:host(${C}) .control{font-size:${ke};font-weight:${R};line-height:${Ie}}:host(${C}) .root{height:40px;gap:${Je};padding:0 ${xe}}:host(${C}) ::slotted([slot='start']),:host(${C}) ::slotted([slot='end']){font-size:${Di}}:host(${_t}) .root{background:${Be};border:0;border-radius:0;border-bottom:${N} solid ${Qe}}:host(${_t}:hover) .root{border-bottom-color:${Vt}}:host(${_t}:active) .root{border-bottom-color:${Ht}}:host(${_t}:focus-within) .root{border:0;border-bottom-color:${Ht}}:host(${_t}[disabled]) .root{border-bottom-color:${Ae}}:host(${Ot}) .root,:host(${$t}) .root{border:${N} solid ${ce};box-shadow:${Ys}}:host(${Ot}) .root{background:${E}}:host(${$t}) .root{background:${_o}}:host(${Ot}:hover) .root,:host(${$t}:hover) .root{border-color:${Gs}}:host(${Ot}:active) .root,:host(${$t}:active) .root{border-color:${Gs};background:${_o}}`;function Hm(o={}){return g`<template @beforeinput="${(e,t)=>e.beforeinputHandler(t.event)}" @focusin="${(e,t)=>e.focusinHandler(t.event)}" @keydown="${(e,t)=>e.keydownHandler(t.event)}"><label part="label" for="control" class="label" ${X("controlLabel")}><slot ${K({property:"defaultSlottedNodes",filter:Es})}></slot></label><div class="root" part="root">${Ke(o)}<input class="control" part="control" id="control" @change="${(e,t)=>e.changeHandler(t.event)}" @input="${(e,t)=>e.inputHandler(t.event)}" ?autofocus="${e=>e.autofocus}" autocomplete="${e=>e.autocomplete}" ?disabled="${e=>e.disabled}" list="${e=>e.list}" maxlength="${e=>e.maxlength}" minlength="${e=>e.minlength}" ?multiple="${e=>e.multiple}" name="${e=>e.name}" pattern="${e=>e.pattern}" placeholder="${e=>e.placeholder}" ?readonly="${e=>e.readOnly}" ?required="${e=>e.required}" size="${e=>e.size}" spellcheck="${e=>e.spellcheck}" type="${e=>e.type}" value="${e=>e.initialValue}" ${X("control")} />${mt(o)}</div></template>`}const Rm=Hm(),jm=ls.compose({name:`${b.prefix}-text-input`,template:Rm,styles:Vm,shadowOptions:{delegatesFocus:!0}});jm.define(b.registry);const qm={_100:"100",_200:"200",_300:"300",_400:"400",_500:"500",_600:"600",_700:"700",_800:"800",_900:"900",_1000:"1000"},Wm={base:"base",numeric:"numeric",monospace:"monospace"},Gm={medium:"medium",regular:"regular",semibold:"semibold",bold:"bold"},Um={start:"start",end:"end",center:"center",justify:"justify"};var Xm=Object.defineProperty,Km=Object.getOwnPropertyDescriptor,st=(o,e,t,i)=>{for(var s=i>1?void 0:i?Km(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Xm(e,t,s),s};class qe extends w{constructor(){super(...arguments),this.elementInternals=this.attachInternals(),this.nowrap=!1,this.truncate=!1,this.italic=!1,this.underline=!1,this.strikethrough=!1,this.block=!1}sizeChanged(e,t){y(this.elementInternals,e,t,qm,"size-")}fontChanged(e,t){y(this.elementInternals,e,t,Wm)}weightChanged(e,t){y(this.elementInternals,e,t,Gm)}alignChanged(e,t){y(this.elementInternals,e,t,Um)}connectedCallback(){super.connectedCallback(),f.getNotifier(this).subscribe(this),Object.keys(this.$fastController.definition.attributeLookup).forEach(e=>{this.handleChange(this,e)})}disconnectedCallback(){super.disconnectedCallback(),f.getNotifier(this).unsubscribe(this)}handleChange(e,t){switch(t){case"nowrap":case"truncate":case"italic":case"underline":case"strikethrough":case"block":v(this.elementInternals,t,!!this[t]);break}}}st([a({mode:"boolean"})],qe.prototype,"nowrap",2),st([a({mode:"boolean"})],qe.prototype,"truncate",2),st([a({mode:"boolean"})],qe.prototype,"italic",2),st([a({mode:"boolean"})],qe.prototype,"underline",2),st([a({mode:"boolean"})],qe.prototype,"strikethrough",2),st([a({mode:"boolean"})],qe.prototype,"block",2),st([a],qe.prototype,"size",2),st([a],qe.prototype,"font",2),st([a],qe.prototype,"weight",2),st([a],qe.prototype,"align",2);const Ym=p`
541
+ :host{font-family:${k};font-size:${M};font-weight:${R};line-height:${j};max-width:400px}.label{display:flex;color:${O};padding-bottom:${ho};flex-shrink:0;padding-inline-end:${Ee}}.label[hidden],:host(:empty) .label{display:none}.root{align-items:center;background-color:${E};border:${N} solid ${Ze};border-bottom-color:${Qe};border-radius:${T};box-sizing:border-box;height:32px;display:inline-flex;flex-direction:row;gap:${te};padding:0 ${fe};position:relative;width:100%}:has(.control:user-invalid){border-color:${Xs}}.root::after{box-sizing:border-box;content:'';position:absolute;left:-1px;bottom:0px;right:-1px;height:max(2px,${T});border-radius:0 0 ${T} ${T};border-bottom:2px solid ${Rt};clip-path:inset(calc(100% - 2px) 1px 0px);transform:scaleX(0);transition-property:transform;transition-duration:${Js};transition-delay:${jt}}.control{width:100%;height:100%;box-sizing:border-box;color:${O};border-radius:${T};background:${Be};font-family:${k};font-weight:${R};font-size:${M};border:none;vertical-align:center}.control:focus-visible{outline:0;border:0}.control::placeholder{color:${Ls}}:host ::slotted([slot='start']),:host ::slotted([slot='end']){display:flex;align-items:center;justify-content:center;color:${be};font-size:${co}}:host ::slotted([slot='start']){padding-right:${te}}:host ::slotted([slot='end']){padding-left:${te};gap:${Ee}}:host(:hover) .root{border-color:${lo};border-bottom-color:${Vt}}:host(:active) .root{border-color:${Mo}}:host(:focus-within) .root{outline:transparent solid 2px;border-bottom:0}:host(:focus-within) .root::after{transform:scaleX(1);transition-property:transform;transition-duration:${qi};transition-delay:${qt}}:host(:focus-within:active) .root:after{border-bottom-color:${Wn}}:host(${F}:focus-within) .root{border:${N} solid ${Ze}}:host(:focus-within) .control{color:${O}}:host([disabled]) .root{background:${Be};border:${N} solid ${Ae}}:host([disabled]) .control::placeholder,:host([disabled]) ::slotted([slot='start']),:host([disabled]) ::slotted([slot='end']){color:${A}}::selection{color:${Dt};background-color:${Vn}}:host(${P}) .control{font-size:${G};font-weight:${R};line-height:${ee}}:host(${P}) .root{height:24px;gap:${te};padding:0 ${de}}:host(${P}) ::slotted([slot='start']),:host(${P}) ::slotted([slot='end']){font-size:${ke}}:host(${C}) .control{font-size:${ke};font-weight:${R};line-height:${Ie}}:host(${C}) .root{height:40px;gap:${Je};padding:0 ${xe}}:host(${C}) ::slotted([slot='start']),:host(${C}) ::slotted([slot='end']){font-size:${Di}}:host(${_t}) .root{background:${Be};border:0;border-radius:0;border-bottom:${N} solid ${Qe}}:host(${_t}:hover) .root{border-bottom-color:${Vt}}:host(${_t}:active) .root{border-bottom-color:${Ht}}:host(${_t}:focus-within) .root{border:0;border-bottom-color:${Ht}}:host(${_t}[disabled]) .root{border-bottom-color:${Ae}}:host(${Ot}) .root,:host(${$t}) .root{border:${N} solid ${ce};box-shadow:${Ys}}:host(${Ot}) .root{background:${E}}:host(${$t}) .root{background:${_o}}:host(${Ot}:hover) .root,:host(${$t}:hover) .root{border-color:${Gs}}:host(${Ot}:active) .root,:host(${$t}:active) .root{border-color:${Gs};background:${_o}}`;function Vm(o={}){return g`<template @beforeinput="${(e,t)=>e.beforeinputHandler(t.event)}" @focusin="${(e,t)=>e.focusinHandler(t.event)}" @keydown="${(e,t)=>e.keydownHandler(t.event)}"><label part="label" for="control" class="label" ${X("controlLabel")}><slot ${K({property:"defaultSlottedNodes",filter:Es})}></slot></label><div class="root" part="root">${Ke(o)}<input class="control" part="control" id="control" @change="${(e,t)=>e.changeHandler(t.event)}" @input="${(e,t)=>e.inputHandler(t.event)}" ?autofocus="${e=>e.autofocus}" autocomplete="${e=>e.autocomplete}" ?disabled="${e=>e.disabled}" list="${e=>e.list}" maxlength="${e=>e.maxlength}" minlength="${e=>e.minlength}" ?multiple="${e=>e.multiple}" name="${e=>e.name}" pattern="${e=>e.pattern}" placeholder="${e=>e.placeholder}" ?readonly="${e=>e.readOnly}" ?required="${e=>e.required}" size="${e=>e.size}" spellcheck="${e=>e.spellcheck}" type="${e=>e.type}" value="${e=>e.initialValue}" ${X("control")} />${mt(o)}</div></template>`}const Hm=Vm(),Rm=ls.compose({name:`${b.prefix}-text-input`,template:Hm,styles:Lm,shadowOptions:{delegatesFocus:!0}});Rm.define(b.registry);const jm={_100:"100",_200:"200",_300:"300",_400:"400",_500:"500",_600:"600",_700:"700",_800:"800",_900:"900",_1000:"1000"},qm={base:"base",numeric:"numeric",monospace:"monospace"},Wm={medium:"medium",regular:"regular",semibold:"semibold",bold:"bold"},Gm={start:"start",end:"end",center:"center",justify:"justify"};var Um=Object.defineProperty,Xm=Object.getOwnPropertyDescriptor,st=(o,e,t,i)=>{for(var s=i>1?void 0:i?Xm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Um(e,t,s),s};class qe extends w{constructor(){super(...arguments),this.elementInternals=this.attachInternals(),this.nowrap=!1,this.truncate=!1,this.italic=!1,this.underline=!1,this.strikethrough=!1,this.block=!1}sizeChanged(e,t){y(this.elementInternals,e,t,jm,"size-")}fontChanged(e,t){y(this.elementInternals,e,t,qm)}weightChanged(e,t){y(this.elementInternals,e,t,Wm)}alignChanged(e,t){y(this.elementInternals,e,t,Gm)}connectedCallback(){super.connectedCallback(),f.getNotifier(this).subscribe(this),Object.keys(this.$fastController.definition.attributeLookup).forEach(e=>{this.handleChange(this,e)})}disconnectedCallback(){super.disconnectedCallback(),f.getNotifier(this).unsubscribe(this)}handleChange(e,t){switch(t){case"nowrap":case"truncate":case"italic":case"underline":case"strikethrough":case"block":v(this.elementInternals,t,!!this[t]);break}}}st([a({mode:"boolean"})],qe.prototype,"nowrap",2),st([a({mode:"boolean"})],qe.prototype,"truncate",2),st([a({mode:"boolean"})],qe.prototype,"italic",2),st([a({mode:"boolean"})],qe.prototype,"underline",2),st([a({mode:"boolean"})],qe.prototype,"strikethrough",2),st([a({mode:"boolean"})],qe.prototype,"block",2),st([a],qe.prototype,"size",2),st([a],qe.prototype,"font",2),st([a],qe.prototype,"weight",2),st([a],qe.prototype,"align",2);const Km=p`
542
542
  ${I("inline")}
543
543
 
544
- :host{contain:content;font-family:${k};font-size:${M};line-height:${j};font-weight:${R};text-align:start}:host(${On}),:host(${On}) ::slotted(*){white-space:nowrap;overflow:hidden}:host(${_n}),:host(${_n}) ::slotted(*){text-overflow:ellipsis}:host(${zo}){display:block}:host(${kc}){font-style:italic}:host(${_t}){text-decoration-line:underline}:host(${Nn}){text-decoration-line:line-through}:host(${_t}${Nn}){text-decoration-line:line-through underline}:host(${Zc}){font-size:${Lo};line-height:${Vi}}:host(${Jc}){font-size:${G};line-height:${ee}}:host(${ed}){font-size:${ke};line-height:${Ie}}:host(${td}){font-size:${co};line-height:${Hi}}:host(${od}){font-size:${Di};line-height:${da}}:host(${id}){font-size:${na};line-height:${ha}}:host(${sd}){font-size:${aa};line-height:${ua}}:host(${rd}){font-size:${la};line-height:${pa}}:host(${Qc}){font-size:${ca};line-height:${ba}}:host(${Bc}){font-family:${su}}:host(${Ec}){font-family:${ru}}:host(${Pc}){font-weight:${nu}}:host(${Fn}){font-weight:${U}}:host(${Ql}){font-weight:${Li}}:host(${tc}){text-align:center}:host(${lc}){text-align:end}:host(${xc}){text-align:justify}::slotted(*){font:inherit;line-height:inherit;text-decoration-line:inherit;text-align:inherit;text-decoration-line:inherit;margin:0}`,Qm=g`<slot></slot>`,Zm=qe.compose({name:`${b.prefix}-text`,template:Qm,styles:Ym});Zm.define(b.registry);var Jm=Object.defineProperty,e$=Object.getOwnPropertyDescriptor,Ua=(o,e,t,i)=>{for(var s=i>1?void 0:i?e$(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Jm(e,t,s),s};class $r extends ut{pressedChanged(){this.setPressedState()}mixedChanged(){this.setPressedState()}press(){this.pressed=!this.pressed}connectedCallback(){super.connectedCallback(),this.setPressedState()}setPressedState(){if(this.$fastController.isConnected){const e=`${this.mixed?"mixed":!!this.pressed}`;this.elementInternals.ariaPressed=e,v(this.elementInternals,"pressed",!!this.pressed||!!this.mixed)}}}Ua([a({mode:"boolean"})],$r.prototype,"pressed",2),Ua([a({mode:"boolean"})],$r.prototype,"mixed",2);const t$=p`
544
+ :host{contain:content;font-family:${k};font-size:${M};line-height:${j};font-weight:${R};text-align:start}:host(${On}),:host(${On}) ::slotted(*){white-space:nowrap;overflow:hidden}:host(${_n}),:host(${_n}) ::slotted(*){text-overflow:ellipsis}:host(${zo}){display:block}:host(${kc}){font-style:italic}:host(${_t}){text-decoration-line:underline}:host(${Nn}){text-decoration-line:line-through}:host(${_t}${Nn}){text-decoration-line:line-through underline}:host(${Zc}){font-size:${Lo};line-height:${Vi}}:host(${Jc}){font-size:${G};line-height:${ee}}:host(${ed}){font-size:${ke};line-height:${Ie}}:host(${td}){font-size:${co};line-height:${Hi}}:host(${od}){font-size:${Di};line-height:${da}}:host(${id}){font-size:${na};line-height:${ha}}:host(${sd}){font-size:${aa};line-height:${ua}}:host(${rd}){font-size:${la};line-height:${pa}}:host(${Qc}){font-size:${ca};line-height:${ba}}:host(${Bc}){font-family:${su}}:host(${Ec}){font-family:${ru}}:host(${Pc}){font-weight:${nu}}:host(${Fn}){font-weight:${U}}:host(${Ql}){font-weight:${Li}}:host(${tc}){text-align:center}:host(${lc}){text-align:end}:host(${xc}){text-align:justify}::slotted(*){font:inherit;line-height:inherit;text-decoration-line:inherit;text-align:inherit;text-decoration-line:inherit;margin:0}`,Ym=g`<slot></slot>`,Qm=qe.compose({name:`${b.prefix}-text`,template:Ym,styles:Km});Qm.define(b.registry);var Zm=Object.defineProperty,Jm=Object.getOwnPropertyDescriptor,Ua=(o,e,t,i)=>{for(var s=i>1?void 0:i?Jm(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&Zm(e,t,s),s};class $r extends ut{pressedChanged(){this.setPressedState()}mixedChanged(){this.setPressedState()}press(){this.pressed=!this.pressed}connectedCallback(){super.connectedCallback(),this.setPressedState()}setPressedState(){if(this.$fastController.isConnected){const e=`${this.mixed?"mixed":!!this.pressed}`;this.elementInternals.ariaPressed=e,v(this.elementInternals,"pressed",!!this.pressed||!!this.mixed)}}}Ua([a({mode:"boolean"})],$r.prototype,"pressed",2),Ua([a({mode:"boolean"})],$r.prototype,"mixed",2);const e$=p`
545
545
  ${Xi}
546
546
 
547
547
  :host(${D}){border-color:${Ze};background-color:${Ln};color:${O};border-width:${N}}:host(${D}:hover){border-color:${lo};background-color:${Oi}}:host(${D}:active){border-color:${Mo};background-color:${Fi}}:host(${D}${ye}){border-color:transparent;background-color:${_d};color:${ht}}:host(${D}${ye}:hover){background-color:${Hn}}:host(${D}${ye}:active){background-color:${Rn}}:host(${D}${B}){border-color:transparent;background-color:${Fd};color:${fd}}:host(${D}${B}:hover){background-color:${_i};color:${Fo}}:host(${D}${B}:active){background-color:${ro};color:${No}}:host(${D}${F}),:host(${D}${H}){background-color:${Nd}}:host(${D}${F}:hover),:host(${D}${H}:hover){background-color:${Hs}}:host(${D}${F}:active),:host(${D}${H}:active){background-color:${Rs}}:host(${D}${H}){border-color:transparent;color:${md}}:host(${D}${H}:hover){color:${Ai}}:host(${D}${H}:active){color:${Ei}}`.withBehaviors(le(p`
548
- :host(${D}),:host(${D}${ye}),:host(${D}${B}),:host(${D}${F}),:host(${D}${H}){background:SelectedItem;color:SelectedItemText}`)),o$=nr(),i$=$r.compose({name:`${b.prefix}-toggle-button`,template:o$,styles:t$});i$.define(b.registry);var s$=Object.defineProperty,r$=Object.getOwnPropertyDescriptor,cs=(o,e,t,i)=>{for(var s=i>1?void 0:i?r$(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&s$(e,t,s),s};class ti extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.id=io("tooltip-"),this.defaultDelay=250,this.anchor="",this.anchorPositioningStyleElement=null,this.mouseenterAnchorHandler=()=>this.showTooltip(this.delay),this.mouseleaveAnchorHandler=()=>this.hideTooltip(this.delay),this.focusAnchorHandler=()=>this.showTooltip(0),this.blurAnchorHandler=()=>this.hideTooltip(0),this.elementInternals.role="tooltip"}positioningChanged(){Sn||this.setFallbackStyles()}get anchorElement(){const e=this.getRootNode();return(e instanceof ShadowRoot?e:document).getElementById(this.anchor??"")}connectedCallback(){if(super.connectedCallback(),!this.anchorElement)return;const e=this.anchorElement.style.anchorName||`--${this.anchor}`,t=this.anchorElement.getAttribute("aria-describedby");if(this.anchorElement.setAttribute("aria-describedby",t?`${t} ${this.id}`:this.id),this.anchorElement.addEventListener("focus",this.focusAnchorHandler),this.anchorElement.addEventListener("blur",this.blurAnchorHandler),this.anchorElement.addEventListener("mouseenter",this.mouseenterAnchorHandler),this.anchorElement.addEventListener("mouseleave",this.mouseleaveAnchorHandler),Sn){Hl||(this.anchorElement.style.anchorName=e,this.style.positionAnchor=e);return}ne.enqueue(()=>this.setFallbackStyles())}disconnectedCallback(){super.disconnectedCallback(),this.anchorElement?.removeEventListener("focus",this.focusAnchorHandler),this.anchorElement?.removeEventListener("blur",this.blurAnchorHandler),this.anchorElement?.removeEventListener("mouseenter",this.mouseenterAnchorHandler),this.anchorElement?.removeEventListener("mouseleave",this.mouseleaveAnchorHandler)}showTooltip(e=this.defaultDelay){setTimeout(()=>{this.setAttribute("aria-hidden","false"),this.showPopover()},e)}hideTooltip(e=this.defaultDelay){setTimeout(()=>{if(this.matches(":hover")||this.anchorElement?.matches(":hover")){this.hideTooltip(e);return}this.setAttribute("aria-hidden","true"),this.hidePopover()},e)}setFallbackStyles(){if(!this.anchorElement)return;const e=this.anchorElement.style.anchorName||`--${this.anchor}`;this.anchorPositioningStyleElement||(this.anchorPositioningStyleElement=document.createElement("style"),document.head.append(this.anchorPositioningStyleElement));let[t,i]=this.positioning?.split("-")??[];i||((t==="above"||t==="below")&&(i="centerX"),(t==="before"||t==="after")&&(i="centerY"));const s={above:"bottom: anchor(top);",below:"top: anchor(bottom);",before:"right: anchor(left);",after:"left: anchor(right);"},r=s[t]??s.above,n={start:"left: anchor(left);",end:"right: anchor(right);",top:"top: anchor(top);",bottom:"bottom: anchor(bottom);",centerX:"left: anchor(center); translate: -50% 0;",centerY:"top: anchor(center); translate: 0 -50%;"},d=n[i]??n.centerX;this.anchorPositioningStyleElement.textContent=`
548
+ :host(${D}),:host(${D}${ye}),:host(${D}${B}),:host(${D}${F}),:host(${D}${H}){background:SelectedItem;color:SelectedItemText}`)),t$=nr(),o$=$r.compose({name:`${b.prefix}-toggle-button`,template:t$,styles:e$});o$.define(b.registry);var i$=Object.defineProperty,s$=Object.getOwnPropertyDescriptor,cs=(o,e,t,i)=>{for(var s=i>1?void 0:i?s$(e,t):e,r=o.length-1,n;r>=0;r--)(n=o[r])&&(s=(i?n(e,t,s):n(s))||s);return i&&s&&i$(e,t,s),s};class ti extends w{constructor(){super(),this.elementInternals=this.attachInternals(),this.id=io("tooltip-"),this.defaultDelay=250,this.anchor="",this.anchorPositioningStyleElement=null,this.mouseenterAnchorHandler=()=>this.showTooltip(this.delay),this.mouseleaveAnchorHandler=()=>this.hideTooltip(this.delay),this.focusAnchorHandler=()=>this.showTooltip(0),this.blurAnchorHandler=()=>this.hideTooltip(0),this.elementInternals.role="tooltip"}positioningChanged(){Sn||this.setFallbackStyles()}get anchorElement(){const e=this.getRootNode();return(e instanceof ShadowRoot?e:document).getElementById(this.anchor??"")}connectedCallback(){if(super.connectedCallback(),!this.anchorElement)return;const e=this.anchorElement.style.anchorName||`--${this.anchor}`,t=this.anchorElement.getAttribute("aria-describedby");if(this.anchorElement.setAttribute("aria-describedby",t?`${t} ${this.id}`:this.id),this.anchorElement.addEventListener("focus",this.focusAnchorHandler),this.anchorElement.addEventListener("blur",this.blurAnchorHandler),this.anchorElement.addEventListener("mouseenter",this.mouseenterAnchorHandler),this.anchorElement.addEventListener("mouseleave",this.mouseleaveAnchorHandler),Sn){Hl||(this.anchorElement.style.anchorName=e,this.style.positionAnchor=e);return}ne.enqueue(()=>this.setFallbackStyles())}disconnectedCallback(){super.disconnectedCallback(),this.anchorElement?.removeEventListener("focus",this.focusAnchorHandler),this.anchorElement?.removeEventListener("blur",this.blurAnchorHandler),this.anchorElement?.removeEventListener("mouseenter",this.mouseenterAnchorHandler),this.anchorElement?.removeEventListener("mouseleave",this.mouseleaveAnchorHandler)}showTooltip(e=this.defaultDelay){setTimeout(()=>{this.setAttribute("aria-hidden","false"),this.showPopover()},e)}hideTooltip(e=this.defaultDelay){setTimeout(()=>{if(this.matches(":hover")||this.anchorElement?.matches(":hover")){this.hideTooltip(e);return}this.setAttribute("aria-hidden","true"),this.hidePopover()},e)}setFallbackStyles(){if(!this.anchorElement)return;const e=this.anchorElement.style.anchorName||`--${this.anchor}`;this.anchorPositioningStyleElement||(this.anchorPositioningStyleElement=document.createElement("style"),document.head.append(this.anchorPositioningStyleElement));let[t,i]=this.positioning?.split("-")??[];i||((t==="above"||t==="below")&&(i="centerX"),(t==="before"||t==="after")&&(i="centerY"));const s={above:"bottom: anchor(top);",below:"top: anchor(bottom);",before:"right: anchor(left);",after:"left: anchor(right);"},r=s[t]??s.above,n={start:"left: anchor(left);",end:"right: anchor(right);",top:"top: anchor(top);",bottom:"bottom: anchor(bottom);",centerX:"left: anchor(center); translate: -50% 0;",centerY:"top: anchor(center); translate: 0 -50%;"},d=n[i]??n.centerX;this.anchorPositioningStyleElement.textContent=`
549
549
  #${this.anchor} {
550
550
  anchor-name: ${e};
551
551
  }
@@ -556,7 +556,7 @@ const b=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElem
556
556
  ${r}
557
557
  ${d}
558
558
  }
559
- `,window.CSS_ANCHOR_POLYFILL&&window.CSS_ANCHOR_POLYFILL.call({element:this.anchorPositioningStyleElement})}}cs([a],ti.prototype,"id",2),cs([a({converter:ae})],ti.prototype,"delay",2),cs([a],ti.prototype,"positioning",2),cs([a],ti.prototype,"anchor",2);const _e={"above-start":"block-start span-inline-end",above:"block-start","above-end":"block-start span-inline-start","below-start":"block-end span-inline-end",below:"block-end","below-end":"block-end span-inline-start","before-top":"inline-start span-block-end",before:"inline-start","before-bottom":"inline-start span-block-start","after-top":"inline-end span-block-end",after:"inline-end","after-bottom":"inline-end span-block-start"},n$=p`
559
+ `,window.CSS_ANCHOR_POLYFILL&&window.CSS_ANCHOR_POLYFILL.call({element:this.anchorPositioningStyleElement})}}cs([a],ti.prototype,"id",2),cs([a({converter:ae})],ti.prototype,"delay",2),cs([a],ti.prototype,"positioning",2),cs([a],ti.prototype,"anchor",2);const _e={"above-start":"block-start span-inline-end",above:"block-start","above-end":"block-start span-inline-start","below-start":"block-end span-inline-end",below:"block-end","below-end":"block-end span-inline-start","before-top":"inline-start span-block-end",before:"inline-start","before-bottom":"inline-start span-block-start","after-top":"inline-end span-block-end",after:"inline-end","after-bottom":"inline-end span-block-start"},r$=p`
560
560
  ${I("inline-flex")}
561
561
 
562
- :host(:not(:popover-open)){display:none}:host{--position-area:block-start;--position-try-options:flip-block;--block-offset:${ho};--inline-offset:${Ee};background:${E};border-radius:${T};border:1px solid ${ce};box-sizing:border-box;color:${O};display:inline-flex;filter:drop-shadow(0 0 2px ${Hd}) drop-shadow(0 4px 8px ${Rd});font-family:${k};font-size:${G};inset:unset;line-height:${ee};margin:unset;max-width:240px;overflow:visible;padding:4px ${fe} 6px;position:absolute;position-area:var(--position-area);position-try-options:var(--position-try-options);width:auto;z-index:1}@supports (inset-area:block-start){:host{inset-area:var(--position-area);position-try-fallbacks:var(--position-try-options)}}:host(:is([positioning^='above'],[positioning^='below'],:not([positioning]))){margin-block:var(--block-offset)}:host(:is([positioning^='before'],[positioning^='after'])){margin-inline:var(--inline-offset);--position-try-options:flip-inline}:host([positioning='above-start']){--position-area:${_e["above-start"]}}:host([positioning='above']){--position-area:${_e.above}}:host([positioning='above-end']){--position-area:${_e["above-end"]}}:host([positioning='below-start']){--position-area:${_e["below-start"]}}:host([positioning='below']){--position-area:${_e.below}}:host([positioning='below-end']){--position-area:${_e["below-end"]}}:host([positioning='before-top']){--position-area:${_e["before-top"]}}:host([positioning='before']){--position-area:${_e.before}}:host([positioning='before-bottom']){--position-area:${_e["before-bottom"]}}:host([positioning='after-top']){--position-area:${_e["after-top"]}}:host([positioning='after']){--position-area:${_e.after}}:host([positioning='after-bottom']){--position-area:${_e["after-bottom"]}}`,a$=g`<template popover aria-hidden="true"><slot></slot></template>`,l$=ti.compose({name:`${b.prefix}-tooltip`,template:a$,styles:n$});l$.define(b.registry);
562
+ :host(:not(:popover-open)){display:none}:host{--position-area:block-start;--position-try-options:flip-block;--block-offset:${ho};--inline-offset:${Ee};background:${E};border-radius:${T};border:1px solid ${ce};box-sizing:border-box;color:${O};display:inline-flex;filter:drop-shadow(0 0 2px ${Hd}) drop-shadow(0 4px 8px ${Rd});font-family:${k};font-size:${G};inset:unset;line-height:${ee};margin:unset;max-width:240px;overflow:visible;padding:4px ${fe} 6px;position:absolute;position-area:var(--position-area);position-try-options:var(--position-try-options);width:auto;z-index:1}@supports (inset-area:block-start){:host{inset-area:var(--position-area);position-try-fallbacks:var(--position-try-options)}}:host(:is([positioning^='above'],[positioning^='below'],:not([positioning]))){margin-block:var(--block-offset)}:host(:is([positioning^='before'],[positioning^='after'])){margin-inline:var(--inline-offset);--position-try-options:flip-inline}:host([positioning='above-start']){--position-area:${_e["above-start"]}}:host([positioning='above']){--position-area:${_e.above}}:host([positioning='above-end']){--position-area:${_e["above-end"]}}:host([positioning='below-start']){--position-area:${_e["below-start"]}}:host([positioning='below']){--position-area:${_e.below}}:host([positioning='below-end']){--position-area:${_e["below-end"]}}:host([positioning='before-top']){--position-area:${_e["before-top"]}}:host([positioning='before']){--position-area:${_e.before}}:host([positioning='before-bottom']){--position-area:${_e["before-bottom"]}}:host([positioning='after-top']){--position-area:${_e["after-top"]}}:host([positioning='after']){--position-area:${_e.after}}:host([positioning='after-bottom']){--position-area:${_e["after-bottom"]}}`,n$=g`<template popover aria-hidden="true"><slot></slot></template>`,a$=ti.compose({name:`${b.prefix}-tooltip`,template:n$,styles:r$});a$.define(b.registry);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@fluentui/web-components",
3
3
  "description": "A library of Fluent Web Components",
4
- "version": "3.0.0-beta.78",
4
+ "version": "3.0.0-beta.79",
5
5
  "author": {
6
6
  "name": "Microsoft",
7
7
  "url": "https://discord.gg/FcSNfg4"