@momentum-design/components 0.1.7 → 0.1.9
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/browser/index.js +16 -18
- package/dist/browser/index.js.map +2 -2
- package/dist/components/icon/icon.component.d.ts +29 -16
- package/dist/components/icon/icon.component.js +37 -31
- package/dist/components/icon/icon.styles.js +4 -1
- package/dist/components/icon/icon.utils.d.ts +10 -0
- package/dist/components/icon/icon.utils.js +15 -5
- package/dist/components/themeprovider/themeprovider.component.d.ts +2 -1
- package/dist/components/themeprovider/themeprovider.component.js +1 -1
- package/dist/custom-elements.json +126 -134
- package/dist/models/provider/provider.component.d.ts +1 -1
- package/dist/models/provider/provider.component.js +1 -1
- package/dist/models/provider/provider.styles.js +1 -6
- package/dist/react/icon/index.d.ts +28 -12
- package/dist/react/icon/index.js +28 -12
- package/dist/react/index.d.ts +1 -1
- package/dist/react/index.js +3 -3
- package/package.json +1 -1
package/dist/browser/index.js
CHANGED
@@ -1,15 +1,10 @@
|
|
1
|
-
"use strict";(()=>{var ze=Object.defineProperty;var He=Object.getOwnPropertyDescriptor;var
|
2
|
-
\f\r]`,
|
3
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),Jt=/'/g,Qt=/"/g,re=/^(?:script|style|textarea|title)$/i,Ut=r=>(t,...e)=>({_$litType$:r,strings:t,values:e}),g=Ut(1),Js=Ut(2),Qs=Ut(3),A=Symbol.for("lit-noChange"),u=Symbol.for("lit-nothing"),te=new WeakMap,R=L.createTreeWalker(L,129);function oe(r,t){if(!Pt(r)||!r.hasOwnProperty("raw"))throw Error("invalid template strings array");return Zt!==void 0?Zt.createHTML(t):t}var Qe=(r,t)=>{let e=r.length-1,s=[],i,n=t===2?"<svg>":t===3?"<math>":"",o=j;for(let a=0;a<e;a++){let l=r[a],m,d,p=-1,b=0;for(;b<l.length&&(o.lastIndex=b,d=o.exec(l),d!==null);)b=o.lastIndex,o===j?d[1]==="!--"?o=Xt:d[1]!==void 0?o=Kt:d[2]!==void 0?(re.test(d[2])&&(i=RegExp("</"+d[2],"g")),o=U):d[3]!==void 0&&(o=U):o===U?d[0]===">"?(o=i!=null?i:j,p=-1):d[1]===void 0?p=-2:(p=o.lastIndex-d[2].length,m=d[1],o=d[3]===void 0?U:d[3]==='"'?Qt:Jt):o===Qt||o===Jt?o=U:o===Xt||o===Kt?o=j:(o=U,i=void 0);let S=o===U&&r[a+1].startsWith("/>")?" ":"";n+=o===j?l+Ke:p>=0?(s.push(m),l.slice(0,p)+se+l.slice(p)+T+S):l+T+(p===-2?a:S)}return[oe(r,n+(r[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),s]},Y=class r{constructor({strings:t,_$litType$:e},s){let i;this.parts=[];let n=0,o=0,a=t.length-1,l=this.parts,[m,d]=Qe(t,e);if(this.el=r.createElement(m,s),R.currentNode=this.el.content,e===2||e===3){let p=this.el.content.firstChild;p.replaceWith(...p.childNodes)}for(;(i=R.nextNode())!==null&&l.length<a;){if(i.nodeType===1){if(i.hasAttributes())for(let p of i.getAttributeNames())if(p.endsWith(se)){let b=d[o++],S=i.getAttribute(p).split(T),tt=/([.?@])?(.*)/.exec(b);l.push({type:1,index:n,name:tt[2],strings:S,ctor:tt[1]==="."?Ct:tt[1]==="?"?Tt:tt[1]==="@"?Nt:z}),i.removeAttribute(p)}else p.startsWith(T)&&(l.push({type:6,index:n}),i.removeAttribute(p));if(re.test(i.tagName)){let p=i.textContent.split(T),b=p.length-1;if(b>0){i.textContent=lt?lt.emptyScript:"";for(let S=0;S<b;S++)i.append(p[S],W()),R.nextNode(),l.push({type:2,index:++n});i.append(p[b],W())}}}else if(i.nodeType===8)if(i.data===ie)l.push({type:2,index:n});else{let p=-1;for(;(p=i.data.indexOf(T,p+1))!==-1;)l.push({type:7,index:n}),p+=T.length-1}n++}}static createElement(t,e){let s=L.createElement("template");return s.innerHTML=t,s}};function I(r,t,e=r,s){var o,a,l;if(t===A)return t;let i=s!==void 0?(o=e.o)==null?void 0:o[s]:e.l,n=B(t)?void 0:t._$litDirective$;return(i==null?void 0:i.constructor)!==n&&((a=i==null?void 0:i._$AO)==null||a.call(i,!1),n===void 0?i=void 0:(i=new n(r),i._$AT(r,e,s)),s!==void 0?((l=e.o)!=null?l:e.o=[])[s]=i:e.l=i),i!==void 0&&(t=I(r,i._$AS(r,t.values),i,s)),t}var St=class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){var m;let{el:{content:e},parts:s}=this._$AD,i=((m=t==null?void 0:t.creationScope)!=null?m:L).importNode(e,!0);R.currentNode=i;let n=R.nextNode(),o=0,a=0,l=s[0];for(;l!==void 0;){if(o===l.index){let d;l.type===2?d=new Z(n,n.nextSibling,this,t):l.type===1?d=new l.ctor(n,l.name,l.strings,this,t):l.type===6&&(d=new wt(n,this,t)),this._$AV.push(d),l=s[++a]}o!==(l==null?void 0:l.index)&&(n=R.nextNode(),o++)}return R.currentNode=L,i}p(t){let e=0;for(let s of this._$AV)s!==void 0&&(s.strings!==void 0?(s._$AI(t,s,e),e+=s.strings.length-2):s._$AI(t[e])),e++}},Z=class r{get _$AU(){var t,e;return(e=(t=this._$AM)==null?void 0:t._$AU)!=null?e:this.v}constructor(t,e,s,i){var n;this.type=2,this._$AH=u,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=i,this.v=(n=i==null?void 0:i.isConnected)!=null?n:!0}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&(t==null?void 0:t.nodeType)===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=I(this,t,e),B(t)?t===u||t==null||t===""?(this._$AH!==u&&this._$AR(),this._$AH=u):t!==this._$AH&&t!==A&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Je(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!==u&&B(this._$AH)?this._$AA.nextSibling.data=t:this.T(L.createTextNode(t)),this._$AH=t}$(t){var n;let{values:e,_$litType$:s}=t,i=typeof s=="number"?this._$AC(t):(s.el===void 0&&(s.el=Y.createElement(oe(s.h,s.h[0]),this.options)),s);if(((n=this._$AH)==null?void 0:n._$AD)===i)this._$AH.p(e);else{let o=new St(i,this),a=o.u(this.options);o.p(e),this.T(a),this._$AH=o}}_$AC(t){let e=te.get(t.strings);return e===void 0&&te.set(t.strings,e=new Y(t)),e}k(t){Pt(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,s,i=0;for(let n of t)i===e.length?e.push(s=new r(this.O(W()),this.O(W()),this,this.options)):s=e[i],s._$AI(n),i++;i<e.length&&(this._$AR(s&&s._$AB.nextSibling,i),e.length=i)}_$AR(t=this._$AA.nextSibling,e){var s;for((s=this._$AP)==null?void 0:s.call(this,!1,!0,e);t&&t!==this._$AB;){let i=t.nextSibling;t.remove(),t=i}}setConnected(t){var e;this._$AM===void 0&&(this.v=t,(e=this._$AP)==null||e.call(this,t))}},z=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,s,i,n){this.type=1,this._$AH=u,this._$AN=void 0,this.element=t,this.name=e,this._$AM=i,this.options=n,s.length>2||s[0]!==""||s[1]!==""?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=u}_$AI(t,e=this,s,i){let n=this.strings,o=!1;if(n===void 0)t=I(this,t,e,0),o=!B(t)||t!==this._$AH&&t!==A,o&&(this._$AH=t);else{let a=t,l,m;for(t=n[0],l=0;l<n.length-1;l++)m=I(this,a[s+l],e,l),m===A&&(m=this._$AH[l]),o||(o=!B(m)||m!==this._$AH[l]),m===u?t=u:t!==u&&(t+=(m!=null?m:"")+n[l+1]),this._$AH[l]=m}o&&!i&&this.j(t)}j(t){t===u?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t!=null?t:"")}},Ct=class extends z{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===u?void 0:t}},Tt=class extends z{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==u)}},Nt=class extends z{constructor(t,e,s,i,n){super(t,e,s,i,n),this.type=5}_$AI(t,e=this){var o;if((t=(o=I(this,t,e,0))!=null?o:u)===A)return;let s=this._$AH,i=t===u&&s!==u||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,n=t!==u&&(s===u||i);i&&this.element.removeEventListener(this.name,this,s),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,s;typeof this._$AH=="function"?this._$AH.call((s=(e=this.options)==null?void 0:e.host)!=null?s:this.element,t):this._$AH.handleEvent(t)}},wt=class{constructor(t,e,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){I(this,t)}};var $t=V.litHtmlPolyfillSupport,ee;$t==null||$t(Y,Z),((ee=V.litHtmlVersions)!=null?ee:V.litHtmlVersions=[]).push("3.2.0");var ne=(r,t,e)=>{var n,o;let s=(n=e==null?void 0:e.renderBefore)!=null?n:t,i=s._$litPart$;if(i===void 0){let a=(o=e==null?void 0:e.renderBefore)!=null?o:null;s._$litPart$=i=new Z(t.insertBefore(W(),a),a,void 0,e!=null?e:{})}return i._$AI(r),i};var N=class extends E{constructor(){super(...arguments),this.renderOptions={host:this},this.o=void 0}createRenderRoot(){var e,s;let t=super.createRenderRoot();return(s=(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=ne(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 A}},ae;N._$litElement$=!0,N.finalized=!0,(ae=globalThis.litElementHydrateSupport)==null||ae.call(globalThis,{LitElement:N});var Rt=globalThis.litElementPolyfillSupport;Rt==null||Rt({LitElement:N});var le;((le=globalThis.litElementVersions)!=null?le:globalThis.litElementVersions=[]).push("4.1.0");var Lt=class extends N{static register(t){customElements.get(t)||customElements.define(t,this)}},ce=Lt;var v=ce;var w=class extends Event{constructor(t,e,s){super("context-request",{bubbles:!0,composed:!0}),this.context=t,this.callback=e,this.subscribe=s!=null?s:!1}};var H=class{constructor(t,e,s,i){var n;if(this.subscribe=!1,this.provided=!1,this.value=void 0,this.t=(o,a)=>{this.unsubscribe&&(this.unsubscribe!==a&&(this.provided=!1,this.unsubscribe()),this.subscribe||this.unsubscribe()),this.value=o,this.host.requestUpdate(),this.provided&&!this.subscribe||(this.provided=!0,this.callback&&this.callback(o,a)),this.unsubscribe=a},this.host=t,e.context!==void 0){let o=e;this.context=o.context,this.callback=o.callback,this.subscribe=(n=o.subscribe)!=null?n:!1}else this.context=e,this.callback=s,this.subscribe=i!=null?i:!1;this.host.addController(this)}hostConnected(){this.dispatchRequest()}hostDisconnected(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=void 0)}dispatchRequest(){this.host.dispatchEvent(new w(this.context,this.t,this.subscribe))}};var ct=class{get value(){return this.o}set value(t){this.setValue(t)}setValue(t,e=!1){let s=e||!Object.is(t,this.o);this.o=t,s&&this.updateObservers()}constructor(t){this.subscriptions=new Map,this.updateObservers=()=>{for(let[e,{disposer:s}]of this.subscriptions)e(this.o,s)},t!==void 0&&(this.value=t)}addCallback(t,e,s){if(!s)return void t(this.value);this.subscriptions.has(t)||this.subscriptions.set(t,{disposer:()=>{this.subscriptions.delete(t)},consumerHost:e});let{disposer:i}=this.subscriptions.get(t);t(this.value,i)}clearCallbacks(){this.subscriptions.clear()}};var Ot=class extends Event{constructor(t){super("context-provider",{bubbles:!0,composed:!0}),this.context=t}},k=class extends ct{constructor(t,e,s){var i,n;super(e.context!==void 0?e.initialValue:s),this.onContextRequest=o=>{let a=o.composedPath()[0];o.context===this.context&&a!==this.host&&(o.stopPropagation(),this.addCallback(o.callback,a,o.subscribe))},this.onProviderRequest=o=>{let a=o.composedPath()[0];if(o.context!==this.context||a===this.host)return;let l=new Set;for(let[m,{consumerHost:d}]of this.subscriptions)l.has(m)||(l.add(m),d.dispatchEvent(new w(this.context,m,!0)));o.stopPropagation()},this.host=t,e.context!==void 0?this.context=e.context:this.context=e,this.attachListeners(),(n=(i=this.host).addController)==null||n.call(i,this)}attachListeners(){this.host.addEventListener("context-request",this.onContextRequest),this.host.addEventListener("context-provider",this.onProviderRequest)}hostConnected(){this.host.dispatchEvent(new Ot(this.context))}};var ts=f`
|
1
|
+
"use strict";(()=>{var ze=Object.defineProperty;var He=Object.getOwnPropertyDescriptor;var l=(o,t,e,s)=>{for(var i=s>1?void 0:s?He(t,e):t,n=o.length-1,r;n>=0;n--)(r=o[n])&&(i=(s?r(t,e,i):r(i))||i);return s&&i&&ze(t,e,i),i};var et=globalThis,st=et.ShadowRoot&&(et.ShadyCSS===void 0||et.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,vt=Symbol(),qt=new WeakMap,q=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==vt)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(st&&t===void 0){let s=e!==void 0&&e.length===1;s&&(t=qt.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&qt.set(e,t))}return t}toString(){return this.cssText}},Gt=o=>new q(typeof o=="string"?o:o+"",void 0,vt),f=(o,...t)=>{let e=o.length===1?o[0]:t.reduce((s,i,n)=>s+(r=>{if(r._$cssResult$===!0)return r.cssText;if(typeof r=="number")return r;throw Error("Value passed to 'css' function must be a 'css' function result: "+r+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+o[n+1],o[0]);return new q(e,o,vt)},bt=(o,t)=>{if(st)o.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(let e of t){let s=document.createElement("style"),i=et.litNonce;i!==void 0&&s.setAttribute("nonce",i),s.textContent=e.cssText,o.appendChild(s)}},it=st?o=>o:o=>o instanceof CSSStyleSheet?(t=>{let e="";for(let s of t.cssRules)e+=s.cssText;return Gt(e)})(o):o;var{is:ke,defineProperty:De,getOwnPropertyDescriptor:Fe,getOwnPropertyNames:qe,getOwnPropertySymbols:Ge,getPrototypeOf:je}=Object,C=globalThis,jt=C.trustedTypes,Ve=jt?jt.emptyScript:"",Et=C.reactiveElementPolyfillSupport,G=(o,t)=>o,j={toAttribute(o,t){switch(t){case Boolean:o=o?Ve:null;break;case Object:case Array:o=o==null?o:JSON.stringify(o)}return o},fromAttribute(o,t){let e=o;switch(t){case Boolean:e=o!==null;break;case Number:e=o===null?null:Number(o);break;case Object:case Array:try{e=JSON.parse(o)}catch{e=null}}return e}},ot=(o,t)=>!ke(o,t),Vt={attribute:!0,type:String,converter:j,reflect:!1,hasChanged:ot},Wt,Bt;(Wt=Symbol.metadata)!=null||(Symbol.metadata=Symbol("metadata")),(Bt=C.litPropertyMetadata)!=null||(C.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=Vt){if(e.state&&(e.attribute=!1),this._$Ei(),this.elementProperties.set(t,e),!e.noAccessor){let s=Symbol(),i=this.getPropertyDescriptor(t,s,e);i!==void 0&&De(this.prototype,t,i)}}static getPropertyDescriptor(t,e,s){var r;let{get:i,set:n}=(r=Fe(this.prototype,t))!=null?r:{get(){return this[e]},set(a){this[e]=a}};return{get(){return i==null?void 0:i.call(this)},set(a){let c=i==null?void 0:i.call(this);n.call(this,a),this.requestUpdate(t,c,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){var e;return(e=this.elementProperties.get(t))!=null?e:Vt}static _$Ei(){if(this.hasOwnProperty(G("elementProperties")))return;let t=je(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(G("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(G("properties"))){let e=this.properties,s=[...qe(e),...Ge(e)];for(let i of s)this.createProperty(i,e[i])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[s,i]of e)this.elementProperties.set(s,i)}this._$Eh=new Map;for(let[e,s]of this.elementProperties){let i=this._$Eu(e,s);i!==void 0&&this._$Eh.set(i,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let s=new Set(t.flat(1/0).reverse());for(let i of s)e.unshift(it(i))}else t!==void 0&&e.push(it(t));return e}static _$Eu(t,e){let s=e.attribute;return s===!1?void 0:typeof s=="string"?s: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,s;((e=this._$EO)!=null?e:this._$EO=new Set).add(t),this.renderRoot!==void 0&&this.isConnected&&((s=t.hostConnected)==null||s.call(t))}removeController(t){var e;(e=this._$EO)==null||e.delete(t)}_$E_(){let t=new Map,e=this.constructor.elementProperties;for(let s of e.keys())this.hasOwnProperty(s)&&(t.set(s,this[s]),delete this[s]);t.size>0&&(this._$Ep=t)}createRenderRoot(){var e;let t=(e=this.shadowRoot)!=null?e:this.attachShadow(this.constructor.shadowRootOptions);return bt(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(s=>{var i;return(i=s.hostConnected)==null?void 0:i.call(s)})}enableUpdating(t){}disconnectedCallback(){var t;(t=this._$EO)==null||t.forEach(e=>{var s;return(s=e.hostDisconnected)==null?void 0:s.call(e)})}attributeChangedCallback(t,e,s){this._$AK(t,s)}_$EC(t,e){var n;let s=this.constructor.elementProperties.get(t),i=this.constructor._$Eu(t,s);if(i!==void 0&&s.reflect===!0){let r=(((n=s.converter)==null?void 0:n.toAttribute)!==void 0?s.converter:j).toAttribute(e,s.type);this._$Em=t,r==null?this.removeAttribute(i):this.setAttribute(i,r),this._$Em=null}}_$AK(t,e){var n;let s=this.constructor,i=s._$Eh.get(t);if(i!==void 0&&this._$Em!==i){let r=s.getPropertyOptions(i),a=typeof r.converter=="function"?{fromAttribute:r.converter}:((n=r.converter)==null?void 0:n.fromAttribute)!==void 0?r.converter:j;this._$Em=i,this[i]=a.fromAttribute(e,r.type),this._$Em=null}}requestUpdate(t,e,s){var i;if(t!==void 0){if(s!=null||(s=this.constructor.getPropertyOptions(t)),!((i=s.hasChanged)!=null?i:ot)(this[t],e))return;this.P(t,e,s)}this.isUpdatePending===!1&&(this._$ES=this._$ET())}P(t,e,s){var i;this._$AL.has(t)||this._$AL.set(t,e),s.reflect===!0&&this._$Em!==t&&((i=this._$Ej)!=null?i:this._$Ej=new Set).add(t)}async _$ET(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var s,i;if(!this.isUpdatePending)return;if(!this.hasUpdated){if((s=this.renderRoot)!=null||(this.renderRoot=this.createRenderRoot()),this._$Ep){for(let[r,a]of this._$Ep)this[r]=a;this._$Ep=void 0}let n=this.constructor.elementProperties;if(n.size>0)for(let[r,a]of n)a.wrapped!==!0||this._$AL.has(r)||this[r]===void 0||this.P(r,this[r],a)}let t=!1,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),(i=this._$EO)==null||i.forEach(n=>{var r;return(r=n.hostUpdate)==null?void 0:r.call(n)}),this.update(e)):this._$EU()}catch(n){throw t=!1,this._$EU(),n}t&&this._$AE(e)}willUpdate(t){}_$AE(t){var e;(e=this._$EO)==null||e.forEach(s=>{var i;return(i=s.hostUpdated)==null?void 0:i.call(s)}),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){}},Yt;E.elementStyles=[],E.shadowRootOptions={mode:"open"},E[G("elementProperties")]=new Map,E[G("finalized")]=new Map,Et==null||Et({ReactiveElement:E}),((Yt=C.reactiveElementVersions)!=null?Yt:C.reactiveElementVersions=[]).push("2.0.4");var We={attribute:!0,type:String,converter:j,reflect:!1,hasChanged:ot},Be=(o=We,t,e)=>{let{kind:s,metadata:i}=e,n=globalThis.litPropertyMetadata.get(i);if(n===void 0&&globalThis.litPropertyMetadata.set(i,n=new Map),n.set(e.name,o),s==="accessor"){let{name:r}=e;return{set(a){let c=t.get.call(this);t.set.call(this,a),this.requestUpdate(r,c,o)},init(a){return a!==void 0&&this.P(r,void 0,o),a}}}if(s==="setter"){let{name:r}=e;return function(a){let c=this[r];t.call(this,a),this.requestUpdate(r,c,o)}}throw Error("Unsupported decorator location: "+s)};function h(o){return(t,e)=>typeof e=="object"?Be(o,t,e):((s,i,n)=>{let r=i.hasOwnProperty(n);return i.constructor.createProperty(n,r?{...s,wrapped:!0}:s),r?Object.getOwnPropertyDescriptor(i,n):void 0})(o,t,e)}function M(o){return h({...o,state:!0,attribute:!1})}var Ye={PREFIX:"mdc",SEPARATOR:"-"},Ze={NAMESPACE:Ye},At=Ze;var Xe=o=>[At.NAMESPACE.PREFIX,o].join(At.NAMESPACE.SEPARATOR),y={constructTagName:Xe};var nt=y.constructTagName("themeprovider"),at={THEMECLASS:"mds-theme-stable-darkWebex",TYPOGRAPHYCLASS:"mds-typography"};var W=globalThis,ct=W.trustedTypes,Zt=ct?ct.createPolicy("lit-html",{createHTML:o=>o}):void 0,se="$lit$",T=`lit$${Math.random().toFixed(9).slice(2)}$`,ie="?"+T,Ke=`<${ie}>`,L=document,B=()=>L.createComment(""),Y=o=>o===null||typeof o!="object"&&typeof o!="function",Pt=Array.isArray,Je=o=>Pt(o)||typeof(o==null?void 0:o[Symbol.iterator])=="function",_t=`[
|
2
|
+
\f\r]`,V=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Xt=/-->/g,Kt=/>/g,U=RegExp(`>|${_t}(?:([^\\s"'>=/]+)(${_t}*=${_t}*(?:[^
|
3
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),Jt=/'/g,Qt=/"/g,oe=/^(?:script|style|textarea|title)$/i,Ut=o=>(t,...e)=>({_$litType$:o,strings:t,values:e}),g=Ut(1),Js=Ut(2),Qs=Ut(3),A=Symbol.for("lit-noChange"),u=Symbol.for("lit-nothing"),te=new WeakMap,R=L.createTreeWalker(L,129);function re(o,t){if(!Pt(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return Zt!==void 0?Zt.createHTML(t):t}var Qe=(o,t)=>{let e=o.length-1,s=[],i,n=t===2?"<svg>":t===3?"<math>":"",r=V;for(let a=0;a<e;a++){let c=o[a],m,d,p=-1,b=0;for(;b<c.length&&(r.lastIndex=b,d=r.exec(c),d!==null);)b=r.lastIndex,r===V?d[1]==="!--"?r=Xt:d[1]!==void 0?r=Kt:d[2]!==void 0?(oe.test(d[2])&&(i=RegExp("</"+d[2],"g")),r=U):d[3]!==void 0&&(r=U):r===U?d[0]===">"?(r=i!=null?i:V,p=-1):d[1]===void 0?p=-2:(p=r.lastIndex-d[2].length,m=d[1],r=d[3]===void 0?U:d[3]==='"'?Qt:Jt):r===Qt||r===Jt?r=U:r===Xt||r===Kt?r=V:(r=U,i=void 0);let S=r===U&&o[a+1].startsWith("/>")?" ":"";n+=r===V?c+Ke:p>=0?(s.push(m),c.slice(0,p)+se+c.slice(p)+T+S):c+T+(p===-2?a:S)}return[re(o,n+(o[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),s]},Z=class o{constructor({strings:t,_$litType$:e},s){let i;this.parts=[];let n=0,r=0,a=t.length-1,c=this.parts,[m,d]=Qe(t,e);if(this.el=o.createElement(m,s),R.currentNode=this.el.content,e===2||e===3){let p=this.el.content.firstChild;p.replaceWith(...p.childNodes)}for(;(i=R.nextNode())!==null&&c.length<a;){if(i.nodeType===1){if(i.hasAttributes())for(let p of i.getAttributeNames())if(p.endsWith(se)){let b=d[r++],S=i.getAttribute(p).split(T),tt=/([.?@])?(.*)/.exec(b);c.push({type:1,index:n,name:tt[2],strings:S,ctor:tt[1]==="."?Ct:tt[1]==="?"?Tt:tt[1]==="@"?Nt:z}),i.removeAttribute(p)}else p.startsWith(T)&&(c.push({type:6,index:n}),i.removeAttribute(p));if(oe.test(i.tagName)){let p=i.textContent.split(T),b=p.length-1;if(b>0){i.textContent=ct?ct.emptyScript:"";for(let S=0;S<b;S++)i.append(p[S],B()),R.nextNode(),c.push({type:2,index:++n});i.append(p[b],B())}}}else if(i.nodeType===8)if(i.data===ie)c.push({type:2,index:n});else{let p=-1;for(;(p=i.data.indexOf(T,p+1))!==-1;)c.push({type:7,index:n}),p+=T.length-1}n++}}static createElement(t,e){let s=L.createElement("template");return s.innerHTML=t,s}};function I(o,t,e=o,s){var r,a,c;if(t===A)return t;let i=s!==void 0?(r=e.o)==null?void 0:r[s]:e.l,n=Y(t)?void 0:t._$litDirective$;return(i==null?void 0:i.constructor)!==n&&((a=i==null?void 0:i._$AO)==null||a.call(i,!1),n===void 0?i=void 0:(i=new n(o),i._$AT(o,e,s)),s!==void 0?((c=e.o)!=null?c:e.o=[])[s]=i:e.l=i),i!==void 0&&(t=I(o,i._$AS(o,t.values),i,s)),t}var St=class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){var m;let{el:{content:e},parts:s}=this._$AD,i=((m=t==null?void 0:t.creationScope)!=null?m:L).importNode(e,!0);R.currentNode=i;let n=R.nextNode(),r=0,a=0,c=s[0];for(;c!==void 0;){if(r===c.index){let d;c.type===2?d=new X(n,n.nextSibling,this,t):c.type===1?d=new c.ctor(n,c.name,c.strings,this,t):c.type===6&&(d=new wt(n,this,t)),this._$AV.push(d),c=s[++a]}r!==(c==null?void 0:c.index)&&(n=R.nextNode(),r++)}return R.currentNode=L,i}p(t){let e=0;for(let s of this._$AV)s!==void 0&&(s.strings!==void 0?(s._$AI(t,s,e),e+=s.strings.length-2):s._$AI(t[e])),e++}},X=class o{get _$AU(){var t,e;return(e=(t=this._$AM)==null?void 0:t._$AU)!=null?e:this.v}constructor(t,e,s,i){var n;this.type=2,this._$AH=u,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=i,this.v=(n=i==null?void 0:i.isConnected)!=null?n:!0}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&(t==null?void 0:t.nodeType)===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=I(this,t,e),Y(t)?t===u||t==null||t===""?(this._$AH!==u&&this._$AR(),this._$AH=u):t!==this._$AH&&t!==A&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Je(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!==u&&Y(this._$AH)?this._$AA.nextSibling.data=t:this.T(L.createTextNode(t)),this._$AH=t}$(t){var n;let{values:e,_$litType$:s}=t,i=typeof s=="number"?this._$AC(t):(s.el===void 0&&(s.el=Z.createElement(re(s.h,s.h[0]),this.options)),s);if(((n=this._$AH)==null?void 0:n._$AD)===i)this._$AH.p(e);else{let r=new St(i,this),a=r.u(this.options);r.p(e),this.T(a),this._$AH=r}}_$AC(t){let e=te.get(t.strings);return e===void 0&&te.set(t.strings,e=new Z(t)),e}k(t){Pt(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,s,i=0;for(let n of t)i===e.length?e.push(s=new o(this.O(B()),this.O(B()),this,this.options)):s=e[i],s._$AI(n),i++;i<e.length&&(this._$AR(s&&s._$AB.nextSibling,i),e.length=i)}_$AR(t=this._$AA.nextSibling,e){var s;for((s=this._$AP)==null?void 0:s.call(this,!1,!0,e);t&&t!==this._$AB;){let i=t.nextSibling;t.remove(),t=i}}setConnected(t){var e;this._$AM===void 0&&(this.v=t,(e=this._$AP)==null||e.call(this,t))}},z=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,s,i,n){this.type=1,this._$AH=u,this._$AN=void 0,this.element=t,this.name=e,this._$AM=i,this.options=n,s.length>2||s[0]!==""||s[1]!==""?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=u}_$AI(t,e=this,s,i){let n=this.strings,r=!1;if(n===void 0)t=I(this,t,e,0),r=!Y(t)||t!==this._$AH&&t!==A,r&&(this._$AH=t);else{let a=t,c,m;for(t=n[0],c=0;c<n.length-1;c++)m=I(this,a[s+c],e,c),m===A&&(m=this._$AH[c]),r||(r=!Y(m)||m!==this._$AH[c]),m===u?t=u:t!==u&&(t+=(m!=null?m:"")+n[c+1]),this._$AH[c]=m}r&&!i&&this.j(t)}j(t){t===u?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t!=null?t:"")}},Ct=class extends z{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===u?void 0:t}},Tt=class extends z{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==u)}},Nt=class extends z{constructor(t,e,s,i,n){super(t,e,s,i,n),this.type=5}_$AI(t,e=this){var r;if((t=(r=I(this,t,e,0))!=null?r:u)===A)return;let s=this._$AH,i=t===u&&s!==u||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,n=t!==u&&(s===u||i);i&&this.element.removeEventListener(this.name,this,s),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,s;typeof this._$AH=="function"?this._$AH.call((s=(e=this.options)==null?void 0:e.host)!=null?s:this.element,t):this._$AH.handleEvent(t)}},wt=class{constructor(t,e,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){I(this,t)}};var $t=W.litHtmlPolyfillSupport,ee;$t==null||$t(Z,X),((ee=W.litHtmlVersions)!=null?ee:W.litHtmlVersions=[]).push("3.2.0");var ne=(o,t,e)=>{var n,r;let s=(n=e==null?void 0:e.renderBefore)!=null?n:t,i=s._$litPart$;if(i===void 0){let a=(r=e==null?void 0:e.renderBefore)!=null?r:null;s._$litPart$=i=new X(t.insertBefore(B(),a),a,void 0,e!=null?e:{})}return i._$AI(o),i};var N=class extends E{constructor(){super(...arguments),this.renderOptions={host:this},this.o=void 0}createRenderRoot(){var e,s;let t=super.createRenderRoot();return(s=(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=ne(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 A}},ae;N._$litElement$=!0,N.finalized=!0,(ae=globalThis.litElementHydrateSupport)==null||ae.call(globalThis,{LitElement:N});var Rt=globalThis.litElementPolyfillSupport;Rt==null||Rt({LitElement:N});var ce;((ce=globalThis.litElementVersions)!=null?ce:globalThis.litElementVersions=[]).push("4.1.0");var Lt=class extends N{static register(t){customElements.get(t)||customElements.define(t,this)}},le=Lt;var x=le;var w=class extends Event{constructor(t,e,s){super("context-request",{bubbles:!0,composed:!0}),this.context=t,this.callback=e,this.subscribe=s!=null?s:!1}};var H=class{constructor(t,e,s,i){var n;if(this.subscribe=!1,this.provided=!1,this.value=void 0,this.t=(r,a)=>{this.unsubscribe&&(this.unsubscribe!==a&&(this.provided=!1,this.unsubscribe()),this.subscribe||this.unsubscribe()),this.value=r,this.host.requestUpdate(),this.provided&&!this.subscribe||(this.provided=!0,this.callback&&this.callback(r,a)),this.unsubscribe=a},this.host=t,e.context!==void 0){let r=e;this.context=r.context,this.callback=r.callback,this.subscribe=(n=r.subscribe)!=null?n:!1}else this.context=e,this.callback=s,this.subscribe=i!=null?i:!1;this.host.addController(this)}hostConnected(){this.dispatchRequest()}hostDisconnected(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=void 0)}dispatchRequest(){this.host.dispatchEvent(new w(this.context,this.t,this.subscribe))}};var lt=class{get value(){return this.o}set value(t){this.setValue(t)}setValue(t,e=!1){let s=e||!Object.is(t,this.o);this.o=t,s&&this.updateObservers()}constructor(t){this.subscriptions=new Map,this.updateObservers=()=>{for(let[e,{disposer:s}]of this.subscriptions)e(this.o,s)},t!==void 0&&(this.value=t)}addCallback(t,e,s){if(!s)return void t(this.value);this.subscriptions.has(t)||this.subscriptions.set(t,{disposer:()=>{this.subscriptions.delete(t)},consumerHost:e});let{disposer:i}=this.subscriptions.get(t);t(this.value,i)}clearCallbacks(){this.subscriptions.clear()}};var Ot=class extends Event{constructor(t){super("context-provider",{bubbles:!0,composed:!0}),this.context=t}},k=class extends lt{constructor(t,e,s){var i,n;super(e.context!==void 0?e.initialValue:s),this.onContextRequest=r=>{let a=r.composedPath()[0];r.context===this.context&&a!==this.host&&(r.stopPropagation(),this.addCallback(r.callback,a,r.subscribe))},this.onProviderRequest=r=>{let a=r.composedPath()[0];if(r.context!==this.context||a===this.host)return;let c=new Set;for(let[m,{consumerHost:d}]of this.subscriptions)c.has(m)||(c.add(m),d.dispatchEvent(new w(this.context,m,!0)));r.stopPropagation()},this.host=t,e.context!==void 0?this.context=e.context:this.context=e,this.attachListeners(),(n=(i=this.host).addController)==null||n.call(i,this)}attachListeners(){this.host.addEventListener("context-request",this.onContextRequest),this.host.addEventListener("context-provider",this.onProviderRequest)}hostConnected(){this.host.dispatchEvent(new Ot(this.context))}};var ts=f`
|
4
4
|
:host {
|
5
|
-
|
6
|
-
display: block;
|
7
|
-
height: 100%;
|
8
|
-
margin: 0;
|
9
|
-
padding: 0;
|
10
|
-
width: 100%;
|
5
|
+
display: contents;
|
11
6
|
}
|
12
|
-
`,pe=ts;var ht=class extends
|
7
|
+
`,pe=ts;var ht=class extends x{constructor({context:t,initialValue:e}){super(),this.context=new k(this,{context:t,initialValue:e})}render(){return this.updateContext(),g`<slot></slot>`}};ht.styles=[pe];var de=ht;var D=de;var pt=class{constructor(t){this.themeclass=t}};pt.context=nt;var dt=pt;var es=f`
|
13
8
|
:host {
|
14
9
|
--mdc-themeprovider-font-family: var(--mds-font-family-primary);
|
15
10
|
--mdc-themeprovider-color-default: var(--mds-color-theme-text-primary-normal);
|
@@ -17,7 +12,7 @@
|
|
17
12
|
font-family: var(--mdc-themeprovider-font-family);
|
18
13
|
color: var(--mdc-themeprovider-color-default);
|
19
14
|
}
|
20
|
-
`,me=es;var
|
15
|
+
`,me=es;var F=class extends D{constructor(){super({context:dt.context,initialValue:new dt(at.THEMECLASS)});this.themeclass=at.THEMECLASS;this.classList.add(at.TYPOGRAPHYCLASS)}static get Context(){return dt.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(" "))}};F.styles=[...D.styles,me],l([M()],F.prototype,"currentThemeClass",2),l([h({type:String})],F.prototype,"themeclass",2);var Mt=F;Mt.register(nt);var ss=Mt;var mt=f`
|
21
16
|
:host {
|
22
17
|
align-items: center;
|
23
18
|
display: flex;
|
@@ -26,12 +21,15 @@
|
|
26
21
|
width: fit-content;
|
27
22
|
}
|
28
23
|
`;var is=[mt,f`
|
24
|
+
:host {
|
25
|
+
--mdc-icon-fill-color: currentColor;
|
26
|
+
}
|
29
27
|
svg {
|
30
28
|
height: 100%;
|
31
29
|
width: 100%;
|
32
|
-
fill:
|
30
|
+
fill: var(--mdc-icon-fill-color);
|
33
31
|
}
|
34
|
-
`],ue=is;var
|
32
|
+
`],ue=is;var os=o=>{let{host:t,context:e,subscribe:s}=o;return new H(t,{context:e,subscribe:s!=null?s:!0})},rs={consume:os},fe=rs;var ut=y.constructTagName("iconprovider"),ge=["svg"],ye=["em","rem","px"],_={FILE_EXTENSION:"svg",LENGTH_UNIT:"em",LENGTH_UNIT_SIZE:{px:16,em:1,rem:1}};var ft=class{};ft.context=ut;var gt=ft;var O=class extends D{constructor(){super({context:gt.context,initialValue:new gt});this.fileExtension=_.FILE_EXTENSION;this.lengthUnit=_.LENGTH_UNIT;this.size=_.LENGTH_UNIT_SIZE[_.LENGTH_UNIT]}static get Context(){return gt.context}updateValuesInContext(){this.fileExtension&&ge.includes(this.fileExtension)?this.context.value.fileExtension=this.fileExtension:(this.fileExtension=_.FILE_EXTENSION,this.context.value.fileExtension=_.FILE_EXTENSION),this.context.value.url=this.url,this.context.value.size=this.size,this.lengthUnit&&ye.includes(this.lengthUnit)?this.context.value.lengthUnit=this.lengthUnit:(this.lengthUnit=_.LENGTH_UNIT,this.context.value.lengthUnit=_.LENGTH_UNIT)}updateContext(){(this.context.value.fileExtension!==this.fileExtension||this.context.value.url!==this.url||this.context.value.lengthUnit!==this.lengthUnit||this.context.value.size!==this.size)&&(this.updateValuesInContext(),this.context.updateObservers())}};l([h({type:String})],O.prototype,"url",2),l([h({type:String,attribute:"file-extension",reflect:!0})],O.prototype,"fileExtension",2),l([h({type:String,attribute:"length-unit",reflect:!0})],O.prototype,"lengthUnit",2),l([h({type:Number,reflect:!0})],O.prototype,"size",2);var K=O;var xe=async(o,t,e)=>{let s=await fetch(`${o}/${t}.${e}`);if(!s.ok)throw new Error("There was a problem while fetching the icon!");let i=await s.text();return new DOMParser().parseFromString(i,"text/html").body.children[0]};var ve=y.constructTagName("icon"),It={NAME:void 0,SIZE:1};var v=class extends x{constructor(){super(...arguments);this.name=It.NAME;this.ariaLabel=null;this.iconProviderContext=fe.consume({host:this,context:K.Context})}async getIconData(){if(this.iconProviderContext.value){let{fileExtension:e,url:s}=this.iconProviderContext.value;if(s&&e&&this.name){let i=await xe(s,this.name,e);this.iconData=i,this.setRoleOnIcon(),this.setAriaLabelOnIcon(),this.setAriaHiddenOnIcon()}}}updateSize(){var e;if(this.computedIconSize&&(this.lengthUnit||this.lengthUnitFromContext)){let s=`${this.computedIconSize}${(e=this.lengthUnit)!=null?e:this.lengthUnitFromContext}`;this.style.width=s,this.style.height=s}}setRoleOnIcon(){this.role=this.ariaLabel?"img":null}setAriaHiddenOnIcon(){var e;(e=this.iconData)==null||e.setAttribute("aria-hidden","true")}setAriaLabelOnIcon(){var e,s;this.ariaLabel?(e=this.iconData)==null||e.setAttribute("aria-label",this.ariaLabel):(s=this.iconData)==null||s.removeAttribute("aria-label")}get computedIconSize(){var e,s;return(s=(e=this.size)!=null?e:this.sizeFromContext)!=null?s:It.SIZE}updated(e){var s,i,n,r;super.updated(e),e.has("name")&&this.getIconData().catch(a=>{console.error(a)}),e.has("ariaLabel")&&(this.setRoleOnIcon(),this.setAriaLabelOnIcon()),(e.has("size")||e.has("lengthUnit"))&&this.updateSize(),this.lengthUnitFromContext!==((s=this.iconProviderContext.value)==null?void 0:s.lengthUnit)&&(this.lengthUnitFromContext=(i=this.iconProviderContext.value)==null?void 0:i.lengthUnit,this.updateSize()),this.sizeFromContext!==((n=this.iconProviderContext.value)==null?void 0:n.size)&&(this.sizeFromContext=(r=this.iconProviderContext.value)==null?void 0:r.size,this.updateSize())}render(){return g` ${this.iconData} `}};v.styles=ue,l([M()],v.prototype,"iconData",2),l([M()],v.prototype,"lengthUnitFromContext",2),l([M()],v.prototype,"sizeFromContext",2),l([h({type:String,reflect:!0})],v.prototype,"name",2),l([h({type:Number})],v.prototype,"size",2),l([h({type:String,attribute:"length-unit"})],v.prototype,"lengthUnit",2),l([h({type:String,attribute:"aria-label"})],v.prototype,"ariaLabel",2);var zt=v;zt.register(ve);var ns=zt;K.register(ut);var as=K;var J=o=>o!=null?o:u;var cs=f`
|
35
33
|
:host {
|
36
34
|
display: flex;
|
37
35
|
justify-content: center;
|
@@ -46,12 +44,12 @@
|
|
46
44
|
width: inherit;
|
47
45
|
object-fit: cover;
|
48
46
|
}
|
49
|
-
`,be=
|
47
|
+
`,be=cs;var Ee=y.constructTagName("avatar"),Ae="rem",Ht={TYPE:"photo",SIZE:1.5};var P=class extends x{constructor(){super(...arguments);this.type=Ht.TYPE;this.size=Ht.SIZE}updateSize(){if(this.size){let e=`${this.size}${Ae}`;this.style.width=e,this.style.height=e}}updated(e){super.updated(e),e.has("size")&&this.updateSize()}photoTemplate(){return g`
|
50
48
|
<img
|
51
49
|
src="${J(this.src)}"
|
52
50
|
alt="${J(this.alt)}"
|
53
51
|
/>
|
54
|
-
`}render(){let e;return this.type==="photo"?e=this.photoTemplate():e=g``,g`${e}`}};P.styles=be,
|
52
|
+
`}render(){let e;return this.type==="photo"?e=this.photoTemplate():e=g``,g`${e}`}};P.styles=be,l([h({type:String,reflect:!0})],P.prototype,"type",2),l([h({type:String})],P.prototype,"alt",2),l([h({type:String})],P.prototype,"src",2),l([h({type:Number})],P.prototype,"size",2);var kt=P;kt.register(Ee);var ls=kt;var _e={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},$e=o=>(...t)=>({_$litDirective$:o,values:t}),yt=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,s){this.t=t,this._$AM=e,this.i=s}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};var Se="important",hs=" !"+Se,Ce=$e(class extends yt{constructor(o){var t;if(super(o),o.type!==_e.ATTRIBUTE||o.name!=="style"||((t=o.strings)==null?void 0:t.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(o){return Object.keys(o).reduce((t,e)=>{let s=o[e];return s==null?t:t+`${e=e.includes("-")?e:e.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${s};`},"")}update(o,[t]){let{style:e}=o.element;if(this.ft===void 0)return this.ft=new Set(Object.keys(t)),this.render(t);for(let s of this.ft)t[s]==null&&(this.ft.delete(s),s.includes("-")?e.removeProperty(s):e[s]=null);for(let s in t){let i=t[s];if(i!=null){this.ft.add(s);let n=typeof i=="string"&&i.endsWith(hs);s.includes("-")||n?e.setProperty(s,n?i.slice(0,-11):i,n?Se:""):e[s]=i}}return A}});var Te=y.constructTagName("badge"),Ne="warning-badge-filled",xt={TYPE:"regular",SIZE:1,LENGTH_UNIT:"rem"};var ps=[mt,f`
|
55
53
|
:host {
|
56
54
|
--mdc-badge-icon-background-color: var(--mds-color-theme-background-accent-normal);
|
57
55
|
--mdc-badge-icon-color: var(--mds-color-theme-common-text-primary-normal);
|
@@ -70,9 +68,9 @@
|
|
70
68
|
height: 80%;
|
71
69
|
width: 80%;
|
72
70
|
}
|
73
|
-
`],we=ps;var $=class extends
|
71
|
+
`],we=ps;var $=class extends x{constructor(){super(...arguments);this.type=xt.TYPE;this.size=xt.SIZE;this.lengthUnit=xt.LENGTH_UNIT}updateSize(){}updated(e){super.updated(e),(e.has("size")||e.has("lengthUnit"))&&this.updateSize()}iconTemplate(){return g`<div class="mdc-badge-icon-container">
|
74
72
|
<mdc-icon name=${J(this.iconName)} size="100" length-unit="%"></mdc-icon>
|
75
|
-
</div>`}textTemplate(){return g`${this.text}`}warningTemplate(){return g` <mdc-icon name="${Ne}" class="mdc-badge-warning"></mdc-icon> `}render(){let e,s=`${this.size}${this.lengthUnit}`,i={width:s,height:s};switch(this.type){case"regular":e=g``;break;case"icon":e=this.iconTemplate();break;case"text":e=this.textTemplate(),i={height:i.height};break;case"warning":e=this.warningTemplate();break;default:e=g``;break}return g`<div class="mdc-badge-container" style=${Ce(i)}>${e}</div>`}};$.styles=we,
|
73
|
+
</div>`}textTemplate(){return g`${this.text}`}warningTemplate(){return g` <mdc-icon name="${Ne}" class="mdc-badge-warning"></mdc-icon> `}render(){let e,s=`${this.size}${this.lengthUnit}`,i={width:s,height:s};switch(this.type){case"regular":e=g``;break;case"icon":e=this.iconTemplate();break;case"text":e=this.textTemplate(),i={height:i.height};break;case"warning":e=this.warningTemplate();break;default:e=g``;break}return g`<div class="mdc-badge-container" style=${Ce(i)}>${e}</div>`}};$.styles=we,l([h({type:String,reflect:!0})],$.prototype,"type",2),l([h({type:Number})],$.prototype,"size",2),l([h({type:String,attribute:"length-unit"})],$.prototype,"lengthUnit",2),l([h({type:String,attribute:"icon-name"})],$.prototype,"iconName",2),l([h({type:String})],$.prototype,"text",2);var Dt=$;Dt.register(Te);var ds=Dt;var Pe=f`
|
76
74
|
:host([type="heading-1"]) {
|
77
75
|
font-size: 7.5rem;
|
78
76
|
font-style: normal;
|
@@ -173,7 +171,7 @@
|
|
173
171
|
display: block;
|
174
172
|
font-family: var(--mdc-text-font-family);
|
175
173
|
}
|
176
|
-
`,Pe],Ue=ms;var Re=
|
174
|
+
`,Pe],Ue=ms;var Re=o=>{let t=o.split("-");return{firstPart:t[0],secondPart:t[1]}},Le=o=>{let{firstPart:t,secondPart:e}=Re(o);return t==="heading"&&+e>0&&+e<7},Oe=o=>o?Le(o)?"heading":"paragraph":null,Me=o=>{if(o&&Le(o)){let{secondPart:t}=Re(o);return t}return null};var Q=class extends x{handleTypeChanged(){this.role=Oe(this.type),this.ariaLevel=Me(this.type)}updated(t){super.updated(t),t.has("type")&&this.handleTypeChanged()}render(){return g`<slot></slot>`}};Q.styles=Ue,l([h({attribute:"type",reflect:!0,type:String})],Q.prototype,"type",2);var Ft=Q;var Ie=y.constructTagName("text");Ft.register(Ie);var us=Ft;})();
|
177
175
|
/*! Bundled license information:
|
178
176
|
|
179
177
|
@lit/reactive-element/decorators/custom-element.js:
|