@fluid-topics/ft-reader-toc 0.3.22 → 0.3.23
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-reader-toc.light.js +4 -4
- package/build/ft-reader-toc.min.js +164 -164
- package/package.json +7 -7
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
!function(t,i,e,o,n,s,r,a){var l=function(t,i,e,o){for(var n,s=arguments.length,r=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(r=(s<3?n(r):s>3?n(i,e,r):n(i,e))||r);return s>3&&r&&Object.defineProperty(i,e,r),r};class
|
|
1
|
+
!function(t,i,e,o,n,s,r,a){var l,h=function(t,i,e,o){for(var n,s=arguments.length,r=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(r=(s<3?n(r):s>3?n(i,e,r):n(i,e))||r);return s>3&&r&&Object.defineProperty(i,e,r),r};class p extends Event{constructor(){super("register-ft-reader-component",{bubbles:!0,composed:!0})}}class f extends(function(t){class i extends t{setReaderStateManager(t){this.stateManager=t,this.store=t.store}get service(){var t;return null===(t=this.stateManager)||void 0===t?void 0:t.service}connectedCallback(){super.connectedCallback(),setTimeout((()=>this.dispatchEvent(new p)),10)}disconnectedCallback(){super.disconnectedCallback(),this.store=void 0,this.stateManager=void 0}}return h([r.state()],i.prototype,"stateManager",void 0),i}(i.FtLitElementRedux)){}
|
|
2
2
|
/**
|
|
3
3
|
* @license
|
|
4
4
|
* Copyright 2017 Google LLC
|
|
5
5
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
6
|
-
*/
|
|
6
|
+
*/const d=window,c=d.trustedTypes,u=c?c.createPolicy("lit-html",{createHTML:t=>t}):void 0,v=`lit$${(Math.random()+"").slice(9)}$`,g="?"+v,x=`<${g}>`,y=document,b=(t="")=>y.createComment(t),m=t=>null===t||"object"!=typeof t&&"function"!=typeof t,$=Array.isArray,w=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,k=/-->/g,z=/>/g,S=RegExp(">|[ \t\n\f\r](?:([^\\s\"'>=/]+)([ \t\n\f\r]*=[ \t\n\f\r]*(?:[^ \t\n\f\r\"'`<>=]|(\"|')|))|$)","g"),C=/'/g,N=/"/g,O=/^(?:script|style|textarea|title)$/i,j=(t=>(i,...e)=>({_$litType$:t,strings:i,values:e}))(1),T=Symbol.for("lit-noChange"),E=Symbol.for("lit-nothing"),I=new WeakMap,B=y.createTreeWalker(y,129,null,!1),A=(t,i)=>{const e=t.length-1,o=[];let n,s=2===i?"<svg>":"",r=w;for(let i=0;i<e;i++){const e=t[i];let a,l,h=-1,p=0;for(;p<e.length&&(r.lastIndex=p,l=r.exec(e),null!==l);)p=r.lastIndex,r===w?"!--"===l[1]?r=k:void 0!==l[1]?r=z:void 0!==l[2]?(O.test(l[2])&&(n=RegExp("</"+l[2],"g")),r=S):void 0!==l[3]&&(r=S):r===S?">"===l[0]?(r=null!=n?n:w,h=-1):void 0===l[1]?h=-2:(h=r.lastIndex-l[2].length,a=l[1],r=void 0===l[3]?S:'"'===l[3]?N:C):r===N||r===C?r=S:r===k||r===z?r=w:(r=S,n=void 0);const f=r===S&&t[i+1].startsWith("/>")?" ":"";s+=r===w?e+x:h>=0?(o.push(a),e.slice(0,h)+"$lit$"+e.slice(h)+v+f):e+v+(-2===h?(o.push(void 0),i):f)}const a=s+(t[e]||"<?>")+(2===i?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==u?u.createHTML(a):a,o]};class F{constructor({strings:t,_$litType$:i},e){let o;this.parts=[];let n=0,s=0;const r=t.length-1,a=this.parts,[l,h]=A(t,i);if(this.el=F.createElement(l,e),B.currentNode=this.el.content,2===i){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes)}for(;null!==(o=B.nextNode())&&a.length<r;){if(1===o.nodeType){if(o.hasAttributes()){const t=[];for(const i of o.getAttributeNames())if(i.endsWith("$lit$")||i.startsWith(v)){const e=h[s++];if(t.push(i),void 0!==e){const t=o.getAttribute(e.toLowerCase()+"$lit$").split(v),i=/([.?@])?(.*)/.exec(e);a.push({type:1,index:n,name:i[2],strings:t,ctor:"."===i[1]?Z:"?"===i[1]?L:"@"===i[1]?D:R})}else a.push({type:6,index:n})}for(const i of t)o.removeAttribute(i)}if(O.test(o.tagName)){const t=o.textContent.split(v),i=t.length-1;if(i>0){o.textContent=c?c.emptyScript:"";for(let e=0;e<i;e++)o.append(t[e],b()),B.nextNode(),a.push({type:2,index:++n});o.append(t[i],b())}}}else if(8===o.nodeType)if(o.data===g)a.push({type:2,index:n});else{let t=-1;for(;-1!==(t=o.data.indexOf(v,t+1));)a.push({type:7,index:n}),t+=v.length-1}n++}}static createElement(t,i){const e=y.createElement("template");return e.innerHTML=t,e}}function M(t,i,e=t,o){var n,s,r,a;if(i===T)return i;let l=void 0!==o?null===(n=e._$Co)||void 0===n?void 0:n[o]:e._$Cl;const h=m(i)?void 0:i._$litDirective$;return(null==l?void 0:l.constructor)!==h&&(null===(s=null==l?void 0:l._$AO)||void 0===s||s.call(l,!1),void 0===h?l=void 0:(l=new h(t),l._$AT(t,e,o)),void 0!==o?(null!==(r=(a=e)._$Co)&&void 0!==r?r:a._$Co=[])[o]=l:e._$Cl=l),void 0!==l&&(i=M(t,l._$AS(t,i.values),l,o)),i}class U{constructor(t,i){this.u=[],this._$AN=void 0,this._$AD=t,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}v(t){var i;const{el:{content:e},parts:o}=this._$AD,n=(null!==(i=null==t?void 0:t.creationScope)&&void 0!==i?i:y).importNode(e,!0);B.currentNode=n;let s=B.nextNode(),r=0,a=0,l=o[0];for(;void 0!==l;){if(r===l.index){let i;2===l.type?i=new _(s,s.nextSibling,this,t):1===l.type?i=new l.ctor(s,l.name,l.strings,this,t):6===l.type&&(i=new G(s,this,t)),this.u.push(i),l=o[++a]}r!==(null==l?void 0:l.index)&&(s=B.nextNode(),r++)}return n}p(t){let i=0;for(const e of this.u)void 0!==e&&(void 0!==e.strings?(e._$AI(t,e,i),i+=e.strings.length-2):e._$AI(t[i])),i++}}class _{constructor(t,i,e,o){var n;this.type=2,this._$AH=E,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=e,this.options=o,this._$Cm=null===(n=null==o?void 0:o.isConnected)||void 0===n||n}get _$AU(){var t,i;return null!==(i=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==i?i:this._$Cm}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=M(this,t,i),m(t)?t===E||null==t||""===t?(this._$AH!==E&&this._$AR(),this._$AH=E):t!==this._$AH&&t!==T&&this.g(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):(t=>$(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.k(t):this.g(t)}O(t,i=this._$AB){return this._$AA.parentNode.insertBefore(t,i)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}g(t){this._$AH!==E&&m(this._$AH)?this._$AA.nextSibling.data=t:this.T(y.createTextNode(t)),this._$AH=t}$(t){var i;const{values:e,_$litType$:o}=t,n="number"==typeof o?this._$AC(t):(void 0===o.el&&(o.el=F.createElement(o.h,this.options)),o);if((null===(i=this._$AH)||void 0===i?void 0:i._$AD)===n)this._$AH.p(e);else{const t=new U(n,this),i=t.v(this.options);t.p(e),this.T(i),this._$AH=t}}_$AC(t){let i=I.get(t.strings);return void 0===i&&I.set(t.strings,i=new F(t)),i}k(t){$(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let e,o=0;for(const n of t)o===i.length?i.push(e=new _(this.O(b()),this.O(b()),this,this.options)):e=i[o],e._$AI(n),o++;o<i.length&&(this._$AR(e&&e._$AB.nextSibling,o),i.length=o)}_$AR(t=this._$AA.nextSibling,i){var e;for(null===(e=this._$AP)||void 0===e||e.call(this,!1,!0,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){var i;void 0===this._$AM&&(this._$Cm=t,null===(i=this._$AP)||void 0===i||i.call(this,t))}}class R{constructor(t,i,e,o,n){this.type=1,this._$AH=E,this._$AN=void 0,this.element=t,this.name=i,this._$AM=o,this.options=n,e.length>2||""!==e[0]||""!==e[1]?(this._$AH=Array(e.length-1).fill(new String),this.strings=e):this._$AH=E}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,e,o){const n=this.strings;let s=!1;if(void 0===n)t=M(this,t,i,0),s=!m(t)||t!==this._$AH&&t!==T,s&&(this._$AH=t);else{const o=t;let r,a;for(t=n[0],r=0;r<n.length-1;r++)a=M(this,o[e+r],i,r),a===T&&(a=this._$AH[r]),s||(s=!m(a)||a!==this._$AH[r]),a===E?t=E:t!==E&&(t+=(null!=a?a:"")+n[r+1]),this._$AH[r]=a}s&&!o&&this.j(t)}j(t){t===E?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class Z extends R{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===E?void 0:t}}const W=c?c.emptyScript:"";class L extends R{constructor(){super(...arguments),this.type=4}j(t){t&&t!==E?this.element.setAttribute(this.name,W):this.element.removeAttribute(this.name)}}class D extends R{constructor(t,i,e,o,n){super(t,i,e,o,n),this.type=5}_$AI(t,i=this){var e;if((t=null!==(e=M(this,t,i,0))&&void 0!==e?e:E)===T)return;const o=this._$AH,n=t===E&&o!==E||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,s=t!==E&&(o===E||n);n&&this.element.removeEventListener(this.name,this,o),s&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var i,e;"function"==typeof this._$AH?this._$AH.call(null!==(e=null===(i=this.options)||void 0===i?void 0:i.host)&&void 0!==e?e:this.element,t):this._$AH.handleEvent(t)}}class G{constructor(t,i,e){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=e}get _$AU(){return this._$AM._$AU}_$AI(t){M(this,t)}}const K=d.litHtmlPolyfillSupport;null==K||K(F,_),(null!==(l=d.litHtmlVersions)&&void 0!==l?l:d.litHtmlVersions=[]).push("2.4.0");
|
|
7
7
|
/**
|
|
8
8
|
* @license
|
|
9
9
|
* Copyright 2020 Google LLC
|
|
@@ -120,7 +120,7 @@ const H=Symbol.for(""),P=t=>{if((null==t?void 0:t.r)===H)return null==t?void 0:t
|
|
|
120
120
|
text-decoration: none;
|
|
121
121
|
color: inherit;
|
|
122
122
|
}
|
|
123
|
-
`;var xi,yi,bi=function(t,i,e,o){for(var n,s=arguments.length,r=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(r=(s<3?n(r):s>3?n(i,e,r):n(i,e))||r);return s>3&&r&&Object.defineProperty(i,e,r),r};class mi extends
|
|
123
|
+
`;var xi,yi,bi=function(t,i,e,o){for(var n,s=arguments.length,r=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(r=(s<3?n(r):s>3?n(i,e,r):n(i,e))||r);return s>3&&r&&Object.defineProperty(i,e,r),r};class mi extends f{constructor(){super(...arguments),this.removeStyle=!1}render(){var t;let i=n.classMap({"ft-reader-link":!0,"ft-reader-link--remove-style":this.removeStyle});return e.html`
|
|
124
124
|
<a class=${i}
|
|
125
125
|
href="${null===(t=this.service)||void 0===t?void 0:t.getLink(this.tocId,this.pageNumber,this.section)}"
|
|
126
126
|
@click=${t=>this.onClick(t)}>
|
|
@@ -614,7 +614,7 @@ const H=Symbol.for(""),P=t=>{if((null==t?void 0:t.r)===H)return null==t?void 0:t
|
|
|
614
614
|
${i.setVariable(qi.iconSize,he.iconFontSize)};
|
|
615
615
|
${i.setVariable(qi.backgroundColor,"transparent")};
|
|
616
616
|
}
|
|
617
|
-
`;var fe=function(t,i,e,o){for(var n,s=arguments.length,r=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(r=(s<3?n(r):s>3?n(i,e,r):n(i,e))||r);return s>3&&r&&Object.defineProperty(i,e,r),r};class de extends
|
|
617
|
+
`;var fe=function(t,i,e,o){for(var n,s=arguments.length,r=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(r=(s<3?n(r):s>3?n(i,e,r):n(i,e))||r);return s>3&&r&&Object.defineProperty(i,e,r),r};class de extends f{constructor(){super(...arguments),this.expanded=!1,this.iconVariant=ki.fluid_topics,this.collapseIcon="MINUS",this.expandIcon="PLUS",this.autoCollapse=!1,this.scope="pages",this.hideIfEmpty=!1,this.empty=!0,this.labels={},this.labelResolver=new i.ParametrizedLabelResolver(le,{}),this.automaticallyExpandedNodes=new Set,this.manuallyExpandedNodes=new Set,this.manuallyCollapsedNodes=new Set,this.viewportSize=ie.M}get isCurrentPageToc(){return"current-page"===this.scope}update(t){var e,o;if(super.update(t),t.has("labels")&&(this.labelResolver=new i.ParametrizedLabelResolver(le,this.labels)),!this.expanded&&["splitToc","visibleTopics","currentPage","toc"].some((i=>t.has(i)))){const t=this.isCurrentPageToc||!this.splitToc?null!==(e=this.visibleTopics)&&void 0!==e?e:[]:this.currentPage?[this.currentPage.rootTocId]:[];this.automaticallyExpandedNodes=this.buildAutomaticallyExpandedNodes(t)}this.empty=0===(null!==(o=this.getToc())&&void 0!==o?o:[]).length}render(){var t;const i={"ft-reader-toc":!0,"ft-reader-toc-mobile":this.viewportSize===ie.S,"ft-reader-toc-desktop":this.viewportSize!==ie.S,"ft-reader-toc-loaded":null!=this.toc&&null!=this.currentPage,"ft-reader-toc-expanded":this.expanded};return e.html`
|
|
618
618
|
${this.hideIfEmpty&&this.empty?e.html`
|
|
619
619
|
<style>
|
|
620
620
|
:host {
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
*
|
|
15
15
|
* @see https://github.com/webcomponents/polyfills/tree/master/packages/scoped-custom-element-registry
|
|
16
16
|
*/
|
|
17
|
-
if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,e=window.customElements.define,i=window.customElements.get,o=window.customElements,n=new WeakMap,r=new WeakMap,s=new WeakMap,a=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,n){if(t=t.toLowerCase(),void 0!==this._getDefinition(t))throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': the name "${t}" has already been used with this registry`);if(void 0!==this._definitionsByClass.get(n))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const a=n.prototype.attributeChangedCallback,l=new Set(n.observedAttributes||[]);d(n,l,a);const h={elementClass:n,connectedCallback:n.prototype.connectedCallback,disconnectedCallback:n.prototype.disconnectedCallback,adoptedCallback:n.prototype.adoptedCallback,attributeChangedCallback:a,formAssociated:n.formAssociated,formAssociatedCallback:n.prototype.formAssociatedCallback,formDisabledCallback:n.prototype.formDisabledCallback,formResetCallback:n.prototype.formResetCallback,formStateRestoreCallback:n.prototype.formStateRestoreCallback,observedAttributes:l};this._definitionsByTag.set(t,h),this._definitionsByClass.set(n,h);let c=i.call(o,t);c||(c=p(t),e.call(o,t,c)),this===window.customElements&&(s.set(n,h),h.standInClass=c);const f=this._awaitingUpgrade.get(t);if(f){this._awaitingUpgrade.delete(t);for(const t of f)r.delete(t),u(t,h,!0)}const v=this._whenDefinedPromises.get(t);return void 0!==v&&(v.resolve(n),this._whenDefinedPromises.delete(t)),n}upgrade(){y.push(this),o.upgrade.apply(o,arguments),y.pop()}get(t){return this._definitionsByTag.get(t)?.elementClass}_getDefinition(t){return this._definitionsByTag.get(t)}whenDefined(t){const e=this._getDefinition(t);if(void 0!==e)return Promise.resolve(e.elementClass);let i=this._whenDefinedPromises.get(t);return void 0===i&&(i={},i.promise=new Promise((t=>i.resolve=t)),this._whenDefinedPromises.set(t,i)),i.promise}_upgradeWhenDefined(t,e,i){let o=this._awaitingUpgrade.get(e);o||this._awaitingUpgrade.set(e,o=new Set),i?o.add(t):o.delete(t)}},window.HTMLElement=function(){let e=l;if(e)return l=void 0,e;const i=s.get(this.constructor);if(!i)throw new TypeError("Illegal constructor (custom element class must be registered with global customElements registry to be newable)");return e=Reflect.construct(t,[],i.standInClass),Object.setPrototypeOf(e,this.constructor.prototype),n.set(e,i),e},window.HTMLElement.prototype=t.prototype;const h=t=>t===document||t instanceof ShadowRoot,c=t=>{let e=t.getRootNode();if(!h(e)){const t=y[y.length-1];if(t instanceof CustomElementRegistry)return t;e=t.getRootNode(),h(e)||(e=a.get(e)?.getRootNode()||document)}return e.customElements},p=e=>class{static get formAssociated(){return!0}constructor(){const i=Reflect.construct(t,[],this.constructor);Object.setPrototypeOf(i,HTMLElement.prototype);const o=c(i)||window.customElements,n=o._getDefinition(e);return n?u(i,n):r.set(i,o),i}connectedCallback(){const t=n.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):r.get(this)._upgradeWhenDefined(this,e,!0)}disconnectedCallback(){const t=n.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):r.get(this)._upgradeWhenDefined(this,e,!1)}adoptedCallback(){n.get(this)?.adoptedCallback?.apply(this,arguments)}formAssociatedCallback(){const t=n.get(this);t&&t.formAssociated&&t?.formAssociatedCallback?.apply(this,arguments)}formDisabledCallback(){const t=n.get(this);t?.formAssociated&&t?.formDisabledCallback?.apply(this,arguments)}formResetCallback(){const t=n.get(this);t?.formAssociated&&t?.formResetCallback?.apply(this,arguments)}formStateRestoreCallback(){const t=n.get(this);t?.formAssociated&&t?.formStateRestoreCallback?.apply(this,arguments)}},d=(t,e,i)=>{if(0===e.size||void 0===i)return;const o=t.prototype.setAttribute;o&&(t.prototype.setAttribute=function(t,n){const r=t.toLowerCase();if(e.has(r)){const t=this.getAttribute(r);o.call(this,r,n),i.call(this,r,t,n)}else o.call(this,r,n)});const n=t.prototype.removeAttribute;n&&(t.prototype.removeAttribute=function(t){const o=t.toLowerCase();if(e.has(o)){const t=this.getAttribute(o);n.call(this,o),i.call(this,o,t,null)}else n.call(this,o)})},f=e=>{const i=Object.getPrototypeOf(e);if(i!==window.HTMLElement)return i===t||"HTMLElement"===i?.prototype?.constructor?.name?Object.setPrototypeOf(e,window.HTMLElement):f(i)},u=(t,e,i=!1)=>{Object.setPrototypeOf(t,e.elementClass.prototype),n.set(t,e),l=t;try{new e.elementClass}catch(t){f(e.elementClass),new e.elementClass}e.observedAttributes.forEach((i=>{t.hasAttribute(i)&&e.attributeChangedCallback.call(t,i,null,t.getAttribute(i))})),i&&e.connectedCallback&&t.isConnected&&e.connectedCallback.call(t)},v=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const e=v.apply(this,arguments);return t.customElements&&(e.customElements=t.customElements),e};let y=[document];const b=(t,e,i)=>{const o=(i?Object.getPrototypeOf(i):t.prototype)[e];t.prototype[e]=function(){y.push(this);const t=o.apply(i||this,arguments);return void 0!==t&&a.set(t,this),y.pop(),t}};b(ShadowRoot,"createElement",document),b(ShadowRoot,"importNode",document),b(Element,"insertAdjacentHTML");const x=(t,e)=>{const i=Object.getOwnPropertyDescriptor(t.prototype,e);Object.defineProperty(t.prototype,e,{...i,set(t){y.push(this),i.set.call(this,t),y.pop()}})};if(x(Element,"innerHTML"),x(ShadowRoot,"innerHTML"),Object.defineProperty(window,"customElements",{value:new CustomElementRegistry,configurable:!0,writable:!0}),window.ElementInternals&&window.ElementInternals.prototype.setFormValue){const t=new WeakMap,e=HTMLElement.prototype.attachInternals,i=["setFormValue","setValidity","checkValidity","reportValidity"];HTMLElement.prototype.attachInternals=function(...i){const o=e.call(this,...i);return t.set(o,this),o},i.forEach((e=>{const i=window.ElementInternals.prototype,o=i[e];i[e]=function(...e){const i=t.get(this);if(!0!==n.get(i).formAssociated)throw new DOMException(`Failed to execute ${o} on 'ElementInternals': The target element is not a form-associated custom element.`);o?.call(this,...e)}}));class o extends Array{constructor(t){super(...t),this._elements=t}get value(){return this._elements.find((t=>!0===t.checked))?.value||""}}class r{constructor(t){const e=new Map;t.forEach(((t,i)=>{const o=t.getAttribute("name"),n=e.get(o)||[];this[+i]=t,n.push(t),e.set(o,n)})),this.length=t.length,e.forEach(((t,e)=>{t&&(1===t.length?this[e]=t[0]:this[e]=new o(t))}))}namedItem(t){return this[t]}}const s=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get:function(){const t=s.get.call(this,[]),e=[];for(const i of t){const t=n.get(i);t&&!0!==t.formAssociated||e.push(i)}return new r(e)}})}}try{window.customElements.define("custom-element",null)}catch(
|
|
17
|
+
if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,e=window.customElements.define,i=window.customElements.get,o=window.customElements,n=new WeakMap,r=new WeakMap,s=new WeakMap,a=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,n){if(t=t.toLowerCase(),void 0!==this._getDefinition(t))throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': the name "${t}" has already been used with this registry`);if(void 0!==this._definitionsByClass.get(n))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const a=n.prototype.attributeChangedCallback,l=new Set(n.observedAttributes||[]);d(n,l,a);const h={elementClass:n,connectedCallback:n.prototype.connectedCallback,disconnectedCallback:n.prototype.disconnectedCallback,adoptedCallback:n.prototype.adoptedCallback,attributeChangedCallback:a,formAssociated:n.formAssociated,formAssociatedCallback:n.prototype.formAssociatedCallback,formDisabledCallback:n.prototype.formDisabledCallback,formResetCallback:n.prototype.formResetCallback,formStateRestoreCallback:n.prototype.formStateRestoreCallback,observedAttributes:l};this._definitionsByTag.set(t,h),this._definitionsByClass.set(n,h);let c=i.call(o,t);c||(c=p(t),e.call(o,t,c)),this===window.customElements&&(s.set(n,h),h.standInClass=c);const f=this._awaitingUpgrade.get(t);if(f){this._awaitingUpgrade.delete(t);for(const t of f)r.delete(t),u(t,h,!0)}const v=this._whenDefinedPromises.get(t);return void 0!==v&&(v.resolve(n),this._whenDefinedPromises.delete(t)),n}upgrade(){y.push(this),o.upgrade.apply(o,arguments),y.pop()}get(t){return this._definitionsByTag.get(t)?.elementClass}_getDefinition(t){return this._definitionsByTag.get(t)}whenDefined(t){const e=this._getDefinition(t);if(void 0!==e)return Promise.resolve(e.elementClass);let i=this._whenDefinedPromises.get(t);return void 0===i&&(i={},i.promise=new Promise((t=>i.resolve=t)),this._whenDefinedPromises.set(t,i)),i.promise}_upgradeWhenDefined(t,e,i){let o=this._awaitingUpgrade.get(e);o||this._awaitingUpgrade.set(e,o=new Set),i?o.add(t):o.delete(t)}},window.HTMLElement=function(){let e=l;if(e)return l=void 0,e;const i=s.get(this.constructor);if(!i)throw new TypeError("Illegal constructor (custom element class must be registered with global customElements registry to be newable)");return e=Reflect.construct(t,[],i.standInClass),Object.setPrototypeOf(e,this.constructor.prototype),n.set(e,i),e},window.HTMLElement.prototype=t.prototype;const h=t=>t===document||t instanceof ShadowRoot,c=t=>{let e=t.getRootNode();if(!h(e)){const t=y[y.length-1];if(t instanceof CustomElementRegistry)return t;e=t.getRootNode(),h(e)||(e=a.get(e)?.getRootNode()||document)}return e.customElements},p=e=>class{static get formAssociated(){return!0}constructor(){const i=Reflect.construct(t,[],this.constructor);Object.setPrototypeOf(i,HTMLElement.prototype);const o=c(i)||window.customElements,n=o._getDefinition(e);return n?u(i,n):r.set(i,o),i}connectedCallback(){const t=n.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):r.get(this)._upgradeWhenDefined(this,e,!0)}disconnectedCallback(){const t=n.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):r.get(this)._upgradeWhenDefined(this,e,!1)}adoptedCallback(){n.get(this)?.adoptedCallback?.apply(this,arguments)}formAssociatedCallback(){const t=n.get(this);t&&t.formAssociated&&t?.formAssociatedCallback?.apply(this,arguments)}formDisabledCallback(){const t=n.get(this);t?.formAssociated&&t?.formDisabledCallback?.apply(this,arguments)}formResetCallback(){const t=n.get(this);t?.formAssociated&&t?.formResetCallback?.apply(this,arguments)}formStateRestoreCallback(){const t=n.get(this);t?.formAssociated&&t?.formStateRestoreCallback?.apply(this,arguments)}},d=(t,e,i)=>{if(0===e.size||void 0===i)return;const o=t.prototype.setAttribute;o&&(t.prototype.setAttribute=function(t,n){const r=t.toLowerCase();if(e.has(r)){const t=this.getAttribute(r);o.call(this,r,n),i.call(this,r,t,n)}else o.call(this,r,n)});const n=t.prototype.removeAttribute;n&&(t.prototype.removeAttribute=function(t){const o=t.toLowerCase();if(e.has(o)){const t=this.getAttribute(o);n.call(this,o),i.call(this,o,t,null)}else n.call(this,o)})},f=e=>{const i=Object.getPrototypeOf(e);if(i!==window.HTMLElement)return i===t||"HTMLElement"===i?.prototype?.constructor?.name?Object.setPrototypeOf(e,window.HTMLElement):f(i)},u=(t,e,i=!1)=>{Object.setPrototypeOf(t,e.elementClass.prototype),n.set(t,e),l=t;try{new e.elementClass}catch(t){f(e.elementClass),new e.elementClass}e.observedAttributes.forEach((i=>{t.hasAttribute(i)&&e.attributeChangedCallback.call(t,i,null,t.getAttribute(i))})),i&&e.connectedCallback&&t.isConnected&&e.connectedCallback.call(t)},v=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const e=v.apply(this,arguments);return t.customElements&&(e.customElements=t.customElements),e};let y=[document];const b=(t,e,i)=>{const o=(i?Object.getPrototypeOf(i):t.prototype)[e];t.prototype[e]=function(){y.push(this);const t=o.apply(i||this,arguments);return void 0!==t&&a.set(t,this),y.pop(),t}};b(ShadowRoot,"createElement",document),b(ShadowRoot,"importNode",document),b(Element,"insertAdjacentHTML");const x=(t,e)=>{const i=Object.getOwnPropertyDescriptor(t.prototype,e);Object.defineProperty(t.prototype,e,{...i,set(t){y.push(this),i.set.call(this,t),y.pop()}})};if(x(Element,"innerHTML"),x(ShadowRoot,"innerHTML"),Object.defineProperty(window,"customElements",{value:new CustomElementRegistry,configurable:!0,writable:!0}),window.ElementInternals&&window.ElementInternals.prototype.setFormValue){const t=new WeakMap,e=HTMLElement.prototype.attachInternals,i=["setFormValue","setValidity","checkValidity","reportValidity"];HTMLElement.prototype.attachInternals=function(...i){const o=e.call(this,...i);return t.set(o,this),o},i.forEach((e=>{const i=window.ElementInternals.prototype,o=i[e];i[e]=function(...e){const i=t.get(this);if(!0!==n.get(i).formAssociated)throw new DOMException(`Failed to execute ${o} on 'ElementInternals': The target element is not a form-associated custom element.`);o?.call(this,...e)}}));class o extends Array{constructor(t){super(...t),this._elements=t}get value(){return this._elements.find((t=>!0===t.checked))?.value||""}}class r{constructor(t){const e=new Map;t.forEach(((t,i)=>{const o=t.getAttribute("name"),n=e.get(o)||[];this[+i]=t,n.push(t),e.set(o,n)})),this.length=t.length,e.forEach(((t,e)=>{t&&(1===t.length?this[e]=t[0]:this[e]=new o(t))}))}namedItem(t){return this[t]}}const s=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get:function(){const t=s.get.call(this,[]),e=[];for(const i of t){const t=n.get(i);t&&!0!==t.formAssociated||e.push(i)}return new r(e)}})}}try{window.customElements.define("custom-element",null)}catch(mi){const t=window.customElements.define;window.customElements.define=(e,i,o)=>{try{t.bind(window.customElements)(e,i,o)}catch(t){console.info(e,i,o,t)}}}class e{constructor(t=0){this.timeout=t,this.callbacks=[]}run(t,e){this.callbacks=[t],this.debounce(e)}queue(t,e){this.callbacks.push(t),this.debounce(e)}cancel(){null!=this._debounce&&window.clearTimeout(this._debounce)}debounce(t){this.cancel(),this._debounce=window.setTimeout((()=>this.runCallbacks()),null!=t?t:this.timeout)}runCallbacks(){for(let t of this.callbacks)t();this.callbacks=[]}}
|
|
18
18
|
/**
|
|
19
19
|
* @license
|
|
20
20
|
* Copyright 2017 Google LLC
|
|
@@ -92,162 +92,162 @@ var ft,ut;class vt extends z{constructor(){super(...arguments),this.renderOption
|
|
|
92
92
|
-webkit-hyphens: auto;
|
|
93
93
|
hyphens: auto
|
|
94
94
|
}
|
|
95
|
-
`;class Ot{constructor(t,e){this.defaultLabels=t,this.labels=e}resolve(t,...e){var i,o;let n=null!==(o=null!==(i=this.labels[t])&&void 0!==i?i:this.defaultLabels[t])&&void 0!==o?o:"";return e.forEach(((t,e)=>n=n.replace(new RegExp(`\\{${e}\\}`,"g"),t))),n}}const St=(t,e)=>(i,o)=>{i.constructor.createProperty(o,{attribute:!1,hasChanged:null!=e?e:(t,e)=>!p(t,e)});const n=i;n.reduxProperties=n.reduxProperties||new Map,n.reduxProperties.set(o,null!=t?t:t=>t[o])};
|
|
95
|
+
`;class Ot{constructor(t,e){this.defaultLabels=t,this.labels=e}resolve(t,...e){var i,o;let n=null!==(o=null!==(i=this.labels[t])&&void 0!==i?i:this.defaultLabels[t])&&void 0!==o?o:"";return e.forEach(((t,e)=>n=n.replace(new RegExp(`\\{${e}\\}`,"g"),t))),n}}const St=(t,e)=>(i,o)=>{i.constructor.createProperty(o,{attribute:!1,hasChanged:null!=e?e:(t,e)=>!p(t,e)});const n=i;n.reduxProperties=n.reduxProperties||new Map,n.reduxProperties.set(o,null!=t?t:t=>t[o])};class kt extends wt{get store(){return this.internalStore}set store(t){this.internalStore=t,this.store&&this.setupStore()}updateFromStore(){const t=this.store.getState();this.reduxProperties&&this.reduxProperties.forEach(((e,i)=>{this[i]=e(t,this)}))}setupStore(){this.unsubscribeFromStore&&this.unsubscribeFromStore(),this.updateFromStore(),this.unsubscribeFromStore=this.store.subscribe((()=>{this.updateFromStore()})),this.onStoreAvailable(),this.requestUpdate()}onStoreAvailable(){}connectedCallback(){super.connectedCallback(),this.store&&this.setupStore()}disconnectedCallback(){this.unsubscribeFromStore&&this.unsubscribeFromStore(),super.disconnectedCallback()}}var Nt,Ct,Et;const zt=navigator.vendor&&!!navigator.vendor.match(/apple/i)||"[object SafariRemoteNotification]"===(null!==(Et=null===(Ct=null===(Nt=window.safari)||void 0===Nt?void 0:Nt.pushNotification)||void 0===Ct?void 0:Ct.toString())&&void 0!==Et?Et:""),Rt=1,Mt=2,jt=t=>(...e)=>({_$litDirective$:t,values:e});
|
|
96
96
|
/**
|
|
97
97
|
* @license
|
|
98
98
|
* Copyright 2017 Google LLC
|
|
99
99
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
100
|
-
*/class
|
|
100
|
+
*/class Ut{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,i){this._$Ct=t,this._$AM=e,this._$Ci=i}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}}
|
|
101
101
|
/**
|
|
102
102
|
* @license
|
|
103
103
|
* Copyright 2020 Google LLC
|
|
104
104
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
105
|
-
*/const{I:
|
|
105
|
+
*/const{I:Ft}=pt,Tt=()=>document.createComment(""),Bt=(t,e,i)=>{var o;const n=t._$AA.parentNode,r=void 0===e?t._$AB:e._$AA;if(void 0===i){const e=n.insertBefore(Tt(),r),o=n.insertBefore(Tt(),r);i=new Ft(e,o,t,t.options)}else{const e=i._$AB.nextSibling,s=i._$AM,a=s!==t;if(a){let e;null===(o=i._$AQ)||void 0===o||o.call(i,t),i._$AM=t,void 0!==i._$AP&&(e=t._$AU)!==s._$AU&&i._$AP(e)}if(e!==r||a){let t=i._$AA;for(;t!==e;){const e=t.nextSibling;n.insertBefore(t,r),t=e}}}return i},At=(t,e,i=t)=>(t._$AI(e,i),t),Lt={},Pt=t=>{var e;null===(e=t._$AP)||void 0===e||e.call(t,!1,!0);let i=t._$AA;const o=t._$AB.nextSibling;for(;i!==o;){const t=i.nextSibling;i.remove(),i=t}},It=(t,e,i)=>{const o=new Map;for(let n=e;n<=i;n++)o.set(t[n],n);return o},_t=jt(class extends Ut{constructor(t){if(super(t),t.type!==Mt)throw Error("repeat() can only be used in text expressions")}ht(t,e,i){let o;void 0===i?i=e:void 0!==e&&(o=e);const n=[],r=[];let s=0;for(const e of t)n[s]=o?o(e,s):s,r[s]=i(e,s),s++;return{values:r,keys:n}}render(t,e,i){return this.ht(t,e,i).values}update(t,[e,i,o]){var n;const r=(t=>t._$AH)(t),{values:s,keys:a}=this.ht(e,i,o);if(!Array.isArray(r))return this.ut=a,s;const l=null!==(n=this.ut)&&void 0!==n?n:this.ut=[],h=[];let c,p,d=0,f=r.length-1,u=0,v=s.length-1;for(;d<=f&&u<=v;)if(null===r[d])d++;else if(null===r[f])f--;else if(l[d]===a[u])h[u]=At(r[d],s[u]),d++,u++;else if(l[f]===a[v])h[v]=At(r[f],s[v]),f--,v--;else if(l[d]===a[v])h[v]=At(r[d],s[v]),Bt(t,h[v+1],r[d]),d++,v--;else if(l[f]===a[u])h[u]=At(r[f],s[u]),Bt(t,r[d],r[f]),f--,u++;else if(void 0===c&&(c=It(a,u,v),p=It(l,d,f)),c.has(l[d]))if(c.has(l[f])){const e=p.get(a[u]),i=void 0!==e?r[e]:null;if(null===i){const e=Bt(t,r[d]);At(e,s[u]),h[u]=e}else h[u]=At(i,s[u]),Bt(t,r[d],i),r[e]=null;u++}else Pt(r[f]),f--;else Pt(r[d]),d++;for(;u<=v;){const e=Bt(t,h[v+1]);At(e,s[u]),h[u++]=e}for(;d<=f;){const t=r[d++];null!==t&&Pt(t)}return this.ut=a,((t,e=Lt)=>{t._$AH=e})(t,h),q}}),Dt=jt(class extends Ut{constructor(t){var e;if(super(t),t.type!==Rt||"class"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter((e=>t[e])).join(" ")+" "}update(t,[e]){var i,o;if(void 0===this.nt){this.nt=new Set,void 0!==t.strings&&(this.st=new Set(t.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in e)e[t]&&!(null===(i=this.st)||void 0===i?void 0:i.has(t))&&this.nt.add(t);return this.render(e)}const n=t.element.classList;this.nt.forEach((t=>{t in e||(n.remove(t),this.nt.delete(t))}));for(const t in e){const i=!!e[t];i===this.nt.has(t)||(null===(o=this.st)||void 0===o?void 0:o.has(t))||(i?(n.add(t),this.nt.add(t)):(n.remove(t),this.nt.delete(t)))}return q}}),Wt=jt(class extends Ut{constructor(t){var e;if(super(t),t.type!==Rt||"style"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(t){return Object.keys(t).reduce(((e,i)=>{const o=t[i];return null==o?e:e+`${i=i.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${o};`}),"")}update(t,[e]){const{style:i}=t.element;if(void 0===this.vt){this.vt=new Set;for(const t in e)this.vt.add(t);return this.render(e)}this.vt.forEach((t=>{null==e[t]&&(this.vt.delete(t),t.includes("-")?i.removeProperty(t):i[t]="")}));for(const t in e){const o=e[t];null!=o&&(this.vt.add(t),t.includes("-")?i.setProperty(t,o):i[t]=o)}return q}});
|
|
106
106
|
/**
|
|
107
107
|
* @license
|
|
108
108
|
* Copyright 2017 Google LLC
|
|
109
109
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
110
|
-
*/var
|
|
110
|
+
*/var Ht=function(t,e,i,o){for(var n,r=arguments.length,s=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(e,i,s):n(e,i))||s);return r>3&&s&&Object.defineProperty(e,i,s),s};class Kt extends Event{constructor(){super("register-ft-reader-component",{bubbles:!0,composed:!0})}}class Zt extends(function(t){class e extends t{setReaderStateManager(t){this.stateManager=t,this.store=t.store}get service(){var t;return null===(t=this.stateManager)||void 0===t?void 0:t.service}connectedCallback(){super.connectedCallback(),setTimeout((()=>this.dispatchEvent(new Kt)),10)}disconnectedCallback(){super.disconnectedCallback(),this.store=void 0,this.stateManager=void 0}}return Ht([n()],e.prototype,"stateManager",void 0),e}(kt)){}
|
|
111
111
|
/**
|
|
112
112
|
* @license
|
|
113
113
|
* Copyright 2020 Google LLC
|
|
114
114
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
115
|
-
*/var
|
|
115
|
+
*/const Vt=Symbol.for(""),Jt=t=>{if((null==t?void 0:t.r)===Vt)return null==t?void 0:t._$litStatic$},Xt=t=>({_$litStatic$:t,r:Vt}),qt=new Map,Yt=(t=>(e,...i)=>{const o=i.length;let n,r;const s=[],a=[];let l,h=0,c=!1;for(;h<o;){for(l=e[h];h<o&&void 0!==(r=i[h],n=Jt(r));)l+=n+e[++h],c=!0;a.push(r),s.push(l),h++}if(h===o&&s.push(e[o]),c){const t=s.join("$$lit$$");void 0===(e=qt.get(t))&&(s.raw=s,qt.set(t,e=s)),i=a}return t(e,...i)})(X);var Gt;!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"}(Gt||(Gt={}));const Qt=bt.extend("--ft-typography-font-family",gt.titleFont),te=bt.extend("--ft-typography-font-family",gt.contentFont),ee={fontFamily:te,fontSize:bt.create("--ft-typography-font-size","SIZE","16px"),fontWeight:bt.create("--ft-typography-font-weight","UNKNOWN","normal"),letterSpacing:bt.create("--ft-typography-letter-spacing","SIZE","0.496px"),lineHeight:bt.create("--ft-typography-line-height","NUMBER","1.5"),textTransform:bt.create("--ft-typography-text-transform","UNKNOWN","inherit")},ie=bt.extend("--ft-typography-title-font-family",Qt),oe=bt.extend("--ft-typography-title-font-size",ee.fontSize,"20px"),ne=bt.extend("--ft-typography-title-font-weight",ee.fontWeight,"normal"),re=bt.extend("--ft-typography-title-letter-spacing",ee.letterSpacing,"0.15px"),se=bt.extend("--ft-typography-title-line-height",ee.lineHeight,"1.2"),ae=bt.extend("--ft-typography-title-text-transform",ee.textTransform,"inherit"),le=bt.extend("--ft-typography-title-dense-font-family",Qt),he=bt.extend("--ft-typography-title-dense-font-size",ee.fontSize,"14px"),ce=bt.extend("--ft-typography-title-dense-font-weight",ee.fontWeight,"normal"),pe=bt.extend("--ft-typography-title-dense-letter-spacing",ee.letterSpacing,"0.105px"),de=bt.extend("--ft-typography-title-dense-line-height",ee.lineHeight,"1.7"),fe=bt.extend("--ft-typography-title-dense-text-transform",ee.textTransform,"inherit"),ue=bt.extend("--ft-typography-subtitle1-font-family",te),ve=bt.extend("--ft-typography-subtitle1-font-size",ee.fontSize,"16px"),ye=bt.extend("--ft-typography-subtitle1-font-weight",ee.fontWeight,"600"),be=bt.extend("--ft-typography-subtitle1-letter-spacing",ee.letterSpacing,"0.144px"),xe=bt.extend("--ft-typography-subtitle1-line-height",ee.lineHeight,"1.5"),ge=bt.extend("--ft-typography-subtitle1-text-transform",ee.textTransform,"inherit"),me=bt.extend("--ft-typography-subtitle2-font-family",te),we=bt.extend("--ft-typography-subtitle2-font-size",ee.fontSize,"14px"),$e=bt.extend("--ft-typography-subtitle2-font-weight",ee.fontWeight,"normal"),Oe=bt.extend("--ft-typography-subtitle2-letter-spacing",ee.letterSpacing,"0.098px"),Se=bt.extend("--ft-typography-subtitle2-line-height",ee.lineHeight,"1.7"),ke=bt.extend("--ft-typography-subtitle2-text-transform",ee.textTransform,"inherit"),Ne=bt.extend("--ft-typography-body1-font-family",te),Ce=bt.extend("--ft-typography-body1-font-size",ee.fontSize,"16px"),Ee=bt.extend("--ft-typography-body1-font-weight",ee.fontWeight,"normal"),ze=bt.extend("--ft-typography-body1-letter-spacing",ee.letterSpacing,"0.496px"),Re=bt.extend("--ft-typography-body1-line-height",ee.lineHeight,"1.5"),Me=bt.extend("--ft-typography-body1-text-transform",ee.textTransform,"inherit"),je=bt.extend("--ft-typography-body2-font-family",te),Ue=bt.extend("--ft-typography-body2-font-size",ee.fontSize,"14px"),Fe=bt.extend("--ft-typography-body2-font-weight",ee.fontWeight,"normal"),Te=bt.extend("--ft-typography-body2-letter-spacing",ee.letterSpacing,"0.252px"),Be=bt.extend("--ft-typography-body2-line-height",ee.lineHeight,"1.4"),Ae=bt.extend("--ft-typography-body2-text-transform",ee.textTransform,"inherit"),Le=bt.extend("--ft-typography-caption-font-family",te),Pe=bt.extend("--ft-typography-caption-font-size",ee.fontSize,"12px"),Ie=bt.extend("--ft-typography-caption-font-weight",ee.fontWeight,"normal"),_e=bt.extend("--ft-typography-caption-letter-spacing",ee.letterSpacing,"0.396px"),De=bt.extend("--ft-typography-caption-line-height",ee.lineHeight,"1.33"),We=bt.extend("--ft-typography-caption-text-transform",ee.textTransform,"inherit"),He=bt.extend("--ft-typography-breadcrumb-font-family",te),Ke=bt.extend("--ft-typography-breadcrumb-font-size",ee.fontSize,"10px"),Ze=bt.extend("--ft-typography-breadcrumb-font-weight",ee.fontWeight,"normal"),Ve=bt.extend("--ft-typography-breadcrumb-letter-spacing",ee.letterSpacing,"0.33px"),Je=bt.extend("--ft-typography-breadcrumb-line-height",ee.lineHeight,"1.6"),Xe=bt.extend("--ft-typography-breadcrumb-text-transform",ee.textTransform,"inherit"),qe=bt.extend("--ft-typography-overline-font-family",te),Ye=bt.extend("--ft-typography-overline-font-size",ee.fontSize,"10px"),Ge=bt.extend("--ft-typography-overline-font-weight",ee.fontWeight,"normal"),Qe=bt.extend("--ft-typography-overline-letter-spacing",ee.letterSpacing,"1.5px"),ti=bt.extend("--ft-typography-overline-line-height",ee.lineHeight,"1.6"),ei=bt.extend("--ft-typography-overline-text-transform",ee.textTransform,"uppercase"),ii={fontFamily:bt.extend("--ft-typography-button-font-family",te),fontSize:bt.extend("--ft-typography-button-font-size",ee.fontSize,"14px"),fontWeight:bt.extend("--ft-typography-button-font-weight",ee.fontWeight,"600"),letterSpacing:bt.extend("--ft-typography-button-letter-spacing",ee.letterSpacing,"1.246px"),lineHeight:bt.extend("--ft-typography-button-line-height",ee.lineHeight,"1.15"),textTransform:bt.extend("--ft-typography-button-text-transform",ee.textTransform,"uppercase")},oi=x`
|
|
116
116
|
.ft-typography--title {
|
|
117
|
-
font-family: ${
|
|
118
|
-
font-size: ${
|
|
119
|
-
font-weight: ${
|
|
120
|
-
letter-spacing: ${
|
|
121
|
-
line-height: ${
|
|
122
|
-
text-transform: ${
|
|
123
|
-
}
|
|
124
|
-
`,oi=x`
|
|
125
|
-
.ft-typography--title-dense {
|
|
126
|
-
font-family: ${ae};
|
|
127
|
-
font-size: ${le};
|
|
128
|
-
font-weight: ${he};
|
|
129
|
-
letter-spacing: ${ce};
|
|
130
|
-
line-height: ${pe};
|
|
131
|
-
text-transform: ${de};
|
|
117
|
+
font-family: ${ie};
|
|
118
|
+
font-size: ${oe};
|
|
119
|
+
font-weight: ${ne};
|
|
120
|
+
letter-spacing: ${re};
|
|
121
|
+
line-height: ${se};
|
|
122
|
+
text-transform: ${ae};
|
|
132
123
|
}
|
|
133
124
|
`,ni=x`
|
|
134
|
-
.ft-typography--
|
|
135
|
-
font-family: ${
|
|
136
|
-
font-size: ${
|
|
137
|
-
font-weight: ${
|
|
138
|
-
letter-spacing: ${
|
|
139
|
-
line-height: ${
|
|
140
|
-
text-transform: ${
|
|
125
|
+
.ft-typography--title-dense {
|
|
126
|
+
font-family: ${le};
|
|
127
|
+
font-size: ${he};
|
|
128
|
+
font-weight: ${ce};
|
|
129
|
+
letter-spacing: ${pe};
|
|
130
|
+
line-height: ${de};
|
|
131
|
+
text-transform: ${fe};
|
|
141
132
|
}
|
|
142
133
|
`,ri=x`
|
|
143
|
-
.ft-typography--
|
|
144
|
-
font-family: ${
|
|
145
|
-
font-size: ${
|
|
146
|
-
font-weight: ${
|
|
147
|
-
letter-spacing: ${
|
|
148
|
-
line-height: ${
|
|
149
|
-
text-transform: ${
|
|
134
|
+
.ft-typography--subtitle1 {
|
|
135
|
+
font-family: ${ue};
|
|
136
|
+
font-size: ${ve};
|
|
137
|
+
font-weight: ${ye};
|
|
138
|
+
letter-spacing: ${be};
|
|
139
|
+
line-height: ${xe};
|
|
140
|
+
text-transform: ${ge};
|
|
150
141
|
}
|
|
151
|
-
|
|
152
142
|
`,si=x`
|
|
153
|
-
.ft-typography--
|
|
154
|
-
font-family: ${
|
|
155
|
-
font-size: ${
|
|
156
|
-
font-weight: ${
|
|
157
|
-
letter-spacing: ${
|
|
158
|
-
line-height: ${
|
|
159
|
-
text-transform: ${
|
|
143
|
+
.ft-typography--subtitle2 {
|
|
144
|
+
font-family: ${me};
|
|
145
|
+
font-size: ${we};
|
|
146
|
+
font-weight: ${$e};
|
|
147
|
+
letter-spacing: ${Oe};
|
|
148
|
+
line-height: ${Se};
|
|
149
|
+
text-transform: ${ke};
|
|
160
150
|
}
|
|
151
|
+
|
|
161
152
|
`,ai=x`
|
|
162
|
-
.ft-typography--
|
|
163
|
-
font-family: ${
|
|
164
|
-
font-size: ${
|
|
165
|
-
font-weight: ${
|
|
166
|
-
letter-spacing: ${
|
|
167
|
-
line-height: ${
|
|
168
|
-
text-transform: ${
|
|
153
|
+
.ft-typography--body1 {
|
|
154
|
+
font-family: ${Ne};
|
|
155
|
+
font-size: ${Ce};
|
|
156
|
+
font-weight: ${Ee};
|
|
157
|
+
letter-spacing: ${ze};
|
|
158
|
+
line-height: ${Re};
|
|
159
|
+
text-transform: ${Me};
|
|
169
160
|
}
|
|
170
161
|
`,li=x`
|
|
171
|
-
.ft-typography--
|
|
172
|
-
font-family: ${
|
|
173
|
-
font-size: ${
|
|
174
|
-
font-weight: ${
|
|
175
|
-
letter-spacing: ${
|
|
176
|
-
line-height: ${
|
|
177
|
-
text-transform: ${
|
|
162
|
+
.ft-typography--body2 {
|
|
163
|
+
font-family: ${je};
|
|
164
|
+
font-size: ${Ue};
|
|
165
|
+
font-weight: ${Fe};
|
|
166
|
+
letter-spacing: ${Te};
|
|
167
|
+
line-height: ${Be};
|
|
168
|
+
text-transform: ${Ae};
|
|
178
169
|
}
|
|
179
170
|
`,hi=x`
|
|
180
|
-
.ft-typography--
|
|
181
|
-
font-family: ${
|
|
182
|
-
font-size: ${
|
|
183
|
-
font-weight: ${
|
|
184
|
-
letter-spacing: ${
|
|
185
|
-
line-height: ${
|
|
186
|
-
text-transform: ${
|
|
171
|
+
.ft-typography--caption {
|
|
172
|
+
font-family: ${Le};
|
|
173
|
+
font-size: ${Pe};
|
|
174
|
+
font-weight: ${Ie};
|
|
175
|
+
letter-spacing: ${_e};
|
|
176
|
+
line-height: ${De};
|
|
177
|
+
text-transform: ${We};
|
|
187
178
|
}
|
|
188
179
|
`,ci=x`
|
|
189
|
-
.ft-typography--
|
|
190
|
-
font-family: ${
|
|
191
|
-
font-size: ${
|
|
192
|
-
font-weight: ${
|
|
193
|
-
letter-spacing: ${
|
|
194
|
-
line-height: ${
|
|
195
|
-
text-transform: ${
|
|
180
|
+
.ft-typography--breadcrumb {
|
|
181
|
+
font-family: ${He};
|
|
182
|
+
font-size: ${Ke};
|
|
183
|
+
font-weight: ${Ze};
|
|
184
|
+
letter-spacing: ${Ve};
|
|
185
|
+
line-height: ${Je};
|
|
186
|
+
text-transform: ${Xe};
|
|
196
187
|
}
|
|
197
188
|
`,pi=x`
|
|
198
|
-
.ft-typography--
|
|
199
|
-
font-family: ${
|
|
200
|
-
font-size: ${
|
|
201
|
-
font-weight: ${
|
|
202
|
-
letter-spacing: ${
|
|
203
|
-
line-height: ${
|
|
204
|
-
text-transform: ${ei
|
|
189
|
+
.ft-typography--overline {
|
|
190
|
+
font-family: ${qe};
|
|
191
|
+
font-size: ${Ye};
|
|
192
|
+
font-weight: ${Ge};
|
|
193
|
+
letter-spacing: ${Qe};
|
|
194
|
+
line-height: ${ti};
|
|
195
|
+
text-transform: ${ei};
|
|
205
196
|
}
|
|
206
197
|
`,di=x`
|
|
198
|
+
.ft-typography--button {
|
|
199
|
+
font-family: ${ii.fontFamily};
|
|
200
|
+
font-size: ${ii.fontSize};
|
|
201
|
+
font-weight: ${ii.fontWeight};
|
|
202
|
+
letter-spacing: ${ii.letterSpacing};
|
|
203
|
+
line-height: ${ii.lineHeight};
|
|
204
|
+
text-transform: ${ii.textTransform};
|
|
205
|
+
}
|
|
206
|
+
`,fi=x`
|
|
207
207
|
.ft-typography {
|
|
208
208
|
vertical-align: inherit;
|
|
209
209
|
}
|
|
210
|
-
`;var
|
|
211
|
-
<${
|
|
210
|
+
`;var ui=function(t,e,i,o){for(var n,r=arguments.length,s=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(e,i,s):n(e,i))||s);return r>3&&s&&Object.defineProperty(e,i,s),s};class vi extends wt{constructor(){super(...arguments),this.variant=Gt.body1}render(){return this.element?Yt`
|
|
211
|
+
<${Xt(this.element)}
|
|
212
212
|
class="ft-typography ft-typography--${this.variant}">
|
|
213
213
|
<slot></slot>
|
|
214
|
-
</${
|
|
215
|
-
`:
|
|
214
|
+
</${Xt(this.element)}>
|
|
215
|
+
`:Yt`
|
|
216
216
|
<slot class="ft-typography ft-typography--${this.variant}"></slot>
|
|
217
|
-
`}}
|
|
217
|
+
`}}vi.styles=[oi,ni,ri,si,ai,li,hi,ci,pi,di,fi],ui([o()],vi.prototype,"element",void 0),ui([o()],vi.prototype,"variant",void 0),h("ft-typography")(vi);const yi=bt.extend("--ft-reader-internal-link-outline-color",gt.colorPrimary),bi=x`
|
|
218
218
|
a:focus {
|
|
219
|
-
outline-color: ${
|
|
219
|
+
outline-color: ${yi};
|
|
220
220
|
}
|
|
221
221
|
|
|
222
222
|
.ft-reader-link--remove-style {
|
|
223
223
|
text-decoration: none;
|
|
224
224
|
color: inherit;
|
|
225
225
|
}
|
|
226
|
-
`;var
|
|
226
|
+
`;var xi=function(t,e,i,o){for(var n,r=arguments.length,s=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(e,i,s):n(e,i))||s);return r>3&&s&&Object.defineProperty(e,i,s),s};class gi extends Zt{constructor(){super(...arguments),this.removeStyle=!1}render(){var t;let e=Dt({"ft-reader-link":!0,"ft-reader-link--remove-style":this.removeStyle});return X`
|
|
227
227
|
<a class=${e}
|
|
228
228
|
href="${null===(t=this.service)||void 0===t?void 0:t.getLink(this.tocId,this.pageNumber,this.section)}"
|
|
229
229
|
@click=${t=>this.onClick(t)}>
|
|
230
230
|
<slot></slot>
|
|
231
231
|
</a>
|
|
232
|
-
`}onClick(t){var e;t.ctrlKey||t.metaKey||(t.stopPropagation(),t.preventDefault(),this.tocId&&(null===(e=this.stateManager)||void 0===e||e.navigateToTopic(this.tocId,this.section,this.pageNumber)))}}
|
|
232
|
+
`}onClick(t){var e;t.ctrlKey||t.metaKey||(t.stopPropagation(),t.preventDefault(),this.tocId&&(null===(e=this.stateManager)||void 0===e||e.navigateToTopic(this.tocId,this.section,this.pageNumber)))}}gi.styles=bi,xi([o()],gi.prototype,"tocId",void 0),xi([o()],gi.prototype,"section",void 0),xi([o({type:Number})],gi.prototype,"pageNumber",void 0),xi([o({type:Boolean})],gi.prototype,"removeStyle",void 0),h("ft-reader-internal-link")(gi);
|
|
233
233
|
/**
|
|
234
234
|
* @license
|
|
235
235
|
* Copyright 2017 Google LLC
|
|
236
236
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
237
237
|
*/
|
|
238
|
-
class
|
|
238
|
+
class mi extends Ut{constructor(t){if(super(t),this.it=Y,t.type!==Mt)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===Y||null==t)return this._t=void 0,this.it=t;if(t===q)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this._t;this.it=t;const e=[t];return e.raw=e,this._t={_$litType$:this.constructor.resultType,strings:e,values:[]}}}mi.directiveName="unsafeHTML",mi.resultType=1;const wi=jt(mi);var $i,Oi;!function(t){t.THIN_ARROW_LEFT="",t.THIN_ARROW_RIGHT="",t.MY_COLLECTIONS="",t.OFFLINE_SETTINGS="",t.MY_LIBRARY="",t.RATE_PLAIN="",t.RATE="",t.FEEDBACK_PLAIN="",t.STAR_PLAIN="",t.STAR="",t.THUMBS_DOWN_PLAIN="",t.THUMBS_DOWN="",t.THUMBS_UP_PLAIN="",t.THUMBS_UP="",t.PAUSE="",t.PLAY="",t.RELATIVES_PLAIN="",t.RELATIVES="",t.SHORTCUT_MENU="",t.PRINT="",t.DEFAULT_ROLES="",t.ACCOUNT_SETTINGS="",t.ONLINE="",t.OFFLINE="",t.UPLOAD="",t.BOOK_PLAIN="",t.SYNC="",t.SHARED_PBK="",t.COLLECTIONS="",t.SEARCH_IN_PUBLICATION="",t.BOOKS="",t.LOCKER="",t.ARROW_DOWN="",t.ARROW_LEFT="",t.ARROW_RIGHT="",t.ARROW_UP="",t.SAVE="",t.MAILS_AND_NOTIFICATIONS="",t.DOT="",t.MINUS="",t.PLUS="",t.FILTERS="",t.STRIPE_ARROW_RIGHT="",t.STRIPE_ARROW_LEFT="",t.ATTACHMENTS="",t.ADD_BOOKMARK="",t.BOOKMARK="",t.EXPORT="",t.MENU="",t.TAG="",t.TAG_PLAIN="",t.COPY_TO_CLIPBOARD="",t.COLUMNS="",t.ARTICLE="",t.CLOSE_PLAIN="",t.CHECK_PLAIN="",t.LOGOUT="",t.SIGN_IN="",t.THIN_ARROW="",t.TRIANGLE_BOTTOM="",t.TRIANGLE_LEFT="",t.TRIANGLE_RIGHT="",t.TRIANGLE_TOP="",t.FACET_HAS_DESCENDANT="",t.MINUS_PLAIN="",t.PLUS_PLAIN="",t.INFO="",t.ICON_EXPAND="",t.ICON_COLLAPSE="",t.ADD_TO_PBK="",t.ALERT="",t.ADD_ALERT="",t.BACK_TO_SEARCH="",t.DOWNLOAD="",t.EDIT="",t.FEEDBACK="",t.MODIFY_PBK="",t.SCHEDULED="",t.SEARCH="",t.SHARE="󨃱",t.TOC="",t.WRITE_UGC="",t.TRASH="",t.EXTLINK="",t.CALENDAR="",t.BOOK="",t.DOWNLOAD_PLAIN="",t.CHECK="",t.TOPICS="",t.EYE="\f06e",t.DISC="",t.CIRCLE="",t.SHARED="",t.SORT_UNSORTED="",t.SORT_UP="",t.SORT_DOWN="",t.WORKING="",t.CLOSE="",t.ZOOM_OUT="",t.ZOOM_IN="",t.ZOOM_REALSIZE="",t.ZOOM_FULLSCREEN="",t.ADMIN_RESTRICTED="",t.ADMIN_THEME="",t.WARNING="",t.CONTEXT="",t.SEARCH_HOME="",t.STEPS="",t.HOME="",t.TRANSLATE="",t.USER="",t.ADMIN="",t.ANALYTICS="",t.ADMIN_KHUB="",t.ADMIN_USERS="",t.ADMIN_INTEGRATION="",t.ADMIN_PORTAL=""}($i||($i={})),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=""}(Oi||(Oi={})),new Map([...["abw"].map((t=>[t,Oi.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,Oi.AUDIO])),...["avi"].map((t=>[t,Oi.AVI])),...["chm","xhs"].map((t=>[t,Oi.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,Oi.CODE])),...["csv"].map((t=>[t,Oi.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,Oi.DITA])),...["epub"].map((t=>[t,Oi.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,Oi.EXCEL])),...["flac"].map((t=>[t,Oi.FLAC])),...["gif"].map((t=>[t,Oi.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,Oi.GZIP])),...["html","htm","xhtml"].map((t=>[t,Oi.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,Oi.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,Oi.JPEG])),...["json"].map((t=>[t,Oi.JSON])),...["m4a","m4p"].map((t=>[t,Oi.M4A])),...["mov","qt"].map((t=>[t,Oi.MOV])),...["mp3"].map((t=>[t,Oi.MP3])),...["mp4","m4v"].map((t=>[t,Oi.MP4])),...["ogg","oga"].map((t=>[t,Oi.OGG])),...["pdf","ps"].map((t=>[t,Oi.PDF])),...["png"].map((t=>[t,Oi.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,Oi.POWERPOINT])),...["rar"].map((t=>[t,Oi.RAR])),...["stp"].map((t=>[t,Oi.STP])),...["txt","rtf","md","mdown"].map((t=>[t,Oi.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,Oi.VIDEO])),...["wav"].map((t=>[t,Oi.WAV])),...["wma"].map((t=>[t,Oi.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,Oi.WORD])),...["xml","xsl","rdf"].map((t=>[t,Oi.XML])),...["yaml","yml","x-yaml"].map((t=>[t,Oi.YAML])),...["zip"].map((t=>[t,Oi.ZIP]))]);const Si={size:bt.create("--ft-icon-font-size","SIZE","24px"),fluidTopicsFontFamily:bt.extend("--ft-icon-fluid-topics-font-family",bt.create("--ft-icon-font-family","UNKNOWN","ft-icons")),fileFormatFontFamily:bt.extend("--ft-icon-file-format-font-family",bt.create("--ft-icon-font-family","UNKNOWN","ft-mime")),materialFontFamily:bt.extend("--ft-icon-material-font-family",bt.create("--ft-icon-font-family","UNKNOWN","Material Icons")),verticalAlign:bt.create("--ft-icon-vertical-align","UNKNOWN","unset")},ki=x`
|
|
239
239
|
:host {
|
|
240
240
|
display: inline-block;
|
|
241
241
|
}
|
|
242
242
|
|
|
243
243
|
:host, i.ft-icon {
|
|
244
|
-
width: ${
|
|
245
|
-
height: ${
|
|
244
|
+
width: ${Si.size};
|
|
245
|
+
height: ${Si.size};
|
|
246
246
|
text-align: center;
|
|
247
247
|
}
|
|
248
248
|
|
|
249
249
|
i.ft-icon {
|
|
250
|
-
font-size: ${
|
|
250
|
+
font-size: ${Si.size};
|
|
251
251
|
line-height: 1;
|
|
252
252
|
font-weight: normal;
|
|
253
253
|
text-transform: none;
|
|
@@ -258,26 +258,26 @@ class gi extends jt{constructor(t){if(super(t),this.it=Y,t.type!==Rt)throw Error
|
|
|
258
258
|
text-rendering: auto;
|
|
259
259
|
-webkit-font-smoothing: antialiased;
|
|
260
260
|
-moz-osx-font-smoothing: grayscale;
|
|
261
|
-
vertical-align: ${
|
|
261
|
+
vertical-align: ${Si.verticalAlign};
|
|
262
262
|
}
|
|
263
263
|
|
|
264
264
|
.ft-icon--fluid-topics {
|
|
265
|
-
font-family: ${
|
|
265
|
+
font-family: ${Si.fluidTopicsFontFamily}, ft-icons, fticons, sans-serif;
|
|
266
266
|
}
|
|
267
267
|
|
|
268
268
|
.ft-icon--file-format {
|
|
269
|
-
font-family: ${
|
|
269
|
+
font-family: ${Si.fileFormatFontFamily}, ft-mime, sans-serif;
|
|
270
270
|
}
|
|
271
271
|
|
|
272
272
|
.ft-icon--material {
|
|
273
|
-
font-family: ${
|
|
273
|
+
font-family: ${Si.materialFontFamily}, "Material Icons", sans-serif;
|
|
274
274
|
}
|
|
275
|
-
`;var
|
|
275
|
+
`;var Ni;!function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(Ni||(Ni={}));var Ci=function(t,e,i,o){for(var n,r=arguments.length,s=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(e,i,s):n(e,i))||s);return r>3&&s&&Object.defineProperty(e,i,s),s};class Ei extends wt{constructor(){super(...arguments),this.variant=Ni.fluid_topics,this.resolvedIcon=Y}render(){const t="material"!==this.variant||this.value;return X`
|
|
276
276
|
<i class="ft-icon ${"ft-icon--"+this.variant}">
|
|
277
|
-
${
|
|
277
|
+
${wi(this.resolvedIcon)}
|
|
278
278
|
<slot ?hidden=${t}></slot>
|
|
279
279
|
</i>
|
|
280
|
-
`}get textContent(){var t,e;return null!==(e=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==e?e:""}update(t){super.update(t),["value","variant"].some((e=>t.has(e)))&&this.resolveIcon()}resolveIcon(){var t,e;let i=this.value||this.textContent;switch(this.variant){case
|
|
280
|
+
`}get textContent(){var t,e;return null!==(e=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==e?e:""}update(t){super.update(t),["value","variant"].some((e=>t.has(e)))&&this.resolveIcon()}resolveIcon(){var t,e;let i=this.value||this.textContent;switch(this.variant){case Ni.file_format:this.resolvedIcon=null!==(t=Oi[i.toUpperCase()])&&void 0!==t?t:i;break;case Ni.fluid_topics:this.resolvedIcon=null!==(e=$i[i.toUpperCase()])&&void 0!==e?e:i;break;default:this.resolvedIcon=this.value||Y}}firstUpdated(t){super.firstUpdated(t),setTimeout((()=>{this.resolveIcon()}))}}Ei.elementDefinitions={},Ei.styles=ki,Ci([o()],Ei.prototype,"variant",void 0),Ci([o()],Ei.prototype,"value",void 0),Ci([n()],Ei.prototype,"resolvedIcon",void 0),Ci([s("slot")],Ei.prototype,"slottedContent",void 0),h("ft-icon")(Ei);const zi=bt.extend("--ft-ripple-color",gt.colorContent),Ri={color:zi,backgroundColor:bt.extend("--ft-ripple-background-color",zi),opacityContentOnSurfacePressed:bt.external(gt.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:bt.external(gt.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:bt.external(gt.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:bt.external(gt.opacityContentOnSurfaceSelected,"Design system")},Mi=bt.extend("--ft-ripple-color",gt.colorPrimary),ji=Mi,Ui=bt.extend("--ft-ripple-background-color",Mi),Fi=bt.extend("--ft-ripple-color",gt.colorSecondary),Ti=Fi,Bi=bt.extend("--ft-ripple-background-color",Fi),Ai=x`
|
|
281
281
|
:host {
|
|
282
282
|
display: contents;
|
|
283
283
|
}
|
|
@@ -299,27 +299,27 @@ class gi extends jt{constructor(t){if(super(t),this.it=Y,t.type!==Rt)throw Error
|
|
|
299
299
|
}
|
|
300
300
|
|
|
301
301
|
.ft-ripple .ft-ripple--background {
|
|
302
|
-
background-color: ${
|
|
302
|
+
background-color: ${Ri.backgroundColor};
|
|
303
303
|
}
|
|
304
304
|
|
|
305
305
|
.ft-ripple .ft-ripple--effect {
|
|
306
|
-
background-color: ${
|
|
306
|
+
background-color: ${Ri.color};
|
|
307
307
|
}
|
|
308
308
|
|
|
309
309
|
.ft-ripple.ft-ripple--secondary .ft-ripple--background {
|
|
310
|
-
background-color: ${
|
|
310
|
+
background-color: ${Bi};
|
|
311
311
|
}
|
|
312
312
|
|
|
313
313
|
.ft-ripple.ft-ripple--secondary .ft-ripple--effect {
|
|
314
|
-
background-color: ${
|
|
314
|
+
background-color: ${Ti};
|
|
315
315
|
}
|
|
316
316
|
|
|
317
317
|
.ft-ripple.ft-ripple--primary .ft-ripple--background {
|
|
318
|
-
background-color: ${
|
|
318
|
+
background-color: ${Ui};
|
|
319
319
|
}
|
|
320
320
|
|
|
321
321
|
.ft-ripple.ft-ripple--primary .ft-ripple--effect {
|
|
322
|
-
background-color: ${
|
|
322
|
+
background-color: ${ji};
|
|
323
323
|
}
|
|
324
324
|
|
|
325
325
|
.ft-ripple .ft-ripple--background {
|
|
@@ -351,22 +351,22 @@ class gi extends jt{constructor(t){if(super(t),this.it=Y,t.type!==Rt)throw Error
|
|
|
351
351
|
}
|
|
352
352
|
|
|
353
353
|
.ft-ripple.ft-ripple--hovered .ft-ripple--background {
|
|
354
|
-
opacity: ${
|
|
354
|
+
opacity: ${Ri.opacityContentOnSurfaceHover};
|
|
355
355
|
}
|
|
356
356
|
|
|
357
357
|
.ft-ripple.ft-ripple--selected .ft-ripple--background {
|
|
358
|
-
opacity: ${
|
|
358
|
+
opacity: ${Ri.opacityContentOnSurfaceSelected};
|
|
359
359
|
}
|
|
360
360
|
|
|
361
361
|
.ft-ripple.ft-ripple--focused .ft-ripple--background {
|
|
362
|
-
opacity: ${
|
|
362
|
+
opacity: ${Ri.opacityContentOnSurfaceFocused};
|
|
363
363
|
}
|
|
364
364
|
|
|
365
365
|
.ft-ripple.ft-ripple--pressed .ft-ripple--effect {
|
|
366
|
-
opacity: ${
|
|
366
|
+
opacity: ${Ri.opacityContentOnSurfacePressed};
|
|
367
367
|
transform: translate(-50%, -50%) scale(1);
|
|
368
368
|
}
|
|
369
|
-
`;var
|
|
369
|
+
`;var Li=function(t,e,i,o){for(var n,r=arguments.length,s=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(e,i,s):n(e,i))||s);return r>3&&s&&Object.defineProperty(e,i,s),s};class Pi extends wt{constructor(){super(...arguments),this.primary=!1,this.secondary=!1,this.unbounded=!1,this.activated=!1,this.selected=!1,this.disabled=!1,this.hovered=!1,this.focused=!1,this.pressed=!1,this.rippling=!1,this.rippleSize=0,this.originX=0,this.originY=0,this.resizeObserver=new ResizeObserver((()=>this.setRippleSize())),this.debouncer=new e(1e3),this.onTransitionStart=t=>{"transform"===t.propertyName&&(this.rippling=this.pressed,this.debouncer.run((()=>this.rippling=!1)))},this.onTransitionEnd=t=>{"transform"===t.propertyName&&(this.rippling=!1)},this.moveRipple=t=>{var e,i;let{x:o,y:n}=this.getCoordinates(t),r=null!==(i=null===(e=this.ripple)||void 0===e?void 0:e.getBoundingClientRect())&&void 0!==i?i:{x:0,y:0,width:0,height:0};this.originX=Math.round(null!=o?o-r.x:r.width/2),this.originY=Math.round(null!=n?n-r.y:r.height/2)},this.startPress=t=>{this.moveRipple(t),this.pressed=!this.isIgnored(t)},this.endPress=()=>{this.pressed=!1},this.startHover=t=>{this.hovered=!this.isIgnored(t)},this.endHover=()=>{this.hovered=!1},this.startFocus=t=>{this.focused=!this.isIgnored(t)},this.endFocus=()=>{this.focused=!1}}render(){let t={"ft-ripple":!0,"ft-ripple--primary":this.primary,"ft-ripple--secondary":this.secondary,"ft-ripple--unbounded":this.unbounded,"ft-ripple--selected":(this.selected||this.activated)&&!this.disabled,"ft-ripple--pressed":(this.pressed||this.rippling)&&!this.disabled,"ft-ripple--hovered":this.hovered&&!this.disabled,"ft-ripple--focused":this.focused&&!this.disabled};return X`
|
|
370
370
|
<style>
|
|
371
371
|
.ft-ripple .ft-ripple--effect,
|
|
372
372
|
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
@@ -379,11 +379,11 @@ class gi extends jt{constructor(t){if(super(t),this.it=Y,t.type!==Rt)throw Error
|
|
|
379
379
|
top: ${this.originY}px;
|
|
380
380
|
}
|
|
381
381
|
</style>
|
|
382
|
-
<div class="${
|
|
382
|
+
<div class="${Dt(t)}">
|
|
383
383
|
<div class="ft-ripple--background"></div>
|
|
384
384
|
<div class="ft-ripple--effect"></div>
|
|
385
385
|
</div>
|
|
386
|
-
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){var e,i;super.updated(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(e=this.target)||void 0===e||e.removeAttribute("data-is-ft-ripple-target")):null===(i=this.target)||void 0===i||i.setAttribute("data-is-ft-ripple-target","true")),t.has("unbounded")&&this.setRippleSize()}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}setRippleSize(){if(this.ripple){const t=this.ripple.getBoundingClientRect();this.rippleSize=(this.unbounded?1:1.7)*Math.max(t.width,t.height)}}connectedCallback(){var t;super.connectedCallback();const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(e),this.setRippleSize()}setupFor(t){if(this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const e=(...t)=>e=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(e)},i=e("mouseup","contextmenu"),o=e("touchend","touchcancel"),n=t=>{["Enter"," "].includes(t.key)&&e("keyup")(t)};t.addEventListener("mouseover",this.startHover),t.addEventListener("mousemove",this.moveRipple),t.addEventListener("mouseleave",this.endHover),t.addEventListener("mousedown",i),t.addEventListener("touchstart",o),t.addEventListener("touchmove",this.moveRipple),t.addEventListener("keydown",n),t.addEventListener("focus",this.startFocus),t.addEventListener("blur",this.endFocus),t.addEventListener("focusin",this.startFocus),t.addEventListener("focusout",this.endFocus),this.onDisconnect=()=>{t.removeAttribute("data-is-ft-ripple-target"),t.removeEventListener("mouseover",this.startHover),t.removeEventListener("mousemove",this.moveRipple),t.removeEventListener("mouseleave",this.endHover),t.removeEventListener("mousedown",i),t.removeEventListener("touchstart",o),t.removeEventListener("touchmove",this.moveRipple),t.removeEventListener("keydown",n),t.removeEventListener("focus",this.startFocus),t.removeEventListener("blur",this.endFocus),t.removeEventListener("focusin",this.startFocus),t.removeEventListener("focusout",this.endFocus),this.onDisconnect=void 0}}getCoordinates(t){const e=t,i=t;let o,n;return null!=e.x?({x:o,y:n}=e):null!=i.touches&&(o=i.touches[0].clientX,n=i.touches[0].clientY),{x:o,y:n}}isIgnored(t){if(this.disabled)return!0;if(null!=t)for(let e of t.composedPath()){if(e===this.target)break;if("hasAttribute"in e&&e.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.resizeObserver.disconnect(),this.endRipple()}}
|
|
386
|
+
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){var e,i;super.updated(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(e=this.target)||void 0===e||e.removeAttribute("data-is-ft-ripple-target")):null===(i=this.target)||void 0===i||i.setAttribute("data-is-ft-ripple-target","true")),t.has("unbounded")&&this.setRippleSize()}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}setRippleSize(){if(this.ripple){const t=this.ripple.getBoundingClientRect();this.rippleSize=(this.unbounded?1:1.7)*Math.max(t.width,t.height)}}connectedCallback(){var t;super.connectedCallback();const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(e),this.setRippleSize()}setupFor(t){if(this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const e=(...t)=>e=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(e)},i=e("mouseup","contextmenu"),o=e("touchend","touchcancel"),n=t=>{["Enter"," "].includes(t.key)&&e("keyup")(t)};t.addEventListener("mouseover",this.startHover),t.addEventListener("mousemove",this.moveRipple),t.addEventListener("mouseleave",this.endHover),t.addEventListener("mousedown",i),t.addEventListener("touchstart",o),t.addEventListener("touchmove",this.moveRipple),t.addEventListener("keydown",n),t.addEventListener("focus",this.startFocus),t.addEventListener("blur",this.endFocus),t.addEventListener("focusin",this.startFocus),t.addEventListener("focusout",this.endFocus),this.onDisconnect=()=>{t.removeAttribute("data-is-ft-ripple-target"),t.removeEventListener("mouseover",this.startHover),t.removeEventListener("mousemove",this.moveRipple),t.removeEventListener("mouseleave",this.endHover),t.removeEventListener("mousedown",i),t.removeEventListener("touchstart",o),t.removeEventListener("touchmove",this.moveRipple),t.removeEventListener("keydown",n),t.removeEventListener("focus",this.startFocus),t.removeEventListener("blur",this.endFocus),t.removeEventListener("focusin",this.startFocus),t.removeEventListener("focusout",this.endFocus),this.onDisconnect=void 0}}getCoordinates(t){const e=t,i=t;let o,n;return null!=e.x?({x:o,y:n}=e):null!=i.touches&&(o=i.touches[0].clientX,n=i.touches[0].clientY),{x:o,y:n}}isIgnored(t){if(this.disabled)return!0;if(null!=t)for(let e of t.composedPath()){if(e===this.target)break;if("hasAttribute"in e&&e.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.resizeObserver.disconnect(),this.endRipple()}}Pi.elementDefinitions={},Pi.styles=Ai,Li([o({type:Boolean})],Pi.prototype,"primary",void 0),Li([o({type:Boolean})],Pi.prototype,"secondary",void 0),Li([o({type:Boolean})],Pi.prototype,"unbounded",void 0),Li([o({type:Boolean})],Pi.prototype,"activated",void 0),Li([o({type:Boolean})],Pi.prototype,"selected",void 0),Li([o({type:Boolean})],Pi.prototype,"disabled",void 0),Li([n()],Pi.prototype,"hovered",void 0),Li([n()],Pi.prototype,"focused",void 0),Li([n()],Pi.prototype,"pressed",void 0),Li([n()],Pi.prototype,"rippling",void 0),Li([n()],Pi.prototype,"rippleSize",void 0),Li([n()],Pi.prototype,"originX",void 0),Li([n()],Pi.prototype,"originY",void 0),Li([s(".ft-ripple")],Pi.prototype,"ripple",void 0),Li([s(".ft-ripple--effect")],Pi.prototype,"rippleEffect",void 0),h("ft-ripple")(Pi);const Ii=bt.create("--ft-tooltip-distance","SIZE","4px"),_i=bt.create("--ft-tooltip-color","COLOR","#FFFFFF"),Di=bt.create("--ft-tooltip-background-color","COLOR","#666666"),Wi=bt.create("--ft-tooltip-z-index","NUMBER","1"),Hi=bt.external(gt.borderRadiusS,"Design system"),Ki=bt.create("--ft-tooltip-max-width","SIZE","150px"),Zi=x`
|
|
387
387
|
.ft-tooltip--container {
|
|
388
388
|
display: block;
|
|
389
389
|
position: relative;
|
|
@@ -399,23 +399,23 @@ class gi extends jt{constructor(t){if(super(t),this.it=Y,t.type!==Rt)throw Error
|
|
|
399
399
|
box-sizing: border-box;
|
|
400
400
|
overflow: hidden;
|
|
401
401
|
width: max-content;
|
|
402
|
-
max-width: ${
|
|
402
|
+
max-width: ${Ki};
|
|
403
403
|
text-align: center;
|
|
404
|
-
padding: ${
|
|
405
|
-
z-index: ${
|
|
404
|
+
padding: ${Ii};
|
|
405
|
+
z-index: ${Wi};
|
|
406
406
|
}
|
|
407
407
|
|
|
408
408
|
.ft-tooltip--content {
|
|
409
409
|
padding: 4px 8px;
|
|
410
|
-
border-radius: ${
|
|
411
|
-
background-color: ${
|
|
412
|
-
color: ${
|
|
410
|
+
border-radius: ${Hi};
|
|
411
|
+
background-color: ${Di};
|
|
412
|
+
color: ${_i};
|
|
413
413
|
top: -500px;
|
|
414
414
|
left: -500px;
|
|
415
415
|
position: relative;
|
|
416
416
|
word-break: break-word;
|
|
417
417
|
}
|
|
418
|
-
`;var
|
|
418
|
+
`;var Vi=function(t,e,i,o){for(var n,r=arguments.length,s=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(e,i,s):n(e,i))||s);return r>3&&s&&Object.defineProperty(e,i,s),s};class Ji extends wt{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.hideDebounce=new e,this.revealDebouncer=new e}render(){return X`
|
|
419
419
|
<div part="container"
|
|
420
420
|
class="ft-tooltip--container ${this.inline?"ft-tooltip--inline":""}"
|
|
421
421
|
@mouseenter=${this.onHover}
|
|
@@ -431,13 +431,13 @@ class gi extends jt{constructor(t){if(super(t),this.it=Y,t.type!==Rt)throw Error
|
|
|
431
431
|
</div>
|
|
432
432
|
<slot></slot>
|
|
433
433
|
</div>
|
|
434
|
-
`}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){["visible","text"].some((e=>t.has(e)))&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.position){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const e=t.getBoundingClientRect(),i=(e.height-this.tooltip.clientHeight)/2,o=(e.width-this.tooltip.clientWidth)/2;let n=0,r=0;switch(this.position){case"top":r=-this.tooltip.clientHeight,n=o;break;case"bottom":r=e.height,n=o;break;case"left":r=i,n=-this.tooltip.clientWidth;break;case"right":r=i,n=e.width}e.left+n+this.tooltip.clientWidth>window.innerWidth&&(n=window.innerWidth-this.tooltip.clientWidth-e.left),e.left+n<0&&(n=0);const s=this.tooltip.style;s.left=n+"px",s.top=r+"px",s.maxWidth=`max(${e.width}px, ${
|
|
434
|
+
`}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){["visible","text"].some((e=>t.has(e)))&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.position){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const e=t.getBoundingClientRect(),i=(e.height-this.tooltip.clientHeight)/2,o=(e.width-this.tooltip.clientWidth)/2;let n=0,r=0;switch(this.position){case"top":r=-this.tooltip.clientHeight,n=o;break;case"bottom":r=e.height,n=o;break;case"left":r=i,n=-this.tooltip.clientWidth;break;case"right":r=i,n=e.width}e.left+n+this.tooltip.clientWidth>window.innerWidth&&(n=window.innerWidth-this.tooltip.clientWidth-e.left),e.left+n<0&&(n=0);const s=this.tooltip.style;s.left=n+"px",s.top=r+"px",s.maxWidth=`max(${e.width}px, ${Ki})`}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())}}Ji.elementDefinitions={"ft-typography":vi},Ji.styles=Zi,Vi([o()],Ji.prototype,"text",void 0),Vi([o({type:Boolean})],Ji.prototype,"manual",void 0),Vi([o({type:Boolean})],Ji.prototype,"inline",void 0),Vi([o({type:Number})],Ji.prototype,"delay",void 0),Vi([o()],Ji.prototype,"position",void 0),Vi([
|
|
435
435
|
/**
|
|
436
436
|
* @license
|
|
437
437
|
* Copyright 2017 Google LLC
|
|
438
438
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
439
439
|
*/
|
|
440
|
-
function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},i?function(t){const{slot:e,selector:i}=null!=t?t:{};return r({descriptor:o=>({get(){var o;const n="slot"+(e?`[name=${e}]`:":not([name])"),r=null===(o=this.renderRoot)||void 0===o?void 0:o.querySelector(n),s=null!=r?l(r,t):[];return i?s.filter((t=>t.matches(i))):s},enumerable:!0,configurable:!0})})}({slot:n,flatten:e,selector:i}):r({descriptor:t=>({get(){var t,e;const i="slot"+(n?`[name=${n}]`:":not([name])"),r=null===(t=this.renderRoot)||void 0===t?void 0:t.querySelector(i);return null!==(e=null==r?void 0:r.assignedNodes(o))&&void 0!==e?e:[]},enumerable:!0,configurable:!0})})}("",!0)],
|
|
440
|
+
function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},i?function(t){const{slot:e,selector:i}=null!=t?t:{};return r({descriptor:o=>({get(){var o;const n="slot"+(e?`[name=${e}]`:":not([name])"),r=null===(o=this.renderRoot)||void 0===o?void 0:o.querySelector(n),s=null!=r?l(r,t):[];return i?s.filter((t=>t.matches(i))):s},enumerable:!0,configurable:!0})})}({slot:n,flatten:e,selector:i}):r({descriptor:t=>({get(){var t,e;const i="slot"+(n?`[name=${n}]`:":not([name])"),r=null===(t=this.renderRoot)||void 0===t?void 0:t.querySelector(i);return null!==(e=null==r?void 0:r.assignedNodes(o))&&void 0!==e?e:[]},enumerable:!0,configurable:!0})})}("",!0)],Ji.prototype,"slotNodes",void 0),Vi([s(".ft-tooltip--container")],Ji.prototype,"container",void 0),Vi([s("slot")],Ji.prototype,"target",void 0),Vi([s(".ft-tooltip")],Ji.prototype,"tooltip",void 0),Vi([s(".ft-tooltip--content")],Ji.prototype,"tooltipContent",void 0),Vi([n()],Ji.prototype,"visible",void 0),h("ft-tooltip")(Ji);const Xi={color:bt.extend("--ft-loader-color",gt.colorPrimary),size:bt.create("--ft-loader-size","SIZE","80px")},qi=x`
|
|
441
441
|
:host {
|
|
442
442
|
line-height: 0;
|
|
443
443
|
}
|
|
@@ -446,8 +446,8 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
446
446
|
display: inline-block;
|
|
447
447
|
position: relative;
|
|
448
448
|
|
|
449
|
-
width: ${
|
|
450
|
-
height: ${
|
|
449
|
+
width: ${Xi.size};
|
|
450
|
+
height: ${Xi.size};
|
|
451
451
|
}
|
|
452
452
|
|
|
453
453
|
.ft-loader div {
|
|
@@ -456,7 +456,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
456
456
|
width: 25%;
|
|
457
457
|
height: 25%;
|
|
458
458
|
border-radius: 50%;
|
|
459
|
-
background: ${
|
|
459
|
+
background: ${Xi.color};
|
|
460
460
|
animation-timing-function: cubic-bezier(0, 1, 1, 0);
|
|
461
461
|
}
|
|
462
462
|
|
|
@@ -503,17 +503,17 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
503
503
|
transform: translate(0, 0);
|
|
504
504
|
}
|
|
505
505
|
100% {
|
|
506
|
-
transform: translate(calc(0.35 * ${
|
|
506
|
+
transform: translate(calc(0.35 * ${Xi.size}), 0);
|
|
507
507
|
}
|
|
508
508
|
}
|
|
509
|
-
`;class
|
|
509
|
+
`;class Yi extends wt{render(){return X`
|
|
510
510
|
<div class="ft-loader">
|
|
511
511
|
<div></div>
|
|
512
512
|
<div></div>
|
|
513
513
|
<div></div>
|
|
514
514
|
<div></div>
|
|
515
515
|
</div>
|
|
516
|
-
`}}
|
|
516
|
+
`}}Yi.styles=qi,h("ft-loader")(Yi);const Gi=bt.extend("--ft-button-color",gt.colorPrimary),Qi={backgroundColor:bt.extend("--ft-button-background-color",gt.colorSurface),borderRadius:bt.extend("--ft-button-border-radius",gt.borderRadiusL),color:Gi,fontSize:bt.extend("--ft-button-font-size",ii.fontSize),iconSize:bt.create("--ft-button-icon-size","SIZE","24px"),rippleColor:bt.extend("--ft-button-ripple-color",Gi),opacityDisabled:bt.external(gt.colorOpacityDisabled,"Design system")},to=bt.extend("--ft-button-primary-color",bt.extend("--ft-button-color",gt.colorOnPrimary)),eo={backgroundColor:bt.extend("--ft-button-primary-background-color",bt.extend("--ft-button-background-color",gt.colorPrimary)),color:to,rippleColor:bt.extend("--ft-button-primary-ripple-color",to)},io=bt.extend("--ft-button-dense-border-radius",bt.extend("--ft-button-border-radius",gt.borderRadiusM)),oo=[$t,x`
|
|
517
517
|
:host {
|
|
518
518
|
display: inline-block;
|
|
519
519
|
max-width: 100%;
|
|
@@ -524,7 +524,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
524
524
|
box-shadow: 0px 0px 0px transparent;
|
|
525
525
|
border: 0px solid transparent;
|
|
526
526
|
text-shadow: 0px 0px 0px transparent;
|
|
527
|
-
font-size: ${
|
|
527
|
+
font-size: ${Qi.fontSize};
|
|
528
528
|
}
|
|
529
529
|
|
|
530
530
|
button:hover {
|
|
@@ -553,17 +553,17 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
553
553
|
border: none;
|
|
554
554
|
pointer-events: auto;
|
|
555
555
|
|
|
556
|
-
--ft-button-internal-line-height: calc(${
|
|
557
|
-
--ft-button-internal-color: ${
|
|
558
|
-
${xt(
|
|
556
|
+
--ft-button-internal-line-height: calc(${Qi.fontSize} + 2px);
|
|
557
|
+
--ft-button-internal-color: ${Qi.color};
|
|
558
|
+
${xt(Si.size,Qi.iconSize)};
|
|
559
559
|
--ft-button-internal-vertical-padding: 6px;
|
|
560
560
|
--ft-button-internal-horizontal-padding: 8px;
|
|
561
|
-
${xt(
|
|
562
|
-
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height), ${
|
|
561
|
+
${xt(Ri.color,Qi.rippleColor)};
|
|
562
|
+
--ft-button-internal-content-height: max(var(--ft-button-internal-line-height), ${Qi.iconSize});
|
|
563
563
|
|
|
564
|
-
border-radius: ${
|
|
564
|
+
border-radius: ${Qi.borderRadius};
|
|
565
565
|
padding: var(--ft-button-internal-vertical-padding) var(--ft-button-internal-horizontal-padding);
|
|
566
|
-
background-color: ${
|
|
566
|
+
background-color: ${Qi.backgroundColor};
|
|
567
567
|
color: var(--ft-button-internal-color);
|
|
568
568
|
-webkit-mask-image: radial-gradient(white, black);
|
|
569
569
|
}
|
|
@@ -575,7 +575,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
575
575
|
.ft-button--dense {
|
|
576
576
|
--ft-button-internal-vertical-padding: 2px;
|
|
577
577
|
--ft-button-internal-horizontal-padding: 4px;
|
|
578
|
-
border-radius: ${
|
|
578
|
+
border-radius: ${io};
|
|
579
579
|
}
|
|
580
580
|
|
|
581
581
|
.ft-button--round {
|
|
@@ -584,13 +584,13 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
584
584
|
|
|
585
585
|
.ft-button[disabled] {
|
|
586
586
|
filter: grayscale(1);
|
|
587
|
-
opacity: ${
|
|
587
|
+
opacity: ${Qi.opacityDisabled};
|
|
588
588
|
}
|
|
589
589
|
|
|
590
590
|
.ft-button.ft-button--primary {
|
|
591
|
-
background-color: ${
|
|
592
|
-
--ft-button-internal-color: ${
|
|
593
|
-
${xt(
|
|
591
|
+
background-color: ${eo.backgroundColor};
|
|
592
|
+
--ft-button-internal-color: ${eo.color};
|
|
593
|
+
${xt(Ri.color,eo.rippleColor)};
|
|
594
594
|
}
|
|
595
595
|
|
|
596
596
|
.ft-button.ft-button--outlined {
|
|
@@ -609,8 +609,8 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
609
609
|
text-overflow: ellipsis;
|
|
610
610
|
display: block;
|
|
611
611
|
margin: 0 var(--ft-button-internal-horizontal-padding);
|
|
612
|
-
${xt(
|
|
613
|
-
${xt(
|
|
612
|
+
${xt(ii.fontSize,"1em")};
|
|
613
|
+
${xt(ii.lineHeight,"var(--ft-button-internal-content-height)")};
|
|
614
614
|
}
|
|
615
615
|
|
|
616
616
|
.ft-button--safari-fix .ft-button--label {
|
|
@@ -643,12 +643,12 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
643
643
|
}
|
|
644
644
|
|
|
645
645
|
ft-loader {
|
|
646
|
-
${xt(
|
|
647
|
-
${xt(
|
|
646
|
+
${xt(Xi.size,Qi.iconSize)};
|
|
647
|
+
${xt(Xi.color,"var(--ft-button-internal-color)")};
|
|
648
648
|
}
|
|
649
|
-
`];var
|
|
649
|
+
`];var no,ro=function(t,e,i,o){for(var n,r=arguments.length,s=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(e,i,s):n(e,i))||s);return r>3&&s&&Object.defineProperty(e,i,s),s};class so extends wt{constructor(){super(...arguments),this.primary=!1,this.outlined=!1,this.disabled=!1,this.dense=!1,this.round=!1,this.label="",this.icon=void 0,this.iconVariant=Ni.material,this.trailingIcon=!1,this.loading=!1,this.tooltipPosition="bottom",this.hideTooltip=!1,this.forceTooltip=!1,this.onclick=t=>{this.isDisabled()&&(t.preventDefault(),t.stopPropagation(),t.stopImmediatePropagation())}}render(){const t={"ft-button":!0,"ft-button--primary":this.primary,"ft-button--outlined":this.outlined,"ft-button--dense":this.dense,"ft-button--round":this.round,"ft-button--trailing-icon":this.trailingIcon,"ft-button--loading":this.trailingIcon,"ft-button--safari-fix":zt,"ft-no-text-select":!0};return this.addTooltipIfNeeded(X`
|
|
650
650
|
<button part="button"
|
|
651
|
-
class="${
|
|
651
|
+
class="${Dt(t)}"
|
|
652
652
|
aria-label="${this.getLabel()}"
|
|
653
653
|
?disabled=${this.isDisabled()}>
|
|
654
654
|
<ft-ripple part="ripple" ?disabled=${this.isDisabled()}></ft-ripple>
|
|
@@ -668,7 +668,7 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
668
668
|
</ft-tooltip>
|
|
669
669
|
`:t}resolveIcon(){return this.loading?X`
|
|
670
670
|
<ft-loader></ft-loader> `:this.icon?X`
|
|
671
|
-
<ft-icon variant="${this.iconVariant}" value="${this.icon}"></ft-icon> `:Y}focus(){var t;null===(t=this.button)||void 0===t||t.focus()}getLabel(){return this.label||this.textContent}get textContent(){return this.unslotText(this.slottedContent).trim()}unslotText(t){return t instanceof HTMLSlotElement?t.assignedNodes().map((t=>this.unslotText(t))).join(""):(null==t?void 0:t.textContent)||""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}isDisabled(){return this.disabled||this.loading}}
|
|
671
|
+
<ft-icon variant="${this.iconVariant}" value="${this.icon}"></ft-icon> `:Y}focus(){var t;null===(t=this.button)||void 0===t||t.focus()}getLabel(){return this.label||this.textContent}get textContent(){return this.unslotText(this.slottedContent).trim()}unslotText(t){return t instanceof HTMLSlotElement?t.assignedNodes().map((t=>this.unslotText(t))).join(""):(null==t?void 0:t.textContent)||""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}isDisabled(){return this.disabled||this.loading}}so.elementDefinitions={"ft-ripple":Pi,"ft-tooltip":Ji,"ft-typography":vi,"ft-icon":Ei,"ft-loader":Yi},so.styles=oo,ro([o({type:Boolean})],so.prototype,"primary",void 0),ro([o({type:Boolean})],so.prototype,"outlined",void 0),ro([o({type:Boolean})],so.prototype,"disabled",void 0),ro([o({type:Boolean})],so.prototype,"dense",void 0),ro([o({type:Boolean})],so.prototype,"round",void 0),ro([o({type:String})],so.prototype,"label",void 0),ro([o({type:String})],so.prototype,"icon",void 0),ro([o({type:String})],so.prototype,"iconVariant",void 0),ro([o({type:Boolean})],so.prototype,"trailingIcon",void 0),ro([o({type:Boolean})],so.prototype,"loading",void 0),ro([o({type:String})],so.prototype,"tooltipPosition",void 0),ro([o({type:Boolean})],so.prototype,"hideTooltip",void 0),ro([o({type:Boolean})],so.prototype,"forceTooltip",void 0),ro([s(".ft-button")],so.prototype,"button",void 0),ro([s(".ft-button--label slot")],so.prototype,"slottedContent",void 0),h("ft-button")(so),function(t){t.S="S",t.M="M",t.L="L",t.XL="XL",t.XXL="XXL"}(no||(no={}));const ao=x`
|
|
672
672
|
.ft-size-watcher--pixel {
|
|
673
673
|
width: 0;
|
|
674
674
|
height: 0;
|
|
@@ -687,25 +687,25 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
687
687
|
.ft-size-watcher--local .ft-size-watcher--watcher {
|
|
688
688
|
width: 100%;
|
|
689
689
|
}
|
|
690
|
-
`;var
|
|
690
|
+
`;var lo=function(t,e,i,o){for(var n,r=arguments.length,s=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(e,i,s):n(e,i))||s);return r>3&&s&&Object.defineProperty(e,i,s),s};class ho extends CustomEvent{constructor(t,e){super("change",{detail:{size:t,category:e}})}}class co extends wt{constructor(){super(...arguments),this.debounceTimeout=100,this.local=!1,this.size=0,this.category=no.S,this.resizeObserver=new ResizeObserver((()=>this.updateSize())),this.debouncer=new e}render(){return X`
|
|
691
691
|
<div class="ft-size-watcher--pixel ${this.local?"ft-size-watcher--local":""}">
|
|
692
692
|
<div class="ft-size-watcher--watcher"></div>
|
|
693
693
|
</div>
|
|
694
|
-
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.watcher&&this.resizeObserver.observe(this.watcher),this.updateSize()}updateSize(){this.debouncer.run((()=>{this.watcher&&this.size!==this.watcher.clientWidth&&(this.size=this.watcher.clientWidth,this.size<768?this.category=
|
|
694
|
+
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.watcher&&this.resizeObserver.observe(this.watcher),this.updateSize()}updateSize(){this.debouncer.run((()=>{this.watcher&&this.size!==this.watcher.clientWidth&&(this.size=this.watcher.clientWidth,this.size<768?this.category=no.S:this.size<976?this.category=no.M:this.size<1024?this.category=no.L:this.size<1440?this.category=no.XL:this.category=no.XXL,this.dispatchEvent(new ho(this.size,this.category)))}),this.debounceTimeout)}}co.elementDefinitions={},co.styles=ao,lo([o({type:Number})],co.prototype,"debounceTimeout",void 0),lo([o({type:Boolean})],co.prototype,"local",void 0),lo([o({type:Number,reflect:!0})],co.prototype,"size",void 0),lo([o({type:String,reflect:!0})],co.prototype,"category",void 0),lo([s(".ft-size-watcher--watcher")],co.prototype,"watcher",void 0),h("ft-size-watcher")(co);const po={expand:"Expand {0}",collapse:"Collapse {0}"},fo={tabulationSize:bt.create("--ft-reader-toc-tabulation-size","SIZE","16px"),verticalSpacing:bt.create("--ft-reader-toc-vertical-spacing","SIZE","4px"),textColor:bt.extend("--ft-reader-toc-text-color",gt.colorOnSurface),highlightedTextColor:bt.extend("--ft-reader-toc-highlighted-text-color",gt.colorPrimary),highlightedFontWeight:bt.create("--ft-reader-toc-highlighted-font-weight","UNKNOWN","bold"),highlightedBackgroundColor:bt.create("--ft-reader-toc-highlighted-background-color","COLOR","transparent"),iconFontSize:bt.create("--ft-reader-toc-icon-font-size","SIZE","16px")},uo=x`
|
|
695
695
|
.ft-reader-toc {
|
|
696
|
-
color: ${
|
|
696
|
+
color: ${fo.textColor};
|
|
697
697
|
}
|
|
698
698
|
|
|
699
699
|
.ft-reader-toc--node-highlighted > .ft-reader-toc--link-container {
|
|
700
|
-
background-color: ${
|
|
701
|
-
color: ${
|
|
702
|
-
${xt(
|
|
700
|
+
background-color: ${fo.highlightedBackgroundColor};
|
|
701
|
+
color: ${fo.highlightedTextColor};
|
|
702
|
+
${xt(ee.fontWeight,fo.highlightedFontWeight)}
|
|
703
703
|
}
|
|
704
704
|
|
|
705
705
|
.ft-reader-toc--link-container {
|
|
706
706
|
display: flex;
|
|
707
707
|
gap: 4px;
|
|
708
|
-
padding: ${
|
|
708
|
+
padding: ${fo.verticalSpacing} 4px; /* left padding is override on inline style */
|
|
709
709
|
align-items: center;
|
|
710
710
|
}
|
|
711
711
|
|
|
@@ -714,11 +714,11 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
714
714
|
}
|
|
715
715
|
|
|
716
716
|
.ft-reader-toc-mobile .ft-reader-toc--toggle-container {
|
|
717
|
-
width: calc(${
|
|
717
|
+
width: calc(${fo.iconFontSize} + 12px); /*--ft-button-internal-horizontal-padding: 8px; in ft-button NOT dense*/
|
|
718
718
|
}
|
|
719
719
|
|
|
720
720
|
.ft-reader-toc-desktop .ft-reader-toc--toggle-container {
|
|
721
|
-
width: calc(${
|
|
721
|
+
width: calc(${fo.iconFontSize} + 4px); /*--ft-button-internal-horizontal-padding: 4px; in ft-button dense*/
|
|
722
722
|
}
|
|
723
723
|
|
|
724
724
|
.ft-reader-toc-expanded .ft-reader-toc--toggle-container {
|
|
@@ -726,10 +726,10 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
726
726
|
}
|
|
727
727
|
|
|
728
728
|
ft-button {
|
|
729
|
-
${xt(
|
|
730
|
-
${xt(
|
|
729
|
+
${xt(Qi.iconSize,fo.iconFontSize)};
|
|
730
|
+
${xt(Qi.backgroundColor,"transparent")};
|
|
731
731
|
}
|
|
732
|
-
`;var
|
|
732
|
+
`;var vo=function(t,e,i,o){for(var n,r=arguments.length,s=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(e,i,s):n(e,i))||s);return r>3&&s&&Object.defineProperty(e,i,s),s};class yo extends Zt{constructor(){super(...arguments),this.expanded=!1,this.iconVariant=Ni.fluid_topics,this.collapseIcon="MINUS",this.expandIcon="PLUS",this.autoCollapse=!1,this.scope="pages",this.hideIfEmpty=!1,this.empty=!0,this.labels={},this.labelResolver=new Ot(po,{}),this.automaticallyExpandedNodes=new Set,this.manuallyExpandedNodes=new Set,this.manuallyCollapsedNodes=new Set,this.viewportSize=no.M}get isCurrentPageToc(){return"current-page"===this.scope}update(t){var e,i;if(super.update(t),t.has("labels")&&(this.labelResolver=new Ot(po,this.labels)),!this.expanded&&["splitToc","visibleTopics","currentPage","toc"].some((e=>t.has(e)))){const t=this.isCurrentPageToc||!this.splitToc?null!==(e=this.visibleTopics)&&void 0!==e?e:[]:this.currentPage?[this.currentPage.rootTocId]:[];this.automaticallyExpandedNodes=this.buildAutomaticallyExpandedNodes(t)}this.empty=0===(null!==(i=this.getToc())&&void 0!==i?i:[]).length}render(){var t;const e={"ft-reader-toc":!0,"ft-reader-toc-mobile":this.viewportSize===no.S,"ft-reader-toc-desktop":this.viewportSize!==no.S,"ft-reader-toc-loaded":null!=this.toc&&null!=this.currentPage,"ft-reader-toc-expanded":this.expanded};return X`
|
|
733
733
|
${this.hideIfEmpty&&this.empty?X`
|
|
734
734
|
<style>
|
|
735
735
|
:host {
|
|
@@ -737,17 +737,17 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
737
737
|
}
|
|
738
738
|
</style>
|
|
739
739
|
`:Y}
|
|
740
|
-
<div class=${
|
|
740
|
+
<div class=${Dt(e)}>
|
|
741
741
|
<ft-size-watcher @change=${this.onViewportSizeChange}></ft-size-watcher>
|
|
742
|
-
${
|
|
742
|
+
${_t(null!==(t=this.getToc())&&void 0!==t?t:[],(t=>t.tocId),(t=>this.renderNode(t)))}
|
|
743
743
|
</div>
|
|
744
|
-
`}getToc(){var t;return this.isCurrentPageToc?this.splitToc?null===(t=this.currentPage)||void 0===t?void 0:t.toc:void 0:this.toc}renderNode(t){var e,i,o,n;const r=!this.isCurrentPageToc&&this.splitToc&&null!=t.page&&!t.page.onItsOwn,s=!this.isCurrentPageToc&&this.splitToc?(null===(e=this.currentPage)||void 0===e?void 0:e.rootTocId)===t.tocId:null===(i=this.visibleTopics)||void 0===i?void 0:i.includes(t.tocId),a=this.expanded||this.manuallyExpandedNodes.has(t.tocId)||this.automaticallyExpandedNodes.has(t.tocId)&&!this.manuallyCollapsedNodes.has(t.tocId),l=(this.isCurrentPageToc||!r)&&t.children.length>0,h=l&&!this.expanded,c=this.isCurrentPageToc?(null!==(n=null===(o=this.currentPage)||void 0===o?void 0:o.breadcrumb.length)&&void 0!==n?n:0)+1:0,p=t.depth-1-c,d={"padding-left":`calc( ${
|
|
744
|
+
`}getToc(){var t;return this.isCurrentPageToc?this.splitToc?null===(t=this.currentPage)||void 0===t?void 0:t.toc:void 0:this.toc}renderNode(t){var e,i,o,n;const r=!this.isCurrentPageToc&&this.splitToc&&null!=t.page&&!t.page.onItsOwn,s=!this.isCurrentPageToc&&this.splitToc?(null===(e=this.currentPage)||void 0===e?void 0:e.rootTocId)===t.tocId:null===(i=this.visibleTopics)||void 0===i?void 0:i.includes(t.tocId),a=this.expanded||this.manuallyExpandedNodes.has(t.tocId)||this.automaticallyExpandedNodes.has(t.tocId)&&!this.manuallyCollapsedNodes.has(t.tocId),l=(this.isCurrentPageToc||!r)&&t.children.length>0,h=l&&!this.expanded,c=this.isCurrentPageToc?(null!==(n=null===(o=this.currentPage)||void 0===o?void 0:o.breadcrumb.length)&&void 0!==n?n:0)+1:0,p=t.depth-1-c,d={"padding-left":`calc( ${fo.tabulationSize} * ${p} + 4px)`};return X`
|
|
745
745
|
<div class="ft-reader-toc--node ${s?"ft-reader-toc--node-highlighted":""}">
|
|
746
|
-
<div class="ft-reader-toc--link-container" data-depth="${t.depth}" style=${
|
|
746
|
+
<div class="ft-reader-toc--link-container" data-depth="${t.depth}" style=${Wt(d)}>
|
|
747
747
|
<div class="ft-reader-toc--toggle-container">
|
|
748
748
|
${h?X`
|
|
749
749
|
<ft-button round hideTooltip
|
|
750
|
-
?dense=${this.viewportSize!==
|
|
750
|
+
?dense=${this.viewportSize!==no.S}
|
|
751
751
|
label="${this.labelResolver.resolve(a?"collapse":"expand",t.title)}"
|
|
752
752
|
iconVariant="${this.iconVariant}"
|
|
753
753
|
icon="${a?this.collapseIcon:this.expandIcon}"
|
|
@@ -765,8 +765,8 @@ function(t,e,i){let o,n=t;return"object"==typeof t?(n=t.slot,o=t):o={flatten:e},
|
|
|
765
765
|
</div>
|
|
766
766
|
${l?X`
|
|
767
767
|
<div class="ft-reader-toc--node-children">
|
|
768
|
-
${a?
|
|
768
|
+
${a?_t(t.children,(t=>t.tocId),(t=>this.renderNode(t))):Y}
|
|
769
769
|
</div>
|
|
770
770
|
`:Y}
|
|
771
771
|
</div>
|
|
772
|
-
`}buildAutomaticallyExpandedNodes(t){var e,i,o,n;let r=new Set(this.autoCollapse?[]:this.automaticallyExpandedNodes);for(let s of t){let t=null===(i=null===(e=this.service)||void 0===e?void 0:e.getTocNodeOrThrow(s))||void 0===i?void 0:i.parentTocId;for(;t&&!r.has(t);)r.add(t),this.manuallyCollapsedNodes.delete(t),t=null===(n=null===(o=this.service)||void 0===o?void 0:o.getTocNodeOrThrow(t))||void 0===n?void 0:n.parentTocId}return r}manuallyToggle(t,e){e?(this.manuallyCollapsedNodes.add(t),this.manuallyExpandedNodes.delete(t)):(this.manuallyExpandedNodes.add(t),this.manuallyCollapsedNodes.delete(t)),this.requestUpdate()}onViewportSizeChange(t){this.viewportSize=t.detail.category}}
|
|
772
|
+
`}buildAutomaticallyExpandedNodes(t){var e,i,o,n;let r=new Set(this.autoCollapse?[]:this.automaticallyExpandedNodes);for(let s of t){let t=null===(i=null===(e=this.service)||void 0===e?void 0:e.getTocNodeOrThrow(s))||void 0===i?void 0:i.parentTocId;for(;t&&!r.has(t);)r.add(t),this.manuallyCollapsedNodes.delete(t),t=null===(n=null===(o=this.service)||void 0===o?void 0:o.getTocNodeOrThrow(t))||void 0===n?void 0:n.parentTocId}return r}manuallyToggle(t,e){e?(this.manuallyCollapsedNodes.add(t),this.manuallyExpandedNodes.delete(t)):(this.manuallyExpandedNodes.add(t),this.manuallyCollapsedNodes.delete(t)),this.requestUpdate()}onViewportSizeChange(t){this.viewportSize=t.detail.category}}yo.elementDefinitions={"ft-button":so,"ft-reader-internal-link":gi,"ft-size-watcher":co,"ft-typography":vi},yo.styles=uo,vo([o({type:Boolean})],yo.prototype,"expanded",void 0),vo([o()],yo.prototype,"iconVariant",void 0),vo([o()],yo.prototype,"collapseIcon",void 0),vo([o()],yo.prototype,"expandIcon",void 0),vo([o({type:Boolean})],yo.prototype,"autoCollapse",void 0),vo([o()],yo.prototype,"scope",void 0),vo([o({type:Boolean})],yo.prototype,"hideIfEmpty",void 0),vo([o({type:Boolean,reflect:!0})],yo.prototype,"empty",void 0),vo([c({})],yo.prototype,"labels",void 0),vo([St()],yo.prototype,"toc",void 0),vo([St((t=>{var e;return null===(e=t.map)||void 0===e?void 0:e.shouldSplitCurrentPageToc}))],yo.prototype,"splitToc",void 0),vo([St()],yo.prototype,"currentPage",void 0),vo([St()],yo.prototype,"visibleTopics",void 0),vo([n({hasChanged:(t,e)=>!p(t,e)})],yo.prototype,"automaticallyExpandedNodes",void 0),vo([n({hasChanged:(t,e)=>!p(t,e)})],yo.prototype,"manuallyExpandedNodes",void 0),vo([n({hasChanged:(t,e)=>!p(t,e)})],yo.prototype,"manuallyCollapsedNodes",void 0),vo([n()],yo.prototype,"viewportSize",void 0),h("ft-reader-toc")(yo),t.DEFAULT_LABELS=po,t.FtReaderToc=yo,t.FtReaderTocCssVariables=fo,t.styles=uo,Object.defineProperty(t,"i",{value:!0})}({});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluid-topics/ft-reader-toc",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.23",
|
|
4
4
|
"description": "Main table of content for integrated reader",
|
|
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": "0.3.
|
|
23
|
-
"@fluid-topics/ft-reader-context": "0.3.
|
|
24
|
-
"@fluid-topics/ft-size-watcher": "0.3.
|
|
25
|
-
"@fluid-topics/ft-typography": "0.3.
|
|
26
|
-
"@fluid-topics/ft-wc-utils": "0.3.
|
|
22
|
+
"@fluid-topics/ft-icon": "0.3.23",
|
|
23
|
+
"@fluid-topics/ft-reader-context": "0.3.23",
|
|
24
|
+
"@fluid-topics/ft-size-watcher": "0.3.23",
|
|
25
|
+
"@fluid-topics/ft-typography": "0.3.23",
|
|
26
|
+
"@fluid-topics/ft-wc-utils": "0.3.23",
|
|
27
27
|
"lit": "2.2.8"
|
|
28
28
|
},
|
|
29
|
-
"gitHead": "
|
|
29
|
+
"gitHead": "7fb0bb52d064423f63bfd9c36c5454d65aa890d6"
|
|
30
30
|
}
|