@fluid-topics/ft-switch 1.1.7 → 1.1.8
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-switch.min.js +162 -162
- package/package.json +7 -7
package/build/ft-switch.min.js
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* subject to an additional IP rights grant found at
|
|
13
13
|
* http://polymer.github.io/PATENTS.txt
|
|
14
14
|
*/
|
|
15
|
-
if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,o=window.customElements.define,e=window.customElements.get,i=window.customElements,r=new WeakMap,n=new WeakMap,a=new WeakMap,s=new WeakMap;let l;window.CustomElementRegistry=class{constructor(){this._definitionsByTag=new Map,this._definitionsByClass=new Map,this._whenDefinedPromises=new Map,this._awaitingUpgrade=new Map}define(t,r){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(r))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const s=r.prototype.attributeChangedCallback,l=new Set(r.observedAttributes||[]);h(r,l,s);const c={elementClass:r,connectedCallback:r.prototype.connectedCallback,disconnectedCallback:r.prototype.disconnectedCallback,adoptedCallback:r.prototype.adoptedCallback,attributeChangedCallback:s,formAssociated:r.formAssociated,formAssociatedCallback:r.prototype.formAssociatedCallback,formDisabledCallback:r.prototype.formDisabledCallback,formResetCallback:r.prototype.formResetCallback,formStateRestoreCallback:r.prototype.formStateRestoreCallback,observedAttributes:l};this._definitionsByTag.set(t,c),this._definitionsByClass.set(r,c);let p=e.call(i,t);p||(p=f(t),o.call(i,t,p)),this===window.customElements&&(a.set(r,c),c.standInClass=p);const d=this._awaitingUpgrade.get(t);if(d){this._awaitingUpgrade.delete(t);for(const t of d)n.delete(t),u(t,c,!0)}const y=this._whenDefinedPromises.get(t);return void 0!==y&&(y.resolve(r),this._whenDefinedPromises.delete(t)),r}upgrade(){g.push(this),i.upgrade.apply(i,arguments),g.pop()}get(t){const o=this._definitionsByTag.get(t);return o?.elementClass}_getDefinition(t){return this._definitionsByTag.get(t)}whenDefined(t){const o=this._getDefinition(t);if(void 0!==o)return Promise.resolve(o.elementClass);let e=this._whenDefinedPromises.get(t);return void 0===e&&(e={},e.promise=new Promise((t=>e.resolve=t)),this._whenDefinedPromises.set(t,e)),e.promise}_upgradeWhenDefined(t,o,e){let i=this._awaitingUpgrade.get(o);i||this._awaitingUpgrade.set(o,i=new Set),e?i.add(t):i.delete(t)}},window.HTMLElement=function(){let o=l;if(o)return l=void 0,o;const e=a.get(this.constructor);if(!e)throw new TypeError("Illegal constructor (custom element class must be registered with global customElements registry to be newable)");return o=Reflect.construct(t,[],e.standInClass),Object.setPrototypeOf(o,this.constructor.prototype),r.set(o,e),o},window.HTMLElement.prototype=t.prototype;const c=t=>t===document||t instanceof ShadowRoot,p=t=>{let o=t.getRootNode();if(!c(o)){const t=g[g.length-1];if(t instanceof CustomElementRegistry)return t;o=t.getRootNode(),c(o)||(o=s.get(o)?.getRootNode()||document)}return o.customElements},f=o=>class{static get formAssociated(){return!0}constructor(){const e=Reflect.construct(t,[],this.constructor);Object.setPrototypeOf(e,HTMLElement.prototype);const i=p(e)||window.customElements,r=i._getDefinition(o);return r?u(e,r):n.set(e,i),e}connectedCallback(){const t=r.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):n.get(this)._upgradeWhenDefined(this,o,!0)}disconnectedCallback(){const t=r.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):n.get(this)._upgradeWhenDefined(this,o,!1)}adoptedCallback(){const t=r.get(this);t?.adoptedCallback?.apply(this,arguments)}formAssociatedCallback(){const t=r.get(this);t&&t.formAssociated&&t?.formAssociatedCallback?.apply(this,arguments)}formDisabledCallback(){const t=r.get(this);t?.formAssociated&&t?.formDisabledCallback?.apply(this,arguments)}formResetCallback(){const t=r.get(this);t?.formAssociated&&t?.formResetCallback?.apply(this,arguments)}formStateRestoreCallback(){const t=r.get(this);t?.formAssociated&&t?.formStateRestoreCallback?.apply(this,arguments)}},h=(t,o,e)=>{if(0===o.size||void 0===e)return;const i=t.prototype.setAttribute;i&&(t.prototype.setAttribute=function(t,r){const n=t.toLowerCase();if(o.has(n)){const t=this.getAttribute(n);i.call(this,n,r),e.call(this,n,t,r)}else i.call(this,n,r)});const r=t.prototype.removeAttribute;r&&(t.prototype.removeAttribute=function(t){const i=t.toLowerCase();if(o.has(i)){const t=this.getAttribute(i);r.call(this,i),e.call(this,i,t,null)}else r.call(this,i)});const n=t.prototype.toggleAttribute;n&&(t.prototype.toggleAttribute=function(t,i){const r=t.toLowerCase();if(o.has(r)){const t=this.getAttribute(r);n.call(this,r,i);const o=this.getAttribute(r);e.call(this,r,t,o)}else n.call(this,r,i)})},d=o=>{const e=Object.getPrototypeOf(o);if(e!==window.HTMLElement)return e===t?Object.setPrototypeOf(o,window.HTMLElement):d(e)},u=(t,o,e=!1)=>{Object.setPrototypeOf(t,o.elementClass.prototype),r.set(t,o),l=t;try{new o.elementClass}catch(t){d(o.elementClass),new o.elementClass}o.attributeChangedCallback&&o.observedAttributes.forEach((e=>{t.hasAttribute(e)&&o.attributeChangedCallback.call(t,e,null,t.getAttribute(e))})),e&&o.connectedCallback&&t.isConnected&&o.connectedCallback.call(t)},y=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const o=y.apply(this,arguments);return t.customElements&&(o.customElements=t.customElements),o};let g=[document];const b=(t,o,e=void 0)=>{const i=(e?Object.getPrototypeOf(e):t.prototype)[o];t.prototype[o]=function(){g.push(this);const t=i.apply(e||this,arguments);return void 0!==t&&s.set(t,this),g.pop(),t}};b(ShadowRoot,"createElement",document),b(ShadowRoot,"importNode",document),b(Element,"insertAdjacentHTML");const m=(t,o)=>{const e=Object.getOwnPropertyDescriptor(t.prototype,o);Object.defineProperty(t.prototype,o,{...e,set(t){g.push(this),e.set.call(this,t),g.pop()}})};if(m(Element,"innerHTML"),m(ShadowRoot,"innerHTML"),Object.defineProperty(window,"customElements",{value:new CustomElementRegistry,configurable:!0,writable:!0}),window.ElementInternals&&window.ElementInternals.prototype.setFormValue){const t=new WeakMap,o=HTMLElement.prototype.attachInternals,e=["setFormValue","setValidity","checkValidity","reportValidity"];HTMLElement.prototype.attachInternals=function(...e){const i=o.call(this,...e);return t.set(i,this),i},e.forEach((o=>{const e=window.ElementInternals.prototype,i=e[o];e[o]=function(...o){const e=t.get(this);if(!0===r.get(e).formAssociated)return i?.call(this,...o);throw new DOMException(`Failed to execute ${i} on 'ElementInternals': The target element is not a form-associated custom element.`)}}));class i 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 o=new Map;t.forEach(((t,e)=>{const i=t.getAttribute("name"),r=o.get(i)||[];this[+e]=t,r.push(t),o.set(i,r)})),this.length=t.length,o.forEach(((t,o)=>{t&&(1===t.length?this[o]=t[0]:this[o]=new i(t))}))}namedItem(t){return this[t]}}const a=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get:function(){const t=a.get.call(this,[]),o=[];for(const e of t){const t=r.get(e);t&&!0!==t.formAssociated||o.push(e)}return new n(o)}})}}try{window.customElements.define("custom-element",null)}catch(
|
|
15
|
+
if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,o=window.customElements.define,e=window.customElements.get,i=window.customElements,r=new WeakMap,n=new WeakMap,a=new WeakMap,s=new WeakMap;let l;window.CustomElementRegistry=class{constructor(){this._definitionsByTag=new Map,this._definitionsByClass=new Map,this._whenDefinedPromises=new Map,this._awaitingUpgrade=new Map}define(t,r){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(r))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const s=r.prototype.attributeChangedCallback,l=new Set(r.observedAttributes||[]);h(r,l,s);const c={elementClass:r,connectedCallback:r.prototype.connectedCallback,disconnectedCallback:r.prototype.disconnectedCallback,adoptedCallback:r.prototype.adoptedCallback,attributeChangedCallback:s,formAssociated:r.formAssociated,formAssociatedCallback:r.prototype.formAssociatedCallback,formDisabledCallback:r.prototype.formDisabledCallback,formResetCallback:r.prototype.formResetCallback,formStateRestoreCallback:r.prototype.formStateRestoreCallback,observedAttributes:l};this._definitionsByTag.set(t,c),this._definitionsByClass.set(r,c);let p=e.call(i,t);p||(p=f(t),o.call(i,t,p)),this===window.customElements&&(a.set(r,c),c.standInClass=p);const d=this._awaitingUpgrade.get(t);if(d){this._awaitingUpgrade.delete(t);for(const t of d)n.delete(t),u(t,c,!0)}const y=this._whenDefinedPromises.get(t);return void 0!==y&&(y.resolve(r),this._whenDefinedPromises.delete(t)),r}upgrade(){g.push(this),i.upgrade.apply(i,arguments),g.pop()}get(t){const o=this._definitionsByTag.get(t);return o?.elementClass}_getDefinition(t){return this._definitionsByTag.get(t)}whenDefined(t){const o=this._getDefinition(t);if(void 0!==o)return Promise.resolve(o.elementClass);let e=this._whenDefinedPromises.get(t);return void 0===e&&(e={},e.promise=new Promise((t=>e.resolve=t)),this._whenDefinedPromises.set(t,e)),e.promise}_upgradeWhenDefined(t,o,e){let i=this._awaitingUpgrade.get(o);i||this._awaitingUpgrade.set(o,i=new Set),e?i.add(t):i.delete(t)}},window.HTMLElement=function(){let o=l;if(o)return l=void 0,o;const e=a.get(this.constructor);if(!e)throw new TypeError("Illegal constructor (custom element class must be registered with global customElements registry to be newable)");return o=Reflect.construct(t,[],e.standInClass),Object.setPrototypeOf(o,this.constructor.prototype),r.set(o,e),o},window.HTMLElement.prototype=t.prototype;const c=t=>t===document||t instanceof ShadowRoot,p=t=>{let o=t.getRootNode();if(!c(o)){const t=g[g.length-1];if(t instanceof CustomElementRegistry)return t;o=t.getRootNode(),c(o)||(o=s.get(o)?.getRootNode()||document)}return o.customElements},f=o=>class{static get formAssociated(){return!0}constructor(){const e=Reflect.construct(t,[],this.constructor);Object.setPrototypeOf(e,HTMLElement.prototype);const i=p(e)||window.customElements,r=i._getDefinition(o);return r?u(e,r):n.set(e,i),e}connectedCallback(){const t=r.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):n.get(this)._upgradeWhenDefined(this,o,!0)}disconnectedCallback(){const t=r.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):n.get(this)._upgradeWhenDefined(this,o,!1)}adoptedCallback(){const t=r.get(this);t?.adoptedCallback?.apply(this,arguments)}formAssociatedCallback(){const t=r.get(this);t&&t.formAssociated&&t?.formAssociatedCallback?.apply(this,arguments)}formDisabledCallback(){const t=r.get(this);t?.formAssociated&&t?.formDisabledCallback?.apply(this,arguments)}formResetCallback(){const t=r.get(this);t?.formAssociated&&t?.formResetCallback?.apply(this,arguments)}formStateRestoreCallback(){const t=r.get(this);t?.formAssociated&&t?.formStateRestoreCallback?.apply(this,arguments)}},h=(t,o,e)=>{if(0===o.size||void 0===e)return;const i=t.prototype.setAttribute;i&&(t.prototype.setAttribute=function(t,r){const n=t.toLowerCase();if(o.has(n)){const t=this.getAttribute(n);i.call(this,n,r),e.call(this,n,t,r)}else i.call(this,n,r)});const r=t.prototype.removeAttribute;r&&(t.prototype.removeAttribute=function(t){const i=t.toLowerCase();if(o.has(i)){const t=this.getAttribute(i);r.call(this,i),e.call(this,i,t,null)}else r.call(this,i)});const n=t.prototype.toggleAttribute;n&&(t.prototype.toggleAttribute=function(t,i){const r=t.toLowerCase();if(o.has(r)){const t=this.getAttribute(r);n.call(this,r,i);const o=this.getAttribute(r);e.call(this,r,t,o)}else n.call(this,r,i)})},d=o=>{const e=Object.getPrototypeOf(o);if(e!==window.HTMLElement)return e===t?Object.setPrototypeOf(o,window.HTMLElement):d(e)},u=(t,o,e=!1)=>{Object.setPrototypeOf(t,o.elementClass.prototype),r.set(t,o),l=t;try{new o.elementClass}catch(t){d(o.elementClass),new o.elementClass}o.attributeChangedCallback&&o.observedAttributes.forEach((e=>{t.hasAttribute(e)&&o.attributeChangedCallback.call(t,e,null,t.getAttribute(e))})),e&&o.connectedCallback&&t.isConnected&&o.connectedCallback.call(t)},y=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const o=y.apply(this,arguments);return t.customElements&&(o.customElements=t.customElements),o};let g=[document];const b=(t,o,e=void 0)=>{const i=(e?Object.getPrototypeOf(e):t.prototype)[o];t.prototype[o]=function(){g.push(this);const t=i.apply(e||this,arguments);return void 0!==t&&s.set(t,this),g.pop(),t}};b(ShadowRoot,"createElement",document),b(ShadowRoot,"importNode",document),b(Element,"insertAdjacentHTML");const m=(t,o)=>{const e=Object.getOwnPropertyDescriptor(t.prototype,o);Object.defineProperty(t.prototype,o,{...e,set(t){g.push(this),e.set.call(this,t),g.pop()}})};if(m(Element,"innerHTML"),m(ShadowRoot,"innerHTML"),Object.defineProperty(window,"customElements",{value:new CustomElementRegistry,configurable:!0,writable:!0}),window.ElementInternals&&window.ElementInternals.prototype.setFormValue){const t=new WeakMap,o=HTMLElement.prototype.attachInternals,e=["setFormValue","setValidity","checkValidity","reportValidity"];HTMLElement.prototype.attachInternals=function(...e){const i=o.call(this,...e);return t.set(i,this),i},e.forEach((o=>{const e=window.ElementInternals.prototype,i=e[o];e[o]=function(...o){const e=t.get(this);if(!0===r.get(e).formAssociated)return i?.call(this,...o);throw new DOMException(`Failed to execute ${i} on 'ElementInternals': The target element is not a form-associated custom element.`)}}));class i 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 o=new Map;t.forEach(((t,e)=>{const i=t.getAttribute("name"),r=o.get(i)||[];this[+e]=t,r.push(t),o.set(i,r)})),this.length=t.length,o.forEach(((t,o)=>{t&&(1===t.length?this[o]=t[0]:this[o]=new i(t))}))}namedItem(t){return this[t]}}const a=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get:function(){const t=a.get.call(this,[]),o=[];for(const e of t){const t=r.get(e);t&&!0!==t.formAssociated||o.push(e)}return new n(o)}})}}try{window.customElements.define("custom-element",null)}catch(Hr){const t=window.customElements.define;window.customElements.define=(o,e,i)=>{if(null!==e)try{t.bind(window.customElements)(o,e,i)}catch(t){console.info(o,e,i,t)}}}
|
|
16
16
|
/**
|
|
17
17
|
* @license
|
|
18
18
|
* Copyright 2019 Google LLC
|
|
@@ -59,7 +59,7 @@ const w={attribute:!0,type:String,converter:m,reflect:!1,hasChanged:x},N=(t=w,o,
|
|
|
59
59
|
* Copyright 2017 Google LLC
|
|
60
60
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
61
61
|
*/
|
|
62
|
-
const W=globalThis,L=W.trustedTypes,K=L?L.createPolicy("lit-html",{createHTML:t=>t}):void 0,
|
|
62
|
+
const W=globalThis,L=W.trustedTypes,K=L?L.createPolicy("lit-html",{createHTML:t=>t}):void 0,F="$lit$",Z=`lit$${(Math.random()+"").slice(9)}$`,z="?"+Z,A=`<${z}>`,M=document,D=()=>M.createComment(""),B=t=>null===t||"object"!=typeof t&&"function"!=typeof t,P=Array.isArray,H="[ \t\n\f\r]",j=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,T=/-->/g,_=/>/g,G=RegExp(`>|${H}(?:([^\\s"'>=/]+)(${H}*=${H}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),Y=/'/g,V=/"/g,J=/^(?:script|style|textarea|title)$/i,q=(t=>(o,...e)=>({_$litType$:t,strings:o,values:e}))(1),X=Symbol.for("lit-noChange"),Q=Symbol.for("lit-nothing"),tt=new WeakMap,ot=M.createTreeWalker(M,129);function et(t,o){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==K?K.createHTML(o):o}let it=class t{constructor({strings:o,_$litType$:e},i){let r;this.parts=[];let n=0,a=0;const s=o.length-1,l=this.parts,[c,p]=((t,o)=>{const e=t.length-1,i=[];let r,n=2===o?"<svg>":"",a=j;for(let o=0;o<e;o++){const e=t[o];let s,l,c=-1,p=0;for(;p<e.length&&(a.lastIndex=p,l=a.exec(e),null!==l);)p=a.lastIndex,a===j?"!--"===l[1]?a=T:void 0!==l[1]?a=_:void 0!==l[2]?(J.test(l[2])&&(r=RegExp("</"+l[2],"g")),a=G):void 0!==l[3]&&(a=G):a===G?">"===l[0]?(a=r??j,c=-1):void 0===l[1]?c=-2:(c=a.lastIndex-l[2].length,s=l[1],a=void 0===l[3]?G:'"'===l[3]?V:Y):a===V||a===Y?a=G:a===T||a===_?a=j:(a=G,r=void 0);const f=a===G&&t[o+1].startsWith("/>")?" ":"";n+=a===j?e+A:c>=0?(i.push(s),e.slice(0,c)+F+e.slice(c)+Z+f):e+Z+(-2===c?o:f)}return[et(t,n+(t[e]||"<?>")+(2===o?"</svg>":"")),i]})(o,e);if(this.el=t.createElement(c,i),ot.currentNode=this.el.content,2===e){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(r=ot.nextNode())&&l.length<s;){if(1===r.nodeType){if(r.hasAttributes())for(const t of r.getAttributeNames())if(t.endsWith(F)){const o=p[a++],e=r.getAttribute(t).split(Z),i=/([.?@])?(.*)/.exec(o);l.push({type:1,index:n,name:i[2],strings:e,ctor:"."===i[1]?st:"?"===i[1]?lt:"@"===i[1]?ct:at}),r.removeAttribute(t)}else t.startsWith(Z)&&(l.push({type:6,index:n}),r.removeAttribute(t));if(J.test(r.tagName)){const t=r.textContent.split(Z),o=t.length-1;if(o>0){r.textContent=L?L.emptyScript:"";for(let e=0;e<o;e++)r.append(t[e],D()),ot.nextNode(),l.push({type:2,index:++n});r.append(t[o],D())}}}else if(8===r.nodeType)if(r.data===z)l.push({type:2,index:n});else{let t=-1;for(;-1!==(t=r.data.indexOf(Z,t+1));)l.push({type:7,index:n}),t+=Z.length-1}n++}}static createElement(t,o){const e=M.createElement("template");return e.innerHTML=t,e}};function rt(t,o,e=t,i){if(o===X)return o;let r=void 0!==i?e._$Co?.[i]:e._$Cl;const n=B(o)?void 0:o._$litDirective$;return r?.constructor!==n&&(r?._$AO?.(!1),void 0===n?r=void 0:(r=new n(t),r._$AT(t,e,i)),void 0!==i?(e._$Co??=[])[i]=r:e._$Cl=r),void 0!==r&&(o=rt(t,r._$AS(t,o.values),r,i)),o}let nt=class t{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,o,e,i){this.type=2,this._$AH=Q,this._$AN=void 0,this._$AA=t,this._$AB=o,this._$AM=e,this.options=i,this._$Cv=i?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const o=this._$AM;return void 0!==o&&11===t?.nodeType&&(t=o.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,o=this){t=rt(this,t,o),B(t)?t===Q||null==t||""===t?(this._$AH!==Q&&this._$AR(),this._$AH=Q):t!==this._$AH&&t!==X&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>P(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==Q&&B(this._$AH)?this._$AA.nextSibling.data=t:this.$(M.createTextNode(t)),this._$AH=t}g(t){const{values:o,_$litType$:e}=t,i="number"==typeof e?this._$AC(t):(void 0===e.el&&(e.el=it.createElement(et(e.h,e.h[0]),this.options)),e);if(this._$AH?._$AD===i)this._$AH.p(o);else{const t=new class{constructor(t,o){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=o}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:o},parts:e}=this._$AD,i=(t?.creationScope??M).importNode(o,!0);ot.currentNode=i;let r=ot.nextNode(),n=0,a=0,s=e[0];for(;void 0!==s;){if(n===s.index){let o;2===s.type?o=new nt(r,r.nextSibling,this,t):1===s.type?o=new s.ctor(r,s.name,s.strings,this,t):6===s.type&&(o=new pt(r,this,t)),this._$AV.push(o),s=e[++a]}n!==s?.index&&(r=ot.nextNode(),n++)}return ot.currentNode=M,i}p(t){let o=0;for(const e of this._$AV)void 0!==e&&(void 0!==e.strings?(e._$AI(t,e,o),o+=e.strings.length-2):e._$AI(t[o])),o++}}(i,this),e=t.u(this.options);t.p(o),this.$(e),this._$AH=t}}_$AC(t){let o=tt.get(t.strings);return void 0===o&&tt.set(t.strings,o=new it(t)),o}T(o){P(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,r=0;for(const n of o)r===e.length?e.push(i=new t(this.k(D()),this.k(D()),this,this.options)):i=e[r],i._$AI(n),r++;r<e.length&&(this._$AR(i&&i._$AB.nextSibling,r),e.length=r)}_$AR(t=this._$AA.nextSibling,o){for(this._$AP?.(!1,!0,o);t&&t!==this._$AB;){const o=t.nextSibling;t.remove(),t=o}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}},at=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,o,e,i,r){this.type=1,this._$AH=Q,this._$AN=void 0,this.element=t,this.name=o,this._$AM=i,this.options=r,e.length>2||""!==e[0]||""!==e[1]?(this._$AH=Array(e.length-1).fill(new String),this.strings=e):this._$AH=Q}_$AI(t,o=this,e,i){const r=this.strings;let n=!1;if(void 0===r)t=rt(this,t,o,0),n=!B(t)||t!==this._$AH&&t!==X,n&&(this._$AH=t);else{const i=t;let a,s;for(t=r[0],a=0;a<r.length-1;a++)s=rt(this,i[e+a],o,a),s===X&&(s=this._$AH[a]),n||=!B(s)||s!==this._$AH[a],s===Q?t=Q:t!==Q&&(t+=(s??"")+r[a+1]),this._$AH[a]=s}n&&!i&&this.O(t)}O(t){t===Q?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},st=class extends at{constructor(){super(...arguments),this.type=3}O(t){this.element[this.name]=t===Q?void 0:t}},lt=class extends at{constructor(){super(...arguments),this.type=4}O(t){this.element.toggleAttribute(this.name,!!t&&t!==Q)}},ct=class extends at{constructor(t,o,e,i,r){super(t,o,e,i,r),this.type=5}_$AI(t,o=this){if((t=rt(this,t,o,0)??Q)===X)return;const e=this._$AH,i=t===Q&&e!==Q||t.capture!==e.capture||t.once!==e.once||t.passive!==e.passive,r=t!==Q&&(e===Q||i);i&&this.element.removeEventListener(this.name,this,e),r&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},pt=class{constructor(t,o,e){this.element=t,this.type=6,this._$AN=void 0,this._$AM=o,this.options=e}get _$AU(){return this._$AM._$AU}_$AI(t){rt(this,t)}};const ft=W.litHtmlPolyfillSupport;ft?.(it,nt),(W.litHtmlVersions??=[]).push("3.1.0");
|
|
63
63
|
/**
|
|
64
64
|
* @license
|
|
65
65
|
* Copyright 2019 Google LLC
|
|
@@ -76,7 +76,7 @@ const ht=globalThis,dt=ht.ShadowRoot&&(void 0===ht.ShadyCSS||ht.ShadyCSS.nativeS
|
|
|
76
76
|
* Copyright 2017 Google LLC
|
|
77
77
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
78
78
|
*/
|
|
79
|
-
const
|
|
79
|
+
const Ft=globalThis,Zt=Ft.trustedTypes,zt=Zt?Zt.createPolicy("lit-html",{createHTML:t=>t}):void 0,At="$lit$",Mt=`lit$${(Math.random()+"").slice(9)}$`,Dt="?"+Mt,Bt=`<${Dt}>`,Pt=document,Ht=()=>Pt.createComment(""),jt=t=>null===t||"object"!=typeof t&&"function"!=typeof t,Tt=Array.isArray,_t="[ \t\n\f\r]",Gt=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Yt=/-->/g,Vt=/>/g,Jt=RegExp(`>|${_t}(?:([^\\s"'>=/]+)(${_t}*=${_t}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),qt=/'/g,Xt=/"/g,Qt=/^(?:script|style|textarea|title)$/i,to=(t=>(o,...e)=>({_$litType$:t,strings:o,values:e}))(1),oo=Symbol.for("lit-noChange"),eo=Symbol.for("lit-nothing"),io=new WeakMap,ro=Pt.createTreeWalker(Pt,129);function no(t,o){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==zt?zt.createHTML(o):o}const ao=(t,o)=>{const e=t.length-1,i=[];let r,n=2===o?"<svg>":"",a=Gt;for(let o=0;o<e;o++){const e=t[o];let s,l,c=-1,p=0;for(;p<e.length&&(a.lastIndex=p,l=a.exec(e),null!==l);)p=a.lastIndex,a===Gt?"!--"===l[1]?a=Yt:void 0!==l[1]?a=Vt:void 0!==l[2]?(Qt.test(l[2])&&(r=RegExp("</"+l[2],"g")),a=Jt):void 0!==l[3]&&(a=Jt):a===Jt?">"===l[0]?(a=r??Gt,c=-1):void 0===l[1]?c=-2:(c=a.lastIndex-l[2].length,s=l[1],a=void 0===l[3]?Jt:'"'===l[3]?Xt:qt):a===Xt||a===qt?a=Jt:a===Yt||a===Vt?a=Gt:(a=Jt,r=void 0);const f=a===Jt&&t[o+1].startsWith("/>")?" ":"";n+=a===Gt?e+Bt:c>=0?(i.push(s),e.slice(0,c)+At+e.slice(c)+Mt+f):e+Mt+(-2===c?o:f)}return[no(t,n+(t[e]||"<?>")+(2===o?"</svg>":"")),i]};class so{constructor({strings:t,_$litType$:o},e){let i;this.parts=[];let r=0,n=0;const a=t.length-1,s=this.parts,[l,c]=ao(t,o);if(this.el=so.createElement(l,e),ro.currentNode=this.el.content,2===o){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(i=ro.nextNode())&&s.length<a;){if(1===i.nodeType){if(i.hasAttributes())for(const t of i.getAttributeNames())if(t.endsWith(At)){const o=c[n++],e=i.getAttribute(t).split(Mt),a=/([.?@])?(.*)/.exec(o);s.push({type:1,index:r,name:a[2],strings:e,ctor:"."===a[1]?fo:"?"===a[1]?ho:"@"===a[1]?uo:po}),i.removeAttribute(t)}else t.startsWith(Mt)&&(s.push({type:6,index:r}),i.removeAttribute(t));if(Qt.test(i.tagName)){const t=i.textContent.split(Mt),o=t.length-1;if(o>0){i.textContent=Zt?Zt.emptyScript:"";for(let e=0;e<o;e++)i.append(t[e],Ht()),ro.nextNode(),s.push({type:2,index:++r});i.append(t[o],Ht())}}}else if(8===i.nodeType)if(i.data===Dt)s.push({type:2,index:r});else{let t=-1;for(;-1!==(t=i.data.indexOf(Mt,t+1));)s.push({type:7,index:r}),t+=Mt.length-1}r++}}static createElement(t,o){const e=Pt.createElement("template");return e.innerHTML=t,e}}function lo(t,o,e=t,i){if(o===oo)return o;let r=void 0!==i?e._$Co?.[i]:e._$Cl;const n=jt(o)?void 0:o._$litDirective$;return r?.constructor!==n&&(r?._$AO?.(!1),void 0===n?r=void 0:(r=new n(t),r._$AT(t,e,i)),void 0!==i?(e._$Co??=[])[i]=r:e._$Cl=r),void 0!==r&&(o=lo(t,r._$AS(t,o.values),r,i)),o}class co{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,o,e,i){this.type=2,this._$AH=eo,this._$AN=void 0,this._$AA=t,this._$AB=o,this._$AM=e,this.options=i,this._$Cv=i?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const o=this._$AM;return void 0!==o&&11===t?.nodeType&&(t=o.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,o=this){t=lo(this,t,o),jt(t)?t===eo||null==t||""===t?(this._$AH!==eo&&this._$AR(),this._$AH=eo):t!==this._$AH&&t!==oo&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>Tt(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==eo&&jt(this._$AH)?this._$AA.nextSibling.data=t:this.$(Pt.createTextNode(t)),this._$AH=t}g(t){const{values:o,_$litType$:e}=t,i="number"==typeof e?this._$AC(t):(void 0===e.el&&(e.el=so.createElement(no(e.h,e.h[0]),this.options)),e);if(this._$AH?._$AD===i)this._$AH.p(o);else{const t=new class{constructor(t,o){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=o}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:o},parts:e}=this._$AD,i=(t?.creationScope??Pt).importNode(o,!0);ro.currentNode=i;let r=ro.nextNode(),n=0,a=0,s=e[0];for(;void 0!==s;){if(n===s.index){let o;2===s.type?o=new co(r,r.nextSibling,this,t):1===s.type?o=new s.ctor(r,s.name,s.strings,this,t):6===s.type&&(o=new yo(r,this,t)),this._$AV.push(o),s=e[++a]}n!==s?.index&&(r=ro.nextNode(),n++)}return ro.currentNode=Pt,i}p(t){let o=0;for(const e of this._$AV)void 0!==e&&(void 0!==e.strings?(e._$AI(t,e,o),o+=e.strings.length-2):e._$AI(t[o])),o++}}(i,this),e=t.u(this.options);t.p(o),this.$(e),this._$AH=t}}_$AC(t){let o=io.get(t.strings);return void 0===o&&io.set(t.strings,o=new so(t)),o}T(t){Tt(this._$AH)||(this._$AH=[],this._$AR());const o=this._$AH;let e,i=0;for(const r of t)i===o.length?o.push(e=new co(this.k(Ht()),this.k(Ht()),this,this.options)):e=o[i],e._$AI(r),i++;i<o.length&&(this._$AR(e&&e._$AB.nextSibling,i),o.length=i)}_$AR(t=this._$AA.nextSibling,o){for(this._$AP?.(!1,!0,o);t&&t!==this._$AB;){const o=t.nextSibling;t.remove(),t=o}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}}class po{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,o,e,i,r){this.type=1,this._$AH=eo,this._$AN=void 0,this.element=t,this.name=o,this._$AM=i,this.options=r,e.length>2||""!==e[0]||""!==e[1]?(this._$AH=Array(e.length-1).fill(new String),this.strings=e):this._$AH=eo}_$AI(t,o=this,e,i){const r=this.strings;let n=!1;if(void 0===r)t=lo(this,t,o,0),n=!jt(t)||t!==this._$AH&&t!==oo,n&&(this._$AH=t);else{const i=t;let a,s;for(t=r[0],a=0;a<r.length-1;a++)s=lo(this,i[e+a],o,a),s===oo&&(s=this._$AH[a]),n||=!jt(s)||s!==this._$AH[a],s===eo?t=eo:t!==eo&&(t+=(s??"")+r[a+1]),this._$AH[a]=s}n&&!i&&this.O(t)}O(t){t===eo?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class fo extends po{constructor(){super(...arguments),this.type=3}O(t){this.element[this.name]=t===eo?void 0:t}}class ho extends po{constructor(){super(...arguments),this.type=4}O(t){this.element.toggleAttribute(this.name,!!t&&t!==eo)}}class uo extends po{constructor(t,o,e,i,r){super(t,o,e,i,r),this.type=5}_$AI(t,o=this){if((t=lo(this,t,o,0)??eo)===oo)return;const e=this._$AH,i=t===eo&&e!==eo||t.capture!==e.capture||t.once!==e.once||t.passive!==e.passive,r=t!==eo&&(e===eo||i);i&&this.element.removeEventListener(this.name,this,e),r&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}}class yo{constructor(t,o,e){this.element=t,this.type=6,this._$AN=void 0,this._$AM=o,this.options=e}get _$AU(){return this._$AM._$AU}_$AI(t){lo(this,t)}}const go=Ft.litHtmlPolyfillSupport;go?.(so,co),(Ft.litHtmlVersions??=[]).push("3.1.0");
|
|
80
80
|
/**
|
|
81
81
|
* @license
|
|
82
82
|
* Copyright 2017 Google LLC
|
|
@@ -87,9 +87,9 @@ class bo extends Kt{constructor(){super(...arguments),this.renderOptions={host:t
|
|
|
87
87
|
* @license
|
|
88
88
|
* Copyright 2019 Google LLC
|
|
89
89
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
90
|
-
*/class Eo extends bo{createRenderRoot(){const t=this.constructor;t.elementDefinitions&&!t.registry&&(t.registry=new CustomElementRegistry,Object.entries(t.elementDefinitions).forEach((([o,e])=>t.registry.define(o,e))));const o={...t.shadowRootOptions,customElements:t.registry},e=this.renderOptions.creationScope=this.attachShadow(o);return((t,o)=>{$o?t.adoptedStyleSheets=o.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet)):o.forEach((o=>{const e=document.createElement("style"),i=Ro.litNonce;void 0!==i&&e.setAttribute("nonce",i),e.textContent=o.cssText,t.appendChild(e)}))})(e,t.elementStyles),e}}var Uo,ko=function(t,o,e,i){for(var r,n=arguments.length,a=n<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,e):i,s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(o,e,a):r(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};const Io=Symbol("constructorPrototype"),Wo=Symbol("constructorName"),Lo=Symbol("exportpartsDebouncer");class Ko extends Eo{constructor(){super(),this[Uo]=new U(5),this[Wo]=this.constructor.name,this[Io]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[Wo]&&Object.setPrototypeOf(this,this[Io])}updated(t){super.updated(t),setTimeout((()=>{this.contentAvailableCallback(t),this.scheduleExportpartsUpdate()}),0)}contentAvailableCallback(t){var o,e;if((null!==(e=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))&&void 0!==e?e:[]).forEach((t=>t.remove())),this.customStylesheet){const t=document.createElement("style");t.classList.add("ft-lit-element--custom-stylesheet"),t.innerHTML=this.customStylesheet,this.shadowRoot.append(t)}}scheduleExportpartsUpdate(){this[Lo].run((()=>{var t;(null===(t=this.exportpartsPrefix)||void 0===t?void 0:t.trim())?this.setExportpartsAttribute([this.exportpartsPrefix]):null!=this.exportpartsPrefixes&&this.exportpartsPrefixes.length>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)}))}setExportpartsAttribute(t){var o,e,i,r,n,a;const s=t=>null!=t&&t.trim().length>0,l=t.filter(s).map((t=>t.trim()));if(0===l.length)return void this.removeAttribute("exportparts");const c=new Set;for(let t of null!==(e=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll("[part],[exportparts]"))&&void 0!==e?e:[]){const o=null!==(r=null===(i=t.getAttribute("part"))||void 0===i?void 0:i.split(" "))&&void 0!==r?r:[],e=null!==(a=null===(n=t.getAttribute("exportparts"))||void 0===n?void 0:n.split(",").map((t=>t.split(":")[1])))&&void 0!==a?a:[];new Array(...o,...e).filter(s).map((t=>t.trim())).forEach((t=>c.add(t)))}if(0===c.size)return void this.removeAttribute("exportparts");const p=[...c.values()].flatMap((t=>l.map((o=>`${t}:${o}--${t}`))));this.setAttribute("exportparts",[...this.part,...p].join(", "))}}Uo=Lo,ko([S()],Ko.prototype,"exportpartsPrefix",void 0),ko([function(t,o){const e=()=>JSON.parse(JSON.stringify(t));return S({type:Object,converter:{fromAttribute:t=>{if(null==t)return e();try{return JSON.parse(t)}catch{return e()}},toAttribute:t=>JSON.stringify(t)},hasChanged:(t,o)=>!k(t,o),...null!=o?o:{}})}([])],Ko.prototype,"exportpartsPrefixes",void 0),ko([S()],Ko.prototype,"customStylesheet",void 0);const
|
|
90
|
+
*/class Eo extends bo{createRenderRoot(){const t=this.constructor;t.elementDefinitions&&!t.registry&&(t.registry=new CustomElementRegistry,Object.entries(t.elementDefinitions).forEach((([o,e])=>t.registry.define(o,e))));const o={...t.shadowRootOptions,customElements:t.registry},e=this.renderOptions.creationScope=this.attachShadow(o);return((t,o)=>{$o?t.adoptedStyleSheets=o.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet)):o.forEach((o=>{const e=document.createElement("style"),i=Ro.litNonce;void 0!==i&&e.setAttribute("nonce",i),e.textContent=o.cssText,t.appendChild(e)}))})(e,t.elementStyles),e}}var Uo,ko=function(t,o,e,i){for(var r,n=arguments.length,a=n<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,e):i,s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(o,e,a):r(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};const Io=Symbol("constructorPrototype"),Wo=Symbol("constructorName"),Lo=Symbol("exportpartsDebouncer");class Ko extends Eo{constructor(){super(),this[Uo]=new U(5),this[Wo]=this.constructor.name,this[Io]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[Wo]&&Object.setPrototypeOf(this,this[Io])}updated(t){super.updated(t),setTimeout((()=>{this.contentAvailableCallback(t),this.scheduleExportpartsUpdate()}),0)}contentAvailableCallback(t){var o,e;if((null!==(e=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))&&void 0!==e?e:[]).forEach((t=>t.remove())),this.customStylesheet){const t=document.createElement("style");t.classList.add("ft-lit-element--custom-stylesheet"),t.innerHTML=this.customStylesheet,this.shadowRoot.append(t)}}scheduleExportpartsUpdate(){this[Lo].run((()=>{var t;(null===(t=this.exportpartsPrefix)||void 0===t?void 0:t.trim())?this.setExportpartsAttribute([this.exportpartsPrefix]):null!=this.exportpartsPrefixes&&this.exportpartsPrefixes.length>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)}))}setExportpartsAttribute(t){var o,e,i,r,n,a;const s=t=>null!=t&&t.trim().length>0,l=t.filter(s).map((t=>t.trim()));if(0===l.length)return void this.removeAttribute("exportparts");const c=new Set;for(let t of null!==(e=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll("[part],[exportparts]"))&&void 0!==e?e:[]){const o=null!==(r=null===(i=t.getAttribute("part"))||void 0===i?void 0:i.split(" "))&&void 0!==r?r:[],e=null!==(a=null===(n=t.getAttribute("exportparts"))||void 0===n?void 0:n.split(",").map((t=>t.split(":")[1])))&&void 0!==a?a:[];new Array(...o,...e).filter(s).map((t=>t.trim())).forEach((t=>c.add(t)))}if(0===c.size)return void this.removeAttribute("exportparts");const p=[...c.values()].flatMap((t=>l.map((o=>`${t}:${o}--${t}`))));this.setAttribute("exportparts",[...this.part,...p].join(", "))}}Uo=Lo,ko([S()],Ko.prototype,"exportpartsPrefix",void 0),ko([function(t,o){const e=()=>JSON.parse(JSON.stringify(t));return S({type:Object,converter:{fromAttribute:t=>{if(null==t)return e();try{return JSON.parse(t)}catch{return e()}},toAttribute:t=>JSON.stringify(t)},hasChanged:(t,o)=>!k(t,o),...null!=o?o:{}})}([])],Ko.prototype,"exportpartsPrefixes",void 0),ko([S()],Ko.prototype,"customStylesheet",void 0);const Fo=Oo.create("--ft-utils-highlight-html-background-color","","COLOR","#FFF26E");mt`
|
|
91
91
|
.highlight-html-match {
|
|
92
|
-
background: ${
|
|
92
|
+
background: ${Fo};
|
|
93
93
|
}
|
|
94
94
|
`,mt`
|
|
95
95
|
.ft-no-text-select {
|
|
@@ -112,7 +112,7 @@ class bo extends Kt{constructor(){super(...arguments),this.renderOptions={host:t
|
|
|
112
112
|
-webkit-hyphens: auto;
|
|
113
113
|
hyphens: auto
|
|
114
114
|
}
|
|
115
|
-
`;const
|
|
115
|
+
`;const Zo=mt`
|
|
116
116
|
.ft-safari-ellipsis-fix {
|
|
117
117
|
margin-right: 0;
|
|
118
118
|
|
|
@@ -123,17 +123,17 @@ class bo extends Kt{constructor(){super(...arguments),this.renderOptions={host:t
|
|
|
123
123
|
display: inline-block;
|
|
124
124
|
width: 0;
|
|
125
125
|
}
|
|
126
|
-
`;var
|
|
126
|
+
`;function zo(t){var o;return null!==(o=null==t?void 0:t.isFtReduxStore)&&void 0!==o&&o}var Ao,Mo,Do;const Bo=Symbol("internalReduxEventsUnsubscribers"),Po=Symbol("internalStoresUnsubscribers"),Ho=Symbol("internalStores");class jo extends Ko{constructor(){super(...arguments),this[Ao]=new Map,this[Mo]=new Map,this[Do]=[]}get reduxConstructor(){return this.constructor}update(t){super.update(t),[...this.reduxConstructor.reduxReactiveProperties].some((o=>t.has(o)))&&this.updateFromStores()}getUnnamedStore(){if(this[Ho].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Ho].values()][0]}getStore(t){return null==t?this.getUnnamedStore():this[Ho].get(t)}addStore(t,o){var e;o=null!==(e=null!=o?o:zo(t)?t.name:void 0)&&void 0!==e?e:"default-store",this.unsubscribeFromStore(o),this.setupStore(o,t)}removeStore(t){const o="string"==typeof t?t:t.name;this.unsubscribeFromStore(o),this[Ho].delete(o)}setupStore(t,o){this[Ho].set(t,o),this.subscribeToStore(t,o),this.updateFromStores()}setupStores(){this.unsubscribeFromStores(),this[Ho].forEach(((t,o)=>this.subscribeToStore(o,t))),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach(((t,o)=>{const e=this.constructor.getPropertyOptions(o);if(!(null==e?void 0:e.attribute)||!this.hasAttribute("string"==typeof(null==e?void 0:e.attribute)?e.attribute:o)){const e=this.getStore(t.store);e&&(t.store?this[Po].has(t.store):this[Po].size>0)&&(this[o]=t.selector(e.getState(),this))}}))}subscribeToStore(t,o){var e;this[Po].set(t,o.subscribe((()=>this.updateFromStores()))),zo(o)&&o.eventBus&&(null===(e=this.reduxConstructor.reduxEventListeners)||void 0===e||e.forEach(((t,e)=>{if("function"==typeof this[e]&&(!t.store||o.name===t.store)){const i=t=>this[e](t);o.eventBus.addEventListener(t.eventName,i),this[Bo].push((()=>o.eventBus.removeEventListener(t.eventName,i)))}}))),this.onStoreAvailable(t)}unsubscribeFromStores(){this[Po].forEach(((t,o)=>this.unsubscribeFromStore(o))),this[Bo].forEach((t=>t())),this[Bo]=[]}unsubscribeFromStore(t){this[Po].has(t)&&this[Po].get(t)(),this[Po].delete(t)}onStoreAvailable(t){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}var To,_o,Go;Ao=Po,Mo=Ho,Do=Bo,jo.reduxProperties=new Map,jo.reduxReactiveProperties=new Set,jo.reduxEventListeners=new Map,window.ftReduxStores||(window.ftReduxStores={});const Yo=navigator.vendor&&!!navigator.vendor.match(/apple/i)||"[object SafariRemoteNotification]"===(null!==(Go=null===(_o=null===(To=window.safari)||void 0===To?void 0:To.pushNotification)||void 0===_o?void 0:_o.toString())&&void 0!==Go?Go:""),Vo=1,Jo=2,qo=t=>(...o)=>({_$litDirective$:t,values:o});
|
|
127
127
|
/**
|
|
128
128
|
* @license
|
|
129
129
|
* Copyright 2017 Google LLC
|
|
130
130
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
131
|
-
*/let
|
|
131
|
+
*/let Xo=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,o,e){this._$Ct=t,this._$AM=o,this._$Ci=e}_$AS(t,o){return this.update(t,o)}update(t,o){return this.render(...o)}};
|
|
132
132
|
/**
|
|
133
133
|
* @license
|
|
134
134
|
* Copyright 2018 Google LLC
|
|
135
135
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
136
|
-
*/const
|
|
136
|
+
*/const Qo=qo(class extends Xo{constructor(t){if(super(t),t.type!==Vo||"class"!==t.name||t.strings?.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((o=>t[o])).join(" ")+" "}update(t,[o]){if(void 0===this.it){this.it=new Set,void 0!==t.strings&&(this.st=new Set(t.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in o)o[t]&&!this.st?.has(t)&&this.it.add(t);return this.render(o)}const e=t.element.classList;for(const t of this.it)t in o||(e.remove(t),this.it.delete(t));for(const t in o){const i=!!o[t];i===this.it.has(t)||this.st?.has(t)||(i?(e.add(t),this.it.add(t)):(e.remove(t),this.it.delete(t)))}return X}}),te=Oo.extend("--ft-ripple-color","",Co.colorContent),oe={color:te,backgroundColor:Oo.extend("--ft-ripple-background-color","",te),opacityContentOnSurfacePressed:Oo.external(Co.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:Oo.external(Co.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:Oo.external(Co.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:Oo.external(Co.opacityContentOnSurfaceSelected,"Design system"),borderRadius:Oo.create("--ft-ripple-border-radius","","SIZE","0px")},ee=Oo.extend("--ft-ripple-color","",Co.colorPrimary),ie=ee,re=Oo.extend("--ft-ripple-background-color","",ee),ne=Oo.extend("--ft-ripple-color","",Co.colorSecondary),ae=ne,se=Oo.extend("--ft-ripple-background-color","",ne),le=mt`
|
|
137
137
|
:host {
|
|
138
138
|
display: contents;
|
|
139
139
|
}
|
|
@@ -146,7 +146,7 @@ class bo extends Kt{constructor(){super(...arguments),this.renderOptions={host:t
|
|
|
146
146
|
|
|
147
147
|
.ft-ripple:not(.ft-ripple--unbounded) {
|
|
148
148
|
overflow: hidden;
|
|
149
|
-
border-radius: ${
|
|
149
|
+
border-radius: ${oe.borderRadius};
|
|
150
150
|
}
|
|
151
151
|
|
|
152
152
|
.ft-ripple .ft-ripple--background,
|
|
@@ -180,27 +180,27 @@ class bo extends Kt{constructor(){super(...arguments),this.renderOptions={host:t
|
|
|
180
180
|
}
|
|
181
181
|
|
|
182
182
|
.ft-ripple .ft-ripple--background {
|
|
183
|
-
background-color: ${
|
|
183
|
+
background-color: ${oe.backgroundColor};
|
|
184
184
|
}
|
|
185
185
|
|
|
186
186
|
.ft-ripple .ft-ripple--effect {
|
|
187
|
-
background-color: ${
|
|
187
|
+
background-color: ${oe.color};
|
|
188
188
|
}
|
|
189
189
|
|
|
190
190
|
.ft-ripple.ft-ripple--secondary .ft-ripple--background {
|
|
191
|
-
background-color: ${
|
|
191
|
+
background-color: ${se};
|
|
192
192
|
}
|
|
193
193
|
|
|
194
194
|
.ft-ripple.ft-ripple--secondary .ft-ripple--effect {
|
|
195
|
-
background-color: ${
|
|
195
|
+
background-color: ${ae};
|
|
196
196
|
}
|
|
197
197
|
|
|
198
198
|
.ft-ripple.ft-ripple--primary .ft-ripple--background {
|
|
199
|
-
background-color: ${
|
|
199
|
+
background-color: ${re};
|
|
200
200
|
}
|
|
201
201
|
|
|
202
202
|
.ft-ripple.ft-ripple--primary .ft-ripple--effect {
|
|
203
|
-
background-color: ${
|
|
203
|
+
background-color: ${ie};
|
|
204
204
|
}
|
|
205
205
|
|
|
206
206
|
.ft-ripple .ft-ripple--background {
|
|
@@ -230,134 +230,134 @@ class bo extends Kt{constructor(){super(...arguments),this.renderOptions={host:t
|
|
|
230
230
|
}
|
|
231
231
|
|
|
232
232
|
.ft-ripple.ft-ripple--hovered .ft-ripple--background {
|
|
233
|
-
opacity: ${
|
|
233
|
+
opacity: ${oe.opacityContentOnSurfaceHover};
|
|
234
234
|
}
|
|
235
235
|
|
|
236
236
|
.ft-ripple.ft-ripple--selected .ft-ripple--background {
|
|
237
|
-
opacity: ${
|
|
237
|
+
opacity: ${oe.opacityContentOnSurfaceSelected};
|
|
238
238
|
}
|
|
239
239
|
|
|
240
240
|
.ft-ripple.ft-ripple--focused .ft-ripple--background {
|
|
241
|
-
opacity: ${
|
|
241
|
+
opacity: ${oe.opacityContentOnSurfaceFocused};
|
|
242
242
|
}
|
|
243
243
|
|
|
244
244
|
.ft-ripple.ft-ripple--pressed .ft-ripple--effect {
|
|
245
|
-
opacity: ${
|
|
245
|
+
opacity: ${oe.opacityContentOnSurfacePressed};
|
|
246
246
|
transform: translate(-50%, -50%) scale(1);
|
|
247
247
|
}
|
|
248
|
-
`;var
|
|
248
|
+
`;var ce=function(t,o,e,i){for(var r,n=arguments.length,a=n<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,e):i,s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(o,e,a):r(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class pe extends Ko{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.originX=0,this.originY=0,this.debouncer=new U(1e3),this.onTransitionStart=t=>{"transform"===t.propertyName&&(this.rippling=this.pressed,this.debouncer.run((()=>this.rippling=!1)))},this.onTransitionEnd=t=>{"transform"===t.propertyName&&(this.rippling=!1)},this.setupDebouncer=new U(10),this.moveRipple=t=>{var o,e;let{x:i,y:r}=this.getCoordinates(t),n=null!==(e=null===(o=this.ripple)||void 0===o?void 0:o.getBoundingClientRect())&&void 0!==e?e:{x:0,y:0,width:0,height:0};this.originX=Math.round(null!=i?i-n.x:n.width/2),this.originY=Math.round(null!=r?r-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.isFocusVisible(null==t?void 0:t.target)&&!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 to`
|
|
249
249
|
<style>
|
|
250
250
|
.ft-ripple .ft-ripple--effect {
|
|
251
251
|
left: ${this.originX}px;
|
|
252
252
|
top: ${this.originY}px;
|
|
253
253
|
}
|
|
254
254
|
</style>
|
|
255
|
-
<div class="${
|
|
255
|
+
<div class="${Qo(t)}">
|
|
256
256
|
<div class="ft-ripple--background"></div>
|
|
257
257
|
<div class="ft-ripple--effect"></div>
|
|
258
258
|
</div>
|
|
259
|
-
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}update(t){var o,e;super.update(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(o=this.target)||void 0===o||o.removeAttribute("data-is-ft-ripple-target")):null===(e=this.target)||void 0===e||e.setAttribute("data-is-ft-ripple-target","true"))}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}connectedCallback(){super.connectedCallback(),this.setupDebouncer.run((()=>this.defaultSetup()))}defaultSetup(){var t,o;const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(null!==(o=this.target)&&void 0!==o?o:e)}setupFor(t){if(this.setupDebouncer.cancel(),this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const o=(...t)=>o=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(o)},e=o("mouseup","contextmenu"),i=o("touchend","touchcancel"),r=t=>{["Enter"," "].includes(t.key)&&o("keyup")(t)},n={passive:!0};t.addEventListener("mouseover",this.startHover,n),t.addEventListener("mousemove",this.moveRipple,n),t.addEventListener("mouseleave",this.endHover,n),t.addEventListener("mousedown",e,n),t.addEventListener("touchstart",i,n),t.addEventListener("touchmove",this.moveRipple,n),t.addEventListener("keydown",r,n),t.addEventListener("focus",this.startFocus,n),t.addEventListener("blur",this.endFocus,n),t.addEventListener("focusin",this.startFocus,n),t.addEventListener("focusout",this.endFocus,n),this.onDisconnect=()=>{t.removeAttribute("data-is-ft-ripple-target"),t.removeEventListener("mouseover",this.startHover,n),t.removeEventListener("mousemove",this.moveRipple,n),t.removeEventListener("mouseleave",this.endHover,n),t.removeEventListener("mousedown",e,n),t.removeEventListener("touchstart",i,n),t.removeEventListener("touchmove",this.moveRipple,n),t.removeEventListener("keydown",r,n),t.removeEventListener("focus",this.startFocus,n),t.removeEventListener("blur",this.endFocus,n),t.removeEventListener("focusin",this.startFocus,n),t.removeEventListener("focusout",this.endFocus,n),this.onDisconnect=void 0,this.target=void 0}}getCoordinates(t){const o=t,e=t;let i,r;return null!=o.x?({x:i,y:r}=o):null!=e.touches&&(i=e.touches[0].clientX,r=e.touches[0].clientY),{x:i,y:r}}isFocusVisible(t){return!(t instanceof HTMLElement)||t.matches(":focus-visible")}isIgnored(t){if(this.disabled)return!0;if(null!=t)for(let o of t.composedPath()){if(o===this.target)break;if("hasAttribute"in o&&o.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.endRipple()}}
|
|
259
|
+
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}update(t){var o,e;super.update(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(o=this.target)||void 0===o||o.removeAttribute("data-is-ft-ripple-target")):null===(e=this.target)||void 0===e||e.setAttribute("data-is-ft-ripple-target","true"))}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}connectedCallback(){super.connectedCallback(),this.setupDebouncer.run((()=>this.defaultSetup()))}defaultSetup(){var t,o;const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(null!==(o=this.target)&&void 0!==o?o:e)}setupFor(t){if(this.setupDebouncer.cancel(),this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const o=(...t)=>o=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(o)},e=o("mouseup","contextmenu"),i=o("touchend","touchcancel"),r=t=>{["Enter"," "].includes(t.key)&&o("keyup")(t)},n={passive:!0};t.addEventListener("mouseover",this.startHover,n),t.addEventListener("mousemove",this.moveRipple,n),t.addEventListener("mouseleave",this.endHover,n),t.addEventListener("mousedown",e,n),t.addEventListener("touchstart",i,n),t.addEventListener("touchmove",this.moveRipple,n),t.addEventListener("keydown",r,n),t.addEventListener("focus",this.startFocus,n),t.addEventListener("blur",this.endFocus,n),t.addEventListener("focusin",this.startFocus,n),t.addEventListener("focusout",this.endFocus,n),this.onDisconnect=()=>{t.removeAttribute("data-is-ft-ripple-target"),t.removeEventListener("mouseover",this.startHover,n),t.removeEventListener("mousemove",this.moveRipple,n),t.removeEventListener("mouseleave",this.endHover,n),t.removeEventListener("mousedown",e,n),t.removeEventListener("touchstart",i,n),t.removeEventListener("touchmove",this.moveRipple,n),t.removeEventListener("keydown",r,n),t.removeEventListener("focus",this.startFocus,n),t.removeEventListener("blur",this.endFocus,n),t.removeEventListener("focusin",this.startFocus,n),t.removeEventListener("focusout",this.endFocus,n),this.onDisconnect=void 0,this.target=void 0}}getCoordinates(t){const o=t,e=t;let i,r;return null!=o.x?({x:i,y:r}=o):null!=e.touches&&(i=e.touches[0].clientX,r=e.touches[0].clientY),{x:i,y:r}}isFocusVisible(t){return!(t instanceof HTMLElement)||t.matches(":focus-visible")}isIgnored(t){if(this.disabled)return!0;if(null!=t)for(let o of t.composedPath()){if(o===this.target)break;if("hasAttribute"in o&&o.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.endRipple()}}pe.elementDefinitions={},pe.styles=le,ce([S({type:Boolean})],pe.prototype,"primary",void 0),ce([S({type:Boolean})],pe.prototype,"secondary",void 0),ce([S({type:Boolean})],pe.prototype,"unbounded",void 0),ce([S({type:Boolean})],pe.prototype,"activated",void 0),ce([S({type:Boolean})],pe.prototype,"selected",void 0),ce([S({type:Boolean})],pe.prototype,"disabled",void 0),ce([C()],pe.prototype,"hovered",void 0),ce([C()],pe.prototype,"focused",void 0),ce([C()],pe.prototype,"pressed",void 0),ce([C()],pe.prototype,"rippling",void 0),ce([C()],pe.prototype,"originX",void 0),ce([C()],pe.prototype,"originY",void 0),ce([E(".ft-ripple")],pe.prototype,"ripple",void 0),ce([E(".ft-ripple--effect")],pe.prototype,"rippleEffect",void 0),I("ft-ripple")(pe);
|
|
260
260
|
/**
|
|
261
261
|
* @license
|
|
262
262
|
* Copyright 2020 Google LLC
|
|
263
263
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
264
264
|
*/
|
|
265
|
-
const
|
|
265
|
+
const fe=Symbol.for(""),he=t=>{if(t?.r===fe)return t?._$litStatic$},de=t=>({_$litStatic$:t,r:fe}),ue=new Map,ye=(t=>(o,...e)=>{const i=e.length;let r,n;const a=[],s=[];let l,c=0,p=!1;for(;c<i;){for(l=o[c];c<i&&void 0!==(n=e[c],r=he(n));)l+=r+o[++c],p=!0;c!==i&&s.push(n),a.push(l),c++}if(c===i&&a.push(o[i]),p){const t=a.join("$$lit$$");void 0===(o=ue.get(t))&&(a.raw=a,ue.set(t,o=a)),e=s}return t(o,...e)})(q);var ge;!function(t){t.title="title",t.title_dense="title-dense",t.subtitle1="subtitle1",t.subtitle2="subtitle2",t.body1="body1",t.body2="body2",t.caption="caption",t.breadcrumb="breadcrumb",t.overline="overline",t.button="button",t.display="display",t.title1="title-1",t.title2="title-2",t.title3="title-3",t.body1regular="body-1-regular",t.body1medium="body-1-medium",t.body1semibold="body-1-semibold",t.body2regular="body-2-regular",t.body2medium="body-2-medium",t.body2semibold="body-2-semibold",t.label1medium="label-1-medium",t.label1semibold="label-1-semibold",t.label1bold="label-1-bold",t.label2medium="label-2-medium",t.label2semibold="label-2-semibold",t.label2bold="label-2-bold",t.caption1medium="caption-1-medium",t.caption1semibold="caption-1-semibold",t.caption1bold="caption-1-bold",t.caption2medium="caption-2-medium",t.caption2semibold="caption-2-semibold",t.caption2bold="caption-2-bold"}(ge||(ge={}));const be=Oo.extend("--ft-typography-font-family","",Co.titleFont),me=Oo.extend("--ft-typography-font-family","",Co.contentFont),xe={fontFamily:me,fontSize:Oo.create("--ft-typography-font-size","","SIZE","16px"),fontWeight:Oo.create("--ft-typography-font-weight","","UNKNOWN","normal"),letterSpacing:Oo.create("--ft-typography-letter-spacing","","SIZE","0.496px"),lineHeight:Oo.create("--ft-typography-line-height","","NUMBER","1.5"),textTransform:Oo.create("--ft-typography-text-transform","","UNKNOWN","inherit")},Oe=Oo.extend("--ft-typography-title-font-family","",be),ve=Oo.extend("--ft-typography-title-font-size","",xe.fontSize,"20px"),we=Oo.extend("--ft-typography-title-font-weight","",xe.fontWeight,"normal"),Ne=Oo.extend("--ft-typography-title-letter-spacing","",xe.letterSpacing,"0.15px"),Se=Oo.extend("--ft-typography-title-line-height","",xe.lineHeight,"1.2"),Ce=Oo.extend("--ft-typography-title-text-transform","",xe.textTransform,"inherit"),Re=Oo.extend("--ft-typography-title-dense-font-family","",be),$e=Oo.extend("--ft-typography-title-dense-font-size","",xe.fontSize,"14px"),Ee=Oo.extend("--ft-typography-title-dense-font-weight","",xe.fontWeight,"normal"),Ue=Oo.extend("--ft-typography-title-dense-letter-spacing","",xe.letterSpacing,"0.105px"),ke=Oo.extend("--ft-typography-title-dense-line-height","",xe.lineHeight,"1.7"),Ie=Oo.extend("--ft-typography-title-dense-text-transform","",xe.textTransform,"inherit"),We=Oo.extend("--ft-typography-subtitle1-font-family","",me),Le=Oo.extend("--ft-typography-subtitle1-font-size","",xe.fontSize,"16px"),Ke=Oo.extend("--ft-typography-subtitle1-font-weight","",xe.fontWeight,"600"),Fe=Oo.extend("--ft-typography-subtitle1-letter-spacing","",xe.letterSpacing,"0.144px"),Ze=Oo.extend("--ft-typography-subtitle1-line-height","",xe.lineHeight,"1.5"),ze=Oo.extend("--ft-typography-subtitle1-text-transform","",xe.textTransform,"inherit"),Ae=Oo.extend("--ft-typography-subtitle2-font-family","",me),Me=Oo.extend("--ft-typography-subtitle2-font-size","",xe.fontSize,"14px"),De=Oo.extend("--ft-typography-subtitle2-font-weight","",xe.fontWeight,"normal"),Be=Oo.extend("--ft-typography-subtitle2-letter-spacing","",xe.letterSpacing,"0.098px"),Pe=Oo.extend("--ft-typography-subtitle2-line-height","",xe.lineHeight,"1.7"),He=Oo.extend("--ft-typography-subtitle2-text-transform","",xe.textTransform,"inherit"),je=Oo.extend("--ft-typography-body1-font-family","",me),Te=Oo.extend("--ft-typography-body1-font-size","",xe.fontSize,"16px"),_e=Oo.extend("--ft-typography-body1-font-weight","",xe.fontWeight,"normal"),Ge=Oo.extend("--ft-typography-body1-letter-spacing","",xe.letterSpacing,"0.496px"),Ye=Oo.extend("--ft-typography-body1-line-height","",xe.lineHeight,"1.5"),Ve=Oo.extend("--ft-typography-body1-text-transform","",xe.textTransform,"inherit"),Je=Oo.extend("--ft-typography-body2-font-family","",me),qe=Oo.extend("--ft-typography-body2-font-size","",xe.fontSize,"14px"),Xe=Oo.extend("--ft-typography-body2-font-weight","",xe.fontWeight,"normal"),Qe=Oo.extend("--ft-typography-body2-letter-spacing","",xe.letterSpacing,"0.252px"),ti=Oo.extend("--ft-typography-body2-line-height","",xe.lineHeight,"1.4"),oi=Oo.extend("--ft-typography-body2-text-transform","",xe.textTransform,"inherit"),ei=Oo.extend("--ft-typography-caption-font-family","",me),ii=Oo.extend("--ft-typography-caption-font-size","",xe.fontSize,"12px"),ri=Oo.extend("--ft-typography-caption-font-weight","",xe.fontWeight,"normal"),ni=Oo.extend("--ft-typography-caption-letter-spacing","",xe.letterSpacing,"0.396px"),ai=Oo.extend("--ft-typography-caption-line-height","",xe.lineHeight,"1.33"),si=Oo.extend("--ft-typography-caption-text-transform","",xe.textTransform,"inherit"),li=Oo.extend("--ft-typography-breadcrumb-font-family","",me),ci=Oo.extend("--ft-typography-breadcrumb-font-size","",xe.fontSize,"10px"),pi=Oo.extend("--ft-typography-breadcrumb-font-weight","",xe.fontWeight,"normal"),fi=Oo.extend("--ft-typography-breadcrumb-letter-spacing","",xe.letterSpacing,"0.33px"),hi=Oo.extend("--ft-typography-breadcrumb-line-height","",xe.lineHeight,"1.6"),di=Oo.extend("--ft-typography-breadcrumb-text-transform","",xe.textTransform,"inherit"),ui=Oo.extend("--ft-typography-overline-font-family","",me),yi=Oo.extend("--ft-typography-overline-font-size","",xe.fontSize,"10px"),gi=Oo.extend("--ft-typography-overline-font-weight","",xe.fontWeight,"normal"),bi=Oo.extend("--ft-typography-overline-letter-spacing","",xe.letterSpacing,"1.5px"),mi=Oo.extend("--ft-typography-overline-line-height","",xe.lineHeight,"1.6"),xi=Oo.extend("--ft-typography-overline-text-transform","",xe.textTransform,"uppercase"),Oi={fontFamily:Oo.extend("--ft-typography-button-font-family","",me),fontSize:Oo.extend("--ft-typography-button-font-size","",xe.fontSize,"14px"),fontWeight:Oo.extend("--ft-typography-button-font-weight","",xe.fontWeight,"600"),letterSpacing:Oo.extend("--ft-typography-button-letter-spacing","",xe.letterSpacing,"1.246px"),lineHeight:Oo.extend("--ft-typography-button-line-height","",xe.lineHeight,"1.15"),textTransform:Oo.extend("--ft-typography-button-text-transform","",xe.textTransform,"uppercase")},vi=mt`
|
|
266
266
|
.ft-typography--title {
|
|
267
|
-
font-family: ${
|
|
268
|
-
font-size: ${
|
|
269
|
-
font-weight: ${
|
|
270
|
-
letter-spacing: ${
|
|
271
|
-
line-height: ${
|
|
272
|
-
text-transform: ${
|
|
273
|
-
}
|
|
274
|
-
`,
|
|
267
|
+
font-family: ${Oe};
|
|
268
|
+
font-size: ${ve};
|
|
269
|
+
font-weight: ${we};
|
|
270
|
+
letter-spacing: ${Ne};
|
|
271
|
+
line-height: ${Se};
|
|
272
|
+
text-transform: ${Ce};
|
|
273
|
+
}
|
|
274
|
+
`,wi=mt`
|
|
275
275
|
.ft-typography--title-dense {
|
|
276
|
-
font-family: ${
|
|
277
|
-
font-size: ${
|
|
278
|
-
font-weight: ${
|
|
279
|
-
letter-spacing: ${
|
|
280
|
-
line-height: ${
|
|
281
|
-
text-transform: ${
|
|
282
|
-
}
|
|
283
|
-
`,
|
|
276
|
+
font-family: ${Re};
|
|
277
|
+
font-size: ${$e};
|
|
278
|
+
font-weight: ${Ee};
|
|
279
|
+
letter-spacing: ${Ue};
|
|
280
|
+
line-height: ${ke};
|
|
281
|
+
text-transform: ${Ie};
|
|
282
|
+
}
|
|
283
|
+
`,Ni=mt`
|
|
284
284
|
.ft-typography--subtitle1 {
|
|
285
|
-
font-family: ${
|
|
286
|
-
font-size: ${
|
|
287
|
-
font-weight: ${
|
|
288
|
-
letter-spacing: ${
|
|
289
|
-
line-height: ${
|
|
290
|
-
text-transform: ${
|
|
291
|
-
}
|
|
292
|
-
`,
|
|
285
|
+
font-family: ${We};
|
|
286
|
+
font-size: ${Le};
|
|
287
|
+
font-weight: ${Ke};
|
|
288
|
+
letter-spacing: ${Fe};
|
|
289
|
+
line-height: ${Ze};
|
|
290
|
+
text-transform: ${ze};
|
|
291
|
+
}
|
|
292
|
+
`,Si=mt`
|
|
293
293
|
.ft-typography--subtitle2 {
|
|
294
|
-
font-family: ${
|
|
295
|
-
font-size: ${
|
|
296
|
-
font-weight: ${
|
|
297
|
-
letter-spacing: ${
|
|
298
|
-
line-height: ${
|
|
299
|
-
text-transform: ${
|
|
294
|
+
font-family: ${Ae};
|
|
295
|
+
font-size: ${Me};
|
|
296
|
+
font-weight: ${De};
|
|
297
|
+
letter-spacing: ${Be};
|
|
298
|
+
line-height: ${Pe};
|
|
299
|
+
text-transform: ${He};
|
|
300
300
|
}
|
|
301
301
|
|
|
302
|
-
`,
|
|
302
|
+
`,Ci=mt`
|
|
303
303
|
.ft-typography--body1 {
|
|
304
|
-
font-family: ${
|
|
305
|
-
font-size: ${
|
|
306
|
-
font-weight: ${
|
|
307
|
-
letter-spacing: ${
|
|
308
|
-
line-height: ${
|
|
309
|
-
text-transform: ${
|
|
310
|
-
}
|
|
311
|
-
`,
|
|
304
|
+
font-family: ${je};
|
|
305
|
+
font-size: ${Te};
|
|
306
|
+
font-weight: ${_e};
|
|
307
|
+
letter-spacing: ${Ge};
|
|
308
|
+
line-height: ${Ye};
|
|
309
|
+
text-transform: ${Ve};
|
|
310
|
+
}
|
|
311
|
+
`,Ri=mt`
|
|
312
312
|
.ft-typography--body2 {
|
|
313
|
-
font-family: ${
|
|
314
|
-
font-size: ${
|
|
315
|
-
font-weight: ${
|
|
316
|
-
letter-spacing: ${
|
|
317
|
-
line-height: ${
|
|
318
|
-
text-transform: ${
|
|
319
|
-
}
|
|
320
|
-
|
|
313
|
+
font-family: ${Je};
|
|
314
|
+
font-size: ${qe};
|
|
315
|
+
font-weight: ${Xe};
|
|
316
|
+
letter-spacing: ${Qe};
|
|
317
|
+
line-height: ${ti};
|
|
318
|
+
text-transform: ${oi};
|
|
319
|
+
}
|
|
320
|
+
`,$i=mt`
|
|
321
321
|
.ft-typography--caption {
|
|
322
|
-
font-family: ${
|
|
323
|
-
font-size: ${
|
|
324
|
-
font-weight: ${
|
|
325
|
-
letter-spacing: ${
|
|
326
|
-
line-height: ${
|
|
327
|
-
text-transform: ${
|
|
328
|
-
}
|
|
329
|
-
`,
|
|
322
|
+
font-family: ${ei};
|
|
323
|
+
font-size: ${ii};
|
|
324
|
+
font-weight: ${ri};
|
|
325
|
+
letter-spacing: ${ni};
|
|
326
|
+
line-height: ${ai};
|
|
327
|
+
text-transform: ${si};
|
|
328
|
+
}
|
|
329
|
+
`,Ei=mt`
|
|
330
330
|
.ft-typography--breadcrumb {
|
|
331
|
-
font-family: ${
|
|
332
|
-
font-size: ${
|
|
333
|
-
font-weight: ${
|
|
334
|
-
letter-spacing: ${
|
|
335
|
-
line-height: ${
|
|
336
|
-
text-transform: ${
|
|
337
|
-
}
|
|
338
|
-
`,
|
|
331
|
+
font-family: ${li};
|
|
332
|
+
font-size: ${ci};
|
|
333
|
+
font-weight: ${pi};
|
|
334
|
+
letter-spacing: ${fi};
|
|
335
|
+
line-height: ${hi};
|
|
336
|
+
text-transform: ${di};
|
|
337
|
+
}
|
|
338
|
+
`,Ui=mt`
|
|
339
339
|
.ft-typography--overline {
|
|
340
|
-
font-family: ${
|
|
341
|
-
font-size: ${
|
|
342
|
-
font-weight: ${
|
|
343
|
-
letter-spacing: ${
|
|
344
|
-
line-height: ${
|
|
345
|
-
text-transform: ${
|
|
346
|
-
}
|
|
347
|
-
`,
|
|
340
|
+
font-family: ${ui};
|
|
341
|
+
font-size: ${yi};
|
|
342
|
+
font-weight: ${gi};
|
|
343
|
+
letter-spacing: ${bi};
|
|
344
|
+
line-height: ${mi};
|
|
345
|
+
text-transform: ${xi};
|
|
346
|
+
}
|
|
347
|
+
`,ki=mt`
|
|
348
348
|
.ft-typography--button {
|
|
349
|
-
font-family: ${
|
|
350
|
-
font-size: ${
|
|
351
|
-
font-weight: ${
|
|
352
|
-
letter-spacing: ${
|
|
353
|
-
line-height: ${
|
|
354
|
-
text-transform: ${
|
|
355
|
-
}
|
|
356
|
-
`,
|
|
349
|
+
font-family: ${Oi.fontFamily};
|
|
350
|
+
font-size: ${Oi.fontSize};
|
|
351
|
+
font-weight: ${Oi.fontWeight};
|
|
352
|
+
letter-spacing: ${Oi.letterSpacing};
|
|
353
|
+
line-height: ${Oi.lineHeight};
|
|
354
|
+
text-transform: ${Oi.textTransform};
|
|
355
|
+
}
|
|
356
|
+
`,Ii=mt`
|
|
357
357
|
.ft-typography {
|
|
358
358
|
vertical-align: inherit;
|
|
359
359
|
}
|
|
360
|
-
`,
|
|
360
|
+
`,Wi=[Object.keys(No).map((t=>function(t){const o=No[t];return mt`
|
|
361
361
|
.ft-typography--${bt(t)} {
|
|
362
362
|
font-family: ${o.fontFamily};
|
|
363
363
|
font-size: ${o.fontSize};
|
|
@@ -366,14 +366,14 @@ const ie=Symbol.for(""),re=t=>{if(t?.r===ie)return t?._$litStatic$},ne=t=>({_$li
|
|
|
366
366
|
line-height: ${o.lineHeight};
|
|
367
367
|
text-transform: ${o.textCase};
|
|
368
368
|
}
|
|
369
|
-
`}(t)))];var
|
|
370
|
-
<${
|
|
369
|
+
`}(t)))];var Li=function(t,o,e,i){for(var r,n=arguments.length,a=n<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,e):i,s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(o,e,a):r(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class Ki extends Ko{constructor(){super(...arguments),this.variant=ge.body1}render(){return this.element?ye`
|
|
370
|
+
<${de(this.element)}
|
|
371
371
|
class="ft-typography ft-typography--${this.variant}">
|
|
372
372
|
<slot></slot>
|
|
373
|
-
</${
|
|
374
|
-
`:
|
|
373
|
+
</${de(this.element)}>
|
|
374
|
+
`:ye`
|
|
375
375
|
<slot class="ft-typography ft-typography--${this.variant}"></slot>
|
|
376
|
-
`}}
|
|
376
|
+
`}}Ki.styles=[vi,wi,Ni,Si,Ci,Ri,$i,Ei,Ui,ki,Ii,...Wi],Li([S()],Ki.prototype,"element",void 0),Li([S()],Ki.prototype,"variant",void 0),I("ft-typography")(Ki);const Fi=Oo.create("--ft-tooltip-distance","","SIZE","4px"),Zi=Oo.create("--ft-tooltip-color","","COLOR","#FFFFFF"),zi=Oo.create("--ft-tooltip-background-color","","COLOR","#666666"),Ai=Oo.create("--ft-tooltip-z-index","","NUMBER","100"),Mi=Oo.external(Co.borderRadiusS,"Design system"),Di=Oo.create("--ft-tooltip-max-width","","SIZE","150px"),Bi=mt`
|
|
377
377
|
.ft-tooltip--container {
|
|
378
378
|
display: block;
|
|
379
379
|
}
|
|
@@ -388,21 +388,21 @@ const ie=Symbol.for(""),re=t=>{if(t?.r===ie)return t?._$litStatic$},ne=t=>({_$li
|
|
|
388
388
|
box-sizing: border-box;
|
|
389
389
|
overflow: hidden;
|
|
390
390
|
width: max-content;
|
|
391
|
-
max-width: ${
|
|
391
|
+
max-width: ${Di};
|
|
392
392
|
text-align: center;
|
|
393
|
-
padding: ${
|
|
394
|
-
z-index: ${
|
|
393
|
+
padding: ${Fi};
|
|
394
|
+
z-index: ${Ai};
|
|
395
395
|
}
|
|
396
396
|
|
|
397
397
|
.ft-tooltip--content {
|
|
398
398
|
padding: 4px 8px;
|
|
399
|
-
border-radius: ${
|
|
400
|
-
background-color: ${
|
|
401
|
-
color: ${
|
|
399
|
+
border-radius: ${Mi};
|
|
400
|
+
background-color: ${zi};
|
|
401
|
+
color: ${Zi};
|
|
402
402
|
position: relative;
|
|
403
403
|
word-break: break-word;
|
|
404
404
|
}
|
|
405
|
-
`,Ki=["start","end"],Zi=["top","right","bottom","left"].reduce(((t,o)=>t.concat(o,o+"-"+Ki[0],o+"-"+Ki[1])),[]),zi=Math.min,Fi=Math.max,Ai=Math.round,Mi=t=>({x:t,y:t}),Di={left:"right",right:"left",bottom:"top",top:"bottom"},Bi={start:"end",end:"start"};function Pi(t,o,e){return Fi(t,zi(o,e))}function Hi(t,o){return"function"==typeof t?t(o):t}function ji(t){return t.split("-")[0]}function Ti(t){return t.split("-")[1]}function _i(t){return"x"===t?"y":"x"}function Gi(t){return"y"===t?"height":"width"}function Yi(t){return["top","bottom"].includes(ji(t))?"y":"x"}function Vi(t){return _i(Yi(t))}function Ji(t){return t.replace(/left|right|bottom|top/g,(t=>Di[t]))}function qi(t){return{...t,top:t.y,left:t.x,right:t.x+t.width,bottom:t.y+t.height}}function Xi(t,o,e){let{reference:i,floating:r}=t;const n=Yi(o),a=Vi(o),s=Gi(a),l=ji(o),c="y"===n,p=i.x+i.width/2-r.width/2,f=i.y+i.height/2-r.height/2,h=i[s]/2-r[s]/2;let d;switch(l){case"top":d={x:p,y:i.y-r.height};break;case"bottom":d={x:p,y:i.y+i.height};break;case"right":d={x:i.x+i.width,y:f};break;case"left":d={x:i.x-r.width,y:f};break;default:d={x:i.x,y:i.y}}switch(Ti(o)){case"start":d[a]-=h*(e&&c?-1:1);break;case"end":d[a]+=h*(e&&c?-1:1)}return d}async function Qi(t,o){var e;void 0===o&&(o={});const{x:i,y:r,platform:n,rects:a,elements:s,strategy:l}=t,{boundary:c="clippingAncestors",rootBoundary:p="viewport",elementContext:f="floating",altBoundary:h=!1,padding:d=0}=Hi(o,t),u=function(t){return"number"!=typeof t?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(t):{top:t,right:t,bottom:t,left:t}}(d),y=s[h?"floating"===f?"reference":"floating":f],g=qi(await n.getClippingRect({element:null==(e=await(null==n.isElement?void 0:n.isElement(y)))||e?y:y.contextElement||await(null==n.getDocumentElement?void 0:n.getDocumentElement(s.floating)),boundary:c,rootBoundary:p,strategy:l})),b="floating"===f?{...a.floating,x:i,y:r}:a.reference,m=await(null==n.getOffsetParent?void 0:n.getOffsetParent(s.floating)),x=await(null==n.isElement?void 0:n.isElement(m))&&await(null==n.getScale?void 0:n.getScale(m))||{x:1,y:1},O=qi(n.convertOffsetParentRelativeRectToViewportRelativeRect?await n.convertOffsetParentRelativeRectToViewportRelativeRect({rect:b,offsetParent:m,strategy:l}):b);return{top:(g.top-O.top+u.top)/x.y,bottom:(O.bottom-g.bottom+u.bottom)/x.y,left:(g.left-O.left+u.left)/x.x,right:(O.right-g.right+u.right)/x.x}}function tr(t,o,e){return(t?[...e.filter((o=>Ti(o)===t)),...e.filter((o=>Ti(o)!==t))]:e.filter((t=>ji(t)===t))).filter((e=>!t||(Ti(e)===t||!!o&&function(t){return t.replace(/start|end/g,(t=>Bi[t]))}(e)!==e)))}const or=function(t){return void 0===t&&(t={}),{name:"autoPlacement",options:t,async fn(o){var e,i,r;const{rects:n,middlewareData:a,placement:s,platform:l,elements:c}=o,{crossAxis:p=!1,alignment:f,allowedPlacements:h=Zi,autoAlignment:d=!0,...u}=Hi(t,o),y=void 0!==f||h===Zi?tr(f||null,d,h):h,g=await Qi(o,u),b=(null==(e=a.autoPlacement)?void 0:e.index)||0,m=y[b];if(null==m)return{};const x=function(t,o,e){void 0===e&&(e=!1);const i=Ti(t),r=Vi(t),n=Gi(r);let a="x"===r?i===(e?"end":"start")?"right":"left":"start"===i?"bottom":"top";return o.reference[n]>o.floating[n]&&(a=Ji(a)),[a,Ji(a)]}(m,n,await(null==l.isRTL?void 0:l.isRTL(c.floating)));if(s!==m)return{reset:{placement:y[0]}};const O=[g[ji(m)],g[x[0]],g[x[1]]],v=[...(null==(i=a.autoPlacement)?void 0:i.overflows)||[],{placement:m,overflows:O}],w=y[b+1];if(w)return{data:{index:b+1,overflows:v},reset:{placement:w}};const N=v.map((t=>{const o=Ti(t.placement);return[t.placement,o&&p?t.overflows.slice(0,2).reduce(((t,o)=>t+o),0):t.overflows[0],t.overflows]})).sort(((t,o)=>t[1]-o[1])),S=N.filter((t=>t[2].slice(0,Ti(t[0])?2:3).every((t=>t<=0)))),C=(null==(r=S[0])?void 0:r[0])||N[0][0];return C!==s?{data:{index:b+1,overflows:v},reset:{placement:C}}:{}}}};function er(t){return nr(t)?(t.nodeName||"").toLowerCase():"#document"}function ir(t){var o;return(null==t||null==(o=t.ownerDocument)?void 0:o.defaultView)||window}function rr(t){var o;return null==(o=(nr(t)?t.ownerDocument:t.document)||window.document)?void 0:o.documentElement}function nr(t){return t instanceof Node||t instanceof ir(t).Node}function ar(t){return t instanceof Element||t instanceof ir(t).Element}function sr(t){return t instanceof HTMLElement||t instanceof ir(t).HTMLElement}function lr(t){return"undefined"!=typeof ShadowRoot&&(t instanceof ShadowRoot||t instanceof ir(t).ShadowRoot)}function cr(t){const{overflow:o,overflowX:e,overflowY:i,display:r}=ur(t);return/auto|scroll|overlay|hidden|clip/.test(o+i+e)&&!["inline","contents"].includes(r)}function pr(t){return["table","td","th"].includes(er(t))}function fr(t){const o=hr(),e=ur(t);return"none"!==e.transform||"none"!==e.perspective||!!e.containerType&&"normal"!==e.containerType||!o&&!!e.backdropFilter&&"none"!==e.backdropFilter||!o&&!!e.filter&&"none"!==e.filter||["transform","perspective","filter"].some((t=>(e.willChange||"").includes(t)))||["paint","layout","strict","content"].some((t=>(e.contain||"").includes(t)))}function hr(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function dr(t){return["html","body","#document"].includes(er(t))}function ur(t){return ir(t).getComputedStyle(t)}function yr(t){return ar(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function gr(t){if("html"===er(t))return t;const o=t.assignedSlot||t.parentNode||lr(t)&&t.host||rr(t);return lr(o)?o.host:o}function br(t){const o=gr(t);return dr(o)?t.ownerDocument?t.ownerDocument.body:t.body:sr(o)&&cr(o)?o:br(o)}function mr(t,o,e){var i;void 0===o&&(o=[]),void 0===e&&(e=!0);const r=br(t),n=r===(null==(i=t.ownerDocument)?void 0:i.body),a=ir(r);return n?o.concat(a,a.visualViewport||[],cr(r)?r:[],a.frameElement&&e?mr(a.frameElement):[]):o.concat(r,mr(r,[],e))}function xr(t){const o=ur(t);let e=parseFloat(o.width)||0,i=parseFloat(o.height)||0;const r=sr(t),n=r?t.offsetWidth:e,a=r?t.offsetHeight:i,s=Ai(e)!==n||Ai(i)!==a;return s&&(e=n,i=a),{width:e,height:i,$:s}}function Or(t){return ar(t)?t:t.contextElement}function vr(t){const o=Or(t);if(!sr(o))return Mi(1);const e=o.getBoundingClientRect(),{width:i,height:r,$:n}=xr(o);let a=(n?Ai(e.width):e.width)/i,s=(n?Ai(e.height):e.height)/r;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const wr=Mi(0);function Nr(t){const o=ir(t);return hr()&&o.visualViewport?{x:o.visualViewport.offsetLeft,y:o.visualViewport.offsetTop}:wr}function Sr(t,o,e,i){void 0===o&&(o=!1),void 0===e&&(e=!1);const r=t.getBoundingClientRect(),n=Or(t);let a=Mi(1);o&&(i?ar(i)&&(a=vr(i)):a=vr(t));const s=function(t,o,e){return void 0===o&&(o=!1),!(!e||o&&e!==ir(t))&&o}(n,e,i)?Nr(n):Mi(0);let l=(r.left+s.x)/a.x,c=(r.top+s.y)/a.y,p=r.width/a.x,f=r.height/a.y;if(n){const t=ir(n),o=i&&ar(i)?ir(i):i;let e=t.frameElement;for(;e&&i&&o!==t;){const t=vr(e),o=e.getBoundingClientRect(),i=ur(e),r=o.left+(e.clientLeft+parseFloat(i.paddingLeft))*t.x,n=o.top+(e.clientTop+parseFloat(i.paddingTop))*t.y;l*=t.x,c*=t.y,p*=t.x,f*=t.y,l+=r,c+=n,e=ir(e).frameElement}}return qi({width:p,height:f,x:l,y:c})}function Cr(t){return Sr(rr(t)).left+yr(t).scrollLeft}function Rr(t,o,e){let i;if("viewport"===o)i=function(t,o){const e=ir(t),i=rr(t),r=e.visualViewport;let n=i.clientWidth,a=i.clientHeight,s=0,l=0;if(r){n=r.width,a=r.height;const t=hr();(!t||t&&"fixed"===o)&&(s=r.offsetLeft,l=r.offsetTop)}return{width:n,height:a,x:s,y:l}}(t,e);else if("document"===o)i=function(t){const o=rr(t),e=yr(t),i=t.ownerDocument.body,r=Fi(o.scrollWidth,o.clientWidth,i.scrollWidth,i.clientWidth),n=Fi(o.scrollHeight,o.clientHeight,i.scrollHeight,i.clientHeight);let a=-e.scrollLeft+Cr(t);const s=-e.scrollTop;return"rtl"===ur(i).direction&&(a+=Fi(o.clientWidth,i.clientWidth)-r),{width:r,height:n,x:a,y:s}}(rr(t));else if(ar(o))i=function(t,o){const e=Sr(t,!0,"fixed"===o),i=e.top+t.clientTop,r=e.left+t.clientLeft,n=sr(t)?vr(t):Mi(1);return{width:t.clientWidth*n.x,height:t.clientHeight*n.y,x:r*n.x,y:i*n.y}}(o,e);else{const e=Nr(t);i={...o,x:o.x-e.x,y:o.y-e.y}}return qi(i)}function $r(t,o){const e=gr(t);return!(e===o||!ar(e)||dr(e))&&("fixed"===ur(e).position||$r(e,o))}function Er(t,o,e){const i=sr(o),r=rr(o),n="fixed"===e,a=Sr(t,!0,n,o);let s={scrollLeft:0,scrollTop:0};const l=Mi(0);if(i||!i&&!n)if(("body"!==er(o)||cr(r))&&(s=yr(o)),i){const t=Sr(o,!0,n,o);l.x=t.x+o.clientLeft,l.y=t.y+o.clientTop}else r&&(l.x=Cr(r));return{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function Ur(t,o){return sr(t)&&"fixed"!==ur(t).position?o?o(t):t.offsetParent:null}function kr(t,o){const e=ir(t);if(!sr(t))return e;let i=Ur(t,o);for(;i&&pr(i)&&"static"===ur(i).position;)i=Ur(i,o);return i&&("html"===er(i)||"body"===er(i)&&"static"===ur(i).position&&!fr(i))?e:i||function(t){let o=gr(t);for(;sr(o)&&!dr(o);){if(fr(o))return o;o=gr(o)}return null}(t)||e}const Ir={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{rect:o,offsetParent:e,strategy:i}=t;const r=sr(e),n=rr(e);if(e===n)return o;let a={scrollLeft:0,scrollTop:0},s=Mi(1);const l=Mi(0);if((r||!r&&"fixed"!==i)&&(("body"!==er(e)||cr(n))&&(a=yr(e)),sr(e))){const t=Sr(e);s=vr(e),l.x=t.x+e.clientLeft,l.y=t.y+e.clientTop}return{width:o.width*s.x,height:o.height*s.y,x:o.x*s.x-a.scrollLeft*s.x+l.x,y:o.y*s.y-a.scrollTop*s.y+l.y}},getDocumentElement:rr,getClippingRect:function(t){let{element:o,boundary:e,rootBoundary:i,strategy:r}=t;const n=[..."clippingAncestors"===e?function(t,o){const e=o.get(t);if(e)return e;let i=mr(t,[],!1).filter((t=>ar(t)&&"body"!==er(t))),r=null;const n="fixed"===ur(t).position;let a=n?gr(t):t;for(;ar(a)&&!dr(a);){const o=ur(a),e=fr(a);e||"fixed"!==o.position||(r=null),(n?!e&&!r:!e&&"static"===o.position&&r&&["absolute","fixed"].includes(r.position)||cr(a)&&!e&&$r(t,a))?i=i.filter((t=>t!==a)):r=o,a=gr(a)}return o.set(t,i),i}(o,this._c):[].concat(e),i],a=n[0],s=n.reduce(((t,e)=>{const i=Rr(o,e,r);return t.top=Fi(i.top,t.top),t.right=zi(i.right,t.right),t.bottom=zi(i.bottom,t.bottom),t.left=Fi(i.left,t.left),t}),Rr(o,a,r));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:kr,getElementRects:async function(t){let{reference:o,floating:e,strategy:i}=t;const r=this.getOffsetParent||kr,n=this.getDimensions;return{reference:Er(o,await r(e),i),floating:{x:0,y:0,...await n(e)}}},getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){return xr(t)},getScale:vr,isElement:ar,isRTL:function(t){return"rtl"===ur(t).direction}},Wr=(t,o,e)=>{const i=new Map,r={platform:Ir,...e},n={...r.platform,_c:i};return(async(t,o,e)=>{const{placement:i="bottom",strategy:r="absolute",middleware:n=[],platform:a}=e,s=n.filter(Boolean),l=await(null==a.isRTL?void 0:a.isRTL(o));let c=await a.getElementRects({reference:t,floating:o,strategy:r}),{x:p,y:f}=Xi(c,i,l),h=i,d={},u=0;for(let e=0;e<s.length;e++){const{name:n,fn:y}=s[e],{x:g,y:b,data:m,reset:x}=await y({x:p,y:f,initialPlacement:i,placement:h,strategy:r,middlewareData:d,rects:c,platform:a,elements:{reference:t,floating:o}});p=null!=g?g:p,f=null!=b?b:f,d={...d,[n]:{...d[n],...m}},x&&u<=50&&(u++,"object"==typeof x&&(x.placement&&(h=x.placement),x.rects&&(c=!0===x.rects?await a.getElementRects({reference:t,floating:o,strategy:r}):x.rects),({x:p,y:f}=Xi(c,h,l))),e=-1)}return{x:p,y:f,placement:h,strategy:r,middlewareData:d}})(t,o,{...r,platform:n})};var Lr=function(t,o,e,i){for(var r,n=arguments.length,a=n<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,e):i,s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(o,e,a):r(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class Kr extends Ko{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.validPositions=new Set(["top","bottom","left","right"]),this.hideDebounce=new U,this.revealDebouncer=new U}get validPosition(){return this.validPositions.has(this.position)?this.position:"bottom"}render(){return to`
|
|
405
|
+
`,Pi=["start","end"],Hi=["top","right","bottom","left"].reduce(((t,o)=>t.concat(o,o+"-"+Pi[0],o+"-"+Pi[1])),[]),ji=Math.min,Ti=Math.max,_i=Math.round,Gi=t=>({x:t,y:t}),Yi={left:"right",right:"left",bottom:"top",top:"bottom"},Vi={start:"end",end:"start"};function Ji(t,o,e){return Ti(t,ji(o,e))}function qi(t,o){return"function"==typeof t?t(o):t}function Xi(t){return t.split("-")[0]}function Qi(t){return t.split("-")[1]}function tr(t){return"x"===t?"y":"x"}function or(t){return"y"===t?"height":"width"}function er(t){return["top","bottom"].includes(Xi(t))?"y":"x"}function ir(t){return tr(er(t))}function rr(t){return t.replace(/left|right|bottom|top/g,(t=>Yi[t]))}function nr(t){return{...t,top:t.y,left:t.x,right:t.x+t.width,bottom:t.y+t.height}}function ar(t,o,e){let{reference:i,floating:r}=t;const n=er(o),a=ir(o),s=or(a),l=Xi(o),c="y"===n,p=i.x+i.width/2-r.width/2,f=i.y+i.height/2-r.height/2,h=i[s]/2-r[s]/2;let d;switch(l){case"top":d={x:p,y:i.y-r.height};break;case"bottom":d={x:p,y:i.y+i.height};break;case"right":d={x:i.x+i.width,y:f};break;case"left":d={x:i.x-r.width,y:f};break;default:d={x:i.x,y:i.y}}switch(Qi(o)){case"start":d[a]-=h*(e&&c?-1:1);break;case"end":d[a]+=h*(e&&c?-1:1)}return d}async function sr(t,o){var e;void 0===o&&(o={});const{x:i,y:r,platform:n,rects:a,elements:s,strategy:l}=t,{boundary:c="clippingAncestors",rootBoundary:p="viewport",elementContext:f="floating",altBoundary:h=!1,padding:d=0}=qi(o,t),u=function(t){return"number"!=typeof t?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(t):{top:t,right:t,bottom:t,left:t}}(d),y=s[h?"floating"===f?"reference":"floating":f],g=nr(await n.getClippingRect({element:null==(e=await(null==n.isElement?void 0:n.isElement(y)))||e?y:y.contextElement||await(null==n.getDocumentElement?void 0:n.getDocumentElement(s.floating)),boundary:c,rootBoundary:p,strategy:l})),b="floating"===f?{...a.floating,x:i,y:r}:a.reference,m=await(null==n.getOffsetParent?void 0:n.getOffsetParent(s.floating)),x=await(null==n.isElement?void 0:n.isElement(m))&&await(null==n.getScale?void 0:n.getScale(m))||{x:1,y:1},O=nr(n.convertOffsetParentRelativeRectToViewportRelativeRect?await n.convertOffsetParentRelativeRectToViewportRelativeRect({rect:b,offsetParent:m,strategy:l}):b);return{top:(g.top-O.top+u.top)/x.y,bottom:(O.bottom-g.bottom+u.bottom)/x.y,left:(g.left-O.left+u.left)/x.x,right:(O.right-g.right+u.right)/x.x}}function lr(t,o,e){return(t?[...e.filter((o=>Qi(o)===t)),...e.filter((o=>Qi(o)!==t))]:e.filter((t=>Xi(t)===t))).filter((e=>!t||(Qi(e)===t||!!o&&function(t){return t.replace(/start|end/g,(t=>Vi[t]))}(e)!==e)))}const cr=function(t){return void 0===t&&(t={}),{name:"autoPlacement",options:t,async fn(o){var e,i,r;const{rects:n,middlewareData:a,placement:s,platform:l,elements:c}=o,{crossAxis:p=!1,alignment:f,allowedPlacements:h=Hi,autoAlignment:d=!0,...u}=qi(t,o),y=void 0!==f||h===Hi?lr(f||null,d,h):h,g=await sr(o,u),b=(null==(e=a.autoPlacement)?void 0:e.index)||0,m=y[b];if(null==m)return{};const x=function(t,o,e){void 0===e&&(e=!1);const i=Qi(t),r=ir(t),n=or(r);let a="x"===r?i===(e?"end":"start")?"right":"left":"start"===i?"bottom":"top";return o.reference[n]>o.floating[n]&&(a=rr(a)),[a,rr(a)]}(m,n,await(null==l.isRTL?void 0:l.isRTL(c.floating)));if(s!==m)return{reset:{placement:y[0]}};const O=[g[Xi(m)],g[x[0]],g[x[1]]],v=[...(null==(i=a.autoPlacement)?void 0:i.overflows)||[],{placement:m,overflows:O}],w=y[b+1];if(w)return{data:{index:b+1,overflows:v},reset:{placement:w}};const N=v.map((t=>{const o=Qi(t.placement);return[t.placement,o&&p?t.overflows.slice(0,2).reduce(((t,o)=>t+o),0):t.overflows[0],t.overflows]})).sort(((t,o)=>t[1]-o[1])),S=N.filter((t=>t[2].slice(0,Qi(t[0])?2:3).every((t=>t<=0)))),C=(null==(r=S[0])?void 0:r[0])||N[0][0];return C!==s?{data:{index:b+1,overflows:v},reset:{placement:C}}:{}}}};function pr(t){return dr(t)?(t.nodeName||"").toLowerCase():"#document"}function fr(t){var o;return(null==t||null==(o=t.ownerDocument)?void 0:o.defaultView)||window}function hr(t){var o;return null==(o=(dr(t)?t.ownerDocument:t.document)||window.document)?void 0:o.documentElement}function dr(t){return t instanceof Node||t instanceof fr(t).Node}function ur(t){return t instanceof Element||t instanceof fr(t).Element}function yr(t){return t instanceof HTMLElement||t instanceof fr(t).HTMLElement}function gr(t){return"undefined"!=typeof ShadowRoot&&(t instanceof ShadowRoot||t instanceof fr(t).ShadowRoot)}function br(t){const{overflow:o,overflowX:e,overflowY:i,display:r}=wr(t);return/auto|scroll|overlay|hidden|clip/.test(o+i+e)&&!["inline","contents"].includes(r)}function mr(t){return["table","td","th"].includes(pr(t))}function xr(t){const o=Or(),e=wr(t);return"none"!==e.transform||"none"!==e.perspective||!!e.containerType&&"normal"!==e.containerType||!o&&!!e.backdropFilter&&"none"!==e.backdropFilter||!o&&!!e.filter&&"none"!==e.filter||["transform","perspective","filter"].some((t=>(e.willChange||"").includes(t)))||["paint","layout","strict","content"].some((t=>(e.contain||"").includes(t)))}function Or(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function vr(t){return["html","body","#document"].includes(pr(t))}function wr(t){return fr(t).getComputedStyle(t)}function Nr(t){return ur(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function Sr(t){if("html"===pr(t))return t;const o=t.assignedSlot||t.parentNode||gr(t)&&t.host||hr(t);return gr(o)?o.host:o}function Cr(t){const o=Sr(t);return vr(o)?t.ownerDocument?t.ownerDocument.body:t.body:yr(o)&&br(o)?o:Cr(o)}function Rr(t,o,e){var i;void 0===o&&(o=[]),void 0===e&&(e=!0);const r=Cr(t),n=r===(null==(i=t.ownerDocument)?void 0:i.body),a=fr(r);return n?o.concat(a,a.visualViewport||[],br(r)?r:[],a.frameElement&&e?Rr(a.frameElement):[]):o.concat(r,Rr(r,[],e))}function $r(t){const o=wr(t);let e=parseFloat(o.width)||0,i=parseFloat(o.height)||0;const r=yr(t),n=r?t.offsetWidth:e,a=r?t.offsetHeight:i,s=_i(e)!==n||_i(i)!==a;return s&&(e=n,i=a),{width:e,height:i,$:s}}function Er(t){return ur(t)?t:t.contextElement}function Ur(t){const o=Er(t);if(!yr(o))return Gi(1);const e=o.getBoundingClientRect(),{width:i,height:r,$:n}=$r(o);let a=(n?_i(e.width):e.width)/i,s=(n?_i(e.height):e.height)/r;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const kr=Gi(0);function Ir(t){const o=fr(t);return Or()&&o.visualViewport?{x:o.visualViewport.offsetLeft,y:o.visualViewport.offsetTop}:kr}function Wr(t,o,e,i){void 0===o&&(o=!1),void 0===e&&(e=!1);const r=t.getBoundingClientRect(),n=Er(t);let a=Gi(1);o&&(i?ur(i)&&(a=Ur(i)):a=Ur(t));const s=function(t,o,e){return void 0===o&&(o=!1),!(!e||o&&e!==fr(t))&&o}(n,e,i)?Ir(n):Gi(0);let l=(r.left+s.x)/a.x,c=(r.top+s.y)/a.y,p=r.width/a.x,f=r.height/a.y;if(n){const t=fr(n),o=i&&ur(i)?fr(i):i;let e=t.frameElement;for(;e&&i&&o!==t;){const t=Ur(e),o=e.getBoundingClientRect(),i=wr(e),r=o.left+(e.clientLeft+parseFloat(i.paddingLeft))*t.x,n=o.top+(e.clientTop+parseFloat(i.paddingTop))*t.y;l*=t.x,c*=t.y,p*=t.x,f*=t.y,l+=r,c+=n,e=fr(e).frameElement}}return nr({width:p,height:f,x:l,y:c})}function Lr(t){return Wr(hr(t)).left+Nr(t).scrollLeft}function Kr(t,o,e){let i;if("viewport"===o)i=function(t,o){const e=fr(t),i=hr(t),r=e.visualViewport;let n=i.clientWidth,a=i.clientHeight,s=0,l=0;if(r){n=r.width,a=r.height;const t=Or();(!t||t&&"fixed"===o)&&(s=r.offsetLeft,l=r.offsetTop)}return{width:n,height:a,x:s,y:l}}(t,e);else if("document"===o)i=function(t){const o=hr(t),e=Nr(t),i=t.ownerDocument.body,r=Ti(o.scrollWidth,o.clientWidth,i.scrollWidth,i.clientWidth),n=Ti(o.scrollHeight,o.clientHeight,i.scrollHeight,i.clientHeight);let a=-e.scrollLeft+Lr(t);const s=-e.scrollTop;return"rtl"===wr(i).direction&&(a+=Ti(o.clientWidth,i.clientWidth)-r),{width:r,height:n,x:a,y:s}}(hr(t));else if(ur(o))i=function(t,o){const e=Wr(t,!0,"fixed"===o),i=e.top+t.clientTop,r=e.left+t.clientLeft,n=yr(t)?Ur(t):Gi(1);return{width:t.clientWidth*n.x,height:t.clientHeight*n.y,x:r*n.x,y:i*n.y}}(o,e);else{const e=Ir(t);i={...o,x:o.x-e.x,y:o.y-e.y}}return nr(i)}function Fr(t,o){const e=Sr(t);return!(e===o||!ur(e)||vr(e))&&("fixed"===wr(e).position||Fr(e,o))}function Zr(t,o,e){const i=yr(o),r=hr(o),n="fixed"===e,a=Wr(t,!0,n,o);let s={scrollLeft:0,scrollTop:0};const l=Gi(0);if(i||!i&&!n)if(("body"!==pr(o)||br(r))&&(s=Nr(o)),i){const t=Wr(o,!0,n,o);l.x=t.x+o.clientLeft,l.y=t.y+o.clientTop}else r&&(l.x=Lr(r));return{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function zr(t,o){return yr(t)&&"fixed"!==wr(t).position?o?o(t):t.offsetParent:null}function Ar(t,o){const e=fr(t);if(!yr(t))return e;let i=zr(t,o);for(;i&&mr(i)&&"static"===wr(i).position;)i=zr(i,o);return i&&("html"===pr(i)||"body"===pr(i)&&"static"===wr(i).position&&!xr(i))?e:i||function(t){let o=Sr(t);for(;yr(o)&&!vr(o);){if(xr(o))return o;o=Sr(o)}return null}(t)||e}const Mr={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{rect:o,offsetParent:e,strategy:i}=t;const r=yr(e),n=hr(e);if(e===n)return o;let a={scrollLeft:0,scrollTop:0},s=Gi(1);const l=Gi(0);if((r||!r&&"fixed"!==i)&&(("body"!==pr(e)||br(n))&&(a=Nr(e)),yr(e))){const t=Wr(e);s=Ur(e),l.x=t.x+e.clientLeft,l.y=t.y+e.clientTop}return{width:o.width*s.x,height:o.height*s.y,x:o.x*s.x-a.scrollLeft*s.x+l.x,y:o.y*s.y-a.scrollTop*s.y+l.y}},getDocumentElement:hr,getClippingRect:function(t){let{element:o,boundary:e,rootBoundary:i,strategy:r}=t;const n=[..."clippingAncestors"===e?function(t,o){const e=o.get(t);if(e)return e;let i=Rr(t,[],!1).filter((t=>ur(t)&&"body"!==pr(t))),r=null;const n="fixed"===wr(t).position;let a=n?Sr(t):t;for(;ur(a)&&!vr(a);){const o=wr(a),e=xr(a);e||"fixed"!==o.position||(r=null),(n?!e&&!r:!e&&"static"===o.position&&r&&["absolute","fixed"].includes(r.position)||br(a)&&!e&&Fr(t,a))?i=i.filter((t=>t!==a)):r=o,a=Sr(a)}return o.set(t,i),i}(o,this._c):[].concat(e),i],a=n[0],s=n.reduce(((t,e)=>{const i=Kr(o,e,r);return t.top=Ti(i.top,t.top),t.right=ji(i.right,t.right),t.bottom=ji(i.bottom,t.bottom),t.left=Ti(i.left,t.left),t}),Kr(o,a,r));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:Ar,getElementRects:async function(t){let{reference:o,floating:e,strategy:i}=t;const r=this.getOffsetParent||Ar,n=this.getDimensions;return{reference:Zr(o,await r(e),i),floating:{x:0,y:0,...await n(e)}}},getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){return $r(t)},getScale:Ur,isElement:ur,isRTL:function(t){return"rtl"===wr(t).direction}},Dr=(t,o,e)=>{const i=new Map,r={platform:Mr,...e},n={...r.platform,_c:i};return(async(t,o,e)=>{const{placement:i="bottom",strategy:r="absolute",middleware:n=[],platform:a}=e,s=n.filter(Boolean),l=await(null==a.isRTL?void 0:a.isRTL(o));let c=await a.getElementRects({reference:t,floating:o,strategy:r}),{x:p,y:f}=ar(c,i,l),h=i,d={},u=0;for(let e=0;e<s.length;e++){const{name:n,fn:y}=s[e],{x:g,y:b,data:m,reset:x}=await y({x:p,y:f,initialPlacement:i,placement:h,strategy:r,middlewareData:d,rects:c,platform:a,elements:{reference:t,floating:o}});p=null!=g?g:p,f=null!=b?b:f,d={...d,[n]:{...d[n],...m}},x&&u<=50&&(u++,"object"==typeof x&&(x.placement&&(h=x.placement),x.rects&&(c=!0===x.rects?await a.getElementRects({reference:t,floating:o,strategy:r}):x.rects),({x:p,y:f}=ar(c,h,l))),e=-1)}return{x:p,y:f,placement:h,strategy:r,middlewareData:d}})(t,o,{...r,platform:n})};var Br=function(t,o,e,i){for(var r,n=arguments.length,a=n<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,e):i,s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(o,e,a):r(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class Pr extends Ko{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.validPositions=new Set(["top","bottom","left","right"]),this.hideDebounce=new U,this.revealDebouncer=new U}get validPosition(){return this.validPositions.has(this.position)?this.position:"bottom"}render(){return to`
|
|
406
406
|
<div part="container"
|
|
407
407
|
class="ft-tooltip--container ${this.inline?"ft-tooltip--inline":""}"
|
|
408
408
|
@mouseenter=${this.onHover}
|
|
@@ -420,13 +420,13 @@ const ie=Symbol.for(""),re=t=>{if(t?.r===ie)return t?._$litStatic$},ne=t=>({_$li
|
|
|
420
420
|
</div>
|
|
421
421
|
</div>
|
|
422
422
|
</div>
|
|
423
|
-
`}updated(t){t.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((o=>t.has(o)))&&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.validPosition){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(){var t;this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",
|
|
423
|
+
`}updated(t){t.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((o=>t.has(o)))&&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.validPosition){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(){var t;this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",Dr(this.slottedElement,this.tooltip,{middleware:[(t={crossAxis:!0},void 0===t&&(t={}),{name:"shift",options:t,async fn(o){const{x:e,y:i,placement:r}=o,{mainAxis:n=!0,crossAxis:a=!1,limiter:s={fn:t=>{let{x:o,y:e}=t;return{x:o,y:e}}},...l}=qi(t,o),c={x:e,y:i},p=await sr(o,l),f=er(Xi(r)),h=tr(f);let d=c[h],u=c[f];if(n){const t="y"===h?"bottom":"right";d=Ji(d+p["y"===h?"top":"left"],d,d-p[t])}if(a){const t="y"===f?"bottom":"right";u=Ji(u+p["y"===f?"top":"left"],u,u-p[t])}const y=s.fn({...o,[h]:d,[f]:u});return{...y,data:{x:y.x-e,y:y.y-i}}}}),cr({allowedPlacements:[this.position]})]}).then((({x:t,y:o})=>{this.tooltip&&(this.tooltip.style.left=`${t}px`,this.tooltip.style.top=`${o}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())}correctOutOfWindowPixels(t,o){return Math.max(t,Math.min(0,-o))}}Pr.elementDefinitions={"ft-typography":Ki},Pr.styles=Bi,Br([S()],Pr.prototype,"text",void 0),Br([S({type:Boolean})],Pr.prototype,"manual",void 0),Br([S({type:Boolean})],Pr.prototype,"inline",void 0),Br([S({type:Number})],Pr.prototype,"delay",void 0),Br([S()],Pr.prototype,"position",void 0),Br([function(t){return(o,e)=>{const{slot:i}=t??{},r="slot"+(i?`[name=${i}]`:":not([name])");return $(0,0,{get(){const o=this.renderRoot?.querySelector(r);return o?.assignedNodes(t)??[]}})}}()],Pr.prototype,"slotNodes",void 0),Br([E(".ft-tooltip--container")],Pr.prototype,"container",void 0),Br([E(".ft-tooltip")],Pr.prototype,"tooltip",void 0),Br([E(".ft-tooltip--content")],Pr.prototype,"tooltipContent",void 0),Br([C()],Pr.prototype,"visible",void 0),Br([R({passive:!0})],Pr.prototype,"onTouch",null),Br([R({passive:!0})],Pr.prototype,"onHover",null),Br([R({passive:!0})],Pr.prototype,"onOut",null),I("ft-tooltip")(Pr);
|
|
424
424
|
/**
|
|
425
425
|
* @license
|
|
426
426
|
* Copyright 2017 Google LLC
|
|
427
427
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
428
428
|
*/
|
|
429
|
-
class
|
|
429
|
+
class Hr extends Xo{constructor(t){if(super(t),this.et=Q,t.type!==Jo)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===Q||null==t)return this.vt=void 0,this.et=t;if(t===X)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.et)return this.vt;this.et=t;const o=[t];return o.raw=o,this.vt={_$litType$:this.constructor.resultType,strings:o,values:[]}}}Hr.directiveName="unsafeHTML",Hr.resultType=1;const jr=qo(Hr);var Tr,_r;!function(t){t.THUMBS_DOWN="",t.THUMBS_DOWN_PLAIN="",t.THUMBS_UP="",t.THUMBS_UP_PLAIN="",t.STAR="",t.STAR_PLAIN="",t.DESKTOP="",t.LIFE_RING="",t.GLOBE="",t.PIGGY_BANK="",t.TABLET_LANDSCAPE="",t.TABLET_PORTRAIT="",t.MOBILE_LANDSCAPE="",t.MOBILE_PORTRAIT="",t.ARROW_RIGHT_TO_LINE="",t.THIN_ARROW_UP="",t.CONTEXTUAL="",t.CHART_SIMPLE="",t.BARS_PROGRESS="",t.LINE_CHART="",t.STACKED_CHART="",t.BOOK_OPEN_GEAR="",t.BOOK_OPEN_GEAR_SLASH="",t.DIAGRAM_SUNBURST="",t.DIAGRAM_SANKEY="",t.UNSTRUCTURED_DOC="",t.RESET="",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.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.EXTLINK_LIGHT="",t.CALENDAR="",t.BOOK="",t.DOWNLOAD_PLAIN="",t.CHECK="",t.TOPICS="",t.EYE="",t.EYE_SLASH="",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="",t.COMMENT_QUESTION="",t.COMMENT_QUESTION_PLAIN="",t.MESSAGE_BOT="",t.PIP="",t.PIP_WIDE="",t.EXPAND_WIDE="",t.X_MARK=""}(Tr||(Tr={})),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=""}(_r||(_r={})),new Map([...["abw"].map((t=>[t,_r.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,_r.AUDIO])),...["avi"].map((t=>[t,_r.AVI])),...["chm","xhs"].map((t=>[t,_r.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,_r.CODE])),...["csv"].map((t=>[t,_r.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,_r.DITA])),...["epub"].map((t=>[t,_r.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,_r.EXCEL])),...["flac"].map((t=>[t,_r.FLAC])),...["gif"].map((t=>[t,_r.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,_r.GZIP])),...["html","htm","xhtml"].map((t=>[t,_r.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,_r.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,_r.JPEG])),...["json"].map((t=>[t,_r.JSON])),...["m4a","m4p"].map((t=>[t,_r.M4A])),...["mov","qt"].map((t=>[t,_r.MOV])),...["mp3"].map((t=>[t,_r.MP3])),...["mp4","m4v"].map((t=>[t,_r.MP4])),...["ogg","oga"].map((t=>[t,_r.OGG])),...["pdf","ps"].map((t=>[t,_r.PDF])),...["png"].map((t=>[t,_r.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,_r.POWERPOINT])),...["rar"].map((t=>[t,_r.RAR])),...["stp"].map((t=>[t,_r.STP])),...["txt","rtf","md","mdown"].map((t=>[t,_r.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,_r.VIDEO])),...["wav"].map((t=>[t,_r.WAV])),...["wma"].map((t=>[t,_r.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,_r.WORD])),...["xml","xsl","rdf"].map((t=>[t,_r.XML])),...["yaml","yml","x-yaml"].map((t=>[t,_r.YAML])),...["zip"].map((t=>[t,_r.ZIP]))]);const Gr={size:Oo.create("--ft-icon-font-size","","SIZE","24px"),fluidTopicsFontFamily:Oo.extend("--ft-icon-fluid-topics-font-family","",Oo.create("--ft-icon-font-family","","UNKNOWN","ft-icons")),fileFormatFontFamily:Oo.extend("--ft-icon-file-format-font-family","",Oo.create("--ft-icon-font-family","","UNKNOWN","ft-mime")),materialFontFamily:Oo.extend("--ft-icon-material-font-family","",Oo.create("--ft-icon-font-family","","UNKNOWN","Material Icons")),verticalAlign:Oo.create("--ft-icon-vertical-align","","UNKNOWN","unset")},Yr=mt`
|
|
430
430
|
:host, i.ft-icon {
|
|
431
431
|
display: inline-flex;
|
|
432
432
|
align-items: center;
|
|
@@ -435,14 +435,14 @@ class Zr extends jo{constructor(t){if(super(t),this.et=Q,t.type!==Po)throw Error
|
|
|
435
435
|
}
|
|
436
436
|
|
|
437
437
|
:host {
|
|
438
|
-
width: ${
|
|
439
|
-
height: ${
|
|
438
|
+
width: ${Gr.size};
|
|
439
|
+
height: ${Gr.size};
|
|
440
440
|
}
|
|
441
441
|
|
|
442
442
|
i.ft-icon {
|
|
443
443
|
width: 100%;
|
|
444
444
|
height: 100%;
|
|
445
|
-
font-size: ${
|
|
445
|
+
font-size: ${Gr.size};
|
|
446
446
|
line-height: 1;
|
|
447
447
|
font-weight: normal;
|
|
448
448
|
text-transform: none;
|
|
@@ -453,33 +453,33 @@ class Zr extends jo{constructor(t){if(super(t),this.et=Q,t.type!==Po)throw Error
|
|
|
453
453
|
text-rendering: auto;
|
|
454
454
|
-webkit-font-smoothing: antialiased;
|
|
455
455
|
-moz-osx-font-smoothing: grayscale;
|
|
456
|
-
vertical-align: ${
|
|
456
|
+
vertical-align: ${Gr.verticalAlign};
|
|
457
457
|
}
|
|
458
458
|
|
|
459
459
|
i.ft-icon.ft-icon--fluid-topics {
|
|
460
|
-
font-family: ${
|
|
460
|
+
font-family: ${Gr.fluidTopicsFontFamily}, ft-icons, fticons, sans-serif;
|
|
461
461
|
|
|
462
462
|
/* Ugly fix because font is broken */
|
|
463
|
-
font-size: calc(0.75 * ${
|
|
464
|
-
line-height: ${
|
|
463
|
+
font-size: calc(0.75 * ${Gr.size});
|
|
464
|
+
line-height: ${Gr.size};
|
|
465
465
|
position: relative;
|
|
466
466
|
top: -4%;
|
|
467
467
|
justify-content: center;
|
|
468
468
|
}
|
|
469
469
|
|
|
470
470
|
.ft-icon--file-format {
|
|
471
|
-
font-family: ${
|
|
471
|
+
font-family: ${Gr.fileFormatFontFamily}, ft-mime, sans-serif;
|
|
472
472
|
}
|
|
473
473
|
|
|
474
474
|
.ft-icon--material {
|
|
475
|
-
font-family: ${
|
|
475
|
+
font-family: ${Gr.materialFontFamily}, "Material Icons", sans-serif;
|
|
476
476
|
}
|
|
477
|
-
`;var
|
|
477
|
+
`;var Vr;!function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(Vr||(Vr={}));var Jr=function(t,o,e,i){for(var r,n=arguments.length,a=n<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,e):i,s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(o,e,a):r(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class qr extends Ko{constructor(){super(...arguments),this.resolvedIcon=eo}render(){const t=this.variant&&Object.values(Vr).includes(this.variant)?this.variant:Vr.fluid_topics,o=t!==Vr.material||!!this.value;return to`
|
|
478
478
|
<i class="ft-icon ft-icon--${t}" part="icon icon-${t}">
|
|
479
|
-
${
|
|
479
|
+
${jr(this.resolvedIcon)}
|
|
480
480
|
<slot ?hidden=${o}></slot>
|
|
481
481
|
</i>
|
|
482
|
-
`}get textContent(){var t,o;return null!==(o=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==o?o:""}update(t){super.update(t),["value","variant"].some((o=>t.has(o)))&&this.resolveIcon()}resolveIcon(){var t,o;let e=this.value||this.textContent;switch(this.variant){case
|
|
482
|
+
`}get textContent(){var t,o;return null!==(o=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==o?o:""}update(t){super.update(t),["value","variant"].some((o=>t.has(o)))&&this.resolveIcon()}resolveIcon(){var t,o;let e=this.value||this.textContent;switch(this.variant){case Vr.file_format:this.resolvedIcon=null!==(t=_r[e.replace("-","_").toUpperCase()])&&void 0!==t?t:e;break;case Vr.material:this.resolvedIcon=this.value||eo;break;default:this.resolvedIcon=null!==(o=Tr[e.replace("-","_").toUpperCase()])&&void 0!==o?o:e}}firstUpdated(t){super.firstUpdated(t),setTimeout((()=>this.resolveIcon()))}}qr.elementDefinitions={},qr.styles=Yr,Jr([S()],qr.prototype,"variant",void 0),Jr([S()],qr.prototype,"value",void 0),Jr([C()],qr.prototype,"resolvedIcon",void 0),Jr([E("slot")],qr.prototype,"slottedContent",void 0),I("ft-icon")(qr);const Xr={textColor:Oo.extend("--ft-switch-text-color","",Co.colorOnSurfaceHigh),backgroundColor:Oo.extend("--ft-switch-background-color","",Co.colorSurface),selectedTextColor:Oo.extend("--ft-switch-selected-text-color","",Co.colorPrimary),selectedBackgroundColor:Oo.extend("--ft-switch-selected-background-color","",Co.colorPrimary),borderColor:Oo.extend("--ft-switch-border-color","",Co.colorOutline),borderRadius:Oo.extend("--ft-switch-border-radius","",Co.borderRadiusL),fontSize:Oo.extend("--ft-switch-font-size","",Oi.fontSize),iconSize:Oo.create("--ft-switch-icon-size","","SIZE","24px"),iconColor:Oo.extend("--ft-switch-text-color","",Co.colorOnSurfaceMedium),rippleColor:Oo.extend("--ft-switch-ripple-color","",Co.colorPrimary),outlineColor:Oo.extend("--ft-switch-outline-color","",Co.colorPrimary)},Qr={borderRadiusLeft:Oo.extend("--ft-switch-option-border-radius-left","",Co.borderRadiusL),borderRadiusRight:Oo.extend("--ft-switch-option-border-radius-right","",Co.borderRadiusL),borderWidthLeft:Oo.create("--ft-switch-option-border-width-left","","SIZE","1px"),borderWidthRight:Oo.create("--ft-switch-option-border-width-right","","SIZE","1px"),borderWidthVertical:Oo.create("--ft-switch-option-border-width-vertical","","SIZE","1px")},tn=mt`
|
|
483
483
|
.ft-switch-option {
|
|
484
484
|
position: relative;
|
|
485
485
|
display: inline-block;
|
|
@@ -493,20 +493,20 @@ class Zr extends jo{constructor(t){if(super(t),this.et=Q,t.type!==Po)throw Error
|
|
|
493
493
|
}
|
|
494
494
|
|
|
495
495
|
.ft-switch-option--content {
|
|
496
|
-
--ft-switch-option-internal-line-height: calc(${
|
|
497
|
-
--ft-switch-option-internal-content-height: max(var(--ft-switch-option-internal-line-height), ${
|
|
496
|
+
--ft-switch-option-internal-line-height: calc(${Xr.fontSize} + 2px);
|
|
497
|
+
--ft-switch-option-internal-content-height: max(var(--ft-switch-option-internal-line-height), ${Xr.iconSize});
|
|
498
498
|
|
|
499
499
|
border-style: solid;
|
|
500
|
-
border-color: ${
|
|
501
|
-
border-width: ${
|
|
502
|
-
border-radius: ${
|
|
500
|
+
border-color: ${Xr.borderColor};
|
|
501
|
+
border-width: ${Qr.borderWidthVertical} ${Qr.borderWidthRight} ${Qr.borderWidthVertical} ${Qr.borderWidthLeft};
|
|
502
|
+
border-radius: ${Qr.borderRadiusLeft} ${Qr.borderRadiusRight} ${Qr.borderRadiusRight} ${Qr.borderRadiusLeft};
|
|
503
503
|
display: flex;
|
|
504
504
|
align-items: center;
|
|
505
505
|
justify-content: center;
|
|
506
506
|
overflow: hidden;
|
|
507
|
-
${vo(
|
|
507
|
+
${vo(Gr.size,Xr.iconSize)};
|
|
508
508
|
padding: var(--ft-switch-internal-vertical-padding, 6px) var(--ft-switch-internal-horizontal-padding, 8px);
|
|
509
|
-
background-color: ${
|
|
509
|
+
background-color: ${Xr.backgroundColor};
|
|
510
510
|
-webkit-mask-image: radial-gradient(white, black);
|
|
511
511
|
}
|
|
512
512
|
|
|
@@ -515,8 +515,8 @@ class Zr extends jo{constructor(t){if(super(t),this.et=Q,t.type!==Po)throw Error
|
|
|
515
515
|
}
|
|
516
516
|
|
|
517
517
|
.ft-switch-option--selected .ft-switch-option--content:before {
|
|
518
|
-
background-color: ${
|
|
519
|
-
border-radius: ${
|
|
518
|
+
background-color: ${Xr.selectedBackgroundColor};
|
|
519
|
+
border-radius: ${Qr.borderRadiusLeft} ${Qr.borderRadiusRight} ${Qr.borderRadiusRight} ${Qr.borderRadiusLeft};
|
|
520
520
|
position: absolute;
|
|
521
521
|
inset: 0;
|
|
522
522
|
content: "";
|
|
@@ -525,18 +525,18 @@ class Zr extends jo{constructor(t){if(super(t),this.et=Q,t.type!==Po)throw Error
|
|
|
525
525
|
}
|
|
526
526
|
|
|
527
527
|
.ft-switch-option--label {
|
|
528
|
-
color: ${
|
|
528
|
+
color: ${Xr.textColor};
|
|
529
529
|
overflow: hidden;
|
|
530
530
|
white-space: nowrap;
|
|
531
531
|
text-overflow: ellipsis;
|
|
532
532
|
display: block;
|
|
533
533
|
margin: 0 8px;
|
|
534
|
-
${vo(
|
|
535
|
-
${vo(
|
|
534
|
+
${vo(Oi.fontSize,Xr.fontSize)};
|
|
535
|
+
${vo(Oi.lineHeight,"var(--ft-switch-option-internal-content-height)")}
|
|
536
536
|
}
|
|
537
537
|
|
|
538
538
|
.ft-switch-option--selected .ft-switch-option--label {
|
|
539
|
-
color: ${
|
|
539
|
+
color: ${Xr.selectedTextColor};
|
|
540
540
|
}
|
|
541
541
|
|
|
542
542
|
.ft-switch-option--label[hidden] {
|
|
@@ -544,7 +544,7 @@ class Zr extends jo{constructor(t){if(super(t),this.et=Q,t.type!==Po)throw Error
|
|
|
544
544
|
}
|
|
545
545
|
|
|
546
546
|
.ft-switch-option--ripple {
|
|
547
|
-
${vo(
|
|
547
|
+
${vo(oe.color,Xr.rippleColor)};
|
|
548
548
|
}
|
|
549
549
|
|
|
550
550
|
ft-icon, ft-ripple, ft-typography {
|
|
@@ -557,20 +557,20 @@ class Zr extends jo{constructor(t){if(super(t),this.et=Q,t.type!==Po)throw Error
|
|
|
557
557
|
|
|
558
558
|
ft-icon {
|
|
559
559
|
flex-shrink: 0;
|
|
560
|
-
color: ${
|
|
560
|
+
color: ${Xr.iconColor};
|
|
561
561
|
}
|
|
562
562
|
|
|
563
563
|
.ft-switch-option--selected ft-icon {
|
|
564
|
-
color: ${
|
|
564
|
+
color: ${Xr.selectedTextColor};
|
|
565
565
|
}
|
|
566
|
-
`;var
|
|
567
|
-
<label part="label" for="input" class=${
|
|
566
|
+
`;var on=function(t,o,e,i){for(var r,n=arguments.length,a=n<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,e):i,s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(o,e,a):r(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class en extends CustomEvent{constructor(t){super("option-change-by-user",{detail:t,bubbles:!0,composed:!0})}}class rn extends CustomEvent{constructor(t){super("option-change",{detail:t,bubbles:!0,composed:!0})}}class nn extends Ko{constructor(){super(...arguments),this.value="",this.label="",this.tooltipPosition="bottom",this.selected=!1,this.trailingIcon=!1,this.unselectable=!1}focus(){this.input.focus()}update(t){super.update(t),t.has("selected")&&this.dispatchEvent(new rn(this.selected))}render(){const t={"ft-switch-option":!0,"ft-switch-option--trailing-icon":this.trailingIcon,"ft-switch-option--selected":this.selected};return this.addTooltip(to`
|
|
567
|
+
<label part="label" for="input" class=${Qo(t)}
|
|
568
568
|
@click=${this.onChange}>
|
|
569
569
|
<div class="ft-switch-option--content">
|
|
570
570
|
<ft-ripple part="ripple" class="ft-switch-option--ripple"></ft-ripple>
|
|
571
571
|
<ft-typography part="text"
|
|
572
572
|
variant="button"
|
|
573
|
-
class="ft-switch-option--label ${
|
|
573
|
+
class="ft-switch-option--label ${Yo?"ft-safari-ellipsis-fix":""}"
|
|
574
574
|
?hidden=${!this.hasTextContent()}>
|
|
575
575
|
<slot @slotchange=${this.onSlotchange}></slot>
|
|
576
576
|
</ft-typography>
|
|
@@ -585,23 +585,23 @@ class Zr extends jo{constructor(t){if(super(t),this.et=Q,t.type!==Po)throw Error
|
|
|
585
585
|
position="${this.tooltipPosition}">
|
|
586
586
|
${t}
|
|
587
587
|
</ft-tooltip>
|
|
588
|
-
`}onChange(){this.selected=!this.unselectable||!this.selected,this.dispatchEvent(new
|
|
588
|
+
`}onChange(){this.selected=!this.unselectable||!this.selected,this.dispatchEvent(new en(this.selected))}getLabel(){return this.label||this.textContent}resolveIcon(){return this.icon?to`
|
|
589
589
|
<ft-icon part="icon" .variant=${this.iconVariant} .value=${this.icon}></ft-icon>
|
|
590
|
-
`:eo}get textContent(){var t,o;return null!==(o=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==o?o:""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}}
|
|
591
|
-
<div @keydown=${this.onKeyDown} tabindex="0" class="${
|
|
590
|
+
`:eo}get textContent(){var t,o;return null!==(o=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==o?o:""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}}nn.elementDefinitions={"ft-ripple":pe,"ft-typography":Ki,"ft-tooltip":Pr,"ft-icon":qr},nn.styles=[Zo,tn],on([S()],nn.prototype,"value",void 0),on([S()],nn.prototype,"icon",void 0),on([S()],nn.prototype,"iconVariant",void 0),on([S()],nn.prototype,"label",void 0),on([S()],nn.prototype,"tooltipPosition",void 0),on([S({type:Boolean,reflect:!0})],nn.prototype,"selected",void 0),on([S({type:Boolean})],nn.prototype,"trailingIcon",void 0),on([S({type:Boolean})],nn.prototype,"unselectable",void 0),on([E(".ft-switch-option--content slot")],nn.prototype,"slottedContent",void 0),on([E(".ft-switch-option--input")],nn.prototype,"input",void 0);var an=function(t,o,e,i){for(var r,n=arguments.length,a=n<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,e):i,s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(o,e,a):r(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class sn extends CustomEvent{constructor(t){super("change",{detail:t})}}class ln extends Ko{constructor(){super(...arguments),this.dense=!1,this.unselectable=!1,this.options=[]}get value(){var t;return null===(t=this.selectedOption)||void 0===t?void 0:t.value}update(t){super.update(t),t.has("selectedOption")&&this.updateOptions(),t.has("unselectable")&&this.options.forEach((t=>t.unselectable=this.unselectable))}render(){const t={"ft-switch":!0,"ft-switch--dense":this.dense};return to`
|
|
591
|
+
<div @keydown=${this.onKeyDown} tabindex="0" class="${Qo(t)}">
|
|
592
592
|
<slot @slotchange=${this.onSlotchange}
|
|
593
593
|
@option-change=${this.onOptionChangeByScript}
|
|
594
594
|
@option-change-by-user=${this.onOptionChangeByUser}
|
|
595
595
|
></slot>
|
|
596
596
|
</div>
|
|
597
|
-
`}onKeyDown(t){let o;"ArrowDown"!=t.key&&"ArrowRight"!=t.key||(o=this.selectedOption?this.options.indexOf(this.selectedOption)+1:0),"ArrowUp"!=t.key&&"ArrowLeft"!=t.key||(o=this.selectedOption?this.options.indexOf(this.selectedOption)-1:this.options.length-1),null!=o&&(t.preventDefault(),this.options[this.fixIndex(o)].selected=!0)}fixIndex(t){return t<0?this.options.length-1:t>this.options.length-1?0:t}onSlotchange(){var t;this.options=[],null===(t=this.slottedContent)||void 0===t||t.assignedElements().forEach((t=>{t instanceof
|
|
597
|
+
`}onKeyDown(t){let o;"ArrowDown"!=t.key&&"ArrowRight"!=t.key||(o=this.selectedOption?this.options.indexOf(this.selectedOption)+1:0),"ArrowUp"!=t.key&&"ArrowLeft"!=t.key||(o=this.selectedOption?this.options.indexOf(this.selectedOption)-1:this.options.length-1),null!=o&&(t.preventDefault(),this.options[this.fixIndex(o)].selected=!0)}fixIndex(t){return t<0?this.options.length-1:t>this.options.length-1?0:t}onSlotchange(){var t;this.options=[],null===(t=this.slottedContent)||void 0===t||t.assignedElements().forEach((t=>{t instanceof nn&&this.registerOption(t)})),this.selectedOption=this.options.find((t=>t.selected))}registerOption(t){t.setAttribute("tabindex","-1"),t.unselectable=this.unselectable,this.options.push(t)}onOptionChangeByScript(t){t.stopPropagation();let o=t.target;this.onOptionChange(o)}onOptionChangeByUser(t){var o;t.stopPropagation(),this.onOptionChange(t.target),this.dispatchEvent(new sn(null===(o=this.selectedOption)||void 0===o?void 0:o.value))}onOptionChange(t){t.selected?this.selectedOption=t:this.selectedOption=this.options.find((t=>t.selected))}private(t){t.selected?this.selectedOption=t:this.selectedOption=this.options.find((t=>t.selected))}focus(){this.ftSwitchDiv.focus()}updateOptions(){this.options.forEach((t=>{t.selected=t===this.selectedOption}))}}ln.elementDefinitions={},ln.styles=mt`
|
|
598
598
|
:host {
|
|
599
599
|
display: inline-block;
|
|
600
600
|
}
|
|
601
601
|
|
|
602
602
|
.ft-switch {
|
|
603
|
-
border-radius: ${
|
|
604
|
-
outline-color: ${
|
|
603
|
+
border-radius: ${Xr.borderRadius};
|
|
604
|
+
outline-color: ${Xr.outlineColor};
|
|
605
605
|
}
|
|
606
606
|
|
|
607
607
|
.ft-switch slot {
|
|
@@ -610,22 +610,22 @@ class Zr extends jo{constructor(t){if(super(t),this.et=Q,t.type!==Po)throw Error
|
|
|
610
610
|
}
|
|
611
611
|
|
|
612
612
|
.ft-switch slot::slotted(ft-switch-option) {
|
|
613
|
-
${vo(
|
|
614
|
-
${vo(
|
|
615
|
-
${vo(
|
|
613
|
+
${vo(Qr.borderRadiusLeft,"0")};
|
|
614
|
+
${vo(Qr.borderRadiusRight,"0")};
|
|
615
|
+
${vo(Qr.borderWidthLeft,"0")};
|
|
616
616
|
}
|
|
617
617
|
|
|
618
618
|
.ft-switch slot::slotted(ft-switch-option:first-child) {
|
|
619
|
-
${vo(
|
|
620
|
-
${vo(
|
|
619
|
+
${vo(Qr.borderRadiusLeft,Xr.borderRadius)};
|
|
620
|
+
${vo(Qr.borderWidthLeft,"1px")};
|
|
621
621
|
}
|
|
622
622
|
|
|
623
623
|
.ft-switch slot::slotted(ft-switch-option:last-child) {
|
|
624
|
-
${vo(
|
|
624
|
+
${vo(Qr.borderRadiusRight,Xr.borderRadius)};
|
|
625
625
|
}
|
|
626
626
|
|
|
627
627
|
.ft-switch--dense slot::slotted(ft-switch-option) {
|
|
628
628
|
--ft-switch-internal-vertical-padding: 2px;
|
|
629
629
|
--ft-switch-internal-horizontal-padding: 4px;
|
|
630
630
|
}
|
|
631
|
-
`,
|
|
631
|
+
`,an([S({type:Boolean})],ln.prototype,"dense",void 0),an([S({type:Boolean})],ln.prototype,"unselectable",void 0),an([E(".ft-switch slot")],ln.prototype,"slottedContent",void 0),an([C()],ln.prototype,"selectedOption",void 0),an([E(".ft-switch")],ln.prototype,"ftSwitchDiv",void 0),I("ft-switch")(ln),I("ft-switch-option")(nn),t.FtSwitch=ln,t.FtSwitchChange=sn,t.FtSwitchCssVariables=Xr,t.FtSwitchOption=nn,t.FtSwitchOptionCssVariables=Qr,t.SwitchOptionChange=rn,t.SwitchOptionChangeByUser=en,t.optionStyles=tn}({});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluid-topics/ft-switch",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.8",
|
|
4
4
|
"description": "two-state",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Lit"
|
|
@@ -19,12 +19,12 @@
|
|
|
19
19
|
"url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@fluid-topics/ft-icon": "1.1.
|
|
23
|
-
"@fluid-topics/ft-ripple": "1.1.
|
|
24
|
-
"@fluid-topics/ft-tooltip": "1.1.
|
|
25
|
-
"@fluid-topics/ft-typography": "1.1.
|
|
26
|
-
"@fluid-topics/ft-wc-utils": "1.1.
|
|
22
|
+
"@fluid-topics/ft-icon": "1.1.8",
|
|
23
|
+
"@fluid-topics/ft-ripple": "1.1.8",
|
|
24
|
+
"@fluid-topics/ft-tooltip": "1.1.8",
|
|
25
|
+
"@fluid-topics/ft-typography": "1.1.8",
|
|
26
|
+
"@fluid-topics/ft-wc-utils": "1.1.8",
|
|
27
27
|
"lit": "3.1.0"
|
|
28
28
|
},
|
|
29
|
-
"gitHead": "
|
|
29
|
+
"gitHead": "95fb2d06899d700513970ac830958922b98539df"
|
|
30
30
|
}
|