@fluid-topics/ft-search-result-title 1.2.24 → 1.2.26
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.
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
`)===0?L.substr(1,L.length):L}).forEach(function(L){var k=L.split(":"),I=k.shift().trim();if(I){var at=k.join(":").trim();try{g.append(I,at)}catch(Wt){console.warn("Response "+Wt.message)}}}),g}A.call(M.prototype);function $(u,g){if(!(this instanceof $))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');if(g||(g={}),this.type="default",this.status=g.status===void 0?200:g.status,this.status<200||this.status>599)throw new RangeError("Failed to construct 'Response': The status provided (0) is outside the range [200, 599].");this.ok=this.status>=200&&this.status<300,this.statusText=g.statusText===void 0?"":""+g.statusText,this.headers=new y(g.headers),this.url=g.url||"",this._initBody(u)}A.call($.prototype),$.prototype.clone=function(){return new $(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new y(this.headers),url:this.url})},$.error=function(){var u=new $(null,{status:200,statusText:""});return u.ok=!1,u.status=0,u.type="error",u};var me=[301,302,303,307,308];$.redirect=function(u,g){if(me.indexOf(g)===-1)throw new RangeError("Invalid status code");return new $(null,{status:g,headers:{location:u}})},o.DOMException=n.DOMException;try{new o.DOMException}catch{o.DOMException=function(g,C){this.message=g,this.name=C;var L=Error(g);this.stack=L.stack},o.DOMException.prototype=Object.create(Error.prototype),o.DOMException.prototype.constructor=o.DOMException}function Ae(u,g){return new Promise(function(C,L){var k=new M(u,g);if(k.signal&&k.signal.aborted)return L(new o.DOMException("Aborted","AbortError"));var I=new XMLHttpRequest;function at(){I.abort()}I.onload=function(){var W={statusText:I.statusText,headers:ge(I.getAllResponseHeaders()||"")};k.url.indexOf("file://")===0&&(I.status<200||I.status>599)?W.status=200:W.status=I.status,W.url="responseURL"in I?I.responseURL:W.headers.get("X-Request-URL");var be="response"in I?I.response:I.responseText;setTimeout(function(){C(new $(be,W))},0)},I.onerror=function(){setTimeout(function(){L(new TypeError("Network request failed"))},0)},I.ontimeout=function(){setTimeout(function(){L(new TypeError("Network request timed out"))},0)},I.onabort=function(){setTimeout(function(){L(new o.DOMException("Aborted","AbortError"))},0)};function Wt(W){try{return W===""&&n.location.href?n.location.href:W}catch{return W}}if(I.open(k.method,Wt(k.url),!0),k.credentials==="include"?I.withCredentials=!0:k.credentials==="omit"&&(I.withCredentials=!1),"responseType"in I&&(i.blob?I.responseType="blob":i.arrayBuffer&&(I.responseType="arraybuffer")),g&&typeof g.headers=="object"&&!(g.headers instanceof y||n.Headers&&g.headers instanceof n.Headers)){var Ur=[];Object.getOwnPropertyNames(g.headers).forEach(function(W){Ur.push(f(W)),I.setRequestHeader(W,p(g.headers[W]))}),k.headers.forEach(function(W,be){Ur.indexOf(be)===-1&&I.setRequestHeader(be,W)})}else k.headers.forEach(function(W,be){I.setRequestHeader(be,W)});k.signal&&(k.signal.addEventListener("abort",at),I.onreadystatechange=function(){I.readyState===4&&k.signal.removeEventListener("abort",at)}),I.send(typeof k._bodyInit>"u"?null:k._bodyInit)})}return Ae.polyfill=!0,n.fetch||(n.fetch=Ae,n.Headers=y,n.Request=M,n.Response=$),o.Headers=y,o.Request=M,o.Response=$,o.fetch=Ae,o}({})})(ct);ct.fetch.ponyfill=!0;delete ct.fetch.polyfill;var Ne=it.fetch?it:ct;ae=Ne.fetch;ae.default=Ne.fetch;ae.fetch=Ne.fetch;ae.Headers=Ne.Headers;ae.Request=Ne.Request;ae.Response=Ne.Response;Hr.exports=ae});var ma=Ke((dh,ga)=>{ga.exports=ftGlobals.litUnsafeHTML});var Ea=N(B());var nt=N(J()),Oa=N(X());var on=N(B()),nn=N(X());var Rt=N(B());var zr=N(B());var La=N($r(),1);var Gr;(function(r){r.black="black",r.green="green",r.blue="blue",r.purple="purple",r.red="red",r.orange="orange",r.yellow="yellow"})(Gr||(Gr={}));var jr;(function(r){r.OFFICIAL="OFFICIAL",r.PERSONAL="PERSONAL",r.SHARED="SHARED"})(jr||(jr={}));var Kr;(function(r){r.THIRD_PARTY="THIRD_PARTY",r.OFF_THE_GRID="OFF_THE_GRID",r.CONTENT_PACKAGER="CONTENT_PACKAGER",r.PAGES="PAGES",r.DESIGNED_READER="DESIGNED_READER"})(Kr||(Kr={}));var Vr;(function(r){r.HOMEPAGE="HOMEPAGE",r.CUSTOM="CUSTOM",r.HEADER="HEADER",r.READER="READER",r.TOPIC_TEMPLATE="TOPIC_TEMPLATE",r.SEARCH="SEARCH",r.SEARCH_RESULT="SEARCH_RESULT"})(Vr||(Vr={}));var Zr;(function(r){r.CLASSIC="CLASSIC",r.CUSTOM="CUSTOM",r.DESIGNER="DESIGNER"})(Zr||(Zr={}));var qr;(function(r){r.AND="AND",r.OR="OR",r.MONOVALUED="MONOVALUED"})(qr||(qr={}));var Yr;(function(r){r.NONE="NONE",r.ALPHABET="ALPHABET",r.VERSION="VERSION"})(Yr||(Yr={}));var Xr;(function(r){r.STARS="STARS",r.LIKE="LIKE",r.DICHOTOMOUS="DICHOTOMOUS",r.NO_RATING="NO_RATING"})(Xr||(Xr={}));var Qr;(function(r){r.LAST_WEEK="LAST_WEEK",r.LAST_MONTH="LAST_MONTH",r.LAST_QUARTER="LAST_QUARTER",r.LAST_YEAR="LAST_YEAR",r.CUSTOM="CUSTOM"})(Qr||(Qr={}));var Jr;(function(r){r.ASC="ASC",r.DESC="DESC"})(Jr||(Jr={}));var eo;(function(r){r.ALPHA="ALPHA",r.NATURAL="NATURAL"})(eo||(eo={}));var zt;(function(r){r.EVERYWHERE="EVERYWHERE",r.TITLE_ONLY="TITLE_ONLY",r.NONE="NONE"})(zt||(zt={}));var to;(function(r){r.ARTICLE="ARTICLE",r.BOOK="BOOK",r.SHARED_BOOK="SHARED_BOOK"})(to||(to={}));var st;(function(r){r.FLUIDTOPICS="FLUIDTOPICS",r.EXTERNAL="EXTERNAL"})(st||(st={}));var ro;(function(r){r.MAP="MAP",r.DOCUMENT="DOCUMENT",r.TOPIC="TOPIC",r.PERSONAL_BOOK="PERSONAL_BOOK",r.SHARED_BOOK="SHARED_BOOK"})(ro||(ro={}));var oo;(function(r){r.LAST_WEEK="LAST_WEEK",r.LAST_MONTH="LAST_MONTH",r.LAST_QUARTER="LAST_QUARTER",r.LAST_YEAR="LAST_YEAR"})(oo||(oo={}));var Ie;(function(r){r.MAP="MAP",r.DOCUMENT="DOCUMENT",r.TOPIC="TOPIC"})(Ie||(Ie={}));var Ht;(function(r){r.DEFAULT="DEFAULT",r.DOCUMENTS="DOCUMENTS",r.ALL_TOPICS="ALL_TOPICS",r.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(Ht||(Ht={}));var U;(function(r){r.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",r.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",r.HTML_EXPORT_USER="HTML_EXPORT_USER",r.PDF_EXPORT_USER="PDF_EXPORT_USER",r.SAVED_SEARCH_USER="SAVED_SEARCH_USER",r.COLLECTION_USER="COLLECTION_USER",r.OFFLINE_USER="OFFLINE_USER",r.ANALYTICS_USER="ANALYTICS_USER",r.BETA_USER="BETA_USER",r.DEBUG_USER="DEBUG_USER",r.PRINT_USER="PRINT_USER",r.RATING_USER="RATING_USER",r.FEEDBACK_USER="FEEDBACK_USER",r.GENERATIVE_AI_USER="GENERATIVE_AI_USER",r.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",r.CONTENT_PUBLISHER="CONTENT_PUBLISHER",r.KHUB_ADMIN="KHUB_ADMIN",r.USERS_ADMIN="USERS_ADMIN",r.PORTAL_ADMIN="PORTAL_ADMIN",r.ADMIN="ADMIN",r.DEVELOPER="DEVELOPER"})(U||(U={}));var no;(function(r){r.VALID="VALID",r.INVALID="INVALID"})(no||(no={}));var ao;(function(r){r.TEXT="TEXT",r.HTML="HTML"})(ao||(ao={}));var Gi={[U.PERSONAL_BOOK_SHARE_USER]:[U.PERSONAL_BOOK_USER],[U.HTML_EXPORT_USER]:[U.PERSONAL_BOOK_USER],[U.PDF_EXPORT_USER]:[U.PERSONAL_BOOK_USER],[U.KHUB_ADMIN]:[U.CONTENT_PUBLISHER],[U.ADMIN]:[U.KHUB_ADMIN,U.USERS_ADMIN,U.PORTAL_ADMIN],[U.DEVELOPER]:[U.BETA_USER,U.DEBUG_USER],[U.GENERATIVE_AI_EXPORT_USER]:[U.GENERATIVE_AI_USER]};var rn=N(B());var uo=N(J()),G=N(X()),q=N(B());var io=N(J());var co=io.css`
|
|
3
3
|
`;var lt=N(B()),Pa="ft-app-info",$t=class extends CustomEvent{constructor(t){super("authentication-change",{detail:t})}},Fa={session:(r,t)=>{(0,lt.deepEqual)(r.session,t.payload)||(r.session=t.payload,setTimeout(()=>E.dispatchEvent(new $t(t.payload)),0))}},E=lt.FtReduxStore.get({name:Pa,reducers:Fa,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],defaultLocales:void 0,searchInAllLanguagesAllowed:!1,metadataConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,session:void 0,openExternalDocumentInNewTab:!1,navigatorOnline:!0,forcedOffline:!1}});var ie=N(B());var Gt=N(B());var xe=class r{static get(t){let{baseUrl:o,apiIntegrationIdentifier:n}=E.getState(),i=t??n;if(o&&i&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,i,!0)}static await(t){return new Promise(o=>{let n=r.get(t);if(n)o(n);else{let i=E.subscribe(()=>{n=r.get(t),n&&(i(),o(n))})}})}};var ee=class{constructor(t=!0,o){var n;this.overrideApi=o;let i=this.constructor;i.commonCache=(n=i.commonCache)!==null&&n!==void 0?n:new Gt.CacheRegistry,this.cache=t?i.commonCache:new Gt.CacheRegistry}get api(){var t;return(t=this.overrideApi)!==null&&t!==void 0?t:xe.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):xe.await()}clearCache(){this.cache.clearAll()}};var so,ka=Symbol("clearAfterUnitTest"),dt=class extends ee{constructor(t){super(),this.messageContextProvider=t,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[so]=()=>{this.defaultMessages={},this.cache=new ie.CacheRegistry,this.listeners={}},this.currentUiLocale=E.getState().uiLocale,E.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:t}=E.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){let o=t.name.toLowerCase();this.cache.setFinal(o,t),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,o){var n;if(t=t.toLowerCase(),Object.keys(o).length>0){let i={...(n=this.defaultMessages[t])!==null&&n!==void 0?n:{},...o};(0,ie.deepEqual)(this.defaultMessages[t],i)||(this.defaultMessages[t]=i,await this.notify(t))}await this.fetchContext(t)}resolveContext(t){var o,n;return this.fetchContext(t),(n=(o=this.cache.getNow(t))===null||o===void 0?void 0:o.messages)!==null&&n!==void 0?n:{}}resolveRawMessage(t,o){let n=t.toLowerCase();return this.resolveContext(n)[o]}resolveMessage(t,o,...n){var i;let c=t.toLowerCase(),l=this.resolveContext(c);return new ie.ParametrizedLabelResolver((i=this.defaultMessages[c])!==null&&i!==void 0?i:{},l).resolve(o,...n)}async fetchContext(t){if(!this.cache.has(t))try{await this.cache.get(t,()=>this.messageContextProvider(this.currentUiLocale,t)),await this.notify(t)}catch(o){console.error(o)}}subscribe(t,o){var n;return t=t.toLowerCase(),this.listeners[t]=(n=this.listeners[t])!==null&&n!==void 0?n:new Set,this.listeners[t].add(o),()=>{var i;return(i=this.listeners[t])===null||i===void 0?void 0:i.delete(o)}}async notifyAll(){await Promise.all(Object.keys(this.listeners).map(t=>this.notify(t)))}async notify(t){this.listeners[t]!=null&&await Promise.all([...this.listeners[t].values()].map(o=>(0,ie.delay)(0).then(()=>o()).catch(()=>null)))}};so=ka;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends dt{constructor(){super(async(r,t)=>(await this.awaitApi).getFluidTopicsMessageContext(r,t))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends dt{constructor(){super(async(r,t)=>(await this.awaitApi).getCustomMessageContext(r,t))}});var lo=window.FluidTopicsI18nService,sc=window.FluidTopicsCustomI18nService;var z=function(r,t,o,n){var i=arguments.length,c=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")c=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(l=r[d])&&(c=(i<3?l(c):i>3?l(t,o,c):l(t,o))||c);return i>3&&c&&Object.defineProperty(t,o,c),c},_=class extends q.FtLitElement{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.editorMode=!1,this.noCustom=!1,this.openExternalDocumentInNewTab=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.navigatorOnline=!1,this.forcedOffline=!1,this.apiProvider=()=>xe.get(),this.messageContexts=[],this.cache=new q.CacheRegistry,this.cleanSessionDebouncer=new q.Debouncer}render(){return uo.html`
|
|
4
4
|
<slot></slot>
|
|
5
|
-
`}update(t){var o,n,i,c,l;super.update(t),t.has("baseUrl")&&(E.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),t.has("apiIntegrationIdentifier")&&E.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&E.actions.uiLocale(this.uiLocale),t.has("metadataConfiguration")&&E.actions.metadataConfiguration(this.metadataConfiguration),t.has("noCustom")&&E.actions.noCustom(this.noCustom),t.has("editorMode")&&E.actions.editorMode(this.editorMode),t.has("noCustomComponent")&&E.actions.noCustomComponent(this.noCustomComponent),t.has("session")&&E.actions.session(this.session),t.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(d=>lo.addContext(d)),t.has("openExternalDocumentInNewTab")&&E.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),t.has("navigatorOnline")&&E.actions.navigatorOnline(this.navigatorOnline),t.has("forcedOffline")&&E.actions.forcedOffline(this.forcedOffline),t.has("localesConfiguration")&&(E.actions.defaultLocales((o=this.localesConfiguration)===null||o===void 0?void 0:o.defaultLocales),E.actions.availableUiLocales((i=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&i!==void 0?i:[]),E.actions.searchInAllLanguagesAllowed((l=(c=this.localesConfiguration)===null||c===void 0?void 0:c.allLanguagesAllowed)!==null&&l!==void 0?l:!1)),setTimeout(()=>this.updateIfNeeded())}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.session==null&&this.updateSession(),this.metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration())}async updateSession(){this.session=await this.cache.get("session",async()=>{let t=await this.apiProvider().getCurrentSession();return t.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.session=void 0},t.idleTimeoutInMillis),t})}async updateMetadataConfiguration(){this.metadataConfiguration=await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration())}async updateLocalesConfiguration(){this.localesConfiguration=await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration())}};_.elementDefinitions={};_.styles=co;z([(0,G.property)()],_.prototype,"baseUrl",void 0);z([(0,G.property)()],_.prototype,"apiIntegrationIdentifier",void 0);z([(0,G.property)()],_.prototype,"uiLocale",void 0);z([(0,q.jsonProperty)(null)],_.prototype,"availableUiLocales",void 0);z([(0,q.jsonProperty)(null)],_.prototype,"metadataConfiguration",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"editorMode",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"noCustom",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"openExternalDocumentInNewTab",void 0);z([(0,G.property)({converter:{fromAttribute(r){return r==="false"?!1:r==="true"||(r??!1)}}})],_.prototype,"noCustomComponent",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"withManualResources",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"navigatorOnline",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"forcedOffline",void 0);z([(0,G.property)({type:Object})],_.prototype,"apiProvider",void 0);z([(0,q.jsonProperty)([])],_.prototype,"messageContexts",void 0);z([(0,q.jsonProperty)(void 0)],_.prototype,"session",void 0);z([(0,G.state)()],_.prototype,"localesConfiguration",void 0);var Si=N(X());function _a(r,t){if(r===t)return!0;if(r&&t&&typeof r=="object"&&typeof t=="object"){if(r.constructor!==t.constructor)return!1;var o,n,i;if(Array.isArray(r)){if(o=r.length,o!=t.length)return!1;for(n=o;n--!==0;)if(!ut(r[n],t[n]))return!1;return!0}if(r instanceof Map&&t instanceof Map){if(r.size!==t.size)return!1;for(n of r.entries())if(!t.has(n[0]))return!1;for(n of r.entries())if(!ut(n[1],t.get(n[0])))return!1;return!0}if(r instanceof Set&&t instanceof Set){if(r.size!==t.size)return!1;for(n of r.entries())if(!t.has(n[0]))return!1;return!0}if(r.constructor===RegExp)return r.source===t.source&&r.flags===t.flags;if(r.valueOf!==Object.prototype.valueOf)return r.valueOf()===t.valueOf();if(i=Object.keys(r),o=i.length,o!==Object.keys(t).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[n]))return!1;for(n=o;n--!==0;){var c=i[n];if(!ut(r[c],t[c]))return!1}return!0}return r!==r&&t!==t}function ut(r,t){try{return _a(r,t)}catch{return!1}}function pt(r,t){return!ut(r,t)}var Ua=N(X(),1);var ft=class{constructor(){this.queue=[]}add(t,o=!1){o&&(this.queue=this.queue.filter(n=>n.type!==t.type)),this.queue.push(t)}consume(t){let o=this.queue.find(n=>n.type===t);return o&&(this.queue=this.queue.filter(n=>n!==o)),o}};var Ve=N(X(),1);var po=N(X(),1);function fo(r,t){let o=()=>JSON.parse(JSON.stringify(r));return(0,po.property)({type:Object,converter:{fromAttribute:n=>{if(n==null)return o();try{return JSON.parse(n)}catch{return o()}},toAttribute:n=>JSON.stringify(n)},hasChanged:pt,...t??{}})}var ht=class{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 this.promise==null&&(this.promise=new Promise((o,n)=>{this.resolvePromise=o,this.rejectPromise=n})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),t??this.timeout),this.promise}async runCallbacks(){var t,o;let n=[...this.callbacks];this.callbacks=[];let i=(t=this.rejectPromise)!==null&&t!==void 0?t:()=>null,c=(o=this.resolvePromise)!==null&&o!==void 0?o:()=>null;this.clearPromise();for(let l of n)try{await l()}catch(d){i(d);return}c(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var yo=N(J(),1);var yt=window,Da=yt.ShadowRoot&&(yt.ShadyCSS===void 0||yt.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Ec=Symbol();var ho=(r,t)=>{Da?r.adoptedStyleSheets=t.map(o=>o instanceof CSSStyleSheet?o:o.styleSheet):t.forEach(o=>{let n=document.createElement("style"),i=yt.litNonce;i!==void 0&&n.setAttribute("nonce",i),n.textContent=o.cssText,r.appendChild(n)})};var gt=class extends yo.LitElement{createRenderRoot(){let t=this.constructor;t.elementDefinitions&&!t.registry&&(t.registry=new CustomElementRegistry,Object.entries(t.elementDefinitions).forEach(([i,c])=>t.registry.define(i,c)));let o={...t.shadowRootOptions,customElements:t.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return ho(n,t.elementStyles),n}};var mt=function(r,t,o,n){var i=arguments.length,c=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")c=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(l=r[d])&&(c=(i<3?l(c):i>3?l(t,o,c):l(t,o))||c);return i>3&&c&&Object.defineProperty(t,o,c),c},xo,go=Symbol("constructorPrototype"),mo=Symbol("constructorName"),vo=Symbol("exportpartsDebouncer"),bo=Symbol("dynamicDependenciesLoaded"),ce=class extends gt{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[xo]=new ht(5),this[mo]=this.constructor.name,this[go]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[mo]&&Object.setPrototypeOf(this,this[go])}connectedCallback(){super.connectedCallback();try{this.shadowRoot&&!this.shadowRoot.adoptedStyleSheets.includes(this.adoptedCustomStyleSheet)&&(this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,this.adoptedCustomStyleSheet]),this.useAdoptedStyleSheets=!0}catch(o){this.useAdoptedStyleSheets=!1,console.error("Cannot use adopted stylesheets",o)}let t=this.constructor;t[bo]||(t[bo]=!0,this.importDynamicDependencies())}importDynamicDependencies(){}updated(t){super.updated(t),this.updateComplete.then(()=>{this.contentAvailableCallback(t),this.applyCustomStylesheet(t),this.scheduleExportpartsUpdate()})}contentAvailableCallback(t){}applyCustomStylesheet(t){var o,n,i;if(((n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))!==null&&n!==void 0?n:[]).forEach(c=>c.remove()),this.useAdoptedStyleSheets){if(t.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((i=this.customStylesheet)!==null&&i!==void 0?i:"")}catch(c){console.error(c,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let c=document.createElement("style");c.classList.add("ft-lit-element--custom-stylesheet"),c.innerHTML=this.customStylesheet,this.shadowRoot.append(c)}}scheduleExportpartsUpdate(){var t,o,n;(!((t=this.exportpartsPrefix)===null||t===void 0)&&t.trim()||(n=(o=this.exportpartsPrefixes)===null||o===void 0?void 0:o.length)!==null&&n!==void 0&&n)&&this[vo].run(()=>{var i,c;!((i=this.exportpartsPrefix)===null||i===void 0)&&i.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((c=this.exportpartsPrefixes)===null||c===void 0?void 0:c.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})}setExportpartsAttribute(t){var o,n,i,c,l,d;let f=m=>m!=null&&m.trim().length>0,p=t.filter(f).map(m=>m.trim());if(p.length===0){this.removeAttribute("exportparts");return}let h=new Set;for(let m of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let v=(c=(i=m.getAttribute("part"))===null||i===void 0?void 0:i.split(" "))!==null&&c!==void 0?c:[],b=(d=(l=m.getAttribute("exportparts"))===null||l===void 0?void 0:l.split(",").map(S=>S.split(":")[1]))!==null&&d!==void 0?d:[];new Array(...v,...b).filter(f).map(S=>S.trim()).forEach(S=>h.add(S))}if(h.size===0){this.removeAttribute("exportparts");return}let y=[...h.values()].flatMap(m=>p.map(v=>`${m}:${v}--${m}`));this.setAttribute("exportparts",[...this.part,...y].join(", "))}};xo=vo;mt([(0,Ve.property)()],ce.prototype,"exportpartsPrefix",void 0);mt([fo([])],ce.prototype,"exportpartsPrefixes",void 0);mt([(0,Ve.property)()],ce.prototype,"customStylesheet",void 0);mt([(0,Ve.state)()],ce.prototype,"useAdoptedStyleSheets",void 0);function Ze(r){var t;return(t=r?.isFtReduxStore)!==null&&t!==void 0?t:!1}var So,Oo,Co,qe=Symbol("internalReduxEventsUnsubscribers"),se=Symbol("internalStoresUnsubscribers"),ve=Symbol("internalStores"),Ye=class extends ce{constructor(){super(...arguments),this[So]=new Map,this[Oo]=new Map,this[Co]=new Map}get reduxConstructor(){return this.constructor}update(t){super.update(t),[...this.reduxConstructor.reduxReactiveProperties].some(o=>t.has(o))&&this.updateFromStores()}getUnnamedStore(){if(this[ve].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[ve].values()][0]}getStore(t){return t==null?this.getUnnamedStore():this[ve].get(t)}addStore(t,o){var n;o=(n=o??(Ze(t)?t.name:void 0))!==null&&n!==void 0?n:"default-store",this.unsubscribeFromStore(o),this[ve].set(o,t),this.subscribeToStore(o,t),this.updateFromStores()}removeStore(t){let o=typeof t=="string"?t:t.name;this.unsubscribeFromStore(o),this[ve].delete(o)}setupStores(){this.unsubscribeFromStores(),this[ve].forEach((t,o)=>this.subscribeToStore(o,t)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((t,o)=>{let n=this.constructor.getPropertyOptions(o);if(!n?.attribute||!this.hasAttribute(typeof n?.attribute=="string"?n.attribute:o)){let i=this.getStore(t.store);i&&(t.store?this[se].has(t.store):this[se].size>0)&&(this[o]=t.selector(i.getState(),this))}})}subscribeToStore(t,o){var n;this[se].set(t,o.subscribe(()=>this.updateFromStores())),this[qe].set(t,[]),Ze(o)&&o.eventBus&&((n=this.reduxConstructor.reduxEventListeners)===null||n===void 0||n.forEach((i,c)=>{if(typeof this[c]=="function"&&(!i.store||o.name===i.store)){let l=d=>this[c](d);o.addEventListener(i.eventName,l),this[qe].get(t).push(()=>o.removeEventListener(i.eventName,l))}})),this.onStoreAvailable(t)}unsubscribeFromStores(){this[se].forEach((t,o)=>this.unsubscribeFromStore(o))}unsubscribeFromStore(t){var o;this[se].has(t)&&this[se].get(t)(),this[se].delete(t),(o=this[qe].get(t))===null||o===void 0||o.forEach(n=>n()),this[qe].delete(t)}onStoreAvailable(t){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}};So=se,Oo=ve,Co=qe;Ye.reduxProperties=new Map;Ye.reduxReactiveProperties=new Set;Ye.reduxEventListeners=new Map;function K(r){for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;n<t;n++)o[n-1]=arguments[n];if(0)var i,c;throw Error("[Immer] minified error nr: "+r+(o.length?" "+o.map(function(l){return"'"+l+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function te(r){return!!r&&!!r[F]}function Y(r){var t;return!!r&&(function(o){if(!o||typeof o!="object")return!1;var n=Object.getPrototypeOf(o);if(n===null)return!0;var i=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return i===Object||typeof i=="function"&&Function.toString.call(i)===ja}(r)||Array.isArray(r)||!!r[To]||!!(!((t=r.constructor)===null||t===void 0)&&t[To])||Jt(r)||er(r))}function Se(r,t,o){o===void 0&&(o=!1),Le(r)===0?(o?Object.keys:Te)(r).forEach(function(n){o&&typeof n=="symbol"||t(n,r[n],r)}):r.forEach(function(n,i){return t(i,n,r)})}function Le(r){var t=r[F];return t?t.i>3?t.i-4:t.i:Array.isArray(r)?1:Jt(r)?2:er(r)?3:0}function Re(r,t){return Le(r)===2?r.has(t):Object.prototype.hasOwnProperty.call(r,t)}function Ba(r,t){return Le(r)===2?r.get(t):r[t]}function Lo(r,t,o){var n=Le(r);n===2?r.set(t,o):n===3?r.add(o):r[t]=o}function Po(r,t){return r===t?r!==0||1/r==1/t:r!=r&&t!=t}function Jt(r){return $a&&r instanceof Map}function er(r){return Ga&&r instanceof Set}function le(r){return r.o||r.t}function tr(r){if(Array.isArray(r))return Array.prototype.slice.call(r);var t=_o(r);delete t[F];for(var o=Te(t),n=0;n<o.length;n++){var i=o[n],c=t[i];c.writable===!1&&(c.writable=!0,c.configurable=!0),(c.get||c.set)&&(t[i]={configurable:!0,writable:!0,enumerable:c.enumerable,value:r[i]})}return Object.create(Object.getPrototypeOf(r),t)}function rr(r,t){return t===void 0&&(t=!1),or(r)||te(r)||!Y(r)||(Le(r)>1&&(r.set=r.add=r.clear=r.delete=Ma),Object.freeze(r),t&&Se(r,function(o,n){return rr(n,!0)},!0)),r}function Ma(){K(2)}function or(r){return r==null||typeof r!="object"||Object.isFrozen(r)}function Q(r){var t=Qt[r];return t||K(18,r),t}function Wa(r,t){Qt[r]||(Qt[r]=t)}function qt(){return Qe}function jt(r,t){t&&(Q("Patches"),r.u=[],r.s=[],r.v=t)}function bt(r){Yt(r),r.p.forEach(za),r.p=null}function Yt(r){r===Qe&&(Qe=r.l)}function Eo(r){return Qe={p:[],l:Qe,h:r,m:!0,_:0}}function za(r){var t=r[F];t.i===0||t.i===1?t.j():t.g=!0}function Kt(r,t){t._=t.p.length;var o=t.p[0],n=r!==void 0&&r!==o;return t.h.O||Q("ES5").S(t,r,n),n?(o[F].P&&(bt(t),K(4)),Y(r)&&(r=xt(t,r),t.l||vt(t,r)),t.u&&Q("Patches").M(o[F].t,r,t.u,t.s)):r=xt(t,o,[]),bt(t),t.u&&t.v(t.u,t.s),r!==ko?r:void 0}function xt(r,t,o){if(or(t))return t;var n=t[F];if(!n)return Se(t,function(d,f){return wo(r,n,t,d,f,o)},!0),t;if(n.A!==r)return t;if(!n.P)return vt(r,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=n.i===4||n.i===5?n.o=tr(n.k):n.o,c=i,l=!1;n.i===3&&(c=new Set(i),i.clear(),l=!0),Se(c,function(d,f){return wo(r,n,i,d,f,o,l)}),vt(r,i,!1),o&&r.u&&Q("Patches").N(n,o,r.u,r.s)}return n.o}function wo(r,t,o,n,i,c,l){if(te(i)){var d=xt(r,i,c&&t&&t.i!==3&&!Re(t.R,n)?c.concat(n):void 0);if(Lo(o,n,d),!te(d))return;r.m=!1}else l&&o.add(i);if(Y(i)&&!or(i)){if(!r.h.D&&r._<1)return;xt(r,i),t&&t.A.l||vt(r,i)}}function vt(r,t,o){o===void 0&&(o=!1),!r.l&&r.h.D&&r.m&&rr(t,o)}function Vt(r,t){var o=r[F];return(o?le(o):r)[t]}function Ao(r,t){if(t in r)for(var o=Object.getPrototypeOf(r);o;){var n=Object.getOwnPropertyDescriptor(o,t);if(n)return n;o=Object.getPrototypeOf(o)}}function de(r){r.P||(r.P=!0,r.l&&de(r.l))}function Zt(r){r.o||(r.o=tr(r.t))}function Xt(r,t,o){var n=Jt(t)?Q("MapSet").F(t,o):er(t)?Q("MapSet").T(t,o):r.O?function(i,c){var l=Array.isArray(i),d={i:l?1:0,A:c?c.A:qt(),P:!1,I:!1,R:{},l:c,t:i,k:null,o:null,j:null,C:!1},f=d,p=Je;l&&(f=[d],p=Xe);var h=Proxy.revocable(f,p),y=h.revoke,m=h.proxy;return d.k=m,d.j=y,m}(t,o):Q("ES5").J(t,o);return(o?o.A:qt()).p.push(n),n}function Ha(r){return te(r)||K(22,r),function t(o){if(!Y(o))return o;var n,i=o[F],c=Le(o);if(i){if(!i.P&&(i.i<4||!Q("ES5").K(i)))return i.t;i.I=!0,n=No(o,c),i.I=!1}else n=No(o,c);return Se(n,function(l,d){i&&Ba(i.t,l)===d||Lo(n,l,t(d))}),c===3?new Set(n):n}(r)}function No(r,t){switch(t){case 2:return new Map(r);case 3:return Array.from(r)}return tr(r)}function Fo(){function r(l,d){var f=c[l];return f?f.enumerable=d:c[l]=f={configurable:!0,enumerable:d,get:function(){var p=this[F];return Je.get(p,l)},set:function(p){var h=this[F];Je.set(h,l,p)}},f}function t(l){for(var d=l.length-1;d>=0;d--){var f=l[d][F];if(!f.P)switch(f.i){case 5:n(f)&&de(f);break;case 4:o(f)&&de(f)}}}function o(l){for(var d=l.t,f=l.k,p=Te(f),h=p.length-1;h>=0;h--){var y=p[h];if(y!==F){var m=d[y];if(m===void 0&&!Re(d,y))return!0;var v=f[y],b=v&&v[F];if(b?b.t!==m:!Po(v,m))return!0}}var S=!!d[F];return p.length!==Te(d).length+(S?0:1)}function n(l){var d=l.k;if(d.length!==l.t.length)return!0;var f=Object.getOwnPropertyDescriptor(d,d.length-1);if(f&&!f.get)return!0;for(var p=0;p<d.length;p++)if(!d.hasOwnProperty(p))return!0;return!1}function i(l){l.g&&K(3,JSON.stringify(le(l)))}var c={};Wa("ES5",{J:function(l,d){var f=Array.isArray(l),p=function(y,m){if(y){for(var v=Array(m.length),b=0;b<m.length;b++)Object.defineProperty(v,""+b,r(b,!0));return v}var S=_o(m);delete S[F];for(var R=Te(S),w=0;w<R.length;w++){var A=R[w];S[A]=r(A,y||!!S[A].enumerable)}return Object.create(Object.getPrototypeOf(m),S)}(f,l),h={i:f?5:4,A:d?d.A:qt(),P:!1,I:!1,R:{},l:d,t:l,k:p,o:null,g:!1,C:!1};return Object.defineProperty(p,F,{value:h,writable:!0}),p},S:function(l,d,f){f?te(d)&&d[F].A===l&&t(l.p):(l.u&&function p(h){if(h&&typeof h=="object"){var y=h[F];if(y){var m=y.t,v=y.k,b=y.R,S=y.i;if(S===4)Se(v,function(T){T!==F&&(m[T]!==void 0||Re(m,T)?b[T]||p(v[T]):(b[T]=!0,de(y)))}),Se(m,function(T){v[T]!==void 0||Re(v,T)||(b[T]=!1,de(y))});else if(S===5){if(n(y)&&(de(y),b.length=!0),v.length<m.length)for(var R=v.length;R<m.length;R++)b[R]=!1;else for(var w=m.length;w<v.length;w++)b[w]=!0;for(var A=Math.min(v.length,m.length),P=0;P<A;P++)v.hasOwnProperty(P)||(b[P]=!0),b[P]===void 0&&p(v[P])}}}}(l.p[0]),t(l.p))},K:function(l){return l.i===4?o(l):n(l)}})}var Io,Qe,nr=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",$a=typeof Map<"u",Ga=typeof Set<"u",Ro=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",ko=nr?Symbol.for("immer-nothing"):((Io={})["immer-nothing"]=!0,Io),To=nr?Symbol.for("immer-draftable"):"__$immer_draftable",F=nr?Symbol.for("immer-state"):"__$immer_state";var ja=""+Object.prototype.constructor,Te=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(r){return Object.getOwnPropertyNames(r).concat(Object.getOwnPropertySymbols(r))}:Object.getOwnPropertyNames,_o=Object.getOwnPropertyDescriptors||function(r){var t={};return Te(r).forEach(function(o){t[o]=Object.getOwnPropertyDescriptor(r,o)}),t},Qt={},Je={get:function(r,t){if(t===F)return r;var o=le(r);if(!Re(o,t))return function(i,c,l){var d,f=Ao(c,l);return f?"value"in f?f.value:(d=f.get)===null||d===void 0?void 0:d.call(i.k):void 0}(r,o,t);var n=o[t];return r.I||!Y(n)?n:n===Vt(r.t,t)?(Zt(r),r.o[t]=Xt(r.A.h,n,r)):n},has:function(r,t){return t in le(r)},ownKeys:function(r){return Reflect.ownKeys(le(r))},set:function(r,t,o){var n=Ao(le(r),t);if(n?.set)return n.set.call(r.k,o),!0;if(!r.P){var i=Vt(le(r),t),c=i?.[F];if(c&&c.t===o)return r.o[t]=o,r.R[t]=!1,!0;if(Po(o,i)&&(o!==void 0||Re(r.t,t)))return!0;Zt(r),de(r)}return r.o[t]===o&&(o!==void 0||t in r.o)||Number.isNaN(o)&&Number.isNaN(r.o[t])||(r.o[t]=o,r.R[t]=!0),!0},deleteProperty:function(r,t){return Vt(r.t,t)!==void 0||t in r.t?(r.R[t]=!1,Zt(r),de(r)):delete r.R[t],r.o&&delete r.o[t],!0},getOwnPropertyDescriptor:function(r,t){var o=le(r),n=Reflect.getOwnPropertyDescriptor(o,t);return n&&{writable:!0,configurable:r.i!==1||t!=="length",enumerable:n.enumerable,value:o[t]}},defineProperty:function(){K(11)},getPrototypeOf:function(r){return Object.getPrototypeOf(r.t)},setPrototypeOf:function(){K(12)}},Xe={};Se(Je,function(r,t){Xe[r]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),Xe.deleteProperty=function(r,t){return Xe.set.call(this,r,t,void 0)},Xe.set=function(r,t,o){return Je.set.call(this,r[0],t,o,r[0])};var Ka=function(){function r(o){var n=this;this.O=Ro,this.D=!0,this.produce=function(i,c,l){if(typeof i=="function"&&typeof c!="function"){var d=c;c=i;var f=n;return function(S){var R=this;S===void 0&&(S=d);for(var w=arguments.length,A=Array(w>1?w-1:0),P=1;P<w;P++)A[P-1]=arguments[P];return f.produce(S,function(T){var M;return(M=c).call.apply(M,[R,T].concat(A))})}}var p;if(typeof c!="function"&&K(6),l!==void 0&&typeof l!="function"&&K(7),Y(i)){var h=Eo(n),y=Xt(n,i,void 0),m=!0;try{p=c(y),m=!1}finally{m?bt(h):Yt(h)}return typeof Promise<"u"&&p instanceof Promise?p.then(function(S){return jt(h,l),Kt(S,h)},function(S){throw bt(h),S}):(jt(h,l),Kt(p,h))}if(!i||typeof i!="object"){if((p=c(i))===void 0&&(p=i),p===ko&&(p=void 0),n.D&&rr(p,!0),l){var v=[],b=[];Q("Patches").M(i,p,v,b),l(v,b)}return p}K(21,i)},this.produceWithPatches=function(i,c){if(typeof i=="function")return function(p){for(var h=arguments.length,y=Array(h>1?h-1:0),m=1;m<h;m++)y[m-1]=arguments[m];return n.produceWithPatches(p,function(v){return i.apply(void 0,[v].concat(y))})};var l,d,f=n.produce(i,c,function(p,h){l=p,d=h});return typeof Promise<"u"&&f instanceof Promise?f.then(function(p){return[p,l,d]}):[f,l,d]},typeof o?.useProxies=="boolean"&&this.setUseProxies(o.useProxies),typeof o?.autoFreeze=="boolean"&&this.setAutoFreeze(o.autoFreeze)}var t=r.prototype;return t.createDraft=function(o){Y(o)||K(8),te(o)&&(o=Ha(o));var n=Eo(this),i=Xt(this,o,void 0);return i[F].C=!0,Yt(n),i},t.finishDraft=function(o,n){var i=o&&o[F],c=i.A;return jt(c,n),Kt(void 0,c)},t.setAutoFreeze=function(o){this.D=o},t.setUseProxies=function(o){o&&!Ro&&K(20),this.O=o},t.applyPatches=function(o,n){var i;for(i=n.length-1;i>=0;i--){var c=n[i];if(c.path.length===0&&c.op==="replace"){o=c.value;break}}i>-1&&(n=n.slice(i+1));var l=Q("Patches").$;return te(o)?l(o,n):this.produce(o,function(d){return l(d,n)})},r}(),j=new Ka,Va=j.produce,Uc=j.produceWithPatches.bind(j),Dc=j.setAutoFreeze.bind(j),Bc=j.setUseProxies.bind(j),Mc=j.applyPatches.bind(j),Wc=j.createDraft.bind(j),zc=j.finishDraft.bind(j),St=Va;function ue(r){"@babel/helpers - typeof";return ue=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ue(r)}function ar(r,t){if(ue(r)!=="object"||r===null)return r;var o=r[Symbol.toPrimitive];if(o!==void 0){var n=o.call(r,t||"default");if(ue(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(r)}function ir(r){var t=ar(r,"string");return ue(t)==="symbol"?t:String(t)}function cr(r,t,o){return t=ir(t),t in r?Object.defineProperty(r,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[t]=o,r}function Uo(r,t){var o=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(r,i).enumerable})),o.push.apply(o,n)}return o}function Ot(r){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?Uo(Object(o),!0).forEach(function(n){cr(r,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):Uo(Object(o)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(o,n))})}return r}function H(r){return"Minified Redux error #"+r+"; visit https://redux.js.org/Errors?code="+r+" for the full message or use the non-minified dev environment for full errors. "}var Do=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),sr=function(){return Math.random().toString(36).substring(7).split("").join(".")},Ct={INIT:"@@redux/INIT"+sr(),REPLACE:"@@redux/REPLACE"+sr(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+sr()}};function Za(r){if(typeof r!="object"||r===null)return!1;for(var t=r;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(r)===t}function lr(r,t,o){var n;if(typeof t=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(H(0));if(typeof t=="function"&&typeof o>"u"&&(o=t,t=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(H(1));return o(lr)(r,t)}if(typeof r!="function")throw new Error(H(2));var i=r,c=t,l=[],d=l,f=!1;function p(){d===l&&(d=l.slice())}function h(){if(f)throw new Error(H(3));return c}function y(S){if(typeof S!="function")throw new Error(H(4));if(f)throw new Error(H(5));var R=!0;return p(),d.push(S),function(){if(R){if(f)throw new Error(H(6));R=!1,p();var A=d.indexOf(S);d.splice(A,1),l=null}}}function m(S){if(!Za(S))throw new Error(H(7));if(typeof S.type>"u")throw new Error(H(8));if(f)throw new Error(H(9));try{f=!0,c=i(c,S)}finally{f=!1}for(var R=l=d,w=0;w<R.length;w++){var A=R[w];A()}return S}function v(S){if(typeof S!="function")throw new Error(H(10));i=S,m({type:Ct.REPLACE})}function b(){var S,R=y;return S={subscribe:function(A){if(typeof A!="object"||A===null)throw new Error(H(11));function P(){A.next&&A.next(h())}P();var T=R(P);return{unsubscribe:T}}},S[Do]=function(){return this},S}return m({type:Ct.INIT}),n={dispatch:m,subscribe:y,getState:h,replaceReducer:v},n[Do]=b,n}function qa(r){Object.keys(r).forEach(function(t){var o=r[t],n=o(void 0,{type:Ct.INIT});if(typeof n>"u")throw new Error(H(12));if(typeof o(void 0,{type:Ct.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(H(13))})}function Bo(r){for(var t=Object.keys(r),o={},n=0;n<t.length;n++){var i=t[n];typeof r[i]=="function"&&(o[i]=r[i])}var c=Object.keys(o),l,d;try{qa(o)}catch(f){d=f}return function(p,h){if(p===void 0&&(p={}),d)throw d;if(0)var y;for(var m=!1,v={},b=0;b<c.length;b++){var S=c[b],R=o[S],w=p[S],A=R(w,h);if(typeof A>"u"){var P=h&&h.type;throw new Error(H(14))}v[S]=A,m=m||A!==w}return m=m||c.length!==Object.keys(p).length,m?v:p}}function Pe(){for(var r=arguments.length,t=new Array(r),o=0;o<r;o++)t[o]=arguments[o];return t.length===0?function(n){return n}:t.length===1?t[0]:t.reduce(function(n,i){return function(){return n(i.apply(void 0,arguments))}})}function Mo(){for(var r=arguments.length,t=new Array(r),o=0;o<r;o++)t[o]=arguments[o];return function(n){return function(){var i=n.apply(void 0,arguments),c=function(){throw new Error(H(15))},l={getState:i.getState,dispatch:function(){return c.apply(void 0,arguments)}},d=t.map(function(f){return f(l)});return c=Pe.apply(void 0,d)(i.dispatch),Ot(Ot({},i),{},{dispatch:c})}}}function Wo(r){var t=function(n){var i=n.dispatch,c=n.getState;return function(l){return function(d){return typeof d=="function"?d(i,c,r):l(d)}}};return t}var zo=Wo();zo.withExtraArgument=Wo;var dr=zo;var Ko=function(){var r=function(t,o){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var c in i)Object.prototype.hasOwnProperty.call(i,c)&&(n[c]=i[c])},r(t,o)};return function(t,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");r(t,o);function n(){this.constructor=t}t.prototype=o===null?Object.create(o):(n.prototype=o.prototype,new n)}}(),Ya=function(r,t){var o={label:0,sent:function(){if(c[0]&1)throw c[1];return c[1]},trys:[],ops:[]},n,i,c,l;return l={next:d(0),throw:d(1),return:d(2)},typeof Symbol=="function"&&(l[Symbol.iterator]=function(){return this}),l;function d(p){return function(h){return f([p,h])}}function f(p){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,i&&(c=p[0]&2?i.return:p[0]?i.throw||((c=i.return)&&c.call(i),0):i.next)&&!(c=c.call(i,p[1])).done)return c;switch(i=0,c&&(p=[p[0]&2,c.value]),p[0]){case 0:case 1:c=p;break;case 4:return o.label++,{value:p[1],done:!1};case 5:o.label++,i=p[1],p=[0];continue;case 7:p=o.ops.pop(),o.trys.pop();continue;default:if(c=o.trys,!(c=c.length>0&&c[c.length-1])&&(p[0]===6||p[0]===2)){o=0;continue}if(p[0]===3&&(!c||p[1]>c[0]&&p[1]<c[3])){o.label=p[1];break}if(p[0]===6&&o.label<c[1]){o.label=c[1],c=p;break}if(c&&o.label<c[2]){o.label=c[2],o.ops.push(p);break}c[2]&&o.ops.pop(),o.trys.pop();continue}p=t.call(r,o)}catch(h){p=[6,h],i=0}finally{n=c=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Fe=function(r,t){for(var o=0,n=t.length,i=r.length;o<n;o++,i++)r[i]=t[o];return r},Xa=Object.defineProperty,Qa=Object.defineProperties,Ja=Object.getOwnPropertyDescriptors,Ho=Object.getOwnPropertySymbols,ei=Object.prototype.hasOwnProperty,ti=Object.prototype.propertyIsEnumerable,$o=function(r,t,o){return t in r?Xa(r,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):r[t]=o},pe=function(r,t){for(var o in t||(t={}))ei.call(t,o)&&$o(r,o,t[o]);if(Ho)for(var n=0,i=Ho(t);n<i.length;n++){var o=i[n];ti.call(t,o)&&$o(r,o,t[o])}return r},ur=function(r,t){return Qa(r,Ja(t))},ri=function(r,t,o){return new Promise(function(n,i){var c=function(f){try{d(o.next(f))}catch(p){i(p)}},l=function(f){try{d(o.throw(f))}catch(p){i(p)}},d=function(f){return f.done?n(f.value):Promise.resolve(f.value).then(c,l)};d((o=o.apply(r,t)).next())})};var oi=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Pe:Pe.apply(null,arguments)},as=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(r){return r}};function ni(r){if(typeof r!="object"||r===null)return!1;var t=Object.getPrototypeOf(r);if(t===null)return!0;for(var o=t;Object.getPrototypeOf(o)!==null;)o=Object.getPrototypeOf(o);return t===o}var ai=function(r){Ko(t,r);function t(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=r.apply(this,o)||this;return Object.setPrototypeOf(i,t.prototype),i}return Object.defineProperty(t,Symbol.species,{get:function(){return t},enumerable:!1,configurable:!0}),t.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return r.prototype.concat.apply(this,o)},t.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(t.bind.apply(t,Fe([void 0],o[0].concat(this)))):new(t.bind.apply(t,Fe([void 0],o.concat(this))))},t}(Array),ii=function(r){Ko(t,r);function t(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=r.apply(this,o)||this;return Object.setPrototypeOf(i,t.prototype),i}return Object.defineProperty(t,Symbol.species,{get:function(){return t},enumerable:!1,configurable:!0}),t.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return r.prototype.concat.apply(this,o)},t.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(t.bind.apply(t,Fe([void 0],o[0].concat(this)))):new(t.bind.apply(t,Fe([void 0],o.concat(this))))},t}(Array);function hr(r){return Y(r)?St(r,function(){}):r}function ci(r){return typeof r=="boolean"}function si(){return function(t){return li(t)}}function li(r){r===void 0&&(r={});var t=r.thunk,o=t===void 0?!0:t,n=r.immutableCheck,i=n===void 0?!0:n,c=r.serializableCheck,l=c===void 0?!0:c,d=new ai;if(o&&(ci(o)?d.push(dr):d.push(dr.withExtraArgument(o.extraArgument))),0){if(i)var f;if(l)var p}return d}var pr=!0;function Vo(r){var t=si(),o=r||{},n=o.reducer,i=n===void 0?void 0:n,c=o.middleware,l=c===void 0?t():c,d=o.devTools,f=d===void 0?!0:d,p=o.preloadedState,h=p===void 0?void 0:p,y=o.enhancers,m=y===void 0?void 0:y,v;if(typeof i=="function")v=i;else if(ni(i))v=Bo(i);else throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');var b=l;if(typeof b=="function"&&(b=b(t),!pr&&!Array.isArray(b)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!pr&&b.some(function(T){return typeof T!="function"}))throw new Error("each middleware provided to configureStore must be a function");var S=Mo.apply(void 0,b),R=Pe;f&&(R=oi(pe({trace:!pr},typeof f=="object"&&f)));var w=new ii(S),A=w;Array.isArray(m)?A=Fe([S],m):typeof m=="function"&&(A=m(w));var P=R.apply(void 0,A);return lr(v,h,P)}function fe(r,t){function o(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];if(t){var c=t.apply(void 0,n);if(!c)throw new Error("prepareAction did not return an object");return pe(pe({type:r,payload:c.payload},"meta"in c&&{meta:c.meta}),"error"in c&&{error:c.error})}return{type:r,payload:n[0]}}return o.toString=function(){return""+r},o.type=r,o.match=function(n){return n.type===r},o}function Zo(r){var t={},o=[],n,i={addCase:function(c,l){var d=typeof c=="string"?c:c.type;if(d in t)throw new Error("addCase cannot be called with two reducers for the same action type");return t[d]=l,i},addMatcher:function(c,l){return o.push({matcher:c,reducer:l}),i},addDefaultCase:function(c){return n=c,i}};return r(i),[t,o,n]}function di(r){return typeof r=="function"}function ui(r,t,o,n){o===void 0&&(o=[]);var i=typeof t=="function"?Zo(t):[t,o,n],c=i[0],l=i[1],d=i[2],f;if(di(r))f=function(){return hr(r())};else{var p=hr(r);f=function(){return p}}function h(y,m){y===void 0&&(y=f());var v=Fe([c[m.type]],l.filter(function(b){var S=b.matcher;return S(m)}).map(function(b){var S=b.reducer;return S}));return v.filter(function(b){return!!b}).length===0&&(v=[d]),v.reduce(function(b,S){if(S)if(te(b)){var R=b,w=S(R,m);return w===void 0?b:w}else{if(Y(b))return St(b,function(A){return S(A,m)});var w=S(b,m);if(w===void 0){if(b===null)return b;throw Error("A case reducer on a non-draftable value must not return undefined")}return w}return b},y)}return h.getInitialState=f,h}function pi(r,t){return r+"/"+t}function qo(r){var t=r.name;if(!t)throw new Error("`name` is a required option for createSlice");typeof process<"u";var o=typeof r.initialState=="function"?r.initialState:hr(r.initialState),n=r.reducers||{},i=Object.keys(n),c={},l={},d={};i.forEach(function(h){var y=n[h],m=pi(t,h),v,b;"reducer"in y?(v=y.reducer,b=y.prepare):v=y,c[h]=v,l[m]=v,d[h]=b?fe(m,b):fe(m)});function f(){var h=typeof r.extraReducers=="function"?Zo(r.extraReducers):[r.extraReducers],y=h[0],m=y===void 0?{}:y,v=h[1],b=v===void 0?[]:v,S=h[2],R=S===void 0?void 0:S,w=pe(pe({},m),l);return ui(o,function(A){for(var P in w)A.addCase(P,w[P]);for(var T=0,M=b;T<M.length;T++){var Z=M[T];A.addMatcher(Z.matcher,Z.reducer)}R&&A.addDefaultCase(R)})}var p;return{name:t,reducer:function(h,y){return p||(p=f()),p(h,y)},actions:d,caseReducers:c,getInitialState:function(){return p||(p=f()),p.getInitialState()}}}var fi="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",hi=function(r){r===void 0&&(r=21);for(var t="",o=r;o--;)t+=fi[Math.random()*64|0];return t},yi=["name","message","stack","code"],fr=function(){function r(t,o){this.payload=t,this.meta=o}return r}(),Go=function(){function r(t,o){this.payload=t,this.meta=o}return r}(),gi=function(r){if(typeof r=="object"&&r!==null){for(var t={},o=0,n=yi;o<n.length;o++){var i=n[o];typeof r[i]=="string"&&(t[i]=r[i])}return t}return{message:String(r)}},ls=function(){function r(t,o,n){var i=fe(t+"/fulfilled",function(h,y,m,v){return{payload:h,meta:ur(pe({},v||{}),{arg:m,requestId:y,requestStatus:"fulfilled"})}}),c=fe(t+"/pending",function(h,y,m){return{payload:void 0,meta:ur(pe({},m||{}),{arg:y,requestId:h,requestStatus:"pending"})}}),l=fe(t+"/rejected",function(h,y,m,v,b){return{payload:v,error:(n&&n.serializeError||gi)(h||"Rejected"),meta:ur(pe({},b||{}),{arg:m,requestId:y,rejectedWithValue:!!v,requestStatus:"rejected",aborted:h?.name==="AbortError",condition:h?.name==="ConditionError"})}}),d=!1,f=typeof AbortController<"u"?AbortController:function(){function h(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return h.prototype.abort=function(){},h}();function p(h){return function(y,m,v){var b=n?.idGenerator?n.idGenerator(h):hi(),S=new f,R,w=!1;function A(T){R=T,S.abort()}var P=function(){return ri(this,null,function(){var T,M,Z,ge,$,me,Ae;return Ya(this,function(u){switch(u.label){case 0:return u.trys.push([0,4,,5]),ge=(T=n?.condition)==null?void 0:T.call(n,h,{getState:m,extra:v}),bi(ge)?[4,ge]:[3,2];case 1:ge=u.sent(),u.label=2;case 2:if(ge===!1||S.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return w=!0,$=new Promise(function(g,C){return S.signal.addEventListener("abort",function(){return C({name:"AbortError",message:R||"Aborted"})})}),y(c(b,h,(M=n?.getPendingMeta)==null?void 0:M.call(n,{requestId:b,arg:h},{getState:m,extra:v}))),[4,Promise.race([$,Promise.resolve(o(h,{dispatch:y,getState:m,extra:v,requestId:b,signal:S.signal,abort:A,rejectWithValue:function(g,C){return new fr(g,C)},fulfillWithValue:function(g,C){return new Go(g,C)}})).then(function(g){if(g instanceof fr)throw g;return g instanceof Go?i(g.payload,b,h,g.meta):i(g,b,h)})])];case 3:return Z=u.sent(),[3,5];case 4:return me=u.sent(),Z=me instanceof fr?l(null,b,h,me.payload,me.meta):l(me,b,h),[3,5];case 5:return Ae=n&&!n.dispatchConditionRejection&&l.match(Z)&&Z.meta.condition,Ae||y(Z),[2,Z]}})})}();return Object.assign(P,{abort:A,requestId:b,arg:h,unwrap:function(){return P.then(mi)}})}}return Object.assign(p,{pending:c,rejected:l,fulfilled:i,typePrefix:t})}return r.withTypes=function(){return r},r}();function mi(r){if(r.meta&&r.meta.rejectedWithValue)throw r.payload;if(r.error)throw r.error;return r.payload}function bi(r){return r!==null&&typeof r=="object"&&typeof r.then=="function"}var Yo="listener",Xo="completed",Qo="cancelled",ds="task-"+Qo,us="task-"+Xo,ps=Yo+"-"+Qo,fs=Yo+"-"+Xo;var yr="listenerMiddleware";var hs=fe(yr+"/add"),ys=fe(yr+"/removeAll"),gs=fe(yr+"/remove");var jo,ms=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(r){return(jo||(jo=Promise.resolve())).then(r).catch(function(t){return setTimeout(function(){throw t},0)})},xi=function(r){return function(t){setTimeout(t,r)}},bs=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:xi(10);Fo();function vi(r,t){return class extends r{constructor(){super(...arguments),this.eventBus=t??document.createElement("span")}addEventListener(o,n,i){this.eventBus.addEventListener(o,n,i)}dispatchEvent(o){return this.eventBus.dispatchEvent(o)}removeEventListener(o,n,i){this.eventBus.removeEventListener(o,n,i)}}}var Et=class extends vi(Object){};window.ftReduxStores||(window.ftReduxStores={});var Jo=class r extends Et{static get(t){var o;let n=typeof t=="string"?t:t.name,i=typeof t=="string"?void 0:t,c=window.ftReduxStores[n];if(Ze(c))return c;if(i==null)return;let l=qo({...i,reducers:(o=i.reducers)!==null&&o!==void 0?o:{}}),d=Vo({reducer:(f,p)=>p.type==="CLEAR_FT_REDUX_STORE"?l.getInitialState():typeof p.type=="string"&&p.type.startsWith("DEFAULT_VALUE_SETTER__")?{...f,...p.overwrites}:l.reducer(f,p)});return window.ftReduxStores[i.name]=new r(l,d)}constructor(t,o){super(),this.reduxSlice=t,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new ft;let n=i=>i!=null?JSON.parse(JSON.stringify(i)):i;this.actions=new Proxy(this.reduxSlice.actions,{get:(i,c,l)=>{let d=c,f=i[d];return f?(...p)=>{let h=f(...p.map(n));return this.reduxStore.dispatch(h),h}:p=>{this.setState({[d]:n(p)})}}})}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE"})}setState(t){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(t).join("_"),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()}};var It=N(B());var wt=class extends ee{async listMySearches(){let t=E.getState().session;return t?.sessionAuthenticated?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(t.profile.userId),5*60*1e3):[]}};var At=class extends ee{async listMyBookmarks(){let t=E.getState().session;return t?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(t.profile.userId),5*60*1e3):[]}};var Oi="ft-user-assets",Nt=It.FtReduxStore.get({name:Oi,initialState:{savedSearches:void 0,bookmarks:void 0}}),gr=class{constructor(){this.currentSession=E.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new At,this.savedSearchesService=new wt,E.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var t;let{session:o}=E.getState();(0,It.deepEqual)((t=this.currentSession)===null||t===void 0?void 0:t.profile,o?.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),Nt.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),Nt.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let t=await this.savedSearchesService.listMySearches();Nt.actions.savedSearches(t)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){let o=!((t=this.currentSession)===null||t===void 0)&&t.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;Nt.actions.bookmarks(o)}}},Js=new gr;var mr=class{addCommand(t,o=!1){E.commands.add(t,o)}consumeCommand(t){return E.commands.consume(t)}};window.FluidTopicsAppInfoStoreService=new mr;var en=N(B()),br=class{highlightHtml(t,o,n){(0,en.highlightHtml)(t,o,n)}};window.FluidTopicsHighlightHtmlService=new br;var tn=N(B());var xr=class{isDate(t){var o,n,i,c;return(c=(i=((n=(o=E.getState().metadataConfiguration)===null||o===void 0?void 0:o.descriptors)!==null&&n!==void 0?n:[]).find(d=>d.key===t))===null||i===void 0?void 0:i.date)!==null&&c!==void 0?c:!1}format(t,o){var n,i,c;return tn.DateFormatter.format(t,(n=o?.locale)!==null&&n!==void 0?n:E.getState().uiLocale,(i=o?.longFormat)!==null&&i!==void 0?i:!1,(c=o?.withTime)!==null&&c!==void 0?c:!1)}};window.FluidTopicsDateService=new xr;var Ci=N(B());(0,rn.customElement)("ft-app-context")(_);var vr=class r extends Event{constructor(){super(r.eventName)}};vr.eventName="search-context-clear-all-filters";var Ei=function(r,t,o,n){var i=arguments.length,c=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")c=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(l=r[d])&&(c=(i<3?l(c):i>3?l(t,o,c):l(t,o))||c);return i>3&&c&&Object.defineProperty(t,o,c),c},Or=class extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}},Sr=Symbol("registerInterval");function wi(r){var t;class o extends r{constructor(){super(...arguments),this[t]=0}setSearchStateManager(i){this.clearStateManager(),this.stateManager=i,this.addStore(i.store,"search")}clearStateManager(){this.stateManager&&(this.removeStore(this.stateManager.store),this.stateManager=void 0)}connectedCallback(){super.connectedCallback(),this[Sr]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null?window.clearInterval(this[Sr]):this.dispatchEvent(new Or)}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return t=Sr,Ei([(0,nn.state)()],o.prototype,"stateManager",void 0),o}var Tt=class extends wi(on.FtLitElementRedux){};var Lt=N(X()),Cr=function(r,t,o,n){var i=arguments.length,c=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")c=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(l=r[d])&&(c=(i<3?l(c):i>3?l(t,o,c):l(t,o))||c);return i>3&&c&&Object.defineProperty(t,o,c),c},wr=class extends Event{constructor(){super("register-ft-search-result-component",{bubbles:!0,composed:!0})}},Er=Symbol("registerInterval");function Ai(r){var t;class o extends r{constructor(){super(...arguments),this[t]=0}setResultStateManager(i){this.resultStateManager=i}unregisterResultStateManager(){this.resultStateManager&&(this.resultStateManager.unregisterComponent(this),this.resultStateManager=void 0)}connectedCallback(){super.connectedCallback(),this[Er]=window.setInterval(()=>this.tryToRegisterToResultContext(),50)}tryToRegisterToResultContext(){this.result!=null?window.clearInterval(this[Er]):this.dispatchEvent(new wr)}disconnectedCallback(){super.disconnectedCallback(),this.unregisterResultStateManager()}}return t=Er,Cr([(0,Lt.property)({attribute:!1})],o.prototype,"cluster",void 0),Cr([(0,Lt.property)({attribute:!1})],o.prototype,"result",void 0),Cr([(0,Lt.property)({attribute:!1,type:Number})],o.prototype,"rank",void 0),o}var Pt=class extends Ai(Tt){};var an=N(J()),cn=N(B()),Ni={highlightBackgroundColor:cn.FtCssVariableFactory.create("--ft-srt-highlight-background-color","","COLOR","transparent")},sn=an.css`
|
|
5
|
+
`}update(t){var o,n,i,c,l;super.update(t),t.has("baseUrl")&&(E.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),t.has("apiIntegrationIdentifier")&&E.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&E.actions.uiLocale(this.uiLocale),t.has("metadataConfiguration")&&E.actions.metadataConfiguration(this.metadataConfiguration),t.has("noCustom")&&E.actions.noCustom(this.noCustom),t.has("editorMode")&&E.actions.editorMode(this.editorMode),t.has("noCustomComponent")&&E.actions.noCustomComponent(this.noCustomComponent),t.has("session")&&E.actions.session(this.session),t.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(d=>lo.addContext(d)),t.has("openExternalDocumentInNewTab")&&E.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),t.has("navigatorOnline")&&E.actions.navigatorOnline(this.navigatorOnline),t.has("forcedOffline")&&E.actions.forcedOffline(this.forcedOffline),t.has("localesConfiguration")&&(E.actions.defaultLocales((o=this.localesConfiguration)===null||o===void 0?void 0:o.defaultLocales),E.actions.availableUiLocales((i=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&i!==void 0?i:[]),E.actions.searchInAllLanguagesAllowed((l=(c=this.localesConfiguration)===null||c===void 0?void 0:c.allLanguagesAllowed)!==null&&l!==void 0?l:!1)),setTimeout(()=>this.updateIfNeeded())}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.session==null&&this.updateSession(),this.metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration())}async updateSession(){this.session=await this.cache.get("session",async()=>{let t=await this.apiProvider().getCurrentSession();return t.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.session=void 0},t.idleTimeoutInMillis),t})}async updateMetadataConfiguration(){this.metadataConfiguration=await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration())}async updateLocalesConfiguration(){this.localesConfiguration=await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration())}};_.elementDefinitions={};_.styles=co;z([(0,G.property)()],_.prototype,"baseUrl",void 0);z([(0,G.property)()],_.prototype,"apiIntegrationIdentifier",void 0);z([(0,G.property)()],_.prototype,"uiLocale",void 0);z([(0,q.jsonProperty)(null)],_.prototype,"availableUiLocales",void 0);z([(0,q.jsonProperty)(null)],_.prototype,"metadataConfiguration",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"editorMode",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"noCustom",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"openExternalDocumentInNewTab",void 0);z([(0,G.property)({converter:{fromAttribute(r){return r==="false"?!1:r==="true"||(r??!1)}}})],_.prototype,"noCustomComponent",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"withManualResources",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"navigatorOnline",void 0);z([(0,G.property)({type:Boolean})],_.prototype,"forcedOffline",void 0);z([(0,G.property)({type:Object})],_.prototype,"apiProvider",void 0);z([(0,q.jsonProperty)([])],_.prototype,"messageContexts",void 0);z([(0,q.jsonProperty)(void 0)],_.prototype,"session",void 0);z([(0,G.state)()],_.prototype,"localesConfiguration",void 0);var Si=N(X());function _a(r,t){if(r===t)return!0;if(r&&t&&typeof r=="object"&&typeof t=="object"){if(r.constructor!==t.constructor)return!1;var o,n,i;if(Array.isArray(r)){if(o=r.length,o!=t.length)return!1;for(n=o;n--!==0;)if(!ut(r[n],t[n]))return!1;return!0}if(r instanceof Map&&t instanceof Map){if(r.size!==t.size)return!1;for(n of r.entries())if(!t.has(n[0]))return!1;for(n of r.entries())if(!ut(n[1],t.get(n[0])))return!1;return!0}if(r instanceof Set&&t instanceof Set){if(r.size!==t.size)return!1;for(n of r.entries())if(!t.has(n[0]))return!1;return!0}if(r.constructor===RegExp)return r.source===t.source&&r.flags===t.flags;if(r.valueOf!==Object.prototype.valueOf)return r.valueOf()===t.valueOf();let c=l=>Object.keys(l).filter(d=>l[d]!=null);if(i=c(r),o=i.length,o!==c(t).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[n]))return!1;for(n=o;n--!==0;){let l=i[n];if(!ut(r[l],t[l]))return!1}return!0}return r!==r&&t!==t||r==null&&t==null}function ut(r,t){try{return _a(r,t)}catch{return!1}}function pt(r,t){return!ut(r,t)}var Ua=N(X(),1);var ft=class{constructor(){this.queue=[]}add(t,o=!1){o&&(this.queue=this.queue.filter(n=>n.type!==t.type)),this.queue.push(t)}consume(t){let o=this.queue.find(n=>n.type===t);return o&&(this.queue=this.queue.filter(n=>n!==o)),o}};var Ve=N(X(),1);var po=N(X(),1);function fo(r,t){let o=()=>JSON.parse(JSON.stringify(r));return(0,po.property)({type:Object,converter:{fromAttribute:n=>{if(n==null)return o();try{return JSON.parse(n)}catch{return o()}},toAttribute:n=>JSON.stringify(n)},hasChanged:pt,...t??{}})}var ht=class{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 this.promise==null&&(this.promise=new Promise((o,n)=>{this.resolvePromise=o,this.rejectPromise=n})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),t??this.timeout),this.promise}async runCallbacks(){var t,o;let n=[...this.callbacks];this.callbacks=[];let i=(t=this.rejectPromise)!==null&&t!==void 0?t:()=>null,c=(o=this.resolvePromise)!==null&&o!==void 0?o:()=>null;this.clearPromise();for(let l of n)try{await l()}catch(d){i(d);return}c(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var yo=N(J(),1);var yt=window,Da=yt.ShadowRoot&&(yt.ShadyCSS===void 0||yt.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Ec=Symbol();var ho=(r,t)=>{Da?r.adoptedStyleSheets=t.map(o=>o instanceof CSSStyleSheet?o:o.styleSheet):t.forEach(o=>{let n=document.createElement("style"),i=yt.litNonce;i!==void 0&&n.setAttribute("nonce",i),n.textContent=o.cssText,r.appendChild(n)})};var gt=class extends yo.LitElement{createRenderRoot(){let t=this.constructor;t.elementDefinitions&&!t.registry&&(t.registry=new CustomElementRegistry,Object.entries(t.elementDefinitions).forEach(([i,c])=>t.registry.define(i,c)));let o={...t.shadowRootOptions,customElements:t.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return ho(n,t.elementStyles),n}};var mt=function(r,t,o,n){var i=arguments.length,c=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")c=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(l=r[d])&&(c=(i<3?l(c):i>3?l(t,o,c):l(t,o))||c);return i>3&&c&&Object.defineProperty(t,o,c),c},xo,go=Symbol("constructorPrototype"),mo=Symbol("constructorName"),vo=Symbol("exportpartsDebouncer"),bo=Symbol("dynamicDependenciesLoaded"),ce=class extends gt{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[xo]=new ht(5),this[mo]=this.constructor.name,this[go]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[mo]&&Object.setPrototypeOf(this,this[go])}connectedCallback(){super.connectedCallback();try{this.shadowRoot&&!this.shadowRoot.adoptedStyleSheets.includes(this.adoptedCustomStyleSheet)&&(this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,this.adoptedCustomStyleSheet]),this.useAdoptedStyleSheets=!0}catch(o){this.useAdoptedStyleSheets=!1,console.error("Cannot use adopted stylesheets",o)}let t=this.constructor;t[bo]||(t[bo]=!0,this.importDynamicDependencies())}importDynamicDependencies(){}updated(t){super.updated(t),this.updateComplete.then(()=>{this.contentAvailableCallback(t),this.applyCustomStylesheet(t),this.scheduleExportpartsUpdate()})}contentAvailableCallback(t){}applyCustomStylesheet(t){var o,n,i;if(((n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))!==null&&n!==void 0?n:[]).forEach(c=>c.remove()),this.useAdoptedStyleSheets){if(t.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((i=this.customStylesheet)!==null&&i!==void 0?i:"")}catch(c){console.error(c,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let c=document.createElement("style");c.classList.add("ft-lit-element--custom-stylesheet"),c.innerHTML=this.customStylesheet,this.shadowRoot.append(c)}}scheduleExportpartsUpdate(){var t,o,n;(!((t=this.exportpartsPrefix)===null||t===void 0)&&t.trim()||(n=(o=this.exportpartsPrefixes)===null||o===void 0?void 0:o.length)!==null&&n!==void 0&&n)&&this[vo].run(()=>{var i,c;!((i=this.exportpartsPrefix)===null||i===void 0)&&i.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((c=this.exportpartsPrefixes)===null||c===void 0?void 0:c.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})}setExportpartsAttribute(t){var o,n,i,c,l,d;let f=m=>m!=null&&m.trim().length>0,p=t.filter(f).map(m=>m.trim());if(p.length===0){this.removeAttribute("exportparts");return}let h=new Set;for(let m of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let v=(c=(i=m.getAttribute("part"))===null||i===void 0?void 0:i.split(" "))!==null&&c!==void 0?c:[],b=(d=(l=m.getAttribute("exportparts"))===null||l===void 0?void 0:l.split(",").map(S=>S.split(":")[1]))!==null&&d!==void 0?d:[];new Array(...v,...b).filter(f).map(S=>S.trim()).forEach(S=>h.add(S))}if(h.size===0){this.removeAttribute("exportparts");return}let y=[...h.values()].flatMap(m=>p.map(v=>`${m}:${v}--${m}`));this.setAttribute("exportparts",[...this.part,...y].join(", "))}};xo=vo;mt([(0,Ve.property)()],ce.prototype,"exportpartsPrefix",void 0);mt([fo([])],ce.prototype,"exportpartsPrefixes",void 0);mt([(0,Ve.property)()],ce.prototype,"customStylesheet",void 0);mt([(0,Ve.state)()],ce.prototype,"useAdoptedStyleSheets",void 0);function Ze(r){var t;return(t=r?.isFtReduxStore)!==null&&t!==void 0?t:!1}var So,Oo,Co,qe=Symbol("internalReduxEventsUnsubscribers"),se=Symbol("internalStoresUnsubscribers"),ve=Symbol("internalStores"),Ye=class extends ce{constructor(){super(...arguments),this[So]=new Map,this[Oo]=new Map,this[Co]=new Map}get reduxConstructor(){return this.constructor}update(t){super.update(t),[...this.reduxConstructor.reduxReactiveProperties].some(o=>t.has(o))&&this.updateFromStores()}getUnnamedStore(){if(this[ve].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[ve].values()][0]}getStore(t){return t==null?this.getUnnamedStore():this[ve].get(t)}addStore(t,o){var n;o=(n=o??(Ze(t)?t.name:void 0))!==null&&n!==void 0?n:"default-store",this.unsubscribeFromStore(o),this[ve].set(o,t),this.subscribeToStore(o,t),this.updateFromStores()}removeStore(t){let o=typeof t=="string"?t:t.name;this.unsubscribeFromStore(o),this[ve].delete(o)}setupStores(){this.unsubscribeFromStores(),this[ve].forEach((t,o)=>this.subscribeToStore(o,t)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((t,o)=>{let n=this.constructor.getPropertyOptions(o);if(!n?.attribute||!this.hasAttribute(typeof n?.attribute=="string"?n.attribute:o)){let i=this.getStore(t.store);i&&(t.store?this[se].has(t.store):this[se].size>0)&&(this[o]=t.selector(i.getState(),this))}})}subscribeToStore(t,o){var n;this[se].set(t,o.subscribe(()=>this.updateFromStores())),this[qe].set(t,[]),Ze(o)&&o.eventBus&&((n=this.reduxConstructor.reduxEventListeners)===null||n===void 0||n.forEach((i,c)=>{if(typeof this[c]=="function"&&(!i.store||o.name===i.store)){let l=d=>this[c](d);o.addEventListener(i.eventName,l),this[qe].get(t).push(()=>o.removeEventListener(i.eventName,l))}})),this.onStoreAvailable(t)}unsubscribeFromStores(){this[se].forEach((t,o)=>this.unsubscribeFromStore(o))}unsubscribeFromStore(t){var o;this[se].has(t)&&this[se].get(t)(),this[se].delete(t),(o=this[qe].get(t))===null||o===void 0||o.forEach(n=>n()),this[qe].delete(t)}onStoreAvailable(t){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}};So=se,Oo=ve,Co=qe;Ye.reduxProperties=new Map;Ye.reduxReactiveProperties=new Set;Ye.reduxEventListeners=new Map;function K(r){for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;n<t;n++)o[n-1]=arguments[n];if(0)var i,c;throw Error("[Immer] minified error nr: "+r+(o.length?" "+o.map(function(l){return"'"+l+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function te(r){return!!r&&!!r[F]}function Y(r){var t;return!!r&&(function(o){if(!o||typeof o!="object")return!1;var n=Object.getPrototypeOf(o);if(n===null)return!0;var i=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return i===Object||typeof i=="function"&&Function.toString.call(i)===ja}(r)||Array.isArray(r)||!!r[To]||!!(!((t=r.constructor)===null||t===void 0)&&t[To])||Jt(r)||er(r))}function Se(r,t,o){o===void 0&&(o=!1),Le(r)===0?(o?Object.keys:Te)(r).forEach(function(n){o&&typeof n=="symbol"||t(n,r[n],r)}):r.forEach(function(n,i){return t(i,n,r)})}function Le(r){var t=r[F];return t?t.i>3?t.i-4:t.i:Array.isArray(r)?1:Jt(r)?2:er(r)?3:0}function Re(r,t){return Le(r)===2?r.has(t):Object.prototype.hasOwnProperty.call(r,t)}function Ba(r,t){return Le(r)===2?r.get(t):r[t]}function Lo(r,t,o){var n=Le(r);n===2?r.set(t,o):n===3?r.add(o):r[t]=o}function Po(r,t){return r===t?r!==0||1/r==1/t:r!=r&&t!=t}function Jt(r){return $a&&r instanceof Map}function er(r){return Ga&&r instanceof Set}function le(r){return r.o||r.t}function tr(r){if(Array.isArray(r))return Array.prototype.slice.call(r);var t=_o(r);delete t[F];for(var o=Te(t),n=0;n<o.length;n++){var i=o[n],c=t[i];c.writable===!1&&(c.writable=!0,c.configurable=!0),(c.get||c.set)&&(t[i]={configurable:!0,writable:!0,enumerable:c.enumerable,value:r[i]})}return Object.create(Object.getPrototypeOf(r),t)}function rr(r,t){return t===void 0&&(t=!1),or(r)||te(r)||!Y(r)||(Le(r)>1&&(r.set=r.add=r.clear=r.delete=Ma),Object.freeze(r),t&&Se(r,function(o,n){return rr(n,!0)},!0)),r}function Ma(){K(2)}function or(r){return r==null||typeof r!="object"||Object.isFrozen(r)}function Q(r){var t=Qt[r];return t||K(18,r),t}function Wa(r,t){Qt[r]||(Qt[r]=t)}function qt(){return Qe}function jt(r,t){t&&(Q("Patches"),r.u=[],r.s=[],r.v=t)}function bt(r){Yt(r),r.p.forEach(za),r.p=null}function Yt(r){r===Qe&&(Qe=r.l)}function Eo(r){return Qe={p:[],l:Qe,h:r,m:!0,_:0}}function za(r){var t=r[F];t.i===0||t.i===1?t.j():t.g=!0}function Kt(r,t){t._=t.p.length;var o=t.p[0],n=r!==void 0&&r!==o;return t.h.O||Q("ES5").S(t,r,n),n?(o[F].P&&(bt(t),K(4)),Y(r)&&(r=xt(t,r),t.l||vt(t,r)),t.u&&Q("Patches").M(o[F].t,r,t.u,t.s)):r=xt(t,o,[]),bt(t),t.u&&t.v(t.u,t.s),r!==ko?r:void 0}function xt(r,t,o){if(or(t))return t;var n=t[F];if(!n)return Se(t,function(d,f){return wo(r,n,t,d,f,o)},!0),t;if(n.A!==r)return t;if(!n.P)return vt(r,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=n.i===4||n.i===5?n.o=tr(n.k):n.o,c=i,l=!1;n.i===3&&(c=new Set(i),i.clear(),l=!0),Se(c,function(d,f){return wo(r,n,i,d,f,o,l)}),vt(r,i,!1),o&&r.u&&Q("Patches").N(n,o,r.u,r.s)}return n.o}function wo(r,t,o,n,i,c,l){if(te(i)){var d=xt(r,i,c&&t&&t.i!==3&&!Re(t.R,n)?c.concat(n):void 0);if(Lo(o,n,d),!te(d))return;r.m=!1}else l&&o.add(i);if(Y(i)&&!or(i)){if(!r.h.D&&r._<1)return;xt(r,i),t&&t.A.l||vt(r,i)}}function vt(r,t,o){o===void 0&&(o=!1),!r.l&&r.h.D&&r.m&&rr(t,o)}function Vt(r,t){var o=r[F];return(o?le(o):r)[t]}function Ao(r,t){if(t in r)for(var o=Object.getPrototypeOf(r);o;){var n=Object.getOwnPropertyDescriptor(o,t);if(n)return n;o=Object.getPrototypeOf(o)}}function de(r){r.P||(r.P=!0,r.l&&de(r.l))}function Zt(r){r.o||(r.o=tr(r.t))}function Xt(r,t,o){var n=Jt(t)?Q("MapSet").F(t,o):er(t)?Q("MapSet").T(t,o):r.O?function(i,c){var l=Array.isArray(i),d={i:l?1:0,A:c?c.A:qt(),P:!1,I:!1,R:{},l:c,t:i,k:null,o:null,j:null,C:!1},f=d,p=Je;l&&(f=[d],p=Xe);var h=Proxy.revocable(f,p),y=h.revoke,m=h.proxy;return d.k=m,d.j=y,m}(t,o):Q("ES5").J(t,o);return(o?o.A:qt()).p.push(n),n}function Ha(r){return te(r)||K(22,r),function t(o){if(!Y(o))return o;var n,i=o[F],c=Le(o);if(i){if(!i.P&&(i.i<4||!Q("ES5").K(i)))return i.t;i.I=!0,n=No(o,c),i.I=!1}else n=No(o,c);return Se(n,function(l,d){i&&Ba(i.t,l)===d||Lo(n,l,t(d))}),c===3?new Set(n):n}(r)}function No(r,t){switch(t){case 2:return new Map(r);case 3:return Array.from(r)}return tr(r)}function Fo(){function r(l,d){var f=c[l];return f?f.enumerable=d:c[l]=f={configurable:!0,enumerable:d,get:function(){var p=this[F];return Je.get(p,l)},set:function(p){var h=this[F];Je.set(h,l,p)}},f}function t(l){for(var d=l.length-1;d>=0;d--){var f=l[d][F];if(!f.P)switch(f.i){case 5:n(f)&&de(f);break;case 4:o(f)&&de(f)}}}function o(l){for(var d=l.t,f=l.k,p=Te(f),h=p.length-1;h>=0;h--){var y=p[h];if(y!==F){var m=d[y];if(m===void 0&&!Re(d,y))return!0;var v=f[y],b=v&&v[F];if(b?b.t!==m:!Po(v,m))return!0}}var S=!!d[F];return p.length!==Te(d).length+(S?0:1)}function n(l){var d=l.k;if(d.length!==l.t.length)return!0;var f=Object.getOwnPropertyDescriptor(d,d.length-1);if(f&&!f.get)return!0;for(var p=0;p<d.length;p++)if(!d.hasOwnProperty(p))return!0;return!1}function i(l){l.g&&K(3,JSON.stringify(le(l)))}var c={};Wa("ES5",{J:function(l,d){var f=Array.isArray(l),p=function(y,m){if(y){for(var v=Array(m.length),b=0;b<m.length;b++)Object.defineProperty(v,""+b,r(b,!0));return v}var S=_o(m);delete S[F];for(var R=Te(S),w=0;w<R.length;w++){var A=R[w];S[A]=r(A,y||!!S[A].enumerable)}return Object.create(Object.getPrototypeOf(m),S)}(f,l),h={i:f?5:4,A:d?d.A:qt(),P:!1,I:!1,R:{},l:d,t:l,k:p,o:null,g:!1,C:!1};return Object.defineProperty(p,F,{value:h,writable:!0}),p},S:function(l,d,f){f?te(d)&&d[F].A===l&&t(l.p):(l.u&&function p(h){if(h&&typeof h=="object"){var y=h[F];if(y){var m=y.t,v=y.k,b=y.R,S=y.i;if(S===4)Se(v,function(T){T!==F&&(m[T]!==void 0||Re(m,T)?b[T]||p(v[T]):(b[T]=!0,de(y)))}),Se(m,function(T){v[T]!==void 0||Re(v,T)||(b[T]=!1,de(y))});else if(S===5){if(n(y)&&(de(y),b.length=!0),v.length<m.length)for(var R=v.length;R<m.length;R++)b[R]=!1;else for(var w=m.length;w<v.length;w++)b[w]=!0;for(var A=Math.min(v.length,m.length),P=0;P<A;P++)v.hasOwnProperty(P)||(b[P]=!0),b[P]===void 0&&p(v[P])}}}}(l.p[0]),t(l.p))},K:function(l){return l.i===4?o(l):n(l)}})}var Io,Qe,nr=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",$a=typeof Map<"u",Ga=typeof Set<"u",Ro=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",ko=nr?Symbol.for("immer-nothing"):((Io={})["immer-nothing"]=!0,Io),To=nr?Symbol.for("immer-draftable"):"__$immer_draftable",F=nr?Symbol.for("immer-state"):"__$immer_state";var ja=""+Object.prototype.constructor,Te=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(r){return Object.getOwnPropertyNames(r).concat(Object.getOwnPropertySymbols(r))}:Object.getOwnPropertyNames,_o=Object.getOwnPropertyDescriptors||function(r){var t={};return Te(r).forEach(function(o){t[o]=Object.getOwnPropertyDescriptor(r,o)}),t},Qt={},Je={get:function(r,t){if(t===F)return r;var o=le(r);if(!Re(o,t))return function(i,c,l){var d,f=Ao(c,l);return f?"value"in f?f.value:(d=f.get)===null||d===void 0?void 0:d.call(i.k):void 0}(r,o,t);var n=o[t];return r.I||!Y(n)?n:n===Vt(r.t,t)?(Zt(r),r.o[t]=Xt(r.A.h,n,r)):n},has:function(r,t){return t in le(r)},ownKeys:function(r){return Reflect.ownKeys(le(r))},set:function(r,t,o){var n=Ao(le(r),t);if(n?.set)return n.set.call(r.k,o),!0;if(!r.P){var i=Vt(le(r),t),c=i?.[F];if(c&&c.t===o)return r.o[t]=o,r.R[t]=!1,!0;if(Po(o,i)&&(o!==void 0||Re(r.t,t)))return!0;Zt(r),de(r)}return r.o[t]===o&&(o!==void 0||t in r.o)||Number.isNaN(o)&&Number.isNaN(r.o[t])||(r.o[t]=o,r.R[t]=!0),!0},deleteProperty:function(r,t){return Vt(r.t,t)!==void 0||t in r.t?(r.R[t]=!1,Zt(r),de(r)):delete r.R[t],r.o&&delete r.o[t],!0},getOwnPropertyDescriptor:function(r,t){var o=le(r),n=Reflect.getOwnPropertyDescriptor(o,t);return n&&{writable:!0,configurable:r.i!==1||t!=="length",enumerable:n.enumerable,value:o[t]}},defineProperty:function(){K(11)},getPrototypeOf:function(r){return Object.getPrototypeOf(r.t)},setPrototypeOf:function(){K(12)}},Xe={};Se(Je,function(r,t){Xe[r]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),Xe.deleteProperty=function(r,t){return Xe.set.call(this,r,t,void 0)},Xe.set=function(r,t,o){return Je.set.call(this,r[0],t,o,r[0])};var Ka=function(){function r(o){var n=this;this.O=Ro,this.D=!0,this.produce=function(i,c,l){if(typeof i=="function"&&typeof c!="function"){var d=c;c=i;var f=n;return function(S){var R=this;S===void 0&&(S=d);for(var w=arguments.length,A=Array(w>1?w-1:0),P=1;P<w;P++)A[P-1]=arguments[P];return f.produce(S,function(T){var M;return(M=c).call.apply(M,[R,T].concat(A))})}}var p;if(typeof c!="function"&&K(6),l!==void 0&&typeof l!="function"&&K(7),Y(i)){var h=Eo(n),y=Xt(n,i,void 0),m=!0;try{p=c(y),m=!1}finally{m?bt(h):Yt(h)}return typeof Promise<"u"&&p instanceof Promise?p.then(function(S){return jt(h,l),Kt(S,h)},function(S){throw bt(h),S}):(jt(h,l),Kt(p,h))}if(!i||typeof i!="object"){if((p=c(i))===void 0&&(p=i),p===ko&&(p=void 0),n.D&&rr(p,!0),l){var v=[],b=[];Q("Patches").M(i,p,v,b),l(v,b)}return p}K(21,i)},this.produceWithPatches=function(i,c){if(typeof i=="function")return function(p){for(var h=arguments.length,y=Array(h>1?h-1:0),m=1;m<h;m++)y[m-1]=arguments[m];return n.produceWithPatches(p,function(v){return i.apply(void 0,[v].concat(y))})};var l,d,f=n.produce(i,c,function(p,h){l=p,d=h});return typeof Promise<"u"&&f instanceof Promise?f.then(function(p){return[p,l,d]}):[f,l,d]},typeof o?.useProxies=="boolean"&&this.setUseProxies(o.useProxies),typeof o?.autoFreeze=="boolean"&&this.setAutoFreeze(o.autoFreeze)}var t=r.prototype;return t.createDraft=function(o){Y(o)||K(8),te(o)&&(o=Ha(o));var n=Eo(this),i=Xt(this,o,void 0);return i[F].C=!0,Yt(n),i},t.finishDraft=function(o,n){var i=o&&o[F],c=i.A;return jt(c,n),Kt(void 0,c)},t.setAutoFreeze=function(o){this.D=o},t.setUseProxies=function(o){o&&!Ro&&K(20),this.O=o},t.applyPatches=function(o,n){var i;for(i=n.length-1;i>=0;i--){var c=n[i];if(c.path.length===0&&c.op==="replace"){o=c.value;break}}i>-1&&(n=n.slice(i+1));var l=Q("Patches").$;return te(o)?l(o,n):this.produce(o,function(d){return l(d,n)})},r}(),j=new Ka,Va=j.produce,Uc=j.produceWithPatches.bind(j),Dc=j.setAutoFreeze.bind(j),Bc=j.setUseProxies.bind(j),Mc=j.applyPatches.bind(j),Wc=j.createDraft.bind(j),zc=j.finishDraft.bind(j),St=Va;function ue(r){"@babel/helpers - typeof";return ue=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ue(r)}function ar(r,t){if(ue(r)!=="object"||r===null)return r;var o=r[Symbol.toPrimitive];if(o!==void 0){var n=o.call(r,t||"default");if(ue(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(r)}function ir(r){var t=ar(r,"string");return ue(t)==="symbol"?t:String(t)}function cr(r,t,o){return t=ir(t),t in r?Object.defineProperty(r,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[t]=o,r}function Uo(r,t){var o=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(r,i).enumerable})),o.push.apply(o,n)}return o}function Ot(r){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?Uo(Object(o),!0).forEach(function(n){cr(r,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):Uo(Object(o)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(o,n))})}return r}function H(r){return"Minified Redux error #"+r+"; visit https://redux.js.org/Errors?code="+r+" for the full message or use the non-minified dev environment for full errors. "}var Do=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),sr=function(){return Math.random().toString(36).substring(7).split("").join(".")},Ct={INIT:"@@redux/INIT"+sr(),REPLACE:"@@redux/REPLACE"+sr(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+sr()}};function Za(r){if(typeof r!="object"||r===null)return!1;for(var t=r;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(r)===t}function lr(r,t,o){var n;if(typeof t=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(H(0));if(typeof t=="function"&&typeof o>"u"&&(o=t,t=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(H(1));return o(lr)(r,t)}if(typeof r!="function")throw new Error(H(2));var i=r,c=t,l=[],d=l,f=!1;function p(){d===l&&(d=l.slice())}function h(){if(f)throw new Error(H(3));return c}function y(S){if(typeof S!="function")throw new Error(H(4));if(f)throw new Error(H(5));var R=!0;return p(),d.push(S),function(){if(R){if(f)throw new Error(H(6));R=!1,p();var A=d.indexOf(S);d.splice(A,1),l=null}}}function m(S){if(!Za(S))throw new Error(H(7));if(typeof S.type>"u")throw new Error(H(8));if(f)throw new Error(H(9));try{f=!0,c=i(c,S)}finally{f=!1}for(var R=l=d,w=0;w<R.length;w++){var A=R[w];A()}return S}function v(S){if(typeof S!="function")throw new Error(H(10));i=S,m({type:Ct.REPLACE})}function b(){var S,R=y;return S={subscribe:function(A){if(typeof A!="object"||A===null)throw new Error(H(11));function P(){A.next&&A.next(h())}P();var T=R(P);return{unsubscribe:T}}},S[Do]=function(){return this},S}return m({type:Ct.INIT}),n={dispatch:m,subscribe:y,getState:h,replaceReducer:v},n[Do]=b,n}function qa(r){Object.keys(r).forEach(function(t){var o=r[t],n=o(void 0,{type:Ct.INIT});if(typeof n>"u")throw new Error(H(12));if(typeof o(void 0,{type:Ct.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(H(13))})}function Bo(r){for(var t=Object.keys(r),o={},n=0;n<t.length;n++){var i=t[n];typeof r[i]=="function"&&(o[i]=r[i])}var c=Object.keys(o),l,d;try{qa(o)}catch(f){d=f}return function(p,h){if(p===void 0&&(p={}),d)throw d;if(0)var y;for(var m=!1,v={},b=0;b<c.length;b++){var S=c[b],R=o[S],w=p[S],A=R(w,h);if(typeof A>"u"){var P=h&&h.type;throw new Error(H(14))}v[S]=A,m=m||A!==w}return m=m||c.length!==Object.keys(p).length,m?v:p}}function Pe(){for(var r=arguments.length,t=new Array(r),o=0;o<r;o++)t[o]=arguments[o];return t.length===0?function(n){return n}:t.length===1?t[0]:t.reduce(function(n,i){return function(){return n(i.apply(void 0,arguments))}})}function Mo(){for(var r=arguments.length,t=new Array(r),o=0;o<r;o++)t[o]=arguments[o];return function(n){return function(){var i=n.apply(void 0,arguments),c=function(){throw new Error(H(15))},l={getState:i.getState,dispatch:function(){return c.apply(void 0,arguments)}},d=t.map(function(f){return f(l)});return c=Pe.apply(void 0,d)(i.dispatch),Ot(Ot({},i),{},{dispatch:c})}}}function Wo(r){var t=function(n){var i=n.dispatch,c=n.getState;return function(l){return function(d){return typeof d=="function"?d(i,c,r):l(d)}}};return t}var zo=Wo();zo.withExtraArgument=Wo;var dr=zo;var Ko=function(){var r=function(t,o){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var c in i)Object.prototype.hasOwnProperty.call(i,c)&&(n[c]=i[c])},r(t,o)};return function(t,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");r(t,o);function n(){this.constructor=t}t.prototype=o===null?Object.create(o):(n.prototype=o.prototype,new n)}}(),Ya=function(r,t){var o={label:0,sent:function(){if(c[0]&1)throw c[1];return c[1]},trys:[],ops:[]},n,i,c,l;return l={next:d(0),throw:d(1),return:d(2)},typeof Symbol=="function"&&(l[Symbol.iterator]=function(){return this}),l;function d(p){return function(h){return f([p,h])}}function f(p){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,i&&(c=p[0]&2?i.return:p[0]?i.throw||((c=i.return)&&c.call(i),0):i.next)&&!(c=c.call(i,p[1])).done)return c;switch(i=0,c&&(p=[p[0]&2,c.value]),p[0]){case 0:case 1:c=p;break;case 4:return o.label++,{value:p[1],done:!1};case 5:o.label++,i=p[1],p=[0];continue;case 7:p=o.ops.pop(),o.trys.pop();continue;default:if(c=o.trys,!(c=c.length>0&&c[c.length-1])&&(p[0]===6||p[0]===2)){o=0;continue}if(p[0]===3&&(!c||p[1]>c[0]&&p[1]<c[3])){o.label=p[1];break}if(p[0]===6&&o.label<c[1]){o.label=c[1],c=p;break}if(c&&o.label<c[2]){o.label=c[2],o.ops.push(p);break}c[2]&&o.ops.pop(),o.trys.pop();continue}p=t.call(r,o)}catch(h){p=[6,h],i=0}finally{n=c=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Fe=function(r,t){for(var o=0,n=t.length,i=r.length;o<n;o++,i++)r[i]=t[o];return r},Xa=Object.defineProperty,Qa=Object.defineProperties,Ja=Object.getOwnPropertyDescriptors,Ho=Object.getOwnPropertySymbols,ei=Object.prototype.hasOwnProperty,ti=Object.prototype.propertyIsEnumerable,$o=function(r,t,o){return t in r?Xa(r,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):r[t]=o},pe=function(r,t){for(var o in t||(t={}))ei.call(t,o)&&$o(r,o,t[o]);if(Ho)for(var n=0,i=Ho(t);n<i.length;n++){var o=i[n];ti.call(t,o)&&$o(r,o,t[o])}return r},ur=function(r,t){return Qa(r,Ja(t))},ri=function(r,t,o){return new Promise(function(n,i){var c=function(f){try{d(o.next(f))}catch(p){i(p)}},l=function(f){try{d(o.throw(f))}catch(p){i(p)}},d=function(f){return f.done?n(f.value):Promise.resolve(f.value).then(c,l)};d((o=o.apply(r,t)).next())})};var oi=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Pe:Pe.apply(null,arguments)},as=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(r){return r}};function ni(r){if(typeof r!="object"||r===null)return!1;var t=Object.getPrototypeOf(r);if(t===null)return!0;for(var o=t;Object.getPrototypeOf(o)!==null;)o=Object.getPrototypeOf(o);return t===o}var ai=function(r){Ko(t,r);function t(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=r.apply(this,o)||this;return Object.setPrototypeOf(i,t.prototype),i}return Object.defineProperty(t,Symbol.species,{get:function(){return t},enumerable:!1,configurable:!0}),t.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return r.prototype.concat.apply(this,o)},t.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(t.bind.apply(t,Fe([void 0],o[0].concat(this)))):new(t.bind.apply(t,Fe([void 0],o.concat(this))))},t}(Array),ii=function(r){Ko(t,r);function t(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=r.apply(this,o)||this;return Object.setPrototypeOf(i,t.prototype),i}return Object.defineProperty(t,Symbol.species,{get:function(){return t},enumerable:!1,configurable:!0}),t.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return r.prototype.concat.apply(this,o)},t.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(t.bind.apply(t,Fe([void 0],o[0].concat(this)))):new(t.bind.apply(t,Fe([void 0],o.concat(this))))},t}(Array);function hr(r){return Y(r)?St(r,function(){}):r}function ci(r){return typeof r=="boolean"}function si(){return function(t){return li(t)}}function li(r){r===void 0&&(r={});var t=r.thunk,o=t===void 0?!0:t,n=r.immutableCheck,i=n===void 0?!0:n,c=r.serializableCheck,l=c===void 0?!0:c,d=new ai;if(o&&(ci(o)?d.push(dr):d.push(dr.withExtraArgument(o.extraArgument))),0){if(i)var f;if(l)var p}return d}var pr=!0;function Vo(r){var t=si(),o=r||{},n=o.reducer,i=n===void 0?void 0:n,c=o.middleware,l=c===void 0?t():c,d=o.devTools,f=d===void 0?!0:d,p=o.preloadedState,h=p===void 0?void 0:p,y=o.enhancers,m=y===void 0?void 0:y,v;if(typeof i=="function")v=i;else if(ni(i))v=Bo(i);else throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');var b=l;if(typeof b=="function"&&(b=b(t),!pr&&!Array.isArray(b)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!pr&&b.some(function(T){return typeof T!="function"}))throw new Error("each middleware provided to configureStore must be a function");var S=Mo.apply(void 0,b),R=Pe;f&&(R=oi(pe({trace:!pr},typeof f=="object"&&f)));var w=new ii(S),A=w;Array.isArray(m)?A=Fe([S],m):typeof m=="function"&&(A=m(w));var P=R.apply(void 0,A);return lr(v,h,P)}function fe(r,t){function o(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];if(t){var c=t.apply(void 0,n);if(!c)throw new Error("prepareAction did not return an object");return pe(pe({type:r,payload:c.payload},"meta"in c&&{meta:c.meta}),"error"in c&&{error:c.error})}return{type:r,payload:n[0]}}return o.toString=function(){return""+r},o.type=r,o.match=function(n){return n.type===r},o}function Zo(r){var t={},o=[],n,i={addCase:function(c,l){var d=typeof c=="string"?c:c.type;if(d in t)throw new Error("addCase cannot be called with two reducers for the same action type");return t[d]=l,i},addMatcher:function(c,l){return o.push({matcher:c,reducer:l}),i},addDefaultCase:function(c){return n=c,i}};return r(i),[t,o,n]}function di(r){return typeof r=="function"}function ui(r,t,o,n){o===void 0&&(o=[]);var i=typeof t=="function"?Zo(t):[t,o,n],c=i[0],l=i[1],d=i[2],f;if(di(r))f=function(){return hr(r())};else{var p=hr(r);f=function(){return p}}function h(y,m){y===void 0&&(y=f());var v=Fe([c[m.type]],l.filter(function(b){var S=b.matcher;return S(m)}).map(function(b){var S=b.reducer;return S}));return v.filter(function(b){return!!b}).length===0&&(v=[d]),v.reduce(function(b,S){if(S)if(te(b)){var R=b,w=S(R,m);return w===void 0?b:w}else{if(Y(b))return St(b,function(A){return S(A,m)});var w=S(b,m);if(w===void 0){if(b===null)return b;throw Error("A case reducer on a non-draftable value must not return undefined")}return w}return b},y)}return h.getInitialState=f,h}function pi(r,t){return r+"/"+t}function qo(r){var t=r.name;if(!t)throw new Error("`name` is a required option for createSlice");typeof process<"u";var o=typeof r.initialState=="function"?r.initialState:hr(r.initialState),n=r.reducers||{},i=Object.keys(n),c={},l={},d={};i.forEach(function(h){var y=n[h],m=pi(t,h),v,b;"reducer"in y?(v=y.reducer,b=y.prepare):v=y,c[h]=v,l[m]=v,d[h]=b?fe(m,b):fe(m)});function f(){var h=typeof r.extraReducers=="function"?Zo(r.extraReducers):[r.extraReducers],y=h[0],m=y===void 0?{}:y,v=h[1],b=v===void 0?[]:v,S=h[2],R=S===void 0?void 0:S,w=pe(pe({},m),l);return ui(o,function(A){for(var P in w)A.addCase(P,w[P]);for(var T=0,M=b;T<M.length;T++){var Z=M[T];A.addMatcher(Z.matcher,Z.reducer)}R&&A.addDefaultCase(R)})}var p;return{name:t,reducer:function(h,y){return p||(p=f()),p(h,y)},actions:d,caseReducers:c,getInitialState:function(){return p||(p=f()),p.getInitialState()}}}var fi="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",hi=function(r){r===void 0&&(r=21);for(var t="",o=r;o--;)t+=fi[Math.random()*64|0];return t},yi=["name","message","stack","code"],fr=function(){function r(t,o){this.payload=t,this.meta=o}return r}(),Go=function(){function r(t,o){this.payload=t,this.meta=o}return r}(),gi=function(r){if(typeof r=="object"&&r!==null){for(var t={},o=0,n=yi;o<n.length;o++){var i=n[o];typeof r[i]=="string"&&(t[i]=r[i])}return t}return{message:String(r)}},ls=function(){function r(t,o,n){var i=fe(t+"/fulfilled",function(h,y,m,v){return{payload:h,meta:ur(pe({},v||{}),{arg:m,requestId:y,requestStatus:"fulfilled"})}}),c=fe(t+"/pending",function(h,y,m){return{payload:void 0,meta:ur(pe({},m||{}),{arg:y,requestId:h,requestStatus:"pending"})}}),l=fe(t+"/rejected",function(h,y,m,v,b){return{payload:v,error:(n&&n.serializeError||gi)(h||"Rejected"),meta:ur(pe({},b||{}),{arg:m,requestId:y,rejectedWithValue:!!v,requestStatus:"rejected",aborted:h?.name==="AbortError",condition:h?.name==="ConditionError"})}}),d=!1,f=typeof AbortController<"u"?AbortController:function(){function h(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return h.prototype.abort=function(){},h}();function p(h){return function(y,m,v){var b=n?.idGenerator?n.idGenerator(h):hi(),S=new f,R,w=!1;function A(T){R=T,S.abort()}var P=function(){return ri(this,null,function(){var T,M,Z,ge,$,me,Ae;return Ya(this,function(u){switch(u.label){case 0:return u.trys.push([0,4,,5]),ge=(T=n?.condition)==null?void 0:T.call(n,h,{getState:m,extra:v}),bi(ge)?[4,ge]:[3,2];case 1:ge=u.sent(),u.label=2;case 2:if(ge===!1||S.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return w=!0,$=new Promise(function(g,C){return S.signal.addEventListener("abort",function(){return C({name:"AbortError",message:R||"Aborted"})})}),y(c(b,h,(M=n?.getPendingMeta)==null?void 0:M.call(n,{requestId:b,arg:h},{getState:m,extra:v}))),[4,Promise.race([$,Promise.resolve(o(h,{dispatch:y,getState:m,extra:v,requestId:b,signal:S.signal,abort:A,rejectWithValue:function(g,C){return new fr(g,C)},fulfillWithValue:function(g,C){return new Go(g,C)}})).then(function(g){if(g instanceof fr)throw g;return g instanceof Go?i(g.payload,b,h,g.meta):i(g,b,h)})])];case 3:return Z=u.sent(),[3,5];case 4:return me=u.sent(),Z=me instanceof fr?l(null,b,h,me.payload,me.meta):l(me,b,h),[3,5];case 5:return Ae=n&&!n.dispatchConditionRejection&&l.match(Z)&&Z.meta.condition,Ae||y(Z),[2,Z]}})})}();return Object.assign(P,{abort:A,requestId:b,arg:h,unwrap:function(){return P.then(mi)}})}}return Object.assign(p,{pending:c,rejected:l,fulfilled:i,typePrefix:t})}return r.withTypes=function(){return r},r}();function mi(r){if(r.meta&&r.meta.rejectedWithValue)throw r.payload;if(r.error)throw r.error;return r.payload}function bi(r){return r!==null&&typeof r=="object"&&typeof r.then=="function"}var Yo="listener",Xo="completed",Qo="cancelled",ds="task-"+Qo,us="task-"+Xo,ps=Yo+"-"+Qo,fs=Yo+"-"+Xo;var yr="listenerMiddleware";var hs=fe(yr+"/add"),ys=fe(yr+"/removeAll"),gs=fe(yr+"/remove");var jo,ms=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(r){return(jo||(jo=Promise.resolve())).then(r).catch(function(t){return setTimeout(function(){throw t},0)})},xi=function(r){return function(t){setTimeout(t,r)}},bs=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:xi(10);Fo();function vi(r,t){return class extends r{constructor(){super(...arguments),this.eventBus=t??document.createElement("span")}addEventListener(o,n,i){this.eventBus.addEventListener(o,n,i)}dispatchEvent(o){return this.eventBus.dispatchEvent(o)}removeEventListener(o,n,i){this.eventBus.removeEventListener(o,n,i)}}}var Et=class extends vi(Object){};window.ftReduxStores||(window.ftReduxStores={});var Jo=class r extends Et{static get(t){var o;let n=typeof t=="string"?t:t.name,i=typeof t=="string"?void 0:t,c=window.ftReduxStores[n];if(Ze(c))return c;if(i==null)return;let l=qo({...i,reducers:(o=i.reducers)!==null&&o!==void 0?o:{}}),d=Vo({reducer:(f,p)=>p.type==="CLEAR_FT_REDUX_STORE"?l.getInitialState():typeof p.type=="string"&&p.type.startsWith("DEFAULT_VALUE_SETTER__")?{...f,...p.overwrites}:l.reducer(f,p)});return window.ftReduxStores[i.name]=new r(l,d)}constructor(t,o){super(),this.reduxSlice=t,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new ft;let n=i=>i!=null?JSON.parse(JSON.stringify(i)):i;this.actions=new Proxy(this.reduxSlice.actions,{get:(i,c,l)=>{let d=c,f=i[d];return f?(...p)=>{let h=f(...p.map(n));return this.reduxStore.dispatch(h),h}:p=>{this.setState({[d]:n(p)})}}})}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE"})}setState(t){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(t).join("_"),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()}};var It=N(B());var wt=class extends ee{async listMySearches(){let t=E.getState().session;return t?.sessionAuthenticated?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(t.profile.userId),5*60*1e3):[]}};var At=class extends ee{async listMyBookmarks(){let t=E.getState().session;return t?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(t.profile.userId),5*60*1e3):[]}};var Oi="ft-user-assets",Nt=It.FtReduxStore.get({name:Oi,initialState:{savedSearches:void 0,bookmarks:void 0}}),gr=class{constructor(){this.currentSession=E.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new At,this.savedSearchesService=new wt,E.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var t;let{session:o}=E.getState();(0,It.deepEqual)((t=this.currentSession)===null||t===void 0?void 0:t.profile,o?.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),Nt.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),Nt.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let t=await this.savedSearchesService.listMySearches();Nt.actions.savedSearches(t)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){let o=!((t=this.currentSession)===null||t===void 0)&&t.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;Nt.actions.bookmarks(o)}}},Js=new gr;var mr=class{addCommand(t,o=!1){E.commands.add(t,o)}consumeCommand(t){return E.commands.consume(t)}};window.FluidTopicsAppInfoStoreService=new mr;var en=N(B()),br=class{highlightHtml(t,o,n){(0,en.highlightHtml)(t,o,n)}};window.FluidTopicsHighlightHtmlService=new br;var tn=N(B());var xr=class{isDate(t){var o,n,i,c;return(c=(i=((n=(o=E.getState().metadataConfiguration)===null||o===void 0?void 0:o.descriptors)!==null&&n!==void 0?n:[]).find(d=>d.key===t))===null||i===void 0?void 0:i.date)!==null&&c!==void 0?c:!1}format(t,o){var n,i,c;return tn.DateFormatter.format(t,(n=o?.locale)!==null&&n!==void 0?n:E.getState().uiLocale,(i=o?.longFormat)!==null&&i!==void 0?i:!1,(c=o?.withTime)!==null&&c!==void 0?c:!1)}};window.FluidTopicsDateService=new xr;var Ci=N(B());(0,rn.customElement)("ft-app-context")(_);var vr=class r extends Event{constructor(){super(r.eventName)}};vr.eventName="search-context-clear-all-filters";var Ei=function(r,t,o,n){var i=arguments.length,c=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")c=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(l=r[d])&&(c=(i<3?l(c):i>3?l(t,o,c):l(t,o))||c);return i>3&&c&&Object.defineProperty(t,o,c),c},Or=class extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}},Sr=Symbol("registerInterval");function wi(r){var t;class o extends r{constructor(){super(...arguments),this[t]=0}setSearchStateManager(i){this.clearStateManager(),this.stateManager=i,this.addStore(i.store,"search")}clearStateManager(){this.stateManager&&(this.removeStore(this.stateManager.store),this.stateManager=void 0)}connectedCallback(){super.connectedCallback(),this[Sr]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null?window.clearInterval(this[Sr]):this.dispatchEvent(new Or)}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return t=Sr,Ei([(0,nn.state)()],o.prototype,"stateManager",void 0),o}var Tt=class extends wi(on.FtLitElementRedux){};var Lt=N(X()),Cr=function(r,t,o,n){var i=arguments.length,c=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")c=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(l=r[d])&&(c=(i<3?l(c):i>3?l(t,o,c):l(t,o))||c);return i>3&&c&&Object.defineProperty(t,o,c),c},wr=class extends Event{constructor(){super("register-ft-search-result-component",{bubbles:!0,composed:!0})}},Er=Symbol("registerInterval");function Ai(r){var t;class o extends r{constructor(){super(...arguments),this[t]=0}setResultStateManager(i){this.resultStateManager=i}unregisterResultStateManager(){this.resultStateManager&&(this.resultStateManager.unregisterComponent(this),this.resultStateManager=void 0)}connectedCallback(){super.connectedCallback(),this[Er]=window.setInterval(()=>this.tryToRegisterToResultContext(),50)}tryToRegisterToResultContext(){this.result!=null?window.clearInterval(this[Er]):this.dispatchEvent(new wr)}disconnectedCallback(){super.disconnectedCallback(),this.unregisterResultStateManager()}}return t=Er,Cr([(0,Lt.property)({attribute:!1})],o.prototype,"cluster",void 0),Cr([(0,Lt.property)({attribute:!1})],o.prototype,"result",void 0),Cr([(0,Lt.property)({attribute:!1,type:Number})],o.prototype,"rank",void 0),o}var Pt=class extends Ai(Tt){};var an=N(J()),cn=N(B()),Ni={highlightBackgroundColor:cn.FtCssVariableFactory.create("--ft-srt-highlight-background-color","","COLOR","transparent")},sn=an.css`
|
|
6
6
|
.kwicmatch {
|
|
7
7
|
font-weight: 700;
|
|
8
8
|
background-color: ${Ni.highlightBackgroundColor};
|