@fluid-topics/ft-filter 0.2.15 → 0.2.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/ft-filter-level.d.ts +1 -0
- package/build/ft-filter-level.js +18 -0
- package/build/ft-filter.d.ts +2 -0
- package/build/ft-filter.js +14 -4
- package/build/ft-filter.light.js +94 -71
- package/build/ft-filter.min.js +242 -220
- package/package.json +10 -10
- package/build/ft-filter.inline-styles.js +0 -1303
- package/build/inline-styles.d.ts +0 -2
- package/build/inline-styles.js +0 -6
package/build/ft-filter.min.js
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
*
|
|
15
15
|
* @see https://github.com/webcomponents/polyfills/tree/master/packages/scoped-custom-element-registry
|
|
16
16
|
*/
|
|
17
|
-
if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,e=window.customElements.define,i=window.customElements.get,o=window.customElements,s=new WeakMap,n=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,s){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(s))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const l=s.prototype.attributeChangedCallback,a=new Set(s.observedAttributes||[]);d(s,a,l);const h={elementClass:s,connectedCallback:s.prototype.connectedCallback,disconnectedCallback:s.prototype.disconnectedCallback,adoptedCallback:s.prototype.adoptedCallback,attributeChangedCallback:l,formAssociated:s.formAssociated,formAssociatedCallback:s.prototype.formAssociatedCallback,formDisabledCallback:s.prototype.formDisabledCallback,formResetCallback:s.prototype.formResetCallback,formStateRestoreCallback:s.prototype.formStateRestoreCallback,observedAttributes:a};this._definitionsByTag.set(t,h),this._definitionsByClass.set(s,h);let c=i.call(o,t);c||(c=p(t),e.call(o,t,c)),this===window.customElements&&(r.set(s,h),h.standInClass=c);const f=this._awaitingUpgrade.get(t);if(f){this._awaitingUpgrade.delete(t);for(const t of f)n.delete(t),u(t,h,!0)}const v=this._whenDefinedPromises.get(t);return void 0!==v&&(v.resolve(s),this._whenDefinedPromises.delete(t)),s}upgrade(){b.push(this),o.upgrade.apply(o,arguments),b.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),s.set(e,i),e},window.HTMLElement.prototype=t.prototype;const h=t=>t===document||t instanceof ShadowRoot,c=t=>{let e=t.getRootNode();if(!h(e)){const t=b[b.length-1];if(t instanceof CustomElementRegistry)return t;e=t.getRootNode(),h(e)||(e=l.get(e)?.getRootNode()||document)}return e.customElements},p=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,s=o._getDefinition(e);return s?u(i,s):n.set(i,o),i}connectedCallback(){const t=s.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):n.get(this)._upgradeWhenDefined(this,e,!0)}disconnectedCallback(){const t=s.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):n.get(this)._upgradeWhenDefined(this,e,!1)}adoptedCallback(){s.get(this)?.adoptedCallback?.apply(this,arguments)}formAssociatedCallback(){const t=s.get(this);t&&t.formAssociated&&t?.formAssociatedCallback?.apply(this,arguments)}formDisabledCallback(){const t=s.get(this);t?.formAssociated&&t?.formDisabledCallback?.apply(this,arguments)}formResetCallback(){const t=s.get(this);t?.formAssociated&&t?.formResetCallback?.apply(this,arguments)}formStateRestoreCallback(){const t=s.get(this);t?.formAssociated&&t?.formStateRestoreCallback?.apply(this,arguments)}},d=(t,e,i)=>{if(0===e.size||void 0===i)return;const o=t.prototype.setAttribute;o&&(t.prototype.setAttribute=function(t,s){const n=t.toLowerCase();if(e.has(n)){const t=this.getAttribute(n);o.call(this,n,s),i.call(this,n,t,s)}else o.call(this,n,s)});const s=t.prototype.removeAttribute;s&&(t.prototype.removeAttribute=function(t){const o=t.toLowerCase();if(e.has(o)){const t=this.getAttribute(o);s.call(this,o),i.call(this,o,t,null)}else s.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),s.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)},v=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const e=v.apply(this,arguments);return t.customElements&&(e.customElements=t.customElements),e};let b=[document];const x=(t,e,i)=>{const o=(i?Object.getPrototypeOf(i):t.prototype)[e];t.prototype[e]=function(){b.push(this);const t=o.apply(i||this,arguments);return void 0!==t&&l.set(t,this),b.pop(),t}};x(ShadowRoot,"createElement",document),x(ShadowRoot,"importNode",document),x(Element,"insertAdjacentHTML");const y=(t,e)=>{const i=Object.getOwnPropertyDescriptor(t.prototype,e);Object.defineProperty(t.prototype,e,{...i,set(t){b.push(this),i.set.call(this,t),b.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!==s.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 n{constructor(t){const e=new Map;t.forEach(((t,i)=>{const o=t.getAttribute("name"),s=e.get(o)||[];this[+i]=t,s.push(t),e.set(o,s)})),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=s.get(i);t&&!0!==t.formAssociated||e.push(i)}return new n(e)}})}}try{window.customElements.define("custom-element",null)}catch(
|
|
17
|
+
if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,e=window.customElements.define,i=window.customElements.get,o=window.customElements,s=new WeakMap,n=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,s){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(s))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const l=s.prototype.attributeChangedCallback,a=new Set(s.observedAttributes||[]);d(s,a,l);const h={elementClass:s,connectedCallback:s.prototype.connectedCallback,disconnectedCallback:s.prototype.disconnectedCallback,adoptedCallback:s.prototype.adoptedCallback,attributeChangedCallback:l,formAssociated:s.formAssociated,formAssociatedCallback:s.prototype.formAssociatedCallback,formDisabledCallback:s.prototype.formDisabledCallback,formResetCallback:s.prototype.formResetCallback,formStateRestoreCallback:s.prototype.formStateRestoreCallback,observedAttributes:a};this._definitionsByTag.set(t,h),this._definitionsByClass.set(s,h);let c=i.call(o,t);c||(c=p(t),e.call(o,t,c)),this===window.customElements&&(r.set(s,h),h.standInClass=c);const f=this._awaitingUpgrade.get(t);if(f){this._awaitingUpgrade.delete(t);for(const t of f)n.delete(t),u(t,h,!0)}const v=this._whenDefinedPromises.get(t);return void 0!==v&&(v.resolve(s),this._whenDefinedPromises.delete(t)),s}upgrade(){b.push(this),o.upgrade.apply(o,arguments),b.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),s.set(e,i),e},window.HTMLElement.prototype=t.prototype;const h=t=>t===document||t instanceof ShadowRoot,c=t=>{let e=t.getRootNode();if(!h(e)){const t=b[b.length-1];if(t instanceof CustomElementRegistry)return t;e=t.getRootNode(),h(e)||(e=l.get(e)?.getRootNode()||document)}return e.customElements},p=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,s=o._getDefinition(e);return s?u(i,s):n.set(i,o),i}connectedCallback(){const t=s.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):n.get(this)._upgradeWhenDefined(this,e,!0)}disconnectedCallback(){const t=s.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):n.get(this)._upgradeWhenDefined(this,e,!1)}adoptedCallback(){s.get(this)?.adoptedCallback?.apply(this,arguments)}formAssociatedCallback(){const t=s.get(this);t&&t.formAssociated&&t?.formAssociatedCallback?.apply(this,arguments)}formDisabledCallback(){const t=s.get(this);t?.formAssociated&&t?.formDisabledCallback?.apply(this,arguments)}formResetCallback(){const t=s.get(this);t?.formAssociated&&t?.formResetCallback?.apply(this,arguments)}formStateRestoreCallback(){const t=s.get(this);t?.formAssociated&&t?.formStateRestoreCallback?.apply(this,arguments)}},d=(t,e,i)=>{if(0===e.size||void 0===i)return;const o=t.prototype.setAttribute;o&&(t.prototype.setAttribute=function(t,s){const n=t.toLowerCase();if(e.has(n)){const t=this.getAttribute(n);o.call(this,n,s),i.call(this,n,t,s)}else o.call(this,n,s)});const s=t.prototype.removeAttribute;s&&(t.prototype.removeAttribute=function(t){const o=t.toLowerCase();if(e.has(o)){const t=this.getAttribute(o);s.call(this,o),i.call(this,o,t,null)}else s.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),s.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)},v=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const e=v.apply(this,arguments);return t.customElements&&(e.customElements=t.customElements),e};let b=[document];const x=(t,e,i)=>{const o=(i?Object.getPrototypeOf(i):t.prototype)[e];t.prototype[e]=function(){b.push(this);const t=o.apply(i||this,arguments);return void 0!==t&&l.set(t,this),b.pop(),t}};x(ShadowRoot,"createElement",document),x(ShadowRoot,"importNode",document),x(Element,"insertAdjacentHTML");const y=(t,e)=>{const i=Object.getOwnPropertyDescriptor(t.prototype,e);Object.defineProperty(t.prototype,e,{...i,set(t){b.push(this),i.set.call(this,t),b.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!==s.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 n{constructor(t){const e=new Map;t.forEach(((t,i)=>{const o=t.getAttribute("name"),s=e.get(o)||[];this[+i]=t,s.push(t),e.set(o,s)})),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=s.get(i);t&&!0!==t.formAssociated||e.push(i)}return new n(e)}})}}try{window.customElements.define("custom-element",null)}catch(mi){const t=window.customElements.define;window.customElements.define=(e,i,o)=>{try{t.bind(window.customElements)(e,i,o)}catch(t){console.warn(e,i,o,t)}}}class e{constructor(t=0){this.timeout=t,this.callbacks=[]}run(t,e){this.callbacks=[t],this.debounce(e)}queue(t,e){this.callbacks.push(t),this.debounce(e)}cancel(){null!=this._debounce&&window.clearTimeout(this._debounce)}debounce(t){this.cancel(),this._debounce=window.setTimeout((()=>this.runCallbacks()),null!=t?t:this.timeout)}runCallbacks(){for(let t of this.callbacks)t();this.callbacks=[]}}
|
|
18
18
|
/**
|
|
19
19
|
* @license
|
|
20
20
|
* Copyright 2017 Google LLC
|
|
@@ -50,40 +50,39 @@ var l;const a=null!=(null===(l=window.HTMLSlotElement)||void 0===l?void 0:l.prot
|
|
|
50
50
|
* @license
|
|
51
51
|
* Copyright 2017 Google LLC
|
|
52
52
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
53
|
-
*/const c=t=>e=>{window.customElements.get(t)||window.customElements.define(t,e)};
|
|
53
|
+
*/const c=t=>e=>{window.customElements.get(t)||window.customElements.define(t,e)};function p(t,e){const i=()=>JSON.parse(JSON.stringify(t));return o({type:Object,converter:{fromAttribute:t=>{if(null==t)return i();try{return JSON.parse(t)}catch{return i()}},toAttribute:t=>JSON.stringify(t)},...null!=e?e:{}})}
|
|
54
54
|
/**
|
|
55
55
|
* @license
|
|
56
56
|
* Copyright 2019 Google LLC
|
|
57
57
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
58
|
-
*/
|
|
59
|
-
const p=window.ShadowRoot&&(void 0===window.ShadyCSS||window.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,d=Symbol(),f=new Map;class u{constructor(t,e){if(this._$cssResult$=!0,e!==d)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t}get styleSheet(){let t=f.get(this.cssText);return p&&void 0===t&&(f.set(this.cssText,t=new CSSStyleSheet),t.replaceSync(this.cssText)),t}toString(){return this.cssText}}const v=t=>new u("string"==typeof t?t:t+"",d),b=(t,...e)=>{const i=1===t.length?t[0]:e.reduce(((e,i,o)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+t[o+1]),t[0]);return new u(i,d)},x=(t,e)=>{p?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=p?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return v(e)})(t):t
|
|
58
|
+
*/const d=window.ShadowRoot&&(void 0===window.ShadyCSS||window.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,f=Symbol(),u=new Map;class v{constructor(t,e){if(this._$cssResult$=!0,e!==f)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t}get styleSheet(){let t=u.get(this.cssText);return d&&void 0===t&&(u.set(this.cssText,t=new CSSStyleSheet),t.replaceSync(this.cssText)),t}toString(){return this.cssText}}const b=t=>new v("string"==typeof t?t:t+"",f),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 v(i,f)},y=(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)}))},g=d?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return b(e)})(t):t
|
|
60
59
|
/**
|
|
61
60
|
* @license
|
|
62
61
|
* Copyright 2017 Google LLC
|
|
63
62
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
64
|
-
*/;var
|
|
63
|
+
*/;var m;const $=window.trustedTypes,w=$?$.emptyScript:"",k=window.reactiveElementPolyfillSupport,O={toAttribute(t,e){switch(e){case Boolean:t=t?w: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),C={attribute:!0,type:String,converter:O,reflect:!1,hasChanged:S};class E 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=C){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 s=this[t];this[e]=o,this.requestUpdate(t,s,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||C}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(g(t))}else void 0!==t&&e.push(g(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 y(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=C){var o,s;const n=this.constructor._$Eh(t,i);if(void 0!==n&&!0===i.reflect){const r=(null!==(s=null===(o=i.converter)||void 0===o?void 0:o.toAttribute)&&void 0!==s?s:O.toAttribute)(e,i.type);this._$Ei=t,null==r?this.removeAttribute(n):this.setAttribute(n,r),this._$Ei=null}}_$AK(t,e){var i,o,s;const n=this.constructor,r=n._$Eu.get(t);if(void 0!==r&&this._$Ei!==r){const t=n.getPropertyOptions(r),l=t.converter,a=null!==(s=null!==(o=null===(i=l)||void 0===i?void 0:i.fromAttribute)&&void 0!==o?o:"function"==typeof l?l:null)&&void 0!==s?s: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._$EC&&(this._$EC=new Map),this._$EC.set(t,i))):o=!1),!this.isUpdatePending&&o&&(this._$Ep=this._$E_())}async _$E_(){this.isUpdatePending=!0;try{await this._$Ep}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Et&&(this._$Et.forEach(((t,e)=>this[e]=t)),this._$Et=void 0);let e=!1;const i=this._$AL;try{e=this.shouldUpdate(i),e?(this.willUpdate(i),null===(t=this._$Eg)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostUpdate)||void 0===e?void 0:e.call(t)})),this.update(i)):this._$EU()}catch(t){throw e=!1,this._$EU(),t}e&&this._$AE(i)}willUpdate(t){}_$AE(t){var e;null===(e=this._$Eg)||void 0===e||e.forEach((t=>{var e;return null===(e=t.hostUpdated)||void 0===e?void 0:e.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EU(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$Ep}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,e)=>this._$ES(e,this[e],t))),this._$EC=void 0),this._$EU()}updated(t){}firstUpdated(t){}}
|
|
65
64
|
/**
|
|
66
65
|
* @license
|
|
67
66
|
* Copyright 2017 Google LLC
|
|
68
67
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
69
68
|
*/
|
|
70
|
-
var E
|
|
69
|
+
var N;E.finalized=!0,E.elementProperties=new Map,E.elementStyles=[],E.shadowRootOptions={mode:"open"},null==k||k({ReactiveElement:E}),(null!==(m=globalThis.reactiveElementVersions)&&void 0!==m?m:globalThis.reactiveElementVersions=[]).push("1.3.2");const z=globalThis.trustedTypes,M=z?z.createPolicy("lit-html",{createHTML:t=>t}):void 0,R=`lit$${(Math.random()+"").slice(9)}$`,B="?"+R,F=`<${B}>`,j=document,U=(t="")=>j.createComment(t),D=t=>null===t||"object"!=typeof t&&"function"!=typeof t,L=Array.isArray,T=t=>{var e;return L(t)||"function"==typeof(null===(e=t)||void 0===e?void 0:e[Symbol.iterator])},A=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,_=/-->/g,P=/>/g,I=/>|[ \n\r](?:([^\s"'>=/]+)([ \n\r]*=[ \n\r]*(?:[^ \n\r"'`<>=]|("|')|))|$)/g,H=/'/g,W=/"/g,K=/^(?:script|style|textarea|title)$/i,V=(t=>(e,...i)=>({_$litType$:t,strings:e,values:i}))(1),Z=Symbol.for("lit-noChange"),J=Symbol.for("lit-nothing"),q=new WeakMap,X=j.createTreeWalker(j,129,null,!1),Y=(t,e)=>{const i=t.length-1,o=[];let s,n=2===e?"<svg>":"",r=A;for(let e=0;e<i;e++){const i=t[e];let l,a,h=-1,c=0;for(;c<i.length&&(r.lastIndex=c,a=r.exec(i),null!==a);)c=r.lastIndex,r===A?"!--"===a[1]?r=_:void 0!==a[1]?r=P:void 0!==a[2]?(K.test(a[2])&&(s=RegExp("</"+a[2],"g")),r=I):void 0!==a[3]&&(r=I):r===I?">"===a[0]?(r=null!=s?s:A,h=-1):void 0===a[1]?h=-2:(h=r.lastIndex-a[2].length,l=a[1],r=void 0===a[3]?I:'"'===a[3]?W:H):r===W||r===H?r=I:r===_||r===P?r=A:(r=I,s=void 0);const p=r===I&&t[e+1].startsWith("/>")?" ":"";n+=r===A?i+F:h>=0?(o.push(l),i.slice(0,h)+"$lit$"+i.slice(h)+R+p):i+R+(-2===h?(o.push(void 0),e):p)}const l=n+(t[i]||"<?>")+(2===e?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==M?M.createHTML(l):l,o]};class G{constructor({strings:t,_$litType$:e},i){let o;this.parts=[];let s=0,n=0;const r=t.length-1,l=this.parts,[a,h]=Y(t,e);if(this.el=G.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(R)){const i=h[n++];if(t.push(e),void 0!==i){const t=o.getAttribute(i.toLowerCase()+"$lit$").split(R),e=/([.?@])?(.*)/.exec(i);l.push({type:1,index:s,name:e[2],strings:t,ctor:"."===e[1]?ot:"?"===e[1]?nt:"@"===e[1]?rt:it})}else l.push({type:6,index:s})}for(const e of t)o.removeAttribute(e)}if(K.test(o.tagName)){const t=o.textContent.split(R),e=t.length-1;if(e>0){o.textContent=z?z.emptyScript:"";for(let i=0;i<e;i++)o.append(t[i],U()),X.nextNode(),l.push({type:2,index:++s});o.append(t[e],U())}}}else if(8===o.nodeType)if(o.data===B)l.push({type:2,index:s});else{let t=-1;for(;-1!==(t=o.data.indexOf(R,t+1));)l.push({type:7,index:s}),t+=R.length-1}s++}}static createElement(t,e){const i=j.createElement("template");return i.innerHTML=t,i}}function Q(t,e,i=t,o){var s,n,r,l;if(e===Z)return e;let a=void 0!==o?null===(s=i._$Cl)||void 0===s?void 0:s[o]:i._$Cu;const h=D(e)?void 0:e._$litDirective$;return(null==a?void 0:a.constructor)!==h&&(null===(n=null==a?void 0:a._$AO)||void 0===n||n.call(a,!1),void 0===h?a=void 0:(a=new h(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=Q(t,a._$AS(t,e.values),a,o)),e}class tt{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,s=(null!==(e=null==t?void 0:t.creationScope)&&void 0!==e?e:j).importNode(i,!0);X.currentNode=s;let n=X.nextNode(),r=0,l=0,a=o[0];for(;void 0!==a;){if(r===a.index){let e;2===a.type?e=new et(n,n.nextSibling,this,t):1===a.type?e=new a.ctor(n,a.name,a.strings,this,t):6===a.type&&(e=new lt(n,this,t)),this.v.push(e),a=o[++l]}r!==(null==a?void 0:a.index)&&(n=X.nextNode(),r++)}return s}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 et{constructor(t,e,i,o){var s;this.type=2,this._$AH=J,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=o,this._$Cg=null===(s=null==o?void 0:o.isConnected)||void 0===s||s}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=Q(this,t,e),D(t)?t===J||null==t||""===t?(this._$AH!==J&&this._$AR(),this._$AH=J):t!==this._$AH&&t!==Z&&this.$(t):void 0!==t._$litType$?this.T(t):void 0!==t.nodeType?this.k(t):T(t)?this.S(t):this.$(t)}M(t,e=this._$AB){return this._$AA.parentNode.insertBefore(t,e)}k(t){this._$AH!==t&&(this._$AR(),this._$AH=this.M(t))}$(t){this._$AH!==J&&D(this._$AH)?this._$AA.nextSibling.data=t:this.k(j.createTextNode(t)),this._$AH=t}T(t){var e;const{values:i,_$litType$:o}=t,s="number"==typeof o?this._$AC(t):(void 0===o.el&&(o.el=G.createElement(o.h,this.options)),o);if((null===(e=this._$AH)||void 0===e?void 0:e._$AD)===s)this._$AH.m(i);else{const t=new tt(s,this),e=t.p(this.options);t.m(i),this.k(e),this._$AH=t}}_$AC(t){let e=q.get(t.strings);return void 0===e&&q.set(t.strings,e=new G(t)),e}S(t){L(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,o=0;for(const s of t)o===e.length?e.push(i=new et(this.M(U()),this.M(U()),this,this.options)):i=e[o],i._$AI(s),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 it{constructor(t,e,i,o,s){this.type=1,this._$AH=J,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=s,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=J}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,i,o){const s=this.strings;let n=!1;if(void 0===s)t=Q(this,t,e,0),n=!D(t)||t!==this._$AH&&t!==Z,n&&(this._$AH=t);else{const o=t;let r,l;for(t=s[0],r=0;r<s.length-1;r++)l=Q(this,o[i+r],e,r),l===Z&&(l=this._$AH[r]),n||(n=!D(l)||l!==this._$AH[r]),l===J?t=J:t!==J&&(t+=(null!=l?l:"")+s[r+1]),this._$AH[r]=l}n&&!o&&this.C(t)}C(t){t===J?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class ot extends it{constructor(){super(...arguments),this.type=3}C(t){this.element[this.name]=t===J?void 0:t}}const st=z?z.emptyScript:"";class nt extends it{constructor(){super(...arguments),this.type=4}C(t){t&&t!==J?this.element.setAttribute(this.name,st):this.element.removeAttribute(this.name)}}class rt extends it{constructor(t,e,i,o,s){super(t,e,i,o,s),this.type=5}_$AI(t,e=this){var i;if((t=null!==(i=Q(this,t,e,0))&&void 0!==i?i:J)===Z)return;const o=this._$AH,s=t===J&&o!==J||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,n=t!==J&&(o===J||s);s&&this.element.removeEventListener(this.name,this,o),n&&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 lt{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){Q(this,t)}}const at={L:"$lit$",P:R,V:B,I:1,N:Y,R:tt,j:T,D:Q,H:et,F:it,O:nt,W:rt,B:ot,Z:lt},ht=window.litHtmlPolyfillSupport;
|
|
71
70
|
/**
|
|
72
71
|
* @license
|
|
73
72
|
* Copyright 2017 Google LLC
|
|
74
73
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
75
74
|
*/
|
|
76
|
-
var
|
|
75
|
+
var ct,pt;null==ht||ht(G,et),(null!==(N=globalThis.litHtmlVersions)&&void 0!==N?N:globalThis.litHtmlVersions=[]).push("2.2.4");class dt extends E{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,s;const n=null!==(o=null==i?void 0:i.renderBefore)&&void 0!==o?o:e;let r=n._$litPart$;if(void 0===r){const t=null!==(s=null==i?void 0:i.renderBefore)&&void 0!==s?s:null;n._$litPart$=r=new et(e.insertBefore(U(),t),t,void 0,null!=i?i:{})}return r._$AI(t),r})(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Dt)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Dt)||void 0===t||t.setConnected(!1)}render(){return Z}}dt.finalized=!0,dt._$litElement$=!0,null===(ct=globalThis.litElementHydrateSupport)||void 0===ct||ct.call(globalThis,{LitElement:dt});const ft=globalThis.litElementPolyfillSupport;null==ft||ft({LitElement:dt}),(null!==(pt=globalThis.litElementVersions)&&void 0!==pt?pt:globalThis.litElementVersions=[]).push("3.2.0");class ut{constructor(t,e,i,o,s){this.name=t,this.category=e,this.fallbackVariable=i,this.defaultValue=o,this.context=s,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 ut(t,e,void 0,i)}static extend(t,e,i){return new ut(t,e.category,e,i)}static external(t,e){return new ut(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 vt(t,e){return b(`${t.name}: ${e}`)}const bt={colorPrimary:ut.create("--ft-color-primary","COLOR","#2196F3"),colorPrimaryVariant:ut.create("--ft-color-primary-variant","COLOR","#1976D2"),colorSecondary:ut.create("--ft-color-secondary","COLOR","#FFCC80"),colorSecondaryVariant:ut.create("--ft-color-secondary-variant","COLOR","#F57C00"),colorSurface:ut.create("--ft-color-surface","COLOR","#FFFFFF"),colorContent:ut.create("--ft-color-content","COLOR","rgba(0, 0, 0, 0.87)"),colorError:ut.create("--ft-color-error","COLOR","#B00020"),colorOutline:ut.create("--ft-color-outline","COLOR","rgba(0, 0, 0, 0.14)"),colorOpacityHigh:ut.create("--ft-color-opacity-high","NUMBER","1"),colorOpacityMedium:ut.create("--ft-color-opacity-medium","NUMBER","0.74"),colorOpacityDisabled:ut.create("--ft-color-opacity-disabled","NUMBER","0.38"),colorOnPrimary:ut.create("--ft-color-on-primary","COLOR","#FFFFFF"),colorOnPrimaryHigh:ut.create("--ft-color-on-primary-high","COLOR","#FFFFFF"),colorOnPrimaryMedium:ut.create("--ft-color-on-primary-medium","COLOR","rgba(255, 255, 255, 0.74)"),colorOnPrimaryDisabled:ut.create("--ft-color-on-primary-disabled","COLOR","rgba(255, 255, 255, 0.38)"),colorOnSecondary:ut.create("--ft-color-on-secondary","COLOR","#FFFFFF"),colorOnSecondaryHigh:ut.create("--ft-color-on-secondary-high","COLOR","#FFFFFF"),colorOnSecondaryMedium:ut.create("--ft-color-on-secondary-medium","COLOR","rgba(255, 255, 255, 0.74)"),colorOnSecondaryDisabled:ut.create("--ft-color-on-secondary-disabled","COLOR","rgba(255, 255, 255, 0.38)"),colorOnSurface:ut.create("--ft-color-on-surface","COLOR","rgba(0, 0, 0, 0.87)"),colorOnSurfaceHigh:ut.create("--ft-color-on-surface-high","COLOR","rgba(0, 0, 0, 0.87)"),colorOnSurfaceMedium:ut.create("--ft-color-on-surface-medium","COLOR","rgba(0, 0, 0, 0.60)"),colorOnSurfaceDisabled:ut.create("--ft-color-on-surface-disabled","COLOR","rgba(0, 0, 0, 0.38)"),opacityContentOnSurfaceDisabled:ut.create("--ft-opacity-content-on-surface-disabled","NUMBER","0"),opacityContentOnSurfaceEnable:ut.create("--ft-opacity-content-on-surface-enable","NUMBER","0"),opacityContentOnSurfaceHover:ut.create("--ft-opacity-content-on-surface-hover","NUMBER","0.04"),opacityContentOnSurfaceFocused:ut.create("--ft-opacity-content-on-surface-focused","NUMBER","0.12"),opacityContentOnSurfacePressed:ut.create("--ft-opacity-content-on-surface-pressed","NUMBER","0.10"),opacityContentOnSurfaceSelected:ut.create("--ft-opacity-content-on-surface-selected","NUMBER","0.08"),opacityContentOnSurfaceDragged:ut.create("--ft-opacity-content-on-surface-dragged","NUMBER","0.08"),opacityPrimaryOnSurfaceDisabled:ut.create("--ft-opacity-primary-on-surface-disabled","NUMBER","0"),opacityPrimaryOnSurfaceEnable:ut.create("--ft-opacity-primary-on-surface-enable","NUMBER","0"),opacityPrimaryOnSurfaceHover:ut.create("--ft-opacity-primary-on-surface-hover","NUMBER","0.04"),opacityPrimaryOnSurfaceFocused:ut.create("--ft-opacity-primary-on-surface-focused","NUMBER","0.12"),opacityPrimaryOnSurfacePressed:ut.create("--ft-opacity-primary-on-surface-pressed","NUMBER","0.10"),opacityPrimaryOnSurfaceSelected:ut.create("--ft-opacity-primary-on-surface-selected","NUMBER","0.08"),opacityPrimaryOnSurfaceDragged:ut.create("--ft-opacity-primary-on-surface-dragged","NUMBER","0.08"),opacitySurfaceOnPrimaryDisabled:ut.create("--ft-opacity-surface-on-primary-disabled","NUMBER","0"),opacitySurfaceOnPrimaryEnable:ut.create("--ft-opacity-surface-on-primary-enable","NUMBER","0"),opacitySurfaceOnPrimaryHover:ut.create("--ft-opacity-surface-on-primary-hover","NUMBER","0.04"),opacitySurfaceOnPrimaryFocused:ut.create("--ft-opacity-surface-on-primary-focused","NUMBER","0.12"),opacitySurfaceOnPrimaryPressed:ut.create("--ft-opacity-surface-on-primary-pressed","NUMBER","0.10"),opacitySurfaceOnPrimarySelected:ut.create("--ft-opacity-surface-on-primary-selected","NUMBER","0.08"),opacitySurfaceOnPrimaryDragged:ut.create("--ft-opacity-surface-on-primary-dragged","NUMBER","0.08"),elevation00:ut.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:ut.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:ut.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:ut.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:ut.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:ut.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:ut.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:ut.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:ut.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:ut.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:ut.create("--ft-border-radius-S","SIZE","4px"),borderRadiusM:ut.create("--ft-border-radius-M","SIZE","8px"),borderRadiusL:ut.create("--ft-border-radius-L","SIZE","12px"),borderRadiusXL:ut.create("--ft-border-radius-XL","SIZE","16px"),titleFont:ut.create("--ft-title-font","UNKNOWN","Ubuntu, system-ui, sans-serif"),contentFont:ut.create("--ft-content-font","UNKNOWN","'Open Sans', system-ui, sans-serif"),transitionDuration:ut.create("--ft-transition-duration","UNKNOWN","250ms"),transitionTimingFunction:ut.create("--ft-transition-timing-function","UNKNOWN","ease-in-out")};
|
|
77
76
|
/**
|
|
78
77
|
* @license
|
|
79
78
|
* Copyright 2021 Google LLC
|
|
80
79
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
81
|
-
*/class
|
|
82
|
-
${t.map((t=>
|
|
80
|
+
*/var xt=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};class yt 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 s=this.renderOptions.creationScope=this.attachShadow({...o,customElements:t.registry});return y(s,this.constructor.elementStyles),s}}}(dt)){getStyles(){return[]}getTemplate(){return null}render(){let t=this.getStyles();return Array.isArray(t)||(t=[t]),V`
|
|
81
|
+
${t.map((t=>V`
|
|
83
82
|
<style>${t}</style>
|
|
84
83
|
`))}
|
|
85
84
|
${this.getTemplate()}
|
|
86
|
-
`}updated(t){super.updated(t),setTimeout((()=>this.contentAvailableCallback(t)),0)}contentAvailableCallback(t){}}const
|
|
85
|
+
`}updated(t){super.updated(t),setTimeout((()=>{var e;this.contentAvailableCallback(t),(null===(e=this.exportpartsPrefix)||void 0===e?void 0:e.trim())?this.setExportpartsAttribute([this.exportpartsPrefix]):null!=this.exportpartsPrefixes&&this.exportpartsPrefixes.length>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)}),0)}setExportpartsAttribute(t){var e,i,o,s,n,r;const l=t=>null!=t&&t.trim().length>0,a=t.filter(l).map((t=>t.trim()));if(0===a.length)return void this.removeAttribute("exportparts");const h=new Set;for(let t of null!==(i=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelectorAll("[part],[exportparts]"))&&void 0!==i?i:[]){const e=null!==(s=null===(o=t.getAttribute("part"))||void 0===o?void 0:o.split(" "))&&void 0!==s?s:[],i=null!==(r=null===(n=t.getAttribute("exportparts"))||void 0===n?void 0:n.split(",").map((t=>t.split(":")[1])))&&void 0!==r?r:[];new Array(...e,...i).filter(l).map((t=>t.trim())).forEach((t=>h.add(t)))}if(0===h.size)return void this.removeAttribute("exportparts");const c=[...h.values()].flatMap((t=>a.map((e=>`${t}:${e}--${t}`))));this.setAttribute("exportparts",[...this.part,...c].join(", "))}contentAvailableCallback(t){}}xt([o()],yt.prototype,"exportpartsPrefix",void 0),xt([p([])],yt.prototype,"exportpartsPrefixes",void 0);const gt=x`
|
|
87
86
|
.ft-no-text-select {
|
|
88
87
|
-webkit-touch-callout: none;
|
|
89
88
|
-webkit-user-select: none;
|
|
@@ -92,129 +91,129 @@ var ht,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?
|
|
|
92
91
|
-ms-user-select: none;
|
|
93
92
|
user-select: none;
|
|
94
93
|
}
|
|
95
|
-
`;var
|
|
94
|
+
`;var mt,$t,wt;const kt=navigator.vendor&&!!navigator.vendor.match(/apple/i)||"[object SafariRemoteNotification]"===(null!==(wt=null===($t=null===(mt=window.safari)||void 0===mt?void 0:mt.pushNotification)||void 0===$t?void 0:$t.toString())&&void 0!==wt?wt:""),Ot=Symbol.for(""),St=t=>{var e,i;if((null===(e=t)||void 0===e?void 0:e.r)===Ot)return null===(i=t)||void 0===i?void 0:i._$litStatic$},Ct=t=>({_$litStatic$:t,r:Ot}),Et=new Map,Nt=(t=>(e,...i)=>{const o=i.length;let s,n;const r=[],l=[];let a,h=0,c=!1;for(;h<o;){for(a=e[h];h<o&&void 0!==(n=i[h],s=St(n));)a+=s+e[++h],c=!0;l.push(n),r.push(a),h++}if(h===o&&r.push(e[o]),c){const t=r.join("$$lit$$");void 0===(e=Et.get(t))&&(r.raw=r,Et.set(t,e=r)),i=l}return t(e,...i)})(V);
|
|
96
95
|
/**
|
|
97
96
|
* @license
|
|
98
97
|
* Copyright 2020 Google LLC
|
|
99
98
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
100
|
-
*/var
|
|
99
|
+
*/var zt,Mt=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>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"}(zt||(zt={}));const Rt=ut.extend("--ft-typography-font-family",bt.titleFont),Bt=ut.extend("--ft-typography-font-family",bt.contentFont),Ft={fontFamily:Bt,fontSize:ut.create("--ft-typography-font-size","SIZE","16px"),fontWeight:ut.create("--ft-typography-font-weight","UNKNOWN","normal"),letterSpacing:ut.create("--ft-typography-letter-spacing","SIZE","0.496px"),lineHeight:ut.create("--ft-typography-line-height","NUMBER","1.5"),textTransform:ut.create("--ft-typography-text-transform","UNKNOWN","inherit")},jt=ut.extend("--ft-typography-title-font-family",Rt),Ut=ut.extend("--ft-typography-title-font-size",Ft.fontSize,"20px"),Dt=ut.extend("--ft-typography-title-font-weight",Ft.fontWeight,"normal"),Lt=ut.extend("--ft-typography-title-letter-spacing",Ft.letterSpacing,"0.15px"),Tt=ut.extend("--ft-typography-title-line-height",Ft.lineHeight,"1.2"),At=ut.extend("--ft-typography-title-text-transform",Ft.textTransform,"inherit"),_t=ut.extend("--ft-typography-title-dense-font-family",Rt),Pt=ut.extend("--ft-typography-title-dense-font-size",Ft.fontSize,"14px"),It=ut.extend("--ft-typography-title-dense-font-weight",Ft.fontWeight,"normal"),Ht=ut.extend("--ft-typography-title-dense-letter-spacing",Ft.letterSpacing,"0.105px"),Wt=ut.extend("--ft-typography-title-dense-line-height",Ft.lineHeight,"1.7"),Kt=ut.extend("--ft-typography-title-dense-text-transform",Ft.textTransform,"inherit"),Vt=ut.extend("--ft-typography-subtitle1-font-family",Bt),Zt=ut.extend("--ft-typography-subtitle1-font-size",Ft.fontSize,"16px"),Jt=ut.extend("--ft-typography-subtitle1-font-weight",Ft.fontWeight,"600"),qt=ut.extend("--ft-typography-subtitle1-letter-spacing",Ft.letterSpacing,"0.144px"),Xt=ut.extend("--ft-typography-subtitle1-line-height",Ft.lineHeight,"1.5"),Yt=ut.extend("--ft-typography-subtitle1-text-transform",Ft.textTransform,"inherit"),Gt=ut.extend("--ft-typography-subtitle2-font-family",Bt),Qt=ut.extend("--ft-typography-subtitle2-font-size",Ft.fontSize,"14px"),te=ut.extend("--ft-typography-subtitle2-font-weight",Ft.fontWeight,"normal"),ee=ut.extend("--ft-typography-subtitle2-letter-spacing",Ft.letterSpacing,"0.098px"),ie=ut.extend("--ft-typography-subtitle2-line-height",Ft.lineHeight,"1.7"),oe=ut.extend("--ft-typography-subtitle2-text-transform",Ft.textTransform,"inherit"),se=ut.extend("--ft-typography-body1-font-family",Bt),ne=ut.extend("--ft-typography-body1-font-size",Ft.fontSize,"16px"),re=ut.extend("--ft-typography-body1-font-weight",Ft.fontWeight,"normal"),le=ut.extend("--ft-typography-body1-letter-spacing",Ft.letterSpacing,"0.496px"),ae=ut.extend("--ft-typography-body1-line-height",Ft.lineHeight,"1.5"),he=ut.extend("--ft-typography-body1-text-transform",Ft.textTransform,"inherit"),ce={fontFamily:ut.extend("--ft-typography-body2-font-family",Bt),fontSize:ut.extend("--ft-typography-body2-font-size",Ft.fontSize,"14px"),fontWeight:ut.extend("--ft-typography-body2-font-weight",Ft.fontWeight,"normal"),letterSpacing:ut.extend("--ft-typography-body2-letter-spacing",Ft.letterSpacing,"0.252px"),lineHeight:ut.extend("--ft-typography-body2-line-height",Ft.lineHeight,"1.4"),textTransform:ut.extend("--ft-typography-body2-text-transform",Ft.textTransform,"inherit")},pe=ut.extend("--ft-typography-caption-font-family",Bt),de=ut.extend("--ft-typography-caption-font-size",Ft.fontSize,"12px"),fe=ut.extend("--ft-typography-caption-font-weight",Ft.fontWeight,"normal"),ue=ut.extend("--ft-typography-caption-letter-spacing",Ft.letterSpacing,"0.396px"),ve=ut.extend("--ft-typography-caption-line-height",Ft.lineHeight,"1.33"),be=ut.extend("--ft-typography-caption-text-transform",Ft.textTransform,"inherit"),xe=ut.extend("--ft-typography-breadcrumb-font-family",Bt),ye=ut.extend("--ft-typography-breadcrumb-font-size",Ft.fontSize,"10px"),ge=ut.extend("--ft-typography-breadcrumb-font-weight",Ft.fontWeight,"normal"),me=ut.extend("--ft-typography-breadcrumb-letter-spacing",Ft.letterSpacing,"0.33px"),$e=ut.extend("--ft-typography-breadcrumb-line-height",Ft.lineHeight,"1.6"),we=ut.extend("--ft-typography-breadcrumb-text-transform",Ft.textTransform,"inherit"),ke=ut.extend("--ft-typography-overline-font-family",Bt),Oe=ut.extend("--ft-typography-overline-font-size",Ft.fontSize,"10px"),Se=ut.extend("--ft-typography-overline-font-weight",Ft.fontWeight,"normal"),Ce=ut.extend("--ft-typography-overline-letter-spacing",Ft.letterSpacing,"1.5px"),Ee=ut.extend("--ft-typography-overline-line-height",Ft.lineHeight,"1.6"),Ne=ut.extend("--ft-typography-overline-text-transform",Ft.textTransform,"uppercase"),ze={fontFamily:ut.extend("--ft-typography-button-font-family",Bt),fontSize:ut.extend("--ft-typography-button-font-size",Ft.fontSize,"14px"),fontWeight:ut.extend("--ft-typography-button-font-weight",Ft.fontWeight,"600"),letterSpacing:ut.extend("--ft-typography-button-letter-spacing",Ft.letterSpacing,"1.246px"),lineHeight:ut.extend("--ft-typography-button-line-height",Ft.lineHeight,"1.15"),textTransform:ut.extend("--ft-typography-button-text-transform",Ft.textTransform,"uppercase")},Me=x`
|
|
101
100
|
.ft-typography--title {
|
|
102
|
-
font-family: ${
|
|
103
|
-
font-size: ${
|
|
104
|
-
font-weight: ${
|
|
105
|
-
letter-spacing: ${
|
|
106
|
-
line-height: ${
|
|
107
|
-
text-transform: ${
|
|
101
|
+
font-family: ${jt};
|
|
102
|
+
font-size: ${Ut};
|
|
103
|
+
font-weight: ${Dt};
|
|
104
|
+
letter-spacing: ${Lt};
|
|
105
|
+
line-height: ${Tt};
|
|
106
|
+
text-transform: ${At};
|
|
108
107
|
}
|
|
109
|
-
`,
|
|
108
|
+
`,Re=x`
|
|
110
109
|
.ft-typography--title-dense {
|
|
111
|
-
font-family: ${
|
|
112
|
-
font-size: ${
|
|
113
|
-
font-weight: ${
|
|
114
|
-
letter-spacing: ${
|
|
115
|
-
line-height: ${
|
|
116
|
-
text-transform: ${
|
|
110
|
+
font-family: ${_t};
|
|
111
|
+
font-size: ${Pt};
|
|
112
|
+
font-weight: ${It};
|
|
113
|
+
letter-spacing: ${Ht};
|
|
114
|
+
line-height: ${Wt};
|
|
115
|
+
text-transform: ${Kt};
|
|
117
116
|
}
|
|
118
|
-
`,
|
|
117
|
+
`,Be=x`
|
|
119
118
|
.ft-typography--subtitle1 {
|
|
120
|
-
font-family: ${
|
|
121
|
-
font-size: ${
|
|
122
|
-
font-weight: ${
|
|
123
|
-
letter-spacing: ${
|
|
124
|
-
line-height: ${
|
|
125
|
-
text-transform: ${
|
|
119
|
+
font-family: ${Vt};
|
|
120
|
+
font-size: ${Zt};
|
|
121
|
+
font-weight: ${Jt};
|
|
122
|
+
letter-spacing: ${qt};
|
|
123
|
+
line-height: ${Xt};
|
|
124
|
+
text-transform: ${Yt};
|
|
126
125
|
}
|
|
127
|
-
`,
|
|
126
|
+
`,Fe=x`
|
|
128
127
|
.ft-typography--subtitle2 {
|
|
129
|
-
font-family: ${
|
|
130
|
-
font-size: ${
|
|
131
|
-
font-weight: ${
|
|
132
|
-
letter-spacing: ${
|
|
133
|
-
line-height: ${
|
|
134
|
-
text-transform: ${
|
|
128
|
+
font-family: ${Gt};
|
|
129
|
+
font-size: ${Qt};
|
|
130
|
+
font-weight: ${te};
|
|
131
|
+
letter-spacing: ${ee};
|
|
132
|
+
line-height: ${ie};
|
|
133
|
+
text-transform: ${oe};
|
|
135
134
|
}
|
|
136
135
|
|
|
137
|
-
`,
|
|
136
|
+
`,je=x`
|
|
138
137
|
.ft-typography--body1 {
|
|
139
|
-
font-family: ${
|
|
140
|
-
font-size: ${
|
|
141
|
-
font-weight: ${
|
|
142
|
-
letter-spacing: ${
|
|
143
|
-
line-height: ${
|
|
144
|
-
text-transform: ${
|
|
138
|
+
font-family: ${se};
|
|
139
|
+
font-size: ${ne};
|
|
140
|
+
font-weight: ${re};
|
|
141
|
+
letter-spacing: ${le};
|
|
142
|
+
line-height: ${ae};
|
|
143
|
+
text-transform: ${he};
|
|
145
144
|
}
|
|
146
|
-
`,
|
|
145
|
+
`,Ue=x`
|
|
147
146
|
.ft-typography--body2 {
|
|
148
|
-
font-family: ${
|
|
149
|
-
font-size: ${
|
|
150
|
-
font-weight: ${
|
|
151
|
-
letter-spacing: ${
|
|
152
|
-
line-height: ${
|
|
153
|
-
text-transform: ${
|
|
147
|
+
font-family: ${ce.fontFamily};
|
|
148
|
+
font-size: ${ce.fontSize};
|
|
149
|
+
font-weight: ${ce.fontWeight};
|
|
150
|
+
letter-spacing: ${ce.letterSpacing};
|
|
151
|
+
line-height: ${ce.lineHeight};
|
|
152
|
+
text-transform: ${ce.textTransform};
|
|
154
153
|
}
|
|
155
|
-
`,
|
|
154
|
+
`,De=x`
|
|
156
155
|
.ft-typography--caption {
|
|
157
|
-
font-family: ${
|
|
158
|
-
font-size: ${
|
|
159
|
-
font-weight: ${
|
|
160
|
-
letter-spacing: ${
|
|
161
|
-
line-height: ${
|
|
162
|
-
text-transform: ${
|
|
156
|
+
font-family: ${pe};
|
|
157
|
+
font-size: ${de};
|
|
158
|
+
font-weight: ${fe};
|
|
159
|
+
letter-spacing: ${ue};
|
|
160
|
+
line-height: ${ve};
|
|
161
|
+
text-transform: ${be};
|
|
163
162
|
}
|
|
164
|
-
`,
|
|
163
|
+
`,Le=x`
|
|
165
164
|
.ft-typography--breadcrumb {
|
|
166
|
-
font-family: ${
|
|
167
|
-
font-size: ${
|
|
168
|
-
font-weight: ${
|
|
169
|
-
letter-spacing: ${
|
|
170
|
-
line-height: ${
|
|
171
|
-
text-transform: ${
|
|
165
|
+
font-family: ${xe};
|
|
166
|
+
font-size: ${ye};
|
|
167
|
+
font-weight: ${ge};
|
|
168
|
+
letter-spacing: ${me};
|
|
169
|
+
line-height: ${$e};
|
|
170
|
+
text-transform: ${we};
|
|
172
171
|
}
|
|
173
|
-
`,
|
|
172
|
+
`,Te=x`
|
|
174
173
|
.ft-typography--overline {
|
|
175
|
-
font-family: ${
|
|
176
|
-
font-size: ${
|
|
177
|
-
font-weight: ${
|
|
178
|
-
letter-spacing: ${
|
|
179
|
-
line-height: ${
|
|
180
|
-
text-transform: ${
|
|
174
|
+
font-family: ${ke};
|
|
175
|
+
font-size: ${Oe};
|
|
176
|
+
font-weight: ${Se};
|
|
177
|
+
letter-spacing: ${Ce};
|
|
178
|
+
line-height: ${Ee};
|
|
179
|
+
text-transform: ${Ne};
|
|
181
180
|
}
|
|
182
|
-
`,
|
|
181
|
+
`,Ae=x`
|
|
183
182
|
.ft-typography--button {
|
|
184
|
-
font-family: ${
|
|
185
|
-
font-size: ${
|
|
186
|
-
font-weight: ${
|
|
187
|
-
letter-spacing: ${
|
|
188
|
-
line-height: ${
|
|
189
|
-
text-transform: ${
|
|
183
|
+
font-family: ${ze.fontFamily};
|
|
184
|
+
font-size: ${ze.fontSize};
|
|
185
|
+
font-weight: ${ze.fontWeight};
|
|
186
|
+
letter-spacing: ${ze.letterSpacing};
|
|
187
|
+
line-height: ${ze.lineHeight};
|
|
188
|
+
text-transform: ${ze.textTransform};
|
|
190
189
|
}
|
|
191
|
-
`;class
|
|
192
|
-
<${
|
|
190
|
+
`;class _e extends yt{constructor(){super(...arguments),this.variant=zt.body1}render(){return this.element?Nt`
|
|
191
|
+
<${Ct(this.element)}
|
|
193
192
|
class="ft-typography ft-typography--${this.variant}">
|
|
194
193
|
<slot></slot>
|
|
195
|
-
</${
|
|
196
|
-
`:
|
|
194
|
+
</${Ct(this.element)}>
|
|
195
|
+
`:Nt`
|
|
197
196
|
<slot class="ft-typography ft-typography--${this.variant}"></slot>
|
|
198
|
-
`}}function
|
|
197
|
+
`}}function Pe(t,e){return t.flatMap((t=>[t,...Pe(e(t),e)]))}
|
|
199
198
|
/**
|
|
200
199
|
* @license
|
|
201
200
|
* Copyright 2017 Google LLC
|
|
202
201
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
203
|
-
*/
|
|
202
|
+
*/_e.styles=[Me,Re,Be,Fe,je,Ue,De,Le,Te,Ae,x`
|
|
204
203
|
.ft-typography {
|
|
205
204
|
vertical-align: inherit;
|
|
206
205
|
}
|
|
207
|
-
`],
|
|
206
|
+
`],Mt([o()],_e.prototype,"element",void 0),Mt([o()],_e.prototype,"variant",void 0),c("ft-typography")(_e);const Ie=1,He=2,We=t=>(...e)=>({_$litDirective$:t,values:e});class Ke{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)}}
|
|
208
207
|
/**
|
|
209
208
|
* @license
|
|
210
209
|
* Copyright 2020 Google LLC
|
|
211
210
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
212
|
-
*/const{H:
|
|
211
|
+
*/const{H:Ve}=at,Ze=()=>document.createComment(""),Je=(t,e,i)=>{var o;const s=t._$AA.parentNode,n=void 0===e?t._$AB:e._$AA;if(void 0===i){const e=s.insertBefore(Ze(),n),o=s.insertBefore(Ze(),n);i=new Ve(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!==n||l){let t=i._$AA;for(;t!==e;){const e=t.nextSibling;s.insertBefore(t,n),t=e}}}return i},qe=(t,e,i=t)=>(t._$AI(e,i),t),Xe={},Ye=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}},Ge=(t,e,i)=>{const o=new Map;for(let s=e;s<=i;s++)o.set(t[s],s);return o},Qe=We(class extends Ke{constructor(t){if(super(t),t.type!==He)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 s=[],n=[];let r=0;for(const e of t)s[r]=o?o(e,r):r,n[r]=i(e,r),r++;return{values:n,keys:s}}render(t,e,i){return this.dt(t,e,i).values}update(t,[e,i,o]){var s;const n=(t=>t._$AH)(t),{values:r,keys:l}=this.dt(e,i,o);if(!Array.isArray(n))return this.ut=l,r;const a=null!==(s=this.ut)&&void 0!==s?s:this.ut=[],h=[];let c,p,d=0,f=n.length-1,u=0,v=r.length-1;for(;d<=f&&u<=v;)if(null===n[d])d++;else if(null===n[f])f--;else if(a[d]===l[u])h[u]=qe(n[d],r[u]),d++,u++;else if(a[f]===l[v])h[v]=qe(n[f],r[v]),f--,v--;else if(a[d]===l[v])h[v]=qe(n[d],r[v]),Je(t,h[v+1],n[d]),d++,v--;else if(a[f]===l[u])h[u]=qe(n[f],r[u]),Je(t,n[d],n[f]),f--,u++;else if(void 0===c&&(c=Ge(l,u,v),p=Ge(a,d,f)),c.has(a[d]))if(c.has(a[f])){const e=p.get(l[u]),i=void 0!==e?n[e]:null;if(null===i){const e=Je(t,n[d]);qe(e,r[u]),h[u]=e}else h[u]=qe(i,r[u]),Je(t,n[d],i),n[e]=null;u++}else Ye(n[f]),f--;else Ye(n[d]),d++;for(;u<=v;){const e=Je(t,h[v+1]);qe(e,r[u]),h[u++]=e}for(;d<=f;){const t=n[d++];null!==t&&Ye(t)}return this.ut=l,((t,e=Xe)=>{t._$AH=e})(t,h),Z}}),ti=We(class extends Ke{constructor(t){var e;if(super(t),t.type!==Ie||"class"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter((e=>t[e])).join(" ")+" "}update(t,[e]){var i,o;if(void 0===this.et){this.et=new Set,void 0!==t.strings&&(this.st=new Set(t.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in e)e[t]&&!(null===(i=this.st)||void 0===i?void 0:i.has(t))&&this.et.add(t);return this.render(e)}const s=t.element.classList;this.et.forEach((t=>{t in e||(s.remove(t),this.et.delete(t))}));for(const t in e){const i=!!e[t];i===this.et.has(t)||(null===(o=this.st)||void 0===o?void 0:o.has(t))||(i?(s.add(t),this.et.add(t)):(s.remove(t),this.et.delete(t)))}return Z}});
|
|
213
212
|
/**
|
|
214
213
|
* @license
|
|
215
214
|
* Copyright 2017 Google LLC
|
|
216
215
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
217
|
-
*/var
|
|
216
|
+
*/var ei=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const ii=ut.extend("--ft-ripple-color",bt.colorContent),oi={color:ii,backgroundColor:ut.extend("--ft-ripple-background-color",ii),opacityContentOnSurfacePressed:ut.external(bt.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:ut.external(bt.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:ut.external(bt.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:ut.external(bt.opacityContentOnSurfaceSelected,"Design system")},si=ut.extend("--ft-ripple-color",bt.colorPrimary),ni=si,ri=ut.extend("--ft-ripple-background-color",si),li=ut.extend("--ft-ripple-color",bt.colorSecondary),ai=li,hi=ut.extend("--ft-ripple-background-color",li);class ci extends yt{constructor(){super(...arguments),this.primary=!1,this.secondary=!1,this.unbounded=!1,this.activated=!1,this.selected=!1,this.disabled=!1,this.hovered=!1,this.focused=!1,this.pressed=!1,this.rippling=!1,this.rippleSize=0,this.originX=0,this.originY=0,this.resizeObserver=new ResizeObserver((()=>this.setRippleSize())),this.debouncer=new e(1e3),this.onTransitionStart=t=>{"transform"===t.propertyName&&(this.rippling=this.pressed,this.debouncer.run((()=>this.rippling=!1)))},this.onTransitionEnd=t=>{"transform"===t.propertyName&&(this.rippling=!1)},this.moveRipple=t=>{var e,i;let{x:o,y:s}=this.getCoordinates(t),n=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-n.x:n.width/2),this.originY=Math.round(null!=s?s-n.y:n.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 V`
|
|
218
217
|
<style>
|
|
219
218
|
.ft-ripple .ft-ripple--effect,
|
|
220
219
|
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
@@ -227,11 +226,11 @@ var ht,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?
|
|
|
227
226
|
top: ${this.originY}px;
|
|
228
227
|
}
|
|
229
228
|
</style>
|
|
230
|
-
<div class="${
|
|
229
|
+
<div class="${ti(t)}">
|
|
231
230
|
<div class="ft-ripple--background"></div>
|
|
232
231
|
<div class="ft-ripple--effect"></div>
|
|
233
232
|
</div>
|
|
234
|
-
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){var e,i;super.updated(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(e=this.target)||void 0===e||e.removeAttribute("data-is-ft-ripple-target")):null===(i=this.target)||void 0===i||i.setAttribute("data-is-ft-ripple-target","true")),t.has("unbounded")&&this.setRippleSize()}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}setRippleSize(){if(this.ripple){const t=this.ripple.getBoundingClientRect();this.rippleSize=(this.unbounded?1:1.7)*Math.max(t.width,t.height)}}connectedCallback(){var t;super.connectedCallback();const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(e),this.setRippleSize()}setupFor(t){if(this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const e=(...t)=>e=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(e)},i=e("mouseup","contextmenu"),o=e("touchend","touchcancel"),s=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",s),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",s),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,s;return null!=e.x?({x:o,y:s}=e):null!=i.touches&&(o=i.touches[0].clientX,s=i.touches[0].clientY),{x:o,y:s}}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()}}
|
|
233
|
+
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){var e,i;super.updated(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(e=this.target)||void 0===e||e.removeAttribute("data-is-ft-ripple-target")):null===(i=this.target)||void 0===i||i.setAttribute("data-is-ft-ripple-target","true")),t.has("unbounded")&&this.setRippleSize()}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}setRippleSize(){if(this.ripple){const t=this.ripple.getBoundingClientRect();this.rippleSize=(this.unbounded?1:1.7)*Math.max(t.width,t.height)}}connectedCallback(){var t;super.connectedCallback();const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(e),this.setRippleSize()}setupFor(t){if(this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const e=(...t)=>e=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(e)},i=e("mouseup","contextmenu"),o=e("touchend","touchcancel"),s=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",s),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",s),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,s;return null!=e.x?({x:o,y:s}=e):null!=i.touches&&(o=i.touches[0].clientX,s=i.touches[0].clientY),{x:o,y:s}}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()}}ci.elementDefinitions={},ci.styles=x`
|
|
235
234
|
:host {
|
|
236
235
|
display: contents;
|
|
237
236
|
}
|
|
@@ -253,27 +252,27 @@ var ht,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?
|
|
|
253
252
|
}
|
|
254
253
|
|
|
255
254
|
.ft-ripple .ft-ripple--background {
|
|
256
|
-
background-color: ${
|
|
255
|
+
background-color: ${oi.backgroundColor};
|
|
257
256
|
}
|
|
258
257
|
|
|
259
258
|
.ft-ripple .ft-ripple--effect {
|
|
260
|
-
background-color: ${
|
|
259
|
+
background-color: ${oi.color};
|
|
261
260
|
}
|
|
262
261
|
|
|
263
262
|
.ft-ripple.ft-ripple--secondary .ft-ripple--background {
|
|
264
|
-
background-color: ${
|
|
263
|
+
background-color: ${hi};
|
|
265
264
|
}
|
|
266
265
|
|
|
267
266
|
.ft-ripple.ft-ripple--secondary .ft-ripple--effect {
|
|
268
|
-
background-color: ${
|
|
267
|
+
background-color: ${ai};
|
|
269
268
|
}
|
|
270
269
|
|
|
271
270
|
.ft-ripple.ft-ripple--primary .ft-ripple--background {
|
|
272
|
-
background-color: ${
|
|
271
|
+
background-color: ${ri};
|
|
273
272
|
}
|
|
274
273
|
|
|
275
274
|
.ft-ripple.ft-ripple--primary .ft-ripple--effect {
|
|
276
|
-
background-color: ${
|
|
275
|
+
background-color: ${ni};
|
|
277
276
|
}
|
|
278
277
|
|
|
279
278
|
.ft-ripple .ft-ripple--background {
|
|
@@ -305,22 +304,22 @@ var ht,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?
|
|
|
305
304
|
}
|
|
306
305
|
|
|
307
306
|
.ft-ripple.ft-ripple--hovered .ft-ripple--background {
|
|
308
|
-
opacity: ${
|
|
307
|
+
opacity: ${oi.opacityContentOnSurfaceHover};
|
|
309
308
|
}
|
|
310
309
|
|
|
311
310
|
.ft-ripple.ft-ripple--selected .ft-ripple--background {
|
|
312
|
-
opacity: ${
|
|
311
|
+
opacity: ${oi.opacityContentOnSurfaceSelected};
|
|
313
312
|
}
|
|
314
313
|
|
|
315
314
|
.ft-ripple.ft-ripple--focused .ft-ripple--background {
|
|
316
|
-
opacity: ${
|
|
315
|
+
opacity: ${oi.opacityContentOnSurfaceFocused};
|
|
317
316
|
}
|
|
318
317
|
|
|
319
318
|
.ft-ripple.ft-ripple--pressed .ft-ripple--effect {
|
|
320
|
-
opacity: ${
|
|
319
|
+
opacity: ${oi.opacityContentOnSurfacePressed};
|
|
321
320
|
transform: translate(-50%, -50%) scale(1);
|
|
322
321
|
}
|
|
323
|
-
`,
|
|
322
|
+
`,ei([o({type:Boolean})],ci.prototype,"primary",void 0),ei([o({type:Boolean})],ci.prototype,"secondary",void 0),ei([o({type:Boolean})],ci.prototype,"unbounded",void 0),ei([o({type:Boolean})],ci.prototype,"activated",void 0),ei([o({type:Boolean})],ci.prototype,"selected",void 0),ei([o({type:Boolean})],ci.prototype,"disabled",void 0),ei([s()],ci.prototype,"hovered",void 0),ei([s()],ci.prototype,"focused",void 0),ei([s()],ci.prototype,"pressed",void 0),ei([s()],ci.prototype,"rippling",void 0),ei([s()],ci.prototype,"rippleSize",void 0),ei([s()],ci.prototype,"originX",void 0),ei([s()],ci.prototype,"originY",void 0),ei([r(".ft-ripple")],ci.prototype,"ripple",void 0),ei([r(".ft-ripple--effect")],ci.prototype,"rippleEffect",void 0),c("ft-ripple")(ci);var pi=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const di=ut.create("--ft-tooltip-distance","SIZE","4px"),fi=ut.create("--ft-tooltip-color","COLOR","#FFFFFF"),ui=ut.create("--ft-tooltip-background-color","COLOR","#666666"),vi=ut.create("--ft-tooltip-z-index","NUMBER","1"),bi=ut.external(bt.borderRadiusS,"Design system");class xi extends yt{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.hideDebounce=new e,this.revealDebouncer=new e}render(){return V`
|
|
324
323
|
<div part="container"
|
|
325
324
|
class="ft-tooltip--container ${this.inline?"ft-tooltip--inline":""}"
|
|
326
325
|
@mouseenter=${this.onHover}
|
|
@@ -335,7 +334,7 @@ var ht,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?
|
|
|
335
334
|
</div>
|
|
336
335
|
<slot></slot>
|
|
337
336
|
</div>
|
|
338
|
-
`}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,s=this.tooltip.style;switch(this.position){case"top":s.top=-this.tooltip.clientHeight+"px",s.left=o+"px";break;case"bottom":s.top=e.height+"px",s.left=o+"px";break;case"left":s.top=i+"px",s.left=-this.tooltip.clientWidth+"px";break;case"right":s.top=i+"px",s.left=e.width+"px"}s.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())}}
|
|
337
|
+
`}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,s=this.tooltip.style;switch(this.position){case"top":s.top=-this.tooltip.clientHeight+"px",s.left=o+"px";break;case"bottom":s.top=e.height+"px",s.left=o+"px";break;case"left":s.top=i+"px",s.left=-this.tooltip.clientWidth+"px";break;case"right":s.top=i+"px",s.left=e.width+"px"}s.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())}}xi.elementDefinitions={"ft-typography":_e},xi.styles=x`
|
|
339
338
|
.ft-tooltip--container {
|
|
340
339
|
display: block;
|
|
341
340
|
position: relative;
|
|
@@ -353,21 +352,21 @@ var ht,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?
|
|
|
353
352
|
width: max-content;
|
|
354
353
|
max-width: 150px;
|
|
355
354
|
text-align: center;
|
|
356
|
-
padding: ${
|
|
357
|
-
z-index: ${
|
|
355
|
+
padding: ${di};
|
|
356
|
+
z-index: ${vi};
|
|
358
357
|
}
|
|
359
358
|
|
|
360
359
|
.ft-tooltip--content {
|
|
361
360
|
padding: 4px 8px;
|
|
362
|
-
border-radius: ${
|
|
363
|
-
background-color: ${
|
|
364
|
-
color: ${
|
|
361
|
+
border-radius: ${bi};
|
|
362
|
+
background-color: ${ui};
|
|
363
|
+
color: ${fi};
|
|
365
364
|
top: -500px;
|
|
366
365
|
left: -500px;
|
|
367
366
|
position: relative;
|
|
368
367
|
word-break: break-word;
|
|
369
368
|
}
|
|
370
|
-
`,
|
|
369
|
+
`,pi([o()],xi.prototype,"text",void 0),pi([o({type:Boolean})],xi.prototype,"manual",void 0),pi([o({type:Boolean})],xi.prototype,"inline",void 0),pi([o({type:Number})],xi.prototype,"delay",void 0),pi([o()],xi.prototype,"position",void 0),pi([function(t,e,i){let o,s=t;return"object"==typeof t?(s=t.slot,o=t):o={flatten:e},i?h({slot:s,flatten:e,selector:i}):n({descriptor:t=>({get(){var t,e;const i="slot"+(s?`[name=${s}]`:":not([name])"),n=null===(t=this.renderRoot)||void 0===t?void 0:t.querySelector(i);return null!==(e=null==n?void 0:n.assignedNodes(o))&&void 0!==e?e:[]},enumerable:!0,configurable:!0})})}("",!0)],xi.prototype,"slotNodes",void 0),pi([r(".ft-tooltip--container")],xi.prototype,"container",void 0),pi([r("slot")],xi.prototype,"target",void 0),pi([r(".ft-tooltip")],xi.prototype,"tooltip",void 0),pi([r(".ft-tooltip--content")],xi.prototype,"tooltipContent",void 0),pi([s()],xi.prototype,"visible",void 0),c("ft-tooltip")(xi);const yi={color:ut.extend("--ft-loader-color",bt.colorPrimary),size:ut.create("--ft-loader-size","SIZE","80px")};class gi extends yt{static get styles(){return x`
|
|
371
370
|
:host {
|
|
372
371
|
line-height: 0;
|
|
373
372
|
}
|
|
@@ -376,8 +375,8 @@ var ht,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?
|
|
|
376
375
|
display: inline-block;
|
|
377
376
|
position: relative;
|
|
378
377
|
|
|
379
|
-
width: ${
|
|
380
|
-
height: ${
|
|
378
|
+
width: ${yi.size};
|
|
379
|
+
height: ${yi.size};
|
|
381
380
|
}
|
|
382
381
|
|
|
383
382
|
.ft-loader div {
|
|
@@ -386,7 +385,7 @@ var ht,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?
|
|
|
386
385
|
width: 25%;
|
|
387
386
|
height: 25%;
|
|
388
387
|
border-radius: 50%;
|
|
389
|
-
background: ${
|
|
388
|
+
background: ${yi.color};
|
|
390
389
|
animation-timing-function: cubic-bezier(0, 1, 1, 0);
|
|
391
390
|
}
|
|
392
391
|
|
|
@@ -433,37 +432,39 @@ var ht,ct;null==at||at(Y,tt),(null!==(E=globalThis.litHtmlVersions)&&void 0!==E?
|
|
|
433
432
|
transform: translate(0, 0);
|
|
434
433
|
}
|
|
435
434
|
100% {
|
|
436
|
-
transform: translate(calc(0.35 * ${
|
|
435
|
+
transform: translate(calc(0.35 * ${yi.size}), 0);
|
|
437
436
|
}
|
|
438
437
|
}
|
|
439
|
-
`}render(){return
|
|
438
|
+
`}render(){return V`
|
|
440
439
|
<div class="ft-loader">
|
|
441
440
|
<div></div>
|
|
442
441
|
<div></div>
|
|
443
442
|
<div></div>
|
|
444
443
|
<div></div>
|
|
445
444
|
</div>
|
|
446
|
-
`}}c("ft-loader")(
|
|
445
|
+
`}}c("ft-loader")(gi);
|
|
447
446
|
/**
|
|
448
447
|
* @license
|
|
449
448
|
* Copyright 2017 Google LLC
|
|
450
449
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
451
450
|
*/
|
|
452
|
-
class
|
|
451
|
+
class mi extends Ke{constructor(t){if(super(t),this.it=J,t.type!==He)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===J||null==t)return this.ft=void 0,this.it=t;if(t===Z)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this.ft;this.it=t;const e=[t];return e.raw=e,this.ft={_$litType$:this.constructor.resultType,strings:e,values:[]}}}mi.directiveName="unsafeHTML",mi.resultType=1;const $i=We(mi);var wi,ki;!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=""}(wi||(wi={})),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=""}(ki||(ki={})),new Map([...["abw"].map((t=>[t,ki.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,ki.AUDIO])),...["avi"].map((t=>[t,ki.AVI])),...["chm","xhs"].map((t=>[t,ki.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,ki.CODE])),...["csv"].map((t=>[t,ki.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,ki.DITA])),...["epub"].map((t=>[t,ki.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,ki.EXCEL])),...["flac"].map((t=>[t,ki.FLAC])),...["gif"].map((t=>[t,ki.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,ki.GZIP])),...["html","htm","xhtml"].map((t=>[t,ki.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,ki.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,ki.JPEG])),...["json"].map((t=>[t,ki.JSON])),...["m4a","m4p"].map((t=>[t,ki.M4A])),...["mov","qt"].map((t=>[t,ki.MOV])),...["mp3"].map((t=>[t,ki.MP3])),...["mp4","m4v"].map((t=>[t,ki.MP4])),...["ogg","oga"].map((t=>[t,ki.OGG])),...["pdf","ps"].map((t=>[t,ki.PDF])),...["png"].map((t=>[t,ki.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,ki.POWERPOINT])),...["rar"].map((t=>[t,ki.RAR])),...["stp"].map((t=>[t,ki.STP])),...["txt","rtf","md","mdown"].map((t=>[t,ki.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,ki.VIDEO])),...["wav"].map((t=>[t,ki.WAV])),...["wma"].map((t=>[t,ki.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,ki.WORD])),...["xml","xsl","rdf"].map((t=>[t,ki.XML])),...["yaml","yml","x-yaml"].map((t=>[t,ki.YAML])),...["zip"].map((t=>[t,ki.ZIP]))]);var Oi,Si=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};!function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(Oi||(Oi={}));const Ci={size:ut.create("--ft-icon-font-size","SIZE","24px"),fluidTopicsFontFamily:ut.extend("--ft-icon-fluid-topics-font-family",ut.create("--ft-icon-font-family","UNKNOWN","ft-icons")),fileFormatFontFamily:ut.extend("--ft-icon-file-format-font-family",ut.create("--ft-icon-font-family","UNKNOWN","ft-mime")),materialFontFamily:ut.extend("--ft-icon-material-font-family",ut.create("--ft-icon-font-family","UNKNOWN","Material Icons"))};class Ei extends yt{constructor(){super(...arguments),this.variant=Oi.fluid_topics}render(){return V`
|
|
453
452
|
<i class="ft-icon ${"ft-icon--"+this.variant}">
|
|
454
|
-
${
|
|
453
|
+
${$i(this.getIcon())}
|
|
455
454
|
<slot @slotchange=${()=>this.requestUpdate()} ?hidden=${"material"!==this.variant}></slot>
|
|
456
455
|
</i>
|
|
457
|
-
`}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===
|
|
458
|
-
:host
|
|
456
|
+
`}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===Oi.file_format?null!==(t=ki[i.toUpperCase()])&&void 0!==t?t:i:this.variant===Oi.fluid_topics?null!==(e=wi[i.toUpperCase()])&&void 0!==e?e:i:J}}Ei.elementDefinitions={},Ei.styles=x`
|
|
457
|
+
:host {
|
|
459
458
|
display: inline-block;
|
|
460
|
-
|
|
461
|
-
|
|
459
|
+
}
|
|
460
|
+
:host, i.ft-icon {
|
|
461
|
+
width: ${Ci.size};
|
|
462
|
+
height: ${Ci.size};
|
|
462
463
|
text-align: center;
|
|
463
464
|
}
|
|
464
465
|
|
|
465
466
|
i.ft-icon {
|
|
466
|
-
font-size: ${
|
|
467
|
+
font-size: ${Ci.size};
|
|
467
468
|
line-height: 1;
|
|
468
469
|
font-weight: normal;
|
|
469
470
|
text-transform: none;
|
|
@@ -477,17 +478,17 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
477
478
|
}
|
|
478
479
|
|
|
479
480
|
.ft-icon--fluid-topics {
|
|
480
|
-
font-family: ${
|
|
481
|
+
font-family: ${Ci.fluidTopicsFontFamily}, ft-icons, fticons, sans-serif;
|
|
481
482
|
}
|
|
482
483
|
|
|
483
484
|
.ft-icon--file-format {
|
|
484
|
-
font-family: ${
|
|
485
|
+
font-family: ${Ci.fileFormatFontFamily}, ft-mime, sans-serif;
|
|
485
486
|
}
|
|
486
487
|
|
|
487
488
|
.ft-icon--material {
|
|
488
|
-
font-family: ${
|
|
489
|
+
font-family: ${Ci.materialFontFamily}, "Material Icons", sans-serif;
|
|
489
490
|
}
|
|
490
|
-
`,
|
|
491
|
+
`,Si([o()],Ei.prototype,"variant",void 0),Si([r("slot")],Ei.prototype,"slottedContent",void 0),c("ft-icon")(Ei);var Ni=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const zi=ut.extend("--ft-button-color",bt.colorPrimary),Mi={backgroundColor:ut.extend("--ft-button-background-color",bt.colorSurface),borderRadius:ut.extend("--ft-button-border-radius",bt.borderRadiusL),color:zi,fontSize:ut.extend("--ft-button-font-size",ze.fontSize),iconSize:ut.create("--ft-button-icon-size","SIZE","24px"),rippleColor:ut.extend("--ft-button-ripple-color",zi),opacityDisabled:ut.external(bt.colorOpacityDisabled,"Design system")},Ri=ut.extend("--ft-button-primary-color",ut.extend("--ft-button-color",bt.colorOnPrimary)),Bi={backgroundColor:ut.extend("--ft-button-primary-background-color",ut.extend("--ft-button-background-color",bt.colorPrimary)),color:Ri,rippleColor:ut.extend("--ft-button-primary-ripple-color",Ri)},Fi=ut.extend("--ft-button-dense-border-radius",ut.extend("--ft-button-border-radius",bt.borderRadiusM));class ji extends yt{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[gt,x`
|
|
491
492
|
:host {
|
|
492
493
|
display: inline-block;
|
|
493
494
|
max-width: 100%;
|
|
@@ -498,7 +499,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
498
499
|
box-shadow: 0px 0px 0px transparent;
|
|
499
500
|
border: 0px solid transparent;
|
|
500
501
|
text-shadow: 0px 0px 0px transparent;
|
|
501
|
-
font-size:
|
|
502
|
+
font-size: 16px;
|
|
502
503
|
}
|
|
503
504
|
|
|
504
505
|
button:hover {
|
|
@@ -527,18 +528,18 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
527
528
|
border: none;
|
|
528
529
|
pointer-events: auto;
|
|
529
530
|
|
|
530
|
-
--ft-button-internal-font-size: ${
|
|
531
|
+
--ft-button-internal-font-size: ${Mi.fontSize};
|
|
531
532
|
--ft-button-internal-line-height: calc(var(--ft-button-internal-font-size) + 2px);
|
|
532
|
-
--ft-button-internal-color: ${
|
|
533
|
-
${
|
|
533
|
+
--ft-button-internal-color: ${Mi.color};
|
|
534
|
+
${vt(Ci.size,Mi.iconSize)};
|
|
534
535
|
--ft-button-internal-vertical-padding: 6px;
|
|
535
536
|
--ft-button-internal-horizontal-padding: 8px;
|
|
536
|
-
${
|
|
537
|
-
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height), ${
|
|
537
|
+
${vt(oi.color,Mi.rippleColor)};
|
|
538
|
+
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height), ${Mi.iconSize});
|
|
538
539
|
|
|
539
|
-
border-radius: ${
|
|
540
|
+
border-radius: ${Mi.borderRadius};
|
|
540
541
|
padding: var(--ft-button-internal-vertical-padding) var(--ft-button-internal-horizontal-padding);
|
|
541
|
-
background-color: ${
|
|
542
|
+
background-color: ${Mi.backgroundColor};
|
|
542
543
|
color: var(--ft-button-internal-color);
|
|
543
544
|
-webkit-mask-image: radial-gradient(white, black);
|
|
544
545
|
}
|
|
@@ -550,7 +551,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
550
551
|
.ft-button--dense {
|
|
551
552
|
--ft-button-internal-vertical-padding: 2px;
|
|
552
553
|
--ft-button-internal-horizontal-padding: 4px;
|
|
553
|
-
border-radius: ${
|
|
554
|
+
border-radius: ${Fi};
|
|
554
555
|
}
|
|
555
556
|
|
|
556
557
|
.ft-button--round {
|
|
@@ -559,13 +560,13 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
559
560
|
|
|
560
561
|
.ft-button[disabled] {
|
|
561
562
|
filter: grayscale(1);
|
|
562
|
-
opacity: ${
|
|
563
|
+
opacity: ${Mi.opacityDisabled};
|
|
563
564
|
}
|
|
564
565
|
|
|
565
566
|
.ft-button.ft-button--primary {
|
|
566
|
-
background-color: ${
|
|
567
|
-
--ft-button-internal-color: ${
|
|
568
|
-
${
|
|
567
|
+
background-color: ${Bi.backgroundColor};
|
|
568
|
+
--ft-button-internal-color: ${Bi.color};
|
|
569
|
+
${vt(oi.color,Bi.rippleColor)};
|
|
569
570
|
}
|
|
570
571
|
|
|
571
572
|
.ft-button.ft-button--outlined {
|
|
@@ -584,8 +585,8 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
584
585
|
text-overflow: ellipsis;
|
|
585
586
|
display: block;
|
|
586
587
|
margin: 0 var(--ft-button-internal-horizontal-padding);
|
|
587
|
-
${
|
|
588
|
-
${
|
|
588
|
+
${vt(ze.fontSize,"var(--ft-button-internal-font-size)")};
|
|
589
|
+
${vt(ze.lineHeight,"var(--ft-button-internal-content-height)")};
|
|
589
590
|
}
|
|
590
591
|
|
|
591
592
|
.ft-button--safari-fix .ft-button--label {
|
|
@@ -618,12 +619,12 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
618
619
|
}
|
|
619
620
|
|
|
620
621
|
ft-loader {
|
|
621
|
-
${
|
|
622
|
-
${
|
|
622
|
+
${vt(yi.size,Mi.iconSize)};
|
|
623
|
+
${vt(yi.color,"var(--ft-button-internal-color)")};
|
|
623
624
|
}
|
|
624
|
-
`]}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"
|
|
625
|
+
`]}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":kt,"ft-no-text-select":!0};return this.addTooltip(V`
|
|
625
626
|
<button part="button"
|
|
626
|
-
class="${
|
|
627
|
+
class="${ti(t)}"
|
|
627
628
|
aria-label="${this.getLabel()}"
|
|
628
629
|
?disabled=${this.isDisabled()}>
|
|
629
630
|
<ft-ripple part="ripple" ?disabled=${this.isDisabled()}></ft-ripple>
|
|
@@ -635,16 +636,16 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
635
636
|
</ft-typography>
|
|
636
637
|
${this.resolveIcon()}
|
|
637
638
|
</button>
|
|
638
|
-
`)}addTooltip(t){return this.hasTextContent()||0===this.getLabel().trim().length?t:
|
|
639
|
+
`)}addTooltip(t){return this.hasTextContent()||0===this.getLabel().trim().length?t:V`
|
|
639
640
|
<ft-tooltip part="tooltip"
|
|
640
641
|
text="${this.getLabel()}"
|
|
641
642
|
position="${this.tooltipPosition}">
|
|
642
643
|
${t}
|
|
643
644
|
</ft-tooltip>
|
|
644
|
-
`}resolveIcon(){return this.loading?
|
|
645
|
-
<ft-loader></ft-loader> `:this.icon?
|
|
646
|
-
<ft-icon variant="material">${this.icon}</ft-icon> `:
|
|
647
|
-
<label class="${
|
|
645
|
+
`}resolveIcon(){return this.loading?V`
|
|
646
|
+
<ft-loader></ft-loader> `:this.icon?V`
|
|
647
|
+
<ft-icon variant="material">${this.icon}</ft-icon> `:J}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}}ji.elementDefinitions={"ft-ripple":ci,"ft-tooltip":xi,"ft-typography":_e,"ft-icon":Ei,"ft-loader":gi},Ni([o({type:Boolean})],ji.prototype,"primary",void 0),Ni([o({type:Boolean})],ji.prototype,"outlined",void 0),Ni([o({type:Boolean})],ji.prototype,"disabled",void 0),Ni([o({type:Boolean})],ji.prototype,"dense",void 0),Ni([o({type:Boolean})],ji.prototype,"round",void 0),Ni([o({type:String})],ji.prototype,"label",void 0),Ni([o({type:String})],ji.prototype,"icon",void 0),Ni([o({type:Boolean})],ji.prototype,"trailingIcon",void 0),Ni([o({type:Boolean})],ji.prototype,"loading",void 0),Ni([o({type:String})],ji.prototype,"tooltipPosition",void 0),Ni([r(".ft-button")],ji.prototype,"button",void 0),Ni([r(".ft-button--label slot")],ji.prototype,"slottedContent",void 0),c("ft-button")(ji);var Ui=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const Di=ut.extend("--ft-checkbox-text-color",bt.colorOnSurfaceHigh),Li=ut.external(bt.colorPrimary,"Design system"),Ti=ut.external(bt.colorOnPrimary,"Design system"),Ai=ut.extend("--ft-checkbox-border-color",bt.colorOnSurfaceMedium),_i=ut.external(bt.colorOnSurfaceDisabled,"Design system");class Pi extends yt{constructor(){super(...arguments),this.name="",this.checked=!1,this.indeterminate=!1,this.disabled=!1}render(){const t={"ft-checkbox":!0,"ft-checkbox--checked":this.checked,"ft-checkbox--indeterminate":this.indeterminate,"ft-checkbox--disabled":this.disabled};return V`
|
|
648
|
+
<label class="${ti(t)}">
|
|
648
649
|
<div class="ft-checkbox--box-container">
|
|
649
650
|
<input type="checkbox"
|
|
650
651
|
name=${this.name}
|
|
@@ -668,14 +669,14 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
668
669
|
<slot></slot>
|
|
669
670
|
</ft-typography>
|
|
670
671
|
</label>
|
|
671
|
-
`}onChange(t){t.stopPropagation(),this.checked=t.target.checked,this.indeterminate=!1,this.dispatchEvent(new CustomEvent("change",{detail:this.checked}))}contentAvailableCallback(t){var e;super.contentAvailableCallback(t),null===(e=this.ripple)||void 0===e||e.setupFor(this.container)}}
|
|
672
|
+
`}onChange(t){t.stopPropagation(),this.checked=t.target.checked,this.indeterminate=!1,this.dispatchEvent(new CustomEvent("change",{detail:this.checked}))}contentAvailableCallback(t){var e;super.contentAvailableCallback(t),null===(e=this.ripple)||void 0===e||e.setupFor(this.container)}}Pi.elementDefinitions={"ft-ripple":ci,"ft-typography":_e},Pi.styles=x`
|
|
672
673
|
* {
|
|
673
674
|
box-sizing: border-box;
|
|
674
675
|
}
|
|
675
676
|
|
|
676
677
|
.ft-checkbox {
|
|
677
678
|
box-sizing: border-box;
|
|
678
|
-
color: ${
|
|
679
|
+
color: ${Di};
|
|
679
680
|
|
|
680
681
|
display: inline-flex;
|
|
681
682
|
align-items: center;
|
|
@@ -683,7 +684,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
683
684
|
}
|
|
684
685
|
|
|
685
686
|
.ft-checkbox--disabled {
|
|
686
|
-
color: ${
|
|
687
|
+
color: ${_i};
|
|
687
688
|
}
|
|
688
689
|
|
|
689
690
|
input {
|
|
@@ -707,26 +708,26 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
707
708
|
|
|
708
709
|
.ft-checkbox--box {
|
|
709
710
|
display: flex;
|
|
710
|
-
border: 2px solid ${
|
|
711
|
+
border: 2px solid ${Ai};
|
|
711
712
|
border-radius: 2px;
|
|
712
713
|
|
|
713
714
|
width: 18px;
|
|
714
715
|
height: 18px;
|
|
715
716
|
|
|
716
|
-
color: ${
|
|
717
|
+
color: ${Ti};
|
|
717
718
|
}
|
|
718
719
|
|
|
719
720
|
|
|
720
721
|
.ft-checkbox--checked .ft-checkbox--box,
|
|
721
722
|
.ft-checkbox--indeterminate .ft-checkbox--box {
|
|
722
|
-
border-color: ${
|
|
723
|
-
background-color: ${
|
|
723
|
+
border-color: ${Li};
|
|
724
|
+
background-color: ${Li};
|
|
724
725
|
}
|
|
725
726
|
|
|
726
727
|
.ft-checkbox--disabled .ft-checkbox--box {
|
|
727
|
-
border-color: ${
|
|
728
|
+
border-color: ${_i};
|
|
728
729
|
background-color: transparent;
|
|
729
|
-
color: ${
|
|
730
|
+
color: ${_i};
|
|
730
731
|
}
|
|
731
732
|
|
|
732
733
|
.ft-checkbox--checkmark {
|
|
@@ -745,8 +746,8 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
745
746
|
.ft-checkbox--indeterminate .ft-checkbox--checkmark {
|
|
746
747
|
opacity: 1;
|
|
747
748
|
}
|
|
748
|
-
`,
|
|
749
|
-
<div class="${
|
|
749
|
+
`,Ui([o()],Pi.prototype,"name",void 0),Ui([o({type:Boolean})],Pi.prototype,"checked",void 0),Ui([o({type:Boolean})],Pi.prototype,"indeterminate",void 0),Ui([o({type:Boolean})],Pi.prototype,"disabled",void 0),Ui([r(".ft-checkbox")],Pi.prototype,"container",void 0),Ui([r("ft-ripple")],Pi.prototype,"ripple",void 0),c("ft-checkbox")(Pi);var Ii=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const Hi=ut.extend("--ft-radio-text-color",bt.colorOnSurfaceHigh),Wi=ut.external(bt.colorPrimary,"Design system"),Ki=(ut.external(bt.colorOnPrimary,"Design system"),ut.extend("--ft-radio-border-color",bt.colorOnSurfaceMedium)),Vi=ut.external(bt.colorOnSurfaceDisabled,"Design system");class Zi extends CustomEvent{constructor(t,e){super("change",{detail:{value:t,checked:e},bubbles:!0,composed:!0})}}class Ji extends yt{constructor(){super(...arguments),this.value="",this.name="",this.checked=!1,this.disabled=!1}render(){const t={"ft-radio":!0,"ft-radio--checked":this.checked,"ft-radio--disabled":this.disabled};return V`
|
|
750
|
+
<div class="${ti(t)}">
|
|
750
751
|
<div class="ft-radio--box-container">
|
|
751
752
|
<input id="radio-button"
|
|
752
753
|
type="radio"
|
|
@@ -770,14 +771,14 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
770
771
|
</ft-typography>
|
|
771
772
|
</label>
|
|
772
773
|
</div>
|
|
773
|
-
`}onChange(t){t.stopPropagation(),this.checked=t.target.checked,this.dispatchEvent(new
|
|
774
|
+
`}onChange(t){t.stopPropagation(),this.checked=t.target.checked,this.dispatchEvent(new Zi(this.value,this.checked))}contentAvailableCallback(t){var e;super.contentAvailableCallback(t),null===(e=this.ripple)||void 0===e||e.setupFor(this.container)}select(){this.checked=!0,this.dispatchEvent(new Zi(this.value,this.checked)),this.focus()}focus(){var t;null===(t=this.input)||void 0===t||t.focus()}}Ji.elementDefinitions={"ft-ripple":ci,"ft-typography":_e},Ji.styles=x`
|
|
774
775
|
* {
|
|
775
776
|
box-sizing: border-box;
|
|
776
777
|
}
|
|
777
778
|
|
|
778
779
|
.ft-radio {
|
|
779
780
|
box-sizing: border-box;
|
|
780
|
-
color: ${
|
|
781
|
+
color: ${Hi};
|
|
781
782
|
|
|
782
783
|
display: inline-flex;
|
|
783
784
|
align-items: center;
|
|
@@ -785,7 +786,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
785
786
|
}
|
|
786
787
|
|
|
787
788
|
.ft-radio--disabled {
|
|
788
|
-
color: ${
|
|
789
|
+
color: ${Vi};
|
|
789
790
|
}
|
|
790
791
|
|
|
791
792
|
input {
|
|
@@ -808,7 +809,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
808
809
|
}
|
|
809
810
|
|
|
810
811
|
.ft-radio--box {
|
|
811
|
-
border: 2px solid ${
|
|
812
|
+
border: 2px solid ${Ki};
|
|
812
813
|
border-radius: 50%;
|
|
813
814
|
|
|
814
815
|
display: flex;
|
|
@@ -821,7 +822,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
821
822
|
|
|
822
823
|
.ft-radio--box:after {
|
|
823
824
|
content: " ";
|
|
824
|
-
background-color: ${
|
|
825
|
+
background-color: ${Wi};
|
|
825
826
|
|
|
826
827
|
border-radius: 50%;
|
|
827
828
|
|
|
@@ -833,7 +834,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
833
834
|
}
|
|
834
835
|
|
|
835
836
|
.ft-radio--checked .ft-radio--box {
|
|
836
|
-
border-color: ${
|
|
837
|
+
border-color: ${Wi};
|
|
837
838
|
}
|
|
838
839
|
|
|
839
840
|
|
|
@@ -842,27 +843,28 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
842
843
|
}
|
|
843
844
|
|
|
844
845
|
.ft-radio--disabled .ft-radio--box {
|
|
845
|
-
border-color: ${
|
|
846
|
+
border-color: ${Vi};
|
|
846
847
|
background-color: transparent;
|
|
847
848
|
}
|
|
848
849
|
|
|
849
850
|
.ft-radio--disabled .ft-radio--box:after {
|
|
850
|
-
background-color: ${
|
|
851
|
+
background-color: ${Vi};
|
|
851
852
|
}
|
|
852
|
-
`,
|
|
853
|
+
`,Ii([o()],Ji.prototype,"value",void 0),Ii([o()],Ji.prototype,"name",void 0),Ii([o({type:Boolean})],Ji.prototype,"checked",void 0),Ii([o({type:Boolean})],Ji.prototype,"disabled",void 0),Ii([r(".ft-radio")],Ji.prototype,"container",void 0),Ii([r("ft-ripple")],Ji.prototype,"ripple",void 0),Ii([r("input")],Ji.prototype,"input",void 0);var qi=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};class Xi extends yt{constructor(){super(...arguments),this.name=""}render(){return V`
|
|
853
854
|
<slot @slotchange=${this.onSlotChange}
|
|
854
855
|
@change=${this.onChange}
|
|
855
856
|
@keydown=${this.onKeyDown}
|
|
856
857
|
@focusin=${this.onFocusIn}
|
|
857
858
|
></slot>
|
|
858
|
-
`}onSlotChange(){this.radioButtons.forEach((t=>t.name=this.name))}onChange(t){t.stopPropagation(),this.radioButtons.forEach((e=>e.checked=t.detail.value===e.value)),this.dispatchEvent(new CustomEvent("change",{detail:t.detail.value}))}onKeyDown(t){switch(t.key){case"ArrowUp":case"ArrowLeft":{let e=this.findFtRadio(t),i=this.radioButtons.indexOf(e)-1;this.radioButtons[i<0?this.radioButtons.length-1:i].select();break}case"ArrowDown":case"ArrowRight":{let e=this.radioButtons.indexOf(this.findFtRadio(t))+1;this.radioButtons[e>this.radioButtons.length-1?0:e].select();break}}}findFtRadio(t){return t.composedPath().find((t=>"FT-RADIO"===t.tagName))}onFocusIn(){setTimeout((()=>{var t;return null===(t=this.radioButtons.find((t=>t.checked)))||void 0===t?void 0:t.focus()}),10)}}
|
|
859
|
+
`}onSlotChange(){this.radioButtons.forEach((t=>t.name=this.name))}onChange(t){t.stopPropagation(),this.radioButtons.forEach((e=>e.checked=t.detail.value===e.value)),this.dispatchEvent(new CustomEvent("change",{detail:t.detail.value}))}onKeyDown(t){switch(t.key){case"ArrowUp":case"ArrowLeft":{let e=this.findFtRadio(t),i=this.radioButtons.indexOf(e)-1;this.radioButtons[i<0?this.radioButtons.length-1:i].select();break}case"ArrowDown":case"ArrowRight":{let e=this.radioButtons.indexOf(this.findFtRadio(t))+1;this.radioButtons[e>this.radioButtons.length-1?0:e].select();break}}}findFtRadio(t){return t.composedPath().find((t=>"FT-RADIO"===t.tagName))}onFocusIn(){setTimeout((()=>{var t;return null===(t=this.radioButtons.find((t=>t.checked)))||void 0===t?void 0:t.focus()}),10)}}Xi.elementDefinitions={},Xi.styles=x`
|
|
859
860
|
:host {
|
|
860
861
|
display: contents;
|
|
861
862
|
}
|
|
862
|
-
`,
|
|
863
|
+
`,qi([o()],Xi.prototype,"name",void 0),qi([h()],Xi.prototype,"radioButtons",void 0),c("ft-radio")(Ji),c("ft-radio-group")(Xi);var Yi=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const Gi={borderRadiusM:ut.external(bt.borderRadiusM,"Design system"),colorOutline:ut.external(bt.colorOutline,"Design system"),colorOnSurface:ut.external(bt.colorOnSurface,"Design system"),colorOnSurfaceMedium:ut.external(bt.colorOnSurfaceMedium,"Design system"),colorOnSurfaceDisabled:ut.external(bt.colorOnSurfaceDisabled,"Design system"),colorPrimary:ut.external(bt.colorPrimary,"Design system"),colorOnPrimary:ut.external(bt.colorOnPrimary,"Design system"),fontFamily:ut.external(ce.fontFamily,"Body2 typography"),fontSize:ut.external(ce.fontSize,"Body2 typography"),fontWeight:ut.external(ce.fontWeight,"Body2 typography"),letterSpacing:ut.external(ce.letterSpacing,"Body2 typography"),lineHeight:ut.external(ce.lineHeight,"Body2 typography"),textTransform:ut.external(ce.textTransform,"Body2 typography")};class Qi extends yt{constructor(){super(...arguments),this.id="",this.options=[],this.multivalued=!1,this.disabled=!1,this.hideSelectedOptions=!1,this.preventNavigation=!1,this.filter="",this.moreValuesButtonLabel="More",this.displayedValuesLimit=0,this.displayedPages=1}get hasHiddenValues(){let t=this.limit;return null!=t&&t<this.options.length}get limit(){return this.displayedValuesLimit>0?this.displayedPages*this.displayedValuesLimit:void 0}get height(){var t,e;return null!==(e=null===(t=this.container)||void 0===t?void 0:t.scrollHeight)&&void 0!==e?e:0}render(){let t=this.options;this.hideSelectedOptions&&(t=t.filter((t=>!t.selected))),this.filter&&(t=t.filter((t=>t.label.toLowerCase().includes(this.filter.toLowerCase()))));const e=t.slice(0,this.limit);return V`
|
|
863
864
|
<div class="ft-filter-level--container ${this.disabled?"ft-filter--disabled":""}">
|
|
864
|
-
${null==this.parent?null:
|
|
865
|
+
${null==this.parent?null:V`
|
|
865
866
|
<div tabindex="0"
|
|
867
|
+
part="controls go-back"
|
|
866
868
|
class="ft-filter-level--go-back"
|
|
867
869
|
?disabled=${this.disabled}
|
|
868
870
|
@keyup=${this.goBackOnKeyPress}
|
|
@@ -872,11 +874,17 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
872
874
|
<ft-typography variant="body2">${this.parent.label}</ft-typography>
|
|
873
875
|
</div>
|
|
874
876
|
`}
|
|
875
|
-
${
|
|
877
|
+
${0===this.options.length&&this.noValuesLabel?V`
|
|
878
|
+
<ft-typography class="ft-filter-level--no-values" element="span" variant="body2">
|
|
879
|
+
${this.noValuesLabel}
|
|
880
|
+
</ft-typography>
|
|
881
|
+
`:J}
|
|
882
|
+
${Qe(e,(t=>t.value),(t=>{var e;return V`
|
|
876
883
|
<div class="ft-filter-level--option" part="options">
|
|
877
884
|
${this.multivalued?this.buildMultiValuedOption(t):this.buildMonoValuedOption(t)}
|
|
878
|
-
${this.preventNavigation||t.selected||0===(null!==(e=t.subOptions)&&void 0!==e?e:[]).length?
|
|
885
|
+
${this.preventNavigation||t.selected||0===(null!==(e=t.subOptions)&&void 0!==e?e:[]).length?J:V`
|
|
879
886
|
<ft-button icon="chevron_right"
|
|
887
|
+
part="controls navigate-hierarchy"
|
|
880
888
|
label="${t.label}"
|
|
881
889
|
?disabled=${this.disabled}
|
|
882
890
|
tooltipPosition="left"
|
|
@@ -884,26 +892,29 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
884
892
|
`}
|
|
885
893
|
</div>
|
|
886
894
|
`}))}
|
|
887
|
-
${e.length<t.length?
|
|
895
|
+
${e.length<t.length?V`
|
|
888
896
|
<ft-button
|
|
889
897
|
class="ft-filter-level--display-more"
|
|
890
898
|
icon="expand_more"
|
|
891
899
|
dense trailingIcon
|
|
900
|
+
part="controls display-more"
|
|
892
901
|
@click=${this.displayMore}>
|
|
893
902
|
${this.moreValuesButtonLabel}
|
|
894
903
|
</ft-button>
|
|
895
|
-
`:
|
|
904
|
+
`:J}
|
|
896
905
|
</div>
|
|
897
|
-
`}goBackOnKeyPress(t){"Enter"!==t.key&&" "!==t.key||this.dispatchEvent(new CustomEvent("go-back",{detail:this.parent}))}goBackOnClick(t){t.stopPropagation(),t.preventDefault(),this.dispatchEvent(new CustomEvent("go-back",{detail:this.parent}))}displayMore(){this.displayedPages++}buildMultiValuedOption(t){var e;return
|
|
906
|
+
`}goBackOnKeyPress(t){"Enter"!==t.key&&" "!==t.key||this.dispatchEvent(new CustomEvent("go-back",{detail:this.parent}))}goBackOnClick(t){t.stopPropagation(),t.preventDefault(),this.dispatchEvent(new CustomEvent("go-back",{detail:this.parent}))}displayMore(){this.displayedPages++}buildMultiValuedOption(t){var e;return V`
|
|
898
907
|
<ft-checkbox name="${this.id}"
|
|
908
|
+
part="multivalued-option"
|
|
899
909
|
.checked=${t.selected}
|
|
900
910
|
.disabled=${this.disabled}
|
|
901
|
-
.indeterminate=${
|
|
911
|
+
.indeterminate=${Pe(null!==(e=t.subOptions)&&void 0!==e?e:[],(t=>{var e;return null!==(e=t.subOptions)&&void 0!==e?e:[]})).some((t=>t.selected))}
|
|
902
912
|
@change=${e=>this.optionsChanged(e,t)}>
|
|
903
913
|
${t.label}
|
|
904
914
|
</ft-checkbox>
|
|
905
|
-
`}buildMonoValuedOption(t){return
|
|
915
|
+
`}buildMonoValuedOption(t){return V`
|
|
906
916
|
<ft-radio name="${this.id+Math.round(1e6*Math.random())}"
|
|
917
|
+
part="monovalued-option"
|
|
907
918
|
.checked=${t.selected}
|
|
908
919
|
?disabled=${this.disabled}
|
|
909
920
|
@click=${e=>this.optionsChanged(e,t)}
|
|
@@ -912,7 +923,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
912
923
|
|
|
913
924
|
${t.label}
|
|
914
925
|
</ft-radio>
|
|
915
|
-
`}onRadioKeyUp(t,e){e.selected&&" "===t.key&&this.optionsChanged(t,e)}optionsChanged(t,e){t.stopPropagation(),this.dispatchEvent(new CustomEvent("change",{detail:e}))}displayLevel(t){this.dispatchEvent(new CustomEvent("display-level",{detail:t}))}}
|
|
926
|
+
`}onRadioKeyUp(t,e){e.selected&&" "===t.key&&this.optionsChanged(t,e)}optionsChanged(t,e){t.stopPropagation(),this.dispatchEvent(new CustomEvent("change",{detail:e}))}displayLevel(t){this.dispatchEvent(new CustomEvent("display-level",{detail:t}))}}Qi.elementDefinitions={"ft-button":ji,"ft-ripple":ci,"ft-typography":_e,"ft-checkbox":Pi,"ft-icon":Ei,"ft-radio":Ji},Qi.styles=[x`
|
|
916
927
|
.ft-filter-level--container {
|
|
917
928
|
display: flex;
|
|
918
929
|
flex-direction: column;
|
|
@@ -926,14 +937,14 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
926
937
|
flex-shrink: 0;
|
|
927
938
|
text-decoration: none;
|
|
928
939
|
position: relative;
|
|
929
|
-
border-radius: ${
|
|
940
|
+
border-radius: ${Gi.borderRadiusM};
|
|
930
941
|
overflow: hidden;
|
|
931
942
|
display: flex;
|
|
932
943
|
align-items: center;
|
|
933
944
|
padding: 4px 4px;
|
|
934
945
|
gap: 4px;
|
|
935
946
|
cursor: pointer;
|
|
936
|
-
color: ${
|
|
947
|
+
color: ${Gi.colorOnSurface};
|
|
937
948
|
}
|
|
938
949
|
|
|
939
950
|
.ft-filter-level--go-back:focus {
|
|
@@ -962,7 +973,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
962
973
|
}
|
|
963
974
|
|
|
964
975
|
ft-button {
|
|
965
|
-
${
|
|
976
|
+
${vt(Mi.color,Gi.colorOnSurface)};
|
|
966
977
|
}
|
|
967
978
|
|
|
968
979
|
ft-radio, ft-checkbox {
|
|
@@ -973,7 +984,12 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
973
984
|
margin-left: -10px;
|
|
974
985
|
word-break: break-word;
|
|
975
986
|
}
|
|
976
|
-
|
|
987
|
+
|
|
988
|
+
.ft-filter-level--no-values {
|
|
989
|
+
margin: 10px 0;
|
|
990
|
+
color: ${Gi.colorOnSurfaceMedium};
|
|
991
|
+
}
|
|
992
|
+
`],Yi([o({type:String})],Qi.prototype,"id",void 0),Yi([o({type:Object})],Qi.prototype,"parent",void 0),Yi([o({type:Array})],Qi.prototype,"options",void 0),Yi([o({type:Boolean})],Qi.prototype,"multivalued",void 0),Yi([o({type:Boolean})],Qi.prototype,"disabled",void 0),Yi([o({type:Boolean})],Qi.prototype,"hideSelectedOptions",void 0),Yi([o({type:Boolean})],Qi.prototype,"preventNavigation",void 0),Yi([o({type:String})],Qi.prototype,"filter",void 0),Yi([o({type:String})],Qi.prototype,"moreValuesButtonLabel",void 0),Yi([o({type:String})],Qi.prototype,"noValuesLabel",void 0),Yi([o({type:Number})],Qi.prototype,"displayedValuesLimit",void 0),Yi([r(".ft-filter-level--container")],Qi.prototype,"container",void 0),Yi([s()],Qi.prototype,"displayedPages",void 0);var to=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const eo={buttonsColor:ut.extend("--ft-snap-scroll-buttons-color",bt.colorPrimary),buttonsZIndex:ut.create("--ft-snap-scroll-buttons-z-index","COLOR","1"),gap:ut.create("--ft-snap-scroll-gap","SIZE","0"),colorSurface:ut.external(bt.colorSurface,"Design system")};class io extends CustomEvent{constructor(t,e){super("current-element-change",{detail:{index:t,element:e}})}}class oo extends yt{constructor(){super(...arguments),this.horizontal=!1,this.hideScrollbar=!1,this.controls=!1,this.limitSize=!1,this.elements=[],this.currentElement=0,this.withScroll=!1,this.startReached=!0,this.endReached=!0,this.offsetAttribute="offsetTop",this.scrollAttribute="scrollTop",this.sizeAttribute="clientHeight",this.scrollSizeAttribute="scrollHeight",this.updateScrollCallback=()=>this.onScroll(),this.resizeObserver=new ResizeObserver((()=>this.scheduleUpdateScroll())),this.scrollDebouncer=new e(200),this.updateScrollDebouncer=new e(100)}scrollToIndex(t){this.scrollToElement(this.elements[t])}scrollIndexIntoView(t){let e=this.elements[t];if(e){const t=this.contentSlot[this.scrollAttribute]+this.contentSlot[this.sizeAttribute]-this.nextSize,i=this.contentSlot[this.scrollAttribute]+this.prevSize;(e[this.offsetAttribute]<i||e[this.offsetAttribute]+e[this.sizeAttribute]>t)&&this.scrollToElement(e)}}previous(){this.scrollToElement(this.elements[Math.max(0,this.closestIndexFromStart()-1)])}next(){this.scrollToElement(this.elements[Math.min(this.closestIndexFromStart()+1,this.elements.length-1)])}render(){const t=ti({"ft-snap-scroll":!0,"ft-snap-scroll--horizontal":this.horizontal,"ft-snap-scroll--vertical":!this.horizontal,"ft-snap-scroll--hide-scrollbar":this.hideScrollbar,"ft-snap-scroll--limit-size":this.limitSize,"ft-snap-scroll--safari-fix":kt}),e=this.controls&&this.withScroll;return V`
|
|
977
993
|
<div part="container" class="${t}">
|
|
978
994
|
<ft-button
|
|
979
995
|
class="ft-snap-scroll--previous"
|
|
@@ -997,7 +1013,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
997
1013
|
@click=${this.next}
|
|
998
1014
|
></ft-button>
|
|
999
1015
|
</div>
|
|
1000
|
-
`}updated(t){var e;super.updated(t),this.contentSlot&&(this.resizeObserver.observe(this.contentSlot),this.listenedContainer!==this.contentSlot&&(this.listenedContainer&&this.listenedContainer.removeEventListener("scroll",this.updateScrollCallback),this.listenedContainer=this.contentSlot,null===(e=this.listenedContainer)||void 0===e||e.addEventListener("scroll",this.updateScrollCallback))),t.has("horizontal")&&(this.horizontal?(this.offsetAttribute="offsetLeft",this.scrollAttribute="scrollLeft",this.sizeAttribute="clientWidth",this.scrollSizeAttribute="scrollWidth"):(this.offsetAttribute="offsetTop",this.scrollAttribute="scrollTop",this.sizeAttribute="clientHeight",this.scrollSizeAttribute="scrollHeight")),t.has("currentElement")&&this.dispatchEvent(new
|
|
1016
|
+
`}updated(t){var e;super.updated(t),this.contentSlot&&(this.resizeObserver.observe(this.contentSlot),this.listenedContainer!==this.contentSlot&&(this.listenedContainer&&this.listenedContainer.removeEventListener("scroll",this.updateScrollCallback),this.listenedContainer=this.contentSlot,null===(e=this.listenedContainer)||void 0===e||e.addEventListener("scroll",this.updateScrollCallback))),t.has("horizontal")&&(this.horizontal?(this.offsetAttribute="offsetLeft",this.scrollAttribute="scrollLeft",this.sizeAttribute="clientWidth",this.scrollSizeAttribute="scrollWidth"):(this.offsetAttribute="offsetTop",this.scrollAttribute="scrollTop",this.sizeAttribute="clientHeight",this.scrollSizeAttribute="scrollHeight")),t.has("currentElement")&&this.dispatchEvent(new io(this.currentElement,this.elements[this.currentElement]))}onScroll(){this.scrollDebouncer.run((()=>this.snap())),this.scheduleUpdateScroll()}snap(){let t=this.closestElementFromStart();if(null!=t){const e=this.getDistanceFromStart(t);Math.abs(this.contentSlot[this.scrollAttribute]+this.contentSlot[this.sizeAttribute]-this.contentSlot[this.scrollSizeAttribute])<e&&(t=this.lastElement),this.scrollToElement(t)}}scrollToElement(t){var e,i;t&&(this.horizontal?null===(e=this.contentSlot)||void 0===e||e.scrollTo({left:this.getOffset(t)-this.controlsSize,behavior:"smooth"}):null===(i=this.contentSlot)||void 0===i||i.scrollTo({top:this.getOffset(t)-this.controlsSize,behavior:"smooth"}),this.currentElement=this.elements.indexOf(t))}onSlotChange(){var t,e;this.elements=null!==(e=null===(t=this.contentSlot)||void 0===t?void 0:t.assignedElements().map((t=>t)))&&void 0!==e?e:[],this.scheduleUpdateScroll()}closestElementFromStart(){return this.elements[this.closestIndexFromStart()]}closestIndexFromStart(){let t=-1;for(let e=0;e<this.elements.length;e++)(t<0||this.getDistanceFromStart(this.elements[e])<this.getDistanceFromStart(this.elements[t]))&&(t=e);return t}scheduleUpdateScroll(){this.updateScrollDebouncer.run((()=>this.updateScroll()))}updateScroll(){null!=this.contentSlot?(this.withScroll=this.contentSlot[this.scrollSizeAttribute]>this.contentSlot[this.sizeAttribute],this.startReached=0===this.contentSlot[this.scrollAttribute],this.endReached=this.contentSlot[this.scrollAttribute]+this.contentSlot[this.sizeAttribute]+1>=this.contentSlot[this.scrollSizeAttribute]):(this.withScroll=!1,this.startReached=!0,this.endReached=!0)}get lastElement(){return this.elements[this.elements.length-1]}get firstElementOffset(){let t=this.elements[0];return t?t[this.offsetAttribute]:0}get controlsSize(){return this.controls?36:0}get nextSize(){return this.endReached?0:this.controlsSize}get prevSize(){return this.startReached?0:this.controlsSize}getOffset(t){return t[this.offsetAttribute]-this.firstElementOffset}getDistanceFromStart(t){const e=t===this.elements[0]?0:this.controlsSize;return Math.abs(this.getOffset(t)-this.contentSlot[this.scrollAttribute]-e)}}oo.elementDefinitions={"ft-button":ji},oo.styles=x`
|
|
1001
1017
|
.ft-snap-scroll {
|
|
1002
1018
|
box-sizing: border-box;
|
|
1003
1019
|
position: relative;
|
|
@@ -1032,7 +1048,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1032
1048
|
flex-wrap: nowrap;
|
|
1033
1049
|
align-items: flex-start;
|
|
1034
1050
|
justify-content: flex-start;
|
|
1035
|
-
gap: ${
|
|
1051
|
+
gap: ${eo.gap};
|
|
1036
1052
|
}
|
|
1037
1053
|
|
|
1038
1054
|
.ft-snap-scroll--hide-scrollbar .ft-snap-scroll--content::-webkit-scrollbar {
|
|
@@ -1075,11 +1091,11 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1075
1091
|
.ft-snap-scroll--next {
|
|
1076
1092
|
position: absolute;
|
|
1077
1093
|
display: flex;
|
|
1078
|
-
z-index: ${
|
|
1094
|
+
z-index: ${eo.buttonsZIndex};
|
|
1079
1095
|
opacity: 1;
|
|
1080
1096
|
transition: background-color .5s ease-in-out, opacity .5s ease-in-out, z-index .5s ease-in-out;
|
|
1081
|
-
${
|
|
1082
|
-
${
|
|
1097
|
+
${vt(Mi.backgroundColor,"transparent")};
|
|
1098
|
+
${vt(Mi.color,eo.buttonsColor)};
|
|
1083
1099
|
}
|
|
1084
1100
|
|
|
1085
1101
|
.ft-snap-scroll--previous[hidden],
|
|
@@ -1092,44 +1108,44 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1092
1108
|
top: 0;
|
|
1093
1109
|
left: -1px;
|
|
1094
1110
|
bottom: 0;
|
|
1095
|
-
background: linear-gradient(to right, ${
|
|
1111
|
+
background: linear-gradient(to right, ${eo.colorSurface} 50%, var(--ft-snap-scroll-transparent-color));
|
|
1096
1112
|
}
|
|
1097
1113
|
|
|
1098
1114
|
.ft-snap-scroll--vertical .ft-snap-scroll--previous {
|
|
1099
1115
|
top: -1px;
|
|
1100
1116
|
left: 0;
|
|
1101
1117
|
right: 0;
|
|
1102
|
-
background: linear-gradient(to bottom, ${
|
|
1118
|
+
background: linear-gradient(to bottom, ${eo.colorSurface} 50%, var(--ft-snap-scroll-transparent-color));
|
|
1103
1119
|
}
|
|
1104
1120
|
|
|
1105
1121
|
.ft-snap-scroll--horizontal .ft-snap-scroll--next {
|
|
1106
1122
|
top: 0;
|
|
1107
1123
|
right: -1px;
|
|
1108
1124
|
bottom: 0;
|
|
1109
|
-
background: linear-gradient(to left, ${
|
|
1125
|
+
background: linear-gradient(to left, ${eo.colorSurface} 50%, var(--ft-snap-scroll-transparent-color));
|
|
1110
1126
|
}
|
|
1111
1127
|
|
|
1112
1128
|
.ft-snap-scroll--vertical .ft-snap-scroll--next {
|
|
1113
1129
|
left: 0;
|
|
1114
1130
|
right: 0;
|
|
1115
1131
|
bottom: -1px;
|
|
1116
|
-
background: linear-gradient(to top, ${
|
|
1132
|
+
background: linear-gradient(to top, ${eo.colorSurface} 50%, var(--ft-snap-scroll-transparent-color));
|
|
1117
1133
|
}
|
|
1118
1134
|
|
|
1119
1135
|
.ft-snap-scroll--horizontal .ft-snap-scroll--previous:hover,
|
|
1120
1136
|
.ft-snap-scroll--horizontal .ft-snap-scroll--next:hover,
|
|
1121
1137
|
.ft-snap-scroll--vertical .ft-snap-scroll--previous:hover,
|
|
1122
1138
|
.ft-snap-scroll--vertical .ft-snap-scroll--next:hover {
|
|
1123
|
-
background-color: ${
|
|
1139
|
+
background-color: ${eo.colorSurface};
|
|
1124
1140
|
}
|
|
1125
|
-
`,
|
|
1141
|
+
`,to([o({type:Boolean})],oo.prototype,"horizontal",void 0),to([o({type:Boolean})],oo.prototype,"hideScrollbar",void 0),to([o({type:Boolean})],oo.prototype,"controls",void 0),to([o({type:Boolean})],oo.prototype,"limitSize",void 0),to([s()],oo.prototype,"elements",void 0),to([s()],oo.prototype,"currentElement",void 0),to([s()],oo.prototype,"withScroll",void 0),to([s()],oo.prototype,"startReached",void 0),to([s()],oo.prototype,"endReached",void 0),to([r(".ft-snap-scroll--content")],oo.prototype,"contentSlot",void 0),c("ft-snap-scroll")(oo);var so=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const no={colorOutline:ut.external(bt.colorOutline,"Design system"),colorOnSurface:ut.external(bt.colorOnSurface,"Design system"),colorOnSurfaceMedium:ut.external(bt.colorOnSurfaceMedium,"Design system"),colorPrimary:ut.external(bt.colorPrimary,"Design system"),colorSurface:ut.external(bt.colorSurface,"Design system"),transitionDuration:ut.external(bt.transitionDuration,"Design system"),transitionTimingFunction:ut.external(bt.transitionTimingFunction,"Design system")};class ro extends CustomEvent{constructor(t){super("change",{detail:t})}}class lo extends yt{constructor(){super(...arguments),this.id="",this.label="",this.filterPlaceHolder="Filter {0}",this.clearButtonLabel="Clear",this.moreValuesButtonLabel="More",this.noValuesLabel="No values available",this.options=[],this.multivalued=!1,this.disabled=!1,this.raiseSelectedOptions=!1,this.displayedValuesLimit=0,this.withScroll=!1,this.filter="",this.displayedLevels=[],this.scrollResizeObserver=new ResizeObserver((()=>this.updateScroll())),this.levelsScrollDebouncer=new e(300),this.changeDebouncer=new e(10)}get flatOptions(){return Pe(this.options,(t=>{var e;return null!==(e=t.subOptions)&&void 0!==e?e:[]}))}render(){var t,e;const i=this.flatOptions.some((t=>t.selected));let o=this.withScroll||this.filter||null!==(e=null===(t=this.lastLevel)||void 0===t?void 0:t.hasHiddenValues)&&void 0!==e&&e;return V`
|
|
1126
1142
|
<div class="ft-filter--container ${this.disabled?"ft-filter--disabled":""}"
|
|
1127
1143
|
part="container">
|
|
1128
|
-
${this.label||i?
|
|
1144
|
+
${this.label||i?V`
|
|
1129
1145
|
<div class="ft-filter--header" part="header">
|
|
1130
1146
|
<ft-typography class="ft-filter--label" variant="overline" part="label">${this.label}
|
|
1131
1147
|
</ft-typography>
|
|
1132
|
-
${i?
|
|
1148
|
+
${i?V`
|
|
1133
1149
|
<ft-button icon="close" dense @click=${this.clear} part="clear-button">
|
|
1134
1150
|
${this.clearButtonLabel}
|
|
1135
1151
|
</ft-button>
|
|
@@ -1152,8 +1168,8 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1152
1168
|
@slotchange=${this.updateOptionsFromSlot}
|
|
1153
1169
|
@option-change=${this.optionsChanged}></slot>
|
|
1154
1170
|
</div>
|
|
1155
|
-
`}update(t){if(super.update(t),t.has("options")){const t=new Set(this.flatOptions.map((t=>t.value)));this.displayedLevels=this.displayedLevels.filter((e=>t.has(e)))}}contentAvailableCallback(t){var e,i;super.contentAvailableCallback(t),this.valuesContainer&&this.scrollResizeObserver.observe(this.valuesContainer),this.container&&this.scrollResizeObserver.observe(this.container),t.has("options")&&(this.updateScroll(),null===(e=this.levelsContainer)||void 0===e||e.scrollToIndex(this.displayedLevels.length)),t.has("slideIn")&&this.slideIn&&setTimeout((()=>{var t;null===(t=this.levelsContainer)||void 0===t||t.next(),this.slideIn=void 0}),0),t.has("slideOut")&&this.slideOut&&(null===(i=this.levelsContainer)||void 0===i||i.previous(),setTimeout((()=>{this.displayedLevels.pop(),this.slideOut=void 0}),300))}renderLevels(){const t=this.flatOptions,e=t.filter((t=>t.selected)),i=this.slideIn||this.slideOut?this.displayedLevels.length-2:this.displayedLevels.length-1,o=i<0?"ft-filter--level-center":"ft-filter--level-left";return
|
|
1156
|
-
${this.raiseSelectedOptions&&e.length>0?
|
|
1171
|
+
`}update(t){if(super.update(t),t.has("options")){const t=new Set(this.flatOptions.map((t=>t.value)));this.displayedLevels=this.displayedLevels.filter((e=>t.has(e)))}}contentAvailableCallback(t){var e,i;super.contentAvailableCallback(t),this.valuesContainer&&this.scrollResizeObserver.observe(this.valuesContainer),this.container&&this.scrollResizeObserver.observe(this.container),t.has("options")&&(this.updateScroll(),null===(e=this.levelsContainer)||void 0===e||e.scrollToIndex(this.displayedLevels.length)),t.has("slideIn")&&this.slideIn&&setTimeout((()=>{var t;null===(t=this.levelsContainer)||void 0===t||t.next(),this.slideIn=void 0}),0),t.has("slideOut")&&this.slideOut&&(null===(i=this.levelsContainer)||void 0===i||i.previous(),setTimeout((()=>{this.displayedLevels.pop(),this.slideOut=void 0}),300))}renderLevels(){const t=this.flatOptions,e=t.filter((t=>t.selected)),i=this.slideIn||this.slideOut?this.displayedLevels.length-2:this.displayedLevels.length-1,o=i<0?"ft-filter--level-center":"ft-filter--level-left";return V`
|
|
1172
|
+
${this.raiseSelectedOptions&&e.length>0?V`
|
|
1157
1173
|
<ft-filter-level
|
|
1158
1174
|
id="${this.id}"
|
|
1159
1175
|
?multivalued=${this.multivalued}
|
|
@@ -1161,7 +1177,8 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1161
1177
|
preventNavigation
|
|
1162
1178
|
.options=${e}
|
|
1163
1179
|
@change=${this.onChange}
|
|
1164
|
-
part="selected-values"
|
|
1180
|
+
part="values selected-values"
|
|
1181
|
+
.exportpartsPrefixes=${["values","selected-values"]}
|
|
1165
1182
|
></ft-filter-level>
|
|
1166
1183
|
<div class="ft-filter--separator">
|
|
1167
1184
|
`:null}
|
|
@@ -1171,7 +1188,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1171
1188
|
${this.renderLevel(o,this.options)}
|
|
1172
1189
|
${this.displayedLevels.map((e=>t.find((t=>t.value===e)))).map(((t,e)=>{var o;const s=(null==t?void 0:t.value)===this.slideIn||(null==t?void 0:t.value)===this.slideOut?"ft-filter--level-right":e===i?"ft-filter--level-center":"ft-filter--level-left";return this.renderLevel(s,null!==(o=null==t?void 0:t.subOptions)&&void 0!==o?o:[],t)}))}
|
|
1173
1190
|
</ft-snap-scroll>
|
|
1174
|
-
`}renderLevel(t,e,i){return
|
|
1191
|
+
`}renderLevel(t,e,i){return V`
|
|
1175
1192
|
<ft-filter-level
|
|
1176
1193
|
class="${t}"
|
|
1177
1194
|
id="${this.id}"
|
|
@@ -1186,9 +1203,11 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1186
1203
|
@change=${this.onChange}
|
|
1187
1204
|
@go-back=${this.goBack}
|
|
1188
1205
|
@display-level=${this.onDisplayLevel}
|
|
1189
|
-
part="values"
|
|
1206
|
+
part="values available-values"
|
|
1207
|
+
.exportpartsPrefixes=${["values","available-values"]}
|
|
1208
|
+
noValuesLabel="${this.noValuesLabel}"
|
|
1190
1209
|
></ft-filter-level>
|
|
1191
|
-
`}goBack(t){this.slideOut=t.detail.value}onDisplayLevel(t){this.displayedLevels.push(t.detail.value),this.slideIn=t.detail.value}clear(){if(this.flatOptions.forEach((t=>t.selected=!1)),this.displayedLevels.length>0){let t=this.displayedLevels[this.displayedLevels.length-1];this.displayedLevels=[t],this.slideOut=t}this.optionsChanged()}onChange(t){var e;t.stopPropagation();const i=this.flatOptions.find((e=>e.value===t.detail.value));i.selected=!i.selected;const o=t=>{var e;t!==i&&(t.selected=!1),null===(e=t.subOptions)||void 0===e||e.forEach(o)};this.multivalued?null===(e=i.subOptions)||void 0===e||e.forEach(o):this.options.forEach(o),this.optionsChanged()}optionsChanged(){this.changeDebouncer.run((()=>{var t;const e=this.flatOptions.filter((t=>t.selected)).map((t=>t.value));this.dispatchEvent(new
|
|
1210
|
+
`}goBack(t){this.slideOut=t.detail.value}onDisplayLevel(t){this.displayedLevels.push(t.detail.value),this.slideIn=t.detail.value}clear(){if(this.flatOptions.forEach((t=>t.selected=!1)),this.displayedLevels.length>0){let t=this.displayedLevels[this.displayedLevels.length-1];this.displayedLevels=[t],this.slideOut=t}this.optionsChanged()}onChange(t){var e;t.stopPropagation();const i=this.flatOptions.find((e=>e.value===t.detail.value));i.selected=!i.selected;const o=t=>{var e;t!==i&&(t.selected=!1),null===(e=t.subOptions)||void 0===e||e.forEach(o)};this.multivalued?null===(e=i.subOptions)||void 0===e||e.forEach(o):this.options.forEach(o),this.optionsChanged()}optionsChanged(){this.changeDebouncer.run((()=>{var t;const e=this.flatOptions.filter((t=>t.selected)).map((t=>t.value));this.dispatchEvent(new ro(e)),this.requestUpdate(),null===(t=this.levels)||void 0===t||t.forEach((t=>t.requestUpdate()))}))}updateOptionsFromSlot(t){t.stopPropagation(),this.options=this.slotElement.assignedElements().map((t=>t)),this.optionsChanged()}onFilterChange(){var t,e;this.filter=null!==(e=null===(t=this.filterInput)||void 0===t?void 0:t.value)&&void 0!==e?e:""}updateScroll(){this.valuesContainer&&(this.withScroll=this.valuesContainer.scrollHeight>this.valuesContainer.clientHeight)}}lo.elementDefinitions={"ft-button":ji,"ft-filter-level":Qi,"ft-snap-scroll":oo,"ft-typography":_e},lo.styles=[De,x`
|
|
1192
1211
|
:host {
|
|
1193
1212
|
display: flex;
|
|
1194
1213
|
max-height: 100%;
|
|
@@ -1201,8 +1220,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1201
1220
|
flex-direction: column;
|
|
1202
1221
|
max-height: 100%;
|
|
1203
1222
|
max-width: 100%;
|
|
1204
|
-
color: ${
|
|
1205
|
-
background: ${oo.colorSurface};
|
|
1223
|
+
color: ${no.colorOnSurface};
|
|
1206
1224
|
}
|
|
1207
1225
|
|
|
1208
1226
|
.ft-filter--header {
|
|
@@ -1212,13 +1230,13 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1212
1230
|
flex-shrink: 0;
|
|
1213
1231
|
padding: 0 10px;
|
|
1214
1232
|
margin-bottom: 8px;
|
|
1215
|
-
${
|
|
1233
|
+
${vt(Ft.fontSize,"14px")};
|
|
1216
1234
|
}
|
|
1217
1235
|
|
|
1218
1236
|
.ft-filter--header ft-button {
|
|
1219
1237
|
flex-shrink: 0;
|
|
1220
1238
|
margin-left: auto;
|
|
1221
|
-
${
|
|
1239
|
+
${vt(Mi.iconSize,"18px")};
|
|
1222
1240
|
}
|
|
1223
1241
|
|
|
1224
1242
|
.ft-filter--label {
|
|
@@ -1226,8 +1244,8 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1226
1244
|
flex-shrink: 1;
|
|
1227
1245
|
flex-grow: 1;
|
|
1228
1246
|
word-break: break-word;
|
|
1229
|
-
${
|
|
1230
|
-
${
|
|
1247
|
+
${vt(Ft.lineHeight,"22px")};
|
|
1248
|
+
${vt(Ft.fontWeight,"bold")};
|
|
1231
1249
|
}
|
|
1232
1250
|
|
|
1233
1251
|
.ft-filter--filter {
|
|
@@ -1238,8 +1256,8 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1238
1256
|
padding: 0 10px;
|
|
1239
1257
|
overflow: hidden;
|
|
1240
1258
|
height: 32px;
|
|
1241
|
-
transition: height ${
|
|
1242
|
-
margin ${
|
|
1259
|
+
transition: height ${no.transitionDuration} ${no.transitionTimingFunction},
|
|
1260
|
+
margin ${no.transitionDuration} ${no.transitionTimingFunction};
|
|
1243
1261
|
transition-delay: 500ms;
|
|
1244
1262
|
}
|
|
1245
1263
|
|
|
@@ -1252,11 +1270,15 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1252
1270
|
display: block;
|
|
1253
1271
|
width: 100%;
|
|
1254
1272
|
border-radius: 4px;
|
|
1255
|
-
border: 1px solid ${
|
|
1273
|
+
border: 1px solid ${no.colorOutline};
|
|
1256
1274
|
padding: 4px;
|
|
1257
|
-
background-color: ${
|
|
1258
|
-
color: ${
|
|
1259
|
-
outline-color: ${
|
|
1275
|
+
background-color: ${no.colorSurface};
|
|
1276
|
+
color: ${no.colorOnSurface};
|
|
1277
|
+
outline-color: ${no.colorPrimary};
|
|
1278
|
+
}
|
|
1279
|
+
|
|
1280
|
+
input::placeholder {
|
|
1281
|
+
color: ${no.colorOnSurfaceMedium};
|
|
1260
1282
|
}
|
|
1261
1283
|
|
|
1262
1284
|
.ft-filter--values {
|
|
@@ -1268,7 +1290,7 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1268
1290
|
}
|
|
1269
1291
|
|
|
1270
1292
|
.ft-filter--separator {
|
|
1271
|
-
border-top: 1px solid ${
|
|
1293
|
+
border-top: 1px solid ${no.colorOutline};
|
|
1272
1294
|
margin: 4px 10px;
|
|
1273
1295
|
}
|
|
1274
1296
|
|
|
@@ -1293,6 +1315,6 @@ class yi extends He{constructor(t){if(super(t),this.it=Z,t.type!==Pe)throw Error
|
|
|
1293
1315
|
slot {
|
|
1294
1316
|
display: none;
|
|
1295
1317
|
}
|
|
1296
|
-
`],
|
|
1318
|
+
`],so([o({type:String})],lo.prototype,"id",void 0),so([o({type:String})],lo.prototype,"label",void 0),so([o({type:String})],lo.prototype,"filterPlaceHolder",void 0),so([o({type:String})],lo.prototype,"clearButtonLabel",void 0),so([o({type:String})],lo.prototype,"moreValuesButtonLabel",void 0),so([o({type:String})],lo.prototype,"noValuesLabel",void 0),so([p([])],lo.prototype,"options",void 0),so([o({type:Boolean})],lo.prototype,"multivalued",void 0),so([o({type:Boolean})],lo.prototype,"disabled",void 0),so([o({type:Boolean})],lo.prototype,"raiseSelectedOptions",void 0),so([o({type:Number})],lo.prototype,"displayedValuesLimit",void 0),so([r(".ft-filter--slot")],lo.prototype,"slotElement",void 0),so([r(".ft-filter--container")],lo.prototype,"container",void 0),so([r(".ft-filter--values")],lo.prototype,"valuesContainer",void 0),so([r(".ft-filter--levels")],lo.prototype,"levelsContainer",void 0),so([r(".ft-filter--levels ft-filter-level:last-child")],lo.prototype,"lastLevel",void 0),so([r(".ft-filter--filter input")],lo.prototype,"filterInput",void 0),so([function(t){return n({descriptor:e=>({get(){var e,i;return null!==(i=null===(e=this.renderRoot)||void 0===e?void 0:e.querySelectorAll(t))&&void 0!==i?i:[]},enumerable:!0,configurable:!0})})}(".ft-filter--levels ft-filter-level")],lo.prototype,"levels",void 0),so([s()],lo.prototype,"withScroll",void 0),so([s()],lo.prototype,"filter",void 0),so([s()],lo.prototype,"slideIn",void 0),so([s()],lo.prototype,"slideOut",void 0);var ao=function(t,e,i,o){for(var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,l=t.length-1;l>=0;l--)(s=t[l])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};class ho extends yt{constructor(){super(...arguments),this.label="",this.value=null,this.selected=!1,this.subOptions=[]}render(){return V`
|
|
1297
1319
|
<slot class="ft-filter-option--slot" @slotchange=${this.updateSubOptionsFromSlot}></slot>
|
|
1298
|
-
`}updateSubOptionsFromSlot(t){t.stopPropagation(),this.subOptions=this.slotElement.assignedElements().map((t=>t))}updated(t){super.updated(t),this.dispatchEvent(new CustomEvent("option-change",{detail:this,bubbles:!0}))}}
|
|
1320
|
+
`}updateSubOptionsFromSlot(t){t.stopPropagation(),this.subOptions=this.slotElement.assignedElements().map((t=>t))}updated(t){super.updated(t),this.dispatchEvent(new CustomEvent("option-change",{detail:this,bubbles:!0}))}}ho.elementDefinitions={},ao([o({type:String})],ho.prototype,"label",void 0),ao([o({type:Object,converter:t=>t})],ho.prototype,"value",void 0),ao([o({type:Boolean,reflect:!0})],ho.prototype,"selected",void 0),ao([o({type:Object})],ho.prototype,"subOptions",void 0),ao([r(".ft-filter-option--slot")],ho.prototype,"slotElement",void 0),c("ft-filter")(lo),c("ft-filter-option")(ho),t.FtFilter=lo,t.FtFilterChangeEvent=ro,t.FtFilterCssVariables=no,t.FtFilterOption=ho,Object.defineProperty(t,"t",{value:!0})}({});
|