@fluid-topics/ft-filterable-table 0.2.3 → 0.2.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/ft-filterable-table.inline-styles.js +322 -245
- package/build/ft-filterable-table.light.js +322 -245
- package/build/ft-filterable-table.min.js +314 -237
- package/package.json +6 -6
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
*
|
|
15
15
|
* @see https://github.com/webcomponents/polyfills/tree/master/packages/scoped-custom-element-registry
|
|
16
16
|
*/
|
|
17
|
-
if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,e=window.customElements.define,i=window.customElements.get,o=window.customElements,n=new WeakMap,s=new WeakMap,r=new WeakMap,l=new WeakMap;let a;window.CustomElementRegistry=class{constructor(){this._definitionsByTag=new Map,this._definitionsByClass=new Map,this._whenDefinedPromises=new Map,this._awaitingUpgrade=new Map}define(t,n){if(t=t.toLowerCase(),void 0!==this._getDefinition(t))throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': the name "${t}" has already been used with this registry`);if(void 0!==this._definitionsByClass.get(n))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const l=n.prototype.attributeChangedCallback,a=new Set(n.observedAttributes||[]);
|
|
17
|
+
if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,e=window.customElements.define,i=window.customElements.get,o=window.customElements,n=new WeakMap,s=new WeakMap,r=new WeakMap,l=new WeakMap;let a;window.CustomElementRegistry=class{constructor(){this._definitionsByTag=new Map,this._definitionsByClass=new Map,this._whenDefinedPromises=new Map,this._awaitingUpgrade=new Map}define(t,n){if(t=t.toLowerCase(),void 0!==this._getDefinition(t))throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': the name "${t}" has already been used with this registry`);if(void 0!==this._definitionsByClass.get(n))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const l=n.prototype.attributeChangedCallback,a=new Set(n.observedAttributes||[]);f(n,a,l);const p={elementClass:n,connectedCallback:n.prototype.connectedCallback,disconnectedCallback:n.prototype.disconnectedCallback,adoptedCallback:n.prototype.adoptedCallback,attributeChangedCallback:l,formAssociated:n.formAssociated,formAssociatedCallback:n.prototype.formAssociatedCallback,formDisabledCallback:n.prototype.formDisabledCallback,formResetCallback:n.prototype.formResetCallback,formStateRestoreCallback:n.prototype.formStateRestoreCallback,observedAttributes:a};this._definitionsByTag.set(t,p),this._definitionsByClass.set(n,p);let c=i.call(o,t);c||(c=d(t),e.call(o,t,c)),this===window.customElements&&(r.set(n,p),p.standInClass=c);const h=this._awaitingUpgrade.get(t);if(h){this._awaitingUpgrade.delete(t);for(const t of h)s.delete(t),u(t,p,!0)}const b=this._whenDefinedPromises.get(t);return void 0!==b&&(b.resolve(n),this._whenDefinedPromises.delete(t)),n}upgrade(){x.push(this),o.upgrade.apply(o,arguments),x.pop()}get(t){return this._definitionsByTag.get(t)?.elementClass}_getDefinition(t){return this._definitionsByTag.get(t)}whenDefined(t){const e=this._getDefinition(t);if(void 0!==e)return Promise.resolve(e.elementClass);let i=this._whenDefinedPromises.get(t);return void 0===i&&(i={},i.promise=new Promise((t=>i.resolve=t)),this._whenDefinedPromises.set(t,i)),i.promise}_upgradeWhenDefined(t,e,i){let o=this._awaitingUpgrade.get(e);o||this._awaitingUpgrade.set(e,o=new Set),i?o.add(t):o.delete(t)}},window.HTMLElement=function(){let e=a;if(e)return a=void 0,e;const i=r.get(this.constructor);if(!i)throw new TypeError("Illegal constructor (custom element class must be registered with global customElements registry to be newable)");return e=Reflect.construct(t,[],i.standInClass),Object.setPrototypeOf(e,this.constructor.prototype),n.set(e,i),e},window.HTMLElement.prototype=t.prototype;const p=t=>t===document||t instanceof ShadowRoot,c=t=>{let e=t.getRootNode();if(!p(e)){const t=x[x.length-1];if(t instanceof CustomElementRegistry)return t;e=t.getRootNode(),p(e)||(e=l.get(e)?.getRootNode()||document)}return e.customElements},d=e=>class{static get formAssociated(){return!0}constructor(){const i=Reflect.construct(t,[],this.constructor);Object.setPrototypeOf(i,HTMLElement.prototype);const o=c(i)||window.customElements,n=o._getDefinition(e);return n?u(i,n):s.set(i,o),i}connectedCallback(){const t=n.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):s.get(this)._upgradeWhenDefined(this,e,!0)}disconnectedCallback(){const t=n.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):s.get(this)._upgradeWhenDefined(this,e,!1)}adoptedCallback(){n.get(this)?.adoptedCallback?.apply(this,arguments)}formAssociatedCallback(){const t=n.get(this);t&&t.formAssociated&&t?.formAssociatedCallback?.apply(this,arguments)}formDisabledCallback(){const t=n.get(this);t?.formAssociated&&t?.formDisabledCallback?.apply(this,arguments)}formResetCallback(){const t=n.get(this);t?.formAssociated&&t?.formResetCallback?.apply(this,arguments)}formStateRestoreCallback(){const t=n.get(this);t?.formAssociated&&t?.formStateRestoreCallback?.apply(this,arguments)}},f=(t,e,i)=>{if(0===e.size||void 0===i)return;const o=t.prototype.setAttribute;o&&(t.prototype.setAttribute=function(t,n){const s=t.toLowerCase();if(e.has(s)){const t=this.getAttribute(s);o.call(this,s,n),i.call(this,s,t,n)}else o.call(this,s,n)});const n=t.prototype.removeAttribute;n&&(t.prototype.removeAttribute=function(t){const o=t.toLowerCase();if(e.has(o)){const t=this.getAttribute(o);n.call(this,o),i.call(this,o,t,null)}else n.call(this,o)})},h=e=>{const i=Object.getPrototypeOf(e);if(i!==window.HTMLElement)return i===t||"HTMLElement"===i?.prototype?.constructor?.name?Object.setPrototypeOf(e,window.HTMLElement):h(i)},u=(t,e,i=!1)=>{Object.setPrototypeOf(t,e.elementClass.prototype),n.set(t,e),a=t;try{new e.elementClass}catch(t){h(e.elementClass),new e.elementClass}e.observedAttributes.forEach((i=>{t.hasAttribute(i)&&e.attributeChangedCallback.call(t,i,null,t.getAttribute(i))})),i&&e.connectedCallback&&t.isConnected&&e.connectedCallback.call(t)},b=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const e=b.apply(this,arguments);return t.customElements&&(e.customElements=t.customElements),e};let x=[document];const v=(t,e,i)=>{const o=(i?Object.getPrototypeOf(i):t.prototype)[e];t.prototype[e]=function(){x.push(this);const t=o.apply(i||this,arguments);return void 0!==t&&l.set(t,this),x.pop(),t}};v(ShadowRoot,"createElement",document),v(ShadowRoot,"importNode",document),v(Element,"insertAdjacentHTML");const y=(t,e)=>{const i=Object.getOwnPropertyDescriptor(t.prototype,e);Object.defineProperty(t.prototype,e,{...i,set(t){x.push(this),i.set.call(this,t),x.pop()}})};if(y(Element,"innerHTML"),y(ShadowRoot,"innerHTML"),Object.defineProperty(window,"customElements",{value:new CustomElementRegistry,configurable:!0,writable:!0}),window.ElementInternals&&window.ElementInternals.prototype.setFormValue){const t=new WeakMap,e=HTMLElement.prototype.attachInternals,i=["setFormValue","setValidity","checkValidity","reportValidity"];HTMLElement.prototype.attachInternals=function(...i){const o=e.call(this,...i);return t.set(o,this),o},i.forEach((e=>{const i=window.ElementInternals.prototype,o=i[e];i[e]=function(...e){const i=t.get(this);if(!0!==n.get(i).formAssociated)throw new DOMException(`Failed to execute ${o} on 'ElementInternals': The target element is not a form-associated custom element.`);o?.call(this,...e)}}));class o extends Array{constructor(t){super(...t),this._elements=t}get value(){return this._elements.find((t=>!0===t.checked))?.value||""}}class s{constructor(t){const e=new Map;t.forEach(((t,i)=>{const o=t.getAttribute("name"),n=e.get(o)||[];this[+i]=t,n.push(t),e.set(o,n)})),this.length=t.length,e.forEach(((t,e)=>{t&&(1===t.length?this[e]=t[0]:this[e]=new o(t))}))}namedItem(t){return this[t]}}const r=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get:function(){const t=r.get.call(this,[]),e=[];for(const i of t){const t=n.get(i);t&&!0!==t.formAssociated||e.push(i)}return new s(e)}})}}try{window.customElements.define("custom-element",null)}catch(Tt){const t=window.customElements.define;window.customElements.define=(e,i,o)=>{try{t.bind(window.customElements)(e,i,o)}catch(t){console.warn(e,i,o,t)}}}class e{constructor(t=0){this.timeout=t,this.callbacks=[]}run(t,e){this.callbacks=[t],this.debounce(e)}queue(t,e){this.callbacks.push(t),this.debounce(e)}cancel(){null!=this._debounce&&window.clearTimeout(this._debounce)}debounce(t){this.cancel(),this._debounce=window.setTimeout((()=>this.runCallbacks()),null!=t?t:this.timeout)}runCallbacks(){for(let t of this.callbacks)t();this.callbacks=[]}}
|
|
18
18
|
/**
|
|
19
19
|
* @license
|
|
20
20
|
* Copyright 2017 Google LLC
|
|
@@ -44,24 +44,24 @@ if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,e=window.cust
|
|
|
44
44
|
* @license
|
|
45
45
|
* Copyright 2019 Google LLC
|
|
46
46
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
47
|
-
*/,c=window.ShadowRoot&&(void 0===window.ShadyCSS||window.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,d=Symbol(),
|
|
47
|
+
*/,c=window.ShadowRoot&&(void 0===window.ShadyCSS||window.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,d=Symbol(),f=new Map;class h{constructor(t,e){if(this._$cssResult$=!0,e!==d)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t}get styleSheet(){let t=f.get(this.cssText);return c&&void 0===t&&(f.set(this.cssText,t=new CSSStyleSheet),t.replaceSync(this.cssText)),t}toString(){return this.cssText}}const u=t=>new h("string"==typeof t?t:t+"",d),b=(t,...e)=>{const i=1===t.length?t[0]:e.reduce(((e,i,o)=>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[o+1]),t[0]);return new h(i,d)},x=(t,e)=>{c?t.adoptedStyleSheets=e.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet)):e.forEach((e=>{const i=document.createElement("style"),o=window.litNonce;void 0!==o&&i.setAttribute("nonce",o),i.textContent=e.cssText,t.appendChild(i)}))},v=c?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return u(e)})(t):t
|
|
48
48
|
/**
|
|
49
49
|
* @license
|
|
50
50
|
* Copyright 2017 Google LLC
|
|
51
51
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
52
|
-
*/;var y;const g=window.trustedTypes,m=g?g.emptyScript:"",$=window.reactiveElementPolyfillSupport,w={toAttribute(t,e){switch(e){case Boolean:t=t?m: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}},O=(t,e)=>e!==t&&(e==e||t==t),S={attribute:!0,type:String,converter:w,reflect:!1,hasChanged:O};class k extends HTMLElement{constructor(){super(),this._$Et=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Ei=null,this.o()}static addInitializer(t){var e;null!==(e=this.l)&&void 0!==e||(this.l=[]),this.l.push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((e,i)=>{const o=this._$Eh(i,e);void 0!==o&&(this._$Eu.set(o,i),t.push(o))})),t}static createProperty(t,e=S){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,o=this.getPropertyDescriptor(t,i,e);void 0!==o&&Object.defineProperty(this.prototype,t,o)}}static getPropertyDescriptor(t,e,i){return{get(){return this[e]},set(o){const n=this[t];this[e]=o,this.requestUpdate(t,n,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||S}static finalize(){if(this.hasOwnProperty("finalized"))return!1;this.finalized=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),this.elementProperties=new Map(t.elementProperties),this._$Eu=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(v(t))}else void 0!==t&&e.push(v(t));return e}static _$Eh(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}o(){var t;this._$Ep=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Em(),this.requestUpdate(),null===(t=this.constructor.l)||void 0===t||t.forEach((t=>t(this)))}addController(t){var e,i;(null!==(e=this._$Eg)&&void 0!==e?e:this._$Eg=[]).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._$Eg)||void 0===e||e.splice(this._$Eg.indexOf(t)>>>0,1)}_$Em(){this.constructor.elementProperties.forEach(((t,e)=>{this.hasOwnProperty(e)&&(this._$Et.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 x(e,this.constructor.elementStyles),e}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$Eg)||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._$Eg)||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)}_$ES(t,e,i=S){var o,n;const s=this.constructor._$Eh(t,i);if(void 0!==s&&!0===i.reflect){const r=(null!==(n=null===(o=i.converter)||void 0===o?void 0:o.toAttribute)&&void 0!==n?n:w.toAttribute)(e,i.type);this._$Ei=t,null==r?this.removeAttribute(s):this.setAttribute(s,r),this._$Ei=null}}_$AK(t,e){var i,o,n;const s=this.constructor,r=s._$Eu.get(t);if(void 0!==r&&this._$Ei!==r){const t=s.getPropertyOptions(r),l=t.converter,a=null!==(n=null!==(o=null===(i=l)||void 0===i?void 0:i.fromAttribute)&&void 0!==o?o:"function"==typeof l?l:null)&&void 0!==n?n:w.fromAttribute;this._$Ei=r,this[r]=a(e,t.type),this._$Ei=null}}requestUpdate(t,e,i){let o=!0;void 0!==t&&(((i=i||this.constructor.getPropertyOptions(t)).hasChanged||O)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),!0===i.reflect&&this._$Ei!==t&&(void 0===this._$
|
|
52
|
+
*/;var y;const g=window.trustedTypes,m=g?g.emptyScript:"",$=window.reactiveElementPolyfillSupport,w={toAttribute(t,e){switch(e){case Boolean:t=t?m: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}},O=(t,e)=>e!==t&&(e==e||t==t),S={attribute:!0,type:String,converter:w,reflect:!1,hasChanged:O};class k extends HTMLElement{constructor(){super(),this._$Et=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Ei=null,this.o()}static addInitializer(t){var e;null!==(e=this.l)&&void 0!==e||(this.l=[]),this.l.push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((e,i)=>{const o=this._$Eh(i,e);void 0!==o&&(this._$Eu.set(o,i),t.push(o))})),t}static createProperty(t,e=S){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,o=this.getPropertyDescriptor(t,i,e);void 0!==o&&Object.defineProperty(this.prototype,t,o)}}static getPropertyDescriptor(t,e,i){return{get(){return this[e]},set(o){const n=this[t];this[e]=o,this.requestUpdate(t,n,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||S}static finalize(){if(this.hasOwnProperty("finalized"))return!1;this.finalized=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),this.elementProperties=new Map(t.elementProperties),this._$Eu=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(v(t))}else void 0!==t&&e.push(v(t));return e}static _$Eh(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}o(){var t;this._$Ep=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Em(),this.requestUpdate(),null===(t=this.constructor.l)||void 0===t||t.forEach((t=>t(this)))}addController(t){var e,i;(null!==(e=this._$Eg)&&void 0!==e?e:this._$Eg=[]).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._$Eg)||void 0===e||e.splice(this._$Eg.indexOf(t)>>>0,1)}_$Em(){this.constructor.elementProperties.forEach(((t,e)=>{this.hasOwnProperty(e)&&(this._$Et.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 x(e,this.constructor.elementStyles),e}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$Eg)||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._$Eg)||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)}_$ES(t,e,i=S){var o,n;const s=this.constructor._$Eh(t,i);if(void 0!==s&&!0===i.reflect){const r=(null!==(n=null===(o=i.converter)||void 0===o?void 0:o.toAttribute)&&void 0!==n?n:w.toAttribute)(e,i.type);this._$Ei=t,null==r?this.removeAttribute(s):this.setAttribute(s,r),this._$Ei=null}}_$AK(t,e){var i,o,n;const s=this.constructor,r=s._$Eu.get(t);if(void 0!==r&&this._$Ei!==r){const t=s.getPropertyOptions(r),l=t.converter,a=null!==(n=null!==(o=null===(i=l)||void 0===i?void 0:i.fromAttribute)&&void 0!==o?o:"function"==typeof l?l:null)&&void 0!==n?n:w.fromAttribute;this._$Ei=r,this[r]=a(e,t.type),this._$Ei=null}}requestUpdate(t,e,i){let o=!0;void 0!==t&&(((i=i||this.constructor.getPropertyOptions(t)).hasChanged||O)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),!0===i.reflect&&this._$Ei!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,i))):o=!1),!this.isUpdatePending&&o&&(this._$Ep=this._$E_())}async _$E_(){this.isUpdatePending=!0;try{await this._$Ep}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._$Et&&(this._$Et.forEach(((t,e)=>this[e]=t)),this._$Et=void 0);let e=!1;const i=this._$AL;try{e=this.shouldUpdate(i),e?(this.willUpdate(i),null===(t=this._$Eg)||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._$EU()}catch(t){throw e=!1,this._$EU(),t}e&&this._$AE(i)}willUpdate(t){}_$AE(t){var e;null===(e=this._$Eg)||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)}_$EU(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$Ep}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,e)=>this._$ES(e,this[e],t))),this._$EC=void 0),this._$EU()}updated(t){}firstUpdated(t){}}
|
|
53
53
|
/**
|
|
54
54
|
* @license
|
|
55
55
|
* Copyright 2017 Google LLC
|
|
56
56
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
57
57
|
*/
|
|
58
|
-
var C;k.finalized=!0,k.elementProperties=new Map,k.elementStyles=[],k.shadowRootOptions={mode:"open"},null==$||$({ReactiveElement:k}),(null!==(y=globalThis.reactiveElementVersions)&&void 0!==y?y:globalThis.reactiveElementVersions=[]).push("1.
|
|
58
|
+
var C;k.finalized=!0,k.elementProperties=new Map,k.elementStyles=[],k.shadowRootOptions={mode:"open"},null==$||$({ReactiveElement:k}),(null!==(y=globalThis.reactiveElementVersions)&&void 0!==y?y:globalThis.reactiveElementVersions=[]).push("1.3.2");const E=globalThis.trustedTypes,N=E?E.createPolicy("lit-html",{createHTML:t=>t}):void 0,R=`lit$${(Math.random()+"").slice(9)}$`,z="?"+R,M=`<${z}>`,F=document,U=(t="")=>F.createComment(t),B=t=>null===t||"object"!=typeof t&&"function"!=typeof t,D=Array.isArray,j=t=>{var e;return D(t)||"function"==typeof(null===(e=t)||void 0===e?void 0:e[Symbol.iterator])},T=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,L=/-->/g,A=/>/g,I=/>|[ \n\r](?:([^\s"'>=/]+)([ \n\r]*=[ \n\r]*(?:[^ \n\r"'`<>=]|("|')|))|$)/g,_=/'/g,P=/"/g,H=/^(?:script|style|textarea|title)$/i,W=(t=>(e,...i)=>({_$litType$:t,strings:e,values:i}))(1),Z=Symbol.for("lit-noChange"),K=Symbol.for("lit-nothing"),V=new WeakMap,q=F.createTreeWalker(F,129,null,!1),X=(t,e)=>{const i=t.length-1,o=[];let n,s=2===e?"<svg>":"",r=T;for(let e=0;e<i;e++){const i=t[e];let l,a,p=-1,c=0;for(;c<i.length&&(r.lastIndex=c,a=r.exec(i),null!==a);)c=r.lastIndex,r===T?"!--"===a[1]?r=L:void 0!==a[1]?r=A:void 0!==a[2]?(H.test(a[2])&&(n=RegExp("</"+a[2],"g")),r=I):void 0!==a[3]&&(r=I):r===I?">"===a[0]?(r=null!=n?n:T,p=-1):void 0===a[1]?p=-2:(p=r.lastIndex-a[2].length,l=a[1],r=void 0===a[3]?I:'"'===a[3]?P:_):r===P||r===_?r=I:r===L||r===A?r=T:(r=I,n=void 0);const d=r===I&&t[e+1].startsWith("/>")?" ":"";s+=r===T?i+M:p>=0?(o.push(l),i.slice(0,p)+"$lit$"+i.slice(p)+R+d):i+R+(-2===p?(o.push(void 0),e):d)}const l=s+(t[i]||"<?>")+(2===e?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==N?N.createHTML(l):l,o]};class J{constructor({strings:t,_$litType$:e},i){let o;this.parts=[];let n=0,s=0;const r=t.length-1,l=this.parts,[a,p]=X(t,e);if(this.el=J.createElement(a,i),q.currentNode=this.el.content,2===e){const t=this.el.content,e=t.firstChild;e.remove(),t.append(...e.childNodes)}for(;null!==(o=q.nextNode())&&l.length<r;){if(1===o.nodeType){if(o.hasAttributes()){const t=[];for(const e of o.getAttributeNames())if(e.endsWith("$lit$")||e.startsWith(R)){const i=p[s++];if(t.push(e),void 0!==i){const t=o.getAttribute(i.toLowerCase()+"$lit$").split(R),e=/([.?@])?(.*)/.exec(i);l.push({type:1,index:n,name:e[2],strings:t,ctor:"."===e[1]?et:"?"===e[1]?ot:"@"===e[1]?nt:tt})}else l.push({type:6,index:n})}for(const e of t)o.removeAttribute(e)}if(H.test(o.tagName)){const t=o.textContent.split(R),e=t.length-1;if(e>0){o.textContent=E?E.emptyScript:"";for(let i=0;i<e;i++)o.append(t[i],U()),q.nextNode(),l.push({type:2,index:++n});o.append(t[e],U())}}}else if(8===o.nodeType)if(o.data===z)l.push({type:2,index:n});else{let t=-1;for(;-1!==(t=o.data.indexOf(R,t+1));)l.push({type:7,index:n}),t+=R.length-1}n++}}static createElement(t,e){const i=F.createElement("template");return i.innerHTML=t,i}}function Y(t,e,i=t,o){var n,s,r,l;if(e===Z)return e;let a=void 0!==o?null===(n=i._$Cl)||void 0===n?void 0:n[o]:i._$Cu;const p=B(e)?void 0:e._$litDirective$;return(null==a?void 0:a.constructor)!==p&&(null===(s=null==a?void 0:a._$AO)||void 0===s||s.call(a,!1),void 0===p?a=void 0:(a=new p(t),a._$AT(t,i,o)),void 0!==o?(null!==(r=(l=i)._$Cl)&&void 0!==r?r:l._$Cl=[])[o]=a:i._$Cu=a),void 0!==a&&(e=Y(t,a._$AS(t,e.values),a,o)),e}class G{constructor(t,e){this.v=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}p(t){var e;const{el:{content:i},parts:o}=this._$AD,n=(null!==(e=null==t?void 0:t.creationScope)&&void 0!==e?e:F).importNode(i,!0);q.currentNode=n;let s=q.nextNode(),r=0,l=0,a=o[0];for(;void 0!==a;){if(r===a.index){let e;2===a.type?e=new Q(s,s.nextSibling,this,t):1===a.type?e=new a.ctor(s,a.name,a.strings,this,t):6===a.type&&(e=new st(s,this,t)),this.v.push(e),a=o[++l]}r!==(null==a?void 0:a.index)&&(s=q.nextNode(),r++)}return n}m(t){let e=0;for(const i of this.v)void 0!==i&&(void 0!==i.strings?(i._$AI(t,i,e),e+=i.strings.length-2):i._$AI(t[e])),e++}}class Q{constructor(t,e,i,o){var n;this.type=2,this._$AH=K,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=o,this._$Cg=null===(n=null==o?void 0:o.isConnected)||void 0===n||n}get _$AU(){var t,e;return null!==(e=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==e?e:this._$Cg}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=Y(this,t,e),B(t)?t===K||null==t||""===t?(this._$AH!==K&&this._$AR(),this._$AH=K):t!==this._$AH&&t!==Z&&this.$(t):void 0!==t._$litType$?this.T(t):void 0!==t.nodeType?this.k(t):j(t)?this.S(t):this.$(t)}M(t,e=this._$AB){return this._$AA.parentNode.insertBefore(t,e)}k(t){this._$AH!==t&&(this._$AR(),this._$AH=this.M(t))}$(t){this._$AH!==K&&B(this._$AH)?this._$AA.nextSibling.data=t:this.k(F.createTextNode(t)),this._$AH=t}T(t){var e;const{values:i,_$litType$:o}=t,n="number"==typeof o?this._$AC(t):(void 0===o.el&&(o.el=J.createElement(o.h,this.options)),o);if((null===(e=this._$AH)||void 0===e?void 0:e._$AD)===n)this._$AH.m(i);else{const t=new G(n,this),e=t.p(this.options);t.m(i),this.k(e),this._$AH=t}}_$AC(t){let e=V.get(t.strings);return void 0===e&&V.set(t.strings,e=new J(t)),e}S(t){D(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,o=0;for(const n of t)o===e.length?e.push(i=new Q(this.M(U()),this.M(U()),this,this.options)):i=e[o],i._$AI(n),o++;o<e.length&&(this._$AR(i&&i._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){var i;for(null===(i=this._$AP)||void 0===i||i.call(this,!1,!0,e);t&&t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){var e;void 0===this._$AM&&(this._$Cg=t,null===(e=this._$AP)||void 0===e||e.call(this,t))}}class tt{constructor(t,e,i,o,n){this.type=1,this._$AH=K,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=n,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=K}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,i,o){const n=this.strings;let s=!1;if(void 0===n)t=Y(this,t,e,0),s=!B(t)||t!==this._$AH&&t!==Z,s&&(this._$AH=t);else{const o=t;let r,l;for(t=n[0],r=0;r<n.length-1;r++)l=Y(this,o[i+r],e,r),l===Z&&(l=this._$AH[r]),s||(s=!B(l)||l!==this._$AH[r]),l===K?t=K:t!==K&&(t+=(null!=l?l:"")+n[r+1]),this._$AH[r]=l}s&&!o&&this.C(t)}C(t){t===K?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class et extends tt{constructor(){super(...arguments),this.type=3}C(t){this.element[this.name]=t===K?void 0:t}}const it=E?E.emptyScript:"";class ot extends tt{constructor(){super(...arguments),this.type=4}C(t){t&&t!==K?this.element.setAttribute(this.name,it):this.element.removeAttribute(this.name)}}class nt extends tt{constructor(t,e,i,o,n){super(t,e,i,o,n),this.type=5}_$AI(t,e=this){var i;if((t=null!==(i=Y(this,t,e,0))&&void 0!==i?i:K)===Z)return;const o=this._$AH,n=t===K&&o!==K||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,s=t!==K&&(o===K||n);n&&this.element.removeEventListener(this.name,this,o),s&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,i;"function"==typeof this._$AH?this._$AH.call(null!==(i=null===(e=this.options)||void 0===e?void 0:e.host)&&void 0!==i?i:this.element,t):this._$AH.handleEvent(t)}}class st{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){Y(this,t)}}const rt={L:"$lit$",P:R,V:z,I:1,N:X,R:G,j,D:Y,H:Q,F:tt,O:ot,W:nt,B:et,Z:st},lt=window.litHtmlPolyfillSupport;
|
|
59
59
|
/**
|
|
60
60
|
* @license
|
|
61
61
|
* Copyright 2017 Google LLC
|
|
62
62
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
63
63
|
*/
|
|
64
|
-
var at,pt;null==lt||lt(J,Q),(null!==(C=globalThis.litHtmlVersions)&&void 0!==C?C:globalThis.litHtmlVersions=[]).push("2.
|
|
64
|
+
var at,pt;null==lt||lt(J,Q),(null!==(C=globalThis.litHtmlVersions)&&void 0!==C?C:globalThis.litHtmlVersions=[]).push("2.2.4");class ct extends k{constructor(){super(...arguments),this.renderOptions={host:this},this._$Dt=void 0}createRenderRoot(){var t,e;const i=super.createRenderRoot();return null!==(t=(e=this.renderOptions).renderBefore)&&void 0!==t||(e.renderBefore=i.firstChild),i}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Dt=((t,e,i)=>{var o,n;const s=null!==(o=null==i?void 0:i.renderBefore)&&void 0!==o?o:e;let r=s._$litPart$;if(void 0===r){const t=null!==(n=null==i?void 0:i.renderBefore)&&void 0!==n?n:null;s._$litPart$=r=new Q(e.insertBefore(U(),t),t,void 0,null!=i?i:{})}return r._$AI(t),r})(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Dt)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Dt)||void 0===t||t.setConnected(!1)}render(){return Z}}ct.finalized=!0,ct._$litElement$=!0,null===(at=globalThis.litElementHydrateSupport)||void 0===at||at.call(globalThis,{LitElement:ct});const dt=globalThis.litElementPolyfillSupport;null==dt||dt({LitElement:ct}),(null!==(pt=globalThis.litElementVersions)&&void 0!==pt?pt:globalThis.litElementVersions=[]).push("3.2.0");class ft{constructor(t,e,i,o,n){this.name=t,this.category=e,this.fallbackVariable=i,this.defaultValue=o,this.context=n,this._$cssResult$=!0,this.value=this.get()}get cssText(){return this.value.cssText}get styleSheet(){return this.value.styleSheet}toString(){return this.value.toString()}static create(t,e,i){return new ft(t,e,void 0,i)}static extend(t,e,i){return new ft(t,e.category,e,i)}static external(t,e){return new ft(t.name,t.category,t.fallbackVariable,t.defaultValue,e)}get(t){return b`var(${u(this.name)}, ${this.defaultCssValue(t)})`}defaultCssValue(t){return this.fallbackVariable?this.fallbackVariable.get(null!=t?t:this.defaultValue):u(null!=t?t:this.defaultValue)}lastResortDefaultValue(){var t,e;return null!==(t=this.defaultValue)&&void 0!==t?t:null===(e=this.fallbackVariable)||void 0===e?void 0:e.lastResortDefaultValue()}breadcrumb(){return this.fallbackVariable?[this.fallbackVariable.name,...this.fallbackVariable.breadcrumb()]:[]}}function ht(t,e){return u(`${t.name}: ${e}`)}const ut={colorPrimary:ft.create("--ft-color-primary","COLOR","#2196F3"),colorPrimaryVariant:ft.create("--ft-color-primary-variant","COLOR","#1976D2"),colorSecondary:ft.create("--ft-color-secondary","COLOR","#FFCC80"),colorSecondaryVariant:ft.create("--ft-color-secondary-variant","COLOR","#F57C00"),colorSurface:ft.create("--ft-color-surface","COLOR","#FFFFFF"),colorContent:ft.create("--ft-color-content","COLOR","rgba(0, 0, 0, 0.87)"),colorError:ft.create("--ft-color-error","COLOR","#B00020"),colorOutline:ft.create("--ft-color-outline","COLOR","rgba(0, 0, 0, 0.14)"),colorOpacityHigh:ft.create("--ft-color-opacity-high","NUMBER","1"),colorOpacityMedium:ft.create("--ft-color-opacity-medium","NUMBER","0.74"),colorOpacityDisabled:ft.create("--ft-color-opacity-disabled","NUMBER","0.38"),colorOnPrimary:ft.create("--ft-color-on-primary","COLOR","#FFFFFF"),colorOnPrimaryHigh:ft.create("--ft-color-on-primary-high","COLOR","#FFFFFF"),colorOnPrimaryMedium:ft.create("--ft-color-on-primary-medium","COLOR","rgba(255, 255, 255, 0.74)"),colorOnPrimaryDisabled:ft.create("--ft-color-on-primary-disabled","COLOR","rgba(255, 255, 255, 0.38)"),colorOnSecondary:ft.create("--ft-color-on-secondary","COLOR","#FFFFFF"),colorOnSecondaryHigh:ft.create("--ft-color-on-secondary-high","COLOR","#FFFFFF"),colorOnSecondaryMedium:ft.create("--ft-color-on-secondary-medium","COLOR","rgba(255, 255, 255, 0.74)"),colorOnSecondaryDisabled:ft.create("--ft-color-on-secondary-disabled","COLOR","rgba(255, 255, 255, 0.38)"),colorOnSurface:ft.create("--ft-color-on-surface","COLOR","rgba(0, 0, 0, 0.87)"),colorOnSurfaceHigh:ft.create("--ft-color-on-surface-high","COLOR","rgba(0, 0, 0, 0.87)"),colorOnSurfaceMedium:ft.create("--ft-color-on-surface-medium","COLOR","rgba(0, 0, 0, 0.60)"),colorOnSurfaceDisabled:ft.create("--ft-color-on-surface-disabled","COLOR","rgba(0, 0, 0, 0.38)"),opacityContentOnSurfaceDisabled:ft.create("--ft-opacity-content-on-surface-disabled","NUMBER","0"),opacityContentOnSurfaceEnable:ft.create("--ft-opacity-content-on-surface-enable","NUMBER","0"),opacityContentOnSurfaceHover:ft.create("--ft-opacity-content-on-surface-hover","NUMBER","0.04"),opacityContentOnSurfaceFocused:ft.create("--ft-opacity-content-on-surface-focused","NUMBER","0.12"),opacityContentOnSurfacePressed:ft.create("--ft-opacity-content-on-surface-pressed","NUMBER","0.10"),opacityContentOnSurfaceSelected:ft.create("--ft-opacity-content-on-surface-selected","NUMBER","0.08"),opacityContentOnSurfaceDragged:ft.create("--ft-opacity-content-on-surface-dragged","NUMBER","0.08"),opacityPrimaryOnSurfaceDisabled:ft.create("--ft-opacity-primary-on-surface-disabled","NUMBER","0"),opacityPrimaryOnSurfaceEnable:ft.create("--ft-opacity-primary-on-surface-enable","NUMBER","0"),opacityPrimaryOnSurfaceHover:ft.create("--ft-opacity-primary-on-surface-hover","NUMBER","0.04"),opacityPrimaryOnSurfaceFocused:ft.create("--ft-opacity-primary-on-surface-focused","NUMBER","0.12"),opacityPrimaryOnSurfacePressed:ft.create("--ft-opacity-primary-on-surface-pressed","NUMBER","0.10"),opacityPrimaryOnSurfaceSelected:ft.create("--ft-opacity-primary-on-surface-selected","NUMBER","0.08"),opacityPrimaryOnSurfaceDragged:ft.create("--ft-opacity-primary-on-surface-dragged","NUMBER","0.08"),opacitySurfaceOnPrimaryDisabled:ft.create("--ft-opacity-surface-on-primary-disabled","NUMBER","0"),opacitySurfaceOnPrimaryEnable:ft.create("--ft-opacity-surface-on-primary-enable","NUMBER","0"),opacitySurfaceOnPrimaryHover:ft.create("--ft-opacity-surface-on-primary-hover","NUMBER","0.04"),opacitySurfaceOnPrimaryFocused:ft.create("--ft-opacity-surface-on-primary-focused","NUMBER","0.12"),opacitySurfaceOnPrimaryPressed:ft.create("--ft-opacity-surface-on-primary-pressed","NUMBER","0.10"),opacitySurfaceOnPrimarySelected:ft.create("--ft-opacity-surface-on-primary-selected","NUMBER","0.08"),opacitySurfaceOnPrimaryDragged:ft.create("--ft-opacity-surface-on-primary-dragged","NUMBER","0.08"),elevation00:ft.create("--ft-elevation-00","UNKNOWN","0px 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px 0px rgba(0, 0, 0, 0)"),elevation01:ft.create("--ft-elevation-01","UNKNOWN","0px 1px 4px 0px rgba(0, 0, 0, 0.06), 0px 1px 2px 0px rgba(0, 0, 0, 0.14), 0px 0px 1px 0px rgba(0, 0, 0, 0.06)"),elevation02:ft.create("--ft-elevation-02","UNKNOWN","0px 4px 10px 0px rgba(0, 0, 0, 0.06), 0px 2px 5px 0px rgba(0, 0, 0, 0.14), 0px 0px 1px 0px rgba(0, 0, 0, 0.06)"),elevation03:ft.create("--ft-elevation-03","UNKNOWN","0px 6px 13px 0px rgba(0, 0, 0, 0.06), 0px 3px 7px 0px rgba(0, 0, 0, 0.14), 0px 1px 2px 0px rgba(0, 0, 0, 0.06)"),elevation04:ft.create("--ft-elevation-04","UNKNOWN","0px 8px 16px 0px rgba(0, 0, 0, 0.06), 0px 4px 9px 0px rgba(0, 0, 0, 0.14), 0px 2px 3px 0px rgba(0, 0, 0, 0.06)"),elevation06:ft.create("--ft-elevation-06","UNKNOWN","0px 12px 22px 0px rgba(0, 0, 0, 0.06), 0px 6px 13px 0px rgba(0, 0, 0, 0.14), 0px 4px 5px 0px rgba(0, 0, 0, 0.06)"),elevation08:ft.create("--ft-elevation-08","UNKNOWN","0px 16px 28px 0px rgba(0, 0, 0, 0.06), 0px 8px 17px 0px rgba(0, 0, 0, 0.14), 0px 6px 7px 0px rgba(0, 0, 0, 0.06)"),elevation12:ft.create("--ft-elevation-12","UNKNOWN","0px 22px 40px 0px rgba(0, 0, 0, 0.06), 0px 12px 23px 0px rgba(0, 0, 0, 0.14), 0px 10px 11px 0px rgba(0, 0, 0, 0.06)"),elevation16:ft.create("--ft-elevation-16","UNKNOWN","0px 28px 52px 0px rgba(0, 0, 0, 0.06), 0px 16px 29px 0px rgba(0, 0, 0, 0.14), 0px 14px 15px 0px rgba(0, 0, 0, 0.06)"),elevation24:ft.create("--ft-elevation-24","UNKNOWN","0px 40px 76px 0px rgba(0, 0, 0, 0.06), 0px 24px 41px 0px rgba(0, 0, 0, 0.14), 0px 22px 23px 0px rgba(0, 0, 0, 0.06)"),borderRadiusS:ft.create("--ft-border-radius-S","SIZE","4px"),borderRadiusM:ft.create("--ft-border-radius-M","SIZE","8px"),borderRadiusL:ft.create("--ft-border-radius-L","SIZE","12px"),borderRadiusXL:ft.create("--ft-border-radius-XL","SIZE","16px"),titleFont:ft.create("--ft-title-font","UNKNOWN","Ubuntu, system-ui, sans-serif"),contentFont:ft.create("--ft-content-font","UNKNOWN","'Open Sans', system-ui, sans-serif"),transitionDuration:ft.create("--ft-transition-duration","UNKNOWN","250ms"),transitionTimingFunction:ft.create("--ft-transition-timing-function","UNKNOWN","ease-in-out")};
|
|
65
65
|
/**
|
|
66
66
|
* @license
|
|
67
67
|
* Copyright 2021 Google LLC
|
|
@@ -90,7 +90,7 @@ var at,pt;null==lt||lt(J,Q),(null!==(C=globalThis.litHtmlVersions)&&void 0!==C?C
|
|
|
90
90
|
* @license
|
|
91
91
|
* Copyright 2020 Google LLC
|
|
92
92
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
93
|
-
*/const{H:kt}=rt,Ct=()=>document.createComment(""),Et=(t,e,i)=>{var o;const n=t._$AA.parentNode,s=void 0===e?t._$AB:e._$AA;if(void 0===i){const e=n.insertBefore(Ct(),s),o=n.insertBefore(Ct(),s);i=new kt(e,o,t,t.options)}else{const e=i._$AB.nextSibling,r=i._$AM,l=r!==t;if(l){let e;null===(o=i._$AQ)||void 0===o||o.call(i,t),i._$AM=t,void 0!==i._$AP&&(e=t._$AU)!==r._$AU&&i._$AP(e)}if(e!==s||l){let t=i._$AA;for(;t!==e;){const e=t.nextSibling;n.insertBefore(t,s),t=e}}}return i},Nt=(t,e,i=t)=>(t._$AI(e,i),t),Rt={},zt=t=>{var e;null===(e=t._$AP)||void 0===e||e.call(t,!1,!0);let i=t._$AA;const o=t._$AB.nextSibling;for(;i!==o;){const t=i.nextSibling;i.remove(),i=t}},Mt=(t,e,i)=>{const o=new Map;for(let n=e;n<=i;n++)o.set(t[n],n);return o},Ft=Ot(class extends St{constructor(t){if(super(t),t.type!==wt)throw Error("repeat() can only be used in text expressions")}dt(t,e,i){let o;void 0===i?i=e:void 0!==e&&(o=e);const n=[],s=[];let r=0;for(const e of t)n[r]=o?o(e,r):r,s[r]=i(e,r),r++;return{values:s,keys:n}}render(t,e,i){return this.dt(t,e,i).values}update(t,[e,i,o]){var n;const s=(t=>t._$AH)(t),{values:r,keys:l}=this.dt(e,i,o);if(!Array.isArray(s))return this.
|
|
93
|
+
*/const{H:kt}=rt,Ct=()=>document.createComment(""),Et=(t,e,i)=>{var o;const n=t._$AA.parentNode,s=void 0===e?t._$AB:e._$AA;if(void 0===i){const e=n.insertBefore(Ct(),s),o=n.insertBefore(Ct(),s);i=new kt(e,o,t,t.options)}else{const e=i._$AB.nextSibling,r=i._$AM,l=r!==t;if(l){let e;null===(o=i._$AQ)||void 0===o||o.call(i,t),i._$AM=t,void 0!==i._$AP&&(e=t._$AU)!==r._$AU&&i._$AP(e)}if(e!==s||l){let t=i._$AA;for(;t!==e;){const e=t.nextSibling;n.insertBefore(t,s),t=e}}}return i},Nt=(t,e,i=t)=>(t._$AI(e,i),t),Rt={},zt=t=>{var e;null===(e=t._$AP)||void 0===e||e.call(t,!1,!0);let i=t._$AA;const o=t._$AB.nextSibling;for(;i!==o;){const t=i.nextSibling;i.remove(),i=t}},Mt=(t,e,i)=>{const o=new Map;for(let n=e;n<=i;n++)o.set(t[n],n);return o},Ft=Ot(class extends St{constructor(t){if(super(t),t.type!==wt)throw Error("repeat() can only be used in text expressions")}dt(t,e,i){let o;void 0===i?i=e:void 0!==e&&(o=e);const n=[],s=[];let r=0;for(const e of t)n[r]=o?o(e,r):r,s[r]=i(e,r),r++;return{values:s,keys:n}}render(t,e,i){return this.dt(t,e,i).values}update(t,[e,i,o]){var n;const s=(t=>t._$AH)(t),{values:r,keys:l}=this.dt(e,i,o);if(!Array.isArray(s))return this.ut=l,r;const a=null!==(n=this.ut)&&void 0!==n?n:this.ut=[],p=[];let c,d,f=0,h=s.length-1,u=0,b=r.length-1;for(;f<=h&&u<=b;)if(null===s[f])f++;else if(null===s[h])h--;else if(a[f]===l[u])p[u]=Nt(s[f],r[u]),f++,u++;else if(a[h]===l[b])p[b]=Nt(s[h],r[b]),h--,b--;else if(a[f]===l[b])p[b]=Nt(s[f],r[b]),Et(t,p[b+1],s[f]),f++,b--;else if(a[h]===l[u])p[u]=Nt(s[h],r[u]),Et(t,s[f],s[h]),h--,u++;else if(void 0===c&&(c=Mt(l,u,b),d=Mt(a,f,h)),c.has(a[f]))if(c.has(a[h])){const e=d.get(l[u]),i=void 0!==e?s[e]:null;if(null===i){const e=Et(t,s[f]);Nt(e,r[u]),p[u]=e}else p[u]=Nt(i,r[u]),Et(t,s[f],i),s[e]=null;u++}else zt(s[h]),h--;else zt(s[f]),f++;for(;u<=b;){const e=Et(t,p[b+1]);Nt(e,r[u]),p[u++]=e}for(;f<=h;){const t=s[f++];null!==t&&zt(t)}return this.ut=l,((t,e=Rt)=>{t._$AH=e})(t,p),Z}});
|
|
94
94
|
/**
|
|
95
95
|
* @license
|
|
96
96
|
* Copyright 2017 Google LLC
|
|
@@ -101,114 +101,114 @@ var at,pt;null==lt||lt(J,Q),(null!==(C=globalThis.litHtmlVersions)&&void 0!==C?C
|
|
|
101
101
|
* Copyright 2017 Google LLC
|
|
102
102
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
103
103
|
*/
|
|
104
|
-
class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===K||null==t)return this.
|
|
104
|
+
class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===K||null==t)return this.ft=void 0,this.it=t;if(t===Z)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this.ft;this.it=t;const e=[t];return e.raw=e,this.ft={_$litType$:this.constructor.resultType,strings:e,values:[]}}}Ut.directiveName="unsafeHTML",Ut.resultType=1;const Bt=Ot(Ut),Dt=Ot(class extends St{constructor(t){var e;if(super(t),t.type!==$t||"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,o;if(void 0===this.et){this.et=new Set,void 0!==t.strings&&(this.st=new Set(t.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in e)e[t]&&!(null===(i=this.st)||void 0===i?void 0:i.has(t))&&this.et.add(t);return this.render(e)}const n=t.element.classList;this.et.forEach((t=>{t in e||(n.remove(t),this.et.delete(t))}));for(const t in e){const i=!!e[t];i===this.et.has(t)||(null===(o=this.st)||void 0===o?void 0:o.has(t))||(i?(n.add(t),this.et.add(t)):(n.remove(t),this.et.delete(t)))}return Z}}),jt=Symbol.for(""),Tt=t=>{var e,i;if((null===(e=t)||void 0===e?void 0:e.r)===jt)return null===(i=t)||void 0===i?void 0:i._$litStatic$},Lt=t=>({_$litStatic$:t,r:jt}),At=new Map,It=(t=>(e,...i)=>{const o=i.length;let n,s;const r=[],l=[];let a,p=0,c=!1;for(;p<o;){for(a=e[p];p<o&&void 0!==(s=i[p],n=Tt(s));)a+=n+e[++p],c=!0;l.push(s),r.push(a),p++}if(p===o&&r.push(e[o]),c){const t=r.join("$$lit$$");void 0===(e=At.get(t))&&(r.raw=r,At.set(t,e=r)),i=l}return t(e,...i)})(W);
|
|
105
105
|
/**
|
|
106
106
|
* @license
|
|
107
107
|
* Copyright 2018 Google LLC
|
|
108
108
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
109
|
-
*/var
|
|
109
|
+
*/var _t,Pt=function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(n=t[l])&&(r=(s<3?n(r):s>3?n(e,i,r):n(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r};!function(t){t.title="title",t.title_dense="title-dense",t.subtitle1="subtitle1",t.subtitle2="subtitle2",t.body1="body1",t.body2="body2",t.caption="caption",t.breadcrumb="breadcrumb",t.overline="overline",t.button="button"}(_t||(_t={}));const Ht=ft.extend("--ft-typography-font-family",ut.titleFont),Wt=ft.extend("--ft-typography-font-family",ut.contentFont),Zt={fontFamily:Wt,fontSize:ft.create("--ft-typography-font-size","SIZE","16px"),fontWeight:ft.create("--ft-typography-font-weight","UNKNOWN","normal"),letterSpacing:ft.create("--ft-typography-letter-spacing","SIZE","0.496px"),lineHeight:ft.create("--ft-typography-line-height","SIZE","24px"),textTransform:ft.create("--ft-typography-text-transform","UNKNOWN","inherit")},Kt=ft.extend("--ft-typography-title-font-family",Ht),Vt=ft.extend("--ft-typography-title-font-size",Zt.fontSize,"20px"),qt=ft.extend("--ft-typography-title-font-weight",Zt.fontWeight,"normal"),Xt=ft.extend("--ft-typography-title-letter-spacing",Zt.letterSpacing,"0.15px"),Jt=ft.extend("--ft-typography-title-line-height",Zt.lineHeight,"24px"),Yt=ft.extend("--ft-typography-title-text-transform",Zt.textTransform,"inherit"),Gt=ft.extend("--ft-typography-title-dense-font-family",Ht),Qt=ft.extend("--ft-typography-title-dense-font-size",Zt.fontSize,"14px"),te=ft.extend("--ft-typography-title-dense-font-weight",Zt.fontWeight,"normal"),ee=ft.extend("--ft-typography-title-dense-letter-spacing",Zt.letterSpacing,"0.105px"),ie=ft.extend("--ft-typography-title-dense-line-height",Zt.lineHeight,"24px"),oe=ft.extend("--ft-typography-title-dense-text-transform",Zt.textTransform,"inherit"),ne=ft.extend("--ft-typography-subtitle1-font-family",Wt),se=ft.extend("--ft-typography-subtitle1-font-size",Zt.fontSize,"16px"),re=ft.extend("--ft-typography-subtitle1-font-weight",Zt.fontWeight,"600"),le=ft.extend("--ft-typography-subtitle1-letter-spacing",Zt.letterSpacing,"0.144px"),ae=ft.extend("--ft-typography-subtitle1-line-height",Zt.lineHeight,"24px"),pe=ft.extend("--ft-typography-subtitle1-text-transform",Zt.textTransform,"inherit"),ce=ft.extend("--ft-typography-subtitle2-font-family",Wt),de=ft.extend("--ft-typography-subtitle2-font-size",Zt.fontSize,"14px"),fe=ft.extend("--ft-typography-subtitle2-font-weight",Zt.fontWeight,"normal"),he=ft.extend("--ft-typography-subtitle2-letter-spacing",Zt.letterSpacing,"0.098px"),ue=ft.extend("--ft-typography-subtitle2-line-height",Zt.lineHeight,"24px"),be=ft.extend("--ft-typography-subtitle2-text-transform",Zt.textTransform,"inherit"),xe={fontFamily:ft.extend("--ft-typography-body1-font-family",Wt),fontSize:ft.extend("--ft-typography-body1-font-size",Zt.fontSize,"16px"),fontWeight:ft.extend("--ft-typography-body1-font-weight",Zt.fontWeight,"normal"),letterSpacing:ft.extend("--ft-typography-body1-letter-spacing",Zt.letterSpacing,"0.496px"),lineHeight:ft.extend("--ft-typography-body1-line-height",Zt.lineHeight,"24px"),textTransform:ft.extend("--ft-typography-body1-text-transform",Zt.textTransform,"inherit")},ve=ft.extend("--ft-typography-body2-font-family",Wt),ye=ft.extend("--ft-typography-body2-font-size",Zt.fontSize,"14px"),ge=ft.extend("--ft-typography-body2-font-weight",Zt.fontWeight,"normal"),me=ft.extend("--ft-typography-body2-letter-spacing",Zt.letterSpacing,"0.252px"),$e=ft.extend("--ft-typography-body2-line-height",Zt.lineHeight,"20px"),we=ft.extend("--ft-typography-body2-text-transform",Zt.textTransform,"inherit"),Oe={fontFamily:ft.extend("--ft-typography-caption-font-family",Wt),fontSize:ft.extend("--ft-typography-caption-font-size",Zt.fontSize,"12px"),fontWeight:ft.extend("--ft-typography-caption-font-weight",Zt.fontWeight,"normal"),letterSpacing:ft.extend("--ft-typography-caption-letter-spacing",Zt.letterSpacing,"0.396px"),lineHeight:ft.extend("--ft-typography-caption-line-height",Zt.lineHeight,"16px"),textTransform:ft.extend("--ft-typography-caption-text-transform",Zt.textTransform,"inherit")},Se=ft.extend("--ft-typography-breadcrumb-font-family",Wt),ke=ft.extend("--ft-typography-breadcrumb-font-size",Zt.fontSize,"10px"),Ce=ft.extend("--ft-typography-breadcrumb-font-weight",Zt.fontWeight,"normal"),Ee=ft.extend("--ft-typography-breadcrumb-letter-spacing",Zt.letterSpacing,"0.33px"),Ne=ft.extend("--ft-typography-breadcrumb-line-height",Zt.lineHeight,"16px"),Re=ft.extend("--ft-typography-breadcrumb-text-transform",Zt.textTransform,"inherit"),ze=ft.extend("--ft-typography-overline-font-family",Wt),Me=ft.extend("--ft-typography-overline-font-size",Zt.fontSize,"10px"),Fe=ft.extend("--ft-typography-overline-font-weight",Zt.fontWeight,"normal"),Ue=ft.extend("--ft-typography-overline-letter-spacing",Zt.letterSpacing,"1.5px"),Be=ft.extend("--ft-typography-overline-line-height",Zt.lineHeight,"16px"),De=ft.extend("--ft-typography-overline-text-transform",Zt.textTransform,"uppercase"),je={fontFamily:ft.extend("--ft-typography-button-font-family",Wt),fontSize:ft.extend("--ft-typography-button-font-size",Zt.fontSize,"14px"),fontWeight:ft.extend("--ft-typography-button-font-weight",Zt.fontWeight,"600"),letterSpacing:ft.extend("--ft-typography-button-letter-spacing",Zt.letterSpacing,"1.246px"),lineHeight:ft.extend("--ft-typography-button-line-height",Zt.lineHeight,"16px"),textTransform:ft.extend("--ft-typography-button-text-transform",Zt.textTransform,"uppercase")},Te=b`
|
|
110
110
|
.ft-typography--title {
|
|
111
|
-
font-family: ${
|
|
112
|
-
font-size: ${
|
|
113
|
-
font-weight: ${
|
|
114
|
-
letter-spacing: ${
|
|
115
|
-
line-height: ${
|
|
116
|
-
text-transform: ${
|
|
111
|
+
font-family: ${Kt};
|
|
112
|
+
font-size: ${Vt};
|
|
113
|
+
font-weight: ${qt};
|
|
114
|
+
letter-spacing: ${Xt};
|
|
115
|
+
line-height: ${Jt};
|
|
116
|
+
text-transform: ${Yt};
|
|
117
117
|
}
|
|
118
|
-
`,
|
|
118
|
+
`,Le=b`
|
|
119
119
|
.ft-typography--title-dense {
|
|
120
|
-
font-family: ${
|
|
121
|
-
font-size: ${
|
|
122
|
-
font-weight: ${
|
|
123
|
-
letter-spacing: ${
|
|
124
|
-
line-height: ${
|
|
125
|
-
text-transform: ${
|
|
120
|
+
font-family: ${Gt};
|
|
121
|
+
font-size: ${Qt};
|
|
122
|
+
font-weight: ${te};
|
|
123
|
+
letter-spacing: ${ee};
|
|
124
|
+
line-height: ${ie};
|
|
125
|
+
text-transform: ${oe};
|
|
126
126
|
}
|
|
127
|
-
`,
|
|
127
|
+
`,Ae=b`
|
|
128
128
|
.ft-typography--subtitle1 {
|
|
129
|
-
font-family: ${
|
|
130
|
-
font-size: ${
|
|
131
|
-
font-weight: ${
|
|
132
|
-
letter-spacing: ${
|
|
133
|
-
line-height: ${
|
|
134
|
-
text-transform: ${
|
|
129
|
+
font-family: ${ne};
|
|
130
|
+
font-size: ${se};
|
|
131
|
+
font-weight: ${re};
|
|
132
|
+
letter-spacing: ${le};
|
|
133
|
+
line-height: ${ae};
|
|
134
|
+
text-transform: ${pe};
|
|
135
135
|
}
|
|
136
|
-
`,
|
|
136
|
+
`,Ie=b`
|
|
137
137
|
.ft-typography--subtitle2 {
|
|
138
|
-
font-family: ${
|
|
139
|
-
font-size: ${
|
|
140
|
-
font-weight: ${
|
|
141
|
-
letter-spacing: ${
|
|
142
|
-
line-height: ${
|
|
143
|
-
text-transform: ${
|
|
138
|
+
font-family: ${ce};
|
|
139
|
+
font-size: ${de};
|
|
140
|
+
font-weight: ${fe};
|
|
141
|
+
letter-spacing: ${he};
|
|
142
|
+
line-height: ${ue};
|
|
143
|
+
text-transform: ${be};
|
|
144
144
|
}
|
|
145
145
|
|
|
146
|
-
`,
|
|
146
|
+
`,_e=b`
|
|
147
147
|
.ft-typography--body1 {
|
|
148
|
-
font-family: ${
|
|
149
|
-
font-size: ${
|
|
150
|
-
font-weight: ${
|
|
151
|
-
letter-spacing: ${
|
|
152
|
-
line-height: ${
|
|
153
|
-
text-transform: ${
|
|
148
|
+
font-family: ${xe.fontFamily};
|
|
149
|
+
font-size: ${xe.fontSize};
|
|
150
|
+
font-weight: ${xe.fontWeight};
|
|
151
|
+
letter-spacing: ${xe.letterSpacing};
|
|
152
|
+
line-height: ${xe.lineHeight};
|
|
153
|
+
text-transform: ${xe.textTransform};
|
|
154
154
|
}
|
|
155
|
-
`,
|
|
155
|
+
`,Pe=b`
|
|
156
156
|
.ft-typography--body2 {
|
|
157
|
-
font-family: ${
|
|
158
|
-
font-size: ${
|
|
159
|
-
font-weight: ${
|
|
160
|
-
letter-spacing: ${
|
|
161
|
-
line-height: ${
|
|
162
|
-
text-transform: ${
|
|
157
|
+
font-family: ${ve};
|
|
158
|
+
font-size: ${ye};
|
|
159
|
+
font-weight: ${ge};
|
|
160
|
+
letter-spacing: ${me};
|
|
161
|
+
line-height: ${$e};
|
|
162
|
+
text-transform: ${we};
|
|
163
163
|
}
|
|
164
|
-
`,
|
|
164
|
+
`,He=b`
|
|
165
165
|
.ft-typography--caption {
|
|
166
|
-
font-family: ${
|
|
167
|
-
font-size: ${
|
|
168
|
-
font-weight: ${
|
|
169
|
-
letter-spacing: ${
|
|
170
|
-
line-height: ${
|
|
171
|
-
text-transform: ${
|
|
166
|
+
font-family: ${Oe.fontFamily};
|
|
167
|
+
font-size: ${Oe.fontSize};
|
|
168
|
+
font-weight: ${Oe.fontWeight};
|
|
169
|
+
letter-spacing: ${Oe.letterSpacing};
|
|
170
|
+
line-height: ${Oe.lineHeight};
|
|
171
|
+
text-transform: ${Oe.textTransform};
|
|
172
172
|
}
|
|
173
|
-
`,
|
|
173
|
+
`,We=b`
|
|
174
174
|
.ft-typography--breadcrumb {
|
|
175
|
-
font-family: ${
|
|
176
|
-
font-size: ${
|
|
177
|
-
font-weight: ${
|
|
178
|
-
letter-spacing: ${
|
|
179
|
-
line-height: ${
|
|
180
|
-
text-transform: ${
|
|
175
|
+
font-family: ${Se};
|
|
176
|
+
font-size: ${ke};
|
|
177
|
+
font-weight: ${Ce};
|
|
178
|
+
letter-spacing: ${Ee};
|
|
179
|
+
line-height: ${Ne};
|
|
180
|
+
text-transform: ${Re};
|
|
181
181
|
}
|
|
182
|
-
`,
|
|
182
|
+
`,Ze=b`
|
|
183
183
|
.ft-typography--overline {
|
|
184
|
-
font-family: ${
|
|
185
|
-
font-size: ${
|
|
186
|
-
font-weight: ${
|
|
187
|
-
letter-spacing: ${
|
|
188
|
-
line-height: ${
|
|
189
|
-
text-transform: ${
|
|
184
|
+
font-family: ${ze};
|
|
185
|
+
font-size: ${Me};
|
|
186
|
+
font-weight: ${Fe};
|
|
187
|
+
letter-spacing: ${Ue};
|
|
188
|
+
line-height: ${Be};
|
|
189
|
+
text-transform: ${De};
|
|
190
190
|
}
|
|
191
|
-
`,
|
|
191
|
+
`,Ke=b`
|
|
192
192
|
.ft-typography--button {
|
|
193
|
-
font-family: ${
|
|
194
|
-
font-size: ${
|
|
195
|
-
font-weight: ${
|
|
196
|
-
letter-spacing: ${
|
|
197
|
-
line-height: ${
|
|
198
|
-
text-transform: ${
|
|
193
|
+
font-family: ${je.fontFamily};
|
|
194
|
+
font-size: ${je.fontSize};
|
|
195
|
+
font-weight: ${je.fontWeight};
|
|
196
|
+
letter-spacing: ${je.letterSpacing};
|
|
197
|
+
line-height: ${je.lineHeight};
|
|
198
|
+
text-transform: ${je.textTransform};
|
|
199
199
|
}
|
|
200
|
-
`;class
|
|
201
|
-
<${
|
|
200
|
+
`;class Ve extends bt{constructor(){super(...arguments),this.variant=_t.body1}render(){return this.element?It`
|
|
201
|
+
<${Lt(this.element)}
|
|
202
202
|
class="ft-typography ft-typography--${this.variant}">
|
|
203
203
|
<slot></slot>
|
|
204
|
-
</${
|
|
205
|
-
`:
|
|
204
|
+
</${Lt(this.element)}>
|
|
205
|
+
`:It`
|
|
206
206
|
<slot class="ft-typography ft-typography--${this.variant}"></slot>
|
|
207
|
-
`}}
|
|
207
|
+
`}}Ve.styles=[Te,Le,Ae,Ie,_e,Pe,He,We,Ze,Ke,b`
|
|
208
208
|
.ft-typography {
|
|
209
209
|
vertical-align: inherit;
|
|
210
210
|
}
|
|
211
|
-
`],
|
|
211
|
+
`],Pt([o()],Ve.prototype,"element",void 0),Pt([o()],Ve.prototype,"variant",void 0),p("ft-typography")(Ve);var qe=function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(n=t[l])&&(r=(s<3?n(r):s>3?n(e,i,r):n(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r};const Xe={fontSize:ft.create("--ft-input-label-font-size","SIZE","14px"),raisedFontSize:ft.create("--ft-input-label-raised-font-size","SIZE","11px"),raisedZIndex:ft.create("--ft-input-label-outlined-raised-z-index","NUMBER","2"),verticalSpacing:ft.create("--ft-input-label-vertical-spacing","SIZE","4px"),horizontalSpacing:ft.create("--ft-input-label-horizontal-spacing","SIZE","12px"),borderColor:ft.extend("--ft-input-label-border-color",ut.colorOutline),textColor:ft.extend("--ft-input-label-text-color",ut.colorOnSurfaceMedium),disabledTextColor:ft.extend("--ft-input-label-disabled-text-color",ut.colorOnSurfaceDisabled),colorSurface:ft.external(ut.colorSurface,"Design system"),borderRadiusS:ft.external(ut.borderRadiusS,"Design system"),colorError:ft.external(ut.colorError,"Design system")};class Je extends bt{constructor(){super(...arguments),this.text="",this.raised=!1,this.outlined=!1,this.disabled=!1,this.error=!1}render(){const t={"ft-input-label":!0,"ft-input-label--raised":this.raised,"ft-input-label--outlined":this.outlined,"ft-input-label--disabled":this.disabled,"ft-input-label--in-error":this.error};return W`
|
|
212
212
|
<div class="${Dt(t)}">
|
|
213
213
|
${this.text?W`
|
|
214
214
|
<div class="ft-input-label--text ft-typography--caption">
|
|
@@ -217,7 +217,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
217
217
|
</div>
|
|
218
218
|
`:null}
|
|
219
219
|
</div>
|
|
220
|
-
`}}
|
|
220
|
+
`}}Je.elementDefinitions={},Je.styles=[He,b`
|
|
221
221
|
.ft-input-label {
|
|
222
222
|
position: absolute;
|
|
223
223
|
inset: 0;
|
|
@@ -225,7 +225,11 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
225
225
|
}
|
|
226
226
|
|
|
227
227
|
.ft-input-label {
|
|
228
|
-
border-color: ${
|
|
228
|
+
border-color: ${Xe.borderColor};
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
.ft-input-label.ft-input-label--in-error {
|
|
232
|
+
border-color: ${Xe.colorError}
|
|
229
233
|
}
|
|
230
234
|
|
|
231
235
|
.ft-input-label:before,
|
|
@@ -238,7 +242,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
238
242
|
}
|
|
239
243
|
|
|
240
244
|
.ft-input-label:before {
|
|
241
|
-
width: ${
|
|
245
|
+
width: ${Xe.horizontalSpacing};
|
|
242
246
|
flex-shrink: 0;
|
|
243
247
|
}
|
|
244
248
|
|
|
@@ -254,14 +258,18 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
254
258
|
border-bottom-width: 1px;
|
|
255
259
|
border-bottom-style: solid;
|
|
256
260
|
border-color: inherit;
|
|
257
|
-
color: ${
|
|
261
|
+
color: ${Xe.textColor};
|
|
258
262
|
transition: font-size 250ms, line-height 250ms, color 250ms;
|
|
259
|
-
${
|
|
260
|
-
${
|
|
263
|
+
${ht(Oe.fontSize,Xe.fontSize)};
|
|
264
|
+
${ht(Oe.lineHeight,Xe.fontSize)};
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
.ft-input-label--in-error .ft-input-label--text {
|
|
268
|
+
color: ${Xe.colorError}
|
|
261
269
|
}
|
|
262
270
|
|
|
263
271
|
.ft-input-label--disabled .ft-input-label--text {
|
|
264
|
-
color: ${
|
|
272
|
+
color: ${Xe.disabledTextColor};
|
|
265
273
|
}
|
|
266
274
|
|
|
267
275
|
.ft-input-label--hidden-text {
|
|
@@ -277,17 +285,17 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
277
285
|
overflow: hidden;
|
|
278
286
|
white-space: nowrap;
|
|
279
287
|
text-overflow: ellipsis;
|
|
280
|
-
padding: ${
|
|
281
|
-
margin: calc(${
|
|
288
|
+
padding: ${Xe.verticalSpacing} 4px;
|
|
289
|
+
margin: calc(${Xe.verticalSpacing} * -1) 0;
|
|
282
290
|
}
|
|
283
291
|
|
|
284
292
|
.ft-input-label--raised .ft-input-label--text {
|
|
285
|
-
${
|
|
286
|
-
${
|
|
293
|
+
${ht(Oe.fontSize,Xe.raisedFontSize)};
|
|
294
|
+
${ht(Oe.lineHeight,Xe.raisedFontSize)};
|
|
287
295
|
}
|
|
288
296
|
|
|
289
297
|
.ft-input-label--raised .ft-input-label--floating-text {
|
|
290
|
-
top: ${
|
|
298
|
+
top: ${Xe.verticalSpacing};
|
|
291
299
|
}
|
|
292
300
|
|
|
293
301
|
.ft-input-label--outlined .ft-input-label--text,
|
|
@@ -300,27 +308,27 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
300
308
|
.ft-input-label--outlined:before {
|
|
301
309
|
border-left-width: 1px;
|
|
302
310
|
border-left-style: solid;
|
|
303
|
-
border-radius: ${
|
|
311
|
+
border-radius: ${Xe.borderRadiusS} 0 0 ${Xe.borderRadiusS};
|
|
304
312
|
}
|
|
305
313
|
|
|
306
314
|
.ft-input-label--outlined:after {
|
|
307
315
|
border-right-width: 1px;
|
|
308
316
|
border-right-style: solid;
|
|
309
|
-
border-radius: 0 ${
|
|
317
|
+
border-radius: 0 ${Xe.borderRadiusS} ${Xe.borderRadiusS} 0;
|
|
310
318
|
}
|
|
311
319
|
|
|
312
320
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--floating-text {
|
|
313
321
|
padding: 2px 4px;
|
|
314
|
-
z-index: ${
|
|
315
|
-
background-color: ${
|
|
316
|
-
border-radius: ${
|
|
322
|
+
z-index: ${Xe.raisedZIndex};
|
|
323
|
+
background-color: ${Xe.colorSurface};
|
|
324
|
+
border-radius: ${Xe.borderRadiusS};
|
|
317
325
|
top: calc((var(--ft-typography-caption-line-height) / -2) + 2px);
|
|
318
326
|
}
|
|
319
327
|
|
|
320
328
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--text {
|
|
321
329
|
border-top: none;
|
|
322
330
|
}
|
|
323
|
-
`],
|
|
331
|
+
`],qe([o({type:String})],Je.prototype,"text",void 0),qe([o({type:Boolean})],Je.prototype,"raised",void 0),qe([o({type:Boolean})],Je.prototype,"outlined",void 0),qe([o({type:Boolean})],Je.prototype,"disabled",void 0),qe([o({type:Boolean})],Je.prototype,"error",void 0),p("ft-input-label")(Je);var Ye=function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(n=t[l])&&(r=(s<3?n(r):s>3?n(e,i,r):n(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r};const Ge=ft.extend("--ft-ripple-color",ut.colorContent),Qe={color:Ge,backgroundColor:ft.extend("--ft-ripple-background-color",Ge),opacityContentOnSurfacePressed:ft.external(ut.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:ft.external(ut.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:ft.external(ut.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:ft.external(ut.opacityContentOnSurfaceSelected,"Design system")},ti=ft.extend("--ft-ripple-color",ut.colorPrimary),ei=ti,ii=ft.extend("--ft-ripple-background-color",ti),oi=ft.extend("--ft-ripple-color",ut.colorSecondary),ni=oi,si=ft.extend("--ft-ripple-background-color",oi);class ri extends bt{constructor(){super(...arguments),this.primary=!1,this.secondary=!1,this.unbounded=!1,this.activated=!1,this.selected=!1,this.disabled=!1,this.hovered=!1,this.focused=!1,this.pressed=!1,this.rippling=!1,this.rippleSize=0,this.originX=0,this.originY=0,this.resizeObserver=new ResizeObserver((()=>this.setRippleSize())),this.debouncer=new e(1e3),this.onTransitionStart=t=>{"transform"===t.propertyName&&(this.rippling=this.pressed,this.debouncer.run((()=>this.rippling=!1)))},this.onTransitionEnd=t=>{"transform"===t.propertyName&&(this.rippling=!1)},this.moveRipple=t=>{var e,i;let{x:o,y:n}=this.getCoordinates(t),s=null!==(i=null===(e=this.ripple)||void 0===e?void 0:e.getBoundingClientRect())&&void 0!==i?i:{x:0,y:0,width:0,height:0};this.originX=Math.round(null!=o?o-s.x:s.width/2),this.originY=Math.round(null!=n?n-s.y:s.height/2)},this.startPress=t=>{this.moveRipple(t),this.pressed=!this.isIgnored(t)},this.endPress=()=>{this.pressed=!1},this.startHover=t=>{this.hovered=!this.isIgnored(t)},this.endHover=()=>{this.hovered=!1},this.startFocus=t=>{this.focused=!this.isIgnored(t)},this.endFocus=()=>{this.focused=!1}}render(){let t={"ft-ripple":!0,"ft-ripple--primary":this.primary,"ft-ripple--secondary":this.secondary,"ft-ripple--unbounded":this.unbounded,"ft-ripple--selected":(this.selected||this.activated)&&!this.disabled,"ft-ripple--pressed":(this.pressed||this.rippling)&&!this.disabled,"ft-ripple--hovered":this.hovered&&!this.disabled,"ft-ripple--focused":this.focused&&!this.disabled};return W`
|
|
324
332
|
<style>
|
|
325
333
|
.ft-ripple .ft-ripple--effect,
|
|
326
334
|
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
@@ -337,7 +345,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
337
345
|
<div class="ft-ripple--background"></div>
|
|
338
346
|
<div class="ft-ripple--effect"></div>
|
|
339
347
|
</div>
|
|
340
|
-
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){super.updated(t),t.has("disabled")&&this.disabled
|
|
348
|
+
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){var e,i;super.updated(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(e=this.target)||void 0===e||e.removeAttribute("data-is-ft-ripple-target")):null===(i=this.target)||void 0===i||i.setAttribute("data-is-ft-ripple-target","true")),t.has("unbounded")&&this.setRippleSize()}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}setRippleSize(){if(this.ripple){const t=this.ripple.getBoundingClientRect();this.rippleSize=(this.unbounded?1:1.7)*Math.max(t.width,t.height)}}connectedCallback(){var t;super.connectedCallback();const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(e),this.setRippleSize()}setupFor(t){if(this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const e=(...t)=>e=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(e)},i=e("mouseup","contextmenu"),o=e("touchend","touchcancel"),n=t=>{["Enter"," "].includes(t.key)&&e("keyup")(t)};t.addEventListener("mouseover",this.startHover),t.addEventListener("mousemove",this.moveRipple),t.addEventListener("mouseleave",this.endHover),t.addEventListener("mousedown",i),t.addEventListener("touchstart",o),t.addEventListener("touchmove",this.moveRipple),t.addEventListener("keydown",n),t.addEventListener("focus",this.startFocus),t.addEventListener("blur",this.endFocus),t.addEventListener("focusin",this.startFocus),t.addEventListener("focusout",this.endFocus),this.onDisconnect=()=>{t.removeAttribute("data-is-ft-ripple-target"),t.removeEventListener("mouseover",this.startHover),t.removeEventListener("mousemove",this.moveRipple),t.removeEventListener("mouseleave",this.endHover),t.removeEventListener("mousedown",i),t.removeEventListener("touchstart",o),t.removeEventListener("touchmove",this.moveRipple),t.removeEventListener("keydown",n),t.removeEventListener("focus",this.startFocus),t.removeEventListener("blur",this.endFocus),t.removeEventListener("focusin",this.startFocus),t.removeEventListener("focusout",this.endFocus),this.onDisconnect=void 0}}getCoordinates(t){const e=t,i=t;let o,n;return null!=e.x?({x:o,y:n}=e):null!=i.touches&&(o=i.touches[0].clientX,n=i.touches[0].clientY),{x:o,y:n}}isIgnored(t){if(this.disabled)return!0;if(null!=t)for(let e of t.composedPath()){if(e===this.target)break;if("hasAttribute"in e&&e.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.resizeObserver.disconnect(),this.endRipple()}}var li,ai;ri.elementDefinitions={},ri.styles=b`
|
|
341
349
|
:host {
|
|
342
350
|
display: contents;
|
|
343
351
|
}
|
|
@@ -356,17 +364,30 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
356
364
|
.ft-ripple .ft-ripple--effect {
|
|
357
365
|
position: absolute;
|
|
358
366
|
opacity: 0;
|
|
359
|
-
background-color: ${Je.color};
|
|
360
367
|
}
|
|
361
368
|
|
|
362
|
-
.ft-ripple
|
|
369
|
+
.ft-ripple .ft-ripple--background {
|
|
370
|
+
background-color: ${Qe.backgroundColor};
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
.ft-ripple .ft-ripple--effect {
|
|
374
|
+
background-color: ${Qe.color};
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
.ft-ripple.ft-ripple--secondary .ft-ripple--background {
|
|
378
|
+
background-color: ${si};
|
|
379
|
+
}
|
|
380
|
+
|
|
363
381
|
.ft-ripple.ft-ripple--secondary .ft-ripple--effect {
|
|
364
|
-
background-color: ${
|
|
382
|
+
background-color: ${ni};
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
.ft-ripple.ft-ripple--primary .ft-ripple--background {
|
|
386
|
+
background-color: ${ii};
|
|
365
387
|
}
|
|
366
388
|
|
|
367
|
-
.ft-ripple.ft-ripple--primary .ft-ripple--background,
|
|
368
389
|
.ft-ripple.ft-ripple--primary .ft-ripple--effect {
|
|
369
|
-
background-color: ${
|
|
390
|
+
background-color: ${ei};
|
|
370
391
|
}
|
|
371
392
|
|
|
372
393
|
.ft-ripple .ft-ripple--background {
|
|
@@ -374,6 +395,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
374
395
|
left: 0;
|
|
375
396
|
height: 100%;
|
|
376
397
|
width: 100%;
|
|
398
|
+
transition: opacity 75ms linear;
|
|
377
399
|
}
|
|
378
400
|
|
|
379
401
|
.ft-ripple .ft-ripple--effect,
|
|
@@ -397,36 +419,36 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
397
419
|
}
|
|
398
420
|
|
|
399
421
|
.ft-ripple.ft-ripple--hovered .ft-ripple--background {
|
|
400
|
-
opacity: ${
|
|
422
|
+
opacity: ${Qe.opacityContentOnSurfaceHover};
|
|
401
423
|
}
|
|
402
424
|
|
|
403
425
|
.ft-ripple.ft-ripple--selected .ft-ripple--background {
|
|
404
|
-
opacity: ${
|
|
426
|
+
opacity: ${Qe.opacityContentOnSurfaceSelected};
|
|
405
427
|
}
|
|
406
428
|
|
|
407
429
|
.ft-ripple.ft-ripple--focused .ft-ripple--background {
|
|
408
|
-
opacity: ${
|
|
430
|
+
opacity: ${Qe.opacityContentOnSurfaceFocused};
|
|
409
431
|
}
|
|
410
432
|
|
|
411
433
|
.ft-ripple.ft-ripple--pressed .ft-ripple--effect {
|
|
412
|
-
opacity: ${
|
|
434
|
+
opacity: ${Qe.opacityContentOnSurfacePressed};
|
|
413
435
|
transform: translate(-50%, -50%) scale(1);
|
|
414
436
|
}
|
|
415
|
-
`,
|
|
437
|
+
`,Ye([o({type:Boolean})],ri.prototype,"primary",void 0),Ye([o({type:Boolean})],ri.prototype,"secondary",void 0),Ye([o({type:Boolean})],ri.prototype,"unbounded",void 0),Ye([o({type:Boolean})],ri.prototype,"activated",void 0),Ye([o({type:Boolean})],ri.prototype,"selected",void 0),Ye([o({type:Boolean})],ri.prototype,"disabled",void 0),Ye([n()],ri.prototype,"hovered",void 0),Ye([n()],ri.prototype,"focused",void 0),Ye([n()],ri.prototype,"pressed",void 0),Ye([n()],ri.prototype,"rippling",void 0),Ye([n()],ri.prototype,"rippleSize",void 0),Ye([n()],ri.prototype,"originX",void 0),Ye([n()],ri.prototype,"originY",void 0),Ye([r(".ft-ripple")],ri.prototype,"ripple",void 0),Ye([r(".ft-ripple--effect")],ri.prototype,"rippleEffect",void 0),p("ft-ripple")(ri),function(t){t.THIN_ARROW_LEFT="",t.THIN_ARROW_RIGHT="",t.MY_COLLECTIONS="",t.OFFLINE_SETTINGS="",t.MY_LIBRARY="",t.RATE_PLAIN="",t.RATE="",t.FEEDBACK_PLAIN="",t.STAR_PLAIN="",t.STAR="",t.THUMBS_DOWN_PLAIN="",t.THUMBS_DOWN="",t.THUMBS_UP_PLAIN="",t.THUMBS_UP="",t.PAUSE="",t.PLAY="",t.RELATIVES_PLAIN="",t.RELATIVES="",t.SHORTCUT_MENU="",t.PRINT="",t.DEFAULT_ROLES="",t.ACCOUNT_SETTINGS="",t.ONLINE="",t.OFFLINE="",t.UPLOAD="",t.BOOK_PLAIN="",t.SYNC="",t.SHARED_PBK="",t.COLLECTIONS="",t.SEARCH_IN_PUBLICATION="",t.BOOKS="",t.LOCKER="",t.ARROW_DOWN="",t.ARROW_LEFT="",t.ARROW_RIGHT="",t.ARROW_UP="",t.SAVE="",t.MAILS_AND_NOTIFICATIONS="",t.DOT="",t.MINUS="",t.PLUS="",t.FILTERS="",t.STRIPE_ARROW_RIGHT="",t.STRIPE_ARROW_LEFT="",t.ATTACHMENTS="",t.ADD_BOOKMARK="",t.BOOKMARK="",t.EXPORT="",t.MENU="",t.TAG="",t.TAG_PLAIN="",t.COPY_TO_CLIPBOARD="",t.COLUMNS="",t.ARTICLE="",t.CLOSE_PLAIN="",t.CHECK_PLAIN="",t.LOGOUT="",t.SIGN_IN="",t.THIN_ARROW="",t.TRIANGLE_BOTTOM="",t.TRIANGLE_LEFT="",t.TRIANGLE_RIGHT="",t.TRIANGLE_TOP="",t.FACET_HAS_DESCENDANT="",t.MINUS_PLAIN="",t.PLUS_PLAIN="",t.INFO="",t.ICON_EXPAND="",t.ICON_COLLAPSE="",t.ADD_TO_PBK="",t.ALERT="",t.ADD_ALERT="",t.BACK_TO_SEARCH="",t.DOWNLOAD="",t.EDIT="",t.FEEDBACK="",t.MODIFY_PBK="",t.SCHEDULED="",t.SEARCH="",t.SHARE="󨃱",t.TOC="",t.WRITE_UGC="",t.TRASH="",t.EXTLINK="",t.CALENDAR="",t.BOOK="",t.DOWNLOAD_PLAIN="",t.CHECK="",t.TOPICS="",t.EYE="\f06e",t.DISC="",t.CIRCLE="",t.SHARED="",t.SORT_UNSORTED="",t.SORT_UP="",t.SORT_DOWN="",t.WORKING="",t.CLOSE="",t.ZOOM_OUT="",t.ZOOM_IN="",t.ZOOM_REALSIZE="",t.ZOOM_FULLSCREEN="",t.ADMIN_RESTRICTED="",t.ADMIN_THEME="",t.WARNING="",t.CONTEXT="",t.SEARCH_HOME="",t.STEPS="",t.HOME="",t.TRANSLATE="",t.USER="",t.ADMIN="",t.ANALYTICS="",t.ADMIN_KHUB="",t.ADMIN_USERS="",t.ADMIN_INTEGRATION="",t.ADMIN_PORTAL=""}(li||(li={})),function(t){t.UNKNOWN="",t.ABW="",t.AUDIO="",t.AVI="",t.CHM="",t.CODE="",t.CSV="",t.DITA="",t.EPUB="",t.EXCEL="",t.FLAC="",t.GIF="",t.GZIP="",t.HTML="",t.IMAGE="",t.JPEG="",t.JSON="",t.M4A="",t.MOV="",t.MP3="",t.MP4="",t.OGG="",t.PDF="",t.PNG="",t.POWERPOINT="",t.RAR="",t.STP="",t.TEXT="",t.VIDEO="",t.WAV="",t.WMA="",t.WORD="",t.XML="",t.YAML="",t.ZIP=""}(ai||(ai={})),new Map([...["abw"].map((t=>[t,ai.ABW])),...["3gp","act","aiff","aac","amr","au","awb","dct","dss","dvf","gsm","iklax","ivs","mmf","mpc","msv","opus","ra","rm","raw","sln","tta","vox","wv"].map((t=>[t,ai.AUDIO])),...["avi"].map((t=>[t,ai.AVI])),...["chm","xhs"].map((t=>[t,ai.CHM])),...["java","py","php","php3","php4","php5","js","javascript","rb","rbw","c","cpp","cxx","h","hh","hpp","hxx","sh","bash","zsh","tcsh","ksh","csh","vb","scala","pl","prl","perl","groovy","ceylon","aspx","jsp","scpt","applescript","bas","bat","lua","jsp","mk","cmake","css","sass","less","m","mm","xcodeproj"].map((t=>[t,ai.CODE])),...["csv"].map((t=>[t,ai.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,ai.DITA])),...["epub"].map((t=>[t,ai.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,ai.EXCEL])),...["flac"].map((t=>[t,ai.FLAC])),...["gif"].map((t=>[t,ai.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,ai.GZIP])),...["html","htm","xhtml"].map((t=>[t,ai.HTML])),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf"].map((t=>[t,ai.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,ai.JPEG])),...["json"].map((t=>[t,ai.JSON])),...["m4a","m4p"].map((t=>[t,ai.M4A])),...["mov","qt"].map((t=>[t,ai.MOV])),...["mp3"].map((t=>[t,ai.MP3])),...["mp4","m4v"].map((t=>[t,ai.MP4])),...["ogg","oga"].map((t=>[t,ai.OGG])),...["pdf","ps"].map((t=>[t,ai.PDF])),...["png"].map((t=>[t,ai.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,ai.POWERPOINT])),...["rar"].map((t=>[t,ai.RAR])),...["stp"].map((t=>[t,ai.STP])),...["txt","rtf","md","mdown"].map((t=>[t,ai.TEXT])),...["webm","mkv","flv","vob","ogv","ogg","drc","mng","wmv","yuv","rm","rmvb","asf","mpg","mp2","mpeg","mpe","mpv","m2v","svi","3gp","3g2","mxf","roq","nsv"].map((t=>[t,ai.VIDEO])),...["wav"].map((t=>[t,ai.WAV])),...["wma"].map((t=>[t,ai.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,ai.WORD])),...["xml","xsl","rdf"].map((t=>[t,ai.XML])),...["yaml","yml","x-yaml"].map((t=>[t,ai.YAML])),...["zip"].map((t=>[t,ai.ZIP]))]);var pi,ci=function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(n=t[l])&&(r=(s<3?n(r):s>3?n(e,i,r):n(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r};!function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(pi||(pi={}));const di={size:ft.create("--ft-icon-font-size","SIZE","24px"),fluidTopicsFontFamily:ft.extend("--ft-icon-fluid-topics-font-family",ft.create("--ft-icon-font-family","UNKNOWN","ft-icons")),fileFormatFontFamily:ft.extend("--ft-icon-file-format-font-family",ft.create("--ft-icon-font-family","UNKNOWN","ft-mime")),materialFontFamily:ft.extend("--ft-icon-material-font-family",ft.create("--ft-icon-font-family","UNKNOWN","Material Icons"))};class fi extends bt{constructor(){super(...arguments),this.variant=pi.fluid_topics}render(){return W`
|
|
416
438
|
<i class="ft-icon ${"ft-icon--"+this.variant}">
|
|
417
439
|
${Bt(this.getIcon())}
|
|
418
440
|
<slot @slotchange=${()=>this.requestUpdate()} ?hidden=${"material"!==this.variant}></slot>
|
|
419
441
|
</i>
|
|
420
|
-
`}get textContent(){var t,e;return null!==(e=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==e?e:""}getIcon(){var t,e;let i=this.textContent;return this.variant===
|
|
442
|
+
`}get textContent(){var t,e;return null!==(e=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==e?e:""}getIcon(){var t,e;let i=this.textContent;return this.variant===pi.file_format?null!==(t=ai[i.toUpperCase()])&&void 0!==t?t:i:this.variant===pi.fluid_topics?null!==(e=li[i.toUpperCase()])&&void 0!==e?e:i:K}}fi.elementDefinitions={},fi.styles=b`
|
|
421
443
|
:host, i.ft-icon {
|
|
422
444
|
display: inline-block;
|
|
423
|
-
width: ${
|
|
424
|
-
height: ${
|
|
445
|
+
width: ${di.size};
|
|
446
|
+
height: ${di.size};
|
|
425
447
|
text-align: center;
|
|
426
448
|
}
|
|
427
449
|
|
|
428
450
|
i.ft-icon {
|
|
429
|
-
font-size: ${
|
|
451
|
+
font-size: ${di.size};
|
|
430
452
|
line-height: 1;
|
|
431
453
|
font-weight: normal;
|
|
432
454
|
text-transform: none;
|
|
@@ -440,17 +462,17 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
440
462
|
}
|
|
441
463
|
|
|
442
464
|
.ft-icon--fluid-topics {
|
|
443
|
-
font-family: ${
|
|
465
|
+
font-family: ${di.fluidTopicsFontFamily}, ft-icons, fticons, sans-serif;
|
|
444
466
|
}
|
|
445
467
|
|
|
446
468
|
.ft-icon--file-format {
|
|
447
|
-
font-family: ${
|
|
469
|
+
font-family: ${di.fileFormatFontFamily}, ft-mime, sans-serif;
|
|
448
470
|
}
|
|
449
471
|
|
|
450
472
|
.ft-icon--material {
|
|
451
|
-
font-family: ${
|
|
473
|
+
font-family: ${di.materialFontFamily}, "Material Icons", sans-serif;
|
|
452
474
|
}
|
|
453
|
-
`,
|
|
475
|
+
`,ci([o()],fi.prototype,"variant",void 0),ci([r("slot")],fi.prototype,"slottedContent",void 0),p("ft-icon")(fi);var hi=function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(n=t[l])&&(r=(s<3?n(r):s>3?n(e,i,r):n(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r};class ui extends bt{constructor(){super(...arguments),this.label="",this.value=null,this.selected=!1}render(){return W``}updated(t){super.updated(t),this.dispatchEvent(new CustomEvent("option-change",{detail:this,bubbles:!0}))}}ui.elementDefinitions={},hi([o({type:String})],ui.prototype,"label",void 0),hi([o({type:Object,converter:t=>t})],ui.prototype,"value",void 0),hi([o({type:Boolean,reflect:!0})],ui.prototype,"selected",void 0);const bi={labelSize:ft.create("--ft-select-label-size","SIZE","11px"),selectedOptionSize:ft.create("--ft-select-selected-option-size","SIZE","14px"),verticalSpacing:ft.create("--ft-select-vertical-spacing","SIZE","4px"),selectedOptionColor:ft.extend("--ft-select-selected-option-color",ut.colorOnSurface),helperColor:ft.extend("--ft-select-helper-color",ut.colorOnSurfaceMedium),optionsColor:ft.extend("--ft-select-options-color",ut.colorOnSurface),optionsZIndex:ft.create("--ft-select-options-z-index","NUMBER","3"),colorSurface:ft.external(ut.colorSurface,"Design system"),colorOnSurfaceDisabled:ft.external(ut.colorOnSurfaceDisabled,"Design system"),colorPrimary:ft.external(ut.colorPrimary,"Design system"),borderRadiusS:ft.external(ut.borderRadiusS,"Design system"),elevation02:ft.external(ut.elevation02,"Design system"),colorError:ft.external(ut.colorError,"Design system")};class xi extends bt{constructor(){super(...arguments),this.label="",this.helper="",this.outlined=!1,this.disabled=!1,this.error=!1,this.fixedMenuPosition=!1,this.options=[],this.optionsDisplayed=!1,this.focusOptions=!1,this.hideOptions=t=>this.optionsDisplayed=this.optionsDisplayed&&t.composedPath().includes(this.container)}render(){var t,e,i,o,n;let s=this.hasOptionsMenuOpen,r=this.disabled||!this.hasOptions;const l=null!=(null===(t=this.selectedOption)||void 0===t?void 0:t.value)||(null!==(i=null===(e=this.selectedOption)||void 0===e?void 0:e.label)&&void 0!==i?i:"").length>0,a={"ft-select":!0,"ft-select--filled":!this.outlined,"ft-select--outlined":this.outlined,"ft-select--disabled":r,"ft-select--options-displayed":s,"ft-select--has-option-selected":l,"ft-select--no-label":!this.label,"ft-select--fixed":this.fixedMenuPosition,"ft-select--in-error":this.error};return W`
|
|
454
476
|
<div class="${Dt(a)}" part="container">
|
|
455
477
|
<div class="ft-select--main-panel" part="main-panel">
|
|
456
478
|
<ft-input-label text="${this.label}"
|
|
@@ -458,6 +480,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
458
480
|
?disabled=${r}
|
|
459
481
|
?outlined=${this.outlined}
|
|
460
482
|
?raised=${l||s}
|
|
483
|
+
?error=${this.error}
|
|
461
484
|
></ft-input-label>
|
|
462
485
|
<div class="ft-select--input-panel"
|
|
463
486
|
part="selected-value"
|
|
@@ -496,7 +519,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
496
519
|
<ft-ripple ?primary=${e} ?activated=${e}></ft-ripple>
|
|
497
520
|
${t.label}
|
|
498
521
|
</div>
|
|
499
|
-
`}updated(t){var e;super.updated(t),t.has("options")&&(this.selectedOption=this.options.filter((t=>t.selected))[0]),t.has("selectedOption")&&(this.optionsDisplayed=!1,this.dispatchEvent(new CustomEvent("change",{detail:null===(e=this.selectedOption)||void 0===e?void 0:e.value})))}contentAvailableCallback(t){var e,i;t.has("focusOptions")&&this.focusOptions&&(null===(i=null!==(e=this.selectedOptionElement)&&void 0!==e?e:this.firstOption)||void 0===i||i.focus(),this.focusOptions=!1)}get hasOptions(){return this.options.length>0}updateOptionsFromSlot(t){var e;t.stopPropagation();let i=null===(e=this.optionsSlot)||void 0===e?void 0:e.assignedElements().map((t=>t));i&&i.length>0&&(this.options=i)}onMainPanelKeyDown(t){switch(t.key){case" ":t.preventDefault(),t.stopPropagation();case"Enter":this.optionsDisplayed=!this.optionsDisplayed,this.focusOptions=!0;break;case"ArrowUp":case"ArrowDown":t.preventDefault(),t.stopPropagation(),this.optionsDisplayed=!0,this.focusOptions=!0}}onOptionsKeyDown(t){var e,i,o,n,s;let r;switch(t.key){case"Escape":this.optionsDisplayed=!1,null===(e=this.mainPanel)||void 0===e||e.focus();break;case"Tab":this.optionsDisplayed=!1;break;case"ArrowUp":t.preventDefault(),t.stopPropagation(),r=null!==(o=null===(i=this.focusedOption)||void 0===i?void 0:i.previousElementSibling)&&void 0!==o?o:this.lastOption;break;case"ArrowDown":t.preventDefault(),t.stopPropagation(),r=null!==(s=null===(n=this.focusedOption)||void 0===n?void 0:n.nextElementSibling)&&void 0!==s?s:this.firstOption}null==r||r.focus()}onOptionKeyDown(t,e){var i;"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),t.stopPropagation(),this.selectOption(e),this.optionsDisplayed=!1,null===(i=this.mainPanel)||void 0===i||i.focus())}selectOption(t){this.selectedOption=t;for(let e of this.options)e.selected=e===t}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.hideOptions)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.hideOptions)}}
|
|
522
|
+
`}updated(t){var e;super.updated(t),t.has("options")&&(this.selectedOption=this.options.filter((t=>t.selected))[0]),t.has("selectedOption")&&(this.optionsDisplayed=!1,this.dispatchEvent(new CustomEvent("change",{detail:null===(e=this.selectedOption)||void 0===e?void 0:e.value}))),t.has("optionsDisplayed")&&this.fixedMenuPosition&&this.hasOptionsMenuOpen&&this.positionOptionsMenu()}positionOptionsMenu(){this.optionsMenu.style.top=this.mainPanel.getBoundingClientRect().top+this.mainPanel.getBoundingClientRect().height+"px",this.optionsMenu.style.left=this.mainPanel.getBoundingClientRect().left+"px",this.optionsMenu.style.minWidth=this.mainPanel.getBoundingClientRect().width+"px"}contentAvailableCallback(t){var e,i;t.has("focusOptions")&&this.focusOptions&&(null===(i=null!==(e=this.selectedOptionElement)&&void 0!==e?e:this.firstOption)||void 0===i||i.focus(),this.focusOptions=!1)}get hasOptionsMenuOpen(){return!this.disabled&&this.optionsDisplayed&&this.hasOptions}get hasOptions(){return this.options.length>0}updateOptionsFromSlot(t){var e;t.stopPropagation();let i=null===(e=this.optionsSlot)||void 0===e?void 0:e.assignedElements().map((t=>t));i&&i.length>0&&(this.options=i)}onMainPanelKeyDown(t){switch(t.key){case" ":t.preventDefault(),t.stopPropagation();case"Enter":this.optionsDisplayed=!this.optionsDisplayed,this.focusOptions=!0;break;case"ArrowUp":case"ArrowDown":t.preventDefault(),t.stopPropagation(),this.optionsDisplayed=!0,this.focusOptions=!0}}onOptionsKeyDown(t){var e,i,o,n,s;let r;switch(t.key){case"Escape":this.optionsDisplayed=!1,null===(e=this.mainPanel)||void 0===e||e.focus();break;case"Tab":this.optionsDisplayed=!1;break;case"ArrowUp":t.preventDefault(),t.stopPropagation(),r=null!==(o=null===(i=this.focusedOption)||void 0===i?void 0:i.previousElementSibling)&&void 0!==o?o:this.lastOption;break;case"ArrowDown":t.preventDefault(),t.stopPropagation(),r=null!==(s=null===(n=this.focusedOption)||void 0===n?void 0:n.nextElementSibling)&&void 0!==s?s:this.firstOption}null==r||r.focus()}onOptionKeyDown(t,e){var i;"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),t.stopPropagation(),this.selectOption(e),this.optionsDisplayed=!1,null===(i=this.mainPanel)||void 0===i||i.focus())}selectOption(t){this.selectedOption=t;for(let e of this.options)e.selected=e===t}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.hideOptions)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.hideOptions)}}xi.elementDefinitions={"ft-input-label":Je,"ft-typography":Ve,"ft-ripple":ri,"ft-icon":fi},xi.styles=[Pe,He,b`
|
|
500
523
|
*:focus {
|
|
501
524
|
outline: none;
|
|
502
525
|
}
|
|
@@ -510,7 +533,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
510
533
|
.ft-select--main-panel {
|
|
511
534
|
position: relative;
|
|
512
535
|
display: flex;
|
|
513
|
-
height: calc(4 * ${
|
|
536
|
+
height: calc(4 * ${bi.verticalSpacing} + ${bi.labelSize} + ${bi.selectedOptionSize});
|
|
514
537
|
}
|
|
515
538
|
|
|
516
539
|
.ft-select--input-panel {
|
|
@@ -522,19 +545,24 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
522
545
|
padding-left: 16px;
|
|
523
546
|
padding-right: 8px;
|
|
524
547
|
gap: 8px;
|
|
525
|
-
color: ${
|
|
526
|
-
${
|
|
548
|
+
color: ${bi.selectedOptionColor};
|
|
549
|
+
${ht(Qe.color,bi.selectedOptionColor)};
|
|
527
550
|
}
|
|
528
551
|
|
|
529
552
|
.ft-select--input-panel,
|
|
530
553
|
.ft-select--option {
|
|
531
|
-
${
|
|
532
|
-
${
|
|
554
|
+
${ht(Qe.opacityContentOnSurfaceHover,"0.08")};
|
|
555
|
+
${ht(Qe.opacityContentOnSurfacePressed,"0.04")};
|
|
556
|
+
}
|
|
557
|
+
|
|
558
|
+
.ft-select--input-panel > *:not(ft-ripple),
|
|
559
|
+
.ft-select--option > *:not(ft-ripple) {
|
|
560
|
+
position: relative;
|
|
533
561
|
}
|
|
534
562
|
|
|
535
563
|
.ft-select--disabled .ft-select--input-panel,
|
|
536
564
|
.ft-select--disabled .ft-select--option {
|
|
537
|
-
color: ${
|
|
565
|
+
color: ${bi.colorOnSurfaceDisabled};
|
|
538
566
|
}
|
|
539
567
|
|
|
540
568
|
.ft-select:not(.ft-select--disabled) .ft-select--input-panel,
|
|
@@ -543,18 +571,18 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
543
571
|
}
|
|
544
572
|
|
|
545
573
|
ft-input-label {
|
|
546
|
-
${
|
|
547
|
-
${
|
|
548
|
-
${
|
|
574
|
+
${ht(Xe.fontSize,bi.selectedOptionSize)};
|
|
575
|
+
${ht(Xe.raisedFontSize,bi.labelSize)};
|
|
576
|
+
${ht(Xe.verticalSpacing,bi.verticalSpacing)};
|
|
549
577
|
}
|
|
550
578
|
|
|
551
579
|
.ft-select:not(.ft-select--disabled):focus-within ft-icon {
|
|
552
|
-
color: ${
|
|
580
|
+
color: ${bi.colorPrimary};
|
|
553
581
|
}
|
|
554
582
|
|
|
555
583
|
.ft-select:not(.ft-select--disabled):focus-within ft-input-label {
|
|
556
|
-
${
|
|
557
|
-
${
|
|
584
|
+
${ht(Xe.borderColor,bi.colorPrimary)};
|
|
585
|
+
${ht(Xe.textColor,bi.colorPrimary)};
|
|
558
586
|
}
|
|
559
587
|
|
|
560
588
|
.ft-select--selected-option {
|
|
@@ -564,8 +592,12 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
564
592
|
overflow: hidden;
|
|
565
593
|
white-space: nowrap;
|
|
566
594
|
text-overflow: ellipsis;
|
|
567
|
-
${
|
|
568
|
-
${
|
|
595
|
+
${ht(xe.fontSize,bi.selectedOptionSize)};
|
|
596
|
+
${ht(xe.lineHeight,bi.selectedOptionSize)};
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
.ft-select--in-error .ft-select--selected-option {
|
|
600
|
+
color: ${bi.colorError};
|
|
569
601
|
}
|
|
570
602
|
|
|
571
603
|
ft-icon {
|
|
@@ -577,16 +609,16 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
577
609
|
}
|
|
578
610
|
|
|
579
611
|
.ft-select--filled .ft-select--input-panel {
|
|
580
|
-
border-radius: ${
|
|
612
|
+
border-radius: ${bi.borderRadiusS} ${bi.borderRadiusS} 0 0;
|
|
581
613
|
}
|
|
582
614
|
|
|
583
615
|
.ft-select--filled:not(.ft-select--no-label) .ft-select--selected-option {
|
|
584
616
|
align-self: stretch;
|
|
585
|
-
padding-top: calc(${
|
|
617
|
+
padding-top: calc(${bi.labelSize} + 2 * ${bi.verticalSpacing});
|
|
586
618
|
}
|
|
587
619
|
|
|
588
620
|
.ft-select--outlined .ft-select--input-panel {
|
|
589
|
-
border-radius: ${
|
|
621
|
+
border-radius: ${bi.borderRadiusS};
|
|
590
622
|
}
|
|
591
623
|
|
|
592
624
|
.ft-select--options {
|
|
@@ -595,10 +627,16 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
595
627
|
top: 100%;
|
|
596
628
|
left: 0;
|
|
597
629
|
right: 0;
|
|
598
|
-
color: ${
|
|
599
|
-
background: ${
|
|
600
|
-
z-index: ${
|
|
601
|
-
box-shadow: ${
|
|
630
|
+
color: ${bi.optionsColor};
|
|
631
|
+
background: ${bi.colorSurface};
|
|
632
|
+
z-index: ${bi.optionsZIndex};
|
|
633
|
+
box-shadow: ${bi.elevation02};
|
|
634
|
+
}
|
|
635
|
+
|
|
636
|
+
.ft-select--fixed .ft-select--options {
|
|
637
|
+
position: fixed;
|
|
638
|
+
right: unset;
|
|
639
|
+
/* left and top are set dynamically */
|
|
602
640
|
}
|
|
603
641
|
|
|
604
642
|
.ft-select--options-displayed .ft-select--options {
|
|
@@ -615,44 +653,48 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
615
653
|
|
|
616
654
|
.ft-select--helper-text {
|
|
617
655
|
padding: 0 12px 0 16px;
|
|
618
|
-
color: ${
|
|
656
|
+
color: ${bi.helperColor};
|
|
657
|
+
}
|
|
658
|
+
|
|
659
|
+
.ft-select--in-error .ft-select--helper-text {
|
|
660
|
+
color: ${bi.colorError};
|
|
619
661
|
}
|
|
620
|
-
`],
|
|
662
|
+
`],hi([o({type:String})],xi.prototype,"label",void 0),hi([o({type:String})],xi.prototype,"helper",void 0),hi([o({type:Boolean})],xi.prototype,"outlined",void 0),hi([o({type:Boolean})],xi.prototype,"disabled",void 0),hi([o({type:Boolean})],xi.prototype,"error",void 0),hi([o({type:Boolean})],xi.prototype,"fixedMenuPosition",void 0),hi([o({type:Array})],xi.prototype,"options",void 0),hi([n()],xi.prototype,"selectedOption",void 0),hi([n()],xi.prototype,"optionsDisplayed",void 0),hi([n()],xi.prototype,"focusOptions",void 0),hi([r(".ft-select")],xi.prototype,"container",void 0),hi([r(".ft-select--options")],xi.prototype,"optionsMenu",void 0),hi([r(".ft-select--input-panel")],xi.prototype,"mainPanel",void 0),hi([r(".ft-select--option:first-child")],xi.prototype,"firstOption",void 0),hi([r(".ft-select--option:focus")],xi.prototype,"focusedOption",void 0),hi([r(".ft-select--option.ft-select--option-selected")],xi.prototype,"selectedOptionElement",void 0),hi([r(".ft-select--option:last-child")],xi.prototype,"lastOption",void 0),hi([r("slot")],xi.prototype,"optionsSlot",void 0),p("ft-select")(xi),p("ft-select-option")(ui);var vi=function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(n=t[l])&&(r=(s<3?n(r):s>3?n(e,i,r):n(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r};const yi={fontSize:ft.create("--ft-text-field-font-size","SIZE","14px"),labelSize:ft.create("--ft-text-field-label-size","SIZE","11px"),verticalSpacing:ft.create("--ft-text-field-vertical-spacing","SIZE","4px"),horizontalSpacing:ft.create("--ft-text-field-horizontal-spacing","SIZE","16px"),helperColor:ft.extend("--ft-text-field-helper-color",ut.colorOnSurfaceMedium),colorPrimary:ft.external(ut.colorPrimary,"Design system"),colorOnSurface:ft.external(ut.colorOnSurface,"Design system"),colorOnSurfaceDisabled:ft.external(ut.colorOnSurfaceDisabled,"Design system"),borderRadiusS:ft.external(ut.borderRadiusS,"Design system"),colorError:ft.external(ut.colorError,"Design system"),prefixColor:ft.extend("--ft-text-field-prefix-color",ut.colorOnSurfaceMedium),iconColor:ft.extend("--ft-text-field-icon-color",ut.colorOnSurfaceMedium)};class gi extends bt{constructor(){super(...arguments),this.label="",this.value="",this.helper="",this.outlined=!1,this.disabled=!1,this.error=!1,this.prefix="",this.icon="",this.iconVariant="",this.focused=!1}focus(){var t;null===(t=this.input)||void 0===t||t.focus()}render(){const t={"ft-text-field":!0,"ft-text-field--filled":!this.outlined,"ft-text-field--outlined":this.outlined,"ft-text-field--disabled":this.disabled,"ft-text-field--has-value":!!this.value,"ft-text-field--no-label":!this.label,"ft-text-field--in-error":this.error,"ft-text-field--with-prefix":!!this.prefix,"ft-text-field--raised-label":this.focused||""!=this.value};return W`
|
|
621
663
|
<div class="${Dt(t)}">
|
|
622
664
|
<div class="ft-text-field--main-panel">
|
|
623
665
|
<ft-input-label text="${this.label}"
|
|
624
666
|
?disabled=${this.disabled}
|
|
625
667
|
?outlined=${this.outlined}
|
|
626
668
|
?raised=${this.focused||""!=this.value}
|
|
669
|
+
?error=${this.error}
|
|
627
670
|
></ft-input-label>
|
|
628
671
|
<div class="ft-text-field--input-panel"
|
|
629
672
|
aria-label="${this.label}">
|
|
630
673
|
${this.outlined?null:W`
|
|
631
674
|
<ft-ripple ?disabled=${this.disabled} activated></ft-ripple>
|
|
632
675
|
`}
|
|
633
|
-
<
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
676
|
+
<div class="ft-text-field--input-wrapper">
|
|
677
|
+
<ft-typography class="ft-text-field--prefix" vaiant="body1">${this.prefix}</ft-typography>
|
|
678
|
+
<input type="text"
|
|
679
|
+
class="ft-typography--body1 ft-text-field--input"
|
|
680
|
+
?disabled=${this.disabled}
|
|
681
|
+
.value=${this.value}
|
|
682
|
+
@change=${this.updateValueFromInputField}
|
|
683
|
+
@keyup=${this.liveUpdateValueFromInputField}
|
|
684
|
+
@focus=${()=>this.focused=!0}
|
|
685
|
+
@focusout=${()=>this.focused=!1}
|
|
686
|
+
/>
|
|
687
|
+
</div>
|
|
688
|
+
${this.icon?W`
|
|
689
|
+
<ft-icon class="ft-text-field--icon" variant="${this.iconVariant}">${this.icon}
|
|
690
|
+
</ft-icon>`:void 0}
|
|
649
691
|
</div>
|
|
650
692
|
</div>
|
|
651
693
|
${this.helper?W`
|
|
652
694
|
<ft-typography class="ft-text-field--helper-text" variant="caption">${this.helper}
|
|
653
695
|
</ft-typography>`:void 0}
|
|
654
696
|
</div>
|
|
655
|
-
`}updated(t){super.updated(t),t.has("value")&&this.dispatchEvent(new CustomEvent("live-change",{detail:this.value}))}updateValueFromInputField(){var t;this.value=(null===(t=this.input)||void 0===t?void 0:t.value)||"",this.dispatchEvent(new CustomEvent("change",{detail:this.value}))}liveUpdateValueFromInputField(){var t;this.value=(null===(t=this.input)||void 0===t?void 0:t.value)||""}}
|
|
697
|
+
`}updated(t){super.updated(t),t.has("value")&&this.dispatchEvent(new CustomEvent("live-change",{detail:this.value}))}updateValueFromInputField(){var t;this.value=(null===(t=this.input)||void 0===t?void 0:t.value)||"",this.dispatchEvent(new CustomEvent("change",{detail:this.value}))}liveUpdateValueFromInputField(){var t;this.value=(null===(t=this.input)||void 0===t?void 0:t.value)||""}}gi.elementDefinitions={"ft-input-label":Je,"ft-ripple":ri,"ft-typography":Ve,"ft-icon":fi},gi.styles=[_e,b`
|
|
656
698
|
*:focus {
|
|
657
699
|
outline: none;
|
|
658
700
|
}
|
|
@@ -664,16 +706,16 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
664
706
|
}
|
|
665
707
|
|
|
666
708
|
ft-input-label {
|
|
667
|
-
${
|
|
668
|
-
${
|
|
669
|
-
${
|
|
670
|
-
${
|
|
709
|
+
${ht(Xe.fontSize,yi.fontSize)};
|
|
710
|
+
${ht(Xe.raisedFontSize,yi.labelSize)};
|
|
711
|
+
${ht(Xe.verticalSpacing,yi.verticalSpacing)};
|
|
712
|
+
${ht(Xe.horizontalSpacing,b`calc(${yi.horizontalSpacing} - 4px)`)};
|
|
671
713
|
}
|
|
672
714
|
|
|
673
715
|
.ft-text-field--main-panel {
|
|
674
716
|
position: relative;
|
|
675
717
|
display: flex;
|
|
676
|
-
height: calc(4 * ${
|
|
718
|
+
height: calc(4 * ${yi.verticalSpacing} + ${yi.labelSize} + ${yi.fontSize});
|
|
677
719
|
}
|
|
678
720
|
|
|
679
721
|
.ft-text-field--input-panel {
|
|
@@ -682,37 +724,65 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
682
724
|
display: flex;
|
|
683
725
|
align-items: center;
|
|
684
726
|
overflow: hidden;
|
|
685
|
-
gap: 8px;
|
|
686
727
|
}
|
|
687
728
|
|
|
688
729
|
.ft-text-field--input-panel ft-ripple {
|
|
689
|
-
${
|
|
690
|
-
${
|
|
730
|
+
${ht(Qe.opacityContentOnSurfaceHover,"0.08")};
|
|
731
|
+
${ht(Qe.opacityContentOnSurfacePressed,"0.04")};
|
|
732
|
+
}
|
|
733
|
+
|
|
734
|
+
.ft-text-field--input-wrapper {
|
|
735
|
+
flex-grow: 1;
|
|
736
|
+
flex-shrink: 1;
|
|
737
|
+
|
|
738
|
+
display: flex;
|
|
739
|
+
align-items: center;
|
|
740
|
+
|
|
741
|
+
${ht(xe.fontSize,yi.fontSize)};
|
|
742
|
+
${ht(xe.lineHeight,yi.fontSize)};
|
|
743
|
+
|
|
744
|
+
padding: 0 ${yi.horizontalSpacing};
|
|
745
|
+
}
|
|
746
|
+
|
|
747
|
+
.ft-text-field--filled:not(.ft-text-field--no-label) .ft-text-field--input-wrapper {
|
|
748
|
+
align-items: flex-end;
|
|
749
|
+
padding: 0 ${yi.horizontalSpacing} ${yi.verticalSpacing} ${yi.horizontalSpacing};
|
|
750
|
+
}
|
|
751
|
+
|
|
752
|
+
.ft-text-field--prefix {
|
|
753
|
+
display: none;
|
|
754
|
+
color: ${yi.prefixColor}
|
|
755
|
+
}
|
|
756
|
+
|
|
757
|
+
.ft-text-field--with-prefix.ft-text-field--raised-label .ft-text-field--prefix {
|
|
758
|
+
display: block;
|
|
691
759
|
}
|
|
692
760
|
|
|
693
761
|
.ft-text-field--input {
|
|
694
762
|
display: block;
|
|
763
|
+
position: relative;
|
|
695
764
|
flex-grow: 1;
|
|
696
765
|
flex-shrink: 1;
|
|
697
766
|
min-width: 0; /* flex sets this to auto an prevents input from shrinking properly */
|
|
698
767
|
|
|
699
|
-
${
|
|
700
|
-
${
|
|
701
|
-
color: ${pi.colorOnSurface};
|
|
702
|
-
|
|
703
|
-
padding: 0 ${pi.horizontalSpacing};
|
|
704
|
-
|
|
768
|
+
color: ${yi.colorOnSurface};
|
|
769
|
+
padding: calc(2 * ${yi.verticalSpacing}) 0;
|
|
705
770
|
border: none;
|
|
706
771
|
background: none;
|
|
707
772
|
}
|
|
708
773
|
|
|
774
|
+
.ft-text-field--filled:not(.ft-text-field--no-label) .ft-text-field--input {
|
|
775
|
+
padding-bottom: 0;
|
|
776
|
+
padding-top: calc(${yi.labelSize} + 2 * ${yi.verticalSpacing});
|
|
777
|
+
}
|
|
778
|
+
|
|
709
779
|
.ft-text-field--input::-webkit-calendar-picker-indicator,
|
|
710
780
|
.ft-text-field--input::-webkit-list-button {
|
|
711
781
|
display: none !important;
|
|
712
782
|
}
|
|
713
783
|
|
|
714
784
|
.ft-text-field--disabled .ft-text-field--input {
|
|
715
|
-
color: ${
|
|
785
|
+
color: ${yi.colorOnSurfaceDisabled};
|
|
716
786
|
}
|
|
717
787
|
|
|
718
788
|
.ft-text-field:not(.ft-text-field--disabled) .ft-text-field--input-panel {
|
|
@@ -720,29 +790,34 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
720
790
|
}
|
|
721
791
|
|
|
722
792
|
.ft-text-field:not(.ft-text-field--disabled):focus-within ft-input-label {
|
|
723
|
-
${
|
|
724
|
-
${
|
|
793
|
+
${ht(Xe.borderColor,yi.colorPrimary)};
|
|
794
|
+
${ht(Xe.textColor,yi.colorPrimary)};
|
|
725
795
|
}
|
|
726
796
|
|
|
727
797
|
.ft-text-field--filled .ft-text-field--input-panel {
|
|
728
|
-
border-radius: ${
|
|
729
|
-
}
|
|
730
|
-
|
|
731
|
-
.ft-text-field--filled:not(.ft-text-field--no-label) .ft-text-field--input {
|
|
732
|
-
align-self: stretch;
|
|
733
|
-
padding-bottom: ${pi.verticalSpacing};
|
|
734
|
-
padding-top: calc(${pi.labelSize} + 2 * ${pi.verticalSpacing});
|
|
798
|
+
border-radius: ${yi.borderRadiusS} ${yi.borderRadiusS} 0 0;
|
|
735
799
|
}
|
|
736
800
|
|
|
737
801
|
.ft-text-field--outlined .ft-text-field--input-panel {
|
|
738
|
-
border-radius: ${
|
|
802
|
+
border-radius: ${yi.borderRadiusS};
|
|
739
803
|
}
|
|
740
804
|
|
|
741
805
|
.ft-text-field--helper-text {
|
|
742
|
-
padding: 0 12px 0 ${
|
|
743
|
-
color: ${
|
|
806
|
+
padding: 0 12px 0 ${yi.horizontalSpacing};
|
|
807
|
+
color: ${yi.helperColor};
|
|
808
|
+
}
|
|
809
|
+
|
|
810
|
+
.ft-text-field--in-error .ft-text-field--input,
|
|
811
|
+
.ft-text-field--in-error .ft-text-field--helper-text,
|
|
812
|
+
.ft-text-field--in-error .ft-text-field--prefix {
|
|
813
|
+
color: ${yi.colorError};
|
|
744
814
|
}
|
|
745
|
-
|
|
815
|
+
|
|
816
|
+
.ft-text-field--icon {
|
|
817
|
+
padding-right: ${yi.horizontalSpacing};
|
|
818
|
+
color: ${yi.iconColor};
|
|
819
|
+
}
|
|
820
|
+
`],vi([o({type:String})],gi.prototype,"label",void 0),vi([o({reflect:!0})],gi.prototype,"value",void 0),vi([o({type:String})],gi.prototype,"helper",void 0),vi([o({type:Boolean})],gi.prototype,"outlined",void 0),vi([o({type:Boolean})],gi.prototype,"disabled",void 0),vi([o({type:Boolean})],gi.prototype,"error",void 0),vi([r(".ft-text-field--input")],gi.prototype,"input",void 0),vi([o({type:String})],gi.prototype,"prefix",void 0),vi([o({type:String})],gi.prototype,"icon",void 0),vi([o({type:String})],gi.prototype,"iconVariant",void 0),vi([n()],gi.prototype,"focused",void 0),p("ft-text-field")(gi);var mi=function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(n=t[l])&&(r=(s<3?n(r):s>3?n(e,i,r):n(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r};const $i=ft.create("--ft-tooltip-distance","SIZE","4px"),wi=ft.create("--ft-tooltip-color","COLOR","#FFFFFF"),Oi=ft.create("--ft-tooltip-background-color","COLOR","#666666"),Si=ft.create("--ft-tooltip-z-index","NUMBER","1"),ki=ft.external(ut.borderRadiusS,"Design system");class Ci extends bt{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.hideDebounce=new e,this.revealDebouncer=new e}render(){return W`
|
|
746
821
|
<div part="container"
|
|
747
822
|
class="ft-tooltip--container ${this.inline?"ft-tooltip--inline":""}"
|
|
748
823
|
@mouseenter=${this.onHover}
|
|
@@ -757,7 +832,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
757
832
|
</div>
|
|
758
833
|
<slot></slot>
|
|
759
834
|
</div>
|
|
760
|
-
`}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){t.has("visible")&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.position){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const e=t.getBoundingClientRect(),i=(e.height-this.tooltip.clientHeight)/2,o=(e.width-this.tooltip.clientWidth)/2,n=this.tooltip.style;switch(this.position){case"top":n.top=-this.tooltip.clientHeight+"px",n.left=o+"px";break;case"bottom":n.top=e.height+"px",n.left=o+"px";break;case"left":n.top=i+"px",n.left=-this.tooltip.clientWidth+"px";break;case"right":n.top=i+"px",n.left=e.width+"px"}n.maxWidth=Math.max(e.width,150)+"px"}this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}}
|
|
835
|
+
`}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){t.has("visible")&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.position){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const e=t.getBoundingClientRect(),i=(e.height-this.tooltip.clientHeight)/2,o=(e.width-this.tooltip.clientWidth)/2,n=this.tooltip.style;switch(this.position){case"top":n.top=-this.tooltip.clientHeight+"px",n.left=o+"px";break;case"bottom":n.top=e.height+"px",n.left=o+"px";break;case"left":n.top=i+"px",n.left=-this.tooltip.clientWidth+"px";break;case"right":n.top=i+"px",n.left=e.width+"px"}n.maxWidth=Math.max(e.width,150)+"px"}this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}}Ci.elementDefinitions={"ft-typography":Ve},Ci.styles=b`
|
|
761
836
|
.ft-tooltip--container {
|
|
762
837
|
display: block;
|
|
763
838
|
position: relative;
|
|
@@ -775,27 +850,27 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
775
850
|
width: max-content;
|
|
776
851
|
max-width: 150px;
|
|
777
852
|
text-align: center;
|
|
778
|
-
padding: ${
|
|
779
|
-
z-index: ${
|
|
853
|
+
padding: ${$i};
|
|
854
|
+
z-index: ${Si};
|
|
780
855
|
}
|
|
781
856
|
|
|
782
857
|
.ft-tooltip--content {
|
|
783
858
|
padding: 4px 8px;
|
|
784
|
-
border-radius: ${
|
|
785
|
-
background-color: ${
|
|
786
|
-
color: ${
|
|
859
|
+
border-radius: ${ki};
|
|
860
|
+
background-color: ${Oi};
|
|
861
|
+
color: ${wi};
|
|
787
862
|
top: -500px;
|
|
788
863
|
left: -500px;
|
|
789
864
|
position: relative;
|
|
790
865
|
word-break: break-word;
|
|
791
866
|
}
|
|
792
|
-
`,
|
|
867
|
+
`,mi([o()],Ci.prototype,"text",void 0),mi([o({type:Boolean})],Ci.prototype,"manual",void 0),mi([o({type:Boolean})],Ci.prototype,"inline",void 0),mi([o({type:Number})],Ci.prototype,"delay",void 0),mi([o()],Ci.prototype,"position",void 0),mi([
|
|
793
868
|
/**
|
|
794
869
|
* @license
|
|
795
870
|
* Copyright 2017 Google LLC
|
|
796
871
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
797
872
|
*/
|
|
798
|
-
function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},i?function(t){const{slot:e,selector:i}=null!=t?t:{};return s({descriptor:o=>({get(){var o;const n="slot"+(e?`[name=${e}]`:":not([name])"),s=null===(o=this.renderRoot)||void 0===o?void 0:o.querySelector(n),r=null!=s?a(s,t):[];return i?r.filter((t=>t.matches(i))):r},enumerable:!0,configurable:!0})})}({slot:n,flatten:e,selector:i}):s({descriptor:t=>({get(){var t,e;const i="slot"+(n?`[name=${n}]`:":not([name])"),s=null===(t=this.renderRoot)||void 0===t?void 0:t.querySelector(i);return null!==(e=null==s?void 0:s.assignedNodes(o))&&void 0!==e?e:[]},enumerable:!0,configurable:!0})})}("",!0)],
|
|
873
|
+
function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},i?function(t){const{slot:e,selector:i}=null!=t?t:{};return s({descriptor:o=>({get(){var o;const n="slot"+(e?`[name=${e}]`:":not([name])"),s=null===(o=this.renderRoot)||void 0===o?void 0:o.querySelector(n),r=null!=s?a(s,t):[];return i?r.filter((t=>t.matches(i))):r},enumerable:!0,configurable:!0})})}({slot:n,flatten:e,selector:i}):s({descriptor:t=>({get(){var t,e;const i="slot"+(n?`[name=${n}]`:":not([name])"),s=null===(t=this.renderRoot)||void 0===t?void 0:t.querySelector(i);return null!==(e=null==s?void 0:s.assignedNodes(o))&&void 0!==e?e:[]},enumerable:!0,configurable:!0})})}("",!0)],Ci.prototype,"slotNodes",void 0),mi([r(".ft-tooltip--container")],Ci.prototype,"container",void 0),mi([r("slot")],Ci.prototype,"target",void 0),mi([r(".ft-tooltip")],Ci.prototype,"tooltip",void 0),mi([r(".ft-tooltip--content")],Ci.prototype,"tooltipContent",void 0),mi([n()],Ci.prototype,"visible",void 0),p("ft-tooltip")(Ci);const Ei={color:ft.extend("--ft-loader-color",ut.colorPrimary),size:ft.create("--ft-loader-size","SIZE","80px")};class Ni extends bt{static get styles(){return b`
|
|
799
874
|
:host {
|
|
800
875
|
line-height: 0;
|
|
801
876
|
}
|
|
@@ -804,8 +879,8 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
804
879
|
display: inline-block;
|
|
805
880
|
position: relative;
|
|
806
881
|
|
|
807
|
-
width: ${
|
|
808
|
-
height: ${
|
|
882
|
+
width: ${Ei.size};
|
|
883
|
+
height: ${Ei.size};
|
|
809
884
|
}
|
|
810
885
|
|
|
811
886
|
.ft-loader div {
|
|
@@ -814,7 +889,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
814
889
|
width: 25%;
|
|
815
890
|
height: 25%;
|
|
816
891
|
border-radius: 50%;
|
|
817
|
-
background: ${
|
|
892
|
+
background: ${Ei.color};
|
|
818
893
|
animation-timing-function: cubic-bezier(0, 1, 1, 0);
|
|
819
894
|
}
|
|
820
895
|
|
|
@@ -861,7 +936,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
861
936
|
transform: translate(0, 0);
|
|
862
937
|
}
|
|
863
938
|
100% {
|
|
864
|
-
transform: translate(calc(0.35 * ${
|
|
939
|
+
transform: translate(calc(0.35 * ${Ei.size}), 0);
|
|
865
940
|
}
|
|
866
941
|
}
|
|
867
942
|
`}render(){return W`
|
|
@@ -871,7 +946,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
871
946
|
<div></div>
|
|
872
947
|
<div></div>
|
|
873
948
|
</div>
|
|
874
|
-
`}}p("ft-loader")(
|
|
949
|
+
`}}p("ft-loader")(Ni);var Ri=function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(n=t[l])&&(r=(s<3?n(r):s>3?n(e,i,r):n(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r};const zi=ft.extend("--ft-button-color",ut.colorPrimary),Mi={backgroundColor:ft.extend("--ft-button-background-color",ut.colorSurface),borderRadius:ft.extend("--ft-button-border-radius",ut.borderRadiusL),color:zi,fontSize:ft.extend("--ft-button-font-size",je.fontSize),iconSize:ft.create("--ft-button-icon-size","SIZE","24px"),rippleColor:ft.extend("--ft-button-ripple-color",zi),opacityDisabled:ft.external(ut.colorOpacityDisabled,"Design system")},Fi=ft.extend("--ft-button-primary-color",ft.extend("--ft-button-color",ut.colorOnPrimary)),Ui={backgroundColor:ft.extend("--ft-button-primary-background-color",ft.extend("--ft-button-background-color",ut.colorPrimary)),color:Fi,rippleColor:ft.extend("--ft-button-primary-ripple-color",Fi)},Bi=ft.extend("--ft-button-dense-border-radius",ft.extend("--ft-button-border-radius",ut.borderRadiusM));class Di extends bt{constructor(){super(...arguments),this.primary=!1,this.outlined=!1,this.disabled=!1,this.dense=!1,this.round=!1,this.label="",this.icon=void 0,this.trailingIcon=!1,this.loading=!1,this.tooltipPosition="bottom",this.onclick=t=>{this.isDisabled()&&(t.preventDefault(),t.stopPropagation(),t.stopImmediatePropagation())}}static get styles(){return[xt,b`
|
|
875
950
|
:host {
|
|
876
951
|
display: inline-block;
|
|
877
952
|
max-width: 100%;
|
|
@@ -910,18 +985,18 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
910
985
|
border: none;
|
|
911
986
|
pointer-events: auto;
|
|
912
987
|
|
|
913
|
-
--ft-button-internal-font-size: ${
|
|
988
|
+
--ft-button-internal-font-size: ${Mi.fontSize};
|
|
914
989
|
--ft-button-internal-line-height: calc(var(--ft-button-internal-font-size) + 2px);
|
|
915
|
-
--ft-button-internal-color: ${
|
|
916
|
-
${
|
|
990
|
+
--ft-button-internal-color: ${Mi.color};
|
|
991
|
+
${ht(di.size,Mi.iconSize)};
|
|
917
992
|
--ft-button-internal-vertical-padding: 6px;
|
|
918
993
|
--ft-button-internal-horizontal-padding: 8px;
|
|
919
|
-
${
|
|
920
|
-
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height), ${
|
|
994
|
+
${ht(Qe.color,Mi.rippleColor)};
|
|
995
|
+
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height), ${Mi.iconSize});
|
|
921
996
|
|
|
922
|
-
border-radius: ${
|
|
997
|
+
border-radius: ${Mi.borderRadius};
|
|
923
998
|
padding: var(--ft-button-internal-vertical-padding) var(--ft-button-internal-horizontal-padding);
|
|
924
|
-
background-color: ${
|
|
999
|
+
background-color: ${Mi.backgroundColor};
|
|
925
1000
|
color: var(--ft-button-internal-color);
|
|
926
1001
|
-webkit-mask-image: radial-gradient(white, black);
|
|
927
1002
|
}
|
|
@@ -933,7 +1008,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
933
1008
|
.ft-button--dense {
|
|
934
1009
|
--ft-button-internal-vertical-padding: 2px;
|
|
935
1010
|
--ft-button-internal-horizontal-padding: 4px;
|
|
936
|
-
border-radius: ${
|
|
1011
|
+
border-radius: ${Bi};
|
|
937
1012
|
}
|
|
938
1013
|
|
|
939
1014
|
.ft-button--round {
|
|
@@ -942,13 +1017,13 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
942
1017
|
|
|
943
1018
|
.ft-button[disabled] {
|
|
944
1019
|
filter: grayscale(1);
|
|
945
|
-
opacity: ${
|
|
1020
|
+
opacity: ${Mi.opacityDisabled};
|
|
946
1021
|
}
|
|
947
1022
|
|
|
948
1023
|
.ft-button.ft-button--primary {
|
|
949
|
-
background-color: ${
|
|
950
|
-
--ft-button-internal-color: ${
|
|
951
|
-
${
|
|
1024
|
+
background-color: ${Ui.backgroundColor};
|
|
1025
|
+
--ft-button-internal-color: ${Ui.color};
|
|
1026
|
+
${ht(Qe.color,Ui.rippleColor)};
|
|
952
1027
|
}
|
|
953
1028
|
|
|
954
1029
|
.ft-button.ft-button--outlined {
|
|
@@ -961,13 +1036,14 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
961
1036
|
}
|
|
962
1037
|
|
|
963
1038
|
.ft-button--label {
|
|
1039
|
+
position: relative;
|
|
964
1040
|
overflow: hidden;
|
|
965
1041
|
white-space: nowrap;
|
|
966
1042
|
text-overflow: ellipsis;
|
|
967
1043
|
display: block;
|
|
968
1044
|
margin: 0 var(--ft-button-internal-horizontal-padding);
|
|
969
|
-
${
|
|
970
|
-
${
|
|
1045
|
+
${ht(je.fontSize,"var(--ft-button-internal-font-size)")};
|
|
1046
|
+
${ht(je.lineHeight,"var(--ft-button-internal-content-height)")};
|
|
971
1047
|
}
|
|
972
1048
|
|
|
973
1049
|
.ft-button--safari-fix .ft-button--label {
|
|
@@ -986,6 +1062,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
986
1062
|
|
|
987
1063
|
ft-icon {
|
|
988
1064
|
flex-shrink: 0;
|
|
1065
|
+
position: relative;
|
|
989
1066
|
}
|
|
990
1067
|
|
|
991
1068
|
.ft-button--label[hidden] + ft-icon {
|
|
@@ -999,8 +1076,8 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
999
1076
|
}
|
|
1000
1077
|
|
|
1001
1078
|
ft-loader {
|
|
1002
|
-
${
|
|
1003
|
-
${
|
|
1079
|
+
${ht(Ei.size,Mi.iconSize)};
|
|
1080
|
+
${ht(Ei.color,"var(--ft-button-internal-color)")};
|
|
1004
1081
|
}
|
|
1005
1082
|
`]}render(){const t={"ft-button":!0,"ft-button--primary":this.primary,"ft-button--outlined":this.outlined,"ft-button--dense":this.dense,"ft-button--round":this.round,"ft-button--trailing-icon":this.trailingIcon,"ft-button--loading":this.trailingIcon,"ft-button--safari-fix":mt,"ft-no-text-select":!0};return this.addTooltip(W`
|
|
1006
1083
|
<button part="button"
|
|
@@ -1024,7 +1101,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1024
1101
|
</ft-tooltip>
|
|
1025
1102
|
`}resolveIcon(){return this.loading?W`
|
|
1026
1103
|
<ft-loader></ft-loader> `:this.icon?W`
|
|
1027
|
-
<ft-icon variant="material">${this.icon}</ft-icon> `:K}focus(){var t;null===(t=this.button)||void 0===t||t.focus()}getLabel(){return this.label||this.textContent}get textContent(){return this.unslotText(this.slottedContent).trim()}unslotText(t){return t instanceof HTMLSlotElement?t.assignedNodes().map((t=>this.unslotText(t))).join(""):(null==t?void 0:t.textContent)||""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}isDisabled(){return this.disabled||this.loading}}
|
|
1104
|
+
<ft-icon variant="material">${this.icon}</ft-icon> `:K}focus(){var t;null===(t=this.button)||void 0===t||t.focus()}getLabel(){return this.label||this.textContent}get textContent(){return this.unslotText(this.slottedContent).trim()}unslotText(t){return t instanceof HTMLSlotElement?t.assignedNodes().map((t=>this.unslotText(t))).join(""):(null==t?void 0:t.textContent)||""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}isDisabled(){return this.disabled||this.loading}}Di.elementDefinitions={"ft-ripple":ri,"ft-tooltip":Ci,"ft-typography":Ve,"ft-icon":fi,"ft-loader":Ni},Ri([o({type:Boolean})],Di.prototype,"primary",void 0),Ri([o({type:Boolean})],Di.prototype,"outlined",void 0),Ri([o({type:Boolean})],Di.prototype,"disabled",void 0),Ri([o({type:Boolean})],Di.prototype,"dense",void 0),Ri([o({type:Boolean})],Di.prototype,"round",void 0),Ri([o({type:String})],Di.prototype,"label",void 0),Ri([o({type:String})],Di.prototype,"icon",void 0),Ri([o({type:Boolean})],Di.prototype,"trailingIcon",void 0),Ri([o({type:Boolean})],Di.prototype,"loading",void 0),Ri([o({type:String})],Di.prototype,"tooltipPosition",void 0),Ri([r(".ft-button")],Di.prototype,"button",void 0),Ri([r(".ft-button--label slot")],Di.prototype,"slottedContent",void 0),p("ft-button")(Di);var ji=function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(n=t[l])&&(r=(s<3?n(r):s>3?n(e,i,r):n(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r};class Ti extends CustomEvent{constructor(t){super("row-click",{detail:t})}}const Li={headerBackground:ft.create("--ft-filterable-table-header-background","COLOR","whitesmoke"),oddRowBackground:ft.create("--ft-filterable-table-odd-row-background","COLOR","#FFFFFF"),evenRowBackground:ft.create("--ft-filterable-table-even-row-background","COLOR","#fdfdfd"),rowHoverBackground:ft.create("--ft-filterable-table-row-hover-background","COLOR","#fafafa"),stickyHeaderZIndex:ft.create("--ft-filterable-table-sticky-header-zindex","NUMBER","100"),colorOnSurfaceHigh:ft.external(ut.colorOnSurfaceHigh,"Design system"),titleFont:ft.external(ut.titleFont,"Design system"),contentFont:ft.external(ut.contentFont,"Design system")},Ai=t=>W`${t}`,Ii=(t,e)=>t-e;class _i extends bt{constructor(){super(...arguments),this.data=[],this.columns=[],this.stickyHeaders=!1,this.filters=[],this.selectData=[]}init(t,e,i){this.data=t,this.columns=e,this.sort=i}render(){let t=this.sortData(this.filterData());return W`
|
|
1028
1105
|
<style>
|
|
1029
1106
|
.table {
|
|
1030
1107
|
grid-template-columns: repeat(${this.columns.length}, minmax(min-content, auto));
|
|
@@ -1036,12 +1113,12 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1036
1113
|
</div>
|
|
1037
1114
|
${Ft(t,((t,e)=>"row-"+e),((t,e)=>W`
|
|
1038
1115
|
<div class="row"
|
|
1039
|
-
@click=${()=>this.dispatchEvent(new
|
|
1116
|
+
@click=${()=>this.dispatchEvent(new Ti(t))}>
|
|
1040
1117
|
${Ft(this.columns,((t,i)=>"cell-"+e+" "+i),(i=>this.renderCell(i,t,e)))}
|
|
1041
1118
|
</div>
|
|
1042
1119
|
`))}
|
|
1043
1120
|
</div>
|
|
1044
|
-
`}filterData(){let t=[...this.data];return this.filters.forEach(((e,i)=>{var o;const n=this.columns[i];if(e)switch(null!==(o=n.filter)&&void 0!==o?o:"text"){case"text":e.value&&(t=t.filter((t=>this.getValueAsString(n,t,i).toLowerCase().includes(e.value.toLowerCase()))));break;case"select":e.value&&(t=t.filter((t=>this.getValueAsString(n,t,i)===e.value)))}})),t}sortData(t){var e;if(this.currentSort){const i=this.columns[this.currentSort.column],o=null!==(e=i.comparator)&&void 0!==e?e:
|
|
1121
|
+
`}filterData(){let t=[...this.data];return this.filters.forEach(((e,i)=>{var o;const n=this.columns[i];if(e)switch(null!==(o=n.filter)&&void 0!==o?o:"text"){case"text":e.value&&(t=t.filter((t=>this.getValueAsString(n,t,i).toLowerCase().includes(e.value.toLowerCase()))));break;case"select":e.value&&(t=t.filter((t=>this.getValueAsString(n,t,i)===e.value)))}})),t}sortData(t){var e;if(this.currentSort){const i=this.columns[this.currentSort.column],o=null!==(e=i.comparator)&&void 0!==e?e:Ii,n="asc"===this.currentSort.order?o:(t,e)=>-o(t,e);return t.sort(((t,e)=>n(this.getValue(i,t),this.getValue(i,e))))}return t}update(t){super.update(t),t.has("sort")&&(this.currentSort=this.sort),(t.has("data")||t.has("columns"))&&this.updateSelectData()}updateSelectData(){this.selectData=[];const t=this.data,e=this.columns;for(let i in e){const o=e[i];"select"===o.filter&&(this.selectData[i]=[...new Set(t.map(((t,e)=>this.getValueAsString(o,t,e))))].sort(((t,e)=>t.localeCompare(e))))}this.requestUpdate()}renderHeader(t,e){const i={"header-cell":!0,"header-cell--sticky":this.stickyHeaders};return W`
|
|
1045
1122
|
<div class="${Dt(i)}">
|
|
1046
1123
|
<div class="column-title-container">
|
|
1047
1124
|
<span class="column-title">${t.title}</span>
|
|
@@ -1073,9 +1150,9 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1073
1150
|
<ft-select-option value="${t}" label="${t}"></ft-select-option>
|
|
1074
1151
|
`))}
|
|
1075
1152
|
</ft-select>
|
|
1076
|
-
`:null}return null}renderCell(t,e,i){var o;const n=null!==(o=t.render)&&void 0!==o?o:
|
|
1153
|
+
`:null}return null}renderCell(t,e,i){var o;const n=null!==(o=t.render)&&void 0!==o?o:Ai;return W`
|
|
1077
1154
|
<div class="cell">${(t=>{const e=n(t,i);return"string"==typeof e?Bt(e):e})(this.getValue(t,e))}</div>
|
|
1078
|
-
`}getValue(t,e){return"string"==typeof t.getter?e[t.getter]:t.getter(e)}getValueAsString(t,e,i){const o=this.getValue(t,e);return"function"==typeof t.stringify?t.stringify(o,i):(t=>""+t)(o)}}
|
|
1155
|
+
`}getValue(t,e){return"string"==typeof t.getter?e[t.getter]:t.getter(e)}getValueAsString(t,e,i){const o=this.getValue(t,e);return"function"==typeof t.stringify?t.stringify(o,i):(t=>""+t)(o)}}_i.styles=b`
|
|
1079
1156
|
:host {
|
|
1080
1157
|
display: block;
|
|
1081
1158
|
}
|
|
@@ -1091,15 +1168,15 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1091
1168
|
.header-cell {
|
|
1092
1169
|
display: flex;
|
|
1093
1170
|
flex-direction: column;
|
|
1094
|
-
background: ${
|
|
1095
|
-
color: ${
|
|
1171
|
+
background: ${Li.headerBackground};
|
|
1172
|
+
color: ${Li.colorOnSurfaceHigh};
|
|
1096
1173
|
padding: .5rem 1rem;
|
|
1097
|
-
font-family: ${
|
|
1174
|
+
font-family: ${Li.titleFont};
|
|
1098
1175
|
}
|
|
1099
1176
|
|
|
1100
1177
|
.header-cell--sticky {
|
|
1101
1178
|
top: 0;
|
|
1102
|
-
z-index: ${
|
|
1179
|
+
z-index: ${Li.stickyHeaderZIndex};
|
|
1103
1180
|
position: sticky;
|
|
1104
1181
|
}
|
|
1105
1182
|
|
|
@@ -1117,8 +1194,8 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1117
1194
|
}
|
|
1118
1195
|
|
|
1119
1196
|
.column-title-container ft-button {
|
|
1120
|
-
${
|
|
1121
|
-
${
|
|
1197
|
+
${ht(Mi.backgroundColor,Li.headerBackground)};
|
|
1198
|
+
${ht(Mi.color,Li.colorOnSurfaceHigh)};
|
|
1122
1199
|
}
|
|
1123
1200
|
|
|
1124
1201
|
.column-title {
|
|
@@ -1147,29 +1224,29 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1147
1224
|
|
|
1148
1225
|
.cell {
|
|
1149
1226
|
padding: 1rem;
|
|
1150
|
-
border-left: 1px solid ${
|
|
1151
|
-
border-bottom: 1px solid ${
|
|
1227
|
+
border-left: 1px solid ${Li.headerBackground};
|
|
1228
|
+
border-bottom: 1px solid ${Li.headerBackground};
|
|
1152
1229
|
overflow-x: auto;
|
|
1153
1230
|
display: flex;
|
|
1154
1231
|
align-items: center;
|
|
1155
|
-
font-family: ${
|
|
1232
|
+
font-family: ${Li.contentFont};
|
|
1156
1233
|
}
|
|
1157
1234
|
|
|
1158
1235
|
/* Even is 2n+1 and odd is 2n because of the header */
|
|
1159
1236
|
.row:nth-child(2n) > .cell {
|
|
1160
|
-
background: ${
|
|
1237
|
+
background: ${Li.oddRowBackground};
|
|
1161
1238
|
}
|
|
1162
1239
|
|
|
1163
1240
|
.row:nth-child(2n + 1) > .cell {
|
|
1164
|
-
background: ${
|
|
1241
|
+
background: ${Li.evenRowBackground};
|
|
1165
1242
|
}
|
|
1166
1243
|
|
|
1167
1244
|
.row:hover > .cell {
|
|
1168
|
-
background: ${
|
|
1245
|
+
background: ${Li.rowHoverBackground};
|
|
1169
1246
|
}
|
|
1170
1247
|
|
|
1171
1248
|
.cell:last-of-type {
|
|
1172
|
-
border-right: 1px solid ${
|
|
1249
|
+
border-right: 1px solid ${Li.headerBackground};
|
|
1173
1250
|
}
|
|
1174
1251
|
|
|
1175
1252
|
.row:last-of-type .cell:first-of-type {
|
|
@@ -1183,4 +1260,4 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1183
1260
|
.hidden {
|
|
1184
1261
|
visibility: hidden;
|
|
1185
1262
|
}
|
|
1186
|
-
`,
|
|
1263
|
+
`,ji([o({attribute:!1})],_i.prototype,"data",void 0),ji([o({attribute:!1})],_i.prototype,"columns",void 0),ji([o({attribute:!1})],_i.prototype,"sort",void 0),ji([o()],_i.prototype,"stickyHeaders",void 0),ji([n()],_i.prototype,"currentSort",void 0),p("ft-filterable-table")(_i),t.FtFilterableTable=_i,t.FtFilterableTableCssVariables=Li,t.RowClickEvent=Ti,Object.defineProperty(t,"t",{value:!0})}({});
|