@fluid-topics/ft-reader-context 1.0.60 → 1.0.62

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.
@@ -1,12 +1,12 @@
1
- !function(t,i,e,s){class n{constructor(t){this.paginatedToc=t,this.nodeByTocId={},this.knownPrettyUrls=new Set,this.duplicatedPrettyUrls=new Set,this.pages=[],this.pageByTocId={}}build(){return{paginationConfiguration:this.paginatedToc.configuration,toc:this.convertNodes(this.paginatedToc.paginatedToc,1),pagesToc:this.extractPagesToc(this.paginatedToc.paginatedToc,1),nodeByTocId:this.nodeByTocId,duplicatedPrettyUrls:this.duplicatedPrettyUrls,pages:this.pages,pageByTocId:this.pageByTocId}}extractPagesToc(t,i,e){return t.flatMap((t=>(t.pageConfiguration&&this.registerPage(this.buildPage(t,e)),null==t.tocId?this.extractPagesToc(t.children,i,e):[{tocId:t.tocId,title:t.title,depth:i,children:this.extractPagesToc(t.children,i+1,t.tocId)}])))}convertNodes(t,i,e){return t.flatMap((t=>{var s,n,r;if(null==t.tocId)return[...this.convertSectionNodes(null!==(s=t.pageToc)&&void 0!==s?s:[],i,t.tocId),...this.convertNodes(t.children,i,t.tocId)];let o=null===(n=t.prettyUrl)||void 0===n?void 0:n.replace(/^\//,"");const a={tocId:t.tocId,contentId:t.contentId,title:t.title,hasRating:t.hasRating,origin:t.origin,prettyUrl:o,depth:i,parentTocId:e,children:[]};this.register(a);const h=this.convertSectionNodes(null!==(r=t.pageToc)&&void 0!==r?r:[],i+1,t.tocId),u=this.convertNodes(t.children,i+1,a.tocId);return a.children=[...h,...u],[a]}))}convertSectionNodes(t,i,e){return t.flatMap((t=>{var s;let n=null===(s=t.prettyUrl)||void 0===s?void 0:s.replace(/^\//,"");const r={...t,prettyUrl:n,depth:i,parentTocId:e,children:[]};return this.register(r),r.children=this.convertSectionNodes(t.children,i+1,t.tocId),[r]}))}buildPage(t,i){var e,s,n,r,o,a;const h={number:this.pages.length+1,title:null!==(e=t.title)&&void 0!==e?e:"",rootTocId:null!==(s=t.tocId)&&void 0!==s?s:"root",toc:(null!==(n=t.pageToc)&&void 0!==n?n:[]).map((t=>this.nodeByTocId[t.tocId])),topics:[],hiddenTopics:[],breadcrumb:i?this.buildBreadcrumb(this.nodeByTocId[i]):[]},u=(t,i)=>(i?h.topics:h.hiddenTopics).push(t),c=null!==(o=null===(r=t.pageConfiguration)||void 0===r?void 0:r.parentsVisibility)&&void 0!==o?o:[];return h.breadcrumb.forEach(((t,i)=>{u(t,c[i])})),t.tocId&&u(t.tocId,t.pageConfiguration.isVisible),h.topics.push(...this.tocIds(null!==(a=t.pageToc)&&void 0!==a?a:[])),h}registerPage(t){for(let i of[...t.topics,...t.hiddenTopics])this.pageByTocId[i]||(this.pageByTocId[i]=t);this.pages.push(t)}tocIds(t){return t.flatMap((t=>[t.tocId,...this.tocIds(t.children)]))}buildBreadcrumb(t){const i=[t.tocId];for(;null==t?void 0:t.parentTocId;)i.unshift(t.parentTocId),t=this.nodeByTocId[t.parentTocId];return i}register(t){t.prettyUrl&&(this.knownPrettyUrls.has(t.prettyUrl)&&this.duplicatedPrettyUrls.add(t.prettyUrl),this.knownPrettyUrls.add(t.prettyUrl)),this.nodeByTocId[t.tocId]=t}}class r{convertPaginatedToc(t){return new n(t).build()}}!function(t){!function(i){var e={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch(t){return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};if(e.arrayBuffer)var s=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],n=ArrayBuffer.isView||function(t){return t&&s.indexOf(Object.prototype.toString.call(t))>-1};function r(t){if("string"!=typeof t&&(t=String(t)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(t))throw new TypeError("Invalid character in header field name");return t.toLowerCase()}function o(t){return"string"!=typeof t&&(t=String(t)),t}function a(t){var i={next:function(){var i=t.shift();return{done:void 0===i,value:i}}};return e.iterable&&(i[Symbol.iterator]=function(){return i}),i}function h(t){this.map={},t instanceof h?t.forEach((function(t,i){this.append(i,t)}),this):Array.isArray(t)?t.forEach((function(t){this.append(t[0],t[1])}),this):t&&Object.getOwnPropertyNames(t).forEach((function(i){this.append(i,t[i])}),this)}function u(t){if(t.bodyUsed)return Promise.reject(new TypeError("Already read"));t.bodyUsed=!0}function c(t){return new Promise((function(i,e){t.onload=function(){i(t.result)},t.onerror=function(){e(t.error)}}))}function l(t){var i=new FileReader,e=c(i);return i.readAsArrayBuffer(t),e}function d(t){if(t.slice)return t.slice(0);var i=new Uint8Array(t.byteLength);return i.set(new Uint8Array(t)),i.buffer}function v(){return this.bodyUsed=!1,this._initBody=function(t){var i;this._bodyInit=t,t?"string"==typeof t?this._bodyText=t:e.blob&&Blob.prototype.isPrototypeOf(t)?this._bodyBlob=t:e.formData&&FormData.prototype.isPrototypeOf(t)?this._bodyFormData=t:e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)?this._bodyText=t.toString():e.arrayBuffer&&e.blob&&((i=t)&&DataView.prototype.isPrototypeOf(i))?(this._bodyArrayBuffer=d(t.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):e.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(t)||n(t))?this._bodyArrayBuffer=d(t):this._bodyText=t=Object.prototype.toString.call(t):this._bodyText="",this.headers.get("content-type")||("string"==typeof t?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},e.blob&&(this.blob=function(){var t=u(this);if(t)return t;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?u(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(l)}),this.text=function(){var t,i,e,s=u(this);if(s)return s;if(this._bodyBlob)return t=this._bodyBlob,i=new FileReader,e=c(i),i.readAsText(t),e;if(this._bodyArrayBuffer)return Promise.resolve(function(t){for(var i=new Uint8Array(t),e=new Array(i.length),s=0;s<i.length;s++)e[s]=String.fromCharCode(i[s]);return e.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},e.formData&&(this.formData=function(){return this.text().then(w)}),this.json=function(){return this.text().then(JSON.parse)},this}h.prototype.append=function(t,i){t=r(t),i=o(i);var e=this.map[t];this.map[t]=e?e+", "+i:i},h.prototype.delete=function(t){delete this.map[r(t)]},h.prototype.get=function(t){return t=r(t),this.has(t)?this.map[t]:null},h.prototype.has=function(t){return this.map.hasOwnProperty(r(t))},h.prototype.set=function(t,i){this.map[r(t)]=o(i)},h.prototype.forEach=function(t,i){for(var e in this.map)this.map.hasOwnProperty(e)&&t.call(i,this.map[e],e,this)},h.prototype.keys=function(){var t=[];return this.forEach((function(i,e){t.push(e)})),a(t)},h.prototype.values=function(){var t=[];return this.forEach((function(i){t.push(i)})),a(t)},h.prototype.entries=function(){var t=[];return this.forEach((function(i,e){t.push([e,i])})),a(t)},e.iterable&&(h.prototype[Symbol.iterator]=h.prototype.entries);var f=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function p(t,i){var e,s,n=(i=i||{}).body;if(t instanceof p){if(t.bodyUsed)throw new TypeError("Already read");this.url=t.url,this.credentials=t.credentials,i.headers||(this.headers=new h(t.headers)),this.method=t.method,this.mode=t.mode,this.signal=t.signal,n||null==t._bodyInit||(n=t._bodyInit,t.bodyUsed=!0)}else this.url=String(t);if(this.credentials=i.credentials||this.credentials||"same-origin",!i.headers&&this.headers||(this.headers=new h(i.headers)),this.method=(e=i.method||this.method||"GET",s=e.toUpperCase(),f.indexOf(s)>-1?s:e),this.mode=i.mode||this.mode||null,this.signal=i.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&n)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(n)}function w(t){var i=new FormData;return t.trim().split("&").forEach((function(t){if(t){var e=t.split("="),s=e.shift().replace(/\+/g," "),n=e.join("=").replace(/\+/g," ");i.append(decodeURIComponent(s),decodeURIComponent(n))}})),i}function E(t,i){i||(i={}),this.type="default",this.status=void 0===i.status?200:i.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in i?i.statusText:"OK",this.headers=new h(i.headers),this.url=i.url||"",this._initBody(t)}p.prototype.clone=function(){return new p(this,{body:this._bodyInit})},v.call(p.prototype),v.call(E.prototype),E.prototype.clone=function(){return new E(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new h(this.headers),url:this.url})},E.error=function(){var t=new E(null,{status:0,statusText:""});return t.type="error",t};var y=[301,302,303,307,308];E.redirect=function(t,i){if(-1===y.indexOf(i))throw new RangeError("Invalid status code");return new E(null,{status:i,headers:{location:t}})},i.DOMException=t.DOMException;try{new i.DOMException}catch(t){i.DOMException=function(t,i){this.message=t,this.name=i;var e=Error(t);this.stack=e.stack},i.DOMException.prototype=Object.create(Error.prototype),i.DOMException.prototype.constructor=i.DOMException}function T(t,s){return new Promise((function(n,r){var o=new p(t,s);if(o.signal&&o.signal.aborted)return r(new i.DOMException("Aborted","AbortError"));var a=new XMLHttpRequest;function u(){a.abort()}a.onload=function(){var t,i,e={status:a.status,statusText:a.statusText,headers:(t=a.getAllResponseHeaders()||"",i=new h,t.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(t){var e=t.split(":"),s=e.shift().trim();if(s){var n=e.join(":").trim();i.append(s,n)}})),i)};e.url="responseURL"in a?a.responseURL:e.headers.get("X-Request-URL");var s="response"in a?a.response:a.responseText;n(new E(s,e))},a.onerror=function(){r(new TypeError("Network request failed"))},a.ontimeout=function(){r(new TypeError("Network request failed"))},a.onabort=function(){r(new i.DOMException("Aborted","AbortError"))},a.open(o.method,o.url,!0),"include"===o.credentials?a.withCredentials=!0:"omit"===o.credentials&&(a.withCredentials=!1),"responseType"in a&&e.blob&&(a.responseType="blob"),o.headers.forEach((function(t,i){a.setRequestHeader(i,t)})),o.signal&&(o.signal.addEventListener("abort",u),a.onreadystatechange=function(){4===a.readyState&&o.signal.removeEventListener("abort",u)}),a.send(void 0===o._bodyInit?null:o._bodyInit)}))}T.polyfill=!0,t.fetch||(t.fetch=T,t.Headers=h,t.Request=p,t.Response=E),i.Headers=h,i.Request=p,i.Response=E,i.fetch=T,Object.defineProperty(i,"t",{value:!0})}({})}("undefined"!=typeof self?self:void 0);const o=t=>"object"==typeof t&&null!=t,a=t=>"string"==typeof t;var h,u,c,l,d,v,f,p,w,E,y,T;!function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"}(h||(h={})),function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"}(u||(u={})),function(t){t.THIRD_PARTY="THIRD_PARTY",t.OFF_THE_GRID="OFF_THE_GRID",t.CONTENT_PACKAGER="CONTENT_PACKAGER",t.PAGES="PAGES",t.DESIGNED_READER="DESIGNED_READER"}(c||(c={})),function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"}(l||(l={})),function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"}(d||(d={})),function(t){t.ASC="ASC",t.DESC="DESC"}(v||(v={})),function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"}(f||(f={})),function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK"}(p||(p={})),function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"}(w||(w={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK"}(E||(E={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC"}(y||(y={})),function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN",t.DEVELOPER="DEVELOPER"}(T||(T={}));const m=t=>o(t)&&(null==t.authenticationIdentifier||(t=>o(t)&&a(t.identifier)&&a(t.realm))(t.authenticationIdentifier))&&(t=>"number"==typeof t)(t.idleTimeoutInMillis)&&g(t.profile)&&(t=>"boolean"==typeof t)(t.sessionAuthenticated),g=t=>o(t)&&(null==t.emailAddress||a(t.emailAddress))&&(null==t.displayName||a(t.displayName))&&Array.isArray(t.roles)&&t.roles.every((t=>(t=>["PERSONAL_BOOK_USER","PERSONAL_BOOK_SHARE_USER","HTML_EXPORT_USER","PDF_EXPORT_USER","SAVED_SEARCH_USER","COLLECTION_USER","OFFLINE_USER","ANALYTICS_USER","BETA_USER","DEBUG_USER","PRINT_USER","RATING_USER","FEEDBACK_USER","CONTENT_PUBLISHER","KHUB_ADMIN","USERS_ADMIN","PORTAL_ADMIN","ADMIN","DEVELOPER"].includes(t))(t)))&&(null==t.userId||a(t.userId)),R={[T.PERSONAL_BOOK_SHARE_USER]:[T.PERSONAL_BOOK_USER],[T.HTML_EXPORT_USER]:[T.PERSONAL_BOOK_USER],[T.PDF_EXPORT_USER]:[T.PERSONAL_BOOK_USER],[T.KHUB_ADMIN]:[T.CONTENT_PUBLISHER],[T.ADMIN]:[T.KHUB_ADMIN,T.USERS_ADMIN,T.PORTAL_ADMIN],[T.DEVELOPER]:[T.BETA_USER,T.DEBUG_USER]};function S(t,i){return t===i||(R[t]??[]).some((t=>S(t,i)))}function b(t,i){return(m(t)?t.profile.roles:g(t)?t.roles:t).some((t=>S(t,i)))}var A;t.FtReaderFeatures=void 0,(A=t.FtReaderFeatures||(t.FtReaderFeatures={})).FEEDBACK="FEEDBACK",A.RATING="RATING",A.PRINT="PRINT",A.BOOKMARK="BOOKMARK",A.COLLECTIONS="COLLECTIONS";const I=e.css`
2
- `,U=i.FtReduxStore.get({name:"ft-app-info",reducers:{setBaseUrl:(t,i)=>{t.baseUrl=i.payload},setApiIntegrationIdentifier:(t,i)=>{t.apiIntegrationIdentifier=i.payload},setUiLocale:(t,i)=>{t.uiLocale=i.payload},setAvailableUiLocales:(t,i)=>{t.availableUiLocales=i.payload},setEditorMode:(t,i)=>{t.editorMode=i.payload},setNoCustom:(t,i)=>{t.noCustom=i.payload},setNoCustomComponent:(t,i)=>{t.noCustomComponent=i.payload},setSession:(t,i)=>{t.session=i.payload}},initialState:{uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],editorMode:!1,noCustom:!1,noCustomComponent:!1}});class O{static build(t){const{baseUrl:i,apiIntegrationIdentifier:e}=U.getState(),s=null!=t?t:e;if(i&&s&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(i,s,!0)}static get(t){var i;return null!=t?O.build(t):null!==(i=O.API)&&void 0!==i?i:O.API=O.build()}static await(t){return new Promise((i=>{let e=O.get(t);if(e)i(e);else{const s=U.subscribe((()=>{e=O.get(t),e&&(s(),i(e))}))}}))}}var P;const C=Symbol("clearAfterUnitTest");class N{constructor(t){this.messageContextProvider=t,this.defaultMessages={},this.cache=new i.CacheRegistry,this.listeners={},this.currentUiLocale="",this[P]=()=>{this.defaultMessages={},this.cache=new i.CacheRegistry,this.listeners={}},this.currentUiLocale=U.getState().uiLocale,U.subscribe((()=>this.clearWhenUiLocaleChanges()))}clearWhenUiLocaleChanges(){const{uiLocale:t}=U.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){const i=t.name.toLowerCase();this.cache.setFinal(i,t),this.notify(i)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,e){var s;if(t=t.toLowerCase(),Object.keys(e).length>0){const n={...null!==(s=this.defaultMessages[t])&&void 0!==s?s:{},...e};i.deepEqual(this.defaultMessages[t],n)||(this.defaultMessages[t]=n,await this.notify(t))}await this.fetchContext(t)}resolveMessage(t,e,...s){var n,r,o;t=t.toLowerCase(),this.fetchContext(t);const a=null!==(r=null===(n=this.cache.getNow(t))||void 0===n?void 0:n.messages)&&void 0!==r?r:{};return new i.ParametrizedLabelResolver(null!==(o=this.defaultMessages[t])&&void 0!==o?o:{},a).resolve(e,...s)}async fetchContext(t){if(!this.cache.has(t))try{await this.cache.get(t,(()=>this.messageContextProvider(this.currentUiLocale,t))),await this.notify(t)}catch(t){console.error(t)}}subscribe(t,i){var e;return t=t.toLowerCase(),this.listeners[t]=null!==(e=this.listeners[t])&&void 0!==e?e:new Set,this.listeners[t].add(i),()=>{var e;return null===(e=this.listeners[t])||void 0===e?void 0:e.delete(i)}}async notifyAll(){await Promise.all(Object.keys(this.listeners).map((t=>this.notify(t))))}async notify(t){null!=this.listeners[t]&&await Promise.all([...this.listeners[t].values()].map((t=>i.delay(0).then((()=>t())).catch((()=>null)))))}}P=C,null==window.FluidTopicsI18nService&&(window.FluidTopicsI18nService=new N((async(t,i)=>(await O.await()).getFluidTopicsMessageContext(t,i)))),null==window.FluidTopicsCustomI18nService&&(window.FluidTopicsCustomI18nService=new N((async(t,i)=>(await O.await()).getCustomMessageContext(t,i))));const _=window.FluidTopicsI18nService;var L=function(t,i,e,s){for(var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s,a=t.length-1;a>=0;a--)(n=t[a])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};class D extends i.FtLitElement{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.availableUiLocales=[],this.editorMode=!1,this.noCustom=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.messageContexts=[],this.apiProvider=()=>O.get(),this.cache=new i.CacheRegistry,this.cleanSessionDebouncer=new i.Debouncer}render(){return e.html`
1
+ !function(t,i,e,s){class n{constructor(t){this.paginatedToc=t,this.nodeByTocId={},this.knownPrettyUrls=new Set,this.duplicatedPrettyUrls=new Set,this.pages=[],this.pageByTocId={}}build(){return{paginationConfiguration:this.paginatedToc.configuration,toc:this.convertNodes(this.paginatedToc.paginatedToc,1),pagesToc:this.extractPagesToc(this.paginatedToc.paginatedToc,1),nodeByTocId:this.nodeByTocId,duplicatedPrettyUrls:this.duplicatedPrettyUrls,pages:this.pages,pageByTocId:this.pageByTocId}}extractPagesToc(t,i,e){return t.flatMap((t=>(t.pageConfiguration&&this.registerPage(this.buildPage(t,e)),null==t.tocId?this.extractPagesToc(t.children,i,e):[{tocId:t.tocId,title:t.title,depth:i,children:this.extractPagesToc(t.children,i+1,t.tocId)}])))}convertNodes(t,i,e){return t.flatMap((t=>{var s,n,r;if(null==t.tocId)return[...this.convertSectionNodes(null!==(s=t.pageToc)&&void 0!==s?s:[],i,t.tocId),...this.convertNodes(t.children,i,t.tocId)];let o=null===(n=t.prettyUrl)||void 0===n?void 0:n.replace(/^\//,"");const a={tocId:t.tocId,contentId:t.contentId,title:t.title,hasRating:t.hasRating,origin:t.origin,prettyUrl:o,depth:i,parentTocId:e,children:[]};this.register(a);const h=this.convertSectionNodes(null!==(r=t.pageToc)&&void 0!==r?r:[],i+1,t.tocId),u=this.convertNodes(t.children,i+1,a.tocId);return a.children=[...h,...u],[a]}))}convertSectionNodes(t,i,e){return t.flatMap((t=>{var s;let n=null===(s=t.prettyUrl)||void 0===s?void 0:s.replace(/^\//,"");const r={...t,prettyUrl:n,depth:i,parentTocId:e,children:[]};return this.register(r),r.children=this.convertSectionNodes(t.children,i+1,t.tocId),[r]}))}buildPage(t,i){var e,s,n,r,o,a;const h={number:this.pages.length+1,title:null!==(e=t.title)&&void 0!==e?e:"",rootTocId:null!==(s=t.tocId)&&void 0!==s?s:"root",toc:(null!==(n=t.pageToc)&&void 0!==n?n:[]).map((t=>this.nodeByTocId[t.tocId])),topics:[],hiddenTopics:[],breadcrumb:i?this.buildBreadcrumb(this.nodeByTocId[i]):[]},u=(t,i)=>(i?h.topics:h.hiddenTopics).push(t),c=null!==(o=null===(r=t.pageConfiguration)||void 0===r?void 0:r.parentsVisibility)&&void 0!==o?o:[];return h.breadcrumb.forEach(((t,i)=>{u(t,c[i])})),t.tocId&&u(t.tocId,t.pageConfiguration.isVisible),h.topics.push(...this.tocIds(null!==(a=t.pageToc)&&void 0!==a?a:[])),h}registerPage(t){for(let i of[...t.topics,...t.hiddenTopics])this.pageByTocId[i]||(this.pageByTocId[i]=t);this.pages.push(t)}tocIds(t){return t.flatMap((t=>[t.tocId,...this.tocIds(t.children)]))}buildBreadcrumb(t){const i=[t.tocId];for(;null==t?void 0:t.parentTocId;)i.unshift(t.parentTocId),t=this.nodeByTocId[t.parentTocId];return i}register(t){t.prettyUrl&&(this.knownPrettyUrls.has(t.prettyUrl)&&this.duplicatedPrettyUrls.add(t.prettyUrl),this.knownPrettyUrls.add(t.prettyUrl)),this.nodeByTocId[t.tocId]=t}}class r{convertPaginatedToc(t){return new n(t).build()}}var o,a,h,u,c,l,d,v,f,p,w,y,m,T;!function(t){!function(i){var e={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch(t){return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};if(e.arrayBuffer)var s=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],n=ArrayBuffer.isView||function(t){return t&&s.indexOf(Object.prototype.toString.call(t))>-1};function r(t){if("string"!=typeof t&&(t=String(t)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(t))throw new TypeError("Invalid character in header field name");return t.toLowerCase()}function o(t){return"string"!=typeof t&&(t=String(t)),t}function a(t){var i={next:function(){var i=t.shift();return{done:void 0===i,value:i}}};return e.iterable&&(i[Symbol.iterator]=function(){return i}),i}function h(t){this.map={},t instanceof h?t.forEach((function(t,i){this.append(i,t)}),this):Array.isArray(t)?t.forEach((function(t){this.append(t[0],t[1])}),this):t&&Object.getOwnPropertyNames(t).forEach((function(i){this.append(i,t[i])}),this)}function u(t){if(t.bodyUsed)return Promise.reject(new TypeError("Already read"));t.bodyUsed=!0}function c(t){return new Promise((function(i,e){t.onload=function(){i(t.result)},t.onerror=function(){e(t.error)}}))}function l(t){var i=new FileReader,e=c(i);return i.readAsArrayBuffer(t),e}function d(t){if(t.slice)return t.slice(0);var i=new Uint8Array(t.byteLength);return i.set(new Uint8Array(t)),i.buffer}function v(){return this.bodyUsed=!1,this._initBody=function(t){var i;this._bodyInit=t,t?"string"==typeof t?this._bodyText=t:e.blob&&Blob.prototype.isPrototypeOf(t)?this._bodyBlob=t:e.formData&&FormData.prototype.isPrototypeOf(t)?this._bodyFormData=t:e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)?this._bodyText=t.toString():e.arrayBuffer&&e.blob&&((i=t)&&DataView.prototype.isPrototypeOf(i))?(this._bodyArrayBuffer=d(t.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):e.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(t)||n(t))?this._bodyArrayBuffer=d(t):this._bodyText=t=Object.prototype.toString.call(t):this._bodyText="",this.headers.get("content-type")||("string"==typeof t?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},e.blob&&(this.blob=function(){var t=u(this);if(t)return t;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?u(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(l)}),this.text=function(){var t,i,e,s=u(this);if(s)return s;if(this._bodyBlob)return t=this._bodyBlob,i=new FileReader,e=c(i),i.readAsText(t),e;if(this._bodyArrayBuffer)return Promise.resolve(function(t){for(var i=new Uint8Array(t),e=new Array(i.length),s=0;s<i.length;s++)e[s]=String.fromCharCode(i[s]);return e.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},e.formData&&(this.formData=function(){return this.text().then(w)}),this.json=function(){return this.text().then(JSON.parse)},this}h.prototype.append=function(t,i){t=r(t),i=o(i);var e=this.map[t];this.map[t]=e?e+", "+i:i},h.prototype.delete=function(t){delete this.map[r(t)]},h.prototype.get=function(t){return t=r(t),this.has(t)?this.map[t]:null},h.prototype.has=function(t){return this.map.hasOwnProperty(r(t))},h.prototype.set=function(t,i){this.map[r(t)]=o(i)},h.prototype.forEach=function(t,i){for(var e in this.map)this.map.hasOwnProperty(e)&&t.call(i,this.map[e],e,this)},h.prototype.keys=function(){var t=[];return this.forEach((function(i,e){t.push(e)})),a(t)},h.prototype.values=function(){var t=[];return this.forEach((function(i){t.push(i)})),a(t)},h.prototype.entries=function(){var t=[];return this.forEach((function(i,e){t.push([e,i])})),a(t)},e.iterable&&(h.prototype[Symbol.iterator]=h.prototype.entries);var f=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function p(t,i){var e,s,n=(i=i||{}).body;if(t instanceof p){if(t.bodyUsed)throw new TypeError("Already read");this.url=t.url,this.credentials=t.credentials,i.headers||(this.headers=new h(t.headers)),this.method=t.method,this.mode=t.mode,this.signal=t.signal,n||null==t._bodyInit||(n=t._bodyInit,t.bodyUsed=!0)}else this.url=String(t);if(this.credentials=i.credentials||this.credentials||"same-origin",!i.headers&&this.headers||(this.headers=new h(i.headers)),this.method=(e=i.method||this.method||"GET",s=e.toUpperCase(),f.indexOf(s)>-1?s:e),this.mode=i.mode||this.mode||null,this.signal=i.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&n)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(n)}function w(t){var i=new FormData;return t.trim().split("&").forEach((function(t){if(t){var e=t.split("="),s=e.shift().replace(/\+/g," "),n=e.join("=").replace(/\+/g," ");i.append(decodeURIComponent(s),decodeURIComponent(n))}})),i}function y(t,i){i||(i={}),this.type="default",this.status=void 0===i.status?200:i.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in i?i.statusText:"OK",this.headers=new h(i.headers),this.url=i.url||"",this._initBody(t)}p.prototype.clone=function(){return new p(this,{body:this._bodyInit})},v.call(p.prototype),v.call(y.prototype),y.prototype.clone=function(){return new y(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new h(this.headers),url:this.url})},y.error=function(){var t=new y(null,{status:0,statusText:""});return t.type="error",t};var m=[301,302,303,307,308];y.redirect=function(t,i){if(-1===m.indexOf(i))throw new RangeError("Invalid status code");return new y(null,{status:i,headers:{location:t}})},i.DOMException=t.DOMException;try{new i.DOMException}catch(t){i.DOMException=function(t,i){this.message=t,this.name=i;var e=Error(t);this.stack=e.stack},i.DOMException.prototype=Object.create(Error.prototype),i.DOMException.prototype.constructor=i.DOMException}function T(t,s){return new Promise((function(n,r){var o=new p(t,s);if(o.signal&&o.signal.aborted)return r(new i.DOMException("Aborted","AbortError"));var a=new XMLHttpRequest;function u(){a.abort()}a.onload=function(){var t,i,e={status:a.status,statusText:a.statusText,headers:(t=a.getAllResponseHeaders()||"",i=new h,t.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(t){var e=t.split(":"),s=e.shift().trim();if(s){var n=e.join(":").trim();i.append(s,n)}})),i)};e.url="responseURL"in a?a.responseURL:e.headers.get("X-Request-URL");var s="response"in a?a.response:a.responseText;n(new y(s,e))},a.onerror=function(){r(new TypeError("Network request failed"))},a.ontimeout=function(){r(new TypeError("Network request failed"))},a.onabort=function(){r(new i.DOMException("Aborted","AbortError"))},a.open(o.method,o.url,!0),"include"===o.credentials?a.withCredentials=!0:"omit"===o.credentials&&(a.withCredentials=!1),"responseType"in a&&e.blob&&(a.responseType="blob"),o.headers.forEach((function(t,i){a.setRequestHeader(i,t)})),o.signal&&(o.signal.addEventListener("abort",u),a.onreadystatechange=function(){4===a.readyState&&o.signal.removeEventListener("abort",u)}),a.send(void 0===o._bodyInit?null:o._bodyInit)}))}T.polyfill=!0,t.fetch||(t.fetch=T,t.Headers=h,t.Request=p,t.Response=y),i.Headers=h,i.Request=p,i.Response=y,i.fetch=T,Object.defineProperty(i,"t",{value:!0})}({})}("undefined"!=typeof self?self:void 0),function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"}(o||(o={})),function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"}(a||(a={})),function(t){t.THIRD_PARTY="THIRD_PARTY",t.OFF_THE_GRID="OFF_THE_GRID",t.CONTENT_PACKAGER="CONTENT_PACKAGER",t.PAGES="PAGES",t.DESIGNED_READER="DESIGNED_READER"}(h||(h={})),function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"}(u||(u={})),function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"}(c||(c={})),function(t){t.ASC="ASC",t.DESC="DESC"}(l||(l={})),function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"}(d||(d={})),function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"}(v||(v={})),function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK"}(f||(f={})),function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"}(p||(p={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK"}(w||(w={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC"}(y||(y={})),function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS"}(m||(m={})),function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN",t.DEVELOPER="DEVELOPER"}(T||(T={}));const g={[T.PERSONAL_BOOK_SHARE_USER]:[T.PERSONAL_BOOK_USER],[T.HTML_EXPORT_USER]:[T.PERSONAL_BOOK_USER],[T.PDF_EXPORT_USER]:[T.PERSONAL_BOOK_USER],[T.KHUB_ADMIN]:[T.CONTENT_PUBLISHER],[T.ADMIN]:[T.KHUB_ADMIN,T.USERS_ADMIN,T.PORTAL_ADMIN],[T.DEVELOPER]:[T.BETA_USER,T.DEBUG_USER]};function E(t,i){return t===i||(g[t]??[]).some((t=>E(t,i)))}function b(t,i){if(null==t)return!1;return(Array.isArray(t)?t:Array.isArray(t.roles)?t.roles:Array.isArray(t.profile?.roles)?t.profile.roles:[]).some((t=>E(t,i)))}var A;t.FtReaderFeatures=void 0,(A=t.FtReaderFeatures||(t.FtReaderFeatures={})).FEEDBACK="FEEDBACK",A.RATING="RATING",A.PRINT="PRINT",A.BOOKMARK="BOOKMARK",A.COLLECTIONS="COLLECTIONS";const S=e.css`
2
+ `,R=i.FtReduxStore.get({name:"ft-app-info",reducers:{setBaseUrl:(t,i)=>{t.baseUrl=i.payload},setApiIntegrationIdentifier:(t,i)=>{t.apiIntegrationIdentifier=i.payload},setUiLocale:(t,i)=>{t.uiLocale=i.payload},setAvailableUiLocales:(t,i)=>{t.availableUiLocales=i.payload},setEditorMode:(t,i)=>{t.editorMode=i.payload},setNoCustom:(t,i)=>{t.noCustom=i.payload},setNoCustomComponent:(t,i)=>{t.noCustomComponent=i.payload},setSession:(t,i)=>{t.session=i.payload}},initialState:{uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],editorMode:!1,noCustom:!1,noCustomComponent:!1}});class I{static build(t){const{baseUrl:i,apiIntegrationIdentifier:e}=R.getState(),s=null!=t?t:e;if(i&&s&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(i,s,!0)}static get(t){var i;return null!=t?I.build(t):null!==(i=I.API)&&void 0!==i?i:I.API=I.build()}static await(t){return new Promise((i=>{let e=I.get(t);if(e)i(e);else{const s=R.subscribe((()=>{e=I.get(t),e&&(s(),i(e))}))}}))}}var U;const C=Symbol("clearAfterUnitTest");class O{constructor(t){this.messageContextProvider=t,this.defaultMessages={},this.cache=new i.CacheRegistry,this.listeners={},this.currentUiLocale="",this[U]=()=>{this.defaultMessages={},this.cache=new i.CacheRegistry,this.listeners={}},this.currentUiLocale=R.getState().uiLocale,R.subscribe((()=>this.clearWhenUiLocaleChanges()))}clearWhenUiLocaleChanges(){const{uiLocale:t}=R.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){const i=t.name.toLowerCase();this.cache.setFinal(i,t),this.notify(i)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,e){var s;if(t=t.toLowerCase(),Object.keys(e).length>0){const n={...null!==(s=this.defaultMessages[t])&&void 0!==s?s:{},...e};i.deepEqual(this.defaultMessages[t],n)||(this.defaultMessages[t]=n,await this.notify(t))}await this.fetchContext(t)}resolveMessage(t,e,...s){var n,r,o;t=t.toLowerCase(),this.fetchContext(t);const a=null!==(r=null===(n=this.cache.getNow(t))||void 0===n?void 0:n.messages)&&void 0!==r?r:{};return new i.ParametrizedLabelResolver(null!==(o=this.defaultMessages[t])&&void 0!==o?o:{},a).resolve(e,...s)}async fetchContext(t){if(!this.cache.has(t))try{await this.cache.get(t,(()=>this.messageContextProvider(this.currentUiLocale,t))),await this.notify(t)}catch(t){console.error(t)}}subscribe(t,i){var e;return t=t.toLowerCase(),this.listeners[t]=null!==(e=this.listeners[t])&&void 0!==e?e:new Set,this.listeners[t].add(i),()=>{var e;return null===(e=this.listeners[t])||void 0===e?void 0:e.delete(i)}}async notifyAll(){await Promise.all(Object.keys(this.listeners).map((t=>this.notify(t))))}async notify(t){null!=this.listeners[t]&&await Promise.all([...this.listeners[t].values()].map((t=>i.delay(0).then((()=>t())).catch((()=>null)))))}}U=C,null==window.FluidTopicsI18nService&&(window.FluidTopicsI18nService=new O((async(t,i)=>(await I.await()).getFluidTopicsMessageContext(t,i)))),null==window.FluidTopicsCustomI18nService&&(window.FluidTopicsCustomI18nService=new O((async(t,i)=>(await I.await()).getCustomMessageContext(t,i))));const P=window.FluidTopicsI18nService;var N=function(t,i,e,s){for(var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s,a=t.length-1;a>=0;a--)(n=t[a])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};class L extends i.FtLitElement{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.availableUiLocales=[],this.editorMode=!1,this.noCustom=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.messageContexts=[],this.apiProvider=()=>I.get(),this.cache=new i.CacheRegistry,this.cleanSessionDebouncer=new i.Debouncer}render(){return e.html`
3
3
  <slot></slot>
4
- `}update(t){super.update(t),t.has("baseUrl")&&U.actions.setBaseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&U.actions.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&U.actions.setUiLocale(this.uiLocale),t.has("noCustom")&&U.actions.setNoCustom(this.noCustom),t.has("editorMode")&&U.actions.setEditorMode(this.editorMode),t.has("noCustomComponent")&&U.actions.setNoCustomComponent(this.noCustomComponent),t.has("session")&&U.actions.setSession(this.session),t.has("availableUiLocales")&&U.actions.setAvailableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>_.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){const t=this.apiProvider();!this.withManualResources&&t&&(null==this.session&&(this.session=await this.cache.get("session",(async()=>{const i=await t.getCurrentSession();return i.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),i.idleTimeoutInMillis),i}))),null==this.availableUiLocales&&(this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>t.getAvailableUiLocales()))))}}D.elementDefinitions={},D.styles=I,L([s.property()],D.prototype,"baseUrl",void 0),L([s.property()],D.prototype,"apiIntegrationIdentifier",void 0),L([s.property()],D.prototype,"uiLocale",void 0),L([i.jsonProperty([])],D.prototype,"availableUiLocales",void 0),L([s.property({type:Boolean})],D.prototype,"editorMode",void 0),L([s.property({type:Boolean})],D.prototype,"noCustom",void 0),L([s.property({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],D.prototype,"noCustomComponent",void 0),L([s.property({type:Boolean})],D.prototype,"withManualResources",void 0),L([i.jsonProperty([])],D.prototype,"messageContexts",void 0),L([i.jsonProperty(void 0)],D.prototype,"session",void 0),L([s.property({type:Object})],D.prototype,"apiProvider",void 0);class M{async listMySearches(){var t;return(null===(t=U.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await O.await()).listMySearches(U.getState().session.profile.userId):[]}}const B=new i.CacheRegistry;class k{async listMyBookmarks(){return B.get("bookmarks",(async()=>(await O.await()).listMyBookmarks(U.getState().session.profile.userId)))}clearCache(){B.clear("bookmarks")}}const F=i.FtReduxStore.get({name:"ft-user-assets",initialState:{savedSearches:void 0,bookmarks:void 0}});const x=new class{constructor(){this.currentSession=U.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new k,U.subscribe((()=>this.reloadWhenUserSessionChanges()))}reloadWhenUserSessionChanges(){var t;const{session:e}=U.getState();i.deepEqual(null===(t=this.currentSession)||void 0===t?void 0:t.profile,null==e?void 0:e.profile)||(this.currentSession=e,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){F.actions.savedSearches(void 0)}clearMyBookmarks(){F.actions.bookmarks(void 0)}async reloadMySearches(){const t=new M,i=await t.listMySearches();F.actions.savedSearches(i)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){const i=(null===(t=this.currentSession)||void 0===t?void 0:t.sessionAuthenticated)?await this.bookmarksService.listMyBookmarks():void 0;F.actions.bookmarks(i)}}};i.customElement("ft-app-context")(D);class j{get mapId(){return this._mapId}set mapId(t){t!==this._mapId&&this.clear(),this._mapId=t}constructor(t,i,e,s){this.converter=t,this.api=i,this.cache=e,this._mapId=s,this.initCache()}async withMapId(t){return this._mapId?t(this._mapId):void 0}initCache(){this.cache.registerFinal("configuration",(()=>this.api.getReaderConfiguration())),this.cache.register("map",(()=>this.withMapId((t=>this.fetchMap(t))))),this.cache.register("enrichedToc",(()=>this.withMapId((t=>this.fetchPages(t).then((t=>this.converter.convertPaginatedToc(t))))))),this.cache.register("ratingSummary",(()=>{var t,i;return b(null!==(i=null===(t=U.getState().session)||void 0===t?void 0:t.profile.roles)&&void 0!==i?i:[],"RATING_USER")?this.withMapId((t=>this.fetchMapRating(t))):Promise.resolve()}))}clear(){this.cache.clearAll()}getMap(){return this.cache.get("map")}getConfiguration(){return this.cache.get("configuration")}getEnrichedToc(){return this.cache.get("enrichedToc")}get enrichedToc(){return this.cache.getNow("enrichedToc")}async getPaginationConfiguration(){return(await this.getEnrichedToc()).paginationConfiguration}async getToc(){return(await this.getEnrichedToc()).toc}async getPagesToc(){return(await this.getEnrichedToc()).pagesToc}async getTocNode(t){return(await this.getEnrichedToc()).nodeByTocId[t]}getTocNodeNow(t){var i;return null===(i=this.enrichedToc)||void 0===i?void 0:i.nodeByTocId[t]}async getPage(t){const i=await this.getEnrichedToc();return i.pages[t-1]||i.pages[0]}async getPageByTocId(t){const i=await this.getEnrichedToc();return i.pageByTocId[t]||i.pages[0]}getTopicInfo(t){return this.cache.get("topic-"+t.tocId,(()=>this.fetchTopicMetadata(t)))}getTopicContent(t){return this.cache.get("topic-content-"+t.tocId,(()=>this.fetchTopicHTMLContent(t)))}getLink(t,i,e){const s=this.getNavigationData(t,i,e),n=this.getReaderLinkPrefix()+(s.prettyUrl?s.prettyUrl:`${s.mapId}/${s.tocId}`),r=new URL(n,this.api.tenantBaseUrl);return null!=s.page&&r.searchParams.set("page",`${s.page}`),s.prettyUrlDuplicated&&r.searchParams.set("tocId",s.tocId),null!=s.section&&r.searchParams.set("section",s.section),r.href}getNavigationData(t,i,e){var s,n;t=t||"root";const r=this.enrichedToc,o=null==r?void 0:r.pageByTocId[t],a=null==r?void 0:r.nodeByTocId[t],h=null==a?void 0:a.prettyUrl;return{mapId:this.mapId,tocId:t,topicTitle:null!==(s=null==a?void 0:a.title)&&void 0!==s?s:"",page:i&&o&&o.number!==i?i:void 0,prettyUrl:null!=h?h.replace(/^r\//,""):void 0,prettyUrlDuplicated:null!==(n=null==r?void 0:r.duplicatedPrettyUrls.has(null!=h?h:""))&&void 0!==n&&n,section:e}}async getAccurateNavigationData(t,i,e){return await this.getEnrichedToc(),this.getNavigationData(t,i,e)}getRatingSummary(){return this.cache.get("ratingSummary")}getMapRating(){return this.getRatingSummary().then((t=>null==t?void 0:t.publication))}getTopicRating(t){return this.getRatingSummary().then((i=>{var e;return i?{type:i.topics.type,rating:null===(e=i.topics)||void 0===e?void 0:e.ratings.find((i=>i.tocId===t))}:void 0}))}rateMap(t,i){return this.makeRateMapRequest(t,i).then((()=>this.clearRatingIfNecessary()))}unrateMap(){return this.makeUnrateMapRequest().then((()=>this.clearRatingIfNecessary()))}sendMapFeedback(t,i){return this.makeMapFeedbackRequest(t,i)}rateTopic(t,i,e){return this.makeRateTopicRequest(t,i,e).then((()=>this.clearRatingIfNecessary()))}unrateTopic(t){return this.makeUnrateTopicRequest(t).then((()=>this.clearRatingIfNecessary()))}async clearRatingIfNecessary(){const t=U.getState().session;(null==t?void 0:t.sessionAuthenticated)&&this.cache.clear("ratingSummary")}sendTopicFeedback(t,i,e){return this.makeTopicFeedbackRequest(t,i,e)}fontsStylesheet(){return this.api.makeAbsolute(this.api.endpoints.stylesheets.fonts)}themeStylesheet(){return this.api.makeAbsolute(this.api.endpoints.stylesheets.theme)}buildBreadcrumb(t){let i=this.getTocNodeNow(t),e=[{tocId:i.tocId,title:i.title}],s=this.getTocNodeNow(i.parentTocId);for(;s;)e.unshift({tocId:s.tocId,title:s.title}),s=this.getTocNodeNow(s.parentTocId);return e}isFeatureAccessible(i,{session:e,ratingType:s}){if(!this.isFeatureAvailable(i))return!1;switch(i){case t.FtReaderFeatures.FEEDBACK:return b(null!=e?e:[],T.FEEDBACK_USER);case t.FtReaderFeatures.RATING:return b(null!=e?e:[],T.RATING_USER)&&null!=s&&s!==l.NO_RATING;case t.FtReaderFeatures.PRINT:return b(null!=e?e:[],T.PRINT_USER);case t.FtReaderFeatures.BOOKMARK:return!!(null==e?void 0:e.sessionAuthenticated);case t.FtReaderFeatures.COLLECTIONS:return b(null!=e?e:[],T.COLLECTION_USER);default:return!1}}}class H extends j{static async build(t){return new H(new r,await O.await(),new i.CacheRegistry,t)}fetchMap(t){return this.api.getMap(t)}fetchMapRating(t){return this.api.getMapRating(t)}fetchPages(t){return this.api.getPages(t)}fetchTopicHTMLContent(t){return this.api.getTopicHTMLContent(this.mapId,t.contentId,"DESIGNED_READER")}fetchTopicMetadata(t){return this.api.getTopic(this.mapId,t.contentId)}makeMapFeedbackRequest(t,i){return this.api.sendMapFeedback(this.mapId,t,i)}makeRateMapRequest(t,i){return this.api.rateMap(this.mapId,t,i)}makeRateTopicRequest(t,i,e){return this.api.rateTopic(this.mapId,t,i,e)}makeTopicFeedbackRequest(t,i,e){return this.api.sendTopicFeedback(this.mapId,t,i,e)}makeUnrateMapRequest(){return this.api.unrateMap(this.mapId)}makeUnrateTopicRequest(t){return this.api.unrateTopic(this.mapId,t)}getReaderLinkPrefix(){return"r/"}isFeatureAvailable(t){return!0}}class G{static build(t,e){return new G((t=>i.FtReduxStore.get({name:"ft-reader-"+t,initialState:{mapId:void 0,visibleTopics:[],map:void 0,toc:void 0,pagesToc:void 0,paginationConfiguration:void 0,currentPage:void 0,scrollTarget:void 0,configuration:void 0}}))(t.trim()||"context"),null!=e?e:H.build)}constructor(t,e){this.store=t,this.reloadDebouncer=new i.Debouncer(10),this.initService(e)}async initService(t){return this.service=await t(),this.service.mapId=this.store.getState().mapId,this.reload()}async setMapId(t){t!==this.store.getState().mapId&&(this.store.actions.mapId(t),this.service&&(this.service.mapId=t),await this.reload())}setVisibleTopics(t){this.store.actions.visibleTopics(t)}async awaitService(){for(;null==this.service;)await i.delay(5);return this.service}async navigateToTopic(t,i,e){const s=await this.awaitService(),n=await(null!=e?s.getPage(e):s.getPageByTocId(null!=t?t:"root"));this.store.actions.currentPage(n),this.store.actions.scrollTarget({tocId:this.resolveValidNonRootTocId(t,n),section:i})}resolveValidNonRootTocId(t,i){var e,s,n;let r=null!==(e="root"===t?void 0:t)&&void 0!==e?e:i.rootTocId;return i.topics.includes(r)?r:null!==(n=null!==(s=i.topics[0])&&void 0!==s?s:i.hiddenTopics[0])&&void 0!==n?n:"root"}async navigateToPage(t){const i=await this.awaitService();let e=await i.getPage(t);this.store.actions.currentPage(e)}scrollDone(){this.store.actions.scrollTarget({})}async reload(){var t,i;this.store.actions.configuration(void 0),this.store.actions.map(void 0),this.store.actions.toc(void 0),this.store.actions.pagesToc(void 0),this.store.actions.currentPage(void 0),null===(t=this.service)||void 0===t||t.clear(),(null===(i=this.service)||void 0===i?void 0:i.mapId)&&await this.reloadDebouncer.run((()=>this.fetchData()))}async fetchData(){var t,e,s,n,r;try{await Promise.all([null===(t=this.service)||void 0===t?void 0:t.getConfiguration().then((t=>this.store.actions.configuration(t))),null===(e=this.service)||void 0===e?void 0:e.getMap().then((t=>this.store.actions.map(t))),null===(s=this.service)||void 0===s?void 0:s.getToc().then((t=>this.store.actions.toc(t))),null===(n=this.service)||void 0===n?void 0:n.getPagesToc().then((t=>this.store.actions.pagesToc(t))),null===(r=this.service)||void 0===r?void 0:r.getPaginationConfiguration().then((t=>this.store.actions.paginationConfiguration(t)))])}catch(t){!this.errorHandler||t instanceof i.CanceledPromiseError||this.errorHandler(t)}}}const K=e.css`
5
- `;class q extends CustomEvent{constructor(t,i){super("ft-reader-map-loaded",{detail:{map:t,toc:i}})}}class $ extends CustomEvent{constructor(t,i){super("ft-reader-visible-topics-change",{detail:{visibleTopics:i}})}}class V extends CustomEvent{constructor(t){super("ft-reader-navigation-done",{detail:t})}}class X extends CustomEvent{constructor(t){super("ft-reader-load-error",{detail:t})}}class Y extends Event{constructor(){super("ft-reader-map-not-found")}}class W extends Event{constructor(){super("ft-reader-map-unauthorized")}}var z=function(t,i,e,s){for(var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s,a=t.length-1;a>=0;a--)(n=t[a])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};class J extends i.FtLitElementRedux{constructor(){super(),this.visibleTopics=[],this.scrollToTargetDebouncer=new i.Debouncer(5),this.navigationDebouncer=new i.Debouncer(10),this.addStore(U)}render(){return e.html`
4
+ `}update(t){super.update(t),t.has("baseUrl")&&R.actions.setBaseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&R.actions.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&R.actions.setUiLocale(this.uiLocale),t.has("noCustom")&&R.actions.setNoCustom(this.noCustom),t.has("editorMode")&&R.actions.setEditorMode(this.editorMode),t.has("noCustomComponent")&&R.actions.setNoCustomComponent(this.noCustomComponent),t.has("session")&&R.actions.setSession(this.session),t.has("availableUiLocales")&&R.actions.setAvailableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>P.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){const t=this.apiProvider();!this.withManualResources&&t&&(null==this.session&&(this.session=await this.cache.get("session",(async()=>{const i=await t.getCurrentSession();return i.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),i.idleTimeoutInMillis),i}))),null==this.availableUiLocales&&(this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>t.getAvailableUiLocales()))))}}L.elementDefinitions={},L.styles=S,N([s.property()],L.prototype,"baseUrl",void 0),N([s.property()],L.prototype,"apiIntegrationIdentifier",void 0),N([s.property()],L.prototype,"uiLocale",void 0),N([i.jsonProperty([])],L.prototype,"availableUiLocales",void 0),N([s.property({type:Boolean})],L.prototype,"editorMode",void 0),N([s.property({type:Boolean})],L.prototype,"noCustom",void 0),N([s.property({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],L.prototype,"noCustomComponent",void 0),N([s.property({type:Boolean})],L.prototype,"withManualResources",void 0),N([i.jsonProperty([])],L.prototype,"messageContexts",void 0),N([i.jsonProperty(void 0)],L.prototype,"session",void 0),N([s.property({type:Object})],L.prototype,"apiProvider",void 0);class D{async listMySearches(){var t;return(null===(t=R.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await I.await()).listMySearches(R.getState().session.profile.userId):[]}}const M=new i.CacheRegistry;class _{async listMyBookmarks(){return M.get("bookmarks",(async()=>(await I.await()).listMyBookmarks(R.getState().session.profile.userId)))}clearCache(){M.clear("bookmarks")}}const B=i.FtReduxStore.get({name:"ft-user-assets",initialState:{savedSearches:void 0,bookmarks:void 0}});const k=new class{constructor(){this.currentSession=R.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new _,R.subscribe((()=>this.reloadWhenUserSessionChanges()))}reloadWhenUserSessionChanges(){var t;const{session:e}=R.getState();i.deepEqual(null===(t=this.currentSession)||void 0===t?void 0:t.profile,null==e?void 0:e.profile)||(this.currentSession=e,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){B.actions.savedSearches(void 0)}clearMyBookmarks(){B.actions.bookmarks(void 0)}async reloadMySearches(){const t=new D,i=await t.listMySearches();B.actions.savedSearches(i)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){const i=(null===(t=this.currentSession)||void 0===t?void 0:t.sessionAuthenticated)?await this.bookmarksService.listMyBookmarks():void 0;B.actions.bookmarks(i)}}};i.customElement("ft-app-context")(L);class F{get mapId(){return this._mapId}set mapId(t){t!==this._mapId&&this.clear(),this._mapId=t}constructor(t,i,e,s){this.converter=t,this.api=i,this.cache=e,this._mapId=s,this.initCache()}async withMapId(t){return this._mapId?t(this._mapId):void 0}initCache(){this.cache.registerFinal("configuration",(()=>this.api.getReaderConfiguration())),this.cache.register("map",(()=>this.withMapId((t=>this.fetchMap(t))))),this.cache.register("enrichedToc",(()=>this.withMapId((t=>this.fetchPages(t).then((t=>this.converter.convertPaginatedToc(t))))))),this.cache.register("ratingSummary",(()=>{var t,i;return b(null!==(i=null===(t=R.getState().session)||void 0===t?void 0:t.profile.roles)&&void 0!==i?i:[],"RATING_USER")?this.withMapId((t=>this.fetchMapRating(t))):Promise.resolve()}))}clear(){this.cache.clearAll()}getMap(){return this.cache.get("map")}getConfiguration(){return this.cache.get("configuration")}getEnrichedToc(){return this.cache.get("enrichedToc")}get enrichedToc(){return this.cache.getNow("enrichedToc")}async getPaginationConfiguration(){return(await this.getEnrichedToc()).paginationConfiguration}async getToc(){return(await this.getEnrichedToc()).toc}async getPagesToc(){return(await this.getEnrichedToc()).pagesToc}async getTocNode(t){return(await this.getEnrichedToc()).nodeByTocId[t]}getTocNodeNow(t){var i;return null===(i=this.enrichedToc)||void 0===i?void 0:i.nodeByTocId[t]}async getPage(t){const i=await this.getEnrichedToc();return i.pages[t-1]||i.pages[0]}async getPageByTocId(t){const i=await this.getEnrichedToc();return i.pageByTocId[t]||i.pages[0]}getTopicInfo(t){return this.cache.get("topic-"+t.tocId,(()=>this.fetchTopicMetadata(t)))}getTopicContent(t){return this.cache.get("topic-content-"+t.tocId,(()=>this.fetchTopicHTMLContent(t)))}getLink(t,i,e){const s=this.getNavigationData(t,i,e),n=this.getReaderLinkPrefix()+(s.prettyUrl?s.prettyUrl:`${s.mapId}/${s.tocId}`),r=new URL(n,this.api.tenantBaseUrl);return null!=s.page&&r.searchParams.set("page",`${s.page}`),s.prettyUrlDuplicated&&r.searchParams.set("tocId",s.tocId),null!=s.section&&r.searchParams.set("section",s.section),r.href}getNavigationData(t,i,e){var s,n;t=t||"root";const r=this.enrichedToc,o=null==r?void 0:r.pageByTocId[t],a=null==r?void 0:r.nodeByTocId[t],h=null==a?void 0:a.prettyUrl;return{mapId:this.mapId,tocId:t,topicTitle:null!==(s=null==a?void 0:a.title)&&void 0!==s?s:"",page:i&&o&&o.number!==i?i:void 0,prettyUrl:null!=h?h.replace(/^r\//,""):void 0,prettyUrlDuplicated:null!==(n=null==r?void 0:r.duplicatedPrettyUrls.has(null!=h?h:""))&&void 0!==n&&n,section:e}}async getAccurateNavigationData(t,i,e){return await this.getEnrichedToc(),this.getNavigationData(t,i,e)}getRatingSummary(){return this.cache.get("ratingSummary")}getMapRating(){return this.getRatingSummary().then((t=>null==t?void 0:t.publication))}getTopicRating(t){return this.getRatingSummary().then((i=>{var e;return i?{type:i.topics.type,rating:null===(e=i.topics)||void 0===e?void 0:e.ratings.find((i=>i.tocId===t))}:void 0}))}rateMap(t,i){return this.makeRateMapRequest(t,i).then((()=>this.clearRatingIfNecessary()))}unrateMap(){return this.makeUnrateMapRequest().then((()=>this.clearRatingIfNecessary()))}sendMapFeedback(t,i){return this.makeMapFeedbackRequest(t,i)}rateTopic(t,i,e){return this.makeRateTopicRequest(t,i,e).then((()=>this.clearRatingIfNecessary()))}unrateTopic(t){return this.makeUnrateTopicRequest(t).then((()=>this.clearRatingIfNecessary()))}async clearRatingIfNecessary(){const t=R.getState().session;(null==t?void 0:t.sessionAuthenticated)&&this.cache.clear("ratingSummary")}sendTopicFeedback(t,i,e){return this.makeTopicFeedbackRequest(t,i,e)}fontsStylesheet(){return this.api.makeAbsolute(this.api.endpoints.stylesheets.fonts)}themeStylesheet(){return this.api.makeAbsolute(this.api.endpoints.stylesheets.theme)}buildBreadcrumb(t){let i=this.getTocNodeNow(t),e=[{tocId:i.tocId,title:i.title}],s=this.getTocNodeNow(i.parentTocId);for(;s;)e.unshift({tocId:s.tocId,title:s.title}),s=this.getTocNodeNow(s.parentTocId);return e}isFeatureAccessible(i,{session:e,ratingType:s}){if(!this.isFeatureAvailable(i))return!1;switch(i){case t.FtReaderFeatures.FEEDBACK:return b(null!=e?e:[],T.FEEDBACK_USER);case t.FtReaderFeatures.RATING:return b(null!=e?e:[],T.RATING_USER)&&null!=s&&s!==u.NO_RATING;case t.FtReaderFeatures.PRINT:return b(null!=e?e:[],T.PRINT_USER);case t.FtReaderFeatures.BOOKMARK:return!!(null==e?void 0:e.sessionAuthenticated);case t.FtReaderFeatures.COLLECTIONS:return b(null!=e?e:[],T.COLLECTION_USER);default:return!1}}}class x extends F{static async build(t){return new x(new r,await I.await(),new i.CacheRegistry,t)}clear(){super.clear(),this.fingerprint=void 0}async fetchMap(t){var i;const e=await this.api.getMap(t);return this.fingerprint=null===(i=e.lastPublication)||void 0===i?void 0:i.replace(/\D/g,""),e}fetchMapRating(t){return this.api.getMapRating(t)}async fetchPages(t){return await this.getMap(),this.api.getPages(t,this.fingerprint)}fetchTopicHTMLContent(t){return this.api.getTopicHTMLContent(this.mapId,t.contentId,"DESIGNED_READER",this.fingerprint)}fetchTopicMetadata(t){return this.api.getTopic(this.mapId,t.contentId,this.fingerprint)}makeMapFeedbackRequest(t,i){return this.api.sendMapFeedback(this.mapId,t,i)}makeRateMapRequest(t,i){return this.api.rateMap(this.mapId,t,i)}makeRateTopicRequest(t,i,e){return this.api.rateTopic(this.mapId,t,i,e)}makeTopicFeedbackRequest(t,i,e){return this.api.sendTopicFeedback(this.mapId,t,i,e)}makeUnrateMapRequest(){return this.api.unrateMap(this.mapId)}makeUnrateTopicRequest(t){return this.api.unrateTopic(this.mapId,t)}getReaderLinkPrefix(){return"r/"}isFeatureAvailable(t){return!0}}class j{static build(t,e){return new j((t=>i.FtReduxStore.get({name:"ft-reader-"+t,initialState:{mapId:void 0,visibleTopics:[],map:void 0,toc:void 0,pagesToc:void 0,paginationConfiguration:void 0,currentPage:void 0,scrollTarget:void 0,configuration:void 0}}))(t.trim()||"context"),null!=e?e:x.build)}constructor(t,e){this.store=t,this.reloadDebouncer=new i.Debouncer(10),this.initService(e)}async initService(t){return this.service=await t(),this.service.mapId=this.store.getState().mapId,this.reload()}async setMapId(t){t!==this.store.getState().mapId&&(this.store.actions.mapId(t),this.service&&(this.service.mapId=t),await this.reload())}setVisibleTopics(t){this.store.actions.visibleTopics(t)}async awaitService(){for(;null==this.service;)await i.delay(5);return this.service}async navigateToTopic(t,i,e){const s=await this.awaitService(),n=await(null!=e?s.getPage(e):s.getPageByTocId(null!=t?t:"root"));this.store.actions.currentPage(n),this.store.actions.scrollTarget({tocId:this.resolveValidNonRootTocId(t,n),section:i})}resolveValidNonRootTocId(t,i){var e,s,n;let r=null!==(e="root"===t?void 0:t)&&void 0!==e?e:i.rootTocId;return i.topics.includes(r)?r:null!==(n=null!==(s=i.topics[0])&&void 0!==s?s:i.hiddenTopics[0])&&void 0!==n?n:"root"}async navigateToPage(t){const i=await this.awaitService();let e=await i.getPage(t);this.store.actions.currentPage(e)}scrollDone(){this.store.actions.scrollTarget({})}async reload(){var t,i;this.store.actions.configuration(void 0),this.store.actions.map(void 0),this.store.actions.toc(void 0),this.store.actions.pagesToc(void 0),this.store.actions.currentPage(void 0),null===(t=this.service)||void 0===t||t.clear(),(null===(i=this.service)||void 0===i?void 0:i.mapId)&&await this.reloadDebouncer.run((()=>this.fetchData()))}async fetchData(){var t,e,s,n,r;try{await Promise.all([null===(t=this.service)||void 0===t?void 0:t.getConfiguration().then((t=>this.store.actions.configuration(t))),null===(e=this.service)||void 0===e?void 0:e.getMap().then((t=>this.store.actions.map(t))),null===(s=this.service)||void 0===s?void 0:s.getToc().then((t=>this.store.actions.toc(t))),null===(n=this.service)||void 0===n?void 0:n.getPagesToc().then((t=>this.store.actions.pagesToc(t))),null===(r=this.service)||void 0===r?void 0:r.getPaginationConfiguration().then((t=>this.store.actions.paginationConfiguration(t)))])}catch(t){!this.errorHandler||t instanceof i.CanceledPromiseError||this.errorHandler(t)}}}const H=e.css`
5
+ `;class G extends CustomEvent{constructor(t,i){super("ft-reader-map-loaded",{detail:{map:t,toc:i}})}}class K extends CustomEvent{constructor(t,i){super("ft-reader-visible-topics-change",{detail:{visibleTopics:i}})}}class q extends CustomEvent{constructor(t){super("ft-reader-navigation-done",{detail:t})}}class $ extends CustomEvent{constructor(t){super("ft-reader-load-error",{detail:t})}}class V extends Event{constructor(){super("ft-reader-map-not-found")}}class X extends Event{constructor(){super("ft-reader-map-unauthorized")}}var Y=function(t,i,e,s){for(var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s,a=t.length-1;a>=0;a--)(n=t[a])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};class W extends i.FtLitElementRedux{constructor(){super(),this.visibleTopics=[],this.scrollToTargetDebouncer=new i.Debouncer(5),this.navigationDebouncer=new i.Debouncer(10),this.addStore(R)}render(){return e.html`
6
6
  ${this.importStyleIfNeeded()}
7
7
  <slot @register-ft-reader-component=${this.registerComponent}></slot>
8
8
  `}importStyleIfNeeded(){var t,i;const s=null===(t=this.stateManager.service)||void 0===t?void 0:t.themeStylesheet();return!s||window.location.href.startsWith(null!==(i=this.baseUrl)&&void 0!==i?i:"")?e.nothing:e.html`
9
9
  <style>
10
10
  @import "${s}"
11
11
  </style>
12
- `}get stateManager(){return null==this._stateManager&&(this._stateManager=G.build(this.id||(""+Math.round(999e3*Math.random())).padStart(6,"0"),this.readerServiceProvider),this._stateManager.errorHandler=t=>this.handleLoadError(t),this.addStore(this.stateManager.store,"reader")),this._stateManager}connectedCallback(){super.connectedCallback(),this.stateManager.setMapId(this.mapId),this.stateManager.awaitService().then((t=>{const i=t.fontsStylesheet();if(i&&!window.location.href.startsWith(this.baseUrl)&&!document.querySelector(`head link[href="${i}"]`)){const t=document.createElement("link");t.setAttribute("rel","stylesheet"),t.setAttribute("href",i),document.head.append(t)}}))}update(t){super.update(t),t.has("readerServiceProvider")&&this.readerServiceProvider&&this.stateManager.initService(this.readerServiceProvider),t.has("mapId")&&this.mapId&&this.stateManager.setMapId(this.mapId),["tocId","section","page","mapId"].some((i=>t.has(i)))&&this.mapId&&this.navigateToTarget()}contentAvailableCallback(t){var i;if(super.contentAvailableCallback(t),(t.has("map")||t.has("toc"))&&this.map&&this.toc&&this.dispatchEvent(new q(this.map,this.toc)),t.has("scrollTarget")&&null==(null===(i=this.scrollTarget)||void 0===i?void 0:i.tocId)){const i=t.get("scrollTarget");null!=(null==i?void 0:i.tocId)&&this.scrollToTargetDebouncer.run((()=>{var t;return this.stateManager.service.getAccurateNavigationData(i.tocId,null===(t=this.currentPage)||void 0===t?void 0:t.number,i.section).then((t=>this.dispatchEvent(new V(t))))}))}t.has("visibleTopics")&&Promise.all(this.visibleTopics.map((t=>{var i;return this.stateManager.service.getAccurateNavigationData(t,null===(i=this.currentPage)||void 0===i?void 0:i.number)}))).then((t=>{let i=t.filter((t=>null!=t&&""!==t.topicTitle)).map((t=>{var i;return{tocId:t.tocId,title:t.topicTitle,page:t.page,prettyUrl:t.prettyUrl,prettyUrlDuplicated:t.prettyUrlDuplicated,breadcrumb:null===(i=this.stateManager.service)||void 0===i?void 0:i.buildBreadcrumb(t.tocId)}}));this.dispatchEvent(new $(this.map,i))}))}async reload(){await this.stateManager.reload(),this.navigateToTarget()}navigateToTarget(){this.navigationDebouncer.run((()=>{null!=this.tocId?this.stateManager.navigateToTopic(this.tocId,this.section,this.page):null!=this.page&&this.stateManager.navigateToPage(this.page)}))}registerComponent(t){t.stopPropagation();const i=t.composedPath()[0];this.register(i)}register(t){t.setReaderStateManager(this.stateManager)}handleLoadError(t){const i=t;404===i.status?this.dispatchEvent(new Y):401===i.status?this.dispatchEvent(new W):this.dispatchEvent(new X(t))}reloadBookmarks(){x.reloadBookmarks()}}var Q;J.styles=K,z([i.redux({store:U.name})],J.prototype,"baseUrl",void 0),z([s.property()],J.prototype,"mapId",void 0),z([s.property()],J.prototype,"tocId",void 0),z([s.property()],J.prototype,"section",void 0),z([s.property({type:Number,converter:{fromAttribute:t=>+(null!=t?t:"NaN")>0?+t:Q}})],J.prototype,"page",void 0),z([i.redux({store:"reader"})],J.prototype,"map",void 0),z([i.redux({store:"reader"})],J.prototype,"toc",void 0),z([i.redux({store:"reader"})],J.prototype,"visibleTopics",void 0),z([i.redux({store:"reader"})],J.prototype,"currentPage",void 0),z([i.redux({store:"reader"})],J.prototype,"scrollTarget",void 0),z([s.property({attribute:!1})],J.prototype,"readerServiceProvider",void 0),i.customElement("ft-reader-context")(J),t.FtOfficialReaderService=H,t.FtReaderContext=J,t.FtReaderContextCssVariables={},t.FtReaderConverter=r,t.FtReaderService=j,t.LoadErrorEvent=X,t.MapLoadedEvent=q,t.NavigationDoneEvent=V,t.NotFoundErrorEvent=Y,t.UnauthorizedErrorEvent=W,t.VisibleTopicsChangeEvent=$,t.styles=K}({},ftGlobals.wcUtils,ftGlobals.lit,ftGlobals.litDecorators);
12
+ `}get stateManager(){return null==this._stateManager&&(this._stateManager=j.build(this.id||(""+Math.round(999e3*Math.random())).padStart(6,"0"),this.readerServiceProvider),this._stateManager.errorHandler=t=>this.handleLoadError(t),this.addStore(this.stateManager.store,"reader")),this._stateManager}connectedCallback(){super.connectedCallback(),this.stateManager.setMapId(this.mapId),this.stateManager.awaitService().then((t=>{const i=t.fontsStylesheet();if(i&&!window.location.href.startsWith(this.baseUrl)&&!document.querySelector(`head link[href="${i}"]`)){const t=document.createElement("link");t.setAttribute("rel","stylesheet"),t.setAttribute("href",i),document.head.append(t)}}))}update(t){super.update(t),t.has("readerServiceProvider")&&this.readerServiceProvider&&this.stateManager.initService(this.readerServiceProvider),t.has("mapId")&&this.mapId&&this.stateManager.setMapId(this.mapId),["tocId","section","page","mapId"].some((i=>t.has(i)))&&this.mapId&&this.navigateToTarget()}contentAvailableCallback(t){var i;if(super.contentAvailableCallback(t),(t.has("map")||t.has("toc"))&&this.map&&this.toc&&this.dispatchEvent(new G(this.map,this.toc)),t.has("scrollTarget")&&null==(null===(i=this.scrollTarget)||void 0===i?void 0:i.tocId)){const i=t.get("scrollTarget");null!=(null==i?void 0:i.tocId)&&this.scrollToTargetDebouncer.run((()=>{var t;return this.stateManager.service.getAccurateNavigationData(i.tocId,null===(t=this.currentPage)||void 0===t?void 0:t.number,i.section).then((t=>this.dispatchEvent(new q(t))))}))}t.has("visibleTopics")&&Promise.all(this.visibleTopics.map((t=>{var i;return this.stateManager.service.getAccurateNavigationData(t,null===(i=this.currentPage)||void 0===i?void 0:i.number)}))).then((t=>{let i=t.filter((t=>null!=t&&""!==t.topicTitle)).map((t=>{var i;return{tocId:t.tocId,title:t.topicTitle,page:t.page,prettyUrl:t.prettyUrl,prettyUrlDuplicated:t.prettyUrlDuplicated,breadcrumb:null===(i=this.stateManager.service)||void 0===i?void 0:i.buildBreadcrumb(t.tocId)}}));this.dispatchEvent(new K(this.map,i))}))}async reload(){await this.stateManager.reload(),this.navigateToTarget()}navigateToTarget(){this.navigationDebouncer.run((()=>{null!=this.tocId?this.stateManager.navigateToTopic(this.tocId,this.section,this.page):null!=this.page&&this.stateManager.navigateToPage(this.page)}))}registerComponent(t){t.stopPropagation();const i=t.composedPath()[0];this.register(i)}register(t){t.setReaderStateManager(this.stateManager)}handleLoadError(t){const i=t;404===i.status?this.dispatchEvent(new V):401===i.status?this.dispatchEvent(new X):this.dispatchEvent(new $(t))}reloadBookmarks(){k.reloadBookmarks()}}var z;W.styles=H,Y([i.redux({store:R.name})],W.prototype,"baseUrl",void 0),Y([s.property()],W.prototype,"mapId",void 0),Y([s.property()],W.prototype,"tocId",void 0),Y([s.property()],W.prototype,"section",void 0),Y([s.property({type:Number,converter:{fromAttribute:t=>+(null!=t?t:"NaN")>0?+t:z}})],W.prototype,"page",void 0),Y([i.redux({store:"reader"})],W.prototype,"map",void 0),Y([i.redux({store:"reader"})],W.prototype,"toc",void 0),Y([i.redux({store:"reader"})],W.prototype,"visibleTopics",void 0),Y([i.redux({store:"reader"})],W.prototype,"currentPage",void 0),Y([i.redux({store:"reader"})],W.prototype,"scrollTarget",void 0),Y([s.property({attribute:!1})],W.prototype,"readerServiceProvider",void 0),i.customElement("ft-reader-context")(W),t.FtOfficialReaderService=x,t.FtReaderContext=W,t.FtReaderContextCssVariables={},t.FtReaderConverter=r,t.FtReaderService=F,t.LoadErrorEvent=$,t.MapLoadedEvent=G,t.NavigationDoneEvent=q,t.NotFoundErrorEvent=V,t.UnauthorizedErrorEvent=X,t.VisibleTopicsChangeEvent=K,t.styles=H}({},ftGlobals.wcUtils,ftGlobals.lit,ftGlobals.litDecorators);
@@ -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,o=window.customElements.define,r=window.customElements.get,e=window.customElements,n=new WeakMap,i=new WeakMap,a=new WeakMap,c=new WeakMap;let s;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 c=n.prototype.attributeChangedCallback,s=new Set(n.observedAttributes||[]);h(n,s,c);const l={elementClass:n,connectedCallback:n.prototype.connectedCallback,disconnectedCallback:n.prototype.disconnectedCallback,adoptedCallback:n.prototype.adoptedCallback,attributeChangedCallback:c,formAssociated:n.formAssociated,formAssociatedCallback:n.prototype.formAssociatedCallback,formDisabledCallback:n.prototype.formDisabledCallback,formResetCallback:n.prototype.formResetCallback,formStateRestoreCallback:n.prototype.formStateRestoreCallback,observedAttributes:s};this._definitionsByTag.set(t,l),this._definitionsByClass.set(n,l);let f=r.call(e,t);f||(f=u(t),o.call(e,t,f)),this===window.customElements&&(a.set(n,l),l.standInClass=f);const d=this._awaitingUpgrade.get(t);if(d){this._awaitingUpgrade.delete(t);for(const t of d)i.delete(t),p(t,l,!0)}const y=this._whenDefinedPromises.get(t);return void 0!==y&&(y.resolve(n),this._whenDefinedPromises.delete(t)),n}upgrade(){b.push(this),e.upgrade.apply(e,arguments),b.pop()}get(t){const o=this._definitionsByTag.get(t);return o?.elementClass}_getDefinition(t){return this._definitionsByTag.get(t)}whenDefined(t){const o=this._getDefinition(t);if(void 0!==o)return Promise.resolve(o.elementClass);let r=this._whenDefinedPromises.get(t);return void 0===r&&(r={},r.promise=new Promise((t=>r.resolve=t)),this._whenDefinedPromises.set(t,r)),r.promise}_upgradeWhenDefined(t,o,r){let e=this._awaitingUpgrade.get(o);e||this._awaitingUpgrade.set(o,e=new Set),r?e.add(t):e.delete(t)}},window.HTMLElement=function(){let o=s;if(o)return s=void 0,o;const r=a.get(this.constructor);if(!r)throw new TypeError("Illegal constructor (custom element class must be registered with global customElements registry to be newable)");return o=Reflect.construct(t,[],r.standInClass),Object.setPrototypeOf(o,this.constructor.prototype),n.set(o,r),o},window.HTMLElement.prototype=t.prototype;const l=t=>t===document||t instanceof ShadowRoot,f=t=>{let o=t.getRootNode();if(!l(o)){const t=b[b.length-1];if(t instanceof CustomElementRegistry)return t;o=t.getRootNode(),l(o)||(o=c.get(o)?.getRootNode()||document)}return o.customElements},u=o=>class{static get formAssociated(){return!0}constructor(){const r=Reflect.construct(t,[],this.constructor);Object.setPrototypeOf(r,HTMLElement.prototype);const e=f(r)||window.customElements,n=e._getDefinition(o);return n?p(r,n):i.set(r,e),r}connectedCallback(){const t=n.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):i.get(this)._upgradeWhenDefined(this,o,!0)}disconnectedCallback(){const t=n.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):i.get(this)._upgradeWhenDefined(this,o,!1)}adoptedCallback(){const t=n.get(this);t?.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)}},h=(t,o,r)=>{if(0===o.size||void 0===r)return;const e=t.prototype.setAttribute;e&&(t.prototype.setAttribute=function(t,n){const i=t.toLowerCase();if(o.has(i)){const t=this.getAttribute(i);e.call(this,i,n),r.call(this,i,t,n)}else e.call(this,i,n)});const n=t.prototype.removeAttribute;n&&(t.prototype.removeAttribute=function(t){const e=t.toLowerCase();if(o.has(e)){const t=this.getAttribute(e);n.call(this,e),r.call(this,e,t,null)}else n.call(this,e)})},d=o=>{const r=Object.getPrototypeOf(o);if(r!==window.HTMLElement)return r===t||"HTMLElement"===r?.prototype?.constructor?.name?Object.setPrototypeOf(o,window.HTMLElement):d(r)},p=(t,o,r=!1)=>{Object.setPrototypeOf(t,o.elementClass.prototype),n.set(t,o),s=t;try{new o.elementClass}catch(t){d(o.elementClass),new o.elementClass}o.observedAttributes.forEach((r=>{t.hasAttribute(r)&&o.attributeChangedCallback.call(t,r,null,t.getAttribute(r))})),r&&o.connectedCallback&&t.isConnected&&o.connectedCallback.call(t)},y=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const o=y.apply(this,arguments);return t.customElements&&(o.customElements=t.customElements),o};let b=[document];const g=(t,o,r=void 0)=>{const e=(r?Object.getPrototypeOf(r):t.prototype)[o];t.prototype[o]=function(){b.push(this);const t=e.apply(r||this,arguments);return void 0!==t&&c.set(t,this),b.pop(),t}};g(ShadowRoot,"createElement",document),g(ShadowRoot,"importNode",document),g(Element,"insertAdjacentHTML");const v=(t,o)=>{const r=Object.getOwnPropertyDescriptor(t.prototype,o);Object.defineProperty(t.prototype,o,{...r,set(t){b.push(this),r.set.call(this,t),b.pop()}})};if(v(Element,"innerHTML"),v(ShadowRoot,"innerHTML"),Object.defineProperty(window,"customElements",{value:new CustomElementRegistry,configurable:!0,writable:!0}),window.ElementInternals&&window.ElementInternals.prototype.setFormValue){const t=new WeakMap,o=HTMLElement.prototype.attachInternals,r=["setFormValue","setValidity","checkValidity","reportValidity"];HTMLElement.prototype.attachInternals=function(...r){const e=o.call(this,...r);return t.set(e,this),e},r.forEach((o=>{const r=window.ElementInternals.prototype,e=r[o];r[o]=function(...o){const r=t.get(this);if(!0!==n.get(r).formAssociated)throw new DOMException(`Failed to execute ${e} on 'ElementInternals': The target element is not a form-associated custom element.`);e?.call(this,...o)}}));class e extends Array{constructor(t){super(...t),this._elements=t}get value(){return this._elements.find((t=>!0===t.checked))?.value||""}}class i{constructor(t){const o=new Map;t.forEach(((t,r)=>{const e=t.getAttribute("name"),n=o.get(e)||[];this[+r]=t,n.push(t),o.set(e,n)})),this.length=t.length,o.forEach(((t,o)=>{t&&(1===t.length?this[o]=t[0]:this[o]=new e(t))}))}namedItem(t){return this[t]}}const a=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get:function(){const t=a.get.call(this,[]),o=[];for(const r of t){const t=n.get(r);t&&!0!==t.formAssociated||o.push(r)}return new i(o)}})}}try{window.customElements.define("custom-element",null)}catch(W){const t=window.customElements.define;window.customElements.define=(o,r,e)=>{if(null!==r)try{t.bind(window.customElements)(o,r,e)}catch(t){console.info(o,r,e,t)}}}class o extends Error{constructor(t,o,r){super(t),this.canceledPromiseResult=o,this.canceledPromiseError=r}}class r extends Promise{constructor(t){super(((r,e)=>t((t=>{this.isCanceled?e(new o("Promise has been canceled",t)):r(t)}),(t=>{this.isCanceled?e(new o("Promise has been canceled",void 0,t)):e(t)})))),this.isCanceled=!1}cancel(){this.isCanceled=!0}}class e{constructor(){this.loaders={},this.content={},this.clearTimeouts={},this.finalContent=new Set}register(t,o){this.loaders[t]=o,this.finalContent.delete(t)}registerFinal(t,o){this.loaders[t]=o,this.finalContent.add(t)}clearAll(){for(let t in this.content)this.clear(t)}clear(t){this.finalContent.has(t)||this.forceClear(t)}forceClear(t){this.clearClearTimeout(t),this.content[t]instanceof r&&this.content[t].cancel(),delete this.content[t]}clearClearTimeout(t){null!=this.clearTimeouts[t]&&(window.clearTimeout(this.clearTimeouts[t]),delete this.clearTimeouts[t])}set(t,o){this.forceClear(t),this.register(t,(async()=>o)),this.content[t]=o}setFinal(t,o){this.forceClear(t),this.registerFinal(t,(async()=>o)),this.content[t]=o}async get(t,o,e){if(void 0===this.content[t]){if(null==(o=null!=o?o:this.loaders[t]))throw new Error("Unknown cache key "+t);const n=(t=>new r(((o,r)=>t.then(o).catch(r))))(o());return this.content[t]=n,n.then((o=>(this.content[t]=o,null!=e&&(this.clearClearTimeout(t),this.clearTimeouts[t]=window.setTimeout((()=>this.clear(t)),e)),o)))}if(this.content[t]instanceof Error)throw this.content[t];return this.content[t]}isResolvedValue(t){return!(null==t||t instanceof Promise||t instanceof Error)}getNow(t){if(this.isResolvedValue(this.content[t]))return this.content[t]}has(t){return null!=this.content[t]}resolvedKeys(){return Object.keys(this.content).filter((t=>this.isResolvedValue(this.content[t])))}resolvedValues(){return Object.values(this.content).filter((t=>this.isResolvedValue(t)))}keys(){return Object.keys(this.content)}values(){return Object.values(this.content)}}class n{constructor(t=0){this.timeout=t,this.callbacks=[]}run(t,o){return this.callbacks=[t],this.debounce(o)}queue(t,o){return this.callbacks.push(t),this.debounce(o)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(t){return null==this.promise&&(this.promise=new Promise(((t,o)=>{this.resolvePromise=t,this.rejectPromise=o}))),this.clearTimeout(),this._debounce=window.setTimeout((()=>this.runCallbacks()),null!=t?t:this.timeout),this.promise}async runCallbacks(){var t,o;const r=[...this.callbacks];this.callbacks=[];const e=null!==(t=this.rejectPromise)&&void 0!==t?t:()=>null,n=null!==(o=this.resolvePromise)&&void 0!==o?o:()=>null;this.clearPromise();for(let t of r)try{await t()}catch(t){return void e(t)}n(!0)}clearTimeout(){null!=this._debounce&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}}
17
+ if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,o=window.customElements.define,r=window.customElements.get,e=window.customElements,n=new WeakMap,i=new WeakMap,a=new WeakMap,s=new WeakMap;let c;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 s=n.prototype.attributeChangedCallback,c=new Set(n.observedAttributes||[]);h(n,c,s);const l={elementClass:n,connectedCallback:n.prototype.connectedCallback,disconnectedCallback:n.prototype.disconnectedCallback,adoptedCallback:n.prototype.adoptedCallback,attributeChangedCallback:s,formAssociated:n.formAssociated,formAssociatedCallback:n.prototype.formAssociatedCallback,formDisabledCallback:n.prototype.formDisabledCallback,formResetCallback:n.prototype.formResetCallback,formStateRestoreCallback:n.prototype.formStateRestoreCallback,observedAttributes:c};this._definitionsByTag.set(t,l),this._definitionsByClass.set(n,l);let f=r.call(e,t);f||(f=u(t),o.call(e,t,f)),this===window.customElements&&(a.set(n,l),l.standInClass=f);const d=this._awaitingUpgrade.get(t);if(d){this._awaitingUpgrade.delete(t);for(const t of d)i.delete(t),p(t,l,!0)}const y=this._whenDefinedPromises.get(t);return void 0!==y&&(y.resolve(n),this._whenDefinedPromises.delete(t)),n}upgrade(){b.push(this),e.upgrade.apply(e,arguments),b.pop()}get(t){const o=this._definitionsByTag.get(t);return o?.elementClass}_getDefinition(t){return this._definitionsByTag.get(t)}whenDefined(t){const o=this._getDefinition(t);if(void 0!==o)return Promise.resolve(o.elementClass);let r=this._whenDefinedPromises.get(t);return void 0===r&&(r={},r.promise=new Promise((t=>r.resolve=t)),this._whenDefinedPromises.set(t,r)),r.promise}_upgradeWhenDefined(t,o,r){let e=this._awaitingUpgrade.get(o);e||this._awaitingUpgrade.set(o,e=new Set),r?e.add(t):e.delete(t)}},window.HTMLElement=function(){let o=c;if(o)return c=void 0,o;const r=a.get(this.constructor);if(!r)throw new TypeError("Illegal constructor (custom element class must be registered with global customElements registry to be newable)");return o=Reflect.construct(t,[],r.standInClass),Object.setPrototypeOf(o,this.constructor.prototype),n.set(o,r),o},window.HTMLElement.prototype=t.prototype;const l=t=>t===document||t instanceof ShadowRoot,f=t=>{let o=t.getRootNode();if(!l(o)){const t=b[b.length-1];if(t instanceof CustomElementRegistry)return t;o=t.getRootNode(),l(o)||(o=s.get(o)?.getRootNode()||document)}return o.customElements},u=o=>class{static get formAssociated(){return!0}constructor(){const r=Reflect.construct(t,[],this.constructor);Object.setPrototypeOf(r,HTMLElement.prototype);const e=f(r)||window.customElements,n=e._getDefinition(o);return n?p(r,n):i.set(r,e),r}connectedCallback(){const t=n.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):i.get(this)._upgradeWhenDefined(this,o,!0)}disconnectedCallback(){const t=n.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):i.get(this)._upgradeWhenDefined(this,o,!1)}adoptedCallback(){const t=n.get(this);t?.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)}},h=(t,o,r)=>{if(0===o.size||void 0===r)return;const e=t.prototype.setAttribute;e&&(t.prototype.setAttribute=function(t,n){const i=t.toLowerCase();if(o.has(i)){const t=this.getAttribute(i);e.call(this,i,n),r.call(this,i,t,n)}else e.call(this,i,n)});const n=t.prototype.removeAttribute;n&&(t.prototype.removeAttribute=function(t){const e=t.toLowerCase();if(o.has(e)){const t=this.getAttribute(e);n.call(this,e),r.call(this,e,t,null)}else n.call(this,e)})},d=o=>{const r=Object.getPrototypeOf(o);if(r!==window.HTMLElement)return r===t||"HTMLElement"===r?.prototype?.constructor?.name?Object.setPrototypeOf(o,window.HTMLElement):d(r)},p=(t,o,r=!1)=>{Object.setPrototypeOf(t,o.elementClass.prototype),n.set(t,o),c=t;try{new o.elementClass}catch(t){d(o.elementClass),new o.elementClass}o.observedAttributes.forEach((r=>{t.hasAttribute(r)&&o.attributeChangedCallback.call(t,r,null,t.getAttribute(r))})),r&&o.connectedCallback&&t.isConnected&&o.connectedCallback.call(t)},y=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const o=y.apply(this,arguments);return t.customElements&&(o.customElements=t.customElements),o};let b=[document];const g=(t,o,r=void 0)=>{const e=(r?Object.getPrototypeOf(r):t.prototype)[o];t.prototype[o]=function(){b.push(this);const t=e.apply(r||this,arguments);return void 0!==t&&s.set(t,this),b.pop(),t}};g(ShadowRoot,"createElement",document),g(ShadowRoot,"importNode",document),g(Element,"insertAdjacentHTML");const v=(t,o)=>{const r=Object.getOwnPropertyDescriptor(t.prototype,o);Object.defineProperty(t.prototype,o,{...r,set(t){b.push(this),r.set.call(this,t),b.pop()}})};if(v(Element,"innerHTML"),v(ShadowRoot,"innerHTML"),Object.defineProperty(window,"customElements",{value:new CustomElementRegistry,configurable:!0,writable:!0}),window.ElementInternals&&window.ElementInternals.prototype.setFormValue){const t=new WeakMap,o=HTMLElement.prototype.attachInternals,r=["setFormValue","setValidity","checkValidity","reportValidity"];HTMLElement.prototype.attachInternals=function(...r){const e=o.call(this,...r);return t.set(e,this),e},r.forEach((o=>{const r=window.ElementInternals.prototype,e=r[o];r[o]=function(...o){const r=t.get(this);if(!0!==n.get(r).formAssociated)throw new DOMException(`Failed to execute ${e} on 'ElementInternals': The target element is not a form-associated custom element.`);e?.call(this,...o)}}));class e extends Array{constructor(t){super(...t),this._elements=t}get value(){return this._elements.find((t=>!0===t.checked))?.value||""}}class i{constructor(t){const o=new Map;t.forEach(((t,r)=>{const e=t.getAttribute("name"),n=o.get(e)||[];this[+r]=t,n.push(t),o.set(e,n)})),this.length=t.length,o.forEach(((t,o)=>{t&&(1===t.length?this[o]=t[0]:this[o]=new e(t))}))}namedItem(t){return this[t]}}const a=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get:function(){const t=a.get.call(this,[]),o=[];for(const r of t){const t=n.get(r);t&&!0!==t.formAssociated||o.push(r)}return new i(o)}})}}try{window.customElements.define("custom-element",null)}catch(W){const t=window.customElements.define;window.customElements.define=(o,r,e)=>{if(null!==r)try{t.bind(window.customElements)(o,r,e)}catch(t){console.info(o,r,e,t)}}}class o extends Error{constructor(t,o,r){super(t),this.canceledPromiseResult=o,this.canceledPromiseError=r}}class r extends Promise{constructor(t){super(((r,e)=>t((t=>{this.isCanceled?e(new o("Promise has been canceled",t)):r(t)}),(t=>{this.isCanceled?e(new o("Promise has been canceled",void 0,t)):e(t)})))),this.isCanceled=!1}cancel(){this.isCanceled=!0}}class e{constructor(){this.loaders={},this.content={},this.clearTimeouts={},this.finalContent=new Set}register(t,o){this.loaders[t]=o,this.finalContent.delete(t)}registerFinal(t,o){this.loaders[t]=o,this.finalContent.add(t)}clearAll(){for(let t in this.content)this.clear(t)}clear(t){this.finalContent.has(t)||this.forceClear(t)}forceClear(t){this.clearClearTimeout(t),this.content[t]instanceof r&&this.content[t].cancel(),delete this.content[t]}clearClearTimeout(t){null!=this.clearTimeouts[t]&&(window.clearTimeout(this.clearTimeouts[t]),delete this.clearTimeouts[t])}set(t,o){this.forceClear(t),this.register(t,(async()=>o)),this.content[t]=o}setFinal(t,o){this.forceClear(t),this.registerFinal(t,(async()=>o)),this.content[t]=o}async get(t,o,e){if(void 0===this.content[t]){if(null==(o=null!=o?o:this.loaders[t]))throw new Error("Unknown cache key "+t);const n=(t=>new r(((o,r)=>t.then(o).catch(r))))(o());return this.content[t]=n,n.then((o=>(this.content[t]=o,null!=e&&(this.clearClearTimeout(t),this.clearTimeouts[t]=window.setTimeout((()=>this.clear(t)),e)),o)))}if(this.content[t]instanceof Error)throw this.content[t];return this.content[t]}isResolvedValue(t){return!(null==t||t instanceof Promise||t instanceof Error)}getNow(t){if(this.isResolvedValue(this.content[t]))return this.content[t]}has(t){return null!=this.content[t]}resolvedKeys(){return Object.keys(this.content).filter((t=>this.isResolvedValue(this.content[t])))}resolvedValues(){return Object.values(this.content).filter((t=>this.isResolvedValue(t)))}keys(){return Object.keys(this.content)}values(){return Object.values(this.content)}}class n{constructor(t=0){this.timeout=t,this.callbacks=[]}run(t,o){return this.callbacks=[t],this.debounce(o)}queue(t,o){return this.callbacks.push(t),this.debounce(o)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(t){return null==this.promise&&(this.promise=new Promise(((t,o)=>{this.resolvePromise=t,this.rejectPromise=o}))),this.clearTimeout(),this._debounce=window.setTimeout((()=>this.runCallbacks()),null!=t?t:this.timeout),this.promise}async runCallbacks(){var t,o;const r=[...this.callbacks];this.callbacks=[];const e=null!==(t=this.rejectPromise)&&void 0!==t?t:()=>null,n=null!==(o=this.resolvePromise)&&void 0!==o?o:()=>null;this.clearPromise();for(let t of r)try{await t()}catch(t){return void e(t)}n(!0)}clearTimeout(){null!=this._debounce&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}}
18
18
  /**
19
19
  * @license
20
20
  * Copyright 2017 Google LLC
@@ -24,7 +24,7 @@ if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,o=window.cust
24
24
  * @license
25
25
  * Copyright 2021 Google LLC
26
26
  * SPDX-License-Identifier: BSD-3-Clause
27
- */}var c;null===(c=window.HTMLSlotElement)||void 0===c||c.prototype.assignedElements;const s=t=>new Promise((o=>setTimeout(o,t)));function l(t,o){try{return function(t,o){if(t===o)return!0;if(t&&o&&"object"==typeof t&&"object"==typeof o){if(t.constructor!==o.constructor)return!1;var r,e,n;if(Array.isArray(t)){if((r=t.length)!=o.length)return!1;for(e=r;0!=e--;)if(!l(t[e],o[e]))return!1;return!0}if(t instanceof Map&&o instanceof Map){if(t.size!==o.size)return!1;for(e of t.entries())if(!o.has(e[0]))return!1;for(e of t.entries())if(!l(e[1],o.get(e[0])))return!1;return!0}if(t instanceof Set&&o instanceof Set){if(t.size!==o.size)return!1;for(e of t.entries())if(!o.has(e[0]))return!1;return!0}if(t.constructor===RegExp)return t.source===o.source&&t.flags===o.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===o.valueOf();if((r=(n=Object.keys(t)).length)!==Object.keys(o).length)return!1;for(e=r;0!=e--;)if(!Object.prototype.hasOwnProperty.call(o,n[e]))return!1;for(e=r;0!=e--;){var i=n[e];if(!l(t[i],o[i]))return!1}return!0}return t!=t&&o!=o}(t,o)}catch(t){return!1}}const f=t=>o=>{window.customElements.get(t)||window.customElements.define(t,o)};function u(t,o){const r=()=>JSON.parse(JSON.stringify(t));return a({type:Object,converter:{fromAttribute:t=>{if(null==t)return r();try{return JSON.parse(t)}catch{return r()}},toAttribute:t=>JSON.stringify(t)},hasChanged:(t,o)=>!l(t,o),...null!=o?o:{}})}
27
+ */}var s;null===(s=window.HTMLSlotElement)||void 0===s||s.prototype.assignedElements;const c=t=>new Promise((o=>setTimeout(o,t)));function l(t,o){try{return function(t,o){if(t===o)return!0;if(t&&o&&"object"==typeof t&&"object"==typeof o){if(t.constructor!==o.constructor)return!1;var r,e,n;if(Array.isArray(t)){if((r=t.length)!=o.length)return!1;for(e=r;0!=e--;)if(!l(t[e],o[e]))return!1;return!0}if(t instanceof Map&&o instanceof Map){if(t.size!==o.size)return!1;for(e of t.entries())if(!o.has(e[0]))return!1;for(e of t.entries())if(!l(e[1],o.get(e[0])))return!1;return!0}if(t instanceof Set&&o instanceof Set){if(t.size!==o.size)return!1;for(e of t.entries())if(!o.has(e[0]))return!1;return!0}if(t.constructor===RegExp)return t.source===o.source&&t.flags===o.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===o.valueOf();if((r=(n=Object.keys(t)).length)!==Object.keys(o).length)return!1;for(e=r;0!=e--;)if(!Object.prototype.hasOwnProperty.call(o,n[e]))return!1;for(e=r;0!=e--;){var i=n[e];if(!l(t[i],o[i]))return!1}return!0}return t!=t&&o!=o}(t,o)}catch(t){return!1}}const f=t=>o=>{window.customElements.get(t)||window.customElements.define(t,o)};function u(t,o){const r=()=>JSON.parse(JSON.stringify(t));return a({type:Object,converter:{fromAttribute:t=>{if(null==t)return r();try{return JSON.parse(t)}catch{return r()}},toAttribute:t=>JSON.stringify(t)},hasChanged:(t,o)=>!l(t,o),...null!=o?o:{}})}
28
28
  /**
29
29
  * @license
30
30
  * Copyright 2019 Google LLC
@@ -34,19 +34,19 @@ if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,o=window.cust
34
34
  * @license
35
35
  * Copyright 2017 Google LLC
36
36
  * SPDX-License-Identifier: BSD-3-Clause
37
- */;var N;const w=window,S=w.trustedTypes,E=S?S.emptyScript:"",R=w.reactiveElementPolyfillSupport,C={toAttribute(t,o){switch(o){case Boolean:t=t?E:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,o){let r=t;switch(o){case Boolean:r=null!==t;break;case Number:r=null===t?null:Number(t);break;case Object:case Array:try{r=JSON.parse(t)}catch(t){r=null}}return r}},U=(t,o)=>o!==t&&(o==o||t==t),x={attribute:!0,type:String,converter:C,reflect:!1,hasChanged:U};let I=class extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this.u()}static addInitializer(t){var o;this.finalize(),(null!==(o=this.h)&&void 0!==o?o:this.h=[]).push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((o,r)=>{const e=this._$Ep(r,o);void 0!==e&&(this._$Ev.set(e,r),t.push(e))})),t}static createProperty(t,o=x){if(o.state&&(o.attribute=!1),this.finalize(),this.elementProperties.set(t,o),!o.noAccessor&&!this.prototype.hasOwnProperty(t)){const r="symbol"==typeof t?Symbol():"__"+t,e=this.getPropertyDescriptor(t,r,o);void 0!==e&&Object.defineProperty(this.prototype,t,e)}}static getPropertyDescriptor(t,o,r){return{get(){return this[o]},set(e){const n=this[t];this[o]=e,this.requestUpdate(t,n,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||x}static finalize(){if(this.hasOwnProperty("finalized"))return!1;this.finalized=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),void 0!==t.h&&(this.h=[...t.h]),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,o=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const r of o)this.createProperty(r,t[r])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){const o=[];if(Array.isArray(t)){const r=new Set(t.flat(1/0).reverse());for(const t of r)o.unshift(O(t))}else void 0!==t&&o.push(O(t));return o}static _$Ep(t,o){const r=o.attribute;return!1===r?void 0:"string"==typeof r?r:"string"==typeof t?t.toLowerCase():void 0}u(){var t;this._$E_=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(t=this.constructor.h)||void 0===t||t.forEach((t=>t(this)))}addController(t){var o,r;(null!==(o=this._$ES)&&void 0!==o?o:this._$ES=[]).push(t),void 0!==this.renderRoot&&this.isConnected&&(null===(r=t.hostConnected)||void 0===r||r.call(t))}removeController(t){var o;null===(o=this._$ES)||void 0===o||o.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach(((t,o)=>{this.hasOwnProperty(o)&&(this._$Ei.set(o,this[o]),delete this[o])}))}createRenderRoot(){var t;const o=null!==(t=this.shadowRoot)&&void 0!==t?t:this.attachShadow(this.constructor.shadowRootOptions);return m(o,this.constructor.elementStyles),o}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var o;return null===(o=t.hostConnected)||void 0===o?void 0:o.call(t)}))}enableUpdating(t){}disconnectedCallback(){var t;null===(t=this._$ES)||void 0===t||t.forEach((t=>{var o;return null===(o=t.hostDisconnected)||void 0===o?void 0:o.call(t)}))}attributeChangedCallback(t,o,r){this._$AK(t,r)}_$EO(t,o,r=x){var e;const n=this.constructor._$Ep(t,r);if(void 0!==n&&!0===r.reflect){const i=(void 0!==(null===(e=r.converter)||void 0===e?void 0:e.toAttribute)?r.converter:C).toAttribute(o,r.type);this._$El=t,null==i?this.removeAttribute(n):this.setAttribute(n,i),this._$El=null}}_$AK(t,o){var r;const e=this.constructor,n=e._$Ev.get(t);if(void 0!==n&&this._$El!==n){const t=e.getPropertyOptions(n),i="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==(null===(r=t.converter)||void 0===r?void 0:r.fromAttribute)?t.converter:C;this._$El=n,this[n]=i.fromAttribute(o,t.type),this._$El=null}}requestUpdate(t,o,r){let e=!0;void 0!==t&&(((r=r||this.constructor.getPropertyOptions(t)).hasChanged||U)(this[t],o)?(this._$AL.has(t)||this._$AL.set(t,o),!0===r.reflect&&this._$El!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,r))):e=!1),!this.isUpdatePending&&e&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((t,o)=>this[o]=t)),this._$Ei=void 0);let o=!1;const r=this._$AL;try{o=this.shouldUpdate(r),o?(this.willUpdate(r),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var o;return null===(o=t.hostUpdate)||void 0===o?void 0:o.call(t)})),this.update(r)):this._$Ek()}catch(t){throw o=!1,this._$Ek(),t}o&&this._$AE(r)}willUpdate(t){}_$AE(t){var o;null===(o=this._$ES)||void 0===o||o.forEach((t=>{var o;return null===(o=t.hostUpdated)||void 0===o?void 0:o.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,o)=>this._$EO(o,this[o],t))),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}};
37
+ */;var N;const w=window,S=w.trustedTypes,E=S?S.emptyScript:"",C=w.reactiveElementPolyfillSupport,R={toAttribute(t,o){switch(o){case Boolean:t=t?E:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,o){let r=t;switch(o){case Boolean:r=null!==t;break;case Number:r=null===t?null:Number(t);break;case Object:case Array:try{r=JSON.parse(t)}catch(t){r=null}}return r}},U=(t,o)=>o!==t&&(o==o||t==t),x={attribute:!0,type:String,converter:R,reflect:!1,hasChanged:U};let I=class extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this.u()}static addInitializer(t){var o;this.finalize(),(null!==(o=this.h)&&void 0!==o?o:this.h=[]).push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((o,r)=>{const e=this._$Ep(r,o);void 0!==e&&(this._$Ev.set(e,r),t.push(e))})),t}static createProperty(t,o=x){if(o.state&&(o.attribute=!1),this.finalize(),this.elementProperties.set(t,o),!o.noAccessor&&!this.prototype.hasOwnProperty(t)){const r="symbol"==typeof t?Symbol():"__"+t,e=this.getPropertyDescriptor(t,r,o);void 0!==e&&Object.defineProperty(this.prototype,t,e)}}static getPropertyDescriptor(t,o,r){return{get(){return this[o]},set(e){const n=this[t];this[o]=e,this.requestUpdate(t,n,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||x}static finalize(){if(this.hasOwnProperty("finalized"))return!1;this.finalized=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),void 0!==t.h&&(this.h=[...t.h]),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,o=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const r of o)this.createProperty(r,t[r])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){const o=[];if(Array.isArray(t)){const r=new Set(t.flat(1/0).reverse());for(const t of r)o.unshift(O(t))}else void 0!==t&&o.push(O(t));return o}static _$Ep(t,o){const r=o.attribute;return!1===r?void 0:"string"==typeof r?r:"string"==typeof t?t.toLowerCase():void 0}u(){var t;this._$E_=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(t=this.constructor.h)||void 0===t||t.forEach((t=>t(this)))}addController(t){var o,r;(null!==(o=this._$ES)&&void 0!==o?o:this._$ES=[]).push(t),void 0!==this.renderRoot&&this.isConnected&&(null===(r=t.hostConnected)||void 0===r||r.call(t))}removeController(t){var o;null===(o=this._$ES)||void 0===o||o.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach(((t,o)=>{this.hasOwnProperty(o)&&(this._$Ei.set(o,this[o]),delete this[o])}))}createRenderRoot(){var t;const o=null!==(t=this.shadowRoot)&&void 0!==t?t:this.attachShadow(this.constructor.shadowRootOptions);return m(o,this.constructor.elementStyles),o}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var o;return null===(o=t.hostConnected)||void 0===o?void 0:o.call(t)}))}enableUpdating(t){}disconnectedCallback(){var t;null===(t=this._$ES)||void 0===t||t.forEach((t=>{var o;return null===(o=t.hostDisconnected)||void 0===o?void 0:o.call(t)}))}attributeChangedCallback(t,o,r){this._$AK(t,r)}_$EO(t,o,r=x){var e;const n=this.constructor._$Ep(t,r);if(void 0!==n&&!0===r.reflect){const i=(void 0!==(null===(e=r.converter)||void 0===e?void 0:e.toAttribute)?r.converter:R).toAttribute(o,r.type);this._$El=t,null==i?this.removeAttribute(n):this.setAttribute(n,i),this._$El=null}}_$AK(t,o){var r;const e=this.constructor,n=e._$Ev.get(t);if(void 0!==n&&this._$El!==n){const t=e.getPropertyOptions(n),i="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==(null===(r=t.converter)||void 0===r?void 0:r.fromAttribute)?t.converter:R;this._$El=n,this[n]=i.fromAttribute(o,t.type),this._$El=null}}requestUpdate(t,o,r){let e=!0;void 0!==t&&(((r=r||this.constructor.getPropertyOptions(t)).hasChanged||U)(this[t],o)?(this._$AL.has(t)||this._$AL.set(t,o),!0===r.reflect&&this._$El!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,r))):e=!1),!this.isUpdatePending&&e&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((t,o)=>this[o]=t)),this._$Ei=void 0);let o=!1;const r=this._$AL;try{o=this.shouldUpdate(r),o?(this.willUpdate(r),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var o;return null===(o=t.hostUpdate)||void 0===o?void 0:o.call(t)})),this.update(r)):this._$Ek()}catch(t){throw o=!1,this._$Ek(),t}o&&this._$AE(r)}willUpdate(t){}_$AE(t){var o;null===(o=this._$ES)||void 0===o||o.forEach((t=>{var o;return null===(o=t.hostUpdated)||void 0===o?void 0:o.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,o)=>this._$EO(o,this[o],t))),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}};
38
38
  /**
39
39
  * @license
40
40
  * Copyright 2017 Google LLC
41
41
  * SPDX-License-Identifier: BSD-3-Clause
42
42
  */
43
- var L;I.finalized=!0,I.elementProperties=new Map,I.elementStyles=[],I.shadowRootOptions={mode:"open"},null==R||R({ReactiveElement:I}),(null!==(N=w.reactiveElementVersions)&&void 0!==N?N:w.reactiveElementVersions=[]).push("1.6.1");const A=window,k=A.trustedTypes,W=k?k.createPolicy("lit-html",{createHTML:t=>t}):void 0,K="$lit$",T=`lit$${(Math.random()+"").slice(9)}$`,j="?"+T,P=`<${j}>`,M=document,F=()=>M.createComment(""),Z=t=>null===t||"object"!=typeof t&&"function"!=typeof t,B=Array.isArray,D="[ \t\n\f\r]",_=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,$=/-->/g,z=/>/g,G=RegExp(`>|${D}(?:([^\\s"'>=/]+)(${D}*=${D}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),H=/'/g,q=/"/g,V=/^(?:script|style|textarea|title)$/i,Y=(t=>(o,...r)=>({_$litType$:t,strings:o,values:r}))(1),X=Symbol.for("lit-noChange"),J=Symbol.for("lit-nothing"),Q=new WeakMap,tt=M.createTreeWalker(M,129,null,!1),ot=(t,o)=>{const r=t.length-1,e=[];let n,i=2===o?"<svg>":"",a=_;for(let o=0;o<r;o++){const r=t[o];let c,s,l=-1,f=0;for(;f<r.length&&(a.lastIndex=f,s=a.exec(r),null!==s);)f=a.lastIndex,a===_?"!--"===s[1]?a=$:void 0!==s[1]?a=z:void 0!==s[2]?(V.test(s[2])&&(n=RegExp("</"+s[2],"g")),a=G):void 0!==s[3]&&(a=G):a===G?">"===s[0]?(a=null!=n?n:_,l=-1):void 0===s[1]?l=-2:(l=a.lastIndex-s[2].length,c=s[1],a=void 0===s[3]?G:'"'===s[3]?q:H):a===q||a===H?a=G:a===$||a===z?a=_:(a=G,n=void 0);const u=a===G&&t[o+1].startsWith("/>")?" ":"";i+=a===_?r+P:l>=0?(e.push(c),r.slice(0,l)+K+r.slice(l)+T+u):r+T+(-2===l?(e.push(void 0),o):u)}const c=i+(t[r]||"<?>")+(2===o?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==W?W.createHTML(c):c,e]};class rt{constructor({strings:t,_$litType$:o},r){let e;this.parts=[];let n=0,i=0;const a=t.length-1,c=this.parts,[s,l]=ot(t,o);if(this.el=rt.createElement(s,r),tt.currentNode=this.el.content,2===o){const t=this.el.content,o=t.firstChild;o.remove(),t.append(...o.childNodes)}for(;null!==(e=tt.nextNode())&&c.length<a;){if(1===e.nodeType){if(e.hasAttributes()){const t=[];for(const o of e.getAttributeNames())if(o.endsWith(K)||o.startsWith(T)){const r=l[i++];if(t.push(o),void 0!==r){const t=e.getAttribute(r.toLowerCase()+K).split(T),o=/([.?@])?(.*)/.exec(r);c.push({type:1,index:n,name:o[2],strings:t,ctor:"."===o[1]?at:"?"===o[1]?st:"@"===o[1]?lt:it})}else c.push({type:6,index:n})}for(const o of t)e.removeAttribute(o)}if(V.test(e.tagName)){const t=e.textContent.split(T),o=t.length-1;if(o>0){e.textContent=k?k.emptyScript:"";for(let r=0;r<o;r++)e.append(t[r],F()),tt.nextNode(),c.push({type:2,index:++n});e.append(t[o],F())}}}else if(8===e.nodeType)if(e.data===j)c.push({type:2,index:n});else{let t=-1;for(;-1!==(t=e.data.indexOf(T,t+1));)c.push({type:7,index:n}),t+=T.length-1}n++}}static createElement(t,o){const r=M.createElement("template");return r.innerHTML=t,r}}function et(t,o,r=t,e){var n,i,a,c;if(o===X)return o;let s=void 0!==e?null===(n=r._$Co)||void 0===n?void 0:n[e]:r._$Cl;const l=Z(o)?void 0:o._$litDirective$;return(null==s?void 0:s.constructor)!==l&&(null===(i=null==s?void 0:s._$AO)||void 0===i||i.call(s,!1),void 0===l?s=void 0:(s=new l(t),s._$AT(t,r,e)),void 0!==e?(null!==(a=(c=r)._$Co)&&void 0!==a?a:c._$Co=[])[e]=s:r._$Cl=s),void 0!==s&&(o=et(t,s._$AS(t,o.values),s,e)),o}let nt=class t{constructor(t,o,r,e){var n;this.type=2,this._$AH=J,this._$AN=void 0,this._$AA=t,this._$AB=o,this._$AM=r,this.options=e,this._$Cp=null===(n=null==e?void 0:e.isConnected)||void 0===n||n}get _$AU(){var t,o;return null!==(o=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==o?o:this._$Cp}get parentNode(){let t=this._$AA.parentNode;const o=this._$AM;return void 0!==o&&11===(null==t?void 0:t.nodeType)&&(t=o.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,o=this){t=et(this,t,o),Z(t)?t===J||null==t||""===t?(this._$AH!==J&&this._$AR(),this._$AH=J):t!==this._$AH&&t!==X&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>B(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==J&&Z(this._$AH)?this._$AA.nextSibling.data=t:this.$(M.createTextNode(t)),this._$AH=t}g(t){var o;const{values:r,_$litType$:e}=t,n="number"==typeof e?this._$AC(t):(void 0===e.el&&(e.el=rt.createElement(e.h,this.options)),e);if((null===(o=this._$AH)||void 0===o?void 0:o._$AD)===n)this._$AH.v(r);else{const t=new class{constructor(t,o){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=o}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){var o;const{el:{content:r},parts:e}=this._$AD,n=(null!==(o=null==t?void 0:t.creationScope)&&void 0!==o?o:M).importNode(r,!0);tt.currentNode=n;let i=tt.nextNode(),a=0,c=0,s=e[0];for(;void 0!==s;){if(a===s.index){let o;2===s.type?o=new nt(i,i.nextSibling,this,t):1===s.type?o=new s.ctor(i,s.name,s.strings,this,t):6===s.type&&(o=new ft(i,this,t)),this._$AV.push(o),s=e[++c]}a!==(null==s?void 0:s.index)&&(i=tt.nextNode(),a++)}return n}v(t){let o=0;for(const r of this._$AV)void 0!==r&&(void 0!==r.strings?(r._$AI(t,r,o),o+=r.strings.length-2):r._$AI(t[o])),o++}}(n,this),o=t.u(this.options);t.v(r),this.$(o),this._$AH=t}}_$AC(t){let o=Q.get(t.strings);return void 0===o&&Q.set(t.strings,o=new rt(t)),o}T(o){B(this._$AH)||(this._$AH=[],this._$AR());const r=this._$AH;let e,n=0;for(const i of o)n===r.length?r.push(e=new t(this.k(F()),this.k(F()),this,this.options)):e=r[n],e._$AI(i),n++;n<r.length&&(this._$AR(e&&e._$AB.nextSibling,n),r.length=n)}_$AR(t=this._$AA.nextSibling,o){var r;for(null===(r=this._$AP)||void 0===r||r.call(this,!1,!0,o);t&&t!==this._$AB;){const o=t.nextSibling;t.remove(),t=o}}setConnected(t){var o;void 0===this._$AM&&(this._$Cp=t,null===(o=this._$AP)||void 0===o||o.call(this,t))}},it=class{constructor(t,o,r,e,n){this.type=1,this._$AH=J,this._$AN=void 0,this.element=t,this.name=o,this._$AM=e,this.options=n,r.length>2||""!==r[0]||""!==r[1]?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=J}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,o=this,r,e){const n=this.strings;let i=!1;if(void 0===n)t=et(this,t,o,0),i=!Z(t)||t!==this._$AH&&t!==X,i&&(this._$AH=t);else{const e=t;let a,c;for(t=n[0],a=0;a<n.length-1;a++)c=et(this,e[r+a],o,a),c===X&&(c=this._$AH[a]),i||(i=!Z(c)||c!==this._$AH[a]),c===J?t=J:t!==J&&(t+=(null!=c?c:"")+n[a+1]),this._$AH[a]=c}i&&!e&&this.j(t)}j(t){t===J?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}},at=class extends it{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===J?void 0:t}};const ct=k?k.emptyScript:"";let st=class extends it{constructor(){super(...arguments),this.type=4}j(t){t&&t!==J?this.element.setAttribute(this.name,ct):this.element.removeAttribute(this.name)}},lt=class extends it{constructor(t,o,r,e,n){super(t,o,r,e,n),this.type=5}_$AI(t,o=this){var r;if((t=null!==(r=et(this,t,o,0))&&void 0!==r?r:J)===X)return;const e=this._$AH,n=t===J&&e!==J||t.capture!==e.capture||t.once!==e.once||t.passive!==e.passive,i=t!==J&&(e===J||n);n&&this.element.removeEventListener(this.name,this,e),i&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var o,r;"function"==typeof this._$AH?this._$AH.call(null!==(r=null===(o=this.options)||void 0===o?void 0:o.host)&&void 0!==r?r:this.element,t):this._$AH.handleEvent(t)}},ft=class{constructor(t,o,r){this.element=t,this.type=6,this._$AN=void 0,this._$AM=o,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(t){et(this,t)}};const ut=A.litHtmlPolyfillSupport;null==ut||ut(rt,nt),(null!==(L=A.litHtmlVersions)&&void 0!==L?L:A.litHtmlVersions=[]).push("2.7.3");
43
+ var L;I.finalized=!0,I.elementProperties=new Map,I.elementStyles=[],I.shadowRootOptions={mode:"open"},null==C||C({ReactiveElement:I}),(null!==(N=w.reactiveElementVersions)&&void 0!==N?N:w.reactiveElementVersions=[]).push("1.6.1");const A=window,k=A.trustedTypes,W=k?k.createPolicy("lit-html",{createHTML:t=>t}):void 0,K="$lit$",T=`lit$${(Math.random()+"").slice(9)}$`,j="?"+T,M=`<${j}>`,P=document,F=()=>P.createComment(""),Z=t=>null===t||"object"!=typeof t&&"function"!=typeof t,B=Array.isArray,D="[ \t\n\f\r]",_=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,$=/-->/g,z=/>/g,G=RegExp(`>|${D}(?:([^\\s"'>=/]+)(${D}*=${D}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),H=/'/g,q=/"/g,Y=/^(?:script|style|textarea|title)$/i,V=(t=>(o,...r)=>({_$litType$:t,strings:o,values:r}))(1),X=Symbol.for("lit-noChange"),J=Symbol.for("lit-nothing"),Q=new WeakMap,tt=P.createTreeWalker(P,129,null,!1),ot=(t,o)=>{const r=t.length-1,e=[];let n,i=2===o?"<svg>":"",a=_;for(let o=0;o<r;o++){const r=t[o];let s,c,l=-1,f=0;for(;f<r.length&&(a.lastIndex=f,c=a.exec(r),null!==c);)f=a.lastIndex,a===_?"!--"===c[1]?a=$:void 0!==c[1]?a=z:void 0!==c[2]?(Y.test(c[2])&&(n=RegExp("</"+c[2],"g")),a=G):void 0!==c[3]&&(a=G):a===G?">"===c[0]?(a=null!=n?n:_,l=-1):void 0===c[1]?l=-2:(l=a.lastIndex-c[2].length,s=c[1],a=void 0===c[3]?G:'"'===c[3]?q:H):a===q||a===H?a=G:a===$||a===z?a=_:(a=G,n=void 0);const u=a===G&&t[o+1].startsWith("/>")?" ":"";i+=a===_?r+M:l>=0?(e.push(s),r.slice(0,l)+K+r.slice(l)+T+u):r+T+(-2===l?(e.push(void 0),o):u)}const s=i+(t[r]||"<?>")+(2===o?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==W?W.createHTML(s):s,e]};class rt{constructor({strings:t,_$litType$:o},r){let e;this.parts=[];let n=0,i=0;const a=t.length-1,s=this.parts,[c,l]=ot(t,o);if(this.el=rt.createElement(c,r),tt.currentNode=this.el.content,2===o){const t=this.el.content,o=t.firstChild;o.remove(),t.append(...o.childNodes)}for(;null!==(e=tt.nextNode())&&s.length<a;){if(1===e.nodeType){if(e.hasAttributes()){const t=[];for(const o of e.getAttributeNames())if(o.endsWith(K)||o.startsWith(T)){const r=l[i++];if(t.push(o),void 0!==r){const t=e.getAttribute(r.toLowerCase()+K).split(T),o=/([.?@])?(.*)/.exec(r);s.push({type:1,index:n,name:o[2],strings:t,ctor:"."===o[1]?at:"?"===o[1]?ct:"@"===o[1]?lt:it})}else s.push({type:6,index:n})}for(const o of t)e.removeAttribute(o)}if(Y.test(e.tagName)){const t=e.textContent.split(T),o=t.length-1;if(o>0){e.textContent=k?k.emptyScript:"";for(let r=0;r<o;r++)e.append(t[r],F()),tt.nextNode(),s.push({type:2,index:++n});e.append(t[o],F())}}}else if(8===e.nodeType)if(e.data===j)s.push({type:2,index:n});else{let t=-1;for(;-1!==(t=e.data.indexOf(T,t+1));)s.push({type:7,index:n}),t+=T.length-1}n++}}static createElement(t,o){const r=P.createElement("template");return r.innerHTML=t,r}}function et(t,o,r=t,e){var n,i,a,s;if(o===X)return o;let c=void 0!==e?null===(n=r._$Co)||void 0===n?void 0:n[e]:r._$Cl;const l=Z(o)?void 0:o._$litDirective$;return(null==c?void 0:c.constructor)!==l&&(null===(i=null==c?void 0:c._$AO)||void 0===i||i.call(c,!1),void 0===l?c=void 0:(c=new l(t),c._$AT(t,r,e)),void 0!==e?(null!==(a=(s=r)._$Co)&&void 0!==a?a:s._$Co=[])[e]=c:r._$Cl=c),void 0!==c&&(o=et(t,c._$AS(t,o.values),c,e)),o}let nt=class t{constructor(t,o,r,e){var n;this.type=2,this._$AH=J,this._$AN=void 0,this._$AA=t,this._$AB=o,this._$AM=r,this.options=e,this._$Cp=null===(n=null==e?void 0:e.isConnected)||void 0===n||n}get _$AU(){var t,o;return null!==(o=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==o?o:this._$Cp}get parentNode(){let t=this._$AA.parentNode;const o=this._$AM;return void 0!==o&&11===(null==t?void 0:t.nodeType)&&(t=o.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,o=this){t=et(this,t,o),Z(t)?t===J||null==t||""===t?(this._$AH!==J&&this._$AR(),this._$AH=J):t!==this._$AH&&t!==X&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>B(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==J&&Z(this._$AH)?this._$AA.nextSibling.data=t:this.$(P.createTextNode(t)),this._$AH=t}g(t){var o;const{values:r,_$litType$:e}=t,n="number"==typeof e?this._$AC(t):(void 0===e.el&&(e.el=rt.createElement(e.h,this.options)),e);if((null===(o=this._$AH)||void 0===o?void 0:o._$AD)===n)this._$AH.v(r);else{const t=new class{constructor(t,o){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=o}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){var o;const{el:{content:r},parts:e}=this._$AD,n=(null!==(o=null==t?void 0:t.creationScope)&&void 0!==o?o:P).importNode(r,!0);tt.currentNode=n;let i=tt.nextNode(),a=0,s=0,c=e[0];for(;void 0!==c;){if(a===c.index){let o;2===c.type?o=new nt(i,i.nextSibling,this,t):1===c.type?o=new c.ctor(i,c.name,c.strings,this,t):6===c.type&&(o=new ft(i,this,t)),this._$AV.push(o),c=e[++s]}a!==(null==c?void 0:c.index)&&(i=tt.nextNode(),a++)}return n}v(t){let o=0;for(const r of this._$AV)void 0!==r&&(void 0!==r.strings?(r._$AI(t,r,o),o+=r.strings.length-2):r._$AI(t[o])),o++}}(n,this),o=t.u(this.options);t.v(r),this.$(o),this._$AH=t}}_$AC(t){let o=Q.get(t.strings);return void 0===o&&Q.set(t.strings,o=new rt(t)),o}T(o){B(this._$AH)||(this._$AH=[],this._$AR());const r=this._$AH;let e,n=0;for(const i of o)n===r.length?r.push(e=new t(this.k(F()),this.k(F()),this,this.options)):e=r[n],e._$AI(i),n++;n<r.length&&(this._$AR(e&&e._$AB.nextSibling,n),r.length=n)}_$AR(t=this._$AA.nextSibling,o){var r;for(null===(r=this._$AP)||void 0===r||r.call(this,!1,!0,o);t&&t!==this._$AB;){const o=t.nextSibling;t.remove(),t=o}}setConnected(t){var o;void 0===this._$AM&&(this._$Cp=t,null===(o=this._$AP)||void 0===o||o.call(this,t))}},it=class{constructor(t,o,r,e,n){this.type=1,this._$AH=J,this._$AN=void 0,this.element=t,this.name=o,this._$AM=e,this.options=n,r.length>2||""!==r[0]||""!==r[1]?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=J}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,o=this,r,e){const n=this.strings;let i=!1;if(void 0===n)t=et(this,t,o,0),i=!Z(t)||t!==this._$AH&&t!==X,i&&(this._$AH=t);else{const e=t;let a,s;for(t=n[0],a=0;a<n.length-1;a++)s=et(this,e[r+a],o,a),s===X&&(s=this._$AH[a]),i||(i=!Z(s)||s!==this._$AH[a]),s===J?t=J:t!==J&&(t+=(null!=s?s:"")+n[a+1]),this._$AH[a]=s}i&&!e&&this.j(t)}j(t){t===J?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}},at=class extends it{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===J?void 0:t}};const st=k?k.emptyScript:"";let ct=class extends it{constructor(){super(...arguments),this.type=4}j(t){t&&t!==J?this.element.setAttribute(this.name,st):this.element.removeAttribute(this.name)}},lt=class extends it{constructor(t,o,r,e,n){super(t,o,r,e,n),this.type=5}_$AI(t,o=this){var r;if((t=null!==(r=et(this,t,o,0))&&void 0!==r?r:J)===X)return;const e=this._$AH,n=t===J&&e!==J||t.capture!==e.capture||t.once!==e.once||t.passive!==e.passive,i=t!==J&&(e===J||n);n&&this.element.removeEventListener(this.name,this,e),i&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var o,r;"function"==typeof this._$AH?this._$AH.call(null!==(r=null===(o=this.options)||void 0===o?void 0:o.host)&&void 0!==r?r:this.element,t):this._$AH.handleEvent(t)}},ft=class{constructor(t,o,r){this.element=t,this.type=6,this._$AN=void 0,this._$AM=o,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(t){et(this,t)}};const ut=A.litHtmlPolyfillSupport;null==ut||ut(rt,nt),(null!==(L=A.litHtmlVersions)&&void 0!==L?L:A.litHtmlVersions=[]).push("2.7.3");
44
44
  /**
45
45
  * @license
46
46
  * Copyright 2017 Google LLC
47
47
  * SPDX-License-Identifier: BSD-3-Clause
48
48
  */
49
- var ht,dt;let pt=class extends I{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t,o;const r=super.createRenderRoot();return null!==(t=(o=this.renderOptions).renderBefore)&&void 0!==t||(o.renderBefore=r.firstChild),r}update(t){const o=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,o,r)=>{var e,n;const i=null!==(e=null==r?void 0:r.renderBefore)&&void 0!==e?e:o;let a=i._$litPart$;if(void 0===a){const t=null!==(n=null==r?void 0:r.renderBefore)&&void 0!==n?n:null;i._$litPart$=a=new nt(o.insertBefore(F(),t),t,void 0,null!=r?r:{})}return a._$AI(t),a})(o,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!1)}render(){return X}};pt.finalized=!0,pt._$litElement$=!0,null===(ht=globalThis.litElementHydrateSupport)||void 0===ht||ht.call(globalThis,{LitElement:pt});const yt=globalThis.litElementPolyfillSupport;null==yt||yt({LitElement:pt}),(null!==(dt=globalThis.litElementVersions)&&void 0!==dt?dt:globalThis.litElementVersions=[]).push("3.3.2");const bt=t=>"string"==typeof t?g(t):t;class gt{static create(t,o,r,e){const n=t=>bt(null!=t?t:e),i=v`var(${bt(t)}, ${n(e)})`;return i.name=t,i.description=t,i.category=r,i.defaultValue=e,i.defaultCssValue=n,i.get=o=>v`var(${bt(t)}, ${n(o)})`,i.breadcrumb=()=>[],i.lastResortDefaultValue=()=>e,i}static extend(t,o,r,e){const n=t=>r.get(null!=t?t:e),i=v`var(${bt(t)}, ${n(e)})`;return i.name=t,i.description=o,i.category=r.category,i.fallbackVariable=r,i.defaultValue=e,i.defaultCssValue=n,i.get=o=>v`var(${bt(t)}, ${n(o)})`,i.breadcrumb=()=>[r.name,...r.breadcrumb()],i.lastResortDefaultValue=()=>null!=e?e:r.lastResortDefaultValue(),i}static external(t,o){const r=o=>t.fallbackVariable?t.fallbackVariable.get(null!=o?o:t.defaultValue):bt(null!=o?o:t.lastResortDefaultValue()),e=v`var(${bt(t.name)}, ${r(t.defaultValue)})`;return e.name=t.name,e.category=t.category,e.fallbackVariable=t.fallbackVariable,e.defaultValue=t.defaultValue,e.context=o,e.defaultCssValue=r,e.get=o=>v`var(${bt(t.name)}, ${r(o)})`,e.breadcrumb=()=>t.fallbackVariable?[t.fallbackVariable.name,...t.fallbackVariable.breadcrumb()]:[],e.lastResortDefaultValue=()=>t.lastResortDefaultValue(),e}}const vt={colorWhite:gt.create("--ft-color-white","","COLOR","#ffffff"),colorGray0:gt.create("--ft-color-gray-0","","COLOR","#71718e"),colorGray10:gt.create("--ft-color-gray-10","","COLOR","#fbfbfc"),colorGray20:gt.create("--ft-color-gray-20","","COLOR","#f2f2f5"),colorGray30:gt.create("--ft-color-gray-30","","COLOR","#e9e9ed"),colorGray40:gt.create("--ft-color-gray-40","","COLOR","#e0e0e6"),colorGray50:gt.create("--ft-color-gray-50","","COLOR","#cdcdd7"),colorGray60:gt.create("--ft-color-gray-60","","COLOR","#bbbbc9"),colorGray70:gt.create("--ft-color-gray-70","","COLOR","#a8a8ba"),colorGray80:gt.create("--ft-color-gray-80","","COLOR","#9696ab"),colorGray90:gt.create("--ft-color-gray-90","","COLOR","#83839d"),colorGray100:gt.create("--ft-color-gray-100","","COLOR","#62627c"),colorGray200:gt.create("--ft-color-gray-200","","COLOR","#545469"),colorGray300:gt.create("--ft-color-gray-300","","COLOR","#454557"),colorGray400:gt.create("--ft-color-gray-400","","COLOR","#363644"),colorGray500:gt.create("--ft-color-gray-500","","COLOR","#282832"),colorGray600:gt.create("--ft-color-gray-600","","COLOR","#19191f"),colorGray700:gt.create("--ft-color-gray-700","","COLOR","#0a0a0d"),colorBrand0:gt.create("--ft-color-brand-0","","COLOR","#9d207b"),colorBrand10:gt.create("--ft-color-brand-10","","COLOR","#f7edf4"),colorBrand20:gt.create("--ft-color-brand-20","","COLOR","#ebcfe4"),colorBrand30:gt.create("--ft-color-brand-30","","COLOR","#dfb2d3"),colorBrand40:gt.create("--ft-color-brand-40","","COLOR","#d395c2"),colorBrand50:gt.create("--ft-color-brand-50","","COLOR","#c778b1"),colorBrand60:gt.create("--ft-color-brand-60","","COLOR","#ba5ba1"),colorBrand70:gt.create("--ft-color-brand-70","","COLOR","#ae3e90"),colorBrand100:gt.create("--ft-color-brand-100","","COLOR","#8d1d6e"),colorBrand200:gt.create("--ft-color-brand-200","","COLOR","#78185e"),colorBrand300:gt.create("--ft-color-brand-300","","COLOR","#62144d"),colorBrand400:gt.create("--ft-color-brand-400","","COLOR","#4d103c"),colorBrand500:gt.create("--ft-color-brand-500","","COLOR","#380b2c"),colorBrand600:gt.create("--ft-color-brand-600","","COLOR","#23071b"),colorBrand700:gt.create("--ft-color-brand-700","","COLOR","#0d030b"),colorCyan0:gt.create("--ft-color-cyan-0","","COLOR","#0e98b4"),colorCyan10:gt.create("--ft-color-cyan-10","","COLOR","#ebf6f9"),colorCyan20:gt.create("--ft-color-cyan-20","","COLOR","#cbe9ef"),colorCyan30:gt.create("--ft-color-cyan-30","","COLOR","#acdbe5"),colorCyan40:gt.create("--ft-color-cyan-40","","COLOR","#8ccedb"),colorCyan50:gt.create("--ft-color-cyan-50","","COLOR","#6dc0d1"),colorCyan60:gt.create("--ft-color-cyan-60","","COLOR","#4db3c8"),colorCyan70:gt.create("--ft-color-cyan-70","","COLOR","#2ea5be"),colorCyan100:gt.create("--ft-color-cyan-100","","COLOR","#0c849c"),colorCyan200:gt.create("--ft-color-cyan-200","","COLOR","#0a7085"),colorCyan300:gt.create("--ft-color-cyan-300","","COLOR","#085c6d"),colorCyan400:gt.create("--ft-color-cyan-400","","COLOR","#074856"),colorCyan500:gt.create("--ft-color-cyan-500","","COLOR","#05343e"),colorCyan600:gt.create("--ft-color-cyan-600","","COLOR","#032127"),colorCyan700:gt.create("--ft-color-cyan-700","","COLOR","#010d0f"),colorGreen0:gt.create("--ft-color-green-0","","COLOR","#21a274"),colorGreen10:gt.create("--ft-color-green-10","","COLOR","#edf7f3"),colorGreen20:gt.create("--ft-color-green-20","","COLOR","#cfebe1"),colorGreen30:gt.create("--ft-color-green-30","","COLOR","#b2dfcf"),colorGreen40:gt.create("--ft-color-green-40","","COLOR","#95d3bd"),colorGreen50:gt.create("--ft-color-green-50","","COLOR","#78c7ab"),colorGreen60:gt.create("--ft-color-green-60","","COLOR","#5bba98"),colorGreen70:gt.create("--ft-color-green-70","","COLOR","#3eae86"),colorGreen100:gt.create("--ft-color-green-100","","COLOR","#1d8d65"),colorGreen200:gt.create("--ft-color-green-200","","COLOR","#187856"),colorGreen300:gt.create("--ft-color-green-300","","COLOR","#146246"),colorGreen400:gt.create("--ft-color-green-400","","COLOR","#104d37"),colorGreen500:gt.create("--ft-color-green-500","","COLOR","#0b3828"),colorGreen600:gt.create("--ft-color-green-600","","COLOR","#072319"),colorGreen700:gt.create("--ft-color-green-700","","COLOR","#030d0a"),colorOrange0:gt.create("--ft-color-orange-0","","COLOR","#ee8d17"),colorOrange10:gt.create("--ft-color-orange-10","","COLOR","#fef6ec"),colorOrange20:gt.create("--ft-color-orange-20","","COLOR","#fbe7cd"),colorOrange30:gt.create("--ft-color-orange-30","","COLOR","#f9d8af"),colorOrange40:gt.create("--ft-color-orange-40","","COLOR","#f7c991"),colorOrange50:gt.create("--ft-color-orange-50","","COLOR","#f5ba72"),colorOrange60:gt.create("--ft-color-orange-60","","COLOR","#f2ab54"),colorOrange70:gt.create("--ft-color-orange-70","","COLOR","#f09c35"),colorOrange100:gt.create("--ft-color-orange-100","","COLOR","#cf7b14"),colorOrange200:gt.create("--ft-color-orange-200","","COLOR","#b06811"),colorOrange300:gt.create("--ft-color-orange-300","","COLOR","#90560e"),colorOrange400:gt.create("--ft-color-orange-400","","COLOR","#71430b"),colorOrange500:gt.create("--ft-color-orange-500","","COLOR","#523108"),colorOrange600:gt.create("--ft-color-orange-600","","COLOR","#331e05"),colorOrange700:gt.create("--ft-color-orange-700","","COLOR","#140c02"),colorRed0:gt.create("--ft-color-red-0","","COLOR","#b40e2c"),colorRed10:gt.create("--ft-color-red-10","","COLOR","#f9ebed"),colorRed20:gt.create("--ft-color-red-20","","COLOR","#efcbd2"),colorRed30:gt.create("--ft-color-red-30","","COLOR","#e5acb6"),colorRed40:gt.create("--ft-color-red-40","","COLOR","#db8c9b"),colorRed50:gt.create("--ft-color-red-50","","COLOR","#d16d7f"),colorRed60:gt.create("--ft-color-red-60","","COLOR","#c84d63"),colorRed70:gt.create("--ft-color-red-70","","COLOR","#be2e48"),colorRed100:gt.create("--ft-color-red-100","","COLOR","#9c0c26"),colorRed200:gt.create("--ft-color-red-200","","COLOR","#850a20"),colorRed300:gt.create("--ft-color-red-300","","COLOR","#6d081b"),colorRed400:gt.create("--ft-color-red-400","","COLOR","#560715"),colorRed500:gt.create("--ft-color-red-500","","COLOR","#3e050f"),colorRed600:gt.create("--ft-color-red-600","","COLOR","#270309"),colorRed700:gt.create("--ft-color-red-700","","COLOR","#0f0104"),colorYellow0:gt.create("--ft-color-yellow-0","","COLOR","#E4C00C"),colorYellow10:gt.create("--ft-color-yellow-10","","COLOR","#fefae9"),colorYellow20:gt.create("--ft-color-yellow-20","","COLOR","#fcf4ca"),colorYellow30:gt.create("--ft-color-yellow-30","","COLOR","#faedaa"),colorYellow40:gt.create("--ft-color-yellow-40","","COLOR","#f9e78b"),colorYellow50:gt.create("--ft-color-yellow-50","","COLOR","#f7e06b"),colorYellow60:gt.create("--ft-color-yellow-60","","COLOR","#F4D63E"),colorYellow70:gt.create("--ft-color-yellow-70","","COLOR","#F3CE16"),colorYellow100:gt.create("--ft-color-yellow-100","","COLOR","#d3b10b"),colorYellow200:gt.create("--ft-color-yellow-200","","COLOR","#b3970a"),colorYellow300:gt.create("--ft-color-yellow-300","","COLOR","#947c08"),colorYellow400:gt.create("--ft-color-yellow-400","","COLOR","#746206"),colorYellow500:gt.create("--ft-color-yellow-500","","COLOR","#554705"),colorYellow600:gt.create("--ft-color-yellow-600","","COLOR","#352d03"),colorYellow700:gt.create("--ft-color-yellow-700","","COLOR","#161201"),colorUltramarine0:gt.create("--ft-color-ultramarine-0","","COLOR","#3C19E5"),colorUltramarine10:gt.create("--ft-color-ultramarine-10","","COLOR","#EDEAFD"),colorUltramarine20:gt.create("--ft-color-ultramarine-20","","COLOR","#D4CCF9"),colorUltramarine30:gt.create("--ft-color-ultramarine-30","","COLOR","#BBAFF6"),colorUltramarine40:gt.create("--ft-color-ultramarine-40","","COLOR","#A191F3"),colorUltramarine50:gt.create("--ft-color-ultramarine-50","","COLOR","#8873EF"),colorUltramarine60:gt.create("--ft-color-ultramarine-60","","COLOR","#6F55EC"),colorUltramarine70:gt.create("--ft-color-ultramarine-70","","COLOR","#5537E8"),colorUltramarine100:gt.create("--ft-color-ultramarine-100","","COLOR","#3416C7"),colorUltramarine200:gt.create("--ft-color-ultramarine-200","","COLOR","#2C13A9"),colorUltramarine300:gt.create("--ft-color-ultramarine-300","","COLOR","#250F8C"),colorUltramarine400:gt.create("--ft-color-ultramarine-400","","COLOR","#1D0C6E"),colorUltramarine500:gt.create("--ft-color-ultramarine-500","","COLOR","#150950"),colorUltramarine600:gt.create("--ft-color-ultramarine-600","","COLOR","#0D0532"),colorUltramarine700:gt.create("--ft-color-ultramarine-700","","COLOR","#050215"),colorAvocado0:gt.create("--ft-color-avocado-0","","COLOR","#98BD28"),colorAvocado10:gt.create("--ft-color-avocado-10","","COLOR","#F6F9EC"),colorAvocado20:gt.create("--ft-color-avocado-20","","COLOR","#E8F0D0"),colorAvocado30:gt.create("--ft-color-avocado-30","","COLOR","#DBE8B4"),colorAvocado40:gt.create("--ft-color-avocado-40","","COLOR","#CEDF98"),colorAvocado50:gt.create("--ft-color-avocado-50","","COLOR","#C0D77C"),colorAvocado60:gt.create("--ft-color-avocado-60","","COLOR","#B3CE60"),colorAvocado70:gt.create("--ft-color-avocado-70","","COLOR","#A5C644"),colorAvocado100:gt.create("--ft-color-avocado-100","","COLOR","#84A423"),colorAvocado200:gt.create("--ft-color-avocado-200","","COLOR","#708C1E"),colorAvocado300:gt.create("--ft-color-avocado-300","","COLOR","#5D7318"),colorAvocado400:gt.create("--ft-color-avocado-400","","COLOR","#495B13"),colorAvocado500:gt.create("--ft-color-avocado-500","","COLOR","#35420E"),colorAvocado600:gt.create("--ft-color-avocado-600","","COLOR","#212A09"),colorAvocado700:gt.create("--ft-color-avocado-700","","COLOR","#0E1104"),colorBrown0:gt.create("--ft-color-brown-0","","COLOR","#B26F4D"),colorBrown10:gt.create("--ft-color-brown-10","","COLOR","#F8F2EF"),colorBrown20:gt.create("--ft-color-brown-20","","COLOR","#EEDFD8"),colorBrown30:gt.create("--ft-color-brown-30","","COLOR","#E4CDC1"),colorBrown40:gt.create("--ft-color-brown-40","","COLOR","#DABAAA"),colorBrown50:gt.create("--ft-color-brown-50","","COLOR","#D0A792"),colorBrown60:gt.create("--ft-color-brown-60","","COLOR","#C6947B"),colorBrown70:gt.create("--ft-color-brown-70","","COLOR","#BC8264"),colorBrown100:gt.create("--ft-color-brown-100","","COLOR","#9B6143"),colorBrown200:gt.create("--ft-color-brown-200","","COLOR","#845239"),colorBrown300:gt.create("--ft-color-brown-300","","COLOR","#6D442F"),colorBrown400:gt.create("--ft-color-brown-400","","COLOR","#553525"),colorBrown500:gt.create("--ft-color-brown-500","","COLOR","#3E271B"),colorBrown600:gt.create("--ft-color-brown-600","","COLOR","#271811"),colorBrown700:gt.create("--ft-color-brown-700","","COLOR","#100A07"),spacing1:gt.create("--ft-spacing-1","","SIZE","0.25rem"),spacing2:gt.create("--ft-spacing-2","","SIZE","calc(var(--ft-spacing-2, 0.25rem)*2)"),spacing3:gt.create("--ft-spacing-3","","SIZE","calc(var(--ft-spacing-3, 0.25rem)*3)"),spacing4:gt.create("--ft-spacing-4","","SIZE","calc(var(--ft-spacing-4, 0.25rem)*4)"),spacing5:gt.create("--ft-spacing-5","","SIZE","calc(var(--ft-spacing-5, 0.25rem)*5)"),spacing6:gt.create("--ft-spacing-6","","SIZE","calc(var(--ft-spacing-6, 0.25rem)*6)"),spacing8:gt.create("--ft-spacing-8","","SIZE","calc(var(--ft-spacing-8, 0.25rem)*8)"),spacing10:gt.create("--ft-spacing-10","","SIZE","calc(var(--ft-spacing-10, 0.25rem)*10)"),spacing12:gt.create("--ft-spacing-12","","SIZE","calc(var(--ft-spacing-12, 0.25rem)*12)"),spacing16:gt.create("--ft-spacing-16","","SIZE","calc(var(--ft-spacing-16, 0.25rem)*16)"),spacing20:gt.create("--ft-spacing-20","","SIZE","calc(var(--ft-spacing-20, 0.25rem)*20)"),spacing24:gt.create("--ft-spacing-24","","SIZE","calc(var(--ft-spacing-24, 0.25rem)*24)"),spacing28:gt.create("--ft-spacing-28","","SIZE","calc(var(--ft-spacing-28, 0.25rem)*28)"),spacing32:gt.create("--ft-spacing-32","","SIZE","calc(var(--ft-spacing-32, 0.25rem)*32)"),spacing05:gt.create("--ft-spacing-0-5","","SIZE","calc(var(--ft-spacing-0-5, 0.25rem)*0.5)"),borderRadiusS:gt.create("--ft-border-radius-s","","SIZE","4px"),borderRadiusM:gt.create("--ft-border-radius-m","","SIZE","8px"),borderRadiusL:gt.create("--ft-border-radius-l","","SIZE","12px"),borderRadiusXl:gt.create("--ft-border-radius-xl","","SIZE","16px"),borderRadiusPill:gt.create("--ft-border-radius-pill","","SIZE","999px"),borderRadiusRound:gt.create("--ft-border-radius-round","","SIZE","50%"),iconSize1:gt.create("--ft-icon-size-1","","SIZE","12px"),iconSize2:gt.create("--ft-icon-size-2","","SIZE","16px"),iconSize3:gt.create("--ft-icon-size-3","","SIZE","20px"),iconSize4:gt.create("--ft-icon-size-4","","SIZE","24px"),iconSize5:gt.create("--ft-icon-size-5","","SIZE","32px"),iconSize6:gt.create("--ft-icon-size-6","","SIZE","48px"),opacity0:gt.create("--ft-opacity-0","","NUMBER","0"),opacity8:gt.create("--ft-opacity-8","","NUMBER","0.08"),opacity16:gt.create("--ft-opacity-16","","NUMBER","0.16"),opacity24:gt.create("--ft-opacity-24","","NUMBER","0.24"),opacity40:gt.create("--ft-opacity-40","","NUMBER","0.4"),opacity80:gt.create("--ft-opacity-80","","NUMBER","0.8")};gt.create("--ft-typography-display-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-display-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-display-lineHeight","","SIZE","120%"),gt.create("--ft-typography-display-fontSize","","SIZE","2.5rem"),gt.create("--ft-typography-display-letterSpacing","","SIZE","-0.02em"),gt.create("--ft-typography-display-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-display-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-display-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-display-textCase","","UNKNOWN","none"),gt.create("--ft-typography-title-1-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-title-1-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-title-1-lineHeight","","SIZE","120%"),gt.create("--ft-typography-title-1-fontSize","","SIZE","2rem"),gt.create("--ft-typography-title-1-letterSpacing","","SIZE","-0.02em"),gt.create("--ft-typography-title-1-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-title-1-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-title-1-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-title-1-textCase","","UNKNOWN","none"),gt.create("--ft-typography-title-2-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-title-2-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-title-2-lineHeight","","SIZE","120%"),gt.create("--ft-typography-title-2-fontSize","","SIZE","1.5rem"),gt.create("--ft-typography-title-2-letterSpacing","","SIZE","-0.02em"),gt.create("--ft-typography-title-2-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-title-2-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-title-2-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-title-2-textCase","","UNKNOWN","none"),gt.create("--ft-typography-title-3-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-title-3-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-title-3-lineHeight","","SIZE","120%"),gt.create("--ft-typography-title-3-fontSize","","SIZE","1.25rem"),gt.create("--ft-typography-title-3-letterSpacing","","SIZE","-0.01em"),gt.create("--ft-typography-title-3-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-title-3-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-title-3-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-title-3-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-1-regular-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-1-regular-fontWeight","","UNKNOWN","400"),gt.create("--ft-typography-body-1-regular-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-1-regular-fontSize","","SIZE","1rem"),gt.create("--ft-typography-body-1-regular-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-1-regular-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-1-regular-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-1-regular-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-1-regular-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-1-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-1-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-body-1-medium-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-1-medium-fontSize","","SIZE","1rem"),gt.create("--ft-typography-body-1-medium-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-1-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-1-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-1-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-1-medium-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-1-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-1-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-body-1-semibold-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-1-semibold-fontSize","","SIZE","1rem"),gt.create("--ft-typography-body-1-semibold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-1-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-1-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-1-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-1-semibold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-2-regular-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-2-regular-fontWeight","","UNKNOWN","400"),gt.create("--ft-typography-body-2-regular-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-2-regular-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-body-2-regular-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-2-regular-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-2-regular-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-2-regular-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-2-regular-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-2-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-2-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-body-2-medium-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-2-medium-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-body-2-medium-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-2-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-2-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-2-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-2-medium-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-2-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-2-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-body-2-semibold-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-2-semibold-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-body-2-semibold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-2-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-2-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-2-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-2-semibold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-label-1-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-1-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-label-1-medium-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-1-medium-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-label-1-medium-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-1-medium-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-1-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-1-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-1-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-1-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-1-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-label-1-semibold-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-1-semibold-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-label-1-semibold-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-1-semibold-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-1-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-1-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-1-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-1-bold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-1-bold-fontWeight","","UNKNOWN","700"),gt.create("--ft-typography-label-1-bold-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-1-bold-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-label-1-bold-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-1-bold-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-1-bold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-1-bold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-1-bold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-2-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-2-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-label-2-medium-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-2-medium-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-label-2-medium-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-2-medium-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-2-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-2-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-2-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-2-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-2-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-label-2-semibold-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-2-semibold-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-label-2-semibold-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-2-semibold-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-2-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-2-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-2-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-2-bold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-2-bold-fontWeight","","UNKNOWN","700"),gt.create("--ft-typography-label-2-bold-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-2-bold-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-label-2-bold-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-2-bold-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-2-bold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-2-bold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-2-bold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-1-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-caption-1-medium-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-1-medium-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-caption-1-medium-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-1-medium-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-1-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-1-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-1-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-caption-1-semibold-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-1-semibold-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-caption-1-semibold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-1-semibold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-1-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-1-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-bold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-1-bold-fontWeight","","UNKNOWN","700"),gt.create("--ft-typography-caption-1-bold-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-1-bold-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-caption-1-bold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-1-bold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-bold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-1-bold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-1-bold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-2-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-caption-2-medium-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-2-medium-fontSize","","SIZE","0.6875rem"),gt.create("--ft-typography-caption-2-medium-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-2-medium-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-2-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-2-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-2-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-caption-2-semibold-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-2-semibold-fontSize","","SIZE","0.6875rem"),gt.create("--ft-typography-caption-2-semibold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-2-semibold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-2-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-2-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-bold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-2-bold-fontWeight","","UNKNOWN","700"),gt.create("--ft-typography-caption-2-bold-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-2-bold-fontSize","","SIZE","0.6875rem"),gt.create("--ft-typography-caption-2-bold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-2-bold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-bold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-2-bold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-2-bold-textDecoration","","UNKNOWN","none");const mt={backgroundActionPrimary:gt.extend("--ft-background-action-primary","Used as backgorund of primary action components.",vt.colorBrand0),backgroundErrorPrimary:gt.extend("--ft-background-error-primary","Used as background of error components.",vt.colorRed0),backgroundErrorSubtle:gt.extend("--ft-background-error-subtle","Used as background of subtle error components.",vt.colorRed10),backgroundInfoPrimary:gt.extend("--ft-background-info-primary","Used as background of information components.",vt.colorCyan200),backgroundInfoSubtle:gt.extend("--ft-background-info-subtle","Used as background of subtle information components.",vt.colorCyan10),backgroundWarningPrimary:gt.extend("--ft-background-warning-primary","Used as background of warning components.",vt.colorOrange300),backgroundWarningSubtle:gt.extend("--ft-background-warning-subtle","Used as background of subtle information components.",vt.colorOrange10),backgroundSuccessPrimary:gt.extend("--ft-background-success-primary","Used as background of success components.",vt.colorGreen200),backgroundSuccessSubtle:gt.extend("--ft-background-success-subtle","Used as background of subtle success components.",vt.colorGreen10),backgroundGlobalSurface:gt.extend("--ft-background-global-surface","Used as app background.",vt.colorWhite),backgroundGlobalOnSurface:gt.extend("--ft-background-global-on-surface","Used as background on element on the base background, like cards.",vt.colorGray10),backgroundGlobalOnSurfaceDark:gt.extend("--ft-background-global-on-surface-dark","Used as background on element that need background separation.",vt.colorGray30),contentActionPrimary:gt.extend("--ft-content-action-primary","Used on label of primary action on light surface.",vt.colorBrand0),contentWarningPrimary:gt.extend("--ft-content-warning-primary","Used on label of warning messages on light surface.",vt.colorOrange300),contentWarningIconOnly:gt.extend("--ft-content-warning-icon-only","Used on warning status icons alone",vt.colorOrange0),contentErrorPrimary:gt.extend("--ft-content-error-primary","Used on label of error messages on light surface.",vt.colorRed0),contentErrorIconOnly:gt.extend("--ft-content-error-icon-only","Used on error status icons alone",vt.colorRed0),contentInfoPrimary:gt.extend("--ft-content-info-primary","Used on label of information messages on light surface.",vt.colorCyan200),contentInfoIconOnly:gt.extend("--ft-content-info-icon-only","Used on info status icons alone",vt.colorCyan0),contentSuccessIconOnly:gt.extend("--ft-content-success-icon-only","Used on success status icons alone",vt.colorGreen0),contentSuccessPrimary:gt.extend("--ft-content-success-primary","Used on label of success messages on light surface.",vt.colorGreen200),contentGlobalPrimary:gt.extend("--ft-content-global-primary","Used for main content on the page.",vt.colorGray500),contentGlobalSecondary:gt.extend("--ft-content-global-secondary","Used for secondary content, often paired with primary content.\nAlso for action icons.",vt.colorGray200),contentGlobalSubtle:gt.extend("--ft-content-global-subtle","Used for placeholder, unselected items in a tab component or breadcrumb.",vt.colorGray0),contentGlobalOnColor:gt.extend("--ft-content-global-on-color","Used for content on a dominant color.",vt.colorWhite),borderActionPrimary:gt.extend("--ft-border-action-primary","Used as border for primary action components.",vt.colorBrand0),borderActionFocusRing:gt.extend("--ft-border-action-focus-ring","Focus ring is an additional border to indicate focus-visible state.",vt.colorCyan0),borderWarningPrimary:gt.extend("--ft-border-warning-primary","Used as border for warning components.",vt.colorOrange30),borderSuccessPrimary:gt.extend("--ft-border-success-primary","Used as border for success components.",vt.colorGreen30),borderErrorPrimary:gt.extend("--ft-border-error-primary","Used as border for error components.",vt.colorRed30),borderInfoPrimary:gt.extend("--ft-border-info-primary","Used as border for information components.",vt.colorCyan30),borderGlobalSubtle:gt.extend("--ft-border-global-subtle","Used as border to deliminate an area filled with background.on-surface and separators.",vt.colorGray30),borderGlobalPrimary:gt.extend("--ft-border-global-primary","Used as border for element like input.",vt.colorGray50),borderInputPrimary:gt.extend("--ft-border-input-primary","Used as border for checkboxes and radio buttons",vt.colorGray80)};gt.create("--ft-button-large-height","","SIZE","40px"),gt.extend("--ft-button-large-horizontal-padding","",vt.spacing4),gt.extend("--ft-button-large-gap","",vt.spacing2),gt.extend("--ft-button-large-border-radius","",vt.borderRadiusS),gt.extend("--ft-button-large-icon-size","",vt.iconSize3),gt.create("--ft-button-large-border-width","","SIZE","1px"),gt.create("--ft-button-large-focus-outline-offset","","SIZE","2px"),gt.create("--ft-button-large-focus-outline-width","","SIZE","2px"),gt.create("--ft-button-large-icon-only-width","","SIZE","40px"),gt.create("--ft-button-small-height","","SIZE","30px"),gt.extend("--ft-button-small-horizontal-padding","",vt.spacing3),gt.extend("--ft-button-small-gap","",vt.spacing2),gt.extend("--ft-button-small-border-radius","",vt.borderRadiusS),gt.extend("--ft-button-small-icon-size","",vt.iconSize2),gt.create("--ft-button-small-border-width","","SIZE","1px"),gt.create("--ft-button-small-focus-outline-offset","","SIZE","2px"),gt.create("--ft-button-small-focus-outline-width","","SIZE","2px"),gt.create("--ft-button-small-icon-only-width","","SIZE","30px"),gt.extend("--ft-button-primary-background-color","",mt.backgroundActionPrimary),gt.extend("--ft-button-primary-color","",mt.contentGlobalOnColor),gt.extend("--ft-button-primary-icon-color","",mt.contentGlobalOnColor),gt.extend("--ft-button-primary-state-layer-color","",mt.contentGlobalOnColor),gt.extend("--ft-button-primary-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-button-primary-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-button-primary-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-button-primary-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-button-focus-focus-ring-color","",mt.borderActionFocusRing),gt.create("--ft-button-tertiary-background-color","","COLOR","rgba(0,0,0,0)"),gt.extend("--ft-button-tertiary-color","",mt.contentActionPrimary),gt.extend("--ft-button-tertiary-icon-color","",mt.contentActionPrimary),gt.extend("--ft-button-tertiary-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-button-tertiary-state-layer-opacity-hover","",vt.opacity8),gt.extend("--ft-button-tertiary-state-layer-opacity-focus","",vt.opacity8),gt.extend("--ft-button-tertiary-state-layer-opacity-active","",vt.opacity16),gt.extend("--ft-button-tertiary-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-button-secondary-background-color","",vt.colorWhite),gt.extend("--ft-button-secondary-color","",mt.contentActionPrimary),gt.extend("--ft-button-secondary-icon-color","",mt.contentActionPrimary),gt.extend("--ft-button-secondary-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-button-secondary-state-layer-opacity-hover","",vt.opacity8),gt.extend("--ft-button-secondary-state-layer-opacity-focus","",vt.opacity8),gt.extend("--ft-button-secondary-state-layer-opacity-active","",vt.opacity16),gt.extend("--ft-button-secondary-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-button-secondary-border-color","",mt.borderActionPrimary),gt.create("--ft-button-neutral-background-color","","COLOR","rgba(0,0,0,0)"),gt.extend("--ft-button-neutral-icon-color","",mt.contentGlobalSecondary),gt.extend("--ft-button-neutral-color","",mt.contentGlobalSecondary),gt.extend("--ft-button-neutral-state-layer-color","",mt.contentGlobalSecondary),gt.extend("--ft-button-neutral-state-layer-opacity-hover","",vt.opacity8),gt.extend("--ft-button-neutral-state-layer-opacity-focus","",vt.opacity8),gt.extend("--ft-button-neutral-state-layer-opacity-active","",vt.opacity16),gt.extend("--ft-button-neutral-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-tabs-top-left-border-radius","",vt.borderRadiusS),gt.extend("--ft-tabs-top-right-border-radius","",vt.borderRadiusS),gt.extend("--ft-tabs-label-horizontal-padding","",vt.spacing4),gt.extend("--ft-tabs-label-vertical-padding","",vt.spacing3),gt.extend("--ft-tabs-label-gap","",vt.spacing1),gt.extend("--ft-switch-group-horizontal-padding","",vt.spacing1),gt.extend("--ft-switch-group-vertical-padding","",vt.spacing1),gt.extend("--ft-switch-group-gap","",vt.spacing1),gt.extend("--ft-switch-group-background-color","",mt.backgroundGlobalSurface),gt.extend("--ft-switch-group-border-color","",mt.borderGlobalSubtle),gt.create("--ft-switch-group-border-radius","","SIZE","6px"),gt.extend("--ft-switch-label-horizontal-padding","",vt.spacing2),gt.extend("--ft-switch-label-vertical-padding","",vt.spacing1),gt.extend("--ft-switch-icon-horizontal-padding","",vt.spacing1),gt.extend("--ft-switch-icon-vertical-padding","",vt.spacing1),gt.create("--ft-switch-focus-outline-width","","SIZE","2px"),gt.extend("--ft-switch-focus-focus-ring-color","",mt.borderActionFocusRing),gt.extend("--ft-switch-option-border-radius","",vt.borderRadiusS),gt.extend("--ft-switch-off-state-layer-opacity-hover","",vt.opacity8),gt.extend("--ft-switch-off-state-layer-opacity-focus","",vt.opacity8),gt.extend("--ft-switch-off-state-layer-opacity-active","",vt.opacity16),gt.extend("--ft-switch-off-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-switch-off-color","",mt.contentGlobalSubtle),gt.extend("--ft-switch-off-state-layer-color","",mt.contentGlobalSubtle),gt.extend("--ft-chart-1-light","for area color charts",vt.colorBrand40),gt.extend("--ft-chart-1-base","for line charts",vt.colorBrand0),gt.extend("--ft-chart-2-light","for area color charts",vt.colorYellow60),gt.extend("--ft-chart-2-base","for line charts",vt.colorYellow100),gt.extend("--ft-chart-3-light","",vt.colorUltramarine40),gt.extend("--ft-chart-3-base","",vt.colorUltramarine70),gt.extend("--ft-chart-4-light","",vt.colorCyan50),gt.extend("--ft-chart-4-base","",vt.colorCyan100),gt.extend("--ft-chart-5-light","",vt.colorRed40),gt.extend("--ft-chart-5-base","",vt.colorRed60),gt.extend("--ft-chart-6-light","",vt.colorGreen40),gt.extend("--ft-chart-6-base","",vt.colorGreen70),gt.extend("--ft-chart-7-light","",vt.colorOrange70),gt.extend("--ft-chart-7-base","",vt.colorOrange100),gt.extend("--ft-chart-8-light","",vt.colorAvocado70),gt.extend("--ft-chart-8-base","",vt.colorAvocado200),gt.extend("--ft-chart-9-light","",vt.colorBrown50),gt.extend("--ft-chart-9-base","",vt.colorBrown200),gt.extend("--ft-chart-10-light","",vt.colorGray50),gt.extend("--ft-chart-10-base","",vt.colorGray80),gt.extend("--ft-chart-monochrome-10","",vt.colorBrand10),gt.extend("--ft-chart-monochrome-20","",vt.colorBrand20),gt.extend("--ft-chart-monochrome-30","",vt.colorBrand40),gt.extend("--ft-chart-monochrome-40","",vt.colorBrand60),gt.extend("--ft-chart-monochrome-50","",vt.colorBrand0),gt.extend("--ft-chart-monochrome-60","",vt.colorBrand200),gt.extend("--ft-chip-large-horizontal-padding","",vt.spacing4),gt.extend("--ft-chip-large-vertical-padding","",vt.spacing2),gt.extend("--ft-chip-large-gap","",vt.spacing1),gt.create("--ft-chip-large-focus-outline-offset","","SIZE","2px"),gt.create("--ft-chip-large-focus-outline-width","","SIZE","2px"),gt.extend("--ft-chip-large-border-radius","",vt.borderRadiusPill),gt.create("--ft-chip-large-border-width","","SIZE","1px"),gt.extend("--ft-chip-large-icon-size","",vt.iconSize3),gt.extend("--ft-chip-medium-horizontal-padding","",vt.spacing3),gt.extend("--ft-chip-medium-vertical-padding","",vt.spacing1),gt.extend("--ft-chip-medium-gap","",vt.spacing1),gt.create("--ft-chip-medium-focus-outline-offset","","SIZE","2px"),gt.create("--ft-chip-medium-focus-outline-width","","SIZE","2px"),gt.extend("--ft-chip-medium-border-radius","",vt.borderRadiusPill),gt.create("--ft-chip-medium-border-width","","SIZE","1px"),gt.extend("--ft-chip-medium-icon-size","",vt.iconSize2),gt.extend("--ft-chip-small-horizontal-padding","",vt.spacing2),gt.extend("--ft-chip-small-vertical-padding","",vt.spacing05),gt.extend("--ft-chip-small-gap","",vt.spacing1),gt.create("--ft-chip-small-focus-outline-offset","","SIZE","2px"),gt.create("--ft-chip-small-focus-outline-width","","SIZE","2px"),gt.extend("--ft-chip-small-border-radius","",vt.borderRadiusPill),gt.create("--ft-chip-small-border-width","","SIZE","1px"),gt.extend("--ft-chip-small-icon-size","",vt.iconSize1),gt.extend("--ft-chip-neutral-background-color","",mt.backgroundGlobalOnSurface),gt.extend("--ft-chip-neutral-color","",mt.contentGlobalPrimary),gt.extend("--ft-chip-neutral-border-color","",mt.borderGlobalSubtle),gt.extend("--ft-chip-info-background-color","",mt.backgroundInfoSubtle),gt.extend("--ft-chip-info-color","",mt.contentInfoPrimary),gt.extend("--ft-chip-info-border-color","",mt.borderInfoPrimary),gt.extend("--ft-chip-success-background-color","",mt.backgroundSuccessSubtle),gt.extend("--ft-chip-success-color","",mt.contentSuccessPrimary),gt.extend("--ft-chip-success-border-color","",mt.borderSuccessPrimary),gt.extend("--ft-chip-warning-background-color","",mt.backgroundWarningSubtle),gt.extend("--ft-chip-warning-color","",mt.contentWarningPrimary),gt.extend("--ft-chip-warning-border-color","",mt.borderWarningPrimary),gt.extend("--ft-chip-error-background-color","",mt.backgroundErrorSubtle),gt.extend("--ft-chip-error-color","",mt.contentErrorPrimary),gt.extend("--ft-chip-error-border-color","",mt.borderErrorPrimary),gt.create("--ft-notice-border-width","","SIZE","1px"),gt.extend("--ft-notice-horizontal-padding","",vt.spacing2),gt.extend("--ft-notice-vertical-padding","",vt.spacing1),gt.extend("--ft-notice-border-radius","",vt.borderRadiusS),gt.extend("--ft-notice-gap","",vt.spacing2),gt.extend("--ft-notice-icon-size","",vt.iconSize3),gt.extend("--ft-notice-info-background-color","",mt.backgroundInfoSubtle),gt.extend("--ft-notice-info-border-color","",mt.borderInfoPrimary),gt.extend("--ft-notice-info-color","",mt.contentInfoPrimary),gt.extend("--ft-notice-warning-background-color","",mt.backgroundWarningSubtle),gt.extend("--ft-notice-warning-border-color","",mt.borderWarningPrimary),gt.extend("--ft-notice-warning-color","",mt.contentWarningPrimary),gt.extend("--ft-checkbox-label-color","",mt.contentGlobalPrimary),gt.extend("--ft-checkbox-checked-background-color","",mt.contentActionPrimary),gt.extend("--ft-checkbox-checked-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-checkbox-checked-color","",mt.contentGlobalOnColor),gt.extend("--ft-checkbox-checked-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-checkbox-checked-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-checkbox-checked-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-checkbox-checked-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-checkbox-unchecked-border-color","",vt.colorGray80),gt.extend("--ft-checkbox-unchecked-state-layer-color","",vt.colorGray80),gt.extend("--ft-checkbox-unchecked-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-checkbox-unchecked-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-checkbox-unchecked-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-checkbox-unchecked-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-checkbox-focus-focus-ring-color","",mt.borderActionFocusRing),gt.create("--ft-checkbox-focus-outline-offset","","SIZE","3px"),gt.create("--ft-checkbox-focus-outline-width","","SIZE","2px"),gt.extend("--ft-checkbox-gap","",vt.spacing3),gt.extend("--ft-toggle-off-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-toggle-off-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-toggle-off-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-toggle-off-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-toggle-off-background-color","",mt.contentGlobalSubtle),gt.extend("--ft-toggle-off-icon-color","",mt.contentGlobalSubtle),gt.extend("--ft-toggle-off-state-layer-color","",mt.contentGlobalSubtle),gt.extend("--ft-toggle-on-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-toggle-on-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-toggle-on-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-toggle-on-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-toggle-on-background-color","",mt.contentActionPrimary),gt.extend("--ft-toggle-on-icon-color","",mt.contentActionPrimary),gt.extend("--ft-toggle-on-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-toggle-label-color","",mt.contentGlobalPrimary),gt.extend("--ft-toggle-focus-focus-ring-color","",mt.borderActionFocusRing),gt.extend("--ft-toggle-gap","",vt.spacing3),gt.extend("--ft-radio-label-color","",mt.contentGlobalPrimary),gt.extend("--ft-radio-selected-color","",mt.contentActionPrimary),gt.extend("--ft-radio-selected-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-radio-selected-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-radio-selected-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-radio-selected-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-radio-selected-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-radio-unselected-state-layer-color","",vt.colorGray80),gt.extend("--ft-radio-unselected-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-radio-unselected-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-radio-unselected-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-radio-unselected-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-radio-focus-focus-ring-color","",mt.borderActionFocusRing),gt.create("--ft-radio-focus-outline-offset","","SIZE","3px"),gt.create("--ft-radio-focus-outline-width","","SIZE","2px"),gt.extend("--ft-radio-gap","",vt.spacing3),gt.extend("--ft-notification-icon-size","",vt.iconSize4),gt.extend("--ft-notification-horizontal-padding","",vt.spacing4),gt.extend("--ft-notification-vertical-padding","",vt.spacing4),gt.extend("--ft-notification-info-background-color","",mt.backgroundInfoSubtle),gt.extend("--ft-notification-info-color","",mt.contentInfoPrimary),gt.extend("--ft-notification-info-border-color","",mt.borderInfoPrimary),gt.extend("--ft-notification-success-background-color","",mt.backgroundSuccessSubtle),gt.extend("--ft-notification-success-color","",mt.contentSuccessPrimary),gt.extend("--ft-notification-success-border-color","",mt.borderSuccessPrimary),gt.extend("--ft-notification-warning-background-color","",mt.backgroundWarningSubtle),gt.extend("--ft-notification-warning-color","",mt.contentWarningPrimary),gt.extend("--ft-notification-warning-border-color","",mt.borderWarningPrimary),gt.extend("--ft-notification-error-background-color","",mt.backgroundErrorSubtle),gt.extend("--ft-notification-error-color","",mt.contentErrorPrimary),gt.extend("--ft-notification-error-border-color","",mt.borderErrorPrimary),gt.extend("--ft-notification-border-radius","",vt.borderRadiusPill),gt.create("--ft-notification-border-width","","SIZE","1px"),gt.extend("--ft-notification-gap-leading","",vt.spacing2),gt.extend("--ft-notification-gap-trailing","",vt.spacing8),gt.create("--ft-color-primary","","COLOR","#2196F3"),gt.create("--ft-color-primary-variant","","COLOR","#1976D2"),gt.create("--ft-color-secondary","","COLOR","#FFCC80"),gt.create("--ft-color-secondary-variant","","COLOR","#F57C00"),gt.create("--ft-color-surface","","COLOR","#FFFFFF"),gt.create("--ft-color-content","","COLOR","rgba(0, 0, 0, 0.87)"),gt.create("--ft-color-error","","COLOR","#B00020"),gt.create("--ft-color-outline","","COLOR","rgba(0, 0, 0, 0.14)"),gt.create("--ft-color-opacity-high","","NUMBER","1"),gt.create("--ft-color-opacity-medium","","NUMBER","0.74"),gt.create("--ft-color-opacity-disabled","","NUMBER","0.38"),gt.create("--ft-color-on-primary","","COLOR","#FFFFFF"),gt.create("--ft-color-on-primary-high","","COLOR","#FFFFFF"),gt.create("--ft-color-on-primary-medium","","COLOR","rgba(255, 255, 255, 0.74)"),gt.create("--ft-color-on-primary-disabled","","COLOR","rgba(255, 255, 255, 0.38)"),gt.create("--ft-color-on-secondary","","COLOR","#FFFFFF"),gt.create("--ft-color-on-secondary-high","","COLOR","#FFFFFF"),gt.create("--ft-color-on-secondary-medium","","COLOR","rgba(255, 255, 255, 0.74)"),gt.create("--ft-color-on-secondary-disabled","","COLOR","rgba(255, 255, 255, 0.38)"),gt.create("--ft-color-on-surface","","COLOR","rgba(0, 0, 0, 0.87)"),gt.create("--ft-color-on-surface-high","","COLOR","rgba(0, 0, 0, 0.87)"),gt.create("--ft-color-on-surface-medium","","COLOR","rgba(0, 0, 0, 0.60)"),gt.create("--ft-color-on-surface-disabled","","COLOR","rgba(0, 0, 0, 0.38)"),gt.create("--ft-opacity-content-on-surface-disabled","","NUMBER","0"),gt.create("--ft-opacity-content-on-surface-enable","","NUMBER","0"),gt.create("--ft-opacity-content-on-surface-hover","","NUMBER","0.04"),gt.create("--ft-opacity-content-on-surface-focused","","NUMBER","0.12"),gt.create("--ft-opacity-content-on-surface-pressed","","NUMBER","0.10"),gt.create("--ft-opacity-content-on-surface-selected","","NUMBER","0.08"),gt.create("--ft-opacity-content-on-surface-dragged","","NUMBER","0.08"),gt.create("--ft-opacity-primary-on-surface-disabled","","NUMBER","0"),gt.create("--ft-opacity-primary-on-surface-enable","","NUMBER","0"),gt.create("--ft-opacity-primary-on-surface-hover","","NUMBER","0.04"),gt.create("--ft-opacity-primary-on-surface-focused","","NUMBER","0.12"),gt.create("--ft-opacity-primary-on-surface-pressed","","NUMBER","0.10"),gt.create("--ft-opacity-primary-on-surface-selected","","NUMBER","0.08"),gt.create("--ft-opacity-primary-on-surface-dragged","","NUMBER","0.08"),gt.create("--ft-opacity-surface-on-primary-disabled","","NUMBER","0"),gt.create("--ft-opacity-surface-on-primary-enable","","NUMBER","0"),gt.create("--ft-opacity-surface-on-primary-hover","","NUMBER","0.04"),gt.create("--ft-opacity-surface-on-primary-focused","","NUMBER","0.12"),gt.create("--ft-opacity-surface-on-primary-pressed","","NUMBER","0.10"),gt.create("--ft-opacity-surface-on-primary-selected","","NUMBER","0.08"),gt.create("--ft-opacity-surface-on-primary-dragged","","NUMBER","0.08"),gt.create("--ft-elevation-00","","UNKNOWN","0px 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px 0px rgba(0, 0, 0, 0)"),gt.create("--ft-elevation-01","","UNKNOWN","0px 1px 4px 0px rgba(0, 0, 0, 0.06), 0px 1px 2px 0px rgba(0, 0, 0, 0.14), 0px 0px 1px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-02","","UNKNOWN","0px 4px 10px 0px rgba(0, 0, 0, 0.06), 0px 2px 5px 0px rgba(0, 0, 0, 0.14), 0px 0px 1px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-03","","UNKNOWN","0px 6px 13px 0px rgba(0, 0, 0, 0.06), 0px 3px 7px 0px rgba(0, 0, 0, 0.14), 0px 1px 2px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-04","","UNKNOWN","0px 8px 16px 0px rgba(0, 0, 0, 0.06), 0px 4px 9px 0px rgba(0, 0, 0, 0.14), 0px 2px 3px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-06","","UNKNOWN","0px 12px 22px 0px rgba(0, 0, 0, 0.06), 0px 6px 13px 0px rgba(0, 0, 0, 0.14), 0px 4px 5px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-08","","UNKNOWN","0px 16px 28px 0px rgba(0, 0, 0, 0.06), 0px 8px 17px 0px rgba(0, 0, 0, 0.14), 0px 6px 7px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-12","","UNKNOWN","0px 22px 40px 0px rgba(0, 0, 0, 0.06), 0px 12px 23px 0px rgba(0, 0, 0, 0.14), 0px 10px 11px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-16","","UNKNOWN","0px 28px 52px 0px rgba(0, 0, 0, 0.06), 0px 16px 29px 0px rgba(0, 0, 0, 0.14), 0px 14px 15px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-24","","UNKNOWN","0px 40px 76px 0px rgba(0, 0, 0, 0.06), 0px 24px 41px 0px rgba(0, 0, 0, 0.14), 0px 22px 23px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-border-radius-S","","SIZE","4px"),gt.create("--ft-border-radius-M","","SIZE","8px"),gt.create("--ft-border-radius-L","","SIZE","12px"),gt.create("--ft-border-radius-XL","","SIZE","16px"),gt.create("--ft-title-font","","UNKNOWN","Ubuntu, system-ui, sans-serif"),gt.create("--ft-content-font","","UNKNOWN","'Open Sans', system-ui, sans-serif"),gt.create("--ft-transition-duration","","UNKNOWN","250ms"),gt.create("--ft-transition-timing-function","","UNKNOWN","ease-in-out");class Ot extends pt{createRenderRoot(){const t=this.constructor;t.elementDefinitions&&!t.registry&&(t.registry=new CustomElementRegistry,Object.entries(t.elementDefinitions).forEach((([o,r])=>t.registry.define(o,r))));const o={...t.shadowRootOptions,customElements:t.registry},r=this.renderOptions.creationScope=this.attachShadow(o);return m(r,t.elementStyles),r}}var Nt,wt=function(t,o,r,e){for(var n,i=arguments.length,a=i<3?o:null===e?e=Object.getOwnPropertyDescriptor(o,r):e,c=t.length-1;c>=0;c--)(n=t[c])&&(a=(i<3?n(a):i>3?n(o,r,a):n(o,r))||a);return i>3&&a&&Object.defineProperty(o,r,a),a};const St=Symbol("constructorPrototype"),Et=Symbol("constructorName"),Rt=Symbol("exportpartsDebouncer");class Ct extends Ot{constructor(){super(),this[Nt]=new n(5),this[Et]=this.constructor.name,this[St]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[Et]&&Object.setPrototypeOf(this,this[St])}updated(t){super.updated(t),setTimeout((()=>{this.contentAvailableCallback(t),this.scheduleExportpartsUpdate()}),0)}contentAvailableCallback(t){var o,r;if((null!==(r=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))&&void 0!==r?r:[]).forEach((t=>t.remove())),this.customStylesheet){const t=document.createElement("style");t.classList.add("ft-lit-element--custom-stylesheet"),t.innerHTML=this.customStylesheet,this.shadowRoot.append(t)}}scheduleExportpartsUpdate(){this[Rt].run((()=>{var t;(null===(t=this.exportpartsPrefix)||void 0===t?void 0:t.trim())?this.setExportpartsAttribute([this.exportpartsPrefix]):null!=this.exportpartsPrefixes&&this.exportpartsPrefixes.length>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)}))}setExportpartsAttribute(t){var o,r,e,n,i,a;const c=t=>null!=t&&t.trim().length>0,s=t.filter(c).map((t=>t.trim()));if(0===s.length)return void this.removeAttribute("exportparts");const l=new Set;for(let t of null!==(r=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll("[part],[exportparts]"))&&void 0!==r?r:[]){const o=null!==(n=null===(e=t.getAttribute("part"))||void 0===e?void 0:e.split(" "))&&void 0!==n?n:[],r=null!==(a=null===(i=t.getAttribute("exportparts"))||void 0===i?void 0:i.split(",").map((t=>t.split(":")[1])))&&void 0!==a?a:[];new Array(...o,...r).filter(c).map((t=>t.trim())).forEach((t=>l.add(t)))}if(0===l.size)return void this.removeAttribute("exportparts");const f=[...l.values()].flatMap((t=>s.map((o=>`${t}:${o}--${t}`))));this.setAttribute("exportparts",[...this.part,...f].join(", "))}}Nt=Rt,wt([a()],Ct.prototype,"exportpartsPrefix",void 0),wt([u([])],Ct.prototype,"exportpartsPrefixes",void 0),wt([a()],Ct.prototype,"customStylesheet",void 0),v`
49
+ var ht,dt;let pt=class extends I{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t,o;const r=super.createRenderRoot();return null!==(t=(o=this.renderOptions).renderBefore)&&void 0!==t||(o.renderBefore=r.firstChild),r}update(t){const o=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,o,r)=>{var e,n;const i=null!==(e=null==r?void 0:r.renderBefore)&&void 0!==e?e:o;let a=i._$litPart$;if(void 0===a){const t=null!==(n=null==r?void 0:r.renderBefore)&&void 0!==n?n:null;i._$litPart$=a=new nt(o.insertBefore(F(),t),t,void 0,null!=r?r:{})}return a._$AI(t),a})(o,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!1)}render(){return X}};pt.finalized=!0,pt._$litElement$=!0,null===(ht=globalThis.litElementHydrateSupport)||void 0===ht||ht.call(globalThis,{LitElement:pt});const yt=globalThis.litElementPolyfillSupport;null==yt||yt({LitElement:pt}),(null!==(dt=globalThis.litElementVersions)&&void 0!==dt?dt:globalThis.litElementVersions=[]).push("3.3.2");const bt=t=>"string"==typeof t?g(t):t;class gt{static create(t,o,r,e){const n=t=>bt(null!=t?t:e),i=v`var(${bt(t)}, ${n(e)})`;return i.name=t,i.description=t,i.category=r,i.defaultValue=e,i.defaultCssValue=n,i.get=o=>v`var(${bt(t)}, ${n(o)})`,i.breadcrumb=()=>[],i.lastResortDefaultValue=()=>e,i}static extend(t,o,r,e){const n=t=>r.get(null!=t?t:e),i=v`var(${bt(t)}, ${n(e)})`;return i.name=t,i.description=o,i.category=r.category,i.fallbackVariable=r,i.defaultValue=e,i.defaultCssValue=n,i.get=o=>v`var(${bt(t)}, ${n(o)})`,i.breadcrumb=()=>[r.name,...r.breadcrumb()],i.lastResortDefaultValue=()=>null!=e?e:r.lastResortDefaultValue(),i}static external(t,o){const r=o=>t.fallbackVariable?t.fallbackVariable.get(null!=o?o:t.defaultValue):bt(null!=o?o:t.lastResortDefaultValue()),e=v`var(${bt(t.name)}, ${r(t.defaultValue)})`;return e.name=t.name,e.category=t.category,e.fallbackVariable=t.fallbackVariable,e.defaultValue=t.defaultValue,e.context=o,e.defaultCssValue=r,e.get=o=>v`var(${bt(t.name)}, ${r(o)})`,e.breadcrumb=()=>t.fallbackVariable?[t.fallbackVariable.name,...t.fallbackVariable.breadcrumb()]:[],e.lastResortDefaultValue=()=>t.lastResortDefaultValue(),e}}const vt={colorWhite:gt.create("--ft-color-white","","COLOR","#ffffff"),colorGray0:gt.create("--ft-color-gray-0","","COLOR","#71718e"),colorGray10:gt.create("--ft-color-gray-10","","COLOR","#fbfbfc"),colorGray20:gt.create("--ft-color-gray-20","","COLOR","#f2f2f5"),colorGray30:gt.create("--ft-color-gray-30","","COLOR","#e9e9ed"),colorGray40:gt.create("--ft-color-gray-40","","COLOR","#e0e0e6"),colorGray50:gt.create("--ft-color-gray-50","","COLOR","#cdcdd7"),colorGray60:gt.create("--ft-color-gray-60","","COLOR","#bbbbc9"),colorGray70:gt.create("--ft-color-gray-70","","COLOR","#a8a8ba"),colorGray80:gt.create("--ft-color-gray-80","","COLOR","#9696ab"),colorGray90:gt.create("--ft-color-gray-90","","COLOR","#83839d"),colorGray100:gt.create("--ft-color-gray-100","","COLOR","#62627c"),colorGray200:gt.create("--ft-color-gray-200","","COLOR","#545469"),colorGray300:gt.create("--ft-color-gray-300","","COLOR","#454557"),colorGray400:gt.create("--ft-color-gray-400","","COLOR","#363644"),colorGray500:gt.create("--ft-color-gray-500","","COLOR","#282832"),colorGray600:gt.create("--ft-color-gray-600","","COLOR","#19191f"),colorGray700:gt.create("--ft-color-gray-700","","COLOR","#0a0a0d"),colorBrand0:gt.create("--ft-color-brand-0","","COLOR","#9d207b"),colorBrand10:gt.create("--ft-color-brand-10","","COLOR","#f7edf4"),colorBrand20:gt.create("--ft-color-brand-20","","COLOR","#ebcfe4"),colorBrand30:gt.create("--ft-color-brand-30","","COLOR","#dfb2d3"),colorBrand40:gt.create("--ft-color-brand-40","","COLOR","#d395c2"),colorBrand50:gt.create("--ft-color-brand-50","","COLOR","#c778b1"),colorBrand60:gt.create("--ft-color-brand-60","","COLOR","#ba5ba1"),colorBrand70:gt.create("--ft-color-brand-70","","COLOR","#ae3e90"),colorBrand100:gt.create("--ft-color-brand-100","","COLOR","#8d1d6e"),colorBrand200:gt.create("--ft-color-brand-200","","COLOR","#78185e"),colorBrand300:gt.create("--ft-color-brand-300","","COLOR","#62144d"),colorBrand400:gt.create("--ft-color-brand-400","","COLOR","#4d103c"),colorBrand500:gt.create("--ft-color-brand-500","","COLOR","#380b2c"),colorBrand600:gt.create("--ft-color-brand-600","","COLOR","#23071b"),colorBrand700:gt.create("--ft-color-brand-700","","COLOR","#0d030b"),colorCyan0:gt.create("--ft-color-cyan-0","","COLOR","#0e98b4"),colorCyan10:gt.create("--ft-color-cyan-10","","COLOR","#ebf6f9"),colorCyan20:gt.create("--ft-color-cyan-20","","COLOR","#cbe9ef"),colorCyan30:gt.create("--ft-color-cyan-30","","COLOR","#acdbe5"),colorCyan40:gt.create("--ft-color-cyan-40","","COLOR","#8ccedb"),colorCyan50:gt.create("--ft-color-cyan-50","","COLOR","#6dc0d1"),colorCyan60:gt.create("--ft-color-cyan-60","","COLOR","#4db3c8"),colorCyan70:gt.create("--ft-color-cyan-70","","COLOR","#2ea5be"),colorCyan100:gt.create("--ft-color-cyan-100","","COLOR","#0c849c"),colorCyan200:gt.create("--ft-color-cyan-200","","COLOR","#0a7085"),colorCyan300:gt.create("--ft-color-cyan-300","","COLOR","#085c6d"),colorCyan400:gt.create("--ft-color-cyan-400","","COLOR","#074856"),colorCyan500:gt.create("--ft-color-cyan-500","","COLOR","#05343e"),colorCyan600:gt.create("--ft-color-cyan-600","","COLOR","#032127"),colorCyan700:gt.create("--ft-color-cyan-700","","COLOR","#010d0f"),colorGreen0:gt.create("--ft-color-green-0","","COLOR","#21a274"),colorGreen10:gt.create("--ft-color-green-10","","COLOR","#edf7f3"),colorGreen20:gt.create("--ft-color-green-20","","COLOR","#cfebe1"),colorGreen30:gt.create("--ft-color-green-30","","COLOR","#b2dfcf"),colorGreen40:gt.create("--ft-color-green-40","","COLOR","#95d3bd"),colorGreen50:gt.create("--ft-color-green-50","","COLOR","#78c7ab"),colorGreen60:gt.create("--ft-color-green-60","","COLOR","#5bba98"),colorGreen70:gt.create("--ft-color-green-70","","COLOR","#3eae86"),colorGreen100:gt.create("--ft-color-green-100","","COLOR","#1d8d65"),colorGreen200:gt.create("--ft-color-green-200","","COLOR","#187856"),colorGreen300:gt.create("--ft-color-green-300","","COLOR","#146246"),colorGreen400:gt.create("--ft-color-green-400","","COLOR","#104d37"),colorGreen500:gt.create("--ft-color-green-500","","COLOR","#0b3828"),colorGreen600:gt.create("--ft-color-green-600","","COLOR","#072319"),colorGreen700:gt.create("--ft-color-green-700","","COLOR","#030d0a"),colorOrange0:gt.create("--ft-color-orange-0","","COLOR","#ee8d17"),colorOrange10:gt.create("--ft-color-orange-10","","COLOR","#fef6ec"),colorOrange20:gt.create("--ft-color-orange-20","","COLOR","#fbe7cd"),colorOrange30:gt.create("--ft-color-orange-30","","COLOR","#f9d8af"),colorOrange40:gt.create("--ft-color-orange-40","","COLOR","#f7c991"),colorOrange50:gt.create("--ft-color-orange-50","","COLOR","#f5ba72"),colorOrange60:gt.create("--ft-color-orange-60","","COLOR","#f2ab54"),colorOrange70:gt.create("--ft-color-orange-70","","COLOR","#f09c35"),colorOrange100:gt.create("--ft-color-orange-100","","COLOR","#cf7b14"),colorOrange200:gt.create("--ft-color-orange-200","","COLOR","#b06811"),colorOrange300:gt.create("--ft-color-orange-300","","COLOR","#90560e"),colorOrange400:gt.create("--ft-color-orange-400","","COLOR","#71430b"),colorOrange500:gt.create("--ft-color-orange-500","","COLOR","#523108"),colorOrange600:gt.create("--ft-color-orange-600","","COLOR","#331e05"),colorOrange700:gt.create("--ft-color-orange-700","","COLOR","#140c02"),colorRed0:gt.create("--ft-color-red-0","","COLOR","#b40e2c"),colorRed10:gt.create("--ft-color-red-10","","COLOR","#f9ebed"),colorRed20:gt.create("--ft-color-red-20","","COLOR","#efcbd2"),colorRed30:gt.create("--ft-color-red-30","","COLOR","#e5acb6"),colorRed40:gt.create("--ft-color-red-40","","COLOR","#db8c9b"),colorRed50:gt.create("--ft-color-red-50","","COLOR","#d16d7f"),colorRed60:gt.create("--ft-color-red-60","","COLOR","#c84d63"),colorRed70:gt.create("--ft-color-red-70","","COLOR","#be2e48"),colorRed100:gt.create("--ft-color-red-100","","COLOR","#9c0c26"),colorRed200:gt.create("--ft-color-red-200","","COLOR","#850a20"),colorRed300:gt.create("--ft-color-red-300","","COLOR","#6d081b"),colorRed400:gt.create("--ft-color-red-400","","COLOR","#560715"),colorRed500:gt.create("--ft-color-red-500","","COLOR","#3e050f"),colorRed600:gt.create("--ft-color-red-600","","COLOR","#270309"),colorRed700:gt.create("--ft-color-red-700","","COLOR","#0f0104"),colorYellow0:gt.create("--ft-color-yellow-0","","COLOR","#E4C00C"),colorYellow10:gt.create("--ft-color-yellow-10","","COLOR","#fefae9"),colorYellow20:gt.create("--ft-color-yellow-20","","COLOR","#fcf4ca"),colorYellow30:gt.create("--ft-color-yellow-30","","COLOR","#faedaa"),colorYellow40:gt.create("--ft-color-yellow-40","","COLOR","#f9e78b"),colorYellow50:gt.create("--ft-color-yellow-50","","COLOR","#f7e06b"),colorYellow60:gt.create("--ft-color-yellow-60","","COLOR","#F4D63E"),colorYellow70:gt.create("--ft-color-yellow-70","","COLOR","#F3CE16"),colorYellow100:gt.create("--ft-color-yellow-100","","COLOR","#d3b10b"),colorYellow200:gt.create("--ft-color-yellow-200","","COLOR","#b3970a"),colorYellow300:gt.create("--ft-color-yellow-300","","COLOR","#947c08"),colorYellow400:gt.create("--ft-color-yellow-400","","COLOR","#746206"),colorYellow500:gt.create("--ft-color-yellow-500","","COLOR","#554705"),colorYellow600:gt.create("--ft-color-yellow-600","","COLOR","#352d03"),colorYellow700:gt.create("--ft-color-yellow-700","","COLOR","#161201"),colorUltramarine0:gt.create("--ft-color-ultramarine-0","","COLOR","#3C19E5"),colorUltramarine10:gt.create("--ft-color-ultramarine-10","","COLOR","#EDEAFD"),colorUltramarine20:gt.create("--ft-color-ultramarine-20","","COLOR","#D4CCF9"),colorUltramarine30:gt.create("--ft-color-ultramarine-30","","COLOR","#BBAFF6"),colorUltramarine40:gt.create("--ft-color-ultramarine-40","","COLOR","#A191F3"),colorUltramarine50:gt.create("--ft-color-ultramarine-50","","COLOR","#8873EF"),colorUltramarine60:gt.create("--ft-color-ultramarine-60","","COLOR","#6F55EC"),colorUltramarine70:gt.create("--ft-color-ultramarine-70","","COLOR","#5537E8"),colorUltramarine100:gt.create("--ft-color-ultramarine-100","","COLOR","#3416C7"),colorUltramarine200:gt.create("--ft-color-ultramarine-200","","COLOR","#2C13A9"),colorUltramarine300:gt.create("--ft-color-ultramarine-300","","COLOR","#250F8C"),colorUltramarine400:gt.create("--ft-color-ultramarine-400","","COLOR","#1D0C6E"),colorUltramarine500:gt.create("--ft-color-ultramarine-500","","COLOR","#150950"),colorUltramarine600:gt.create("--ft-color-ultramarine-600","","COLOR","#0D0532"),colorUltramarine700:gt.create("--ft-color-ultramarine-700","","COLOR","#050215"),colorAvocado0:gt.create("--ft-color-avocado-0","","COLOR","#98BD28"),colorAvocado10:gt.create("--ft-color-avocado-10","","COLOR","#F6F9EC"),colorAvocado20:gt.create("--ft-color-avocado-20","","COLOR","#E8F0D0"),colorAvocado30:gt.create("--ft-color-avocado-30","","COLOR","#DBE8B4"),colorAvocado40:gt.create("--ft-color-avocado-40","","COLOR","#CEDF98"),colorAvocado50:gt.create("--ft-color-avocado-50","","COLOR","#C0D77C"),colorAvocado60:gt.create("--ft-color-avocado-60","","COLOR","#B3CE60"),colorAvocado70:gt.create("--ft-color-avocado-70","","COLOR","#A5C644"),colorAvocado100:gt.create("--ft-color-avocado-100","","COLOR","#84A423"),colorAvocado200:gt.create("--ft-color-avocado-200","","COLOR","#708C1E"),colorAvocado300:gt.create("--ft-color-avocado-300","","COLOR","#5D7318"),colorAvocado400:gt.create("--ft-color-avocado-400","","COLOR","#495B13"),colorAvocado500:gt.create("--ft-color-avocado-500","","COLOR","#35420E"),colorAvocado600:gt.create("--ft-color-avocado-600","","COLOR","#212A09"),colorAvocado700:gt.create("--ft-color-avocado-700","","COLOR","#0E1104"),colorBrown0:gt.create("--ft-color-brown-0","","COLOR","#B26F4D"),colorBrown10:gt.create("--ft-color-brown-10","","COLOR","#F8F2EF"),colorBrown20:gt.create("--ft-color-brown-20","","COLOR","#EEDFD8"),colorBrown30:gt.create("--ft-color-brown-30","","COLOR","#E4CDC1"),colorBrown40:gt.create("--ft-color-brown-40","","COLOR","#DABAAA"),colorBrown50:gt.create("--ft-color-brown-50","","COLOR","#D0A792"),colorBrown60:gt.create("--ft-color-brown-60","","COLOR","#C6947B"),colorBrown70:gt.create("--ft-color-brown-70","","COLOR","#BC8264"),colorBrown100:gt.create("--ft-color-brown-100","","COLOR","#9B6143"),colorBrown200:gt.create("--ft-color-brown-200","","COLOR","#845239"),colorBrown300:gt.create("--ft-color-brown-300","","COLOR","#6D442F"),colorBrown400:gt.create("--ft-color-brown-400","","COLOR","#553525"),colorBrown500:gt.create("--ft-color-brown-500","","COLOR","#3E271B"),colorBrown600:gt.create("--ft-color-brown-600","","COLOR","#271811"),colorBrown700:gt.create("--ft-color-brown-700","","COLOR","#100A07"),spacing1:gt.create("--ft-spacing-1","","SIZE","0.25rem"),spacing2:gt.create("--ft-spacing-2","","SIZE","calc(var(--ft-spacing-2, 0.25rem)*2)"),spacing3:gt.create("--ft-spacing-3","","SIZE","calc(var(--ft-spacing-3, 0.25rem)*3)"),spacing4:gt.create("--ft-spacing-4","","SIZE","calc(var(--ft-spacing-4, 0.25rem)*4)"),spacing5:gt.create("--ft-spacing-5","","SIZE","calc(var(--ft-spacing-5, 0.25rem)*5)"),spacing6:gt.create("--ft-spacing-6","","SIZE","calc(var(--ft-spacing-6, 0.25rem)*6)"),spacing8:gt.create("--ft-spacing-8","","SIZE","calc(var(--ft-spacing-8, 0.25rem)*8)"),spacing10:gt.create("--ft-spacing-10","","SIZE","calc(var(--ft-spacing-10, 0.25rem)*10)"),spacing12:gt.create("--ft-spacing-12","","SIZE","calc(var(--ft-spacing-12, 0.25rem)*12)"),spacing16:gt.create("--ft-spacing-16","","SIZE","calc(var(--ft-spacing-16, 0.25rem)*16)"),spacing20:gt.create("--ft-spacing-20","","SIZE","calc(var(--ft-spacing-20, 0.25rem)*20)"),spacing24:gt.create("--ft-spacing-24","","SIZE","calc(var(--ft-spacing-24, 0.25rem)*24)"),spacing28:gt.create("--ft-spacing-28","","SIZE","calc(var(--ft-spacing-28, 0.25rem)*28)"),spacing32:gt.create("--ft-spacing-32","","SIZE","calc(var(--ft-spacing-32, 0.25rem)*32)"),spacing05:gt.create("--ft-spacing-0-5","","SIZE","calc(var(--ft-spacing-0-5, 0.25rem)*0.5)"),borderRadiusS:gt.create("--ft-border-radius-s","","SIZE","4px"),borderRadiusM:gt.create("--ft-border-radius-m","","SIZE","8px"),borderRadiusL:gt.create("--ft-border-radius-l","","SIZE","12px"),borderRadiusXl:gt.create("--ft-border-radius-xl","","SIZE","16px"),borderRadiusPill:gt.create("--ft-border-radius-pill","","SIZE","999px"),borderRadiusRound:gt.create("--ft-border-radius-round","","SIZE","50%"),iconSize1:gt.create("--ft-icon-size-1","","SIZE","12px"),iconSize2:gt.create("--ft-icon-size-2","","SIZE","16px"),iconSize3:gt.create("--ft-icon-size-3","","SIZE","20px"),iconSize4:gt.create("--ft-icon-size-4","","SIZE","24px"),iconSize5:gt.create("--ft-icon-size-5","","SIZE","32px"),iconSize6:gt.create("--ft-icon-size-6","","SIZE","48px"),opacity0:gt.create("--ft-opacity-0","","NUMBER","0"),opacity8:gt.create("--ft-opacity-8","","NUMBER","0.08"),opacity16:gt.create("--ft-opacity-16","","NUMBER","0.16"),opacity24:gt.create("--ft-opacity-24","","NUMBER","0.24"),opacity40:gt.create("--ft-opacity-40","","NUMBER","0.4"),opacity80:gt.create("--ft-opacity-80","","NUMBER","0.8")};gt.create("--ft-typography-display-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-display-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-display-lineHeight","","SIZE","120%"),gt.create("--ft-typography-display-fontSize","","SIZE","2.5rem"),gt.create("--ft-typography-display-letterSpacing","","SIZE","-0.02em"),gt.create("--ft-typography-display-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-display-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-display-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-display-textCase","","UNKNOWN","none"),gt.create("--ft-typography-title-1-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-title-1-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-title-1-lineHeight","","SIZE","120%"),gt.create("--ft-typography-title-1-fontSize","","SIZE","2rem"),gt.create("--ft-typography-title-1-letterSpacing","","SIZE","-0.02em"),gt.create("--ft-typography-title-1-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-title-1-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-title-1-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-title-1-textCase","","UNKNOWN","none"),gt.create("--ft-typography-title-2-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-title-2-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-title-2-lineHeight","","SIZE","120%"),gt.create("--ft-typography-title-2-fontSize","","SIZE","1.5rem"),gt.create("--ft-typography-title-2-letterSpacing","","SIZE","-0.02em"),gt.create("--ft-typography-title-2-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-title-2-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-title-2-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-title-2-textCase","","UNKNOWN","none"),gt.create("--ft-typography-title-3-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-title-3-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-title-3-lineHeight","","SIZE","120%"),gt.create("--ft-typography-title-3-fontSize","","SIZE","1.25rem"),gt.create("--ft-typography-title-3-letterSpacing","","SIZE","-0.01em"),gt.create("--ft-typography-title-3-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-title-3-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-title-3-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-title-3-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-1-regular-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-1-regular-fontWeight","","UNKNOWN","400"),gt.create("--ft-typography-body-1-regular-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-1-regular-fontSize","","SIZE","1rem"),gt.create("--ft-typography-body-1-regular-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-1-regular-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-1-regular-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-1-regular-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-1-regular-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-1-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-1-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-body-1-medium-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-1-medium-fontSize","","SIZE","1rem"),gt.create("--ft-typography-body-1-medium-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-1-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-1-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-1-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-1-medium-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-1-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-1-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-body-1-semibold-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-1-semibold-fontSize","","SIZE","1rem"),gt.create("--ft-typography-body-1-semibold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-1-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-1-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-1-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-1-semibold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-2-regular-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-2-regular-fontWeight","","UNKNOWN","400"),gt.create("--ft-typography-body-2-regular-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-2-regular-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-body-2-regular-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-2-regular-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-2-regular-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-2-regular-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-2-regular-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-2-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-2-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-body-2-medium-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-2-medium-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-body-2-medium-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-2-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-2-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-2-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-2-medium-textCase","","UNKNOWN","none"),gt.create("--ft-typography-body-2-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-body-2-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-body-2-semibold-lineHeight","","SIZE","135%"),gt.create("--ft-typography-body-2-semibold-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-body-2-semibold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-body-2-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-body-2-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-body-2-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-body-2-semibold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-label-1-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-1-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-label-1-medium-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-1-medium-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-label-1-medium-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-1-medium-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-1-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-1-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-1-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-1-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-1-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-label-1-semibold-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-1-semibold-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-label-1-semibold-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-1-semibold-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-1-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-1-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-1-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-1-bold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-1-bold-fontWeight","","UNKNOWN","700"),gt.create("--ft-typography-label-1-bold-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-1-bold-fontSize","","SIZE","0.875rem"),gt.create("--ft-typography-label-1-bold-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-1-bold-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-1-bold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-1-bold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-1-bold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-2-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-2-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-label-2-medium-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-2-medium-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-label-2-medium-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-2-medium-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-2-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-2-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-2-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-2-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-2-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-label-2-semibold-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-2-semibold-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-label-2-semibold-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-2-semibold-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-2-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-2-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-2-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-label-2-bold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-label-2-bold-fontWeight","","UNKNOWN","700"),gt.create("--ft-typography-label-2-bold-lineHeight","","SIZE","110%"),gt.create("--ft-typography-label-2-bold-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-label-2-bold-letterSpacing","","SIZE","0.04em"),gt.create("--ft-typography-label-2-bold-textCase","","UNKNOWN","uppercase"),gt.create("--ft-typography-label-2-bold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-label-2-bold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-label-2-bold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-1-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-caption-1-medium-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-1-medium-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-caption-1-medium-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-1-medium-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-1-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-1-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-1-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-caption-1-semibold-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-1-semibold-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-caption-1-semibold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-1-semibold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-1-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-1-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-bold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-1-bold-fontWeight","","UNKNOWN","700"),gt.create("--ft-typography-caption-1-bold-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-1-bold-fontSize","","SIZE","0.75rem"),gt.create("--ft-typography-caption-1-bold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-1-bold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-1-bold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-1-bold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-1-bold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-medium-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-2-medium-fontWeight","","UNKNOWN","500"),gt.create("--ft-typography-caption-2-medium-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-2-medium-fontSize","","SIZE","0.6875rem"),gt.create("--ft-typography-caption-2-medium-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-2-medium-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-medium-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-2-medium-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-2-medium-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-semibold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-2-semibold-fontWeight","","UNKNOWN","600"),gt.create("--ft-typography-caption-2-semibold-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-2-semibold-fontSize","","SIZE","0.6875rem"),gt.create("--ft-typography-caption-2-semibold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-2-semibold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-semibold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-2-semibold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-2-semibold-textDecoration","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-bold-fontFamily","","UNKNOWN","Inter"),gt.create("--ft-typography-caption-2-bold-fontWeight","","UNKNOWN","700"),gt.create("--ft-typography-caption-2-bold-lineHeight","","SIZE","130%"),gt.create("--ft-typography-caption-2-bold-fontSize","","SIZE","0.6875rem"),gt.create("--ft-typography-caption-2-bold-letterSpacing","","SIZE","normal"),gt.create("--ft-typography-caption-2-bold-textCase","","UNKNOWN","none"),gt.create("--ft-typography-caption-2-bold-paragraphSpacing","","UNKNOWN","normal"),gt.create("--ft-typography-caption-2-bold-paragraphIndent","","UNKNOWN","0"),gt.create("--ft-typography-caption-2-bold-textDecoration","","UNKNOWN","none");const mt={backgroundActionPrimary:gt.extend("--ft-background-action-primary","Used as backgorund of primary action components.",vt.colorBrand0),backgroundErrorPrimary:gt.extend("--ft-background-error-primary","Used as background of error components.",vt.colorRed0),backgroundErrorSubtle:gt.extend("--ft-background-error-subtle","Used as background of subtle error components.",vt.colorRed10),backgroundInfoPrimary:gt.extend("--ft-background-info-primary","Used as background of information components.",vt.colorCyan200),backgroundInfoSubtle:gt.extend("--ft-background-info-subtle","Used as background of subtle information components.",vt.colorCyan10),backgroundWarningPrimary:gt.extend("--ft-background-warning-primary","Used as background of warning components.",vt.colorOrange300),backgroundWarningSubtle:gt.extend("--ft-background-warning-subtle","Used as background of subtle information components.",vt.colorOrange10),backgroundSuccessPrimary:gt.extend("--ft-background-success-primary","Used as background of success components.",vt.colorGreen200),backgroundSuccessSubtle:gt.extend("--ft-background-success-subtle","Used as background of subtle success components.",vt.colorGreen10),backgroundGlobalSurface:gt.extend("--ft-background-global-surface","Used as app background.",vt.colorWhite),backgroundGlobalOnSurface:gt.extend("--ft-background-global-on-surface","Used as background on element on the base background, like cards.",vt.colorGray10),backgroundGlobalOnSurfaceDark:gt.extend("--ft-background-global-on-surface-dark","Used as background on element that need background separation.",vt.colorGray30),contentActionPrimary:gt.extend("--ft-content-action-primary","Used on label of primary action on light surface.",vt.colorBrand0),contentWarningPrimary:gt.extend("--ft-content-warning-primary","Used on label of warning messages on light surface.",vt.colorOrange300),contentWarningIconOnly:gt.extend("--ft-content-warning-icon-only","Used on warning status icons alone",vt.colorOrange0),contentErrorPrimary:gt.extend("--ft-content-error-primary","Used on label of error messages on light surface.",vt.colorRed0),contentErrorIconOnly:gt.extend("--ft-content-error-icon-only","Used on error status icons alone",vt.colorRed0),contentInfoPrimary:gt.extend("--ft-content-info-primary","Used on label of information messages on light surface.",vt.colorCyan200),contentInfoIconOnly:gt.extend("--ft-content-info-icon-only","Used on info status icons alone",vt.colorCyan0),contentSuccessIconOnly:gt.extend("--ft-content-success-icon-only","Used on success status icons alone",vt.colorGreen0),contentSuccessPrimary:gt.extend("--ft-content-success-primary","Used on label of success messages on light surface.",vt.colorGreen200),contentGlobalPrimary:gt.extend("--ft-content-global-primary","Used for main content on the page.",vt.colorGray500),contentGlobalSecondary:gt.extend("--ft-content-global-secondary","Used for secondary content, often paired with primary content.\nAlso for action icons.",vt.colorGray200),contentGlobalSubtle:gt.extend("--ft-content-global-subtle","Used for placeholder, unselected items in a tab component or breadcrumb.",vt.colorGray0),contentGlobalOnColor:gt.extend("--ft-content-global-on-color","Used for content on a dominant color.",vt.colorWhite),borderActionPrimary:gt.extend("--ft-border-action-primary","Used as border for primary action components.",vt.colorBrand0),borderActionFocusRing:gt.extend("--ft-border-action-focus-ring","Focus ring is an additional border to indicate focus-visible state.",vt.colorCyan0),borderWarningPrimary:gt.extend("--ft-border-warning-primary","Used as border for warning components.",vt.colorOrange30),borderSuccessPrimary:gt.extend("--ft-border-success-primary","Used as border for success components.",vt.colorGreen30),borderErrorPrimary:gt.extend("--ft-border-error-primary","Used as border for error components.",vt.colorRed30),borderInfoPrimary:gt.extend("--ft-border-info-primary","Used as border for information components.",vt.colorCyan30),borderGlobalSubtle:gt.extend("--ft-border-global-subtle","Used as border to deliminate an area filled with background.on-surface and separators.",vt.colorGray30),borderGlobalPrimary:gt.extend("--ft-border-global-primary","Used as border for element like input.",vt.colorGray50),borderInputPrimary:gt.extend("--ft-border-input-primary","Used as border for checkboxes and radio buttons",vt.colorGray80)};gt.create("--ft-button-large-height","","SIZE","40px"),gt.extend("--ft-button-large-horizontal-padding","",vt.spacing4),gt.extend("--ft-button-large-gap","",vt.spacing2),gt.extend("--ft-button-large-border-radius","",vt.borderRadiusS),gt.extend("--ft-button-large-icon-size","",vt.iconSize3),gt.create("--ft-button-large-border-width","","SIZE","1px"),gt.create("--ft-button-large-focus-outline-offset","","SIZE","2px"),gt.create("--ft-button-large-focus-outline-width","","SIZE","2px"),gt.create("--ft-button-large-icon-only-width","","SIZE","40px"),gt.create("--ft-button-small-height","","SIZE","30px"),gt.extend("--ft-button-small-horizontal-padding","",vt.spacing3),gt.extend("--ft-button-small-gap","",vt.spacing2),gt.extend("--ft-button-small-border-radius","",vt.borderRadiusS),gt.extend("--ft-button-small-icon-size","",vt.iconSize2),gt.create("--ft-button-small-border-width","","SIZE","1px"),gt.create("--ft-button-small-focus-outline-offset","","SIZE","2px"),gt.create("--ft-button-small-focus-outline-width","","SIZE","2px"),gt.create("--ft-button-small-icon-only-width","","SIZE","30px"),gt.extend("--ft-button-primary-background-color","",mt.backgroundActionPrimary),gt.extend("--ft-button-primary-color","",mt.contentGlobalOnColor),gt.extend("--ft-button-primary-icon-color","",mt.contentGlobalOnColor),gt.extend("--ft-button-primary-state-layer-color","",mt.contentGlobalOnColor),gt.extend("--ft-button-primary-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-button-primary-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-button-primary-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-button-primary-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-button-focus-focus-ring-color","",mt.borderActionFocusRing),gt.create("--ft-button-tertiary-background-color","","COLOR","rgba(0,0,0,0)"),gt.extend("--ft-button-tertiary-color","",mt.contentActionPrimary),gt.extend("--ft-button-tertiary-icon-color","",mt.contentActionPrimary),gt.extend("--ft-button-tertiary-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-button-tertiary-state-layer-opacity-hover","",vt.opacity8),gt.extend("--ft-button-tertiary-state-layer-opacity-focus","",vt.opacity8),gt.extend("--ft-button-tertiary-state-layer-opacity-active","",vt.opacity16),gt.extend("--ft-button-tertiary-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-button-secondary-background-color","",vt.colorWhite),gt.extend("--ft-button-secondary-color","",mt.contentActionPrimary),gt.extend("--ft-button-secondary-icon-color","",mt.contentActionPrimary),gt.extend("--ft-button-secondary-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-button-secondary-state-layer-opacity-hover","",vt.opacity8),gt.extend("--ft-button-secondary-state-layer-opacity-focus","",vt.opacity8),gt.extend("--ft-button-secondary-state-layer-opacity-active","",vt.opacity16),gt.extend("--ft-button-secondary-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-button-secondary-border-color","",mt.borderActionPrimary),gt.create("--ft-button-neutral-background-color","","COLOR","rgba(0,0,0,0)"),gt.extend("--ft-button-neutral-icon-color","",mt.contentGlobalSecondary),gt.extend("--ft-button-neutral-color","",mt.contentGlobalSecondary),gt.extend("--ft-button-neutral-state-layer-color","",mt.contentGlobalSecondary),gt.extend("--ft-button-neutral-state-layer-opacity-hover","",vt.opacity8),gt.extend("--ft-button-neutral-state-layer-opacity-focus","",vt.opacity8),gt.extend("--ft-button-neutral-state-layer-opacity-active","",vt.opacity16),gt.extend("--ft-button-neutral-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-tabs-top-left-border-radius","",vt.borderRadiusS),gt.extend("--ft-tabs-top-right-border-radius","",vt.borderRadiusS),gt.extend("--ft-tabs-label-horizontal-padding","",vt.spacing4),gt.extend("--ft-tabs-label-vertical-padding","",vt.spacing3),gt.extend("--ft-tabs-label-gap","",vt.spacing1),gt.extend("--ft-switch-group-horizontal-padding","",vt.spacing1),gt.extend("--ft-switch-group-vertical-padding","",vt.spacing1),gt.extend("--ft-switch-group-gap","",vt.spacing1),gt.extend("--ft-switch-group-background-color","",mt.backgroundGlobalSurface),gt.extend("--ft-switch-group-border-color","",mt.borderGlobalSubtle),gt.create("--ft-switch-group-border-radius","","SIZE","6px"),gt.extend("--ft-switch-label-horizontal-padding","",vt.spacing2),gt.extend("--ft-switch-label-vertical-padding","",vt.spacing1),gt.extend("--ft-switch-icon-horizontal-padding","",vt.spacing1),gt.extend("--ft-switch-icon-vertical-padding","",vt.spacing1),gt.create("--ft-switch-focus-outline-width","","SIZE","2px"),gt.extend("--ft-switch-focus-focus-ring-color","",mt.borderActionFocusRing),gt.extend("--ft-switch-option-border-radius","",vt.borderRadiusS),gt.extend("--ft-switch-off-state-layer-opacity-hover","",vt.opacity8),gt.extend("--ft-switch-off-state-layer-opacity-focus","",vt.opacity8),gt.extend("--ft-switch-off-state-layer-opacity-active","",vt.opacity16),gt.extend("--ft-switch-off-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-switch-off-color","",mt.contentGlobalSubtle),gt.extend("--ft-switch-off-state-layer-color","",mt.contentGlobalSubtle),gt.extend("--ft-chart-1-light","for area color charts",vt.colorBrand40),gt.extend("--ft-chart-1-base","for line charts",vt.colorBrand0),gt.extend("--ft-chart-2-light","for area color charts",vt.colorYellow60),gt.extend("--ft-chart-2-base","for line charts",vt.colorYellow100),gt.extend("--ft-chart-3-light","",vt.colorUltramarine40),gt.extend("--ft-chart-3-base","",vt.colorUltramarine70),gt.extend("--ft-chart-4-light","",vt.colorCyan50),gt.extend("--ft-chart-4-base","",vt.colorCyan100),gt.extend("--ft-chart-5-light","",vt.colorRed40),gt.extend("--ft-chart-5-base","",vt.colorRed60),gt.extend("--ft-chart-6-light","",vt.colorGreen40),gt.extend("--ft-chart-6-base","",vt.colorGreen70),gt.extend("--ft-chart-7-light","",vt.colorOrange70),gt.extend("--ft-chart-7-base","",vt.colorOrange100),gt.extend("--ft-chart-8-light","",vt.colorAvocado70),gt.extend("--ft-chart-8-base","",vt.colorAvocado200),gt.extend("--ft-chart-9-light","",vt.colorBrown50),gt.extend("--ft-chart-9-base","",vt.colorBrown200),gt.extend("--ft-chart-10-light","",vt.colorGray50),gt.extend("--ft-chart-10-base","",vt.colorGray80),gt.extend("--ft-chart-monochrome-10","",vt.colorBrand10),gt.extend("--ft-chart-monochrome-20","",vt.colorBrand20),gt.extend("--ft-chart-monochrome-30","",vt.colorBrand40),gt.extend("--ft-chart-monochrome-40","",vt.colorBrand60),gt.extend("--ft-chart-monochrome-50","",vt.colorBrand0),gt.extend("--ft-chart-monochrome-60","",vt.colorBrand200),gt.extend("--ft-chip-large-horizontal-padding","",vt.spacing4),gt.extend("--ft-chip-large-vertical-padding","",vt.spacing2),gt.extend("--ft-chip-large-gap","",vt.spacing1),gt.create("--ft-chip-large-focus-outline-offset","","SIZE","2px"),gt.create("--ft-chip-large-focus-outline-width","","SIZE","2px"),gt.extend("--ft-chip-large-border-radius","",vt.borderRadiusPill),gt.create("--ft-chip-large-border-width","","SIZE","1px"),gt.extend("--ft-chip-large-icon-size","",vt.iconSize3),gt.extend("--ft-chip-medium-horizontal-padding","",vt.spacing3),gt.extend("--ft-chip-medium-vertical-padding","",vt.spacing1),gt.extend("--ft-chip-medium-gap","",vt.spacing1),gt.create("--ft-chip-medium-focus-outline-offset","","SIZE","2px"),gt.create("--ft-chip-medium-focus-outline-width","","SIZE","2px"),gt.extend("--ft-chip-medium-border-radius","",vt.borderRadiusPill),gt.create("--ft-chip-medium-border-width","","SIZE","1px"),gt.extend("--ft-chip-medium-icon-size","",vt.iconSize2),gt.extend("--ft-chip-small-horizontal-padding","",vt.spacing2),gt.extend("--ft-chip-small-vertical-padding","",vt.spacing05),gt.extend("--ft-chip-small-gap","",vt.spacing1),gt.create("--ft-chip-small-focus-outline-offset","","SIZE","2px"),gt.create("--ft-chip-small-focus-outline-width","","SIZE","2px"),gt.extend("--ft-chip-small-border-radius","",vt.borderRadiusPill),gt.create("--ft-chip-small-border-width","","SIZE","1px"),gt.extend("--ft-chip-small-icon-size","",vt.iconSize1),gt.extend("--ft-chip-neutral-background-color","",mt.backgroundGlobalOnSurface),gt.extend("--ft-chip-neutral-color","",mt.contentGlobalPrimary),gt.extend("--ft-chip-neutral-border-color","",mt.borderGlobalSubtle),gt.extend("--ft-chip-info-background-color","",mt.backgroundInfoSubtle),gt.extend("--ft-chip-info-color","",mt.contentInfoPrimary),gt.extend("--ft-chip-info-border-color","",mt.borderInfoPrimary),gt.extend("--ft-chip-success-background-color","",mt.backgroundSuccessSubtle),gt.extend("--ft-chip-success-color","",mt.contentSuccessPrimary),gt.extend("--ft-chip-success-border-color","",mt.borderSuccessPrimary),gt.extend("--ft-chip-warning-background-color","",mt.backgroundWarningSubtle),gt.extend("--ft-chip-warning-color","",mt.contentWarningPrimary),gt.extend("--ft-chip-warning-border-color","",mt.borderWarningPrimary),gt.extend("--ft-chip-error-background-color","",mt.backgroundErrorSubtle),gt.extend("--ft-chip-error-color","",mt.contentErrorPrimary),gt.extend("--ft-chip-error-border-color","",mt.borderErrorPrimary),gt.create("--ft-notice-border-width","","SIZE","1px"),gt.extend("--ft-notice-horizontal-padding","",vt.spacing2),gt.extend("--ft-notice-vertical-padding","",vt.spacing1),gt.extend("--ft-notice-border-radius","",vt.borderRadiusS),gt.extend("--ft-notice-gap","",vt.spacing2),gt.extend("--ft-notice-icon-size","",vt.iconSize3),gt.extend("--ft-notice-info-background-color","",mt.backgroundInfoSubtle),gt.extend("--ft-notice-info-border-color","",mt.borderInfoPrimary),gt.extend("--ft-notice-info-color","",mt.contentInfoPrimary),gt.extend("--ft-notice-warning-background-color","",mt.backgroundWarningSubtle),gt.extend("--ft-notice-warning-border-color","",mt.borderWarningPrimary),gt.extend("--ft-notice-warning-color","",mt.contentWarningPrimary),gt.extend("--ft-checkbox-label-color","",mt.contentGlobalPrimary),gt.extend("--ft-checkbox-checked-background-color","",mt.contentActionPrimary),gt.extend("--ft-checkbox-checked-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-checkbox-checked-color","",mt.contentGlobalOnColor),gt.extend("--ft-checkbox-checked-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-checkbox-checked-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-checkbox-checked-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-checkbox-checked-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-checkbox-unchecked-border-color","",vt.colorGray80),gt.extend("--ft-checkbox-unchecked-state-layer-color","",vt.colorGray80),gt.extend("--ft-checkbox-unchecked-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-checkbox-unchecked-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-checkbox-unchecked-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-checkbox-unchecked-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-checkbox-focus-focus-ring-color","",mt.borderActionFocusRing),gt.create("--ft-checkbox-focus-outline-offset","","SIZE","3px"),gt.create("--ft-checkbox-focus-outline-width","","SIZE","2px"),gt.extend("--ft-checkbox-gap","",vt.spacing3),gt.extend("--ft-toggle-off-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-toggle-off-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-toggle-off-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-toggle-off-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-toggle-off-background-color","",mt.contentGlobalSubtle),gt.extend("--ft-toggle-off-icon-color","",mt.contentGlobalSubtle),gt.extend("--ft-toggle-off-state-layer-color","",mt.contentGlobalSubtle),gt.extend("--ft-toggle-on-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-toggle-on-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-toggle-on-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-toggle-on-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-toggle-on-background-color","",mt.contentActionPrimary),gt.extend("--ft-toggle-on-icon-color","",mt.contentActionPrimary),gt.extend("--ft-toggle-on-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-toggle-label-color","",mt.contentGlobalPrimary),gt.extend("--ft-toggle-focus-focus-ring-color","",mt.borderActionFocusRing),gt.extend("--ft-toggle-gap","",vt.spacing3),gt.extend("--ft-radio-label-color","",mt.contentGlobalPrimary),gt.extend("--ft-radio-selected-color","",mt.contentActionPrimary),gt.extend("--ft-radio-selected-state-layer-color","",mt.contentActionPrimary),gt.extend("--ft-radio-selected-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-radio-selected-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-radio-selected-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-radio-selected-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-radio-unselected-state-layer-color","",vt.colorGray80),gt.extend("--ft-radio-unselected-state-layer-opacity-hover","",vt.opacity16),gt.extend("--ft-radio-unselected-state-layer-opacity-focus","",vt.opacity16),gt.extend("--ft-radio-unselected-state-layer-opacity-active","",vt.opacity24),gt.extend("--ft-radio-unselected-component-opacity-disabled","",vt.opacity40),gt.extend("--ft-radio-focus-focus-ring-color","",mt.borderActionFocusRing),gt.create("--ft-radio-focus-outline-offset","","SIZE","3px"),gt.create("--ft-radio-focus-outline-width","","SIZE","2px"),gt.extend("--ft-radio-gap","",vt.spacing3),gt.extend("--ft-notification-icon-size","",vt.iconSize4),gt.extend("--ft-notification-horizontal-padding","",vt.spacing4),gt.extend("--ft-notification-vertical-padding","",vt.spacing4),gt.extend("--ft-notification-info-background-color","",mt.backgroundInfoSubtle),gt.extend("--ft-notification-info-color","",mt.contentInfoPrimary),gt.extend("--ft-notification-info-border-color","",mt.borderInfoPrimary),gt.extend("--ft-notification-success-background-color","",mt.backgroundSuccessSubtle),gt.extend("--ft-notification-success-color","",mt.contentSuccessPrimary),gt.extend("--ft-notification-success-border-color","",mt.borderSuccessPrimary),gt.extend("--ft-notification-warning-background-color","",mt.backgroundWarningSubtle),gt.extend("--ft-notification-warning-color","",mt.contentWarningPrimary),gt.extend("--ft-notification-warning-border-color","",mt.borderWarningPrimary),gt.extend("--ft-notification-error-background-color","",mt.backgroundErrorSubtle),gt.extend("--ft-notification-error-color","",mt.contentErrorPrimary),gt.extend("--ft-notification-error-border-color","",mt.borderErrorPrimary),gt.extend("--ft-notification-border-radius","",vt.borderRadiusPill),gt.create("--ft-notification-border-width","","SIZE","1px"),gt.extend("--ft-notification-gap-leading","",vt.spacing2),gt.extend("--ft-notification-gap-trailing","",vt.spacing8),gt.create("--ft-color-primary","","COLOR","#2196F3"),gt.create("--ft-color-primary-variant","","COLOR","#1976D2"),gt.create("--ft-color-secondary","","COLOR","#FFCC80"),gt.create("--ft-color-secondary-variant","","COLOR","#F57C00"),gt.create("--ft-color-surface","","COLOR","#FFFFFF"),gt.create("--ft-color-content","","COLOR","rgba(0, 0, 0, 0.87)"),gt.create("--ft-color-error","","COLOR","#B00020"),gt.create("--ft-color-outline","","COLOR","rgba(0, 0, 0, 0.14)"),gt.create("--ft-color-opacity-high","","NUMBER","1"),gt.create("--ft-color-opacity-medium","","NUMBER","0.74"),gt.create("--ft-color-opacity-disabled","","NUMBER","0.38"),gt.create("--ft-color-on-primary","","COLOR","#FFFFFF"),gt.create("--ft-color-on-primary-high","","COLOR","#FFFFFF"),gt.create("--ft-color-on-primary-medium","","COLOR","rgba(255, 255, 255, 0.74)"),gt.create("--ft-color-on-primary-disabled","","COLOR","rgba(255, 255, 255, 0.38)"),gt.create("--ft-color-on-secondary","","COLOR","#FFFFFF"),gt.create("--ft-color-on-secondary-high","","COLOR","#FFFFFF"),gt.create("--ft-color-on-secondary-medium","","COLOR","rgba(255, 255, 255, 0.74)"),gt.create("--ft-color-on-secondary-disabled","","COLOR","rgba(255, 255, 255, 0.38)"),gt.create("--ft-color-on-surface","","COLOR","rgba(0, 0, 0, 0.87)"),gt.create("--ft-color-on-surface-high","","COLOR","rgba(0, 0, 0, 0.87)"),gt.create("--ft-color-on-surface-medium","","COLOR","rgba(0, 0, 0, 0.60)"),gt.create("--ft-color-on-surface-disabled","","COLOR","rgba(0, 0, 0, 0.38)"),gt.create("--ft-opacity-content-on-surface-disabled","","NUMBER","0"),gt.create("--ft-opacity-content-on-surface-enable","","NUMBER","0"),gt.create("--ft-opacity-content-on-surface-hover","","NUMBER","0.04"),gt.create("--ft-opacity-content-on-surface-focused","","NUMBER","0.12"),gt.create("--ft-opacity-content-on-surface-pressed","","NUMBER","0.10"),gt.create("--ft-opacity-content-on-surface-selected","","NUMBER","0.08"),gt.create("--ft-opacity-content-on-surface-dragged","","NUMBER","0.08"),gt.create("--ft-opacity-primary-on-surface-disabled","","NUMBER","0"),gt.create("--ft-opacity-primary-on-surface-enable","","NUMBER","0"),gt.create("--ft-opacity-primary-on-surface-hover","","NUMBER","0.04"),gt.create("--ft-opacity-primary-on-surface-focused","","NUMBER","0.12"),gt.create("--ft-opacity-primary-on-surface-pressed","","NUMBER","0.10"),gt.create("--ft-opacity-primary-on-surface-selected","","NUMBER","0.08"),gt.create("--ft-opacity-primary-on-surface-dragged","","NUMBER","0.08"),gt.create("--ft-opacity-surface-on-primary-disabled","","NUMBER","0"),gt.create("--ft-opacity-surface-on-primary-enable","","NUMBER","0"),gt.create("--ft-opacity-surface-on-primary-hover","","NUMBER","0.04"),gt.create("--ft-opacity-surface-on-primary-focused","","NUMBER","0.12"),gt.create("--ft-opacity-surface-on-primary-pressed","","NUMBER","0.10"),gt.create("--ft-opacity-surface-on-primary-selected","","NUMBER","0.08"),gt.create("--ft-opacity-surface-on-primary-dragged","","NUMBER","0.08"),gt.create("--ft-elevation-00","","UNKNOWN","0px 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px 0px rgba(0, 0, 0, 0)"),gt.create("--ft-elevation-01","","UNKNOWN","0px 1px 4px 0px rgba(0, 0, 0, 0.06), 0px 1px 2px 0px rgba(0, 0, 0, 0.14), 0px 0px 1px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-02","","UNKNOWN","0px 4px 10px 0px rgba(0, 0, 0, 0.06), 0px 2px 5px 0px rgba(0, 0, 0, 0.14), 0px 0px 1px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-03","","UNKNOWN","0px 6px 13px 0px rgba(0, 0, 0, 0.06), 0px 3px 7px 0px rgba(0, 0, 0, 0.14), 0px 1px 2px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-04","","UNKNOWN","0px 8px 16px 0px rgba(0, 0, 0, 0.06), 0px 4px 9px 0px rgba(0, 0, 0, 0.14), 0px 2px 3px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-06","","UNKNOWN","0px 12px 22px 0px rgba(0, 0, 0, 0.06), 0px 6px 13px 0px rgba(0, 0, 0, 0.14), 0px 4px 5px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-08","","UNKNOWN","0px 16px 28px 0px rgba(0, 0, 0, 0.06), 0px 8px 17px 0px rgba(0, 0, 0, 0.14), 0px 6px 7px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-12","","UNKNOWN","0px 22px 40px 0px rgba(0, 0, 0, 0.06), 0px 12px 23px 0px rgba(0, 0, 0, 0.14), 0px 10px 11px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-16","","UNKNOWN","0px 28px 52px 0px rgba(0, 0, 0, 0.06), 0px 16px 29px 0px rgba(0, 0, 0, 0.14), 0px 14px 15px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-elevation-24","","UNKNOWN","0px 40px 76px 0px rgba(0, 0, 0, 0.06), 0px 24px 41px 0px rgba(0, 0, 0, 0.14), 0px 22px 23px 0px rgba(0, 0, 0, 0.06)"),gt.create("--ft-border-radius-S","","SIZE","4px"),gt.create("--ft-border-radius-M","","SIZE","8px"),gt.create("--ft-border-radius-L","","SIZE","12px"),gt.create("--ft-border-radius-XL","","SIZE","16px"),gt.create("--ft-title-font","","UNKNOWN","Ubuntu, system-ui, sans-serif"),gt.create("--ft-content-font","","UNKNOWN","'Open Sans', system-ui, sans-serif"),gt.create("--ft-transition-duration","","UNKNOWN","250ms"),gt.create("--ft-transition-timing-function","","UNKNOWN","ease-in-out");class Ot extends pt{createRenderRoot(){const t=this.constructor;t.elementDefinitions&&!t.registry&&(t.registry=new CustomElementRegistry,Object.entries(t.elementDefinitions).forEach((([o,r])=>t.registry.define(o,r))));const o={...t.shadowRootOptions,customElements:t.registry},r=this.renderOptions.creationScope=this.attachShadow(o);return m(r,t.elementStyles),r}}var Nt,wt=function(t,o,r,e){for(var n,i=arguments.length,a=i<3?o:null===e?e=Object.getOwnPropertyDescriptor(o,r):e,s=t.length-1;s>=0;s--)(n=t[s])&&(a=(i<3?n(a):i>3?n(o,r,a):n(o,r))||a);return i>3&&a&&Object.defineProperty(o,r,a),a};const St=Symbol("constructorPrototype"),Et=Symbol("constructorName"),Ct=Symbol("exportpartsDebouncer");class Rt extends Ot{constructor(){super(),this[Nt]=new n(5),this[Et]=this.constructor.name,this[St]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[Et]&&Object.setPrototypeOf(this,this[St])}updated(t){super.updated(t),setTimeout((()=>{this.contentAvailableCallback(t),this.scheduleExportpartsUpdate()}),0)}contentAvailableCallback(t){var o,r;if((null!==(r=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))&&void 0!==r?r:[]).forEach((t=>t.remove())),this.customStylesheet){const t=document.createElement("style");t.classList.add("ft-lit-element--custom-stylesheet"),t.innerHTML=this.customStylesheet,this.shadowRoot.append(t)}}scheduleExportpartsUpdate(){this[Ct].run((()=>{var t;(null===(t=this.exportpartsPrefix)||void 0===t?void 0:t.trim())?this.setExportpartsAttribute([this.exportpartsPrefix]):null!=this.exportpartsPrefixes&&this.exportpartsPrefixes.length>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)}))}setExportpartsAttribute(t){var o,r,e,n,i,a;const s=t=>null!=t&&t.trim().length>0,c=t.filter(s).map((t=>t.trim()));if(0===c.length)return void this.removeAttribute("exportparts");const l=new Set;for(let t of null!==(r=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll("[part],[exportparts]"))&&void 0!==r?r:[]){const o=null!==(n=null===(e=t.getAttribute("part"))||void 0===e?void 0:e.split(" "))&&void 0!==n?n:[],r=null!==(a=null===(i=t.getAttribute("exportparts"))||void 0===i?void 0:i.split(",").map((t=>t.split(":")[1])))&&void 0!==a?a:[];new Array(...o,...r).filter(s).map((t=>t.trim())).forEach((t=>l.add(t)))}if(0===l.size)return void this.removeAttribute("exportparts");const f=[...l.values()].flatMap((t=>c.map((o=>`${t}:${o}--${t}`))));this.setAttribute("exportparts",[...this.part,...f].join(", "))}}Nt=Ct,wt([a()],Rt.prototype,"exportpartsPrefix",void 0),wt([u([])],Rt.prototype,"exportpartsPrefixes",void 0),wt([a()],Rt.prototype,"customStylesheet",void 0),v`
50
50
  .ft-no-text-select {
51
51
  -webkit-touch-callout: none;
52
52
  -webkit-user-select: none;
@@ -78,15 +78,15 @@ var ht,dt;let pt=class extends I{constructor(){super(...arguments),this.renderOp
78
78
  display: inline-block;
79
79
  width: 0;
80
80
  }
81
- `;class Ut{constructor(t,o){this.defaultLabels=t,this.labels=o}resolve(t,...o){var r,e;t=this.resolvePluralKey(t,o);let n=null!==(e=null!==(r=this.labels[t])&&void 0!==r?r:this.defaultLabels[t])&&void 0!==e?e:"";return o.forEach(((t,o)=>n=n.replace(new RegExp(`\\{${o}([^}]*)\\}`,"g"),((o,r)=>this.formatValue(t,r))))),n}resolvePluralKey(t,o){for(let r of o)if("number"==typeof r){const o=`${String(t)}[\\=${r}]`;if(o in this.labels||o in this.defaultLabels)return o}return t}formatValue(t,o){return t instanceof Date?this.formatDate(t,o):null!=t?t:""}formatDate(t,o){const r=r=>(null==o?void 0:o.includes("date"))?t.toLocaleDateString(r):(null==o?void 0:o.includes("time"))?t.toLocaleTimeString(r):t.toLocaleString(r);try{return r(document.documentElement.lang)}catch(t){return r()}}}function xt(t){var o;return null!==(o=null==t?void 0:t.isFtReduxStore)&&void 0!==o&&o}var It,Lt,At;const kt=Symbol("internalReduxEventsUnsubscribers"),Wt=Symbol("internalStoresUnsubscribers"),Kt=Symbol("internalStores");class Tt extends Ct{constructor(){super(...arguments),this[It]=new Map,this[Lt]=new Map,this[At]=[]}update(t){var o;super.update(t),(null===(o=this.reduxReactiveProperties)||void 0===o?void 0:o.some((o=>t.has(o))))&&this.updateFromStores()}getUnnamedStore(){if(this[Kt].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Kt].values()][0]}getStore(t){return null==t?this.getUnnamedStore():this[Kt].get(t)}addStore(t,o){var r;o=null!==(r=null!=o?o:xt(t)?t.name:void 0)&&void 0!==r?r:"default-store",this.unsubscribeFromStore(o),this.setupStore(o,t)}removeStore(t){const o="string"==typeof t?t:t.name;this.unsubscribeFromStore(o),this[Kt].delete(o)}setupStore(t,o){this[Kt].set(t,o),this.subscribeToStore(t,o),this.updateFromStores()}setupStores(){this.unsubscribeFromStores(),this[Kt].forEach(((t,o)=>this.subscribeToStore(o,t))),this.updateFromStores()}updateFromStores(){this.reduxProperties&&this.reduxProperties.forEach(((t,o)=>{const r=this.constructor.getPropertyOptions(o);if(!(null==r?void 0:r.attribute)||!this.hasAttribute("string"==typeof(null==r?void 0:r.attribute)?r.attribute:o)){const r=this.getStore(t.store);r&&(t.store?this[Wt].has(t.store):this[Wt].size>0)&&(this[o]=t.selector(r.getState(),this))}}))}subscribeToStore(t,o){var r;this[Wt].set(t,o.subscribe((()=>this.updateFromStores()))),xt(o)&&o.eventBus&&(null===(r=this.reduxEventListeners)||void 0===r||r.forEach(((t,r)=>{if("function"==typeof this[r]&&(!t.store||o.name===t.store)){const e=t=>this[r](t);o.eventBus.addEventListener(t.eventName,e),this[kt].push((()=>o.eventBus.removeEventListener(t.eventName,e)))}}))),this.onStoreAvailable(t)}unsubscribeFromStores(){this[Wt].forEach(((t,o)=>this.unsubscribeFromStore(o))),this[kt].forEach((t=>t())),this[kt]=[]}unsubscribeFromStore(t){this[Wt].has(t)&&this[Wt].get(t)(),this[Wt].delete(t)}onStoreAvailable(t){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}function jt(t){for(var o=arguments.length,r=Array(o>1?o-1:0),e=1;e<o;e++)r[e-1]=arguments[e];throw Error("[Immer] minified error nr: "+t+(r.length?" "+r.map((function(t){return"'"+t+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Pt(t){return!!t&&!!t[Eo]}function Mt(t){var o;return!!t&&(function(t){if(!t||"object"!=typeof t)return!1;var o=Object.getPrototypeOf(t);if(null===o)return!0;var r=Object.hasOwnProperty.call(o,"constructor")&&o.constructor;return r===Object||"function"==typeof r&&Function.toString.call(r)===Ro}(t)||Array.isArray(t)||!!t[So]||!!(null===(o=t.constructor)||void 0===o?void 0:o[So])||$t(t)||zt(t))}function Ft(t,o,r){void 0===r&&(r=!1),0===Zt(t)?(r?Object.keys:Co)(t).forEach((function(e){r&&"symbol"==typeof e||o(e,t[e],t)})):t.forEach((function(r,e){return o(e,r,t)}))}function Zt(t){var o=t[Eo];return o?o.i>3?o.i-4:o.i:Array.isArray(t)?1:$t(t)?2:zt(t)?3:0}function Bt(t,o){return 2===Zt(t)?t.has(o):Object.prototype.hasOwnProperty.call(t,o)}function Dt(t,o,r){var e=Zt(t);2===e?t.set(o,r):3===e?t.add(r):t[o]=r}function _t(t,o){return t===o?0!==t||1/t==1/o:t!=t&&o!=o}function $t(t){return mo&&t instanceof Map}function zt(t){return Oo&&t instanceof Set}function Gt(t){return t.o||t.t}function Ht(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var o=Uo(t);delete o[Eo];for(var r=Co(o),e=0;e<r.length;e++){var n=r[e],i=o[n];!1===i.writable&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(o[n]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[n]})}return Object.create(Object.getPrototypeOf(t),o)}function qt(t,o){return void 0===o&&(o=!1),Yt(t)||Pt(t)||!Mt(t)||(Zt(t)>1&&(t.set=t.add=t.clear=t.delete=Vt),Object.freeze(t),o&&Ft(t,(function(t,o){return qt(o,!0)}),!0)),t}function Vt(){jt(2)}function Yt(t){return null==t||"object"!=typeof t||Object.isFrozen(t)}function Xt(t){var o=xo[t];return o||jt(18,t),o}function Jt(){return go}function Qt(t,o){o&&(Xt("Patches"),t.u=[],t.s=[],t.v=o)}function to(t){oo(t),t.p.forEach(eo),t.p=null}function oo(t){t===go&&(go=t.l)}function ro(t){return go={p:[],l:go,h:t,m:!0,_:0}}function eo(t){var o=t[Eo];0===o.i||1===o.i?o.j():o.g=!0}function no(t,o){o._=o.p.length;var r=o.p[0],e=void 0!==t&&t!==r;return o.h.O||Xt("ES5").S(o,t,e),e?(r[Eo].P&&(to(o),jt(4)),Mt(t)&&(t=io(o,t),o.l||co(o,t)),o.u&&Xt("Patches").M(r[Eo].t,t,o.u,o.s)):t=io(o,r,[]),to(o),o.u&&o.v(o.u,o.s),t!==wo?t:void 0}function io(t,o,r){if(Yt(o))return o;var e=o[Eo];if(!e)return Ft(o,(function(n,i){return ao(t,e,o,n,i,r)}),!0),o;if(e.A!==t)return o;if(!e.P)return co(t,e.t,!0),e.t;if(!e.I){e.I=!0,e.A._--;var n=4===e.i||5===e.i?e.o=Ht(e.k):e.o,i=n,a=!1;3===e.i&&(i=new Set(n),n.clear(),a=!0),Ft(i,(function(o,i){return ao(t,e,n,o,i,r,a)})),co(t,n,!1),r&&t.u&&Xt("Patches").N(e,r,t.u,t.s)}return e.o}function ao(t,o,r,e,n,i,a){if(Pt(n)){var c=io(t,n,i&&o&&3!==o.i&&!Bt(o.R,e)?i.concat(e):void 0);if(Dt(r,e,c),!Pt(c))return;t.m=!1}else a&&r.add(n);if(Mt(n)&&!Yt(n)){if(!t.h.D&&t._<1)return;io(t,n),o&&o.A.l||co(t,n)}}function co(t,o,r){void 0===r&&(r=!1),!t.l&&t.h.D&&t.m&&qt(o,r)}function so(t,o){var r=t[Eo];return(r?Gt(r):t)[o]}function lo(t,o){if(o in t)for(var r=Object.getPrototypeOf(t);r;){var e=Object.getOwnPropertyDescriptor(r,o);if(e)return e;r=Object.getPrototypeOf(r)}}function fo(t){t.P||(t.P=!0,t.l&&fo(t.l))}function uo(t){t.o||(t.o=Ht(t.t))}function ho(t,o,r){var e=$t(o)?Xt("MapSet").F(o,r):zt(o)?Xt("MapSet").T(o,r):t.O?function(t,o){var r=Array.isArray(t),e={i:r?1:0,A:o?o.A:Jt(),P:!1,I:!1,R:{},l:o,t,k:null,o:null,j:null,C:!1},n=e,i=Io;r&&(n=[e],i=Lo);var a=Proxy.revocable(n,i),c=a.revoke,s=a.proxy;return e.k=s,e.j=c,s}(o,r):Xt("ES5").J(o,r);return(r?r.A:Jt()).p.push(e),e}function po(t){return Pt(t)||jt(22,t),function t(o){if(!Mt(o))return o;var r,e=o[Eo],n=Zt(o);if(e){if(!e.P&&(e.i<4||!Xt("ES5").K(e)))return e.t;e.I=!0,r=yo(o,n),e.I=!1}else r=yo(o,n);return Ft(r,(function(o,n){e&&function(t,o){return 2===Zt(t)?t.get(o):t[o]}(e.t,o)===n||Dt(r,o,t(n))})),3===n?new Set(r):r}(t)}function yo(t,o){switch(o){case 2:return new Map(t);case 3:return Array.from(t)}return Ht(t)}It=Wt,Lt=Kt,At=kt;var bo,go,vo="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),mo="undefined"!=typeof Map,Oo="undefined"!=typeof Set,No="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,wo=vo?Symbol.for("immer-nothing"):((bo={})["immer-nothing"]=!0,bo),So=vo?Symbol.for("immer-draftable"):"__$immer_draftable",Eo=vo?Symbol.for("immer-state"):"__$immer_state",Ro=""+Object.prototype.constructor,Co="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,Uo=Object.getOwnPropertyDescriptors||function(t){var o={};return Co(t).forEach((function(r){o[r]=Object.getOwnPropertyDescriptor(t,r)})),o},xo={},Io={get:function(t,o){if(o===Eo)return t;var r=Gt(t);if(!Bt(r,o))return function(t,o,r){var e,n=lo(o,r);return n?"value"in n?n.value:null===(e=n.get)||void 0===e?void 0:e.call(t.k):void 0}(t,r,o);var e=r[o];return t.I||!Mt(e)?e:e===so(t.t,o)?(uo(t),t.o[o]=ho(t.A.h,e,t)):e},has:function(t,o){return o in Gt(t)},ownKeys:function(t){return Reflect.ownKeys(Gt(t))},set:function(t,o,r){var e=lo(Gt(t),o);if(null==e?void 0:e.set)return e.set.call(t.k,r),!0;if(!t.P){var n=so(Gt(t),o),i=null==n?void 0:n[Eo];if(i&&i.t===r)return t.o[o]=r,t.R[o]=!1,!0;if(_t(r,n)&&(void 0!==r||Bt(t.t,o)))return!0;uo(t),fo(t)}return t.o[o]===r&&(void 0!==r||o in t.o)||Number.isNaN(r)&&Number.isNaN(t.o[o])||(t.o[o]=r,t.R[o]=!0),!0},deleteProperty:function(t,o){return void 0!==so(t.t,o)||o in t.t?(t.R[o]=!1,uo(t),fo(t)):delete t.R[o],t.o&&delete t.o[o],!0},getOwnPropertyDescriptor:function(t,o){var r=Gt(t),e=Reflect.getOwnPropertyDescriptor(r,o);return e?{writable:!0,configurable:1!==t.i||"length"!==o,enumerable:e.enumerable,value:r[o]}:e},defineProperty:function(){jt(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){jt(12)}},Lo={};Ft(Io,(function(t,o){Lo[t]=function(){return arguments[0]=arguments[0][0],o.apply(this,arguments)}})),Lo.deleteProperty=function(t,o){return Lo.set.call(this,t,o,void 0)},Lo.set=function(t,o,r){return Io.set.call(this,t[0],o,r,t[0])};var Ao=function(){function t(t){var o=this;this.O=No,this.D=!0,this.produce=function(t,r,e){if("function"==typeof t&&"function"!=typeof r){var n=r;r=t;var i=o;return function(t){var o=this;void 0===t&&(t=n);for(var e=arguments.length,a=Array(e>1?e-1:0),c=1;c<e;c++)a[c-1]=arguments[c];return i.produce(t,(function(t){var e;return(e=r).call.apply(e,[o,t].concat(a))}))}}var a;if("function"!=typeof r&&jt(6),void 0!==e&&"function"!=typeof e&&jt(7),Mt(t)){var c=ro(o),s=ho(o,t,void 0),l=!0;try{a=r(s),l=!1}finally{l?to(c):oo(c)}return"undefined"!=typeof Promise&&a instanceof Promise?a.then((function(t){return Qt(c,e),no(t,c)}),(function(t){throw to(c),t})):(Qt(c,e),no(a,c))}if(!t||"object"!=typeof t){if(void 0===(a=r(t))&&(a=t),a===wo&&(a=void 0),o.D&&qt(a,!0),e){var f=[],u=[];Xt("Patches").M(t,a,f,u),e(f,u)}return a}jt(21,t)},this.produceWithPatches=function(t,r){if("function"==typeof t)return function(r){for(var e=arguments.length,n=Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];return o.produceWithPatches(r,(function(o){return t.apply(void 0,[o].concat(n))}))};var e,n,i=o.produce(t,r,(function(t,o){e=t,n=o}));return"undefined"!=typeof Promise&&i instanceof Promise?i.then((function(t){return[t,e,n]})):[i,e,n]},"boolean"==typeof(null==t?void 0:t.useProxies)&&this.setUseProxies(t.useProxies),"boolean"==typeof(null==t?void 0:t.autoFreeze)&&this.setAutoFreeze(t.autoFreeze)}var o=t.prototype;return o.createDraft=function(t){Mt(t)||jt(8),Pt(t)&&(t=po(t));var o=ro(this),r=ho(this,t,void 0);return r[Eo].C=!0,oo(o),r},o.finishDraft=function(t,o){var r=(t&&t[Eo]).A;return Qt(r,o),no(void 0,r)},o.setAutoFreeze=function(t){this.D=t},o.setUseProxies=function(t){t&&!No&&jt(20),this.O=t},o.applyPatches=function(t,o){var r;for(r=o.length-1;r>=0;r--){var e=o[r];if(0===e.path.length&&"replace"===e.op){t=e.value;break}}r>-1&&(o=o.slice(r+1));var n=Xt("Patches").$;return Pt(t)?n(t,o):this.produce(t,(function(t){return n(t,o)}))},t}(),ko=new Ao,Wo=ko.produce;function Ko(t){return Ko="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ko(t)}function To(t){var o=function(t,o){if("object"!==Ko(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var e=r.call(t,o||"default");if("object"!==Ko(e))return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===o?String:Number)(t)}(t,"string");return"symbol"===Ko(o)?o:String(o)}function jo(t,o,r){return(o=To(o))in t?Object.defineProperty(t,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[o]=r,t}function Po(t,o){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var e=Object.getOwnPropertySymbols(t);o&&(e=e.filter((function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable}))),r.push.apply(r,e)}return r}function Mo(t){for(var o=1;o<arguments.length;o++){var r=null!=arguments[o]?arguments[o]:{};o%2?Po(Object(r),!0).forEach((function(o){jo(t,o,r[o])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Po(Object(r)).forEach((function(o){Object.defineProperty(t,o,Object.getOwnPropertyDescriptor(r,o))}))}return t}function Fo(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}ko.produceWithPatches.bind(ko),ko.setAutoFreeze.bind(ko),ko.setUseProxies.bind(ko),ko.applyPatches.bind(ko),ko.createDraft.bind(ko),ko.finishDraft.bind(ko);var Zo="function"==typeof Symbol&&Symbol.observable||"@@observable",Bo=function(){return Math.random().toString(36).substring(7).split("").join(".")},Do={INIT:"@@redux/INIT"+Bo(),REPLACE:"@@redux/REPLACE"+Bo(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Bo()}};function _o(t,o,r){var e;if("function"==typeof o&&"function"==typeof r||"function"==typeof r&&"function"==typeof arguments[3])throw new Error(Fo(0));if("function"==typeof o&&void 0===r&&(r=o,o=void 0),void 0!==r){if("function"!=typeof r)throw new Error(Fo(1));return r(_o)(t,o)}if("function"!=typeof t)throw new Error(Fo(2));var n=t,i=o,a=[],c=a,s=!1;function l(){c===a&&(c=a.slice())}function f(){if(s)throw new Error(Fo(3));return i}function u(t){if("function"!=typeof t)throw new Error(Fo(4));if(s)throw new Error(Fo(5));var o=!0;return l(),c.push(t),function(){if(o){if(s)throw new Error(Fo(6));o=!1,l();var r=c.indexOf(t);c.splice(r,1),a=null}}}function h(t){if(!function(t){if("object"!=typeof t||null===t)return!1;for(var o=t;null!==Object.getPrototypeOf(o);)o=Object.getPrototypeOf(o);return Object.getPrototypeOf(t)===o}(t))throw new Error(Fo(7));if(void 0===t.type)throw new Error(Fo(8));if(s)throw new Error(Fo(9));try{s=!0,i=n(i,t)}finally{s=!1}for(var o=a=c,r=0;r<o.length;r++){(0,o[r])()}return t}return h({type:Do.INIT}),(e={dispatch:h,subscribe:u,getState:f,replaceReducer:function(t){if("function"!=typeof t)throw new Error(Fo(10));n=t,h({type:Do.REPLACE})}})[Zo]=function(){var t,o=u;return(t={subscribe:function(t){if("object"!=typeof t||null===t)throw new Error(Fo(11));function r(){t.next&&t.next(f())}return r(),{unsubscribe:o(r)}}})[Zo]=function(){return this},t},e}function $o(t){for(var o=Object.keys(t),r={},e=0;e<o.length;e++){var n=o[e];"function"==typeof t[n]&&(r[n]=t[n])}var i,a=Object.keys(r);try{!function(t){Object.keys(t).forEach((function(o){var r=t[o];if(void 0===r(void 0,{type:Do.INIT}))throw new Error(Fo(12));if(void 0===r(void 0,{type:Do.PROBE_UNKNOWN_ACTION()}))throw new Error(Fo(13))}))}(r)}catch(t){i=t}return function(t,o){if(void 0===t&&(t={}),i)throw i;for(var e=!1,n={},c=0;c<a.length;c++){var s=a[c],l=r[s],f=t[s],u=l(f,o);if(void 0===u)throw o&&o.type,new Error(Fo(14));n[s]=u,e=e||u!==f}return(e=e||a.length!==Object.keys(t).length)?n:t}}function zo(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return 0===o.length?function(t){return t}:1===o.length?o[0]:o.reduce((function(t,o){return function(){return t(o.apply(void 0,arguments))}}))}function Go(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return function(t){return function(){var r=t.apply(void 0,arguments),e=function(){throw new Error(Fo(15))},n={getState:r.getState,dispatch:function(){return e.apply(void 0,arguments)}},i=o.map((function(t){return t(n)}));return e=zo.apply(void 0,i)(r.dispatch),Mo(Mo({},r),{},{dispatch:e})}}}function Ho(t){return function(o){var r=o.dispatch,e=o.getState;return function(o){return function(n){return"function"==typeof n?n(r,e,t):o(n)}}}}var qo=Ho();qo.withExtraArgument=Ho;var Vo,Yo=qo,Xo=(Vo=function(t,o){return Vo=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,o){t.__proto__=o}||function(t,o){for(var r in o)Object.prototype.hasOwnProperty.call(o,r)&&(t[r]=o[r])},Vo(t,o)},function(t,o){if("function"!=typeof o&&null!==o)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");function r(){this.constructor=t}Vo(t,o),t.prototype=null===o?Object.create(o):(r.prototype=o.prototype,new r)}),Jo=function(t,o){var r,e,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function c(i){return function(c){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,e&&(n=2&i[0]?e.return:i[0]?e.throw||((n=e.return)&&n.call(e),0):e.next)&&!(n=n.call(e,i[1])).done)return n;switch(e=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,e=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=a.trys,(n=n.length>0&&n[n.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=o.call(t,a)}catch(t){i=[6,t],e=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,c])}}},Qo=function(t,o){for(var r=0,e=o.length,n=t.length;r<e;r++,n++)t[n]=o[r];return t},tr=Object.defineProperty,or=Object.defineProperties,rr=Object.getOwnPropertyDescriptors,er=Object.getOwnPropertySymbols,nr=Object.prototype.hasOwnProperty,ir=Object.prototype.propertyIsEnumerable,ar=function(t,o,r){return o in t?tr(t,o,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[o]=r},cr=function(t,o){for(var r in o||(o={}))nr.call(o,r)&&ar(t,r,o[r]);if(er)for(var e=0,n=er(o);e<n.length;e++){r=n[e];ir.call(o,r)&&ar(t,r,o[r])}return t},sr=function(t,o){return or(t,rr(o))},lr="undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(0!==arguments.length)return"object"==typeof arguments[0]?zo:zo.apply(null,arguments)};var fr=function(t){function o(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var n=t.apply(this,r)||this;return Object.setPrototypeOf(n,o.prototype),n}return Xo(o,t),Object.defineProperty(o,Symbol.species,{get:function(){return o},enumerable:!1,configurable:!0}),o.prototype.concat=function(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];return t.prototype.concat.apply(this,o)},o.prototype.prepend=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return 1===t.length&&Array.isArray(t[0])?new(o.bind.apply(o,Qo([void 0],t[0].concat(this)))):new(o.bind.apply(o,Qo([void 0],t.concat(this))))},o}(Array),ur=function(t){function o(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var n=t.apply(this,r)||this;return Object.setPrototypeOf(n,o.prototype),n}return Xo(o,t),Object.defineProperty(o,Symbol.species,{get:function(){return o},enumerable:!1,configurable:!0}),o.prototype.concat=function(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];return t.prototype.concat.apply(this,o)},o.prototype.prepend=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return 1===t.length&&Array.isArray(t[0])?new(o.bind.apply(o,Qo([void 0],t[0].concat(this)))):new(o.bind.apply(o,Qo([void 0],t.concat(this))))},o}(Array);function hr(t){return Mt(t)?Wo(t,(function(){})):t}function dr(){return function(t){return function(t){void 0===t&&(t={});var o=t.thunk,r=void 0===o||o;t.immutableCheck,t.serializableCheck;var e=new fr;r&&(!function(t){return"boolean"==typeof t}(r)?e.push(Yo.withExtraArgument(r.extraArgument)):e.push(Yo));return e}(t)}}function pr(t){var o,r=dr(),e=t||{},n=e.reducer,i=void 0===n?void 0:n,a=e.middleware,c=void 0===a?r():a,s=e.devTools,l=void 0===s||s,f=e.preloadedState,u=void 0===f?void 0:f,h=e.enhancers,d=void 0===h?void 0:h;if("function"==typeof i)o=i;else{if(!function(t){if("object"!=typeof t||null===t)return!1;var o=Object.getPrototypeOf(t);if(null===o)return!0;for(var r=o;null!==Object.getPrototypeOf(r);)r=Object.getPrototypeOf(r);return o===r}(i))throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');o=$o(i)}var p=c;"function"==typeof p&&(p=p(r));var y=Go.apply(void 0,p),b=zo;l&&(b=lr(cr({trace:!1},"object"==typeof l&&l)));var g=new ur(y),v=g;return Array.isArray(d)?v=Qo([y],d):"function"==typeof d&&(v=d(g)),_o(o,u,b.apply(void 0,v))}function yr(t,o){function r(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];if(o){var n=o.apply(void 0,r);if(!n)throw new Error("prepareAction did not return an object");return cr(cr({type:t,payload:n.payload},"meta"in n&&{meta:n.meta}),"error"in n&&{error:n.error})}return{type:t,payload:r[0]}}return r.toString=function(){return""+t},r.type=t,r.match=function(o){return o.type===t},r}function br(t){var o,r={},e=[],n={addCase:function(t,o){var e="string"==typeof t?t:t.type;if(e in r)throw new Error("addCase cannot be called with two reducers for the same action type");return r[e]=o,n},addMatcher:function(t,o){return e.push({matcher:t,reducer:o}),n},addDefaultCase:function(t){return o=t,n}};return t(n),[r,e,o]}function gr(t){var o=t.name;if(!o)throw new Error("`name` is a required option for createSlice");var r,e="function"==typeof t.initialState?t.initialState:hr(t.initialState),n=t.reducers||{},i=Object.keys(n),a={},c={},s={};function l(){var o="function"==typeof t.extraReducers?br(t.extraReducers):[t.extraReducers],r=o[0],n=void 0===r?{}:r,i=o[1],a=void 0===i?[]:i,s=o[2],l=void 0===s?void 0:s,f=cr(cr({},n),c);return function(t,o,r,e){void 0===r&&(r=[]);var n,i="function"==typeof o?br(o):[o,r,e],a=i[0],c=i[1],s=i[2];if(function(t){return"function"==typeof t}(t))n=function(){return hr(t())};else{var l=hr(t);n=function(){return l}}function f(t,o){void 0===t&&(t=n());var r=Qo([a[o.type]],c.filter((function(t){return(0,t.matcher)(o)})).map((function(t){return t.reducer})));return 0===r.filter((function(t){return!!t})).length&&(r=[s]),r.reduce((function(t,r){if(r){var e;if(Pt(t))return void 0===(e=r(t,o))?t:e;if(Mt(t))return Wo(t,(function(t){return r(t,o)}));if(void 0===(e=r(t,o))){if(null===t)return t;throw Error("A case reducer on a non-draftable value must not return undefined")}return e}return t}),t)}return f.getInitialState=n,f}(e,(function(t){for(var o in f)t.addCase(o,f[o]);for(var r=0,e=a;r<e.length;r++){var n=e[r];t.addMatcher(n.matcher,n.reducer)}l&&t.addDefaultCase(l)}))}return i.forEach((function(t){var r,e,i=n[t],l=o+"/"+t;"reducer"in i?(r=i.reducer,e=i.prepare):r=i,a[t]=r,c[l]=r,s[t]=e?yr(l,e):yr(l)})),{name:o,reducer:function(t,o){return r||(r=l()),r(t,o)},actions:s,caseReducers:a,getInitialState:function(){return r||(r=l()),r.getInitialState()}}}var vr=["name","message","stack","code"],mr=function(t,o){this.payload=t,this.meta=o},Or=function(t,o){this.payload=t,this.meta=o},Nr=function(t){if("object"==typeof t&&null!==t){for(var o={},r=0,e=vr;r<e.length;r++){var n=e[r];"string"==typeof t[n]&&(o[n]=t[n])}return o}return{message:String(t)}};function wr(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}!function(){function t(t,o,r){var e=yr(t+"/fulfilled",(function(t,o,r,e){return{payload:t,meta:sr(cr({},e||{}),{arg:r,requestId:o,requestStatus:"fulfilled"})}})),n=yr(t+"/pending",(function(t,o,r){return{payload:void 0,meta:sr(cr({},r||{}),{arg:o,requestId:t,requestStatus:"pending"})}})),i=yr(t+"/rejected",(function(t,o,e,n,i){return{payload:n,error:(r&&r.serializeError||Nr)(t||"Rejected"),meta:sr(cr({},i||{}),{arg:e,requestId:o,rejectedWithValue:!!n,requestStatus:"rejected",aborted:"AbortError"===(null==t?void 0:t.name),condition:"ConditionError"===(null==t?void 0:t.name)})}})),a="undefined"!=typeof AbortController?AbortController:function(){function t(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return t.prototype.abort=function(){},t}();return Object.assign((function(t){return function(c,s,l){var f,u=(null==r?void 0:r.idGenerator)?r.idGenerator(t):function(t){void 0===t&&(t=21);for(var o="",r=t;r--;)o+="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW"[64*Math.random()|0];return o}(),h=new a;function d(t){f=t,h.abort()}var p=function(){return a=this,p=null,y=function(){var a,p,y,b,g,v;return Jo(this,(function(m){switch(m.label){case 0:return m.trys.push([0,4,,5]),b=null==(a=null==r?void 0:r.condition)?void 0:a.call(r,t,{getState:s,extra:l}),null===(O=b)||"object"!=typeof O||"function"!=typeof O.then?[3,2]:[4,b];case 1:b=m.sent(),m.label=2;case 2:if(!1===b||h.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return g=new Promise((function(t,o){return h.signal.addEventListener("abort",(function(){return o({name:"AbortError",message:f||"Aborted"})}))})),c(n(u,t,null==(p=null==r?void 0:r.getPendingMeta)?void 0:p.call(r,{requestId:u,arg:t},{getState:s,extra:l}))),[4,Promise.race([g,Promise.resolve(o(t,{dispatch:c,getState:s,extra:l,requestId:u,signal:h.signal,abort:d,rejectWithValue:function(t,o){return new mr(t,o)},fulfillWithValue:function(t,o){return new Or(t,o)}})).then((function(o){if(o instanceof mr)throw o;return o instanceof Or?e(o.payload,u,t,o.meta):e(o,u,t)}))])];case 3:return y=m.sent(),[3,5];case 4:return v=m.sent(),y=v instanceof mr?i(null,u,t,v.payload,v.meta):i(v,u,t),[3,5];case 5:return r&&!r.dispatchConditionRejection&&i.match(y)&&y.meta.condition||c(y),[2,y]}var O}))},new Promise((function(t,o){var r=function(t){try{n(y.next(t))}catch(t){o(t)}},e=function(t){try{n(y.throw(t))}catch(t){o(t)}},n=function(o){return o.done?t(o.value):Promise.resolve(o.value).then(r,e)};n((y=y.apply(a,p)).next())}));var a,p,y}();return Object.assign(p,{abort:d,requestId:u,arg:t,unwrap:function(){return p.then(wr)}})}}),{pending:n,rejected:i,fulfilled:e,typePrefix:t})}t.withTypes=function(){return t}}();var Sr="listenerMiddleware";yr(Sr+"/add"),yr(Sr+"/removeAll"),yr(Sr+"/remove"),"function"==typeof queueMicrotask&&queueMicrotask.bind("undefined"!=typeof window?window:"undefined"!=typeof global?global:globalThis),function(){function t(t,o){var r=n[t];return r?r.enumerable=o:n[t]=r={configurable:!0,enumerable:o,get:function(){var o=this[Eo];return Io.get(o,t)},set:function(o){var r=this[Eo];Io.set(r,t,o)}},r}function o(t){for(var o=t.length-1;o>=0;o--){var n=t[o][Eo];if(!n.P)switch(n.i){case 5:e(n)&&fo(n);break;case 4:r(n)&&fo(n)}}}function r(t){for(var o=t.t,r=t.k,e=Co(r),n=e.length-1;n>=0;n--){var i=e[n];if(i!==Eo){var a=o[i];if(void 0===a&&!Bt(o,i))return!0;var c=r[i],s=c&&c[Eo];if(s?s.t!==a:!_t(c,a))return!0}}var l=!!o[Eo];return e.length!==Co(o).length+(l?0:1)}function e(t){var o=t.k;if(o.length!==t.t.length)return!0;var r=Object.getOwnPropertyDescriptor(o,o.length-1);if(r&&!r.get)return!0;for(var e=0;e<o.length;e++)if(!o.hasOwnProperty(e))return!0;return!1}var n={};!function(t,o){xo[t]||(xo[t]=o)}("ES5",{J:function(o,r){var e=Array.isArray(o),n=function(o,r){if(o){for(var e=Array(r.length),n=0;n<r.length;n++)Object.defineProperty(e,""+n,t(n,!0));return e}var i=Uo(r);delete i[Eo];for(var a=Co(i),c=0;c<a.length;c++){var s=a[c];i[s]=t(s,o||!!i[s].enumerable)}return Object.create(Object.getPrototypeOf(r),i)}(e,o),i={i:e?5:4,A:r?r.A:Jt(),P:!1,I:!1,R:{},l:r,t:o,k:n,o:null,g:!1,C:!1};return Object.defineProperty(n,Eo,{value:i,writable:!0}),n},S:function(t,r,n){n?Pt(r)&&r[Eo].A===t&&o(t.p):(t.u&&function t(o){if(o&&"object"==typeof o){var r=o[Eo];if(r){var n=r.t,i=r.k,a=r.R,c=r.i;if(4===c)Ft(i,(function(o){o!==Eo&&(void 0!==n[o]||Bt(n,o)?a[o]||t(i[o]):(a[o]=!0,fo(r)))})),Ft(n,(function(t){void 0!==i[t]||Bt(i,t)||(a[t]=!1,fo(r))}));else if(5===c){if(e(r)&&(fo(r),a.length=!0),i.length<n.length)for(var s=i.length;s<n.length;s++)a[s]=!1;else for(var l=n.length;l<i.length;l++)a[l]=!0;for(var f=Math.min(i.length,n.length),u=0;u<f;u++)i.hasOwnProperty(u)||(a[u]=!0),void 0===a[u]&&t(i[u])}}}}(t.p[0]),o(t.p))},K:function(t){return 4===t.i?r(t):e(t)}})}(),window.ftReduxStores||(window.ftReduxStores={});class Er{static get(t){var o;const r="string"==typeof t?t:t.name,e="string"==typeof t?void 0:t,n=window.ftReduxStores[r];if(xt(n))return n;if(null==e)return;const i=gr({...e,reducers:null!==(o=e.reducers)&&void 0!==o?o:{}}),a=pr({reducer:(t,o)=>{var r;switch(o.type){case"CLEAR_FT_REDUX_STORE":return i.getInitialState();case"DEFAULT_STATE_FIELDS_VALUES_SETTER":return{...t,...null!==(r=o.overwrites)&&void 0!==r?r:{}};default:return i.reducer(t,o)}}});return window.ftReduxStores[e.name]=new Er(i,a)}constructor(t,o){this.reduxSlice=t,this.reduxStore=o,this.isFtReduxStore=!0,this.eventBus=document.createElement("event-bus"),this.actions=new Proxy(this.reduxSlice.actions,{get:(t,o,r)=>{const e=o,n=t[e];return n?(...t)=>{const o=n(...t);return this.reduxStore.dispatch(o),o}:t=>{this.setState({[e]:t})}}})}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE"})}setState(t){this.reduxStore.dispatch({type:"DEFAULT_STATE_FIELDS_VALUES_SETTER",overwrites:t})}get dispatch(){throw new Error("Don't use this method, actions are automatically dispatched when called.")}[Symbol.observable](){return this.reduxStore[Symbol.observable]()}getState(){return this.reduxStore.getState()}replaceReducer(t){throw new Error("Not implemented yet.")}subscribe(t){return this.reduxStore.subscribe(t)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}}const Rr=t=>{const o=null!=t?t:{};return(t,r)=>{var e;const n={hasChanged:(t,o)=>!l(t,o),attribute:!1,...o};a(n)(t,r);const i=t;i.reduxProperties=i.reduxProperties||new Map,i.reduxProperties.set(r,{selector:null!==(e=o.selector)&&void 0!==e?e:t=>t[r],store:o.store})}};var Cr,Ur;navigator.vendor&&navigator.vendor.match(/apple/i)||(null===(Ur=null===(Cr=window.safari)||void 0===Cr?void 0:Cr.pushNotification)||void 0===Ur||Ur.toString());class xr{constructor(t){this.paginatedToc=t,this.nodeByTocId={},this.knownPrettyUrls=new Set,this.duplicatedPrettyUrls=new Set,this.pages=[],this.pageByTocId={}}build(){return{paginationConfiguration:this.paginatedToc.configuration,toc:this.convertNodes(this.paginatedToc.paginatedToc,1),pagesToc:this.extractPagesToc(this.paginatedToc.paginatedToc,1),nodeByTocId:this.nodeByTocId,duplicatedPrettyUrls:this.duplicatedPrettyUrls,pages:this.pages,pageByTocId:this.pageByTocId}}extractPagesToc(t,o,r){return t.flatMap((t=>(t.pageConfiguration&&this.registerPage(this.buildPage(t,r)),null==t.tocId?this.extractPagesToc(t.children,o,r):[{tocId:t.tocId,title:t.title,depth:o,children:this.extractPagesToc(t.children,o+1,t.tocId)}])))}convertNodes(t,o,r){return t.flatMap((t=>{var e,n,i;if(null==t.tocId)return[...this.convertSectionNodes(null!==(e=t.pageToc)&&void 0!==e?e:[],o,t.tocId),...this.convertNodes(t.children,o,t.tocId)];let a=null===(n=t.prettyUrl)||void 0===n?void 0:n.replace(/^\//,"");const c={tocId:t.tocId,contentId:t.contentId,title:t.title,hasRating:t.hasRating,origin:t.origin,prettyUrl:a,depth:o,parentTocId:r,children:[]};this.register(c);const s=this.convertSectionNodes(null!==(i=t.pageToc)&&void 0!==i?i:[],o+1,t.tocId),l=this.convertNodes(t.children,o+1,c.tocId);return c.children=[...s,...l],[c]}))}convertSectionNodes(t,o,r){return t.flatMap((t=>{var e;let n=null===(e=t.prettyUrl)||void 0===e?void 0:e.replace(/^\//,"");const i={...t,prettyUrl:n,depth:o,parentTocId:r,children:[]};return this.register(i),i.children=this.convertSectionNodes(t.children,o+1,t.tocId),[i]}))}buildPage(t,o){var r,e,n,i,a,c;const s={number:this.pages.length+1,title:null!==(r=t.title)&&void 0!==r?r:"",rootTocId:null!==(e=t.tocId)&&void 0!==e?e:"root",toc:(null!==(n=t.pageToc)&&void 0!==n?n:[]).map((t=>this.nodeByTocId[t.tocId])),topics:[],hiddenTopics:[],breadcrumb:o?this.buildBreadcrumb(this.nodeByTocId[o]):[]},l=(t,o)=>(o?s.topics:s.hiddenTopics).push(t),f=null!==(a=null===(i=t.pageConfiguration)||void 0===i?void 0:i.parentsVisibility)&&void 0!==a?a:[];return s.breadcrumb.forEach(((t,o)=>{l(t,f[o])})),t.tocId&&l(t.tocId,t.pageConfiguration.isVisible),s.topics.push(...this.tocIds(null!==(c=t.pageToc)&&void 0!==c?c:[])),s}registerPage(t){for(let o of[...t.topics,...t.hiddenTopics])this.pageByTocId[o]||(this.pageByTocId[o]=t);this.pages.push(t)}tocIds(t){return t.flatMap((t=>[t.tocId,...this.tocIds(t.children)]))}buildBreadcrumb(t){const o=[t.tocId];for(;null==t?void 0:t.parentTocId;)o.unshift(t.parentTocId),t=this.nodeByTocId[t.parentTocId];return o}register(t){t.prettyUrl&&(this.knownPrettyUrls.has(t.prettyUrl)&&this.duplicatedPrettyUrls.add(t.prettyUrl),this.knownPrettyUrls.add(t.prettyUrl)),this.nodeByTocId[t.tocId]=t}}class Ir{convertPaginatedToc(t){return new xr(t).build()}}!function(t){!function(o){var r={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch(t){return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};if(r.arrayBuffer)var e=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],n=ArrayBuffer.isView||function(t){return t&&e.indexOf(Object.prototype.toString.call(t))>-1};function i(t){if("string"!=typeof t&&(t=String(t)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(t))throw new TypeError("Invalid character in header field name");return t.toLowerCase()}function a(t){return"string"!=typeof t&&(t=String(t)),t}function c(t){var o={next:function(){var o=t.shift();return{done:void 0===o,value:o}}};return r.iterable&&(o[Symbol.iterator]=function(){return o}),o}function s(t){this.map={},t instanceof s?t.forEach((function(t,o){this.append(o,t)}),this):Array.isArray(t)?t.forEach((function(t){this.append(t[0],t[1])}),this):t&&Object.getOwnPropertyNames(t).forEach((function(o){this.append(o,t[o])}),this)}function l(t){if(t.bodyUsed)return Promise.reject(new TypeError("Already read"));t.bodyUsed=!0}function f(t){return new Promise((function(o,r){t.onload=function(){o(t.result)},t.onerror=function(){r(t.error)}}))}function u(t){var o=new FileReader,r=f(o);return o.readAsArrayBuffer(t),r}function h(t){if(t.slice)return t.slice(0);var o=new Uint8Array(t.byteLength);return o.set(new Uint8Array(t)),o.buffer}function d(){return this.bodyUsed=!1,this._initBody=function(t){var o;this._bodyInit=t,t?"string"==typeof t?this._bodyText=t:r.blob&&Blob.prototype.isPrototypeOf(t)?this._bodyBlob=t:r.formData&&FormData.prototype.isPrototypeOf(t)?this._bodyFormData=t:r.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)?this._bodyText=t.toString():r.arrayBuffer&&r.blob&&((o=t)&&DataView.prototype.isPrototypeOf(o))?(this._bodyArrayBuffer=h(t.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):r.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(t)||n(t))?this._bodyArrayBuffer=h(t):this._bodyText=t=Object.prototype.toString.call(t):this._bodyText="",this.headers.get("content-type")||("string"==typeof t?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):r.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},r.blob&&(this.blob=function(){var t=l(this);if(t)return t;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?l(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(u)}),this.text=function(){var t=l(this);if(t)return t;if(this._bodyBlob)return function(t){var o=new FileReader,r=f(o);return o.readAsText(t),r}(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(function(t){for(var o=new Uint8Array(t),r=new Array(o.length),e=0;e<o.length;e++)r[e]=String.fromCharCode(o[e]);return r.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},r.formData&&(this.formData=function(){return this.text().then(b)}),this.json=function(){return this.text().then(JSON.parse)},this}s.prototype.append=function(t,o){t=i(t),o=a(o);var r=this.map[t];this.map[t]=r?r+", "+o:o},s.prototype.delete=function(t){delete this.map[i(t)]},s.prototype.get=function(t){return t=i(t),this.has(t)?this.map[t]:null},s.prototype.has=function(t){return this.map.hasOwnProperty(i(t))},s.prototype.set=function(t,o){this.map[i(t)]=a(o)},s.prototype.forEach=function(t,o){for(var r in this.map)this.map.hasOwnProperty(r)&&t.call(o,this.map[r],r,this)},s.prototype.keys=function(){var t=[];return this.forEach((function(o,r){t.push(r)})),c(t)},s.prototype.values=function(){var t=[];return this.forEach((function(o){t.push(o)})),c(t)},s.prototype.entries=function(){var t=[];return this.forEach((function(o,r){t.push([r,o])})),c(t)},r.iterable&&(s.prototype[Symbol.iterator]=s.prototype.entries);var p=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function y(t,o){var r,e,n=(o=o||{}).body;if(t instanceof y){if(t.bodyUsed)throw new TypeError("Already read");this.url=t.url,this.credentials=t.credentials,o.headers||(this.headers=new s(t.headers)),this.method=t.method,this.mode=t.mode,this.signal=t.signal,n||null==t._bodyInit||(n=t._bodyInit,t.bodyUsed=!0)}else this.url=String(t);if(this.credentials=o.credentials||this.credentials||"same-origin",!o.headers&&this.headers||(this.headers=new s(o.headers)),this.method=(r=o.method||this.method||"GET",e=r.toUpperCase(),p.indexOf(e)>-1?e:r),this.mode=o.mode||this.mode||null,this.signal=o.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&n)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(n)}function b(t){var o=new FormData;return t.trim().split("&").forEach((function(t){if(t){var r=t.split("="),e=r.shift().replace(/\+/g," "),n=r.join("=").replace(/\+/g," ");o.append(decodeURIComponent(e),decodeURIComponent(n))}})),o}function g(t,o){o||(o={}),this.type="default",this.status=void 0===o.status?200:o.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in o?o.statusText:"OK",this.headers=new s(o.headers),this.url=o.url||"",this._initBody(t)}y.prototype.clone=function(){return new y(this,{body:this._bodyInit})},d.call(y.prototype),d.call(g.prototype),g.prototype.clone=function(){return new g(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new s(this.headers),url:this.url})},g.error=function(){var t=new g(null,{status:0,statusText:""});return t.type="error",t};var v=[301,302,303,307,308];g.redirect=function(t,o){if(-1===v.indexOf(o))throw new RangeError("Invalid status code");return new g(null,{status:o,headers:{location:t}})},o.DOMException=t.DOMException;try{new o.DOMException}catch(t){o.DOMException=function(t,o){this.message=t,this.name=o;var r=Error(t);this.stack=r.stack},o.DOMException.prototype=Object.create(Error.prototype),o.DOMException.prototype.constructor=o.DOMException}function m(t,e){return new Promise((function(n,i){var a=new y(t,e);if(a.signal&&a.signal.aborted)return i(new o.DOMException("Aborted","AbortError"));var c=new XMLHttpRequest;function l(){c.abort()}c.onload=function(){var t,o,r={status:c.status,statusText:c.statusText,headers:(t=c.getAllResponseHeaders()||"",o=new s,t.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(t){var r=t.split(":"),e=r.shift().trim();if(e){var n=r.join(":").trim();o.append(e,n)}})),o)};r.url="responseURL"in c?c.responseURL:r.headers.get("X-Request-URL");var e="response"in c?c.response:c.responseText;n(new g(e,r))},c.onerror=function(){i(new TypeError("Network request failed"))},c.ontimeout=function(){i(new TypeError("Network request failed"))},c.onabort=function(){i(new o.DOMException("Aborted","AbortError"))},c.open(a.method,a.url,!0),"include"===a.credentials?c.withCredentials=!0:"omit"===a.credentials&&(c.withCredentials=!1),"responseType"in c&&r.blob&&(c.responseType="blob"),a.headers.forEach((function(t,o){c.setRequestHeader(o,t)})),a.signal&&(a.signal.addEventListener("abort",l),c.onreadystatechange=function(){4===c.readyState&&a.signal.removeEventListener("abort",l)}),c.send(void 0===a._bodyInit?null:a._bodyInit)}))}m.polyfill=!0,t.fetch||(t.fetch=m,t.Headers=s,t.Request=y,t.Response=g),o.Headers=s,o.Request=y,o.Response=g,o.fetch=m,Object.defineProperty(o,"U",{value:!0})}({})}("undefined"!=typeof self?self:void 0);const Lr=t=>"object"==typeof t&&null!=t,Ar=t=>"string"==typeof t;var kr,Wr,Kr,Tr,jr,Pr,Mr,Fr,Zr,Br,Dr,_r;!function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"}(kr||(kr={})),function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"}(Wr||(Wr={})),function(t){t.THIRD_PARTY="THIRD_PARTY",t.OFF_THE_GRID="OFF_THE_GRID",t.CONTENT_PACKAGER="CONTENT_PACKAGER",t.PAGES="PAGES",t.DESIGNED_READER="DESIGNED_READER"}(Kr||(Kr={})),function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"}(Tr||(Tr={})),function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"}(jr||(jr={})),function(t){t.ASC="ASC",t.DESC="DESC"}(Pr||(Pr={})),function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"}(Mr||(Mr={})),function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK"}(Fr||(Fr={})),function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"}(Zr||(Zr={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK"}(Br||(Br={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC"}(Dr||(Dr={})),function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN",t.DEVELOPER="DEVELOPER"}(_r||(_r={}));const $r=t=>Lr(t)&&(null==t.authenticationIdentifier||(t=>Lr(t)&&Ar(t.identifier)&&Ar(t.realm))(t.authenticationIdentifier))&&(t=>"number"==typeof t)(t.idleTimeoutInMillis)&&zr(t.profile)&&(t=>"boolean"==typeof t)(t.sessionAuthenticated),zr=t=>Lr(t)&&(null==t.emailAddress||Ar(t.emailAddress))&&(null==t.displayName||Ar(t.displayName))&&Array.isArray(t.roles)&&t.roles.every((t=>(t=>["PERSONAL_BOOK_USER","PERSONAL_BOOK_SHARE_USER","HTML_EXPORT_USER","PDF_EXPORT_USER","SAVED_SEARCH_USER","COLLECTION_USER","OFFLINE_USER","ANALYTICS_USER","BETA_USER","DEBUG_USER","PRINT_USER","RATING_USER","FEEDBACK_USER","CONTENT_PUBLISHER","KHUB_ADMIN","USERS_ADMIN","PORTAL_ADMIN","ADMIN","DEVELOPER"].includes(t))(t)))&&(null==t.userId||Ar(t.userId)),Gr={[_r.PERSONAL_BOOK_SHARE_USER]:[_r.PERSONAL_BOOK_USER],[_r.HTML_EXPORT_USER]:[_r.PERSONAL_BOOK_USER],[_r.PDF_EXPORT_USER]:[_r.PERSONAL_BOOK_USER],[_r.KHUB_ADMIN]:[_r.CONTENT_PUBLISHER],[_r.ADMIN]:[_r.KHUB_ADMIN,_r.USERS_ADMIN,_r.PORTAL_ADMIN],[_r.DEVELOPER]:[_r.BETA_USER,_r.DEBUG_USER]};function Hr(t,o){return t===o||(Gr[t]??[]).some((t=>Hr(t,o)))}function qr(t,o){return($r(t)?t.profile.roles:zr(t)?t.roles:t).some((t=>Hr(t,o)))}var Vr;t.FtReaderFeatures=void 0,(Vr=t.FtReaderFeatures||(t.FtReaderFeatures={})).FEEDBACK="FEEDBACK",Vr.RATING="RATING",Vr.PRINT="PRINT",Vr.BOOKMARK="BOOKMARK",Vr.COLLECTIONS="COLLECTIONS";const Yr=v`
82
- `,Xr=Er.get({name:"ft-app-info",reducers:{setBaseUrl:(t,o)=>{t.baseUrl=o.payload},setApiIntegrationIdentifier:(t,o)=>{t.apiIntegrationIdentifier=o.payload},setUiLocale:(t,o)=>{t.uiLocale=o.payload},setAvailableUiLocales:(t,o)=>{t.availableUiLocales=o.payload},setEditorMode:(t,o)=>{t.editorMode=o.payload},setNoCustom:(t,o)=>{t.noCustom=o.payload},setNoCustomComponent:(t,o)=>{t.noCustomComponent=o.payload},setSession:(t,o)=>{t.session=o.payload}},initialState:{uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],editorMode:!1,noCustom:!1,noCustomComponent:!1}});class Jr{static build(t){const{baseUrl:o,apiIntegrationIdentifier:r}=Xr.getState(),e=null!=t?t:r;if(o&&e&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,e,!0)}static get(t){var o;return null!=t?Jr.build(t):null!==(o=Jr.API)&&void 0!==o?o:Jr.API=Jr.build()}static await(t){return new Promise((o=>{let r=Jr.get(t);if(r)o(r);else{const e=Xr.subscribe((()=>{r=Jr.get(t),r&&(e(),o(r))}))}}))}}var Qr;const te=Symbol("clearAfterUnitTest");class oe{constructor(t){this.messageContextProvider=t,this.defaultMessages={},this.cache=new e,this.listeners={},this.currentUiLocale="",this[Qr]=()=>{this.defaultMessages={},this.cache=new e,this.listeners={}},this.currentUiLocale=Xr.getState().uiLocale,Xr.subscribe((()=>this.clearWhenUiLocaleChanges()))}clearWhenUiLocaleChanges(){const{uiLocale:t}=Xr.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){const o=t.name.toLowerCase();this.cache.setFinal(o,t),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,o){var r;if(t=t.toLowerCase(),Object.keys(o).length>0){const e={...null!==(r=this.defaultMessages[t])&&void 0!==r?r:{},...o};l(this.defaultMessages[t],e)||(this.defaultMessages[t]=e,await this.notify(t))}await this.fetchContext(t)}resolveMessage(t,o,...r){var e,n,i;t=t.toLowerCase(),this.fetchContext(t);const a=null!==(n=null===(e=this.cache.getNow(t))||void 0===e?void 0:e.messages)&&void 0!==n?n:{};return new Ut(null!==(i=this.defaultMessages[t])&&void 0!==i?i:{},a).resolve(o,...r)}async fetchContext(t){if(!this.cache.has(t))try{await this.cache.get(t,(()=>this.messageContextProvider(this.currentUiLocale,t))),await this.notify(t)}catch(t){console.error(t)}}subscribe(t,o){var r;return t=t.toLowerCase(),this.listeners[t]=null!==(r=this.listeners[t])&&void 0!==r?r:new Set,this.listeners[t].add(o),()=>{var r;return null===(r=this.listeners[t])||void 0===r?void 0:r.delete(o)}}async notifyAll(){await Promise.all(Object.keys(this.listeners).map((t=>this.notify(t))))}async notify(t){null!=this.listeners[t]&&await Promise.all([...this.listeners[t].values()].map((t=>s(0).then((()=>t())).catch((()=>null)))))}}Qr=te,null==window.FluidTopicsI18nService&&(window.FluidTopicsI18nService=new oe((async(t,o)=>(await Jr.await()).getFluidTopicsMessageContext(t,o)))),null==window.FluidTopicsCustomI18nService&&(window.FluidTopicsCustomI18nService=new oe((async(t,o)=>(await Jr.await()).getCustomMessageContext(t,o))));const re=window.FluidTopicsI18nService;var ee=function(t,o,r,e){for(var n,i=arguments.length,a=i<3?o:null===e?e=Object.getOwnPropertyDescriptor(o,r):e,c=t.length-1;c>=0;c--)(n=t[c])&&(a=(i<3?n(a):i>3?n(o,r,a):n(o,r))||a);return i>3&&a&&Object.defineProperty(o,r,a),a};class ne extends Ct{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.availableUiLocales=[],this.editorMode=!1,this.noCustom=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.messageContexts=[],this.apiProvider=()=>Jr.get(),this.cache=new e,this.cleanSessionDebouncer=new n}render(){return Y`
81
+ `;class Ut{constructor(t,o){this.defaultLabels=t,this.labels=o}resolve(t,...o){var r,e;t=this.resolvePluralKey(t,o);let n=null!==(e=null!==(r=this.labels[t])&&void 0!==r?r:this.defaultLabels[t])&&void 0!==e?e:"";return o.forEach(((t,o)=>n=n.replace(new RegExp(`\\{${o}([^}]*)\\}`,"g"),((o,r)=>this.formatValue(t,r))))),n}resolvePluralKey(t,o){for(let r of o)if("number"==typeof r){const o=`${String(t)}[\\=${r}]`;if(o in this.labels||o in this.defaultLabels)return o}return t}formatValue(t,o){return t instanceof Date?this.formatDate(t,o):null!=t?t:""}formatDate(t,o){const r=r=>(null==o?void 0:o.includes("date"))?t.toLocaleDateString(r):(null==o?void 0:o.includes("time"))?t.toLocaleTimeString(r):t.toLocaleString(r);try{return r(document.documentElement.lang)}catch(t){return r()}}}function xt(t){var o;return null!==(o=null==t?void 0:t.isFtReduxStore)&&void 0!==o&&o}var It,Lt,At;const kt=Symbol("internalReduxEventsUnsubscribers"),Wt=Symbol("internalStoresUnsubscribers"),Kt=Symbol("internalStores");class Tt extends Rt{constructor(){super(...arguments),this[It]=new Map,this[Lt]=new Map,this[At]=[]}update(t){var o;super.update(t),(null===(o=this.reduxReactiveProperties)||void 0===o?void 0:o.some((o=>t.has(o))))&&this.updateFromStores()}getUnnamedStore(){if(this[Kt].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Kt].values()][0]}getStore(t){return null==t?this.getUnnamedStore():this[Kt].get(t)}addStore(t,o){var r;o=null!==(r=null!=o?o:xt(t)?t.name:void 0)&&void 0!==r?r:"default-store",this.unsubscribeFromStore(o),this.setupStore(o,t)}removeStore(t){const o="string"==typeof t?t:t.name;this.unsubscribeFromStore(o),this[Kt].delete(o)}setupStore(t,o){this[Kt].set(t,o),this.subscribeToStore(t,o),this.updateFromStores()}setupStores(){this.unsubscribeFromStores(),this[Kt].forEach(((t,o)=>this.subscribeToStore(o,t))),this.updateFromStores()}updateFromStores(){this.reduxProperties&&this.reduxProperties.forEach(((t,o)=>{const r=this.constructor.getPropertyOptions(o);if(!(null==r?void 0:r.attribute)||!this.hasAttribute("string"==typeof(null==r?void 0:r.attribute)?r.attribute:o)){const r=this.getStore(t.store);r&&(t.store?this[Wt].has(t.store):this[Wt].size>0)&&(this[o]=t.selector(r.getState(),this))}}))}subscribeToStore(t,o){var r;this[Wt].set(t,o.subscribe((()=>this.updateFromStores()))),xt(o)&&o.eventBus&&(null===(r=this.reduxEventListeners)||void 0===r||r.forEach(((t,r)=>{if("function"==typeof this[r]&&(!t.store||o.name===t.store)){const e=t=>this[r](t);o.eventBus.addEventListener(t.eventName,e),this[kt].push((()=>o.eventBus.removeEventListener(t.eventName,e)))}}))),this.onStoreAvailable(t)}unsubscribeFromStores(){this[Wt].forEach(((t,o)=>this.unsubscribeFromStore(o))),this[kt].forEach((t=>t())),this[kt]=[]}unsubscribeFromStore(t){this[Wt].has(t)&&this[Wt].get(t)(),this[Wt].delete(t)}onStoreAvailable(t){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}function jt(t){for(var o=arguments.length,r=Array(o>1?o-1:0),e=1;e<o;e++)r[e-1]=arguments[e];throw Error("[Immer] minified error nr: "+t+(r.length?" "+r.map((function(t){return"'"+t+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Mt(t){return!!t&&!!t[Eo]}function Pt(t){var o;return!!t&&(function(t){if(!t||"object"!=typeof t)return!1;var o=Object.getPrototypeOf(t);if(null===o)return!0;var r=Object.hasOwnProperty.call(o,"constructor")&&o.constructor;return r===Object||"function"==typeof r&&Function.toString.call(r)===Co}(t)||Array.isArray(t)||!!t[So]||!!(null===(o=t.constructor)||void 0===o?void 0:o[So])||$t(t)||zt(t))}function Ft(t,o,r){void 0===r&&(r=!1),0===Zt(t)?(r?Object.keys:Ro)(t).forEach((function(e){r&&"symbol"==typeof e||o(e,t[e],t)})):t.forEach((function(r,e){return o(e,r,t)}))}function Zt(t){var o=t[Eo];return o?o.i>3?o.i-4:o.i:Array.isArray(t)?1:$t(t)?2:zt(t)?3:0}function Bt(t,o){return 2===Zt(t)?t.has(o):Object.prototype.hasOwnProperty.call(t,o)}function Dt(t,o,r){var e=Zt(t);2===e?t.set(o,r):3===e?t.add(r):t[o]=r}function _t(t,o){return t===o?0!==t||1/t==1/o:t!=t&&o!=o}function $t(t){return mo&&t instanceof Map}function zt(t){return Oo&&t instanceof Set}function Gt(t){return t.o||t.t}function Ht(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var o=Uo(t);delete o[Eo];for(var r=Ro(o),e=0;e<r.length;e++){var n=r[e],i=o[n];!1===i.writable&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(o[n]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[n]})}return Object.create(Object.getPrototypeOf(t),o)}function qt(t,o){return void 0===o&&(o=!1),Vt(t)||Mt(t)||!Pt(t)||(Zt(t)>1&&(t.set=t.add=t.clear=t.delete=Yt),Object.freeze(t),o&&Ft(t,(function(t,o){return qt(o,!0)}),!0)),t}function Yt(){jt(2)}function Vt(t){return null==t||"object"!=typeof t||Object.isFrozen(t)}function Xt(t){var o=xo[t];return o||jt(18,t),o}function Jt(){return go}function Qt(t,o){o&&(Xt("Patches"),t.u=[],t.s=[],t.v=o)}function to(t){oo(t),t.p.forEach(eo),t.p=null}function oo(t){t===go&&(go=t.l)}function ro(t){return go={p:[],l:go,h:t,m:!0,_:0}}function eo(t){var o=t[Eo];0===o.i||1===o.i?o.j():o.g=!0}function no(t,o){o._=o.p.length;var r=o.p[0],e=void 0!==t&&t!==r;return o.h.O||Xt("ES5").S(o,t,e),e?(r[Eo].P&&(to(o),jt(4)),Pt(t)&&(t=io(o,t),o.l||so(o,t)),o.u&&Xt("Patches").M(r[Eo].t,t,o.u,o.s)):t=io(o,r,[]),to(o),o.u&&o.v(o.u,o.s),t!==wo?t:void 0}function io(t,o,r){if(Vt(o))return o;var e=o[Eo];if(!e)return Ft(o,(function(n,i){return ao(t,e,o,n,i,r)}),!0),o;if(e.A!==t)return o;if(!e.P)return so(t,e.t,!0),e.t;if(!e.I){e.I=!0,e.A._--;var n=4===e.i||5===e.i?e.o=Ht(e.k):e.o,i=n,a=!1;3===e.i&&(i=new Set(n),n.clear(),a=!0),Ft(i,(function(o,i){return ao(t,e,n,o,i,r,a)})),so(t,n,!1),r&&t.u&&Xt("Patches").N(e,r,t.u,t.s)}return e.o}function ao(t,o,r,e,n,i,a){if(Mt(n)){var s=io(t,n,i&&o&&3!==o.i&&!Bt(o.R,e)?i.concat(e):void 0);if(Dt(r,e,s),!Mt(s))return;t.m=!1}else a&&r.add(n);if(Pt(n)&&!Vt(n)){if(!t.h.D&&t._<1)return;io(t,n),o&&o.A.l||so(t,n)}}function so(t,o,r){void 0===r&&(r=!1),!t.l&&t.h.D&&t.m&&qt(o,r)}function co(t,o){var r=t[Eo];return(r?Gt(r):t)[o]}function lo(t,o){if(o in t)for(var r=Object.getPrototypeOf(t);r;){var e=Object.getOwnPropertyDescriptor(r,o);if(e)return e;r=Object.getPrototypeOf(r)}}function fo(t){t.P||(t.P=!0,t.l&&fo(t.l))}function uo(t){t.o||(t.o=Ht(t.t))}function ho(t,o,r){var e=$t(o)?Xt("MapSet").F(o,r):zt(o)?Xt("MapSet").T(o,r):t.O?function(t,o){var r=Array.isArray(t),e={i:r?1:0,A:o?o.A:Jt(),P:!1,I:!1,R:{},l:o,t,k:null,o:null,j:null,C:!1},n=e,i=Io;r&&(n=[e],i=Lo);var a=Proxy.revocable(n,i),s=a.revoke,c=a.proxy;return e.k=c,e.j=s,c}(o,r):Xt("ES5").J(o,r);return(r?r.A:Jt()).p.push(e),e}function po(t){return Mt(t)||jt(22,t),function t(o){if(!Pt(o))return o;var r,e=o[Eo],n=Zt(o);if(e){if(!e.P&&(e.i<4||!Xt("ES5").K(e)))return e.t;e.I=!0,r=yo(o,n),e.I=!1}else r=yo(o,n);return Ft(r,(function(o,n){e&&function(t,o){return 2===Zt(t)?t.get(o):t[o]}(e.t,o)===n||Dt(r,o,t(n))})),3===n?new Set(r):r}(t)}function yo(t,o){switch(o){case 2:return new Map(t);case 3:return Array.from(t)}return Ht(t)}It=Wt,Lt=Kt,At=kt;var bo,go,vo="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),mo="undefined"!=typeof Map,Oo="undefined"!=typeof Set,No="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,wo=vo?Symbol.for("immer-nothing"):((bo={})["immer-nothing"]=!0,bo),So=vo?Symbol.for("immer-draftable"):"__$immer_draftable",Eo=vo?Symbol.for("immer-state"):"__$immer_state",Co=""+Object.prototype.constructor,Ro="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,Uo=Object.getOwnPropertyDescriptors||function(t){var o={};return Ro(t).forEach((function(r){o[r]=Object.getOwnPropertyDescriptor(t,r)})),o},xo={},Io={get:function(t,o){if(o===Eo)return t;var r=Gt(t);if(!Bt(r,o))return function(t,o,r){var e,n=lo(o,r);return n?"value"in n?n.value:null===(e=n.get)||void 0===e?void 0:e.call(t.k):void 0}(t,r,o);var e=r[o];return t.I||!Pt(e)?e:e===co(t.t,o)?(uo(t),t.o[o]=ho(t.A.h,e,t)):e},has:function(t,o){return o in Gt(t)},ownKeys:function(t){return Reflect.ownKeys(Gt(t))},set:function(t,o,r){var e=lo(Gt(t),o);if(null==e?void 0:e.set)return e.set.call(t.k,r),!0;if(!t.P){var n=co(Gt(t),o),i=null==n?void 0:n[Eo];if(i&&i.t===r)return t.o[o]=r,t.R[o]=!1,!0;if(_t(r,n)&&(void 0!==r||Bt(t.t,o)))return!0;uo(t),fo(t)}return t.o[o]===r&&(void 0!==r||o in t.o)||Number.isNaN(r)&&Number.isNaN(t.o[o])||(t.o[o]=r,t.R[o]=!0),!0},deleteProperty:function(t,o){return void 0!==co(t.t,o)||o in t.t?(t.R[o]=!1,uo(t),fo(t)):delete t.R[o],t.o&&delete t.o[o],!0},getOwnPropertyDescriptor:function(t,o){var r=Gt(t),e=Reflect.getOwnPropertyDescriptor(r,o);return e?{writable:!0,configurable:1!==t.i||"length"!==o,enumerable:e.enumerable,value:r[o]}:e},defineProperty:function(){jt(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){jt(12)}},Lo={};Ft(Io,(function(t,o){Lo[t]=function(){return arguments[0]=arguments[0][0],o.apply(this,arguments)}})),Lo.deleteProperty=function(t,o){return Lo.set.call(this,t,o,void 0)},Lo.set=function(t,o,r){return Io.set.call(this,t[0],o,r,t[0])};var Ao=function(){function t(t){var o=this;this.O=No,this.D=!0,this.produce=function(t,r,e){if("function"==typeof t&&"function"!=typeof r){var n=r;r=t;var i=o;return function(t){var o=this;void 0===t&&(t=n);for(var e=arguments.length,a=Array(e>1?e-1:0),s=1;s<e;s++)a[s-1]=arguments[s];return i.produce(t,(function(t){var e;return(e=r).call.apply(e,[o,t].concat(a))}))}}var a;if("function"!=typeof r&&jt(6),void 0!==e&&"function"!=typeof e&&jt(7),Pt(t)){var s=ro(o),c=ho(o,t,void 0),l=!0;try{a=r(c),l=!1}finally{l?to(s):oo(s)}return"undefined"!=typeof Promise&&a instanceof Promise?a.then((function(t){return Qt(s,e),no(t,s)}),(function(t){throw to(s),t})):(Qt(s,e),no(a,s))}if(!t||"object"!=typeof t){if(void 0===(a=r(t))&&(a=t),a===wo&&(a=void 0),o.D&&qt(a,!0),e){var f=[],u=[];Xt("Patches").M(t,a,f,u),e(f,u)}return a}jt(21,t)},this.produceWithPatches=function(t,r){if("function"==typeof t)return function(r){for(var e=arguments.length,n=Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];return o.produceWithPatches(r,(function(o){return t.apply(void 0,[o].concat(n))}))};var e,n,i=o.produce(t,r,(function(t,o){e=t,n=o}));return"undefined"!=typeof Promise&&i instanceof Promise?i.then((function(t){return[t,e,n]})):[i,e,n]},"boolean"==typeof(null==t?void 0:t.useProxies)&&this.setUseProxies(t.useProxies),"boolean"==typeof(null==t?void 0:t.autoFreeze)&&this.setAutoFreeze(t.autoFreeze)}var o=t.prototype;return o.createDraft=function(t){Pt(t)||jt(8),Mt(t)&&(t=po(t));var o=ro(this),r=ho(this,t,void 0);return r[Eo].C=!0,oo(o),r},o.finishDraft=function(t,o){var r=(t&&t[Eo]).A;return Qt(r,o),no(void 0,r)},o.setAutoFreeze=function(t){this.D=t},o.setUseProxies=function(t){t&&!No&&jt(20),this.O=t},o.applyPatches=function(t,o){var r;for(r=o.length-1;r>=0;r--){var e=o[r];if(0===e.path.length&&"replace"===e.op){t=e.value;break}}r>-1&&(o=o.slice(r+1));var n=Xt("Patches").$;return Mt(t)?n(t,o):this.produce(t,(function(t){return n(t,o)}))},t}(),ko=new Ao,Wo=ko.produce;function Ko(t){return Ko="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ko(t)}function To(t){var o=function(t,o){if("object"!==Ko(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var e=r.call(t,o||"default");if("object"!==Ko(e))return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===o?String:Number)(t)}(t,"string");return"symbol"===Ko(o)?o:String(o)}function jo(t,o,r){return(o=To(o))in t?Object.defineProperty(t,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[o]=r,t}function Mo(t,o){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var e=Object.getOwnPropertySymbols(t);o&&(e=e.filter((function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable}))),r.push.apply(r,e)}return r}function Po(t){for(var o=1;o<arguments.length;o++){var r=null!=arguments[o]?arguments[o]:{};o%2?Mo(Object(r),!0).forEach((function(o){jo(t,o,r[o])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Mo(Object(r)).forEach((function(o){Object.defineProperty(t,o,Object.getOwnPropertyDescriptor(r,o))}))}return t}function Fo(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}ko.produceWithPatches.bind(ko),ko.setAutoFreeze.bind(ko),ko.setUseProxies.bind(ko),ko.applyPatches.bind(ko),ko.createDraft.bind(ko),ko.finishDraft.bind(ko);var Zo="function"==typeof Symbol&&Symbol.observable||"@@observable",Bo=function(){return Math.random().toString(36).substring(7).split("").join(".")},Do={INIT:"@@redux/INIT"+Bo(),REPLACE:"@@redux/REPLACE"+Bo(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Bo()}};function _o(t,o,r){var e;if("function"==typeof o&&"function"==typeof r||"function"==typeof r&&"function"==typeof arguments[3])throw new Error(Fo(0));if("function"==typeof o&&void 0===r&&(r=o,o=void 0),void 0!==r){if("function"!=typeof r)throw new Error(Fo(1));return r(_o)(t,o)}if("function"!=typeof t)throw new Error(Fo(2));var n=t,i=o,a=[],s=a,c=!1;function l(){s===a&&(s=a.slice())}function f(){if(c)throw new Error(Fo(3));return i}function u(t){if("function"!=typeof t)throw new Error(Fo(4));if(c)throw new Error(Fo(5));var o=!0;return l(),s.push(t),function(){if(o){if(c)throw new Error(Fo(6));o=!1,l();var r=s.indexOf(t);s.splice(r,1),a=null}}}function h(t){if(!function(t){if("object"!=typeof t||null===t)return!1;for(var o=t;null!==Object.getPrototypeOf(o);)o=Object.getPrototypeOf(o);return Object.getPrototypeOf(t)===o}(t))throw new Error(Fo(7));if(void 0===t.type)throw new Error(Fo(8));if(c)throw new Error(Fo(9));try{c=!0,i=n(i,t)}finally{c=!1}for(var o=a=s,r=0;r<o.length;r++){(0,o[r])()}return t}return h({type:Do.INIT}),(e={dispatch:h,subscribe:u,getState:f,replaceReducer:function(t){if("function"!=typeof t)throw new Error(Fo(10));n=t,h({type:Do.REPLACE})}})[Zo]=function(){var t,o=u;return(t={subscribe:function(t){if("object"!=typeof t||null===t)throw new Error(Fo(11));function r(){t.next&&t.next(f())}return r(),{unsubscribe:o(r)}}})[Zo]=function(){return this},t},e}function $o(t){for(var o=Object.keys(t),r={},e=0;e<o.length;e++){var n=o[e];"function"==typeof t[n]&&(r[n]=t[n])}var i,a=Object.keys(r);try{!function(t){Object.keys(t).forEach((function(o){var r=t[o];if(void 0===r(void 0,{type:Do.INIT}))throw new Error(Fo(12));if(void 0===r(void 0,{type:Do.PROBE_UNKNOWN_ACTION()}))throw new Error(Fo(13))}))}(r)}catch(t){i=t}return function(t,o){if(void 0===t&&(t={}),i)throw i;for(var e=!1,n={},s=0;s<a.length;s++){var c=a[s],l=r[c],f=t[c],u=l(f,o);if(void 0===u)throw o&&o.type,new Error(Fo(14));n[c]=u,e=e||u!==f}return(e=e||a.length!==Object.keys(t).length)?n:t}}function zo(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return 0===o.length?function(t){return t}:1===o.length?o[0]:o.reduce((function(t,o){return function(){return t(o.apply(void 0,arguments))}}))}function Go(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return function(t){return function(){var r=t.apply(void 0,arguments),e=function(){throw new Error(Fo(15))},n={getState:r.getState,dispatch:function(){return e.apply(void 0,arguments)}},i=o.map((function(t){return t(n)}));return e=zo.apply(void 0,i)(r.dispatch),Po(Po({},r),{},{dispatch:e})}}}function Ho(t){return function(o){var r=o.dispatch,e=o.getState;return function(o){return function(n){return"function"==typeof n?n(r,e,t):o(n)}}}}var qo=Ho();qo.withExtraArgument=Ho;var Yo,Vo=qo,Xo=(Yo=function(t,o){return Yo=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,o){t.__proto__=o}||function(t,o){for(var r in o)Object.prototype.hasOwnProperty.call(o,r)&&(t[r]=o[r])},Yo(t,o)},function(t,o){if("function"!=typeof o&&null!==o)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");function r(){this.constructor=t}Yo(t,o),t.prototype=null===o?Object.create(o):(r.prototype=o.prototype,new r)}),Jo=function(t,o){var r,e,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,e&&(n=2&i[0]?e.return:i[0]?e.throw||((n=e.return)&&n.call(e),0):e.next)&&!(n=n.call(e,i[1])).done)return n;switch(e=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,e=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=a.trys,(n=n.length>0&&n[n.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=o.call(t,a)}catch(t){i=[6,t],e=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},Qo=function(t,o){for(var r=0,e=o.length,n=t.length;r<e;r++,n++)t[n]=o[r];return t},tr=Object.defineProperty,or=Object.defineProperties,rr=Object.getOwnPropertyDescriptors,er=Object.getOwnPropertySymbols,nr=Object.prototype.hasOwnProperty,ir=Object.prototype.propertyIsEnumerable,ar=function(t,o,r){return o in t?tr(t,o,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[o]=r},sr=function(t,o){for(var r in o||(o={}))nr.call(o,r)&&ar(t,r,o[r]);if(er)for(var e=0,n=er(o);e<n.length;e++){r=n[e];ir.call(o,r)&&ar(t,r,o[r])}return t},cr=function(t,o){return or(t,rr(o))},lr="undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(0!==arguments.length)return"object"==typeof arguments[0]?zo:zo.apply(null,arguments)};var fr=function(t){function o(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var n=t.apply(this,r)||this;return Object.setPrototypeOf(n,o.prototype),n}return Xo(o,t),Object.defineProperty(o,Symbol.species,{get:function(){return o},enumerable:!1,configurable:!0}),o.prototype.concat=function(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];return t.prototype.concat.apply(this,o)},o.prototype.prepend=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return 1===t.length&&Array.isArray(t[0])?new(o.bind.apply(o,Qo([void 0],t[0].concat(this)))):new(o.bind.apply(o,Qo([void 0],t.concat(this))))},o}(Array),ur=function(t){function o(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var n=t.apply(this,r)||this;return Object.setPrototypeOf(n,o.prototype),n}return Xo(o,t),Object.defineProperty(o,Symbol.species,{get:function(){return o},enumerable:!1,configurable:!0}),o.prototype.concat=function(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];return t.prototype.concat.apply(this,o)},o.prototype.prepend=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return 1===t.length&&Array.isArray(t[0])?new(o.bind.apply(o,Qo([void 0],t[0].concat(this)))):new(o.bind.apply(o,Qo([void 0],t.concat(this))))},o}(Array);function hr(t){return Pt(t)?Wo(t,(function(){})):t}function dr(){return function(t){return function(t){void 0===t&&(t={});var o=t.thunk,r=void 0===o||o;t.immutableCheck,t.serializableCheck;var e=new fr;r&&(!function(t){return"boolean"==typeof t}(r)?e.push(Vo.withExtraArgument(r.extraArgument)):e.push(Vo));return e}(t)}}function pr(t){var o,r=dr(),e=t||{},n=e.reducer,i=void 0===n?void 0:n,a=e.middleware,s=void 0===a?r():a,c=e.devTools,l=void 0===c||c,f=e.preloadedState,u=void 0===f?void 0:f,h=e.enhancers,d=void 0===h?void 0:h;if("function"==typeof i)o=i;else{if(!function(t){if("object"!=typeof t||null===t)return!1;var o=Object.getPrototypeOf(t);if(null===o)return!0;for(var r=o;null!==Object.getPrototypeOf(r);)r=Object.getPrototypeOf(r);return o===r}(i))throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');o=$o(i)}var p=s;"function"==typeof p&&(p=p(r));var y=Go.apply(void 0,p),b=zo;l&&(b=lr(sr({trace:!1},"object"==typeof l&&l)));var g=new ur(y),v=g;return Array.isArray(d)?v=Qo([y],d):"function"==typeof d&&(v=d(g)),_o(o,u,b.apply(void 0,v))}function yr(t,o){function r(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];if(o){var n=o.apply(void 0,r);if(!n)throw new Error("prepareAction did not return an object");return sr(sr({type:t,payload:n.payload},"meta"in n&&{meta:n.meta}),"error"in n&&{error:n.error})}return{type:t,payload:r[0]}}return r.toString=function(){return""+t},r.type=t,r.match=function(o){return o.type===t},r}function br(t){var o,r={},e=[],n={addCase:function(t,o){var e="string"==typeof t?t:t.type;if(e in r)throw new Error("addCase cannot be called with two reducers for the same action type");return r[e]=o,n},addMatcher:function(t,o){return e.push({matcher:t,reducer:o}),n},addDefaultCase:function(t){return o=t,n}};return t(n),[r,e,o]}function gr(t){var o=t.name;if(!o)throw new Error("`name` is a required option for createSlice");var r,e="function"==typeof t.initialState?t.initialState:hr(t.initialState),n=t.reducers||{},i=Object.keys(n),a={},s={},c={};function l(){var o="function"==typeof t.extraReducers?br(t.extraReducers):[t.extraReducers],r=o[0],n=void 0===r?{}:r,i=o[1],a=void 0===i?[]:i,c=o[2],l=void 0===c?void 0:c,f=sr(sr({},n),s);return function(t,o,r,e){void 0===r&&(r=[]);var n,i="function"==typeof o?br(o):[o,r,e],a=i[0],s=i[1],c=i[2];if(function(t){return"function"==typeof t}(t))n=function(){return hr(t())};else{var l=hr(t);n=function(){return l}}function f(t,o){void 0===t&&(t=n());var r=Qo([a[o.type]],s.filter((function(t){return(0,t.matcher)(o)})).map((function(t){return t.reducer})));return 0===r.filter((function(t){return!!t})).length&&(r=[c]),r.reduce((function(t,r){if(r){var e;if(Mt(t))return void 0===(e=r(t,o))?t:e;if(Pt(t))return Wo(t,(function(t){return r(t,o)}));if(void 0===(e=r(t,o))){if(null===t)return t;throw Error("A case reducer on a non-draftable value must not return undefined")}return e}return t}),t)}return f.getInitialState=n,f}(e,(function(t){for(var o in f)t.addCase(o,f[o]);for(var r=0,e=a;r<e.length;r++){var n=e[r];t.addMatcher(n.matcher,n.reducer)}l&&t.addDefaultCase(l)}))}return i.forEach((function(t){var r,e,i=n[t],l=o+"/"+t;"reducer"in i?(r=i.reducer,e=i.prepare):r=i,a[t]=r,s[l]=r,c[t]=e?yr(l,e):yr(l)})),{name:o,reducer:function(t,o){return r||(r=l()),r(t,o)},actions:c,caseReducers:a,getInitialState:function(){return r||(r=l()),r.getInitialState()}}}var vr=["name","message","stack","code"],mr=function(t,o){this.payload=t,this.meta=o},Or=function(t,o){this.payload=t,this.meta=o},Nr=function(t){if("object"==typeof t&&null!==t){for(var o={},r=0,e=vr;r<e.length;r++){var n=e[r];"string"==typeof t[n]&&(o[n]=t[n])}return o}return{message:String(t)}};function wr(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}!function(){function t(t,o,r){var e=yr(t+"/fulfilled",(function(t,o,r,e){return{payload:t,meta:cr(sr({},e||{}),{arg:r,requestId:o,requestStatus:"fulfilled"})}})),n=yr(t+"/pending",(function(t,o,r){return{payload:void 0,meta:cr(sr({},r||{}),{arg:o,requestId:t,requestStatus:"pending"})}})),i=yr(t+"/rejected",(function(t,o,e,n,i){return{payload:n,error:(r&&r.serializeError||Nr)(t||"Rejected"),meta:cr(sr({},i||{}),{arg:e,requestId:o,rejectedWithValue:!!n,requestStatus:"rejected",aborted:"AbortError"===(null==t?void 0:t.name),condition:"ConditionError"===(null==t?void 0:t.name)})}})),a="undefined"!=typeof AbortController?AbortController:function(){function t(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return t.prototype.abort=function(){},t}();return Object.assign((function(t){return function(s,c,l){var f,u=(null==r?void 0:r.idGenerator)?r.idGenerator(t):function(t){void 0===t&&(t=21);for(var o="",r=t;r--;)o+="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW"[64*Math.random()|0];return o}(),h=new a;function d(t){f=t,h.abort()}var p=function(){return a=this,p=null,y=function(){var a,p,y,b,g,v;return Jo(this,(function(m){switch(m.label){case 0:return m.trys.push([0,4,,5]),b=null==(a=null==r?void 0:r.condition)?void 0:a.call(r,t,{getState:c,extra:l}),null===(O=b)||"object"!=typeof O||"function"!=typeof O.then?[3,2]:[4,b];case 1:b=m.sent(),m.label=2;case 2:if(!1===b||h.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return g=new Promise((function(t,o){return h.signal.addEventListener("abort",(function(){return o({name:"AbortError",message:f||"Aborted"})}))})),s(n(u,t,null==(p=null==r?void 0:r.getPendingMeta)?void 0:p.call(r,{requestId:u,arg:t},{getState:c,extra:l}))),[4,Promise.race([g,Promise.resolve(o(t,{dispatch:s,getState:c,extra:l,requestId:u,signal:h.signal,abort:d,rejectWithValue:function(t,o){return new mr(t,o)},fulfillWithValue:function(t,o){return new Or(t,o)}})).then((function(o){if(o instanceof mr)throw o;return o instanceof Or?e(o.payload,u,t,o.meta):e(o,u,t)}))])];case 3:return y=m.sent(),[3,5];case 4:return v=m.sent(),y=v instanceof mr?i(null,u,t,v.payload,v.meta):i(v,u,t),[3,5];case 5:return r&&!r.dispatchConditionRejection&&i.match(y)&&y.meta.condition||s(y),[2,y]}var O}))},new Promise((function(t,o){var r=function(t){try{n(y.next(t))}catch(t){o(t)}},e=function(t){try{n(y.throw(t))}catch(t){o(t)}},n=function(o){return o.done?t(o.value):Promise.resolve(o.value).then(r,e)};n((y=y.apply(a,p)).next())}));var a,p,y}();return Object.assign(p,{abort:d,requestId:u,arg:t,unwrap:function(){return p.then(wr)}})}}),{pending:n,rejected:i,fulfilled:e,typePrefix:t})}t.withTypes=function(){return t}}();var Sr="listenerMiddleware";yr(Sr+"/add"),yr(Sr+"/removeAll"),yr(Sr+"/remove"),"function"==typeof queueMicrotask&&queueMicrotask.bind("undefined"!=typeof window?window:"undefined"!=typeof global?global:globalThis),function(){function t(t,o){var r=n[t];return r?r.enumerable=o:n[t]=r={configurable:!0,enumerable:o,get:function(){var o=this[Eo];return Io.get(o,t)},set:function(o){var r=this[Eo];Io.set(r,t,o)}},r}function o(t){for(var o=t.length-1;o>=0;o--){var n=t[o][Eo];if(!n.P)switch(n.i){case 5:e(n)&&fo(n);break;case 4:r(n)&&fo(n)}}}function r(t){for(var o=t.t,r=t.k,e=Ro(r),n=e.length-1;n>=0;n--){var i=e[n];if(i!==Eo){var a=o[i];if(void 0===a&&!Bt(o,i))return!0;var s=r[i],c=s&&s[Eo];if(c?c.t!==a:!_t(s,a))return!0}}var l=!!o[Eo];return e.length!==Ro(o).length+(l?0:1)}function e(t){var o=t.k;if(o.length!==t.t.length)return!0;var r=Object.getOwnPropertyDescriptor(o,o.length-1);if(r&&!r.get)return!0;for(var e=0;e<o.length;e++)if(!o.hasOwnProperty(e))return!0;return!1}var n={};!function(t,o){xo[t]||(xo[t]=o)}("ES5",{J:function(o,r){var e=Array.isArray(o),n=function(o,r){if(o){for(var e=Array(r.length),n=0;n<r.length;n++)Object.defineProperty(e,""+n,t(n,!0));return e}var i=Uo(r);delete i[Eo];for(var a=Ro(i),s=0;s<a.length;s++){var c=a[s];i[c]=t(c,o||!!i[c].enumerable)}return Object.create(Object.getPrototypeOf(r),i)}(e,o),i={i:e?5:4,A:r?r.A:Jt(),P:!1,I:!1,R:{},l:r,t:o,k:n,o:null,g:!1,C:!1};return Object.defineProperty(n,Eo,{value:i,writable:!0}),n},S:function(t,r,n){n?Mt(r)&&r[Eo].A===t&&o(t.p):(t.u&&function t(o){if(o&&"object"==typeof o){var r=o[Eo];if(r){var n=r.t,i=r.k,a=r.R,s=r.i;if(4===s)Ft(i,(function(o){o!==Eo&&(void 0!==n[o]||Bt(n,o)?a[o]||t(i[o]):(a[o]=!0,fo(r)))})),Ft(n,(function(t){void 0!==i[t]||Bt(i,t)||(a[t]=!1,fo(r))}));else if(5===s){if(e(r)&&(fo(r),a.length=!0),i.length<n.length)for(var c=i.length;c<n.length;c++)a[c]=!1;else for(var l=n.length;l<i.length;l++)a[l]=!0;for(var f=Math.min(i.length,n.length),u=0;u<f;u++)i.hasOwnProperty(u)||(a[u]=!0),void 0===a[u]&&t(i[u])}}}}(t.p[0]),o(t.p))},K:function(t){return 4===t.i?r(t):e(t)}})}(),window.ftReduxStores||(window.ftReduxStores={});class Er{static get(t){var o;const r="string"==typeof t?t:t.name,e="string"==typeof t?void 0:t,n=window.ftReduxStores[r];if(xt(n))return n;if(null==e)return;const i=gr({...e,reducers:null!==(o=e.reducers)&&void 0!==o?o:{}}),a=pr({reducer:(t,o)=>{var r;switch(o.type){case"CLEAR_FT_REDUX_STORE":return i.getInitialState();case"DEFAULT_STATE_FIELDS_VALUES_SETTER":return{...t,...null!==(r=o.overwrites)&&void 0!==r?r:{}};default:return i.reducer(t,o)}}});return window.ftReduxStores[e.name]=new Er(i,a)}constructor(t,o){this.reduxSlice=t,this.reduxStore=o,this.isFtReduxStore=!0,this.eventBus=document.createElement("event-bus"),this.actions=new Proxy(this.reduxSlice.actions,{get:(t,o,r)=>{const e=o,n=t[e];return n?(...t)=>{const o=n(...t);return this.reduxStore.dispatch(o),o}:t=>{this.setState({[e]:t})}}})}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE"})}setState(t){this.reduxStore.dispatch({type:"DEFAULT_STATE_FIELDS_VALUES_SETTER",overwrites:t})}get dispatch(){throw new Error("Don't use this method, actions are automatically dispatched when called.")}[Symbol.observable](){return this.reduxStore[Symbol.observable]()}getState(){return this.reduxStore.getState()}replaceReducer(t){throw new Error("Not implemented yet.")}subscribe(t){return this.reduxStore.subscribe(t)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}}const Cr=t=>{const o=null!=t?t:{};return(t,r)=>{var e;const n={hasChanged:(t,o)=>!l(t,o),attribute:!1,...o};a(n)(t,r);const i=t;i.reduxProperties=i.reduxProperties||new Map,i.reduxProperties.set(r,{selector:null!==(e=o.selector)&&void 0!==e?e:t=>t[r],store:o.store})}};var Rr,Ur;navigator.vendor&&navigator.vendor.match(/apple/i)||(null===(Ur=null===(Rr=window.safari)||void 0===Rr?void 0:Rr.pushNotification)||void 0===Ur||Ur.toString());class xr{constructor(t){this.paginatedToc=t,this.nodeByTocId={},this.knownPrettyUrls=new Set,this.duplicatedPrettyUrls=new Set,this.pages=[],this.pageByTocId={}}build(){return{paginationConfiguration:this.paginatedToc.configuration,toc:this.convertNodes(this.paginatedToc.paginatedToc,1),pagesToc:this.extractPagesToc(this.paginatedToc.paginatedToc,1),nodeByTocId:this.nodeByTocId,duplicatedPrettyUrls:this.duplicatedPrettyUrls,pages:this.pages,pageByTocId:this.pageByTocId}}extractPagesToc(t,o,r){return t.flatMap((t=>(t.pageConfiguration&&this.registerPage(this.buildPage(t,r)),null==t.tocId?this.extractPagesToc(t.children,o,r):[{tocId:t.tocId,title:t.title,depth:o,children:this.extractPagesToc(t.children,o+1,t.tocId)}])))}convertNodes(t,o,r){return t.flatMap((t=>{var e,n,i;if(null==t.tocId)return[...this.convertSectionNodes(null!==(e=t.pageToc)&&void 0!==e?e:[],o,t.tocId),...this.convertNodes(t.children,o,t.tocId)];let a=null===(n=t.prettyUrl)||void 0===n?void 0:n.replace(/^\//,"");const s={tocId:t.tocId,contentId:t.contentId,title:t.title,hasRating:t.hasRating,origin:t.origin,prettyUrl:a,depth:o,parentTocId:r,children:[]};this.register(s);const c=this.convertSectionNodes(null!==(i=t.pageToc)&&void 0!==i?i:[],o+1,t.tocId),l=this.convertNodes(t.children,o+1,s.tocId);return s.children=[...c,...l],[s]}))}convertSectionNodes(t,o,r){return t.flatMap((t=>{var e;let n=null===(e=t.prettyUrl)||void 0===e?void 0:e.replace(/^\//,"");const i={...t,prettyUrl:n,depth:o,parentTocId:r,children:[]};return this.register(i),i.children=this.convertSectionNodes(t.children,o+1,t.tocId),[i]}))}buildPage(t,o){var r,e,n,i,a,s;const c={number:this.pages.length+1,title:null!==(r=t.title)&&void 0!==r?r:"",rootTocId:null!==(e=t.tocId)&&void 0!==e?e:"root",toc:(null!==(n=t.pageToc)&&void 0!==n?n:[]).map((t=>this.nodeByTocId[t.tocId])),topics:[],hiddenTopics:[],breadcrumb:o?this.buildBreadcrumb(this.nodeByTocId[o]):[]},l=(t,o)=>(o?c.topics:c.hiddenTopics).push(t),f=null!==(a=null===(i=t.pageConfiguration)||void 0===i?void 0:i.parentsVisibility)&&void 0!==a?a:[];return c.breadcrumb.forEach(((t,o)=>{l(t,f[o])})),t.tocId&&l(t.tocId,t.pageConfiguration.isVisible),c.topics.push(...this.tocIds(null!==(s=t.pageToc)&&void 0!==s?s:[])),c}registerPage(t){for(let o of[...t.topics,...t.hiddenTopics])this.pageByTocId[o]||(this.pageByTocId[o]=t);this.pages.push(t)}tocIds(t){return t.flatMap((t=>[t.tocId,...this.tocIds(t.children)]))}buildBreadcrumb(t){const o=[t.tocId];for(;null==t?void 0:t.parentTocId;)o.unshift(t.parentTocId),t=this.nodeByTocId[t.parentTocId];return o}register(t){t.prettyUrl&&(this.knownPrettyUrls.has(t.prettyUrl)&&this.duplicatedPrettyUrls.add(t.prettyUrl),this.knownPrettyUrls.add(t.prettyUrl)),this.nodeByTocId[t.tocId]=t}}class Ir{convertPaginatedToc(t){return new xr(t).build()}}var Lr,Ar,kr,Wr,Kr,Tr,jr,Mr,Pr,Fr,Zr,Br,Dr,_r;!function(t){!function(o){var r={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch(t){return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};if(r.arrayBuffer)var e=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],n=ArrayBuffer.isView||function(t){return t&&e.indexOf(Object.prototype.toString.call(t))>-1};function i(t){if("string"!=typeof t&&(t=String(t)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(t))throw new TypeError("Invalid character in header field name");return t.toLowerCase()}function a(t){return"string"!=typeof t&&(t=String(t)),t}function s(t){var o={next:function(){var o=t.shift();return{done:void 0===o,value:o}}};return r.iterable&&(o[Symbol.iterator]=function(){return o}),o}function c(t){this.map={},t instanceof c?t.forEach((function(t,o){this.append(o,t)}),this):Array.isArray(t)?t.forEach((function(t){this.append(t[0],t[1])}),this):t&&Object.getOwnPropertyNames(t).forEach((function(o){this.append(o,t[o])}),this)}function l(t){if(t.bodyUsed)return Promise.reject(new TypeError("Already read"));t.bodyUsed=!0}function f(t){return new Promise((function(o,r){t.onload=function(){o(t.result)},t.onerror=function(){r(t.error)}}))}function u(t){var o=new FileReader,r=f(o);return o.readAsArrayBuffer(t),r}function h(t){if(t.slice)return t.slice(0);var o=new Uint8Array(t.byteLength);return o.set(new Uint8Array(t)),o.buffer}function d(){return this.bodyUsed=!1,this._initBody=function(t){var o;this._bodyInit=t,t?"string"==typeof t?this._bodyText=t:r.blob&&Blob.prototype.isPrototypeOf(t)?this._bodyBlob=t:r.formData&&FormData.prototype.isPrototypeOf(t)?this._bodyFormData=t:r.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)?this._bodyText=t.toString():r.arrayBuffer&&r.blob&&((o=t)&&DataView.prototype.isPrototypeOf(o))?(this._bodyArrayBuffer=h(t.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):r.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(t)||n(t))?this._bodyArrayBuffer=h(t):this._bodyText=t=Object.prototype.toString.call(t):this._bodyText="",this.headers.get("content-type")||("string"==typeof t?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):r.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},r.blob&&(this.blob=function(){var t=l(this);if(t)return t;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?l(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(u)}),this.text=function(){var t=l(this);if(t)return t;if(this._bodyBlob)return function(t){var o=new FileReader,r=f(o);return o.readAsText(t),r}(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(function(t){for(var o=new Uint8Array(t),r=new Array(o.length),e=0;e<o.length;e++)r[e]=String.fromCharCode(o[e]);return r.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},r.formData&&(this.formData=function(){return this.text().then(b)}),this.json=function(){return this.text().then(JSON.parse)},this}c.prototype.append=function(t,o){t=i(t),o=a(o);var r=this.map[t];this.map[t]=r?r+", "+o:o},c.prototype.delete=function(t){delete this.map[i(t)]},c.prototype.get=function(t){return t=i(t),this.has(t)?this.map[t]:null},c.prototype.has=function(t){return this.map.hasOwnProperty(i(t))},c.prototype.set=function(t,o){this.map[i(t)]=a(o)},c.prototype.forEach=function(t,o){for(var r in this.map)this.map.hasOwnProperty(r)&&t.call(o,this.map[r],r,this)},c.prototype.keys=function(){var t=[];return this.forEach((function(o,r){t.push(r)})),s(t)},c.prototype.values=function(){var t=[];return this.forEach((function(o){t.push(o)})),s(t)},c.prototype.entries=function(){var t=[];return this.forEach((function(o,r){t.push([r,o])})),s(t)},r.iterable&&(c.prototype[Symbol.iterator]=c.prototype.entries);var p=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function y(t,o){var r,e,n=(o=o||{}).body;if(t instanceof y){if(t.bodyUsed)throw new TypeError("Already read");this.url=t.url,this.credentials=t.credentials,o.headers||(this.headers=new c(t.headers)),this.method=t.method,this.mode=t.mode,this.signal=t.signal,n||null==t._bodyInit||(n=t._bodyInit,t.bodyUsed=!0)}else this.url=String(t);if(this.credentials=o.credentials||this.credentials||"same-origin",!o.headers&&this.headers||(this.headers=new c(o.headers)),this.method=(r=o.method||this.method||"GET",e=r.toUpperCase(),p.indexOf(e)>-1?e:r),this.mode=o.mode||this.mode||null,this.signal=o.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&n)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(n)}function b(t){var o=new FormData;return t.trim().split("&").forEach((function(t){if(t){var r=t.split("="),e=r.shift().replace(/\+/g," "),n=r.join("=").replace(/\+/g," ");o.append(decodeURIComponent(e),decodeURIComponent(n))}})),o}function g(t,o){o||(o={}),this.type="default",this.status=void 0===o.status?200:o.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in o?o.statusText:"OK",this.headers=new c(o.headers),this.url=o.url||"",this._initBody(t)}y.prototype.clone=function(){return new y(this,{body:this._bodyInit})},d.call(y.prototype),d.call(g.prototype),g.prototype.clone=function(){return new g(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new c(this.headers),url:this.url})},g.error=function(){var t=new g(null,{status:0,statusText:""});return t.type="error",t};var v=[301,302,303,307,308];g.redirect=function(t,o){if(-1===v.indexOf(o))throw new RangeError("Invalid status code");return new g(null,{status:o,headers:{location:t}})},o.DOMException=t.DOMException;try{new o.DOMException}catch(t){o.DOMException=function(t,o){this.message=t,this.name=o;var r=Error(t);this.stack=r.stack},o.DOMException.prototype=Object.create(Error.prototype),o.DOMException.prototype.constructor=o.DOMException}function m(t,e){return new Promise((function(n,i){var a=new y(t,e);if(a.signal&&a.signal.aborted)return i(new o.DOMException("Aborted","AbortError"));var s=new XMLHttpRequest;function l(){s.abort()}s.onload=function(){var t,o,r={status:s.status,statusText:s.statusText,headers:(t=s.getAllResponseHeaders()||"",o=new c,t.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(t){var r=t.split(":"),e=r.shift().trim();if(e){var n=r.join(":").trim();o.append(e,n)}})),o)};r.url="responseURL"in s?s.responseURL:r.headers.get("X-Request-URL");var e="response"in s?s.response:s.responseText;n(new g(e,r))},s.onerror=function(){i(new TypeError("Network request failed"))},s.ontimeout=function(){i(new TypeError("Network request failed"))},s.onabort=function(){i(new o.DOMException("Aborted","AbortError"))},s.open(a.method,a.url,!0),"include"===a.credentials?s.withCredentials=!0:"omit"===a.credentials&&(s.withCredentials=!1),"responseType"in s&&r.blob&&(s.responseType="blob"),a.headers.forEach((function(t,o){s.setRequestHeader(o,t)})),a.signal&&(a.signal.addEventListener("abort",l),s.onreadystatechange=function(){4===s.readyState&&a.signal.removeEventListener("abort",l)}),s.send(void 0===a._bodyInit?null:a._bodyInit)}))}m.polyfill=!0,t.fetch||(t.fetch=m,t.Headers=c,t.Request=y,t.Response=g),o.Headers=c,o.Request=y,o.Response=g,o.fetch=m,Object.defineProperty(o,"U",{value:!0})}({})}("undefined"!=typeof self?self:void 0),function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"}(Lr||(Lr={})),function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"}(Ar||(Ar={})),function(t){t.THIRD_PARTY="THIRD_PARTY",t.OFF_THE_GRID="OFF_THE_GRID",t.CONTENT_PACKAGER="CONTENT_PACKAGER",t.PAGES="PAGES",t.DESIGNED_READER="DESIGNED_READER"}(kr||(kr={})),function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"}(Wr||(Wr={})),function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"}(Kr||(Kr={})),function(t){t.ASC="ASC",t.DESC="DESC"}(Tr||(Tr={})),function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"}(jr||(jr={})),function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"}(Mr||(Mr={})),function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK"}(Pr||(Pr={})),function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"}(Fr||(Fr={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK"}(Zr||(Zr={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC"}(Br||(Br={})),function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS"}(Dr||(Dr={})),function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN",t.DEVELOPER="DEVELOPER"}(_r||(_r={}));const $r={[_r.PERSONAL_BOOK_SHARE_USER]:[_r.PERSONAL_BOOK_USER],[_r.HTML_EXPORT_USER]:[_r.PERSONAL_BOOK_USER],[_r.PDF_EXPORT_USER]:[_r.PERSONAL_BOOK_USER],[_r.KHUB_ADMIN]:[_r.CONTENT_PUBLISHER],[_r.ADMIN]:[_r.KHUB_ADMIN,_r.USERS_ADMIN,_r.PORTAL_ADMIN],[_r.DEVELOPER]:[_r.BETA_USER,_r.DEBUG_USER]};function zr(t,o){return t===o||($r[t]??[]).some((t=>zr(t,o)))}function Gr(t,o){if(null==t)return!1;return(Array.isArray(t)?t:Array.isArray(t.roles)?t.roles:Array.isArray(t.profile?.roles)?t.profile.roles:[]).some((t=>zr(t,o)))}var Hr;t.FtReaderFeatures=void 0,(Hr=t.FtReaderFeatures||(t.FtReaderFeatures={})).FEEDBACK="FEEDBACK",Hr.RATING="RATING",Hr.PRINT="PRINT",Hr.BOOKMARK="BOOKMARK",Hr.COLLECTIONS="COLLECTIONS";const qr=v`
82
+ `,Yr=Er.get({name:"ft-app-info",reducers:{setBaseUrl:(t,o)=>{t.baseUrl=o.payload},setApiIntegrationIdentifier:(t,o)=>{t.apiIntegrationIdentifier=o.payload},setUiLocale:(t,o)=>{t.uiLocale=o.payload},setAvailableUiLocales:(t,o)=>{t.availableUiLocales=o.payload},setEditorMode:(t,o)=>{t.editorMode=o.payload},setNoCustom:(t,o)=>{t.noCustom=o.payload},setNoCustomComponent:(t,o)=>{t.noCustomComponent=o.payload},setSession:(t,o)=>{t.session=o.payload}},initialState:{uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],editorMode:!1,noCustom:!1,noCustomComponent:!1}});class Vr{static build(t){const{baseUrl:o,apiIntegrationIdentifier:r}=Yr.getState(),e=null!=t?t:r;if(o&&e&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,e,!0)}static get(t){var o;return null!=t?Vr.build(t):null!==(o=Vr.API)&&void 0!==o?o:Vr.API=Vr.build()}static await(t){return new Promise((o=>{let r=Vr.get(t);if(r)o(r);else{const e=Yr.subscribe((()=>{r=Vr.get(t),r&&(e(),o(r))}))}}))}}var Xr;const Jr=Symbol("clearAfterUnitTest");class Qr{constructor(t){this.messageContextProvider=t,this.defaultMessages={},this.cache=new e,this.listeners={},this.currentUiLocale="",this[Xr]=()=>{this.defaultMessages={},this.cache=new e,this.listeners={}},this.currentUiLocale=Yr.getState().uiLocale,Yr.subscribe((()=>this.clearWhenUiLocaleChanges()))}clearWhenUiLocaleChanges(){const{uiLocale:t}=Yr.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){const o=t.name.toLowerCase();this.cache.setFinal(o,t),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,o){var r;if(t=t.toLowerCase(),Object.keys(o).length>0){const e={...null!==(r=this.defaultMessages[t])&&void 0!==r?r:{},...o};l(this.defaultMessages[t],e)||(this.defaultMessages[t]=e,await this.notify(t))}await this.fetchContext(t)}resolveMessage(t,o,...r){var e,n,i;t=t.toLowerCase(),this.fetchContext(t);const a=null!==(n=null===(e=this.cache.getNow(t))||void 0===e?void 0:e.messages)&&void 0!==n?n:{};return new Ut(null!==(i=this.defaultMessages[t])&&void 0!==i?i:{},a).resolve(o,...r)}async fetchContext(t){if(!this.cache.has(t))try{await this.cache.get(t,(()=>this.messageContextProvider(this.currentUiLocale,t))),await this.notify(t)}catch(t){console.error(t)}}subscribe(t,o){var r;return t=t.toLowerCase(),this.listeners[t]=null!==(r=this.listeners[t])&&void 0!==r?r:new Set,this.listeners[t].add(o),()=>{var r;return null===(r=this.listeners[t])||void 0===r?void 0:r.delete(o)}}async notifyAll(){await Promise.all(Object.keys(this.listeners).map((t=>this.notify(t))))}async notify(t){null!=this.listeners[t]&&await Promise.all([...this.listeners[t].values()].map((t=>c(0).then((()=>t())).catch((()=>null)))))}}Xr=Jr,null==window.FluidTopicsI18nService&&(window.FluidTopicsI18nService=new Qr((async(t,o)=>(await Vr.await()).getFluidTopicsMessageContext(t,o)))),null==window.FluidTopicsCustomI18nService&&(window.FluidTopicsCustomI18nService=new Qr((async(t,o)=>(await Vr.await()).getCustomMessageContext(t,o))));const te=window.FluidTopicsI18nService;var oe=function(t,o,r,e){for(var n,i=arguments.length,a=i<3?o:null===e?e=Object.getOwnPropertyDescriptor(o,r):e,s=t.length-1;s>=0;s--)(n=t[s])&&(a=(i<3?n(a):i>3?n(o,r,a):n(o,r))||a);return i>3&&a&&Object.defineProperty(o,r,a),a};class re extends Rt{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.availableUiLocales=[],this.editorMode=!1,this.noCustom=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.messageContexts=[],this.apiProvider=()=>Vr.get(),this.cache=new e,this.cleanSessionDebouncer=new n}render(){return V`
83
83
  <slot></slot>
84
- `}update(t){super.update(t),t.has("baseUrl")&&Xr.actions.setBaseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&Xr.actions.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&Xr.actions.setUiLocale(this.uiLocale),t.has("noCustom")&&Xr.actions.setNoCustom(this.noCustom),t.has("editorMode")&&Xr.actions.setEditorMode(this.editorMode),t.has("noCustomComponent")&&Xr.actions.setNoCustomComponent(this.noCustomComponent),t.has("session")&&Xr.actions.setSession(this.session),t.has("availableUiLocales")&&Xr.actions.setAvailableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>re.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){const t=this.apiProvider();!this.withManualResources&&t&&(null==this.session&&(this.session=await this.cache.get("session",(async()=>{const o=await t.getCurrentSession();return o.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),o.idleTimeoutInMillis),o}))),null==this.availableUiLocales&&(this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>t.getAvailableUiLocales()))))}}ne.elementDefinitions={},ne.styles=Yr,ee([a()],ne.prototype,"baseUrl",void 0),ee([a()],ne.prototype,"apiIntegrationIdentifier",void 0),ee([a()],ne.prototype,"uiLocale",void 0),ee([u([])],ne.prototype,"availableUiLocales",void 0),ee([a({type:Boolean})],ne.prototype,"editorMode",void 0),ee([a({type:Boolean})],ne.prototype,"noCustom",void 0),ee([a({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],ne.prototype,"noCustomComponent",void 0),ee([a({type:Boolean})],ne.prototype,"withManualResources",void 0),ee([u([])],ne.prototype,"messageContexts",void 0),ee([u(void 0)],ne.prototype,"session",void 0),ee([a({type:Object})],ne.prototype,"apiProvider",void 0);class ie{async listMySearches(){var t;return(null===(t=Xr.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await Jr.await()).listMySearches(Xr.getState().session.profile.userId):[]}}const ae=new e;class ce{async listMyBookmarks(){return ae.get("bookmarks",(async()=>(await Jr.await()).listMyBookmarks(Xr.getState().session.profile.userId)))}clearCache(){ae.clear("bookmarks")}}const se=Er.get({name:"ft-user-assets",initialState:{savedSearches:void 0,bookmarks:void 0}});const le=new class{constructor(){this.currentSession=Xr.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new ce,Xr.subscribe((()=>this.reloadWhenUserSessionChanges()))}reloadWhenUserSessionChanges(){var t;const{session:o}=Xr.getState();l(null===(t=this.currentSession)||void 0===t?void 0:t.profile,null==o?void 0:o.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){se.actions.savedSearches(void 0)}clearMyBookmarks(){se.actions.bookmarks(void 0)}async reloadMySearches(){const t=new ie,o=await t.listMySearches();se.actions.savedSearches(o)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){const o=(null===(t=this.currentSession)||void 0===t?void 0:t.sessionAuthenticated)?await this.bookmarksService.listMyBookmarks():void 0;se.actions.bookmarks(o)}}};f("ft-app-context")(ne);class fe{get mapId(){return this._mapId}set mapId(t){t!==this._mapId&&this.clear(),this._mapId=t}constructor(t,o,r,e){this.converter=t,this.api=o,this.cache=r,this._mapId=e,this.initCache()}async withMapId(t){return this._mapId?t(this._mapId):void 0}initCache(){this.cache.registerFinal("configuration",(()=>this.api.getReaderConfiguration())),this.cache.register("map",(()=>this.withMapId((t=>this.fetchMap(t))))),this.cache.register("enrichedToc",(()=>this.withMapId((t=>this.fetchPages(t).then((t=>this.converter.convertPaginatedToc(t))))))),this.cache.register("ratingSummary",(()=>{var t,o;return qr(null!==(o=null===(t=Xr.getState().session)||void 0===t?void 0:t.profile.roles)&&void 0!==o?o:[],"RATING_USER")?this.withMapId((t=>this.fetchMapRating(t))):Promise.resolve()}))}clear(){this.cache.clearAll()}getMap(){return this.cache.get("map")}getConfiguration(){return this.cache.get("configuration")}getEnrichedToc(){return this.cache.get("enrichedToc")}get enrichedToc(){return this.cache.getNow("enrichedToc")}async getPaginationConfiguration(){return(await this.getEnrichedToc()).paginationConfiguration}async getToc(){return(await this.getEnrichedToc()).toc}async getPagesToc(){return(await this.getEnrichedToc()).pagesToc}async getTocNode(t){return(await this.getEnrichedToc()).nodeByTocId[t]}getTocNodeNow(t){var o;return null===(o=this.enrichedToc)||void 0===o?void 0:o.nodeByTocId[t]}async getPage(t){const o=await this.getEnrichedToc();return o.pages[t-1]||o.pages[0]}async getPageByTocId(t){const o=await this.getEnrichedToc();return o.pageByTocId[t]||o.pages[0]}getTopicInfo(t){return this.cache.get("topic-"+t.tocId,(()=>this.fetchTopicMetadata(t)))}getTopicContent(t){return this.cache.get("topic-content-"+t.tocId,(()=>this.fetchTopicHTMLContent(t)))}getLink(t,o,r){const e=this.getNavigationData(t,o,r),n=this.getReaderLinkPrefix()+(e.prettyUrl?e.prettyUrl:`${e.mapId}/${e.tocId}`),i=new URL(n,this.api.tenantBaseUrl);return null!=e.page&&i.searchParams.set("page",`${e.page}`),e.prettyUrlDuplicated&&i.searchParams.set("tocId",e.tocId),null!=e.section&&i.searchParams.set("section",e.section),i.href}getNavigationData(t,o,r){var e,n;t=t||"root";const i=this.enrichedToc,a=null==i?void 0:i.pageByTocId[t],c=null==i?void 0:i.nodeByTocId[t],s=null==c?void 0:c.prettyUrl;return{mapId:this.mapId,tocId:t,topicTitle:null!==(e=null==c?void 0:c.title)&&void 0!==e?e:"",page:o&&a&&a.number!==o?o:void 0,prettyUrl:null!=s?s.replace(/^r\//,""):void 0,prettyUrlDuplicated:null!==(n=null==i?void 0:i.duplicatedPrettyUrls.has(null!=s?s:""))&&void 0!==n&&n,section:r}}async getAccurateNavigationData(t,o,r){return await this.getEnrichedToc(),this.getNavigationData(t,o,r)}getRatingSummary(){return this.cache.get("ratingSummary")}getMapRating(){return this.getRatingSummary().then((t=>null==t?void 0:t.publication))}getTopicRating(t){return this.getRatingSummary().then((o=>{var r;return o?{type:o.topics.type,rating:null===(r=o.topics)||void 0===r?void 0:r.ratings.find((o=>o.tocId===t))}:void 0}))}rateMap(t,o){return this.makeRateMapRequest(t,o).then((()=>this.clearRatingIfNecessary()))}unrateMap(){return this.makeUnrateMapRequest().then((()=>this.clearRatingIfNecessary()))}sendMapFeedback(t,o){return this.makeMapFeedbackRequest(t,o)}rateTopic(t,o,r){return this.makeRateTopicRequest(t,o,r).then((()=>this.clearRatingIfNecessary()))}unrateTopic(t){return this.makeUnrateTopicRequest(t).then((()=>this.clearRatingIfNecessary()))}async clearRatingIfNecessary(){const t=Xr.getState().session;(null==t?void 0:t.sessionAuthenticated)&&this.cache.clear("ratingSummary")}sendTopicFeedback(t,o,r){return this.makeTopicFeedbackRequest(t,o,r)}fontsStylesheet(){return this.api.makeAbsolute(this.api.endpoints.stylesheets.fonts)}themeStylesheet(){return this.api.makeAbsolute(this.api.endpoints.stylesheets.theme)}buildBreadcrumb(t){let o=this.getTocNodeNow(t),r=[{tocId:o.tocId,title:o.title}],e=this.getTocNodeNow(o.parentTocId);for(;e;)r.unshift({tocId:e.tocId,title:e.title}),e=this.getTocNodeNow(e.parentTocId);return r}isFeatureAccessible(o,{session:r,ratingType:e}){if(!this.isFeatureAvailable(o))return!1;switch(o){case t.FtReaderFeatures.FEEDBACK:return qr(null!=r?r:[],_r.FEEDBACK_USER);case t.FtReaderFeatures.RATING:return qr(null!=r?r:[],_r.RATING_USER)&&null!=e&&e!==Tr.NO_RATING;case t.FtReaderFeatures.PRINT:return qr(null!=r?r:[],_r.PRINT_USER);case t.FtReaderFeatures.BOOKMARK:return!!(null==r?void 0:r.sessionAuthenticated);case t.FtReaderFeatures.COLLECTIONS:return qr(null!=r?r:[],_r.COLLECTION_USER);default:return!1}}}class ue extends fe{static async build(t){return new ue(new Ir,await Jr.await(),new e,t)}fetchMap(t){return this.api.getMap(t)}fetchMapRating(t){return this.api.getMapRating(t)}fetchPages(t){return this.api.getPages(t)}fetchTopicHTMLContent(t){return this.api.getTopicHTMLContent(this.mapId,t.contentId,"DESIGNED_READER")}fetchTopicMetadata(t){return this.api.getTopic(this.mapId,t.contentId)}makeMapFeedbackRequest(t,o){return this.api.sendMapFeedback(this.mapId,t,o)}makeRateMapRequest(t,o){return this.api.rateMap(this.mapId,t,o)}makeRateTopicRequest(t,o,r){return this.api.rateTopic(this.mapId,t,o,r)}makeTopicFeedbackRequest(t,o,r){return this.api.sendTopicFeedback(this.mapId,t,o,r)}makeUnrateMapRequest(){return this.api.unrateMap(this.mapId)}makeUnrateTopicRequest(t){return this.api.unrateTopic(this.mapId,t)}getReaderLinkPrefix(){return"r/"}isFeatureAvailable(t){return!0}}class he{static build(t,o){return new he((t=>Er.get({name:"ft-reader-"+t,initialState:{mapId:void 0,visibleTopics:[],map:void 0,toc:void 0,pagesToc:void 0,paginationConfiguration:void 0,currentPage:void 0,scrollTarget:void 0,configuration:void 0}}))(t.trim()||"context"),null!=o?o:ue.build)}constructor(t,o){this.store=t,this.reloadDebouncer=new n(10),this.initService(o)}async initService(t){return this.service=await t(),this.service.mapId=this.store.getState().mapId,this.reload()}async setMapId(t){t!==this.store.getState().mapId&&(this.store.actions.mapId(t),this.service&&(this.service.mapId=t),await this.reload())}setVisibleTopics(t){this.store.actions.visibleTopics(t)}async awaitService(){for(;null==this.service;)await s(5);return this.service}async navigateToTopic(t,o,r){const e=await this.awaitService(),n=await(null!=r?e.getPage(r):e.getPageByTocId(null!=t?t:"root"));this.store.actions.currentPage(n),this.store.actions.scrollTarget({tocId:this.resolveValidNonRootTocId(t,n),section:o})}resolveValidNonRootTocId(t,o){var r,e,n;let i=null!==(r="root"===t?void 0:t)&&void 0!==r?r:o.rootTocId;return o.topics.includes(i)?i:null!==(n=null!==(e=o.topics[0])&&void 0!==e?e:o.hiddenTopics[0])&&void 0!==n?n:"root"}async navigateToPage(t){const o=await this.awaitService();let r=await o.getPage(t);this.store.actions.currentPage(r)}scrollDone(){this.store.actions.scrollTarget({})}async reload(){var t,o;this.store.actions.configuration(void 0),this.store.actions.map(void 0),this.store.actions.toc(void 0),this.store.actions.pagesToc(void 0),this.store.actions.currentPage(void 0),null===(t=this.service)||void 0===t||t.clear(),(null===(o=this.service)||void 0===o?void 0:o.mapId)&&await this.reloadDebouncer.run((()=>this.fetchData()))}async fetchData(){var t,r,e,n,i;try{await Promise.all([null===(t=this.service)||void 0===t?void 0:t.getConfiguration().then((t=>this.store.actions.configuration(t))),null===(r=this.service)||void 0===r?void 0:r.getMap().then((t=>this.store.actions.map(t))),null===(e=this.service)||void 0===e?void 0:e.getToc().then((t=>this.store.actions.toc(t))),null===(n=this.service)||void 0===n?void 0:n.getPagesToc().then((t=>this.store.actions.pagesToc(t))),null===(i=this.service)||void 0===i?void 0:i.getPaginationConfiguration().then((t=>this.store.actions.paginationConfiguration(t)))])}catch(t){!this.errorHandler||t instanceof o||this.errorHandler(t)}}}const de=v`
85
- `;class pe extends CustomEvent{constructor(t,o){super("ft-reader-map-loaded",{detail:{map:t,toc:o}})}}class ye extends CustomEvent{constructor(t,o){super("ft-reader-visible-topics-change",{detail:{visibleTopics:o}})}}class be extends CustomEvent{constructor(t){super("ft-reader-navigation-done",{detail:t})}}class ge extends CustomEvent{constructor(t){super("ft-reader-load-error",{detail:t})}}class ve extends Event{constructor(){super("ft-reader-map-not-found")}}class me extends Event{constructor(){super("ft-reader-map-unauthorized")}}var Oe=function(t,o,r,e){for(var n,i=arguments.length,a=i<3?o:null===e?e=Object.getOwnPropertyDescriptor(o,r):e,c=t.length-1;c>=0;c--)(n=t[c])&&(a=(i<3?n(a):i>3?n(o,r,a):n(o,r))||a);return i>3&&a&&Object.defineProperty(o,r,a),a};class Ne extends Tt{constructor(){super(),this.visibleTopics=[],this.scrollToTargetDebouncer=new n(5),this.navigationDebouncer=new n(10),this.addStore(Xr)}render(){return Y`
84
+ `}update(t){super.update(t),t.has("baseUrl")&&Yr.actions.setBaseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&Yr.actions.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&Yr.actions.setUiLocale(this.uiLocale),t.has("noCustom")&&Yr.actions.setNoCustom(this.noCustom),t.has("editorMode")&&Yr.actions.setEditorMode(this.editorMode),t.has("noCustomComponent")&&Yr.actions.setNoCustomComponent(this.noCustomComponent),t.has("session")&&Yr.actions.setSession(this.session),t.has("availableUiLocales")&&Yr.actions.setAvailableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>te.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){const t=this.apiProvider();!this.withManualResources&&t&&(null==this.session&&(this.session=await this.cache.get("session",(async()=>{const o=await t.getCurrentSession();return o.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),o.idleTimeoutInMillis),o}))),null==this.availableUiLocales&&(this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>t.getAvailableUiLocales()))))}}re.elementDefinitions={},re.styles=qr,oe([a()],re.prototype,"baseUrl",void 0),oe([a()],re.prototype,"apiIntegrationIdentifier",void 0),oe([a()],re.prototype,"uiLocale",void 0),oe([u([])],re.prototype,"availableUiLocales",void 0),oe([a({type:Boolean})],re.prototype,"editorMode",void 0),oe([a({type:Boolean})],re.prototype,"noCustom",void 0),oe([a({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],re.prototype,"noCustomComponent",void 0),oe([a({type:Boolean})],re.prototype,"withManualResources",void 0),oe([u([])],re.prototype,"messageContexts",void 0),oe([u(void 0)],re.prototype,"session",void 0),oe([a({type:Object})],re.prototype,"apiProvider",void 0);class ee{async listMySearches(){var t;return(null===(t=Yr.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await Vr.await()).listMySearches(Yr.getState().session.profile.userId):[]}}const ne=new e;class ie{async listMyBookmarks(){return ne.get("bookmarks",(async()=>(await Vr.await()).listMyBookmarks(Yr.getState().session.profile.userId)))}clearCache(){ne.clear("bookmarks")}}const ae=Er.get({name:"ft-user-assets",initialState:{savedSearches:void 0,bookmarks:void 0}});const se=new class{constructor(){this.currentSession=Yr.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new ie,Yr.subscribe((()=>this.reloadWhenUserSessionChanges()))}reloadWhenUserSessionChanges(){var t;const{session:o}=Yr.getState();l(null===(t=this.currentSession)||void 0===t?void 0:t.profile,null==o?void 0:o.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){ae.actions.savedSearches(void 0)}clearMyBookmarks(){ae.actions.bookmarks(void 0)}async reloadMySearches(){const t=new ee,o=await t.listMySearches();ae.actions.savedSearches(o)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){const o=(null===(t=this.currentSession)||void 0===t?void 0:t.sessionAuthenticated)?await this.bookmarksService.listMyBookmarks():void 0;ae.actions.bookmarks(o)}}};f("ft-app-context")(re);class ce{get mapId(){return this._mapId}set mapId(t){t!==this._mapId&&this.clear(),this._mapId=t}constructor(t,o,r,e){this.converter=t,this.api=o,this.cache=r,this._mapId=e,this.initCache()}async withMapId(t){return this._mapId?t(this._mapId):void 0}initCache(){this.cache.registerFinal("configuration",(()=>this.api.getReaderConfiguration())),this.cache.register("map",(()=>this.withMapId((t=>this.fetchMap(t))))),this.cache.register("enrichedToc",(()=>this.withMapId((t=>this.fetchPages(t).then((t=>this.converter.convertPaginatedToc(t))))))),this.cache.register("ratingSummary",(()=>{var t,o;return Gr(null!==(o=null===(t=Yr.getState().session)||void 0===t?void 0:t.profile.roles)&&void 0!==o?o:[],"RATING_USER")?this.withMapId((t=>this.fetchMapRating(t))):Promise.resolve()}))}clear(){this.cache.clearAll()}getMap(){return this.cache.get("map")}getConfiguration(){return this.cache.get("configuration")}getEnrichedToc(){return this.cache.get("enrichedToc")}get enrichedToc(){return this.cache.getNow("enrichedToc")}async getPaginationConfiguration(){return(await this.getEnrichedToc()).paginationConfiguration}async getToc(){return(await this.getEnrichedToc()).toc}async getPagesToc(){return(await this.getEnrichedToc()).pagesToc}async getTocNode(t){return(await this.getEnrichedToc()).nodeByTocId[t]}getTocNodeNow(t){var o;return null===(o=this.enrichedToc)||void 0===o?void 0:o.nodeByTocId[t]}async getPage(t){const o=await this.getEnrichedToc();return o.pages[t-1]||o.pages[0]}async getPageByTocId(t){const o=await this.getEnrichedToc();return o.pageByTocId[t]||o.pages[0]}getTopicInfo(t){return this.cache.get("topic-"+t.tocId,(()=>this.fetchTopicMetadata(t)))}getTopicContent(t){return this.cache.get("topic-content-"+t.tocId,(()=>this.fetchTopicHTMLContent(t)))}getLink(t,o,r){const e=this.getNavigationData(t,o,r),n=this.getReaderLinkPrefix()+(e.prettyUrl?e.prettyUrl:`${e.mapId}/${e.tocId}`),i=new URL(n,this.api.tenantBaseUrl);return null!=e.page&&i.searchParams.set("page",`${e.page}`),e.prettyUrlDuplicated&&i.searchParams.set("tocId",e.tocId),null!=e.section&&i.searchParams.set("section",e.section),i.href}getNavigationData(t,o,r){var e,n;t=t||"root";const i=this.enrichedToc,a=null==i?void 0:i.pageByTocId[t],s=null==i?void 0:i.nodeByTocId[t],c=null==s?void 0:s.prettyUrl;return{mapId:this.mapId,tocId:t,topicTitle:null!==(e=null==s?void 0:s.title)&&void 0!==e?e:"",page:o&&a&&a.number!==o?o:void 0,prettyUrl:null!=c?c.replace(/^r\//,""):void 0,prettyUrlDuplicated:null!==(n=null==i?void 0:i.duplicatedPrettyUrls.has(null!=c?c:""))&&void 0!==n&&n,section:r}}async getAccurateNavigationData(t,o,r){return await this.getEnrichedToc(),this.getNavigationData(t,o,r)}getRatingSummary(){return this.cache.get("ratingSummary")}getMapRating(){return this.getRatingSummary().then((t=>null==t?void 0:t.publication))}getTopicRating(t){return this.getRatingSummary().then((o=>{var r;return o?{type:o.topics.type,rating:null===(r=o.topics)||void 0===r?void 0:r.ratings.find((o=>o.tocId===t))}:void 0}))}rateMap(t,o){return this.makeRateMapRequest(t,o).then((()=>this.clearRatingIfNecessary()))}unrateMap(){return this.makeUnrateMapRequest().then((()=>this.clearRatingIfNecessary()))}sendMapFeedback(t,o){return this.makeMapFeedbackRequest(t,o)}rateTopic(t,o,r){return this.makeRateTopicRequest(t,o,r).then((()=>this.clearRatingIfNecessary()))}unrateTopic(t){return this.makeUnrateTopicRequest(t).then((()=>this.clearRatingIfNecessary()))}async clearRatingIfNecessary(){const t=Yr.getState().session;(null==t?void 0:t.sessionAuthenticated)&&this.cache.clear("ratingSummary")}sendTopicFeedback(t,o,r){return this.makeTopicFeedbackRequest(t,o,r)}fontsStylesheet(){return this.api.makeAbsolute(this.api.endpoints.stylesheets.fonts)}themeStylesheet(){return this.api.makeAbsolute(this.api.endpoints.stylesheets.theme)}buildBreadcrumb(t){let o=this.getTocNodeNow(t),r=[{tocId:o.tocId,title:o.title}],e=this.getTocNodeNow(o.parentTocId);for(;e;)r.unshift({tocId:e.tocId,title:e.title}),e=this.getTocNodeNow(e.parentTocId);return r}isFeatureAccessible(o,{session:r,ratingType:e}){if(!this.isFeatureAvailable(o))return!1;switch(o){case t.FtReaderFeatures.FEEDBACK:return Gr(null!=r?r:[],_r.FEEDBACK_USER);case t.FtReaderFeatures.RATING:return Gr(null!=r?r:[],_r.RATING_USER)&&null!=e&&e!==Wr.NO_RATING;case t.FtReaderFeatures.PRINT:return Gr(null!=r?r:[],_r.PRINT_USER);case t.FtReaderFeatures.BOOKMARK:return!!(null==r?void 0:r.sessionAuthenticated);case t.FtReaderFeatures.COLLECTIONS:return Gr(null!=r?r:[],_r.COLLECTION_USER);default:return!1}}}class le extends ce{static async build(t){return new le(new Ir,await Vr.await(),new e,t)}clear(){super.clear(),this.fingerprint=void 0}async fetchMap(t){var o;const r=await this.api.getMap(t);return this.fingerprint=null===(o=r.lastPublication)||void 0===o?void 0:o.replace(/\D/g,""),r}fetchMapRating(t){return this.api.getMapRating(t)}async fetchPages(t){return await this.getMap(),this.api.getPages(t,this.fingerprint)}fetchTopicHTMLContent(t){return this.api.getTopicHTMLContent(this.mapId,t.contentId,"DESIGNED_READER",this.fingerprint)}fetchTopicMetadata(t){return this.api.getTopic(this.mapId,t.contentId,this.fingerprint)}makeMapFeedbackRequest(t,o){return this.api.sendMapFeedback(this.mapId,t,o)}makeRateMapRequest(t,o){return this.api.rateMap(this.mapId,t,o)}makeRateTopicRequest(t,o,r){return this.api.rateTopic(this.mapId,t,o,r)}makeTopicFeedbackRequest(t,o,r){return this.api.sendTopicFeedback(this.mapId,t,o,r)}makeUnrateMapRequest(){return this.api.unrateMap(this.mapId)}makeUnrateTopicRequest(t){return this.api.unrateTopic(this.mapId,t)}getReaderLinkPrefix(){return"r/"}isFeatureAvailable(t){return!0}}class fe{static build(t,o){return new fe((t=>Er.get({name:"ft-reader-"+t,initialState:{mapId:void 0,visibleTopics:[],map:void 0,toc:void 0,pagesToc:void 0,paginationConfiguration:void 0,currentPage:void 0,scrollTarget:void 0,configuration:void 0}}))(t.trim()||"context"),null!=o?o:le.build)}constructor(t,o){this.store=t,this.reloadDebouncer=new n(10),this.initService(o)}async initService(t){return this.service=await t(),this.service.mapId=this.store.getState().mapId,this.reload()}async setMapId(t){t!==this.store.getState().mapId&&(this.store.actions.mapId(t),this.service&&(this.service.mapId=t),await this.reload())}setVisibleTopics(t){this.store.actions.visibleTopics(t)}async awaitService(){for(;null==this.service;)await c(5);return this.service}async navigateToTopic(t,o,r){const e=await this.awaitService(),n=await(null!=r?e.getPage(r):e.getPageByTocId(null!=t?t:"root"));this.store.actions.currentPage(n),this.store.actions.scrollTarget({tocId:this.resolveValidNonRootTocId(t,n),section:o})}resolveValidNonRootTocId(t,o){var r,e,n;let i=null!==(r="root"===t?void 0:t)&&void 0!==r?r:o.rootTocId;return o.topics.includes(i)?i:null!==(n=null!==(e=o.topics[0])&&void 0!==e?e:o.hiddenTopics[0])&&void 0!==n?n:"root"}async navigateToPage(t){const o=await this.awaitService();let r=await o.getPage(t);this.store.actions.currentPage(r)}scrollDone(){this.store.actions.scrollTarget({})}async reload(){var t,o;this.store.actions.configuration(void 0),this.store.actions.map(void 0),this.store.actions.toc(void 0),this.store.actions.pagesToc(void 0),this.store.actions.currentPage(void 0),null===(t=this.service)||void 0===t||t.clear(),(null===(o=this.service)||void 0===o?void 0:o.mapId)&&await this.reloadDebouncer.run((()=>this.fetchData()))}async fetchData(){var t,r,e,n,i;try{await Promise.all([null===(t=this.service)||void 0===t?void 0:t.getConfiguration().then((t=>this.store.actions.configuration(t))),null===(r=this.service)||void 0===r?void 0:r.getMap().then((t=>this.store.actions.map(t))),null===(e=this.service)||void 0===e?void 0:e.getToc().then((t=>this.store.actions.toc(t))),null===(n=this.service)||void 0===n?void 0:n.getPagesToc().then((t=>this.store.actions.pagesToc(t))),null===(i=this.service)||void 0===i?void 0:i.getPaginationConfiguration().then((t=>this.store.actions.paginationConfiguration(t)))])}catch(t){!this.errorHandler||t instanceof o||this.errorHandler(t)}}}const ue=v`
85
+ `;class he extends CustomEvent{constructor(t,o){super("ft-reader-map-loaded",{detail:{map:t,toc:o}})}}class de extends CustomEvent{constructor(t,o){super("ft-reader-visible-topics-change",{detail:{visibleTopics:o}})}}class pe extends CustomEvent{constructor(t){super("ft-reader-navigation-done",{detail:t})}}class ye extends CustomEvent{constructor(t){super("ft-reader-load-error",{detail:t})}}class be extends Event{constructor(){super("ft-reader-map-not-found")}}class ge extends Event{constructor(){super("ft-reader-map-unauthorized")}}var ve=function(t,o,r,e){for(var n,i=arguments.length,a=i<3?o:null===e?e=Object.getOwnPropertyDescriptor(o,r):e,s=t.length-1;s>=0;s--)(n=t[s])&&(a=(i<3?n(a):i>3?n(o,r,a):n(o,r))||a);return i>3&&a&&Object.defineProperty(o,r,a),a};class me extends Tt{constructor(){super(),this.visibleTopics=[],this.scrollToTargetDebouncer=new n(5),this.navigationDebouncer=new n(10),this.addStore(Yr)}render(){return V`
86
86
  ${this.importStyleIfNeeded()}
87
87
  <slot @register-ft-reader-component=${this.registerComponent}></slot>
88
- `}importStyleIfNeeded(){var t,o;const r=null===(t=this.stateManager.service)||void 0===t?void 0:t.themeStylesheet();return!r||window.location.href.startsWith(null!==(o=this.baseUrl)&&void 0!==o?o:"")?J:Y`
88
+ `}importStyleIfNeeded(){var t,o;const r=null===(t=this.stateManager.service)||void 0===t?void 0:t.themeStylesheet();return!r||window.location.href.startsWith(null!==(o=this.baseUrl)&&void 0!==o?o:"")?J:V`
89
89
  <style>
90
90
  @import "${r}"
91
91
  </style>
92
- `}get stateManager(){return null==this._stateManager&&(this._stateManager=he.build(this.id||(""+Math.round(999e3*Math.random())).padStart(6,"0"),this.readerServiceProvider),this._stateManager.errorHandler=t=>this.handleLoadError(t),this.addStore(this.stateManager.store,"reader")),this._stateManager}connectedCallback(){super.connectedCallback(),this.stateManager.setMapId(this.mapId),this.stateManager.awaitService().then((t=>{const o=t.fontsStylesheet();if(o&&!window.location.href.startsWith(this.baseUrl)&&!document.querySelector(`head link[href="${o}"]`)){const t=document.createElement("link");t.setAttribute("rel","stylesheet"),t.setAttribute("href",o),document.head.append(t)}}))}update(t){super.update(t),t.has("readerServiceProvider")&&this.readerServiceProvider&&this.stateManager.initService(this.readerServiceProvider),t.has("mapId")&&this.mapId&&this.stateManager.setMapId(this.mapId),["tocId","section","page","mapId"].some((o=>t.has(o)))&&this.mapId&&this.navigateToTarget()}contentAvailableCallback(t){var o;if(super.contentAvailableCallback(t),(t.has("map")||t.has("toc"))&&this.map&&this.toc&&this.dispatchEvent(new pe(this.map,this.toc)),t.has("scrollTarget")&&null==(null===(o=this.scrollTarget)||void 0===o?void 0:o.tocId)){const o=t.get("scrollTarget");null!=(null==o?void 0:o.tocId)&&this.scrollToTargetDebouncer.run((()=>{var t;return this.stateManager.service.getAccurateNavigationData(o.tocId,null===(t=this.currentPage)||void 0===t?void 0:t.number,o.section).then((t=>this.dispatchEvent(new be(t))))}))}t.has("visibleTopics")&&Promise.all(this.visibleTopics.map((t=>{var o;return this.stateManager.service.getAccurateNavigationData(t,null===(o=this.currentPage)||void 0===o?void 0:o.number)}))).then((t=>{let o=t.filter((t=>null!=t&&""!==t.topicTitle)).map((t=>{var o;return{tocId:t.tocId,title:t.topicTitle,page:t.page,prettyUrl:t.prettyUrl,prettyUrlDuplicated:t.prettyUrlDuplicated,breadcrumb:null===(o=this.stateManager.service)||void 0===o?void 0:o.buildBreadcrumb(t.tocId)}}));this.dispatchEvent(new ye(this.map,o))}))}async reload(){await this.stateManager.reload(),this.navigateToTarget()}navigateToTarget(){this.navigationDebouncer.run((()=>{null!=this.tocId?this.stateManager.navigateToTopic(this.tocId,this.section,this.page):null!=this.page&&this.stateManager.navigateToPage(this.page)}))}registerComponent(t){t.stopPropagation();const o=t.composedPath()[0];this.register(o)}register(t){t.setReaderStateManager(this.stateManager)}handleLoadError(t){const o=t;404===o.status?this.dispatchEvent(new ve):401===o.status?this.dispatchEvent(new me):this.dispatchEvent(new ge(t))}reloadBookmarks(){le.reloadBookmarks()}}var we;Ne.styles=de,Oe([Rr({store:Xr.name})],Ne.prototype,"baseUrl",void 0),Oe([a()],Ne.prototype,"mapId",void 0),Oe([a()],Ne.prototype,"tocId",void 0),Oe([a()],Ne.prototype,"section",void 0),Oe([a({type:Number,converter:{fromAttribute:t=>+(null!=t?t:"NaN")>0?+t:we}})],Ne.prototype,"page",void 0),Oe([Rr({store:"reader"})],Ne.prototype,"map",void 0),Oe([Rr({store:"reader"})],Ne.prototype,"toc",void 0),Oe([Rr({store:"reader"})],Ne.prototype,"visibleTopics",void 0),Oe([Rr({store:"reader"})],Ne.prototype,"currentPage",void 0),Oe([Rr({store:"reader"})],Ne.prototype,"scrollTarget",void 0),Oe([a({attribute:!1})],Ne.prototype,"readerServiceProvider",void 0),f("ft-reader-context")(Ne),t.FtOfficialReaderService=ue,t.FtReaderContext=Ne,t.FtReaderContextCssVariables={},t.FtReaderConverter=Ir,t.FtReaderService=fe,t.LoadErrorEvent=ge,t.MapLoadedEvent=pe,t.NavigationDoneEvent=be,t.NotFoundErrorEvent=ve,t.UnauthorizedErrorEvent=me,t.VisibleTopicsChangeEvent=ye,t.styles=de}({});
92
+ `}get stateManager(){return null==this._stateManager&&(this._stateManager=fe.build(this.id||(""+Math.round(999e3*Math.random())).padStart(6,"0"),this.readerServiceProvider),this._stateManager.errorHandler=t=>this.handleLoadError(t),this.addStore(this.stateManager.store,"reader")),this._stateManager}connectedCallback(){super.connectedCallback(),this.stateManager.setMapId(this.mapId),this.stateManager.awaitService().then((t=>{const o=t.fontsStylesheet();if(o&&!window.location.href.startsWith(this.baseUrl)&&!document.querySelector(`head link[href="${o}"]`)){const t=document.createElement("link");t.setAttribute("rel","stylesheet"),t.setAttribute("href",o),document.head.append(t)}}))}update(t){super.update(t),t.has("readerServiceProvider")&&this.readerServiceProvider&&this.stateManager.initService(this.readerServiceProvider),t.has("mapId")&&this.mapId&&this.stateManager.setMapId(this.mapId),["tocId","section","page","mapId"].some((o=>t.has(o)))&&this.mapId&&this.navigateToTarget()}contentAvailableCallback(t){var o;if(super.contentAvailableCallback(t),(t.has("map")||t.has("toc"))&&this.map&&this.toc&&this.dispatchEvent(new he(this.map,this.toc)),t.has("scrollTarget")&&null==(null===(o=this.scrollTarget)||void 0===o?void 0:o.tocId)){const o=t.get("scrollTarget");null!=(null==o?void 0:o.tocId)&&this.scrollToTargetDebouncer.run((()=>{var t;return this.stateManager.service.getAccurateNavigationData(o.tocId,null===(t=this.currentPage)||void 0===t?void 0:t.number,o.section).then((t=>this.dispatchEvent(new pe(t))))}))}t.has("visibleTopics")&&Promise.all(this.visibleTopics.map((t=>{var o;return this.stateManager.service.getAccurateNavigationData(t,null===(o=this.currentPage)||void 0===o?void 0:o.number)}))).then((t=>{let o=t.filter((t=>null!=t&&""!==t.topicTitle)).map((t=>{var o;return{tocId:t.tocId,title:t.topicTitle,page:t.page,prettyUrl:t.prettyUrl,prettyUrlDuplicated:t.prettyUrlDuplicated,breadcrumb:null===(o=this.stateManager.service)||void 0===o?void 0:o.buildBreadcrumb(t.tocId)}}));this.dispatchEvent(new de(this.map,o))}))}async reload(){await this.stateManager.reload(),this.navigateToTarget()}navigateToTarget(){this.navigationDebouncer.run((()=>{null!=this.tocId?this.stateManager.navigateToTopic(this.tocId,this.section,this.page):null!=this.page&&this.stateManager.navigateToPage(this.page)}))}registerComponent(t){t.stopPropagation();const o=t.composedPath()[0];this.register(o)}register(t){t.setReaderStateManager(this.stateManager)}handleLoadError(t){const o=t;404===o.status?this.dispatchEvent(new be):401===o.status?this.dispatchEvent(new ge):this.dispatchEvent(new ye(t))}reloadBookmarks(){se.reloadBookmarks()}}var Oe;me.styles=ue,ve([Cr({store:Yr.name})],me.prototype,"baseUrl",void 0),ve([a()],me.prototype,"mapId",void 0),ve([a()],me.prototype,"tocId",void 0),ve([a()],me.prototype,"section",void 0),ve([a({type:Number,converter:{fromAttribute:t=>+(null!=t?t:"NaN")>0?+t:Oe}})],me.prototype,"page",void 0),ve([Cr({store:"reader"})],me.prototype,"map",void 0),ve([Cr({store:"reader"})],me.prototype,"toc",void 0),ve([Cr({store:"reader"})],me.prototype,"visibleTopics",void 0),ve([Cr({store:"reader"})],me.prototype,"currentPage",void 0),ve([Cr({store:"reader"})],me.prototype,"scrollTarget",void 0),ve([a({attribute:!1})],me.prototype,"readerServiceProvider",void 0),f("ft-reader-context")(me),t.FtOfficialReaderService=le,t.FtReaderContext=me,t.FtReaderContextCssVariables={},t.FtReaderConverter=Ir,t.FtReaderService=ce,t.LoadErrorEvent=ye,t.MapLoadedEvent=he,t.NavigationDoneEvent=pe,t.NotFoundErrorEvent=be,t.UnauthorizedErrorEvent=ge,t.VisibleTopicsChangeEvent=de,t.styles=ue}({});
@@ -2,7 +2,9 @@ import type { FtMap, FtPaginatedToc, FtRatingSummary, FtRatingType, FtRatingType
2
2
  import { FtReaderService } from "./FtReaderService";
3
3
  import { FtReaderFeatures } from "../model";
4
4
  export declare class FtOfficialReaderService extends FtReaderService {
5
+ private fingerprint?;
5
6
  static build(mapId?: string): Promise<FtOfficialReaderService>;
7
+ clear(): void;
6
8
  protected fetchMap(mapId: string): Promise<FtMap>;
7
9
  protected fetchMapRating(mapId: string): Promise<FtRatingSummary>;
8
10
  protected fetchPages(mapId: string): Promise<FtPaginatedToc>;
@@ -6,20 +6,28 @@ export class FtOfficialReaderService extends FtReaderService {
6
6
  static async build(mapId) {
7
7
  return new FtOfficialReaderService(new FtReaderConverter(), await FluidTopicsApiProvider.await(), new CacheRegistry(), mapId);
8
8
  }
9
- fetchMap(mapId) {
10
- return this.api.getMap(mapId);
9
+ clear() {
10
+ super.clear();
11
+ this.fingerprint = undefined;
12
+ }
13
+ async fetchMap(mapId) {
14
+ var _a;
15
+ const map = await this.api.getMap(mapId);
16
+ this.fingerprint = (_a = map.lastPublication) === null || _a === void 0 ? void 0 : _a.replace(/\D/g, "");
17
+ return map;
11
18
  }
12
19
  fetchMapRating(mapId) {
13
20
  return this.api.getMapRating(mapId);
14
21
  }
15
- fetchPages(mapId) {
16
- return this.api.getPages(mapId);
22
+ async fetchPages(mapId) {
23
+ await this.getMap();
24
+ return this.api.getPages(mapId, this.fingerprint);
17
25
  }
18
26
  fetchTopicHTMLContent(tocNode) {
19
- return this.api.getTopicHTMLContent(this.mapId, tocNode.contentId, "DESIGNED_READER");
27
+ return this.api.getTopicHTMLContent(this.mapId, tocNode.contentId, "DESIGNED_READER", this.fingerprint);
20
28
  }
21
29
  fetchTopicMetadata(tocNode) {
22
- return this.api.getTopic(this.mapId, tocNode.contentId);
30
+ return this.api.getTopic(this.mapId, tocNode.contentId, this.fingerprint);
23
31
  }
24
32
  makeMapFeedbackRequest(message, from) {
25
33
  return this.api.sendMapFeedback(this.mapId, message, from);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluid-topics/ft-reader-context",
3
- "version": "1.0.60",
3
+ "version": "1.0.62",
4
4
  "description": "Context block for integrated reader components",
5
5
  "keywords": [
6
6
  "Lit"
@@ -19,13 +19,13 @@
19
19
  "url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
20
20
  },
21
21
  "dependencies": {
22
- "@fluid-topics/ft-app-context": "1.0.60",
23
- "@fluid-topics/ft-wc-utils": "1.0.60",
22
+ "@fluid-topics/ft-app-context": "1.0.62",
23
+ "@fluid-topics/ft-wc-utils": "1.0.62",
24
24
  "@reduxjs/toolkit": "^1.6.2",
25
25
  "lit": "2.7.2"
26
26
  },
27
27
  "devDependencies": {
28
- "@fluid-topics/public-api": "1.0.45"
28
+ "@fluid-topics/public-api": "1.0.48"
29
29
  },
30
- "gitHead": "8eb7c2ef052f5d3f61ed0bf150fcaee093805450"
30
+ "gitHead": "44e9005773fe47b2e6a9ada16802918052a146cf"
31
31
  }