@fluid-topics/ft-search-results 1.2.60 → 1.2.62
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { PropertyValues, TemplateResult } from "lit";
|
|
2
2
|
import { ClusterPolicy, FtSearchResultsProperties } from "./ft-search-results.properties";
|
|
3
3
|
import { FtSearchComponent } from "@fluid-topics/ft-search-context/build/registration";
|
|
4
|
-
import type { FtPublicClusterSortCriterion, FtSearchRequest, FtSearchResultCluster, FtSearchResultClusterEntry
|
|
4
|
+
import type { FtPageRequest, FtPublicClusterSortCriterion, FtSearchRequest, FtSearchResultCluster, FtSearchResultClusterEntry } from "@fluid-topics/public-api";
|
|
5
5
|
import "@fluid-topics/ft-search-result-context";
|
|
6
6
|
import "@fluid-topics/ft-search-result-title";
|
|
7
7
|
import "@fluid-topics/ft-search-result-abstract";
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
text-align: center;
|
|
5
5
|
padding: 12px;
|
|
6
6
|
}
|
|
7
|
-
`;var ra=O(T()),oa=O(G());var Vt=O(T());var Io=O(T());var Zi=O(No(),1);var To;(function(r){r.black="black",r.green="green",r.blue="blue",r.purple="purple",r.red="red",r.orange="orange",r.yellow="yellow"})(To||(To={}));var _o;(function(r){r.OFFICIAL="OFFICIAL",r.PERSONAL="PERSONAL",r.SHARED="SHARED"})(_o||(_o={}));var Po;(function(r){r.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",r.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",r.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",r.PERSONAL_BOOK="PERSONAL_BOOK",r.MAP_ATTACHMENT="MAP_ATTACHMENT",r.RESOURCE="RESOURCE"})(Po||(Po={}));var ko;(function(r){r.LAST_WEEK="LAST_WEEK",r.LAST_MONTH="LAST_MONTH",r.LAST_QUARTER="LAST_QUARTER",r.LAST_YEAR="LAST_YEAR"})(ko||(ko={}));var Lo;(function(r){r.VALUE="VALUE",r.DATE="DATE",r.RANGE="RANGE"})(Lo||(Lo={}));var Fo;(function(r){r.BOOKMARK__CREATE="BOOKMARK__CREATE",r.BOOKMARK__DELETE="BOOKMARK__DELETE",r.CASE_DEFLECTION__START="CASE_DEFLECTION__START",r.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",r.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",r.COLLECTION__CREATE="COLLECTION__CREATE",r.COLLECTION__UPDATE="COLLECTION__UPDATE",r.COLLECTION__DELETE="COLLECTION__DELETE",r.DOCUMENT__DISPLAY="DOCUMENT__DISPLAY",r.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",r.DOCUMENT__PRINT="DOCUMENT__PRINT",r.DOCUMENT__PROCESS="DOCUMENT__PROCESS",r.DOCUMENT__RATE="DOCUMENT__RATE",r.DOCUMENT__SEARCH="DOCUMENT__SEARCH",r.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",r.DOCUMENT__UNRATE="DOCUMENT__UNRATE",r.FEEDBACK__SEND="FEEDBACK__SEND",r.GEN_AI__COMPLETED_QUERY="GEN_AI__COMPLETED_QUERY",r.GEN_AI__RATE="GEN_AI__RATE",r.GENAI_CASE_DEFLECTION__START="GENAI_CASE_DEFLECTION__START",r.GENAI_CASE_DEFLECTION__OPEN_TICKET="GENAI_CASE_DEFLECTION__OPEN_TICKET",r.KHUB__PROCESS="KHUB__PROCESS",r.KHUB__SEARCH="KHUB__SEARCH",r.LABELS__DOWNLOAD="LABELS__DOWNLOAD",r.LINK__SHARE="LINK__SHARE",r.PAGE__DISPLAY="PAGE__DISPLAY",r.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",r.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",r.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",r.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",r.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",r.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",r.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",r.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",r.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",r.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",r.
|
|
7
|
+
`;var ra=O(T()),oa=O(G());var Vt=O(T());var Io=O(T());var Zi=O(No(),1);var To;(function(r){r.black="black",r.green="green",r.blue="blue",r.purple="purple",r.red="red",r.orange="orange",r.yellow="yellow"})(To||(To={}));var _o;(function(r){r.OFFICIAL="OFFICIAL",r.PERSONAL="PERSONAL",r.SHARED="SHARED"})(_o||(_o={}));var Po;(function(r){r.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",r.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",r.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",r.PERSONAL_BOOK="PERSONAL_BOOK",r.MAP_ATTACHMENT="MAP_ATTACHMENT",r.RESOURCE="RESOURCE"})(Po||(Po={}));var ko;(function(r){r.LAST_WEEK="LAST_WEEK",r.LAST_MONTH="LAST_MONTH",r.LAST_QUARTER="LAST_QUARTER",r.LAST_YEAR="LAST_YEAR"})(ko||(ko={}));var Lo;(function(r){r.VALUE="VALUE",r.DATE="DATE",r.RANGE="RANGE"})(Lo||(Lo={}));var Fo;(function(r){r.BOOKMARK__CREATE="BOOKMARK__CREATE",r.BOOKMARK__DELETE="BOOKMARK__DELETE",r.CASE_DEFLECTION__START="CASE_DEFLECTION__START",r.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",r.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",r.COLLECTION__CREATE="COLLECTION__CREATE",r.COLLECTION__UPDATE="COLLECTION__UPDATE",r.COLLECTION__DELETE="COLLECTION__DELETE",r.DOCUMENT__DISPLAY="DOCUMENT__DISPLAY",r.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",r.DOCUMENT__PRINT="DOCUMENT__PRINT",r.DOCUMENT__PROCESS="DOCUMENT__PROCESS",r.DOCUMENT__RATE="DOCUMENT__RATE",r.DOCUMENT__SEARCH="DOCUMENT__SEARCH",r.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",r.DOCUMENT__UNRATE="DOCUMENT__UNRATE",r.FEEDBACK__SEND="FEEDBACK__SEND",r.GEN_AI__COMPLETED_QUERY="GEN_AI__COMPLETED_QUERY",r.GEN_AI__RATE="GEN_AI__RATE",r.GENAI_CASE_DEFLECTION__START="GENAI_CASE_DEFLECTION__START",r.GENAI_CASE_DEFLECTION__OPEN_TICKET="GENAI_CASE_DEFLECTION__OPEN_TICKET",r.KHUB__PROCESS="KHUB__PROCESS",r.KHUB__SEARCH="KHUB__SEARCH",r.LABELS__DOWNLOAD="LABELS__DOWNLOAD",r.LINK__SHARE="LINK__SHARE",r.PAGE__DISPLAY="PAGE__DISPLAY",r.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",r.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",r.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",r.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",r.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",r.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",r.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",r.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",r.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",r.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",r.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",r.TOPIC__DISPLAY="TOPIC__DISPLAY",r.TOPIC__RATE="TOPIC__RATE",r.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",r.TOPIC__UNRATE="TOPIC__UNRATE",r.USER__LOGIN="USER__LOGIN",r.USER__LOGOUT="USER__LOGOUT",r.HEARTBEAT="HEARTBEAT"})(Fo||(Fo={}));var Do;(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"})(Do||(Do={}));var Uo;(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"})(Uo||(Uo={}));var Bo;(function(r){r.CLASSIC="CLASSIC",r.CUSTOM="CUSTOM",r.DESIGNER="DESIGNER"})(Bo||(Bo={}));var Mo;(function(r){r.AND="AND",r.OR="OR",r.MONOVALUED="MONOVALUED"})(Mo||(Mo={}));var Wo;(function(r){r.NONE="NONE",r.ALPHABET="ALPHABET",r.VERSION="VERSION"})(Wo||(Wo={}));var Ho;(function(r){r.STARS="STARS",r.LIKE="LIKE",r.DICHOTOMOUS="DICHOTOMOUS",r.NO_RATING="NO_RATING"})(Ho||(Ho={}));var zo;(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"})(zo||(zo={}));var jo;(function(r){r.ASC="ASC",r.DESC="DESC"})(jo||(jo={}));var $o;(function(r){r.ALPHA="ALPHA",r.NATURAL="NATURAL"})($o||($o={}));var gr;(function(r){r.EVERYWHERE="EVERYWHERE",r.TITLE_ONLY="TITLE_ONLY",r.NONE="NONE"})(gr||(gr={}));var Go;(function(r){r.ARTICLE="ARTICLE",r.BOOK="BOOK",r.SHARED_BOOK="SHARED_BOOK"})(Go||(Go={}));var At;(function(r){r.FLUIDTOPICS="FLUIDTOPICS",r.EXTERNAL="EXTERNAL"})(At||(At={}));var Ko;(function(r){r.MAP="MAP",r.DOCUMENT="DOCUMENT",r.TOPIC="TOPIC",r.PERSONAL_BOOK="PERSONAL_BOOK",r.SHARED_BOOK="SHARED_BOOK"})(Ko||(Ko={}));var Vo;(function(r){r.LAST_WEEK="LAST_WEEK",r.LAST_MONTH="LAST_MONTH",r.LAST_QUARTER="LAST_QUARTER",r.LAST_YEAR="LAST_YEAR"})(Vo||(Vo={}));var De;(function(r){r.MAP="MAP",r.DOCUMENT="DOCUMENT",r.TOPIC="TOPIC"})(De||(De={}));var mr;(function(r){r.DEFAULT="DEFAULT",r.DOCUMENTS="DOCUMENTS",r.ALL_TOPICS="ALL_TOPICS",r.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(mr||(mr={}));var B;(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.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_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"})(B||(B={}));var Zo;(function(r){r.VALID="VALID",r.INVALID="INVALID"})(Zo||(Zo={}));var qo;(function(r){r.JSON="JSON",r.TEXT="TEXT"})(qo||(qo={}));var Yo;(function(r){r.TEXT="TEXT",r.HTML="HTML"})(Yo||(Yo={}));var Vi={[B.PERSONAL_BOOK_SHARE_USER]:[B.PERSONAL_BOOK_USER],[B.HTML_EXPORT_USER]:[B.PERSONAL_BOOK_USER],[B.PDF_EXPORT_USER]:[B.PERSONAL_BOOK_USER],[B.KHUB_ADMIN]:[B.CONTENT_PUBLISHER],[B.ADMIN]:[B.KHUB_ADMIN,B.USERS_ADMIN,B.PORTAL_ADMIN],[B.GENERATIVE_AI_EXPORT_USER]:[B.GENERATIVE_AI_USER]};function Qo(r,t){return r===t||(Vi[r]??[]).some(o=>Qo(o,t))}function Xo(r,t){return r==null?!1:(Array.isArray(r)?r:Array.isArray(r.roles)?r.roles:Array.isArray(r.profile?.roles)?r.profile.roles:[]).some(n=>Qo(n,t))}var ea=O(T());var rn=O(H()),K=O(G()),X=O(T());var Jo=O(H());var en=Jo.css`
|
|
8
8
|
`;var It=O(T()),qi="ft-app-info",br=class extends CustomEvent{constructor(t){super("authentication-change",{detail:t})}},Yi={session:(r,t)=>{(0,It.deepEqual)(r.session,t.payload)||(r.session=t.payload,setTimeout(()=>w.dispatchEvent(new br(t.payload)),0))}},w=It.FtReduxStore.get({name:qi,reducers:Yi,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],defaultLocales:void 0,searchInAllLanguagesAllowed:!1,metadataConfiguration:void 0,privacyPolicyConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,session:void 0,openExternalDocumentInNewTab:!1,navigatorOnline:!0,forcedOffline:!1}});var re=O(T());var xr=O(T());var Ce=class r{static get(t){let{baseUrl:o,apiIntegrationIdentifier:n}=w.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=w.subscribe(()=>{n=r.get(t),n&&(i(),o(n))})}})}};var it=class{constructor(t){this.overrideApi=t}get api(){var t;return(t=this.overrideApi)!==null&&t!==void 0?t:Ce.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):Ce.await()}};var ae=class extends it{constructor(t=!0,o){var n;super(o);let i=this.constructor;i.commonCache=(n=i.commonCache)!==null&&n!==void 0?n:new xr.CacheRegistry,this.cache=t?i.commonCache:new xr.CacheRegistry}clearCache(){this.cache.clearAll()}};var tn,Qi=Symbol("clearAfterUnitTest"),Rt=class extends ae{constructor(t){super(),this.messageContextProvider=t,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[tn]=()=>{this.defaultMessages={},this.cache=new re.CacheRegistry,this.listeners={}},this.currentUiLocale=w.getState().uiLocale,w.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:t}=w.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(),o&&Object.keys(o).length>0){let i={...(n=this.defaultMessages[t])!==null&&n!==void 0?n:{},...o};(0,re.deepEqual)(this.defaultMessages[t],i)||(this.defaultMessages[t]=i,await this.notify(t))}return 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 s=t.toLowerCase(),c=this.resolveContext(s);return new re.ParametrizedLabelResolver((i=this.defaultMessages[s])!==null&&i!==void 0?i:{},c).resolve(o,...n)}async fetchContext(t){let o=!this.cache.has(t),n;try{n=await this.cache.get(t,()=>this.messageContextProvider(this.currentUiLocale,t))}catch(i){!(i instanceof re.CanceledPromiseError)&&o&&console.error(i)}return o&&await this.notify(t),n}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,re.delay)(0).then(()=>o()).catch(()=>null)))}};tn=Qi;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends Rt{constructor(){super(async(r,t)=>(await this.awaitApi).getFluidTopicsMessageContext(r,t))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends Rt{constructor(){super(async(r,t)=>(await this.awaitApi).getCustomMessageContext(r,t))}});var Ue=window.FluidTopicsI18nService,Nt=window.FluidTopicsCustomI18nService;var z=function(r,t,o,n){var i=arguments.length,s=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,c;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")s=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(c=r[d])&&(s=(i<3?c(s):i>3?c(t,o,s):c(t,o))||s);return i>3&&s&&Object.defineProperty(t,o,s),s},D=class extends X.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=()=>Ce.get(),this.messageContexts=[],this.cache=new X.CacheRegistry,this.cleanSessionDebouncer=new X.Debouncer}render(){return rn.html`
|
|
9
9
|
<slot></slot>
|
|
10
10
|
`}update(t){var o,n,i,s,c;super.update(t),t.has("baseUrl")&&(w.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),t.has("apiIntegrationIdentifier")&&w.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&w.actions.uiLocale(this.uiLocale),t.has("metadataConfiguration")&&w.actions.metadataConfiguration(this.metadataConfiguration),t.has("noCustom")&&w.actions.noCustom(this.noCustom),t.has("editorMode")&&w.actions.editorMode(this.editorMode),t.has("noCustomComponent")&&w.actions.noCustomComponent(this.noCustomComponent),t.has("session")&&w.actions.session(this.session),t.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(d=>Ue.addContext(d)),t.has("openExternalDocumentInNewTab")&&w.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),t.has("navigatorOnline")&&w.actions.navigatorOnline(this.navigatorOnline),t.has("forcedOffline")&&w.actions.forcedOffline(this.forcedOffline),t.has("localesConfiguration")&&(w.actions.defaultLocales((o=this.localesConfiguration)===null||o===void 0?void 0:o.defaultLocales),w.actions.availableUiLocales((i=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&i!==void 0?i:[]),w.actions.searchInAllLanguagesAllowed((c=(s=this.localesConfiguration)===null||s===void 0?void 0:s.allLanguagesAllowed)!==null&&c!==void 0?c:!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())}};D.elementDefinitions={};D.styles=en;z([(0,K.property)()],D.prototype,"baseUrl",void 0);z([(0,K.property)()],D.prototype,"apiIntegrationIdentifier",void 0);z([(0,K.property)()],D.prototype,"uiLocale",void 0);z([(0,X.jsonProperty)(null)],D.prototype,"availableUiLocales",void 0);z([(0,X.jsonProperty)(null)],D.prototype,"metadataConfiguration",void 0);z([(0,K.property)({type:Boolean})],D.prototype,"editorMode",void 0);z([(0,K.property)({type:Boolean})],D.prototype,"noCustom",void 0);z([(0,K.property)({type:Boolean})],D.prototype,"openExternalDocumentInNewTab",void 0);z([(0,K.property)({converter:{fromAttribute(r){return r==="false"?!1:r==="true"||(r??!1)}}})],D.prototype,"noCustomComponent",void 0);z([(0,K.property)({type:Boolean})],D.prototype,"withManualResources",void 0);z([(0,K.property)({type:Boolean})],D.prototype,"navigatorOnline",void 0);z([(0,K.property)({type:Boolean})],D.prototype,"forcedOffline",void 0);z([(0,K.property)({type:Object})],D.prototype,"apiProvider",void 0);z([(0,X.jsonProperty)([])],D.prototype,"messageContexts",void 0);z([(0,X.jsonProperty)(void 0)],D.prototype,"session",void 0);z([(0,K.state)()],D.prototype,"localesConfiguration",void 0);var Bs=O(G());function Xi(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(!Tt(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(!Tt(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 s=c=>Object.keys(c).filter(d=>c[d]!=null);if(i=s(r),o=i.length,o!==s(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 c=i[n];if(!Tt(r[c],t[c]))return!1}return!0}return r!==r&&t!==t||r==null&&t==null}function Tt(r,t){try{return Xi(r,t)}catch{return!1}}function _t(r,t){return!Tt(r,t)}var Ji=O(G(),1);var Pt=class{constructor(){this.queue=[]}add(t,o=!1){o&&this.clear(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}clear(t){typeof t=="string"?this.queue=this.queue.filter(o=>o.type!==t):this.queue=this.queue.filter(o=>!t.test(o.type))}};var Be=O(G(),1);var on=O(G(),1);function nn(r,t){let o=()=>JSON.parse(JSON.stringify(r));return(0,on.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:_t,...t??{}})}var kt=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,s=(o=this.resolvePromise)!==null&&o!==void 0?o:()=>null;this.clearPromise();for(let c of n)try{await c()}catch(d){i(d);return}s(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var sn=O(H(),1);var Lt=globalThis,es=Lt.ShadowRoot&&(Lt.ShadyCSS===void 0||Lt.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Zc=Symbol();var an=(r,t)=>{if(es)r.adoptedStyleSheets=t.map(o=>o instanceof CSSStyleSheet?o:o.styleSheet);else for(let o of t){let n=document.createElement("style"),i=Lt.litNonce;i!==void 0&&n.setAttribute("nonce",i),n.textContent=o.cssText,r.appendChild(n)}};var Ft=class extends sn.LitElement{createRenderRoot(){let t=this.constructor;t.elementDefinitions&&!t.registry&&(t.registry=new CustomElementRegistry,Object.entries(t.elementDefinitions).forEach(([i,s])=>t.registry.define(i,s)));let o={...t.shadowRootOptions,customElements:t.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return an(n,t.elementStyles),n}};function cn(r,t,...o){var n;let i=r.querySelector(t);for(let s of o)i=(n=i?.shadowRoot)===null||n===void 0?void 0:n.querySelector(s);return i}var st=function(r,t,o,n){var i=arguments.length,s=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,c;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")s=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(c=r[d])&&(s=(i<3?c(s):i>3?c(t,o,s):c(t,o))||s);return i>3&&s&&Object.defineProperty(t,o,s),s},pn,ln=Symbol("constructorPrototype"),dn=Symbol("constructorName"),fn=Symbol("exportpartsDebouncer"),un=Symbol("dynamicDependenciesLoaded"),ie=class extends Ft{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[pn]=new kt(5),this[dn]=this.constructor.name,this[ln]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[dn]&&Object.setPrototypeOf(this,this[ln])}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[un]||(t[un]=!0,this.importDynamicDependencies())}importDynamicDependencies(){}updated(t){super.updated(t),this.updateComplete.then(()=>{this.contentAvailableCallback(t),this.focusElementToFocus(t),this.applyCustomStylesheet(t),this.scheduleExportpartsUpdate()})}contentAvailableCallback(t){}focusElementToFocus(t){if(t.has("elementToFocus")&&this.elementToFocus!=null){let{element:o,selector:n,shadowPath:i}=this.elementToFocus;if(n!=null){let s=[...i??[],n];o=cn(this.shadowRoot,...s)}o?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||o?.blur(),this.elementToFocus=void 0}}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(s=>s.remove()),this.useAdoptedStyleSheets){if(t.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((i=this.customStylesheet)!==null&&i!==void 0?i:"")}catch(s){console.error(s,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let s=document.createElement("style");s.classList.add("ft-lit-element--custom-stylesheet"),s.innerHTML=this.customStylesheet,this.shadowRoot.append(s)}}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[fn].run(()=>{var i,s;!((i=this.exportpartsPrefix)===null||i===void 0)&&i.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((s=this.exportpartsPrefixes)===null||s===void 0?void 0:s.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})}setExportpartsAttribute(t){var o,n,i,s,c,d;let u=g=>g!=null&&g.trim().length>0,p=t.filter(u).map(g=>g.trim());if(p.length===0){this.removeAttribute("exportparts");return}let y=new Set;for(let g of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let v=(s=(i=g.getAttribute("part"))===null||i===void 0?void 0:i.split(" "))!==null&&s!==void 0?s:[],b=(d=(c=g.getAttribute("exportparts"))===null||c===void 0?void 0:c.split(",").map(S=>S.split(":")[1]))!==null&&d!==void 0?d:[];new Array(...v,...b).filter(u).map(S=>S.trim()).forEach(S=>y.add(S))}if(y.size===0){this.removeAttribute("exportparts");return}let h=[...y.values()].flatMap(g=>p.map(v=>`${g}:${v}--${g}`));this.setAttribute("exportparts",[...this.part,...h].join(", "))}};pn=fn;st([(0,Be.property)()],ie.prototype,"exportpartsPrefix",void 0);st([nn([])],ie.prototype,"exportpartsPrefixes",void 0);st([(0,Be.property)()],ie.prototype,"customStylesheet",void 0);st([(0,Be.property)()],ie.prototype,"elementToFocus",void 0);st([(0,Be.state)()],ie.prototype,"useAdoptedStyleSheets",void 0);function ct(r){var t;return(t=r?.isFtReduxStore)!==null&&t!==void 0?t:!1}var hn,yn,gn,lt=Symbol("internalReduxEventsUnsubscribers"),ue=Symbol("internalStoresUnsubscribers"),Ee=Symbol("internalStores"),dt=class extends ie{constructor(){super(...arguments),this[hn]=new Map,this[yn]=new Map,this[gn]=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[Ee].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Ee].values()][0]}getStore(t){return t==null?this.getUnnamedStore():this[Ee].get(t)}addStore(t,o){var n;o=(n=o??(ct(t)?t.name:void 0))!==null&&n!==void 0?n:"default-store",this.unsubscribeFromStore(o),this[Ee].set(o,t),this.subscribeToStore(o,t),this.updateFromStores()}removeStore(t){let o=typeof t=="string"?t:t.name;this.unsubscribeFromStore(o),this[Ee].delete(o)}setupStores(){this.unsubscribeFromStores(),this[Ee].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[ue].has(t.store):this[ue].size>0)&&(this[o]=t.selector(i.getState(),this))}})}subscribeToStore(t,o){var n;this[ue].set(t,o.subscribe(()=>this.updateFromStores())),this[lt].set(t,[]),ct(o)&&o.eventBus&&((n=this.reduxConstructor.reduxEventListeners)===null||n===void 0||n.forEach((i,s)=>{if(typeof this[s]=="function"&&(!i.store||o.name===i.store)){let c=d=>this[s](d);o.addEventListener(i.eventName,c),this[lt].get(t).push(()=>o.removeEventListener(i.eventName,c))}})),this.onStoreAvailable(t)}unsubscribeFromStores(){this[ue].forEach((t,o)=>this.unsubscribeFromStore(o))}unsubscribeFromStore(t){var o;this[ue].has(t)&&this[ue].get(t)(),this[ue].delete(t),(o=this[lt].get(t))===null||o===void 0||o.forEach(n=>n()),this[lt].delete(t)}onStoreAvailable(t){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}};hn=ue,yn=Ee,gn=lt;dt.reduxProperties=new Map;dt.reduxReactiveProperties=new Set;dt.reduxEventListeners=new Map;function Z(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,s;throw Error("[Immer] minified error nr: "+r+(o.length?" "+o.map(function(c){return"'"+c+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function se(r){return!!r&&!!r[L]}function J(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)===cs}(r)||Array.isArray(r)||!!r[Cn]||!!(!((t=r.constructor)===null||t===void 0)&&t[Cn])||Rr(r)||Nr(r))}function we(r,t,o){o===void 0&&(o=!1),He(r)===0?(o?Object.keys:We)(r).forEach(function(n){o&&typeof n=="symbol"||t(n,r[n],r)}):r.forEach(function(n,i){return t(i,n,r)})}function He(r){var t=r[L];return t?t.i>3?t.i-4:t.i:Array.isArray(r)?1:Rr(r)?2:Nr(r)?3:0}function Me(r,t){return He(r)===2?r.has(t):Object.prototype.hasOwnProperty.call(r,t)}function ts(r,t){return He(r)===2?r.get(t):r[t]}function En(r,t,o){var n=He(r);n===2?r.set(t,o):n===3?r.add(o):r[t]=o}function wn(r,t){return r===t?r!==0||1/r==1/t:r!=r&&t!=t}function Rr(r){return is&&r instanceof Map}function Nr(r){return ss&&r instanceof Set}function pe(r){return r.o||r.t}function Tr(r){if(Array.isArray(r))return Array.prototype.slice.call(r);var t=Rn(r);delete t[L];for(var o=We(t),n=0;n<o.length;n++){var i=o[n],s=t[i];s.writable===!1&&(s.writable=!0,s.configurable=!0),(s.get||s.set)&&(t[i]={configurable:!0,writable:!0,enumerable:s.enumerable,value:r[i]})}return Object.create(Object.getPrototypeOf(r),t)}function _r(r,t){return t===void 0&&(t=!1),Pr(r)||se(r)||!J(r)||(He(r)>1&&(r.set=r.add=r.clear=r.delete=rs),Object.freeze(r),t&&we(r,function(o,n){return _r(n,!0)},!0)),r}function rs(){Z(2)}function Pr(r){return r==null||typeof r!="object"||Object.isFrozen(r)}function oe(r){var t=Ir[r];return t||Z(18,r),t}function os(r,t){Ir[r]||(Ir[r]=t)}function Er(){return pt}function vr(r,t){t&&(oe("Patches"),r.u=[],r.s=[],r.v=t)}function Dt(r){wr(r),r.p.forEach(ns),r.p=null}function wr(r){r===pt&&(pt=r.l)}function mn(r){return pt={p:[],l:pt,h:r,m:!0,_:0}}function ns(r){var t=r[L];t.i===0||t.i===1?t.j():t.g=!0}function Sr(r,t){t._=t.p.length;var o=t.p[0],n=r!==void 0&&r!==o;return t.h.O||oe("ES5").S(t,r,n),n?(o[L].P&&(Dt(t),Z(4)),J(r)&&(r=Ut(t,r),t.l||Bt(t,r)),t.u&&oe("Patches").M(o[L].t,r,t.u,t.s)):r=Ut(t,o,[]),Dt(t),t.u&&t.v(t.u,t.s),r!==In?r:void 0}function Ut(r,t,o){if(Pr(t))return t;var n=t[L];if(!n)return we(t,function(d,u){return bn(r,n,t,d,u,o)},!0),t;if(n.A!==r)return t;if(!n.P)return Bt(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,s=i,c=!1;n.i===3&&(s=new Set(i),i.clear(),c=!0),we(s,function(d,u){return bn(r,n,i,d,u,o,c)}),Bt(r,i,!1),o&&r.u&&oe("Patches").N(n,o,r.u,r.s)}return n.o}function bn(r,t,o,n,i,s,c){if(se(i)){var d=Ut(r,i,s&&t&&t.i!==3&&!Me(t.R,n)?s.concat(n):void 0);if(En(o,n,d),!se(d))return;r.m=!1}else c&&o.add(i);if(J(i)&&!Pr(i)){if(!r.h.D&&r._<1)return;Ut(r,i),t&&t.A.l||Bt(r,i)}}function Bt(r,t,o){o===void 0&&(o=!1),!r.l&&r.h.D&&r.m&&_r(t,o)}function Or(r,t){var o=r[L];return(o?pe(o):r)[t]}function xn(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 fe(r){r.P||(r.P=!0,r.l&&fe(r.l))}function Cr(r){r.o||(r.o=Tr(r.t))}function Ar(r,t,o){var n=Rr(t)?oe("MapSet").F(t,o):Nr(t)?oe("MapSet").T(t,o):r.O?function(i,s){var c=Array.isArray(i),d={i:c?1:0,A:s?s.A:Er(),P:!1,I:!1,R:{},l:s,t:i,k:null,o:null,j:null,C:!1},u=d,p=ft;c&&(u=[d],p=ut);var y=Proxy.revocable(u,p),h=y.revoke,g=y.proxy;return d.k=g,d.j=h,g}(t,o):oe("ES5").J(t,o);return(o?o.A:Er()).p.push(n),n}function as(r){return se(r)||Z(22,r),function t(o){if(!J(o))return o;var n,i=o[L],s=He(o);if(i){if(!i.P&&(i.i<4||!oe("ES5").K(i)))return i.t;i.I=!0,n=vn(o,s),i.I=!1}else n=vn(o,s);return we(n,function(c,d){i&&ts(i.t,c)===d||En(n,c,t(d))}),s===3?new Set(n):n}(r)}function vn(r,t){switch(t){case 2:return new Map(r);case 3:return Array.from(r)}return Tr(r)}function An(){function r(c,d){var u=s[c];return u?u.enumerable=d:s[c]=u={configurable:!0,enumerable:d,get:function(){var p=this[L];return ft.get(p,c)},set:function(p){var y=this[L];ft.set(y,c,p)}},u}function t(c){for(var d=c.length-1;d>=0;d--){var u=c[d][L];if(!u.P)switch(u.i){case 5:n(u)&&fe(u);break;case 4:o(u)&&fe(u)}}}function o(c){for(var d=c.t,u=c.k,p=We(u),y=p.length-1;y>=0;y--){var h=p[y];if(h!==L){var g=d[h];if(g===void 0&&!Me(d,h))return!0;var v=u[h],b=v&&v[L];if(b?b.t!==g:!wn(v,g))return!0}}var S=!!d[L];return p.length!==We(d).length+(S?0:1)}function n(c){var d=c.k;if(d.length!==c.t.length)return!0;var u=Object.getOwnPropertyDescriptor(d,d.length-1);if(u&&!u.get)return!0;for(var p=0;p<d.length;p++)if(!d.hasOwnProperty(p))return!0;return!1}function i(c){c.g&&Z(3,JSON.stringify(pe(c)))}var s={};os("ES5",{J:function(c,d){var u=Array.isArray(c),p=function(h,g){if(h){for(var v=Array(g.length),b=0;b<g.length;b++)Object.defineProperty(v,""+b,r(b,!0));return v}var S=Rn(g);delete S[L];for(var N=We(S),A=0;A<N.length;A++){var I=N[A];S[I]=r(I,h||!!S[I].enumerable)}return Object.create(Object.getPrototypeOf(g),S)}(u,c),y={i:u?5:4,A:d?d.A:Er(),P:!1,I:!1,R:{},l:d,t:c,k:p,o:null,g:!1,C:!1};return Object.defineProperty(p,L,{value:y,writable:!0}),p},S:function(c,d,u){u?se(d)&&d[L].A===c&&t(c.p):(c.u&&function p(y){if(y&&typeof y=="object"){var h=y[L];if(h){var g=h.t,v=h.k,b=h.R,S=h.i;if(S===4)we(v,function(_){_!==L&&(g[_]!==void 0||Me(g,_)?b[_]||p(v[_]):(b[_]=!0,fe(h)))}),we(g,function(_){v[_]!==void 0||Me(v,_)||(b[_]=!1,fe(h))});else if(S===5){if(n(h)&&(fe(h),b.length=!0),v.length<g.length)for(var N=v.length;N<g.length;N++)b[N]=!1;else for(var A=g.length;A<v.length;A++)b[A]=!0;for(var I=Math.min(v.length,g.length),k=0;k<I;k++)v.hasOwnProperty(k)||(b[k]=!0),b[k]===void 0&&p(v[k])}}}}(c.p[0]),t(c.p))},K:function(c){return c.i===4?o(c):n(c)}})}var Sn,pt,kr=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",is=typeof Map<"u",ss=typeof Set<"u",On=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",In=kr?Symbol.for("immer-nothing"):((Sn={})["immer-nothing"]=!0,Sn),Cn=kr?Symbol.for("immer-draftable"):"__$immer_draftable",L=kr?Symbol.for("immer-state"):"__$immer_state";var cs=""+Object.prototype.constructor,We=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(r){return Object.getOwnPropertyNames(r).concat(Object.getOwnPropertySymbols(r))}:Object.getOwnPropertyNames,Rn=Object.getOwnPropertyDescriptors||function(r){var t={};return We(r).forEach(function(o){t[o]=Object.getOwnPropertyDescriptor(r,o)}),t},Ir={},ft={get:function(r,t){if(t===L)return r;var o=pe(r);if(!Me(o,t))return function(i,s,c){var d,u=xn(s,c);return u?"value"in u?u.value:(d=u.get)===null||d===void 0?void 0:d.call(i.k):void 0}(r,o,t);var n=o[t];return r.I||!J(n)?n:n===Or(r.t,t)?(Cr(r),r.o[t]=Ar(r.A.h,n,r)):n},has:function(r,t){return t in pe(r)},ownKeys:function(r){return Reflect.ownKeys(pe(r))},set:function(r,t,o){var n=xn(pe(r),t);if(n?.set)return n.set.call(r.k,o),!0;if(!r.P){var i=Or(pe(r),t),s=i?.[L];if(s&&s.t===o)return r.o[t]=o,r.R[t]=!1,!0;if(wn(o,i)&&(o!==void 0||Me(r.t,t)))return!0;Cr(r),fe(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 Or(r.t,t)!==void 0||t in r.t?(r.R[t]=!1,Cr(r),fe(r)):delete r.R[t],r.o&&delete r.o[t],!0},getOwnPropertyDescriptor:function(r,t){var o=pe(r),n=Reflect.getOwnPropertyDescriptor(o,t);return n&&{writable:!0,configurable:r.i!==1||t!=="length",enumerable:n.enumerable,value:o[t]}},defineProperty:function(){Z(11)},getPrototypeOf:function(r){return Object.getPrototypeOf(r.t)},setPrototypeOf:function(){Z(12)}},ut={};we(ft,function(r,t){ut[r]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),ut.deleteProperty=function(r,t){return ut.set.call(this,r,t,void 0)},ut.set=function(r,t,o){return ft.set.call(this,r[0],t,o,r[0])};var ls=function(){function r(o){var n=this;this.O=On,this.D=!0,this.produce=function(i,s,c){if(typeof i=="function"&&typeof s!="function"){var d=s;s=i;var u=n;return function(S){var N=this;S===void 0&&(S=d);for(var A=arguments.length,I=Array(A>1?A-1:0),k=1;k<A;k++)I[k-1]=arguments[k];return u.produce(S,function(_){var M;return(M=s).call.apply(M,[N,_].concat(I))})}}var p;if(typeof s!="function"&&Z(6),c!==void 0&&typeof c!="function"&&Z(7),J(i)){var y=mn(n),h=Ar(n,i,void 0),g=!0;try{p=s(h),g=!1}finally{g?Dt(y):wr(y)}return typeof Promise<"u"&&p instanceof Promise?p.then(function(S){return vr(y,c),Sr(S,y)},function(S){throw Dt(y),S}):(vr(y,c),Sr(p,y))}if(!i||typeof i!="object"){if((p=s(i))===void 0&&(p=i),p===In&&(p=void 0),n.D&&_r(p,!0),c){var v=[],b=[];oe("Patches").M(i,p,v,b),c(v,b)}return p}Z(21,i)},this.produceWithPatches=function(i,s){if(typeof i=="function")return function(p){for(var y=arguments.length,h=Array(y>1?y-1:0),g=1;g<y;g++)h[g-1]=arguments[g];return n.produceWithPatches(p,function(v){return i.apply(void 0,[v].concat(h))})};var c,d,u=n.produce(i,s,function(p,y){c=p,d=y});return typeof Promise<"u"&&u instanceof Promise?u.then(function(p){return[p,c,d]}):[u,c,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){J(o)||Z(8),se(o)&&(o=as(o));var n=mn(this),i=Ar(this,o,void 0);return i[L].C=!0,wr(n),i},t.finishDraft=function(o,n){var i=o&&o[L],s=i.A;return vr(s,n),Sr(void 0,s)},t.setAutoFreeze=function(o){this.D=o},t.setUseProxies=function(o){o&&!On&&Z(20),this.O=o},t.applyPatches=function(o,n){var i;for(i=n.length-1;i>=0;i--){var s=n[i];if(s.path.length===0&&s.op==="replace"){o=s.value;break}}i>-1&&(n=n.slice(i+1));var c=oe("Patches").$;return se(o)?c(o,n):this.produce(o,function(d){return c(d,n)})},r}(),V=new ls,ds=V.produce,cl=V.produceWithPatches.bind(V),ll=V.setAutoFreeze.bind(V),dl=V.setUseProxies.bind(V),ul=V.applyPatches.bind(V),pl=V.createDraft.bind(V),fl=V.finishDraft.bind(V),Mt=ds;function Ae(r){"@babel/helpers - typeof";return Ae=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},Ae(r)}function Nn(r,t){if(Ae(r)!="object"||!r)return r;var o=r[Symbol.toPrimitive];if(o!==void 0){var n=o.call(r,t||"default");if(Ae(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(r)}function Tn(r){var t=Nn(r,"string");return Ae(t)=="symbol"?t:t+""}function _n(r,t,o){return(t=Tn(t))in r?Object.defineProperty(r,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[t]=o,r}function Pn(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 Lr(r){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?Pn(Object(o),!0).forEach(function(n){_n(r,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):Pn(Object(o)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(o,n))})}return r}function j(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 kn=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),Fr=function(){return Math.random().toString(36).substring(7).split("").join(".")},Wt={INIT:"@@redux/INIT"+Fr(),REPLACE:"@@redux/REPLACE"+Fr(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Fr()}};function us(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 Dr(r,t,o){var n;if(typeof t=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(j(0));if(typeof t=="function"&&typeof o>"u"&&(o=t,t=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(j(1));return o(Dr)(r,t)}if(typeof r!="function")throw new Error(j(2));var i=r,s=t,c=[],d=c,u=!1;function p(){d===c&&(d=c.slice())}function y(){if(u)throw new Error(j(3));return s}function h(S){if(typeof S!="function")throw new Error(j(4));if(u)throw new Error(j(5));var N=!0;return p(),d.push(S),function(){if(N){if(u)throw new Error(j(6));N=!1,p();var I=d.indexOf(S);d.splice(I,1),c=null}}}function g(S){if(!us(S))throw new Error(j(7));if(typeof S.type>"u")throw new Error(j(8));if(u)throw new Error(j(9));try{u=!0,s=i(s,S)}finally{u=!1}for(var N=c=d,A=0;A<N.length;A++){var I=N[A];I()}return S}function v(S){if(typeof S!="function")throw new Error(j(10));i=S,g({type:Wt.REPLACE})}function b(){var S,N=h;return S={subscribe:function(I){if(typeof I!="object"||I===null)throw new Error(j(11));function k(){I.next&&I.next(y())}k();var _=N(k);return{unsubscribe:_}}},S[kn]=function(){return this},S}return g({type:Wt.INIT}),n={dispatch:g,subscribe:h,getState:y,replaceReducer:v},n[kn]=b,n}function ps(r){Object.keys(r).forEach(function(t){var o=r[t],n=o(void 0,{type:Wt.INIT});if(typeof n>"u")throw new Error(j(12));if(typeof o(void 0,{type:Wt.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(j(13))})}function Ln(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 s=Object.keys(o),c,d;try{ps(o)}catch(u){d=u}return function(p,y){if(p===void 0&&(p={}),d)throw d;if(0)var h;for(var g=!1,v={},b=0;b<s.length;b++){var S=s[b],N=o[S],A=p[S],I=N(A,y);if(typeof I>"u"){var k=y&&y.type;throw new Error(j(14))}v[S]=I,g=g||I!==A}return g=g||s.length!==Object.keys(p).length,g?v:p}}function ze(){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 Fn(){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),s=function(){throw new Error(j(15))},c={getState:i.getState,dispatch:function(){return s.apply(void 0,arguments)}},d=t.map(function(u){return u(c)});return s=ze.apply(void 0,d)(i.dispatch),Lr(Lr({},i),{},{dispatch:s})}}}function Dn(r){var t=function(n){var i=n.dispatch,s=n.getState;return function(c){return function(d){return typeof d=="function"?d(i,s,r):c(d)}}};return t}var Un=Dn();Un.withExtraArgument=Dn;var Ur=Un;var zn=function(){var r=function(t,o){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var s in i)Object.prototype.hasOwnProperty.call(i,s)&&(n[s]=i[s])},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)}}(),fs=function(r,t){var o={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},n,i,s,c;return c={next:d(0),throw:d(1),return:d(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function d(p){return function(y){return u([p,y])}}function u(p){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,i&&(s=p[0]&2?i.return:p[0]?i.throw||((s=i.return)&&s.call(i),0):i.next)&&!(s=s.call(i,p[1])).done)return s;switch(i=0,s&&(p=[p[0]&2,s.value]),p[0]){case 0:case 1:s=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(s=o.trys,!(s=s.length>0&&s[s.length-1])&&(p[0]===6||p[0]===2)){o=0;continue}if(p[0]===3&&(!s||p[1]>s[0]&&p[1]<s[3])){o.label=p[1];break}if(p[0]===6&&o.label<s[1]){o.label=s[1],s=p;break}if(s&&o.label<s[2]){o.label=s[2],o.ops.push(p);break}s[2]&&o.ops.pop(),o.trys.pop();continue}p=t.call(r,o)}catch(y){p=[6,y],i=0}finally{n=s=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},je=function(r,t){for(var o=0,n=t.length,i=r.length;o<n;o++,i++)r[i]=t[o];return r},hs=Object.defineProperty,ys=Object.defineProperties,gs=Object.getOwnPropertyDescriptors,Bn=Object.getOwnPropertySymbols,ms=Object.prototype.hasOwnProperty,bs=Object.prototype.propertyIsEnumerable,Mn=function(r,t,o){return t in r?hs(r,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):r[t]=o},he=function(r,t){for(var o in t||(t={}))ms.call(t,o)&&Mn(r,o,t[o]);if(Bn)for(var n=0,i=Bn(t);n<i.length;n++){var o=i[n];bs.call(t,o)&&Mn(r,o,t[o])}return r},Br=function(r,t){return ys(r,gs(t))},xs=function(r,t,o){return new Promise(function(n,i){var s=function(u){try{d(o.next(u))}catch(p){i(p)}},c=function(u){try{d(o.throw(u))}catch(p){i(p)}},d=function(u){return u.done?n(u.value):Promise.resolve(u.value).then(s,c)};d((o=o.apply(r,t)).next())})};var vs=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?ze:ze.apply(null,arguments)},_l=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(r){return r}};function Ss(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 Os=function(r){zn(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,je([void 0],o[0].concat(this)))):new(t.bind.apply(t,je([void 0],o.concat(this))))},t}(Array),Cs=function(r){zn(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,je([void 0],o[0].concat(this)))):new(t.bind.apply(t,je([void 0],o.concat(this))))},t}(Array);function Hr(r){return J(r)?Mt(r,function(){}):r}function Es(r){return typeof r=="boolean"}function ws(){return function(t){return As(t)}}function As(r){r===void 0&&(r={});var t=r.thunk,o=t===void 0?!0:t,n=r.immutableCheck,i=n===void 0?!0:n,s=r.serializableCheck,c=s===void 0?!0:s,d=new Os;if(o&&(Es(o)?d.push(Ur):d.push(Ur.withExtraArgument(o.extraArgument))),0){if(i)var u;if(c)var p}return d}var Mr=!0;function jn(r){var t=ws(),o=r||{},n=o.reducer,i=n===void 0?void 0:n,s=o.middleware,c=s===void 0?t():s,d=o.devTools,u=d===void 0?!0:d,p=o.preloadedState,y=p===void 0?void 0:p,h=o.enhancers,g=h===void 0?void 0:h,v;if(typeof i=="function")v=i;else if(Ss(i))v=Ln(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=c;if(typeof b=="function"&&(b=b(t),!Mr&&!Array.isArray(b)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!Mr&&b.some(function(_){return typeof _!="function"}))throw new Error("each middleware provided to configureStore must be a function");var S=Fn.apply(void 0,b),N=ze;u&&(N=vs(he({trace:!Mr},typeof u=="object"&&u)));var A=new Cs(S),I=A;Array.isArray(g)?I=je([S],g):typeof g=="function"&&(I=g(A));var k=N.apply(void 0,I);return Dr(v,y,k)}function ye(r,t){function o(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];if(t){var s=t.apply(void 0,n);if(!s)throw new Error("prepareAction did not return an object");return he(he({type:r,payload:s.payload},"meta"in s&&{meta:s.meta}),"error"in s&&{error:s.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 $n(r){var t={},o=[],n,i={addCase:function(s,c){var d=typeof s=="string"?s:s.type;if(d in t)throw new Error("addCase cannot be called with two reducers for the same action type");return t[d]=c,i},addMatcher:function(s,c){return o.push({matcher:s,reducer:c}),i},addDefaultCase:function(s){return n=s,i}};return r(i),[t,o,n]}function Is(r){return typeof r=="function"}function Rs(r,t,o,n){o===void 0&&(o=[]);var i=typeof t=="function"?$n(t):[t,o,n],s=i[0],c=i[1],d=i[2],u;if(Is(r))u=function(){return Hr(r())};else{var p=Hr(r);u=function(){return p}}function y(h,g){h===void 0&&(h=u());var v=je([s[g.type]],c.filter(function(b){var S=b.matcher;return S(g)}).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(se(b)){var N=b,A=S(N,g);return A===void 0?b:A}else{if(J(b))return Mt(b,function(I){return S(I,g)});var A=S(b,g);if(A===void 0){if(b===null)return b;throw Error("A case reducer on a non-draftable value must not return undefined")}return A}return b},h)}return y.getInitialState=u,y}function Ns(r,t){return r+"/"+t}function Gn(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),s={},c={},d={};i.forEach(function(y){var h=n[y],g=Ns(t,y),v,b;"reducer"in h?(v=h.reducer,b=h.prepare):v=h,s[y]=v,c[g]=v,d[y]=b?ye(g,b):ye(g)});function u(){var y=typeof r.extraReducers=="function"?$n(r.extraReducers):[r.extraReducers],h=y[0],g=h===void 0?{}:h,v=y[1],b=v===void 0?[]:v,S=y[2],N=S===void 0?void 0:S,A=he(he({},g),c);return Rs(o,function(I){for(var k in A)I.addCase(k,A[k]);for(var _=0,M=b;_<M.length;_++){var Q=M[_];I.addMatcher(Q.matcher,Q.reducer)}N&&I.addDefaultCase(N)})}var p;return{name:t,reducer:function(y,h){return p||(p=u()),p(y,h)},actions:d,caseReducers:s,getInitialState:function(){return p||(p=u()),p.getInitialState()}}}var Ts="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",_s=function(r){r===void 0&&(r=21);for(var t="",o=r;o--;)t+=Ts[Math.random()*64|0];return t},Ps=["name","message","stack","code"],Wr=function(){function r(t,o){this.payload=t,this.meta=o}return r}(),Wn=function(){function r(t,o){this.payload=t,this.meta=o}return r}(),ks=function(r){if(typeof r=="object"&&r!==null){for(var t={},o=0,n=Ps;o<n.length;o++){var i=n[o];typeof r[i]=="string"&&(t[i]=r[i])}return t}return{message:String(r)}},Fl=function(){function r(t,o,n){var i=ye(t+"/fulfilled",function(y,h,g,v){return{payload:y,meta:Br(he({},v||{}),{arg:g,requestId:h,requestStatus:"fulfilled"})}}),s=ye(t+"/pending",function(y,h,g){return{payload:void 0,meta:Br(he({},g||{}),{arg:h,requestId:y,requestStatus:"pending"})}}),c=ye(t+"/rejected",function(y,h,g,v,b){return{payload:v,error:(n&&n.serializeError||ks)(y||"Rejected"),meta:Br(he({},b||{}),{arg:g,requestId:h,rejectedWithValue:!!v,requestStatus:"rejected",aborted:y?.name==="AbortError",condition:y?.name==="ConditionError"})}}),d=!1,u=typeof AbortController<"u"?AbortController:function(){function y(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return y.prototype.abort=function(){},y}();function p(y){return function(h,g,v){var b=n?.idGenerator?n.idGenerator(y):_s(),S=new u,N,A=!1;function I(_){N=_,S.abort()}var k=function(){return xs(this,null,function(){var _,M,Q,ve,$,Se,ke;return fs(this,function(f){switch(f.label){case 0:return f.trys.push([0,4,,5]),ve=(_=n?.condition)==null?void 0:_.call(n,y,{getState:g,extra:v}),Fs(ve)?[4,ve]:[3,2];case 1:ve=f.sent(),f.label=2;case 2:if(ve===!1||S.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return A=!0,$=new Promise(function(m,E){return S.signal.addEventListener("abort",function(){return E({name:"AbortError",message:N||"Aborted"})})}),h(s(b,y,(M=n?.getPendingMeta)==null?void 0:M.call(n,{requestId:b,arg:y},{getState:g,extra:v}))),[4,Promise.race([$,Promise.resolve(o(y,{dispatch:h,getState:g,extra:v,requestId:b,signal:S.signal,abort:I,rejectWithValue:function(m,E){return new Wr(m,E)},fulfillWithValue:function(m,E){return new Wn(m,E)}})).then(function(m){if(m instanceof Wr)throw m;return m instanceof Wn?i(m.payload,b,y,m.meta):i(m,b,y)})])];case 3:return Q=f.sent(),[3,5];case 4:return Se=f.sent(),Q=Se instanceof Wr?c(null,b,y,Se.payload,Se.meta):c(Se,b,y),[3,5];case 5:return ke=n&&!n.dispatchConditionRejection&&c.match(Q)&&Q.meta.condition,ke||h(Q),[2,Q]}})})}();return Object.assign(k,{abort:I,requestId:b,arg:y,unwrap:function(){return k.then(Ls)}})}}return Object.assign(p,{pending:s,rejected:c,fulfilled:i,typePrefix:t})}return r.withTypes=function(){return r},r}();function Ls(r){if(r.meta&&r.meta.rejectedWithValue)throw r.payload;if(r.error)throw r.error;return r.payload}function Fs(r){return r!==null&&typeof r=="object"&&typeof r.then=="function"}var Kn="listener",Vn="completed",Zn="cancelled",Dl="task-"+Zn,Ul="task-"+Vn,Bl=Kn+"-"+Zn,Ml=Kn+"-"+Vn;var zr="listenerMiddleware";var Wl=ye(zr+"/add"),Hl=ye(zr+"/removeAll"),zl=ye(zr+"/remove");var Hn,jl=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(r){return(Hn||(Hn=Promise.resolve())).then(r).catch(function(t){return setTimeout(function(){throw t},0)})},Ds=function(r){return function(t){setTimeout(t,r)}},$l=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Ds(10);An();function Us(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 Ht=class extends Us(Object){};window.ftReduxStores||(window.ftReduxStores={});var qn=class r extends Ht{static get(t){var o;let n=typeof t=="string"?t:t.name,i=typeof t=="string"?void 0:t,s=window.ftReduxStores[n];if(ct(s))return s;if(i==null)return;let c=Gn({...i,reducers:(o=i.reducers)!==null&&o!==void 0?o:{}}),d=jn({reducer:(u,p)=>p.type==="CLEAR_FT_REDUX_STORE"?c.getInitialState():typeof p.type=="string"&&p.type.startsWith("DEFAULT_VALUE_SETTER__")?{...u,...p.overwrites}:c.reducer(u,p)});return window.ftReduxStores[i.name]=new r(c,d,i.eventBus)}constructor(t,o,n){super(),this.reduxSlice=t,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new Pt;let i=s=>s!=null?JSON.parse(JSON.stringify(s)):s;this.actions=new Proxy(this.reduxSlice.actions,{get:(s,c,d)=>{let u=c,p=s[u];return p?(...y)=>{let h=p(...y.map(i));return this.reduxStore.dispatch(h),h}:y=>{this.setState({[u]:i(y)})}}}),this.eventBus=n??this.eventBus}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 Gt=O(T());var zt=class extends ae{async listMySearches(){let{session:t}=w.getState();return Xo(t,B.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(t.profile.userId),5*60*1e3):[]}};var jt=class extends ae{async listMyBookmarks(){let t=w.getState().session;return t?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(t.profile.userId),5*60*1e3):[]}};var Ms="ft-user-assets",$t=Gt.FtReduxStore.get({name:Ms,initialState:{savedSearches:void 0,bookmarks:void 0}}),jr=class{constructor(){this.currentSession=w.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new jt,this.savedSearchesService=new zt,w.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var t;let{session:o}=w.getState();(0,Gt.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(),$t.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),$t.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let t=await this.savedSearchesService.listMySearches();$t.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;$t.actions.bookmarks(o)}}},Ad=new jr;var $r=class{addCommand(t,o=!1){w.commands.add(t,o)}consumeCommand(t){return w.commands.consume(t)}};window.FluidTopicsAppInfoStoreService=new $r;var Yn=O(T()),Gr=class{highlightHtml(t,o,n){(0,Yn.highlightHtml)(t,o,n)}};window.FluidTopicsHighlightHtmlService=new Gr;var Qn=O(T());var Kr=class{isDate(t){var o,n,i,s;return(s=(i=((n=(o=w.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&&s!==void 0?s:!1}format(t,o){var n,i,s;return Qn.DateFormatter.format(t,(n=o?.locale)!==null&&n!==void 0?n:w.getState().uiLocale,(i=o?.longFormat)!==null&&i!==void 0?i:!1,(s=o?.withTime)!==null&&s!==void 0?s:!1)}};window.FluidTopicsDateService=new Kr;var Xn=O(T());var ht=class{static get(t,o){var n,i,s,c;let d=w.getState(),{lang:u,region:p}=(i=(n=d.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&i!==void 0?i:{lang:"en",region:"US"};return new Xn.SearchPlaceConverter(d.baseUrl,(c=(s=window.FluidTopicsClientConfiguration)===null||s===void 0?void 0:s.predefinedSorts)!==null&&c!==void 0?c:{},t??20,d.searchInAllLanguagesAllowed,o??`${u}-${p}`)}};var Vr=class{urlToSearchRequest(t){return ht.get().parse(t)}searchRequestToUrl(t){return ht.get().serialize(t)}};window.FluidTopicsUrlService=new Vr;var ge=O(T());var Ie=class r extends CustomEvent{constructor(t){super(r.eventName,{detail:{currentItem:t}})}};Ie.eventName="change";var Zr=class{itemName(t){return`fluid-topics-history-item-${t}`}get(t){let o=sessionStorage.getItem(this.itemName(t));return o?JSON.parse(o):void 0}set(t,o){sessionStorage.setItem(this.itemName(t),JSON.stringify(o))}},Jn=new Zr;var Kt=class r extends ge.WithEventBus{static build(){return new r(window.history,Jn,()=>window.location,!1)}constructor(t,o,n,i){var s,c;super(),this.history=t,this.historyStorage=o,this.windowLocation=n,this.states=[],this.realPushState=t.pushState,this.realReplaceState=t.replaceState,this.initialIndex=(c=(s=t.state)===null||s===void 0?void 0:s.index)!==null&&c!==void 0?c:t.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(i)}setCurrentState(t,o=!1){let n=o&&this.currentIndex===t.index-1;this.currentState={...this.buildCurrentState(),...t},this.currentIndex=this.currentState.index,this.states[this.currentIndex]=this.currentState,n&&(this.states=this.states.slice(0,this.currentIndex+1)),this.historyStorage.set(this.currentIndex,this.currentState),(0,ge.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,window.location.href]),setTimeout(()=>this.dispatchEvent(new Ie(this.currentItem())),0)}installProxies(){let t=o=>(n,i,[s,c,d])=>{let u=o(),p={...u===this.currentIndex?this.currentState:void 0,...s,index:u,href:typeof d=="string"?d:(d??this.windowLocation()).href};n.apply(i,[p,c,d]),this.setCurrentState(p,!0)};this.history.pushState=new Proxy(this.history.pushState,{apply:t(()=>this.currentIndex+1)}),this.history.replaceState=new Proxy(this.history.replaceState,{apply:t(()=>this.currentIndex)})}initEventListeners(){window.addEventListener("popstate",t=>this.setCurrentState(t.state)),document.querySelector("title")==null&&document.head.append(document.createElement("title")),new MutationObserver(()=>this.updateCurrentState({title:document.title})).observe(document.querySelector("title"),{subtree:!0,characterData:!0,childList:!0})}initData(t){for(let o=this.history.length-1;o>=0;o--)t?this.states[o]=this.historyStorage.get(o):setTimeout(()=>this.states[o]=this.historyStorage.get(o),this.history.length-o)}updateCurrentState(t,o=!1){var n,i,s;let c={...this.buildCurrentState(),...t,index:this.currentIndex,title:(n=t?.title)!==null&&n!==void 0?n:this.currentState.title},d=o?(i=t?.majorState)!==null&&i!==void 0?i:this.currentState.majorState:(s=this.currentState.majorState)!==null&&s!==void 0?s:t?.majorState;d!=null&&(c.majorState=d),this.setCurrentState(c)}addHistoryChangeListener(t){this.addEventListener(Ie.eventName,t)}removeHistoryChangeListener(t){this.removeEventListener(Ie.eventName,t)}currentItem(){return(0,ge.deepCopy)(this.currentState)}back(){let t=this.previousMajorPosition();t>=0?this.history.go(t-this.currentIndex):this.currentIndex!==this.initialIndex?this.history.go(this.initialIndex-this.currentIndex):this.history.back()}backwardItem(){return(0,ge.deepCopy)(this.states[this.previousMajorPosition()])}previousMajorPosition(){let t=this.currentIndex;for(;t>0&&!this.isMajorState(t);)t--;return this.previousExistingPosition(t)}forward(){let t=this.nextMajorPosition();t<this.states.length?this.history.go(t-this.currentIndex):this.history.forward()}forwardItem(){return(0,ge.deepCopy)(this.states[this.nextMajorPosition()])}nextMajorPosition(){let t=this.currentIndex;do t++;while(t<this.states.length&&!this.isMajorState(t));do t++;while(t<this.states.length&&!this.isMajorState(t));return this.previousExistingPosition(t)}previousExistingPosition(t){let o=t;do o--;while(o>0&&!this.hasState(o));return o}buildCurrentState(){var t,o;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(o=(t=this.history.state)===null||t===void 0?void 0:t.title)!==null&&o!==void 0?o:document.title}}hasState(t){return this.states[t]!=null}isMajorState(t){var o,n;return this.hasState(t)&&((n=(o=this.states[t])===null||o===void 0?void 0:o.majorState)!==null&&n!==void 0?n:!0)}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=Kt.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),addHistoryChangeListener:r=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(r),removeHistoryChangeListener:r=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(r)});(0,ea.customElement)("ft-app-context")(D);var qr=class r extends Event{constructor(){super(r.eventName)}};qr.eventName="search-context-clear-all-filters";var Ws=function(r,t,o,n){var i=arguments.length,s=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,c;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")s=Reflect.decorate(r,t,o,n);else for(var d=r.length-1;d>=0;d--)(c=r[d])&&(s=(i<3?c(s):i>3?c(t,o,s):c(t,o))||s);return i>3&&s&&Object.defineProperty(t,o,s),s},Qr=class extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}},ta=Symbol("registerInterval"),Yr=Symbol("registerAttempts"),Hs=40;function zs(r){class t extends r{setSearchStateManager(n){this.clearStateManager(),this.stateManager=n,this.addStore(n.store,"search")}clearStateManager(){this.stateManager&&(this.removeStore(this.stateManager.store),this.stateManager=void 0)}connectedCallback(){super.connectedCallback(),this[Yr]=0,this[ta]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null||this[Yr]>Hs?window.clearInterval(this[ta]):(this[Yr]++,this.dispatchEvent(new Qr))}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return Ws([(0,oa.state)()],t.prototype,"stateManager",void 0),t}var $e=class extends zs(ra.FtLitElementRedux){};var ca=O(T());var ia=O(H()),Ge=O(G()),sa=O(T());var na=O(H());var aa=na.css`
|