@fluid-topics/ft-reader-toc 2.0.28 → 2.0.29

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.
@@ -82,7 +82,7 @@ Also for action icons.`,l.colorGray200),contentGlobalSubtle:n.extend("--ftds-con
82
82
  <li>${this.helperText}</li>
83
83
  `)}
84
84
  </ul>
85
- `}resolveStatus(){return this.forceStatus?this.forceStatus:this.errorMessages.length?gr.error:this.warningMessages.length?gr.warning:gr.default}processRules(o){return o.map(a=>a(this.value)).filter(a=>a!==!0).map(a=>a)}}return be([E()],e.prototype,"warningRules",void 0),be([E()],e.prototype,"errorRules",void 0),be([E()],e.prototype,"validateOn",void 0),be([E({type:Boolean})],e.prototype,"validateAtRender",void 0),be([E()],e.prototype,"label",void 0),be([E({type:Boolean})],e.prototype,"hideLabel",void 0),be([E()],e.prototype,"name",void 0),be([E({type:Boolean})],e.prototype,"disabled",void 0),be([E()],e.prototype,"helperText",void 0),be([E()],e.prototype,"forceStatus",void 0),be([E({reflect:!0})],e.prototype,"value",void 0),be([ee()],e.prototype,"errorMessages",void 0),be([ee()],e.prototype,"warningMessages",void 0),be([ee()],e.prototype,"status",void 0),be([ee()],e.prototype,"focused",void 0),be([ee()],e.prototype,"additionalWarningRules",void 0),be([ee()],e.prototype,"additionalErrorRules",void 0),e});var $o=(t,e)=>{let r=t._$AN;if(r===void 0)return!1;for(let o of r)o._$AO?.(e,!1),$o(o,e);return!0},Dn=t=>{let e,r;do{if((e=t._$AM)===void 0)break;r=e._$AN,r.delete(t),t=e}while(r?.size===0)},g2=t=>{for(let e;e=t._$AM;t=e){let r=e._$AN;if(r===void 0)e._$AN=r=new Set;else if(r.has(t))break;r.add(t),Tf(e)}};function _f(t){this._$AN!==void 0?(Dn(this),this._$AM=t,g2(this)):this._$AM=t}function Nf(t,e=!1,r=0){let o=this._$AH,a=this._$AN;if(a!==void 0&&a.size!==0)if(e)if(Array.isArray(o))for(let i=r;i<o.length;i++)$o(o[i],!1),Dn(o[i]);else o!=null&&($o(o,!1),Dn(o));else $o(this,t)}var Tf=t=>{t.type==nt.CHILD&&(t._$AP??=Nf,t._$AQ??=_f)},jr=class extends Fe{constructor(){super(...arguments),this._$AN=void 0}_$AT(e,r,o){super._$AT(e,r,o),g2(this),this.isConnected=e._$AU}_$AO(e,r=!0){e!==this.isConnected&&(this.isConnected=e,e?this.reconnected?.():this.disconnected?.()),r&&($o(this,e),Dn(this))}setValue(e){if(qc(this._$Ct))this._$Ct._$AI(e,this);else{let r=[...this._$Ct._$AH];r[this._$Ci]=e,this._$Ct._$AI(r,this,0)}}disconnected(){}reconnected(){}};var Ts=class extends jr{get element(){var e;return(e=this.part)===null||e===void 0?void 0:e.element}constructor(e){super(e),this.onFirstTrapFocus=async r=>{if(!this.element||!r.relatedTarget)return;let o=r.relatedTarget;this.isInsideElement(o,this.element)?await this.focusLastDescendant(this.element):await this.focusFirstDescendant(this.element)},this.onLastTrapFocus=async r=>{if(!this.element||!r.relatedTarget)return;let o=r.relatedTarget;this.isInsideElement(o,this.element)?await this.focusFirstDescendant(this.element):await this.focusLastDescendant(this.element)}}render(){return fe}update(e){return this.part=e,this.ensureFocusTrap(e.element),fe}reconnected(){var e;this.ensureFocusTrap((e=this.part)===null||e===void 0?void 0:e.element)}disconnected(){this.removeFocusTrap()}ensureFocusTrap(e){var r,o;this.isElementTrappable(e)&&(((r=this.firstTrap)===null||r===void 0?void 0:r.parentElement)===e&&((o=this.lastTrap)===null||o===void 0?void 0:o.parentElement)===e||(this.removeFocusTrap(),this.createFocusTrap(e)))}removeFocusTrap(){var e,r,o,a;(e=this.firstTrap)===null||e===void 0||e.removeEventListener("focus",this.onFirstTrapFocus),(r=this.lastTrap)===null||r===void 0||r.removeEventListener("focus",this.onLastTrapFocus),(o=this.firstTrap)===null||o===void 0||o.remove(),(a=this.lastTrap)===null||a===void 0||a.remove(),this.firstTrap=void 0,this.lastTrap=void 0}isElementTrappable(e){return!!e&&e instanceof HTMLElement&&e.childElementCount>0}createFocusTrap(e){this.firstTrap=this.createTrap(),this.lastTrap=this.createTrap(),e.insertBefore(this.firstTrap,e.firstChild),e.appendChild(this.lastTrap),this.lastTrap.addEventListener("focus",this.onLastTrapFocus),this.firstTrap.addEventListener("focus",this.onFirstTrapFocus)}createTrap(){let e=document.createElement("div");return e.tabIndex=0,e}getChildren(e){return e instanceof HTMLSlotElement?e.assignedElements():e.shadowRoot?e.shadowRoot.children:e.children}async focusFirstDescendant(e){await this.updateCompleteIfNecessary(e);let r=this.getChildren(e);for(let o=0;o<r.length;o++){let a=r[o];if(a instanceof HTMLElement&&(this.attemptFocus(a)||await this.focusFirstDescendant(a)))return!0}return!1}async focusLastDescendant(e){await this.updateCompleteIfNecessary(e);let r=this.getChildren(e);for(let o=r.length-1;o>=0;o--){let a=r[o];if(a instanceof HTMLElement&&(this.attemptFocus(a)||await this.focusLastDescendant(a)))return!0}return!1}async updateCompleteIfNecessary(e){e instanceof He&&await e.updateComplete}isInsideElement(e,r){for(let o=e;o;o=o.parentNode){if(o===r)return!0;o instanceof ShadowRoot?o=o.host:o.assignedSlot&&(o=o.assignedSlot)}return!1}attemptFocus(e){return e===this.firstTrap||e===this.lastTrap||!this.isFocusable(e)?!1:(e.focus(),!0)}isFocusable(e){return!e.checkVisibility()||this.isElementDisabled(e)?!1:e instanceof HTMLAnchorElement?!!e.href&&e.rel!=="ignore":e instanceof HTMLInputElement?e.type!=="hidden":e.tabIndex>=0}isElementDisabled(e){return"disabled"in e&&!!e.disabled}},w7=Te(Ts);var y2;(function(t){t.sm="sm",t.md="md",t.lg="lg",t.xl="xl"})(y2||(y2={}));var Mf={sm:640,md:768,lg:1024,xl:1280},Ms=class extends jr{constructor(e){super(e),this.size=0,this.onResize=()=>{let r=window.innerWidth;this.size!==r&&(this.size=r,this.lastArgs&&this.setValue(this.render(...this.lastArgs)))},this.size=window.innerWidth,window.addEventListener("resize",this.onResize)}disconnected(){window.removeEventListener("resize",this.onResize)}reconnected(){window.addEventListener("resize",this.onResize)}update(e,[r,o,a]){return this.lastArgs=[r,o,a],this.render(r,o,a)}render(e,r,o){let a=this.resolveThreshold(e),i=o??(()=>K);return this.size>a?r():i()}resolveThreshold(e){return typeof e=="number"?e:Mf[e]}},M7=Te(Ms);var Ps,Is,ks,zs,Ds=navigator.vendor&&!!navigator.vendor.match(/apple/i)||((ks=(Is=(Ps=window.safari)===null||Ps===void 0?void 0:Ps.pushNotification)===null||Is===void 0?void 0:Is.toString())!==null&&ks!==void 0?ks:"")==="[object SafariRemoteNotification]",Pf="ontouchstart"in window||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0;window.ftGlobals=(zs=window.ftGlobals)!==null&&zs!==void 0?zs:{lit:wa,litDecorators:Na,litRepeat:Ta,litClassMap:Ma,litStyleMap:Ia,litUnsafeHTML:ka,wcUtils:{...ja,...Da,...Xa,...As,...Ja,...Ba,...yi,...Va,...Mi,...ws,...p2,...bs,...Pi,...gi,...Bi,...Es,...Di,..._s,...Gl,...Fa,...Fi,...bi,...Gi,...h2,...Vl,...Wi,...hs,...Os,...Ii,...zi,...vs,...Za,isSafari:Ds,isTouchScreen:Pf,setVariable:w}};var Ho=t=>t??K;var b2;(function(t){t.clusteringHelperCreated="clustering-helper-created",t.mapAttachmentsUpdate="map-attachments-update",t.visibleTopicChange="visible-topic-change"})(b2||(b2={}));var x2;(function(t){t.FEEDBACK="FEEDBACK",t.RATING="RATING",t.PRINT="PRINT",t.BOOKMARK="BOOKMARK",t.COLLECTIONS="COLLECTIONS",t.PERSONAL_BOOKS="PERSONAL_BOOKS"})(x2||(x2={}));var If=function(t,e,r,o){var a=arguments.length,i=a<3?e:o===null?o=Object.getOwnPropertyDescriptor(e,r):o,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,o);else for(var c=t.length-1;c>=0;c--)(s=t[c])&&(i=(a<3?s(i):a>3?s(e,r,i):s(e,r))||i);return a>3&&i&&Object.defineProperty(e,r,i),i},Bs=class extends Event{constructor(){super("register-ft-reader-component",{bubbles:!0,composed:!0})}},Us=Symbol("registerInterval"),kf=pe(Symbol("toFtReaderComponent"),function(t){var e;class r extends t{constructor(){super(...arguments),this[e]=0}setReaderStateManager(a){this.clearStateManager(),this.stateManager=a,this.addStore(a.store,"reader")}clearStateManager(){this.stateManager&&(this.removeStore("reader"),this.stateManager=void 0)}get service(){var a;return(a=this.stateManager)===null||a===void 0?void 0:a.service}connectedCallback(){super.connectedCallback(),this[Us]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null?window.clearInterval(this[Us]):this.dispatchEvent(new Bs)}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return e=Us,If([ee()],r.prototype,"stateManager",void 0),r}),Kr=class extends kf(Ct){};var S2=Symbol.for(""),zf=t=>{if(t?.r===S2)return t?._$litStatic$},Zr=t=>({_$litStatic$:t,r:S2});var v2=new Map,$s=t=>(e,...r)=>{let o=r.length,a,i,s=[],c=[],d,u=0,h=!1;for(;u<o;){for(d=e[u];u<o&&(i=r[u],(a=zf(i))!==void 0);)d+=a+e[++u],h=!0;u!==o&&c.push(i),s.push(d),u++}if(u===o&&s.push(e[o]),h){let p=s.join("$$lit$$");(e=v2.get(p))===void 0&&(s.raw=s,v2.set(p,e=s)),r=c}return t(e,...r)},Yr=$s(H),M9=$s(Ea),P9=$s(Aa);var Bt;(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"})(Bt||(Bt={}));var C2=n.extend("--ft-typography-font-family","",G.titleFont),At=n.extend("--ft-typography-font-family","",G.contentFont),$={fontFamily:At,fontSize:n.create("--ft-typography-font-size","","SIZE","16px"),fontWeight:n.create("--ft-typography-font-weight","","UNKNOWN","normal"),letterSpacing:n.create("--ft-typography-letter-spacing","","SIZE","0.496px"),lineHeight:n.create("--ft-typography-line-height","","NUMBER","1.5"),textTransform:n.create("--ft-typography-text-transform","","UNKNOWN","inherit")},qr={fontFamily:n.extend("--ft-typography-title-font-family","",C2),fontSize:n.extend("--ft-typography-title-font-size","",$.fontSize,"20px"),fontWeight:n.extend("--ft-typography-title-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-title-letter-spacing","",$.letterSpacing,"0.15px"),lineHeight:n.extend("--ft-typography-title-line-height","",$.lineHeight,"1.2"),textTransform:n.extend("--ft-typography-title-text-transform","",$.textTransform,"inherit")},Xr={fontFamily:n.extend("--ft-typography-title-dense-font-family","",C2),fontSize:n.extend("--ft-typography-title-dense-font-size","",$.fontSize,"14px"),fontWeight:n.extend("--ft-typography-title-dense-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-title-dense-letter-spacing","",$.letterSpacing,"0.105px"),lineHeight:n.extend("--ft-typography-title-dense-line-height","",$.lineHeight,"1.7"),textTransform:n.extend("--ft-typography-title-dense-text-transform","",$.textTransform,"inherit")},Jr={fontFamily:n.extend("--ft-typography-subtitle1-font-family","",At),fontSize:n.extend("--ft-typography-subtitle1-font-size","",$.fontSize,"16px"),fontWeight:n.extend("--ft-typography-subtitle1-font-weight","",$.fontWeight,"600"),letterSpacing:n.extend("--ft-typography-subtitle1-letter-spacing","",$.letterSpacing,"0.144px"),lineHeight:n.extend("--ft-typography-subtitle1-line-height","",$.lineHeight,"1.5"),textTransform:n.extend("--ft-typography-subtitle1-text-transform","",$.textTransform,"inherit")},Qr={fontFamily:n.extend("--ft-typography-subtitle2-font-family","",At),fontSize:n.extend("--ft-typography-subtitle2-font-size","",$.fontSize,"14px"),fontWeight:n.extend("--ft-typography-subtitle2-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-subtitle2-letter-spacing","",$.letterSpacing,"0.098px"),lineHeight:n.extend("--ft-typography-subtitle2-line-height","",$.lineHeight,"1.7"),textTransform:n.extend("--ft-typography-subtitle2-text-transform","",$.textTransform,"inherit")},eo={fontFamily:n.extend("--ft-typography-body1-font-family","",At),fontSize:n.extend("--ft-typography-body1-font-size","",$.fontSize,"16px"),fontWeight:n.extend("--ft-typography-body1-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-body1-letter-spacing","",$.letterSpacing,"0.496px"),lineHeight:n.extend("--ft-typography-body1-line-height","",$.lineHeight,"1.5"),textTransform:n.extend("--ft-typography-body1-text-transform","",$.textTransform,"inherit")},to={fontFamily:n.extend("--ft-typography-body2-font-family","",At),fontSize:n.extend("--ft-typography-body2-font-size","",$.fontSize,"14px"),fontWeight:n.extend("--ft-typography-body2-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-body2-letter-spacing","",$.letterSpacing,"0.252px"),lineHeight:n.extend("--ft-typography-body2-line-height","",$.lineHeight,"1.4"),textTransform:n.extend("--ft-typography-body2-text-transform","",$.textTransform,"inherit")},ro={fontFamily:n.extend("--ft-typography-caption-font-family","",At),fontSize:n.extend("--ft-typography-caption-font-size","",$.fontSize,"12px"),fontWeight:n.extend("--ft-typography-caption-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-caption-letter-spacing","",$.letterSpacing,"0.396px"),lineHeight:n.extend("--ft-typography-caption-line-height","",$.lineHeight,"1.33"),textTransform:n.extend("--ft-typography-caption-text-transform","",$.textTransform,"inherit")},oo={fontFamily:n.extend("--ft-typography-breadcrumb-font-family","",At),fontSize:n.extend("--ft-typography-breadcrumb-font-size","",$.fontSize,"10px"),fontWeight:n.extend("--ft-typography-breadcrumb-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-breadcrumb-letter-spacing","",$.letterSpacing,"0.33px"),lineHeight:n.extend("--ft-typography-breadcrumb-line-height","",$.lineHeight,"1.6"),textTransform:n.extend("--ft-typography-breadcrumb-text-transform","",$.textTransform,"inherit")},no={fontFamily:n.extend("--ft-typography-overline-font-family","",At),fontSize:n.extend("--ft-typography-overline-font-size","",$.fontSize,"10px"),fontWeight:n.extend("--ft-typography-overline-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-overline-letter-spacing","",$.letterSpacing,"1.5px"),lineHeight:n.extend("--ft-typography-overline-line-height","",$.lineHeight,"1.6"),textTransform:n.extend("--ft-typography-overline-text-transform","",$.textTransform,"uppercase")},ut={fontFamily:n.extend("--ft-typography-button-font-family","",At),fontSize:n.extend("--ft-typography-button-font-size","",$.fontSize,"14px"),fontWeight:n.extend("--ft-typography-button-font-weight","",$.fontWeight,"600"),letterSpacing:n.extend("--ft-typography-button-letter-spacing","",$.letterSpacing,"1.246px"),lineHeight:n.extend("--ft-typography-button-line-height","",$.lineHeight,"1.15"),textTransform:n.extend("--ft-typography-button-text-transform","",$.textTransform,"uppercase")},E2=z`
85
+ `}resolveStatus(){return this.forceStatus?this.forceStatus:this.errorMessages.length?gr.error:this.warningMessages.length?gr.warning:gr.default}processRules(o){return o.map(a=>a(this.value)).filter(a=>a!==!0).map(a=>a)}}return be([E()],e.prototype,"warningRules",void 0),be([E()],e.prototype,"errorRules",void 0),be([E()],e.prototype,"validateOn",void 0),be([E({type:Boolean})],e.prototype,"validateAtRender",void 0),be([E()],e.prototype,"label",void 0),be([E({type:Boolean})],e.prototype,"hideLabel",void 0),be([E()],e.prototype,"name",void 0),be([E({type:Boolean})],e.prototype,"disabled",void 0),be([E()],e.prototype,"helperText",void 0),be([E()],e.prototype,"forceStatus",void 0),be([E({reflect:!0})],e.prototype,"value",void 0),be([ee()],e.prototype,"errorMessages",void 0),be([ee()],e.prototype,"warningMessages",void 0),be([ee()],e.prototype,"status",void 0),be([ee()],e.prototype,"focused",void 0),be([ee()],e.prototype,"additionalWarningRules",void 0),be([ee()],e.prototype,"additionalErrorRules",void 0),e});var $o=(t,e)=>{let r=t._$AN;if(r===void 0)return!1;for(let o of r)o._$AO?.(e,!1),$o(o,e);return!0},Dn=t=>{let e,r;do{if((e=t._$AM)===void 0)break;r=e._$AN,r.delete(t),t=e}while(r?.size===0)},g2=t=>{for(let e;e=t._$AM;t=e){let r=e._$AN;if(r===void 0)e._$AN=r=new Set;else if(r.has(t))break;r.add(t),Tf(e)}};function _f(t){this._$AN!==void 0?(Dn(this),this._$AM=t,g2(this)):this._$AM=t}function Nf(t,e=!1,r=0){let o=this._$AH,a=this._$AN;if(a!==void 0&&a.size!==0)if(e)if(Array.isArray(o))for(let i=r;i<o.length;i++)$o(o[i],!1),Dn(o[i]);else o!=null&&($o(o,!1),Dn(o));else $o(this,t)}var Tf=t=>{t.type==nt.CHILD&&(t._$AP??=Nf,t._$AQ??=_f)},jr=class extends Fe{constructor(){super(...arguments),this._$AN=void 0}_$AT(e,r,o){super._$AT(e,r,o),g2(this),this.isConnected=e._$AU}_$AO(e,r=!0){e!==this.isConnected&&(this.isConnected=e,e?this.reconnected?.():this.disconnected?.()),r&&($o(this,e),Dn(this))}setValue(e){if(qc(this._$Ct))this._$Ct._$AI(e,this);else{let r=[...this._$Ct._$AH];r[this._$Ci]=e,this._$Ct._$AI(r,this,0)}}disconnected(){}reconnected(){}};var Ts=class extends jr{get element(){var e;return(e=this.part)===null||e===void 0?void 0:e.element}constructor(e){super(e),this.onFirstTrapFocus=async r=>{if(!this.element||!r.relatedTarget)return;let o=r.relatedTarget;this.isInsideElement(o,this.element)?await this.focusLastDescendant(this.element):await this.focusFirstDescendant(this.element)},this.onLastTrapFocus=async r=>{if(!this.element||!r.relatedTarget)return;let o=r.relatedTarget;this.isInsideElement(o,this.element)?await this.focusFirstDescendant(this.element):await this.focusLastDescendant(this.element)}}render(){return fe}update(e){return this.part=e,this.ensureFocusTrap(e.element),fe}reconnected(){var e;this.ensureFocusTrap((e=this.part)===null||e===void 0?void 0:e.element)}disconnected(){this.removeFocusTrap()}ensureFocusTrap(e){var r,o;this.isElementTrappable(e)&&(((r=this.firstTrap)===null||r===void 0?void 0:r.parentElement)===e&&((o=this.lastTrap)===null||o===void 0?void 0:o.parentElement)===e||(this.removeFocusTrap(),this.createFocusTrap(e)))}removeFocusTrap(){var e,r,o,a;(e=this.firstTrap)===null||e===void 0||e.removeEventListener("focus",this.onFirstTrapFocus),(r=this.lastTrap)===null||r===void 0||r.removeEventListener("focus",this.onLastTrapFocus),(o=this.firstTrap)===null||o===void 0||o.remove(),(a=this.lastTrap)===null||a===void 0||a.remove(),this.firstTrap=void 0,this.lastTrap=void 0}isElementTrappable(e){return!!e&&e instanceof HTMLElement&&e.childElementCount>0}createFocusTrap(e){this.firstTrap=this.createTrap(),this.lastTrap=this.createTrap(),e.insertBefore(this.firstTrap,e.firstChild),e.appendChild(this.lastTrap),this.lastTrap.addEventListener("focus",this.onLastTrapFocus),this.firstTrap.addEventListener("focus",this.onFirstTrapFocus)}createTrap(){let e=document.createElement("div");return e.tabIndex=0,e}getChildren(e){return e instanceof HTMLSlotElement?e.assignedElements():e.shadowRoot?e.shadowRoot.children:e.children}async focusFirstDescendant(e){await this.updateCompleteIfNecessary(e);let r=this.getChildren(e);for(let o=0;o<r.length;o++){let a=r[o];if(a instanceof HTMLElement&&(this.attemptFocus(a)||await this.focusFirstDescendant(a)))return!0}return!1}async focusLastDescendant(e){await this.updateCompleteIfNecessary(e);let r=this.getChildren(e);for(let o=r.length-1;o>=0;o--){let a=r[o];if(a instanceof HTMLElement&&(this.attemptFocus(a)||await this.focusLastDescendant(a)))return!0}return!1}async updateCompleteIfNecessary(e){e instanceof He&&await e.updateComplete}isInsideElement(e,r){for(let o=e;o;o=o.parentNode){if(o===r)return!0;o instanceof ShadowRoot?o=o.host:o.assignedSlot&&(o=o.assignedSlot)}return!1}attemptFocus(e){return e===this.firstTrap||e===this.lastTrap||!this.isFocusable(e)?!1:(e.focus(),!0)}isFocusable(e){return!e.checkVisibility()||this.isElementDisabled(e)?!1:e instanceof HTMLAnchorElement?!!e.href&&e.rel!=="ignore":e instanceof HTMLInputElement?e.type!=="hidden":e.tabIndex>=0}isElementDisabled(e){return"disabled"in e&&!!e.disabled}},w7=Te(Ts);var y2;(function(t){t.sm="sm",t.md="md",t.lg="lg",t.xl="xl"})(y2||(y2={}));var Mf={sm:640,md:768,lg:1024,xl:1280},Ms=class extends jr{constructor(e){super(e),this.size=0,this.onResize=()=>{let r=window.innerWidth;this.size!==r&&(this.size=r,this.lastArgs&&this.setValue(this.render(...this.lastArgs)))},this.size=window.innerWidth,window.addEventListener("resize",this.onResize)}disconnected(){window.removeEventListener("resize",this.onResize)}reconnected(){window.addEventListener("resize",this.onResize)}update(e,[r,o,a]){return this.lastArgs=[r,o,a],this.render(r,o,a)}render(e,r,o){let a=this.resolveThreshold(e),i=o??(()=>K);return this.size>a?r():i()}resolveThreshold(e){return typeof e=="number"?e:Mf[e]}},M7=Te(Ms);var Ps,Is,ks,zs,Ds=navigator.vendor&&!!navigator.vendor.match(/apple/i)||((ks=(Is=(Ps=window.safari)===null||Ps===void 0?void 0:Ps.pushNotification)===null||Is===void 0?void 0:Is.toString())!==null&&ks!==void 0?ks:"")==="[object SafariRemoteNotification]",Pf="ontouchstart"in window||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0;window.ftGlobals=(zs=window.ftGlobals)!==null&&zs!==void 0?zs:{lit:wa,litDecorators:Na,litRepeat:Ta,litClassMap:Ma,litStyleMap:Ia,litUnsafeHTML:ka,wcUtils:{...ja,...Da,...Xa,...As,...Ja,...Ba,...yi,...Va,...Mi,...ws,...p2,...bs,...Pi,...gi,...Bi,...Es,...Di,..._s,...Gl,...Fa,...Fi,...bi,...Gi,...h2,...Vl,...Wi,...hs,...Os,...Ii,...zi,...vs,...Za,isSafari:Ds,isTouchScreen:Pf,setVariable:w}};var Ho=t=>t??K;var b2;(function(t){t.clusteringHelperCreated="clustering-helper-created",t.mapAttachmentsUpdate="map-attachments-update",t.visibleTopicChange="visible-topic-change",t.requestedTopicNotFound="requested-topic-not-found"})(b2||(b2={}));var x2;(function(t){t.FEEDBACK="FEEDBACK",t.RATING="RATING",t.PRINT="PRINT",t.BOOKMARK="BOOKMARK",t.COLLECTIONS="COLLECTIONS",t.PERSONAL_BOOKS="PERSONAL_BOOKS"})(x2||(x2={}));var If=function(t,e,r,o){var a=arguments.length,i=a<3?e:o===null?o=Object.getOwnPropertyDescriptor(e,r):o,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,o);else for(var c=t.length-1;c>=0;c--)(s=t[c])&&(i=(a<3?s(i):a>3?s(e,r,i):s(e,r))||i);return a>3&&i&&Object.defineProperty(e,r,i),i},Bs=class extends Event{constructor(){super("register-ft-reader-component",{bubbles:!0,composed:!0})}},Us=Symbol("registerInterval"),kf=pe(Symbol("toFtReaderComponent"),function(t){var e;class r extends t{constructor(){super(...arguments),this[e]=0}setReaderStateManager(a){this.clearStateManager(),this.stateManager=a,this.addStore(a.store,"reader")}clearStateManager(){this.stateManager&&(this.removeStore("reader"),this.stateManager=void 0)}get service(){var a;return(a=this.stateManager)===null||a===void 0?void 0:a.service}connectedCallback(){super.connectedCallback(),this[Us]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null?window.clearInterval(this[Us]):this.dispatchEvent(new Bs)}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return e=Us,If([ee()],r.prototype,"stateManager",void 0),r}),Kr=class extends kf(Ct){};var S2=Symbol.for(""),zf=t=>{if(t?.r===S2)return t?._$litStatic$},Zr=t=>({_$litStatic$:t,r:S2});var v2=new Map,$s=t=>(e,...r)=>{let o=r.length,a,i,s=[],c=[],d,u=0,h=!1;for(;u<o;){for(d=e[u];u<o&&(i=r[u],(a=zf(i))!==void 0);)d+=a+e[++u],h=!0;u!==o&&c.push(i),s.push(d),u++}if(u===o&&s.push(e[o]),h){let p=s.join("$$lit$$");(e=v2.get(p))===void 0&&(s.raw=s,v2.set(p,e=s)),r=c}return t(e,...r)},Yr=$s(H),M9=$s(Ea),P9=$s(Aa);var Bt;(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"})(Bt||(Bt={}));var C2=n.extend("--ft-typography-font-family","",G.titleFont),At=n.extend("--ft-typography-font-family","",G.contentFont),$={fontFamily:At,fontSize:n.create("--ft-typography-font-size","","SIZE","16px"),fontWeight:n.create("--ft-typography-font-weight","","UNKNOWN","normal"),letterSpacing:n.create("--ft-typography-letter-spacing","","SIZE","0.496px"),lineHeight:n.create("--ft-typography-line-height","","NUMBER","1.5"),textTransform:n.create("--ft-typography-text-transform","","UNKNOWN","inherit")},qr={fontFamily:n.extend("--ft-typography-title-font-family","",C2),fontSize:n.extend("--ft-typography-title-font-size","",$.fontSize,"20px"),fontWeight:n.extend("--ft-typography-title-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-title-letter-spacing","",$.letterSpacing,"0.15px"),lineHeight:n.extend("--ft-typography-title-line-height","",$.lineHeight,"1.2"),textTransform:n.extend("--ft-typography-title-text-transform","",$.textTransform,"inherit")},Xr={fontFamily:n.extend("--ft-typography-title-dense-font-family","",C2),fontSize:n.extend("--ft-typography-title-dense-font-size","",$.fontSize,"14px"),fontWeight:n.extend("--ft-typography-title-dense-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-title-dense-letter-spacing","",$.letterSpacing,"0.105px"),lineHeight:n.extend("--ft-typography-title-dense-line-height","",$.lineHeight,"1.7"),textTransform:n.extend("--ft-typography-title-dense-text-transform","",$.textTransform,"inherit")},Jr={fontFamily:n.extend("--ft-typography-subtitle1-font-family","",At),fontSize:n.extend("--ft-typography-subtitle1-font-size","",$.fontSize,"16px"),fontWeight:n.extend("--ft-typography-subtitle1-font-weight","",$.fontWeight,"600"),letterSpacing:n.extend("--ft-typography-subtitle1-letter-spacing","",$.letterSpacing,"0.144px"),lineHeight:n.extend("--ft-typography-subtitle1-line-height","",$.lineHeight,"1.5"),textTransform:n.extend("--ft-typography-subtitle1-text-transform","",$.textTransform,"inherit")},Qr={fontFamily:n.extend("--ft-typography-subtitle2-font-family","",At),fontSize:n.extend("--ft-typography-subtitle2-font-size","",$.fontSize,"14px"),fontWeight:n.extend("--ft-typography-subtitle2-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-subtitle2-letter-spacing","",$.letterSpacing,"0.098px"),lineHeight:n.extend("--ft-typography-subtitle2-line-height","",$.lineHeight,"1.7"),textTransform:n.extend("--ft-typography-subtitle2-text-transform","",$.textTransform,"inherit")},eo={fontFamily:n.extend("--ft-typography-body1-font-family","",At),fontSize:n.extend("--ft-typography-body1-font-size","",$.fontSize,"16px"),fontWeight:n.extend("--ft-typography-body1-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-body1-letter-spacing","",$.letterSpacing,"0.496px"),lineHeight:n.extend("--ft-typography-body1-line-height","",$.lineHeight,"1.5"),textTransform:n.extend("--ft-typography-body1-text-transform","",$.textTransform,"inherit")},to={fontFamily:n.extend("--ft-typography-body2-font-family","",At),fontSize:n.extend("--ft-typography-body2-font-size","",$.fontSize,"14px"),fontWeight:n.extend("--ft-typography-body2-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-body2-letter-spacing","",$.letterSpacing,"0.252px"),lineHeight:n.extend("--ft-typography-body2-line-height","",$.lineHeight,"1.4"),textTransform:n.extend("--ft-typography-body2-text-transform","",$.textTransform,"inherit")},ro={fontFamily:n.extend("--ft-typography-caption-font-family","",At),fontSize:n.extend("--ft-typography-caption-font-size","",$.fontSize,"12px"),fontWeight:n.extend("--ft-typography-caption-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-caption-letter-spacing","",$.letterSpacing,"0.396px"),lineHeight:n.extend("--ft-typography-caption-line-height","",$.lineHeight,"1.33"),textTransform:n.extend("--ft-typography-caption-text-transform","",$.textTransform,"inherit")},oo={fontFamily:n.extend("--ft-typography-breadcrumb-font-family","",At),fontSize:n.extend("--ft-typography-breadcrumb-font-size","",$.fontSize,"10px"),fontWeight:n.extend("--ft-typography-breadcrumb-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-breadcrumb-letter-spacing","",$.letterSpacing,"0.33px"),lineHeight:n.extend("--ft-typography-breadcrumb-line-height","",$.lineHeight,"1.6"),textTransform:n.extend("--ft-typography-breadcrumb-text-transform","",$.textTransform,"inherit")},no={fontFamily:n.extend("--ft-typography-overline-font-family","",At),fontSize:n.extend("--ft-typography-overline-font-size","",$.fontSize,"10px"),fontWeight:n.extend("--ft-typography-overline-font-weight","",$.fontWeight,"normal"),letterSpacing:n.extend("--ft-typography-overline-letter-spacing","",$.letterSpacing,"1.5px"),lineHeight:n.extend("--ft-typography-overline-line-height","",$.lineHeight,"1.6"),textTransform:n.extend("--ft-typography-overline-text-transform","",$.textTransform,"uppercase")},ut={fontFamily:n.extend("--ft-typography-button-font-family","",At),fontSize:n.extend("--ft-typography-button-font-size","",$.fontSize,"14px"),fontWeight:n.extend("--ft-typography-button-font-weight","",$.fontWeight,"600"),letterSpacing:n.extend("--ft-typography-button-letter-spacing","",$.letterSpacing,"1.246px"),lineHeight:n.extend("--ft-typography-button-line-height","",$.lineHeight,"1.15"),textTransform:n.extend("--ft-typography-button-text-transform","",$.textTransform,"uppercase")},E2=z`
86
86
  .ft-typography--title {
87
87
  font-family: ${qr.fontFamily};
88
88
  font-size: ${qr.fontSize};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluid-topics/ft-reader-toc",
3
- "version": "2.0.28",
3
+ "version": "2.0.29",
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": "2.0.28",
23
- "@fluid-topics/ft-reader-context": "2.0.28",
24
- "@fluid-topics/ft-size-watcher": "2.0.28",
25
- "@fluid-topics/ft-typography": "2.0.28",
26
- "@fluid-topics/ft-wc-utils": "2.0.28",
22
+ "@fluid-topics/ft-icon": "2.0.29",
23
+ "@fluid-topics/ft-reader-context": "2.0.29",
24
+ "@fluid-topics/ft-size-watcher": "2.0.29",
25
+ "@fluid-topics/ft-typography": "2.0.29",
26
+ "@fluid-topics/ft-wc-utils": "2.0.29",
27
27
  "lit": "3.1.0"
28
28
  },
29
- "gitHead": "c81a78f103c19425eb2eac2675a6dd8396e2aa4e"
29
+ "gitHead": "7c6a7af32908ebb8496d98416d21cd37097b991f"
30
30
  }