@momentum-design/components 0.28.4 → 0.28.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/index.js +63 -44
- package/dist/browser/index.js.map +3 -3
- package/dist/components/input/input.component.js +1 -1
- package/dist/components/input/input.styles.js +3 -3
- package/dist/components/link/link.component.js +5 -1
- package/dist/components/link/link.styles.js +23 -15
- package/dist/components/virtualizedlist/virtualizedlist.component.d.ts +13 -3
- package/dist/components/virtualizedlist/virtualizedlist.component.js +42 -24
- package/dist/components/virtualizedlist/virtualizedlist.helper.test.d.ts +2 -2
- package/dist/components/virtualizedlist/virtualizedlist.helper.test.js +7 -7
- package/dist/custom-elements.json +131 -215
- package/dist/react/index.d.ts +1 -1
- package/dist/react/index.js +1 -1
- package/dist/utils/styles/index.js +9 -2
- package/package.json +1 -1
- package/dist/components/virtualizedlist/virtualizedlist.test.component.d.ts +0 -17
- package/dist/components/virtualizedlist/virtualizedlist.test.component.js +0 -79
package/dist/browser/index.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";(()=>{var Fs=Object.defineProperty;var Bs=Object.getOwnPropertyDescriptor;var c=(o,t,e,r)=>{for(var i=r>1?void 0:r?Bs(t,e):t,n=o.length-1,s;n>=0;n--)(s=o[n])&&(i=(r?s(t,e,i):s(i))||i);return r&&i&&Fs(t,e,i),i};var ar=globalThis,lr=ar.ShadowRoot&&(ar.ShadyCSS===void 0||ar.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,oo=Symbol(),mi=new WeakMap,Lt=class{constructor(t,e,r){if(this._$cssResult$=!0,r!==oo)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o,e=this.t;if(lr&&t===void 0){let r=e!==void 0&&e.length===1;r&&(t=mi.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),r&&mi.set(e,t))}return t}toString(){return this.cssText}},hi=o=>new Lt(typeof o=="string"?o:o+"",void 0,oo),g=(o,...t)=>{let e=o.length===1?o[0]:t.reduce((r,i,n)=>r+(s=>{if(s._$cssResult$===!0)return s.cssText;if(typeof s=="number")return s;throw Error("Value passed to 'css' function must be a 'css' function result: "+s+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+o[n+1],o[0]);return new Lt(e,o,oo)},io=(o,t)=>{if(lr)o.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(let e of t){let r=document.createElement("style"),i=ar.litNonce;i!==void 0&&r.setAttribute("nonce",i),r.textContent=e.cssText,o.appendChild(r)}},cr=lr?o=>o:o=>o instanceof CSSStyleSheet?(t=>{let e="";for(let r of t.cssRules)e+=r.cssText;return hi(e)})(o):o;var{is:Gs,defineProperty:qs,getOwnPropertyDescriptor:Ys,getOwnPropertyNames:Ws,getOwnPropertySymbols:Xs,getPrototypeOf:Zs}=Object,Ne=globalThis,pi=Ne.trustedTypes,js=pi?pi.emptyScript:"",no=Ne.reactiveElementPolyfillSupport,Nt=(o,t)=>o,Ot={toAttribute(o,t){switch(t){case Boolean:o=o?js:null;break;case Object:case Array:o=o==null?o:JSON.stringify(o)}return o},fromAttribute(o,t){let e=o;switch(t){case Boolean:e=o!==null;break;case Number:e=o===null?null:Number(o);break;case Object:case Array:try{e=JSON.parse(o)}catch{e=null}}return e}},dr=(o,t)=>!Gs(o,t),ui={attribute:!0,type:String,converter:Ot,reflect:!1,hasChanged:dr},fi,gi;(fi=Symbol.metadata)!=null||(Symbol.metadata=Symbol("metadata")),(gi=Ne.litPropertyMetadata)!=null||(Ne.litPropertyMetadata=new WeakMap);var be=class extends HTMLElement{static addInitializer(t){var e;this._$Ei(),((e=this.l)!=null?e:this.l=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=ui){if(e.state&&(e.attribute=!1),this._$Ei(),this.elementProperties.set(t,e),!e.noAccessor){let r=Symbol(),i=this.getPropertyDescriptor(t,r,e);i!==void 0&&qs(this.prototype,t,i)}}static getPropertyDescriptor(t,e,r){var s;let{get:i,set:n}=(s=Ys(this.prototype,t))!=null?s:{get(){return this[e]},set(a){this[e]=a}};return{get(){return i==null?void 0:i.call(this)},set(a){let l=i==null?void 0:i.call(this);n.call(this,a),this.requestUpdate(t,l,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){var e;return(e=this.elementProperties.get(t))!=null?e:ui}static _$Ei(){if(this.hasOwnProperty(Nt("elementProperties")))return;let t=Zs(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(Nt("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(Nt("properties"))){let e=this.properties,r=[...Ws(e),...Xs(e)];for(let i of r)this.createProperty(i,e[i])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[r,i]of e)this.elementProperties.set(r,i)}this._$Eh=new Map;for(let[e,r]of this.elementProperties){let i=this._$Eu(e,r);i!==void 0&&this._$Eh.set(i,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let r=new Set(t.flat(1/0).reverse());for(let i of r)e.unshift(cr(i))}else t!==void 0&&e.push(cr(t));return e}static _$Eu(t,e){let r=e.attribute;return r===!1?void 0:typeof r=="string"?r:typeof t=="string"?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var t;this._$ES=new Promise(e=>this.enableUpdating=e),this._$AL=new Map,this._$E_(),this.requestUpdate(),(t=this.constructor.l)==null||t.forEach(e=>e(this))}addController(t){var e,r;((e=this._$EO)!=null?e:this._$EO=new Set).add(t),this.renderRoot!==void 0&&this.isConnected&&((r=t.hostConnected)==null||r.call(t))}removeController(t){var e;(e=this._$EO)==null||e.delete(t)}_$E_(){let t=new Map,e=this.constructor.elementProperties;for(let r of e.keys())this.hasOwnProperty(r)&&(t.set(r,this[r]),delete this[r]);t.size>0&&(this._$Ep=t)}createRenderRoot(){var e;let t=(e=this.shadowRoot)!=null?e:this.attachShadow(this.constructor.shadowRootOptions);return io(t,this.constructor.elementStyles),t}connectedCallback(){var t,e;(t=this.renderRoot)!=null||(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(e=this._$EO)==null||e.forEach(r=>{var i;return(i=r.hostConnected)==null?void 0:i.call(r)})}enableUpdating(t){}disconnectedCallback(){var t;(t=this._$EO)==null||t.forEach(e=>{var r;return(r=e.hostDisconnected)==null?void 0:r.call(e)})}attributeChangedCallback(t,e,r){this._$AK(t,r)}_$EC(t,e){var n;let r=this.constructor.elementProperties.get(t),i=this.constructor._$Eu(t,r);if(i!==void 0&&r.reflect===!0){let s=(((n=r.converter)==null?void 0:n.toAttribute)!==void 0?r.converter:Ot).toAttribute(e,r.type);this._$Em=t,s==null?this.removeAttribute(i):this.setAttribute(i,s),this._$Em=null}}_$AK(t,e){var n;let r=this.constructor,i=r._$Eh.get(t);if(i!==void 0&&this._$Em!==i){let s=r.getPropertyOptions(i),a=typeof s.converter=="function"?{fromAttribute:s.converter}:((n=s.converter)==null?void 0:n.fromAttribute)!==void 0?s.converter:Ot;this._$Em=i,this[i]=a.fromAttribute(e,s.type),this._$Em=null}}requestUpdate(t,e,r){var i;if(t!==void 0){if(r!=null||(r=this.constructor.getPropertyOptions(t)),!((i=r.hasChanged)!=null?i:dr)(this[t],e))return;this.P(t,e,r)}this.isUpdatePending===!1&&(this._$ES=this._$ET())}P(t,e,r){var i;this._$AL.has(t)||this._$AL.set(t,e),r.reflect===!0&&this._$Em!==t&&((i=this._$Ej)!=null?i:this._$Ej=new Set).add(t)}async _$ET(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var r,i;if(!this.isUpdatePending)return;if(!this.hasUpdated){if((r=this.renderRoot)!=null||(this.renderRoot=this.createRenderRoot()),this._$Ep){for(let[s,a]of this._$Ep)this[s]=a;this._$Ep=void 0}let n=this.constructor.elementProperties;if(n.size>0)for(let[s,a]of n)a.wrapped!==!0||this._$AL.has(s)||this[s]===void 0||this.P(s,this[s],a)}let t=!1,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),(i=this._$EO)==null||i.forEach(n=>{var s;return(s=n.hostUpdate)==null?void 0:s.call(n)}),this.update(e)):this._$EU()}catch(n){throw t=!1,this._$EU(),n}t&&this._$AE(e)}willUpdate(t){}_$AE(t){var e;(e=this._$EO)==null||e.forEach(r=>{var i;return(i=r.hostUpdated)==null?void 0:i.call(r)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EU(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Ej&&(this._$Ej=this._$Ej.forEach(e=>this._$EC(e,this[e]))),this._$EU()}updated(t){}firstUpdated(t){}},vi;be.elementStyles=[],be.shadowRootOptions={mode:"open"},be[Nt("elementProperties")]=new Map,be[Nt("finalized")]=new Map,no==null||no({ReactiveElement:be}),((vi=Ne.reactiveElementVersions)!=null?vi:Ne.reactiveElementVersions=[]).push("2.0.4");var Ks={attribute:!0,type:String,converter:Ot,reflect:!1,hasChanged:dr},Qs=(o=Ks,t,e)=>{let{kind:r,metadata:i}=e,n=globalThis.litPropertyMetadata.get(i);if(n===void 0&&globalThis.litPropertyMetadata.set(i,n=new Map),n.set(e.name,o),r==="accessor"){let{name:s}=e;return{set(a){let l=t.get.call(this);t.set.call(this,a),this.requestUpdate(s,l,o)},init(a){return a!==void 0&&this.P(s,void 0,o),a}}}if(r==="setter"){let{name:s}=e;return function(a){let l=this[s];t.call(this,a),this.requestUpdate(s,l,o)}}throw Error("Unsupported decorator location: "+r)};function d(o){return(t,e)=>typeof e=="object"?Qs(o,t,e):((r,i,n)=>{let s=i.hasOwnProperty(n);return i.constructor.createProperty(n,s?{...r,wrapped:!0}:r),s?Object.getOwnPropertyDescriptor(i,n):void 0})(o,t,e)}function q(o){return d({...o,state:!0,attribute:!1})}var Be=(o,t,e)=>(e.configurable=!0,e.enumerable=!0,Reflect.decorate&&typeof t!="object"&&Object.defineProperty(o,t,e),e);function bi(o,t){return(e,r,i)=>{let n=s=>{var a,l;return(l=(a=s.renderRoot)==null?void 0:a.querySelector(o))!=null?l:null};if(t){let{get:s,set:a}=typeof r=="object"?e:i!=null?i:(()=>{let l=Symbol();return{get(){return this[l]},set(m){this[l]=m}}})();return Be(e,r,{get(){let l=s.call(this);return l===void 0&&(l=n(this),(l!==null||this.hasUpdated)&&a.call(this,l)),l}})}return Be(e,r,{get(){return n(this)}})}}var Js={PREFIX:"mdc",SEPARATOR:"-"},ea={NAMESPACE:Js},so=ea;var ta=o=>[so.NAMESPACE.PREFIX,o].join(so.NAMESPACE.SEPARATOR),y={constructTagName:ta};var mr=y.constructTagName("themeprovider"),ao={THEMECLASS:"mds-theme-stable-darkWebex"};var Mt=globalThis,hr=Mt.trustedTypes,yi=hr?hr.createPolicy("lit-html",{createHTML:o=>o}):void 0,mo="$lit$",ye=`lit$${Math.random().toFixed(9).slice(2)}$`,ho="?"+ye,ra=`<${ho}>`,Ye=document,Dt=()=>Ye.createComment(""),$t=o=>o===null||typeof o!="object"&&typeof o!="function",po=Array.isArray,Ii=o=>po(o)||typeof(o==null?void 0:o[Symbol.iterator])=="function",lo=`[
|
2
2
|
\f\r]`,zt=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,xi=/-->/g,Ei=/>/g,Ge=RegExp(`>|${lo}(?:([^\\s"'>=/]+)(${lo}*=${lo}*(?:[^
|
3
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),Ti=/'/g,Ai=/"/g,wi=/^(?:script|style|textarea|title)$/i,uo=o=>(t,...e)=>({_$litType$:o,strings:t,values:e}),u=uo(1),bc=uo(2),yc=uo(3),xe=Symbol.for("lit-noChange"),x=Symbol.for("lit-nothing"),Si=new WeakMap,qe=Ye.createTreeWalker(Ye,129);function Ci(o,t){if(!po(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return yi!==void 0?yi.createHTML(t):t}var
|
3
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),Ti=/'/g,Ai=/"/g,wi=/^(?:script|style|textarea|title)$/i,uo=o=>(t,...e)=>({_$litType$:o,strings:t,values:e}),u=uo(1),bc=uo(2),yc=uo(3),xe=Symbol.for("lit-noChange"),x=Symbol.for("lit-nothing"),Si=new WeakMap,qe=Ye.createTreeWalker(Ye,129);function Ci(o,t){if(!po(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return yi!==void 0?yi.createHTML(t):t}var ki=(o,t)=>{let e=o.length-1,r=[],i,n=t===2?"<svg>":t===3?"<math>":"",s=zt;for(let a=0;a<e;a++){let l=o[a],m,h,p=-1,v=0;for(;v<l.length&&(s.lastIndex=v,h=s.exec(l),h!==null);)v=s.lastIndex,s===zt?h[1]==="!--"?s=xi:h[1]!==void 0?s=Ei:h[2]!==void 0?(wi.test(h[2])&&(i=RegExp("</"+h[2],"g")),s=Ge):h[3]!==void 0&&(s=Ge):s===Ge?h[0]===">"?(s=i!=null?i:zt,p=-1):h[1]===void 0?p=-2:(p=s.lastIndex-h[2].length,m=h[1],s=h[3]===void 0?Ge:h[3]==='"'?Ai:Ti):s===Ai||s===Ti?s=Ge:s===xi||s===Ei?s=zt:(s=Ge,i=void 0);let f=s===Ge&&o[a+1].startsWith("/>")?" ":"";n+=s===zt?l+ra:p>=0?(r.push(m),l.slice(0,p)+mo+l.slice(p)+ye+f):l+ye+(p===-2?a:f)}return[Ci(o,n+(o[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),r]},Pt=class o{constructor({strings:t,_$litType$:e},r){let i;this.parts=[];let n=0,s=0,a=t.length-1,l=this.parts,[m,h]=ki(t,e);if(this.el=o.createElement(m,r),qe.currentNode=this.el.content,e===2||e===3){let p=this.el.content.firstChild;p.replaceWith(...p.childNodes)}for(;(i=qe.nextNode())!==null&&l.length<a;){if(i.nodeType===1){if(i.hasAttributes())for(let p of i.getAttributeNames())if(p.endsWith(mo)){let v=h[s++],f=i.getAttribute(p).split(ye),b=/([.?@])?(.*)/.exec(v);l.push({type:1,index:n,name:b[2],strings:f,ctor:b[1]==="."?ur:b[1]==="?"?fr:b[1]==="@"?gr:Xe}),i.removeAttribute(p)}else p.startsWith(ye)&&(l.push({type:6,index:n}),i.removeAttribute(p));if(wi.test(i.tagName)){let p=i.textContent.split(ye),v=p.length-1;if(v>0){i.textContent=hr?hr.emptyScript:"";for(let f=0;f<v;f++)i.append(p[f],Dt()),qe.nextNode(),l.push({type:2,index:++n});i.append(p[v],Dt())}}}else if(i.nodeType===8)if(i.data===ho)l.push({type:2,index:n});else{let p=-1;for(;(p=i.data.indexOf(ye,p+1))!==-1;)l.push({type:7,index:n}),p+=ye.length-1}n++}}static createElement(t,e){let r=Ye.createElement("template");return r.innerHTML=t,r}};function We(o,t,e=o,r){var s,a,l;if(t===xe)return t;let i=r!==void 0?(s=e.o)==null?void 0:s[r]:e.l,n=$t(t)?void 0:t._$litDirective$;return(i==null?void 0:i.constructor)!==n&&((a=i==null?void 0:i._$AO)==null||a.call(i,!1),n===void 0?i=void 0:(i=new n(o),i._$AT(o,e,r)),r!==void 0?((l=e.o)!=null?l:e.o=[])[r]=i:e.l=i),i!==void 0&&(t=We(o,i._$AS(o,t.values),i,r)),t}var pr=class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){var m;let{el:{content:e},parts:r}=this._$AD,i=((m=t==null?void 0:t.creationScope)!=null?m:Ye).importNode(e,!0);qe.currentNode=i;let n=qe.nextNode(),s=0,a=0,l=r[0];for(;l!==void 0;){if(s===l.index){let h;l.type===2?h=new ut(n,n.nextSibling,this,t):l.type===1?h=new l.ctor(n,l.name,l.strings,this,t):l.type===6&&(h=new vr(n,this,t)),this._$AV.push(h),l=r[++a]}s!==(l==null?void 0:l.index)&&(n=qe.nextNode(),s++)}return qe.currentNode=Ye,i}p(t){let e=0;for(let r of this._$AV)r!==void 0&&(r.strings!==void 0?(r._$AI(t,r,e),e+=r.strings.length-2):r._$AI(t[e])),e++}},ut=class o{get _$AU(){var t,e;return(e=(t=this._$AM)==null?void 0:t._$AU)!=null?e:this.v}constructor(t,e,r,i){var n;this.type=2,this._$AH=x,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=r,this.options=i,this.v=(n=i==null?void 0:i.isConnected)!=null?n:!0}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&(t==null?void 0:t.nodeType)===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=We(this,t,e),$t(t)?t===x||t==null||t===""?(this._$AH!==x&&this._$AR(),this._$AH=x):t!==this._$AH&&t!==xe&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Ii(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==x&&$t(this._$AH)?this._$AA.nextSibling.data=t:this.T(Ye.createTextNode(t)),this._$AH=t}$(t){var n;let{values:e,_$litType$:r}=t,i=typeof r=="number"?this._$AC(t):(r.el===void 0&&(r.el=Pt.createElement(Ci(r.h,r.h[0]),this.options)),r);if(((n=this._$AH)==null?void 0:n._$AD)===i)this._$AH.p(e);else{let s=new pr(i,this),a=s.u(this.options);s.p(e),this.T(a),this._$AH=s}}_$AC(t){let e=Si.get(t.strings);return e===void 0&&Si.set(t.strings,e=new Pt(t)),e}k(t){po(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,r,i=0;for(let n of t)i===e.length?e.push(r=new o(this.O(Dt()),this.O(Dt()),this,this.options)):r=e[i],r._$AI(n),i++;i<e.length&&(this._$AR(r&&r._$AB.nextSibling,i),e.length=i)}_$AR(t=this._$AA.nextSibling,e){var r;for((r=this._$AP)==null?void 0:r.call(this,!1,!0,e);t&&t!==this._$AB;){let i=t.nextSibling;t.remove(),t=i}}setConnected(t){var e;this._$AM===void 0&&(this.v=t,(e=this._$AP)==null||e.call(this,t))}},Xe=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,r,i,n){this.type=1,this._$AH=x,this._$AN=void 0,this.element=t,this.name=e,this._$AM=i,this.options=n,r.length>2||r[0]!==""||r[1]!==""?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=x}_$AI(t,e=this,r,i){let n=this.strings,s=!1;if(n===void 0)t=We(this,t,e,0),s=!$t(t)||t!==this._$AH&&t!==xe,s&&(this._$AH=t);else{let a=t,l,m;for(t=n[0],l=0;l<n.length-1;l++)m=We(this,a[r+l],e,l),m===xe&&(m=this._$AH[l]),s||(s=!$t(m)||m!==this._$AH[l]),m===x?t=x:t!==x&&(t+=(m!=null?m:"")+n[l+1]),this._$AH[l]=m}s&&!i&&this.j(t)}j(t){t===x?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t!=null?t:"")}},ur=class extends Xe{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===x?void 0:t}},fr=class extends Xe{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==x)}},gr=class extends Xe{constructor(t,e,r,i,n){super(t,e,r,i,n),this.type=5}_$AI(t,e=this){var s;if((t=(s=We(this,t,e,0))!=null?s:x)===xe)return;let r=this._$AH,i=t===x&&r!==x||t.capture!==r.capture||t.once!==r.once||t.passive!==r.passive,n=t!==x&&(r===x||i);i&&this.element.removeEventListener(this.name,this,r),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,r;typeof this._$AH=="function"?this._$AH.call((r=(e=this.options)==null?void 0:e.host)!=null?r:this.element,t):this._$AH.handleEvent(t)}},vr=class{constructor(t,e,r){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(t){We(this,t)}},Ri={M:mo,P:ye,A:ho,C:1,L:ki,R:pr,D:Ii,V:We,I:ut,H:Xe,N:fr,U:gr,B:ur,F:vr},co=Mt.litHtmlPolyfillSupport,_i;co==null||co(Pt,ut),((_i=Mt.litHtmlVersions)!=null?_i:Mt.litHtmlVersions=[]).push("3.2.0");var Li=(o,t,e)=>{var n,s;let r=(n=e==null?void 0:e.renderBefore)!=null?n:t,i=r._$litPart$;if(i===void 0){let a=(s=e==null?void 0:e.renderBefore)!=null?s:null;r._$litPart$=i=new ut(t.insertBefore(Dt(),a),a,void 0,e!=null?e:{})}return i._$AI(o),i};var Oe=class extends be{constructor(){super(...arguments),this.renderOptions={host:this},this.o=void 0}createRenderRoot(){var e,r;let t=super.createRenderRoot();return(r=(e=this.renderOptions).renderBefore)!=null||(e.renderBefore=t.firstChild),t}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this.o=Li(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),(t=this.o)==null||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),(t=this.o)==null||t.setConnected(!1)}render(){return xe}},Ni;Oe._$litElement$=!0,Oe.finalized=!0,(Ni=globalThis.litElementHydrateSupport)==null||Ni.call(globalThis,{LitElement:Oe});var fo=globalThis.litElementPolyfillSupport;fo==null||fo({LitElement:Oe});var Oi;((Oi=globalThis.litElementVersions)!=null?Oi:globalThis.litElementVersions=[]).push("4.1.0");var zi=g`
|
4
4
|
:host {
|
5
5
|
box-sizing: border-box;
|
6
6
|
}
|
@@ -74,10 +74,17 @@
|
|
74
74
|
:host([disabled]) .mdc-focus-ring:focus {
|
75
75
|
box-shadow: none;
|
76
76
|
}
|
77
|
+
/* Add focus ring to parent when child is focused. The parent element must have class name mdc-focus-ring */
|
77
78
|
.mdc-focus-ring:focus-within {
|
78
79
|
position: relative;
|
79
80
|
box-shadow: ${e};
|
80
81
|
}
|
82
|
+
/* Remove focus ring from parent when children has its own focus ring.
|
83
|
+
The child element must have class name own-focus-ring */
|
84
|
+
.mdc-focus-ring:has(.own-focus-ring:focus-visible){
|
85
|
+
box-shadow: none;
|
86
|
+
}
|
87
|
+
|
81
88
|
/* High Contrast Mode */
|
82
89
|
@media (forced-colors: active) {
|
83
90
|
.mdc-focus-ring:focus-within {
|
@@ -91,13 +98,13 @@
|
|
91
98
|
:host([disabled]:focus) {
|
92
99
|
box-shadow: none;
|
93
100
|
}
|
94
|
-
:host(:focus)
|
101
|
+
:host(:focus) {
|
95
102
|
position: relative;
|
96
103
|
box-shadow: ${e};
|
97
104
|
}
|
98
105
|
/* High Contrast Mode */
|
99
106
|
@media (forced-colors: active) {
|
100
|
-
:host(:focus)
|
107
|
+
:host(:focus) {
|
101
108
|
outline: 0.125rem solid var(--mds-color-theme-focus-default-0);
|
102
109
|
}
|
103
110
|
}
|
@@ -624,7 +631,7 @@
|
|
624
631
|
display: block;
|
625
632
|
font-family: var(--mdc-text-font-family);
|
626
633
|
}
|
627
|
-
`,nn],sn=ga;var Et=class extends E{constructor(){super(...arguments);this.type=X.TYPE;this.tagname=X.TEXT_ELEMENT_TAGNAME}render(){switch(this.tagname){case z.H1:return u`<h1 part=${X.CSS_PART_TEXT}><slot></slot></h1>`;case z.H2:return u`<h2 part=${X.CSS_PART_TEXT}><slot></slot></h2>`;case z.H3:return u`<h3 part=${X.CSS_PART_TEXT}><slot></slot></h3>`;case z.H4:return u`<h4 part=${X.CSS_PART_TEXT}><slot></slot></h4>`;case z.H5:return u`<h5 part=${X.CSS_PART_TEXT}><slot></slot></h5>`;case z.H6:return u`<h6 part=${X.CSS_PART_TEXT}><slot></slot></h6>`;case z.DIV:return u`<div part=${X.CSS_PART_TEXT}><slot></slot></div>`;case z.SPAN:return u`<span part=${X.CSS_PART_TEXT}><slot></slot></span>`;case z.SMALL:return u`<small part=${X.CSS_PART_TEXT}><slot></slot></small>`;case z.P:default:return u`<p part=${X.CSS_PART_TEXT}><slot></slot></p>`}}};Et.styles=[...E.styles,...sn],c([d({attribute:"type",reflect:!0,type:String})],Et.prototype,"type",2),c([d({attribute:"tagname",reflect:!0,type:String})],Et.prototype,"tagname",2);var Ao=Et;Ao.register(Ht);var va=Ao;Eo.register(ji);var ba=Eo;var wr={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},Bt=o=>(...t)=>({_$litDirective$:o,values:t}),Tt=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,r){this.t=t,this._$AM=e,this.i=r}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};var Cr=Bt(class extends Tt{constructor(o){var t;if(super(o),o.type!==wr.ATTRIBUTE||o.name!=="class"||((t=o.strings)==null?void 0:t.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(o){return" "+Object.keys(o).filter(t=>o[t]).join(" ")+" "}update(o,[t]){var r,i;if(this.st===void 0){this.st=new Set,o.strings!==void 0&&(this.nt=new Set(o.strings.join(" ").split(/\s/).filter(n=>n!=="")));for(let n in t)t[n]&&!((r=this.nt)!=null&&r.has(n))&&this.st.add(n);return this.render(t)}let e=o.element.classList;for(let n of this.st)n in t||(e.remove(n),this.st.delete(n));for(let n in t){let s=!!t[n];s===this.st.has(n)||(i=this.nt)!=null&&i.has(n)||(s?(e.add(n),this.st.add(n)):(e.remove(n),this.st.delete(n)))}return xe}});var an=y.constructTagName("badge"),Te={DOT:"dot",ICON:"icon",COUNTER:"counter",SUCCESS:"success",WARNING:"warning",ERROR:"error"},
|
634
|
+
`,nn],sn=ga;var Et=class extends E{constructor(){super(...arguments);this.type=X.TYPE;this.tagname=X.TEXT_ELEMENT_TAGNAME}render(){switch(this.tagname){case z.H1:return u`<h1 part=${X.CSS_PART_TEXT}><slot></slot></h1>`;case z.H2:return u`<h2 part=${X.CSS_PART_TEXT}><slot></slot></h2>`;case z.H3:return u`<h3 part=${X.CSS_PART_TEXT}><slot></slot></h3>`;case z.H4:return u`<h4 part=${X.CSS_PART_TEXT}><slot></slot></h4>`;case z.H5:return u`<h5 part=${X.CSS_PART_TEXT}><slot></slot></h5>`;case z.H6:return u`<h6 part=${X.CSS_PART_TEXT}><slot></slot></h6>`;case z.DIV:return u`<div part=${X.CSS_PART_TEXT}><slot></slot></div>`;case z.SPAN:return u`<span part=${X.CSS_PART_TEXT}><slot></slot></span>`;case z.SMALL:return u`<small part=${X.CSS_PART_TEXT}><slot></slot></small>`;case z.P:default:return u`<p part=${X.CSS_PART_TEXT}><slot></slot></p>`}}};Et.styles=[...E.styles,...sn],c([d({attribute:"type",reflect:!0,type:String})],Et.prototype,"type",2),c([d({attribute:"tagname",reflect:!0,type:String})],Et.prototype,"tagname",2);var Ao=Et;Ao.register(Ht);var va=Ao;Eo.register(ji);var ba=Eo;var wr={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},Bt=o=>(...t)=>({_$litDirective$:o,values:t}),Tt=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,r){this.t=t,this._$AM=e,this.i=r}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};var Cr=Bt(class extends Tt{constructor(o){var t;if(super(o),o.type!==wr.ATTRIBUTE||o.name!=="class"||((t=o.strings)==null?void 0:t.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(o){return" "+Object.keys(o).filter(t=>o[t]).join(" ")+" "}update(o,[t]){var r,i;if(this.st===void 0){this.st=new Set,o.strings!==void 0&&(this.nt=new Set(o.strings.join(" ").split(/\s/).filter(n=>n!=="")));for(let n in t)t[n]&&!((r=this.nt)!=null&&r.has(n))&&this.st.add(n);return this.render(t)}let e=o.element.classList;for(let n of this.st)n in t||(e.remove(n),this.st.delete(n));for(let n in t){let s=!!t[n];s===this.st.has(n)||(i=this.nt)!=null&&i.has(n)||(s?(e.add(n),this.st.add(n)):(e.remove(n),this.st.delete(n)))}return xe}});var an=y.constructTagName("badge"),Te={DOT:"dot",ICON:"icon",COUNTER:"counter",SUCCESS:"success",WARNING:"warning",ERROR:"error"},kr={SUCCESS_ICON_NAME:"check-circle-badge-filled",WARNING_ICON_NAME:"warning-badge-filled",ERROR_ICON_NAME:"error-legacy-badge-filled"},Rr={PRIMARY:"primary",SECONDARY:"secondary"},Gt={SUCCESS:"success",WARNING:"warning",ERROR:"error"},ep={...Rr,...Gt},Me={TYPE:Te.DOT,MAX_COUNTER:99,MAX_COUNTER_LIMIT:999,VARIANT:Rr.PRIMARY,ICON_SIZE:1};var ya=[C,g`
|
628
635
|
:host {
|
629
636
|
--mdc-badge-primary-foreground-color: var(--mds-color-theme-common-text-primary-normal);
|
630
637
|
--mdc-badge-primary-background-color: var(--mds-color-theme-background-accent-normal);
|
@@ -707,7 +714,7 @@
|
|
707
714
|
>
|
708
715
|
${this.getCounterText(this.maxCounter,this.counter)}
|
709
716
|
</mdc-text>
|
710
|
-
`}setRoleByAriaLabel(){this.ariaLabel?this.role="img":this.role=null}getBadgeContentBasedOnType(){this.variant&&!Object.values(
|
717
|
+
`}setRoleByAriaLabel(){this.ariaLabel?this.role="img":this.role=null}getBadgeContentBasedOnType(){this.variant&&!Object.values(Rr).includes(this.variant)&&(this.variant=Me.VARIANT);let{iconName:e,type:r,variant:i}=this;switch(r){case Te.ICON:return this.getBadgeIcon(e||"",i);case Te.COUNTER:return this.getBadgeCounterText();case Te.SUCCESS:return this.getBadgeIcon(kr.SUCCESS_ICON_NAME,Gt.SUCCESS);case Te.WARNING:return this.getBadgeIcon(kr.WARNING_ICON_NAME,Gt.WARNING);case Te.ERROR:return this.getBadgeIcon(kr.ERROR_ICON_NAME,Gt.ERROR);case Te.DOT:default:return this.type=Te.DOT,this.getBadgeDot()}}update(e){super.update(e),e.has("ariaLabel")&&this.setRoleByAriaLabel()}render(){return this.getBadgeContentBasedOnType()}};me.styles=[...E.styles,...ln],c([d({type:String,reflect:!0})],me.prototype,"type",2),c([d({type:String,reflect:!0})],me.prototype,"variant",2),c([d({type:Number})],me.prototype,"counter",2),c([d({type:Number,attribute:"max-counter",reflect:!0})],me.prototype,"maxCounter",2),c([d({type:Boolean})],me.prototype,"overlay",2),c([d({type:String,attribute:"aria-label"})],me.prototype,"ariaLabel",2);var So=me;So.register(an);var xa=So;var At=o=>{class t extends o{constructor(){super(...arguments);this.disabled=!1}}return c([d({reflect:!0,type:Boolean})],t.prototype,"disabled",2),t};var U=[];for(let o=0;o<256;++o)U.push((o+256).toString(16).slice(1));function cn(o,t=0){return(U[o[t+0]]+U[o[t+1]]+U[o[t+2]]+U[o[t+3]]+"-"+U[o[t+4]]+U[o[t+5]]+"-"+U[o[t+6]]+U[o[t+7]]+"-"+U[o[t+8]]+U[o[t+9]]+"-"+U[o[t+10]]+U[o[t+11]]+U[o[t+12]]+U[o[t+13]]+U[o[t+14]]+U[o[t+15]]).toLowerCase()}var _o,Ea=new Uint8Array(16);function Io(){if(!_o){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");_o=crypto.getRandomValues.bind(crypto)}return _o(Ea)}var Ta=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),wo={randomUUID:Ta};function Aa(o,t,e){var i,n,s;if(wo.randomUUID&&!t&&!o)return wo.randomUUID();o=o||{};let r=(s=(n=o.random)!=null?n:(i=o.rng)==null?void 0:i.call(o))!=null?s:Io();if(r.length<16)throw new Error("Random bytes length must be >= 16");if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){if(e=e||0,e<0||e+16>t.length)throw new RangeError(`UUID byte range ${e}:${e+15} is out of buffer bounds`);for(let a=0;a<16;++a)t[e+a]=r[a];return t}return cn(r)}var Co=Aa;var he=o=>{class t extends o{constructor(...i){super(i);this.name="";this.value="";this.internals=this.attachInternals(),this.id=`mdc-input-${Co()}`}get form(){return this.internals.form}get validity(){return this.internals.validity}get willValidate(){return this.internals.willValidate}setValidity(){this.inputElement&&this.internals.setValidity(this.inputElement.validity,this.inputElement.validationMessage,this.inputElement)}checkValidity(){return this.setValidity(),this.internals.checkValidity()}reportValidity(){return this.setValidity(),this.internals.reportValidity()}}return t.formAssociated=!0,c([d({reflect:!0,type:String})],t.prototype,"name",2),c([d({reflect:!0,type:String})],t.prototype,"value",2),c([d({reflect:!0,type:String,attribute:"validation-message"})],t.prototype,"validationMessage",2),c([bi("input")],t.prototype,"inputElement",2),t};var dn=o=>{class t extends o{constructor(){super(...arguments);this.tabIndex=0}}return c([d({reflect:!0,type:Number})],t.prototype,"tabIndex",2),t};var Fp=y.constructTagName("buttonsimple"),Sa={20:20,24:24,28:28,32:32,40:40,48:48,52:52,64:64,72:72,88:88,124:124},St={BUTTON:"button",SUBMIT:"submit",RESET:"reset"},Lr={SIZE:Sa[32],TYPE:St.BUTTON,ROLE:"button"};var _a=[C,g`
|
711
718
|
:host {
|
712
719
|
border: 0.0625rem solid transparent;
|
713
720
|
cursor: pointer;
|
@@ -765,7 +772,7 @@
|
|
765
772
|
}
|
766
773
|
`,...$()],mn=_a;var Ae=class extends he(dn(At(E))){constructor(){super();this.active=!1;this.softDisabled=!1;this.size=Lr.SIZE;this.role=Lr.ROLE;this.type=Lr.TYPE;this.prevTabindex=0;this.addEventListener("click",this.executeAction.bind(this)),this.addEventListener("keydown",this.handleKeyDown.bind(this)),this.addEventListener("keyup",this.handleKeyUp.bind(this)),this.addEventListener("blur",this.handleBlur.bind(this))}update(e){super.update(e),e.has("disabled")&&this.setDisabled(this,this.disabled),e.has("softDisabled")&&this.setSoftDisabled(this,this.softDisabled),e.has("active")&&this.setActive(this,this.active)}executeAction(){this.type===St.SUBMIT&&this.form&&this.form.requestSubmit(),this.type===St.RESET&&this.form&&this.form.reset()}setActive(e,r){r?e.setAttribute("aria-pressed","true"):e.removeAttribute("aria-pressed")}setSoftDisabled(e,r){r?e.setAttribute("aria-disabled","true"):e.removeAttribute("aria-disabled")}setDisabled(e,r){r?(e.setAttribute("aria-disabled","true"),this.prevTabindex=this.tabIndex,this.tabIndex=-1):(this.tabIndex===-1&&(this.tabIndex=this.prevTabindex),e.removeAttribute("aria-disabled"))}triggerClickEvent(){let e=new MouseEvent("click",{bubbles:!0,cancelable:!0,view:window});this.dispatchEvent(e)}handleBlur(){this.classList.contains("pressed")&&this.classList.remove("pressed")}handleKeyDown(e){["Enter"," "].includes(e.key)&&(this.classList.add("pressed"),e.key==="Enter"&&this.triggerClickEvent())}handleKeyUp(e){["Enter"," "].includes(e.key)&&(this.classList.remove("pressed"),e.key===" "&&this.triggerClickEvent())}render(){return u`
|
767
774
|
<slot></slot>
|
768
|
-
`}};Ae.styles=[...E.styles,...mn],c([d({type:Boolean,reflect:!0})],Ae.prototype,"active",2),c([d({type:Boolean,attribute:"soft-disabled"})],Ae.prototype,"softDisabled",2),c([d({type:Number,reflect:!0})],Ae.prototype,"size",2),c([d({type:String,reflect:!0})],Ae.prototype,"role",2),c([d({reflect:!0})],Ae.prototype,"type",2);var De=Ae;var qt=y.constructTagName("button"),je={PRIMARY:"primary",SECONDARY:"secondary",TERTIARY:"tertiary"},Nr={40:40,32:32,28:28,24:24},Se={64:64,52:52,20:20,...Nr},
|
775
|
+
`}};Ae.styles=[...E.styles,...mn],c([d({type:Boolean,reflect:!0})],Ae.prototype,"active",2),c([d({type:Boolean,attribute:"soft-disabled"})],Ae.prototype,"softDisabled",2),c([d({type:Number,reflect:!0})],Ae.prototype,"size",2),c([d({type:String,reflect:!0})],Ae.prototype,"role",2),c([d({reflect:!0})],Ae.prototype,"type",2);var De=Ae;var qt=y.constructTagName("button"),je={PRIMARY:"primary",SECONDARY:"secondary",TERTIARY:"tertiary"},Nr={40:40,32:32,28:28,24:24},Se={64:64,52:52,20:20,...Nr},ko={POSITIVE:"positive",NEGATIVE:"negative",ACCENT:"accent",PROMOTIONAL:"promotional",DEFAULT:"default"},_t={PILL:"pill",ICON:"icon",PILL_WITH_ICON:"pill-with-icon"},pe={VARIANT:je.PRIMARY,SIZE:Nr[32],COLOR:ko.DEFAULT,TYPE_INTERNAL:_t.ICON,TYPE:St.BUTTON};var Ia=g`
|
769
776
|
:host {
|
770
777
|
background-color: transparent;
|
771
778
|
border-radius: 1.25rem;
|
@@ -937,7 +944,7 @@
|
|
937
944
|
--mdc-button-secondary-hover-background-color: var(--mds-color-theme-button-secondary-hover);
|
938
945
|
--mdc-button-secondary-pressed-background-color: var(--mds-color-theme-button-secondary-pressed);
|
939
946
|
}
|
940
|
-
`,hn=[Ia];var pn=o=>{switch(o){case Se[64]:return 2;case Se[52]:return 1.75;case Se[40]:return 1.25;default:return 1}},Yt=o=>{let t=o.split("-"),e=["bold","filled","regular","light"];return t.filter(r=>!e.includes(r)).join("-")};var K=class extends De{constructor(){super(...arguments);this.variant=pe.VARIANT;this.size=pe.SIZE;this.color=pe.COLOR;this.role="button";this.typeInternal=pe.TYPE_INTERNAL;this.iconSize=1}update(e){super.update(e),e.has("active")&&this.modifyIconName(this.active),e.has("size")&&this.setSize(this.size),e.has("variant")&&(this.setVariant(this.variant),this.setSize(this.size)),e.has("color")&&this.setColor(this.color),e.has("typeInternal")&&this.setSize(this.size),(e.has("prefixIcon")||e.has("postfixIcon"))&&this.inferButtonType()}modifyIconName(e){e?(this.prefixIcon&&(this.prevPrefixIcon=this.prefixIcon,this.prefixIcon=`${Yt(this.prefixIcon)}-filled`),this.postfixIcon&&(this.prevPostfixIcon=this.postfixIcon,this.postfixIcon=`${Yt(this.postfixIcon)}-filled`)):(this.prevPrefixIcon&&(this.prefixIcon=this.prevPrefixIcon),this.prevPostfixIcon&&(this.postfixIcon=this.prevPostfixIcon))}setVariant(e){this.setAttribute("variant",Object.values(je).includes(e)?e:pe.VARIANT)}setSize(e){let i=this.typeInternal===_t.ICON?Object.values(Se).includes(e)&&!(e===Se[20]&&this.variant!==je.TERTIARY):Object.values(Nr).includes(e);this.setAttribute("size",i?`${e}`:`${pe.SIZE}`),this.iconSize=pn(e)}setColor(e){!Object.values(
|
947
|
+
`,hn=[Ia];var pn=o=>{switch(o){case Se[64]:return 2;case Se[52]:return 1.75;case Se[40]:return 1.25;default:return 1}},Yt=o=>{let t=o.split("-"),e=["bold","filled","regular","light"];return t.filter(r=>!e.includes(r)).join("-")};var K=class extends De{constructor(){super(...arguments);this.variant=pe.VARIANT;this.size=pe.SIZE;this.color=pe.COLOR;this.role="button";this.typeInternal=pe.TYPE_INTERNAL;this.iconSize=1}update(e){super.update(e),e.has("active")&&this.modifyIconName(this.active),e.has("size")&&this.setSize(this.size),e.has("variant")&&(this.setVariant(this.variant),this.setSize(this.size)),e.has("color")&&this.setColor(this.color),e.has("typeInternal")&&this.setSize(this.size),(e.has("prefixIcon")||e.has("postfixIcon"))&&this.inferButtonType()}modifyIconName(e){e?(this.prefixIcon&&(this.prevPrefixIcon=this.prefixIcon,this.prefixIcon=`${Yt(this.prefixIcon)}-filled`),this.postfixIcon&&(this.prevPostfixIcon=this.postfixIcon,this.postfixIcon=`${Yt(this.postfixIcon)}-filled`)):(this.prevPrefixIcon&&(this.prefixIcon=this.prevPrefixIcon),this.prevPostfixIcon&&(this.postfixIcon=this.prevPostfixIcon))}setVariant(e){this.setAttribute("variant",Object.values(je).includes(e)?e:pe.VARIANT)}setSize(e){let i=this.typeInternal===_t.ICON?Object.values(Se).includes(e)&&!(e===Se[20]&&this.variant!==je.TERTIARY):Object.values(Nr).includes(e);this.setAttribute("size",i?`${e}`:`${pe.SIZE}`),this.iconSize=pn(e)}setColor(e){!Object.values(ko).includes(e)||this.variant===je.TERTIARY?this.setAttribute("color",`${pe.COLOR}`):this.setAttribute("color",e)}inferButtonType(){var r,i;let e=(i=(r=this.shadowRoot)==null?void 0:r.querySelector("slot"))==null?void 0:i.assignedNodes().filter(n=>{var s;return n.nodeType!==Node.TEXT_NODE||((s=n.textContent)==null?void 0:s.trim())}).length;e&&(this.prefixIcon||this.postfixIcon)?(this.typeInternal=_t.PILL_WITH_ICON,this.setAttribute("data-btn-type","pill-with-icon")):!e&&(this.prefixIcon||this.postfixIcon)?(this.typeInternal=_t.ICON,this.setAttribute("data-btn-type","icon")):(this.typeInternal=_t.PILL,this.setAttribute("data-btn-type","pill"))}render(){return u`
|
941
948
|
${this.prefixIcon?u` <mdc-icon
|
942
949
|
name="${this.prefixIcon}"
|
943
950
|
part="prefix-icon"
|
@@ -953,7 +960,7 @@
|
|
953
960
|
length-unit="rem"
|
954
961
|
>
|
955
962
|
</mdc-icon>`:""}
|
956
|
-
`}};K.styles=[...De.styles,...hn],c([d({type:String,attribute:"prefix-icon",reflect:!0})],K.prototype,"prefixIcon",2),c([d({type:String,attribute:"postfix-icon",reflect:!0})],K.prototype,"postfixIcon",2),c([d({type:String})],K.prototype,"variant",2),c([d({type:Number})],K.prototype,"size",2),c([d({type:String})],K.prototype,"color",2),c([d({type:String,reflect:!0})],K.prototype,"role",2),c([q()],K.prototype,"typeInternal",2),c([q()],K.prototype,"iconSize",2);var ko=K;ko.register(qt);var wa=ko;var ue=Math.min,G=Math.max,Xt=Math.round,Zt=Math.floor,oe=o=>({x:o,y:o}),Ca={left:"right",right:"left",bottom:"top",top:"bottom"},Ra={start:"end",end:"start"};function zr(o,t,e){return G(o,ue(t,e))}function Ke(o,t){return typeof o=="function"?o(t):o}function _e(o){return o.split("-")[0]}function Qe(o){return o.split("-")[1]}function Lo(o){return o==="x"?"y":"x"}function Mr(o){return o==="y"?"height":"width"}function $e(o){return["top","bottom"].includes(_e(o))?"y":"x"}function Dr(o){return Lo($e(o))}function un(o,t,e){e===void 0&&(e=!1);let r=Qe(o),i=Dr(o),n=Mr(i),s=i==="x"?r===(e?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[n]>t.floating[n]&&(s=Wt(s)),[s,Wt(s)]}function fn(o){let t=Wt(o);return[Or(o),t,Or(t)]}function Or(o){return o.replace(/start|end/g,t=>Ra[t])}function ka(o,t,e){let r=["left","right"],i=["right","left"],n=["top","bottom"],s=["bottom","top"];switch(o){case"top":case"bottom":return e?t?i:r:t?r:i;case"left":case"right":return t?n:s;default:return[]}}function gn(o,t,e,r){let i=Qe(o),n=ka(_e(o),e==="start",r);return i&&(n=n.map(s=>s+"-"+i),t&&(n=n.concat(n.map(Or)))),n}function Wt(o){return o.replace(/left|right|bottom|top/g,t=>Ca[t])}function La(o){return{top:0,right:0,bottom:0,left:0,...o}}function No(o){return typeof o!="number"?La(o):{top:o,right:o,bottom:o,left:o}}function Je(o){let{x:t,y:e,width:r,height:i}=o;return{width:r,height:i,top:e,left:t,right:t+r,bottom:e+i,x:t,y:e}}function vn(o,t,e){let{reference:r,floating:i}=o,n=$e(t),s=Dr(t),a=Mr(s),l=_e(t),m=n==="y",h=r.x+r.width/2-i.width/2,p=r.y+r.height/2-i.height/2,v=r[a]/2-i[a]/2,f;switch(l){case"top":f={x:h,y:r.y-i.height};break;case"bottom":f={x:h,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:p};break;case"left":f={x:r.x-i.width,y:p};break;default:f={x:r.x,y:r.y}}switch(Qe(t)){case"start":f[s]-=v*(e&&m?-1:1);break;case"end":f[s]+=v*(e&&m?-1:1);break}return f}var bn=async(o,t,e)=>{let{placement:r="bottom",strategy:i="absolute",middleware:n=[],platform:s}=e,a=n.filter(Boolean),l=await(s.isRTL==null?void 0:s.isRTL(t)),m=await s.getElementRects({reference:o,floating:t,strategy:i}),{x:h,y:p}=vn(m,r,l),v=r,f={},b=0;for(let T=0;T<a.length;T++){let{name:_,fn:S}=a[T],{x:I,y:w,data:D,reset:N}=await S({x:h,y:p,initialPlacement:r,placement:v,strategy:i,middlewareData:f,rects:m,platform:s,elements:{reference:o,floating:t}});h=I!=null?I:h,p=w!=null?w:p,f={...f,[_]:{...f[_],...D}},N&&b<=50&&(b++,typeof N=="object"&&(N.placement&&(v=N.placement),N.rects&&(m=N.rects===!0?await s.getElementRects({reference:o,floating:t,strategy:i}):N.rects),{x:h,y:p}=vn(m,v,l)),T=-1)}return{x:h,y:p,placement:v,strategy:i,middlewareData:f}};async function $r(o,t){var e;t===void 0&&(t={});let{x:r,y:i,platform:n,rects:s,elements:a,strategy:l}=o,{boundary:m="clippingAncestors",rootBoundary:h="viewport",elementContext:p="floating",altBoundary:v=!1,padding:f=0}=Ke(t,o),b=No(f),_=a[v?p==="floating"?"reference":"floating":p],S=Je(await n.getClippingRect({element:(e=await(n.isElement==null?void 0:n.isElement(_)))==null||e?_:_.contextElement||await(n.getDocumentElement==null?void 0:n.getDocumentElement(a.floating)),boundary:m,rootBoundary:h,strategy:l})),I=p==="floating"?{x:r,y:i,width:s.floating.width,height:s.floating.height}:s.reference,w=await(n.getOffsetParent==null?void 0:n.getOffsetParent(a.floating)),D=await(n.isElement==null?void 0:n.isElement(w))?await(n.getScale==null?void 0:n.getScale(w))||{x:1,y:1}:{x:1,y:1},N=Je(n.convertOffsetParentRelativeRectToViewportRelativeRect?await n.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:I,offsetParent:w,strategy:l}):I);return{top:(S.top-N.top+b.top)/D.y,bottom:(N.bottom-S.bottom+b.bottom)/D.y,left:(S.left-N.left+b.left)/D.x,right:(N.right-S.right+b.right)/D.x}}var yn=o=>({name:"arrow",options:o,async fn(t){let{x:e,y:r,placement:i,rects:n,platform:s,elements:a,middlewareData:l}=t,{element:m,padding:h=0}=Ke(o,t)||{};if(m==null)return{};let p=No(h),v={x:e,y:r},f=Dr(i),b=Mr(f),T=await s.getDimensions(m),_=f==="y",S=_?"top":"left",I=_?"bottom":"right",w=_?"clientHeight":"clientWidth",D=n.reference[b]+n.reference[f]-v[f]-n.floating[b],N=v[f]-n.reference[f],Z=await(s.getOffsetParent==null?void 0:s.getOffsetParent(m)),te=Z?Z[w]:0;(!te||!await(s.isElement==null?void 0:s.isElement(Z)))&&(te=a.floating[w]||n.floating[b]);let ge=D/2-N/2,se=te/2-T[b]/2-1,re=ue(p[S],se),Ce=ue(p[I],se),ae=re,Re=te-T[b]-Ce,F=te/2-T[b]/2+ge,pt=zr(ae,F,Re),ve=!l.arrow&&Qe(i)!=null&&F!==pt&&n.reference[b]/2-(F<ae?re:Ce)-T[b]/2<0,le=ve?F<ae?F-ae:F-Re:0;return{[f]:v[f]+le,data:{[f]:pt,centerOffset:F-pt-le,...ve&&{alignmentOffset:le}},reset:ve}}});var xn=function(o){return o===void 0&&(o={}),{name:"flip",options:o,async fn(t){var e,r;let{placement:i,middlewareData:n,rects:s,initialPlacement:a,platform:l,elements:m}=t,{mainAxis:h=!0,crossAxis:p=!0,fallbackPlacements:v,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:T=!0,..._}=Ke(o,t);if((e=n.arrow)!=null&&e.alignmentOffset)return{};let S=_e(i),I=$e(a),w=_e(a)===a,D=await(l.isRTL==null?void 0:l.isRTL(m.floating)),N=v||(w||!T?[Wt(a)]:fn(a)),Z=b!=="none";!v&&Z&&N.push(...gn(a,T,b,D));let te=[a,...N],ge=await $r(t,_),se=[],re=((r=n.flip)==null?void 0:r.overflows)||[];if(h&&se.push(ge[S]),p){let F=un(i,s,D);se.push(ge[F[0]],ge[F[1]])}if(re=[...re,{placement:i,overflows:se}],!se.every(F=>F<=0)){var Ce,ae;let F=(((Ce=n.flip)==null?void 0:Ce.index)||0)+1,pt=te[F];if(pt)return{data:{index:F,overflows:re},reset:{placement:pt}};let ve=(ae=re.filter(le=>le.overflows[0]<=0).sort((le,ke)=>le.overflows[1]-ke.overflows[1])[0])==null?void 0:ae.placement;if(!ve)switch(f){case"bestFit":{var Re;let le=(Re=re.filter(ke=>{if(Z){let Le=$e(ke.placement);return Le===I||Le==="y"}return!0}).map(ke=>[ke.placement,ke.overflows.filter(Le=>Le>0).reduce((Le,Hs)=>Le+Hs,0)]).sort((ke,Le)=>ke[1]-Le[1])[0])==null?void 0:Re[0];le&&(ve=le);break}case"initialPlacement":ve=a;break}if(i!==ve)return{reset:{placement:ve}}}return{}}}};async function Na(o,t){let{placement:e,platform:r,elements:i}=o,n=await(r.isRTL==null?void 0:r.isRTL(i.floating)),s=_e(e),a=Qe(e),l=$e(e)==="y",m=["left","top"].includes(s)?-1:1,h=n&&l?-1:1,p=Ke(t,o),{mainAxis:v,crossAxis:f,alignmentAxis:b}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return a&&typeof b=="number"&&(f=a==="end"?b*-1:b),l?{x:f*h,y:v*m}:{x:v*m,y:f*h}}var En=function(o){return o===void 0&&(o=0),{name:"offset",options:o,async fn(t){var e,r;let{x:i,y:n,placement:s,middlewareData:a}=t,l=await Na(t,o);return s===((e=a.offset)==null?void 0:e.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:i+l.x,y:n+l.y,data:{...l,placement:s}}}}},Tn=function(o){return o===void 0&&(o={}),{name:"shift",options:o,async fn(t){let{x:e,y:r,placement:i}=t,{mainAxis:n=!0,crossAxis:s=!1,limiter:a={fn:_=>{let{x:S,y:I}=_;return{x:S,y:I}}},...l}=Ke(o,t),m={x:e,y:r},h=await $r(t,l),p=$e(_e(i)),v=Lo(p),f=m[v],b=m[p];if(n){let _=v==="y"?"top":"left",S=v==="y"?"bottom":"right",I=f+h[_],w=f-h[S];f=zr(I,f,w)}if(s){let _=p==="y"?"top":"left",S=p==="y"?"bottom":"right",I=b+h[_],w=b-h[S];b=zr(I,b,w)}let T=a.fn({...t,[v]:f,[p]:b});return{...T,data:{x:T.x-e,y:T.y-r,enabled:{[v]:n,[p]:s}}}}}};var An=function(o){return o===void 0&&(o={}),{name:"size",options:o,async fn(t){var e,r;let{placement:i,rects:n,platform:s,elements:a}=t,{apply:l=()=>{},...m}=Ke(o,t),h=await $r(t,m),p=_e(i),v=Qe(i),f=$e(i)==="y",{width:b,height:T}=n.floating,_,S;p==="top"||p==="bottom"?(_=p,S=v===(await(s.isRTL==null?void 0:s.isRTL(a.floating))?"start":"end")?"left":"right"):(S=p,_=v==="end"?"top":"bottom");let I=T-h.top-h.bottom,w=b-h.left-h.right,D=ue(T-h[_],I),N=ue(b-h[S],w),Z=!t.middlewareData.shift,te=D,ge=N;if((e=t.middlewareData.shift)!=null&&e.enabled.x&&(ge=w),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(te=I),Z&&!v){let re=G(h.left,0),Ce=G(h.right,0),ae=G(h.top,0),Re=G(h.bottom,0);f?ge=b-2*(re!==0||Ce!==0?re+Ce:G(h.left,h.right)):te=T-2*(ae!==0||Re!==0?ae+Re:G(h.top,h.bottom))}await l({...t,availableWidth:ge,availableHeight:te});let se=await s.getDimensions(a.floating);return b!==se.width||T!==se.height?{reset:{rects:!0}}:{}}}};function Pr(){return typeof window<"u"}function et(o){return _n(o)?(o.nodeName||"").toLowerCase():"#document"}function Y(o){var t;return(o==null||(t=o.ownerDocument)==null?void 0:t.defaultView)||window}function ie(o){var t;return(t=(_n(o)?o.ownerDocument:o.document)||window.document)==null?void 0:t.documentElement}function _n(o){return Pr()?o instanceof Node||o instanceof Y(o).Node:!1}function Q(o){return Pr()?o instanceof Element||o instanceof Y(o).Element:!1}function ne(o){return Pr()?o instanceof HTMLElement||o instanceof Y(o).HTMLElement:!1}function Sn(o){return!Pr()||typeof ShadowRoot>"u"?!1:o instanceof ShadowRoot||o instanceof Y(o).ShadowRoot}function wt(o){let{overflow:t,overflowX:e,overflowY:r,display:i}=J(o);return/auto|scroll|overlay|hidden|clip/.test(t+r+e)&&!["inline","contents"].includes(i)}function In(o){return["table","td","th"].includes(et(o))}function jt(o){return[":popover-open",":modal"].some(t=>{try{return o.matches(t)}catch{return!1}})}function Ur(o){let t=Vr(),e=Q(o)?J(o):o;return e.transform!=="none"||e.perspective!=="none"||(e.containerType?e.containerType!=="normal":!1)||!t&&(e.backdropFilter?e.backdropFilter!=="none":!1)||!t&&(e.filter?e.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(e.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(e.contain||"").includes(r))}function wn(o){let t=Ie(o);for(;ne(t)&&!tt(t);){if(Ur(t))return t;if(jt(t))return null;t=Ie(t)}return null}function Vr(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function tt(o){return["html","body","#document"].includes(et(o))}function J(o){return Y(o).getComputedStyle(o)}function Kt(o){return Q(o)?{scrollLeft:o.scrollLeft,scrollTop:o.scrollTop}:{scrollLeft:o.scrollX,scrollTop:o.scrollY}}function Ie(o){if(et(o)==="html")return o;let t=o.assignedSlot||o.parentNode||Sn(o)&&o.host||ie(o);return Sn(t)?t.host:t}function Cn(o){let t=Ie(o);return tt(t)?o.ownerDocument?o.ownerDocument.body:o.body:ne(t)&&wt(t)?t:Cn(t)}function It(o,t,e){var r;t===void 0&&(t=[]),e===void 0&&(e=!0);let i=Cn(o),n=i===((r=o.ownerDocument)==null?void 0:r.body),s=Y(i);if(n){let a=Hr(s);return t.concat(s,s.visualViewport||[],wt(i)?i:[],a&&e?It(a):[])}return t.concat(i,It(i,[],e))}function Hr(o){return o.parent&&Object.getPrototypeOf(o.parent)?o.frameElement:null}function Ln(o){let t=J(o),e=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=ne(o),n=i?o.offsetWidth:e,s=i?o.offsetHeight:r,a=Xt(e)!==n||Xt(r)!==s;return a&&(e=n,r=s),{width:e,height:r,$:a}}function zo(o){return Q(o)?o:o.contextElement}function Ct(o){let t=zo(o);if(!ne(t))return oe(1);let e=t.getBoundingClientRect(),{width:r,height:i,$:n}=Ln(t),s=(n?Xt(e.width):e.width)/r,a=(n?Xt(e.height):e.height)/i;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var Oa=oe(0);function Nn(o){let t=Y(o);return!Vr()||!t.visualViewport?Oa:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function za(o,t,e){return t===void 0&&(t=!1),!e||t&&e!==Y(o)?!1:t}function rt(o,t,e,r){t===void 0&&(t=!1),e===void 0&&(e=!1);let i=o.getBoundingClientRect(),n=zo(o),s=oe(1);t&&(r?Q(r)&&(s=Ct(r)):s=Ct(o));let a=za(n,e,r)?Nn(n):oe(0),l=(i.left+a.x)/s.x,m=(i.top+a.y)/s.y,h=i.width/s.x,p=i.height/s.y;if(n){let v=Y(n),f=r&&Q(r)?Y(r):r,b=v,T=Hr(b);for(;T&&r&&f!==b;){let _=Ct(T),S=T.getBoundingClientRect(),I=J(T),w=S.left+(T.clientLeft+parseFloat(I.paddingLeft))*_.x,D=S.top+(T.clientTop+parseFloat(I.paddingTop))*_.y;l*=_.x,m*=_.y,h*=_.x,p*=_.y,l+=w,m+=D,b=Y(T),T=Hr(b)}}return Je({width:h,height:p,x:l,y:m})}function Mo(o,t){let e=Kt(o).scrollLeft;return t?t.left+e:rt(ie(o)).left+e}function On(o,t,e){e===void 0&&(e=!1);let r=o.getBoundingClientRect(),i=r.left+t.scrollLeft-(e?0:Mo(o,r)),n=r.top+t.scrollTop;return{x:i,y:n}}function Ma(o){let{elements:t,rect:e,offsetParent:r,strategy:i}=o,n=i==="fixed",s=ie(r),a=t?jt(t.floating):!1;if(r===s||a&&n)return e;let l={scrollLeft:0,scrollTop:0},m=oe(1),h=oe(0),p=ne(r);if((p||!p&&!n)&&((et(r)!=="body"||wt(s))&&(l=Kt(r)),ne(r))){let f=rt(r);m=Ct(r),h.x=f.x+r.clientLeft,h.y=f.y+r.clientTop}let v=s&&!p&&!n?On(s,l,!0):oe(0);return{width:e.width*m.x,height:e.height*m.y,x:e.x*m.x-l.scrollLeft*m.x+h.x+v.x,y:e.y*m.y-l.scrollTop*m.y+h.y+v.y}}function Da(o){return Array.from(o.getClientRects())}function $a(o){let t=ie(o),e=Kt(o),r=o.ownerDocument.body,i=G(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),n=G(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),s=-e.scrollLeft+Mo(o),a=-e.scrollTop;return J(r).direction==="rtl"&&(s+=G(t.clientWidth,r.clientWidth)-i),{width:i,height:n,x:s,y:a}}function Pa(o,t){let e=Y(o),r=ie(o),i=e.visualViewport,n=r.clientWidth,s=r.clientHeight,a=0,l=0;if(i){n=i.width,s=i.height;let m=Vr();(!m||m&&t==="fixed")&&(a=i.offsetLeft,l=i.offsetTop)}return{width:n,height:s,x:a,y:l}}function Ua(o,t){let e=rt(o,!0,t==="fixed"),r=e.top+o.clientTop,i=e.left+o.clientLeft,n=ne(o)?Ct(o):oe(1),s=o.clientWidth*n.x,a=o.clientHeight*n.y,l=i*n.x,m=r*n.y;return{width:s,height:a,x:l,y:m}}function Rn(o,t,e){let r;if(t==="viewport")r=Pa(o,e);else if(t==="document")r=$a(ie(o));else if(Q(t))r=Ua(t,e);else{let i=Nn(o);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return Je(r)}function zn(o,t){let e=Ie(o);return e===t||!Q(e)||tt(e)?!1:J(e).position==="fixed"||zn(e,t)}function Va(o,t){let e=t.get(o);if(e)return e;let r=It(o,[],!1).filter(a=>Q(a)&&et(a)!=="body"),i=null,n=J(o).position==="fixed",s=n?Ie(o):o;for(;Q(s)&&!tt(s);){let a=J(s),l=Ur(s);!l&&a.position==="fixed"&&(i=null),(n?!l&&!i:!l&&a.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||wt(s)&&!l&&zn(o,s))?r=r.filter(h=>h!==s):i=a,s=Ie(s)}return t.set(o,r),r}function Ha(o){let{element:t,boundary:e,rootBoundary:r,strategy:i}=o,s=[...e==="clippingAncestors"?jt(t)?[]:Va(t,this._c):[].concat(e),r],a=s[0],l=s.reduce((m,h)=>{let p=Rn(t,h,i);return m.top=G(p.top,m.top),m.right=ue(p.right,m.right),m.bottom=ue(p.bottom,m.bottom),m.left=G(p.left,m.left),m},Rn(t,a,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Fa(o){let{width:t,height:e}=Ln(o);return{width:t,height:e}}function Ba(o,t,e){let r=ne(t),i=ie(t),n=e==="fixed",s=rt(o,!0,n,t),a={scrollLeft:0,scrollTop:0},l=oe(0);if(r||!r&&!n)if((et(t)!=="body"||wt(i))&&(a=Kt(t)),r){let v=rt(t,!0,n,t);l.x=v.x+t.clientLeft,l.y=v.y+t.clientTop}else i&&(l.x=Mo(i));let m=i&&!r&&!n?On(i,a):oe(0),h=s.left+a.scrollLeft-l.x-m.x,p=s.top+a.scrollTop-l.y-m.y;return{x:h,y:p,width:s.width,height:s.height}}function Oo(o){return J(o).position==="static"}function kn(o,t){if(!ne(o)||J(o).position==="fixed")return null;if(t)return t(o);let e=o.offsetParent;return ie(o)===e&&(e=e.ownerDocument.body),e}function Mn(o,t){let e=Y(o);if(jt(o))return e;if(!ne(o)){let i=Ie(o);for(;i&&!tt(i);){if(Q(i)&&!Oo(i))return i;i=Ie(i)}return e}let r=kn(o,t);for(;r&&In(r)&&Oo(r);)r=kn(r,t);return r&&tt(r)&&Oo(r)&&!Ur(r)?e:r||wn(o)||e}var Ga=async function(o){let t=this.getOffsetParent||Mn,e=this.getDimensions,r=await e(o.floating);return{reference:Ba(o.reference,await t(o.floating),o.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function qa(o){return J(o).direction==="rtl"}var Ya={convertOffsetParentRelativeRectToViewportRelativeRect:Ma,getDocumentElement:ie,getClippingRect:Ha,getOffsetParent:Mn,getElementRects:Ga,getClientRects:Da,getDimensions:Fa,getScale:Ct,isElement:Q,isRTL:qa};function Wa(o,t){let e=null,r,i=ie(o);function n(){var a;clearTimeout(r),(a=e)==null||a.disconnect(),e=null}function s(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),n();let{left:m,top:h,width:p,height:v}=o.getBoundingClientRect();if(a||t(),!p||!v)return;let f=Zt(h),b=Zt(i.clientWidth-(m+p)),T=Zt(i.clientHeight-(h+v)),_=Zt(m),I={rootMargin:-f+"px "+-b+"px "+-T+"px "+-_+"px",threshold:G(0,ue(1,l))||1},w=!0;function D(N){let Z=N[0].intersectionRatio;if(Z!==l){if(!w)return s();Z?s(!1,Z):r=setTimeout(()=>{s(!1,1e-7)},1e3)}w=!1}try{e=new IntersectionObserver(D,{...I,root:i.ownerDocument})}catch{e=new IntersectionObserver(D,I)}e.observe(o)}return s(!0),n}function Dn(o,t,e,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:n=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,m=zo(o),h=i||n?[...m?It(m):[],...It(t)]:[];h.forEach(S=>{i&&S.addEventListener("scroll",e,{passive:!0}),n&&S.addEventListener("resize",e)});let p=m&&a?Wa(m,e):null,v=-1,f=null;s&&(f=new ResizeObserver(S=>{let[I]=S;I&&I.target===m&&f&&(f.unobserve(t),cancelAnimationFrame(v),v=requestAnimationFrame(()=>{var w;(w=f)==null||w.observe(t)})),e()}),m&&!l&&f.observe(m),f.observe(t));let b,T=l?rt(o):null;l&&_();function _(){let S=rt(o);T&&(S.x!==T.x||S.y!==T.y||S.width!==T.width||S.height!==T.height)&&e(),T=S,b=requestAnimationFrame(_)}return e(),()=>{var S;h.forEach(I=>{i&&I.removeEventListener("scroll",e),n&&I.removeEventListener("resize",e)}),p==null||p(),(S=f)==null||S.disconnect(),f=null,l&&cancelAnimationFrame(b)}}var $n=En;var Pn=Tn,Un=xn,Vn=An;var Hn=yn;var Fn=(o,t,e)=>{let r=new Map,i={platform:Ya,...e},n={...i.platform,_c:r};return bn(o,t,{...i,platform:n})};var Xa=g`
|
963
|
+
`}};K.styles=[...De.styles,...hn],c([d({type:String,attribute:"prefix-icon",reflect:!0})],K.prototype,"prefixIcon",2),c([d({type:String,attribute:"postfix-icon",reflect:!0})],K.prototype,"postfixIcon",2),c([d({type:String})],K.prototype,"variant",2),c([d({type:Number})],K.prototype,"size",2),c([d({type:String})],K.prototype,"color",2),c([d({type:String,reflect:!0})],K.prototype,"role",2),c([q()],K.prototype,"typeInternal",2),c([q()],K.prototype,"iconSize",2);var Ro=K;Ro.register(qt);var wa=Ro;var ue=Math.min,G=Math.max,Xt=Math.round,Zt=Math.floor,oe=o=>({x:o,y:o}),Ca={left:"right",right:"left",bottom:"top",top:"bottom"},ka={start:"end",end:"start"};function zr(o,t,e){return G(o,ue(t,e))}function Ke(o,t){return typeof o=="function"?o(t):o}function _e(o){return o.split("-")[0]}function Qe(o){return o.split("-")[1]}function Lo(o){return o==="x"?"y":"x"}function Mr(o){return o==="y"?"height":"width"}function $e(o){return["top","bottom"].includes(_e(o))?"y":"x"}function Dr(o){return Lo($e(o))}function un(o,t,e){e===void 0&&(e=!1);let r=Qe(o),i=Dr(o),n=Mr(i),s=i==="x"?r===(e?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[n]>t.floating[n]&&(s=Wt(s)),[s,Wt(s)]}function fn(o){let t=Wt(o);return[Or(o),t,Or(t)]}function Or(o){return o.replace(/start|end/g,t=>ka[t])}function Ra(o,t,e){let r=["left","right"],i=["right","left"],n=["top","bottom"],s=["bottom","top"];switch(o){case"top":case"bottom":return e?t?i:r:t?r:i;case"left":case"right":return t?n:s;default:return[]}}function gn(o,t,e,r){let i=Qe(o),n=Ra(_e(o),e==="start",r);return i&&(n=n.map(s=>s+"-"+i),t&&(n=n.concat(n.map(Or)))),n}function Wt(o){return o.replace(/left|right|bottom|top/g,t=>Ca[t])}function La(o){return{top:0,right:0,bottom:0,left:0,...o}}function No(o){return typeof o!="number"?La(o):{top:o,right:o,bottom:o,left:o}}function Je(o){let{x:t,y:e,width:r,height:i}=o;return{width:r,height:i,top:e,left:t,right:t+r,bottom:e+i,x:t,y:e}}function vn(o,t,e){let{reference:r,floating:i}=o,n=$e(t),s=Dr(t),a=Mr(s),l=_e(t),m=n==="y",h=r.x+r.width/2-i.width/2,p=r.y+r.height/2-i.height/2,v=r[a]/2-i[a]/2,f;switch(l){case"top":f={x:h,y:r.y-i.height};break;case"bottom":f={x:h,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:p};break;case"left":f={x:r.x-i.width,y:p};break;default:f={x:r.x,y:r.y}}switch(Qe(t)){case"start":f[s]-=v*(e&&m?-1:1);break;case"end":f[s]+=v*(e&&m?-1:1);break}return f}var bn=async(o,t,e)=>{let{placement:r="bottom",strategy:i="absolute",middleware:n=[],platform:s}=e,a=n.filter(Boolean),l=await(s.isRTL==null?void 0:s.isRTL(t)),m=await s.getElementRects({reference:o,floating:t,strategy:i}),{x:h,y:p}=vn(m,r,l),v=r,f={},b=0;for(let T=0;T<a.length;T++){let{name:_,fn:S}=a[T],{x:I,y:w,data:D,reset:N}=await S({x:h,y:p,initialPlacement:r,placement:v,strategy:i,middlewareData:f,rects:m,platform:s,elements:{reference:o,floating:t}});h=I!=null?I:h,p=w!=null?w:p,f={...f,[_]:{...f[_],...D}},N&&b<=50&&(b++,typeof N=="object"&&(N.placement&&(v=N.placement),N.rects&&(m=N.rects===!0?await s.getElementRects({reference:o,floating:t,strategy:i}):N.rects),{x:h,y:p}=vn(m,v,l)),T=-1)}return{x:h,y:p,placement:v,strategy:i,middlewareData:f}};async function $r(o,t){var e;t===void 0&&(t={});let{x:r,y:i,platform:n,rects:s,elements:a,strategy:l}=o,{boundary:m="clippingAncestors",rootBoundary:h="viewport",elementContext:p="floating",altBoundary:v=!1,padding:f=0}=Ke(t,o),b=No(f),_=a[v?p==="floating"?"reference":"floating":p],S=Je(await n.getClippingRect({element:(e=await(n.isElement==null?void 0:n.isElement(_)))==null||e?_:_.contextElement||await(n.getDocumentElement==null?void 0:n.getDocumentElement(a.floating)),boundary:m,rootBoundary:h,strategy:l})),I=p==="floating"?{x:r,y:i,width:s.floating.width,height:s.floating.height}:s.reference,w=await(n.getOffsetParent==null?void 0:n.getOffsetParent(a.floating)),D=await(n.isElement==null?void 0:n.isElement(w))?await(n.getScale==null?void 0:n.getScale(w))||{x:1,y:1}:{x:1,y:1},N=Je(n.convertOffsetParentRelativeRectToViewportRelativeRect?await n.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:I,offsetParent:w,strategy:l}):I);return{top:(S.top-N.top+b.top)/D.y,bottom:(N.bottom-S.bottom+b.bottom)/D.y,left:(S.left-N.left+b.left)/D.x,right:(N.right-S.right+b.right)/D.x}}var yn=o=>({name:"arrow",options:o,async fn(t){let{x:e,y:r,placement:i,rects:n,platform:s,elements:a,middlewareData:l}=t,{element:m,padding:h=0}=Ke(o,t)||{};if(m==null)return{};let p=No(h),v={x:e,y:r},f=Dr(i),b=Mr(f),T=await s.getDimensions(m),_=f==="y",S=_?"top":"left",I=_?"bottom":"right",w=_?"clientHeight":"clientWidth",D=n.reference[b]+n.reference[f]-v[f]-n.floating[b],N=v[f]-n.reference[f],Z=await(s.getOffsetParent==null?void 0:s.getOffsetParent(m)),te=Z?Z[w]:0;(!te||!await(s.isElement==null?void 0:s.isElement(Z)))&&(te=a.floating[w]||n.floating[b]);let ge=D/2-N/2,se=te/2-T[b]/2-1,re=ue(p[S],se),Ce=ue(p[I],se),ae=re,ke=te-T[b]-Ce,F=te/2-T[b]/2+ge,pt=zr(ae,F,ke),ve=!l.arrow&&Qe(i)!=null&&F!==pt&&n.reference[b]/2-(F<ae?re:Ce)-T[b]/2<0,le=ve?F<ae?F-ae:F-ke:0;return{[f]:v[f]+le,data:{[f]:pt,centerOffset:F-pt-le,...ve&&{alignmentOffset:le}},reset:ve}}});var xn=function(o){return o===void 0&&(o={}),{name:"flip",options:o,async fn(t){var e,r;let{placement:i,middlewareData:n,rects:s,initialPlacement:a,platform:l,elements:m}=t,{mainAxis:h=!0,crossAxis:p=!0,fallbackPlacements:v,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:T=!0,..._}=Ke(o,t);if((e=n.arrow)!=null&&e.alignmentOffset)return{};let S=_e(i),I=$e(a),w=_e(a)===a,D=await(l.isRTL==null?void 0:l.isRTL(m.floating)),N=v||(w||!T?[Wt(a)]:fn(a)),Z=b!=="none";!v&&Z&&N.push(...gn(a,T,b,D));let te=[a,...N],ge=await $r(t,_),se=[],re=((r=n.flip)==null?void 0:r.overflows)||[];if(h&&se.push(ge[S]),p){let F=un(i,s,D);se.push(ge[F[0]],ge[F[1]])}if(re=[...re,{placement:i,overflows:se}],!se.every(F=>F<=0)){var Ce,ae;let F=(((Ce=n.flip)==null?void 0:Ce.index)||0)+1,pt=te[F];if(pt)return{data:{index:F,overflows:re},reset:{placement:pt}};let ve=(ae=re.filter(le=>le.overflows[0]<=0).sort((le,Re)=>le.overflows[1]-Re.overflows[1])[0])==null?void 0:ae.placement;if(!ve)switch(f){case"bestFit":{var ke;let le=(ke=re.filter(Re=>{if(Z){let Le=$e(Re.placement);return Le===I||Le==="y"}return!0}).map(Re=>[Re.placement,Re.overflows.filter(Le=>Le>0).reduce((Le,Hs)=>Le+Hs,0)]).sort((Re,Le)=>Re[1]-Le[1])[0])==null?void 0:ke[0];le&&(ve=le);break}case"initialPlacement":ve=a;break}if(i!==ve)return{reset:{placement:ve}}}return{}}}};async function Na(o,t){let{placement:e,platform:r,elements:i}=o,n=await(r.isRTL==null?void 0:r.isRTL(i.floating)),s=_e(e),a=Qe(e),l=$e(e)==="y",m=["left","top"].includes(s)?-1:1,h=n&&l?-1:1,p=Ke(t,o),{mainAxis:v,crossAxis:f,alignmentAxis:b}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return a&&typeof b=="number"&&(f=a==="end"?b*-1:b),l?{x:f*h,y:v*m}:{x:v*m,y:f*h}}var En=function(o){return o===void 0&&(o=0),{name:"offset",options:o,async fn(t){var e,r;let{x:i,y:n,placement:s,middlewareData:a}=t,l=await Na(t,o);return s===((e=a.offset)==null?void 0:e.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:i+l.x,y:n+l.y,data:{...l,placement:s}}}}},Tn=function(o){return o===void 0&&(o={}),{name:"shift",options:o,async fn(t){let{x:e,y:r,placement:i}=t,{mainAxis:n=!0,crossAxis:s=!1,limiter:a={fn:_=>{let{x:S,y:I}=_;return{x:S,y:I}}},...l}=Ke(o,t),m={x:e,y:r},h=await $r(t,l),p=$e(_e(i)),v=Lo(p),f=m[v],b=m[p];if(n){let _=v==="y"?"top":"left",S=v==="y"?"bottom":"right",I=f+h[_],w=f-h[S];f=zr(I,f,w)}if(s){let _=p==="y"?"top":"left",S=p==="y"?"bottom":"right",I=b+h[_],w=b-h[S];b=zr(I,b,w)}let T=a.fn({...t,[v]:f,[p]:b});return{...T,data:{x:T.x-e,y:T.y-r,enabled:{[v]:n,[p]:s}}}}}};var An=function(o){return o===void 0&&(o={}),{name:"size",options:o,async fn(t){var e,r;let{placement:i,rects:n,platform:s,elements:a}=t,{apply:l=()=>{},...m}=Ke(o,t),h=await $r(t,m),p=_e(i),v=Qe(i),f=$e(i)==="y",{width:b,height:T}=n.floating,_,S;p==="top"||p==="bottom"?(_=p,S=v===(await(s.isRTL==null?void 0:s.isRTL(a.floating))?"start":"end")?"left":"right"):(S=p,_=v==="end"?"top":"bottom");let I=T-h.top-h.bottom,w=b-h.left-h.right,D=ue(T-h[_],I),N=ue(b-h[S],w),Z=!t.middlewareData.shift,te=D,ge=N;if((e=t.middlewareData.shift)!=null&&e.enabled.x&&(ge=w),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(te=I),Z&&!v){let re=G(h.left,0),Ce=G(h.right,0),ae=G(h.top,0),ke=G(h.bottom,0);f?ge=b-2*(re!==0||Ce!==0?re+Ce:G(h.left,h.right)):te=T-2*(ae!==0||ke!==0?ae+ke:G(h.top,h.bottom))}await l({...t,availableWidth:ge,availableHeight:te});let se=await s.getDimensions(a.floating);return b!==se.width||T!==se.height?{reset:{rects:!0}}:{}}}};function Pr(){return typeof window<"u"}function et(o){return _n(o)?(o.nodeName||"").toLowerCase():"#document"}function Y(o){var t;return(o==null||(t=o.ownerDocument)==null?void 0:t.defaultView)||window}function ie(o){var t;return(t=(_n(o)?o.ownerDocument:o.document)||window.document)==null?void 0:t.documentElement}function _n(o){return Pr()?o instanceof Node||o instanceof Y(o).Node:!1}function Q(o){return Pr()?o instanceof Element||o instanceof Y(o).Element:!1}function ne(o){return Pr()?o instanceof HTMLElement||o instanceof Y(o).HTMLElement:!1}function Sn(o){return!Pr()||typeof ShadowRoot>"u"?!1:o instanceof ShadowRoot||o instanceof Y(o).ShadowRoot}function wt(o){let{overflow:t,overflowX:e,overflowY:r,display:i}=J(o);return/auto|scroll|overlay|hidden|clip/.test(t+r+e)&&!["inline","contents"].includes(i)}function In(o){return["table","td","th"].includes(et(o))}function jt(o){return[":popover-open",":modal"].some(t=>{try{return o.matches(t)}catch{return!1}})}function Ur(o){let t=Vr(),e=Q(o)?J(o):o;return e.transform!=="none"||e.perspective!=="none"||(e.containerType?e.containerType!=="normal":!1)||!t&&(e.backdropFilter?e.backdropFilter!=="none":!1)||!t&&(e.filter?e.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(e.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(e.contain||"").includes(r))}function wn(o){let t=Ie(o);for(;ne(t)&&!tt(t);){if(Ur(t))return t;if(jt(t))return null;t=Ie(t)}return null}function Vr(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function tt(o){return["html","body","#document"].includes(et(o))}function J(o){return Y(o).getComputedStyle(o)}function Kt(o){return Q(o)?{scrollLeft:o.scrollLeft,scrollTop:o.scrollTop}:{scrollLeft:o.scrollX,scrollTop:o.scrollY}}function Ie(o){if(et(o)==="html")return o;let t=o.assignedSlot||o.parentNode||Sn(o)&&o.host||ie(o);return Sn(t)?t.host:t}function Cn(o){let t=Ie(o);return tt(t)?o.ownerDocument?o.ownerDocument.body:o.body:ne(t)&&wt(t)?t:Cn(t)}function It(o,t,e){var r;t===void 0&&(t=[]),e===void 0&&(e=!0);let i=Cn(o),n=i===((r=o.ownerDocument)==null?void 0:r.body),s=Y(i);if(n){let a=Hr(s);return t.concat(s,s.visualViewport||[],wt(i)?i:[],a&&e?It(a):[])}return t.concat(i,It(i,[],e))}function Hr(o){return o.parent&&Object.getPrototypeOf(o.parent)?o.frameElement:null}function Ln(o){let t=J(o),e=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=ne(o),n=i?o.offsetWidth:e,s=i?o.offsetHeight:r,a=Xt(e)!==n||Xt(r)!==s;return a&&(e=n,r=s),{width:e,height:r,$:a}}function zo(o){return Q(o)?o:o.contextElement}function Ct(o){let t=zo(o);if(!ne(t))return oe(1);let e=t.getBoundingClientRect(),{width:r,height:i,$:n}=Ln(t),s=(n?Xt(e.width):e.width)/r,a=(n?Xt(e.height):e.height)/i;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var Oa=oe(0);function Nn(o){let t=Y(o);return!Vr()||!t.visualViewport?Oa:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function za(o,t,e){return t===void 0&&(t=!1),!e||t&&e!==Y(o)?!1:t}function rt(o,t,e,r){t===void 0&&(t=!1),e===void 0&&(e=!1);let i=o.getBoundingClientRect(),n=zo(o),s=oe(1);t&&(r?Q(r)&&(s=Ct(r)):s=Ct(o));let a=za(n,e,r)?Nn(n):oe(0),l=(i.left+a.x)/s.x,m=(i.top+a.y)/s.y,h=i.width/s.x,p=i.height/s.y;if(n){let v=Y(n),f=r&&Q(r)?Y(r):r,b=v,T=Hr(b);for(;T&&r&&f!==b;){let _=Ct(T),S=T.getBoundingClientRect(),I=J(T),w=S.left+(T.clientLeft+parseFloat(I.paddingLeft))*_.x,D=S.top+(T.clientTop+parseFloat(I.paddingTop))*_.y;l*=_.x,m*=_.y,h*=_.x,p*=_.y,l+=w,m+=D,b=Y(T),T=Hr(b)}}return Je({width:h,height:p,x:l,y:m})}function Mo(o,t){let e=Kt(o).scrollLeft;return t?t.left+e:rt(ie(o)).left+e}function On(o,t,e){e===void 0&&(e=!1);let r=o.getBoundingClientRect(),i=r.left+t.scrollLeft-(e?0:Mo(o,r)),n=r.top+t.scrollTop;return{x:i,y:n}}function Ma(o){let{elements:t,rect:e,offsetParent:r,strategy:i}=o,n=i==="fixed",s=ie(r),a=t?jt(t.floating):!1;if(r===s||a&&n)return e;let l={scrollLeft:0,scrollTop:0},m=oe(1),h=oe(0),p=ne(r);if((p||!p&&!n)&&((et(r)!=="body"||wt(s))&&(l=Kt(r)),ne(r))){let f=rt(r);m=Ct(r),h.x=f.x+r.clientLeft,h.y=f.y+r.clientTop}let v=s&&!p&&!n?On(s,l,!0):oe(0);return{width:e.width*m.x,height:e.height*m.y,x:e.x*m.x-l.scrollLeft*m.x+h.x+v.x,y:e.y*m.y-l.scrollTop*m.y+h.y+v.y}}function Da(o){return Array.from(o.getClientRects())}function $a(o){let t=ie(o),e=Kt(o),r=o.ownerDocument.body,i=G(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),n=G(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),s=-e.scrollLeft+Mo(o),a=-e.scrollTop;return J(r).direction==="rtl"&&(s+=G(t.clientWidth,r.clientWidth)-i),{width:i,height:n,x:s,y:a}}function Pa(o,t){let e=Y(o),r=ie(o),i=e.visualViewport,n=r.clientWidth,s=r.clientHeight,a=0,l=0;if(i){n=i.width,s=i.height;let m=Vr();(!m||m&&t==="fixed")&&(a=i.offsetLeft,l=i.offsetTop)}return{width:n,height:s,x:a,y:l}}function Ua(o,t){let e=rt(o,!0,t==="fixed"),r=e.top+o.clientTop,i=e.left+o.clientLeft,n=ne(o)?Ct(o):oe(1),s=o.clientWidth*n.x,a=o.clientHeight*n.y,l=i*n.x,m=r*n.y;return{width:s,height:a,x:l,y:m}}function kn(o,t,e){let r;if(t==="viewport")r=Pa(o,e);else if(t==="document")r=$a(ie(o));else if(Q(t))r=Ua(t,e);else{let i=Nn(o);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return Je(r)}function zn(o,t){let e=Ie(o);return e===t||!Q(e)||tt(e)?!1:J(e).position==="fixed"||zn(e,t)}function Va(o,t){let e=t.get(o);if(e)return e;let r=It(o,[],!1).filter(a=>Q(a)&&et(a)!=="body"),i=null,n=J(o).position==="fixed",s=n?Ie(o):o;for(;Q(s)&&!tt(s);){let a=J(s),l=Ur(s);!l&&a.position==="fixed"&&(i=null),(n?!l&&!i:!l&&a.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||wt(s)&&!l&&zn(o,s))?r=r.filter(h=>h!==s):i=a,s=Ie(s)}return t.set(o,r),r}function Ha(o){let{element:t,boundary:e,rootBoundary:r,strategy:i}=o,s=[...e==="clippingAncestors"?jt(t)?[]:Va(t,this._c):[].concat(e),r],a=s[0],l=s.reduce((m,h)=>{let p=kn(t,h,i);return m.top=G(p.top,m.top),m.right=ue(p.right,m.right),m.bottom=ue(p.bottom,m.bottom),m.left=G(p.left,m.left),m},kn(t,a,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Fa(o){let{width:t,height:e}=Ln(o);return{width:t,height:e}}function Ba(o,t,e){let r=ne(t),i=ie(t),n=e==="fixed",s=rt(o,!0,n,t),a={scrollLeft:0,scrollTop:0},l=oe(0);if(r||!r&&!n)if((et(t)!=="body"||wt(i))&&(a=Kt(t)),r){let v=rt(t,!0,n,t);l.x=v.x+t.clientLeft,l.y=v.y+t.clientTop}else i&&(l.x=Mo(i));let m=i&&!r&&!n?On(i,a):oe(0),h=s.left+a.scrollLeft-l.x-m.x,p=s.top+a.scrollTop-l.y-m.y;return{x:h,y:p,width:s.width,height:s.height}}function Oo(o){return J(o).position==="static"}function Rn(o,t){if(!ne(o)||J(o).position==="fixed")return null;if(t)return t(o);let e=o.offsetParent;return ie(o)===e&&(e=e.ownerDocument.body),e}function Mn(o,t){let e=Y(o);if(jt(o))return e;if(!ne(o)){let i=Ie(o);for(;i&&!tt(i);){if(Q(i)&&!Oo(i))return i;i=Ie(i)}return e}let r=Rn(o,t);for(;r&&In(r)&&Oo(r);)r=Rn(r,t);return r&&tt(r)&&Oo(r)&&!Ur(r)?e:r||wn(o)||e}var Ga=async function(o){let t=this.getOffsetParent||Mn,e=this.getDimensions,r=await e(o.floating);return{reference:Ba(o.reference,await t(o.floating),o.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function qa(o){return J(o).direction==="rtl"}var Ya={convertOffsetParentRelativeRectToViewportRelativeRect:Ma,getDocumentElement:ie,getClippingRect:Ha,getOffsetParent:Mn,getElementRects:Ga,getClientRects:Da,getDimensions:Fa,getScale:Ct,isElement:Q,isRTL:qa};function Wa(o,t){let e=null,r,i=ie(o);function n(){var a;clearTimeout(r),(a=e)==null||a.disconnect(),e=null}function s(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),n();let{left:m,top:h,width:p,height:v}=o.getBoundingClientRect();if(a||t(),!p||!v)return;let f=Zt(h),b=Zt(i.clientWidth-(m+p)),T=Zt(i.clientHeight-(h+v)),_=Zt(m),I={rootMargin:-f+"px "+-b+"px "+-T+"px "+-_+"px",threshold:G(0,ue(1,l))||1},w=!0;function D(N){let Z=N[0].intersectionRatio;if(Z!==l){if(!w)return s();Z?s(!1,Z):r=setTimeout(()=>{s(!1,1e-7)},1e3)}w=!1}try{e=new IntersectionObserver(D,{...I,root:i.ownerDocument})}catch{e=new IntersectionObserver(D,I)}e.observe(o)}return s(!0),n}function Dn(o,t,e,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:n=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,m=zo(o),h=i||n?[...m?It(m):[],...It(t)]:[];h.forEach(S=>{i&&S.addEventListener("scroll",e,{passive:!0}),n&&S.addEventListener("resize",e)});let p=m&&a?Wa(m,e):null,v=-1,f=null;s&&(f=new ResizeObserver(S=>{let[I]=S;I&&I.target===m&&f&&(f.unobserve(t),cancelAnimationFrame(v),v=requestAnimationFrame(()=>{var w;(w=f)==null||w.observe(t)})),e()}),m&&!l&&f.observe(m),f.observe(t));let b,T=l?rt(o):null;l&&_();function _(){let S=rt(o);T&&(S.x!==T.x||S.y!==T.y||S.width!==T.width||S.height!==T.height)&&e(),T=S,b=requestAnimationFrame(_)}return e(),()=>{var S;h.forEach(I=>{i&&I.removeEventListener("scroll",e),n&&I.removeEventListener("resize",e)}),p==null||p(),(S=f)==null||S.disconnect(),f=null,l&&cancelAnimationFrame(b)}}var $n=En;var Pn=Tn,Un=xn,Vn=An;var Hn=yn;var Fn=(o,t,e)=>{let r=new Map,i={platform:Ya,...e},n={...i.platform,_c:r};return bn(o,t,{...i,platform:n})};var Xa=g`
|
957
964
|
:host {
|
958
965
|
--mdc-popover-arrow-border-radius: 0.1875rem;
|
959
966
|
--mdc-popover-arrow-border: 0.0625rem solid var(--mds-color-theme-outline-secondary-normal);
|
@@ -1059,7 +1066,7 @@
|
|
1059
1066
|
border-top-right-radius: var(--mdc-popover-arrow-border-radius);
|
1060
1067
|
border-bottom-left-radius: 100%;
|
1061
1068
|
}
|
1062
|
-
`,Bn=[Xa];var Gn=y.constructTagName("modalcontainer"),Qt={TONAL:"tonal",CONTRAST:"contrast"},Za={0:0,1:1,2:2,3:3,4:4},Jt={COLOR:Qt.TONAL,ELEVATION:Za[0],ROLE:"dialog",ARIA_MODAL:!1,CHILDREN:"Lorem ipsum dolor sit amet"};var qn=y.constructTagName("popover"),Do={LEFT_START:"left-start",LEFT:"left",LEFT_END:"left-end",RIGHT_START:"right-start",RIGHT:"right",RIGHT_END:"right-end",TOP_START:"top-start",TOP:"top",TOP_END:"top-end",BOTTOM_START:"bottom-start",BOTTOM:"bottom",BOTTOM_END:"bottom-end"},$o={CLICK:"click",MOUSEENTER:"mouseenter",FOCUSIN:"focusin",MANUAL:"manual"},k={PLACEMENT:Do.BOTTOM,TRIGGER:$o.CLICK,COLOR:Qt.TONAL,OFFSET:4,VISIBLE:!1,ARROW:!1,CLOSE_BUTTON:!1,FOCUS_TRAP:!1,INTERACTIVE:!1,PREVENT_SCROLL:!1,HIDE_ON_ESCAPE:!1,HIDE_ON_BLUR:!1,HIDE_ON_CLICK_OUTSIDE:!1,FOCUS_BACK:!1,BACKDROP:!1,FLIP:!0,SIZE:!1,DELAY:"0,0",ROLE:"dialog",Z_INDEX:1e3};var Yn=o=>{class t extends o{constructor(...i){super(...i);this.enabledFocusTrap=k.FOCUS_TRAP;this.enabledPreventScroll=k.PREVENT_SCROLL;this.focusTrapIndex=-1;this.focusableElements=[];this.shouldWrapFocus=()=>!0;this.addEventListener("keydown",this.handleKeydown)}deactivateFocusTrap(){this.enabledFocusTrap=!1,this.enabledPreventScroll=!1,this.focusTrapIndex=-1,document.body.style.overflow=""}hasNoClientRects(i){return i.getClientRects().length===0}hasZeroDimensions(i){let{width:n,height:s}=i.getBoundingClientRect(),{offsetWidth:a,offsetHeight:l}=i;return a+l+s+n===0}isNotVisible(i){return this.hasZeroDimensions(i)||this.hasNoClientRects(i)}hasHiddenStyle(i){let{display:n,opacity:s,visibility:a}=i.style;return n==="none"||s==="0"||a==="hidden"||a==="collapse"}hasComputedHidden(i){let n=getComputedStyle(i);return n.visibility==="hidden"||n.height==="0"||n.display==="none"}isHidden(i){return i.hasAttribute("hidden")||i.getAttribute("aria-hidden")==="true"||this.hasHiddenStyle(i)||this.isNotVisible(i)||this.hasComputedHidden(i)}isNotTabbable(i){return i.getAttribute("tabindex")==="-1"}isInteractiveElement(i){return!!(new Set(["BUTTON","DETAILS","EMBED","IFRAME","SELECT","TEXTAREA"]).has(i.tagName)||i instanceof HTMLAnchorElement&&i.hasAttribute("href")||i instanceof HTMLInputElement&&i.type!=="hidden"||(i instanceof HTMLAudioElement||i instanceof HTMLVideoElement)&&i.hasAttribute("controls")||(i instanceof HTMLImageElement||i instanceof HTMLObjectElement)&&i.hasAttribute("usemap")||i.hasAttribute("tabindex")&&i.tabIndex>-1)}isFocusable(i){return this.isHidden(i)||this.isNotTabbable(i)?!1:this.isInteractiveElement(i)}findFocusable(i,n=new Set){return i instanceof HTMLElement&&this.isFocusable(i)&&n.add(i),Array.from(i.children).forEach(a=>{let l=a;this.isFocusable(l)&&n.add(l),l.shadowRoot?this.findFocusable(l.shadowRoot,n):l.tagName==="SLOT"?l.assignedElements({flatten:!0}).forEach(h=>{h instanceof HTMLElement&&this.findFocusable(h,n)}):this.findFocusable(l,n)}),[...n]}setFocusableElements(){this.shadowRoot&&(this.focusableElements=this.findFocusable(this.shadowRoot,new Set))}setInitialFocus(i=0){this.focusableElements.length!==0&&(this.enabledPreventScroll&&(document.body.style.overflow="hidden"),this.focusableElements[i]&&(this.focusTrapIndex=i,this.focusableElements[i].focus()))}calculateNextIndex(i,n){let{length:s}=this.focusableElements,a=this.shouldWrapFocus();if(i===-1)return n>0?0:s-1;let l=i+n;return a?(l<0&&(l=s-1),l>=s&&(l=0)):(l<0&&(l=0),l>=s&&(l=s-1)),l}getDeepActiveElement(){var n;let i=document.activeElement||document.body;for(;i instanceof HTMLElement&&((n=i.shadowRoot)!=null&&n.activeElement);)i=i.shadowRoot.activeElement;return i||document.body}findElement(i){return this.focusableElements.findIndex(n=>this.isEqualFocusNode(i,n))}isEqualFocusNode(i,n){return i.nodeType>=0?n.isEqualNode(i)&&n===i:!1}trapFocus(i){if(this.focusableElements.length===0)return;let n=this.getDeepActiveElement(),s=this.findElement(n);i?this.focusTrapIndex=this.calculateNextIndex(s,-1):this.focusTrapIndex=this.calculateNextIndex(s,1);let a=this.focusableElements[this.focusTrapIndex];a&&a.focus()}handleKeydown(i){!this.enabledFocusTrap||!this.focusableElements.length||i.key==="Tab"&&(i.preventDefault(),this.trapFocus(i.shiftKey))}}return c([d({type:Boolean})],t.prototype,"enabledFocusTrap",2),c([d({type:Boolean})],t.prototype,"enabledPreventScroll",2),t};var Po=class{constructor(){this.stack=[]}push(t){this.stack.push(t)}pop(){return this.stack.pop()}peek(){return this.stack[this.stack.length-1]}remove(t){this.stack=this.stack.filter(e=>e!==t)}clear(){this.stack=[]}},ot=new Po;var W=o=>{class t extends o{constructor(){super(...arguments);this.dataAriaLabel=null}}return c([d({type:String,reflect:!0,attribute:"data-aria-label"})],t.prototype,"dataAriaLabel",2),t};var Fr=o=>{class t extends o{constructor(){super(...arguments);this.dataAriaDescribedby=null}}return c([d({type:String,reflect:!0,attribute:"data-aria-describedby"})],t.prototype,"dataAriaDescribedby",2),t};var Br=o=>{class t extends o{constructor(){super(...arguments);this.dataAriaLabelledby=null}}return c([d({type:String,reflect:!0,attribute:"data-aria-labelledby"})],t.prototype,"dataAriaLabelledby",2),t};var it=class{static dispatchPopoverEvent(t,e){e.dispatchEvent(new CustomEvent(t,{detail:{show:e.visible},composed:!0,bubbles:!0}))}static onShowPopover(t){this.dispatchPopoverEvent("popover-on-show",t)}static onHidePopover(t){this.dispatchPopoverEvent("popover-on-hide",t)}static onCreatedPopover(t){this.dispatchPopoverEvent("popover-on-created",t)}static onDestroyedPopover(t){this.dispatchPopoverEvent("popover-on-destroyed",t)}};var Gr=class{constructor(t){this.arrowPixelChange=!1;this.popover=t}setupDelay(){try{let[t,e]=this.popover.delay.split(",").map(r=>{let i=parseInt(r,10);if(Number.isNaN(i)||i<0)throw new Error(`Invalid delay value: ${r}`);return i});return[t,e]}catch{return this.popover.delay="0,0",[0,0]}}setupHoverBridge(t){var a;let e=this.popover.renderRoot.querySelector(".popover-hover-bridge");Object.assign(e.style,{top:"",left:"",right:"",bottom:""});let r=`calc(${this.popover.showArrow?"0.75rem + ":""}${this.popover.offset}px)`,i=(a=this.popover.shadowRoot)==null?void 0:a.querySelector("mdc-modalcontainer"),n=i.offsetHeight||0,s=i.offsetWidth||0;if(e)switch(t.split("-")[0]){case"top":e.style.height=r,e.style.bottom=`calc(-1 * (${r}))`,e.style.left="50%",e.style.width=`${s}px`;break;case"left":e.style.height=`${n}px`,e.style.width=r,e.style.right=`calc(-1.5 * (${r}))`;break;case"right":e.style.height=`${n}px`,e.style.width=r,e.style.left=`calc(-0.5 * (${r}))`;break;case"bottom":default:e.style.height=r,e.style.top=`calc(-1 * (${r}))`,e.style.left="50%",e.style.width=`${s}px`;break}}setupAppendTo(){if(this.popover.appendTo){let t=document.getElementById(this.popover.appendTo);t&&t.appendChild(this.popover)}}setupAccessibility(){var t,e,r;this.popover.interactive&&(this.popover.dataAriaLabel||(this.popover.dataAriaLabel=((t=this.popover.triggerElement)==null?void 0:t.ariaLabel)||((e=this.popover.triggerElement)==null?void 0:e.textContent)||""),this.popover.dataAriaLabelledby||(this.popover.dataAriaLabelledby=((r=this.popover.triggerElement)==null?void 0:r.id)||""))}updateArrowStyle(t,e){var h;if(!this.popover.arrowElement)return;let r=e.split("-")[0],i={top:"bottom",right:"left",bottom:"top",left:"right"}[r],{x:n,y:s}=t,a=this.popover.arrowElement.getBoundingClientRect(),l=(h=this.popover.arrowElement.offsetParent)==null?void 0:h.getBoundingClientRect();if(!this.arrowPixelChange){let p=l!=null&&l[i]?12-Math.abs(a[i]-l[i]):0;Math.round(p)===1?this.arrowPixelChange=!0:this.arrowPixelChange=!1}let m=this.arrowPixelChange?.5:0;this.popover.arrowElement.setAttribute("data-side",r),Object.assign(this.popover.arrowElement.style,{left:n!=null?`${n}px`:"",top:s!=null?`${s}px`:"",[i]:`${-this.popover.arrowElement.offsetHeight/2-m}px`})}updatePopoverStyle(t,e){this.popover.containerElement&&Object.assign(this.popover.containerElement.style,{left:`${t}px`,top:`${e}px`})}};var R=class extends W(Br(Fr(Yn(E)))){constructor(){super();this.id="";this.triggerID="";this.trigger=k.TRIGGER;this.placement=k.PLACEMENT;this.color=k.COLOR;this.visible=k.VISIBLE;this.offset=k.OFFSET;this.focusTrap=k.FOCUS_TRAP;this.preventScroll=k.PREVENT_SCROLL;this.showArrow=k.ARROW;this.closeButton=k.CLOSE_BUTTON;this.interactive=k.INTERACTIVE;this.delay=k.DELAY;this.hideOnEscape=k.HIDE_ON_ESCAPE;this.hideOnBlur=k.HIDE_ON_BLUR;this.hideOnOutsideClick=k.HIDE_ON_CLICK_OUTSIDE;this.focusBackToTrigger=k.FOCUS_BACK;this.backdrop=k.BACKDROP;this.flip=k.FLIP;this.size=k.SIZE;this.zIndex=k.Z_INDEX;this.appendTo="";this.closeButtonAriaLabel=null;this.dataRole=k.ROLE;this.arrowElement=null;this.triggerElement=null;this.containerElement=null;this.hoverTimer=null;this.isTriggerClicked=!1;this.openDelay=0;this.closeDelay=0;this.onOutsidePopoverClick=e=>{if(ot.peek()!==this)return;let r=!1,i=e.composedPath();r=this.contains(e.target)||i.includes(this.triggerElement);let n=this.renderRoot.querySelector(".popover-backdrop"),s=n?i.includes(n):!1;(!r||s)&&this.hidePopover()};this.onEscapeKeydown=e=>{!this.visible||e.code!=="Escape"||(e.preventDefault(),this.hidePopover())};this.onPopoverFocusOut=e=>{this.contains(e.relatedTarget)||this.hidePopover()};this.startCloseDelay=()=>{if(!this.interactive)this.hidePopover();else{if(this.isTriggerClicked)return;this.hoverTimer=window.setTimeout(()=>{this.visible=!1},this.closeDelay)}};this.cancelCloseDelay=()=>{this.hoverTimer&&(clearTimeout(this.hoverTimer),this.hoverTimer=null)};this.showPopover=()=>{this.cancelCloseDelay(),setTimeout(()=>{this.visible=!0,it.onShowPopover(this)},this.openDelay),ot.peek()!==this&&ot.push(this)};this.hidePopover=()=>{ot.peek()===this&&(setTimeout(()=>{this.visible=!1,it.onHidePopover(this),this.isTriggerClicked=!1},this.closeDelay),ot.pop())};this.togglePopoverVisible=()=>{this.isTriggerClicked?this.hidePopover():(this.showPopover(),this.isTriggerClicked=!0)};this.utils=new Gr(this)}async firstUpdated(e){super.firstUpdated(e),this.containerElement=this.renderRoot.querySelector(".popover-container"),this.utils.setupAppendTo(),[this.openDelay,this.closeDelay]=this.utils.setupDelay(),this.setupTriggerListener(),this.utils.setupAccessibility(),it.onCreatedPopover(this),this.visible&&(await this.positionPopover(),await this.handleCreatePopoverFirstUpdate())}async disconnectedCallback(){super.disconnectedCallback(),await this.removeEventListeners(),it.onDestroyedPopover(this),ot.remove(this)}setupTriggerListener(){var e,r;if(this.triggerID&&(this.triggerElement=document.getElementById(this.triggerID),!!this.triggerElement)){if(this.trigger==="mouseenter"&&(this.interactive?this.trigger="mouseenter click":this.trigger="mouseenter focusin"),this.trigger.includes("click")&&this.triggerElement.addEventListener("click",this.togglePopoverVisible),this.trigger.includes("mouseenter")){let i=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.addEventListener("mouseenter",this.showPopover),this.triggerElement.addEventListener("mouseleave",this.startCloseDelay),(e=this.containerElement)==null||e.addEventListener("mouseenter",this.cancelCloseDelay),(r=this.containerElement)==null||r.addEventListener("mouseleave",this.startCloseDelay),i==null||i.addEventListener("mouseenter",this.cancelCloseDelay)}this.trigger.includes("focusin")&&(this.triggerElement.addEventListener("focusin",this.showPopover),this.interactive||this.triggerElement.addEventListener("focusout",this.hidePopover)),this.addEventListener("focus-trap-exit",this.hidePopover)}}removeEventListeners(){var r,i;if(!this.triggerElement)return;let e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.removeEventListener("click",this.togglePopoverVisible),this.triggerElement.removeEventListener("mouseenter",this.showPopover),this.triggerElement.removeEventListener("mouseleave",this.hidePopover),(r=this.containerElement)==null||r.removeEventListener("mouseenter",this.cancelCloseDelay),(i=this.containerElement)==null||i.removeEventListener("mouseleave",this.startCloseDelay),this.triggerElement.removeEventListener("focusin",this.showPopover),this.triggerElement.removeEventListener("focusout",this.hidePopover),e==null||e.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("focus-trap-exit",this.hidePopover)}async updated(e){if(super.updated(e),e.has("visible")){let r=e.get("visible");await this.isOpenUpdated(r,this.visible)}if(e.has("placement")&&this.setAttribute("placement",Object.values(Do).includes(this.placement)?this.placement:k.PLACEMENT),e.has("delay")&&([this.openDelay,this.closeDelay]=this.utils.setupDelay()),e.has("trigger")){let i=this.trigger.split(" ").filter(n=>Object.values($o).includes(n));this.setAttribute("trigger",i.length>0?this.trigger:k.TRIGGER),this.removeEventListeners(),this.setupTriggerListener()}e.has("color")&&this.setAttribute("color",Object.values(Qt).includes(this.color)?this.color:k.COLOR),e.has("zIndex")&&this.setAttribute("z-index",`${this.zIndex}`),e.has("append-to")&&this.utils.setupAppendTo(),(e.has("interactive")||e.has("data-aria-label")||e.has("data-aria-labelledby"))&&this.utils.setupAccessibility()}async isOpenUpdated(e,r){var i,n,s,a;if(!(e===r||!this.triggerElement))if(r){if(this.enabledFocusTrap=this.focusTrap,this.enabledPreventScroll=this.preventScroll,this.backdrop){let l=this.renderRoot.querySelector(".popover-backdrop");l.style.zIndex=`${this.zIndex-1}`,this.triggerElement.style.zIndex=`${this.zIndex}`}this.positionPopover(),await this.handleCreatePopoverFirstUpdate(),this.hideOnBlur&&((i=this.containerElement)==null||i.addEventListener("focusout",this.onPopoverFocusOut),this.trigger==="click"&&(this.triggerElement.style.pointerEvents="none")),this.hideOnOutsideClick&&document.addEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.addEventListener("keydown",this.onEscapeKeydown),this.triggerElement.setAttribute("aria-expanded","true"),this.interactive&&this.triggerElement.setAttribute("aria-haspopup",this.triggerElement.getAttribute("aria-haspopup")||"dialog")}else this.hideOnBlur&&((n=this.containerElement)==null||n.removeEventListener("focusout",this.onPopoverFocusOut),this.trigger==="click"&&(this.triggerElement.style.pointerEvents="")),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.removeEventListener("keydown",this.onEscapeKeydown),(s=this.deactivateFocusTrap)==null||s.call(this),this.triggerElement.removeAttribute("aria-expanded"),this.interactive&&this.triggerElement.removeAttribute("aria-haspopup"),this.focusBackToTrigger&&((a=this.triggerElement)==null||a.focus())}async handleCreatePopoverFirstUpdate(){var e,r;this.visible&&this.interactive&&((e=this.setFocusableElements)==null||e.call(this),await this.updateComplete,(r=this.setInitialFocus)==null||r.call(this))}positionPopover(){if(!this.triggerElement||!this.containerElement)return;let e=[Pn()],r=this.offset;if(this.flip&&e.push(Un()),this.size){let i=this.containerElement.querySelector('[part="popover-content"]');e.push(Vn({apply({availableHeight:n}){i&&Object.assign(i.style,{maxHeight:`${n}px`})},padding:50}))}if(this.showArrow&&(this.arrowElement=this.renderRoot.querySelector(".popover-arrow"),this.arrowElement)){let i=this.arrowElement.offsetHeight;r=Math.sqrt(2*i**2)/2+this.offset,e.push(Hn({element:this.arrowElement,padding:12}))}e.push($n(r)),Dn(this.triggerElement,this.containerElement,async()=>{if(!this.triggerElement||!this.containerElement)return;let{x:i,y:n,middlewareData:s,placement:a}=await Fn(this.triggerElement,this.containerElement,{placement:this.placement,middleware:e});this.utils.updatePopoverStyle(i,n),s.arrow&&this.arrowElement&&this.utils.updateArrowStyle(s.arrow,a),this.trigger.includes("mouseenter")&&this.utils.setupHoverBridge(a)})}render(){return u`
|
1069
|
+
`,Bn=[Xa];var Gn=y.constructTagName("modalcontainer"),Qt={TONAL:"tonal",CONTRAST:"contrast"},Za={0:0,1:1,2:2,3:3,4:4},Jt={COLOR:Qt.TONAL,ELEVATION:Za[0],ROLE:"dialog",ARIA_MODAL:!1,CHILDREN:"Lorem ipsum dolor sit amet"};var qn=y.constructTagName("popover"),Do={LEFT_START:"left-start",LEFT:"left",LEFT_END:"left-end",RIGHT_START:"right-start",RIGHT:"right",RIGHT_END:"right-end",TOP_START:"top-start",TOP:"top",TOP_END:"top-end",BOTTOM_START:"bottom-start",BOTTOM:"bottom",BOTTOM_END:"bottom-end"},$o={CLICK:"click",MOUSEENTER:"mouseenter",FOCUSIN:"focusin",MANUAL:"manual"},R={PLACEMENT:Do.BOTTOM,TRIGGER:$o.CLICK,COLOR:Qt.TONAL,OFFSET:4,VISIBLE:!1,ARROW:!1,CLOSE_BUTTON:!1,FOCUS_TRAP:!1,INTERACTIVE:!1,PREVENT_SCROLL:!1,HIDE_ON_ESCAPE:!1,HIDE_ON_BLUR:!1,HIDE_ON_CLICK_OUTSIDE:!1,FOCUS_BACK:!1,BACKDROP:!1,FLIP:!0,SIZE:!1,DELAY:"0,0",ROLE:"dialog",Z_INDEX:1e3};var Yn=o=>{class t extends o{constructor(...i){super(...i);this.enabledFocusTrap=R.FOCUS_TRAP;this.enabledPreventScroll=R.PREVENT_SCROLL;this.focusTrapIndex=-1;this.focusableElements=[];this.shouldWrapFocus=()=>!0;this.addEventListener("keydown",this.handleKeydown)}deactivateFocusTrap(){this.enabledFocusTrap=!1,this.enabledPreventScroll=!1,this.focusTrapIndex=-1,document.body.style.overflow=""}hasNoClientRects(i){return i.getClientRects().length===0}hasZeroDimensions(i){let{width:n,height:s}=i.getBoundingClientRect(),{offsetWidth:a,offsetHeight:l}=i;return a+l+s+n===0}isNotVisible(i){return this.hasZeroDimensions(i)||this.hasNoClientRects(i)}hasHiddenStyle(i){let{display:n,opacity:s,visibility:a}=i.style;return n==="none"||s==="0"||a==="hidden"||a==="collapse"}hasComputedHidden(i){let n=getComputedStyle(i);return n.visibility==="hidden"||n.height==="0"||n.display==="none"}isHidden(i){return i.hasAttribute("hidden")||i.getAttribute("aria-hidden")==="true"||this.hasHiddenStyle(i)||this.isNotVisible(i)||this.hasComputedHidden(i)}isNotTabbable(i){return i.getAttribute("tabindex")==="-1"}isInteractiveElement(i){return!!(new Set(["BUTTON","DETAILS","EMBED","IFRAME","SELECT","TEXTAREA"]).has(i.tagName)||i instanceof HTMLAnchorElement&&i.hasAttribute("href")||i instanceof HTMLInputElement&&i.type!=="hidden"||(i instanceof HTMLAudioElement||i instanceof HTMLVideoElement)&&i.hasAttribute("controls")||(i instanceof HTMLImageElement||i instanceof HTMLObjectElement)&&i.hasAttribute("usemap")||i.hasAttribute("tabindex")&&i.tabIndex>-1)}isFocusable(i){return this.isHidden(i)||this.isNotTabbable(i)?!1:this.isInteractiveElement(i)}findFocusable(i,n=new Set){return i instanceof HTMLElement&&this.isFocusable(i)&&n.add(i),Array.from(i.children).forEach(a=>{let l=a;this.isFocusable(l)&&n.add(l),l.shadowRoot?this.findFocusable(l.shadowRoot,n):l.tagName==="SLOT"?l.assignedElements({flatten:!0}).forEach(h=>{h instanceof HTMLElement&&this.findFocusable(h,n)}):this.findFocusable(l,n)}),[...n]}setFocusableElements(){this.shadowRoot&&(this.focusableElements=this.findFocusable(this.shadowRoot,new Set))}setInitialFocus(i=0){this.focusableElements.length!==0&&(this.enabledPreventScroll&&(document.body.style.overflow="hidden"),this.focusableElements[i]&&(this.focusTrapIndex=i,this.focusableElements[i].focus()))}calculateNextIndex(i,n){let{length:s}=this.focusableElements,a=this.shouldWrapFocus();if(i===-1)return n>0?0:s-1;let l=i+n;return a?(l<0&&(l=s-1),l>=s&&(l=0)):(l<0&&(l=0),l>=s&&(l=s-1)),l}getDeepActiveElement(){var n;let i=document.activeElement||document.body;for(;i instanceof HTMLElement&&((n=i.shadowRoot)!=null&&n.activeElement);)i=i.shadowRoot.activeElement;return i||document.body}findElement(i){return this.focusableElements.findIndex(n=>this.isEqualFocusNode(i,n))}isEqualFocusNode(i,n){return i.nodeType>=0?n.isEqualNode(i)&&n===i:!1}trapFocus(i){if(this.focusableElements.length===0)return;let n=this.getDeepActiveElement(),s=this.findElement(n);i?this.focusTrapIndex=this.calculateNextIndex(s,-1):this.focusTrapIndex=this.calculateNextIndex(s,1);let a=this.focusableElements[this.focusTrapIndex];a&&a.focus()}handleKeydown(i){!this.enabledFocusTrap||!this.focusableElements.length||i.key==="Tab"&&(i.preventDefault(),this.trapFocus(i.shiftKey))}}return c([d({type:Boolean})],t.prototype,"enabledFocusTrap",2),c([d({type:Boolean})],t.prototype,"enabledPreventScroll",2),t};var Po=class{constructor(){this.stack=[]}push(t){this.stack.push(t)}pop(){return this.stack.pop()}peek(){return this.stack[this.stack.length-1]}remove(t){this.stack=this.stack.filter(e=>e!==t)}clear(){this.stack=[]}},ot=new Po;var W=o=>{class t extends o{constructor(){super(...arguments);this.dataAriaLabel=null}}return c([d({type:String,reflect:!0,attribute:"data-aria-label"})],t.prototype,"dataAriaLabel",2),t};var Fr=o=>{class t extends o{constructor(){super(...arguments);this.dataAriaDescribedby=null}}return c([d({type:String,reflect:!0,attribute:"data-aria-describedby"})],t.prototype,"dataAriaDescribedby",2),t};var Br=o=>{class t extends o{constructor(){super(...arguments);this.dataAriaLabelledby=null}}return c([d({type:String,reflect:!0,attribute:"data-aria-labelledby"})],t.prototype,"dataAriaLabelledby",2),t};var it=class{static dispatchPopoverEvent(t,e){e.dispatchEvent(new CustomEvent(t,{detail:{show:e.visible},composed:!0,bubbles:!0}))}static onShowPopover(t){this.dispatchPopoverEvent("popover-on-show",t)}static onHidePopover(t){this.dispatchPopoverEvent("popover-on-hide",t)}static onCreatedPopover(t){this.dispatchPopoverEvent("popover-on-created",t)}static onDestroyedPopover(t){this.dispatchPopoverEvent("popover-on-destroyed",t)}};var Gr=class{constructor(t){this.arrowPixelChange=!1;this.popover=t}setupDelay(){try{let[t,e]=this.popover.delay.split(",").map(r=>{let i=parseInt(r,10);if(Number.isNaN(i)||i<0)throw new Error(`Invalid delay value: ${r}`);return i});return[t,e]}catch{return this.popover.delay="0,0",[0,0]}}setupHoverBridge(t){var a;let e=this.popover.renderRoot.querySelector(".popover-hover-bridge");Object.assign(e.style,{top:"",left:"",right:"",bottom:""});let r=`calc(${this.popover.showArrow?"0.75rem + ":""}${this.popover.offset}px)`,i=(a=this.popover.shadowRoot)==null?void 0:a.querySelector("mdc-modalcontainer"),n=i.offsetHeight||0,s=i.offsetWidth||0;if(e)switch(t.split("-")[0]){case"top":e.style.height=r,e.style.bottom=`calc(-1 * (${r}))`,e.style.left="50%",e.style.width=`${s}px`;break;case"left":e.style.height=`${n}px`,e.style.width=r,e.style.right=`calc(-1.5 * (${r}))`;break;case"right":e.style.height=`${n}px`,e.style.width=r,e.style.left=`calc(-0.5 * (${r}))`;break;case"bottom":default:e.style.height=r,e.style.top=`calc(-1 * (${r}))`,e.style.left="50%",e.style.width=`${s}px`;break}}setupAppendTo(){if(this.popover.appendTo){let t=document.getElementById(this.popover.appendTo);t&&t.appendChild(this.popover)}}setupAccessibility(){var t,e,r;this.popover.interactive&&(this.popover.dataAriaLabel||(this.popover.dataAriaLabel=((t=this.popover.triggerElement)==null?void 0:t.ariaLabel)||((e=this.popover.triggerElement)==null?void 0:e.textContent)||""),this.popover.dataAriaLabelledby||(this.popover.dataAriaLabelledby=((r=this.popover.triggerElement)==null?void 0:r.id)||""))}updateArrowStyle(t,e){var h;if(!this.popover.arrowElement)return;let r=e.split("-")[0],i={top:"bottom",right:"left",bottom:"top",left:"right"}[r],{x:n,y:s}=t,a=this.popover.arrowElement.getBoundingClientRect(),l=(h=this.popover.arrowElement.offsetParent)==null?void 0:h.getBoundingClientRect();if(!this.arrowPixelChange){let p=l!=null&&l[i]?12-Math.abs(a[i]-l[i]):0;Math.round(p)===1?this.arrowPixelChange=!0:this.arrowPixelChange=!1}let m=this.arrowPixelChange?.5:0;this.popover.arrowElement.setAttribute("data-side",r),Object.assign(this.popover.arrowElement.style,{left:n!=null?`${n}px`:"",top:s!=null?`${s}px`:"",[i]:`${-this.popover.arrowElement.offsetHeight/2-m}px`})}updatePopoverStyle(t,e){this.popover.containerElement&&Object.assign(this.popover.containerElement.style,{left:`${t}px`,top:`${e}px`})}};var k=class extends W(Br(Fr(Yn(E)))){constructor(){super();this.id="";this.triggerID="";this.trigger=R.TRIGGER;this.placement=R.PLACEMENT;this.color=R.COLOR;this.visible=R.VISIBLE;this.offset=R.OFFSET;this.focusTrap=R.FOCUS_TRAP;this.preventScroll=R.PREVENT_SCROLL;this.showArrow=R.ARROW;this.closeButton=R.CLOSE_BUTTON;this.interactive=R.INTERACTIVE;this.delay=R.DELAY;this.hideOnEscape=R.HIDE_ON_ESCAPE;this.hideOnBlur=R.HIDE_ON_BLUR;this.hideOnOutsideClick=R.HIDE_ON_CLICK_OUTSIDE;this.focusBackToTrigger=R.FOCUS_BACK;this.backdrop=R.BACKDROP;this.flip=R.FLIP;this.size=R.SIZE;this.zIndex=R.Z_INDEX;this.appendTo="";this.closeButtonAriaLabel=null;this.dataRole=R.ROLE;this.arrowElement=null;this.triggerElement=null;this.containerElement=null;this.hoverTimer=null;this.isTriggerClicked=!1;this.openDelay=0;this.closeDelay=0;this.onOutsidePopoverClick=e=>{if(ot.peek()!==this)return;let r=!1,i=e.composedPath();r=this.contains(e.target)||i.includes(this.triggerElement);let n=this.renderRoot.querySelector(".popover-backdrop"),s=n?i.includes(n):!1;(!r||s)&&this.hidePopover()};this.onEscapeKeydown=e=>{!this.visible||e.code!=="Escape"||(e.preventDefault(),this.hidePopover())};this.onPopoverFocusOut=e=>{this.contains(e.relatedTarget)||this.hidePopover()};this.startCloseDelay=()=>{if(!this.interactive)this.hidePopover();else{if(this.isTriggerClicked)return;this.hoverTimer=window.setTimeout(()=>{this.visible=!1},this.closeDelay)}};this.cancelCloseDelay=()=>{this.hoverTimer&&(clearTimeout(this.hoverTimer),this.hoverTimer=null)};this.showPopover=()=>{this.cancelCloseDelay(),setTimeout(()=>{this.visible=!0,it.onShowPopover(this)},this.openDelay),ot.peek()!==this&&ot.push(this)};this.hidePopover=()=>{ot.peek()===this&&(setTimeout(()=>{this.visible=!1,it.onHidePopover(this),this.isTriggerClicked=!1},this.closeDelay),ot.pop())};this.togglePopoverVisible=()=>{this.isTriggerClicked?this.hidePopover():(this.showPopover(),this.isTriggerClicked=!0)};this.utils=new Gr(this)}async firstUpdated(e){super.firstUpdated(e),this.containerElement=this.renderRoot.querySelector(".popover-container"),this.utils.setupAppendTo(),[this.openDelay,this.closeDelay]=this.utils.setupDelay(),this.setupTriggerListener(),this.utils.setupAccessibility(),it.onCreatedPopover(this),this.visible&&(await this.positionPopover(),await this.handleCreatePopoverFirstUpdate())}async disconnectedCallback(){super.disconnectedCallback(),await this.removeEventListeners(),it.onDestroyedPopover(this),ot.remove(this)}setupTriggerListener(){var e,r;if(this.triggerID&&(this.triggerElement=document.getElementById(this.triggerID),!!this.triggerElement)){if(this.trigger==="mouseenter"&&(this.interactive?this.trigger="mouseenter click":this.trigger="mouseenter focusin"),this.trigger.includes("click")&&this.triggerElement.addEventListener("click",this.togglePopoverVisible),this.trigger.includes("mouseenter")){let i=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.addEventListener("mouseenter",this.showPopover),this.triggerElement.addEventListener("mouseleave",this.startCloseDelay),(e=this.containerElement)==null||e.addEventListener("mouseenter",this.cancelCloseDelay),(r=this.containerElement)==null||r.addEventListener("mouseleave",this.startCloseDelay),i==null||i.addEventListener("mouseenter",this.cancelCloseDelay)}this.trigger.includes("focusin")&&(this.triggerElement.addEventListener("focusin",this.showPopover),this.interactive||this.triggerElement.addEventListener("focusout",this.hidePopover)),this.addEventListener("focus-trap-exit",this.hidePopover)}}removeEventListeners(){var r,i;if(!this.triggerElement)return;let e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.removeEventListener("click",this.togglePopoverVisible),this.triggerElement.removeEventListener("mouseenter",this.showPopover),this.triggerElement.removeEventListener("mouseleave",this.hidePopover),(r=this.containerElement)==null||r.removeEventListener("mouseenter",this.cancelCloseDelay),(i=this.containerElement)==null||i.removeEventListener("mouseleave",this.startCloseDelay),this.triggerElement.removeEventListener("focusin",this.showPopover),this.triggerElement.removeEventListener("focusout",this.hidePopover),e==null||e.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("focus-trap-exit",this.hidePopover)}async updated(e){if(super.updated(e),e.has("visible")){let r=e.get("visible");await this.isOpenUpdated(r,this.visible)}if(e.has("placement")&&this.setAttribute("placement",Object.values(Do).includes(this.placement)?this.placement:R.PLACEMENT),e.has("delay")&&([this.openDelay,this.closeDelay]=this.utils.setupDelay()),e.has("trigger")){let i=this.trigger.split(" ").filter(n=>Object.values($o).includes(n));this.setAttribute("trigger",i.length>0?this.trigger:R.TRIGGER),this.removeEventListeners(),this.setupTriggerListener()}e.has("color")&&this.setAttribute("color",Object.values(Qt).includes(this.color)?this.color:R.COLOR),e.has("zIndex")&&this.setAttribute("z-index",`${this.zIndex}`),e.has("append-to")&&this.utils.setupAppendTo(),(e.has("interactive")||e.has("data-aria-label")||e.has("data-aria-labelledby"))&&this.utils.setupAccessibility()}async isOpenUpdated(e,r){var i,n,s,a;if(!(e===r||!this.triggerElement))if(r){if(this.enabledFocusTrap=this.focusTrap,this.enabledPreventScroll=this.preventScroll,this.backdrop){let l=this.renderRoot.querySelector(".popover-backdrop");l.style.zIndex=`${this.zIndex-1}`,this.triggerElement.style.zIndex=`${this.zIndex}`}this.positionPopover(),await this.handleCreatePopoverFirstUpdate(),this.hideOnBlur&&((i=this.containerElement)==null||i.addEventListener("focusout",this.onPopoverFocusOut),this.trigger==="click"&&(this.triggerElement.style.pointerEvents="none")),this.hideOnOutsideClick&&document.addEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.addEventListener("keydown",this.onEscapeKeydown),this.triggerElement.setAttribute("aria-expanded","true"),this.interactive&&this.triggerElement.setAttribute("aria-haspopup",this.triggerElement.getAttribute("aria-haspopup")||"dialog")}else this.hideOnBlur&&((n=this.containerElement)==null||n.removeEventListener("focusout",this.onPopoverFocusOut),this.trigger==="click"&&(this.triggerElement.style.pointerEvents="")),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.removeEventListener("keydown",this.onEscapeKeydown),(s=this.deactivateFocusTrap)==null||s.call(this),this.triggerElement.removeAttribute("aria-expanded"),this.interactive&&this.triggerElement.removeAttribute("aria-haspopup"),this.focusBackToTrigger&&((a=this.triggerElement)==null||a.focus())}async handleCreatePopoverFirstUpdate(){var e,r;this.visible&&this.interactive&&((e=this.setFocusableElements)==null||e.call(this),await this.updateComplete,(r=this.setInitialFocus)==null||r.call(this))}positionPopover(){if(!this.triggerElement||!this.containerElement)return;let e=[Pn()],r=this.offset;if(this.flip&&e.push(Un()),this.size){let i=this.containerElement.querySelector('[part="popover-content"]');e.push(Vn({apply({availableHeight:n}){i&&Object.assign(i.style,{maxHeight:`${n}px`})},padding:50}))}if(this.showArrow&&(this.arrowElement=this.renderRoot.querySelector(".popover-arrow"),this.arrowElement)){let i=this.arrowElement.offsetHeight;r=Math.sqrt(2*i**2)/2+this.offset,e.push(Hn({element:this.arrowElement,padding:12}))}e.push($n(r)),Dn(this.triggerElement,this.containerElement,async()=>{if(!this.triggerElement||!this.containerElement)return;let{x:i,y:n,middlewareData:s,placement:a}=await Fn(this.triggerElement,this.containerElement,{placement:this.placement,middleware:e});this.utils.updatePopoverStyle(i,n),s.arrow&&this.arrowElement&&this.utils.updateArrowStyle(s.arrow,a),this.trigger.includes("mouseenter")&&this.utils.setupHoverBridge(a)})}render(){return u`
|
1063
1070
|
${this.backdrop&&this.visible?u`<div class="popover-backdrop"></div>`:x}
|
1064
1071
|
<mdc-modalcontainer
|
1065
1072
|
class="popover-container"
|
@@ -1086,7 +1093,7 @@
|
|
1086
1093
|
<slot></slot>
|
1087
1094
|
</div>
|
1088
1095
|
</mdc-modalcontainer>
|
1089
|
-
`}};
|
1096
|
+
`}};k.styles=[...E.styles,...Bn],c([d({type:String})],k.prototype,"id",2),c([d({type:String})],k.prototype,"triggerID",2),c([d({type:String,reflect:!0})],k.prototype,"trigger",2),c([d({type:String,reflect:!0})],k.prototype,"placement",2),c([d({type:String,reflect:!0})],k.prototype,"color",2),c([d({type:Boolean,reflect:!0})],k.prototype,"visible",2),c([d({type:Number,reflect:!0})],k.prototype,"offset",2),c([d({type:Boolean,reflect:!0,attribute:"focus-trap"})],k.prototype,"focusTrap",2),c([d({type:Boolean,reflect:!0,attribute:"prevent-scroll"})],k.prototype,"preventScroll",2),c([d({type:Boolean,attribute:"show-arrow"})],k.prototype,"showArrow",2),c([d({type:Boolean,reflect:!0,attribute:"close-button"})],k.prototype,"closeButton",2),c([d({type:Boolean,reflect:!0})],k.prototype,"interactive",2),c([d({type:String,reflect:!0})],k.prototype,"delay",2),c([d({type:Boolean,reflect:!0,attribute:"hide-on-escape"})],k.prototype,"hideOnEscape",2),c([d({type:Boolean,reflect:!0,attribute:"hide-on-blur"})],k.prototype,"hideOnBlur",2),c([d({type:Boolean,reflect:!0,attribute:"hide-on-outside-click"})],k.prototype,"hideOnOutsideClick",2),c([d({type:Boolean,reflect:!0,attribute:"focus-back-to-trigger"})],k.prototype,"focusBackToTrigger",2),c([d({type:Boolean,reflect:!0})],k.prototype,"backdrop",2),c([d({type:Boolean,reflect:!0})],k.prototype,"flip",2),c([d({type:Boolean,reflect:!0})],k.prototype,"size",2),c([d({type:Number,reflect:!0,attribute:"z-index"})],k.prototype,"zIndex",2),c([d({type:String,reflect:!0,attribute:"append-to"})],k.prototype,"appendTo",2),c([d({type:String,attribute:"close-button-aria-label"})],k.prototype,"closeButtonAriaLabel",2),c([d({type:String,reflect:!0,attribute:"data-role"})],k.prototype,"dataRole",2);var Uo=k;var ja=[C,g`
|
1090
1097
|
:host {
|
1091
1098
|
--mdc-modalcontainer-primary-background-color: var(--mds-color-theme-background-solid-primary-normal);
|
1092
1099
|
--mdc-modalcontainer-border-color: var(--mds-color-theme-outline-secondary-normal);
|
@@ -1496,7 +1503,7 @@
|
|
1496
1503
|
|
1497
1504
|
.prefix-text{
|
1498
1505
|
color: var(--mdc-input-support-text-color);
|
1499
|
-
white-space: nowrap; //
|
1506
|
+
white-space: nowrap; // restrict prefix text to be in one line
|
1500
1507
|
}
|
1501
1508
|
|
1502
1509
|
:host(:not([disabled])) .input-container:hover{
|
@@ -1505,7 +1512,7 @@
|
|
1505
1512
|
|
1506
1513
|
:host(:not([disabled])) .input-container:active, :host(:not([disabled])) .input-container:focus-within{
|
1507
1514
|
background-color: var(--mdc-input-focused-background-color);
|
1508
|
-
border-color:
|
1515
|
+
border-color: var(--mdc-input-focused-border-color);
|
1509
1516
|
}
|
1510
1517
|
|
1511
1518
|
.input::placeholder{
|
@@ -1529,7 +1536,7 @@
|
|
1529
1536
|
opacity: 0;
|
1530
1537
|
pointer-events: none;
|
1531
1538
|
}
|
1532
|
-
|
1539
|
+
`,...$(!0)],ns=sl;var ss=y.constructTagName("formfieldwrapper"),fe={DEFAULT:"default",ERROR:"error",PRIORITY:"priority",SUCCESS:"success",WARNING:"warning"},H={VALIDATION:fe.DEFAULT,HELPER_TEXT_ID:"helper-text-id",HEADING_ID:"heading-id"},st={TAGNAME:z.SPAN,TYPE:O.BODY_MIDSIZE_REGULAR,HEADER_TYPE:O.BODY_MIDSIZE_BOLD};var al=[C,g`
|
1533
1540
|
:host {
|
1534
1541
|
flex-direction: column;
|
1535
1542
|
align-items: flex-start;
|
@@ -1604,7 +1611,7 @@
|
|
1604
1611
|
</div>`}renderHelperText(){return this.helpText?u`<div class="mdc-help-text" part="mdc-help-text">
|
1605
1612
|
<slot name="help-icon">${this.renderHelpTextIcon()}</slot>
|
1606
1613
|
<slot name="help-text">${this.renderHelpText()}</slot>
|
1607
|
-
</div>`:x}};we.styles=[...E.styles,...as],c([d({reflect:!0,type:String})],we.prototype,"label",2),c([d({type:String,reflect:!0,attribute:"required-label"})],we.prototype,"requiredLabel",2),c([d({type:String})],we.prototype,"id",2),c([d({reflect:!0,attribute:"help-text-type"})],we.prototype,"helpTextType",2),c([d({type:String,reflect:!0,attribute:"help-text"})],we.prototype,"helpText",2);var ee=we;ee.register(ss);var
|
1614
|
+
</div>`:x}};we.styles=[...E.styles,...as],c([d({reflect:!0,type:String})],we.prototype,"label",2),c([d({type:String,reflect:!0,attribute:"required-label"})],we.prototype,"requiredLabel",2),c([d({type:String})],we.prototype,"id",2),c([d({reflect:!0,attribute:"help-text-type"})],we.prototype,"helpTextType",2),c([d({type:String,reflect:!0,attribute:"help-text"})],we.prototype,"helpText",2);var ee=we;ee.register(ss);var kt=ee;var cs=y.constructTagName("input"),ds={OFF:"off",NONE:"none",ON:"on",SENTENCES:"sentences",WORDS:"words",CHARACTERS:"characters"},ms={MAX_LENGTH:10,HELPERTEXT:"Prefix text should not exceed 10 characters",VALIDATION:fe.ERROR},He={VALIDATION:fe.DEFAULT,ICON_SIZE_VALUE:1,ICON_SIZE_UNIT:"rem",CLEAR_BUTTON_ICON:"cancel-bold",CLEAR_BUTTON_VARIANT:je.TERTIARY,CLEAR_BUTTON_SIZE:Se[20],PREFIX_TEXT_TYPE:O.BODY_MIDSIZE_REGULAR,PREFIX_TEXT_TAG:z.SPAN};var M=class extends he(W(kt)){constructor(){super(...arguments);this.placeholder="";this.readonly=!1;this.trailingButton=!1;this.autocapitalize=ds.OFF;this.autocomplete="off";this.autofocus=!1;this.clearAriaLabel=""}connectedCallback(){super.connectedCallback(),this.updateComplete.then(()=>{this.inputElement&&(this.inputElement.checkValidity(),this.setInputValidity(),this.internals.setFormValue(this.inputElement.value))}).catch(e=>{this.onerror&&this.onerror(e)})}formResetCallback(){this.value="",this.requestUpdate()}formStateRestoreCallback(e){this.value=e}handleValueChange(){this.updateComplete.then(()=>{this.setInputValidity()}).catch(e=>{this.onerror&&this.onerror(e)})}updated(e){super.updated(e),e.has("value")&&this.handleValueChange()}setInputValidity(){this.validationMessage&&this.value===""?this.inputElement.setCustomValidity(this.validationMessage):this.inputElement.setCustomValidity(""),this.setValidity()}attributeChangedCallback(e,r,i){super.attributeChangedCallback(e,r,i),["maxlength","minlength","pattern","required"].includes(e)&&this.updateComplete.then(()=>{this.setInputValidity()}).catch(s=>{this.onerror&&this.onerror(s)})}updateValue(){this.value=this.inputElement.value,this.internals.setFormValue(this.inputElement.value)}onInput(){this.updateValue(),this.setInputValidity()}onChange(e){this.updateValue(),this.setInputValidity();let r=e.constructor;this.dispatchEvent(new r(e.type,e))}handleKeyDown(e){var r;e.key==="Enter"&&((r=this.form)==null||r.requestSubmit())}renderLeadingIcon(){return this.leadingIcon?u`
|
1608
1615
|
<mdc-icon
|
1609
1616
|
class="leading-icon"
|
1610
1617
|
part="leading-icon"
|
@@ -1624,7 +1631,7 @@
|
|
1624
1631
|
`:x}clearInputText(){var e;this.value="",(e=this.inputElement)==null||e.focus()}renderTrailingButton(){return this.trailingButton?u`
|
1625
1632
|
<mdc-button
|
1626
1633
|
part='trailing-button'
|
1627
|
-
class='${this.value?"":"hidden"}'
|
1634
|
+
class='own-focus-ring ${this.value?"":"hidden"}'
|
1628
1635
|
prefix-icon='${He.CLEAR_BUTTON_ICON}'
|
1629
1636
|
variant='${He.CLEAR_BUTTON_VARIANT}'
|
1630
1637
|
size="${He.CLEAR_BUTTON_SIZE}"
|
@@ -1670,7 +1677,7 @@
|
|
1670
1677
|
<slot name="trailing-button">${this.renderTrailingButton()}</slot>
|
1671
1678
|
</div>
|
1672
1679
|
${this.helpText?this.renderHelperText():x}
|
1673
|
-
`}};M.styles=[...
|
1680
|
+
`}};M.styles=[...kt.styles,...ns],c([d({type:String})],M.prototype,"placeholder",2),c([d({type:Boolean})],M.prototype,"readonly",2),c([d({type:String,attribute:"prefix-text"})],M.prototype,"prefixText",2),c([d({type:String,attribute:"leading-icon"})],M.prototype,"leadingIcon",2),c([d({type:Boolean,attribute:"trailing-button"})],M.prototype,"trailingButton",2),c([d({type:Number})],M.prototype,"maxlength",2),c([d({type:Number})],M.prototype,"minlength",2),c([d({type:String})],M.prototype,"autocapitalize",2),c([d({type:String})],M.prototype,"autocomplete",2),c([d({type:Boolean})],M.prototype,"autofocus",2),c([d({type:String})],M.prototype,"dirname",2),c([d({type:String})],M.prototype,"pattern",2),c([d({type:String})],M.prototype,"list",2),c([d({type:Number})],M.prototype,"size",2),c([d({type:String,attribute:"clear-aria-label"})],M.prototype,"clearAriaLabel",2);var qo=M;qo.register(cs);var ll=qo;var hs=y.constructTagName("link"),qr={LARGE:"large",MIDSIZE:"midsize",SMALL:"small"},Yr={LARGE:1,MIDSIZE:.875,SMALL:.75},Wr={INLINE:!1,INVERTED:!1,LINK_SIZE:qr.LARGE};var cl=[C,g`
|
1674
1681
|
|
1675
1682
|
:host {
|
1676
1683
|
|
@@ -1685,7 +1692,9 @@
|
|
1685
1692
|
--mdc-link-inverted-color-hover: var(--mds-color-theme-inverted-text-accent-hover);
|
1686
1693
|
--mdc-link-inverted-color-normal: var(--mds-color-theme-inverted-text-accent-normal);
|
1687
1694
|
--mdc-link-text-decoration-disabled: underline;
|
1695
|
+
}
|
1688
1696
|
|
1697
|
+
:host::part(link-container){
|
1689
1698
|
border-radius: var(--mdc-link-border-radius);
|
1690
1699
|
color: var(--mdc-link-color-normal);
|
1691
1700
|
}
|
@@ -1701,11 +1710,11 @@
|
|
1701
1710
|
text-underline-position: from-font;
|
1702
1711
|
}
|
1703
1712
|
|
1704
|
-
:host(:hover) {
|
1713
|
+
:host(:hover)::part(link-container) {
|
1705
1714
|
color: var(--mdc-link-color-hover);
|
1706
1715
|
}
|
1707
1716
|
|
1708
|
-
:host(:active) {
|
1717
|
+
:host(:active)::part(link-container) {
|
1709
1718
|
color: var(--mdc-link-color-active);
|
1710
1719
|
}
|
1711
1720
|
|
@@ -1713,19 +1722,19 @@
|
|
1713
1722
|
display: inline-flex;
|
1714
1723
|
}
|
1715
1724
|
|
1716
|
-
:host([inverted]) {
|
1725
|
+
:host([inverted])::part(link-container) {
|
1717
1726
|
color: var(--mdc-link-inverted-color-normal);
|
1718
1727
|
}
|
1719
1728
|
|
1720
|
-
:host([inverted]:hover) {
|
1729
|
+
:host([inverted]:hover)::part(link-container) {
|
1721
1730
|
color: var(--mdc-link-inverted-color-hover);
|
1722
1731
|
}
|
1723
1732
|
|
1724
|
-
:host([inverted]:active) {
|
1733
|
+
:host([inverted]:active)::part(link-container) {
|
1725
1734
|
color: var(--mdc-link-inverted-color-active);
|
1726
1735
|
}
|
1727
1736
|
|
1728
|
-
:host([size="large"]) {
|
1737
|
+
:host([size="large"])::part(link-container) {
|
1729
1738
|
font-size: var(--mds-font-apps-body-large-regular-font-size);
|
1730
1739
|
font-weight: var(--mds-font-apps-body-large-regular-font-weight);
|
1731
1740
|
line-height: var(--mds-font-apps-body-large-regular-line-height);
|
@@ -1733,7 +1742,7 @@
|
|
1733
1742
|
text-transform: var(--mds-font-apps-body-large-regular-text-case);
|
1734
1743
|
}
|
1735
1744
|
|
1736
|
-
:host([size="midsize"]) {
|
1745
|
+
:host([size="midsize"])::part(link-container) {
|
1737
1746
|
font-size: var(--mds-font-apps-body-midsize-regular-font-size);
|
1738
1747
|
font-weight: var(--mds-font-apps-body-midsize-regular-font-weight);
|
1739
1748
|
line-height: var(--mds-font-apps-body-midsize-regular-line-height);
|
@@ -1741,7 +1750,7 @@
|
|
1741
1750
|
text-transform: var(--mds-font-apps-body-midsize-regular-text-case);
|
1742
1751
|
}
|
1743
1752
|
|
1744
|
-
:host([size="small"]) {
|
1753
|
+
:host([size="small"])::part(link-container) {
|
1745
1754
|
font-size: var(--mds-font-apps-body-small-regular-font-size);
|
1746
1755
|
font-weight: var(--mds-font-apps-body-small-regular-font-weight);
|
1747
1756
|
line-height: var(--mds-font-apps-body-small-regular-line-height);
|
@@ -1749,7 +1758,9 @@
|
|
1749
1758
|
text-transform: var(--mds-font-apps-body-small-regular-text-case);
|
1750
1759
|
}
|
1751
1760
|
|
1752
|
-
:host([size="large"]:hover)
|
1761
|
+
:host([size="large"]:hover)::part(link-container),
|
1762
|
+
:host([size="large"]:active)::part(link-container),
|
1763
|
+
:host([size="large"][inline])::part(link-container) {
|
1753
1764
|
font-size: var(--mds-font-apps-body-large-regular-underline-font-size);
|
1754
1765
|
font-weight: var(--mds-font-apps-body-large-regular-underline-font-weight);
|
1755
1766
|
line-height: var(--mds-font-apps-body-large-regular-underline-line-height);
|
@@ -1757,7 +1768,9 @@
|
|
1757
1768
|
text-transform: var(--mds-font-apps-body-large-regular-underline-text-case);
|
1758
1769
|
}
|
1759
1770
|
|
1760
|
-
:host([size="midsize"]:hover)
|
1771
|
+
:host([size="midsize"]:hover)::part(link-container),
|
1772
|
+
:host([size="midsize"]:active)::part(link-container),
|
1773
|
+
:host([size="midsize"][inline])::part(link-container) {
|
1761
1774
|
font-size: var(--mds-font-apps-body-midsize-regular-underline-font-size);
|
1762
1775
|
font-weight: var(--mds-font-apps-body-midsize-regular-underline-font-weight);
|
1763
1776
|
line-height: var(--mds-font-apps-body-midsize-regular-underline-line-height);
|
@@ -1765,7 +1778,9 @@
|
|
1765
1778
|
text-transform: var(--mds-font-apps-body-midsize-regular-underline-text-case);
|
1766
1779
|
}
|
1767
1780
|
|
1768
|
-
:host([size="small"]:hover)
|
1781
|
+
:host([size="small"]:hover)::part(link-container),
|
1782
|
+
:host([size="small"]:active)::part(link-container),
|
1783
|
+
:host([size="small"][inline])::part(link-container) {
|
1769
1784
|
font-size: var(--mds-font-apps-body-small-regular-underline-font-size);
|
1770
1785
|
font-weight: var(--mds-font-apps-body-small-regular-underline-font-weight);
|
1771
1786
|
line-height: var(--mds-font-apps-body-small-regular-underline-line-height);
|
@@ -1773,19 +1788,23 @@
|
|
1773
1788
|
text-transform: var(--mds-font-apps-body-small-regular-underline-text-case);
|
1774
1789
|
}
|
1775
1790
|
|
1776
|
-
:host([disabled]) {
|
1791
|
+
:host([disabled])::part(link-container) {
|
1777
1792
|
color: var(--mdc-link-color-disabled);
|
1778
1793
|
pointer-events: none;
|
1779
1794
|
}
|
1780
1795
|
|
1781
|
-
:host([inverted][disabled]) {
|
1796
|
+
:host([inverted][disabled])::part(link-container) {
|
1782
1797
|
color: var(--mdc-link-inverted-color-disabled);
|
1783
1798
|
}
|
1784
|
-
`,...$(),g`
|
1785
|
-
:host(:active) {
|
1799
|
+
`,...$(!0),g`
|
1800
|
+
:host(:active)::part(link-container) {
|
1786
1801
|
box-shadow: none;
|
1787
1802
|
}
|
1788
|
-
`],ps=cl;var at=class extends At(de(E)){constructor(){super(...arguments);this.inline=Wr.INLINE;this.inverted=Wr.INVERTED;this.size=Wr.LINK_SIZE;this.prevTabindex=null}getIconSize(){switch(this.size){case qr.SMALL:return Yr.SMALL;case qr.MIDSIZE:return Yr.MIDSIZE;default:return Yr.LARGE}}setDisabled(e){e?(this.prevTabindex=this.hasAttribute("tabindex")?this.tabIndex:null,this.tabIndex=-1,this.setAttribute("aria-disabled","true")):this.prevTabindex===null?(this.removeAttribute("tabindex"),this.removeAttribute("aria-disabled")):(this.tabIndex=this.prevTabindex,this.removeAttribute("aria-disabled"))}updateTrailingIcon(){var i,n;let e=(n=(i=this.shadowRoot)==null?void 0:i.querySelector("slot"))==null?void 0:n.assignedElements({flatten:!0}).find(s=>s.tagName==="A"),r=this.getIconSize();if(this.iconName&&e){let s=document.createElement("mdc-icon");s.setAttribute("name",this.iconName),s.setAttribute("size",`${r}`),s.setAttribute("length-unit","rem"),e.appendChild(s)}}update(e){super.update(e),e.has("disabled")&&this.setDisabled(this.disabled)}render(){return u
|
1803
|
+
`],ps=cl;var at=class extends At(de(E)){constructor(){super(...arguments);this.inline=Wr.INLINE;this.inverted=Wr.INVERTED;this.size=Wr.LINK_SIZE;this.prevTabindex=null}getIconSize(){switch(this.size){case qr.SMALL:return Yr.SMALL;case qr.MIDSIZE:return Yr.MIDSIZE;default:return Yr.LARGE}}setDisabled(e){e?(this.prevTabindex=this.hasAttribute("tabindex")?this.tabIndex:null,this.tabIndex=-1,this.setAttribute("aria-disabled","true")):this.prevTabindex===null?(this.removeAttribute("tabindex"),this.removeAttribute("aria-disabled")):(this.tabIndex=this.prevTabindex,this.removeAttribute("aria-disabled"))}updateTrailingIcon(){var i,n;let e=(n=(i=this.shadowRoot)==null?void 0:i.querySelector("slot"))==null?void 0:n.assignedElements({flatten:!0}).find(s=>s.tagName==="A"),r=this.getIconSize();if(this.iconName&&e){let s=document.createElement("mdc-icon");s.setAttribute("name",this.iconName),s.setAttribute("size",`${r}`),s.setAttribute("length-unit","rem"),e.appendChild(s)}}update(e){super.update(e),e.has("disabled")&&this.setDisabled(this.disabled)}render(){return u`
|
1804
|
+
<div part='link-container' class='mdc-focus-ring'>
|
1805
|
+
<slot @slotchange=${this.updateTrailingIcon}></slot>
|
1806
|
+
</div>
|
1807
|
+
`}};at.styles=[...E.styles,...ps],c([d({type:Boolean,reflect:!0})],at.prototype,"inline",2),c([d({type:Boolean,reflect:!0})],at.prototype,"inverted",2),c([d({type:String,reflect:!0})],at.prototype,"size",2);var Yo=at;Yo.register(hs);var dl=Yo;var ml=[C,g`
|
1789
1808
|
:host {
|
1790
1809
|
--mdc-toggle-width: 3rem;
|
1791
1810
|
--mdc-toggle-height: 1.5rem;
|
@@ -1929,7 +1948,7 @@
|
|
1929
1948
|
border: var(--mdc-toggle-border);
|
1930
1949
|
}
|
1931
1950
|
}
|
1932
|
-
`,...$(!0)],us=ml;var fs=y.constructTagName("toggle"),Wo={DEFAULT:"default",COMPACT:"compact"},Xo={CHECKED:"check-bold",UNCHECKED:"cancel-bold"},gs={compact:.75,default:1.25},Zo={SIZE:Wo.DEFAULT,VALIDATION_MESSAGE:"Please toggle this switch if you want to proceed."};var lt=class extends he(W(
|
1951
|
+
`,...$(!0)],us=ml;var fs=y.constructTagName("toggle"),Wo={DEFAULT:"default",COMPACT:"compact"},Xo={CHECKED:"check-bold",UNCHECKED:"cancel-bold"},gs={compact:.75,default:1.25},Zo={SIZE:Wo.DEFAULT,VALIDATION_MESSAGE:"Please toggle this switch if you want to proceed."};var lt=class extends he(W(kt)){constructor(){super();this.checked=!1;this.size=Zo.SIZE;this.autofocus=!1;this.helpTextType=void 0}formResetCallback(){this.checked=!1}formStateRestoreCallback(e){e&&(this.checked=!0)}manageRequired(){!this.checked&&this.requiredLabel?(this.validationMessage?this.inputElement.setCustomValidity(this.validationMessage):this.inputElement.setCustomValidity(""),this.setValidity()):this.internals.setValidity({})}setFormValue(){let e=null;this.checked?e=this.value?this.value:"isActive":e=null,this.manageRequired(),this.internals.setFormValue(e)}toggleState(){this.disabled||(this.checked=!this.checked)}handleKeyDown(e){var r;e.key==="Enter"&&((r=this.form)==null||r.requestSubmit())}handleChange(e){this.toggleState();let r=e.constructor;this.dispatchEvent(new r(e.type,e))}setToggleSize(e){this.setAttribute("size",Object.values(Wo).includes(e)?e:Zo.SIZE)}update(e){super.update(e),e.has("checked")&&this.setFormValue(),e.has("size")&&this.setToggleSize(this.size)}render(){var e;return u`
|
1933
1952
|
<div class="mdc-toggle__container mdc-focus-ring">
|
1934
1953
|
<input
|
1935
1954
|
id="${this.id}"
|
@@ -1960,7 +1979,7 @@
|
|
1960
1979
|
</div>
|
1961
1980
|
${this.renderLabel()}
|
1962
1981
|
${this.renderHelperText()}
|
1963
|
-
`}};lt.styles=[...
|
1982
|
+
`}};lt.styles=[...kt.styles,...us],c([d({type:Boolean,reflect:!0})],lt.prototype,"checked",2),c([d({type:String,reflect:!0})],lt.prototype,"size",2),c([d({type:Boolean,reflect:!0})],lt.prototype,"autofocus",2);var jo=lt;jo.register(fs);var hl=jo;var vs=y.constructTagName("checkbox"),Ko={CHECKED:"check-bold",INDETERMINATE:"minus-bold"};var pl=[g`
|
1964
1983
|
:host {
|
1965
1984
|
--mdc-checkbox-background-color-hover: var(--mds-color-theme-control-inactive-hover);
|
1966
1985
|
--mdc-checkbox-border-color: var(--mds-color-theme-outline-button-normal);
|
@@ -2288,7 +2307,7 @@
|
|
2288
2307
|
`}};dt.styles=[...ee.styles,...ys],c([d({type:Boolean,reflect:!0})],dt.prototype,"checked",2),c([d({type:Boolean,reflect:!0})],dt.prototype,"readonly",2),c([d({type:Boolean,reflect:!0})],dt.prototype,"autofocus",2);var Jo=dt;var Xr=y.constructTagName("radio");Jo.register(Xr);var gl=Jo;function mt(o,t,e){var n;let r=(n=e.initialDeps)!=null?n:[],i;return()=>{var s,a,l,m;let h;e.key&&((s=e.debug)!=null&&s.call(e))&&(h=Date.now());let p=o();if(!(p.length!==r.length||p.some((b,T)=>r[T]!==b)))return i;r=p;let f;if(e.key&&((a=e.debug)!=null&&a.call(e))&&(f=Date.now()),i=t(...p),e.key&&((l=e.debug)!=null&&l.call(e))){let b=Math.round((Date.now()-h)*100)/100,T=Math.round((Date.now()-f)*100)/100,_=T/16,S=(I,w)=>{for(I=String(I);I.length<w;)I=" "+I;return I};console.info(`%c\u23F1 ${S(T,5)} /${S(b,5)} ms`,`
|
2289
2308
|
font-size: .6rem;
|
2290
2309
|
font-weight: bold;
|
2291
|
-
color: hsl(${Math.max(0,Math.min(120-120*_,120))}deg 100% 31%);`,e==null?void 0:e.key)}return(m=e==null?void 0:e.onChange)==null||m.call(e,i),i}}function Zr(o,t){if(o===void 0)throw new Error(`Unexpected undefined${t?`: ${t}`:""}`);return o}var xs=(o,t)=>Math.abs(o-t)<1,Es=(o,t,e)=>{let r;return function(...i){o.clearTimeout(r),r=o.setTimeout(()=>t.apply(this,i),e)}};var vl=o=>o,bl=o=>{let t=Math.max(o.startIndex-o.overscan,0),e=Math.min(o.endIndex+o.overscan,o.count-1),r=[];for(let i=t;i<=e;i++)r.push(i);return r},As=(o,t)=>{let e=o.scrollElement;if(!e)return;let r=o.targetWindow;if(!r)return;let i=s=>{let{width:a,height:l}=s;t({width:Math.round(a),height:Math.round(l)})};if(i(e.getBoundingClientRect()),!r.ResizeObserver)return()=>{};let n=new r.ResizeObserver(s=>{let a=s[0];if(a!=null&&a.borderBoxSize){let l=a.borderBoxSize[0];if(l){i({width:l.inlineSize,height:l.blockSize});return}}i(e.getBoundingClientRect())});return n.observe(e,{box:"border-box"}),()=>{n.unobserve(e)}},Ts={passive:!0};var yl=typeof window>"u"?!0:"onscrollend"in window,Ss=(o,t)=>{let e=o.scrollElement;if(!e)return;let r=o.targetWindow;if(!r)return;let i=0,n=o.options.useScrollendEvent&&yl?()=>{}:Es(r,()=>{t(i,!1)},o.options.isScrollingResetDelay),s=m=>()=>{let{horizontal:h,isRtl:p}=o.options;i=h?e.scrollLeft*(p&&-1||1):e.scrollTop,n(),t(i,m)},a=s(!0),l=s(!1);return l(),e.addEventListener("scroll",a,Ts),e.addEventListener("scrollend",l,Ts),()=>{e.removeEventListener("scroll",a),e.removeEventListener("scrollend",l)}};var xl=(o,t,e)=>{if(t!=null&&t.borderBoxSize){let r=t.borderBoxSize[0];if(r)return Math.round(r[e.options.horizontal?"inlineSize":"blockSize"])}return Math.round(o.getBoundingClientRect()[e.options.horizontal?"width":"height"])};var _s=(o,{adjustments:t=0,behavior:e},r)=>{var i,n;let s=o+t;(n=(i=r.scrollElement)==null?void 0:i.scrollTo)==null||n.call(i,{[r.options.horizontal?"left":"top"]:s,behavior:e})},jr=class{constructor(t){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.scrollToIndexTimeoutId=null,this.measurementsCache=[],this.itemSizeCache=new Map,this.pendingMeasuredCacheIndexes=[],this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let e=null,r=()=>e||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:e=new this.targetWindow.ResizeObserver(i=>{i.forEach(n=>{this._measureElement(n.target,n)})}));return{disconnect:()=>{var i;(i=r())==null||i.disconnect(),e=null},observe:i=>{var n;return(n=r())==null?void 0:n.observe(i,{box:"border-box"})},unobserve:i=>{var n;return(n=r())==null?void 0:n.unobserve(i)}}})(),this.range=null,this.setOptions=e=>{Object.entries(e).forEach(([r,i])=>{typeof i>"u"&&delete e[r]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:vl,rangeExtractor:bl,onChange:()=>{},measureElement:xl,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!0,...e}},this.notify=e=>{var r,i;(i=(r=this.options).onChange)==null||i.call(r,this,e)},this.maybeNotify=mt(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),e=>{this.notify(e)},{key:!1,debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(e=>e()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var i;var e;let r=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==r){if(this.cleanup(),!r){this.maybeNotify();return}this.scrollElement=r,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=(i=(e=this.scrollElement)==null?void 0:e.window)!=null?i:null,this.elementsCache.forEach(n=>{this.observer.observe(n)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,n=>{this.scrollRect=n,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(n,s)=>{this.scrollAdjustments=0,this.scrollDirection=s?this.getScrollOffset()<n?"forward":"backward":null,this.scrollOffset=n,this.isScrolling=s,this.maybeNotify()}))}},this.getSize=()=>{var e;return this.options.enabled?(this.scrollRect=(e=this.scrollRect)!=null?e:this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0)},this.getScrollOffset=()=>{var e;return this.options.enabled?(this.scrollOffset=(e=this.scrollOffset)!=null?e:typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset,this.scrollOffset):(this.scrollOffset=null,0)},this.getFurthestMeasurement=(e,r)=>{let i=new Map,n=new Map;for(let s=r-1;s>=0;s--){let a=e[s];if(i.has(a.lane))continue;let l=n.get(a.lane);if(l==null||a.end>l.end?n.set(a.lane,a):a.end<l.end&&i.set(a.lane,!0),i.size===this.options.lanes)break}return n.size===this.options.lanes?Array.from(n.values()).sort((s,a)=>s.end===a.end?s.index-a.index:s.end-a.end)[0]:void 0},this.getMeasurementOptions=mt(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(e,r,i,n,s)=>(this.pendingMeasuredCacheIndexes=[],{count:e,paddingStart:r,scrollMargin:i,getItemKey:n,enabled:s}),{key:!1}),this.getMeasurements=mt(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:e,paddingStart:r,scrollMargin:i,getItemKey:n,enabled:s},a)=>{if(!s)return this.measurementsCache=[],this.itemSizeCache.clear(),[];this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(h=>{this.itemSizeCache.set(h.key,h.size)}));let l=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];let m=this.measurementsCache.slice(0,l);for(let h=l;h<e;h++){let p=n(h),v=this.options.lanes===1?m[h-1]:this.getFurthestMeasurement(m,h),f=v?v.end+this.options.gap:r+i,b=a.get(p),T=typeof b=="number"?b:this.options.estimateSize(h),_=f+T,S=v?v.lane:h%this.options.lanes;m[h]={index:h,start:f,size:T,end:_,key:p,lane:S}}return this.measurementsCache=m,m},{key:!1,debug:()=>this.options.debug}),this.calculateRange=mt(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset()],(e,r,i)=>this.range=e.length>0&&r>0?El({measurements:e,outerSize:r,scrollOffset:i}):null,{key:!1,debug:()=>this.options.debug}),this.getIndexes=mt(()=>{let e=null,r=null,i=this.calculateRange();return i&&(e=i.startIndex,r=i.endIndex),[this.options.rangeExtractor,this.options.overscan,this.options.count,e,r]},(e,r,i,n,s)=>n===null||s===null?[]:e({startIndex:n,endIndex:s,overscan:r,count:i}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=e=>{let r=this.options.indexAttribute,i=e.getAttribute(r);return i?parseInt(i,10):(console.warn(`Missing attribute name '${r}={index}' on measured element.`),-1)},this._measureElement=(e,r)=>{let i=this.indexFromElement(e),n=this.measurementsCache[i];if(!n)return;let s=n.key,a=this.elementsCache.get(s);a!==e&&(a&&this.observer.unobserve(a),this.observer.observe(e),this.elementsCache.set(s,e)),e.isConnected&&this.resizeItem(i,this.options.measureElement(e,r,this))},this.resizeItem=(e,r)=>{var a;let i=this.measurementsCache[e];if(!i)return;let n=(a=this.itemSizeCache.get(i.key))!=null?a:i.size,s=r-n;s!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(i,s,this):i.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=s,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(i.index),this.itemSizeCache=new Map(this.itemSizeCache.set(i.key,r)),this.notify(!1))},this.measureElement=e=>{if(!e){this.elementsCache.forEach((r,i)=>{r.isConnected||(this.observer.unobserve(r),this.elementsCache.delete(i))});return}this._measureElement(e,void 0)},this.getVirtualItems=mt(()=>[this.getIndexes(),this.getMeasurements()],(e,r)=>{let i=[];for(let n=0,s=e.length;n<s;n++){let a=e[n],l=r[a];i.push(l)}return i},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=e=>{let r=this.getMeasurements();if(r.length!==0)return Zr(r[Is(0,r.length-1,i=>Zr(r[i]).start,e)])},this.getOffsetForAlignment=(e,r)=>{let i=this.getSize(),n=this.getScrollOffset();r==="auto"&&e>=n+i&&(r="end"),r==="end"&&(e-=i);let s=this.options.horizontal?"scrollWidth":"scrollHeight",l=(this.scrollElement?"document"in this.scrollElement?this.scrollElement.document.documentElement[s]:this.scrollElement[s]:0)-i;return Math.max(Math.min(l,e),0)},this.getOffsetForIndex=(e,r="auto")=>{e=Math.max(0,Math.min(e,this.options.count-1));let i=this.measurementsCache[e];if(!i)return;let n=this.getSize(),s=this.getScrollOffset();if(r==="auto")if(i.end>=s+n-this.options.scrollPaddingEnd)r="end";else if(i.start<=s+this.options.scrollPaddingStart)r="start";else return[s,r];let a=i.start-this.options.scrollPaddingStart+(i.size-n)/2;switch(r){case"center":return[this.getOffsetForAlignment(a,r),r];case"end":return[this.getOffsetForAlignment(i.end+this.options.scrollPaddingEnd,r),r];default:return[this.getOffsetForAlignment(i.start-this.options.scrollPaddingStart,r),r]}},this.isDynamicMode=()=>this.elementsCache.size>0,this.cancelScrollToIndex=()=>{this.scrollToIndexTimeoutId!==null&&this.targetWindow&&(this.targetWindow.clearTimeout(this.scrollToIndexTimeoutId),this.scrollToIndexTimeoutId=null)},this.scrollToOffset=(e,{align:r="start",behavior:i}={})=>{this.cancelScrollToIndex(),i==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(e,r),{adjustments:void 0,behavior:i})},this.scrollToIndex=(e,{align:r="auto",behavior:i}={})=>{e=Math.max(0,Math.min(e,this.options.count-1)),this.cancelScrollToIndex(),i==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size.");let n=this.getOffsetForIndex(e,r);if(!n)return;let[s,a]=n;this._scrollToOffset(s,{adjustments:void 0,behavior:i}),i!=="smooth"&&this.isDynamicMode()&&this.targetWindow&&(this.scrollToIndexTimeoutId=this.targetWindow.setTimeout(()=>{if(this.scrollToIndexTimeoutId=null,this.elementsCache.has(this.options.getItemKey(e))){let[m]=Zr(this.getOffsetForIndex(e,a));xs(m,this.getScrollOffset())||this.scrollToIndex(e,{align:a,behavior:i})}else this.scrollToIndex(e,{align:a,behavior:i})}))},this.scrollBy=(e,{behavior:r}={})=>{this.cancelScrollToIndex(),r==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+e,{adjustments:void 0,behavior:r})},this.getTotalSize=()=>{var n;var e;let r=this.getMeasurements(),i;return r.length===0?i=this.options.paddingStart:i=this.options.lanes===1?(n=(e=r[r.length-1])==null?void 0:e.end)!=null?n:0:Math.max(...r.slice(-this.options.lanes).map(s=>s.end)),Math.max(i-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(e,{adjustments:r,behavior:i})=>{this.options.scrollToFn(e,{behavior:i,adjustments:r},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(t)}},Is=(o,t,e,r)=>{for(;o<=t;){let i=(o+t)/2|0,n=e(i);if(n<r)o=i+1;else if(n>r)t=i-1;else return i}return o>0?o-1:0};function El({measurements:o,outerSize:t,scrollOffset:e}){let r=o.length-1,n=Is(0,r,a=>o[a].start,e),s=n;for(;s<r&&o[s].end<e+t;)s++;return{startIndex:n,endIndex:s}}var ei=class{constructor(t,e){this.cleanup=()=>{},(this.host=t).addController(this);let r={...e,onChange:(i,n)=>{var s;this.host.updateComplete.then(()=>this.host.requestUpdate()),(s=e.onChange)==null||s.call(e,i,n)}};this.virtualizer=new jr(r)}getVirtualizer(){return this.virtualizer}async hostConnected(){this.cleanup=this.virtualizer._didMount()}hostUpdated(){this.virtualizer._willUpdate()}hostDisconnected(){this.cleanup()}},Kr=class extends ei{constructor(t,e){super(t,{observeElementRect:As,observeElementOffset:Ss,scrollToFn:_s,...e})}};var{I:Yy}=ki;var ws=o=>o.strings===void 0;var nr=(o,t)=>{var r;let e=o._$AN;if(e===void 0)return!1;for(let i of e)(r=i._$AO)==null||r.call(i,t,!1),nr(i,t);return!0},Qr=o=>{let t,e;do{if((t=o._$AM)===void 0)break;e=t._$AN,e.delete(o),o=t}while((e==null?void 0:e.size)===0)},Cs=o=>{for(let t;t=o._$AM;o=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(o))break;e.add(o),Sl(t)}};function Tl(o){this._$AN!==void 0?(Qr(this),this._$AM=o,Cs(this)):this._$AM=o}function Al(o,t=!1,e=0){let r=this._$AH,i=this._$AN;if(i!==void 0&&i.size!==0)if(t)if(Array.isArray(r))for(let n=e;n<r.length;n++)nr(r[n],!1),Qr(r[n]);else r!=null&&(nr(r,!1),Qr(r));else nr(this,o)}var Sl=o=>{var t,e;o.type==wr.CHILD&&((t=o._$AP)!=null||(o._$AP=Al),(e=o._$AQ)!=null||(o._$AQ=Tl))},Jr=class extends Tt{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,r){super._$AT(t,e,r),Cs(this),this.isConnected=t._$AU}_$AO(t,e=!0){var r,i;t!==this.isConnected&&(this.isConnected=t,t?(r=this.reconnected)==null||r.call(this):(i=this.disconnected)==null||i.call(this)),e&&(nr(this,t),Qr(this))}setValue(t){if(ws(this.t))this.t._$AI(t,this);else{let e=[...this.t._$AH];e[this.i]=t,this.t._$AI(e,this,0)}}disconnected(){}reconnected(){}};var Rs=()=>new ri,ri=class{},ti=new WeakMap,ks=Bt(class extends Jr{render(o){return x}update(o,[t]){var r;let e=t!==this.Y;return e&&this.Y!==void 0&&this.rt(void 0),(e||this.lt!==this.ct)&&(this.Y=t,this.ht=(r=o.options)==null?void 0:r.host,this.rt(this.ct=o.element)),x}rt(o){var t;if(this.isConnected||(o=void 0),typeof this.Y=="function"){let e=(t=this.ht)!=null?t:globalThis,r=ti.get(e);r===void 0&&(r=new WeakMap,ti.set(e,r)),r.get(this.Y)!==void 0&&this.Y.call(this.ht,void 0),r.set(this.Y,o),o!==void 0&&this.Y.call(this.ht,o)}else this.Y.value=o}get lt(){var o,t,e;return typeof this.Y=="function"?(t=ti.get((o=this.ht)!=null?o:globalThis))==null?void 0:t.get(this.Y):(e=this.Y)==null?void 0:e.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}});var _l=[g`
|
2310
|
+
color: hsl(${Math.max(0,Math.min(120-120*_,120))}deg 100% 31%);`,e==null?void 0:e.key)}return(m=e==null?void 0:e.onChange)==null||m.call(e,i),i}}function Zr(o,t){if(o===void 0)throw new Error(`Unexpected undefined${t?`: ${t}`:""}`);return o}var xs=(o,t)=>Math.abs(o-t)<1,Es=(o,t,e)=>{let r;return function(...i){o.clearTimeout(r),r=o.setTimeout(()=>t.apply(this,i),e)}};var vl=o=>o,bl=o=>{let t=Math.max(o.startIndex-o.overscan,0),e=Math.min(o.endIndex+o.overscan,o.count-1),r=[];for(let i=t;i<=e;i++)r.push(i);return r},As=(o,t)=>{let e=o.scrollElement;if(!e)return;let r=o.targetWindow;if(!r)return;let i=s=>{let{width:a,height:l}=s;t({width:Math.round(a),height:Math.round(l)})};if(i(e.getBoundingClientRect()),!r.ResizeObserver)return()=>{};let n=new r.ResizeObserver(s=>{let a=s[0];if(a!=null&&a.borderBoxSize){let l=a.borderBoxSize[0];if(l){i({width:l.inlineSize,height:l.blockSize});return}}i(e.getBoundingClientRect())});return n.observe(e,{box:"border-box"}),()=>{n.unobserve(e)}},Ts={passive:!0};var yl=typeof window>"u"?!0:"onscrollend"in window,Ss=(o,t)=>{let e=o.scrollElement;if(!e)return;let r=o.targetWindow;if(!r)return;let i=0,n=o.options.useScrollendEvent&&yl?()=>{}:Es(r,()=>{t(i,!1)},o.options.isScrollingResetDelay),s=m=>()=>{let{horizontal:h,isRtl:p}=o.options;i=h?e.scrollLeft*(p&&-1||1):e.scrollTop,n(),t(i,m)},a=s(!0),l=s(!1);return l(),e.addEventListener("scroll",a,Ts),e.addEventListener("scrollend",l,Ts),()=>{e.removeEventListener("scroll",a),e.removeEventListener("scrollend",l)}};var xl=(o,t,e)=>{if(t!=null&&t.borderBoxSize){let r=t.borderBoxSize[0];if(r)return Math.round(r[e.options.horizontal?"inlineSize":"blockSize"])}return Math.round(o.getBoundingClientRect()[e.options.horizontal?"width":"height"])};var _s=(o,{adjustments:t=0,behavior:e},r)=>{var i,n;let s=o+t;(n=(i=r.scrollElement)==null?void 0:i.scrollTo)==null||n.call(i,{[r.options.horizontal?"left":"top"]:s,behavior:e})},jr=class{constructor(t){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.scrollToIndexTimeoutId=null,this.measurementsCache=[],this.itemSizeCache=new Map,this.pendingMeasuredCacheIndexes=[],this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let e=null,r=()=>e||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:e=new this.targetWindow.ResizeObserver(i=>{i.forEach(n=>{this._measureElement(n.target,n)})}));return{disconnect:()=>{var i;(i=r())==null||i.disconnect(),e=null},observe:i=>{var n;return(n=r())==null?void 0:n.observe(i,{box:"border-box"})},unobserve:i=>{var n;return(n=r())==null?void 0:n.unobserve(i)}}})(),this.range=null,this.setOptions=e=>{Object.entries(e).forEach(([r,i])=>{typeof i>"u"&&delete e[r]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:vl,rangeExtractor:bl,onChange:()=>{},measureElement:xl,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!0,...e}},this.notify=e=>{var r,i;(i=(r=this.options).onChange)==null||i.call(r,this,e)},this.maybeNotify=mt(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),e=>{this.notify(e)},{key:!1,debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(e=>e()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var i;var e;let r=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==r){if(this.cleanup(),!r){this.maybeNotify();return}this.scrollElement=r,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=(i=(e=this.scrollElement)==null?void 0:e.window)!=null?i:null,this.elementsCache.forEach(n=>{this.observer.observe(n)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,n=>{this.scrollRect=n,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(n,s)=>{this.scrollAdjustments=0,this.scrollDirection=s?this.getScrollOffset()<n?"forward":"backward":null,this.scrollOffset=n,this.isScrolling=s,this.maybeNotify()}))}},this.getSize=()=>{var e;return this.options.enabled?(this.scrollRect=(e=this.scrollRect)!=null?e:this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0)},this.getScrollOffset=()=>{var e;return this.options.enabled?(this.scrollOffset=(e=this.scrollOffset)!=null?e:typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset,this.scrollOffset):(this.scrollOffset=null,0)},this.getFurthestMeasurement=(e,r)=>{let i=new Map,n=new Map;for(let s=r-1;s>=0;s--){let a=e[s];if(i.has(a.lane))continue;let l=n.get(a.lane);if(l==null||a.end>l.end?n.set(a.lane,a):a.end<l.end&&i.set(a.lane,!0),i.size===this.options.lanes)break}return n.size===this.options.lanes?Array.from(n.values()).sort((s,a)=>s.end===a.end?s.index-a.index:s.end-a.end)[0]:void 0},this.getMeasurementOptions=mt(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(e,r,i,n,s)=>(this.pendingMeasuredCacheIndexes=[],{count:e,paddingStart:r,scrollMargin:i,getItemKey:n,enabled:s}),{key:!1}),this.getMeasurements=mt(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:e,paddingStart:r,scrollMargin:i,getItemKey:n,enabled:s},a)=>{if(!s)return this.measurementsCache=[],this.itemSizeCache.clear(),[];this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(h=>{this.itemSizeCache.set(h.key,h.size)}));let l=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];let m=this.measurementsCache.slice(0,l);for(let h=l;h<e;h++){let p=n(h),v=this.options.lanes===1?m[h-1]:this.getFurthestMeasurement(m,h),f=v?v.end+this.options.gap:r+i,b=a.get(p),T=typeof b=="number"?b:this.options.estimateSize(h),_=f+T,S=v?v.lane:h%this.options.lanes;m[h]={index:h,start:f,size:T,end:_,key:p,lane:S}}return this.measurementsCache=m,m},{key:!1,debug:()=>this.options.debug}),this.calculateRange=mt(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset()],(e,r,i)=>this.range=e.length>0&&r>0?El({measurements:e,outerSize:r,scrollOffset:i}):null,{key:!1,debug:()=>this.options.debug}),this.getIndexes=mt(()=>{let e=null,r=null,i=this.calculateRange();return i&&(e=i.startIndex,r=i.endIndex),[this.options.rangeExtractor,this.options.overscan,this.options.count,e,r]},(e,r,i,n,s)=>n===null||s===null?[]:e({startIndex:n,endIndex:s,overscan:r,count:i}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=e=>{let r=this.options.indexAttribute,i=e.getAttribute(r);return i?parseInt(i,10):(console.warn(`Missing attribute name '${r}={index}' on measured element.`),-1)},this._measureElement=(e,r)=>{let i=this.indexFromElement(e),n=this.measurementsCache[i];if(!n)return;let s=n.key,a=this.elementsCache.get(s);a!==e&&(a&&this.observer.unobserve(a),this.observer.observe(e),this.elementsCache.set(s,e)),e.isConnected&&this.resizeItem(i,this.options.measureElement(e,r,this))},this.resizeItem=(e,r)=>{var a;let i=this.measurementsCache[e];if(!i)return;let n=(a=this.itemSizeCache.get(i.key))!=null?a:i.size,s=r-n;s!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(i,s,this):i.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=s,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(i.index),this.itemSizeCache=new Map(this.itemSizeCache.set(i.key,r)),this.notify(!1))},this.measureElement=e=>{if(!e){this.elementsCache.forEach((r,i)=>{r.isConnected||(this.observer.unobserve(r),this.elementsCache.delete(i))});return}this._measureElement(e,void 0)},this.getVirtualItems=mt(()=>[this.getIndexes(),this.getMeasurements()],(e,r)=>{let i=[];for(let n=0,s=e.length;n<s;n++){let a=e[n],l=r[a];i.push(l)}return i},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=e=>{let r=this.getMeasurements();if(r.length!==0)return Zr(r[Is(0,r.length-1,i=>Zr(r[i]).start,e)])},this.getOffsetForAlignment=(e,r)=>{let i=this.getSize(),n=this.getScrollOffset();r==="auto"&&e>=n+i&&(r="end"),r==="end"&&(e-=i);let s=this.options.horizontal?"scrollWidth":"scrollHeight",l=(this.scrollElement?"document"in this.scrollElement?this.scrollElement.document.documentElement[s]:this.scrollElement[s]:0)-i;return Math.max(Math.min(l,e),0)},this.getOffsetForIndex=(e,r="auto")=>{e=Math.max(0,Math.min(e,this.options.count-1));let i=this.measurementsCache[e];if(!i)return;let n=this.getSize(),s=this.getScrollOffset();if(r==="auto")if(i.end>=s+n-this.options.scrollPaddingEnd)r="end";else if(i.start<=s+this.options.scrollPaddingStart)r="start";else return[s,r];let a=i.start-this.options.scrollPaddingStart+(i.size-n)/2;switch(r){case"center":return[this.getOffsetForAlignment(a,r),r];case"end":return[this.getOffsetForAlignment(i.end+this.options.scrollPaddingEnd,r),r];default:return[this.getOffsetForAlignment(i.start-this.options.scrollPaddingStart,r),r]}},this.isDynamicMode=()=>this.elementsCache.size>0,this.cancelScrollToIndex=()=>{this.scrollToIndexTimeoutId!==null&&this.targetWindow&&(this.targetWindow.clearTimeout(this.scrollToIndexTimeoutId),this.scrollToIndexTimeoutId=null)},this.scrollToOffset=(e,{align:r="start",behavior:i}={})=>{this.cancelScrollToIndex(),i==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(e,r),{adjustments:void 0,behavior:i})},this.scrollToIndex=(e,{align:r="auto",behavior:i}={})=>{e=Math.max(0,Math.min(e,this.options.count-1)),this.cancelScrollToIndex(),i==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size.");let n=this.getOffsetForIndex(e,r);if(!n)return;let[s,a]=n;this._scrollToOffset(s,{adjustments:void 0,behavior:i}),i!=="smooth"&&this.isDynamicMode()&&this.targetWindow&&(this.scrollToIndexTimeoutId=this.targetWindow.setTimeout(()=>{if(this.scrollToIndexTimeoutId=null,this.elementsCache.has(this.options.getItemKey(e))){let[m]=Zr(this.getOffsetForIndex(e,a));xs(m,this.getScrollOffset())||this.scrollToIndex(e,{align:a,behavior:i})}else this.scrollToIndex(e,{align:a,behavior:i})}))},this.scrollBy=(e,{behavior:r}={})=>{this.cancelScrollToIndex(),r==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+e,{adjustments:void 0,behavior:r})},this.getTotalSize=()=>{var n;var e;let r=this.getMeasurements(),i;return r.length===0?i=this.options.paddingStart:i=this.options.lanes===1?(n=(e=r[r.length-1])==null?void 0:e.end)!=null?n:0:Math.max(...r.slice(-this.options.lanes).map(s=>s.end)),Math.max(i-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(e,{adjustments:r,behavior:i})=>{this.options.scrollToFn(e,{behavior:i,adjustments:r},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(t)}},Is=(o,t,e,r)=>{for(;o<=t;){let i=(o+t)/2|0,n=e(i);if(n<r)o=i+1;else if(n>r)t=i-1;else return i}return o>0?o-1:0};function El({measurements:o,outerSize:t,scrollOffset:e}){let r=o.length-1,n=Is(0,r,a=>o[a].start,e),s=n;for(;s<r&&o[s].end<e+t;)s++;return{startIndex:n,endIndex:s}}var ei=class{constructor(t,e){this.cleanup=()=>{},(this.host=t).addController(this);let r={...e,onChange:(i,n)=>{var s;this.host.updateComplete.then(()=>this.host.requestUpdate()),(s=e.onChange)==null||s.call(e,i,n)}};this.virtualizer=new jr(r)}getVirtualizer(){return this.virtualizer}async hostConnected(){this.cleanup=this.virtualizer._didMount()}hostUpdated(){this.virtualizer._willUpdate()}hostDisconnected(){this.cleanup()}},Kr=class extends ei{constructor(t,e){super(t,{observeElementRect:As,observeElementOffset:Ss,scrollToFn:_s,...e})}};var{I:Yy}=Ri;var ws=o=>o.strings===void 0;var nr=(o,t)=>{var r;let e=o._$AN;if(e===void 0)return!1;for(let i of e)(r=i._$AO)==null||r.call(i,t,!1),nr(i,t);return!0},Qr=o=>{let t,e;do{if((t=o._$AM)===void 0)break;e=t._$AN,e.delete(o),o=t}while((e==null?void 0:e.size)===0)},Cs=o=>{for(let t;t=o._$AM;o=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(o))break;e.add(o),Sl(t)}};function Tl(o){this._$AN!==void 0?(Qr(this),this._$AM=o,Cs(this)):this._$AM=o}function Al(o,t=!1,e=0){let r=this._$AH,i=this._$AN;if(i!==void 0&&i.size!==0)if(t)if(Array.isArray(r))for(let n=e;n<r.length;n++)nr(r[n],!1),Qr(r[n]);else r!=null&&(nr(r,!1),Qr(r));else nr(this,o)}var Sl=o=>{var t,e;o.type==wr.CHILD&&((t=o._$AP)!=null||(o._$AP=Al),(e=o._$AQ)!=null||(o._$AQ=Tl))},Jr=class extends Tt{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,r){super._$AT(t,e,r),Cs(this),this.isConnected=t._$AU}_$AO(t,e=!0){var r,i;t!==this.isConnected&&(this.isConnected=t,t?(r=this.reconnected)==null||r.call(this):(i=this.disconnected)==null||i.call(this)),e&&(nr(this,t),Qr(this))}setValue(t){if(ws(this.t))this.t._$AI(t,this);else{let e=[...this.t._$AH];e[this.i]=t,this.t._$AI(e,this,0)}}disconnected(){}reconnected(){}};var ks=()=>new ri,ri=class{},ti=new WeakMap,Rs=Bt(class extends Jr{render(o){return x}update(o,[t]){var r;let e=t!==this.Y;return e&&this.Y!==void 0&&this.rt(void 0),(e||this.lt!==this.ct)&&(this.Y=t,this.ht=(r=o.options)==null?void 0:r.host,this.rt(this.ct=o.element)),x}rt(o){var t;if(this.isConnected||(o=void 0),typeof this.Y=="function"){let e=(t=this.ht)!=null?t:globalThis,r=ti.get(e);r===void 0&&(r=new WeakMap,ti.set(e,r)),r.get(this.Y)!==void 0&&this.Y.call(this.ht,void 0),r.set(this.Y,o),o!==void 0&&this.Y.call(this.ht,o)}else this.Y.value=o}get lt(){var o,t,e;return typeof this.Y=="function"?(t=ti.get((o=this.ht)!=null?o:globalThis))==null?void 0:t.get(this.Y):(e=this.Y)==null?void 0:e.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}});var _l=[g`
|
2292
2311
|
:host::part(scroll) {
|
2293
2312
|
height: 100%;
|
2294
2313
|
width: 100%;
|
@@ -2298,19 +2317,19 @@
|
|
2298
2317
|
position: relative;
|
2299
2318
|
width: 100%;
|
2300
2319
|
}
|
2301
|
-
`],Ls=_l;var Ns=y.constructTagName("virtualizedlist"),lx=y.constructTagName("virtualizedwrapper"),Os={VIRTUALIZER_PROPS:{count:0,estimateSize:()=>0}};var ht=class extends E{constructor(){super();this.
|
2320
|
+
`],Ls=_l;var Ns=y.constructTagName("virtualizedlist"),lx=y.constructTagName("virtualizedwrapper"),Os={VIRTUALIZER_PROPS:{count:0,estimateSize:()=>0}};var ht=class extends E{constructor(){super();this.virtualizerProps=Os.VIRTUALIZER_PROPS;this.scrollElementRef=ks();this.virtualItems=[];this.virtualizerController=null,this.virtualizer=null,this.setlistdata=null,this.onscroll=null}update(e){super.update(e),e.get("virtualizerProps")&&this.setVirtualizerOptions()}firstUpdated(e){super.firstUpdated(e),this.setVirtualizerOptions()}setVirtualizerOptions(){var e;(e=this.virtualizer)==null||e.setOptions({...this.virtualizer.options,...this.virtualizerProps}),this.requestUpdate()}connectedCallback(){var e;this.virtualizerController=new Kr(this,{count:this.virtualizerProps.count,estimateSize:(e=this.virtualizerProps)==null?void 0:e.estimateSize,getScrollElement:()=>this.scrollElementRef.value||null,...this.virtualizerProps}),super.connectedCallback()}getVirtualizedListWrapper(e){var a,l;this.virtualizer=e.getVirtualizer();let{getTotalSize:r,getVirtualItems:i,measureElement:n}=this.virtualizer,s=i();if(s!==this.virtualItems){this.virtualItems=s;let m=i(),h={position:"absolute",top:0,left:0,width:"100%",transform:`translateY(${(l=(a=m[0])==null?void 0:a.start)!=null?l:0}px)`};this.setlistdata&&this.setlistdata({virtualItems:m,measureElement:n,listStyle:h})}return u`<div
|
2302
2321
|
part="container"
|
2303
|
-
style="height: ${
|
2322
|
+
style="height: ${r()}px;"
|
2304
2323
|
>
|
2305
2324
|
<slot></slot>
|
2306
2325
|
</div>`}render(){return u`<div
|
2307
|
-
${
|
2326
|
+
${Rs(this.scrollElementRef)}
|
2308
2327
|
part="scroll"
|
2309
2328
|
@scroll=${this.onscroll&&this.onscroll}
|
2310
2329
|
>
|
2311
2330
|
${this.virtualizerController?this.getVirtualizedListWrapper(this.virtualizerController):u``}
|
2312
2331
|
</div>
|
2313
|
-
`}};ht.styles=[...E.styles,...Ls],c([d({type:Function,attribute:"onscroll"})],ht.prototype,"onscroll",2),c([d({type:Object,attribute:"virtualizerprops"})],ht.prototype,"
|
2332
|
+
`}};ht.styles=[...E.styles,...Ls],c([d({type:Function,attribute:"onscroll"})],ht.prototype,"onscroll",2),c([d({type:Object,attribute:"virtualizerprops"})],ht.prototype,"virtualizerProps",2),c([d({type:Function,attribute:"setlistdata"})],ht.prototype,"setlistdata",2);var oi=ht;oi.register(Ns);var Il=oi;var wl=[C,g`
|
2314
2333
|
|
2315
2334
|
:host {
|
2316
2335
|
--mdc-tab-content-gap: 0.5rem;
|
@@ -2553,7 +2572,7 @@
|
|
2553
2572
|
color: var(--mdc-tab-pill-active-color-disabled);
|
2554
2573
|
}
|
2555
2574
|
|
2556
|
-
`,...$()],zs=wl;var Ms=y.constructTagName("tab"),ii={GLASS:"glass",LINE:"line",PILL:"pill"},ni={VARIANT:ii.PILL};var
|
2575
|
+
`,...$()],zs=wl;var Ms=y.constructTagName("tab"),ii={GLASS:"glass",LINE:"line",PILL:"pill"},ni={VARIANT:ii.PILL};var Rt=class extends de(De){constructor(){super();this.variant=ni.VARIANT;this.role="tab",this.softDisabled=void 0,this.size=void 0,this.type=void 0}modifyIconName(e){this.iconName&&(e?(this.prevIconName=this.iconName,this.iconName=`${Yt(this.iconName)}-filled`):this.prevIconName&&(this.iconName=this.prevIconName))}setVariant(e){this.setAttribute("variant",Object.values(ii).includes(e)?e:ni.VARIANT)}setActive(e,r){e.setAttribute("aria-selected",r?"true":"false"),this.modifyIconName(r)}executeAction(){this.active=!this.active}update(e){super.update(e),e.has("variant")&&this.setVariant(this.variant)}render(){return u`
|
2557
2576
|
<div part="container">
|
2558
2577
|
${this.iconName?u` <mdc-icon name="${this.iconName}" size="1" length-unit="rem" part="icon"></mdc-icon>`:x}
|
2559
2578
|
${this.text?u` <mdc-text
|
@@ -2567,7 +2586,7 @@
|
|
2567
2586
|
<slot name="chip"></slot>
|
2568
2587
|
</div>
|
2569
2588
|
<div part="indicator"></div>
|
2570
|
-
`}};
|
2589
|
+
`}};Rt.styles=[...De.styles,...zs],c([d({type:String,reflect:!0})],Rt.prototype,"text",2),c([d({type:String,reflect:!0})],Rt.prototype,"variant",2);var si=Rt;si.register(Ms);var Cl=si;var Ds=y.constructTagName("formfieldgroup"),ai={RADIOGROUP:"radiogroup",GROUP:"group"};var kl=g`
|
2571
2590
|
|
2572
2591
|
:host::part(container) {
|
2573
2592
|
display: flex;
|
@@ -2584,7 +2603,7 @@
|
|
2584
2603
|
:host::part(label-text){
|
2585
2604
|
font-weight: bold;
|
2586
2605
|
}
|
2587
|
-
`,$s=[
|
2606
|
+
`,$s=[kl];var eo=class extends W(ee){constructor(){super();this.isRadio=!1;this.shouldRenderLabel=!1,this.id="",this.helpTextType=void 0,this.disabled=void 0}render(){var e;return u`
|
2588
2607
|
<div
|
2589
2608
|
part="container"
|
2590
2609
|
role="${this.isRadio?ai.RADIOGROUP:ai.GROUP}"
|
@@ -2598,7 +2617,7 @@
|
|
2598
2617
|
</div>
|
2599
2618
|
<slot></slot>
|
2600
2619
|
</div>
|
2601
|
-
`}};eo.styles=[...ee.styles,...$s];var li=eo;li.register(Ds);var to=li;var
|
2620
|
+
`}};eo.styles=[...ee.styles,...$s];var li=eo;li.register(Ds);var to=li;var Rl=[C,g`
|
2602
2621
|
:host {
|
2603
2622
|
--mdc-spinner-default-color: var(--mds-color-theme-control-active-normal);
|
2604
2623
|
--mdc-spinner-inverted-color: var(--mds-color-theme-inverted-control-active-normal);
|
@@ -2660,7 +2679,7 @@
|
|
2660
2679
|
stroke-dashoffset: -292;
|
2661
2680
|
}
|
2662
2681
|
}
|
2663
|
-
`],Ps=
|
2682
|
+
`],Ps=Rl;var Us=y.constructTagName("spinner"),Ll={LARGE:"large",MIDSIZE:"midsize",SMALL:"small"},Nl={STANDALONE:"standalone",BUTTON:"button"},ro={VARIANT:Nl.STANDALONE,SIZE:Ll.MIDSIZE,INVERTED:!1};var Fe=class extends E{constructor(){super(...arguments);this.inverted=ro.INVERTED;this.size=ro.SIZE;this.ariaLabel=null;this.variant=ro.VARIANT}updated(e){super.updated(e),e.has("ariaLabel")&&(this.role=this.ariaLabel?"img":null,this.ariaHidden=this.ariaLabel?"false":"true")}render(){return u`
|
2664
2683
|
<svg part="container" viewBox="0 0 100 100">
|
2665
2684
|
<circle part="circle" cx="50" cy="50" r="46"></circle>
|
2666
2685
|
</svg>
|