diff --git a/polr-ytube-media-card.js b/polr-ytube-media-card.js
index 1490bdc..51e77b8 100644
--- a/polr-ytube-media-card.js
+++ b/polr-ytube-media-card.js
@@ -1,441 +1,180 @@
-/******************************************************************************
-Copyright (c) Microsoft Corporation.
-
-Permission to use, copy, modify, and/or distribute this software for any
-purpose with or without fee is hereby granted.
-
-THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
-REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
-AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
-INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
-LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
-OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-PERFORMANCE OF THIS SOFTWARE.
-***************************************************************************** */
-/* global Reflect, Promise */
-
-var extendStatics = function(d, b) {
- extendStatics = Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
- return extendStatics(d, b);
-};
-
-function __extends(d, b) {
- if (typeof b !== "function" && b !== null)
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
- extendStatics(d, b);
- function __() { this.constructor = d; }
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
-}
-
-var __assign = function() {
- __assign = Object.assign || function __assign(t) {
- for (var s, i = 1, n = arguments.length; i < n; i++) {
- s = arguments[i];
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
- }
- return t;
- };
- return __assign.apply(this, arguments);
-};
-
-function __decorate(decorators, target, key, desc) {
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
- return c > 3 && r && Object.defineProperty(target, key, r), r;
-}
-
-function __values(o) {
- var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
- if (m) return m.call(o);
- if (o && typeof o.length === "number") return {
- next: function () {
- if (o && i >= o.length) o = void 0;
- return { value: o && o[i++], done: !o };
- }
- };
- throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
-}
-
-function __read(o, n) {
- var m = typeof Symbol === "function" && o[Symbol.iterator];
- if (!m) return o;
- var i = m.call(o), r, ar = [], e;
- try {
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
- }
- catch (error) { e = { error: error }; }
- finally {
- try {
- if (r && !r.done && (m = i["return"])) m.call(i);
- }
- finally { if (e) throw e.error; }
- }
- return ar;
-}
-
+var t=function(e,i){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i])},t(e,i)};function e(e,i){if("function"!=typeof i&&null!==i)throw new TypeError("Class extends value "+String(i)+" is not a constructor or null");function n(){this.constructor=e}t(e,i),e.prototype=null===i?Object.create(i):(n.prototype=i.prototype,new n)}var i=function(){return i=Object.assign||function(t){for(var e,i=1,n=arguments.length;i=0;o--)(r=t[o])&&(l=(a<3?r(l):a>3?r(e,i,l):r(e,i))||l);return a>3&&l&&Object.defineProperty(e,i,l),l}function r(t){var e="function"==typeof Symbol&&Symbol.iterator,i=e&&t[e],n=0;if(i)return i.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}
/**
* @license
* Copyright 2019 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
*/
-const t$3=window,e$8=t$3.ShadowRoot&&(void 0===t$3.ShadyCSS||t$3.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,s$4=Symbol(),n$7=new WeakMap;let o$8 = class o{constructor(t,e,n){if(this._$cssResult$=!0,n!==s$4)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e;}get styleSheet(){let t=this.o;const s=this.t;if(e$8&&void 0===t){const e=void 0!==s&&1===s.length;e&&(t=n$7.get(s)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&n$7.set(s,t));}return t}toString(){return this.cssText}};const r$2=t=>new o$8("string"==typeof t?t:t+"",void 0,s$4),i$5=(t,...e)=>{const n=1===t.length?t[0]:e.reduce(((e,s,n)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(s)+t[n+1]),t[0]);return new o$8(n,t,s$4)},S$1=(s,n)=>{e$8?s.adoptedStyleSheets=n.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet)):n.forEach((e=>{const n=document.createElement("style"),o=t$3.litNonce;void 0!==o&&n.setAttribute("nonce",o),n.textContent=e.cssText,s.appendChild(n);}));},c$1=e$8?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const s of t.cssRules)e+=s.cssText;return r$2(e)})(t):t;
-
+const a=window,l=a.ShadowRoot&&(void 0===a.ShadyCSS||a.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,o=Symbol(),d=new WeakMap;let c=class{constructor(t,e,i){if(this._$cssResult$=!0,i!==o)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const e=this.t;if(l&&void 0===t){const i=void 0!==e&&1===e.length;i&&(t=d.get(e)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),i&&d.set(e,t))}return t}toString(){return this.cssText}};const s=(t,...e)=>{const i=1===t.length?t[0]:e.reduce(((e,i,n)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+t[n+1]),t[0]);return new c(i,t,o)},m=l?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return(t=>new c("string"==typeof t?t:t+"",void 0,o))(e)})(t):t
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */var s$3;const e$7=window,r$1=e$7.trustedTypes,h$1=r$1?r$1.emptyScript:"",o$7=e$7.reactiveElementPolyfillSupport,n$6={toAttribute(t,i){switch(i){case Boolean:t=t?h$1:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t);}return t},fromAttribute(t,i){let s=t;switch(i){case Boolean:s=null!==t;break;case Number:s=null===t?null:Number(t);break;case Object:case Array:try{s=JSON.parse(t);}catch(t){s=null;}}return s}},a$1=(t,i)=>i!==t&&(i==i||t==t),l$4={attribute:!0,type:String,converter:n$6,reflect:!1,hasChanged:a$1},d$1="finalized";let u$1 = class u extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this.u();}static addInitializer(t){var i;this.finalize(),(null!==(i=this.h)&&void 0!==i?i:this.h=[]).push(t);}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((i,s)=>{const e=this._$Ep(s,i);void 0!==e&&(this._$Ev.set(e,s),t.push(e));})),t}static createProperty(t,i=l$4){if(i.state&&(i.attribute=!1),this.finalize(),this.elementProperties.set(t,i),!i.noAccessor&&!this.prototype.hasOwnProperty(t)){const s="symbol"==typeof t?Symbol():"__"+t,e=this.getPropertyDescriptor(t,s,i);void 0!==e&&Object.defineProperty(this.prototype,t,e);}}static getPropertyDescriptor(t,i,s){return {get(){return this[i]},set(e){const r=this[t];this[i]=e,this.requestUpdate(t,r,s);},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||l$4}static finalize(){if(this.hasOwnProperty(d$1))return !1;this[d$1]=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),void 0!==t.h&&(this.h=[...t.h]),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,i=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const s of i)this.createProperty(s,t[s]);}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(i){const s=[];if(Array.isArray(i)){const e=new Set(i.flat(1/0).reverse());for(const i of e)s.unshift(c$1(i));}else void 0!==i&&s.push(c$1(i));return s}static _$Ep(t,i){const s=i.attribute;return !1===s?void 0:"string"==typeof s?s:"string"==typeof t?t.toLowerCase():void 0}u(){var t;this._$E_=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(t=this.constructor.h)||void 0===t||t.forEach((t=>t(this)));}addController(t){var i,s;(null!==(i=this._$ES)&&void 0!==i?i:this._$ES=[]).push(t),void 0!==this.renderRoot&&this.isConnected&&(null===(s=t.hostConnected)||void 0===s||s.call(t));}removeController(t){var i;null===(i=this._$ES)||void 0===i||i.splice(this._$ES.indexOf(t)>>>0,1);}_$Eg(){this.constructor.elementProperties.forEach(((t,i)=>{this.hasOwnProperty(i)&&(this._$Ei.set(i,this[i]),delete this[i]);}));}createRenderRoot(){var t;const s=null!==(t=this.shadowRoot)&&void 0!==t?t:this.attachShadow(this.constructor.shadowRootOptions);return S$1(s,this.constructor.elementStyles),s}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var i;return null===(i=t.hostConnected)||void 0===i?void 0:i.call(t)}));}enableUpdating(t){}disconnectedCallback(){var t;null===(t=this._$ES)||void 0===t||t.forEach((t=>{var i;return null===(i=t.hostDisconnected)||void 0===i?void 0:i.call(t)}));}attributeChangedCallback(t,i,s){this._$AK(t,s);}_$EO(t,i,s=l$4){var e;const r=this.constructor._$Ep(t,s);if(void 0!==r&&!0===s.reflect){const h=(void 0!==(null===(e=s.converter)||void 0===e?void 0:e.toAttribute)?s.converter:n$6).toAttribute(i,s.type);this._$El=t,null==h?this.removeAttribute(r):this.setAttribute(r,h),this._$El=null;}}_$AK(t,i){var s;const e=this.constructor,r=e._$Ev.get(t);if(void 0!==r&&this._$El!==r){const t=e.getPropertyOptions(r),h="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==(null===(s=t.converter)||void 0===s?void 0:s.fromAttribute)?t.converter:n$6;this._$El=r,this[r]=h.fromAttribute(i,t.type),this._$El=null;}}requestUpdate(t,i,s){let e=!0;void 0!==t&&(((s=s||this.constructor.getPropertyOptions(t)).hasChanged||a$1)(this[t],i)?(this._$AL.has(t)||this._$AL.set(t,i),!0===s.reflect&&this._$El!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,s))):e=!1),!this.isUpdatePending&&e&&(this._$E_=this._$Ej());}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_;}catch(t){Promise.reject(t);}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((t,i)=>this[i]=t)),this._$Ei=void 0);let i=!1;const s=this._$AL;try{i=this.shouldUpdate(s),i?(this.willUpdate(s),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var i;return null===(i=t.hostUpdate)||void 0===i?void 0:i.call(t)})),this.update(s)):this._$Ek();}catch(t){throw i=!1,this._$Ek(),t}i&&this._$AE(s);}willUpdate(t){}_$AE(t){var i;null===(i=this._$ES)||void 0===i||i.forEach((t=>{var i;return null===(i=t.hostUpdated)||void 0===i?void 0:i.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t);}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1;}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return !0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,i)=>this._$EO(i,this[i],t))),this._$EC=void 0),this._$Ek();}updated(t){}firstUpdated(t){}};u$1[d$1]=!0,u$1.elementProperties=new Map,u$1.elementStyles=[],u$1.shadowRootOptions={mode:"open"},null==o$7||o$7({ReactiveElement:u$1}),(null!==(s$3=e$7.reactiveElementVersions)&&void 0!==s$3?s$3:e$7.reactiveElementVersions=[]).push("1.6.2");
-
+ */;var h;const p=window,u=p.trustedTypes,f=u?u.emptyScript:"",g=p.reactiveElementPolyfillSupport,b={toAttribute(t,e){switch(e){case Boolean:t=t?f:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},v=(t,e)=>e!==t&&(e==e||t==t),_={attribute:!0,type:String,converter:b,reflect:!1,hasChanged:v},x="finalized";let y=class extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this.u()}static addInitializer(t){var e;this.finalize(),(null!==(e=this.h)&&void 0!==e?e:this.h=[]).push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((e,i)=>{const n=this._$Ep(i,e);void 0!==n&&(this._$Ev.set(n,i),t.push(n))})),t}static createProperty(t,e=_){if(e.state&&(e.attribute=!1),this.finalize(),this.elementProperties.set(t,e),!e.noAccessor&&!this.prototype.hasOwnProperty(t)){const i="symbol"==typeof t?Symbol():"__"+t,n=this.getPropertyDescriptor(t,i,e);void 0!==n&&Object.defineProperty(this.prototype,t,n)}}static getPropertyDescriptor(t,e,i){return{get(){return this[e]},set(n){const r=this[t];this[e]=n,this.requestUpdate(t,r,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||_}static finalize(){if(this.hasOwnProperty(x))return!1;this[x]=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),void 0!==t.h&&(this.h=[...t.h]),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,e=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const i of e)this.createProperty(i,t[i])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(m(t))}else void 0!==t&&e.push(m(t));return e}static _$Ep(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}u(){var t;this._$E_=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(t=this.constructor.h)||void 0===t||t.forEach((t=>t(this)))}addController(t){var e,i;(null!==(e=this._$ES)&&void 0!==e?e:this._$ES=[]).push(t),void 0!==this.renderRoot&&this.isConnected&&(null===(i=t.hostConnected)||void 0===i||i.call(t))}removeController(t){var e;null===(e=this._$ES)||void 0===e||e.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach(((t,e)=>{this.hasOwnProperty(e)&&(this._$Ei.set(e,this[e]),delete this[e])}))}createRenderRoot(){var t;const e=null!==(t=this.shadowRoot)&&void 0!==t?t:this.attachShadow(this.constructor.shadowRootOptions);return((t,e)=>{l?t.adoptedStyleSheets=e.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet)):e.forEach((e=>{const i=document.createElement("style"),n=a.litNonce;void 0!==n&&i.setAttribute("nonce",n),i.textContent=e.cssText,t.appendChild(i)}))})(e,this.constructor.elementStyles),e}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostConnected)||void 0===e?void 0:e.call(t)}))}enableUpdating(t){}disconnectedCallback(){var t;null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostDisconnected)||void 0===e?void 0:e.call(t)}))}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$EO(t,e,i=_){var n;const r=this.constructor._$Ep(t,i);if(void 0!==r&&!0===i.reflect){const a=(void 0!==(null===(n=i.converter)||void 0===n?void 0:n.toAttribute)?i.converter:b).toAttribute(e,i.type);this._$El=t,null==a?this.removeAttribute(r):this.setAttribute(r,a),this._$El=null}}_$AK(t,e){var i;const n=this.constructor,r=n._$Ev.get(t);if(void 0!==r&&this._$El!==r){const t=n.getPropertyOptions(r),a="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==(null===(i=t.converter)||void 0===i?void 0:i.fromAttribute)?t.converter:b;this._$El=r,this[r]=a.fromAttribute(e,t.type),this._$El=null}}requestUpdate(t,e,i){let n=!0;void 0!==t&&(((i=i||this.constructor.getPropertyOptions(t)).hasChanged||v)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),!0===i.reflect&&this._$El!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,i))):n=!1),!this.isUpdatePending&&n&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((t,e)=>this[e]=t)),this._$Ei=void 0);let e=!1;const i=this._$AL;try{e=this.shouldUpdate(i),e?(this.willUpdate(i),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostUpdate)||void 0===e?void 0:e.call(t)})),this.update(i)):this._$Ek()}catch(t){throw e=!1,this._$Ek(),t}e&&this._$AE(i)}willUpdate(t){}_$AE(t){var e;null===(e=this._$ES)||void 0===e||e.forEach((t=>{var e;return null===(e=t.hostUpdated)||void 0===e?void 0:e.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,e)=>this._$EO(e,this[e],t))),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}};
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
*/
-var t$2;const i$4=window,s$2=i$4.trustedTypes,e$6=s$2?s$2.createPolicy("lit-html",{createHTML:t=>t}):void 0,o$6="$lit$",n$5=`lit$${(Math.random()+"").slice(9)}$`,l$3="?"+n$5,h=`<${l$3}>`,r=document,d=()=>r.createComment(""),u=t=>null===t||"object"!=typeof t&&"function"!=typeof t,c=Array.isArray,v=t=>c(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]),a="[ \t\n\f\r]",f$1=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,_=/-->/g,m=/>/g,p=RegExp(`>|${a}(?:([^\\s"'>=/]+)(${a}*=${a}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),g=/'/g,$=/"/g,y=/^(?:script|style|textarea|title)$/i,w=t=>(i,...s)=>({_$litType$:t,strings:i,values:s}),x=w(1),T=Symbol.for("lit-noChange"),A=Symbol.for("lit-nothing"),E=new WeakMap,C=r.createTreeWalker(r,129,null,!1),P=(t,i)=>{const s=t.length-1,l=[];let r,d=2===i?"":"",u=f$1;for(let i=0;i"===c[0]?(u=null!=r?r:f$1,v=-1):void 0===c[1]?v=-2:(v=u.lastIndex-c[2].length,e=c[1],u=void 0===c[3]?p:'"'===c[3]?$:g):u===$||u===g?u=p:u===_||u===m?u=f$1:(u=p,r=void 0);const w=u===p&&t[i+1].startsWith("/>")?" ":"";d+=u===f$1?s+h:v>=0?(l.push(e),s.slice(0,v)+o$6+s.slice(v)+n$5+w):s+n$5+(-2===v?(l.push(void 0),i):w);}const c=d+(t[s]||">")+(2===i?" ":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return [void 0!==e$6?e$6.createHTML(c):c,l]};class V{constructor({strings:t,_$litType$:i},e){let h;this.parts=[];let r=0,u=0;const c=t.length-1,v=this.parts,[a,f]=P(t,i);if(this.el=V.createElement(a,e),C.currentNode=this.el.content,2===i){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes);}for(;null!==(h=C.nextNode())&&v.length0){h.textContent=s$2?s$2.emptyScript:"";for(let s=0;s2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=A;}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,s,e){const o=this.strings;let n=!1;if(void 0===o)t=N(this,t,i,0),n=!u(t)||t!==this._$AH&&t!==T,n&&(this._$AH=t);else {const e=t;let l,h;for(t=o[0],l=0;l{var e,o;const n=null!==(e=null==s?void 0:s.renderBefore)&&void 0!==e?e:i;let l=n._$litPart$;if(void 0===l){const t=null!==(o=null==s?void 0:s.renderBefore)&&void 0!==o?o:null;n._$litPart$=l=new M(i.insertBefore(d(),t),t,void 0,null!=s?s:{});}return l._$AI(t),l};
-
+var w;y[x]=!0,y.elementProperties=new Map,y.elementStyles=[],y.shadowRootOptions={mode:"open"},null==g||g({ReactiveElement:y}),(null!==(h=p.reactiveElementVersions)&&void 0!==h?h:p.reactiveElementVersions=[]).push("1.6.2");const E=window,A=E.trustedTypes,C=A?A.createPolicy("lit-html",{createHTML:t=>t}):void 0,S="$lit$",k=`lit$${(Math.random()+"").slice(9)}$`,T="?"+k,I=`<${T}>`,L=document,R=()=>L.createComment(""),O=t=>null===t||"object"!=typeof t&&"function"!=typeof t,$=Array.isArray,z="[ \t\n\f\r]",P=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,V=/-->/g,M=/>/g,F=RegExp(`>|${z}(?:([^\\s"'>=/]+)(${z}*=${z}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),N=/'/g,H=/"/g,D=/^(?:script|style|textarea|title)$/i,B=(t=>(e,...i)=>({_$litType$:t,strings:e,values:i}))(1),U=Symbol.for("lit-noChange"),Y=Symbol.for("lit-nothing"),W=new WeakMap,j=L.createTreeWalker(L,129,null,!1),X=(t,e)=>{const i=t.length-1,n=[];let r,a=2===e?"":"",l=P;for(let e=0;e"===d[0]?(l=null!=r?r:P,c=-1):void 0===d[1]?c=-2:(c=l.lastIndex-d[2].length,o=d[1],l=void 0===d[3]?F:'"'===d[3]?H:N):l===H||l===N?l=F:l===V||l===M?l=P:(l=F,r=void 0);const m=l===F&&t[e+1].startsWith("/>")?" ":"";a+=l===P?i+I:c>=0?(n.push(o),i.slice(0,c)+S+i.slice(c)+k+m):i+k+(-2===c?(n.push(void 0),e):m)}const o=a+(t[i]||">")+(2===e?" ":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==C?C.createHTML(o):o,n]};class q{constructor({strings:t,_$litType$:e},i){let n;this.parts=[];let r=0,a=0;const l=t.length-1,o=this.parts,[d,c]=X(t,e);if(this.el=q.createElement(d,i),j.currentNode=this.el.content,2===e){const t=this.el.content,e=t.firstChild;e.remove(),t.append(...e.childNodes)}for(;null!==(n=j.nextNode())&&o.length0){n.textContent=A?A.emptyScript:"";for(let i=0;i$(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==Y&&O(this._$AH)?this._$AA.nextSibling.data=t:this.$(L.createTextNode(t)),this._$AH=t}g(t){var e;const{values:i,_$litType$:n}=t,r="number"==typeof n?this._$AC(t):(void 0===n.el&&(n.el=q.createElement(n.h,this.options)),n);if((null===(e=this._$AH)||void 0===e?void 0:e._$AD)===r)this._$AH.v(i);else{const t=new G(r,this),e=t.u(this.options);t.v(i),this.$(e),this._$AH=t}}_$AC(t){let e=W.get(t.strings);return void 0===e&&W.set(t.strings,e=new q(t)),e}T(t){$(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,n=0;for(const r of t)n===e.length?e.push(i=new Z(this.k(R()),this.k(R()),this,this.options)):i=e[n],i._$AI(r),n++;n2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=Y}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,i,n){const r=this.strings;let a=!1;if(void 0===r)t=K(this,t,e,0),a=!O(t)||t!==this._$AH&&t!==U,a&&(this._$AH=t);else{const n=t;let l,o;for(t=r[0],l=0;l{var n,r;const a=null!==(n=null==i?void 0:i.renderBefore)&&void 0!==n?n:e;let l=a._$litPart$;if(void 0===l){const t=null!==(r=null==i?void 0:i.renderBefore)&&void 0!==r?r:null;a._$litPart$=l=new Z(e.insertBefore(R(),t),t,void 0,null!=i?i:{})}return l._$AI(t),l})(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!1)}render(){return U}};ot.finalized=!0,ot._$litElement$=!0,null===(at=globalThis.litElementHydrateSupport)||void 0===at||at.call(globalThis,{LitElement:ot});const dt=globalThis.litElementPolyfillSupport;null==dt||dt({LitElement:ot}),(null!==(lt=globalThis.litElementVersions)&&void 0!==lt?lt:globalThis.litElementVersions=[]).push("3.3.2");
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
*/
-const e$5=e=>n=>"function"==typeof n?((e,n)=>(customElements.define(e,n),n))(e,n):((e,n)=>{const{kind:t,elements:s}=n;return {kind:t,elements:s,finisher(n){customElements.define(e,n);}}})(e,n);
-
+const ct=t=>e=>"function"==typeof e?((t,e)=>(customElements.define(t,e),e))(t,e):((t,e)=>{const{kind:i,elements:n}=e;return{kind:i,elements:n,finisher(e){customElements.define(t,e)}}})(t,e)
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */
-const i$3=(i,e)=>"method"===e.kind&&e.descriptor&&!("value"in e.descriptor)?{...e,finisher(n){n.createProperty(e.key,i);}}:{kind:"field",key:Symbol(),placement:"own",descriptor:{},originalKey:e.key,initializer(){"function"==typeof e.initializer&&(this[e.key]=e.initializer.call(this));},finisher(n){n.createProperty(e.key,i);}},e$4=(i,e,n)=>{e.constructor.createProperty(n,i);};function n$3(n){return (t,o)=>void 0!==o?e$4(n,t,o):i$3(n,t)}
-
+ */,st=(t,e)=>"method"===e.kind&&e.descriptor&&!("value"in e.descriptor)?{...e,finisher(i){i.createProperty(e.key,t)}}:{kind:"field",key:Symbol(),placement:"own",descriptor:{},originalKey:e.key,initializer(){"function"==typeof e.initializer&&(this[e.key]=e.initializer.call(this))},finisher(i){i.createProperty(e.key,t)}},mt=(t,e,i)=>{e.constructor.createProperty(i,t)};function ht(t){return(e,i)=>void 0!==i?mt(t,e,i):st(t,e)
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */function t$1(t){return n$3({...t,state:!0})}
-
+ */}function pt(t){return ht({...t,state:!0})}
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */
-const o$4=({finisher:e,descriptor:t})=>(o,n)=>{var r;if(void 0===n){const n=null!==(r=o.originalKey)&&void 0!==r?r:o.key,i=null!=t?{kind:"method",placement:"prototype",key:n,descriptor:t(o.key)}:{...o,key:n};return null!=e&&(i.finisher=function(t){e(t,n);}),i}{const r=o.constructor;void 0!==t&&Object.defineProperty(o,n,t(n)),null==e||e(r,n);}};
-
+ */const ut=({finisher:t,descriptor:e})=>(i,n)=>{var r;if(void 0===n){const n=null!==(r=i.originalKey)&&void 0!==r?r:i.key,a=null!=e?{kind:"method",placement:"prototype",key:n,descriptor:e(i.key)}:{...i,key:n};return null!=t&&(a.finisher=function(e){t(e,n)}),a}{const r=i.constructor;void 0!==e&&Object.defineProperty(i,n,e(n)),null==t||t(r,n)}}
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */function e$3(e){return o$4({finisher:(r,t)=>{Object.assign(r.prototype[t],e);}})}
-
+ */;function ft(t){return ut({finisher:(e,i)=>{Object.assign(e.prototype[i],t)}})}
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */function i$2(i,n){return o$4({descriptor:o=>{const t={get(){var o,n;return null!==(n=null===(o=this.renderRoot)||void 0===o?void 0:o.querySelector(i))&&void 0!==n?n:null},enumerable:!0,configurable:!0};if(n){const n="symbol"==typeof o?Symbol():"__"+o;t.get=function(){var o,t;return void 0===this[n]&&(this[n]=null!==(t=null===(o=this.renderRoot)||void 0===o?void 0:o.querySelector(i))&&void 0!==t?t:null),this[n]};}return t}})}
-
+ */function gt(t,e){return ut({descriptor:i=>{const n={get(){var e,i;return null!==(i=null===(e=this.renderRoot)||void 0===e?void 0:e.querySelector(t))&&void 0!==i?i:null},enumerable:!0,configurable:!0};if(e){const e="symbol"==typeof i?Symbol():"__"+i;n.get=function(){var i,n;return void 0===this[e]&&(this[e]=null!==(n=null===(i=this.renderRoot)||void 0===i?void 0:i.querySelector(t))&&void 0!==n?n:null),this[e]}}return n}})}
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */
-function e$2(e){return o$4({descriptor:r=>({async get(){var r;return await this.updateComplete,null===(r=this.renderRoot)||void 0===r?void 0:r.querySelector(e)},enumerable:!0,configurable:!0})})}
-
+ */function bt(t){return ut({descriptor:e=>({async get(){var e;return await this.updateComplete,null===(e=this.renderRoot)||void 0===e?void 0:e.querySelector(t)},enumerable:!0,configurable:!0})})}
/**
* @license
* Copyright 2021 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */var n$2;null!=(null===(n$2=window.HTMLSlotElement)||void 0===n$2?void 0:n$2.prototype.assignedElements)?(o,n)=>o.assignedElements(n):(o,n)=>o.assignedNodes(n).filter((o=>o.nodeType===Node.ELEMENT_NODE));
-
-class PoLRYTubeItem {
-}
-const PlayableMediaList = ["track", "playlist", "tv_show", "album"];
-const FetchableMediaContentType = [
- "vid_channel",
- "playlist",
- "track",
- "speakers",
- "music",
-];
-const isNumeric = (num) => (typeof num === "number" ||
- (typeof num === "string" && num.trim() !== "")) &&
- !isNaN(num);
-function areDeeplyEqual(obj1, obj2, ignoreKeys) {
- if (obj1 === obj2)
- return true;
- if (Array.isArray(obj1) && Array.isArray(obj2)) {
- if (obj1.length !== obj2.length)
- return false;
- return obj1.every((elem, index) => {
- return areDeeplyEqual(elem, obj2[index], ignoreKeys);
- });
- }
- if (typeof obj1 === "object" &&
- typeof obj2 === "object" &&
- obj1 !== null &&
- obj2 !== null) {
- if (Array.isArray(obj1) || Array.isArray(obj2))
- return false;
- const keys1 = Object.keys(obj1);
- const keys2 = Object.keys(obj2);
- if (keys1.length !== keys2.length ||
- !keys1.every((key) => keys2.includes(key)))
- return false;
- for (let key in obj1) {
- if (ignoreKeys.includes(key))
- continue;
- let isEqual = areDeeplyEqual(obj1[key], obj2[key], ignoreKeys);
- if (!isEqual) {
- return false;
- }
- }
- return true;
- }
- return false;
-}
-
-const ArrowLeftIcon = x `
+ */var vt;null===(vt=window.HTMLSlotElement)||void 0===vt||vt.prototype.assignedElements;class _t{}const xt=["track","playlist","tv_show","album"],yt=["vid_channel","playlist","track","speakers","music"];function wt(t,e,i){if(t===e)return!0;if(Array.isArray(t)&&Array.isArray(e))return t.length===e.length&&t.every(((t,n)=>wt(t,e[n],i)));if("object"==typeof t&&"object"==typeof e&&null!==t&&null!==e){if(Array.isArray(t)||Array.isArray(e))return!1;const n=Object.keys(t),r=Object.keys(e);if(n.length!==r.length||!n.every((t=>r.includes(t))))return!1;for(let n in t){if(i.includes(n))continue;if(!wt(t[n],e[n],i))return!1}return!0}return!1}const Et=B`
arrow-left
-`;
-const CastAudioIcon = x `
+`,At=B`
-`;
-const CloseIcon = x `
+`,Ct=B`
-`;
-const ForwardBurgerIcon = x `
+`,St=B`
forwardburger
-`;
-const RadioTowerIcon = x `
+`,kt=B`
-`;
-const RepeatIcon = x `
+`,Tt=B`
repeat
-`;
-const ShuffleVariantIcon = x `
+`,It=B`
shuffle-variant
-`;
-const SkipNextIcon = x `
+`,Lt=B`
skip-next
-`;
-const SkipPreviousIcon = x `
+`,Rt=B`
skip-previous
-`;
-const PauseIcon = x `
+`,Ot=B`
pause
-`;
-const PlayIcon = x `
+`,$t=B`
play
-`;
-const ThumbUpIcon = x `
+`,zt=B`
thumb-up
-`;
-const ThumbUpOutlineIcon = x `
+`,Pt=B`
thumb-up-outline
-`;
-const VolumeHighIcon = x `
+`,Vt=B`
volume-high
-`;
-const VolumeOffIcon = x `
volume-off
- `;
-
-let PoLRYTubeList = class PoLRYTubeList extends s$1 {
- updated(_changedProperties) {
- // this.renderRoot.querySelector(".current")?.scrollIntoView({
- // behavior: "smooth",
- // block: "start",
- // inline: "center",
- // });
- }
- _is_current(element) {
- if (this.entity == null)
- return false;
- if (!isNumeric(element.media_content_id))
- return false;
- if ("current_track" in this.entity["attributes"]) {
- return (parseInt(element.media_content_id) - 1 ==
- this.entity["attributes"]["current_track"]);
- }
- return false;
- }
- render() {
- if (this.state == 4 /* PoLRYTubeListState.LOADING */) {
- return x `Loading...
`;
- }
- if (this.state == 8 /* PoLRYTubeListState.NO_RESULTS */) {
- return x `No results
`;
- }
- if (this.state == 16 /* PoLRYTubeListState.ERROR */) {
- return x `Unknown Error
`;
- }
- if (this.state == 2 /* PoLRYTubeListState.HAS_RESULTS */) {
- if (this.elements.length == 0)
- return x ``;
- const renderedElements = this.elements.map((element) => {
- return x `
+`;let Ft=class extends ot{updated(t){}_is_current(t){return null!=this.entity&&(("number"==typeof(e=t.media_content_id)||"string"==typeof e&&""!==e.trim())&&!isNaN(e)&&("current_track"in this.entity.attributes&&parseInt(t.media_content_id)-1==this.entity.attributes.current_track));var e}render(){if(4==this.state)return B`Loading...
`;if(8==this.state)return B`No results
`;if(16==this.state)return B`Unknown Error
`;if(2==this.state){if(0==this.elements.length)return B``;const t=this.elements.map((t=>B`
- ${this._renderThumbnail(element)}
-
${element.title}
+ class="element ${this._is_current(t)?"current":""}">
+ ${this._renderThumbnail(t)}
+
${t.title}
- ${this._renderMoreButton(element)}
- ${this._renderRadioButton(element)}
- ${this._renderPlayButton(element)}
+ ${this._renderMoreButton(t)}
+ ${this._renderRadioButton(t)}
+ ${this._renderPlayButton(t)}
- `;
- });
- return x `
+ `));return B`
-
${renderedElements}
+
${t}
- `;
- }
- }
- _renderMoreButton(element) {
- if (!element["can_expand"])
- return x ``;
- return x `
- this._fireNavigateEvent(element)}>
- ${ForwardBurgerIcon}
+ `}}_renderMoreButton(t){return t.can_expand?B`
+ this._fireNavigateEvent(t)}>
+ ${St}
- `;
- }
- _renderPlayButton(element) {
- if (!element.can_play)
- return x ``;
- return x `
- this._play(element)}>
- ${PlayIcon}
+ `:B``}_renderPlayButton(t){return t.can_play?B`
+ this._play(t)}>
+ ${$t}
- `;
- }
- _renderRadioButton(element) {
- if (this._is_current(element) ||
- element.media_content_type == "track") {
- const id = element.media_content_type == "track"
- ? element.media_content_id
- : this.entity["attributes"]["videoId"];
- return x `
- this._startRadio(id)}>
- ${RadioTowerIcon}
+ `:B``}_renderRadioButton(t){if(this._is_current(t)||"track"==t.media_content_type){const e="track"==t.media_content_type?t.media_content_id:this.entity.attributes.videoId;return B`
+ this._startRadio(e)}>
+ ${kt}
- `;
- }
- return A;
- }
- _renderThumbnail(element) {
- if (element.thumbnail == "") {
- return x `
+ `}return Y}_renderThumbnail(t){return""==t.thumbnail?B`
-
`;
- }
- return x `
`;
- }
- async _fireNavigateEvent(element) {
- this.dispatchEvent(new CustomEvent("navigate", {
- detail: {
- action: element,
- },
- }));
- return;
- }
- async _startRadio(media_content_id) {
- this.hass.callService("media_player", "shuffle_set", {
- entity_id: this.entity["entity_id"],
- shuffle: false,
- });
- this.hass.callService("media_player", "play_media", {
- entity_id: this.entity["entity_id"],
- media_content_id: media_content_id,
- media_content_type: "vid_channel",
- });
- return;
- }
- async _play(element) {
- if (element.media_content_type == "PLAYLIST_GOTO_TRACK") {
- this.hass.callService("ytube_music_player", "call_method", {
- entity_id: this.entity["entity_id"],
- command: "goto_track",
- parameters: element.media_content_id,
- });
- return;
- }
- if (PlayableMediaList.includes(element.media_class)) {
- this.hass.callService("media_player", "play_media", {
- entity_id: this.entity["entity_id"],
- media_content_id: element.media_content_id,
- media_content_type: element.media_content_type,
- });
- return;
- }
- }
- static get styles() {
- return [
- i$5 `
+
`:B` `}async _fireNavigateEvent(t){this.dispatchEvent(new CustomEvent("navigate",{detail:{action:t}}))}async _startRadio(t){this.hass.callService("media_player","shuffle_set",{entity_id:this.entity.entity_id,shuffle:!1}),this.hass.callService("media_player","play_media",{entity_id:this.entity.entity_id,media_content_id:t,media_content_type:"vid_channel"})}async _play(t){"PLAYLIST_GOTO_TRACK"!=t.media_content_type?xt.includes(t.media_class)&&this.hass.callService("media_player","play_media",{entity_id:this.entity.entity_id,media_content_id:t.media_content_id,media_content_type:t.media_content_type}):this.hass.callService("ytube_music_player","call_method",{entity_id:this.entity.entity_id,command:"goto_track",parameters:t.media_content_id})}static get styles(){return[s`
.elements {
}
@@ -484,40 +223,7 @@ let PoLRYTubeList = class PoLRYTubeList extends s$1 {
justify-items: center;
height: 100px;
}
- `,
- ];
- }
-};
-__decorate([
- t$1()
-], PoLRYTubeList.prototype, "entity", void 0);
-__decorate([
- t$1()
-], PoLRYTubeList.prototype, "hass", void 0);
-__decorate([
- t$1()
-], PoLRYTubeList.prototype, "elements", void 0);
-__decorate([
- t$1()
-], PoLRYTubeList.prototype, "state", void 0);
-PoLRYTubeList = __decorate([
- e$5("polr-ytube-list")
-], PoLRYTubeList);
-
-/**
- * @license
- * Copyright 2021 Google LLC
- * SPDX-License-Identifier: BSD-3-Clause
- */
-function*o$3(o,t){const f="function"==typeof t;if(void 0!==o){let i=-1;for(const n of o)i>-1&&(yield f?t(i):t),i++,yield n;}}
-
-/**
- * @license
- * Copyright 2021 Google LLC
- * SPDX-License-Identifier: BSD-3-Clause
- */
-function*o$2(o,f){if(void 0!==o){let i=0;for(const t of o)yield f(t,i++);}}
-
+ `]}};n([pt()],Ft.prototype,"entity",void 0),n([pt()],Ft.prototype,"hass",void 0),n([pt()],Ft.prototype,"elements",void 0),n([pt()],Ft.prototype,"state",void 0),Ft=n([ct("polr-ytube-list")],Ft);
/**
* @license
* Copyright 2020 Google Inc.
@@ -540,104 +246,7 @@ function*o$2(o,f){if(void 0!==o){let i=0;for(const t of o)yield f(t,i++);}}
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
-/**
- * KEY provides normalized string values for keys.
- */
-var KEY = {
- UNKNOWN: 'Unknown',
- BACKSPACE: 'Backspace',
- ENTER: 'Enter',
- SPACEBAR: 'Spacebar',
- PAGE_UP: 'PageUp',
- PAGE_DOWN: 'PageDown',
- END: 'End',
- HOME: 'Home',
- ARROW_LEFT: 'ArrowLeft',
- ARROW_UP: 'ArrowUp',
- ARROW_RIGHT: 'ArrowRight',
- ARROW_DOWN: 'ArrowDown',
- DELETE: 'Delete',
- ESCAPE: 'Escape',
- TAB: 'Tab',
-};
-var normalizedKeys = new Set();
-// IE11 has no support for new Map with iterable so we need to initialize this
-// by hand.
-normalizedKeys.add(KEY.BACKSPACE);
-normalizedKeys.add(KEY.ENTER);
-normalizedKeys.add(KEY.SPACEBAR);
-normalizedKeys.add(KEY.PAGE_UP);
-normalizedKeys.add(KEY.PAGE_DOWN);
-normalizedKeys.add(KEY.END);
-normalizedKeys.add(KEY.HOME);
-normalizedKeys.add(KEY.ARROW_LEFT);
-normalizedKeys.add(KEY.ARROW_UP);
-normalizedKeys.add(KEY.ARROW_RIGHT);
-normalizedKeys.add(KEY.ARROW_DOWN);
-normalizedKeys.add(KEY.DELETE);
-normalizedKeys.add(KEY.ESCAPE);
-normalizedKeys.add(KEY.TAB);
-var KEY_CODE = {
- BACKSPACE: 8,
- ENTER: 13,
- SPACEBAR: 32,
- PAGE_UP: 33,
- PAGE_DOWN: 34,
- END: 35,
- HOME: 36,
- ARROW_LEFT: 37,
- ARROW_UP: 38,
- ARROW_RIGHT: 39,
- ARROW_DOWN: 40,
- DELETE: 46,
- ESCAPE: 27,
- TAB: 9,
-};
-var mappedKeyCodes = new Map();
-// IE11 has no support for new Map with iterable so we need to initialize this
-// by hand.
-mappedKeyCodes.set(KEY_CODE.BACKSPACE, KEY.BACKSPACE);
-mappedKeyCodes.set(KEY_CODE.ENTER, KEY.ENTER);
-mappedKeyCodes.set(KEY_CODE.SPACEBAR, KEY.SPACEBAR);
-mappedKeyCodes.set(KEY_CODE.PAGE_UP, KEY.PAGE_UP);
-mappedKeyCodes.set(KEY_CODE.PAGE_DOWN, KEY.PAGE_DOWN);
-mappedKeyCodes.set(KEY_CODE.END, KEY.END);
-mappedKeyCodes.set(KEY_CODE.HOME, KEY.HOME);
-mappedKeyCodes.set(KEY_CODE.ARROW_LEFT, KEY.ARROW_LEFT);
-mappedKeyCodes.set(KEY_CODE.ARROW_UP, KEY.ARROW_UP);
-mappedKeyCodes.set(KEY_CODE.ARROW_RIGHT, KEY.ARROW_RIGHT);
-mappedKeyCodes.set(KEY_CODE.ARROW_DOWN, KEY.ARROW_DOWN);
-mappedKeyCodes.set(KEY_CODE.DELETE, KEY.DELETE);
-mappedKeyCodes.set(KEY_CODE.ESCAPE, KEY.ESCAPE);
-mappedKeyCodes.set(KEY_CODE.TAB, KEY.TAB);
-var navigationKeys = new Set();
-// IE11 has no support for new Set with iterable so we need to initialize this
-// by hand.
-navigationKeys.add(KEY.PAGE_UP);
-navigationKeys.add(KEY.PAGE_DOWN);
-navigationKeys.add(KEY.END);
-navigationKeys.add(KEY.HOME);
-navigationKeys.add(KEY.ARROW_LEFT);
-navigationKeys.add(KEY.ARROW_UP);
-navigationKeys.add(KEY.ARROW_RIGHT);
-navigationKeys.add(KEY.ARROW_DOWN);
-/**
- * normalizeKey returns the normalized string for a navigational action.
- */
-function normalizeKey(evt) {
- var key = evt.key;
- // If the event already has a normalized key, return it
- if (normalizedKeys.has(key)) {
- return key;
- }
- // tslint:disable-next-line:deprecation
- var mappedKey = mappedKeyCodes.get(evt.keyCode);
- if (mappedKey) {
- return mappedKey;
- }
- return KEY.UNKNOWN;
-}
-
+var Nt={UNKNOWN:"Unknown",BACKSPACE:"Backspace",ENTER:"Enter",SPACEBAR:"Spacebar",PAGE_UP:"PageUp",PAGE_DOWN:"PageDown",END:"End",HOME:"Home",ARROW_LEFT:"ArrowLeft",ARROW_UP:"ArrowUp",ARROW_RIGHT:"ArrowRight",ARROW_DOWN:"ArrowDown",DELETE:"Delete",ESCAPE:"Escape",TAB:"Tab"},Ht=new Set;Ht.add(Nt.BACKSPACE),Ht.add(Nt.ENTER),Ht.add(Nt.SPACEBAR),Ht.add(Nt.PAGE_UP),Ht.add(Nt.PAGE_DOWN),Ht.add(Nt.END),Ht.add(Nt.HOME),Ht.add(Nt.ARROW_LEFT),Ht.add(Nt.ARROW_UP),Ht.add(Nt.ARROW_RIGHT),Ht.add(Nt.ARROW_DOWN),Ht.add(Nt.DELETE),Ht.add(Nt.ESCAPE),Ht.add(Nt.TAB);var Dt=8,Bt=13,Ut=32,Yt=33,Wt=34,jt=35,Xt=36,qt=37,Kt=38,Gt=39,Zt=40,Qt=46,Jt=27,te=9,ee=new Map;ee.set(Dt,Nt.BACKSPACE),ee.set(Bt,Nt.ENTER),ee.set(Ut,Nt.SPACEBAR),ee.set(Yt,Nt.PAGE_UP),ee.set(Wt,Nt.PAGE_DOWN),ee.set(jt,Nt.END),ee.set(Xt,Nt.HOME),ee.set(qt,Nt.ARROW_LEFT),ee.set(Kt,Nt.ARROW_UP),ee.set(Gt,Nt.ARROW_RIGHT),ee.set(Zt,Nt.ARROW_DOWN),ee.set(Qt,Nt.DELETE),ee.set(Jt,Nt.ESCAPE),ee.set(te,Nt.TAB);var ie,ne,re=new Set;function ae(t){var e=t.key;if(Ht.has(e))return e;var i=ee.get(t.keyCode);return i||Nt.UNKNOWN}
/**
* @license
* Copyright 2018 Google Inc.
@@ -659,101 +268,7 @@ function normalizeKey(evt) {
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
- */
-var _a$1, _b$1;
-var cssClasses$7 = {
- LIST_ITEM_ACTIVATED_CLASS: 'mdc-list-item--activated',
- LIST_ITEM_CLASS: 'mdc-list-item',
- LIST_ITEM_DISABLED_CLASS: 'mdc-list-item--disabled',
- LIST_ITEM_SELECTED_CLASS: 'mdc-list-item--selected',
- LIST_ITEM_TEXT_CLASS: 'mdc-list-item__text',
- LIST_ITEM_PRIMARY_TEXT_CLASS: 'mdc-list-item__primary-text',
- ROOT: 'mdc-list',
-};
-(_a$1 = {},
- _a$1["" + cssClasses$7.LIST_ITEM_ACTIVATED_CLASS] = 'mdc-list-item--activated',
- _a$1["" + cssClasses$7.LIST_ITEM_CLASS] = 'mdc-list-item',
- _a$1["" + cssClasses$7.LIST_ITEM_DISABLED_CLASS] = 'mdc-list-item--disabled',
- _a$1["" + cssClasses$7.LIST_ITEM_SELECTED_CLASS] = 'mdc-list-item--selected',
- _a$1["" + cssClasses$7.LIST_ITEM_PRIMARY_TEXT_CLASS] = 'mdc-list-item__primary-text',
- _a$1["" + cssClasses$7.ROOT] = 'mdc-list',
- _a$1);
-var deprecatedClassNameMap = (_b$1 = {},
- _b$1["" + cssClasses$7.LIST_ITEM_ACTIVATED_CLASS] = 'mdc-deprecated-list-item--activated',
- _b$1["" + cssClasses$7.LIST_ITEM_CLASS] = 'mdc-deprecated-list-item',
- _b$1["" + cssClasses$7.LIST_ITEM_DISABLED_CLASS] = 'mdc-deprecated-list-item--disabled',
- _b$1["" + cssClasses$7.LIST_ITEM_SELECTED_CLASS] = 'mdc-deprecated-list-item--selected',
- _b$1["" + cssClasses$7.LIST_ITEM_TEXT_CLASS] = 'mdc-deprecated-list-item__text',
- _b$1["" + cssClasses$7.LIST_ITEM_PRIMARY_TEXT_CLASS] = 'mdc-deprecated-list-item__primary-text',
- _b$1["" + cssClasses$7.ROOT] = 'mdc-deprecated-list',
- _b$1);
-({
- ACTION_EVENT: 'MDCList:action',
- SELECTION_CHANGE_EVENT: 'MDCList:selectionChange',
- ARIA_CHECKED: 'aria-checked',
- ARIA_CHECKED_CHECKBOX_SELECTOR: '[role="checkbox"][aria-checked="true"]',
- ARIA_CHECKED_RADIO_SELECTOR: '[role="radio"][aria-checked="true"]',
- ARIA_CURRENT: 'aria-current',
- ARIA_DISABLED: 'aria-disabled',
- ARIA_ORIENTATION: 'aria-orientation',
- ARIA_ORIENTATION_HORIZONTAL: 'horizontal',
- ARIA_ROLE_CHECKBOX_SELECTOR: '[role="checkbox"]',
- ARIA_SELECTED: 'aria-selected',
- ARIA_INTERACTIVE_ROLES_SELECTOR: '[role="listbox"], [role="menu"]',
- ARIA_MULTI_SELECTABLE_SELECTOR: '[aria-multiselectable="true"]',
- CHECKBOX_RADIO_SELECTOR: 'input[type="checkbox"], input[type="radio"]',
- CHECKBOX_SELECTOR: 'input[type="checkbox"]',
- CHILD_ELEMENTS_TO_TOGGLE_TABINDEX: "\n ." + cssClasses$7.LIST_ITEM_CLASS + " button:not(:disabled),\n ." + cssClasses$7.LIST_ITEM_CLASS + " a,\n ." + deprecatedClassNameMap[cssClasses$7.LIST_ITEM_CLASS] + " button:not(:disabled),\n ." + deprecatedClassNameMap[cssClasses$7.LIST_ITEM_CLASS] + " a\n ",
- DEPRECATED_SELECTOR: '.mdc-deprecated-list',
- FOCUSABLE_CHILD_ELEMENTS: "\n ." + cssClasses$7.LIST_ITEM_CLASS + " button:not(:disabled),\n ." + cssClasses$7.LIST_ITEM_CLASS + " a,\n ." + cssClasses$7.LIST_ITEM_CLASS + " input[type=\"radio\"]:not(:disabled),\n ." + cssClasses$7.LIST_ITEM_CLASS + " input[type=\"checkbox\"]:not(:disabled),\n ." + deprecatedClassNameMap[cssClasses$7.LIST_ITEM_CLASS] + " button:not(:disabled),\n ." + deprecatedClassNameMap[cssClasses$7.LIST_ITEM_CLASS] + " a,\n ." + deprecatedClassNameMap[cssClasses$7.LIST_ITEM_CLASS] + " input[type=\"radio\"]:not(:disabled),\n ." + deprecatedClassNameMap[cssClasses$7.LIST_ITEM_CLASS] + " input[type=\"checkbox\"]:not(:disabled)\n ",
- RADIO_SELECTOR: 'input[type="radio"]',
- SELECTED_ITEM_SELECTOR: '[aria-selected="true"], [aria-current="true"]',
-});
-var numbers$3 = {
- UNSET_INDEX: -1,
- TYPEAHEAD_BUFFER_CLEAR_TIMEOUT_MS: 300
-};
-
-/**
- * @license
- * Copyright 2020 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-var ELEMENTS_KEY_ALLOWED_IN = ['input', 'button', 'textarea', 'select'];
-/**
- * Ensures that preventDefault is only called if the containing element
- * doesn't consume the event, and it will cause an unintended scroll.
- *
- * @param evt keyboard event to be prevented.
- */
-var preventDefaultEvent = function (evt) {
- var target = evt.target;
- if (!target) {
- return;
- }
- var tagName = ("" + target.tagName).toLowerCase();
- if (ELEMENTS_KEY_ALLOWED_IN.indexOf(tagName) === -1) {
- evt.preventDefault();
- }
-};
-
+ */re.add(Nt.PAGE_UP),re.add(Nt.PAGE_DOWN),re.add(Nt.END),re.add(Nt.HOME),re.add(Nt.ARROW_LEFT),re.add(Nt.ARROW_UP),re.add(Nt.ARROW_RIGHT),re.add(Nt.ARROW_DOWN);var le="mdc-list-item--activated",oe="mdc-list-item",de="mdc-list-item--disabled",ce="mdc-list-item--selected",se="mdc-list-item__text",me="mdc-list-item__primary-text",he="mdc-list";(ie={})[""+le]="mdc-list-item--activated",ie[""+oe]="mdc-list-item",ie[""+de]="mdc-list-item--disabled",ie[""+ce]="mdc-list-item--selected",ie[""+me]="mdc-list-item__primary-text",ie[""+he]="mdc-list";var pe=((ne={})[""+le]="mdc-deprecated-list-item--activated",ne[""+oe]="mdc-deprecated-list-item",ne[""+de]="mdc-deprecated-list-item--disabled",ne[""+ce]="mdc-deprecated-list-item--selected",ne[""+se]="mdc-deprecated-list-item__text",ne[""+me]="mdc-deprecated-list-item__primary-text",ne[""+he]="mdc-deprecated-list",ne);pe[oe],pe[oe],pe[oe],pe[oe],pe[oe],pe[oe];var ue={UNSET_INDEX:-1,TYPEAHEAD_BUFFER_CLEAR_TIMEOUT_MS:300},fe=["input","button","textarea","select"],ge=function(t){var e=t.target;if(e){var i=(""+e.tagName).toLowerCase();-1===fe.indexOf(i)&&t.preventDefault()}};
/**
* @license
* Copyright 2020 Google Inc.
@@ -775,524 +290,24 @@ var preventDefaultEvent = function (evt) {
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
- */
-/**
- * Initializes a state object for typeahead. Use the same reference for calls to
- * typeahead functions.
- *
- * @return The current state of the typeahead process. Each state reference
- * represents a typeahead instance as the reference is typically mutated
- * in-place.
- */
-function initState() {
- var state = {
- bufferClearTimeout: 0,
- currentFirstChar: '',
- sortedIndexCursor: 0,
- typeaheadBuffer: '',
- };
- return state;
-}
-/**
- * Initializes typeahead state by indexing the current list items by primary
- * text into the sortedIndexByFirstChar data structure.
- *
- * @param listItemCount numer of items in the list
- * @param getPrimaryTextByItemIndex function that returns the primary text at a
- * given index
- *
- * @return Map that maps the first character of the primary text to the full
- * list text and it's index
- */
-function initSortedIndex(listItemCount, getPrimaryTextByItemIndex) {
- var sortedIndexByFirstChar = new Map();
- // Aggregate item text to index mapping
- for (var i = 0; i < listItemCount; i++) {
- var primaryText = getPrimaryTextByItemIndex(i).trim();
- if (!primaryText) {
- continue;
- }
- var firstChar = primaryText[0].toLowerCase();
- if (!sortedIndexByFirstChar.has(firstChar)) {
- sortedIndexByFirstChar.set(firstChar, []);
- }
- sortedIndexByFirstChar.get(firstChar).push({ text: primaryText.toLowerCase(), index: i });
- }
- // Sort the mapping
- // TODO(b/157162694): Investigate replacing forEach with Map.values()
- sortedIndexByFirstChar.forEach(function (values) {
- values.sort(function (first, second) {
- return first.index - second.index;
- });
- });
- return sortedIndexByFirstChar;
-}
-/**
- * Given the next desired character from the user, it attempts to find the next
- * list option matching the buffer. Wraps around if at the end of options.
- *
- * @param opts Options and accessors
- * - nextChar - the next character to match against items
- * - sortedIndexByFirstChar - output of `initSortedIndex(...)`
- * - focusedItemIndex - the index of the currently focused item
- * - focusItemAtIndex - function that focuses a list item at given index
- * - skipFocus - whether or not to focus the matched item
- * - isItemAtIndexDisabled - function that determines whether an item at a
- * given index is disabled
- * @param state The typeahead state instance. See `initState`.
- *
- * @return The index of the matched item, or -1 if no match.
- */
-function matchItem(opts, state) {
- var nextChar = opts.nextChar, focusItemAtIndex = opts.focusItemAtIndex, sortedIndexByFirstChar = opts.sortedIndexByFirstChar, focusedItemIndex = opts.focusedItemIndex, skipFocus = opts.skipFocus, isItemAtIndexDisabled = opts.isItemAtIndexDisabled;
- clearTimeout(state.bufferClearTimeout);
- state.bufferClearTimeout = setTimeout(function () {
- clearBuffer(state);
- }, numbers$3.TYPEAHEAD_BUFFER_CLEAR_TIMEOUT_MS);
- state.typeaheadBuffer = state.typeaheadBuffer + nextChar;
- var index;
- if (state.typeaheadBuffer.length === 1) {
- index = matchFirstChar(sortedIndexByFirstChar, focusedItemIndex, isItemAtIndexDisabled, state);
- }
- else {
- index = matchAllChars(sortedIndexByFirstChar, isItemAtIndexDisabled, state);
- }
- if (index !== -1 && !skipFocus) {
- focusItemAtIndex(index);
- }
- return index;
-}
-/**
- * Matches the user's single input character in the buffer to the
- * next option that begins with such character. Wraps around if at
- * end of options. Returns -1 if no match is found.
- */
-function matchFirstChar(sortedIndexByFirstChar, focusedItemIndex, isItemAtIndexDisabled, state) {
- var firstChar = state.typeaheadBuffer[0];
- var itemsMatchingFirstChar = sortedIndexByFirstChar.get(firstChar);
- if (!itemsMatchingFirstChar) {
- return -1;
- }
- // Has the same firstChar been recently matched?
- // Also, did starting index remain the same between key presses?
- // If both hold true, simply increment index.
- if (firstChar === state.currentFirstChar &&
- itemsMatchingFirstChar[state.sortedIndexCursor].index ===
- focusedItemIndex) {
- state.sortedIndexCursor =
- (state.sortedIndexCursor + 1) % itemsMatchingFirstChar.length;
- var newIndex = itemsMatchingFirstChar[state.sortedIndexCursor].index;
- if (!isItemAtIndexDisabled(newIndex)) {
- return newIndex;
- }
- }
- // If we're here, it means one of the following happened:
- // - either firstChar or startingIndex has changed, invalidating the
- // cursor.
- // - The next item of typeahead is disabled, so we have to look further.
- state.currentFirstChar = firstChar;
- var newCursorPosition = -1;
- var cursorPosition;
- // Find the first non-disabled item as a fallback.
- for (cursorPosition = 0; cursorPosition < itemsMatchingFirstChar.length; cursorPosition++) {
- if (!isItemAtIndexDisabled(itemsMatchingFirstChar[cursorPosition].index)) {
- newCursorPosition = cursorPosition;
- break;
- }
- }
- // Advance cursor to first item matching the firstChar that is positioned
- // after starting item. Cursor is unchanged from fallback if there's no
- // such item.
- for (; cursorPosition < itemsMatchingFirstChar.length; cursorPosition++) {
- if (itemsMatchingFirstChar[cursorPosition].index > focusedItemIndex &&
- !isItemAtIndexDisabled(itemsMatchingFirstChar[cursorPosition].index)) {
- newCursorPosition = cursorPosition;
- break;
- }
- }
- if (newCursorPosition !== -1) {
- state.sortedIndexCursor = newCursorPosition;
- return itemsMatchingFirstChar[state.sortedIndexCursor].index;
- }
- return -1;
-}
-/**
- * Attempts to find the next item that matches all of the typeahead buffer.
- * Wraps around if at end of options. Returns -1 if no match is found.
- */
-function matchAllChars(sortedIndexByFirstChar, isItemAtIndexDisabled, state) {
- var firstChar = state.typeaheadBuffer[0];
- var itemsMatchingFirstChar = sortedIndexByFirstChar.get(firstChar);
- if (!itemsMatchingFirstChar) {
- return -1;
- }
- // Do nothing if text already matches
- var startingItem = itemsMatchingFirstChar[state.sortedIndexCursor];
- if (startingItem.text.lastIndexOf(state.typeaheadBuffer, 0) === 0 &&
- !isItemAtIndexDisabled(startingItem.index)) {
- return startingItem.index;
- }
- // Find next item that matches completely; if no match, we'll eventually
- // loop around to same position
- var cursorPosition = (state.sortedIndexCursor + 1) % itemsMatchingFirstChar.length;
- var nextCursorPosition = -1;
- while (cursorPosition !== state.sortedIndexCursor) {
- var currentItem = itemsMatchingFirstChar[cursorPosition];
- var matches = currentItem.text.lastIndexOf(state.typeaheadBuffer, 0) === 0;
- var isEnabled = !isItemAtIndexDisabled(currentItem.index);
- if (matches && isEnabled) {
- nextCursorPosition = cursorPosition;
- break;
- }
- cursorPosition = (cursorPosition + 1) % itemsMatchingFirstChar.length;
- }
- if (nextCursorPosition !== -1) {
- state.sortedIndexCursor = nextCursorPosition;
- return itemsMatchingFirstChar[state.sortedIndexCursor].index;
- }
- return -1;
-}
-/**
- * Whether or not the given typeahead instaance state is currently typing.
- *
- * @param state The typeahead state instance. See `initState`.
- */
-function isTypingInProgress(state) {
- return state.typeaheadBuffer.length > 0;
-}
-/**
- * Clears the typeahaed buffer so that it resets item matching to the first
- * character.
- *
- * @param state The typeahead state instance. See `initState`.
- */
-function clearBuffer(state) {
- state.typeaheadBuffer = '';
-}
-/**
- * Given a keydown event, it calculates whether or not to automatically focus a
- * list item depending on what was typed mimicing the typeahead functionality of
- * a standard element that is open.
- *
- * @param opts Options and accessors
- * - event - the KeyboardEvent to handle and parse
- * - sortedIndexByFirstChar - output of `initSortedIndex(...)`
- * - focusedItemIndex - the index of the currently focused item
- * - focusItemAtIndex - function that focuses a list item at given index
- * - isItemAtFocusedIndexDisabled - whether or not the currently focused item
- * is disabled
- * - isTargetListItem - whether or not the event target is a list item
- * @param state The typeahead state instance. See `initState`.
- *
- * @returns index of the item matched by the keydown. -1 if not matched.
- */
-function handleKeydown(opts, state) {
- var event = opts.event, isTargetListItem = opts.isTargetListItem, focusedItemIndex = opts.focusedItemIndex, focusItemAtIndex = opts.focusItemAtIndex, sortedIndexByFirstChar = opts.sortedIndexByFirstChar, isItemAtIndexDisabled = opts.isItemAtIndexDisabled;
- var isArrowLeft = normalizeKey(event) === 'ArrowLeft';
- var isArrowUp = normalizeKey(event) === 'ArrowUp';
- var isArrowRight = normalizeKey(event) === 'ArrowRight';
- var isArrowDown = normalizeKey(event) === 'ArrowDown';
- var isHome = normalizeKey(event) === 'Home';
- var isEnd = normalizeKey(event) === 'End';
- var isEnter = normalizeKey(event) === 'Enter';
- var isSpace = normalizeKey(event) === 'Spacebar';
- if (event.altKey || event.ctrlKey || event.metaKey || isArrowLeft ||
- isArrowUp || isArrowRight || isArrowDown || isHome || isEnd || isEnter) {
- return -1;
- }
- var isCharacterKey = !isSpace && event.key.length === 1;
- if (isCharacterKey) {
- preventDefaultEvent(event);
- var matchItemOpts = {
- focusItemAtIndex: focusItemAtIndex,
- focusedItemIndex: focusedItemIndex,
- nextChar: event.key.toLowerCase(),
- sortedIndexByFirstChar: sortedIndexByFirstChar,
- skipFocus: false,
- isItemAtIndexDisabled: isItemAtIndexDisabled,
- };
- return matchItem(matchItemOpts, state);
- }
- if (!isSpace) {
- return -1;
- }
- if (isTargetListItem) {
- preventDefaultEvent(event);
- }
- var typeaheadOnListItem = isTargetListItem && isTypingInProgress(state);
- if (typeaheadOnListItem) {
- var matchItemOpts = {
- focusItemAtIndex: focusItemAtIndex,
- focusedItemIndex: focusedItemIndex,
- nextChar: ' ',
- sortedIndexByFirstChar: sortedIndexByFirstChar,
- skipFocus: false,
- isItemAtIndexDisabled: isItemAtIndexDisabled,
- };
- // space participates in typeahead matching if in rapid typing mode
- return matchItem(matchItemOpts, state);
- }
- return -1;
-}
-
-/**
- * @license
- * Copyright 2018 Google LLC
- * SPDX-License-Identifier: Apache-2.0
- */
-// Style preference for leading underscores.
-// tslint:disable:strip-private-property-underscore
-/**
- * Determines whether a node is an element.
- *
- * @param node Node to check
- */
-const isNodeElement = (node) => {
- return node.nodeType === Node.ELEMENT_NODE;
-};
-function addHasRemoveClass(element) {
- return {
- addClass: (className) => {
- element.classList.add(className);
- },
- removeClass: (className) => {
- element.classList.remove(className);
- },
- hasClass: (className) => element.classList.contains(className),
- };
-}
-const fn = () => { };
-const optionsBlock = {
- get passive() {
- return false;
- }
-};
-document.addEventListener('x', fn, optionsBlock);
-document.removeEventListener('x', fn);
-
+ */function be(t,e){for(var i=new Map,n=0;ne&&!i(a[o].index)){d=o;break}if(-1!==d)return n.sortedIndexCursor=d,a[n.sortedIndexCursor].index;return-1}(a,l,d,e):function(t,e,i){var n=i.typeaheadBuffer[0],r=t.get(n);if(!r)return-1;var a=r[i.sortedIndexCursor];if(0===a.text.lastIndexOf(i.typeaheadBuffer,0)&&!e(a.index))return a.index;var l=(i.sortedIndexCursor+1)%r.length,o=-1;for(;l!==i.sortedIndexCursor;){var d=r[l],c=0===d.text.lastIndexOf(i.typeaheadBuffer,0),s=!e(d.index);if(c&&s){o=l;break}l=(l+1)%r.length}if(-1!==o)return i.sortedIndexCursor=o,r[i.sortedIndexCursor].index;return-1}(a,d,e),-1===i||o||r(i),i}function _e(t){return t.typeaheadBuffer.length>0}function xe(t){return{addClass:e=>{t.classList.add(e)},removeClass:e=>{t.classList.remove(e)},hasClass:e=>t.classList.contains(e)}}const ye=()=>{},we={get passive(){return!1}};document.addEventListener("x",ye,we),document.removeEventListener("x",ye);
/**
* @license
* Copyright 2018 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
-/** @soyCompatible */
-class BaseElement extends s$1 {
- click() {
- if (this.mdcRoot) {
- this.mdcRoot.focus();
- this.mdcRoot.click();
- return;
- }
- super.click();
- }
- /**
- * Create and attach the MDC Foundation to the instance
- */
- createFoundation() {
- if (this.mdcFoundation !== undefined) {
- this.mdcFoundation.destroy();
- }
- if (this.mdcFoundationClass) {
- this.mdcFoundation = new this.mdcFoundationClass(this.createAdapter());
- this.mdcFoundation.init();
- }
- }
- firstUpdated() {
- this.createFoundation();
- }
-}
-
+class Ee extends ot{click(){if(this.mdcRoot)return this.mdcRoot.focus(),void this.mdcRoot.click();super.click()}createFoundation(){void 0!==this.mdcFoundation&&this.mdcFoundation.destroy(),this.mdcFoundationClass&&(this.mdcFoundation=new this.mdcFoundationClass(this.createAdapter()),this.mdcFoundation.init())}firstUpdated(){this.createFoundation()}}
/**
* @license
* Copyright 2018 Google LLC
* SPDX-License-Identifier: Apache-2.0
- */
-var _a, _b;
-// ShadyDOM should submit elements in component internals
-const USING_SHADY_DOM = (_b = (_a = window.ShadyDOM) === null || _a === void 0 ? void 0 : _a.inUse) !== null && _b !== void 0 ? _b : false;
-/** @soyCompatible */
-class FormElement extends BaseElement {
- constructor() {
- super(...arguments);
- /**
- * Disabled state for the component. When `disabled` is set to `true`, the
- * component will not be added to form submission.
- */
- this.disabled = false;
- /**
- * Form element that contains this element
- */
- this.containingForm = null;
- this.formDataListener = (ev) => {
- if (!this.disabled) {
- this.setFormData(ev.formData);
- }
- };
- }
- findFormElement() {
- // If the component internals are not in Shadow DOM, subscribing to form
- // data events could lead to duplicated data, which may not work correctly
- // on the server side.
- if (!this.shadowRoot || USING_SHADY_DOM) {
- return null;
- }
- const root = this.getRootNode();
- const forms = root.querySelectorAll('form');
- for (const form of Array.from(forms)) {
- if (form.contains(this)) {
- return form;
- }
- }
- return null;
- }
- connectedCallback() {
- var _a;
- super.connectedCallback();
- this.containingForm = this.findFormElement();
- (_a = this.containingForm) === null || _a === void 0 ? void 0 : _a.addEventListener('formdata', this.formDataListener);
- }
- disconnectedCallback() {
- var _a;
- super.disconnectedCallback();
- (_a = this.containingForm) === null || _a === void 0 ? void 0 : _a.removeEventListener('formdata', this.formDataListener);
- this.containingForm = null;
- }
- click() {
- if (this.formElement && !this.disabled) {
- this.formElement.focus();
- this.formElement.click();
- }
- }
- firstUpdated() {
- super.firstUpdated();
- if (this.shadowRoot) {
- this.mdcRoot.addEventListener('change', (e) => {
- this.dispatchEvent(new Event('change', e));
- });
- }
- }
-}
-FormElement.shadowRootOptions = { mode: 'open', delegatesFocus: true };
-__decorate([
- n$3({ type: Boolean })
-], FormElement.prototype, "disabled", void 0);
-
+ */var Ae,Ce;const Se=null!==(Ce=null===(Ae=window.ShadyDOM)||void 0===Ae?void 0:Ae.inUse)&&void 0!==Ce&&Ce;class ke extends Ee{constructor(){super(...arguments),this.disabled=!1,this.containingForm=null,this.formDataListener=t=>{this.disabled||this.setFormData(t.formData)}}findFormElement(){if(!this.shadowRoot||Se)return null;const t=this.getRootNode().querySelectorAll("form");for(const e of Array.from(t))if(e.contains(this))return e;return null}connectedCallback(){var t;super.connectedCallback(),this.containingForm=this.findFormElement(),null===(t=this.containingForm)||void 0===t||t.addEventListener("formdata",this.formDataListener)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this.containingForm)||void 0===t||t.removeEventListener("formdata",this.formDataListener),this.containingForm=null}click(){this.formElement&&!this.disabled&&(this.formElement.focus(),this.formElement.click())}firstUpdated(){super.firstUpdated(),this.shadowRoot&&this.mdcRoot.addEventListener("change",(t=>{this.dispatchEvent(new Event("change",t))}))}}ke.shadowRootOptions={mode:"open",delegatesFocus:!0},n([ht({type:Boolean})],ke.prototype,"disabled",void 0);
/**
* @license
* Copyright 2018 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
-/**
- * Specifies an observer callback that is run when the decorated property
- * changes. The observer receives the current and old value as arguments.
- */
-const observer = (observer) =>
-// eslint-disable-next-line @typescript-eslint/no-explicit-any
-(proto, propName) => {
- // if we haven't wrapped `updated` in this class, do so
- if (!proto.constructor
- ._observers) {
- proto.constructor._observers = new Map();
- const userUpdated = proto.updated;
- proto.updated = function (changedProperties) {
- userUpdated.call(this, changedProperties);
- changedProperties.forEach((v, k) => {
- const observers = this.constructor
- ._observers;
- const observer = observers.get(k);
- if (observer !== undefined) {
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
- observer.call(this, this[k], v);
- }
- });
- };
- // clone any existing observers (superclasses)
- // eslint-disable-next-line no-prototype-builtins
- }
- else if (!proto.constructor.hasOwnProperty('_observers')) {
- const observers = proto.constructor._observers;
- proto.constructor._observers = new Map();
- observers.forEach(
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
- (v, k) => proto.constructor._observers.set(k, v));
- }
- // set this method
- proto.constructor._observers.set(propName, observer);
-};
-
-/**
- * @license
- * Copyright 2016 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-var MDCFoundation = /** @class */ (function () {
- function MDCFoundation(adapter) {
- if (adapter === void 0) { adapter = {}; }
- this.adapter = adapter;
- }
- Object.defineProperty(MDCFoundation, "cssClasses", {
- get: function () {
- // Classes extending MDCFoundation should implement this method to return an object which exports every
- // CSS class the foundation class needs as a property. e.g. {ACTIVE: 'mdc-component--active'}
- return {};
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCFoundation, "strings", {
- get: function () {
- // Classes extending MDCFoundation should implement this method to return an object which exports all
- // semantic strings as constants. e.g. {ARIA_ROLE: 'tablist'}
- return {};
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCFoundation, "numbers", {
- get: function () {
- // Classes extending MDCFoundation should implement this method to return an object which exports all
- // of its semantic numbers as constants. e.g. {ANIMATION_DELAY_MS: 350}
- return {};
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCFoundation, "defaultAdapter", {
- get: function () {
- // Classes extending MDCFoundation may choose to implement this getter in order to provide a convenient
- // way of viewing the necessary methods of an adapter. In the future, this could also be used for adapter
- // validation.
- return {};
- },
- enumerable: false,
- configurable: true
- });
- MDCFoundation.prototype.init = function () {
- // Subclasses should override this method to perform initialization routines (registering events, etc.)
- };
- MDCFoundation.prototype.destroy = function () {
- // Subclasses should override this method to perform de-initialization routines (de-registering events, etc.)
- };
- return MDCFoundation;
-}());
-
+const Te=t=>(e,i)=>{if(e.constructor._observers){if(!e.constructor.hasOwnProperty("_observers")){const t=e.constructor._observers;e.constructor._observers=new Map,t.forEach(((t,i)=>e.constructor._observers.set(i,t)))}}else{e.constructor._observers=new Map;const t=e.updated;e.updated=function(e){t.call(this,e),e.forEach(((t,e)=>{const i=this.constructor._observers.get(e);void 0!==i&&i.call(this,this[e],t)}))}}e.constructor._observers.set(i,t)}
/**
* @license
* Copyright 2016 Google Inc.
@@ -1314,14 +329,7 @@ var MDCFoundation = /** @class */ (function () {
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
- */
-var cssClasses$6 = {
- LABEL_FLOAT_ABOVE: 'mdc-floating-label--float-above',
- LABEL_REQUIRED: 'mdc-floating-label--required',
- LABEL_SHAKE: 'mdc-floating-label--shake',
- ROOT: 'mdc-floating-label',
-};
-
+ */;var Ie=function(){function t(t){void 0===t&&(t={}),this.adapter=t}return Object.defineProperty(t,"cssClasses",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(t,"strings",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(t,"numbers",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{}},enumerable:!1,configurable:!0}),t.prototype.init=function(){},t.prototype.destroy=function(){},t}(),Le={LABEL_FLOAT_ABOVE:"mdc-floating-label--float-above",LABEL_REQUIRED:"mdc-floating-label--required",LABEL_SHAKE:"mdc-floating-label--shake",ROOT:"mdc-floating-label"},Re=function(t){function n(e){var r=t.call(this,i(i({},n.defaultAdapter),e))||this;return r.shakeAnimationEndHandler=function(){r.handleShakeAnimationEnd()},r}return e(n,t),Object.defineProperty(n,"cssClasses",{get:function(){return Le},enumerable:!1,configurable:!0}),Object.defineProperty(n,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},getWidth:function(){return 0},registerInteractionHandler:function(){},deregisterInteractionHandler:function(){}}},enumerable:!1,configurable:!0}),n.prototype.init=function(){this.adapter.registerInteractionHandler("animationend",this.shakeAnimationEndHandler)},n.prototype.destroy=function(){this.adapter.deregisterInteractionHandler("animationend",this.shakeAnimationEndHandler)},n.prototype.getWidth=function(){return this.adapter.getWidth()},n.prototype.shake=function(t){var e=n.cssClasses.LABEL_SHAKE;t?this.adapter.addClass(e):this.adapter.removeClass(e)},n.prototype.float=function(t){var e=n.cssClasses,i=e.LABEL_FLOAT_ABOVE,r=e.LABEL_SHAKE;t?this.adapter.addClass(i):(this.adapter.removeClass(i),this.adapter.removeClass(r))},n.prototype.setRequired=function(t){var e=n.cssClasses.LABEL_REQUIRED;t?this.adapter.addClass(e):this.adapter.removeClass(e)},n.prototype.handleShakeAnimationEnd=function(){var t=n.cssClasses.LABEL_SHAKE;this.adapter.removeClass(t)},n}(Ie);
/**
* @license
* Copyright 2016 Google Inc.
@@ -1344,162 +352,17 @@ var cssClasses$6 = {
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
-var MDCFloatingLabelFoundation = /** @class */ (function (_super) {
- __extends(MDCFloatingLabelFoundation, _super);
- function MDCFloatingLabelFoundation(adapter) {
- var _this = _super.call(this, __assign(__assign({}, MDCFloatingLabelFoundation.defaultAdapter), adapter)) || this;
- _this.shakeAnimationEndHandler = function () {
- _this.handleShakeAnimationEnd();
- };
- return _this;
- }
- Object.defineProperty(MDCFloatingLabelFoundation, "cssClasses", {
- get: function () {
- return cssClasses$6;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCFloatingLabelFoundation, "defaultAdapter", {
- /**
- * See {@link MDCFloatingLabelAdapter} for typing information on parameters and return types.
- */
- get: function () {
- // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
- return {
- addClass: function () { return undefined; },
- removeClass: function () { return undefined; },
- getWidth: function () { return 0; },
- registerInteractionHandler: function () { return undefined; },
- deregisterInteractionHandler: function () { return undefined; },
- };
- // tslint:enable:object-literal-sort-keys
- },
- enumerable: false,
- configurable: true
- });
- MDCFloatingLabelFoundation.prototype.init = function () {
- this.adapter.registerInteractionHandler('animationend', this.shakeAnimationEndHandler);
- };
- MDCFloatingLabelFoundation.prototype.destroy = function () {
- this.adapter.deregisterInteractionHandler('animationend', this.shakeAnimationEndHandler);
- };
- /**
- * Returns the width of the label element.
- */
- MDCFloatingLabelFoundation.prototype.getWidth = function () {
- return this.adapter.getWidth();
- };
- /**
- * Styles the label to produce a shake animation to indicate an error.
- * @param shouldShake If true, adds the shake CSS class; otherwise, removes shake class.
- */
- MDCFloatingLabelFoundation.prototype.shake = function (shouldShake) {
- var LABEL_SHAKE = MDCFloatingLabelFoundation.cssClasses.LABEL_SHAKE;
- if (shouldShake) {
- this.adapter.addClass(LABEL_SHAKE);
- }
- else {
- this.adapter.removeClass(LABEL_SHAKE);
- }
- };
- /**
- * Styles the label to float or dock.
- * @param shouldFloat If true, adds the float CSS class; otherwise, removes float and shake classes to dock the label.
- */
- MDCFloatingLabelFoundation.prototype.float = function (shouldFloat) {
- var _a = MDCFloatingLabelFoundation.cssClasses, LABEL_FLOAT_ABOVE = _a.LABEL_FLOAT_ABOVE, LABEL_SHAKE = _a.LABEL_SHAKE;
- if (shouldFloat) {
- this.adapter.addClass(LABEL_FLOAT_ABOVE);
- }
- else {
- this.adapter.removeClass(LABEL_FLOAT_ABOVE);
- this.adapter.removeClass(LABEL_SHAKE);
- }
- };
- /**
- * Styles the label as required.
- * @param isRequired If true, adds an asterisk to the label, indicating that it is required.
- */
- MDCFloatingLabelFoundation.prototype.setRequired = function (isRequired) {
- var LABEL_REQUIRED = MDCFloatingLabelFoundation.cssClasses.LABEL_REQUIRED;
- if (isRequired) {
- this.adapter.addClass(LABEL_REQUIRED);
- }
- else {
- this.adapter.removeClass(LABEL_REQUIRED);
- }
- };
- MDCFloatingLabelFoundation.prototype.handleShakeAnimationEnd = function () {
- var LABEL_SHAKE = MDCFloatingLabelFoundation.cssClasses.LABEL_SHAKE;
- this.adapter.removeClass(LABEL_SHAKE);
- };
- return MDCFloatingLabelFoundation;
-}(MDCFoundation));
-
/**
* @license
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
*/
-const t={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},e$1=t=>(...e)=>({_$litDirective$:t,values:e});let i$1 = class i{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,i){this._$Ct=t,this._$AM=e,this._$Ci=i;}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};
-
+const Oe=1,$e=3,ze=4,Pe=t=>(...e)=>({_$litDirective$:t,values:e});let Ve=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,i){this._$Ct=t,this._$AM=e,this._$Ci=i}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};
/**
* @license
* Copyright 2018 Google LLC
* SPDX-License-Identifier: Apache-2.0
- */
-const createAdapter$1 = (labelElement) => {
- return {
- addClass: (className) => labelElement.classList.add(className),
- removeClass: (className) => labelElement.classList.remove(className),
- getWidth: () => labelElement.scrollWidth,
- registerInteractionHandler: (evtType, handler) => {
- labelElement.addEventListener(evtType, handler);
- },
- deregisterInteractionHandler: (evtType, handler) => {
- labelElement.removeEventListener(evtType, handler);
- },
- };
-};
-class FloatingLabelDirective extends i$1 {
- constructor(partInfo) {
- super(partInfo);
- this.foundation = null;
- this.previousPart = null;
- switch (partInfo.type) {
- // Only allow Attribute and Part bindings
- case t.ATTRIBUTE:
- case t.PROPERTY:
- break;
- default:
- throw new Error('FloatingLabel directive only support attribute and property parts');
- }
- }
- /**
- * There is no PropertyPart in Lit 2 so far. For more info see:
- * https://github.com/lit/lit/issues/1863
- */
- update(part, [label]) {
- if (part !== this.previousPart) {
- if (this.foundation) {
- this.foundation.destroy();
- }
- this.previousPart = part;
- const labelElement = part.element;
- labelElement.classList.add('mdc-floating-label');
- const adapter = createAdapter$1(labelElement);
- this.foundation = new MDCFloatingLabelFoundation(adapter);
- this.foundation.init();
- }
- return this.render(label);
- }
- render(_label) {
- return this.foundation;
- }
-}
-const floatingLabel = e$1(FloatingLabelDirective);
-
+ */const Me=Pe(class extends Ve{constructor(t){switch(super(t),this.foundation=null,this.previousPart=null,t.type){case Oe:case $e:break;default:throw new Error("FloatingLabel directive only support attribute and property parts")}}update(t,[e]){if(t!==this.previousPart){this.foundation&&this.foundation.destroy(),this.previousPart=t;const e=t.element;e.classList.add("mdc-floating-label");const i=(t=>({addClass:e=>t.classList.add(e),removeClass:e=>t.classList.remove(e),getWidth:()=>t.scrollWidth,registerInteractionHandler:(e,i)=>{t.addEventListener(e,i)},deregisterInteractionHandler:(e,i)=>{t.removeEventListener(e,i)}}))(e);this.foundation=new Re(i),this.foundation.init()}return this.render(e)}render(t){return this.foundation}});
/**
* @license
* Copyright 2018 Google Inc.
@@ -1521,12 +384,7 @@ const floatingLabel = e$1(FloatingLabelDirective);
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
- */
-var cssClasses$5 = {
- LINE_RIPPLE_ACTIVE: 'mdc-line-ripple--active',
- LINE_RIPPLE_DEACTIVATING: 'mdc-line-ripple--deactivating',
-};
-
+ */var Fe={LINE_RIPPLE_ACTIVE:"mdc-line-ripple--active",LINE_RIPPLE_DEACTIVATING:"mdc-line-ripple--deactivating"},Ne=function(t){function n(e){var r=t.call(this,i(i({},n.defaultAdapter),e))||this;return r.transitionEndHandler=function(t){r.handleTransitionEnd(t)},r}return e(n,t),Object.defineProperty(n,"cssClasses",{get:function(){return Fe},enumerable:!1,configurable:!0}),Object.defineProperty(n,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!1},setStyle:function(){},registerEventHandler:function(){},deregisterEventHandler:function(){}}},enumerable:!1,configurable:!0}),n.prototype.init=function(){this.adapter.registerEventHandler("transitionend",this.transitionEndHandler)},n.prototype.destroy=function(){this.adapter.deregisterEventHandler("transitionend",this.transitionEndHandler)},n.prototype.activate=function(){this.adapter.removeClass(Fe.LINE_RIPPLE_DEACTIVATING),this.adapter.addClass(Fe.LINE_RIPPLE_ACTIVE)},n.prototype.setRippleCenter=function(t){this.adapter.setStyle("transform-origin",t+"px center")},n.prototype.deactivate=function(){this.adapter.addClass(Fe.LINE_RIPPLE_DEACTIVATING)},n.prototype.handleTransitionEnd=function(t){var e=this.adapter.hasClass(Fe.LINE_RIPPLE_DEACTIVATING);"opacity"===t.propertyName&&e&&(this.adapter.removeClass(Fe.LINE_RIPPLE_ACTIVE),this.adapter.removeClass(Fe.LINE_RIPPLE_DEACTIVATING))},n}(Ie);
/**
* @license
* Copyright 2018 Google Inc.
@@ -1548,128 +406,7 @@ var cssClasses$5 = {
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
- */
-var MDCLineRippleFoundation = /** @class */ (function (_super) {
- __extends(MDCLineRippleFoundation, _super);
- function MDCLineRippleFoundation(adapter) {
- var _this = _super.call(this, __assign(__assign({}, MDCLineRippleFoundation.defaultAdapter), adapter)) || this;
- _this.transitionEndHandler = function (evt) {
- _this.handleTransitionEnd(evt);
- };
- return _this;
- }
- Object.defineProperty(MDCLineRippleFoundation, "cssClasses", {
- get: function () {
- return cssClasses$5;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCLineRippleFoundation, "defaultAdapter", {
- /**
- * See {@link MDCLineRippleAdapter} for typing information on parameters and return types.
- */
- get: function () {
- // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
- return {
- addClass: function () { return undefined; },
- removeClass: function () { return undefined; },
- hasClass: function () { return false; },
- setStyle: function () { return undefined; },
- registerEventHandler: function () { return undefined; },
- deregisterEventHandler: function () { return undefined; },
- };
- // tslint:enable:object-literal-sort-keys
- },
- enumerable: false,
- configurable: true
- });
- MDCLineRippleFoundation.prototype.init = function () {
- this.adapter.registerEventHandler('transitionend', this.transitionEndHandler);
- };
- MDCLineRippleFoundation.prototype.destroy = function () {
- this.adapter.deregisterEventHandler('transitionend', this.transitionEndHandler);
- };
- MDCLineRippleFoundation.prototype.activate = function () {
- this.adapter.removeClass(cssClasses$5.LINE_RIPPLE_DEACTIVATING);
- this.adapter.addClass(cssClasses$5.LINE_RIPPLE_ACTIVE);
- };
- MDCLineRippleFoundation.prototype.setRippleCenter = function (xCoordinate) {
- this.adapter.setStyle('transform-origin', xCoordinate + "px center");
- };
- MDCLineRippleFoundation.prototype.deactivate = function () {
- this.adapter.addClass(cssClasses$5.LINE_RIPPLE_DEACTIVATING);
- };
- MDCLineRippleFoundation.prototype.handleTransitionEnd = function (evt) {
- // Wait for the line ripple to be either transparent or opaque
- // before emitting the animation end event
- var isDeactivating = this.adapter.hasClass(cssClasses$5.LINE_RIPPLE_DEACTIVATING);
- if (evt.propertyName === 'opacity') {
- if (isDeactivating) {
- this.adapter.removeClass(cssClasses$5.LINE_RIPPLE_ACTIVE);
- this.adapter.removeClass(cssClasses$5.LINE_RIPPLE_DEACTIVATING);
- }
- }
- };
- return MDCLineRippleFoundation;
-}(MDCFoundation));
-
-/**
- * @license
- * Copyright 2019 Google LLC
- * SPDX-License-Identifier: Apache-2.0
- */
-const createAdapter = (lineElement) => {
- return {
- addClass: (className) => lineElement.classList.add(className),
- removeClass: (className) => lineElement.classList.remove(className),
- hasClass: (className) => lineElement.classList.contains(className),
- setStyle: (propertyName, value) => lineElement.style.setProperty(propertyName, value),
- registerEventHandler: (evtType, handler) => {
- lineElement.addEventListener(evtType, handler);
- },
- deregisterEventHandler: (evtType, handler) => {
- lineElement.removeEventListener(evtType, handler);
- },
- };
-};
-class LineRippleDirective extends i$1 {
- constructor(partInfo) {
- super(partInfo);
- this.previousPart = null;
- this.foundation = null;
- switch (partInfo.type) {
- case t.ATTRIBUTE:
- case t.PROPERTY:
- return;
- default:
- throw new Error('LineRipple only support attribute and property parts.');
- }
- }
- /**
- * There is no PropertyPart in Lit 2 so far. For more info see:
- * https://github.com/lit/lit/issues/1863
- */
- update(part, _params) {
- if (this.previousPart !== part) {
- if (this.foundation) {
- this.foundation.destroy();
- }
- this.previousPart = part;
- const lineElement = part.element;
- lineElement.classList.add('mdc-line-ripple');
- const adapter = createAdapter(lineElement);
- this.foundation = new MDCLineRippleFoundation(adapter);
- this.foundation.init();
- }
- return this.render();
- }
- render() {
- return this.foundation;
- }
-}
-const lineRipple = e$1(LineRippleDirective);
-
+ */const He=Pe(class extends Ve{constructor(t){switch(super(t),this.previousPart=null,this.foundation=null,t.type){case Oe:case $e:return;default:throw new Error("LineRipple only support attribute and property parts.")}}update(t,e){if(this.previousPart!==t){this.foundation&&this.foundation.destroy(),this.previousPart=t;const e=t.element;e.classList.add("mdc-line-ripple");const i=(t=>({addClass:e=>t.classList.add(e),removeClass:e=>t.classList.remove(e),hasClass:e=>t.classList.contains(e),setStyle:(e,i)=>t.style.setProperty(e,i),registerEventHandler:(e,i)=>{t.addEventListener(e,i)},deregisterEventHandler:(e,i)=>{t.removeEventListener(e,i)}}))(e);this.foundation=new Ne(i),this.foundation.init()}return this.render()}render(){return this.foundation}});
/**
* @license
* Copyright 2018 Google Inc.
@@ -1691,36 +428,7 @@ const lineRipple = e$1(LineRippleDirective);
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
- */
-/**
- * Enum for bits in the {@see Corner) bitmap.
- */
-var CornerBit;
-(function (CornerBit) {
- CornerBit[CornerBit["BOTTOM"] = 1] = "BOTTOM";
- CornerBit[CornerBit["CENTER"] = 2] = "CENTER";
- CornerBit[CornerBit["RIGHT"] = 4] = "RIGHT";
- CornerBit[CornerBit["FLIP_RTL"] = 8] = "FLIP_RTL";
-})(CornerBit || (CornerBit = {}));
-/**
- * Enum for representing an element corner for positioning the menu-surface.
- *
- * The START constants map to LEFT if element directionality is left
- * to right and RIGHT if the directionality is right to left.
- * Likewise END maps to RIGHT or LEFT depending on the directionality.
- */
-var Corner;
-(function (Corner) {
- Corner[Corner["TOP_LEFT"] = 0] = "TOP_LEFT";
- Corner[Corner["TOP_RIGHT"] = 4] = "TOP_RIGHT";
- Corner[Corner["BOTTOM_LEFT"] = 1] = "BOTTOM_LEFT";
- Corner[Corner["BOTTOM_RIGHT"] = 5] = "BOTTOM_RIGHT";
- Corner[Corner["TOP_START"] = 8] = "TOP_START";
- Corner[Corner["TOP_END"] = 12] = "TOP_END";
- Corner[Corner["BOTTOM_START"] = 9] = "BOTTOM_START";
- Corner[Corner["BOTTOM_END"] = 13] = "BOTTOM_END";
-})(Corner || (Corner = {}));
-
+ */var De,Be;!function(t){t[t.BOTTOM=1]="BOTTOM",t[t.CENTER=2]="CENTER",t[t.RIGHT=4]="RIGHT",t[t.FLIP_RTL=8]="FLIP_RTL"}(De||(De={})),function(t){t[t.TOP_LEFT=0]="TOP_LEFT",t[t.TOP_RIGHT=4]="TOP_RIGHT",t[t.BOTTOM_LEFT=1]="BOTTOM_LEFT",t[t.BOTTOM_RIGHT=5]="BOTTOM_RIGHT",t[t.TOP_START=8]="TOP_START",t[t.TOP_END=12]="TOP_END",t[t.BOTTOM_START=9]="BOTTOM_START",t[t.BOTTOM_END=13]="BOTTOM_END"}(Be||(Be={}));
/**
* @license
* Copyright 2016 Google Inc.
@@ -1743,606 +451,25 @@ var Corner;
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
-var cssClasses$4 = {
- ACTIVATED: 'mdc-select--activated',
- DISABLED: 'mdc-select--disabled',
- FOCUSED: 'mdc-select--focused',
- INVALID: 'mdc-select--invalid',
- MENU_INVALID: 'mdc-select__menu--invalid',
- OUTLINED: 'mdc-select--outlined',
- REQUIRED: 'mdc-select--required',
- ROOT: 'mdc-select',
- WITH_LEADING_ICON: 'mdc-select--with-leading-icon',
-};
-var strings$5 = {
- ARIA_CONTROLS: 'aria-controls',
- ARIA_DESCRIBEDBY: 'aria-describedby',
- ARIA_SELECTED_ATTR: 'aria-selected',
- CHANGE_EVENT: 'MDCSelect:change',
- HIDDEN_INPUT_SELECTOR: 'input[type="hidden"]',
- LABEL_SELECTOR: '.mdc-floating-label',
- LEADING_ICON_SELECTOR: '.mdc-select__icon',
- LINE_RIPPLE_SELECTOR: '.mdc-line-ripple',
- MENU_SELECTOR: '.mdc-select__menu',
- OUTLINE_SELECTOR: '.mdc-notched-outline',
- SELECTED_TEXT_SELECTOR: '.mdc-select__selected-text',
- SELECT_ANCHOR_SELECTOR: '.mdc-select__anchor',
- VALUE_ATTR: 'data-value',
-};
-var numbers$2 = {
- LABEL_SCALE: 0.75,
- UNSET_INDEX: -1,
- CLICK_DEBOUNCE_TIMEOUT_MS: 330,
-};
-
+var Ue={ACTIVATED:"mdc-select--activated",DISABLED:"mdc-select--disabled",FOCUSED:"mdc-select--focused",INVALID:"mdc-select--invalid",MENU_INVALID:"mdc-select__menu--invalid",OUTLINED:"mdc-select--outlined",REQUIRED:"mdc-select--required",ROOT:"mdc-select",WITH_LEADING_ICON:"mdc-select--with-leading-icon"},Ye={ARIA_CONTROLS:"aria-controls",ARIA_DESCRIBEDBY:"aria-describedby",ARIA_SELECTED_ATTR:"aria-selected",CHANGE_EVENT:"MDCSelect:change",HIDDEN_INPUT_SELECTOR:'input[type="hidden"]',LABEL_SELECTOR:".mdc-floating-label",LEADING_ICON_SELECTOR:".mdc-select__icon",LINE_RIPPLE_SELECTOR:".mdc-line-ripple",MENU_SELECTOR:".mdc-select__menu",OUTLINE_SELECTOR:".mdc-notched-outline",SELECTED_TEXT_SELECTOR:".mdc-select__selected-text",SELECT_ANCHOR_SELECTOR:".mdc-select__anchor",VALUE_ATTR:"data-value"},We={LABEL_SCALE:.75,UNSET_INDEX:-1,CLICK_DEBOUNCE_TIMEOUT_MS:330},je=function(t){function n(e,r){void 0===r&&(r={});var a=t.call(this,i(i({},n.defaultAdapter),e))||this;return a.disabled=!1,a.isMenuOpen=!1,a.useDefaultValidation=!0,a.customValidity=!0,a.lastSelectedIndex=We.UNSET_INDEX,a.clickDebounceTimeout=0,a.recentlyClicked=!1,a.leadingIcon=r.leadingIcon,a.helperText=r.helperText,a}return e(n,t),Object.defineProperty(n,"cssClasses",{get:function(){return Ue},enumerable:!1,configurable:!0}),Object.defineProperty(n,"numbers",{get:function(){return We},enumerable:!1,configurable:!0}),Object.defineProperty(n,"strings",{get:function(){return Ye},enumerable:!1,configurable:!0}),Object.defineProperty(n,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!1},activateBottomLine:function(){},deactivateBottomLine:function(){},getSelectedIndex:function(){return-1},setSelectedIndex:function(){},hasLabel:function(){return!1},floatLabel:function(){},getLabelWidth:function(){return 0},setLabelRequired:function(){},hasOutline:function(){return!1},notchOutline:function(){},closeOutline:function(){},setRippleCenter:function(){},notifyChange:function(){},setSelectedText:function(){},isSelectAnchorFocused:function(){return!1},getSelectAnchorAttr:function(){return""},setSelectAnchorAttr:function(){},removeSelectAnchorAttr:function(){},addMenuClass:function(){},removeMenuClass:function(){},openMenu:function(){},closeMenu:function(){},getAnchorElement:function(){return null},setMenuAnchorElement:function(){},setMenuAnchorCorner:function(){},setMenuWrapFocus:function(){},focusMenuItemAtIndex:function(){},getMenuItemCount:function(){return 0},getMenuItemValues:function(){return[]},getMenuItemTextAtIndex:function(){return""},isTypeaheadInProgress:function(){return!1},typeaheadMatchItem:function(){return-1}}},enumerable:!1,configurable:!0}),n.prototype.getSelectedIndex=function(){return this.adapter.getSelectedIndex()},n.prototype.setSelectedIndex=function(t,e,i){void 0===e&&(e=!1),void 0===i&&(i=!1),t>=this.adapter.getMenuItemCount()||(t===We.UNSET_INDEX?this.adapter.setSelectedText(""):this.adapter.setSelectedText(this.adapter.getMenuItemTextAtIndex(t).trim()),this.adapter.setSelectedIndex(t),e&&this.adapter.closeMenu(),i||this.lastSelectedIndex===t||this.handleChange(),this.lastSelectedIndex=t)},n.prototype.setValue=function(t,e){void 0===e&&(e=!1);var i=this.adapter.getMenuItemValues().indexOf(t);this.setSelectedIndex(i,!1,e)},n.prototype.getValue=function(){var t=this.adapter.getSelectedIndex(),e=this.adapter.getMenuItemValues();return t!==We.UNSET_INDEX?e[t]:""},n.prototype.getDisabled=function(){return this.disabled},n.prototype.setDisabled=function(t){this.disabled=t,this.disabled?(this.adapter.addClass(Ue.DISABLED),this.adapter.closeMenu()):this.adapter.removeClass(Ue.DISABLED),this.leadingIcon&&this.leadingIcon.setDisabled(this.disabled),this.disabled?this.adapter.removeSelectAnchorAttr("tabindex"):this.adapter.setSelectAnchorAttr("tabindex","0"),this.adapter.setSelectAnchorAttr("aria-disabled",this.disabled.toString())},n.prototype.openMenu=function(){this.adapter.addClass(Ue.ACTIVATED),this.adapter.openMenu(),this.isMenuOpen=!0,this.adapter.setSelectAnchorAttr("aria-expanded","true")},n.prototype.setHelperTextContent=function(t){this.helperText&&this.helperText.setContent(t)},n.prototype.layout=function(){if(this.adapter.hasLabel()){var t=this.getValue().length>0,e=this.adapter.hasClass(Ue.FOCUSED),i=t||e,n=this.adapter.hasClass(Ue.REQUIRED);this.notchOutline(i),this.adapter.floatLabel(i),this.adapter.setLabelRequired(n)}},n.prototype.layoutOptions=function(){var t=this.adapter.getMenuItemValues().indexOf(this.getValue());this.setSelectedIndex(t,!1,!0)},n.prototype.handleMenuOpened=function(){if(0!==this.adapter.getMenuItemValues().length){var t=this.getSelectedIndex(),e=t>=0?t:0;this.adapter.focusMenuItemAtIndex(e)}},n.prototype.handleMenuClosing=function(){this.adapter.setSelectAnchorAttr("aria-expanded","false")},n.prototype.handleMenuClosed=function(){this.adapter.removeClass(Ue.ACTIVATED),this.isMenuOpen=!1,this.adapter.isSelectAnchorFocused()||this.blur()},n.prototype.handleChange=function(){this.layout(),this.adapter.notifyChange(this.getValue()),this.adapter.hasClass(Ue.REQUIRED)&&this.useDefaultValidation&&this.setValid(this.isValid())},n.prototype.handleMenuItemAction=function(t){this.setSelectedIndex(t,!0)},n.prototype.handleFocus=function(){this.adapter.addClass(Ue.FOCUSED),this.layout(),this.adapter.activateBottomLine()},n.prototype.handleBlur=function(){this.isMenuOpen||this.blur()},n.prototype.handleClick=function(t){this.disabled||this.recentlyClicked||(this.setClickDebounceTimeout(),this.isMenuOpen?this.adapter.closeMenu():(this.adapter.setRippleCenter(t),this.openMenu()))},n.prototype.handleKeydown=function(t){if(!this.isMenuOpen&&this.adapter.hasClass(Ue.FOCUSED)){var e=ae(t)===Nt.ENTER,i=ae(t)===Nt.SPACEBAR,n=ae(t)===Nt.ARROW_UP,r=ae(t)===Nt.ARROW_DOWN;if(!(t.ctrlKey||t.metaKey)&&(!i&&t.key&&1===t.key.length||i&&this.adapter.isTypeaheadInProgress())){var a=i?" ":t.key,l=this.adapter.typeaheadMatchItem(a,this.getSelectedIndex());return l>=0&&this.setSelectedIndex(l),void t.preventDefault()}(e||i||n||r)&&(this.openMenu(),t.preventDefault())}},n.prototype.notchOutline=function(t){if(this.adapter.hasOutline()){var e=this.adapter.hasClass(Ue.FOCUSED);if(t){var i=We.LABEL_SCALE,n=this.adapter.getLabelWidth()*i;this.adapter.notchOutline(n)}else e||this.adapter.closeOutline()}},n.prototype.setLeadingIconAriaLabel=function(t){this.leadingIcon&&this.leadingIcon.setAriaLabel(t)},n.prototype.setLeadingIconContent=function(t){this.leadingIcon&&this.leadingIcon.setContent(t)},n.prototype.getUseDefaultValidation=function(){return this.useDefaultValidation},n.prototype.setUseDefaultValidation=function(t){this.useDefaultValidation=t},n.prototype.setValid=function(t){this.useDefaultValidation||(this.customValidity=t),this.adapter.setSelectAnchorAttr("aria-invalid",(!t).toString()),t?(this.adapter.removeClass(Ue.INVALID),this.adapter.removeMenuClass(Ue.MENU_INVALID)):(this.adapter.addClass(Ue.INVALID),this.adapter.addMenuClass(Ue.MENU_INVALID)),this.syncHelperTextValidity(t)},n.prototype.isValid=function(){return this.useDefaultValidation&&this.adapter.hasClass(Ue.REQUIRED)&&!this.adapter.hasClass(Ue.DISABLED)?this.getSelectedIndex()!==We.UNSET_INDEX&&(0!==this.getSelectedIndex()||Boolean(this.getValue())):this.customValidity},n.prototype.setRequired=function(t){t?this.adapter.addClass(Ue.REQUIRED):this.adapter.removeClass(Ue.REQUIRED),this.adapter.setSelectAnchorAttr("aria-required",t.toString()),this.adapter.setLabelRequired(t)},n.prototype.getRequired=function(){return"true"===this.adapter.getSelectAnchorAttr("aria-required")},n.prototype.init=function(){var t=this.adapter.getAnchorElement();t&&(this.adapter.setMenuAnchorElement(t),this.adapter.setMenuAnchorCorner(Be.BOTTOM_START)),this.adapter.setMenuWrapFocus(!1),this.setDisabled(this.adapter.hasClass(Ue.DISABLED)),this.syncHelperTextValidity(!this.adapter.hasClass(Ue.INVALID)),this.layout(),this.layoutOptions()},n.prototype.blur=function(){this.adapter.removeClass(Ue.FOCUSED),this.layout(),this.adapter.deactivateBottomLine(),this.adapter.hasClass(Ue.REQUIRED)&&this.useDefaultValidation&&this.setValid(this.isValid())},n.prototype.syncHelperTextValidity=function(t){if(this.helperText){this.helperText.setValidity(t);var e=this.helperText.isVisible(),i=this.helperText.getId();e&&i?this.adapter.setSelectAnchorAttr(Ye.ARIA_DESCRIBEDBY,i):this.adapter.removeSelectAnchorAttr(Ye.ARIA_DESCRIBEDBY)}},n.prototype.setClickDebounceTimeout=function(){var t=this;clearTimeout(this.clickDebounceTimeout),this.clickDebounceTimeout=setTimeout((function(){t.recentlyClicked=!1}),We.CLICK_DEBOUNCE_TIMEOUT_MS),this.recentlyClicked=!0},n}(Ie);
/**
* @license
- * Copyright 2016 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
+ * Copyright 2018 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
*/
-var MDCSelectFoundation = /** @class */ (function (_super) {
- __extends(MDCSelectFoundation, _super);
- /* istanbul ignore next: optional argument is not a branch statement */
- /**
- * @param adapter
- * @param foundationMap Map from subcomponent names to their subfoundations.
- */
- function MDCSelectFoundation(adapter, foundationMap) {
- if (foundationMap === void 0) { foundationMap = {}; }
- var _this = _super.call(this, __assign(__assign({}, MDCSelectFoundation.defaultAdapter), adapter)) || this;
- // Disabled state
- _this.disabled = false;
- // isMenuOpen is used to track the state of the menu by listening to the
- // MDCMenuSurface:closed event For reference, menu.open will return false if
- // the menu is still closing, but isMenuOpen returns false only after the menu
- // has closed
- _this.isMenuOpen = false;
- // By default, select is invalid if it is required but no value is selected.
- _this.useDefaultValidation = true;
- _this.customValidity = true;
- _this.lastSelectedIndex = numbers$2.UNSET_INDEX;
- _this.clickDebounceTimeout = 0;
- _this.recentlyClicked = false;
- _this.leadingIcon = foundationMap.leadingIcon;
- _this.helperText = foundationMap.helperText;
- return _this;
- }
- Object.defineProperty(MDCSelectFoundation, "cssClasses", {
- get: function () {
- return cssClasses$4;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCSelectFoundation, "numbers", {
- get: function () {
- return numbers$2;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCSelectFoundation, "strings", {
- get: function () {
- return strings$5;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCSelectFoundation, "defaultAdapter", {
- /**
- * See {@link MDCSelectAdapter} for typing information on parameters and return types.
- */
- get: function () {
- // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
- return {
- addClass: function () { return undefined; },
- removeClass: function () { return undefined; },
- hasClass: function () { return false; },
- activateBottomLine: function () { return undefined; },
- deactivateBottomLine: function () { return undefined; },
- getSelectedIndex: function () { return -1; },
- setSelectedIndex: function () { return undefined; },
- hasLabel: function () { return false; },
- floatLabel: function () { return undefined; },
- getLabelWidth: function () { return 0; },
- setLabelRequired: function () { return undefined; },
- hasOutline: function () { return false; },
- notchOutline: function () { return undefined; },
- closeOutline: function () { return undefined; },
- setRippleCenter: function () { return undefined; },
- notifyChange: function () { return undefined; },
- setSelectedText: function () { return undefined; },
- isSelectAnchorFocused: function () { return false; },
- getSelectAnchorAttr: function () { return ''; },
- setSelectAnchorAttr: function () { return undefined; },
- removeSelectAnchorAttr: function () { return undefined; },
- addMenuClass: function () { return undefined; },
- removeMenuClass: function () { return undefined; },
- openMenu: function () { return undefined; },
- closeMenu: function () { return undefined; },
- getAnchorElement: function () { return null; },
- setMenuAnchorElement: function () { return undefined; },
- setMenuAnchorCorner: function () { return undefined; },
- setMenuWrapFocus: function () { return undefined; },
- focusMenuItemAtIndex: function () { return undefined; },
- getMenuItemCount: function () { return 0; },
- getMenuItemValues: function () { return []; },
- getMenuItemTextAtIndex: function () { return ''; },
- isTypeaheadInProgress: function () { return false; },
- typeaheadMatchItem: function () { return -1; },
- };
- // tslint:enable:object-literal-sort-keys
- },
- enumerable: false,
- configurable: true
- });
- /** Returns the index of the currently selected menu item, or -1 if none. */
- MDCSelectFoundation.prototype.getSelectedIndex = function () {
- return this.adapter.getSelectedIndex();
- };
- MDCSelectFoundation.prototype.setSelectedIndex = function (index, closeMenu, skipNotify) {
- if (closeMenu === void 0) { closeMenu = false; }
- if (skipNotify === void 0) { skipNotify = false; }
- if (index >= this.adapter.getMenuItemCount()) {
- return;
- }
- if (index === numbers$2.UNSET_INDEX) {
- this.adapter.setSelectedText('');
- }
- else {
- this.adapter.setSelectedText(this.adapter.getMenuItemTextAtIndex(index).trim());
- }
- this.adapter.setSelectedIndex(index);
- if (closeMenu) {
- this.adapter.closeMenu();
- }
- if (!skipNotify && this.lastSelectedIndex !== index) {
- this.handleChange();
- }
- this.lastSelectedIndex = index;
- };
- MDCSelectFoundation.prototype.setValue = function (value, skipNotify) {
- if (skipNotify === void 0) { skipNotify = false; }
- var index = this.adapter.getMenuItemValues().indexOf(value);
- this.setSelectedIndex(index, /** closeMenu */ false, skipNotify);
- };
- MDCSelectFoundation.prototype.getValue = function () {
- var index = this.adapter.getSelectedIndex();
- var menuItemValues = this.adapter.getMenuItemValues();
- return index !== numbers$2.UNSET_INDEX ? menuItemValues[index] : '';
- };
- MDCSelectFoundation.prototype.getDisabled = function () {
- return this.disabled;
- };
- MDCSelectFoundation.prototype.setDisabled = function (isDisabled) {
- this.disabled = isDisabled;
- if (this.disabled) {
- this.adapter.addClass(cssClasses$4.DISABLED);
- this.adapter.closeMenu();
- }
- else {
- this.adapter.removeClass(cssClasses$4.DISABLED);
- }
- if (this.leadingIcon) {
- this.leadingIcon.setDisabled(this.disabled);
- }
- if (this.disabled) {
- // Prevent click events from focusing select. Simply pointer-events: none
- // is not enough since screenreader clicks may bypass this.
- this.adapter.removeSelectAnchorAttr('tabindex');
- }
- else {
- this.adapter.setSelectAnchorAttr('tabindex', '0');
- }
- this.adapter.setSelectAnchorAttr('aria-disabled', this.disabled.toString());
- };
- /** Opens the menu. */
- MDCSelectFoundation.prototype.openMenu = function () {
- this.adapter.addClass(cssClasses$4.ACTIVATED);
- this.adapter.openMenu();
- this.isMenuOpen = true;
- this.adapter.setSelectAnchorAttr('aria-expanded', 'true');
- };
- /**
- * @param content Sets the content of the helper text.
- */
- MDCSelectFoundation.prototype.setHelperTextContent = function (content) {
- if (this.helperText) {
- this.helperText.setContent(content);
- }
- };
- /**
- * Re-calculates if the notched outline should be notched and if the label
- * should float.
- */
- MDCSelectFoundation.prototype.layout = function () {
- if (this.adapter.hasLabel()) {
- var optionHasValue = this.getValue().length > 0;
- var isFocused = this.adapter.hasClass(cssClasses$4.FOCUSED);
- var shouldFloatAndNotch = optionHasValue || isFocused;
- var isRequired = this.adapter.hasClass(cssClasses$4.REQUIRED);
- this.notchOutline(shouldFloatAndNotch);
- this.adapter.floatLabel(shouldFloatAndNotch);
- this.adapter.setLabelRequired(isRequired);
- }
- };
- /**
- * Synchronizes the list of options with the state of the foundation. Call
- * this whenever menu options are dynamically updated.
- */
- MDCSelectFoundation.prototype.layoutOptions = function () {
- var menuItemValues = this.adapter.getMenuItemValues();
- var selectedIndex = menuItemValues.indexOf(this.getValue());
- this.setSelectedIndex(selectedIndex, /** closeMenu */ false, /** skipNotify */ true);
- };
- MDCSelectFoundation.prototype.handleMenuOpened = function () {
- if (this.adapter.getMenuItemValues().length === 0) {
- return;
- }
- // Menu should open to the last selected element, should open to first menu item otherwise.
- var selectedIndex = this.getSelectedIndex();
- var focusItemIndex = selectedIndex >= 0 ? selectedIndex : 0;
- this.adapter.focusMenuItemAtIndex(focusItemIndex);
- };
- MDCSelectFoundation.prototype.handleMenuClosing = function () {
- this.adapter.setSelectAnchorAttr('aria-expanded', 'false');
- };
- MDCSelectFoundation.prototype.handleMenuClosed = function () {
- this.adapter.removeClass(cssClasses$4.ACTIVATED);
- this.isMenuOpen = false;
- // Unfocus the select if menu is closed without a selection
- if (!this.adapter.isSelectAnchorFocused()) {
- this.blur();
- }
- };
- /**
- * Handles value changes, via change event or programmatic updates.
- */
- MDCSelectFoundation.prototype.handleChange = function () {
- this.layout();
- this.adapter.notifyChange(this.getValue());
- var isRequired = this.adapter.hasClass(cssClasses$4.REQUIRED);
- if (isRequired && this.useDefaultValidation) {
- this.setValid(this.isValid());
- }
- };
- MDCSelectFoundation.prototype.handleMenuItemAction = function (index) {
- this.setSelectedIndex(index, /** closeMenu */ true);
- };
- /**
- * Handles focus events from select element.
- */
- MDCSelectFoundation.prototype.handleFocus = function () {
- this.adapter.addClass(cssClasses$4.FOCUSED);
- this.layout();
- this.adapter.activateBottomLine();
- };
- /**
- * Handles blur events from select element.
- */
- MDCSelectFoundation.prototype.handleBlur = function () {
- if (this.isMenuOpen) {
- return;
- }
- this.blur();
- };
- MDCSelectFoundation.prototype.handleClick = function (normalizedX) {
- if (this.disabled || this.recentlyClicked) {
- return;
- }
- this.setClickDebounceTimeout();
- if (this.isMenuOpen) {
- this.adapter.closeMenu();
- return;
- }
- this.adapter.setRippleCenter(normalizedX);
- this.openMenu();
- };
- /**
- * Handles keydown events on select element. Depending on the type of
- * character typed, does typeahead matching or opens menu.
- */
- MDCSelectFoundation.prototype.handleKeydown = function (event) {
- if (this.isMenuOpen || !this.adapter.hasClass(cssClasses$4.FOCUSED)) {
- return;
- }
- var isEnter = normalizeKey(event) === KEY.ENTER;
- var isSpace = normalizeKey(event) === KEY.SPACEBAR;
- var arrowUp = normalizeKey(event) === KEY.ARROW_UP;
- var arrowDown = normalizeKey(event) === KEY.ARROW_DOWN;
- var isModifier = event.ctrlKey || event.metaKey;
- // Typeahead
- if (!isModifier &&
- (!isSpace && event.key && event.key.length === 1 ||
- isSpace && this.adapter.isTypeaheadInProgress())) {
- var key = isSpace ? ' ' : event.key;
- var typeaheadNextIndex = this.adapter.typeaheadMatchItem(key, this.getSelectedIndex());
- if (typeaheadNextIndex >= 0) {
- this.setSelectedIndex(typeaheadNextIndex);
- }
- event.preventDefault();
- return;
- }
- if (!isEnter && !isSpace && !arrowUp && !arrowDown) {
- return;
- }
- this.openMenu();
- event.preventDefault();
- };
- /**
- * Opens/closes the notched outline.
- */
- MDCSelectFoundation.prototype.notchOutline = function (openNotch) {
- if (!this.adapter.hasOutline()) {
- return;
- }
- var isFocused = this.adapter.hasClass(cssClasses$4.FOCUSED);
- if (openNotch) {
- var labelScale = numbers$2.LABEL_SCALE;
- var labelWidth = this.adapter.getLabelWidth() * labelScale;
- this.adapter.notchOutline(labelWidth);
- }
- else if (!isFocused) {
- this.adapter.closeOutline();
- }
- };
- /**
- * Sets the aria label of the leading icon.
- */
- MDCSelectFoundation.prototype.setLeadingIconAriaLabel = function (label) {
- if (this.leadingIcon) {
- this.leadingIcon.setAriaLabel(label);
- }
- };
- /**
- * Sets the text content of the leading icon.
- */
- MDCSelectFoundation.prototype.setLeadingIconContent = function (content) {
- if (this.leadingIcon) {
- this.leadingIcon.setContent(content);
- }
- };
- MDCSelectFoundation.prototype.getUseDefaultValidation = function () {
- return this.useDefaultValidation;
- };
- MDCSelectFoundation.prototype.setUseDefaultValidation = function (useDefaultValidation) {
- this.useDefaultValidation = useDefaultValidation;
- };
- MDCSelectFoundation.prototype.setValid = function (isValid) {
- if (!this.useDefaultValidation) {
- this.customValidity = isValid;
- }
- this.adapter.setSelectAnchorAttr('aria-invalid', (!isValid).toString());
- if (isValid) {
- this.adapter.removeClass(cssClasses$4.INVALID);
- this.adapter.removeMenuClass(cssClasses$4.MENU_INVALID);
- }
- else {
- this.adapter.addClass(cssClasses$4.INVALID);
- this.adapter.addMenuClass(cssClasses$4.MENU_INVALID);
- }
- this.syncHelperTextValidity(isValid);
- };
- MDCSelectFoundation.prototype.isValid = function () {
- if (this.useDefaultValidation &&
- this.adapter.hasClass(cssClasses$4.REQUIRED) &&
- !this.adapter.hasClass(cssClasses$4.DISABLED)) {
- // See notes for required attribute under https://www.w3.org/TR/html52/sec-forms.html#the-select-element
- // TL;DR: Invalid if no index is selected, or if the first index is selected and has an empty value.
- return this.getSelectedIndex() !== numbers$2.UNSET_INDEX &&
- (this.getSelectedIndex() !== 0 || Boolean(this.getValue()));
- }
- return this.customValidity;
- };
- MDCSelectFoundation.prototype.setRequired = function (isRequired) {
- if (isRequired) {
- this.adapter.addClass(cssClasses$4.REQUIRED);
- }
- else {
- this.adapter.removeClass(cssClasses$4.REQUIRED);
- }
- this.adapter.setSelectAnchorAttr('aria-required', isRequired.toString());
- this.adapter.setLabelRequired(isRequired);
- };
- MDCSelectFoundation.prototype.getRequired = function () {
- return this.adapter.getSelectAnchorAttr('aria-required') === 'true';
- };
- MDCSelectFoundation.prototype.init = function () {
- var anchorEl = this.adapter.getAnchorElement();
- if (anchorEl) {
- this.adapter.setMenuAnchorElement(anchorEl);
- this.adapter.setMenuAnchorCorner(Corner.BOTTOM_START);
- }
- this.adapter.setMenuWrapFocus(false);
- this.setDisabled(this.adapter.hasClass(cssClasses$4.DISABLED));
- this.syncHelperTextValidity(!this.adapter.hasClass(cssClasses$4.INVALID));
- this.layout();
- this.layoutOptions();
- };
- /**
- * Unfocuses the select component.
- */
- MDCSelectFoundation.prototype.blur = function () {
- this.adapter.removeClass(cssClasses$4.FOCUSED);
- this.layout();
- this.adapter.deactivateBottomLine();
- var isRequired = this.adapter.hasClass(cssClasses$4.REQUIRED);
- if (isRequired && this.useDefaultValidation) {
- this.setValid(this.isValid());
- }
- };
- MDCSelectFoundation.prototype.syncHelperTextValidity = function (isValid) {
- if (!this.helperText) {
- return;
- }
- this.helperText.setValidity(isValid);
- var helperTextVisible = this.helperText.isVisible();
- var helperTextId = this.helperText.getId();
- if (helperTextVisible && helperTextId) {
- this.adapter.setSelectAnchorAttr(strings$5.ARIA_DESCRIBEDBY, helperTextId);
- }
- else {
- // Needed because screenreaders will read labels pointed to by
- // `aria-describedby` even if they are `aria-hidden`.
- this.adapter.removeSelectAnchorAttr(strings$5.ARIA_DESCRIBEDBY);
- }
- };
- MDCSelectFoundation.prototype.setClickDebounceTimeout = function () {
- var _this = this;
- clearTimeout(this.clickDebounceTimeout);
- this.clickDebounceTimeout = setTimeout(function () {
- _this.recentlyClicked = false;
- }, numbers$2.CLICK_DEBOUNCE_TIMEOUT_MS);
- this.recentlyClicked = true;
- };
- return MDCSelectFoundation;
-}(MDCFoundation));
-// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
-var MDCSelectFoundation$1 = MDCSelectFoundation;
-
+const Xe=Pe(class extends Ve{constructor(t){var e;if(super(t),t.type!==Oe||"class"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter((e=>t[e])).join(" ")+" "}update(t,[e]){var i,n;if(void 0===this.it){this.it=new Set,void 0!==t.strings&&(this.nt=new Set(t.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in e)e[t]&&!(null===(i=this.nt)||void 0===i?void 0:i.has(t))&&this.it.add(t);return this.render(e)}const r=t.element.classList;this.it.forEach((t=>{t in e||(r.remove(t),this.it.delete(t))}));for(const t in e){const i=!!e[t];i===this.it.has(t)||(null===(n=this.nt)||void 0===n?void 0:n.has(t))||(i?(r.add(t),this.it.add(t)):(r.remove(t),this.it.delete(t)))}return U}}),qe=t=>null!=t?t:Y
/**
* @license
- * Copyright 2018 Google LLC
- * SPDX-License-Identifier: BSD-3-Clause
- */const o$1=e$1(class extends i$1{constructor(t$1){var i;if(super(t$1),t$1.type!==t.ATTRIBUTE||"class"!==t$1.name||(null===(i=t$1.strings)||void 0===i?void 0:i.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return " "+Object.keys(t).filter((i=>t[i])).join(" ")+" "}update(i,[s]){var r,o;if(void 0===this.it){this.it=new Set,void 0!==i.strings&&(this.nt=new Set(i.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in s)s[t]&&!(null===(r=this.nt)||void 0===r?void 0:r.has(t))&&this.it.add(t);return this.render(s)}const e=i.element.classList;this.it.forEach((t=>{t in s||(e.remove(t),this.it.delete(t));}));for(const t in s){const i=!!s[t];i===this.it.has(t)||(null===(o=this.nt)||void 0===o?void 0:o.has(t))||(i?(e.add(t),this.it.add(t)):(e.remove(t),this.it.delete(t)));}return T}});
-
+ * Copyright 2020 Google LLC
+ * SPDX-License-Identifier: Apache-2.0
+ */,Ke=(t={})=>{const e={};for(const i in t)e[i]=t[i];return Object.assign({badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valid:!0,valueMissing:!1},e)};
/**
* @license
* Copyright 2018 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */const l$1=l=>null!=l?l:A;
-
-/**
- * @license
- * Copyright 2020 Google LLC
- * SPDX-License-Identifier: Apache-2.0
- */
-const createValidityObj$1 = (customValidity = {}) => {
- /*
- * We need to make ValidityState an object because it is readonly and
- * we cannot use the spread operator. Also, we don't export
- * `CustomValidityState` because it is a leaky implementation and the user
- * already has access to `ValidityState` in lib.dom.ts. Also an interface
- * {a: Type} can be casted to {readonly a: Type} so passing any object
- * should be fine.
- */
- const objectifiedCustomValidity = {};
- // eslint-disable-next-line guard-for-in
- for (const propName in customValidity) {
- /*
- * Casting is needed because ValidityState's props are all readonly and
- * thus cannot be set on `onjectifiedCustomValidity`. In the end, the
- * interface is the same as ValidityState (but not readonly), but the
- * function signature casts the output to ValidityState (thus readonly).
- */
- objectifiedCustomValidity[propName] =
- customValidity[propName];
- }
- return Object.assign({ badInput: false, customError: false, patternMismatch: false, rangeOverflow: false, rangeUnderflow: false, stepMismatch: false, tooLong: false, tooShort: false, typeMismatch: false, valid: true, valueMissing: false }, objectifiedCustomValidity);
-};
-/**
- * @fires selected {SelectedDetail}
- * @fires action {ActionDetail}
- * @fires opened
- * @fires closed
- * @fires change
- * @fires invalid
- */
-class SelectBase extends FormElement {
- constructor() {
- super(...arguments);
- this.mdcFoundationClass = MDCSelectFoundation$1;
- this.disabled = false;
- this.outlined = false;
- this.label = '';
- this.outlineOpen = false;
- this.outlineWidth = 0;
- this.value = '';
- this.name = '';
- this.selectedText = '';
- this.icon = '';
- this.menuOpen = false;
- this.helper = '';
- this.validateOnInitialRender = false;
- this.validationMessage = '';
- this.required = false;
- this.naturalMenuWidth = false;
- this.isUiValid = true;
- this.fixedMenuPosition = false;
- // Transiently holds current typeahead prefix from user.
- this.typeaheadState = initState();
- this.sortedIndexByFirstChar = new Map();
- this.menuElement_ = null;
- this.listeners = [];
- this.onBodyClickBound = () => undefined;
- this._menuUpdateComplete = null;
- this.valueSetDirectly = false;
- this.validityTransform = null;
- this._validity = createValidityObj$1();
- }
- get items() {
- // memoize menuElement to prevent unnecessary querySelector calls.
- if (!this.menuElement_) {
- this.menuElement_ = this.menuElement;
- }
- if (this.menuElement_) {
- return this.menuElement_.items;
- }
- return [];
- }
- get selected() {
- const menuElement = this.menuElement;
- if (menuElement) {
- return menuElement.selected;
- }
- return null;
- }
- get index() {
- const menuElement = this.menuElement;
- if (menuElement) {
- return menuElement.index;
- }
- return -1;
- }
- get shouldRenderHelperText() {
- return !!this.helper || !!this.validationMessage;
- }
- get validity() {
- this._checkValidity(this.value);
- return this._validity;
- }
- render() {
- const classes = {
- 'mdc-select--disabled': this.disabled,
- 'mdc-select--no-label': !this.label,
- 'mdc-select--filled': !this.outlined,
- 'mdc-select--outlined': this.outlined,
- 'mdc-select--with-leading-icon': !!this.icon,
- 'mdc-select--required': this.required,
- 'mdc-select--invalid': !this.isUiValid,
- };
- const labelledby = !!this.label ? 'label' : undefined;
- const describedby = this.shouldRenderHelperText ? 'helper-text' : undefined;
- return x `
+ */class Ge extends ke{constructor(){super(...arguments),this.mdcFoundationClass=je,this.disabled=!1,this.outlined=!1,this.label="",this.outlineOpen=!1,this.outlineWidth=0,this.value="",this.name="",this.selectedText="",this.icon="",this.menuOpen=!1,this.helper="",this.validateOnInitialRender=!1,this.validationMessage="",this.required=!1,this.naturalMenuWidth=!1,this.isUiValid=!0,this.fixedMenuPosition=!1,this.typeaheadState={bufferClearTimeout:0,currentFirstChar:"",sortedIndexCursor:0,typeaheadBuffer:""},this.sortedIndexByFirstChar=new Map,this.menuElement_=null,this.listeners=[],this.onBodyClickBound=()=>{},this._menuUpdateComplete=null,this.valueSetDirectly=!1,this.validityTransform=null,this._validity=Ke()}get items(){return this.menuElement_||(this.menuElement_=this.menuElement),this.menuElement_?this.menuElement_.items:[]}get selected(){const t=this.menuElement;return t?t.selected:null}get index(){const t=this.menuElement;return t?t.index:-1}get shouldRenderHelperText(){return!!this.helper||!!this.validationMessage}get validity(){return this._checkValidity(this.value),this._validity}render(){const t={"mdc-select--disabled":this.disabled,"mdc-select--no-label":!this.label,"mdc-select--filled":!this.outlined,"mdc-select--outlined":this.outlined,"mdc-select--with-leading-icon":!!this.icon,"mdc-select--required":this.required,"mdc-select--invalid":!this.isUiValid},e=this.label?"label":void 0,i=this.shouldRenderHelperText?"helper-text":void 0;return B`
+ class="mdc-select ${Xe(t)}">
${this.renderRipple()}
- ${this.outlined ? this.renderOutline() : this.renderLabel()}
+ ${this.outlined?this.renderOutline():this.renderLabel()}
${this.renderLeadingIcon()}
${this.selectedText}
@@ -2393,17 +520,13 @@ class SelectBase extends FormElement {
${this.renderMenu()}
- ${this.renderHelperText()}`;
- }
- renderMenu() {
- const classes = this.getMenuClasses();
- return x `
+ ${this.renderHelperText()}`}renderMenu(){const t=this.getMenuClasses();return B`
${this.renderMenuContent()}
- `;
- }
- getMenuClasses() {
- return {
- 'mdc-select__menu': true,
- 'mdc-menu': true,
- 'mdc-menu-surface': true,
- 'mdc-select__menu--invalid': !this.isUiValid,
- };
- }
- renderMenuContent() {
- return x ` `;
- }
- renderRipple() {
- if (this.outlined) {
- return A;
- }
- return x `
+ `}getMenuClasses(){return{"mdc-select__menu":!0,"mdc-menu":!0,"mdc-menu-surface":!0,"mdc-select__menu--invalid":!this.isUiValid}}renderMenuContent(){return B` `}renderRipple(){return this.outlined?Y:B`
- `;
- }
- renderOutline() {
- if (!this.outlined) {
- return A;
- }
- return x `
+ `}renderOutline(){return this.outlined?B`
${this.renderLabel()}
- `;
- }
- renderLabel() {
- if (!this.label) {
- return A;
- }
- return x `
+ `:Y}renderLabel(){return this.label?B`
${this.label}
- `;
- }
- renderLeadingIcon() {
- if (!this.icon) {
- return A;
- }
- return x `${this.icon}
`;
- }
- renderLineRipple() {
- if (this.outlined) {
- return A;
- }
- return x `
-
- `;
- }
- renderHelperText() {
- if (!this.shouldRenderHelperText) {
- return A;
- }
- const showValidationMessage = this.validationMessage && !this.isUiValid;
- const classes = {
- 'mdc-select-helper-text--validation-msg': showValidationMessage,
- };
- return x `
+ `:Y}renderLeadingIcon(){return this.icon?B`${this.icon}
`:Y}renderLineRipple(){return this.outlined?Y:B`
+
+ `}renderHelperText(){if(!this.shouldRenderHelperText)return Y;const t=this.validationMessage&&!this.isUiValid;return B`
${showValidationMessage ? this.validationMessage : this.helper}
`;
- }
- createAdapter() {
- return Object.assign(Object.assign({}, addHasRemoveClass(this.mdcRoot)), { activateBottomLine: () => {
- if (this.lineRippleElement) {
- this.lineRippleElement.lineRippleFoundation.activate();
- }
- }, deactivateBottomLine: () => {
- if (this.lineRippleElement) {
- this.lineRippleElement.lineRippleFoundation.deactivate();
- }
- }, hasLabel: () => {
- return !!this.label;
- }, floatLabel: (shouldFloat) => {
- if (this.labelElement) {
- this.labelElement.floatingLabelFoundation.float(shouldFloat);
- }
- }, getLabelWidth: () => {
- if (this.labelElement) {
- return this.labelElement.floatingLabelFoundation.getWidth();
- }
- return 0;
- }, setLabelRequired: (isRequired) => {
- if (this.labelElement) {
- this.labelElement.floatingLabelFoundation.setRequired(isRequired);
- }
- }, hasOutline: () => this.outlined, notchOutline: (labelWidth) => {
- const outlineElement = this.outlineElement;
- if (outlineElement && !this.outlineOpen) {
- this.outlineWidth = labelWidth;
- this.outlineOpen = true;
- }
- }, closeOutline: () => {
- if (this.outlineElement) {
- this.outlineOpen = false;
- }
- }, setRippleCenter: (normalizedX) => {
- if (this.lineRippleElement) {
- const foundation = this.lineRippleElement.lineRippleFoundation;
- foundation.setRippleCenter(normalizedX);
- }
- }, notifyChange: async (value) => {
- if (!this.valueSetDirectly && value === this.value) {
- return;
- }
- this.valueSetDirectly = false;
- this.value = value;
- await this.updateComplete;
- const ev = new Event('change', { bubbles: true });
- this.dispatchEvent(ev);
- }, setSelectedText: (value) => this.selectedText = value, isSelectAnchorFocused: () => {
- const selectAnchorElement = this.anchorElement;
- if (!selectAnchorElement) {
- return false;
- }
- const rootNode = selectAnchorElement.getRootNode();
- return rootNode.activeElement === selectAnchorElement;
- }, getSelectAnchorAttr: (attr) => {
- const selectAnchorElement = this.anchorElement;
- if (!selectAnchorElement) {
- return null;
- }
- return selectAnchorElement.getAttribute(attr);
- }, setSelectAnchorAttr: (attr, value) => {
- const selectAnchorElement = this.anchorElement;
- if (!selectAnchorElement) {
- return;
- }
- selectAnchorElement.setAttribute(attr, value);
- }, removeSelectAnchorAttr: (attr) => {
- const selectAnchorElement = this.anchorElement;
- if (!selectAnchorElement) {
- return;
- }
- selectAnchorElement.removeAttribute(attr);
- }, openMenu: () => {
- this.menuOpen = true;
- }, closeMenu: () => {
- this.menuOpen = false;
- }, addMenuClass: () => undefined, removeMenuClass: () => undefined, getAnchorElement: () => this.anchorElement, setMenuAnchorElement: () => {
- /* Handled by anchor directive */
- }, setMenuAnchorCorner: () => {
- const menuElement = this.menuElement;
- if (menuElement) {
- menuElement.corner = 'BOTTOM_START';
- }
- }, setMenuWrapFocus: (wrapFocus) => {
- const menuElement = this.menuElement;
- if (menuElement) {
- menuElement.wrapFocus = wrapFocus;
- }
- }, focusMenuItemAtIndex: (index) => {
- const menuElement = this.menuElement;
- if (!menuElement) {
- return;
- }
- const element = menuElement.items[index];
- if (!element) {
- return;
- }
- element.focus();
- }, getMenuItemCount: () => {
- const menuElement = this.menuElement;
- if (menuElement) {
- return menuElement.items.length;
- }
- return 0;
- }, getMenuItemValues: () => {
- const menuElement = this.menuElement;
- if (!menuElement) {
- return [];
- }
- const items = menuElement.items;
- return items.map((item) => item.value);
- }, getMenuItemTextAtIndex: (index) => {
- const menuElement = this.menuElement;
- if (!menuElement) {
- return '';
- }
- const element = menuElement.items[index];
- if (!element) {
- return '';
- }
- return element.text;
- }, getSelectedIndex: () => this.index, setSelectedIndex: () => undefined, isTypeaheadInProgress: () => isTypingInProgress(this.typeaheadState), typeaheadMatchItem: (nextChar, startingIndex) => {
- if (!this.menuElement) {
- return -1;
- }
- const opts = {
- focusItemAtIndex: (index) => {
- this.menuElement.focusItemAtIndex(index);
- },
- focusedItemIndex: startingIndex ?
- startingIndex :
- this.menuElement.getFocusedItemIndex(),
- nextChar,
- sortedIndexByFirstChar: this.sortedIndexByFirstChar,
- skipFocus: false,
- isItemAtIndexDisabled: (index) => this.items[index].disabled,
- };
- const index = matchItem(opts, this.typeaheadState);
- if (index !== -1) {
- this.select(index);
- }
- return index;
- } });
- }
- checkValidity() {
- const isValid = this._checkValidity(this.value);
- if (!isValid) {
- const invalidEvent = new Event('invalid', { bubbles: false, cancelable: true });
- this.dispatchEvent(invalidEvent);
- }
- return isValid;
- }
- reportValidity() {
- const isValid = this.checkValidity();
- this.isUiValid = isValid;
- return isValid;
- }
- _checkValidity(value) {
- const nativeValidity = this.formElement.validity;
- let validity = createValidityObj$1(nativeValidity);
- if (this.validityTransform) {
- const customValidity = this.validityTransform(value, validity);
- validity = Object.assign(Object.assign({}, validity), customValidity);
- }
- this._validity = validity;
- return this._validity.valid;
- }
- setCustomValidity(message) {
- this.validationMessage = message;
- this.formElement.setCustomValidity(message);
- }
- // tslint:disable:ban-ts-ignore
- async getUpdateComplete() {
- await this._menuUpdateComplete;
- // @ts-ignore
- const result = await super.getUpdateComplete();
- return result;
- }
- // tslint:enable:ban-ts-ignore
- async firstUpdated() {
- const menuElement = this.menuElement;
- if (menuElement) {
- this._menuUpdateComplete = menuElement.updateComplete;
- await this._menuUpdateComplete;
- }
- super.firstUpdated();
- this.mdcFoundation.isValid = () => true;
- this.mdcFoundation.setValid = () => undefined;
- this.mdcFoundation.setDisabled(this.disabled);
- if (this.validateOnInitialRender) {
- this.reportValidity();
- }
- // Select an option based on init value
- if (!this.selected) {
- if (!this.items.length && this.slotElement &&
- this.slotElement.assignedNodes({ flatten: true }).length) {
- // Shady DOM initial render fix
- await new Promise((res) => requestAnimationFrame(res));
- await this.layout();
- }
- const hasEmptyFirstOption = this.items.length && this.items[0].value === '';
- if (!this.value && hasEmptyFirstOption) {
- this.select(0);
- return;
- }
- this.selectByValue(this.value);
- }
- this.sortedIndexByFirstChar = initSortedIndex(this.items.length, (index) => this.items[index].text);
- }
- onItemsUpdated() {
- this.sortedIndexByFirstChar = initSortedIndex(this.items.length, (index) => this.items[index].text);
- }
- select(index) {
- const menuElement = this.menuElement;
- if (menuElement) {
- menuElement.select(index);
- }
- }
- selectByValue(value) {
- let indexToSelect = -1;
- for (let i = 0; i < this.items.length; i++) {
- const item = this.items[i];
- if (item.value === value) {
- indexToSelect = i;
- break;
- }
- }
- this.valueSetDirectly = true;
- this.select(indexToSelect);
- this.mdcFoundation.handleChange();
- }
- disconnectedCallback() {
- super.disconnectedCallback();
- for (const listener of this.listeners) {
- listener.target.removeEventListener(listener.name, listener.cb);
- }
- }
- focus() {
- const focusEvt = new CustomEvent('focus');
- const selectAnchorElement = this.anchorElement;
- if (selectAnchorElement) {
- selectAnchorElement.dispatchEvent(focusEvt);
- selectAnchorElement.focus();
- }
- }
- blur() {
- const focusEvt = new CustomEvent('blur');
- const selectAnchorElement = this.anchorElement;
- if (selectAnchorElement) {
- selectAnchorElement.dispatchEvent(focusEvt);
- selectAnchorElement.blur();
- }
- }
- onFocus() {
- if (this.mdcFoundation) {
- this.mdcFoundation.handleFocus();
- }
- }
- onBlur() {
- if (this.mdcFoundation) {
- this.mdcFoundation.handleBlur();
- }
- const menuElement = this.menuElement;
- if (menuElement && !menuElement.open) {
- this.reportValidity();
- }
- }
- onClick(evt) {
- if (this.mdcFoundation) {
- this.focus();
- const targetClientRect = evt.target.getBoundingClientRect();
- let xCoord = 0;
- if ('touches' in evt) {
- xCoord = evt.touches[0].clientX;
- }
- else {
- xCoord = evt.clientX;
- }
- const normalizedX = xCoord - targetClientRect.left;
- this.mdcFoundation.handleClick(normalizedX);
- }
- }
- onKeydown(evt) {
- const arrowUp = normalizeKey(evt) === KEY.ARROW_UP;
- const arrowDown = normalizeKey(evt) === KEY.ARROW_DOWN;
- if (arrowDown || arrowUp) {
- const shouldSelectNextItem = arrowUp && this.index > 0;
- const shouldSelectPrevItem = arrowDown && this.index < this.items.length - 1;
- if (shouldSelectNextItem) {
- this.select(this.index - 1);
- }
- else if (shouldSelectPrevItem) {
- this.select(this.index + 1);
- }
- evt.preventDefault();
- this.mdcFoundation.openMenu();
- return;
- }
- this.mdcFoundation.handleKeydown(evt);
- }
- // must capture to run before list foundation captures event
- handleTypeahead(event) {
- if (!this.menuElement) {
- return;
- }
- const focusedItemIndex = this.menuElement.getFocusedItemIndex();
- const target = isNodeElement(event.target) ?
- event.target :
- null;
- const isTargetListItem = target ? target.hasAttribute('mwc-list-item') : false;
- const opts = {
- event,
- focusItemAtIndex: (index) => {
- this.menuElement.focusItemAtIndex(index);
- },
- focusedItemIndex,
- isTargetListItem,
- sortedIndexByFirstChar: this.sortedIndexByFirstChar,
- isItemAtIndexDisabled: (index) => this.items[index].disabled,
- };
- handleKeydown(opts, this.typeaheadState);
- }
- async onSelected(event) {
- if (!this.mdcFoundation) {
- await this.updateComplete;
- }
- this.mdcFoundation.handleMenuItemAction(event.detail.index);
- const item = this.items[event.detail.index];
- if (item) {
- this.value = item.value;
- }
- }
- onOpened() {
- if (this.mdcFoundation) {
- this.menuOpen = true;
- this.mdcFoundation.handleMenuOpened();
- }
- }
- onClosed() {
- if (this.mdcFoundation) {
- this.menuOpen = false;
- this.mdcFoundation.handleMenuClosed();
- }
- }
- setFormData(formData) {
- if (this.name && this.selected !== null) {
- formData.append(this.name, this.value);
- }
- }
- async layout(updateItems = true) {
- if (this.mdcFoundation) {
- this.mdcFoundation.layout();
- }
- await this.updateComplete;
- const menuElement = this.menuElement;
- if (menuElement) {
- menuElement.layout(updateItems);
- }
- const labelElement = this.labelElement;
- if (!labelElement) {
- this.outlineOpen = false;
- return;
- }
- const shouldFloat = !!this.label && !!this.value;
- labelElement.floatingLabelFoundation.float(shouldFloat);
- if (!this.outlined) {
- return;
- }
- this.outlineOpen = shouldFloat;
- await this.updateComplete;
- /* When the textfield automatically notches due to a value and label
- * being defined, the textfield may be set to `display: none` by the user.
- * this means that the notch is of size 0px. We provide this function so
- * that the user may manually resize the notch to the floated label's
- * width.
- */
- const labelWidth = labelElement.floatingLabelFoundation.getWidth();
- if (this.outlineOpen) {
- this.outlineWidth = labelWidth;
- }
- }
- async layoutOptions() {
- if (!this.mdcFoundation) {
- return;
- }
- this.mdcFoundation.layoutOptions();
- }
-}
-__decorate([
- i$2('.mdc-select')
-], SelectBase.prototype, "mdcRoot", void 0);
-__decorate([
- i$2('.formElement')
-], SelectBase.prototype, "formElement", void 0);
-__decorate([
- i$2('slot')
-], SelectBase.prototype, "slotElement", void 0);
-__decorate([
- i$2('select')
-], SelectBase.prototype, "nativeSelectElement", void 0);
-__decorate([
- i$2('input')
-], SelectBase.prototype, "nativeInputElement", void 0);
-__decorate([
- i$2('.mdc-line-ripple')
-], SelectBase.prototype, "lineRippleElement", void 0);
-__decorate([
- i$2('.mdc-floating-label')
-], SelectBase.prototype, "labelElement", void 0);
-__decorate([
- i$2('mwc-notched-outline')
-], SelectBase.prototype, "outlineElement", void 0);
-__decorate([
- i$2('.mdc-menu')
-], SelectBase.prototype, "menuElement", void 0);
-__decorate([
- i$2('.mdc-select__anchor')
-], SelectBase.prototype, "anchorElement", void 0);
-__decorate([
- n$3({ type: Boolean, attribute: 'disabled', reflect: true }),
- observer(function (value) {
- if (this.mdcFoundation) {
- this.mdcFoundation.setDisabled(value);
- }
- })
-], SelectBase.prototype, "disabled", void 0);
-__decorate([
- n$3({ type: Boolean }),
- observer(function (_newVal, oldVal) {
- if (oldVal !== undefined && this.outlined !== oldVal) {
- this.layout(false);
- }
- })
-], SelectBase.prototype, "outlined", void 0);
-__decorate([
- n$3({ type: String }),
- observer(function (_newVal, oldVal) {
- if (oldVal !== undefined && this.label !== oldVal) {
- this.layout(false);
- }
- })
-], SelectBase.prototype, "label", void 0);
-__decorate([
- t$1()
-], SelectBase.prototype, "outlineOpen", void 0);
-__decorate([
- t$1()
-], SelectBase.prototype, "outlineWidth", void 0);
-__decorate([
- n$3({ type: String }),
- observer(function (value) {
- if (this.mdcFoundation) {
- const initialization = this.selected === null && !!value;
- const valueSetByUser = this.selected && this.selected.value !== value;
- if (initialization || valueSetByUser) {
- this.selectByValue(value);
- }
- this.reportValidity();
- }
- })
-], SelectBase.prototype, "value", void 0);
-__decorate([
- n$3()
-], SelectBase.prototype, "name", void 0);
-__decorate([
- t$1()
-], SelectBase.prototype, "selectedText", void 0);
-__decorate([
- n$3({ type: String })
-], SelectBase.prototype, "icon", void 0);
-__decorate([
- t$1()
-], SelectBase.prototype, "menuOpen", void 0);
-__decorate([
- n$3({ type: String })
-], SelectBase.prototype, "helper", void 0);
-__decorate([
- n$3({ type: Boolean })
-], SelectBase.prototype, "validateOnInitialRender", void 0);
-__decorate([
- n$3({ type: String })
-], SelectBase.prototype, "validationMessage", void 0);
-__decorate([
- n$3({ type: Boolean })
-], SelectBase.prototype, "required", void 0);
-__decorate([
- n$3({ type: Boolean })
-], SelectBase.prototype, "naturalMenuWidth", void 0);
-__decorate([
- t$1()
-], SelectBase.prototype, "isUiValid", void 0);
-__decorate([
- n$3({ type: Boolean })
-], SelectBase.prototype, "fixedMenuPosition", void 0);
-__decorate([
- e$3({ capture: true })
-], SelectBase.prototype, "handleTypeahead", null);
-
+ class="mdc-select-helper-text ${Xe({"mdc-select-helper-text--validation-msg":t})}"
+ id="helper-text">${t?this.validationMessage:this.helper}
`}createAdapter(){return Object.assign(Object.assign({},xe(this.mdcRoot)),{activateBottomLine:()=>{this.lineRippleElement&&this.lineRippleElement.lineRippleFoundation.activate()},deactivateBottomLine:()=>{this.lineRippleElement&&this.lineRippleElement.lineRippleFoundation.deactivate()},hasLabel:()=>!!this.label,floatLabel:t=>{this.labelElement&&this.labelElement.floatingLabelFoundation.float(t)},getLabelWidth:()=>this.labelElement?this.labelElement.floatingLabelFoundation.getWidth():0,setLabelRequired:t=>{this.labelElement&&this.labelElement.floatingLabelFoundation.setRequired(t)},hasOutline:()=>this.outlined,notchOutline:t=>{this.outlineElement&&!this.outlineOpen&&(this.outlineWidth=t,this.outlineOpen=!0)},closeOutline:()=>{this.outlineElement&&(this.outlineOpen=!1)},setRippleCenter:t=>{if(this.lineRippleElement){this.lineRippleElement.lineRippleFoundation.setRippleCenter(t)}},notifyChange:async t=>{if(!this.valueSetDirectly&&t===this.value)return;this.valueSetDirectly=!1,this.value=t,await this.updateComplete;const e=new Event("change",{bubbles:!0});this.dispatchEvent(e)},setSelectedText:t=>this.selectedText=t,isSelectAnchorFocused:()=>{const t=this.anchorElement;if(!t)return!1;return t.getRootNode().activeElement===t},getSelectAnchorAttr:t=>{const e=this.anchorElement;return e?e.getAttribute(t):null},setSelectAnchorAttr:(t,e)=>{const i=this.anchorElement;i&&i.setAttribute(t,e)},removeSelectAnchorAttr:t=>{const e=this.anchorElement;e&&e.removeAttribute(t)},openMenu:()=>{this.menuOpen=!0},closeMenu:()=>{this.menuOpen=!1},addMenuClass:()=>{},removeMenuClass:()=>{},getAnchorElement:()=>this.anchorElement,setMenuAnchorElement:()=>{},setMenuAnchorCorner:()=>{const t=this.menuElement;t&&(t.corner="BOTTOM_START")},setMenuWrapFocus:t=>{const e=this.menuElement;e&&(e.wrapFocus=t)},focusMenuItemAtIndex:t=>{const e=this.menuElement;if(!e)return;const i=e.items[t];i&&i.focus()},getMenuItemCount:()=>{const t=this.menuElement;return t?t.items.length:0},getMenuItemValues:()=>{const t=this.menuElement;if(!t)return[];return t.items.map((t=>t.value))},getMenuItemTextAtIndex:t=>{const e=this.menuElement;if(!e)return"";const i=e.items[t];return i?i.text:""},getSelectedIndex:()=>this.index,setSelectedIndex:()=>{},isTypeaheadInProgress:()=>_e(this.typeaheadState),typeaheadMatchItem:(t,e)=>{if(!this.menuElement)return-1;const i={focusItemAtIndex:t=>{this.menuElement.focusItemAtIndex(t)},focusedItemIndex:e||this.menuElement.getFocusedItemIndex(),nextChar:t,sortedIndexByFirstChar:this.sortedIndexByFirstChar,skipFocus:!1,isItemAtIndexDisabled:t=>this.items[t].disabled},n=ve(i,this.typeaheadState);return-1!==n&&this.select(n),n}})}checkValidity(){const t=this._checkValidity(this.value);if(!t){const t=new Event("invalid",{bubbles:!1,cancelable:!0});this.dispatchEvent(t)}return t}reportValidity(){const t=this.checkValidity();return this.isUiValid=t,t}_checkValidity(t){const e=this.formElement.validity;let i=Ke(e);if(this.validityTransform){const e=this.validityTransform(t,i);i=Object.assign(Object.assign({},i),e)}return this._validity=i,this._validity.valid}setCustomValidity(t){this.validationMessage=t,this.formElement.setCustomValidity(t)}async getUpdateComplete(){await this._menuUpdateComplete;return await super.getUpdateComplete()}async firstUpdated(){const t=this.menuElement;if(t&&(this._menuUpdateComplete=t.updateComplete,await this._menuUpdateComplete),super.firstUpdated(),this.mdcFoundation.isValid=()=>!0,this.mdcFoundation.setValid=()=>{},this.mdcFoundation.setDisabled(this.disabled),this.validateOnInitialRender&&this.reportValidity(),!this.selected){!this.items.length&&this.slotElement&&this.slotElement.assignedNodes({flatten:!0}).length&&(await new Promise((t=>requestAnimationFrame(t))),await this.layout());const t=this.items.length&&""===this.items[0].value;if(!this.value&&t)return void this.select(0);this.selectByValue(this.value)}this.sortedIndexByFirstChar=be(this.items.length,(t=>this.items[t].text))}onItemsUpdated(){this.sortedIndexByFirstChar=be(this.items.length,(t=>this.items[t].text))}select(t){const e=this.menuElement;e&&e.select(t)}selectByValue(t){let e=-1;for(let i=0;i0,r=i&&this.index{this.menuElement.focusItemAtIndex(t)},focusedItemIndex:e,isTargetListItem:!!i&&i.hasAttribute("mwc-list-item"),sortedIndexByFirstChar:this.sortedIndexByFirstChar,isItemAtIndexDisabled:t=>this.items[t].disabled},this.typeaheadState)}async onSelected(t){this.mdcFoundation||await this.updateComplete,this.mdcFoundation.handleMenuItemAction(t.detail.index);const e=this.items[t.detail.index];e&&(this.value=e.value)}onOpened(){this.mdcFoundation&&(this.menuOpen=!0,this.mdcFoundation.handleMenuOpened())}onClosed(){this.mdcFoundation&&(this.menuOpen=!1,this.mdcFoundation.handleMenuClosed())}setFormData(t){this.name&&null!==this.selected&&t.append(this.name,this.value)}async layout(t=!0){this.mdcFoundation&&this.mdcFoundation.layout(),await this.updateComplete;const e=this.menuElement;e&&e.layout(t);const i=this.labelElement;if(!i)return void(this.outlineOpen=!1);const n=!!this.label&&!!this.value;if(i.floatingLabelFoundation.float(n),!this.outlined)return;this.outlineOpen=n,await this.updateComplete;const r=i.floatingLabelFoundation.getWidth();this.outlineOpen&&(this.outlineWidth=r)}async layoutOptions(){this.mdcFoundation&&this.mdcFoundation.layoutOptions()}}n([gt(".mdc-select")],Ge.prototype,"mdcRoot",void 0),n([gt(".formElement")],Ge.prototype,"formElement",void 0),n([gt("slot")],Ge.prototype,"slotElement",void 0),n([gt("select")],Ge.prototype,"nativeSelectElement",void 0),n([gt("input")],Ge.prototype,"nativeInputElement",void 0),n([gt(".mdc-line-ripple")],Ge.prototype,"lineRippleElement",void 0),n([gt(".mdc-floating-label")],Ge.prototype,"labelElement",void 0),n([gt("mwc-notched-outline")],Ge.prototype,"outlineElement",void 0),n([gt(".mdc-menu")],Ge.prototype,"menuElement",void 0),n([gt(".mdc-select__anchor")],Ge.prototype,"anchorElement",void 0),n([ht({type:Boolean,attribute:"disabled",reflect:!0}),Te((function(t){this.mdcFoundation&&this.mdcFoundation.setDisabled(t)}))],Ge.prototype,"disabled",void 0),n([ht({type:Boolean}),Te((function(t,e){void 0!==e&&this.outlined!==e&&this.layout(!1)}))],Ge.prototype,"outlined",void 0),n([ht({type:String}),Te((function(t,e){void 0!==e&&this.label!==e&&this.layout(!1)}))],Ge.prototype,"label",void 0),n([pt()],Ge.prototype,"outlineOpen",void 0),n([pt()],Ge.prototype,"outlineWidth",void 0),n([ht({type:String}),Te((function(t){if(this.mdcFoundation){const e=null===this.selected&&!!t,i=this.selected&&this.selected.value!==t;(e||i)&&this.selectByValue(t),this.reportValidity()}}))],Ge.prototype,"value",void 0),n([ht()],Ge.prototype,"name",void 0),n([pt()],Ge.prototype,"selectedText",void 0),n([ht({type:String})],Ge.prototype,"icon",void 0),n([pt()],Ge.prototype,"menuOpen",void 0),n([ht({type:String})],Ge.prototype,"helper",void 0),n([ht({type:Boolean})],Ge.prototype,"validateOnInitialRender",void 0),n([ht({type:String})],Ge.prototype,"validationMessage",void 0),n([ht({type:Boolean})],Ge.prototype,"required",void 0),n([ht({type:Boolean})],Ge.prototype,"naturalMenuWidth",void 0),n([pt()],Ge.prototype,"isUiValid",void 0),n([ht({type:Boolean})],Ge.prototype,"fixedMenuPosition",void 0),n([ft({capture:!0})],Ge.prototype,"handleTypeahead",null);
/**
* @license
* Copyright 2021 Google LLC
* SPDX-LIcense-Identifier: Apache-2.0
*/
-const styles$6 = i$5 `.mdc-floating-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:1rem;font-size:var(--mdc-typography-subtitle1-font-size, 1rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);position:absolute;left:0;-webkit-transform-origin:left top;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform;transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1),color 150ms cubic-bezier(0.4, 0, 0.2, 1)}[dir=rtl] .mdc-floating-label,.mdc-floating-label[dir=rtl]{right:0;left:auto;-webkit-transform-origin:right top;transform-origin:right top;text-align:right}.mdc-floating-label--float-above{cursor:auto}.mdc-floating-label--required::after{margin-left:1px;margin-right:0px;content:"*"}[dir=rtl] .mdc-floating-label--required::after,.mdc-floating-label--required[dir=rtl]::after{margin-left:0;margin-right:1px}.mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-standard 250ms 1}@keyframes mdc-floating-label-shake-float-above-standard{0%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-106%) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-106%) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}}@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-line-ripple::before,.mdc-line-ripple::after{position:absolute;bottom:0;left:0;width:100%;border-bottom-style:solid;content:""}.mdc-line-ripple::before{border-bottom-width:1px}.mdc-line-ripple::before{z-index:1}.mdc-line-ripple::after{transform:scaleX(0);border-bottom-width:2px;opacity:0;z-index:2}.mdc-line-ripple::after{transition:transform 180ms cubic-bezier(0.4, 0, 0.2, 1),opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-line-ripple--active::after{transform:scaleX(1);opacity:1}.mdc-line-ripple--deactivating::after{opacity:0}.mdc-notched-outline{display:flex;position:absolute;top:0;right:0;left:0;box-sizing:border-box;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}[dir=rtl] .mdc-notched-outline,.mdc-notched-outline[dir=rtl]{text-align:right}.mdc-notched-outline__leading,.mdc-notched-outline__notch,.mdc-notched-outline__trailing{box-sizing:border-box;height:100%;border-top:1px solid;border-bottom:1px solid;pointer-events:none}.mdc-notched-outline__leading{border-left:1px solid;border-right:none;width:12px}[dir=rtl] .mdc-notched-outline__leading,.mdc-notched-outline__leading[dir=rtl]{border-left:none;border-right:1px solid}.mdc-notched-outline__trailing{border-left:none;border-right:1px solid;flex-grow:1}[dir=rtl] .mdc-notched-outline__trailing,.mdc-notched-outline__trailing[dir=rtl]{border-left:1px solid;border-right:none}.mdc-notched-outline__notch{flex:0 0 auto;width:auto;max-width:calc(100% - 12px * 2)}.mdc-notched-outline .mdc-floating-label{display:inline-block;position:relative;max-width:100%}.mdc-notched-outline .mdc-floating-label--float-above{text-overflow:clip}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:calc(100% / 0.75)}.mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:0;padding-right:8px;border-top:none}[dir=rtl] .mdc-notched-outline--notched .mdc-notched-outline__notch,.mdc-notched-outline--notched .mdc-notched-outline__notch[dir=rtl]{padding-left:8px;padding-right:0}.mdc-notched-outline--no-label .mdc-notched-outline__notch{display:none}.mdc-select{display:inline-flex;position:relative}.mdc-select:not(.mdc-select--disabled) .mdc-select__selected-text{color:rgba(0, 0, 0, 0.87)}.mdc-select.mdc-select--disabled .mdc-select__selected-text{color:rgba(0, 0, 0, 0.38)}.mdc-select:not(.mdc-select--disabled) .mdc-floating-label{color:rgba(0, 0, 0, 0.6)}.mdc-select:not(.mdc-select--disabled).mdc-select--focused .mdc-floating-label{color:rgba(98, 0, 238, 0.87)}.mdc-select.mdc-select--disabled .mdc-floating-label{color:rgba(0, 0, 0, 0.38)}.mdc-select:not(.mdc-select--disabled) .mdc-select__dropdown-icon{fill:rgba(0, 0, 0, 0.54)}.mdc-select:not(.mdc-select--disabled).mdc-select--focused .mdc-select__dropdown-icon{fill:#6200ee;fill:var(--mdc-theme-primary, #6200ee)}.mdc-select.mdc-select--disabled .mdc-select__dropdown-icon{fill:rgba(0, 0, 0, 0.38)}.mdc-select:not(.mdc-select--disabled)+.mdc-select-helper-text{color:rgba(0, 0, 0, 0.6)}.mdc-select.mdc-select--disabled+.mdc-select-helper-text{color:rgba(0, 0, 0, 0.38)}.mdc-select:not(.mdc-select--disabled) .mdc-select__icon{color:rgba(0, 0, 0, 0.54)}.mdc-select.mdc-select--disabled .mdc-select__icon{color:rgba(0, 0, 0, 0.38)}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-select.mdc-select--disabled .mdc-select__selected-text{color:GrayText}.mdc-select.mdc-select--disabled .mdc-select__dropdown-icon{fill:red}.mdc-select.mdc-select--disabled .mdc-floating-label{color:GrayText}.mdc-select.mdc-select--disabled .mdc-line-ripple::before{border-bottom-color:GrayText}.mdc-select.mdc-select--disabled .mdc-notched-outline__leading,.mdc-select.mdc-select--disabled .mdc-notched-outline__notch,.mdc-select.mdc-select--disabled .mdc-notched-outline__trailing{border-color:GrayText}.mdc-select.mdc-select--disabled .mdc-select__icon{color:GrayText}.mdc-select.mdc-select--disabled+.mdc-select-helper-text{color:GrayText}}.mdc-select .mdc-floating-label{top:50%;transform:translateY(-50%);pointer-events:none}.mdc-select .mdc-select__anchor{padding-left:16px;padding-right:0}[dir=rtl] .mdc-select .mdc-select__anchor,.mdc-select .mdc-select__anchor[dir=rtl]{padding-left:0;padding-right:16px}.mdc-select.mdc-select--with-leading-icon .mdc-select__anchor{padding-left:0;padding-right:0}[dir=rtl] .mdc-select.mdc-select--with-leading-icon .mdc-select__anchor,.mdc-select.mdc-select--with-leading-icon .mdc-select__anchor[dir=rtl]{padding-left:0;padding-right:0}.mdc-select .mdc-select__icon{width:24px;height:24px;font-size:24px}.mdc-select .mdc-select__dropdown-icon{width:24px;height:24px}.mdc-select .mdc-select__menu .mdc-deprecated-list-item{padding-left:16px;padding-right:16px}[dir=rtl] .mdc-select .mdc-select__menu .mdc-deprecated-list-item,.mdc-select .mdc-select__menu .mdc-deprecated-list-item[dir=rtl]{padding-left:16px;padding-right:16px}.mdc-select .mdc-select__menu .mdc-deprecated-list-item__graphic{margin-left:0;margin-right:12px}[dir=rtl] .mdc-select .mdc-select__menu .mdc-deprecated-list-item__graphic,.mdc-select .mdc-select__menu .mdc-deprecated-list-item__graphic[dir=rtl]{margin-left:12px;margin-right:0}.mdc-select__dropdown-icon{margin-left:12px;margin-right:12px;display:inline-flex;position:relative;align-self:center;align-items:center;justify-content:center;flex-shrink:0;pointer-events:none}.mdc-select__dropdown-icon .mdc-select__dropdown-icon-active,.mdc-select__dropdown-icon .mdc-select__dropdown-icon-inactive{position:absolute;top:0;left:0}.mdc-select__dropdown-icon .mdc-select__dropdown-icon-graphic{width:41.6666666667%;height:20.8333333333%}.mdc-select__dropdown-icon .mdc-select__dropdown-icon-inactive{opacity:1;transition:opacity 75ms linear 75ms}.mdc-select__dropdown-icon .mdc-select__dropdown-icon-active{opacity:0;transition:opacity 75ms linear}[dir=rtl] .mdc-select__dropdown-icon,.mdc-select__dropdown-icon[dir=rtl]{margin-left:12px;margin-right:12px}.mdc-select--activated .mdc-select__dropdown-icon .mdc-select__dropdown-icon-inactive{opacity:0;transition:opacity 49.5ms linear}.mdc-select--activated .mdc-select__dropdown-icon .mdc-select__dropdown-icon-active{opacity:1;transition:opacity 100.5ms linear 49.5ms}.mdc-select__anchor{width:200px;min-width:0;flex:1 1 auto;position:relative;box-sizing:border-box;overflow:hidden;outline:none;cursor:pointer}.mdc-select__anchor .mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-select__selected-text-container{display:flex;appearance:none;pointer-events:none;box-sizing:border-box;width:auto;min-width:0;flex-grow:1;height:28px;border:none;outline:none;padding:0;background-color:transparent;color:inherit}.mdc-select__selected-text{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:1rem;font-size:var(--mdc-typography-subtitle1-font-size, 1rem);line-height:1.75rem;line-height:var(--mdc-typography-subtitle1-line-height, 1.75rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);text-overflow:ellipsis;white-space:nowrap;overflow:hidden;display:block;width:100%;text-align:left}[dir=rtl] .mdc-select__selected-text,.mdc-select__selected-text[dir=rtl]{text-align:right}.mdc-select--invalid:not(.mdc-select--disabled) .mdc-floating-label{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-floating-label{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--invalid+.mdc-select-helper-text--validation-msg{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled) .mdc-select__dropdown-icon{fill:#b00020;fill:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-select__dropdown-icon{fill:#b00020;fill:var(--mdc-theme-error, #b00020)}.mdc-select--disabled{cursor:default;pointer-events:none}.mdc-select--with-leading-icon .mdc-select__menu .mdc-deprecated-list-item{padding-left:12px;padding-right:12px}[dir=rtl] .mdc-select--with-leading-icon .mdc-select__menu .mdc-deprecated-list-item,.mdc-select--with-leading-icon .mdc-select__menu .mdc-deprecated-list-item[dir=rtl]{padding-left:12px;padding-right:12px}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-select__menu::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid transparent;border-radius:inherit;content:"";pointer-events:none}}@media screen and (forced-colors: active)and (forced-colors: active),screen and (-ms-high-contrast: active)and (forced-colors: active){.mdc-select__menu::before{border-color:CanvasText}}.mdc-select__menu .mdc-deprecated-list .mdc-select__icon,.mdc-select__menu .mdc-list .mdc-select__icon{margin-left:0;margin-right:0}[dir=rtl] .mdc-select__menu .mdc-deprecated-list .mdc-select__icon,[dir=rtl] .mdc-select__menu .mdc-list .mdc-select__icon,.mdc-select__menu .mdc-deprecated-list .mdc-select__icon[dir=rtl],.mdc-select__menu .mdc-list .mdc-select__icon[dir=rtl]{margin-left:0;margin-right:0}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--activated,.mdc-select__menu .mdc-list .mdc-deprecated-list-item--selected,.mdc-select__menu .mdc-list .mdc-deprecated-list-item--activated{color:#000;color:var(--mdc-theme-on-surface, #000)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-deprecated-list-item__graphic,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--activated .mdc-deprecated-list-item__graphic,.mdc-select__menu .mdc-list .mdc-deprecated-list-item--selected .mdc-deprecated-list-item__graphic,.mdc-select__menu .mdc-list .mdc-deprecated-list-item--activated .mdc-deprecated-list-item__graphic{color:#000;color:var(--mdc-theme-on-surface, #000)}.mdc-select__menu .mdc-list-item__start{display:inline-flex;align-items:center}.mdc-select__option{padding-left:16px;padding-right:16px}[dir=rtl] .mdc-select__option,.mdc-select__option[dir=rtl]{padding-left:16px;padding-right:16px}.mdc-select__one-line-option.mdc-list-item--with-one-line{height:48px}.mdc-select__two-line-option.mdc-list-item--with-two-lines{height:64px}.mdc-select__two-line-option.mdc-list-item--with-two-lines .mdc-list-item__start{margin-top:20px}.mdc-select__two-line-option.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-select__two-line-option.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-select__two-line-option.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-select__two-line-option.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-select__two-line-option.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:36px;content:"";vertical-align:0}.mdc-select__option-with-leading-content{padding-left:0;padding-right:12px}.mdc-select__option-with-leading-content.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-select__option-with-leading-content.mdc-list-item,.mdc-select__option-with-leading-content.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-select__option-with-leading-content .mdc-list-item__start{margin-left:12px;margin-right:0}[dir=rtl] .mdc-select__option-with-leading-content .mdc-list-item__start,.mdc-select__option-with-leading-content .mdc-list-item__start[dir=rtl]{margin-left:0;margin-right:12px}.mdc-select__option-with-leading-content .mdc-list-item__start{width:36px;height:24px}[dir=rtl] .mdc-select__option-with-leading-content,.mdc-select__option-with-leading-content[dir=rtl]{padding-left:12px;padding-right:0}.mdc-select__option-with-meta.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-select__option-with-meta.mdc-list-item,.mdc-select__option-with-meta.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-select__option-with-meta .mdc-list-item__end{margin-left:12px;margin-right:12px}[dir=rtl] .mdc-select__option-with-meta .mdc-list-item__end,.mdc-select__option-with-meta .mdc-list-item__end[dir=rtl]{margin-left:12px;margin-right:12px}.mdc-select--filled .mdc-select__anchor{height:56px;display:flex;align-items:baseline}.mdc-select--filled .mdc-select__anchor::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}.mdc-select--filled.mdc-select--no-label .mdc-select__anchor .mdc-select__selected-text::before{content:"​"}.mdc-select--filled.mdc-select--no-label .mdc-select__anchor .mdc-select__selected-text-container{height:100%;display:inline-flex;align-items:center}.mdc-select--filled.mdc-select--no-label .mdc-select__anchor::before{display:none}.mdc-select--filled .mdc-select__anchor{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:0;border-bottom-left-radius:0}.mdc-select--filled:not(.mdc-select--disabled) .mdc-select__anchor{background-color:whitesmoke}.mdc-select--filled.mdc-select--disabled .mdc-select__anchor{background-color:#fafafa}.mdc-select--filled:not(.mdc-select--disabled) .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.42)}.mdc-select--filled:not(.mdc-select--disabled):hover .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.87)}.mdc-select--filled:not(.mdc-select--disabled) .mdc-line-ripple::after{border-bottom-color:#6200ee;border-bottom-color:var(--mdc-theme-primary, #6200ee)}.mdc-select--filled.mdc-select--disabled .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.06)}.mdc-select--filled .mdc-floating-label{max-width:calc(100% - 64px)}.mdc-select--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 64px / 0.75)}.mdc-select--filled .mdc-menu-surface--is-open-below{border-top-left-radius:0px;border-top-right-radius:0px}.mdc-select--filled.mdc-select--focused.mdc-line-ripple::after{transform:scale(1, 2);opacity:1}.mdc-select--filled .mdc-floating-label{left:16px;right:initial}[dir=rtl] .mdc-select--filled .mdc-floating-label,.mdc-select--filled .mdc-floating-label[dir=rtl]{left:initial;right:16px}.mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label{left:48px;right:initial}[dir=rtl] .mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label,.mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label[dir=rtl]{left:initial;right:48px}.mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label{max-width:calc(100% - 96px)}.mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 96px / 0.75)}.mdc-select--invalid:not(.mdc-select--disabled) .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled):hover .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled) .mdc-line-ripple::after{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-select--outlined{border:none}.mdc-select--outlined .mdc-select__anchor{height:56px}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1)}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--float-above{font-size:.75rem}.mdc-select--outlined .mdc-select__anchor.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-select--outlined .mdc-select__anchor.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-select-outlined-56px 250ms 1}@keyframes mdc-floating-label-shake-float-above-select-outlined-56px{0%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}}.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__leading{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:4px;border-bottom-left-radius:var(--mdc-shape-small, 4px)}[dir=rtl] .mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__leading[dir=rtl]{border-top-left-radius:0;border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:4px;border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}@supports(top: max(0%)){.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__leading{width:max(12px, var(--mdc-shape-small, 4px))}}@supports(top: max(0%)){.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__notch{max-width:calc(100% - max(12px, var(--mdc-shape-small, 4px)) * 2)}}.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__trailing{border-top-left-radius:0;border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:4px;border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}[dir=rtl] .mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__trailing,.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__trailing[dir=rtl]{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:4px;border-bottom-left-radius:var(--mdc-shape-small, 4px)}@supports(top: max(0%)){.mdc-select--outlined .mdc-select__anchor{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}[dir=rtl] .mdc-select--outlined .mdc-select__anchor,.mdc-select--outlined .mdc-select__anchor[dir=rtl]{padding-left:0}@supports(top: max(0%)){[dir=rtl] .mdc-select--outlined .mdc-select__anchor,.mdc-select--outlined .mdc-select__anchor[dir=rtl]{padding-right:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}@supports(top: max(0%)){.mdc-select--outlined+.mdc-select-helper-text{margin-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}[dir=rtl] .mdc-select--outlined+.mdc-select-helper-text,.mdc-select--outlined+.mdc-select-helper-text[dir=rtl]{margin-left:0}@supports(top: max(0%)){[dir=rtl] .mdc-select--outlined+.mdc-select-helper-text,.mdc-select--outlined+.mdc-select-helper-text[dir=rtl]{margin-right:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}.mdc-select--outlined:not(.mdc-select--disabled) .mdc-select__anchor{background-color:transparent}.mdc-select--outlined.mdc-select--disabled .mdc-select__anchor{background-color:transparent}.mdc-select--outlined:not(.mdc-select--disabled) .mdc-notched-outline__leading,.mdc-select--outlined:not(.mdc-select--disabled) .mdc-notched-outline__notch,.mdc-select--outlined:not(.mdc-select--disabled) .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.38)}.mdc-select--outlined:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.87)}.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__trailing{border-width:2px}.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__trailing{border-color:#6200ee;border-color:var(--mdc-theme-primary, #6200ee)}.mdc-select--outlined.mdc-select--disabled .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--disabled .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--disabled .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.06)}.mdc-select--outlined .mdc-select__anchor :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mdc-select--outlined .mdc-select__anchor{display:flex;align-items:baseline;overflow:visible}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-select-outlined 250ms 1}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1)}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--float-above{font-size:.75rem}.mdc-select--outlined .mdc-select__anchor.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-select--outlined .mdc-select__anchor.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:1px}.mdc-select--outlined .mdc-select__anchor .mdc-select__selected-text::before{content:"​"}.mdc-select--outlined .mdc-select__anchor .mdc-select__selected-text-container{height:100%;display:inline-flex;align-items:center}.mdc-select--outlined .mdc-select__anchor::before{display:none}.mdc-select--outlined .mdc-select__selected-text-container{display:flex;border:none;z-index:1;background-color:transparent}.mdc-select--outlined .mdc-select__icon{z-index:2}.mdc-select--outlined .mdc-floating-label{line-height:1.15rem;left:4px;right:initial}[dir=rtl] .mdc-select--outlined .mdc-floating-label,.mdc-select--outlined .mdc-floating-label[dir=rtl]{left:initial;right:4px}.mdc-select--outlined.mdc-select--focused .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:2px}.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled) .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled) .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled) .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__trailing{border-width:2px}.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label{left:36px;right:initial}[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label,.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label[dir=rtl]{left:initial;right:36px}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--float-above{transform:translateY(-37.25px) translateX(-32px) scale(1)}[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--float-above,.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-37.25px) translateX(32px) scale(1)}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--float-above{font-size:.75rem}.mdc-select--outlined.mdc-select--with-leading-icon.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined.mdc-select--with-leading-icon .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) translateX(-32px) scale(0.75)}[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon.mdc-notched-outline--upgraded .mdc-floating-label--float-above,[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon .mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined.mdc-select--with-leading-icon.mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl],.mdc-select--outlined.mdc-select--with-leading-icon .mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-34.75px) translateX(32px) scale(0.75)}.mdc-select--outlined.mdc-select--with-leading-icon.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined.mdc-select--with-leading-icon .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-select-outlined-leading-icon-56px 250ms 1}@keyframes mdc-floating-label-shake-float-above-select-outlined-leading-icon-56px{0%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}}[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--shake,.mdc-select--outlined.mdc-select--with-leading-icon[dir=rtl] .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-select-outlined-leading-icon-56px 250ms 1}@keyframes mdc-floating-label-shake-float-above-select-outlined-leading-icon-56px-rtl{0%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - -32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - -32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-select__anchor :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 96px)}.mdc-select--outlined .mdc-menu-surface{margin-bottom:8px}.mdc-select--outlined.mdc-select--no-label .mdc-menu-surface,.mdc-select--outlined .mdc-menu-surface--is-open-below{margin-bottom:0}.mdc-select__anchor{--mdc-ripple-fg-size: 0;--mdc-ripple-left: 0;--mdc-ripple-top: 0;--mdc-ripple-fg-scale: 1;--mdc-ripple-fg-translate-end: 0;--mdc-ripple-fg-translate-start: 0;-webkit-tap-highlight-color:rgba(0,0,0,0);will-change:transform,opacity}.mdc-select__anchor .mdc-select__ripple::before,.mdc-select__anchor .mdc-select__ripple::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.mdc-select__anchor .mdc-select__ripple::before{transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-select__anchor .mdc-select__ripple::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-select__anchor.mdc-ripple-upgraded .mdc-select__ripple::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-select__anchor.mdc-ripple-upgraded .mdc-select__ripple::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-select__anchor.mdc-ripple-upgraded--unbounded .mdc-select__ripple::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-select__anchor.mdc-ripple-upgraded--foreground-activation .mdc-select__ripple::after{animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.mdc-select__anchor.mdc-ripple-upgraded--foreground-deactivation .mdc-select__ripple::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-select__anchor .mdc-select__ripple::before,.mdc-select__anchor .mdc-select__ripple::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-select__anchor.mdc-ripple-upgraded .mdc-select__ripple::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-select__anchor .mdc-select__ripple::before,.mdc-select__anchor .mdc-select__ripple::after{background-color:rgba(0, 0, 0, 0.87);background-color:var(--mdc-ripple-color, rgba(0, 0, 0, 0.87))}.mdc-select__anchor:hover .mdc-select__ripple::before,.mdc-select__anchor.mdc-ripple-surface--hover .mdc-select__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-select__anchor.mdc-ripple-upgraded--background-focused .mdc-select__ripple::before,.mdc-select__anchor:not(.mdc-ripple-upgraded):focus .mdc-select__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-select__anchor .mdc-select__ripple{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-deprecated-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-deprecated-list-item__ripple::after{background-color:#000;background-color:var(--mdc-ripple-color, var(--mdc-theme-on-surface, #000))}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:hover .mdc-deprecated-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-surface--hover .mdc-deprecated-list-item__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-upgraded--background-focused .mdc-deprecated-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded):focus .mdc-deprecated-list-item__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded) .mdc-deprecated-list-item__ripple::after{transition:opacity 150ms linear}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded):active .mdc-deprecated-list-item__ripple::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-list-item__ripple::after{background-color:#000;background-color:var(--mdc-ripple-color, var(--mdc-theme-on-surface, #000))}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:hover .mdc-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-surface--hover .mdc-list-item__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-upgraded--background-focused .mdc-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded):focus .mdc-list-item__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded) .mdc-list-item__ripple::after{transition:opacity 150ms linear}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded):active .mdc-list-item__ripple::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-select-helper-text{margin:0;margin-left:16px;margin-right:16px;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.75rem;font-size:var(--mdc-typography-caption-font-size, 0.75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight, 400);letter-spacing:0.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, 0.0333333333em);text-decoration:inherit;text-decoration:var(--mdc-typography-caption-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform, inherit);display:block;margin-top:0;line-height:normal}[dir=rtl] .mdc-select-helper-text,.mdc-select-helper-text[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-select-helper-text::before{display:inline-block;width:0;height:16px;content:"";vertical-align:0}.mdc-select-helper-text--validation-msg{opacity:0;transition:opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-select--invalid+.mdc-select-helper-text--validation-msg,.mdc-select-helper-text--validation-msg-persistent{opacity:1}.mdc-select--with-leading-icon .mdc-select__icon{display:inline-block;box-sizing:border-box;border:none;text-decoration:none;cursor:pointer;user-select:none;flex-shrink:0;align-self:center;background-color:transparent;fill:currentColor}.mdc-select--with-leading-icon .mdc-select__icon{margin-left:12px;margin-right:12px}[dir=rtl] .mdc-select--with-leading-icon .mdc-select__icon,.mdc-select--with-leading-icon .mdc-select__icon[dir=rtl]{margin-left:12px;margin-right:12px}.mdc-select__icon:not([tabindex]),.mdc-select__icon[tabindex="-1"]{cursor:default;pointer-events:none}.material-icons{font-family:var(--mdc-icon-font, "Material Icons");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:"liga"}:host{display:inline-block;vertical-align:top;outline:none}.mdc-select{width:100%}[hidden]{display:none}.mdc-select__icon{z-index:2}.mdc-select--with-leading-icon{--mdc-list-item-graphic-margin: calc( 48px - var(--mdc-list-item-graphic-size, 24px) - var(--mdc-list-side-padding, 16px) )}.mdc-select .mdc-select__anchor .mdc-select__selected-text{overflow:hidden}.mdc-select .mdc-select__anchor *{display:inline-flex}.mdc-select .mdc-select__anchor .mdc-floating-label{display:inline-block}mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-select-outlined-idle-border-color, rgba(0, 0, 0, 0.38) );--mdc-notched-outline-notch-offset: 1px}:host(:not([disabled]):hover) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-select-outlined-hover-border-color, rgba(0, 0, 0, 0.87) )}:host(:not([disabled])) .mdc-select:not(.mdc-select--disabled) .mdc-select__selected-text{color:rgba(0, 0, 0, 0.87);color:var(--mdc-select-ink-color, rgba(0, 0, 0, 0.87))}:host(:not([disabled])) .mdc-select:not(.mdc-select--disabled) .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.42);border-bottom-color:var(--mdc-select-idle-line-color, rgba(0, 0, 0, 0.42))}:host(:not([disabled])) .mdc-select:not(.mdc-select--disabled):hover .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.87);border-bottom-color:var(--mdc-select-hover-line-color, rgba(0, 0, 0, 0.87))}:host(:not([disabled])) .mdc-select:not(.mdc-select--outlined):not(.mdc-select--disabled) .mdc-select__anchor{background-color:whitesmoke;background-color:var(--mdc-select-fill-color, whitesmoke)}:host(:not([disabled])) .mdc-select.mdc-select--invalid .mdc-select__dropdown-icon{fill:var(--mdc-select-error-dropdown-icon-color, var(--mdc-select-error-color, var(--mdc-theme-error, #b00020)))}:host(:not([disabled])) .mdc-select.mdc-select--invalid .mdc-floating-label,:host(:not([disabled])) .mdc-select.mdc-select--invalid .mdc-floating-label::after{color:var(--mdc-select-error-color, var(--mdc-theme-error, #b00020))}:host(:not([disabled])) .mdc-select.mdc-select--invalid mwc-notched-outline{--mdc-notched-outline-border-color: var(--mdc-select-error-color, var(--mdc-theme-error, #b00020))}.mdc-select__menu--invalid{--mdc-theme-primary: var(--mdc-select-error-color, var(--mdc-theme-error, #b00020))}:host(:not([disabled])) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-floating-label,:host(:not([disabled])) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-floating-label::after{color:rgba(0, 0, 0, 0.6);color:var(--mdc-select-label-ink-color, rgba(0, 0, 0, 0.6))}:host(:not([disabled])) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-select__dropdown-icon{fill:rgba(0, 0, 0, 0.54);fill:var(--mdc-select-dropdown-icon-color, rgba(0, 0, 0, 0.54))}:host(:not([disabled])) .mdc-select.mdc-select--focused mwc-notched-outline{--mdc-notched-outline-stroke-width: 2px;--mdc-notched-outline-notch-offset: 2px}:host(:not([disabled])) .mdc-select.mdc-select--focused:not(.mdc-select--invalid) mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-select-focused-label-color, var(--mdc-theme-primary, rgba(98, 0, 238, 0.87)) )}:host(:not([disabled])) .mdc-select.mdc-select--focused:not(.mdc-select--invalid) .mdc-select__dropdown-icon{fill:rgba(98,0,238,.87);fill:var(--mdc-select-focused-dropdown-icon-color, var(--mdc-theme-primary, rgba(98, 0, 238, 0.87)))}:host(:not([disabled])) .mdc-select.mdc-select--focused:not(.mdc-select--invalid) .mdc-floating-label{color:#6200ee;color:var(--mdc-theme-primary, #6200ee)}:host(:not([disabled])) .mdc-select.mdc-select--focused:not(.mdc-select--invalid) .mdc-floating-label::after{color:#6200ee;color:var(--mdc-theme-primary, #6200ee)}:host(:not([disabled])) .mdc-select-helper-text:not(.mdc-select-helper-text--validation-msg){color:var(--mdc-select-label-ink-color, rgba(0, 0, 0, 0.6))}:host([disabled]){pointer-events:none}:host([disabled]) .mdc-select:not(.mdc-select--outlined).mdc-select--disabled .mdc-select__anchor{background-color:#fafafa;background-color:var(--mdc-select-disabled-fill-color, #fafafa)}:host([disabled]) .mdc-select.mdc-select--outlined mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-select-outlined-disabled-border-color, rgba(0, 0, 0, 0.06) )}:host([disabled]) .mdc-select .mdc-select__dropdown-icon{fill:rgba(0, 0, 0, 0.38);fill:var(--mdc-select-disabled-dropdown-icon-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-floating-label,:host([disabled]) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-floating-label::after{color:rgba(0, 0, 0, 0.38);color:var(--mdc-select-disabled-ink-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-select-helper-text{color:rgba(0, 0, 0, 0.38);color:var(--mdc-select-disabled-ink-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-select__selected-text{color:rgba(0, 0, 0, 0.38);color:var(--mdc-select-disabled-ink-color, rgba(0, 0, 0, 0.38))}`;
-
-let PoLRSelect = class PoLRSelect extends SelectBase {
-};
-PoLRSelect.styles = [
- styles$6,
- i$5 `
+const Ze=s`.mdc-floating-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:1rem;font-size:var(--mdc-typography-subtitle1-font-size, 1rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);position:absolute;left:0;-webkit-transform-origin:left top;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform;transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1),color 150ms cubic-bezier(0.4, 0, 0.2, 1)}[dir=rtl] .mdc-floating-label,.mdc-floating-label[dir=rtl]{right:0;left:auto;-webkit-transform-origin:right top;transform-origin:right top;text-align:right}.mdc-floating-label--float-above{cursor:auto}.mdc-floating-label--required::after{margin-left:1px;margin-right:0px;content:"*"}[dir=rtl] .mdc-floating-label--required::after,.mdc-floating-label--required[dir=rtl]::after{margin-left:0;margin-right:1px}.mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-standard 250ms 1}@keyframes mdc-floating-label-shake-float-above-standard{0%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-106%) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-106%) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}}@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-line-ripple::before,.mdc-line-ripple::after{position:absolute;bottom:0;left:0;width:100%;border-bottom-style:solid;content:""}.mdc-line-ripple::before{border-bottom-width:1px}.mdc-line-ripple::before{z-index:1}.mdc-line-ripple::after{transform:scaleX(0);border-bottom-width:2px;opacity:0;z-index:2}.mdc-line-ripple::after{transition:transform 180ms cubic-bezier(0.4, 0, 0.2, 1),opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-line-ripple--active::after{transform:scaleX(1);opacity:1}.mdc-line-ripple--deactivating::after{opacity:0}.mdc-notched-outline{display:flex;position:absolute;top:0;right:0;left:0;box-sizing:border-box;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}[dir=rtl] .mdc-notched-outline,.mdc-notched-outline[dir=rtl]{text-align:right}.mdc-notched-outline__leading,.mdc-notched-outline__notch,.mdc-notched-outline__trailing{box-sizing:border-box;height:100%;border-top:1px solid;border-bottom:1px solid;pointer-events:none}.mdc-notched-outline__leading{border-left:1px solid;border-right:none;width:12px}[dir=rtl] .mdc-notched-outline__leading,.mdc-notched-outline__leading[dir=rtl]{border-left:none;border-right:1px solid}.mdc-notched-outline__trailing{border-left:none;border-right:1px solid;flex-grow:1}[dir=rtl] .mdc-notched-outline__trailing,.mdc-notched-outline__trailing[dir=rtl]{border-left:1px solid;border-right:none}.mdc-notched-outline__notch{flex:0 0 auto;width:auto;max-width:calc(100% - 12px * 2)}.mdc-notched-outline .mdc-floating-label{display:inline-block;position:relative;max-width:100%}.mdc-notched-outline .mdc-floating-label--float-above{text-overflow:clip}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:calc(100% / 0.75)}.mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:0;padding-right:8px;border-top:none}[dir=rtl] .mdc-notched-outline--notched .mdc-notched-outline__notch,.mdc-notched-outline--notched .mdc-notched-outline__notch[dir=rtl]{padding-left:8px;padding-right:0}.mdc-notched-outline--no-label .mdc-notched-outline__notch{display:none}.mdc-select{display:inline-flex;position:relative}.mdc-select:not(.mdc-select--disabled) .mdc-select__selected-text{color:rgba(0, 0, 0, 0.87)}.mdc-select.mdc-select--disabled .mdc-select__selected-text{color:rgba(0, 0, 0, 0.38)}.mdc-select:not(.mdc-select--disabled) .mdc-floating-label{color:rgba(0, 0, 0, 0.6)}.mdc-select:not(.mdc-select--disabled).mdc-select--focused .mdc-floating-label{color:rgba(98, 0, 238, 0.87)}.mdc-select.mdc-select--disabled .mdc-floating-label{color:rgba(0, 0, 0, 0.38)}.mdc-select:not(.mdc-select--disabled) .mdc-select__dropdown-icon{fill:rgba(0, 0, 0, 0.54)}.mdc-select:not(.mdc-select--disabled).mdc-select--focused .mdc-select__dropdown-icon{fill:#6200ee;fill:var(--mdc-theme-primary, #6200ee)}.mdc-select.mdc-select--disabled .mdc-select__dropdown-icon{fill:rgba(0, 0, 0, 0.38)}.mdc-select:not(.mdc-select--disabled)+.mdc-select-helper-text{color:rgba(0, 0, 0, 0.6)}.mdc-select.mdc-select--disabled+.mdc-select-helper-text{color:rgba(0, 0, 0, 0.38)}.mdc-select:not(.mdc-select--disabled) .mdc-select__icon{color:rgba(0, 0, 0, 0.54)}.mdc-select.mdc-select--disabled .mdc-select__icon{color:rgba(0, 0, 0, 0.38)}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-select.mdc-select--disabled .mdc-select__selected-text{color:GrayText}.mdc-select.mdc-select--disabled .mdc-select__dropdown-icon{fill:red}.mdc-select.mdc-select--disabled .mdc-floating-label{color:GrayText}.mdc-select.mdc-select--disabled .mdc-line-ripple::before{border-bottom-color:GrayText}.mdc-select.mdc-select--disabled .mdc-notched-outline__leading,.mdc-select.mdc-select--disabled .mdc-notched-outline__notch,.mdc-select.mdc-select--disabled .mdc-notched-outline__trailing{border-color:GrayText}.mdc-select.mdc-select--disabled .mdc-select__icon{color:GrayText}.mdc-select.mdc-select--disabled+.mdc-select-helper-text{color:GrayText}}.mdc-select .mdc-floating-label{top:50%;transform:translateY(-50%);pointer-events:none}.mdc-select .mdc-select__anchor{padding-left:16px;padding-right:0}[dir=rtl] .mdc-select .mdc-select__anchor,.mdc-select .mdc-select__anchor[dir=rtl]{padding-left:0;padding-right:16px}.mdc-select.mdc-select--with-leading-icon .mdc-select__anchor{padding-left:0;padding-right:0}[dir=rtl] .mdc-select.mdc-select--with-leading-icon .mdc-select__anchor,.mdc-select.mdc-select--with-leading-icon .mdc-select__anchor[dir=rtl]{padding-left:0;padding-right:0}.mdc-select .mdc-select__icon{width:24px;height:24px;font-size:24px}.mdc-select .mdc-select__dropdown-icon{width:24px;height:24px}.mdc-select .mdc-select__menu .mdc-deprecated-list-item{padding-left:16px;padding-right:16px}[dir=rtl] .mdc-select .mdc-select__menu .mdc-deprecated-list-item,.mdc-select .mdc-select__menu .mdc-deprecated-list-item[dir=rtl]{padding-left:16px;padding-right:16px}.mdc-select .mdc-select__menu .mdc-deprecated-list-item__graphic{margin-left:0;margin-right:12px}[dir=rtl] .mdc-select .mdc-select__menu .mdc-deprecated-list-item__graphic,.mdc-select .mdc-select__menu .mdc-deprecated-list-item__graphic[dir=rtl]{margin-left:12px;margin-right:0}.mdc-select__dropdown-icon{margin-left:12px;margin-right:12px;display:inline-flex;position:relative;align-self:center;align-items:center;justify-content:center;flex-shrink:0;pointer-events:none}.mdc-select__dropdown-icon .mdc-select__dropdown-icon-active,.mdc-select__dropdown-icon .mdc-select__dropdown-icon-inactive{position:absolute;top:0;left:0}.mdc-select__dropdown-icon .mdc-select__dropdown-icon-graphic{width:41.6666666667%;height:20.8333333333%}.mdc-select__dropdown-icon .mdc-select__dropdown-icon-inactive{opacity:1;transition:opacity 75ms linear 75ms}.mdc-select__dropdown-icon .mdc-select__dropdown-icon-active{opacity:0;transition:opacity 75ms linear}[dir=rtl] .mdc-select__dropdown-icon,.mdc-select__dropdown-icon[dir=rtl]{margin-left:12px;margin-right:12px}.mdc-select--activated .mdc-select__dropdown-icon .mdc-select__dropdown-icon-inactive{opacity:0;transition:opacity 49.5ms linear}.mdc-select--activated .mdc-select__dropdown-icon .mdc-select__dropdown-icon-active{opacity:1;transition:opacity 100.5ms linear 49.5ms}.mdc-select__anchor{width:200px;min-width:0;flex:1 1 auto;position:relative;box-sizing:border-box;overflow:hidden;outline:none;cursor:pointer}.mdc-select__anchor .mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-select__selected-text-container{display:flex;appearance:none;pointer-events:none;box-sizing:border-box;width:auto;min-width:0;flex-grow:1;height:28px;border:none;outline:none;padding:0;background-color:transparent;color:inherit}.mdc-select__selected-text{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:1rem;font-size:var(--mdc-typography-subtitle1-font-size, 1rem);line-height:1.75rem;line-height:var(--mdc-typography-subtitle1-line-height, 1.75rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);text-overflow:ellipsis;white-space:nowrap;overflow:hidden;display:block;width:100%;text-align:left}[dir=rtl] .mdc-select__selected-text,.mdc-select__selected-text[dir=rtl]{text-align:right}.mdc-select--invalid:not(.mdc-select--disabled) .mdc-floating-label{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-floating-label{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--invalid+.mdc-select-helper-text--validation-msg{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled) .mdc-select__dropdown-icon{fill:#b00020;fill:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-select__dropdown-icon{fill:#b00020;fill:var(--mdc-theme-error, #b00020)}.mdc-select--disabled{cursor:default;pointer-events:none}.mdc-select--with-leading-icon .mdc-select__menu .mdc-deprecated-list-item{padding-left:12px;padding-right:12px}[dir=rtl] .mdc-select--with-leading-icon .mdc-select__menu .mdc-deprecated-list-item,.mdc-select--with-leading-icon .mdc-select__menu .mdc-deprecated-list-item[dir=rtl]{padding-left:12px;padding-right:12px}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-select__menu::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid transparent;border-radius:inherit;content:"";pointer-events:none}}@media screen and (forced-colors: active)and (forced-colors: active),screen and (-ms-high-contrast: active)and (forced-colors: active){.mdc-select__menu::before{border-color:CanvasText}}.mdc-select__menu .mdc-deprecated-list .mdc-select__icon,.mdc-select__menu .mdc-list .mdc-select__icon{margin-left:0;margin-right:0}[dir=rtl] .mdc-select__menu .mdc-deprecated-list .mdc-select__icon,[dir=rtl] .mdc-select__menu .mdc-list .mdc-select__icon,.mdc-select__menu .mdc-deprecated-list .mdc-select__icon[dir=rtl],.mdc-select__menu .mdc-list .mdc-select__icon[dir=rtl]{margin-left:0;margin-right:0}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--activated,.mdc-select__menu .mdc-list .mdc-deprecated-list-item--selected,.mdc-select__menu .mdc-list .mdc-deprecated-list-item--activated{color:#000;color:var(--mdc-theme-on-surface, #000)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-deprecated-list-item__graphic,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--activated .mdc-deprecated-list-item__graphic,.mdc-select__menu .mdc-list .mdc-deprecated-list-item--selected .mdc-deprecated-list-item__graphic,.mdc-select__menu .mdc-list .mdc-deprecated-list-item--activated .mdc-deprecated-list-item__graphic{color:#000;color:var(--mdc-theme-on-surface, #000)}.mdc-select__menu .mdc-list-item__start{display:inline-flex;align-items:center}.mdc-select__option{padding-left:16px;padding-right:16px}[dir=rtl] .mdc-select__option,.mdc-select__option[dir=rtl]{padding-left:16px;padding-right:16px}.mdc-select__one-line-option.mdc-list-item--with-one-line{height:48px}.mdc-select__two-line-option.mdc-list-item--with-two-lines{height:64px}.mdc-select__two-line-option.mdc-list-item--with-two-lines .mdc-list-item__start{margin-top:20px}.mdc-select__two-line-option.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-select__two-line-option.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-select__two-line-option.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-select__two-line-option.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-select__two-line-option.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:36px;content:"";vertical-align:0}.mdc-select__option-with-leading-content{padding-left:0;padding-right:12px}.mdc-select__option-with-leading-content.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-select__option-with-leading-content.mdc-list-item,.mdc-select__option-with-leading-content.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-select__option-with-leading-content .mdc-list-item__start{margin-left:12px;margin-right:0}[dir=rtl] .mdc-select__option-with-leading-content .mdc-list-item__start,.mdc-select__option-with-leading-content .mdc-list-item__start[dir=rtl]{margin-left:0;margin-right:12px}.mdc-select__option-with-leading-content .mdc-list-item__start{width:36px;height:24px}[dir=rtl] .mdc-select__option-with-leading-content,.mdc-select__option-with-leading-content[dir=rtl]{padding-left:12px;padding-right:0}.mdc-select__option-with-meta.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-select__option-with-meta.mdc-list-item,.mdc-select__option-with-meta.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-select__option-with-meta .mdc-list-item__end{margin-left:12px;margin-right:12px}[dir=rtl] .mdc-select__option-with-meta .mdc-list-item__end,.mdc-select__option-with-meta .mdc-list-item__end[dir=rtl]{margin-left:12px;margin-right:12px}.mdc-select--filled .mdc-select__anchor{height:56px;display:flex;align-items:baseline}.mdc-select--filled .mdc-select__anchor::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}.mdc-select--filled.mdc-select--no-label .mdc-select__anchor .mdc-select__selected-text::before{content:"​"}.mdc-select--filled.mdc-select--no-label .mdc-select__anchor .mdc-select__selected-text-container{height:100%;display:inline-flex;align-items:center}.mdc-select--filled.mdc-select--no-label .mdc-select__anchor::before{display:none}.mdc-select--filled .mdc-select__anchor{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:0;border-bottom-left-radius:0}.mdc-select--filled:not(.mdc-select--disabled) .mdc-select__anchor{background-color:whitesmoke}.mdc-select--filled.mdc-select--disabled .mdc-select__anchor{background-color:#fafafa}.mdc-select--filled:not(.mdc-select--disabled) .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.42)}.mdc-select--filled:not(.mdc-select--disabled):hover .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.87)}.mdc-select--filled:not(.mdc-select--disabled) .mdc-line-ripple::after{border-bottom-color:#6200ee;border-bottom-color:var(--mdc-theme-primary, #6200ee)}.mdc-select--filled.mdc-select--disabled .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.06)}.mdc-select--filled .mdc-floating-label{max-width:calc(100% - 64px)}.mdc-select--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 64px / 0.75)}.mdc-select--filled .mdc-menu-surface--is-open-below{border-top-left-radius:0px;border-top-right-radius:0px}.mdc-select--filled.mdc-select--focused.mdc-line-ripple::after{transform:scale(1, 2);opacity:1}.mdc-select--filled .mdc-floating-label{left:16px;right:initial}[dir=rtl] .mdc-select--filled .mdc-floating-label,.mdc-select--filled .mdc-floating-label[dir=rtl]{left:initial;right:16px}.mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label{left:48px;right:initial}[dir=rtl] .mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label,.mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label[dir=rtl]{left:initial;right:48px}.mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label{max-width:calc(100% - 96px)}.mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 96px / 0.75)}.mdc-select--invalid:not(.mdc-select--disabled) .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled):hover .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-select--invalid:not(.mdc-select--disabled) .mdc-line-ripple::after{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-select--outlined{border:none}.mdc-select--outlined .mdc-select__anchor{height:56px}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1)}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--float-above{font-size:.75rem}.mdc-select--outlined .mdc-select__anchor.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-select--outlined .mdc-select__anchor.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-select-outlined-56px 250ms 1}@keyframes mdc-floating-label-shake-float-above-select-outlined-56px{0%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}}.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__leading{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:4px;border-bottom-left-radius:var(--mdc-shape-small, 4px)}[dir=rtl] .mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__leading[dir=rtl]{border-top-left-radius:0;border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:4px;border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}@supports(top: max(0%)){.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__leading{width:max(12px, var(--mdc-shape-small, 4px))}}@supports(top: max(0%)){.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__notch{max-width:calc(100% - max(12px, var(--mdc-shape-small, 4px)) * 2)}}.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__trailing{border-top-left-radius:0;border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:4px;border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}[dir=rtl] .mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__trailing,.mdc-select--outlined .mdc-notched-outline .mdc-notched-outline__trailing[dir=rtl]{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:4px;border-bottom-left-radius:var(--mdc-shape-small, 4px)}@supports(top: max(0%)){.mdc-select--outlined .mdc-select__anchor{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}[dir=rtl] .mdc-select--outlined .mdc-select__anchor,.mdc-select--outlined .mdc-select__anchor[dir=rtl]{padding-left:0}@supports(top: max(0%)){[dir=rtl] .mdc-select--outlined .mdc-select__anchor,.mdc-select--outlined .mdc-select__anchor[dir=rtl]{padding-right:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}@supports(top: max(0%)){.mdc-select--outlined+.mdc-select-helper-text{margin-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}[dir=rtl] .mdc-select--outlined+.mdc-select-helper-text,.mdc-select--outlined+.mdc-select-helper-text[dir=rtl]{margin-left:0}@supports(top: max(0%)){[dir=rtl] .mdc-select--outlined+.mdc-select-helper-text,.mdc-select--outlined+.mdc-select-helper-text[dir=rtl]{margin-right:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}.mdc-select--outlined:not(.mdc-select--disabled) .mdc-select__anchor{background-color:transparent}.mdc-select--outlined.mdc-select--disabled .mdc-select__anchor{background-color:transparent}.mdc-select--outlined:not(.mdc-select--disabled) .mdc-notched-outline__leading,.mdc-select--outlined:not(.mdc-select--disabled) .mdc-notched-outline__notch,.mdc-select--outlined:not(.mdc-select--disabled) .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.38)}.mdc-select--outlined:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.87)}.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__trailing{border-width:2px}.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__trailing{border-color:#6200ee;border-color:var(--mdc-theme-primary, #6200ee)}.mdc-select--outlined.mdc-select--disabled .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--disabled .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--disabled .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.06)}.mdc-select--outlined .mdc-select__anchor :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mdc-select--outlined .mdc-select__anchor{display:flex;align-items:baseline;overflow:visible}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-select-outlined 250ms 1}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1)}.mdc-select--outlined .mdc-select__anchor .mdc-floating-label--float-above{font-size:.75rem}.mdc-select--outlined .mdc-select__anchor.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-select--outlined .mdc-select__anchor.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-select--outlined .mdc-select__anchor .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:1px}.mdc-select--outlined .mdc-select__anchor .mdc-select__selected-text::before{content:"​"}.mdc-select--outlined .mdc-select__anchor .mdc-select__selected-text-container{height:100%;display:inline-flex;align-items:center}.mdc-select--outlined .mdc-select__anchor::before{display:none}.mdc-select--outlined .mdc-select__selected-text-container{display:flex;border:none;z-index:1;background-color:transparent}.mdc-select--outlined .mdc-select__icon{z-index:2}.mdc-select--outlined .mdc-floating-label{line-height:1.15rem;left:4px;right:initial}[dir=rtl] .mdc-select--outlined .mdc-floating-label,.mdc-select--outlined .mdc-floating-label[dir=rtl]{left:initial;right:4px}.mdc-select--outlined.mdc-select--focused .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:2px}.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled) .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled) .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled) .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled):not(.mdc-select--focused) .mdc-select__anchor:hover .mdc-notched-outline .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__trailing{border-width:2px}.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__leading,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__notch,.mdc-select--outlined.mdc-select--invalid:not(.mdc-select--disabled).mdc-select--focused .mdc-notched-outline .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label{left:36px;right:initial}[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label,.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label[dir=rtl]{left:initial;right:36px}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--float-above{transform:translateY(-37.25px) translateX(-32px) scale(1)}[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--float-above,.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-37.25px) translateX(32px) scale(1)}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--float-above{font-size:.75rem}.mdc-select--outlined.mdc-select--with-leading-icon.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined.mdc-select--with-leading-icon .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) translateX(-32px) scale(0.75)}[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon.mdc-notched-outline--upgraded .mdc-floating-label--float-above,[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon .mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined.mdc-select--with-leading-icon.mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl],.mdc-select--outlined.mdc-select--with-leading-icon .mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-34.75px) translateX(32px) scale(0.75)}.mdc-select--outlined.mdc-select--with-leading-icon.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-select--outlined.mdc-select--with-leading-icon .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-select-outlined-leading-icon-56px 250ms 1}@keyframes mdc-floating-label-shake-float-above-select-outlined-leading-icon-56px{0%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}}[dir=rtl] .mdc-select--outlined.mdc-select--with-leading-icon .mdc-floating-label--shake,.mdc-select--outlined.mdc-select--with-leading-icon[dir=rtl] .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-select-outlined-leading-icon-56px 250ms 1}@keyframes mdc-floating-label-shake-float-above-select-outlined-leading-icon-56px-rtl{0%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - -32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - -32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}}.mdc-select--outlined.mdc-select--with-leading-icon .mdc-select__anchor :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 96px)}.mdc-select--outlined .mdc-menu-surface{margin-bottom:8px}.mdc-select--outlined.mdc-select--no-label .mdc-menu-surface,.mdc-select--outlined .mdc-menu-surface--is-open-below{margin-bottom:0}.mdc-select__anchor{--mdc-ripple-fg-size: 0;--mdc-ripple-left: 0;--mdc-ripple-top: 0;--mdc-ripple-fg-scale: 1;--mdc-ripple-fg-translate-end: 0;--mdc-ripple-fg-translate-start: 0;-webkit-tap-highlight-color:rgba(0,0,0,0);will-change:transform,opacity}.mdc-select__anchor .mdc-select__ripple::before,.mdc-select__anchor .mdc-select__ripple::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.mdc-select__anchor .mdc-select__ripple::before{transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-select__anchor .mdc-select__ripple::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-select__anchor.mdc-ripple-upgraded .mdc-select__ripple::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-select__anchor.mdc-ripple-upgraded .mdc-select__ripple::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-select__anchor.mdc-ripple-upgraded--unbounded .mdc-select__ripple::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-select__anchor.mdc-ripple-upgraded--foreground-activation .mdc-select__ripple::after{animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.mdc-select__anchor.mdc-ripple-upgraded--foreground-deactivation .mdc-select__ripple::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-select__anchor .mdc-select__ripple::before,.mdc-select__anchor .mdc-select__ripple::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-select__anchor.mdc-ripple-upgraded .mdc-select__ripple::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-select__anchor .mdc-select__ripple::before,.mdc-select__anchor .mdc-select__ripple::after{background-color:rgba(0, 0, 0, 0.87);background-color:var(--mdc-ripple-color, rgba(0, 0, 0, 0.87))}.mdc-select__anchor:hover .mdc-select__ripple::before,.mdc-select__anchor.mdc-ripple-surface--hover .mdc-select__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-select__anchor.mdc-ripple-upgraded--background-focused .mdc-select__ripple::before,.mdc-select__anchor:not(.mdc-ripple-upgraded):focus .mdc-select__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-select__anchor .mdc-select__ripple{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-deprecated-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-deprecated-list-item__ripple::after{background-color:#000;background-color:var(--mdc-ripple-color, var(--mdc-theme-on-surface, #000))}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:hover .mdc-deprecated-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-surface--hover .mdc-deprecated-list-item__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-upgraded--background-focused .mdc-deprecated-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded):focus .mdc-deprecated-list-item__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded) .mdc-deprecated-list-item__ripple::after{transition:opacity 150ms linear}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded):active .mdc-deprecated-list-item__ripple::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected .mdc-list-item__ripple::after{background-color:#000;background-color:var(--mdc-ripple-color, var(--mdc-theme-on-surface, #000))}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:hover .mdc-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-surface--hover .mdc-list-item__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-upgraded--background-focused .mdc-list-item__ripple::before,.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded):focus .mdc-list-item__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded) .mdc-list-item__ripple::after{transition:opacity 150ms linear}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected:not(.mdc-ripple-upgraded):active .mdc-list-item__ripple::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-select__menu .mdc-deprecated-list .mdc-deprecated-list-item--selected.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-select-helper-text{margin:0;margin-left:16px;margin-right:16px;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.75rem;font-size:var(--mdc-typography-caption-font-size, 0.75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight, 400);letter-spacing:0.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, 0.0333333333em);text-decoration:inherit;text-decoration:var(--mdc-typography-caption-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform, inherit);display:block;margin-top:0;line-height:normal}[dir=rtl] .mdc-select-helper-text,.mdc-select-helper-text[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-select-helper-text::before{display:inline-block;width:0;height:16px;content:"";vertical-align:0}.mdc-select-helper-text--validation-msg{opacity:0;transition:opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-select--invalid+.mdc-select-helper-text--validation-msg,.mdc-select-helper-text--validation-msg-persistent{opacity:1}.mdc-select--with-leading-icon .mdc-select__icon{display:inline-block;box-sizing:border-box;border:none;text-decoration:none;cursor:pointer;user-select:none;flex-shrink:0;align-self:center;background-color:transparent;fill:currentColor}.mdc-select--with-leading-icon .mdc-select__icon{margin-left:12px;margin-right:12px}[dir=rtl] .mdc-select--with-leading-icon .mdc-select__icon,.mdc-select--with-leading-icon .mdc-select__icon[dir=rtl]{margin-left:12px;margin-right:12px}.mdc-select__icon:not([tabindex]),.mdc-select__icon[tabindex="-1"]{cursor:default;pointer-events:none}.material-icons{font-family:var(--mdc-icon-font, "Material Icons");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:"liga"}:host{display:inline-block;vertical-align:top;outline:none}.mdc-select{width:100%}[hidden]{display:none}.mdc-select__icon{z-index:2}.mdc-select--with-leading-icon{--mdc-list-item-graphic-margin: calc( 48px - var(--mdc-list-item-graphic-size, 24px) - var(--mdc-list-side-padding, 16px) )}.mdc-select .mdc-select__anchor .mdc-select__selected-text{overflow:hidden}.mdc-select .mdc-select__anchor *{display:inline-flex}.mdc-select .mdc-select__anchor .mdc-floating-label{display:inline-block}mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-select-outlined-idle-border-color, rgba(0, 0, 0, 0.38) );--mdc-notched-outline-notch-offset: 1px}:host(:not([disabled]):hover) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-select-outlined-hover-border-color, rgba(0, 0, 0, 0.87) )}:host(:not([disabled])) .mdc-select:not(.mdc-select--disabled) .mdc-select__selected-text{color:rgba(0, 0, 0, 0.87);color:var(--mdc-select-ink-color, rgba(0, 0, 0, 0.87))}:host(:not([disabled])) .mdc-select:not(.mdc-select--disabled) .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.42);border-bottom-color:var(--mdc-select-idle-line-color, rgba(0, 0, 0, 0.42))}:host(:not([disabled])) .mdc-select:not(.mdc-select--disabled):hover .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.87);border-bottom-color:var(--mdc-select-hover-line-color, rgba(0, 0, 0, 0.87))}:host(:not([disabled])) .mdc-select:not(.mdc-select--outlined):not(.mdc-select--disabled) .mdc-select__anchor{background-color:whitesmoke;background-color:var(--mdc-select-fill-color, whitesmoke)}:host(:not([disabled])) .mdc-select.mdc-select--invalid .mdc-select__dropdown-icon{fill:var(--mdc-select-error-dropdown-icon-color, var(--mdc-select-error-color, var(--mdc-theme-error, #b00020)))}:host(:not([disabled])) .mdc-select.mdc-select--invalid .mdc-floating-label,:host(:not([disabled])) .mdc-select.mdc-select--invalid .mdc-floating-label::after{color:var(--mdc-select-error-color, var(--mdc-theme-error, #b00020))}:host(:not([disabled])) .mdc-select.mdc-select--invalid mwc-notched-outline{--mdc-notched-outline-border-color: var(--mdc-select-error-color, var(--mdc-theme-error, #b00020))}.mdc-select__menu--invalid{--mdc-theme-primary: var(--mdc-select-error-color, var(--mdc-theme-error, #b00020))}:host(:not([disabled])) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-floating-label,:host(:not([disabled])) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-floating-label::after{color:rgba(0, 0, 0, 0.6);color:var(--mdc-select-label-ink-color, rgba(0, 0, 0, 0.6))}:host(:not([disabled])) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-select__dropdown-icon{fill:rgba(0, 0, 0, 0.54);fill:var(--mdc-select-dropdown-icon-color, rgba(0, 0, 0, 0.54))}:host(:not([disabled])) .mdc-select.mdc-select--focused mwc-notched-outline{--mdc-notched-outline-stroke-width: 2px;--mdc-notched-outline-notch-offset: 2px}:host(:not([disabled])) .mdc-select.mdc-select--focused:not(.mdc-select--invalid) mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-select-focused-label-color, var(--mdc-theme-primary, rgba(98, 0, 238, 0.87)) )}:host(:not([disabled])) .mdc-select.mdc-select--focused:not(.mdc-select--invalid) .mdc-select__dropdown-icon{fill:rgba(98,0,238,.87);fill:var(--mdc-select-focused-dropdown-icon-color, var(--mdc-theme-primary, rgba(98, 0, 238, 0.87)))}:host(:not([disabled])) .mdc-select.mdc-select--focused:not(.mdc-select--invalid) .mdc-floating-label{color:#6200ee;color:var(--mdc-theme-primary, #6200ee)}:host(:not([disabled])) .mdc-select.mdc-select--focused:not(.mdc-select--invalid) .mdc-floating-label::after{color:#6200ee;color:var(--mdc-theme-primary, #6200ee)}:host(:not([disabled])) .mdc-select-helper-text:not(.mdc-select-helper-text--validation-msg){color:var(--mdc-select-label-ink-color, rgba(0, 0, 0, 0.6))}:host([disabled]){pointer-events:none}:host([disabled]) .mdc-select:not(.mdc-select--outlined).mdc-select--disabled .mdc-select__anchor{background-color:#fafafa;background-color:var(--mdc-select-disabled-fill-color, #fafafa)}:host([disabled]) .mdc-select.mdc-select--outlined mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-select-outlined-disabled-border-color, rgba(0, 0, 0, 0.06) )}:host([disabled]) .mdc-select .mdc-select__dropdown-icon{fill:rgba(0, 0, 0, 0.38);fill:var(--mdc-select-disabled-dropdown-icon-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-floating-label,:host([disabled]) .mdc-select:not(.mdc-select--invalid):not(.mdc-select--focused) .mdc-floating-label::after{color:rgba(0, 0, 0, 0.38);color:var(--mdc-select-disabled-ink-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-select-helper-text{color:rgba(0, 0, 0, 0.38);color:var(--mdc-select-disabled-ink-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-select__selected-text{color:rgba(0, 0, 0, 0.38);color:var(--mdc-select-disabled-ink-color, rgba(0, 0, 0, 0.38))}`;let Qe=class extends Ge{};Qe.styles=[Ze,s`
.mdc-select__anchor {
height: var(--select-height, 56px) !important;
width: 100%;
}
- `,
-];
-PoLRSelect = __decorate([
- e$5("polr-select")
-], PoLRSelect);
-
-/**
- * @license
- * Copyright 2016 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-var strings$4 = {
- ARIA_CONTROLS: 'aria-controls',
- ARIA_DESCRIBEDBY: 'aria-describedby',
- INPUT_SELECTOR: '.mdc-text-field__input',
- LABEL_SELECTOR: '.mdc-floating-label',
- LEADING_ICON_SELECTOR: '.mdc-text-field__icon--leading',
- LINE_RIPPLE_SELECTOR: '.mdc-line-ripple',
- OUTLINE_SELECTOR: '.mdc-notched-outline',
- PREFIX_SELECTOR: '.mdc-text-field__affix--prefix',
- SUFFIX_SELECTOR: '.mdc-text-field__affix--suffix',
- TRAILING_ICON_SELECTOR: '.mdc-text-field__icon--trailing'
-};
-var cssClasses$3 = {
- DISABLED: 'mdc-text-field--disabled',
- FOCUSED: 'mdc-text-field--focused',
- HELPER_LINE: 'mdc-text-field-helper-line',
- INVALID: 'mdc-text-field--invalid',
- LABEL_FLOATING: 'mdc-text-field--label-floating',
- NO_LABEL: 'mdc-text-field--no-label',
- OUTLINED: 'mdc-text-field--outlined',
- ROOT: 'mdc-text-field',
- TEXTAREA: 'mdc-text-field--textarea',
- WITH_LEADING_ICON: 'mdc-text-field--with-leading-icon',
- WITH_TRAILING_ICON: 'mdc-text-field--with-trailing-icon',
- WITH_INTERNAL_COUNTER: 'mdc-text-field--with-internal-counter',
-};
-var numbers$1 = {
- LABEL_SCALE: 0.75,
-};
-/**
- * Whitelist based off of
- * https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/HTML5/Constraint_validation
- * under the "Validation-related attributes" section.
- */
-var VALIDATION_ATTR_WHITELIST = [
- 'pattern',
- 'min',
- 'max',
- 'required',
- 'step',
- 'minlength',
- 'maxlength',
-];
-/**
- * Label should always float for these types as they show some UI even if value
- * is empty.
- */
-var ALWAYS_FLOAT_TYPES = [
- 'color',
- 'date',
- 'datetime-local',
- 'month',
- 'range',
- 'time',
- 'week',
-];
-
+ `],Qe=n([ct("polr-select")],Qe);
/**
* @license
* Copyright 2016 Google Inc.
@@ -3105,1198 +592,86 @@ var ALWAYS_FLOAT_TYPES = [
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
-var POINTERDOWN_EVENTS = ['mousedown', 'touchstart'];
-var INTERACTION_EVENTS = ['click', 'keydown'];
-var MDCTextFieldFoundation = /** @class */ (function (_super) {
- __extends(MDCTextFieldFoundation, _super);
- /**
- * @param adapter
- * @param foundationMap Map from subcomponent names to their subfoundations.
- */
- function MDCTextFieldFoundation(adapter, foundationMap) {
- if (foundationMap === void 0) { foundationMap = {}; }
- var _this = _super.call(this, __assign(__assign({}, MDCTextFieldFoundation.defaultAdapter), adapter)) || this;
- _this.isFocused = false;
- _this.receivedUserInput = false;
- _this.valid = true;
- _this.useNativeValidation = true;
- _this.validateOnValueChange = true;
- _this.helperText = foundationMap.helperText;
- _this.characterCounter = foundationMap.characterCounter;
- _this.leadingIcon = foundationMap.leadingIcon;
- _this.trailingIcon = foundationMap.trailingIcon;
- _this.inputFocusHandler = function () {
- _this.activateFocus();
- };
- _this.inputBlurHandler = function () {
- _this.deactivateFocus();
- };
- _this.inputInputHandler = function () {
- _this.handleInput();
- };
- _this.setPointerXOffset = function (evt) {
- _this.setTransformOrigin(evt);
- };
- _this.textFieldInteractionHandler = function () {
- _this.handleTextFieldInteraction();
- };
- _this.validationAttributeChangeHandler = function (attributesList) {
- _this.handleValidationAttributeChange(attributesList);
- };
- return _this;
- }
- Object.defineProperty(MDCTextFieldFoundation, "cssClasses", {
- get: function () {
- return cssClasses$3;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTextFieldFoundation, "strings", {
- get: function () {
- return strings$4;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTextFieldFoundation, "numbers", {
- get: function () {
- return numbers$1;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTextFieldFoundation.prototype, "shouldAlwaysFloat", {
- get: function () {
- var type = this.getNativeInput().type;
- return ALWAYS_FLOAT_TYPES.indexOf(type) >= 0;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTextFieldFoundation.prototype, "shouldFloat", {
- get: function () {
- return this.shouldAlwaysFloat || this.isFocused || !!this.getValue() ||
- this.isBadInput();
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTextFieldFoundation.prototype, "shouldShake", {
- get: function () {
- return !this.isFocused && !this.isValid() && !!this.getValue();
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTextFieldFoundation, "defaultAdapter", {
- /**
- * See {@link MDCTextFieldAdapter} for typing information on parameters and
- * return types.
- */
- get: function () {
- // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
- return {
- addClass: function () { return undefined; },
- removeClass: function () { return undefined; },
- hasClass: function () { return true; },
- setInputAttr: function () { return undefined; },
- removeInputAttr: function () { return undefined; },
- registerTextFieldInteractionHandler: function () { return undefined; },
- deregisterTextFieldInteractionHandler: function () { return undefined; },
- registerInputInteractionHandler: function () { return undefined; },
- deregisterInputInteractionHandler: function () { return undefined; },
- registerValidationAttributeChangeHandler: function () {
- return new MutationObserver(function () { return undefined; });
- },
- deregisterValidationAttributeChangeHandler: function () { return undefined; },
- getNativeInput: function () { return null; },
- isFocused: function () { return false; },
- activateLineRipple: function () { return undefined; },
- deactivateLineRipple: function () { return undefined; },
- setLineRippleTransformOrigin: function () { return undefined; },
- shakeLabel: function () { return undefined; },
- floatLabel: function () { return undefined; },
- setLabelRequired: function () { return undefined; },
- hasLabel: function () { return false; },
- getLabelWidth: function () { return 0; },
- hasOutline: function () { return false; },
- notchOutline: function () { return undefined; },
- closeOutline: function () { return undefined; },
- };
- // tslint:enable:object-literal-sort-keys
- },
- enumerable: false,
- configurable: true
- });
- MDCTextFieldFoundation.prototype.init = function () {
- var e_1, _a, e_2, _b;
- if (this.adapter.hasLabel() && this.getNativeInput().required) {
- this.adapter.setLabelRequired(true);
- }
- if (this.adapter.isFocused()) {
- this.inputFocusHandler();
- }
- else if (this.adapter.hasLabel() && this.shouldFloat) {
- this.notchOutline(true);
- this.adapter.floatLabel(true);
- this.styleFloating(true);
- }
- this.adapter.registerInputInteractionHandler('focus', this.inputFocusHandler);
- this.adapter.registerInputInteractionHandler('blur', this.inputBlurHandler);
- this.adapter.registerInputInteractionHandler('input', this.inputInputHandler);
- try {
- for (var POINTERDOWN_EVENTS_1 = __values(POINTERDOWN_EVENTS), POINTERDOWN_EVENTS_1_1 = POINTERDOWN_EVENTS_1.next(); !POINTERDOWN_EVENTS_1_1.done; POINTERDOWN_EVENTS_1_1 = POINTERDOWN_EVENTS_1.next()) {
- var evtType = POINTERDOWN_EVENTS_1_1.value;
- this.adapter.registerInputInteractionHandler(evtType, this.setPointerXOffset);
- }
- }
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
- finally {
- try {
- if (POINTERDOWN_EVENTS_1_1 && !POINTERDOWN_EVENTS_1_1.done && (_a = POINTERDOWN_EVENTS_1.return)) _a.call(POINTERDOWN_EVENTS_1);
- }
- finally { if (e_1) throw e_1.error; }
- }
- try {
- for (var INTERACTION_EVENTS_1 = __values(INTERACTION_EVENTS), INTERACTION_EVENTS_1_1 = INTERACTION_EVENTS_1.next(); !INTERACTION_EVENTS_1_1.done; INTERACTION_EVENTS_1_1 = INTERACTION_EVENTS_1.next()) {
- var evtType = INTERACTION_EVENTS_1_1.value;
- this.adapter.registerTextFieldInteractionHandler(evtType, this.textFieldInteractionHandler);
- }
- }
- catch (e_2_1) { e_2 = { error: e_2_1 }; }
- finally {
- try {
- if (INTERACTION_EVENTS_1_1 && !INTERACTION_EVENTS_1_1.done && (_b = INTERACTION_EVENTS_1.return)) _b.call(INTERACTION_EVENTS_1);
- }
- finally { if (e_2) throw e_2.error; }
- }
- this.validationObserver =
- this.adapter.registerValidationAttributeChangeHandler(this.validationAttributeChangeHandler);
- this.setcharacterCounter(this.getValue().length);
- };
- MDCTextFieldFoundation.prototype.destroy = function () {
- var e_3, _a, e_4, _b;
- this.adapter.deregisterInputInteractionHandler('focus', this.inputFocusHandler);
- this.adapter.deregisterInputInteractionHandler('blur', this.inputBlurHandler);
- this.adapter.deregisterInputInteractionHandler('input', this.inputInputHandler);
- try {
- for (var POINTERDOWN_EVENTS_2 = __values(POINTERDOWN_EVENTS), POINTERDOWN_EVENTS_2_1 = POINTERDOWN_EVENTS_2.next(); !POINTERDOWN_EVENTS_2_1.done; POINTERDOWN_EVENTS_2_1 = POINTERDOWN_EVENTS_2.next()) {
- var evtType = POINTERDOWN_EVENTS_2_1.value;
- this.adapter.deregisterInputInteractionHandler(evtType, this.setPointerXOffset);
- }
- }
- catch (e_3_1) { e_3 = { error: e_3_1 }; }
- finally {
- try {
- if (POINTERDOWN_EVENTS_2_1 && !POINTERDOWN_EVENTS_2_1.done && (_a = POINTERDOWN_EVENTS_2.return)) _a.call(POINTERDOWN_EVENTS_2);
- }
- finally { if (e_3) throw e_3.error; }
- }
- try {
- for (var INTERACTION_EVENTS_2 = __values(INTERACTION_EVENTS), INTERACTION_EVENTS_2_1 = INTERACTION_EVENTS_2.next(); !INTERACTION_EVENTS_2_1.done; INTERACTION_EVENTS_2_1 = INTERACTION_EVENTS_2.next()) {
- var evtType = INTERACTION_EVENTS_2_1.value;
- this.adapter.deregisterTextFieldInteractionHandler(evtType, this.textFieldInteractionHandler);
- }
- }
- catch (e_4_1) { e_4 = { error: e_4_1 }; }
- finally {
- try {
- if (INTERACTION_EVENTS_2_1 && !INTERACTION_EVENTS_2_1.done && (_b = INTERACTION_EVENTS_2.return)) _b.call(INTERACTION_EVENTS_2);
- }
- finally { if (e_4) throw e_4.error; }
- }
- this.adapter.deregisterValidationAttributeChangeHandler(this.validationObserver);
- };
- /**
- * Handles user interactions with the Text Field.
- */
- MDCTextFieldFoundation.prototype.handleTextFieldInteraction = function () {
- var nativeInput = this.adapter.getNativeInput();
- if (nativeInput && nativeInput.disabled) {
- return;
- }
- this.receivedUserInput = true;
- };
- /**
- * Handles validation attribute changes
- */
- MDCTextFieldFoundation.prototype.handleValidationAttributeChange = function (attributesList) {
- var _this = this;
- attributesList.some(function (attributeName) {
- if (VALIDATION_ATTR_WHITELIST.indexOf(attributeName) > -1) {
- _this.styleValidity(true);
- _this.adapter.setLabelRequired(_this.getNativeInput().required);
- return true;
- }
- return false;
- });
- if (attributesList.indexOf('maxlength') > -1) {
- this.setcharacterCounter(this.getValue().length);
- }
- };
- /**
- * Opens/closes the notched outline.
- */
- MDCTextFieldFoundation.prototype.notchOutline = function (openNotch) {
- if (!this.adapter.hasOutline() || !this.adapter.hasLabel()) {
- return;
- }
- if (openNotch) {
- var labelWidth = this.adapter.getLabelWidth() * numbers$1.LABEL_SCALE;
- this.adapter.notchOutline(labelWidth);
- }
- else {
- this.adapter.closeOutline();
- }
- };
- /**
- * Activates the text field focus state.
- */
- MDCTextFieldFoundation.prototype.activateFocus = function () {
- this.isFocused = true;
- this.styleFocused(this.isFocused);
- this.adapter.activateLineRipple();
- if (this.adapter.hasLabel()) {
- this.notchOutline(this.shouldFloat);
- this.adapter.floatLabel(this.shouldFloat);
- this.styleFloating(this.shouldFloat);
- this.adapter.shakeLabel(this.shouldShake);
- }
- if (this.helperText &&
- (this.helperText.isPersistent() || !this.helperText.isValidation() ||
- !this.valid)) {
- this.helperText.showToScreenReader();
- }
- };
- /**
- * Sets the line ripple's transform origin, so that the line ripple activate
- * animation will animate out from the user's click location.
- */
- MDCTextFieldFoundation.prototype.setTransformOrigin = function (evt) {
- if (this.isDisabled() || this.adapter.hasOutline()) {
- return;
- }
- var touches = evt.touches;
- var targetEvent = touches ? touches[0] : evt;
- var targetClientRect = targetEvent.target.getBoundingClientRect();
- var normalizedX = targetEvent.clientX - targetClientRect.left;
- this.adapter.setLineRippleTransformOrigin(normalizedX);
- };
- /**
- * Handles input change of text input and text area.
- */
- MDCTextFieldFoundation.prototype.handleInput = function () {
- this.autoCompleteFocus();
- this.setcharacterCounter(this.getValue().length);
- };
- /**
- * Activates the Text Field's focus state in cases when the input value
- * changes without user input (e.g. programmatically).
- */
- MDCTextFieldFoundation.prototype.autoCompleteFocus = function () {
- if (!this.receivedUserInput) {
- this.activateFocus();
- }
- };
- /**
- * Deactivates the Text Field's focus state.
- */
- MDCTextFieldFoundation.prototype.deactivateFocus = function () {
- this.isFocused = false;
- this.adapter.deactivateLineRipple();
- var isValid = this.isValid();
- this.styleValidity(isValid);
- this.styleFocused(this.isFocused);
- if (this.adapter.hasLabel()) {
- this.notchOutline(this.shouldFloat);
- this.adapter.floatLabel(this.shouldFloat);
- this.styleFloating(this.shouldFloat);
- this.adapter.shakeLabel(this.shouldShake);
- }
- if (!this.shouldFloat) {
- this.receivedUserInput = false;
- }
- };
- MDCTextFieldFoundation.prototype.getValue = function () {
- return this.getNativeInput().value;
- };
- /**
- * @param value The value to set on the input Element.
- */
- MDCTextFieldFoundation.prototype.setValue = function (value) {
- // Prevent Safari from moving the caret to the end of the input when the
- // value has not changed.
- if (this.getValue() !== value) {
- this.getNativeInput().value = value;
- }
- this.setcharacterCounter(value.length);
- if (this.validateOnValueChange) {
- var isValid = this.isValid();
- this.styleValidity(isValid);
- }
- if (this.adapter.hasLabel()) {
- this.notchOutline(this.shouldFloat);
- this.adapter.floatLabel(this.shouldFloat);
- this.styleFloating(this.shouldFloat);
- if (this.validateOnValueChange) {
- this.adapter.shakeLabel(this.shouldShake);
- }
- }
- };
- /**
- * @return The custom validity state, if set; otherwise, the result of a
- * native validity check.
- */
- MDCTextFieldFoundation.prototype.isValid = function () {
- return this.useNativeValidation ? this.isNativeInputValid() : this.valid;
- };
- /**
- * @param isValid Sets the custom validity state of the Text Field.
- */
- MDCTextFieldFoundation.prototype.setValid = function (isValid) {
- this.valid = isValid;
- this.styleValidity(isValid);
- var shouldShake = !isValid && !this.isFocused && !!this.getValue();
- if (this.adapter.hasLabel()) {
- this.adapter.shakeLabel(shouldShake);
- }
- };
- /**
- * @param shouldValidate Whether or not validity should be updated on
- * value change.
- */
- MDCTextFieldFoundation.prototype.setValidateOnValueChange = function (shouldValidate) {
- this.validateOnValueChange = shouldValidate;
- };
- /**
- * @return Whether or not validity should be updated on value change. `true`
- * by default.
- */
- MDCTextFieldFoundation.prototype.getValidateOnValueChange = function () {
- return this.validateOnValueChange;
- };
- /**
- * Enables or disables the use of native validation. Use this for custom
- * validation.
- * @param useNativeValidation Set this to false to ignore native input
- * validation.
- */
- MDCTextFieldFoundation.prototype.setUseNativeValidation = function (useNativeValidation) {
- this.useNativeValidation = useNativeValidation;
- };
- MDCTextFieldFoundation.prototype.isDisabled = function () {
- return this.getNativeInput().disabled;
- };
- /**
- * @param disabled Sets the text-field disabled or enabled.
- */
- MDCTextFieldFoundation.prototype.setDisabled = function (disabled) {
- this.getNativeInput().disabled = disabled;
- this.styleDisabled(disabled);
- };
- /**
- * @param content Sets the content of the helper text.
- */
- MDCTextFieldFoundation.prototype.setHelperTextContent = function (content) {
- if (this.helperText) {
- this.helperText.setContent(content);
- }
- };
- /**
- * Sets the aria label of the leading icon.
- */
- MDCTextFieldFoundation.prototype.setLeadingIconAriaLabel = function (label) {
- if (this.leadingIcon) {
- this.leadingIcon.setAriaLabel(label);
- }
- };
- /**
- * Sets the text content of the leading icon.
- */
- MDCTextFieldFoundation.prototype.setLeadingIconContent = function (content) {
- if (this.leadingIcon) {
- this.leadingIcon.setContent(content);
- }
- };
- /**
- * Sets the aria label of the trailing icon.
- */
- MDCTextFieldFoundation.prototype.setTrailingIconAriaLabel = function (label) {
- if (this.trailingIcon) {
- this.trailingIcon.setAriaLabel(label);
- }
- };
- /**
- * Sets the text content of the trailing icon.
- */
- MDCTextFieldFoundation.prototype.setTrailingIconContent = function (content) {
- if (this.trailingIcon) {
- this.trailingIcon.setContent(content);
- }
- };
- /**
- * Sets character counter values that shows characters used and the total
- * character limit.
- */
- MDCTextFieldFoundation.prototype.setcharacterCounter = function (currentLength) {
- if (!this.characterCounter) {
- return;
- }
- var maxLength = this.getNativeInput().maxLength;
- if (maxLength === -1) {
- throw new Error('MDCTextFieldFoundation: Expected maxlength html property on text input or textarea.');
- }
- this.characterCounter.setCounterValue(currentLength, maxLength);
- };
- /**
- * @return True if the Text Field input fails in converting the user-supplied
- * value.
- */
- MDCTextFieldFoundation.prototype.isBadInput = function () {
- // The badInput property is not supported in IE 11 💩.
- return this.getNativeInput().validity.badInput || false;
- };
- /**
- * @return The result of native validity checking (ValidityState.valid).
- */
- MDCTextFieldFoundation.prototype.isNativeInputValid = function () {
- return this.getNativeInput().validity.valid;
- };
- /**
- * Styles the component based on the validity state.
- */
- MDCTextFieldFoundation.prototype.styleValidity = function (isValid) {
- var INVALID = MDCTextFieldFoundation.cssClasses.INVALID;
- if (isValid) {
- this.adapter.removeClass(INVALID);
- }
- else {
- this.adapter.addClass(INVALID);
- }
- if (this.helperText) {
- this.helperText.setValidity(isValid);
- // We dynamically set or unset aria-describedby for validation helper text
- // only, based on whether the field is valid
- var helperTextValidation = this.helperText.isValidation();
- if (!helperTextValidation) {
- return;
- }
- var helperTextVisible = this.helperText.isVisible();
- var helperTextId = this.helperText.getId();
- if (helperTextVisible && helperTextId) {
- this.adapter.setInputAttr(strings$4.ARIA_DESCRIBEDBY, helperTextId);
- }
- else {
- this.adapter.removeInputAttr(strings$4.ARIA_DESCRIBEDBY);
- }
- }
- };
- /**
- * Styles the component based on the focused state.
- */
- MDCTextFieldFoundation.prototype.styleFocused = function (isFocused) {
- var FOCUSED = MDCTextFieldFoundation.cssClasses.FOCUSED;
- if (isFocused) {
- this.adapter.addClass(FOCUSED);
- }
- else {
- this.adapter.removeClass(FOCUSED);
- }
- };
- /**
- * Styles the component based on the disabled state.
- */
- MDCTextFieldFoundation.prototype.styleDisabled = function (isDisabled) {
- var _a = MDCTextFieldFoundation.cssClasses, DISABLED = _a.DISABLED, INVALID = _a.INVALID;
- if (isDisabled) {
- this.adapter.addClass(DISABLED);
- this.adapter.removeClass(INVALID);
- }
- else {
- this.adapter.removeClass(DISABLED);
- }
- if (this.leadingIcon) {
- this.leadingIcon.setDisabled(isDisabled);
- }
- if (this.trailingIcon) {
- this.trailingIcon.setDisabled(isDisabled);
- }
- };
- /**
- * Styles the component based on the label floating state.
- */
- MDCTextFieldFoundation.prototype.styleFloating = function (isFloating) {
- var LABEL_FLOATING = MDCTextFieldFoundation.cssClasses.LABEL_FLOATING;
- if (isFloating) {
- this.adapter.addClass(LABEL_FLOATING);
- }
- else {
- this.adapter.removeClass(LABEL_FLOATING);
- }
- };
- /**
- * @return The native text input element from the host environment, or an
- * object with the same shape for unit tests.
- */
- MDCTextFieldFoundation.prototype.getNativeInput = function () {
- // this.adapter may be undefined in foundation unit tests. This happens when
- // testdouble is creating a mock object and invokes the
- // shouldShake/shouldFloat getters (which in turn call getValue(), which
- // calls this method) before init() has been called from the MDCTextField
- // constructor. To work around that issue, we return a dummy object.
- var nativeInput = this.adapter ? this.adapter.getNativeInput() : null;
- return nativeInput || {
- disabled: false,
- maxLength: -1,
- required: false,
- type: 'input',
- validity: {
- badInput: false,
- valid: true,
- },
- value: '',
- };
- };
- return MDCTextFieldFoundation;
-}(MDCFoundation));
-// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
-var MDCTextFieldFoundation$1 = MDCTextFieldFoundation;
-
+var Je={ARIA_CONTROLS:"aria-controls",ARIA_DESCRIBEDBY:"aria-describedby",INPUT_SELECTOR:".mdc-text-field__input",LABEL_SELECTOR:".mdc-floating-label",LEADING_ICON_SELECTOR:".mdc-text-field__icon--leading",LINE_RIPPLE_SELECTOR:".mdc-line-ripple",OUTLINE_SELECTOR:".mdc-notched-outline",PREFIX_SELECTOR:".mdc-text-field__affix--prefix",SUFFIX_SELECTOR:".mdc-text-field__affix--suffix",TRAILING_ICON_SELECTOR:".mdc-text-field__icon--trailing"},ti={DISABLED:"mdc-text-field--disabled",FOCUSED:"mdc-text-field--focused",HELPER_LINE:"mdc-text-field-helper-line",INVALID:"mdc-text-field--invalid",LABEL_FLOATING:"mdc-text-field--label-floating",NO_LABEL:"mdc-text-field--no-label",OUTLINED:"mdc-text-field--outlined",ROOT:"mdc-text-field",TEXTAREA:"mdc-text-field--textarea",WITH_LEADING_ICON:"mdc-text-field--with-leading-icon",WITH_TRAILING_ICON:"mdc-text-field--with-trailing-icon",WITH_INTERNAL_COUNTER:"mdc-text-field--with-internal-counter"},ei={LABEL_SCALE:.75},ii=["pattern","min","max","required","step","minlength","maxlength"],ni=["color","date","datetime-local","month","range","time","week"],ri=["mousedown","touchstart"],ai=["click","keydown"],li=function(t){function n(e,r){void 0===r&&(r={});var a=t.call(this,i(i({},n.defaultAdapter),e))||this;return a.isFocused=!1,a.receivedUserInput=!1,a.valid=!0,a.useNativeValidation=!0,a.validateOnValueChange=!0,a.helperText=r.helperText,a.characterCounter=r.characterCounter,a.leadingIcon=r.leadingIcon,a.trailingIcon=r.trailingIcon,a.inputFocusHandler=function(){a.activateFocus()},a.inputBlurHandler=function(){a.deactivateFocus()},a.inputInputHandler=function(){a.handleInput()},a.setPointerXOffset=function(t){a.setTransformOrigin(t)},a.textFieldInteractionHandler=function(){a.handleTextFieldInteraction()},a.validationAttributeChangeHandler=function(t){a.handleValidationAttributeChange(t)},a}return e(n,t),Object.defineProperty(n,"cssClasses",{get:function(){return ti},enumerable:!1,configurable:!0}),Object.defineProperty(n,"strings",{get:function(){return Je},enumerable:!1,configurable:!0}),Object.defineProperty(n,"numbers",{get:function(){return ei},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"shouldAlwaysFloat",{get:function(){var t=this.getNativeInput().type;return ni.indexOf(t)>=0},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"shouldFloat",{get:function(){return this.shouldAlwaysFloat||this.isFocused||!!this.getValue()||this.isBadInput()},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"shouldShake",{get:function(){return!this.isFocused&&!this.isValid()&&!!this.getValue()},enumerable:!1,configurable:!0}),Object.defineProperty(n,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!0},setInputAttr:function(){},removeInputAttr:function(){},registerTextFieldInteractionHandler:function(){},deregisterTextFieldInteractionHandler:function(){},registerInputInteractionHandler:function(){},deregisterInputInteractionHandler:function(){},registerValidationAttributeChangeHandler:function(){return new MutationObserver((function(){}))},deregisterValidationAttributeChangeHandler:function(){},getNativeInput:function(){return null},isFocused:function(){return!1},activateLineRipple:function(){},deactivateLineRipple:function(){},setLineRippleTransformOrigin:function(){},shakeLabel:function(){},floatLabel:function(){},setLabelRequired:function(){},hasLabel:function(){return!1},getLabelWidth:function(){return 0},hasOutline:function(){return!1},notchOutline:function(){},closeOutline:function(){}}},enumerable:!1,configurable:!0}),n.prototype.init=function(){var t,e,i,n;this.adapter.hasLabel()&&this.getNativeInput().required&&this.adapter.setLabelRequired(!0),this.adapter.isFocused()?this.inputFocusHandler():this.adapter.hasLabel()&&this.shouldFloat&&(this.notchOutline(!0),this.adapter.floatLabel(!0),this.styleFloating(!0)),this.adapter.registerInputInteractionHandler("focus",this.inputFocusHandler),this.adapter.registerInputInteractionHandler("blur",this.inputBlurHandler),this.adapter.registerInputInteractionHandler("input",this.inputInputHandler);try{for(var a=r(ri),l=a.next();!l.done;l=a.next()){var o=l.value;this.adapter.registerInputInteractionHandler(o,this.setPointerXOffset)}}catch(e){t={error:e}}finally{try{l&&!l.done&&(e=a.return)&&e.call(a)}finally{if(t)throw t.error}}try{for(var d=r(ai),c=d.next();!c.done;c=d.next()){o=c.value;this.adapter.registerTextFieldInteractionHandler(o,this.textFieldInteractionHandler)}}catch(t){i={error:t}}finally{try{c&&!c.done&&(n=d.return)&&n.call(d)}finally{if(i)throw i.error}}this.validationObserver=this.adapter.registerValidationAttributeChangeHandler(this.validationAttributeChangeHandler),this.setcharacterCounter(this.getValue().length)},n.prototype.destroy=function(){var t,e,i,n;this.adapter.deregisterInputInteractionHandler("focus",this.inputFocusHandler),this.adapter.deregisterInputInteractionHandler("blur",this.inputBlurHandler),this.adapter.deregisterInputInteractionHandler("input",this.inputInputHandler);try{for(var a=r(ri),l=a.next();!l.done;l=a.next()){var o=l.value;this.adapter.deregisterInputInteractionHandler(o,this.setPointerXOffset)}}catch(e){t={error:e}}finally{try{l&&!l.done&&(e=a.return)&&e.call(a)}finally{if(t)throw t.error}}try{for(var d=r(ai),c=d.next();!c.done;c=d.next()){o=c.value;this.adapter.deregisterTextFieldInteractionHandler(o,this.textFieldInteractionHandler)}}catch(t){i={error:t}}finally{try{c&&!c.done&&(n=d.return)&&n.call(d)}finally{if(i)throw i.error}}this.adapter.deregisterValidationAttributeChangeHandler(this.validationObserver)},n.prototype.handleTextFieldInteraction=function(){var t=this.adapter.getNativeInput();t&&t.disabled||(this.receivedUserInput=!0)},n.prototype.handleValidationAttributeChange=function(t){var e=this;t.some((function(t){return ii.indexOf(t)>-1&&(e.styleValidity(!0),e.adapter.setLabelRequired(e.getNativeInput().required),!0)})),t.indexOf("maxlength")>-1&&this.setcharacterCounter(this.getValue().length)},n.prototype.notchOutline=function(t){if(this.adapter.hasOutline()&&this.adapter.hasLabel())if(t){var e=this.adapter.getLabelWidth()*ei.LABEL_SCALE;this.adapter.notchOutline(e)}else this.adapter.closeOutline()},n.prototype.activateFocus=function(){this.isFocused=!0,this.styleFocused(this.isFocused),this.adapter.activateLineRipple(),this.adapter.hasLabel()&&(this.notchOutline(this.shouldFloat),this.adapter.floatLabel(this.shouldFloat),this.styleFloating(this.shouldFloat),this.adapter.shakeLabel(this.shouldShake)),!this.helperText||!this.helperText.isPersistent()&&this.helperText.isValidation()&&this.valid||this.helperText.showToScreenReader()},n.prototype.setTransformOrigin=function(t){if(!this.isDisabled()&&!this.adapter.hasOutline()){var e=t.touches,i=e?e[0]:t,n=i.target.getBoundingClientRect(),r=i.clientX-n.left;this.adapter.setLineRippleTransformOrigin(r)}},n.prototype.handleInput=function(){this.autoCompleteFocus(),this.setcharacterCounter(this.getValue().length)},n.prototype.autoCompleteFocus=function(){this.receivedUserInput||this.activateFocus()},n.prototype.deactivateFocus=function(){this.isFocused=!1,this.adapter.deactivateLineRipple();var t=this.isValid();this.styleValidity(t),this.styleFocused(this.isFocused),this.adapter.hasLabel()&&(this.notchOutline(this.shouldFloat),this.adapter.floatLabel(this.shouldFloat),this.styleFloating(this.shouldFloat),this.adapter.shakeLabel(this.shouldShake)),this.shouldFloat||(this.receivedUserInput=!1)},n.prototype.getValue=function(){return this.getNativeInput().value},n.prototype.setValue=function(t){if(this.getValue()!==t&&(this.getNativeInput().value=t),this.setcharacterCounter(t.length),this.validateOnValueChange){var e=this.isValid();this.styleValidity(e)}this.adapter.hasLabel()&&(this.notchOutline(this.shouldFloat),this.adapter.floatLabel(this.shouldFloat),this.styleFloating(this.shouldFloat),this.validateOnValueChange&&this.adapter.shakeLabel(this.shouldShake))},n.prototype.isValid=function(){return this.useNativeValidation?this.isNativeInputValid():this.valid},n.prototype.setValid=function(t){this.valid=t,this.styleValidity(t);var e=!t&&!this.isFocused&&!!this.getValue();this.adapter.hasLabel()&&this.adapter.shakeLabel(e)},n.prototype.setValidateOnValueChange=function(t){this.validateOnValueChange=t},n.prototype.getValidateOnValueChange=function(){return this.validateOnValueChange},n.prototype.setUseNativeValidation=function(t){this.useNativeValidation=t},n.prototype.isDisabled=function(){return this.getNativeInput().disabled},n.prototype.setDisabled=function(t){this.getNativeInput().disabled=t,this.styleDisabled(t)},n.prototype.setHelperTextContent=function(t){this.helperText&&this.helperText.setContent(t)},n.prototype.setLeadingIconAriaLabel=function(t){this.leadingIcon&&this.leadingIcon.setAriaLabel(t)},n.prototype.setLeadingIconContent=function(t){this.leadingIcon&&this.leadingIcon.setContent(t)},n.prototype.setTrailingIconAriaLabel=function(t){this.trailingIcon&&this.trailingIcon.setAriaLabel(t)},n.prototype.setTrailingIconContent=function(t){this.trailingIcon&&this.trailingIcon.setContent(t)},n.prototype.setcharacterCounter=function(t){if(this.characterCounter){var e=this.getNativeInput().maxLength;if(-1===e)throw new Error("MDCTextFieldFoundation: Expected maxlength html property on text input or textarea.");this.characterCounter.setCounterValue(t,e)}},n.prototype.isBadInput=function(){return this.getNativeInput().validity.badInput||!1},n.prototype.isNativeInputValid=function(){return this.getNativeInput().validity.valid},n.prototype.styleValidity=function(t){var e=n.cssClasses.INVALID;if(t?this.adapter.removeClass(e):this.adapter.addClass(e),this.helperText){if(this.helperText.setValidity(t),!this.helperText.isValidation())return;var i=this.helperText.isVisible(),r=this.helperText.getId();i&&r?this.adapter.setInputAttr(Je.ARIA_DESCRIBEDBY,r):this.adapter.removeInputAttr(Je.ARIA_DESCRIBEDBY)}},n.prototype.styleFocused=function(t){var e=n.cssClasses.FOCUSED;t?this.adapter.addClass(e):this.adapter.removeClass(e)},n.prototype.styleDisabled=function(t){var e=n.cssClasses,i=e.DISABLED,r=e.INVALID;t?(this.adapter.addClass(i),this.adapter.removeClass(r)):this.adapter.removeClass(i),this.leadingIcon&&this.leadingIcon.setDisabled(t),this.trailingIcon&&this.trailingIcon.setDisabled(t)},n.prototype.styleFloating=function(t){var e=n.cssClasses.LABEL_FLOATING;t?this.adapter.addClass(e):this.adapter.removeClass(e)},n.prototype.getNativeInput=function(){return(this.adapter?this.adapter.getNativeInput():null)||{disabled:!1,maxLength:-1,required:!1,type:"input",validity:{badInput:!1,valid:!0},value:""}},n}(Ie),oi=li;
/**
* @license
* Copyright 2020 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */const e=o=>void 0===o.strings,f={},s=(o,l=f)=>o._$AH=l;
-
+ */
+const di={},ci=Pe(class extends Ve{constructor(t){if(super(t),t.type!==$e&&t.type!==Oe&&t.type!==ze)throw Error("The `live` directive is not allowed on child or event bindings");if(!(t=>void 0===t.strings)(t))throw Error("`live` bindings can only contain a single expression")}render(t){return t}update(t,[e]){if(e===U||e===Y)return e;const i=t.element,n=t.name;if(t.type===$e){if(e===i[n])return U}else if(t.type===ze){if(!!e===i.hasAttribute(n))return U}else if(t.type===Oe&&i.getAttribute(n)===e+"")return U;return((t,e=di)=>{t._$AH=e;
/**
* @license
* Copyright 2020 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */const l=e$1(class extends i$1{constructor(r){if(super(r),r.type!==t.PROPERTY&&r.type!==t.ATTRIBUTE&&r.type!==t.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!e(r))throw Error("`live` bindings can only contain a single expression")}render(r){return r}update(i,[t$1]){if(t$1===T||t$1===A)return t$1;const o=i.element,l=i.name;if(i.type===t.PROPERTY){if(t$1===o[l])return T}else if(i.type===t.BOOLEAN_ATTRIBUTE){if(!!t$1===o.hasAttribute(l))return T}else if(i.type===t.ATTRIBUTE&&o.getAttribute(l)===t$1+"")return T;return s(i),t$1}});
-
-/**
- * @license
- * Copyright 2019 Google LLC
- * SPDX-License-Identifier: Apache-2.0
- */
-const passiveEvents = ['touchstart', 'touchmove', 'scroll', 'mousewheel'];
-const createValidityObj = (customValidity = {}) => {
- /*
- * We need to make ValidityState an object because it is readonly and
- * we cannot use the spread operator. Also, we don't export
- * `CustomValidityState` because it is a leaky implementation and the user
- * already has access to `ValidityState` in lib.dom.ts. Also an interface
- * {a: Type} can be casted to {readonly a: Type} so passing any object
- * should be fine.
- */
- const objectifiedCustomValidity = {};
- // eslint-disable-next-line guard-for-in
- for (const propName in customValidity) {
- /*
- * Casting is needed because ValidityState's props are all readonly and
- * thus cannot be set on `onjectifiedCustomValidity`. In the end, the
- * interface is the same as ValidityState (but not readonly), but the
- * function signature casts the output to ValidityState (thus readonly).
- */
- objectifiedCustomValidity[propName] =
- customValidity[propName];
- }
- return Object.assign({ badInput: false, customError: false, patternMismatch: false, rangeOverflow: false, rangeUnderflow: false, stepMismatch: false, tooLong: false, tooShort: false, typeMismatch: false, valid: true, valueMissing: false }, objectifiedCustomValidity);
-};
-/** @soyCompatible */
-class TextFieldBase extends FormElement {
- constructor() {
- super(...arguments);
- this.mdcFoundationClass = MDCTextFieldFoundation$1;
- this.value = '';
- this.type = 'text';
- this.placeholder = '';
- this.label = '';
- this.icon = '';
- this.iconTrailing = '';
- this.disabled = false;
- this.required = false;
- this.minLength = -1;
- this.maxLength = -1;
- this.outlined = false;
- this.helper = '';
- this.validateOnInitialRender = false;
- this.validationMessage = '';
- this.autoValidate = false;
- this.pattern = '';
- this.min = '';
- this.max = '';
- /**
- * step can be a number or the keyword "any".
- *
- * Use `String` typing to pass down the value as a string and let the native
- * input cast internally as needed.
- */
- this.step = null;
- this.size = null;
- this.helperPersistent = false;
- this.charCounter = false;
- this.endAligned = false;
- this.prefix = '';
- this.suffix = '';
- this.name = '';
- this.readOnly = false;
- this.autocapitalize = '';
- this.outlineOpen = false;
- this.outlineWidth = 0;
- this.isUiValid = true;
- this.focused = false;
- this._validity = createValidityObj();
- this.validityTransform = null;
- }
- get validity() {
- this._checkValidity(this.value);
- return this._validity;
- }
- get willValidate() {
- return this.formElement.willValidate;
- }
- get selectionStart() {
- return this.formElement.selectionStart;
- }
- get selectionEnd() {
- return this.formElement.selectionEnd;
- }
- focus() {
- const focusEvt = new CustomEvent('focus');
- this.formElement.dispatchEvent(focusEvt);
- this.formElement.focus();
- }
- blur() {
- const blurEvt = new CustomEvent('blur');
- this.formElement.dispatchEvent(blurEvt);
- this.formElement.blur();
- }
- select() {
- this.formElement.select();
- }
- setSelectionRange(selectionStart, selectionEnd, selectionDirection) {
- this.formElement.setSelectionRange(selectionStart, selectionEnd, selectionDirection);
- }
- update(changedProperties) {
- if (changedProperties.has('autoValidate') && this.mdcFoundation) {
- this.mdcFoundation.setValidateOnValueChange(this.autoValidate);
- }
- if (changedProperties.has('value') && typeof this.value !== 'string') {
- this.value = `${this.value}`;
- }
- super.update(changedProperties);
- }
- setFormData(formData) {
- if (this.name) {
- formData.append(this.name, this.value);
- }
- }
- /** @soyTemplate */
- render() {
- const shouldRenderCharCounter = this.charCounter && this.maxLength !== -1;
- const shouldRenderHelperText = !!this.helper || !!this.validationMessage || shouldRenderCharCounter;
- /** @classMap */
- const classes = {
- 'mdc-text-field--disabled': this.disabled,
- 'mdc-text-field--no-label': !this.label,
- 'mdc-text-field--filled': !this.outlined,
- 'mdc-text-field--outlined': this.outlined,
- 'mdc-text-field--with-leading-icon': this.icon,
- 'mdc-text-field--with-trailing-icon': this.iconTrailing,
- 'mdc-text-field--end-aligned': this.endAligned,
- };
- return x `
-
+ */})(t),e}}),si=["touchstart","touchmove","scroll","mousewheel"],mi=(t={})=>{const e={};for(const i in t)e[i]=t[i];return Object.assign({badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valid:!0,valueMissing:!1},e)};class hi extends ke{constructor(){super(...arguments),this.mdcFoundationClass=oi,this.value="",this.type="text",this.placeholder="",this.label="",this.icon="",this.iconTrailing="",this.disabled=!1,this.required=!1,this.minLength=-1,this.maxLength=-1,this.outlined=!1,this.helper="",this.validateOnInitialRender=!1,this.validationMessage="",this.autoValidate=!1,this.pattern="",this.min="",this.max="",this.step=null,this.size=null,this.helperPersistent=!1,this.charCounter=!1,this.endAligned=!1,this.prefix="",this.suffix="",this.name="",this.readOnly=!1,this.autocapitalize="",this.outlineOpen=!1,this.outlineWidth=0,this.isUiValid=!0,this.focused=!1,this._validity=mi(),this.validityTransform=null}get validity(){return this._checkValidity(this.value),this._validity}get willValidate(){return this.formElement.willValidate}get selectionStart(){return this.formElement.selectionStart}get selectionEnd(){return this.formElement.selectionEnd}focus(){const t=new CustomEvent("focus");this.formElement.dispatchEvent(t),this.formElement.focus()}blur(){const t=new CustomEvent("blur");this.formElement.dispatchEvent(t),this.formElement.blur()}select(){this.formElement.select()}setSelectionRange(t,e,i){this.formElement.setSelectionRange(t,e,i)}update(t){t.has("autoValidate")&&this.mdcFoundation&&this.mdcFoundation.setValidateOnValueChange(this.autoValidate),t.has("value")&&"string"!=typeof this.value&&(this.value=`${this.value}`),super.update(t)}setFormData(t){this.name&&t.append(this.name,this.value)}render(){const t=this.charCounter&&-1!==this.maxLength,e=!!this.helper||!!this.validationMessage||t,i={"mdc-text-field--disabled":this.disabled,"mdc-text-field--no-label":!this.label,"mdc-text-field--filled":!this.outlined,"mdc-text-field--outlined":this.outlined,"mdc-text-field--with-leading-icon":this.icon,"mdc-text-field--with-trailing-icon":this.iconTrailing,"mdc-text-field--end-aligned":this.endAligned};return B`
+
${this.renderRipple()}
- ${this.outlined ? this.renderOutline() : this.renderLabel()}
+ ${this.outlined?this.renderOutline():this.renderLabel()}
${this.renderLeadingIcon()}
${this.renderPrefix()}
- ${this.renderInput(shouldRenderHelperText)}
+ ${this.renderInput(e)}
${this.renderSuffix()}
${this.renderTrailingIcon()}
${this.renderLineRipple()}
- ${this.renderHelperText(shouldRenderHelperText, shouldRenderCharCounter)}
- `;
- }
- updated(changedProperties) {
- if (changedProperties.has('value') &&
- changedProperties.get('value') !== undefined) {
- this.mdcFoundation.setValue(this.value);
- if (this.autoValidate) {
- this.reportValidity();
- }
- }
- }
- /** @soyTemplate */
- renderRipple() {
- return this.outlined ? '' : x `
+ ${this.renderHelperText(e,t)}
+ `}updated(t){t.has("value")&&void 0!==t.get("value")&&(this.mdcFoundation.setValue(this.value),this.autoValidate&&this.reportValidity())}renderRipple(){return this.outlined?"":B`
- `;
- }
- /** @soyTemplate */
- renderOutline() {
- return !this.outlined ? '' : x `
+ `}renderOutline(){return this.outlined?B`
${this.renderLabel()}
- `;
- }
- /** @soyTemplate */
- renderLabel() {
- return !this.label ?
- '' :
- x `
+ `:""}renderLabel(){return this.label?B`
${this.label}
- `;
- }
- /** @soyTemplate */
- renderLeadingIcon() {
- return this.icon ? this.renderIcon(this.icon) : '';
- }
- /** @soyTemplate */
- renderTrailingIcon() {
- return this.iconTrailing ? this.renderIcon(this.iconTrailing, true) : '';
- }
- /** @soyTemplate */
- renderIcon(icon, isTrailingIcon = false) {
- /** @classMap */
- const classes = {
- 'mdc-text-field__icon--leading': !isTrailingIcon,
- 'mdc-text-field__icon--trailing': isTrailingIcon
- };
- return x `${icon} `;
- }
- /** @soyTemplate */
- renderPrefix() {
- return this.prefix ? this.renderAffix(this.prefix) : '';
- }
- /** @soyTemplate */
- renderSuffix() {
- return this.suffix ? this.renderAffix(this.suffix, true) : '';
- }
- /** @soyTemplate */
- renderAffix(content, isSuffix = false) {
- /** @classMap */
- const classes = {
- 'mdc-text-field__affix--prefix': !isSuffix,
- 'mdc-text-field__affix--suffix': isSuffix
- };
- return x `
- ${content} `;
- }
- /** @soyTemplate */
- renderInput(shouldRenderHelperText) {
- const minOrUndef = this.minLength === -1 ? undefined : this.minLength;
- const maxOrUndef = this.maxLength === -1 ? undefined : this.maxLength;
- const autocapitalizeOrUndef = this.autocapitalize ?
- this.autocapitalize :
- undefined;
- const showValidationMessage = this.validationMessage && !this.isUiValid;
- const ariaLabelledbyOrUndef = !!this.label ? 'label' : undefined;
- const ariaControlsOrUndef = shouldRenderHelperText ? 'helper-text' : undefined;
- const ariaDescribedbyOrUndef = this.focused || this.helperPersistent || showValidationMessage ?
- 'helper-text' :
- undefined;
- // TODO: live() directive needs casting for lit-analyzer
- // https://github.com/runem/lit-analyzer/pull/91/files
- // TODO: lit-analyzer labels min/max as (number|string) instead of string
- return x `
+ `:""}renderLeadingIcon(){return this.icon?this.renderIcon(this.icon):""}renderTrailingIcon(){return this.iconTrailing?this.renderIcon(this.iconTrailing,!0):""}renderIcon(t,e=!1){return B`${t} `}renderPrefix(){return this.prefix?this.renderAffix(this.prefix):""}renderSuffix(){return this.suffix?this.renderAffix(this.suffix,!0):""}renderAffix(t,e=!1){return B`
+ ${t} `}renderInput(t){const e=-1===this.minLength?void 0:this.minLength,i=-1===this.maxLength?void 0:this.maxLength,n=this.autocapitalize?this.autocapitalize:void 0,r=this.validationMessage&&!this.isUiValid,a=this.label?"label":void 0,l=t?"helper-text":void 0,o=this.focused||this.helperPersistent||r?"helper-text":void 0;return B`
`;
- }
- /** @soyTemplate */
- renderLineRipple() {
- return this.outlined ?
- '' :
- x `
-
- `;
- }
- /** @soyTemplate */
- renderHelperText(shouldRenderHelperText, shouldRenderCharCounter) {
- const showValidationMessage = this.validationMessage && !this.isUiValid;
- /** @classMap */
- const classes = {
- 'mdc-text-field-helper-text--persistent': this.helperPersistent,
- 'mdc-text-field-helper-text--validation-msg': showValidationMessage,
- };
- const ariaHiddenOrUndef = this.focused || this.helperPersistent || showValidationMessage ?
- undefined :
- 'true';
- const helperText = showValidationMessage ? this.validationMessage : this.helper;
- return !shouldRenderHelperText ? '' : x `
+ @blur="${this.onInputBlur}">`}renderLineRipple(){return this.outlined?"":B`
+
+ `}renderHelperText(t,e){const i=this.validationMessage&&!this.isUiValid,n={"mdc-text-field-helper-text--persistent":this.helperPersistent,"mdc-text-field-helper-text--validation-msg":i},r=this.focused||this.helperPersistent||i?void 0:"true",a=i?this.validationMessage:this.helper;return t?B`
${helperText}
- ${this.renderCharCounter(shouldRenderCharCounter)}
-
`;
- }
- /** @soyTemplate */
- renderCharCounter(shouldRenderCharCounter) {
- const length = Math.min(this.value.length, this.maxLength);
- return !shouldRenderCharCounter ? '' : x `
+ aria-hidden="${qe(r)}"
+ class="mdc-text-field-helper-text ${Xe(n)}"
+ >${a}
+ ${this.renderCharCounter(e)}
+ `:""}renderCharCounter(t){const e=Math.min(this.value.length,this.maxLength);return t?B`
${length} / ${this.maxLength} `;
- }
- onInputFocus() {
- this.focused = true;
- }
- onInputBlur() {
- this.focused = false;
- this.reportValidity();
- }
- checkValidity() {
- const isValid = this._checkValidity(this.value);
- if (!isValid) {
- const invalidEvent = new Event('invalid', { bubbles: false, cancelable: true });
- this.dispatchEvent(invalidEvent);
- }
- return isValid;
- }
- reportValidity() {
- const isValid = this.checkValidity();
- this.mdcFoundation.setValid(isValid);
- this.isUiValid = isValid;
- return isValid;
- }
- _checkValidity(value) {
- const nativeValidity = this.formElement.validity;
- let validity = createValidityObj(nativeValidity);
- if (this.validityTransform) {
- const customValidity = this.validityTransform(value, validity);
- validity = Object.assign(Object.assign({}, validity), customValidity);
- this.mdcFoundation.setUseNativeValidation(false);
- }
- else {
- this.mdcFoundation.setUseNativeValidation(true);
- }
- this._validity = validity;
- return this._validity.valid;
- }
- setCustomValidity(message) {
- this.validationMessage = message;
- this.formElement.setCustomValidity(message);
- }
- handleInputChange() {
- this.value = this.formElement.value;
- }
- createAdapter() {
- return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, this.getRootAdapterMethods()), this.getInputAdapterMethods()), this.getLabelAdapterMethods()), this.getLineRippleAdapterMethods()), this.getOutlineAdapterMethods());
- }
- getRootAdapterMethods() {
- return Object.assign({ registerTextFieldInteractionHandler: (evtType, handler) => this.addEventListener(evtType, handler), deregisterTextFieldInteractionHandler: (evtType, handler) => this.removeEventListener(evtType, handler), registerValidationAttributeChangeHandler: (handler) => {
- const getAttributesList = (mutationsList) => {
- return mutationsList.map((mutation) => mutation.attributeName)
- .filter((attributeName) => attributeName);
- };
- const observer = new MutationObserver((mutationsList) => {
- handler(getAttributesList(mutationsList));
- });
- const config = { attributes: true };
- observer.observe(this.formElement, config);
- return observer;
- }, deregisterValidationAttributeChangeHandler: (observer) => observer.disconnect() }, addHasRemoveClass(this.mdcRoot));
- }
- getInputAdapterMethods() {
- return {
- getNativeInput: () => this.formElement,
- // since HelperTextFoundation is not used, aria-describedby a11y logic
- // is implemented in render method instead of these adapter methods
- setInputAttr: () => undefined,
- removeInputAttr: () => undefined,
- isFocused: () => this.shadowRoot ?
- this.shadowRoot.activeElement === this.formElement :
- false,
- registerInputInteractionHandler: (evtType, handler) => this.formElement.addEventListener(evtType, handler, { passive: evtType in passiveEvents }),
- deregisterInputInteractionHandler: (evtType, handler) => this.formElement.removeEventListener(evtType, handler),
- };
- }
- getLabelAdapterMethods() {
- return {
- floatLabel: (shouldFloat) => this.labelElement &&
- this.labelElement.floatingLabelFoundation.float(shouldFloat),
- getLabelWidth: () => {
- return this.labelElement ?
- this.labelElement.floatingLabelFoundation.getWidth() :
- 0;
- },
- hasLabel: () => Boolean(this.labelElement),
- shakeLabel: (shouldShake) => this.labelElement &&
- this.labelElement.floatingLabelFoundation.shake(shouldShake),
- setLabelRequired: (isRequired) => {
- if (this.labelElement) {
- this.labelElement.floatingLabelFoundation.setRequired(isRequired);
- }
- },
- };
- }
- getLineRippleAdapterMethods() {
- return {
- activateLineRipple: () => {
- if (this.lineRippleElement) {
- this.lineRippleElement.lineRippleFoundation.activate();
- }
- },
- deactivateLineRipple: () => {
- if (this.lineRippleElement) {
- this.lineRippleElement.lineRippleFoundation.deactivate();
- }
- },
- setLineRippleTransformOrigin: (normalizedX) => {
- if (this.lineRippleElement) {
- this.lineRippleElement.lineRippleFoundation.setRippleCenter(normalizedX);
- }
- },
- };
- }
- // tslint:disable:ban-ts-ignore
- async getUpdateComplete() {
- var _a;
- // @ts-ignore
- const result = await super.getUpdateComplete();
- await ((_a = this.outlineElement) === null || _a === void 0 ? void 0 : _a.updateComplete);
- return result;
- }
- // tslint:enable:ban-ts-ignore
- firstUpdated() {
- var _a;
- super.firstUpdated();
- this.mdcFoundation.setValidateOnValueChange(this.autoValidate);
- if (this.validateOnInitialRender) {
- this.reportValidity();
- }
- // wait for the outline element to render to update the notch width
- (_a = this.outlineElement) === null || _a === void 0 ? void 0 : _a.updateComplete.then(() => {
- var _a;
- // `foundation.notchOutline()` assumes the label isn't floating and
- // multiplies by a constant, but the label is already is floating at this
- // stage, therefore directly set the outline width to the label width
- this.outlineWidth =
- ((_a = this.labelElement) === null || _a === void 0 ? void 0 : _a.floatingLabelFoundation.getWidth()) || 0;
- });
- }
- getOutlineAdapterMethods() {
- return {
- closeOutline: () => this.outlineElement && (this.outlineOpen = false),
- hasOutline: () => Boolean(this.outlineElement),
- notchOutline: (labelWidth) => {
- const outlineElement = this.outlineElement;
- if (outlineElement && !this.outlineOpen) {
- this.outlineWidth = labelWidth;
- this.outlineOpen = true;
- }
- }
- };
- }
- async layout() {
- await this.updateComplete;
- const labelElement = this.labelElement;
- if (!labelElement) {
- this.outlineOpen = false;
- return;
- }
- const shouldFloat = !!this.label && !!this.value;
- labelElement.floatingLabelFoundation.float(shouldFloat);
- if (!this.outlined) {
- return;
- }
- this.outlineOpen = shouldFloat;
- await this.updateComplete;
- /* When the textfield automatically notches due to a value and label
- * being defined, the textfield may be set to `display: none` by the user.
- * this means that the notch is of size 0px. We provide this function so
- * that the user may manually resize the notch to the floated label's
- * width.
- */
- const labelWidth = labelElement.floatingLabelFoundation.getWidth();
- if (this.outlineOpen) {
- this.outlineWidth = labelWidth;
- await this.updateComplete;
- }
- }
-}
-__decorate([
- i$2('.mdc-text-field')
-], TextFieldBase.prototype, "mdcRoot", void 0);
-__decorate([
- i$2('input')
-], TextFieldBase.prototype, "formElement", void 0);
-__decorate([
- i$2('.mdc-floating-label')
-], TextFieldBase.prototype, "labelElement", void 0);
-__decorate([
- i$2('.mdc-line-ripple')
-], TextFieldBase.prototype, "lineRippleElement", void 0);
-__decorate([
- i$2('mwc-notched-outline')
-], TextFieldBase.prototype, "outlineElement", void 0);
-__decorate([
- i$2('.mdc-notched-outline__notch')
-], TextFieldBase.prototype, "notchElement", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "value", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "type", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "placeholder", void 0);
-__decorate([
- n$3({ type: String }),
- observer(function (_newVal, oldVal) {
- if (oldVal !== undefined && this.label !== oldVal) {
- this.layout();
- }
- })
-], TextFieldBase.prototype, "label", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "icon", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "iconTrailing", void 0);
-__decorate([
- n$3({ type: Boolean, reflect: true })
-], TextFieldBase.prototype, "disabled", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TextFieldBase.prototype, "required", void 0);
-__decorate([
- n$3({ type: Number })
-], TextFieldBase.prototype, "minLength", void 0);
-__decorate([
- n$3({ type: Number })
-], TextFieldBase.prototype, "maxLength", void 0);
-__decorate([
- n$3({ type: Boolean, reflect: true }),
- observer(function (_newVal, oldVal) {
- if (oldVal !== undefined && this.outlined !== oldVal) {
- this.layout();
- }
- })
-], TextFieldBase.prototype, "outlined", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "helper", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TextFieldBase.prototype, "validateOnInitialRender", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "validationMessage", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TextFieldBase.prototype, "autoValidate", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "pattern", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "min", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "max", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "step", void 0);
-__decorate([
- n$3({ type: Number })
-], TextFieldBase.prototype, "size", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TextFieldBase.prototype, "helperPersistent", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TextFieldBase.prototype, "charCounter", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TextFieldBase.prototype, "endAligned", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "prefix", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "suffix", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "name", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "inputMode", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TextFieldBase.prototype, "readOnly", void 0);
-__decorate([
- n$3({ type: String })
-], TextFieldBase.prototype, "autocapitalize", void 0);
-__decorate([
- t$1()
-], TextFieldBase.prototype, "outlineOpen", void 0);
-__decorate([
- t$1()
-], TextFieldBase.prototype, "outlineWidth", void 0);
-__decorate([
- t$1()
-], TextFieldBase.prototype, "isUiValid", void 0);
-__decorate([
- t$1()
-], TextFieldBase.prototype, "focused", void 0);
-__decorate([
- e$3({ passive: true })
-], TextFieldBase.prototype, "handleInputChange", null);
-
+ >${e} / ${this.maxLength}`:""}onInputFocus(){this.focused=!0}onInputBlur(){this.focused=!1,this.reportValidity()}checkValidity(){const t=this._checkValidity(this.value);if(!t){const t=new Event("invalid",{bubbles:!1,cancelable:!0});this.dispatchEvent(t)}return t}reportValidity(){const t=this.checkValidity();return this.mdcFoundation.setValid(t),this.isUiValid=t,t}_checkValidity(t){const e=this.formElement.validity;let i=mi(e);if(this.validityTransform){const e=this.validityTransform(t,i);i=Object.assign(Object.assign({},i),e),this.mdcFoundation.setUseNativeValidation(!1)}else this.mdcFoundation.setUseNativeValidation(!0);return this._validity=i,this._validity.valid}setCustomValidity(t){this.validationMessage=t,this.formElement.setCustomValidity(t)}handleInputChange(){this.value=this.formElement.value}createAdapter(){return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},this.getRootAdapterMethods()),this.getInputAdapterMethods()),this.getLabelAdapterMethods()),this.getLineRippleAdapterMethods()),this.getOutlineAdapterMethods())}getRootAdapterMethods(){return Object.assign({registerTextFieldInteractionHandler:(t,e)=>this.addEventListener(t,e),deregisterTextFieldInteractionHandler:(t,e)=>this.removeEventListener(t,e),registerValidationAttributeChangeHandler:t=>{const e=new MutationObserver((e=>{t((t=>t.map((t=>t.attributeName)).filter((t=>t)))(e))}));return e.observe(this.formElement,{attributes:!0}),e},deregisterValidationAttributeChangeHandler:t=>t.disconnect()},xe(this.mdcRoot))}getInputAdapterMethods(){return{getNativeInput:()=>this.formElement,setInputAttr:()=>{},removeInputAttr:()=>{},isFocused:()=>!!this.shadowRoot&&this.shadowRoot.activeElement===this.formElement,registerInputInteractionHandler:(t,e)=>this.formElement.addEventListener(t,e,{passive:t in si}),deregisterInputInteractionHandler:(t,e)=>this.formElement.removeEventListener(t,e)}}getLabelAdapterMethods(){return{floatLabel:t=>this.labelElement&&this.labelElement.floatingLabelFoundation.float(t),getLabelWidth:()=>this.labelElement?this.labelElement.floatingLabelFoundation.getWidth():0,hasLabel:()=>Boolean(this.labelElement),shakeLabel:t=>this.labelElement&&this.labelElement.floatingLabelFoundation.shake(t),setLabelRequired:t=>{this.labelElement&&this.labelElement.floatingLabelFoundation.setRequired(t)}}}getLineRippleAdapterMethods(){return{activateLineRipple:()=>{this.lineRippleElement&&this.lineRippleElement.lineRippleFoundation.activate()},deactivateLineRipple:()=>{this.lineRippleElement&&this.lineRippleElement.lineRippleFoundation.deactivate()},setLineRippleTransformOrigin:t=>{this.lineRippleElement&&this.lineRippleElement.lineRippleFoundation.setRippleCenter(t)}}}async getUpdateComplete(){var t;const e=await super.getUpdateComplete();return await(null===(t=this.outlineElement)||void 0===t?void 0:t.updateComplete),e}firstUpdated(){var t;super.firstUpdated(),this.mdcFoundation.setValidateOnValueChange(this.autoValidate),this.validateOnInitialRender&&this.reportValidity(),null===(t=this.outlineElement)||void 0===t||t.updateComplete.then((()=>{var t;this.outlineWidth=(null===(t=this.labelElement)||void 0===t?void 0:t.floatingLabelFoundation.getWidth())||0}))}getOutlineAdapterMethods(){return{closeOutline:()=>this.outlineElement&&(this.outlineOpen=!1),hasOutline:()=>Boolean(this.outlineElement),notchOutline:t=>{this.outlineElement&&!this.outlineOpen&&(this.outlineWidth=t,this.outlineOpen=!0)}}}async layout(){await this.updateComplete;const t=this.labelElement;if(!t)return void(this.outlineOpen=!1);const e=!!this.label&&!!this.value;if(t.floatingLabelFoundation.float(e),!this.outlined)return;this.outlineOpen=e,await this.updateComplete;const i=t.floatingLabelFoundation.getWidth();this.outlineOpen&&(this.outlineWidth=i,await this.updateComplete)}}n([gt(".mdc-text-field")],hi.prototype,"mdcRoot",void 0),n([gt("input")],hi.prototype,"formElement",void 0),n([gt(".mdc-floating-label")],hi.prototype,"labelElement",void 0),n([gt(".mdc-line-ripple")],hi.prototype,"lineRippleElement",void 0),n([gt("mwc-notched-outline")],hi.prototype,"outlineElement",void 0),n([gt(".mdc-notched-outline__notch")],hi.prototype,"notchElement",void 0),n([ht({type:String})],hi.prototype,"value",void 0),n([ht({type:String})],hi.prototype,"type",void 0),n([ht({type:String})],hi.prototype,"placeholder",void 0),n([ht({type:String}),Te((function(t,e){void 0!==e&&this.label!==e&&this.layout()}))],hi.prototype,"label",void 0),n([ht({type:String})],hi.prototype,"icon",void 0),n([ht({type:String})],hi.prototype,"iconTrailing",void 0),n([ht({type:Boolean,reflect:!0})],hi.prototype,"disabled",void 0),n([ht({type:Boolean})],hi.prototype,"required",void 0),n([ht({type:Number})],hi.prototype,"minLength",void 0),n([ht({type:Number})],hi.prototype,"maxLength",void 0),n([ht({type:Boolean,reflect:!0}),Te((function(t,e){void 0!==e&&this.outlined!==e&&this.layout()}))],hi.prototype,"outlined",void 0),n([ht({type:String})],hi.prototype,"helper",void 0),n([ht({type:Boolean})],hi.prototype,"validateOnInitialRender",void 0),n([ht({type:String})],hi.prototype,"validationMessage",void 0),n([ht({type:Boolean})],hi.prototype,"autoValidate",void 0),n([ht({type:String})],hi.prototype,"pattern",void 0),n([ht({type:String})],hi.prototype,"min",void 0),n([ht({type:String})],hi.prototype,"max",void 0),n([ht({type:String})],hi.prototype,"step",void 0),n([ht({type:Number})],hi.prototype,"size",void 0),n([ht({type:Boolean})],hi.prototype,"helperPersistent",void 0),n([ht({type:Boolean})],hi.prototype,"charCounter",void 0),n([ht({type:Boolean})],hi.prototype,"endAligned",void 0),n([ht({type:String})],hi.prototype,"prefix",void 0),n([ht({type:String})],hi.prototype,"suffix",void 0),n([ht({type:String})],hi.prototype,"name",void 0),n([ht({type:String})],hi.prototype,"inputMode",void 0),n([ht({type:Boolean})],hi.prototype,"readOnly",void 0),n([ht({type:String})],hi.prototype,"autocapitalize",void 0),n([pt()],hi.prototype,"outlineOpen",void 0),n([pt()],hi.prototype,"outlineWidth",void 0),n([pt()],hi.prototype,"isUiValid",void 0),n([pt()],hi.prototype,"focused",void 0),n([ft({passive:!0})],hi.prototype,"handleInputChange",null);
/**
* @license
* Copyright 2021 Google LLC
* SPDX-LIcense-Identifier: Apache-2.0
*/
-const styles$5 = i$5 `.mdc-floating-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:1rem;font-size:var(--mdc-typography-subtitle1-font-size, 1rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);position:absolute;left:0;-webkit-transform-origin:left top;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform;transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1),color 150ms cubic-bezier(0.4, 0, 0.2, 1)}[dir=rtl] .mdc-floating-label,.mdc-floating-label[dir=rtl]{right:0;left:auto;-webkit-transform-origin:right top;transform-origin:right top;text-align:right}.mdc-floating-label--float-above{cursor:auto}.mdc-floating-label--required::after{margin-left:1px;margin-right:0px;content:"*"}[dir=rtl] .mdc-floating-label--required::after,.mdc-floating-label--required[dir=rtl]::after{margin-left:0;margin-right:1px}.mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-standard 250ms 1}@keyframes mdc-floating-label-shake-float-above-standard{0%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-106%) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-106%) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}}.mdc-line-ripple::before,.mdc-line-ripple::after{position:absolute;bottom:0;left:0;width:100%;border-bottom-style:solid;content:""}.mdc-line-ripple::before{border-bottom-width:1px}.mdc-line-ripple::before{z-index:1}.mdc-line-ripple::after{transform:scaleX(0);border-bottom-width:2px;opacity:0;z-index:2}.mdc-line-ripple::after{transition:transform 180ms cubic-bezier(0.4, 0, 0.2, 1),opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-line-ripple--active::after{transform:scaleX(1);opacity:1}.mdc-line-ripple--deactivating::after{opacity:0}.mdc-notched-outline{display:flex;position:absolute;top:0;right:0;left:0;box-sizing:border-box;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}[dir=rtl] .mdc-notched-outline,.mdc-notched-outline[dir=rtl]{text-align:right}.mdc-notched-outline__leading,.mdc-notched-outline__notch,.mdc-notched-outline__trailing{box-sizing:border-box;height:100%;border-top:1px solid;border-bottom:1px solid;pointer-events:none}.mdc-notched-outline__leading{border-left:1px solid;border-right:none;width:12px}[dir=rtl] .mdc-notched-outline__leading,.mdc-notched-outline__leading[dir=rtl]{border-left:none;border-right:1px solid}.mdc-notched-outline__trailing{border-left:none;border-right:1px solid;flex-grow:1}[dir=rtl] .mdc-notched-outline__trailing,.mdc-notched-outline__trailing[dir=rtl]{border-left:1px solid;border-right:none}.mdc-notched-outline__notch{flex:0 0 auto;width:auto;max-width:calc(100% - 12px * 2)}.mdc-notched-outline .mdc-floating-label{display:inline-block;position:relative;max-width:100%}.mdc-notched-outline .mdc-floating-label--float-above{text-overflow:clip}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:calc(100% / 0.75)}.mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:0;padding-right:8px;border-top:none}[dir=rtl] .mdc-notched-outline--notched .mdc-notched-outline__notch,.mdc-notched-outline--notched .mdc-notched-outline__notch[dir=rtl]{padding-left:8px;padding-right:0}.mdc-notched-outline--no-label .mdc-notched-outline__notch{display:none}@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-text-field--filled{--mdc-ripple-fg-size: 0;--mdc-ripple-left: 0;--mdc-ripple-top: 0;--mdc-ripple-fg-scale: 1;--mdc-ripple-fg-translate-end: 0;--mdc-ripple-fg-translate-start: 0;-webkit-tap-highlight-color:rgba(0,0,0,0);will-change:transform,opacity}.mdc-text-field--filled .mdc-text-field__ripple::before,.mdc-text-field--filled .mdc-text-field__ripple::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.mdc-text-field--filled .mdc-text-field__ripple::before{transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-text-field--filled .mdc-text-field__ripple::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-text-field--filled.mdc-ripple-upgraded .mdc-text-field__ripple::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-text-field--filled.mdc-ripple-upgraded .mdc-text-field__ripple::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-text-field--filled.mdc-ripple-upgraded--unbounded .mdc-text-field__ripple::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-text-field--filled.mdc-ripple-upgraded--foreground-activation .mdc-text-field__ripple::after{animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.mdc-text-field--filled.mdc-ripple-upgraded--foreground-deactivation .mdc-text-field__ripple::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-text-field--filled .mdc-text-field__ripple::before,.mdc-text-field--filled .mdc-text-field__ripple::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-text-field--filled.mdc-ripple-upgraded .mdc-text-field__ripple::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-text-field__ripple{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none}.mdc-text-field{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:0;border-bottom-left-radius:0;display:inline-flex;align-items:baseline;padding:0 16px;position:relative;box-sizing:border-box;overflow:hidden;will-change:opacity,transform,color}.mdc-text-field:not(.mdc-text-field--disabled) .mdc-floating-label{color:rgba(0, 0, 0, 0.6)}.mdc-text-field:not(.mdc-text-field--disabled) .mdc-text-field__input{color:rgba(0, 0, 0, 0.87)}@media all{.mdc-text-field:not(.mdc-text-field--disabled) .mdc-text-field__input::placeholder{color:rgba(0, 0, 0, 0.54)}}@media all{.mdc-text-field:not(.mdc-text-field--disabled) .mdc-text-field__input:-ms-input-placeholder{color:rgba(0, 0, 0, 0.54)}}.mdc-text-field .mdc-text-field__input{caret-color:#6200ee;caret-color:var(--mdc-theme-primary, #6200ee)}.mdc-text-field:not(.mdc-text-field--disabled)+.mdc-text-field-helper-line .mdc-text-field-helper-text{color:rgba(0, 0, 0, 0.6)}.mdc-text-field:not(.mdc-text-field--disabled) .mdc-text-field-character-counter,.mdc-text-field:not(.mdc-text-field--disabled)+.mdc-text-field-helper-line .mdc-text-field-character-counter{color:rgba(0, 0, 0, 0.6)}.mdc-text-field:not(.mdc-text-field--disabled) .mdc-text-field__icon--leading{color:rgba(0, 0, 0, 0.54)}.mdc-text-field:not(.mdc-text-field--disabled) .mdc-text-field__icon--trailing{color:rgba(0, 0, 0, 0.54)}.mdc-text-field:not(.mdc-text-field--disabled) .mdc-text-field__affix--prefix{color:rgba(0, 0, 0, 0.6)}.mdc-text-field:not(.mdc-text-field--disabled) .mdc-text-field__affix--suffix{color:rgba(0, 0, 0, 0.6)}.mdc-text-field .mdc-floating-label{top:50%;transform:translateY(-50%);pointer-events:none}.mdc-text-field__input{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:1rem;font-size:var(--mdc-typography-subtitle1-font-size, 1rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);height:28px;transition:opacity 150ms 0ms cubic-bezier(0.4, 0, 0.2, 1);width:100%;min-width:0;border:none;border-radius:0;background:none;appearance:none;padding:0}.mdc-text-field__input::-ms-clear{display:none}.mdc-text-field__input::-webkit-calendar-picker-indicator{display:none}.mdc-text-field__input:focus{outline:none}.mdc-text-field__input:invalid{box-shadow:none}@media all{.mdc-text-field__input::placeholder{transition:opacity 67ms 0ms cubic-bezier(0.4, 0, 0.2, 1);opacity:0}}@media all{.mdc-text-field__input:-ms-input-placeholder{transition:opacity 67ms 0ms cubic-bezier(0.4, 0, 0.2, 1);opacity:0}}@media all{.mdc-text-field--no-label .mdc-text-field__input::placeholder,.mdc-text-field--focused .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms;opacity:1}}@media all{.mdc-text-field--no-label .mdc-text-field__input:-ms-input-placeholder,.mdc-text-field--focused .mdc-text-field__input:-ms-input-placeholder{transition-delay:40ms;transition-duration:110ms;opacity:1}}.mdc-text-field__affix{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:1rem;font-size:var(--mdc-typography-subtitle1-font-size, 1rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);height:28px;transition:opacity 150ms 0ms cubic-bezier(0.4, 0, 0.2, 1);opacity:0;white-space:nowrap}.mdc-text-field--label-floating .mdc-text-field__affix,.mdc-text-field--no-label .mdc-text-field__affix{opacity:1}@supports(-webkit-hyphens: none){.mdc-text-field--outlined .mdc-text-field__affix{align-items:center;align-self:center;display:inline-flex;height:100%}}.mdc-text-field__affix--prefix{padding-left:0;padding-right:2px}[dir=rtl] .mdc-text-field__affix--prefix,.mdc-text-field__affix--prefix[dir=rtl]{padding-left:2px;padding-right:0}.mdc-text-field--end-aligned .mdc-text-field__affix--prefix{padding-left:0;padding-right:12px}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__affix--prefix,.mdc-text-field--end-aligned .mdc-text-field__affix--prefix[dir=rtl]{padding-left:12px;padding-right:0}.mdc-text-field__affix--suffix{padding-left:12px;padding-right:0}[dir=rtl] .mdc-text-field__affix--suffix,.mdc-text-field__affix--suffix[dir=rtl]{padding-left:0;padding-right:12px}.mdc-text-field--end-aligned .mdc-text-field__affix--suffix{padding-left:2px;padding-right:0}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__affix--suffix,.mdc-text-field--end-aligned .mdc-text-field__affix--suffix[dir=rtl]{padding-left:0;padding-right:2px}.mdc-text-field--filled{height:56px}.mdc-text-field--filled .mdc-text-field__ripple::before,.mdc-text-field--filled .mdc-text-field__ripple::after{background-color:rgba(0, 0, 0, 0.87);background-color:var(--mdc-ripple-color, rgba(0, 0, 0, 0.87))}.mdc-text-field--filled:hover .mdc-text-field__ripple::before,.mdc-text-field--filled.mdc-ripple-surface--hover .mdc-text-field__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-text-field--filled.mdc-ripple-upgraded--background-focused .mdc-text-field__ripple::before,.mdc-text-field--filled:not(.mdc-ripple-upgraded):focus .mdc-text-field__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-text-field--filled::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}.mdc-text-field--filled:not(.mdc-text-field--disabled){background-color:whitesmoke}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.42)}.mdc-text-field--filled:not(.mdc-text-field--disabled):hover .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.87)}.mdc-text-field--filled .mdc-line-ripple::after{border-bottom-color:#6200ee;border-bottom-color:var(--mdc-theme-primary, #6200ee)}.mdc-text-field--filled .mdc-floating-label{left:16px;right:initial}[dir=rtl] .mdc-text-field--filled .mdc-floating-label,.mdc-text-field--filled .mdc-floating-label[dir=rtl]{left:initial;right:16px}.mdc-text-field--filled .mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__input{height:100%}.mdc-text-field--filled.mdc-text-field--no-label .mdc-floating-label{display:none}.mdc-text-field--filled.mdc-text-field--no-label::before{display:none}@supports(-webkit-hyphens: none){.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__affix{align-items:center;align-self:center;display:inline-flex;height:100%}}.mdc-text-field--outlined{height:56px;overflow:visible}.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1)}.mdc-text-field--outlined .mdc-floating-label--float-above{font-size:.75rem}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-text-field--outlined .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-text-field-outlined 250ms 1}@keyframes mdc-floating-label-shake-float-above-text-field-outlined{0%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}}.mdc-text-field--outlined .mdc-text-field__input{height:100%}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-notched-outline__leading,.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-notched-outline__notch,.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.38)}.mdc-text-field--outlined:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-notched-outline .mdc-notched-outline__leading,.mdc-text-field--outlined:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-notched-outline .mdc-notched-outline__notch,.mdc-text-field--outlined:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-notched-outline .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.87)}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline__leading,.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline__notch,.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline__trailing{border-color:#6200ee;border-color:var(--mdc-theme-primary, #6200ee)}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:4px;border-bottom-left-radius:var(--mdc-shape-small, 4px)}[dir=rtl] .mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading,.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading[dir=rtl]{border-top-left-radius:0;border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:4px;border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}@supports(top: max(0%)){.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{width:max(12px, var(--mdc-shape-small, 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__notch{max-width:calc(100% - max(12px, var(--mdc-shape-small, 4px)) * 2)}}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing{border-top-left-radius:0;border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:4px;border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}[dir=rtl] .mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing,.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing[dir=rtl]{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:4px;border-bottom-left-radius:var(--mdc-shape-small, 4px)}@supports(top: max(0%)){.mdc-text-field--outlined{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined{padding-right:max(16px, var(--mdc-shape-small, 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined+.mdc-text-field-helper-line{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined+.mdc-text-field-helper-line{padding-right:max(16px, var(--mdc-shape-small, 4px))}}.mdc-text-field--outlined.mdc-text-field--with-leading-icon{padding-left:0}@supports(top: max(0%)){.mdc-text-field--outlined.mdc-text-field--with-leading-icon{padding-right:max(16px, var(--mdc-shape-small, 4px))}}[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-leading-icon,.mdc-text-field--outlined.mdc-text-field--with-leading-icon[dir=rtl]{padding-right:0}@supports(top: max(0%)){[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-leading-icon,.mdc-text-field--outlined.mdc-text-field--with-leading-icon[dir=rtl]{padding-left:max(16px, var(--mdc-shape-small, 4px))}}.mdc-text-field--outlined.mdc-text-field--with-trailing-icon{padding-right:0}@supports(top: max(0%)){.mdc-text-field--outlined.mdc-text-field--with-trailing-icon{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-trailing-icon,.mdc-text-field--outlined.mdc-text-field--with-trailing-icon[dir=rtl]{padding-left:0}@supports(top: max(0%)){[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-trailing-icon,.mdc-text-field--outlined.mdc-text-field--with-trailing-icon[dir=rtl]{padding-right:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}.mdc-text-field--outlined.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon{padding-left:0;padding-right:0}.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:1px}.mdc-text-field--outlined .mdc-text-field__ripple::before,.mdc-text-field--outlined .mdc-text-field__ripple::after{background-color:transparent;background-color:var(--mdc-ripple-color, transparent)}.mdc-text-field--outlined .mdc-floating-label{left:4px;right:initial}[dir=rtl] .mdc-text-field--outlined .mdc-floating-label,.mdc-text-field--outlined .mdc-floating-label[dir=rtl]{left:initial;right:4px}.mdc-text-field--outlined .mdc-text-field__input{display:flex;border:none !important;background-color:transparent}.mdc-text-field--outlined .mdc-notched-outline{z-index:1}.mdc-text-field--textarea{flex-direction:column;align-items:center;width:auto;height:auto;padding:0;transition:none}.mdc-text-field--textarea .mdc-floating-label{top:19px}.mdc-text-field--textarea .mdc-floating-label:not(.mdc-floating-label--float-above){transform:none}.mdc-text-field--textarea .mdc-text-field__input{flex-grow:1;height:auto;min-height:1.5rem;overflow-x:hidden;overflow-y:auto;box-sizing:border-box;resize:none;padding:0 16px;line-height:1.5rem}.mdc-text-field--textarea.mdc-text-field--filled::before{display:none}.mdc-text-field--textarea.mdc-text-field--filled .mdc-floating-label--float-above{transform:translateY(-10.25px) scale(0.75)}.mdc-text-field--textarea.mdc-text-field--filled .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-textarea-filled 250ms 1}@keyframes mdc-floating-label-shake-float-above-textarea-filled{0%{transform:translateX(calc(0 - 0%)) translateY(-10.25px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-10.25px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-10.25px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-10.25px) scale(0.75)}}.mdc-text-field--textarea.mdc-text-field--filled .mdc-text-field__input{margin-top:23px;margin-bottom:9px}.mdc-text-field--textarea.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__input{margin-top:16px;margin-bottom:16px}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:0}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-27.25px) scale(1)}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label--float-above{font-size:.75rem}.mdc-text-field--textarea.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--textarea.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-24.75px) scale(0.75)}.mdc-text-field--textarea.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--textarea.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-textarea-outlined 250ms 1}@keyframes mdc-floating-label-shake-float-above-textarea-outlined{0%{transform:translateX(calc(0 - 0%)) translateY(-24.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-24.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-24.75px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-24.75px) scale(0.75)}}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-text-field__input{margin-top:16px;margin-bottom:16px}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label{top:18px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field__input{margin-bottom:2px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field-character-counter{align-self:flex-end;padding:0 16px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field-character-counter::after{display:inline-block;width:0;height:16px;content:"";vertical-align:-16px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field-character-counter::before{display:none}.mdc-text-field__resizer{align-self:stretch;display:inline-flex;flex-direction:column;flex-grow:1;max-height:100%;max-width:100%;min-height:56px;min-width:fit-content;min-width:-moz-available;min-width:-webkit-fill-available;overflow:hidden;resize:both}.mdc-text-field--filled .mdc-text-field__resizer{transform:translateY(-1px)}.mdc-text-field--filled .mdc-text-field__resizer .mdc-text-field__input,.mdc-text-field--filled .mdc-text-field__resizer .mdc-text-field-character-counter{transform:translateY(1px)}.mdc-text-field--outlined .mdc-text-field__resizer{transform:translateX(-1px) translateY(-1px)}[dir=rtl] .mdc-text-field--outlined .mdc-text-field__resizer,.mdc-text-field--outlined .mdc-text-field__resizer[dir=rtl]{transform:translateX(1px) translateY(-1px)}.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field__input,.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field-character-counter{transform:translateX(1px) translateY(1px)}[dir=rtl] .mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field__input,[dir=rtl] .mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field-character-counter,.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field__input[dir=rtl],.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field-character-counter[dir=rtl]{transform:translateX(-1px) translateY(1px)}.mdc-text-field--with-leading-icon{padding-left:0;padding-right:16px}[dir=rtl] .mdc-text-field--with-leading-icon,.mdc-text-field--with-leading-icon[dir=rtl]{padding-left:16px;padding-right:0}.mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label{max-width:calc(100% - 48px);left:48px;right:initial}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label,.mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label[dir=rtl]{left:initial;right:48px}.mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 64px / 0.75)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label{left:36px;right:initial}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label[dir=rtl]{left:initial;right:36px}.mdc-text-field--with-leading-icon.mdc-text-field--outlined :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-37.25px) translateX(-32px) scale(1)}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-37.25px) translateX(32px) scale(1)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above{font-size:.75rem}.mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) translateX(-32px) scale(0.75)}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl],.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-34.75px) translateX(32px) scale(0.75)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-text-field-outlined-leading-icon 250ms 1}@keyframes mdc-floating-label-shake-float-above-text-field-outlined-leading-icon{0%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--shake,.mdc-text-field--with-leading-icon.mdc-text-field--outlined[dir=rtl] .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-text-field-outlined-leading-icon 250ms 1}@keyframes mdc-floating-label-shake-float-above-text-field-outlined-leading-icon-rtl{0%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - -32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - -32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}}.mdc-text-field--with-trailing-icon{padding-left:16px;padding-right:0}[dir=rtl] .mdc-text-field--with-trailing-icon,.mdc-text-field--with-trailing-icon[dir=rtl]{padding-left:0;padding-right:16px}.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label{max-width:calc(100% - 64px)}.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 64px / 0.75)}.mdc-text-field--with-trailing-icon.mdc-text-field--outlined :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon{padding-left:0;padding-right:0}.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label{max-width:calc(100% - 96px)}.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 96px / 0.75)}.mdc-text-field-helper-line{display:flex;justify-content:space-between;box-sizing:border-box}.mdc-text-field+.mdc-text-field-helper-line{padding-right:16px;padding-left:16px}.mdc-form-field>.mdc-text-field+label{align-self:flex-start}.mdc-text-field--focused:not(.mdc-text-field--disabled) .mdc-floating-label{color:rgba(98, 0, 238, 0.87)}.mdc-text-field--focused .mdc-notched-outline__leading,.mdc-text-field--focused .mdc-notched-outline__notch,.mdc-text-field--focused .mdc-notched-outline__trailing{border-width:2px}.mdc-text-field--focused+.mdc-text-field-helper-line .mdc-text-field-helper-text:not(.mdc-text-field-helper-text--validation-msg){opacity:1}.mdc-text-field--focused.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:2px}.mdc-text-field--focused.mdc-text-field--outlined.mdc-text-field--textarea .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:0}.mdc-text-field--invalid:not(.mdc-text-field--disabled):hover .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-line-ripple::after{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-floating-label{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled).mdc-text-field--invalid+.mdc-text-field-helper-line .mdc-text-field-helper-text--validation-msg{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid .mdc-text-field__input{caret-color:#b00020;caret-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-text-field__icon--trailing{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-notched-outline__leading,.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-notched-outline__notch,.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-notched-outline .mdc-notched-outline__leading,.mdc-text-field--invalid:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-notched-outline .mdc-notched-outline__notch,.mdc-text-field--invalid:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-notched-outline .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline__leading,.mdc-text-field--invalid:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline__notch,.mdc-text-field--invalid:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid+.mdc-text-field-helper-line .mdc-text-field-helper-text--validation-msg{opacity:1}.mdc-text-field--disabled{pointer-events:none}.mdc-text-field--disabled .mdc-text-field__input{color:rgba(0, 0, 0, 0.38)}@media all{.mdc-text-field--disabled .mdc-text-field__input::placeholder{color:rgba(0, 0, 0, 0.38)}}@media all{.mdc-text-field--disabled .mdc-text-field__input:-ms-input-placeholder{color:rgba(0, 0, 0, 0.38)}}.mdc-text-field--disabled .mdc-floating-label{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled+.mdc-text-field-helper-line .mdc-text-field-helper-text{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled .mdc-text-field-character-counter,.mdc-text-field--disabled+.mdc-text-field-helper-line .mdc-text-field-character-counter{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled .mdc-text-field__icon--leading{color:rgba(0, 0, 0, 0.3)}.mdc-text-field--disabled .mdc-text-field__icon--trailing{color:rgba(0, 0, 0, 0.3)}.mdc-text-field--disabled .mdc-text-field__affix--prefix{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled .mdc-text-field__affix--suffix{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.06)}.mdc-text-field--disabled .mdc-notched-outline__leading,.mdc-text-field--disabled .mdc-notched-outline__notch,.mdc-text-field--disabled .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.06)}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__input::placeholder{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__input:-ms-input-placeholder{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-floating-label{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled+.mdc-text-field-helper-line .mdc-text-field-helper-text{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field-character-counter,.mdc-text-field--disabled+.mdc-text-field-helper-line .mdc-text-field-character-counter{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__icon--leading{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__icon--trailing{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__affix--prefix{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__affix--suffix{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-line-ripple::before{border-bottom-color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-notched-outline__leading,.mdc-text-field--disabled .mdc-notched-outline__notch,.mdc-text-field--disabled .mdc-notched-outline__trailing{border-color:GrayText}}@media screen and (forced-colors: active){.mdc-text-field--disabled .mdc-text-field__input{background-color:Window}.mdc-text-field--disabled .mdc-floating-label{z-index:1}}.mdc-text-field--disabled .mdc-floating-label{cursor:default}.mdc-text-field--disabled.mdc-text-field--filled{background-color:#fafafa}.mdc-text-field--disabled.mdc-text-field--filled .mdc-text-field__ripple{display:none}.mdc-text-field--disabled .mdc-text-field__input{pointer-events:auto}.mdc-text-field--end-aligned .mdc-text-field__input{text-align:right}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__input,.mdc-text-field--end-aligned .mdc-text-field__input[dir=rtl]{text-align:left}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__input,[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__input,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix{direction:ltr}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--prefix{padding-left:0;padding-right:2px}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--suffix{padding-left:12px;padding-right:0}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__icon--leading,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__icon--leading{order:1}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--suffix{order:2}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__input,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__input{order:3}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--prefix{order:4}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__icon--trailing,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__icon--trailing{order:5}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__input,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__input{text-align:right}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__affix--prefix{padding-right:12px}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__affix--suffix{padding-left:2px}.mdc-text-field-helper-text{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.75rem;font-size:var(--mdc-typography-caption-font-size, 0.75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight, 400);letter-spacing:0.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, 0.0333333333em);text-decoration:inherit;text-decoration:var(--mdc-typography-caption-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform, inherit);display:block;margin-top:0;line-height:normal;margin:0;opacity:0;will-change:opacity;transition:opacity 150ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-text-field-helper-text::before{display:inline-block;width:0;height:16px;content:"";vertical-align:0}.mdc-text-field-helper-text--persistent{transition:none;opacity:1;will-change:initial}.mdc-text-field-character-counter{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.75rem;font-size:var(--mdc-typography-caption-font-size, 0.75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight, 400);letter-spacing:0.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, 0.0333333333em);text-decoration:inherit;text-decoration:var(--mdc-typography-caption-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform, inherit);display:block;margin-top:0;line-height:normal;margin-left:auto;margin-right:0;padding-left:16px;padding-right:0;white-space:nowrap}.mdc-text-field-character-counter::before{display:inline-block;width:0;height:16px;content:"";vertical-align:0}[dir=rtl] .mdc-text-field-character-counter,.mdc-text-field-character-counter[dir=rtl]{margin-left:0;margin-right:auto}[dir=rtl] .mdc-text-field-character-counter,.mdc-text-field-character-counter[dir=rtl]{padding-left:0;padding-right:16px}.mdc-text-field__icon{align-self:center;cursor:pointer}.mdc-text-field__icon:not([tabindex]),.mdc-text-field__icon[tabindex="-1"]{cursor:default;pointer-events:none}.mdc-text-field__icon svg{display:block}.mdc-text-field__icon--leading{margin-left:16px;margin-right:8px}[dir=rtl] .mdc-text-field__icon--leading,.mdc-text-field__icon--leading[dir=rtl]{margin-left:8px;margin-right:16px}.mdc-text-field__icon--trailing{padding:12px;margin-left:0px;margin-right:0px}[dir=rtl] .mdc-text-field__icon--trailing,.mdc-text-field__icon--trailing[dir=rtl]{margin-left:0px;margin-right:0px}.material-icons{font-family:var(--mdc-icon-font, "Material Icons");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:"liga"}:host{display:inline-flex;flex-direction:column;outline:none}.mdc-text-field{width:100%}.mdc-text-field:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.42);border-bottom-color:var(--mdc-text-field-idle-line-color, rgba(0, 0, 0, 0.42))}.mdc-text-field:not(.mdc-text-field--disabled):hover .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.87);border-bottom-color:var(--mdc-text-field-hover-line-color, rgba(0, 0, 0, 0.87))}.mdc-text-field.mdc-text-field--disabled .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.06);border-bottom-color:var(--mdc-text-field-disabled-line-color, rgba(0, 0, 0, 0.06))}.mdc-text-field.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-text-field__input{direction:inherit}mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-outlined-idle-border-color, rgba(0, 0, 0, 0.38) )}:host(:not([disabled]):hover) :not(.mdc-text-field--invalid):not(.mdc-text-field--focused) mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-outlined-hover-border-color, rgba(0, 0, 0, 0.87) )}:host(:not([disabled])) .mdc-text-field:not(.mdc-text-field--outlined){background-color:var(--mdc-text-field-fill-color, whitesmoke)}:host(:not([disabled])) .mdc-text-field.mdc-text-field--invalid mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-error-color, var(--mdc-theme-error, #b00020) )}:host(:not([disabled])) .mdc-text-field.mdc-text-field--invalid+.mdc-text-field-helper-line .mdc-text-field-character-counter,:host(:not([disabled])) .mdc-text-field.mdc-text-field--invalid .mdc-text-field__icon{color:var(--mdc-text-field-error-color, var(--mdc-theme-error, #b00020))}:host(:not([disabled])) .mdc-text-field:not(.mdc-text-field--invalid):not(.mdc-text-field--focused) .mdc-floating-label,:host(:not([disabled])) .mdc-text-field:not(.mdc-text-field--invalid):not(.mdc-text-field--focused) .mdc-floating-label::after{color:var(--mdc-text-field-label-ink-color, rgba(0, 0, 0, 0.6))}:host(:not([disabled])) .mdc-text-field.mdc-text-field--focused mwc-notched-outline{--mdc-notched-outline-stroke-width: 2px}:host(:not([disabled])) .mdc-text-field.mdc-text-field--focused:not(.mdc-text-field--invalid) mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-focused-label-color, var(--mdc-theme-primary, rgba(98, 0, 238, 0.87)) )}:host(:not([disabled])) .mdc-text-field.mdc-text-field--focused:not(.mdc-text-field--invalid) .mdc-floating-label{color:#6200ee;color:var(--mdc-theme-primary, #6200ee)}:host(:not([disabled])) .mdc-text-field .mdc-text-field__input{color:var(--mdc-text-field-ink-color, rgba(0, 0, 0, 0.87))}:host(:not([disabled])) .mdc-text-field .mdc-text-field__input::placeholder{color:var(--mdc-text-field-label-ink-color, rgba(0, 0, 0, 0.6))}:host(:not([disabled])) .mdc-text-field-helper-line .mdc-text-field-helper-text:not(.mdc-text-field-helper-text--validation-msg),:host(:not([disabled])) .mdc-text-field-helper-line:not(.mdc-text-field--invalid) .mdc-text-field-character-counter{color:var(--mdc-text-field-label-ink-color, rgba(0, 0, 0, 0.6))}:host([disabled]) .mdc-text-field:not(.mdc-text-field--outlined){background-color:var(--mdc-text-field-disabled-fill-color, #fafafa)}:host([disabled]) .mdc-text-field.mdc-text-field--outlined mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-outlined-disabled-border-color, rgba(0, 0, 0, 0.06) )}:host([disabled]) .mdc-text-field:not(.mdc-text-field--invalid):not(.mdc-text-field--focused) .mdc-floating-label,:host([disabled]) .mdc-text-field:not(.mdc-text-field--invalid):not(.mdc-text-field--focused) .mdc-floating-label::after{color:var(--mdc-text-field-disabled-ink-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-text-field .mdc-text-field__input,:host([disabled]) .mdc-text-field .mdc-text-field__input::placeholder{color:var(--mdc-text-field-disabled-ink-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-text-field-helper-line .mdc-text-field-helper-text,:host([disabled]) .mdc-text-field-helper-line .mdc-text-field-character-counter{color:var(--mdc-text-field-disabled-ink-color, rgba(0, 0, 0, 0.38))}`;
-
-let PoLRTextfield = class PoLRTextfield extends TextFieldBase {
- renderLeadingIcon() {
- if (!this.icon) {
- return x ``;
- }
- return x `.mdc-text-field+label{align-self:flex-start}.mdc-text-field--focused:not(.mdc-text-field--disabled) .mdc-floating-label{color:rgba(98, 0, 238, 0.87)}.mdc-text-field--focused .mdc-notched-outline__leading,.mdc-text-field--focused .mdc-notched-outline__notch,.mdc-text-field--focused .mdc-notched-outline__trailing{border-width:2px}.mdc-text-field--focused+.mdc-text-field-helper-line .mdc-text-field-helper-text:not(.mdc-text-field-helper-text--validation-msg){opacity:1}.mdc-text-field--focused.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:2px}.mdc-text-field--focused.mdc-text-field--outlined.mdc-text-field--textarea .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:0}.mdc-text-field--invalid:not(.mdc-text-field--disabled):hover .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-line-ripple::after{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-floating-label{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled).mdc-text-field--invalid+.mdc-text-field-helper-line .mdc-text-field-helper-text--validation-msg{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid .mdc-text-field__input{caret-color:#b00020;caret-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-text-field__icon--trailing{color:#b00020;color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-notched-outline__leading,.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-notched-outline__notch,.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-notched-outline .mdc-notched-outline__leading,.mdc-text-field--invalid:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-notched-outline .mdc-notched-outline__notch,.mdc-text-field--invalid:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-notched-outline .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline__leading,.mdc-text-field--invalid:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline__notch,.mdc-text-field--invalid:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline__trailing{border-color:#b00020;border-color:var(--mdc-theme-error, #b00020)}.mdc-text-field--invalid+.mdc-text-field-helper-line .mdc-text-field-helper-text--validation-msg{opacity:1}.mdc-text-field--disabled{pointer-events:none}.mdc-text-field--disabled .mdc-text-field__input{color:rgba(0, 0, 0, 0.38)}@media all{.mdc-text-field--disabled .mdc-text-field__input::placeholder{color:rgba(0, 0, 0, 0.38)}}@media all{.mdc-text-field--disabled .mdc-text-field__input:-ms-input-placeholder{color:rgba(0, 0, 0, 0.38)}}.mdc-text-field--disabled .mdc-floating-label{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled+.mdc-text-field-helper-line .mdc-text-field-helper-text{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled .mdc-text-field-character-counter,.mdc-text-field--disabled+.mdc-text-field-helper-line .mdc-text-field-character-counter{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled .mdc-text-field__icon--leading{color:rgba(0, 0, 0, 0.3)}.mdc-text-field--disabled .mdc-text-field__icon--trailing{color:rgba(0, 0, 0, 0.3)}.mdc-text-field--disabled .mdc-text-field__affix--prefix{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled .mdc-text-field__affix--suffix{color:rgba(0, 0, 0, 0.38)}.mdc-text-field--disabled .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.06)}.mdc-text-field--disabled .mdc-notched-outline__leading,.mdc-text-field--disabled .mdc-notched-outline__notch,.mdc-text-field--disabled .mdc-notched-outline__trailing{border-color:rgba(0, 0, 0, 0.06)}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__input::placeholder{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__input:-ms-input-placeholder{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-floating-label{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled+.mdc-text-field-helper-line .mdc-text-field-helper-text{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field-character-counter,.mdc-text-field--disabled+.mdc-text-field-helper-line .mdc-text-field-character-counter{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__icon--leading{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__icon--trailing{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__affix--prefix{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-text-field__affix--suffix{color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-line-ripple::before{border-bottom-color:GrayText}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-text-field--disabled .mdc-notched-outline__leading,.mdc-text-field--disabled .mdc-notched-outline__notch,.mdc-text-field--disabled .mdc-notched-outline__trailing{border-color:GrayText}}@media screen and (forced-colors: active){.mdc-text-field--disabled .mdc-text-field__input{background-color:Window}.mdc-text-field--disabled .mdc-floating-label{z-index:1}}.mdc-text-field--disabled .mdc-floating-label{cursor:default}.mdc-text-field--disabled.mdc-text-field--filled{background-color:#fafafa}.mdc-text-field--disabled.mdc-text-field--filled .mdc-text-field__ripple{display:none}.mdc-text-field--disabled .mdc-text-field__input{pointer-events:auto}.mdc-text-field--end-aligned .mdc-text-field__input{text-align:right}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__input,.mdc-text-field--end-aligned .mdc-text-field__input[dir=rtl]{text-align:left}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__input,[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__input,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix{direction:ltr}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--prefix{padding-left:0;padding-right:2px}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--suffix{padding-left:12px;padding-right:0}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__icon--leading,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__icon--leading{order:1}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--suffix{order:2}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__input,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__input{order:3}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--prefix{order:4}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__icon--trailing,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__icon--trailing{order:5}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__input,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__input{text-align:right}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__affix--prefix{padding-right:12px}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__affix--suffix{padding-left:2px}.mdc-text-field-helper-text{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.75rem;font-size:var(--mdc-typography-caption-font-size, 0.75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight, 400);letter-spacing:0.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, 0.0333333333em);text-decoration:inherit;text-decoration:var(--mdc-typography-caption-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform, inherit);display:block;margin-top:0;line-height:normal;margin:0;opacity:0;will-change:opacity;transition:opacity 150ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-text-field-helper-text::before{display:inline-block;width:0;height:16px;content:"";vertical-align:0}.mdc-text-field-helper-text--persistent{transition:none;opacity:1;will-change:initial}.mdc-text-field-character-counter{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.75rem;font-size:var(--mdc-typography-caption-font-size, 0.75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight, 400);letter-spacing:0.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, 0.0333333333em);text-decoration:inherit;text-decoration:var(--mdc-typography-caption-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform, inherit);display:block;margin-top:0;line-height:normal;margin-left:auto;margin-right:0;padding-left:16px;padding-right:0;white-space:nowrap}.mdc-text-field-character-counter::before{display:inline-block;width:0;height:16px;content:"";vertical-align:0}[dir=rtl] .mdc-text-field-character-counter,.mdc-text-field-character-counter[dir=rtl]{margin-left:0;margin-right:auto}[dir=rtl] .mdc-text-field-character-counter,.mdc-text-field-character-counter[dir=rtl]{padding-left:0;padding-right:16px}.mdc-text-field__icon{align-self:center;cursor:pointer}.mdc-text-field__icon:not([tabindex]),.mdc-text-field__icon[tabindex="-1"]{cursor:default;pointer-events:none}.mdc-text-field__icon svg{display:block}.mdc-text-field__icon--leading{margin-left:16px;margin-right:8px}[dir=rtl] .mdc-text-field__icon--leading,.mdc-text-field__icon--leading[dir=rtl]{margin-left:8px;margin-right:16px}.mdc-text-field__icon--trailing{padding:12px;margin-left:0px;margin-right:0px}[dir=rtl] .mdc-text-field__icon--trailing,.mdc-text-field__icon--trailing[dir=rtl]{margin-left:0px;margin-right:0px}.material-icons{font-family:var(--mdc-icon-font, "Material Icons");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:"liga"}:host{display:inline-flex;flex-direction:column;outline:none}.mdc-text-field{width:100%}.mdc-text-field:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.42);border-bottom-color:var(--mdc-text-field-idle-line-color, rgba(0, 0, 0, 0.42))}.mdc-text-field:not(.mdc-text-field--disabled):hover .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.87);border-bottom-color:var(--mdc-text-field-hover-line-color, rgba(0, 0, 0, 0.87))}.mdc-text-field.mdc-text-field--disabled .mdc-line-ripple::before{border-bottom-color:rgba(0, 0, 0, 0.06);border-bottom-color:var(--mdc-text-field-disabled-line-color, rgba(0, 0, 0, 0.06))}.mdc-text-field.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:#b00020;border-bottom-color:var(--mdc-theme-error, #b00020)}.mdc-text-field__input{direction:inherit}mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-outlined-idle-border-color, rgba(0, 0, 0, 0.38) )}:host(:not([disabled]):hover) :not(.mdc-text-field--invalid):not(.mdc-text-field--focused) mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-outlined-hover-border-color, rgba(0, 0, 0, 0.87) )}:host(:not([disabled])) .mdc-text-field:not(.mdc-text-field--outlined){background-color:var(--mdc-text-field-fill-color, whitesmoke)}:host(:not([disabled])) .mdc-text-field.mdc-text-field--invalid mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-error-color, var(--mdc-theme-error, #b00020) )}:host(:not([disabled])) .mdc-text-field.mdc-text-field--invalid+.mdc-text-field-helper-line .mdc-text-field-character-counter,:host(:not([disabled])) .mdc-text-field.mdc-text-field--invalid .mdc-text-field__icon{color:var(--mdc-text-field-error-color, var(--mdc-theme-error, #b00020))}:host(:not([disabled])) .mdc-text-field:not(.mdc-text-field--invalid):not(.mdc-text-field--focused) .mdc-floating-label,:host(:not([disabled])) .mdc-text-field:not(.mdc-text-field--invalid):not(.mdc-text-field--focused) .mdc-floating-label::after{color:var(--mdc-text-field-label-ink-color, rgba(0, 0, 0, 0.6))}:host(:not([disabled])) .mdc-text-field.mdc-text-field--focused mwc-notched-outline{--mdc-notched-outline-stroke-width: 2px}:host(:not([disabled])) .mdc-text-field.mdc-text-field--focused:not(.mdc-text-field--invalid) mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-focused-label-color, var(--mdc-theme-primary, rgba(98, 0, 238, 0.87)) )}:host(:not([disabled])) .mdc-text-field.mdc-text-field--focused:not(.mdc-text-field--invalid) .mdc-floating-label{color:#6200ee;color:var(--mdc-theme-primary, #6200ee)}:host(:not([disabled])) .mdc-text-field .mdc-text-field__input{color:var(--mdc-text-field-ink-color, rgba(0, 0, 0, 0.87))}:host(:not([disabled])) .mdc-text-field .mdc-text-field__input::placeholder{color:var(--mdc-text-field-label-ink-color, rgba(0, 0, 0, 0.6))}:host(:not([disabled])) .mdc-text-field-helper-line .mdc-text-field-helper-text:not(.mdc-text-field-helper-text--validation-msg),:host(:not([disabled])) .mdc-text-field-helper-line:not(.mdc-text-field--invalid) .mdc-text-field-character-counter{color:var(--mdc-text-field-label-ink-color, rgba(0, 0, 0, 0.6))}:host([disabled]) .mdc-text-field:not(.mdc-text-field--outlined){background-color:var(--mdc-text-field-disabled-fill-color, #fafafa)}:host([disabled]) .mdc-text-field.mdc-text-field--outlined mwc-notched-outline{--mdc-notched-outline-border-color: var( --mdc-text-field-outlined-disabled-border-color, rgba(0, 0, 0, 0.06) )}:host([disabled]) .mdc-text-field:not(.mdc-text-field--invalid):not(.mdc-text-field--focused) .mdc-floating-label,:host([disabled]) .mdc-text-field:not(.mdc-text-field--invalid):not(.mdc-text-field--focused) .mdc-floating-label::after{color:var(--mdc-text-field-disabled-ink-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-text-field .mdc-text-field__input,:host([disabled]) .mdc-text-field .mdc-text-field__input::placeholder{color:var(--mdc-text-field-disabled-ink-color, rgba(0, 0, 0, 0.38))}:host([disabled]) .mdc-text-field-helper-line .mdc-text-field-helper-text,:host([disabled]) .mdc-text-field-helper-line .mdc-text-field-character-counter{color:var(--mdc-text-field-disabled-ink-color, rgba(0, 0, 0, 0.38))}`;let ui=class extends hi{renderLeadingIcon(){return this.icon?B` `;
- }
-};
-PoLRTextfield.styles = [
- styles$5,
- i$5 `
+ > `:B``}};ui.styles=[pi,s`
.mdc-text-field--outlined {
height: var(--textfield-height, 56px) !important;
overflow: visible;
@@ -4305,41 +680,15 @@ PoLRTextfield.styles = [
--mdc-icon-size: 12px;
padding: 8px;
}
- `,
-];
-__decorate([
- n$3({ type: Boolean })
-], PoLRTextfield.prototype, "icon", void 0);
-PoLRTextfield = __decorate([
- e$5("polr-textfield")
-], PoLRTextfield);
-
-let PoLRYTubeBrowser = class PoLRYTubeBrowser extends s$1 {
- constructor() {
- super(...arguments);
- this._browseHistory = [];
- this._previousBrowseHistory = [];
- }
- firstUpdated(_changedProperties) {
- this._polrYTubeList = this.renderRoot.querySelector("polr-ytube-list");
- this._searchTextField = this.renderRoot.querySelector("#query");
- if (this.initialAction) {
- this._browse(this.initialAction);
- }
- }
- render() {
- return x `
+ `],n([ht({type:Boolean})],ui.prototype,"icon",void 0),ui=n([ct("polr-textfield")],ui);let fi=class extends ot{constructor(){super(...arguments),this._browseHistory=[],this._previousBrowseHistory=[]}firstUpdated(t){this._polrYTubeList=this.renderRoot.querySelector("polr-ytube-list"),this._searchTextField=this.renderRoot.querySelector("#query"),this.initialAction&&this._browse(this.initialAction)}render(){return B`
${this._renderSearch()} ${this._renderNavigation()}
this._browse(ev.detail.action)}>
+ @navigate=${t=>this._browse(t.detail.action)}>
- `;
- }
- _renderSearch() {
- return x `
+ `}_renderSearch(){return B`
- `;
- }
- loadElement(element) {
- this._browseHistory = [];
- this._browse(element);
- }
- async _browse(element) {
- var _a;
- this._polrYTubeList.state = 4 /* PoLRYTubeListState.LOADING */;
- this._browseHistory.push(element);
- if (((_a = element.children) === null || _a === void 0 ? void 0 : _a.length) > 0) {
- this._polrYTubeList.elements = element["children"];
- this._polrYTubeList.state = 2 /* PoLRYTubeListState.HAS_RESULTS */;
- }
- else {
- try {
- const response = await this.hass.callWS({
- type: "media_player/browse_media",
- entity_id: this.entity["entity_id"],
- media_content_type: element.media_content_type,
- media_content_id: element.media_content_id,
- });
- this._polrYTubeList.elements = response["children"];
- this._polrYTubeList.state = 2 /* PoLRYTubeListState.HAS_RESULTS */;
- }
- catch (e) {
- this._polrYTubeList.state = 16 /* PoLRYTubeListState.ERROR */;
- console.error(e, element.media_content_type, element.media_content_id);
- }
- }
- this.requestUpdate();
- }
- async _fetchSearchResults() {
- var _a, _b;
- this._polrYTubeList.state = 4 /* PoLRYTubeListState.LOADING */;
- try {
- let response = await this.hass.callWS({
- type: "media_player/browse_media",
- entity_id: (_a = this.entity) === null || _a === void 0 ? void 0 : _a.entity_id,
- media_content_type: "search",
- media_content_id: "",
- });
- if (((_b = response["children"]) === null || _b === void 0 ? void 0 : _b.length) > 0) {
- // TODO: Move to ytube_music_player component,
- // instead of handling in frontend
- // Filter out community playlists of podcast
- response["children"].filter((el) => !el["media_content_id"].startsWith("MPSP"));
- if (!this._isSearchResults)
- this._previousBrowseHistory = this._browseHistory;
- this._isSearchResults = true;
- this._browseHistory = [];
- this._browse(response);
- this.requestUpdate();
- }
- else
- this._polrYTubeList.state = 8 /* PoLRYTubeListState.NO_RESULTS */;
- }
- catch (e) {
- this._polrYTubeList.state = 16 /* PoLRYTubeListState.ERROR */;
- console.error(e);
- }
- }
- _renderNavigation() {
- if (this._browseHistory.length <= 1 && !this._isSearchResults)
- return x ``;
- let breadcrumbItems;
- if (this._browseHistory.length > 2) {
- breadcrumbItems = [
- this._browseHistory[0].title,
- "...",
- this._browseHistory[this._browseHistory.length - 1].title,
- ];
- }
- else {
- breadcrumbItems = this._browseHistory.map((item) => item.title);
- }
- let breadcrumb = x `
- ${o$3(o$2(breadcrumbItems, (i) => x `${i} `), x `/ `)}
- `;
- return x `
+ `}loadElement(t){this._browseHistory=[],this._browse(t)}async _browse(t){var e;if(this._polrYTubeList.state=4,this._browseHistory.push(t),(null===(e=t.children)||void 0===e?void 0:e.length)>0)this._polrYTubeList.elements=t.children,this._polrYTubeList.state=2;else try{const e=await this.hass.callWS({type:"media_player/browse_media",entity_id:this.entity.entity_id,media_content_type:t.media_content_type,media_content_id:t.media_content_id});this._polrYTubeList.elements=e.children,this._polrYTubeList.state=2}catch(e){this._polrYTubeList.state=16,console.error(e,t.media_content_type,t.media_content_id)}this.requestUpdate()}async _fetchSearchResults(){var t,e;this._polrYTubeList.state=4;try{let i=await this.hass.callWS({type:"media_player/browse_media",entity_id:null===(t=this.entity)||void 0===t?void 0:t.entity_id,media_content_type:"search",media_content_id:""});(null===(e=i.children)||void 0===e?void 0:e.length)>0?(i.children.filter((t=>!t.media_content_id.startsWith("MPSP"))),this._isSearchResults||(this._previousBrowseHistory=this._browseHistory),this._isSearchResults=!0,this._browseHistory=[],this._browse(i),this.requestUpdate()):this._polrYTubeList.state=8}catch(t){this._polrYTubeList.state=16,console.error(t)}}_renderNavigation(){if(this._browseHistory.length<=1&&!this._isSearchResults)return B``;let t;t=this._browseHistory.length>2?[this._browseHistory[0].title,"...",this._browseHistory[this._browseHistory.length-1].title]:this._browseHistory.map((t=>t.title));let e=B`
+ ${
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+function*(t,e){const i="function"==typeof e;if(void 0!==t){let n=-1;for(const r of t)n>-1&&(yield i?e(n):e),n++,yield r}}
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */(function*(t,e){if(void 0!==t){let i=0;for(const n of t)yield e(n,i++)}}(t,(t=>B`${t} `)),B`/ `)}
+ `;return B`
- ${this._isSearchResults
- ? x `
+ ${this._isSearchResults?B`
{
- this._isSearchResults = false;
- this._browseHistory =
- this._previousBrowseHistory;
- this._searchTextField.value = "";
- this._browse(this._browseHistory.pop());
- }}>
- ${CloseIcon}
+ @click=${()=>{this._isSearchResults=!1,this._browseHistory=this._previousBrowseHistory,this._searchTextField.value="",this._browse(this._browseHistory.pop())}}>
+ ${Ct}
- `
- : A}
- ${this._browseHistory.length > 1
- ? x `
+ `:Y}
+ ${this._browseHistory.length>1?B`
this._browse(this._browseHistory.pop() &&
- this._browseHistory.pop())}>
- ${ArrowLeftIcon}
+ @click=${()=>this._browse(this._browseHistory.pop()&&this._browseHistory.pop())}>
+ ${Et}
- `
- : A}
- ${this._browseHistory.length > 1 || this._isSearchResults
- ? x `
${breadcrumb}
`
- : A}
+ `:Y}
+ ${this._browseHistory.length>1||this._isSearchResults?B`
${e}
`:Y}
- `;
- }
- _handleSearchInput(ev) {
- if (ev.keyCode == 13) {
- this._search();
- this._searchTextField.blur();
- }
- }
- async _search() {
- var _a, _b, _c, _d;
- const query = (_a = this.shadowRoot.querySelector("#query")) === null || _a === void 0 ? void 0 : _a.value;
- const filter = (_b = this.renderRoot.querySelector("#filter")) === null || _b === void 0 ? void 0 : _b.selected.value;
- if (query == "")
- return;
- let data;
- if (filter == "all") {
- data = {
- entity_id: (_c = this.entity) === null || _c === void 0 ? void 0 : _c.entity_id,
- query: query,
- limit: 40,
- };
- }
- else {
- data = {
- entity_id: (_d = this.entity) === null || _d === void 0 ? void 0 : _d.entity_id,
- query: query,
- filter: filter,
- limit: 40,
- };
- }
- await this.hass.callService("ytube_music_player", "search", data);
- this._fetchSearchResults();
- }
- static get styles() {
- return [
- i$5 `
+ `}_handleSearchInput(t){13==t.keyCode&&(this._search(),this._searchTextField.blur())}async _search(){var t,e,i,n;const r=null===(t=this.shadowRoot.querySelector("#query"))||void 0===t?void 0:t.value,a=null===(e=this.renderRoot.querySelector("#filter"))||void 0===e?void 0:e.selected.value;if(""==r)return;let l;l="all"==a?{entity_id:null===(i=this.entity)||void 0===i?void 0:i.entity_id,query:r,limit:40}:{entity_id:null===(n=this.entity)||void 0===n?void 0:n.entity_id,query:r,filter:a,limit:40},await this.hass.callService("ytube_music_player","search",l),this._fetchSearchResults()}static get styles(){return[s`
.container {
display: flex;
overflow: auto;
@@ -4568,88 +803,24 @@ let PoLRYTubeBrowser = class PoLRYTubeBrowser extends s$1 {
#query {
--textfield-height: 42px;
}
- `,
- ];
- }
-};
-__decorate([
- t$1()
-], PoLRYTubeBrowser.prototype, "entity", void 0);
-__decorate([
- t$1()
-], PoLRYTubeBrowser.prototype, "hass", void 0);
-__decorate([
- t$1()
-], PoLRYTubeBrowser.prototype, "initialAction", void 0);
-__decorate([
- t$1()
-], PoLRYTubeBrowser.prototype, "initialElements", void 0);
-__decorate([
- t$1()
-], PoLRYTubeBrowser.prototype, "_browseHistory", void 0);
-__decorate([
- t$1()
-], PoLRYTubeBrowser.prototype, "_previousBrowseHistory", void 0);
-__decorate([
- t$1()
-], PoLRYTubeBrowser.prototype, "_polrYTubeList", void 0);
-__decorate([
- t$1()
-], PoLRYTubeBrowser.prototype, "_searchTextField", void 0);
-__decorate([
- t$1()
-], PoLRYTubeBrowser.prototype, "_isSearchResults", void 0);
-PoLRYTubeBrowser = __decorate([
- e$5("polr-ytube-browser")
-], PoLRYTubeBrowser);
-
+ `]}};n([pt()],fi.prototype,"entity",void 0),n([pt()],fi.prototype,"hass",void 0),n([pt()],fi.prototype,"initialAction",void 0),n([pt()],fi.prototype,"initialElements",void 0),n([pt()],fi.prototype,"_browseHistory",void 0),n([pt()],fi.prototype,"_previousBrowseHistory",void 0),n([pt()],fi.prototype,"_polrYTubeList",void 0),n([pt()],fi.prototype,"_searchTextField",void 0),n([pt()],fi.prototype,"_isSearchResults",void 0),fi=n([ct("polr-ytube-browser")],fi);
/**
* @license
* Copyright 2019 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
-/** @soyCompatible */
-let TextField = class TextField extends TextFieldBase {
-};
-TextField.styles = [styles$5];
-TextField = __decorate([
- e$5('mwc-textfield')
-], TextField);
-
+let gi=class extends hi{};gi.styles=[pi],gi=n([ct("mwc-textfield")],gi);
/**
* @license
* Copyright 2020 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
-let Select = class Select extends SelectBase {
-};
-Select.styles = [styles$6];
-Select = __decorate([
- e$5('mwc-select')
-], Select);
-
-let PoLRYTubeSearch = class PoLRYTubeSearch extends s$1 {
- constructor() {
- super();
- this._elements = [];
- this._limit = 25;
- }
- firstUpdated(_changedProperties) {
- this._polrYTubeBrowser =
- this.renderRoot.querySelector("polr-ytube-browser");
- this._searchTextField = this.renderRoot.querySelector("#query");
- }
- _renderResults() {
- console.log(this._elements);
- return x `
+let bi=class extends Ge{};bi.styles=[Ze],bi=n([ct("mwc-select")],bi);let vi=class extends ot{constructor(){super(),this._elements=[],this._limit=25}firstUpdated(t){this._polrYTubeBrowser=this.renderRoot.querySelector("polr-ytube-browser"),this._searchTextField=this.renderRoot.querySelector("#query")}_renderResults(){return console.log(this._elements),B`
- `;
- }
- render() {
- return x `
+ `}render(){return B`
- `;
- }
- async _fetchResults() {
- //this._polrYTubeList.state = PoLRYTubeListState.LOADING;
- var _a, _b;
- try {
- let response = await this._hass.callWS({
- type: "media_player/browse_media",
- entity_id: (_a = this._entity) === null || _a === void 0 ? void 0 : _a.entity_id,
- media_content_type: "search",
- media_content_id: "",
- });
- if (((_b = response["children"]) === null || _b === void 0 ? void 0 : _b.length) > 0) {
- // TODO: Move to ytube_music_player component,
- // instead of handling in frontend
- // Filter out community playlists of podcast
- response["children"].filter((el) => !el["media_content_id"].startsWith("MPSP"));
- //this._polrYTubeList.state = PoLRYTubeListState.HAS_RESULTS;
- //this._polrYTubeList.elements = response["children"];
- this._elements = response;
- this._polrYTubeBrowser.loadElement(response);
- console.log(this._elements);
- this.requestUpdate();
- } //else //this._polrYTubeList.state = PoLRYTubeListState.NO_RESULTS;
- }
- catch (e) {
- // this._polrYTubeList.state = PoLRYTubeListState.ERROR;
- console.error(e);
- }
- }
- handleKey(ev) {
- if (ev.keyCode == 13) {
- this._search();
- this._searchTextField.blur();
- }
- }
- async _search() {
- var _a, _b;
- //this._polrYTubeList.state = PoLRYTubeListState.LOADING;
- const query = this.shadowRoot.querySelector("#query").value;
- const filter = this.renderRoot.querySelector("#filter")
- .selected.value;
- let data;
- if (filter == "all") {
- data = {
- entity_id: (_a = this._entity) === null || _a === void 0 ? void 0 : _a.entity_id,
- query: query,
- limit: this._limit,
- };
- }
- else {
- data = {
- entity_id: (_b = this._entity) === null || _b === void 0 ? void 0 : _b.entity_id,
- query: query,
- filter: filter,
- limit: this._limit,
- };
- }
- await this._hass.callService("ytube_music_player", "search", data);
- this._fetchResults();
- }
-};
-PoLRYTubeSearch.styles = i$5 `
+ `}async _fetchResults(){var t,e;try{let i=await this._hass.callWS({type:"media_player/browse_media",entity_id:null===(t=this._entity)||void 0===t?void 0:t.entity_id,media_content_type:"search",media_content_id:""});(null===(e=i.children)||void 0===e?void 0:e.length)>0&&(i.children.filter((t=>!t.media_content_id.startsWith("MPSP"))),this._elements=i,this._polrYTubeBrowser.loadElement(i),console.log(this._elements),this.requestUpdate())}catch(t){console.error(t)}}handleKey(t){13==t.keyCode&&(this._search(),this._searchTextField.blur())}async _search(){var t,e;const i=this.shadowRoot.querySelector("#query").value,n=this.renderRoot.querySelector("#filter").selected.value;let r;r="all"==n?{entity_id:null===(t=this._entity)||void 0===t?void 0:t.entity_id,query:i,limit:this._limit}:{entity_id:null===(e=this._entity)||void 0===e?void 0:e.entity_id,query:i,filter:n,limit:this._limit},await this._hass.callService("ytube_music_player","search",r),this._fetchResults()}};vi.styles=s`
.search {
display: grid;
grid-template-columns: 1fr min-content;
align-items: center;
gap: 4px;
}
- `;
-__decorate([
- t$1()
-], PoLRYTubeSearch.prototype, "_hass", void 0);
-__decorate([
- t$1()
-], PoLRYTubeSearch.prototype, "_entity", void 0);
-__decorate([
- t$1()
-], PoLRYTubeSearch.prototype, "_limit", void 0);
-__decorate([
- t$1()
-], PoLRYTubeSearch.prototype, "_polrYTubeBrowser", void 0);
-__decorate([
- t$1()
-], PoLRYTubeSearch.prototype, "_elements", void 0);
-__decorate([
- t$1()
-], PoLRYTubeSearch.prototype, "_searchTextField", void 0);
-__decorate([
- t$1()
-], PoLRYTubeSearch.prototype, "initialAction", void 0);
-PoLRYTubeSearch = __decorate([
- e$5("polr-ytube-search")
-], PoLRYTubeSearch);
-
-class PoLRYTubeSearchCard extends s$1 {
- constructor() {
- super(...arguments);
- this._config = {};
- this._runOnce = false;
- }
- static getConfigElement() {
- // return document.createElement("polr-ytube-search-card-editor");
- }
- static getStubConfig() {
- return {};
- }
- setConfig(config) {
- if (!config.entity_id) {
- throw new Error("entity_id must be specified");
- }
- this._config = structuredClone(config);
- if (!("header" in this._config))
- this._config.header = "YouTube Music Search";
- if (!("showHeader" in this._config))
- this._config.showHeader = false;
- if (!("icon" in this._config))
- this._config.searchTitle = "mdi:speaker";
- }
- set hass(hass) {
- if (!this._runOnce) {
- this._hass = hass;
- this._entity = structuredClone(this._hass["states"][this._config["entity_id"]]);
- this._runOnce = true;
- }
- }
- render() {
- const header = this._config["showHeader"]
- ? x `
+ `,n([pt()],vi.prototype,"_hass",void 0),n([pt()],vi.prototype,"_entity",void 0),n([pt()],vi.prototype,"_limit",void 0),n([pt()],vi.prototype,"_polrYTubeBrowser",void 0),n([pt()],vi.prototype,"_elements",void 0),n([pt()],vi.prototype,"_searchTextField",void 0),n([pt()],vi.prototype,"initialAction",void 0),vi=n([ct("polr-ytube-search")],vi);class _i extends ot{constructor(){super(...arguments),this._config={},this._runOnce=!1}static getConfigElement(){}static getStubConfig(){return{}}setConfig(t){if(!t.entity_id)throw new Error("entity_id must be specified");this._config=structuredClone(t),"header"in this._config||(this._config.header="YouTube Music Search"),"showHeader"in this._config||(this._config.showHeader=!1),"icon"in this._config||(this._config.searchTitle="mdi:speaker")}set hass(t){this._runOnce||(this._hass=t,this._entity=structuredClone(this._hass.states[this._config.entity_id]),this._runOnce=!0)}render(){const t=this._config.showHeader?B`
- `
- : x ``;
- return x `
+ `:B``;return B`
- ${header}
+ ${t}
- `;
- }
-}
-PoLRYTubeSearchCard.styles = i$5 `
+ `}}_i.styles=s`
ha-card {
overflow: hidden;
}
@@ -4871,1395 +916,14 @@ PoLRYTubeSearchCard.styles = i$5 `
.content {
padding: 12px 12px 12px 12px;
- }
- `;
-__decorate([
- n$3()
-], PoLRYTubeSearchCard.prototype, "_config", void 0);
-__decorate([
- n$3()
-], PoLRYTubeSearchCard.prototype, "_hass", void 0);
-__decorate([
- t$1()
-], PoLRYTubeSearchCard.prototype, "_entity", void 0);
-__decorate([
- t$1()
-], PoLRYTubeSearchCard.prototype, "_runOnce", void 0);
-customElements.define("polr-ytube-search-card", PoLRYTubeSearchCard);
-// This puts your card into the UI card picker dialog
-window.customCards = window.customCards || [];
-window.customCards.push({
- type: "polr-ytube-search-card",
- name: "PoLR YouTube Search",
- description: "Requires the ytube_media_player integration",
-});
-
-/**
- * @license
- * Copyright 2020 Google LLC
- * SPDX-License-Identifier: Apache-2.0
- */
-/**
- * Class that encapsulates the events handlers for `mwc-ripple`
- *
- *
- * Example:
- * ```
- * class XFoo extends LitElement {
- * async getRipple() {
- * this.renderRipple = true;
- * await this.updateComplete;
- * return this.renderRoot.querySelector('mwc-ripple');
- * }
- * rippleHandlers = new RippleHandlers(() => this.getRipple());
- *
- * render() {
- * return html`
- *
- * ${this.renderRipple ? html`
` : ''}
- * `;
- * }
- * }
- * ```
- */
-class RippleHandlers {
- constructor(
- /** Function that returns a `mwc-ripple` */
- rippleFn) {
- this.startPress = (ev) => {
- rippleFn().then((r) => {
- r && r.startPress(ev);
- });
- };
- this.endPress = () => {
- rippleFn().then((r) => {
- r && r.endPress();
- });
- };
- this.startFocus = () => {
- rippleFn().then((r) => {
- r && r.startFocus();
- });
- };
- this.endFocus = () => {
- rippleFn().then((r) => {
- r && r.endFocus();
- });
- };
- this.startHover = () => {
- rippleFn().then((r) => {
- r && r.startHover();
- });
- };
- this.endHover = () => {
- rippleFn().then((r) => {
- r && r.endHover();
- });
- };
- }
-}
-
-/**
- * @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-var cssClasses$2 = {
- ACTIVE: 'mdc-tab--active',
-};
-var strings$3 = {
- ARIA_SELECTED: 'aria-selected',
- CONTENT_SELECTOR: '.mdc-tab__content',
- INTERACTED_EVENT: 'MDCTab:interacted',
- RIPPLE_SELECTOR: '.mdc-tab__ripple',
- TABINDEX: 'tabIndex',
- TAB_INDICATOR_SELECTOR: '.mdc-tab-indicator',
-};
-
-/**
- * @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-var MDCTabFoundation = /** @class */ (function (_super) {
- __extends(MDCTabFoundation, _super);
- function MDCTabFoundation(adapter) {
- var _this = _super.call(this, __assign(__assign({}, MDCTabFoundation.defaultAdapter), adapter)) || this;
- _this.focusOnActivate = true;
- return _this;
- }
- Object.defineProperty(MDCTabFoundation, "cssClasses", {
- get: function () {
- return cssClasses$2;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTabFoundation, "strings", {
- get: function () {
- return strings$3;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTabFoundation, "defaultAdapter", {
- get: function () {
- // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
- return {
- addClass: function () { return undefined; },
- removeClass: function () { return undefined; },
- hasClass: function () { return false; },
- setAttr: function () { return undefined; },
- activateIndicator: function () { return undefined; },
- deactivateIndicator: function () { return undefined; },
- notifyInteracted: function () { return undefined; },
- getOffsetLeft: function () { return 0; },
- getOffsetWidth: function () { return 0; },
- getContentOffsetLeft: function () { return 0; },
- getContentOffsetWidth: function () { return 0; },
- focus: function () { return undefined; },
- };
- // tslint:enable:object-literal-sort-keys
- },
- enumerable: false,
- configurable: true
- });
- MDCTabFoundation.prototype.handleClick = function () {
- // It's up to the parent component to keep track of the active Tab and
- // ensure we don't activate a Tab that's already active.
- this.adapter.notifyInteracted();
- };
- MDCTabFoundation.prototype.isActive = function () {
- return this.adapter.hasClass(cssClasses$2.ACTIVE);
- };
- /**
- * Sets whether the tab should focus itself when activated
- */
- MDCTabFoundation.prototype.setFocusOnActivate = function (focusOnActivate) {
- this.focusOnActivate = focusOnActivate;
- };
- /**
- * Activates the Tab
- */
- MDCTabFoundation.prototype.activate = function (previousIndicatorClientRect) {
- this.adapter.addClass(cssClasses$2.ACTIVE);
- this.adapter.setAttr(strings$3.ARIA_SELECTED, 'true');
- this.adapter.setAttr(strings$3.TABINDEX, '0');
- this.adapter.activateIndicator(previousIndicatorClientRect);
- if (this.focusOnActivate) {
- this.adapter.focus();
- }
- };
- /**
- * Deactivates the Tab
- */
- MDCTabFoundation.prototype.deactivate = function () {
- // Early exit
- if (!this.isActive()) {
- return;
- }
- this.adapter.removeClass(cssClasses$2.ACTIVE);
- this.adapter.setAttr(strings$3.ARIA_SELECTED, 'false');
- this.adapter.setAttr(strings$3.TABINDEX, '-1');
- this.adapter.deactivateIndicator();
- };
- /**
- * Returns the dimensions of the Tab
- */
- MDCTabFoundation.prototype.computeDimensions = function () {
- var rootWidth = this.adapter.getOffsetWidth();
- var rootLeft = this.adapter.getOffsetLeft();
- var contentWidth = this.adapter.getContentOffsetWidth();
- var contentLeft = this.adapter.getContentOffsetLeft();
- return {
- contentLeft: rootLeft + contentLeft,
- contentRight: rootLeft + contentLeft + contentWidth,
- rootLeft: rootLeft,
- rootRight: rootLeft + rootWidth,
- };
- };
- return MDCTabFoundation;
-}(MDCFoundation));
-// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
-var MDCTabFoundation$1 = MDCTabFoundation;
-
-/**
- * @license
- * Copyright 2018 Google LLC
- * SPDX-License-Identifier: Apache-2.0
- */
-// used for generating unique id for each tab
-let tabIdCounter = 0;
-class TabBase extends BaseElement {
- constructor() {
- super(...arguments);
- this.mdcFoundationClass = MDCTabFoundation$1;
- this.label = '';
- this.icon = '';
- this.hasImageIcon = false;
- this.isFadingIndicator = false;
- this.minWidth = false;
- this.isMinWidthIndicator = false;
- this.indicatorIcon = '';
- this.stacked = false;
- this.focusOnActivate = true;
- this._active = false;
- this.initFocus = false;
- this.shouldRenderRipple = false;
- this.useStateLayerCustomProperties = false;
- this.rippleElement = null;
- this.rippleHandlers = new RippleHandlers(() => {
- this.shouldRenderRipple = true;
- this.ripple.then((v) => this.rippleElement = v);
- return this.ripple;
- });
- }
- get active() {
- return this._active;
- }
- connectedCallback() {
- this.dir = document.dir;
- super.connectedCallback();
- }
- firstUpdated() {
- super.firstUpdated();
- // create an unique id
- this.id = this.id || `mdc-tab-${++tabIdCounter}`;
- }
- render() {
- const classes = {
- 'mdc-tab--min-width': this.minWidth,
- 'mdc-tab--stacked': this.stacked,
- };
- let iconTemplate = x ``;
- if (this.hasImageIcon || this.icon) {
- // NOTE: MUST be on same line as spaces will cause vert alignment issues
- // in IE
- iconTemplate = x `
-
${this.icon} `;
- }
- let labelTemplate = x ``;
- if (this.label) {
- labelTemplate = x `
-
${this.label} `;
- }
- return x `
-
-
- ${iconTemplate}
- ${labelTemplate}
- ${this.isMinWidthIndicator ? this.renderIndicator() : ''}
-
- ${this.isMinWidthIndicator ? '' : this.renderIndicator()}
- ${this.renderRipple()}
- `;
- }
- renderIndicator() {
- return x `
`;
- }
- // TODO(dfreedm): Make this use selected as a param after Polymer/internal#739
- /** @soyCompatible */
- renderRipple() {
- return this.shouldRenderRipple ?
- x `
` :
- '';
- }
- createAdapter() {
- return Object.assign(Object.assign({}, addHasRemoveClass(this.mdcRoot)), { setAttr: (attr, value) => this.mdcRoot.setAttribute(attr, value), activateIndicator: async (previousIndicatorClientRect) => {
- await this.tabIndicator.updateComplete;
- this.tabIndicator.activate(previousIndicatorClientRect);
- }, deactivateIndicator: async () => {
- await this.tabIndicator.updateComplete;
- this.tabIndicator.deactivate();
- }, notifyInteracted: () => this.dispatchEvent(new CustomEvent(MDCTabFoundation$1.strings.INTERACTED_EVENT, {
- detail: { tabId: this.id },
- bubbles: true,
- composed: true,
- cancelable: true,
- })), getOffsetLeft: () => this.offsetLeft, getOffsetWidth: () => this.mdcRoot.offsetWidth, getContentOffsetLeft: () => this._contentElement.offsetLeft, getContentOffsetWidth: () => this._contentElement.offsetWidth, focus: () => {
- if (this.initFocus) {
- this.initFocus = false;
- }
- else {
- this.mdcRoot.focus();
- }
- } });
- }
- activate(clientRect) {
- // happens only on initialization. We don't want to focus to prevent scroll
- if (!clientRect) {
- this.initFocus = true;
- }
- if (this.mdcFoundation) {
- this.mdcFoundation.activate(clientRect);
- this.setActive(this.mdcFoundation.isActive());
- }
- else {
- // happens if this is called by tab-bar on initialization, but tab has not
- // finished rendering.
- this.updateComplete.then(() => {
- this.mdcFoundation.activate(clientRect);
- this.setActive(this.mdcFoundation.isActive());
- });
- }
- }
- deactivate() {
- this.mdcFoundation.deactivate();
- this.setActive(this.mdcFoundation.isActive());
- }
- setActive(newValue) {
- const oldValue = this.active;
- if (oldValue !== newValue) {
- this._active = newValue;
- this.requestUpdate('active', oldValue);
- }
- }
- computeDimensions() {
- return this.mdcFoundation.computeDimensions();
- }
- computeIndicatorClientRect() {
- return this.tabIndicator.computeContentClientRect();
- }
- // NOTE: needed only for ShadyDOM where delegatesFocus is not implemented
- focus() {
- this.mdcRoot.focus();
- this.handleFocus();
- }
- handleClick() {
- this.handleFocus();
- this.mdcFoundation.handleClick();
- }
- handleFocus() {
- this.handleRippleFocus();
- }
- handleBlur() {
- this.handleRippleBlur();
- }
- handleRippleMouseDown(event) {
- const onUp = () => {
- window.removeEventListener('mouseup', onUp);
- this.handleRippleDeactivate();
- };
- window.addEventListener('mouseup', onUp);
- this.rippleHandlers.startPress(event);
- }
- handleRippleTouchStart(event) {
- this.rippleHandlers.startPress(event);
- }
- handleRippleDeactivate() {
- this.rippleHandlers.endPress();
- }
- handleRippleMouseEnter() {
- this.rippleHandlers.startHover();
- }
- handleRippleMouseLeave() {
- this.rippleHandlers.endHover();
- }
- handleRippleFocus() {
- this.rippleHandlers.startFocus();
- }
- handleRippleBlur() {
- this.rippleHandlers.endFocus();
- }
- get isRippleActive() {
- var _a;
- return ((_a = this.rippleElement) === null || _a === void 0 ? void 0 : _a.isActive) || false;
- }
-}
-TabBase.shadowRootOptions = { mode: 'open', delegatesFocus: true };
-__decorate([
- i$2('.mdc-tab')
-], TabBase.prototype, "mdcRoot", void 0);
-__decorate([
- i$2('mwc-tab-indicator')
-], TabBase.prototype, "tabIndicator", void 0);
-__decorate([
- n$3()
-], TabBase.prototype, "label", void 0);
-__decorate([
- n$3()
-], TabBase.prototype, "icon", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TabBase.prototype, "hasImageIcon", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TabBase.prototype, "isFadingIndicator", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TabBase.prototype, "minWidth", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TabBase.prototype, "isMinWidthIndicator", void 0);
-__decorate([
- n$3({ type: Boolean, reflect: true, attribute: 'active' })
-], TabBase.prototype, "active", null);
-__decorate([
- n$3()
-], TabBase.prototype, "indicatorIcon", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TabBase.prototype, "stacked", void 0);
-__decorate([
- observer(async function (value) {
- await this.updateComplete;
- this.mdcFoundation.setFocusOnActivate(value);
- }),
- n$3({ type: Boolean })
-], TabBase.prototype, "focusOnActivate", void 0);
-__decorate([
- i$2('.mdc-tab__content')
-], TabBase.prototype, "_contentElement", void 0);
-__decorate([
- t$1()
-], TabBase.prototype, "shouldRenderRipple", void 0);
-__decorate([
- t$1()
-], TabBase.prototype, "useStateLayerCustomProperties", void 0);
-__decorate([
- e$2('mwc-ripple')
-], TabBase.prototype, "ripple", void 0);
-__decorate([
- e$3({ passive: true })
-], TabBase.prototype, "handleRippleTouchStart", null);
-
-/**
- * @license
- * Copyright 2021 Google LLC
- * SPDX-LIcense-Identifier: Apache-2.0
- */
-const styles$4 = i$5 `.material-icons{font-family:var(--mdc-icon-font, "Material Icons");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:"liga"}.mdc-tab{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-button-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.875rem;font-size:var(--mdc-typography-button-font-size, 0.875rem);line-height:2.25rem;line-height:var(--mdc-typography-button-line-height, 2.25rem);font-weight:500;font-weight:var(--mdc-typography-button-font-weight, 500);letter-spacing:0.0892857143em;letter-spacing:var(--mdc-typography-button-letter-spacing, 0.0892857143em);text-decoration:none;text-decoration:var(--mdc-typography-button-text-decoration, none);text-transform:uppercase;text-transform:var(--mdc-typography-button-text-transform, uppercase);position:relative}.mdc-tab .mdc-tab__text-label{color:rgba(0, 0, 0, 0.6)}.mdc-tab .mdc-tab__icon{color:rgba(0, 0, 0, 0.54);fill:currentColor}.mdc-tab.mdc-ripple-upgraded--background-focused.mdc-tab--active .mdc-tab__focus-ring,.mdc-tab:not(.mdc-ripple-upgraded):focus.mdc-tab--active .mdc-tab__focus-ring{pointer-events:none;border:2px solid transparent;border-radius:8px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc( 100% + -12px );width:calc( 100% + -8px );margin-top:-2px;z-index:2}@media screen and (forced-colors: active){.mdc-tab.mdc-ripple-upgraded--background-focused.mdc-tab--active .mdc-tab__focus-ring,.mdc-tab:not(.mdc-ripple-upgraded):focus.mdc-tab--active .mdc-tab__focus-ring{border-color:CanvasText}}.mdc-tab.mdc-ripple-upgraded--background-focused.mdc-tab--active .mdc-tab__focus-ring::after,.mdc-tab:not(.mdc-ripple-upgraded):focus.mdc-tab--active .mdc-tab__focus-ring::after{content:"";border:2px solid transparent;border-radius:10px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-tab.mdc-ripple-upgraded--background-focused.mdc-tab--active .mdc-tab__focus-ring::after,.mdc-tab:not(.mdc-ripple-upgraded):focus.mdc-tab--active .mdc-tab__focus-ring::after{border-color:CanvasText}}.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__focus-ring,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__focus-ring{pointer-events:none;border:2px solid transparent;border-radius:8px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc( 100% + -8px );width:calc( 100% + -8px );z-index:2}@media screen and (forced-colors: active){.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__focus-ring,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__focus-ring{border-color:CanvasText}}.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__focus-ring::after,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__focus-ring::after{content:"";border:2px solid transparent;border-radius:10px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__focus-ring::after,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__focus-ring::after{border-color:CanvasText}}.mdc-tab__content{position:relative}.mdc-tab__icon{width:24px;height:24px;font-size:24px}.mdc-tab--active .mdc-tab__text-label{color:#6200ee;color:var(--mdc-theme-primary, #6200ee)}.mdc-tab--active .mdc-tab__icon{color:#6200ee;color:var(--mdc-theme-primary, #6200ee);fill:currentColor}.mdc-tab{background:none}.mdc-tab{min-width:90px;padding-right:24px;padding-left:24px;display:flex;flex:1 0 auto;justify-content:center;box-sizing:border-box;margin:0;padding-top:0;padding-bottom:0;border:none;outline:none;text-align:center;white-space:nowrap;cursor:pointer;-webkit-appearance:none;z-index:1}.mdc-tab::-moz-focus-inner{padding:0;border:0}.mdc-tab--min-width{flex:0 1 auto}.mdc-tab__content{display:flex;align-items:center;justify-content:center;height:inherit;pointer-events:none}.mdc-tab__text-label{transition:150ms color linear;display:inline-block;line-height:1;z-index:2}.mdc-tab__icon{transition:150ms color linear;z-index:2}.mdc-tab--stacked .mdc-tab__content{flex-direction:column;align-items:center;justify-content:center}.mdc-tab--stacked .mdc-tab__text-label{padding-top:6px;padding-bottom:4px}.mdc-tab--active .mdc-tab__text-label,.mdc-tab--active .mdc-tab__icon{transition-delay:100ms}.mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label{padding-left:8px;padding-right:0}[dir=rtl] .mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label,.mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label[dir=rtl]{padding-left:0;padding-right:8px}@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-tab{--mdc-ripple-fg-size: 0;--mdc-ripple-left: 0;--mdc-ripple-top: 0;--mdc-ripple-fg-scale: 1;--mdc-ripple-fg-translate-end: 0;--mdc-ripple-fg-translate-start: 0;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mdc-tab .mdc-tab__ripple::before,.mdc-tab .mdc-tab__ripple::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.mdc-tab .mdc-tab__ripple::before{transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-tab .mdc-tab__ripple::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-tab.mdc-ripple-upgraded .mdc-tab__ripple::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-tab.mdc-ripple-upgraded .mdc-tab__ripple::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-tab.mdc-ripple-upgraded--unbounded .mdc-tab__ripple::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-tab.mdc-ripple-upgraded--foreground-activation .mdc-tab__ripple::after{animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.mdc-tab.mdc-ripple-upgraded--foreground-deactivation .mdc-tab__ripple::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-tab .mdc-tab__ripple::before,.mdc-tab .mdc-tab__ripple::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-tab.mdc-ripple-upgraded .mdc-tab__ripple::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-tab .mdc-tab__ripple::before,.mdc-tab .mdc-tab__ripple::after{background-color:#6200ee;background-color:var(--mdc-ripple-color, var(--mdc-theme-primary, #6200ee))}.mdc-tab:hover .mdc-tab__ripple::before,.mdc-tab.mdc-ripple-surface--hover .mdc-tab__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__ripple::before,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-tab:not(.mdc-ripple-upgraded) .mdc-tab__ripple::after{transition:opacity 150ms linear}.mdc-tab:not(.mdc-ripple-upgraded):active .mdc-tab__ripple::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-tab.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-tab__ripple{position:absolute;top:0;left:0;width:100%;height:100%;overflow:hidden;will-change:transform,opacity}:host{outline:none;flex:1 0 auto;display:flex;justify-content:center;-webkit-tap-highlight-color:transparent}.mdc-tab{height:var(--mdc-tab-height, 48px);margin-left:0;margin-right:0;padding-right:var(--mdc-tab-horizontal-padding, 24px);padding-left:var(--mdc-tab-horizontal-padding, 24px)}.mdc-tab--stacked{height:var(--mdc-tab-stacked-height, 72px)}.mdc-tab::-moz-focus-inner{border:0}.mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label{padding-left:8px;padding-right:0}[dir=rtl] .mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label,.mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label[dir=rtl]{padding-left:0;padding-right:8px}.mdc-tab:not(.mdc-tab--active) .mdc-tab__text-label{color:var(--mdc-tab-text-label-color-default, rgba(0, 0, 0, 0.6))}.mdc-tab:not(.mdc-tab--active) .mdc-tab__icon{color:var(--mdc-tab-color-default, rgba(0, 0, 0, 0.54))}`;
-
-/**
- * @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-var cssClasses$1 = {
- ACTIVE: 'mdc-tab-indicator--active',
- FADE: 'mdc-tab-indicator--fade',
- NO_TRANSITION: 'mdc-tab-indicator--no-transition',
-};
-var strings$2 = {
- CONTENT_SELECTOR: '.mdc-tab-indicator__content',
-};
-
-/**
- * @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-var MDCTabIndicatorFoundation = /** @class */ (function (_super) {
- __extends(MDCTabIndicatorFoundation, _super);
- function MDCTabIndicatorFoundation(adapter) {
- return _super.call(this, __assign(__assign({}, MDCTabIndicatorFoundation.defaultAdapter), adapter)) || this;
- }
- Object.defineProperty(MDCTabIndicatorFoundation, "cssClasses", {
- get: function () {
- return cssClasses$1;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTabIndicatorFoundation, "strings", {
- get: function () {
- return strings$2;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTabIndicatorFoundation, "defaultAdapter", {
- get: function () {
- // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
- return {
- addClass: function () { return undefined; },
- removeClass: function () { return undefined; },
- computeContentClientRect: function () {
- return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 });
- },
- setContentStyleProperty: function () { return undefined; },
- };
- // tslint:enable:object-literal-sort-keys
- },
- enumerable: false,
- configurable: true
- });
- MDCTabIndicatorFoundation.prototype.computeContentClientRect = function () {
- return this.adapter.computeContentClientRect();
- };
- return MDCTabIndicatorFoundation;
-}(MDCFoundation));
-
-/**
- * @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-/* istanbul ignore next: subclass is not a branch statement */
-var MDCFadingTabIndicatorFoundation = /** @class */ (function (_super) {
- __extends(MDCFadingTabIndicatorFoundation, _super);
- function MDCFadingTabIndicatorFoundation() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- MDCFadingTabIndicatorFoundation.prototype.activate = function () {
- this.adapter.addClass(MDCTabIndicatorFoundation.cssClasses.ACTIVE);
- };
- MDCFadingTabIndicatorFoundation.prototype.deactivate = function () {
- this.adapter.removeClass(MDCTabIndicatorFoundation.cssClasses.ACTIVE);
- };
- return MDCFadingTabIndicatorFoundation;
-}(MDCTabIndicatorFoundation));
-// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
-var MDCFadingTabIndicatorFoundation$1 = MDCFadingTabIndicatorFoundation;
-
-/**
- * @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-/* istanbul ignore next: subclass is not a branch statement */
-var MDCSlidingTabIndicatorFoundation = /** @class */ (function (_super) {
- __extends(MDCSlidingTabIndicatorFoundation, _super);
- function MDCSlidingTabIndicatorFoundation() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- MDCSlidingTabIndicatorFoundation.prototype.activate = function (previousIndicatorClientRect) {
- // Early exit if no indicator is present to handle cases where an indicator
- // may be activated without a prior indicator state
- if (!previousIndicatorClientRect) {
- this.adapter.addClass(MDCTabIndicatorFoundation.cssClasses.ACTIVE);
- return;
- }
- // This animation uses the FLIP approach. You can read more about it at the link below:
- // https://aerotwist.com/blog/flip-your-animations/
- // Calculate the dimensions based on the dimensions of the previous indicator
- var currentClientRect = this.computeContentClientRect();
- var widthDelta = previousIndicatorClientRect.width / currentClientRect.width;
- var xPosition = previousIndicatorClientRect.left - currentClientRect.left;
- this.adapter.addClass(MDCTabIndicatorFoundation.cssClasses.NO_TRANSITION);
- this.adapter.setContentStyleProperty('transform', "translateX(" + xPosition + "px) scaleX(" + widthDelta + ")");
- // Force repaint before updating classes and transform to ensure the transform properly takes effect
- this.computeContentClientRect();
- this.adapter.removeClass(MDCTabIndicatorFoundation.cssClasses.NO_TRANSITION);
- this.adapter.addClass(MDCTabIndicatorFoundation.cssClasses.ACTIVE);
- this.adapter.setContentStyleProperty('transform', '');
- };
- MDCSlidingTabIndicatorFoundation.prototype.deactivate = function () {
- this.adapter.removeClass(MDCTabIndicatorFoundation.cssClasses.ACTIVE);
- };
- return MDCSlidingTabIndicatorFoundation;
-}(MDCTabIndicatorFoundation));
-// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
-var MDCSlidingTabIndicatorFoundation$1 = MDCSlidingTabIndicatorFoundation;
-
-/**
- * @license
- * Copyright 2018 Google LLC
- * SPDX-License-Identifier: Apache-2.0
- */
-class TabIndicatorBase extends BaseElement {
- constructor() {
- super(...arguments);
- this.icon = '';
- this.fade = false;
- }
- get mdcFoundationClass() {
- return this.fade ? MDCFadingTabIndicatorFoundation$1 :
- MDCSlidingTabIndicatorFoundation$1;
- }
- render() {
- const contentClasses = {
- 'mdc-tab-indicator__content--icon': this.icon,
- 'material-icons': this.icon,
- 'mdc-tab-indicator__content--underline': !this.icon,
- };
- return x `
-
- ${this.icon}
-
- `;
- }
- updated(changedProperties) {
- if (changedProperties.has('fade')) {
- this.createFoundation();
- }
- }
- createAdapter() {
- return Object.assign(Object.assign({}, addHasRemoveClass(this.mdcRoot)), { computeContentClientRect: () => this.contentElement.getBoundingClientRect(), setContentStyleProperty: (prop, value) => this.contentElement.style.setProperty(prop, value) });
- }
- computeContentClientRect() {
- return this.mdcFoundation.computeContentClientRect();
- }
- activate(previousIndicatorClientRect) {
- this.mdcFoundation.activate(previousIndicatorClientRect);
- }
- deactivate() {
- this.mdcFoundation.deactivate();
- }
-}
-__decorate([
- i$2('.mdc-tab-indicator')
-], TabIndicatorBase.prototype, "mdcRoot", void 0);
-__decorate([
- i$2('.mdc-tab-indicator__content')
-], TabIndicatorBase.prototype, "contentElement", void 0);
-__decorate([
- n$3()
-], TabIndicatorBase.prototype, "icon", void 0);
-__decorate([
- n$3({ type: Boolean })
-], TabIndicatorBase.prototype, "fade", void 0);
-
-/**
- * @license
- * Copyright 2021 Google LLC
- * SPDX-LIcense-Identifier: Apache-2.0
- */
-const styles$3 = i$5 `.material-icons{font-family:var(--mdc-icon-font, "Material Icons");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:"liga"}.mdc-tab-indicator .mdc-tab-indicator__content--underline{border-color:#6200ee;border-color:var(--mdc-theme-primary, #6200ee)}.mdc-tab-indicator .mdc-tab-indicator__content--icon{color:#018786;color:var(--mdc-theme-secondary, #018786)}.mdc-tab-indicator .mdc-tab-indicator__content--underline{border-top-width:2px}.mdc-tab-indicator .mdc-tab-indicator__content--icon{height:34px;font-size:34px}.mdc-tab-indicator{display:flex;position:absolute;top:0;left:0;justify-content:center;width:100%;height:100%;pointer-events:none;z-index:1}.mdc-tab-indicator__content{transform-origin:left;opacity:0}.mdc-tab-indicator__content--underline{align-self:flex-end;box-sizing:border-box;width:100%;border-top-style:solid}.mdc-tab-indicator__content--icon{align-self:center;margin:0 auto}.mdc-tab-indicator--active .mdc-tab-indicator__content{opacity:1}.mdc-tab-indicator .mdc-tab-indicator__content{transition:250ms transform cubic-bezier(0.4, 0, 0.2, 1)}.mdc-tab-indicator--no-transition .mdc-tab-indicator__content{transition:none}.mdc-tab-indicator--fade .mdc-tab-indicator__content{transition:150ms opacity linear}.mdc-tab-indicator--active.mdc-tab-indicator--fade .mdc-tab-indicator__content{transition-delay:100ms}`;
-
-let PoLRTabIndicator = class PoLRTabIndicator extends TabIndicatorBase {
-};
-PoLRTabIndicator.styles = [styles$3];
-PoLRTabIndicator = __decorate([
- e$5("polr-tab-indicator")
-], PoLRTabIndicator);
-
-let PoLRTab = class PoLRTab extends TabBase {
- renderIndicator() {
- return x `
`;
- }
-};
-PoLRTab.styles = [styles$4];
-PoLRTab = __decorate([
- e$5("polr-tab")
-], PoLRTab);
-__decorate([i$2("polr-tab-indicator")], TabBase.prototype, "tabIndicator", void 0);
-
-/**
- * @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-var strings$1 = {
- ARROW_LEFT_KEY: 'ArrowLeft',
- ARROW_RIGHT_KEY: 'ArrowRight',
- END_KEY: 'End',
- ENTER_KEY: 'Enter',
- HOME_KEY: 'Home',
- SPACE_KEY: 'Space',
- TAB_ACTIVATED_EVENT: 'MDCTabBar:activated',
- TAB_SCROLLER_SELECTOR: '.mdc-tab-scroller',
- TAB_SELECTOR: '.mdc-tab',
-};
-var numbers = {
- ARROW_LEFT_KEYCODE: 37,
- ARROW_RIGHT_KEYCODE: 39,
- END_KEYCODE: 35,
- ENTER_KEYCODE: 13,
- EXTRA_SCROLL_AMOUNT: 20,
- HOME_KEYCODE: 36,
- SPACE_KEYCODE: 32,
-};
-
-/**
- * @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-var ACCEPTABLE_KEYS = new Set();
-// IE11 has no support for new Set with iterable so we need to initialize this by hand
-ACCEPTABLE_KEYS.add(strings$1.ARROW_LEFT_KEY);
-ACCEPTABLE_KEYS.add(strings$1.ARROW_RIGHT_KEY);
-ACCEPTABLE_KEYS.add(strings$1.END_KEY);
-ACCEPTABLE_KEYS.add(strings$1.HOME_KEY);
-ACCEPTABLE_KEYS.add(strings$1.ENTER_KEY);
-ACCEPTABLE_KEYS.add(strings$1.SPACE_KEY);
-var KEYCODE_MAP = new Map();
-// IE11 has no support for new Map with iterable so we need to initialize this by hand
-KEYCODE_MAP.set(numbers.ARROW_LEFT_KEYCODE, strings$1.ARROW_LEFT_KEY);
-KEYCODE_MAP.set(numbers.ARROW_RIGHT_KEYCODE, strings$1.ARROW_RIGHT_KEY);
-KEYCODE_MAP.set(numbers.END_KEYCODE, strings$1.END_KEY);
-KEYCODE_MAP.set(numbers.HOME_KEYCODE, strings$1.HOME_KEY);
-KEYCODE_MAP.set(numbers.ENTER_KEYCODE, strings$1.ENTER_KEY);
-KEYCODE_MAP.set(numbers.SPACE_KEYCODE, strings$1.SPACE_KEY);
-var MDCTabBarFoundation = /** @class */ (function (_super) {
- __extends(MDCTabBarFoundation, _super);
- function MDCTabBarFoundation(adapter) {
- var _this = _super.call(this, __assign(__assign({}, MDCTabBarFoundation.defaultAdapter), adapter)) || this;
- _this.useAutomaticActivation = false;
- return _this;
- }
- Object.defineProperty(MDCTabBarFoundation, "strings", {
- get: function () {
- return strings$1;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTabBarFoundation, "numbers", {
- get: function () {
- return numbers;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTabBarFoundation, "defaultAdapter", {
- get: function () {
- // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
- return {
- scrollTo: function () { return undefined; },
- incrementScroll: function () { return undefined; },
- getScrollPosition: function () { return 0; },
- getScrollContentWidth: function () { return 0; },
- getOffsetWidth: function () { return 0; },
- isRTL: function () { return false; },
- setActiveTab: function () { return undefined; },
- activateTabAtIndex: function () { return undefined; },
- deactivateTabAtIndex: function () { return undefined; },
- focusTabAtIndex: function () { return undefined; },
- getTabIndicatorClientRectAtIndex: function () {
- return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 });
- },
- getTabDimensionsAtIndex: function () {
- return ({ rootLeft: 0, rootRight: 0, contentLeft: 0, contentRight: 0 });
- },
- getPreviousActiveTabIndex: function () { return -1; },
- getFocusedTabIndex: function () { return -1; },
- getIndexOfTabById: function () { return -1; },
- getTabListLength: function () { return 0; },
- notifyTabActivated: function () { return undefined; },
- };
- // tslint:enable:object-literal-sort-keys
- },
- enumerable: false,
- configurable: true
- });
- /**
- * Switches between automatic and manual activation modes.
- * See https://www.w3.org/TR/wai-aria-practices/#tabpanel for examples.
- */
- MDCTabBarFoundation.prototype.setUseAutomaticActivation = function (useAutomaticActivation) {
- this.useAutomaticActivation = useAutomaticActivation;
- };
- MDCTabBarFoundation.prototype.activateTab = function (index) {
- var previousActiveIndex = this.adapter.getPreviousActiveTabIndex();
- if (!this.indexIsInRange(index) || index === previousActiveIndex) {
- return;
- }
- var previousClientRect;
- if (previousActiveIndex !== -1) {
- this.adapter.deactivateTabAtIndex(previousActiveIndex);
- previousClientRect =
- this.adapter.getTabIndicatorClientRectAtIndex(previousActiveIndex);
- }
- this.adapter.activateTabAtIndex(index, previousClientRect);
- this.scrollIntoView(index);
- this.adapter.notifyTabActivated(index);
- };
- MDCTabBarFoundation.prototype.handleKeyDown = function (evt) {
- // Get the key from the event
- var key = this.getKeyFromEvent(evt);
- // Early exit if the event key isn't one of the keyboard navigation keys
- if (key === undefined) {
- return;
- }
- // Prevent default behavior for movement keys, but not for activation keys, since :active is used to apply ripple
- if (!this.isActivationKey(key)) {
- evt.preventDefault();
- }
- if (this.useAutomaticActivation) {
- if (this.isActivationKey(key)) {
- return;
- }
- var index = this.determineTargetFromKey(this.adapter.getPreviousActiveTabIndex(), key);
- this.adapter.setActiveTab(index);
- this.scrollIntoView(index);
- }
- else {
- var focusedTabIndex = this.adapter.getFocusedTabIndex();
- if (this.isActivationKey(key)) {
- this.adapter.setActiveTab(focusedTabIndex);
- }
- else {
- var index = this.determineTargetFromKey(focusedTabIndex, key);
- this.adapter.focusTabAtIndex(index);
- this.scrollIntoView(index);
- }
- }
- };
- /**
- * Handles the MDCTab:interacted event
- */
- MDCTabBarFoundation.prototype.handleTabInteraction = function (evt) {
- this.adapter.setActiveTab(this.adapter.getIndexOfTabById(evt.detail.tabId));
- };
- /**
- * Scrolls the tab at the given index into view
- * @param index The tab index to make visible
- */
- MDCTabBarFoundation.prototype.scrollIntoView = function (index) {
- // Early exit if the index is out of range
- if (!this.indexIsInRange(index)) {
- return;
- }
- // Always scroll to 0 if scrolling to the 0th index
- if (index === 0) {
- this.adapter.scrollTo(0);
- return;
- }
- // Always scroll to the max value if scrolling to the Nth index
- // MDCTabScroller.scrollTo() will never scroll past the max possible value
- if (index === this.adapter.getTabListLength() - 1) {
- this.adapter.scrollTo(this.adapter.getScrollContentWidth());
- return;
- }
- if (this.isRTL()) {
- this.scrollIntoViewImplRTL(index);
- return;
- }
- this.scrollIntoViewImpl(index);
- };
- /**
- * Private method for determining the index of the destination tab based on what key was pressed
- * @param origin The original index from which to determine the destination
- * @param key The name of the key
- */
- MDCTabBarFoundation.prototype.determineTargetFromKey = function (origin, key) {
- var isRTL = this.isRTL();
- var maxIndex = this.adapter.getTabListLength() - 1;
- var shouldGoToEnd = key === strings$1.END_KEY;
- var shouldDecrement = key === strings$1.ARROW_LEFT_KEY && !isRTL || key === strings$1.ARROW_RIGHT_KEY && isRTL;
- var shouldIncrement = key === strings$1.ARROW_RIGHT_KEY && !isRTL || key === strings$1.ARROW_LEFT_KEY && isRTL;
- var index = origin;
- if (shouldGoToEnd) {
- index = maxIndex;
- }
- else if (shouldDecrement) {
- index -= 1;
- }
- else if (shouldIncrement) {
- index += 1;
- }
- else {
- index = 0;
- }
- if (index < 0) {
- index = maxIndex;
- }
- else if (index > maxIndex) {
- index = 0;
- }
- return index;
- };
- /**
- * Calculates the scroll increment that will make the tab at the given index visible
- * @param index The index of the tab
- * @param nextIndex The index of the next tab
- * @param scrollPosition The current scroll position
- * @param barWidth The width of the Tab Bar
- */
- MDCTabBarFoundation.prototype.calculateScrollIncrement = function (index, nextIndex, scrollPosition, barWidth) {
- var nextTabDimensions = this.adapter.getTabDimensionsAtIndex(nextIndex);
- var relativeContentLeft = nextTabDimensions.contentLeft - scrollPosition - barWidth;
- var relativeContentRight = nextTabDimensions.contentRight - scrollPosition;
- var leftIncrement = relativeContentRight - numbers.EXTRA_SCROLL_AMOUNT;
- var rightIncrement = relativeContentLeft + numbers.EXTRA_SCROLL_AMOUNT;
- if (nextIndex < index) {
- return Math.min(leftIncrement, 0);
- }
- return Math.max(rightIncrement, 0);
- };
- /**
- * Calculates the scroll increment that will make the tab at the given index visible in RTL
- * @param index The index of the tab
- * @param nextIndex The index of the next tab
- * @param scrollPosition The current scroll position
- * @param barWidth The width of the Tab Bar
- * @param scrollContentWidth The width of the scroll content
- */
- MDCTabBarFoundation.prototype.calculateScrollIncrementRTL = function (index, nextIndex, scrollPosition, barWidth, scrollContentWidth) {
- var nextTabDimensions = this.adapter.getTabDimensionsAtIndex(nextIndex);
- var relativeContentLeft = scrollContentWidth - nextTabDimensions.contentLeft - scrollPosition;
- var relativeContentRight = scrollContentWidth - nextTabDimensions.contentRight - scrollPosition - barWidth;
- var leftIncrement = relativeContentRight + numbers.EXTRA_SCROLL_AMOUNT;
- var rightIncrement = relativeContentLeft - numbers.EXTRA_SCROLL_AMOUNT;
- if (nextIndex > index) {
- return Math.max(leftIncrement, 0);
- }
- return Math.min(rightIncrement, 0);
- };
- /**
- * Determines the index of the adjacent tab closest to either edge of the Tab Bar
- * @param index The index of the tab
- * @param tabDimensions The dimensions of the tab
- * @param scrollPosition The current scroll position
- * @param barWidth The width of the tab bar
- */
- MDCTabBarFoundation.prototype.findAdjacentTabIndexClosestToEdge = function (index, tabDimensions, scrollPosition, barWidth) {
- /**
- * Tabs are laid out in the Tab Scroller like this:
- *
- * Scroll Position
- * +---+
- * | | Bar Width
- * | +-----------------------------------+
- * | | |
- * | V V
- * | +-----------------------------------+
- * V | Tab Scroller |
- * +------------+--------------+-------------------+
- * | Tab | Tab | Tab |
- * +------------+--------------+-------------------+
- * | |
- * +-----------------------------------+
- *
- * To determine the next adjacent index, we look at the Tab root left and
- * Tab root right, both relative to the scroll position. If the Tab root
- * left is less than 0, then we know it's out of view to the left. If the
- * Tab root right minus the bar width is greater than 0, we know the Tab is
- * out of view to the right. From there, we either increment or decrement
- * the index.
- */
- var relativeRootLeft = tabDimensions.rootLeft - scrollPosition;
- var relativeRootRight = tabDimensions.rootRight - scrollPosition - barWidth;
- var relativeRootDelta = relativeRootLeft + relativeRootRight;
- var leftEdgeIsCloser = relativeRootLeft < 0 || relativeRootDelta < 0;
- var rightEdgeIsCloser = relativeRootRight > 0 || relativeRootDelta > 0;
- if (leftEdgeIsCloser) {
- return index - 1;
- }
- if (rightEdgeIsCloser) {
- return index + 1;
- }
- return -1;
- };
- /**
- * Determines the index of the adjacent tab closest to either edge of the Tab Bar in RTL
- * @param index The index of the tab
- * @param tabDimensions The dimensions of the tab
- * @param scrollPosition The current scroll position
- * @param barWidth The width of the tab bar
- * @param scrollContentWidth The width of the scroller content
- */
- MDCTabBarFoundation.prototype.findAdjacentTabIndexClosestToEdgeRTL = function (index, tabDimensions, scrollPosition, barWidth, scrollContentWidth) {
- var rootLeft = scrollContentWidth - tabDimensions.rootLeft - barWidth - scrollPosition;
- var rootRight = scrollContentWidth - tabDimensions.rootRight - scrollPosition;
- var rootDelta = rootLeft + rootRight;
- var leftEdgeIsCloser = rootLeft > 0 || rootDelta > 0;
- var rightEdgeIsCloser = rootRight < 0 || rootDelta < 0;
- if (leftEdgeIsCloser) {
- return index + 1;
- }
- if (rightEdgeIsCloser) {
- return index - 1;
- }
- return -1;
- };
- /**
- * Returns the key associated with a keydown event
- * @param evt The keydown event
- */
- MDCTabBarFoundation.prototype.getKeyFromEvent = function (evt) {
- if (ACCEPTABLE_KEYS.has(evt.key)) {
- return evt.key;
- }
- return KEYCODE_MAP.get(evt.keyCode);
- };
- MDCTabBarFoundation.prototype.isActivationKey = function (key) {
- return key === strings$1.SPACE_KEY || key === strings$1.ENTER_KEY;
- };
- /**
- * Returns whether a given index is inclusively between the ends
- * @param index The index to test
- */
- MDCTabBarFoundation.prototype.indexIsInRange = function (index) {
- return index >= 0 && index < this.adapter.getTabListLength();
- };
- /**
- * Returns the view's RTL property
- */
- MDCTabBarFoundation.prototype.isRTL = function () {
- return this.adapter.isRTL();
- };
- /**
- * Scrolls the tab at the given index into view for left-to-right user agents.
- * @param index The index of the tab to scroll into view
- */
- MDCTabBarFoundation.prototype.scrollIntoViewImpl = function (index) {
- var scrollPosition = this.adapter.getScrollPosition();
- var barWidth = this.adapter.getOffsetWidth();
- var tabDimensions = this.adapter.getTabDimensionsAtIndex(index);
- var nextIndex = this.findAdjacentTabIndexClosestToEdge(index, tabDimensions, scrollPosition, barWidth);
- if (!this.indexIsInRange(nextIndex)) {
- return;
- }
- var scrollIncrement = this.calculateScrollIncrement(index, nextIndex, scrollPosition, barWidth);
- this.adapter.incrementScroll(scrollIncrement);
- };
- /**
- * Scrolls the tab at the given index into view in RTL
- * @param index The tab index to make visible
- */
- MDCTabBarFoundation.prototype.scrollIntoViewImplRTL = function (index) {
- var scrollPosition = this.adapter.getScrollPosition();
- var barWidth = this.adapter.getOffsetWidth();
- var tabDimensions = this.adapter.getTabDimensionsAtIndex(index);
- var scrollWidth = this.adapter.getScrollContentWidth();
- var nextIndex = this.findAdjacentTabIndexClosestToEdgeRTL(index, tabDimensions, scrollPosition, barWidth, scrollWidth);
- if (!this.indexIsInRange(nextIndex)) {
- return;
- }
- var scrollIncrement = this.calculateScrollIncrementRTL(index, nextIndex, scrollPosition, barWidth, scrollWidth);
- this.adapter.incrementScroll(scrollIncrement);
- };
- return MDCTabBarFoundation;
-}(MDCFoundation));
-// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
-var MDCTabBarFoundation$1 = MDCTabBarFoundation;
-
-/**
- * @license
- * Copyright 2018 Google LLC
- * SPDX-License-Identifier: Apache-2.0
- */
-class TabBarBase extends BaseElement {
- constructor() {
- super(...arguments);
- this.mdcFoundationClass = MDCTabBarFoundation$1;
- this.activeIndex = 0;
- this._previousActiveIndex = -1;
- }
- _handleTabInteraction(e) {
- this.mdcFoundation.handleTabInteraction(e);
- }
- _handleKeydown(e) {
- this.mdcFoundation.handleKeyDown(e);
- }
- // TODO(sorvell): can scroller be optional for perf?
- render() {
- return x `
-
-
-
- `;
- }
- // TODO(sorvell): probably want to memoize this and use a `slotChange` event
- _getTabs() {
- return this.tabsSlot
- .assignedNodes({ flatten: true })
- .filter((e) => e instanceof TabBase);
- }
- _getTab(index) {
- return this._getTabs()[index];
- }
- createAdapter() {
- return {
- scrollTo: (scrollX) => this.scrollerElement.scrollToPosition(scrollX),
- incrementScroll: (scrollXIncrement) => this.scrollerElement.incrementScrollPosition(scrollXIncrement),
- getScrollPosition: () => this.scrollerElement.getScrollPosition(),
- getScrollContentWidth: () => this.scrollerElement.getScrollContentWidth(),
- getOffsetWidth: () => this.mdcRoot.offsetWidth,
- isRTL: () => window.getComputedStyle(this.mdcRoot)
- .getPropertyValue('direction') === 'rtl',
- setActiveTab: (index) => this.mdcFoundation.activateTab(index),
- activateTabAtIndex: (index, clientRect) => {
- const tab = this._getTab(index);
- if (tab !== undefined) {
- tab.activate(clientRect);
- }
- this._previousActiveIndex = index;
- },
- deactivateTabAtIndex: (index) => {
- const tab = this._getTab(index);
- if (tab !== undefined) {
- tab.deactivate();
- }
- },
- focusTabAtIndex: (index) => {
- const tab = this._getTab(index);
- if (tab !== undefined) {
- tab.focus();
- }
- },
- // TODO(sorvell): tab may not be able to synchronously answer
- // `computeIndicatorClientRect` if an update is pending or it has not yet
- // updated. If this is necessary, LitElement may need a `forceUpdate`
- // method.
- getTabIndicatorClientRectAtIndex: (index) => {
- const tab = this._getTab(index);
- return tab !== undefined ? tab.computeIndicatorClientRect() :
- new DOMRect();
- },
- getTabDimensionsAtIndex: (index) => {
- const tab = this._getTab(index);
- return tab !== undefined ?
- tab.computeDimensions() :
- { rootLeft: 0, rootRight: 0, contentLeft: 0, contentRight: 0 };
- },
- getPreviousActiveTabIndex: () => {
- return this._previousActiveIndex;
- },
- getFocusedTabIndex: () => {
- const tabElements = this._getTabs();
- const activeElement = this.getRootNode().activeElement;
- return tabElements.indexOf(activeElement);
- },
- getIndexOfTabById: (id) => {
- const tabElements = this._getTabs();
- for (let i = 0; i < tabElements.length; i++) {
- if (tabElements[i].id === id) {
- return i;
- }
- }
- return -1;
- },
- getTabListLength: () => this._getTabs().length,
- notifyTabActivated: (index) => {
- // Synchronize the tabs `activeIndex` to the foundation.
- // This is needed when a tab is changed via a click, for example.
- this.activeIndex = index;
- this.dispatchEvent(new CustomEvent(MDCTabBarFoundation$1.strings.TAB_ACTIVATED_EVENT, { detail: { index }, bubbles: true, cancelable: true }));
- },
- };
- }
- firstUpdated() {
- // NOTE: Delay creating foundation until scroller is fully updated.
- // This is necessary because the foundation/adapter synchronously addresses
- // the scroller element.
- }
- async getUpdateComplete() {
- const result = await super.getUpdateComplete();
- await this.scrollerElement.updateComplete;
- if (this.mdcFoundation === undefined) {
- this.createFoundation();
- }
- return result;
- }
- scrollIndexIntoView(index) {
- this.mdcFoundation.scrollIntoView(index);
- }
-}
-__decorate([
- i$2('.mdc-tab-bar')
-], TabBarBase.prototype, "mdcRoot", void 0);
-__decorate([
- i$2('mwc-tab-scroller')
-], TabBarBase.prototype, "scrollerElement", void 0);
-__decorate([
- i$2('slot')
-], TabBarBase.prototype, "tabsSlot", void 0);
-__decorate([
- observer(async function () {
- await this.updateComplete;
- // only provoke the foundation if we are out of sync with it, i.e.
- // ignore an foundation generated set.
- // use `activeIndex` directly to avoid staleness if it was set before the
- // first render.
- if (this.activeIndex !== this._previousActiveIndex) {
- this.mdcFoundation.activateTab(this.activeIndex);
- }
- }),
- n$3({ type: Number })
-], TabBarBase.prototype, "activeIndex", void 0);
-
-/**
- * @license
- * Copyright 2021 Google LLC
- * SPDX-LIcense-Identifier: Apache-2.0
- */
-const styles$2 = i$5 `.mdc-tab-bar{width:100%}.mdc-tab{height:48px}.mdc-tab--stacked{height:72px}:host{display:block}.mdc-tab-bar{flex:1}mwc-tab{--mdc-tab-height: 48px;--mdc-tab-stacked-height: 72px}`;
-
-/**
- * @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
+ }
+ `,n([ht()],_i.prototype,"_config",void 0),n([ht()],_i.prototype,"_hass",void 0),n([pt()],_i.prototype,"_entity",void 0),n([pt()],_i.prototype,"_runOnce",void 0),customElements.define("polr-ytube-search-card",_i),window.customCards=window.customCards||[],window.customCards.push({type:"polr-ytube-search-card",name:"PoLR YouTube Search",description:"Requires the ytube_media_player integration"});
/**
- * @fileoverview A "ponyfill" is a polyfill that doesn't modify the global prototype chain.
- * This makes ponyfills safer than traditional polyfills, especially for libraries like MDC.
+ * @license
+ * Copyright 2020 Google LLC
+ * SPDX-License-Identifier: Apache-2.0
*/
-function matches(element, selector) {
- var nativeMatches = element.matches
- || element.webkitMatchesSelector
- || element.msMatchesSelector;
- return nativeMatches.call(element, selector);
-}
-
+class xi{constructor(t){this.startPress=e=>{t().then((t=>{t&&t.startPress(e)}))},this.endPress=()=>{t().then((t=>{t&&t.endPress()}))},this.startFocus=()=>{t().then((t=>{t&&t.startFocus()}))},this.endFocus=()=>{t().then((t=>{t&&t.endFocus()}))},this.startHover=()=>{t().then((t=>{t&&t.startHover()}))},this.endHover=()=>{t().then((t=>{t&&t.endHover()}))}}}
/**
* @license
* Copyright 2018 Google Inc.
@@ -6281,46 +945,46 @@ function matches(element, selector) {
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
+ */var yi={ACTIVE:"mdc-tab--active"},wi={ARIA_SELECTED:"aria-selected",CONTENT_SELECTOR:".mdc-tab__content",INTERACTED_EVENT:"MDCTab:interacted",RIPPLE_SELECTOR:".mdc-tab__ripple",TABINDEX:"tabIndex",TAB_INDICATOR_SELECTOR:".mdc-tab-indicator"},Ei=function(t){function n(e){var r=t.call(this,i(i({},n.defaultAdapter),e))||this;return r.focusOnActivate=!0,r}return e(n,t),Object.defineProperty(n,"cssClasses",{get:function(){return yi},enumerable:!1,configurable:!0}),Object.defineProperty(n,"strings",{get:function(){return wi},enumerable:!1,configurable:!0}),Object.defineProperty(n,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!1},setAttr:function(){},activateIndicator:function(){},deactivateIndicator:function(){},notifyInteracted:function(){},getOffsetLeft:function(){return 0},getOffsetWidth:function(){return 0},getContentOffsetLeft:function(){return 0},getContentOffsetWidth:function(){return 0},focus:function(){}}},enumerable:!1,configurable:!0}),n.prototype.handleClick=function(){this.adapter.notifyInteracted()},n.prototype.isActive=function(){return this.adapter.hasClass(yi.ACTIVE)},n.prototype.setFocusOnActivate=function(t){this.focusOnActivate=t},n.prototype.activate=function(t){this.adapter.addClass(yi.ACTIVE),this.adapter.setAttr(wi.ARIA_SELECTED,"true"),this.adapter.setAttr(wi.TABINDEX,"0"),this.adapter.activateIndicator(t),this.focusOnActivate&&this.adapter.focus()},n.prototype.deactivate=function(){this.isActive()&&(this.adapter.removeClass(yi.ACTIVE),this.adapter.setAttr(wi.ARIA_SELECTED,"false"),this.adapter.setAttr(wi.TABINDEX,"-1"),this.adapter.deactivateIndicator())},n.prototype.computeDimensions=function(){var t=this.adapter.getOffsetWidth(),e=this.adapter.getOffsetLeft(),i=this.adapter.getContentOffsetWidth(),n=this.adapter.getContentOffsetLeft();return{contentLeft:e+n,contentRight:e+n+i,rootLeft:e,rootRight:e+t}},n}(Ie);
+/**
+ * @license
+ * Copyright 2018 Google LLC
+ * SPDX-License-Identifier: Apache-2.0
*/
-var cssClasses = {
- ANIMATING: 'mdc-tab-scroller--animating',
- SCROLL_AREA_SCROLL: 'mdc-tab-scroller__scroll-area--scroll',
- SCROLL_TEST: 'mdc-tab-scroller__test',
-};
-var strings = {
- AREA_SELECTOR: '.mdc-tab-scroller__scroll-area',
- CONTENT_SELECTOR: '.mdc-tab-scroller__scroll-content',
-};
-
+let Ai=0;class Ci extends Ee{constructor(){super(...arguments),this.mdcFoundationClass=Ei,this.label="",this.icon="",this.hasImageIcon=!1,this.isFadingIndicator=!1,this.minWidth=!1,this.isMinWidthIndicator=!1,this.indicatorIcon="",this.stacked=!1,this.focusOnActivate=!0,this._active=!1,this.initFocus=!1,this.shouldRenderRipple=!1,this.useStateLayerCustomProperties=!1,this.rippleElement=null,this.rippleHandlers=new xi((()=>(this.shouldRenderRipple=!0,this.ripple.then((t=>this.rippleElement=t)),this.ripple)))}get active(){return this._active}connectedCallback(){this.dir=document.dir,super.connectedCallback()}firstUpdated(){super.firstUpdated(),this.id=this.id||"mdc-tab-"+ ++Ai}render(){const t={"mdc-tab--min-width":this.minWidth,"mdc-tab--stacked":this.stacked};let e=B``;(this.hasImageIcon||this.icon)&&(e=B`
+
${this.icon} `);let i=B``;return this.label&&(i=B`
+
${this.label} `),B`
+
+
+ ${e}
+ ${i}
+ ${this.isMinWidthIndicator?this.renderIndicator():""}
+
+ ${this.isMinWidthIndicator?"":this.renderIndicator()}
+ ${this.renderRipple()}
+ `}renderIndicator(){return B`
`}renderRipple(){return this.shouldRenderRipple?B`
`:""}createAdapter(){return Object.assign(Object.assign({},xe(this.mdcRoot)),{setAttr:(t,e)=>this.mdcRoot.setAttribute(t,e),activateIndicator:async t=>{await this.tabIndicator.updateComplete,this.tabIndicator.activate(t)},deactivateIndicator:async()=>{await this.tabIndicator.updateComplete,this.tabIndicator.deactivate()},notifyInteracted:()=>this.dispatchEvent(new CustomEvent(Ei.strings.INTERACTED_EVENT,{detail:{tabId:this.id},bubbles:!0,composed:!0,cancelable:!0})),getOffsetLeft:()=>this.offsetLeft,getOffsetWidth:()=>this.mdcRoot.offsetWidth,getContentOffsetLeft:()=>this._contentElement.offsetLeft,getContentOffsetWidth:()=>this._contentElement.offsetWidth,focus:()=>{this.initFocus?this.initFocus=!1:this.mdcRoot.focus()}})}activate(t){t||(this.initFocus=!0),this.mdcFoundation?(this.mdcFoundation.activate(t),this.setActive(this.mdcFoundation.isActive())):this.updateComplete.then((()=>{this.mdcFoundation.activate(t),this.setActive(this.mdcFoundation.isActive())}))}deactivate(){this.mdcFoundation.deactivate(),this.setActive(this.mdcFoundation.isActive())}setActive(t){const e=this.active;e!==t&&(this._active=t,this.requestUpdate("active",e))}computeDimensions(){return this.mdcFoundation.computeDimensions()}computeIndicatorClientRect(){return this.tabIndicator.computeContentClientRect()}focus(){this.mdcRoot.focus(),this.handleFocus()}handleClick(){this.handleFocus(),this.mdcFoundation.handleClick()}handleFocus(){this.handleRippleFocus()}handleBlur(){this.handleRippleBlur()}handleRippleMouseDown(t){const e=()=>{window.removeEventListener("mouseup",e),this.handleRippleDeactivate()};window.addEventListener("mouseup",e),this.rippleHandlers.startPress(t)}handleRippleTouchStart(t){this.rippleHandlers.startPress(t)}handleRippleDeactivate(){this.rippleHandlers.endPress()}handleRippleMouseEnter(){this.rippleHandlers.startHover()}handleRippleMouseLeave(){this.rippleHandlers.endHover()}handleRippleFocus(){this.rippleHandlers.startFocus()}handleRippleBlur(){this.rippleHandlers.endFocus()}get isRippleActive(){var t;return(null===(t=this.rippleElement)||void 0===t?void 0:t.isActive)||!1}}Ci.shadowRootOptions={mode:"open",delegatesFocus:!0},n([gt(".mdc-tab")],Ci.prototype,"mdcRoot",void 0),n([gt("mwc-tab-indicator")],Ci.prototype,"tabIndicator",void 0),n([ht()],Ci.prototype,"label",void 0),n([ht()],Ci.prototype,"icon",void 0),n([ht({type:Boolean})],Ci.prototype,"hasImageIcon",void 0),n([ht({type:Boolean})],Ci.prototype,"isFadingIndicator",void 0),n([ht({type:Boolean})],Ci.prototype,"minWidth",void 0),n([ht({type:Boolean})],Ci.prototype,"isMinWidthIndicator",void 0),n([ht({type:Boolean,reflect:!0,attribute:"active"})],Ci.prototype,"active",null),n([ht()],Ci.prototype,"indicatorIcon",void 0),n([ht({type:Boolean})],Ci.prototype,"stacked",void 0),n([Te((async function(t){await this.updateComplete,this.mdcFoundation.setFocusOnActivate(t)})),ht({type:Boolean})],Ci.prototype,"focusOnActivate",void 0),n([gt(".mdc-tab__content")],Ci.prototype,"_contentElement",void 0),n([pt()],Ci.prototype,"shouldRenderRipple",void 0),n([pt()],Ci.prototype,"useStateLayerCustomProperties",void 0),n([bt("mwc-ripple")],Ci.prototype,"ripple",void 0),n([ft({passive:!0})],Ci.prototype,"handleRippleTouchStart",null);
/**
* @license
- * Copyright 2018 Google Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
+ * Copyright 2021 Google LLC
+ * SPDX-LIcense-Identifier: Apache-2.0
*/
-var MDCTabScrollerRTL = /** @class */ (function () {
- function MDCTabScrollerRTL(adapter) {
- this.adapter = adapter;
- }
- return MDCTabScrollerRTL;
-}());
-
+const Si=s`.material-icons{font-family:var(--mdc-icon-font, "Material Icons");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:"liga"}.mdc-tab{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-button-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.875rem;font-size:var(--mdc-typography-button-font-size, 0.875rem);line-height:2.25rem;line-height:var(--mdc-typography-button-line-height, 2.25rem);font-weight:500;font-weight:var(--mdc-typography-button-font-weight, 500);letter-spacing:0.0892857143em;letter-spacing:var(--mdc-typography-button-letter-spacing, 0.0892857143em);text-decoration:none;text-decoration:var(--mdc-typography-button-text-decoration, none);text-transform:uppercase;text-transform:var(--mdc-typography-button-text-transform, uppercase);position:relative}.mdc-tab .mdc-tab__text-label{color:rgba(0, 0, 0, 0.6)}.mdc-tab .mdc-tab__icon{color:rgba(0, 0, 0, 0.54);fill:currentColor}.mdc-tab.mdc-ripple-upgraded--background-focused.mdc-tab--active .mdc-tab__focus-ring,.mdc-tab:not(.mdc-ripple-upgraded):focus.mdc-tab--active .mdc-tab__focus-ring{pointer-events:none;border:2px solid transparent;border-radius:8px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc( 100% + -12px );width:calc( 100% + -8px );margin-top:-2px;z-index:2}@media screen and (forced-colors: active){.mdc-tab.mdc-ripple-upgraded--background-focused.mdc-tab--active .mdc-tab__focus-ring,.mdc-tab:not(.mdc-ripple-upgraded):focus.mdc-tab--active .mdc-tab__focus-ring{border-color:CanvasText}}.mdc-tab.mdc-ripple-upgraded--background-focused.mdc-tab--active .mdc-tab__focus-ring::after,.mdc-tab:not(.mdc-ripple-upgraded):focus.mdc-tab--active .mdc-tab__focus-ring::after{content:"";border:2px solid transparent;border-radius:10px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-tab.mdc-ripple-upgraded--background-focused.mdc-tab--active .mdc-tab__focus-ring::after,.mdc-tab:not(.mdc-ripple-upgraded):focus.mdc-tab--active .mdc-tab__focus-ring::after{border-color:CanvasText}}.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__focus-ring,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__focus-ring{pointer-events:none;border:2px solid transparent;border-radius:8px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc( 100% + -8px );width:calc( 100% + -8px );z-index:2}@media screen and (forced-colors: active){.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__focus-ring,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__focus-ring{border-color:CanvasText}}.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__focus-ring::after,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__focus-ring::after{content:"";border:2px solid transparent;border-radius:10px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__focus-ring::after,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__focus-ring::after{border-color:CanvasText}}.mdc-tab__content{position:relative}.mdc-tab__icon{width:24px;height:24px;font-size:24px}.mdc-tab--active .mdc-tab__text-label{color:#6200ee;color:var(--mdc-theme-primary, #6200ee)}.mdc-tab--active .mdc-tab__icon{color:#6200ee;color:var(--mdc-theme-primary, #6200ee);fill:currentColor}.mdc-tab{background:none}.mdc-tab{min-width:90px;padding-right:24px;padding-left:24px;display:flex;flex:1 0 auto;justify-content:center;box-sizing:border-box;margin:0;padding-top:0;padding-bottom:0;border:none;outline:none;text-align:center;white-space:nowrap;cursor:pointer;-webkit-appearance:none;z-index:1}.mdc-tab::-moz-focus-inner{padding:0;border:0}.mdc-tab--min-width{flex:0 1 auto}.mdc-tab__content{display:flex;align-items:center;justify-content:center;height:inherit;pointer-events:none}.mdc-tab__text-label{transition:150ms color linear;display:inline-block;line-height:1;z-index:2}.mdc-tab__icon{transition:150ms color linear;z-index:2}.mdc-tab--stacked .mdc-tab__content{flex-direction:column;align-items:center;justify-content:center}.mdc-tab--stacked .mdc-tab__text-label{padding-top:6px;padding-bottom:4px}.mdc-tab--active .mdc-tab__text-label,.mdc-tab--active .mdc-tab__icon{transition-delay:100ms}.mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label{padding-left:8px;padding-right:0}[dir=rtl] .mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label,.mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label[dir=rtl]{padding-left:0;padding-right:8px}@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-tab{--mdc-ripple-fg-size: 0;--mdc-ripple-left: 0;--mdc-ripple-top: 0;--mdc-ripple-fg-scale: 1;--mdc-ripple-fg-translate-end: 0;--mdc-ripple-fg-translate-start: 0;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mdc-tab .mdc-tab__ripple::before,.mdc-tab .mdc-tab__ripple::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.mdc-tab .mdc-tab__ripple::before{transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-tab .mdc-tab__ripple::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-tab.mdc-ripple-upgraded .mdc-tab__ripple::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-tab.mdc-ripple-upgraded .mdc-tab__ripple::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-tab.mdc-ripple-upgraded--unbounded .mdc-tab__ripple::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-tab.mdc-ripple-upgraded--foreground-activation .mdc-tab__ripple::after{animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.mdc-tab.mdc-ripple-upgraded--foreground-deactivation .mdc-tab__ripple::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-tab .mdc-tab__ripple::before,.mdc-tab .mdc-tab__ripple::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-tab.mdc-ripple-upgraded .mdc-tab__ripple::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-tab .mdc-tab__ripple::before,.mdc-tab .mdc-tab__ripple::after{background-color:#6200ee;background-color:var(--mdc-ripple-color, var(--mdc-theme-primary, #6200ee))}.mdc-tab:hover .mdc-tab__ripple::before,.mdc-tab.mdc-ripple-surface--hover .mdc-tab__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-tab.mdc-ripple-upgraded--background-focused .mdc-tab__ripple::before,.mdc-tab:not(.mdc-ripple-upgraded):focus .mdc-tab__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-tab:not(.mdc-ripple-upgraded) .mdc-tab__ripple::after{transition:opacity 150ms linear}.mdc-tab:not(.mdc-ripple-upgraded):active .mdc-tab__ripple::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-tab.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-tab__ripple{position:absolute;top:0;left:0;width:100%;height:100%;overflow:hidden;will-change:transform,opacity}:host{outline:none;flex:1 0 auto;display:flex;justify-content:center;-webkit-tap-highlight-color:transparent}.mdc-tab{height:var(--mdc-tab-height, 48px);margin-left:0;margin-right:0;padding-right:var(--mdc-tab-horizontal-padding, 24px);padding-left:var(--mdc-tab-horizontal-padding, 24px)}.mdc-tab--stacked{height:var(--mdc-tab-stacked-height, 72px)}.mdc-tab::-moz-focus-inner{border:0}.mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label{padding-left:8px;padding-right:0}[dir=rtl] .mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label,.mdc-tab:not(.mdc-tab--stacked) .mdc-tab__icon+.mdc-tab__text-label[dir=rtl]{padding-left:0;padding-right:8px}.mdc-tab:not(.mdc-tab--active) .mdc-tab__text-label{color:var(--mdc-tab-text-label-color-default, rgba(0, 0, 0, 0.6))}.mdc-tab:not(.mdc-tab--active) .mdc-tab__icon{color:var(--mdc-tab-color-default, rgba(0, 0, 0, 0.54))}`
/**
* @license
* Copyright 2018 Google Inc.
@@ -6342,53 +1006,25 @@ var MDCTabScrollerRTL = /** @class */ (function () {
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
+ */;var ki={ACTIVE:"mdc-tab-indicator--active",FADE:"mdc-tab-indicator--fade",NO_TRANSITION:"mdc-tab-indicator--no-transition"},Ti={CONTENT_SELECTOR:".mdc-tab-indicator__content"},Ii=function(t){function n(e){return t.call(this,i(i({},n.defaultAdapter),e))||this}return e(n,t),Object.defineProperty(n,"cssClasses",{get:function(){return ki},enumerable:!1,configurable:!0}),Object.defineProperty(n,"strings",{get:function(){return Ti},enumerable:!1,configurable:!0}),Object.defineProperty(n,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},computeContentClientRect:function(){return{top:0,right:0,bottom:0,left:0,width:0,height:0}},setContentStyleProperty:function(){}}},enumerable:!1,configurable:!0}),n.prototype.computeContentClientRect=function(){return this.adapter.computeContentClientRect()},n}(Ie),Li=function(t){function i(){return null!==t&&t.apply(this,arguments)||this}return e(i,t),i.prototype.activate=function(){this.adapter.addClass(Ii.cssClasses.ACTIVE)},i.prototype.deactivate=function(){this.adapter.removeClass(Ii.cssClasses.ACTIVE)},i}(Ii),Ri=function(t){function i(){return null!==t&&t.apply(this,arguments)||this}return e(i,t),i.prototype.activate=function(t){if(t){var e=this.computeContentClientRect(),i=t.width/e.width,n=t.left-e.left;this.adapter.addClass(Ii.cssClasses.NO_TRANSITION),this.adapter.setContentStyleProperty("transform","translateX("+n+"px) scaleX("+i+")"),this.computeContentClientRect(),this.adapter.removeClass(Ii.cssClasses.NO_TRANSITION),this.adapter.addClass(Ii.cssClasses.ACTIVE),this.adapter.setContentStyleProperty("transform","")}else this.adapter.addClass(Ii.cssClasses.ACTIVE)},i.prototype.deactivate=function(){this.adapter.removeClass(Ii.cssClasses.ACTIVE)},i}(Ii);
+/**
+ * @license
+ * Copyright 2018 Google LLC
+ * SPDX-License-Identifier: Apache-2.0
*/
-var MDCTabScrollerRTLDefault = /** @class */ (function (_super) {
- __extends(MDCTabScrollerRTLDefault, _super);
- function MDCTabScrollerRTLDefault() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- MDCTabScrollerRTLDefault.prototype.getScrollPositionRTL = function () {
- var currentScrollLeft = this.adapter.getScrollAreaScrollLeft();
- var right = this.calculateScrollEdges().right;
- // Scroll values on most browsers are ints instead of floats so we round
- return Math.round(right - currentScrollLeft);
- };
- MDCTabScrollerRTLDefault.prototype.scrollToRTL = function (scrollX) {
- var edges = this.calculateScrollEdges();
- var currentScrollLeft = this.adapter.getScrollAreaScrollLeft();
- var clampedScrollLeft = this.clampScrollValue(edges.right - scrollX);
- return {
- finalScrollPosition: clampedScrollLeft,
- scrollDelta: clampedScrollLeft - currentScrollLeft,
- };
- };
- MDCTabScrollerRTLDefault.prototype.incrementScrollRTL = function (scrollX) {
- var currentScrollLeft = this.adapter.getScrollAreaScrollLeft();
- var clampedScrollLeft = this.clampScrollValue(currentScrollLeft - scrollX);
- return {
- finalScrollPosition: clampedScrollLeft,
- scrollDelta: clampedScrollLeft - currentScrollLeft,
- };
- };
- MDCTabScrollerRTLDefault.prototype.getAnimatingScrollPosition = function (scrollX) {
- return scrollX;
- };
- MDCTabScrollerRTLDefault.prototype.calculateScrollEdges = function () {
- var contentWidth = this.adapter.getScrollContentOffsetWidth();
- var rootWidth = this.adapter.getScrollAreaOffsetWidth();
- return {
- left: 0,
- right: contentWidth - rootWidth,
- };
- };
- MDCTabScrollerRTLDefault.prototype.clampScrollValue = function (scrollX) {
- var edges = this.calculateScrollEdges();
- return Math.min(Math.max(edges.left, scrollX), edges.right);
- };
- return MDCTabScrollerRTLDefault;
-}(MDCTabScrollerRTL));
-
+class Oi extends Ee{constructor(){super(...arguments),this.icon="",this.fade=!1}get mdcFoundationClass(){return this.fade?Li:Ri}render(){const t={"mdc-tab-indicator__content--icon":this.icon,"material-icons":this.icon,"mdc-tab-indicator__content--underline":!this.icon};return B`
+
+ ${this.icon}
+
+ `}updated(t){t.has("fade")&&this.createFoundation()}createAdapter(){return Object.assign(Object.assign({},xe(this.mdcRoot)),{computeContentClientRect:()=>this.contentElement.getBoundingClientRect(),setContentStyleProperty:(t,e)=>this.contentElement.style.setProperty(t,e)})}computeContentClientRect(){return this.mdcFoundation.computeContentClientRect()}activate(t){this.mdcFoundation.activate(t)}deactivate(){this.mdcFoundation.deactivate()}}n([gt(".mdc-tab-indicator")],Oi.prototype,"mdcRoot",void 0),n([gt(".mdc-tab-indicator__content")],Oi.prototype,"contentElement",void 0),n([ht()],Oi.prototype,"icon",void 0),n([ht({type:Boolean})],Oi.prototype,"fade",void 0);
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-LIcense-Identifier: Apache-2.0
+ */
+const $i=s`.material-icons{font-family:var(--mdc-icon-font, "Material Icons");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:"liga"}.mdc-tab-indicator .mdc-tab-indicator__content--underline{border-color:#6200ee;border-color:var(--mdc-theme-primary, #6200ee)}.mdc-tab-indicator .mdc-tab-indicator__content--icon{color:#018786;color:var(--mdc-theme-secondary, #018786)}.mdc-tab-indicator .mdc-tab-indicator__content--underline{border-top-width:2px}.mdc-tab-indicator .mdc-tab-indicator__content--icon{height:34px;font-size:34px}.mdc-tab-indicator{display:flex;position:absolute;top:0;left:0;justify-content:center;width:100%;height:100%;pointer-events:none;z-index:1}.mdc-tab-indicator__content{transform-origin:left;opacity:0}.mdc-tab-indicator__content--underline{align-self:flex-end;box-sizing:border-box;width:100%;border-top-style:solid}.mdc-tab-indicator__content--icon{align-self:center;margin:0 auto}.mdc-tab-indicator--active .mdc-tab-indicator__content{opacity:1}.mdc-tab-indicator .mdc-tab-indicator__content{transition:250ms transform cubic-bezier(0.4, 0, 0.2, 1)}.mdc-tab-indicator--no-transition .mdc-tab-indicator__content{transition:none}.mdc-tab-indicator--fade .mdc-tab-indicator__content{transition:150ms opacity linear}.mdc-tab-indicator--active.mdc-tab-indicator--fade .mdc-tab-indicator__content{transition-delay:100ms}`;let zi=class extends Oi{};zi.styles=[$i],zi=n([ct("polr-tab-indicator")],zi);let Pi=class extends Ci{renderIndicator(){return B`
`}};Pi.styles=[Si],Pi=n([ct("polr-tab")],Pi),n([gt("polr-tab-indicator")],Ci.prototype,"tabIndicator",void 0);
/**
* @license
* Copyright 2018 Google Inc.
@@ -6411,49 +1047,25 @@ var MDCTabScrollerRTLDefault = /** @class */ (function (_super) {
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
-var MDCTabScrollerRTLNegative = /** @class */ (function (_super) {
- __extends(MDCTabScrollerRTLNegative, _super);
- function MDCTabScrollerRTLNegative() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- MDCTabScrollerRTLNegative.prototype.getScrollPositionRTL = function (translateX) {
- var currentScrollLeft = this.adapter.getScrollAreaScrollLeft();
- return Math.round(translateX - currentScrollLeft);
- };
- MDCTabScrollerRTLNegative.prototype.scrollToRTL = function (scrollX) {
- var currentScrollLeft = this.adapter.getScrollAreaScrollLeft();
- var clampedScrollLeft = this.clampScrollValue(-scrollX);
- return {
- finalScrollPosition: clampedScrollLeft,
- scrollDelta: clampedScrollLeft - currentScrollLeft,
- };
- };
- MDCTabScrollerRTLNegative.prototype.incrementScrollRTL = function (scrollX) {
- var currentScrollLeft = this.adapter.getScrollAreaScrollLeft();
- var clampedScrollLeft = this.clampScrollValue(currentScrollLeft - scrollX);
- return {
- finalScrollPosition: clampedScrollLeft,
- scrollDelta: clampedScrollLeft - currentScrollLeft,
- };
- };
- MDCTabScrollerRTLNegative.prototype.getAnimatingScrollPosition = function (scrollX, translateX) {
- return scrollX - translateX;
- };
- MDCTabScrollerRTLNegative.prototype.calculateScrollEdges = function () {
- var contentWidth = this.adapter.getScrollContentOffsetWidth();
- var rootWidth = this.adapter.getScrollAreaOffsetWidth();
- return {
- left: rootWidth - contentWidth,
- right: 0,
- };
- };
- MDCTabScrollerRTLNegative.prototype.clampScrollValue = function (scrollX) {
- var edges = this.calculateScrollEdges();
- return Math.max(Math.min(edges.right, scrollX), edges.left);
- };
- return MDCTabScrollerRTLNegative;
-}(MDCTabScrollerRTL));
-
+var Vi={ARROW_LEFT_KEY:"ArrowLeft",ARROW_RIGHT_KEY:"ArrowRight",END_KEY:"End",ENTER_KEY:"Enter",HOME_KEY:"Home",SPACE_KEY:"Space",TAB_ACTIVATED_EVENT:"MDCTabBar:activated",TAB_SCROLLER_SELECTOR:".mdc-tab-scroller",TAB_SELECTOR:".mdc-tab"},Mi={ARROW_LEFT_KEYCODE:37,ARROW_RIGHT_KEYCODE:39,END_KEYCODE:35,ENTER_KEYCODE:13,EXTRA_SCROLL_AMOUNT:20,HOME_KEYCODE:36,SPACE_KEYCODE:32},Fi=new Set;Fi.add(Vi.ARROW_LEFT_KEY),Fi.add(Vi.ARROW_RIGHT_KEY),Fi.add(Vi.END_KEY),Fi.add(Vi.HOME_KEY),Fi.add(Vi.ENTER_KEY),Fi.add(Vi.SPACE_KEY);var Ni=new Map;Ni.set(Mi.ARROW_LEFT_KEYCODE,Vi.ARROW_LEFT_KEY),Ni.set(Mi.ARROW_RIGHT_KEYCODE,Vi.ARROW_RIGHT_KEY),Ni.set(Mi.END_KEYCODE,Vi.END_KEY),Ni.set(Mi.HOME_KEYCODE,Vi.HOME_KEY),Ni.set(Mi.ENTER_KEYCODE,Vi.ENTER_KEY),Ni.set(Mi.SPACE_KEYCODE,Vi.SPACE_KEY);var Hi=function(t){function n(e){var r=t.call(this,i(i({},n.defaultAdapter),e))||this;return r.useAutomaticActivation=!1,r}return e(n,t),Object.defineProperty(n,"strings",{get:function(){return Vi},enumerable:!1,configurable:!0}),Object.defineProperty(n,"numbers",{get:function(){return Mi},enumerable:!1,configurable:!0}),Object.defineProperty(n,"defaultAdapter",{get:function(){return{scrollTo:function(){},incrementScroll:function(){},getScrollPosition:function(){return 0},getScrollContentWidth:function(){return 0},getOffsetWidth:function(){return 0},isRTL:function(){return!1},setActiveTab:function(){},activateTabAtIndex:function(){},deactivateTabAtIndex:function(){},focusTabAtIndex:function(){},getTabIndicatorClientRectAtIndex:function(){return{top:0,right:0,bottom:0,left:0,width:0,height:0}},getTabDimensionsAtIndex:function(){return{rootLeft:0,rootRight:0,contentLeft:0,contentRight:0}},getPreviousActiveTabIndex:function(){return-1},getFocusedTabIndex:function(){return-1},getIndexOfTabById:function(){return-1},getTabListLength:function(){return 0},notifyTabActivated:function(){}}},enumerable:!1,configurable:!0}),n.prototype.setUseAutomaticActivation=function(t){this.useAutomaticActivation=t},n.prototype.activateTab=function(t){var e,i=this.adapter.getPreviousActiveTabIndex();this.indexIsInRange(t)&&t!==i&&(-1!==i&&(this.adapter.deactivateTabAtIndex(i),e=this.adapter.getTabIndicatorClientRectAtIndex(i)),this.adapter.activateTabAtIndex(t,e),this.scrollIntoView(t),this.adapter.notifyTabActivated(t))},n.prototype.handleKeyDown=function(t){var e=this.getKeyFromEvent(t);if(void 0!==e)if(this.isActivationKey(e)||t.preventDefault(),this.useAutomaticActivation){if(this.isActivationKey(e))return;var i=this.determineTargetFromKey(this.adapter.getPreviousActiveTabIndex(),e);this.adapter.setActiveTab(i),this.scrollIntoView(i)}else{var n=this.adapter.getFocusedTabIndex();if(this.isActivationKey(e))this.adapter.setActiveTab(n);else{i=this.determineTargetFromKey(n,e);this.adapter.focusTabAtIndex(i),this.scrollIntoView(i)}}},n.prototype.handleTabInteraction=function(t){this.adapter.setActiveTab(this.adapter.getIndexOfTabById(t.detail.tabId))},n.prototype.scrollIntoView=function(t){this.indexIsInRange(t)&&(0!==t?t!==this.adapter.getTabListLength()-1?this.isRTL()?this.scrollIntoViewImplRTL(t):this.scrollIntoViewImpl(t):this.adapter.scrollTo(this.adapter.getScrollContentWidth()):this.adapter.scrollTo(0))},n.prototype.determineTargetFromKey=function(t,e){var i=this.isRTL(),n=this.adapter.getTabListLength()-1,r=t;return e===Vi.END_KEY?r=n:e===Vi.ARROW_LEFT_KEY&&!i||e===Vi.ARROW_RIGHT_KEY&&i?r-=1:e===Vi.ARROW_RIGHT_KEY&&!i||e===Vi.ARROW_LEFT_KEY&&i?r+=1:r=0,r<0?r=n:r>n&&(r=0),r},n.prototype.calculateScrollIncrement=function(t,e,i,n){var r=this.adapter.getTabDimensionsAtIndex(e),a=r.contentLeft-i-n,l=r.contentRight-i-Mi.EXTRA_SCROLL_AMOUNT,o=a+Mi.EXTRA_SCROLL_AMOUNT;return e
t?Math.max(o,0):Math.min(d,0)},n.prototype.findAdjacentTabIndexClosestToEdge=function(t,e,i,n){var r=e.rootLeft-i,a=e.rootRight-i-n,l=r+a;return r<0||l<0?t-1:a>0||l>0?t+1:-1},n.prototype.findAdjacentTabIndexClosestToEdgeRTL=function(t,e,i,n,r){var a=r-e.rootLeft-n-i,l=r-e.rootRight-i,o=a+l;return a>0||o>0?t+1:l<0||o<0?t-1:-1},n.prototype.getKeyFromEvent=function(t){return Fi.has(t.key)?t.key:Ni.get(t.keyCode)},n.prototype.isActivationKey=function(t){return t===Vi.SPACE_KEY||t===Vi.ENTER_KEY},n.prototype.indexIsInRange=function(t){return t>=0&&t
+
+
+ `}_getTabs(){return this.tabsSlot.assignedNodes({flatten:!0}).filter((t=>t instanceof Ci))}_getTab(t){return this._getTabs()[t]}createAdapter(){return{scrollTo:t=>this.scrollerElement.scrollToPosition(t),incrementScroll:t=>this.scrollerElement.incrementScrollPosition(t),getScrollPosition:()=>this.scrollerElement.getScrollPosition(),getScrollContentWidth:()=>this.scrollerElement.getScrollContentWidth(),getOffsetWidth:()=>this.mdcRoot.offsetWidth,isRTL:()=>"rtl"===window.getComputedStyle(this.mdcRoot).getPropertyValue("direction"),setActiveTab:t=>this.mdcFoundation.activateTab(t),activateTabAtIndex:(t,e)=>{const i=this._getTab(t);void 0!==i&&i.activate(e),this._previousActiveIndex=t},deactivateTabAtIndex:t=>{const e=this._getTab(t);void 0!==e&&e.deactivate()},focusTabAtIndex:t=>{const e=this._getTab(t);void 0!==e&&e.focus()},getTabIndicatorClientRectAtIndex:t=>{const e=this._getTab(t);return void 0!==e?e.computeIndicatorClientRect():new DOMRect},getTabDimensionsAtIndex:t=>{const e=this._getTab(t);return void 0!==e?e.computeDimensions():{rootLeft:0,rootRight:0,contentLeft:0,contentRight:0}},getPreviousActiveTabIndex:()=>this._previousActiveIndex,getFocusedTabIndex:()=>{const t=this._getTabs(),e=this.getRootNode().activeElement;return t.indexOf(e)},getIndexOfTabById:t=>{const e=this._getTabs();for(let i=0;ithis._getTabs().length,notifyTabActivated:t=>{this.activeIndex=t,this.dispatchEvent(new CustomEvent(Hi.strings.TAB_ACTIVATED_EVENT,{detail:{index:t},bubbles:!0,cancelable:!0}))}}}firstUpdated(){}async getUpdateComplete(){const t=await super.getUpdateComplete();return await this.scrollerElement.updateComplete,void 0===this.mdcFoundation&&this.createFoundation(),t}scrollIndexIntoView(t){this.mdcFoundation.scrollIntoView(t)}}n([gt(".mdc-tab-bar")],Di.prototype,"mdcRoot",void 0),n([gt("mwc-tab-scroller")],Di.prototype,"scrollerElement",void 0),n([gt("slot")],Di.prototype,"tabsSlot",void 0),n([Te((async function(){await this.updateComplete,this.activeIndex!==this._previousActiveIndex&&this.mdcFoundation.activateTab(this.activeIndex)})),ht({type:Number})],Di.prototype,"activeIndex",void 0);
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-LIcense-Identifier: Apache-2.0
+ */
+const Bi=s`.mdc-tab-bar{width:100%}.mdc-tab{height:48px}.mdc-tab--stacked{height:72px}:host{display:block}.mdc-tab-bar{flex:1}mwc-tab{--mdc-tab-height: 48px;--mdc-tab-stacked-height: 72px}`
/**
* @license
* Copyright 2018 Google Inc.
@@ -6475,51 +1087,7 @@ var MDCTabScrollerRTLNegative = /** @class */ (function (_super) {
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
- */
-var MDCTabScrollerRTLReverse = /** @class */ (function (_super) {
- __extends(MDCTabScrollerRTLReverse, _super);
- function MDCTabScrollerRTLReverse() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- MDCTabScrollerRTLReverse.prototype.getScrollPositionRTL = function (translateX) {
- var currentScrollLeft = this.adapter.getScrollAreaScrollLeft();
- // Scroll values on most browsers are ints instead of floats so we round
- return Math.round(currentScrollLeft - translateX);
- };
- MDCTabScrollerRTLReverse.prototype.scrollToRTL = function (scrollX) {
- var currentScrollLeft = this.adapter.getScrollAreaScrollLeft();
- var clampedScrollLeft = this.clampScrollValue(scrollX);
- return {
- finalScrollPosition: clampedScrollLeft,
- scrollDelta: currentScrollLeft - clampedScrollLeft,
- };
- };
- MDCTabScrollerRTLReverse.prototype.incrementScrollRTL = function (scrollX) {
- var currentScrollLeft = this.adapter.getScrollAreaScrollLeft();
- var clampedScrollLeft = this.clampScrollValue(currentScrollLeft + scrollX);
- return {
- finalScrollPosition: clampedScrollLeft,
- scrollDelta: currentScrollLeft - clampedScrollLeft,
- };
- };
- MDCTabScrollerRTLReverse.prototype.getAnimatingScrollPosition = function (scrollX, translateX) {
- return scrollX + translateX;
- };
- MDCTabScrollerRTLReverse.prototype.calculateScrollEdges = function () {
- var contentWidth = this.adapter.getScrollContentOffsetWidth();
- var rootWidth = this.adapter.getScrollAreaOffsetWidth();
- return {
- left: contentWidth - rootWidth,
- right: 0,
- };
- };
- MDCTabScrollerRTLReverse.prototype.clampScrollValue = function (scrollX) {
- var edges = this.calculateScrollEdges();
- return Math.min(Math.max(edges.right, scrollX), edges.left);
- };
- return MDCTabScrollerRTLReverse;
-}(MDCTabScrollerRTL));
-
+ */;
/**
* @license
* Copyright 2018 Google Inc.
@@ -6542,345 +1110,13 @@ var MDCTabScrollerRTLReverse = /** @class */ (function (_super) {
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
-var MDCTabScrollerFoundation = /** @class */ (function (_super) {
- __extends(MDCTabScrollerFoundation, _super);
- function MDCTabScrollerFoundation(adapter) {
- var _this = _super.call(this, __assign(__assign({}, MDCTabScrollerFoundation.defaultAdapter), adapter)) || this;
- /**
- * Controls whether we should handle the transitionend and interaction events during the animation.
- */
- _this.isAnimating = false;
- return _this;
- }
- Object.defineProperty(MDCTabScrollerFoundation, "cssClasses", {
- get: function () {
- return cssClasses;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTabScrollerFoundation, "strings", {
- get: function () {
- return strings;
- },
- enumerable: false,
- configurable: true
- });
- Object.defineProperty(MDCTabScrollerFoundation, "defaultAdapter", {
- get: function () {
- // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
- return {
- eventTargetMatchesSelector: function () { return false; },
- addClass: function () { return undefined; },
- removeClass: function () { return undefined; },
- addScrollAreaClass: function () { return undefined; },
- setScrollAreaStyleProperty: function () { return undefined; },
- setScrollContentStyleProperty: function () { return undefined; },
- getScrollContentStyleValue: function () { return ''; },
- setScrollAreaScrollLeft: function () { return undefined; },
- getScrollAreaScrollLeft: function () { return 0; },
- getScrollContentOffsetWidth: function () { return 0; },
- getScrollAreaOffsetWidth: function () { return 0; },
- computeScrollAreaClientRect: function () {
- return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 });
- },
- computeScrollContentClientRect: function () {
- return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 });
- },
- computeHorizontalScrollbarHeight: function () { return 0; },
- };
- // tslint:enable:object-literal-sort-keys
- },
- enumerable: false,
- configurable: true
- });
- MDCTabScrollerFoundation.prototype.init = function () {
- // Compute horizontal scrollbar height on scroller with overflow initially hidden, then update overflow to scroll
- // and immediately adjust bottom margin to avoid the scrollbar initially appearing before JS runs.
- var horizontalScrollbarHeight = this.adapter.computeHorizontalScrollbarHeight();
- this.adapter.setScrollAreaStyleProperty('margin-bottom', -horizontalScrollbarHeight + 'px');
- this.adapter.addScrollAreaClass(MDCTabScrollerFoundation.cssClasses.SCROLL_AREA_SCROLL);
- };
- /**
- * Computes the current visual scroll position
- */
- MDCTabScrollerFoundation.prototype.getScrollPosition = function () {
- if (this.isRTL()) {
- return this.computeCurrentScrollPositionRTL();
- }
- var currentTranslateX = this.calculateCurrentTranslateX();
- var scrollLeft = this.adapter.getScrollAreaScrollLeft();
- return scrollLeft - currentTranslateX;
- };
- /**
- * Handles interaction events that occur during transition
- */
- MDCTabScrollerFoundation.prototype.handleInteraction = function () {
- // Early exit if we aren't animating
- if (!this.isAnimating) {
- return;
- }
- // Prevent other event listeners from handling this event
- this.stopScrollAnimation();
- };
- /**
- * Handles the transitionend event
- */
- MDCTabScrollerFoundation.prototype.handleTransitionEnd = function (evt) {
- // Early exit if we aren't animating or the event was triggered by a different element.
- var evtTarget = evt.target;
- if (!this.isAnimating ||
- !this.adapter.eventTargetMatchesSelector(evtTarget, MDCTabScrollerFoundation.strings.CONTENT_SELECTOR)) {
- return;
- }
- this.isAnimating = false;
- this.adapter.removeClass(MDCTabScrollerFoundation.cssClasses.ANIMATING);
- };
- /**
- * Increment the scroll value by the scrollXIncrement using animation.
- * @param scrollXIncrement The value by which to increment the scroll position
- */
- MDCTabScrollerFoundation.prototype.incrementScroll = function (scrollXIncrement) {
- // Early exit for non-operational increment values
- if (scrollXIncrement === 0) {
- return;
- }
- this.animate(this.getIncrementScrollOperation(scrollXIncrement));
- };
- /**
- * Increment the scroll value by the scrollXIncrement without animation.
- * @param scrollXIncrement The value by which to increment the scroll position
- */
- MDCTabScrollerFoundation.prototype.incrementScrollImmediate = function (scrollXIncrement) {
- // Early exit for non-operational increment values
- if (scrollXIncrement === 0) {
- return;
- }
- var operation = this.getIncrementScrollOperation(scrollXIncrement);
- if (operation.scrollDelta === 0) {
- return;
- }
- this.stopScrollAnimation();
- this.adapter.setScrollAreaScrollLeft(operation.finalScrollPosition);
- };
- /**
- * Scrolls to the given scrollX value
- */
- MDCTabScrollerFoundation.prototype.scrollTo = function (scrollX) {
- if (this.isRTL()) {
- this.scrollToImplRTL(scrollX);
- return;
- }
- this.scrollToImpl(scrollX);
- };
- /**
- * @return Browser-specific {@link MDCTabScrollerRTL} instance.
- */
- MDCTabScrollerFoundation.prototype.getRTLScroller = function () {
- if (!this.rtlScrollerInstance) {
- this.rtlScrollerInstance = this.rtlScrollerFactory();
- }
- return this.rtlScrollerInstance;
- };
- /**
- * @return translateX value from a CSS matrix transform function string.
- */
- MDCTabScrollerFoundation.prototype.calculateCurrentTranslateX = function () {
- var transformValue = this.adapter.getScrollContentStyleValue('transform');
- // Early exit if no transform is present
- if (transformValue === 'none') {
- return 0;
- }
- // The transform value comes back as a matrix transformation in the form
- // of `matrix(a, b, c, d, tx, ty)`. We only care about tx (translateX) so
- // we're going to grab all the parenthesized values, strip out tx, and
- // parse it.
- var match = /\((.+?)\)/.exec(transformValue);
- if (!match) {
- return 0;
- }
- var matrixParams = match[1];
- // tslint:disable-next-line:ban-ts-ignore "Unused vars" should be a linter warning, not a compiler error.
- // @ts-ignore These unused variables should retain their semantic names for clarity.
- var _a = __read(matrixParams.split(','), 6); _a[0]; _a[1]; _a[2]; _a[3]; var tx = _a[4]; _a[5];
- return parseFloat(tx); // tslint:disable-line:ban
- };
- /**
- * Calculates a safe scroll value that is > 0 and < the max scroll value
- * @param scrollX The distance to scroll
- */
- MDCTabScrollerFoundation.prototype.clampScrollValue = function (scrollX) {
- var edges = this.calculateScrollEdges();
- return Math.min(Math.max(edges.left, scrollX), edges.right);
- };
- MDCTabScrollerFoundation.prototype.computeCurrentScrollPositionRTL = function () {
- var translateX = this.calculateCurrentTranslateX();
- return this.getRTLScroller().getScrollPositionRTL(translateX);
- };
- MDCTabScrollerFoundation.prototype.calculateScrollEdges = function () {
- var contentWidth = this.adapter.getScrollContentOffsetWidth();
- var rootWidth = this.adapter.getScrollAreaOffsetWidth();
- return {
- left: 0,
- right: contentWidth - rootWidth,
- };
- };
- /**
- * Internal scroll method
- * @param scrollX The new scroll position
- */
- MDCTabScrollerFoundation.prototype.scrollToImpl = function (scrollX) {
- var currentScrollX = this.getScrollPosition();
- var safeScrollX = this.clampScrollValue(scrollX);
- var scrollDelta = safeScrollX - currentScrollX;
- this.animate({
- finalScrollPosition: safeScrollX,
- scrollDelta: scrollDelta,
- });
- };
- /**
- * Internal RTL scroll method
- * @param scrollX The new scroll position
- */
- MDCTabScrollerFoundation.prototype.scrollToImplRTL = function (scrollX) {
- var animation = this.getRTLScroller().scrollToRTL(scrollX);
- this.animate(animation);
- };
- /**
- * Internal method to compute the increment scroll operation values.
- * @param scrollX The desired scroll position increment
- * @return MDCTabScrollerAnimation with the sanitized values for performing the scroll operation.
- */
- MDCTabScrollerFoundation.prototype.getIncrementScrollOperation = function (scrollX) {
- if (this.isRTL()) {
- return this.getRTLScroller().incrementScrollRTL(scrollX);
- }
- var currentScrollX = this.getScrollPosition();
- var targetScrollX = scrollX + currentScrollX;
- var safeScrollX = this.clampScrollValue(targetScrollX);
- var scrollDelta = safeScrollX - currentScrollX;
- return {
- finalScrollPosition: safeScrollX,
- scrollDelta: scrollDelta,
- };
- };
- /**
- * Animates the tab scrolling
- * @param animation The animation to apply
- */
- MDCTabScrollerFoundation.prototype.animate = function (animation) {
- var _this = this;
- // Early exit if translateX is 0, which means there's no animation to perform
- if (animation.scrollDelta === 0) {
- return;
- }
- this.stopScrollAnimation();
- // This animation uses the FLIP approach.
- // Read more here: https://aerotwist.com/blog/flip-your-animations/
- this.adapter.setScrollAreaScrollLeft(animation.finalScrollPosition);
- this.adapter.setScrollContentStyleProperty('transform', "translateX(" + animation.scrollDelta + "px)");
- // Force repaint
- this.adapter.computeScrollAreaClientRect();
- requestAnimationFrame(function () {
- _this.adapter.addClass(MDCTabScrollerFoundation.cssClasses.ANIMATING);
- _this.adapter.setScrollContentStyleProperty('transform', 'none');
- });
- this.isAnimating = true;
- };
- /**
- * Stops scroll animation
- */
- MDCTabScrollerFoundation.prototype.stopScrollAnimation = function () {
- this.isAnimating = false;
- var currentScrollPosition = this.getAnimatingScrollPosition();
- this.adapter.removeClass(MDCTabScrollerFoundation.cssClasses.ANIMATING);
- this.adapter.setScrollContentStyleProperty('transform', 'translateX(0px)');
- this.adapter.setScrollAreaScrollLeft(currentScrollPosition);
- };
- /**
- * Gets the current scroll position during animation
- */
- MDCTabScrollerFoundation.prototype.getAnimatingScrollPosition = function () {
- var currentTranslateX = this.calculateCurrentTranslateX();
- var scrollLeft = this.adapter.getScrollAreaScrollLeft();
- if (this.isRTL()) {
- return this.getRTLScroller().getAnimatingScrollPosition(scrollLeft, currentTranslateX);
- }
- return scrollLeft - currentTranslateX;
- };
- /**
- * Determines the RTL Scroller to use
- */
- MDCTabScrollerFoundation.prototype.rtlScrollerFactory = function () {
- // Browsers have three different implementations of scrollLeft in RTL mode,
- // dependent on the browser. The behavior is based off the max LTR
- // scrollLeft value and 0.
- //
- // * Default scrolling in RTL *
- // - Left-most value: 0
- // - Right-most value: Max LTR scrollLeft value
- //
- // * Negative scrolling in RTL *
- // - Left-most value: Negated max LTR scrollLeft value
- // - Right-most value: 0
- //
- // * Reverse scrolling in RTL *
- // - Left-most value: Max LTR scrollLeft value
- // - Right-most value: 0
- //
- // We use those principles below to determine which RTL scrollLeft
- // behavior is implemented in the current browser.
- var initialScrollLeft = this.adapter.getScrollAreaScrollLeft();
- this.adapter.setScrollAreaScrollLeft(initialScrollLeft - 1);
- var newScrollLeft = this.adapter.getScrollAreaScrollLeft();
- // If the newScrollLeft value is negative,then we know that the browser has
- // implemented negative RTL scrolling, since all other implementations have
- // only positive values.
- if (newScrollLeft < 0) {
- // Undo the scrollLeft test check
- this.adapter.setScrollAreaScrollLeft(initialScrollLeft);
- return new MDCTabScrollerRTLNegative(this.adapter);
- }
- var rootClientRect = this.adapter.computeScrollAreaClientRect();
- var contentClientRect = this.adapter.computeScrollContentClientRect();
- var rightEdgeDelta = Math.round(contentClientRect.right - rootClientRect.right);
- // Undo the scrollLeft test check
- this.adapter.setScrollAreaScrollLeft(initialScrollLeft);
- // By calculating the clientRect of the root element and the clientRect of
- // the content element, we can determine how much the scroll value changed
- // when we performed the scrollLeft subtraction above.
- if (rightEdgeDelta === newScrollLeft) {
- return new MDCTabScrollerRTLReverse(this.adapter);
- }
- return new MDCTabScrollerRTLDefault(this.adapter);
- };
- MDCTabScrollerFoundation.prototype.isRTL = function () {
- return this.adapter.getScrollContentStyleValue('direction') === 'rtl';
- };
- return MDCTabScrollerFoundation;
-}(MDCFoundation));
-// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
-var MDCTabScrollerFoundation$1 = MDCTabScrollerFoundation;
-
+var Ui={ANIMATING:"mdc-tab-scroller--animating",SCROLL_AREA_SCROLL:"mdc-tab-scroller__scroll-area--scroll",SCROLL_TEST:"mdc-tab-scroller__test"},Yi={AREA_SELECTOR:".mdc-tab-scroller__scroll-area",CONTENT_SELECTOR:".mdc-tab-scroller__scroll-content"},Wi=function(t){this.adapter=t},ji=function(t){function i(){return null!==t&&t.apply(this,arguments)||this}return e(i,t),i.prototype.getScrollPositionRTL=function(){var t=this.adapter.getScrollAreaScrollLeft(),e=this.calculateScrollEdges().right;return Math.round(e-t)},i.prototype.scrollToRTL=function(t){var e=this.calculateScrollEdges(),i=this.adapter.getScrollAreaScrollLeft(),n=this.clampScrollValue(e.right-t);return{finalScrollPosition:n,scrollDelta:n-i}},i.prototype.incrementScrollRTL=function(t){var e=this.adapter.getScrollAreaScrollLeft(),i=this.clampScrollValue(e-t);return{finalScrollPosition:i,scrollDelta:i-e}},i.prototype.getAnimatingScrollPosition=function(t){return t},i.prototype.calculateScrollEdges=function(){return{left:0,right:this.adapter.getScrollContentOffsetWidth()-this.adapter.getScrollAreaOffsetWidth()}},i.prototype.clampScrollValue=function(t){var e=this.calculateScrollEdges();return Math.min(Math.max(e.left,t),e.right)},i}(Wi),Xi=function(t){function i(){return null!==t&&t.apply(this,arguments)||this}return e(i,t),i.prototype.getScrollPositionRTL=function(t){var e=this.adapter.getScrollAreaScrollLeft();return Math.round(t-e)},i.prototype.scrollToRTL=function(t){var e=this.adapter.getScrollAreaScrollLeft(),i=this.clampScrollValue(-t);return{finalScrollPosition:i,scrollDelta:i-e}},i.prototype.incrementScrollRTL=function(t){var e=this.adapter.getScrollAreaScrollLeft(),i=this.clampScrollValue(e-t);return{finalScrollPosition:i,scrollDelta:i-e}},i.prototype.getAnimatingScrollPosition=function(t,e){return t-e},i.prototype.calculateScrollEdges=function(){var t=this.adapter.getScrollContentOffsetWidth();return{left:this.adapter.getScrollAreaOffsetWidth()-t,right:0}},i.prototype.clampScrollValue=function(t){var e=this.calculateScrollEdges();return Math.max(Math.min(e.right,t),e.left)},i}(Wi),qi=function(t){function i(){return null!==t&&t.apply(this,arguments)||this}return e(i,t),i.prototype.getScrollPositionRTL=function(t){var e=this.adapter.getScrollAreaScrollLeft();return Math.round(e-t)},i.prototype.scrollToRTL=function(t){var e=this.adapter.getScrollAreaScrollLeft(),i=this.clampScrollValue(t);return{finalScrollPosition:i,scrollDelta:e-i}},i.prototype.incrementScrollRTL=function(t){var e=this.adapter.getScrollAreaScrollLeft(),i=this.clampScrollValue(e+t);return{finalScrollPosition:i,scrollDelta:e-i}},i.prototype.getAnimatingScrollPosition=function(t,e){return t+e},i.prototype.calculateScrollEdges=function(){return{left:this.adapter.getScrollContentOffsetWidth()-this.adapter.getScrollAreaOffsetWidth(),right:0}},i.prototype.clampScrollValue=function(t){var e=this.calculateScrollEdges();return Math.min(Math.max(e.right,t),e.left)},i}(Wi),Ki=function(t){function n(e){var r=t.call(this,i(i({},n.defaultAdapter),e))||this;return r.isAnimating=!1,r}return e(n,t),Object.defineProperty(n,"cssClasses",{get:function(){return Ui},enumerable:!1,configurable:!0}),Object.defineProperty(n,"strings",{get:function(){return Yi},enumerable:!1,configurable:!0}),Object.defineProperty(n,"defaultAdapter",{get:function(){return{eventTargetMatchesSelector:function(){return!1},addClass:function(){},removeClass:function(){},addScrollAreaClass:function(){},setScrollAreaStyleProperty:function(){},setScrollContentStyleProperty:function(){},getScrollContentStyleValue:function(){return""},setScrollAreaScrollLeft:function(){},getScrollAreaScrollLeft:function(){return 0},getScrollContentOffsetWidth:function(){return 0},getScrollAreaOffsetWidth:function(){return 0},computeScrollAreaClientRect:function(){return{top:0,right:0,bottom:0,left:0,width:0,height:0}},computeScrollContentClientRect:function(){return{top:0,right:0,bottom:0,left:0,width:0,height:0}},computeHorizontalScrollbarHeight:function(){return 0}}},enumerable:!1,configurable:!0}),n.prototype.init=function(){var t=this.adapter.computeHorizontalScrollbarHeight();this.adapter.setScrollAreaStyleProperty("margin-bottom",-t+"px"),this.adapter.addScrollAreaClass(n.cssClasses.SCROLL_AREA_SCROLL)},n.prototype.getScrollPosition=function(){if(this.isRTL())return this.computeCurrentScrollPositionRTL();var t=this.calculateCurrentTranslateX();return this.adapter.getScrollAreaScrollLeft()-t},n.prototype.handleInteraction=function(){this.isAnimating&&this.stopScrollAnimation()},n.prototype.handleTransitionEnd=function(t){var e=t.target;this.isAnimating&&this.adapter.eventTargetMatchesSelector(e,n.strings.CONTENT_SELECTOR)&&(this.isAnimating=!1,this.adapter.removeClass(n.cssClasses.ANIMATING))},n.prototype.incrementScroll=function(t){0!==t&&this.animate(this.getIncrementScrollOperation(t))},n.prototype.incrementScrollImmediate=function(t){if(0!==t){var e=this.getIncrementScrollOperation(t);0!==e.scrollDelta&&(this.stopScrollAnimation(),this.adapter.setScrollAreaScrollLeft(e.finalScrollPosition))}},n.prototype.scrollTo=function(t){this.isRTL()?this.scrollToImplRTL(t):this.scrollToImpl(t)},n.prototype.getRTLScroller=function(){return this.rtlScrollerInstance||(this.rtlScrollerInstance=this.rtlScrollerFactory()),this.rtlScrollerInstance},n.prototype.calculateCurrentTranslateX=function(){var t=this.adapter.getScrollContentStyleValue("transform");if("none"===t)return 0;var e=/\((.+?)\)/.exec(t);if(!e)return 0;var i=function(t,e){var i="function"==typeof Symbol&&t[Symbol.iterator];if(!i)return t;var n,r,a=i.call(t),l=[];try{for(;(void 0===e||e-- >0)&&!(n=a.next()).done;)l.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}return l}(e[1].split(","),6);i[0],i[1],i[2],i[3];var n=i[4];return i[5],parseFloat(n)},n.prototype.clampScrollValue=function(t){var e=this.calculateScrollEdges();return Math.min(Math.max(e.left,t),e.right)},n.prototype.computeCurrentScrollPositionRTL=function(){var t=this.calculateCurrentTranslateX();return this.getRTLScroller().getScrollPositionRTL(t)},n.prototype.calculateScrollEdges=function(){return{left:0,right:this.adapter.getScrollContentOffsetWidth()-this.adapter.getScrollAreaOffsetWidth()}},n.prototype.scrollToImpl=function(t){var e=this.getScrollPosition(),i=this.clampScrollValue(t),n=i-e;this.animate({finalScrollPosition:i,scrollDelta:n})},n.prototype.scrollToImplRTL=function(t){var e=this.getRTLScroller().scrollToRTL(t);this.animate(e)},n.prototype.getIncrementScrollOperation=function(t){if(this.isRTL())return this.getRTLScroller().incrementScrollRTL(t);var e=this.getScrollPosition(),i=t+e,n=this.clampScrollValue(i);return{finalScrollPosition:n,scrollDelta:n-e}},n.prototype.animate=function(t){var e=this;0!==t.scrollDelta&&(this.stopScrollAnimation(),this.adapter.setScrollAreaScrollLeft(t.finalScrollPosition),this.adapter.setScrollContentStyleProperty("transform","translateX("+t.scrollDelta+"px)"),this.adapter.computeScrollAreaClientRect(),requestAnimationFrame((function(){e.adapter.addClass(n.cssClasses.ANIMATING),e.adapter.setScrollContentStyleProperty("transform","none")})),this.isAnimating=!0)},n.prototype.stopScrollAnimation=function(){this.isAnimating=!1;var t=this.getAnimatingScrollPosition();this.adapter.removeClass(n.cssClasses.ANIMATING),this.adapter.setScrollContentStyleProperty("transform","translateX(0px)"),this.adapter.setScrollAreaScrollLeft(t)},n.prototype.getAnimatingScrollPosition=function(){var t=this.calculateCurrentTranslateX(),e=this.adapter.getScrollAreaScrollLeft();return this.isRTL()?this.getRTLScroller().getAnimatingScrollPosition(e,t):e-t},n.prototype.rtlScrollerFactory=function(){var t=this.adapter.getScrollAreaScrollLeft();this.adapter.setScrollAreaScrollLeft(t-1);var e=this.adapter.getScrollAreaScrollLeft();if(e<0)return this.adapter.setScrollAreaScrollLeft(t),new Xi(this.adapter);var i=this.adapter.computeScrollAreaClientRect(),n=this.adapter.computeScrollContentClientRect(),r=Math.round(n.right-i.right);return this.adapter.setScrollAreaScrollLeft(t),r===e?new qi(this.adapter):new ji(this.adapter)},n.prototype.isRTL=function(){return"rtl"===this.adapter.getScrollContentStyleValue("direction")},n}(Ie),Gi=Ki;
/**
* @license
* Copyright 2018 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
-class TabScrollerBase extends BaseElement {
- constructor() {
- super(...arguments);
- this.mdcFoundationClass = MDCTabScrollerFoundation$1;
- this._scrollbarHeight = -1;
- }
- _handleInteraction() {
- this.mdcFoundation.handleInteraction();
- }
- _handleTransitionEnd(e) {
- this.mdcFoundation.handleTransitionEnd(e);
- }
- render() {
- return x `
+class Zi extends Ee{constructor(){super(...arguments),this.mdcFoundationClass=Gi,this._scrollbarHeight=-1}_handleInteraction(){this.mdcFoundation.handleInteraction()}_handleTransitionEnd(t){this.mdcFoundation.handleTransitionEnd(t)}render(){return B`
- `;
- }
- createAdapter() {
- return Object.assign(Object.assign({}, addHasRemoveClass(this.mdcRoot)), { eventTargetMatchesSelector: (evtTarget, selector) => matches(evtTarget, selector), addScrollAreaClass: (className) => this.scrollAreaElement.classList.add(className), setScrollAreaStyleProperty: (prop, value) => this.scrollAreaElement.style.setProperty(prop, value), setScrollContentStyleProperty: (prop, value) => this.scrollContentElement.style.setProperty(prop, value), getScrollContentStyleValue: (propName) => window.getComputedStyle(this.scrollContentElement)
- .getPropertyValue(propName), setScrollAreaScrollLeft: (scrollX) => this.scrollAreaElement.scrollLeft = scrollX, getScrollAreaScrollLeft: () => this.scrollAreaElement.scrollLeft, getScrollContentOffsetWidth: () => this.scrollContentElement.offsetWidth, getScrollAreaOffsetWidth: () => this.scrollAreaElement.offsetWidth, computeScrollAreaClientRect: () => this.scrollAreaElement.getBoundingClientRect(), computeScrollContentClientRect: () => this.scrollContentElement.getBoundingClientRect(), computeHorizontalScrollbarHeight: () => {
- if (this._scrollbarHeight === -1) {
- this.scrollAreaElement.style.overflowX = 'scroll';
- this._scrollbarHeight = this.scrollAreaElement.offsetHeight -
- this.scrollAreaElement.clientHeight;
- this.scrollAreaElement.style.overflowX = '';
- }
- return this._scrollbarHeight;
- } });
- }
- /**
- * Returns the current visual scroll position
- * @return {number}
- */
- getScrollPosition() {
- return this.mdcFoundation.getScrollPosition();
- }
- /**
- * Returns the width of the scroll content
- * @return {number}
- */
- getScrollContentWidth() {
- return this.scrollContentElement.offsetWidth;
- }
- /**
- * Increments the scroll value by the given amount
- * @param {number} scrollXIncrement The pixel value by which to increment the
- * scroll value
- */
- incrementScrollPosition(scrollXIncrement) {
- this.mdcFoundation.incrementScroll(scrollXIncrement);
- }
- /**
- * Scrolls to the given pixel position
- * @param {number} scrollX The pixel value to scroll to
- */
- scrollToPosition(scrollX) {
- this.mdcFoundation.scrollTo(scrollX);
- }
-}
-__decorate([
- i$2('.mdc-tab-scroller')
-], TabScrollerBase.prototype, "mdcRoot", void 0);
-__decorate([
- i$2('.mdc-tab-scroller__scroll-area')
-], TabScrollerBase.prototype, "scrollAreaElement", void 0);
-__decorate([
- i$2('.mdc-tab-scroller__scroll-content')
-], TabScrollerBase.prototype, "scrollContentElement", void 0);
-__decorate([
- e$3({ passive: true })
-], TabScrollerBase.prototype, "_handleInteraction", null);
-
+ `}createAdapter(){return Object.assign(Object.assign({},xe(this.mdcRoot)),{eventTargetMatchesSelector:(t,e)=>function(t,e){return(t.matches||t.webkitMatchesSelector||t.msMatchesSelector).call(t,e)}(t,e),addScrollAreaClass:t=>this.scrollAreaElement.classList.add(t),setScrollAreaStyleProperty:(t,e)=>this.scrollAreaElement.style.setProperty(t,e),setScrollContentStyleProperty:(t,e)=>this.scrollContentElement.style.setProperty(t,e),getScrollContentStyleValue:t=>window.getComputedStyle(this.scrollContentElement).getPropertyValue(t),setScrollAreaScrollLeft:t=>this.scrollAreaElement.scrollLeft=t,getScrollAreaScrollLeft:()=>this.scrollAreaElement.scrollLeft,getScrollContentOffsetWidth:()=>this.scrollContentElement.offsetWidth,getScrollAreaOffsetWidth:()=>this.scrollAreaElement.offsetWidth,computeScrollAreaClientRect:()=>this.scrollAreaElement.getBoundingClientRect(),computeScrollContentClientRect:()=>this.scrollContentElement.getBoundingClientRect(),computeHorizontalScrollbarHeight:()=>(-1===this._scrollbarHeight&&(this.scrollAreaElement.style.overflowX="scroll",this._scrollbarHeight=this.scrollAreaElement.offsetHeight-this.scrollAreaElement.clientHeight,this.scrollAreaElement.style.overflowX=""),this._scrollbarHeight)})}getScrollPosition(){return this.mdcFoundation.getScrollPosition()}getScrollContentWidth(){return this.scrollContentElement.offsetWidth}incrementScrollPosition(t){this.mdcFoundation.incrementScroll(t)}scrollToPosition(t){this.mdcFoundation.scrollTo(t)}}n([gt(".mdc-tab-scroller")],Zi.prototype,"mdcRoot",void 0),n([gt(".mdc-tab-scroller__scroll-area")],Zi.prototype,"scrollAreaElement",void 0),n([gt(".mdc-tab-scroller__scroll-content")],Zi.prototype,"scrollContentElement",void 0),n([ft({passive:!0})],Zi.prototype,"_handleInteraction",null);
/**
* @license
* Copyright 2021 Google LLC
* SPDX-LIcense-Identifier: Apache-2.0
*/
-const styles$1 = i$5 `.mdc-tab-scroller{overflow-y:hidden}.mdc-tab-scroller.mdc-tab-scroller--animating .mdc-tab-scroller__scroll-content{transition:250ms transform cubic-bezier(0.4, 0, 0.2, 1)}.mdc-tab-scroller__test{position:absolute;top:-9999px;width:100px;height:100px;overflow-x:scroll}.mdc-tab-scroller__scroll-area{-webkit-overflow-scrolling:touch;display:flex;overflow-x:hidden}.mdc-tab-scroller__scroll-area::-webkit-scrollbar,.mdc-tab-scroller__test::-webkit-scrollbar{display:none}.mdc-tab-scroller__scroll-area--scroll{overflow-x:scroll}.mdc-tab-scroller__scroll-content{position:relative;display:flex;flex:1 0 auto;transform:none;will-change:transform}.mdc-tab-scroller--align-start .mdc-tab-scroller__scroll-content{justify-content:flex-start}.mdc-tab-scroller--align-end .mdc-tab-scroller__scroll-content{justify-content:flex-end}.mdc-tab-scroller--align-center .mdc-tab-scroller__scroll-content{justify-content:center}.mdc-tab-scroller--animating .mdc-tab-scroller__scroll-area{-webkit-overflow-scrolling:auto}:host{display:flex}.mdc-tab-scroller{flex:1}`;
-
-let PoLRTabScroller = class PoLRTabScroller extends TabScrollerBase {
-};
-PoLRTabScroller.styles = [styles$1];
-PoLRTabScroller = __decorate([
- e$5("polr-tab-scroller")
-], PoLRTabScroller);
-
-let PoLRTabBar = class PoLRTabBar extends TabBarBase {
- render() {
- return x `
+const Qi=s`.mdc-tab-scroller{overflow-y:hidden}.mdc-tab-scroller.mdc-tab-scroller--animating .mdc-tab-scroller__scroll-content{transition:250ms transform cubic-bezier(0.4, 0, 0.2, 1)}.mdc-tab-scroller__test{position:absolute;top:-9999px;width:100px;height:100px;overflow-x:scroll}.mdc-tab-scroller__scroll-area{-webkit-overflow-scrolling:touch;display:flex;overflow-x:hidden}.mdc-tab-scroller__scroll-area::-webkit-scrollbar,.mdc-tab-scroller__test::-webkit-scrollbar{display:none}.mdc-tab-scroller__scroll-area--scroll{overflow-x:scroll}.mdc-tab-scroller__scroll-content{position:relative;display:flex;flex:1 0 auto;transform:none;will-change:transform}.mdc-tab-scroller--align-start .mdc-tab-scroller__scroll-content{justify-content:flex-start}.mdc-tab-scroller--align-end .mdc-tab-scroller__scroll-content{justify-content:flex-end}.mdc-tab-scroller--align-center .mdc-tab-scroller__scroll-content{justify-content:center}.mdc-tab-scroller--animating .mdc-tab-scroller__scroll-area{-webkit-overflow-scrolling:auto}:host{display:flex}.mdc-tab-scroller{flex:1}`;let Ji=class extends Zi{};Ji.styles=[Qi],Ji=n([ct("polr-tab-scroller")],Ji);let tn=class extends Di{render(){return B`
- `;
- }
-};
-PoLRTabBar.styles = [styles$2];
-PoLRTabBar = __decorate([
- e$5("polr-tab-bar")
-], PoLRTabBar);
-__decorate([i$2("polr-tab-scroller")], TabBarBase.prototype, "scrollerElement", void 0);
-
+ `}};tn.styles=[Bi],tn=n([ct("polr-tab-bar")],tn),n([gt("polr-tab-scroller")],Di.prototype,"scrollerElement",void 0);
/**
* @license
* Copyright 2018 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */const i="important",n$1=" !"+i,o=e$1(class extends i$1{constructor(t$1){var e;if(super(t$1),t$1.type!==t.ATTRIBUTE||"style"!==t$1.name||(null===(e=t$1.strings)||void 0===e?void 0:e.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(t){return Object.keys(t).reduce(((e,r)=>{const s=t[r];return null==s?e:e+`${r=r.includes("-")?r:r.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${s};`}),"")}update(e,[r]){const{style:s}=e.element;if(void 0===this.ut){this.ut=new Set;for(const t in r)this.ut.add(t);return this.render(r)}this.ut.forEach((t=>{null==r[t]&&(this.ut.delete(t),t.includes("-")?s.removeProperty(t):s[t]="");}));for(const t in r){const e=r[t];if(null!=e){this.ut.add(t);const r="string"==typeof e&&e.endsWith(n$1);t.includes("-")||r?s.setProperty(t,r?e.slice(0,-11):e,r?i:""):s[t]=e;}}return T}});
-
+ */
+const en="important",nn=" !"+en,rn=Pe(class extends Ve{constructor(t){var e;if(super(t),t.type!==Oe||"style"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(t){return Object.keys(t).reduce(((e,i)=>{const n=t[i];return null==n?e:e+`${i=i.includes("-")?i:i.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${n};`}),"")}update(t,[e]){const{style:i}=t.element;if(void 0===this.ut){this.ut=new Set;for(const t in e)this.ut.add(t);return this.render(e)}this.ut.forEach((t=>{null==e[t]&&(this.ut.delete(t),t.includes("-")?i.removeProperty(t):i[t]="")}));for(const t in e){const n=e[t];if(null!=n){this.ut.add(t);const e="string"==typeof n&&n.endsWith(nn);t.includes("-")||e?i.setProperty(t,e?n.slice(0,-11):n,e?en:""):i[t]=n}}return U}});
/**
* @license
* Copyright 2021 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */
-function n(n,o,r){return n?o():null==r?void 0:r()}
-
+ */function an(t,e,i){return t?e():null==i?void 0:i()}
/**
* @license
* Copyright 2023 Google LLC
* SPDX-License-Identifier: Apache-2.0
- */
-/**
- * Accessibility Object Model reflective aria properties.
- */
-const ARIA_PROPERTIES = [
- 'ariaAtomic',
- 'ariaAutoComplete',
- 'ariaBusy',
- 'ariaChecked',
- 'ariaColCount',
- 'ariaColIndex',
- 'ariaColSpan',
- 'ariaCurrent',
- 'ariaDisabled',
- 'ariaExpanded',
- 'ariaHasPopup',
- 'ariaHidden',
- 'ariaInvalid',
- 'ariaKeyShortcuts',
- 'ariaLabel',
- 'ariaLevel',
- 'ariaLive',
- 'ariaModal',
- 'ariaMultiLine',
- 'ariaMultiSelectable',
- 'ariaOrientation',
- 'ariaPlaceholder',
- 'ariaPosInSet',
- 'ariaPressed',
- 'ariaReadOnly',
- 'ariaRequired',
- 'ariaRoleDescription',
- 'ariaRowCount',
- 'ariaRowIndex',
- 'ariaRowSpan',
- 'ariaSelected',
- 'ariaSetSize',
- 'ariaSort',
- 'ariaValueMax',
- 'ariaValueMin',
- 'ariaValueNow',
- 'ariaValueText',
-];
-/**
- * Accessibility Object Model aria attributes.
- */
-ARIA_PROPERTIES.map(ariaPropertyToAttribute);
-/**
- * Converts an AOM aria property into its corresponding attribute.
- *
- * @example
- * ariaPropertyToAttribute('ariaLabel'); // 'aria-label'
- *
- * @param property The aria property.
- * @return The aria attribute.
- */
-function ariaPropertyToAttribute(property) {
- return property
- .replace('aria', 'aria-')
- // IDREF attributes also include an "Element" or "Elements" suffix
- .replace(/Elements?/g, '')
- .toLowerCase();
-}
-
+ */const ln=["ariaAtomic","ariaAutoComplete","ariaBusy","ariaChecked","ariaColCount","ariaColIndex","ariaColSpan","ariaCurrent","ariaDisabled","ariaExpanded","ariaHasPopup","ariaHidden","ariaInvalid","ariaKeyShortcuts","ariaLabel","ariaLevel","ariaLive","ariaModal","ariaMultiLine","ariaMultiSelectable","ariaOrientation","ariaPlaceholder","ariaPosInSet","ariaPressed","ariaReadOnly","ariaRequired","ariaRoleDescription","ariaRowCount","ariaRowIndex","ariaRowSpan","ariaSelected","ariaSetSize","ariaSort","ariaValueMax","ariaValueMin","ariaValueNow","ariaValueText"];function on(t){return t.replace("aria","aria-").replace(/Elements?/g,"").toLowerCase()}
/**
* @license
* Copyright 2023 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
-/**
- * Sets up a `ReactiveElement` constructor to enable updates when delegating
- * aria attributes. Elements may bind `this.aria*` properties to `aria-*`
- * attributes in their render functions.
- *
- * This function will:
- * - Call `requestUpdate()` when an aria attribute changes.
- * - Add `role="presentation"` to the host.
- *
- * NOTE: The following features are not currently supported:
- * - Delegating IDREF attributes (ex: `aria-labelledby`, `aria-controls`)
- * - Delegating the `role` attribute
- *
- * @example
- * class XButton extends LitElement {
- * static {
- * requestUpdateOnAriaChange(XButton);
- * }
- *
- * protected override render() {
- * return html`
- *
- *
- *
- * `;
- * }
- * }
- *
- * @param ctor The `ReactiveElement` constructor to patch.
- */
-function requestUpdateOnAriaChange(ctor) {
- for (const ariaProperty of ARIA_PROPERTIES) {
- ctor.createProperty(ariaProperty, {
- attribute: ariaPropertyToAttribute(ariaProperty),
- reflect: true,
- });
- }
- ctor.addInitializer((element) => {
- const controller = {
- hostConnected() {
- element.setAttribute('role', 'presentation');
- },
- };
- element.addController(controller);
- });
-}
-
/**
* @license
* Copyright 2021 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
-/**
- * Re-dispatches an event from the provided element.
- *
- * This function is useful for forwarding non-composed events, such as `change`
- * events.
- *
- * @example
- * class MyInput extends LitElement {
- * render() {
- * return html` `;
- * }
- *
- * protected redispatchEvent(event: Event) {
- * redispatchEvent(this, event);
- * }
- * }
- *
- * @param element The element to dispatch the event from.
- * @param event The event to re-dispatch.
- * @return Whether or not the event was dispatched (if cancelable).
- */
-function redispatchEvent(element, event) {
- // For bubbling events in SSR light DOM (or composed), stop their propagation
- // and dispatch the copy.
- if (event.bubbles && (!element.shadowRoot || event.composed)) {
- event.stopPropagation();
- }
- const copy = Reflect.construct(event.constructor, [event.type, event]);
- const dispatched = element.dispatchEvent(copy);
- if (!dispatched) {
- event.preventDefault();
- }
- return dispatched;
-}
-/**
- * Dispatches a click event to the given element that triggers a native action,
- * but is not composed and therefore is not seen outside the element.
- *
- * This is useful for responding to an external click event on the host element
- * that should trigger an internal action like a button click.
- *
- * Note, a helper is provided because setting this up correctly is a bit tricky.
- * In particular, calling `click` on an element creates a composed event, which
- * is not desirable, and a manually dispatched event must specifically be a
- * `MouseEvent` to trigger a native action.
- *
- * @example
- * hostClickListener = (event: MouseEvent) {
- * if (isActivationClick(event)) {
- * this.dispatchActivationClick(this.buttonElement);
- * }
- * }
- *
- */
-function dispatchActivationClick(element) {
- const event = new MouseEvent('click', { bubbles: true });
- element.dispatchEvent(event);
- return event;
-}
-/**
- * Returns true if the click event should trigger an activation behavior. The
- * behavior is defined by the element and is whatever it should do when
- * clicked.
- *
- * Typically when an element needs to handle a click, the click is generated
- * from within the element and an event listener within the element implements
- * the needed behavior; however, it's possible to fire a click directly
- * at the element that the element should handle. This method helps
- * distinguish these "external" clicks.
- *
- * An "external" click can be triggered in a number of ways: via a click
- * on an associated label for a form associated element, calling
- * `element.click()`, or calling
- * `element.dispatchEvent(new MouseEvent('click', ...))`.
- *
- * Also works around Firefox issue
- * https://bugzilla.mozilla.org/show_bug.cgi?id=1804576 by squelching
- * events for a microtask after called.
- *
- * @example
- * hostClickListener = (event: MouseEvent) {
- * if (isActivationClick(event)) {
- * this.dispatchActivationClick(this.buttonElement);
- * }
- * }
- *
- */
-function isActivationClick(event) {
- // Event must start at the event target.
- if (event.currentTarget !== event.target) {
- return false;
- }
- // Event must not be retargeted from shadowRoot.
- if (event.composedPath()[0] !== event.target) {
- return false;
- }
- // Target must not be disabled; this should only occur for a synthetically
- // dispatched click.
- if (event.target.disabled) {
- return false;
- }
- // This is an activation if the event should not be squelched.
- return !squelchEvent(event);
-}
-// TODO(https://bugzilla.mozilla.org/show_bug.cgi?id=1804576)
-// Remove when Firefox bug is addressed.
-function squelchEvent(event) {
- const squelched = isSquelchingEvents;
- if (squelched) {
- event.preventDefault();
- event.stopImmediatePropagation();
- }
- squelchEventsForMicrotask();
- return squelched;
-}
-// Ignore events for one microtask only.
-let isSquelchingEvents = false;
-async function squelchEventsForMicrotask() {
- isSquelchingEvents = true;
- // Need to pause for just one microtask.
- // tslint:disable-next-line
- await null;
- isSquelchingEvents = false;
-}
-
+function dn(t,e){!e.bubbles||t.shadowRoot&&!e.composed||e.stopPropagation();const i=Reflect.construct(e.constructor,[e.type,e]),n=t.dispatchEvent(i);return n||e.preventDefault(),n}function cn(t){return t.currentTarget===t.target&&(t.composedPath()[0]===t.target&&(!t.target.disabled&&!function(t){const e=sn;e&&(t.preventDefault(),t.stopImmediatePropagation());return async function(){sn=!0,await null,sn=!1}
/**
* @license
* Copyright 2023 Google LLC
* SPDX-License-Identifier: Apache-2.0
- */
-/**
- * A unique symbol used for protected access to an instance's
- * `ElementInternals`.
- *
- * @example
- * ```ts
- * class MyElement extends mixinElementInternals(LitElement) {
- * constructor() {
- * super();
- * this[internals].role = 'button';
- * }
- * }
- * ```
- */
-const internals = Symbol('internals');
-// Private symbols
-const privateInternals = Symbol('privateInternals');
-/**
- * Mixes in an attached `ElementInternals` instance.
- *
- * This mixin is only needed when other shared code needs access to a
- * component's `ElementInternals`, such as form-associated mixins.
- *
- * @param base The class to mix functionality into.
- * @return The provided class with `WithElementInternals` mixed in.
- */
-function mixinElementInternals(base) {
- class WithElementInternalsElement extends base {
- get [internals]() {
- // Create internals in getter so that it can be used in methods called on
- // construction in `ReactiveElement`, such as `requestUpdate()`.
- if (!this[privateInternals]) {
- // Cast needed for closure
- this[privateInternals] = this.attachInternals();
- }
- return this[privateInternals];
- }
- }
- return WithElementInternalsElement;
-}
-
+ */(),e}(t)))}ln.map(on);let sn=!1;const mn=Symbol("internals"),hn=Symbol("privateInternals");
/**
* @license
* Copyright 2023 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
-/**
- * A symbol property to retrieve the form value for an element.
- */
-const getFormValue = Symbol('getFormValue');
-/**
- * A symbol property to retrieve the form state for an element.
- */
-const getFormState = Symbol('getFormState');
-/**
- * Mixes in form-associated behavior for a class. This allows an element to add
- * values to `