@fluid-topics/ft-filterable-table 0.1.18 → 0.2.2
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.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
!function(t){
|
|
1
|
+
!function(t,e){
|
|
2
2
|
/**
|
|
3
3
|
* @license
|
|
4
4
|
* Copyright (c) 2020 The Polymer Project Authors. All rights reserved.
|
|
@@ -14,69 +14,64 @@
|
|
|
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||[]);h(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 f=this._awaitingUpgrade.get(t);if(f){this._awaitingUpgrade.delete(t);for(const t of f)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(){
|
|
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||[]);h(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 f=this._awaitingUpgrade.get(t);if(f){this._awaitingUpgrade.delete(t);for(const t of f)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)}},h=(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)})},f=e=>{const i=Object.getPrototypeOf(e);if(i!==window.HTMLElement)return i===t||"HTMLElement"===i?.prototype?.constructor?.name?Object.setPrototypeOf(e,window.HTMLElement):f(i)},u=(t,e,i=!1)=>{Object.setPrototypeOf(t,e.elementClass.prototype),n.set(t,e),a=t;try{new e.elementClass}catch(t){f(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(Bt){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 i{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
|
|
21
21
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
22
|
-
*/const
|
|
22
|
+
*/const o=(t,e)=>"method"===e.kind&&e.descriptor&&!("value"in e.descriptor)?{...e,finisher(i){i.createProperty(e.key,t)}}:{kind:"field",key:Symbol(),placement:"own",descriptor:{},originalKey:e.key,initializer(){"function"==typeof e.initializer&&(this[e.key]=e.initializer.call(this))},finisher(i){i.createProperty(e.key,t)}};function n(t){return(e,i)=>void 0!==i?((t,e,i)=>{e.constructor.createProperty(i,t)})(t,e,i):o(t,e)
|
|
23
23
|
/**
|
|
24
24
|
* @license
|
|
25
25
|
* Copyright 2017 Google LLC
|
|
26
26
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
27
|
-
*/function
|
|
27
|
+
*/}function s(t){return n({...t,state:!0})}
|
|
28
28
|
/**
|
|
29
29
|
* @license
|
|
30
30
|
* Copyright 2017 Google LLC
|
|
31
31
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
32
|
-
*/}
|
|
32
|
+
*/const r=({finisher:t,descriptor:e})=>(i,o)=>{var n;if(void 0===o){const o=null!==(n=i.originalKey)&&void 0!==n?n:i.key,s=null!=e?{kind:"method",placement:"prototype",key:o,descriptor:e(i.key)}:{...i,key:o};return null!=t&&(s.finisher=function(e){t(e,o)}),s}{const n=i.constructor;void 0!==e&&Object.defineProperty(i,o,e(o)),null==t||t(n,o)}}
|
|
33
33
|
/**
|
|
34
34
|
* @license
|
|
35
35
|
* Copyright 2017 Google LLC
|
|
36
36
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
37
|
-
|
|
38
|
-
/**
|
|
39
|
-
* @license
|
|
40
|
-
* Copyright 2017 Google LLC
|
|
41
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
42
|
-
*/;function r(t,e){return s({descriptor:i=>{const o={get(){var e,i;return null!==(i=null===(e=this.renderRoot)||void 0===e?void 0:e.querySelector(t))&&void 0!==i?i:null},enumerable:!0,configurable:!0};if(e){const e="symbol"==typeof i?Symbol():"__"+i;o.get=function(){var i,o;return void 0===this[e]&&(this[e]=null!==(o=null===(i=this.renderRoot)||void 0===i?void 0:i.querySelector(t))&&void 0!==o?o:null),this[e]}}return o}})}
|
|
37
|
+
*/;function l(t,e){return r({descriptor:i=>{const o={get(){var e,i;return null!==(i=null===(e=this.renderRoot)||void 0===e?void 0:e.querySelector(t))&&void 0!==i?i:null},enumerable:!0,configurable:!0};if(e){const e="symbol"==typeof i?Symbol():"__"+i;o.get=function(){var i,o;return void 0===this[e]&&(this[e]=null!==(o=null===(i=this.renderRoot)||void 0===i?void 0:i.querySelector(t))&&void 0!==o?o:null),this[e]}}return o}})}
|
|
43
38
|
/**
|
|
44
39
|
* @license
|
|
45
40
|
* Copyright 2021 Google LLC
|
|
46
41
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
47
|
-
*/var
|
|
42
|
+
*/var a;const p=null!=(null===(a=window.HTMLSlotElement)||void 0===a?void 0:a.prototype.assignedElements)?(t,e)=>t.assignedElements(e):(t,e)=>t.assignedNodes(e).filter((t=>t.nodeType===Node.ELEMENT_NODE));const c=t=>e=>{window.customElements.get(t)||window.customElements.define(t,e)}
|
|
48
43
|
/**
|
|
49
44
|
* @license
|
|
50
45
|
* Copyright 2019 Google LLC
|
|
51
46
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
52
|
-
*/,
|
|
47
|
+
*/,d=window.ShadowRoot&&(void 0===window.ShadyCSS||window.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,h=Symbol(),f=new Map;class u{constructor(t,e){if(this._$cssResult$=!0,e!==h)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t}get styleSheet(){let t=f.get(this.cssText);return d&&void 0===t&&(f.set(this.cssText,t=new CSSStyleSheet),t.replaceSync(this.cssText)),t}toString(){return this.cssText}}const b=t=>new u("string"==typeof t?t:t+"",h),x=(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 u(i,h)},v=(t,e)=>{d?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)}))},y=d?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return b(e)})(t):t
|
|
53
48
|
/**
|
|
54
49
|
* @license
|
|
55
50
|
* Copyright 2017 Google LLC
|
|
56
51
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
57
|
-
*/;var g;const
|
|
52
|
+
*/;var g;const m=window.trustedTypes,$=m?m.emptyScript:"",w=window.reactiveElementPolyfillSupport,O={toAttribute(t,e){switch(e){case Boolean:t=t?$: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}},S=(t,e)=>e!==t&&(e==e||t==t),k={attribute:!0,type:String,converter:O,reflect:!1,hasChanged:S};class C 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=k){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)||k}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(y(t))}else void 0!==t&&e.push(y(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 v(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=k){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:O.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:O.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||S)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),!0===i.reflect&&this._$Ei!==t&&(void 0===this._$E_&&(this._$E_=new Map),this._$E_.set(t,i))):o=!1),!this.isUpdatePending&&o&&(this._$Ep=this._$EC())}async _$EC(){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._$E_&&(this._$E_.forEach(((t,e)=>this._$ES(e,this[e],t))),this._$E_=void 0),this._$EU()}updated(t){}firstUpdated(t){}}
|
|
58
53
|
/**
|
|
59
54
|
* @license
|
|
60
55
|
* Copyright 2017 Google LLC
|
|
61
56
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
62
57
|
*/
|
|
63
|
-
var C
|
|
58
|
+
var E;C.finalized=!0,C.elementProperties=new Map,C.elementStyles=[],C.shadowRootOptions={mode:"open"},null==w||w({ReactiveElement:C}),(null!==(g=globalThis.reactiveElementVersions)&&void 0!==g?g:globalThis.reactiveElementVersions=[]).push("1.2.2");const N=globalThis.trustedTypes,R=N?N.createPolicy("lit-html",{createHTML:t=>t}):void 0,z=`lit$${(Math.random()+"").slice(9)}$`,M="?"+z,F=`<${M}>`,U=document,B=(t="")=>U.createComment(t),D=t=>null===t||"object"!=typeof t&&"function"!=typeof t,j=Array.isArray,T=t=>{var e;return j(t)||"function"==typeof(null===(e=t)||void 0===e?void 0:e[Symbol.iterator])},L=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,A=/-->/g,I=/>/g,_=/>|[ \n\r](?:([^\s"'>=/]+)([ \n\r]*=[ \n\r]*(?:[^ \n\r"'`<>=]|("|')|))|$)/g,P=/'/g,H=/"/g,W=/^(?:script|style|textarea|title)$/i,Z=(t=>(e,...i)=>({_$litType$:t,strings:e,values:i}))(1),K=Symbol.for("lit-noChange"),V=Symbol.for("lit-nothing"),q=new WeakMap,X=U.createTreeWalker(U,129,null,!1),J=(t,e)=>{const i=t.length-1,o=[];let n,s=2===e?"<svg>":"",r=L;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===L?"!--"===a[1]?r=A:void 0!==a[1]?r=I:void 0!==a[2]?(W.test(a[2])&&(n=RegExp("</"+a[2],"g")),r=_):void 0!==a[3]&&(r=_):r===_?">"===a[0]?(r=null!=n?n:L,p=-1):void 0===a[1]?p=-2:(p=r.lastIndex-a[2].length,l=a[1],r=void 0===a[3]?_:'"'===a[3]?H:P):r===H||r===P?r=_:r===A||r===I?r=L:(r=_,n=void 0);const d=r===_&&t[e+1].startsWith("/>")?" ":"";s+=r===L?i+F:p>=0?(o.push(l),i.slice(0,p)+"$lit$"+i.slice(p)+z+d):i+z+(-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!==R?R.createHTML(l):l,o]};class Y{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]=J(t,e);if(this.el=Y.createElement(a,i),X.currentNode=this.el.content,2===e){const t=this.el.content,e=t.firstChild;e.remove(),t.append(...e.childNodes)}for(;null!==(o=X.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(z)){const i=p[s++];if(t.push(e),void 0!==i){const t=o.getAttribute(i.toLowerCase()+"$lit$").split(z),e=/([.?@])?(.*)/.exec(i);l.push({type:1,index:n,name:e[2],strings:t,ctor:"."===e[1]?it:"?"===e[1]?nt:"@"===e[1]?st:et})}else l.push({type:6,index:n})}for(const e of t)o.removeAttribute(e)}if(W.test(o.tagName)){const t=o.textContent.split(z),e=t.length-1;if(e>0){o.textContent=N?N.emptyScript:"";for(let i=0;i<e;i++)o.append(t[i],B()),X.nextNode(),l.push({type:2,index:++n});o.append(t[e],B())}}}else if(8===o.nodeType)if(o.data===M)l.push({type:2,index:n});else{let t=-1;for(;-1!==(t=o.data.indexOf(z,t+1));)l.push({type:7,index:n}),t+=z.length-1}n++}}static createElement(t,e){const i=U.createElement("template");return i.innerHTML=t,i}}function G(t,e,i=t,o){var n,s,r,l;if(e===K)return e;let a=void 0!==o?null===(n=i._$Cl)||void 0===n?void 0:n[o]:i._$Cu;const p=D(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=G(t,a._$AS(t,e.values),a,o)),e}class Q{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:U).importNode(i,!0);X.currentNode=n;let s=X.nextNode(),r=0,l=0,a=o[0];for(;void 0!==a;){if(r===a.index){let e;2===a.type?e=new tt(s,s.nextSibling,this,t):1===a.type?e=new a.ctor(s,a.name,a.strings,this,t):6===a.type&&(e=new rt(s,this,t)),this.v.push(e),a=o[++l]}r!==(null==a?void 0:a.index)&&(s=X.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 tt{constructor(t,e,i,o){var n;this.type=2,this._$AH=V,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=G(this,t,e),D(t)?t===V||null==t||""===t?(this._$AH!==V&&this._$AR(),this._$AH=V):t!==this._$AH&&t!==K&&this.$(t):void 0!==t._$litType$?this.T(t):void 0!==t.nodeType?this.S(t):T(t)?this.A(t):this.$(t)}M(t,e=this._$AB){return this._$AA.parentNode.insertBefore(t,e)}S(t){this._$AH!==t&&(this._$AR(),this._$AH=this.M(t))}$(t){this._$AH!==V&&D(this._$AH)?this._$AA.nextSibling.data=t:this.S(U.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=Y.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 Q(n,this),e=t.p(this.options);t.m(i),this.S(e),this._$AH=t}}_$AC(t){let e=q.get(t.strings);return void 0===e&&q.set(t.strings,e=new Y(t)),e}A(t){j(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 tt(this.M(B()),this.M(B()),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 et{constructor(t,e,i,o,n){this.type=1,this._$AH=V,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=V}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=G(this,t,e,0),s=!D(t)||t!==this._$AH&&t!==K,s&&(this._$AH=t);else{const o=t;let r,l;for(t=n[0],r=0;r<n.length-1;r++)l=G(this,o[i+r],e,r),l===K&&(l=this._$AH[r]),s||(s=!D(l)||l!==this._$AH[r]),l===V?t=V:t!==V&&(t+=(null!=l?l:"")+n[r+1]),this._$AH[r]=l}s&&!o&&this.k(t)}k(t){t===V?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class it extends et{constructor(){super(...arguments),this.type=3}k(t){this.element[this.name]=t===V?void 0:t}}const ot=N?N.emptyScript:"";class nt extends et{constructor(){super(...arguments),this.type=4}k(t){t&&t!==V?this.element.setAttribute(this.name,ot):this.element.removeAttribute(this.name)}}class st extends et{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=G(this,t,e,0))&&void 0!==i?i:V)===K)return;const o=this._$AH,n=t===V&&o!==V||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,s=t!==V&&(o===V||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 rt{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){G(this,t)}}const lt={P:"$lit$",V:z,L:M,I:1,N:J,R:Q,D:T,j:G,H:tt,O:et,F:nt,B:st,W:it,Z:rt},at=window.litHtmlPolyfillSupport;
|
|
64
59
|
/**
|
|
65
60
|
* @license
|
|
66
61
|
* Copyright 2017 Google LLC
|
|
67
62
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
68
63
|
*/
|
|
69
|
-
var
|
|
64
|
+
var pt,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?E:globalThis.litHtmlVersions=[]).push("2.1.3");class dt extends C{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 tt(e.insertBefore(B(),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 K}}dt.finalized=!0,dt._$litElement$=!0,null===(pt=globalThis.litElementHydrateSupport)||void 0===pt||pt.call(globalThis,{LitElement:dt});const ht=globalThis.litElementPolyfillSupport;null==ht||ht({LitElement:dt}),(null!==(ct=globalThis.litElementVersions)&&void 0!==ct?ct:globalThis.litElementVersions=[]).push("3.1.2");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 x`var(${b(this.name)}, ${this.defaultCssValue(t)})`}defaultCssValue(t){return this.fallbackVariable?this.fallbackVariable.get(null!=t?t:this.defaultValue):b(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 ut(t,e){return b(`${t.name}: ${e}`)}const bt={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")};
|
|
70
65
|
/**
|
|
71
66
|
* @license
|
|
72
67
|
* Copyright 2021 Google LLC
|
|
73
68
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
74
|
-
*/class
|
|
75
|
-
${t.map((t=>
|
|
69
|
+
*/class xt extends(function(t){return class extends t{createRenderRoot(){const t=this.constructor,{registry:e,elementDefinitions:i,shadowRootOptions:o}=t;i&&!e&&(t.registry=new CustomElementRegistry,Object.entries(i).forEach((([e,i])=>t.registry.define(e,i))));const n=this.renderOptions.creationScope=this.attachShadow({...o,customElements:t.registry});return v(n,this.constructor.elementStyles),n}}}(dt)){getStyles(){return[]}getTemplate(){return null}render(){let t=this.getStyles();return Array.isArray(t)||(t=[t]),Z`
|
|
70
|
+
${t.map((t=>Z`
|
|
76
71
|
<style>${t}</style>
|
|
77
72
|
`))}
|
|
78
73
|
${this.getTemplate()}
|
|
79
|
-
`}updated(t){super.updated(t),setTimeout((()=>this.contentAvailableCallback(t)),0)}contentAvailableCallback(t){}}const vt=
|
|
74
|
+
`}updated(t){super.updated(t),setTimeout((()=>this.contentAvailableCallback(t)),0)}contentAvailableCallback(t){}}const vt=x`
|
|
80
75
|
.ft-no-text-select {
|
|
81
76
|
-webkit-touch-callout: none;
|
|
82
77
|
-webkit-user-select: none;
|
|
@@ -85,17 +80,17 @@ var at,pt;null==lt||lt(J,Q),(null!==(C=globalThis.litHtmlVersions)&&void 0!==C?C
|
|
|
85
80
|
-ms-user-select: none;
|
|
86
81
|
user-select: none;
|
|
87
82
|
}
|
|
88
|
-
`;var yt,gt,
|
|
83
|
+
`;var yt,gt,mt;const $t=navigator.vendor&&!!navigator.vendor.match(/apple/i)||"[object SafariRemoteNotification]"===(null!==(mt=null===(gt=null===(yt=window.safari)||void 0===yt?void 0:yt.pushNotification)||void 0===gt?void 0:gt.toString())&&void 0!==mt?mt:""),wt=1,Ot=2,St=t=>(...e)=>({_$litDirective$:t,values:e});
|
|
89
84
|
/**
|
|
90
85
|
* @license
|
|
91
86
|
* Copyright 2017 Google LLC
|
|
92
87
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
93
|
-
*/class
|
|
88
|
+
*/class kt{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,i){this._$Ct=t,this._$AM=e,this._$Ci=i}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}}
|
|
94
89
|
/**
|
|
95
90
|
* @license
|
|
96
91
|
* Copyright 2020 Google LLC
|
|
97
92
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
98
|
-
*/const{H:
|
|
93
|
+
*/const{H:Ct}=lt,Et=()=>document.createComment(""),Nt=(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(Et(),s),o=n.insertBefore(Et(),s);i=new Ct(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},Rt=(t,e,i=t)=>(t._$AI(e,i),t),zt={},Mt=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}},Ft=(t,e,i)=>{const o=new Map;for(let n=e;n<=i;n++)o.set(t[n],n);return o},Ut=St(class extends kt{constructor(t){if(super(t),t.type!==Ot)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.at=l,r;const a=null!==(n=this.at)&&void 0!==n?n:this.at=[],p=[];let c,d,h=0,f=s.length-1,u=0,b=r.length-1;for(;h<=f&&u<=b;)if(null===s[h])h++;else if(null===s[f])f--;else if(a[h]===l[u])p[u]=Rt(s[h],r[u]),h++,u++;else if(a[f]===l[b])p[b]=Rt(s[f],r[b]),f--,b--;else if(a[h]===l[b])p[b]=Rt(s[h],r[b]),Nt(t,p[b+1],s[h]),h++,b--;else if(a[f]===l[u])p[u]=Rt(s[f],r[u]),Nt(t,s[h],s[f]),f--,u++;else if(void 0===c&&(c=Ft(l,u,b),d=Ft(a,h,f)),c.has(a[h]))if(c.has(a[f])){const e=d.get(l[u]),i=void 0!==e?s[e]:null;if(null===i){const e=Nt(t,s[h]);Rt(e,r[u]),p[u]=e}else p[u]=Rt(i,r[u]),Nt(t,s[h],i),s[e]=null;u++}else Mt(s[f]),f--;else Mt(s[h]),h++;for(;u<=b;){const e=Nt(t,p[b+1]);Rt(e,r[u]),p[u++]=e}for(;h<=f;){const t=s[h++];null!==t&&Mt(t)}return this.at=l,((t,e=zt)=>{t._$AH=e})(t,p),K}});
|
|
99
94
|
/**
|
|
100
95
|
* @license
|
|
101
96
|
* Copyright 2017 Google LLC
|
|
@@ -106,94 +101,94 @@ var at,pt;null==lt||lt(J,Q),(null!==(C=globalThis.litHtmlVersions)&&void 0!==C?C
|
|
|
106
101
|
* Copyright 2017 Google LLC
|
|
107
102
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
108
103
|
*/
|
|
109
|
-
class
|
|
104
|
+
class Bt extends kt{constructor(t){if(super(t),this.it=V,t.type!==Ot)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===V||null==t)return this.vt=void 0,this.it=t;if(t===K)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this.vt;this.it=t;const e=[t];return e.raw=e,this.vt={_$litType$:this.constructor.resultType,strings:e,values:[]}}}Bt.directiveName="unsafeHTML",Bt.resultType=1;const Dt=St(Bt),jt=St(class extends kt{constructor(t){var e;if(super(t),t.type!==wt||"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.st){this.st=new Set,void 0!==t.strings&&(this.et=new Set(t.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in e)e[t]&&!(null===(i=this.et)||void 0===i?void 0:i.has(t))&&this.st.add(t);return this.render(e)}const n=t.element.classList;this.st.forEach((t=>{t in e||(n.remove(t),this.st.delete(t))}));for(const t in e){const i=!!e[t];i===this.st.has(t)||(null===(o=this.et)||void 0===o?void 0:o.has(t))||(i?(n.add(t),this.st.add(t)):(n.remove(t),this.st.delete(t)))}return K}}),Tt=t=>({_$litStatic$:t}),Lt=new Map,At=(t=>(e,...i)=>{var o;const n=i.length;let s,r;const l=[],a=[];let p,c=0,d=!1;for(;c<n;){for(p=e[c];c<n&&void 0!==(r=i[c],s=null===(o=r)||void 0===o?void 0:o._$litStatic$);)p+=s+e[++c],d=!0;a.push(r),l.push(p),c++}if(c===n&&l.push(e[n]),d){const t=l.join("$$lit$$");void 0===(e=Lt.get(t))&&(l.raw=l,Lt.set(t,e=l)),i=a}return t(e,...i)})(Z);
|
|
110
105
|
/**
|
|
111
106
|
* @license
|
|
112
107
|
* Copyright 2018 Google LLC
|
|
113
108
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
114
|
-
*/var
|
|
109
|
+
*/var It,_t=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"}(It||(It={}));const Pt=ft.extend("--ft-typography-font-family",bt.titleFont),Ht=ft.extend("--ft-typography-font-family",bt.contentFont),Wt={fontFamily:Ht,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")},Zt=ft.extend("--ft-typography-title-font-family",Pt),Kt=ft.extend("--ft-typography-title-font-size",Wt.fontSize,"20px"),Vt=ft.extend("--ft-typography-title-font-weight",Wt.fontWeight,"normal"),qt=ft.extend("--ft-typography-title-letter-spacing",Wt.letterSpacing,"0.15px"),Xt=ft.extend("--ft-typography-title-line-height",Wt.lineHeight,"24px"),Jt=ft.extend("--ft-typography-title-text-transform",Wt.textTransform,"inherit"),Yt=ft.extend("--ft-typography-title-dense-font-family",Pt),Gt=ft.extend("--ft-typography-title-dense-font-size",Wt.fontSize,"14px"),Qt=ft.extend("--ft-typography-title-dense-font-weight",Wt.fontWeight,"normal"),te=ft.extend("--ft-typography-title-dense-letter-spacing",Wt.letterSpacing,"0.105px"),ee=ft.extend("--ft-typography-title-dense-line-height",Wt.lineHeight,"24px"),ie=ft.extend("--ft-typography-title-dense-text-transform",Wt.textTransform,"inherit"),oe=ft.extend("--ft-typography-subtitle1-font-family",Ht),ne=ft.extend("--ft-typography-subtitle1-font-size",Wt.fontSize,"16px"),se=ft.extend("--ft-typography-subtitle1-font-weight",Wt.fontWeight,"600"),re=ft.extend("--ft-typography-subtitle1-letter-spacing",Wt.letterSpacing,"0.144px"),le=ft.extend("--ft-typography-subtitle1-line-height",Wt.lineHeight,"24px"),ae=ft.extend("--ft-typography-subtitle1-text-transform",Wt.textTransform,"inherit"),pe=ft.extend("--ft-typography-subtitle2-font-family",Ht),ce=ft.extend("--ft-typography-subtitle2-font-size",Wt.fontSize,"14px"),de=ft.extend("--ft-typography-subtitle2-font-weight",Wt.fontWeight,"normal"),he=ft.extend("--ft-typography-subtitle2-letter-spacing",Wt.letterSpacing,"0.098px"),fe=ft.extend("--ft-typography-subtitle2-line-height",Wt.lineHeight,"24px"),ue=ft.extend("--ft-typography-subtitle2-text-transform",Wt.textTransform,"inherit"),be={fontFamily:ft.extend("--ft-typography-body1-font-family",Ht),fontSize:ft.extend("--ft-typography-body1-font-size",Wt.fontSize,"16px"),fontWeight:ft.extend("--ft-typography-body1-font-weight",Wt.fontWeight,"normal"),letterSpacing:ft.extend("--ft-typography-body1-letter-spacing",Wt.letterSpacing,"0.496px"),lineHeight:ft.extend("--ft-typography-body1-line-height",Wt.lineHeight,"24px"),textTransform:ft.extend("--ft-typography-body1-text-transform",Wt.textTransform,"inherit")},xe=ft.extend("--ft-typography-body2-font-family",Ht),ve=ft.extend("--ft-typography-body2-font-size",Wt.fontSize,"14px"),ye=ft.extend("--ft-typography-body2-font-weight",Wt.fontWeight,"normal"),ge=ft.extend("--ft-typography-body2-letter-spacing",Wt.letterSpacing,"0.252px"),me=ft.extend("--ft-typography-body2-line-height",Wt.lineHeight,"20px"),$e=ft.extend("--ft-typography-body2-text-transform",Wt.textTransform,"inherit"),we={fontFamily:ft.extend("--ft-typography-caption-font-family",Ht),fontSize:ft.extend("--ft-typography-caption-font-size",Wt.fontSize,"12px"),fontWeight:ft.extend("--ft-typography-caption-font-weight",Wt.fontWeight,"normal"),letterSpacing:ft.extend("--ft-typography-caption-letter-spacing",Wt.letterSpacing,"0.396px"),lineHeight:ft.extend("--ft-typography-caption-line-height",Wt.lineHeight,"16px"),textTransform:ft.extend("--ft-typography-caption-text-transform",Wt.textTransform,"inherit")},Oe=ft.extend("--ft-typography-breadcrumb-font-family",Ht),Se=ft.extend("--ft-typography-breadcrumb-font-size",Wt.fontSize,"10px"),ke=ft.extend("--ft-typography-breadcrumb-font-weight",Wt.fontWeight,"normal"),Ce=ft.extend("--ft-typography-breadcrumb-letter-spacing",Wt.letterSpacing,"0.33px"),Ee=ft.extend("--ft-typography-breadcrumb-line-height",Wt.lineHeight,"16px"),Ne=ft.extend("--ft-typography-breadcrumb-text-transform",Wt.textTransform,"inherit"),Re=ft.extend("--ft-typography-overline-font-family",Ht),ze=ft.extend("--ft-typography-overline-font-size",Wt.fontSize,"10px"),Me=ft.extend("--ft-typography-overline-font-weight",Wt.fontWeight,"normal"),Fe=ft.extend("--ft-typography-overline-letter-spacing",Wt.letterSpacing,"1.5px"),Ue=ft.extend("--ft-typography-overline-line-height",Wt.lineHeight,"16px"),Be=ft.extend("--ft-typography-overline-text-transform",Wt.textTransform,"uppercase"),De={fontFamily:ft.extend("--ft-typography-button-font-family",Ht),fontSize:ft.extend("--ft-typography-button-font-size",Wt.fontSize,"14px"),fontWeight:ft.extend("--ft-typography-button-font-weight",Wt.fontWeight,"600"),letterSpacing:ft.extend("--ft-typography-button-letter-spacing",Wt.letterSpacing,"1.246px"),lineHeight:ft.extend("--ft-typography-button-line-height",Wt.lineHeight,"16px"),textTransform:ft.extend("--ft-typography-button-text-transform",Wt.textTransform,"uppercase")},je=x`
|
|
115
110
|
.ft-typography--title {
|
|
116
|
-
font-family: ${
|
|
117
|
-
font-size: ${
|
|
118
|
-
font-weight: ${
|
|
119
|
-
letter-spacing: ${
|
|
111
|
+
font-family: ${Zt};
|
|
112
|
+
font-size: ${Kt};
|
|
113
|
+
font-weight: ${Vt};
|
|
114
|
+
letter-spacing: ${qt};
|
|
120
115
|
line-height: ${Xt};
|
|
121
|
-
text-transform: ${
|
|
116
|
+
text-transform: ${Jt};
|
|
122
117
|
}
|
|
123
|
-
`,
|
|
118
|
+
`,Te=x`
|
|
124
119
|
.ft-typography--title-dense {
|
|
125
|
-
font-family: ${
|
|
126
|
-
font-size: ${
|
|
127
|
-
font-weight: ${
|
|
128
|
-
letter-spacing: ${
|
|
129
|
-
line-height: ${
|
|
130
|
-
text-transform: ${
|
|
120
|
+
font-family: ${Yt};
|
|
121
|
+
font-size: ${Gt};
|
|
122
|
+
font-weight: ${Qt};
|
|
123
|
+
letter-spacing: ${te};
|
|
124
|
+
line-height: ${ee};
|
|
125
|
+
text-transform: ${ie};
|
|
131
126
|
}
|
|
132
|
-
`,
|
|
127
|
+
`,Le=x`
|
|
133
128
|
.ft-typography--subtitle1 {
|
|
134
|
-
font-family: ${
|
|
135
|
-
font-size: ${
|
|
136
|
-
font-weight: ${
|
|
137
|
-
letter-spacing: ${
|
|
138
|
-
line-height: ${
|
|
139
|
-
text-transform: ${
|
|
129
|
+
font-family: ${oe};
|
|
130
|
+
font-size: ${ne};
|
|
131
|
+
font-weight: ${se};
|
|
132
|
+
letter-spacing: ${re};
|
|
133
|
+
line-height: ${le};
|
|
134
|
+
text-transform: ${ae};
|
|
140
135
|
}
|
|
141
|
-
`,Ae=
|
|
136
|
+
`,Ae=x`
|
|
142
137
|
.ft-typography--subtitle2 {
|
|
143
|
-
font-family: ${
|
|
144
|
-
font-size: ${
|
|
145
|
-
font-weight: ${
|
|
146
|
-
letter-spacing: ${
|
|
147
|
-
line-height: ${
|
|
148
|
-
text-transform: ${
|
|
138
|
+
font-family: ${pe};
|
|
139
|
+
font-size: ${ce};
|
|
140
|
+
font-weight: ${de};
|
|
141
|
+
letter-spacing: ${he};
|
|
142
|
+
line-height: ${fe};
|
|
143
|
+
text-transform: ${ue};
|
|
149
144
|
}
|
|
150
145
|
|
|
151
|
-
`,
|
|
146
|
+
`,Ie=x`
|
|
152
147
|
.ft-typography--body1 {
|
|
153
|
-
font-family: ${
|
|
154
|
-
font-size: ${
|
|
155
|
-
font-weight: ${
|
|
156
|
-
letter-spacing: ${
|
|
157
|
-
line-height: ${
|
|
158
|
-
text-transform: ${
|
|
148
|
+
font-family: ${be.fontFamily};
|
|
149
|
+
font-size: ${be.fontSize};
|
|
150
|
+
font-weight: ${be.fontWeight};
|
|
151
|
+
letter-spacing: ${be.letterSpacing};
|
|
152
|
+
line-height: ${be.lineHeight};
|
|
153
|
+
text-transform: ${be.textTransform};
|
|
159
154
|
}
|
|
160
|
-
`,_e=
|
|
155
|
+
`,_e=x`
|
|
161
156
|
.ft-typography--body2 {
|
|
162
|
-
font-family: ${
|
|
157
|
+
font-family: ${xe};
|
|
163
158
|
font-size: ${ve};
|
|
164
159
|
font-weight: ${ye};
|
|
165
160
|
letter-spacing: ${ge};
|
|
166
|
-
line-height: ${
|
|
167
|
-
text-transform: ${
|
|
161
|
+
line-height: ${me};
|
|
162
|
+
text-transform: ${$e};
|
|
168
163
|
}
|
|
169
|
-
`,
|
|
164
|
+
`,Pe=x`
|
|
170
165
|
.ft-typography--caption {
|
|
171
|
-
font-family: ${
|
|
172
|
-
font-size: ${
|
|
173
|
-
font-weight: ${
|
|
174
|
-
letter-spacing: ${
|
|
175
|
-
line-height: ${
|
|
176
|
-
text-transform: ${
|
|
166
|
+
font-family: ${we.fontFamily};
|
|
167
|
+
font-size: ${we.fontSize};
|
|
168
|
+
font-weight: ${we.fontWeight};
|
|
169
|
+
letter-spacing: ${we.letterSpacing};
|
|
170
|
+
line-height: ${we.lineHeight};
|
|
171
|
+
text-transform: ${we.textTransform};
|
|
177
172
|
}
|
|
178
|
-
`,
|
|
173
|
+
`,He=x`
|
|
179
174
|
.ft-typography--breadcrumb {
|
|
180
|
-
font-family: ${
|
|
181
|
-
font-size: ${
|
|
182
|
-
font-weight: ${
|
|
183
|
-
letter-spacing: ${
|
|
184
|
-
line-height: ${
|
|
185
|
-
text-transform: ${
|
|
175
|
+
font-family: ${Oe};
|
|
176
|
+
font-size: ${Se};
|
|
177
|
+
font-weight: ${ke};
|
|
178
|
+
letter-spacing: ${Ce};
|
|
179
|
+
line-height: ${Ee};
|
|
180
|
+
text-transform: ${Ne};
|
|
186
181
|
}
|
|
187
|
-
`,
|
|
182
|
+
`,We=x`
|
|
188
183
|
.ft-typography--overline {
|
|
189
184
|
font-family: ${Re};
|
|
190
|
-
font-size: ${
|
|
191
|
-
font-weight: ${
|
|
192
|
-
letter-spacing: ${
|
|
193
|
-
line-height: ${
|
|
194
|
-
text-transform: ${
|
|
185
|
+
font-size: ${ze};
|
|
186
|
+
font-weight: ${Me};
|
|
187
|
+
letter-spacing: ${Fe};
|
|
188
|
+
line-height: ${Ue};
|
|
189
|
+
text-transform: ${Be};
|
|
195
190
|
}
|
|
196
|
-
`,
|
|
191
|
+
`,Ze=x`
|
|
197
192
|
.ft-typography--button {
|
|
198
193
|
font-family: ${De.fontFamily};
|
|
199
194
|
font-size: ${De.fontSize};
|
|
@@ -202,27 +197,27 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
202
197
|
line-height: ${De.lineHeight};
|
|
203
198
|
text-transform: ${De.textTransform};
|
|
204
199
|
}
|
|
205
|
-
`;class
|
|
206
|
-
<${
|
|
200
|
+
`;class Ke extends xt{constructor(){super(...arguments),this.variant=It.body1}render(){return this.element?At`
|
|
201
|
+
<${Tt(this.element)}
|
|
207
202
|
class="ft-typography ft-typography--${this.variant}">
|
|
208
203
|
<slot></slot>
|
|
209
|
-
</${
|
|
204
|
+
</${Tt(this.element)}>
|
|
210
205
|
`:At`
|
|
211
206
|
<slot class="ft-typography ft-typography--${this.variant}"></slot>
|
|
212
|
-
`}}
|
|
207
|
+
`}}Ke.styles=[je,Te,Le,Ae,Ie,_e,Pe,He,We,Ze,x`
|
|
213
208
|
.ft-typography {
|
|
214
209
|
vertical-align: inherit;
|
|
215
210
|
}
|
|
216
|
-
`],_t([
|
|
217
|
-
<div class="${
|
|
218
|
-
${this.text?
|
|
211
|
+
`],_t([n()],Ke.prototype,"element",void 0),_t([n()],Ke.prototype,"variant",void 0),c("ft-typography")(Ke);var Ve=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 qe={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",bt.colorOutline),textColor:ft.extend("--ft-input-label-text-color",bt.colorOnSurfaceMedium),disabledTextColor:ft.extend("--ft-input-label-disabled-text-color",bt.colorOnSurfaceDisabled),colorSurface:ft.external(bt.colorSurface,"Design system"),borderRadiusS:ft.external(bt.borderRadiusS,"Design system")};class Xe extends xt{constructor(){super(...arguments),this.text="",this.raised=!1,this.outlined=!1,this.disabled=!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};return Z`
|
|
212
|
+
<div class="${jt(t)}">
|
|
213
|
+
${this.text?Z`
|
|
219
214
|
<div class="ft-input-label--text ft-typography--caption">
|
|
220
215
|
<span class="ft-input-label--floating-text">${this.text}</span>
|
|
221
216
|
<span class="ft-input-label--hidden-text" aria-hidden="true">${this.text}</span>
|
|
222
217
|
</div>
|
|
223
218
|
`:null}
|
|
224
219
|
</div>
|
|
225
|
-
`}}Xe.elementDefinitions={},Xe.styles=[
|
|
220
|
+
`}}Xe.elementDefinitions={},Xe.styles=[Pe,x`
|
|
226
221
|
.ft-input-label {
|
|
227
222
|
position: absolute;
|
|
228
223
|
inset: 0;
|
|
@@ -230,7 +225,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
230
225
|
}
|
|
231
226
|
|
|
232
227
|
.ft-input-label {
|
|
233
|
-
border-color: ${
|
|
228
|
+
border-color: ${qe.borderColor};
|
|
234
229
|
}
|
|
235
230
|
|
|
236
231
|
.ft-input-label:before,
|
|
@@ -243,7 +238,7 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
243
238
|
}
|
|
244
239
|
|
|
245
240
|
.ft-input-label:before {
|
|
246
|
-
width: ${
|
|
241
|
+
width: ${qe.horizontalSpacing};
|
|
247
242
|
flex-shrink: 0;
|
|
248
243
|
}
|
|
249
244
|
|
|
@@ -259,14 +254,14 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
259
254
|
border-bottom-width: 1px;
|
|
260
255
|
border-bottom-style: solid;
|
|
261
256
|
border-color: inherit;
|
|
262
|
-
color: ${
|
|
257
|
+
color: ${qe.textColor};
|
|
263
258
|
transition: font-size 250ms, line-height 250ms, color 250ms;
|
|
264
|
-
${
|
|
265
|
-
${
|
|
259
|
+
${ut(we.fontSize,qe.fontSize)};
|
|
260
|
+
${ut(we.lineHeight,qe.fontSize)};
|
|
266
261
|
}
|
|
267
262
|
|
|
268
263
|
.ft-input-label--disabled .ft-input-label--text {
|
|
269
|
-
color: ${
|
|
264
|
+
color: ${qe.disabledTextColor};
|
|
270
265
|
}
|
|
271
266
|
|
|
272
267
|
.ft-input-label--hidden-text {
|
|
@@ -282,17 +277,17 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
282
277
|
overflow: hidden;
|
|
283
278
|
white-space: nowrap;
|
|
284
279
|
text-overflow: ellipsis;
|
|
285
|
-
padding: ${
|
|
286
|
-
margin: calc(${
|
|
280
|
+
padding: ${qe.verticalSpacing} 4px;
|
|
281
|
+
margin: calc(${qe.verticalSpacing} * -1) 0;
|
|
287
282
|
}
|
|
288
283
|
|
|
289
284
|
.ft-input-label--raised .ft-input-label--text {
|
|
290
|
-
${
|
|
291
|
-
${
|
|
285
|
+
${ut(we.fontSize,qe.raisedFontSize)};
|
|
286
|
+
${ut(we.lineHeight,qe.raisedFontSize)};
|
|
292
287
|
}
|
|
293
288
|
|
|
294
289
|
.ft-input-label--raised .ft-input-label--floating-text {
|
|
295
|
-
top: ${
|
|
290
|
+
top: ${qe.verticalSpacing};
|
|
296
291
|
}
|
|
297
292
|
|
|
298
293
|
.ft-input-label--outlined .ft-input-label--text,
|
|
@@ -305,27 +300,27 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
305
300
|
.ft-input-label--outlined:before {
|
|
306
301
|
border-left-width: 1px;
|
|
307
302
|
border-left-style: solid;
|
|
308
|
-
border-radius: ${
|
|
303
|
+
border-radius: ${qe.borderRadiusS} 0 0 ${qe.borderRadiusS};
|
|
309
304
|
}
|
|
310
305
|
|
|
311
306
|
.ft-input-label--outlined:after {
|
|
312
307
|
border-right-width: 1px;
|
|
313
308
|
border-right-style: solid;
|
|
314
|
-
border-radius: 0 ${
|
|
309
|
+
border-radius: 0 ${qe.borderRadiusS} ${qe.borderRadiusS} 0;
|
|
315
310
|
}
|
|
316
311
|
|
|
317
312
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--floating-text {
|
|
318
313
|
padding: 2px 4px;
|
|
319
|
-
z-index: ${
|
|
320
|
-
background-color: ${
|
|
321
|
-
border-radius: ${
|
|
314
|
+
z-index: ${qe.raisedZIndex};
|
|
315
|
+
background-color: ${qe.colorSurface};
|
|
316
|
+
border-radius: ${qe.borderRadiusS};
|
|
322
317
|
top: calc((var(--ft-typography-caption-line-height) / -2) + 2px);
|
|
323
318
|
}
|
|
324
319
|
|
|
325
320
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--text {
|
|
326
321
|
border-top: none;
|
|
327
322
|
}
|
|
328
|
-
`],
|
|
323
|
+
`],Ve([n({type:String})],Xe.prototype,"text",void 0),Ve([n({type:Boolean})],Xe.prototype,"raised",void 0),Ve([n({type:Boolean})],Xe.prototype,"outlined",void 0),Ve([n({type:Boolean})],Xe.prototype,"disabled",void 0),c("ft-input-label")(Xe);var Je=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 Ye={color:ft.extend("--ft-ripple-color",bt.colorContent),primaryColor:ft.extend("--ft-ripple-primary-color",ft.extend("--ft-ripple-color",bt.colorPrimary)),secondaryColor:ft.extend("--ft-ripple-secondary-color",ft.extend("--ft-ripple-color",bt.colorSecondary)),opacityContentOnSurfacePressed:ft.external(bt.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:ft.external(bt.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:ft.external(bt.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:ft.external(bt.opacityContentOnSurfaceSelected,"Design system")};class Ge extends xt{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.onTransitionStart=t=>{"transform"===t.propertyName&&(this.rippling=this.pressed)},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 Z`
|
|
329
324
|
<style>
|
|
330
325
|
.ft-ripple .ft-ripple--effect,
|
|
331
326
|
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
@@ -338,11 +333,11 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
338
333
|
top: ${this.originY}px;
|
|
339
334
|
}
|
|
340
335
|
</style>
|
|
341
|
-
<div class="${
|
|
336
|
+
<div class="${jt(t)}">
|
|
342
337
|
<div class="ft-ripple--background"></div>
|
|
343
338
|
<div class="ft-ripple--effect"></div>
|
|
344
339
|
</div>
|
|
345
|
-
`}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&&this.endRipple(),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){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),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),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()}}
|
|
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&&this.endRipple(),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 Qe,ti;Ge.elementDefinitions={},Ge.styles=x`
|
|
346
341
|
:host {
|
|
347
342
|
display: contents;
|
|
348
343
|
}
|
|
@@ -361,17 +356,17 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
361
356
|
.ft-ripple .ft-ripple--effect {
|
|
362
357
|
position: absolute;
|
|
363
358
|
opacity: 0;
|
|
364
|
-
background-color: ${
|
|
359
|
+
background-color: ${Ye.color};
|
|
365
360
|
}
|
|
366
361
|
|
|
367
362
|
.ft-ripple.ft-ripple--secondary .ft-ripple--background,
|
|
368
363
|
.ft-ripple.ft-ripple--secondary .ft-ripple--effect {
|
|
369
|
-
background-color: ${
|
|
364
|
+
background-color: ${Ye.secondaryColor};
|
|
370
365
|
}
|
|
371
366
|
|
|
372
367
|
.ft-ripple.ft-ripple--primary .ft-ripple--background,
|
|
373
368
|
.ft-ripple.ft-ripple--primary .ft-ripple--effect {
|
|
374
|
-
background-color: ${
|
|
369
|
+
background-color: ${Ye.primaryColor};
|
|
375
370
|
}
|
|
376
371
|
|
|
377
372
|
.ft-ripple .ft-ripple--background {
|
|
@@ -402,49 +397,61 @@ class Ut extends St{constructor(t){if(super(t),this.it=K,t.type!==wt)throw Error
|
|
|
402
397
|
}
|
|
403
398
|
|
|
404
399
|
.ft-ripple.ft-ripple--hovered .ft-ripple--background {
|
|
405
|
-
opacity: ${
|
|
400
|
+
opacity: ${Ye.opacityContentOnSurfaceHover};
|
|
406
401
|
}
|
|
407
402
|
|
|
408
403
|
.ft-ripple.ft-ripple--selected .ft-ripple--background {
|
|
409
|
-
opacity: ${
|
|
404
|
+
opacity: ${Ye.opacityContentOnSurfaceSelected};
|
|
410
405
|
}
|
|
411
406
|
|
|
412
407
|
.ft-ripple.ft-ripple--focused .ft-ripple--background {
|
|
413
|
-
opacity: ${
|
|
408
|
+
opacity: ${Ye.opacityContentOnSurfaceFocused};
|
|
414
409
|
}
|
|
415
410
|
|
|
416
411
|
.ft-ripple.ft-ripple--pressed .ft-ripple--effect {
|
|
417
|
-
opacity: ${
|
|
412
|
+
opacity: ${Ye.opacityContentOnSurfacePressed};
|
|
418
413
|
transform: translate(-50%, -50%) scale(1);
|
|
419
414
|
}
|
|
420
|
-
`,
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
415
|
+
`,Je([n({type:Boolean})],Ge.prototype,"primary",void 0),Je([n({type:Boolean})],Ge.prototype,"secondary",void 0),Je([n({type:Boolean})],Ge.prototype,"unbounded",void 0),Je([n({type:Boolean})],Ge.prototype,"activated",void 0),Je([n({type:Boolean})],Ge.prototype,"selected",void 0),Je([n({type:Boolean})],Ge.prototype,"disabled",void 0),Je([s()],Ge.prototype,"hovered",void 0),Je([s()],Ge.prototype,"focused",void 0),Je([s()],Ge.prototype,"pressed",void 0),Je([s()],Ge.prototype,"rippling",void 0),Je([s()],Ge.prototype,"rippleSize",void 0),Je([s()],Ge.prototype,"originX",void 0),Je([s()],Ge.prototype,"originY",void 0),Je([l(".ft-ripple")],Ge.prototype,"ripple",void 0),Je([l(".ft-ripple--effect")],Ge.prototype,"rippleEffect",void 0),c("ft-ripple")(Ge),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=""}(Qe||(Qe={})),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=""}(ti||(ti={})),new Map([...["abw"].map((t=>[t,ti.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,ti.AUDIO])),...["avi"].map((t=>[t,ti.AVI])),...["chm","xhs"].map((t=>[t,ti.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,ti.CODE])),...["csv"].map((t=>[t,ti.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,ti.DITA])),...["epub"].map((t=>[t,ti.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,ti.EXCEL])),...["flac"].map((t=>[t,ti.FLAC])),...["gif"].map((t=>[t,ti.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,ti.GZIP])),...["html","htm","xhtml"].map((t=>[t,ti.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,ti.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,ti.JPEG])),...["json"].map((t=>[t,ti.JSON])),...["m4a","m4p"].map((t=>[t,ti.M4A])),...["mov","qt"].map((t=>[t,ti.MOV])),...["mp3"].map((t=>[t,ti.MP3])),...["mp4","m4v"].map((t=>[t,ti.MP4])),...["ogg","oga"].map((t=>[t,ti.OGG])),...["pdf","ps"].map((t=>[t,ti.PDF])),...["png"].map((t=>[t,ti.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,ti.POWERPOINT])),...["rar"].map((t=>[t,ti.RAR])),...["stp"].map((t=>[t,ti.STP])),...["txt","rtf","md","mdown"].map((t=>[t,ti.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,ti.VIDEO])),...["wav"].map((t=>[t,ti.WAV])),...["wma"].map((t=>[t,ti.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,ti.WORD])),...["xml","xsl","rdf"].map((t=>[t,ti.XML])),...["yaml","yml","x-yaml"].map((t=>[t,ti.YAML])),...["zip"].map((t=>[t,ti.ZIP]))]);var ei,ii=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"}(ei||(ei={}));const oi={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 ni extends xt{constructor(){super(...arguments),this.variant=ei.fluid_topics}render(){return Z`
|
|
416
|
+
<i class="ft-icon ${"ft-icon--"+this.variant}">
|
|
417
|
+
${Dt(this.getIcon())}
|
|
418
|
+
<slot @slotchange=${()=>this.requestUpdate()} ?hidden=${"material"!==this.variant}></slot>
|
|
419
|
+
</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===ei.file_format?null!==(t=ti[i.toUpperCase()])&&void 0!==t?t:i:this.variant===ei.fluid_topics?null!==(e=Qe[i.toUpperCase()])&&void 0!==e?e:i:V}}ni.elementDefinitions={},ni.styles=x`
|
|
421
|
+
:host, i.ft-icon {
|
|
422
|
+
display: inline-block;
|
|
423
|
+
width: ${oi.size};
|
|
424
|
+
height: ${oi.size};
|
|
425
|
+
text-align: center;
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
i.ft-icon {
|
|
429
|
+
font-size: ${oi.size};
|
|
430
|
+
line-height: 1;
|
|
431
|
+
font-weight: normal;
|
|
432
|
+
text-transform: none;
|
|
433
|
+
font-style: normal;
|
|
434
|
+
font-variant: normal;
|
|
435
|
+
speak: none;
|
|
436
|
+
text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.004);
|
|
437
|
+
text-rendering: auto;
|
|
438
|
+
-webkit-font-smoothing: antialiased;
|
|
439
|
+
-moz-osx-font-smoothing: grayscale;
|
|
440
|
+
}
|
|
441
|
+
|
|
442
|
+
.ft-icon--fluid-topics {
|
|
443
|
+
font-family: ${oi.fluidTopicsFontFamily}, ft-icons, fticons, sans-serif;
|
|
444
|
+
}
|
|
445
|
+
|
|
446
|
+
.ft-icon--file-format {
|
|
447
|
+
font-family: ${oi.fileFormatFontFamily}, ft-mime, sans-serif;
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
.ft-icon--material {
|
|
451
|
+
font-family: ${oi.materialFontFamily}, "Material Icons", sans-serif;
|
|
452
|
+
}
|
|
453
|
+
`,ii([n()],ni.prototype,"variant",void 0),ii([l("slot")],ni.prototype,"slottedContent",void 0),c("ft-icon")(ni);var si=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 ri extends xt{constructor(){super(...arguments),this.label="",this.value=null,this.selected=!1}render(){return Z``}updated(t){super.updated(t),this.dispatchEvent(new CustomEvent("option-change",{detail:this,bubbles:!0}))}}ri.elementDefinitions={},si([n({type:String})],ri.prototype,"label",void 0),si([n({type:Object,converter:t=>t})],ri.prototype,"value",void 0),si([n({type:Boolean,reflect:!0})],ri.prototype,"selected",void 0);const li={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",bt.colorOnSurface),helperColor:ft.extend("--ft-select-helper-color",bt.colorOnSurfaceMedium),optionsColor:ft.extend("--ft-select-options-color",bt.colorOnSurface),optionsZIndex:ft.create("--ft-select-options-z-index","NUMBER","2"),colorSurface:ft.external(bt.colorSurface,"Design system"),colorOnSurfaceDisabled:ft.external(bt.colorOnSurfaceDisabled,"Design system"),colorPrimary:ft.external(bt.colorPrimary,"Design system"),borderRadiusS:ft.external(bt.borderRadiusS,"Design system"),elevation02:ft.external(bt.elevation02,"Design system")};class ai extends xt{constructor(){super(...arguments),this.label="",this.helper="",this.outlined=!1,this.disabled=!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.disabled&&this.optionsDisplayed&&this.hasOptions,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};return Z`
|
|
454
|
+
<div class="${jt(a)}" part="container">
|
|
448
455
|
<div class="ft-select--main-panel" part="main-panel">
|
|
449
456
|
<ft-input-label text="${this.label}"
|
|
450
457
|
part="label"
|
|
@@ -464,24 +471,24 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
464
471
|
<ft-typography variant="body1" class="ft-select--selected-option">
|
|
465
472
|
${null!==(n=null===(o=this.selectedOption)||void 0===o?void 0:o.label)&&void 0!==n?n:""}
|
|
466
473
|
</ft-typography>
|
|
467
|
-
<
|
|
474
|
+
<ft-icon variant="material">${s?"expand_less":"expand_more"}</ft-icon>
|
|
468
475
|
</div>
|
|
469
476
|
<div class="ft-select--options"
|
|
470
477
|
part="options"
|
|
471
478
|
@keydown=${this.onOptionsKeyDown}
|
|
472
479
|
innerrole="listbox">
|
|
473
|
-
${
|
|
480
|
+
${Ut(this.options,(t=>t.value),(t=>this.renderOption(t)))}
|
|
474
481
|
</div>
|
|
475
482
|
</div>
|
|
476
|
-
${this.helper?
|
|
483
|
+
${this.helper?Z`
|
|
477
484
|
<ft-typography class="ft-select--helper-text" variant="caption">${this.helper}
|
|
478
485
|
</ft-typography>`:void 0}
|
|
479
486
|
</div>
|
|
480
487
|
<slot @slotchange=${this.updateOptionsFromSlot}
|
|
481
488
|
@option-change=${this.updateOptionsFromSlot}
|
|
482
489
|
></slot>
|
|
483
|
-
`}renderOption(t){let e=this.selectedOption===t;return
|
|
484
|
-
<div class="${
|
|
490
|
+
`}renderOption(t){let e=this.selectedOption===t;return Z`
|
|
491
|
+
<div class="${jt({"ft-select--option":!0,"ft-select--option-selected":e,"ft-typography--body2":!0})}"
|
|
485
492
|
part="option"
|
|
486
493
|
tabindex="0"
|
|
487
494
|
@keydown=${e=>this.onOptionKeyDown(e,t)}
|
|
@@ -489,7 +496,7 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
489
496
|
<ft-ripple ?primary=${e} ?activated=${e}></ft-ripple>
|
|
490
497
|
${t.label}
|
|
491
498
|
</div>
|
|
492
|
-
`}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)}}
|
|
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)}}ai.elementDefinitions={"ft-input-label":Xe,"ft-typography":Ke,"ft-ripple":Ge,"ft-icon":ni},ai.styles=[_e,Pe,x`
|
|
493
500
|
*:focus {
|
|
494
501
|
outline: none;
|
|
495
502
|
}
|
|
@@ -503,7 +510,7 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
503
510
|
.ft-select--main-panel {
|
|
504
511
|
position: relative;
|
|
505
512
|
display: flex;
|
|
506
|
-
height: calc(4 * ${
|
|
513
|
+
height: calc(4 * ${li.verticalSpacing} + ${li.labelSize} + ${li.selectedOptionSize});
|
|
507
514
|
}
|
|
508
515
|
|
|
509
516
|
.ft-select--input-panel {
|
|
@@ -515,19 +522,19 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
515
522
|
padding-left: 16px;
|
|
516
523
|
padding-right: 8px;
|
|
517
524
|
gap: 8px;
|
|
518
|
-
color: ${
|
|
519
|
-
${
|
|
525
|
+
color: ${li.selectedOptionColor};
|
|
526
|
+
${ut(Ye.color,li.selectedOptionColor)};
|
|
520
527
|
}
|
|
521
528
|
|
|
522
529
|
.ft-select--input-panel,
|
|
523
530
|
.ft-select--option {
|
|
524
|
-
${
|
|
525
|
-
${
|
|
531
|
+
${ut(Ye.opacityContentOnSurfaceHover,"0.08")};
|
|
532
|
+
${ut(Ye.opacityContentOnSurfacePressed,"0.04")};
|
|
526
533
|
}
|
|
527
534
|
|
|
528
535
|
.ft-select--disabled .ft-select--input-panel,
|
|
529
536
|
.ft-select--disabled .ft-select--option {
|
|
530
|
-
color: ${
|
|
537
|
+
color: ${li.colorOnSurfaceDisabled};
|
|
531
538
|
}
|
|
532
539
|
|
|
533
540
|
.ft-select:not(.ft-select--disabled) .ft-select--input-panel,
|
|
@@ -536,18 +543,18 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
536
543
|
}
|
|
537
544
|
|
|
538
545
|
ft-input-label {
|
|
539
|
-
${
|
|
540
|
-
${
|
|
541
|
-
${
|
|
546
|
+
${ut(qe.fontSize,li.selectedOptionSize)};
|
|
547
|
+
${ut(qe.raisedFontSize,li.labelSize)};
|
|
548
|
+
${ut(qe.verticalSpacing,li.verticalSpacing)};
|
|
542
549
|
}
|
|
543
550
|
|
|
544
|
-
.ft-select:not(.ft-select--disabled):focus-within
|
|
545
|
-
color: ${
|
|
551
|
+
.ft-select:not(.ft-select--disabled):focus-within ft-icon {
|
|
552
|
+
color: ${li.colorPrimary};
|
|
546
553
|
}
|
|
547
554
|
|
|
548
555
|
.ft-select:not(.ft-select--disabled):focus-within ft-input-label {
|
|
549
|
-
${
|
|
550
|
-
${
|
|
556
|
+
${ut(qe.borderColor,li.colorPrimary)};
|
|
557
|
+
${ut(qe.textColor,li.colorPrimary)};
|
|
551
558
|
}
|
|
552
559
|
|
|
553
560
|
.ft-select--selected-option {
|
|
@@ -557,11 +564,11 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
557
564
|
overflow: hidden;
|
|
558
565
|
white-space: nowrap;
|
|
559
566
|
text-overflow: ellipsis;
|
|
560
|
-
${
|
|
561
|
-
${
|
|
567
|
+
${ut(be.fontSize,li.selectedOptionSize)};
|
|
568
|
+
${ut(be.lineHeight,li.selectedOptionSize)};
|
|
562
569
|
}
|
|
563
570
|
|
|
564
|
-
|
|
571
|
+
ft-icon {
|
|
565
572
|
flex-shrink: 0;
|
|
566
573
|
}
|
|
567
574
|
|
|
@@ -570,16 +577,16 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
570
577
|
}
|
|
571
578
|
|
|
572
579
|
.ft-select--filled .ft-select--input-panel {
|
|
573
|
-
border-radius: ${
|
|
580
|
+
border-radius: ${li.borderRadiusS} ${li.borderRadiusS} 0 0;
|
|
574
581
|
}
|
|
575
582
|
|
|
576
583
|
.ft-select--filled:not(.ft-select--no-label) .ft-select--selected-option {
|
|
577
584
|
align-self: stretch;
|
|
578
|
-
padding-top: calc(${
|
|
585
|
+
padding-top: calc(${li.labelSize} + 2 * ${li.verticalSpacing});
|
|
579
586
|
}
|
|
580
587
|
|
|
581
588
|
.ft-select--outlined .ft-select--input-panel {
|
|
582
|
-
border-radius: ${
|
|
589
|
+
border-radius: ${li.borderRadiusS};
|
|
583
590
|
}
|
|
584
591
|
|
|
585
592
|
.ft-select--options {
|
|
@@ -588,10 +595,10 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
588
595
|
top: 100%;
|
|
589
596
|
left: 0;
|
|
590
597
|
right: 0;
|
|
591
|
-
color: ${
|
|
592
|
-
background: ${
|
|
593
|
-
z-index: ${
|
|
594
|
-
box-shadow: ${
|
|
598
|
+
color: ${li.optionsColor};
|
|
599
|
+
background: ${li.colorSurface};
|
|
600
|
+
z-index: ${li.optionsZIndex};
|
|
601
|
+
box-shadow: ${li.elevation02};
|
|
595
602
|
}
|
|
596
603
|
|
|
597
604
|
.ft-select--options-displayed .ft-select--options {
|
|
@@ -608,10 +615,10 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
608
615
|
|
|
609
616
|
.ft-select--helper-text {
|
|
610
617
|
padding: 0 12px 0 16px;
|
|
611
|
-
color: ${
|
|
618
|
+
color: ${li.helperColor};
|
|
612
619
|
}
|
|
613
|
-
`],
|
|
614
|
-
<div class="${
|
|
620
|
+
`],si([n({type:String})],ai.prototype,"label",void 0),si([n({type:String})],ai.prototype,"helper",void 0),si([n({type:Boolean})],ai.prototype,"outlined",void 0),si([n({type:Boolean})],ai.prototype,"disabled",void 0),si([n({type:Array})],ai.prototype,"options",void 0),si([s()],ai.prototype,"selectedOption",void 0),si([s()],ai.prototype,"optionsDisplayed",void 0),si([s()],ai.prototype,"focusOptions",void 0),si([l(".ft-select")],ai.prototype,"container",void 0),si([l(".ft-select--input-panel")],ai.prototype,"mainPanel",void 0),si([l(".ft-select--option:first-child")],ai.prototype,"firstOption",void 0),si([l(".ft-select--option:focus")],ai.prototype,"focusedOption",void 0),si([l(".ft-select--option.ft-select--option-selected")],ai.prototype,"selectedOptionElement",void 0),si([l(".ft-select--option:last-child")],ai.prototype,"lastOption",void 0),si([l("slot")],ai.prototype,"optionsSlot",void 0),c("ft-select")(ai),c("ft-select-option")(ri);var pi=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 ci={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",bt.colorOnSurfaceMedium),colorPrimary:ft.external(bt.colorPrimary,"Design system"),colorOnSurface:ft.external(bt.colorOnSurface,"Design system"),colorOnSurfaceDisabled:ft.external(bt.colorOnSurfaceDisabled,"Design system"),borderRadiusS:ft.external(bt.borderRadiusS,"Design system")};class di extends xt{constructor(){super(...arguments),this.label="",this.value="",this.helper="",this.outlined=!1,this.disabled=!1,this.dataList=[],this.focused=!1}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};return Z`
|
|
621
|
+
<div class="${jt(t)}">
|
|
615
622
|
<div class="ft-text-field--main-panel">
|
|
616
623
|
<ft-input-label text="${this.label}"
|
|
617
624
|
?disabled=${this.disabled}
|
|
@@ -620,7 +627,7 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
620
627
|
></ft-input-label>
|
|
621
628
|
<div class="ft-text-field--input-panel"
|
|
622
629
|
aria-label="${this.label}">
|
|
623
|
-
${this.outlined?null:
|
|
630
|
+
${this.outlined?null:Z`
|
|
624
631
|
<ft-ripple ?disabled=${this.disabled} activated></ft-ripple>
|
|
625
632
|
`}
|
|
626
633
|
<input type="text"
|
|
@@ -635,17 +642,17 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
635
642
|
/>
|
|
636
643
|
|
|
637
644
|
<datalist id="datalist">
|
|
638
|
-
${this.dataList.map((t=>
|
|
645
|
+
${this.dataList.map((t=>Z`
|
|
639
646
|
<option value="${t}"></option>`))}
|
|
640
647
|
</datalist>
|
|
641
648
|
|
|
642
649
|
</div>
|
|
643
650
|
</div>
|
|
644
|
-
${this.helper?
|
|
651
|
+
${this.helper?Z`
|
|
645
652
|
<ft-typography class="ft-text-field--helper-text" variant="caption">${this.helper}
|
|
646
653
|
</ft-typography>`:void 0}
|
|
647
654
|
</div>
|
|
648
|
-
`}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)||""}}
|
|
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)||""}}di.elementDefinitions={"ft-input-label":Xe,"ft-ripple":Ge,"ft-typography":Ke},di.styles=[Ie,x`
|
|
649
656
|
*:focus {
|
|
650
657
|
outline: none;
|
|
651
658
|
}
|
|
@@ -657,16 +664,16 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
657
664
|
}
|
|
658
665
|
|
|
659
666
|
ft-input-label {
|
|
660
|
-
${
|
|
661
|
-
${
|
|
662
|
-
${
|
|
663
|
-
${
|
|
667
|
+
${ut(qe.fontSize,ci.fontSize)};
|
|
668
|
+
${ut(qe.raisedFontSize,ci.labelSize)};
|
|
669
|
+
${ut(qe.verticalSpacing,ci.verticalSpacing)};
|
|
670
|
+
${ut(qe.horizontalSpacing,x`calc(${ci.horizontalSpacing} - 4px)`)};
|
|
664
671
|
}
|
|
665
672
|
|
|
666
673
|
.ft-text-field--main-panel {
|
|
667
674
|
position: relative;
|
|
668
675
|
display: flex;
|
|
669
|
-
height: calc(4 * ${
|
|
676
|
+
height: calc(4 * ${ci.verticalSpacing} + ${ci.labelSize} + ${ci.fontSize});
|
|
670
677
|
}
|
|
671
678
|
|
|
672
679
|
.ft-text-field--input-panel {
|
|
@@ -679,8 +686,8 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
679
686
|
}
|
|
680
687
|
|
|
681
688
|
.ft-text-field--input-panel ft-ripple {
|
|
682
|
-
${
|
|
683
|
-
${
|
|
689
|
+
${ut(Ye.opacityContentOnSurfaceHover,"0.08")};
|
|
690
|
+
${ut(Ye.opacityContentOnSurfacePressed,"0.04")};
|
|
684
691
|
}
|
|
685
692
|
|
|
686
693
|
.ft-text-field--input {
|
|
@@ -689,11 +696,11 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
689
696
|
flex-shrink: 1;
|
|
690
697
|
min-width: 0; /* flex sets this to auto an prevents input from shrinking properly */
|
|
691
698
|
|
|
692
|
-
${
|
|
693
|
-
${
|
|
694
|
-
color: ${
|
|
699
|
+
${ut(be.fontSize,ci.fontSize)};
|
|
700
|
+
${ut(be.lineHeight,ci.fontSize)};
|
|
701
|
+
color: ${ci.colorOnSurface};
|
|
695
702
|
|
|
696
|
-
padding: 0 ${
|
|
703
|
+
padding: 0 ${ci.horizontalSpacing};
|
|
697
704
|
|
|
698
705
|
border: none;
|
|
699
706
|
background: none;
|
|
@@ -705,7 +712,7 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
705
712
|
}
|
|
706
713
|
|
|
707
714
|
.ft-text-field--disabled .ft-text-field--input {
|
|
708
|
-
color: ${
|
|
715
|
+
color: ${ci.colorOnSurfaceDisabled};
|
|
709
716
|
}
|
|
710
717
|
|
|
711
718
|
.ft-text-field:not(.ft-text-field--disabled) .ft-text-field--input-panel {
|
|
@@ -713,29 +720,29 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
713
720
|
}
|
|
714
721
|
|
|
715
722
|
.ft-text-field:not(.ft-text-field--disabled):focus-within ft-input-label {
|
|
716
|
-
${
|
|
717
|
-
${
|
|
723
|
+
${ut(qe.borderColor,ci.colorPrimary)};
|
|
724
|
+
${ut(qe.textColor,ci.colorPrimary)};
|
|
718
725
|
}
|
|
719
726
|
|
|
720
727
|
.ft-text-field--filled .ft-text-field--input-panel {
|
|
721
|
-
border-radius: ${
|
|
728
|
+
border-radius: ${ci.borderRadiusS} ${ci.borderRadiusS} 0 0;
|
|
722
729
|
}
|
|
723
730
|
|
|
724
731
|
.ft-text-field--filled:not(.ft-text-field--no-label) .ft-text-field--input {
|
|
725
732
|
align-self: stretch;
|
|
726
|
-
padding-bottom: ${
|
|
727
|
-
padding-top: calc(${
|
|
733
|
+
padding-bottom: ${ci.verticalSpacing};
|
|
734
|
+
padding-top: calc(${ci.labelSize} + 2 * ${ci.verticalSpacing});
|
|
728
735
|
}
|
|
729
736
|
|
|
730
737
|
.ft-text-field--outlined .ft-text-field--input-panel {
|
|
731
|
-
border-radius: ${
|
|
738
|
+
border-radius: ${ci.borderRadiusS};
|
|
732
739
|
}
|
|
733
740
|
|
|
734
741
|
.ft-text-field--helper-text {
|
|
735
|
-
padding: 0 12px 0 ${
|
|
736
|
-
color: ${
|
|
742
|
+
padding: 0 12px 0 ${ci.horizontalSpacing};
|
|
743
|
+
color: ${ci.helperColor};
|
|
737
744
|
}
|
|
738
|
-
`],
|
|
745
|
+
`],pi([n({type:String})],di.prototype,"label",void 0),pi([n({reflect:!0})],di.prototype,"value",void 0),pi([n({type:String})],di.prototype,"helper",void 0),pi([n({type:Boolean})],di.prototype,"outlined",void 0),pi([n({type:Boolean})],di.prototype,"disabled",void 0),pi([l(".ft-text-field--input")],di.prototype,"input",void 0),pi([n({attribute:!1})],di.prototype,"dataList",void 0),pi([s()],di.prototype,"focused",void 0),c("ft-text-field")(di);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};const fi=ft.create("--ft-tooltip-distance","SIZE","4px"),ui=ft.create("--ft-tooltip-color","COLOR","#FFFFFF"),bi=ft.create("--ft-tooltip-background-color","COLOR","#666666"),xi=ft.create("--ft-tooltip-z-index","NUMBER","1"),vi=ft.external(bt.borderRadiusS,"Design system");class yi extends xt{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.hideDebounce=new i,this.revealDebouncer=new i}render(){return Z`
|
|
739
746
|
<div part="container"
|
|
740
747
|
class="ft-tooltip--container ${this.inline?"ft-tooltip--inline":""}"
|
|
741
748
|
@mouseenter=${this.onHover}
|
|
@@ -750,7 +757,7 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
750
757
|
</div>
|
|
751
758
|
<slot></slot>
|
|
752
759
|
</div>
|
|
753
|
-
`}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())}}
|
|
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())}}yi.elementDefinitions={"ft-typography":Ke},yi.styles=x`
|
|
754
761
|
.ft-tooltip--container {
|
|
755
762
|
display: block;
|
|
756
763
|
position: relative;
|
|
@@ -768,27 +775,27 @@ function(t,e,i,o){for(var n,s=arguments.length,r=s<3?e:null===o?o=Object.getOwnP
|
|
|
768
775
|
width: max-content;
|
|
769
776
|
max-width: 150px;
|
|
770
777
|
text-align: center;
|
|
771
|
-
padding: ${
|
|
772
|
-
z-index: ${
|
|
778
|
+
padding: ${fi};
|
|
779
|
+
z-index: ${xi};
|
|
773
780
|
}
|
|
774
781
|
|
|
775
782
|
.ft-tooltip--content {
|
|
776
783
|
padding: 4px 8px;
|
|
777
|
-
border-radius: ${
|
|
778
|
-
background-color: ${
|
|
779
|
-
color: ${
|
|
784
|
+
border-radius: ${vi};
|
|
785
|
+
background-color: ${bi};
|
|
786
|
+
color: ${ui};
|
|
780
787
|
top: -500px;
|
|
781
788
|
left: -500px;
|
|
782
789
|
position: relative;
|
|
783
790
|
word-break: break-word;
|
|
784
791
|
}
|
|
785
|
-
`,
|
|
792
|
+
`,hi([n()],yi.prototype,"text",void 0),hi([n({type:Boolean})],yi.prototype,"manual",void 0),hi([n({type:Boolean})],yi.prototype,"inline",void 0),hi([n({type:Number})],yi.prototype,"delay",void 0),hi([n()],yi.prototype,"position",void 0),hi([
|
|
786
793
|
/**
|
|
787
794
|
* @license
|
|
788
795
|
* Copyright 2017 Google LLC
|
|
789
796
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
790
797
|
*/
|
|
791
|
-
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
|
|
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 r({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?p(s,t):[];return i?r.filter((t=>t.matches(i))):r},enumerable:!0,configurable:!0})})}({slot:n,flatten:e,selector:i}):r({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)],yi.prototype,"slotNodes",void 0),hi([l(".ft-tooltip--container")],yi.prototype,"container",void 0),hi([l("slot")],yi.prototype,"target",void 0),hi([l(".ft-tooltip")],yi.prototype,"tooltip",void 0),hi([l(".ft-tooltip--content")],yi.prototype,"tooltipContent",void 0),hi([s()],yi.prototype,"visible",void 0),c("ft-tooltip")(yi);const gi={color:ft.extend("--ft-loader-color",bt.colorPrimary),size:ft.create("--ft-loader-size","SIZE","80px")};class mi extends xt{static get styles(){return x`
|
|
792
799
|
:host {
|
|
793
800
|
line-height: 0;
|
|
794
801
|
}
|
|
@@ -797,8 +804,8 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
797
804
|
display: inline-block;
|
|
798
805
|
position: relative;
|
|
799
806
|
|
|
800
|
-
width: ${
|
|
801
|
-
height: ${
|
|
807
|
+
width: ${gi.size};
|
|
808
|
+
height: ${gi.size};
|
|
802
809
|
}
|
|
803
810
|
|
|
804
811
|
.ft-loader div {
|
|
@@ -807,7 +814,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
807
814
|
width: 25%;
|
|
808
815
|
height: 25%;
|
|
809
816
|
border-radius: 50%;
|
|
810
|
-
background: ${
|
|
817
|
+
background: ${gi.color};
|
|
811
818
|
animation-timing-function: cubic-bezier(0, 1, 1, 0);
|
|
812
819
|
}
|
|
813
820
|
|
|
@@ -854,17 +861,17 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
854
861
|
transform: translate(0, 0);
|
|
855
862
|
}
|
|
856
863
|
100% {
|
|
857
|
-
transform: translate(calc(0.35 * ${
|
|
864
|
+
transform: translate(calc(0.35 * ${gi.size}), 0);
|
|
858
865
|
}
|
|
859
866
|
}
|
|
860
|
-
`}render(){return
|
|
867
|
+
`}render(){return Z`
|
|
861
868
|
<div class="ft-loader">
|
|
862
869
|
<div></div>
|
|
863
870
|
<div></div>
|
|
864
871
|
<div></div>
|
|
865
872
|
<div></div>
|
|
866
873
|
</div>
|
|
867
|
-
`}}
|
|
874
|
+
`}}c("ft-loader")(mi);var $i=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 wi=ft.extend("--ft-button-color",bt.colorPrimary),Oi={backgroundColor:ft.extend("--ft-button-background-color",bt.colorSurface),borderRadius:ft.extend("--ft-button-border-radius",bt.borderRadiusL),color:wi,fontSize:ft.extend("--ft-button-font-size",De.fontSize),iconSize:ft.create("--ft-button-icon-size","SIZE","24px"),rippleColor:ft.extend("--ft-button-ripple-color",wi),opacityDisabled:ft.external(bt.colorOpacityDisabled,"Design system")},Si=ft.extend("--ft-button-primary-color",ft.extend("--ft-button-color",bt.colorOnPrimary)),ki={backgroundColor:ft.extend("--ft-button-primary-background-color",ft.extend("--ft-button-background-color",bt.colorPrimary)),color:Si,rippleColor:ft.extend("--ft-button-primary-ripple-color",Si)},Ci=ft.extend("--ft-button-dense-border-radius",ft.extend("--ft-button-border-radius",bt.borderRadiusM));class Ei extends xt{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[vt,x`
|
|
868
875
|
:host {
|
|
869
876
|
display: inline-block;
|
|
870
877
|
max-width: 100%;
|
|
@@ -903,18 +910,18 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
903
910
|
border: none;
|
|
904
911
|
pointer-events: auto;
|
|
905
912
|
|
|
906
|
-
--ft-button-internal-font-size: ${
|
|
913
|
+
--ft-button-internal-font-size: ${Oi.fontSize};
|
|
907
914
|
--ft-button-internal-line-height: calc(var(--ft-button-internal-font-size) + 2px);
|
|
908
|
-
--ft-button-internal-color: ${
|
|
909
|
-
|
|
915
|
+
--ft-button-internal-color: ${Oi.color};
|
|
916
|
+
${ut(oi.size,Oi.iconSize)};
|
|
910
917
|
--ft-button-internal-vertical-padding: 6px;
|
|
911
918
|
--ft-button-internal-horizontal-padding: 8px;
|
|
912
|
-
${
|
|
913
|
-
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height),
|
|
919
|
+
${ut(Ye.color,Oi.rippleColor)};
|
|
920
|
+
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height), ${Oi.iconSize});
|
|
914
921
|
|
|
915
|
-
border-radius: ${
|
|
922
|
+
border-radius: ${Oi.borderRadius};
|
|
916
923
|
padding: var(--ft-button-internal-vertical-padding) var(--ft-button-internal-horizontal-padding);
|
|
917
|
-
background-color: ${
|
|
924
|
+
background-color: ${Oi.backgroundColor};
|
|
918
925
|
color: var(--ft-button-internal-color);
|
|
919
926
|
-webkit-mask-image: radial-gradient(white, black);
|
|
920
927
|
}
|
|
@@ -926,7 +933,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
926
933
|
.ft-button--dense {
|
|
927
934
|
--ft-button-internal-vertical-padding: 2px;
|
|
928
935
|
--ft-button-internal-horizontal-padding: 4px;
|
|
929
|
-
border-radius: ${
|
|
936
|
+
border-radius: ${Ci};
|
|
930
937
|
}
|
|
931
938
|
|
|
932
939
|
.ft-button--round {
|
|
@@ -935,13 +942,13 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
935
942
|
|
|
936
943
|
.ft-button[disabled] {
|
|
937
944
|
filter: grayscale(1);
|
|
938
|
-
opacity: ${
|
|
945
|
+
opacity: ${Oi.opacityDisabled};
|
|
939
946
|
}
|
|
940
947
|
|
|
941
948
|
.ft-button.ft-button--primary {
|
|
942
|
-
background-color: ${
|
|
943
|
-
--ft-button-internal-color: ${
|
|
944
|
-
${
|
|
949
|
+
background-color: ${ki.backgroundColor};
|
|
950
|
+
--ft-button-internal-color: ${ki.color};
|
|
951
|
+
${ut(Ye.color,ki.rippleColor)};
|
|
945
952
|
}
|
|
946
953
|
|
|
947
954
|
.ft-button.ft-button--outlined {
|
|
@@ -959,8 +966,8 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
959
966
|
text-overflow: ellipsis;
|
|
960
967
|
display: block;
|
|
961
968
|
margin: 0 var(--ft-button-internal-horizontal-padding);
|
|
962
|
-
${
|
|
963
|
-
${
|
|
969
|
+
${ut(De.fontSize,"var(--ft-button-internal-font-size)")};
|
|
970
|
+
${ut(De.lineHeight,"var(--ft-button-internal-content-height)")};
|
|
964
971
|
}
|
|
965
972
|
|
|
966
973
|
.ft-button--safari-fix .ft-button--label {
|
|
@@ -977,28 +984,27 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
977
984
|
display: none;
|
|
978
985
|
}
|
|
979
986
|
|
|
980
|
-
|
|
987
|
+
ft-icon {
|
|
981
988
|
flex-shrink: 0;
|
|
982
|
-
width: var(--mdc-icon-size);
|
|
983
989
|
}
|
|
984
990
|
|
|
985
|
-
.ft-button--label[hidden] +
|
|
991
|
+
.ft-button--label[hidden] + ft-icon {
|
|
986
992
|
margin: 0 calc(var(--ft-button-internal-horizontal-padding) * -1);
|
|
987
993
|
padding: 0 var(--ft-button-internal-vertical-padding);
|
|
988
994
|
}
|
|
989
995
|
|
|
990
|
-
.ft-button:not(.ft-button--trailing-icon)
|
|
996
|
+
.ft-button:not(.ft-button--trailing-icon) ft-icon,
|
|
991
997
|
.ft-button:not(.ft-button--trailing-icon) ft-loader {
|
|
992
998
|
order: -1;
|
|
993
999
|
}
|
|
994
1000
|
|
|
995
1001
|
ft-loader {
|
|
996
|
-
${
|
|
997
|
-
${
|
|
1002
|
+
${ut(gi.size,Oi.iconSize)};
|
|
1003
|
+
${ut(gi.color,"var(--ft-button-internal-color)")};
|
|
998
1004
|
}
|
|
999
|
-
`]}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"
|
|
1005
|
+
`]}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":$t,"ft-no-text-select":!0};return this.addTooltip(Z`
|
|
1000
1006
|
<button part="button"
|
|
1001
|
-
class="${
|
|
1007
|
+
class="${jt(t)}"
|
|
1002
1008
|
aria-label="${this.getLabel()}"
|
|
1003
1009
|
?disabled=${this.isDisabled()}>
|
|
1004
1010
|
<ft-ripple part="ripple" ?disabled=${this.isDisabled()}></ft-ripple>
|
|
@@ -1010,15 +1016,15 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1010
1016
|
</ft-typography>
|
|
1011
1017
|
${this.resolveIcon()}
|
|
1012
1018
|
</button>
|
|
1013
|
-
`)}addTooltip(t){return this.hasTextContent()||0===this.getLabel().trim().length?t:
|
|
1019
|
+
`)}addTooltip(t){return this.hasTextContent()||0===this.getLabel().trim().length?t:Z`
|
|
1014
1020
|
<ft-tooltip part="tooltip"
|
|
1015
1021
|
text="${this.getLabel()}"
|
|
1016
1022
|
position="${this.tooltipPosition}">
|
|
1017
1023
|
${t}
|
|
1018
1024
|
</ft-tooltip>
|
|
1019
|
-
`}resolveIcon(){return this.loading?
|
|
1020
|
-
<ft-loader></ft-loader> `:this.icon?
|
|
1021
|
-
<
|
|
1025
|
+
`}resolveIcon(){return this.loading?Z`
|
|
1026
|
+
<ft-loader></ft-loader> `:this.icon?Z`
|
|
1027
|
+
<ft-icon variant="material">${this.icon}</ft-icon> `:V}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}}Ei.elementDefinitions={"ft-ripple":Ge,"ft-tooltip":yi,"ft-typography":Ke,"ft-icon":ni,"ft-loader":mi},$i([n({type:Boolean})],Ei.prototype,"primary",void 0),$i([n({type:Boolean})],Ei.prototype,"outlined",void 0),$i([n({type:Boolean})],Ei.prototype,"disabled",void 0),$i([n({type:Boolean})],Ei.prototype,"dense",void 0),$i([n({type:Boolean})],Ei.prototype,"round",void 0),$i([n({type:String})],Ei.prototype,"label",void 0),$i([n({type:String})],Ei.prototype,"icon",void 0),$i([n({type:Boolean})],Ei.prototype,"trailingIcon",void 0),$i([n({type:Boolean})],Ei.prototype,"loading",void 0),$i([n({type:String})],Ei.prototype,"tooltipPosition",void 0),$i([l(".ft-button")],Ei.prototype,"button",void 0),$i([l(".ft-button--label slot")],Ei.prototype,"slottedContent",void 0),c("ft-button")(Ei);var Ni=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 Ri extends CustomEvent{constructor(t){super("row-click",{detail:t})}}const zi={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(bt.colorOnSurfaceHigh,"Design system"),titleFont:ft.external(bt.titleFont,"Design system"),contentFont:ft.external(bt.contentFont,"Design system")},Mi=t=>Z`${t}`,Fi=(t,e)=>t-e;class Ui extends xt{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 Z`
|
|
1022
1028
|
<style>
|
|
1023
1029
|
.table {
|
|
1024
1030
|
grid-template-columns: repeat(${this.columns.length}, minmax(min-content, auto));
|
|
@@ -1026,26 +1032,27 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1026
1032
|
</style>
|
|
1027
1033
|
<div class="table">
|
|
1028
1034
|
<div class="header">
|
|
1029
|
-
${
|
|
1035
|
+
${Ut(this.columns,((t,e)=>"header-cell-"+e),((t,e)=>this.renderHeader(t,e)))}
|
|
1030
1036
|
</div>
|
|
1031
|
-
${
|
|
1037
|
+
${Ut(t,((t,e)=>"row-"+e),((t,e)=>Z`
|
|
1032
1038
|
<div class="row"
|
|
1033
|
-
@click=${()=>this.dispatchEvent(new
|
|
1034
|
-
${
|
|
1039
|
+
@click=${()=>this.dispatchEvent(new Ri(t))}>
|
|
1040
|
+
${Ut(this.columns,((t,i)=>"cell-"+e+" "+i),(i=>this.renderCell(i,t,e)))}
|
|
1035
1041
|
</div>
|
|
1036
1042
|
`))}
|
|
1037
1043
|
</div>
|
|
1038
|
-
`}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:
|
|
1039
|
-
<div class="
|
|
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:Fi,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,i){const o={"header-cell":!0,"header-cell--sticky":this.stickyHeaders};return Z`
|
|
1045
|
+
<div class="${e.classMap(o)}">
|
|
1040
1046
|
<div class="column-title-container">
|
|
1041
1047
|
<span class="column-title">${t.title}</span>
|
|
1042
|
-
${this.renderColumnSort(t,
|
|
1048
|
+
${this.renderColumnSort(t,i)}
|
|
1043
1049
|
</div>
|
|
1050
|
+
${t.filter?Z`
|
|
1044
1051
|
<div class="column-filter">
|
|
1045
|
-
${this.renderColumnFilter(t,
|
|
1046
|
-
</div
|
|
1052
|
+
${this.renderColumnFilter(t,i)}
|
|
1053
|
+
</div>`:null}
|
|
1047
1054
|
</div>
|
|
1048
|
-
`}renderColumnSort(t,e){var i;const o=this.currentSort&&this.currentSort.column===e,n=o?"asc"===this.currentSort.order?"expand_more":"expand_less":"unfold_more";return
|
|
1055
|
+
`}renderColumnSort(t,e){var i;const o=this.currentSort&&this.currentSort.column===e,n=o?"asc"===this.currentSort.order?"expand_more":"expand_less":"unfold_more";return Z`
|
|
1049
1056
|
<ft-button
|
|
1050
1057
|
round
|
|
1051
1058
|
dense
|
|
@@ -1054,21 +1061,21 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1054
1061
|
label="Sort ${t.title}"
|
|
1055
1062
|
@click=${()=>{var t;o?"asc"===(null===(t=this.currentSort)||void 0===t?void 0:t.order)?this.currentSort={column:e,order:"desc"}:this.currentSort=void 0:this.currentSort={column:e,order:"asc"}}}
|
|
1056
1063
|
></ft-button>
|
|
1057
|
-
`}renderColumnFilter(t,e){var i,o;const n=t=>{this.filters[e]={value:t.detail},this.requestUpdate()};switch(null!==(i=t.filter)&&void 0!==i?i:"text"){case"text":return
|
|
1064
|
+
`}renderColumnFilter(t,e){var i,o;const n=t=>{this.filters[e]={value:t.detail},this.requestUpdate()};switch(null!==(i=t.filter)&&void 0!==i?i:"text"){case"text":return Z`
|
|
1058
1065
|
<ft-text-field
|
|
1059
1066
|
label="Search ${t.title}"
|
|
1060
1067
|
@live-change="${n}"
|
|
1061
1068
|
></ft-text-field>
|
|
1062
|
-
`;case"select":const i=null!==(o=this.selectData[e])&&void 0!==o?o:[];return i.length?
|
|
1069
|
+
`;case"select":const i=null!==(o=this.selectData[e])&&void 0!==o?o:[];return i.length?Z`
|
|
1063
1070
|
<ft-select label="Filter ${t.title}" @change=${n}>
|
|
1064
1071
|
<ft-select-option></ft-select-option>
|
|
1065
|
-
${i.map((t=>
|
|
1072
|
+
${i.map((t=>Z`
|
|
1066
1073
|
<ft-select-option value="${t}" label="${t}"></ft-select-option>
|
|
1067
1074
|
`))}
|
|
1068
1075
|
</ft-select>
|
|
1069
|
-
`:null}return null}renderCell(t,e,i){var o;const n=null!==(o=t.render)&&void 0!==o?o:
|
|
1076
|
+
`:null}return null}renderCell(t,e,i){var o;const n=null!==(o=t.render)&&void 0!==o?o:Mi;return Z`
|
|
1070
1077
|
<div class="cell">${(t=>{const e=n(t,i);return"string"==typeof e?Dt(e):e})(this.getValue(t,e))}</div>
|
|
1071
|
-
`}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)}}
|
|
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)}}Ui.styles=x`
|
|
1072
1079
|
:host {
|
|
1073
1080
|
display: block;
|
|
1074
1081
|
}
|
|
@@ -1084,10 +1091,16 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1084
1091
|
.header-cell {
|
|
1085
1092
|
display: flex;
|
|
1086
1093
|
flex-direction: column;
|
|
1087
|
-
background: ${
|
|
1088
|
-
color: ${
|
|
1094
|
+
background: ${zi.headerBackground};
|
|
1095
|
+
color: ${zi.colorOnSurfaceHigh};
|
|
1089
1096
|
padding: .5rem 1rem;
|
|
1090
|
-
font-family: ${
|
|
1097
|
+
font-family: ${zi.titleFont};
|
|
1098
|
+
}
|
|
1099
|
+
|
|
1100
|
+
.header-cell--sticky {
|
|
1101
|
+
top: 0;
|
|
1102
|
+
z-index: ${zi.stickyHeaderZIndex};
|
|
1103
|
+
position: sticky;
|
|
1091
1104
|
}
|
|
1092
1105
|
|
|
1093
1106
|
.header-cell:first-of-type {
|
|
@@ -1104,14 +1117,17 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1104
1117
|
}
|
|
1105
1118
|
|
|
1106
1119
|
.column-title-container ft-button {
|
|
1107
|
-
${
|
|
1108
|
-
${
|
|
1120
|
+
${ut(Oi.backgroundColor,zi.headerBackground)};
|
|
1121
|
+
${ut(Oi.color,zi.colorOnSurfaceHigh)};
|
|
1109
1122
|
}
|
|
1110
1123
|
|
|
1111
1124
|
.column-title {
|
|
1112
1125
|
white-space: nowrap;
|
|
1113
1126
|
text-transform: uppercase;
|
|
1114
1127
|
margin-right: .5rem;
|
|
1128
|
+
font-weight: normal;
|
|
1129
|
+
letter-spacing: 1.5px;
|
|
1130
|
+
font-size: 0.8em;
|
|
1115
1131
|
}
|
|
1116
1132
|
|
|
1117
1133
|
.column-filter {
|
|
@@ -1131,29 +1147,29 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1131
1147
|
|
|
1132
1148
|
.cell {
|
|
1133
1149
|
padding: 1rem;
|
|
1134
|
-
border-left: 1px solid ${
|
|
1135
|
-
border-bottom: 1px solid ${
|
|
1150
|
+
border-left: 1px solid ${zi.headerBackground};
|
|
1151
|
+
border-bottom: 1px solid ${zi.headerBackground};
|
|
1136
1152
|
overflow-x: auto;
|
|
1137
1153
|
display: flex;
|
|
1138
1154
|
align-items: center;
|
|
1139
|
-
font-family: ${
|
|
1155
|
+
font-family: ${zi.contentFont};
|
|
1140
1156
|
}
|
|
1141
1157
|
|
|
1142
1158
|
/* Even is 2n+1 and odd is 2n because of the header */
|
|
1143
1159
|
.row:nth-child(2n) > .cell {
|
|
1144
|
-
background: ${
|
|
1160
|
+
background: ${zi.oddRowBackground};
|
|
1145
1161
|
}
|
|
1146
1162
|
|
|
1147
1163
|
.row:nth-child(2n + 1) > .cell {
|
|
1148
|
-
background: ${
|
|
1164
|
+
background: ${zi.evenRowBackground};
|
|
1149
1165
|
}
|
|
1150
1166
|
|
|
1151
1167
|
.row:hover > .cell {
|
|
1152
|
-
background: ${
|
|
1168
|
+
background: ${zi.rowHoverBackground};
|
|
1153
1169
|
}
|
|
1154
1170
|
|
|
1155
1171
|
.cell:last-of-type {
|
|
1156
|
-
border-right: 1px solid ${
|
|
1172
|
+
border-right: 1px solid ${zi.headerBackground};
|
|
1157
1173
|
}
|
|
1158
1174
|
|
|
1159
1175
|
.row:last-of-type .cell:first-of-type {
|
|
@@ -1167,4 +1183,4 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
1167
1183
|
.hidden {
|
|
1168
1184
|
visibility: hidden;
|
|
1169
1185
|
}
|
|
1170
|
-
`,
|
|
1186
|
+
`,Ni([n({attribute:!1})],Ui.prototype,"data",void 0),Ni([n({attribute:!1})],Ui.prototype,"columns",void 0),Ni([n({attribute:!1})],Ui.prototype,"sort",void 0),Ni([n()],Ui.prototype,"stickyHeaders",void 0),Ni([s()],Ui.prototype,"currentSort",void 0),c("ft-filterable-table")(Ui),t.FtFilterableTable=Ui,t.FtFilterableTableCssVariables=zi,t.RowClickEvent=Ri,Object.defineProperty(t,"t",{value:!0})}({},classMap);
|