@fluid-topics/ft-search-bar 0.1.18 → 0.2.0
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-search-bar.inline-styles.js +648 -825
- package/build/ft-search-bar.js +1 -3
- package/build/ft-search-bar.light.js +574 -730
- package/build/ft-search-bar.min.js +643 -820
- package/package.json +13 -14
|
@@ -14,91 +14,75 @@
|
|
|
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,
|
|
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 c={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,c),this._definitionsByClass.set(s,c);let h=i.call(o,t);h||(h=p(t),e.call(o,t,h)),this===window.customElements&&(r.set(s,c),c.standInClass=h);const f=this._awaitingUpgrade.get(t);if(f){this._awaitingUpgrade.delete(t);for(const t of f)n.delete(t),u(t,c,!0)}const b=this._whenDefinedPromises.get(t);return void 0!==b&&(b.resolve(s),this._whenDefinedPromises.delete(t)),s}upgrade(){v.push(this),o.upgrade.apply(o,arguments),v.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 c=t=>t===document||t instanceof ShadowRoot,h=t=>{let e=t.getRootNode();if(!c(e)){const t=v[v.length-1];if(t instanceof CustomElementRegistry)return t;e=t.getRootNode(),c(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=h(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)},b=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const e=b.apply(this,arguments);return t.customElements&&(e.customElements=t.customElements),e};let v=[document];const g=(t,e,i)=>{const o=(i?Object.getPrototypeOf(i):t.prototype)[e];t.prototype[e]=function(){v.push(this);const t=o.apply(i||this,arguments);return void 0!==t&&l.set(t,this),v.pop(),t}};g(ShadowRoot,"createElement",document),g(ShadowRoot,"importNode",document),g(Element,"insertAdjacentHTML");const x=(t,e)=>{const i=Object.getOwnPropertyDescriptor(t.prototype,e);Object.defineProperty(t.prototype,e,{...i,set(t){v.push(this),i.set.call(this,t),v.pop()}})};if(x(Element,"innerHTML"),x(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(li){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 t{constructor(t=0){this.timeout=t,this.callbacks=[]}run(t,e){this.callbacks=[t],this.debounce(e)}queue(t,e){this.callbacks.push(t),this.debounce(e)}cancel(){null!=this._debounce&&window.clearTimeout(this._debounce)}debounce(t){this.cancel(),this._debounce=window.setTimeout((()=>this.runCallbacks()),null!=t?t:this.timeout)}runCallbacks(){for(let t of this.callbacks)t();this.callbacks=[]}}
|
|
18
18
|
/**
|
|
19
19
|
* @license
|
|
20
20
|
* Copyright 2017 Google LLC
|
|
21
21
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
22
|
-
*/const e=t
|
|
22
|
+
*/const e=(t,e)=>"method"===e.kind&&e.descriptor&&!("value"in e.descriptor)?{...e,finisher(i){i.createProperty(e.key,t)}}:{kind:"field",key:Symbol(),placement:"own",descriptor:{},originalKey:e.key,initializer(){"function"==typeof e.initializer&&(this[e.key]=e.initializer.call(this))},finisher(i){i.createProperty(e.key,t)}};function i(t){return(i,o)=>void 0!==o?((t,e,i)=>{e.constructor.createProperty(i,t)})(t,i,o):e(t,i)
|
|
23
23
|
/**
|
|
24
24
|
* @license
|
|
25
25
|
* Copyright 2017 Google LLC
|
|
26
26
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
27
|
-
|
|
27
|
+
*/}function o(t){return i({...t,state:!0})}
|
|
28
28
|
/**
|
|
29
29
|
* @license
|
|
30
30
|
* Copyright 2017 Google LLC
|
|
31
31
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
32
|
-
*/}
|
|
32
|
+
*/const s=({finisher:t,descriptor:e})=>(i,o)=>{var s;if(void 0===o){const o=null!==(s=i.originalKey)&&void 0!==s?s:i.key,n=null!=e?{kind:"method",placement:"prototype",key:o,descriptor:e(i.key)}:{...i,key:o};return null!=t&&(n.finisher=function(e){t(e,o)}),n}{const s=i.constructor;void 0!==e&&Object.defineProperty(i,o,e(o)),null==t||t(s,o)}}
|
|
33
33
|
/**
|
|
34
34
|
* @license
|
|
35
35
|
* Copyright 2017 Google LLC
|
|
36
36
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
37
|
-
|
|
38
|
-
/**
|
|
39
|
-
* @license
|
|
40
|
-
* Copyright 2017 Google LLC
|
|
41
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
42
|
-
*/;function a(t){return n({finisher:(e,i)=>{Object.assign(e.prototype[i],t)}})}
|
|
43
|
-
/**
|
|
44
|
-
* @license
|
|
45
|
-
* Copyright 2017 Google LLC
|
|
46
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
47
|
-
*/function c(t,e){return n({descriptor:i=>{const r={get(){var e,i;return null!==(i=null===(e=this.renderRoot)||void 0===e?void 0:e.querySelector(t))&&void 0!==i?i:null},enumerable:!0,configurable:!0};if(e){const e="symbol"==typeof i?Symbol():"__"+i;r.get=function(){var i,r;return void 0===this[e]&&(this[e]=null!==(r=null===(i=this.renderRoot)||void 0===i?void 0:i.querySelector(t))&&void 0!==r?r:null),this[e]}}return r}})}
|
|
37
|
+
*/;function n(t,e){return s({descriptor:i=>{const o={get(){var e,i;return null!==(i=null===(e=this.renderRoot)||void 0===e?void 0:e.querySelector(t))&&void 0!==i?i:null},enumerable:!0,configurable:!0};if(e){const e="symbol"==typeof i?Symbol():"__"+i;o.get=function(){var i,o;return void 0===this[e]&&(this[e]=null!==(o=null===(i=this.renderRoot)||void 0===i?void 0:i.querySelector(t))&&void 0!==o?o:null),this[e]}}return o}})}
|
|
48
38
|
/**
|
|
49
39
|
* @license
|
|
50
40
|
* Copyright 2017 Google LLC
|
|
51
41
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
52
42
|
*/
|
|
53
|
-
/**
|
|
54
|
-
* @license
|
|
55
|
-
* Copyright 2017 Google LLC
|
|
56
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
57
|
-
*/
|
|
58
|
-
function s(t){return n({descriptor:e=>({async get(){var e;return await this.updateComplete,null===(e=this.renderRoot)||void 0===e?void 0:e.querySelector(t)},enumerable:!0,configurable:!0})})}
|
|
59
43
|
/**
|
|
60
44
|
* @license
|
|
61
45
|
* Copyright 2021 Google LLC
|
|
62
46
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
63
|
-
*/
|
|
47
|
+
*/
|
|
48
|
+
var r;const l=null!=(null===(r=window.HTMLSlotElement)||void 0===r?void 0:r.prototype.assignedElements)?(t,e)=>t.assignedElements(e):(t,e)=>t.assignedNodes(e).filter((t=>t.nodeType===Node.ELEMENT_NODE));function a(t){const{slot:e,selector:i}=null!=t?t:{};return s({descriptor:o=>({get(){var o;const s="slot"+(e?`[name=${e}]`:":not([name])"),n=null===(o=this.renderRoot)||void 0===o?void 0:o.querySelector(s),r=null!=n?l(n,t):[];return i?r.filter((t=>t.matches(i))):r},enumerable:!0,configurable:!0})})}
|
|
64
49
|
/**
|
|
65
50
|
* @license
|
|
66
51
|
* Copyright 2017 Google LLC
|
|
67
52
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
68
|
-
*/
|
|
69
|
-
function h(t,e,i){let r,o=t;return"object"==typeof t?(o=t.slot,r=t):r={flatten:e},i?function(t){const{slot:e,selector:i}=null!=t?t:{};return n({descriptor:r=>({get(){var r;const o="slot"+(e?`[name=${e}]`:":not([name])"),n=null===(r=this.renderRoot)||void 0===r?void 0:r.querySelector(o),a=null!=n?d(n,t):[];return i?a.filter((t=>t.matches(i))):a},enumerable:!0,configurable:!0})})}({slot:o,flatten:e,selector:i}):n({descriptor:t=>({get(){var t,e;const i="slot"+(o?`[name=${o}]`:":not([name])"),n=null===(t=this.renderRoot)||void 0===t?void 0:t.querySelector(i);return null!==(e=null==n?void 0:n.assignedNodes(r))&&void 0!==e?e:[]},enumerable:!0,configurable:!0})})}const p=t=>e=>{window.customElements.get(t)||window.customElements.define(t,e)};function f(t,e){const i=()=>JSON.parse(JSON.stringify(t));return r({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:{}})}
|
|
53
|
+
*/const c=t=>e=>{window.customElements.get(t)||window.customElements.define(t,e)};function h(t,e){const o=()=>JSON.parse(JSON.stringify(t));return i({type:Object,converter:{fromAttribute:t=>{if(null==t)return o();try{return JSON.parse(t)}catch{return o()}},toAttribute:t=>JSON.stringify(t)},...null!=e?e:{}})}
|
|
70
54
|
/**
|
|
71
55
|
* @license
|
|
72
56
|
* Copyright 2019 Google LLC
|
|
73
57
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
74
|
-
*/const
|
|
58
|
+
*/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 b=t=>new u("string"==typeof t?t:t+"",d),v=(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)},g=(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)}))},x=p?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return b(e)})(t):t
|
|
75
59
|
/**
|
|
76
60
|
* @license
|
|
77
61
|
* Copyright 2017 Google LLC
|
|
78
62
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
79
|
-
*/;var
|
|
63
|
+
*/;var y;const m=window.trustedTypes,$=m?m.emptyScript:"",w=window.reactiveElementPolyfillSupport,k={toAttribute(t,e){switch(e){case Boolean:t=t?$:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},S=(t,e)=>e!==t&&(e==e||t==t),O={attribute:!0,type:String,converter:k,reflect:!1,hasChanged:S};class C extends HTMLElement{constructor(){super(),this._$Et=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Ei=null,this.o()}static addInitializer(t){var e;null!==(e=this.l)&&void 0!==e||(this.l=[]),this.l.push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((e,i)=>{const o=this._$Eh(i,e);void 0!==o&&(this._$Eu.set(o,i),t.push(o))})),t}static createProperty(t,e=O){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)||O}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(x(t))}else void 0!==t&&e.push(x(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 g(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=O){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:k.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:k.fromAttribute;this._$Ei=r,this[r]=a(e,t.type),this._$Ei=null}}requestUpdate(t,e,i){let o=!0;void 0!==t&&(((i=i||this.constructor.getPropertyOptions(t)).hasChanged||S)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),!0===i.reflect&&this._$Ei!==t&&(void 0===this._$E_&&(this._$E_=new Map),this._$E_.set(t,i))):o=!1),!this.isUpdatePending&&o&&(this._$Ep=this._$EC())}async _$EC(){this.isUpdatePending=!0;try{await this._$Ep}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Et&&(this._$Et.forEach(((t,e)=>this[e]=t)),this._$Et=void 0);let e=!1;const i=this._$AL;try{e=this.shouldUpdate(i),e?(this.willUpdate(i),null===(t=this._$Eg)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostUpdate)||void 0===e?void 0:e.call(t)})),this.update(i)):this._$EU()}catch(t){throw e=!1,this._$EU(),t}e&&this._$AE(i)}willUpdate(t){}_$AE(t){var e;null===(e=this._$Eg)||void 0===e||e.forEach((t=>{var e;return null===(e=t.hostUpdated)||void 0===e?void 0:e.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EU(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$Ep}shouldUpdate(t){return!0}update(t){void 0!==this._$E_&&(this._$E_.forEach(((t,e)=>this._$ES(e,this[e],t))),this._$E_=void 0),this._$EU()}updated(t){}firstUpdated(t){}}
|
|
80
64
|
/**
|
|
81
65
|
* @license
|
|
82
66
|
* Copyright 2017 Google LLC
|
|
83
67
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
84
68
|
*/
|
|
85
|
-
var
|
|
69
|
+
var z;C.finalized=!0,C.elementProperties=new Map,C.elementStyles=[],C.shadowRootOptions={mode:"open"},null==w||w({ReactiveElement:C}),(null!==(y=globalThis.reactiveElementVersions)&&void 0!==y?y:globalThis.reactiveElementVersions=[]).push("1.2.2");const E=globalThis.trustedTypes,B=E?E.createPolicy("lit-html",{createHTML:t=>t}):void 0,N=`lit$${(Math.random()+"").slice(9)}$`,F="?"+N,R=`<${F}>`,M=document,L=(t="")=>M.createComment(t),D=t=>null===t||"object"!=typeof t&&"function"!=typeof t,j=Array.isArray,I=t=>{var e;return j(t)||"function"==typeof(null===(e=t)||void 0===e?void 0:e[Symbol.iterator])},U=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,T=/-->/g,A=/>/g,P=/>|[ \n\r](?:([^\s"'>=/]+)([ \n\r]*=[ \n\r]*(?:[^ \n\r"'`<>=]|("|')|))|$)/g,_=/'/g,H=/"/g,Z=/^(?:script|style|textarea|title)$/i,K=(t=>(e,...i)=>({_$litType$:t,strings:e,values:i}))(1),W=Symbol.for("lit-noChange"),V=Symbol.for("lit-nothing"),q=new WeakMap,J=M.createTreeWalker(M,129,null,!1),X=(t,e)=>{const i=t.length-1,o=[];let s,n=2===e?"<svg>":"",r=U;for(let e=0;e<i;e++){const i=t[e];let l,a,c=-1,h=0;for(;h<i.length&&(r.lastIndex=h,a=r.exec(i),null!==a);)h=r.lastIndex,r===U?"!--"===a[1]?r=T:void 0!==a[1]?r=A:void 0!==a[2]?(Z.test(a[2])&&(s=RegExp("</"+a[2],"g")),r=P):void 0!==a[3]&&(r=P):r===P?">"===a[0]?(r=null!=s?s:U,c=-1):void 0===a[1]?c=-2:(c=r.lastIndex-a[2].length,l=a[1],r=void 0===a[3]?P:'"'===a[3]?H:_):r===H||r===_?r=P:r===T||r===A?r=U:(r=P,s=void 0);const p=r===P&&t[e+1].startsWith("/>")?" ":"";n+=r===U?i+R:c>=0?(o.push(l),i.slice(0,c)+"$lit$"+i.slice(c)+N+p):i+N+(-2===c?(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!==B?B.createHTML(l):l,o]};class Y{constructor({strings:t,_$litType$:e},i){let o;this.parts=[];let s=0,n=0;const r=t.length-1,l=this.parts,[a,c]=X(t,e);if(this.el=Y.createElement(a,i),J.currentNode=this.el.content,2===e){const t=this.el.content,e=t.firstChild;e.remove(),t.append(...e.childNodes)}for(;null!==(o=J.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(N)){const i=c[n++];if(t.push(e),void 0!==i){const t=o.getAttribute(i.toLowerCase()+"$lit$").split(N),e=/([.?@])?(.*)/.exec(i);l.push({type:1,index:s,name:e[2],strings:t,ctor:"."===e[1]?it:"?"===e[1]?st:"@"===e[1]?nt:et})}else l.push({type:6,index:s})}for(const e of t)o.removeAttribute(e)}if(Z.test(o.tagName)){const t=o.textContent.split(N),e=t.length-1;if(e>0){o.textContent=E?E.emptyScript:"";for(let i=0;i<e;i++)o.append(t[i],L()),J.nextNode(),l.push({type:2,index:++s});o.append(t[e],L())}}}else if(8===o.nodeType)if(o.data===F)l.push({type:2,index:s});else{let t=-1;for(;-1!==(t=o.data.indexOf(N,t+1));)l.push({type:7,index:s}),t+=N.length-1}s++}}static createElement(t,e){const i=M.createElement("template");return i.innerHTML=t,i}}function Q(t,e,i=t,o){var s,n,r,l;if(e===W)return e;let a=void 0!==o?null===(s=i._$Cl)||void 0===s?void 0:s[o]:i._$Cu;const c=D(e)?void 0:e._$litDirective$;return(null==a?void 0:a.constructor)!==c&&(null===(n=null==a?void 0:a._$AO)||void 0===n||n.call(a,!1),void 0===c?a=void 0:(a=new c(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 G{constructor(t,e){this.v=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}p(t){var e;const{el:{content:i},parts:o}=this._$AD,s=(null!==(e=null==t?void 0:t.creationScope)&&void 0!==e?e:M).importNode(i,!0);J.currentNode=s;let n=J.nextNode(),r=0,l=0,a=o[0];for(;void 0!==a;){if(r===a.index){let e;2===a.type?e=new tt(n,n.nextSibling,this,t):1===a.type?e=new a.ctor(n,a.name,a.strings,this,t):6===a.type&&(e=new rt(n,this,t)),this.v.push(e),a=o[++l]}r!==(null==a?void 0:a.index)&&(n=J.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 tt{constructor(t,e,i,o){var s;this.type=2,this._$AH=V,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=o,this._$Cg=null===(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===V||null==t||""===t?(this._$AH!==V&&this._$AR(),this._$AH=V):t!==this._$AH&&t!==W&&this.$(t):void 0!==t._$litType$?this.T(t):void 0!==t.nodeType?this.S(t):I(t)?this.A(t):this.$(t)}M(t,e=this._$AB){return this._$AA.parentNode.insertBefore(t,e)}S(t){this._$AH!==t&&(this._$AR(),this._$AH=this.M(t))}$(t){this._$AH!==V&&D(this._$AH)?this._$AA.nextSibling.data=t:this.S(M.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=Y.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 G(s,this),e=t.p(this.options);t.m(i),this.S(e),this._$AH=t}}_$AC(t){let e=q.get(t.strings);return void 0===e&&q.set(t.strings,e=new Y(t)),e}A(t){j(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,o=0;for(const s of t)o===e.length?e.push(i=new tt(this.M(L()),this.M(L()),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 et{constructor(t,e,i,o,s){this.type=1,this._$AH=V,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=V}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!==W,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===W&&(l=this._$AH[r]),n||(n=!D(l)||l!==this._$AH[r]),l===V?t=V:t!==V&&(t+=(null!=l?l:"")+s[r+1]),this._$AH[r]=l}n&&!o&&this.k(t)}k(t){t===V?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class it extends et{constructor(){super(...arguments),this.type=3}k(t){this.element[this.name]=t===V?void 0:t}}const ot=E?E.emptyScript:"";class st extends et{constructor(){super(...arguments),this.type=4}k(t){t&&t!==V?this.element.setAttribute(this.name,ot):this.element.removeAttribute(this.name)}}class nt extends et{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:V)===W)return;const o=this._$AH,s=t===V&&o!==V||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,n=t!==V&&(o===V||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 rt{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){Q(this,t)}}const lt={P:"$lit$",V:N,L:F,I:1,N:X,R:G,D:I,j:Q,H:tt,O:et,F:st,B:nt,W:it,Z:rt},at=window.litHtmlPolyfillSupport;
|
|
86
70
|
/**
|
|
87
71
|
* @license
|
|
88
72
|
* Copyright 2017 Google LLC
|
|
89
73
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
90
74
|
*/
|
|
91
|
-
var
|
|
75
|
+
var ct,ht;null==at||at(Y,tt),(null!==(z=globalThis.litHtmlVersions)&&void 0!==z?z:globalThis.litHtmlVersions=[]).push("2.1.3");class pt extends C{constructor(){super(...arguments),this.renderOptions={host:this},this._$Dt=void 0}createRenderRoot(){var t,e;const i=super.createRenderRoot();return null!==(t=(e=this.renderOptions).renderBefore)&&void 0!==t||(e.renderBefore=i.firstChild),i}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Dt=((t,e,i)=>{var o,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 tt(e.insertBefore(L(),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 W}}pt.finalized=!0,pt._$litElement$=!0,null===(ct=globalThis.litElementHydrateSupport)||void 0===ct||ct.call(globalThis,{LitElement:pt});const dt=globalThis.litElementPolyfillSupport;null==dt||dt({LitElement:pt}),(null!==(ht=globalThis.litElementVersions)&&void 0!==ht?ht:globalThis.litElementVersions=[]).push("3.1.2");class ft{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 ft(t,e,void 0,i)}static extend(t,e,i){return new ft(t,e.category,e,i)}static external(t,e){return new ft(t.name,t.category,t.fallbackVariable,t.defaultValue,e)}get(t){return v`var(${b(this.name)}, ${this.defaultCssValue(t)})`}defaultCssValue(t){return this.fallbackVariable?this.fallbackVariable.get(null!=t?t:this.defaultValue):b(null!=t?t:this.defaultValue)}lastResortDefaultValue(){var t,e;return null!==(t=this.defaultValue)&&void 0!==t?t:null===(e=this.fallbackVariable)||void 0===e?void 0:e.lastResortDefaultValue()}breadcrumb(){return this.fallbackVariable?[this.fallbackVariable.name,...this.fallbackVariable.breadcrumb()]:[]}}function ut(t,e){return b(`${t.name}: ${e}`)}const bt={colorPrimary:ft.create("--ft-color-primary","COLOR","#2196F3"),colorPrimaryVariant:ft.create("--ft-color-primary-variant","COLOR","#1976D2"),colorSecondary:ft.create("--ft-color-secondary","COLOR","#FFCC80"),colorSecondaryVariant:ft.create("--ft-color-secondary-variant","COLOR","#F57C00"),colorSurface:ft.create("--ft-color-surface","COLOR","#FFFFFF"),colorContent:ft.create("--ft-color-content","COLOR","rgba(0, 0, 0, 0.87)"),colorError:ft.create("--ft-color-error","COLOR","#B00020"),colorOutline:ft.create("--ft-color-outline","COLOR","rgba(0, 0, 0, 0.14)"),colorOpacityHigh:ft.create("--ft-color-opacity-high","NUMBER","1"),colorOpacityMedium:ft.create("--ft-color-opacity-medium","NUMBER","0.74"),colorOpacityDisabled:ft.create("--ft-color-opacity-disabled","NUMBER","0.38"),colorOnPrimary:ft.create("--ft-color-on-primary","COLOR","#FFFFFF"),colorOnPrimaryHigh:ft.create("--ft-color-on-primary-high","COLOR","#FFFFFF"),colorOnPrimaryMedium:ft.create("--ft-color-on-primary-medium","COLOR","rgba(255, 255, 255, 0.74)"),colorOnPrimaryDisabled:ft.create("--ft-color-on-primary-disabled","COLOR","rgba(255, 255, 255, 0.38)"),colorOnSecondary:ft.create("--ft-color-on-secondary","COLOR","#FFFFFF"),colorOnSecondaryHigh:ft.create("--ft-color-on-secondary-high","COLOR","#FFFFFF"),colorOnSecondaryMedium:ft.create("--ft-color-on-secondary-medium","COLOR","rgba(255, 255, 255, 0.74)"),colorOnSecondaryDisabled:ft.create("--ft-color-on-secondary-disabled","COLOR","rgba(255, 255, 255, 0.38)"),colorOnSurface:ft.create("--ft-color-on-surface","COLOR","rgba(0, 0, 0, 0.87)"),colorOnSurfaceHigh:ft.create("--ft-color-on-surface-high","COLOR","rgba(0, 0, 0, 0.87)"),colorOnSurfaceMedium:ft.create("--ft-color-on-surface-medium","COLOR","rgba(0, 0, 0, 0.60)"),colorOnSurfaceDisabled:ft.create("--ft-color-on-surface-disabled","COLOR","rgba(0, 0, 0, 0.38)"),opacityContentOnSurfaceDisabled:ft.create("--ft-opacity-content-on-surface-disabled","NUMBER","0"),opacityContentOnSurfaceEnable:ft.create("--ft-opacity-content-on-surface-enable","NUMBER","0"),opacityContentOnSurfaceHover:ft.create("--ft-opacity-content-on-surface-hover","NUMBER","0.04"),opacityContentOnSurfaceFocused:ft.create("--ft-opacity-content-on-surface-focused","NUMBER","0.12"),opacityContentOnSurfacePressed:ft.create("--ft-opacity-content-on-surface-pressed","NUMBER","0.10"),opacityContentOnSurfaceSelected:ft.create("--ft-opacity-content-on-surface-selected","NUMBER","0.08"),opacityContentOnSurfaceDragged:ft.create("--ft-opacity-content-on-surface-dragged","NUMBER","0.08"),opacityPrimaryOnSurfaceDisabled:ft.create("--ft-opacity-primary-on-surface-disabled","NUMBER","0"),opacityPrimaryOnSurfaceEnable:ft.create("--ft-opacity-primary-on-surface-enable","NUMBER","0"),opacityPrimaryOnSurfaceHover:ft.create("--ft-opacity-primary-on-surface-hover","NUMBER","0.04"),opacityPrimaryOnSurfaceFocused:ft.create("--ft-opacity-primary-on-surface-focused","NUMBER","0.12"),opacityPrimaryOnSurfacePressed:ft.create("--ft-opacity-primary-on-surface-pressed","NUMBER","0.10"),opacityPrimaryOnSurfaceSelected:ft.create("--ft-opacity-primary-on-surface-selected","NUMBER","0.08"),opacityPrimaryOnSurfaceDragged:ft.create("--ft-opacity-primary-on-surface-dragged","NUMBER","0.08"),opacitySurfaceOnPrimaryDisabled:ft.create("--ft-opacity-surface-on-primary-disabled","NUMBER","0"),opacitySurfaceOnPrimaryEnable:ft.create("--ft-opacity-surface-on-primary-enable","NUMBER","0"),opacitySurfaceOnPrimaryHover:ft.create("--ft-opacity-surface-on-primary-hover","NUMBER","0.04"),opacitySurfaceOnPrimaryFocused:ft.create("--ft-opacity-surface-on-primary-focused","NUMBER","0.12"),opacitySurfaceOnPrimaryPressed:ft.create("--ft-opacity-surface-on-primary-pressed","NUMBER","0.10"),opacitySurfaceOnPrimarySelected:ft.create("--ft-opacity-surface-on-primary-selected","NUMBER","0.08"),opacitySurfaceOnPrimaryDragged:ft.create("--ft-opacity-surface-on-primary-dragged","NUMBER","0.08"),elevation00:ft.create("--ft-elevation-00","UNKNOWN","0px 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px 0px rgba(0, 0, 0, 0)"),elevation01:ft.create("--ft-elevation-01","UNKNOWN","0px 1px 4px 0px rgba(0, 0, 0, 0.06), 0px 1px 2px 0px rgba(0, 0, 0, 0.14), 0px 0px 1px 0px rgba(0, 0, 0, 0.06)"),elevation02:ft.create("--ft-elevation-02","UNKNOWN","0px 4px 10px 0px rgba(0, 0, 0, 0.06), 0px 2px 5px 0px rgba(0, 0, 0, 0.14), 0px 0px 1px 0px rgba(0, 0, 0, 0.06)"),elevation03:ft.create("--ft-elevation-03","UNKNOWN","0px 6px 13px 0px rgba(0, 0, 0, 0.06), 0px 3px 7px 0px rgba(0, 0, 0, 0.14), 0px 1px 2px 0px rgba(0, 0, 0, 0.06)"),elevation04:ft.create("--ft-elevation-04","UNKNOWN","0px 8px 16px 0px rgba(0, 0, 0, 0.06), 0px 4px 9px 0px rgba(0, 0, 0, 0.14), 0px 2px 3px 0px rgba(0, 0, 0, 0.06)"),elevation06:ft.create("--ft-elevation-06","UNKNOWN","0px 12px 22px 0px rgba(0, 0, 0, 0.06), 0px 6px 13px 0px rgba(0, 0, 0, 0.14), 0px 4px 5px 0px rgba(0, 0, 0, 0.06)"),elevation08:ft.create("--ft-elevation-08","UNKNOWN","0px 16px 28px 0px rgba(0, 0, 0, 0.06), 0px 8px 17px 0px rgba(0, 0, 0, 0.14), 0px 6px 7px 0px rgba(0, 0, 0, 0.06)"),elevation12:ft.create("--ft-elevation-12","UNKNOWN","0px 22px 40px 0px rgba(0, 0, 0, 0.06), 0px 12px 23px 0px rgba(0, 0, 0, 0.14), 0px 10px 11px 0px rgba(0, 0, 0, 0.06)"),elevation16:ft.create("--ft-elevation-16","UNKNOWN","0px 28px 52px 0px rgba(0, 0, 0, 0.06), 0px 16px 29px 0px rgba(0, 0, 0, 0.14), 0px 14px 15px 0px rgba(0, 0, 0, 0.06)"),elevation24:ft.create("--ft-elevation-24","UNKNOWN","0px 40px 76px 0px rgba(0, 0, 0, 0.06), 0px 24px 41px 0px rgba(0, 0, 0, 0.14), 0px 22px 23px 0px rgba(0, 0, 0, 0.06)"),borderRadiusS:ft.create("--ft-border-radius-S","SIZE","4px"),borderRadiusM:ft.create("--ft-border-radius-M","SIZE","8px"),borderRadiusL:ft.create("--ft-border-radius-L","SIZE","12px"),borderRadiusXL:ft.create("--ft-border-radius-XL","SIZE","16px"),titleFont:ft.create("--ft-title-font","UNKNOWN","Ubuntu, system-ui, sans-serif"),contentFont:ft.create("--ft-content-font","UNKNOWN","'Open Sans', system-ui, sans-serif"),transitionDuration:ft.create("--ft-transition-duration","UNKNOWN","250ms"),transitionTimingFunction:ft.create("--ft-transition-timing-function","UNKNOWN","ease-in-out")};
|
|
92
76
|
/**
|
|
93
77
|
* @license
|
|
94
78
|
* Copyright 2021 Google LLC
|
|
95
79
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
96
|
-
*/class
|
|
97
|
-
${t.map((t=>
|
|
80
|
+
*/class vt 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 g(s,this.constructor.elementStyles),s}}}(pt)){getStyles(){return[]}getTemplate(){return null}render(){let t=this.getStyles();return Array.isArray(t)||(t=[t]),K`
|
|
81
|
+
${t.map((t=>K`
|
|
98
82
|
<style>${t}</style>
|
|
99
83
|
`))}
|
|
100
84
|
${this.getTemplate()}
|
|
101
|
-
`}updated(t){super.updated(t),setTimeout((()=>this.contentAvailableCallback(t)),0)}contentAvailableCallback(t){}}const
|
|
85
|
+
`}updated(t){super.updated(t),setTimeout((()=>this.contentAvailableCallback(t)),0)}contentAvailableCallback(t){}}const gt=v`
|
|
102
86
|
.ft-no-text-select {
|
|
103
87
|
-webkit-touch-callout: none;
|
|
104
88
|
-webkit-user-select: none;
|
|
@@ -107,26 +91,26 @@ var pt,ft;null==ht||ht(tt,rt),(null!==(R=globalThis.litHtmlVersions)&&void 0!==R
|
|
|
107
91
|
-ms-user-select: none;
|
|
108
92
|
user-select: none;
|
|
109
93
|
}
|
|
110
|
-
`;class
|
|
94
|
+
`;class xt{constructor(t,e){this.defaultLabels=t,this.labels=e}resolve(t,...e){var i,o;let s=null!==(o=null!==(i=this.labels[t])&&void 0!==i?i:this.defaultLabels[t])&&void 0!==o?o:"";return e.forEach(((t,e)=>s=s.replace(new RegExp(`\\{${e}\\}`,"g"),t))),s}}var yt,mt,$t;const wt=navigator.vendor&&!!navigator.vendor.match(/apple/i)||"[object SafariRemoteNotification]"===(null!==($t=null===(mt=null===(yt=window.safari)||void 0===yt?void 0:yt.pushNotification)||void 0===mt?void 0:mt.toString())&&void 0!==$t?$t:""),kt=1,St=2,Ot=t=>(...e)=>({_$litDirective$:t,values:e});
|
|
111
95
|
/**
|
|
112
96
|
* @license
|
|
113
97
|
* Copyright 2017 Google LLC
|
|
114
98
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
115
|
-
*/class
|
|
99
|
+
*/class Ct{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)}}
|
|
116
100
|
/**
|
|
117
101
|
* @license
|
|
118
102
|
* Copyright 2020 Google LLC
|
|
119
103
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
120
|
-
*/const{H:
|
|
104
|
+
*/const{H:zt}=lt,Et=()=>document.createComment(""),Bt=(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(Et(),n),o=s.insertBefore(Et(),n);i=new zt(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},Nt=(t,e,i=t)=>(t._$AI(e,i),t),Ft={},Rt=t=>{var e;null===(e=t._$AP)||void 0===e||e.call(t,!1,!0);let i=t._$AA;const o=t._$AB.nextSibling;for(;i!==o;){const t=i.nextSibling;i.remove(),i=t}},Mt=(t,e,i)=>{const o=new Map;for(let s=e;s<=i;s++)o.set(t[s],s);return o},Lt=Ot(class extends Ct{constructor(t){if(super(t),t.type!==St)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.at=l,r;const a=null!==(s=this.at)&&void 0!==s?s:this.at=[],c=[];let h,p,d=0,f=n.length-1,u=0,b=r.length-1;for(;d<=f&&u<=b;)if(null===n[d])d++;else if(null===n[f])f--;else if(a[d]===l[u])c[u]=Nt(n[d],r[u]),d++,u++;else if(a[f]===l[b])c[b]=Nt(n[f],r[b]),f--,b--;else if(a[d]===l[b])c[b]=Nt(n[d],r[b]),Bt(t,c[b+1],n[d]),d++,b--;else if(a[f]===l[u])c[u]=Nt(n[f],r[u]),Bt(t,n[d],n[f]),f--,u++;else if(void 0===h&&(h=Mt(l,u,b),p=Mt(a,d,f)),h.has(a[d]))if(h.has(a[f])){const e=p.get(l[u]),i=void 0!==e?n[e]:null;if(null===i){const e=Bt(t,n[d]);Nt(e,r[u]),c[u]=e}else c[u]=Nt(i,r[u]),Bt(t,n[d],i),n[e]=null;u++}else Rt(n[f]),f--;else Rt(n[d]),d++;for(;u<=b;){const e=Bt(t,c[b+1]);Nt(e,r[u]),c[u++]=e}for(;d<=f;){const t=n[d++];null!==t&&Rt(t)}return this.at=l,((t,e=Ft)=>{t._$AH=e})(t,c),W}}),Dt=Ot(class extends Ct{constructor(t){var e;if(super(t),t.type!==kt||"class"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter((e=>t[e])).join(" ")+" "}update(t,[e]){var i,o;if(void 0===this.st){this.st=new Set,void 0!==t.strings&&(this.et=new Set(t.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in e)e[t]&&!(null===(i=this.et)||void 0===i?void 0:i.has(t))&&this.st.add(t);return this.render(e)}const s=t.element.classList;this.st.forEach((t=>{t in e||(s.remove(t),this.st.delete(t))}));for(const t in e){const i=!!e[t];i===this.st.has(t)||(null===(o=this.et)||void 0===o?void 0:o.has(t))||(i?(s.add(t),this.st.add(t)):(s.remove(t),this.st.delete(t)))}return W}});
|
|
121
105
|
/**
|
|
122
106
|
* @license
|
|
123
107
|
* Copyright 2017 Google LLC
|
|
124
108
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
125
|
-
*/var It
|
|
109
|
+
*/var jt,It=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.S="S",t.M="M",t.L="L",t.XL="XL",t.XXL="XXL"}(jt||(jt={}));class Ut extends CustomEvent{constructor(t,e){super("change",{detail:{size:t,category:e}})}}class Tt extends vt{constructor(){super(...arguments),this.debounceTimeout=100,this.local=!1,this.size=0,this.category=jt.S,this.resizeObserver=new ResizeObserver((()=>this.updateSize())),this.debouncer=new t}render(){return K`
|
|
126
110
|
<div class="ft-size-watcher--pixel ${this.local?"ft-size-watcher--local":""}">
|
|
127
111
|
<div class="ft-size-watcher--watcher"></div>
|
|
128
112
|
</div>
|
|
129
|
-
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.watcher&&this.resizeObserver.observe(this.watcher),this.updateSize()}updateSize(){this.debouncer.run((()=>{this.watcher&&this.size!==this.watcher.clientWidth&&(this.size=this.watcher.clientWidth,this.size<768?this.category=
|
|
113
|
+
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.watcher&&this.resizeObserver.observe(this.watcher),this.updateSize()}updateSize(){this.debouncer.run((()=>{this.watcher&&this.size!==this.watcher.clientWidth&&(this.size=this.watcher.clientWidth,this.size<768?this.category=jt.S:this.size<976?this.category=jt.M:this.size<1024?this.category=jt.L:this.size<1440?this.category=jt.XL:this.category=jt.XXL,this.dispatchEvent(new Ut(this.size,this.category)))}),this.debounceTimeout)}}Tt.elementDefinitions={},Tt.styles=v`
|
|
130
114
|
.ft-size-watcher--pixel {
|
|
131
115
|
width: 0;
|
|
132
116
|
height: 0;
|
|
@@ -145,95 +129,95 @@ var pt,ft;null==ht||ht(tt,rt),(null!==(R=globalThis.litHtmlVersions)&&void 0!==R
|
|
|
145
129
|
.ft-size-watcher--local .ft-size-watcher--watcher {
|
|
146
130
|
width: 100%;
|
|
147
131
|
}
|
|
148
|
-
`,
|
|
132
|
+
`,It([i({type:Number})],Tt.prototype,"debounceTimeout",void 0),It([i({type:Boolean})],Tt.prototype,"local",void 0),It([i({type:Number,reflect:!0})],Tt.prototype,"size",void 0),It([i({type:String,reflect:!0})],Tt.prototype,"category",void 0),It([n(".ft-size-watcher--watcher")],Tt.prototype,"watcher",void 0),c("ft-size-watcher")(Tt);
|
|
149
133
|
/**
|
|
150
134
|
* @license
|
|
151
135
|
* Copyright 2020 Google LLC
|
|
152
136
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
153
137
|
*/
|
|
154
|
-
const
|
|
138
|
+
const At=t=>({_$litStatic$:t}),Pt=new Map,_t=(t=>(e,...i)=>{var o;const s=i.length;let n,r;const l=[],a=[];let c,h=0,p=!1;for(;h<s;){for(c=e[h];h<s&&void 0!==(r=i[h],n=null===(o=r)||void 0===o?void 0:o._$litStatic$);)c+=n+e[++h],p=!0;a.push(r),l.push(c),h++}if(h===s&&l.push(e[s]),p){const t=l.join("$$lit$$");void 0===(e=Pt.get(t))&&(l.raw=l,Pt.set(t,e=l)),i=a}return t(e,...i)})(K);var Ht,Zt=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"}(Ht||(Ht={}));const Kt=ft.extend("--ft-typography-font-family",bt.titleFont),Wt=ft.extend("--ft-typography-font-family",bt.contentFont),Vt={fontFamily:Wt,fontSize:ft.create("--ft-typography-font-size","SIZE","16px"),fontWeight:ft.create("--ft-typography-font-weight","UNKNOWN","normal"),letterSpacing:ft.create("--ft-typography-letter-spacing","SIZE","0.496px"),lineHeight:ft.create("--ft-typography-line-height","SIZE","24px"),textTransform:ft.create("--ft-typography-text-transform","UNKNOWN","inherit")},qt=ft.extend("--ft-typography-title-font-family",Kt),Jt=ft.extend("--ft-typography-title-font-size",Vt.fontSize,"20px"),Xt=ft.extend("--ft-typography-title-font-weight",Vt.fontWeight,"normal"),Yt=ft.extend("--ft-typography-title-letter-spacing",Vt.letterSpacing,"0.15px"),Qt=ft.extend("--ft-typography-title-line-height",Vt.lineHeight,"24px"),Gt=ft.extend("--ft-typography-title-text-transform",Vt.textTransform,"inherit"),te=ft.extend("--ft-typography-title-dense-font-family",Kt),ee=ft.extend("--ft-typography-title-dense-font-size",Vt.fontSize,"14px"),ie=ft.extend("--ft-typography-title-dense-font-weight",Vt.fontWeight,"normal"),oe=ft.extend("--ft-typography-title-dense-letter-spacing",Vt.letterSpacing,"0.105px"),se=ft.extend("--ft-typography-title-dense-line-height",Vt.lineHeight,"24px"),ne=ft.extend("--ft-typography-title-dense-text-transform",Vt.textTransform,"inherit"),re=ft.extend("--ft-typography-subtitle1-font-family",Wt),le=ft.extend("--ft-typography-subtitle1-font-size",Vt.fontSize,"16px"),ae=ft.extend("--ft-typography-subtitle1-font-weight",Vt.fontWeight,"600"),ce=ft.extend("--ft-typography-subtitle1-letter-spacing",Vt.letterSpacing,"0.144px"),he=ft.extend("--ft-typography-subtitle1-line-height",Vt.lineHeight,"24px"),pe=ft.extend("--ft-typography-subtitle1-text-transform",Vt.textTransform,"inherit"),de=ft.extend("--ft-typography-subtitle2-font-family",Wt),fe=ft.extend("--ft-typography-subtitle2-font-size",Vt.fontSize,"14px"),ue=ft.extend("--ft-typography-subtitle2-font-weight",Vt.fontWeight,"normal"),be=ft.extend("--ft-typography-subtitle2-letter-spacing",Vt.letterSpacing,"0.098px"),ve=ft.extend("--ft-typography-subtitle2-line-height",Vt.lineHeight,"24px"),ge=ft.extend("--ft-typography-subtitle2-text-transform",Vt.textTransform,"inherit"),xe={fontFamily:ft.extend("--ft-typography-body1-font-family",Wt),fontSize:ft.extend("--ft-typography-body1-font-size",Vt.fontSize,"16px"),fontWeight:ft.extend("--ft-typography-body1-font-weight",Vt.fontWeight,"normal"),letterSpacing:ft.extend("--ft-typography-body1-letter-spacing",Vt.letterSpacing,"0.496px"),lineHeight:ft.extend("--ft-typography-body1-line-height",Vt.lineHeight,"24px"),textTransform:ft.extend("--ft-typography-body1-text-transform",Vt.textTransform,"inherit")},ye={fontFamily:ft.extend("--ft-typography-body2-font-family",Wt),fontSize:ft.extend("--ft-typography-body2-font-size",Vt.fontSize,"14px"),fontWeight:ft.extend("--ft-typography-body2-font-weight",Vt.fontWeight,"normal"),letterSpacing:ft.extend("--ft-typography-body2-letter-spacing",Vt.letterSpacing,"0.252px"),lineHeight:ft.extend("--ft-typography-body2-line-height",Vt.lineHeight,"20px"),textTransform:ft.extend("--ft-typography-body2-text-transform",Vt.textTransform,"inherit")},me={fontFamily:ft.extend("--ft-typography-caption-font-family",Wt),fontSize:ft.extend("--ft-typography-caption-font-size",Vt.fontSize,"12px"),fontWeight:ft.extend("--ft-typography-caption-font-weight",Vt.fontWeight,"normal"),letterSpacing:ft.extend("--ft-typography-caption-letter-spacing",Vt.letterSpacing,"0.396px"),lineHeight:ft.extend("--ft-typography-caption-line-height",Vt.lineHeight,"16px"),textTransform:ft.extend("--ft-typography-caption-text-transform",Vt.textTransform,"inherit")},$e=ft.extend("--ft-typography-breadcrumb-font-family",Wt),we=ft.extend("--ft-typography-breadcrumb-font-size",Vt.fontSize,"10px"),ke=ft.extend("--ft-typography-breadcrumb-font-weight",Vt.fontWeight,"normal"),Se=ft.extend("--ft-typography-breadcrumb-letter-spacing",Vt.letterSpacing,"0.33px"),Oe=ft.extend("--ft-typography-breadcrumb-line-height",Vt.lineHeight,"16px"),Ce=ft.extend("--ft-typography-breadcrumb-text-transform",Vt.textTransform,"inherit"),ze=ft.extend("--ft-typography-overline-font-family",Wt),Ee=ft.extend("--ft-typography-overline-font-size",Vt.fontSize,"10px"),Be=ft.extend("--ft-typography-overline-font-weight",Vt.fontWeight,"normal"),Ne=ft.extend("--ft-typography-overline-letter-spacing",Vt.letterSpacing,"1.5px"),Fe=ft.extend("--ft-typography-overline-line-height",Vt.lineHeight,"16px"),Re=ft.extend("--ft-typography-overline-text-transform",Vt.textTransform,"uppercase"),Me={fontFamily:ft.extend("--ft-typography-button-font-family",Wt),fontSize:ft.extend("--ft-typography-button-font-size",Vt.fontSize,"14px"),fontWeight:ft.extend("--ft-typography-button-font-weight",Vt.fontWeight,"600"),letterSpacing:ft.extend("--ft-typography-button-letter-spacing",Vt.letterSpacing,"1.246px"),lineHeight:ft.extend("--ft-typography-button-line-height",Vt.lineHeight,"16px"),textTransform:ft.extend("--ft-typography-button-text-transform",Vt.textTransform,"uppercase")},Le=v`
|
|
155
139
|
.ft-typography--title {
|
|
156
|
-
font-family: ${
|
|
157
|
-
font-size: ${
|
|
158
|
-
font-weight: ${
|
|
159
|
-
letter-spacing: ${
|
|
160
|
-
line-height: ${
|
|
161
|
-
text-transform: ${
|
|
162
|
-
}
|
|
163
|
-
`,De=
|
|
140
|
+
font-family: ${qt};
|
|
141
|
+
font-size: ${Jt};
|
|
142
|
+
font-weight: ${Xt};
|
|
143
|
+
letter-spacing: ${Yt};
|
|
144
|
+
line-height: ${Qt};
|
|
145
|
+
text-transform: ${Gt};
|
|
146
|
+
}
|
|
147
|
+
`,De=v`
|
|
164
148
|
.ft-typography--title-dense {
|
|
149
|
+
font-family: ${te};
|
|
150
|
+
font-size: ${ee};
|
|
151
|
+
font-weight: ${ie};
|
|
152
|
+
letter-spacing: ${oe};
|
|
153
|
+
line-height: ${se};
|
|
154
|
+
text-transform: ${ne};
|
|
155
|
+
}
|
|
156
|
+
`,je=v`
|
|
157
|
+
.ft-typography--subtitle1 {
|
|
165
158
|
font-family: ${re};
|
|
166
|
-
font-size: ${
|
|
167
|
-
font-weight: ${
|
|
168
|
-
letter-spacing: ${
|
|
169
|
-
line-height: ${
|
|
170
|
-
text-transform: ${
|
|
159
|
+
font-size: ${le};
|
|
160
|
+
font-weight: ${ae};
|
|
161
|
+
letter-spacing: ${ce};
|
|
162
|
+
line-height: ${he};
|
|
163
|
+
text-transform: ${pe};
|
|
171
164
|
}
|
|
172
|
-
`,Ie=
|
|
173
|
-
.ft-typography--subtitle1 {
|
|
174
|
-
font-family: ${le};
|
|
175
|
-
font-size: ${de};
|
|
176
|
-
font-weight: ${he};
|
|
177
|
-
letter-spacing: ${pe};
|
|
178
|
-
line-height: ${fe};
|
|
179
|
-
text-transform: ${ue};
|
|
180
|
-
}
|
|
181
|
-
`,je=x`
|
|
165
|
+
`,Ie=v`
|
|
182
166
|
.ft-typography--subtitle2 {
|
|
183
|
-
font-family: ${
|
|
184
|
-
font-size: ${
|
|
185
|
-
font-weight: ${
|
|
186
|
-
letter-spacing: ${
|
|
187
|
-
line-height: ${
|
|
188
|
-
text-transform: ${
|
|
167
|
+
font-family: ${de};
|
|
168
|
+
font-size: ${fe};
|
|
169
|
+
font-weight: ${ue};
|
|
170
|
+
letter-spacing: ${be};
|
|
171
|
+
line-height: ${ve};
|
|
172
|
+
text-transform: ${ge};
|
|
189
173
|
}
|
|
190
174
|
|
|
191
|
-
`,Ue=
|
|
175
|
+
`,Ue=v`
|
|
192
176
|
.ft-typography--body1 {
|
|
193
|
-
font-family: ${
|
|
194
|
-
font-size: ${
|
|
195
|
-
font-weight: ${
|
|
196
|
-
letter-spacing: ${
|
|
197
|
-
line-height: ${
|
|
198
|
-
text-transform: ${
|
|
199
|
-
}
|
|
200
|
-
`,
|
|
177
|
+
font-family: ${xe.fontFamily};
|
|
178
|
+
font-size: ${xe.fontSize};
|
|
179
|
+
font-weight: ${xe.fontWeight};
|
|
180
|
+
letter-spacing: ${xe.letterSpacing};
|
|
181
|
+
line-height: ${xe.lineHeight};
|
|
182
|
+
text-transform: ${xe.textTransform};
|
|
183
|
+
}
|
|
184
|
+
`,Te=v`
|
|
201
185
|
.ft-typography--body2 {
|
|
202
|
-
font-family: ${
|
|
203
|
-
font-size: ${
|
|
204
|
-
font-weight: ${
|
|
205
|
-
letter-spacing: ${
|
|
206
|
-
line-height: ${
|
|
207
|
-
text-transform: ${
|
|
208
|
-
}
|
|
209
|
-
`,
|
|
186
|
+
font-family: ${ye.fontFamily};
|
|
187
|
+
font-size: ${ye.fontSize};
|
|
188
|
+
font-weight: ${ye.fontWeight};
|
|
189
|
+
letter-spacing: ${ye.letterSpacing};
|
|
190
|
+
line-height: ${ye.lineHeight};
|
|
191
|
+
text-transform: ${ye.textTransform};
|
|
192
|
+
}
|
|
193
|
+
`,Ae=v`
|
|
210
194
|
.ft-typography--caption {
|
|
211
|
-
font-family: ${
|
|
212
|
-
font-size: ${
|
|
213
|
-
font-weight: ${
|
|
214
|
-
letter-spacing: ${
|
|
215
|
-
line-height: ${
|
|
216
|
-
text-transform: ${
|
|
217
|
-
}
|
|
218
|
-
`,
|
|
195
|
+
font-family: ${me.fontFamily};
|
|
196
|
+
font-size: ${me.fontSize};
|
|
197
|
+
font-weight: ${me.fontWeight};
|
|
198
|
+
letter-spacing: ${me.letterSpacing};
|
|
199
|
+
line-height: ${me.lineHeight};
|
|
200
|
+
text-transform: ${me.textTransform};
|
|
201
|
+
}
|
|
202
|
+
`,Pe=v`
|
|
219
203
|
.ft-typography--breadcrumb {
|
|
220
|
-
font-family: ${
|
|
221
|
-
font-size: ${
|
|
222
|
-
font-weight: ${
|
|
223
|
-
letter-spacing: ${
|
|
224
|
-
line-height: ${
|
|
225
|
-
text-transform: ${
|
|
226
|
-
}
|
|
227
|
-
`,
|
|
204
|
+
font-family: ${$e};
|
|
205
|
+
font-size: ${we};
|
|
206
|
+
font-weight: ${ke};
|
|
207
|
+
letter-spacing: ${Se};
|
|
208
|
+
line-height: ${Oe};
|
|
209
|
+
text-transform: ${Ce};
|
|
210
|
+
}
|
|
211
|
+
`,_e=v`
|
|
228
212
|
.ft-typography--overline {
|
|
229
|
-
font-family: ${
|
|
230
|
-
font-size: ${
|
|
231
|
-
font-weight: ${
|
|
232
|
-
letter-spacing: ${
|
|
233
|
-
line-height: ${
|
|
234
|
-
text-transform: ${
|
|
235
|
-
}
|
|
236
|
-
`,
|
|
213
|
+
font-family: ${ze};
|
|
214
|
+
font-size: ${Ee};
|
|
215
|
+
font-weight: ${Be};
|
|
216
|
+
letter-spacing: ${Ne};
|
|
217
|
+
line-height: ${Fe};
|
|
218
|
+
text-transform: ${Re};
|
|
219
|
+
}
|
|
220
|
+
`,He=v`
|
|
237
221
|
.ft-typography--button {
|
|
238
222
|
font-family: ${Me.fontFamily};
|
|
239
223
|
font-size: ${Me.fontSize};
|
|
@@ -242,231 +226,18 @@ const Ht=t=>({_$litStatic$:t}),Vt=new Map,Zt=(t=>(e,...i)=>{var r;const o=i.leng
|
|
|
242
226
|
line-height: ${Me.lineHeight};
|
|
243
227
|
text-transform: ${Me.textTransform};
|
|
244
228
|
}
|
|
245
|
-
`;class
|
|
246
|
-
<${
|
|
229
|
+
`;class Ze extends vt{constructor(){super(...arguments),this.variant=Ht.body1}render(){return this.element?_t`
|
|
230
|
+
<${At(this.element)}
|
|
247
231
|
class="ft-typography ft-typography--${this.variant}">
|
|
248
232
|
<slot></slot>
|
|
249
|
-
</${
|
|
250
|
-
`:
|
|
233
|
+
</${At(this.element)}>
|
|
234
|
+
`:_t`
|
|
251
235
|
<slot class="ft-typography ft-typography--${this.variant}"></slot>
|
|
252
|
-
`}}function
|
|
236
|
+
`}}function Ke(t,e){return t.flatMap((t=>[t,...Ke(e(t),e)]))}function We(t){return t.startsWith('"')&&t.endsWith('"')?t.replace(/(^"+)|("+$)/g,""):t}function Ve(t,e){return{label:t.label,selected:!e&&t.selected,subOptions:t.childNodes.map((e=>Ve(e,t.selected))),value:t.value}}function qe(t){return{id:t.key,label:t.label,multivalued:t.multiSelectionable,options:t.rootNodes.map((t=>Ve(t,!1)))}}Ze.styles=[Le,De,je,Ie,Ue,Te,Ae,Pe,_e,He,v`
|
|
253
237
|
.ft-typography {
|
|
254
238
|
vertical-align: inherit;
|
|
255
239
|
}
|
|
256
|
-
`],
|
|
257
|
-
/*! *****************************************************************************
|
|
258
|
-
Copyright (c) Microsoft Corporation.
|
|
259
|
-
|
|
260
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
261
|
-
purpose with or without fee is hereby granted.
|
|
262
|
-
|
|
263
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
264
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
265
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
266
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
267
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
268
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
269
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
270
|
-
***************************************************************************** */
|
|
271
|
-
var Ye=function(t,e){return Ye=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i])},Ye(t,e)};function Qe(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function i(){this.constructor=t}Ye(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}var ti=function(){return ti=Object.assign||function(t){for(var e,i=1,r=arguments.length;i<r;i++)for(var o in e=arguments[i])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},ti.apply(this,arguments)};function ei(t,e,i,r){for(var o,n=arguments.length,a=n<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,i):r,c=t.length-1;c>=0;c--)(o=t[c])&&(a=(n<3?o(a):n>3?o(e,i,a):o(e,i))||a);return n>3&&a&&Object.defineProperty(e,i,a),a}function ii(t){var e="function"==typeof Symbol&&Symbol.iterator,i=e&&t[e],r=0;if(i)return i.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}
|
|
272
|
-
/**
|
|
273
|
-
* @license
|
|
274
|
-
* Copyright 2018 Google Inc.
|
|
275
|
-
*
|
|
276
|
-
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
277
|
-
* of this software and associated documentation files (the "Software"), to deal
|
|
278
|
-
* in the Software without restriction, including without limitation the rights
|
|
279
|
-
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
280
|
-
* copies of the Software, and to permit persons to whom the Software is
|
|
281
|
-
* furnished to do so, subject to the following conditions:
|
|
282
|
-
*
|
|
283
|
-
* The above copyright notice and this permission notice shall be included in
|
|
284
|
-
* all copies or substantial portions of the Software.
|
|
285
|
-
*
|
|
286
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
287
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
288
|
-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
289
|
-
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
290
|
-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
291
|
-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
292
|
-
* THE SOFTWARE.
|
|
293
|
-
*/const ri=()=>{},oi={get passive(){return!1}};document.addEventListener("x",ri,oi),document.removeEventListener("x",ri);
|
|
294
|
-
/**
|
|
295
|
-
* @license
|
|
296
|
-
* Copyright 2018 Google LLC
|
|
297
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
298
|
-
*/
|
|
299
|
-
class ni extends ut{click(){if(this.mdcRoot)return this.mdcRoot.focus(),void this.mdcRoot.click();super.click()}createFoundation(){void 0!==this.mdcFoundation&&this.mdcFoundation.destroy(),this.mdcFoundationClass&&(this.mdcFoundation=new this.mdcFoundationClass(this.createAdapter()),this.mdcFoundation.init())}firstUpdated(){this.createFoundation()}}
|
|
300
|
-
/**
|
|
301
|
-
* @license
|
|
302
|
-
* Copyright 2016 Google Inc.
|
|
303
|
-
*
|
|
304
|
-
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
305
|
-
* of this software and associated documentation files (the "Software"), to deal
|
|
306
|
-
* in the Software without restriction, including without limitation the rights
|
|
307
|
-
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
308
|
-
* copies of the Software, and to permit persons to whom the Software is
|
|
309
|
-
* furnished to do so, subject to the following conditions:
|
|
310
|
-
*
|
|
311
|
-
* The above copyright notice and this permission notice shall be included in
|
|
312
|
-
* all copies or substantial portions of the Software.
|
|
313
|
-
*
|
|
314
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
315
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
316
|
-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
317
|
-
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
318
|
-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
319
|
-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
320
|
-
* THE SOFTWARE.
|
|
321
|
-
*/var ai=function(){function t(t){void 0===t&&(t={}),this.adapter=t}return Object.defineProperty(t,"cssClasses",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(t,"strings",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(t,"numbers",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{}},enumerable:!1,configurable:!0}),t.prototype.init=function(){},t.prototype.destroy=function(){},t}(),ci={BG_FOCUSED:"mdc-ripple-upgraded--background-focused",FG_ACTIVATION:"mdc-ripple-upgraded--foreground-activation",FG_DEACTIVATION:"mdc-ripple-upgraded--foreground-deactivation",ROOT:"mdc-ripple-upgraded",UNBOUNDED:"mdc-ripple-upgraded--unbounded"},si={VAR_FG_SCALE:"--mdc-ripple-fg-scale",VAR_FG_SIZE:"--mdc-ripple-fg-size",VAR_FG_TRANSLATE_END:"--mdc-ripple-fg-translate-end",VAR_FG_TRANSLATE_START:"--mdc-ripple-fg-translate-start",VAR_LEFT:"--mdc-ripple-left",VAR_TOP:"--mdc-ripple-top"},li={DEACTIVATION_TIMEOUT_MS:225,FG_DEACTIVATION_MS:150,INITIAL_ORIGIN_SCALE:.6,PADDING:10,TAP_DELAY_MS:300};
|
|
322
|
-
/**
|
|
323
|
-
* @license
|
|
324
|
-
* Copyright 2016 Google Inc.
|
|
325
|
-
*
|
|
326
|
-
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
327
|
-
* of this software and associated documentation files (the "Software"), to deal
|
|
328
|
-
* in the Software without restriction, including without limitation the rights
|
|
329
|
-
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
330
|
-
* copies of the Software, and to permit persons to whom the Software is
|
|
331
|
-
* furnished to do so, subject to the following conditions:
|
|
332
|
-
*
|
|
333
|
-
* The above copyright notice and this permission notice shall be included in
|
|
334
|
-
* all copies or substantial portions of the Software.
|
|
335
|
-
*
|
|
336
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
337
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
338
|
-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
339
|
-
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
340
|
-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
341
|
-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
342
|
-
* THE SOFTWARE.
|
|
343
|
-
*/
|
|
344
|
-
/**
|
|
345
|
-
* @license
|
|
346
|
-
* Copyright 2016 Google Inc.
|
|
347
|
-
*
|
|
348
|
-
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
349
|
-
* of this software and associated documentation files (the "Software"), to deal
|
|
350
|
-
* in the Software without restriction, including without limitation the rights
|
|
351
|
-
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
352
|
-
* copies of the Software, and to permit persons to whom the Software is
|
|
353
|
-
* furnished to do so, subject to the following conditions:
|
|
354
|
-
*
|
|
355
|
-
* The above copyright notice and this permission notice shall be included in
|
|
356
|
-
* all copies or substantial portions of the Software.
|
|
357
|
-
*
|
|
358
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
359
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
360
|
-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
361
|
-
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
362
|
-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
363
|
-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
364
|
-
* THE SOFTWARE.
|
|
365
|
-
*/
|
|
366
|
-
var di=["touchstart","pointerdown","mousedown","keydown"],hi=["touchend","pointerup","mouseup","contextmenu"],pi=[],fi=function(t){function e(i){var r=t.call(this,ti(ti({},e.defaultAdapter),i))||this;return r.activationAnimationHasEnded=!1,r.activationTimer=0,r.fgDeactivationRemovalTimer=0,r.fgScale="0",r.frame={width:0,height:0},r.initialSize=0,r.layoutFrame=0,r.maxRadius=0,r.unboundedCoords={left:0,top:0},r.activationState=r.defaultActivationState(),r.activationTimerCallback=function(){r.activationAnimationHasEnded=!0,r.runDeactivationUXLogicIfReady()},r.activateHandler=function(t){r.activateImpl(t)},r.deactivateHandler=function(){r.deactivateImpl()},r.focusHandler=function(){r.handleFocus()},r.blurHandler=function(){r.handleBlur()},r.resizeHandler=function(){r.layout()},r}return Qe(e,t),Object.defineProperty(e,"cssClasses",{get:function(){return ci},enumerable:!1,configurable:!0}),Object.defineProperty(e,"strings",{get:function(){return si},enumerable:!1,configurable:!0}),Object.defineProperty(e,"numbers",{get:function(){return li},enumerable:!1,configurable:!0}),Object.defineProperty(e,"defaultAdapter",{get:function(){return{addClass:function(){},browserSupportsCssVars:function(){return!0},computeBoundingRect:function(){return{top:0,right:0,bottom:0,left:0,width:0,height:0}},containsEventTarget:function(){return!0},deregisterDocumentInteractionHandler:function(){},deregisterInteractionHandler:function(){},deregisterResizeHandler:function(){},getWindowPageOffset:function(){return{x:0,y:0}},isSurfaceActive:function(){return!0},isSurfaceDisabled:function(){return!0},isUnbounded:function(){return!0},registerDocumentInteractionHandler:function(){},registerInteractionHandler:function(){},registerResizeHandler:function(){},removeClass:function(){},updateCssVariable:function(){}}},enumerable:!1,configurable:!0}),e.prototype.init=function(){var t=this,i=this.supportsPressRipple();if(this.registerRootHandlers(i),i){var r=e.cssClasses,o=r.ROOT,n=r.UNBOUNDED;requestAnimationFrame((function(){t.adapter.addClass(o),t.adapter.isUnbounded()&&(t.adapter.addClass(n),t.layoutInternal())}))}},e.prototype.destroy=function(){var t=this;if(this.supportsPressRipple()){this.activationTimer&&(clearTimeout(this.activationTimer),this.activationTimer=0,this.adapter.removeClass(e.cssClasses.FG_ACTIVATION)),this.fgDeactivationRemovalTimer&&(clearTimeout(this.fgDeactivationRemovalTimer),this.fgDeactivationRemovalTimer=0,this.adapter.removeClass(e.cssClasses.FG_DEACTIVATION));var i=e.cssClasses,r=i.ROOT,o=i.UNBOUNDED;requestAnimationFrame((function(){t.adapter.removeClass(r),t.adapter.removeClass(o),t.removeCssVars()}))}this.deregisterRootHandlers(),this.deregisterDeactivationHandlers()},e.prototype.activate=function(t){this.activateImpl(t)},e.prototype.deactivate=function(){this.deactivateImpl()},e.prototype.layout=function(){var t=this;this.layoutFrame&&cancelAnimationFrame(this.layoutFrame),this.layoutFrame=requestAnimationFrame((function(){t.layoutInternal(),t.layoutFrame=0}))},e.prototype.setUnbounded=function(t){var i=e.cssClasses.UNBOUNDED;t?this.adapter.addClass(i):this.adapter.removeClass(i)},e.prototype.handleFocus=function(){var t=this;requestAnimationFrame((function(){return t.adapter.addClass(e.cssClasses.BG_FOCUSED)}))},e.prototype.handleBlur=function(){var t=this;requestAnimationFrame((function(){return t.adapter.removeClass(e.cssClasses.BG_FOCUSED)}))},e.prototype.supportsPressRipple=function(){return this.adapter.browserSupportsCssVars()},e.prototype.defaultActivationState=function(){return{activationEvent:void 0,hasDeactivationUXRun:!1,isActivated:!1,isProgrammatic:!1,wasActivatedByPointer:!1,wasElementMadeActive:!1}},e.prototype.registerRootHandlers=function(t){var e,i;if(t){try{for(var r=ii(di),o=r.next();!o.done;o=r.next()){var n=o.value;this.adapter.registerInteractionHandler(n,this.activateHandler)}}catch(t){e={error:t}}finally{try{o&&!o.done&&(i=r.return)&&i.call(r)}finally{if(e)throw e.error}}this.adapter.isUnbounded()&&this.adapter.registerResizeHandler(this.resizeHandler)}this.adapter.registerInteractionHandler("focus",this.focusHandler),this.adapter.registerInteractionHandler("blur",this.blurHandler)},e.prototype.registerDeactivationHandlers=function(t){var e,i;if("keydown"===t.type)this.adapter.registerInteractionHandler("keyup",this.deactivateHandler);else try{for(var r=ii(hi),o=r.next();!o.done;o=r.next()){var n=o.value;this.adapter.registerDocumentInteractionHandler(n,this.deactivateHandler)}}catch(t){e={error:t}}finally{try{o&&!o.done&&(i=r.return)&&i.call(r)}finally{if(e)throw e.error}}},e.prototype.deregisterRootHandlers=function(){var t,e;try{for(var i=ii(di),r=i.next();!r.done;r=i.next()){var o=r.value;this.adapter.deregisterInteractionHandler(o,this.activateHandler)}}catch(e){t={error:e}}finally{try{r&&!r.done&&(e=i.return)&&e.call(i)}finally{if(t)throw t.error}}this.adapter.deregisterInteractionHandler("focus",this.focusHandler),this.adapter.deregisterInteractionHandler("blur",this.blurHandler),this.adapter.isUnbounded()&&this.adapter.deregisterResizeHandler(this.resizeHandler)},e.prototype.deregisterDeactivationHandlers=function(){var t,e;this.adapter.deregisterInteractionHandler("keyup",this.deactivateHandler);try{for(var i=ii(hi),r=i.next();!r.done;r=i.next()){var o=r.value;this.adapter.deregisterDocumentInteractionHandler(o,this.deactivateHandler)}}catch(e){t={error:e}}finally{try{r&&!r.done&&(e=i.return)&&e.call(i)}finally{if(t)throw t.error}}},e.prototype.removeCssVars=function(){var t=this,i=e.strings;Object.keys(i).forEach((function(e){0===e.indexOf("VAR_")&&t.adapter.updateCssVariable(i[e],null)}))},e.prototype.activateImpl=function(t){var e=this;if(!this.adapter.isSurfaceDisabled()){var i=this.activationState;if(!i.isActivated){var r=this.previousActivationEvent;if(!(r&&void 0!==t&&r.type!==t.type))i.isActivated=!0,i.isProgrammatic=void 0===t,i.activationEvent=t,i.wasActivatedByPointer=!i.isProgrammatic&&(void 0!==t&&("mousedown"===t.type||"touchstart"===t.type||"pointerdown"===t.type)),void 0!==t&&pi.length>0&&pi.some((function(t){return e.adapter.containsEventTarget(t)}))?this.resetActivationState():(void 0!==t&&(pi.push(t.target),this.registerDeactivationHandlers(t)),i.wasElementMadeActive=this.checkElementMadeActive(t),i.wasElementMadeActive&&this.animateActivation(),requestAnimationFrame((function(){pi=[],i.wasElementMadeActive||void 0===t||" "!==t.key&&32!==t.keyCode||(i.wasElementMadeActive=e.checkElementMadeActive(t),i.wasElementMadeActive&&e.animateActivation()),i.wasElementMadeActive||(e.activationState=e.defaultActivationState())})))}}},e.prototype.checkElementMadeActive=function(t){return void 0===t||"keydown"!==t.type||this.adapter.isSurfaceActive()},e.prototype.animateActivation=function(){var t=this,i=e.strings,r=i.VAR_FG_TRANSLATE_START,o=i.VAR_FG_TRANSLATE_END,n=e.cssClasses,a=n.FG_DEACTIVATION,c=n.FG_ACTIVATION,s=e.numbers.DEACTIVATION_TIMEOUT_MS;this.layoutInternal();var l="",d="";if(!this.adapter.isUnbounded()){var h=this.getFgTranslationCoordinates(),p=h.startPoint,f=h.endPoint;l=p.x+"px, "+p.y+"px",d=f.x+"px, "+f.y+"px"}this.adapter.updateCssVariable(r,l),this.adapter.updateCssVariable(o,d),clearTimeout(this.activationTimer),clearTimeout(this.fgDeactivationRemovalTimer),this.rmBoundedActivationClasses(),this.adapter.removeClass(a),this.adapter.computeBoundingRect(),this.adapter.addClass(c),this.activationTimer=setTimeout((function(){t.activationTimerCallback()}),s)},e.prototype.getFgTranslationCoordinates=function(){var t,e=this.activationState,i=e.activationEvent;return t=e.wasActivatedByPointer?function(t,e,i){if(!t)return{x:0,y:0};var r,o,n=e.x,a=e.y,c=n+i.left,s=a+i.top;if("touchstart"===t.type){var l=t;r=l.changedTouches[0].pageX-c,o=l.changedTouches[0].pageY-s}else{var d=t;r=d.pageX-c,o=d.pageY-s}return{x:r,y:o}}(i,this.adapter.getWindowPageOffset(),this.adapter.computeBoundingRect()):{x:this.frame.width/2,y:this.frame.height/2},{startPoint:t={x:t.x-this.initialSize/2,y:t.y-this.initialSize/2},endPoint:{x:this.frame.width/2-this.initialSize/2,y:this.frame.height/2-this.initialSize/2}}},e.prototype.runDeactivationUXLogicIfReady=function(){var t=this,i=e.cssClasses.FG_DEACTIVATION,r=this.activationState,o=r.hasDeactivationUXRun,n=r.isActivated;(o||!n)&&this.activationAnimationHasEnded&&(this.rmBoundedActivationClasses(),this.adapter.addClass(i),this.fgDeactivationRemovalTimer=setTimeout((function(){t.adapter.removeClass(i)}),li.FG_DEACTIVATION_MS))},e.prototype.rmBoundedActivationClasses=function(){var t=e.cssClasses.FG_ACTIVATION;this.adapter.removeClass(t),this.activationAnimationHasEnded=!1,this.adapter.computeBoundingRect()},e.prototype.resetActivationState=function(){var t=this;this.previousActivationEvent=this.activationState.activationEvent,this.activationState=this.defaultActivationState(),setTimeout((function(){return t.previousActivationEvent=void 0}),e.numbers.TAP_DELAY_MS)},e.prototype.deactivateImpl=function(){var t=this,e=this.activationState;if(e.isActivated){var i=ti({},e);e.isProgrammatic?(requestAnimationFrame((function(){t.animateDeactivation(i)})),this.resetActivationState()):(this.deregisterDeactivationHandlers(),requestAnimationFrame((function(){t.activationState.hasDeactivationUXRun=!0,t.animateDeactivation(i),t.resetActivationState()})))}},e.prototype.animateDeactivation=function(t){var e=t.wasActivatedByPointer,i=t.wasElementMadeActive;(e||i)&&this.runDeactivationUXLogicIfReady()},e.prototype.layoutInternal=function(){var t=this;this.frame=this.adapter.computeBoundingRect();var i=Math.max(this.frame.height,this.frame.width);this.maxRadius=this.adapter.isUnbounded()?i:Math.sqrt(Math.pow(t.frame.width,2)+Math.pow(t.frame.height,2))+e.numbers.PADDING;var r=Math.floor(i*e.numbers.INITIAL_ORIGIN_SCALE);this.adapter.isUnbounded()&&r%2!=0?this.initialSize=r-1:this.initialSize=r,this.fgScale=""+this.maxRadius/this.initialSize,this.updateLayoutCssVars()},e.prototype.updateLayoutCssVars=function(){var t=e.strings,i=t.VAR_FG_SIZE,r=t.VAR_LEFT,o=t.VAR_TOP,n=t.VAR_FG_SCALE;this.adapter.updateCssVariable(i,this.initialSize+"px"),this.adapter.updateCssVariable(n,this.fgScale),this.adapter.isUnbounded()&&(this.unboundedCoords={left:Math.round(this.frame.width/2-this.initialSize/2),top:Math.round(this.frame.height/2-this.initialSize/2)},this.adapter.updateCssVariable(r,this.unboundedCoords.left+"px"),this.adapter.updateCssVariable(o,this.unboundedCoords.top+"px"))},e}(ai),ui=fi;
|
|
367
|
-
/**
|
|
368
|
-
* @license
|
|
369
|
-
* Copyright 2018 Google LLC
|
|
370
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
371
|
-
*/
|
|
372
|
-
const mi=Ct(class extends Et{constructor(t){var e;if(super(t),t.type!==Ot||"style"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(t){return Object.keys(t).reduce(((e,i)=>{const r=t[i];return null==r?e:e+`${i=i.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${r};`}),"")}update(t,[e]){const{style:i}=t.element;if(void 0===this.ct){this.ct=new Set;for(const t in e)this.ct.add(t);return this.render(e)}this.ct.forEach((t=>{null==e[t]&&(this.ct.delete(t),t.includes("-")?i.removeProperty(t):i[t]="")}));for(const t in e){const r=e[t];null!=r&&(this.ct.add(t),t.includes("-")?i.setProperty(t,r):i[t]=r)}return G}});
|
|
373
|
-
/**
|
|
374
|
-
* @license
|
|
375
|
-
* Copyright 2018 Google LLC
|
|
376
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
377
|
-
*/class bi extends ni{constructor(){super(...arguments),this.primary=!1,this.accent=!1,this.unbounded=!1,this.disabled=!1,this.activated=!1,this.selected=!1,this.internalUseStateLayerCustomProperties=!1,this.hovering=!1,this.bgFocused=!1,this.fgActivation=!1,this.fgDeactivation=!1,this.fgScale="",this.fgSize="",this.translateStart="",this.translateEnd="",this.leftPos="",this.topPos="",this.mdcFoundationClass=ui}get isActive(){return t=this.parentElement||this,e=":active",(t.matches||t.webkitMatchesSelector||t.msMatchesSelector).call(t,e);var t,e;
|
|
378
|
-
/**
|
|
379
|
-
* @license
|
|
380
|
-
* Copyright 2018 Google LLC
|
|
381
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
382
|
-
*/}createAdapter(){return{browserSupportsCssVars:()=>!0,isUnbounded:()=>this.unbounded,isSurfaceActive:()=>this.isActive,isSurfaceDisabled:()=>this.disabled,addClass:t=>{switch(t){case"mdc-ripple-upgraded--background-focused":this.bgFocused=!0;break;case"mdc-ripple-upgraded--foreground-activation":this.fgActivation=!0;break;case"mdc-ripple-upgraded--foreground-deactivation":this.fgDeactivation=!0}},removeClass:t=>{switch(t){case"mdc-ripple-upgraded--background-focused":this.bgFocused=!1;break;case"mdc-ripple-upgraded--foreground-activation":this.fgActivation=!1;break;case"mdc-ripple-upgraded--foreground-deactivation":this.fgDeactivation=!1}},containsEventTarget:()=>!0,registerInteractionHandler:()=>{},deregisterInteractionHandler:()=>{},registerDocumentInteractionHandler:()=>{},deregisterDocumentInteractionHandler:()=>{},registerResizeHandler:()=>{},deregisterResizeHandler:()=>{},updateCssVariable:(t,e)=>{switch(t){case"--mdc-ripple-fg-scale":this.fgScale=e;break;case"--mdc-ripple-fg-size":this.fgSize=e;break;case"--mdc-ripple-fg-translate-end":this.translateEnd=e;break;case"--mdc-ripple-fg-translate-start":this.translateStart=e;break;case"--mdc-ripple-left":this.leftPos=e;break;case"--mdc-ripple-top":this.topPos=e}},computeBoundingRect:()=>(this.parentElement||this).getBoundingClientRect(),getWindowPageOffset:()=>({x:window.pageXOffset,y:window.pageYOffset})}}startPress(t){this.waitForFoundation((()=>{this.mdcFoundation.activate(t)}))}endPress(){this.waitForFoundation((()=>{this.mdcFoundation.deactivate()}))}startFocus(){this.waitForFoundation((()=>{this.mdcFoundation.handleFocus()}))}endFocus(){this.waitForFoundation((()=>{this.mdcFoundation.handleBlur()}))}startHover(){this.hovering=!0}endHover(){this.hovering=!1}waitForFoundation(t){this.mdcFoundation?t():this.updateComplete.then(t)}update(t){t.has("disabled")&&this.disabled&&this.endHover(),super.update(t)}render(){const t=this.activated&&(this.primary||!this.accent),e=this.selected&&(this.primary||!this.accent),i={"mdc-ripple-surface--accent":this.accent,"mdc-ripple-surface--primary--activated":t,"mdc-ripple-surface--accent--activated":this.accent&&this.activated,"mdc-ripple-surface--primary--selected":e,"mdc-ripple-surface--accent--selected":this.accent&&this.selected,"mdc-ripple-surface--disabled":this.disabled,"mdc-ripple-surface--hover":this.hovering,"mdc-ripple-surface--primary":this.primary,"mdc-ripple-surface--selected":this.selected,"mdc-ripple-upgraded--background-focused":this.bgFocused,"mdc-ripple-upgraded--foreground-activation":this.fgActivation,"mdc-ripple-upgraded--foreground-deactivation":this.fgDeactivation,"mdc-ripple-upgraded--unbounded":this.unbounded,"mdc-ripple-surface--internal-use-state-layer-custom-properties":this.internalUseStateLayerCustomProperties};return q`
|
|
383
|
-
<div class="mdc-ripple-surface mdc-ripple-upgraded ${Dt(i)}"
|
|
384
|
-
style="${mi({"--mdc-ripple-fg-scale":this.fgScale,"--mdc-ripple-fg-size":this.fgSize,"--mdc-ripple-fg-translate-end":this.translateEnd,"--mdc-ripple-fg-translate-start":this.translateStart,"--mdc-ripple-left":this.leftPos,"--mdc-ripple-top":this.topPos})}"></div>`}}ei([c(".mdc-ripple-surface")],bi.prototype,"mdcRoot",void 0),ei([r({type:Boolean})],bi.prototype,"primary",void 0),ei([r({type:Boolean})],bi.prototype,"accent",void 0),ei([r({type:Boolean})],bi.prototype,"unbounded",void 0),ei([r({type:Boolean})],bi.prototype,"disabled",void 0),ei([r({type:Boolean})],bi.prototype,"activated",void 0),ei([r({type:Boolean})],bi.prototype,"selected",void 0),ei([r({type:Boolean})],bi.prototype,"internalUseStateLayerCustomProperties",void 0),ei([o()],bi.prototype,"hovering",void 0),ei([o()],bi.prototype,"bgFocused",void 0),ei([o()],bi.prototype,"fgActivation",void 0),ei([o()],bi.prototype,"fgDeactivation",void 0),ei([o()],bi.prototype,"fgScale",void 0),ei([o()],bi.prototype,"fgSize",void 0),ei([o()],bi.prototype,"translateStart",void 0),ei([o()],bi.prototype,"translateEnd",void 0),ei([o()],bi.prototype,"leftPos",void 0),ei([o()],bi.prototype,"topPos",void 0);
|
|
385
|
-
/**
|
|
386
|
-
* @license
|
|
387
|
-
* Copyright 2021 Google LLC
|
|
388
|
-
* SPDX-LIcense-Identifier: Apache-2.0
|
|
389
|
-
*/
|
|
390
|
-
const vi=x`.mdc-ripple-surface{--mdc-ripple-fg-size: 0;--mdc-ripple-left: 0;--mdc-ripple-top: 0;--mdc-ripple-fg-scale: 1;--mdc-ripple-fg-translate-end: 0;--mdc-ripple-fg-translate-start: 0;-webkit-tap-highlight-color:rgba(0,0,0,0);will-change:transform,opacity;position:relative;outline:none;overflow:hidden}.mdc-ripple-surface::before,.mdc-ripple-surface::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.mdc-ripple-surface::before{transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-ripple-surface::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-ripple-surface.mdc-ripple-upgraded::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-ripple-surface.mdc-ripple-upgraded::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-ripple-surface.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-activation::after{animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-deactivation::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-ripple-surface::before,.mdc-ripple-surface::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-ripple-surface.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded],.mdc-ripple-upgraded--unbounded{overflow:visible}.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::before,.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::after,.mdc-ripple-upgraded--unbounded::before,.mdc-ripple-upgraded--unbounded::after{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::before,.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::before,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after{top:var(--mdc-ripple-top, calc(50% - 50%));left:var(--mdc-ripple-left, calc(50% - 50%));width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-ripple-surface::before,.mdc-ripple-surface::after{background-color:#000;background-color:var(--mdc-ripple-color, #000)}.mdc-ripple-surface:hover::before,.mdc-ripple-surface.mdc-ripple-surface--hover::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-ripple-surface.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-ripple-surface:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-ripple-surface.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}:host{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none;display:block}:host .mdc-ripple-surface{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none;will-change:unset}.mdc-ripple-surface--primary::before,.mdc-ripple-surface--primary::after{background-color:#6200ee;background-color:var(--mdc-ripple-color, var(--mdc-theme-primary, #6200ee))}.mdc-ripple-surface--primary:hover::before,.mdc-ripple-surface--primary.mdc-ripple-surface--hover::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-ripple-surface--primary.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface--primary:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-ripple-surface--primary:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface--primary:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-ripple-surface--primary.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-ripple-surface--primary--activated::before{opacity:0.12;opacity:var(--mdc-ripple-activated-opacity, 0.12)}.mdc-ripple-surface--primary--activated::before,.mdc-ripple-surface--primary--activated::after{background-color:#6200ee;background-color:var(--mdc-ripple-color, var(--mdc-theme-primary, #6200ee))}.mdc-ripple-surface--primary--activated:hover::before,.mdc-ripple-surface--primary--activated.mdc-ripple-surface--hover::before{opacity:0.16;opacity:var(--mdc-ripple-hover-opacity, 0.16)}.mdc-ripple-surface--primary--activated.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface--primary--activated:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-focus-opacity, 0.24)}.mdc-ripple-surface--primary--activated:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface--primary--activated:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-ripple-surface--primary--activated.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-ripple-surface--primary--selected::before{opacity:0.08;opacity:var(--mdc-ripple-selected-opacity, 0.08)}.mdc-ripple-surface--primary--selected::before,.mdc-ripple-surface--primary--selected::after{background-color:#6200ee;background-color:var(--mdc-ripple-color, var(--mdc-theme-primary, #6200ee))}.mdc-ripple-surface--primary--selected:hover::before,.mdc-ripple-surface--primary--selected.mdc-ripple-surface--hover::before{opacity:0.12;opacity:var(--mdc-ripple-hover-opacity, 0.12)}.mdc-ripple-surface--primary--selected.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface--primary--selected:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.2;opacity:var(--mdc-ripple-focus-opacity, 0.2)}.mdc-ripple-surface--primary--selected:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface--primary--selected:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.2;opacity:var(--mdc-ripple-press-opacity, 0.2)}.mdc-ripple-surface--primary--selected.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.2)}.mdc-ripple-surface--accent::before,.mdc-ripple-surface--accent::after{background-color:#018786;background-color:var(--mdc-ripple-color, var(--mdc-theme-secondary, #018786))}.mdc-ripple-surface--accent:hover::before,.mdc-ripple-surface--accent.mdc-ripple-surface--hover::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-ripple-surface--accent.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface--accent:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-ripple-surface--accent:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface--accent:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-ripple-surface--accent.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-ripple-surface--accent--activated::before{opacity:0.12;opacity:var(--mdc-ripple-activated-opacity, 0.12)}.mdc-ripple-surface--accent--activated::before,.mdc-ripple-surface--accent--activated::after{background-color:#018786;background-color:var(--mdc-ripple-color, var(--mdc-theme-secondary, #018786))}.mdc-ripple-surface--accent--activated:hover::before,.mdc-ripple-surface--accent--activated.mdc-ripple-surface--hover::before{opacity:0.16;opacity:var(--mdc-ripple-hover-opacity, 0.16)}.mdc-ripple-surface--accent--activated.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface--accent--activated:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-focus-opacity, 0.24)}.mdc-ripple-surface--accent--activated:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface--accent--activated:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-ripple-surface--accent--activated.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-ripple-surface--accent--selected::before{opacity:0.08;opacity:var(--mdc-ripple-selected-opacity, 0.08)}.mdc-ripple-surface--accent--selected::before,.mdc-ripple-surface--accent--selected::after{background-color:#018786;background-color:var(--mdc-ripple-color, var(--mdc-theme-secondary, #018786))}.mdc-ripple-surface--accent--selected:hover::before,.mdc-ripple-surface--accent--selected.mdc-ripple-surface--hover::before{opacity:0.12;opacity:var(--mdc-ripple-hover-opacity, 0.12)}.mdc-ripple-surface--accent--selected.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface--accent--selected:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.2;opacity:var(--mdc-ripple-focus-opacity, 0.2)}.mdc-ripple-surface--accent--selected:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface--accent--selected:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.2;opacity:var(--mdc-ripple-press-opacity, 0.2)}.mdc-ripple-surface--accent--selected.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.2)}.mdc-ripple-surface--disabled{opacity:0}.mdc-ripple-surface--internal-use-state-layer-custom-properties::before,.mdc-ripple-surface--internal-use-state-layer-custom-properties::after{background-color:#000;background-color:var(--mdc-ripple-hover-state-layer-color, #000)}.mdc-ripple-surface--internal-use-state-layer-custom-properties:hover::before,.mdc-ripple-surface--internal-use-state-layer-custom-properties.mdc-ripple-surface--hover::before{opacity:0.04;opacity:var(--mdc-ripple-hover-state-layer-opacity, 0.04)}.mdc-ripple-surface--internal-use-state-layer-custom-properties.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface--internal-use-state-layer-custom-properties:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-state-layer-opacity, 0.12)}.mdc-ripple-surface--internal-use-state-layer-custom-properties:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface--internal-use-state-layer-custom-properties:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-pressed-state-layer-opacity, 0.12)}.mdc-ripple-surface--internal-use-state-layer-custom-properties.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-pressed-state-layer-opacity, 0.12)}`
|
|
391
|
-
/**
|
|
392
|
-
* @license
|
|
393
|
-
* Copyright 2018 Google LLC
|
|
394
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
395
|
-
*/;let gi=class extends bi{};function xi(t,e,i){if(void 0!==e)
|
|
396
|
-
/**
|
|
397
|
-
* @license
|
|
398
|
-
* Copyright 2021 Google LLC
|
|
399
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
400
|
-
*/
|
|
401
|
-
return function(t,e,i){const r=t.constructor;if(!i){const t=`__${e}`;if(!(i=r.getPropertyDescriptor(e,t)))throw new Error("@ariaProperty must be used after a @property decorator")}const o=i;let n="";if(!o.set)throw new Error(`@ariaProperty requires a setter for ${e}`);if(t.dispatchWizEvent)return i;const a={configurable:!0,enumerable:!0,set(t){if(""===n){const t=r.getPropertyOptions(e);n="string"==typeof t.attribute?t.attribute:e}this.hasAttribute(n)&&this.removeAttribute(n),o.set.call(this,t)}};return o.get&&(a.get=function(){return o.get.call(this)}),a}(t,e,i);throw new Error("@ariaProperty only supports TypeScript Decorators")}
|
|
402
|
-
/**
|
|
403
|
-
* @license
|
|
404
|
-
* Copyright 2018 Google LLC
|
|
405
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
406
|
-
*/var yi,ki;gi.styles=[vi],gi=ei([e("mwc-ripple")],gi);const wi=null!==(ki=null===(yi=window.ShadyDOM)||void 0===yi?void 0:yi.inUse)&&void 0!==ki&&ki;class $i extends ni{constructor(){super(...arguments),this.disabled=!1,this.containingForm=null,this.formDataListener=t=>{this.disabled||this.setFormData(t.formData)}}findFormElement(){if(!this.shadowRoot||wi)return null;const t=this.getRootNode().querySelectorAll("form");for(const e of Array.from(t))if(e.contains(this))return e;return null}connectedCallback(){var t;super.connectedCallback(),this.containingForm=this.findFormElement(),null===(t=this.containingForm)||void 0===t||t.addEventListener("formdata",this.formDataListener)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this.containingForm)||void 0===t||t.removeEventListener("formdata",this.formDataListener),this.containingForm=null}click(){this.formElement&&!this.disabled&&(this.formElement.focus(),this.formElement.click())}firstUpdated(){super.firstUpdated(),this.shadowRoot&&this.mdcRoot.addEventListener("change",(t=>{this.dispatchEvent(new Event("change",t))}))}}$i.shadowRootOptions={mode:"open",delegatesFocus:!0},ei([r({type:Boolean})],$i.prototype,"disabled",void 0);
|
|
407
|
-
/**
|
|
408
|
-
* @license
|
|
409
|
-
* Copyright 2020 Google LLC
|
|
410
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
411
|
-
*/
|
|
412
|
-
class _i{constructor(t){this.startPress=e=>{t().then((t=>{t&&t.startPress(e)}))},this.endPress=()=>{t().then((t=>{t&&t.endPress()}))},this.startFocus=()=>{t().then((t=>{t&&t.startFocus()}))},this.endFocus=()=>{t().then((t=>{t&&t.endFocus()}))},this.startHover=()=>{t().then((t=>{t&&t.startHover()}))},this.endHover=()=>{t().then((t=>{t&&t.endHover()}))}}}
|
|
413
|
-
/**
|
|
414
|
-
* @license
|
|
415
|
-
* Copyright 2018 Google LLC
|
|
416
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
417
|
-
*/const Si=t=>null!=t?t:X
|
|
418
|
-
/**
|
|
419
|
-
* @license
|
|
420
|
-
* Copyright 2019 Google LLC
|
|
421
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
422
|
-
*/;class Oi extends $i{constructor(){super(...arguments),this.checked=!1,this.indeterminate=!1,this.disabled=!1,this.name="",this.value="on",this.reducedTouchTarget=!1,this.animationClass="",this.shouldRenderRipple=!1,this.focused=!1,this.mdcFoundationClass=void 0,this.mdcFoundation=void 0,this.rippleElement=null,this.rippleHandlers=new _i((()=>(this.shouldRenderRipple=!0,this.ripple.then((t=>this.rippleElement=t)),this.ripple)))}createAdapter(){return{}}update(t){const e=t.get("indeterminate"),i=t.get("checked"),r=t.get("disabled");if(void 0!==e||void 0!==i||void 0!==r){const t=this.calculateAnimationStateName(!!i,!!e,!!r),o=this.calculateAnimationStateName(this.checked,this.indeterminate,this.disabled);this.animationClass=`${t}-${o}`}super.update(t)}calculateAnimationStateName(t,e,i){return i?"disabled":e?"indeterminate":t?"checked":"unchecked"}renderRipple(){return this.shouldRenderRipple?this.renderRippleTemplate():""}renderRippleTemplate(){return q`<mwc-ripple
|
|
423
|
-
.disabled="${this.disabled}"
|
|
424
|
-
unbounded></mwc-ripple>`}render(){const t=this.indeterminate||this.checked,e={"mdc-checkbox--disabled":this.disabled,"mdc-checkbox--selected":t,"mdc-checkbox--touch":!this.reducedTouchTarget,"mdc-ripple-upgraded--background-focused":this.focused,"mdc-checkbox--anim-checked-indeterminate":"checked-indeterminate"==this.animationClass,"mdc-checkbox--anim-checked-unchecked":"checked-unchecked"==this.animationClass,"mdc-checkbox--anim-indeterminate-checked":"indeterminate-checked"==this.animationClass,"mdc-checkbox--anim-indeterminate-unchecked":"indeterminate-unchecked"==this.animationClass,"mdc-checkbox--anim-unchecked-checked":"unchecked-checked"==this.animationClass,"mdc-checkbox--anim-unchecked-indeterminate":"unchecked-indeterminate"==this.animationClass},i=this.indeterminate?"mixed":void 0;return q`
|
|
425
|
-
<div class="mdc-checkbox mdc-checkbox--upgraded ${Dt(e)}">
|
|
426
|
-
<input type="checkbox"
|
|
427
|
-
class="mdc-checkbox__native-control"
|
|
428
|
-
name="${Si(this.name)}"
|
|
429
|
-
aria-checked="${Si(i)}"
|
|
430
|
-
aria-label="${Si(this.ariaLabel)}"
|
|
431
|
-
aria-labelledby="${Si(this.ariaLabelledBy)}"
|
|
432
|
-
aria-describedby="${Si(this.ariaDescribedBy)}"
|
|
433
|
-
data-indeterminate="${this.indeterminate?"true":"false"}"
|
|
434
|
-
?disabled="${this.disabled}"
|
|
435
|
-
.indeterminate="${this.indeterminate}"
|
|
436
|
-
.checked="${this.checked}"
|
|
437
|
-
.value="${this.value}"
|
|
438
|
-
@change="${this.handleChange}"
|
|
439
|
-
@focus="${this.handleFocus}"
|
|
440
|
-
@blur="${this.handleBlur}"
|
|
441
|
-
@mousedown="${this.handleRippleMouseDown}"
|
|
442
|
-
@mouseenter="${this.handleRippleMouseEnter}"
|
|
443
|
-
@mouseleave="${this.handleRippleMouseLeave}"
|
|
444
|
-
@touchstart="${this.handleRippleTouchStart}"
|
|
445
|
-
@touchend="${this.handleRippleDeactivate}"
|
|
446
|
-
@touchcancel="${this.handleRippleDeactivate}">
|
|
447
|
-
<div class="mdc-checkbox__background"
|
|
448
|
-
@animationend="${this.resetAnimationClass}">
|
|
449
|
-
<svg class="mdc-checkbox__checkmark"
|
|
450
|
-
viewBox="0 0 24 24">
|
|
451
|
-
<path class="mdc-checkbox__checkmark-path"
|
|
452
|
-
fill="none"
|
|
453
|
-
d="M1.73,12.91 8.1,19.28 22.79,4.59"></path>
|
|
454
|
-
</svg>
|
|
455
|
-
<div class="mdc-checkbox__mixedmark"></div>
|
|
456
|
-
</div>
|
|
457
|
-
${this.renderRipple()}
|
|
458
|
-
</div>`}setFormData(t){this.name&&this.checked&&t.append(this.name,this.value)}handleFocus(){this.focused=!0,this.handleRippleFocus()}handleBlur(){this.focused=!1,this.handleRippleBlur()}handleRippleMouseDown(t){const e=()=>{window.removeEventListener("mouseup",e),this.handleRippleDeactivate()};window.addEventListener("mouseup",e),this.rippleHandlers.startPress(t)}handleRippleTouchStart(t){this.rippleHandlers.startPress(t)}handleRippleDeactivate(){this.rippleHandlers.endPress()}handleRippleMouseEnter(){this.rippleHandlers.startHover()}handleRippleMouseLeave(){this.rippleHandlers.endHover()}handleRippleFocus(){this.rippleHandlers.startFocus()}handleRippleBlur(){this.rippleHandlers.endFocus()}handleChange(){this.checked=this.formElement.checked,this.indeterminate=this.formElement.indeterminate}resetAnimationClass(){this.animationClass=""}get isRippleActive(){var t;return(null===(t=this.rippleElement)||void 0===t?void 0:t.isActive)||!1}}ei([c(".mdc-checkbox")],Oi.prototype,"mdcRoot",void 0),ei([c("input")],Oi.prototype,"formElement",void 0),ei([r({type:Boolean,reflect:!0})],Oi.prototype,"checked",void 0),ei([r({type:Boolean})],Oi.prototype,"indeterminate",void 0),ei([r({type:Boolean,reflect:!0})],Oi.prototype,"disabled",void 0),ei([r({type:String,reflect:!0})],Oi.prototype,"name",void 0),ei([r({type:String})],Oi.prototype,"value",void 0),ei([xi,r({type:String,attribute:"aria-label"})],Oi.prototype,"ariaLabel",void 0),ei([xi,r({type:String,attribute:"aria-labelledby"})],Oi.prototype,"ariaLabelledBy",void 0),ei([xi,r({type:String,attribute:"aria-describedby"})],Oi.prototype,"ariaDescribedBy",void 0),ei([r({type:Boolean})],Oi.prototype,"reducedTouchTarget",void 0),ei([o()],Oi.prototype,"animationClass",void 0),ei([o()],Oi.prototype,"shouldRenderRipple",void 0),ei([o()],Oi.prototype,"focused",void 0),ei([s("mwc-ripple")],Oi.prototype,"ripple",void 0),ei([a({passive:!0})],Oi.prototype,"handleRippleTouchStart",null);
|
|
459
|
-
/**
|
|
460
|
-
* @license
|
|
461
|
-
* Copyright 2021 Google LLC
|
|
462
|
-
* SPDX-LIcense-Identifier: Apache-2.0
|
|
463
|
-
*/
|
|
464
|
-
const zi=x`.mdc-checkbox{padding:calc((40px - 18px) / 2);padding:calc((var(--mdc-checkbox-ripple-size, 40px) - 18px) / 2);margin:calc((40px - 40px) / 2);margin:calc((var(--mdc-checkbox-touch-target-size, 40px) - 40px) / 2)}.mdc-checkbox .mdc-checkbox__ripple::before,.mdc-checkbox .mdc-checkbox__ripple::after{background-color:#000;background-color:var(--mdc-ripple-color, #000)}.mdc-checkbox:hover .mdc-checkbox__ripple::before,.mdc-checkbox.mdc-ripple-surface--hover .mdc-checkbox__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__ripple::before,.mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-checkbox:not(.mdc-ripple-upgraded) .mdc-checkbox__ripple::after{transition:opacity 150ms linear}.mdc-checkbox:not(.mdc-ripple-upgraded):active .mdc-checkbox__ripple::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-checkbox.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-checkbox.mdc-checkbox--selected .mdc-checkbox__ripple::before,.mdc-checkbox.mdc-checkbox--selected .mdc-checkbox__ripple::after{background-color:#018786;background-color:var(--mdc-ripple-color, var(--mdc-theme-secondary, #018786))}.mdc-checkbox.mdc-checkbox--selected:hover .mdc-checkbox__ripple::before,.mdc-checkbox.mdc-checkbox--selected.mdc-ripple-surface--hover .mdc-checkbox__ripple::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-checkbox.mdc-checkbox--selected.mdc-ripple-upgraded--background-focused .mdc-checkbox__ripple::before,.mdc-checkbox.mdc-checkbox--selected:not(.mdc-ripple-upgraded):focus .mdc-checkbox__ripple::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-checkbox.mdc-checkbox--selected:not(.mdc-ripple-upgraded) .mdc-checkbox__ripple::after{transition:opacity 150ms linear}.mdc-checkbox.mdc-checkbox--selected:not(.mdc-ripple-upgraded):active .mdc-checkbox__ripple::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-checkbox.mdc-checkbox--selected.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--selected .mdc-checkbox__ripple::before,.mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--selected .mdc-checkbox__ripple::after{background-color:#018786;background-color:var(--mdc-ripple-color, var(--mdc-theme-secondary, #018786))}.mdc-checkbox .mdc-checkbox__background{top:calc((40px - 18px) / 2);top:calc((var(--mdc-checkbox-ripple-size, 40px) - 18px) / 2);left:calc((40px - 18px) / 2);left:calc((var(--mdc-checkbox-ripple-size, 40px) - 18px) / 2)}.mdc-checkbox .mdc-checkbox__native-control{top:calc((40px - 40px) / 2);top:calc((40px - var(--mdc-checkbox-touch-target-size, 40px)) / 2);right:calc((40px - 40px) / 2);right:calc((40px - var(--mdc-checkbox-touch-target-size, 40px)) / 2);left:calc((40px - 40px) / 2);left:calc((40px - var(--mdc-checkbox-touch-target-size, 40px)) / 2);width:40px;width:var(--mdc-checkbox-touch-target-size, 40px);height:40px;height:var(--mdc-checkbox-touch-target-size, 40px)}.mdc-checkbox .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:rgba(0, 0, 0, 0.54);border-color:var(--mdc-checkbox-unchecked-color, rgba(0, 0, 0, 0.54));background-color:transparent}.mdc-checkbox .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mdc-checkbox .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mdc-checkbox .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background{border-color:#018786;border-color:var(--mdc-checkbox-checked-color, var(--mdc-theme-secondary, #018786));background-color:#018786;background-color:var(--mdc-checkbox-checked-color, var(--mdc-theme-secondary, #018786))}@keyframes mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786{0%{border-color:rgba(0, 0, 0, 0.54);border-color:var(--mdc-checkbox-unchecked-color, rgba(0, 0, 0, 0.54));background-color:transparent}50%{border-color:#018786;border-color:var(--mdc-checkbox-checked-color, var(--mdc-theme-secondary, #018786));background-color:#018786;background-color:var(--mdc-checkbox-checked-color, var(--mdc-theme-secondary, #018786))}}@keyframes mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786{0%,80%{border-color:#018786;border-color:var(--mdc-checkbox-checked-color, var(--mdc-theme-secondary, #018786));background-color:#018786;background-color:var(--mdc-checkbox-checked-color, var(--mdc-theme-secondary, #018786))}100%{border-color:rgba(0, 0, 0, 0.54);border-color:var(--mdc-checkbox-unchecked-color, rgba(0, 0, 0, 0.54));background-color:transparent}}.mdc-checkbox.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mdc-checkbox.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786}.mdc-checkbox.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mdc-checkbox.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786}.mdc-checkbox .mdc-checkbox__native-control[disabled]:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:rgba(0, 0, 0, 0.38);border-color:var(--mdc-checkbox-disabled-color, rgba(0, 0, 0, 0.38));background-color:transparent}.mdc-checkbox .mdc-checkbox__native-control[disabled]:checked~.mdc-checkbox__background,.mdc-checkbox .mdc-checkbox__native-control[disabled]:indeterminate~.mdc-checkbox__background,.mdc-checkbox .mdc-checkbox__native-control[data-indeterminate=true][disabled]~.mdc-checkbox__background{border-color:transparent;background-color:rgba(0, 0, 0, 0.38);background-color:var(--mdc-checkbox-disabled-color, rgba(0, 0, 0, 0.38))}.mdc-checkbox .mdc-checkbox__native-control:enabled~.mdc-checkbox__background .mdc-checkbox__checkmark{color:#fff;color:var(--mdc-checkbox-ink-color, #fff)}.mdc-checkbox .mdc-checkbox__native-control:enabled~.mdc-checkbox__background .mdc-checkbox__mixedmark{border-color:#fff;border-color:var(--mdc-checkbox-ink-color, #fff)}.mdc-checkbox .mdc-checkbox__native-control:disabled~.mdc-checkbox__background .mdc-checkbox__checkmark{color:#fff;color:var(--mdc-checkbox-ink-color, #fff)}.mdc-checkbox .mdc-checkbox__native-control:disabled~.mdc-checkbox__background .mdc-checkbox__mixedmark{border-color:#fff;border-color:var(--mdc-checkbox-ink-color, #fff)}.mdc-touch-target-wrapper{display:inline}@keyframes mdc-checkbox-unchecked-checked-checkmark-path{0%,50%{stroke-dashoffset:29.7833385}50%{animation-timing-function:cubic-bezier(0, 0, 0.2, 1)}100%{stroke-dashoffset:0}}@keyframes mdc-checkbox-unchecked-indeterminate-mixedmark{0%,68.2%{transform:scaleX(0)}68.2%{animation-timing-function:cubic-bezier(0, 0, 0, 1)}100%{transform:scaleX(1)}}@keyframes mdc-checkbox-checked-unchecked-checkmark-path{from{animation-timing-function:cubic-bezier(0.4, 0, 1, 1);opacity:1;stroke-dashoffset:0}to{opacity:0;stroke-dashoffset:-29.7833385}}@keyframes mdc-checkbox-checked-indeterminate-checkmark{from{animation-timing-function:cubic-bezier(0, 0, 0.2, 1);transform:rotate(0deg);opacity:1}to{transform:rotate(45deg);opacity:0}}@keyframes mdc-checkbox-indeterminate-checked-checkmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);transform:rotate(45deg);opacity:0}to{transform:rotate(360deg);opacity:1}}@keyframes mdc-checkbox-checked-indeterminate-mixedmark{from{animation-timing-function:mdc-animation-deceleration-curve-timing-function;transform:rotate(-45deg);opacity:0}to{transform:rotate(0deg);opacity:1}}@keyframes mdc-checkbox-indeterminate-checked-mixedmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);transform:rotate(0deg);opacity:1}to{transform:rotate(315deg);opacity:0}}@keyframes mdc-checkbox-indeterminate-unchecked-mixedmark{0%{animation-timing-function:linear;transform:scaleX(1);opacity:1}32.8%,100%{transform:scaleX(0);opacity:0}}.mdc-checkbox{display:inline-block;position:relative;flex:0 0 18px;box-sizing:content-box;width:18px;height:18px;line-height:0;white-space:nowrap;cursor:pointer;vertical-align:bottom}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-checkbox__native-control[disabled]:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:GrayText;border-color:var(--mdc-checkbox-disabled-color, GrayText);background-color:transparent}.mdc-checkbox__native-control[disabled]:checked~.mdc-checkbox__background,.mdc-checkbox__native-control[disabled]:indeterminate~.mdc-checkbox__background,.mdc-checkbox__native-control[data-indeterminate=true][disabled]~.mdc-checkbox__background{border-color:GrayText;background-color:transparent;background-color:var(--mdc-checkbox-disabled-color, transparent)}.mdc-checkbox__native-control:disabled~.mdc-checkbox__background .mdc-checkbox__checkmark{color:GrayText;color:var(--mdc-checkbox-ink-color, GrayText)}.mdc-checkbox__native-control:disabled~.mdc-checkbox__background .mdc-checkbox__mixedmark{border-color:GrayText;border-color:var(--mdc-checkbox-ink-color, GrayText)}.mdc-checkbox__mixedmark{margin:0 1px}}.mdc-checkbox--disabled{cursor:default;pointer-events:none}.mdc-checkbox__background{display:inline-flex;position:absolute;align-items:center;justify-content:center;box-sizing:border-box;width:18px;height:18px;border:2px solid currentColor;border-radius:2px;background-color:transparent;pointer-events:none;will-change:background-color,border-color;transition:background-color 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1),border-color 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox__checkmark{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;opacity:0;transition:opacity 180ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox--upgraded .mdc-checkbox__checkmark{opacity:1}.mdc-checkbox__checkmark-path{transition:stroke-dashoffset 180ms 0ms cubic-bezier(0.4, 0, 0.6, 1);stroke:currentColor;stroke-width:3.12px;stroke-dashoffset:29.7833385;stroke-dasharray:29.7833385}.mdc-checkbox__mixedmark{width:100%;height:0;transform:scaleX(0) rotate(0deg);border-width:1px;border-style:solid;opacity:0;transition:opacity 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1),transform 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__background,.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__background,.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__background,.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__background{animation-duration:180ms;animation-timing-function:linear}.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__checkmark-path{animation:mdc-checkbox-unchecked-checked-checkmark-path 180ms linear 0s;transition:none}.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__mixedmark{animation:mdc-checkbox-unchecked-indeterminate-mixedmark 90ms linear 0s;transition:none}.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__checkmark-path{animation:mdc-checkbox-checked-unchecked-checkmark-path 90ms linear 0s;transition:none}.mdc-checkbox--anim-checked-indeterminate .mdc-checkbox__checkmark{animation:mdc-checkbox-checked-indeterminate-checkmark 90ms linear 0s;transition:none}.mdc-checkbox--anim-checked-indeterminate .mdc-checkbox__mixedmark{animation:mdc-checkbox-checked-indeterminate-mixedmark 90ms linear 0s;transition:none}.mdc-checkbox--anim-indeterminate-checked .mdc-checkbox__checkmark{animation:mdc-checkbox-indeterminate-checked-checkmark 500ms linear 0s;transition:none}.mdc-checkbox--anim-indeterminate-checked .mdc-checkbox__mixedmark{animation:mdc-checkbox-indeterminate-checked-mixedmark 500ms linear 0s;transition:none}.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__mixedmark{animation:mdc-checkbox-indeterminate-unchecked-mixedmark 300ms linear 0s;transition:none}.mdc-checkbox__native-control:checked~.mdc-checkbox__background,.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background{transition:border-color 90ms 0ms cubic-bezier(0, 0, 0.2, 1),background-color 90ms 0ms cubic-bezier(0, 0, 0.2, 1)}.mdc-checkbox__native-control:checked~.mdc-checkbox__background .mdc-checkbox__checkmark-path,.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background .mdc-checkbox__checkmark-path,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background .mdc-checkbox__checkmark-path{stroke-dashoffset:0}.mdc-checkbox__native-control{position:absolute;margin:0;padding:0;opacity:0;cursor:inherit}.mdc-checkbox__native-control:disabled{cursor:default;pointer-events:none}.mdc-checkbox--touch{margin:calc((48px - 40px) / 2);margin:calc((var(--mdc-checkbox-state-layer-size, 48px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2)}.mdc-checkbox--touch .mdc-checkbox__native-control{top:calc((40px - 48px) / 2);top:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 48px)) / 2);right:calc((40px - 48px) / 2);right:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 48px)) / 2);left:calc((40px - 48px) / 2);left:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 48px)) / 2);width:48px;width:var(--mdc-checkbox-state-layer-size, 48px);height:48px;height:var(--mdc-checkbox-state-layer-size, 48px)}.mdc-checkbox__native-control:checked~.mdc-checkbox__background .mdc-checkbox__checkmark{transition:opacity 180ms 0ms cubic-bezier(0, 0, 0.2, 1),transform 180ms 0ms cubic-bezier(0, 0, 0.2, 1);opacity:1}.mdc-checkbox__native-control:checked~.mdc-checkbox__background .mdc-checkbox__mixedmark{transform:scaleX(1) rotate(-45deg)}.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background .mdc-checkbox__checkmark,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background .mdc-checkbox__checkmark{transform:rotate(45deg);opacity:0;transition:opacity 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1),transform 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background .mdc-checkbox__mixedmark,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background .mdc-checkbox__mixedmark{transform:scaleX(1) rotate(0deg);opacity:1}.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__background,.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__checkmark,.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__checkmark-path,.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__mixedmark{transition:none}:host{outline:none;display:inline-flex;-webkit-tap-highlight-color:transparent}:host([checked]),:host([indeterminate]){--mdc-ripple-color:var(--mdc-theme-secondary, #018786)}.mdc-checkbox .mdc-checkbox__background::before{content:none}`
|
|
465
|
-
/**
|
|
466
|
-
* @license
|
|
467
|
-
* Copyright 2018 Google LLC
|
|
468
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
469
|
-
*/;let Ci=class extends Oi{};Ci.styles=[zi],Ci=ei([e("mwc-checkbox")],Ci);var Ei=function(t,e,i,r){for(var o,n=arguments.length,a=n<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,i):r,c=t.length-1;c>=0;c--)(o=t[c])&&(a=(n<3?o(a):n>3?o(e,i,a):o(e,i))||a);return n>3&&a&&Object.defineProperty(e,i,a),a};const Ri={color:bt.extend("--ft-ripple-color",gt.colorContent),primaryColor:bt.extend("--ft-ripple-primary-color",bt.extend("--ft-ripple-color",gt.colorPrimary)),secondaryColor:bt.extend("--ft-ripple-secondary-color",bt.extend("--ft-ripple-color",gt.colorSecondary)),opacityContentOnSurfacePressed:bt.external(gt.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:bt.external(gt.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:bt.external(gt.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:bt.external(gt.opacityContentOnSurfaceSelected,"Design system")};class Bi extends xt{constructor(){super(...arguments),this.primary=!1,this.secondary=!1,this.unbounded=!1,this.activated=!1,this.selected=!1,this.disabled=!1,this.hovered=!1,this.focused=!1,this.pressed=!1,this.rippling=!1,this.rippleSize=0,this.originX=0,this.originY=0,this.resizeObserver=new ResizeObserver((()=>this.setRippleSize())),this.onTransitionStart=t=>{"transform"===t.propertyName&&(this.rippling=this.pressed)},this.onTransitionEnd=t=>{"transform"===t.propertyName&&(this.rippling=!1)},this.moveRipple=t=>{var e,i;let{x:r,y:o}=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!=r?r-n.x:n.width/2),this.originY=Math.round(null!=o?o-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 q`
|
|
240
|
+
`],Zt([i()],Ze.prototype,"element",void 0),Zt([i()],Ze.prototype,"variant",void 0),c("ft-typography")(Ze);var Je=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 Xe={color:ft.extend("--ft-ripple-color",bt.colorContent),primaryColor:ft.extend("--ft-ripple-primary-color",ft.extend("--ft-ripple-color",bt.colorPrimary)),secondaryColor:ft.extend("--ft-ripple-secondary-color",ft.extend("--ft-ripple-color",bt.colorSecondary)),opacityContentOnSurfacePressed:ft.external(bt.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:ft.external(bt.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:ft.external(bt.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:ft.external(bt.opacityContentOnSurfaceSelected,"Design system")};class Ye extends vt{constructor(){super(...arguments),this.primary=!1,this.secondary=!1,this.unbounded=!1,this.activated=!1,this.selected=!1,this.disabled=!1,this.hovered=!1,this.focused=!1,this.pressed=!1,this.rippling=!1,this.rippleSize=0,this.originX=0,this.originY=0,this.resizeObserver=new ResizeObserver((()=>this.setRippleSize())),this.onTransitionStart=t=>{"transform"===t.propertyName&&(this.rippling=this.pressed)},this.onTransitionEnd=t=>{"transform"===t.propertyName&&(this.rippling=!1)},this.moveRipple=t=>{var e,i;let{x:o,y: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 K`
|
|
470
241
|
<style>
|
|
471
242
|
.ft-ripple .ft-ripple--effect,
|
|
472
243
|
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
@@ -483,7 +254,7 @@ const zi=x`.mdc-checkbox{padding:calc((40px - 18px) / 2);padding:calc((var(--mdc
|
|
|
483
254
|
<div class="ft-ripple--background"></div>
|
|
484
255
|
<div class="ft-ripple--effect"></div>
|
|
485
256
|
</div>
|
|
486
|
-
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){super.updated(t),t.has("disabled")&&this.disabled&&this.endRipple(),t.has("unbounded")&&this.setRippleSize()}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}setRippleSize(){if(this.ripple){const t=this.ripple.getBoundingClientRect();this.rippleSize=(this.unbounded?1:1.7)*Math.max(t.width,t.height)}}connectedCallback(){var t;super.connectedCallback();const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(e),this.setRippleSize()}setupFor(t){this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const e=(...t)=>e=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(e)},i=e("mouseup","contextmenu"),
|
|
257
|
+
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){super.updated(t),t.has("disabled")&&this.disabled&&this.endRipple(),t.has("unbounded")&&this.setRippleSize()}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}setRippleSize(){if(this.ripple){const t=this.ripple.getBoundingClientRect();this.rippleSize=(this.unbounded?1:1.7)*Math.max(t.width,t.height)}}connectedCallback(){var t;super.connectedCallback();const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(e),this.setRippleSize()}setupFor(t){if(this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const e=(...t)=>e=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(e)},i=e("mouseup","contextmenu"),o=e("touchend","touchcancel"),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()}}Ye.elementDefinitions={},Ye.styles=v`
|
|
487
258
|
:host {
|
|
488
259
|
display: contents;
|
|
489
260
|
}
|
|
@@ -502,17 +273,17 @@ const zi=x`.mdc-checkbox{padding:calc((40px - 18px) / 2);padding:calc((var(--mdc
|
|
|
502
273
|
.ft-ripple .ft-ripple--effect {
|
|
503
274
|
position: absolute;
|
|
504
275
|
opacity: 0;
|
|
505
|
-
background-color: ${
|
|
276
|
+
background-color: ${Xe.color};
|
|
506
277
|
}
|
|
507
278
|
|
|
508
279
|
.ft-ripple.ft-ripple--secondary .ft-ripple--background,
|
|
509
280
|
.ft-ripple.ft-ripple--secondary .ft-ripple--effect {
|
|
510
|
-
background-color: ${
|
|
281
|
+
background-color: ${Xe.secondaryColor};
|
|
511
282
|
}
|
|
512
283
|
|
|
513
284
|
.ft-ripple.ft-ripple--primary .ft-ripple--background,
|
|
514
285
|
.ft-ripple.ft-ripple--primary .ft-ripple--effect {
|
|
515
|
-
background-color: ${
|
|
286
|
+
background-color: ${Xe.primaryColor};
|
|
516
287
|
}
|
|
517
288
|
|
|
518
289
|
.ft-ripple .ft-ripple--background {
|
|
@@ -543,33 +314,22 @@ const zi=x`.mdc-checkbox{padding:calc((40px - 18px) / 2);padding:calc((var(--mdc
|
|
|
543
314
|
}
|
|
544
315
|
|
|
545
316
|
.ft-ripple.ft-ripple--hovered .ft-ripple--background {
|
|
546
|
-
opacity: ${
|
|
317
|
+
opacity: ${Xe.opacityContentOnSurfaceHover};
|
|
547
318
|
}
|
|
548
319
|
|
|
549
320
|
.ft-ripple.ft-ripple--selected .ft-ripple--background {
|
|
550
|
-
opacity: ${
|
|
321
|
+
opacity: ${Xe.opacityContentOnSurfaceSelected};
|
|
551
322
|
}
|
|
552
323
|
|
|
553
324
|
.ft-ripple.ft-ripple--focused .ft-ripple--background {
|
|
554
|
-
opacity: ${
|
|
325
|
+
opacity: ${Xe.opacityContentOnSurfaceFocused};
|
|
555
326
|
}
|
|
556
327
|
|
|
557
328
|
.ft-ripple.ft-ripple--pressed .ft-ripple--effect {
|
|
558
|
-
opacity: ${
|
|
329
|
+
opacity: ${Xe.opacityContentOnSurfacePressed};
|
|
559
330
|
transform: translate(-50%, -50%) scale(1);
|
|
560
331
|
}
|
|
561
|
-
`,
|
|
562
|
-
/**
|
|
563
|
-
* @license
|
|
564
|
-
* Copyright 2021 Google LLC
|
|
565
|
-
* SPDX-LIcense-Identifier: Apache-2.0
|
|
566
|
-
*/
|
|
567
|
-
const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:"liga"}`
|
|
568
|
-
/**
|
|
569
|
-
* @license
|
|
570
|
-
* Copyright 2018 Google LLC
|
|
571
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
572
|
-
*/;let Ai=class extends ut{render(){return q`<span><slot></slot></span>`}};Ai.styles=[Fi],Ai=ei([e("mwc-icon")],Ai);var Ni=function(t,e,i,r){for(var o,n=arguments.length,a=n<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,i):r,c=t.length-1;c>=0;c--)(o=t[c])&&(a=(n<3?o(a):n>3?o(e,i,a):o(e,i))||a);return n>3&&a&&Object.defineProperty(e,i,a),a};const Ti=bt.create("--ft-tooltip-distance","SIZE","4px"),Mi=bt.create("--ft-tooltip-color","COLOR","#FFFFFF"),Li=bt.create("--ft-tooltip-background-color","COLOR","#666666"),Di=bt.create("--ft-tooltip-z-index","NUMBER","1"),Ii=bt.external(gt.borderRadiusS,"Design system");class ji extends xt{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.hideDebounce=new t,this.revealDebouncer=new t}render(){return q`
|
|
332
|
+
`,Je([i({type:Boolean})],Ye.prototype,"primary",void 0),Je([i({type:Boolean})],Ye.prototype,"secondary",void 0),Je([i({type:Boolean})],Ye.prototype,"unbounded",void 0),Je([i({type:Boolean})],Ye.prototype,"activated",void 0),Je([i({type:Boolean})],Ye.prototype,"selected",void 0),Je([i({type:Boolean})],Ye.prototype,"disabled",void 0),Je([o()],Ye.prototype,"hovered",void 0),Je([o()],Ye.prototype,"focused",void 0),Je([o()],Ye.prototype,"pressed",void 0),Je([o()],Ye.prototype,"rippling",void 0),Je([o()],Ye.prototype,"rippleSize",void 0),Je([o()],Ye.prototype,"originX",void 0),Je([o()],Ye.prototype,"originY",void 0),Je([n(".ft-ripple")],Ye.prototype,"ripple",void 0),Je([n(".ft-ripple--effect")],Ye.prototype,"rippleEffect",void 0),c("ft-ripple")(Ye);var Qe=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 Ge=ft.create("--ft-tooltip-distance","SIZE","4px"),ti=ft.create("--ft-tooltip-color","COLOR","#FFFFFF"),ei=ft.create("--ft-tooltip-background-color","COLOR","#666666"),ii=ft.create("--ft-tooltip-z-index","NUMBER","1"),oi=ft.external(bt.borderRadiusS,"Design system");class si extends vt{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.hideDebounce=new t,this.revealDebouncer=new t}render(){return K`
|
|
573
333
|
<div part="container"
|
|
574
334
|
class="ft-tooltip--container ${this.inline?"ft-tooltip--inline":""}"
|
|
575
335
|
@mouseenter=${this.onHover}
|
|
@@ -584,7 +344,7 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
584
344
|
</div>
|
|
585
345
|
<slot></slot>
|
|
586
346
|
</div>
|
|
587
|
-
`}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,
|
|
347
|
+
`}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())}}si.elementDefinitions={"ft-typography":Ze},si.styles=v`
|
|
588
348
|
.ft-tooltip--container {
|
|
589
349
|
display: block;
|
|
590
350
|
position: relative;
|
|
@@ -602,21 +362,21 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
602
362
|
width: max-content;
|
|
603
363
|
max-width: 150px;
|
|
604
364
|
text-align: center;
|
|
605
|
-
padding: ${
|
|
606
|
-
z-index: ${
|
|
365
|
+
padding: ${Ge};
|
|
366
|
+
z-index: ${ii};
|
|
607
367
|
}
|
|
608
368
|
|
|
609
369
|
.ft-tooltip--content {
|
|
610
370
|
padding: 4px 8px;
|
|
611
|
-
border-radius: ${
|
|
612
|
-
background-color: ${
|
|
613
|
-
color: ${
|
|
371
|
+
border-radius: ${oi};
|
|
372
|
+
background-color: ${ei};
|
|
373
|
+
color: ${ti};
|
|
614
374
|
top: -500px;
|
|
615
375
|
left: -500px;
|
|
616
376
|
position: relative;
|
|
617
377
|
word-break: break-word;
|
|
618
378
|
}
|
|
619
|
-
`,
|
|
379
|
+
`,Qe([i()],si.prototype,"text",void 0),Qe([i({type:Boolean})],si.prototype,"manual",void 0),Qe([i({type:Boolean})],si.prototype,"inline",void 0),Qe([i({type:Number})],si.prototype,"delay",void 0),Qe([i()],si.prototype,"position",void 0),Qe([function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},i?a({slot:n,flatten:e,selector:i}):s({descriptor:t=>({get(){var t,e;const i="slot"+(n?`[name=${n}]`:":not([name])"),s=null===(t=this.renderRoot)||void 0===t?void 0:t.querySelector(i);return null!==(e=null==s?void 0:s.assignedNodes(o))&&void 0!==e?e:[]},enumerable:!0,configurable:!0})})}("",!0)],si.prototype,"slotNodes",void 0),Qe([n(".ft-tooltip--container")],si.prototype,"container",void 0),Qe([n("slot")],si.prototype,"target",void 0),Qe([n(".ft-tooltip")],si.prototype,"tooltip",void 0),Qe([n(".ft-tooltip--content")],si.prototype,"tooltipContent",void 0),Qe([o()],si.prototype,"visible",void 0),c("ft-tooltip")(si);const ni={color:ft.extend("--ft-loader-color",bt.colorPrimary),size:ft.create("--ft-loader-size","SIZE","80px")};class ri extends vt{static get styles(){return v`
|
|
620
380
|
:host {
|
|
621
381
|
line-height: 0;
|
|
622
382
|
}
|
|
@@ -625,8 +385,8 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
625
385
|
display: inline-block;
|
|
626
386
|
position: relative;
|
|
627
387
|
|
|
628
|
-
width: ${
|
|
629
|
-
height: ${
|
|
388
|
+
width: ${ni.size};
|
|
389
|
+
height: ${ni.size};
|
|
630
390
|
}
|
|
631
391
|
|
|
632
392
|
.ft-loader div {
|
|
@@ -635,7 +395,7 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
635
395
|
width: 25%;
|
|
636
396
|
height: 25%;
|
|
637
397
|
border-radius: 50%;
|
|
638
|
-
background: ${
|
|
398
|
+
background: ${ni.color};
|
|
639
399
|
animation-timing-function: cubic-bezier(0, 1, 1, 0);
|
|
640
400
|
}
|
|
641
401
|
|
|
@@ -682,17 +442,61 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
682
442
|
transform: translate(0, 0);
|
|
683
443
|
}
|
|
684
444
|
100% {
|
|
685
|
-
transform: translate(calc(0.35 * ${
|
|
445
|
+
transform: translate(calc(0.35 * ${ni.size}), 0);
|
|
686
446
|
}
|
|
687
447
|
}
|
|
688
|
-
`}render(){return
|
|
448
|
+
`}render(){return K`
|
|
689
449
|
<div class="ft-loader">
|
|
690
450
|
<div></div>
|
|
691
451
|
<div></div>
|
|
692
452
|
<div></div>
|
|
693
453
|
<div></div>
|
|
694
454
|
</div>
|
|
695
|
-
`}}
|
|
455
|
+
`}}c("ft-loader")(ri);
|
|
456
|
+
/**
|
|
457
|
+
* @license
|
|
458
|
+
* Copyright 2017 Google LLC
|
|
459
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
460
|
+
*/
|
|
461
|
+
class li extends Ct{constructor(t){if(super(t),this.it=V,t.type!==St)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===V||null==t)return this.vt=void 0,this.it=t;if(t===W)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this.vt;this.it=t;const e=[t];return e.raw=e,this.vt={_$litType$:this.constructor.resultType,strings:e,values:[]}}}li.directiveName="unsafeHTML",li.resultType=1;const ai=Ot(li);var ci,hi;!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=""}(ci||(ci={})),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=""}(hi||(hi={}));const pi=new Map([...["abw"].map((t=>[t,hi.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,hi.AUDIO])),...["avi"].map((t=>[t,hi.AVI])),...["chm","xhs"].map((t=>[t,hi.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,hi.CODE])),...["csv"].map((t=>[t,hi.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,hi.DITA])),...["epub"].map((t=>[t,hi.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,hi.EXCEL])),...["flac"].map((t=>[t,hi.FLAC])),...["gif"].map((t=>[t,hi.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,hi.GZIP])),...["html","htm","xhtml"].map((t=>[t,hi.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,hi.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,hi.JPEG])),...["json"].map((t=>[t,hi.JSON])),...["m4a","m4p"].map((t=>[t,hi.M4A])),...["mov","qt"].map((t=>[t,hi.MOV])),...["mp3"].map((t=>[t,hi.MP3])),...["mp4","m4v"].map((t=>[t,hi.MP4])),...["ogg","oga"].map((t=>[t,hi.OGG])),...["pdf","ps"].map((t=>[t,hi.PDF])),...["png"].map((t=>[t,hi.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,hi.POWERPOINT])),...["rar"].map((t=>[t,hi.RAR])),...["stp"].map((t=>[t,hi.STP])),...["txt","rtf","md","mdown"].map((t=>[t,hi.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,hi.VIDEO])),...["wav"].map((t=>[t,hi.WAV])),...["wma"].map((t=>[t,hi.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,hi.WORD])),...["xml","xsl","rdf"].map((t=>[t,hi.XML])),...["yaml","yml","x-yaml"].map((t=>[t,hi.YAML])),...["zip"].map((t=>[t,hi.ZIP]))]),di=new Map([["application/msword","application/doc"],["application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/docx"],["application/vnd.openxmlformats-officedocument.wordprocessingml.template","application/dotx"],["application/vnd.ms-word.document.macroEnabled.12","application/docm"],["application/vnd.ms-word.template.macroEnabled.12","application/dotm"],["application/vnd.ms-excel","application/xls"],["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/xlsx"],["application/vnd.openxmlformats-officedocument.spreadsheetml.template","application/xltx"],["application/vnd.ms-excel.sheet.macroEnabled.12","application/xlsm"],["application/vnd.ms-excel.template.macroEnabled.12","application/xltm"],["application/vnd.ms-excel.addin.macroEnabled.12","application/xlam"],["application/vnd.ms-excel.sheet.binary.macroEnabled.12","application/xlsb"],["application/vnd.ms-powerpoint","application/ppt"],["application/vnd.openxmlformats-officedocument.presentationml.presentation","application/pptx"],["application/vnd.openxmlformats-officedocument.presentationml.template","application/potx"],["application/vnd.openxmlformats-officedocument.presentationml.slideshow","application/ppsx"],["application/vnd.ms-powerpoint.addin.macroEnabled.12","application/ppam"],["application/vnd.ms-powerpoint.presentation.macroEnabled.12","application/pptm"],["application/vnd.ms-powerpoint.template.macroEnabled.12","application/potm"],["application/vnd.ms-powerpoint.slideshow.macroEnabled.12","application/ppsm"],["application/vnd.ms-access","application/mdb"]]);var fi,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};!function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(fi||(fi={}));const bi={size:ft.create("--ft-icon-font-size","SIZE","24px"),fluidTopicsFontFamily:ft.extend("--ft-icon-fluid-topics-font-family",ft.create("--ft-icon-font-family","UNKNOWN","ft-icons")),fileFormatFontFamily:ft.extend("--ft-icon-file-format-font-family",ft.create("--ft-icon-font-family","UNKNOWN","ft-mime")),materialFontFamily:ft.extend("--ft-icon-material-font-family",ft.create("--ft-icon-font-family","UNKNOWN","Material Icons"))};class vi extends vt{constructor(){super(...arguments),this.variant=fi.fluid_topics}render(){return K`
|
|
462
|
+
<i class="ft-icon ${"ft-icon--"+this.variant}">
|
|
463
|
+
${ai(this.getIcon())}
|
|
464
|
+
<slot @slotchange=${()=>this.requestUpdate()} ?hidden=${"material"!==this.variant}></slot>
|
|
465
|
+
</i>
|
|
466
|
+
`}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===fi.file_format?null!==(t=hi[i.toUpperCase()])&&void 0!==t?t:i:this.variant===fi.fluid_topics?null!==(e=ci[i.toUpperCase()])&&void 0!==e?e:i:V}}vi.elementDefinitions={},vi.styles=v`
|
|
467
|
+
:host, i.ft-icon {
|
|
468
|
+
display: inline-block;
|
|
469
|
+
width: ${bi.size};
|
|
470
|
+
height: ${bi.size};
|
|
471
|
+
text-align: center;
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
i.ft-icon {
|
|
475
|
+
font-size: ${bi.size};
|
|
476
|
+
line-height: 1;
|
|
477
|
+
font-weight: normal;
|
|
478
|
+
text-transform: none;
|
|
479
|
+
font-style: normal;
|
|
480
|
+
font-variant: normal;
|
|
481
|
+
speak: none;
|
|
482
|
+
text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.004);
|
|
483
|
+
text-rendering: auto;
|
|
484
|
+
-webkit-font-smoothing: antialiased;
|
|
485
|
+
-moz-osx-font-smoothing: grayscale;
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
.ft-icon--fluid-topics {
|
|
489
|
+
font-family: ${bi.fluidTopicsFontFamily}, ft-icons, fticons, sans-serif;
|
|
490
|
+
}
|
|
491
|
+
|
|
492
|
+
.ft-icon--file-format {
|
|
493
|
+
font-family: ${bi.fileFormatFontFamily}, ft-mime, sans-serif;
|
|
494
|
+
}
|
|
495
|
+
|
|
496
|
+
.ft-icon--material {
|
|
497
|
+
font-family: ${bi.materialFontFamily}, "Material Icons", sans-serif;
|
|
498
|
+
}
|
|
499
|
+
`,ui([i()],vi.prototype,"variant",void 0),ui([n("slot")],vi.prototype,"slottedContent",void 0),c("ft-icon")(vi);var gi=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 xi=ft.extend("--ft-button-color",bt.colorPrimary),yi={backgroundColor:ft.extend("--ft-button-background-color",bt.colorSurface),borderRadius:ft.extend("--ft-button-border-radius",bt.borderRadiusL),color:xi,fontSize:ft.extend("--ft-button-font-size",Me.fontSize),iconSize:ft.create("--ft-button-icon-size","SIZE","24px"),rippleColor:ft.extend("--ft-button-ripple-color",xi),opacityDisabled:ft.external(bt.colorOpacityDisabled,"Design system")},mi=ft.extend("--ft-button-primary-color",ft.extend("--ft-button-color",bt.colorOnPrimary)),$i={backgroundColor:ft.extend("--ft-button-primary-background-color",ft.extend("--ft-button-background-color",bt.colorPrimary)),color:mi,rippleColor:ft.extend("--ft-button-primary-ripple-color",mi)},wi=ft.extend("--ft-button-dense-border-radius",ft.extend("--ft-button-border-radius",bt.borderRadiusM));class ki extends vt{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,v`
|
|
696
500
|
:host {
|
|
697
501
|
display: inline-block;
|
|
698
502
|
max-width: 100%;
|
|
@@ -731,18 +535,18 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
731
535
|
border: none;
|
|
732
536
|
pointer-events: auto;
|
|
733
537
|
|
|
734
|
-
--ft-button-internal-font-size: ${
|
|
538
|
+
--ft-button-internal-font-size: ${yi.fontSize};
|
|
735
539
|
--ft-button-internal-line-height: calc(var(--ft-button-internal-font-size) + 2px);
|
|
736
|
-
--ft-button-internal-color: ${
|
|
737
|
-
|
|
540
|
+
--ft-button-internal-color: ${yi.color};
|
|
541
|
+
${ut(bi.size,yi.iconSize)};
|
|
738
542
|
--ft-button-internal-vertical-padding: 6px;
|
|
739
543
|
--ft-button-internal-horizontal-padding: 8px;
|
|
740
|
-
${
|
|
741
|
-
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height),
|
|
544
|
+
${ut(Xe.color,yi.rippleColor)};
|
|
545
|
+
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height), ${yi.iconSize});
|
|
742
546
|
|
|
743
|
-
border-radius: ${
|
|
547
|
+
border-radius: ${yi.borderRadius};
|
|
744
548
|
padding: var(--ft-button-internal-vertical-padding) var(--ft-button-internal-horizontal-padding);
|
|
745
|
-
background-color: ${
|
|
549
|
+
background-color: ${yi.backgroundColor};
|
|
746
550
|
color: var(--ft-button-internal-color);
|
|
747
551
|
-webkit-mask-image: radial-gradient(white, black);
|
|
748
552
|
}
|
|
@@ -754,7 +558,7 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
754
558
|
.ft-button--dense {
|
|
755
559
|
--ft-button-internal-vertical-padding: 2px;
|
|
756
560
|
--ft-button-internal-horizontal-padding: 4px;
|
|
757
|
-
border-radius: ${
|
|
561
|
+
border-radius: ${wi};
|
|
758
562
|
}
|
|
759
563
|
|
|
760
564
|
.ft-button--round {
|
|
@@ -763,13 +567,13 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
763
567
|
|
|
764
568
|
.ft-button[disabled] {
|
|
765
569
|
filter: grayscale(1);
|
|
766
|
-
opacity: ${
|
|
570
|
+
opacity: ${yi.opacityDisabled};
|
|
767
571
|
}
|
|
768
572
|
|
|
769
573
|
.ft-button.ft-button--primary {
|
|
770
|
-
background-color: ${
|
|
771
|
-
--ft-button-internal-color: ${
|
|
772
|
-
${
|
|
574
|
+
background-color: ${$i.backgroundColor};
|
|
575
|
+
--ft-button-internal-color: ${$i.color};
|
|
576
|
+
${ut(Xe.color,$i.rippleColor)};
|
|
773
577
|
}
|
|
774
578
|
|
|
775
579
|
.ft-button.ft-button--outlined {
|
|
@@ -787,8 +591,8 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
787
591
|
text-overflow: ellipsis;
|
|
788
592
|
display: block;
|
|
789
593
|
margin: 0 var(--ft-button-internal-horizontal-padding);
|
|
790
|
-
${
|
|
791
|
-
${
|
|
594
|
+
${ut(Me.fontSize,"var(--ft-button-internal-font-size)")};
|
|
595
|
+
${ut(Me.lineHeight,"var(--ft-button-internal-content-height)")};
|
|
792
596
|
}
|
|
793
597
|
|
|
794
598
|
.ft-button--safari-fix .ft-button--label {
|
|
@@ -805,26 +609,25 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
805
609
|
display: none;
|
|
806
610
|
}
|
|
807
611
|
|
|
808
|
-
|
|
612
|
+
ft-icon {
|
|
809
613
|
flex-shrink: 0;
|
|
810
|
-
width: var(--mdc-icon-size);
|
|
811
614
|
}
|
|
812
615
|
|
|
813
|
-
.ft-button--label[hidden] +
|
|
616
|
+
.ft-button--label[hidden] + ft-icon {
|
|
814
617
|
margin: 0 calc(var(--ft-button-internal-horizontal-padding) * -1);
|
|
815
618
|
padding: 0 var(--ft-button-internal-vertical-padding);
|
|
816
619
|
}
|
|
817
620
|
|
|
818
|
-
.ft-button:not(.ft-button--trailing-icon)
|
|
621
|
+
.ft-button:not(.ft-button--trailing-icon) ft-icon,
|
|
819
622
|
.ft-button:not(.ft-button--trailing-icon) ft-loader {
|
|
820
623
|
order: -1;
|
|
821
624
|
}
|
|
822
625
|
|
|
823
626
|
ft-loader {
|
|
824
|
-
${
|
|
825
|
-
${
|
|
627
|
+
${ut(ni.size,yi.iconSize)};
|
|
628
|
+
${ut(ni.color,"var(--ft-button-internal-color)")};
|
|
826
629
|
}
|
|
827
|
-
`]}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":
|
|
630
|
+
`]}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":wt,"ft-no-text-select":!0};return this.addTooltip(K`
|
|
828
631
|
<button part="button"
|
|
829
632
|
class="${Dt(t)}"
|
|
830
633
|
aria-label="${this.getLabel()}"
|
|
@@ -838,155 +641,246 @@ const Fi=x`:host{font-family:var(--mdc-icon-font, "Material Icons");font-weight:
|
|
|
838
641
|
</ft-typography>
|
|
839
642
|
${this.resolveIcon()}
|
|
840
643
|
</button>
|
|
841
|
-
`)}addTooltip(t){return this.hasTextContent()||0===this.getLabel().trim().length?t:
|
|
644
|
+
`)}addTooltip(t){return this.hasTextContent()||0===this.getLabel().trim().length?t:K`
|
|
842
645
|
<ft-tooltip part="tooltip"
|
|
843
646
|
text="${this.getLabel()}"
|
|
844
647
|
position="${this.tooltipPosition}">
|
|
845
648
|
${t}
|
|
846
649
|
</ft-tooltip>
|
|
847
|
-
`}resolveIcon(){return this.loading?
|
|
848
|
-
<ft-loader></ft-loader> `:this.icon?
|
|
849
|
-
<
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
.
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
650
|
+
`}resolveIcon(){return this.loading?K`
|
|
651
|
+
<ft-loader></ft-loader> `:this.icon?K`
|
|
652
|
+
<ft-icon variant="material">${this.icon}</ft-icon> `:V}focus(){var t;null===(t=this.button)||void 0===t||t.focus()}getLabel(){return this.label||this.textContent}get textContent(){return this.unslotText(this.slottedContent).trim()}unslotText(t){return t instanceof HTMLSlotElement?t.assignedNodes().map((t=>this.unslotText(t))).join(""):(null==t?void 0:t.textContent)||""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}isDisabled(){return this.disabled||this.loading}}ki.elementDefinitions={"ft-ripple":Ye,"ft-tooltip":si,"ft-typography":Ze,"ft-icon":vi,"ft-loader":ri},gi([i({type:Boolean})],ki.prototype,"primary",void 0),gi([i({type:Boolean})],ki.prototype,"outlined",void 0),gi([i({type:Boolean})],ki.prototype,"disabled",void 0),gi([i({type:Boolean})],ki.prototype,"dense",void 0),gi([i({type:Boolean})],ki.prototype,"round",void 0),gi([i({type:String})],ki.prototype,"label",void 0),gi([i({type:String})],ki.prototype,"icon",void 0),gi([i({type:Boolean})],ki.prototype,"trailingIcon",void 0),gi([i({type:Boolean})],ki.prototype,"loading",void 0),gi([i({type:String})],ki.prototype,"tooltipPosition",void 0),gi([n(".ft-button")],ki.prototype,"button",void 0),gi([n(".ft-button--label slot")],ki.prototype,"slottedContent",void 0),c("ft-button")(ki);var 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};const Oi=ft.extend("--ft-checkbox-text-color",bt.colorOnSurfaceHigh),Ci=ft.external(bt.colorPrimary,"Design system"),zi=ft.external(bt.colorOnPrimary,"Design system"),Ei=ft.extend("--ft-checkbox-border-color",bt.colorOnSurfaceMedium),Bi=ft.external(bt.colorOnSurfaceDisabled,"Design system");class Ni extends vt{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 K`
|
|
653
|
+
<label class="${Dt(t)}">
|
|
654
|
+
<div class="ft-checkbox--box-container">
|
|
655
|
+
<input type="checkbox"
|
|
656
|
+
name=${this.name}
|
|
657
|
+
.checked=${this.checked}
|
|
658
|
+
.disabled=${this.disabled}
|
|
659
|
+
@change=${this.onChange}
|
|
660
|
+
>
|
|
661
|
+
<ft-ripple
|
|
662
|
+
?disabled=${this.disabled}
|
|
663
|
+
?primary=${this.checked||this.indeterminate}
|
|
664
|
+
unbounded>
|
|
665
|
+
</ft-ripple>
|
|
666
|
+
<div class="ft-checkbox--box">
|
|
667
|
+
<svg class="ft-checkbox--checkmark" viewBox="0 0 24 24">
|
|
668
|
+
<path class="ft-checkbox--checkmark-path" fill="none"
|
|
669
|
+
d=${this.indeterminate&&!this.checked?"M2,12 22,12":"M1.73,12.91 8.1,19.28 22.79,4.59"}></path>
|
|
670
|
+
</svg>
|
|
671
|
+
</div>
|
|
672
|
+
</div>
|
|
673
|
+
<ft-typography variant="body2">
|
|
674
|
+
<slot></slot>
|
|
675
|
+
</ft-typography>
|
|
676
|
+
</label>
|
|
677
|
+
`}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)}}Ni.elementDefinitions={"ft-ripple":Ye,"ft-typography":Ze},Ni.styles=v`
|
|
678
|
+
* {
|
|
679
|
+
box-sizing: border-box;
|
|
680
|
+
}
|
|
681
|
+
|
|
682
|
+
.ft-checkbox {
|
|
683
|
+
box-sizing: border-box;
|
|
684
|
+
color: ${Oi};
|
|
685
|
+
|
|
686
|
+
display: inline-flex;
|
|
687
|
+
align-items: center;
|
|
688
|
+
gap: 4px;
|
|
689
|
+
}
|
|
690
|
+
|
|
691
|
+
.ft-checkbox--disabled {
|
|
692
|
+
color: ${Bi};
|
|
693
|
+
}
|
|
694
|
+
|
|
695
|
+
input {
|
|
696
|
+
opacity: 0;
|
|
697
|
+
position: absolute;
|
|
698
|
+
width: 40px;
|
|
699
|
+
height: 40px;
|
|
700
|
+
margin: 0;
|
|
701
|
+
}
|
|
702
|
+
|
|
703
|
+
.ft-checkbox--box-container {
|
|
704
|
+
position: relative;
|
|
705
|
+
width: 40px;
|
|
706
|
+
height: 40px;
|
|
707
|
+
|
|
708
|
+
display: flex;
|
|
709
|
+
justify-content: center;
|
|
710
|
+
align-items: center;
|
|
711
|
+
flex-shrink: 0;
|
|
712
|
+
}
|
|
713
|
+
|
|
714
|
+
.ft-checkbox--box {
|
|
715
|
+
border: 2px solid ${Ei};
|
|
716
|
+
border-radius: 2px;
|
|
717
|
+
|
|
718
|
+
width: 18px;
|
|
719
|
+
height: 18px;
|
|
720
|
+
|
|
721
|
+
color: ${zi};
|
|
722
|
+
}
|
|
723
|
+
|
|
724
|
+
|
|
725
|
+
.ft-checkbox--checked .ft-checkbox--box,
|
|
726
|
+
.ft-checkbox--indeterminate .ft-checkbox--box {
|
|
727
|
+
border-color: ${Ci};
|
|
728
|
+
background-color: ${Ci};
|
|
729
|
+
}
|
|
730
|
+
|
|
731
|
+
.ft-checkbox--disabled .ft-checkbox--box {
|
|
732
|
+
border-color: ${Bi};
|
|
733
|
+
background-color: transparent;
|
|
734
|
+
color: ${Bi};
|
|
735
|
+
}
|
|
736
|
+
|
|
737
|
+
.ft-checkbox--checkmark {
|
|
738
|
+
transition: opacity 180ms cubic-bezier(0, 0, 0.2, 1) 0ms, transform 180ms cubic-bezier(0, 0, 0.2, 1) 0ms;
|
|
739
|
+
opacity: 0;
|
|
740
|
+
}
|
|
741
|
+
|
|
742
|
+
.ft-checkbox--checkmark-path {
|
|
743
|
+
stroke-dashoffset: 0;
|
|
744
|
+
stroke: currentcolor;
|
|
745
|
+
stroke-width: 3px;
|
|
746
|
+
stroke-dasharray: 30;
|
|
747
|
+
}
|
|
748
|
+
|
|
749
|
+
.ft-checkbox--checked .ft-checkbox--checkmark,
|
|
750
|
+
.ft-checkbox--indeterminate .ft-checkbox--checkmark {
|
|
751
|
+
opacity: 1;
|
|
752
|
+
}
|
|
753
|
+
`,Si([i()],Ni.prototype,"name",void 0),Si([i({type:Boolean})],Ni.prototype,"checked",void 0),Si([i({type:Boolean})],Ni.prototype,"indeterminate",void 0),Si([i({type:Boolean})],Ni.prototype,"disabled",void 0),Si([n(".ft-checkbox")],Ni.prototype,"container",void 0),Si([n("ft-ripple")],Ni.prototype,"ripple",void 0),c("ft-checkbox")(Ni);var Fi=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 Ri=ft.extend("--ft-radio-text-color",bt.colorOnSurfaceHigh),Mi=ft.external(bt.colorPrimary,"Design system"),Li=(ft.external(bt.colorOnPrimary,"Design system"),ft.extend("--ft-radio-border-color",bt.colorOnSurfaceMedium)),Di=ft.external(bt.colorOnSurfaceDisabled,"Design system");class ji extends CustomEvent{constructor(t,e){super("change",{detail:{value:t,checked:e},bubbles:!0,composed:!0})}}class Ii extends vt{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 K`
|
|
754
|
+
<div class="${Dt(t)}">
|
|
755
|
+
<div class="ft-radio--box-container">
|
|
756
|
+
<input id="radio-button"
|
|
757
|
+
type="radio"
|
|
758
|
+
name="${this.name}"
|
|
759
|
+
value="${this.value}"
|
|
760
|
+
.checked=${this.checked}
|
|
761
|
+
.disabled=${this.disabled}
|
|
762
|
+
@change=${this.onChange}
|
|
763
|
+
>
|
|
764
|
+
<ft-ripple
|
|
765
|
+
?disabled=${this.disabled}
|
|
766
|
+
?primary=${this.checked}
|
|
767
|
+
unbounded>
|
|
768
|
+
</ft-ripple>
|
|
769
|
+
<div class="ft-radio--box">
|
|
770
|
+
</div>
|
|
771
|
+
</div>
|
|
772
|
+
<label for="radio-button" @click=${t=>t.stopPropagation()}>
|
|
773
|
+
<ft-typography variant="body2">
|
|
774
|
+
<slot></slot>
|
|
775
|
+
</ft-typography>
|
|
776
|
+
</label>
|
|
777
|
+
</div>
|
|
778
|
+
`}onChange(t){t.stopPropagation(),this.checked=t.target.checked,this.dispatchEvent(new ji(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 ji(this.value,this.checked)),this.focus()}focus(){var t;null===(t=this.input)||void 0===t||t.focus()}}Ii.elementDefinitions={"ft-ripple":Ye,"ft-typography":Ze},Ii.styles=v`
|
|
779
|
+
* {
|
|
780
|
+
box-sizing: border-box;
|
|
781
|
+
}
|
|
782
|
+
|
|
783
|
+
.ft-radio {
|
|
784
|
+
box-sizing: border-box;
|
|
785
|
+
color: ${Ri};
|
|
786
|
+
|
|
787
|
+
display: inline-flex;
|
|
788
|
+
align-items: center;
|
|
789
|
+
gap: 4px;
|
|
790
|
+
}
|
|
791
|
+
|
|
792
|
+
.ft-radio--disabled {
|
|
793
|
+
color: ${Di};
|
|
794
|
+
}
|
|
795
|
+
|
|
796
|
+
input {
|
|
797
|
+
opacity: 0;
|
|
798
|
+
position: absolute;
|
|
799
|
+
width: 40px;
|
|
800
|
+
height: 40px;
|
|
801
|
+
margin: 0;
|
|
802
|
+
}
|
|
803
|
+
|
|
804
|
+
.ft-radio--box-container {
|
|
805
|
+
position: relative;
|
|
806
|
+
width: 40px;
|
|
807
|
+
height: 40px;
|
|
808
|
+
|
|
809
|
+
display: flex;
|
|
810
|
+
justify-content: center;
|
|
811
|
+
align-items: center;
|
|
812
|
+
flex-shrink: 0;
|
|
813
|
+
}
|
|
814
|
+
|
|
815
|
+
.ft-radio--box {
|
|
816
|
+
border: 2px solid ${Li};
|
|
817
|
+
border-radius: 50%;
|
|
818
|
+
|
|
819
|
+
display: flex;
|
|
820
|
+
justify-content: center;
|
|
821
|
+
align-items: center;
|
|
822
|
+
|
|
823
|
+
width: 20px;
|
|
824
|
+
height: 20px;
|
|
825
|
+
}
|
|
826
|
+
|
|
827
|
+
.ft-radio--box:after {
|
|
828
|
+
content: " ";
|
|
829
|
+
background-color: ${Mi};
|
|
830
|
+
|
|
831
|
+
border-radius: 50%;
|
|
832
|
+
|
|
833
|
+
width: 12px;
|
|
834
|
+
height: 12px;
|
|
835
|
+
|
|
836
|
+
transform: scale(0);
|
|
837
|
+
transition: transform 100ms ease;
|
|
838
|
+
}
|
|
839
|
+
|
|
840
|
+
.ft-radio--checked .ft-radio--box {
|
|
841
|
+
border-color: ${Mi};
|
|
842
|
+
}
|
|
843
|
+
|
|
844
|
+
|
|
845
|
+
.ft-radio--checked .ft-radio--box:after {
|
|
846
|
+
transform: scale(1);
|
|
847
|
+
}
|
|
848
|
+
|
|
849
|
+
.ft-radio--disabled .ft-radio--box {
|
|
850
|
+
border-color: ${Di};
|
|
851
|
+
background-color: transparent;
|
|
852
|
+
}
|
|
853
|
+
|
|
854
|
+
.ft-radio--disabled .ft-radio--box:after {
|
|
855
|
+
background-color: ${Di};
|
|
856
|
+
}
|
|
857
|
+
`,Fi([i()],Ii.prototype,"value",void 0),Fi([i()],Ii.prototype,"name",void 0),Fi([i({type:Boolean})],Ii.prototype,"checked",void 0),Fi([i({type:Boolean})],Ii.prototype,"disabled",void 0),Fi([n(".ft-radio")],Ii.prototype,"container",void 0),Fi([n("ft-ripple")],Ii.prototype,"ripple",void 0),Fi([n("input")],Ii.prototype,"input",void 0);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};class Ti extends vt{constructor(){super(...arguments),this.name=""}render(){return K`
|
|
858
|
+
<slot @slotchange=${this.onSlotChange}
|
|
859
|
+
@change=${this.onChange}
|
|
860
|
+
@keydown=${this.onKeyDown}
|
|
861
|
+
@focusin=${this.onFocusIn}
|
|
862
|
+
></slot>
|
|
863
|
+
`}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)}}Ti.elementDefinitions={},Ti.styles=v`
|
|
864
|
+
:host {
|
|
865
|
+
display: contents;
|
|
866
|
+
}
|
|
867
|
+
`,Ui([i()],Ti.prototype,"name",void 0),Ui([a()],Ti.prototype,"radioButtons",void 0),c("ft-radio")(Ii),c("ft-radio-group")(Ti);var Ai=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 Pi={borderRadiusM:ft.external(bt.borderRadiusM,"Design system"),colorOutline:ft.external(bt.colorOutline,"Design system"),colorOnSurface:ft.external(bt.colorOnSurface,"Design system"),colorOnSurfaceMedium:ft.external(bt.colorOnSurfaceMedium,"Design system"),colorOnSurfaceDisabled:ft.external(bt.colorOnSurfaceDisabled,"Design system"),colorPrimary:ft.external(bt.colorPrimary,"Design system"),colorOnPrimary:ft.external(bt.colorOnPrimary,"Design system"),fontFamily:ft.external(ye.fontFamily,"Body2 typography"),fontSize:ft.external(ye.fontSize,"Body2 typography"),fontWeight:ft.external(ye.fontWeight,"Body2 typography"),letterSpacing:ft.external(ye.letterSpacing,"Body2 typography"),lineHeight:ft.external(ye.lineHeight,"Body2 typography"),textTransform:ft.external(ye.textTransform,"Body2 typography")};class _i extends vt{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 K`
|
|
974
868
|
<div class="ft-filter-level--container ${this.disabled?"ft-filter--disabled":""}">
|
|
975
|
-
${null==this.parent?null:
|
|
869
|
+
${null==this.parent?null:K`
|
|
976
870
|
<div tabindex="0"
|
|
977
871
|
class="ft-filter-level--go-back"
|
|
978
872
|
?disabled=${this.disabled}
|
|
979
873
|
@keyup=${this.goBackOnKeyPress}
|
|
980
874
|
@click=${this.goBackOnClick}>
|
|
981
875
|
<ft-ripple></ft-ripple>
|
|
982
|
-
<
|
|
876
|
+
<ft-icon variant="material">chevron_left</ft-icon>
|
|
983
877
|
<ft-typography variant="body2">${this.parent.label}</ft-typography>
|
|
984
878
|
</div>
|
|
985
879
|
`}
|
|
986
|
-
${Lt(e,(t=>t.value),(t=>{var e;return
|
|
880
|
+
${Lt(e,(t=>t.value),(t=>{var e;return K`
|
|
987
881
|
<div class="ft-filter-level--option" part="options">
|
|
988
882
|
${this.multivalued?this.buildMultiValuedOption(t):this.buildMonoValuedOption(t)}
|
|
989
|
-
${this.preventNavigation||t.selected||0===(null!==(e=t.subOptions)&&void 0!==e?e:[]).length?
|
|
883
|
+
${this.preventNavigation||t.selected||0===(null!==(e=t.subOptions)&&void 0!==e?e:[]).length?V:K`
|
|
990
884
|
<ft-button icon="chevron_right"
|
|
991
885
|
label="${t.label}"
|
|
992
886
|
?disabled=${this.disabled}
|
|
@@ -995,7 +889,7 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
995
889
|
`}
|
|
996
890
|
</div>
|
|
997
891
|
`}))}
|
|
998
|
-
${e.length<t.length?
|
|
892
|
+
${e.length<t.length?K`
|
|
999
893
|
<ft-button
|
|
1000
894
|
class="ft-filter-level--display-more"
|
|
1001
895
|
icon="expand_more"
|
|
@@ -1003,29 +897,27 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1003
897
|
@click=${this.displayMore}>
|
|
1004
898
|
${this.moreValuesButtonLabel}
|
|
1005
899
|
</ft-button>
|
|
1006
|
-
`:
|
|
900
|
+
`:V}
|
|
1007
901
|
</div>
|
|
1008
|
-
`}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
|
|
1009
|
-
<
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
</mwc-formfield>
|
|
1028
|
-
`}optionsChanged(t,e){t.stopPropagation(),this.dispatchEvent(new CustomEvent("change",{detail:e}))}displayLevel(t){this.dispatchEvent(new CustomEvent("display-level",{detail:t}))}}ur.elementDefinitions={"ft-button":Gi,"ft-ripple":Bi,"ft-typography":Ke,"mwc-checkbox":Ci,"mwc-formfield":ir,"mwc-icon":Ai,"mwc-radio":hr},ur.styles=[x`
|
|
902
|
+
`}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 K`
|
|
903
|
+
<ft-checkbox name="${this.id}"
|
|
904
|
+
.checked=${t.selected}
|
|
905
|
+
.disabled=${this.disabled}
|
|
906
|
+
.indeterminate=${Ke(null!==(e=t.subOptions)&&void 0!==e?e:[],(t=>{var e;return null!==(e=t.subOptions)&&void 0!==e?e:[]})).some((t=>t.selected))}
|
|
907
|
+
@change=${e=>this.optionsChanged(e,t)}>
|
|
908
|
+
${t.label}
|
|
909
|
+
</ft-checkbox>
|
|
910
|
+
`}buildMonoValuedOption(t){return K`
|
|
911
|
+
<ft-radio name="${this.id+Math.round(1e6*Math.random())}"
|
|
912
|
+
.checked=${t.selected}
|
|
913
|
+
?disabled=${this.disabled}
|
|
914
|
+
@click=${e=>this.optionsChanged(e,t)}
|
|
915
|
+
@keyup=${e=>this.onRadioKeyUp(e,t)}
|
|
916
|
+
@change=${t=>t.stopPropagation()}>
|
|
917
|
+
|
|
918
|
+
${t.label}
|
|
919
|
+
</ft-radio>
|
|
920
|
+
`}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}))}}_i.elementDefinitions={"ft-button":ki,"ft-ripple":Ye,"ft-typography":Ze,"ft-checkbox":Ni,"ft-icon":vi,"ft-radio":Ii},_i.styles=[v`
|
|
1029
921
|
.ft-filter-level--container {
|
|
1030
922
|
display: flex;
|
|
1031
923
|
flex-direction: column;
|
|
@@ -1039,21 +931,21 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1039
931
|
flex-shrink: 0;
|
|
1040
932
|
text-decoration: none;
|
|
1041
933
|
position: relative;
|
|
1042
|
-
border-radius: ${
|
|
934
|
+
border-radius: ${Pi.borderRadiusM};
|
|
1043
935
|
overflow: hidden;
|
|
1044
936
|
display: flex;
|
|
1045
937
|
align-items: center;
|
|
1046
938
|
padding: 4px 4px;
|
|
1047
939
|
gap: 4px;
|
|
1048
940
|
cursor: pointer;
|
|
1049
|
-
color: ${
|
|
941
|
+
color: ${Pi.colorOnSurface};
|
|
1050
942
|
}
|
|
1051
943
|
|
|
1052
944
|
.ft-filter-level--go-back:focus {
|
|
1053
945
|
outline: none;
|
|
1054
946
|
}
|
|
1055
947
|
|
|
1056
|
-
.ft-filter-level--go-back
|
|
948
|
+
.ft-filter-level--go-back ft-icon {
|
|
1057
949
|
flex-shrink: 0;
|
|
1058
950
|
}
|
|
1059
951
|
|
|
@@ -1075,41 +967,18 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1075
967
|
}
|
|
1076
968
|
|
|
1077
969
|
ft-button {
|
|
1078
|
-
${
|
|
970
|
+
${ut(yi.color,Pi.colorOnSurface)};
|
|
1079
971
|
}
|
|
1080
972
|
|
|
1081
|
-
|
|
973
|
+
ft-radio, ft-checkbox {
|
|
1082
974
|
flex-shrink: 1;
|
|
1083
975
|
flex-grow: 1;
|
|
1084
976
|
display: block;
|
|
1085
977
|
max-width: calc(100% + 10px);
|
|
1086
978
|
margin-left: -10px;
|
|
1087
979
|
word-break: break-word;
|
|
1088
|
-
|
|
1089
|
-
--mdc-theme-secondary: ${fr.colorPrimary};
|
|
1090
|
-
|
|
1091
|
-
--mdc-radio-unchecked-color: ${fr.colorOnSurfaceMedium};
|
|
1092
|
-
--mdc-checkbox-unchecked-color: ${fr.colorOnSurfaceMedium};
|
|
1093
|
-
--mdc-checkbox-ink-color: ${fr.colorOnPrimary};
|
|
1094
|
-
|
|
1095
|
-
--mdc-radio-disabled-color: ${fr.colorOnSurfaceDisabled};
|
|
1096
|
-
--mdc-checkbox-disabled-color: ${fr.colorOnSurfaceDisabled};
|
|
1097
|
-
|
|
1098
|
-
--mdc-theme-on-surface: ${fr.colorPrimary};
|
|
1099
|
-
|
|
1100
|
-
--mdc-typography-body2-font-family: ${fr.fontFamily};
|
|
1101
|
-
--mdc-typography-body2-font-size: ${fr.fontSize};
|
|
1102
|
-
--mdc-typography-body2-font-weight: ${fr.fontWeight};
|
|
1103
|
-
--mdc-typography-body2-letter-spacing: ${fr.letterSpacing};
|
|
1104
|
-
--mdc-typography-body2-line-height: ${fr.lineHeight};
|
|
1105
|
-
--mdc-typography-body2-text-transform: ${fr.textTransform};
|
|
1106
|
-
--mdc-theme-text-primary-on-background: ${fr.colorOnSurface};
|
|
1107
|
-
}
|
|
1108
|
-
|
|
1109
|
-
.ft-filter--disabled {
|
|
1110
|
-
--mdc-theme-text-primary-on-background: ${fr.colorOnSurfaceDisabled};
|
|
1111
980
|
}
|
|
1112
|
-
`],
|
|
981
|
+
`],Ai([i({type:String})],_i.prototype,"id",void 0),Ai([i({type:Object})],_i.prototype,"parent",void 0),Ai([i({type:Array})],_i.prototype,"options",void 0),Ai([i({type:Boolean})],_i.prototype,"multivalued",void 0),Ai([i({type:Boolean})],_i.prototype,"disabled",void 0),Ai([i({type:Boolean})],_i.prototype,"hideSelectedOptions",void 0),Ai([i({type:Boolean})],_i.prototype,"preventNavigation",void 0),Ai([i({type:String})],_i.prototype,"filter",void 0),Ai([i({type:String})],_i.prototype,"moreValuesButtonLabel",void 0),Ai([i({type:Number})],_i.prototype,"displayedValuesLimit",void 0),Ai([n(".ft-filter-level--container")],_i.prototype,"container",void 0),Ai([o()],_i.prototype,"displayedPages",void 0);var Hi=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={buttonsColor:ft.extend("--ft-snap-scroll-buttons-color",bt.colorPrimary),buttonsZIndex:ft.create("--ft-snap-scroll-buttons-z-index","COLOR","1"),gap:ft.create("--ft-snap-scroll-gap","SIZE","0"),colorSurface:ft.external(bt.colorSurface,"Design system")};class Ki extends CustomEvent{constructor(t,e){super("current-element-change",{detail:{index:t,element:e}})}}class Wi extends vt{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 t(200),this.updateScrollDebouncer=new t(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=Dt({"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":wt}),e=this.controls&&this.withScroll;return K`
|
|
1113
982
|
<div part="container" class="${t}">
|
|
1114
983
|
<ft-button
|
|
1115
984
|
class="ft-snap-scroll--previous"
|
|
@@ -1133,7 +1002,7 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1133
1002
|
@click=${this.next}
|
|
1134
1003
|
></ft-button>
|
|
1135
1004
|
</div>
|
|
1136
|
-
`}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
|
|
1005
|
+
`}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 Ki(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)}}Wi.elementDefinitions={"ft-button":ki},Wi.styles=v`
|
|
1137
1006
|
.ft-snap-scroll {
|
|
1138
1007
|
box-sizing: border-box;
|
|
1139
1008
|
position: relative;
|
|
@@ -1168,7 +1037,7 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1168
1037
|
flex-wrap: nowrap;
|
|
1169
1038
|
align-items: flex-start;
|
|
1170
1039
|
justify-content: flex-start;
|
|
1171
|
-
gap: ${
|
|
1040
|
+
gap: ${Zi.gap};
|
|
1172
1041
|
}
|
|
1173
1042
|
|
|
1174
1043
|
.ft-snap-scroll--hide-scrollbar .ft-snap-scroll--content::-webkit-scrollbar {
|
|
@@ -1211,11 +1080,11 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1211
1080
|
.ft-snap-scroll--next {
|
|
1212
1081
|
position: absolute;
|
|
1213
1082
|
display: flex;
|
|
1214
|
-
z-index: ${
|
|
1083
|
+
z-index: ${Zi.buttonsZIndex};
|
|
1215
1084
|
opacity: 1;
|
|
1216
1085
|
transition: background-color .5s ease-in-out, opacity .5s ease-in-out, z-index .5s ease-in-out;
|
|
1217
|
-
${
|
|
1218
|
-
${
|
|
1086
|
+
${ut(yi.backgroundColor,"transparent")};
|
|
1087
|
+
${ut(yi.color,Zi.buttonsColor)};
|
|
1219
1088
|
}
|
|
1220
1089
|
|
|
1221
1090
|
.ft-snap-scroll--previous[hidden],
|
|
@@ -1228,55 +1097,55 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1228
1097
|
top: 0;
|
|
1229
1098
|
left: -1px;
|
|
1230
1099
|
bottom: 0;
|
|
1231
|
-
background: linear-gradient(to right, ${
|
|
1100
|
+
background: linear-gradient(to right, ${Zi.colorSurface} 50%, var(--ft-snap-scroll-transparent-color));
|
|
1232
1101
|
}
|
|
1233
1102
|
|
|
1234
1103
|
.ft-snap-scroll--vertical .ft-snap-scroll--previous {
|
|
1235
1104
|
top: -1px;
|
|
1236
1105
|
left: 0;
|
|
1237
1106
|
right: 0;
|
|
1238
|
-
background: linear-gradient(to bottom, ${
|
|
1107
|
+
background: linear-gradient(to bottom, ${Zi.colorSurface} 50%, var(--ft-snap-scroll-transparent-color));
|
|
1239
1108
|
}
|
|
1240
1109
|
|
|
1241
1110
|
.ft-snap-scroll--horizontal .ft-snap-scroll--next {
|
|
1242
1111
|
top: 0;
|
|
1243
1112
|
right: -1px;
|
|
1244
1113
|
bottom: 0;
|
|
1245
|
-
background: linear-gradient(to left, ${
|
|
1114
|
+
background: linear-gradient(to left, ${Zi.colorSurface} 50%, var(--ft-snap-scroll-transparent-color));
|
|
1246
1115
|
}
|
|
1247
1116
|
|
|
1248
1117
|
.ft-snap-scroll--vertical .ft-snap-scroll--next {
|
|
1249
1118
|
left: 0;
|
|
1250
1119
|
right: 0;
|
|
1251
1120
|
bottom: -1px;
|
|
1252
|
-
background: linear-gradient(to top, ${
|
|
1121
|
+
background: linear-gradient(to top, ${Zi.colorSurface} 50%, var(--ft-snap-scroll-transparent-color));
|
|
1253
1122
|
}
|
|
1254
1123
|
|
|
1255
1124
|
.ft-snap-scroll--horizontal .ft-snap-scroll--previous:hover,
|
|
1256
1125
|
.ft-snap-scroll--horizontal .ft-snap-scroll--next:hover,
|
|
1257
1126
|
.ft-snap-scroll--vertical .ft-snap-scroll--previous:hover,
|
|
1258
1127
|
.ft-snap-scroll--vertical .ft-snap-scroll--next:hover {
|
|
1259
|
-
background-color: ${
|
|
1128
|
+
background-color: ${Zi.colorSurface};
|
|
1260
1129
|
}
|
|
1261
|
-
`,
|
|
1130
|
+
`,Hi([i({type:Boolean})],Wi.prototype,"horizontal",void 0),Hi([i({type:Boolean})],Wi.prototype,"hideScrollbar",void 0),Hi([i({type:Boolean})],Wi.prototype,"controls",void 0),Hi([i({type:Boolean})],Wi.prototype,"limitSize",void 0),Hi([o()],Wi.prototype,"elements",void 0),Hi([o()],Wi.prototype,"currentElement",void 0),Hi([o()],Wi.prototype,"withScroll",void 0),Hi([o()],Wi.prototype,"startReached",void 0),Hi([o()],Wi.prototype,"endReached",void 0),Hi([n(".ft-snap-scroll--content")],Wi.prototype,"contentSlot",void 0),c("ft-snap-scroll")(Wi);var Vi=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 qi=ft.external(bt.colorOutline,"Design system"),Ji=ft.external(bt.colorOnSurface,"Design system"),Xi=ft.external(bt.colorOnSurfaceMedium,"Design system"),Yi=ft.external(bt.colorPrimary,"Design system"),Qi=ft.external(bt.colorSurface,"Design system"),Gi=ft.external(bt.transitionDuration,"Design system"),to=ft.external(bt.transitionTimingFunction,"Design system");class eo extends CustomEvent{constructor(t){super("change",{detail:t})}}class io extends vt{constructor(){super(...arguments),this.id="",this.label="",this.filterPlaceHolder="Filter {0}",this.clearButtonLabel="Clear",this.moreValuesButtonLabel="More",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 t(300),this.changeDebouncer=new t(10)}get flatOptions(){return Ke(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 K`
|
|
1262
1131
|
<div class="ft-filter--container ${this.disabled?"ft-filter--disabled":""}"
|
|
1263
1132
|
part="container">
|
|
1264
|
-
${this.label||i?
|
|
1133
|
+
${this.label||i?K`
|
|
1265
1134
|
<div class="ft-filter--header" part="header">
|
|
1266
1135
|
<ft-typography class="ft-filter--label" variant="overline" part="label">${this.label}
|
|
1267
1136
|
</ft-typography>
|
|
1268
|
-
${i?
|
|
1137
|
+
${i?K`
|
|
1269
1138
|
<ft-button icon="close" dense @click=${this.clear} part="clear-button">
|
|
1270
1139
|
${this.clearButtonLabel}
|
|
1271
1140
|
</ft-button>
|
|
1272
1141
|
`:null}
|
|
1273
1142
|
</div>
|
|
1274
1143
|
`:null}
|
|
1275
|
-
<div class="ft-filter--filter" ?hidden=${!
|
|
1144
|
+
<div class="ft-filter--filter" ?hidden=${!o}>
|
|
1276
1145
|
<input type="search"
|
|
1277
1146
|
part="input"
|
|
1278
1147
|
class="ft-typography--caption"
|
|
1279
|
-
?disabled=${!
|
|
1148
|
+
?disabled=${!o}
|
|
1280
1149
|
placeholder="${this.filterPlaceHolder.replace("{0}",this.label)}"
|
|
1281
1150
|
@keyup=${this.onFilterChange}>
|
|
1282
1151
|
</div>
|
|
@@ -1287,8 +1156,8 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1287
1156
|
@slotchange=${this.updateOptionsFromSlot}
|
|
1288
1157
|
@option-change=${this.optionsChanged}></slot>
|
|
1289
1158
|
</div>
|
|
1290
|
-
`}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,
|
|
1291
|
-
${this.raiseSelectedOptions&&e.length>0?
|
|
1159
|
+
`}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 K`
|
|
1160
|
+
${this.raiseSelectedOptions&&e.length>0?K`
|
|
1292
1161
|
<ft-filter-level
|
|
1293
1162
|
id="${this.id}"
|
|
1294
1163
|
?multivalued=${this.multivalued}
|
|
@@ -1303,10 +1172,10 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1303
1172
|
<ft-snap-scroll horizontal hideScrollbar
|
|
1304
1173
|
class="ft-filter--levels"
|
|
1305
1174
|
@current-element-change=${t=>this.levelsScrollDebouncer.run((()=>{for(;t.detail.index<this.displayedLevels.length;)this.displayedLevels.pop();this.requestUpdate()}))}>
|
|
1306
|
-
${this.renderLevel(
|
|
1307
|
-
${this.displayedLevels.map((e=>t.find((t=>t.value===e)))).map(((t,e)=>{var
|
|
1175
|
+
${this.renderLevel(o,this.options)}
|
|
1176
|
+
${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)}))}
|
|
1308
1177
|
</ft-snap-scroll>
|
|
1309
|
-
`}renderLevel(t,e,i){return
|
|
1178
|
+
`}renderLevel(t,e,i){return K`
|
|
1310
1179
|
<ft-filter-level
|
|
1311
1180
|
class="${t}"
|
|
1312
1181
|
id="${this.id}"
|
|
@@ -1323,7 +1192,7 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1323
1192
|
@display-level=${this.onDisplayLevel}
|
|
1324
1193
|
part="values"
|
|
1325
1194
|
></ft-filter-level>
|
|
1326
|
-
`}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
|
|
1195
|
+
`}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 eo(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(t){const e=t.composedPath()[0];this.filter=e.value}updateScroll(){this.valuesContainer&&(this.withScroll=this.valuesContainer.scrollHeight>this.valuesContainer.clientHeight)}}io.elementDefinitions={"ft-button":ki,"ft-filter-level":_i,"ft-snap-scroll":Wi,"ft-typography":Ze},io.styles=[Ae,v`
|
|
1327
1196
|
:host {
|
|
1328
1197
|
display: flex;
|
|
1329
1198
|
max-height: 100%;
|
|
@@ -1336,8 +1205,8 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1336
1205
|
flex-direction: column;
|
|
1337
1206
|
max-height: 100%;
|
|
1338
1207
|
max-width: 100%;
|
|
1339
|
-
color: ${
|
|
1340
|
-
background: ${
|
|
1208
|
+
color: ${Ji};
|
|
1209
|
+
background: ${Qi};
|
|
1341
1210
|
}
|
|
1342
1211
|
|
|
1343
1212
|
.ft-filter--header {
|
|
@@ -1347,13 +1216,13 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1347
1216
|
flex-shrink: 0;
|
|
1348
1217
|
padding: 0 10px;
|
|
1349
1218
|
margin-bottom: 8px;
|
|
1350
|
-
${
|
|
1219
|
+
${ut(Vt.fontSize,"14px")};
|
|
1351
1220
|
}
|
|
1352
1221
|
|
|
1353
1222
|
.ft-filter--header ft-button {
|
|
1354
1223
|
flex-shrink: 0;
|
|
1355
1224
|
margin-left: auto;
|
|
1356
|
-
${
|
|
1225
|
+
${ut(yi.iconSize,"18px")};
|
|
1357
1226
|
}
|
|
1358
1227
|
|
|
1359
1228
|
.ft-filter--label {
|
|
@@ -1361,8 +1230,8 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1361
1230
|
flex-shrink: 1;
|
|
1362
1231
|
flex-grow: 1;
|
|
1363
1232
|
word-break: break-word;
|
|
1364
|
-
${
|
|
1365
|
-
${
|
|
1233
|
+
${ut(Vt.lineHeight,"22px")};
|
|
1234
|
+
${ut(Vt.fontWeight,"bold")};
|
|
1366
1235
|
}
|
|
1367
1236
|
|
|
1368
1237
|
.ft-filter--filter {
|
|
@@ -1373,8 +1242,8 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1373
1242
|
padding: 0 10px;
|
|
1374
1243
|
overflow: hidden;
|
|
1375
1244
|
height: 32px;
|
|
1376
|
-
transition: height ${
|
|
1377
|
-
margin ${
|
|
1245
|
+
transition: height ${Gi} ${to},
|
|
1246
|
+
margin ${Gi} ${to};
|
|
1378
1247
|
transition-delay: 500ms;
|
|
1379
1248
|
}
|
|
1380
1249
|
|
|
@@ -1387,11 +1256,11 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1387
1256
|
display: block;
|
|
1388
1257
|
width: 100%;
|
|
1389
1258
|
border-radius: 4px;
|
|
1390
|
-
border: 1px solid ${
|
|
1259
|
+
border: 1px solid ${qi};
|
|
1391
1260
|
padding: 4px;
|
|
1392
|
-
background-color: ${
|
|
1393
|
-
color: ${
|
|
1394
|
-
outline-color: ${
|
|
1261
|
+
background-color: ${Qi};
|
|
1262
|
+
color: ${Xi};
|
|
1263
|
+
outline-color: ${Yi};
|
|
1395
1264
|
}
|
|
1396
1265
|
|
|
1397
1266
|
.ft-filter--values {
|
|
@@ -1403,7 +1272,7 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1403
1272
|
}
|
|
1404
1273
|
|
|
1405
1274
|
.ft-filter--separator {
|
|
1406
|
-
border-top: 1px solid ${
|
|
1275
|
+
border-top: 1px solid ${qi};
|
|
1407
1276
|
margin: 4px 10px;
|
|
1408
1277
|
}
|
|
1409
1278
|
|
|
@@ -1428,63 +1297,17 @@ const dr=x`.mdc-touch-target-wrapper{display:inline}.mdc-radio{padding:calc((40p
|
|
|
1428
1297
|
slot {
|
|
1429
1298
|
display: none;
|
|
1430
1299
|
}
|
|
1431
|
-
`],
|
|
1300
|
+
`],Vi([i({type:String})],io.prototype,"id",void 0),Vi([i({type:String})],io.prototype,"label",void 0),Vi([i({type:String})],io.prototype,"filterPlaceHolder",void 0),Vi([i({type:String})],io.prototype,"clearButtonLabel",void 0),Vi([i({type:String})],io.prototype,"moreValuesButtonLabel",void 0),Vi([h([])],io.prototype,"options",void 0),Vi([i({type:Boolean})],io.prototype,"multivalued",void 0),Vi([i({type:Boolean})],io.prototype,"disabled",void 0),Vi([i({type:Boolean})],io.prototype,"raiseSelectedOptions",void 0),Vi([i({type:Number})],io.prototype,"displayedValuesLimit",void 0),Vi([n(".ft-filter--slot")],io.prototype,"slotElement",void 0),Vi([n(".ft-filter--container")],io.prototype,"container",void 0),Vi([n(".ft-filter--values")],io.prototype,"valuesContainer",void 0),Vi([n(".ft-filter--levels")],io.prototype,"levelsContainer",void 0),Vi([n(".ft-filter--levels ft-filter-level:last-child")],io.prototype,"lastLevel",void 0),Vi([function(t){return s({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")],io.prototype,"levels",void 0),Vi([o()],io.prototype,"withScroll",void 0),Vi([o()],io.prototype,"filter",void 0),Vi([o()],io.prototype,"slideIn",void 0),Vi([o()],io.prototype,"slideOut",void 0);var oo=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 so extends vt{constructor(){super(...arguments),this.label="",this.value=null,this.selected=!1,this.subOptions=[]}render(){return K`
|
|
1432
1301
|
<slot class="ft-filter-option--slot" @slotchange=${this.updateSubOptionsFromSlot}></slot>
|
|
1433
|
-
`}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}))}}
|
|
1434
|
-
/**
|
|
1435
|
-
* @license
|
|
1436
|
-
* Copyright 2017 Google LLC
|
|
1437
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
1438
|
-
*/
|
|
1439
|
-
class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===X||null==t)return this.vt=void 0,this.it=t;if(t===G)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this.vt;this.it=t;const e=[t];return e.raw=e,this.vt={_$litType$:this.constructor.resultType,strings:e,values:[]}}}Br.directiveName="unsafeHTML",Br.resultType=1;const Fr=Ct(Br);var Ar,Nr;!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=""}(Ar||(Ar={})),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=""}(Nr||(Nr={}));const Tr=new Map([...["abw"].map((t=>[t,Nr.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,Nr.AUDIO])),...["avi"].map((t=>[t,Nr.AVI])),...["chm","xhs"].map((t=>[t,Nr.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,Nr.CODE])),...["csv"].map((t=>[t,Nr.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,Nr.DITA])),...["epub"].map((t=>[t,Nr.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,Nr.EXCEL])),...["flac"].map((t=>[t,Nr.FLAC])),...["gif"].map((t=>[t,Nr.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,Nr.GZIP])),...["html","htm","xhtml"].map((t=>[t,Nr.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,Nr.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,Nr.JPEG])),...["json"].map((t=>[t,Nr.JSON])),...["m4a","m4p"].map((t=>[t,Nr.M4A])),...["mov","qt"].map((t=>[t,Nr.MOV])),...["mp3"].map((t=>[t,Nr.MP3])),...["mp4","m4v"].map((t=>[t,Nr.MP4])),...["ogg","oga"].map((t=>[t,Nr.OGG])),...["pdf","ps"].map((t=>[t,Nr.PDF])),...["png"].map((t=>[t,Nr.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,Nr.POWERPOINT])),...["rar"].map((t=>[t,Nr.RAR])),...["stp"].map((t=>[t,Nr.STP])),...["txt","rtf","md","mdown"].map((t=>[t,Nr.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,Nr.VIDEO])),...["wav"].map((t=>[t,Nr.WAV])),...["wma"].map((t=>[t,Nr.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,Nr.WORD])),...["xml","xsl","rdf"].map((t=>[t,Nr.XML])),...["yaml","yml","x-yaml"].map((t=>[t,Nr.YAML])),...["zip"].map((t=>[t,Nr.ZIP]))]),Mr=new Map([["application/msword","application/doc"],["application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/docx"],["application/vnd.openxmlformats-officedocument.wordprocessingml.template","application/dotx"],["application/vnd.ms-word.document.macroEnabled.12","application/docm"],["application/vnd.ms-word.template.macroEnabled.12","application/dotm"],["application/vnd.ms-excel","application/xls"],["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/xlsx"],["application/vnd.openxmlformats-officedocument.spreadsheetml.template","application/xltx"],["application/vnd.ms-excel.sheet.macroEnabled.12","application/xlsm"],["application/vnd.ms-excel.template.macroEnabled.12","application/xltm"],["application/vnd.ms-excel.addin.macroEnabled.12","application/xlam"],["application/vnd.ms-excel.sheet.binary.macroEnabled.12","application/xlsb"],["application/vnd.ms-powerpoint","application/ppt"],["application/vnd.openxmlformats-officedocument.presentationml.presentation","application/pptx"],["application/vnd.openxmlformats-officedocument.presentationml.template","application/potx"],["application/vnd.openxmlformats-officedocument.presentationml.slideshow","application/ppsx"],["application/vnd.ms-powerpoint.addin.macroEnabled.12","application/ppam"],["application/vnd.ms-powerpoint.presentation.macroEnabled.12","application/pptm"],["application/vnd.ms-powerpoint.template.macroEnabled.12","application/potm"],["application/vnd.ms-powerpoint.slideshow.macroEnabled.12","application/ppsm"],["application/vnd.ms-access","application/mdb"]]);var Lr,Dr=function(t,e,i,r){for(var o,n=arguments.length,a=n<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,i):r,c=t.length-1;c>=0;c--)(o=t[c])&&(a=(n<3?o(a):n>3?o(e,i,a):o(e,i))||a);return n>3&&a&&Object.defineProperty(e,i,a),a};!function(t){t.fluid_topics="fluid-topics",t.file_format="file-format"}(Lr||(Lr={}));const Ir=bt.create("--ft-icon-font-size","SIZE","24px"),jr=bt.extend("--ft-icon-fluid-topics-font-family",bt.create("--ft-icon-font-family","UNKNOWN","ft-icons")),Ur=bt.extend("--ft-icon-file-format-font-family",bt.create("--ft-icon-font-family","UNKNOWN","ft-mime")),Pr=x`
|
|
1440
|
-
.ft-icon--fluid-topics {
|
|
1441
|
-
font-family: ${jr}, ft-icons, fticons, sans-serif;
|
|
1442
|
-
font-size: ${Ir};
|
|
1443
|
-
line-height: 1;
|
|
1444
|
-
font-weight: normal;
|
|
1445
|
-
text-transform: none;
|
|
1446
|
-
font-style: normal;
|
|
1447
|
-
font-variant: normal;
|
|
1448
|
-
speak: none;
|
|
1449
|
-
text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.004);
|
|
1450
|
-
text-rendering: auto;
|
|
1451
|
-
-webkit-font-smoothing: antialiased;
|
|
1452
|
-
-moz-osx-font-smoothing: grayscale;
|
|
1453
|
-
}
|
|
1454
|
-
`,Hr=x`
|
|
1455
|
-
.ft-icon--file-format {
|
|
1456
|
-
font-family: ${Ur}, ft-mime, sans-serif;
|
|
1457
|
-
font-size: ${Ir};
|
|
1458
|
-
line-height: 1;
|
|
1459
|
-
font-weight: normal;
|
|
1460
|
-
text-transform: none;
|
|
1461
|
-
font-style: normal;
|
|
1462
|
-
font-variant: normal;
|
|
1463
|
-
speak: none;
|
|
1464
|
-
text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.004);
|
|
1465
|
-
text-rendering: auto;
|
|
1466
|
-
-webkit-font-smoothing: antialiased;
|
|
1467
|
-
-moz-osx-font-smoothing: grayscale;
|
|
1468
|
-
}
|
|
1469
|
-
`;class Vr extends xt{constructor(){super(...arguments),this.variant=Lr.fluid_topics}render(){return q`
|
|
1470
|
-
<slot @slotchange=${()=>this.requestUpdate()} hidden></slot>
|
|
1471
|
-
<i class="ft-icon ${"ft-icon--"+this.variant}">${Fr(this.getIcon())}</i>
|
|
1472
|
-
`}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;return this.variant===Lr.file_format?null!==(t=Nr[this.textContent.toUpperCase()])&&void 0!==t?t:this.textContent:null!==(e=Ar[this.textContent.toUpperCase()])&&void 0!==e?e:this.textContent}}Vr.elementDefinitions={},Vr.styles=[Pr,Hr,x`
|
|
1473
|
-
:host, i.ft-icon {
|
|
1474
|
-
display: inline-block;
|
|
1475
|
-
width: ${Ir};
|
|
1476
|
-
height: ${Ir};
|
|
1477
|
-
text-align: center;
|
|
1478
|
-
}
|
|
1479
|
-
`],Dr([r()],Vr.prototype,"variant",void 0),Dr([c("slot")],Vr.prototype,"slottedContent",void 0),p("ft-icon")(Vr);var Zr=function(t,e,i,r){for(var o,n=arguments.length,a=n<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,i):r,c=t.length-1;c>=0;c--)(o=t[c])&&(a=(n<3?o(a):n>3?o(e,i,a):o(e,i))||a);return n>3&&a&&Object.defineProperty(e,i,a),a};class Wr extends xt{constructor(){super(...arguments),this.multi=!1}render(){return q`
|
|
1302
|
+
`}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}))}}so.elementDefinitions={},oo([i({type:String})],so.prototype,"label",void 0),oo([i({type:Object,converter:t=>t})],so.prototype,"value",void 0),oo([i({type:Boolean,reflect:!0})],so.prototype,"selected",void 0),oo([i({type:Object})],so.prototype,"subOptions",void 0),oo([n(".ft-filter-option--slot")],so.prototype,"slotElement",void 0),c("ft-filter")(io),c("ft-filter-option")(so);var no=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 ro extends vt{constructor(){super(...arguments),this.multi=!1}render(){return K`
|
|
1480
1303
|
<div class="ft-accordion">
|
|
1481
1304
|
<slot @activated=${this.onChange}></slot>
|
|
1482
1305
|
</div>
|
|
1483
|
-
`}onChange(t){t.stopPropagation(),this.multi||this.content.assignedElements().forEach((e=>e.active=e===t.target))}}
|
|
1306
|
+
`}onChange(t){t.stopPropagation(),this.multi||this.content.assignedElements().forEach((e=>e.active=e===t.target))}}ro.elementDefinitions={},ro.styles=v`
|
|
1484
1307
|
.ft-accordion {
|
|
1485
1308
|
box-sizing: border-box;
|
|
1486
1309
|
}
|
|
1487
|
-
`,
|
|
1310
|
+
`,no([i({type:Boolean})],ro.prototype,"multi",void 0),no([n("slot")],ro.prototype,"content",void 0);var lo=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 ao=ft.create("--ft-accordion-toggle-horizontal-spacing","SIZE","16px"),co=ft.create("--ft-accordion-toggle-vertical-spacing","SIZE","16px"),ho=ft.external(bt.colorOutline,"Design system");class po extends vt{constructor(){super(...arguments),this.icon="",this.label="",this.active=!1}render(){return K`
|
|
1488
1311
|
<div class="ft-accordion-item ${this.active?"ft-accordion-item--active":""}">
|
|
1489
1312
|
<div class="ft-accordion-item--toggle"
|
|
1490
1313
|
part="toggle"
|
|
@@ -1492,23 +1315,23 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1492
1315
|
@keydown=${this.onToggleKeyDown}
|
|
1493
1316
|
tabindex="0">
|
|
1494
1317
|
<ft-ripple part="toggle-ripple"></ft-ripple>
|
|
1495
|
-
${this.icon?
|
|
1496
|
-
<
|
|
1318
|
+
${this.icon?K`
|
|
1319
|
+
<ft-icon variant="material">${this.icon}</ft-icon>
|
|
1497
1320
|
`:null}
|
|
1498
|
-
${this.label?
|
|
1321
|
+
${this.label?K`
|
|
1499
1322
|
<ft-typography class="ft-accordion-item--label" variant="body1" part="label">${this.label}
|
|
1500
1323
|
</ft-typography>
|
|
1501
|
-
`:
|
|
1324
|
+
`:K`
|
|
1502
1325
|
<slot class="ft-accordion-item--label" name="toggle" part="label"></slot>
|
|
1503
1326
|
`}
|
|
1504
|
-
<
|
|
1327
|
+
<ft-icon variant="material">${this.active?"expand_less":"expand_more"}</ft-icon>
|
|
1505
1328
|
</div>
|
|
1506
1329
|
<div class="ft-accordion-item--content" part="content" @focusin=${()=>this.active=!0}>
|
|
1507
1330
|
<slot></slot>
|
|
1508
1331
|
</div>
|
|
1509
1332
|
<div class="ft-accordion-item--separator" part="separator"></div>
|
|
1510
1333
|
</div>
|
|
1511
|
-
`}update(t){super.update(t),t.has("active")&&this.active&&this.dispatchEvent(new Event("activated",{composed:!0,bubbles:!0}))}onToggleKeyDown(t){"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),this.active=!this.active)}}
|
|
1334
|
+
`}update(t){super.update(t),t.has("active")&&this.active&&this.dispatchEvent(new Event("activated",{composed:!0,bubbles:!0}))}onToggleKeyDown(t){"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),this.active=!this.active)}}po.elementDefinitions={"ft-ripple":Ye,"ft-typography":Ze,"ft-icon":vi},po.styles=v`
|
|
1512
1335
|
.ft-accordion-item {
|
|
1513
1336
|
display: flex;
|
|
1514
1337
|
flex-direction: column;
|
|
@@ -1521,8 +1344,8 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1521
1344
|
display: flex;
|
|
1522
1345
|
align-items: center;
|
|
1523
1346
|
cursor: pointer;
|
|
1524
|
-
padding: ${
|
|
1525
|
-
gap: calc(${
|
|
1347
|
+
padding: ${co} ${ao};
|
|
1348
|
+
gap: calc(${ao} / 2);
|
|
1526
1349
|
outline: none;
|
|
1527
1350
|
}
|
|
1528
1351
|
|
|
@@ -1543,13 +1366,13 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1543
1366
|
.ft-accordion-item--active .ft-accordion-item--content {
|
|
1544
1367
|
height: initial;
|
|
1545
1368
|
overflow: visible;
|
|
1546
|
-
padding: ${
|
|
1369
|
+
padding: ${co} ${ao};
|
|
1547
1370
|
}
|
|
1548
1371
|
|
|
1549
1372
|
.ft-accordion-item--separator {
|
|
1550
|
-
border-bottom: 1px solid ${
|
|
1373
|
+
border-bottom: 1px solid ${ho};
|
|
1551
1374
|
}
|
|
1552
|
-
`,
|
|
1375
|
+
`,lo([i({type:String})],po.prototype,"icon",void 0),lo([i({type:String})],po.prototype,"label",void 0),lo([i({type:Boolean,reflect:!0})],po.prototype,"active",void 0),c("ft-accordion")(ro),c("ft-accordion-item")(po);var fo=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 uo=ft.extend("--ft-chip-color",bt.colorOnSurface),bo={backgroundColor:ft.extend("--ft-chip-background-color",bt.colorSurface),color:uo,fontSize:ft.extend("--ft-chip-font-size",ye.fontSize),iconSize:ft.create("--ft-chip-icon-size","SIZE","18px"),rippleColor:ft.extend("--ft-chip-ripple-color",uo),horizontalPadding:ft.create("--ft-chip-horizontal-padding","SIZE","6px"),verticalPadding:ft.create("--ft-chip-vertical-padding","SIZE","6px"),colorOutline:ft.external(bt.colorOutline,"Design system"),opacityDisabled:ft.external(bt.colorOpacityDisabled,"Design system")},vo=ft.extend("--ft-chip-highlighted-color",ft.extend("--ft-chip-color",bt.colorOnPrimary)),go={backgroundColor:ft.extend("--ft-chip-highlighted-background-color",ft.extend("--ft-chip-background-color",bt.colorPrimary)),color:vo,rippleColor:ft.extend("--ft-chip-highlighted-ripple-color",vo)},xo=ft.create("--ft-chip-dense-horizontal-padding","SIZE","4px"),yo=ft.create("--ft-chip-dense-vertical-padding","SIZE","4px");class mo extends CustomEvent{constructor(){super("icon-click")}}class $o extends vt{constructor(){super(...arguments),this.highlighted=!1,this.removable=!1,this.disabled=!1,this.clickable=!1,this.iconClickable=!1,this.dense=!1,this.multiLine=!1,this.label="",this.icon=void 0,this.trailingIcon=!1}static get styles(){return[gt,v`
|
|
1553
1376
|
:host {
|
|
1554
1377
|
display: inline-block;
|
|
1555
1378
|
max-width: 100%;
|
|
@@ -1566,27 +1389,27 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1566
1389
|
box-sizing: border-box;
|
|
1567
1390
|
pointer-events: auto;
|
|
1568
1391
|
|
|
1569
|
-
--ft-chip-internal-font-size: ${
|
|
1392
|
+
--ft-chip-internal-font-size: ${bo.fontSize};
|
|
1570
1393
|
--ft-chip-internal-line-height: max(20px, calc(var(--ft-chip-internal-font-size) + 2px));
|
|
1571
|
-
|
|
1572
|
-
--ft-chip-internal-vertical-padding: ${
|
|
1573
|
-
--ft-chip-internal-horizontal-padding: ${
|
|
1394
|
+
${ut(bi.size,bo.iconSize)};
|
|
1395
|
+
--ft-chip-internal-vertical-padding: ${bo.verticalPadding};
|
|
1396
|
+
--ft-chip-internal-horizontal-padding: ${bo.horizontalPadding};
|
|
1574
1397
|
--ft-chip-internal-icon-padding: 3px;
|
|
1575
|
-
--ft-chip-internal-content-height: max(var(--ft-chip-internal-line-height),
|
|
1398
|
+
--ft-chip-internal-content-height: max(var(--ft-chip-internal-line-height), ${bo.iconSize});
|
|
1576
1399
|
|
|
1577
|
-
border: 1px solid ${
|
|
1578
|
-
color: ${
|
|
1579
|
-
${
|
|
1400
|
+
border: 1px solid ${bo.colorOutline};
|
|
1401
|
+
color: ${bo.color};
|
|
1402
|
+
${ut(Xe.color,bo.rippleColor)};
|
|
1580
1403
|
border-radius: calc(var(--ft-chip-internal-content-height) / 2 + var(--ft-chip-internal-vertical-padding));
|
|
1581
1404
|
padding: calc(var(--ft-chip-internal-vertical-padding) - 1px) calc(var(--ft-chip-internal-horizontal-padding) - 1px);
|
|
1582
|
-
background-color: ${
|
|
1405
|
+
background-color: ${bo.backgroundColor};
|
|
1583
1406
|
line-height: var(--ft-chip-internal-content-height);
|
|
1584
1407
|
}
|
|
1585
1408
|
|
|
1586
1409
|
.ft-chip--dense {
|
|
1587
1410
|
--ft-chip-internal-icon-padding: 3px;
|
|
1588
|
-
--ft-chip-internal-vertical-padding: ${
|
|
1589
|
-
--ft-chip-internal-horizontal-padding: ${
|
|
1411
|
+
--ft-chip-internal-vertical-padding: ${yo};
|
|
1412
|
+
--ft-chip-internal-horizontal-padding: ${xo};
|
|
1590
1413
|
--ft-chip-internal-line-height: max(16px, calc(var(--ft-chip-internal-font-size) + 2px));
|
|
1591
1414
|
}
|
|
1592
1415
|
|
|
@@ -1598,15 +1421,15 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1598
1421
|
cursor: default;
|
|
1599
1422
|
pointer-events: none;
|
|
1600
1423
|
filter: grayscale(1);
|
|
1601
|
-
opacity: ${
|
|
1424
|
+
opacity: ${bo.opacityDisabled};
|
|
1602
1425
|
}
|
|
1603
1426
|
|
|
1604
1427
|
.ft-chip--highlighted {
|
|
1605
1428
|
border: none;
|
|
1606
1429
|
padding: var(--ft-chip-internal-vertical-padding) var(--ft-chip-internal-horizontal-padding);
|
|
1607
|
-
background-color: ${
|
|
1608
|
-
${
|
|
1609
|
-
color: ${
|
|
1430
|
+
background-color: ${go.backgroundColor};
|
|
1431
|
+
${ut(Xe.color,go.rippleColor)};
|
|
1432
|
+
color: ${go.color};
|
|
1610
1433
|
}
|
|
1611
1434
|
|
|
1612
1435
|
.ft-chip--clickable {
|
|
@@ -1635,8 +1458,8 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1635
1458
|
vertical-align: bottom;
|
|
1636
1459
|
display: block;
|
|
1637
1460
|
margin: 0 var(--ft-chip-internal-horizontal-padding);
|
|
1638
|
-
${
|
|
1639
|
-
${
|
|
1461
|
+
${ut(ye.fontSize,"var(--ft-chip-internal-font-size)")};
|
|
1462
|
+
${ut(ye.lineHeight,"var(--ft-chip-internal-content-height)")};
|
|
1640
1463
|
}
|
|
1641
1464
|
|
|
1642
1465
|
.ft-chip--safari-fix .ft-chip--label {
|
|
@@ -1671,7 +1494,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1671
1494
|
.ft-chip:not(.ft-chip--trailing-icon) .ft-chip--icon-container {
|
|
1672
1495
|
order: -1;
|
|
1673
1496
|
}
|
|
1674
|
-
`]}render(){const t={"ft-chip":!0,"ft-chip--highlighted":this.highlighted,"ft-chip--disabled":this.disabled,"ft-chip--clickable":this.interactionsOnChip,"ft-chip--trailing-icon":this.trailingIcon||this.removable,"ft-chip--no-content":!this.hasTextContent(),"ft-chip--dense":this.dense,"ft-chip--multi-line":this.multiLine,"ft-chip--safari-fix":
|
|
1497
|
+
`]}render(){const t={"ft-chip":!0,"ft-chip--highlighted":this.highlighted,"ft-chip--disabled":this.disabled,"ft-chip--clickable":this.interactionsOnChip,"ft-chip--trailing-icon":this.trailingIcon||this.removable,"ft-chip--no-content":!this.hasTextContent(),"ft-chip--dense":this.dense,"ft-chip--multi-line":this.multiLine,"ft-chip--safari-fix":wt};return K`
|
|
1675
1498
|
<div class="${Dt(t)}"
|
|
1676
1499
|
aria-label="${this.getLabel()}"
|
|
1677
1500
|
tabindex="${this.interactionsOnChip?0:-1}"
|
|
@@ -1682,24 +1505,24 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1682
1505
|
</ft-typography>
|
|
1683
1506
|
${this.internalIcon?this.renderIcon():null}
|
|
1684
1507
|
</div>
|
|
1685
|
-
`}get interactionsOnChip(){return this.clickable&&!this.disabled}get interactionsOnIcon(){return(this.iconClickable||this.removable)&&!this.disabled}renderIcon(){return
|
|
1508
|
+
`}get interactionsOnChip(){return this.clickable&&!this.disabled}get interactionsOnIcon(){return(this.iconClickable||this.removable)&&!this.disabled}renderIcon(){return K`
|
|
1686
1509
|
<div class="ft-chip--icon-container ft-no-text-select ${this.interactionsOnIcon?"ft-chip--clickable":""}"
|
|
1687
1510
|
tabindex="${this.interactionsOnIcon?0:-1}"
|
|
1688
1511
|
@click=${this.onIconClick}
|
|
1689
1512
|
@keyup=${this.onIconKeyUp}>
|
|
1690
1513
|
<ft-ripple ?disabled=${!this.interactionsOnIcon}></ft-ripple>
|
|
1691
|
-
<
|
|
1514
|
+
<ft-icon variant="material">${this.internalIcon}</ft-icon>
|
|
1692
1515
|
</div>
|
|
1693
|
-
`}onKeyUp(t){this.interactionsOnChip&&["Enter"," "].includes(t.key)&&t.target.click()}onIconKeyUp(t){this.interactionsOnIcon&&["Enter"," "].includes(t.key)&&(t.stopPropagation(),this.dispatchEvent(new
|
|
1516
|
+
`}onKeyUp(t){this.interactionsOnChip&&["Enter"," "].includes(t.key)&&t.target.click()}onIconKeyUp(t){this.interactionsOnIcon&&["Enter"," "].includes(t.key)&&(t.stopPropagation(),this.dispatchEvent(new mo))}onIconClick(t){this.interactionsOnIcon&&(t.stopPropagation(),this.dispatchEvent(new mo))}getLabel(){return this.label||this.textContent}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:""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}get internalIcon(){return this.icon||(this.removable?"cancel":void 0)}}$o.elementDefinitions={"ft-ripple":Ye,"ft-typography":Ze,"ft-icon":vi},fo([i({type:Boolean})],$o.prototype,"highlighted",void 0),fo([i({type:Boolean})],$o.prototype,"removable",void 0),fo([i({type:Boolean})],$o.prototype,"disabled",void 0),fo([i({type:Boolean})],$o.prototype,"clickable",void 0),fo([i({type:Boolean})],$o.prototype,"iconClickable",void 0),fo([i({type:Boolean})],$o.prototype,"dense",void 0),fo([i({type:Boolean})],$o.prototype,"multiLine",void 0),fo([i({type:String})],$o.prototype,"label",void 0),fo([i({type:String})],$o.prototype,"icon",void 0),fo([i({type:Boolean})],$o.prototype,"trailingIcon",void 0),fo([n("ft-typography slot")],$o.prototype,"slottedContent",void 0),c("ft-chip")($o);var wo=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 ko={fontSize:ft.create("--ft-input-label-font-size","SIZE","14px"),raisedFontSize:ft.create("--ft-input-label-raised-font-size","SIZE","11px"),raisedZIndex:ft.create("--ft-input-label-outlined-raised-z-index","NUMBER","2"),verticalSpacing:ft.create("--ft-input-label-vertical-spacing","SIZE","4px"),horizontalSpacing:ft.create("--ft-input-label-horizontal-spacing","SIZE","12px"),borderColor:ft.extend("--ft-input-label-border-color",bt.colorOutline),textColor:ft.extend("--ft-input-label-text-color",bt.colorOnSurfaceMedium),disabledTextColor:ft.extend("--ft-input-label-disabled-text-color",bt.colorOnSurfaceDisabled),colorSurface:ft.external(bt.colorSurface,"Design system"),borderRadiusS:ft.external(bt.borderRadiusS,"Design system")};class So extends vt{constructor(){super(...arguments),this.text="",this.raised=!1,this.outlined=!1,this.disabled=!1}render(){const t={"ft-input-label":!0,"ft-input-label--raised":this.raised,"ft-input-label--outlined":this.outlined,"ft-input-label--disabled":this.disabled};return K`
|
|
1694
1517
|
<div class="${Dt(t)}">
|
|
1695
|
-
${this.text?
|
|
1518
|
+
${this.text?K`
|
|
1696
1519
|
<div class="ft-input-label--text ft-typography--caption">
|
|
1697
1520
|
<span class="ft-input-label--floating-text">${this.text}</span>
|
|
1698
1521
|
<span class="ft-input-label--hidden-text" aria-hidden="true">${this.text}</span>
|
|
1699
1522
|
</div>
|
|
1700
1523
|
`:null}
|
|
1701
1524
|
</div>
|
|
1702
|
-
`}}
|
|
1525
|
+
`}}So.elementDefinitions={},So.styles=[Ae,v`
|
|
1703
1526
|
.ft-input-label {
|
|
1704
1527
|
position: absolute;
|
|
1705
1528
|
inset: 0;
|
|
@@ -1707,7 +1530,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1707
1530
|
}
|
|
1708
1531
|
|
|
1709
1532
|
.ft-input-label {
|
|
1710
|
-
border-color: ${
|
|
1533
|
+
border-color: ${ko.borderColor};
|
|
1711
1534
|
}
|
|
1712
1535
|
|
|
1713
1536
|
.ft-input-label:before,
|
|
@@ -1720,7 +1543,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1720
1543
|
}
|
|
1721
1544
|
|
|
1722
1545
|
.ft-input-label:before {
|
|
1723
|
-
width: ${
|
|
1546
|
+
width: ${ko.horizontalSpacing};
|
|
1724
1547
|
flex-shrink: 0;
|
|
1725
1548
|
}
|
|
1726
1549
|
|
|
@@ -1736,14 +1559,14 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1736
1559
|
border-bottom-width: 1px;
|
|
1737
1560
|
border-bottom-style: solid;
|
|
1738
1561
|
border-color: inherit;
|
|
1739
|
-
color: ${
|
|
1562
|
+
color: ${ko.textColor};
|
|
1740
1563
|
transition: font-size 250ms, line-height 250ms, color 250ms;
|
|
1741
|
-
${
|
|
1742
|
-
${
|
|
1564
|
+
${ut(me.fontSize,ko.fontSize)};
|
|
1565
|
+
${ut(me.lineHeight,ko.fontSize)};
|
|
1743
1566
|
}
|
|
1744
1567
|
|
|
1745
1568
|
.ft-input-label--disabled .ft-input-label--text {
|
|
1746
|
-
color: ${
|
|
1569
|
+
color: ${ko.disabledTextColor};
|
|
1747
1570
|
}
|
|
1748
1571
|
|
|
1749
1572
|
.ft-input-label--hidden-text {
|
|
@@ -1759,17 +1582,17 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1759
1582
|
overflow: hidden;
|
|
1760
1583
|
white-space: nowrap;
|
|
1761
1584
|
text-overflow: ellipsis;
|
|
1762
|
-
padding: ${
|
|
1763
|
-
margin: calc(${
|
|
1585
|
+
padding: ${ko.verticalSpacing} 4px;
|
|
1586
|
+
margin: calc(${ko.verticalSpacing} * -1) 0;
|
|
1764
1587
|
}
|
|
1765
1588
|
|
|
1766
1589
|
.ft-input-label--raised .ft-input-label--text {
|
|
1767
|
-
${
|
|
1768
|
-
${
|
|
1590
|
+
${ut(me.fontSize,ko.raisedFontSize)};
|
|
1591
|
+
${ut(me.lineHeight,ko.raisedFontSize)};
|
|
1769
1592
|
}
|
|
1770
1593
|
|
|
1771
1594
|
.ft-input-label--raised .ft-input-label--floating-text {
|
|
1772
|
-
top: ${
|
|
1595
|
+
top: ${ko.verticalSpacing};
|
|
1773
1596
|
}
|
|
1774
1597
|
|
|
1775
1598
|
.ft-input-label--outlined .ft-input-label--text,
|
|
@@ -1782,48 +1605,48 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1782
1605
|
.ft-input-label--outlined:before {
|
|
1783
1606
|
border-left-width: 1px;
|
|
1784
1607
|
border-left-style: solid;
|
|
1785
|
-
border-radius: ${
|
|
1608
|
+
border-radius: ${ko.borderRadiusS} 0 0 ${ko.borderRadiusS};
|
|
1786
1609
|
}
|
|
1787
1610
|
|
|
1788
1611
|
.ft-input-label--outlined:after {
|
|
1789
1612
|
border-right-width: 1px;
|
|
1790
1613
|
border-right-style: solid;
|
|
1791
|
-
border-radius: 0 ${
|
|
1614
|
+
border-radius: 0 ${ko.borderRadiusS} ${ko.borderRadiusS} 0;
|
|
1792
1615
|
}
|
|
1793
1616
|
|
|
1794
1617
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--floating-text {
|
|
1795
1618
|
padding: 2px 4px;
|
|
1796
|
-
z-index: ${
|
|
1797
|
-
background-color: ${
|
|
1798
|
-
border-radius: ${
|
|
1619
|
+
z-index: ${ko.raisedZIndex};
|
|
1620
|
+
background-color: ${ko.colorSurface};
|
|
1621
|
+
border-radius: ${ko.borderRadiusS};
|
|
1799
1622
|
top: calc((var(--ft-typography-caption-line-height) / -2) + 2px);
|
|
1800
1623
|
}
|
|
1801
1624
|
|
|
1802
1625
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--text {
|
|
1803
1626
|
border-top: none;
|
|
1804
1627
|
}
|
|
1805
|
-
`],
|
|
1806
|
-
<div class="${Dt(
|
|
1628
|
+
`],wo([i({type:String})],So.prototype,"text",void 0),wo([i({type:Boolean})],So.prototype,"raised",void 0),wo([i({type:Boolean})],So.prototype,"outlined",void 0),wo([i({type:Boolean})],So.prototype,"disabled",void 0),c("ft-input-label")(So);var Oo=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 Co extends vt{constructor(){super(...arguments),this.label="",this.value=null,this.selected=!1}render(){return K``}updated(t){super.updated(t),this.dispatchEvent(new CustomEvent("option-change",{detail:this,bubbles:!0}))}}Co.elementDefinitions={},Oo([i({type:String})],Co.prototype,"label",void 0),Oo([i({type:Object,converter:t=>t})],Co.prototype,"value",void 0),Oo([i({type:Boolean,reflect:!0})],Co.prototype,"selected",void 0);const zo={labelSize:ft.create("--ft-select-label-size","SIZE","11px"),selectedOptionSize:ft.create("--ft-select-selected-option-size","SIZE","14px"),verticalSpacing:ft.create("--ft-select-vertical-spacing","SIZE","4px"),selectedOptionColor:ft.extend("--ft-select-selected-option-color",bt.colorOnSurface),helperColor:ft.extend("--ft-select-helper-color",bt.colorOnSurfaceMedium),optionsColor:ft.extend("--ft-select-options-color",bt.colorOnSurface),optionsZIndex:ft.create("--ft-select-options-z-index","NUMBER","2"),colorSurface:ft.external(bt.colorSurface,"Design system"),colorOnSurfaceDisabled:ft.external(bt.colorOnSurfaceDisabled,"Design system"),colorPrimary:ft.external(bt.colorPrimary,"Design system"),borderRadiusS:ft.external(bt.borderRadiusS,"Design system"),elevation02:ft.external(bt.elevation02,"Design system")};class Eo extends vt{constructor(){super(...arguments),this.label="",this.helper="",this.outlined=!1,this.disabled=!1,this.options=[],this.optionsDisplayed=!1,this.focusOptions=!1,this.hideOptions=t=>this.optionsDisplayed=this.optionsDisplayed&&t.composedPath().includes(this.container)}render(){var t,e,i,o,s;let n=!this.disabled&&this.optionsDisplayed&&this.hasOptions,r=this.disabled||!this.hasOptions;const l=null!=(null===(t=this.selectedOption)||void 0===t?void 0:t.value)||(null!==(i=null===(e=this.selectedOption)||void 0===e?void 0:e.label)&&void 0!==i?i:"").length>0,a={"ft-select":!0,"ft-select--filled":!this.outlined,"ft-select--outlined":this.outlined,"ft-select--disabled":r,"ft-select--options-displayed":n,"ft-select--has-option-selected":l,"ft-select--no-label":!this.label};return K`
|
|
1629
|
+
<div class="${Dt(a)}" part="container">
|
|
1807
1630
|
<div class="ft-select--main-panel" part="main-panel">
|
|
1808
1631
|
<ft-input-label text="${this.label}"
|
|
1809
1632
|
part="label"
|
|
1810
|
-
?disabled=${
|
|
1633
|
+
?disabled=${r}
|
|
1811
1634
|
?outlined=${this.outlined}
|
|
1812
|
-
?raised=${
|
|
1635
|
+
?raised=${l||n}
|
|
1813
1636
|
></ft-input-label>
|
|
1814
1637
|
<div class="ft-select--input-panel"
|
|
1815
1638
|
part="selected-value"
|
|
1816
|
-
tabindex="${
|
|
1639
|
+
tabindex="${r?"-1":"0"}"
|
|
1817
1640
|
@click=${()=>{this.optionsDisplayed=!this.optionsDisplayed,this.focusOptions=this.optionsDisplayed}}
|
|
1818
1641
|
@keydown=${this.onMainPanelKeyDown}
|
|
1819
1642
|
aria-label="${this.label}"
|
|
1820
1643
|
aria-haspopup="listbox"
|
|
1821
1644
|
aria-expanded="${n}">
|
|
1822
|
-
<ft-ripple ?disabled=${
|
|
1645
|
+
<ft-ripple ?disabled=${r} ?activated=${!this.outlined}></ft-ripple>
|
|
1823
1646
|
<ft-typography variant="body1" class="ft-select--selected-option">
|
|
1824
|
-
${null!==(
|
|
1647
|
+
${null!==(s=null===(o=this.selectedOption)||void 0===o?void 0:o.label)&&void 0!==s?s:""}
|
|
1825
1648
|
</ft-typography>
|
|
1826
|
-
<
|
|
1649
|
+
<ft-icon variant="material">${n?"expand_less":"expand_more"}</ft-icon>
|
|
1827
1650
|
</div>
|
|
1828
1651
|
<div class="ft-select--options"
|
|
1829
1652
|
part="options"
|
|
@@ -1832,14 +1655,14 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1832
1655
|
${Lt(this.options,(t=>t.value),(t=>this.renderOption(t)))}
|
|
1833
1656
|
</div>
|
|
1834
1657
|
</div>
|
|
1835
|
-
${this.helper?
|
|
1658
|
+
${this.helper?K`
|
|
1836
1659
|
<ft-typography class="ft-select--helper-text" variant="caption">${this.helper}
|
|
1837
1660
|
</ft-typography>`:void 0}
|
|
1838
1661
|
</div>
|
|
1839
1662
|
<slot @slotchange=${this.updateOptionsFromSlot}
|
|
1840
1663
|
@option-change=${this.updateOptionsFromSlot}
|
|
1841
1664
|
></slot>
|
|
1842
|
-
`}renderOption(t){let e=this.selectedOption===t;return
|
|
1665
|
+
`}renderOption(t){let e=this.selectedOption===t;return K`
|
|
1843
1666
|
<div class="${Dt({"ft-select--option":!0,"ft-select--option-selected":e,"ft-typography--body2":!0})}"
|
|
1844
1667
|
part="option"
|
|
1845
1668
|
tabindex="0"
|
|
@@ -1848,7 +1671,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1848
1671
|
<ft-ripple ?primary=${e} ?activated=${e}></ft-ripple>
|
|
1849
1672
|
${t.label}
|
|
1850
1673
|
</div>
|
|
1851
|
-
`}updated(t){var e;super.updated(t),t.has("options")&&(this.selectedOption=this.options.filter((t=>t.selected))[0]),t.has("selectedOption")&&(this.optionsDisplayed=!1,this.dispatchEvent(new CustomEvent("change",{detail:null===(e=this.selectedOption)||void 0===e?void 0:e.value})))}contentAvailableCallback(t){var e,i;t.has("focusOptions")&&this.focusOptions&&(null===(i=null!==(e=this.selectedOptionElement)&&void 0!==e?e:this.firstOption)||void 0===i||i.focus(),this.focusOptions=!1)}get hasOptions(){return this.options.length>0}updateOptionsFromSlot(t){var e;t.stopPropagation();let i=null===(e=this.optionsSlot)||void 0===e?void 0:e.assignedElements().map((t=>t));i&&i.length>0&&(this.options=i)}onMainPanelKeyDown(t){switch(t.key){case" ":t.preventDefault(),t.stopPropagation();case"Enter":this.optionsDisplayed=!this.optionsDisplayed,this.focusOptions=!0;break;case"ArrowUp":case"ArrowDown":t.preventDefault(),t.stopPropagation(),this.optionsDisplayed=!0,this.focusOptions=!0}}onOptionsKeyDown(t){var e,i,
|
|
1674
|
+
`}updated(t){var e;super.updated(t),t.has("options")&&(this.selectedOption=this.options.filter((t=>t.selected))[0]),t.has("selectedOption")&&(this.optionsDisplayed=!1,this.dispatchEvent(new CustomEvent("change",{detail:null===(e=this.selectedOption)||void 0===e?void 0:e.value})))}contentAvailableCallback(t){var e,i;t.has("focusOptions")&&this.focusOptions&&(null===(i=null!==(e=this.selectedOptionElement)&&void 0!==e?e:this.firstOption)||void 0===i||i.focus(),this.focusOptions=!1)}get hasOptions(){return this.options.length>0}updateOptionsFromSlot(t){var e;t.stopPropagation();let i=null===(e=this.optionsSlot)||void 0===e?void 0:e.assignedElements().map((t=>t));i&&i.length>0&&(this.options=i)}onMainPanelKeyDown(t){switch(t.key){case" ":t.preventDefault(),t.stopPropagation();case"Enter":this.optionsDisplayed=!this.optionsDisplayed,this.focusOptions=!0;break;case"ArrowUp":case"ArrowDown":t.preventDefault(),t.stopPropagation(),this.optionsDisplayed=!0,this.focusOptions=!0}}onOptionsKeyDown(t){var e,i,o,s,n;let r;switch(t.key){case"Escape":this.optionsDisplayed=!1,null===(e=this.mainPanel)||void 0===e||e.focus();break;case"Tab":this.optionsDisplayed=!1;break;case"ArrowUp":t.preventDefault(),t.stopPropagation(),r=null!==(o=null===(i=this.focusedOption)||void 0===i?void 0:i.previousElementSibling)&&void 0!==o?o:this.lastOption;break;case"ArrowDown":t.preventDefault(),t.stopPropagation(),r=null!==(n=null===(s=this.focusedOption)||void 0===s?void 0:s.nextElementSibling)&&void 0!==n?n:this.firstOption}null==r||r.focus()}onOptionKeyDown(t,e){var i;"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),t.stopPropagation(),this.selectOption(e),this.optionsDisplayed=!1,null===(i=this.mainPanel)||void 0===i||i.focus())}selectOption(t){this.selectedOption=t;for(let e of this.options)e.selected=e===t}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.hideOptions)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.hideOptions)}}Eo.elementDefinitions={"ft-input-label":So,"ft-typography":Ze,"ft-ripple":Ye,"ft-icon":vi},Eo.styles=[Te,Ae,v`
|
|
1852
1675
|
*:focus {
|
|
1853
1676
|
outline: none;
|
|
1854
1677
|
}
|
|
@@ -1862,7 +1685,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1862
1685
|
.ft-select--main-panel {
|
|
1863
1686
|
position: relative;
|
|
1864
1687
|
display: flex;
|
|
1865
|
-
height: calc(4 * ${
|
|
1688
|
+
height: calc(4 * ${zo.verticalSpacing} + ${zo.labelSize} + ${zo.selectedOptionSize});
|
|
1866
1689
|
}
|
|
1867
1690
|
|
|
1868
1691
|
.ft-select--input-panel {
|
|
@@ -1874,19 +1697,19 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1874
1697
|
padding-left: 16px;
|
|
1875
1698
|
padding-right: 8px;
|
|
1876
1699
|
gap: 8px;
|
|
1877
|
-
color: ${
|
|
1878
|
-
${
|
|
1700
|
+
color: ${zo.selectedOptionColor};
|
|
1701
|
+
${ut(Xe.color,zo.selectedOptionColor)};
|
|
1879
1702
|
}
|
|
1880
1703
|
|
|
1881
1704
|
.ft-select--input-panel,
|
|
1882
1705
|
.ft-select--option {
|
|
1883
|
-
${
|
|
1884
|
-
${
|
|
1706
|
+
${ut(Xe.opacityContentOnSurfaceHover,"0.08")};
|
|
1707
|
+
${ut(Xe.opacityContentOnSurfacePressed,"0.04")};
|
|
1885
1708
|
}
|
|
1886
1709
|
|
|
1887
1710
|
.ft-select--disabled .ft-select--input-panel,
|
|
1888
1711
|
.ft-select--disabled .ft-select--option {
|
|
1889
|
-
color: ${
|
|
1712
|
+
color: ${zo.colorOnSurfaceDisabled};
|
|
1890
1713
|
}
|
|
1891
1714
|
|
|
1892
1715
|
.ft-select:not(.ft-select--disabled) .ft-select--input-panel,
|
|
@@ -1895,18 +1718,18 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1895
1718
|
}
|
|
1896
1719
|
|
|
1897
1720
|
ft-input-label {
|
|
1898
|
-
${
|
|
1899
|
-
${
|
|
1900
|
-
${
|
|
1721
|
+
${ut(ko.fontSize,zo.selectedOptionSize)};
|
|
1722
|
+
${ut(ko.raisedFontSize,zo.labelSize)};
|
|
1723
|
+
${ut(ko.verticalSpacing,zo.verticalSpacing)};
|
|
1901
1724
|
}
|
|
1902
1725
|
|
|
1903
|
-
.ft-select:not(.ft-select--disabled):focus-within
|
|
1904
|
-
color: ${
|
|
1726
|
+
.ft-select:not(.ft-select--disabled):focus-within ft-icon {
|
|
1727
|
+
color: ${zo.colorPrimary};
|
|
1905
1728
|
}
|
|
1906
1729
|
|
|
1907
1730
|
.ft-select:not(.ft-select--disabled):focus-within ft-input-label {
|
|
1908
|
-
${
|
|
1909
|
-
${
|
|
1731
|
+
${ut(ko.borderColor,zo.colorPrimary)};
|
|
1732
|
+
${ut(ko.textColor,zo.colorPrimary)};
|
|
1910
1733
|
}
|
|
1911
1734
|
|
|
1912
1735
|
.ft-select--selected-option {
|
|
@@ -1916,11 +1739,11 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1916
1739
|
overflow: hidden;
|
|
1917
1740
|
white-space: nowrap;
|
|
1918
1741
|
text-overflow: ellipsis;
|
|
1919
|
-
${
|
|
1920
|
-
${
|
|
1742
|
+
${ut(xe.fontSize,zo.selectedOptionSize)};
|
|
1743
|
+
${ut(xe.lineHeight,zo.selectedOptionSize)};
|
|
1921
1744
|
}
|
|
1922
1745
|
|
|
1923
|
-
|
|
1746
|
+
ft-icon {
|
|
1924
1747
|
flex-shrink: 0;
|
|
1925
1748
|
}
|
|
1926
1749
|
|
|
@@ -1929,16 +1752,16 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1929
1752
|
}
|
|
1930
1753
|
|
|
1931
1754
|
.ft-select--filled .ft-select--input-panel {
|
|
1932
|
-
border-radius: ${
|
|
1755
|
+
border-radius: ${zo.borderRadiusS} ${zo.borderRadiusS} 0 0;
|
|
1933
1756
|
}
|
|
1934
1757
|
|
|
1935
1758
|
.ft-select--filled:not(.ft-select--no-label) .ft-select--selected-option {
|
|
1936
1759
|
align-self: stretch;
|
|
1937
|
-
padding-top: calc(${
|
|
1760
|
+
padding-top: calc(${zo.labelSize} + 2 * ${zo.verticalSpacing});
|
|
1938
1761
|
}
|
|
1939
1762
|
|
|
1940
1763
|
.ft-select--outlined .ft-select--input-panel {
|
|
1941
|
-
border-radius: ${
|
|
1764
|
+
border-radius: ${zo.borderRadiusS};
|
|
1942
1765
|
}
|
|
1943
1766
|
|
|
1944
1767
|
.ft-select--options {
|
|
@@ -1947,10 +1770,10 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1947
1770
|
top: 100%;
|
|
1948
1771
|
left: 0;
|
|
1949
1772
|
right: 0;
|
|
1950
|
-
color: ${
|
|
1951
|
-
background: ${
|
|
1952
|
-
z-index: ${
|
|
1953
|
-
box-shadow: ${
|
|
1773
|
+
color: ${zo.optionsColor};
|
|
1774
|
+
background: ${zo.colorSurface};
|
|
1775
|
+
z-index: ${zo.optionsZIndex};
|
|
1776
|
+
box-shadow: ${zo.elevation02};
|
|
1954
1777
|
}
|
|
1955
1778
|
|
|
1956
1779
|
.ft-select--options-displayed .ft-select--options {
|
|
@@ -1967,9 +1790,9 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1967
1790
|
|
|
1968
1791
|
.ft-select--helper-text {
|
|
1969
1792
|
padding: 0 12px 0 16px;
|
|
1970
|
-
color: ${
|
|
1793
|
+
color: ${zo.helperColor};
|
|
1971
1794
|
}
|
|
1972
|
-
`],
|
|
1795
|
+
`],Oo([i({type:String})],Eo.prototype,"label",void 0),Oo([i({type:String})],Eo.prototype,"helper",void 0),Oo([i({type:Boolean})],Eo.prototype,"outlined",void 0),Oo([i({type:Boolean})],Eo.prototype,"disabled",void 0),Oo([i({type:Array})],Eo.prototype,"options",void 0),Oo([o()],Eo.prototype,"selectedOption",void 0),Oo([o()],Eo.prototype,"optionsDisplayed",void 0),Oo([o()],Eo.prototype,"focusOptions",void 0),Oo([n(".ft-select")],Eo.prototype,"container",void 0),Oo([n(".ft-select--input-panel")],Eo.prototype,"mainPanel",void 0),Oo([n(".ft-select--option:first-child")],Eo.prototype,"firstOption",void 0),Oo([n(".ft-select--option:focus")],Eo.prototype,"focusedOption",void 0),Oo([n(".ft-select--option.ft-select--option-selected")],Eo.prototype,"selectedOptionElement",void 0),Oo([n(".ft-select--option:last-child")],Eo.prototype,"lastOption",void 0),Oo([n("slot")],Eo.prototype,"optionsSlot",void 0),c("ft-select")(Eo),c("ft-select-option")(Co);const Bo={height:ft.create("--ft-search-bar-height","SIZE","38px"),borderRadius:ft.extend("--ft-search-bar-border-radius",bt.borderRadiusS),mobileOpenPosition:ft.create("--ft-search-bar-mobile-open-position","POSITION","fixed"),mobileOpenTop:ft.create("--ft-search-bar-mobile-open-top","SIZE","0"),mobileOpenBottom:ft.create("--ft-search-bar-mobile-open-bottom","SIZE","0"),mobileOpenLeft:ft.create("--ft-search-bar-mobile-open-left","SIZE","0"),mobileOpenRight:ft.create("--ft-search-bar-mobile-open-right","SIZE","0"),floatingZIndex:ft.create("--ft-search-bar-floating-components-z-index","NUMBER","2"),colorSurface:ft.external(bt.colorSurface,"Design system"),colorOnSurface:ft.external(bt.colorOnSurface,"Design system"),colorOnSurfaceMedium:ft.external(bt.colorOnSurfaceMedium,"Design system"),colorOutline:ft.external(bt.colorOutline,"Design system"),colorPrimary:ft.external(bt.colorPrimary,"Design system"),elevation02:ft.external(bt.elevation02,"Design system"),buttonColor:ft.external(yi.color,"Button"),buttonRippleColor:ft.external(yi.rippleColor,"Button")},No=v`
|
|
1973
1796
|
* {
|
|
1974
1797
|
box-sizing: border-box;
|
|
1975
1798
|
}
|
|
@@ -1978,7 +1801,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1978
1801
|
display: flex;
|
|
1979
1802
|
flex-direction: column;
|
|
1980
1803
|
gap: 8px;
|
|
1981
|
-
color: ${
|
|
1804
|
+
color: ${Bo.colorOnSurface};
|
|
1982
1805
|
outline: none;
|
|
1983
1806
|
}
|
|
1984
1807
|
|
|
@@ -1987,14 +1810,14 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
1987
1810
|
}
|
|
1988
1811
|
|
|
1989
1812
|
.ft-search-bar--mobile-menu-open {
|
|
1990
|
-
position: ${
|
|
1991
|
-
top: ${
|
|
1992
|
-
bottom: ${
|
|
1993
|
-
left: ${
|
|
1994
|
-
right: ${
|
|
1995
|
-
z-index: ${
|
|
1813
|
+
position: ${Bo.mobileOpenPosition};
|
|
1814
|
+
top: ${Bo.mobileOpenTop};
|
|
1815
|
+
bottom: ${Bo.mobileOpenBottom};
|
|
1816
|
+
left: ${Bo.mobileOpenLeft};
|
|
1817
|
+
right: ${Bo.mobileOpenRight};
|
|
1818
|
+
z-index: ${Bo.floatingZIndex};
|
|
1996
1819
|
padding: 16px;
|
|
1997
|
-
background: ${
|
|
1820
|
+
background: ${Bo.colorSurface};
|
|
1998
1821
|
}
|
|
1999
1822
|
|
|
2000
1823
|
.ft-search-bar {
|
|
@@ -2002,15 +1825,15 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2002
1825
|
display: flex;
|
|
2003
1826
|
flex-direction: row;
|
|
2004
1827
|
align-items: center;
|
|
2005
|
-
height: ${
|
|
1828
|
+
height: ${Bo.height};
|
|
2006
1829
|
|
|
2007
|
-
background: ${
|
|
2008
|
-
border: 1px solid ${
|
|
2009
|
-
border-radius: ${
|
|
1830
|
+
background: ${Bo.colorSurface};
|
|
1831
|
+
border: 1px solid ${Bo.colorOutline};
|
|
1832
|
+
border-radius: ${Bo.borderRadius};
|
|
2010
1833
|
}
|
|
2011
1834
|
|
|
2012
1835
|
.ft-search-bar--floating-panel-open .ft-search-bar {
|
|
2013
|
-
border-radius: ${
|
|
1836
|
+
border-radius: ${Bo.borderRadius} ${Bo.borderRadius} 0 0;
|
|
2014
1837
|
}
|
|
2015
1838
|
|
|
2016
1839
|
.ft-search-bar--input-container {
|
|
@@ -2028,7 +1851,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2028
1851
|
align-self: stretch;
|
|
2029
1852
|
display: grid;
|
|
2030
1853
|
padding: 0 8px;
|
|
2031
|
-
border-radius: ${
|
|
1854
|
+
border-radius: ${Bo.borderRadius};
|
|
2032
1855
|
}
|
|
2033
1856
|
|
|
2034
1857
|
.ft-search-bar--dense .ft-search-bar--input-outline {
|
|
@@ -2037,7 +1860,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2037
1860
|
}
|
|
2038
1861
|
|
|
2039
1862
|
.ft-search-bar--input-container:focus-within .ft-search-bar--input-outline {
|
|
2040
|
-
outline: 2px solid ${
|
|
1863
|
+
outline: 2px solid ${Bo.colorPrimary};
|
|
2041
1864
|
}
|
|
2042
1865
|
|
|
2043
1866
|
.ft-search-bar--input {
|
|
@@ -2058,8 +1881,8 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2058
1881
|
}
|
|
2059
1882
|
|
|
2060
1883
|
.ft-search-bar--left-action {
|
|
2061
|
-
${
|
|
2062
|
-
border-right: 1px solid ${
|
|
1884
|
+
${ut(yi.borderRadius,v`calc(${Bo.borderRadius} - 1px) 0 0 calc(${Bo.borderRadius} - 1px)`)};
|
|
1885
|
+
border-right: 1px solid ${Bo.colorOutline};
|
|
2063
1886
|
height: 100%;
|
|
2064
1887
|
}
|
|
2065
1888
|
|
|
@@ -2068,7 +1891,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2068
1891
|
}
|
|
2069
1892
|
|
|
2070
1893
|
.ft-search-bar--floating-panel-open .ft-search-bar--left-action {
|
|
2071
|
-
${
|
|
1894
|
+
${ut(yi.borderRadius,v`calc(${Bo.borderRadius} - 1px) 0 0 0`)};
|
|
2072
1895
|
}
|
|
2073
1896
|
|
|
2074
1897
|
.ft-search-bar .ft-search-bar--launch-search,
|
|
@@ -2078,13 +1901,13 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2078
1901
|
|
|
2079
1902
|
.ft-search-bar--separator {
|
|
2080
1903
|
height: 20px;
|
|
2081
|
-
border-right: 1px solid ${
|
|
1904
|
+
border-right: 1px solid ${Bo.colorOutline};
|
|
2082
1905
|
}
|
|
2083
1906
|
|
|
2084
1907
|
.ft-search-bar--left-action.ft-search-bar--content-locale {
|
|
2085
|
-
${
|
|
2086
|
-
${
|
|
2087
|
-
${
|
|
1908
|
+
${ut(ko.borderColor,"transparent")};
|
|
1909
|
+
${ut(ko.borderRadiusS,v`calc(${Bo.borderRadius} - 1px)`)};
|
|
1910
|
+
${ut(zo.selectedOptionColor,Bo.buttonColor)};
|
|
2088
1911
|
}
|
|
2089
1912
|
|
|
2090
1913
|
.ft-search-bar--left-action.ft-search-bar--content-locale,
|
|
@@ -2101,17 +1924,17 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2101
1924
|
}
|
|
2102
1925
|
|
|
2103
1926
|
.ft-search-bar--left-action.ft-search-bar--content-locale::part(selected-value) {
|
|
2104
|
-
border-radius: calc(${
|
|
1927
|
+
border-radius: calc(${Bo.borderRadius} - 1px) 0 0 calc(${Bo.borderRadius} - 1px);
|
|
2105
1928
|
}
|
|
2106
1929
|
|
|
2107
|
-
`,
|
|
1930
|
+
`,Fo=v`
|
|
2108
1931
|
.ft-search-bar--floating-panel .ft-search-bar--presets {
|
|
2109
1932
|
margin-right: auto;
|
|
2110
1933
|
}
|
|
2111
1934
|
|
|
2112
1935
|
.ft-search-bar--floating-panel .ft-search-bar--presets {
|
|
2113
1936
|
min-width: 250px;
|
|
2114
|
-
${
|
|
1937
|
+
${ut(zo.optionsZIndex,"2")};
|
|
2115
1938
|
}
|
|
2116
1939
|
|
|
2117
1940
|
.ft-search-bar--floating-panel {
|
|
@@ -2203,7 +2026,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2203
2026
|
|
|
2204
2027
|
.ft-search-bar--filter-label > :last-child {
|
|
2205
2028
|
flex-shrink: 1;
|
|
2206
|
-
color: ${
|
|
2029
|
+
color: ${Bo.colorOnSurfaceMedium};
|
|
2207
2030
|
}
|
|
2208
2031
|
|
|
2209
2032
|
ft-accordion-item::part(toggle) {
|
|
@@ -2223,7 +2046,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2223
2046
|
.ft-search-bar--floating-panel .ft-search-bar--launch-search {
|
|
2224
2047
|
margin: 0;
|
|
2225
2048
|
}
|
|
2226
|
-
`,
|
|
2049
|
+
`,Ro=v`
|
|
2227
2050
|
.ft-search-bar--selected-filters:not(ft-snap-scroll) {
|
|
2228
2051
|
flex-shrink: 0;
|
|
2229
2052
|
display: flex;
|
|
@@ -2234,7 +2057,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2234
2057
|
|
|
2235
2058
|
ft-snap-scroll.ft-search-bar--selected-filters {
|
|
2236
2059
|
overflow: hidden;
|
|
2237
|
-
${
|
|
2060
|
+
${ut(Zi.gap,"4px")};
|
|
2238
2061
|
}
|
|
2239
2062
|
|
|
2240
2063
|
ft-snap-scroll.ft-search-bar--selected-filters::part(content) {
|
|
@@ -2242,8 +2065,8 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2242
2065
|
}
|
|
2243
2066
|
|
|
2244
2067
|
.ft-search-bar--desktop ft-snap-scroll.ft-search-bar--selected-filters {
|
|
2245
|
-
${
|
|
2246
|
-
${
|
|
2068
|
+
${ut(bo.iconSize,"17px")};
|
|
2069
|
+
${ut(bo.fontSize,"12px")};
|
|
2247
2070
|
}
|
|
2248
2071
|
|
|
2249
2072
|
.ft-search-bar--selected-filters * {
|
|
@@ -2253,7 +2076,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2253
2076
|
.ft-search-bar--selected-filters ft-chip {
|
|
2254
2077
|
flex-grow: 0;
|
|
2255
2078
|
}
|
|
2256
|
-
`,
|
|
2079
|
+
`,Mo=v`
|
|
2257
2080
|
.ft-search-bar--mobile .ft-search-bar--suggestions {
|
|
2258
2081
|
flex-grow: 1;
|
|
2259
2082
|
flex-shrink: 1;
|
|
@@ -2262,7 +2085,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2262
2085
|
}
|
|
2263
2086
|
|
|
2264
2087
|
.ft-search-bar--mobile-menu-open .ft-search-bar--suggestions {
|
|
2265
|
-
border-top: 1px solid ${
|
|
2088
|
+
border-top: 1px solid ${Bo.colorOutline};
|
|
2266
2089
|
}
|
|
2267
2090
|
|
|
2268
2091
|
.ft-search-bar--mobile-menu-open .ft-search-bar--suggestions {
|
|
@@ -2277,10 +2100,10 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2277
2100
|
left: -1px;
|
|
2278
2101
|
right: -1px;
|
|
2279
2102
|
display: none;
|
|
2280
|
-
background: ${
|
|
2281
|
-
border: 1px solid ${
|
|
2282
|
-
border-radius: 0 0 ${
|
|
2283
|
-
box-shadow: ${
|
|
2103
|
+
background: ${Bo.colorSurface};
|
|
2104
|
+
border: 1px solid ${Bo.colorOutline};
|
|
2105
|
+
border-radius: 0 0 ${Bo.borderRadius} ${Bo.borderRadius};
|
|
2106
|
+
box-shadow: ${Bo.elevation02};
|
|
2284
2107
|
outline: none;
|
|
2285
2108
|
}
|
|
2286
2109
|
|
|
@@ -2295,7 +2118,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2295
2118
|
.ft-search-bar--no-suggestions {
|
|
2296
2119
|
text-align: center;
|
|
2297
2120
|
padding: 8px;
|
|
2298
|
-
color: ${
|
|
2121
|
+
color: ${Bo.colorOnSurface};
|
|
2299
2122
|
}
|
|
2300
2123
|
|
|
2301
2124
|
.ft-search-bar--suggestion {
|
|
@@ -2306,7 +2129,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2306
2129
|
padding: 8px;
|
|
2307
2130
|
gap: 8px;
|
|
2308
2131
|
cursor: pointer;
|
|
2309
|
-
color: ${
|
|
2132
|
+
color: ${Bo.colorOnSurface};
|
|
2310
2133
|
min-height: 52px;
|
|
2311
2134
|
}
|
|
2312
2135
|
|
|
@@ -2319,7 +2142,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2319
2142
|
}
|
|
2320
2143
|
|
|
2321
2144
|
.ft-search-bar--recent-search + .ft-search-bar--suggestion:not(.ft-search-bar--recent-search) {
|
|
2322
|
-
border-top: 1px solid ${
|
|
2145
|
+
border-top: 1px solid ${Bo.colorOutline};
|
|
2323
2146
|
}
|
|
2324
2147
|
|
|
2325
2148
|
.ft-search-bar--suggestion ft-typography {
|
|
@@ -2327,12 +2150,12 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2327
2150
|
flex-grow: 1;
|
|
2328
2151
|
flex-shrink: 1;
|
|
2329
2152
|
}
|
|
2330
|
-
`;var
|
|
2153
|
+
`;var Lo=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};null==window.fluidtopics&&console.warn("Fluid Topics public API was not found. You can find it here: https://www.npmjs.com/package/@fluid-topics/public-api");const Do={filtersButton:"Filters",inputPlaceHolder:"Search",filterInputPlaceHolder:"Filter {0}",clearInputButton:"Clear",clearFilterButton:"Clear",displayMoreFilterValuesButton:"More",searchButton:"Search",noSuggestions:"No results found…",clearFilters:"Clear filters",contentLocaleSelector:"Lang",presetsSelector:"Preset",removeRecentSearch:"Remove",back:"Back"};class jo extends CustomEvent{constructor(t){super("launch-search",{detail:t})}}class Io extends CustomEvent{constructor(t){super("change",{detail:t})}}class Uo extends vt{constructor(){super(...arguments),this.dense=!1,this.baseUrl="",this.apiIntegrationIdentifier="ft-search-bar",this.availableContentLocales=[],this.labels={},this.labelResolver=new xt(Do,{}),this.displayedFilters=[],this.presets=[],this.searchRequestSerializer=t=>function(t,e){var i;const o=new URLSearchParams({"content-lang":null!==(i=e.contentLocale)&&void 0!==i?i:"all",query:e.query});if(e.filters.length>0){const t=e.filters.map((t=>{const e=t.values.map((t=>t.replace(/_/g,"\\\\\\\\_").replace(/~/g,"\\\\~").replace(/\*/g,"\\*"))).map((t=>encodeURIComponent(function(t){return`"${t}"`}(t)))).join("_");return`${t.key}~${e}`})).join("*");o.append("filters",t)}return new URL(`${t}/search/all?${o.toString()}`).href}(this.baseUrl,t),this.searchFilters=[],this.sizeCategory=jt.S,this.displayFacets=!1,this.mobileMenuOpen=!1,this.facets=[],this.knownFacetLabels={},this.query="",this.suggestions=[],this.suggestionsLoaded=!0,this.recentSearches=[],this.updateFacetsDebouncer=new t(500),this.suggestDebouncer=new t(300),this.facetsLoaded=!1,this.closeFloatingContainer=t=>{this.isMobile||(this.displayFacets=this.displayFacets&&t.composedPath().some((t=>t===this.floatingContainer)))},this.compareFilters=(t,e)=>t.key===e.key&&t.negative==e.negative&&t.values.length===e.values.length&&t.values.every((t=>e.values.includes(t))),this.compareRequests=(t,e)=>(null==t.contentLocale||null==e.contentLocale||t.contentLocale===e.contentLocale)&&t.filters.length===e.filters.length&&t.filters.every((t=>e.filters.some((e=>this.compareFilters(t,e)))))}get recentSearchesStorageKey(){return this.baseUrl+":ft:recent-search-queries"}get request(){return{uiLocale:this.uiLocale,contentLocale:this.contentLocale,query:this.query,facets:this.facetsRequest,filters:this.searchFilters,paging:{perPage:0,page:1},sort:[]}}get facetsRequest(){const t=this.searchFilters.filter((t=>!this.displayedFilters.includes(t.key))).map((t=>({id:t.key})));return[...this.displayedFilters.map((t=>({id:t}))),...t]}get suggestRequest(){return{contentLocale:this.contentLocale,input:this.query,filters:this.searchFilters,sort:[]}}get isMobile(){return this.sizeCategory===jt.S}get hasFacets(){return this.facetsRequest.length>0}get hasPresets(){return this.presets.length>0}get hasLocaleSelector(){return this.availableContentLocales.length>1}focus(){var t;null===(t=this.container)||void 0===t||t.focus()}clear(){this.query="",this.searchFilters=[],this.input&&(this.input.value=""),this.mobileMenuOpen=!1,this.displayFacets=!1}render(){const t={"ft-search-bar--container":!0,"ft-search-bar--dense":!this.isMobile&&this.dense,"ft-search-bar--mobile":this.isMobile,"ft-search-bar--desktop":!this.isMobile,"ft-search-bar--floating-panel-open":!this.isMobile&&this.displayFacets,"ft-search-bar--mobile-menu-open":this.mobileMenuOpen};return K`
|
|
2331
2154
|
<ft-size-watcher @change=${this.updateSize}></ft-size-watcher>
|
|
2332
2155
|
<div class="${Dt(t)}" part="container" tabindex="-1">
|
|
2333
2156
|
${this.isMobile?this.renderMobileSearchBar():this.renderDesktopSearchBar()}
|
|
2334
2157
|
</div>
|
|
2335
|
-
`}renderMobileSearchBar(){return
|
|
2158
|
+
`}renderMobileSearchBar(){return K`
|
|
2336
2159
|
<div class="ft-search-bar">
|
|
2337
2160
|
<div class="ft-search-bar--input-container" part="input-container">
|
|
2338
2161
|
<div class="ft-search-bar--input-outline" part="input-outline">
|
|
@@ -2349,15 +2172,15 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2349
2172
|
</div>
|
|
2350
2173
|
${this.displayFacets?this.renderFacetsActions():this.renderSelectedFacets()}
|
|
2351
2174
|
${this.displayFacets?this.renderMobileFacets():this.renderSuggestions()}
|
|
2352
|
-
${this.mobileMenuOpen||this.displayFacets?
|
|
2175
|
+
${this.mobileMenuOpen||this.displayFacets?K`
|
|
2353
2176
|
<ft-button class="ft-search-bar--launch-search"
|
|
2354
2177
|
part="search-bar-actions"
|
|
2355
2178
|
icon="search"
|
|
2356
2179
|
@click=${this.launchSearch}>
|
|
2357
2180
|
${this.labelResolver.resolve("searchButton")}
|
|
2358
2181
|
</ft-button>
|
|
2359
|
-
`:
|
|
2360
|
-
`}renderMobileSearchBarButtons(){return this.query||this.mobileMenuOpen?
|
|
2182
|
+
`:V}
|
|
2183
|
+
`}renderMobileSearchBarButtons(){return this.query||this.mobileMenuOpen?K`
|
|
2361
2184
|
<ft-button class="ft-search-bar--clear-query"
|
|
2362
2185
|
part="search-bar-actions"
|
|
2363
2186
|
icon="close"
|
|
@@ -2365,7 +2188,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2365
2188
|
label="${this.labelResolver.resolve("clearInputButton")}"
|
|
2366
2189
|
@click=${()=>{this.setQuery(""),this.mobileMenuOpen=!1,this.displayFacets=!1}}
|
|
2367
2190
|
></ft-button>
|
|
2368
|
-
`:
|
|
2191
|
+
`:K`
|
|
2369
2192
|
<ft-button class="ft-search-bar--launch-search"
|
|
2370
2193
|
part="search-bar-actions"
|
|
2371
2194
|
icon="search"
|
|
@@ -2373,9 +2196,9 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2373
2196
|
label="${this.labelResolver.resolve("searchButton")}"
|
|
2374
2197
|
@click=${()=>{var t;return null===(t=this.input)||void 0===t?void 0:t.focus()}}
|
|
2375
2198
|
></ft-button>
|
|
2376
|
-
`}renderMobileFacets(){var t;const e=this.availableContentLocales.filter((t=>t.lang===this.contentLocale)).pop();return
|
|
2199
|
+
`}renderMobileFacets(){var t;const e=this.availableContentLocales.filter((t=>t.lang===this.contentLocale)).pop();return K`
|
|
2377
2200
|
<ft-accordion class="ft-search-bar--filters-container">
|
|
2378
|
-
${this.hasLocaleSelector?
|
|
2201
|
+
${this.hasLocaleSelector?K`
|
|
2379
2202
|
<ft-accordion-item data-facet-key="ft:contentLocale">
|
|
2380
2203
|
<div class="ft-search-bar--filter-label" slot="toggle">
|
|
2381
2204
|
<ft-typography variant="button">${this.labelResolver.resolve("contentLocaleSelector")}
|
|
@@ -2393,12 +2216,12 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2393
2216
|
></ft-filter>
|
|
2394
2217
|
</ft-accordion-item>
|
|
2395
2218
|
`:null}
|
|
2396
|
-
${Lt(this.facets,(t=>t.key),(t=>{const e=
|
|
2219
|
+
${Lt(this.facets,(t=>t.key),(t=>{const e=qe(t);return K`
|
|
2397
2220
|
<ft-accordion-item data-facet-key="${t.key}">
|
|
2398
2221
|
<div class="ft-search-bar--filter-label" slot="toggle">
|
|
2399
2222
|
<ft-typography variant="button">${t.label}</ft-typography>
|
|
2400
2223
|
<ft-typography variant="body2">
|
|
2401
|
-
${function(t){return
|
|
2224
|
+
${function(t){return Ke(t.options,(t=>{var e;return null!==(e=t.subOptions)&&void 0!==e?e:[]})).filter((t=>t.selected)).map((t=>t.label))}(e).join(", ")}
|
|
2402
2225
|
</ft-typography>
|
|
2403
2226
|
</div>
|
|
2404
2227
|
<ft-filter
|
|
@@ -2416,12 +2239,12 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2416
2239
|
</ft-accordion-item>
|
|
2417
2240
|
`}))}
|
|
2418
2241
|
</ft-accordion>
|
|
2419
|
-
`}contentLocalesAsFilterOptions(){return this.availableContentLocales.map((t=>({value:t.lang,label:t.label,selected:t.lang==this.contentLocale})))}renderDesktopSearchBar(){return
|
|
2242
|
+
`}contentLocalesAsFilterOptions(){return this.availableContentLocales.map((t=>({value:t.lang,label:t.label,selected:t.lang==this.contentLocale})))}renderDesktopSearchBar(){return K`
|
|
2420
2243
|
<div class="ft-search-bar" part="search-bar">
|
|
2421
2244
|
${this.renderSearchBarLeftAction()}
|
|
2422
2245
|
<div class="ft-search-bar--input-container" part="input-container">
|
|
2423
2246
|
<div class="ft-search-bar--input-outline" part="input-outline">
|
|
2424
|
-
${this.dense?this.renderSelectedFacets():
|
|
2247
|
+
${this.dense?this.renderSelectedFacets():V}
|
|
2425
2248
|
<input class="ft-search-bar--input ft-typography--body2"
|
|
2426
2249
|
part="input"
|
|
2427
2250
|
type="text"
|
|
@@ -2446,8 +2269,8 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2446
2269
|
</div>
|
|
2447
2270
|
</div>
|
|
2448
2271
|
</div>
|
|
2449
|
-
${this.dense?
|
|
2450
|
-
`}renderSearchBarLeftAction(){return this.hasFacets?
|
|
2272
|
+
${this.dense?V:this.renderSelectedFacets()}
|
|
2273
|
+
`}renderSearchBarLeftAction(){return this.hasFacets?K`
|
|
2451
2274
|
<ft-button class="ft-search-bar--filters-opener ft-search-bar--left-action"
|
|
2452
2275
|
part="filters-opener"
|
|
2453
2276
|
trailingIcon
|
|
@@ -2456,20 +2279,20 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2456
2279
|
@focusin=${t=>t.stopPropagation()}>
|
|
2457
2280
|
${this.labelResolver.resolve("filtersButton")}
|
|
2458
2281
|
</ft-button>
|
|
2459
|
-
`:this.hasLocaleSelector?
|
|
2282
|
+
`:this.hasLocaleSelector?K`
|
|
2460
2283
|
<ft-select outlined
|
|
2461
2284
|
class="ft-search-bar--content-locale ft-search-bar--left-action"
|
|
2462
2285
|
part="content-locale"
|
|
2463
2286
|
@change=${t=>this.contentLocale=null==t.detail?void 0:t.detail}>
|
|
2464
|
-
${Lt(this.availableContentLocales,(t=>t.lang),(t=>
|
|
2287
|
+
${Lt(this.availableContentLocales,(t=>t.lang),(t=>K`
|
|
2465
2288
|
<ft-select-option .value=${t.lang}
|
|
2466
2289
|
label="${t.label}"
|
|
2467
2290
|
?selected=${t.lang===this.contentLocale}>
|
|
2468
2291
|
</ft-select-option>
|
|
2469
2292
|
`))}
|
|
2470
2293
|
</ft-select>
|
|
2471
|
-
`:
|
|
2472
|
-
${this.query?
|
|
2294
|
+
`:V}renderDesktopSearchBarButtons(){return K`
|
|
2295
|
+
${this.query?K`
|
|
2473
2296
|
<ft-button class="ft-search-bar--clear-query"
|
|
2474
2297
|
part="search-bar-actions"
|
|
2475
2298
|
icon="close"
|
|
@@ -2486,36 +2309,36 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2486
2309
|
label="${this.labelResolver.resolve("searchButton")}"
|
|
2487
2310
|
@click=${this.launchSearch}
|
|
2488
2311
|
></ft-button>
|
|
2489
|
-
`}renderFacetsActions(){return
|
|
2312
|
+
`}renderFacetsActions(){return K`
|
|
2490
2313
|
<div class="ft-search-bar--facets-actions">
|
|
2491
|
-
${this.hasPresets?
|
|
2314
|
+
${this.hasPresets?K`
|
|
2492
2315
|
<ft-select
|
|
2493
2316
|
class="ft-search-bar--presets"
|
|
2494
2317
|
part="presets"
|
|
2495
2318
|
label="${this.labelResolver.resolve("presetsSelector")}"
|
|
2496
2319
|
outlined
|
|
2497
2320
|
@change=${t=>this.selectedPreset=t.detail}>
|
|
2498
|
-
${Lt(this.presets,(t=>t.name),(t=>
|
|
2321
|
+
${Lt(this.presets,(t=>t.name),(t=>K`
|
|
2499
2322
|
<ft-select-option value="${t.name}"
|
|
2500
2323
|
label="${t.name}"
|
|
2501
2324
|
?selected=${t.name===this.selectedPreset}>
|
|
2502
2325
|
</ft-select-option>
|
|
2503
2326
|
`))}
|
|
2504
2327
|
</ft-select>
|
|
2505
|
-
`:
|
|
2506
|
-
${this.searchFilters.length>0?
|
|
2328
|
+
`:V}
|
|
2329
|
+
${this.searchFilters.length>0?K`
|
|
2507
2330
|
<ft-button part="facets-actions"
|
|
2508
2331
|
@click=${this.clearFilters}>
|
|
2509
2332
|
${this.labelResolver.resolve("clearFilters")}
|
|
2510
2333
|
</ft-button>
|
|
2511
|
-
`:
|
|
2334
|
+
`:V}
|
|
2512
2335
|
<slot name="facets-actions"></slot>
|
|
2513
2336
|
</div>
|
|
2514
|
-
`}renderDesktopFacets(){return this.hasFacets?
|
|
2337
|
+
`}renderDesktopFacets(){return this.hasFacets?K`
|
|
2515
2338
|
<ft-snap-scroll horizontal limitSize controls
|
|
2516
2339
|
class="ft-search-bar--filters-container"
|
|
2517
2340
|
part="filters-container">
|
|
2518
|
-
${this.hasLocaleSelector?
|
|
2341
|
+
${this.hasLocaleSelector?K`
|
|
2519
2342
|
<ft-filter part="filters"
|
|
2520
2343
|
class="ft-search-bar--content-locale"
|
|
2521
2344
|
label="${this.labelResolver.resolve("contentLocaleSelector")}"
|
|
@@ -2523,8 +2346,8 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2523
2346
|
.options=${this.contentLocalesAsFilterOptions()}
|
|
2524
2347
|
@change=${t=>this.contentLocale=t.detail[0]}
|
|
2525
2348
|
></ft-filter>
|
|
2526
|
-
`:
|
|
2527
|
-
${Lt(this.facets,(t=>t.key),(t=>{const e=
|
|
2349
|
+
`:V}
|
|
2350
|
+
${Lt(this.facets,(t=>t.key),(t=>{const e=qe(t),i=e.options.some((t=>{var e,i;return(null!==(i=null===(e=t.subOptions)||void 0===e?void 0:e.length)&&void 0!==i?i:0)>0}));return K`
|
|
2528
2351
|
<ft-filter
|
|
2529
2352
|
class="${i?"ft-search-bar--hierarchical-filter":""}"
|
|
2530
2353
|
part="filters"
|
|
@@ -2541,8 +2364,8 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2541
2364
|
></ft-filter>
|
|
2542
2365
|
`}))}
|
|
2543
2366
|
</ft-snap-scroll>
|
|
2544
|
-
`:
|
|
2545
|
-
${this.hasLocaleSelector&&(this.hasFacets||this.isMobile)?
|
|
2367
|
+
`:V}renderSelectedFacets(){if(!this.hasLocaleSelector&&!this.hasFacets)return null;const t=!this.isMobile&&this.dense||this.isMobile&&this.mobileMenuOpen,e=K`
|
|
2368
|
+
${this.hasLocaleSelector&&(this.hasFacets||this.isMobile)?K`
|
|
2546
2369
|
<ft-chip part="selected-filters"
|
|
2547
2370
|
?dense=${this.dense&&!this.isMobile}
|
|
2548
2371
|
?clickable=${this.isMobile}
|
|
@@ -2550,53 +2373,53 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2550
2373
|
${this.getLocaleLabel(this.contentLocale)}
|
|
2551
2374
|
</ft-chip>
|
|
2552
2375
|
`:null}
|
|
2553
|
-
${Lt(this.facets,(t=>t.key),(e=>{const i=function(t){return
|
|
2376
|
+
${Lt(this.facets,(t=>t.key),(e=>{const i=function(t){return Ke(t.rootNodes,(t=>t.selected?[]:t.childNodes)).filter((t=>t.selected)).map((t=>t.value))}(e);return Lt(i,(o=>{let s=e.label+": "+function(t){return We(t).split("|").join(" > ")}(o);const n=K`
|
|
2554
2377
|
<ft-chip
|
|
2555
2378
|
part="selected-filters"
|
|
2556
2379
|
?dense=${this.dense&&!this.isMobile}
|
|
2557
2380
|
?clickable=${this.isMobile}
|
|
2558
2381
|
?removable=${!this.isMobile}
|
|
2559
|
-
icon=${this.isMobile?
|
|
2560
|
-
label="${
|
|
2561
|
-
title=${t?
|
|
2382
|
+
icon=${this.isMobile?V:"close"}
|
|
2383
|
+
label="${s}"
|
|
2384
|
+
title=${t?s:V}
|
|
2562
2385
|
@click=${()=>this.openMobileFilters(e.key)}
|
|
2563
|
-
@icon-click=${()=>this.setFilter(e.key,i.filter((t=>t!==
|
|
2564
|
-
${function(t){return
|
|
2386
|
+
@icon-click=${()=>this.setFilter(e.key,i.filter((t=>t!==o)))}>
|
|
2387
|
+
${function(t){return We(t).split("|").pop()}(o)}
|
|
2565
2388
|
</ft-chip>
|
|
2566
|
-
`;return t?n:
|
|
2567
|
-
<ft-tooltip inline text="${
|
|
2389
|
+
`;return t?n:K`
|
|
2390
|
+
<ft-tooltip inline text="${s}">
|
|
2568
2391
|
${n}
|
|
2569
2392
|
</ft-tooltip>
|
|
2570
2393
|
`}))}))}
|
|
2571
|
-
${this.isMobile?
|
|
2394
|
+
${this.isMobile?K`
|
|
2572
2395
|
<ft-chip part="selected-filters"
|
|
2573
2396
|
icon="add"
|
|
2574
2397
|
clickable
|
|
2575
2398
|
@click=${()=>{this.mobileMenuOpen=!0,this.displayFacets=!0}}>
|
|
2576
2399
|
${this.labelResolver.resolve("filtersButton")}
|
|
2577
2400
|
</ft-chip>
|
|
2578
|
-
`:
|
|
2579
|
-
`;return t?
|
|
2401
|
+
`:V}
|
|
2402
|
+
`;return t?K`
|
|
2580
2403
|
<ft-snap-scroll horizontal controls hideScrollbar limitSize
|
|
2581
2404
|
class="ft-search-bar--selected-filters"
|
|
2582
2405
|
part="selected-filters-container">
|
|
2583
2406
|
${e}
|
|
2584
2407
|
</ft-snap-scroll>
|
|
2585
|
-
`:
|
|
2408
|
+
`:K`
|
|
2586
2409
|
<div class="ft-search-bar--selected-filters" part="selected-filters-container">
|
|
2587
2410
|
${e}
|
|
2588
2411
|
</div>
|
|
2589
|
-
`}renderSuggestions(){const t=this.recentSearches.filter((t=>t.toLowerCase().includes(this.query.toLowerCase()))),e=this.query.length>2||t.length>0;return
|
|
2412
|
+
`}renderSuggestions(){const t=this.recentSearches.filter((t=>t.toLowerCase().includes(this.query.toLowerCase()))),e=this.query.length>2||t.length>0;return K`
|
|
2590
2413
|
<div class="ft-search-bar--suggestions ${e?"ft-search-bar--suggestions-not-empty":""}"
|
|
2591
2414
|
@keydown=${this.onSuggestKeyDown}>
|
|
2592
|
-
${Lt(t.slice(0,5),(t=>t),(t=>
|
|
2415
|
+
${Lt(t.slice(0,5),(t=>t),(t=>K`
|
|
2593
2416
|
<a href="${this.searchRequestSerializer({...this.request,query:t})}"
|
|
2594
2417
|
part="suggestions"
|
|
2595
2418
|
class="ft-search-bar--suggestion ft-search-bar--recent-search"
|
|
2596
2419
|
@keyup=${e=>this.onSuggestKeyUp(e,t)}
|
|
2597
2420
|
@click=${e=>this.onSuggestClick(e,t)}>
|
|
2598
2421
|
<ft-ripple></ft-ripple>
|
|
2599
|
-
<
|
|
2422
|
+
<ft-icon variant="material" part="suggestion-icon">history</ft-icon>
|
|
2600
2423
|
<ft-typography variant="body1">${t}</ft-typography>
|
|
2601
2424
|
<ft-button icon="close"
|
|
2602
2425
|
round
|
|
@@ -2606,7 +2429,7 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2606
2429
|
@click=${e=>this.removeRecentSearch(e,t)}></ft-button>
|
|
2607
2430
|
</a>
|
|
2608
2431
|
`))}
|
|
2609
|
-
${Lt(this.suggestions,(t=>t.value),(t=>
|
|
2432
|
+
${Lt(this.suggestions,(t=>t.value),(t=>K`
|
|
2610
2433
|
<a href="${this.searchRequestSerializer({...this.request,query:t.value})}"
|
|
2611
2434
|
part="suggestions"
|
|
2612
2435
|
class="ft-search-bar--suggestion"
|
|
@@ -2617,20 +2440,20 @@ class Br extends Et{constructor(t){if(super(t),this.it=X,t.type!==zt)throw Error
|
|
|
2617
2440
|
<ft-typography variant="body1">${t.value}</ft-typography>
|
|
2618
2441
|
</a>
|
|
2619
2442
|
`))}
|
|
2620
|
-
${0===t.length&&0===this.suggestions.length&&this.query.length>2&&this.suggestionsLoaded?
|
|
2443
|
+
${0===t.length&&0===this.suggestions.length&&this.query.length>2&&this.suggestionsLoaded?K`
|
|
2621
2444
|
<ft-typography class="ft-search-bar--no-suggestions" element="p"
|
|
2622
2445
|
variant="body2">
|
|
2623
2446
|
${this.labelResolver.resolve("noSuggestions")}
|
|
2624
2447
|
</ft-typography>
|
|
2625
2448
|
`:null}
|
|
2626
2449
|
</div>
|
|
2627
|
-
`}getIcon(t){const e="DOCUMENT"===t.type?
|
|
2450
|
+
`}getIcon(t){const e="DOCUMENT"===t.type?fi.file_format:fi.fluid_topics;let i;switch(t.type){case"MAP":i="BOOK"===t.editorialType?ci.BOOK:ci.ARTICLE;break;case"DOCUMENT":i=function(t,e){var i,o,s,n;t=(null!=t?t:"").toLowerCase(),e=(null!=e?e:"").toLowerCase();const[r,l]=((null!==(i=di.get(t))&&void 0!==i?i:t)+"/").split("/");return null!==(n=null!==(s=null!==(o=pi.get(l))&&void 0!==o?o:pi.get(e))&&void 0!==s?s:pi.get(r))&&void 0!==n?n:hi.UNKNOWN}(t.mimeType,t.filenameExtension);break;case"TOPIC":i=ci.TOPICS}return K`
|
|
2628
2451
|
<ft-icon variant="${e}" part="suggestion-icon">
|
|
2629
2452
|
${i}
|
|
2630
2453
|
</ft-icon>
|
|
2631
|
-
`}openMobileFilters(t){this.isMobile&&(this.mobileMenuOpen=!0,this.displayFacets=!0,this.scrollToFacet=t)}async firstUpdated(t){var e,i;super.firstUpdated(t),this.initApi(),this.availableContentLocales=null!==(i=await(null===(e=this.api)||void 0===e?void 0:e.getAvailableSearchLocales().then((t=>t.contentLocales)).catch((()=>[]))))&&void 0!==i?i:[]}update(t){var e,i,
|
|
2632
|
-
${i.map((t=>
|
|
2454
|
+
`}openMobileFilters(t){this.isMobile&&(this.mobileMenuOpen=!0,this.displayFacets=!0,this.scrollToFacet=t)}async firstUpdated(t){var e,i;super.firstUpdated(t),this.initApi(),this.availableContentLocales=null!==(i=await(null===(e=this.api)||void 0===e?void 0:e.getAvailableSearchLocales().then((t=>t.contentLocales)).catch((()=>[]))))&&void 0!==i?i:[]}update(t){var e,i,o;if(t.has("labels")&&(this.labelResolver=new xt(Do,this.labels)),t.has("sizeCategory")&&(this.mobileMenuOpen=!1,this.displayFacets=this.displayFacets&&!this.isMobile),super.update(t),(t.has("availableContentLocales")||t.has("contentLocale"))&&this.availableContentLocales.length>0){const i=t=>this.availableContentLocales.some((e=>e.lang===t));i(this.contentLocale)||(this.contentLocale=t.has("contentLocale")&&i(t.get("contentLocale"))?t.get("contentLocale"):null===(e=this.availableContentLocales[0])||void 0===e?void 0:e.lang)}if(t.has("baseUrl")&&this.baseUrl&&(this.baseUrl.endsWith("/")&&(this.baseUrl=this.baseUrl.replace(/\/$/,"")),this.recentSearches=JSON.parse(null!==(i=window.localStorage.getItem(this.recentSearchesStorageKey))&&void 0!==i?i:"[]")),t.has("selectedPreset")){const t=this.presets.find((t=>t.name===this.selectedPreset));t&&!this.compareRequests(this.request,t)&&this.setFiltersFromPreset(t)}["contentLocale","searchFilters"].some((e=>t.has(e)))&&(this.selectedPreset=null===(o=this.presets.find((t=>this.compareRequests(t,this.request))))||void 0===o?void 0:o.name),["baseUrl","apiIntegrationIdentifier"].some((e=>t.has(e)))&&this.setApi(),["uiLocale","contentLocale","searchFilters","displayedFilters","api"].some((e=>t.has(e)))&&this.updateFacets(),["query","uiLocale","contentLocale","searchFilters","displayedFilters","api"].some((e=>t.has(e)))&&this.updateSuggestions(),["query","uiLocale","contentLocale","searchFilters"].some((e=>t.has(e)))&&this.dispatchEvent(new Io(this.request))}contentAvailableCallback(t){var e,i,o;if(super.contentAvailableCallback(t),t.has("displayFacets")&&this.displayFacets&&(null===(e=this.floatingContainer)||void 0===e||e.focus()),null!=this.scrollToFacet&&this.facetsLoaded){null===(i=this.scrollingFiltersContainer)||void 0===i||i.scrollIndexIntoView(this.facets.findIndex((t=>t.key===this.scrollToFacet)));const t=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelector(`ft-accordion-item[data-facet-key="${this.scrollToFacet}"]`);t&&(t.active=!0),this.scrollToFacet=void 0}}initApi(){null==this.api&&(this.setApi(),setTimeout((()=>this.initApi()),100))}setApi(){this.api=window.fluidtopics?new window.fluidtopics.FluidTopicsApi(this.baseUrl,this.apiIntegrationIdentifier,!0):void 0}updateFacets(){this.facetsRequest.length>0?(this.facetsLoaded=!1,this.updateFacetsDebouncer.run((async()=>{var t,e;this.facets=null!==(e=await(null===(t=this.api)||void 0===t?void 0:t.search({...this.request,query:""}).then((t=>t.facets)).catch((()=>[]))))&&void 0!==e?e:[],this.facets.forEach((t=>this.knownFacetLabels[t.key]=t.label)),this.facetsLoaded=!0}))):this.facets=[]}updateSuggestions(){this.suggestionsLoaded=!1,this.suggestDebouncer.run((async()=>{this.suggestions=this.api&&this.query.length>2?await this.api.getSuggestions(this.suggestRequest).then((t=>t.suggestions)).catch((()=>[])):[],this.suggestionsLoaded=!0}))}onSearchBarKeyUp(t){const e=t.composedPath()[0];this.query=e.value,"Enter"===t.key&&this.launchSearch()}onSearchBarKeyDown(t){var e,i;switch(t.key){case"Escape":this.mobileMenuOpen=!1,null===(e=this.input)||void 0===e||e.blur();break;case"ArrowDown":t.stopPropagation(),t.preventDefault(),null===(i=this.firstSuggestion)||void 0===i||i.focus()}}onFloatingContainerKeyUp(t){var e;"Escape"===t.key&&(this.displayFacets=!1,null===(e=this.filtersOpener)||void 0===e||e.focus())}setQuery(t){this.input&&(this.input.value=t),this.query=t}onSuggestClick(t,e){t.ctrlKey||t.metaKey||this.onSuggestSelected(t,e)}onSuggestKeyUp(t,e){"Enter"!==t.key&&" "!==t.key||this.onSuggestSelected(t,e)}onSuggestSelected(t,e){t.preventDefault(),this.setQuery(e),this.launchSearch()}launchSearch(){if(this.query){let t=this.recentSearches.filter((t=>t.toLowerCase()!==this.query.toLowerCase())).filter(((t,e)=>e<20));this.recentSearches=[this.query,...t],this.saveRecentSearches()}this.dispatchEvent(new jo(this.request)),this.mobileMenuOpen=!1,this.displayFacets=!1,this.focus()}saveRecentSearches(){window.localStorage.setItem(this.recentSearchesStorageKey,JSON.stringify(this.recentSearches))}connectedCallback(){super.connectedCallback(),document.addEventListener("focusin",this.closeFloatingContainer),document.addEventListener("click",this.closeFloatingContainer)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("focusin",this.closeFloatingContainer),document.addEventListener("click",this.closeFloatingContainer)}updateSize(t){this.sizeCategory=t.detail.category}getLocaleLabel(t){var e;return null!==(e=this.availableContentLocales.filter((e=>{var i;return(null!==(i=e.lang)&&void 0!==i?i:"").toLowerCase()===(null!=t?t:"").toLowerCase()})).map((t=>t.label)).pop())&&void 0!==e?e:t}setFilter(t,e){let i=this.searchFilters.filter((e=>e.key!==t));this.facets.forEach((i=>{i.key===t&&Ke(i.rootNodes,(t=>t.childNodes)).forEach((t=>t.selected=e.includes(t.value)))})),e.length&&i.push({key:t,negative:!1,values:e}),this.searchFilters=i,this.scrollToFacet=t}setFiltersFromPreset(t){null!=t&&(null!=t.contentLocale&&(this.contentLocale=t.contentLocale),this.searchFilters=t.filters)}clearFilters(){this.facets.forEach((t=>Ke(t.rootNodes,(t=>t.childNodes)).forEach((t=>t.selected=!1)))),this.searchFilters=[];const t=this.facets[0];this.scrollToFacet=null==t?void 0:t.key}removeRecentSearch(t,e){var i,o,s,n;t.preventDefault(),t.stopPropagation();const r=null!==(n=null!==(o=null===(i=this.focusedSuggestion)||void 0===i?void 0:i.previousElementSibling)&&void 0!==o?o:null===(s=this.focusedSuggestion)||void 0===s?void 0:s.nextElementSibling)&&void 0!==n?n:this.input;null==r||r.focus(),this.recentSearches=this.recentSearches.filter((t=>t.toLowerCase()!==e.toLowerCase())),this.saveRecentSearches()}onSuggestKeyDown(t){var e,i,o,s,n,r;switch(t.key){case"ArrowUp":null===(o=null!==(i=null===(e=this.focusedSuggestion)||void 0===e?void 0:e.previousElementSibling)&&void 0!==i?i:this.lastSuggestion)||void 0===o||o.focus(),t.preventDefault(),t.stopPropagation();break;case"ArrowDown":null===(r=null!==(n=null===(s=this.focusedSuggestion)||void 0===s?void 0:s.nextElementSibling)&&void 0!==n?n:this.firstSuggestion)||void 0===r||r.focus(),t.preventDefault(),t.stopPropagation()}}}Uo.elementDefinitions={"ft-accordion":ro,"ft-accordion-item":po,"ft-button":ki,"ft-chip":$o,"ft-filter":io,"ft-filter-option":so,"ft-icon":vi,"ft-ripple":Ye,"ft-select":Eo,"ft-select-option":Co,"ft-size-watcher":Tt,"ft-snap-scroll":Wi,"ft-tooltip":si,"ft-typography":Ze},Uo.styles=[Te,No,Fo,Ro,Mo],Lo([i({type:Boolean})],Uo.prototype,"dense",void 0),Lo([i({type:String})],Uo.prototype,"baseUrl",void 0),Lo([i({type:String})],Uo.prototype,"apiIntegrationIdentifier",void 0),Lo([i({type:String})],Uo.prototype,"contentLocale",void 0),Lo([o()],Uo.prototype,"availableContentLocales",void 0),Lo([i({type:String})],Uo.prototype,"uiLocale",void 0),Lo([h({})],Uo.prototype,"labels",void 0),Lo([h([])],Uo.prototype,"displayedFilters",void 0),Lo([h([])],Uo.prototype,"presets",void 0),Lo([i({type:String,reflect:!0})],Uo.prototype,"selectedPreset",void 0),Lo([i()],Uo.prototype,"searchRequestSerializer",void 0),Lo([o()],Uo.prototype,"searchFilters",void 0),Lo([o()],Uo.prototype,"sizeCategory",void 0),Lo([o()],Uo.prototype,"displayFacets",void 0),Lo([o()],Uo.prototype,"mobileMenuOpen",void 0),Lo([o()],Uo.prototype,"facets",void 0),Lo([n(".ft-search-bar--container")],Uo.prototype,"container",void 0),Lo([n(".ft-search-bar--filters-opener")],Uo.prototype,"filtersOpener",void 0),Lo([n(".ft-search-bar--floating-panel")],Uo.prototype,"floatingContainer",void 0),Lo([n("ft-snap-scroll.ft-search-bar--filters-container")],Uo.prototype,"scrollingFiltersContainer",void 0),Lo([n(".ft-search-bar--input")],Uo.prototype,"input",void 0),Lo([o()],Uo.prototype,"query",void 0),Lo([o()],Uo.prototype,"suggestions",void 0),Lo([o()],Uo.prototype,"suggestionsLoaded",void 0),Lo([o()],Uo.prototype,"recentSearches",void 0),Lo([o()],Uo.prototype,"scrollToFacet",void 0),Lo([n(".ft-search-bar--suggestion:first-child")],Uo.prototype,"firstSuggestion",void 0),Lo([n(".ft-search-bar--suggestion:focus-within")],Uo.prototype,"focusedSuggestion",void 0),Lo([n(".ft-search-bar--suggestion:last-child")],Uo.prototype,"lastSuggestion",void 0),Lo([o()],Uo.prototype,"api",void 0),c("ft-search-bar")(function t(e){var i;let o;if("elementDefinitions"in e){o={};const i=e.elementDefinitions;for(let e in i)o[e]=t(i[e])}return i=class extends e{constructor(...t){super(t),this._constructor=this.constructor}render(){var t;let i=null!==(t=e.styles)&&void 0!==t?t:[];return Array.isArray(i)||(i=[i]),K`
|
|
2455
|
+
${i.map((t=>K`
|
|
2633
2456
|
<style>${t}</style>
|
|
2634
2457
|
`))}
|
|
2635
2458
|
${super.render()}
|
|
2636
|
-
`}},i.styles=void 0,i.elementDefinitions=
|
|
2459
|
+
`}},i.styles=void 0,i.elementDefinitions=o,i}(Uo))}();
|