@momentum-design/components 0.62.2 → 0.62.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/index.js +804 -536
- package/dist/browser/index.js.map +4 -4
- package/dist/components/card/card.component.d.ts +100 -0
- package/dist/components/card/card.component.js +197 -0
- package/dist/components/card/card.constants.d.ts +22 -0
- package/dist/components/card/card.constants.js +26 -0
- package/dist/components/card/card.styles.d.ts +2 -0
- package/dist/components/card/card.styles.js +79 -0
- package/dist/components/card/card.types.d.ts +5 -0
- package/dist/components/card/card.types.js +1 -0
- package/dist/components/card/index.d.ts +9 -0
- package/dist/components/card/index.js +6 -0
- package/dist/components/cardbutton/cardbutton.component.d.ts +37 -0
- package/dist/components/cardbutton/cardbutton.component.js +61 -0
- package/dist/components/cardbutton/cardbutton.constants.d.ts +2 -0
- package/dist/components/cardbutton/cardbutton.constants.js +3 -0
- package/dist/components/cardbutton/cardbutton.styles.d.ts +2 -0
- package/dist/components/cardbutton/cardbutton.styles.js +26 -0
- package/dist/components/cardbutton/cardbutton.types.d.ts +7 -0
- package/dist/components/cardbutton/cardbutton.types.js +1 -0
- package/dist/components/cardbutton/index.d.ts +9 -0
- package/dist/components/cardbutton/index.js +6 -0
- package/dist/components/cardcheckbox/cardcheckbox.component.d.ts +76 -0
- package/dist/components/cardcheckbox/cardcheckbox.component.js +159 -0
- package/dist/components/cardcheckbox/cardcheckbox.constants.d.ts +15 -0
- package/dist/components/cardcheckbox/cardcheckbox.constants.js +16 -0
- package/dist/components/cardcheckbox/cardcheckbox.styles.d.ts +2 -0
- package/dist/components/cardcheckbox/cardcheckbox.styles.js +57 -0
- package/dist/components/cardcheckbox/cardcheckbox.types.d.ts +11 -0
- package/dist/components/cardcheckbox/cardcheckbox.types.js +1 -0
- package/dist/components/cardcheckbox/index.d.ts +10 -0
- package/dist/components/cardcheckbox/index.js +7 -0
- package/dist/components/cardradio/cardradio.component.d.ts +76 -0
- package/dist/components/cardradio/cardradio.component.js +155 -0
- package/dist/components/cardradio/cardradio.constants.d.ts +2 -0
- package/dist/components/cardradio/cardradio.constants.js +3 -0
- package/dist/components/cardradio/cardradio.styles.d.ts +2 -0
- package/dist/components/cardradio/cardradio.styles.js +53 -0
- package/dist/components/cardradio/cardradio.types.d.ts +8 -0
- package/dist/components/cardradio/cardradio.types.js +1 -0
- package/dist/components/cardradio/index.d.ts +10 -0
- package/dist/components/cardradio/index.js +7 -0
- package/dist/components/listitem/index.d.ts +1 -1
- package/dist/components/listitem/index.js +1 -1
- package/dist/components/listitem/listitem.component.d.ts +4 -4
- package/dist/components/listitem/listitem.component.js +2 -2
- package/dist/components/menuitem/index.d.ts +8 -0
- package/dist/components/menuitem/index.js +5 -0
- package/dist/components/menuitem/menuitem.component.d.ts +25 -0
- package/dist/components/menuitem/menuitem.component.js +29 -0
- package/dist/components/menuitem/menuitem.constants.d.ts +2 -0
- package/dist/components/menuitem/menuitem.constants.js +3 -0
- package/dist/components/menuitem/menuitem.types.d.ts +6 -0
- package/dist/components/menuitem/menuitem.types.js +1 -0
- package/dist/components/option/option.component.js +0 -4
- package/dist/components/radiogroup/radiogroup.component.js +2 -1
- package/dist/custom-elements.json +6221 -3340
- package/dist/index.d.ts +12 -7
- package/dist/index.js +12 -7
- package/dist/react/card/index.d.ts +47 -0
- package/dist/react/card/index.js +56 -0
- package/dist/react/cardbutton/index.d.ts +32 -0
- package/dist/react/cardbutton/index.js +40 -0
- package/dist/react/cardcheckbox/index.d.ts +40 -0
- package/dist/react/cardcheckbox/index.js +48 -0
- package/dist/react/cardradio/index.d.ts +40 -0
- package/dist/react/cardradio/index.js +48 -0
- package/dist/react/index.d.ts +7 -2
- package/dist/react/index.js +7 -2
- package/dist/react/menuitem/index.d.ts +27 -0
- package/dist/react/menuitem/index.js +35 -0
- package/dist/utils/mixins/CardComponentMixin.d.ts +20 -0
- package/dist/utils/mixins/CardComponentMixin.js +130 -0
- package/package.json +1 -1
package/dist/browser/index.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
"use strict";(()=>{var
|
2
|
-
\f\r]`,
|
3
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),
|
1
|
+
"use strict";(()=>{var Gc=Object.defineProperty;var Yc=Object.getOwnPropertyDescriptor;var n=(i,t,e,r)=>{for(var o=r>1?void 0:r?Yc(t,e):t,a=i.length-1,s;a>=0;a--)(s=i[a])&&(o=(r?s(t,e,o):s(o))||o);return r&&o&&Gc(t,e,o),o};var uo=globalThis,fo=uo.ShadowRoot&&(uo.ShadyCSS===void 0||uo.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Ni=Symbol(),ms=new WeakMap,Nr=class{constructor(t,e,r){if(this._$cssResult$=!0,r!==Ni)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(fo&&t===void 0){let r=e!==void 0&&e.length===1;r&&(t=ms.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),r&&ms.set(e,t))}return t}toString(){return this.cssText}},ps=i=>new Nr(typeof i=="string"?i:i+"",void 0,Ni),u=(i,...t)=>{let e=i.length===1?i[0]:t.reduce((r,o,a)=>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.")})(o)+i[a+1],i[0]);return new Nr(e,i,Ni)},_i=(i,t)=>{if(fo)i.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(let e of t){let r=document.createElement("style"),o=uo.litNonce;o!==void 0&&r.setAttribute("nonce",o),r.textContent=e.cssText,i.appendChild(r)}},bo=fo?i=>i:i=>i instanceof CSSStyleSheet?(t=>{let e="";for(let r of t.cssRules)e+=r.cssText;return ps(e)})(i):i;var{is:Wc,defineProperty:qc,getOwnPropertyDescriptor:Kc,getOwnPropertyNames:Zc,getOwnPropertySymbols:Xc,getPrototypeOf:jc}=Object,rt=globalThis,hs=rt.trustedTypes,Qc=hs?hs.emptyScript:"",Li=rt.reactiveElementPolyfillSupport,_r=(i,t)=>i,Lr={toAttribute(i,t){switch(t){case Boolean:i=i?Qc:null;break;case Object:case Array:i=i==null?i:JSON.stringify(i)}return i},fromAttribute(i,t){let e=i;switch(t){case Boolean:e=i!==null;break;case Number:e=i===null?null:Number(i);break;case Object:case Array:try{e=JSON.parse(i)}catch{e=null}}return e}},go=(i,t)=>!Wc(i,t),us={attribute:!0,type:String,converter:Lr,reflect:!1,hasChanged:go},fs,bs;(fs=Symbol.metadata)!=null||(Symbol.metadata=Symbol("metadata")),(bs=rt.litPropertyMetadata)!=null||(rt.litPropertyMetadata=new WeakMap);var $e=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=us){if(e.state&&(e.attribute=!1),this._$Ei(),this.elementProperties.set(t,e),!e.noAccessor){let r=Symbol(),o=this.getPropertyDescriptor(t,r,e);o!==void 0&&qc(this.prototype,t,o)}}static getPropertyDescriptor(t,e,r){var s;let{get:o,set:a}=(s=Kc(this.prototype,t))!=null?s:{get(){return this[e]},set(l){this[e]=l}};return{get(){return o==null?void 0:o.call(this)},set(l){let d=o==null?void 0:o.call(this);a.call(this,l),this.requestUpdate(t,d,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){var e;return(e=this.elementProperties.get(t))!=null?e:us}static _$Ei(){if(this.hasOwnProperty(_r("elementProperties")))return;let t=jc(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(_r("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(_r("properties"))){let e=this.properties,r=[...Zc(e),...Xc(e)];for(let o of r)this.createProperty(o,e[o])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[r,o]of e)this.elementProperties.set(r,o)}this._$Eh=new Map;for(let[e,r]of this.elementProperties){let o=this._$Eu(e,r);o!==void 0&&this._$Eh.set(o,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 o of r)e.unshift(bo(o))}else t!==void 0&&e.push(bo(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 _i(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 o;return(o=r.hostConnected)==null?void 0:o.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 a;let r=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,r);if(o!==void 0&&r.reflect===!0){let s=(((a=r.converter)==null?void 0:a.toAttribute)!==void 0?r.converter:Lr).toAttribute(e,r.type);this._$Em=t,s==null?this.removeAttribute(o):this.setAttribute(o,s),this._$Em=null}}_$AK(t,e){var a;let r=this.constructor,o=r._$Eh.get(t);if(o!==void 0&&this._$Em!==o){let s=r.getPropertyOptions(o),l=typeof s.converter=="function"?{fromAttribute:s.converter}:((a=s.converter)==null?void 0:a.fromAttribute)!==void 0?s.converter:Lr;this._$Em=o,this[o]=l.fromAttribute(e,s.type),this._$Em=null}}requestUpdate(t,e,r){var o;if(t!==void 0){if(r!=null||(r=this.constructor.getPropertyOptions(t)),!((o=r.hasChanged)!=null?o:go)(this[t],e))return;this.P(t,e,r)}this.isUpdatePending===!1&&(this._$ES=this._$ET())}P(t,e,r){var o;this._$AL.has(t)||this._$AL.set(t,e),r.reflect===!0&&this._$Em!==t&&((o=this._$Ej)!=null?o: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,o;if(!this.isUpdatePending)return;if(!this.hasUpdated){if((r=this.renderRoot)!=null||(this.renderRoot=this.createRenderRoot()),this._$Ep){for(let[s,l]of this._$Ep)this[s]=l;this._$Ep=void 0}let a=this.constructor.elementProperties;if(a.size>0)for(let[s,l]of a)l.wrapped!==!0||this._$AL.has(s)||this[s]===void 0||this.P(s,this[s],l)}let t=!1,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),(o=this._$EO)==null||o.forEach(a=>{var s;return(s=a.hostUpdate)==null?void 0:s.call(a)}),this.update(e)):this._$EU()}catch(a){throw t=!1,this._$EU(),a}t&&this._$AE(e)}willUpdate(t){}_$AE(t){var e;(e=this._$EO)==null||e.forEach(r=>{var o;return(o=r.hostUpdated)==null?void 0:o.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){}},gs;$e.elementStyles=[],$e.shadowRootOptions={mode:"open"},$e[_r("elementProperties")]=new Map,$e[_r("finalized")]=new Map,Li==null||Li({ReactiveElement:$e}),((gs=rt.reactiveElementVersions)!=null?gs:rt.reactiveElementVersions=[]).push("2.0.4");var Or=globalThis,vo=Or.trustedTypes,vs=vo?vo.createPolicy("lit-html",{createHTML:i=>i}):void 0,Mi="$lit$",ze=`lit$${Math.random().toFixed(9).slice(2)}$`,Di="?"+ze,Jc=`<${Di}>`,bt=document,Mr=()=>bt.createComment(""),Dr=i=>i===null||typeof i!="object"&&typeof i!="function",$i=Array.isArray,Is=i=>$i(i)||typeof(i==null?void 0:i[Symbol.iterator])=="function",Ri=`[
|
2
|
+
\f\r]`,Rr=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,ys=/-->/g,xs=/>/g,ut=RegExp(`>|${Ri}(?:([^\\s"'>=/]+)(${Ri}*=${Ri}*(?:[^
|
3
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),Es=/'/g,Ts=/"/g,Cs=/^(?:script|style|textarea|title)$/i,zi=i=>(t,...e)=>({_$litType$:i,strings:t,values:e}),m=zi(1),Wp=zi(2),qp=zi(3),Pe=Symbol.for("lit-noChange"),g=Symbol.for("lit-nothing"),As=new WeakMap,ft=bt.createTreeWalker(bt,129);function ks(i,t){if(!$i(i)||!i.hasOwnProperty("raw"))throw Error("invalid template strings array");return vs!==void 0?vs.createHTML(t):t}var ws=(i,t)=>{let e=i.length-1,r=[],o,a=t===2?"<svg>":t===3?"<math>":"",s=Rr;for(let l=0;l<e;l++){let d=i[l],p,h,b=-1,x=0;for(;x<d.length&&(s.lastIndex=x,h=s.exec(d),h!==null);)x=s.lastIndex,s===Rr?h[1]==="!--"?s=ys:h[1]!==void 0?s=xs:h[2]!==void 0?(Cs.test(h[2])&&(o=RegExp("</"+h[2],"g")),s=ut):h[3]!==void 0&&(s=ut):s===ut?h[0]===">"?(s=o!=null?o:Rr,b=-1):h[1]===void 0?b=-2:(b=s.lastIndex-h[2].length,p=h[1],s=h[3]===void 0?ut:h[3]==='"'?Ts:Es):s===Ts||s===Es?s=ut:s===ys||s===xs?s=Rr:(s=ut,o=void 0);let y=s===ut&&i[l+1].startsWith("/>")?" ":"";a+=s===Rr?d+Jc:b>=0?(r.push(p),d.slice(0,b)+Mi+d.slice(b)+ze+y):d+ze+(b===-2?l:y)}return[ks(i,a+(i[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),r]},$r=class i{constructor({strings:t,_$litType$:e},r){let o;this.parts=[];let a=0,s=0,l=t.length-1,d=this.parts,[p,h]=ws(t,e);if(this.el=i.createElement(p,r),ft.currentNode=this.el.content,e===2||e===3){let b=this.el.content.firstChild;b.replaceWith(...b.childNodes)}for(;(o=ft.nextNode())!==null&&d.length<l;){if(o.nodeType===1){if(o.hasAttributes())for(let b of o.getAttributeNames())if(b.endsWith(Mi)){let x=h[s++],y=o.getAttribute(b).split(ze),E=/([.?@])?(.*)/.exec(x);d.push({type:1,index:a,name:E[2],strings:y,ctor:E[1]==="."?xo:E[1]==="?"?Eo:E[1]==="@"?To:vt}),o.removeAttribute(b)}else b.startsWith(ze)&&(d.push({type:6,index:a}),o.removeAttribute(b));if(Cs.test(o.tagName)){let b=o.textContent.split(ze),x=b.length-1;if(x>0){o.textContent=vo?vo.emptyScript:"";for(let y=0;y<x;y++)o.append(b[y],Mr()),ft.nextNode(),d.push({type:2,index:++a});o.append(b[x],Mr())}}}else if(o.nodeType===8)if(o.data===Di)d.push({type:2,index:a});else{let b=-1;for(;(b=o.data.indexOf(ze,b+1))!==-1;)d.push({type:7,index:a}),b+=ze.length-1}a++}}static createElement(t,e){let r=bt.createElement("template");return r.innerHTML=t,r}};function gt(i,t,e=i,r){var s,l,d;if(t===Pe)return t;let o=r!==void 0?(s=e.o)==null?void 0:s[r]:e.l,a=Dr(t)?void 0:t._$litDirective$;return(o==null?void 0:o.constructor)!==a&&((l=o==null?void 0:o._$AO)==null||l.call(o,!1),a===void 0?o=void 0:(o=new a(i),o._$AT(i,e,r)),r!==void 0?((d=e.o)!=null?d:e.o=[])[r]=o:e.l=o),o!==void 0&&(t=gt(i,o._$AS(i,t.values),o,r)),t}var yo=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 p;let{el:{content:e},parts:r}=this._$AD,o=((p=t==null?void 0:t.creationScope)!=null?p:bt).importNode(e,!0);ft.currentNode=o;let a=ft.nextNode(),s=0,l=0,d=r[0];for(;d!==void 0;){if(s===d.index){let h;d.type===2?h=new Zt(a,a.nextSibling,this,t):d.type===1?h=new d.ctor(a,d.name,d.strings,this,t):d.type===6&&(h=new Ao(a,this,t)),this._$AV.push(h),d=r[++l]}s!==(d==null?void 0:d.index)&&(a=ft.nextNode(),s++)}return ft.currentNode=bt,o}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++}},Zt=class i{get _$AU(){var t,e;return(e=(t=this._$AM)==null?void 0:t._$AU)!=null?e:this.v}constructor(t,e,r,o){var a;this.type=2,this._$AH=g,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=r,this.options=o,this.v=(a=o==null?void 0:o.isConnected)!=null?a:!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=gt(this,t,e),Dr(t)?t===g||t==null||t===""?(this._$AH!==g&&this._$AR(),this._$AH=g):t!==this._$AH&&t!==Pe&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Is(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!==g&&Dr(this._$AH)?this._$AA.nextSibling.data=t:this.T(bt.createTextNode(t)),this._$AH=t}$(t){var a;let{values:e,_$litType$:r}=t,o=typeof r=="number"?this._$AC(t):(r.el===void 0&&(r.el=$r.createElement(ks(r.h,r.h[0]),this.options)),r);if(((a=this._$AH)==null?void 0:a._$AD)===o)this._$AH.p(e);else{let s=new yo(o,this),l=s.u(this.options);s.p(e),this.T(l),this._$AH=s}}_$AC(t){let e=As.get(t.strings);return e===void 0&&As.set(t.strings,e=new $r(t)),e}k(t){$i(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,r,o=0;for(let a of t)o===e.length?e.push(r=new i(this.O(Mr()),this.O(Mr()),this,this.options)):r=e[o],r._$AI(a),o++;o<e.length&&(this._$AR(r&&r._$AB.nextSibling,o),e.length=o)}_$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 o=t.nextSibling;t.remove(),t=o}}setConnected(t){var e;this._$AM===void 0&&(this.v=t,(e=this._$AP)==null||e.call(this,t))}},vt=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,r,o,a){this.type=1,this._$AH=g,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=a,r.length>2||r[0]!==""||r[1]!==""?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=g}_$AI(t,e=this,r,o){let a=this.strings,s=!1;if(a===void 0)t=gt(this,t,e,0),s=!Dr(t)||t!==this._$AH&&t!==Pe,s&&(this._$AH=t);else{let l=t,d,p;for(t=a[0],d=0;d<a.length-1;d++)p=gt(this,l[r+d],e,d),p===Pe&&(p=this._$AH[d]),s||(s=!Dr(p)||p!==this._$AH[d]),p===g?t=g:t!==g&&(t+=(p!=null?p:"")+a[d+1]),this._$AH[d]=p}s&&!o&&this.j(t)}j(t){t===g?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t!=null?t:"")}},xo=class extends vt{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===g?void 0:t}},Eo=class extends vt{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==g)}},To=class extends vt{constructor(t,e,r,o,a){super(t,e,r,o,a),this.type=5}_$AI(t,e=this){var s;if((t=(s=gt(this,t,e,0))!=null?s:g)===Pe)return;let r=this._$AH,o=t===g&&r!==g||t.capture!==r.capture||t.once!==r.once||t.passive!==r.passive,a=t!==g&&(r===g||o);o&&this.element.removeEventListener(this.name,this,r),a&&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)}},Ao=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){gt(this,t)}},Ns={M:Mi,P:ze,A:Di,C:1,L:ws,R:yo,D:Is,V:gt,I:Zt,H:vt,N:Eo,U:To,B:xo,F:Ao},Oi=Or.litHtmlPolyfillSupport,Ss;Oi==null||Oi($r,Zt),((Ss=Or.litHtmlVersions)!=null?Ss:Or.litHtmlVersions=[]).push("3.2.0");var _s=(i,t,e)=>{var a,s;let r=(a=e==null?void 0:e.renderBefore)!=null?a:t,o=r._$litPart$;if(o===void 0){let l=(s=e==null?void 0:e.renderBefore)!=null?s:null;r._$litPart$=o=new Zt(t.insertBefore(Mr(),l),l,void 0,e!=null?e:{})}return o._$AI(i),o};var ot=class extends $e{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=_s(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 Pe}},Ls;ot._$litElement$=!0,ot.finalized=!0,(Ls=globalThis.litElementHydrateSupport)==null||Ls.call(globalThis,{LitElement:ot});var Pi=globalThis.litElementPolyfillSupport;Pi==null||Pi({LitElement:ot});var Rs;((Rs=globalThis.litElementVersions)!=null?Rs:globalThis.litElementVersions=[]).push("4.1.0");var ed={attribute:!0,type:String,converter:Lr,reflect:!1,hasChanged:go},td=(i=ed,t,e)=>{let{kind:r,metadata:o}=e,a=globalThis.litPropertyMetadata.get(o);if(a===void 0&&globalThis.litPropertyMetadata.set(o,a=new Map),a.set(e.name,i),r==="accessor"){let{name:s}=e;return{set(l){let d=t.get.call(this);t.set.call(this,l),this.requestUpdate(s,d,i)},init(l){return l!==void 0&&this.P(s,void 0,i),l}}}if(r==="setter"){let{name:s}=e;return function(l){let d=this[s];t.call(this,l),this.requestUpdate(s,d,i)}}throw Error("Unsupported decorator location: "+r)};function c(i){return(t,e)=>typeof e=="object"?td(i,t,e):((r,o,a)=>{let s=o.hasOwnProperty(a);return o.constructor.createProperty(a,s?{...r,wrapped:!0}:r),s?Object.getOwnPropertyDescriptor(o,a):void 0})(i,t,e)}function L(i){return c({...i,state:!0,attribute:!1})}var Ve=(i,t,e)=>(e.configurable=!0,e.enumerable=!0,Reflect.decorate&&typeof t!="object"&&Object.defineProperty(i,t,e),e);function Ue(i,t){return(e,r,o)=>{let a=s=>{var l,d;return(d=(l=s.renderRoot)==null?void 0:l.querySelector(i))!=null?d:null};if(t){let{get:s,set:l}=typeof r=="object"?e:o!=null?o:(()=>{let d=Symbol();return{get(){return this[d]},set(p){this[d]=p}}})();return Ve(e,r,{get(){let d=s.call(this);return d===void 0&&(d=a(this),(d!==null||this.hasUpdated)&&l.call(this,d)),d}})}return Ve(e,r,{get(){return a(this)}})}}function G(i){return(t,e)=>{let{slot:r,selector:o}=i!=null?i:{},a="slot"+(r?`[name=${r}]`:":not([name])");return Ve(t,e,{get(){var d,p;let s=(d=this.renderRoot)==null?void 0:d.querySelector(a),l=(p=s==null?void 0:s.assignedElements(i))!=null?p:[];return o===void 0?l:l.filter(h=>h.matches(o))}})}}function So(i){return(t,e)=>{let{slot:r}=i!=null?i:{},o="slot"+(r?`[name=${r}]`:":not([name])");return Ve(t,e,{get(){var s,l;let a=(s=this.renderRoot)==null?void 0:s.querySelector(o);return(l=a==null?void 0:a.assignedNodes(i))!=null?l:[]}})}}var N=u`
|
4
4
|
:host {
|
5
5
|
align-items: center;
|
6
6
|
display: flex;
|
@@ -8,7 +8,7 @@
|
|
8
8
|
justify-content: center;
|
9
9
|
width: fit-content;
|
10
10
|
}
|
11
|
-
`,
|
11
|
+
`,Io=u`
|
12
12
|
:host {
|
13
13
|
--mdc-focus-ring-inner-color: var(--mds-color-theme-focus-default-0);
|
14
14
|
--mdc-focus-ring-middle-color: var(--mds-color-theme-focus-default-1);
|
@@ -21,10 +21,10 @@
|
|
21
21
|
--mdc-focus-ring-middle-offset: var(--mdc-focus-ring-inner-width);
|
22
22
|
--mdc-focus-ring-outer-offset: calc(var(--mdc-focus-ring-inner-width) + var(--mdc-focus-ring-middle-width));
|
23
23
|
}
|
24
|
-
`,
|
24
|
+
`,_=(i=!1)=>{let t=u`0 0 0 var(--mdc-focus-ring-inner-width) var(--mdc-focus-ring-inner-color),
|
25
25
|
0 0 0 var(--mdc-focus-ring-middle-width) var(--mdc-focus-ring-middle-color),
|
26
26
|
0 0 0 var(--mdc-focus-ring-outer-width) var(--mdc-focus-ring-outer-color)
|
27
|
-
`;return i?[
|
27
|
+
`;return i?[Io,u`
|
28
28
|
.mdc-focus-ring:focus-visible {
|
29
29
|
outline: none;
|
30
30
|
}
|
@@ -48,7 +48,7 @@
|
|
48
48
|
outline: 0.125rem solid var(--mds-color-theme-focus-default-0);
|
49
49
|
}
|
50
50
|
}
|
51
|
-
`]:[
|
51
|
+
`]:[Io,u`
|
52
52
|
:host([disabled]:focus) {
|
53
53
|
box-shadow: none;
|
54
54
|
}
|
@@ -63,7 +63,7 @@
|
|
63
63
|
outline: 0.125rem solid var(--mds-color-theme-focus-default-0);
|
64
64
|
}
|
65
65
|
}
|
66
|
-
`]};var
|
66
|
+
`]};var rd=u`
|
67
67
|
:host {
|
68
68
|
height: 1.5rem;
|
69
69
|
gap: 0.25rem;
|
@@ -166,7 +166,7 @@
|
|
166
166
|
:host([variant="informational"]:active){
|
167
167
|
--mdc-chip-background-color: var(--mds-color-theme-background-alert-theme-active);
|
168
168
|
}
|
169
|
-
`,
|
169
|
+
`,Os=[N,rd,..._()];var Ms=u`
|
170
170
|
:host {
|
171
171
|
box-sizing: border-box;
|
172
172
|
}
|
@@ -176,11 +176,11 @@
|
|
176
176
|
:host *::after {
|
177
177
|
box-sizing: inherit;
|
178
178
|
}
|
179
|
-
`;var
|
179
|
+
`;var Co=class extends ot{static register(t){customElements.get(t)||customElements.define(t,this)}};Co.styles=[Ms];var Ds=Co;var v=Ds;var it=class extends Event{constructor(t,e,r){super("context-request",{bubbles:!0,composed:!0}),this.context=t,this.callback=e,this.subscribe=r!=null?r:!1}};var Xt=class{constructor(t,e,r,o){var a;if(this.subscribe=!1,this.provided=!1,this.value=void 0,this.t=(s,l)=>{this.unsubscribe&&(this.unsubscribe!==l&&(this.provided=!1,this.unsubscribe()),this.subscribe||this.unsubscribe()),this.value=s,this.host.requestUpdate(),this.provided&&!this.subscribe||(this.provided=!0,this.callback&&this.callback(s,l)),this.unsubscribe=l},this.host=t,e.context!==void 0){let s=e;this.context=s.context,this.callback=s.callback,this.subscribe=(a=s.subscribe)!=null?a:!1}else this.context=e,this.callback=r,this.subscribe=o!=null?o:!1;this.host.addController(this)}hostConnected(){this.dispatchRequest()}hostDisconnected(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=void 0)}dispatchRequest(){this.host.dispatchEvent(new it(this.context,this.t,this.subscribe))}};var ko=class{get value(){return this.o}set value(t){this.setValue(t)}setValue(t,e=!1){let r=e||!Object.is(t,this.o);this.o=t,r&&this.updateObservers()}constructor(t){this.subscriptions=new Map,this.updateObservers=()=>{for(let[e,{disposer:r}]of this.subscriptions)e(this.o,r)},t!==void 0&&(this.value=t)}addCallback(t,e,r){if(!r)return void t(this.value);this.subscriptions.has(t)||this.subscriptions.set(t,{disposer:()=>{this.subscriptions.delete(t)},consumerHost:e});let{disposer:o}=this.subscriptions.get(t);t(this.value,o)}clearCallbacks(){this.subscriptions.clear()}};var Vi=class extends Event{constructor(t){super("context-provider",{bubbles:!0,composed:!0}),this.context=t}},jt=class extends ko{constructor(t,e,r){var o,a;super(e.context!==void 0?e.initialValue:r),this.onContextRequest=s=>{let l=s.composedPath()[0];s.context===this.context&&l!==this.host&&(s.stopPropagation(),this.addCallback(s.callback,l,s.subscribe))},this.onProviderRequest=s=>{let l=s.composedPath()[0];if(s.context!==this.context||l===this.host)return;let d=new Set;for(let[p,{consumerHost:h}]of this.subscriptions)d.has(p)||(d.add(p),h.dispatchEvent(new it(this.context,p,!0)));s.stopPropagation()},this.host=t,e.context!==void 0?this.context=e.context:this.context=e,this.attachListeners(),(a=(o=this.host).addController)==null||a.call(o,this)}attachListeners(){this.host.addEventListener("context-request",this.onContextRequest),this.host.addEventListener("context-provider",this.onProviderRequest)}hostConnected(){this.host.dispatchEvent(new Vi(this.context))}};var od=u`
|
180
180
|
:host {
|
181
181
|
display: contents;
|
182
182
|
}
|
183
|
-
`,
|
183
|
+
`,zs=od;var wo=class extends v{constructor({context:t,initialValue:e}){super(),this.context=new jt(this,{context:t,initialValue:e})}render(){return this.updateContext(),m`<slot></slot>`}};wo.styles=[...v.styles,zs];var Ps=wo;var Qt=Ps;var id={PREFIX:"mdc",SEPARATOR:"-"},ad={NAMESPACE:id},Ui=ad;var sd=i=>[Ui.NAMESPACE.PREFIX,i].join(Ui.NAMESPACE.SEPARATOR),f={constructTagName:sd};var Mu=f.constructTagName("buttonsimple"),zr={20:20,24:24,28:28,32:32,40:40,48:48,52:52,64:64,72:72,88:88,124:124},Jt={BUTTON:"button",SUBMIT:"submit",RESET:"reset"},Pr={SIZE:zr[32],TYPE:Jt.BUTTON,ROLE:"button",ARIA_STATE_KEY:"aria-pressed"};var Vr=f.constructTagName("text"),S={BODY_SMALL_REGULAR:"body-small-regular",BODY_SMALL_MEDIUM:"body-small-medium",BODY_SMALL_BOLD:"body-small-bold",BODY_MIDSIZE_REGULAR:"body-midsize-regular",BODY_MIDSIZE_MEDIUM:"body-midsize-medium",BODY_MIDSIZE_BOLD:"body-midsize-bold",BODY_LARGE_REGULAR:"body-large-regular",BODY_LARGE_MEDIUM:"body-large-medium",BODY_LARGE_BOLD:"body-large-bold",BODY_SMALL_REGULAR_UNDERLINE:"body-small-regular-underline",BODY_SMALL_MEDIUM_UNDERLINE:"body-small-medium-underline",BODY_MIDSIZE_REGULAR_UNDERLINE:"body-midsize-regular-underline",BODY_MIDSIZE_MEDIUM_UNDERLINE:"body-midsize-medium-underline",BODY_LARGE_REGULAR_UNDERLINE:"body-large-regular-underline",BODY_LARGE_MEDIUM_UNDERLINE:"body-large-medium-underline",HEADING_SMALL_REGULAR:"heading-small-regular",HEADING_SMALL_MEDIUM:"heading-small-medium",HEADING_SMALL_BOLD:"heading-small-bold",HEADING_MIDSIZE_REGULAR:"heading-midsize-regular",HEADING_MIDSIZE_MEDIUM:"heading-midsize-medium",HEADING_MIDSIZE_BOLD:"heading-midsize-bold",HEADING_LARGE_REGULAR:"heading-large-regular",HEADING_LARGE_MEDIUM:"heading-large-medium",HEADING_LARGE_BOLD:"heading-large-bold",HEADING_XLARGE_REGULAR:"heading-xlarge-regular",HEADING_XLARGE_MEDIUM:"heading-xlarge-medium",HEADING_XLARGE_BOLD:"heading-xlarge-bold",HEADLINE_SMALL_LIGHT:"headline-small-light",HEADLINE_SMALL_REGULAR:"headline-small-regular"},w={H1:"h1",H2:"h2",H3:"h3",H4:"h4",H5:"h5",H6:"h6",P:"p",SMALL:"small",SPAN:"span",DIV:"div"},le={TYPE:S.BODY_LARGE_REGULAR,TEXT_ELEMENT_TAGNAME:w.P,CSS_PART_TEXT:"text",CHILDREN:"The quick brown fox jumps over the lazy dog"};var Vs=f.constructTagName("alertchip"),yt={NEUTRAL:"neutral",ERROR:"error",SUCCESS:"success",WARNING:"warning",INFORMATIONAL:"informational"},er={VARIANT:yt.NEUTRAL,TEXT_TYPE:S.BODY_MIDSIZE_REGULAR,TAG_NAME:w.SPAN,SIZE:zr[24],ROLE:"button"};var Us=i=>({[yt.ERROR]:"error-legacy-badge-filled",[yt.WARNING]:"warning-badge-filled",[yt.SUCCESS]:"check-circle-badge-filled",[yt.INFORMATIONAL]:"info-badge-filled",[yt.NEUTRAL]:"dnd-presence-badge-filled"})[i];var P=i=>{class t extends i{}return n([c({reflect:!0,type:Boolean})],t.prototype,"disabled",2),t};var _e=i=>{class t extends i{constructor(){super(...arguments);this.tabIndex=0}}return n([c({reflect:!0,type:Number})],t.prototype,"tabIndex",2),t};var nd=[N,u`
|
184
184
|
:host {
|
185
185
|
border: 0.0625rem solid transparent;
|
186
186
|
cursor: pointer;
|
@@ -237,10 +237,10 @@
|
|
237
237
|
:host([size="20"]){
|
238
238
|
height: var(--mdc-button-height-size-20);
|
239
239
|
}
|
240
|
-
`,...
|
241
|
-
<mdc-icon part="icon" name="${
|
242
|
-
<mdc-text part="label" type="${
|
243
|
-
`}};
|
240
|
+
`,..._()],Fs=nd;var xe=class extends _e(P(v)){constructor(){super();this.size=Pr.SIZE;this.role=Pr.ROLE;this.type=Pr.TYPE;this.prevTabindex=0;this.internals=this.attachInternals(),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))}get form(){return this.internals.form}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.active!==void 0&&(this.ariaStateKey=this.ariaStateKey||Pr.ARIA_STATE_KEY),this.setActive(this,this.active))}executeAction(){this.type===Jt.SUBMIT&&this.form&&this.form.requestSubmit(),this.type===Jt.RESET&&this.form&&this.form.reset()}setActive(e,r){this.ariaStateKey&&this.ariaStateKey.split(",").filter(a=>a.trim().startsWith("aria-")).forEach(a=>{r===!0?e.setAttribute(a.trim(),"true"):r===!1?e.setAttribute(a.trim(),"false"):e.removeAttribute(a.trim())})}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(),e.preventDefault())}handleKeyUp(e){["Enter"," "].includes(e.key)&&(this.classList.remove("pressed"),e.key===" "&&this.triggerClickEvent())}render(){return m` <slot></slot> `}};xe.formAssociated=!0,xe.styles=[...v.styles,...Fs],n([c({type:Boolean,reflect:!0})],xe.prototype,"active",2),n([c({type:Boolean,attribute:"soft-disabled",reflect:!0})],xe.prototype,"softDisabled",2),n([c({type:Number,reflect:!0})],xe.prototype,"size",2),n([c({type:String,reflect:!0})],xe.prototype,"role",2),n([c({type:String,reflect:!0})],xe.prototype,"ariaStateKey",2),n([c({reflect:!0})],xe.prototype,"type",2);var re=xe;var tr=class extends re{constructor(){super(...arguments);this.variant=er.VARIANT;this.label=""}connectedCallback(){super.connectedCallback(),this.disabled=void 0,this.softDisabled=void 0,this.active=void 0,this.size=er.SIZE,this.role=er.ROLE}render(){return m`
|
241
|
+
<mdc-icon part="icon" name="${Us(this.variant)}" length-unit="rem" size="1"></mdc-icon>
|
242
|
+
<mdc-text part="label" type="${er.TEXT_TYPE}" tagname="${er.TAG_NAME}">${this.label}</mdc-text>
|
243
|
+
`}};tr.styles=[...v.styles,...Os],n([c({type:String})],tr.prototype,"variant",2),n([c({type:String})],tr.prototype,"label",2);var Fi=tr;var Bs=u`
|
244
244
|
:host::part(text) {
|
245
245
|
font-size: unset;
|
246
246
|
font-weight: unset;
|
@@ -483,14 +483,14 @@
|
|
483
483
|
text-decoration: var(--mds-font-apps-body-small-regular-text-decoration);
|
484
484
|
text-transform: var(--mds-font-apps-body-small-regular-text-case);
|
485
485
|
}
|
486
|
-
`;var
|
486
|
+
`;var ld=[u`
|
487
487
|
:host {
|
488
488
|
--mdc-text-font-family: var(--mdc-themeprovider-font-family);
|
489
489
|
|
490
490
|
display: block;
|
491
491
|
font-family: var(--mdc-text-font-family);
|
492
492
|
}
|
493
|
-
`,
|
493
|
+
`,Bs],Hs=ld;var rr=class extends v{constructor(){super(...arguments);this.type=le.TYPE;this.tagname=le.TEXT_ELEMENT_TAGNAME}render(){switch(this.tagname){case w.H1:return m`<h1 part=${le.CSS_PART_TEXT}><slot></slot></h1>`;case w.H2:return m`<h2 part=${le.CSS_PART_TEXT}><slot></slot></h2>`;case w.H3:return m`<h3 part=${le.CSS_PART_TEXT}><slot></slot></h3>`;case w.H4:return m`<h4 part=${le.CSS_PART_TEXT}><slot></slot></h4>`;case w.H5:return m`<h5 part=${le.CSS_PART_TEXT}><slot></slot></h5>`;case w.H6:return m`<h6 part=${le.CSS_PART_TEXT}><slot></slot></h6>`;case w.DIV:return m`<div part=${le.CSS_PART_TEXT}><slot></slot></div>`;case w.SPAN:return m`<span part=${le.CSS_PART_TEXT}><slot></slot></span>`;case w.SMALL:return m`<small part=${le.CSS_PART_TEXT}><slot></slot></small>`;case w.P:default:return m`<p part=${le.CSS_PART_TEXT}><slot></slot></p>`}}};rr.styles=[...v.styles,...Hs],n([c({attribute:"type",reflect:!0,type:String})],rr.prototype,"type",2),n([c({attribute:"tagname",reflect:!0,type:String})],rr.prototype,"tagname",2);var Bi=rr;Bi.register(Vr);var cd=Bi;var dd=[N,u`
|
494
494
|
:host {
|
495
495
|
--mdc-icon-fill-color: currentColor;
|
496
496
|
--mdc-icon-size: var(--computed-icon-size);
|
@@ -505,7 +505,7 @@
|
|
505
505
|
width: 100%;
|
506
506
|
fill: var(--mdc-icon-fill-color);
|
507
507
|
}
|
508
|
-
`,...
|
508
|
+
`,..._()],Gs=dd;var md=i=>{let{host:t,context:e,subscribe:r}=i;return new Xt(t,{context:e,subscribe:r!=null?r:!0})},pd={consume:md},Ys=pd;var No=f.constructTagName("iconprovider"),Ws=["svg"],qs=["em","rem","px","%"],hd={px:16,em:1,rem:1,"%":100},Fe={FILE_EXTENSION:"svg",LENGTH_UNIT:"em",SIZE:hd.em,SHOULD_CACHE:!1,ICON_SET:"momentum-icons"};var _o=class{};_o.context=No;var Lo=_o;var Le=class extends Qt{constructor(){super({context:Lo.context,initialValue:new Lo});this.iconSet=Fe.ICON_SET;this.fileExtension=Fe.FILE_EXTENSION;this.lengthUnit=Fe.LENGTH_UNIT;this.size=Fe.SIZE}static get Context(){return Lo.context}updateValuesInContext(){this.fileExtension&&Ws.includes(this.fileExtension)?this.context.value.fileExtension=this.fileExtension:(this.fileExtension=Fe.FILE_EXTENSION,this.context.value.fileExtension=Fe.FILE_EXTENSION),this.context.value.iconSet=this.iconSet,this.context.value.url=this.url,this.context.value.size=this.size,this.context.value.cacheName=this.cacheName,this.context.value.cacheStrategy=this.cacheStrategy,this.lengthUnit&&qs.includes(this.lengthUnit)?this.context.value.lengthUnit=this.lengthUnit:(this.lengthUnit=Fe.LENGTH_UNIT,this.context.value.lengthUnit=Fe.LENGTH_UNIT)}updateContext(){(this.context.value.fileExtension!==this.fileExtension||this.context.value.iconSet!==this.iconSet||this.context.value.url!==this.url||this.context.value.lengthUnit!==this.lengthUnit||this.context.value.size!==this.size||this.context.value.cacheName!==this.cacheName||this.context.value.cacheStrategy!==this.cacheStrategy)&&(this.updateValuesInContext(),this.context.updateObservers())}};n([c({type:String,attribute:"icon-set",reflect:!0})],Le.prototype,"iconSet",2),n([c({type:String})],Le.prototype,"url",2),n([c({type:String,attribute:"file-extension",reflect:!0})],Le.prototype,"fileExtension",2),n([c({type:String,attribute:"length-unit",reflect:!0})],Le.prototype,"lengthUnit",2),n([c({type:Number,reflect:!0})],Le.prototype,"size",2),n([c({type:String,attribute:"cache-strategy"})],Le.prototype,"cacheStrategy",2),n([c({type:String,attribute:"cache-name"})],Le.prototype,"cacheName",2);var Ur=Le;var Fr={},Ks=async i=>(Fr[i]===void 0&&(Fr[i]=new Map),{async set(t,e){Fr[i].set(t.url,await e.text())},async get(t){return Fr[i].get(t.url)},async delete(t){Fr[i].delete(t.url)}}),Zs=async i=>{let t=await caches.open(i);return{set:async(e,r)=>{await t.put(e,r)},get:async e=>{let r=await t.match(e);return r==null?void 0:r.text()},delete:async e=>{await t.delete(e)}}},Xs=async(i,t)=>t==="in-memory-cache"?Ks(i):Zs(i);var js=async i=>fetch(i).then(t=>{if(!t.ok)throw new Error("There was a problem while fetching the icon!");return t}),Qs=async({url:i,name:t,fileExtension:e,cacheStrategy:r,cacheName:o,renewSignal:a})=>{let s=a(),l=new Request(`${i}/${t}.${e}`,{signal:s});return!o||!r||!["in-memory-cache","web-cache-api"].includes(r)?js(l).then(d=>d.text()):Xs(o,r).then(d=>d.get(l).then(p=>p||js(l.clone()).then(h=>{var b;return h.status<400&&h.headers.has("content-type")?(b=d.set)==null?void 0:b.call(d,l,h.clone()).then(()=>h.text()):h.text()})).catch(p=>{throw new Error(`Error in caching the Icon ${t}, ${p}`)}))};var Js=f.constructTagName("icon"),Hi={NAME:void 0,SIZE:1};var ce=class extends v{constructor(){super();this.name=Hi.NAME;this.ariaLabel=null;this.ariaLabelledBy=null;this.iconProviderContext=Ys.consume({host:this,context:Ur.Context});this.abortController=new AbortController}prepareIconElement(e){let r=new DOMParser().parseFromString(e,"text/html").body.children[0];return this.name&&r.setAttribute("data-name",this.name),r.setAttribute("part","icon"),r.setAttribute("aria-hidden","true"),r}async getIconData(){if(this.iconProviderContext.value){let{fileExtension:r,url:o,cacheName:a,iconSet:s,cacheStrategy:l}=this.iconProviderContext.value;if(s==="custom-icons"&&o&&r&&this.name){let d=()=>(this.abortController.abort(),this.abortController=new AbortController,this.abortController.signal);return Qs({url:o,name:this.name,fileExtension:r,cacheName:a,cacheStrategy:l,renewSignal:d}).then(p=>{let h=this.prepareIconElement(p);this.handleIconLoadedSuccess(h)}).catch(p=>{this.handleIconLoadedFailure(p)})}if(s==="momentum-icons"&&this.name)return import(`@momentum-design/icons/dist/ts/${this.name}.ts`).then(d=>{this.handleIconLoadedSuccess(d.default())}).catch(d=>{this.handleIconLoadedFailure(d)})}let e=new Error("IconProvider not found or not properly set up.");return this.handleIconLoadedFailure(e),Promise.reject(e)}handleIconLoadedSuccess(e){this.iconData=e;let r=new Event("load",{bubbles:!0,cancelable:!0});this.dispatchEvent(r)}handleIconLoadedFailure(e){let r=new CustomEvent("error",{bubbles:!0,cancelable:!0,detail:{error:e}});this.dispatchEvent(r)}updateSize(){var e;if(this.computedIconSize&&(this.lengthUnit||this.lengthUnitFromContext)){let r=`${this.computedIconSize}${(e=this.lengthUnit)!=null?e:this.lengthUnitFromContext}`;this.style.setProperty("--computed-icon-size",r)}}get computedIconSize(){var e,r;return(r=(e=this.size)!=null?e:this.sizeFromContext)!=null?r:Hi.SIZE}updated(e){var r,o,a,s;super.updated(e),e.has("name")&&this.getIconData().catch(l=>{l.name!=="AbortError"&&this.onerror&&this.onerror(l)}),(e.has("ariaLabel")||e.has("ariaLabelledBy"))&&(this.role=this.ariaLabel||this.ariaLabelledBy?"img":null),(e.has("size")||e.has("lengthUnit"))&&this.updateSize(),this.lengthUnitFromContext!==((r=this.iconProviderContext.value)==null?void 0:r.lengthUnit)&&(this.lengthUnitFromContext=(o=this.iconProviderContext.value)==null?void 0:o.lengthUnit,this.updateSize()),this.sizeFromContext!==((a=this.iconProviderContext.value)==null?void 0:a.size)&&(this.sizeFromContext=(s=this.iconProviderContext.value)==null?void 0:s.size,this.updateSize())}render(){return m` ${this.iconData} `}};ce.styles=[...v.styles,...Gs],n([L()],ce.prototype,"iconData",2),n([L()],ce.prototype,"lengthUnitFromContext",2),n([L()],ce.prototype,"sizeFromContext",2),n([c({type:String,reflect:!0})],ce.prototype,"name",2),n([c({type:Number})],ce.prototype,"size",2),n([c({type:String,attribute:"length-unit"})],ce.prototype,"lengthUnit",2),n([c({type:String,attribute:"aria-label"})],ce.prototype,"ariaLabel",2),n([c({type:String,attribute:"aria-labelledby"})],ce.prototype,"ariaLabelledBy",2),n([L()],ce.prototype,"abortController",2);var Gi=ce;Gi.register(Js);var ud=Gi;Fi.register(Vs);var fd=Fi;var bd=u`
|
509
509
|
:host {
|
510
510
|
--mdc-appheader-height: 4rem;
|
511
511
|
}
|
@@ -539,7 +539,7 @@
|
|
539
539
|
:host::part(trailing-section) {
|
540
540
|
justify-content: flex-end;
|
541
541
|
}
|
542
|
-
|
542
|
+
`,en=[bd];var Ro=class extends v{render(){return m`
|
543
543
|
<header part="container">
|
544
544
|
<div part="leading-section">
|
545
545
|
<slot name="leading"></slot>
|
@@ -550,7 +550,7 @@
|
|
550
550
|
<div part="trailing-section">
|
551
551
|
<slot name="trailing"></slot>
|
552
552
|
</div>
|
553
|
-
</header>`}};
|
553
|
+
</header>`}};Ro.styles=[...v.styles,...en];var Yi=Ro;var tn=f.constructTagName("appheader");Yi.register(tn);var gd=Yi;var T=i=>i!=null?i:g;var rn=f.constructTagName("avatar"),Q={COUNTER:"counter",ICON:"icon",PHOTO:"photo",TEXT:"text"},Wi=99,vd="user-regular",D={24:24,32:32,48:48,64:64,72:72,88:88,124:124},or={TYPE:Q.PHOTO,SIZE:D[32],ICON_NAME:vd};var Oo=i=>{class t extends i{constructor(){super(...arguments);this.size=or.SIZE;this.isTyping=!1}}return n([c({type:String})],t.prototype,"src",2),n([c({type:String})],t.prototype,"initials",2),n([c({type:String})],t.prototype,"presence",2),n([c({type:Number,reflect:!0,attribute:"size"})],t.prototype,"size",2),n([c({type:Number})],t.prototype,"counter",2),n([c({type:Boolean,attribute:"is-typing"})],t.prototype,"isTyping",2),t};var oe=i=>{class t extends i{}return n([c({type:String,attribute:"icon-name"})],t.prototype,"iconName",2),t};var yd=[N,u`
|
554
554
|
:host {
|
555
555
|
--mdc-avatar-default-background-color: var(--mds-color-theme-avatar-default);
|
556
556
|
--mdc-avatar-default-foreground-color: var(--mds-color-theme-common-text-primary-normal);
|
@@ -673,8 +673,8 @@
|
|
673
673
|
outline: 0.125rem solid;
|
674
674
|
}
|
675
675
|
}
|
676
|
-
`],
|
677
|
-
<mdc-presence part="presence" type="${this.presence}" size="${
|
676
|
+
`],on=yd;var an=f.constructTagName("presence"),X={ACTIVE:"active",AWAY:"away",AWAY_CALLING:"away-calling",BUSY:"busy",DND:"dnd",MEETING:"meeting",ON_CALL:"on-call",ON_DEVICE:"on-device",ON_MOBILE:"on-mobile",PAUSE:"pause",PTO:"pto",PRESENTING:"presenting",QUIET:"quiet",SCHEDULED:"scheduled"},Y={XX_SMALL:"xx_small",X_SMALL:"x_small",SMALL:"small",MIDSIZE:"midsize",LARGE:"large",X_LARGE:"x_large",XX_LARGE:"xx_large"},ir={TYPE:X.ACTIVE,SIZE:Y.SMALL};var sn=i=>({[D[124]]:Y.XX_LARGE,[D[88]]:Y.X_LARGE,[D[72]]:Y.LARGE,[D[64]]:Y.MIDSIZE,[D[48]]:Y.SMALL,[D[32]]:Y.X_SMALL,[D[24]]:Y.XX_SMALL})[i]||Y.X_SMALL,nn=i=>({[D[124]]:4.75,[D[88]]:3,[D[72]]:2.5,[D[64]]:2.25,[D[48]]:1.75,[D[32]]:1.25,[D[24]]:1})[i]||1.25,ln=i=>({[D[124]]:S.HEADING_XLARGE_MEDIUM,[D[88]]:S.HEADING_LARGE_MEDIUM,[D[72]]:S.HEADING_MIDSIZE_MEDIUM,[D[64]]:S.HEADING_SMALL_MEDIUM,[D[48]]:S.HEADING_SMALL_MEDIUM,[D[32]]:S.BODY_MIDSIZE_MEDIUM,[D[24]]:S.BODY_SMALL_MEDIUM})[i]||S.BODY_MIDSIZE_MEDIUM;var Br=class extends Oo(oe(v)){constructor(){super(...arguments);this.isPhotoLoaded=!1}getPresenceTemplateBasedOnType(e){return e===Q.COUNTER&&(this.counter||this.counter===0)||this.isTyping?g:this.presence?m`
|
677
|
+
<mdc-presence part="presence" type="${this.presence}" size="${sn(this.size)}"></mdc-presence>
|
678
678
|
`:g}handleOnLoad(){this.isPhotoLoaded=!0}handleOnError(){this.isPhotoLoaded=!1,this.onerror&&this.onerror("There was a problem while fetching the <img/>. Please check the src attribute and try again.")}photoTemplate(){return m`
|
679
679
|
<img
|
680
680
|
part="photo"
|
@@ -684,27 +684,27 @@
|
|
684
684
|
@load="${this.handleOnLoad}"
|
685
685
|
@error="${this.handleOnError}"
|
686
686
|
/>
|
687
|
-
`}iconTemplate(){let e=this.iconName||
|
687
|
+
`}iconTemplate(){let e=this.iconName||or.ICON_NAME;return m`
|
688
688
|
<mdc-icon
|
689
689
|
name="${T(e)}"
|
690
690
|
length-unit="rem"
|
691
|
-
size="${
|
691
|
+
size="${nn(this.size)}"
|
692
692
|
></mdc-icon>
|
693
693
|
`}textTemplate(e){return m`
|
694
694
|
<mdc-text
|
695
|
-
type="${
|
695
|
+
type="${ln(this.size)}"
|
696
696
|
tagname="span"
|
697
697
|
>
|
698
698
|
${e}
|
699
699
|
</mdc-text>
|
700
|
-
`}generateCounterText(e){return e<0?"0":e>
|
700
|
+
`}generateCounterText(e){return e<0?"0":e>Wi?`${Wi}+`:e.toString()}generateInitialsText(e){return e.toUpperCase().slice(0,2)}generateTextContent(e){let r="";return e===Q.TEXT&&this.initials&&(r=this.generateInitialsText(this.initials)),e===Q.COUNTER&&(this.counter||this.counter===0)&&(r=this.generateCounterText(this.counter)),this.textTemplate(r)}getTypeBasedOnInputs(){return this.src?Q.PHOTO:this.iconName?Q.ICON:this.initials?Q.TEXT:this.counter||this.counter===0?Q.COUNTER:Q.ICON}getTemplateBasedOnType(e){switch(e){case Q.PHOTO:return this.photoTemplate();case Q.TEXT:case Q.COUNTER:return this.generateTextContent(e);case Q.ICON:default:return this.iconTemplate()}}getLoadingContent(){return this.isTyping?m`<div part="loading-wrapper"><div part="loader"></div></div>`:g}getPhotoPlaceHolderContent(e){return this.isPhotoLoaded?g:e===Q.PHOTO?this.initials?this.textTemplate(this.generateInitialsText(this.initials)):this.iconTemplate():g}update(e){super.update(e),e.has("src")&&!this.src&&(this.isPhotoLoaded=!1)}render(){let e=this.getTypeBasedOnInputs();return m`
|
701
701
|
<div part="content" aria-hidden="true">
|
702
702
|
${this.getPhotoPlaceHolderContent(e)}
|
703
703
|
${this.getTemplateBasedOnType(e)}
|
704
704
|
${this.getLoadingContent()}
|
705
705
|
${this.getPresenceTemplateBasedOnType(e)}
|
706
706
|
</div>
|
707
|
-
`}};
|
707
|
+
`}};Br.styles=[...v.styles,...on],n([L()],Br.prototype,"isPhotoLoaded",2);var qi=Br;var xd=[N,u`
|
708
708
|
:host {
|
709
709
|
--mdc-presence-active-background-color: var(--mds-color-theme-indicator-stable);
|
710
710
|
--mdc-presence-away-background-color: var(--mds-color-theme-indicator-locked);
|
@@ -798,7 +798,7 @@
|
|
798
798
|
.mdc-presence-icon__scheduled {
|
799
799
|
color: var(--mdc-presence-scheduled-background-color);
|
800
800
|
}
|
801
|
-
`],
|
801
|
+
`],cn=xd;var dn=i=>{switch(i){case X.AWAY:return"recents-presence-badge-filled";case X.AWAY_CALLING:return"away-calling-presence-filled";case X.BUSY:return"busy-presence-bold";case X.DND:return"dnd-presence-badge-filled";case X.MEETING:return"camera-filled";case X.ON_CALL:return"handset-filled";case X.ON_DEVICE:return"generic-device-video-badge-filled";case X.ON_MOBILE:return"phone-badge-filled";case X.PAUSE:return"pause-badge-filled";case X.PTO:return"pto-presence-filled";case X.PRESENTING:return"share-screen-badge-filled";case X.QUIET:return"quiet-hours-presence-filled";case X.SCHEDULED:return"meetings-presence-badge-filled";case X.ACTIVE:default:return"active-presence-small-filled"}};var xt=class extends v{constructor(){super(...arguments);this.type=ir.TYPE;this.size=ir.SIZE;this.currentIconType=ir.TYPE}get iconSize(){switch(this.size){case Y.MIDSIZE:return 1.16125;case Y.LARGE:return 1.30625;case Y.X_LARGE:return 1.596875;case Y.XX_LARGE:return 2.25;case Y.XX_SMALL:case Y.X_SMALL:case Y.SMALL:default:return this.size=ir.SIZE,.875}}get icon(){let e=dn(this.type);return e==="active-presence-small-filled"&&(this.type=ir.TYPE),e}handleOnLoad(){this.currentIconType=this.type}handleOnError(){this.onerror&&this.onerror("There was a problem while fetching the icon. Please check the icon name and try again.")}render(){return m`
|
802
802
|
<div class="mdc-presence mdc-presence__${this.size}">
|
803
803
|
<mdc-icon
|
804
804
|
class="mdc-presence-icon mdc-presence-icon__${this.currentIconType}"
|
@@ -808,7 +808,7 @@
|
|
808
808
|
@error="${this.handleOnError}"
|
809
809
|
></mdc-icon>
|
810
810
|
</div>
|
811
|
-
`}};
|
811
|
+
`}};xt.styles=[...v.styles,...cn],n([c({type:String,reflect:!0})],xt.prototype,"type",2),n([c({type:String,reflect:!0})],xt.prototype,"size",2),n([L()],xt.prototype,"currentIconType",2);var Ki=xt;Ki.register(an);var Ed=Ki;qi.register(rn);var Td=qi;var Et=f.constructTagName("button"),ie={PRIMARY:"primary",SECONDARY:"secondary",TERTIARY:"tertiary"},Hr={40:40,32:32,28:28,24:24},ar={64:64,52:52,20:20,...Hr},Tt={POSITIVE:"positive",NEGATIVE:"negative",ACCENT:"accent",PROMOTIONAL:"promotional",DEFAULT:"default"},sr={PILL:"pill",ICON:"icon",PILL_WITH_ICON:"pill-with-icon"},ae={VARIANT:ie.PRIMARY,SIZE:Hr[32],COLOR:Tt.DEFAULT,TYPE_INTERNAL:sr.ICON,TYPE:Jt.BUTTON,INVERTED:!1};var Ad=[N,u`
|
812
812
|
:host {
|
813
813
|
--mdc-avatarbutton-overlay-background-color-rest: var(--mds-color-theme-avatar-ghost);
|
814
814
|
--mdc-avatarbutton-overlay-background-color-hover: var(--mds-color-theme-avatar-hover);
|
@@ -837,7 +837,7 @@
|
|
837
837
|
:host::part(presence) {
|
838
838
|
z-index: 2;
|
839
839
|
}
|
840
|
-
`,...
|
840
|
+
`,..._()],mn=Ad;var Gr=class extends Oo(oe(re)){constructor(){super(...arguments);this.ariaLabel=null}connectedCallback(){super.connectedCallback(),this.active=void 0,this.disabled=void 0,this.softDisabled=void 0,this.role="button",this.type=ae.TYPE}update(e){super.update(e),e.has("size")&&this.setSize(this.size)}setSize(e){this.setAttribute("size",Object.values(D).includes(e)?`${e}`:or.SIZE.toString())}render(){return m`
|
841
841
|
<div part="overlay" aria-hidden="true"></div>
|
842
842
|
<mdc-avatar
|
843
843
|
?is-typing="${this.isTyping}"
|
@@ -848,7 +848,7 @@
|
|
848
848
|
size="${T(this.size)}"
|
849
849
|
src="${T(this.src)}"
|
850
850
|
></mdc-avatar>
|
851
|
-
`}};
|
851
|
+
`}};Gr.styles=[...mn],n([c({type:String,attribute:"aria-label"})],Gr.prototype,"ariaLabel",2);var Zi=Gr;var pn=f.constructTagName("avatarbutton");Zi.register(pn);var Sd=Zi;var Mo={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},Yr=i=>(...t)=>({_$litDirective$:i,values:t}),nr=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 lr=Yr(class extends nr{constructor(i){var t;if(super(i),i.type!==Mo.ATTRIBUTE||i.name!=="class"||((t=i.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(i){return" "+Object.keys(i).filter(t=>i[t]).join(" ")+" "}update(i,[t]){var r,o;if(this.st===void 0){this.st=new Set,i.strings!==void 0&&(this.nt=new Set(i.strings.join(" ").split(/\s/).filter(a=>a!=="")));for(let a in t)t[a]&&!((r=this.nt)!=null&&r.has(a))&&this.st.add(a);return this.render(t)}let e=i.element.classList;for(let a of this.st)a in t||(e.remove(a),this.st.delete(a));for(let a in t){let s=!!t[a];s===this.st.has(a)||(o=this.nt)!=null&&o.has(a)||(s?(e.add(a),this.st.add(a)):(e.remove(a),this.st.delete(a)))}return Pe}});var hn=f.constructTagName("badge"),Be={DOT:"dot",ICON:"icon",COUNTER:"counter",SUCCESS:"success",WARNING:"warning",ERROR:"error"},Do={SUCCESS_ICON_NAME:"check-circle-badge-filled",WARNING_ICON_NAME:"warning-badge-filled",ERROR_ICON_NAME:"error-legacy-badge-filled"},$o={PRIMARY:"primary",SECONDARY:"secondary"},Wr={SUCCESS:"success",WARNING:"warning",ERROR:"error"},fv={...$o,...Wr},at={TYPE:Be.DOT,MAX_COUNTER:99,MAX_COUNTER_LIMIT:999,VARIANT:$o.PRIMARY,ICON_SIZE:1};var Id=[N,u`
|
852
852
|
:host {
|
853
853
|
--mdc-badge-primary-foreground-color: var(--mds-color-theme-common-text-primary-normal);
|
854
854
|
--mdc-badge-primary-background-color: var(--mds-color-theme-background-accent-normal);
|
@@ -917,21 +917,21 @@
|
|
917
917
|
outline: 0.125rem solid;
|
918
918
|
}
|
919
919
|
}
|
920
|
-
`],
|
920
|
+
`],un=Id;var Re=class extends oe(v){constructor(){super(...arguments);this.variant=at.VARIANT;this.maxCounter=at.MAX_COUNTER;this.overlay=!1;this.ariaLabel=null}getCounterText(e,r){return r===void 0||typeof r!="number"||e===0?"":r>e?`${e}+`:e>at.MAX_COUNTER_LIMIT||r>at.MAX_COUNTER_LIMIT?`${at.MAX_COUNTER_LIMIT}+`:r.toString()}getBadgeIcon(e,r){return m`
|
921
921
|
<mdc-icon
|
922
|
-
class="mdc-badge-icon ${
|
922
|
+
class="mdc-badge-icon ${lr({"mdc-badge-overlay":this.overlay,[`mdc-badge-icon__${r}`]:!0})}"
|
923
923
|
name="${T(e)}"
|
924
|
-
size="${
|
924
|
+
size="${at.ICON_SIZE}"
|
925
925
|
></mdc-icon>
|
926
|
-
`}getBadgeDot(){return m`<div class="mdc-badge-dot ${
|
926
|
+
`}getBadgeDot(){return m`<div class="mdc-badge-dot ${lr({"mdc-badge-overlay":this.overlay})}"></div>`}getBadgeCounterText(){return m`
|
927
927
|
<mdc-text
|
928
|
-
type="${
|
929
|
-
tagname="${
|
930
|
-
class="mdc-badge-text ${
|
928
|
+
type="${S.BODY_SMALL_MEDIUM}"
|
929
|
+
tagname="${w.DIV}"
|
930
|
+
class="mdc-badge-text ${lr({"mdc-badge-overlay":this.overlay})}"
|
931
931
|
>
|
932
932
|
${this.getCounterText(this.maxCounter,this.counter)}
|
933
933
|
</mdc-text>
|
934
|
-
`}setRoleByAriaLabel(){this.ariaLabel?this.role="img":this.role=null}getBadgeContentBasedOnType(){this.variant&&!Object.values(
|
934
|
+
`}setRoleByAriaLabel(){this.ariaLabel?this.role="img":this.role=null}getBadgeContentBasedOnType(){this.variant&&!Object.values($o).includes(this.variant)&&(this.variant=at.VARIANT);let{iconName:e,type:r,variant:o}=this;switch(r){case Be.ICON:return this.getBadgeIcon(e||"",o);case Be.COUNTER:return this.getBadgeCounterText();case Be.SUCCESS:return this.getBadgeIcon(Do.SUCCESS_ICON_NAME,Wr.SUCCESS);case Be.WARNING:return this.getBadgeIcon(Do.WARNING_ICON_NAME,Wr.WARNING);case Be.ERROR:return this.getBadgeIcon(Do.ERROR_ICON_NAME,Wr.ERROR);case Be.DOT:default:return this.type=Be.DOT,this.getBadgeDot()}}update(e){super.update(e),e.has("ariaLabel")&&this.setRoleByAriaLabel()}render(){return this.getBadgeContentBasedOnType()}};Re.styles=[...v.styles,...un],n([c({type:String,reflect:!0})],Re.prototype,"type",2),n([c({type:String,reflect:!0})],Re.prototype,"variant",2),n([c({type:Number})],Re.prototype,"counter",2),n([c({type:Number,attribute:"max-counter",reflect:!0})],Re.prototype,"maxCounter",2),n([c({type:Boolean})],Re.prototype,"overlay",2),n([c({type:String,attribute:"aria-label"})],Re.prototype,"ariaLabel",2);var Xi=Re;Xi.register(hn);var Cd=Xi;var kd=u`
|
935
935
|
:host {
|
936
936
|
display: block;
|
937
937
|
height: 100%;
|
@@ -940,7 +940,7 @@
|
|
940
940
|
height: 100%;
|
941
941
|
width: 100%;
|
942
942
|
}
|
943
|
-
`,
|
943
|
+
`,fn=[kd];var bn=f.constructTagName("brandvisual"),gn={NAME:void 0};var cr=class extends v{constructor(){super(...arguments);this.name=gn.NAME}async getBrandVisualData(){return this.name?import(`@momentum-design/brand-visuals/dist/logos/ts/${this.name}.ts`).then(e=>{this.handleBrandVisualLoadedSuccess(e.default())}).catch(e=>{this.handleBrandVisualLoadedFailure(e)}):(this.handleBrandVisualLoadedFailure(new Error("No brandvisual name provided.")),Promise.reject(new Error("No brandvisual name provided.")))}updated(e){super.updated(e),e.has("name")&&this.getBrandVisualData().catch(r=>{this.onerror&&this.onerror(r)})}handleBrandVisualLoadedSuccess(e){this.brandVisualData=e;let r=new Event("load",{bubbles:!0,cancelable:!0});this.dispatchEvent(r)}handleBrandVisualLoadedFailure(e){let r=new CustomEvent("error",{bubbles:!0,cancelable:!0,detail:{error:e}});this.dispatchEvent(r)}render(){return m` ${this.brandVisualData} `}};cr.styles=[...v.styles,...fn],n([L()],cr.prototype,"brandVisualData",2),n([c({type:String,reflect:!0})],cr.prototype,"name",2);var ji=cr;ji.register(bn);var wd=ji;var Nd=u`
|
944
944
|
:host {
|
945
945
|
--mdc-bullet-background-color: var(--mds-color-theme-outline-secondary-normal);
|
946
946
|
--mdc-bullet-size-small: 0.25rem;
|
@@ -961,7 +961,7 @@
|
|
961
961
|
:host([size="large"]) {
|
962
962
|
height: var(--mdc-bullet-size-large);
|
963
963
|
}
|
964
|
-
`,
|
964
|
+
`,vn=[Nd];var yn=f.constructTagName("bullet"),xn={SMALL:"small",MEDIUM:"medium",LARGE:"large"};var qr=class extends v{constructor(){super(...arguments);this.size=xn.SMALL}};qr.styles=[...v.styles,...vn],n([c({type:String,reflect:!0})],qr.prototype,"size",2);var Qi=qr;Qi.register(yn);var _d=Qi;var zo=i=>{class t extends i{constructor(){super(...arguments);this.variant=ae.VARIANT;this.color=ae.COLOR;this.typeInternal=ae.TYPE_INTERNAL}setVariant(o){this.setAttribute("variant",Object.values(ie).includes(o)?o:ae.VARIANT)}setColor(o){!Object.values(Tt).includes(o)||this.variant===ie.TERTIARY?this.setAttribute("color",`${ae.COLOR}`):this.setAttribute("color",o)}setSize(o){let s=this.typeInternal===sr.ICON?Object.values(ar).includes(o)&&!(o===ar[20]&&this.variant!==ie.TERTIARY):Object.values(Hr).includes(o);this.setAttribute("size",s?`${o}`:`${ae.SIZE}`)}inferButtonType(){var a,s;let o=(s=(a=this.shadowRoot)==null?void 0:a.querySelector("slot"))==null?void 0:s.assignedNodes().filter(l=>{var d;return l.nodeType!==Node.TEXT_NODE||((d=l.textContent)==null?void 0:d.trim())}).length;o&&(this.prefixIcon||this.postfixIcon)?(this.typeInternal=sr.PILL_WITH_ICON,this.setAttribute("data-btn-type","pill-with-icon")):!o&&(this.prefixIcon||this.postfixIcon)?(this.typeInternal=sr.ICON,this.setAttribute("data-btn-type","icon")):(this.typeInternal=sr.PILL,this.setAttribute("data-btn-type","pill"))}}return n([c({type:String,attribute:"prefix-icon",reflect:!0})],t.prototype,"prefixIcon",2),n([c({type:String,attribute:"postfix-icon",reflect:!0})],t.prototype,"postfixIcon",2),n([c({type:String})],t.prototype,"variant",2),n([c({type:String})],t.prototype,"color",2),n([L()],t.prototype,"typeInternal",2),t};var Ld=u`
|
965
965
|
:host {
|
966
966
|
background-color: transparent;
|
967
967
|
border-radius: 1.25rem;
|
@@ -1197,11 +1197,502 @@
|
|
1197
1197
|
--mdc-button-primary-disabled-background-color: var(--mds-color-theme-inverted-button-primary-disabled);
|
1198
1198
|
--mdc-button-primary-disabled-color: var(--mds-color-theme-inverted-text-primary-disabled);
|
1199
1199
|
}
|
1200
|
-
`,
|
1200
|
+
`,En=[Ld];var Kr=i=>{let t=i.split("-"),e=["bold","filled","regular","light"];return t.filter(r=>!e.includes(r)).join("-")};var He=class extends zo(re){constructor(){super(...arguments);this.size=ae.SIZE;this.inverted=ae.INVERTED;this.role="button"}update(e){super.update(e),e.has("active")&&this.inferFilledIconName(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.inferFilledIconName(this.active),this.inferButtonType())}inferFilledIconName(e){e?(this.prefixIcon&&(this.prefixFilledIconName=`${Kr(this.prefixIcon)}-filled`),this.postfixIcon&&(this.postfixFilledIconName=`${Kr(this.postfixIcon)}-filled`)):(this.prefixFilledIconName=this.prefixIcon,this.postfixFilledIconName=this.postfixIcon)}render(){return m`
|
1201
1201
|
${this.prefixFilledIconName?m` <mdc-icon name="${this.prefixFilledIconName}" part="prefix-icon"></mdc-icon>`:""}
|
1202
1202
|
<slot @slotchange=${this.inferButtonType}></slot>
|
1203
1203
|
${this.postfixFilledIconName?m` <mdc-icon name="${this.postfixFilledIconName}" part="postfix-icon"></mdc-icon>`:""}
|
1204
|
-
`}};
|
1204
|
+
`}};He.styles=[...re.styles,...En],n([c({type:Number})],He.prototype,"size",2),n([c({type:Boolean,reflect:!0})],He.prototype,"inverted",2),n([c({type:String,reflect:!0})],He.prototype,"role",2),n([L()],He.prototype,"prefixFilledIconName",2),n([L()],He.prototype,"postfixFilledIconName",2);var At=He;At.register(Et);var Rd=At;var Tn=f.constructTagName("linksimple"),Ji={INLINE:!1,INVERTED:!1};var Od=[N,u`
|
1205
|
+
:host {
|
1206
|
+
--mdc-link-border-radius: 0.25rem;
|
1207
|
+
--mdc-link-color-active: var(--mds-color-theme-text-accent-active);
|
1208
|
+
--mdc-link-color-disabled: var(--mds-color-theme-text-primary-disabled);
|
1209
|
+
--mdc-link-color-hover: var(--mds-color-theme-text-accent-hover);
|
1210
|
+
--mdc-link-color-normal: var(--mds-color-theme-text-accent-normal);
|
1211
|
+
--mdc-link-inverted-color-active: var(--mds-color-theme-inverted-text-accent-active);
|
1212
|
+
--mdc-link-inverted-color-disabled: var(--mds-color-theme-inverted-text-primary-disabled);
|
1213
|
+
--mdc-link-inverted-color-hover: var(--mds-color-theme-inverted-text-accent-hover);
|
1214
|
+
--mdc-link-inverted-color-normal: var(--mds-color-theme-inverted-text-accent-normal);
|
1215
|
+
|
1216
|
+
border-radius: var(--mdc-link-border-radius);
|
1217
|
+
color: var(--mdc-link-color-normal);
|
1218
|
+
text-underline-offset: auto;
|
1219
|
+
text-underline-position: from-font;
|
1220
|
+
cursor: pointer;
|
1221
|
+
|
1222
|
+
/* based on default linksimple size (large) */
|
1223
|
+
line-height: var(--mds-font-apps-body-large-regular-line-height);
|
1224
|
+
}
|
1225
|
+
|
1226
|
+
:host([inline]) {
|
1227
|
+
display: inline-flex;
|
1228
|
+
}
|
1229
|
+
|
1230
|
+
:host([inverted]) {
|
1231
|
+
color: var(--mdc-link-inverted-color-normal);
|
1232
|
+
}
|
1233
|
+
|
1234
|
+
:host(:hover) {
|
1235
|
+
color: var(--mdc-link-color-hover);
|
1236
|
+
}
|
1237
|
+
|
1238
|
+
:host(:active) {
|
1239
|
+
color: var(--mdc-link-color-active);
|
1240
|
+
box-shadow: none;
|
1241
|
+
}
|
1242
|
+
|
1243
|
+
:host([inverted]:hover) {
|
1244
|
+
color: var(--mdc-link-inverted-color-hover);
|
1245
|
+
}
|
1246
|
+
|
1247
|
+
:host([inverted]:active) {
|
1248
|
+
color: var(--mdc-link-inverted-color-active);
|
1249
|
+
}
|
1250
|
+
|
1251
|
+
:host([disabled]) {
|
1252
|
+
color: var(--mdc-link-color-disabled);
|
1253
|
+
pointer-events: none;
|
1254
|
+
}
|
1255
|
+
|
1256
|
+
:host([inverted][disabled]) {
|
1257
|
+
color: var(--mdc-link-inverted-color-disabled);
|
1258
|
+
}
|
1259
|
+
|
1260
|
+
/* based on default linksimple size (large) */
|
1261
|
+
:host(:hover),
|
1262
|
+
:host(:active),
|
1263
|
+
:host([inline]) {
|
1264
|
+
font-size: var(--mds-font-apps-body-large-regular-underline-font-size);
|
1265
|
+
font-weight: var(--mds-font-apps-body-large-regular-underline-font-weight);
|
1266
|
+
line-height: var(--mds-font-apps-body-large-regular-underline-line-height);
|
1267
|
+
text-decoration: var(--mds-font-apps-body-large-regular-underline-text-decoration);
|
1268
|
+
text-transform: var(--mds-font-apps-body-large-regular-underline-text-case);
|
1269
|
+
}
|
1270
|
+
|
1271
|
+
`,..._()],An=Od;var Ge=class extends P(_e(v)){constructor(){super(...arguments);this.inline=Ji.INLINE;this.inverted=Ji.INVERTED;this.href="#";this.target="_self";this.prevTabindex=0;this.handleNavigation=e=>{if((e.type==="click"||e instanceof KeyboardEvent&&e.key==="Enter")&&this.href){if(this.disabled)return;window.open(this.href,this.target,this.rel)}}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","link"),this.addEventListener("click",this.handleNavigation),this.addEventListener("keydown",this.handleNavigation)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this.handleNavigation),this.removeEventListener("keydown",this.handleNavigation)}setDisabled(e){e?(this.setAttribute("aria-disabled","true"),this.prevTabindex=this.tabIndex,this.tabIndex=-1):(this.tabIndex===-1&&(this.tabIndex=this.prevTabindex),this.removeAttribute("aria-disabled"))}update(e){super.update(e),e.has("disabled")&&this.setDisabled(this.disabled)}render(){return m`
|
1272
|
+
<slot></slot>
|
1273
|
+
`}};Ge.styles=[...v.styles,...An],n([c({type:Boolean,reflect:!0})],Ge.prototype,"inline",2),n([c({type:Boolean,reflect:!0})],Ge.prototype,"inverted",2),n([c({type:String,reflect:!0})],Ge.prototype,"href",2),n([c({type:String,reflect:!0})],Ge.prototype,"target",2),n([c({type:String,reflect:!0})],Ge.prototype,"rel",2);var st=Ge;var dr=class extends zo(st){constructor(){super(...arguments);this.size=ae.SIZE}setSoftDisabled(e,r){r?e.setAttribute("aria-disabled","true"):e.removeAttribute("aria-disabled")}update(e){super.update(e),e.has("softDisabled")&&this.setSoftDisabled(this,this.softDisabled),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()}render(){return m`
|
1274
|
+
${this.prefixIcon?m` <mdc-icon name="${this.prefixIcon}" part="prefix-icon"></mdc-icon>`:""}
|
1275
|
+
<slot @slotchange=${this.inferButtonType}></slot>
|
1276
|
+
${this.postfixIcon?m` <mdc-icon name="${this.postfixIcon}" part="postfix-icon"></mdc-icon>`:""}
|
1277
|
+
`}};dr.styles=[...At.styles],n([c({type:Number,reflect:!0})],dr.prototype,"size",2),n([c({type:Boolean,attribute:"soft-disabled",reflect:!0})],dr.prototype,"softDisabled",2);var ea=dr;var Sn=f.constructTagName("buttonlink");ea.register(Sn);var Md=ea;var Dd=u`
|
1278
|
+
:host {
|
1279
|
+
align-items: flex-start;
|
1280
|
+
border-radius: 0.5rem;
|
1281
|
+
border: 1px solid var(--mds-color-theme-outline-primary-normal);
|
1282
|
+
box-shadow: none;
|
1283
|
+
transition: box-shadow 0.2s;
|
1284
|
+
}
|
1285
|
+
:host([variant='ghost']){
|
1286
|
+
border-color: transparent;
|
1287
|
+
}
|
1288
|
+
:host([orientation="horizontal"]){
|
1289
|
+
width: 40rem;
|
1290
|
+
}
|
1291
|
+
|
1292
|
+
:host([orientation="vertical"]){
|
1293
|
+
width: 20rem;
|
1294
|
+
flex-direction: column;
|
1295
|
+
}
|
1296
|
+
|
1297
|
+
:host([orientation="vertical"])::part(image){
|
1298
|
+
height: 12.5rem;
|
1299
|
+
width: 100%;
|
1300
|
+
border-top-left-radius: 0.5rem;
|
1301
|
+
border-top-right-radius: 0.5rem;
|
1302
|
+
}
|
1303
|
+
|
1304
|
+
:host([orientation="horizontal"])::part(image){
|
1305
|
+
width: 10rem;
|
1306
|
+
height: 100%;
|
1307
|
+
border-top-left-radius: 0.5rem;
|
1308
|
+
border-bottom-left-radius: 0.5rem;
|
1309
|
+
}
|
1310
|
+
|
1311
|
+
:host::part(header){
|
1312
|
+
display: flex;
|
1313
|
+
gap: 0.5rem;
|
1314
|
+
}
|
1315
|
+
|
1316
|
+
:host::part(icon){
|
1317
|
+
margin-top: 0.25rem;
|
1318
|
+
}
|
1319
|
+
|
1320
|
+
:host::part(body){
|
1321
|
+
width: 100%;
|
1322
|
+
padding: 1.5rem;
|
1323
|
+
display: flex;
|
1324
|
+
flex-direction: column;
|
1325
|
+
}
|
1326
|
+
|
1327
|
+
::slotted([slot='body']){
|
1328
|
+
padding-bottom: 0.5rem;
|
1329
|
+
margin-top: 0.75rem;
|
1330
|
+
}
|
1331
|
+
|
1332
|
+
:host([variant='promotional']){
|
1333
|
+
border-color: var(--mds-color-theme-outline-promotion-normal);
|
1334
|
+
}
|
1335
|
+
|
1336
|
+
:host::part(icon-button), :host::part(footer) {
|
1337
|
+
margin-left: auto;
|
1338
|
+
display: flex;
|
1339
|
+
gap: 0.5rem;
|
1340
|
+
align-items: center;
|
1341
|
+
justify-content: center;
|
1342
|
+
}
|
1343
|
+
:host::part(footer){
|
1344
|
+
gap: 1rem;
|
1345
|
+
}
|
1346
|
+
::slotted([slot='footer-link']),
|
1347
|
+
::slotted([slot='footer-button-primary']),
|
1348
|
+
::slotted([slot='footer-button-secondary']){
|
1349
|
+
margin-bottom: 0.5rem;
|
1350
|
+
}
|
1351
|
+
|
1352
|
+
`,In=[N,Dd];var Po=f.constructTagName("link"),Vo={LARGE:"large",MIDSIZE:"midsize",SMALL:"small"},Uo={LARGE:1,MIDSIZE:.875,SMALL:.75},Cn={LINK_SIZE:Vo.LARGE};var kn=f.constructTagName("card"),ta={BORDER:"border",GHOST:"ghost",PROMOTIONAL:"promotional"},$d={HORIZONTAL:"horizontal",VERTICAL:"vertical"},q={VARIANT:ta.BORDER,ORIENTATION:$d.VERTICAL,TITLE_TYPE:S.HEADING_SMALL_BOLD,SUBTITLE_TYPE:S.BODY_MIDSIZE_MEDIUM,TAGNAME:w.SPAN,ICON_SIZE:1.5,ICON_LENGTH_UNIT:"rem",LINK:Po,BUTTON:Et};var Fo=i=>{class t extends i{constructor(){super(...arguments);this.cardTitle="";this.subtitle="";this.imageSrc="";this.imageAlt="";this.variant=q.VARIANT;this.orientation=q.ORIENTATION;this.titleTagName=q.TAGNAME;this.subtitleTagName=q.TAGNAME}renderImage(){return this.imageSrc?m`<img part="image" src="${this.imageSrc}" alt="${this.imageAlt}"/>`:g}renderIcon(){return this.iconName?m`<mdc-icon part="icon"
|
1353
|
+
size="${q.ICON_SIZE}"
|
1354
|
+
length-unit="${q.ICON_LENGTH_UNIT}"
|
1355
|
+
name="${this.iconName}"></mdc-icon>`:g}renderTitle(){return m`<div part="title-container">
|
1356
|
+
<mdc-text part="title" type="${q.TITLE_TYPE}" tagname="${this.titleTagName}">${this.cardTitle}</mdc-text>
|
1357
|
+
${this.subtitle?m`<mdc-text part="subtitle"
|
1358
|
+
type="${q.SUBTITLE_TYPE}"
|
1359
|
+
tagname="${this.subtitleTagName}">${this.subtitle}</mdc-text>`:g}
|
1360
|
+
</div>`}}return n([c({type:String,attribute:"card-title"})],t.prototype,"cardTitle",2),n([c({type:String})],t.prototype,"subtitle",2),n([c({type:String,attribute:"image-src"})],t.prototype,"imageSrc",2),n([c({type:String,attribute:"image-alt"})],t.prototype,"imageAlt",2),n([c({type:String})],t.prototype,"variant",2),n([c({type:String,reflect:!0})],t.prototype,"orientation",2),n([c({type:String,attribute:"title-tag-name"})],t.prototype,"titleTagName",2),n([c({type:String,attribute:"subtitle-tag-name"})],t.prototype,"subtitleTagName",2),n([c({type:String,attribute:"icon-name"})],t.prototype,"iconName",2),t};var nt=class extends Fo(v){constructor(){super(...arguments);this.handleIconButtons=()=>{var e;if((e=this.iconButtons)==null||e.forEach(r=>{!r.matches(q.BUTTON)&&r.getAttribute("data-btn-type")!=="icon"?r.remove():(r.setAttribute("variant",ie.TERTIARY),r.setAttribute("size","32"))}),this.iconButtons&&this.iconButtons.length>3)for(let r=3;r<this.iconButtons.length;r+=1)this.iconButtons[r].remove()};this.handleFooterSlot=(e,r="")=>{var a,s,l;let o=[];e===q.LINK&&((a=this.footerLink)!=null&&a.length)?o=this.footerLink:e===q.BUTTON&&r===ie.PRIMARY&&((s=this.footerButtonPrimary)!=null&&s.length)?o=this.footerButtonPrimary:e===q.BUTTON&&r===ie.SECONDARY&&((l=this.footerButtonSecondary)!=null&&l.length)&&(o=this.footerButtonSecondary);for(let d=1;d<o.length;d+=1)o[d].remove();o.forEach(d=>{d.matches(e)||d.remove(),r&&d.setAttribute("variant",r)})};this.updateFooterButtonColors=()=>{let e=[...this.footerButtonPrimary||[],...this.footerButtonSecondary||[]];e==null||e.forEach(r=>{this.variant===ta.PROMOTIONAL?r.setAttribute("color",Tt.PROMOTIONAL):r.setAttribute("color",Tt.DEFAULT)})}}update(e){super.update(e),e.has("variant")&&this.updateFooterButtonColors()}renderHeader(){return this.cardTitle?m`<div part="header">
|
1361
|
+
${this.renderIcon()}
|
1362
|
+
${this.renderTitle()}
|
1363
|
+
<div part="icon-button"><slot name="icon-button" @slotchange=${this.handleIconButtons}></slot></div>
|
1364
|
+
</div>`:g}render(){return m`
|
1365
|
+
${this.renderImage()}
|
1366
|
+
<div part="body">
|
1367
|
+
${this.renderHeader()}
|
1368
|
+
<slot name="before-body"></slot>
|
1369
|
+
<slot name="body"></slot>
|
1370
|
+
<slot name="after-body"></slot>
|
1371
|
+
<div part="footer">
|
1372
|
+
<slot name="footer-link" @slotchange=${()=>this.handleFooterSlot(q.LINK)}></slot>
|
1373
|
+
<slot name="footer-button-secondary"
|
1374
|
+
@slotchange=${()=>this.handleFooterSlot(q.BUTTON,ie.SECONDARY)}></slot>
|
1375
|
+
<slot name="footer-button-primary"
|
1376
|
+
@slotchange=${()=>this.handleFooterSlot(q.BUTTON,ie.PRIMARY)}></slot>
|
1377
|
+
</div>
|
1378
|
+
</div>
|
1379
|
+
`}};nt.styles=[...v.styles,...In],n([G({slot:"icon-button"})],nt.prototype,"iconButtons",2),n([G({slot:"footer-link"})],nt.prototype,"footerLink",2),n([G({slot:"footer-button-primary"})],nt.prototype,"footerButtonPrimary",2),n([G({slot:"footer-button-secondary"})],nt.prototype,"footerButtonSecondary",2);var Ee=nt;Ee.register(kn);var zd=Ee;var Pd=u`
|
1380
|
+
:host {
|
1381
|
+
cursor: pointer;
|
1382
|
+
user-select: none;
|
1383
|
+
}
|
1384
|
+
|
1385
|
+
:host(:hover) {
|
1386
|
+
background-color: var(--mds-color-theme-background-primary-hover);
|
1387
|
+
}
|
1388
|
+
|
1389
|
+
:host(:active) {
|
1390
|
+
background-color: var(--mds-color-theme-background-primary-active);
|
1391
|
+
}
|
1392
|
+
|
1393
|
+
:host([disabled]) {
|
1394
|
+
background-color: var(--mds-color-theme-background-primary-ghost);
|
1395
|
+
color: var(--mds-color-theme-text-primary-disabled);
|
1396
|
+
}
|
1397
|
+
|
1398
|
+
:host([disabled])::part(image){
|
1399
|
+
opacity: 0.5;
|
1400
|
+
}
|
1401
|
+
`,wn=[Pd,..._()];var Bo=class extends Fo(re){connectedCallback(){super.connectedCallback(),this.active=void 0,this.size=void 0}renderHeader(){return this.cardTitle?m`<div part="header">
|
1402
|
+
${this.renderIcon()}
|
1403
|
+
${this.renderTitle()}
|
1404
|
+
</div>`:g}render(){return m`
|
1405
|
+
${this.renderImage()}
|
1406
|
+
<div part="body">
|
1407
|
+
${this.renderHeader()}
|
1408
|
+
<slot name="before-body"></slot>
|
1409
|
+
<slot name="body"></slot>
|
1410
|
+
<slot name="after-body"></slot>
|
1411
|
+
</div>
|
1412
|
+
`}};Bo.styles=[...Ee.styles,...wn];var ra=Bo;var Nn=f.constructTagName("cardbutton");ra.register(Nn);var Vd=ra;var Ud=u`
|
1413
|
+
:host {
|
1414
|
+
cursor: pointer;
|
1415
|
+
user-select: none;
|
1416
|
+
}
|
1417
|
+
|
1418
|
+
:host::part(check){
|
1419
|
+
margin-left: auto;
|
1420
|
+
}
|
1421
|
+
|
1422
|
+
:host(:hover) {
|
1423
|
+
background-color: var(--mds-color-theme-background-primary-hover);
|
1424
|
+
}
|
1425
|
+
|
1426
|
+
:host(:active) {
|
1427
|
+
background-color: var(--mds-color-theme-background-primary-active);
|
1428
|
+
}
|
1429
|
+
|
1430
|
+
:host([checked]){
|
1431
|
+
border: 1px solid var(--mds-color-theme-outline-input-active);
|
1432
|
+
box-shadow: 0 0 0 1px var(--mds-color-theme-outline-input-active);
|
1433
|
+
background-color: var(--mds-color-theme-background-primary-active);
|
1434
|
+
}
|
1435
|
+
|
1436
|
+
:host([checked]:hover){
|
1437
|
+
background-color: var(--mds-color-theme-background-primary-hover);
|
1438
|
+
}
|
1439
|
+
|
1440
|
+
:host([checked]:active){
|
1441
|
+
background-color: var(--mds-color-theme-background-primary-ghost);
|
1442
|
+
}
|
1443
|
+
|
1444
|
+
:host::part(check-icon){
|
1445
|
+
color: var(--mds-color-theme-text-secondary-normal);
|
1446
|
+
}
|
1447
|
+
|
1448
|
+
:host([checked])::part(check-icon){
|
1449
|
+
color: var(--mds-color-theme-text-accent-normal);
|
1450
|
+
}
|
1451
|
+
|
1452
|
+
:host([disabled]) {
|
1453
|
+
background-color: var(--mds-color-theme-background-primary-ghost);
|
1454
|
+
color: var(--mds-color-theme-text-primary-disabled);
|
1455
|
+
border-color: var(--mds-color-theme-outline-primary-disabled);
|
1456
|
+
}
|
1457
|
+
|
1458
|
+
:host([disabled])::part(image){
|
1459
|
+
opacity: 0.5;
|
1460
|
+
}
|
1461
|
+
|
1462
|
+
:host([disabled])::part(check-icon){
|
1463
|
+
color: var(--mds-color-theme-text-primary-disabled);
|
1464
|
+
}
|
1465
|
+
`,_n=[Ud,..._()];var Ln=f.constructTagName("cardcheckbox"),oa={DEFAULT:"check-circle-bold",CHECKED:"check-circle-filled"},Ho={CHECK:"check",CHECKBOX:"checkbox"},Go={SELECTION_TYPE:Ho.CHECK,ICON_SIZE:1.5,ICON_LENGTH_UNIT:"rem"};var mr=class extends P(_e(Ee)){constructor(){super();this.checked=!1;this.selectionType=Go.SELECTION_TYPE;this.addEventListener("click",this.toggleChecked),this.addEventListener("keydown",this.toggleOnEnter),this.addEventListener("keyup",this.toggleOnSpace)}connectedCallback(){super.connectedCallback(),this.role="checkbox"}update(e){super.update(e),e.has("checked")&&this.setAttribute("aria-checked",`${this.checked}`),e.has("disabled")&&this.setAttribute("aria-disabled",`${this.disabled}`)}toggleChecked(){this.disabled||(this.checked=!this.checked)}toggleOnEnter(e){e.key==="Enter"&&this.toggleChecked()}toggleOnSpace(e){e.key===" "&&this.toggleChecked()}renderSelection(){let e=this.checked?oa.CHECKED:oa.DEFAULT;switch(this.selectionType){case Ho.CHECK:return m`<mdc-icon part="check check-icon"
|
1466
|
+
size="${Go.ICON_SIZE}"
|
1467
|
+
length-unit="${Go.ICON_LENGTH_UNIT}"
|
1468
|
+
name="${e}"></mdc-icon>`;case Ho.CHECKBOX:return m`<mdc-staticcheckbox part="check"
|
1469
|
+
?checked="${this.checked}"
|
1470
|
+
?disabled="${this.disabled}"></mdc-staticcheckbox>`;default:return g}}renderHeader(){return this.cardTitle?m`<div part="header">
|
1471
|
+
${this.renderIcon()}
|
1472
|
+
${this.renderTitle()}
|
1473
|
+
${this.renderSelection()}
|
1474
|
+
</div>`:g}render(){return m`
|
1475
|
+
${this.renderImage()}
|
1476
|
+
<div part="body">
|
1477
|
+
${this.renderHeader()}
|
1478
|
+
<slot name="before-body"></slot>
|
1479
|
+
<slot name="body"></slot>
|
1480
|
+
<slot name="after-body"></slot>
|
1481
|
+
</div>
|
1482
|
+
`}};mr.styles=[...Ee.styles,..._n],n([c({type:Boolean,reflect:!0})],mr.prototype,"checked",2),n([c({type:String,attribute:"selection-type"})],mr.prototype,"selectionType",2);var ia=mr;var Fd=[u`
|
1483
|
+
:host{
|
1484
|
+
margin: 0.125rem 0;
|
1485
|
+
border-radius: 0.125rem;
|
1486
|
+
--mdc-staticcheckbox-border-color: var(--mds-color-theme-outline-button-normal);
|
1487
|
+
--mdc-staticcheckbox-checked-background-color: var(--mds-color-theme-control-active-normal);
|
1488
|
+
--mdc-staticcheckbox-disabled-background-color: var(--mds-color-theme-control-inactive-disabled);
|
1489
|
+
--mdc-staticcheckbox-disabled-icon-color: var(--mds-color-theme-text-primary-disabled);
|
1490
|
+
--mdc-staticcheckbox-icon-background-color: var(--mds-color-theme-control-inactive-normal);
|
1491
|
+
--mdc-staticcheckbox-icon-border-color: var(--mds-color-theme-outline-input-normal);
|
1492
|
+
--mdc-staticcheckbox-icon-color: var(--mds-color-theme-inverted-text-primary-normal);
|
1493
|
+
--mdc-staticcheckbox-disabled-border-color: var(--mds-color-theme-outline-primary-disabled);
|
1494
|
+
--mdc-staticcheckbox-disabled-checked-icon-color: var(--mds-color-theme-control-active-disabled);
|
1495
|
+
}
|
1496
|
+
|
1497
|
+
:host([checked])::part(icon-container),
|
1498
|
+
:host([indeterminate])::part(icon-container) {
|
1499
|
+
background: var(--mdc-staticcheckbox-checked-background-color);
|
1500
|
+
border-color: transparent;
|
1501
|
+
}
|
1502
|
+
|
1503
|
+
:host([disabled])::part(icon-container) {
|
1504
|
+
border-color: var(--mdc-staticcheckbox-disabled-border-color);
|
1505
|
+
background: var(--mdc-staticcheckbox-disabled-background-color);
|
1506
|
+
}
|
1507
|
+
|
1508
|
+
:host([disabled][checked])::part(icon-container),
|
1509
|
+
:host([disabled][indeterminate])::part(icon-container) {
|
1510
|
+
background: var(--mdc-staticcheckbox-disabled-checked-icon-color);
|
1511
|
+
border: 0.0625rem solid var(--mdc-staticcheckbox-disabled-border-color);
|
1512
|
+
}
|
1513
|
+
|
1514
|
+
:host::part(icon-container) {
|
1515
|
+
display: flex;
|
1516
|
+
align-items: center;
|
1517
|
+
border: 0.0625rem solid var(--mdc-staticcheckbox-icon-border-color);
|
1518
|
+
background: var(--mdc-staticcheckbox-icon-background-color);
|
1519
|
+
width: 1rem;
|
1520
|
+
height: 1rem;
|
1521
|
+
border-radius: 0.125rem;
|
1522
|
+
}
|
1523
|
+
|
1524
|
+
.icon {
|
1525
|
+
--mdc-icon-fill-color: var(--mdc-staticcheckbox-icon-color);
|
1526
|
+
}
|
1527
|
+
|
1528
|
+
:host([disabled]) .icon {
|
1529
|
+
--mdc-icon-fill-color: var(--mdc-staticcheckbox-disabled-icon-color);
|
1530
|
+
}
|
1531
|
+
|
1532
|
+
/* High Contrast Mode */
|
1533
|
+
@media (forced-colors: active) {
|
1534
|
+
:host([checked])::part(icon-container)
|
1535
|
+
:host([indeterminate])::part(icon-container) {
|
1536
|
+
border: 0.0625rem solid var(--mdc-staticcheckbox-border-color);
|
1537
|
+
}
|
1538
|
+
}
|
1539
|
+
`],Rn=Fd;var On=f.constructTagName("checkbox"),Yo={CHECKED:"check-bold",INDETERMINATE:"minus-bold"};var Mn=f.constructTagName("staticcheckbox");var pr=class extends P(v){constructor(){super(...arguments);this.checked=!1;this.indeterminate=!1}render(){let e=this.checked||this.indeterminate?m`
|
1540
|
+
<mdc-icon
|
1541
|
+
class="icon"
|
1542
|
+
name="${this.indeterminate?Yo.INDETERMINATE:Yo.CHECKED}"
|
1543
|
+
size="1"
|
1544
|
+
length-unit="rem"
|
1545
|
+
></mdc-icon>
|
1546
|
+
`:g;return m`<slot></slot>
|
1547
|
+
<div part="icon-container">${e}</div>`}};pr.styles=[...v.styles,...Rn],n([c({type:Boolean,reflect:!0})],pr.prototype,"checked",2),n([c({type:Boolean,reflect:!0})],pr.prototype,"indeterminate",2);var aa=pr;aa.register(Mn);var Bd=aa;ia.register(Ln);var Hd=ia;var Gd=u`
|
1548
|
+
:host {
|
1549
|
+
cursor: pointer;
|
1550
|
+
user-select: none;
|
1551
|
+
}
|
1552
|
+
|
1553
|
+
:host::part(check){
|
1554
|
+
margin-left: auto;
|
1555
|
+
}
|
1556
|
+
|
1557
|
+
:host(:hover) {
|
1558
|
+
background-color: var(--mds-color-theme-background-primary-hover);
|
1559
|
+
}
|
1560
|
+
|
1561
|
+
:host(:active) {
|
1562
|
+
background-color: var(--mds-color-theme-background-primary-active);
|
1563
|
+
}
|
1564
|
+
|
1565
|
+
:host([checked]){
|
1566
|
+
border: 1px solid var(--mds-color-theme-outline-input-active);
|
1567
|
+
box-shadow: 0 0 0 1px var(--mds-color-theme-outline-input-active);
|
1568
|
+
background-color: var(--mds-color-theme-background-primary-active);
|
1569
|
+
}
|
1570
|
+
|
1571
|
+
:host([checked]:hover){
|
1572
|
+
background-color: var(--mds-color-theme-background-primary-hover);
|
1573
|
+
}
|
1574
|
+
|
1575
|
+
:host([checked]:active){
|
1576
|
+
background-color: var(--mds-color-theme-background-primary-ghost);
|
1577
|
+
}
|
1578
|
+
|
1579
|
+
:host::part(check-icon){
|
1580
|
+
color: var(--mds-color-theme-text-secondary-normal);
|
1581
|
+
}
|
1582
|
+
|
1583
|
+
:host([checked])::part(check-icon){
|
1584
|
+
color: var(--mds-color-theme-text-accent-normal);
|
1585
|
+
}
|
1586
|
+
|
1587
|
+
:host([disabled]) {
|
1588
|
+
background-color: var(--mds-color-theme-background-primary-ghost);
|
1589
|
+
color: var(--mds-color-theme-text-primary-disabled);
|
1590
|
+
border-color: var(--mds-color-theme-outline-primary-disabled);
|
1591
|
+
}
|
1592
|
+
|
1593
|
+
:host([disabled])::part(image){
|
1594
|
+
opacity: 0.5;
|
1595
|
+
}
|
1596
|
+
`,Dn=[Gd,..._()];var hr=class extends P(_e(Ee)){constructor(){super();this.checked=!1;this.name="";this.addEventListener("click",this.toggleChecked),this.addEventListener("keydown",this.toggleOnEnter),this.addEventListener("keyup",this.toggleOnSpace)}connectedCallback(){super.connectedCallback(),this.role="radio"}getAllCardsWithinSameGroup(){return Array.from(document.querySelectorAll(`mdc-cardradio[name="${this.name}"]`))}toggleChecked(){if(this.disabled)return;this.getAllCardsWithinSameGroup().forEach(r=>{r.checked=!1}),this.checked=!0}update(e){super.update(e),e.has("checked")&&this.setAttribute("aria-checked",`${this.checked}`),e.has("disabled")&&this.setAttribute("aria-disabled",`${this.disabled}`)}toggleOnEnter(e){e.key==="Enter"&&this.toggleChecked()}toggleOnSpace(e){e.key===" "&&this.toggleChecked()}renderHeader(){return this.cardTitle?m`<div part="header">
|
1597
|
+
${this.renderIcon()}
|
1598
|
+
${this.renderTitle()}
|
1599
|
+
<mdc-staticradio part="check"
|
1600
|
+
?checked="${this.checked}"
|
1601
|
+
?disabled="${this.disabled}"></mdc-staticradio>
|
1602
|
+
</div>`:g}render(){return m`
|
1603
|
+
${this.renderImage()}
|
1604
|
+
<div part="body">
|
1605
|
+
${this.renderHeader()}
|
1606
|
+
<slot name="before-body"></slot>
|
1607
|
+
<slot name="body"></slot>
|
1608
|
+
<slot name="after-body"></slot>
|
1609
|
+
</div>
|
1610
|
+
`}};hr.styles=[...Ee.styles,...Dn],n([c({type:Boolean,reflect:!0})],hr.prototype,"checked",2),n([c({type:String})],hr.prototype,"name",2);var sa=hr;var Wo=f.constructTagName("cardradio");var Yd=[u`
|
1611
|
+
:host{
|
1612
|
+
display: block;
|
1613
|
+
position: relative;
|
1614
|
+
width: 1rem;
|
1615
|
+
height: 1rem;
|
1616
|
+
margin: 0.125rem 0;
|
1617
|
+
border-radius: 50%;
|
1618
|
+
|
1619
|
+
--mdc-staticradio-inner-circle-size: 0.375rem;
|
1620
|
+
--mdc-staticradio-text-disabled-color: var(--mds-color-theme-text-primary-disabled);
|
1621
|
+
--mdc-staticradio-disabled-border-color: var(--mds-color-theme-outline-primary-disabled);
|
1622
|
+
--mdc-staticradio-normal-border-color: var(--mds-color-theme-outline-input-normal);
|
1623
|
+
--mdc-staticradio-inner-circle-normal-background: var(--mds-color-theme-inverted-text-primary-normal);
|
1624
|
+
--mdc-staticradio-inner-circle-disabled-background: var(--mds-color-theme-inverted-text-primary-disabled);
|
1625
|
+
--mdc-staticradio-control-inactive-color: var(--mds-color-theme-control-inactive-normal);
|
1626
|
+
--mdc-staticradio-control-inactive-disabled-background: var(--mds-color-theme-control-inactive-disabled);
|
1627
|
+
--mdc-staticradio-control-active-color: var(--mds-color-theme-control-active-normal);
|
1628
|
+
--mdc-staticradio-control-active-disabled-background: var(--mds-color-theme-control-active-disabled);
|
1629
|
+
}
|
1630
|
+
|
1631
|
+
.icon:after {
|
1632
|
+
content: "";
|
1633
|
+
position: absolute;
|
1634
|
+
display: none;
|
1635
|
+
}
|
1636
|
+
|
1637
|
+
:host([disabled]) .icon,
|
1638
|
+
:host([disabled][readonly]) .icon {
|
1639
|
+
border-color: var(--mdc-staticradio-disabled-border-color);
|
1640
|
+
background: var(--mdc-staticradio-control-inactive-disabled-background);
|
1641
|
+
}
|
1642
|
+
|
1643
|
+
:host([disabled][checked]) .icon,
|
1644
|
+
:host([disabled][readonly][checked]) .icon {
|
1645
|
+
border: var(--mdc-staticradio-control-active-disabled-background);
|
1646
|
+
background: var(--mdc-staticradio-control-active-disabled-background);
|
1647
|
+
}
|
1648
|
+
|
1649
|
+
:host([disabled][checked]) .icon:after,
|
1650
|
+
:host([disabled][readonly][checked]) .icon:after {
|
1651
|
+
background: var(--mdc-staticradio-inner-circle-disabled-background);
|
1652
|
+
}
|
1653
|
+
|
1654
|
+
.icon {
|
1655
|
+
position: absolute;
|
1656
|
+
top: 0;
|
1657
|
+
left: 0;
|
1658
|
+
width: 1rem;
|
1659
|
+
height: 1rem;
|
1660
|
+
border: 0.0625rem solid var(--mdc-staticradio-normal-border-color);
|
1661
|
+
background-color: var(--mdc-staticradio-control-inactive-color);
|
1662
|
+
border-radius: 50%;
|
1663
|
+
}
|
1664
|
+
|
1665
|
+
:host([checked]) .icon {
|
1666
|
+
border-color: var(--mdc-staticradio-control-active-color);
|
1667
|
+
background-color: var(--mdc-staticradio-control-active-color);
|
1668
|
+
}
|
1669
|
+
|
1670
|
+
:host([checked]) .icon:after {
|
1671
|
+
display: block;
|
1672
|
+
top: 50%;
|
1673
|
+
left: 50%;
|
1674
|
+
transform: translate(-50%, -50%);
|
1675
|
+
width: var(--mdc-staticradio-inner-circle-size);
|
1676
|
+
height: var(--mdc-staticradio-inner-circle-size);
|
1677
|
+
border-radius: 50%;
|
1678
|
+
background: var(--mdc-staticradio-inner-circle-normal-background);
|
1679
|
+
}
|
1680
|
+
|
1681
|
+
:host([readonly]) .icon{
|
1682
|
+
border-color: var(--mdc-staticradio-normal-border-color);
|
1683
|
+
background-color: var(--mdc-staticradio-control-inactive-color);
|
1684
|
+
}
|
1685
|
+
|
1686
|
+
:host([readonly][checked]) .icon {
|
1687
|
+
border-color: var(--mdc-staticradio-normal-border-color);
|
1688
|
+
}
|
1689
|
+
|
1690
|
+
:host([readonly][checked]) .icon:after{
|
1691
|
+
background-color: var(--mdc-staticradio-text-disabled-color);
|
1692
|
+
}
|
1693
|
+
`],$n=Yd;var ur=class extends P(v){constructor(){super(...arguments);this.checked=!1;this.readonly=!1}render(){return m`
|
1694
|
+
<slot></slot>
|
1695
|
+
<span part="radio-icon" class="icon"></span>`}};ur.styles=[...v.styles,...$n],n([c({type:Boolean,reflect:!0})],ur.prototype,"checked",2),n([c({type:Boolean,reflect:!0})],ur.prototype,"readonly",2);var na=ur;var zn=f.constructTagName("staticradio");na.register(zn);var Wd=na;sa.register(Wo);var qd=sa;var U=i=>{class t extends i{constructor(){super(...arguments);this.dataAriaLabel=null}}return n([c({type:String,reflect:!0,attribute:"data-aria-label"})],t.prototype,"dataAriaLabel",2),t};var K=[];for(let i=0;i<256;++i)K.push((i+256).toString(16).slice(1));function Pn(i,t=0){return(K[i[t+0]]+K[i[t+1]]+K[i[t+2]]+K[i[t+3]]+"-"+K[i[t+4]]+K[i[t+5]]+"-"+K[i[t+6]]+K[i[t+7]]+"-"+K[i[t+8]]+K[i[t+9]]+"-"+K[i[t+10]]+K[i[t+11]]+K[i[t+12]]+K[i[t+13]]+K[i[t+14]]+K[i[t+15]]).toLowerCase()}var la,Kd=new Uint8Array(16);function ca(){if(!la){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");la=crypto.getRandomValues.bind(crypto)}return la(Kd)}var Zd=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),da={randomUUID:Zd};function Xd(i,t,e){var o,a,s;if(da.randomUUID&&!t&&!i)return da.randomUUID();i=i||{};let r=(s=(a=i.random)!=null?a:(o=i.rng)==null?void 0:o.call(i))!=null?s:ca();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 l=0;l<16;++l)t[e+l]=r[l];return t}return Pn(r)}var Ye=Xd;var se=i=>{class t extends i{constructor(){super(...arguments);this.name="";this.value="";this.internals=this.attachInternals()}get form(){return this.internals.form}get validity(){return this.internals.validity}get willValidate(){return this.internals.willValidate}connectedCallback(){super.connectedCallback(),this.id=`mdc-input-${Ye()}`}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,n([c({reflect:!0,type:String})],t.prototype,"name",2),n([c({reflect:!0,type:String})],t.prototype,"value",2),n([c({reflect:!0,type:String,attribute:"validation-message"})],t.prototype,"validationMessage",2),n([Ue("input")],t.prototype,"inputElement",2),t};var Vn=f.constructTagName("formfieldwrapper"),W={DEFAULT:"default",ERROR:"error",PRIORITY:"priority",SUCCESS:"success",WARNING:"warning"},V={VALIDATION:W.DEFAULT,HELPER_TEXT_ID:"helper-text-id",HEADING_ID:"heading-id"},St={TAGNAME:w.SPAN,TYPE:S.BODY_MIDSIZE_REGULAR,HEADER_TYPE:S.BODY_MIDSIZE_BOLD};var jd=[N,u`
|
1205
1696
|
:host {
|
1206
1697
|
flex-direction: column;
|
1207
1698
|
align-items: flex-start;
|
@@ -1254,22 +1745,22 @@
|
|
1254
1745
|
:host([help-text-type='priority']) .mdc-help-text {
|
1255
1746
|
color: var(--mds-color-theme-text-accent-normal);
|
1256
1747
|
}
|
1257
|
-
`],
|
1748
|
+
`],Un=jd;var Fn=i=>({[W.ERROR]:"error-legacy-badge-filled",[W.WARNING]:"warning-badge-filled",[W.SUCCESS]:"check-circle-badge-filled",[W.PRIORITY]:"priority-badge-filled",[W.DEFAULT]:""})[i]||"";var We=class extends P(v){constructor(){super(...arguments);this.id="";this.helpTextType=V.VALIDATION;this.shouldRenderLabel=!0}renderLabelElement(){return this.label?this.shouldRenderLabel?m`<label for="${this.id}" id="${V.HEADING_ID}" class="mdc-label" part="label">${this.label}</label>`:m` <mdc-text
|
1258
1749
|
id="${V.HEADING_ID}"
|
1259
|
-
tagname="${
|
1260
|
-
type="${
|
1750
|
+
tagname="${St.TAGNAME}"
|
1751
|
+
type="${St.HEADER_TYPE}"
|
1261
1752
|
part="label"
|
1262
1753
|
>${this.label}</mdc-text
|
1263
1754
|
>`:g}renderRequiredLabel(){return this.requiredLabel?m`
|
1264
|
-
<mdc-text part="required-label" tagname=${
|
1755
|
+
<mdc-text part="required-label" tagname=${St.TAGNAME} type=${St.TYPE}>
|
1265
1756
|
(${this.requiredLabel})
|
1266
1757
|
</mdc-text>
|
1267
|
-
`:g}renderHelpTextIcon(){if(!this.helpText)return g;let e=
|
1758
|
+
`:g}renderHelpTextIcon(){if(!this.helpText)return g;let e=Fn(this.helpTextType||V.VALIDATION);return e&&!this.disabled?m`<mdc-icon part="helper-icon" size="1" length-unit="rem" name=${e}></mdc-icon>`:g}renderHelpText(){return this.helpText?m`
|
1268
1759
|
<mdc-text
|
1269
1760
|
id="${V.HELPER_TEXT_ID}"
|
1270
1761
|
part="help-text"
|
1271
|
-
tagname=${
|
1272
|
-
type=${
|
1762
|
+
tagname=${St.TAGNAME}
|
1763
|
+
type=${St.TYPE}
|
1273
1764
|
>
|
1274
1765
|
${this.helpText}
|
1275
1766
|
</mdc-text>
|
@@ -1280,7 +1771,7 @@
|
|
1280
1771
|
</div>`:g}renderHelperText(){return this.helpText?m`<div class="mdc-help-text" part="mdc-help-text">
|
1281
1772
|
<slot name="help-icon">${this.renderHelpTextIcon()}</slot>
|
1282
1773
|
<slot name="help-text">${this.renderHelpText()}</slot>
|
1283
|
-
</div>`:g}};
|
1774
|
+
</div>`:g}};We.styles=[...v.styles,...Un],n([c({reflect:!0,type:String})],We.prototype,"label",2),n([c({type:String,reflect:!0,attribute:"required-label"})],We.prototype,"requiredLabel",2),n([c({type:String})],We.prototype,"id",2),n([c({reflect:!0,attribute:"help-text-type"})],We.prototype,"helpTextType",2),n([c({type:String,reflect:!0,attribute:"help-text"})],We.prototype,"helpText",2);var J=We;var Qd=[u`
|
1284
1775
|
:host {
|
1285
1776
|
--mdc-checkbox-background-color-hover: var(--mds-color-theme-control-inactive-hover);
|
1286
1777
|
--mdc-checkbox-pressed-icon-color: var(--mds-color-theme-control-inactive-pressed);
|
@@ -1347,7 +1838,7 @@
|
|
1347
1838
|
}
|
1348
1839
|
|
1349
1840
|
|
1350
|
-
`,...
|
1841
|
+
`,..._(!0)],Bn=Qd;var It=class extends se(U(J)){constructor(){super(...arguments);this.checked=!1;this.indeterminate=!1;this.autofocus=!1;this.renderLabelAndHelperText=()=>this.label?m`<div class="text-container">
|
1351
1842
|
${this.renderLabel()}
|
1352
1843
|
${this.renderHelperText()}
|
1353
1844
|
</div>`:g}connectedCallback(){super.connectedCallback(),this.helpTextType=void 0}setFormValue(){let e=null;this.checked?e=this.value?this.value:"on":e=null,this.manageRequired(),this.internals.setFormValue(e)}manageRequired(){!this.checked&&this.requiredLabel?(this.validationMessage?this.inputElement.setCustomValidity(this.validationMessage):this.inputElement.setCustomValidity(""),this.setValidity()):this.internals.setValidity({})}formResetCallback(){this.checked=!1,this.indeterminate=!1}formStateRestoreCallback(e){e&&(this.checked=!0)}toggleState(){this.disabled||(this.checked=!this.checked,this.indeterminate=!1)}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))}update(e){super.update(e),e.has("checked")&&this.setFormValue()}render(){var e;return m`
|
@@ -1376,72 +1867,7 @@
|
|
1376
1867
|
/>
|
1377
1868
|
</mdc-staticcheckbox>
|
1378
1869
|
${this.renderLabelAndHelperText()}
|
1379
|
-
`}};
|
1380
|
-
:host{
|
1381
|
-
margin: 0.125rem 0;
|
1382
|
-
border-radius: 0.125rem;
|
1383
|
-
--mdc-staticcheckbox-border-color: var(--mds-color-theme-outline-button-normal);
|
1384
|
-
--mdc-staticcheckbox-checked-background-color: var(--mds-color-theme-control-active-normal);
|
1385
|
-
--mdc-staticcheckbox-disabled-background-color: var(--mds-color-theme-control-inactive-disabled);
|
1386
|
-
--mdc-staticcheckbox-disabled-icon-color: var(--mds-color-theme-text-primary-disabled);
|
1387
|
-
--mdc-staticcheckbox-icon-background-color: var(--mds-color-theme-control-inactive-normal);
|
1388
|
-
--mdc-staticcheckbox-icon-border-color: var(--mds-color-theme-outline-input-normal);
|
1389
|
-
--mdc-staticcheckbox-icon-color: var(--mds-color-theme-inverted-text-primary-normal);
|
1390
|
-
--mdc-staticcheckbox-disabled-border-color: var(--mds-color-theme-outline-primary-disabled);
|
1391
|
-
--mdc-staticcheckbox-disabled-checked-icon-color: var(--mds-color-theme-control-active-disabled);
|
1392
|
-
}
|
1393
|
-
|
1394
|
-
:host([checked])::part(icon-container),
|
1395
|
-
:host([indeterminate])::part(icon-container) {
|
1396
|
-
background: var(--mdc-staticcheckbox-checked-background-color);
|
1397
|
-
border-color: transparent;
|
1398
|
-
}
|
1399
|
-
|
1400
|
-
:host([disabled])::part(icon-container) {
|
1401
|
-
border-color: var(--mdc-staticcheckbox-disabled-border-color);
|
1402
|
-
background: var(--mdc-staticcheckbox-disabled-background-color);
|
1403
|
-
}
|
1404
|
-
|
1405
|
-
:host([disabled][checked])::part(icon-container),
|
1406
|
-
:host([disabled][indeterminate])::part(icon-container) {
|
1407
|
-
background: var(--mdc-staticcheckbox-disabled-checked-icon-color);
|
1408
|
-
border: 0.0625rem solid var(--mdc-staticcheckbox-disabled-border-color);
|
1409
|
-
}
|
1410
|
-
|
1411
|
-
:host::part(icon-container) {
|
1412
|
-
display: flex;
|
1413
|
-
align-items: center;
|
1414
|
-
border: 0.0625rem solid var(--mdc-staticcheckbox-icon-border-color);
|
1415
|
-
background: var(--mdc-staticcheckbox-icon-background-color);
|
1416
|
-
width: 1rem;
|
1417
|
-
height: 1rem;
|
1418
|
-
border-radius: 0.125rem;
|
1419
|
-
}
|
1420
|
-
|
1421
|
-
.icon {
|
1422
|
-
--mdc-icon-fill-color: var(--mdc-staticcheckbox-icon-color);
|
1423
|
-
}
|
1424
|
-
|
1425
|
-
:host([disabled]) .icon {
|
1426
|
-
--mdc-icon-fill-color: var(--mdc-staticcheckbox-disabled-icon-color);
|
1427
|
-
}
|
1428
|
-
|
1429
|
-
/* High Contrast Mode */
|
1430
|
-
@media (forced-colors: active) {
|
1431
|
-
:host([checked])::part(icon-container)
|
1432
|
-
:host([indeterminate])::part(icon-container) {
|
1433
|
-
border: 0.0625rem solid var(--mdc-staticcheckbox-border-color);
|
1434
|
-
}
|
1435
|
-
}
|
1436
|
-
`],dn=hd;var mn=f.constructTagName("staticcheckbox");var ir=class extends H(v){constructor(){super(...arguments);this.checked=!1;this.indeterminate=!1}render(){let e=this.checked||this.indeterminate?m`
|
1437
|
-
<mdc-icon
|
1438
|
-
class="icon"
|
1439
|
-
name="${this.indeterminate?Ro.INDETERMINATE:Ro.CHECKED}"
|
1440
|
-
size="1"
|
1441
|
-
length-unit="rem"
|
1442
|
-
></mdc-icon>
|
1443
|
-
`:g;return m`<slot></slot>
|
1444
|
-
<div part="icon-container">${e}</div>`}};ir.styles=[...v.styles,...dn],n([c({type:Boolean,reflect:!0})],ir.prototype,"checked",2),n([c({type:Boolean,reflect:!0})],ir.prototype,"indeterminate",2);var Gi=ir;Gi.register(mn);var ud=Gi;Hi.register(cn);var fd=Hi;var bd=u`
|
1870
|
+
`}};It.styles=[...J.styles,...Bn],n([c({type:Boolean,reflect:!0})],It.prototype,"checked",2),n([c({type:Boolean,reflect:!0})],It.prototype,"indeterminate",2),n([c({type:Boolean,reflect:!0})],It.prototype,"autofocus",2);var ma=It;ma.register(On);var Jd=ma;var em=u`
|
1445
1871
|
:host {
|
1446
1872
|
height: 1.5rem;
|
1447
1873
|
gap: 0.25rem;
|
@@ -1578,15 +2004,15 @@
|
|
1578
2004
|
--mdc-chip-color: var(--mds-color-theme-text-primary-disabled);
|
1579
2005
|
cursor: auto;
|
1580
2006
|
}
|
1581
|
-
`,
|
2007
|
+
`,Hn=[N,em,..._()];var Gn=f.constructTagName("chip"),tm={DEFAULT:"default",COBALT:"cobalt",GOLD:"gold",LIME:"lime",MINT:"mint",PINK:"pink",PURPLE:"purple",SLATE:"slate",VIOLET:"violet"},fr={COLOR:tm.DEFAULT,TEXT_TYPE:S.BODY_MIDSIZE_REGULAR,TAG_NAME:w.SPAN,SIZE:zr[24],ROLE:"button"};var br=class extends oe(re){constructor(){super(...arguments);this.color=fr.COLOR;this.label=""}connectedCallback(){super.connectedCallback(),this.role=fr.ROLE,this.size=fr.SIZE,this.active=void 0,this.softDisabled=void 0}renderIcon(){return this.iconName?m`
|
1582
2008
|
<mdc-icon
|
1583
2009
|
name="${this.iconName}"
|
1584
2010
|
length-unit="rem"
|
1585
2011
|
size="1"></mdc-icon>
|
1586
2012
|
`:g}render(){return m`
|
1587
2013
|
${this.renderIcon()}
|
1588
|
-
<mdc-text type="${
|
1589
|
-
`}};sr.styles=[...v.styles,...pn],n([c({type:String,reflect:!0})],sr.prototype,"color",2),n([c({type:String})],sr.prototype,"label",2);var nr=sr;nr.register(hn);var gd=nr;var Ne=Math.min,Q=Math.max,Gr=Math.round,Wr=Math.floor,ye=i=>({x:i,y:i}),yd={left:"right",right:"left",bottom:"top",top:"bottom"},xd={start:"end",end:"start"};function Mo(i,t,e){return Q(i,Ne(t,e))}function yt(i,t){return typeof i=="function"?i(t):i}function Be(i){return i.split("-")[0]}function xt(i){return i.split("-")[1]}function Wi(i){return i==="x"?"y":"x"}function Do(i){return i==="y"?"height":"width"}function rt(i){return["top","bottom"].includes(Be(i))?"y":"x"}function $o(i){return Wi(rt(i))}function un(i,t,e){e===void 0&&(e=!1);let r=xt(i),o=$o(i),a=Do(o),s=o==="x"?r===(e?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(s=Hr(s)),[s,Hr(s)]}function fn(i){let t=Hr(i);return[Oo(i),t,Oo(t)]}function Oo(i){return i.replace(/start|end/g,t=>xd[t])}function Ed(i,t,e){let r=["left","right"],o=["right","left"],a=["top","bottom"],s=["bottom","top"];switch(i){case"top":case"bottom":return e?t?o:r:t?r:o;case"left":case"right":return t?a:s;default:return[]}}function bn(i,t,e,r){let o=xt(i),a=Ed(Be(i),e==="start",r);return o&&(a=a.map(s=>s+"-"+o),t&&(a=a.concat(a.map(Oo)))),a}function Hr(i){return i.replace(/left|right|bottom|top/g,t=>yd[t])}function Td(i){return{top:0,right:0,bottom:0,left:0,...i}}function Yi(i){return typeof i!="number"?Td(i):{top:i,right:i,bottom:i,left:i}}function Et(i){let{x:t,y:e,width:r,height:o}=i;return{width:r,height:o,top:e,left:t,right:t+r,bottom:e+o,x:t,y:e}}function vn(i,t,e){let{reference:r,floating:o}=i,a=rt(t),s=$o(t),l=Do(s),d=Be(t),p=a==="y",h=r.x+r.width/2-o.width/2,b=r.y+r.height/2-o.height/2,x=r[l]/2-o[l]/2,y;switch(d){case"top":y={x:h,y:r.y-o.height};break;case"bottom":y={x:h,y:r.y+r.height};break;case"right":y={x:r.x+r.width,y:b};break;case"left":y={x:r.x-o.width,y:b};break;default:y={x:r.x,y:r.y}}switch(xt(t)){case"start":y[s]-=x*(e&&p?-1:1);break;case"end":y[s]+=x*(e&&p?-1:1);break}return y}var gn=async(i,t,e)=>{let{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:s}=e,l=a.filter(Boolean),d=await(s.isRTL==null?void 0:s.isRTL(t)),p=await s.getElementRects({reference:i,floating:t,strategy:o}),{x:h,y:b}=vn(p,r,d),x=r,y={},E=0;for(let A=0;A<l.length;A++){let{name:w,fn:S}=l[A],{x:C,y:R,data:B,reset:z}=await S({x:h,y:b,initialPlacement:r,placement:x,strategy:o,middlewareData:y,rects:p,platform:s,elements:{reference:i,floating:t}});h=C!=null?C:h,b=R!=null?R:b,y={...y,[w]:{...y[w],...B}},z&&E<=50&&(E++,typeof z=="object"&&(z.placement&&(x=z.placement),z.rects&&(p=z.rects===!0?await s.getElementRects({reference:i,floating:t,strategy:o}):z.rects),{x:h,y:b}=vn(p,x,d)),A=-1)}return{x:h,y:b,placement:x,strategy:o,middlewareData:y}};async function zo(i,t){var e;t===void 0&&(t={});let{x:r,y:o,platform:a,rects:s,elements:l,strategy:d}=i,{boundary:p="clippingAncestors",rootBoundary:h="viewport",elementContext:b="floating",altBoundary:x=!1,padding:y=0}=yt(t,i),E=Yi(y),w=l[x?b==="floating"?"reference":"floating":b],S=Et(await a.getClippingRect({element:(e=await(a.isElement==null?void 0:a.isElement(w)))==null||e?w:w.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(l.floating)),boundary:p,rootBoundary:h,strategy:d})),C=b==="floating"?{x:r,y:o,width:s.floating.width,height:s.floating.height}:s.reference,R=await(a.getOffsetParent==null?void 0:a.getOffsetParent(l.floating)),B=await(a.isElement==null?void 0:a.isElement(R))?await(a.getScale==null?void 0:a.getScale(R))||{x:1,y:1}:{x:1,y:1},z=Et(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:C,offsetParent:R,strategy:d}):C);return{top:(S.top-z.top+E.top)/B.y,bottom:(z.bottom-S.bottom+E.bottom)/B.y,left:(S.left-z.left+E.left)/B.x,right:(z.right-S.right+E.right)/B.x}}var yn=i=>({name:"arrow",options:i,async fn(t){let{x:e,y:r,placement:o,rects:a,platform:s,elements:l,middlewareData:d}=t,{element:p,padding:h=0}=yt(i,t)||{};if(p==null)return{};let b=Yi(h),x={x:e,y:r},y=$o(o),E=Do(y),A=await s.getDimensions(p),w=y==="y",S=w?"top":"left",C=w?"bottom":"right",R=w?"clientHeight":"clientWidth",B=a.reference[E]+a.reference[y]-x[y]-a.floating[E],z=x[y]-a.reference[y],de=await(s.getOffsetParent==null?void 0:s.getOffsetParent(p)),be=de?de[R]:0;(!be||!await(s.isElement==null?void 0:s.isElement(de)))&&(be=l.floating[R]||a.floating[E]);let _e=B/2-z/2,Se=be/2-A[E]/2-1,ve=Ne(b[S],Se),qe=Ne(b[C],Se),Ie=ve,Ze=be-A[E]-qe,X=be/2-A[E]/2+_e,Ft=Mo(Ie,X,Ze),Le=!d.arrow&&xt(o)!=null&&X!==Ft&&a.reference[E]/2-(X<Ie?ve:qe)-A[E]/2<0,we=Le?X<Ie?X-Ie:X-Ze:0;return{[y]:x[y]+we,data:{[y]:Ft,centerOffset:X-Ft-we,...Le&&{alignmentOffset:we}},reset:Le}}});var xn=function(i){return i===void 0&&(i={}),{name:"flip",options:i,async fn(t){var e,r;let{placement:o,middlewareData:a,rects:s,initialPlacement:l,platform:d,elements:p}=t,{mainAxis:h=!0,crossAxis:b=!0,fallbackPlacements:x,fallbackStrategy:y="bestFit",fallbackAxisSideDirection:E="none",flipAlignment:A=!0,...w}=yt(i,t);if((e=a.arrow)!=null&&e.alignmentOffset)return{};let S=Be(o),C=rt(l),R=Be(l)===l,B=await(d.isRTL==null?void 0:d.isRTL(p.floating)),z=x||(R||!A?[Hr(l)]:fn(l)),de=E!=="none";!x&&de&&z.push(...bn(l,A,E,B));let be=[l,...z],_e=await zo(t,w),Se=[],ve=((r=a.flip)==null?void 0:r.overflows)||[];if(h&&Se.push(_e[S]),b){let X=un(o,s,B);Se.push(_e[X[0]],_e[X[1]])}if(ve=[...ve,{placement:o,overflows:Se}],!Se.every(X=>X<=0)){var qe,Ie;let X=(((qe=a.flip)==null?void 0:qe.index)||0)+1,Ft=be[X];if(Ft)return{data:{index:X,overflows:ve},reset:{placement:Ft}};let Le=(Ie=ve.filter(we=>we.overflows[0]<=0).sort((we,Xe)=>we.overflows[1]-Xe.overflows[1])[0])==null?void 0:Ie.placement;if(!Le)switch(y){case"bestFit":{var Ze;let we=(Ze=ve.filter(Xe=>{if(de){let Ke=rt(Xe.placement);return Ke===C||Ke==="y"}return!0}).map(Xe=>[Xe.placement,Xe.overflows.filter(Ke=>Ke>0).reduce((Ke,gc)=>Ke+gc,0)]).sort((Xe,Ke)=>Xe[1]-Ke[1])[0])==null?void 0:Ze[0];we&&(Le=we);break}case"initialPlacement":Le=l;break}if(o!==Le)return{reset:{placement:Le}}}return{}}}};async function Ad(i,t){let{placement:e,platform:r,elements:o}=i,a=await(r.isRTL==null?void 0:r.isRTL(o.floating)),s=Be(e),l=xt(e),d=rt(e)==="y",p=["left","top"].includes(s)?-1:1,h=a&&d?-1:1,b=yt(t,i),{mainAxis:x,crossAxis:y,alignmentAxis:E}=typeof b=="number"?{mainAxis:b,crossAxis:0,alignmentAxis:null}:{mainAxis:b.mainAxis||0,crossAxis:b.crossAxis||0,alignmentAxis:b.alignmentAxis};return l&&typeof E=="number"&&(y=l==="end"?E*-1:E),d?{x:y*h,y:x*p}:{x:x*p,y:y*h}}var En=function(i){return i===void 0&&(i=0),{name:"offset",options:i,async fn(t){var e,r;let{x:o,y:a,placement:s,middlewareData:l}=t,d=await Ad(t,i);return s===((e=l.offset)==null?void 0:e.placement)&&(r=l.arrow)!=null&&r.alignmentOffset?{}:{x:o+d.x,y:a+d.y,data:{...d,placement:s}}}}},Tn=function(i){return i===void 0&&(i={}),{name:"shift",options:i,async fn(t){let{x:e,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:l={fn:w=>{let{x:S,y:C}=w;return{x:S,y:C}}},...d}=yt(i,t),p={x:e,y:r},h=await zo(t,d),b=rt(Be(o)),x=Wi(b),y=p[x],E=p[b];if(a){let w=x==="y"?"top":"left",S=x==="y"?"bottom":"right",C=y+h[w],R=y-h[S];y=Mo(C,y,R)}if(s){let w=b==="y"?"top":"left",S=b==="y"?"bottom":"right",C=E+h[w],R=E-h[S];E=Mo(C,E,R)}let A=l.fn({...t,[x]:y,[b]:E});return{...A,data:{x:A.x-e,y:A.y-r,enabled:{[x]:a,[b]:s}}}}}};var An=function(i){return i===void 0&&(i={}),{name:"size",options:i,async fn(t){var e,r;let{placement:o,rects:a,platform:s,elements:l}=t,{apply:d=()=>{},...p}=yt(i,t),h=await zo(t,p),b=Be(o),x=xt(o),y=rt(o)==="y",{width:E,height:A}=a.floating,w,S;b==="top"||b==="bottom"?(w=b,S=x===(await(s.isRTL==null?void 0:s.isRTL(l.floating))?"start":"end")?"left":"right"):(S=b,w=x==="end"?"top":"bottom");let C=A-h.top-h.bottom,R=E-h.left-h.right,B=Ne(A-h[w],C),z=Ne(E-h[S],R),de=!t.middlewareData.shift,be=B,_e=z;if((e=t.middlewareData.shift)!=null&&e.enabled.x&&(_e=R),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(be=C),de&&!x){let ve=Q(h.left,0),qe=Q(h.right,0),Ie=Q(h.top,0),Ze=Q(h.bottom,0);y?_e=E-2*(ve!==0||qe!==0?ve+qe:Q(h.left,h.right)):be=A-2*(Ie!==0||Ze!==0?Ie+Ze:Q(h.top,h.bottom))}await d({...t,availableWidth:_e,availableHeight:be});let Se=await s.getDimensions(l.floating);return E!==Se.width||A!==Se.height?{reset:{rects:!0}}:{}}}};function Po(){return typeof window<"u"}function Tt(i){return In(i)?(i.nodeName||"").toLowerCase():"#document"}function oe(i){var t;return(i==null||(t=i.ownerDocument)==null?void 0:t.defaultView)||window}function xe(i){var t;return(t=(In(i)?i.ownerDocument:i.document)||window.document)==null?void 0:t.documentElement}function In(i){return Po()?i instanceof Node||i instanceof oe(i).Node:!1}function pe(i){return Po()?i instanceof Element||i instanceof oe(i).Element:!1}function Ee(i){return Po()?i instanceof HTMLElement||i instanceof oe(i).HTMLElement:!1}function Sn(i){return!Po()||typeof ShadowRoot>"u"?!1:i instanceof ShadowRoot||i instanceof oe(i).ShadowRoot}function cr(i){let{overflow:t,overflowX:e,overflowY:r,display:o}=he(i);return/auto|scroll|overlay|hidden|clip/.test(t+r+e)&&!["inline","contents"].includes(o)}function wn(i){return["table","td","th"].includes(Tt(i))}function Yr(i){return[":popover-open",":modal"].some(t=>{try{return i.matches(t)}catch{return!1}})}function Vo(i){let t=Uo(),e=pe(i)?he(i):i;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 Cn(i){let t=He(i);for(;Ee(t)&&!At(t);){if(Vo(t))return t;if(Yr(t))return null;t=He(t)}return null}function Uo(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function At(i){return["html","body","#document"].includes(Tt(i))}function he(i){return oe(i).getComputedStyle(i)}function qr(i){return pe(i)?{scrollLeft:i.scrollLeft,scrollTop:i.scrollTop}:{scrollLeft:i.scrollX,scrollTop:i.scrollY}}function He(i){if(Tt(i)==="html")return i;let t=i.assignedSlot||i.parentNode||Sn(i)&&i.host||xe(i);return Sn(t)?t.host:t}function kn(i){let t=He(i);return At(t)?i.ownerDocument?i.ownerDocument.body:i.body:Ee(t)&&cr(t)?t:kn(t)}function lr(i,t,e){var r;t===void 0&&(t=[]),e===void 0&&(e=!0);let o=kn(i),a=o===((r=i.ownerDocument)==null?void 0:r.body),s=oe(o);if(a){let l=Fo(s);return t.concat(s,s.visualViewport||[],cr(o)?o:[],l&&e?lr(l):[])}return t.concat(o,lr(o,[],e))}function Fo(i){return i.parent&&Object.getPrototypeOf(i.parent)?i.frameElement:null}function Ln(i){let t=he(i),e=parseFloat(t.width)||0,r=parseFloat(t.height)||0,o=Ee(i),a=o?i.offsetWidth:e,s=o?i.offsetHeight:r,l=Gr(e)!==a||Gr(r)!==s;return l&&(e=a,r=s),{width:e,height:r,$:l}}function Zi(i){return pe(i)?i:i.contextElement}function dr(i){let t=Zi(i);if(!Ee(t))return ye(1);let e=t.getBoundingClientRect(),{width:r,height:o,$:a}=Ln(t),s=(a?Gr(e.width):e.width)/r,l=(a?Gr(e.height):e.height)/o;return(!s||!Number.isFinite(s))&&(s=1),(!l||!Number.isFinite(l))&&(l=1),{x:s,y:l}}var Sd=ye(0);function Rn(i){let t=oe(i);return!Uo()||!t.visualViewport?Sd:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Id(i,t,e){return t===void 0&&(t=!1),!e||t&&e!==oe(i)?!1:t}function St(i,t,e,r){t===void 0&&(t=!1),e===void 0&&(e=!1);let o=i.getBoundingClientRect(),a=Zi(i),s=ye(1);t&&(r?pe(r)&&(s=dr(r)):s=dr(i));let l=Id(a,e,r)?Rn(a):ye(0),d=(o.left+l.x)/s.x,p=(o.top+l.y)/s.y,h=o.width/s.x,b=o.height/s.y;if(a){let x=oe(a),y=r&&pe(r)?oe(r):r,E=x,A=Fo(E);for(;A&&r&&y!==E;){let w=dr(A),S=A.getBoundingClientRect(),C=he(A),R=S.left+(A.clientLeft+parseFloat(C.paddingLeft))*w.x,B=S.top+(A.clientTop+parseFloat(C.paddingTop))*w.y;d*=w.x,p*=w.y,h*=w.x,b*=w.y,d+=R,p+=B,E=oe(A),A=Fo(E)}}return Et({width:h,height:b,x:d,y:p})}function Xi(i,t){let e=qr(i).scrollLeft;return t?t.left+e:St(xe(i)).left+e}function On(i,t,e){e===void 0&&(e=!1);let r=i.getBoundingClientRect(),o=r.left+t.scrollLeft-(e?0:Xi(i,r)),a=r.top+t.scrollTop;return{x:o,y:a}}function wd(i){let{elements:t,rect:e,offsetParent:r,strategy:o}=i,a=o==="fixed",s=xe(r),l=t?Yr(t.floating):!1;if(r===s||l&&a)return e;let d={scrollLeft:0,scrollTop:0},p=ye(1),h=ye(0),b=Ee(r);if((b||!b&&!a)&&((Tt(r)!=="body"||cr(s))&&(d=qr(r)),Ee(r))){let y=St(r);p=dr(r),h.x=y.x+r.clientLeft,h.y=y.y+r.clientTop}let x=s&&!b&&!a?On(s,d,!0):ye(0);return{width:e.width*p.x,height:e.height*p.y,x:e.x*p.x-d.scrollLeft*p.x+h.x+x.x,y:e.y*p.y-d.scrollTop*p.y+h.y+x.y}}function Cd(i){return Array.from(i.getClientRects())}function kd(i){let t=xe(i),e=qr(i),r=i.ownerDocument.body,o=Q(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Q(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),s=-e.scrollLeft+Xi(i),l=-e.scrollTop;return he(r).direction==="rtl"&&(s+=Q(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:s,y:l}}function Nd(i,t){let e=oe(i),r=xe(i),o=e.visualViewport,a=r.clientWidth,s=r.clientHeight,l=0,d=0;if(o){a=o.width,s=o.height;let p=Uo();(!p||p&&t==="fixed")&&(l=o.offsetLeft,d=o.offsetTop)}return{width:a,height:s,x:l,y:d}}function _d(i,t){let e=St(i,!0,t==="fixed"),r=e.top+i.clientTop,o=e.left+i.clientLeft,a=Ee(i)?dr(i):ye(1),s=i.clientWidth*a.x,l=i.clientHeight*a.y,d=o*a.x,p=r*a.y;return{width:s,height:l,x:d,y:p}}function Nn(i,t,e){let r;if(t==="viewport")r=Nd(i,e);else if(t==="document")r=kd(xe(i));else if(pe(t))r=_d(t,e);else{let o=Rn(i);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return Et(r)}function Mn(i,t){let e=He(i);return e===t||!pe(e)||At(e)?!1:he(e).position==="fixed"||Mn(e,t)}function Ld(i,t){let e=t.get(i);if(e)return e;let r=lr(i,[],!1).filter(l=>pe(l)&&Tt(l)!=="body"),o=null,a=he(i).position==="fixed",s=a?He(i):i;for(;pe(s)&&!At(s);){let l=he(s),d=Vo(s);!d&&l.position==="fixed"&&(o=null),(a?!d&&!o:!d&&l.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||cr(s)&&!d&&Mn(i,s))?r=r.filter(h=>h!==s):o=l,s=He(s)}return t.set(i,r),r}function Rd(i){let{element:t,boundary:e,rootBoundary:r,strategy:o}=i,s=[...e==="clippingAncestors"?Yr(t)?[]:Ld(t,this._c):[].concat(e),r],l=s[0],d=s.reduce((p,h)=>{let b=Nn(t,h,o);return p.top=Q(b.top,p.top),p.right=Ne(b.right,p.right),p.bottom=Ne(b.bottom,p.bottom),p.left=Q(b.left,p.left),p},Nn(t,l,o));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function Od(i){let{width:t,height:e}=Ln(i);return{width:t,height:e}}function Md(i,t,e){let r=Ee(t),o=xe(t),a=e==="fixed",s=St(i,!0,a,t),l={scrollLeft:0,scrollTop:0},d=ye(0);if(r||!r&&!a)if((Tt(t)!=="body"||cr(o))&&(l=qr(t)),r){let x=St(t,!0,a,t);d.x=x.x+t.clientLeft,d.y=x.y+t.clientTop}else o&&(d.x=Xi(o));let p=o&&!r&&!a?On(o,l):ye(0),h=s.left+l.scrollLeft-d.x-p.x,b=s.top+l.scrollTop-d.y-p.y;return{x:h,y:b,width:s.width,height:s.height}}function qi(i){return he(i).position==="static"}function _n(i,t){if(!Ee(i)||he(i).position==="fixed")return null;if(t)return t(i);let e=i.offsetParent;return xe(i)===e&&(e=e.ownerDocument.body),e}function Dn(i,t){let e=oe(i);if(Yr(i))return e;if(!Ee(i)){let o=He(i);for(;o&&!At(o);){if(pe(o)&&!qi(o))return o;o=He(o)}return e}let r=_n(i,t);for(;r&&wn(r)&&qi(r);)r=_n(r,t);return r&&At(r)&&qi(r)&&!Vo(r)?e:r||Cn(i)||e}var Dd=async function(i){let t=this.getOffsetParent||Dn,e=this.getDimensions,r=await e(i.floating);return{reference:Md(i.reference,await t(i.floating),i.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function $d(i){return he(i).direction==="rtl"}var zd={convertOffsetParentRelativeRectToViewportRelativeRect:wd,getDocumentElement:xe,getClippingRect:Rd,getOffsetParent:Dn,getElementRects:Dd,getClientRects:Cd,getDimensions:Od,getScale:dr,isElement:pe,isRTL:$d};function Pd(i,t){let e=null,r,o=xe(i);function a(){var l;clearTimeout(r),(l=e)==null||l.disconnect(),e=null}function s(l,d){l===void 0&&(l=!1),d===void 0&&(d=1),a();let{left:p,top:h,width:b,height:x}=i.getBoundingClientRect();if(l||t(),!b||!x)return;let y=Wr(h),E=Wr(o.clientWidth-(p+b)),A=Wr(o.clientHeight-(h+x)),w=Wr(p),C={rootMargin:-y+"px "+-E+"px "+-A+"px "+-w+"px",threshold:Q(0,Ne(1,d))||1},R=!0;function B(z){let de=z[0].intersectionRatio;if(de!==d){if(!R)return s();de?s(!1,de):r=setTimeout(()=>{s(!1,1e-7)},1e3)}R=!1}try{e=new IntersectionObserver(B,{...C,root:o.ownerDocument})}catch{e=new IntersectionObserver(B,C)}e.observe(i)}return s(!0),a}function $n(i,t,e,r){r===void 0&&(r={});let{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:l=typeof IntersectionObserver=="function",animationFrame:d=!1}=r,p=Zi(i),h=o||a?[...p?lr(p):[],...lr(t)]:[];h.forEach(S=>{o&&S.addEventListener("scroll",e,{passive:!0}),a&&S.addEventListener("resize",e)});let b=p&&l?Pd(p,e):null,x=-1,y=null;s&&(y=new ResizeObserver(S=>{let[C]=S;C&&C.target===p&&y&&(y.unobserve(t),cancelAnimationFrame(x),x=requestAnimationFrame(()=>{var R;(R=y)==null||R.observe(t)})),e()}),p&&!d&&y.observe(p),y.observe(t));let E,A=d?St(i):null;d&&w();function w(){let S=St(i);A&&(S.x!==A.x||S.y!==A.y||S.width!==A.width||S.height!==A.height)&&e(),A=S,E=requestAnimationFrame(w)}return e(),()=>{var S;h.forEach(C=>{o&&C.removeEventListener("scroll",e),a&&C.removeEventListener("resize",e)}),b==null||b(),(S=y)==null||S.disconnect(),y=null,d&&cancelAnimationFrame(E)}}var zn=En;var Pn=Tn,Vn=xn,Un=An;var Fn=yn;var Bn=(i,t,e)=>{let r=new Map,o={platform:zd,...e},a={...o.platform,_c:r};return gn(i,t,{...o,platform:a})};var Hn=f.constructTagName("popover"),ne={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"},It={CLICK:"click",MOUSEENTER:"mouseenter",FOCUSIN:"focusin",MANUAL:"manual"},Zr={TONAL:"tonal",CONTRAST:"contrast"},M={PLACEMENT:ne.BOTTOM,TRIGGER:It.CLICK,COLOR:Zr.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,DISABLE_ARIA_EXPANDED:!1};var Gn=i=>{class t extends i{constructor(...o){super(...o);this.enabledFocusTrap=M.FOCUS_TRAP;this.enabledPreventScroll=M.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(o){return o.getClientRects().length===0}hasZeroDimensions(o){let{width:a,height:s}=o.getBoundingClientRect(),{offsetWidth:l,offsetHeight:d}=o;return l+d+s+a===0}isNotVisible(o){return this.hasZeroDimensions(o)||this.hasNoClientRects(o)}hasHiddenStyle(o){let{display:a,opacity:s,visibility:l}=o.style;return a==="none"||s==="0"||l==="hidden"||l==="collapse"}hasComputedHidden(o){let a=getComputedStyle(o);return a.visibility==="hidden"||a.height==="0"||a.display==="none"}isHidden(o){return o.hasAttribute("hidden")||o.getAttribute("aria-hidden")==="true"||this.hasHiddenStyle(o)||this.isNotVisible(o)||this.hasComputedHidden(o)}isNotTabbable(o){return o.getAttribute("tabindex")==="-1"}isInteractiveElement(o){return!!(new Set(["BUTTON","DETAILS","EMBED","IFRAME","SELECT","TEXTAREA"]).has(o.tagName)||o instanceof HTMLAnchorElement&&o.hasAttribute("href")||o instanceof HTMLInputElement&&o.type!=="hidden"||(o instanceof HTMLAudioElement||o instanceof HTMLVideoElement)&&o.hasAttribute("controls")||(o instanceof HTMLImageElement||o instanceof HTMLObjectElement)&&o.hasAttribute("usemap")||o.hasAttribute("tabindex")&&o.tabIndex>-1)}isFocusable(o){return this.isHidden(o)||this.isNotTabbable(o)?!1:this.isInteractiveElement(o)}findFocusable(o,a=new Set){return o instanceof HTMLElement&&this.isFocusable(o)&&a.add(o),Array.from(o.children).forEach(l=>{let d=l;this.isFocusable(d)&&a.add(d),d.shadowRoot?this.findFocusable(d.shadowRoot,a):d.tagName==="SLOT"?d.assignedElements({flatten:!0}).forEach(h=>{h instanceof HTMLElement&&this.findFocusable(h,a)}):this.findFocusable(d,a)}),[...a]}setFocusableElements(){this.shadowRoot&&(this.focusableElements=this.findFocusable(this.shadowRoot,new Set))}setInitialFocus(o=0){this.focusableElements.length!==0&&(this.enabledPreventScroll&&(document.body.style.overflow="hidden"),this.focusableElements[o]&&(this.focusTrapIndex=o,this.focusableElements[o].focus()))}calculateNextIndex(o,a){let{length:s}=this.focusableElements,l=this.shouldWrapFocus();if(o===-1)return a>0?0:s-1;let d=o+a;return l?(d<0&&(d=s-1),d>=s&&(d=0)):(d<0&&(d=0),d>=s&&(d=s-1)),d}getDeepActiveElement(){var a;let o=document.activeElement||document.body;for(;o instanceof HTMLElement&&((a=o.shadowRoot)!=null&&a.activeElement);)o=o.shadowRoot.activeElement;return o||document.body}findElement(o){return this.focusableElements.findIndex(a=>this.isEqualFocusNode(o,a))}isEqualFocusNode(o,a){return o.nodeType>=0?a.isEqualNode(o)&&a===o:!1}trapFocus(o){if(this.focusableElements.length===0)return;let a=this.getDeepActiveElement(),s=this.findElement(a);o?this.focusTrapIndex=this.calculateNextIndex(s,-1):this.focusTrapIndex=this.calculateNextIndex(s,1);let l=this.focusableElements[this.focusTrapIndex];l&&l.focus()}handleKeydown(o){!this.enabledFocusTrap||!this.focusableElements.length||o.key==="Tab"&&(o.preventDefault(),this.trapFocus(o.shiftKey))}}return n([c({type:Boolean})],t.prototype,"enabledFocusTrap",2),n([c({type:Boolean})],t.prototype,"enabledPreventScroll",2),t};var wt=class{static dispatchPopoverEvent(t,e){e.dispatchEvent(new CustomEvent(t,{detail:{show:e.visible},composed:!0,bubbles:!0}))}static onShowPopover(t){this.dispatchPopoverEvent("shown",t)}static onHidePopover(t){this.dispatchPopoverEvent("hidden",t)}static onCreatedPopover(t){this.dispatchPopoverEvent("created",t)}static onDestroyedPopover(t){this.dispatchPopoverEvent("destroyed",t)}};var Ki=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=[]}},Ct=new Ki;var Vd=u`
|
2014
|
+
<mdc-text type="${fr.TEXT_TYPE}" tagname="${fr.TAG_NAME}">${this.label}</mdc-text>
|
2015
|
+
`}};br.styles=[...v.styles,...Hn],n([c({type:String,reflect:!0})],br.prototype,"color",2),n([c({type:String})],br.prototype,"label",2);var gr=br;gr.register(Gn);var rm=gr;var Oe=Math.min,ee=Math.max,Xr=Math.round,jr=Math.floor,Te=i=>({x:i,y:i}),om={left:"right",right:"left",bottom:"top",top:"bottom"},im={start:"end",end:"start"};function Ko(i,t,e){return ee(i,Oe(t,e))}function Ct(i,t){return typeof i=="function"?i(t):i}function qe(i){return i.split("-")[0]}function kt(i){return i.split("-")[1]}function pa(i){return i==="x"?"y":"x"}function Zo(i){return i==="y"?"height":"width"}function lt(i){return["top","bottom"].includes(qe(i))?"y":"x"}function Xo(i){return pa(lt(i))}function Yn(i,t,e){e===void 0&&(e=!1);let r=kt(i),o=Xo(i),a=Zo(o),s=o==="x"?r===(e?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(s=Zr(s)),[s,Zr(s)]}function Wn(i){let t=Zr(i);return[qo(i),t,qo(t)]}function qo(i){return i.replace(/start|end/g,t=>im[t])}function am(i,t,e){let r=["left","right"],o=["right","left"],a=["top","bottom"],s=["bottom","top"];switch(i){case"top":case"bottom":return e?t?o:r:t?r:o;case"left":case"right":return t?a:s;default:return[]}}function qn(i,t,e,r){let o=kt(i),a=am(qe(i),e==="start",r);return o&&(a=a.map(s=>s+"-"+o),t&&(a=a.concat(a.map(qo)))),a}function Zr(i){return i.replace(/left|right|bottom|top/g,t=>om[t])}function sm(i){return{top:0,right:0,bottom:0,left:0,...i}}function ha(i){return typeof i!="number"?sm(i):{top:i,right:i,bottom:i,left:i}}function wt(i){let{x:t,y:e,width:r,height:o}=i;return{width:r,height:o,top:e,left:t,right:t+r,bottom:e+o,x:t,y:e}}function Kn(i,t,e){let{reference:r,floating:o}=i,a=lt(t),s=Xo(t),l=Zo(s),d=qe(t),p=a==="y",h=r.x+r.width/2-o.width/2,b=r.y+r.height/2-o.height/2,x=r[l]/2-o[l]/2,y;switch(d){case"top":y={x:h,y:r.y-o.height};break;case"bottom":y={x:h,y:r.y+r.height};break;case"right":y={x:r.x+r.width,y:b};break;case"left":y={x:r.x-o.width,y:b};break;default:y={x:r.x,y:r.y}}switch(kt(t)){case"start":y[s]-=x*(e&&p?-1:1);break;case"end":y[s]+=x*(e&&p?-1:1);break}return y}var Zn=async(i,t,e)=>{let{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:s}=e,l=a.filter(Boolean),d=await(s.isRTL==null?void 0:s.isRTL(t)),p=await s.getElementRects({reference:i,floating:t,strategy:o}),{x:h,y:b}=Kn(p,r,d),x=r,y={},E=0;for(let A=0;A<l.length;A++){let{name:C,fn:I}=l[A],{x:k,y:O,data:H,reset:z}=await I({x:h,y:b,initialPlacement:r,placement:x,strategy:o,middlewareData:y,rects:p,platform:s,elements:{reference:i,floating:t}});h=k!=null?k:h,b=O!=null?O:b,y={...y,[C]:{...y[C],...H}},z&&E<=50&&(E++,typeof z=="object"&&(z.placement&&(x=z.placement),z.rects&&(p=z.rects===!0?await s.getElementRects({reference:i,floating:t,strategy:o}):z.rects),{x:h,y:b}=Kn(p,x,d)),A=-1)}return{x:h,y:b,placement:x,strategy:o,middlewareData:y}};async function jo(i,t){var e;t===void 0&&(t={});let{x:r,y:o,platform:a,rects:s,elements:l,strategy:d}=i,{boundary:p="clippingAncestors",rootBoundary:h="viewport",elementContext:b="floating",altBoundary:x=!1,padding:y=0}=Ct(t,i),E=ha(y),C=l[x?b==="floating"?"reference":"floating":b],I=wt(await a.getClippingRect({element:(e=await(a.isElement==null?void 0:a.isElement(C)))==null||e?C:C.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(l.floating)),boundary:p,rootBoundary:h,strategy:d})),k=b==="floating"?{x:r,y:o,width:s.floating.width,height:s.floating.height}:s.reference,O=await(a.getOffsetParent==null?void 0:a.getOffsetParent(l.floating)),H=await(a.isElement==null?void 0:a.isElement(O))?await(a.getScale==null?void 0:a.getScale(O))||{x:1,y:1}:{x:1,y:1},z=wt(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:k,offsetParent:O,strategy:d}):k);return{top:(I.top-z.top+E.top)/H.y,bottom:(z.bottom-I.bottom+E.bottom)/H.y,left:(I.left-z.left+E.left)/H.x,right:(z.right-I.right+E.right)/H.x}}var Xn=i=>({name:"arrow",options:i,async fn(t){let{x:e,y:r,placement:o,rects:a,platform:s,elements:l,middlewareData:d}=t,{element:p,padding:h=0}=Ct(i,t)||{};if(p==null)return{};let b=ha(h),x={x:e,y:r},y=Xo(o),E=Zo(y),A=await s.getDimensions(p),C=y==="y",I=C?"top":"left",k=C?"bottom":"right",O=C?"clientHeight":"clientWidth",H=a.reference[E]+a.reference[y]-x[y]-a.floating[E],z=x[y]-a.reference[y],he=await(s.getOffsetParent==null?void 0:s.getOffsetParent(p)),ve=he?he[O]:0;(!ve||!await(s.isElement==null?void 0:s.isElement(he)))&&(ve=l.floating[O]||a.floating[E]);let Me=H/2-z/2,ke=ve/2-A[E]/2-1,ye=Oe(b[I],ke),Qe=Oe(b[k],ke),we=ye,Je=ve-A[E]-Qe,j=ve/2-A[E]/2+Me,Kt=Ko(we,j,Je),De=!d.arrow&&kt(o)!=null&&j!==Kt&&a.reference[E]/2-(j<we?ye:Qe)-A[E]/2<0,Ne=De?j<we?j-we:j-Je:0;return{[y]:x[y]+Ne,data:{[y]:Kt,centerOffset:j-Kt-Ne,...De&&{alignmentOffset:Ne}},reset:De}}});var jn=function(i){return i===void 0&&(i={}),{name:"flip",options:i,async fn(t){var e,r;let{placement:o,middlewareData:a,rects:s,initialPlacement:l,platform:d,elements:p}=t,{mainAxis:h=!0,crossAxis:b=!0,fallbackPlacements:x,fallbackStrategy:y="bestFit",fallbackAxisSideDirection:E="none",flipAlignment:A=!0,...C}=Ct(i,t);if((e=a.arrow)!=null&&e.alignmentOffset)return{};let I=qe(o),k=lt(l),O=qe(l)===l,H=await(d.isRTL==null?void 0:d.isRTL(p.floating)),z=x||(O||!A?[Zr(l)]:Wn(l)),he=E!=="none";!x&&he&&z.push(...qn(l,A,E,H));let ve=[l,...z],Me=await jo(t,C),ke=[],ye=((r=a.flip)==null?void 0:r.overflows)||[];if(h&&ke.push(Me[I]),b){let j=Yn(o,s,H);ke.push(Me[j[0]],Me[j[1]])}if(ye=[...ye,{placement:o,overflows:ke}],!ke.every(j=>j<=0)){var Qe,we;let j=(((Qe=a.flip)==null?void 0:Qe.index)||0)+1,Kt=ve[j];if(Kt)return{data:{index:j,overflows:ye},reset:{placement:Kt}};let De=(we=ye.filter(Ne=>Ne.overflows[0]<=0).sort((Ne,et)=>Ne.overflows[1]-et.overflows[1])[0])==null?void 0:we.placement;if(!De)switch(y){case"bestFit":{var Je;let Ne=(Je=ye.filter(et=>{if(he){let tt=lt(et.placement);return tt===k||tt==="y"}return!0}).map(et=>[et.placement,et.overflows.filter(tt=>tt>0).reduce((tt,Hc)=>tt+Hc,0)]).sort((et,tt)=>et[1]-tt[1])[0])==null?void 0:Je[0];Ne&&(De=Ne);break}case"initialPlacement":De=l;break}if(o!==De)return{reset:{placement:De}}}return{}}}};async function nm(i,t){let{placement:e,platform:r,elements:o}=i,a=await(r.isRTL==null?void 0:r.isRTL(o.floating)),s=qe(e),l=kt(e),d=lt(e)==="y",p=["left","top"].includes(s)?-1:1,h=a&&d?-1:1,b=Ct(t,i),{mainAxis:x,crossAxis:y,alignmentAxis:E}=typeof b=="number"?{mainAxis:b,crossAxis:0,alignmentAxis:null}:{mainAxis:b.mainAxis||0,crossAxis:b.crossAxis||0,alignmentAxis:b.alignmentAxis};return l&&typeof E=="number"&&(y=l==="end"?E*-1:E),d?{x:y*h,y:x*p}:{x:x*p,y:y*h}}var Qn=function(i){return i===void 0&&(i=0),{name:"offset",options:i,async fn(t){var e,r;let{x:o,y:a,placement:s,middlewareData:l}=t,d=await nm(t,i);return s===((e=l.offset)==null?void 0:e.placement)&&(r=l.arrow)!=null&&r.alignmentOffset?{}:{x:o+d.x,y:a+d.y,data:{...d,placement:s}}}}},Jn=function(i){return i===void 0&&(i={}),{name:"shift",options:i,async fn(t){let{x:e,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:l={fn:C=>{let{x:I,y:k}=C;return{x:I,y:k}}},...d}=Ct(i,t),p={x:e,y:r},h=await jo(t,d),b=lt(qe(o)),x=pa(b),y=p[x],E=p[b];if(a){let C=x==="y"?"top":"left",I=x==="y"?"bottom":"right",k=y+h[C],O=y-h[I];y=Ko(k,y,O)}if(s){let C=b==="y"?"top":"left",I=b==="y"?"bottom":"right",k=E+h[C],O=E-h[I];E=Ko(k,E,O)}let A=l.fn({...t,[x]:y,[b]:E});return{...A,data:{x:A.x-e,y:A.y-r,enabled:{[x]:a,[b]:s}}}}}};var el=function(i){return i===void 0&&(i={}),{name:"size",options:i,async fn(t){var e,r;let{placement:o,rects:a,platform:s,elements:l}=t,{apply:d=()=>{},...p}=Ct(i,t),h=await jo(t,p),b=qe(o),x=kt(o),y=lt(o)==="y",{width:E,height:A}=a.floating,C,I;b==="top"||b==="bottom"?(C=b,I=x===(await(s.isRTL==null?void 0:s.isRTL(l.floating))?"start":"end")?"left":"right"):(I=b,C=x==="end"?"top":"bottom");let k=A-h.top-h.bottom,O=E-h.left-h.right,H=Oe(A-h[C],k),z=Oe(E-h[I],O),he=!t.middlewareData.shift,ve=H,Me=z;if((e=t.middlewareData.shift)!=null&&e.enabled.x&&(Me=O),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(ve=k),he&&!x){let ye=ee(h.left,0),Qe=ee(h.right,0),we=ee(h.top,0),Je=ee(h.bottom,0);y?Me=E-2*(ye!==0||Qe!==0?ye+Qe:ee(h.left,h.right)):ve=A-2*(we!==0||Je!==0?we+Je:ee(h.top,h.bottom))}await d({...t,availableWidth:Me,availableHeight:ve});let ke=await s.getDimensions(l.floating);return E!==ke.width||A!==ke.height?{reset:{rects:!0}}:{}}}};function Qo(){return typeof window<"u"}function Nt(i){return rl(i)?(i.nodeName||"").toLowerCase():"#document"}function ne(i){var t;return(i==null||(t=i.ownerDocument)==null?void 0:t.defaultView)||window}function Ae(i){var t;return(t=(rl(i)?i.ownerDocument:i.document)||window.document)==null?void 0:t.documentElement}function rl(i){return Qo()?i instanceof Node||i instanceof ne(i).Node:!1}function ue(i){return Qo()?i instanceof Element||i instanceof ne(i).Element:!1}function Se(i){return Qo()?i instanceof HTMLElement||i instanceof ne(i).HTMLElement:!1}function tl(i){return!Qo()||typeof ShadowRoot>"u"?!1:i instanceof ShadowRoot||i instanceof ne(i).ShadowRoot}function yr(i){let{overflow:t,overflowX:e,overflowY:r,display:o}=fe(i);return/auto|scroll|overlay|hidden|clip/.test(t+r+e)&&!["inline","contents"].includes(o)}function ol(i){return["table","td","th"].includes(Nt(i))}function Qr(i){return[":popover-open",":modal"].some(t=>{try{return i.matches(t)}catch{return!1}})}function Jo(i){let t=ei(),e=ue(i)?fe(i):i;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 il(i){let t=Ke(i);for(;Se(t)&&!_t(t);){if(Jo(t))return t;if(Qr(t))return null;t=Ke(t)}return null}function ei(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function _t(i){return["html","body","#document"].includes(Nt(i))}function fe(i){return ne(i).getComputedStyle(i)}function Jr(i){return ue(i)?{scrollLeft:i.scrollLeft,scrollTop:i.scrollTop}:{scrollLeft:i.scrollX,scrollTop:i.scrollY}}function Ke(i){if(Nt(i)==="html")return i;let t=i.assignedSlot||i.parentNode||tl(i)&&i.host||Ae(i);return tl(t)?t.host:t}function al(i){let t=Ke(i);return _t(t)?i.ownerDocument?i.ownerDocument.body:i.body:Se(t)&&yr(t)?t:al(t)}function vr(i,t,e){var r;t===void 0&&(t=[]),e===void 0&&(e=!0);let o=al(i),a=o===((r=i.ownerDocument)==null?void 0:r.body),s=ne(o);if(a){let l=ti(s);return t.concat(s,s.visualViewport||[],yr(o)?o:[],l&&e?vr(l):[])}return t.concat(o,vr(o,[],e))}function ti(i){return i.parent&&Object.getPrototypeOf(i.parent)?i.frameElement:null}function ll(i){let t=fe(i),e=parseFloat(t.width)||0,r=parseFloat(t.height)||0,o=Se(i),a=o?i.offsetWidth:e,s=o?i.offsetHeight:r,l=Xr(e)!==a||Xr(r)!==s;return l&&(e=a,r=s),{width:e,height:r,$:l}}function fa(i){return ue(i)?i:i.contextElement}function xr(i){let t=fa(i);if(!Se(t))return Te(1);let e=t.getBoundingClientRect(),{width:r,height:o,$:a}=ll(t),s=(a?Xr(e.width):e.width)/r,l=(a?Xr(e.height):e.height)/o;return(!s||!Number.isFinite(s))&&(s=1),(!l||!Number.isFinite(l))&&(l=1),{x:s,y:l}}var lm=Te(0);function cl(i){let t=ne(i);return!ei()||!t.visualViewport?lm:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function cm(i,t,e){return t===void 0&&(t=!1),!e||t&&e!==ne(i)?!1:t}function Lt(i,t,e,r){t===void 0&&(t=!1),e===void 0&&(e=!1);let o=i.getBoundingClientRect(),a=fa(i),s=Te(1);t&&(r?ue(r)&&(s=xr(r)):s=xr(i));let l=cm(a,e,r)?cl(a):Te(0),d=(o.left+l.x)/s.x,p=(o.top+l.y)/s.y,h=o.width/s.x,b=o.height/s.y;if(a){let x=ne(a),y=r&&ue(r)?ne(r):r,E=x,A=ti(E);for(;A&&r&&y!==E;){let C=xr(A),I=A.getBoundingClientRect(),k=fe(A),O=I.left+(A.clientLeft+parseFloat(k.paddingLeft))*C.x,H=I.top+(A.clientTop+parseFloat(k.paddingTop))*C.y;d*=C.x,p*=C.y,h*=C.x,b*=C.y,d+=O,p+=H,E=ne(A),A=ti(E)}}return wt({width:h,height:b,x:d,y:p})}function ba(i,t){let e=Jr(i).scrollLeft;return t?t.left+e:Lt(Ae(i)).left+e}function dl(i,t,e){e===void 0&&(e=!1);let r=i.getBoundingClientRect(),o=r.left+t.scrollLeft-(e?0:ba(i,r)),a=r.top+t.scrollTop;return{x:o,y:a}}function dm(i){let{elements:t,rect:e,offsetParent:r,strategy:o}=i,a=o==="fixed",s=Ae(r),l=t?Qr(t.floating):!1;if(r===s||l&&a)return e;let d={scrollLeft:0,scrollTop:0},p=Te(1),h=Te(0),b=Se(r);if((b||!b&&!a)&&((Nt(r)!=="body"||yr(s))&&(d=Jr(r)),Se(r))){let y=Lt(r);p=xr(r),h.x=y.x+r.clientLeft,h.y=y.y+r.clientTop}let x=s&&!b&&!a?dl(s,d,!0):Te(0);return{width:e.width*p.x,height:e.height*p.y,x:e.x*p.x-d.scrollLeft*p.x+h.x+x.x,y:e.y*p.y-d.scrollTop*p.y+h.y+x.y}}function mm(i){return Array.from(i.getClientRects())}function pm(i){let t=Ae(i),e=Jr(i),r=i.ownerDocument.body,o=ee(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=ee(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),s=-e.scrollLeft+ba(i),l=-e.scrollTop;return fe(r).direction==="rtl"&&(s+=ee(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:s,y:l}}function hm(i,t){let e=ne(i),r=Ae(i),o=e.visualViewport,a=r.clientWidth,s=r.clientHeight,l=0,d=0;if(o){a=o.width,s=o.height;let p=ei();(!p||p&&t==="fixed")&&(l=o.offsetLeft,d=o.offsetTop)}return{width:a,height:s,x:l,y:d}}function um(i,t){let e=Lt(i,!0,t==="fixed"),r=e.top+i.clientTop,o=e.left+i.clientLeft,a=Se(i)?xr(i):Te(1),s=i.clientWidth*a.x,l=i.clientHeight*a.y,d=o*a.x,p=r*a.y;return{width:s,height:l,x:d,y:p}}function sl(i,t,e){let r;if(t==="viewport")r=hm(i,e);else if(t==="document")r=pm(Ae(i));else if(ue(t))r=um(t,e);else{let o=cl(i);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return wt(r)}function ml(i,t){let e=Ke(i);return e===t||!ue(e)||_t(e)?!1:fe(e).position==="fixed"||ml(e,t)}function fm(i,t){let e=t.get(i);if(e)return e;let r=vr(i,[],!1).filter(l=>ue(l)&&Nt(l)!=="body"),o=null,a=fe(i).position==="fixed",s=a?Ke(i):i;for(;ue(s)&&!_t(s);){let l=fe(s),d=Jo(s);!d&&l.position==="fixed"&&(o=null),(a?!d&&!o:!d&&l.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||yr(s)&&!d&&ml(i,s))?r=r.filter(h=>h!==s):o=l,s=Ke(s)}return t.set(i,r),r}function bm(i){let{element:t,boundary:e,rootBoundary:r,strategy:o}=i,s=[...e==="clippingAncestors"?Qr(t)?[]:fm(t,this._c):[].concat(e),r],l=s[0],d=s.reduce((p,h)=>{let b=sl(t,h,o);return p.top=ee(b.top,p.top),p.right=Oe(b.right,p.right),p.bottom=Oe(b.bottom,p.bottom),p.left=ee(b.left,p.left),p},sl(t,l,o));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function gm(i){let{width:t,height:e}=ll(i);return{width:t,height:e}}function vm(i,t,e){let r=Se(t),o=Ae(t),a=e==="fixed",s=Lt(i,!0,a,t),l={scrollLeft:0,scrollTop:0},d=Te(0);if(r||!r&&!a)if((Nt(t)!=="body"||yr(o))&&(l=Jr(t)),r){let x=Lt(t,!0,a,t);d.x=x.x+t.clientLeft,d.y=x.y+t.clientTop}else o&&(d.x=ba(o));let p=o&&!r&&!a?dl(o,l):Te(0),h=s.left+l.scrollLeft-d.x-p.x,b=s.top+l.scrollTop-d.y-p.y;return{x:h,y:b,width:s.width,height:s.height}}function ua(i){return fe(i).position==="static"}function nl(i,t){if(!Se(i)||fe(i).position==="fixed")return null;if(t)return t(i);let e=i.offsetParent;return Ae(i)===e&&(e=e.ownerDocument.body),e}function pl(i,t){let e=ne(i);if(Qr(i))return e;if(!Se(i)){let o=Ke(i);for(;o&&!_t(o);){if(ue(o)&&!ua(o))return o;o=Ke(o)}return e}let r=nl(i,t);for(;r&&ol(r)&&ua(r);)r=nl(r,t);return r&&_t(r)&&ua(r)&&!Jo(r)?e:r||il(i)||e}var ym=async function(i){let t=this.getOffsetParent||pl,e=this.getDimensions,r=await e(i.floating);return{reference:vm(i.reference,await t(i.floating),i.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function xm(i){return fe(i).direction==="rtl"}var Em={convertOffsetParentRelativeRectToViewportRelativeRect:dm,getDocumentElement:Ae,getClippingRect:bm,getOffsetParent:pl,getElementRects:ym,getClientRects:mm,getDimensions:gm,getScale:xr,isElement:ue,isRTL:xm};function Tm(i,t){let e=null,r,o=Ae(i);function a(){var l;clearTimeout(r),(l=e)==null||l.disconnect(),e=null}function s(l,d){l===void 0&&(l=!1),d===void 0&&(d=1),a();let{left:p,top:h,width:b,height:x}=i.getBoundingClientRect();if(l||t(),!b||!x)return;let y=jr(h),E=jr(o.clientWidth-(p+b)),A=jr(o.clientHeight-(h+x)),C=jr(p),k={rootMargin:-y+"px "+-E+"px "+-A+"px "+-C+"px",threshold:ee(0,Oe(1,d))||1},O=!0;function H(z){let he=z[0].intersectionRatio;if(he!==d){if(!O)return s();he?s(!1,he):r=setTimeout(()=>{s(!1,1e-7)},1e3)}O=!1}try{e=new IntersectionObserver(H,{...k,root:o.ownerDocument})}catch{e=new IntersectionObserver(H,k)}e.observe(i)}return s(!0),a}function hl(i,t,e,r){r===void 0&&(r={});let{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:l=typeof IntersectionObserver=="function",animationFrame:d=!1}=r,p=fa(i),h=o||a?[...p?vr(p):[],...vr(t)]:[];h.forEach(I=>{o&&I.addEventListener("scroll",e,{passive:!0}),a&&I.addEventListener("resize",e)});let b=p&&l?Tm(p,e):null,x=-1,y=null;s&&(y=new ResizeObserver(I=>{let[k]=I;k&&k.target===p&&y&&(y.unobserve(t),cancelAnimationFrame(x),x=requestAnimationFrame(()=>{var O;(O=y)==null||O.observe(t)})),e()}),p&&!d&&y.observe(p),y.observe(t));let E,A=d?Lt(i):null;d&&C();function C(){let I=Lt(i);A&&(I.x!==A.x||I.y!==A.y||I.width!==A.width||I.height!==A.height)&&e(),A=I,E=requestAnimationFrame(C)}return e(),()=>{var I;h.forEach(k=>{o&&k.removeEventListener("scroll",e),a&&k.removeEventListener("resize",e)}),b==null||b(),(I=y)==null||I.disconnect(),y=null,d&&cancelAnimationFrame(E)}}var ul=Qn;var fl=Jn,bl=jn,gl=el;var vl=Xn;var yl=(i,t,e)=>{let r=new Map,o={platform:Em,...e},a={...o.platform,_c:r};return Zn(i,t,{...o,platform:a})};var xl=f.constructTagName("popover"),de={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"},Rt={CLICK:"click",MOUSEENTER:"mouseenter",FOCUSIN:"focusin",MANUAL:"manual"},eo={TONAL:"tonal",CONTRAST:"contrast"},M={PLACEMENT:de.BOTTOM,TRIGGER:Rt.CLICK,COLOR:eo.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,DISABLE_ARIA_EXPANDED:!1};var El=i=>{class t extends i{constructor(...o){super(...o);this.enabledFocusTrap=M.FOCUS_TRAP;this.enabledPreventScroll=M.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(o){return o.getClientRects().length===0}hasZeroDimensions(o){let{width:a,height:s}=o.getBoundingClientRect(),{offsetWidth:l,offsetHeight:d}=o;return l+d+s+a===0}isNotVisible(o){return this.hasZeroDimensions(o)||this.hasNoClientRects(o)}hasHiddenStyle(o){let{display:a,opacity:s,visibility:l}=o.style;return a==="none"||s==="0"||l==="hidden"||l==="collapse"}hasComputedHidden(o){let a=getComputedStyle(o);return a.visibility==="hidden"||a.height==="0"||a.display==="none"}isHidden(o){return o.hasAttribute("hidden")||o.getAttribute("aria-hidden")==="true"||this.hasHiddenStyle(o)||this.isNotVisible(o)||this.hasComputedHidden(o)}isNotTabbable(o){return o.getAttribute("tabindex")==="-1"}isInteractiveElement(o){return!!(new Set(["BUTTON","DETAILS","EMBED","IFRAME","SELECT","TEXTAREA"]).has(o.tagName)||o instanceof HTMLAnchorElement&&o.hasAttribute("href")||o instanceof HTMLInputElement&&o.type!=="hidden"||(o instanceof HTMLAudioElement||o instanceof HTMLVideoElement)&&o.hasAttribute("controls")||(o instanceof HTMLImageElement||o instanceof HTMLObjectElement)&&o.hasAttribute("usemap")||o.hasAttribute("tabindex")&&o.tabIndex>-1)}isFocusable(o){return this.isHidden(o)||this.isNotTabbable(o)?!1:this.isInteractiveElement(o)}findFocusable(o,a=new Set){return o instanceof HTMLElement&&this.isFocusable(o)&&a.add(o),Array.from(o.children).forEach(l=>{let d=l;this.isFocusable(d)&&a.add(d),d.shadowRoot?this.findFocusable(d.shadowRoot,a):d.tagName==="SLOT"?d.assignedElements({flatten:!0}).forEach(h=>{h instanceof HTMLElement&&this.findFocusable(h,a)}):this.findFocusable(d,a)}),[...a]}setFocusableElements(){this.shadowRoot&&(this.focusableElements=this.findFocusable(this.shadowRoot,new Set))}setInitialFocus(o=0){this.focusableElements.length!==0&&(this.enabledPreventScroll&&(document.body.style.overflow="hidden"),this.focusableElements[o]&&(this.focusTrapIndex=o,this.focusableElements[o].focus()))}calculateNextIndex(o,a){let{length:s}=this.focusableElements,l=this.shouldWrapFocus();if(o===-1)return a>0?0:s-1;let d=o+a;return l?(d<0&&(d=s-1),d>=s&&(d=0)):(d<0&&(d=0),d>=s&&(d=s-1)),d}getDeepActiveElement(){var a;let o=document.activeElement||document.body;for(;o instanceof HTMLElement&&((a=o.shadowRoot)!=null&&a.activeElement);)o=o.shadowRoot.activeElement;return o||document.body}findElement(o){return this.focusableElements.findIndex(a=>this.isEqualFocusNode(o,a))}isEqualFocusNode(o,a){return o.nodeType>=0?a.isEqualNode(o)&&a===o:!1}trapFocus(o){if(this.focusableElements.length===0)return;let a=this.getDeepActiveElement(),s=this.findElement(a);o?this.focusTrapIndex=this.calculateNextIndex(s,-1):this.focusTrapIndex=this.calculateNextIndex(s,1);let l=this.focusableElements[this.focusTrapIndex];l&&l.focus()}handleKeydown(o){!this.enabledFocusTrap||!this.focusableElements.length||o.key==="Tab"&&(o.preventDefault(),this.trapFocus(o.shiftKey))}}return n([c({type:Boolean})],t.prototype,"enabledFocusTrap",2),n([c({type:Boolean})],t.prototype,"enabledPreventScroll",2),t};var Ot=class{static dispatchPopoverEvent(t,e){e.dispatchEvent(new CustomEvent(t,{detail:{show:e.visible},composed:!0,bubbles:!0}))}static onShowPopover(t){this.dispatchPopoverEvent("shown",t)}static onHidePopover(t){this.dispatchPopoverEvent("hidden",t)}static onCreatedPopover(t){this.dispatchPopoverEvent("created",t)}static onDestroyedPopover(t){this.dispatchPopoverEvent("destroyed",t)}};var ga=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=[]}},Mt=new ga;var Am=u`
|
1590
2016
|
:host {
|
1591
2017
|
--mdc-popover-arrow-border-radius: 0.1875rem;
|
1592
2018
|
--mdc-popover-arrow-border: 0.0625rem solid var(--mds-color-theme-outline-secondary-normal);
|
@@ -1693,207 +2119,33 @@
|
|
1693
2119
|
border-bottom: none;
|
1694
2120
|
border-left: none;
|
1695
2121
|
border-top-right-radius: var(--mdc-popover-arrow-border-radius);
|
1696
|
-
border-bottom-left-radius: 100%;
|
1697
|
-
}
|
1698
|
-
`,
|
1699
|
-
.popover-backdrop {
|
1700
|
-
position: fixed;
|
1701
|
-
top: 0;
|
1702
|
-
left: 0;
|
1703
|
-
width: 100%;
|
1704
|
-
height: 100%;
|
1705
|
-
background: transparent;
|
1706
|
-
z-index: ${this.popover.zIndex-1};
|
1707
|
-
}
|
1708
|
-
`,e.appendChild(r),this.popover.backdropElement=e}}};var
|
1709
|
-
<div class="popover-hover-bridge"></div>
|
1710
|
-
${this.closeButton?m` <mdc-button
|
1711
|
-
class="popover-close"
|
1712
|
-
prefix-icon="cancel-bold"
|
1713
|
-
variant="tertiary"
|
1714
|
-
size="20"
|
1715
|
-
aria-label=${T(this.closeButtonAriaLabel)||""}
|
1716
|
-
@click="${this.hidePopover}"
|
1717
|
-
></mdc-button>`:g}
|
1718
|
-
${this.showArrow?m`<div class="popover-arrow"></div>`:g}
|
1719
|
-
<div part="popover-content">
|
1720
|
-
<slot></slot>
|
1721
|
-
</div>
|
1722
|
-
`}};L.styles=[...v.styles,...Wn],n([c({type:String,reflect:!0})],L.prototype,"id",2),n([c({type:String,reflect:!0})],L.prototype,"triggerID",2),n([c({type:String,reflect:!0})],L.prototype,"trigger",2),n([c({type:String,reflect:!0})],L.prototype,"placement",2),n([c({type:String,reflect:!0})],L.prototype,"color",2),n([c({type:Boolean,reflect:!0})],L.prototype,"visible",2),n([c({type:Number,reflect:!0})],L.prototype,"offset",2),n([c({type:Boolean,reflect:!0,attribute:"focus-trap"})],L.prototype,"focusTrap",2),n([c({type:Boolean,reflect:!0,attribute:"prevent-scroll"})],L.prototype,"preventScroll",2),n([c({type:Boolean,reflect:!0,attribute:"show-arrow"})],L.prototype,"showArrow",2),n([c({type:Boolean,reflect:!0,attribute:"close-button"})],L.prototype,"closeButton",2),n([c({type:Boolean,reflect:!0})],L.prototype,"interactive",2),n([c({type:String,reflect:!0})],L.prototype,"delay",2),n([c({type:Boolean,reflect:!0,attribute:"hide-on-escape"})],L.prototype,"hideOnEscape",2),n([c({type:Boolean,reflect:!0,attribute:"hide-on-blur"})],L.prototype,"hideOnBlur",2),n([c({type:Boolean,reflect:!0,attribute:"hide-on-outside-click"})],L.prototype,"hideOnOutsideClick",2),n([c({type:Boolean,reflect:!0,attribute:"focus-back-to-trigger"})],L.prototype,"focusBackToTrigger",2),n([c({type:Boolean,reflect:!0})],L.prototype,"backdrop",2),n([c({type:Boolean,reflect:!0})],L.prototype,"flip",2),n([c({type:Boolean,reflect:!0})],L.prototype,"size",2),n([c({type:Number,reflect:!0,attribute:"z-index"})],L.prototype,"zIndex",2),n([c({type:String,reflect:!0,attribute:"append-to"})],L.prototype,"appendTo",2),n([c({type:String,attribute:"close-button-aria-label",reflect:!0})],L.prototype,"closeButtonAriaLabel",2),n([c({type:String,reflect:!0})],L.prototype,"role",2),n([c({type:String,reflect:!0,attribute:"aria-labelledby"})],L.prototype,"ariaLabelledby",2),n([c({type:String,reflect:!0,attribute:"aria-describedby"})],L.prototype,"ariaDescribedby",2),n([c({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],L.prototype,"disableAriaExpanded",2);var Te=L;var Yn=f.constructTagName("coachmark"),kt={COLOR:Zr.CONTRAST,TRIGGER:It.MANUAL,ARROW:!0,CLOSE_BUTTON:!0,DISABLE_ARIA_EXPANDED:!0};var Nt=class extends Te{constructor(){super(...arguments);this.trigger=kt.TRIGGER;this.showArrow=kt.ARROW;this.closeButton=kt.CLOSE_BUTTON;this.disableAriaExpanded=kt.DISABLE_ARIA_EXPANDED}connectedCallback(){super.connectedCallback(),this.color=kt.COLOR,this.showArrow=kt.ARROW}};n([c({type:String,reflect:!0})],Nt.prototype,"trigger",2),n([c({type:Boolean,attribute:"show-arrow"})],Nt.prototype,"showArrow",2),n([c({type:Boolean,reflect:!0,attribute:"close-button"})],Nt.prototype,"closeButton",2),n([c({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],Nt.prototype,"disableAriaExpanded",2);var ji=Nt;ji.register(Yn);var Ud=ji;var Fd=[u`
|
1723
|
-
:host{
|
1724
|
-
display: block;
|
1725
|
-
position: relative;
|
1726
|
-
width: 1rem;
|
1727
|
-
height: 1rem;
|
1728
|
-
margin: 0.125rem 0;
|
1729
|
-
border-radius: 50%;
|
1730
|
-
|
1731
|
-
--mdc-staticradio-inner-circle-size: 0.375rem;
|
1732
|
-
--mdc-staticradio-text-disabled-color: var(--mds-color-theme-text-primary-disabled);
|
1733
|
-
--mdc-staticradio-disabled-border-color: var(--mds-color-theme-outline-primary-disabled);
|
1734
|
-
--mdc-staticradio-normal-border-color: var(--mds-color-theme-outline-input-normal);
|
1735
|
-
--mdc-staticradio-inner-circle-normal-background: var(--mds-color-theme-inverted-text-primary-normal);
|
1736
|
-
--mdc-staticradio-inner-circle-disabled-background: var(--mds-color-theme-inverted-text-primary-disabled);
|
1737
|
-
--mdc-staticradio-control-inactive-color: var(--mds-color-theme-control-inactive-normal);
|
1738
|
-
--mdc-staticradio-control-inactive-disabled-background: var(--mds-color-theme-control-inactive-disabled);
|
1739
|
-
--mdc-staticradio-control-active-color: var(--mds-color-theme-control-active-normal);
|
1740
|
-
--mdc-staticradio-control-active-disabled-background: var(--mds-color-theme-control-active-disabled);
|
1741
|
-
}
|
1742
|
-
|
1743
|
-
.icon:after {
|
1744
|
-
content: "";
|
1745
|
-
position: absolute;
|
1746
|
-
display: none;
|
1747
|
-
}
|
1748
|
-
|
1749
|
-
:host([disabled]) .icon,
|
1750
|
-
:host([disabled][readonly]) .icon {
|
1751
|
-
border-color: var(--mdc-staticradio-disabled-border-color);
|
1752
|
-
background: var(--mdc-staticradio-control-inactive-disabled-background);
|
1753
|
-
}
|
1754
|
-
|
1755
|
-
:host([disabled][checked]) .icon,
|
1756
|
-
:host([disabled][readonly][checked]) .icon {
|
1757
|
-
border: var(--mdc-staticradio-control-active-disabled-background);
|
1758
|
-
background: var(--mdc-staticradio-control-active-disabled-background);
|
1759
|
-
}
|
1760
|
-
|
1761
|
-
:host([disabled][checked]) .icon:after,
|
1762
|
-
:host([disabled][readonly][checked]) .icon:after {
|
1763
|
-
background: var(--mdc-staticradio-inner-circle-disabled-background);
|
1764
|
-
}
|
1765
|
-
|
1766
|
-
.icon {
|
1767
|
-
position: absolute;
|
1768
|
-
top: 0;
|
1769
|
-
left: 0;
|
1770
|
-
width: 1rem;
|
1771
|
-
height: 1rem;
|
1772
|
-
border: 0.0625rem solid var(--mdc-staticradio-normal-border-color);
|
1773
|
-
background-color: var(--mdc-staticradio-control-inactive-color);
|
1774
|
-
border-radius: 50%;
|
1775
|
-
}
|
1776
|
-
|
1777
|
-
:host([checked]) .icon {
|
1778
|
-
border-color: var(--mdc-staticradio-control-active-color);
|
1779
|
-
background-color: var(--mdc-staticradio-control-active-color);
|
1780
|
-
}
|
1781
|
-
|
1782
|
-
:host([checked]) .icon:after {
|
1783
|
-
display: block;
|
1784
|
-
top: 50%;
|
1785
|
-
left: 50%;
|
1786
|
-
transform: translate(-50%, -50%);
|
1787
|
-
width: var(--mdc-staticradio-inner-circle-size);
|
1788
|
-
height: var(--mdc-staticradio-inner-circle-size);
|
1789
|
-
border-radius: 50%;
|
1790
|
-
background: var(--mdc-staticradio-inner-circle-normal-background);
|
1791
|
-
}
|
1792
|
-
|
1793
|
-
:host([readonly]) .icon{
|
1794
|
-
border-color: var(--mdc-staticradio-normal-border-color);
|
1795
|
-
background-color: var(--mdc-staticradio-control-inactive-color);
|
1796
|
-
}
|
1797
|
-
|
1798
|
-
:host([readonly][checked]) .icon {
|
1799
|
-
border-color: var(--mdc-staticradio-normal-border-color);
|
1800
|
-
}
|
1801
|
-
|
1802
|
-
:host([readonly][checked]) .icon:after{
|
1803
|
-
background-color: var(--mdc-staticradio-text-disabled-color);
|
1804
|
-
}
|
1805
|
-
`],qn=Fd;var mr=class extends H(v){constructor(){super(...arguments);this.checked=!1;this.readonly=!1}render(){return m`
|
1806
|
-
<slot></slot>
|
1807
|
-
<span part="radio-icon" class="icon"></span>`}};mr.styles=[...v.styles,...qn],n([c({type:Boolean,reflect:!0})],mr.prototype,"checked",2),n([c({type:Boolean,reflect:!0})],mr.prototype,"readonly",2);var Qi=mr;var Zn=f.constructTagName("staticradio");Qi.register(Zn);var Bd=Qi;var Xn=f.constructTagName("statictoggle"),Hd={DEFAULT:"default",COMPACT:"compact"},Ji={CHECKED:"check-bold",UNCHECKED:"cancel-bold"},Kn={compact:.75,default:1.25},jn={SIZE:Hd.DEFAULT};var Gd=[u`
|
1808
|
-
:host {
|
1809
|
-
--mdc-statictoggle-width: 3rem;
|
1810
|
-
--mdc-statictoggle-height: 1.5rem;
|
1811
|
-
--mdc-statictoggle-width-compact: 2rem;
|
1812
|
-
--mdc-statictoggle-height-compact: 1rem;
|
1813
|
-
--mdc-statictoggle-border-radius: 0.75rem;
|
1814
|
-
--mdc-statictoggle-border-radius-compact: 0.5rem;
|
1815
|
-
--mdc-statictoggle-border: 1px solid var(--mds-color-theme-outline-input-normal);
|
1816
|
-
|
1817
|
-
--mdc-statictoggle-inactive-rest-color: var(--mds-color-theme-control-inactive-normal);
|
1818
|
-
--mdc-statictoggle-inactive-disabled-color: var(--mds-color-theme-control-inactive-disabled);
|
1819
|
-
--mdc-statictoggle-active-rest-color: var(--mds-color-theme-control-active-normal);
|
1820
|
-
--mdc-statictoggle-active-disabled-color: var(--mds-color-theme-control-active-disabled);
|
1821
|
-
|
1822
|
-
--mdc-statictoggle-icon-color-normal: var(--mds-color-theme-common-inverted-text-primary-normal);
|
1823
|
-
--mdc-statictoggle-icon-color-disabled: var(--mds-color-theme-common-inverted-text-primary-disabled);
|
1824
|
-
--mdc-statictoggle-icon-background-color-normal: var(--mds-color-theme-common-text-primary-normal);
|
1825
|
-
--mdc-statictoggle-icon-background-color-disabled: var(--mds-color-theme-common-text-primary-disabled);
|
1826
|
-
|
1827
|
-
border-radius: var(--mdc-statictoggle-border-radius);
|
1828
|
-
}
|
1829
|
-
|
1830
|
-
:host::part(slider) {
|
1831
|
-
width: var(--mdc-statictoggle-width);
|
1832
|
-
height: var(--mdc-statictoggle-height);
|
1833
|
-
background: var(--mdc-statictoggle-inactive-rest-color);
|
1834
|
-
border-radius: var(--mdc-statictoggle-border-radius);
|
1835
|
-
border: var(--mdc-statictoggle-border);
|
1836
|
-
display: flex;
|
1837
|
-
align-items: center;
|
1838
|
-
justify-content: flex-start;
|
1839
|
-
transition: background-color 0.3s ease;
|
1840
|
-
outline: none;
|
1841
|
-
padding: 1px;
|
1842
|
-
}
|
1843
|
-
|
1844
|
-
:host([checked])::part(slider) {
|
1845
|
-
background-color: var(--mdc-statictoggle-active-rest-color);
|
1846
|
-
justify-content: flex-end;
|
1847
|
-
border-color: transparent;
|
1848
|
-
}
|
1849
|
-
|
1850
|
-
:host([size='compact'])::part(slider) {
|
1851
|
-
width: var(--mdc-statictoggle-width-compact);
|
1852
|
-
height: var(--mdc-statictoggle-height-compact);
|
1853
|
-
border-radius: var(--mdc-statictoggle-border-radius-compact);
|
1854
|
-
}
|
1855
|
-
|
1856
|
-
.icon {
|
1857
|
-
padding: 0.25rem;
|
1858
|
-
--mdc-icon-fill-color: var(--mdc-statictoggle-icon-color-normal);
|
1859
|
-
background-color: var(--mdc-statictoggle-icon-background-color-normal);
|
1860
|
-
border-radius: 50%;
|
1861
|
-
}
|
1862
|
-
|
1863
|
-
:host([disabled]) .icon {
|
1864
|
-
--mdc-icon-fill-color: var(--mdc-statictoggle-icon-color-disabled);
|
1865
|
-
background-color: var(--mdc-statictoggle-icon-background-color-disabled);
|
1866
|
-
}
|
1867
|
-
|
1868
|
-
:host([size='compact']) .icon {
|
1869
|
-
padding: 0.125rem;
|
1870
|
-
}
|
1871
|
-
|
1872
|
-
:host([disabled])::part(slider) {
|
1873
|
-
background-color: var(--mdc-statictoggle-inactive-disabled-color);
|
1874
|
-
}
|
1875
|
-
|
1876
|
-
:host([disabled][checked])::part(slider) {
|
1877
|
-
background-color: var(--mdc-statictoggle-active-disabled-color);
|
1878
|
-
}
|
1879
|
-
|
1880
|
-
/* High Contrast Mode */
|
1881
|
-
@media (forced-colors: active) {
|
1882
|
-
:host([checked])::part(slider), .icon {
|
1883
|
-
border: var(--mdc-statictoggle-border);
|
1884
|
-
}
|
1885
|
-
}
|
1886
|
-
`],Qn=Gd;var pr=class extends H(v){constructor(){super(...arguments);this.checked=!1;this.size=jn.SIZE}render(){return m`
|
1887
|
-
<slot></slot>
|
1888
|
-
<div part="slider">
|
1889
|
-
<mdc-icon
|
1890
|
-
name="${this.checked?Ji.CHECKED:Ji.UNCHECKED}"
|
1891
|
-
class="icon"
|
1892
|
-
length-unit="rem"
|
1893
|
-
size="${Kn[this.size]}"
|
1894
|
-
></mdc-icon>
|
2122
|
+
border-bottom-left-radius: 100%;
|
2123
|
+
}
|
2124
|
+
`,Tl=[Am];var ri=class{constructor(t){this.arrowPixelChange=!1;this.popover=t}setupDelay(){try{let[t,e]=this.popover.delay.split(",").map(r=>{let o=parseInt(r,10);if(Number.isNaN(o)||o<0)throw new Error(`Invalid delay value: ${r}`);return o});return[t,e]}catch{return this.popover.delay="0,0",[0,0]}}setupHoverBridge(t){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)`,o=this.popover.offsetHeight||0,a=this.popover.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=`${a}px`;break;case"left":e.style.height=`${o}px`,e.style.width=r,e.style.right=`calc(-1.5 * (${r}))`;break;case"right":e.style.height=`${o}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=`${a}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.role==="dialog"||this.popover.role==="alertdialog")&&this.popover.toggleAttribute("aria-modal",this.popover.interactive),this.popover.interactive?(this.popover.setAttribute("aria-modal","true"),this.popover.ariaLabel||(this.popover.ariaLabel=((t=this.popover.triggerElement)==null?void 0:t.ariaLabel)||((e=this.popover.triggerElement)==null?void 0:e.textContent)||""),this.popover.ariaLabelledby||(this.popover.ariaLabelledby=((r=this.popover.triggerElement)==null?void 0:r.id)||"")):this.popover.removeAttribute("aria-modal")}updateAriaHasPopupAttribute(){var t,e,r;this.popover.interactive?(e=this.popover.triggerElement)==null||e.setAttribute("aria-haspopup",((t=this.popover.triggerElement)==null?void 0:t.getAttribute("aria-haspopup"))||"dialog"):(r=this.popover.triggerElement)==null||r.removeAttribute("aria-haspopup")}updateAriaExpandedAttribute(){var t,e;this.popover.disableAriaExpanded?(t=this.popover.triggerElement)==null||t.removeAttribute("aria-expanded"):(e=this.popover.triggerElement)==null||e.setAttribute("aria-expanded",`${this.popover.visible}`)}updateArrowStyle(t,e){var h;if(!this.popover.arrowElement)return;let r=e.split("-")[0],o={top:"bottom",right:"left",bottom:"top",left:"right"}[r],{x:a,y:s}=t,l=this.popover.arrowElement.getBoundingClientRect(),d=(h=this.popover.arrowElement.offsetParent)==null?void 0:h.getBoundingClientRect();if(!this.arrowPixelChange){let b=d!=null&&d[o]?12-Math.abs(l[o]-d[o]):0;Math.round(b)===1?this.arrowPixelChange=!0:this.arrowPixelChange=!1}let p=this.arrowPixelChange?.5:0;this.popover.arrowElement.setAttribute("data-side",r),Object.assign(this.popover.arrowElement.style,{left:a!=null?`${a}px`:"",top:s!=null?`${s}px`:"",[o]:`${-this.popover.arrowElement.offsetHeight/2-p}px`})}updatePopoverStyle(t,e){Object.assign(this.popover.style,{left:`${t}px`,top:`${e}px`})}createBackdrop(){var t;if(!this.popover.backdropElement){let e=document.createElement("div");e.classList.add("popover-backdrop"),(t=this.popover.parentElement)==null||t.appendChild(e);let r=document.createElement("style");r.textContent=`
|
2125
|
+
.popover-backdrop {
|
2126
|
+
position: fixed;
|
2127
|
+
top: 0;
|
2128
|
+
left: 0;
|
2129
|
+
width: 100%;
|
2130
|
+
height: 100%;
|
2131
|
+
background: transparent;
|
2132
|
+
z-index: ${this.popover.zIndex-1};
|
2133
|
+
}
|
2134
|
+
`,e.appendChild(r),this.popover.backdropElement=e}}};var R=class extends El(v){constructor(){super();this.id="";this.triggerID="";this.trigger=M.TRIGGER;this.placement=M.PLACEMENT;this.color=M.COLOR;this.visible=M.VISIBLE;this.offset=M.OFFSET;this.focusTrap=M.FOCUS_TRAP;this.preventScroll=M.PREVENT_SCROLL;this.showArrow=M.ARROW;this.closeButton=M.CLOSE_BUTTON;this.interactive=M.INTERACTIVE;this.delay=M.DELAY;this.hideOnEscape=M.HIDE_ON_ESCAPE;this.hideOnBlur=M.HIDE_ON_BLUR;this.hideOnOutsideClick=M.HIDE_ON_CLICK_OUTSIDE;this.focusBackToTrigger=M.FOCUS_BACK;this.backdrop=M.BACKDROP;this.flip=M.FLIP;this.size=M.SIZE;this.zIndex=M.Z_INDEX;this.appendTo="";this.closeButtonAriaLabel=null;this.role=M.ROLE;this.ariaLabelledby=null;this.ariaDescribedby=null;this.disableAriaExpanded=M.DISABLE_ARIA_EXPANDED;this.arrowElement=null;this.triggerElement=null;this.hoverTimer=null;this.isTriggerClicked=!1;this.openDelay=0;this.closeDelay=0;this.backdropElement=null;this.onOutsidePopoverClick=e=>{if(Mt.peek()!==this)return;let r=!1,o=e.composedPath();r=this.contains(e.target)||o.includes(this.triggerElement);let a=this.backdropElement?o.includes(this.backdropElement):!1;(!r||a)&&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},this.openDelay)};this.hidePopover=()=>{Mt.peek()===this&&setTimeout(()=>{this.visible=!1,this.isTriggerClicked=!1},this.closeDelay)};this.togglePopoverVisible=()=>{this.isTriggerClicked?this.hidePopover():(this.showPopover(),this.isTriggerClicked=!0)};this.utils=new ri(this)}async firstUpdated(e){super.firstUpdated(e),this.utils.setupAppendTo(),[this.openDelay,this.closeDelay]=this.utils.setupDelay(),this.setupTriggerListener(),this.utils.setupAccessibility(),this.style.zIndex=`${this.zIndex}`,Ot.onCreatedPopover(this),this.visible&&(this.positionPopover(),await this.handleCreatePopoverFirstUpdate())}async disconnectedCallback(){super.disconnectedCallback(),this.removeEventListeners(),Ot.onDestroyedPopover(this),Mt.remove(this)}setupTriggerListener(){if(this.triggerID&&(this.triggerElement=this.getRootNode().querySelector(`[id="${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 e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.addEventListener("mouseenter",this.showPopover),this.triggerElement.addEventListener("mouseleave",this.startCloseDelay),this.addEventListener("mouseenter",this.cancelCloseDelay),this.addEventListener("mouseleave",this.startCloseDelay),e==null||e.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(){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),this.removeEventListener("mouseenter",this.cancelCloseDelay),this.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")||!1;await this.isOpenUpdated(r,this.visible),this.utils.updateAriaExpandedAttribute()}if(e.has("placement")&&this.setAttribute("placement",Object.values(de).includes(this.placement)?this.placement:M.PLACEMENT),e.has("delay")&&([this.openDelay,this.closeDelay]=this.utils.setupDelay()),e.has("trigger")){let o=this.trigger.split(" ").filter(a=>Object.values(Rt).includes(a));this.setAttribute("trigger",o.length>0?this.trigger:M.TRIGGER),this.removeEventListeners(),this.setupTriggerListener()}e.has("color")&&this.setAttribute("color",Object.values(eo).includes(this.color)?this.color:M.COLOR),e.has("zIndex")&&this.setAttribute("z-index",`${this.zIndex}`),e.has("append-to")&&this.utils.setupAppendTo(),(e.has("interactive")||e.has("aria-label")||e.has("aria-labelledby"))&&this.utils.setupAccessibility(),e.has("disableAriaExpanded")&&this.utils.updateAriaExpandedAttribute(),e.has("interactive")&&this.utils.updateAriaHasPopupAttribute()}async isOpenUpdated(e,r){var o,a,s;if(!(e===r||!this.triggerElement))if(r)Mt.peek()!==this&&Mt.push(this),this.enabledFocusTrap=this.focusTrap,this.enabledPreventScroll=this.preventScroll,this.backdrop&&(this.utils.createBackdrop(),this.triggerElement.style.zIndex=`${this.zIndex}`),this.positionPopover(),await this.handleCreatePopoverFirstUpdate(),this.hideOnBlur&&(this.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),Ot.onShowPopover(this);else{if(Mt.pop(),this.backdropElement&&((o=this.backdropElement)==null||o.remove(),this.backdropElement=null),this.hideOnBlur&&(this.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),(a=this.deactivateFocusTrap)==null||a.call(this),this.disableAriaExpanded||this.triggerElement.removeAttribute("aria-expanded"),this.interactive){let l=this.triggerElement.getAttribute("aria-haspopup");(l==="dialog"||l==="alertdialog")&&this.triggerElement.removeAttribute("aria-haspopup")}this.focusBackToTrigger&&((s=this.triggerElement)==null||s.focus()),Ot.onHidePopover(this)}}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)return;let e=[fl()],r=this.offset;if(this.flip&&e.push(bl()),this.size){let o=this.renderRoot.querySelector('[part="popover-content"]');e.push(gl({apply({availableHeight:a}){o&&Object.assign(o.style,{maxHeight:`${a}px`,overflowY:"auto"})},padding:50}))}if(this.showArrow&&(this.arrowElement=this.renderRoot.querySelector(".popover-arrow"),this.arrowElement)){let o=this.arrowElement.offsetHeight;r=Math.sqrt(2*o**2)/2+this.offset,e.push(vl({element:this.arrowElement,padding:12}))}e.push(ul(r)),hl(this.triggerElement,this,async()=>{if(!this.triggerElement)return;let{x:o,y:a,middlewareData:s,placement:l}=await yl(this.triggerElement,this,{placement:this.placement,middleware:e});this.utils.updatePopoverStyle(o,a),s.arrow&&this.arrowElement&&this.utils.updateArrowStyle(s.arrow,l),this.trigger.includes("mouseenter")&&this.utils.setupHoverBridge(l)})}render(){return m`
|
2135
|
+
<div class="popover-hover-bridge"></div>
|
2136
|
+
${this.closeButton?m` <mdc-button
|
2137
|
+
class="popover-close"
|
2138
|
+
prefix-icon="cancel-bold"
|
2139
|
+
variant="tertiary"
|
2140
|
+
size="20"
|
2141
|
+
aria-label=${T(this.closeButtonAriaLabel)||""}
|
2142
|
+
@click="${this.hidePopover}"
|
2143
|
+
></mdc-button>`:g}
|
2144
|
+
${this.showArrow?m`<div class="popover-arrow"></div>`:g}
|
2145
|
+
<div part="popover-content">
|
2146
|
+
<slot></slot>
|
1895
2147
|
</div>
|
1896
|
-
`}};
|
2148
|
+
`}};R.styles=[...v.styles,...Tl],n([c({type:String,reflect:!0})],R.prototype,"id",2),n([c({type:String,reflect:!0})],R.prototype,"triggerID",2),n([c({type:String,reflect:!0})],R.prototype,"trigger",2),n([c({type:String,reflect:!0})],R.prototype,"placement",2),n([c({type:String,reflect:!0})],R.prototype,"color",2),n([c({type:Boolean,reflect:!0})],R.prototype,"visible",2),n([c({type:Number,reflect:!0})],R.prototype,"offset",2),n([c({type:Boolean,reflect:!0,attribute:"focus-trap"})],R.prototype,"focusTrap",2),n([c({type:Boolean,reflect:!0,attribute:"prevent-scroll"})],R.prototype,"preventScroll",2),n([c({type:Boolean,reflect:!0,attribute:"show-arrow"})],R.prototype,"showArrow",2),n([c({type:Boolean,reflect:!0,attribute:"close-button"})],R.prototype,"closeButton",2),n([c({type:Boolean,reflect:!0})],R.prototype,"interactive",2),n([c({type:String,reflect:!0})],R.prototype,"delay",2),n([c({type:Boolean,reflect:!0,attribute:"hide-on-escape"})],R.prototype,"hideOnEscape",2),n([c({type:Boolean,reflect:!0,attribute:"hide-on-blur"})],R.prototype,"hideOnBlur",2),n([c({type:Boolean,reflect:!0,attribute:"hide-on-outside-click"})],R.prototype,"hideOnOutsideClick",2),n([c({type:Boolean,reflect:!0,attribute:"focus-back-to-trigger"})],R.prototype,"focusBackToTrigger",2),n([c({type:Boolean,reflect:!0})],R.prototype,"backdrop",2),n([c({type:Boolean,reflect:!0})],R.prototype,"flip",2),n([c({type:Boolean,reflect:!0})],R.prototype,"size",2),n([c({type:Number,reflect:!0,attribute:"z-index"})],R.prototype,"zIndex",2),n([c({type:String,reflect:!0,attribute:"append-to"})],R.prototype,"appendTo",2),n([c({type:String,attribute:"close-button-aria-label",reflect:!0})],R.prototype,"closeButtonAriaLabel",2),n([c({type:String,reflect:!0})],R.prototype,"role",2),n([c({type:String,reflect:!0,attribute:"aria-labelledby"})],R.prototype,"ariaLabelledby",2),n([c({type:String,reflect:!0,attribute:"aria-describedby"})],R.prototype,"ariaDescribedby",2),n([c({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],R.prototype,"disableAriaExpanded",2);var Ie=R;var Al=f.constructTagName("coachmark"),Dt={COLOR:eo.CONTRAST,TRIGGER:Rt.MANUAL,ARROW:!0,CLOSE_BUTTON:!0,DISABLE_ARIA_EXPANDED:!0};var $t=class extends Ie{constructor(){super(...arguments);this.trigger=Dt.TRIGGER;this.showArrow=Dt.ARROW;this.closeButton=Dt.CLOSE_BUTTON;this.disableAriaExpanded=Dt.DISABLE_ARIA_EXPANDED}connectedCallback(){super.connectedCallback(),this.color=Dt.COLOR,this.showArrow=Dt.ARROW}};n([c({type:String,reflect:!0})],$t.prototype,"trigger",2),n([c({type:Boolean,attribute:"show-arrow"})],$t.prototype,"showArrow",2),n([c({type:Boolean,reflect:!0,attribute:"close-button"})],$t.prototype,"closeButton",2),n([c({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],$t.prototype,"disableAriaExpanded",2);var va=$t;va.register(Al);var Sm=va;var Sl=f.constructTagName("divider"),to={HORIZONTAL:"horizontal",VERTICAL:"vertical"},ya={SOLID:"solid",GRADIENT:"gradient"},ct={POSITIVE:"positive",NEGATIVE:"negative"},ro={UP:"arrow-up-regular",DOWN:"arrow-down-regular",LEFT:"arrow-left-regular",RIGHT:"arrow-right-regular"},zt={ORIENTATION:to.HORIZONTAL,VARIANT:ya.SOLID,ARROW_DIRECTION:ct.NEGATIVE,BUTTON_DIRECTION:ct.NEGATIVE};var Im=[N,u`
|
1897
2149
|
:host {
|
1898
2150
|
--mdc-divider-background-color: var(--mds-color-theme-outline-secondary-normal);
|
1899
2151
|
--mdc-divider-width: 0.0625rem;
|
@@ -2104,11 +2356,11 @@
|
|
2104
2356
|
font-size: var(--mdc-divider-text-size);
|
2105
2357
|
line-height: var(--mdc-divider-text-line-height);
|
2106
2358
|
}
|
2107
|
-
`],
|
2359
|
+
`],Il=Im;var dt=class extends v{constructor(){super(...arguments);this.orientation=zt.ORIENTATION;this.variant=zt.VARIANT;this.arrowDirection=zt.ARROW_DIRECTION;this.buttonPosition=zt.BUTTON_DIRECTION}setVariant(e){this.setAttribute("variant",Object.values(ya).includes(e)?e:zt.VARIANT)}setOrientation(e){this.setAttribute("orientation",Object.values(to).includes(e)?e:zt.ORIENTATION)}ensureValidDirections(){let e=this.orientation===to.HORIZONTAL?ct.NEGATIVE:ct.POSITIVE;Object.values(ct).includes(this.buttonPosition)||(this.buttonPosition=e),Object.values(ct).includes(this.arrowDirection)||(this.arrowDirection=e)}setGrabberButton(){this.ensureValidDirections();let e=this.querySelector("mdc-button");if(e){let r=this.getArrowIcon();e.setAttribute("variant","secondary"),e.setAttribute("prefix-icon",r)}}getArrowIcon(){let e=this.orientation===to.HORIZONTAL,r=this.arrowDirection===ct.POSITIVE;return e?r?ro.UP:ro.DOWN:r?ro.RIGHT:ro.LEFT}update(e){super.update(e),e.has("orientation")&&this.setOrientation(this.orientation),e.has("variant")&&this.setVariant(this.variant),(e.has("orientation")||e.has("arrowDirection")||e.has("buttonPosition"))&&this.setGrabberButton()}inferDividerType(){var s;let e=(s=this.shadowRoot)==null?void 0:s.querySelector("slot"),r=(e==null?void 0:e.assignedElements({flatten:!0}))||[];if(r.length>1)return;let o=r.some(l=>l.tagName===Vr.toUpperCase()),a=r.some(l=>l.tagName===Et.toUpperCase());o&&!a?this.setAttribute("data-type","mdc-text-divider"):!o&&a&&(this.setAttribute("data-type","mdc-grabber-divider"),this.setGrabberButton())}connectedCallback(){super.connectedCallback(),this.setAttribute("data-type","mdc-primary-divider")}render(){return m`
|
2108
2360
|
<div></div>
|
2109
2361
|
<slot @slotchange=${this.inferDividerType}></slot>
|
2110
2362
|
<div></div>
|
2111
|
-
`}};
|
2363
|
+
`}};dt.styles=[...v.styles,...Il],n([c({type:String,reflect:!0})],dt.prototype,"orientation",2),n([c({type:String,reflect:!0})],dt.prototype,"variant",2),n([c({type:String,attribute:"arrow-direction",reflect:!0})],dt.prototype,"arrowDirection",2),n([c({type:String,attribute:"button-position",reflect:!0})],dt.prototype,"buttonPosition",2);var xa=dt;xa.register(Sl);var Cm=xa;var km=u`
|
2112
2364
|
:host([selected]){
|
2113
2365
|
border: 2px solid;
|
2114
2366
|
--mdc-chip-background-color: var(--mds-color-theme-background-label-default-active);
|
@@ -2128,7 +2380,7 @@
|
|
2128
2380
|
--mdc-chip-color: var(--mds-color-theme-text-primary-disabled);
|
2129
2381
|
cursor: auto;
|
2130
2382
|
}
|
2131
|
-
`,
|
2383
|
+
`,Cl=[km];var kl=f.constructTagName("filterchip"),Ea={ICON_NAME:"check-bold",COLOR:"default"};var oo=class extends gr{constructor(){super(...arguments);this.selected=!1}connectedCallback(){super.connectedCallback(),this.color=Ea.COLOR}setSelected(e){e?(this.iconName=Ea.ICON_NAME,this.setAttribute("aria-pressed","true")):(this.iconName=void 0,this.setAttribute("aria-pressed","false"))}executeAction(){this.selected=!this.selected}update(e){super.update(e),e.has("selected")&&this.setSelected(this.selected)}};oo.styles=[...gr.styles,...Cl],n([c({type:Boolean,reflect:!0})],oo.prototype,"selected",2);var Ta=oo;Ta.register(kl);var wm=Ta;var wl=f.constructTagName("formfieldgroup"),Aa={RADIOGROUP:"radiogroup",GROUP:"group"};var Nm=u`
|
2132
2384
|
|
2133
2385
|
:host::part(container) {
|
2134
2386
|
display: flex;
|
@@ -2145,10 +2397,10 @@
|
|
2145
2397
|
:host::part(label-text){
|
2146
2398
|
font-weight: bold;
|
2147
2399
|
}
|
2148
|
-
`,
|
2400
|
+
`,Nl=[Nm];var oi=class extends U(J){constructor(){super(...arguments);this.isRadio=!1}connectedCallback(){super.connectedCallback(),this.shouldRenderLabel=!1,this.id="",this.helpTextType=void 0,this.disabled=void 0}render(){var e;return m`
|
2149
2401
|
<div
|
2150
2402
|
part="container"
|
2151
|
-
role="${this.isRadio?
|
2403
|
+
role="${this.isRadio?Aa.RADIOGROUP:Aa.GROUP}"
|
2152
2404
|
aria-labelledby="${V.HEADING_ID}"
|
2153
2405
|
aria-describedby="${T(this.helpText?V.HELPER_TEXT_ID:"")}"
|
2154
2406
|
aria-label="${(e=this.dataAriaLabel)!=null?e:""}"
|
@@ -2159,7 +2411,7 @@
|
|
2159
2411
|
</div>
|
2160
2412
|
<slot></slot>
|
2161
2413
|
</div>
|
2162
|
-
`}};
|
2414
|
+
`}};oi.styles=[...J.styles,...Nl];var Sa=oi;Sa.register(wl);var ii=Sa;Ur.register(No);var _m=Ur;var Lm=[u`
|
2163
2415
|
:host{
|
2164
2416
|
--mdc-input-disabled-border-color: var(--mds-color-theme-outline-primary-disabled);
|
2165
2417
|
--mdc-input-disabled-text-color: var(--mds-color-theme-text-primary-disabled);
|
@@ -2275,30 +2527,30 @@
|
|
2275
2527
|
opacity: 0;
|
2276
2528
|
pointer-events: none;
|
2277
2529
|
}
|
2278
|
-
`,...
|
2530
|
+
`,..._(!0)],_l=Lm;J.register(Vn);var be=J;var Ll=f.constructTagName("input"),ai={OFF:"off",NONE:"none",ON:"on",SENTENCES:"sentences",WORDS:"words",CHARACTERS:"characters"},Ia={OFF:"off",ON:"on"},Ca={TEXT:"text",SEARCH:"search"},Rl={MAX_LENGTH:10,VALIDATION:W.ERROR},Ze={VALIDATION:W.DEFAULT,ICON_SIZE_VALUE:1,ICON_SIZE_UNIT:"rem",CLEAR_BUTTON_ICON:"cancel-bold",CLEAR_BUTTON_VARIANT:ie.TERTIARY,CLEAR_BUTTON_SIZE:ar[20],PREFIX_TEXT_TYPE:S.BODY_MIDSIZE_REGULAR,PREFIX_TEXT_TAG:w.SPAN,AUTO_COMPLETE:Ia.OFF,INPUT_TYPE:Ca.TEXT};var F=class extends se(U(be)){constructor(){super(...arguments);this.placeholder="";this.readonly=!1;this.trailingButton=!1;this.autocapitalize=ai.OFF;this.autocomplete=Ia.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.requiredLabel&&this.validationMessage&&this.value===""?this.inputElement.setCustomValidity(this.validationMessage):this.inputElement.setCustomValidity(""),this.setValidity()}attributeChangedCallback(e,r,o){super.attributeChangedCallback(e,r,o),["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?m`
|
2279
2531
|
<mdc-icon
|
2280
2532
|
class="leading-icon"
|
2281
2533
|
part="leading-icon"
|
2282
2534
|
name=${this.leadingIcon}
|
2283
|
-
size="${
|
2284
|
-
length-unit="${
|
2535
|
+
size="${Ze.ICON_SIZE_VALUE}"
|
2536
|
+
length-unit="${Ze.ICON_SIZE_UNIT}">
|
2285
2537
|
</mdc-icon>
|
2286
2538
|
`:g}renderPrefixText(){return this.prefixText?m`
|
2287
2539
|
<mdc-text
|
2288
2540
|
class="prefix-text"
|
2289
|
-
tagname="${
|
2290
|
-
type="${
|
2541
|
+
tagname="${Ze.PREFIX_TEXT_TAG}"
|
2542
|
+
type="${Ze.PREFIX_TEXT_TYPE}"
|
2291
2543
|
aria-hidden="true"
|
2292
2544
|
>
|
2293
|
-
${this.prefixText.slice(0,
|
2545
|
+
${this.prefixText.slice(0,Rl.MAX_LENGTH)}
|
2294
2546
|
</mdc-text>
|
2295
2547
|
`:g}clearInputText(){var e;this.value="",(e=this.inputElement)==null||e.focus()}renderTrailingButton(e=!1){let r=e||this.value&&this.trailingButton;return r?m`
|
2296
2548
|
<mdc-button
|
2297
2549
|
part='trailing-button'
|
2298
2550
|
class='own-focus-ring ${r?"":"hidden"}'
|
2299
|
-
prefix-icon='${
|
2300
|
-
variant='${
|
2301
|
-
size="${
|
2551
|
+
prefix-icon='${Ze.CLEAR_BUTTON_ICON}'
|
2552
|
+
variant='${Ze.CLEAR_BUTTON_VARIANT}'
|
2553
|
+
size="${Ze.CLEAR_BUTTON_SIZE}"
|
2302
2554
|
aria-label="${this.clearAriaLabel}"
|
2303
2555
|
@click=${this.clearInputText}
|
2304
2556
|
?disabled=${this.disabled||this.readonly||!r}
|
@@ -2335,12 +2587,12 @@
|
|
2335
2587
|
<slot name="input-leading-icon">${this.renderLeadingIcon()}</slot>
|
2336
2588
|
<div class="input-section" part="input-section">
|
2337
2589
|
<slot name="input-prefix-text">${this.renderPrefixText()}</slot>
|
2338
|
-
<slot name="input">${this.renderInputElement(
|
2590
|
+
<slot name="input">${this.renderInputElement(Ze.INPUT_TYPE)}</slot>
|
2339
2591
|
</div>
|
2340
2592
|
<slot name="trailing-button">${this.renderTrailingButton()}</slot>
|
2341
2593
|
</div>
|
2342
2594
|
${this.helpText?this.renderHelperText():g}
|
2343
|
-
`}};
|
2595
|
+
`}};F.styles=[...be.styles,..._l],n([c({type:String})],F.prototype,"placeholder",2),n([c({type:Boolean})],F.prototype,"readonly",2),n([c({type:String,attribute:"prefix-text"})],F.prototype,"prefixText",2),n([c({type:String,attribute:"leading-icon"})],F.prototype,"leadingIcon",2),n([c({type:Boolean,attribute:"trailing-button"})],F.prototype,"trailingButton",2),n([c({type:Number})],F.prototype,"maxlength",2),n([c({type:Number})],F.prototype,"minlength",2),n([c({type:String})],F.prototype,"autocapitalize",2),n([c({type:String})],F.prototype,"autocomplete",2),n([c({type:Boolean})],F.prototype,"autofocus",2),n([c({type:String})],F.prototype,"dirname",2),n([c({type:String})],F.prototype,"pattern",2),n([c({type:String})],F.prototype,"list",2),n([c({type:Number})],F.prototype,"size",2),n([c({type:String,attribute:"clear-aria-label"})],F.prototype,"clearAriaLabel",2);var Er=F;Er.register(Ll);var Rm=Er;var Om=u`
|
2344
2596
|
:host {
|
2345
2597
|
height: 1.5rem;
|
2346
2598
|
gap: 0.25rem;
|
@@ -2369,24 +2621,24 @@
|
|
2369
2621
|
--mdc-chip-color: var(--mds-color-theme-text-primary-disabled);
|
2370
2622
|
cursor: auto;
|
2371
2623
|
}
|
2372
|
-
`,
|
2624
|
+
`,Ol=[N,Om];var si=f.constructTagName("inputchip"),ni={TEXT_TYPE:S.BODY_MIDSIZE_REGULAR,TAG_NAME:w.SPAN,CLOSE_ICON:"cancel-bold"};var Pt=class extends oe(P(v)){constructor(){super(...arguments);this.label="";this.error=!1;this.clearAriaLabel=""}renderIcon(){return this.iconName?m`
|
2373
2625
|
<mdc-icon
|
2374
2626
|
name="${this.iconName}"
|
2375
2627
|
length-unit="rem"
|
2376
2628
|
size="1"></mdc-icon>
|
2377
2629
|
`:g}handleClose(){this.dispatchEvent(new CustomEvent("remove",{bubbles:!0,composed:!0}))}render(){return m`
|
2378
2630
|
${this.renderIcon()}
|
2379
|
-
<mdc-text part="label" type="${
|
2631
|
+
<mdc-text part="label" type="${ni.TEXT_TYPE}" tagname="${ni.TAG_NAME}">${this.label}</mdc-text>
|
2380
2632
|
<mdc-button
|
2381
2633
|
?disabled="${this.disabled}"
|
2382
2634
|
variant="tertiary"
|
2383
2635
|
part="close-icon"
|
2384
2636
|
aria-label="${this.clearAriaLabel}"
|
2385
|
-
prefix-icon="${
|
2637
|
+
prefix-icon="${ni.CLOSE_ICON}"
|
2386
2638
|
size="20"
|
2387
2639
|
@click="${this.handleClose}"
|
2388
2640
|
></mdc-button>
|
2389
|
-
`}};
|
2641
|
+
`}};Pt.styles=[...v.styles,...Ol],n([c({type:String})],Pt.prototype,"label",2),n([c({type:Boolean})],Pt.prototype,"error",2),n([c({type:String,attribute:"clear-aria-label"})],Pt.prototype,"clearAriaLabel",2);var ka=Pt;ka.register(si);var Mm=ka;var Dm=u`
|
2390
2642
|
:host {
|
2391
2643
|
gap: 0.25rem;
|
2392
2644
|
}
|
@@ -2444,76 +2696,7 @@
|
|
2444
2696
|
text-decoration: var(--mds-font-apps-body-small-regular-underline-text-decoration);
|
2445
2697
|
text-transform: var(--mds-font-apps-body-small-regular-underline-text-case);
|
2446
2698
|
}
|
2447
|
-
`,
|
2448
|
-
:host {
|
2449
|
-
--mdc-link-border-radius: 0.25rem;
|
2450
|
-
--mdc-link-color-active: var(--mds-color-theme-text-accent-active);
|
2451
|
-
--mdc-link-color-disabled: var(--mds-color-theme-text-primary-disabled);
|
2452
|
-
--mdc-link-color-hover: var(--mds-color-theme-text-accent-hover);
|
2453
|
-
--mdc-link-color-normal: var(--mds-color-theme-text-accent-normal);
|
2454
|
-
--mdc-link-inverted-color-active: var(--mds-color-theme-inverted-text-accent-active);
|
2455
|
-
--mdc-link-inverted-color-disabled: var(--mds-color-theme-inverted-text-primary-disabled);
|
2456
|
-
--mdc-link-inverted-color-hover: var(--mds-color-theme-inverted-text-accent-hover);
|
2457
|
-
--mdc-link-inverted-color-normal: var(--mds-color-theme-inverted-text-accent-normal);
|
2458
|
-
|
2459
|
-
border-radius: var(--mdc-link-border-radius);
|
2460
|
-
color: var(--mdc-link-color-normal);
|
2461
|
-
text-underline-offset: auto;
|
2462
|
-
text-underline-position: from-font;
|
2463
|
-
cursor: pointer;
|
2464
|
-
|
2465
|
-
/* based on default linksimple size (large) */
|
2466
|
-
line-height: var(--mds-font-apps-body-large-regular-line-height);
|
2467
|
-
}
|
2468
|
-
|
2469
|
-
:host([inline]) {
|
2470
|
-
display: inline-flex;
|
2471
|
-
}
|
2472
|
-
|
2473
|
-
:host([inverted]) {
|
2474
|
-
color: var(--mdc-link-inverted-color-normal);
|
2475
|
-
}
|
2476
|
-
|
2477
|
-
:host(:hover) {
|
2478
|
-
color: var(--mdc-link-color-hover);
|
2479
|
-
}
|
2480
|
-
|
2481
|
-
:host(:active) {
|
2482
|
-
color: var(--mdc-link-color-active);
|
2483
|
-
box-shadow: none;
|
2484
|
-
}
|
2485
|
-
|
2486
|
-
:host([inverted]:hover) {
|
2487
|
-
color: var(--mdc-link-inverted-color-hover);
|
2488
|
-
}
|
2489
|
-
|
2490
|
-
:host([inverted]:active) {
|
2491
|
-
color: var(--mdc-link-inverted-color-active);
|
2492
|
-
}
|
2493
|
-
|
2494
|
-
:host([disabled]) {
|
2495
|
-
color: var(--mdc-link-color-disabled);
|
2496
|
-
pointer-events: none;
|
2497
|
-
}
|
2498
|
-
|
2499
|
-
:host([inverted][disabled]) {
|
2500
|
-
color: var(--mdc-link-inverted-color-disabled);
|
2501
|
-
}
|
2502
|
-
|
2503
|
-
/* based on default linksimple size (large) */
|
2504
|
-
:host(:hover),
|
2505
|
-
:host(:active),
|
2506
|
-
:host([inline]) {
|
2507
|
-
font-size: var(--mds-font-apps-body-large-regular-underline-font-size);
|
2508
|
-
font-weight: var(--mds-font-apps-body-large-regular-underline-font-weight);
|
2509
|
-
line-height: var(--mds-font-apps-body-large-regular-underline-line-height);
|
2510
|
-
text-decoration: var(--mds-font-apps-body-large-regular-underline-text-decoration);
|
2511
|
-
text-transform: var(--mds-font-apps-body-large-regular-underline-text-case);
|
2512
|
-
}
|
2513
|
-
|
2514
|
-
`,...O()],hl=om;var We=class extends H(Zt(v)){constructor(){super(...arguments);this.inline=da.INLINE;this.inverted=da.INVERTED;this.href="#";this.target="_self";this.prevTabindex=0;this.handleNavigation=e=>{if((e.type==="click"||e instanceof KeyboardEvent&&e.key==="Enter")&&this.href){if(this.disabled)return;window.open(this.href,this.target,this.rel)}}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","link"),this.addEventListener("click",this.handleNavigation),this.addEventListener("keydown",this.handleNavigation)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this.handleNavigation),this.removeEventListener("keydown",this.handleNavigation)}setDisabled(e){e?(this.setAttribute("aria-disabled","true"),this.prevTabindex=this.tabIndex,this.tabIndex=-1):(this.tabIndex===-1&&(this.tabIndex=this.prevTabindex),this.removeAttribute("aria-disabled"))}update(e){super.update(e),e.has("disabled")&&this.setDisabled(this.disabled)}render(){return m`
|
2515
|
-
<slot></slot>
|
2516
|
-
`}};We.styles=[...v.styles,...hl],n([c({type:Boolean,reflect:!0})],We.prototype,"inline",2),n([c({type:Boolean,reflect:!0})],We.prototype,"inverted",2),n([c({type:String,reflect:!0})],We.prototype,"href",2),n([c({type:String,reflect:!0})],We.prototype,"target",2),n([c({type:String,reflect:!0})],We.prototype,"rel",2);var at=We;var Qr=class extends ee(at){constructor(){super(...arguments);this.size=dl.LINK_SIZE}getIconSize(){switch(this.size){case Zo.SMALL:return Xo.SMALL;case Zo.MIDSIZE:return Xo.MIDSIZE;default:return Xo.LARGE}}render(){return m`
|
2699
|
+
`,Ml=[Dm];var io=class extends oe(st){constructor(){super(...arguments);this.size=Cn.LINK_SIZE}getIconSize(){switch(this.size){case Vo.SMALL:return Uo.SMALL;case Vo.MIDSIZE:return Uo.MIDSIZE;default:return Uo.LARGE}}render(){return m`
|
2517
2700
|
<slot></slot>
|
2518
2701
|
${this.iconName?m`
|
2519
2702
|
<mdc-icon
|
@@ -2522,27 +2705,27 @@
|
|
2522
2705
|
length-unit="rem"
|
2523
2706
|
></mdc-icon>
|
2524
2707
|
`:g}
|
2525
|
-
`}};
|
2708
|
+
`}};io.styles=[...st.styles,...Ml],n([c({type:String,reflect:!0})],io.prototype,"size",2);var wa=io;wa.register(Po);var $m=wa;st.register(Tn);var zm=st;var li=f.constructTagName("listitem"),ao={FULL_WIDTH:"full-width",INSET_PILL:"inset-pill",INSET_RECTANGLE:"inset-rectangle"},Dl={VARIANT:ao.FULL_WIDTH};var $l=f.constructTagName("list"),Na="header-id";var Pm=u`
|
2526
2709
|
:host::part(header-text) {
|
2527
2710
|
padding: 0.5rem 0.75rem;
|
2528
2711
|
}
|
2529
|
-
`,
|
2712
|
+
`,zl=[Pm];var $={ARROW_DOWN:"ArrowDown",ARROW_UP:"ArrowUp",END:"End",ENTER:"Enter",ESCAPE:"Escape",HOME:"Home",PAGE_DOWN:"PageDown",PAGE_UP:"PageUp",SPACE:" "};var Tr=class extends U(v){constructor(){super(),this.addEventListener("keydown",this.handleKeyDown)}handleKeyDown(t){var o;let e=this.getCurrentIndex(t.target),r=this.getNewIndexBasedOnKey(t.key,e,this.listItems.length);r!==void 0&&((o=this.listItems[r])==null||o.focus(),this.resetTabIndexAndSetActiveTabIndex(r))}getCurrentIndex(t){return this.listItems.findIndex(e=>e===t||e===t.parentElement)}getNewIndexBasedOnKey(t,e,r){switch(t){case $.ARROW_DOWN:return(e+1)%r;case $.ARROW_UP:return(e-1+r)%r;case $.HOME:return 0;case $.END:return r-1;default:return}}handleMouseClick(t){let e=this.getCurrentIndex(t.target);this.resetTabIndexAndSetActiveTabIndex(e)}resetTabIndexAndSetActiveTabIndex(t){this.listItems.forEach((e,r)=>{let o=t===r?"0":"-1";e==null||e.setAttribute("tabindex",o)})}firstUpdated(){this.resetTabIndexAndSetActiveTabIndex(0)}render(){var e;let t=this.headerText?m`
|
2530
2713
|
<mdc-text
|
2531
|
-
id="${
|
2714
|
+
id="${Na}"
|
2532
2715
|
part="header-text"
|
2533
|
-
type="${
|
2534
|
-
tagname="${
|
2716
|
+
type="${S.BODY_MIDSIZE_BOLD}"
|
2717
|
+
tagname="${w.SPAN}"
|
2535
2718
|
>${this.headerText}</mdc-text>
|
2536
2719
|
`:g;return m`
|
2537
2720
|
<div
|
2538
2721
|
role="list"
|
2539
|
-
aria-labelledby="${this.headerText?
|
2722
|
+
aria-labelledby="${this.headerText?Na:""}"
|
2540
2723
|
aria-label="${(e=this.dataAriaLabel)!=null?e:""}"
|
2541
2724
|
>
|
2542
2725
|
${t}
|
2543
2726
|
<slot role="presentation" @click="${this.handleMouseClick}"></slot>
|
2544
2727
|
</div>
|
2545
|
-
`}};
|
2728
|
+
`}};Tr.styles=[...v.styles,...zl],n([G({selector:li})],Tr.prototype,"listItems",2),n([c({type:String,attribute:"header-text",reflect:!0})],Tr.prototype,"headerText",2);var _a=Tr;_a.register($l);var Vm=_a;var Um=u`
|
2546
2729
|
:host {
|
2547
2730
|
--mdc-listitem-default-background-color: var(--mds-color-theme-background-primary-ghost);
|
2548
2731
|
--mdc-listitem-background-color-hover: var(--mds-color-theme-background-primary-hover);
|
@@ -2612,27 +2795,27 @@
|
|
2612
2795
|
display: flex;
|
2613
2796
|
flex-direction: row;
|
2614
2797
|
}
|
2615
|
-
`,
|
2798
|
+
`,Pl=[Um,..._()];var ge=class extends P(_e(v)){constructor(){super(...arguments);this.variant=Dl.VARIANT}connectedCallback(){super.connectedCallback(),this.role=this.role||"listitem"}getText(e,r,o){return o?m`
|
2616
2799
|
<slot name="${e}">
|
2617
|
-
<mdc-text part="${e}" type="${r}" tagname="${
|
2800
|
+
<mdc-text part="${e}" type="${r}" tagname="${w.SPAN}">${o}</mdc-text>
|
2618
2801
|
</slot>
|
2619
|
-
`:g}disableSlottedChildren(e){[...this.leadingControlsSlot,...this.trailingControlsSlot].forEach(r=>{e?r.setAttribute("disabled",""):r.removeAttribute("disabled")})}update(e){super.update(e),e.has("disabled")&&(this.tabIndex=this.disabled?-1:0,this.disableSlottedChildren(this.disabled))}render(){return m`
|
2802
|
+
`:g}disableSlottedChildren(e){[...this.leadingControlsSlot,...this.trailingControlsSlot].forEach(r=>{e?r.setAttribute("disabled",""):r.removeAttribute("disabled")})}update(e){super.update(e),e.has("disabled")&&(this.tabIndex=this.disabled?-1:0,this.disableSlottedChildren(this.disabled),this.setAttribute("aria-disabled",`${this.disabled}`))}render(){return m`
|
2620
2803
|
<div part="leading">
|
2621
2804
|
<slot name="leading-controls"></slot>
|
2622
2805
|
<div part="leading-text">
|
2623
|
-
${this.getText("leading-text-primary-label",
|
2624
|
-
${this.getText("leading-text-secondary-label",
|
2625
|
-
${this.getText("leading-text-tertiary-label",
|
2806
|
+
${this.getText("leading-text-primary-label",S.BODY_MIDSIZE_REGULAR,this.label)}
|
2807
|
+
${this.getText("leading-text-secondary-label",S.BODY_SMALL_REGULAR,this.secondaryLabel)}
|
2808
|
+
${this.getText("leading-text-tertiary-label",S.BODY_SMALL_REGULAR,this.tertiaryLabel)}
|
2626
2809
|
</div>
|
2627
2810
|
</div>
|
2628
2811
|
<div part="trailing">
|
2629
2812
|
<div part="trailing-text">
|
2630
|
-
${this.getText("trailing-text-side-header",
|
2631
|
-
${this.getText("trailing-text-subline",
|
2813
|
+
${this.getText("trailing-text-side-header",S.BODY_MIDSIZE_REGULAR,this.sideHeaderText)}
|
2814
|
+
${this.getText("trailing-text-subline",S.BODY_SMALL_REGULAR,this.sublineText)}
|
2632
2815
|
</div>
|
2633
2816
|
<slot name="trailing-controls"></slot>
|
2634
2817
|
</div>
|
2635
|
-
`}};
|
2818
|
+
`}};ge.styles=[...v.styles,...Pl],n([G({slot:"leading-controls"})],ge.prototype,"leadingControlsSlot",2),n([G({slot:"trailing-controls"})],ge.prototype,"trailingControlsSlot",2),n([c({type:String,reflect:!0})],ge.prototype,"variant",2),n([c({type:String,reflect:!0})],ge.prototype,"label",2),n([c({type:String,reflect:!0,attribute:"secondary-label"})],ge.prototype,"secondaryLabel",2),n([c({type:String,reflect:!0,attribute:"tertiary-label"})],ge.prototype,"tertiaryLabel",2),n([c({type:String,reflect:!0,attribute:"side-header-text"})],ge.prototype,"sideHeaderText",2),n([c({type:String,reflect:!0,attribute:"subline-text"})],ge.prototype,"sublineText",2);var Xe=ge;Xe.register(li);var Fm=Xe;var Bm=u`
|
2636
2819
|
:host {
|
2637
2820
|
--mdc-marker-width: 0.25rem;
|
2638
2821
|
--mdc-marker-solid-background-color: var(--mds-color-theme-outline-secondary-normal);
|
@@ -2657,7 +2840,7 @@
|
|
2657
2840
|
var(--mdc-marker-striped-background-color) 0.375rem
|
2658
2841
|
);
|
2659
2842
|
}
|
2660
|
-
`,
|
2843
|
+
`,Vl=[Bm];var Ul=f.constructTagName("marker"),Fl={SOLID:"solid",STRIPED:"striped"};var so=class extends v{constructor(){super(...arguments);this.variant=Fl.SOLID}};so.styles=[...v.styles,...Vl],n([c({type:String,reflect:!0})],so.prototype,"variant",2);var La=so;La.register(Ul);var Hm=La;var ci=f.constructTagName("optgroup"),Ra="header-id";var Gm=u`
|
2661
2844
|
:host {
|
2662
2845
|
--mdc-optgroup-disabled-color: var(--mds-color-theme-text-primary-disabled);
|
2663
2846
|
}
|
@@ -2670,23 +2853,23 @@
|
|
2670
2853
|
color: var(--mdc-optgroup-disabled-color);
|
2671
2854
|
cursor: default;
|
2672
2855
|
}
|
2673
|
-
`,
|
2856
|
+
`,Bl=[Gm];var Ar=class extends U(P(v)){setDisabledForAllOptions(){this.options.forEach(t=>{this.disabled?t.setAttribute("disabled",""):t.removeAttribute("disabled")})}updated(t){super.updated(t),t.has("disabled")&&this.setDisabledForAllOptions()}render(){var e;let t=this.label?m`
|
2674
2857
|
<mdc-text
|
2675
|
-
id="${
|
2858
|
+
id="${Ra}"
|
2676
2859
|
part="header-text"
|
2677
|
-
type="${
|
2678
|
-
tagname="${
|
2860
|
+
type="${S.BODY_MIDSIZE_BOLD}"
|
2861
|
+
tagname="${w.SPAN}"
|
2679
2862
|
>${this.label}</mdc-text>
|
2680
2863
|
`:g;return m`
|
2681
2864
|
<div
|
2682
2865
|
role="group"
|
2683
|
-
aria-labelledby="${this.label?
|
2866
|
+
aria-labelledby="${this.label?Ra:""}"
|
2684
2867
|
aria-label="${(e=this.dataAriaLabel)!=null?e:""}"
|
2685
2868
|
>
|
2686
2869
|
${t}
|
2687
2870
|
<slot role="presentation"></slot>
|
2688
2871
|
</div>
|
2689
|
-
`}};
|
2872
|
+
`}};Ar.styles=[...v.styles,...Bl],n([c({type:String,reflect:!0})],Ar.prototype,"label",2),n([G({selector:"mdc-option"})],Ar.prototype,"options",2);var Oa=Ar;Oa.register(ci);var Ym=Oa;var di=f.constructTagName("tooltip"),me={DESCRIPTION:"description",LABEL:"label",NONE:"none"},mt={BACKDROP:!1,DELAY:"0,0",OFFSET:4,PLACEMENT:de.TOP,SHOW_ARROW:!0,TOOLTIP_TYPE:me.DESCRIPTION};var Wm=u`
|
2690
2873
|
|
2691
2874
|
:host {
|
2692
2875
|
--mdc-tooltip-max-width: 400px;
|
@@ -2711,7 +2894,7 @@
|
|
2711
2894
|
:host([color='contrast'])::part(popover-content) {
|
2712
2895
|
color: var(--mdc-tooltip-text-color-contrast);
|
2713
2896
|
}
|
2714
|
-
`,
|
2897
|
+
`,Hl=[Wm];var Sr=class extends Ie{constructor(){super(...arguments);this.tooltipType=mt.TOOLTIP_TYPE}connectedCallback(){super.connectedCallback(),this.backdrop=!1,this.delay=mt.DELAY,this.focusTrap=!1,this.hideOnBlur=!0,this.hideOnEscape=!0,this.interactive=!1,this.offset=mt.OFFSET,this.placement=mt.PLACEMENT,this.role="tooltip",this.trigger="mouseenter focusin",this.enabledFocusTrap=!1,this.enabledPreventScroll=!1,this.flip=!0,this.focusTrap=!1,this.preventScroll=!1,this.closeButton=!1,this.hideOnOutsideClick=!1,this.focusBackToTrigger=!1,this.size=!1,this.disableAriaExpanded=!0}getTooltipText(){var e,r;return((r=(e=this.defaultSlotNodes)==null?void 0:e.map(o=>o.textContent).join(" "))==null?void 0:r.trim())||""}setTooltipType(e){this.setAttribute("tooltip-type",Object.values(me).includes(e)?e:mt.TOOLTIP_TYPE)}onIdUpdated(){this.id.length===0&&(this.id=`mdc-tooltip-${Ye()}`);let e=document.getElementById(this.triggerID);if(e)switch(this.tooltipType){case me.DESCRIPTION:e.setAttribute("aria-describedby",this.id);break;case me.LABEL:e.setAttribute("aria-labelledby",this.id);break;default:break}}onPlacementUpdated(){Object.values(de).includes(this.placement)||(this.placement=mt.PLACEMENT)}onTooltipTypeUpdated(e){let r=e.get("tooltipType");Object.values(me).includes(this.tooltipType)||this.setTooltipType(mt.TOOLTIP_TYPE);let o=document.getElementById(this.triggerID);if(o){let a=this.getTooltipText();switch(this.tooltipType){case me.DESCRIPTION:r===me.LABEL&&o.removeAttribute("aria-labelledby"),o.setAttribute("aria-describedby",this.id);break;case me.LABEL:r===me.DESCRIPTION&&o.removeAttribute("aria-describedby"),o.setAttribute("aria-labelledby",this.id);break;default:r===me.DESCRIPTION?o.removeAttribute("aria-describedby"):r===me.LABEL&&o.removeAttribute("aria-labelledby");break}a.length>0&&this.tooltipType!==me.NONE&&!this.ariaLabel&&(this.ariaLabel=a)}}update(e){super.update(e),e.has("id")&&this.onIdUpdated(),e.has("placement")&&this.onPlacementUpdated(),e.has("tooltipType")&&this.onTooltipTypeUpdated(e)}};Sr.styles=[...Ie.styles,...Hl],n([c({type:String,attribute:"tooltip-type",reflect:!0})],Sr.prototype,"tooltipType",2),n([So()],Sr.prototype,"defaultSlotNodes",2);var Ma=Sr;Ma.register(di);var qm=Ma;var mi=f.constructTagName("select"),pi={ARROW_UP:"arrow-up-bold",ARROW_DOWN:"arrow-down-bold"};var Gl="check-bold",Da="dynamic-option-tooltip-popover",no=f.constructTagName("option");var Km=u`
|
2715
2898
|
:host {
|
2716
2899
|
--mdc-option-icon-width: 1rem;
|
2717
2900
|
|
@@ -2740,22 +2923,22 @@
|
|
2740
2923
|
text-overflow: ellipsis;
|
2741
2924
|
white-space: nowrap;
|
2742
2925
|
}
|
2743
|
-
`,
|
2926
|
+
`,Yl=[Km];var Vt=class extends se(Xe){constructor(){super(...arguments);this.selected=!1;this.ariaLabel=null}connectedCallback(){super.connectedCallback(),this.role="option",this.variant=ao.INSET_RECTANGLE,this.updateAttribute("aria-selected",`${this.selected}`),this.updateAttribute("aria-disabled",`${!!this.disabled}`),this.name=void 0,this.secondaryLabel=void 0,this.sideHeaderText=void 0,this.sublineText=void 0,this.addEventListener("focusin",this.displayTooltipForLongText),this.addEventListener("mouseover",this.displayTooltipForLongText),this.addEventListener("focusout",this.hideTooltipOnLeave),this.addEventListener("mouseout",this.hideTooltipOnLeave),this.addEventListener("click",this.handleClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("focusin",this.displayTooltipForLongText),this.removeEventListener("mouseover",this.displayTooltipForLongText),this.removeEventListener("focusout",this.hideTooltipOnLeave),this.removeEventListener("mouseout",this.hideTooltipOnLeave),this.removeEventListener("click",this.handleClick)}handleClick(){this.hideTooltipOnLeave()}displayTooltipForLongText(e){var s,l;let r=(s=e.target.shadowRoot)==null?void 0:s.querySelector('[part="leading-text-primary-label"]');if(r&&r.scrollWidth&&r.clientWidth&&r.scrollWidth<=(r==null?void 0:r.clientWidth))return;let o=document.createElement(di);o.id=Da,o.textContent=(l=this.label)!=null?l:"",o.setAttribute("triggerid",this.id),o.setAttribute("visible",""),o.setAttribute("show-arrow","");let a=this.closest(mi)||this.parentElement;a==null||a.after(o)}hideTooltipOnLeave(){let e=document.querySelector(`#${Da}`);e==null||e.remove()}handleDefaultSlotChange(){var r,o,a;let e=(r=this.shadowRoot)==null?void 0:r.querySelector("slot");e&&!this.label&&(this.label=(a=(o=e.assignedNodes()[0])==null?void 0:o.textContent)==null?void 0:a.trim())}updateAttribute(e,r){this.setAttribute(e,r)}update(e){super.update(e),e.has("selected")&&this.updateAttribute("aria-selected",`${this.selected}`)}render(){let e=this.prefixIcon?m`
|
2744
2927
|
<div part="leading-icon">
|
2745
2928
|
<mdc-icon slot="leading-controls" name="${T(this.prefixIcon)}"></mdc-icon>
|
2746
2929
|
</div>
|
2747
2930
|
`:g,r=this.selected?m`
|
2748
|
-
<mdc-icon slot="trailing-controls" name="${
|
2931
|
+
<mdc-icon slot="trailing-controls" name="${Gl}"></mdc-icon>
|
2749
2932
|
`:g;return m`
|
2750
2933
|
${e}
|
2751
2934
|
<div part="leading-text">
|
2752
|
-
${this.getText("leading-text-primary-label",
|
2935
|
+
${this.getText("leading-text-primary-label",S.BODY_MIDSIZE_REGULAR,this.label)}
|
2753
2936
|
</div>
|
2754
2937
|
<div part="trailing">
|
2755
2938
|
${r}
|
2756
2939
|
</div>
|
2757
2940
|
<slot part="default-slot" @slotchange="${this.handleDefaultSlotChange}"></slot>
|
2758
|
-
`}};
|
2941
|
+
`}};Vt.styles=[...Xe.styles,...Yl],n([c({type:Boolean,reflect:!0})],Vt.prototype,"selected",2),n([c({type:String,reflect:!0,attribute:"prefix-icon"})],Vt.prototype,"prefixIcon",2),n([c({type:String,reflect:!0,attribute:"aria-label"})],Vt.prototype,"ariaLabel",2);var $a=Vt;$a.register(no);var Zm=$a;Ie.register(xl);var Xm=Ie;var jm=[u`
|
2759
2942
|
:host {
|
2760
2943
|
--mdc-progressbar-background-color: var(--mds-color-theme-control-indicator-inactive-normal);
|
2761
2944
|
--mdc-progressbar-active-background-color: var(--mds-color-theme-control-active-normal);
|
@@ -2839,7 +3022,7 @@
|
|
2839
3022
|
border: var(--mdc-progressbar-border);
|
2840
3023
|
}
|
2841
3024
|
}
|
2842
|
-
`],
|
3025
|
+
`],Wl=jm;var ql=f.constructTagName("progressbar"),hi={DEFAULT:"default",INLINE:"inline"},Kl={VARIANT:hi.DEFAULT,VALIDATION:W.DEFAULT};var Ut=class extends U(be){constructor(){super(...arguments);this.variant=Kl.VARIANT;this.value="0";this.error=!1;this.renderProgressbar=()=>{var a;let e=this.getValidationVariant(),r=this.clampedValue>0&&this.clampedValue<100,o=this.error?"100":`${this.clampedValue}`;return m`
|
2843
3026
|
<div
|
2844
3027
|
part="progress-container ${r?"gap":""}"
|
2845
3028
|
role="progressbar"
|
@@ -2851,16 +3034,16 @@
|
|
2851
3034
|
<div part="progress-bar ${e}" style="width: ${o}%"></div>
|
2852
3035
|
<div part="remaining"></div>
|
2853
3036
|
</div>
|
2854
|
-
`}}connectedCallback(){super.connectedCallback(),this.id=`mdc-progressbar-${
|
3037
|
+
`}}connectedCallback(){super.connectedCallback(),this.id=`mdc-progressbar-${Ye()}`,this.disabled=void 0}get clampedValue(){let e=Number(this.value);return Number.isNaN(e)?0:Math.max(0,Math.min(100,e))}getValidationVariant(){return this.error?this.helpTextType=W.ERROR:this.clampedValue===100?this.helpTextType=W.SUCCESS:this.helpTextType=W.DEFAULT,this.helpTextType}render(){let e=this.variant===hi.INLINE;return m`
|
2855
3038
|
${e?m`<div part="inline-label-container">${this.renderLabelElement()} ${this.renderProgressbar()}</div>`:m`
|
2856
3039
|
<div part="label-container">
|
2857
3040
|
${this.renderLabelElement()}
|
2858
|
-
${this.variant===
|
3041
|
+
${this.variant===hi.DEFAULT&&this.label?m`<span part="percentage">${this.clampedValue}%</span>`:""}
|
2859
3042
|
</div>
|
2860
3043
|
${this.renderProgressbar()}
|
2861
3044
|
${this.renderHelperText()}
|
2862
3045
|
`}
|
2863
|
-
`}};
|
3046
|
+
`}};Ut.styles=[...be.styles,...Wl],n([c({type:String,reflect:!0})],Ut.prototype,"variant",2),n([c({type:String,reflect:!0})],Ut.prototype,"value",2),n([c({type:Boolean,attribute:"error"})],Ut.prototype,"error",2);var lo=Ut;lo.register(ql);var Qm=lo;var Jm=u`
|
2864
3047
|
:host {
|
2865
3048
|
--mdc-spinner-size: 3rem;
|
2866
3049
|
--mdc-track-color: var(--mds-color-theme-control-indicator-inactive-normal);
|
@@ -2904,7 +3087,7 @@
|
|
2904
3087
|
color: var(--mdc-progress-error-color);
|
2905
3088
|
margin: 0.5rem;
|
2906
3089
|
}
|
2907
|
-
`,
|
3090
|
+
`,Zl=[Jm];var Xl=f.constructTagName("progressspinner"),B={RADIUS:20,CIRCUMFERENCE:2*Math.PI*20,STROKE_WIDTH:4,GAP_SIZE:7.5,ERROR_ICON_SIZE:2,SUCCESS_ICON_SIZE:3,ICON_LENGTH_UNIT:"em"},za={CHECK_CIRCLE_BOLD:"check-circle-bold",ERROR_LEGACY_FILLED:"error-legacy-filled"};var Pa=i=>{if(i===0)return 0;let t=i/100*B.CIRCUMFERENCE-B.GAP_SIZE;return Math.max(t,.1*i)},jl=i=>{let t=B.CIRCUMFERENCE-Pa(i)-2*B.GAP_SIZE;return i===0?B.CIRCUMFERENCE:t<0?0:t},Ql=i=>i===0?0:B.GAP_SIZE*.5,Jl=(i,t)=>{let e=t+B.GAP_SIZE*1.5;return i===0?0:e};var ui=class extends lo{connectedCallback(){super.connectedCallback(),this.id="",this.disabled=void 0,this.helpTextType=void 0,this.helpText=void 0,this.requiredLabel=void 0,this.variant=void 0,this.label=void 0}renderProgressSpinner(){var a;let t=Pa(this.clampedValue),e=jl(this.clampedValue),r=Ql(this.clampedValue),o=Jl(this.clampedValue,t);return m`
|
2908
3091
|
<div
|
2909
3092
|
part="spinner-container ${this.variant}"
|
2910
3093
|
role="progressbar"
|
@@ -2918,18 +3101,18 @@
|
|
2918
3101
|
part="spinner-track"
|
2919
3102
|
cx="24"
|
2920
3103
|
cy="24"
|
2921
|
-
r="${
|
2922
|
-
stroke-width="${e===0?0:
|
2923
|
-
stroke-dasharray="${e} ${
|
3104
|
+
r="${B.RADIUS}"
|
3105
|
+
stroke-width="${e===0?0:B.STROKE_WIDTH}"
|
3106
|
+
stroke-dasharray="${e} ${B.CIRCUMFERENCE}"
|
2924
3107
|
stroke-dashoffset="-${o}"
|
2925
3108
|
/>
|
2926
3109
|
<circle
|
2927
3110
|
part="spinner-progress"
|
2928
3111
|
cx="24"
|
2929
3112
|
cy="24"
|
2930
|
-
r="${
|
2931
|
-
stroke-width="${t===0?0:
|
2932
|
-
stroke-dasharray="${t} ${
|
3113
|
+
r="${B.RADIUS}"
|
3114
|
+
stroke-width="${t===0?0:B.STROKE_WIDTH}"
|
3115
|
+
stroke-dasharray="${t} ${B.CIRCUMFERENCE}"
|
2933
3116
|
stroke-dashoffset="-${r}"
|
2934
3117
|
/>
|
2935
3118
|
</svg>
|
@@ -2938,18 +3121,18 @@
|
|
2938
3121
|
<mdc-icon
|
2939
3122
|
part="error-icon"
|
2940
3123
|
aria-label="${(t=this.dataAriaLabel)!=null?t:""}"
|
2941
|
-
name="${
|
2942
|
-
size="${
|
2943
|
-
length-unit="${
|
3124
|
+
name="${za.ERROR_LEGACY_FILLED}"
|
3125
|
+
size="${B.ERROR_ICON_SIZE}"
|
3126
|
+
length-unit="${B.ICON_LENGTH_UNIT}"></mdc-icon>
|
2944
3127
|
`}renderSuccessState(){var t;return m`
|
2945
3128
|
<mdc-icon
|
2946
3129
|
part="success-icon"
|
2947
3130
|
aria-label="${(t=this.dataAriaLabel)!=null?t:""}"
|
2948
|
-
name="${
|
2949
|
-
size="${
|
2950
|
-
length-unit="${
|
3131
|
+
name="${za.CHECK_CIRCLE_BOLD}"
|
3132
|
+
size="${B.SUCCESS_ICON_SIZE}"
|
3133
|
+
length-unit="${B.ICON_LENGTH_UNIT}"></mdc-icon>
|
2951
3134
|
`}render(){return this.error?this.renderErrorState():this.clampedValue===100?this.renderSuccessState():m`
|
2952
|
-
${this.renderProgressSpinner()}`}};
|
3135
|
+
${this.renderProgressSpinner()}`}};ui.styles=[...v.styles,...Zl];var Va=ui;Va.register(Xl);var ep=Va;var tp=[N,u`
|
2953
3136
|
:host{
|
2954
3137
|
display: flex;
|
2955
3138
|
flex-direction: row;
|
@@ -3036,7 +3219,7 @@
|
|
3036
3219
|
display: none;
|
3037
3220
|
}
|
3038
3221
|
|
3039
|
-
`,...
|
3222
|
+
`,..._(!0)],ec=tp;var Ft=class extends se(U(J)){constructor(){super(...arguments);this.checked=!1;this.readonly=!1;this.autofocus=!1;this.renderLabelAndHelperText=()=>this.label?m`<div class="mdc-radio__label-container">
|
3040
3223
|
${this.renderLabel()}
|
3041
3224
|
${this.renderHelperText()}
|
3042
3225
|
</div>`:g}connectedCallback(){super.connectedCallback(),this.helpTextType=void 0}firstUpdated(){this.updateTabIndex()}getAllRadiosWithinSameGroup(){return Array.from(document.querySelectorAll(`mdc-radio[name="${this.name}"]`))}dispatchChangeEvent(e){let r=e.constructor;this.dispatchEvent(new r(e.type,e))}formResetCallback(){this.getAllRadiosWithinSameGroup().forEach(r=>{r.checked=!1}),this.updateComplete.then(()=>{this.setActualFormValue()}).catch(r=>{this.onerror&&this.onerror(r)})}formStateRestoreCallback(e){this.value===e&&e!==""&&(this.checked=!0)}setComponentValidity(e){e?this.internals.setValidity({}):this.requiredLabel&&!this.checked&&(this.validationMessage?this.inputElement.setCustomValidity(this.validationMessage):this.inputElement.setCustomValidity(""),this.setValidity()),this.updateTabIndex()}setGroupValidity(e,r){this.updateComplete.then(()=>{e.forEach(o=>{o.setComponentValidity(r)})}).catch(o=>{this.onerror&&this.onerror(o)})}setActualFormValue(){let e="";this.checked?e=this.value?this.value:"on":e=null;let r=this.getAllRadiosWithinSameGroup();if(this.checked)this.setGroupValidity(r,!0);else{let o=r.some(l=>l.requiredLabel),a=!!r.find(l=>l.checked),s=o&&!a;this.setGroupValidity(r,!s)}this.internals.setFormValue(e)}handleChange(e){var a;if(this.disabled||this.readonly)return;this.getAllRadiosWithinSameGroup().forEach(s=>{var d;let l=(d=s.shadowRoot)==null?void 0:d.querySelector("input");l&&(s.checked=!1,l.checked=!1)}),this.checked=!0;let o=(a=this.shadowRoot)==null?void 0:a.querySelector("input");o&&(o.checked=!0),this.dispatchChangeEvent(e)}updateRadio(e,r,o){var a,s;(s=(a=e[r].shadowRoot)==null?void 0:a.querySelector("input"))==null||s.focus(),e[r].handleChange(o)}handleKeyDown(e){var s;if(this.disabled)return;let o=this.getAllRadiosWithinSameGroup().filter(l=>!l.disabled),a=o.indexOf(this);if(["ArrowDown","ArrowRight"].includes(e.key)){let l=(a+1)%o.length;this.updateRadio(o,l,e)}else if(["ArrowUp","ArrowLeft"].includes(e.key)){let l=(a-1+o.length)%o.length;this.updateRadio(o,l,e)}else e.key===" "&&this.updateRadio(o,a,e);this.updateTabIndex(),e.key==="Enter"&&((s=this.form)==null||s.requestSubmit())}updateTabIndex(){let e=this.getAllRadiosWithinSameGroup(),r=e.find(a=>a.checked),o=e.find(a=>!a.disabled);e.forEach(a=>{var l;let s=(l=a.shadowRoot)==null?void 0:l.querySelector("input");s&&(s.tabIndex=-1,(a===r||!r&&a===o)&&(s.tabIndex=0))})}update(e){super.update(e),e.has("checked")&&this.setActualFormValue()}render(){var e;return m`
|
@@ -3066,12 +3249,12 @@
|
|
3066
3249
|
/>
|
3067
3250
|
</mdc-staticradio>
|
3068
3251
|
${this.renderLabelAndHelperText()}
|
3069
|
-
`}};
|
3252
|
+
`}};Ft.styles=[...J.styles,...ec],n([c({type:Boolean,reflect:!0})],Ft.prototype,"checked",2),n([c({type:Boolean,reflect:!0})],Ft.prototype,"readonly",2),n([c({type:Boolean,reflect:!0})],Ft.prototype,"autofocus",2);var Ua=Ft;var fi=f.constructTagName("radio");Ua.register(fi);var rp=Ua;var co=class extends ii{constructor(){super();this.name="";this.isRadio=!0}firstUpdated(){var e,r,o,a,s;(s=(a=(o=(r=Array.from(((e=this.shadowRoot)==null?void 0:e.querySelectorAll("slot"))||[]))==null?void 0:r.flatMap(l=>l.assignedElements({flatten:!0})))==null?void 0:o.filter(l=>l.tagName.toLowerCase()===fi||l.tagName.toLowerCase()===Wo))==null?void 0:a.filter(l=>!l.hasAttribute("name")))==null||s.forEach(l=>{l.setAttribute("name",this.name),this.requiredLabel&&l.setAttribute("required-label",this.requiredLabel)})}};co.styles=[...ii.styles],n([c({type:String})],co.prototype,"name",2);var Fa=co;var tc=f.constructTagName("radiogroup");Fa.register(tc);var op=Fa;var rc=f.constructTagName("screenreaderannouncer"),ip={ASSERTIVE:"assertive",POLITE:"polite",OFF:"off"},Ir={ARIA_LIVE:ip.POLITE,DELAY:150,IDENTITY:"mdc-screenreaderannouncer-identity",TIMEOUT:2e4};var ap=[u`
|
3070
3253
|
:host {
|
3071
3254
|
display: none;
|
3072
3255
|
visibility: hidden;
|
3073
3256
|
}
|
3074
|
-
`]
|
3257
|
+
`],oc=ap;var je=class extends v{constructor(){super(...arguments);this.announcement="";this.identity="";this.dataAriaLive=Ir.ARIA_LIVE;this.delay=Ir.DELAY;this.timeout=Ir.TIMEOUT;this.timeOutIds=[];this.ariaLiveAnnouncementIds=[]}announce(e,r,o,a){var s;if(e.length>0){let l=`mdc-screenreaderannouncer-announcement-${Ye()}`,d=document.createElement("div");d.id=l,d.ariaLive=a,(s=document.getElementById(this.identity))==null||s.appendChild(d);let p=window.setTimeout(()=>{let h=document.createElement("p");h.textContent=e,d.appendChild(h),this.ariaLiveAnnouncementIds.push(l);let b=window.setTimeout(()=>{var x;(x=document.getElementById(l))==null||x.remove()},o);this.timeOutIds.push(b)},r);this.timeOutIds.push(p)}}clearTimeOutsAndAnnouncements(){this.timeOutIds.forEach(e=>{window.clearTimeout(e)}),this.ariaLiveAnnouncementIds.forEach(e=>{var r;(r=document.getElementById(e))==null||r.remove()})}createAnnouncementAriaLiveRegion(){let e=document.getElementById(this.identity);if(!e){e=document.createElement("div"),e.id=this.identity;let r=document.createElement("style");r.textContent=`
|
3075
3258
|
.mdc-screenreaderannouncer__visually-hidden {
|
3076
3259
|
clip: rect(0 0 0 0);
|
3077
3260
|
clip-path: inset(50%);
|
@@ -3081,7 +3264,7 @@
|
|
3081
3264
|
white-space: nowrap;
|
3082
3265
|
width: 1px;
|
3083
3266
|
}
|
3084
|
-
`,e.appendChild(r),e.classList.add("mdc-screenreaderannouncer__visually-hidden"),document.body.appendChild(e)}}connectedCallback(){super.connectedCallback(),this.identity.length===0&&(this.identity=
|
3267
|
+
`,e.appendChild(r),e.classList.add("mdc-screenreaderannouncer__visually-hidden"),document.body.appendChild(e)}}connectedCallback(){super.connectedCallback(),this.identity.length===0&&(this.identity=Ir.IDENTITY),this.createAnnouncementAriaLiveRegion()}disconnectedCallback(){super.disconnectedCallback(),this.clearTimeOutsAndAnnouncements()}updated(e){e.has("identity")&&this.identity.length===0&&(this.identity=Ir.IDENTITY,this.createAnnouncementAriaLiveRegion()),e.has("announcement")&&this.announcement.length>0&&(this.announce(this.announcement,this.delay,this.timeout,this.dataAriaLive),this.announcement="")}};je.styles=[...v.styles,...oc],n([c({type:String,reflect:!0})],je.prototype,"announcement",2),n([c({type:String,reflect:!0})],je.prototype,"identity",2),n([c({type:String,reflect:!0,attribute:"data-aria-live"})],je.prototype,"dataAriaLive",2),n([c({type:Number,reflect:!0})],je.prototype,"delay",2),n([c({type:Number,reflect:!0})],je.prototype,"timeout",2);var Ba=je;Ba.register(rc);var sp=Ba;var np=u`
|
3085
3268
|
|
3086
3269
|
:host::part(filters-container){
|
3087
3270
|
display: flex;
|
@@ -3108,9 +3291,9 @@
|
|
3108
3291
|
scrollbar-width: none;
|
3109
3292
|
}
|
3110
3293
|
|
3111
|
-
`,
|
3294
|
+
`,ic=[np];var ac=f.constructTagName("searchfield"),mo={TYPE:Ca.SEARCH,ICON:"search-bold",CLOSE_BTN:!0,INPUT_CHIP_TAG:si};var Bt=class extends Er{constructor(){super(...arguments);this.isInputFocused=!1;this.hasInputChips=!1}handleKeyDown(e){super.handleKeyDown(e),e.key==="Escape"&&this.clearInputText()}connectedCallback(){super.connectedCallback(),this.leadingIcon=mo.ICON,this.trailingButton=mo.CLOSE_BTN,this.helpText=void 0,this.helpTextType=void 0,this.requiredLabel=void 0,this.validationMessage=void 0,this.prefixText=void 0}renderInputChips(){var e;this.hasInputChips=!!((e=this.inputChips)!=null&&e.length),this.inputChips&&this.inputChips.forEach(r=>{r.matches(mo.INPUT_CHIP_TAG)||r.remove()})}firstUpdated(){this.inputElement.onfocus=()=>{this.isInputFocused=!0},this.inputElement.onblur=()=>{this.isInputFocused=!1}}clearInputText(){var e;super.clearInputText(),(e=this.inputChips)==null||e.forEach(r=>{r.dispatchEvent(new CustomEvent("remove",{bubbles:!0,composed:!0}))})}render(){return m`
|
3112
3295
|
${this.renderLabelElement()}
|
3113
|
-
<div class="${
|
3296
|
+
<div class="${lr({"input-container":!0,"mdc-focus-ring":this.isInputFocused})}" part="input-container">
|
3114
3297
|
${this.renderLeadingIcon()}
|
3115
3298
|
<div part='scrollable-container' tabindex='-1'>
|
3116
3299
|
<div part="filters-container"
|
@@ -3118,11 +3301,11 @@
|
|
3118
3301
|
@keydown=${e=>e.key==="Enter"?this.inputElement.focus():null}
|
3119
3302
|
@keyup=${e=>e.key===" "?this.inputElement.focus():null}>
|
3120
3303
|
<slot name="filters" @slotchange=${this.renderInputChips}></slot></div>
|
3121
|
-
${this.renderInputElement(
|
3304
|
+
${this.renderInputElement(mo.TYPE,this.hasInputChips)}
|
3122
3305
|
</div>
|
3123
3306
|
${this.renderTrailingButton(this.hasInputChips)}
|
3124
3307
|
</div>
|
3125
|
-
`}};
|
3308
|
+
`}};Bt.styles=[...Er.styles,...ic],n([G({slot:"filters"})],Bt.prototype,"inputChips",2),n([L()],Bt.prototype,"isInputFocused",2),n([L()],Bt.prototype,"hasInputChips",2);var Ha=Bt;Ha.register(ac);var lp=Ha;var cp=u`
|
3126
3309
|
:host {
|
3127
3310
|
--mdc-select-background-color: var(--mds-color-theme-background-primary-ghost);
|
3128
3311
|
--mdc-select-icon-border-color: var(--mds-color-theme-outline-input-normal);
|
@@ -3224,7 +3407,7 @@
|
|
3224
3407
|
:host([help-text-type="warning"])::part(base-container) {
|
3225
3408
|
border-color: var(--mdc-select-warning-border-color);
|
3226
3409
|
}
|
3227
|
-
`,
|
3410
|
+
`,sc=[cp,..._(!0)];var te=class extends se(U(J)){constructor(){super(...arguments);this.readonly=!1;this.height="auto";this.baseIconName=pi.ARROW_DOWN;this.selectedValue="";this.displayPopover=!1;this.activeDescendant="";this.popoverWidth="100%"}connectedCallback(){super.connectedCallback(),this.value=void 0,this.addEventListener("keydown",this.handleKeydown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this.handleKeydown)}getAllValidOptions(){var e;return((e=this.optionsList)==null?void 0:e.map(r=>r.tagName.toLowerCase()===no?r:r.tagName.toLowerCase()===ci?Array.from(r.children).filter(o=>o.tagName.toLowerCase()===no):[]).flat())||[]}handlePopoverOpen(){this.displayPopover=!0,this.baseIconName=pi.ARROW_UP}handlePopoverClose(){this.displayPopover=!1,this.baseIconName=pi.ARROW_DOWN}updateTabIndexForAllOptions(e){var o;let r=!1;this.getAllValidOptions().forEach(a=>{a===e?(this.setSelectedValue(a),r=!0,a.setAttribute("selected",""),a.setAttribute("tabindex","0")):(a==null||a.setAttribute("tabindex","-1"),a==null||a.removeAttribute("selected"))}),!r&&((o=this.getAllValidOptions()[0])==null||o.setAttribute("tabindex","0"))}handleOptionsClick(e){this.updateTabIndexForAllOptions(e.target)}setSelectedValue(e){var r,o,a,s;this.selectedValueText=(o=(r=e==null?void 0:e.getAttribute("label"))!=null?r:e==null?void 0:e.textContent)!=null?o:"",this.selectedValue=(s=(a=e==null?void 0:e.getAttribute("value"))!=null?a:e==null?void 0:e.textContent)!=null?s:"",this.internals.setFormValue(this.selectedValue),this.manageRequired(),this.dispatchChange(this.selectedValue)}manageRequired(){!this.selectedValue&&this.requiredLabel?(this.validationMessage?this.inputElement.setCustomValidity(this.validationMessage):this.inputElement.setCustomValidity(""),this.setValidity()):this.internals.setValidity({})}formResetCallback(){this.selectedValue="",this.selectedValueText=void 0,this.internals.setFormValue(this.selectedValue),this.updateTabIndexForAllOptions()}formStateRestoreCallback(e){this.selectedValue=e,this.selectedValueText=e}dispatchChange(e){e&&this.dispatchEvent(new CustomEvent("change",{detail:{value:e},composed:!0,bubbles:!0}))}handleKeydown(e){this.displayPopover?this.handlePopoverOnOpen(e):this.handlePopoverOnClose(e)}handlePopoverOnOpen(e){var r;switch(e.key){case $.SPACE:this.updateTabIndexForAllOptions(e.target),this.closePopover(),e.preventDefault();break;case $.ENTER:this.updateTabIndexForAllOptions(e.target),this.closePopover(),e.preventDefault(),(r=this.form)==null||r.requestSubmit();break;case $.ESCAPE:this.closePopover(),e.stopPropagation();break;case $.HOME:this.setFocusAndTabIndex(0),e.preventDefault();break;case $.END:this.setFocusAndTabIndex(this.getAllValidOptions().length-1),e.preventDefault();break;case $.ARROW_DOWN:case $.ARROW_UP:case $.PAGE_DOWN:case $.PAGE_UP:this.handleOptionsNavigation(e),this.updateActivedescendant(e.target);break;default:break}}handlePopoverOnClose(e){switch(e.key){case $.ARROW_DOWN:case $.ARROW_UP:case $.ENTER:case $.SPACE:this.openPopover(),e.preventDefault();break;case $.HOME:this.openPopover(),this.setFocusAndTabIndex(0),e.preventDefault();break;case $.END:this.openPopover(),this.setFocusAndTabIndex(this.getAllValidOptions().length-1),e.preventDefault();break;default:break}}handleOptionsNavigation(e){let r=this.getAllValidOptions(),o=r.findIndex(s=>s===e.target),a=this.getNewIndexBasedOnKey(e.key,o,r.length);a!==-1&&(this.setFocusAndTabIndex(a),e.preventDefault())}getNewIndexBasedOnKey(e,r,o){return e===$.ARROW_DOWN&&r!==o-1?r+1:e===$.ARROW_UP&&r>0?r-1:e===$.PAGE_DOWN?r+10>o?o-1:r+10:e===$.PAGE_UP?r-10<0?0:r-10:-1}updateActivedescendant(e){var o,a;let r=this.getAllValidOptions().findIndex(s=>s===e);this.activeDescendant=(a=(o=this.getAllValidOptions()[r])==null?void 0:o.id)!=null?a:""}resetActivedescendant(){this.activeDescendant=""}setFocusAndTabIndex(e){var r;(r=this.getAllValidOptions()[e])==null||r.focus(),this.getAllValidOptions().forEach((o,a)=>{let s=e===a?"0":"-1";o==null||o.setAttribute("tabindex",s)})}openPopover(){this.displayPopover=!0,this.resetActivedescendant()}closePopover(){this.displayPopover=!1,this.resetActivedescendant()}firstUpdated(){let e=this.getAllValidOptions(),r=e.findIndex(o=>o==null?void 0:o.hasAttribute("selected"));r!==-1?(this.setSelectedValue(e[r]),this.updateTabIndexForAllOptions(e[r])):this.placeholder?this.placeholder&&this.manageRequired():(this.setSelectedValue(e[0]),this.updateTabIndexForAllOptions())}getNativeSelect(){return m`
|
3228
3411
|
<select
|
3229
3412
|
part="native-select"
|
3230
3413
|
id="${this.id}"
|
@@ -3259,7 +3442,7 @@
|
|
3259
3442
|
focus-back-to-trigger
|
3260
3443
|
focus-trap
|
3261
3444
|
role="listbox"
|
3262
|
-
placement="${
|
3445
|
+
placement="${de.BOTTOM_START}"
|
3263
3446
|
@shown="${this.handlePopoverOpen}"
|
3264
3447
|
@hidden="${this.handlePopoverClose}"
|
3265
3448
|
style="--mdc-popover-max-width: ${this.popoverWidth}; --mdc-popover-max-height: ${this.height};"
|
@@ -3283,8 +3466,8 @@
|
|
3283
3466
|
>
|
3284
3467
|
<mdc-text
|
3285
3468
|
part="base-text ${this.selectedValueText?"selected":""}"
|
3286
|
-
type="${
|
3287
|
-
tagname="${
|
3469
|
+
type="${S.BODY_MIDSIZE_REGULAR}"
|
3470
|
+
tagname="${w.SPAN}"
|
3288
3471
|
>
|
3289
3472
|
${(r=this.selectedValueText)!=null?r:this.placeholder}
|
3290
3473
|
</mdc-text>
|
@@ -3296,7 +3479,7 @@
|
|
3296
3479
|
${this.getPopoverContent()}
|
3297
3480
|
</div>
|
3298
3481
|
${this.renderHelperText()}
|
3299
|
-
`}};
|
3482
|
+
`}};te.styles=[...J.styles,...sc],n([c({type:String})],te.prototype,"placeholder",2),n([c({type:Boolean})],te.prototype,"readonly",2),n([c({type:String})],te.prototype,"height",2),n([G()],te.prototype,"optionsList",2),n([L()],te.prototype,"baseIconName",2),n([L()],te.prototype,"selectedValueText",2),n([L()],te.prototype,"selectedValue",2),n([L()],te.prototype,"displayPopover",2),n([L()],te.prototype,"activeDescendant",2),n([L()],te.prototype,"popoverWidth",2),n([Ue("select")],te.prototype,"inputElement",2);var Ga=te;Ga.register(mi);var dp=Ga;var mp=[N,u`
|
3300
3483
|
:host {
|
3301
3484
|
--mdc-spinner-default-color: var(--mds-color-theme-control-active-normal);
|
3302
3485
|
--mdc-spinner-inverted-color: var(--mds-color-theme-inverted-control-active-normal);
|
@@ -3358,11 +3541,100 @@
|
|
3358
3541
|
stroke-dashoffset: -292;
|
3359
3542
|
}
|
3360
3543
|
}
|
3361
|
-
`],
|
3544
|
+
`],nc=mp;var lc=f.constructTagName("spinner"),pp={LARGE:"large",MIDSIZE:"midsize",SMALL:"small"},hp={STANDALONE:"standalone",BUTTON:"button"},bi={VARIANT:hp.STANDALONE,SIZE:pp.MIDSIZE,INVERTED:!1};var pt=class extends v{constructor(){super(...arguments);this.inverted=bi.INVERTED;this.size=bi.SIZE;this.ariaLabel=null;this.variant=bi.VARIANT}updated(e){super.updated(e),e.has("ariaLabel")&&(this.role=this.ariaLabel?"img":null,this.ariaHidden=this.ariaLabel?"false":"true")}render(){return m`
|
3362
3545
|
<svg part="container" viewBox="0 0 100 100">
|
3363
3546
|
<circle part="circle" cx="50" cy="50" r="46"></circle>
|
3364
3547
|
</svg>
|
3365
|
-
`}};
|
3548
|
+
`}};pt.styles=[...v.styles,...nc],n([c({type:Boolean,reflect:!0})],pt.prototype,"inverted",2),n([c({type:String,reflect:!0})],pt.prototype,"size",2),n([c({type:String,attribute:"aria-label"})],pt.prototype,"ariaLabel",2),n([c({type:String,reflect:!0})],pt.prototype,"variant",2);var Ya=pt;Ya.register(lc);var up=Ya;var cc=f.constructTagName("statictoggle"),fp={DEFAULT:"default",COMPACT:"compact"},Wa={CHECKED:"check-bold",UNCHECKED:"cancel-bold"},dc={compact:.75,default:1.25},mc={SIZE:fp.DEFAULT};var bp=[u`
|
3549
|
+
:host {
|
3550
|
+
--mdc-statictoggle-width: 3rem;
|
3551
|
+
--mdc-statictoggle-height: 1.5rem;
|
3552
|
+
--mdc-statictoggle-width-compact: 2rem;
|
3553
|
+
--mdc-statictoggle-height-compact: 1rem;
|
3554
|
+
--mdc-statictoggle-border-radius: 0.75rem;
|
3555
|
+
--mdc-statictoggle-border-radius-compact: 0.5rem;
|
3556
|
+
--mdc-statictoggle-border: 1px solid var(--mds-color-theme-outline-input-normal);
|
3557
|
+
|
3558
|
+
--mdc-statictoggle-inactive-rest-color: var(--mds-color-theme-control-inactive-normal);
|
3559
|
+
--mdc-statictoggle-inactive-disabled-color: var(--mds-color-theme-control-inactive-disabled);
|
3560
|
+
--mdc-statictoggle-active-rest-color: var(--mds-color-theme-control-active-normal);
|
3561
|
+
--mdc-statictoggle-active-disabled-color: var(--mds-color-theme-control-active-disabled);
|
3562
|
+
|
3563
|
+
--mdc-statictoggle-icon-color-normal: var(--mds-color-theme-common-inverted-text-primary-normal);
|
3564
|
+
--mdc-statictoggle-icon-color-disabled: var(--mds-color-theme-common-inverted-text-primary-disabled);
|
3565
|
+
--mdc-statictoggle-icon-background-color-normal: var(--mds-color-theme-common-text-primary-normal);
|
3566
|
+
--mdc-statictoggle-icon-background-color-disabled: var(--mds-color-theme-common-text-primary-disabled);
|
3567
|
+
|
3568
|
+
border-radius: var(--mdc-statictoggle-border-radius);
|
3569
|
+
}
|
3570
|
+
|
3571
|
+
:host::part(slider) {
|
3572
|
+
width: var(--mdc-statictoggle-width);
|
3573
|
+
height: var(--mdc-statictoggle-height);
|
3574
|
+
background: var(--mdc-statictoggle-inactive-rest-color);
|
3575
|
+
border-radius: var(--mdc-statictoggle-border-radius);
|
3576
|
+
border: var(--mdc-statictoggle-border);
|
3577
|
+
display: flex;
|
3578
|
+
align-items: center;
|
3579
|
+
justify-content: flex-start;
|
3580
|
+
transition: background-color 0.3s ease;
|
3581
|
+
outline: none;
|
3582
|
+
padding: 1px;
|
3583
|
+
}
|
3584
|
+
|
3585
|
+
:host([checked])::part(slider) {
|
3586
|
+
background-color: var(--mdc-statictoggle-active-rest-color);
|
3587
|
+
justify-content: flex-end;
|
3588
|
+
border-color: transparent;
|
3589
|
+
}
|
3590
|
+
|
3591
|
+
:host([size='compact'])::part(slider) {
|
3592
|
+
width: var(--mdc-statictoggle-width-compact);
|
3593
|
+
height: var(--mdc-statictoggle-height-compact);
|
3594
|
+
border-radius: var(--mdc-statictoggle-border-radius-compact);
|
3595
|
+
}
|
3596
|
+
|
3597
|
+
.icon {
|
3598
|
+
padding: 0.25rem;
|
3599
|
+
--mdc-icon-fill-color: var(--mdc-statictoggle-icon-color-normal);
|
3600
|
+
background-color: var(--mdc-statictoggle-icon-background-color-normal);
|
3601
|
+
border-radius: 50%;
|
3602
|
+
}
|
3603
|
+
|
3604
|
+
:host([disabled]) .icon {
|
3605
|
+
--mdc-icon-fill-color: var(--mdc-statictoggle-icon-color-disabled);
|
3606
|
+
background-color: var(--mdc-statictoggle-icon-background-color-disabled);
|
3607
|
+
}
|
3608
|
+
|
3609
|
+
:host([size='compact']) .icon {
|
3610
|
+
padding: 0.125rem;
|
3611
|
+
}
|
3612
|
+
|
3613
|
+
:host([disabled])::part(slider) {
|
3614
|
+
background-color: var(--mdc-statictoggle-inactive-disabled-color);
|
3615
|
+
}
|
3616
|
+
|
3617
|
+
:host([disabled][checked])::part(slider) {
|
3618
|
+
background-color: var(--mdc-statictoggle-active-disabled-color);
|
3619
|
+
}
|
3620
|
+
|
3621
|
+
/* High Contrast Mode */
|
3622
|
+
@media (forced-colors: active) {
|
3623
|
+
:host([checked])::part(slider), .icon {
|
3624
|
+
border: var(--mdc-statictoggle-border);
|
3625
|
+
}
|
3626
|
+
}
|
3627
|
+
`],pc=bp;var Cr=class extends P(v){constructor(){super(...arguments);this.checked=!1;this.size=mc.SIZE}render(){return m`
|
3628
|
+
<slot></slot>
|
3629
|
+
<div part="slider">
|
3630
|
+
<mdc-icon
|
3631
|
+
name="${this.checked?Wa.CHECKED:Wa.UNCHECKED}"
|
3632
|
+
class="icon"
|
3633
|
+
length-unit="rem"
|
3634
|
+
size="${dc[this.size]}"
|
3635
|
+
></mdc-icon>
|
3636
|
+
</div>
|
3637
|
+
`}};Cr.styles=[...v.styles,...pc],n([c({type:Boolean,reflect:!0})],Cr.prototype,"checked",2),n([c({type:String,reflect:!0})],Cr.prototype,"size",2);var qa=Cr;qa.register(cc);var gp=qa;var vp=[N,u`
|
3366
3638
|
|
3367
3639
|
:host {
|
3368
3640
|
--mdc-tab-content-gap: 0.5rem;
|
@@ -3606,12 +3878,12 @@
|
|
3606
3878
|
color: var(--mdc-tab-pill-active-color-disabled);
|
3607
3879
|
}
|
3608
3880
|
|
3609
|
-
`,...
|
3881
|
+
`,..._()],hc=vp;var uc=f.constructTagName("tab"),Ka={GLASS:"glass",LINE:"line",PILL:"pill"},gi={VARIANT:Ka.PILL,ACTIVE:!1};var ht=class extends oe(re){constructor(){super(...arguments);this.active=gi.ACTIVE;this.variant=gi.VARIANT;this.handleTabActiveChange=e=>{let r=new CustomEvent("activechange",{detail:{tabId:this.tabId,active:e},bubbles:!0});this.dispatchEvent(r)}}connectedCallback(){super.connectedCallback(),this.role="tab",this.softDisabled=void 0,this.size=void 0,this.type=void 0,this.ariaStateKey="aria-selected",!this.tabId&&this.onerror&&this.onerror("tab id is required")}modifyIconName(e){this.iconName&&(e?(this.prevIconName=this.iconName,this.iconName=`${Kr(this.iconName)}-filled`):this.prevIconName&&(this.iconName=this.prevIconName))}setVariant(e){this.setAttribute("variant",Object.values(Ka).includes(e)?e:gi.VARIANT)}setActive(e,r){super.setActive(e,r),this.modifyIconName(r)}executeAction(){this.handleTabActiveChange(this.active)}update(e){super.update(e),e.has("variant")&&this.setVariant(this.variant)}render(){return m`
|
3610
3882
|
<div part="container">
|
3611
3883
|
${this.iconName?m` <mdc-icon name="${this.iconName}" size="1" length-unit="rem" part="icon"></mdc-icon>`:g}
|
3612
3884
|
${this.text?m` <mdc-text
|
3613
|
-
type=${this.active?
|
3614
|
-
tagname=${
|
3885
|
+
type=${this.active?S.BODY_MIDSIZE_BOLD:S.BODY_MIDSIZE_MEDIUM}
|
3886
|
+
tagname=${w.SPAN}
|
3615
3887
|
data-text=${this.text}
|
3616
3888
|
part="text"
|
3617
3889
|
>${this.text}</mdc-text
|
@@ -3620,7 +3892,50 @@
|
|
3620
3892
|
<slot name="chip"></slot>
|
3621
3893
|
</div>
|
3622
3894
|
<div part="indicator"></div>
|
3623
|
-
`}};
|
3895
|
+
`}};ht.styles=[...re.styles,...hc],n([c({type:Boolean,reflect:!0})],ht.prototype,"active",2),n([c({type:String,reflect:!0})],ht.prototype,"text",2),n([c({type:String,reflect:!0})],ht.prototype,"variant",2),n([c({type:String,reflect:!0,attribute:"tab-id"})],ht.prototype,"tabId",2);var pe=ht;pe.register(uc);var yp=pe;var xp=[Io,u`
|
3896
|
+
:host {
|
3897
|
+
--mdc-tablist-focus-ring-outer-width: var(--mdc-focus-ring-outer-width);
|
3898
|
+
--mdc-tablist-gap: 0.5rem;
|
3899
|
+
--mdc-tablist-width: 100%;
|
3900
|
+
--mdc-tablist-arrow-button-margin: 0.75rem;
|
3901
|
+
|
3902
|
+
width: var(--mdc-tablist-width);
|
3903
|
+
display: flex;
|
3904
|
+
align-items: center;
|
3905
|
+
|
3906
|
+
::slotted(mdc-tab) {
|
3907
|
+
width: initial;
|
3908
|
+
}
|
3909
|
+
}
|
3910
|
+
|
3911
|
+
:host .container {
|
3912
|
+
display: flex;
|
3913
|
+
overflow-x: hidden;
|
3914
|
+
gap: var(--mdc-tablist-gap);
|
3915
|
+
padding: var(--mdc-tablist-focus-ring-outer-width);
|
3916
|
+
}
|
3917
|
+
|
3918
|
+
:host mdc-button[prefix-icon="arrow-left-regular"] {
|
3919
|
+
margin-right: var(--mdc-tablist-arrow-button-margin);
|
3920
|
+
}
|
3921
|
+
|
3922
|
+
:host mdc-button[prefix-icon="arrow-right-regular"] {
|
3923
|
+
margin-left: var(--mdc-tablist-arrow-button-margin);
|
3924
|
+
}
|
3925
|
+
`],fc=[...xp];var bc=f.constructTagName("tablist"),po={LEFT:"ArrowLeft",RIGHT:"ArrowRight",HOME:"Home",END:"End"},kr={FORWARD:"forward",BACKWARD:"backward"};var vi=i=>i[0],Za=i=>i[i.length-1],gc=(i,t)=>{let e=i.findIndex(r=>t===r)-1;return i[(e+i.length)%i.length]},vc=(i,t)=>{let e=i.findIndex(r=>t===r)+1;return i[e%i.length]},yc=(i,t)=>i.find(e=>e.tabId===t),Xa=i=>i.find(t=>t.active);var Ce=class extends v{constructor(){super();this.showForwardArrowButton=!1;this.showBackwardArrowButton=!1;this.isRtl=()=>{var e;return((e=document.querySelector("html"))==null?void 0:e.getAttribute("dir"))==="rtl"||window.getComputedStyle(this).direction==="rtl"};this.fireTabChangeEvent=e=>{let r=new CustomEvent("change",{detail:{tabId:e.tabId}});this.dispatchEvent(r)};this.handleFocus=async e=>{if(e.relatedTarget instanceof pe||!(e.target instanceof pe))return;let r=Xa(this.tabs||[]);r instanceof pe&&await this.focusTab(r)};this.handleMousedown=e=>{e.target instanceof pe&&e.preventDefault()};this.handleNestedTabActiveChange=async e=>{e.stopPropagation();let r=e.target;r instanceof pe&&(this.setActiveTab(r),await this.focusTab(r),this.activeTabId=r.tabId)};this.resetTabIndexAndSetNewTabIndex=e=>{var r;(r=this.tabs)==null||r.forEach(o=>{o.setAttribute("tabindex",o===e?"0":"-1")})};this.setActiveTab=e=>{var r;(r=this.tabs)==null||r.forEach(o=>{o===e?o.setAttribute("active",""):o.removeAttribute("active")})};this.focusTab=async e=>{e instanceof pe&&(e!==(document==null?void 0:document.activeElement)&&(this.resetTabIndexAndSetNewTabIndex(e),e.focus()),e.scrollIntoView({behavior:"instant",block:"start",inline:"center"}),await this.handleArrowButtonVisibility())};this.handleKeydown=async e=>{let r=e.target;if(!(r instanceof pe)||!this.tabs)return;let o=gc(this.tabs,r),a=vc(this.tabs,r),s=vi(this.tabs),l=Za(this.tabs);switch(e.code){case po.LEFT:e.preventDefault(),await this.focusTab(this.isRtl()?a:o);break;case po.RIGHT:e.preventDefault(),await this.focusTab(this.isRtl()?o:a);break;case po.HOME:await this.focusTab(s);break;case po.END:await this.focusTab(l);break;default:}};this.shouldShowArrowButton=e=>e===kr.FORWARD?this.showForwardArrowButton:this.showBackwardArrowButton;this.switchFocus=async()=>{var e,r;await this.updateComplete,!this.showBackwardArrowButton&&!this.showForwardArrowButton?(e=Xa(this.tabs||[]))==null||e.focus():(this.showBackwardArrowButton&&!this.showForwardArrowButton||this.showForwardArrowButton&&!this.showBackwardArrowButton)&&((r=this.notFocusedArrowButton)==null||r.focus())};this.handleArrowButtonVisibility=async()=>{var b,x,y;if(!this.tabs||!this.tabsContainer)return;let e=!1;((b=this.shadowRoot)==null?void 0:b.activeElement)instanceof At&&(e=!0);let r=vi(this.tabs),o=Za(this.tabs),a=r.getBoundingClientRect().left,s=(x=this.tabsContainer)==null?void 0:x.getBoundingClientRect().left,l=o.getBoundingClientRect().right,d=(y=this.tabsContainer)==null?void 0:y.getBoundingClientRect().right,p=r.getBoundingClientRect().right,h=o.getBoundingClientRect().left;if(!this.isRtl()){a<=s?this.showBackwardArrowButton=!0:this.showBackwardArrowButton=!1,l>d?this.showForwardArrowButton=!0:this.showForwardArrowButton=!1,e&&await this.switchFocus();return}p>d?this.showBackwardArrowButton=!0:this.showBackwardArrowButton=!1,h<s?this.showForwardArrowButton=!0:this.showForwardArrowButton=!1,e&&await this.switchFocus()};this.scrollTabs=async e=>{var a;let r=this.isRtl()?-1:1,o=this.isRtl()?1:-1;(a=this.tabsContainer)==null||a.scrollBy({left:this.tabsContainer.clientWidth*(e===kr.FORWARD?r:o),behavior:"instant"}),await this.handleArrowButtonVisibility()};this.addEventListener("keydown",this.handleKeydown),this.addEventListener("activechange",this.handleNestedTabActiveChange)}async firstUpdated(){var o,a,s;if(!this.tabs)return;if(Array.isArray(this.tabs)&&this.tabs.length===0){this.onerror&&this.onerror("The tablist component must have at least one child tab");return}let e=this.tabs.map(l=>l.tabId);new Set(e).size!==this.tabs.length&&this.onerror&&this.onerror("The tabs inside the tab list must have unique tab ids"),new ResizeObserver(async()=>{let{activeElement:l}=document;l instanceof pe&&l.scrollIntoView({behavior:"instant",block:"start",inline:"center"}),await this.handleArrowButtonVisibility()}).observe(this),this.activeTabId||(this.activeTabId=(o=vi(this.tabs))==null?void 0:o.tabId),(a=this.tabsContainer)==null||a.addEventListener("focusin",this.handleFocus),(s=this.tabsContainer)==null||s.addEventListener("mousedown",this.handleMousedown)}async update(e){if(super.update(e),e.has("activeTabId")){if(!this.tabs||!this.activeTabId)return;let r=yc(this.tabs,this.activeTabId);if(!(r instanceof pe))return;this.setActiveTab(r),e.get("activeTabId")?(this.fireTabChangeEvent(r),await this.focusTab(r)):this.resetTabIndexAndSetNewTabIndex(r)}}render(){let e=this.isRtl()?"left":"right",r=this.isRtl()?"right":"left",o=a=>m` ${this.shouldShowArrowButton(a)?m`<mdc-button
|
3926
|
+
variant="tertiary"
|
3927
|
+
prefix-icon="arrow-${a===kr.FORWARD?e:r}-regular"
|
3928
|
+
aria-label="Scroll tabs ${a===kr.FORWARD?e:r}"
|
3929
|
+
@click="${()=>this.scrollTabs(a)}"
|
3930
|
+
></mdc-button>`:g}`;return m` ${o("backward")}
|
3931
|
+
<div
|
3932
|
+
class="container"
|
3933
|
+
role="tablist"
|
3934
|
+
tabindex="-1"
|
3935
|
+
aria-label="${T(this.dataAriaLabel)}">
|
3936
|
+
<slot></slot>
|
3937
|
+
</div>
|
3938
|
+
${o(kr.FORWARD)}`}};Ce.styles=[...v.styles,...fc],n([c({type:String,attribute:"active-tab-id",reflect:!0})],Ce.prototype,"activeTabId",2),n([c({type:String,attribute:"data-aria-label"})],Ce.prototype,"dataAriaLabel",2),n([Ue(".container")],Ce.prototype,"tabsContainer",2),n([Ue("mdc-button:not(:focus-visible)")],Ce.prototype,"notFocusedArrowButton",2),n([G({selector:"mdc-tab"})],Ce.prototype,"tabs",2),n([L()],Ce.prototype,"showForwardArrowButton",2),n([L()],Ce.prototype,"showBackwardArrowButton",2);var ja=Ce;ja.register(bc);var Ep=ja;var Tp=[u`
|
3624
3939
|
:host {
|
3625
3940
|
--mdc-textarea-disabled-border-color: var(--mds-color-theme-outline-primary-disabled);
|
3626
3941
|
--mdc-textarea-disabled-text-color: var(--mds-color-theme-text-primary-disabled);
|
@@ -3741,11 +4056,11 @@
|
|
3741
4056
|
pointer-events: none;
|
3742
4057
|
}
|
3743
4058
|
|
3744
|
-
`,...
|
4059
|
+
`,..._(!0)],xc=Tp;var Ec=f.constructTagName("textarea"),Qa={HARD:"hard",SOFT:"soft"},Tc={OFF:"off",ON:"on"},yi={CHARACTER_COUNTER_TYPE:S.BODY_MIDSIZE_REGULAR,ROWS:5,COLS:40,WRAP:Qa.SOFT};var Z=class extends se(U(be)){constructor(){super(...arguments);this.readonly=!1;this.rows=yi.ROWS;this.cols=yi.COLS;this.wrap=Qa.SOFT;this.autocapitalize=ai.OFF;this.autocomplete=Tc.OFF;this.autofocus=!1;this.characterLimitExceedingFired=!1}get textarea(){return this.inputElement}connectedCallback(){var e;super.connectedCallback(),this.value=((e=this.textContent)==null?void 0:e.trim())||this.value,this.updateComplete.then(()=>{this.textarea&&(this.textarea.checkValidity(),this.setTextareaValidity(),this.internals.setFormValue(this.textarea.value))}).catch(r=>{this.onerror&&this.onerror(r)})}setTextareaValidity(){this.requiredLabel&&this.validationMessage&&this.value===""?this.textarea.setCustomValidity(this.validationMessage):this.maxCharacterLimit&&this.value.length>this.maxCharacterLimit&&this.helpTextType===W.ERROR&&this.helpText?this.textarea.setCustomValidity(this.helpText):this.textarea.setCustomValidity(""),this.setValidity()}formResetCallback(){this.value="",this.requestUpdate()}formStateRestoreCallback(e){this.value=e}handleValueChange(){this.updateComplete.then(()=>{this.setTextareaValidity()}).catch(e=>{this.onerror&&this.onerror(e)})}updated(e){super.updated(e),e.has("value")&&(this.handleValueChange(),this.handleCharacterOverflowStateChange())}attributeChangedCallback(e,r,o){super.attributeChangedCallback(e,r,o),["maxlength","minlength","required"].includes(e)&&this.updateComplete.then(()=>{this.setTextareaValidity()}).catch(s=>{this.onerror&&this.onerror(s)})}dispatchCharacterOverflowStateChangeEvent(){this.dispatchEvent(new CustomEvent("limitexceeded",{detail:{currentCharacterCount:this.value.length,maxCharacterLimit:this.maxCharacterLimit,value:this.value},bubbles:!0,composed:!0}))}handleCharacterOverflowStateChange(){this.maxCharacterLimit&&(this.value.length>this.maxCharacterLimit&&!this.characterLimitExceedingFired?(this.dispatchCharacterOverflowStateChangeEvent(),this.characterLimitExceedingFired=!0):this.value.length<=this.maxCharacterLimit&&this.characterLimitExceedingFired&&(this.dispatchCharacterOverflowStateChangeEvent(),this.characterLimitExceedingFired=!1))}updateValue(){this.value=this.textarea.value,this.internals.setFormValue(this.textarea.value)}onChange(e){this.updateValue();let r=e.constructor;this.dispatchEvent(new r(e.type,e))}renderCharacterCounter(){return this.maxCharacterLimit?m`
|
3745
4060
|
<mdc-text
|
3746
4061
|
part="character-counter"
|
3747
4062
|
tagname="span"
|
3748
|
-
type=${
|
4063
|
+
type=${yi.CHARACTER_COUNTER_TYPE}
|
3749
4064
|
>
|
3750
4065
|
${this.value.length<10?`0${this.value.length}`:this.value.length}/${this.maxCharacterLimit}
|
3751
4066
|
</mdc-text>
|
@@ -3783,7 +4098,7 @@
|
|
3783
4098
|
></textarea>
|
3784
4099
|
</div>
|
3785
4100
|
${this.renderTextareaFooter()}
|
3786
|
-
`}};
|
4101
|
+
`}};Z.styles=[...be.styles,...xc],n([c({type:String})],Z.prototype,"placeholder",2),n([c({type:Boolean})],Z.prototype,"readonly",2),n([c({type:Number})],Z.prototype,"rows",2),n([c({type:Number})],Z.prototype,"cols",2),n([c({type:String})],Z.prototype,"wrap",2),n([c({type:String})],Z.prototype,"autocapitalize",2),n([c({type:String})],Z.prototype,"autocomplete",2),n([c({type:Boolean})],Z.prototype,"autofocus",2),n([c({type:String})],Z.prototype,"dirname",2),n([c({type:Number})],Z.prototype,"maxlength",2),n([c({type:Number})],Z.prototype,"minlength",2),n([c({type:Number,attribute:"max-character-limit"})],Z.prototype,"maxCharacterLimit",2),n([Ue("textarea")],Z.prototype,"inputElement",2);var Ja=Z;Ja.register(Ec);var Ap=Ja;var xi=f.constructTagName("themeprovider"),es={THEMECLASS:"mds-theme-stable-darkWebex"};var Ei=class{constructor(t){this.themeclass=t}};Ei.context=xi;var Ti=Ei;var Sp=u`
|
3787
4102
|
:host {
|
3788
4103
|
--mdc-themeprovider-color-default: var(--mds-color-theme-text-primary-normal);
|
3789
4104
|
--mdc-themeprovider-font-family: var(--mds-font-family-primary);
|
@@ -3812,7 +4127,7 @@
|
|
3812
4127
|
* {
|
3813
4128
|
scrollbar-color: var(--mdc-themeprovider-scrollbar-thumb-color) var(--mdc-themeprovider-scrollbar-track-color);
|
3814
4129
|
}
|
3815
|
-
`,
|
4130
|
+
`,Ac=[Sp];var wr=class extends Qt{constructor(){super({context:Ti.context,initialValue:new Ti(es.THEMECLASS)});this.themeclass=es.THEMECLASS}static get Context(){return Ti.context}updated(e){super.updated(e),e.has("themeclass")&&(this.setThemeInClassList(),this.currentThemeClass=this.themeclass)}updateContext(){this.context.value.themeclass!==this.themeclass&&(this.context.value.themeclass=this.themeclass,this.context.updateObservers())}setThemeInClassList(){this.currentThemeClass&&this.classList.remove(...this.currentThemeClass.split(" ")),this.themeclass&&this.classList.add(...this.themeclass.split(" "))}};wr.styles=[...Qt.styles,...Ac],n([L()],wr.prototype,"currentThemeClass",2),n([c({type:String})],wr.prototype,"themeclass",2);var ts=wr;ts.register(xi);var Ip=ts;var Sc=f.constructTagName("toggle"),rs={DEFAULT:"default",COMPACT:"compact"};var os={SIZE:rs.DEFAULT,VALIDATION_MESSAGE:"Please toggle this switch if you want to proceed."};var Cp=[N,u`
|
3816
4131
|
:host {
|
3817
4132
|
--mdc-toggle-width: 3rem;
|
3818
4133
|
--mdc-toggle-height: 1.5rem;
|
@@ -3894,7 +4209,7 @@
|
|
3894
4209
|
:host([disabled]) .mdc-label-text, :host([disabled]) .mdc-help-text {
|
3895
4210
|
color: var(--mdc-toggle-label-color-disabled);
|
3896
4211
|
}
|
3897
|
-
`,...
|
4212
|
+
`,..._(!0)],Ic=Cp;var Ht=class extends se(U(be)){constructor(){super(...arguments);this.checked=!1;this.size=os.SIZE;this.autofocus=!1}connectedCallback(){super.connectedCallback(),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(rs).includes(e)?e:os.SIZE)}update(e){super.update(e),e.has("checked")&&this.setFormValue(),e.has("size")&&this.setToggleSize(this.size)}render(){var e;return m`
|
3898
4213
|
<mdc-statictoggle
|
3899
4214
|
?checked="${this.checked}"
|
3900
4215
|
?disabled="${this.disabled}"
|
@@ -3923,7 +4238,7 @@
|
|
3923
4238
|
</mdc-statictoggle>
|
3924
4239
|
${this.renderLabel()}
|
3925
4240
|
${this.renderHelperText()}
|
3926
|
-
`}}
|
4241
|
+
`}};Ht.styles=[...be.styles,...Ic],n([c({type:Boolean,reflect:!0})],Ht.prototype,"checked",2),n([c({type:String,reflect:!0})],Ht.prototype,"size",2),n([c({type:Boolean,reflect:!0})],Ht.prototype,"autofocus",2);var is=Ht;is.register(Sc);var kp=is;var Cc=f.constructTagName("toggletip"),Gt={CLOSE_BUTTON:!0,CLOSE_BUTTON_ARIA_LABEL:"Close",OFFSET:4,PLACEMENT:de.TOP,CLICK:Rt.CLICK,SHOW_ARROW:!0};var wp=u`
|
3927
4242
|
:host {
|
3928
4243
|
--mdc-toggletip-max-width: 400px;
|
3929
4244
|
--mdc-toggletip-text-color: var(--mds-color-theme-text-primary-normal);
|
@@ -3945,17 +4260,17 @@
|
|
3945
4260
|
:host([color='contrast'])::part(popover-content) {
|
3946
4261
|
color: var(--mdc-toggletip-text-color-contrast);
|
3947
4262
|
}
|
3948
|
-
`,
|
4263
|
+
`,kc=[wp];var Yt=class extends Ie{constructor(){super(...arguments);this.currentAnnouncement="";this.screenreaderAnnouncerIdentity=""}connectedCallback(){super.connectedCallback(),this.closeButton=Gt.CLOSE_BUTTON,this.closeButtonAriaLabel=Gt.CLOSE_BUTTON_ARIA_LABEL,this.placement=Gt.PLACEMENT,this.trigger=Gt.CLICK,this.showArrow=Gt.SHOW_ARROW,this.interactive=!0,this.backdrop=!0,this.hideOnBlur=!0,this.hideOnEscape=!0,this.hideOnOutsideClick=!0,this.disableAriaExpanded=!1,this.focusBackToTrigger=!0}getToggleTipText(){var e,r;return((r=(e=this.defaultSlotNodes)==null?void 0:e.map(o=>o.textContent).join(" "))==null?void 0:r.trim())||""}onPlacementUpdated(){Object.values(de).includes(this.placement)||(this.placement=Gt.PLACEMENT)}update(e){super.update(e),e.has("placement")&&this.onPlacementUpdated(),e.has("visible")&&(this.currentAnnouncement=this.visible?this.getToggleTipText():"")}render(){return m`
|
3949
4264
|
${super.render()}
|
3950
4265
|
<mdc-screenreaderannouncer
|
3951
4266
|
identity="${this.screenreaderAnnouncerIdentity}"
|
3952
4267
|
announcement="${this.currentAnnouncement}"
|
3953
4268
|
delay="300">
|
3954
4269
|
</mdc-screenreaderannouncer>
|
3955
|
-
`}};
|
4270
|
+
`}};Yt.styles=[...Ie.styles,...kc],n([So()],Yt.prototype,"defaultSlotNodes",2),n([L()],Yt.prototype,"currentAnnouncement",2),n([c({type:String,reflect:!0,attribute:"screenreader-announcer-identity"})],Yt.prototype,"screenreaderAnnouncerIdentity",2);var as=Yt;as.register(Cc);var Np=as;function Wt(i,t,e){var a;let r=(a=e.initialDeps)!=null?a:[],o;return()=>{var s,l,d,p;let h;e.key&&((s=e.debug)!=null&&s.call(e))&&(h=Date.now());let b=i();if(!(b.length!==r.length||b.some((E,A)=>r[A]!==E)))return o;r=b;let y;if(e.key&&((l=e.debug)!=null&&l.call(e))&&(y=Date.now()),o=t(...b),e.key&&((d=e.debug)!=null&&d.call(e))){let E=Math.round((Date.now()-h)*100)/100,A=Math.round((Date.now()-y)*100)/100,C=A/16,I=(k,O)=>{for(k=String(k);k.length<O;)k=" "+k;return k};console.info(`%c\u23F1 ${I(A,5)} /${I(E,5)} ms`,`
|
3956
4271
|
font-size: .6rem;
|
3957
4272
|
font-weight: bold;
|
3958
|
-
color: hsl(${Math.max(0,Math.min(120-120*w,120))}deg 100% 31%);`,e==null?void 0:e.key)}return(p=e==null?void 0:e.onChange)==null||p.call(e,o),o}}function di(i,t){if(i===void 0)throw new Error(`Unexpected undefined${t?`: ${t}`:""}`);return i}var Ql=(i,t)=>Math.abs(i-t)<1,Jl=(i,t,e)=>{let r;return function(...o){i.clearTimeout(r),r=i.setTimeout(()=>t.apply(this,o),e)}};var Ym=i=>i,qm=i=>{let t=Math.max(i.startIndex-i.overscan,0),e=Math.min(i.endIndex+i.overscan,i.count-1),r=[];for(let o=t;o<=e;o++)r.push(o);return r},tc=(i,t)=>{let e=i.scrollElement;if(!e)return;let r=i.targetWindow;if(!r)return;let o=s=>{let{width:l,height:d}=s;t({width:Math.round(l),height:Math.round(d)})};if(o(e.getBoundingClientRect()),!r.ResizeObserver)return()=>{};let a=new r.ResizeObserver(s=>{let l=s[0];if(l!=null&&l.borderBoxSize){let d=l.borderBoxSize[0];if(d){o({width:d.inlineSize,height:d.blockSize});return}}o(e.getBoundingClientRect())});return a.observe(e,{box:"border-box"}),()=>{a.unobserve(e)}},ec={passive:!0};var Zm=typeof window>"u"?!0:"onscrollend"in window,rc=(i,t)=>{let e=i.scrollElement;if(!e)return;let r=i.targetWindow;if(!r)return;let o=0,a=i.options.useScrollendEvent&&Zm?()=>{}:Jl(r,()=>{t(o,!1)},i.options.isScrollingResetDelay),s=p=>()=>{let{horizontal:h,isRtl:b}=i.options;o=h?e.scrollLeft*(b&&-1||1):e.scrollTop,a(),t(o,p)},l=s(!0),d=s(!1);return d(),e.addEventListener("scroll",l,ec),e.addEventListener("scrollend",d,ec),()=>{e.removeEventListener("scroll",l),e.removeEventListener("scrollend",d)}};var Xm=(i,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(i.getBoundingClientRect()[e.options.horizontal?"width":"height"])};var oc=(i,{adjustments:t=0,behavior:e},r)=>{var o,a;let s=i+t;(a=(o=r.scrollElement)==null?void 0:o.scrollTo)==null||a.call(o,{[r.options.horizontal?"left":"top"]:s,behavior:e})},mi=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(o=>{o.forEach(a=>{this._measureElement(a.target,a)})}));return{disconnect:()=>{var o;(o=r())==null||o.disconnect(),e=null},observe:o=>{var a;return(a=r())==null?void 0:a.observe(o,{box:"border-box"})},unobserve:o=>{var a;return(a=r())==null?void 0:a.unobserve(o)}}})(),this.range=null,this.setOptions=e=>{Object.entries(e).forEach(([r,o])=>{typeof o>"u"&&delete e[r]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:Ym,rangeExtractor:qm,onChange:()=>{},measureElement:Xm,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,o;(o=(r=this.options).onChange)==null||o.call(r,this,e)},this.maybeNotify=Vt(()=>(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 o;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=(o=(e=this.scrollElement)==null?void 0:e.window)!=null?o:null,this.elementsCache.forEach(a=>{this.observer.observe(a)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,a=>{this.scrollRect=a,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(a,s)=>{this.scrollAdjustments=0,this.scrollDirection=s?this.getScrollOffset()<a?"forward":"backward":null,this.scrollOffset=a,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 o=new Map,a=new Map;for(let s=r-1;s>=0;s--){let l=e[s];if(o.has(l.lane))continue;let d=a.get(l.lane);if(d==null||l.end>d.end?a.set(l.lane,l):l.end<d.end&&o.set(l.lane,!0),o.size===this.options.lanes)break}return a.size===this.options.lanes?Array.from(a.values()).sort((s,l)=>s.end===l.end?s.index-l.index:s.end-l.end)[0]:void 0},this.getMeasurementOptions=Vt(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(e,r,o,a,s)=>(this.pendingMeasuredCacheIndexes=[],{count:e,paddingStart:r,scrollMargin:o,getItemKey:a,enabled:s}),{key:!1}),this.getMeasurements=Vt(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:e,paddingStart:r,scrollMargin:o,getItemKey:a,enabled:s},l)=>{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 d=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];let p=this.measurementsCache.slice(0,d);for(let h=d;h<e;h++){let b=a(h),x=this.options.lanes===1?p[h-1]:this.getFurthestMeasurement(p,h),y=x?x.end+this.options.gap:r+o,E=l.get(b),A=typeof E=="number"?E:this.options.estimateSize(h),w=y+A,S=x?x.lane:h%this.options.lanes;p[h]={index:h,start:y,size:A,end:w,key:b,lane:S}}return this.measurementsCache=p,p},{key:!1,debug:()=>this.options.debug}),this.calculateRange=Vt(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset()],(e,r,o)=>this.range=e.length>0&&r>0?Km({measurements:e,outerSize:r,scrollOffset:o}):null,{key:!1,debug:()=>this.options.debug}),this.getIndexes=Vt(()=>{let e=null,r=null,o=this.calculateRange();return o&&(e=o.startIndex,r=o.endIndex),[this.options.rangeExtractor,this.options.overscan,this.options.count,e,r]},(e,r,o,a,s)=>a===null||s===null?[]:e({startIndex:a,endIndex:s,overscan:r,count:o}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=e=>{let r=this.options.indexAttribute,o=e.getAttribute(r);return o?parseInt(o,10):(console.warn(`Missing attribute name '${r}={index}' on measured element.`),-1)},this._measureElement=(e,r)=>{let o=this.indexFromElement(e),a=this.measurementsCache[o];if(!a)return;let s=a.key,l=this.elementsCache.get(s);l!==e&&(l&&this.observer.unobserve(l),this.observer.observe(e),this.elementsCache.set(s,e)),e.isConnected&&this.resizeItem(o,this.options.measureElement(e,r,this))},this.resizeItem=(e,r)=>{var l;let o=this.measurementsCache[e];if(!o)return;let a=(l=this.itemSizeCache.get(o.key))!=null?l:o.size,s=r-a;s!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(o,s,this):o.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=s,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(o.index),this.itemSizeCache=new Map(this.itemSizeCache.set(o.key,r)),this.notify(!1))},this.measureElement=e=>{if(!e){this.elementsCache.forEach((r,o)=>{r.isConnected||(this.observer.unobserve(r),this.elementsCache.delete(o))});return}this._measureElement(e,void 0)},this.getVirtualItems=Vt(()=>[this.getIndexes(),this.getMeasurements()],(e,r)=>{let o=[];for(let a=0,s=e.length;a<s;a++){let l=e[a],d=r[l];o.push(d)}return o},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=e=>{let r=this.getMeasurements();if(r.length!==0)return di(r[ic(0,r.length-1,o=>di(r[o]).start,e)])},this.getOffsetForAlignment=(e,r)=>{let o=this.getSize(),a=this.getScrollOffset();r==="auto"&&e>=a+o&&(r="end"),r==="end"&&(e-=o);let s=this.options.horizontal?"scrollWidth":"scrollHeight",d=(this.scrollElement?"document"in this.scrollElement?this.scrollElement.document.documentElement[s]:this.scrollElement[s]:0)-o;return Math.max(Math.min(d,e),0)},this.getOffsetForIndex=(e,r="auto")=>{e=Math.max(0,Math.min(e,this.options.count-1));let o=this.measurementsCache[e];if(!o)return;let a=this.getSize(),s=this.getScrollOffset();if(r==="auto")if(o.end>=s+a-this.options.scrollPaddingEnd)r="end";else if(o.start<=s+this.options.scrollPaddingStart)r="start";else return[s,r];let l=o.start-this.options.scrollPaddingStart+(o.size-a)/2;switch(r){case"center":return[this.getOffsetForAlignment(l,r),r];case"end":return[this.getOffsetForAlignment(o.end+this.options.scrollPaddingEnd,r),r];default:return[this.getOffsetForAlignment(o.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:o}={})=>{this.cancelScrollToIndex(),o==="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:o})},this.scrollToIndex=(e,{align:r="auto",behavior:o}={})=>{e=Math.max(0,Math.min(e,this.options.count-1)),this.cancelScrollToIndex(),o==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size.");let a=this.getOffsetForIndex(e,r);if(!a)return;let[s,l]=a;this._scrollToOffset(s,{adjustments:void 0,behavior:o}),o!=="smooth"&&this.isDynamicMode()&&this.targetWindow&&(this.scrollToIndexTimeoutId=this.targetWindow.setTimeout(()=>{if(this.scrollToIndexTimeoutId=null,this.elementsCache.has(this.options.getItemKey(e))){let[p]=di(this.getOffsetForIndex(e,l));Ql(p,this.getScrollOffset())||this.scrollToIndex(e,{align:l,behavior:o})}else this.scrollToIndex(e,{align:l,behavior:o})}))},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 a;var e;let r=this.getMeasurements(),o;return r.length===0?o=this.options.paddingStart:o=this.options.lanes===1?(a=(e=r[r.length-1])==null?void 0:e.end)!=null?a:0:Math.max(...r.slice(-this.options.lanes).map(s=>s.end)),Math.max(o-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(e,{adjustments:r,behavior:o})=>{this.options.scrollToFn(e,{behavior:o,adjustments:r},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(t)}},ic=(i,t,e,r)=>{for(;i<=t;){let o=(i+t)/2|0,a=e(o);if(a<r)i=o+1;else if(a>r)t=o-1;else return o}return i>0?i-1:0};function Km({measurements:i,outerSize:t,scrollOffset:e}){let r=i.length-1,a=ic(0,r,l=>i[l].start,e),s=a;for(;s<r&&i[s].end<e+t;)s++;return{startIndex:a,endIndex:s}}var Va=class{constructor(t,e){this.cleanup=()=>{},(this.host=t).addController(this);let r={...e,onChange:(o,a)=>{var s;this.host.updateComplete.then(()=>this.host.requestUpdate()),(s=e.onChange)==null||s.call(e,o,a)}};this.virtualizer=new mi(r)}getVirtualizer(){return this.virtualizer}async hostConnected(){this.cleanup=this.virtualizer._didMount()}hostUpdated(){this.virtualizer._willUpdate()}hostDisconnected(){this.cleanup()}},pi=class extends Va{constructor(t,e){super(t,{observeElementRect:tc,observeElementOffset:rc,scrollToFn:oc,...e})}};var{I:rR}=ms;var ac=i=>i.strings===void 0;var io=(i,t)=>{var r;let e=i._$AN;if(e===void 0)return!1;for(let o of e)(r=o._$AO)==null||r.call(o,t,!1),io(o,t);return!0},hi=i=>{let t,e;do{if((t=i._$AM)===void 0)break;e=t._$AN,e.delete(i),i=t}while((e==null?void 0:e.size)===0)},sc=i=>{for(let t;t=i._$AM;i=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(i))break;e.add(i),Jm(t)}};function jm(i){this._$AN!==void 0?(hi(this),this._$AM=i,sc(this)):this._$AM=i}function Qm(i,t=!1,e=0){let r=this._$AH,o=this._$AN;if(o!==void 0&&o.size!==0)if(t)if(Array.isArray(r))for(let a=e;a<r.length;a++)io(r[a],!1),hi(r[a]);else r!=null&&(io(r,!1),hi(r));else io(this,i)}var Jm=i=>{var t,e;i.type==ko.CHILD&&((t=i._$AP)!=null||(i._$AP=Qm),(e=i._$AQ)!=null||(i._$AQ=jm))},ui=class extends tr{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,r){super._$AT(t,e,r),sc(this),this.isConnected=t._$AU}_$AO(t,e=!0){var r,o;t!==this.isConnected&&(this.isConnected=t,t?(r=this.reconnected)==null||r.call(this):(o=this.disconnected)==null||o.call(this)),e&&(io(this,t),hi(this))}setValue(t){if(ac(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 nc=()=>new Fa,Fa=class{},Ua=new WeakMap,lc=Vr(class extends ui{render(i){return g}update(i,[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=i.options)==null?void 0:r.host,this.rt(this.ct=i.element)),g}rt(i){var t;if(this.isConnected||(i=void 0),typeof this.Y=="function"){let e=(t=this.ht)!=null?t:globalThis,r=Ua.get(e);r===void 0&&(r=new WeakMap,Ua.set(e,r)),r.get(this.Y)!==void 0&&this.Y.call(this.ht,void 0),r.set(this.Y,i),i!==void 0&&this.Y.call(this.ht,i)}else this.Y.value=i}get lt(){var i,t,e;return typeof this.Y=="function"?(t=Ua.get((i=this.ht)!=null?i: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 ep=[u`
|
4273
|
+
color: hsl(${Math.max(0,Math.min(120-120*C,120))}deg 100% 31%);`,e==null?void 0:e.key)}return(p=e==null?void 0:e.onChange)==null||p.call(e,o),o}}function Ai(i,t){if(i===void 0)throw new Error(`Unexpected undefined${t?`: ${t}`:""}`);return i}var wc=(i,t)=>Math.abs(i-t)<1,Nc=(i,t,e)=>{let r;return function(...o){i.clearTimeout(r),r=i.setTimeout(()=>t.apply(this,o),e)}};var _p=i=>i,Lp=i=>{let t=Math.max(i.startIndex-i.overscan,0),e=Math.min(i.endIndex+i.overscan,i.count-1),r=[];for(let o=t;o<=e;o++)r.push(o);return r},Lc=(i,t)=>{let e=i.scrollElement;if(!e)return;let r=i.targetWindow;if(!r)return;let o=s=>{let{width:l,height:d}=s;t({width:Math.round(l),height:Math.round(d)})};if(o(e.getBoundingClientRect()),!r.ResizeObserver)return()=>{};let a=new r.ResizeObserver(s=>{let l=s[0];if(l!=null&&l.borderBoxSize){let d=l.borderBoxSize[0];if(d){o({width:d.inlineSize,height:d.blockSize});return}}o(e.getBoundingClientRect())});return a.observe(e,{box:"border-box"}),()=>{a.unobserve(e)}},_c={passive:!0};var Rp=typeof window>"u"?!0:"onscrollend"in window,Rc=(i,t)=>{let e=i.scrollElement;if(!e)return;let r=i.targetWindow;if(!r)return;let o=0,a=i.options.useScrollendEvent&&Rp?()=>{}:Nc(r,()=>{t(o,!1)},i.options.isScrollingResetDelay),s=p=>()=>{let{horizontal:h,isRtl:b}=i.options;o=h?e.scrollLeft*(b&&-1||1):e.scrollTop,a(),t(o,p)},l=s(!0),d=s(!1);return d(),e.addEventListener("scroll",l,_c),e.addEventListener("scrollend",d,_c),()=>{e.removeEventListener("scroll",l),e.removeEventListener("scrollend",d)}};var Op=(i,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(i.getBoundingClientRect()[e.options.horizontal?"width":"height"])};var Oc=(i,{adjustments:t=0,behavior:e},r)=>{var o,a;let s=i+t;(a=(o=r.scrollElement)==null?void 0:o.scrollTo)==null||a.call(o,{[r.options.horizontal?"left":"top"]:s,behavior:e})},Si=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(o=>{o.forEach(a=>{this._measureElement(a.target,a)})}));return{disconnect:()=>{var o;(o=r())==null||o.disconnect(),e=null},observe:o=>{var a;return(a=r())==null?void 0:a.observe(o,{box:"border-box"})},unobserve:o=>{var a;return(a=r())==null?void 0:a.unobserve(o)}}})(),this.range=null,this.setOptions=e=>{Object.entries(e).forEach(([r,o])=>{typeof o>"u"&&delete e[r]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:_p,rangeExtractor:Lp,onChange:()=>{},measureElement:Op,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,o;(o=(r=this.options).onChange)==null||o.call(r,this,e)},this.maybeNotify=Wt(()=>(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 o;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=(o=(e=this.scrollElement)==null?void 0:e.window)!=null?o:null,this.elementsCache.forEach(a=>{this.observer.observe(a)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,a=>{this.scrollRect=a,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(a,s)=>{this.scrollAdjustments=0,this.scrollDirection=s?this.getScrollOffset()<a?"forward":"backward":null,this.scrollOffset=a,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 o=new Map,a=new Map;for(let s=r-1;s>=0;s--){let l=e[s];if(o.has(l.lane))continue;let d=a.get(l.lane);if(d==null||l.end>d.end?a.set(l.lane,l):l.end<d.end&&o.set(l.lane,!0),o.size===this.options.lanes)break}return a.size===this.options.lanes?Array.from(a.values()).sort((s,l)=>s.end===l.end?s.index-l.index:s.end-l.end)[0]:void 0},this.getMeasurementOptions=Wt(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(e,r,o,a,s)=>(this.pendingMeasuredCacheIndexes=[],{count:e,paddingStart:r,scrollMargin:o,getItemKey:a,enabled:s}),{key:!1}),this.getMeasurements=Wt(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:e,paddingStart:r,scrollMargin:o,getItemKey:a,enabled:s},l)=>{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 d=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];let p=this.measurementsCache.slice(0,d);for(let h=d;h<e;h++){let b=a(h),x=this.options.lanes===1?p[h-1]:this.getFurthestMeasurement(p,h),y=x?x.end+this.options.gap:r+o,E=l.get(b),A=typeof E=="number"?E:this.options.estimateSize(h),C=y+A,I=x?x.lane:h%this.options.lanes;p[h]={index:h,start:y,size:A,end:C,key:b,lane:I}}return this.measurementsCache=p,p},{key:!1,debug:()=>this.options.debug}),this.calculateRange=Wt(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset()],(e,r,o)=>this.range=e.length>0&&r>0?Mp({measurements:e,outerSize:r,scrollOffset:o}):null,{key:!1,debug:()=>this.options.debug}),this.getIndexes=Wt(()=>{let e=null,r=null,o=this.calculateRange();return o&&(e=o.startIndex,r=o.endIndex),[this.options.rangeExtractor,this.options.overscan,this.options.count,e,r]},(e,r,o,a,s)=>a===null||s===null?[]:e({startIndex:a,endIndex:s,overscan:r,count:o}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=e=>{let r=this.options.indexAttribute,o=e.getAttribute(r);return o?parseInt(o,10):(console.warn(`Missing attribute name '${r}={index}' on measured element.`),-1)},this._measureElement=(e,r)=>{let o=this.indexFromElement(e),a=this.measurementsCache[o];if(!a)return;let s=a.key,l=this.elementsCache.get(s);l!==e&&(l&&this.observer.unobserve(l),this.observer.observe(e),this.elementsCache.set(s,e)),e.isConnected&&this.resizeItem(o,this.options.measureElement(e,r,this))},this.resizeItem=(e,r)=>{var l;let o=this.measurementsCache[e];if(!o)return;let a=(l=this.itemSizeCache.get(o.key))!=null?l:o.size,s=r-a;s!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(o,s,this):o.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=s,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(o.index),this.itemSizeCache=new Map(this.itemSizeCache.set(o.key,r)),this.notify(!1))},this.measureElement=e=>{if(!e){this.elementsCache.forEach((r,o)=>{r.isConnected||(this.observer.unobserve(r),this.elementsCache.delete(o))});return}this._measureElement(e,void 0)},this.getVirtualItems=Wt(()=>[this.getIndexes(),this.getMeasurements()],(e,r)=>{let o=[];for(let a=0,s=e.length;a<s;a++){let l=e[a],d=r[l];o.push(d)}return o},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=e=>{let r=this.getMeasurements();if(r.length!==0)return Ai(r[Mc(0,r.length-1,o=>Ai(r[o]).start,e)])},this.getOffsetForAlignment=(e,r)=>{let o=this.getSize(),a=this.getScrollOffset();r==="auto"&&e>=a+o&&(r="end"),r==="end"&&(e-=o);let s=this.options.horizontal?"scrollWidth":"scrollHeight",d=(this.scrollElement?"document"in this.scrollElement?this.scrollElement.document.documentElement[s]:this.scrollElement[s]:0)-o;return Math.max(Math.min(d,e),0)},this.getOffsetForIndex=(e,r="auto")=>{e=Math.max(0,Math.min(e,this.options.count-1));let o=this.measurementsCache[e];if(!o)return;let a=this.getSize(),s=this.getScrollOffset();if(r==="auto")if(o.end>=s+a-this.options.scrollPaddingEnd)r="end";else if(o.start<=s+this.options.scrollPaddingStart)r="start";else return[s,r];let l=o.start-this.options.scrollPaddingStart+(o.size-a)/2;switch(r){case"center":return[this.getOffsetForAlignment(l,r),r];case"end":return[this.getOffsetForAlignment(o.end+this.options.scrollPaddingEnd,r),r];default:return[this.getOffsetForAlignment(o.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:o}={})=>{this.cancelScrollToIndex(),o==="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:o})},this.scrollToIndex=(e,{align:r="auto",behavior:o}={})=>{e=Math.max(0,Math.min(e,this.options.count-1)),this.cancelScrollToIndex(),o==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size.");let a=this.getOffsetForIndex(e,r);if(!a)return;let[s,l]=a;this._scrollToOffset(s,{adjustments:void 0,behavior:o}),o!=="smooth"&&this.isDynamicMode()&&this.targetWindow&&(this.scrollToIndexTimeoutId=this.targetWindow.setTimeout(()=>{if(this.scrollToIndexTimeoutId=null,this.elementsCache.has(this.options.getItemKey(e))){let[p]=Ai(this.getOffsetForIndex(e,l));wc(p,this.getScrollOffset())||this.scrollToIndex(e,{align:l,behavior:o})}else this.scrollToIndex(e,{align:l,behavior:o})}))},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 a;var e;let r=this.getMeasurements(),o;return r.length===0?o=this.options.paddingStart:o=this.options.lanes===1?(a=(e=r[r.length-1])==null?void 0:e.end)!=null?a:0:Math.max(...r.slice(-this.options.lanes).map(s=>s.end)),Math.max(o-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(e,{adjustments:r,behavior:o})=>{this.options.scrollToFn(e,{behavior:o,adjustments:r},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(t)}},Mc=(i,t,e,r)=>{for(;i<=t;){let o=(i+t)/2|0,a=e(o);if(a<r)i=o+1;else if(a>r)t=o-1;else return o}return i>0?i-1:0};function Mp({measurements:i,outerSize:t,scrollOffset:e}){let r=i.length-1,a=Mc(0,r,l=>i[l].start,e),s=a;for(;s<r&&i[s].end<e+t;)s++;return{startIndex:a,endIndex:s}}var ss=class{constructor(t,e){this.cleanup=()=>{},(this.host=t).addController(this);let r={...e,onChange:(o,a)=>{var s;this.host.updateComplete.then(()=>this.host.requestUpdate()),(s=e.onChange)==null||s.call(e,o,a)}};this.virtualizer=new Si(r)}getVirtualizer(){return this.virtualizer}async hostConnected(){this.cleanup=this.virtualizer._didMount()}hostUpdated(){this.virtualizer._willUpdate()}hostDisconnected(){this.cleanup()}},Ii=class extends ss{constructor(t,e){super(t,{observeElementRect:Lc,observeElementOffset:Rc,scrollToFn:Oc,...e})}};var{I:sM}=Ns;var Dc=i=>i.strings===void 0;var ho=(i,t)=>{var r;let e=i._$AN;if(e===void 0)return!1;for(let o of e)(r=o._$AO)==null||r.call(o,t,!1),ho(o,t);return!0},Ci=i=>{let t,e;do{if((t=i._$AM)===void 0)break;e=t._$AN,e.delete(i),i=t}while((e==null?void 0:e.size)===0)},$c=i=>{for(let t;t=i._$AM;i=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(i))break;e.add(i),zp(t)}};function Dp(i){this._$AN!==void 0?(Ci(this),this._$AM=i,$c(this)):this._$AM=i}function $p(i,t=!1,e=0){let r=this._$AH,o=this._$AN;if(o!==void 0&&o.size!==0)if(t)if(Array.isArray(r))for(let a=e;a<r.length;a++)ho(r[a],!1),Ci(r[a]);else r!=null&&(ho(r,!1),Ci(r));else ho(this,i)}var zp=i=>{var t,e;i.type==Mo.CHILD&&((t=i._$AP)!=null||(i._$AP=$p),(e=i._$AQ)!=null||(i._$AQ=Dp))},ki=class extends nr{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,r){super._$AT(t,e,r),$c(this),this.isConnected=t._$AU}_$AO(t,e=!0){var r,o;t!==this.isConnected&&(this.isConnected=t,t?(r=this.reconnected)==null||r.call(this):(o=this.disconnected)==null||o.call(this)),e&&(ho(this,t),Ci(this))}setValue(t){if(Dc(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 zc=()=>new ls,ls=class{},ns=new WeakMap,Pc=Yr(class extends ki{render(i){return g}update(i,[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=i.options)==null?void 0:r.host,this.rt(this.ct=i.element)),g}rt(i){var t;if(this.isConnected||(i=void 0),typeof this.Y=="function"){let e=(t=this.ht)!=null?t:globalThis,r=ns.get(e);r===void 0&&(r=new WeakMap,ns.set(e,r)),r.get(this.Y)!==void 0&&this.Y.call(this.ht,void 0),r.set(this.Y,i),i!==void 0&&this.Y.call(this.ht,i)}else this.Y.value=i}get lt(){var i,t,e;return typeof this.Y=="function"?(t=ns.get((i=this.ht)!=null?i: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 Pp=[u`
|
3959
4274
|
:host::part(scroll) {
|
3960
4275
|
height: 100%;
|
3961
4276
|
width: 100%;
|
@@ -3965,66 +4280,19 @@
|
|
3965
4280
|
position: relative;
|
3966
4281
|
width: 100%;
|
3967
4282
|
}
|
3968
|
-
`],
|
4283
|
+
`],Vc=Pp;var Uc=f.constructTagName("virtualizedlist"),TM=f.constructTagName("virtualizedwrapper"),Fc={VIRTUALIZER_PROPS:{count:0,estimateSize:()=>0}};var qt=class extends v{constructor(){super();this.virtualizerProps=Fc.VIRTUALIZER_PROPS;this.scrollElementRef=zc();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 Ii(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 l,d;this.virtualizer=e.getVirtualizer();let{getTotalSize:r,getVirtualItems:o,measureElement:a}=this.virtualizer,s=o();if(s!==this.virtualItems){this.virtualItems=s;let p=o(),h={position:"absolute",top:0,left:0,width:"100%",transform:`translateY(${(d=(l=p[0])==null?void 0:l.start)!=null?d:0}px)`};this.setlistdata&&this.setlistdata({virtualItems:p,measureElement:a,listStyle:h})}return m`<div
|
3969
4284
|
part="container"
|
3970
4285
|
style="height: ${r()}px;"
|
3971
4286
|
>
|
3972
4287
|
<slot></slot>
|
3973
4288
|
</div>`}render(){return m`<div
|
3974
|
-
${
|
4289
|
+
${Pc(this.scrollElementRef)}
|
3975
4290
|
part="scroll"
|
3976
4291
|
@scroll=${this.onscroll&&this.onscroll}
|
3977
4292
|
>
|
3978
4293
|
${this.virtualizerController?this.getVirtualizedListWrapper(this.virtualizerController):m``}
|
3979
4294
|
</div>
|
3980
|
-
`}};
|
3981
|
-
:host {
|
3982
|
-
--mdc-tablist-focus-ring-outer-width: var(--mdc-focus-ring-outer-width);
|
3983
|
-
--mdc-tablist-gap: 0.5rem;
|
3984
|
-
--mdc-tablist-width: 100%;
|
3985
|
-
--mdc-tablist-arrow-button-margin: 0.75rem;
|
3986
|
-
|
3987
|
-
width: var(--mdc-tablist-width);
|
3988
|
-
display: flex;
|
3989
|
-
align-items: center;
|
3990
|
-
|
3991
|
-
::slotted(mdc-tab) {
|
3992
|
-
width: initial;
|
3993
|
-
}
|
3994
|
-
}
|
3995
|
-
|
3996
|
-
:host .container {
|
3997
|
-
display: flex;
|
3998
|
-
overflow-x: hidden;
|
3999
|
-
gap: var(--mdc-tablist-gap);
|
4000
|
-
padding: var(--mdc-tablist-focus-ring-outer-width);
|
4001
|
-
}
|
4002
|
-
|
4003
|
-
:host mdc-button[prefix-icon="arrow-left-regular"] {
|
4004
|
-
margin-right: var(--mdc-tablist-arrow-button-margin);
|
4005
|
-
}
|
4006
|
-
|
4007
|
-
:host mdc-button[prefix-icon="arrow-right-regular"] {
|
4008
|
-
margin-left: var(--mdc-tablist-arrow-button-margin);
|
4009
|
-
}
|
4010
|
-
`],pc=[...rp];var hc=f.constructTagName("tablist"),ao={LEFT:"ArrowLeft",RIGHT:"ArrowRight",HOME:"Home",END:"End"},xr={FORWARD:"forward",BACKWARD:"backward"};var fi=i=>i[0],Ha=i=>i[i.length-1],uc=(i,t)=>{let e=i.findIndex(r=>t===r)-1;return i[(e+i.length)%i.length]},fc=(i,t)=>{let e=i.findIndex(r=>t===r)+1;return i[e%i.length]},bc=(i,t)=>i.find(e=>e.tabId===t),Ga=i=>i.find(t=>t.active);var Ae=class extends v{constructor(){super();this.showForwardArrowButton=!1;this.showBackwardArrowButton=!1;this.isRtl=()=>{var e;return((e=document.querySelector("html"))==null?void 0:e.getAttribute("dir"))==="rtl"||window.getComputedStyle(this).direction==="rtl"};this.fireTabChangeEvent=e=>{let r=new CustomEvent("change",{detail:{tabId:e.tabId}});this.dispatchEvent(r)};this.handleFocus=async e=>{if(e.relatedTarget instanceof ce||!(e.target instanceof ce))return;let r=Ga(this.tabs||[]);r instanceof ce&&await this.focusTab(r)};this.handleMousedown=e=>{e.target instanceof ce&&e.preventDefault()};this.handleNestedTabActiveChange=async e=>{e.stopPropagation();let r=e.target;r instanceof ce&&(this.setActiveTab(r),await this.focusTab(r),this.activeTabId=r.tabId)};this.resetTabIndexAndSetNewTabIndex=e=>{var r;(r=this.tabs)==null||r.forEach(o=>{o.setAttribute("tabindex",o===e?"0":"-1")})};this.setActiveTab=e=>{var r;(r=this.tabs)==null||r.forEach(o=>{o===e?o.setAttribute("active",""):o.removeAttribute("active")})};this.focusTab=async e=>{e instanceof ce&&(e!==(document==null?void 0:document.activeElement)&&(this.resetTabIndexAndSetNewTabIndex(e),e.focus()),e.scrollIntoView({behavior:"instant",block:"start",inline:"center"}),await this.handleArrowButtonVisibility())};this.handleKeydown=async e=>{let r=e.target;if(!(r instanceof ce)||!this.tabs)return;let o=uc(this.tabs,r),a=fc(this.tabs,r),s=fi(this.tabs),l=Ha(this.tabs);switch(e.code){case ao.LEFT:e.preventDefault(),await this.focusTab(this.isRtl()?a:o);break;case ao.RIGHT:e.preventDefault(),await this.focusTab(this.isRtl()?o:a);break;case ao.HOME:await this.focusTab(s);break;case ao.END:await this.focusTab(l);break;default:}};this.shouldShowArrowButton=e=>e===xr.FORWARD?this.showForwardArrowButton:this.showBackwardArrowButton;this.switchFocus=async()=>{var e,r;await this.updateComplete,!this.showBackwardArrowButton&&!this.showForwardArrowButton?(e=Ga(this.tabs||[]))==null||e.focus():(this.showBackwardArrowButton&&!this.showForwardArrowButton||this.showForwardArrowButton&&!this.showBackwardArrowButton)&&((r=this.notFocusedArrowButton)==null||r.focus())};this.handleArrowButtonVisibility=async()=>{var b,x,y;if(!this.tabs||!this.tabsContainer)return;let e=!1;((b=this.shadowRoot)==null?void 0:b.activeElement)instanceof bt&&(e=!0);let r=fi(this.tabs),o=Ha(this.tabs),a=r.getBoundingClientRect().left,s=(x=this.tabsContainer)==null?void 0:x.getBoundingClientRect().left,l=o.getBoundingClientRect().right,d=(y=this.tabsContainer)==null?void 0:y.getBoundingClientRect().right,p=r.getBoundingClientRect().right,h=o.getBoundingClientRect().left;if(!this.isRtl()){a<=s?this.showBackwardArrowButton=!0:this.showBackwardArrowButton=!1,l>d?this.showForwardArrowButton=!0:this.showForwardArrowButton=!1,e&&await this.switchFocus();return}p>d?this.showBackwardArrowButton=!0:this.showBackwardArrowButton=!1,h<s?this.showForwardArrowButton=!0:this.showForwardArrowButton=!1,e&&await this.switchFocus()};this.scrollTabs=async e=>{var a;let r=this.isRtl()?-1:1,o=this.isRtl()?1:-1;(a=this.tabsContainer)==null||a.scrollBy({left:this.tabsContainer.clientWidth*(e===xr.FORWARD?r:o),behavior:"instant"}),await this.handleArrowButtonVisibility()};this.addEventListener("keydown",this.handleKeydown),this.addEventListener("activechange",this.handleNestedTabActiveChange)}async firstUpdated(){var o,a,s;if(!this.tabs)return;if(Array.isArray(this.tabs)&&this.tabs.length===0){this.onerror&&this.onerror("The tablist component must have at least one child tab");return}let e=this.tabs.map(l=>l.tabId);new Set(e).size!==this.tabs.length&&this.onerror&&this.onerror("The tabs inside the tab list must have unique tab ids"),new ResizeObserver(async()=>{let{activeElement:l}=document;l instanceof ce&&l.scrollIntoView({behavior:"instant",block:"start",inline:"center"}),await this.handleArrowButtonVisibility()}).observe(this),this.activeTabId||(this.activeTabId=(o=fi(this.tabs))==null?void 0:o.tabId),(a=this.tabsContainer)==null||a.addEventListener("focusin",this.handleFocus),(s=this.tabsContainer)==null||s.addEventListener("mousedown",this.handleMousedown)}async update(e){if(super.update(e),e.has("activeTabId")){if(!this.tabs||!this.activeTabId)return;let r=bc(this.tabs,this.activeTabId);if(!(r instanceof ce))return;this.setActiveTab(r),e.get("activeTabId")?(this.fireTabChangeEvent(r),await this.focusTab(r)):this.resetTabIndexAndSetNewTabIndex(r)}}render(){let e=this.isRtl()?"left":"right",r=this.isRtl()?"right":"left",o=a=>m` ${this.shouldShowArrowButton(a)?m`<mdc-button
|
4011
|
-
variant="tertiary"
|
4012
|
-
prefix-icon="arrow-${a===xr.FORWARD?e:r}-regular"
|
4013
|
-
aria-label="Scroll tabs ${a===xr.FORWARD?e:r}"
|
4014
|
-
@click="${()=>this.scrollTabs(a)}"
|
4015
|
-
></mdc-button>`:g}`;return m` ${o("backward")}
|
4016
|
-
<div
|
4017
|
-
class="container"
|
4018
|
-
role="tablist"
|
4019
|
-
tabindex="-1"
|
4020
|
-
aria-label="${T(this.dataAriaLabel)}">
|
4021
|
-
<slot></slot>
|
4022
|
-
</div>
|
4023
|
-
${o(xr.FORWARD)}`}};Ae.styles=[...v.styles,...pc],n([c({type:String,attribute:"active-tab-id",reflect:!0})],Ae.prototype,"activeTabId",2),n([c({type:String,attribute:"data-aria-label"})],Ae.prototype,"dataAriaLabel",2),n([$e(".container")],Ae.prototype,"tabsContainer",2),n([$e("mdc-button:not(:focus-visible)")],Ae.prototype,"notFocusedArrowButton",2),n([ie({selector:"mdc-tab"})],Ae.prototype,"tabs",2),n([N()],Ae.prototype,"showForwardArrowButton",2),n([N()],Ae.prototype,"showBackwardArrowButton",2);var Wa=Ae;Wa.register(hc);var op=Wa;var Er=class extends Lo(at){constructor(){super(...arguments);this.size=te.SIZE}setSoftDisabled(e,r){r?e.setAttribute("aria-disabled","true"):e.removeAttribute("aria-disabled")}update(e){super.update(e),e.has("softDisabled")&&this.setSoftDisabled(this,this.softDisabled),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()}render(){return m`
|
4024
|
-
${this.prefixIcon?m` <mdc-icon name="${this.prefixIcon}" part="prefix-icon"></mdc-icon>`:""}
|
4025
|
-
<slot @slotchange=${this.inferButtonType}></slot>
|
4026
|
-
${this.postfixIcon?m` <mdc-icon name="${this.postfixIcon}" part="postfix-icon"></mdc-icon>`:""}
|
4027
|
-
`}};Er.styles=[...bt.styles],n([c({type:Number,reflect:!0})],Er.prototype,"size",2),n([c({type:Boolean,attribute:"soft-disabled",reflect:!0})],Er.prototype,"softDisabled",2);var Ya=Er;var vc=f.constructTagName("buttonlink");Ya.register(vc);var ip=Ya;at.register(pl);var ap=at;})();
|
4295
|
+
`}};qt.styles=[...v.styles,...Vc],n([c({type:Function,attribute:"onscroll"})],qt.prototype,"onscroll",2),n([c({type:Object,attribute:"virtualizerprops"})],qt.prototype,"virtualizerProps",2),n([c({type:Function,attribute:"setlistdata"})],qt.prototype,"setlistdata",2);var cs=qt;cs.register(Uc);var Vp=cs;var wi=class extends Xe{connectedCallback(){super.connectedCallback(),this.role="menuitem",this.variant=ao.INSET_RECTANGLE}};wi.styles=[...Xe.styles];var ds=wi;var Bc=f.constructTagName("menuitem");ds.register(Bc);var Up=ds;})();
|
4028
4296
|
/*! Bundled license information:
|
4029
4297
|
|
4030
4298
|
@lit/reactive-element/css-tag.js:
|