@duyluonganduin/acl-web-components 0.0.78 → 0.0.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.
@@ -6,17 +6,17 @@
6
6
  * @license
7
7
  * Copyright 2017 Google LLC
8
8
  * SPDX-License-Identifier: BSD-3-Clause
9
- */const{is:t0,defineProperty:i0,getOwnPropertyDescriptor:o0,getOwnPropertyNames:n0,getOwnPropertySymbols:s0,getPrototypeOf:r0}=Object,ce=globalThis,Tl=ce.trustedTypes,l0=Tl?Tl.emptyScript:"",g2=ce.reactiveElementPolyfillSupport,Wt=(n,e)=>n,Wi={toAttribute(n,e){switch(e){case Boolean:n=n?l0:null;break;case Object:case Array:n=n==null?n:JSON.stringify(n)}return n},fromAttribute(n,e){let t=n;switch(e){case Boolean:t=n!==null;break;case Number:t=n===null?null:Number(n);break;case Object:case Array:try{t=JSON.parse(n)}catch{t=null}}return t}},r5=(n,e)=>!t0(n,e),Dl={attribute:!0,type:String,converter:Wi,reflect:!1,useDefault:!1,hasChanged:r5};Symbol.metadata??(Symbol.metadata=Symbol("metadata")),ce.litPropertyMetadata??(ce.litPropertyMetadata=new WeakMap);let it=class extends HTMLElement{static addInitializer(e){this._$Ei(),(this.l??(this.l=[])).push(e)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(e,t=Dl){if(t.state&&(t.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(e)&&((t=Object.create(t)).wrapped=!0),this.elementProperties.set(e,t),!t.noAccessor){const o=Symbol(),i=this.getPropertyDescriptor(e,o,t);i!==void 0&&i0(this.prototype,e,i)}}static getPropertyDescriptor(e,t,o){const{get:i,set:s}=o0(this.prototype,e)??{get(){return this[t]},set(r){this[t]=r}};return{get:i,set(r){const a=i==null?void 0:i.call(this);s==null||s.call(this,r),this.requestUpdate(e,a,o)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){return this.elementProperties.get(e)??Dl}static _$Ei(){if(this.hasOwnProperty(Wt("elementProperties")))return;const e=r0(this);e.finalize(),e.l!==void 0&&(this.l=[...e.l]),this.elementProperties=new Map(e.elementProperties)}static finalize(){if(this.hasOwnProperty(Wt("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(Wt("properties"))){const t=this.properties,o=[...n0(t),...s0(t)];for(const i of o)this.createProperty(i,t[i])}const e=this[Symbol.metadata];if(e!==null){const t=litPropertyMetadata.get(e);if(t!==void 0)for(const[o,i]of t)this.elementProperties.set(o,i)}this._$Eh=new Map;for(const[t,o]of this.elementProperties){const i=this._$Eu(t,o);i!==void 0&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(e){const t=[];if(Array.isArray(e)){const o=new Set(e.flat(1/0).reverse());for(const i of o)t.unshift(Ol(i))}else e!==void 0&&t.push(Ol(e));return t}static _$Eu(e,t){const o=t.attribute;return o===!1?void 0:typeof o=="string"?o:typeof e=="string"?e.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var e;this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),(e=this.constructor.l)==null||e.forEach(t=>t(this))}addController(e){var t;(this._$EO??(this._$EO=new Set)).add(e),this.renderRoot!==void 0&&this.isConnected&&((t=e.hostConnected)==null||t.call(e))}removeController(e){var t;(t=this._$EO)==null||t.delete(e)}_$E_(){const e=new Map,t=this.constructor.elementProperties;for(const o of t.keys())this.hasOwnProperty(o)&&(e.set(o,this[o]),delete this[o]);e.size>0&&(this._$Ep=e)}createRenderRoot(){const e=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return e0(e,this.constructor.elementStyles),e}connectedCallback(){var e;this.renderRoot??(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(e=this._$EO)==null||e.forEach(t=>{var o;return(o=t.hostConnected)==null?void 0:o.call(t)})}enableUpdating(e){}disconnectedCallback(){var e;(e=this._$EO)==null||e.forEach(t=>{var o;return(o=t.hostDisconnected)==null?void 0:o.call(t)})}attributeChangedCallback(e,t,o){this._$AK(e,o)}_$ET(e,t){var s;const o=this.constructor.elementProperties.get(e),i=this.constructor._$Eu(e,o);if(i!==void 0&&o.reflect===!0){const r=(((s=o.converter)==null?void 0:s.toAttribute)!==void 0?o.converter:Wi).toAttribute(t,o.type);this._$Em=e,r==null?this.removeAttribute(i):this.setAttribute(i,r),this._$Em=null}}_$AK(e,t){var s,r;const o=this.constructor,i=o._$Eh.get(e);if(i!==void 0&&this._$Em!==i){const a=o.getPropertyOptions(i),c=typeof a.converter=="function"?{fromAttribute:a.converter}:((s=a.converter)==null?void 0:s.fromAttribute)!==void 0?a.converter:Wi;this._$Em=i;const u=c.fromAttribute(t,a.type);this[i]=u??((r=this._$Ej)==null?void 0:r.get(i))??u,this._$Em=null}}requestUpdate(e,t,o,i=!1,s){var r;if(e!==void 0){const a=this.constructor;if(i===!1&&(s=this[e]),o??(o=a.getPropertyOptions(e)),!((o.hasChanged??r5)(s,t)||o.useDefault&&o.reflect&&s===((r=this._$Ej)==null?void 0:r.get(e))&&!this.hasAttribute(a._$Eu(e,o))))return;this.C(e,t,o)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(e,t,{useDefault:o,reflect:i,wrapped:s},r){o&&!(this._$Ej??(this._$Ej=new Map)).has(e)&&(this._$Ej.set(e,r??t??this[e]),s!==!0||r!==void 0)||(this._$AL.has(e)||(this.hasUpdated||o||(t=void 0),this._$AL.set(e,t)),i===!0&&this._$Em!==e&&(this._$Eq??(this._$Eq=new Set)).add(e))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}const e=this.scheduleUpdate();return e!=null&&await e,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var o;if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??(this.renderRoot=this.createRenderRoot()),this._$Ep){for(const[s,r]of this._$Ep)this[s]=r;this._$Ep=void 0}const i=this.constructor.elementProperties;if(i.size>0)for(const[s,r]of i){const{wrapped:a}=r,c=this[s];a!==!0||this._$AL.has(s)||c===void 0||this.C(s,void 0,r,c)}}let e=!1;const t=this._$AL;try{e=this.shouldUpdate(t),e?(this.willUpdate(t),(o=this._$EO)==null||o.forEach(i=>{var s;return(s=i.hostUpdate)==null?void 0:s.call(i)}),this.update(t)):this._$EM()}catch(i){throw e=!1,this._$EM(),i}e&&this._$AE(t)}willUpdate(e){}_$AE(e){var t;(t=this._$EO)==null||t.forEach(o=>{var i;return(i=o.hostUpdated)==null?void 0:i.call(o)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(e){return!0}update(e){this._$Eq&&(this._$Eq=this._$Eq.forEach(t=>this._$ET(t,this[t]))),this._$EM()}updated(e){}firstUpdated(e){}};it.elementStyles=[],it.shadowRootOptions={mode:"open"},it[Wt("elementProperties")]=new Map,it[Wt("finalized")]=new Map,g2==null||g2({ReactiveElement:it}),(ce.reactiveElementVersions??(ce.reactiveElementVersions=[])).push("2.1.2");/**
9
+ */const{is:t0,defineProperty:i0,getOwnPropertyDescriptor:o0,getOwnPropertyNames:n0,getOwnPropertySymbols:s0,getPrototypeOf:r0}=Object,ce=globalThis,Tl=ce.trustedTypes,l0=Tl?Tl.emptyScript:"",f2=ce.reactiveElementPolyfillSupport,Wt=(n,e)=>n,Wi={toAttribute(n,e){switch(e){case Boolean:n=n?l0:null;break;case Object:case Array:n=n==null?n:JSON.stringify(n)}return n},fromAttribute(n,e){let t=n;switch(e){case Boolean:t=n!==null;break;case Number:t=n===null?null:Number(n);break;case Object:case Array:try{t=JSON.parse(n)}catch{t=null}}return t}},r5=(n,e)=>!t0(n,e),Dl={attribute:!0,type:String,converter:Wi,reflect:!1,useDefault:!1,hasChanged:r5};Symbol.metadata??(Symbol.metadata=Symbol("metadata")),ce.litPropertyMetadata??(ce.litPropertyMetadata=new WeakMap);let it=class extends HTMLElement{static addInitializer(e){this._$Ei(),(this.l??(this.l=[])).push(e)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(e,t=Dl){if(t.state&&(t.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(e)&&((t=Object.create(t)).wrapped=!0),this.elementProperties.set(e,t),!t.noAccessor){const o=Symbol(),i=this.getPropertyDescriptor(e,o,t);i!==void 0&&i0(this.prototype,e,i)}}static getPropertyDescriptor(e,t,o){const{get:i,set:s}=o0(this.prototype,e)??{get(){return this[t]},set(r){this[t]=r}};return{get:i,set(r){const a=i==null?void 0:i.call(this);s==null||s.call(this,r),this.requestUpdate(e,a,o)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){return this.elementProperties.get(e)??Dl}static _$Ei(){if(this.hasOwnProperty(Wt("elementProperties")))return;const e=r0(this);e.finalize(),e.l!==void 0&&(this.l=[...e.l]),this.elementProperties=new Map(e.elementProperties)}static finalize(){if(this.hasOwnProperty(Wt("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(Wt("properties"))){const t=this.properties,o=[...n0(t),...s0(t)];for(const i of o)this.createProperty(i,t[i])}const e=this[Symbol.metadata];if(e!==null){const t=litPropertyMetadata.get(e);if(t!==void 0)for(const[o,i]of t)this.elementProperties.set(o,i)}this._$Eh=new Map;for(const[t,o]of this.elementProperties){const i=this._$Eu(t,o);i!==void 0&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(e){const t=[];if(Array.isArray(e)){const o=new Set(e.flat(1/0).reverse());for(const i of o)t.unshift(Ol(i))}else e!==void 0&&t.push(Ol(e));return t}static _$Eu(e,t){const o=t.attribute;return o===!1?void 0:typeof o=="string"?o:typeof e=="string"?e.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var e;this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),(e=this.constructor.l)==null||e.forEach(t=>t(this))}addController(e){var t;(this._$EO??(this._$EO=new Set)).add(e),this.renderRoot!==void 0&&this.isConnected&&((t=e.hostConnected)==null||t.call(e))}removeController(e){var t;(t=this._$EO)==null||t.delete(e)}_$E_(){const e=new Map,t=this.constructor.elementProperties;for(const o of t.keys())this.hasOwnProperty(o)&&(e.set(o,this[o]),delete this[o]);e.size>0&&(this._$Ep=e)}createRenderRoot(){const e=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return e0(e,this.constructor.elementStyles),e}connectedCallback(){var e;this.renderRoot??(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(e=this._$EO)==null||e.forEach(t=>{var o;return(o=t.hostConnected)==null?void 0:o.call(t)})}enableUpdating(e){}disconnectedCallback(){var e;(e=this._$EO)==null||e.forEach(t=>{var o;return(o=t.hostDisconnected)==null?void 0:o.call(t)})}attributeChangedCallback(e,t,o){this._$AK(e,o)}_$ET(e,t){var s;const o=this.constructor.elementProperties.get(e),i=this.constructor._$Eu(e,o);if(i!==void 0&&o.reflect===!0){const r=(((s=o.converter)==null?void 0:s.toAttribute)!==void 0?o.converter:Wi).toAttribute(t,o.type);this._$Em=e,r==null?this.removeAttribute(i):this.setAttribute(i,r),this._$Em=null}}_$AK(e,t){var s,r;const o=this.constructor,i=o._$Eh.get(e);if(i!==void 0&&this._$Em!==i){const a=o.getPropertyOptions(i),c=typeof a.converter=="function"?{fromAttribute:a.converter}:((s=a.converter)==null?void 0:s.fromAttribute)!==void 0?a.converter:Wi;this._$Em=i;const u=c.fromAttribute(t,a.type);this[i]=u??((r=this._$Ej)==null?void 0:r.get(i))??u,this._$Em=null}}requestUpdate(e,t,o,i=!1,s){var r;if(e!==void 0){const a=this.constructor;if(i===!1&&(s=this[e]),o??(o=a.getPropertyOptions(e)),!((o.hasChanged??r5)(s,t)||o.useDefault&&o.reflect&&s===((r=this._$Ej)==null?void 0:r.get(e))&&!this.hasAttribute(a._$Eu(e,o))))return;this.C(e,t,o)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(e,t,{useDefault:o,reflect:i,wrapped:s},r){o&&!(this._$Ej??(this._$Ej=new Map)).has(e)&&(this._$Ej.set(e,r??t??this[e]),s!==!0||r!==void 0)||(this._$AL.has(e)||(this.hasUpdated||o||(t=void 0),this._$AL.set(e,t)),i===!0&&this._$Em!==e&&(this._$Eq??(this._$Eq=new Set)).add(e))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}const e=this.scheduleUpdate();return e!=null&&await e,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var o;if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??(this.renderRoot=this.createRenderRoot()),this._$Ep){for(const[s,r]of this._$Ep)this[s]=r;this._$Ep=void 0}const i=this.constructor.elementProperties;if(i.size>0)for(const[s,r]of i){const{wrapped:a}=r,c=this[s];a!==!0||this._$AL.has(s)||c===void 0||this.C(s,void 0,r,c)}}let e=!1;const t=this._$AL;try{e=this.shouldUpdate(t),e?(this.willUpdate(t),(o=this._$EO)==null||o.forEach(i=>{var s;return(s=i.hostUpdate)==null?void 0:s.call(i)}),this.update(t)):this._$EM()}catch(i){throw e=!1,this._$EM(),i}e&&this._$AE(t)}willUpdate(e){}_$AE(e){var t;(t=this._$EO)==null||t.forEach(o=>{var i;return(i=o.hostUpdated)==null?void 0:i.call(o)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(e){return!0}update(e){this._$Eq&&(this._$Eq=this._$Eq.forEach(t=>this._$ET(t,this[t]))),this._$EM()}updated(e){}firstUpdated(e){}};it.elementStyles=[],it.shadowRootOptions={mode:"open"},it[Wt("elementProperties")]=new Map,it[Wt("finalized")]=new Map,f2==null||f2({ReactiveElement:it}),(ce.reactiveElementVersions??(ce.reactiveElementVersions=[])).push("2.1.2");/**
10
10
  * @license
11
11
  * Copyright 2017 Google LLC
12
12
  * SPDX-License-Identifier: BSD-3-Clause
13
13
  */const Yt=globalThis,Pl=n=>n,Yi=Yt.trustedTypes,zl=Yi?Yi.createPolicy("lit-html",{createHTML:n=>n}):void 0,La="$lit$",le=`lit$${Math.random().toFixed(9).slice(2)}$`,ka="?"+le,a0=`<${ka}>`,Te=document,Qt=()=>Te.createComment(""),ei=n=>n===null||typeof n!="object"&&typeof n!="function",l5=Array.isArray,d0=n=>l5(n)||typeof(n==null?void 0:n[Symbol.iterator])=="function",v2=`[
14
14
  \f\r]`,Nt=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Il=/-->/g,Fl=/>/g,Ee=RegExp(`>|${v2}(?:([^\\s"'>=/]+)(${v2}*=${v2}*(?:[^
15
- \f\r"'\`<>=]|("|')|))|$)`,"g"),Bl=/'/g,Nl=/"/g,Va=/^(?:script|style|textarea|title)$/i,Ea=n=>(e,...t)=>({_$litType$:n,strings:e,values:t}),d=Ea(1),ti=Ea(2),p1=Symbol.for("lit-noChange"),g=Symbol.for("lit-nothing"),Ul=new WeakMap,Ze=Te.createTreeWalker(Te,129);function Ma(n,e){if(!l5(n)||!n.hasOwnProperty("raw"))throw Error("invalid template strings array");return zl!==void 0?zl.createHTML(e):e}const c0=(n,e)=>{const t=n.length-1,o=[];let i,s=e===2?"<svg>":e===3?"<math>":"",r=Nt;for(let a=0;a<t;a++){const c=n[a];let u,h,f=-1,m=0;for(;m<c.length&&(r.lastIndex=m,h=r.exec(c),h!==null);)m=r.lastIndex,r===Nt?h[1]==="!--"?r=Il:h[1]!==void 0?r=Fl:h[2]!==void 0?(Va.test(h[2])&&(i=RegExp("</"+h[2],"g")),r=Ee):h[3]!==void 0&&(r=Ee):r===Ee?h[0]===">"?(r=i??Nt,f=-1):h[1]===void 0?f=-2:(f=r.lastIndex-h[2].length,u=h[1],r=h[3]===void 0?Ee:h[3]==='"'?Nl:Bl):r===Nl||r===Bl?r=Ee:r===Il||r===Fl?r=Nt:(r=Ee,i=void 0);const v=r===Ee&&n[a+1].startsWith("/>")?" ":"";s+=r===Nt?c+a0:f>=0?(o.push(u),c.slice(0,f)+La+c.slice(f)+le+v):c+le+(f===-2?a:v)}return[Ma(n,s+(n[t]||"<?>")+(e===2?"</svg>":e===3?"</math>":"")),o]};class ii{constructor({strings:e,_$litType$:t},o){let i;this.parts=[];let s=0,r=0;const a=e.length-1,c=this.parts,[u,h]=c0(e,t);if(this.el=ii.createElement(u,o),Ze.currentNode=this.el.content,t===2||t===3){const f=this.el.content.firstChild;f.replaceWith(...f.childNodes)}for(;(i=Ze.nextNode())!==null&&c.length<a;){if(i.nodeType===1){if(i.hasAttributes())for(const f of i.getAttributeNames())if(f.endsWith(La)){const m=h[r++],v=i.getAttribute(f).split(le),_=/([.?@])?(.*)/.exec(m);c.push({type:1,index:s,name:_[2],strings:v,ctor:_[1]==="."?u0:_[1]==="?"?p0:_[1]==="@"?C0:n2}),i.removeAttribute(f)}else f.startsWith(le)&&(c.push({type:6,index:s}),i.removeAttribute(f));if(Va.test(i.tagName)){const f=i.textContent.split(le),m=f.length-1;if(m>0){i.textContent=Yi?Yi.emptyScript:"";for(let v=0;v<m;v++)i.append(f[v],Qt()),Ze.nextNode(),c.push({type:2,index:++s});i.append(f[m],Qt())}}}else if(i.nodeType===8)if(i.data===ka)c.push({type:2,index:s});else{let f=-1;for(;(f=i.data.indexOf(le,f+1))!==-1;)c.push({type:7,index:s}),f+=le.length-1}s++}}static createElement(e,t){const o=Te.createElement("template");return o.innerHTML=e,o}}function rt(n,e,t=n,o){var r,a;if(e===p1)return e;let i=o!==void 0?(r=t._$Co)==null?void 0:r[o]:t._$Cl;const s=ei(e)?void 0:e._$litDirective$;return(i==null?void 0:i.constructor)!==s&&((a=i==null?void 0:i._$AO)==null||a.call(i,!1),s===void 0?i=void 0:(i=new s(n),i._$AT(n,t,o)),o!==void 0?(t._$Co??(t._$Co=[]))[o]=i:t._$Cl=i),i!==void 0&&(e=rt(n,i._$AS(n,e.values),i,o)),e}class h0{constructor(e,t){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=t}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){const{el:{content:t},parts:o}=this._$AD,i=((e==null?void 0:e.creationScope)??Te).importNode(t,!0);Ze.currentNode=i;let s=Ze.nextNode(),r=0,a=0,c=o[0];for(;c!==void 0;){if(r===c.index){let u;c.type===2?u=new Ti(s,s.nextSibling,this,e):c.type===1?u=new c.ctor(s,c.name,c.strings,this,e):c.type===6&&(u=new f0(s,this,e)),this._$AV.push(u),c=o[++a]}r!==(c==null?void 0:c.index)&&(s=Ze.nextNode(),r++)}return Ze.currentNode=Te,i}p(e){let t=0;for(const o of this._$AV)o!==void 0&&(o.strings!==void 0?(o._$AI(e,o,t),t+=o.strings.length-2):o._$AI(e[t])),t++}}class Ti{get _$AU(){var e;return((e=this._$AM)==null?void 0:e._$AU)??this._$Cv}constructor(e,t,o,i){this.type=2,this._$AH=g,this._$AN=void 0,this._$AA=e,this._$AB=t,this._$AM=o,this.options=i,this._$Cv=(i==null?void 0:i.isConnected)??!0}get parentNode(){let e=this._$AA.parentNode;const t=this._$AM;return t!==void 0&&(e==null?void 0:e.nodeType)===11&&(e=t.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,t=this){e=rt(this,e,t),ei(e)?e===g||e==null||e===""?(this._$AH!==g&&this._$AR(),this._$AH=g):e!==this._$AH&&e!==p1&&this._(e):e._$litType$!==void 0?this.$(e):e.nodeType!==void 0?this.T(e):d0(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==g&&ei(this._$AH)?this._$AA.nextSibling.data=e:this.T(Te.createTextNode(e)),this._$AH=e}$(e){var s;const{values:t,_$litType$:o}=e,i=typeof o=="number"?this._$AC(e):(o.el===void 0&&(o.el=ii.createElement(Ma(o.h,o.h[0]),this.options)),o);if(((s=this._$AH)==null?void 0:s._$AD)===i)this._$AH.p(t);else{const r=new h0(i,this),a=r.u(this.options);r.p(t),this.T(a),this._$AH=r}}_$AC(e){let t=Ul.get(e.strings);return t===void 0&&Ul.set(e.strings,t=new ii(e)),t}k(e){l5(this._$AH)||(this._$AH=[],this._$AR());const t=this._$AH;let o,i=0;for(const s of e)i===t.length?t.push(o=new Ti(this.O(Qt()),this.O(Qt()),this,this.options)):o=t[i],o._$AI(s),i++;i<t.length&&(this._$AR(o&&o._$AB.nextSibling,i),t.length=i)}_$AR(e=this._$AA.nextSibling,t){var o;for((o=this._$AP)==null?void 0:o.call(this,!1,!0,t);e!==this._$AB;){const i=Pl(e).nextSibling;Pl(e).remove(),e=i}}setConnected(e){var t;this._$AM===void 0&&(this._$Cv=e,(t=this._$AP)==null||t.call(this,e))}}class n2{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,t,o,i,s){this.type=1,this._$AH=g,this._$AN=void 0,this.element=e,this.name=t,this._$AM=i,this.options=s,o.length>2||o[0]!==""||o[1]!==""?(this._$AH=Array(o.length-1).fill(new String),this.strings=o):this._$AH=g}_$AI(e,t=this,o,i){const s=this.strings;let r=!1;if(s===void 0)e=rt(this,e,t,0),r=!ei(e)||e!==this._$AH&&e!==p1,r&&(this._$AH=e);else{const a=e;let c,u;for(e=s[0],c=0;c<s.length-1;c++)u=rt(this,a[o+c],t,c),u===p1&&(u=this._$AH[c]),r||(r=!ei(u)||u!==this._$AH[c]),u===g?e=g:e!==g&&(e+=(u??"")+s[c+1]),this._$AH[c]=u}r&&!i&&this.j(e)}j(e){e===g?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,e??"")}}class u0 extends n2{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===g?void 0:e}}class p0 extends n2{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==g)}}class C0 extends n2{constructor(e,t,o,i,s){super(e,t,o,i,s),this.type=5}_$AI(e,t=this){if((e=rt(this,e,t,0)??g)===p1)return;const o=this._$AH,i=e===g&&o!==g||e.capture!==o.capture||e.once!==o.once||e.passive!==o.passive,s=e!==g&&(o===g||i);i&&this.element.removeEventListener(this.name,this,o),s&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){var t;typeof this._$AH=="function"?this._$AH.call(((t=this.options)==null?void 0:t.host)??this.element,e):this._$AH.handleEvent(e)}}class f0{constructor(e,t,o){this.element=e,this.type=6,this._$AN=void 0,this._$AM=t,this.options=o}get _$AU(){return this._$AM._$AU}_$AI(e){rt(this,e)}}const m2=Yt.litHtmlPolyfillSupport;m2==null||m2(ii,Ti),(Yt.litHtmlVersions??(Yt.litHtmlVersions=[])).push("3.3.2");const g0=(n,e,t)=>{const o=(t==null?void 0:t.renderBefore)??e;let i=o._$litPart$;if(i===void 0){const s=(t==null?void 0:t.renderBefore)??null;o._$litPart$=i=new Ti(e.insertBefore(Qt(),s),s,void 0,t??{})}return i._$AI(n),i};/**
15
+ \f\r"'\`<>=]|("|')|))|$)`,"g"),Bl=/'/g,Nl=/"/g,Va=/^(?:script|style|textarea|title)$/i,Ea=n=>(e,...t)=>({_$litType$:n,strings:e,values:t}),d=Ea(1),ti=Ea(2),p1=Symbol.for("lit-noChange"),f=Symbol.for("lit-nothing"),Ul=new WeakMap,Ze=Te.createTreeWalker(Te,129);function Ma(n,e){if(!l5(n)||!n.hasOwnProperty("raw"))throw Error("invalid template strings array");return zl!==void 0?zl.createHTML(e):e}const c0=(n,e)=>{const t=n.length-1,o=[];let i,s=e===2?"<svg>":e===3?"<math>":"",r=Nt;for(let a=0;a<t;a++){const c=n[a];let u,h,g=-1,m=0;for(;m<c.length&&(r.lastIndex=m,h=r.exec(c),h!==null);)m=r.lastIndex,r===Nt?h[1]==="!--"?r=Il:h[1]!==void 0?r=Fl:h[2]!==void 0?(Va.test(h[2])&&(i=RegExp("</"+h[2],"g")),r=Ee):h[3]!==void 0&&(r=Ee):r===Ee?h[0]===">"?(r=i??Nt,g=-1):h[1]===void 0?g=-2:(g=r.lastIndex-h[2].length,u=h[1],r=h[3]===void 0?Ee:h[3]==='"'?Nl:Bl):r===Nl||r===Bl?r=Ee:r===Il||r===Fl?r=Nt:(r=Ee,i=void 0);const v=r===Ee&&n[a+1].startsWith("/>")?" ":"";s+=r===Nt?c+a0:g>=0?(o.push(u),c.slice(0,g)+La+c.slice(g)+le+v):c+le+(g===-2?a:v)}return[Ma(n,s+(n[t]||"<?>")+(e===2?"</svg>":e===3?"</math>":"")),o]};class ii{constructor({strings:e,_$litType$:t},o){let i;this.parts=[];let s=0,r=0;const a=e.length-1,c=this.parts,[u,h]=c0(e,t);if(this.el=ii.createElement(u,o),Ze.currentNode=this.el.content,t===2||t===3){const g=this.el.content.firstChild;g.replaceWith(...g.childNodes)}for(;(i=Ze.nextNode())!==null&&c.length<a;){if(i.nodeType===1){if(i.hasAttributes())for(const g of i.getAttributeNames())if(g.endsWith(La)){const m=h[r++],v=i.getAttribute(g).split(le),_=/([.?@])?(.*)/.exec(m);c.push({type:1,index:s,name:_[2],strings:v,ctor:_[1]==="."?u0:_[1]==="?"?p0:_[1]==="@"?C0:n2}),i.removeAttribute(g)}else g.startsWith(le)&&(c.push({type:6,index:s}),i.removeAttribute(g));if(Va.test(i.tagName)){const g=i.textContent.split(le),m=g.length-1;if(m>0){i.textContent=Yi?Yi.emptyScript:"";for(let v=0;v<m;v++)i.append(g[v],Qt()),Ze.nextNode(),c.push({type:2,index:++s});i.append(g[m],Qt())}}}else if(i.nodeType===8)if(i.data===ka)c.push({type:2,index:s});else{let g=-1;for(;(g=i.data.indexOf(le,g+1))!==-1;)c.push({type:7,index:s}),g+=le.length-1}s++}}static createElement(e,t){const o=Te.createElement("template");return o.innerHTML=e,o}}function rt(n,e,t=n,o){var r,a;if(e===p1)return e;let i=o!==void 0?(r=t._$Co)==null?void 0:r[o]:t._$Cl;const s=ei(e)?void 0:e._$litDirective$;return(i==null?void 0:i.constructor)!==s&&((a=i==null?void 0:i._$AO)==null||a.call(i,!1),s===void 0?i=void 0:(i=new s(n),i._$AT(n,t,o)),o!==void 0?(t._$Co??(t._$Co=[]))[o]=i:t._$Cl=i),i!==void 0&&(e=rt(n,i._$AS(n,e.values),i,o)),e}class h0{constructor(e,t){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=t}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){const{el:{content:t},parts:o}=this._$AD,i=((e==null?void 0:e.creationScope)??Te).importNode(t,!0);Ze.currentNode=i;let s=Ze.nextNode(),r=0,a=0,c=o[0];for(;c!==void 0;){if(r===c.index){let u;c.type===2?u=new Ti(s,s.nextSibling,this,e):c.type===1?u=new c.ctor(s,c.name,c.strings,this,e):c.type===6&&(u=new g0(s,this,e)),this._$AV.push(u),c=o[++a]}r!==(c==null?void 0:c.index)&&(s=Ze.nextNode(),r++)}return Ze.currentNode=Te,i}p(e){let t=0;for(const o of this._$AV)o!==void 0&&(o.strings!==void 0?(o._$AI(e,o,t),t+=o.strings.length-2):o._$AI(e[t])),t++}}class Ti{get _$AU(){var e;return((e=this._$AM)==null?void 0:e._$AU)??this._$Cv}constructor(e,t,o,i){this.type=2,this._$AH=f,this._$AN=void 0,this._$AA=e,this._$AB=t,this._$AM=o,this.options=i,this._$Cv=(i==null?void 0:i.isConnected)??!0}get parentNode(){let e=this._$AA.parentNode;const t=this._$AM;return t!==void 0&&(e==null?void 0:e.nodeType)===11&&(e=t.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,t=this){e=rt(this,e,t),ei(e)?e===f||e==null||e===""?(this._$AH!==f&&this._$AR(),this._$AH=f):e!==this._$AH&&e!==p1&&this._(e):e._$litType$!==void 0?this.$(e):e.nodeType!==void 0?this.T(e):d0(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==f&&ei(this._$AH)?this._$AA.nextSibling.data=e:this.T(Te.createTextNode(e)),this._$AH=e}$(e){var s;const{values:t,_$litType$:o}=e,i=typeof o=="number"?this._$AC(e):(o.el===void 0&&(o.el=ii.createElement(Ma(o.h,o.h[0]),this.options)),o);if(((s=this._$AH)==null?void 0:s._$AD)===i)this._$AH.p(t);else{const r=new h0(i,this),a=r.u(this.options);r.p(t),this.T(a),this._$AH=r}}_$AC(e){let t=Ul.get(e.strings);return t===void 0&&Ul.set(e.strings,t=new ii(e)),t}k(e){l5(this._$AH)||(this._$AH=[],this._$AR());const t=this._$AH;let o,i=0;for(const s of e)i===t.length?t.push(o=new Ti(this.O(Qt()),this.O(Qt()),this,this.options)):o=t[i],o._$AI(s),i++;i<t.length&&(this._$AR(o&&o._$AB.nextSibling,i),t.length=i)}_$AR(e=this._$AA.nextSibling,t){var o;for((o=this._$AP)==null?void 0:o.call(this,!1,!0,t);e!==this._$AB;){const i=Pl(e).nextSibling;Pl(e).remove(),e=i}}setConnected(e){var t;this._$AM===void 0&&(this._$Cv=e,(t=this._$AP)==null||t.call(this,e))}}class n2{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,t,o,i,s){this.type=1,this._$AH=f,this._$AN=void 0,this.element=e,this.name=t,this._$AM=i,this.options=s,o.length>2||o[0]!==""||o[1]!==""?(this._$AH=Array(o.length-1).fill(new String),this.strings=o):this._$AH=f}_$AI(e,t=this,o,i){const s=this.strings;let r=!1;if(s===void 0)e=rt(this,e,t,0),r=!ei(e)||e!==this._$AH&&e!==p1,r&&(this._$AH=e);else{const a=e;let c,u;for(e=s[0],c=0;c<s.length-1;c++)u=rt(this,a[o+c],t,c),u===p1&&(u=this._$AH[c]),r||(r=!ei(u)||u!==this._$AH[c]),u===f?e=f:e!==f&&(e+=(u??"")+s[c+1]),this._$AH[c]=u}r&&!i&&this.j(e)}j(e){e===f?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,e??"")}}class u0 extends n2{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===f?void 0:e}}class p0 extends n2{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==f)}}class C0 extends n2{constructor(e,t,o,i,s){super(e,t,o,i,s),this.type=5}_$AI(e,t=this){if((e=rt(this,e,t,0)??f)===p1)return;const o=this._$AH,i=e===f&&o!==f||e.capture!==o.capture||e.once!==o.once||e.passive!==o.passive,s=e!==f&&(o===f||i);i&&this.element.removeEventListener(this.name,this,o),s&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){var t;typeof this._$AH=="function"?this._$AH.call(((t=this.options)==null?void 0:t.host)??this.element,e):this._$AH.handleEvent(e)}}class g0{constructor(e,t,o){this.element=e,this.type=6,this._$AN=void 0,this._$AM=t,this.options=o}get _$AU(){return this._$AM._$AU}_$AI(e){rt(this,e)}}const m2=Yt.litHtmlPolyfillSupport;m2==null||m2(ii,Ti),(Yt.litHtmlVersions??(Yt.litHtmlVersions=[])).push("3.3.2");const f0=(n,e,t)=>{const o=(t==null?void 0:t.renderBefore)??e;let i=o._$litPart$;if(i===void 0){const s=(t==null?void 0:t.renderBefore)??null;o._$litPart$=i=new Ti(e.insertBefore(Qt(),s),s,void 0,t??{})}return i._$AI(n),i};/**
16
16
  * @license
17
17
  * Copyright 2017 Google LLC
18
18
  * SPDX-License-Identifier: BSD-3-Clause
19
- */const Ae=globalThis;let C=class extends it{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t;const e=super.createRenderRoot();return(t=this.renderOptions).renderBefore??(t.renderBefore=e.firstChild),e}update(e){const t=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(e),this._$Do=g0(t,this.renderRoot,this.renderOptions)}connectedCallback(){var e;super.connectedCallback(),(e=this._$Do)==null||e.setConnected(!0)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._$Do)==null||e.setConnected(!1)}render(){return p1}};var wa;C._$litElement$=!0,C.finalized=!0,(wa=Ae.litElementHydrateSupport)==null||wa.call(Ae,{LitElement:C});const b2=Ae.litElementPolyfillSupport;b2==null||b2({LitElement:C});(Ae.litElementVersions??(Ae.litElementVersions=[])).push("4.2.2");/**
19
+ */const Ae=globalThis;let C=class extends it{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t;const e=super.createRenderRoot();return(t=this.renderOptions).renderBefore??(t.renderBefore=e.firstChild),e}update(e){const t=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(e),this._$Do=f0(t,this.renderRoot,this.renderOptions)}connectedCallback(){var e;super.connectedCallback(),(e=this._$Do)==null||e.setConnected(!0)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._$Do)==null||e.setConnected(!1)}render(){return p1}};var wa;C._$litElement$=!0,C.finalized=!0,(wa=Ae.litElementHydrateSupport)==null||wa.call(Ae,{LitElement:C});const b2=Ae.litElementPolyfillSupport;b2==null||b2({LitElement:C});(Ae.litElementVersions??(Ae.litElementVersions=[])).push("4.2.2");/**
20
20
  * @license
21
21
  * Copyright 2017 Google LLC
22
22
  * SPDX-License-Identifier: BSD-3-Clause
@@ -235,8 +235,8 @@
235
235
  <path
236
236
  fill="currentColor"
237
237
  d="${o.d}"
238
- fill-rule="${o.fillRule??g}"
239
- clip-rule="${o.clipRule??g}"
238
+ fill-rule="${o.fillRule??f}"
239
+ clip-rule="${o.clipRule??f}"
240
240
  />`)}
241
241
  </svg>
242
242
  `}};P5.styles=p`
@@ -271,26 +271,26 @@
271
271
  .badge--hidden { display: none; }
272
272
  `;function c5(n){return{gray:"badge--light-gray",primary:"badge--light-primary",success:"badge--light-success",warning:"badge--light-warning",danger:"badge--light-danger",boldGray:"badge--bold-gray",boldPrimary:"badge--bold-primary",boldSuccess:"badge--bold-success",boldWarning:"badge--bold-warning",boldDanger:"badge--bold-danger"}[n||"gray"]||"badge--light-gray"}const z5=class z5 extends C{constructor(){super(...arguments),this.variant="gray"}render(){const e=c5(this.variant);return d`<div class="badge ${e}" part="badge"><slot></slot></div>`}};z5.styles=[d5];let oi=z5;$0([l()],oi.prototype,"variant");customElements.get("anduin-badge")||customElements.define("anduin-badge",oi);var Z0=Object.defineProperty,Sa=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&Z0(e,t,i),i};const I5=class I5 extends C{constructor(){super(...arguments),this.variant="gray",this.count=0}formatCount(e){return e>99?"99+":e.toString()}render(){const e=c5(this.variant),t=this.count===0,o=this.count>0&&this.count<10,i=["badge",e,t?"badge--hidden":"",o?"badge--square":""].filter(Boolean).join(" ");return d`<div class="${i}" part="badge">${this.formatCount(this.count)}</div>`}};I5.styles=[d5];let ct=I5;Sa([l()],ct.prototype,"variant");Sa([l({type:Number})],ct.prototype,"count");customElements.get("anduin-badge-count")||customElements.define("anduin-badge-count",ct);var R0=Object.defineProperty,t1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&R0(e,t,i),i};function A0(n){return n.replace(/([A-Z])/g,e=>`-${e.toLowerCase()}`)}const F5=class F5 extends C{constructor(){super(...arguments),this.iconOnly=!1,this.appearance="filled",this.variant="",this.size="medium",this.disabled=!1,this.loading=!1,this.fullWidth=!1,this.pill=!1,this.selected=!1,this.href="",this.openNewTab=!1,this.download="",this.startIcon="",this.endIcon="",this.label=""}firstUpdated(){var t;const e=(t=this.shadowRoot)==null?void 0:t.querySelector("slot");e&&(this.iconOnly=e.assignedNodes({flatten:!0}).length===0)}onSlotChange(e){const t=e.target;this.iconOnly=t.assignedNodes({flatten:!0}).length===0}getVariant(){return this.variant?this.variant:this.appearance==="filled"?"gray0":this.appearance==="text"?"primary":"gray9"}getSizeKebab(){return A0(this.size)}iconSize(){return this.size==="tiny"||this.size==="extraSmall"||this.size==="small"?"12":"16"}render(){const e=this.getVariant(),t=this.getSizeKebab(),o=["button",`button--${this.appearance}`,`button--${e}`,`button--${t}`,this.fullWidth?"button--full-width":"",this.pill?"button--pill":"",this.disabled?"button--disabled":"",this.loading?"button--loading":"",this.selected?"button--selected":"",this.iconOnly&&this.appearance!=="text"&&!this.fullWidth?"button--icon-only":""].filter(Boolean).join(" "),i=d`
273
273
  <div class="button__content button__content--${t}">
274
- ${this.startIcon?d`<anduin-icon name="${this.startIcon}" size="${this.iconSize()}"></anduin-icon>`:g}
274
+ ${this.startIcon?d`<anduin-icon name="${this.startIcon}" size="${this.iconSize()}"></anduin-icon>`:f}
275
275
  <slot @slotchange=${this.onSlotChange}></slot>
276
- ${this.endIcon?d`<anduin-icon name="${this.endIcon}" size="${this.iconSize()}"></anduin-icon>`:g}
276
+ ${this.endIcon?d`<anduin-icon name="${this.endIcon}" size="${this.iconSize()}"></anduin-icon>`:f}
277
277
  </div>
278
- ${this.loading&&this.appearance!=="text"?d`<div class="button__loading"><anduin-spinner size="small"></anduin-spinner></div>`:g}
278
+ ${this.loading&&this.appearance!=="text"?d`<div class="button__loading"><anduin-spinner size="small"></anduin-spinner></div>`:f}
279
279
  `;return this.href?d`
280
280
  <a
281
281
  class="${o}"
282
282
  href="${this.disabled?"":this.href}"
283
- target="${this.openNewTab?"_blank":g}"
284
- rel="${this.openNewTab?"noreferrer noopener":g}"
285
- download="${this.download||g}"
286
- aria-label="${this.label||g}"
283
+ target="${this.openNewTab?"_blank":f}"
284
+ rel="${this.openNewTab?"noreferrer noopener":f}"
285
+ download="${this.download||f}"
286
+ aria-label="${this.label||f}"
287
287
  >${i}</a>
288
288
  `:d`
289
289
  <button
290
290
  type="button"
291
291
  class="${o}"
292
292
  ?disabled="${this.disabled}"
293
- aria-label="${this.label||g}"
293
+ aria-label="${this.label||f}"
294
294
  >${i}</button>
295
295
  `}};F5.styles=p`
296
296
  :host { display: inline-block; font-family: var(--font-sans); }
@@ -578,11 +578,11 @@
578
578
  .checked=${this.checked}
579
579
  ?disabled=${this.disabled||this.readonly}
580
580
  tabindex="${i}"
581
- @change=${o?this.onInputChange:g}
581
+ @change=${o?this.onInputChange:f}
582
582
  />
583
583
  <div class="${e}" tabindex="${i}"></div>
584
584
  <div class="checkbox__icon ${this.indeterminate||this.checked?"checkbox__icon--visible":""}">
585
- ${t?d`<anduin-icon name="${t}" size="16"></anduin-icon>`:g}
585
+ ${t?d`<anduin-icon name="${t}" size="16"></anduin-icon>`:f}
586
586
  </div>
587
587
  </div>
588
588
  <span class="checkbox__label"><slot></slot></span>
@@ -630,7 +630,7 @@
630
630
  <span class="input__start">
631
631
  <anduin-icon name=${this.startIcon} size=${a}></anduin-icon>
632
632
  </span>
633
- `:g}
633
+ `:f}
634
634
 
635
635
  <!--
636
636
  Always rendered, so a native input slotted later is still seen
@@ -645,11 +645,11 @@
645
645
  ${this.disabled?"input--disabled":""}
646
646
  ${this.readonly?"input--readonly":""}
647
647
  ${t}"
648
- style=${h&&this._slotted?`--_end-extra: ${h}px`:g}
648
+ style=${h&&this._slotted?`--_end-extra: ${h}px`:f}
649
649
  @slotchange=${this.onSlotChange}
650
650
  ></slot>
651
651
 
652
- ${this._slotted?g:d`<input
652
+ ${this._slotted?f:d`<input
653
653
  class="input ${e}
654
654
  ${o?"input--has-start":""}
655
655
  ${s?"input--has-end":""}
@@ -657,9 +657,9 @@
657
657
  ${this.readonly?"input--readonly":""}
658
658
  ${t}"
659
659
  type=${u}
660
- autocomplete=${this.autocomplete||g}
661
- name=${this.name||g}
662
- style=${h?`--_end-extra: ${h}px`:g}
660
+ autocomplete=${this.autocomplete||f}
661
+ name=${this.name||f}
662
+ style=${h?`--_end-extra: ${h}px`:f}
663
663
  ?disabled=${this.disabled}
664
664
  ?readonly=${this.readonly}
665
665
  id=${this.inputid||""}
@@ -674,7 +674,7 @@
674
674
  <button class="input__clear" type="button" @click=${this.onClear} aria-label="Clear">
675
675
  <anduin-icon name="cross" size=${c}></anduin-icon>
676
676
  </button>
677
- `:g}
677
+ `:f}
678
678
  ${i?d`
679
679
  <button
680
680
  class="input__reveal"
@@ -688,12 +688,12 @@
688
688
  >
689
689
  <anduin-icon name=${this._revealed?"eyeOff":"eye"} size=${a}></anduin-icon>
690
690
  </button>
691
- `:g}
691
+ `:f}
692
692
  ${this.endIcon?d`
693
693
  <anduin-icon name=${this.endIcon} size=${a}></anduin-icon>
694
- `:g}
694
+ `:f}
695
695
  </span>
696
- `:g}
696
+ `:f}
697
697
  </div>
698
698
  `}};Dn.shadowRootOptions={...C.shadowRootOptions,delegatesFocus:!0},Dn.styles=p`
699
699
  :host { display: block; font-family: var(--font-sans); }
@@ -833,7 +833,7 @@
833
833
 
834
834
  .input-slot::slotted(input:focus) { outline: none !important; border-color: var(--color-ring) !important; }
835
835
  .input-slot::slotted(input:active) { box-shadow: 0 0 0 2px var(--color-ring-subtle) !important; }
836
- `;let S=Dn;j([l()],S.prototype,"value");j([l()],S.prototype,"size");j([l({type:Boolean})],S.prototype,"disabled");j([l({type:Boolean})],S.prototype,"readonly");j([l()],S.prototype,"placeholder");j([l()],S.prototype,"inputid");j([l()],S.prototype,"status");j([l({attribute:"start-icon"})],S.prototype,"startIcon");j([l({attribute:"end-icon"})],S.prototype,"endIcon");j([l({type:Boolean})],S.prototype,"clearable");j([l()],S.prototype,"type");j([l()],S.prototype,"autocomplete");j([l()],S.prototype,"name");j([l({type:Boolean})],S.prototype,"revealable");j([b()],S.prototype,"_revealed");j([b()],S.prototype,"_slotted");j([b()],S.prototype,"_slottedType");j([E("input.input")],S.prototype,"_innerInput");customElements.get("anduin-input")||customElements.define("anduin-input",S);var X0=Object.defineProperty,Ua=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&X0(e,t,i),i};const Ot="anduin-tooltip:show",Tt="anduin-tooltip:hide",l2="anduin-tooltip:trigger-mounted",f5="anduin-tooltip:content-popup-mounted",g5="anduin-tooltip:content-popup-unmounted",v5="anduin-tooltip:visibility-changed",J0=["top-start","top-center","top-end","right-start","right-center","right-end","bottom-start","bottom-center","bottom-end","left-start","left-center","left-end"];function Xl(n,e,t,o,i){switch(o){case"top-start":return{left:n.left,top:n.top-t-i};case"top-center":return{left:n.left+n.width/2-e/2,top:n.top-t-i};case"top-end":return{left:n.left+n.width-e,top:n.top-t-i};case"right-start":return{left:n.right+i,top:n.top};case"right-center":return{left:n.right+i,top:n.top+n.height/2-t/2};case"right-end":return{left:n.right+i,top:n.top+n.height-t};case"bottom-start":return{left:n.left,top:n.bottom+i};case"bottom-center":return{left:n.left+n.width/2-e/2,top:n.bottom+i};case"bottom-end":return{left:n.left+n.width-e,top:n.bottom+i};case"left-start":return{left:n.left-e-i,top:n.top};case"left-center":return{left:n.left-e-i,top:n.top+n.height/2-t/2};case"left-end":return{left:n.left-e-i,top:n.top+n.height-t};default:return{left:0,top:0}}}function Jl(n,e){return e.right>=n.left&&e.left<=n.right&&e.top<=n.bottom&&e.bottom>=n.top}function Ql(n,e){const t=Math.max(n.left,e.left),o=Math.max(n.top,e.top),i=Math.min(n.right,e.right),s=Math.min(n.bottom,e.bottom);return i<t||s<o?0:(i-t)*(s-o)}function Q0(n,e,t,o=8){const i=window.innerWidth,s=window.innerHeight,r={left:0,top:0,right:i,bottom:s},a=e.width,c=e.height;if(!Jl({left:n.left,top:n.top,right:n.right,bottom:n.bottom},r))return null;const u=Xl(n,a,c,t,o),h=J0.map(v=>({p:v,off:Xl(n,a,c,v,o)})).filter(({off:v})=>Jl({left:v.left,top:v.top,right:v.left+a,bottom:v.top+c},r));if(h.length===0)return{placement:t,left:Math.round(Math.min(Math.max(u.left,0),i-a)),top:Math.round(Math.min(Math.max(u.top,0),s-c))};h.sort((v,_)=>{const x={left:v.off.left,top:v.off.top,right:v.off.left+a,bottom:v.off.top+c},y={left:_.off.left,top:_.off.top,right:_.off.left+a,bottom:_.off.top+c},V=Ql(x,r),k=Ql(y,r);if(k!==V)return k-V;const M=Math.abs(v.off.left-u.left)+Math.abs(v.off.top-u.top),$=Math.abs(_.off.left-u.left)+Math.abs(_.off.top-u.top);return M-$});const{p:f,off:m}=h[0];return{placement:f,left:Math.round(Math.min(Math.max(m.left,0),i-a)),top:Math.round(Math.min(Math.max(m.top,0),s-c))}}function S2(n){return n.split("-")[0]||"top"}function e7(n,e,t){let o=!1,i=t.length-1;for(let s=0;s<t.length;s++){const r=t[s][0],a=t[s][1],c=t[i][0],u=t[i][1];a>e!=u>e&&n<(c-r)*(e-a)/(u-a)+r&&(o=!o),i=s}return o}const es=class es extends C{constructor(){super(...arguments),this.disabled=!1,this.placement="top-center",this.triggerElement=null,this.contentPopupElement=null,this.containingBlockLeft=0,this.containingBlockTop=0,this.rafId=0,this.prevTriggerTop=NaN,this.prevTriggerLeft=NaN,this.isVisible=!1}connectedCallback(){super.connectedCallback(),this.addEventListener(l2,e=>{e.stopPropagation(),this.triggerElement=e.detail,this.maybeStartPositionLoop()}),this.addEventListener(f5,e=>{e.stopPropagation(),this.contentPopupElement=e.detail,this.computeContainingBlockOffset(this.contentPopupElement),this.maybeStartPositionLoop()}),this.addEventListener(g5,e=>{e.stopPropagation(),this.stopPositionLoop(),this.contentPopupElement=null}),this.addEventListener(Ot,e=>{e.stopPropagation(),!this.disabled&&(this.isVisible=!0,this.broadcastVisibilityChanged(`show:${this.placement}`))}),this.addEventListener(Tt,e=>{e.stopPropagation(),this.isVisible=!1,this.stopPositionLoop(),this.broadcastVisibilityChanged("hide")})}updated(e){e.has("disabled")&&this.disabled&&this.isVisible&&(this.isVisible=!1,this.stopPositionLoop(),this.broadcastVisibilityChanged("hide"))}disconnectedCallback(){super.disconnectedCallback(),this.stopPositionLoop(),this.triggerElement=null,this.contentPopupElement=null}maybeStartPositionLoop(){this.isVisible&&this.triggerElement&&this.contentPopupElement&&this.startPositionLoop()}startPositionLoop(){this.stopPositionLoop(),this.prevTriggerTop=NaN,this.prevTriggerLeft=NaN;const e=this.triggerElement,t=this.contentPopupElement,o=this.placement,i=()=>{const s=e.getBoundingClientRect();(s.top!==this.prevTriggerTop||s.left!==this.prevTriggerLeft)&&(this.prevTriggerTop=s.top,this.prevTriggerLeft=s.left,this.positionPopup(t,e,o)),this.rafId=requestAnimationFrame(i)};this.rafId=requestAnimationFrame(i)}stopPositionLoop(){this.rafId&&(cancelAnimationFrame(this.rafId),this.rafId=0),this.prevTriggerTop=NaN,this.prevTriggerLeft=NaN}computeContainingBlockOffset(e){const t=e,o=t.style.transform;t.style.transform="none";const i=e.getBoundingClientRect();this.containingBlockLeft=i.left,this.containingBlockTop=i.top,t.style.transform=o}positionPopup(e,t,o){const i=t.getBoundingClientRect(),s=e.getBoundingClientRect(),r=Q0(i,s,o,8);if(r){const a=e;a.style.transform=`translate(${r.left-this.containingBlockLeft}px, ${r.top-this.containingBlockTop}px)`;const c=S2(r.placement),u=S2(o);if(c!==u){const h=e.querySelector(".tooltip-arrow");h&&(h.classList.remove(`tooltip-arrow--${u}`),h.classList.add(`tooltip-arrow--${c}`))}}}broadcastVisibilityChanged(e){this.dispatchEvent(new CustomEvent(v5,{detail:e,bubbles:!1,composed:!1}))}render(){return d`<div class="tooltip-root" part="tooltip"><slot></slot></div>`}};es.styles=p`
836
+ `;let S=Dn;j([l()],S.prototype,"value");j([l()],S.prototype,"size");j([l({type:Boolean})],S.prototype,"disabled");j([l({type:Boolean})],S.prototype,"readonly");j([l()],S.prototype,"placeholder");j([l()],S.prototype,"inputid");j([l()],S.prototype,"status");j([l({attribute:"start-icon"})],S.prototype,"startIcon");j([l({attribute:"end-icon"})],S.prototype,"endIcon");j([l({type:Boolean})],S.prototype,"clearable");j([l()],S.prototype,"type");j([l()],S.prototype,"autocomplete");j([l()],S.prototype,"name");j([l({type:Boolean})],S.prototype,"revealable");j([b()],S.prototype,"_revealed");j([b()],S.prototype,"_slotted");j([b()],S.prototype,"_slottedType");j([E("input.input")],S.prototype,"_innerInput");customElements.get("anduin-input")||customElements.define("anduin-input",S);var X0=Object.defineProperty,Ua=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&X0(e,t,i),i};const Ot="anduin-tooltip:show",Tt="anduin-tooltip:hide",l2="anduin-tooltip:trigger-mounted",g5="anduin-tooltip:content-popup-mounted",f5="anduin-tooltip:content-popup-unmounted",v5="anduin-tooltip:visibility-changed",J0=["top-start","top-center","top-end","right-start","right-center","right-end","bottom-start","bottom-center","bottom-end","left-start","left-center","left-end"];function Xl(n,e,t,o,i){switch(o){case"top-start":return{left:n.left,top:n.top-t-i};case"top-center":return{left:n.left+n.width/2-e/2,top:n.top-t-i};case"top-end":return{left:n.left+n.width-e,top:n.top-t-i};case"right-start":return{left:n.right+i,top:n.top};case"right-center":return{left:n.right+i,top:n.top+n.height/2-t/2};case"right-end":return{left:n.right+i,top:n.top+n.height-t};case"bottom-start":return{left:n.left,top:n.bottom+i};case"bottom-center":return{left:n.left+n.width/2-e/2,top:n.bottom+i};case"bottom-end":return{left:n.left+n.width-e,top:n.bottom+i};case"left-start":return{left:n.left-e-i,top:n.top};case"left-center":return{left:n.left-e-i,top:n.top+n.height/2-t/2};case"left-end":return{left:n.left-e-i,top:n.top+n.height-t};default:return{left:0,top:0}}}function Jl(n,e){return e.right>=n.left&&e.left<=n.right&&e.top<=n.bottom&&e.bottom>=n.top}function Ql(n,e){const t=Math.max(n.left,e.left),o=Math.max(n.top,e.top),i=Math.min(n.right,e.right),s=Math.min(n.bottom,e.bottom);return i<t||s<o?0:(i-t)*(s-o)}function Q0(n,e,t,o=8){const i=window.innerWidth,s=window.innerHeight,r={left:0,top:0,right:i,bottom:s},a=e.width,c=e.height;if(!Jl({left:n.left,top:n.top,right:n.right,bottom:n.bottom},r))return null;const u=Xl(n,a,c,t,o),h=J0.map(v=>({p:v,off:Xl(n,a,c,v,o)})).filter(({off:v})=>Jl({left:v.left,top:v.top,right:v.left+a,bottom:v.top+c},r));if(h.length===0)return{placement:t,left:Math.round(Math.min(Math.max(u.left,0),i-a)),top:Math.round(Math.min(Math.max(u.top,0),s-c))};h.sort((v,_)=>{const x={left:v.off.left,top:v.off.top,right:v.off.left+a,bottom:v.off.top+c},y={left:_.off.left,top:_.off.top,right:_.off.left+a,bottom:_.off.top+c},V=Ql(x,r),L=Ql(y,r);if(L!==V)return L-V;const M=Math.abs(v.off.left-u.left)+Math.abs(v.off.top-u.top),$=Math.abs(_.off.left-u.left)+Math.abs(_.off.top-u.top);return M-$});const{p:g,off:m}=h[0];return{placement:g,left:Math.round(Math.min(Math.max(m.left,0),i-a)),top:Math.round(Math.min(Math.max(m.top,0),s-c))}}function S2(n){return n.split("-")[0]||"top"}function e7(n,e,t){let o=!1,i=t.length-1;for(let s=0;s<t.length;s++){const r=t[s][0],a=t[s][1],c=t[i][0],u=t[i][1];a>e!=u>e&&n<(c-r)*(e-a)/(u-a)+r&&(o=!o),i=s}return o}const es=class es extends C{constructor(){super(...arguments),this.disabled=!1,this.placement="top-center",this.triggerElement=null,this.contentPopupElement=null,this.containingBlockLeft=0,this.containingBlockTop=0,this.rafId=0,this.prevTriggerTop=NaN,this.prevTriggerLeft=NaN,this.isVisible=!1}connectedCallback(){super.connectedCallback(),this.addEventListener(l2,e=>{e.stopPropagation(),this.triggerElement=e.detail,this.maybeStartPositionLoop()}),this.addEventListener(g5,e=>{e.stopPropagation(),this.contentPopupElement=e.detail,this.computeContainingBlockOffset(this.contentPopupElement),this.maybeStartPositionLoop()}),this.addEventListener(f5,e=>{e.stopPropagation(),this.stopPositionLoop(),this.contentPopupElement=null}),this.addEventListener(Ot,e=>{e.stopPropagation(),!this.disabled&&(this.isVisible=!0,this.broadcastVisibilityChanged(`show:${this.placement}`))}),this.addEventListener(Tt,e=>{e.stopPropagation(),this.isVisible=!1,this.stopPositionLoop(),this.broadcastVisibilityChanged("hide")})}updated(e){e.has("disabled")&&this.disabled&&this.isVisible&&(this.isVisible=!1,this.stopPositionLoop(),this.broadcastVisibilityChanged("hide"))}disconnectedCallback(){super.disconnectedCallback(),this.stopPositionLoop(),this.triggerElement=null,this.contentPopupElement=null}maybeStartPositionLoop(){this.isVisible&&this.triggerElement&&this.contentPopupElement&&this.startPositionLoop()}startPositionLoop(){this.stopPositionLoop(),this.prevTriggerTop=NaN,this.prevTriggerLeft=NaN;const e=this.triggerElement,t=this.contentPopupElement,o=this.placement,i=()=>{const s=e.getBoundingClientRect();(s.top!==this.prevTriggerTop||s.left!==this.prevTriggerLeft)&&(this.prevTriggerTop=s.top,this.prevTriggerLeft=s.left,this.positionPopup(t,e,o)),this.rafId=requestAnimationFrame(i)};this.rafId=requestAnimationFrame(i)}stopPositionLoop(){this.rafId&&(cancelAnimationFrame(this.rafId),this.rafId=0),this.prevTriggerTop=NaN,this.prevTriggerLeft=NaN}computeContainingBlockOffset(e){const t=e,o=t.style.transform;t.style.transform="none";const i=e.getBoundingClientRect();this.containingBlockLeft=i.left,this.containingBlockTop=i.top,t.style.transform=o}positionPopup(e,t,o){const i=t.getBoundingClientRect(),s=e.getBoundingClientRect(),r=Q0(i,s,o,8);if(r){const a=e;a.style.transform=`translate(${r.left-this.containingBlockLeft}px, ${r.top-this.containingBlockTop}px)`;const c=S2(r.placement),u=S2(o);if(c!==u){const h=e.querySelector(".tooltip-arrow");h&&(h.classList.remove(`tooltip-arrow--${u}`),h.classList.add(`tooltip-arrow--${c}`))}}}broadcastVisibilityChanged(e){this.dispatchEvent(new CustomEvent(v5,{detail:e,bubbles:!1,composed:!1}))}render(){return d`<div class="tooltip-root" part="tooltip"><slot></slot></div>`}};es.styles=p`
837
837
  /* inline-flex, not inline-block: the wrapper is purely structural (it exists
838
838
  to position the popup), so it must not add height of its own. As an
839
839
  inline-block it establishes a line box, and an inline-level trigger sits
@@ -843,10 +843,10 @@
843
843
  keeping the wrapper inline in the surrounding text flow. */
844
844
  :host { display: inline-flex; position: relative; max-width: 100%; font-family: var(--font-sans); }
845
845
  .tooltip-root { display: inline-flex; position: relative; max-width: 100%; }
846
- `;let ft=es;Ua([l({type:Boolean})],ft.prototype,"disabled");Ua([l()],ft.prototype,"placement");const ts=class ts extends C{firstUpdated(){requestAnimationFrame(()=>{this.dispatchEvent(new CustomEvent(l2,{detail:this,bubbles:!0,composed:!0}))}),this.addEventListener("pointerenter",()=>{this.dispatchEvent(new CustomEvent(Ot,{bubbles:!0,composed:!0}))}),this.addEventListener("click",()=>{this.dispatchEvent(new CustomEvent(Tt,{bubbles:!0,composed:!0}))})}render(){return d`<span class="tooltip-trigger" part="tooltip-trigger"><slot></slot></span>`}};ts.styles=p`
846
+ `;let gt=es;Ua([l({type:Boolean})],gt.prototype,"disabled");Ua([l()],gt.prototype,"placement");const ts=class ts extends C{firstUpdated(){requestAnimationFrame(()=>{this.dispatchEvent(new CustomEvent(l2,{detail:this,bubbles:!0,composed:!0}))}),this.addEventListener("pointerenter",()=>{this.dispatchEvent(new CustomEvent(Ot,{bubbles:!0,composed:!0}))}),this.addEventListener("click",()=>{this.dispatchEvent(new CustomEvent(Tt,{bubbles:!0,composed:!0}))})}render(){return d`<span class="tooltip-trigger" part="tooltip-trigger"><slot></slot></span>`}};ts.styles=p`
847
847
  :host { display: inline-block; max-width: 100%; font-family: var(--font-sans); }
848
848
  .tooltip-trigger { display: flex; align-items: center; max-width: 100%; }
849
- `;let eo=ts;const is=class is extends C{constructor(){super(...arguments),this.graceArea=null,this.triggerEl=null,this.popupEl=null,this.handlePointerMove=e=>{var s,r;if(!this.graceArea)return;const t=e.target,o=((s=this.triggerEl)==null?void 0:s.contains(t))??!1,i=((r=this.popupEl)==null?void 0:r.contains(t))??!1;o||i?this.graceArea=null:e7(e.clientX,e.clientY,this.graceArea)||(this.graceArea=null,this.dispatchEvent(new CustomEvent(Tt,{bubbles:!0,composed:!0})))},this.handleTriggerLeave=e=>{this.triggerEl&&this.popupEl&&this.createGraceArea(this.triggerEl,this.popupEl,e)},this.handleContentLeave=e=>{this.triggerEl&&this.popupEl&&this.createGraceArea(this.popupEl,this.triggerEl,e)}}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-tooltip");e&&e.addEventListener(v5,t=>{const o=t.detail;o.startsWith("show:")?this.showPopup(o.slice(5)):this.hidePopup()})}disconnectedCallback(){super.disconnectedCallback(),this.hidePopup()}createGraceArea(e,t,o){const i=t.getBoundingClientRect(),s=o.clientX,r=o.clientY;this.graceArea=[[s,r],[i.left,i.top],[i.right,i.top],[i.right,i.bottom],[i.left,i.bottom]]}setupGraceAreaListeners(e,t){this.cleanupGraceAreaListeners(),this.triggerEl=e,this.popupEl=t,e.addEventListener("pointerleave",this.handleTriggerLeave),t.addEventListener("pointerleave",this.handleContentLeave),document.addEventListener("pointermove",this.handlePointerMove)}cleanupGraceAreaListeners(){this.triggerEl&&this.triggerEl.removeEventListener("pointerleave",this.handleTriggerLeave),this.popupEl&&this.popupEl.removeEventListener("pointerleave",this.handleContentLeave),document.removeEventListener("pointermove",this.handlePointerMove),this.graceArea=null,this.triggerEl=null,this.popupEl=null}showPopup(e){this.hidePopup();const t=S2(e),o=document.createElement("div");o.className="tooltip-popup",o.setAttribute("role","tooltip");const i=document.createElement("div");i.className=`tooltip-arrow tooltip-arrow--${t}`;const s=document.createElement("div");s.className="tooltip-body",s.appendChild(document.createElement("slot")),o.appendChild(i),o.appendChild(s);const r=this.shadowRoot.querySelector(".tooltip-content-wrapper");r&&r.appendChild(o),this.popupEl=o;const a=this.closest("anduin-tooltip");if(a){const c=a.querySelector("anduin-tooltip-trigger");c&&this.setupGraceAreaListeners(c,o)}this.dispatchEvent(new CustomEvent(f5,{detail:o,bubbles:!0,composed:!0}))}hidePopup(){this.popupEl&&(this.popupEl.remove(),this.popupEl=null,this.dispatchEvent(new CustomEvent(g5,{bubbles:!0,composed:!0}))),this.cleanupGraceAreaListeners()}render(){return d`<div class="tooltip-content-wrapper"></div>`}};is.styles=p`
849
+ `;let eo=ts;const is=class is extends C{constructor(){super(...arguments),this.graceArea=null,this.triggerEl=null,this.popupEl=null,this.handlePointerMove=e=>{var s,r;if(!this.graceArea)return;const t=e.target,o=((s=this.triggerEl)==null?void 0:s.contains(t))??!1,i=((r=this.popupEl)==null?void 0:r.contains(t))??!1;o||i?this.graceArea=null:e7(e.clientX,e.clientY,this.graceArea)||(this.graceArea=null,this.dispatchEvent(new CustomEvent(Tt,{bubbles:!0,composed:!0})))},this.handleTriggerLeave=e=>{this.triggerEl&&this.popupEl&&this.createGraceArea(this.triggerEl,this.popupEl,e)},this.handleContentLeave=e=>{this.triggerEl&&this.popupEl&&this.createGraceArea(this.popupEl,this.triggerEl,e)}}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-tooltip");e&&e.addEventListener(v5,t=>{const o=t.detail;o.startsWith("show:")?this.showPopup(o.slice(5)):this.hidePopup()})}disconnectedCallback(){super.disconnectedCallback(),this.hidePopup()}createGraceArea(e,t,o){const i=t.getBoundingClientRect(),s=o.clientX,r=o.clientY;this.graceArea=[[s,r],[i.left,i.top],[i.right,i.top],[i.right,i.bottom],[i.left,i.bottom]]}setupGraceAreaListeners(e,t){this.cleanupGraceAreaListeners(),this.triggerEl=e,this.popupEl=t,e.addEventListener("pointerleave",this.handleTriggerLeave),t.addEventListener("pointerleave",this.handleContentLeave),document.addEventListener("pointermove",this.handlePointerMove)}cleanupGraceAreaListeners(){this.triggerEl&&this.triggerEl.removeEventListener("pointerleave",this.handleTriggerLeave),this.popupEl&&this.popupEl.removeEventListener("pointerleave",this.handleContentLeave),document.removeEventListener("pointermove",this.handlePointerMove),this.graceArea=null,this.triggerEl=null,this.popupEl=null}showPopup(e){this.hidePopup();const t=S2(e),o=document.createElement("div");o.className="tooltip-popup",o.setAttribute("role","tooltip");const i=document.createElement("div");i.className=`tooltip-arrow tooltip-arrow--${t}`;const s=document.createElement("div");s.className="tooltip-body",s.appendChild(document.createElement("slot")),o.appendChild(i),o.appendChild(s);const r=this.shadowRoot.querySelector(".tooltip-content-wrapper");r&&r.appendChild(o),this.popupEl=o;const a=this.closest("anduin-tooltip");if(a){const c=a.querySelector("anduin-tooltip-trigger");c&&this.setupGraceAreaListeners(c,o)}this.dispatchEvent(new CustomEvent(g5,{detail:o,bubbles:!0,composed:!0}))}hidePopup(){this.popupEl&&(this.popupEl.remove(),this.popupEl=null,this.dispatchEvent(new CustomEvent(f5,{bubbles:!0,composed:!0}))),this.cleanupGraceAreaListeners()}render(){return d`<div class="tooltip-content-wrapper"></div>`}};is.styles=p`
850
850
  :host {
851
851
  display: contents;
852
852
  --tooltip-bg: var(--anduin-tooltip-content-background, var(--color-inverse));
@@ -869,14 +869,14 @@
869
869
  .tooltip-arrow--bottom { top: -4px; left: 50%; transform: translateX(-50%); border-bottom-color: var(--tooltip-bg); border-top: none; }
870
870
  .tooltip-arrow--left { right: -4px; top: 50%; transform: translateY(-50%); border-left-color: var(--tooltip-bg); border-right: none; }
871
871
  .tooltip-arrow--right { left: -4px; top: 50%; transform: translateY(-50%); border-right-color: var(--tooltip-bg); border-left: none; }
872
- `;let to=is;customElements.get("anduin-tooltip")||customElements.define("anduin-tooltip",ft);customElements.get("anduin-tooltip-trigger")||customElements.define("anduin-tooltip-trigger",eo);customElements.get("anduin-tooltip-content")||customElements.define("anduin-tooltip-content",to);var t7=Object.defineProperty,J=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&t7(e,t,i),i};const Ga="anduin-inline-edit:save",qa="anduin-inline-edit:cancel",Ka="anduin-inline-edit:edit",os=class os extends C{constructor(){super(...arguments),this.value="",this.placeholder="",this.size="medium",this.mode="view",this.disabled=!1,this.clickToEdit=!1,this.hideSwitcher=!1,this.editLabel="Edit",this._editing=!1,this._draft="",this._error="",this._hasSlotted=!1,this._openWidth=0}get editing(){return this._editing}async edit(){var e,t,o;this.disabled||(this._editing||(this._openWidth=((e=this._text)==null?void 0:e.getBoundingClientRect().width)??0,this._draft=this.value,this._error=this._runValidate(this.value),this._editing=!0,this.dispatchEvent(new CustomEvent(Ka,{bubbles:!0,composed:!0}))),await this.updateComplete,(t=this._field)==null||t.focus(),(o=this._field)==null||o.select())}cancel(){this._editing&&(this._exit(),this.dispatchEvent(new CustomEvent(qa,{bubbles:!0,composed:!0})))}save(){if(!this._editing||this._error)return;const e=this._draft;if(e===this.value){this.cancel();return}this.value=e,this._exit(),this.dispatchEvent(new CustomEvent(Ga,{detail:e,bubbles:!0,composed:!0}))}_exit(){this._editing=!1,this._draft=this.value,this._error=""}_runValidate(e){var t;return((t=this.validate)==null?void 0:t.call(this,e))||""}willUpdate(e){if(!this.hasUpdated){this.mode==="edit"&&!this.disabled&&(this._editing=!0,this._draft=this.value,this._error=this._runValidate(this.value));return}if(e.has("value")&&this._editing){const t=e.get("value");this._draft===t&&(this._draft=this.value,this._error=this._runValidate(this.value))}e.has("validate")&&this._editing&&(this._error=this._runValidate(this._draft)),e.has("disabled")&&this.disabled&&this._editing&&this._exit()}updated(){this.toggleAttribute("editing",this._editing)}_onInput(e){this._draft=e.target.value,this._error=this._runValidate(this._draft)}_onKeydown(e){e.isComposing||(e.key==="Enter"?(e.preventDefault(),e.stopPropagation(),this.save()):e.key==="Escape"&&(e.preventDefault(),e.stopPropagation(),this.cancel()))}_onTextClick(){this.clickToEdit&&!this.disabled&&this.edit()}_onSlotChange(e){const t=e.target;this._hasSlotted=t.assignedNodes({flatten:!0}).some(o=>{var i;return o.nodeType===Node.ELEMENT_NODE||o.nodeType===Node.TEXT_NODE&&!!((i=o.textContent)!=null&&i.trim())})}_renderView(){const e=!this.value,t=this.clickToEdit&&!this.disabled;return d`
872
+ `;let to=is;customElements.get("anduin-tooltip")||customElements.define("anduin-tooltip",gt);customElements.get("anduin-tooltip-trigger")||customElements.define("anduin-tooltip-trigger",eo);customElements.get("anduin-tooltip-content")||customElements.define("anduin-tooltip-content",to);var t7=Object.defineProperty,J=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&t7(e,t,i),i};const Ga="anduin-inline-edit:save",qa="anduin-inline-edit:cancel",Ka="anduin-inline-edit:edit",os=class os extends C{constructor(){super(...arguments),this.value="",this.placeholder="",this.size="medium",this.mode="view",this.disabled=!1,this.clickToEdit=!1,this.hideSwitcher=!1,this.editLabel="Edit",this._editing=!1,this._draft="",this._error="",this._hasSlotted=!1,this._openWidth=0}get editing(){return this._editing}async edit(){var e,t,o;this.disabled||(this._editing||(this._openWidth=((e=this._text)==null?void 0:e.getBoundingClientRect().width)??0,this._draft=this.value,this._error=this._runValidate(this.value),this._editing=!0,this.dispatchEvent(new CustomEvent(Ka,{bubbles:!0,composed:!0}))),await this.updateComplete,(t=this._field)==null||t.focus(),(o=this._field)==null||o.select())}cancel(){this._editing&&(this._exit(),this.dispatchEvent(new CustomEvent(qa,{bubbles:!0,composed:!0})))}save(){if(!this._editing||this._error)return;const e=this._draft;if(e===this.value){this.cancel();return}this.value=e,this._exit(),this.dispatchEvent(new CustomEvent(Ga,{detail:e,bubbles:!0,composed:!0}))}_exit(){this._editing=!1,this._draft=this.value,this._error=""}_runValidate(e){var t;return((t=this.validate)==null?void 0:t.call(this,e))||""}willUpdate(e){if(!this.hasUpdated){this.mode==="edit"&&!this.disabled&&(this._editing=!0,this._draft=this.value,this._error=this._runValidate(this.value));return}if(e.has("value")&&this._editing){const t=e.get("value");this._draft===t&&(this._draft=this.value,this._error=this._runValidate(this.value))}e.has("validate")&&this._editing&&(this._error=this._runValidate(this._draft)),e.has("disabled")&&this.disabled&&this._editing&&this._exit()}updated(){this.toggleAttribute("editing",this._editing)}_onInput(e){this._draft=e.target.value,this._error=this._runValidate(this._draft)}_onKeydown(e){e.isComposing||(e.key==="Enter"?(e.preventDefault(),e.stopPropagation(),this.save()):e.key==="Escape"&&(e.preventDefault(),e.stopPropagation(),this.cancel()))}_onTextClick(){this.clickToEdit&&!this.disabled&&this.edit()}_onSlotChange(e){const t=e.target;this._hasSlotted=t.assignedNodes({flatten:!0}).some(o=>{var i;return o.nodeType===Node.ELEMENT_NODE||o.nodeType===Node.TEXT_NODE&&!!((i=o.textContent)!=null&&i.trim())})}_renderView(){const e=!this.value,t=this.clickToEdit&&!this.disabled;return d`
873
873
  <div class="view" part="view">
874
874
  <span
875
875
  class="text ${t?"text--clickable":""} ${e&&!this._hasSlotted?"text--placeholder":""}"
876
876
  part="text"
877
877
  @click=${this._onTextClick}
878
- >${this._hasSlotted?g:e?this.placeholder:this.value}<slot @slotchange=${this._onSlotChange}></slot></span>
879
- ${this.disabled||this.hideSwitcher?g:d`
878
+ >${this._hasSlotted?f:e?this.placeholder:this.value}<slot @slotchange=${this._onSlotChange}></slot></span>
879
+ ${this.disabled||this.hideSwitcher?f:d`
880
880
  <anduin-tooltip class="switcher" part="switcher">
881
881
  <anduin-tooltip-trigger>
882
882
  <anduin-button
@@ -899,7 +899,7 @@
899
899
  type="text"
900
900
  style="width: calc(${i})"
901
901
  .value=${this._draft}
902
- placeholder=${this.placeholder||g}
902
+ placeholder=${this.placeholder||f}
903
903
  aria-invalid=${t?"true":"false"}
904
904
  @input=${this._onInput}
905
905
  @keydown=${this._onKeydown}
@@ -1037,12 +1037,12 @@
1037
1037
  ::-webkit-scrollbar-corner {
1038
1038
  background-color: transparent;
1039
1039
  }
1040
- `;var o7=Object.defineProperty,g1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&o7(e,t,i),i};const m5="anduin-tab:trigger-click",Pi="anduin-tab:value-changed",Wa="anduin-tab:change",ns=class ns extends C{constructor(){super(...arguments),this.defaultValue="",this.value="",this.fill=!1}connectedCallback(){super.connectedCallback(),this.addEventListener(m5,e=>{e.stopPropagation();const t=e;this.value=t.detail,this.broadcastValueChanged(t.detail),this.dispatchEvent(new CustomEvent(Wa,{detail:t.detail,bubbles:!0,composed:!0}))}),requestAnimationFrame(()=>{const e=this.value||this.defaultValue;e&&(this.value||(this.value=e),this.broadcastValueChanged(e))})}updated(e){if(e.has("value")||e.has("defaultValue")){const t=this.value||this.defaultValue;t&&this.broadcastValueChanged(t)}}broadcastValueChanged(e){this.dispatchEvent(new CustomEvent(Pi,{detail:e,bubbles:!1,composed:!1}))}render(){return d`<div class="tabs" part="tabs"><slot></slot></div>`}};ns.styles=p`
1040
+ `;var o7=Object.defineProperty,f1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&o7(e,t,i),i};const m5="anduin-tab:trigger-click",Pi="anduin-tab:value-changed",Wa="anduin-tab:change",ns=class ns extends C{constructor(){super(...arguments),this.defaultValue="",this.value="",this.fill=!1}connectedCallback(){super.connectedCallback(),this.addEventListener(m5,e=>{e.stopPropagation();const t=e;this.value=t.detail,this.broadcastValueChanged(t.detail),this.dispatchEvent(new CustomEvent(Wa,{detail:t.detail,bubbles:!0,composed:!0}))}),requestAnimationFrame(()=>{const e=this.value||this.defaultValue;e&&(this.value||(this.value=e),this.broadcastValueChanged(e))})}updated(e){if(e.has("value")||e.has("defaultValue")){const t=this.value||this.defaultValue;t&&this.broadcastValueChanged(t)}}broadcastValueChanged(e){this.dispatchEvent(new CustomEvent(Pi,{detail:e,bubbles:!1,composed:!1}))}render(){return d`<div class="tabs" part="tabs"><slot></slot></div>`}};ns.styles=p`
1041
1041
  :host { display: flex; flex-direction: column; font-family: var(--font-sans); }
1042
1042
  :host([fill]) { flex: 1; min-height: 0; --_tab-fill-flex: 1; --_tab-fill-height: 100%; }
1043
1043
  .tabs { display: flex; flex-direction: column; width: 100%; }
1044
1044
  :host([fill]) .tabs { flex: 1; min-height: 0; }
1045
- `;let Pe=ns;g1([l({attribute:"default-value"})],Pe.prototype,"defaultValue");g1([l()],Pe.prototype,"value");g1([l({type:Boolean,reflect:!0})],Pe.prototype,"fill");const ss=class ss extends C{constructor(){super(...arguments),this.alignment="left",this.lastActiveValue="",this.resizeObserver=null}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-tabs");e&&e.addEventListener(Pi,t=>{const o=t;this.lastActiveValue=o.detail,requestAnimationFrame(()=>{this.animateIndicator(o.detail)})})}firstUpdated(){const e=this.closest("anduin-tabs"),t=(e==null?void 0:e.value)||(e==null?void 0:e.defaultValue);t&&(this.lastActiveValue=t,requestAnimationFrame(()=>this.animateIndicator(t))),this.resizeObserver=new ResizeObserver(o=>{this.lastActiveValue&&o.length>0&&o[0].contentRect.width>0&&this.animateIndicator(this.lastActiveValue)}),this.resizeObserver.observe(this)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.resizeObserver)==null||e.disconnect(),this.resizeObserver=null}animateIndicator(e){const t=this.querySelectorAll(":scope > anduin-tab-trigger");for(let o=0;o<t.length;o++){const i=t[o];if((i.value||i.getAttribute("value"))===e){const r=i.getBoundingClientRect(),a=this.getBoundingClientRect(),c=r.left-a.left+this.scrollLeft;this.indicator&&(this.indicator.style.width=`${r.width}px`,this.indicator.style.transform=`translateX(${c}px)`);break}}}render(){return d`
1045
+ `;let Pe=ns;f1([l({attribute:"default-value"})],Pe.prototype,"defaultValue");f1([l()],Pe.prototype,"value");f1([l({type:Boolean,reflect:!0})],Pe.prototype,"fill");const ss=class ss extends C{constructor(){super(...arguments),this.alignment="left",this.lastActiveValue="",this.resizeObserver=null}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-tabs");e&&e.addEventListener(Pi,t=>{const o=t;this.lastActiveValue=o.detail,requestAnimationFrame(()=>{this.animateIndicator(o.detail)})})}firstUpdated(){const e=this.closest("anduin-tabs"),t=(e==null?void 0:e.value)||(e==null?void 0:e.defaultValue);t&&(this.lastActiveValue=t,requestAnimationFrame(()=>this.animateIndicator(t))),this.resizeObserver=new ResizeObserver(o=>{this.lastActiveValue&&o.length>0&&o[0].contentRect.width>0&&this.animateIndicator(this.lastActiveValue)}),this.resizeObserver.observe(this)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.resizeObserver)==null||e.disconnect(),this.resizeObserver=null}animateIndicator(e){const t=this.querySelectorAll(":scope > anduin-tab-trigger");for(let o=0;o<t.length;o++){const i=t[o];if((i.value||i.getAttribute("value"))===e){const r=i.getBoundingClientRect(),a=this.getBoundingClientRect(),c=r.left-a.left+this.scrollLeft;this.indicator&&(this.indicator.style.width=`${r.width}px`,this.indicator.style.transform=`translateX(${c}px)`);break}}}render(){return d`
1046
1046
  <div class="tabs-list tabs-list--${this.alignment}" role="tablist" aria-orientation="horizontal" part="tabs-list">
1047
1047
  <slot></slot>
1048
1048
  <div class="tabs-list__indicator"></div>
@@ -1063,7 +1063,7 @@
1063
1063
  position: absolute; bottom: 0; background-color: var(--color-primary);
1064
1064
  left: 0; height: 2px; transition-duration: 200ms; transition-property: transform, width;
1065
1065
  }
1066
- `;let gt=ss;g1([l()],gt.prototype,"alignment");g1([E(".tabs-list__indicator")],gt.prototype,"indicator");const rs=class rs extends C{constructor(){super(...arguments),this.value="",this.startIcon="",this.disabled=!1,this.showBadge=!1,this.badgeCount="",this.isActive=!1}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-tabs");e&&e.addEventListener(Pi,t=>{const o=t;this.isActive=o.detail===this.value})}onClick(){this.dispatchEvent(new CustomEvent(m5,{detail:this.value,bubbles:!0,composed:!0}))}render(){return d`
1066
+ `;let ft=ss;f1([l()],ft.prototype,"alignment");f1([E(".tabs-list__indicator")],ft.prototype,"indicator");const rs=class rs extends C{constructor(){super(...arguments),this.value="",this.startIcon="",this.disabled=!1,this.showBadge=!1,this.badgeCount="",this.isActive=!1}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-tabs");e&&e.addEventListener(Pi,t=>{const o=t;this.isActive=o.detail===this.value})}onClick(){this.dispatchEvent(new CustomEvent(m5,{detail:this.value,bubbles:!0,composed:!0}))}render(){return d`
1067
1067
  <button
1068
1068
  class="tab-trigger ${this.isActive?"tab-trigger--active":"tab-trigger--normal"}"
1069
1069
  role="tab"
@@ -1073,9 +1073,9 @@
1073
1073
  @click=${this.onClick}
1074
1074
  >
1075
1075
  <div class="tab-trigger__content">
1076
- ${this.startIcon?d`<anduin-icon name="${this.startIcon}" size="16"></anduin-icon>`:g}
1076
+ ${this.startIcon?d`<anduin-icon name="${this.startIcon}" size="16"></anduin-icon>`:f}
1077
1077
  <slot></slot>
1078
- ${this.showBadge?d`<span class="tab-trigger__badge">${this.badgeCount}</span>`:g}
1078
+ ${this.showBadge?d`<span class="tab-trigger__badge">${this.badgeCount}</span>`:f}
1079
1079
  </div>
1080
1080
  </button>
1081
1081
  `}};rs.styles=p`
@@ -1100,7 +1100,7 @@
1100
1100
  font-size: 11px; line-height: 16px; font-weight: 590; letter-spacing: 0.066px;
1101
1101
  color: var(--color-neutral-subtle-foreground); white-space: nowrap;
1102
1102
  }
1103
- `;let $1=rs;g1([l({reflect:!0})],$1.prototype,"value");g1([l({attribute:"start-icon"})],$1.prototype,"startIcon");g1([l({type:Boolean})],$1.prototype,"disabled");g1([l({type:Boolean,attribute:"show-badge"})],$1.prototype,"showBadge");g1([l({attribute:"badge-count"})],$1.prototype,"badgeCount");g1([b()],$1.prototype,"isActive");const ls=class ls extends C{constructor(){super(...arguments),this.value="",this.isActive=!1}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-tabs");e&&e.addEventListener(Pi,t=>{const o=t;this.isActive=o.detail===this.value})}updated(e){e.has("isActive")&&this.toggleAttribute("active",this.isActive)}render(){return d`
1103
+ `;let $1=rs;f1([l({reflect:!0})],$1.prototype,"value");f1([l({attribute:"start-icon"})],$1.prototype,"startIcon");f1([l({type:Boolean})],$1.prototype,"disabled");f1([l({type:Boolean,attribute:"show-badge"})],$1.prototype,"showBadge");f1([l({attribute:"badge-count"})],$1.prototype,"badgeCount");f1([b()],$1.prototype,"isActive");const ls=class ls extends C{constructor(){super(...arguments),this.value="",this.isActive=!1}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-tabs");e&&e.addEventListener(Pi,t=>{const o=t;this.isActive=o.detail===this.value})}updated(e){e.has("isActive")&&this.toggleAttribute("active",this.isActive)}render(){return d`
1104
1104
  <div class="tab-content" role="tabpanel" tabindex="0" part="tab-content">
1105
1105
  <slot></slot>
1106
1106
  </div>
@@ -1109,7 +1109,7 @@
1109
1109
  :host { display: block; font-family: var(--font-sans); flex: var(--_tab-fill-flex, 0 0 auto); min-height: 0; }
1110
1110
  :host(:not([active])) { display: none; }
1111
1111
  .tab-content { width: 100%; height: var(--_tab-fill-height, auto); overflow-x: hidden; overflow-y: auto; }
1112
- `;let vt=ls;g1([l()],vt.prototype,"value");g1([b()],vt.prototype,"isActive");customElements.get("anduin-tabs")||customElements.define("anduin-tabs",Pe);customElements.get("anduin-tabs-list")||customElements.define("anduin-tabs-list",gt);customElements.get("anduin-tab-trigger")||customElements.define("anduin-tab-trigger",$1);customElements.get("anduin-tab-content")||customElements.define("anduin-tab-content",vt);var n7=Object.defineProperty,Dt=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&n7(e,t,i),i};const b5="anduin-tag-close:click",s7={gray:"tag--light-gray",primary:"tag--light-primary",success:"tag--light-success",warning:"tag--light-warning",danger:"tag--light-danger",purple:"tag--light-purple",boldGray:"tag--bold-gray",boldPrimary:"tag--bold-primary",boldSuccess:"tag--bold-success",boldWarning:"tag--bold-warning",boldDanger:"tag--bold-danger",boldPurple:"tag--bold-purple",customAqua:"tag--custom-aqua",customBlue:"tag--custom-blue",customBlueGreen:"tag--custom-blue-green",customGreen:"tag--custom-green",customHotPink:"tag--custom-hot-pink",customIndigo:"tag--custom-indigo",customMagenta:"tag--custom-magenta",customOrange:"tag--custom-orange",customPink:"tag--custom-pink",customPurple:"tag--custom-purple",customRed:"tag--custom-red",customYellow:"tag--custom-yellow",customYellowGreen:"tag--custom-yellow-green",customYellowOrange:"tag--custom-yellow-orange"},r7={gray:"tag__icon--light-gray",primary:"tag__icon--light-primary",success:"tag__icon--light-success",warning:"tag__icon--light-warning",danger:"tag__icon--light-danger",purple:"tag__icon--light-purple",boldGray:"tag__icon--bold-gray",boldPrimary:"tag__icon--bold-primary",boldSuccess:"tag__icon--bold-success",boldWarning:"tag__icon--bold-warning",boldDanger:"tag__icon--bold-danger",boldPurple:"tag__icon--bold-purple",customRed:"tag__icon--custom-red",customBlue:"tag__icon--custom-blue",customIndigo:"tag__icon--custom-indigo",customPurple:"tag__icon--custom-purple",customGreen:"tag__icon--custom-green",customHotPink:"tag__icon--custom-hot-pink",customAqua:"tag__icon--custom-aqua",customOrange:"tag__icon--custom-orange",customYellowOrange:"tag__icon--custom-yellow-orange",customYellow:"tag__icon--custom-yellow",customYellowGreen:"tag__icon--custom-yellow-green",customMagenta:"tag__icon--custom-magenta",customBlueGreen:"tag__icon--custom-blue-green",customPink:"tag__icon--custom-pink"};function l7(){return Object.entries(h5).map(([n,e])=>`.tag--custom-${P0(n)} { background-color: ${e}; }`).join(`
1112
+ `;let vt=ls;f1([l()],vt.prototype,"value");f1([b()],vt.prototype,"isActive");customElements.get("anduin-tabs")||customElements.define("anduin-tabs",Pe);customElements.get("anduin-tabs-list")||customElements.define("anduin-tabs-list",ft);customElements.get("anduin-tab-trigger")||customElements.define("anduin-tab-trigger",$1);customElements.get("anduin-tab-content")||customElements.define("anduin-tab-content",vt);var n7=Object.defineProperty,Dt=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&n7(e,t,i),i};const b5="anduin-tag-close:click",s7={gray:"tag--light-gray",primary:"tag--light-primary",success:"tag--light-success",warning:"tag--light-warning",danger:"tag--light-danger",purple:"tag--light-purple",boldGray:"tag--bold-gray",boldPrimary:"tag--bold-primary",boldSuccess:"tag--bold-success",boldWarning:"tag--bold-warning",boldDanger:"tag--bold-danger",boldPurple:"tag--bold-purple",customAqua:"tag--custom-aqua",customBlue:"tag--custom-blue",customBlueGreen:"tag--custom-blue-green",customGreen:"tag--custom-green",customHotPink:"tag--custom-hot-pink",customIndigo:"tag--custom-indigo",customMagenta:"tag--custom-magenta",customOrange:"tag--custom-orange",customPink:"tag--custom-pink",customPurple:"tag--custom-purple",customRed:"tag--custom-red",customYellow:"tag--custom-yellow",customYellowGreen:"tag--custom-yellow-green",customYellowOrange:"tag--custom-yellow-orange"},r7={gray:"tag__icon--light-gray",primary:"tag__icon--light-primary",success:"tag__icon--light-success",warning:"tag__icon--light-warning",danger:"tag__icon--light-danger",purple:"tag__icon--light-purple",boldGray:"tag__icon--bold-gray",boldPrimary:"tag__icon--bold-primary",boldSuccess:"tag__icon--bold-success",boldWarning:"tag__icon--bold-warning",boldDanger:"tag__icon--bold-danger",boldPurple:"tag__icon--bold-purple",customRed:"tag__icon--custom-red",customBlue:"tag__icon--custom-blue",customIndigo:"tag__icon--custom-indigo",customPurple:"tag__icon--custom-purple",customGreen:"tag__icon--custom-green",customHotPink:"tag__icon--custom-hot-pink",customAqua:"tag__icon--custom-aqua",customOrange:"tag__icon--custom-orange",customYellowOrange:"tag__icon--custom-yellow-orange",customYellow:"tag__icon--custom-yellow",customYellowGreen:"tag__icon--custom-yellow-green",customMagenta:"tag__icon--custom-magenta",customBlueGreen:"tag__icon--custom-blue-green",customPink:"tag__icon--custom-pink"};function l7(){return Object.entries(h5).map(([n,e])=>`.tag--custom-${P0(n)} { background-color: ${e}; }`).join(`
1113
1113
  `)}const as=class as extends C{constructor(){super(...arguments),this.variant="gray",this.appearance="filled",this.icon="",this.iconColor="",this.iconColorUid="",this.disabled=!1}render(){const e=s7[this.variant]||"tag--light-gray",t=this.iconColorUid?u5(this.iconColorUid):B0(this.iconColor),o=t?"":r7[this.variant]||"tag__icon--light-gray",i=this.appearance==="outlined"?"tag--outlined":"";return d`
1114
1114
  <div class="tag ${e} ${i} ${this.disabled?"tag--disabled":""}" part="tag">
1115
1115
  ${this.icon?d`<anduin-icon
@@ -1117,7 +1117,7 @@
1117
1117
  size="12"
1118
1118
  class="tag__icon ${o}"
1119
1119
  style=${Da({color:t})}
1120
- ></anduin-icon>`:g}
1120
+ ></anduin-icon>`:f}
1121
1121
  <div class="tag__label"><slot></slot></div>
1122
1122
  <slot name="closeButton" class="tag__close"></slot>
1123
1123
  </div>
@@ -1212,9 +1212,9 @@
1212
1212
  }
1213
1213
  .tag-close__button:hover { opacity: 0.7; }
1214
1214
  .tag-close__button:active { opacity: 0.5; }
1215
- `;let io=ds;customElements.get("anduin-tag")||customElements.define("anduin-tag",Z1);customElements.get("anduin-tag-close")||customElements.define("anduin-tag-close",io);const w={fromAttribute:n=>n!==null&&n!=="false",toAttribute:n=>n?"":null};function P(n,e,t,o=!1){return n.dispatchEvent(new CustomEvent(e,{detail:{value:t},bubbles:!0,composed:!0,cancelable:o}))}function Ya(n,e,t,o={}){const i=o.offset??4,s=o.margin??8,r=o.cssMaxHeight??1/0,a=o.clampToRoom??!0,c=o.minHeight??96,[u,h]=t.split("-");let f=["top","bottom","left","right"].includes(u)?u:"bottom";const m=h==="start"||h==="end"?h:"center",v=n.getBoundingClientRect(),_=window.innerWidth,x=window.innerHeight,y=getComputedStyle(e),V=y.boxSizing==="border-box"?0:["paddingTop","paddingBottom","borderTopWidth","borderBottomWidth"].reduce((R,u1)=>R+(parseFloat(y[u1])||0),0),k=R=>{e.style.maxHeight=Number.isFinite(R)?`${Math.max(0,Math.floor(R-V))}px`:"none"};k(r);const M=e.getBoundingClientRect(),$=M.width;let N=M.height;if(f==="top"||f==="bottom"){const R=x-v.bottom-i-s,u1=v.top-i-s,ne=f==="bottom"?R:u1,Ft=f==="bottom"?u1:R;N>ne&&Ft>ne&&(f=f==="bottom"?"top":"bottom");const se=f==="bottom"?R:u1;if(a&&N>se){const Q3=Math.max(c,Math.floor(se));k(Math.min(Q3,r)),N=e.getBoundingClientRect().height}let Bt=m==="start"?v.left:m==="end"?v.right-$:v.left+v.width/2-$/2;Bt=Math.max(s,Math.min(Bt,_-$-s));const J3=f==="bottom"?v.bottom+i:v.top-i-N;e.style.left=`${Math.round(Bt)}px`,e.style.top=`${Math.round(Math.max(s,Math.min(J3,x-N-s)))}px`}else{const R=_-v.right-i-s,u1=v.left-i-s,ne=f==="right"?R:u1,Ft=f==="right"?u1:R;$>ne&&Ft>ne&&(f=f==="right"?"left":"right"),a&&N>x-2*s&&(k(Math.min(Math.floor(x-2*s),r)),N=e.getBoundingClientRect().height);let se=m==="start"?v.top:m==="end"?v.bottom-N:v.top+v.height/2-N/2;se=Math.max(s,Math.min(se,x-N-s));const Bt=f==="right"?v.right+i:v.left-i-$;e.style.top=`${Math.round(se)}px`,e.style.left=`${Math.round(Math.max(s,Math.min(Bt,_-$-s)))}px`}}var a7=Object.defineProperty,Q=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&a7(e,t,i),i};const Xa="anduin-tags-input:value-change",Ja="anduin-tags-input:blur",Qa="anduin-tags-input:submit",d7=`\r
1216
- `;function ea(n,e){const t=[];let o="";for(const i of n)e.includes(i)?(t.push(o),o=""):o+=i;return t.push(o),t}function c7(n,e){return n===e?!0:!Array.isArray(n)||!Array.isArray(e)||n.length!==e.length?!1:n.every((t,o)=>t===e[o])}function h7(n){return n instanceof bt||n instanceof ze||n instanceof _t||n instanceof N1}const u7="anduin-tags-input-list, anduin-tags-input-input, anduin-tags-input-clear, anduin-tags-input-suggestions";let p7=0;const _5=n=>`${n}-${++p7}`;function mt(n){const e=n.closest("anduin-tags-input");return e instanceof U?e:null}function a2(n){const e=n.closest("anduin-tags-input");e instanceof U&&e._register(n)}function d2(n){var e;(e=n._root)==null||e._unregister(n),n._root=null}const cs=class cs extends C{constructor(){super(...arguments),this.value=void 0,this.defaultValue=[],this.delimiters="",this.addOnBlur=!1,this.addOnTab=!1,this.tagMeta={},this.disabled=!1,this.readonly=!1,this.suggestionsOnly=!1,this._focused=!1,this._highlight=-1,this._parts=new Set,this._wantOpen=!1,this._active=null,this._syncQueued=!1,this._onFocusIn=()=>{var e;this._focused=!0,this._suggestionsPart&&this._editable&&((e=this._inputPart)!=null&&e.hasInputFocus)&&(this._wantOpen=!0,this._syncSuggestions())},this._onFocusOut=e=>{const t=e.relatedTarget;if(t&&(t===this||this.contains(t)))return;this._focused=!1,this._highlight=-1,this._wantOpen=!1;const o=this._inputPart;let i=(o==null?void 0:o.text)??"";this.addOnBlur&&this._editable&&o&&i.trim()&&this._commit(i)!=="refused"&&(o.text="",i=""),this._syncSuggestions(),this.dispatchEvent(new CustomEvent(Ja,{detail:i,bubbles:!0,composed:!0}))},this._onMouseDown=e=>{if(e.button!==0||!this._editable)return;const t=this._inputPart,o=t==null?void 0:t.inputEl;!t||!o||e.composedPath()[0]!==o&&(e.preventDefault(),t.hasInputFocus||t.focus())}}get isControlled(){return this.value!=null}get tags(){const e=this.isControlled?this.value:this.defaultValue;return Array.isArray(e)?e:[]}get highlightedIndex(){return this._highlight}metaFor(e){const t=this.tagMeta;return!t||typeof t!="object"||!Object.prototype.hasOwnProperty.call(t,e)?{}:t[e]??{}}isLocked(e){return!!this.metaFor(e).disabled}get _editable(){return!this.disabled&&!this.readonly}get clearVisible(){return this._editable&&this.tags.some(e=>!this.isLocked(e))}get _inputPart(){for(const e of this._parts)if(e instanceof ze)return e}get _hasListPart(){for(const e of this._parts)if(e instanceof bt)return!0;return!1}get _hasClearPart(){for(const e of this._parts)if(e instanceof _t)return!0;return!1}get _suggestionsPart(){for(const e of this._parts)if(e instanceof N1)return e}get suggestionsOpen(){var e;return!!((e=this._suggestionsPart)!=null&&e.shown)}_own(e){return Array.from(this.querySelectorAll(e)).filter(t=>t.closest("anduin-tags-input")===this)}get options(){return this._own("anduin-tags-input-option").filter(e=>e instanceof pe)}_navigable(){return this.options.filter(e=>!e.hidden&&!e.disabled)}_register(e){e._root&&e._root!==this&&e._root._unregister(e),e._root=this,this._parts.add(e),e.requestUpdate(),this.requestUpdate()}_unregister(e){var t;this._parts.delete(e)&&this.requestUpdate(),e instanceof N1&&(e.setShown(!1),this._setActive(null),(t=this._inputPart)==null||t.syncCombobox(null))}connectedCallback(){super.connectedCallback(),this.addEventListener("focusin",this._onFocusIn),this.addEventListener("focusout",this._onFocusOut),this.addEventListener("mousedown",this._onMouseDown);for(const e of Array.from(this.querySelectorAll(u7)))h7(e)&&e.closest("anduin-tags-input")===this&&this._register(e)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("focusin",this._onFocusIn),this.removeEventListener("focusout",this._onFocusOut),this.removeEventListener("mousedown",this._onMouseDown)}willUpdate(){(this._highlight>=this.tags.length||!this._editable)&&(this._highlight=-1)}updated(){for(const e of this._parts)e.requestUpdate();this._syncSuggestions()}focus(e){var t;(t=this._inputPart)==null||t.focus(e)}_propose(e){this.isControlled||(this.defaultValue=e),this.dispatchEvent(new CustomEvent(Xa,{detail:[...e],bubbles:!0,composed:!0}))}_resolve(e){const t=e.trim();if(!t)return null;if(!this._suggestionsPart&&!this.suggestionsOnly)return{value:t,offered:!1};const o=t.toLowerCase(),i=this.options,s=i.find(r=>r.value.toLowerCase()===o)??i.find(r=>!!r.label&&r.label.toLowerCase()===o);return s?s.disabled?null:{value:s.value,offered:!0}:this.suggestionsOnly?null:{value:t,offered:!1}}_commit(e){if(!e.trim())return"empty";const t=this._resolve(e);return t?t.offered&&this.tags.includes(t.value)?"duplicate":(this._propose([...this.tags,t.value]),"added"):"refused"}_removeAt(e){const t=this.tags;return!this._editable||e<0||e>=t.length||this.isLocked(t[e])?!1:(this._propose(t.filter((o,i)=>i!==e)),!0)}_clearAll(){if(!this._editable)return;const e=this.tags,t=e.filter(o=>this.isLocked(o));this._highlight=-1,t.length!==e.length&&this._propose(t)}_setHighlight(e){this._editable&&(this._highlight=e>=0&&e<this.tags.length?e:-1)}_focusInput(){const e=this._inputPart;e&&!e.hasInputFocus&&e.focus()}_onInputKeydown(e,t){if(!this._editable||e.isComposing||e.keyCode===229)return;const o=t.inputEl;if(!o)return;const i=this.tags,s=this._highlight;if(s>=0)switch(e.key){case"Backspace":case"Delete":e.preventDefault(),this.isLocked(i[s])||(this._highlight=-1,this._removeAt(s));return;case"ArrowLeft":e.preventDefault(),this._highlight=Math.max(0,s-1);return;case"ArrowRight":e.preventDefault(),this._highlight=s+1<i.length?s+1:-1;return;case"Shift":case"Control":case"Alt":case"Meta":return;default:this._highlight=-1}if(!(this._suggestionsPart&&this._onSuggestionsKeydown(e,o)))switch(e.key){case"Enter":{if(o.value.trim()){e.preventDefault(),this._commit(o.value)!=="refused"&&(o.value=""),this._syncSuggestions();return}this.dispatchEvent(new CustomEvent(Qa,{detail:[...i],bubbles:!0,composed:!0,cancelable:!0}))||e.preventDefault();return}case"Tab":if(this.addOnTab&&!e.shiftKey&&o.value.trim()){if(this._commit(o.value)==="refused")return;e.preventDefault(),o.value="",this._syncSuggestions()}return;case"Backspace":o.value===""&&i.length&&(e.preventDefault(),this._highlight=i.length-1);return;case"ArrowLeft":!e.shiftKey&&o.selectionStart===0&&o.selectionEnd===0&&i.length&&(e.preventDefault(),this._highlight=i.length-1);return}}_onSuggestionsKeydown(e,t){switch(e.key){case"ArrowDown":case"ArrowUp":{if(e.altKey||e.ctrlKey||e.metaKey)return!1;const o=this._navigable();if(!o.length)return!1;e.preventDefault(),this.suggestionsOpen||(this._wantOpen=!0,this._syncSuggestions());const i=this._active?o.indexOf(this._active):-1,s=e.key==="ArrowDown"?1:-1,r=i<0?s===1?0:o.length-1:(i+s+o.length)%o.length;return this._setActive(o[r],!0),!0}case"Enter":return!this.suggestionsOpen||!this._active||e.shiftKey?!1:(e.preventDefault(),this._pick(this._active),!0);case"Escape":return this.suggestionsOpen?(e.preventDefault(),e.stopPropagation(),this._wantOpen=!1,this._syncSuggestions(),!0):t.value?(e.preventDefault(),e.stopPropagation(),t.value="",this._syncSuggestions(),!0):!1}return!1}_onInputInput(e){this._highlight=-1,this._splitOnDelimiters(e),this._suggestionsPart&&this._editable&&(this._wantOpen=!0,this._setActive(null),this._syncSuggestions())}_splitOnDelimiters(e){const t=e.inputEl,o=this.delimiters;if(!t||!o||!this._editable)return;const i=t.value;if(![...i].some(u=>o.includes(u)))return;const s=ea(i,o),r=(s.pop()??"").replace(/^\s+/,"");if(!this._suggestionsPart&&!this.suggestionsOnly){const u=s.map(h=>h.trim()).filter(Boolean);t.value=r,u.length&&this._propose([...this.tags,...u]);return}const a=[],c=[];for(const u of s){if(!u.trim())continue;const h=this._resolve(u);h?h.offered&&(this.tags.includes(h.value)||a.includes(h.value))||a.push(h.value):c.push(u.trim())}t.value=[...c,r].filter(Boolean).join(`${o[0]} `),a.length&&this._propose([...this.tags,...a])}_onInputPaste(e,t){var f,m;if(!this._editable)return;const o=t.inputEl,i=((f=e.clipboardData)==null?void 0:f.getData("text/plain"))??"",s=d7+this.delimiters;if(!o||![...i].some(v=>s.includes(v)))return;e.preventDefault();const r=o.selectionStart??o.value.length,a=o.selectionEnd??o.value.length,c=o.value.slice(0,r)+i+o.value.slice(a),u=new Set(this.tags),h=[];for(const v of ea(c,s)){const _=(m=this._resolve(v))==null?void 0:m.value;!_||u.has(_)||(u.add(_),h.push(_))}o.value="",this._highlight=-1,h.length&&this._propose([...this.tags,...h]),this._syncSuggestions()}_setActive(e,t=!1){var o;this._active&&this._active!==e&&(this._active.highlighted=!1),this._active=e,e&&(e.highlighted=!0,t&&((o=this._suggestionsPart)==null||o.reveal(e))),this._syncAria()}_hoverOption(e){!this.suggestionsOpen||e.disabled||e.hidden||e===this._active||this._setActive(e)}_pick(e){if(!this._editable||e.disabled||e.hidden||mt(e)!==this)return;const t=this._inputPart;t&&(t.text=""),this._setActive(null),this._wantOpen=!0,this.tags.includes(e.value)||this._propose([...this.tags,e.value]),this._syncSuggestions(),this._focusInput()}_suggestionsChanged(){this._syncQueued||(this._syncQueued=!0,queueMicrotask(()=>{this._syncQueued=!1,this._syncSuggestions()}))}_matches(e,t){return(e.label||e.value).toLowerCase().includes(t.toLowerCase())}_syncSuggestions(){var u;const e=this._suggestionsPart;if(!e)return;const t=new Set(this.tags),o=(((u=this._inputPart)==null?void 0:u.text)??"").trim();let i=0;for(const h of this.options){const f=!t.has(h.value)&&(!o||this._matches(h,o));h.hidden===f&&(h.hidden=!f),f&&i++}for(const h of this._own("anduin-tags-input-group")){const m=Array.from(h.querySelectorAll("anduin-tags-input-option")).every(v=>v.hidden);h.hidden!==m&&(h.hidden=m)}const s=this._own("anduin-tags-input-empty"),r=!!o&&i===0;for(const h of s)h.hidden===r&&(h.hidden=!r);const a=this._own("anduin-tags-input-footer").length>0,c=this._wantOpen&&this._focused&&this._editable&&(i>0||r&&s.length>0||a);this._active&&(!c||this._active.hidden||this._active.disabled||mt(this._active)!==this)&&(this._active.highlighted=!1,this._active=null),e.setShown(c,this,i===0&&!(r&&s.length>0)),this._syncAria()}_syncAria(){const e=this._suggestionsPart,t=this._inputPart;if(t){if(!e){t.syncCombobox(null);return}t.syncCombobox({expanded:e.shown,listbox:e,active:e.shown?this._active:null})}}render(){const e=["field",this._focused&&this._editable?"field--focused":"",this._hasClearPart&&this.clearVisible?"field--has-clear":"",this._hasListPart&&this.tags.length>0?"field--has-tags":"",this.readonly?"field--readonly":"",this.disabled?"field--disabled":""].filter(Boolean).join(" ");return d`
1217
- <div class=${e} part="field" aria-disabled=${this.disabled?"true":g}>
1215
+ `;let io=ds;customElements.get("anduin-tag")||customElements.define("anduin-tag",Z1);customElements.get("anduin-tag-close")||customElements.define("anduin-tag-close",io);const w={fromAttribute:n=>n!==null&&n!=="false",toAttribute:n=>n?"":null};function P(n,e,t,o=!1){return n.dispatchEvent(new CustomEvent(e,{detail:{value:t},bubbles:!0,composed:!0,cancelable:o}))}function Ya(n,e,t,o={}){const i=o.offset??4,s=o.margin??8,r=o.cssMaxHeight??1/0,a=o.clampToRoom??!0,c=o.minHeight??96,[u,h]=t.split("-");let g=["top","bottom","left","right"].includes(u)?u:"bottom";const m=h==="start"||h==="end"?h:"center",v=n.getBoundingClientRect(),_=window.innerWidth,x=window.innerHeight,y=getComputedStyle(e),V=y.boxSizing==="border-box"?0:["paddingTop","paddingBottom","borderTopWidth","borderBottomWidth"].reduce((R,u1)=>R+(parseFloat(y[u1])||0),0),L=R=>{e.style.maxHeight=Number.isFinite(R)?`${Math.max(0,Math.floor(R-V))}px`:"none"};L(r);const M=e.getBoundingClientRect(),$=M.width;let N=M.height;if(g==="top"||g==="bottom"){const R=x-v.bottom-i-s,u1=v.top-i-s,ne=g==="bottom"?R:u1,Ft=g==="bottom"?u1:R;N>ne&&Ft>ne&&(g=g==="bottom"?"top":"bottom");const se=g==="bottom"?R:u1;if(a&&N>se){const Q3=Math.max(c,Math.floor(se));L(Math.min(Q3,r)),N=e.getBoundingClientRect().height}let Bt=m==="start"?v.left:m==="end"?v.right-$:v.left+v.width/2-$/2;Bt=Math.max(s,Math.min(Bt,_-$-s));const J3=g==="bottom"?v.bottom+i:v.top-i-N;e.style.left=`${Math.round(Bt)}px`,e.style.top=`${Math.round(Math.max(s,Math.min(J3,x-N-s)))}px`}else{const R=_-v.right-i-s,u1=v.left-i-s,ne=g==="right"?R:u1,Ft=g==="right"?u1:R;$>ne&&Ft>ne&&(g=g==="right"?"left":"right"),a&&N>x-2*s&&(L(Math.min(Math.floor(x-2*s),r)),N=e.getBoundingClientRect().height);let se=m==="start"?v.top:m==="end"?v.bottom-N:v.top+v.height/2-N/2;se=Math.max(s,Math.min(se,x-N-s));const Bt=g==="right"?v.right+i:v.left-i-$;e.style.top=`${Math.round(se)}px`,e.style.left=`${Math.round(Math.max(s,Math.min(Bt,_-$-s)))}px`}}var a7=Object.defineProperty,Q=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&a7(e,t,i),i};const Xa="anduin-tags-input:value-change",Ja="anduin-tags-input:blur",Qa="anduin-tags-input:submit",d7=`\r
1216
+ `;function ea(n,e){const t=[];let o="";for(const i of n)e.includes(i)?(t.push(o),o=""):o+=i;return t.push(o),t}function c7(n,e){return n===e?!0:!Array.isArray(n)||!Array.isArray(e)||n.length!==e.length?!1:n.every((t,o)=>t===e[o])}function h7(n){return n instanceof bt||n instanceof ze||n instanceof _t||n instanceof N1}const u7="anduin-tags-input-list, anduin-tags-input-input, anduin-tags-input-clear, anduin-tags-input-suggestions";let p7=0;const _5=n=>`${n}-${++p7}`;function mt(n){const e=n.closest("anduin-tags-input");return e instanceof U?e:null}function a2(n){const e=n.closest("anduin-tags-input");e instanceof U&&e._register(n)}function d2(n){var e;(e=n._root)==null||e._unregister(n),n._root=null}const cs=class cs extends C{constructor(){super(...arguments),this.value=void 0,this.defaultValue=[],this.delimiters="",this.addOnBlur=!1,this.addOnTab=!1,this.tagMeta={},this.disabled=!1,this.readonly=!1,this.suggestionsOnly=!1,this._focused=!1,this._highlight=-1,this._parts=new Set,this._wantOpen=!1,this._active=null,this._syncQueued=!1,this._onFocusIn=()=>{var e;this._focused=!0,this._suggestionsPart&&this._editable&&((e=this._inputPart)!=null&&e.hasInputFocus)&&(this._wantOpen=!0,this._syncSuggestions())},this._onFocusOut=e=>{const t=e.relatedTarget;if(t&&(t===this||this.contains(t)))return;this._focused=!1,this._highlight=-1,this._wantOpen=!1;const o=this._inputPart;let i=(o==null?void 0:o.text)??"";this.addOnBlur&&this._editable&&o&&i.trim()&&this._commit(i)!=="refused"&&(o.text="",i=""),this._syncSuggestions(),this.dispatchEvent(new CustomEvent(Ja,{detail:i,bubbles:!0,composed:!0}))},this._onMouseDown=e=>{if(e.button!==0||!this._editable)return;const t=this._inputPart,o=t==null?void 0:t.inputEl;!t||!o||e.composedPath()[0]!==o&&(e.preventDefault(),t.hasInputFocus||t.focus())}}get isControlled(){return this.value!=null}get tags(){const e=this.isControlled?this.value:this.defaultValue;return Array.isArray(e)?e:[]}get highlightedIndex(){return this._highlight}metaFor(e){const t=this.tagMeta;return!t||typeof t!="object"||!Object.prototype.hasOwnProperty.call(t,e)?{}:t[e]??{}}isLocked(e){return!!this.metaFor(e).disabled}get _editable(){return!this.disabled&&!this.readonly}get clearVisible(){return this._editable&&this.tags.some(e=>!this.isLocked(e))}get _inputPart(){for(const e of this._parts)if(e instanceof ze)return e}get _hasListPart(){for(const e of this._parts)if(e instanceof bt)return!0;return!1}get _hasClearPart(){for(const e of this._parts)if(e instanceof _t)return!0;return!1}get _suggestionsPart(){for(const e of this._parts)if(e instanceof N1)return e}get suggestionsOpen(){var e;return!!((e=this._suggestionsPart)!=null&&e.shown)}_own(e){return Array.from(this.querySelectorAll(e)).filter(t=>t.closest("anduin-tags-input")===this)}get options(){return this._own("anduin-tags-input-option").filter(e=>e instanceof pe)}_navigable(){return this.options.filter(e=>!e.hidden&&!e.disabled)}_register(e){e._root&&e._root!==this&&e._root._unregister(e),e._root=this,this._parts.add(e),e.requestUpdate(),this.requestUpdate()}_unregister(e){var t;this._parts.delete(e)&&this.requestUpdate(),e instanceof N1&&(e.setShown(!1),this._setActive(null),(t=this._inputPart)==null||t.syncCombobox(null))}connectedCallback(){super.connectedCallback(),this.addEventListener("focusin",this._onFocusIn),this.addEventListener("focusout",this._onFocusOut),this.addEventListener("mousedown",this._onMouseDown);for(const e of Array.from(this.querySelectorAll(u7)))h7(e)&&e.closest("anduin-tags-input")===this&&this._register(e)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("focusin",this._onFocusIn),this.removeEventListener("focusout",this._onFocusOut),this.removeEventListener("mousedown",this._onMouseDown)}willUpdate(){(this._highlight>=this.tags.length||!this._editable)&&(this._highlight=-1)}updated(){for(const e of this._parts)e.requestUpdate();this._syncSuggestions()}focus(e){var t;(t=this._inputPart)==null||t.focus(e)}_propose(e){this.isControlled||(this.defaultValue=e),this.dispatchEvent(new CustomEvent(Xa,{detail:[...e],bubbles:!0,composed:!0}))}_resolve(e){const t=e.trim();if(!t)return null;if(!this._suggestionsPart&&!this.suggestionsOnly)return{value:t,offered:!1};const o=t.toLowerCase(),i=this.options,s=i.find(r=>r.value.toLowerCase()===o)??i.find(r=>!!r.label&&r.label.toLowerCase()===o);return s?s.disabled?null:{value:s.value,offered:!0}:this.suggestionsOnly?null:{value:t,offered:!1}}_commit(e){if(!e.trim())return"empty";const t=this._resolve(e);return t?t.offered&&this.tags.includes(t.value)?"duplicate":(this._propose([...this.tags,t.value]),"added"):"refused"}_removeAt(e){const t=this.tags;return!this._editable||e<0||e>=t.length||this.isLocked(t[e])?!1:(this._propose(t.filter((o,i)=>i!==e)),!0)}_clearAll(){if(!this._editable)return;const e=this.tags,t=e.filter(o=>this.isLocked(o));this._highlight=-1,t.length!==e.length&&this._propose(t)}_setHighlight(e){this._editable&&(this._highlight=e>=0&&e<this.tags.length?e:-1)}_focusInput(){const e=this._inputPart;e&&!e.hasInputFocus&&e.focus()}_onInputKeydown(e,t){if(!this._editable||e.isComposing||e.keyCode===229)return;const o=t.inputEl;if(!o)return;const i=this.tags,s=this._highlight;if(s>=0)switch(e.key){case"Backspace":case"Delete":e.preventDefault(),this.isLocked(i[s])||(this._highlight=-1,this._removeAt(s));return;case"ArrowLeft":e.preventDefault(),this._highlight=Math.max(0,s-1);return;case"ArrowRight":e.preventDefault(),this._highlight=s+1<i.length?s+1:-1;return;case"Shift":case"Control":case"Alt":case"Meta":return;default:this._highlight=-1}if(!(this._suggestionsPart&&this._onSuggestionsKeydown(e,o)))switch(e.key){case"Enter":{if(o.value.trim()){e.preventDefault(),this._commit(o.value)!=="refused"&&(o.value=""),this._syncSuggestions();return}this.dispatchEvent(new CustomEvent(Qa,{detail:[...i],bubbles:!0,composed:!0,cancelable:!0}))||e.preventDefault();return}case"Tab":if(this.addOnTab&&!e.shiftKey&&o.value.trim()){if(this._commit(o.value)==="refused")return;e.preventDefault(),o.value="",this._syncSuggestions()}return;case"Backspace":o.value===""&&i.length&&(e.preventDefault(),this._highlight=i.length-1);return;case"ArrowLeft":!e.shiftKey&&o.selectionStart===0&&o.selectionEnd===0&&i.length&&(e.preventDefault(),this._highlight=i.length-1);return}}_onSuggestionsKeydown(e,t){switch(e.key){case"ArrowDown":case"ArrowUp":{if(e.altKey||e.ctrlKey||e.metaKey)return!1;const o=this._navigable();if(!o.length)return!1;e.preventDefault(),this.suggestionsOpen||(this._wantOpen=!0,this._syncSuggestions());const i=this._active?o.indexOf(this._active):-1,s=e.key==="ArrowDown"?1:-1,r=i<0?s===1?0:o.length-1:(i+s+o.length)%o.length;return this._setActive(o[r],!0),!0}case"Enter":return!this.suggestionsOpen||!this._active||e.shiftKey?!1:(e.preventDefault(),this._pick(this._active),!0);case"Escape":return this.suggestionsOpen?(e.preventDefault(),e.stopPropagation(),this._wantOpen=!1,this._syncSuggestions(),!0):t.value?(e.preventDefault(),e.stopPropagation(),t.value="",this._syncSuggestions(),!0):!1}return!1}_onInputInput(e){this._highlight=-1,this._splitOnDelimiters(e),this._suggestionsPart&&this._editable&&(this._wantOpen=!0,this._setActive(null),this._syncSuggestions())}_splitOnDelimiters(e){const t=e.inputEl,o=this.delimiters;if(!t||!o||!this._editable)return;const i=t.value;if(![...i].some(u=>o.includes(u)))return;const s=ea(i,o),r=(s.pop()??"").replace(/^\s+/,"");if(!this._suggestionsPart&&!this.suggestionsOnly){const u=s.map(h=>h.trim()).filter(Boolean);t.value=r,u.length&&this._propose([...this.tags,...u]);return}const a=[],c=[];for(const u of s){if(!u.trim())continue;const h=this._resolve(u);h?h.offered&&(this.tags.includes(h.value)||a.includes(h.value))||a.push(h.value):c.push(u.trim())}t.value=[...c,r].filter(Boolean).join(`${o[0]} `),a.length&&this._propose([...this.tags,...a])}_onInputPaste(e,t){var g,m;if(!this._editable)return;const o=t.inputEl,i=((g=e.clipboardData)==null?void 0:g.getData("text/plain"))??"",s=d7+this.delimiters;if(!o||![...i].some(v=>s.includes(v)))return;e.preventDefault();const r=o.selectionStart??o.value.length,a=o.selectionEnd??o.value.length,c=o.value.slice(0,r)+i+o.value.slice(a),u=new Set(this.tags),h=[];for(const v of ea(c,s)){const _=(m=this._resolve(v))==null?void 0:m.value;!_||u.has(_)||(u.add(_),h.push(_))}o.value="",this._highlight=-1,h.length&&this._propose([...this.tags,...h]),this._syncSuggestions()}_setActive(e,t=!1){var o;this._active&&this._active!==e&&(this._active.highlighted=!1),this._active=e,e&&(e.highlighted=!0,t&&((o=this._suggestionsPart)==null||o.reveal(e))),this._syncAria()}_hoverOption(e){!this.suggestionsOpen||e.disabled||e.hidden||e===this._active||this._setActive(e)}_pick(e){if(!this._editable||e.disabled||e.hidden||mt(e)!==this)return;const t=this._inputPart;t&&(t.text=""),this._setActive(null),this._wantOpen=!0,this.tags.includes(e.value)||this._propose([...this.tags,e.value]),this._syncSuggestions(),this._focusInput()}_suggestionsChanged(){this._syncQueued||(this._syncQueued=!0,queueMicrotask(()=>{this._syncQueued=!1,this._syncSuggestions()}))}_matches(e,t){return(e.label||e.value).toLowerCase().includes(t.toLowerCase())}_syncSuggestions(){var u;const e=this._suggestionsPart;if(!e)return;const t=new Set(this.tags),o=(((u=this._inputPart)==null?void 0:u.text)??"").trim();let i=0;for(const h of this.options){const g=!t.has(h.value)&&(!o||this._matches(h,o));h.hidden===g&&(h.hidden=!g),g&&i++}for(const h of this._own("anduin-tags-input-group")){const m=Array.from(h.querySelectorAll("anduin-tags-input-option")).every(v=>v.hidden);h.hidden!==m&&(h.hidden=m)}const s=this._own("anduin-tags-input-empty"),r=!!o&&i===0;for(const h of s)h.hidden===r&&(h.hidden=!r);const a=this._own("anduin-tags-input-footer").length>0,c=this._wantOpen&&this._focused&&this._editable&&(i>0||r&&s.length>0||a);this._active&&(!c||this._active.hidden||this._active.disabled||mt(this._active)!==this)&&(this._active.highlighted=!1,this._active=null),e.setShown(c,this,i===0&&!(r&&s.length>0)),this._syncAria()}_syncAria(){const e=this._suggestionsPart,t=this._inputPart;if(t){if(!e){t.syncCombobox(null);return}t.syncCombobox({expanded:e.shown,listbox:e,active:e.shown?this._active:null})}}render(){const e=["field",this._focused&&this._editable?"field--focused":"",this._hasClearPart&&this.clearVisible?"field--has-clear":"",this._hasListPart&&this.tags.length>0?"field--has-tags":"",this.readonly?"field--readonly":"",this.disabled?"field--disabled":""].filter(Boolean).join(" ");return d`
1217
+ <div class=${e} part="field" aria-disabled=${this.disabled?"true":f}>
1218
1218
  <slot></slot>
1219
1219
  </div>
1220
1220
  <!-- Outside the field: a press in the panel would otherwise be a press on
@@ -1260,12 +1260,12 @@
1260
1260
  .field--readonly { background-color: var(--color-secondary); cursor: default; }
1261
1261
  .field--disabled { color: var(--color-muted-foreground); background-color: var(--color-disabled); cursor: not-allowed; }
1262
1262
  .field--readonly:active, .field--disabled:active { box-shadow: none; }
1263
- `;let U=cs;Q([l({type:Array})],U.prototype,"value");Q([l({type:Array,attribute:"default-value",hasChanged:(n,e)=>!c7(n,e)})],U.prototype,"defaultValue");Q([l()],U.prototype,"delimiters");Q([l({type:Boolean,attribute:"add-on-blur"})],U.prototype,"addOnBlur");Q([l({type:Boolean,attribute:"add-on-tab"})],U.prototype,"addOnTab");Q([l({type:Object,attribute:"tag-meta"})],U.prototype,"tagMeta");Q([l({type:Boolean,reflect:!0})],U.prototype,"disabled");Q([l({type:Boolean,reflect:!0})],U.prototype,"readonly");Q([l({type:Boolean,attribute:"suggestions-only"})],U.prototype,"suggestionsOnly");Q([b()],U.prototype,"_focused");Q([b()],U.prototype,"_highlight");const hs=class hs extends C{constructor(){super(...arguments),this._root=null,this._onRemove=e=>{e.stopPropagation();const t=this._root,o=this._indexFromPath(e);!t||o<0||(t._removeAt(o),t._focusInput())}}connectedCallback(){super.connectedCallback(),a2(this)}disconnectedCallback(){super.disconnectedCallback(),d2(this)}firstUpdated(){this.renderRoot.addEventListener(b5,this._onRemove)}_indexFromPath(e){for(const t of e.composedPath())if(t instanceof HTMLElement&&t.classList.contains("chip")&&t.dataset.index!==void 0)return Number(t.dataset.index);return-1}_onChipClick(e){var o;if(e.composedPath().some(i=>i.localName==="anduin-tag-close"))return;const t=this._indexFromPath(e);(o=this._root)==null||o._setHighlight(t)}render(){const e=this._root;if(!e)return g;const t=e._editable,o=e.highlightedIndex;return d`${e.tags.map((i,s)=>{const r=e.metaFor(i),a=!!r.disabled,c=s===o,u=d`<anduin-tag
1263
+ `;let U=cs;Q([l({type:Array})],U.prototype,"value");Q([l({type:Array,attribute:"default-value",hasChanged:(n,e)=>!c7(n,e)})],U.prototype,"defaultValue");Q([l()],U.prototype,"delimiters");Q([l({type:Boolean,attribute:"add-on-blur"})],U.prototype,"addOnBlur");Q([l({type:Boolean,attribute:"add-on-tab"})],U.prototype,"addOnTab");Q([l({type:Object,attribute:"tag-meta"})],U.prototype,"tagMeta");Q([l({type:Boolean,reflect:!0})],U.prototype,"disabled");Q([l({type:Boolean,reflect:!0})],U.prototype,"readonly");Q([l({type:Boolean,attribute:"suggestions-only"})],U.prototype,"suggestionsOnly");Q([b()],U.prototype,"_focused");Q([b()],U.prototype,"_highlight");const hs=class hs extends C{constructor(){super(...arguments),this._root=null,this._onRemove=e=>{e.stopPropagation();const t=this._root,o=this._indexFromPath(e);!t||o<0||(t._removeAt(o),t._focusInput())}}connectedCallback(){super.connectedCallback(),a2(this)}disconnectedCallback(){super.disconnectedCallback(),d2(this)}firstUpdated(){this.renderRoot.addEventListener(b5,this._onRemove)}_indexFromPath(e){for(const t of e.composedPath())if(t instanceof HTMLElement&&t.classList.contains("chip")&&t.dataset.index!==void 0)return Number(t.dataset.index);return-1}_onChipClick(e){var o;if(e.composedPath().some(i=>i.localName==="anduin-tag-close"))return;const t=this._indexFromPath(e);(o=this._root)==null||o._setHighlight(t)}render(){const e=this._root;if(!e)return f;const t=e._editable,o=e.highlightedIndex;return d`${e.tags.map((i,s)=>{const r=e.metaFor(i),a=!!r.disabled,c=s===o,u=d`<anduin-tag
1264
1264
  class="chip__tag"
1265
1265
  part="tag"
1266
1266
  variant=${r.variant||"gray"}
1267
1267
  ?disabled=${e.disabled||a}
1268
- >${r.label??i}${t&&!a?d`<anduin-tag-close slot="closeButton" part="remove"></anduin-tag-close>`:g}</anduin-tag>`;return d`<span
1268
+ >${r.label??i}${t&&!a?d`<anduin-tag-close slot="closeButton" part="remove"></anduin-tag-close>`:f}</anduin-tag>`;return d`<span
1269
1269
  class="chip ${c?"chip--highlighted":""}"
1270
1270
  part="chip${c?" chip-highlighted":""}${a?" chip-locked":""}"
1271
1271
  role="listitem"
@@ -1292,7 +1292,7 @@
1292
1292
  part="input"
1293
1293
  type="text"
1294
1294
  autocomplete="off"
1295
- placeholder=${this.placeholder||g}
1295
+ placeholder=${this.placeholder||f}
1296
1296
  ?disabled=${!!(e!=null&&e.disabled)}
1297
1297
  @keydown=${t=>e==null?void 0:e._onInputKeydown(t,this)}
1298
1298
  @input=${()=>e==null?void 0:e._onInputInput(this)}
@@ -1386,15 +1386,15 @@
1386
1386
  :host([data-highlighted]) .option, .option:active { background-color: var(--color-accent-active); }
1387
1387
  :host([disabled]:not([disabled='false'])) .option { opacity: 0.5; cursor: not-allowed; }
1388
1388
  :host([disabled]:not([disabled='false'])) .option:active { background-color: transparent; }
1389
- `;let pe=Cs;Q([l()],pe.prototype,"value");Q([l()],pe.prototype,"label");Q([l({converter:w,reflect:!0})],pe.prototype,"disabled");const fs=class fs extends C{constructor(){super(...arguments),this._root=null}connectedCallback(){var t;super.connectedCallback(),this.setAttribute("role","group");const e=this.querySelector("anduin-tags-input-label");e&&(e.id||(e.id=_5("anduin-tags-input-label")),this.setAttribute("aria-labelledby",e.id)),this._root=mt(this),(t=this._root)==null||t._suggestionsChanged()}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._root)==null||e._suggestionsChanged(),this._root=null}render(){return d`<slot></slot>`}};fs.styles=p`
1389
+ `;let pe=Cs;Q([l()],pe.prototype,"value");Q([l()],pe.prototype,"label");Q([l({converter:w,reflect:!0})],pe.prototype,"disabled");const gs=class gs extends C{constructor(){super(...arguments),this._root=null}connectedCallback(){var t;super.connectedCallback(),this.setAttribute("role","group");const e=this.querySelector("anduin-tags-input-label");e&&(e.id||(e.id=_5("anduin-tags-input-label")),this.setAttribute("aria-labelledby",e.id)),this._root=mt(this),(t=this._root)==null||t._suggestionsChanged()}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._root)==null||e._suggestionsChanged(),this._root=null}render(){return d`<slot></slot>`}};gs.styles=p`
1390
1390
  :host { display: flex; flex-direction: column; }
1391
1391
  :host([hidden]) { display: none; }
1392
- `;let oo=fs;const gs=class gs extends C{render(){return d`<slot></slot>`}};gs.styles=p`
1392
+ `;let oo=gs;const fs=class fs extends C{render(){return d`<slot></slot>`}};fs.styles=p`
1393
1393
  :host {
1394
1394
  display: block; padding: 4px 12px; font-size: 12px; line-height: 16px; font-weight: 500;
1395
1395
  color: var(--color-muted-foreground); user-select: none; text-align: left;
1396
1396
  }
1397
- `;let no=gs;const vs=class vs extends C{constructor(){super(...arguments),this._root=null}connectedCallback(){var e;super.connectedCallback(),this.setAttribute("role","status"),this.setAttribute("aria-live","polite"),this.hidden=!0,this._root=mt(this),(e=this._root)==null||e._suggestionsChanged()}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._root)==null||e._suggestionsChanged(),this._root=null}render(){return d`<slot></slot>`}};vs.styles=p`
1397
+ `;let no=fs;const vs=class vs extends C{constructor(){super(...arguments),this._root=null}connectedCallback(){var e;super.connectedCallback(),this.setAttribute("role","status"),this.setAttribute("aria-live","polite"),this.hidden=!0,this._root=mt(this),(e=this._root)==null||e._suggestionsChanged()}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._root)==null||e._suggestionsChanged(),this._root=null}render(){return d`<slot></slot>`}};vs.styles=p`
1398
1398
  :host { display: block; padding: 8px; color: var(--color-subtle-foreground); text-align: center; }
1399
1399
  :host([hidden]) { display: none; }
1400
1400
  `;let so=vs;const ms=class ms extends C{constructor(){super(...arguments),this._root=null}connectedCallback(){var e;super.connectedCallback(),this.parentElement instanceof N1&&(this.slot="footer"),this._root=mt(this),(e=this._root)==null||e._suggestionsChanged()}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._root)==null||e._suggestionsChanged(),this._root=null}render(){return d`<slot></slot>`}};ms.styles=p`
@@ -1446,7 +1446,7 @@
1446
1446
  @click=${this.onClick}
1447
1447
  >
1448
1448
  <div class="toggle-item__content">
1449
- ${this.startIcon?d`<div class="toggle-item__icon"><anduin-icon name="${this.startIcon}" size="${this.groupSize==="small"?12:16}"></anduin-icon></div>`:g}
1449
+ ${this.startIcon?d`<div class="toggle-item__icon"><anduin-icon name="${this.startIcon}" size="${this.groupSize==="small"?12:16}"></anduin-icon></div>`:f}
1450
1450
  <slot></slot>
1451
1451
  </div>
1452
1452
  </button>
@@ -1485,7 +1485,7 @@
1485
1485
  .toggle-item:hover .toggle-item__icon { color: var(--color-muted-foreground); }
1486
1486
  .toggle-item--selected .toggle-item__icon { color: var(--color-muted-foreground); }
1487
1487
  .toggle-item--variant-primary.toggle-item--selected .toggle-item__icon { color: var(--color-primary-icon); }
1488
- `;let x1=_s;l1([l({reflect:!0})],x1.prototype,"value");l1([l({attribute:"start-icon"})],x1.prototype,"startIcon");l1([l({type:Boolean})],x1.prototype,"disabled");l1([l({attribute:!1})],x1.prototype,"selected");l1([l({attribute:!1})],x1.prototype,"groupSize");l1([l({attribute:!1})],x1.prototype,"groupVariant");l1([l({attribute:!1})],x1.prototype,"groupMode");function y2(n){return n.split(" ").map(e=>e.trim()).filter(Boolean)}customElements.get("anduin-toggle-group")||customElements.define("anduin-toggle-group",y1);customElements.get("anduin-toggle-group-item")||customElements.define("anduin-toggle-group-item",x1);var f7=Object.defineProperty,g7=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&f7(e,t,i),i};const n4="anduin-well-close:click",ys=class ys extends C{constructor(){super(...arguments),this.variant="gray"}render(){return d`
1488
+ `;let x1=_s;l1([l({reflect:!0})],x1.prototype,"value");l1([l({attribute:"start-icon"})],x1.prototype,"startIcon");l1([l({type:Boolean})],x1.prototype,"disabled");l1([l({attribute:!1})],x1.prototype,"selected");l1([l({attribute:!1})],x1.prototype,"groupSize");l1([l({attribute:!1})],x1.prototype,"groupVariant");l1([l({attribute:!1})],x1.prototype,"groupMode");function y2(n){return n.split(" ").map(e=>e.trim()).filter(Boolean)}customElements.get("anduin-toggle-group")||customElements.define("anduin-toggle-group",y1);customElements.get("anduin-toggle-group-item")||customElements.define("anduin-toggle-group-item",x1);var g7=Object.defineProperty,f7=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&g7(e,t,i),i};const n4="anduin-well-close:click",ys=class ys extends C{constructor(){super(...arguments),this.variant="gray"}render(){return d`
1489
1489
  <div class="well well--${this.variant}" part="well">
1490
1490
  <slot
1491
1491
  name="icon"
@@ -1579,7 +1579,7 @@
1579
1579
  .well__icon--warning {
1580
1580
  color: var(--color-warning-active);
1581
1581
  }
1582
- `;let li=ys;g7([l()],li.prototype,"variant");const xs=class xs extends C{onClick(){this.dispatchEvent(new CustomEvent(n4,{bubbles:!0,composed:!0}))}render(){return d`
1582
+ `;let li=ys;f7([l()],li.prototype,"variant");const xs=class xs extends C{onClick(){this.dispatchEvent(new CustomEvent(n4,{bubbles:!0,composed:!0}))}render(){return d`
1583
1583
  <button
1584
1584
  class="well-close__button"
1585
1585
  part="well-close"
@@ -1611,7 +1611,7 @@
1611
1611
  .well-close__button:active {
1612
1612
  background-color: var(--color-accent-active);
1613
1613
  }
1614
- `;let ao=xs;customElements.get("anduin-well")||customElements.define("anduin-well",li);customElements.get("anduin-well-close")||customElements.define("anduin-well-close",ao);const v7=["top","bottom","left","right"],m7=["start","center","end"],E1=8;function y5(n,e){if(!n)return e;const[t,o="center"]=n.split("-");return!v7.includes(t)||!m7.includes(o)?e:`${t}-${o}`}const Gi=n=>n.split("-")[0],O2=n=>n.split("-")[1],ia={top:"bottom",bottom:"top",left:"right",right:"left"};function x2(n,e,t,o,i){const s=Gi(o),r=O2(o);if(s==="top"||s==="bottom"){const u=s==="top"?n.top-t-i:n.bottom+i;return{left:r==="start"?n.left:r==="end"?n.right-e:n.left+n.width/2-e/2,top:u}}const a=s==="left"?n.left-e-i:n.right+i,c=r==="start"?n.top:r==="end"?n.bottom-t:n.top+n.height/2-t/2;return{left:a,top:c}}function w2(n,e,t){const o=window.innerWidth,i=window.innerHeight,s=(r,a)=>Math.max(0,Math.min(r,a-2*E1));switch(e){case"top":return s(n.top-t-E1,i);case"bottom":return s(i-n.bottom-t-E1,i);case"left":return s(n.left-t-E1,o);case"right":return s(o-n.right-t-E1,o)}}function s4(n,e,t,o,i=4){const s=window.innerWidth,r=window.innerHeight;if(n.right<0||n.bottom<0||n.left>s||n.top>r)return null;const a=Gi(o),c=x2(n,e,t,o,i),u=a==="top"?c.top>=0:a==="bottom"?c.top+t<=r:a==="left"?c.left>=0:c.left+e<=s,h=w2(n,ia[a],i)>w2(n,a,i);let f=u||!h?o:`${ia[a]}-${O2(o)}`;const m=Gi(f),v=O2(f),_=x2(n,e,t,f,i);(m==="top"||m==="bottom")&&v==="start"&&_.left+e>s?f=`${m}-end`:(m==="top"||m==="bottom")&&v==="end"&&_.left<0?f=`${m}-start`:(m==="left"||m==="right")&&v==="start"&&_.top+t>r?f=`${m}-end`:(m==="left"||m==="right")&&v==="end"&&_.top<0&&(f=`${m}-start`);const x=x2(n,e,t,f,i),y=(N,R,u1)=>Math.max(R,Math.min(N,u1)),V=Math.round(y(x.left,E1,s-e-E1)),k=Math.round(y(x.top,E1,r-t-E1)),M=Gi(f),$=M==="left"||M==="right"?Math.max(r-2*E1,0):w2(n,M,i);return{placement:f,left:V,top:k,availableHeight:$}}function r4(n){let e=0,t=!1;const o=()=>{t||(n(),e=requestAnimationFrame(o))};return o(),()=>{t=!0,cancelAnimationFrame(e)}}const Se=[];function l4(n){if(n.key!=="Escape"||n.defaultPrevented)return;const e=Se[Se.length-1];e&&(n.preventDefault(),e.onEscape())}function a4(n){ai(n),Se.length===0&&document.addEventListener("keydown",l4),Se.push(n)}function ai(n){const e=Se.indexOf(n);e>=0&&Se.splice(e,1),Se.length===0&&document.removeEventListener("keydown",l4)}const b7='a[href], button:not([disabled]), input:not([disabled]):not([type="hidden"]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"]), [contenteditable="true"]';function x5(n){const e=[],t=o=>{if(o instanceof HTMLSlotElement){o.assignedElements({flatten:!0}).forEach(t);return}o.matches(b7)&&o.getClientRects().length>0&&e.push(o);const i=o.shadowRoot?o.shadowRoot.children:o.children;Array.from(i).forEach(t)};return t(n),e}function d4(){var e;let n=document.activeElement;for(;(e=n==null?void 0:n.shadowRoot)!=null&&e.activeElement;)n=n.shadowRoot.activeElement;return n}function c4(n){let e=d4();for(;e;){if(e===n||n.contains(e))return!0;const t=e.getRootNode();e=t instanceof ShadowRoot?t.host:null}return!1}function _7(n,e){const t=x5(n);if(t.length===0){e.preventDefault();return}const o=d4(),i=o?t.indexOf(o):-1;e.shiftKey&&i<=0?(e.preventDefault(),t[t.length-1].focus()):!e.shiftKey&&(i===-1||i===t.length-1)&&(e.preventDefault(),t[0].focus())}function h4(n,e,t){const o=n==null?void 0:n.firstElementChild;o&&(o.setAttribute("aria-expanded",String(e)),o.setAttribute("aria-haspopup",t))}function T2(n){const e=n==null?void 0:n.firstElementChild;if(!e)return;(e.shadowRoot?x5(e)[0]??e:e).focus()}const w5={fromAttribute:n=>n===null||n!=="false",toAttribute:n=>n?null:"false"};var y7=Object.defineProperty,c2=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&y7(e,t,i),i};const co=n=>n.closest("anduin-popover"),ws=class ws extends C{constructor(){super(...arguments),this._onClick=()=>{var e;(e=co(this))==null||e.toggleFromTrigger()},this._onKeyDown=e=>{var t;e.key!=="Enter"&&e.key!==" "||(e.preventDefault(),(t=co(this))==null||t.toggleFromTrigger())}}connectedCallback(){super.connectedCallback(),this.addEventListener("click",this._onClick),this.addEventListener("keydown",this._onKeyDown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._onClick),this.removeEventListener("keydown",this._onKeyDown)}render(){return d`<div class="trigger" part="trigger"><slot></slot></div>`}};ws.styles=p`
1614
+ `;let ao=xs;customElements.get("anduin-well")||customElements.define("anduin-well",li);customElements.get("anduin-well-close")||customElements.define("anduin-well-close",ao);const v7=["top","bottom","left","right"],m7=["start","center","end"],E1=8;function y5(n,e){if(!n)return e;const[t,o="center"]=n.split("-");return!v7.includes(t)||!m7.includes(o)?e:`${t}-${o}`}const Gi=n=>n.split("-")[0],O2=n=>n.split("-")[1],ia={top:"bottom",bottom:"top",left:"right",right:"left"};function x2(n,e,t,o,i){const s=Gi(o),r=O2(o);if(s==="top"||s==="bottom"){const u=s==="top"?n.top-t-i:n.bottom+i;return{left:r==="start"?n.left:r==="end"?n.right-e:n.left+n.width/2-e/2,top:u}}const a=s==="left"?n.left-e-i:n.right+i,c=r==="start"?n.top:r==="end"?n.bottom-t:n.top+n.height/2-t/2;return{left:a,top:c}}function w2(n,e,t){const o=window.innerWidth,i=window.innerHeight,s=(r,a)=>Math.max(0,Math.min(r,a-2*E1));switch(e){case"top":return s(n.top-t-E1,i);case"bottom":return s(i-n.bottom-t-E1,i);case"left":return s(n.left-t-E1,o);case"right":return s(o-n.right-t-E1,o)}}function s4(n,e,t,o,i=4){const s=window.innerWidth,r=window.innerHeight;if(n.right<0||n.bottom<0||n.left>s||n.top>r)return null;const a=Gi(o),c=x2(n,e,t,o,i),u=a==="top"?c.top>=0:a==="bottom"?c.top+t<=r:a==="left"?c.left>=0:c.left+e<=s,h=w2(n,ia[a],i)>w2(n,a,i);let g=u||!h?o:`${ia[a]}-${O2(o)}`;const m=Gi(g),v=O2(g),_=x2(n,e,t,g,i);(m==="top"||m==="bottom")&&v==="start"&&_.left+e>s?g=`${m}-end`:(m==="top"||m==="bottom")&&v==="end"&&_.left<0?g=`${m}-start`:(m==="left"||m==="right")&&v==="start"&&_.top+t>r?g=`${m}-end`:(m==="left"||m==="right")&&v==="end"&&_.top<0&&(g=`${m}-start`);const x=x2(n,e,t,g,i),y=(N,R,u1)=>Math.max(R,Math.min(N,u1)),V=Math.round(y(x.left,E1,s-e-E1)),L=Math.round(y(x.top,E1,r-t-E1)),M=Gi(g),$=M==="left"||M==="right"?Math.max(r-2*E1,0):w2(n,M,i);return{placement:g,left:V,top:L,availableHeight:$}}function r4(n){let e=0,t=!1;const o=()=>{t||(n(),e=requestAnimationFrame(o))};return o(),()=>{t=!0,cancelAnimationFrame(e)}}const Se=[];function l4(n){if(n.key!=="Escape"||n.defaultPrevented)return;const e=Se[Se.length-1];e&&(n.preventDefault(),e.onEscape())}function a4(n){ai(n),Se.length===0&&document.addEventListener("keydown",l4),Se.push(n)}function ai(n){const e=Se.indexOf(n);e>=0&&Se.splice(e,1),Se.length===0&&document.removeEventListener("keydown",l4)}const b7='a[href], button:not([disabled]), input:not([disabled]):not([type="hidden"]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"]), [contenteditable="true"]';function x5(n){const e=[],t=o=>{if(o instanceof HTMLSlotElement){o.assignedElements({flatten:!0}).forEach(t);return}o.matches(b7)&&o.getClientRects().length>0&&e.push(o);const i=o.shadowRoot?o.shadowRoot.children:o.children;Array.from(i).forEach(t)};return t(n),e}function d4(){var e;let n=document.activeElement;for(;(e=n==null?void 0:n.shadowRoot)!=null&&e.activeElement;)n=n.shadowRoot.activeElement;return n}function c4(n){let e=d4();for(;e;){if(e===n||n.contains(e))return!0;const t=e.getRootNode();e=t instanceof ShadowRoot?t.host:null}return!1}function _7(n,e){const t=x5(n);if(t.length===0){e.preventDefault();return}const o=d4(),i=o?t.indexOf(o):-1;e.shiftKey&&i<=0?(e.preventDefault(),t[t.length-1].focus()):!e.shiftKey&&(i===-1||i===t.length-1)&&(e.preventDefault(),t[0].focus())}function h4(n,e,t){const o=n==null?void 0:n.firstElementChild;o&&(o.setAttribute("aria-expanded",String(e)),o.setAttribute("aria-haspopup",t))}function T2(n){const e=n==null?void 0:n.firstElementChild;if(!e)return;(e.shadowRoot?x5(e)[0]??e:e).focus()}const w5={fromAttribute:n=>n===null||n!=="false",toAttribute:n=>n?null:"false"};var y7=Object.defineProperty,c2=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&y7(e,t,i),i};const co=n=>n.closest("anduin-popover"),ws=class ws extends C{constructor(){super(...arguments),this._onClick=()=>{var e;(e=co(this))==null||e.toggleFromTrigger()},this._onKeyDown=e=>{var t;e.key!=="Enter"&&e.key!==" "||(e.preventDefault(),(t=co(this))==null||t.toggleFromTrigger())}}connectedCallback(){super.connectedCallback(),this.addEventListener("click",this._onClick),this.addEventListener("keydown",this._onKeyDown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._onClick),this.removeEventListener("keydown",this._onKeyDown)}render(){return d`<div class="trigger" part="trigger"><slot></slot></div>`}};ws.styles=p`
1615
1615
  :host { display: block; }
1616
1616
  .trigger { display: block; cursor: pointer; }
1617
1617
  `;let ho=ws;const Hs=class Hs extends C{constructor(){super(...arguments),this.autoFocus=!0,this.modal=!1,this.label="",this._active=!1,this._shown=!1,this._stopTracking=()=>{},this._focusFrame=0,this._onKeyDown=e=>{e.key==="Tab"&&this._shown&&_7(this,e)}}setActive(e){this._active=e,this.hasUpdated&&this._sync()}firstUpdated(){const e=co(this);e!=null&&e.isDesignMode&&e.open&&(this._active=!0),this._sync()}connectedCallback(){super.connectedCallback(),this.addEventListener("keydown",this._onKeyDown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this._onKeyDown),this._active=!1,this._sync()}_sync(){this._active&&!this._shown?this._show():!this._active&&this._shown&&this._hide()}_accessibleName(){var t,o;const e=(o=(t=this.querySelector("anduin-popover-title"))==null?void 0:t.textContent)==null?void 0:o.replace(/\s+/g," ").trim();return this.label||this.getAttribute("aria-label")||e||""}_show(){const e=this._popup;if(!e)return;this._shown=!0;const t=this._accessibleName();t?e.setAttribute("aria-label",t):e.removeAttribute("aria-label");try{e.showPopover()}catch{}e.classList.add("is-open"),this._stopTracking=r4(()=>this._position()),this.autoFocus&&(this._focusFrame=requestAnimationFrame(()=>{var o;this._shown&&!c4(this)&&((o=x5(this)[0])==null||o.focus())}))}_hide(){cancelAnimationFrame(this._focusFrame),this._stopTracking(),this._stopTracking=()=>{},this._shown=!1;const e=this._popup;if(e){e.classList.remove("is-open");try{e.hidePopover()}catch{}}}_position(){const e=co(this),t=e==null?void 0:e.triggerPart,o=this._popup;if(!e||!t||!o)return;const i=s4(t.getBoundingClientRect(),o.offsetWidth,o.offsetHeight,y5(e.placement,"bottom-start"));if(!i){o.style.visibility="hidden";return}const s=`${i.left+(Number(e.offsetX)||0)}px`,r=`${i.top+(Number(e.offsetY)||0)}px`,a=`${Math.max(i.availableHeight,0)}px`;o.style.left!==s&&(o.style.left=s),o.style.top!==r&&(o.style.top=r),o.style.maxHeight!==a&&(o.style.maxHeight=a),o.style.visibility&&(o.style.visibility=""),o.dataset.placement=i.placement}render(){return d`
@@ -1682,7 +1682,7 @@
1682
1682
  text-overflow: ellipsis;
1683
1683
  white-space: nowrap;
1684
1684
  }
1685
- `;let uo=Ls;customElements.get("anduin-popover-trigger")||customElements.define("anduin-popover-trigger",ho);customElements.get("anduin-popover-content")||customElements.define("anduin-popover-content",Ce);customElements.get("anduin-popover-title")||customElements.define("anduin-popover-title",uo);var x7=Object.defineProperty,a1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&x7(e,t,i),i};const po="anduin-popover:close",di="anduin-popover:open-change",u4="anduin-popover-open-change",p4="anduin-popover-on-open",C4="anduin-popover-on-close",ks=class ks extends C{constructor(){super(...arguments),this.open=!1,this.placement="bottom-start",this.fullWidth=!1,this.defaultOpen=!1,this.disabled=!1,this.offsetX=0,this.offsetY=0,this.closeOnEscape=!0,this.closeOnClickOutside=!0,this._design=!1,this._visible=!1,this._closing=!1,this._closeTransitionEndHandler=null,this._detectMode=()=>{const e=this._ownParts("anduin-popover-trigger, anduin-popover-content").length>0;e!==this._design&&(this._design=e)},this._overlay={onEscape:()=>{this.closeOnEscape&&(this.requestOpen(!1),T2(this.triggerPart))}},this._onDesignPointerDown=e=>{!this._design||!this.open||!this.closeOnClickOutside||e.composedPath().includes(this)||this.requestOpen(!1)},this._onOutsideClick=e=>{this._design||e.composedPath().includes(this)||(this.open=!1)},this._onScrollOrResize=()=>{this.open&&this._updatePosition()},this._onPopoverClose=()=>{this._design?this.requestOpen(!1):this.open=!1},this._defaultOpenApplied=!1}_onTriggerClick(){this.open=!this.open}get isDesignMode(){return this._design}_ownParts(e){return Array.from(this.querySelectorAll(e)).filter(t=>t.closest("anduin-popover")===this)}get triggerPart(){return this._ownParts("anduin-popover-trigger")[0]??null}get _contentPart(){return this._ownParts("anduin-popover-content")[0]??null}requestOpen(e){e!==this.open&&(e&&this.disabled||(P(this,u4,e),this.open=e))}toggleFromTrigger(){this.disabled||this.requestOpen(!this.open)}connectedCallback(){super.connectedCallback(),this._detectMode(),document.addEventListener("pointerdown",this._onDesignPointerDown),document.addEventListener("click",this._onOutsideClick),window.addEventListener("scroll",this._onScrollOrResize,{passive:!0,capture:!0}),window.addEventListener("resize",this._onScrollOrResize),this.addEventListener(po,this._onPopoverClose)}disconnectedCallback(){super.disconnectedCallback(),ai(this._overlay),document.removeEventListener("pointerdown",this._onDesignPointerDown),document.removeEventListener("click",this._onOutsideClick),window.removeEventListener("scroll",this._onScrollOrResize,{capture:!0}),window.removeEventListener("resize",this._onScrollOrResize),this.removeEventListener(po,this._onPopoverClose)}willUpdate(e){this._design&&!this._defaultOpenApplied&&(this._defaultOpenApplied=!0,this.defaultOpen&&!this.hasAttribute("open")&&!this.open&&(this.open=!0)),e.has("disabled")&&this.disabled&&this.open&&this._design&&this.requestOpen(!1)}updated(e){if(e.has("_design")&&this._design&&!e.has("open")&&this.open&&this._applyDesignOpen(!0,!1),!!e.has("open")){if(this._design){this.dispatchEvent(new CustomEvent(di,{detail:this.open,bubbles:!0,composed:!0})),this._applyDesignOpen(this.open,e.get("open")===!0);return}this.dispatchEvent(new CustomEvent(di,{detail:this.open,bubbles:!0,composed:!0})),this.open?(this._cancelCloseAnimation(),this._closing=!1,this._visible=!0,requestAnimationFrame(()=>this._updatePosition())):this._startCloseAnimation()}}_applyDesignOpen(e,t){var o;(o=this._contentPart)==null||o.setActive(e),h4(this.triggerPart,e,"dialog"),e?(a4(this._overlay),P(this,p4,void 0)):(ai(this._overlay),t&&P(this,C4,void 0))}_cancelCloseAnimation(){this._closeTransitionEndHandler&&this._panelEl&&(this._panelEl.removeEventListener("transitionend",this._closeTransitionEndHandler),this._closeTransitionEndHandler=null),this._closing=!1}_startCloseAnimation(){if(!this._visible)return;this._closing=!0;const e=t=>{var o;t.propertyName==="opacity"&&((o=this._panelEl)==null||o.removeEventListener("transitionend",e),this._closeTransitionEndHandler=null,this._closing=!1,this._visible=!1)};this._closeTransitionEndHandler=e,requestAnimationFrame(()=>{var t;return(t=this._panelEl)==null?void 0:t.addEventListener("transitionend",e)})}_updatePosition(){const e=this._triggerEl,t=this._panelEl;if(!e||!t)return;const o=e.getBoundingClientRect(),i=t.style.transform;t.style.transform="none";const s=t.getBoundingClientRect();t.style.transform=i;const r=t.getBoundingClientRect(),a=4,c=window.innerWidth,u=window.innerHeight,h=8;let f=0,m=0,v="bottom";const _=!this.placement.startsWith("top"),x=u-o.bottom-a,y=o.top-a,V=x>=r.height,k=y>=r.height,M=_?V||x>=y:!k&&V;v=M?"bottom":"top",m=M?o.bottom+a:o.top-r.height-a;const $=this.placement.endsWith("end")?"end":this.placement.endsWith("start")?"start":"center";$==="start"?f=o.left:$==="end"?f=o.right-r.width:f=o.left+o.width/2-r.width/2,f=Math.max(h,Math.min(f,c-r.width-h)),m=Math.max(h,Math.min(m,u-r.height-h)),t.style.transform=`translate(${Math.round(f-s.left)}px, ${Math.round(m-s.top)}px)`,t.dataset.side=v}render(){return this._design?d`<slot @slotchange=${this._detectMode}></slot>`:d`
1685
+ `;let uo=Ls;customElements.get("anduin-popover-trigger")||customElements.define("anduin-popover-trigger",ho);customElements.get("anduin-popover-content")||customElements.define("anduin-popover-content",Ce);customElements.get("anduin-popover-title")||customElements.define("anduin-popover-title",uo);var x7=Object.defineProperty,a1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&x7(e,t,i),i};const po="anduin-popover:close",di="anduin-popover:open-change",u4="anduin-popover-open-change",p4="anduin-popover-on-open",C4="anduin-popover-on-close",ks=class ks extends C{constructor(){super(...arguments),this.open=!1,this.placement="bottom-start",this.fullWidth=!1,this.defaultOpen=!1,this.disabled=!1,this.offsetX=0,this.offsetY=0,this.closeOnEscape=!0,this.closeOnClickOutside=!0,this._design=!1,this._visible=!1,this._closing=!1,this._closeTransitionEndHandler=null,this._detectMode=()=>{const e=this._ownParts("anduin-popover-trigger, anduin-popover-content").length>0;e!==this._design&&(this._design=e)},this._overlay={onEscape:()=>{this.closeOnEscape&&(this.requestOpen(!1),T2(this.triggerPart))}},this._onDesignPointerDown=e=>{!this._design||!this.open||!this.closeOnClickOutside||e.composedPath().includes(this)||this.requestOpen(!1)},this._onOutsideClick=e=>{this._design||e.composedPath().includes(this)||(this.open=!1)},this._onScrollOrResize=()=>{this.open&&this._updatePosition()},this._onPopoverClose=()=>{this._design?this.requestOpen(!1):this.open=!1},this._defaultOpenApplied=!1}_onTriggerClick(){this.open=!this.open}get isDesignMode(){return this._design}_ownParts(e){return Array.from(this.querySelectorAll(e)).filter(t=>t.closest("anduin-popover")===this)}get triggerPart(){return this._ownParts("anduin-popover-trigger")[0]??null}get _contentPart(){return this._ownParts("anduin-popover-content")[0]??null}requestOpen(e){e!==this.open&&(e&&this.disabled||(P(this,u4,e),this.open=e))}toggleFromTrigger(){this.disabled||this.requestOpen(!this.open)}connectedCallback(){super.connectedCallback(),this._detectMode(),document.addEventListener("pointerdown",this._onDesignPointerDown),document.addEventListener("click",this._onOutsideClick),window.addEventListener("scroll",this._onScrollOrResize,{passive:!0,capture:!0}),window.addEventListener("resize",this._onScrollOrResize),this.addEventListener(po,this._onPopoverClose)}disconnectedCallback(){super.disconnectedCallback(),ai(this._overlay),document.removeEventListener("pointerdown",this._onDesignPointerDown),document.removeEventListener("click",this._onOutsideClick),window.removeEventListener("scroll",this._onScrollOrResize,{capture:!0}),window.removeEventListener("resize",this._onScrollOrResize),this.removeEventListener(po,this._onPopoverClose)}willUpdate(e){this._design&&!this._defaultOpenApplied&&(this._defaultOpenApplied=!0,this.defaultOpen&&!this.hasAttribute("open")&&!this.open&&(this.open=!0)),e.has("disabled")&&this.disabled&&this.open&&this._design&&this.requestOpen(!1)}updated(e){if(e.has("_design")&&this._design&&!e.has("open")&&this.open&&this._applyDesignOpen(!0,!1),!!e.has("open")){if(this._design){this.dispatchEvent(new CustomEvent(di,{detail:this.open,bubbles:!0,composed:!0})),this._applyDesignOpen(this.open,e.get("open")===!0);return}this.dispatchEvent(new CustomEvent(di,{detail:this.open,bubbles:!0,composed:!0})),this.open?(this._cancelCloseAnimation(),this._closing=!1,this._visible=!0,requestAnimationFrame(()=>this._updatePosition())):this._startCloseAnimation()}}_applyDesignOpen(e,t){var o;(o=this._contentPart)==null||o.setActive(e),h4(this.triggerPart,e,"dialog"),e?(a4(this._overlay),P(this,p4,void 0)):(ai(this._overlay),t&&P(this,C4,void 0))}_cancelCloseAnimation(){this._closeTransitionEndHandler&&this._panelEl&&(this._panelEl.removeEventListener("transitionend",this._closeTransitionEndHandler),this._closeTransitionEndHandler=null),this._closing=!1}_startCloseAnimation(){if(!this._visible)return;this._closing=!0;const e=t=>{var o;t.propertyName==="opacity"&&((o=this._panelEl)==null||o.removeEventListener("transitionend",e),this._closeTransitionEndHandler=null,this._closing=!1,this._visible=!1)};this._closeTransitionEndHandler=e,requestAnimationFrame(()=>{var t;return(t=this._panelEl)==null?void 0:t.addEventListener("transitionend",e)})}_updatePosition(){const e=this._triggerEl,t=this._panelEl;if(!e||!t)return;const o=e.getBoundingClientRect(),i=t.style.transform;t.style.transform="none";const s=t.getBoundingClientRect();t.style.transform=i;const r=t.getBoundingClientRect(),a=4,c=window.innerWidth,u=window.innerHeight,h=8;let g=0,m=0,v="bottom";const _=!this.placement.startsWith("top"),x=u-o.bottom-a,y=o.top-a,V=x>=r.height,L=y>=r.height,M=_?V||x>=y:!L&&V;v=M?"bottom":"top",m=M?o.bottom+a:o.top-r.height-a;const $=this.placement.endsWith("end")?"end":this.placement.endsWith("start")?"start":"center";$==="start"?g=o.left:$==="end"?g=o.right-r.width:g=o.left+o.width/2-r.width/2,g=Math.max(h,Math.min(g,c-r.width-h)),m=Math.max(h,Math.min(m,u-r.height-h)),t.style.transform=`translate(${Math.round(g-s.left)}px, ${Math.round(m-s.top)}px)`,t.dataset.side=v}render(){return this._design?d`<slot @slotchange=${this._detectMode}></slot>`:d`
1686
1686
  <div class="popover__trigger" @click=${this._onTriggerClick} part="trigger">
1687
1687
  <slot name="trigger" @slotchange=${this._detectMode}></slot>
1688
1688
  </div>
@@ -1754,7 +1754,7 @@
1754
1754
  * @license
1755
1755
  * Copyright 2018 Google LLC
1756
1756
  * SPDX-License-Identifier: BSD-3-Clause
1757
- */const e1=n=>n??g;var w7=Object.defineProperty,we=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&w7(e,t,i),i};const ot=n=>n.closest("anduin-menu"),D2="anduin-menu-content, anduin-menu-sub-content",f4=p`${B}
1757
+ */const e1=n=>n??f;var w7=Object.defineProperty,we=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&w7(e,t,i),i};const ot=n=>n.closest("anduin-menu"),D2="anduin-menu-content, anduin-menu-sub-content",g4=p`${B}
1758
1758
 
1759
1759
  :host { display: contents; }
1760
1760
  .menu-popup {
@@ -1793,13 +1793,13 @@
1793
1793
  `;function H7(n){return Array.from(n.childNodes).filter(t=>!(t instanceof Element&&t.hasAttribute("slot"))).map(t=>t.textContent??"").join(" ").replace(/\s+/g," ").trim().toLowerCase()}class L5 extends C{constructor(){super(...arguments),this._active=!1,this._shown=!1,this._stopTracking=()=>{},this._typed="",this._typedAt=0,this._onKeyDown=e=>{if(e.defaultPrevented||this._handleOwnKey(e))return;const t=this.items();if(t.length===0)return;const o=e.composedPath(),i=t.findIndex(r=>o.includes(r));let s;switch(e.key){case"ArrowDown":s=t[(i+1)%t.length];break;case"ArrowUp":s=t[i<=0?t.length-1:i-1];break;case"Home":s=t[0];break;case"End":s=t[t.length-1];break;default:if(e.key.length===1&&e.key!==" "&&!e.ctrlKey&&!e.metaKey&&!e.altKey&&(s=this._typeahead(e.key.toLowerCase(),t,i),!s)){e.preventDefault(),e.stopPropagation();return}}s&&(e.preventDefault(),e.stopPropagation(),s.focus())}}connectedCallback(){super.connectedCallback(),this.addEventListener("keydown",this._onKeyDown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this._onKeyDown),this._active=!1,this._sync()}items(){return Array.from(this.querySelectorAll("anduin-menu-item, anduin-menu-sub-trigger")).filter(e=>e.closest(D2)===this&&!e.disabled)}focusEdge(e){const t=this.items(),o=e==="first"?t[0]:t[t.length-1];o==null||o.focus()}setActive(e){this._active=e,this.hasUpdated&&this._sync()}_sync(){this._active&&!this._shown?this._show():!this._active&&this._shown&&this._hide()}_show(){const e=this._popup;if(e){this._shown=!0,this._beforeShow();try{e.showPopover()}catch{}e.classList.add("is-open"),this._stopTracking=r4(()=>this._position())}}_hide(){this._stopTracking(),this._stopTracking=()=>{},this._shown=!1;const e=this._popup;if(e){e.classList.remove("is-open");try{e.hidePopover()}catch{}}}_beforeShow(){}_position(){const e=this._anchor(),t=this._popup;if(!e||!t)return;const o=s4(e.ref.getBoundingClientRect(),t.offsetWidth,t.offsetHeight,e.placement);if(!o){t.style.visibility="hidden";return}const i=o.placement.split("-")[0],s=o.placement.split("-")[1],r=this.localName==="anduin-menu-sub-content"&&(i==="left"||i==="right")?s==="start"?-8:s==="end"?8:0:0,a=`${o.left+e.dx}px`,c=`${o.top+e.dy+r}px`,h=`min(var(${this.localName==="anduin-menu-sub-content"?"--anduin-menu-sub-content-max-height":"--anduin-menu-content-max-height"}, 80vh), ${Math.max(o.availableHeight,0)}px)`;t.style.left!==a&&(t.style.left=a),t.style.top!==c&&(t.style.top=c),t.style.maxHeight!==h&&(t.style.maxHeight=h),t.style.visibility&&(t.style.visibility=""),t.dataset.placement=o.placement}_handleOwnKey(e){return!1}_typeahead(e,t,o){const i=Date.now();this._typed=i-this._typedAt>500?e:this._typed+e,this._typedAt=i;const s=this._typed.split("").every(c=>c===e),r=s?e:this._typed,a=s||this._typed.length===1?o+1:Math.max(o,0);for(let c=0;c<t.length;c++){const u=t[(a+c)%t.length];if(H7(u).startsWith(r))return u}}}we([E(".menu-popup")],L5.prototype,"_popup");const Es=class Es extends C{constructor(){super(...arguments),this._onClick=()=>{var e;(e=ot(this))==null||e.toggleFromTrigger()},this._onKeyDown=e=>{const t=ot(this);if(t)switch(e.key){case"Enter":case" ":e.preventDefault(),t.open?t.requestOpen(!1):t.openAndFocus("first");break;case"ArrowDown":e.preventDefault(),t.openAndFocus("first");break;case"ArrowUp":e.preventDefault(),t.openAndFocus("last");break}}}connectedCallback(){super.connectedCallback(),this.addEventListener("click",this._onClick),this.addEventListener("keydown",this._onKeyDown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._onClick),this.removeEventListener("keydown",this._onKeyDown)}render(){return d`<div class="trigger" part="trigger"><slot></slot></div>`}};Es.styles=p`
1794
1794
  :host { display: block; }
1795
1795
  .trigger { display: block; cursor: pointer; }
1796
- `;let fo=Es;const Ms=class Ms extends L5{constructor(){super(...arguments),this.label="",this.standalone=!1}firstUpdated(){const e=ot(this);!this.standalone&&(e!=null&&e.isDesignMode)&&e.open&&(this._active=!0),this._sync()}_beforeShow(){var i,s,r,a,c,u;const e=(s=(i=ot(this))==null?void 0:i.triggerPart)==null?void 0:s.firstElementChild,t=((e==null?void 0:e.getAttribute("aria-label"))||((a=(r=ot(this))==null?void 0:r.triggerPart)==null?void 0:a.textContent)||"").replace(/\s+/g," ").trim(),o=this.label||t;o?(c=this._popup)==null||c.setAttribute("aria-label",o):(u=this._popup)==null||u.removeAttribute("aria-label")}_anchor(){const e=ot(this),t=e==null?void 0:e.triggerPart;return!e||!t?null:{ref:t,placement:y5(e.placement,"bottom-start"),dx:Number(e.offsetX)||0,dy:Number(e.offsetY)||0}}render(){return this.standalone?d`<div class="menu-popup--standalone" role="menu" part="menu" aria-label=${e1(this.label||void 0)}>
1796
+ `;let go=Es;const Ms=class Ms extends L5{constructor(){super(...arguments),this.label="",this.standalone=!1}firstUpdated(){const e=ot(this);!this.standalone&&(e!=null&&e.isDesignMode)&&e.open&&(this._active=!0),this._sync()}_beforeShow(){var i,s,r,a,c,u;const e=(s=(i=ot(this))==null?void 0:i.triggerPart)==null?void 0:s.firstElementChild,t=((e==null?void 0:e.getAttribute("aria-label"))||((a=(r=ot(this))==null?void 0:r.triggerPart)==null?void 0:a.textContent)||"").replace(/\s+/g," ").trim(),o=this.label||t;o?(c=this._popup)==null||c.setAttribute("aria-label",o):(u=this._popup)==null||u.removeAttribute("aria-label")}_anchor(){const e=ot(this),t=e==null?void 0:e.triggerPart;return!e||!t?null:{ref:t,placement:y5(e.placement,"bottom-start"),dx:Number(e.offsetX)||0,dy:Number(e.offsetY)||0}}render(){return this.standalone?d`<div class="menu-popup--standalone" role="menu" part="menu" aria-label=${e1(this.label||void 0)}>
1797
1797
  <slot></slot>
1798
1798
  </div>`:d`
1799
1799
  <div class="menu-popup" part="menu" popover="manual" role="menu">
1800
1800
  <slot></slot>
1801
1801
  </div>
1802
- `}};Ms.styles=[f4,p`
1802
+ `}};Ms.styles=[g4,p`
1803
1803
  /*
1804
1804
  * The design repo's root menu popup keeps the UA popover padding (0.25em) on top of its 8px list inset,
1805
1805
  * so items sit 12.25px from the edge; match it.
@@ -1817,7 +1817,7 @@
1817
1817
  `];let yt=Ms;we([l()],yt.prototype,"label");we([l({converter:w})],yt.prototype,"standalone");const $s=class $s extends C{render(){return d`<div class="menu-group" role="group" part="group"><slot></slot></div>`}};$s.styles=p`
1818
1818
  :host { display: block; }
1819
1819
  .menu-group { display: flex; flex-direction: column; }
1820
- `;let go=$s;const Zs=class Zs extends C{render(){return d`<div class="menu-label" part="label"><slot></slot></div>`}};Zs.styles=p`
1820
+ `;let fo=$s;const Zs=class Zs extends C{render(){return d`<div class="menu-label" part="label"><slot></slot></div>`}};Zs.styles=p`
1821
1821
  :host { display: block; }
1822
1822
  .menu-label {
1823
1823
  padding: 4px 12px;
@@ -1846,7 +1846,7 @@
1846
1846
  @click=${this._onClick}
1847
1847
  @keydown=${this._onKeyDown}
1848
1848
  >
1849
- ${this.startIcon?d`<anduin-icon name=${this.startIcon} size="16" aria-hidden="true"></anduin-icon>`:g}
1849
+ ${this.startIcon?d`<anduin-icon name=${this.startIcon} size="16" aria-hidden="true"></anduin-icon>`:f}
1850
1850
  <span class="label"><slot></slot></span>
1851
1851
  <anduin-icon class="end-icon" name="chevronRight" size="16" aria-hidden="true"></anduin-icon>
1852
1852
  </button>
@@ -1883,7 +1883,7 @@
1883
1883
  .menu-sub-trigger--inset { padding-left: 36px; }
1884
1884
  .menu-sub-trigger:disabled { color: var(--color-disabled-foreground); cursor: not-allowed; pointer-events: none; }
1885
1885
  .menu-sub-trigger:disabled anduin-icon { color: var(--color-disabled-foreground); }
1886
- `;let fe=In;we([l({converter:w})],fe.prototype,"disabled");we([l({converter:w})],fe.prototype,"inset");we([l({attribute:"start-icon"})],fe.prototype,"startIcon");we([b()],fe.prototype,"_expanded");const Ss=class Ss extends L5{constructor(){super(...arguments),this._onPointerEnter=()=>{var e;return(e=this._sub)==null?void 0:e.cancelClose()},this._onPointerLeave=()=>{var e;return(e=this._sub)==null?void 0:e.scheduleClose()}}get _sub(){return this.closest("anduin-menu-sub")}firstUpdated(){var e;(e=this._sub)!=null&&e.open&&(this._active=!0),this._sync()}_anchor(){const e=this._sub,t=e==null?void 0:e.triggerPart;return!e||!t?null:{ref:t,placement:y5(e.placement,"right-start"),dx:0,dy:0}}_handleOwnKey(e){var t;return e.key!=="ArrowLeft"&&e.key!=="Escape"?!1:(e.preventDefault(),e.stopPropagation(),(t=this._sub)==null||t.closeAndFocusTrigger(),!0)}render(){var e,t,o;return d`
1886
+ `;let ge=In;we([l({converter:w})],ge.prototype,"disabled");we([l({converter:w})],ge.prototype,"inset");we([l({attribute:"start-icon"})],ge.prototype,"startIcon");we([b()],ge.prototype,"_expanded");const Ss=class Ss extends L5{constructor(){super(...arguments),this._onPointerEnter=()=>{var e;return(e=this._sub)==null?void 0:e.cancelClose()},this._onPointerLeave=()=>{var e;return(e=this._sub)==null?void 0:e.scheduleClose()}}get _sub(){return this.closest("anduin-menu-sub")}firstUpdated(){var e;(e=this._sub)!=null&&e.open&&(this._active=!0),this._sync()}_anchor(){const e=this._sub,t=e==null?void 0:e.triggerPart;return!e||!t?null:{ref:t,placement:y5(e.placement,"right-start"),dx:0,dy:0}}_handleOwnKey(e){var t;return e.key!=="ArrowLeft"&&e.key!=="Escape"?!1:(e.preventDefault(),e.stopPropagation(),(t=this._sub)==null||t.closeAndFocusTrigger(),!0)}render(){var e,t,o;return d`
1887
1887
  <div
1888
1888
  class="menu-popup"
1889
1889
  part="menu"
@@ -1895,7 +1895,7 @@
1895
1895
  >
1896
1896
  <slot></slot>
1897
1897
  </div>
1898
- `}};Ss.styles=f4;let bo=Ss;const He=(n,e)=>{customElements.get(n)||customElements.define(n,e)};He("anduin-menu-trigger",fo);He("anduin-menu-content",yt);He("anduin-menu-group",go);He("anduin-menu-label",vo);He("anduin-menu-separator",mo);He("anduin-menu-sub",ci);He("anduin-menu-sub-trigger",fe);He("anduin-menu-sub-content",bo);var L7=Object.defineProperty,Z=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&L7(e,t,i),i};const _o="anduin-menu-item:click",g4="anduin-menu-item-selected",v4="anduin-menu-open-change",yo="anduin-menu:item-commit",Os=class Os extends C{constructor(){super(...arguments),this.open=!1,this.placement="bottom-start",this.defaultOpen=!1,this.disabled=!1,this.offsetX=0,this.offsetY=0,this._design=!1,this._detectMode=()=>{const e=this._ownParts("anduin-menu-trigger, anduin-menu-content").length>0;e!==this._design&&(this._design=e)},this._overlay={onEscape:()=>{this.requestOpen(!1),T2(this.triggerPart)}},this._onDesignPointerDown=e=>{!this._design||!this.open||e.composedPath().includes(this)||this.requestOpen(!1)},this._onItemCommit=()=>{if(!this._design)return;const e=c4(this);this.requestOpen(!1),e&&T2(this.triggerPart)},this._onOutsideClick=e=>{this._design||e.composedPath().includes(this)||(this.open=!1)},this._onItemClick=()=>{this._design||(this.open=!1)},this._onScrollOrResize=()=>{this.open&&!this._design&&this._updatePosition()},this._defaultOpenApplied=!1}_onTriggerClick(){this.open=!this.open}get isDesignMode(){return this._design}_ownParts(e){return Array.from(this.querySelectorAll(e)).filter(t=>t.closest("anduin-menu")===this)}get triggerPart(){return this._ownParts("anduin-menu-trigger")[0]??null}get _contentPart(){return this._ownParts("anduin-menu-content")[0]??null}requestOpen(e){e!==this.open&&(e&&this.disabled||(P(this,v4,e),this.open=e))}toggleFromTrigger(){this.disabled||this.requestOpen(!this.open)}async openAndFocus(e){var t;this.disabled||(this.requestOpen(!0),await this.updateComplete,(t=this._contentPart)==null||t.focusEdge(e))}_applyDesignOpen(e){var t;(t=this._contentPart)==null||t.setActive(e),h4(this.triggerPart,e,"menu"),e?a4(this._overlay):(ai(this._overlay),this.querySelectorAll("anduin-menu-sub").forEach(o=>{var i;return(i=o.setOpen)==null?void 0:i.call(o,!1)}))}connectedCallback(){super.connectedCallback(),this._detectMode(),document.addEventListener("click",this._onOutsideClick),document.addEventListener("pointerdown",this._onDesignPointerDown),this.addEventListener(_o,this._onItemClick),this.addEventListener(yo,this._onItemCommit),window.addEventListener("scroll",this._onScrollOrResize,{passive:!0,capture:!0}),window.addEventListener("resize",this._onScrollOrResize)}disconnectedCallback(){super.disconnectedCallback(),ai(this._overlay),document.removeEventListener("click",this._onOutsideClick),document.removeEventListener("pointerdown",this._onDesignPointerDown),this.removeEventListener(_o,this._onItemClick),this.removeEventListener(yo,this._onItemCommit),window.removeEventListener("scroll",this._onScrollOrResize,{capture:!0}),window.removeEventListener("resize",this._onScrollOrResize)}willUpdate(e){this._design&&!this._defaultOpenApplied&&(this._defaultOpenApplied=!0,this.defaultOpen&&!this.hasAttribute("open")&&!this.open&&(this.open=!0)),e.has("disabled")&&this.disabled&&this.open&&this._design&&this.requestOpen(!1)}updated(e){if(this._design){(e.has("open")||e.has("_design")&&this.open)&&this._applyDesignOpen(this.open);return}e.has("open")&&this.open&&requestAnimationFrame(()=>this._updatePosition())}_updatePosition(){const e=this._triggerEl,t=this._panelEl;if(!e||!t)return;const o=e.getBoundingClientRect(),i=t.style.transform;t.style.transform="none";const s=t.getBoundingClientRect();t.style.transform=i;const r=t.getBoundingClientRect(),a=4;let c=0,u=0,h="bottom";switch(this.placement){case"bottom-start":c=o.left,u=o.bottom+a,h="bottom";break;case"bottom-end":c=o.right-r.width,u=o.bottom+a,h="bottom";break;case"bottom":c=o.left+o.width/2-r.width/2,u=o.bottom+a,h="bottom";break;case"top-start":c=o.left,u=o.top-r.height-a,h="top";break;case"top-end":c=o.right-r.width,u=o.top-r.height-a,h="top";break;case"top":c=o.left+o.width/2-r.width/2,u=o.top-r.height-a,h="top";break}t.style.transform=`translate(${Math.round(c-s.left)}px, ${Math.round(u-s.top)}px)`,t.dataset.side=h}render(){return this._design?d`<slot @slotchange=${this._detectMode}></slot>`:d`
1898
+ `}};Ss.styles=g4;let bo=Ss;const He=(n,e)=>{customElements.get(n)||customElements.define(n,e)};He("anduin-menu-trigger",go);He("anduin-menu-content",yt);He("anduin-menu-group",fo);He("anduin-menu-label",vo);He("anduin-menu-separator",mo);He("anduin-menu-sub",ci);He("anduin-menu-sub-trigger",ge);He("anduin-menu-sub-content",bo);var L7=Object.defineProperty,Z=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&L7(e,t,i),i};const _o="anduin-menu-item:click",f4="anduin-menu-item-selected",v4="anduin-menu-open-change",yo="anduin-menu:item-commit",Os=class Os extends C{constructor(){super(...arguments),this.open=!1,this.placement="bottom-start",this.defaultOpen=!1,this.disabled=!1,this.offsetX=0,this.offsetY=0,this._design=!1,this._detectMode=()=>{const e=this._ownParts("anduin-menu-trigger, anduin-menu-content").length>0;e!==this._design&&(this._design=e)},this._overlay={onEscape:()=>{this.requestOpen(!1),T2(this.triggerPart)}},this._onDesignPointerDown=e=>{!this._design||!this.open||e.composedPath().includes(this)||this.requestOpen(!1)},this._onItemCommit=()=>{if(!this._design)return;const e=c4(this);this.requestOpen(!1),e&&T2(this.triggerPart)},this._onOutsideClick=e=>{this._design||e.composedPath().includes(this)||(this.open=!1)},this._onItemClick=()=>{this._design||(this.open=!1)},this._onScrollOrResize=()=>{this.open&&!this._design&&this._updatePosition()},this._defaultOpenApplied=!1}_onTriggerClick(){this.open=!this.open}get isDesignMode(){return this._design}_ownParts(e){return Array.from(this.querySelectorAll(e)).filter(t=>t.closest("anduin-menu")===this)}get triggerPart(){return this._ownParts("anduin-menu-trigger")[0]??null}get _contentPart(){return this._ownParts("anduin-menu-content")[0]??null}requestOpen(e){e!==this.open&&(e&&this.disabled||(P(this,v4,e),this.open=e))}toggleFromTrigger(){this.disabled||this.requestOpen(!this.open)}async openAndFocus(e){var t;this.disabled||(this.requestOpen(!0),await this.updateComplete,(t=this._contentPart)==null||t.focusEdge(e))}_applyDesignOpen(e){var t;(t=this._contentPart)==null||t.setActive(e),h4(this.triggerPart,e,"menu"),e?a4(this._overlay):(ai(this._overlay),this.querySelectorAll("anduin-menu-sub").forEach(o=>{var i;return(i=o.setOpen)==null?void 0:i.call(o,!1)}))}connectedCallback(){super.connectedCallback(),this._detectMode(),document.addEventListener("click",this._onOutsideClick),document.addEventListener("pointerdown",this._onDesignPointerDown),this.addEventListener(_o,this._onItemClick),this.addEventListener(yo,this._onItemCommit),window.addEventListener("scroll",this._onScrollOrResize,{passive:!0,capture:!0}),window.addEventListener("resize",this._onScrollOrResize)}disconnectedCallback(){super.disconnectedCallback(),ai(this._overlay),document.removeEventListener("click",this._onOutsideClick),document.removeEventListener("pointerdown",this._onDesignPointerDown),this.removeEventListener(_o,this._onItemClick),this.removeEventListener(yo,this._onItemCommit),window.removeEventListener("scroll",this._onScrollOrResize,{capture:!0}),window.removeEventListener("resize",this._onScrollOrResize)}willUpdate(e){this._design&&!this._defaultOpenApplied&&(this._defaultOpenApplied=!0,this.defaultOpen&&!this.hasAttribute("open")&&!this.open&&(this.open=!0)),e.has("disabled")&&this.disabled&&this.open&&this._design&&this.requestOpen(!1)}updated(e){if(this._design){(e.has("open")||e.has("_design")&&this.open)&&this._applyDesignOpen(this.open);return}e.has("open")&&this.open&&requestAnimationFrame(()=>this._updatePosition())}_updatePosition(){const e=this._triggerEl,t=this._panelEl;if(!e||!t)return;const o=e.getBoundingClientRect(),i=t.style.transform;t.style.transform="none";const s=t.getBoundingClientRect();t.style.transform=i;const r=t.getBoundingClientRect(),a=4;let c=0,u=0,h="bottom";switch(this.placement){case"bottom-start":c=o.left,u=o.bottom+a,h="bottom";break;case"bottom-end":c=o.right-r.width,u=o.bottom+a,h="bottom";break;case"bottom":c=o.left+o.width/2-r.width/2,u=o.bottom+a,h="bottom";break;case"top-start":c=o.left,u=o.top-r.height-a,h="top";break;case"top-end":c=o.right-r.width,u=o.top-r.height-a,h="top";break;case"top":c=o.left+o.width/2-r.width/2,u=o.top-r.height-a,h="top";break}t.style.transform=`translate(${Math.round(c-s.left)}px, ${Math.round(u-s.top)}px)`,t.dataset.side=h}render(){return this._design?d`<slot @slotchange=${this._detectMode}></slot>`:d`
1899
1899
  <div class="menu__trigger" @click=${this._onTriggerClick} part="trigger">
1900
1900
  <slot name="trigger" @slotchange=${this._detectMode}></slot>
1901
1901
  </div>
@@ -1947,7 +1947,7 @@
1947
1947
  .menu__panel--open[data-side="top"] .menu__inner {
1948
1948
  transform: scale(1) translateY(0);
1949
1949
  }
1950
- `;let C1=Os;Z([l({reflect:!0,converter:w})],C1.prototype,"open");Z([l()],C1.prototype,"placement");Z([l({attribute:"default-open",converter:w})],C1.prototype,"defaultOpen");Z([l({converter:w})],C1.prototype,"disabled");Z([l({attribute:"offset-x",type:Number})],C1.prototype,"offsetX");Z([l({attribute:"offset-y",type:Number})],C1.prototype,"offsetY");Z([b()],C1.prototype,"_design");Z([E(".menu__trigger")],C1.prototype,"_triggerEl");Z([E(".menu__panel")],C1.prototype,"_panelEl");const k7={fromAttribute:n=>n===null?void 0:n!=="false",toAttribute:n=>n===void 0?null:String(n)},Fn=class Fn extends C{constructor(){super(...arguments),this.icon="",this.startIcon="",this.variant="default",this.disabled=!1,this.checked=void 0,this.radio=!1,this.inset=!1,this.loading=!1,this.href="",this.openNewTab=!1,this.size="medium",this.description="",this.label="",this._design=!1,this._slottedDescription=!1,this._onHostClickCapture=e=>{(this.disabled||this.loading)&&(e.preventDefault(),e.stopPropagation())},this._onDescriptionSlotChange=()=>{this._slottedDescription=!!this.querySelector(':scope > [slot="description"]')}}connectedCallback(){super.connectedCallback(),this._design=!!this.closest("anduin-menu-content, anduin-menu-sub-content"),this._slottedDescription=!!this.querySelector(':scope > [slot="description"]'),this.addEventListener("click",this._onHostClickCapture,{capture:!0})}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._onHostClickCapture,{capture:!0})}_onClick(e){if(this.disabled||this.loading){e.preventDefault();return}P(this,g4,!0,!0)&&this.dispatchEvent(new CustomEvent(yo,{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent(_o,{bubbles:!0,composed:!0}))}_onKeyDown(e){!this._design||e.key!=="Enter"&&e.key!==" "||(e.preventDefault(),!this.disabled&&!this.loading&&e.currentTarget.click())}_onPointerEnter(e){!this._design||this.disabled||e.currentTarget.focus({preventScroll:!0})}render(){const e=this.disabled||this.loading,t=this.startIcon||this.icon,o=this.checked===void 0?"menuitem":this.radio?"menuitemradio":"menuitemcheckbox",i=H5({"menu-item":!0,"menu-item--design":this._design,"menu-item--danger":this.variant==="danger","menu-item--free":this.size==="free","menu-item--inset":this.inset,"menu-item--with-description":!!this.description||this._slottedDescription,"menu-item--loading":this.loading,"menu-item--disabled":this.disabled}),s=this.loading?d`<anduin-spinner size="small"></anduin-spinner>`:this.checked?d`<anduin-icon name="checkSmall" size="16" aria-hidden="true"></anduin-icon>`:t?d`<anduin-icon name="${t}" size="16" aria-hidden="true"></anduin-icon>`:g,r=d`
1950
+ `;let C1=Os;Z([l({reflect:!0,converter:w})],C1.prototype,"open");Z([l()],C1.prototype,"placement");Z([l({attribute:"default-open",converter:w})],C1.prototype,"defaultOpen");Z([l({converter:w})],C1.prototype,"disabled");Z([l({attribute:"offset-x",type:Number})],C1.prototype,"offsetX");Z([l({attribute:"offset-y",type:Number})],C1.prototype,"offsetY");Z([b()],C1.prototype,"_design");Z([E(".menu__trigger")],C1.prototype,"_triggerEl");Z([E(".menu__panel")],C1.prototype,"_panelEl");const k7={fromAttribute:n=>n===null?void 0:n!=="false",toAttribute:n=>n===void 0?null:String(n)},Fn=class Fn extends C{constructor(){super(...arguments),this.icon="",this.startIcon="",this.variant="default",this.disabled=!1,this.checked=void 0,this.radio=!1,this.inset=!1,this.loading=!1,this.href="",this.openNewTab=!1,this.size="medium",this.description="",this.label="",this._design=!1,this._slottedDescription=!1,this._onHostClickCapture=e=>{(this.disabled||this.loading)&&(e.preventDefault(),e.stopPropagation())},this._onDescriptionSlotChange=()=>{this._slottedDescription=!!this.querySelector(':scope > [slot="description"]')}}connectedCallback(){super.connectedCallback(),this._design=!!this.closest("anduin-menu-content, anduin-menu-sub-content"),this._slottedDescription=!!this.querySelector(':scope > [slot="description"]'),this.addEventListener("click",this._onHostClickCapture,{capture:!0})}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._onHostClickCapture,{capture:!0})}_onClick(e){if(this.disabled||this.loading){e.preventDefault();return}P(this,f4,!0,!0)&&this.dispatchEvent(new CustomEvent(yo,{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent(_o,{bubbles:!0,composed:!0}))}_onKeyDown(e){!this._design||e.key!=="Enter"&&e.key!==" "||(e.preventDefault(),!this.disabled&&!this.loading&&e.currentTarget.click())}_onPointerEnter(e){!this._design||this.disabled||e.currentTarget.focus({preventScroll:!0})}render(){const e=this.disabled||this.loading,t=this.startIcon||this.icon,o=this.checked===void 0?"menuitem":this.radio?"menuitemradio":"menuitemcheckbox",i=H5({"menu-item":!0,"menu-item--design":this._design,"menu-item--danger":this.variant==="danger","menu-item--free":this.size==="free","menu-item--inset":this.inset,"menu-item--with-description":!!this.description||this._slottedDescription,"menu-item--loading":this.loading,"menu-item--disabled":this.disabled}),s=this.loading?d`<anduin-spinner size="small"></anduin-spinner>`:this.checked?d`<anduin-icon name="checkSmall" size="16" aria-hidden="true"></anduin-icon>`:t?d`<anduin-icon name="${t}" size="16" aria-hidden="true"></anduin-icon>`:f,r=d`
1951
1951
  ${s}
1952
1952
  <span class="menu-item__content">
1953
1953
  <span class="menu-item__label"><slot></slot></span>
@@ -2154,12 +2154,12 @@
2154
2154
  aria-modal="true"
2155
2155
  aria-labelledby="modal-title"
2156
2156
  >
2157
- ${this.hideHeader?g:d` <div class="header">
2157
+ ${this.hideHeader?f:d` <div class="header">
2158
2158
  <div class="header-slot">
2159
2159
  <slot name="header">
2160
2160
  ${this.heading?d`<span id="modal-title" class="title"
2161
2161
  >${this.heading}</span
2162
- >`:g}
2162
+ >`:f}
2163
2163
  </slot>
2164
2164
  </div>
2165
2165
  <span class="header-sep"></span>
@@ -2175,7 +2175,7 @@
2175
2175
  <div class="body">
2176
2176
  <slot></slot>
2177
2177
  </div>
2178
- ${this.hideFooter?g:d`<div class="footer"><slot name="footer"></slot></div>`}
2178
+ ${this.hideFooter?f:d`<div class="footer"><slot name="footer"></slot></div>`}
2179
2179
  </div>
2180
2180
  </div>
2181
2181
  `}},he.styles=[_4,p`${B}
@@ -2308,10 +2308,10 @@
2308
2308
  type="radio"
2309
2309
  .checked=${this.checked}
2310
2310
  .value=${this.value}
2311
- name=${this.name||g}
2311
+ name=${this.name||f}
2312
2312
  ?disabled=${this.disabled||this.readonly}
2313
2313
  tabindex="${e?0:-1}"
2314
- @change=${e?this._onInputChange:g}
2314
+ @change=${e?this._onInputChange:f}
2315
2315
  />
2316
2316
  <div class="${t}" tabindex="${e?0:-1}"></div>
2317
2317
  <div class="radio__dot ${this.checked?"radio__dot--visible":""}"></div>
@@ -2405,8 +2405,8 @@
2405
2405
  <div
2406
2406
  class="avatar avatar--design avatar--${c} avatar--${r} avatar--${s}"
2407
2407
  style=${i?`background-color:${k4(e)}`:""}
2408
- role=${a?"img":g}
2409
- aria-label=${a||g}
2408
+ role=${a?"img":f}
2409
+ aria-label=${a||f}
2410
2410
  part="avatar"
2411
2411
  >
2412
2412
  ${o?d`<anduin-icon name="anduin" size=${s==="small"?12:16} aria-hidden="true"></anduin-icon>`:i?d`<span>${h}</span>`:d`<slot></slot>`}
@@ -2469,7 +2469,7 @@
2469
2469
  * @license
2470
2470
  * Copyright 2017 Google LLC
2471
2471
  * SPDX-License-Identifier: BSD-3-Clause
2472
- */class z2 extends r2{constructor(e){if(super(e),this.it=g,e.type!==I1.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(e){if(e===g||e==null)return this._t=void 0,this.it=e;if(e===p1)return e;if(typeof e!="string")throw Error(this.constructor.directiveName+"() called with a non-string value");if(e===this.it)return this._t;this.it=e;const t=[e];return t.raw=t,this._t={_$litType$:this.constructor.resultType,strings:t,values:[]}}}z2.directiveName="unsafeHTML",z2.resultType=1;/**
2472
+ */class z2 extends r2{constructor(e){if(super(e),this.it=f,e.type!==I1.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(e){if(e===f||e==null)return this._t=void 0,this.it=e;if(e===p1)return e;if(typeof e!="string")throw Error(this.constructor.directiveName+"() called with a non-string value");if(e===this.it)return this._t;this.it=e;const t=[e];return t.raw=t,this._t={_$litType$:this.constructor.resultType,strings:t,values:[]}}}z2.directiveName="unsafeHTML",z2.resultType=1;/**
2473
2473
  * @license
2474
2474
  * Copyright 2017 Google LLC
2475
2475
  * SPDX-License-Identifier: BSD-3-Clause
@@ -2638,7 +2638,7 @@
2638
2638
  >
2639
2639
  ${A7(e.paths)}
2640
2640
  </svg>
2641
- `:g}};zs.styles=p`
2641
+ `:f}};zs.styles=p`
2642
2642
  :host { display: inline-flex; align-items: center; justify-content: center; }
2643
2643
  svg { display: block; }
2644
2644
  `;let xt=zs;$4([l()],xt.prototype,"type");$4([l({type:Number})],xt.prototype,"size");customElements.get("anduin-file-icon")||customElements.define("anduin-file-icon",xt);var T7=Object.defineProperty,je=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&T7(e,t,i),i};const sa={gray:"info",primary:"infoCircleLine",success:"checkCircle",warning:"warning",danger:"error"},D7="anduin-toast:dismiss",Is=class Is extends C{constructor(){super(...arguments),this.variant="gray",this.heading="",this.description="",this._dismissing=!1}dismiss(){var t;if(this._dismissing)return;this._dismissing=!0;const e=o=>{var i;o.propertyName==="opacity"&&((i=this._toastEl)==null||i.removeEventListener("transitionend",e),this.dispatchEvent(new CustomEvent(D7,{bubbles:!0,composed:!0})))};(t=this._toastEl)==null||t.addEventListener("transitionend",e)}_onClose(){this.dismiss()}render(){const e=sa[this.variant]??sa.gray;return d`
@@ -2984,7 +2984,7 @@
2984
2984
  .thumb--checked { transform: translateX(12px); }
2985
2985
  .label { font-size: 13px; line-height: 20px; color: var(--color-foreground); }
2986
2986
  .label:not(.has-content) { display: none; }
2987
- `;let b1=Bn;ke([l({converter:w,reflect:!0})],b1.prototype,"checked",1);ke([l({attribute:"default-checked",converter:w})],b1.prototype,"defaultChecked",2);ke([l({converter:w,reflect:!0})],b1.prototype,"disabled",2);ke([l()],b1.prototype,"label",2);ke([b()],b1.prototype,"_controlled",2);ke([b()],b1.prototype,"_uncontrolledChecked",2);ke([b()],b1.prototype,"_hasLabel",2);ke([b()],b1.prototype,"_fieldLabel",2);customElements.get("anduin-switch")||customElements.define("anduin-switch",b1);var N7=Object.defineProperty,W=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&N7(e,t,i),i};const F2="anduin-dropdown:change",Ns=class Ns extends C{constructor(){super(...arguments),this.value="",this.placeholder="Select...",this.options=[],this.icon="",this.searchable=!0,this.disabled=!1,this.placement="bottom-start",this.appearance="filled",this.variant="gray0",this.size="default",this.fullWidth=!1,this.clearable=!0,this._open=!1,this._query="",this._activeIndex=-1,this._onOutsideClick=e=>{var t;!this.contains(e.target)&&!((t=this.shadowRoot)!=null&&t.contains(e.target))&&(this._open=!1,this._query="",this._activeIndex=-1)},this._onScrollOrResize=()=>{this._open&&this._updatePosition()}}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this._onOutsideClick),window.addEventListener("scroll",this._onScrollOrResize,{passive:!0,capture:!0}),window.addEventListener("resize",this._onScrollOrResize)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this._onOutsideClick),window.removeEventListener("scroll",this._onScrollOrResize,{capture:!0}),window.removeEventListener("resize",this._onScrollOrResize)}updated(e){var t,o;e.has("_activeIndex")&&this._activeIndex>=0&&((o=(t=this.shadowRoot)==null?void 0:t.querySelector(".option--active"))==null||o.scrollIntoView({block:"nearest"})),e.has("_open")&&this._open&&requestAnimationFrame(()=>{var i,s;if(this._updatePosition(),this.searchable){const r=(s=(i=this._searchEl)==null?void 0:i.shadowRoot)==null?void 0:s.querySelector("input");r==null||r.focus()}})}_onTriggerClick(){this.disabled||(this._open=!this._open,this._activeIndex=-1,this._open||(this._query=""))}_onKeyDown(e){var t;if(e.key==="Escape"){this._open=!1,this._query="",this._activeIndex=-1,(t=this._triggerEl)==null||t.focus();return}if(this._open){if(e.key==="ArrowDown"||e.key==="ArrowUp")e.preventDefault(),this._moveActive(e.key==="ArrowDown"?1:-1);else if(e.key==="Enter"&&this._activeIndex>=0){e.preventDefault();const o=this._filteredOptions[this._activeIndex];o&&this._selectOption(o)}}}_moveActive(e){const t=this._filteredOptions;for(let o=this._activeIndex+e;o>=0&&o<t.length;o+=e)if(!t[o].disabled){this._activeIndex=o;return}}_onClear(e){e.stopPropagation(),this.clearable&&(this.value="",this.dispatchEvent(new CustomEvent(F2,{detail:"",bubbles:!0,composed:!0})))}_selectOption(e){e.disabled||(this.value=e.value,this._open=!1,this._query="",this._activeIndex=-1,this.dispatchEvent(new CustomEvent(F2,{detail:e.value,bubbles:!0,composed:!0})))}_updatePosition(){const e=this._triggerEl,t=this._panelEl;if(!e||!t)return;const o=e.getBoundingClientRect(),i=t.style.transform;t.style.transform="none";const s=t.getBoundingClientRect();t.style.transform=i;const r=t.querySelector(".panel__inner");r&&(r.style.minWidth=`${o.width}px`);const a=t.getBoundingClientRect(),c=4,u=window.innerWidth,h=window.innerHeight,f=8,m=h-o.bottom-c,v=o.top-c,x=a.height<=m||m>=v?o.bottom+c:o.top-a.height-c;let y=o.left;this.placement==="bottom-end"?y=o.right-a.width:this.placement==="bottom"&&(y=o.left+o.width/2-a.width/2),y=Math.max(f,Math.min(y,u-a.width-f));const V=Math.max(f,Math.min(x,h-a.height-f));t.style.transform=`translate(${Math.round(y-s.left)}px, ${Math.round(V-s.top)}px)`}get _filteredOptions(){if(!this._query)return this.options;const e=this._query.toLowerCase();return this.options.filter(t=>t.label.toLowerCase().includes(e))}render(){const e=this.options.find(r=>r.value===this.value),t=(e==null?void 0:e.label)??"",o=e?e.icon??"":this.icon,i=this._filteredOptions,s=this.clearable&&!!this.value&&!this.disabled;return d`
2987
+ `;let b1=Bn;ke([l({converter:w,reflect:!0})],b1.prototype,"checked",1);ke([l({attribute:"default-checked",converter:w})],b1.prototype,"defaultChecked",2);ke([l({converter:w,reflect:!0})],b1.prototype,"disabled",2);ke([l()],b1.prototype,"label",2);ke([b()],b1.prototype,"_controlled",2);ke([b()],b1.prototype,"_uncontrolledChecked",2);ke([b()],b1.prototype,"_hasLabel",2);ke([b()],b1.prototype,"_fieldLabel",2);customElements.get("anduin-switch")||customElements.define("anduin-switch",b1);var N7=Object.defineProperty,W=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&N7(e,t,i),i};const F2="anduin-dropdown:change",Ns=class Ns extends C{constructor(){super(...arguments),this.value="",this.placeholder="Select...",this.options=[],this.icon="",this.searchable=!0,this.disabled=!1,this.placement="bottom-start",this.appearance="filled",this.variant="gray0",this.size="default",this.fullWidth=!1,this.clearable=!0,this._open=!1,this._query="",this._activeIndex=-1,this._onOutsideClick=e=>{var t;!this.contains(e.target)&&!((t=this.shadowRoot)!=null&&t.contains(e.target))&&(this._open=!1,this._query="",this._activeIndex=-1)},this._onScrollOrResize=()=>{this._open&&this._updatePosition()}}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this._onOutsideClick),window.addEventListener("scroll",this._onScrollOrResize,{passive:!0,capture:!0}),window.addEventListener("resize",this._onScrollOrResize)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this._onOutsideClick),window.removeEventListener("scroll",this._onScrollOrResize,{capture:!0}),window.removeEventListener("resize",this._onScrollOrResize)}updated(e){var t,o;e.has("_activeIndex")&&this._activeIndex>=0&&((o=(t=this.shadowRoot)==null?void 0:t.querySelector(".option--active"))==null||o.scrollIntoView({block:"nearest"})),e.has("_open")&&this._open&&requestAnimationFrame(()=>{var i,s;if(this._updatePosition(),this.searchable){const r=(s=(i=this._searchEl)==null?void 0:i.shadowRoot)==null?void 0:s.querySelector("input");r==null||r.focus()}})}_onTriggerClick(){this.disabled||(this._open=!this._open,this._activeIndex=-1,this._open||(this._query=""))}_onKeyDown(e){var t;if(e.key==="Escape"){this._open=!1,this._query="",this._activeIndex=-1,(t=this._triggerEl)==null||t.focus();return}if(this._open){if(e.key==="ArrowDown"||e.key==="ArrowUp")e.preventDefault(),this._moveActive(e.key==="ArrowDown"?1:-1);else if(e.key==="Enter"&&this._activeIndex>=0){e.preventDefault();const o=this._filteredOptions[this._activeIndex];o&&this._selectOption(o)}}}_moveActive(e){const t=this._filteredOptions;for(let o=this._activeIndex+e;o>=0&&o<t.length;o+=e)if(!t[o].disabled){this._activeIndex=o;return}}_onClear(e){e.stopPropagation(),this.clearable&&(this.value="",this.dispatchEvent(new CustomEvent(F2,{detail:"",bubbles:!0,composed:!0})))}_selectOption(e){e.disabled||(this.value=e.value,this._open=!1,this._query="",this._activeIndex=-1,this.dispatchEvent(new CustomEvent(F2,{detail:e.value,bubbles:!0,composed:!0})))}_updatePosition(){const e=this._triggerEl,t=this._panelEl;if(!e||!t)return;const o=e.getBoundingClientRect(),i=t.style.transform;t.style.transform="none";const s=t.getBoundingClientRect();t.style.transform=i;const r=t.querySelector(".panel__inner");r&&(r.style.minWidth=`${o.width}px`);const a=t.getBoundingClientRect(),c=4,u=window.innerWidth,h=window.innerHeight,g=8,m=h-o.bottom-c,v=o.top-c,x=a.height<=m||m>=v?o.bottom+c:o.top-a.height-c;let y=o.left;this.placement==="bottom-end"?y=o.right-a.width:this.placement==="bottom"&&(y=o.left+o.width/2-a.width/2),y=Math.max(g,Math.min(y,u-a.width-g));const V=Math.max(g,Math.min(x,h-a.height-g));t.style.transform=`translate(${Math.round(y-s.left)}px, ${Math.round(V-s.top)}px)`}get _filteredOptions(){if(!this._query)return this.options;const e=this._query.toLowerCase();return this.options.filter(t=>t.label.toLowerCase().includes(e))}render(){const e=this.options.find(r=>r.value===this.value),t=(e==null?void 0:e.label)??"",o=e?e.icon??"":this.icon,i=this._filteredOptions,s=this.clearable&&!!this.value&&!this.disabled;return d`
2988
2988
  <button
2989
2989
  class="trigger trigger--${this.appearance} trigger--${this.variant}${this.size==="small"?" trigger--small":""}${this.value?" has-value":""}"
2990
2990
  part="trigger"
@@ -2994,7 +2994,7 @@
2994
2994
  @click=${this._onTriggerClick}
2995
2995
  @keydown=${this._onKeyDown}
2996
2996
  >
2997
- ${o&&t?d`<anduin-icon name="${o}" size="16"></anduin-icon>`:g}
2997
+ ${o&&t?d`<anduin-icon name="${o}" size="16"></anduin-icon>`:f}
2998
2998
  <span class="trigger__label${t?"":" trigger__label--placeholder"}">${t||this.placeholder}</span>
2999
2999
  <span class="trigger__caret${s?" trigger__caret--clearable":""}">
3000
3000
  <span class="trigger__chevron">
@@ -3004,7 +3004,7 @@
3004
3004
  <span class="trigger__clear" @click=${this._onClear}>
3005
3005
  <anduin-icon name="crossSmall" size="16"></anduin-icon>
3006
3006
  </span>
3007
- `:g}
3007
+ `:f}
3008
3008
  </span>
3009
3009
  </button>
3010
3010
 
@@ -3018,21 +3018,21 @@
3018
3018
  @anduin-input:change=${r=>{this._query=r.detail,this._activeIndex=-1}}
3019
3019
  ></anduin-input>
3020
3020
  </div>
3021
- `:g}
3021
+ `:f}
3022
3022
  <div class="options">
3023
3023
  ${i.length?i.map((r,a)=>d`
3024
3024
  <div
3025
3025
  class="option${r.disabled?" option--disabled":""}${r.description?" option--described":""}${a===this._activeIndex?" option--active":""}"
3026
3026
  role="option"
3027
3027
  aria-selected=${r.value===this.value}
3028
- aria-disabled=${r.disabled?"true":g}
3028
+ aria-disabled=${r.disabled?"true":f}
3029
3029
  @click=${()=>this._selectOption(r)}
3030
3030
  @mouseenter=${()=>{this._activeIndex>=0&&!r.disabled&&(this._activeIndex=a)}}
3031
3031
  >
3032
3032
  <span class="option__check">
3033
- ${r.value===this.value?d`<anduin-icon name="checkSmall" size="16"></anduin-icon>`:g}
3033
+ ${r.value===this.value?d`<anduin-icon name="checkSmall" size="16"></anduin-icon>`:f}
3034
3034
  </span>
3035
- ${r.icon?d`<anduin-icon name="${r.icon}" size="16"></anduin-icon>`:g}
3035
+ ${r.icon?d`<anduin-icon name="${r.icon}" size="16"></anduin-icon>`:f}
3036
3036
  ${r.description?d`<span class="option__text">
3037
3037
  <span class="option__label">${r.label}</span>
3038
3038
  <span class="option__description" part="option-description">${r.description}</span>
@@ -3293,7 +3293,7 @@
3293
3293
  text-align: center;
3294
3294
  }
3295
3295
  `;let O=Ns;W([l()],O.prototype,"value");W([l()],O.prototype,"placeholder");W([l({attribute:!1})],O.prototype,"options");W([l()],O.prototype,"icon");W([l({type:Boolean})],O.prototype,"searchable");W([l({type:Boolean})],O.prototype,"disabled");W([l()],O.prototype,"placement");W([l()],O.prototype,"appearance");W([l()],O.prototype,"variant");W([l()],O.prototype,"size");W([l({type:Boolean,attribute:"full-width",reflect:!0})],O.prototype,"fullWidth");W([l({converter:n=>n!=="false"})],O.prototype,"clearable");W([b()],O.prototype,"_open");W([b()],O.prototype,"_query");W([b()],O.prototype,"_activeIndex");W([E(".trigger")],O.prototype,"_triggerEl");W([E(".panel")],O.prototype,"_panelEl");W([E("anduin-input")],O.prototype,"_searchEl");customElements.get("anduin-dropdown")||customElements.define("anduin-dropdown",O);var U7=Object.defineProperty,J1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&U7(e,t,i),i};const nt="anduin-close",Ki="anduin-after-close",G7=300,ra=250,q7=new Map([["320",320],["360",360],["400",400],["640",640]]),Us=class Us extends C{constructor(){super(...arguments),this.open=!1,this.heading="",this.hideHeader=!1,this.hideFooter=!1,this.defaultWidth="320",this.placement="right",this.allowInteractOutside=!1,this._leaving=!1,this._width=320,this._resizing=!1,this._startX=0,this._startWidth=0,this._stopAtSelf=e=>{e.stopPropagation()},this._onResizeStart=e=>{this._resizing=!0,this._startX=e.clientX,this._startWidth=this._width,e.currentTarget.setPointerCapture(e.pointerId),e.preventDefault()},this._onResizeMove=e=>{var s;if(!this._resizing)return;const t=this.placement==="left"?e.clientX-this._startX:this._startX-e.clientX,o=Math.max(200,Math.min(window.innerWidth*.9,this._startWidth+t));this._width=Math.round(o);const i=(s=this.shadowRoot)==null?void 0:s.querySelector(".drawer");i&&(i.style.width=`${this._width}px`)},this._onResizeEnd=()=>{this._resizing=!1}}willUpdate(e){e.has("defaultWidth")&&(this._width=q7.get(this.defaultWidth)??(parseInt(this.defaultWidth)||320))}updated(e){e.has("open")&&(this.open?(this._leaving=!1,this.classList.add("is-shown")):this.classList.contains("is-shown")&&(this._leaving=!0,setTimeout(()=>{this._leaving=!1,this.classList.remove("is-shown"),this.dispatchEvent(new CustomEvent(Ki,{bubbles:!0,composed:!0}))},ra)))}_dispatch(e){this.dispatchEvent(new CustomEvent(e,{bubbles:!0,composed:!0}))}connectedCallback(){super.connectedCallback(),this.addEventListener(nt,this._stopAtSelf),this.addEventListener(Ki,this._stopAtSelf)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(nt,this._stopAtSelf),this.removeEventListener(Ki,this._stopAtSelf)}_onClose(){this._dispatch(nt)}_onBackdropClick(){this._dispatch(nt)}render(){const e=this._leaving;return d`
3296
- ${this.allowInteractOutside?g:d`<div class="backdrop" @click=${this._onBackdropClick}></div>`}
3296
+ ${this.allowInteractOutside?f:d`<div class="backdrop" @click=${this._onBackdropClick}></div>`}
3297
3297
  <div
3298
3298
  class=${`drawer${e?" is-leaving":""}`}
3299
3299
  style="width: ${this._width}px"
@@ -3308,11 +3308,11 @@
3308
3308
  @pointerup=${this._onResizeEnd}
3309
3309
  @pointercancel=${this._onResizeEnd}
3310
3310
  ></div>
3311
- ${this.hideHeader?g:d` <div class="header">
3311
+ ${this.hideHeader?f:d` <div class="header">
3312
3312
  <slot name="header">
3313
3313
  ${this.heading?d`<span id="drawer-title" class="title"
3314
3314
  >${this.heading}</span
3315
- >`:g}
3315
+ >`:f}
3316
3316
  </slot>
3317
3317
  <anduin-button
3318
3318
  appearance="plain"
@@ -3326,7 +3326,7 @@
3326
3326
  <div class="body">
3327
3327
  <slot></slot>
3328
3328
  </div>
3329
- ${this.hideFooter?g:d`<div class="footer"><slot name="footer"></slot></div>`}
3329
+ ${this.hideFooter?f:d`<div class="footer"><slot name="footer"></slot></div>`}
3330
3330
  </div>
3331
3331
  `}};Us.styles=p`${B}
3332
3332
 
@@ -3491,7 +3491,7 @@
3491
3491
  padding: 16px 20px;
3492
3492
  border-top: 1px solid var(--color-border);
3493
3493
  }
3494
- `;let f1=Us;J1([l({type:Boolean,reflect:!0})],f1.prototype,"open");J1([l()],f1.prototype,"heading");J1([l({type:Boolean,attribute:"hide-header"})],f1.prototype,"hideHeader");J1([l({type:Boolean,attribute:"hide-footer"})],f1.prototype,"hideFooter");J1([l({attribute:"default-width"})],f1.prototype,"defaultWidth");J1([l({reflect:!0})],f1.prototype,"placement");J1([l({type:Boolean,attribute:"allow-interact-outside"})],f1.prototype,"allowInteractOutside");J1([b()],f1.prototype,"_leaving");J1([b()],f1.prototype,"_width");customElements.get("anduin-drawer")||customElements.define("anduin-drawer",f1);class S4 extends HTMLElement{constructor(){super(...arguments),this._onClick=()=>{this.dispatchEvent(new CustomEvent(nt,{bubbles:!0,composed:!0}))}}connectedCallback(){this.style.display="contents",this.addEventListener("click",this._onClick)}disconnectedCallback(){this.removeEventListener("click",this._onClick)}}customElements.get("anduin-drawer-close")||customElements.define("anduin-drawer-close",S4);const la={top:"bottom",bottom:"top",left:"right",right:"left"};function O4(n){const[e,t]=(n||"bottom-start").split("-"),o=["top","bottom","left","right"].includes(e)?e:"bottom",i=["start","center","end"].includes(t)?t:"start";return{side:o,align:i}}function T4(n,e=4,t=8){const o=window.innerWidth,i=window.innerHeight;return{top:n.top-e-t,bottom:i-n.bottom-e-t,left:n.left-e-t,right:o-n.right-e-t}}function K7(n,e,t,o={}){const{gap:i=4,margin:s=8,flip:r=!0}=o,{side:a,align:c}=O4(t),u=T4(n,i,s),h=a==="top"||a==="bottom"?e.height:e.width;let f=a;return r&&h>u[a]&&u[la[a]]>u[a]&&(f=la[a]),{side:f,align:c,room:u[f]}}function D4(n,e,t="bottom-start",o={}){const{gap:i=4,margin:s=8,flip:r=!0}=o,a=e.style.transform;e.style.transform="none";const c=e.getBoundingClientRect();e.style.transform=a;const u=e.getBoundingClientRect(),{side:h,align:f}=O4(t),m=window.innerWidth,v=window.innerHeight;let _=h;if(r)if(h==="bottom"||h==="top"){const V=v-n.bottom-i,k=n.top-i,M=u.height<=V||V>=k,$=u.height<=k||k>=V;_=h==="bottom"?M?"bottom":"top":$?"top":"bottom"}else{const V=m-n.right-i,k=n.left-i,M=u.width<=V||V>=k,$=u.width<=k||k>=V;_=h==="right"?M?"right":"left":$?"left":"right"}let x,y;return _==="bottom"||_==="top"?(y=_==="bottom"?n.bottom+i:n.top-u.height-i,x=f==="start"?n.left:f==="end"?n.right-u.width:n.left+n.width/2-u.width/2):(x=_==="right"?n.right+i:n.left-u.width-i,y=f==="start"?n.top:f==="end"?n.bottom-u.height:n.top+n.height/2-u.height/2),x=Math.max(s,Math.min(x,m-u.width-s)),y=Math.max(s,Math.min(y,v-u.height-s)),e.style.transform=`translate(${Math.round(x-c.left)}px, ${Math.round(y-c.top)}px)`,{side:_,align:f,room:T4(n,i,s)[_]}}const P4=p`
3494
+ `;let g1=Us;J1([l({type:Boolean,reflect:!0})],g1.prototype,"open");J1([l()],g1.prototype,"heading");J1([l({type:Boolean,attribute:"hide-header"})],g1.prototype,"hideHeader");J1([l({type:Boolean,attribute:"hide-footer"})],g1.prototype,"hideFooter");J1([l({attribute:"default-width"})],g1.prototype,"defaultWidth");J1([l({reflect:!0})],g1.prototype,"placement");J1([l({type:Boolean,attribute:"allow-interact-outside"})],g1.prototype,"allowInteractOutside");J1([b()],g1.prototype,"_leaving");J1([b()],g1.prototype,"_width");customElements.get("anduin-drawer")||customElements.define("anduin-drawer",g1);class S4 extends HTMLElement{constructor(){super(...arguments),this._onClick=()=>{this.dispatchEvent(new CustomEvent(nt,{bubbles:!0,composed:!0}))}}connectedCallback(){this.style.display="contents",this.addEventListener("click",this._onClick)}disconnectedCallback(){this.removeEventListener("click",this._onClick)}}customElements.get("anduin-drawer-close")||customElements.define("anduin-drawer-close",S4);const la={top:"bottom",bottom:"top",left:"right",right:"left"};function O4(n){const[e,t]=(n||"bottom-start").split("-"),o=["top","bottom","left","right"].includes(e)?e:"bottom",i=["start","center","end"].includes(t)?t:"start";return{side:o,align:i}}function T4(n,e=4,t=8){const o=window.innerWidth,i=window.innerHeight;return{top:n.top-e-t,bottom:i-n.bottom-e-t,left:n.left-e-t,right:o-n.right-e-t}}function K7(n,e,t,o={}){const{gap:i=4,margin:s=8,flip:r=!0}=o,{side:a,align:c}=O4(t),u=T4(n,i,s),h=a==="top"||a==="bottom"?e.height:e.width;let g=a;return r&&h>u[a]&&u[la[a]]>u[a]&&(g=la[a]),{side:g,align:c,room:u[g]}}function D4(n,e,t="bottom-start",o={}){const{gap:i=4,margin:s=8,flip:r=!0}=o,a=e.style.transform;e.style.transform="none";const c=e.getBoundingClientRect();e.style.transform=a;const u=e.getBoundingClientRect(),{side:h,align:g}=O4(t),m=window.innerWidth,v=window.innerHeight;let _=h;if(r)if(h==="bottom"||h==="top"){const V=v-n.bottom-i,L=n.top-i,M=u.height<=V||V>=L,$=u.height<=L||L>=V;_=h==="bottom"?M?"bottom":"top":$?"top":"bottom"}else{const V=m-n.right-i,L=n.left-i,M=u.width<=V||V>=L,$=u.width<=L||L>=V;_=h==="right"?M?"right":"left":$?"left":"right"}let x,y;return _==="bottom"||_==="top"?(y=_==="bottom"?n.bottom+i:n.top-u.height-i,x=g==="start"?n.left:g==="end"?n.right-u.width:n.left+n.width/2-u.width/2):(x=_==="right"?n.right+i:n.left-u.width-i,y=g==="start"?n.top:g==="end"?n.bottom-u.height:n.top+n.height/2-u.height/2),x=Math.max(s,Math.min(x,m-u.width-s)),y=Math.max(s,Math.min(y,v-u.height-s)),e.style.transform=`translate(${Math.round(x-c.left)}px, ${Math.round(y-c.top)}px)`,{side:_,align:g,room:T4(n,i,s)[_]}}const P4=p`
3495
3495
  .panel {
3496
3496
  position: fixed;
3497
3497
  top: 0;
@@ -3518,7 +3518,7 @@
3518
3518
  <span class="input__start">
3519
3519
  <anduin-icon name=${this.startIcon} size=${r}></anduin-icon>
3520
3520
  </span>
3521
- `:g}
3521
+ `:f}
3522
3522
 
3523
3523
  <input
3524
3524
  class="input ${e}
@@ -3547,26 +3547,26 @@
3547
3547
  <button class="input__clear" type="button" @click=${this._onClear} aria-label="Clear">
3548
3548
  <anduin-icon name="cross" size=${a}></anduin-icon>
3549
3549
  </button>
3550
- `:g}
3550
+ `:f}
3551
3551
  ${this.endIcon?d`
3552
3552
  <anduin-icon name=${this.endIcon} size=${r}></anduin-icon>
3553
- `:g}
3553
+ `:f}
3554
3554
  </span>
3555
- `:g}
3555
+ `:f}
3556
3556
  </div>
3557
3557
 
3558
3558
  <div class="panel${u?" panel--open":""}" part="panel">
3559
3559
  <div class="panel__inner" role="listbox">
3560
3560
  <div class="options">
3561
- ${c.length?c.map((h,f)=>d`
3561
+ ${c.length?c.map((h,g)=>d`
3562
3562
  <div
3563
- class="option${f===this._activeIndex?" option--active":""}"
3563
+ class="option${g===this._activeIndex?" option--active":""}"
3564
3564
  role="option"
3565
- aria-selected=${f===this._activeIndex}
3566
- @mouseenter=${()=>{this._activeIndex=f}}
3565
+ aria-selected=${g===this._activeIndex}
3566
+ @mouseenter=${()=>{this._activeIndex=g}}
3567
3567
  @mousedown=${m=>{m.preventDefault(),this._selectSuggestion(h)}}
3568
3568
  >
3569
- ${h.icon?d`<anduin-icon name=${h.icon} size="16"></anduin-icon>`:g}
3569
+ ${h.icon?d`<anduin-icon name=${h.icon} size="16"></anduin-icon>`:f}
3570
3570
  <span class="option__label">${h.label??h.value}</span>
3571
3571
  </div>
3572
3572
  `):d`<div class="empty">${this.emptyText}</div>`}
@@ -3716,7 +3716,7 @@
3716
3716
  .navigation--center { justify-content: center; }
3717
3717
  .navigation--right { justify-content: flex-end; }
3718
3718
  `;let A1=qs;k1([l({attribute:"default-value"})],A1.prototype,"defaultValue");k1([l()],A1.prototype,"value");k1([l({reflect:!0})],A1.prototype,"theme");k1([l()],A1.prototype,"alignment");k1([b()],A1.prototype,"internalValue");const Ks=class Ks extends C{constructor(){super(...arguments),this.value="",this.startIcon="",this.href="",this.disabled=!1,this.selected=!1,this.theme="light"}onClick(e){if(this.disabled){e.preventDefault();return}this.dispatchEvent(new CustomEvent(hi,{detail:this.value,bubbles:!0,composed:!0}))}updated(e){e.has("selected")&&this.setAttribute("aria-current",this.selected?"page":"false")}render(){const e=["nav-item",this.selected?"nav-item--active":"",this.disabled?"nav-item--disabled":""].filter(Boolean).join(" "),t=d`
3719
- ${this.startIcon?d`<span class="nav-item__icon"><anduin-icon name="${this.startIcon}" size="16"></anduin-icon></span>`:g}
3719
+ ${this.startIcon?d`<span class="nav-item__icon"><anduin-icon name="${this.startIcon}" size="16"></anduin-icon></span>`:f}
3720
3720
  <slot></slot>
3721
3721
  `;return this.href?d`
3722
3722
  <a
@@ -3795,7 +3795,7 @@
3795
3795
  .panel { width: 100%; height: 100%; overflow: hidden; }
3796
3796
  `;let Fe=Ws;We([l({attribute:"default-size"})],Fe.prototype,"defaultSize");We([l({attribute:"min-size"})],Fe.prototype,"minSize");We([l({attribute:"max-size"})],Fe.prototype,"maxSize");const Ys=class Ys extends C{constructor(){super(...arguments),this.withHandle=!1,this.groupVertical=!1,this.dragging=!1,this.group=null,this.startPos=0,this.startPrevPx=0,this.combinedPx=0,this.combinedGrow=0,this.activePointerId=null,this.onPointerDown=e=>{const t=this.closest("anduin-resizable-panel-group"),o=this.prevPanel,i=this.nextPanel;if(!t||!o||!i)return;e.preventDefault(),this.group=t,this.dragging=!0,this.activePointerId=e.pointerId,this.setPointerCapture(e.pointerId),t.normalizeToGrow();const s=t.isVertical;this.startPos=s?e.clientY:e.clientX,this.startPrevPx=o.axisSize(s),this.combinedPx=this.startPrevPx+i.axisSize(s),this.combinedGrow=(parseFloat(o.style.flexGrow)||0)+(parseFloat(i.style.flexGrow)||0),document.body.style.userSelect="none",document.body.style.cursor=s?"row-resize":"col-resize",window.addEventListener("pointermove",this.onPointerMove),window.addEventListener("pointerup",this.onPointerUp)},this.onPointerMove=e=>{if(!this.dragging||!this.group)return;const o=(this.group.isVertical?e.clientY:e.clientX)-this.startPos;this.resizeTo(this.startPrevPx+o)},this.onPointerUp=()=>{this.dragging&&(this.endDrag(),this.emitResize())},this.onKeyDown=e=>{const t=this.closest("anduin-resizable-panel-group");if(!t)return;const o=t.isVertical;let i=0;if(!o&&e.key==="ArrowRight")i=1;else if(!o&&e.key==="ArrowLeft")i=-1;else if(o&&e.key==="ArrowDown")i=1;else if(o&&e.key==="ArrowUp")i=-1;else return;const s=this.prevPanel,r=this.nextPanel;if(!s||!r)return;e.preventDefault(),this.group=t,t.normalizeToGrow();const a=s.axisSize(o);this.combinedPx=a+r.axisSize(o),this.combinedGrow=(parseFloat(s.style.flexGrow)||0)+(parseFloat(r.style.flexGrow)||0);const c=Math.max(t.axisSize*.02,8);this.resizeTo(a+i*c),this.emitResize()}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","separator"),this.hasAttribute("tabindex")||this.setAttribute("tabindex","0"),this.addEventListener("pointerdown",this.onPointerDown),this.addEventListener("keydown",this.onKeyDown);const e=this.closest("anduin-resizable-panel-group");e&&this.setOrientation(e.isVertical)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("pointerdown",this.onPointerDown),this.removeEventListener("keydown",this.onKeyDown),this.endDrag()}setOrientation(e){this.groupVertical=e,this.setAttribute("aria-orientation",e?"horizontal":"vertical")}get prevPanel(){return aa(this.previousElementSibling)?this.previousElementSibling:null}get nextPanel(){return aa(this.nextElementSibling)?this.nextElementSibling:null}endDrag(){if(!(!this.dragging&&this.activePointerId===null)){if(this.dragging=!1,this.activePointerId!==null){try{this.releasePointerCapture(this.activePointerId)}catch{}this.activePointerId=null}document.body.style.userSelect="",document.body.style.cursor="",window.removeEventListener("pointermove",this.onPointerMove),window.removeEventListener("pointerup",this.onPointerUp)}}resizeTo(e){const t=this.group,o=this.prevPanel,i=this.nextPanel;if(!t||!o||!i||this.combinedPx<=0)return;const s=t.axisSize,r=Math.max(o.minPx(s),this.combinedPx-i.maxPx(s),0),a=Math.min(o.maxPx(s),this.combinedPx-i.minPx(s),this.combinedPx),c=Math.max(r,Math.min(a,e)),u=this.combinedGrow*(c/this.combinedPx);o.setGrow(u),i.setGrow(this.combinedGrow-u)}emitResize(){const e=this.group,t=this.prevPanel,o=this.nextPanel;if(!e||!t||!o)return;const i=e.axisSize;if(i<=0)return;const s=e.isVertical;this.dispatchEvent(new CustomEvent(B4,{detail:{sizes:[t.axisSize(s)/i*100,o.axisSize(s)/i*100]},bubbles:!0,composed:!0}))}render(){const e=["handle",this.groupVertical?"handle--vertical":"",this.dragging?"handle--dragging":""].filter(Boolean).join(" ");return d`
3797
3797
  <div class="${e}" part="handle">
3798
- ${this.withHandle?d`<div class="handle__grip" part="grip"><anduin-icon name="ellipsisVertical" size="12" aria-label="Drag"></anduin-icon></div>`:g}
3798
+ ${this.withHandle?d`<div class="handle__grip" part="grip"><anduin-icon name="ellipsisVertical" size="12" aria-label="Drag"></anduin-icon></div>`:f}
3799
3799
  </div>
3800
3800
  `}};Ys.styles=p`
3801
3801
  :host { display: block; flex: 0 0 auto; position: relative; z-index: 1; outline: none; font-family: var(--font-sans); }
@@ -3817,7 +3817,7 @@
3817
3817
  }
3818
3818
  .handle:hover .handle__grip, .handle--dragging .handle__grip, :host(:focus-visible) .handle__grip { opacity: 1; }
3819
3819
  .handle--vertical .handle__grip { transform: rotate(90deg); }
3820
- `;let Be=Ys;We([l({type:Boolean,attribute:"with-handle"})],Be.prototype,"withHandle");We([b()],Be.prototype,"groupVertical");We([b()],Be.prototype,"dragging");customElements.get("anduin-resizable-panel-group")||customElements.define("anduin-resizable-panel-group",ui);customElements.get("anduin-resizable-panel")||customElements.define("anduin-resizable-panel",Fe);customElements.get("anduin-resizable-handle")||customElements.define("anduin-resizable-handle",Be);var X7=Object.defineProperty,Pt=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&X7(e,t,i),i};const U4="anduin-pagination:change",Ho="anduin-pagination:jump";function Ut(n,e){const t=Math.max(e-n+1,0);return Array.from({length:t},(o,i)=>n+i)}const Xs=class Xs extends C{constructor(){super(...arguments),this.numberOfPages=0,this.defaultValue=1,this.value=null,this.internalValue=1,this.indicatorReady=!1,this.onJump=e=>{e.stopPropagation(),this.goTo(e.detail==="first"?1:this.count)},this.onSlotChange=()=>this.syncBoundaryButtons()}get isControlled(){return this.value!=null}get count(){return Math.max(0,Math.floor(this.numberOfPages||0))}get selection(){const e=this.isControlled?this.value:this.internalValue;return Math.min(Math.max(Math.floor(e||1),1),Math.max(this.count,1))}connectedCallback(){super.connectedCallback(),this.hasUpdated||(this.internalValue=this.defaultValue||1),this.addEventListener(Ho,this.onJump)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(Ho,this.onJump)}buildItems(){const e=this.count,t=this.selection,o=1,i=1,s=Ut(1,Math.min(o,e)),r=Ut(Math.max(e-o+1,o+1),e),a=Math.max(Math.min(t-i,e-o-i*2-1),o+2),c=Math.min(Math.max(t+i,o+i*2+2),r.length>0?r[0]-2:e-1);return[...s,...a>o+2?["start-ellipsis"]:o+1<e-o?[o+1]:[],...Ut(a,c),...c<e-o-1?["end-ellipsis"]:e-o>o?[e-o]:[],...r].map(h=>h==="start-ellipsis"?{type:"ellipsis",pages:Ut(o+1,a-1)}:h==="end-ellipsis"?{type:"ellipsis",pages:Ut(c+1,e-o)}:{type:"page",page:h})}goTo(e){const t=this.count,o=Math.min(Math.max(Math.floor(e),1),t);o!==this.selection&&(this.isControlled||(this.internalValue=o),this.dispatchEvent(new CustomEvent(U4,{detail:o,bubbles:!0,composed:!0})))}updated(){this.syncBoundaryButtons(),requestAnimationFrame(()=>this.positionIndicator())}syncBoundaryButtons(){const e=this.selection,t=this.count;this.querySelectorAll("anduin-pagination-first-page").forEach(o=>{o.disabled=e<=1}),this.querySelectorAll("anduin-pagination-last-page").forEach(o=>{o.disabled=e>=t})}positionIndicator(){var o;const e=this.indicatorEl,t=(o=this.shadowRoot)==null?void 0:o.querySelector(".pagination__button--active");if(e){if(!t){e.style.opacity="0",this.indicatorReady=!1;return}this.indicatorReady||(e.style.transition="none"),e.style.width=`${t.offsetWidth}px`,e.style.transform=`translateX(${t.offsetLeft}px)`,e.style.opacity="1",this.indicatorReady||(e.offsetWidth,e.style.transition="",this.indicatorReady=!0)}}render(){const e=this.count;if(e<2)return g;const t=this.selection,o=this.buildItems();return d`
3820
+ `;let Be=Ys;We([l({type:Boolean,attribute:"with-handle"})],Be.prototype,"withHandle");We([b()],Be.prototype,"groupVertical");We([b()],Be.prototype,"dragging");customElements.get("anduin-resizable-panel-group")||customElements.define("anduin-resizable-panel-group",ui);customElements.get("anduin-resizable-panel")||customElements.define("anduin-resizable-panel",Fe);customElements.get("anduin-resizable-handle")||customElements.define("anduin-resizable-handle",Be);var X7=Object.defineProperty,Pt=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&X7(e,t,i),i};const U4="anduin-pagination:change",Ho="anduin-pagination:jump";function Ut(n,e){const t=Math.max(e-n+1,0);return Array.from({length:t},(o,i)=>n+i)}const Xs=class Xs extends C{constructor(){super(...arguments),this.numberOfPages=0,this.defaultValue=1,this.value=null,this.internalValue=1,this.indicatorReady=!1,this.onJump=e=>{e.stopPropagation(),this.goTo(e.detail==="first"?1:this.count)},this.onSlotChange=()=>this.syncBoundaryButtons()}get isControlled(){return this.value!=null}get count(){return Math.max(0,Math.floor(this.numberOfPages||0))}get selection(){const e=this.isControlled?this.value:this.internalValue;return Math.min(Math.max(Math.floor(e||1),1),Math.max(this.count,1))}connectedCallback(){super.connectedCallback(),this.hasUpdated||(this.internalValue=this.defaultValue||1),this.addEventListener(Ho,this.onJump)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(Ho,this.onJump)}buildItems(){const e=this.count,t=this.selection,o=1,i=1,s=Ut(1,Math.min(o,e)),r=Ut(Math.max(e-o+1,o+1),e),a=Math.max(Math.min(t-i,e-o-i*2-1),o+2),c=Math.min(Math.max(t+i,o+i*2+2),r.length>0?r[0]-2:e-1);return[...s,...a>o+2?["start-ellipsis"]:o+1<e-o?[o+1]:[],...Ut(a,c),...c<e-o-1?["end-ellipsis"]:e-o>o?[e-o]:[],...r].map(h=>h==="start-ellipsis"?{type:"ellipsis",pages:Ut(o+1,a-1)}:h==="end-ellipsis"?{type:"ellipsis",pages:Ut(c+1,e-o)}:{type:"page",page:h})}goTo(e){const t=this.count,o=Math.min(Math.max(Math.floor(e),1),t);o!==this.selection&&(this.isControlled||(this.internalValue=o),this.dispatchEvent(new CustomEvent(U4,{detail:o,bubbles:!0,composed:!0})))}updated(){this.syncBoundaryButtons(),requestAnimationFrame(()=>this.positionIndicator())}syncBoundaryButtons(){const e=this.selection,t=this.count;this.querySelectorAll("anduin-pagination-first-page").forEach(o=>{o.disabled=e<=1}),this.querySelectorAll("anduin-pagination-last-page").forEach(o=>{o.disabled=e>=t})}positionIndicator(){var o;const e=this.indicatorEl,t=(o=this.shadowRoot)==null?void 0:o.querySelector(".pagination__button--active");if(e){if(!t){e.style.opacity="0",this.indicatorReady=!1;return}this.indicatorReady||(e.style.transition="none"),e.style.width=`${t.offsetWidth}px`,e.style.transform=`translateX(${t.offsetLeft}px)`,e.style.opacity="1",this.indicatorReady||(e.offsetWidth,e.style.transition="",this.indicatorReady=!0)}}render(){const e=this.count;if(e<2)return f;const t=this.selection,o=this.buildItems();return d`
3821
3821
  <div class="pagination">
3822
3822
  <div class="pagination__indicator"></div>
3823
3823
  <slot name="start" @slotchange=${this.onSlotChange}></slot>
@@ -3843,7 +3843,7 @@
3843
3843
  `}renderItem(e,t){if(e.type==="page"){const s=e.page===t;return d`
3844
3844
  <button
3845
3845
  class="pagination__button ${s?"pagination__button--active":""}"
3846
- aria-current=${s?"page":g}
3846
+ aria-current=${s?"page":f}
3847
3847
  aria-label="Go to page ${e.page}"
3848
3848
  @click=${()=>this.goTo(e.page)}
3849
3849
  >${e.page}</button>
@@ -4185,7 +4185,7 @@
4185
4185
  :host([divider]) {
4186
4186
  border-top: 1px solid var(--color-border);
4187
4187
  }
4188
- `;let fi=ar;Ye([l({type:Boolean,reflect:!0})],fi.prototype,"divider");const dr=class dr extends C{render(){return d`<div class="sidebar-group" part="group" role="group"><slot></slot></div>`}};dr.styles=p`
4188
+ `;let gi=ar;Ye([l({type:Boolean,reflect:!0})],gi.prototype,"divider");const dr=class dr extends C{render(){return d`<div class="sidebar-group" part="group" role="group"><slot></slot></div>`}};dr.styles=p`
4189
4189
  :host {
4190
4190
  display: block;
4191
4191
  }
@@ -4241,16 +4241,16 @@
4241
4241
  gap: 2px;
4242
4242
  }
4243
4243
  `;let Oo=hr;const ur=class ur extends C{constructor(){super(...arguments),this.startIcon="",this.selected=!1,this.disabled=!1,this.href="",this.openNewTab=!1,this.onClick=e=>{if(this.disabled){e.preventDefault(),e.stopPropagation();return}this.dispatchEvent(new CustomEvent(K4,{detail:this,bubbles:!0,composed:!0}))}}render(){const e=["sidebar-menu-item-wrapper",this.disabled?"sidebar-menu-item-wrapper--disabled":"sidebar-menu-item-wrapper--interactive",this.selected?"sidebar-menu-item-wrapper--selected":""].filter(Boolean).join(" "),t=["sidebar-menu-item",this.disabled?"sidebar-menu-item--disabled":""].filter(Boolean).join(" "),o=d`
4244
- ${this.startIcon?d`<anduin-icon class="sidebar-menu-item__icon" name="${this.startIcon}" size="16"></anduin-icon>`:g}
4244
+ ${this.startIcon?d`<anduin-icon class="sidebar-menu-item__icon" name="${this.startIcon}" size="16"></anduin-icon>`:f}
4245
4245
  <span class="sidebar-menu-item__label"><slot></slot></span>
4246
4246
  <slot name="badge" class="sidebar-menu-item__badge"></slot>
4247
4247
  `,i=this.href?d`
4248
4248
  <a
4249
4249
  class="${t}"
4250
4250
  part="menu-item"
4251
- href="${this.disabled?g:this.href}"
4251
+ href="${this.disabled?f:this.href}"
4252
4252
  target="${this.openNewTab?"_blank":"_self"}"
4253
- rel="${this.openNewTab?"noreferrer noopener":g}"
4253
+ rel="${this.openNewTab?"noreferrer noopener":f}"
4254
4254
  aria-current="${this.selected?"page":"false"}"
4255
4255
  aria-disabled="${this.disabled?"true":"false"}"
4256
4256
  tabindex="${this.disabled?"-1":"0"}"
@@ -4375,7 +4375,7 @@
4375
4375
  display: flex;
4376
4376
  align-items: center;
4377
4377
  }
4378
- `;let Do=Cr;const fr=class fr extends C{connectedCallback(){super.connectedCallback(),this.hasAttribute("role")||this.setAttribute("role","separator")}render(){return d`<div class="sidebar-separator" part="separator"></div>`}};fr.styles=p`
4378
+ `;let Do=Cr;const gr=class gr extends C{connectedCallback(){super.connectedCallback(),this.hasAttribute("role")||this.setAttribute("role","separator")}render(){return d`<div class="sidebar-separator" part="separator"></div>`}};gr.styles=p`
4379
4379
  :host {
4380
4380
  display: block;
4381
4381
  }
@@ -4383,7 +4383,7 @@
4383
4383
  height: 1px;
4384
4384
  background-color: var(--color-border);
4385
4385
  }
4386
- `;let Po=fr;customElements.get("anduin-sidebar")||customElements.define("anduin-sidebar",Zo);customElements.get("anduin-sidebar-content")||customElements.define("anduin-sidebar-content",Ro);customElements.get("anduin-sidebar-header")||customElements.define("anduin-sidebar-header",Ci);customElements.get("anduin-sidebar-footer")||customElements.define("anduin-sidebar-footer",fi);customElements.get("anduin-sidebar-group")||customElements.define("anduin-sidebar-group",Ao);customElements.get("anduin-sidebar-group-label")||customElements.define("anduin-sidebar-group-label",So);customElements.get("anduin-sidebar-menu")||customElements.define("anduin-sidebar-menu",Oo);customElements.get("anduin-sidebar-menu-item")||customElements.define("anduin-sidebar-menu-item",q1);customElements.get("anduin-sidebar-action")||customElements.define("anduin-sidebar-action",To);customElements.get("anduin-sidebar-badge")||customElements.define("anduin-sidebar-badge",Do);customElements.get("anduin-sidebar-separator")||customElements.define("anduin-sidebar-separator",Po);function X(n){if(!n)return null;const e=/^(\d{4})-(\d{1,2})-(\d{1,2})$/.exec(n.trim());if(!e)return null;const[t,o,i]=[Number(e[1]),Number(e[2]),Number(e[3])],s=new Date(t,o-1,i);return s.getFullYear()!==t||s.getMonth()!==o-1||s.getDate()!==i?null:s}function ae(n){const e=t=>String(t).padStart(2,"0");return`${n.getFullYear()}-${e(n.getMonth()+1)}-${e(n.getDate())}`}function $e(){const n=new Date;return new Date(n.getFullYear(),n.getMonth(),n.getDate())}function z1(n,e){const t=n.getFullYear(),o=n.getMonth()+e,i=new Date(t,o+1,0).getDate();return new Date(t,o,Math.min(n.getDate(),i))}function Q7(n,e){return new Date(n,e+1,0).getDate()}var e9=Object.defineProperty,D1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&e9(e,t,i),i};const Lt="anduin-calendar:change",zo="anduin-calendar:day-hover",ca=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],ha=["January","February","March","April","May","June","July","August","September","October","November","December"],t9=["Su","Mo","Tu","We","Th","Fr","Sa"],ua=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function et(n,e){return new Date(n.getFullYear(),n.getMonth(),n.getDate()+e)}function i9(n){const e=["th","st","nd","rd"],t=n%100;return`${n}${e[(t-20)%10]??e[t]??e[0]}`}const gr=class gr extends C{constructor(){super(...arguments),this.value="",this.minDate="",this.maxDate="",this.rangeStart="",this.rangeEnd="",this.rangeMode=!1,this._viewMonth=$e().getMonth(),this._viewYear=$e().getFullYear(),this._focus="",this._openSelect=null,this._viewSeeded=!1,this._pendingFocus=!1,this._onOutsideClick=e=>{this._openSelect&&!e.composedPath().includes(this)&&(this._openSelect=null)}}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this._onOutsideClick)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this._onOutsideClick)}willUpdate(e){if(e.has("value")){const t=X(this.value);if(t)this._viewYear=t.getFullYear(),this._viewMonth=t.getMonth(),this._viewSeeded=!0;else if(!this._viewSeeded){const o=$e();this._viewYear=o.getFullYear(),this._viewMonth=o.getMonth()}}}updated(){var t;if(!this._pendingFocus)return;this._pendingFocus=!1;const e=(t=this.shadowRoot)==null?void 0:t.querySelector('.calendar__day-button[tabindex="0"]');e==null||e.focus()}get _min(){return X(this.minDate)}get _max(){return X(this.maxDate)}_isDisabled(e){const t=this._min,o=this._max;return!!(t&&e.getTime()<t.getTime()||o&&e.getTime()>o.getTime())}_clamp(e){const t=this._min,o=this._max;return t&&e.getTime()<t.getTime()?t:o&&e.getTime()>o.getTime()?o:e}_shiftMonth(e){const t=z1(new Date(this._viewYear,this._viewMonth,1),e);this._viewYear=t.getFullYear(),this._viewMonth=t.getMonth(),this._viewSeeded=!0}_moveFocus(e,t){const o=this._clamp(t);this._isDisabled(o)||(this._focus=ae(o),(o.getMonth()!==e.getMonth()||o.getFullYear()!==e.getFullYear())&&(this._viewYear=o.getFullYear(),this._viewMonth=o.getMonth(),this._viewSeeded=!0),this._pendingFocus=!0)}_onGridKeyDown(e){const t=X(this._focus)??this._defaultFocusDate();switch(e.key){case"ArrowLeft":this._moveFocus(t,e.shiftKey?z1(t,-1):et(t,-1));break;case"ArrowRight":this._moveFocus(t,e.shiftKey?z1(t,1):et(t,1));break;case"ArrowUp":this._moveFocus(t,e.shiftKey?z1(t,-12):et(t,-7));break;case"ArrowDown":this._moveFocus(t,e.shiftKey?z1(t,12):et(t,7));break;case"Home":this._moveFocus(t,et(t,-t.getDay()));break;case"End":this._moveFocus(t,et(t,6-t.getDay()));break;case"PageUp":this._moveFocus(t,z1(t,e.shiftKey?-12:-1));break;case"PageDown":this._moveFocus(t,z1(t,e.shiftKey?12:1));break;case"Enter":case" ":this._isDisabled(t)||this._pick(t);break;default:return}e.preventDefault()}_pick(e){const t=ae(e);this.value=t,this._focus=t,this.dispatchEvent(new CustomEvent(Lt,{detail:t,bubbles:!0,composed:!0}))}_emitHover(e){this.dispatchEvent(new CustomEvent(zo,{detail:e,bubbles:!0,composed:!0}))}_defaultFocusDate(){const e=X(this._focus);if(e&&e.getMonth()===this._viewMonth&&e.getFullYear()===this._viewYear)return e;const t=X(this.value);if(t&&t.getMonth()===this._viewMonth&&t.getFullYear()===this._viewYear)return t;const o=$e();return o.getMonth()===this._viewMonth&&o.getFullYear()===this._viewYear?o:this._clamp(new Date(this._viewYear,this._viewMonth,1))}get _yearOptions(){const e=this._min,t=this._max,o=e?e.getFullYear():this._viewYear-10,i=t?t.getFullYear():this._viewYear+10,s=Math.min(o,this._viewYear),r=Math.max(i,this._viewYear);return Array.from({length:r-s+1},(a,c)=>s+c)}_selectMonth(e){this._viewMonth=e,this._viewSeeded=!0,this._openSelect=null}_selectYear(e){this._viewYear=e,this._viewSeeded=!0,this._openSelect=null}_renderSelect(e,t,o,i,s){const r=this._openSelect===e;return d`
4386
+ `;let Po=gr;customElements.get("anduin-sidebar")||customElements.define("anduin-sidebar",Zo);customElements.get("anduin-sidebar-content")||customElements.define("anduin-sidebar-content",Ro);customElements.get("anduin-sidebar-header")||customElements.define("anduin-sidebar-header",Ci);customElements.get("anduin-sidebar-footer")||customElements.define("anduin-sidebar-footer",gi);customElements.get("anduin-sidebar-group")||customElements.define("anduin-sidebar-group",Ao);customElements.get("anduin-sidebar-group-label")||customElements.define("anduin-sidebar-group-label",So);customElements.get("anduin-sidebar-menu")||customElements.define("anduin-sidebar-menu",Oo);customElements.get("anduin-sidebar-menu-item")||customElements.define("anduin-sidebar-menu-item",q1);customElements.get("anduin-sidebar-action")||customElements.define("anduin-sidebar-action",To);customElements.get("anduin-sidebar-badge")||customElements.define("anduin-sidebar-badge",Do);customElements.get("anduin-sidebar-separator")||customElements.define("anduin-sidebar-separator",Po);function X(n){if(!n)return null;const e=/^(\d{4})-(\d{1,2})-(\d{1,2})$/.exec(n.trim());if(!e)return null;const[t,o,i]=[Number(e[1]),Number(e[2]),Number(e[3])],s=new Date(t,o-1,i);return s.getFullYear()!==t||s.getMonth()!==o-1||s.getDate()!==i?null:s}function ae(n){const e=t=>String(t).padStart(2,"0");return`${n.getFullYear()}-${e(n.getMonth()+1)}-${e(n.getDate())}`}function $e(){const n=new Date;return new Date(n.getFullYear(),n.getMonth(),n.getDate())}function z1(n,e){const t=n.getFullYear(),o=n.getMonth()+e,i=new Date(t,o+1,0).getDate();return new Date(t,o,Math.min(n.getDate(),i))}function Q7(n,e){return new Date(n,e+1,0).getDate()}var e9=Object.defineProperty,D1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&e9(e,t,i),i};const Lt="anduin-calendar:change",zo="anduin-calendar:day-hover",ca=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],ha=["January","February","March","April","May","June","July","August","September","October","November","December"],t9=["Su","Mo","Tu","We","Th","Fr","Sa"],ua=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function et(n,e){return new Date(n.getFullYear(),n.getMonth(),n.getDate()+e)}function i9(n){const e=["th","st","nd","rd"],t=n%100;return`${n}${e[(t-20)%10]??e[t]??e[0]}`}const fr=class fr extends C{constructor(){super(...arguments),this.value="",this.minDate="",this.maxDate="",this.rangeStart="",this.rangeEnd="",this.rangeMode=!1,this._viewMonth=$e().getMonth(),this._viewYear=$e().getFullYear(),this._focus="",this._openSelect=null,this._viewSeeded=!1,this._pendingFocus=!1,this._onOutsideClick=e=>{this._openSelect&&!e.composedPath().includes(this)&&(this._openSelect=null)}}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this._onOutsideClick)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this._onOutsideClick)}willUpdate(e){if(e.has("value")){const t=X(this.value);if(t)this._viewYear=t.getFullYear(),this._viewMonth=t.getMonth(),this._viewSeeded=!0;else if(!this._viewSeeded){const o=$e();this._viewYear=o.getFullYear(),this._viewMonth=o.getMonth()}}}updated(){var t;if(!this._pendingFocus)return;this._pendingFocus=!1;const e=(t=this.shadowRoot)==null?void 0:t.querySelector('.calendar__day-button[tabindex="0"]');e==null||e.focus()}get _min(){return X(this.minDate)}get _max(){return X(this.maxDate)}_isDisabled(e){const t=this._min,o=this._max;return!!(t&&e.getTime()<t.getTime()||o&&e.getTime()>o.getTime())}_clamp(e){const t=this._min,o=this._max;return t&&e.getTime()<t.getTime()?t:o&&e.getTime()>o.getTime()?o:e}_shiftMonth(e){const t=z1(new Date(this._viewYear,this._viewMonth,1),e);this._viewYear=t.getFullYear(),this._viewMonth=t.getMonth(),this._viewSeeded=!0}_moveFocus(e,t){const o=this._clamp(t);this._isDisabled(o)||(this._focus=ae(o),(o.getMonth()!==e.getMonth()||o.getFullYear()!==e.getFullYear())&&(this._viewYear=o.getFullYear(),this._viewMonth=o.getMonth(),this._viewSeeded=!0),this._pendingFocus=!0)}_onGridKeyDown(e){const t=X(this._focus)??this._defaultFocusDate();switch(e.key){case"ArrowLeft":this._moveFocus(t,e.shiftKey?z1(t,-1):et(t,-1));break;case"ArrowRight":this._moveFocus(t,e.shiftKey?z1(t,1):et(t,1));break;case"ArrowUp":this._moveFocus(t,e.shiftKey?z1(t,-12):et(t,-7));break;case"ArrowDown":this._moveFocus(t,e.shiftKey?z1(t,12):et(t,7));break;case"Home":this._moveFocus(t,et(t,-t.getDay()));break;case"End":this._moveFocus(t,et(t,6-t.getDay()));break;case"PageUp":this._moveFocus(t,z1(t,e.shiftKey?-12:-1));break;case"PageDown":this._moveFocus(t,z1(t,e.shiftKey?12:1));break;case"Enter":case" ":this._isDisabled(t)||this._pick(t);break;default:return}e.preventDefault()}_pick(e){const t=ae(e);this.value=t,this._focus=t,this.dispatchEvent(new CustomEvent(Lt,{detail:t,bubbles:!0,composed:!0}))}_emitHover(e){this.dispatchEvent(new CustomEvent(zo,{detail:e,bubbles:!0,composed:!0}))}_defaultFocusDate(){const e=X(this._focus);if(e&&e.getMonth()===this._viewMonth&&e.getFullYear()===this._viewYear)return e;const t=X(this.value);if(t&&t.getMonth()===this._viewMonth&&t.getFullYear()===this._viewYear)return t;const o=$e();return o.getMonth()===this._viewMonth&&o.getFullYear()===this._viewYear?o:this._clamp(new Date(this._viewYear,this._viewMonth,1))}get _yearOptions(){const e=this._min,t=this._max,o=e?e.getFullYear():this._viewYear-10,i=t?t.getFullYear():this._viewYear+10,s=Math.min(o,this._viewYear),r=Math.max(i,this._viewYear);return Array.from({length:r-s+1},(a,c)=>s+c)}_selectMonth(e){this._viewMonth=e,this._viewSeeded=!0,this._openSelect=null}_selectYear(e){this._viewYear=e,this._viewSeeded=!0,this._openSelect=null}_renderSelect(e,t,o,i,s){const r=this._openSelect===e;return d`
4387
4387
  <div class="calendar__select">
4388
4388
  <anduin-button
4389
4389
  appearance="text"
@@ -4406,9 +4406,9 @@
4406
4406
  >${a.label}</button>
4407
4407
  `)}
4408
4408
  </div>
4409
- `:g}
4409
+ `:f}
4410
4410
  </div>
4411
- `}render(){const e=ae($e()),t=X(this.value),o=X(this.rangeStart),i=X(this.rangeEnd),s=this.rangeMode||!!(o||i),r=ae(this._defaultFocusDate()),a=new Date(this._viewYear,this._viewMonth,1),c=new Date(this._viewYear,this._viewMonth+1,0).getDate(),u=a.getDay(),h=[...Array.from({length:u},()=>null),...Array.from({length:c},(x,y)=>y+1)];for(;h.length%7!==0;)h.push(null);const f=Array.from({length:h.length/7},(x,y)=>h.slice(y*7,y*7+7)),m=`${ha[this._viewMonth]} ${this._viewYear}`,v=(()=>{const x=this._min;return x?new Date(this._viewYear,this._viewMonth,0).getTime()<x.getTime():!1})(),_=(()=>{const x=this._max;return x?new Date(this._viewYear,this._viewMonth+1,1).getTime()>x.getTime():!1})();return d`
4411
+ `}render(){const e=ae($e()),t=X(this.value),o=X(this.rangeStart),i=X(this.rangeEnd),s=this.rangeMode||!!(o||i),r=ae(this._defaultFocusDate()),a=new Date(this._viewYear,this._viewMonth,1),c=new Date(this._viewYear,this._viewMonth+1,0).getDate(),u=a.getDay(),h=[...Array.from({length:u},()=>null),...Array.from({length:c},(x,y)=>y+1)];for(;h.length%7!==0;)h.push(null);const g=Array.from({length:h.length/7},(x,y)=>h.slice(y*7,y*7+7)),m=`${ha[this._viewMonth]} ${this._viewYear}`,v=(()=>{const x=this._min;return x?new Date(this._viewYear,this._viewMonth,0).getTime()<x.getTime():!1})(),_=(()=>{const x=this._max;return x?new Date(this._viewYear,this._viewMonth+1,1).getTime()>x.getTime():!1})();return d`
4412
4412
  <div class="calendar" part="calendar">
4413
4413
  <div class="calendar__header" part="header">
4414
4414
  <anduin-button
@@ -4450,9 +4450,9 @@
4450
4450
  </tr>
4451
4451
  </thead>
4452
4452
  <tbody>
4453
- ${f.map(x=>d`
4453
+ ${g.map(x=>d`
4454
4454
  <tr>
4455
- ${x.map(y=>{if(y===null)return d`<td class="calendar__day-cell"></td>`;const V=new Date(this._viewYear,this._viewMonth,y),k=ae(V),M=V.getTime(),$=this._isDisabled(V),N=!!o&&M===o.getTime(),R=!!i&&M===i.getTime(),u1=!!o&&!!i&&M>o.getTime()&&M<i.getTime(),ne=!s&&!!t&&M===t.getTime(),Ft=["calendar__day-cell",u1?"calendar__day-cell--in-range":"",N&&i?"calendar__day-cell--range-start":"",R&&o?"calendar__day-cell--range-end":""].filter(Boolean).join(" "),se=["calendar__day-button",k===e?"calendar__day-button--today":"",ne?"calendar__day-button--selected":"",N?"calendar__day-button--range-start":"",R?"calendar__day-button--range-end":"",u1?"calendar__day-button--in-range":"",$?"calendar__day-button--disabled":""].filter(Boolean).join(" ");return d`
4455
+ ${x.map(y=>{if(y===null)return d`<td class="calendar__day-cell"></td>`;const V=new Date(this._viewYear,this._viewMonth,y),L=ae(V),M=V.getTime(),$=this._isDisabled(V),N=!!o&&M===o.getTime(),R=!!i&&M===i.getTime(),u1=!!o&&!!i&&M>o.getTime()&&M<i.getTime(),ne=!s&&!!t&&M===t.getTime(),Ft=["calendar__day-cell",u1?"calendar__day-cell--in-range":"",N&&i?"calendar__day-cell--range-start":"",R&&o?"calendar__day-cell--range-end":""].filter(Boolean).join(" "),se=["calendar__day-button",L===e?"calendar__day-button--today":"",ne?"calendar__day-button--selected":"",N?"calendar__day-button--range-start":"",R?"calendar__day-button--range-end":"",u1?"calendar__day-button--in-range":"",$?"calendar__day-button--disabled":""].filter(Boolean).join(" ");return d`
4456
4456
  <td
4457
4457
  class="${Ft}"
4458
4458
  role="gridcell"
@@ -4464,9 +4464,9 @@
4464
4464
  part="day"
4465
4465
  aria-disabled="${$}"
4466
4466
  aria-label="${ua[V.getDay()]}, ${ha[V.getMonth()]} ${i9(y)}, ${V.getFullYear()}"
4467
- tabindex="${k===r?0:-1}"
4467
+ tabindex="${L===r?0:-1}"
4468
4468
  @click=${()=>{$||this._pick(V)}}
4469
- @mouseenter=${()=>{$||this._emitHover(k)}}
4469
+ @mouseenter=${()=>{$||this._emitHover(L)}}
4470
4470
  >${y}</button>
4471
4471
  </td>
4472
4472
  `})}
@@ -4475,7 +4475,7 @@
4475
4475
  </tbody>
4476
4476
  </table>
4477
4477
  </div>
4478
- `}};gr.styles=p`${B}
4478
+ `}};fr.styles=p`${B}
4479
4479
 
4480
4480
  :host { display: inline-block; font-family: var(--font-sans); }
4481
4481
 
@@ -4570,11 +4570,11 @@
4570
4570
  .calendar__day-button--range-end:hover { background-color: var(--color-primary-active); }
4571
4571
  .calendar__day-button--in-range { color: var(--color-primary-subtle-foreground); }
4572
4572
  .calendar__day-button--in-range:hover { background-color: var(--color-primary-subtle-active); }
4573
- `;let n1=gr;D1([l({reflect:!0})],n1.prototype,"value");D1([l({attribute:"min-date"})],n1.prototype,"minDate");D1([l({attribute:"max-date"})],n1.prototype,"maxDate");D1([l({attribute:"range-start"})],n1.prototype,"rangeStart");D1([l({attribute:"range-end"})],n1.prototype,"rangeEnd");D1([l({type:Boolean,attribute:"range-mode"})],n1.prototype,"rangeMode");D1([b()],n1.prototype,"_viewMonth");D1([b()],n1.prototype,"_viewYear");D1([b()],n1.prototype,"_focus");D1([b()],n1.prototype,"_openSelect");customElements.get("anduin-calendar")||customElements.define("anduin-calendar",n1);var o9=Object.defineProperty,zt=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&o9(e,t,i),i};const j4="anduin-date-range:change",vr=class vr extends C{constructor(){super(...arguments),this.startDate="",this.endDate="",this.minDate="",this.maxDate="",this._anchor=null,this._hover=null,this._panels=new Map,this._pushedValue=new Map,this._onCalendarChange=e=>{e.stopPropagation();const t=e.detail;if(!X(t))return;if(this._anchor===null){this._anchor=t,this._hover=null;return}const[o,i]=this._sorted(this._anchor,t);this._anchor=null,this._hover=null,this.startDate=o,this.endDate=i,this.dispatchEvent(new CustomEvent(j4,{detail:{startDate:o,endDate:i},bubbles:!0,composed:!0}))},this._onCalendarHover=e=>{e.stopPropagation(),this._anchor!==null&&(this._hover=e.detail)}}connectedCallback(){super.connectedCallback(),this.addEventListener(Lt,this._onCalendarChange),this.addEventListener(zo,this._onCalendarHover)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(Lt,this._onCalendarChange),this.removeEventListener(zo,this._onCalendarHover)}updated(){this._sync()}registerPanel(e,t){this._panels.set(e,t),this._pushedValue.delete(e),this._sync()}unregisterPanel(e){for(const[t,o]of this._panels)o===e&&(this._panels.delete(t),this._pushedValue.delete(t))}_sync(){const[e,t]=this._displayedRange();for(const[o,i]of this._panels){const s=i.calendar;if(!s)continue;s.minDate=this.minDate,s.maxDate=this.maxDate,s.rangeStart=e,s.rangeEnd=t;const r=this._panelValue(o);this._pushedValue.get(o)!==r&&(this._pushedValue.set(o,r),s.value=r)}}_panelValue(e){const t=X(this.startDate)??$e();return ae(e==="start"?t:z1(t,1))}_displayedRange(){if(this._anchor===null)return[this.startDate,this.endDate];if(this._hover===null)return[this._anchor,""];const[e,t]=this._sorted(this._anchor,this._hover);return[e,t]}_sorted(e,t){const o=X(e),i=X(t);return!o||!i?[e,t]:o.getTime()<=i.getTime()?[e,t]:[t,e]}render(){return d`<div class="date-range" part="date-range"><slot></slot></div>`}};vr.styles=p`
4573
+ `;let n1=fr;D1([l({reflect:!0})],n1.prototype,"value");D1([l({attribute:"min-date"})],n1.prototype,"minDate");D1([l({attribute:"max-date"})],n1.prototype,"maxDate");D1([l({attribute:"range-start"})],n1.prototype,"rangeStart");D1([l({attribute:"range-end"})],n1.prototype,"rangeEnd");D1([l({type:Boolean,attribute:"range-mode"})],n1.prototype,"rangeMode");D1([b()],n1.prototype,"_viewMonth");D1([b()],n1.prototype,"_viewYear");D1([b()],n1.prototype,"_focus");D1([b()],n1.prototype,"_openSelect");customElements.get("anduin-calendar")||customElements.define("anduin-calendar",n1);var o9=Object.defineProperty,zt=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&o9(e,t,i),i};const j4="anduin-date-range:change",vr=class vr extends C{constructor(){super(...arguments),this.startDate="",this.endDate="",this.minDate="",this.maxDate="",this._anchor=null,this._hover=null,this._panels=new Map,this._pushedValue=new Map,this._onCalendarChange=e=>{e.stopPropagation();const t=e.detail;if(!X(t))return;if(this._anchor===null){this._anchor=t,this._hover=null;return}const[o,i]=this._sorted(this._anchor,t);this._anchor=null,this._hover=null,this.startDate=o,this.endDate=i,this.dispatchEvent(new CustomEvent(j4,{detail:{startDate:o,endDate:i},bubbles:!0,composed:!0}))},this._onCalendarHover=e=>{e.stopPropagation(),this._anchor!==null&&(this._hover=e.detail)}}connectedCallback(){super.connectedCallback(),this.addEventListener(Lt,this._onCalendarChange),this.addEventListener(zo,this._onCalendarHover)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(Lt,this._onCalendarChange),this.removeEventListener(zo,this._onCalendarHover)}updated(){this._sync()}registerPanel(e,t){this._panels.set(e,t),this._pushedValue.delete(e),this._sync()}unregisterPanel(e){for(const[t,o]of this._panels)o===e&&(this._panels.delete(t),this._pushedValue.delete(t))}_sync(){const[e,t]=this._displayedRange();for(const[o,i]of this._panels){const s=i.calendar;if(!s)continue;s.minDate=this.minDate,s.maxDate=this.maxDate,s.rangeStart=e,s.rangeEnd=t;const r=this._panelValue(o);this._pushedValue.get(o)!==r&&(this._pushedValue.set(o,r),s.value=r)}}_panelValue(e){const t=X(this.startDate)??$e();return ae(e==="start"?t:z1(t,1))}_displayedRange(){if(this._anchor===null)return[this.startDate,this.endDate];if(this._hover===null)return[this._anchor,""];const[e,t]=this._sorted(this._anchor,this._hover);return[e,t]}_sorted(e,t){const o=X(e),i=X(t);return!o||!i?[e,t]:o.getTime()<=i.getTime()?[e,t]:[t,e]}render(){return d`<div class="date-range" part="date-range"><slot></slot></div>`}};vr.styles=p`
4574
4574
  :host { display: inline-block; font-family: var(--font-sans); }
4575
4575
  `;let H1=vr;zt([l({attribute:"start-date",reflect:!0})],H1.prototype,"startDate");zt([l({attribute:"end-date",reflect:!0})],H1.prototype,"endDate");zt([l({attribute:"min-date"})],H1.prototype,"minDate");zt([l({attribute:"max-date"})],H1.prototype,"maxDate");zt([b()],H1.prototype,"_anchor");zt([b()],H1.prototype,"_hover");const mr=class mr extends C{constructor(){super(...arguments),this._host=null}get calendar(){var e;return((e=this.shadowRoot)==null?void 0:e.querySelector("anduin-calendar"))??null}firstUpdated(){var e;this._host=this._findRangeHost(),(e=this._host)==null||e.registerPanel(this.panelRole,this)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._host)==null||e.unregisterPanel(this),this._host=null}_findRangeHost(){let e=this;for(;e;){if(e instanceof H1)return e;e=e instanceof ShadowRoot?e.host:e.parentNode}return null}render(){return d`<anduin-calendar part="calendar" range-mode></anduin-calendar>`}};mr.styles=p`
4576
4576
  :host { display: inline-block; font-family: var(--font-sans); }
4577
- `;let gi=mr;class W4 extends gi{constructor(){super(...arguments),this.panelRole="start"}}class Y4 extends gi{constructor(){super(...arguments),this.panelRole="end"}}const br=class br extends C{render(){return d`
4577
+ `;let fi=mr;class W4 extends fi{constructor(){super(...arguments),this.panelRole="start"}}class Y4 extends fi{constructor(){super(...arguments),this.panelRole="end"}}const br=class br extends C{render(){return d`
4578
4578
  <div class="date-range-default" part="layout">
4579
4579
  <anduin-date-range-start part="start"></anduin-date-range-start>
4580
4580
  <anduin-date-range-end part="end"></anduin-date-range-end>
@@ -4583,11 +4583,11 @@
4583
4583
  :host { display: inline-block; font-family: var(--font-sans); }
4584
4584
 
4585
4585
  .date-range-default { display: flex; flex-direction: row; gap: 16px; }
4586
- `;let Io=br;customElements.get("anduin-date-range")||customElements.define("anduin-date-range",H1);customElements.get("anduin-date-range-default")||customElements.define("anduin-date-range-default",Io);customElements.get("anduin-date-range-start")||customElements.define("anduin-date-range-start",W4);customElements.get("anduin-date-range-end")||customElements.define("anduin-date-range-end",Y4);var n9=Object.defineProperty,d1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&n9(e,t,i),i};const Fo="anduin-date-input:change",pa={M:"month",d:"day",y:"year"};function s9(n){const e=[];let t=0,o=0;for(;o<n.length;){const i=n[o],s=pa[i];if(!s){let a="";for(;o<n.length&&!pa[n[o]];)a+=n[o++];e.push({literal:a}),t+=a.length;continue}let r="";for(;o<n.length&&n[o]===i;)r+=n[o++];e.push({segment:{type:s,placeholder:r,length:r.length,start:t}}),t+=r.length}return e}function L2(n){return n.type==="year"?10**n.length-1:n.length===1?9:n.type==="month"?12:31}const Gt=1,Nn=class Nn extends C{constructor(){super(...arguments),this.format="MM/dd/yyyy",this.value="",this.size="default",this.disabled=!1,this.readonly=!1,this.status="",this.startIcon="",this.minDate="",this.maxDate="",this.inputid="",this._digits=[],this._active=0,this._buffer="",this._pendingSelection=null,this._tokens=[],this._segments=[],this._onFieldLabelClick=e=>{const t=e.detail;this.inputid&&this.inputid===t&&this._focusSegment(0)}}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-field");e==null||e.addEventListener(F1,this._onFieldLabelClick)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.closest("anduin-field"))==null||e.removeEventListener(F1,this._onFieldLabelClick)}willUpdate(e){e.has("format")?(this._tokens=s9(this.format),this._segments=this._tokens.flatMap(t=>"segment"in t?[t.segment]:[]),this._digits=this._segments.map(()=>null),this._active=0,this._buffer="",this.value&&this._adoptValue(this.value)):e.has("value")&&this.value!==this._composeValue()&&this._adoptValue(this.value)}updated(){const e=this._display();if(this._inputEl&&this._inputEl.value!==e&&(this._inputEl.value=e),this._pendingSelection&&this._inputEl){const[t,o]=this._pendingSelection;this._pendingSelection=null,this._inputEl.setSelectionRange(t,o)}}_adoptValue(e){const t=this._segments.map(o=>{const i=e.slice(o.start,o.start+o.length);return/^\d+$/.test(i)?i:null});this._digits=t,this._buffer=""}_display(){return this._tokens.map(e=>{if("literal"in e)return e.literal;const t=e.segment,o=this._segments.indexOf(t);return o===this._active&&this._buffer?this._buffer.padStart(t.length,"0"):this._digits[o]??t.placeholder}).join("")}_composeValue(){return!this._segments.length||this._digits.some(e=>e===null)?"":this._tokens.map(e=>"literal"in e?e.literal:this._digits[this._segments.indexOf(e.segment)]).join("")}_setDigits(e){if(this._digits=e,!this._composeValue()){this.value="";return}const o=this._clampToBounds(e);this._digits=o,this.value=this._composeValue(),this.dispatchEvent(new CustomEvent(Fo,{detail:this.value,bubbles:!0,composed:!0}))}_indexOfType(e){return this._segments.findIndex(t=>t.type===e)}_clampToBounds(e){const t=X(this.minDate),o=X(this.maxDate);if(!t&&!o)return e;const i=this._indexOfType("month"),s=this._indexOfType("day"),r=this._indexOfType("year");if(i<0||s<0||r<0)return e;const a=Number(e[r]),c=Number(e[i]),u=Number(e[s]),h=Math.min(u,Q7(a,c-1)),f=new Date(a,c-1,h),m=t&&f.getTime()<t.getTime()?t:o&&f.getTime()>o.getTime()?o:null;if(!m){if(h===u)return e;const _=[...e];return _[s]=String(h).padStart(this._segments[s].length,"0"),_}const v=[...e];return v[r]=String(m.getFullYear()).padStart(this._segments[r].length,"0").slice(-this._segments[r].length),v[i]=String(m.getMonth()+1).padStart(this._segments[i].length,"0"),v[s]=String(m.getDate()).padStart(this._segments[s].length,"0"),v}_focusSegment(e){var o,i;const t=this._segments[e];t&&(this._flushBuffer(),this._active=e,this._buffer="",this._pendingSelection=[t.start,t.start+t.length],(o=this._inputEl)==null||o.focus(),(i=this._inputEl)==null||i.setSelectionRange(t.start,t.start+t.length))}_segmentAt(e){for(let t=0;t<this._segments.length;t++){const o=this._segments[t];if(e>=o.start&&e<=o.start+o.length)return t}return this._segments.length-1}_onSelectionIntent(){if(this.disabled||this.readonly||!this._inputEl)return;const e=this._inputEl.selectionStart??0;this._focusSegment(this._segmentAt(e))}_writeSegment(e,t){const o=this._segments[e];if(!o)return;const i=Math.min(Math.max(Number(t),Gt),L2(o)),s=[...this._digits];s[e]=String(i).padStart(o.length,"0"),this._buffer="",this._setDigits(s)}_flushBuffer(){this._buffer&&this._writeSegment(this._active,this._buffer)}_commitBuffer(e,t,o){this._writeSegment(e,t),o&&e<this._segments.length-1?this._focusSegment(e+1):this._focusSegment(e)}_typeDigit(e){const t=this._active,o=this._segments[t];if(!o)return;const i=this._buffer+e;if(o.length-i.length<=0){this._commitBuffer(t,i,!0);return}const r=Number(i.padEnd(o.length,"0")),a=Number(i.padEnd(o.length,"9"));if(r>L2(o)||a<Gt){this._commitBuffer(t,i,!0);return}this._buffer=i,this._pendingSelection=[o.start,o.start+o.length]}_step(e){const t=this._active,o=this._segments[t];if(!o)return;const i=L2(o),s=this._digits[t];let r;s===null?r=e>0?Gt:i:(r=Number(s)+e,r>i&&(r=Gt),r<Gt&&(r=i));const a=[...this._digits];a[t]=String(r).padStart(o.length,"0"),this._buffer="",this._setDigits(a),this._pendingSelection=[o.start,o.start+o.length]}_clearSegment(){const e=this._active,t=this._segments[e];if(!t)return;const o=[...this._digits];o[e]=null,this._buffer="",this._setDigits(o),this._pendingSelection=[t.start,t.start+t.length]}_onKeyDown(e){if(this.disabled||this.readonly)return;const t=this._segments.length-1;if(/^\d$/.test(e.key)&&!e.metaKey&&!e.ctrlKey&&!e.altKey){e.preventDefault(),this._typeDigit(e.key);return}switch(e.key){case"ArrowRight":this._active<t&&(e.preventDefault(),this._focusSegment(this._active+1));return;case"ArrowLeft":this._active>0&&(e.preventDefault(),this._focusSegment(this._active-1));return;case"ArrowUp":e.preventDefault(),this._step(1);return;case"ArrowDown":e.preventDefault(),this._step(-1);return;case"Backspace":case"Delete":e.preventDefault(),this._clearSegment();return;case"Tab":e.shiftKey&&this._active>0?(e.preventDefault(),this._focusSegment(this._active-1)):!e.shiftKey&&this._active<t&&(e.preventDefault(),this._focusSegment(this._active+1));return}}render(){const e=!!this.startIcon,t=["date-input-container",e?"date-input-container--has-icon":""].filter(Boolean).join(" "),o=["date-input",`date-input--${this.size}`,this.disabled?"date-input--disabled":"",this.readonly?"date-input--readonly":"",this.status?`date-input--${this.status}`:""].filter(Boolean).join(" "),i=this.size==="small"?"12":"16";return d`
4586
+ `;let Io=br;customElements.get("anduin-date-range")||customElements.define("anduin-date-range",H1);customElements.get("anduin-date-range-default")||customElements.define("anduin-date-range-default",Io);customElements.get("anduin-date-range-start")||customElements.define("anduin-date-range-start",W4);customElements.get("anduin-date-range-end")||customElements.define("anduin-date-range-end",Y4);var n9=Object.defineProperty,d1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&n9(e,t,i),i};const Fo="anduin-date-input:change",pa={M:"month",d:"day",y:"year"};function s9(n){const e=[];let t=0,o=0;for(;o<n.length;){const i=n[o],s=pa[i];if(!s){let a="";for(;o<n.length&&!pa[n[o]];)a+=n[o++];e.push({literal:a}),t+=a.length;continue}let r="";for(;o<n.length&&n[o]===i;)r+=n[o++];e.push({segment:{type:s,placeholder:r,length:r.length,start:t}}),t+=r.length}return e}function L2(n){return n.type==="year"?10**n.length-1:n.length===1?9:n.type==="month"?12:31}const Gt=1,Nn=class Nn extends C{constructor(){super(...arguments),this.format="MM/dd/yyyy",this.value="",this.size="default",this.disabled=!1,this.readonly=!1,this.status="",this.startIcon="",this.minDate="",this.maxDate="",this.inputid="",this._digits=[],this._active=0,this._buffer="",this._pendingSelection=null,this._tokens=[],this._segments=[],this._onFieldLabelClick=e=>{const t=e.detail;this.inputid&&this.inputid===t&&this._focusSegment(0)}}connectedCallback(){super.connectedCallback();const e=this.closest("anduin-field");e==null||e.addEventListener(F1,this._onFieldLabelClick)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.closest("anduin-field"))==null||e.removeEventListener(F1,this._onFieldLabelClick)}willUpdate(e){e.has("format")?(this._tokens=s9(this.format),this._segments=this._tokens.flatMap(t=>"segment"in t?[t.segment]:[]),this._digits=this._segments.map(()=>null),this._active=0,this._buffer="",this.value&&this._adoptValue(this.value)):e.has("value")&&this.value!==this._composeValue()&&this._adoptValue(this.value)}updated(){const e=this._display();if(this._inputEl&&this._inputEl.value!==e&&(this._inputEl.value=e),this._pendingSelection&&this._inputEl){const[t,o]=this._pendingSelection;this._pendingSelection=null,this._inputEl.setSelectionRange(t,o)}}_adoptValue(e){const t=this._segments.map(o=>{const i=e.slice(o.start,o.start+o.length);return/^\d+$/.test(i)?i:null});this._digits=t,this._buffer=""}_display(){return this._tokens.map(e=>{if("literal"in e)return e.literal;const t=e.segment,o=this._segments.indexOf(t);return o===this._active&&this._buffer?this._buffer.padStart(t.length,"0"):this._digits[o]??t.placeholder}).join("")}_composeValue(){return!this._segments.length||this._digits.some(e=>e===null)?"":this._tokens.map(e=>"literal"in e?e.literal:this._digits[this._segments.indexOf(e.segment)]).join("")}_setDigits(e){if(this._digits=e,!this._composeValue()){this.value="";return}const o=this._clampToBounds(e);this._digits=o,this.value=this._composeValue(),this.dispatchEvent(new CustomEvent(Fo,{detail:this.value,bubbles:!0,composed:!0}))}_indexOfType(e){return this._segments.findIndex(t=>t.type===e)}_clampToBounds(e){const t=X(this.minDate),o=X(this.maxDate);if(!t&&!o)return e;const i=this._indexOfType("month"),s=this._indexOfType("day"),r=this._indexOfType("year");if(i<0||s<0||r<0)return e;const a=Number(e[r]),c=Number(e[i]),u=Number(e[s]),h=Math.min(u,Q7(a,c-1)),g=new Date(a,c-1,h),m=t&&g.getTime()<t.getTime()?t:o&&g.getTime()>o.getTime()?o:null;if(!m){if(h===u)return e;const _=[...e];return _[s]=String(h).padStart(this._segments[s].length,"0"),_}const v=[...e];return v[r]=String(m.getFullYear()).padStart(this._segments[r].length,"0").slice(-this._segments[r].length),v[i]=String(m.getMonth()+1).padStart(this._segments[i].length,"0"),v[s]=String(m.getDate()).padStart(this._segments[s].length,"0"),v}_focusSegment(e){var o,i;const t=this._segments[e];t&&(this._flushBuffer(),this._active=e,this._buffer="",this._pendingSelection=[t.start,t.start+t.length],(o=this._inputEl)==null||o.focus(),(i=this._inputEl)==null||i.setSelectionRange(t.start,t.start+t.length))}_segmentAt(e){for(let t=0;t<this._segments.length;t++){const o=this._segments[t];if(e>=o.start&&e<=o.start+o.length)return t}return this._segments.length-1}_onSelectionIntent(){if(this.disabled||this.readonly||!this._inputEl)return;const e=this._inputEl.selectionStart??0;this._focusSegment(this._segmentAt(e))}_writeSegment(e,t){const o=this._segments[e];if(!o)return;const i=Math.min(Math.max(Number(t),Gt),L2(o)),s=[...this._digits];s[e]=String(i).padStart(o.length,"0"),this._buffer="",this._setDigits(s)}_flushBuffer(){this._buffer&&this._writeSegment(this._active,this._buffer)}_commitBuffer(e,t,o){this._writeSegment(e,t),o&&e<this._segments.length-1?this._focusSegment(e+1):this._focusSegment(e)}_typeDigit(e){const t=this._active,o=this._segments[t];if(!o)return;const i=this._buffer+e;if(o.length-i.length<=0){this._commitBuffer(t,i,!0);return}const r=Number(i.padEnd(o.length,"0")),a=Number(i.padEnd(o.length,"9"));if(r>L2(o)||a<Gt){this._commitBuffer(t,i,!0);return}this._buffer=i,this._pendingSelection=[o.start,o.start+o.length]}_step(e){const t=this._active,o=this._segments[t];if(!o)return;const i=L2(o),s=this._digits[t];let r;s===null?r=e>0?Gt:i:(r=Number(s)+e,r>i&&(r=Gt),r<Gt&&(r=i));const a=[...this._digits];a[t]=String(r).padStart(o.length,"0"),this._buffer="",this._setDigits(a),this._pendingSelection=[o.start,o.start+o.length]}_clearSegment(){const e=this._active,t=this._segments[e];if(!t)return;const o=[...this._digits];o[e]=null,this._buffer="",this._setDigits(o),this._pendingSelection=[t.start,t.start+t.length]}_onKeyDown(e){if(this.disabled||this.readonly)return;const t=this._segments.length-1;if(/^\d$/.test(e.key)&&!e.metaKey&&!e.ctrlKey&&!e.altKey){e.preventDefault(),this._typeDigit(e.key);return}switch(e.key){case"ArrowRight":this._active<t&&(e.preventDefault(),this._focusSegment(this._active+1));return;case"ArrowLeft":this._active>0&&(e.preventDefault(),this._focusSegment(this._active-1));return;case"ArrowUp":e.preventDefault(),this._step(1);return;case"ArrowDown":e.preventDefault(),this._step(-1);return;case"Backspace":case"Delete":e.preventDefault(),this._clearSegment();return;case"Tab":e.shiftKey&&this._active>0?(e.preventDefault(),this._focusSegment(this._active-1)):!e.shiftKey&&this._active<t&&(e.preventDefault(),this._focusSegment(this._active+1));return}}render(){const e=!!this.startIcon,t=["date-input-container",e?"date-input-container--has-icon":""].filter(Boolean).join(" "),o=["date-input",`date-input--${this.size}`,this.disabled?"date-input--disabled":"",this.readonly?"date-input--readonly":"",this.status?`date-input--${this.status}`:""].filter(Boolean).join(" "),i=this.size==="small"?"12":"16";return d`
4587
4587
  <div class="${t}" part="container">
4588
4588
  ${e?d`<span class="date-input__icon" part="icon">
4589
4589
  <anduin-icon name="${this.startIcon}" size="${i}"></anduin-icon>
4590
- </span>`:g}
4590
+ </span>`:f}
4591
4591
  <input
4592
4592
  class="${o}"
4593
4593
  part="input"
@@ -4599,7 +4599,7 @@
4599
4599
  .value=${this._display()}
4600
4600
  ?disabled=${this.disabled}
4601
4601
  ?readonly=${this.readonly}
4602
- aria-invalid=${this.status==="invalid"?"true":g}
4602
+ aria-invalid=${this.status==="invalid"?"true":f}
4603
4603
  @keydown=${this._onKeyDown}
4604
4604
  @mouseup=${this._onSelectionIntent}
4605
4605
  @focus=${this._onSelectionIntent}
@@ -4684,7 +4684,7 @@
4684
4684
  min-date=${this.minDate}
4685
4685
  max-date=${this.maxDate}
4686
4686
  .value=${this._isoValue}
4687
- ></anduin-calendar>`:g}
4687
+ ></anduin-calendar>`:f}
4688
4688
  <slot name="actions"></slot>
4689
4689
  </div>
4690
4690
  </anduin-popover>
@@ -4698,7 +4698,7 @@
4698
4698
 
4699
4699
  /* The popover contributes 8px; the calendar reads better with 16px total. */
4700
4700
  .datepicker__panel { padding: 8px; display: flex; flex-direction: column; }
4701
- `;let K=_r;c1([l()],K.prototype,"format");c1([l()],K.prototype,"value");c1([l()],K.prototype,"size");c1([l({type:Boolean})],K.prototype,"disabled");c1([l({type:Boolean})],K.prototype,"readonly");c1([l()],K.prototype,"status");c1([l({attribute:"start-icon"})],K.prototype,"startIcon");c1([l({attribute:"min-date"})],K.prototype,"minDate");c1([l({attribute:"max-date"})],K.prototype,"maxDate");c1([l()],K.prototype,"placement");c1([l()],K.prototype,"inputid");c1([b()],K.prototype,"_open");c1([E("anduin-date-input")],K.prototype,"_inputEl");c1([E("anduin-popover")],K.prototype,"_popoverEl");customElements.get("anduin-date-picker")||customElements.define("anduin-date-picker",K);var d9=Object.defineProperty,L=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&d9(e,t,i),i};const Q4="anduin-table:sort",e3="anduin-table:column-click",t3="anduin-table:row-click",i3="anduin-table:selection-change",o3="anduin-table:cell-context-menu",n3="anduin-table:row-expand",s3="anduin-table:row-collapse",r3="anduin-table:group-toggle",B2="anduin-table:column-resize",Ca=40,P1=n=>n.type==="selection",re=(n,e)=>{if(!e)return;let t=n;for(const o of e.split(".")){if(t===null||typeof t!="object")return;t=t[o]}return t},c9=(n,e)=>n===e?0:n==null?1:e==null?-1:typeof n=="number"&&typeof e=="number"?n-e:typeof n=="boolean"&&typeof e=="boolean"?Number(n)-Number(e):n instanceof Date&&e instanceof Date?n.getTime()-e.getTime():String(n).localeCompare(String(e),void 0,{numeric:!0,sensitivity:"base"}),yr=class yr extends C{constructor(){super(...arguments),this.columns=[],this.data=[],this.layout="fit-data",this.renderMode="basic",this.rowHeight=40,this.height="",this.maxHeight="",this.minHeight="",this.resizableColumns=!0,this.hideHeader=!1,this.loading=!1,this.selectable="clickable",this.indexColumn="id",this.columnAlign="left",this.columnVerticalAlign="middle",this.sortField="",this.sortDirection="asc",this.dataTree=!1,this.treeChildrenField="children",this.treeChildIndent=20,this.groupBy="",this.selectedRows=[],this.expandedKeys=new Set,this.collapsedGroups=new Set,this.virtualScrollTop=0,this.viewportHeight=0,this.scrolledX=!1,this.scrollableXEnd=!1,this.resizedWidths={},this.resizingKey="",this.rangeAnchorKey=null,this.isDraggingRange=!1,this.dragBaseKeys=[],this.dragSelects=!0,this.autoExpandedKeys=new Set,this.resizeDrag=null,this.resizeFrame=0,this.renderSelectedKeys=new Set,this.renderSelectableRows=[],this.cachedRenderRows=[],this.rowsDirty=!0,this.onWindowMouseUp=()=>{this.isDraggingRange=!1},this.onScroll=e=>{const t=e.currentTarget;this.renderMode==="virtual"&&(this.virtualScrollTop=t.scrollTop),this.syncHorizontalScrollState()},this.onResizeMove=e=>{const t=this.resizeDrag;if(!t)return;const o=48;t.width=Math.max(o,t.startWidth+(e.clientX-t.startX)),!this.resizeFrame&&(this.resizeFrame=requestAnimationFrame(()=>{this.resizeFrame=0,this.resizeDrag&&(this.resizedWidths={...this.resizedWidths,[t.key]:t.width})}))},this.onResizeEnd=e=>{const t=this.resizeDrag;t&&(this.resizeFrame&&(cancelAnimationFrame(this.resizeFrame),this.resizeFrame=0),this.resizedWidths={...this.resizedWidths,[t.key]:t.width},this.resizeDrag=null,this.resizingKey="",this.dispatchEvent(new CustomEvent(B2,{detail:{column:e,field:t.key,width:t.width},bubbles:!0,composed:!0})))}}connectedCallback(){super.connectedCallback(),window.addEventListener("mouseup",this.onWindowMouseUp)}disconnectedCallback(){var e;super.disconnectedCallback(),window.removeEventListener("mouseup",this.onWindowMouseUp),(e=this.resizeObserver)==null||e.disconnect(),this.resizeObserver=void 0}firstUpdated(){const e=this.scrollEl;e&&(this.resizeObserver=new ResizeObserver(()=>{this.viewportHeight=e.clientHeight,this.syncHorizontalScrollState()}),this.resizeObserver.observe(e),this.viewportHeight=e.clientHeight)}willUpdate(e){["data","columns","sortField","sortDirection","groupBy","dataTree","treeChildrenField","indexColumn","onStartExpanded","isRowDisabled","selectedRows","expandedKeys","collapsedGroups"].some(o=>e.has(o))&&(this.rowsDirty=!0),this.rowsDirty&&(this.cachedRenderRows=this.buildRenderRows(),this.renderSelectedKeys=this.selectedKeySet,this.renderSelectableRows=this.cachedRenderRows.filter(o=>o.kind==="row"&&!this.rowIsDisabled(o.data)),this.rowsDirty=!1)}updated(e){this.applyFrozenOffsets(),(e.has("data")||e.has("columns"))&&this.syncHorizontalScrollState()}get scrollEl(){return this.renderRoot.querySelector(".table__scroll")}keyFor(e,t){const o=re(e,this.indexColumn);return o==null?`__index:${t}`:String(o)}get selectedKeySet(){const e=new Set;return this.selectedRows.forEach((t,o)=>e.add(this.keyFor(t,o))),e}rowIsDisabled(e){return this.isRowDisabled?this.isRowDisabled(e):!1}get frozenSides(){const e=this.columns,t=e.map(()=>null);for(let o=0;o<e.length;o++){const i=e[o].isFrozen;if(!i)break;t[o]=i==="right"?"right":"left"}for(let o=e.length-1;o>=0;o--){const i=e[o].isFrozen;if(!i)break;t[o]===null&&(t[o]=i==="left"?"left":"right")}for(let o=0;o<e.length;o++){const i=e[o].isFrozen;(i==="left"||i==="right")&&(t[o]=i)}return t}applyFrozenOffsets(){const e=this.frozenSides;if(!e.some(Boolean))return;const t=Array.from(this.renderRoot.querySelectorAll("thead th[data-col]"));if(t.length===0)return;const o=t.map(c=>c.getBoundingClientRect().width),i=e.map(()=>null);let s=0;for(let c=0;c<e.length;c++)e[c]==="left"&&(i[c]=s,s+=o[c]??0);let r=0;for(let c=e.length-1;c>=0;c--)e[c]==="right"&&(i[c]=r,r+=o[c]??0);this.renderRoot.querySelectorAll("[data-col]").forEach(c=>{const u=Number(c.dataset.col),h=e[u],f=i[u];!h||f===null||(c.style[h]=`${f}px`)})}get sortedColumn(){if(this.sortField)return this.columns.find(e=>!P1(e)&&e.field===this.sortField)}sortRows(e){const t=this.sortedColumn;if(!t)return e;const o=this.sortDirection==="desc"?-1:1,i=t.sortWith?(s,r)=>t.sortWith({a:s,b:r}):(s,r)=>c9(re(s,t.field),re(r,t.field));return[...e].sort((s,r)=>i(s,r)*o)}onHeaderClick(e){if(this.dispatchEvent(new CustomEvent(e3,{detail:{column:e},bubbles:!0,composed:!0})),!e.isSortable)return;let t=e.field,o="asc";this.sortField===e.field&&(this.sortDirection==="asc"?o="desc":(t="",o=null)),this.sortField=t,o&&(this.sortDirection=o),this.dispatchEvent(new CustomEvent(Q4,{detail:{field:t,direction:o,column:e},bubbles:!0,composed:!0}))}buildRenderRows(){return this.groupBy?this.buildGroupedRows():this.buildFlatRows(this.sortRows(this.data),0)}buildFlatRows(e,t){const o=[];return e.forEach((i,s)=>{const r=this.keyFor(i,s),a=this.dataTree?re(i,this.treeChildrenField):void 0,c=Array.isArray(a)&&a.length>0,u=c&&this.isExpanded(r,i);o.push({kind:"row",data:i,key:r,depth:t,hasChildren:c,expanded:u}),u&&o.push(...this.buildFlatRows(this.sortRows(a),t+1))}),o}buildGroupedRows(){const e=new Map;this.data.forEach(o=>{const i=re(o,this.groupBy),s=String(i),r=e.get(s);r?r.rows.push(o):e.set(s,{value:i,rows:[o]})});const t=[];return e.forEach(({value:o,rows:i},s)=>{const r=!this.collapsedGroups.has(s);t.push({kind:"group",key:s,value:o,rows:i,expanded:r}),r&&t.push(...this.buildFlatRows(this.sortRows(i),0))}),t}isExpanded(e,t){return this.expandedKeys.has(e)?!0:this.onStartExpanded&&!this.autoExpandedKeys.has(e)&&(this.autoExpandedKeys.add(e),this.onStartExpanded(t))?(this.expandedKeys.add(e),!0):!1}toggleTreeRow(e){const t=!e.expanded,o=new Set(this.expandedKeys);t?o.add(e.key):o.delete(e.key),this.expandedKeys=o,this.dispatchEvent(new CustomEvent(t?n3:s3,{detail:{data:e.data,key:e.key,expanded:t},bubbles:!0,composed:!0}))}toggleGroup(e){const t=!e.expanded,o=new Set(this.collapsedGroups);t?o.delete(e.key):o.add(e.key),this.collapsedGroups=o,this.dispatchEvent(new CustomEvent(r3,{detail:{value:e.value,rows:e.rows,expanded:t},bubbles:!0,composed:!0}))}expandAll(){const e=new Set,t=o=>{o.forEach((i,s)=>{const r=re(i,this.treeChildrenField);Array.isArray(r)&&r.length>0&&(e.add(this.keyFor(i,s)),t(r))})};t(this.data),this.expandedKeys=e}collapseAll(){this.expandedKeys=new Set}get selectableRows(){return this.buildRenderRows().filter(e=>e.kind==="row"&&!this.rowIsDisabled(e.data))}commitSelection(e){const t=new Map,o=s=>{s.forEach((r,a)=>{t.set(this.keyFor(r,a),r);const c=this.dataTree?re(r,this.treeChildrenField):void 0;Array.isArray(c)&&o(c)})};o(this.data);const i=[...e].filter(s=>t.has(s));this.selectedRows=i.map(s=>t.get(s)),this.dispatchEvent(new CustomEvent(i3,{detail:{selectedRows:this.selectedRows,selectedKeys:i},bubbles:!0,composed:!0}))}setRowSelected(e,t){if(this.rowIsDisabled(e.data))return;const o=this.selectedKeySet;t?o.add(e.key):o.delete(e.key),this.rangeAnchorKey=e.key,this.commitSelection(o)}toggleAllRows(e){const t=this.selectedKeySet;this.selectableRows.forEach(o=>{e?t.add(o.key):t.delete(o.key)}),this.commitSelection(t)}selectRange(e,t,o){const i=this.selectableRows,s=i.findIndex(f=>f.key===e.key);if(s<0)return;const r=this.rangeAnchorKey?i.findIndex(f=>f.key===this.rangeAnchorKey):-1,a=r<0?s:r,[c,u]=a<=s?[a,s]:[s,a],h=new Set(o);for(let f=c;f<=u;f++)t?h.add(i[f].key):h.delete(i[f].key);this.commitSelection(h)}onRowMouseDown(e,t){this.selectable!=="selectable-by-dragging"||!e.shiftKey||this.rowIsDisabled(t.data)||(e.preventDefault(),this.isDraggingRange=!0,this.dragBaseKeys=[...this.selectedKeySet],this.dragSelects=!this.selectedKeySet.has(t.key),this.rangeAnchorKey=t.key,this.selectRange(t,this.dragSelects,this.dragBaseKeys))}onRowMouseEnter(e){this.isDraggingRange&&this.selectRange(e,this.dragSelects,this.dragBaseKeys)}onRowClick(e,t,o){this.dispatchEvent(new CustomEvent(t3,{detail:{data:t.data,key:t.key,index:o,originalEvent:e},bubbles:!0,composed:!0}));const i=this.selectable;if(i==="unselectable"||i==="clickable"||this.rowIsDisabled(t.data))return;const s=this.selectedKeySet.has(t.key);if(i==="selectable-by-clicking"&&e.shiftKey){this.selectRange(t,!0,e.metaKey||e.ctrlKey?[...this.selectedKeySet]:[]);return}if(i==="selectable-by-clicking"&&!(e.metaKey||e.ctrlKey)){this.rangeAnchorKey=t.key,this.commitSelection(new Set(s&&this.selectedRows.length===1?[]:[t.key]));return}this.setRowSelected(t,!s)}onCellContextMenu(e,t,o,i){this.dispatchEvent(new CustomEvent(o3,{detail:{data:t.data,key:t.key,index:o,column:i,x:e.clientX,y:e.clientY,originalEvent:e},bubbles:!0,composed:!0,cancelable:!0}))}syncHorizontalScrollState(){const e=this.scrollEl;e&&(this.scrolledX=e.scrollLeft>0,this.scrollableXEnd=Math.ceil(e.scrollLeft+e.clientWidth)<e.scrollWidth)}columnKey(e,t){return P1(e)?`__selection:${t}`:e.field||`__col:${t}`}widthFor(e,t){return this.resizedWidths[this.columnKey(e,t)]??e.width}isStretchColumn(e,t){return this.layout!=="fit-data-stretch"||t!==this.columns.length-1?!1:this.resizedWidths[this.columnKey(e,t)]===void 0}sizingClass(e,t){return this.isStretchColumn(e,t)?"table__cell--stretch":this.widthFor(e,t)?"table__cell--sized":""}cellStyle(e,t){if(this.isStretchColumn(e,t))return"width:100%";const o=this.widthFor(e,t),i=[];return o&&(i.push(`width:${o}px`),this.layout!=="fit-columns"&&i.push(`max-width:${o}px`)),e.minWidth?i.push(`min-width:${e.minWidth}px`):o&&i.push(`min-width:${o}px`),i.join(";")}fitColumnsMinWidth(){return this.layout!=="fit-columns"||!this.columns.some(e=>e.minWidth)?0:this.columns.reduce((e,t,o)=>{const i=P1(t)&&!t.width&&!t.minWidth?Ca:Math.max(this.widthFor(t,o)??0,t.minWidth??0);return e+i},0)}isColumnResizable(e){return e.isResizable??this.resizableColumns}onResizeStart(e,t,o){e.preventDefault(),e.stopPropagation();const i=e.currentTarget,s=i.closest("th");if(!s)return;const r=s.getBoundingClientRect().width;this.resizeDrag={key:this.columnKey(t,o),startX:e.clientX,startWidth:r,width:r},this.resizingKey=this.resizeDrag.key,i.setPointerCapture(e.pointerId)}onResizeReset(e,t,o){e.preventDefault(),e.stopPropagation();const i=this.columnKey(t,o);if(this.resizedWidths[i]===void 0)return;const s={...this.resizedWidths};delete s[i],this.resizedWidths=s,this.dispatchEvent(new CustomEvent(B2,{detail:{column:t,field:i,width:null},bubbles:!0,composed:!0}))}resetColumnWidths(){this.resizedWidths={}}alignClass(e){const t=e.align??this.columnAlign,o=e.verticalAlign??this.columnVerticalAlign;return[t!=="left"?`table__cell--${t}`:"",o!=="middle"?`table__cell--${o}`:""].filter(Boolean).join(" ")}renderHeaderCell(e,t){const o=this.frozenSides,i=o[t],s=i==="left"?o[t+1]!=="left":i==="right"?o[t-1]!=="right":!1,r=["table__header-cell",i?"table__header-cell--frozen":"",i&&s?`table__header-cell--frozen-${i}-edge`:"",!P1(e)&&e.isSortable?"table__header-cell--sortable":"",P1(e)?"table__cell--selection":"",this.sizingClass(e,t)].filter(Boolean).join(" "),a=this.cellStyle(e,t),c=e.headerAlign??e.align??this.columnAlign,u=["table__header-inner",c!=="left"?`table__header-inner--${c}`:""].filter(Boolean).join(" "),h=this.columnKey(e,t),f=this.isColumnResizable(e)?d`
4701
+ `;let K=_r;c1([l()],K.prototype,"format");c1([l()],K.prototype,"value");c1([l()],K.prototype,"size");c1([l({type:Boolean})],K.prototype,"disabled");c1([l({type:Boolean})],K.prototype,"readonly");c1([l()],K.prototype,"status");c1([l({attribute:"start-icon"})],K.prototype,"startIcon");c1([l({attribute:"min-date"})],K.prototype,"minDate");c1([l({attribute:"max-date"})],K.prototype,"maxDate");c1([l()],K.prototype,"placement");c1([l()],K.prototype,"inputid");c1([b()],K.prototype,"_open");c1([E("anduin-date-input")],K.prototype,"_inputEl");c1([E("anduin-popover")],K.prototype,"_popoverEl");customElements.get("anduin-date-picker")||customElements.define("anduin-date-picker",K);var d9=Object.defineProperty,k=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&d9(e,t,i),i};const Q4="anduin-table:sort",e3="anduin-table:column-click",t3="anduin-table:row-click",i3="anduin-table:selection-change",o3="anduin-table:cell-context-menu",n3="anduin-table:row-expand",s3="anduin-table:row-collapse",r3="anduin-table:group-toggle",B2="anduin-table:column-resize",Ca=40,P1=n=>n.type==="selection",re=(n,e)=>{if(!e)return;let t=n;for(const o of e.split(".")){if(t===null||typeof t!="object")return;t=t[o]}return t},c9=(n,e)=>n===e?0:n==null?1:e==null?-1:typeof n=="number"&&typeof e=="number"?n-e:typeof n=="boolean"&&typeof e=="boolean"?Number(n)-Number(e):n instanceof Date&&e instanceof Date?n.getTime()-e.getTime():String(n).localeCompare(String(e),void 0,{numeric:!0,sensitivity:"base"}),yr=class yr extends C{constructor(){super(...arguments),this.columns=[],this.data=[],this.layout="fit-data",this.renderMode="basic",this.rowHeight=40,this.height="",this.maxHeight="",this.minHeight="",this.resizableColumns=!0,this.hideHeader=!1,this.loading=!1,this.selectable="clickable",this.indexColumn="id",this.columnAlign="left",this.columnVerticalAlign="middle",this.sortField="",this.sortDirection="asc",this.dataTree=!1,this.treeChildrenField="children",this.treeChildIndent=20,this.groupBy="",this.selectedRows=[],this.expandedKeys=new Set,this.collapsedGroups=new Set,this.virtualScrollTop=0,this.viewportHeight=0,this.resizedWidths={},this.resizingKey="",this.rangeAnchorKey=null,this.isDraggingRange=!1,this.dragBaseKeys=[],this.dragSelects=!0,this.autoExpandedKeys=new Set,this.resizeDrag=null,this.resizeFrame=0,this.renderSelectedKeys=new Set,this.renderSelectableRows=[],this.cachedRenderRows=[],this.rowsDirty=!0,this.onWindowMouseUp=()=>{this.isDraggingRange=!1},this.onScroll=e=>{const t=e.currentTarget;this.renderMode==="virtual"&&(this.virtualScrollTop=t.scrollTop),this.syncHorizontalScrollState()},this.onResizeMove=e=>{const t=this.resizeDrag;if(!t)return;const o=48;t.width=Math.max(o,t.startWidth+(e.clientX-t.startX)),!this.resizeFrame&&(this.resizeFrame=requestAnimationFrame(()=>{this.resizeFrame=0,this.resizeDrag&&(this.resizedWidths={...this.resizedWidths,[t.key]:t.width})}))},this.onResizeEnd=e=>{const t=this.resizeDrag;t&&(this.resizeFrame&&(cancelAnimationFrame(this.resizeFrame),this.resizeFrame=0),this.resizedWidths={...this.resizedWidths,[t.key]:t.width},this.resizeDrag=null,this.resizingKey="",this.dispatchEvent(new CustomEvent(B2,{detail:{column:e,field:t.key,width:t.width},bubbles:!0,composed:!0})))}}connectedCallback(){super.connectedCallback(),window.addEventListener("mouseup",this.onWindowMouseUp)}disconnectedCallback(){var e;super.disconnectedCallback(),window.removeEventListener("mouseup",this.onWindowMouseUp),(e=this.resizeObserver)==null||e.disconnect(),this.resizeObserver=void 0}firstUpdated(){const e=this.scrollEl;e&&(this.resizeObserver=new ResizeObserver(()=>{this.viewportHeight=e.clientHeight,this.syncHorizontalScrollState()}),this.resizeObserver.observe(e),this.viewportHeight=e.clientHeight)}willUpdate(e){["data","columns","sortField","sortDirection","groupBy","dataTree","treeChildrenField","indexColumn","onStartExpanded","isRowDisabled","selectedRows","expandedKeys","collapsedGroups"].some(o=>e.has(o))&&(this.rowsDirty=!0),this.rowsDirty&&(this.cachedRenderRows=this.buildRenderRows(),this.renderSelectedKeys=this.selectedKeySet,this.renderSelectableRows=this.cachedRenderRows.filter(o=>o.kind==="row"&&!this.rowIsDisabled(o.data)),this.rowsDirty=!1)}updated(){this.applyFrozenOffsets(),this.syncHorizontalScrollState()}get scrollEl(){return this.renderRoot.querySelector(".table__scroll")}keyFor(e,t){const o=re(e,this.indexColumn);return o==null?`__index:${t}`:String(o)}get selectedKeySet(){const e=new Set;return this.selectedRows.forEach((t,o)=>e.add(this.keyFor(t,o))),e}rowIsDisabled(e){return this.isRowDisabled?this.isRowDisabled(e):!1}get frozenSides(){const e=this.columns,t=e.map(()=>null);for(let o=0;o<e.length;o++){const i=e[o].isFrozen;if(!i)break;t[o]=i==="right"?"right":"left"}for(let o=e.length-1;o>=0;o--){const i=e[o].isFrozen;if(!i)break;t[o]===null&&(t[o]=i==="left"?"left":"right")}for(let o=0;o<e.length;o++){const i=e[o].isFrozen;(i==="left"||i==="right")&&(t[o]=i)}return t}applyFrozenOffsets(){const e=this.frozenSides;if(!e.some(Boolean))return;const t=Array.from(this.renderRoot.querySelectorAll("thead th[data-col]"));if(t.length===0)return;const o=t.map(c=>c.getBoundingClientRect().width),i=e.map(()=>null);let s=0;for(let c=0;c<e.length;c++)e[c]==="left"&&(i[c]=s,s+=o[c]??0);let r=0;for(let c=e.length-1;c>=0;c--)e[c]==="right"&&(i[c]=r,r+=o[c]??0);this.renderRoot.querySelectorAll("[data-col]").forEach(c=>{const u=Number(c.dataset.col),h=e[u],g=i[u];!h||g===null||(c.style[h]=`${g}px`)})}get sortedColumn(){if(this.sortField)return this.columns.find(e=>!P1(e)&&e.field===this.sortField)}sortRows(e){const t=this.sortedColumn;if(!t)return e;const o=this.sortDirection==="desc"?-1:1,i=t.sortWith?(s,r)=>t.sortWith({a:s,b:r}):(s,r)=>c9(re(s,t.field),re(r,t.field));return[...e].sort((s,r)=>i(s,r)*o)}onHeaderClick(e){if(this.dispatchEvent(new CustomEvent(e3,{detail:{column:e},bubbles:!0,composed:!0})),!e.isSortable)return;let t=e.field,o="asc";this.sortField===e.field&&(this.sortDirection==="asc"?o="desc":(t="",o=null)),this.sortField=t,o&&(this.sortDirection=o),this.dispatchEvent(new CustomEvent(Q4,{detail:{field:t,direction:o,column:e},bubbles:!0,composed:!0}))}buildRenderRows(){return this.groupBy?this.buildGroupedRows():this.buildFlatRows(this.sortRows(this.data),0)}buildFlatRows(e,t){const o=[];return e.forEach((i,s)=>{const r=this.keyFor(i,s),a=this.dataTree?re(i,this.treeChildrenField):void 0,c=Array.isArray(a)&&a.length>0,u=c&&this.isExpanded(r,i);o.push({kind:"row",data:i,key:r,depth:t,hasChildren:c,expanded:u}),u&&o.push(...this.buildFlatRows(this.sortRows(a),t+1))}),o}buildGroupedRows(){const e=new Map;this.data.forEach(o=>{const i=re(o,this.groupBy),s=String(i),r=e.get(s);r?r.rows.push(o):e.set(s,{value:i,rows:[o]})});const t=[];return e.forEach(({value:o,rows:i},s)=>{const r=!this.collapsedGroups.has(s);t.push({kind:"group",key:s,value:o,rows:i,expanded:r}),r&&t.push(...this.buildFlatRows(this.sortRows(i),0))}),t}isExpanded(e,t){return this.expandedKeys.has(e)?!0:this.onStartExpanded&&!this.autoExpandedKeys.has(e)&&(this.autoExpandedKeys.add(e),this.onStartExpanded(t))?(this.expandedKeys.add(e),!0):!1}toggleTreeRow(e){const t=!e.expanded,o=new Set(this.expandedKeys);t?o.add(e.key):o.delete(e.key),this.expandedKeys=o,this.dispatchEvent(new CustomEvent(t?n3:s3,{detail:{data:e.data,key:e.key,expanded:t},bubbles:!0,composed:!0}))}toggleGroup(e){const t=!e.expanded,o=new Set(this.collapsedGroups);t?o.delete(e.key):o.add(e.key),this.collapsedGroups=o,this.dispatchEvent(new CustomEvent(r3,{detail:{value:e.value,rows:e.rows,expanded:t},bubbles:!0,composed:!0}))}expandAll(){const e=new Set,t=o=>{o.forEach((i,s)=>{const r=re(i,this.treeChildrenField);Array.isArray(r)&&r.length>0&&(e.add(this.keyFor(i,s)),t(r))})};t(this.data),this.expandedKeys=e}collapseAll(){this.expandedKeys=new Set}get selectableRows(){return this.buildRenderRows().filter(e=>e.kind==="row"&&!this.rowIsDisabled(e.data))}commitSelection(e){const t=new Map,o=s=>{s.forEach((r,a)=>{t.set(this.keyFor(r,a),r);const c=this.dataTree?re(r,this.treeChildrenField):void 0;Array.isArray(c)&&o(c)})};o(this.data);const i=[...e].filter(s=>t.has(s));this.selectedRows=i.map(s=>t.get(s)),this.dispatchEvent(new CustomEvent(i3,{detail:{selectedRows:this.selectedRows,selectedKeys:i},bubbles:!0,composed:!0}))}setRowSelected(e,t){if(this.rowIsDisabled(e.data))return;const o=this.selectedKeySet;t?o.add(e.key):o.delete(e.key),this.rangeAnchorKey=e.key,this.commitSelection(o)}toggleAllRows(e){const t=this.selectedKeySet;this.selectableRows.forEach(o=>{e?t.add(o.key):t.delete(o.key)}),this.commitSelection(t)}selectRange(e,t,o){const i=this.selectableRows,s=i.findIndex(g=>g.key===e.key);if(s<0)return;const r=this.rangeAnchorKey?i.findIndex(g=>g.key===this.rangeAnchorKey):-1,a=r<0?s:r,[c,u]=a<=s?[a,s]:[s,a],h=new Set(o);for(let g=c;g<=u;g++)t?h.add(i[g].key):h.delete(i[g].key);this.commitSelection(h)}onRowMouseDown(e,t){this.selectable!=="selectable-by-dragging"||!e.shiftKey||this.rowIsDisabled(t.data)||(e.preventDefault(),this.isDraggingRange=!0,this.dragBaseKeys=[...this.selectedKeySet],this.dragSelects=!this.selectedKeySet.has(t.key),this.rangeAnchorKey=t.key,this.selectRange(t,this.dragSelects,this.dragBaseKeys))}onRowMouseEnter(e){this.isDraggingRange&&this.selectRange(e,this.dragSelects,this.dragBaseKeys)}onRowClick(e,t,o){this.dispatchEvent(new CustomEvent(t3,{detail:{data:t.data,key:t.key,index:o,originalEvent:e},bubbles:!0,composed:!0}));const i=this.selectable;if(i==="unselectable"||i==="clickable"||this.rowIsDisabled(t.data))return;const s=this.selectedKeySet.has(t.key);if(i==="selectable-by-clicking"&&e.shiftKey){this.selectRange(t,!0,e.metaKey||e.ctrlKey?[...this.selectedKeySet]:[]);return}if(i==="selectable-by-clicking"&&!(e.metaKey||e.ctrlKey)){this.rangeAnchorKey=t.key,this.commitSelection(new Set(s&&this.selectedRows.length===1?[]:[t.key]));return}this.setRowSelected(t,!s)}onCellContextMenu(e,t,o,i){this.dispatchEvent(new CustomEvent(o3,{detail:{data:t.data,key:t.key,index:o,column:i,x:e.clientX,y:e.clientY,originalEvent:e},bubbles:!0,composed:!0,cancelable:!0}))}syncHorizontalScrollState(){const e=this.scrollEl,t=e==null?void 0:e.parentElement;!e||!t||(t.classList.toggle("table--scrolled-x",e.scrollLeft>0),t.classList.toggle("table--scrollable-x-end",Math.ceil(e.scrollLeft+e.clientWidth)<e.scrollWidth))}columnKey(e,t){return P1(e)?`__selection:${t}`:e.field||`__col:${t}`}widthFor(e,t){return this.resizedWidths[this.columnKey(e,t)]??e.width}isStretchColumn(e,t){return this.layout!=="fit-data-stretch"||t!==this.columns.length-1?!1:this.resizedWidths[this.columnKey(e,t)]===void 0}sizingClass(e,t){return this.isStretchColumn(e,t)?"table__cell--stretch":this.widthFor(e,t)?"table__cell--sized":""}cellStyle(e,t){if(this.isStretchColumn(e,t))return"width:100%";const o=this.widthFor(e,t),i=[];return o&&(i.push(`width:${o}px`),this.layout!=="fit-columns"&&i.push(`max-width:${o}px`)),e.minWidth?i.push(`min-width:${e.minWidth}px`):o&&i.push(`min-width:${o}px`),i.join(";")}fitColumnsMinWidth(){return this.layout!=="fit-columns"||!this.columns.some(e=>e.minWidth)?0:this.columns.reduce((e,t,o)=>{const i=P1(t)&&!t.width&&!t.minWidth?Ca:Math.max(this.widthFor(t,o)??0,t.minWidth??0);return e+i},0)}isColumnResizable(e){return e.isResizable??this.resizableColumns}onResizeStart(e,t,o){e.preventDefault(),e.stopPropagation();const i=e.currentTarget,s=i.closest("th");if(!s)return;const r=s.getBoundingClientRect().width;this.resizeDrag={key:this.columnKey(t,o),startX:e.clientX,startWidth:r,width:r},this.resizingKey=this.resizeDrag.key,i.setPointerCapture(e.pointerId)}onResizeReset(e,t,o){e.preventDefault(),e.stopPropagation();const i=this.columnKey(t,o);if(this.resizedWidths[i]===void 0)return;const s={...this.resizedWidths};delete s[i],this.resizedWidths=s,this.dispatchEvent(new CustomEvent(B2,{detail:{column:t,field:i,width:null},bubbles:!0,composed:!0}))}resetColumnWidths(){this.resizedWidths={}}alignClass(e){const t=e.align??this.columnAlign,o=e.verticalAlign??this.columnVerticalAlign;return[t!=="left"?`table__cell--${t}`:"",o!=="middle"?`table__cell--${o}`:""].filter(Boolean).join(" ")}renderHeaderCell(e,t){const o=this.frozenSides,i=o[t],s=i==="left"?o[t+1]!=="left":i==="right"?o[t-1]!=="right":!1,r=["table__header-cell",i?"table__header-cell--frozen":"",i&&s?`table__header-cell--frozen-${i}-edge`:"",!P1(e)&&e.isSortable?"table__header-cell--sortable":"",P1(e)?"table__cell--selection":"",this.sizingClass(e,t)].filter(Boolean).join(" "),a=this.cellStyle(e,t),c=e.headerAlign??e.align??this.columnAlign,u=["table__header-inner",c!=="left"?`table__header-inner--${c}`:""].filter(Boolean).join(" "),h=this.columnKey(e,t),g=this.isColumnResizable(e)?d`
4702
4702
  <span
4703
4703
  class="table__resize-handle ${this.resizingKey===h?"table__resize-handle--active":""}"
4704
4704
  part="resize-handle"
@@ -4712,7 +4712,7 @@
4712
4712
  @dblclick=${y=>this.onResizeReset(y,e,t)}
4713
4713
  @click=${y=>y.stopPropagation()}
4714
4714
  ></span>
4715
- `:g;if(P1(e)){const y=this.renderSelectableRows,V=this.renderSelectedKeys,k=y.filter(R=>V.has(R.key)).length,M=y.length>0&&k===y.length,$=k>0&&!M,N=e.renderHeader?e.renderHeader({areAllRowsSelected:M,hasSelectedRow:k>0,onChange:R=>this.toggleAllRows(R)}):d`
4715
+ `:f;if(P1(e)){const y=this.renderSelectableRows,V=this.renderSelectedKeys,L=y.filter(R=>V.has(R.key)).length,M=y.length>0&&L===y.length,$=L>0&&!M,N=e.renderHeader?e.renderHeader({areAllRowsSelected:M,hasSelectedRow:L>0,onChange:R=>this.toggleAllRows(R)}):d`
4716
4716
  <anduin-checkbox
4717
4717
  .checked=${M}
4718
4718
  .indeterminate=${$}
@@ -4726,31 +4726,31 @@
4726
4726
  scope="col"
4727
4727
  data-col="${t}"
4728
4728
  style="${a}"
4729
- ><div class="${u}">${N}</div>${f}</th>
4729
+ ><div class="${u}">${N}</div>${g}</th>
4730
4730
  `}const m=this.sortField===e.field,v=m?this.sortDirection:null,_=e.renderHeader?e.renderHeader({column:e,sortDirection:v}):d`<span class="table__header-text">${e.title??""}</span>`,x=e.isSortable?d`
4731
4731
  <anduin-icon
4732
4732
  class="table__sort-icon ${m?"table__sort-icon--active":""}"
4733
4733
  name="${v==="desc"?"caretDown":"caretUp"}"
4734
4734
  size="16"
4735
4735
  ></anduin-icon>
4736
- `:g;return d`
4736
+ `:f;return d`
4737
4737
  <th
4738
4738
  class="${r}"
4739
4739
  part="header-cell"
4740
4740
  scope="col"
4741
4741
  data-col="${t}"
4742
4742
  style="${a}"
4743
- tabindex="${e.isSortable?"0":g}"
4744
- aria-sort="${m?v==="desc"?"descending":"ascending":e.isSortable?"none":g}"
4743
+ tabindex="${e.isSortable?"0":f}"
4744
+ aria-sort="${m?v==="desc"?"descending":"ascending":e.isSortable?"none":f}"
4745
4745
  @click=${()=>this.onHeaderClick(e)}
4746
4746
  @keydown=${y=>{e.isSortable&&(y.key!=="Enter"&&y.key!==" "||(y.preventDefault(),this.onHeaderClick(e)))}}
4747
- ><div class="${u}">${_}${x}</div>${f}</th>
4748
- `}renderCell(e,t,o,i){const s=this.frozenSides,r=s[i],a=r==="left"?s[i+1]!=="left":r==="right"?s[i-1]!=="right":!1,c=["table__cell",this.alignClass(o),r?"table__cell--frozen":"",r&&a?`table__cell--frozen-${r}-edge`:"",P1(o)?"table__cell--selection":"",o.showOnRowHover?"table__cell--hover-only":"",this.sizingClass(o,i)].filter(Boolean).join(" "),u=this.cellStyle(o,i);if(P1(o)){const _=this.renderSelectedKeys.has(e.key),x=this.rowIsDisabled(e.data),y=k=>this.setRowSelected(e,k),V=o.renderCell?o.renderCell({data:e.data,isChecked:_,isDisabled:x,onChange:y}):d`
4747
+ ><div class="${u}">${_}${x}</div>${g}</th>
4748
+ `}renderCell(e,t,o,i){const s=this.frozenSides,r=s[i],a=r==="left"?s[i+1]!=="left":r==="right"?s[i-1]!=="right":!1,c=["table__cell",this.alignClass(o),r?"table__cell--frozen":"",r&&a?`table__cell--frozen-${r}-edge`:"",P1(o)?"table__cell--selection":"",o.showOnRowHover?"table__cell--hover-only":"",this.sizingClass(o,i)].filter(Boolean).join(" "),u=this.cellStyle(o,i);if(P1(o)){const _=this.renderSelectedKeys.has(e.key),x=this.rowIsDisabled(e.data),y=L=>this.setRowSelected(e,L),V=o.renderCell?o.renderCell({data:e.data,isChecked:_,isDisabled:x,onChange:y}):d`
4749
4749
  <anduin-checkbox
4750
4750
  .checked=${_}
4751
4751
  .disabled=${x}
4752
4752
  aria-label="${_?"Deselect row":"Select row"}"
4753
- @anduin-checkbox:change=${k=>{k.stopPropagation(),y(!_)}}
4753
+ @anduin-checkbox:change=${L=>{L.stopPropagation(),y(!_)}}
4754
4754
  ></anduin-checkbox>
4755
4755
  `;return d`
4756
4756
  <td
@@ -4758,9 +4758,9 @@
4758
4758
  part="cell"
4759
4759
  data-col="${i}"
4760
4760
  style="${u}"
4761
- @click=${k=>k.stopPropagation()}
4761
+ @click=${L=>L.stopPropagation()}
4762
4762
  >${V}</td>
4763
- `}const h=re(e.data,o.field),f=o.renderCell?o.renderCell({data:e.data,value:h,rowIndex:t,column:o}):h==null?g:String(h),v=this.dataTree&&i===this.firstDataColumnIndex?d`
4763
+ `}const h=re(e.data,o.field),g=o.renderCell?o.renderCell({data:e.data,value:h,rowIndex:t,column:o}):h==null?f:String(h),v=this.dataTree&&i===this.firstDataColumnIndex?d`
4764
4764
  <div class="table__tree-cell" style="padding-left:${e.depth*this.treeChildIndent}px">
4765
4765
  ${e.hasChildren?d`
4766
4766
  <button
@@ -4776,9 +4776,9 @@
4776
4776
  ></anduin-icon>
4777
4777
  </button>
4778
4778
  `:d`<span class="table__tree-spacer"></span>`}
4779
- <span>${f}</span>
4779
+ <span>${g}</span>
4780
4780
  </div>
4781
- `:f;return d`
4781
+ `:g;return d`
4782
4782
  <td
4783
4783
  class="${c}"
4784
4784
  part="cell"
@@ -4790,14 +4790,14 @@
4790
4790
  <tr
4791
4791
  class="${r}"
4792
4792
  part="${s?`row ${s}`:"row"}"
4793
- aria-selected="${this.selectable==="unselectable"||this.selectable==="clickable"?g:String(o)}"
4793
+ aria-selected="${this.selectable==="unselectable"||this.selectable==="clickable"?f:String(o)}"
4794
4794
  style="${this.renderMode==="virtual"?`height:${this.rowHeight}px`:""}"
4795
4795
  @click=${a=>this.onRowClick(a,e,t)}
4796
4796
  @mousedown=${a=>this.onRowMouseDown(a,e)}
4797
4797
  @mouseenter=${()=>this.onRowMouseEnter(e)}
4798
4798
  >
4799
4799
  ${this.columns.map((a,c)=>this.renderCell(e,t,a,c))}
4800
- ${this.layout==="fit-data-fill"?d`<td class="table__cell" style="width:100%"></td>`:g}
4800
+ ${this.layout==="fit-data-fill"?d`<td class="table__cell" style="width:100%"></td>`:f}
4801
4801
  </tr>
4802
4802
  `}renderGroupRow(e){const t=this.renderGroupHeader?this.renderGroupHeader(e.value,e.rows.length,e.rows):d`
4803
4803
  <span>${String(e.value)}</span>
@@ -4825,26 +4825,26 @@
4825
4825
  <slot name="empty">No data to display</slot>
4826
4826
  </td>
4827
4827
  </tr>
4828
- `}render(){const e=this.cachedRenderRows,t=[this.height?`height:${this.height}`:"",this.maxHeight?`max-height:${this.maxHeight}`:"",this.minHeight?`min-height:${this.minHeight}`:""].filter(Boolean).join(";"),o=this.fitColumnsMinWidth(),i=["table",this.scrolledX?"table--scrolled-x":"",this.scrollableXEnd?"table--scrollable-x-end":""].filter(Boolean).join(" ");let s=e,r=0,a=0,c=0;if(this.renderMode==="virtual"&&e.length>0){const h=Math.ceil((this.viewportHeight||400)/this.rowHeight),f=Math.max(0,Math.floor(this.virtualScrollTop/this.rowHeight)-6),m=Math.min(e.length,f+h+12);s=e.slice(f,m),r=f*this.rowHeight,a=(e.length-m)*this.rowHeight,c=f}return d`
4829
- <div class="${i}" part="table" style="${t}">
4828
+ `}render(){const e=this.cachedRenderRows,t=[this.height?`height:${this.height}`:"",this.maxHeight?`max-height:${this.maxHeight}`:"",this.minHeight?`min-height:${this.minHeight}`:""].filter(Boolean).join(";"),o=this.fitColumnsMinWidth();let i=e,s=0,r=0,a=0;if(this.renderMode==="virtual"&&e.length>0){const u=Math.ceil((this.viewportHeight||400)/this.rowHeight),h=Math.max(0,Math.floor(this.virtualScrollTop/this.rowHeight)-6),g=Math.min(e.length,h+u+12);i=e.slice(h,g),s=h*this.rowHeight,r=(e.length-g)*this.rowHeight,a=h}return d`
4829
+ <div class="table" part="table" style="${t}">
4830
4830
  <div class="table__scroll" part="scroll" @scroll=${this.onScroll}>
4831
4831
  <table
4832
4832
  class="table__el table__el--${this.layout}"
4833
4833
  style="${o?`min-width:${o}px`:""}"
4834
4834
  >
4835
- ${this.hideHeader?g:d`
4835
+ ${this.hideHeader?f:d`
4836
4836
  <thead part="header">
4837
4837
  <tr class="table__header-row" part="header-row">
4838
- ${this.columns.map((u,h)=>this.renderHeaderCell(u,h))}
4839
- ${this.layout==="fit-data-fill"?d`<th class="table__header-cell" style="width:100%"></th>`:g}
4838
+ ${this.columns.map((c,u)=>this.renderHeaderCell(c,u))}
4839
+ ${this.layout==="fit-data-fill"?d`<th class="table__header-cell" style="width:100%"></th>`:f}
4840
4840
  </tr>
4841
4841
  </thead>
4842
4842
  `}
4843
4843
  <tbody part="body">
4844
- ${e.length===0?this.renderPlaceholder():g}
4845
- ${r>0?d`<tr style="height:${r}px" aria-hidden="true"><td colspan="${this.columnCount}"></td></tr>`:g}
4846
- ${s.map((u,h)=>u.kind==="group"?this.renderGroupRow(u):this.renderRow(u,c+h))}
4847
- ${a>0?d`<tr style="height:${a}px" aria-hidden="true"><td colspan="${this.columnCount}"></td></tr>`:g}
4844
+ ${e.length===0?this.renderPlaceholder():f}
4845
+ ${s>0?d`<tr style="height:${s}px" aria-hidden="true"><td colspan="${this.columnCount}"></td></tr>`:f}
4846
+ ${i.map((c,u)=>c.kind==="group"?this.renderGroupRow(c):this.renderRow(c,a+u))}
4847
+ ${r>0?d`<tr style="height:${r}px" aria-hidden="true"><td colspan="${this.columnCount}"></td></tr>`:f}
4848
4848
  </tbody>
4849
4849
  </table>
4850
4850
  </div>
@@ -4852,7 +4852,7 @@
4852
4852
  <div class="table__loading" part="loading">
4853
4853
  <slot name="loading"><anduin-spinner size="medium"></anduin-spinner></slot>
4854
4854
  </div>
4855
- `:g}
4855
+ `:f}
4856
4856
  </div>
4857
4857
  `}};yr.styles=p`${B}
4858
4858
 
@@ -5224,7 +5224,7 @@
5224
5224
  background-color: oklch(from var(--color-background) l c h / 0.6);
5225
5225
  cursor: progress;
5226
5226
  }
5227
- `;let H=yr;L([l({attribute:!1})],H.prototype,"columns");L([l({attribute:!1})],H.prototype,"data");L([l({reflect:!0})],H.prototype,"layout");L([l({attribute:"render-mode",reflect:!0})],H.prototype,"renderMode");L([l({type:Number,attribute:"row-height"})],H.prototype,"rowHeight");L([l()],H.prototype,"height");L([l({attribute:"max-height"})],H.prototype,"maxHeight");L([l({attribute:"min-height"})],H.prototype,"minHeight");L([l({attribute:"resizable-columns",converter:n=>n!=="false"})],H.prototype,"resizableColumns");L([l({type:Boolean,attribute:"hide-header",reflect:!0})],H.prototype,"hideHeader");L([l({type:Boolean,reflect:!0})],H.prototype,"loading");L([l({reflect:!0})],H.prototype,"selectable");L([l({attribute:"index-column"})],H.prototype,"indexColumn");L([l({attribute:"column-align"})],H.prototype,"columnAlign");L([l({attribute:"column-vertical-align"})],H.prototype,"columnVerticalAlign");L([l({attribute:"sort-field"})],H.prototype,"sortField");L([l({attribute:"sort-direction"})],H.prototype,"sortDirection");L([l({type:Boolean,attribute:"data-tree",reflect:!0})],H.prototype,"dataTree");L([l({attribute:"tree-children-field"})],H.prototype,"treeChildrenField");L([l({type:Number,attribute:"tree-child-indent"})],H.prototype,"treeChildIndent");L([l({attribute:"group-by"})],H.prototype,"groupBy");L([l({attribute:!1})],H.prototype,"selectedRows");L([l({attribute:!1})],H.prototype,"isRowDisabled");L([l({attribute:!1})],H.prototype,"onStartExpanded");L([l({attribute:!1})],H.prototype,"rowClass");L([l({attribute:!1})],H.prototype,"renderGroupHeader");L([b()],H.prototype,"expandedKeys");L([b()],H.prototype,"collapsedGroups");L([b()],H.prototype,"virtualScrollTop");L([b()],H.prototype,"viewportHeight");L([b()],H.prototype,"scrolledX");L([b()],H.prototype,"scrollableXEnd");L([b()],H.prototype,"resizedWidths");L([b()],H.prototype,"resizingKey");customElements.get("anduin-table")||customElements.define("anduin-table",H);var h9=Object.defineProperty,Xe=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&h9(e,t,i),i};const l3="anduin-navigation-bar-value-change",u9={backgroundColor:"--anduin-navigation-bar-background-color",textColor:"--anduin-navigation-bar-text-color",activeBackgroundColor:"--anduin-navigation-bar-active-background-color",activeTextColor:"--anduin-navigation-bar-active-text-color",itemBackgroundColor:"--anduin-navigation-bar-item-background-color"},N2="anduin-navigation-bar-item",k2=1,p9={fromAttribute:n=>n===null?null:n!=="false",toAttribute:n=>n==null?null:String(n)},xr=class xr extends A1{constructor(){super(...arguments),this.overflowing=!1,this.layoutFrame=0}connectedCallback(){this.hasAttribute("role")||this.setAttribute("role","navigation"),this.hasAttribute("aria-label")||this.setAttribute("aria-label","Navigation"),super.connectedCallback(),this.resizeObserver??(this.resizeObserver=new ResizeObserver(()=>this.scheduleLayout())),this.mutationObserver??(this.mutationObserver=new MutationObserver(()=>{this.syncItems(),this.refreshObserved()})),this.mutationObserver.observe(this,{childList:!0,subtree:!0,characterData:!0,attributes:!0}),this.refreshObserved()}disconnectedCallback(){var e,t;super.disconnectedCallback(),this.layoutFrame&&cancelAnimationFrame(this.layoutFrame),this.layoutFrame=0,(e=this.resizeObserver)==null||e.disconnect(),(t=this.mutationObserver)==null||t.disconnect()}willUpdate(e){e.has("defaultValue")&&!this.isControlled&&this.defaultValue&&(this.internalValue=this.defaultValue),(e.has("value")&&this.isControlled||e.has("internalValue"))&&this.scheduleScrollToValue(this.selection)}firstUpdated(){this.refreshObserved()}get items(){return Array.from(this.querySelectorAll(N2)).filter(e=>e.closest("anduin-navigation-bar")===this)}syncItems(){const e=this.items;!this.isControlled&&!this.hasAttribute("default-value")&&!this.internalValue&&e.length&&(this.internalValue=e[0].value);const t=this.selection;for(const o of e)o.barSelected=o.value===t}handleItemClick(e){this.isControlled||(this.setAttribute("default-value",e),this.internalValue=e),P(this,l3,e),this.scheduleScrollToValue(e)}refreshObserved(){const e=this.resizeObserver;if(e){e.disconnect(),e.observe(this),this.viewport&&e.observe(this.viewport);for(const t of this.items)e.observe(t);this.scheduleLayout()}}scheduleLayout(){!this.isConnected||this.layoutFrame||(this.layoutFrame=requestAnimationFrame(()=>{this.layoutFrame=0,this.updateLayout()}))}updateLayout(){const e=this.viewport;if(!e)return;const t=e.scrollWidth>e.clientWidth+k2;t!==this.overflowing&&(this.overflowing=t,t&&this.scheduleScrollToValue(this.selection))}scrollOneItem(e){const t=this.viewport;if(!t)return;const o=this.items,i=t.getBoundingClientRect();let s;if(e){const a=o.findIndex(c=>c.getBoundingClientRect().left>=i.left-k2);s=Math.max(0,a-1)}else{let a=-1;o.forEach((c,u)=>{c.getBoundingClientRect().right<=i.right+k2&&(a=u)}),s=Math.min(o.length-1,a+1)}const r=o[s];r&&this.scrollToItem(r)}scheduleScrollToValue(e){!e||!this.isConnected||requestAnimationFrame(()=>{if(!this.overflowing)return;const t=this.items.find(o=>o.getAttribute("value")===e);t&&this.scrollToItem(t)})}scrollToItem(e){const t=this.viewport;if(!t)return;const o=t.scrollLeft+e.getBoundingClientRect().left-t.getBoundingClientRect().left;t.scrollTo({top:0,left:o,behavior:"smooth"})}renderArrow(e){return d`
5227
+ `;let H=yr;k([l({attribute:!1})],H.prototype,"columns");k([l({attribute:!1})],H.prototype,"data");k([l({reflect:!0})],H.prototype,"layout");k([l({attribute:"render-mode",reflect:!0})],H.prototype,"renderMode");k([l({type:Number,attribute:"row-height"})],H.prototype,"rowHeight");k([l()],H.prototype,"height");k([l({attribute:"max-height"})],H.prototype,"maxHeight");k([l({attribute:"min-height"})],H.prototype,"minHeight");k([l({attribute:"resizable-columns",converter:n=>n!=="false"})],H.prototype,"resizableColumns");k([l({type:Boolean,attribute:"hide-header",reflect:!0})],H.prototype,"hideHeader");k([l({type:Boolean,reflect:!0})],H.prototype,"loading");k([l({reflect:!0})],H.prototype,"selectable");k([l({attribute:"index-column"})],H.prototype,"indexColumn");k([l({attribute:"column-align"})],H.prototype,"columnAlign");k([l({attribute:"column-vertical-align"})],H.prototype,"columnVerticalAlign");k([l({attribute:"sort-field"})],H.prototype,"sortField");k([l({attribute:"sort-direction"})],H.prototype,"sortDirection");k([l({type:Boolean,attribute:"data-tree",reflect:!0})],H.prototype,"dataTree");k([l({attribute:"tree-children-field"})],H.prototype,"treeChildrenField");k([l({type:Number,attribute:"tree-child-indent"})],H.prototype,"treeChildIndent");k([l({attribute:"group-by"})],H.prototype,"groupBy");k([l({attribute:!1})],H.prototype,"selectedRows");k([l({attribute:!1})],H.prototype,"isRowDisabled");k([l({attribute:!1})],H.prototype,"onStartExpanded");k([l({attribute:!1})],H.prototype,"rowClass");k([l({attribute:!1})],H.prototype,"renderGroupHeader");k([b()],H.prototype,"expandedKeys");k([b()],H.prototype,"collapsedGroups");k([b()],H.prototype,"virtualScrollTop");k([b()],H.prototype,"viewportHeight");k([b()],H.prototype,"resizedWidths");k([b()],H.prototype,"resizingKey");customElements.get("anduin-table")||customElements.define("anduin-table",H);var h9=Object.defineProperty,Xe=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&h9(e,t,i),i};const l3="anduin-navigation-bar-value-change",u9={backgroundColor:"--anduin-navigation-bar-background-color",textColor:"--anduin-navigation-bar-text-color",activeBackgroundColor:"--anduin-navigation-bar-active-background-color",activeTextColor:"--anduin-navigation-bar-active-text-color",itemBackgroundColor:"--anduin-navigation-bar-item-background-color"},N2="anduin-navigation-bar-item",k2=1,p9={fromAttribute:n=>n===null?null:n!=="false",toAttribute:n=>n==null?null:String(n)},xr=class xr extends A1{constructor(){super(...arguments),this.overflowing=!1,this.layoutFrame=0}connectedCallback(){this.hasAttribute("role")||this.setAttribute("role","navigation"),this.hasAttribute("aria-label")||this.setAttribute("aria-label","Navigation"),super.connectedCallback(),this.resizeObserver??(this.resizeObserver=new ResizeObserver(()=>this.scheduleLayout())),this.mutationObserver??(this.mutationObserver=new MutationObserver(()=>{this.syncItems(),this.refreshObserved()})),this.mutationObserver.observe(this,{childList:!0,subtree:!0,characterData:!0,attributes:!0}),this.refreshObserved()}disconnectedCallback(){var e,t;super.disconnectedCallback(),this.layoutFrame&&cancelAnimationFrame(this.layoutFrame),this.layoutFrame=0,(e=this.resizeObserver)==null||e.disconnect(),(t=this.mutationObserver)==null||t.disconnect()}willUpdate(e){e.has("defaultValue")&&!this.isControlled&&this.defaultValue&&(this.internalValue=this.defaultValue),(e.has("value")&&this.isControlled||e.has("internalValue"))&&this.scheduleScrollToValue(this.selection)}firstUpdated(){this.refreshObserved()}get items(){return Array.from(this.querySelectorAll(N2)).filter(e=>e.closest("anduin-navigation-bar")===this)}syncItems(){const e=this.items;!this.isControlled&&!this.hasAttribute("default-value")&&!this.internalValue&&e.length&&(this.internalValue=e[0].value);const t=this.selection;for(const o of e)o.barSelected=o.value===t}handleItemClick(e){this.isControlled||(this.setAttribute("default-value",e),this.internalValue=e),P(this,l3,e),this.scheduleScrollToValue(e)}refreshObserved(){const e=this.resizeObserver;if(e){e.disconnect(),e.observe(this),this.viewport&&e.observe(this.viewport);for(const t of this.items)e.observe(t);this.scheduleLayout()}}scheduleLayout(){!this.isConnected||this.layoutFrame||(this.layoutFrame=requestAnimationFrame(()=>{this.layoutFrame=0,this.updateLayout()}))}updateLayout(){const e=this.viewport;if(!e)return;const t=e.scrollWidth>e.clientWidth+k2;t!==this.overflowing&&(this.overflowing=t,t&&this.scheduleScrollToValue(this.selection))}scrollOneItem(e){const t=this.viewport;if(!t)return;const o=this.items,i=t.getBoundingClientRect();let s;if(e){const a=o.findIndex(c=>c.getBoundingClientRect().left>=i.left-k2);s=Math.max(0,a-1)}else{let a=-1;o.forEach((c,u)=>{c.getBoundingClientRect().right<=i.right+k2&&(a=u)}),s=Math.min(o.length-1,a+1)}const r=o[s];r&&this.scrollToItem(r)}scheduleScrollToValue(e){!e||!this.isConnected||requestAnimationFrame(()=>{if(!this.overflowing)return;const t=this.items.find(o=>o.getAttribute("value")===e);t&&this.scrollToItem(t)})}scrollToItem(e){const t=this.viewport;if(!t)return;const o=t.scrollLeft+e.getBoundingClientRect().left-t.getBoundingClientRect().left;t.scrollTo({top:0,left:o,behavior:"smooth"})}renderArrow(e){return d`
5228
5228
  <anduin-button
5229
5229
  appearance="plain"
5230
5230
  size="medium"
@@ -5235,11 +5235,11 @@
5235
5235
  ></anduin-button>
5236
5236
  `}render(){return d`
5237
5237
  <div class="navigation-bar ${this.overflowing?"navigation-bar--overflowing":""}" part="navigation-bar">
5238
- ${this.overflowing?this.renderArrow(!0):g}
5238
+ ${this.overflowing?this.renderArrow(!0):f}
5239
5239
  <div class="navigation-bar__viewport" part="viewport">
5240
5240
  <slot @slotchange=${()=>{this.syncItems(),this.refreshObserved()}}></slot>
5241
5241
  </div>
5242
- ${this.overflowing?this.renderArrow(!1):g}
5242
+ ${this.overflowing?this.renderArrow(!1):f}
5243
5243
  </div>
5244
5244
  `}};xr.styles=p`
5245
5245
  :host {
@@ -5306,14 +5306,14 @@
5306
5306
  @media (prefers-reduced-motion: reduce) {
5307
5307
  .navigation-bar__viewport { scroll-behavior: auto; }
5308
5308
  }
5309
- `;let kt=xr;Xe([b()],kt.prototype,"overflowing");Xe([E(".navigation-bar__viewport")],kt.prototype,"viewport");const Un=class Un extends w1{constructor(){super(...arguments),this.disabled=!1,this.openNewTab=!1,this.selected=null,this.barSelected=!1,this.controlLabel=null}get isSelected(){return this.selected??this.barSelected}updated(){}onControlClick(e){if(this.disabled){e.preventDefault(),e.stopPropagation();return}this.dispatchEvent(new CustomEvent(hi,{detail:this.value,bubbles:!0,composed:!0}))}render(){const e=this.isSelected,t=["navigation-bar-item__control",e?"navigation-bar-item__control--selected":"",this.disabled?"navigation-bar-item__control--disabled":""].filter(Boolean).join(" "),o=d`${this.startIcon?d`<span class="navigation-bar-item__icon" aria-hidden="true"><anduin-icon name="${this.startIcon}" size="16"></anduin-icon></span>`:g}<span class="navigation-bar-item__content"><slot></slot></span>`;return this.href?d`<a
5309
+ `;let kt=xr;Xe([b()],kt.prototype,"overflowing");Xe([E(".navigation-bar__viewport")],kt.prototype,"viewport");const Un=class Un extends w1{constructor(){super(...arguments),this.disabled=!1,this.openNewTab=!1,this.selected=null,this.barSelected=!1,this.controlLabel=null}get isSelected(){return this.selected??this.barSelected}updated(){}onControlClick(e){if(this.disabled){e.preventDefault(),e.stopPropagation();return}this.dispatchEvent(new CustomEvent(hi,{detail:this.value,bubbles:!0,composed:!0}))}render(){const e=this.isSelected,t=["navigation-bar-item__control",e?"navigation-bar-item__control--selected":"",this.disabled?"navigation-bar-item__control--disabled":""].filter(Boolean).join(" "),o=d`${this.startIcon?d`<span class="navigation-bar-item__icon" aria-hidden="true"><anduin-icon name="${this.startIcon}" size="16"></anduin-icon></span>`:f}<span class="navigation-bar-item__content"><slot></slot></span>`;return this.href?d`<a
5310
5310
  class="${t}"
5311
5311
  part="control"
5312
- href="${this.disabled?g:this.href}"
5312
+ href="${this.disabled?f:this.href}"
5313
5313
  target="${this.openNewTab?"_blank":"_self"}"
5314
5314
  rel="${this.openNewTab?"noreferrer noopener":""}"
5315
5315
  tabindex="${this.disabled?-1:0}"
5316
- aria-label="${this.controlLabel||g}"
5316
+ aria-label="${this.controlLabel||f}"
5317
5317
  aria-current="${e?"page":"false"}"
5318
5318
  aria-disabled="${this.disabled?"true":"false"}"
5319
5319
  @click=${this.onControlClick}
@@ -5322,7 +5322,7 @@
5322
5322
  class="${t}"
5323
5323
  part="control"
5324
5324
  ?disabled=${this.disabled}
5325
- aria-label="${this.controlLabel||g}"
5325
+ aria-label="${this.controlLabel||f}"
5326
5326
  aria-current="${e?"page":"false"}"
5327
5327
  aria-disabled="${this.disabled?"true":"false"}"
5328
5328
  @click=${this.onControlClick}
@@ -5410,13 +5410,13 @@
5410
5410
  @media (prefers-reduced-motion: reduce) {
5411
5411
  .navigation-bar-item__control { transition: none; }
5412
5412
  }
5413
- `;let K1=Un;Xe([l({converter:w})],K1.prototype,"disabled");Xe([l({attribute:"open-new-tab",converter:w})],K1.prototype,"openNewTab");Xe([l({attribute:"selected",converter:p9})],K1.prototype,"selected");Xe([l({attribute:!1})],K1.prototype,"barSelected");Xe([l({attribute:"aria-label"})],K1.prototype,"controlLabel");customElements.get("anduin-navigation-bar")||customElements.define("anduin-navigation-bar",kt);customElements.get(N2)||customElements.define(N2,K1);var C9=Object.defineProperty,Ve=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&C9(e,t,i),i};const a3=2e3,d3="anduin-clipboard:copy-request",Bo="anduin-clipboard:state-change";function V5(n){const e=n.trim();return e?`Copy ${e}`:"Copy"}function f9(n){let e=n;for(;e;){const t=e.parentElement??e.getRootNode().host??null;if(t instanceof Element&&t.localName==="anduin-clipboard")return t;e=t}return null}const g9=n=>(n==null?void 0:n.status)??"idle",v9=n=>(n==null?void 0:n.label)??(n==null?void 0:n.getAttribute("label"))??"";class c3{constructor(e,t){this.host=e,this.onChange=t,this.root=null}connect(){var e;this.root=f9(this.host),(e=this.root)==null||e.addEventListener(Bo,this.onChange),this.onChange()}disconnect(){var e;(e=this.root)==null||e.removeEventListener(Bo,this.onChange),this.root=null}get status(){return g9(this.root)}get label(){return v9(this.root)}}const wr=class wr extends C{constructor(){super(),this.value="",this.label="",this._status="idle",this._announcement="",this._resetTimer=0,this.addEventListener(d3,e=>{e.stopPropagation(),this.copy()})}get status(){return this._status}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this._resetTimer)}async copy(){this._setStatus("copied"),clearTimeout(this._resetTimer),this._resetTimer=window.setTimeout(()=>{this._announcement="",this._setStatus("idle")},a3);const e=this.value;e&&this._reportOutcome(await this._write(e))}async _write(e){const t=navigator.clipboard;if(t!=null&&t.writeText)try{return await t.writeText(e),!0}catch{return!1}return this._copyByExecCommand(e)}_copyByExecCommand(e){const t=document.createElement("textarea");t.value=e,t.style.cssText="position:fixed;left:-9999px;opacity:0",document.body.appendChild(t),t.select();let o=!1;try{o=document.execCommand("copy")}catch{o=!1}return t.remove(),o}_reportOutcome(e){const t=this.label.trim();e?this._announcement=t?`${t} copied to clipboard`:"Copied to clipboard":(this._setStatus("failed"),this._announcement=t?`Could not copy ${t} to clipboard`:"Could not copy to clipboard")}_setStatus(e){this._status!==e&&(this._status=e,this.dispatchEvent(new CustomEvent(Bo)))}updated(e){e.has("label")&&this.dispatchEvent(new CustomEvent(Bo))}render(){return d`<slot></slot><div class="announcement" part="announcement" aria-live="polite" aria-atomic="true">${this._announcement}</div>`}};wr.styles=p`
5413
+ `;let K1=Un;Xe([l({converter:w})],K1.prototype,"disabled");Xe([l({attribute:"open-new-tab",converter:w})],K1.prototype,"openNewTab");Xe([l({attribute:"selected",converter:p9})],K1.prototype,"selected");Xe([l({attribute:!1})],K1.prototype,"barSelected");Xe([l({attribute:"aria-label"})],K1.prototype,"controlLabel");customElements.get("anduin-navigation-bar")||customElements.define("anduin-navigation-bar",kt);customElements.get(N2)||customElements.define(N2,K1);var C9=Object.defineProperty,Ve=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&C9(e,t,i),i};const a3=2e3,d3="anduin-clipboard:copy-request",Bo="anduin-clipboard:state-change";function V5(n){const e=n.trim();return e?`Copy ${e}`:"Copy"}function g9(n){let e=n;for(;e;){const t=e.parentElement??e.getRootNode().host??null;if(t instanceof Element&&t.localName==="anduin-clipboard")return t;e=t}return null}const f9=n=>(n==null?void 0:n.status)??"idle",v9=n=>(n==null?void 0:n.label)??(n==null?void 0:n.getAttribute("label"))??"";class c3{constructor(e,t){this.host=e,this.onChange=t,this.root=null}connect(){var e;this.root=g9(this.host),(e=this.root)==null||e.addEventListener(Bo,this.onChange),this.onChange()}disconnect(){var e;(e=this.root)==null||e.removeEventListener(Bo,this.onChange),this.root=null}get status(){return f9(this.root)}get label(){return v9(this.root)}}const wr=class wr extends C{constructor(){super(),this.value="",this.label="",this._status="idle",this._announcement="",this._resetTimer=0,this.addEventListener(d3,e=>{e.stopPropagation(),this.copy()})}get status(){return this._status}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this._resetTimer)}async copy(){this._setStatus("copied"),clearTimeout(this._resetTimer),this._resetTimer=window.setTimeout(()=>{this._announcement="",this._setStatus("idle")},a3);const e=this.value;e&&this._reportOutcome(await this._write(e))}async _write(e){const t=navigator.clipboard;if(t!=null&&t.writeText)try{return await t.writeText(e),!0}catch{return!1}return this._copyByExecCommand(e)}_copyByExecCommand(e){const t=document.createElement("textarea");t.value=e,t.style.cssText="position:fixed;left:-9999px;opacity:0",document.body.appendChild(t),t.select();let o=!1;try{o=document.execCommand("copy")}catch{o=!1}return t.remove(),o}_reportOutcome(e){const t=this.label.trim();e?this._announcement=t?`${t} copied to clipboard`:"Copied to clipboard":(this._setStatus("failed"),this._announcement=t?`Could not copy ${t} to clipboard`:"Could not copy to clipboard")}_setStatus(e){this._status!==e&&(this._status=e,this.dispatchEvent(new CustomEvent(Bo)))}updated(e){e.has("label")&&this.dispatchEvent(new CustomEvent(Bo))}render(){return d`<slot></slot><div class="announcement" part="announcement" aria-live="polite" aria-atomic="true">${this._announcement}</div>`}};wr.styles=p`
5414
5414
  :host { display: contents; }
5415
5415
  .announcement {
5416
5416
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
5417
5417
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
5418
5418
  }
5419
- `;let ge=wr;Ve([l()],ge.prototype,"value");Ve([l()],ge.prototype,"label");Ve([b()],ge.prototype,"_status");Ve([b()],ge.prototype,"_announcement");function h3(n){return n==="copied"?"✓ Copied to clipboard":n==="failed"?"Copy failed":"Click to copy"}const V2="data-clipboard-named",Hr=class Hr extends C{constructor(){super(),this._status="idle",this._hovered=!1,this._link=new c3(this,()=>this._onRootChange()),this._onClick=()=>{this.dispatchEvent(new CustomEvent(d3,{bubbles:!0,composed:!0}))},this.addEventListener("click",this._onClick),this.addEventListener("pointerenter",()=>this._hovered=!0),this.addEventListener("pointerleave",()=>{this._hovered=!1,this._tooltip("hide")}),this.addEventListener("focusout",()=>{this._hovered||this._tooltip("hide")})}connectedCallback(){super.connectedCallback(),this._link.connect()}disconnectedCallback(){super.disconnectedCallback(),this._link.disconnect()}_onRootChange(){const e=this._status;this._status=this._link.status,this._status!==e&&(this._status!=="idle"?this._tooltip("show"):this._hovered||this._tooltip("hide")),this._nameControl()}_tooltip(e){var o;const t=(o=this.shadowRoot)==null?void 0:o.querySelector("anduin-tooltip-trigger");t==null||t.dispatchEvent(new CustomEvent(e==="show"?Ot:Tt,{bubbles:!0,composed:!0}))}_nameControl(){var r;const e=this.firstElementChild;if(!e)return;const t=e.localName.includes("-")?"label":"aria-label",o=e.hasAttribute(V2),i=!o&&(e.hasAttribute("aria-label")||!!e.getAttribute("label")),s=!!((r=e.textContent)!=null&&r.trim());if(!i){if(s){o&&(e.removeAttribute(t),e.removeAttribute(V2));return}e.setAttribute(t,V5(this._link.label)),e.setAttribute(V2,"")}}render(){return d`
5419
+ `;let fe=wr;Ve([l()],fe.prototype,"value");Ve([l()],fe.prototype,"label");Ve([b()],fe.prototype,"_status");Ve([b()],fe.prototype,"_announcement");function h3(n){return n==="copied"?"✓ Copied to clipboard":n==="failed"?"Copy failed":"Click to copy"}const V2="data-clipboard-named",Hr=class Hr extends C{constructor(){super(),this._status="idle",this._hovered=!1,this._link=new c3(this,()=>this._onRootChange()),this._onClick=()=>{this.dispatchEvent(new CustomEvent(d3,{bubbles:!0,composed:!0}))},this.addEventListener("click",this._onClick),this.addEventListener("pointerenter",()=>this._hovered=!0),this.addEventListener("pointerleave",()=>{this._hovered=!1,this._tooltip("hide")}),this.addEventListener("focusout",()=>{this._hovered||this._tooltip("hide")})}connectedCallback(){super.connectedCallback(),this._link.connect()}disconnectedCallback(){super.disconnectedCallback(),this._link.disconnect()}_onRootChange(){const e=this._status;this._status=this._link.status,this._status!==e&&(this._status!=="idle"?this._tooltip("show"):this._hovered||this._tooltip("hide")),this._nameControl()}_tooltip(e){var o;const t=(o=this.shadowRoot)==null?void 0:o.querySelector("anduin-tooltip-trigger");t==null||t.dispatchEvent(new CustomEvent(e==="show"?Ot:Tt,{bubbles:!0,composed:!0}))}_nameControl(){var r;const e=this.firstElementChild;if(!e)return;const t=e.localName.includes("-")?"label":"aria-label",o=e.hasAttribute(V2),i=!o&&(e.hasAttribute("aria-label")||!!e.getAttribute("label")),s=!!((r=e.textContent)!=null&&r.trim());if(!i){if(s){o&&(e.removeAttribute(t),e.removeAttribute(V2));return}e.setAttribute(t,V5(this._link.label)),e.setAttribute(V2,"")}}render(){return d`
5420
5420
  <anduin-tooltip placement="top-center">
5421
5421
  <anduin-tooltip-trigger><slot @slotchange=${()=>this._nameControl()}></slot></anduin-tooltip-trigger>
5422
5422
  <anduin-tooltip-content>${h3(this._status)}</anduin-tooltip-content>
@@ -5458,19 +5458,19 @@
5458
5458
  .button--text .icon--out { position: absolute; }
5459
5459
  .icon--in { opacity: 1; transform: scale(1); }
5460
5460
  .icon--out { opacity: 0; transform: scale(0.5); }
5461
- `;let Ne=Lr;Ve([l()],Ne.prototype,"appearance");Ve([b()],Ne.prototype,"_copied");Ve([b()],Ne.prototype,"_label");customElements.get("anduin-clipboard")||customElements.define("anduin-clipboard",ge);customElements.get("anduin-clipboard-trigger")||customElements.define("anduin-clipboard-trigger",vi);customElements.get("anduin-clipboard-indicator")||customElements.define("anduin-clipboard-indicator",Ne);var m9=Object.defineProperty,b9=Object.getOwnPropertyDescriptor,It=(n,e,t,o)=>{for(var i=o>1?void 0:o?b9(e,t):e,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=(o?r(e,t,i):r(i))||i);return o&&i&&m9(e,t,i),i};const u3="anduin-collapsible-open-change",U2="anduin-collapsible:state-change",p3=150;function C3(n){const e=(n??"").trim();if(e==="off")return 0;if(e.endsWith("ms")){const t=Number(e.slice(0,-2).trim());if(e.slice(0,-2).trim()!==""&&Number.isFinite(t)&&t>=0)return t}return p3}let _9=0;const kr=class kr extends C{constructor(){super(...arguments),this._open=!1,this._controlled=!1,this.defaultOpen=!1,this.disabled=!1,this.direction="vertical",this.animation="",this.contentId=`anduin-collapsible-content-${++_9}`,this._uncontrolledOpen=null}get open(){return this._open}set open(e){const t=this._open;this._open=e,this._controlled=!0,this.requestUpdate("open",t)}get isControlled(){return this._controlled||this.hasAttribute("open")}get isOpen(){return this.isControlled?this._open:this._uncontrolledOpen??this.defaultOpen}get isHorizontal(){return this.direction==="horizontal"}get animationDuration(){return C3(this.animation)}toggle(){if(this.disabled)return;const e=!this.isOpen;this.isControlled||(this._uncontrolledOpen=e,this._broadcast()),this.dispatchEvent(new CustomEvent(u3,{detail:{value:e},bubbles:!1,composed:!1}))}updated(){this._broadcast()}_broadcast(){this.dispatchEvent(new CustomEvent(U2))}render(){return d`<slot></slot>`}};kr.styles=p`:host { display: contents; }`;let j1=kr;It([l({converter:w})],j1.prototype,"open",1);It([l({attribute:"default-open",converter:w})],j1.prototype,"defaultOpen",2);It([l({converter:w,reflect:!0})],j1.prototype,"disabled",2);It([l()],j1.prototype,"direction",2);It([l()],j1.prototype,"animation",2);class E5{constructor(e,t){this.host=e,this.onChange=t,this.root=null}connect(){var e;this.root=this.host.closest("anduin-collapsible"),(e=this.root)==null||e.addEventListener(U2,this.onChange),this.root&&this.onChange()}disconnect(){var e;(e=this.root)==null||e.removeEventListener(U2,this.onChange),this.root=null}get isOpen(){var e;return((e=this.root)==null?void 0:e.isOpen)??!1}}const y9="button, a[href], input, select, textarea, summary, [role], [tabindex], [contenteditable]",x9="button, a[href], input, select, textarea, summary, [tabindex], [contenteditable], anduin-button, anduin-checkbox, anduin-radio, anduin-switch",fa=["aria-expanded","aria-controls","aria-disabled"];function w9(n){var e;return n.localName.includes("-")?"host":n.matches(y9)?"control":n.querySelector(x9)||!((e=n.textContent)!=null&&e.trim())&&!n.hasAttribute("aria-label")?"bare":"made-button"}function H9(n){return n==="host"?["control-expanded"]:n==="made-button"?[...fa,"role","tabindex"]:n==="control"?fa:[]}const Vr=class Vr extends C{constructor(){super(),this._link=new E5(this,()=>this._sync()),this._synced=null,this._onKeyDown=e=>{var t,o;e.key!=="Enter"&&e.key!==" "||((t=this._synced)==null?void 0:t.kind)!=="made-button"||e.target!==this._synced.el||(e.preventDefault(),(o=this._link.root)==null||o.toggle())},this.addEventListener("click",()=>{var e;return(e=this._link.root)==null?void 0:e.toggle()}),this.addEventListener("keydown",this._onKeyDown)}connectedCallback(){super.connectedCallback(),this.setAttribute("aria-expanded","false"),this._link.connect()}disconnectedCallback(){super.disconnectedCallback(),this._link.disconnect()}_sync(){var c;const e=this._link.root;if(!e)return;const t=e.isOpen,o=e.disabled;this.setAttribute("aria-expanded",String(t)),this.setAttribute("aria-controls",e.contentId),o?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled");const i=this.firstElementChild;if(i!==(((c=this._synced)==null?void 0:c.el)??null)){if(this._synced)for(const u of H9(this._synced.kind))this._synced.el.removeAttribute(u);this._synced=i?{el:i,kind:w9(i)}:null}if(!this._synced)return;const{el:s,kind:r}=this._synced,a=(u,h)=>h===null?s.removeAttribute(u):s.setAttribute(u,h);r==="host"?(a("control-expanded",String(t)),this._relayIntoButton(s,t)):(r==="control"||r==="made-button")&&(a("aria-expanded",String(t)),a("aria-controls",e.contentId),a("aria-disabled",o?"true":null),r==="made-button"&&(a("role","button"),a("tabindex",o?"-1":"0")))}_relayIntoButton(e,t){var i;if(e.localName!=="anduin-button")return;const o=()=>{var s,r;return(r=(s=e.shadowRoot)==null?void 0:s.querySelector("button, a"))==null?void 0:r.setAttribute("aria-expanded",String(t))};o(),(i=e.updateComplete)==null||i.then(o)}render(){return d`<slot @slotchange=${()=>this._sync()}></slot>`}};Vr.styles=p`:host { display: contents; }`;let No=Vr;const Er=class Er extends C{constructor(){super(...arguments),this._link=new E5(this,()=>this._onState()),this._el=null,this._shown=null}connectedCallback(){super.connectedCallback(),this._link.connect()}disconnectedCallback(){super.disconnectedCallback(),this._link.disconnect()}firstUpdated(){this._el=this.renderRoot.querySelector(".content"),this._onState()}_onState(){const e=this._link.root;if(!e)return;this.id!==e.contentId&&(this.id=e.contentId);const t=this._el;if(!t)return;t.classList.toggle("content--horizontal",e.isHorizontal);const o=e.isOpen;if(o===this._shown)return;const i=this._shown===null;this._shown=o,t.getAnimations().forEach(h=>h.cancel());const s=e.animationDuration;if(i||s<=0){t.style.display=o?"block":"none",t.style.overflow="",t.style.height="",t.style.width="";return}const r=e.isHorizontal?"width":"height";t.style.display="block",t.style.overflow="hidden";const a=`${e.isHorizontal?t.scrollWidth:t.scrollHeight}px`,c=o?[{[r]:"0px"},{[r]:a}]:[{[r]:a},{[r]:"0px"}],u=t.animate(c,{duration:s,easing:"ease-out",fill:o?"none":"forwards"});u.addEventListener("finish",()=>{o||(t.style.display="none"),t.style.overflow="",t.style.height="",t.style.width="",o||u.cancel()})}render(){return d`<div class="content" part="content"><slot></slot></div>`}};Er.styles=p`
5461
+ `;let Ne=Lr;Ve([l()],Ne.prototype,"appearance");Ve([b()],Ne.prototype,"_copied");Ve([b()],Ne.prototype,"_label");customElements.get("anduin-clipboard")||customElements.define("anduin-clipboard",fe);customElements.get("anduin-clipboard-trigger")||customElements.define("anduin-clipboard-trigger",vi);customElements.get("anduin-clipboard-indicator")||customElements.define("anduin-clipboard-indicator",Ne);var m9=Object.defineProperty,b9=Object.getOwnPropertyDescriptor,It=(n,e,t,o)=>{for(var i=o>1?void 0:o?b9(e,t):e,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=(o?r(e,t,i):r(i))||i);return o&&i&&m9(e,t,i),i};const u3="anduin-collapsible-open-change",U2="anduin-collapsible:state-change",p3=150;function C3(n){const e=(n??"").trim();if(e==="off")return 0;if(e.endsWith("ms")){const t=Number(e.slice(0,-2).trim());if(e.slice(0,-2).trim()!==""&&Number.isFinite(t)&&t>=0)return t}return p3}let _9=0;const kr=class kr extends C{constructor(){super(...arguments),this._open=!1,this._controlled=!1,this.defaultOpen=!1,this.disabled=!1,this.direction="vertical",this.animation="",this.contentId=`anduin-collapsible-content-${++_9}`,this._uncontrolledOpen=null}get open(){return this._open}set open(e){const t=this._open;this._open=e,this._controlled=!0,this.requestUpdate("open",t)}get isControlled(){return this._controlled||this.hasAttribute("open")}get isOpen(){return this.isControlled?this._open:this._uncontrolledOpen??this.defaultOpen}get isHorizontal(){return this.direction==="horizontal"}get animationDuration(){return C3(this.animation)}toggle(){if(this.disabled)return;const e=!this.isOpen;this.isControlled||(this._uncontrolledOpen=e,this._broadcast()),this.dispatchEvent(new CustomEvent(u3,{detail:{value:e},bubbles:!1,composed:!1}))}updated(){this._broadcast()}_broadcast(){this.dispatchEvent(new CustomEvent(U2))}render(){return d`<slot></slot>`}};kr.styles=p`:host { display: contents; }`;let j1=kr;It([l({converter:w})],j1.prototype,"open",1);It([l({attribute:"default-open",converter:w})],j1.prototype,"defaultOpen",2);It([l({converter:w,reflect:!0})],j1.prototype,"disabled",2);It([l()],j1.prototype,"direction",2);It([l()],j1.prototype,"animation",2);class E5{constructor(e,t){this.host=e,this.onChange=t,this.root=null}connect(){var e;this.root=this.host.closest("anduin-collapsible"),(e=this.root)==null||e.addEventListener(U2,this.onChange),this.root&&this.onChange()}disconnect(){var e;(e=this.root)==null||e.removeEventListener(U2,this.onChange),this.root=null}get isOpen(){var e;return((e=this.root)==null?void 0:e.isOpen)??!1}}const y9="button, a[href], input, select, textarea, summary, [role], [tabindex], [contenteditable]",x9="button, a[href], input, select, textarea, summary, [tabindex], [contenteditable], anduin-button, anduin-checkbox, anduin-radio, anduin-switch",ga=["aria-expanded","aria-controls","aria-disabled"];function w9(n){var e;return n.localName.includes("-")?"host":n.matches(y9)?"control":n.querySelector(x9)||!((e=n.textContent)!=null&&e.trim())&&!n.hasAttribute("aria-label")?"bare":"made-button"}function H9(n){return n==="host"?["control-expanded"]:n==="made-button"?[...ga,"role","tabindex"]:n==="control"?ga:[]}const Vr=class Vr extends C{constructor(){super(),this._link=new E5(this,()=>this._sync()),this._synced=null,this._onKeyDown=e=>{var t,o;e.key!=="Enter"&&e.key!==" "||((t=this._synced)==null?void 0:t.kind)!=="made-button"||e.target!==this._synced.el||(e.preventDefault(),(o=this._link.root)==null||o.toggle())},this.addEventListener("click",()=>{var e;return(e=this._link.root)==null?void 0:e.toggle()}),this.addEventListener("keydown",this._onKeyDown)}connectedCallback(){super.connectedCallback(),this.setAttribute("aria-expanded","false"),this._link.connect()}disconnectedCallback(){super.disconnectedCallback(),this._link.disconnect()}_sync(){var c;const e=this._link.root;if(!e)return;const t=e.isOpen,o=e.disabled;this.setAttribute("aria-expanded",String(t)),this.setAttribute("aria-controls",e.contentId),o?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled");const i=this.firstElementChild;if(i!==(((c=this._synced)==null?void 0:c.el)??null)){if(this._synced)for(const u of H9(this._synced.kind))this._synced.el.removeAttribute(u);this._synced=i?{el:i,kind:w9(i)}:null}if(!this._synced)return;const{el:s,kind:r}=this._synced,a=(u,h)=>h===null?s.removeAttribute(u):s.setAttribute(u,h);r==="host"?(a("control-expanded",String(t)),this._relayIntoButton(s,t)):(r==="control"||r==="made-button")&&(a("aria-expanded",String(t)),a("aria-controls",e.contentId),a("aria-disabled",o?"true":null),r==="made-button"&&(a("role","button"),a("tabindex",o?"-1":"0")))}_relayIntoButton(e,t){var i;if(e.localName!=="anduin-button")return;const o=()=>{var s,r;return(r=(s=e.shadowRoot)==null?void 0:s.querySelector("button, a"))==null?void 0:r.setAttribute("aria-expanded",String(t))};o(),(i=e.updateComplete)==null||i.then(o)}render(){return d`<slot @slotchange=${()=>this._sync()}></slot>`}};Vr.styles=p`:host { display: contents; }`;let No=Vr;const Er=class Er extends C{constructor(){super(...arguments),this._link=new E5(this,()=>this._onState()),this._el=null,this._shown=null}connectedCallback(){super.connectedCallback(),this._link.connect()}disconnectedCallback(){super.disconnectedCallback(),this._link.disconnect()}firstUpdated(){this._el=this.renderRoot.querySelector(".content"),this._onState()}_onState(){const e=this._link.root;if(!e)return;this.id!==e.contentId&&(this.id=e.contentId);const t=this._el;if(!t)return;t.classList.toggle("content--horizontal",e.isHorizontal);const o=e.isOpen;if(o===this._shown)return;const i=this._shown===null;this._shown=o,t.getAnimations().forEach(h=>h.cancel());const s=e.animationDuration;if(i||s<=0){t.style.display=o?"block":"none",t.style.overflow="",t.style.height="",t.style.width="";return}const r=e.isHorizontal?"width":"height";t.style.display="block",t.style.overflow="hidden";const a=`${e.isHorizontal?t.scrollWidth:t.scrollHeight}px`,c=o?[{[r]:"0px"},{[r]:a}]:[{[r]:a},{[r]:"0px"}],u=t.animate(c,{duration:s,easing:"ease-out",fill:o?"none":"forwards"});u.addEventListener("finish",()=>{o||(t.style.display="none"),t.style.overflow="",t.style.height="",t.style.width="",o||u.cancel()})}render(){return d`<div class="content" part="content"><slot></slot></div>`}};Er.styles=p`
5462
5462
  :host { display: block; }
5463
5463
  .content { display: none; }
5464
5464
  .content--horizontal { height: 100%; }
5465
5465
  `;let Uo=Er;const Mr=class Mr extends C{constructor(){super(...arguments),this.rotation=90,this._link=new E5(this,()=>this._onState()),this._el=null,this._shown=null}get _openAngle(){const e=Number(String(this.rotation).trim());return`${String(this.rotation).trim()!==""&&Number.isInteger(e)?e:90}deg`}connectedCallback(){super.connectedCallback(),this._link.connect()}disconnectedCallback(){super.disconnectedCallback(),this._link.disconnect()}firstUpdated(){this._el=this.renderRoot.querySelector(".icon"),this._onState()}updated(e){e.has("rotation")&&this._el&&this._shown!==null&&(this._el.getAnimations().forEach(t=>t.cancel()),this._rest(this._shown))}_rest(e){e?this._el.style.setProperty("rotate",this._openAngle):this._el.style.removeProperty("rotate")}_onState(){const e=this._link.root,t=this._el;if(!e||!t)return;const o=e.isOpen;if(o===this._shown)return;const i=this._shown===null;this._shown=o,t.getAnimations().forEach(c=>c.cancel());const s=e.animationDuration;if(i||s<=0){this._rest(o);return}t.style.removeProperty("rotate");const r=this._openAngle,a=o?[{rotate:"0deg"},{rotate:r}]:[{rotate:r},{rotate:"0deg"}];t.animate(a,{duration:s,easing:"ease-out",fill:"forwards"})}render(){return d`<div class="icon" part="icon"><slot></slot></div>`}};Mr.styles=p`
5466
5466
  :host { display: contents; }
5467
5467
  .icon { display: block; }
5468
- `;let mi=Mr;It([l()],mi.prototype,"rotation",2);customElements.get("anduin-collapsible")||customElements.define("anduin-collapsible",j1);customElements.get("anduin-collapsible-trigger")||customElements.define("anduin-collapsible-trigger",No);customElements.get("anduin-collapsible-content")||customElements.define("anduin-collapsible-content",Uo);customElements.get("anduin-collapsible-icon")||customElements.define("anduin-collapsible-icon",mi);var L9=Object.defineProperty,h2=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&L9(e,t,i),i};function f3(n){const e=Number(n);return Number.isInteger(e)&&e>=1?e:1}const $r=class $r extends C{constructor(){super(...arguments),this.lineClamp=null,this.tooltip=null,this._tooltipRendered=!1,this._tooltipText="",this._describedTarget=null,this._requestId=0,this._onEnter=async e=>{var a;const t=++this._requestId,o=this.target;if(!o||this._isInsideTooltipTrigger(e)||!this.isTruncated){this._hide(!0);return}const i=this.getAttribute("tooltip")??this._normalizedText;this._tooltipText=i,this._tooltipRendered=!0,this._describe(o,i),await this.updateComplete;const s=(a=this.shadowRoot)==null?void 0:a.querySelector("anduin-tooltip"),r=s==null?void 0:s.querySelector("anduin-tooltip-content");!s||!r||(await Promise.all([s.updateComplete,r.updateComplete]),this._requestId===t&&(s.dispatchEvent(new CustomEvent(l2,{detail:o})),s.dispatchEvent(new CustomEvent(Ot))))},this._onLeave=()=>this._hide(),this._onFocusOut=e=>{const t=e.relatedTarget;t&&this.contains(t)||this._hide()},this._onKeyDown=e=>{e.key==="Escape"&&this._hide()}}connectedCallback(){super.connectedCallback(),this.addEventListener("pointerenter",this._onEnter),this.addEventListener("focusin",this._onEnter),this.addEventListener("pointerleave",this._onLeave),this.addEventListener("focusout",this._onFocusOut),this.addEventListener("keydown",this._onKeyDown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("pointerenter",this._onEnter),this.removeEventListener("focusin",this._onEnter),this.removeEventListener("pointerleave",this._onLeave),this.removeEventListener("focusout",this._onFocusOut),this.removeEventListener("keydown",this._onKeyDown),this._clearDescription(),this._tooltipRendered=!1}get target(){var o;const e=(o=this.shadowRoot)==null?void 0:o.querySelector("slot"),t=e?e.assignedElements():Array.from(this.children);return t.length===1&&t[0]instanceof HTMLElement?t[0]:null}get isTruncated(){const e=this.target;return e?this.hasAttribute("line-clamp")?e.offsetHeight<e.scrollHeight:e.offsetWidth<e.scrollWidth:!1}get _normalizedText(){return(this.textContent??"").trim().replace(/\s+/g," ")}_isInsideTooltipTrigger(e){const t=e.composedPath(),o=t.indexOf(this);return t.slice(o+1).some(i=>i instanceof Element&&i.matches("anduin-tooltip-trigger"))}_hide(e=!1){var o;this._requestId++;const t=(o=this.shadowRoot)==null?void 0:o.querySelector("anduin-tooltip");t==null||t.dispatchEvent(new CustomEvent(Tt)),e&&this._tooltipRendered&&(this._tooltipRendered=!1,this._clearDescription())}_describe(e,t){this._clearDescription(),!(!t||t===this._normalizedText)&&(e.setAttribute("aria-description",t),this._describedTarget=e)}_clearDescription(){var e;(e=this._describedTarget)==null||e.removeAttribute("aria-description"),this._describedTarget=null}render(){const e=this.lineClamp===null?"":`--anduin-truncated-line-clamp: ${f3(this.lineClamp)}`;return d`
5468
+ `;let mi=Mr;It([l()],mi.prototype,"rotation",2);customElements.get("anduin-collapsible")||customElements.define("anduin-collapsible",j1);customElements.get("anduin-collapsible-trigger")||customElements.define("anduin-collapsible-trigger",No);customElements.get("anduin-collapsible-content")||customElements.define("anduin-collapsible-content",Uo);customElements.get("anduin-collapsible-icon")||customElements.define("anduin-collapsible-icon",mi);var L9=Object.defineProperty,h2=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&L9(e,t,i),i};function g3(n){const e=Number(n);return Number.isInteger(e)&&e>=1?e:1}const $r=class $r extends C{constructor(){super(...arguments),this.lineClamp=null,this.tooltip=null,this._tooltipRendered=!1,this._tooltipText="",this._describedTarget=null,this._requestId=0,this._onEnter=async e=>{var a;const t=++this._requestId,o=this.target;if(!o||this._isInsideTooltipTrigger(e)||!this.isTruncated){this._hide(!0);return}const i=this.getAttribute("tooltip")??this._normalizedText;this._tooltipText=i,this._tooltipRendered=!0,this._describe(o,i),await this.updateComplete;const s=(a=this.shadowRoot)==null?void 0:a.querySelector("anduin-tooltip"),r=s==null?void 0:s.querySelector("anduin-tooltip-content");!s||!r||(await Promise.all([s.updateComplete,r.updateComplete]),this._requestId===t&&(s.dispatchEvent(new CustomEvent(l2,{detail:o})),s.dispatchEvent(new CustomEvent(Ot))))},this._onLeave=()=>this._hide(),this._onFocusOut=e=>{const t=e.relatedTarget;t&&this.contains(t)||this._hide()},this._onKeyDown=e=>{e.key==="Escape"&&this._hide()}}connectedCallback(){super.connectedCallback(),this.addEventListener("pointerenter",this._onEnter),this.addEventListener("focusin",this._onEnter),this.addEventListener("pointerleave",this._onLeave),this.addEventListener("focusout",this._onFocusOut),this.addEventListener("keydown",this._onKeyDown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("pointerenter",this._onEnter),this.removeEventListener("focusin",this._onEnter),this.removeEventListener("pointerleave",this._onLeave),this.removeEventListener("focusout",this._onFocusOut),this.removeEventListener("keydown",this._onKeyDown),this._clearDescription(),this._tooltipRendered=!1}get target(){var o;const e=(o=this.shadowRoot)==null?void 0:o.querySelector("slot"),t=e?e.assignedElements():Array.from(this.children);return t.length===1&&t[0]instanceof HTMLElement?t[0]:null}get isTruncated(){const e=this.target;return e?this.hasAttribute("line-clamp")?e.offsetHeight<e.scrollHeight:e.offsetWidth<e.scrollWidth:!1}get _normalizedText(){return(this.textContent??"").trim().replace(/\s+/g," ")}_isInsideTooltipTrigger(e){const t=e.composedPath(),o=t.indexOf(this);return t.slice(o+1).some(i=>i instanceof Element&&i.matches("anduin-tooltip-trigger"))}_hide(e=!1){var o;this._requestId++;const t=(o=this.shadowRoot)==null?void 0:o.querySelector("anduin-tooltip");t==null||t.dispatchEvent(new CustomEvent(Tt)),e&&this._tooltipRendered&&(this._tooltipRendered=!1,this._clearDescription())}_describe(e,t){this._clearDescription(),!(!t||t===this._normalizedText)&&(e.setAttribute("aria-description",t),this._describedTarget=e)}_clearDescription(){var e;(e=this._describedTarget)==null||e.removeAttribute("aria-description"),this._describedTarget=null}render(){const e=this.lineClamp===null?"":`--anduin-truncated-line-clamp: ${g3(this.lineClamp)}`;return d`
5469
5469
  <div class="truncated-root" part="root" style=${e}>
5470
5470
  <slot></slot>
5471
5471
  ${this._tooltipRendered?d`<anduin-tooltip placement="top-center"
5472
5472
  ><anduin-tooltip-content>${this._tooltipText}</anduin-tooltip-content></anduin-tooltip
5473
- >`:g}
5473
+ >`:f}
5474
5474
  </div>
5475
5475
  `}};$r.styles=p`
5476
5476
  :host,
@@ -5541,7 +5541,7 @@
5541
5541
  :host([hidden]) {
5542
5542
  display: none;
5543
5543
  }
5544
- `;let qo=Rr;const g3=2;function v3(n){const e=Number(n);return Number.isInteger(e)&&e>=1&&e<=6?e:g3}const Ar=class Ar extends C{constructor(){super(...arguments),this.headingLevel=null}render(){return d`<div role="heading" aria-level=${v3(this.headingLevel??g3)} part="heading"><slot></slot></div>`}};Ar.styles=p`
5544
+ `;let qo=Rr;const f3=2;function v3(n){const e=Number(n);return Number.isInteger(e)&&e>=1&&e<=6?e:f3}const Ar=class Ar extends C{constructor(){super(...arguments),this.headingLevel=null}render(){return d`<div role="heading" aria-level=${v3(this.headingLevel??f3)} part="heading"><slot></slot></div>`}};Ar.styles=p`
5545
5545
  :host {
5546
5546
  display: block;
5547
5547
  color: var(--color-foreground);
@@ -5569,7 +5569,7 @@
5569
5569
  :host([hidden]) {
5570
5570
  display: none;
5571
5571
  }
5572
- `;let jo=Or;customElements.get("anduin-non-ideal-state")||customElements.define("anduin-non-ideal-state",Go);customElements.get("anduin-non-ideal-state-icon")||customElements.define("anduin-non-ideal-state-icon",qo);customElements.get("anduin-non-ideal-state-title")||customElements.define("anduin-non-ideal-state-title",bi);customElements.get("anduin-non-ideal-state-description")||customElements.define("anduin-non-ideal-state-description",Ko);customElements.get("anduin-non-ideal-state-action")||customElements.define("anduin-non-ideal-state-action",jo);var E9=Object.defineProperty,Je=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&E9(e,t,i),i};const M9={idle:"Click to copy",copied:"✓ Copied to clipboard",failed:"Copy failed"},$9=2e3;async function Z9(n){var o;try{if((o=navigator.clipboard)!=null&&o.writeText)return await navigator.clipboard.writeText(n),!0}catch{return!1}const e=document.createElement("textarea");e.value=n,e.style.cssText="position:fixed;left:-9999px;opacity:0",document.body.appendChild(e),e.select();let t=!1;try{t=document.execCommand("copy")}catch{t=!1}return e.remove(),t}const Tr=class Tr extends C{constructor(){super(...arguments),this.uid="",this.value="",this.email="",this.shape="",this.size="",this._copyStatus="idle",this._announcement="",this._resetTimer=0}disconnectedCallback(){super.disconnectedCallback(),window.clearTimeout(this._resetTimer)}async copyEmail(){var t,o;if(!this.email)return!1;this._copyStatus="copied";const e=await Z9(this.email);return this._copyStatus=e?"copied":"failed",this._announcement=e?"Copied to clipboard":"Could not copy to clipboard",window.clearTimeout(this._resetTimer),this._resetTimer=window.setTimeout(()=>{this._copyStatus="idle",this._announcement=""},$9),await this.updateComplete,(o=(t=this.shadowRoot)==null?void 0:t.querySelector("anduin-tooltip-trigger"))==null||o.dispatchEvent(new CustomEvent(Ot,{bubbles:!0,composed:!0})),e}_renderEmail(){if(!this.email)return g;const e=this._copyStatus==="copied";return d`
5572
+ `;let jo=Or;customElements.get("anduin-non-ideal-state")||customElements.define("anduin-non-ideal-state",Go);customElements.get("anduin-non-ideal-state-icon")||customElements.define("anduin-non-ideal-state-icon",qo);customElements.get("anduin-non-ideal-state-title")||customElements.define("anduin-non-ideal-state-title",bi);customElements.get("anduin-non-ideal-state-description")||customElements.define("anduin-non-ideal-state-description",Ko);customElements.get("anduin-non-ideal-state-action")||customElements.define("anduin-non-ideal-state-action",jo);var E9=Object.defineProperty,Je=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&E9(e,t,i),i};const M9={idle:"Click to copy",copied:"✓ Copied to clipboard",failed:"Copy failed"},$9=2e3;async function Z9(n){var o;try{if((o=navigator.clipboard)!=null&&o.writeText)return await navigator.clipboard.writeText(n),!0}catch{return!1}const e=document.createElement("textarea");e.value=n,e.style.cssText="position:fixed;left:-9999px;opacity:0",document.body.appendChild(e),e.select();let t=!1;try{t=document.execCommand("copy")}catch{t=!1}return e.remove(),t}const Tr=class Tr extends C{constructor(){super(...arguments),this.uid="",this.value="",this.email="",this.shape="",this.size="",this._copyStatus="idle",this._announcement="",this._resetTimer=0}disconnectedCallback(){super.disconnectedCallback(),window.clearTimeout(this._resetTimer)}async copyEmail(){var t,o;if(!this.email)return!1;this._copyStatus="copied";const e=await Z9(this.email);return this._copyStatus=e?"copied":"failed",this._announcement=e?"Copied to clipboard":"Could not copy to clipboard",window.clearTimeout(this._resetTimer),this._resetTimer=window.setTimeout(()=>{this._copyStatus="idle",this._announcement=""},$9),await this.updateComplete,(o=(t=this.shadowRoot)==null?void 0:t.querySelector("anduin-tooltip-trigger"))==null||o.dispatchEvent(new CustomEvent(Ot,{bubbles:!0,composed:!0})),e}_renderEmail(){if(!this.email)return f;const e=this._copyStatus==="copied";return d`
5573
5573
  <div class="block__email" part="email">
5574
5574
  <span class="block__email-text">${this.email}</span>
5575
5575
  <anduin-tooltip>
@@ -5728,7 +5728,7 @@
5728
5728
  display: contents;
5729
5729
  cursor: pointer;
5730
5730
  }
5731
- `;let Wo=Dr;customElements.get("anduin-dialog-trigger")||customElements.define("anduin-dialog-trigger",Wo);const ga={small:"480px",medium:"720px",large:"960px",extraLarge:"1160px","extra-large":"1160px",fitContent:"fit-content"},M2=(n,e)=>{const t=(n??"").trim();return e[t]?e[t]:/^\d+(\.\d+)?$/.test(t)?`${t}px`:t};var Oe;const Qe=(Oe=class extends C{constructor(){super(...arguments),this.width="",this.height="",this.autoFocus=!0,this.alert=!1,this.dialogLabel=null,this._leaving=!1,this._shown=!1,this._holdsScrollLock=!1,this._focusFrame=0,this._onOverlayClick=()=>{var e;return(e=this._dialog)==null?void 0:e.requestCloseFromOutside()}}get _dialog(){return W1(this,Ue)}get _panel(){var e;return(e=this.shadowRoot)==null?void 0:e.querySelector(".panel")}connectedCallback(){super.connectedCallback(),this.syncOpen()}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this._leaveTimer),cancelAnimationFrame(this._focusFrame),this._shown=!1,this._leaving=!1,this.classList.remove("is-shown"),this._releaseScroll()}willUpdate(e){(e.has("width")||e.has("height"))&&this._applySizing()}updated(e){e.has("dialogLabel")&&this.refreshAccessibleText()}_applySizing(){const e=this.style,t=M2(this.width,ga),o=M2(this.height,{fill:"75vh"}),i=(s,r)=>r?e.setProperty(s,r):e.removeProperty(s);t==="full"?(i("--anduin-dialog-content-width","100%"),i("--anduin-dialog-content-height","100%"),i("--anduin-dialog-content-margin","0"),i("--anduin-dialog-content-border-radius","0"),i("--anduin-dialog-content-max-height","100vh")):(i("--anduin-dialog-content-width",t),i("--anduin-dialog-content-height",o),i("--anduin-dialog-content-margin",""),i("--anduin-dialog-content-border-radius",""),i("--anduin-dialog-content-max-height",""))}syncOpen(){var t;!!((t=this._dialog)!=null&&t.isOpen)?this._enter():this._exit()}_enter(){clearTimeout(this._leaveTimer),!(this._shown&&!this._leaving)&&(this._shown=!0,this._leaving=!1,this.classList.add("is-shown"),this._holdsScrollLock||(this._holdsScrollLock=!0,b4()),this.updateComplete.then(()=>{!this._shown||this._leaving||(this.refreshAccessibleText(),this.autoFocus&&(cancelAnimationFrame(this._focusFrame),this._focusFrame=requestAnimationFrame(()=>this._focusInitial())))}))}_exit(){cancelAnimationFrame(this._focusFrame),!(!this._shown||this._leaving)&&(this._leaving=!0,this._leaveTimer=setTimeout(()=>{this._shown=!1,this._leaving=!1,this.classList.remove("is-shown"),this._releaseScroll()},Math.max(Xt,k5)))}_releaseScroll(){this._holdsScrollLock&&(this._holdsScrollLock=!1,P2())}_own(e){return Array.from(this.querySelectorAll(e)).filter(t=>W1(t,Oe)===this)}_focusInitial(){var o;const e=this._own("[autofocus], [data-autofocus]")[0];let t=e?q2(e)??e:null;if(!t&&this.alert){const i=this._own("anduin-dialog-close")[0];t=i?q2(i):null}(o=t??this._panel)==null||o.focus({preventScroll:!0})}trapTab(e){const t=this._panel;if(!t)return;const o=_i(this);if(!o.length){e.preventDefault(),t.focus({preventScroll:!0});return}const i=w3(),s=x3(this,i),r=i===t,a=o.findIndex(h=>h===i),c=o[0],u=o[o.length-1];e.shiftKey?(!s||r||a===0)&&(e.preventDefault(),u.focus()):(!s||r||a===o.length-1)&&(e.preventDefault(),c.focus())}shake(){var e;(e=this._panel)==null||e.animate([{transform:"scale(1)"},{transform:"scale(1.02)"},{transform:"scale(1)"}],{duration:250,easing:"cubic-bezier(0.2, 0, 0, 1)"})}refreshAccessibleText(){var s;const e=this._panel;if(!e)return;const t=r=>{var a,c;return((c=(a=this._own(r)[0])==null?void 0:a.textContent)==null?void 0:c.trim())||null},o=((s=this.dialogLabel)==null?void 0:s.trim())||null,i=(r,a)=>{a?e.getAttribute(r)!==a&&e.setAttribute(r,a):e.removeAttribute(r)};i("aria-label",o??t("anduin-dialog-title")),i("aria-description",t("anduin-dialog-description"))}render(){const e=this._leaving?" is-leaving":"",t=M2(this.width,ga)==="full"?" panel--full":"";return d`
5731
+ `;let Wo=Dr;customElements.get("anduin-dialog-trigger")||customElements.define("anduin-dialog-trigger",Wo);const fa={small:"480px",medium:"720px",large:"960px",extraLarge:"1160px","extra-large":"1160px",fitContent:"fit-content"},M2=(n,e)=>{const t=(n??"").trim();return e[t]?e[t]:/^\d+(\.\d+)?$/.test(t)?`${t}px`:t};var Oe;const Qe=(Oe=class extends C{constructor(){super(...arguments),this.width="",this.height="",this.autoFocus=!0,this.alert=!1,this.dialogLabel=null,this._leaving=!1,this._shown=!1,this._holdsScrollLock=!1,this._focusFrame=0,this._onOverlayClick=()=>{var e;return(e=this._dialog)==null?void 0:e.requestCloseFromOutside()}}get _dialog(){return W1(this,Ue)}get _panel(){var e;return(e=this.shadowRoot)==null?void 0:e.querySelector(".panel")}connectedCallback(){super.connectedCallback(),this.syncOpen()}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this._leaveTimer),cancelAnimationFrame(this._focusFrame),this._shown=!1,this._leaving=!1,this.classList.remove("is-shown"),this._releaseScroll()}willUpdate(e){(e.has("width")||e.has("height"))&&this._applySizing()}updated(e){e.has("dialogLabel")&&this.refreshAccessibleText()}_applySizing(){const e=this.style,t=M2(this.width,fa),o=M2(this.height,{fill:"75vh"}),i=(s,r)=>r?e.setProperty(s,r):e.removeProperty(s);t==="full"?(i("--anduin-dialog-content-width","100%"),i("--anduin-dialog-content-height","100%"),i("--anduin-dialog-content-margin","0"),i("--anduin-dialog-content-border-radius","0"),i("--anduin-dialog-content-max-height","100vh")):(i("--anduin-dialog-content-width",t),i("--anduin-dialog-content-height",o),i("--anduin-dialog-content-margin",""),i("--anduin-dialog-content-border-radius",""),i("--anduin-dialog-content-max-height",""))}syncOpen(){var t;!!((t=this._dialog)!=null&&t.isOpen)?this._enter():this._exit()}_enter(){clearTimeout(this._leaveTimer),!(this._shown&&!this._leaving)&&(this._shown=!0,this._leaving=!1,this.classList.add("is-shown"),this._holdsScrollLock||(this._holdsScrollLock=!0,b4()),this.updateComplete.then(()=>{!this._shown||this._leaving||(this.refreshAccessibleText(),this.autoFocus&&(cancelAnimationFrame(this._focusFrame),this._focusFrame=requestAnimationFrame(()=>this._focusInitial())))}))}_exit(){cancelAnimationFrame(this._focusFrame),!(!this._shown||this._leaving)&&(this._leaving=!0,this._leaveTimer=setTimeout(()=>{this._shown=!1,this._leaving=!1,this.classList.remove("is-shown"),this._releaseScroll()},Math.max(Xt,k5)))}_releaseScroll(){this._holdsScrollLock&&(this._holdsScrollLock=!1,P2())}_own(e){return Array.from(this.querySelectorAll(e)).filter(t=>W1(t,Oe)===this)}_focusInitial(){var o;const e=this._own("[autofocus], [data-autofocus]")[0];let t=e?q2(e)??e:null;if(!t&&this.alert){const i=this._own("anduin-dialog-close")[0];t=i?q2(i):null}(o=t??this._panel)==null||o.focus({preventScroll:!0})}trapTab(e){const t=this._panel;if(!t)return;const o=_i(this);if(!o.length){e.preventDefault(),t.focus({preventScroll:!0});return}const i=w3(),s=x3(this,i),r=i===t,a=o.findIndex(h=>h===i),c=o[0],u=o[o.length-1];e.shiftKey?(!s||r||a===0)&&(e.preventDefault(),u.focus()):(!s||r||a===o.length-1)&&(e.preventDefault(),c.focus())}shake(){var e;(e=this._panel)==null||e.animate([{transform:"scale(1)"},{transform:"scale(1.02)"},{transform:"scale(1)"}],{duration:250,easing:"cubic-bezier(0.2, 0, 0, 1)"})}refreshAccessibleText(){var s;const e=this._panel;if(!e)return;const t=r=>{var a,c;return((c=(a=this._own(r)[0])==null?void 0:a.textContent)==null?void 0:c.trim())||null},o=((s=this.dialogLabel)==null?void 0:s.trim())||null,i=(r,a)=>{a?e.getAttribute(r)!==a&&e.setAttribute(r,a):e.removeAttribute(r)};i("aria-label",o??t("anduin-dialog-title")),i("aria-description",t("anduin-dialog-description"))}render(){const e=this._leaving?" is-leaving":"",t=M2(this.width,fa)==="full"?" panel--full":"";return d`
5732
5732
  <div class="overlay${e}" part="overlay" @click=${this._onOverlayClick}></div>
5733
5733
  <div class="wrapper">
5734
5734
  <div
@@ -5861,7 +5861,7 @@
5861
5861
  <h2 class="title" part="title"><slot></slot></h2>
5862
5862
  ${this.showCloseButton?d`<anduin-dialog-close part="close"
5863
5863
  ><anduin-button appearance="plain" variant="gray9" label="Close" start-icon="cross"></anduin-button
5864
- ></anduin-dialog-close>`:g}
5864
+ ></anduin-dialog-close>`:f}
5865
5865
  </div>
5866
5866
  `}};Fr.styles=p`
5867
5867
  :host {
@@ -5926,7 +5926,7 @@
5926
5926
  white-space: nowrap;
5927
5927
  border: 0;
5928
5928
  }
5929
- `,Gr=class Gr extends C{constructor(){super(...arguments),this.value="",this.placement="bottom-start",this.loading=!1,this.itemHeight=null,this._announcement="",this._open=!1,this._query="",this._highlighted=null,this._ignorePointer=!1,this._typeahead="",this._syncQueued=!1,this._focusFrame=0,this._rankedOrder=!1,this._observer=null,this._onItemSelected=e=>{const t=e.target;!(t instanceof s1)||D(t)!==this||!this._open||this.loading||(e.stopPropagation(),e.defaultPrevented||this._selectValue(e.detail.value))},this._onDocPointerDown=e=>{this._open&&(e.composedPath().includes(this)||this.hide())},this._onDocPointerMove=()=>{this._ignorePointer=!1},this._onDocKeyDown=e=>{!this._open||e.key!=="Escape"||(e.preventDefault(),this.hide(),this._focusTrigger())}}get open(){return this._open}connectedCallback(){super.connectedCallback(),this._observer=new MutationObserver(e=>{e.every(t=>{var o,i,s;return((o=t.target.parentElement)==null?void 0:o.closest("anduin-select-selected-label"))||((s=(i=t.target).closest)==null?void 0:s.call(i,"anduin-select-selected-label"))})||this.requestSync()}),this._observer.observe(this,{childList:!0,subtree:!0,characterData:!0,attributes:!0,attributeFilter:["value","label","disabled","placeholder","max-height"]}),this.addEventListener(Qo,this._onItemSelected),this.requestSync()}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._observer)==null||e.disconnect(),this._observer=null,this.removeEventListener(Qo,this._onItemSelected),this._open&&this._teardownOpen()}updated(e){e.has("itemHeight")&&(this.itemHeight&&this.itemHeight>0?this.style.setProperty("--anduin-select-item-height",`${this.itemHeight}px`):this.style.removeProperty("--anduin-select-item-height")),(e.has("value")||e.has("loading"))&&this._sync()}render(){return d`<slot></slot><div class="sr-only" aria-live="polite" aria-atomic="true">${this._announcement}</div>`}_own(e){return Array.from(this.querySelectorAll(e)).filter(t=>D(t)===this)}get _trigger(){return this._own("anduin-select-trigger")[0]??null}get _content(){return this._own("anduin-select-content")[0]??null}get _list(){return this._own("anduin-select-list")[0]??null}get _input(){return this._own("anduin-select-input")[0]??null}get _items(){return this._own("anduin-select-item")}labelFor(e){if(!e)return"";const t=this._items.find(o=>o.value===e);return t?t.labelText:e}requestSync(){this._syncQueued||(this._syncQueued=!0,queueMicrotask(()=>{this._syncQueued=!1,this.isConnected&&this._sync()}))}_sync(){const e=this.value??"",t=this._items;for(const r of t)r.selected=!!e&&r.value===e,r.highlighted=r===this._highlighted;const o=this.labelFor(e);for(const r of this._own("anduin-select-selected-label"))r._show(o);for(const r of this._own("anduin-select-clear"))r.visible=!!e;const i=this._applyFilter(t);for(const r of this._own("anduin-select-empty"))r.hidden=this.loading||i>0;const s=this._list;s&&(s.loading=this.loading,v1(s,"aria-label",this._comboboxName())),this._syncTrigger()}_applyFilter(e){const t=this._query,o=this._input,i=o==null?void 0:o.rank,s=o==null?void 0:o.filter,r=t.toLowerCase(),a=new Map;let c=0;for(const h of e){let f=!0;if(t){const m={query:t,value:h.value,label:h.labelText};if(i){const v=i(m);f=v!=null&&!Number.isNaN(v),f&&a.set(h,v)}else s?f=!!s(m):f=m.label.toLowerCase().includes(r)}h.hidden=!f,f&&c++}if(!!(t&&i)){const h=new Map;for(const f of a.keys()){const m=f.parentElement;h.has(m)||h.set(m,[]),h.get(m).push(f)}for(const f of h.values())f.map((m,v)=>({item:m,i:v,s:a.get(m)})).sort((m,v)=>v.s-m.s||m.i-v.i).forEach(({item:m},v)=>m.style.setProperty("order",String(v+1)));this._rankedOrder=!0}else if(this._rankedOrder){for(const h of e)h.style.removeProperty("order");this._rankedOrder=!1}for(const h of this._own("anduin-select-group"))h.hidden=!Array.from(h.querySelectorAll("anduin-select-item")).some(f=>D(f)===this&&!f.hidden);for(const h of this._own("anduin-select-separator")){const f=_=>(_.localName==="anduin-select-item"||_.localName==="anduin-select-group")&&!_.hidden;let m=!1;for(let _=h.previousElementSibling;_&&!(_.localName==="anduin-select-separator"&&!_.hidden);_=_.previousElementSibling)if(f(_)){m=!0;break}let v=!1;for(let _=h.nextElementSibling;_;_=_.nextElementSibling)if(f(_)){v=!0;break}h.hidden=!(m&&v)}return this._highlighted&&(this._highlighted.hidden||!this._highlighted.isConnected)&&this._setHighlight(null),c}_comboboxName(){var s,r,a;const e=this._trigger,t=(e==null?void 0:e.getAttribute("label"))||(e==null?void 0:e.getAttribute("aria-label"));if(t)return t;const o=this.closest("anduin-field"),i=(r=(s=o==null?void 0:o.querySelector("anduin-field-label"))==null?void 0:s.textContent)==null?void 0:r.trim();return i||(((a=this._own("anduin-select-selected-label")[0])==null?void 0:a.placeholder)??"")}_syncTrigger(){var o,i;const e=this._trigger;if(!e)return;e._syncAria({expanded:this._open,activeItem:this._open?this._highlighted:null,listId:this._open?((o=this._list)==null?void 0:o.id)??"":"",name:this._comboboxName(),clearable:this._own("anduin-select-clear").length>0});const t=this._input;t==null||t._syncAria(this._open,this._open?this._highlighted:null,((i=this._list)==null?void 0:i.id)??"")}show(){var o;if(this._open)return;const e=this._content;if(!e)return;this._open=!0,this._query="",(o=this._input)==null||o._reset(),this._ignorePointer=!0,this._sync(),e._show(()=>this._trigger??this,()=>this.placement,()=>this._list),document.addEventListener("pointerdown",this._onDocPointerDown,!0),document.addEventListener("pointermove",this._onDocPointerMove,!0),document.addEventListener("keydown",this._onDocKeyDown,!0),this._scrollIntoView(this._items.find(i=>i.selected&&!i.hidden)??null);const t=this._input;t&&(cancelAnimationFrame(this._focusFrame),this._focusFrame=requestAnimationFrame(()=>{this._focusFrame=requestAnimationFrame(()=>{this._open&&t.focusInput()})}))}hide(){this._open&&(this._close(),this.dispatchEvent(new CustomEvent(j2,{detail:{value:void 0},bubbles:!1,composed:!1})))}toggle(){this._open?this.hide():this.show()}_close(){var e,t;this._open=!1,this._teardownOpen(),(e=this._content)==null||e._hide(),this._setHighlight(null),this._query="",(t=this._input)==null||t._reset(),this._sync()}_teardownOpen(){cancelAnimationFrame(this._focusFrame),document.removeEventListener("pointerdown",this._onDocPointerDown,!0),document.removeEventListener("pointermove",this._onDocPointerMove,!0),document.removeEventListener("keydown",this._onDocKeyDown,!0)}clear(){this.value&&(this.value="",this._announcement="Selection cleared",this._sync(),P(this,K2,""))}_selectValue(e){this.value=e,e&&(this._announcement=""),this._close(),this._focusTrigger(),P(this,K2,e),this.dispatchEvent(new CustomEvent(j2,{detail:{value:void 0},bubbles:!1,composed:!1}))}_focusTrigger(){var e;(e=this._trigger)==null||e._focusControl()}_navigable(){const e=this._items.filter(t=>!t.hidden&&!t.disabled);return this._rankedOrder?e.map(t=>({item:t,top:t.getBoundingClientRect().top})).sort((t,o)=>t.top-o.top).map(({item:t})=>t):e}_setHighlight(e,t=!0){this._highlighted!==e&&(this._highlighted&&(this._highlighted.highlighted=!1),this._highlighted=e,e&&(e.highlighted=!0,t&&this._scrollIntoView(e)),this._syncTrigger())}_scrollIntoView(e){const t=this._list;if(!e||!t)return;const o=t.getBoundingClientRect(),i=e.getBoundingClientRect();i.top<o.top?t.scrollTop-=o.top-i.top:i.bottom>o.bottom&&(t.scrollTop+=i.bottom-o.bottom)}_move(e){const t=this._navigable();if(!t.length)return;const o=this._highlighted?t.indexOf(this._highlighted):-1,i=o<0?0:(o+e+t.length)%t.length;this._setHighlight(t[i])}_highlightEdge(e){const t=this._navigable();this._setHighlight(e==="first"?t[0]??null:t[t.length-1]??null)}_selectHighlighted(){if(this.loading||!this._open)return;const e=this._highlighted;e&&!e.hidden&&!e.disabled&&e.click()}_typeaheadKey(e){clearTimeout(this._typeaheadTimer),this._typeahead+=e.toLowerCase(),this._typeaheadTimer=setTimeout(()=>this._typeahead="",500);const t=this._navigable();if(!t.length)return;const o=this._typeahead,i=o.length>1&&[...o].every(c=>c===o[0]),s=i?o[0]:o,r=this._highlighted?t.indexOf(this._highlighted):-1,a=o.length===1||i?1:0;for(let c=0;c<t.length;c++){const u=t[(r+a+c+t.length)%t.length];if(u.labelText.toLowerCase().startsWith(s)){this._setHighlight(u);return}}}_hover(e){this.loading||this._ignorePointer||e.disabled||!this._open||this._setHighlight(e,!1)}_setQuery(e){this._query=e,this._setHighlight(null),this._ignorePointer=!0,this._sync();const t=this._list;t&&(t.scrollTop=0)}_onTriggerKeyDown(e){const o=e.composedPath().some(s=>s instanceof HTMLElement&&(s.isContentEditable||s.tagName==="INPUT"||s.tagName==="TEXTAREA")),i=e.key;if(i==="ArrowDown"||i==="ArrowUp"||(i==="Home"||i==="End")&&!o){e.preventDefault();const s=this._open;if(s||this.show(),this.loading)return;i==="Home"||i==="ArrowDown"&&!s?this._highlightEdge("first"):i==="End"||i==="ArrowUp"&&!s?this._highlightEdge("last"):this._move(i==="ArrowDown"?1:-1)}else i==="Enter"||i===" "?(e.preventDefault(),this._open?this._selectHighlighted():this.show()):(i==="Delete"||i==="Backspace")&&!this._open&&this._own("anduin-select-clear").length?(e.preventDefault(),this.clear()):this._open&&!o&&i.length===1&&!e.ctrlKey&&!e.metaKey&&!e.altKey&&(e.preventDefault(),this.loading||this._typeaheadKey(i))}_onInputKeyDown(e){e.key==="ArrowDown"||e.key==="ArrowUp"?(e.preventDefault(),this.loading||this._move(e.key==="ArrowDown"?1:-1)):e.key==="Enter"&&(e.preventDefault(),this._selectHighlighted())}_onTriggerClick(){var e;(e=this._trigger)!=null&&e._isDisabled()||this.toggle()}};Gr.styles=[P9,p`
5929
+ `,Gr=class Gr extends C{constructor(){super(...arguments),this.value="",this.placement="bottom-start",this.loading=!1,this.itemHeight=null,this._announcement="",this._open=!1,this._query="",this._highlighted=null,this._ignorePointer=!1,this._typeahead="",this._syncQueued=!1,this._focusFrame=0,this._rankedOrder=!1,this._observer=null,this._onItemSelected=e=>{const t=e.target;!(t instanceof s1)||D(t)!==this||!this._open||this.loading||(e.stopPropagation(),e.defaultPrevented||this._selectValue(e.detail.value))},this._onDocPointerDown=e=>{this._open&&(e.composedPath().includes(this)||this.hide())},this._onDocPointerMove=()=>{this._ignorePointer=!1},this._onDocKeyDown=e=>{!this._open||e.key!=="Escape"||(e.preventDefault(),this.hide(),this._focusTrigger())}}get open(){return this._open}connectedCallback(){super.connectedCallback(),this._observer=new MutationObserver(e=>{e.every(t=>{var o,i,s;return((o=t.target.parentElement)==null?void 0:o.closest("anduin-select-selected-label"))||((s=(i=t.target).closest)==null?void 0:s.call(i,"anduin-select-selected-label"))})||this.requestSync()}),this._observer.observe(this,{childList:!0,subtree:!0,characterData:!0,attributes:!0,attributeFilter:["value","label","disabled","placeholder","max-height"]}),this.addEventListener(Qo,this._onItemSelected),this.requestSync()}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._observer)==null||e.disconnect(),this._observer=null,this.removeEventListener(Qo,this._onItemSelected),this._open&&this._teardownOpen()}updated(e){e.has("itemHeight")&&(this.itemHeight&&this.itemHeight>0?this.style.setProperty("--anduin-select-item-height",`${this.itemHeight}px`):this.style.removeProperty("--anduin-select-item-height")),(e.has("value")||e.has("loading"))&&this._sync()}render(){return d`<slot></slot><div class="sr-only" aria-live="polite" aria-atomic="true">${this._announcement}</div>`}_own(e){return Array.from(this.querySelectorAll(e)).filter(t=>D(t)===this)}get _trigger(){return this._own("anduin-select-trigger")[0]??null}get _content(){return this._own("anduin-select-content")[0]??null}get _list(){return this._own("anduin-select-list")[0]??null}get _input(){return this._own("anduin-select-input")[0]??null}get _items(){return this._own("anduin-select-item")}labelFor(e){if(!e)return"";const t=this._items.find(o=>o.value===e);return t?t.labelText:e}requestSync(){this._syncQueued||(this._syncQueued=!0,queueMicrotask(()=>{this._syncQueued=!1,this.isConnected&&this._sync()}))}_sync(){const e=this.value??"",t=this._items;for(const r of t)r.selected=!!e&&r.value===e,r.highlighted=r===this._highlighted;const o=this.labelFor(e);for(const r of this._own("anduin-select-selected-label"))r._show(o);for(const r of this._own("anduin-select-clear"))r.visible=!!e;const i=this._applyFilter(t);for(const r of this._own("anduin-select-empty"))r.hidden=this.loading||i>0;const s=this._list;s&&(s.loading=this.loading,v1(s,"aria-label",this._comboboxName())),this._syncTrigger()}_applyFilter(e){const t=this._query,o=this._input,i=o==null?void 0:o.rank,s=o==null?void 0:o.filter,r=t.toLowerCase(),a=new Map;let c=0;for(const h of e){let g=!0;if(t){const m={query:t,value:h.value,label:h.labelText};if(i){const v=i(m);g=v!=null&&!Number.isNaN(v),g&&a.set(h,v)}else s?g=!!s(m):g=m.label.toLowerCase().includes(r)}h.hidden=!g,g&&c++}if(!!(t&&i)){const h=new Map;for(const g of a.keys()){const m=g.parentElement;h.has(m)||h.set(m,[]),h.get(m).push(g)}for(const g of h.values())g.map((m,v)=>({item:m,i:v,s:a.get(m)})).sort((m,v)=>v.s-m.s||m.i-v.i).forEach(({item:m},v)=>m.style.setProperty("order",String(v+1)));this._rankedOrder=!0}else if(this._rankedOrder){for(const h of e)h.style.removeProperty("order");this._rankedOrder=!1}for(const h of this._own("anduin-select-group"))h.hidden=!Array.from(h.querySelectorAll("anduin-select-item")).some(g=>D(g)===this&&!g.hidden);for(const h of this._own("anduin-select-separator")){const g=_=>(_.localName==="anduin-select-item"||_.localName==="anduin-select-group")&&!_.hidden;let m=!1;for(let _=h.previousElementSibling;_&&!(_.localName==="anduin-select-separator"&&!_.hidden);_=_.previousElementSibling)if(g(_)){m=!0;break}let v=!1;for(let _=h.nextElementSibling;_;_=_.nextElementSibling)if(g(_)){v=!0;break}h.hidden=!(m&&v)}return this._highlighted&&(this._highlighted.hidden||!this._highlighted.isConnected)&&this._setHighlight(null),c}_comboboxName(){var s,r,a;const e=this._trigger,t=(e==null?void 0:e.getAttribute("label"))||(e==null?void 0:e.getAttribute("aria-label"));if(t)return t;const o=this.closest("anduin-field"),i=(r=(s=o==null?void 0:o.querySelector("anduin-field-label"))==null?void 0:s.textContent)==null?void 0:r.trim();return i||(((a=this._own("anduin-select-selected-label")[0])==null?void 0:a.placeholder)??"")}_syncTrigger(){var o,i;const e=this._trigger;if(!e)return;e._syncAria({expanded:this._open,activeItem:this._open?this._highlighted:null,listId:this._open?((o=this._list)==null?void 0:o.id)??"":"",name:this._comboboxName(),clearable:this._own("anduin-select-clear").length>0});const t=this._input;t==null||t._syncAria(this._open,this._open?this._highlighted:null,((i=this._list)==null?void 0:i.id)??"")}show(){var o;if(this._open)return;const e=this._content;if(!e)return;this._open=!0,this._query="",(o=this._input)==null||o._reset(),this._ignorePointer=!0,this._sync(),e._show(()=>this._trigger??this,()=>this.placement,()=>this._list),document.addEventListener("pointerdown",this._onDocPointerDown,!0),document.addEventListener("pointermove",this._onDocPointerMove,!0),document.addEventListener("keydown",this._onDocKeyDown,!0),this._scrollIntoView(this._items.find(i=>i.selected&&!i.hidden)??null);const t=this._input;t&&(cancelAnimationFrame(this._focusFrame),this._focusFrame=requestAnimationFrame(()=>{this._focusFrame=requestAnimationFrame(()=>{this._open&&t.focusInput()})}))}hide(){this._open&&(this._close(),this.dispatchEvent(new CustomEvent(j2,{detail:{value:void 0},bubbles:!1,composed:!1})))}toggle(){this._open?this.hide():this.show()}_close(){var e,t;this._open=!1,this._teardownOpen(),(e=this._content)==null||e._hide(),this._setHighlight(null),this._query="",(t=this._input)==null||t._reset(),this._sync()}_teardownOpen(){cancelAnimationFrame(this._focusFrame),document.removeEventListener("pointerdown",this._onDocPointerDown,!0),document.removeEventListener("pointermove",this._onDocPointerMove,!0),document.removeEventListener("keydown",this._onDocKeyDown,!0)}clear(){this.value&&(this.value="",this._announcement="Selection cleared",this._sync(),P(this,K2,""))}_selectValue(e){this.value=e,e&&(this._announcement=""),this._close(),this._focusTrigger(),P(this,K2,e),this.dispatchEvent(new CustomEvent(j2,{detail:{value:void 0},bubbles:!1,composed:!1}))}_focusTrigger(){var e;(e=this._trigger)==null||e._focusControl()}_navigable(){const e=this._items.filter(t=>!t.hidden&&!t.disabled);return this._rankedOrder?e.map(t=>({item:t,top:t.getBoundingClientRect().top})).sort((t,o)=>t.top-o.top).map(({item:t})=>t):e}_setHighlight(e,t=!0){this._highlighted!==e&&(this._highlighted&&(this._highlighted.highlighted=!1),this._highlighted=e,e&&(e.highlighted=!0,t&&this._scrollIntoView(e)),this._syncTrigger())}_scrollIntoView(e){const t=this._list;if(!e||!t)return;const o=t.getBoundingClientRect(),i=e.getBoundingClientRect();i.top<o.top?t.scrollTop-=o.top-i.top:i.bottom>o.bottom&&(t.scrollTop+=i.bottom-o.bottom)}_move(e){const t=this._navigable();if(!t.length)return;const o=this._highlighted?t.indexOf(this._highlighted):-1,i=o<0?0:(o+e+t.length)%t.length;this._setHighlight(t[i])}_highlightEdge(e){const t=this._navigable();this._setHighlight(e==="first"?t[0]??null:t[t.length-1]??null)}_selectHighlighted(){if(this.loading||!this._open)return;const e=this._highlighted;e&&!e.hidden&&!e.disabled&&e.click()}_typeaheadKey(e){clearTimeout(this._typeaheadTimer),this._typeahead+=e.toLowerCase(),this._typeaheadTimer=setTimeout(()=>this._typeahead="",500);const t=this._navigable();if(!t.length)return;const o=this._typeahead,i=o.length>1&&[...o].every(c=>c===o[0]),s=i?o[0]:o,r=this._highlighted?t.indexOf(this._highlighted):-1,a=o.length===1||i?1:0;for(let c=0;c<t.length;c++){const u=t[(r+a+c+t.length)%t.length];if(u.labelText.toLowerCase().startsWith(s)){this._setHighlight(u);return}}}_hover(e){this.loading||this._ignorePointer||e.disabled||!this._open||this._setHighlight(e,!1)}_setQuery(e){this._query=e,this._setHighlight(null),this._ignorePointer=!0,this._sync();const t=this._list;t&&(t.scrollTop=0)}_onTriggerKeyDown(e){const o=e.composedPath().some(s=>s instanceof HTMLElement&&(s.isContentEditable||s.tagName==="INPUT"||s.tagName==="TEXTAREA")),i=e.key;if(i==="ArrowDown"||i==="ArrowUp"||(i==="Home"||i==="End")&&!o){e.preventDefault();const s=this._open;if(s||this.show(),this.loading)return;i==="Home"||i==="ArrowDown"&&!s?this._highlightEdge("first"):i==="End"||i==="ArrowUp"&&!s?this._highlightEdge("last"):this._move(i==="ArrowDown"?1:-1)}else i==="Enter"||i===" "?(e.preventDefault(),this._open?this._selectHighlighted():this.show()):(i==="Delete"||i==="Backspace")&&!this._open&&this._own("anduin-select-clear").length?(e.preventDefault(),this.clear()):this._open&&!o&&i.length===1&&!e.ctrlKey&&!e.metaKey&&!e.altKey&&(e.preventDefault(),this.loading||this._typeaheadKey(i))}_onInputKeyDown(e){e.key==="ArrowDown"||e.key==="ArrowUp"?(e.preventDefault(),this.loading||this._move(e.key==="ArrowDown"?1:-1)):e.key==="Enter"&&(e.preventDefault(),this._selectHighlighted())}_onTriggerClick(){var e;(e=this._trigger)!=null&&e._isDisabled()||this.toggle()}};Gr.styles=[P9,p`
5930
5930
  :host { display: inline-block; max-width: 100%; font-family: var(--font-sans); }
5931
5931
  `];let S1=Gr;A([l({reflect:!0})],S1.prototype,"value");A([l()],S1.prototype,"placement");A([l({converter:w,reflect:!0})],S1.prototype,"loading");A([l({attribute:"item-height",type:Number})],S1.prototype,"itemHeight");A([b()],S1.prototype,"_announcement");const qr=class qr extends C{constructor(){super(...arguments),this.label="",this._root=null,this._onClick=()=>{var e;return(e=this._root)==null?void 0:e._onTriggerClick()},this._onKeyDown=e=>{var t;return(t=this._root)==null?void 0:t._onTriggerKeyDown(e)},this._lastName=""}connectedCallback(){var e;super.connectedCallback(),this._root=D(this),this.addEventListener("click",this._onClick),this.addEventListener("keydown",this._onKeyDown),(e=this._root)==null||e.requestSync()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._onClick),this.removeEventListener("keydown",this._onKeyDown),this._root=null}updated(){var e;(e=this._root)==null||e.requestSync()}render(){return d`<slot @slotchange=${()=>{var e;return(e=this._root)==null?void 0:e.requestSync()}}></slot>`}_control(){var t;const e=Array.from(this.children).find(o=>o.localName==="anduin-button"||o.localName==="button");return e?e.localName==="button"?e:((t=e.shadowRoot)==null?void 0:t.querySelector("button, a"))??null:null}_isDisabled(){const e=Array.from(this.children).find(o=>o.localName==="anduin-button"||o.localName==="button");if(!e)return!1;const t=e.getAttribute("disabled");return t!==null&&t!=="false"}_focusControl(){const e=this._control();e?e.focus():this.focus()}_syncAria(e){var s;const t=this._control(),o=Array.from(this.children).some(r=>r.localName==="anduin-button"||r.localName==="button"),i=t??(o?null:this);if(t)for(const r of["role","tabindex","aria-haspopup","aria-expanded","aria-controls","aria-activedescendant","aria-keyshortcuts"])this.removeAttribute(r);i&&(v1(i,"role","combobox"),v1(i,"aria-haspopup","listbox"),v1(i,"aria-expanded",String(e.expanded)),i===this?(v1(this,"tabindex","0"),v1(this,"aria-controls",e.listId),v1(this,"aria-activedescendant",((s=e.activeItem)==null?void 0:s.id)??""),v1(this,"aria-keyshortcuts",e.clearable?"Delete Backspace":""),(!this.getAttribute("aria-label")||this.getAttribute("aria-label")===this._lastName)&&(v1(this,"aria-label",e.name),this._lastName=e.name)):(i.ariaActiveDescendantElement=e.activeItem,(!i.getAttribute("aria-label")||i.getAttribute("aria-label")===this._lastName)&&(v1(i,"aria-label",e.name),this._lastName=e.name)))}};qr.styles=p`
5932
5932
  :host { display: block; cursor: pointer; }
@@ -6001,7 +6001,7 @@
6001
6001
  `;let Vt=jr;A([l({attribute:"max-height"})],Vt.prototype,"maxHeight");A([l({type:Boolean,attribute:!1})],Vt.prototype,"loading");const Wr=class Wr extends C{constructor(){super(...arguments),this.value="",this.label=null,this.description="",this.disabled=!1,this.size="medium",this.startIcon="",this.selected=!1,this.highlighted=!1,this._hasSlottedDescription=!1,this._onClick=()=>{this.disabled||this.dispatchEvent(new CustomEvent(Qo,{detail:{value:this.value},bubbles:!0,composed:!0,cancelable:!0}))},this._onPointer=()=>{var e;return(e=D(this))==null?void 0:e._hover(this)},this._onPointerMove=()=>{var e;this.highlighted||(e=D(this))==null||e._hover(this)}}get labelText(){if(this.label)return this.label;let e="";return this.childNodes.forEach(t=>{t instanceof Element&&t.getAttribute("slot")==="description"||(e+=t.textContent??"")}),e.replace(/\s+/g," ").trim()}connectedCallback(){var e;super.connectedCallback(),this.id||(this.id=u2("anduin-select-item")),this.setAttribute("role","option"),this.addEventListener("click",this._onClick),this.addEventListener("pointerenter",this._onPointer),this.addEventListener("pointermove",this._onPointerMove),(e=D(this))==null||e.requestSync()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._onClick),this.removeEventListener("pointerenter",this._onPointer),this.removeEventListener("pointermove",this._onPointerMove)}updated(e){e.has("selected")&&this.setAttribute("aria-selected",String(this.selected)),e.has("disabled")&&v1(this,"aria-disabled",this.disabled?"true":"")}_onDescriptionSlotChange(e){const t=e.target;this._hasSlottedDescription=t.assignedNodes().length>0}render(){const e=["item",this.size==="free"?"item--free":"",this.selected?"item--selected":"",this.highlighted?"item--highlighted":"",this.description||this._hasSlottedDescription?"item--described":"",this.disabled?"item--disabled":""].filter(Boolean).join(" ");return d`
6002
6002
  <div class=${e} part="item">
6003
6003
  <span class="check" aria-hidden="true"><anduin-icon name="checkSmall" size="16"></anduin-icon></span>
6004
- ${this.startIcon?d`<span class="icon" aria-hidden="true"><anduin-icon name=${this.startIcon} size="16"></anduin-icon></span>`:g}
6004
+ ${this.startIcon?d`<span class="icon" aria-hidden="true"><anduin-icon name=${this.startIcon} size="16"></anduin-icon></span>`:f}
6005
6005
  <div class="content">
6006
6006
  <span class="label" part="label"><slot></slot></span>
6007
6007
  <slot class="description" part="description" name="description" @slotchange=${this._onDescriptionSlotChange}>${this.description}</slot>
@@ -6047,7 +6047,7 @@
6047
6047
  .item--highlighted, .item:active { background-color: var(--color-accent-active); }
6048
6048
  .item--disabled { opacity: 0.5; cursor: not-allowed; }
6049
6049
  .item--disabled:active { background-color: transparent; }
6050
- `;let s1=Wr;A([l()],s1.prototype,"value");A([l()],s1.prototype,"label");A([l()],s1.prototype,"description");A([l({converter:w,reflect:!0})],s1.prototype,"disabled");A([l()],s1.prototype,"size");A([l({attribute:"start-icon"})],s1.prototype,"startIcon");A([l({attribute:!1})],s1.prototype,"selected");A([l({attribute:!1})],s1.prototype,"highlighted");A([b()],s1.prototype,"_hasSlottedDescription");const Yr=class Yr extends C{constructor(){super(...arguments),this.placeholder="",this.size="default",this.label="",this._filter=null,this._rank=null}get filter(){return this._filter}set filter(e){var t;this._filter=e,(t=D(this))==null||t.requestSync()}get rank(){return this._rank}set rank(e){var t;this._rank=e,(t=D(this))==null||t.requestSync()}get _inputEl(){var e;return((e=this.renderRoot)==null?void 0:e.querySelector("input"))??null}get query(){var e;return((e=this._inputEl)==null?void 0:e.value)??""}connectedCallback(){var e;super.connectedCallback();for(const t of["filter","rank"])if(Object.prototype.hasOwnProperty.call(this,t)){const o=this[t];delete this[t],this[t]=o}(e=D(this))==null||e.requestSync()}focusInput(){var e;(e=this._inputEl)==null||e.focus()}_reset(){const e=this._inputEl;e&&(e.value="")}_syncAria(e,t,o){const i=this._inputEl;i&&(i.setAttribute("aria-expanded",String(e)),i.ariaActiveDescendantElement=t)}_onInput(e){var t;(t=D(this))==null||t._setQuery(e.target.value)}_onKeyDown(e){var t;(t=D(this))==null||t._onInputKeyDown(e)}render(){const e=this.size==="small"||this.size==="large"?this.size:"default",t=this.label||this.getAttribute("aria-label")||this.placeholder||g;return d`
6050
+ `;let s1=Wr;A([l()],s1.prototype,"value");A([l()],s1.prototype,"label");A([l()],s1.prototype,"description");A([l({converter:w,reflect:!0})],s1.prototype,"disabled");A([l()],s1.prototype,"size");A([l({attribute:"start-icon"})],s1.prototype,"startIcon");A([l({attribute:!1})],s1.prototype,"selected");A([l({attribute:!1})],s1.prototype,"highlighted");A([b()],s1.prototype,"_hasSlottedDescription");const Yr=class Yr extends C{constructor(){super(...arguments),this.placeholder="",this.size="default",this.label="",this._filter=null,this._rank=null}get filter(){return this._filter}set filter(e){var t;this._filter=e,(t=D(this))==null||t.requestSync()}get rank(){return this._rank}set rank(e){var t;this._rank=e,(t=D(this))==null||t.requestSync()}get _inputEl(){var e;return((e=this.renderRoot)==null?void 0:e.querySelector("input"))??null}get query(){var e;return((e=this._inputEl)==null?void 0:e.value)??""}connectedCallback(){var e;super.connectedCallback();for(const t of["filter","rank"])if(Object.prototype.hasOwnProperty.call(this,t)){const o=this[t];delete this[t],this[t]=o}(e=D(this))==null||e.requestSync()}focusInput(){var e;(e=this._inputEl)==null||e.focus()}_reset(){const e=this._inputEl;e&&(e.value="")}_syncAria(e,t,o){const i=this._inputEl;i&&(i.setAttribute("aria-expanded",String(e)),i.ariaActiveDescendantElement=t)}_onInput(e){var t;(t=D(this))==null||t._setQuery(e.target.value)}_onKeyDown(e){var t;(t=D(this))==null||t._onInputKeyDown(e)}render(){const e=this.size==="small"||this.size==="large"?this.size:"default",t=this.label||this.getAttribute("aria-label")||this.placeholder||f;return d`
6051
6051
  <div class="wrapper wrapper--${e}">
6052
6052
  <span class="icon" aria-hidden="true"><anduin-icon name="search" size="16"></anduin-icon></span>
6053
6053
  <input
@@ -6172,7 +6172,7 @@
6172
6172
  part="panel"
6173
6173
  role="dialog"
6174
6174
  tabindex="-1"
6175
- aria-modal=${t?"true":g}
6175
+ aria-modal=${t?"true":f}
6176
6176
  >
6177
6177
  <div class="sheet-panel__scroll"><slot></slot></div>
6178
6178
  <div
@@ -6181,7 +6181,7 @@
6181
6181
  aria-label="Resize sheet"
6182
6182
  tabindex="0"
6183
6183
  aria-orientation=${Me(e)?"horizontal":"vertical"}
6184
- aria-valuenow=${o?Math.round(this._panelSize(e)):g}
6184
+ aria-valuenow=${o?Math.round(this._panelSize(e)):f}
6185
6185
  aria-valuemin=${ba}
6186
6186
  aria-valuemax=${i}
6187
6187
  @pointerdown=${this._onResizeStart}
@@ -6344,11 +6344,11 @@
6344
6344
  @media (prefers-reduced-motion: reduce) {
6345
6345
  .sheet-panel { transition: none; }
6346
6346
  }
6347
- `;let r1=sl;Q1([l({converter:w})],r1.prototype,"dock");Q1([l({converter:C2})],r1.prototype,"modal");Q1([l({converter:w})],r1.prototype,"resizable");Q1([l({attribute:"auto-focus",converter:C2})],r1.prototype,"autoFocus");Q1([l()],r1.prototype,"width");Q1([b()],r1.prototype,"_shown");Q1([b()],r1.prototype,"_entered");Q1([b()],r1.prototype,"_side");Q1([b()],r1.prototype,"_dragging");customElements.get("anduin-sheet-content")||customElements.define("anduin-sheet-content",r1);var J9=Object.defineProperty,Q9=Object.getOwnPropertyDescriptor,f2=(n,e,t,o)=>{for(var i=o>1?void 0:o?Q9(e,t):e,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=(o?r(e,t,i):r(i))||i);return o&&i&&J9(e,t,i),i};const O3="anduin-sheet-open-change",J2="anduin-sheet-on-open",Q2="anduin-sheet-on-close",e6=new Set(["top","right","bottom","left"]),rl=class rl extends C{constructor(){super(),this._open=!1,this._controlled=!1,this.defaultOpen=!1,this.side="right",this.closeOnEscape=!0,this._visible=!1,this._trigger=null,this._content=null,this._focusFrame=0,this._stopAtSelf=e=>{e.stopPropagation()},this._onRegister=e=>{e.stopPropagation(),e.detail.kind==="content"?this._setContent(e.detail.el):this._trigger=e.detail.el},this._onCommand=e=>{e.stopPropagation(),e.detail.action==="toggle"?this.requestOpen(!this._visible):this._visible&&this.requestOpen(!1)},this._onDocKeyDown=e=>{var t;e.key!=="Escape"||!this._visible||e.defaultPrevented||!k3(this)||M3(e,((t=this._content)==null?void 0:t.panel)??null)||(e.preventDefault(),this.closeOnEscape&&(this.requestOpen(!1),this._focusTrigger()))},this.addEventListener(p2,this._onRegister),this.addEventListener(Z5,this._onCommand),this.addEventListener(J2,this._stopAtSelf),this.addEventListener(Q2,this._stopAtSelf)}get open(){return this._open}set open(e){const t=this._open;this._open=e,this._controlled=!0,this.requestUpdate("open",t)}get isOpen(){return this._visible}get _isControlled(){return this._controlled||this.hasAttribute("open")}get _side(){return e6.has(this.side)?this.side:"right"}connectedCallback(){super.connectedCallback(),window.addEventListener("keydown",this._onDocKeyDown),this.querySelectorAll("anduin-sheet-trigger, anduin-sheet-content").forEach(e=>{e.closest("anduin-sheet")===this&&(e instanceof r1?this._setContent(e):e instanceof $i&&(this._trigger=e))})}disconnectedCallback(){super.disconnectedCallback(),window.removeEventListener("keydown",this._onDocKeyDown),W2(this),cancelAnimationFrame(this._focusFrame),this._visible=!1,this._trigger=null,this._content=null}updated(e){var t;e.has("open")&&this._isControlled&&this._content&&(this.open&&!this._visible?this._show():!this.open&&this._visible&&this._hide()),e.has("side")&&this._visible&&((t=this._content)==null||t.setSide(this._side))}requestOpen(e){this._isControlled?(this.dispatchEvent(new CustomEvent(O3,{detail:{value:e},bubbles:!1,composed:!0})),this.open=e):e?this._show():this._hide()}_setContent(e){this._content=e,queueMicrotask(()=>this._maybeShowInitial())}_maybeShowInitial(){this._visible||!this._content||!this.isConnected||(this._isControlled?this.open:this.defaultOpen)&&this._show()}_show(){this._visible||!this._content||(cancelAnimationFrame(this._focusFrame),this._visible=!0,this._content.show(this._side),F9(this),P(this,J2,void 0))}_hide(){var t,o;if(!this._visible)return;const e=((t=this._content)==null?void 0:t.containsFocus())??!1;this._visible=!1,(o=this._content)==null||o.hide(),W2(this),P(this,Q2,void 0),e&&this._focusTrigger()}_focusTrigger(){cancelAnimationFrame(this._focusFrame),this._focusFrame=requestAnimationFrame(()=>{const e=this._trigger;if(!e)return;const t=E3(e)[0]??e.firstElementChild;t==null||t.focus()})}render(){return d`<slot></slot>`}};rl.styles=p`
6347
+ `;let r1=sl;Q1([l({converter:w})],r1.prototype,"dock");Q1([l({converter:C2})],r1.prototype,"modal");Q1([l({converter:w})],r1.prototype,"resizable");Q1([l({attribute:"auto-focus",converter:C2})],r1.prototype,"autoFocus");Q1([l()],r1.prototype,"width");Q1([b()],r1.prototype,"_shown");Q1([b()],r1.prototype,"_entered");Q1([b()],r1.prototype,"_side");Q1([b()],r1.prototype,"_dragging");customElements.get("anduin-sheet-content")||customElements.define("anduin-sheet-content",r1);var J9=Object.defineProperty,Q9=Object.getOwnPropertyDescriptor,g2=(n,e,t,o)=>{for(var i=o>1?void 0:o?Q9(e,t):e,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=(o?r(e,t,i):r(i))||i);return o&&i&&J9(e,t,i),i};const O3="anduin-sheet-open-change",J2="anduin-sheet-on-open",Q2="anduin-sheet-on-close",e6=new Set(["top","right","bottom","left"]),rl=class rl extends C{constructor(){super(),this._open=!1,this._controlled=!1,this.defaultOpen=!1,this.side="right",this.closeOnEscape=!0,this._visible=!1,this._trigger=null,this._content=null,this._focusFrame=0,this._stopAtSelf=e=>{e.stopPropagation()},this._onRegister=e=>{e.stopPropagation(),e.detail.kind==="content"?this._setContent(e.detail.el):this._trigger=e.detail.el},this._onCommand=e=>{e.stopPropagation(),e.detail.action==="toggle"?this.requestOpen(!this._visible):this._visible&&this.requestOpen(!1)},this._onDocKeyDown=e=>{var t;e.key!=="Escape"||!this._visible||e.defaultPrevented||!k3(this)||M3(e,((t=this._content)==null?void 0:t.panel)??null)||(e.preventDefault(),this.closeOnEscape&&(this.requestOpen(!1),this._focusTrigger()))},this.addEventListener(p2,this._onRegister),this.addEventListener(Z5,this._onCommand),this.addEventListener(J2,this._stopAtSelf),this.addEventListener(Q2,this._stopAtSelf)}get open(){return this._open}set open(e){const t=this._open;this._open=e,this._controlled=!0,this.requestUpdate("open",t)}get isOpen(){return this._visible}get _isControlled(){return this._controlled||this.hasAttribute("open")}get _side(){return e6.has(this.side)?this.side:"right"}connectedCallback(){super.connectedCallback(),window.addEventListener("keydown",this._onDocKeyDown),this.querySelectorAll("anduin-sheet-trigger, anduin-sheet-content").forEach(e=>{e.closest("anduin-sheet")===this&&(e instanceof r1?this._setContent(e):e instanceof $i&&(this._trigger=e))})}disconnectedCallback(){super.disconnectedCallback(),window.removeEventListener("keydown",this._onDocKeyDown),W2(this),cancelAnimationFrame(this._focusFrame),this._visible=!1,this._trigger=null,this._content=null}updated(e){var t;e.has("open")&&this._isControlled&&this._content&&(this.open&&!this._visible?this._show():!this.open&&this._visible&&this._hide()),e.has("side")&&this._visible&&((t=this._content)==null||t.setSide(this._side))}requestOpen(e){this._isControlled?(this.dispatchEvent(new CustomEvent(O3,{detail:{value:e},bubbles:!1,composed:!0})),this.open=e):e?this._show():this._hide()}_setContent(e){this._content=e,queueMicrotask(()=>this._maybeShowInitial())}_maybeShowInitial(){this._visible||!this._content||!this.isConnected||(this._isControlled?this.open:this.defaultOpen)&&this._show()}_show(){this._visible||!this._content||(cancelAnimationFrame(this._focusFrame),this._visible=!0,this._content.show(this._side),F9(this),P(this,J2,void 0))}_hide(){var t,o;if(!this._visible)return;const e=((t=this._content)==null?void 0:t.containsFocus())??!1;this._visible=!1,(o=this._content)==null||o.hide(),W2(this),P(this,Q2,void 0),e&&this._focusTrigger()}_focusTrigger(){cancelAnimationFrame(this._focusFrame),this._focusFrame=requestAnimationFrame(()=>{const e=this._trigger;if(!e)return;const t=E3(e)[0]??e.firstElementChild;t==null||t.focus()})}render(){return d`<slot></slot>`}};rl.styles=p`
6348
6348
  :host {
6349
6349
  display: contents;
6350
6350
  }
6351
- `;let me=rl;f2([l({converter:w})],me.prototype,"open",1);f2([l({attribute:"default-open",converter:w})],me.prototype,"defaultOpen",2);f2([l()],me.prototype,"side",2);f2([l({attribute:"close-on-escape",converter:C2})],me.prototype,"closeOnEscape",2);const ll=class ll extends C{constructor(){super(...arguments),this._onClick=()=>Et(this,"toggle"),this._onKeyDown=e=>{e.key!=="Enter"&&e.key!==" "||(e.preventDefault(),Et(this,"toggle"))}}connectedCallback(){super.connectedCallback(),this.addEventListener("click",this._onClick),this.addEventListener("keydown",this._onKeyDown),this.dispatchEvent(new CustomEvent(p2,{detail:{kind:"trigger",el:this},bubbles:!0,composed:!0}))}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._onClick),this.removeEventListener("keydown",this._onKeyDown)}render(){return d`<slot></slot>`}};ll.styles=p`
6351
+ `;let me=rl;g2([l({converter:w})],me.prototype,"open",1);g2([l({attribute:"default-open",converter:w})],me.prototype,"defaultOpen",2);g2([l()],me.prototype,"side",2);g2([l({attribute:"close-on-escape",converter:C2})],me.prototype,"closeOnEscape",2);const ll=class ll extends C{constructor(){super(...arguments),this._onClick=()=>Et(this,"toggle"),this._onKeyDown=e=>{e.key!=="Enter"&&e.key!==" "||(e.preventDefault(),Et(this,"toggle"))}}connectedCallback(){super.connectedCallback(),this.addEventListener("click",this._onClick),this.addEventListener("keydown",this._onKeyDown),this.dispatchEvent(new CustomEvent(p2,{detail:{kind:"trigger",el:this},bubbles:!0,composed:!0}))}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._onClick),this.removeEventListener("keydown",this._onKeyDown)}render(){return d`<slot></slot>`}};ll.styles=p`
6352
6352
  :host {
6353
6353
  display: block;
6354
6354
  cursor: pointer;
@@ -6419,7 +6419,7 @@
6419
6419
  * @license
6420
6420
  * Copyright 2020 Google LLC
6421
6421
  * SPDX-License-Identifier: BSD-3-Clause
6422
- */const R5=s2(class extends r2{constructor(n){if(super(n),n.type!==I1.PROPERTY&&n.type!==I1.ATTRIBUTE&&n.type!==I1.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!t6(n))throw Error("`live` bindings can only contain a single expression")}render(n){return n}update(n,[e]){if(e===p1||e===g)return e;const t=n.element,o=n.name;if(n.type===I1.PROPERTY){if(e===t[o])return p1}else if(n.type===I1.BOOLEAN_ATTRIBUTE){if(!!e===t.hasAttribute(o))return p1}else if(n.type===I1.ATTRIBUTE&&t.getAttribute(o)===e+"")return p1;return o6(n),e}});var n6=Object.defineProperty,i1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&n6(e,t,i),i};let s6=0;const A5=n=>`${n}-${++s6}`,_a=80,r6=64,be=n=>n.constructor.family;function Zi(n){return n.closest(be(n))}const Gn=class Gn extends C{constructor(){super(...arguments),this.value="",this.placement="bottom-start",this.itemHeight=null,this._open=!1,this._highlighted=null,this._ignorePointer=!1,this._raf=0,this._anchorKey="",this._onItemSelected=e=>{var o;if(!this._open||(e.stopPropagation(),e.defaultPrevented))return;const t=((o=e.detail)==null?void 0:o.value)??"";this.onItemChosen(t)},this._onDocumentPointerDown=e=>{this._open&&(e.composedPath().includes(this)||this.closePanel())},this._onDocumentPointerMove=()=>{this._ignorePointer=!1}}get open(){return this._open}get family(){return be(this)}own(e){return Array.from(this.querySelectorAll(e)).filter(t=>t.closest(this.family)===this)}get field(){return this.own(`${this.family}-input, ${this.family}-textarea`)[0]??null}get content(){return this.own(`${this.family}-content`)[0]??null}get list(){return this.own(`${this.family}-list`)[0]??null}items(){return this.own(`${this.family}-item`)}get emptyElement(){return this.own(`${this.family}-empty`)[0]??null}connectedCallback(){super.connectedCallback(),this.addEventListener(`${this.family}-item-selected`,this._onItemSelected),document.addEventListener("pointerdown",this._onDocumentPointerDown),document.addEventListener("pointermove",this._onDocumentPointerMove,{capture:!0})}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(`${this.family}-item-selected`,this._onItemSelected),document.removeEventListener("pointerdown",this._onDocumentPointerDown),document.removeEventListener("pointermove",this._onDocumentPointerMove,{capture:!0}),this._stopLoop(),this._open=!1}updated(e){if(e.has("itemHeight")){const t=Number(this.itemHeight);t>0?this.style.setProperty(`--${this.family}-item-height`,`${t}px`):this.style.removeProperty(`--${this.family}-item-height`)}}render(){return d`<slot></slot>`}onOpened(){}onClosed(){}openPanel(e){var t;this._open||(t=this.field)!=null&&t.isDisabled||(this._open=!0,this._ignorePointer=!0,this.applyFilter(this.openQuery()),this._startLoop(),e==="first"?this.highlightFirst():e==="last"?this.highlightLast():this.onOpened(),this.syncField())}closePanel(){var t;if(!this._open)return;this._open=!1,this.clearHighlight(),this._stopLoop(),(t=this.content)==null||t.setVisible(!1);const e=this.emptyElement;e&&(e.hidden=!0),this.syncField(),this.onClosed()}itemMatches(e,t){var s;const o=t.labelText,i=(s=this.field)==null?void 0:s.filter;return typeof i=="function"?!!i({query:e,value:t.value,label:o}):o.toLowerCase().includes(e.toLowerCase())}applyFilter(e){var a;const t=this.items();let o=0;for(const c of t){const u=e===""||this.itemMatches(e,c);c.hidden=!u,u&&o++}this._updateStructure();const i=o===0,s=this.emptyElement;s&&(s.hidden=!(this._open&&this.emptyVisible(e,i)));const r=this.list;return r&&(r.scrollTop=0),(a=this.content)==null||a.setVisible(this._open&&this.panelVisible(i),!0),o}_updateStructure(){const e=`${this.family}-group`,t=`${this.family}-separator`,o=`${this.family}-item`,i=this.own(e);for(const r of i){const a=Array.from(r.querySelectorAll(o));r.hidden=a.length>0&&a.every(c=>c.hidden)}const s=this.own(`${e}, ${t}`);s.forEach((r,a)=>{if(r.localName!==t)return;const c=s.slice(0,a).filter(h=>h.localName===e),u=s.slice(a+1).find(h=>h.localName===e);if(!c.length&&!u){r.hidden=!1;return}r.hidden=!(c.some(h=>!h.hidden)&&u&&!u.hidden)})}get highlighted(){return this._highlighted}navigable(){return this.items().filter(e=>!e.hidden&&!e.disabled)}setHighlight(e,t=!0){this._highlighted&&this._highlighted!==e&&(this._highlighted.highlighted=!1),this._highlighted=e,e.highlighted=!0,t&&e.scrollIntoView({block:"nearest"}),this.syncField()}clearHighlight(){this._highlighted&&(this._highlighted.highlighted=!1),this._highlighted=null,this.syncField()}highlightFirst(){const e=this.navigable();e.length&&this.setHighlight(e[0])}highlightLast(){const e=this.navigable();e.length&&this.setHighlight(e[e.length-1])}moveHighlight(e){const t=this.navigable();if(!t.length)return;const o=this._highlighted?t.indexOf(this._highlighted):-1,i=o<0?0:(o+e+t.length)%t.length;this.setHighlight(t[i])}itemHovered(e){this._ignorePointer||e.disabled||!this._open||this._highlighted!==e&&this.setHighlight(e,!1)}ignorePointerUntilMove(){this._ignorePointer=!0}syncField(){var e;(e=this.field)==null||e.syncAria(this._open,this.list,this._highlighted)}labelFor(e){const t=this.items().find(o=>o.value===e);return t?t.labelText:e}get anchor(){return this.field??this}_startLoop(){this._stopLoop(),this._anchorKey="";const e=()=>{var o;const t=this.anchor;if(t){const i=t.getBoundingClientRect(),s=`${i.left},${i.top},${i.width},${i.height},${window.innerWidth},${window.innerHeight}`;s!==this._anchorKey&&(this._anchorKey=s,(o=this.content)==null||o.reposition(i,this.placement))}this._raf=requestAnimationFrame(e)};this._raf=requestAnimationFrame(e)}_stopLoop(){this._raf&&cancelAnimationFrame(this._raf),this._raf=0}reposition(){var t;const e=this.anchor;!e||!this._open||(t=this.content)==null||t.reposition(e.getBoundingClientRect(),this.placement,!0)}};Gn.family="",Gn.styles=p`
6422
+ */const R5=s2(class extends r2{constructor(n){if(super(n),n.type!==I1.PROPERTY&&n.type!==I1.ATTRIBUTE&&n.type!==I1.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!t6(n))throw Error("`live` bindings can only contain a single expression")}render(n){return n}update(n,[e]){if(e===p1||e===f)return e;const t=n.element,o=n.name;if(n.type===I1.PROPERTY){if(e===t[o])return p1}else if(n.type===I1.BOOLEAN_ATTRIBUTE){if(!!e===t.hasAttribute(o))return p1}else if(n.type===I1.ATTRIBUTE&&t.getAttribute(o)===e+"")return p1;return o6(n),e}});var n6=Object.defineProperty,i1=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&n6(e,t,i),i};let s6=0;const A5=n=>`${n}-${++s6}`,_a=80,r6=64,be=n=>n.constructor.family;function Zi(n){return n.closest(be(n))}const Gn=class Gn extends C{constructor(){super(...arguments),this.value="",this.placement="bottom-start",this.itemHeight=null,this._open=!1,this._highlighted=null,this._ignorePointer=!1,this._raf=0,this._anchorKey="",this._onItemSelected=e=>{var o;if(!this._open||(e.stopPropagation(),e.defaultPrevented))return;const t=((o=e.detail)==null?void 0:o.value)??"";this.onItemChosen(t)},this._onDocumentPointerDown=e=>{this._open&&(e.composedPath().includes(this)||this.closePanel())},this._onDocumentPointerMove=()=>{this._ignorePointer=!1}}get open(){return this._open}get family(){return be(this)}own(e){return Array.from(this.querySelectorAll(e)).filter(t=>t.closest(this.family)===this)}get field(){return this.own(`${this.family}-input, ${this.family}-textarea`)[0]??null}get content(){return this.own(`${this.family}-content`)[0]??null}get list(){return this.own(`${this.family}-list`)[0]??null}items(){return this.own(`${this.family}-item`)}get emptyElement(){return this.own(`${this.family}-empty`)[0]??null}connectedCallback(){super.connectedCallback(),this.addEventListener(`${this.family}-item-selected`,this._onItemSelected),document.addEventListener("pointerdown",this._onDocumentPointerDown),document.addEventListener("pointermove",this._onDocumentPointerMove,{capture:!0})}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(`${this.family}-item-selected`,this._onItemSelected),document.removeEventListener("pointerdown",this._onDocumentPointerDown),document.removeEventListener("pointermove",this._onDocumentPointerMove,{capture:!0}),this._stopLoop(),this._open=!1}updated(e){if(e.has("itemHeight")){const t=Number(this.itemHeight);t>0?this.style.setProperty(`--${this.family}-item-height`,`${t}px`):this.style.removeProperty(`--${this.family}-item-height`)}}render(){return d`<slot></slot>`}onOpened(){}onClosed(){}openPanel(e){var t;this._open||(t=this.field)!=null&&t.isDisabled||(this._open=!0,this._ignorePointer=!0,this.applyFilter(this.openQuery()),this._startLoop(),e==="first"?this.highlightFirst():e==="last"?this.highlightLast():this.onOpened(),this.syncField())}closePanel(){var t;if(!this._open)return;this._open=!1,this.clearHighlight(),this._stopLoop(),(t=this.content)==null||t.setVisible(!1);const e=this.emptyElement;e&&(e.hidden=!0),this.syncField(),this.onClosed()}itemMatches(e,t){var s;const o=t.labelText,i=(s=this.field)==null?void 0:s.filter;return typeof i=="function"?!!i({query:e,value:t.value,label:o}):o.toLowerCase().includes(e.toLowerCase())}applyFilter(e){var a;const t=this.items();let o=0;for(const c of t){const u=e===""||this.itemMatches(e,c);c.hidden=!u,u&&o++}this._updateStructure();const i=o===0,s=this.emptyElement;s&&(s.hidden=!(this._open&&this.emptyVisible(e,i)));const r=this.list;return r&&(r.scrollTop=0),(a=this.content)==null||a.setVisible(this._open&&this.panelVisible(i),!0),o}_updateStructure(){const e=`${this.family}-group`,t=`${this.family}-separator`,o=`${this.family}-item`,i=this.own(e);for(const r of i){const a=Array.from(r.querySelectorAll(o));r.hidden=a.length>0&&a.every(c=>c.hidden)}const s=this.own(`${e}, ${t}`);s.forEach((r,a)=>{if(r.localName!==t)return;const c=s.slice(0,a).filter(h=>h.localName===e),u=s.slice(a+1).find(h=>h.localName===e);if(!c.length&&!u){r.hidden=!1;return}r.hidden=!(c.some(h=>!h.hidden)&&u&&!u.hidden)})}get highlighted(){return this._highlighted}navigable(){return this.items().filter(e=>!e.hidden&&!e.disabled)}setHighlight(e,t=!0){this._highlighted&&this._highlighted!==e&&(this._highlighted.highlighted=!1),this._highlighted=e,e.highlighted=!0,t&&e.scrollIntoView({block:"nearest"}),this.syncField()}clearHighlight(){this._highlighted&&(this._highlighted.highlighted=!1),this._highlighted=null,this.syncField()}highlightFirst(){const e=this.navigable();e.length&&this.setHighlight(e[0])}highlightLast(){const e=this.navigable();e.length&&this.setHighlight(e[e.length-1])}moveHighlight(e){const t=this.navigable();if(!t.length)return;const o=this._highlighted?t.indexOf(this._highlighted):-1,i=o<0?0:(o+e+t.length)%t.length;this.setHighlight(t[i])}itemHovered(e){this._ignorePointer||e.disabled||!this._open||this._highlighted!==e&&this.setHighlight(e,!1)}ignorePointerUntilMove(){this._ignorePointer=!0}syncField(){var e;(e=this.field)==null||e.syncAria(this._open,this.list,this._highlighted)}labelFor(e){const t=this.items().find(o=>o.value===e);return t?t.labelText:e}get anchor(){return this.field??this}_startLoop(){this._stopLoop(),this._anchorKey="";const e=()=>{var o;const t=this.anchor;if(t){const i=t.getBoundingClientRect(),s=`${i.left},${i.top},${i.width},${i.height},${window.innerWidth},${window.innerHeight}`;s!==this._anchorKey&&(this._anchorKey=s,(o=this.content)==null||o.reposition(i,this.placement))}this._raf=requestAnimationFrame(e)};this._raf=requestAnimationFrame(e)}_stopLoop(){this._raf&&cancelAnimationFrame(this._raf),this._raf=0}reposition(){var t;const e=this.anchor;!e||!this._open||(t=this.content)==null||t.reposition(e.getBoundingClientRect(),this.placement,!0)}};Gn.family="",Gn.styles=p`
6423
6423
  :host { display: block; position: relative; font-family: var(--font-sans); }
6424
6424
  `;let qe=Gn;i1([l({reflect:!0})],qe.prototype,"value");i1([l()],qe.prototype,"placement");i1([l({attribute:"item-height"})],qe.prototype,"itemHeight");const S5=p`
6425
6425
  :host { display: block; font-family: var(--font-sans); }
@@ -6442,7 +6442,7 @@
6442
6442
  .control:focus { outline: none; border-color: var(--color-ring); }
6443
6443
  .control:active { box-shadow: 0 0 0 2px var(--color-ring-subtle); }
6444
6444
  .control::placeholder { color: var(--color-subtle-foreground); }
6445
- `,ul=class ul extends C{constructor(){super(...arguments),this.placeholder="",this.label="",this.filter=null,this._text=""}get root(){return Zi(this)}get control(){var e;return((e=this.renderRoot)==null?void 0:e.querySelector(".control"))??null}get isDisabled(){return!1}get text(){return this._text}set text(e){this._text=e;const t=this.control;t&&t.value!==e&&(t.value=e)}focusField(){var e;(e=this.control)==null||e.focus()}accessibleName(){var o,i;const e=this.closest("anduin-field"),t=((i=(o=e==null?void 0:e.querySelector("anduin-field-label"))==null?void 0:o.textContent)==null?void 0:i.trim())??"";return(this.label||this.getAttribute("aria-label")||t||this.placeholder||"").trim()}syncAria(e,t,o){const i=this.control;if(!i)return;i.setAttribute("aria-expanded",e?"true":"false"),"ariaControlsElements"in i&&(i.ariaControlsElements=e&&t?[t]:null),"ariaActiveDescendantElement"in i&&(i.ariaActiveDescendantElement=e?o:null);const s=this.accessibleName();s?i.setAttribute("aria-label",s):i.removeAttribute("aria-label"),t&&s&&t.setAttribute("aria-label",s)}_onFocus(){var e,t,o,i;this.syncAria(!!((e=this.root)!=null&&e.open),((t=this.root)==null?void 0:t.list)??null,((o=this.root)==null?void 0:o.highlighted)??null),(i=this.root)==null||i.fieldFocus()}_onInput(e){var t;this._text=e.target.value,(t=this.root)==null||t.fieldInput(this._text)}};ul.family="";let _e=ul;i1([l()],_e.prototype,"placeholder");i1([l()],_e.prototype,"label");i1([l({attribute:!1})],_e.prototype,"filter");i1([b()],_e.prototype,"_text");const qn=class qn extends C{constructor(){super(...arguments),this.width=null,this._visible=!1,this._natural=null}get visible(){return this._visible}get _panel(){var e;return((e=this.renderRoot)==null?void 0:e.querySelector(".panel"))??null}get _inner(){var e;return((e=this.renderRoot)==null?void 0:e.querySelector(".panel__inner"))??null}setVisible(e,t=!1){const o=e!==this._visible;this._visible=e,e&&(o||t)&&(this._natural=null,this.updateComplete.then(()=>{var i;return(i=Zi(this))==null?void 0:i.reposition()}))}reposition(e,t,o=!1){var _;const i=this._panel,s=this._inner;if(!i||!s||!this._visible)return;const r=((_=Zi(this))==null?void 0:_.list)??null,a=!!(r!=null&&r.hasAttribute("max-height")),c=(r==null?void 0:r.scrollTop)??0;(o||!this._natural)&&(s.style.maxHeight=a?"none":"",this._natural={width:s.offsetWidth,height:s.offsetHeight});const u=K7(e,this._natural,t),h=Math.max(u.room,r6+16),f=window.innerHeight*_a/100,m=getComputedStyle(s),v=["paddingTop","paddingBottom","borderTopWidth","borderBottomWidth"].reduce((x,y)=>x+(parseFloat(m[y])||0),0);s.style.maxHeight=`${Math.floor((a?h:Math.min(h,f))-v)}px`,r&&r.scrollTop!==c&&(r.scrollTop=c),D4(e,i,`${u.side}-${u.align}`,{flip:!1})}render(){const e=this.width?`--picker-content-width: ${this.width}px`:"";return d`
6445
+ `,ul=class ul extends C{constructor(){super(...arguments),this.placeholder="",this.label="",this.filter=null,this._text=""}get root(){return Zi(this)}get control(){var e;return((e=this.renderRoot)==null?void 0:e.querySelector(".control"))??null}get isDisabled(){return!1}get text(){return this._text}set text(e){this._text=e;const t=this.control;t&&t.value!==e&&(t.value=e)}focusField(){var e;(e=this.control)==null||e.focus()}accessibleName(){var o,i;const e=this.closest("anduin-field"),t=((i=(o=e==null?void 0:e.querySelector("anduin-field-label"))==null?void 0:o.textContent)==null?void 0:i.trim())??"";return(this.label||this.getAttribute("aria-label")||t||this.placeholder||"").trim()}syncAria(e,t,o){const i=this.control;if(!i)return;i.setAttribute("aria-expanded",e?"true":"false"),"ariaControlsElements"in i&&(i.ariaControlsElements=e&&t?[t]:null),"ariaActiveDescendantElement"in i&&(i.ariaActiveDescendantElement=e?o:null);const s=this.accessibleName();s?i.setAttribute("aria-label",s):i.removeAttribute("aria-label"),t&&s&&t.setAttribute("aria-label",s)}_onFocus(){var e,t,o,i;this.syncAria(!!((e=this.root)!=null&&e.open),((t=this.root)==null?void 0:t.list)??null,((o=this.root)==null?void 0:o.highlighted)??null),(i=this.root)==null||i.fieldFocus()}_onInput(e){var t;this._text=e.target.value,(t=this.root)==null||t.fieldInput(this._text)}};ul.family="";let _e=ul;i1([l()],_e.prototype,"placeholder");i1([l()],_e.prototype,"label");i1([l({attribute:!1})],_e.prototype,"filter");i1([b()],_e.prototype,"_text");const qn=class qn extends C{constructor(){super(...arguments),this.width=null,this._visible=!1,this._natural=null}get visible(){return this._visible}get _panel(){var e;return((e=this.renderRoot)==null?void 0:e.querySelector(".panel"))??null}get _inner(){var e;return((e=this.renderRoot)==null?void 0:e.querySelector(".panel__inner"))??null}setVisible(e,t=!1){const o=e!==this._visible;this._visible=e,e&&(o||t)&&(this._natural=null,this.updateComplete.then(()=>{var i;return(i=Zi(this))==null?void 0:i.reposition()}))}reposition(e,t,o=!1){var _;const i=this._panel,s=this._inner;if(!i||!s||!this._visible)return;const r=((_=Zi(this))==null?void 0:_.list)??null,a=!!(r!=null&&r.hasAttribute("max-height")),c=(r==null?void 0:r.scrollTop)??0;(o||!this._natural)&&(s.style.maxHeight=a?"none":"",this._natural={width:s.offsetWidth,height:s.offsetHeight});const u=K7(e,this._natural,t),h=Math.max(u.room,r6+16),g=window.innerHeight*_a/100,m=getComputedStyle(s),v=["paddingTop","paddingBottom","borderTopWidth","borderBottomWidth"].reduce((x,y)=>x+(parseFloat(m[y])||0),0);s.style.maxHeight=`${Math.floor((a?h:Math.min(h,g))-v)}px`,r&&r.scrollTop!==c&&(r.scrollTop=c),D4(e,i,`${u.side}-${u.align}`,{flip:!1})}render(){const e=this.width?`--picker-content-width: ${this.width}px`:"";return d`
6446
6446
  <div class="panel${this._visible?" panel--open":""}" part="panel">
6447
6447
  <div class="panel__inner" part="content" style=${e}><slot></slot></div>
6448
6448
  </div>
@@ -6483,7 +6483,7 @@
6483
6483
  overscroll-behavior: contain;
6484
6484
  max-height: var(--picker-list-max-height, none);
6485
6485
  }
6486
- `;let $t=Kn;i1([l({attribute:"max-height"})],$t.prototype,"maxHeight");i1([l({attribute:!1})],$t.prototype,"items");const jn=class jn extends C{constructor(){super(...arguments),this.value="",this.label=null,this.disabled=!1,this._highlighted=!1,this._onPointer=()=>{var e;this.disabled||(e=this.root)==null||e.itemHovered(this)},this._onMouseDown=e=>e.preventDefault(),this._onClick=()=>{this.disabled||this.dispatchEvent(new CustomEvent(`${be(this)}-item-selected`,{detail:{value:this.value},bubbles:!0,composed:!0,cancelable:!0}))}}get root(){return Zi(this)}get highlighted(){return this._highlighted}set highlighted(e){this._highlighted=e,this.toggleAttribute("data-highlighted",e)}get labelText(){if(this.label!=null&&this.label!=="")return this.label;let e="";return this.childNodes.forEach(t=>{t.nodeType===Node.ELEMENT_NODE&&t.getAttribute("slot")||(e+=t.textContent??"")}),e.replace(/\s+/g," ").trim()}connectedCallback(){super.connectedCallback(),this.setAttribute("role","option"),this.id||(this.id=A5(`${be(this)}-item`)),this.addEventListener("pointerenter",this._onPointer),this.addEventListener("pointermove",this._onPointer),this.addEventListener("mousedown",this._onMouseDown),this.addEventListener("click",this._onClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("pointerenter",this._onPointer),this.removeEventListener("pointermove",this._onPointer),this.removeEventListener("mousedown",this._onMouseDown),this.removeEventListener("click",this._onClick)}updated(e){e.has("disabled")&&(this.disabled?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled"))}renderStart(){return g}renderEnd(){return g}renderContent(){return d`<span class="label"><slot></slot></span>`}rowClass(){return"item"}render(){return d`
6486
+ `;let $t=Kn;i1([l({attribute:"max-height"})],$t.prototype,"maxHeight");i1([l({attribute:!1})],$t.prototype,"items");const jn=class jn extends C{constructor(){super(...arguments),this.value="",this.label=null,this.disabled=!1,this._highlighted=!1,this._onPointer=()=>{var e;this.disabled||(e=this.root)==null||e.itemHovered(this)},this._onMouseDown=e=>e.preventDefault(),this._onClick=()=>{this.disabled||this.dispatchEvent(new CustomEvent(`${be(this)}-item-selected`,{detail:{value:this.value},bubbles:!0,composed:!0,cancelable:!0}))}}get root(){return Zi(this)}get highlighted(){return this._highlighted}set highlighted(e){this._highlighted=e,this.toggleAttribute("data-highlighted",e)}get labelText(){if(this.label!=null&&this.label!=="")return this.label;let e="";return this.childNodes.forEach(t=>{t.nodeType===Node.ELEMENT_NODE&&t.getAttribute("slot")||(e+=t.textContent??"")}),e.replace(/\s+/g," ").trim()}connectedCallback(){super.connectedCallback(),this.setAttribute("role","option"),this.id||(this.id=A5(`${be(this)}-item`)),this.addEventListener("pointerenter",this._onPointer),this.addEventListener("pointermove",this._onPointer),this.addEventListener("mousedown",this._onMouseDown),this.addEventListener("click",this._onClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("pointerenter",this._onPointer),this.removeEventListener("pointermove",this._onPointer),this.removeEventListener("mousedown",this._onMouseDown),this.removeEventListener("click",this._onClick)}updated(e){e.has("disabled")&&(this.disabled?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled"))}renderStart(){return f}renderEnd(){return f}renderContent(){return d`<span class="label"><slot></slot></span>`}rowClass(){return"item"}render(){return d`
6487
6487
  <div class=${this.rowClass()} part="item">
6488
6488
  ${this.renderStart()}
6489
6489
  <div class="content">${this.renderContent()}</div>
@@ -6533,10 +6533,10 @@
6533
6533
  user-select: none;
6534
6534
  text-align: left;
6535
6535
  }
6536
- `;let fn=Yn;const Xn=class Xn extends C{connectedCallback(){super.connectedCallback(),this.setAttribute("role","separator"),this.setAttribute("aria-orientation","horizontal")}render(){return g}};Xn.family="",Xn.styles=p`
6536
+ `;let gn=Yn;const Xn=class Xn extends C{connectedCallback(){super.connectedCallback(),this.setAttribute("role","separator"),this.setAttribute("aria-orientation","horizontal")}render(){return f}};Xn.family="",Xn.styles=p`
6537
6537
  :host { display: block; height: 1px; background-color: var(--color-border); margin: 4px 12px; }
6538
6538
  :host([hidden]) { display: none; }
6539
- `;let gn=Xn;const Jn=class Jn extends C{connectedCallback(){super.connectedCallback(),this.setAttribute("role","status"),this.setAttribute("aria-live","polite"),this.hidden=!0}render(){return d`<slot></slot>`}};Jn.family="",Jn.styles=p`
6539
+ `;let fn=Xn;const Jn=class Jn extends C{connectedCallback(){super.connectedCallback(),this.setAttribute("role","status"),this.setAttribute("aria-live","polite"),this.hidden=!0}render(){return d`<slot></slot>`}};Jn.family="",Jn.styles=p`
6540
6540
  :host { display: block; padding: 8px; color: var(--color-subtle-foreground); text-align: center; }
6541
6541
  :host([hidden]) { display: none; }
6542
6542
  `;let vn=Jn;var l6=Object.defineProperty,a6=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&l6(e,t,i),i};const F3="change",d6="anduin-combobox-item-selected",ee="anduin-combobox",Qn=class Qn extends qe{constructor(){super(...arguments),this._query=""}firstUpdated(){this._syncSelection()}updated(e){super.updated(e),e.has("value")&&this.hasUpdated&&this._syncSelection()}_syncSelection(){for(const e of this.items())this.value&&e.value===this.value?e.setAttribute("aria-selected","true"):e.removeAttribute("aria-selected");if(this._open)this.applyFilter(this._query);else{const e=this.field;e&&(e.text=this.value?this.labelFor(this.value):"")}}openQuery(){return""}emptyVisible(e,t){return t&&e!==""}panelVisible(){return!0}onOpened(){requestAnimationFrame(()=>{const e=this.items().find(t=>this.value&&t.value===this.value&&!t.hidden);e==null||e.scrollIntoView({block:"nearest"})})}onClosed(){this._query="";const e=this.field;e&&(e.text=this.value?this.labelFor(this.value):"")}onItemChosen(e){this.value=e;for(const t of this.items())t.value===e?t.setAttribute("aria-selected","true"):t.removeAttribute("aria-selected");this.closePanel(),P(this,F3,e)}fieldFocus(){this.openPanel()}fieldInput(e){this._open||this.openPanel(),this._query=e,this.clearHighlight(),this.ignorePointerUntilMove(),this.applyFilter(e)}fieldKeyDown(e){switch(e.key){case"ArrowDown":e.preventDefault(),this._open?this.moveHighlight(1):this.openPanel("first");break;case"ArrowUp":e.preventDefault(),this._open?this.moveHighlight(-1):this.openPanel("last");break;case"Enter":{e.preventDefault();const t=this._highlighted;this._open&&t&&!t.disabled&&t.click();break}case"Escape":this._open&&(e.preventDefault(),e.stopPropagation(),this.closePanel());break;case"Tab":this.closePanel();break}}};Qn.family=ee,Qn.styles=p`
@@ -6590,7 +6590,7 @@
6590
6590
  .item--with-description .label { line-height: 16px; font-weight: 600; }
6591
6591
  .check { display: flex; align-items: center; flex-shrink: 0; color: var(--color-muted-foreground); opacity: 0; }
6592
6592
  :host([aria-selected='true']) .check { opacity: 1; }
6593
- `];let Ri=t2;a6([l()],Ri.prototype,"description");const fl=class fl extends Cn{};fl.family=ee;let xn=fl;const gl=class gl extends fn{};gl.family=ee;let wn=gl;const vl=class vl extends gn{};vl.family=ee;let Hn=vl;const ml=class ml extends vn{};ml.family=ee;let Ln=ml;const te=(n,e)=>{customElements.get(n)||customElements.define(n,e)};te("anduin-combobox",mn);te("anduin-combobox-input",bn);te("anduin-combobox-content",_n);te("anduin-combobox-list",yn);te("anduin-combobox-item",Ri);te("anduin-combobox-group",xn);te("anduin-combobox-label",wn);te("anduin-combobox-separator",Hn);te("anduin-combobox-empty",Ln);var c6=Object.defineProperty,ie=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&c6(e,t,i),i};const B3="change",N3="anduin-autocomplete-on-choose",U3="anduin-autocomplete-on-close",G3="anduin-autocomplete-on-blur",q3="anduin-autocomplete-on-submit",K3="anduin-autocomplete-on-before-input",h6="anduin-autocomplete-item-selected",_1="anduin-autocomplete",bl=class bl extends qe{constructor(){super(...arguments),this._current=""}firstUpdated(){this._current=this.value,this._syncText()}updated(e){super.updated(e),e.has("value")&&this.hasUpdated&&this.value!==this._current&&(this._current=this.value,this._syncText(),this._open&&(this.clearHighlight(),this.applyFilter(this._current)))}get text(){return this._current}_syncText(){const e=this.field;e&&e.text!==this._current&&(e.text=this._current);for(const t of this.own(`${_1}-clear`))t.hasText=this._current!==""}_commit(e){e!==this._current&&(this._current=e,this.value=e,this._syncText(),P(this,B3,e))}openQuery(){return this._current}emptyVisible(e,t){return t}panelVisible(e){return!e||!!this.emptyElement}onClosed(){this.dispatchEvent(new CustomEvent(U3,{detail:{value:void 0},bubbles:!1,composed:!0}))}onItemChosen(e){this.choose(e)}choose(e){var t;this._commit(this.labelFor(e)),P(this,N3,e),this.closePanel(),(t=this.field)==null||t.focusField()}get hasHighlight(){return!!this._highlighted}chooseHighlighted(){const e=this._highlighted;this._open&&e&&!e.disabled&&this.choose(e.value)}clear(){var e;this._current!==""&&(this._commit(""),this._open&&(this.clearHighlight(),this.applyFilter("")),(e=this.field)==null||e.focusField())}fieldFocus(){const e=this.field;(e!=null&&e.openOnFocus||this._current==="")&&this.openPanel()}fieldInput(e){this._commit(e),this._open?(this.clearHighlight(),this.ignorePointerUntilMove(),this.applyFilter(e)):this.openPanel()}};bl.family=_1;let kn=bl;const j3=p`
6593
+ `];let Ri=t2;a6([l()],Ri.prototype,"description");const gl=class gl extends Cn{};gl.family=ee;let xn=gl;const fl=class fl extends gn{};fl.family=ee;let wn=fl;const vl=class vl extends fn{};vl.family=ee;let Hn=vl;const ml=class ml extends vn{};ml.family=ee;let Ln=ml;const te=(n,e)=>{customElements.get(n)||customElements.define(n,e)};te("anduin-combobox",mn);te("anduin-combobox-input",bn);te("anduin-combobox-content",_n);te("anduin-combobox-list",yn);te("anduin-combobox-item",Ri);te("anduin-combobox-group",xn);te("anduin-combobox-label",wn);te("anduin-combobox-separator",Hn);te("anduin-combobox-empty",Ln);var c6=Object.defineProperty,ie=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&c6(e,t,i),i};const B3="change",N3="anduin-autocomplete-on-choose",U3="anduin-autocomplete-on-close",G3="anduin-autocomplete-on-blur",q3="anduin-autocomplete-on-submit",K3="anduin-autocomplete-on-before-input",h6="anduin-autocomplete-item-selected",_1="anduin-autocomplete",bl=class bl extends qe{constructor(){super(...arguments),this._current=""}firstUpdated(){this._current=this.value,this._syncText()}updated(e){super.updated(e),e.has("value")&&this.hasUpdated&&this.value!==this._current&&(this._current=this.value,this._syncText(),this._open&&(this.clearHighlight(),this.applyFilter(this._current)))}get text(){return this._current}_syncText(){const e=this.field;e&&e.text!==this._current&&(e.text=this._current);for(const t of this.own(`${_1}-clear`))t.hasText=this._current!==""}_commit(e){e!==this._current&&(this._current=e,this.value=e,this._syncText(),P(this,B3,e))}openQuery(){return this._current}emptyVisible(e,t){return t}panelVisible(e){return!e||!!this.emptyElement}onClosed(){this.dispatchEvent(new CustomEvent(U3,{detail:{value:void 0},bubbles:!1,composed:!0}))}onItemChosen(e){this.choose(e)}choose(e){var t;this._commit(this.labelFor(e)),P(this,N3,e),this.closePanel(),(t=this.field)==null||t.focusField()}get hasHighlight(){return!!this._highlighted}chooseHighlighted(){const e=this._highlighted;this._open&&e&&!e.disabled&&this.choose(e.value)}clear(){var e;this._current!==""&&(this._commit(""),this._open&&(this.clearHighlight(),this.applyFilter("")),(e=this.field)==null||e.focusField())}fieldFocus(){const e=this.field;(e!=null&&e.openOnFocus||this._current==="")&&this.openPanel()}fieldInput(e){this._commit(e),this._open?(this.clearHighlight(),this.ignorePointerUntilMove(),this.applyFilter(e)):this.openPanel()}};bl.family=_1;let kn=bl;const j3=p`
6594
6594
  .control--valid { border-color: var(--color-success); }
6595
6595
  .control--invalid { border-color: var(--color-destructive); }
6596
6596
  .control--warning { border-color: var(--color-warning-active); }
@@ -6702,12 +6702,12 @@
6702
6702
  }
6703
6703
  button:hover { color: var(--color-foreground); }
6704
6704
  button[hidden] { display: none; }
6705
- `;let Ai=wl;ie([b()],Ai.prototype,"hasText");const Hl=class Hl extends Mt{};Hl.family=_1;let En=Hl;const Ll=class Ll extends $t{};Ll.family=_1;let Mn=Ll;const i2=class i2 extends O1{constructor(){super(...arguments),this.startIcon=""}renderStart(){return this.startIcon?d`<span class="icon" aria-hidden="true"><anduin-icon name=${this.startIcon} size="16"></anduin-icon></span>`:g}};i2.family=_1,i2.styles=[O1.styles,p`
6705
+ `;let Ai=wl;ie([b()],Ai.prototype,"hasText");const Hl=class Hl extends Mt{};Hl.family=_1;let En=Hl;const Ll=class Ll extends $t{};Ll.family=_1;let Mn=Ll;const i2=class i2 extends O1{constructor(){super(...arguments),this.startIcon=""}renderStart(){return this.startIcon?d`<span class="icon" aria-hidden="true"><anduin-icon name=${this.startIcon} size="16"></anduin-icon></span>`:f}};i2.family=_1,i2.styles=[O1.styles,p`
6706
6706
  .item { min-height: 0; height: var(--anduin-autocomplete-item-height, 32px); }
6707
- `];let Si=i2;ie([l({attribute:"start-icon"})],Si.prototype,"startIcon");const kl=class kl extends Cn{};kl.family=_1;let $n=kl;const Vl=class Vl extends fn{};Vl.family=_1;let Zn=Vl;const El=class El extends gn{};El.family=_1;let Rn=El;const Ml=class Ml extends vn{};Ml.family=_1;let An=Ml;const V1=(n,e)=>{customElements.get(n)||customElements.define(n,e)};V1("anduin-autocomplete",kn);V1("anduin-autocomplete-input",Vn);V1("anduin-autocomplete-textarea",Zt);V1("anduin-autocomplete-clear",Ai);V1("anduin-autocomplete-content",En);V1("anduin-autocomplete-list",Mn);V1("anduin-autocomplete-item",Si);V1("anduin-autocomplete-group",$n);V1("anduin-autocomplete-label",Zn);V1("anduin-autocomplete-separator",Rn);V1("anduin-autocomplete-empty",An);var p6=Object.defineProperty,oe=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&p6(e,t,i),i};const W3="anduin-breadcrumb-link:navigate",Sn="anduin-breadcrumb-item",On="anduin-breadcrumb-link",t5="anduin-breadcrumb-page",ya="breadcrumb-prefix",Bi="data-anduin-breadcrumb-collapsed",qt="data-anduin-breadcrumb-last",i5=.5,xa=n=>n.length?n[n.length-1]:null,Y3=n=>(n.textContent??"").trim().replace(/\s+/g," ");class X3{constructor(e){this.host=e,this._ro=new ResizeObserver(()=>this.sync()),this._mo=new MutationObserver(()=>this.sync()),this._measure=null,this._target=null}observe(e,t){var o;e!==this._measure&&(this._ro.disconnect(),this._mo.disconnect(),this._measure=e,e&&(this._ro.observe(e),this._mo.observe(this.host,{childList:!0,subtree:!0,characterData:!0}))),t!==this._target&&((o=this._target)==null||o.removeAttribute("title")),this._target=t,this.sync()}disconnect(){this._ro.disconnect(),this._mo.disconnect(),this._measure=null,this._target=null}sync(){const e=this._measure,t=this._target;if(!e||!t)return;e.scrollWidth>e.clientWidth+i5&&!this.host.hasAttribute("title")?t.setAttribute("title",Y3(this.host)):t.removeAttribute("title")}}const $l=class $l extends C{constructor(){super(...arguments),this.navLabel=null}render(){return d`<nav class="breadcrumb" part="nav" aria-label=${this.navLabel||"Breadcrumb"}><slot></slot></nav>`}};$l.styles=p`
6707
+ `];let Si=i2;ie([l({attribute:"start-icon"})],Si.prototype,"startIcon");const kl=class kl extends Cn{};kl.family=_1;let $n=kl;const Vl=class Vl extends gn{};Vl.family=_1;let Zn=Vl;const El=class El extends fn{};El.family=_1;let Rn=El;const Ml=class Ml extends vn{};Ml.family=_1;let An=Ml;const V1=(n,e)=>{customElements.get(n)||customElements.define(n,e)};V1("anduin-autocomplete",kn);V1("anduin-autocomplete-input",Vn);V1("anduin-autocomplete-textarea",Zt);V1("anduin-autocomplete-clear",Ai);V1("anduin-autocomplete-content",En);V1("anduin-autocomplete-list",Mn);V1("anduin-autocomplete-item",Si);V1("anduin-autocomplete-group",$n);V1("anduin-autocomplete-label",Zn);V1("anduin-autocomplete-separator",Rn);V1("anduin-autocomplete-empty",An);var p6=Object.defineProperty,oe=(n,e,t,o)=>{for(var i=void 0,s=n.length-1,r;s>=0;s--)(r=n[s])&&(i=r(e,t,i)||i);return i&&p6(e,t,i),i};const W3="anduin-breadcrumb-link:navigate",Sn="anduin-breadcrumb-item",On="anduin-breadcrumb-link",t5="anduin-breadcrumb-page",ya="breadcrumb-prefix",Bi="data-anduin-breadcrumb-collapsed",qt="data-anduin-breadcrumb-last",i5=.5,xa=n=>n.length?n[n.length-1]:null,Y3=n=>(n.textContent??"").trim().replace(/\s+/g," ");class X3{constructor(e){this.host=e,this._ro=new ResizeObserver(()=>this.sync()),this._mo=new MutationObserver(()=>this.sync()),this._measure=null,this._target=null}observe(e,t){var o;e!==this._measure&&(this._ro.disconnect(),this._mo.disconnect(),this._measure=e,e&&(this._ro.observe(e),this._mo.observe(this.host,{childList:!0,subtree:!0,characterData:!0}))),t!==this._target&&((o=this._target)==null||o.removeAttribute("title")),this._target=t,this.sync()}disconnect(){this._ro.disconnect(),this._mo.disconnect(),this._measure=null,this._target=null}sync(){const e=this._measure,t=this._target;if(!e||!t)return;e.scrollWidth>e.clientWidth+i5&&!this.host.hasAttribute("title")?t.setAttribute("title",Y3(this.host)):t.removeAttribute("title")}}const $l=class $l extends C{constructor(){super(...arguments),this.navLabel=null}render(){return d`<nav class="breadcrumb" part="nav" aria-label=${this.navLabel||"Breadcrumb"}><slot></slot></nav>`}};$l.styles=p`
6708
6708
  :host { display: block; width: 100%; min-width: 0; }
6709
6709
  .breadcrumb { width: 100%; min-width: 0; }
6710
- `;let Oi=$l;oe([l({attribute:"aria-label"})],Oi.prototype,"navLabel");const Zl=class Zl extends C{constructor(){super(...arguments),this._collapsed=[],this._prefixItem=null,this._prefixOriginalSlot=null,this._frame=0,this._ro=new ResizeObserver(()=>this._scheduleLayout()),this._mo=new MutationObserver(()=>this._refresh())}connectedCallback(){super.connectedCallback(),this._refresh(),this._mo.observe(this,{childList:!0,subtree:!0,characterData:!0,attributes:!0,attributeFilter:["href","open-new-tab","name"]})}disconnectedCallback(){super.disconnectedCallback(),this._frame&&cancelAnimationFrame(this._frame),this._frame=0,this._ro.disconnect(),this._mo.disconnect();for(const e of this._children)e.removeAttribute(Bi),e.removeAttribute(qt);this._restorePrefix(),this._collapsed=[]}get _children(){return Array.from(this.children)}get _items(){return this._children.filter(e=>e.localName===Sn)}_refresh(){this._updatePrefix(),this._markLast(xa(this._items)),this._ro.disconnect(),this._ro.observe(this);for(const e of this._children)this._ro.observe(e);this._scheduleLayout()}_scheduleLayout(){this._frame||(this._frame=requestAnimationFrame(()=>{this._frame=0,this._layout()}))}relayout(){this._frame&&cancelAnimationFrame(this._frame),this._frame=0,this._layout()}_layout(){const e=this._children,t=this._items;this._markLast(xa(t));const o=this.clientWidth,i=e.reduce((h,f)=>h+Ni(f),0);if(o<=0||t.length<=2||i<=o+i5){for(const h of e)h.removeAttribute(Bi);this._collapsed=[];return}const s=t[0],r=this._overflowEl?Ni(this._overflowEl):0,a=Ni(s);let c=t.length-1;for(let h=2;h<t.length;h++){const f=e.slice(e.indexOf(t[h])).reduce((m,v)=>m+Ni(v),0);if(a+r+f<=o+i5){c=h;break}}const u=new Set(e.slice(e.indexOf(s)+1,e.indexOf(t[c])));for(const h of e)u.has(h)?h.setAttribute(Bi,""):h.removeAttribute(Bi);this._collapsed=t.slice(1,c).map(C6)}_updatePrefix(){const e=this._items[0]??null;e!==this._prefixItem&&(this._restorePrefix(),e&&(this._prefixItem=e,this._prefixOriginalSlot=e.getAttribute("slot"),e.setAttribute("slot",ya)))}_restorePrefix(){const e=this._prefixItem;e&&(this._prefixOriginalSlot===null?e.removeAttribute("slot"):e.setAttribute("slot",this._prefixOriginalSlot)),this._prefixItem=null,this._prefixOriginalSlot=null}_markLast(e){for(const t of this._children)t===e?t.hasAttribute(qt)||t.setAttribute(qt,""):t.hasAttribute(qt)&&t.removeAttribute(qt)}_onMenuItemClick(e,t){const o=t.metaKey||t.ctrlKey||t.shiftKey||t.altKey;e.href&&o||e.action&&(t.preventDefault(),e.action.click())}_stopMenuEvent(e){e.stopPropagation()}render(){const e=this._collapsed.length>0;return d`
6710
+ `;let Oi=$l;oe([l({attribute:"aria-label"})],Oi.prototype,"navLabel");const Zl=class Zl extends C{constructor(){super(...arguments),this._collapsed=[],this._prefixItem=null,this._prefixOriginalSlot=null,this._frame=0,this._ro=new ResizeObserver(()=>this._scheduleLayout()),this._mo=new MutationObserver(()=>this._refresh())}connectedCallback(){super.connectedCallback(),this._refresh(),this._mo.observe(this,{childList:!0,subtree:!0,characterData:!0,attributes:!0,attributeFilter:["href","open-new-tab","name"]})}disconnectedCallback(){super.disconnectedCallback(),this._frame&&cancelAnimationFrame(this._frame),this._frame=0,this._ro.disconnect(),this._mo.disconnect();for(const e of this._children)e.removeAttribute(Bi),e.removeAttribute(qt);this._restorePrefix(),this._collapsed=[]}get _children(){return Array.from(this.children)}get _items(){return this._children.filter(e=>e.localName===Sn)}_refresh(){this._updatePrefix(),this._markLast(xa(this._items)),this._ro.disconnect(),this._ro.observe(this);for(const e of this._children)this._ro.observe(e);this._scheduleLayout()}_scheduleLayout(){this._frame||(this._frame=requestAnimationFrame(()=>{this._frame=0,this._layout()}))}relayout(){this._frame&&cancelAnimationFrame(this._frame),this._frame=0,this._layout()}_layout(){const e=this._children,t=this._items;this._markLast(xa(t));const o=this.clientWidth,i=e.reduce((h,g)=>h+Ni(g),0);if(o<=0||t.length<=2||i<=o+i5){for(const h of e)h.removeAttribute(Bi);this._collapsed=[];return}const s=t[0],r=this._overflowEl?Ni(this._overflowEl):0,a=Ni(s);let c=t.length-1;for(let h=2;h<t.length;h++){const g=e.slice(e.indexOf(t[h])).reduce((m,v)=>m+Ni(v),0);if(a+r+g<=o+i5){c=h;break}}const u=new Set(e.slice(e.indexOf(s)+1,e.indexOf(t[c])));for(const h of e)u.has(h)?h.setAttribute(Bi,""):h.removeAttribute(Bi);this._collapsed=t.slice(1,c).map(C6)}_updatePrefix(){const e=this._items[0]??null;e!==this._prefixItem&&(this._restorePrefix(),e&&(this._prefixItem=e,this._prefixOriginalSlot=e.getAttribute("slot"),e.setAttribute("slot",ya)))}_restorePrefix(){const e=this._prefixItem;e&&(this._prefixOriginalSlot===null?e.removeAttribute("slot"):e.setAttribute("slot",this._prefixOriginalSlot)),this._prefixItem=null,this._prefixOriginalSlot=null}_markLast(e){for(const t of this._children)t===e?t.hasAttribute(qt)||t.setAttribute(qt,""):t.hasAttribute(qt)&&t.removeAttribute(qt)}_onMenuItemClick(e,t){const o=t.metaKey||t.ctrlKey||t.shiftKey||t.altKey;e.href&&o||e.action&&(t.preventDefault(),e.action.click())}_stopMenuEvent(e){e.stopPropagation()}render(){const e=this._collapsed.length>0;return d`
6711
6711
  <ol class="breadcrumb-list" part="list" role="list">
6712
6712
  <slot name=${ya}></slot>
6713
6713
  <li
@@ -6918,4 +6918,4 @@
6918
6918
  white-space: nowrap;
6919
6919
  }
6920
6920
  .breadcrumb-page__label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
6921
- `;let At=Al;oe([E(".breadcrumb-page")],At.prototype,"_inner");oe([E(".breadcrumb-page__label")],At.prototype,"_label");customElements.get("anduin-breadcrumb")||customElements.define("anduin-breadcrumb",Oi);customElements.get("anduin-breadcrumb-list")||customElements.define("anduin-breadcrumb-list",Rt);customElements.get(Sn)||customElements.define(Sn,Tn);customElements.get(On)||customElements.define(On,ye);customElements.get(t5)||customElements.define(t5,At);exports.ANDUIN_AVATAR_UID=H4;exports.AUTOCOMPLETE_BEFORE_INPUT=K3;exports.AUTOCOMPLETE_BLUR=G3;exports.AUTOCOMPLETE_CHANGE=B3;exports.AUTOCOMPLETE_CHOOSE=N3;exports.AUTOCOMPLETE_CLOSE=U3;exports.AUTOCOMPLETE_ITEM_SELECTED=h6;exports.AUTOCOMPLETE_SUBMIT=q3;exports.AnduinAiSpinner=De;exports.AnduinAutocomplete=kn;exports.AnduinAutocompleteClear=Ai;exports.AnduinAutocompleteContent=En;exports.AnduinAutocompleteEmpty=An;exports.AnduinAutocompleteGroup=$n;exports.AnduinAutocompleteInput=Vn;exports.AnduinAutocompleteItem=Si;exports.AnduinAutocompleteLabel=Zn;exports.AnduinAutocompleteList=Mn;exports.AnduinAutocompleteSeparator=Rn;exports.AnduinAutocompleteTextarea=Zt;exports.AnduinAvatar=o1;exports.AnduinAvatarBlock=L1;exports.AnduinBadge=oi;exports.AnduinBadgeCount=ct;exports.AnduinBreadcrumb=Oi;exports.AnduinBreadcrumbItem=Tn;exports.AnduinBreadcrumbLink=ye;exports.AnduinBreadcrumbList=Rt;exports.AnduinBreadcrumbPage=At;exports.AnduinButton=I;exports.AnduinCalendar=n1;exports.AnduinCallout=ni;exports.AnduinCheckbox=B1;exports.AnduinClipboard=ge;exports.AnduinClipboardIndicator=Ne;exports.AnduinClipboardTrigger=vi;exports.AnduinCollapsible=j1;exports.AnduinCollapsibleContent=Uo;exports.AnduinCollapsibleIcon=mi;exports.AnduinCollapsibleTrigger=No;exports.AnduinCombobox=mn;exports.AnduinComboboxContent=_n;exports.AnduinComboboxEmpty=Ln;exports.AnduinComboboxGroup=xn;exports.AnduinComboboxInput=bn;exports.AnduinComboboxItem=Ri;exports.AnduinComboboxLabel=wn;exports.AnduinComboboxList=yn;exports.AnduinComboboxSeparator=Hn;exports.AnduinDateInput=q;exports.AnduinDatePicker=K;exports.AnduinDateRange=H1;exports.AnduinDateRangeDefault=Io;exports.AnduinDateRangeEnd=Y4;exports.AnduinDateRangePanel=gi;exports.AnduinDateRangeStart=W4;exports.AnduinDialog=Ue;exports.AnduinDialogBody=xi;exports.AnduinDialogClose=Xo;exports.AnduinDialogContent=Ii;exports.AnduinDialogDescription=Yo;exports.AnduinDialogFooter=wi;exports.AnduinDialogHeader=yi;exports.AnduinDialogOverlay=Jo;exports.AnduinDialogTitle=Hi;exports.AnduinDialogTrigger=Wo;exports.AnduinDivider=ht;exports.AnduinDot=ut;exports.AnduinDrawer=f1;exports.AnduinDrawerClose=S4;exports.AnduinDropdown=O;exports.AnduinField=ri;exports.AnduinFieldDescription=Xi;exports.AnduinFieldError=Ji;exports.AnduinFieldGroup=Qi;exports.AnduinFieldLabel=Ct;exports.AnduinFileIcon=xt;exports.AnduinIcon=dt;exports.AnduinInlineEdit=z;exports.AnduinInput=S;exports.AnduinLoadingState=si;exports.AnduinMenu=C1;exports.AnduinMenuContent=yt;exports.AnduinMenuGroup=go;exports.AnduinMenuItem=F;exports.AnduinMenuLabel=vo;exports.AnduinMenuSeparator=mo;exports.AnduinMenuSub=ci;exports.AnduinMenuSubContent=bo;exports.AnduinMenuSubTrigger=fe;exports.AnduinMenuTrigger=fo;exports.AnduinModal=y4;exports.AnduinModalClose=x4;exports.AnduinNavigation=A1;exports.AnduinNavigationBar=kt;exports.AnduinNavigationBarItem=K1;exports.AnduinNavigationItem=w1;exports.AnduinNonIdealState=Go;exports.AnduinNonIdealStateAction=jo;exports.AnduinNonIdealStateDescription=Ko;exports.AnduinNonIdealStateIcon=qo;exports.AnduinNonIdealStateTitle=bi;exports.AnduinPagination=G1;exports.AnduinPaginationFirstPage=G4;exports.AnduinPaginationLastPage=q4;exports.AnduinPopover=G;exports.AnduinPopoverClose=Co;exports.AnduinPopoverContent=Ce;exports.AnduinPopoverTitle=uo;exports.AnduinPopoverTrigger=ho;exports.AnduinProgress=pt;exports.AnduinRadio=R1;exports.AnduinRadioGroup=Ie;exports.AnduinResizableHandle=Be;exports.AnduinResizablePanel=Fe;exports.AnduinResizablePanelGroup=ui;exports.AnduinSelect=S1;exports.AnduinSelectClear=Ei;exports.AnduinSelectContent=ki;exports.AnduinSelectEmpty=en;exports.AnduinSelectFooter=rn;exports.AnduinSelectGroup=tn;exports.AnduinSelectHeader=sn;exports.AnduinSelectInput=Ge;exports.AnduinSelectItem=s1;exports.AnduinSelectLabel=on;exports.AnduinSelectList=Vt;exports.AnduinSelectSelectedLabel=Vi;exports.AnduinSelectSeparator=nn;exports.AnduinSelectTrigger=Li;exports.AnduinSheet=me;exports.AnduinSheetClose=T3;exports.AnduinSheetContent=r1;exports.AnduinSheetDescription=un;exports.AnduinSheetDockToggle=D3;exports.AnduinSheetDockToggleOff=I3;exports.AnduinSheetDockToggleOn=z3;exports.AnduinSheetFooter=pn;exports.AnduinSheetHeader=cn;exports.AnduinSheetTitle=hn;exports.AnduinSheetTrigger=$i;exports.AnduinSidebar=Zo;exports.AnduinSidebarAction=To;exports.AnduinSidebarBadge=Do;exports.AnduinSidebarContent=Ro;exports.AnduinSidebarFooter=fi;exports.AnduinSidebarGroup=Ao;exports.AnduinSidebarGroupLabel=So;exports.AnduinSidebarHeader=Ci;exports.AnduinSidebarMenu=Oo;exports.AnduinSidebarMenuItem=q1;exports.AnduinSidebarSeparator=Po;exports.AnduinSkeleton=M1;exports.AnduinSparkleSpinner=at;exports.AnduinSpinner=lt;exports.AnduinSuggestion=T;exports.AnduinSwitch=b1;exports.AnduinSwitcher=Ht;exports.AnduinTabContent=vt;exports.AnduinTabTrigger=$1;exports.AnduinTable=H;exports.AnduinTabs=Pe;exports.AnduinTabsList=gt;exports.AnduinTag=Z1;exports.AnduinTagClose=io;exports.AnduinTagsInput=U;exports.AnduinTagsInputClear=_t;exports.AnduinTagsInputEmpty=so;exports.AnduinTagsInputFooter=ro;exports.AnduinTagsInputGroup=oo;exports.AnduinTagsInputInput=ze;exports.AnduinTagsInputLabel=no;exports.AnduinTagsInputList=bt;exports.AnduinTagsInputOption=pe;exports.AnduinTagsInputSuggestions=N1;exports.AnduinTextarea=m1;exports.AnduinTimeline=Lo;exports.AnduinTimelineDate=Vo;exports.AnduinTimelineGroup=Mo;exports.AnduinTimelineItem=ko;exports.AnduinTimelineLabel=$o;exports.AnduinTimelineTitle=Eo;exports.AnduinToast=U1;exports.AnduinToaster=wt;exports.AnduinToggleGroup=y1;exports.AnduinToggleGroupItem=x1;exports.AnduinTooltip=ft;exports.AnduinTooltipContent=to;exports.AnduinTooltipTrigger=eo;exports.AnduinTruncated=ve;exports.AnduinWell=li;exports.AnduinWellClose=ao;exports.BADGE_STYLES=d5;exports.BREADCRUMB_LINK_NAVIGATE=W3;exports.CALENDAR_CHANGE=Lt;exports.CALENDAR_DAY_HOVER=zo;exports.CHECKBOX_CHANGE=Ba;exports.CLIPBOARD_RESET_MS=a3;exports.COLLAPSIBLE_DEFAULT_DURATION_MS=p3;exports.COLLAPSIBLE_OPEN_CHANGE=u3;exports.COMBOBOX_CHANGE=F3;exports.COMBOBOX_ITEM_SELECTED=d6;exports.DATE_INPUT_CHANGE=Fo;exports.DATE_PICKER_CHANGE=X4;exports.DATE_RANGE_CHANGE=j4;exports.DIALOG_ON_CLOSE=_3;exports.DIALOG_ON_OPEN=b3;exports.DIALOG_OPEN_CHANGE=m3;exports.DRAWER_AFTER_CLOSE_EVENT=Ki;exports.DRAWER_CLOSE_EVENT=nt;exports.DROPDOWN_CHANGE=F2;exports.FIELD_LABEL_CLICK=C5;exports.FIELD_LABEL_CLICK_COORDINATED=F1;exports.FILE_ICONS=E4;exports.INLINE_EDIT_CANCEL=qa;exports.INLINE_EDIT_EDIT=Ka;exports.INLINE_EDIT_SAVE=Ga;exports.INPUT_CHANGE=A2;exports.INPUT_CLEAR=Na;exports.MENU_ITEM_CLICK=_o;exports.MENU_ITEM_COMMIT=yo;exports.MENU_ITEM_SELECTED=g4;exports.MENU_OPEN_CHANGE=v4;exports.MODAL_AFTER_CLOSE_EVENT=qi;exports.MODAL_CLOSE_EVENT=de;exports.NAVIGATION_BAR_CSS_VARS=u9;exports.NAVIGATION_BAR_VALUE_CHANGE=l3;exports.NAVIGATION_CHANGE=F4;exports.NAVIGATION_ITEM_CLICK=hi;exports.PAGINATION_CHANGE=U4;exports.PAGINATION_JUMP=Ho;exports.POPOVER_CLOSE=po;exports.POPOVER_DESIGN_OPEN_CHANGE=u4;exports.POPOVER_ON_CLOSE=C4;exports.POPOVER_ON_OPEN=p4;exports.POPOVER_OPEN_CHANGE=di;exports.RADIO_CHANGE=wo;exports.RADIO_GROUP_CHANGE=w4;exports.RESIZE_EVENT=B4;exports.SELECT_CHANGE=K2;exports.SELECT_CLOSE=j2;exports.SELECT_ITEM_SELECTED=Qo;exports.SHEET_COMMAND=Z5;exports.SHEET_DOCK_CHANGE=S3;exports.SHEET_DOCK_REGISTER=dn;exports.SHEET_DOCK_TOGGLE=an;exports.SHEET_ON_CLOSE=Q2;exports.SHEET_ON_OPEN=J2;exports.SHEET_ON_RESIZE=X2;exports.SHEET_OPEN_CHANGE=O3;exports.SHEET_REGISTER=p2;exports.SIDEBAR_SELECT=K4;exports.SUGGESTION_CHANGE=ji;exports.SUGGESTION_CLEAR=I4;exports.SUGGESTION_SELECT=z4;exports.SWITCHER_CHANGE=R4;exports.SWITCH_CHECKED_CHANGE=A4;exports.TABLE_CELL_CONTEXT_MENU=o3;exports.TABLE_COLUMN_CLICK=e3;exports.TABLE_COLUMN_RESIZE=B2;exports.TABLE_GROUP_TOGGLE=r3;exports.TABLE_ROW_CLICK=t3;exports.TABLE_ROW_COLLAPSE=s3;exports.TABLE_ROW_EXPAND=n3;exports.TABLE_SELECTION_CHANGE=i3;exports.TABLE_SORT=Q4;exports.TAB_CHANGE=Wa;exports.TAB_TRIGGER_CLICK=m5;exports.TAB_VALUE_CHANGED=Pi;exports.TAGS_INPUT_BLUR=Ja;exports.TAGS_INPUT_SUBMIT=Qa;exports.TAGS_INPUT_VALUE_CHANGE=Xa;exports.TAG_CLOSE_CLICK=b5;exports.TEXTAREA_CHANGE=ja;exports.TOGGLE_GROUP_CHANGE=e4;exports.TOGGLE_GROUP_ITEM_CHANGE=t4;exports.TOGGLE_GROUP_ITEM_CLICK=lo;exports.TOGGLE_GROUP_ITEM_DESELECT=o4;exports.TOGGLE_GROUP_ITEM_SELECT=i4;exports.TOOLTIP_CONTENT_POPUP_MOUNTED=f5;exports.TOOLTIP_CONTENT_POPUP_UNMOUNTED=g5;exports.TOOLTIP_HIDE=Tt;exports.TOOLTIP_SHOW=Ot;exports.TOOLTIP_TRIGGER_MOUNTED=l2;exports.TOOLTIP_VISIBILITY_CHANGED=v5;exports.WELL_CLOSE_CLICK=n4;exports.addMonths=z1;exports.avatarColorForUid=k4;exports.clipboardTooltipText=h3;exports.collapsibleDurationOf=C3;exports.copyActionName=V5;exports.designBooleanDefaultTrue=C2;exports.designInitials=V4;exports.dispatchSheetCommand=Et;exports.formatISODate=ae;exports.getBadgeVariantClass=c5;exports.murmurStringHash=L4;exports.normalizedHeadingLevel=v3;exports.normalizedLineClamp=f3;exports.parseISODate=X;exports.resolveFileIcon=M4;exports.startOfToday=$e;exports.toast=P7;
6921
+ `;let At=Al;oe([E(".breadcrumb-page")],At.prototype,"_inner");oe([E(".breadcrumb-page__label")],At.prototype,"_label");customElements.get("anduin-breadcrumb")||customElements.define("anduin-breadcrumb",Oi);customElements.get("anduin-breadcrumb-list")||customElements.define("anduin-breadcrumb-list",Rt);customElements.get(Sn)||customElements.define(Sn,Tn);customElements.get(On)||customElements.define(On,ye);customElements.get(t5)||customElements.define(t5,At);exports.ANDUIN_AVATAR_UID=H4;exports.AUTOCOMPLETE_BEFORE_INPUT=K3;exports.AUTOCOMPLETE_BLUR=G3;exports.AUTOCOMPLETE_CHANGE=B3;exports.AUTOCOMPLETE_CHOOSE=N3;exports.AUTOCOMPLETE_CLOSE=U3;exports.AUTOCOMPLETE_ITEM_SELECTED=h6;exports.AUTOCOMPLETE_SUBMIT=q3;exports.AnduinAiSpinner=De;exports.AnduinAutocomplete=kn;exports.AnduinAutocompleteClear=Ai;exports.AnduinAutocompleteContent=En;exports.AnduinAutocompleteEmpty=An;exports.AnduinAutocompleteGroup=$n;exports.AnduinAutocompleteInput=Vn;exports.AnduinAutocompleteItem=Si;exports.AnduinAutocompleteLabel=Zn;exports.AnduinAutocompleteList=Mn;exports.AnduinAutocompleteSeparator=Rn;exports.AnduinAutocompleteTextarea=Zt;exports.AnduinAvatar=o1;exports.AnduinAvatarBlock=L1;exports.AnduinBadge=oi;exports.AnduinBadgeCount=ct;exports.AnduinBreadcrumb=Oi;exports.AnduinBreadcrumbItem=Tn;exports.AnduinBreadcrumbLink=ye;exports.AnduinBreadcrumbList=Rt;exports.AnduinBreadcrumbPage=At;exports.AnduinButton=I;exports.AnduinCalendar=n1;exports.AnduinCallout=ni;exports.AnduinCheckbox=B1;exports.AnduinClipboard=fe;exports.AnduinClipboardIndicator=Ne;exports.AnduinClipboardTrigger=vi;exports.AnduinCollapsible=j1;exports.AnduinCollapsibleContent=Uo;exports.AnduinCollapsibleIcon=mi;exports.AnduinCollapsibleTrigger=No;exports.AnduinCombobox=mn;exports.AnduinComboboxContent=_n;exports.AnduinComboboxEmpty=Ln;exports.AnduinComboboxGroup=xn;exports.AnduinComboboxInput=bn;exports.AnduinComboboxItem=Ri;exports.AnduinComboboxLabel=wn;exports.AnduinComboboxList=yn;exports.AnduinComboboxSeparator=Hn;exports.AnduinDateInput=q;exports.AnduinDatePicker=K;exports.AnduinDateRange=H1;exports.AnduinDateRangeDefault=Io;exports.AnduinDateRangeEnd=Y4;exports.AnduinDateRangePanel=fi;exports.AnduinDateRangeStart=W4;exports.AnduinDialog=Ue;exports.AnduinDialogBody=xi;exports.AnduinDialogClose=Xo;exports.AnduinDialogContent=Ii;exports.AnduinDialogDescription=Yo;exports.AnduinDialogFooter=wi;exports.AnduinDialogHeader=yi;exports.AnduinDialogOverlay=Jo;exports.AnduinDialogTitle=Hi;exports.AnduinDialogTrigger=Wo;exports.AnduinDivider=ht;exports.AnduinDot=ut;exports.AnduinDrawer=g1;exports.AnduinDrawerClose=S4;exports.AnduinDropdown=O;exports.AnduinField=ri;exports.AnduinFieldDescription=Xi;exports.AnduinFieldError=Ji;exports.AnduinFieldGroup=Qi;exports.AnduinFieldLabel=Ct;exports.AnduinFileIcon=xt;exports.AnduinIcon=dt;exports.AnduinInlineEdit=z;exports.AnduinInput=S;exports.AnduinLoadingState=si;exports.AnduinMenu=C1;exports.AnduinMenuContent=yt;exports.AnduinMenuGroup=fo;exports.AnduinMenuItem=F;exports.AnduinMenuLabel=vo;exports.AnduinMenuSeparator=mo;exports.AnduinMenuSub=ci;exports.AnduinMenuSubContent=bo;exports.AnduinMenuSubTrigger=ge;exports.AnduinMenuTrigger=go;exports.AnduinModal=y4;exports.AnduinModalClose=x4;exports.AnduinNavigation=A1;exports.AnduinNavigationBar=kt;exports.AnduinNavigationBarItem=K1;exports.AnduinNavigationItem=w1;exports.AnduinNonIdealState=Go;exports.AnduinNonIdealStateAction=jo;exports.AnduinNonIdealStateDescription=Ko;exports.AnduinNonIdealStateIcon=qo;exports.AnduinNonIdealStateTitle=bi;exports.AnduinPagination=G1;exports.AnduinPaginationFirstPage=G4;exports.AnduinPaginationLastPage=q4;exports.AnduinPopover=G;exports.AnduinPopoverClose=Co;exports.AnduinPopoverContent=Ce;exports.AnduinPopoverTitle=uo;exports.AnduinPopoverTrigger=ho;exports.AnduinProgress=pt;exports.AnduinRadio=R1;exports.AnduinRadioGroup=Ie;exports.AnduinResizableHandle=Be;exports.AnduinResizablePanel=Fe;exports.AnduinResizablePanelGroup=ui;exports.AnduinSelect=S1;exports.AnduinSelectClear=Ei;exports.AnduinSelectContent=ki;exports.AnduinSelectEmpty=en;exports.AnduinSelectFooter=rn;exports.AnduinSelectGroup=tn;exports.AnduinSelectHeader=sn;exports.AnduinSelectInput=Ge;exports.AnduinSelectItem=s1;exports.AnduinSelectLabel=on;exports.AnduinSelectList=Vt;exports.AnduinSelectSelectedLabel=Vi;exports.AnduinSelectSeparator=nn;exports.AnduinSelectTrigger=Li;exports.AnduinSheet=me;exports.AnduinSheetClose=T3;exports.AnduinSheetContent=r1;exports.AnduinSheetDescription=un;exports.AnduinSheetDockToggle=D3;exports.AnduinSheetDockToggleOff=I3;exports.AnduinSheetDockToggleOn=z3;exports.AnduinSheetFooter=pn;exports.AnduinSheetHeader=cn;exports.AnduinSheetTitle=hn;exports.AnduinSheetTrigger=$i;exports.AnduinSidebar=Zo;exports.AnduinSidebarAction=To;exports.AnduinSidebarBadge=Do;exports.AnduinSidebarContent=Ro;exports.AnduinSidebarFooter=gi;exports.AnduinSidebarGroup=Ao;exports.AnduinSidebarGroupLabel=So;exports.AnduinSidebarHeader=Ci;exports.AnduinSidebarMenu=Oo;exports.AnduinSidebarMenuItem=q1;exports.AnduinSidebarSeparator=Po;exports.AnduinSkeleton=M1;exports.AnduinSparkleSpinner=at;exports.AnduinSpinner=lt;exports.AnduinSuggestion=T;exports.AnduinSwitch=b1;exports.AnduinSwitcher=Ht;exports.AnduinTabContent=vt;exports.AnduinTabTrigger=$1;exports.AnduinTable=H;exports.AnduinTabs=Pe;exports.AnduinTabsList=ft;exports.AnduinTag=Z1;exports.AnduinTagClose=io;exports.AnduinTagsInput=U;exports.AnduinTagsInputClear=_t;exports.AnduinTagsInputEmpty=so;exports.AnduinTagsInputFooter=ro;exports.AnduinTagsInputGroup=oo;exports.AnduinTagsInputInput=ze;exports.AnduinTagsInputLabel=no;exports.AnduinTagsInputList=bt;exports.AnduinTagsInputOption=pe;exports.AnduinTagsInputSuggestions=N1;exports.AnduinTextarea=m1;exports.AnduinTimeline=Lo;exports.AnduinTimelineDate=Vo;exports.AnduinTimelineGroup=Mo;exports.AnduinTimelineItem=ko;exports.AnduinTimelineLabel=$o;exports.AnduinTimelineTitle=Eo;exports.AnduinToast=U1;exports.AnduinToaster=wt;exports.AnduinToggleGroup=y1;exports.AnduinToggleGroupItem=x1;exports.AnduinTooltip=gt;exports.AnduinTooltipContent=to;exports.AnduinTooltipTrigger=eo;exports.AnduinTruncated=ve;exports.AnduinWell=li;exports.AnduinWellClose=ao;exports.BADGE_STYLES=d5;exports.BREADCRUMB_LINK_NAVIGATE=W3;exports.CALENDAR_CHANGE=Lt;exports.CALENDAR_DAY_HOVER=zo;exports.CHECKBOX_CHANGE=Ba;exports.CLIPBOARD_RESET_MS=a3;exports.COLLAPSIBLE_DEFAULT_DURATION_MS=p3;exports.COLLAPSIBLE_OPEN_CHANGE=u3;exports.COMBOBOX_CHANGE=F3;exports.COMBOBOX_ITEM_SELECTED=d6;exports.DATE_INPUT_CHANGE=Fo;exports.DATE_PICKER_CHANGE=X4;exports.DATE_RANGE_CHANGE=j4;exports.DIALOG_ON_CLOSE=_3;exports.DIALOG_ON_OPEN=b3;exports.DIALOG_OPEN_CHANGE=m3;exports.DRAWER_AFTER_CLOSE_EVENT=Ki;exports.DRAWER_CLOSE_EVENT=nt;exports.DROPDOWN_CHANGE=F2;exports.FIELD_LABEL_CLICK=C5;exports.FIELD_LABEL_CLICK_COORDINATED=F1;exports.FILE_ICONS=E4;exports.INLINE_EDIT_CANCEL=qa;exports.INLINE_EDIT_EDIT=Ka;exports.INLINE_EDIT_SAVE=Ga;exports.INPUT_CHANGE=A2;exports.INPUT_CLEAR=Na;exports.MENU_ITEM_CLICK=_o;exports.MENU_ITEM_COMMIT=yo;exports.MENU_ITEM_SELECTED=f4;exports.MENU_OPEN_CHANGE=v4;exports.MODAL_AFTER_CLOSE_EVENT=qi;exports.MODAL_CLOSE_EVENT=de;exports.NAVIGATION_BAR_CSS_VARS=u9;exports.NAVIGATION_BAR_VALUE_CHANGE=l3;exports.NAVIGATION_CHANGE=F4;exports.NAVIGATION_ITEM_CLICK=hi;exports.PAGINATION_CHANGE=U4;exports.PAGINATION_JUMP=Ho;exports.POPOVER_CLOSE=po;exports.POPOVER_DESIGN_OPEN_CHANGE=u4;exports.POPOVER_ON_CLOSE=C4;exports.POPOVER_ON_OPEN=p4;exports.POPOVER_OPEN_CHANGE=di;exports.RADIO_CHANGE=wo;exports.RADIO_GROUP_CHANGE=w4;exports.RESIZE_EVENT=B4;exports.SELECT_CHANGE=K2;exports.SELECT_CLOSE=j2;exports.SELECT_ITEM_SELECTED=Qo;exports.SHEET_COMMAND=Z5;exports.SHEET_DOCK_CHANGE=S3;exports.SHEET_DOCK_REGISTER=dn;exports.SHEET_DOCK_TOGGLE=an;exports.SHEET_ON_CLOSE=Q2;exports.SHEET_ON_OPEN=J2;exports.SHEET_ON_RESIZE=X2;exports.SHEET_OPEN_CHANGE=O3;exports.SHEET_REGISTER=p2;exports.SIDEBAR_SELECT=K4;exports.SUGGESTION_CHANGE=ji;exports.SUGGESTION_CLEAR=I4;exports.SUGGESTION_SELECT=z4;exports.SWITCHER_CHANGE=R4;exports.SWITCH_CHECKED_CHANGE=A4;exports.TABLE_CELL_CONTEXT_MENU=o3;exports.TABLE_COLUMN_CLICK=e3;exports.TABLE_COLUMN_RESIZE=B2;exports.TABLE_GROUP_TOGGLE=r3;exports.TABLE_ROW_CLICK=t3;exports.TABLE_ROW_COLLAPSE=s3;exports.TABLE_ROW_EXPAND=n3;exports.TABLE_SELECTION_CHANGE=i3;exports.TABLE_SORT=Q4;exports.TAB_CHANGE=Wa;exports.TAB_TRIGGER_CLICK=m5;exports.TAB_VALUE_CHANGED=Pi;exports.TAGS_INPUT_BLUR=Ja;exports.TAGS_INPUT_SUBMIT=Qa;exports.TAGS_INPUT_VALUE_CHANGE=Xa;exports.TAG_CLOSE_CLICK=b5;exports.TEXTAREA_CHANGE=ja;exports.TOGGLE_GROUP_CHANGE=e4;exports.TOGGLE_GROUP_ITEM_CHANGE=t4;exports.TOGGLE_GROUP_ITEM_CLICK=lo;exports.TOGGLE_GROUP_ITEM_DESELECT=o4;exports.TOGGLE_GROUP_ITEM_SELECT=i4;exports.TOOLTIP_CONTENT_POPUP_MOUNTED=g5;exports.TOOLTIP_CONTENT_POPUP_UNMOUNTED=f5;exports.TOOLTIP_HIDE=Tt;exports.TOOLTIP_SHOW=Ot;exports.TOOLTIP_TRIGGER_MOUNTED=l2;exports.TOOLTIP_VISIBILITY_CHANGED=v5;exports.WELL_CLOSE_CLICK=n4;exports.addMonths=z1;exports.avatarColorForUid=k4;exports.clipboardTooltipText=h3;exports.collapsibleDurationOf=C3;exports.copyActionName=V5;exports.designBooleanDefaultTrue=C2;exports.designInitials=V4;exports.dispatchSheetCommand=Et;exports.formatISODate=ae;exports.getBadgeVariantClass=c5;exports.murmurStringHash=L4;exports.normalizedHeadingLevel=v3;exports.normalizedLineClamp=g3;exports.parseISODate=X;exports.resolveFileIcon=M4;exports.startOfToday=$e;exports.toast=P7;