@fluid-topics/ft-search-selected-facets 1.3.27 → 1.3.28
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.
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
`;var In=h(A()),vl=h(j());var Qe=h(A());var Qo=h(A()),jp={setRequest:(t,e)=>{t.request=e.payload},setRequestQuery:(t,e)=>{t.request.query=e.payload},setRequestContentLocale:(t,e)=>{t.request.contentLocale=e.payload},setPageSize:(t,e)=>{var o;let n=+((o=e.payload)!==null&&o!==void 0?o:20);t.request.paging.perPage=isNaN(n)?20:(0,Qo.minmax)(1,n,1e3)},setPageNumber:(t,e)=>{t.request.paging.page=isNaN(e.payload)?1:Math.max(1,e.payload)},setRequestSort:(t,e)=>{t.request.sort=e.payload},setRequestSortId:(t,e)=>{t.request.sortId=e.payload},setRequestFilters:(t,e)=>{t.request.metadataFilters=e.payload},setRequestFacets:(t,e)=>{t.request.facets=e.payload},setRequestVirtualField:(t,e)=>{t.request.virtualField=e.payload},setRequestScope:(t,e)=>{t.request.scope=e.payload},setOtherQueryParams:(t,e)=>{t.request.otherQueryParams=e.payload},setRequestClusterSortCriterion:(t,e)=>{var o;t.request.clusterSortCriterions=(o=e.payload)!==null&&o!==void 0?o:[]}},Ha=t=>Qo.FtReduxStore.get({name:"ft-search-"+t,initialState:{request:{query:"",clusterSortCriterions:[],metadataFilters:[],facets:[],sort:[],sortId:void 0,paging:{page:1,perPage:20}},liveQuery:"",paging:void 0,facets:void 0,spellcheck:void 0,locales:[],results:void 0,announcements:void 0,suggestResults:void 0,configuration:void 0},reducers:jp});var Zp=h(Ga(),1);var Va;(function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"})(Va||(Va={}));var ja;(function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"})(ja||(ja={}));var Ka;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(Ka||(Ka={}));var Mr;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(Mr||(Mr={}));var Za;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(Za||(Za={}));var qa;(function(t){t.VALUE="VALUE",t.DATE="DATE",t.RANGE="RANGE"})(qa||(qa={}));var mr;(function(t){t.BOOKMARK__CREATE="BOOKMARK__CREATE",t.BOOKMARK__DELETE="BOOKMARK__DELETE",t.CASE_DEFLECTION__START="CASE_DEFLECTION__START",t.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",t.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",t.COLLECTION__CREATE="COLLECTION__CREATE",t.COLLECTION__UPDATE="COLLECTION__UPDATE",t.COLLECTION__DELETE="COLLECTION__DELETE",t.CUSTOM_EVENT__TRIGGER="CUSTOM_EVENT__TRIGGER",t.DOCUMENT__DISPLAY="DOCUMENT__DISPLAY",t.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",t.DOCUMENT__PRINT="DOCUMENT__PRINT",t.DOCUMENT__PROCESS="DOCUMENT__PROCESS",t.DOCUMENT__RATE="DOCUMENT__RATE",t.DOCUMENT__SEARCH="DOCUMENT__SEARCH",t.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",t.DOCUMENT__UNRATE="DOCUMENT__UNRATE",t.FEEDBACK__SEND="FEEDBACK__SEND",t.AI__COMPLETED_QUERY="AI__COMPLETED_QUERY",t.AI__RATE="AI__RATE",t.AI_CASE_DEFLECTION__START="AI_CASE_DEFLECTION__START",t.AI_CASE_DEFLECTION__OPEN_TICKET="AI_CASE_DEFLECTION__OPEN_TICKET",t.KHUB__PROCESS="KHUB__PROCESS",t.KHUB__SEARCH="KHUB__SEARCH",t.LABELS__DOWNLOAD="LABELS__DOWNLOAD",t.LINK__SHARE="LINK__SHARE",t.PAGE__DISPLAY="PAGE__DISPLAY",t.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",t.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",t.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",t.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",t.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",t.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",t.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",t.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",t.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",t.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",t.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",t.TOPIC__DISPLAY="TOPIC__DISPLAY",t.TOPIC__RATE="TOPIC__RATE",t.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",t.TOPIC__UNRATE="TOPIC__UNRATE",t.USER__LOGIN="USER__LOGIN",t.USER__LOGOUT="USER__LOGOUT",t.HEARTBEAT="HEARTBEAT"})(mr||(mr={}));var Ya;(function(t){t.THIRD_PARTY="THIRD_PARTY",t.OFF_THE_GRID="OFF_THE_GRID",t.CONTENT_PACKAGER="CONTENT_PACKAGER",t.PAGES="PAGES",t.DESIGNED_READER="DESIGNED_READER"})(Ya||(Ya={}));var Qa;(function(t){t.HOMEPAGE="HOMEPAGE",t.CUSTOM="CUSTOM",t.HEADER="HEADER",t.READER="READER",t.TOPIC_TEMPLATE="TOPIC_TEMPLATE",t.SEARCH="SEARCH",t.SEARCH_RESULT="SEARCH_RESULT",t.SEARCH_ANNOUNCEMENT="SEARCH_ANNOUNCEMENT"})(Qa||(Qa={}));var Xa;(function(t){t.CLASSIC="CLASSIC",t.CUSTOM="CUSTOM",t.DESIGNER="DESIGNER"})(Xa||(Xa={}));var Ja;(function(t){t.AND="AND",t.OR="OR",t.MONOVALUED="MONOVALUED"})(Ja||(Ja={}));var es;(function(t){t.NONE="NONE",t.ALPHABET="ALPHABET",t.VERSION="VERSION"})(es||(es={}));var ts;(function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"})(ts||(ts={}));var rs;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"})(rs||(rs={}));var os;(function(t){t.ASC="ASC",t.DESC="DESC"})(os||(os={}));var ns;(function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"})(ns||(ns={}));var Ur;(function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"})(Ur||(Ur={}));var is;(function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(is||(is={}));var as;(function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"})(as||(as={}));var ss;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK"})(ss||(ss={}));var en;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(en||(en={}));var Ut;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC"})(Ut||(Ut={}));var zr;(function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS",t.ALL_TOPICS="ALL_TOPICS",t.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(zr||(zr={}));var ls;(function(t){t.PLAIN_TEXT="PLAIN_TEXT",t.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",t.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(ls||(ls={}));var ue;(function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.GENERATIVE_AI_USER="GENERATIVE_AI_USER",t.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.ANNOUNCEMENT_ADMIN="ANNOUNCEMENT_ADMIN",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN"})(ue||(ue={}));var gr;(function(t){t.SEARCHES="SEARCHES",t.BOOKMARKS="BOOKMARKS",t.BOOKS="BOOKS",t.COLLECTIONS="COLLECTIONS"})(gr||(gr={}));var cs;(function(t){t.VALID="VALID",t.INVALID="INVALID"})(cs||(cs={}));var ds;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(ds||(ds={}));var ps;(function(t){t.USER="USER",t.ASSISTANT="ASSISTANT"})(ps||(ps={}));var us;(function(t){t.TEXT="TEXT",t.HTML="HTML"})(us||(us={}));var Kp={[ue.PERSONAL_BOOK_SHARE_USER]:[ue.PERSONAL_BOOK_USER],[ue.HTML_EXPORT_USER]:[ue.PERSONAL_BOOK_USER],[ue.PDF_EXPORT_USER]:[ue.PERSONAL_BOOK_USER],[ue.KHUB_ADMIN]:[ue.CONTENT_PUBLISHER],[ue.ADMIN]:[ue.KHUB_ADMIN,ue.USERS_ADMIN,ue.PORTAL_ADMIN],[ue.GENERATIVE_AI_EXPORT_USER]:[ue.GENERATIVE_AI_USER]};function fs(t,e){return t===e||(Kp[t]??[]).some(o=>fs(o,e))}function hs(t,e){return t==null?!1:(Array.isArray(t)?t:Array.isArray(t.roles)?t.roles:Array.isArray(t.profile?.roles)?t.profile.roles:[]).some(n=>fs(n,e))}var bl=h(A());var Es=h(k()),Oe=h(j()),dt=h(A());var ys=h(k());var ms=ys.css`
|
|
13
13
|
`;var tn=h(A()),qp="ft-app-info",br=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};br.eventName="authentication-change";var Yp={session:(t,e)=>{(0,tn.deepEqual)(t.session,e.payload)||(t.session=e.payload,setTimeout(()=>T.dispatchEvent(new br(e.payload)),0))}},T=tn.FtReduxStore.get({name:qp,reducers:Yp,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],availableContentLocales:[],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,authenticationRequired:!1}});var fi=h(A());var xr=class t{static get(e){let{baseUrl:o,apiIntegrationIdentifier:n}=T.getState(),i=e??n;if(o&&i&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,i,!0)}static await(e){return new Promise(o=>{let n=t.get(e);if(n)o(n);else{let i=T.subscribe(()=>{n=t.get(e),n&&(i(),o(n))})}})}};var rn=class{constructor(e){this.overrideApi=e}get api(){var e;return(e=this.overrideApi)!==null&&e!==void 0?e:xr.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):xr.await()}};var Re=class extends rn{constructor(e=!0,o){var n;super(o),this.sortObjectFields=(a,s)=>typeof s!="object"||s==null||Array.isArray(s)?s:Object.fromEntries(Object.entries(s).sort(([c],[p])=>c.localeCompare(p)));let i=this.constructor;i.commonCache=(n=i.commonCache)!==null&&n!==void 0?n:new fi.CacheRegistry,this.cache=e?i.commonCache:new fi.CacheRegistry}clearCache(){this.cache.clearAll()}hash(e){return String(Array.from(JSON.stringify(e,this.sortObjectFields)).reduce((o,n)=>0|31*o+n.charCodeAt(0),0))}};var on=class extends Re{async listMyBookmarks(){let e=T.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),5*60*1e3):[]}};var hi=class{addCommand(e,o=!1){T.commands.add(e,o)}consumeCommand(e){return T.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new hi;var nt=h(A());var gs,Hr=class extends CustomEvent{constructor(e){super("ft-i18n-context-loaded",{detail:e})}},Qp=Symbol("clearAfterUnitTest"),nn=class extends(0,nt.withEventBus)(Re){constructor(e){super(),this.messageContextProvider=e,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[gs]=()=>{this.defaultMessages={},this.cache=new nt.CacheRegistry,this.listeners={}},this.currentUiLocale=T.getState().uiLocale,T.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:e}=T.getState();this.currentUiLocale!==e&&(this.currentUiLocale=e,this.cache.clearAll(),this.notifyAll())}addContext(e){let o=e.name.toLowerCase();this.cache.setFinal(o,e),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(e,o){var n;if(e=e.toLowerCase(),o&&Object.keys(o).length>0){let i={...(n=this.defaultMessages[e])!==null&&n!==void 0?n:{},...o};(0,nt.deepEqual)(this.defaultMessages[e],i)||(this.defaultMessages[e]=i,await this.notify(e))}return this.fetchContext(e)}resolveContext(e){var o,n;return this.fetchContext(e),(n=(o=this.cache.getNow(e))===null||o===void 0?void 0:o.messages)!==null&&n!==void 0?n:{}}resolveRawMessage(e,o){let n=e.toLowerCase();return this.resolveContext(n)[o]}resolveMessage(e,o,...n){var i;let a=e.toLowerCase(),s=this.resolveContext(a);return new nt.ParametrizedLabelResolver((i=this.defaultMessages[a])!==null&&i!==void 0?i:{},s).resolve(o,...n)}async fetchContext(e){let o=!this.cache.has(e),n;try{n=await this.cache.get(e,()=>this.messageContextProvider(this.currentUiLocale,e)),o&&await this.notify(e)}catch(i){!(i instanceof nt.CanceledPromiseError)&&o&&console.error(i)}return n}subscribe(e,o){var n;return e=e.toLowerCase(),this.listeners[e]=(n=this.listeners[e])!==null&&n!==void 0?n:new Set,this.listeners[e].add(o),()=>{var i;return(i=this.listeners[e])===null||i===void 0?void 0:i.delete(o)}}async notifyAll(){let e=Object.keys(this.listeners);document.body.dispatchEvent(new Hr({loadedContexts:e})),this.dispatchEvent(new Hr({loadedContexts:e})),await Promise.all(e.map(o=>this.notify(o,!1)))}async notify(e,o=!0){o&&(document.body.dispatchEvent(new Hr({loadedContexts:[e]})),this.dispatchEvent(new Hr({loadedContexts:[e]}))),this.listeners[e]!=null&&await Promise.all([...this.listeners[e].values()].map(n=>(0,nt.delay)(0).then(()=>n()).catch(()=>null)))}};gs=Qp;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends nn{constructor(){super(async(t,e)=>(await this.awaitApi).getFluidTopicsMessageContext(t,e))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends nn{constructor(){super(async(t,e)=>(await this.awaitApi).getCustomMessageContext(t,e))}});var Wr=window.FluidTopicsI18nService,an=window.FluidTopicsCustomI18nService;var bs=h(A()),yi=class{highlightHtml(e,o,n){(0,bs.highlightHtml)(e,o,n)}};window.FluidTopicsHighlightHtmlService=new yi;var sn=class extends Re{async listMySearches(){let{session:e}=T.getState();return hs(e,ue.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),5*60*1e3):[]}};var xs=h(A());var mi=class{isDate(e){var o,n,i,a;return(a=(i=((n=(o=T.getState().metadataConfiguration)===null||o===void 0?void 0:o.descriptors)!==null&&n!==void 0?n:[]).find(c=>c.key===e))===null||i===void 0?void 0:i.date)!==null&&a!==void 0?a:!1}format(e,o){var n,i,a;return xs.DateFormatter.format(e,(n=o?.locale)!==null&&n!==void 0?n:T.getState().uiLocale,(i=o?.longFormat)!==null&&i!==void 0?i:!1,(a=o?.withTime)!==null&&a!==void 0?a:!1)}};window.FluidTopicsDateService=new mi;var vs=h(A());var xo=class{static get(e,o){var n,i;let a=T.getState(),{lang:s,region:c}=(i=(n=a.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&i!==void 0?i:{lang:"en",region:"US"};return new vs.SearchPlaceConverter(a.baseUrl,e??20,a.searchInAllLanguagesAllowed,o??`${s}-${c}`)}};var ln=class extends Re{async sendDocumentStartDisplayEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.start_display event")}async sendTopicStartDisplayEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send topic.start_display event")}async sendKhubSearchEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send khub.search event")}async sendDocumentSearchEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.search event")}async sendSearchPageSelectEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send search_page.select event")}async sendSearchResultOpenContextMenuEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send search_result.open_context_menu event")}sortEventArrays(e){let o=Object.entries(e).map(([n,i])=>Array.isArray(i)?[n,i.map(a=>typeof a=="object"&&a!=null&&!Array.isArray(a)?this.sortEventArrays(a):a).sort((a,s)=>typeof a=="object"&&a!==null&&"key"in a?a.key.localeCompare(s.key):typeof a=="string"&&typeof s=="string"?a.localeCompare(s):String(a).localeCompare(String(s)))]:typeof i=="object"&&i!==null?[n,this.sortEventArrays(i)]:[n,i]);return Object.fromEntries(o)}sendEvents(e,o){let n="anything not undefined";return this.cache.get("analytics-event-"+this.hash(e),async()=>(await this.awaitApi).sendEvents(e).then(()=>n).catch(i=>(console.info(o),console.debug(i),n)),1e3)}};var gi=class{urlToSearchRequest(e){return xo.get().parse(e)}searchRequestToUrl(e){return xo.get().serialize(e)}};window.FluidTopicsUrlService=new gi;var zt=h(A());var vr=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{currentItem:e}})}};vr.eventName="change";var bi=class{itemName(e){return`fluid-topics-history-item-${e}`}get(e){let o=sessionStorage.getItem(this.itemName(e));return o?JSON.parse(o):void 0}set(e,o){sessionStorage.setItem(this.itemName(e),JSON.stringify(o))}},Ss=new bi;var cn=class t extends zt.WithEventBus{static build(){return new t(window.history,Ss,()=>window.location,!1)}constructor(e,o,n,i){var a,s;super(),this.history=e,this.historyStorage=o,this.windowLocation=n,this.states=[],this.realPushState=e.pushState,this.realReplaceState=e.replaceState,this.initialIndex=(s=(a=e.state)===null||a===void 0?void 0:a.index)!==null&&s!==void 0?s:e.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(i)}setCurrentState(e,o=!1){let n=o&&this.currentIndex===e.index-1;this.currentState={...this.buildCurrentState(),...e},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,zt.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,window.location.href]),setTimeout(()=>this.dispatchEvent(new vr(this.currentItem())),0)}installProxies(){let e=o=>(n,i,[a,s,c])=>{let p=o(),u={...p===this.currentIndex?this.currentState:void 0,...a,index:p,href:typeof c=="string"?c:(c??this.windowLocation()).href};n.apply(i,[u,s,c]),this.setCurrentState(u,!0)};this.history.pushState=new Proxy(this.history.pushState,{apply:e(()=>this.currentIndex+1)}),this.history.replaceState=new Proxy(this.history.replaceState,{apply:e(()=>this.currentIndex)})}initEventListeners(){window.addEventListener("popstate",e=>this.setCurrentState(e.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(e){for(let o=this.history.length-1;o>=0;o--)e?this.states[o]=this.historyStorage.get(o):setTimeout(()=>this.states[o]=this.historyStorage.get(o),this.history.length-o)}updateCurrentState(e){var o;let n={...this.buildCurrentState(),...e,index:this.currentIndex,title:(o=e?.title)!==null&&o!==void 0?o:this.currentState.title};this.setCurrentState(n)}addHistoryChangeListener(e){this.addEventListener(vr.eventName,e)}removeHistoryChangeListener(e){this.removeEventListener(vr.eventName,e)}currentItem(){return(0,zt.deepCopy)(this.currentState)}back(){let e=this.previousDifferentMajorPosition();e>=0?this.history.go(e-this.currentIndex):this.currentIndex!==this.initialIndex?this.history.go(this.initialIndex-this.currentIndex):this.history.back()}backwardItem(){return(0,zt.deepCopy)(this.states[this.previousDifferentMajorPosition()])}previousDifferentMajorPosition(){let e=this.currentIndex>0?this.currentIndex-1:0;for(;e>0&&!this.isDifferentMajorState(e);)e--;return e}forward(){let e=this.nextMajorPosition();e&&e<this.states.length?this.history.go(e-this.currentIndex):this.history.forward()}forwardItem(){let e=this.nextMajorPosition();if(e)return(0,zt.deepCopy)(this.states[e])}nextMajorPosition(){let e=this.currentIndex;if(!(e>=this.states.length)){do e++;while(e<this.states.length&&!this.isDifferentMajorState(e));return this.getHigherPositionInTheSameState(e)}}getHigherPositionInTheSameState(e){var o;let n=(o=this.states[e])===null||o===void 0?void 0:o.majorStateId;if(!n)return e;let i=e,a=e+1;for(;this.states.length>a&&!this.isDifferentMajorState(a,n);)this.hasState(a)&&(i=a),a++;return i}buildCurrentState(){var e,o;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(o=(e=this.history.state)===null||e===void 0?void 0:e.title)!==null&&o!==void 0?o:document.title}}hasState(e){return this.states[e]!=null}isDifferentMajorState(e,o){var n;if(!this.hasState(e))return!1;let i=o??this.currentState.majorStateId,a=(n=this.states[e])===null||n===void 0?void 0:n.majorStateId;return a==null||a!=i}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=cn.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),addHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(t),removeHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(t)});var Os=T;function Cs(t,e){var o;return Os.getState().authenticationRequired&&!(!((o=Os.getState().session)===null||o===void 0)&&o.sessionAuthenticated)?Promise.resolve(e):t()}var fe=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(s=t[c])&&(a=(i<3?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},Y=class extends dt.FtLitElement{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.apiIntegrationAppVersion="ft-integration-app-version",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=()=>xr.get(),this.authenticationRequired=!1,this.messageContexts=[],this.cache=new dt.CacheRegistry,this.cleanSessionDebouncer=new dt.Debouncer,this.reloadConfiguration=()=>{this.cache.clear("availableContentLocales"),this.updateAvailableContentLocales()}}render(){return Es.html`
|
|
14
14
|
<slot></slot>
|
|
15
|
-
`}connectedCallback(){super.connectedCallback(),T.addEventListener(br.eventName,this.reloadConfiguration)}disconnectedCallback(){T.addEventListener(br.eventName,this.reloadConfiguration),super.disconnectedCallback()}update(e){var o,n,i,a,s,c,p;super.update(e),e.has("baseUrl")&&(T.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),e.has("apiIntegrationIdentifier")&&T.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("apiIntegrationAppVersion")&&T.actions.apiIntegrationAppVersion(this.apiIntegrationAppVersion),e.has("uiLocale")&&T.actions.uiLocale(this.uiLocale),e.has("metadataConfiguration")&&T.actions.metadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&T.actions.noCustom(this.noCustom),e.has("editorMode")&&T.actions.editorMode(this.editorMode),e.has("noCustomComponent")&&T.actions.noCustomComponent(this.noCustomComponent),e.has("session")&&T.actions.session(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(u=>Wr.addContext(u)),e.has("openExternalDocumentInNewTab")&&T.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&T.actions.navigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&T.actions.forcedOffline(this.forcedOffline),e.has("localesConfiguration")&&(T.actions.defaultLocales((o=this.localesConfiguration)===null||o===void 0?void 0:o.defaultLocales),T.actions.availableUiLocales((i=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&i!==void 0?i:[]),T.actions.searchInAllLanguagesAllowed((s=(a=this.localesConfiguration)===null||a===void 0?void 0:a.allLanguagesAllowed)!==null&&s!==void 0?s:!1)),e.has("authenticationRequired")&&T.actions.authenticationRequired(this.authenticationRequired),e.has("availableContentLocales")&&T.actions.availableContentLocales((p=(c=this.availableContentLocales)===null||c===void 0?void 0:c.contentLocales)!==null&&p!==void 0?p:[]),setTimeout(()=>this.updateIfNeeded())}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.session==null&&this.updateSession(),this.metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration(),this.availableContentLocales==null&&this.updateAvailableContentLocales())}async updateSession(){this.session=await this.cache.get("session",async()=>{let e=await this.apiProvider().getCurrentSession();return e.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.session=void 0},e.idleTimeoutInMillis),e})}async updateMetadataConfiguration(){this.metadataConfiguration=await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration())}async updateLocalesConfiguration(){this.localesConfiguration=await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration())}async updateAvailableContentLocales(){this.availableContentLocales=await this.cache.get("availableContentLocales",()=>Cs(()=>this.apiProvider().getAvailableSearchLocales(),{contentLocales:[]}))}};Y.elementDefinitions={};Y.styles=ms;fe([(0,Oe.property)()],Y.prototype,"baseUrl",void 0);fe([(0,Oe.property)()],Y.prototype,"apiIntegrationIdentifier",void 0);fe([(0,Oe.property)()],Y.prototype,"apiIntegrationAppVersion",void 0);fe([(0,Oe.property)()],Y.prototype,"uiLocale",void 0);fe([(0,dt.jsonProperty)(null)],Y.prototype,"availableUiLocales",void 0);fe([(0,dt.jsonProperty)(null)],Y.prototype,"metadataConfiguration",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"editorMode",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"noCustom",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"openExternalDocumentInNewTab",void 0);fe([(0,Oe.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],Y.prototype,"noCustomComponent",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"withManualResources",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"navigatorOnline",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"forcedOffline",void 0);fe([(0,Oe.property)({type:Object})],Y.prototype,"apiProvider",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"authenticationRequired",void 0);fe([(0,dt.jsonProperty)([])],Y.prototype,"messageContexts",void 0);fe([(0,dt.jsonProperty)(void 0)],Y.prototype,"session",void 0);fe([(0,Oe.state)()],Y.prototype,"localesConfiguration",void 0);fe([(0,Oe.state)()],Y.prototype,"availableContentLocales",void 0);var Wi=h(j());function Xp(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;let o,n,i;if(Array.isArray(t)){if(o=t.length,o!=e.length)return!1;for(n=o;n--!==0;)if(!dn(t[n],e[n]))return!1;return!0}if(t instanceof Map&&e instanceof Map){if(t.size!==e.size)return!1;for(n of t.entries())if(!e.has(n[0]))return!1;for(n of t.entries())if(!dn(n[1],e.get(n[0])))return!1;return!0}if(t instanceof Set&&e instanceof Set){if(t.size!==e.size)return!1;for(n of t.entries())if(!e.has(n[0]))return!1;return!0}if(t.constructor===RegExp)return t.source===e.source&&t.flags===e.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===e.valueOf();let a=s=>Object.keys(s).filter(c=>s[c]!=null);if(i=a(t),o=i.length,o!==a(e).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(e,i[n]))return!1;for(n=o;n--!==0;){let s=i[n];if(!dn(t[s],e[s]))return!1}return!0}return t!==t&&e!==e||t==null&&e==null}function dn(t,e){try{return Xp(t,e)}catch{return!1}}function vo(t,e){return!dn(t,e)}function pn(t,e){let o=n=>n[t]===!0;return n=>{if(o(n))return n;let i=e(n);return i[t]=!0,i}}var As=h(j(),1);var xi=t=>{let e=t??{};return(o,n)=>{var i;let a={hasChanged:vo,attribute:!1,...e};(0,As.property)(a)(o,n);let s=o.constructor;s.reduxProperties=new Map(s.reduxProperties),s.reduxProperties.set(n,{selector:(i=e.selector)!==null&&i!==void 0?i:c=>c[n],store:e.store})}};var un=class{constructor(){this.queue=[]}add(e,o=!1){o&&this.clear(e.type),this.queue.push(e)}consume(e){let o=this.queue.find(n=>n.type===e);return o&&(this.queue=this.queue.filter(n=>n!==o)),o}clear(e){typeof e=="string"?this.queue=this.queue.filter(o=>o.type!==e):this.queue=this.queue.filter(o=>!e.test(o.type))}};var Gr=h(j(),1);var ws=h(j(),1);function Rs(t,e){let o=()=>JSON.parse(JSON.stringify(t));return(0,ws.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:vo,...e??{}})}var fn=class{constructor(e=0){this.timeout=e,this.callbacks=[]}run(e,o){return this.callbacks=[e],this.debounce(o)}queue(e,o){return this.callbacks.push(e),this.debounce(o)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(e){return this.promise==null&&(this.promise=new Promise((o,n)=>{this.resolvePromise=o,this.rejectPromise=n})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),e??this.timeout),this.promise}async runCallbacks(){var e,o;let n=[...this.callbacks];this.callbacks=[];let i=(e=this.rejectPromise)!==null&&e!==void 0?e:()=>null,a=(o=this.resolvePromise)!==null&&o!==void 0?o:()=>null;this.clearPromise();for(let s of n)try{await s()}catch(c){i(c);return}a(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var Ls=h(k(),1);var hn=globalThis,Jp=hn.ShadowRoot&&(hn.ShadyCSS===void 0||hn.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,ey=Symbol();var Ts=(t,e)=>{if(Jp)t.adoptedStyleSheets=e.map(o=>o instanceof CSSStyleSheet?o:o.styleSheet);else for(let o of e){let n=document.createElement("style"),i=hn.litNonce;i!==void 0&&n.setAttribute("nonce",i),n.textContent=o.cssText,t.appendChild(n)}};var yn=class extends Ls.LitElement{createRenderRoot(){let e=this.constructor;e.elementDefinitions&&!e.registry&&(e.registry=new CustomElementRegistry,Object.entries(e.elementDefinitions).forEach(([i,a])=>e.registry.define(i,a)));let o={...e.shadowRootOptions,customElements:e.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return Ts(n,e.elementStyles),n}};function Is(t,e,...o){var n;let i=t.querySelector(e);for(let a of o)i=(n=i?.shadowRoot)===null||n===void 0?void 0:n.querySelector(a);return i}var So=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(s=t[c])&&(a=(i<3?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},Ps,Ns=Symbol("constructorPrototype"),_s=Symbol("constructorName"),Ds=Symbol("exportpartsDebouncer"),ks=Symbol("dynamicDependenciesLoaded"),Lt=class extends yn{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[Ps]=new fn(5),this[_s]=this.constructor.name,this[Ns]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[_s]&&Object.setPrototypeOf(this,this[Ns])}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 e=this.constructor;e[ks]||(e[ks]=!0,this.importDynamicDependencies())}importDynamicDependencies(){}updated(e){super.updated(e),this.updateComplete.then(()=>{this.contentAvailableCallback(e),this.focusElementToFocus(e),this.applyCustomStylesheet(e),this.scheduleExportpartsUpdate()})}contentAvailableCallback(e){}focusElementToFocus(e){if(e.has("elementToFocus")&&this.elementToFocus!=null){let{element:o,selector:n,shadowPath:i}=this.elementToFocus;if(n!=null){let a=[...i??[],n];o=Is(this.shadowRoot,...a)}o?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||o?.blur(),this.elementToFocus=void 0}}applyCustomStylesheet(e){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(a=>a.remove()),this.useAdoptedStyleSheets){if(e.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((i=this.customStylesheet)!==null&&i!==void 0?i:"")}catch(a){console.error(a,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let a=document.createElement("style");a.classList.add("ft-lit-element--custom-stylesheet"),a.innerHTML=this.customStylesheet,this.shadowRoot.append(a)}}scheduleExportpartsUpdate(){var e,o,n;(!((e=this.exportpartsPrefix)===null||e===void 0)&&e.trim()||(n=(o=this.exportpartsPrefixes)===null||o===void 0?void 0:o.length)!==null&&n!==void 0&&n)&&this[Ds].run(()=>{var i,a;!((i=this.exportpartsPrefix)===null||i===void 0)&&i.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((a=this.exportpartsPrefixes)===null||a===void 0?void 0:a.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})}setExportpartsAttribute(e){var o,n,i,a,s,c;let p=b=>b!=null&&b.trim().length>0,u=e.filter(p).map(b=>b.trim());if(u.length===0){this.removeAttribute("exportparts");return}let m=new Set;for(let b of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let v=(a=(i=b.getAttribute("part"))===null||i===void 0?void 0:i.split(" "))!==null&&a!==void 0?a:[],S=(c=(s=b.getAttribute("exportparts"))===null||s===void 0?void 0:s.split(",").map(E=>E.split(":")[1]))!==null&&c!==void 0?c:[];new Array(...v,...S).filter(p).map(E=>E.trim()).forEach(E=>m.add(E))}if(m.size===0){this.removeAttribute("exportparts");return}let y=[...m.values()].flatMap(b=>u.map(v=>`${b}:${v}--${b}`));this.setAttribute("exportparts",[...this.part,...y].join(", "))}};Ps=Ds;So([(0,Gr.property)()],Lt.prototype,"exportpartsPrefix",void 0);So([Rs([])],Lt.prototype,"exportpartsPrefixes",void 0);So([(0,Gr.property)()],Lt.prototype,"customStylesheet",void 0);So([(0,Gr.property)()],Lt.prototype,"elementToFocus",void 0);So([(0,Gr.state)()],Lt.prototype,"useAdoptedStyleSheets",void 0);function mn(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var Oo=Symbol("internalReduxEventsUnsubscribers"),Ht=Symbol("internalStoresUnsubscribers"),Sr=Symbol("internalStores"),eu=pn(Symbol("withRedux"),function(t){var e,o,n;class i extends t{constructor(){super(...arguments),this[e]=new Map,this[o]=new Map,this[n]=new Map}get reduxConstructor(){return this.constructor}willUpdate(s){super.willUpdate(s),[...this.reduxConstructor.reduxReactiveProperties].some(c=>s.has(c))&&this.updateFromStores()}getUnnamedStore(){if(this[Sr].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Sr].values()][0]}getStore(s){return s==null?this.getUnnamedStore():this[Sr].get(s)}addStore(s,c){var p;c=(p=c??s.name)!==null&&p!==void 0?p:"default-store",this.unsubscribeFromStore(c),this[Sr].set(c,s),this.subscribeToStore(c,s),this.updateFromStores()}removeStore(s){let c=typeof s=="string"?s:s.name;this.unsubscribeFromStore(c),this[Sr].delete(c)}setupStores(){this.unsubscribeFromStores(),this[Sr].forEach((s,c)=>this.subscribeToStore(c,s)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((s,c)=>{let p=this.constructor.getPropertyOptions(c);if(!p?.attribute||!this.hasAttribute(typeof p?.attribute=="string"?p.attribute:c)){let u=this.getStore(s.store);u&&(s.store?this[Ht].has(s.store):this[Ht].size>0)&&(this[c]=s.selector(u.getState(),this))}})}subscribeToStore(s,c){var p;this[Ht].set(s,c.subscribe(()=>this.updateFromStores())),this[Oo].set(s,[]),mn(c)&&c.eventBus&&((p=this.reduxConstructor.reduxEventListeners)===null||p===void 0||p.forEach((u,m)=>{if(typeof this[m]=="function"&&(!u.store||c.name===u.store)){let y=b=>this[m](b);c.addEventListener(u.eventName,y),this[Oo].get(s).push(()=>c.removeEventListener(u.eventName,y))}})),this.onStoreAvailable(s)}unsubscribeFromStores(){this[Ht].forEach((s,c)=>this.unsubscribeFromStore(c))}unsubscribeFromStore(s){var c;this[Ht].has(s)&&this[Ht].get(s)(),this[Ht].delete(s),(c=this[Oo].get(s))===null||c===void 0||c.forEach(p=>p()),this[Oo].delete(s)}onStoreAvailable(s){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return e=Ht,o=Sr,n=Oo,i.reduxProperties=new Map,i.reduxReactiveProperties=new Set,i.reduxEventListeners=new Map,i}),$s=class extends eu(Lt){};function it(t){for(var e=arguments.length,o=Array(e>1?e-1:0),n=1;n<e;n++)o[n-1]=arguments[n];if(0)var i,a;throw Error("[Immer] minified error nr: "+t+(o.length?" "+o.map(function(s){return"'"+s+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function It(t){return!!t&&!!t[ee]}function pt(t){var e;return!!t&&(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)===lu}(t)||Array.isArray(t)||!!t[Ws]||!!(!((e=t.constructor)===null||e===void 0)&&e[Ws])||Ti(t)||Li(t))}function Or(t,e,o){o===void 0&&(o=!1),Kr(t)===0?(o?Object.keys:jr)(t).forEach(function(n){o&&typeof n=="symbol"||e(n,t[n],t)}):t.forEach(function(n,i){return e(i,n,t)})}function Kr(t){var e=t[ee];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:Ti(t)?2:Li(t)?3:0}function Vr(t,e){return Kr(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function tu(t,e){return Kr(t)===2?t.get(e):t[e]}function Gs(t,e,o){var n=Kr(t);n===2?t.set(e,o):n===3?t.add(o):t[e]=o}function Vs(t,e){return t===e?t!==0||1/t==1/e:t!=t&&e!=e}function Ti(t){return au&&t instanceof Map}function Li(t){return su&&t instanceof Set}function Wt(t){return t.o||t.t}function Ii(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=Zs(t);delete e[ee];for(var o=jr(e),n=0;n<o.length;n++){var i=o[n],a=e[i];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(e[i]={configurable:!0,writable:!0,enumerable:a.enumerable,value:t[i]})}return Object.create(Object.getPrototypeOf(t),e)}function Ni(t,e){return e===void 0&&(e=!1),_i(t)||It(t)||!pt(t)||(Kr(t)>1&&(t.set=t.add=t.clear=t.delete=ru),Object.freeze(t),e&&Or(t,function(o,n){return Ni(n,!0)},!0)),t}function ru(){it(2)}function _i(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function St(t){var e=Ri[t];return e||it(18,t),e}function ou(t,e){Ri[t]||(Ri[t]=e)}function Ei(){return Eo}function vi(t,e){e&&(St("Patches"),t.u=[],t.s=[],t.v=e)}function gn(t){Ai(t),t.p.forEach(nu),t.p=null}function Ai(t){t===Eo&&(Eo=t.l)}function Bs(t){return Eo={p:[],l:Eo,h:t,m:!0,_:0}}function nu(t){var e=t[ee];e.i===0||e.i===1?e.j():e.g=!0}function Si(t,e){e._=e.p.length;var o=e.p[0],n=t!==void 0&&t!==o;return e.h.O||St("ES5").S(e,t,n),n?(o[ee].P&&(gn(e),it(4)),pt(t)&&(t=bn(e,t),e.l||xn(e,t)),e.u&&St("Patches").M(o[ee].t,t,e.u,e.s)):t=bn(e,o,[]),gn(e),e.u&&e.v(e.u,e.s),t!==Ks?t:void 0}function bn(t,e,o){if(_i(e))return e;var n=e[ee];if(!n)return Or(e,function(c,p){return Fs(t,n,e,c,p,o)},!0),e;if(n.A!==t)return e;if(!n.P)return xn(t,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=n.i===4||n.i===5?n.o=Ii(n.k):n.o,a=i,s=!1;n.i===3&&(a=new Set(i),i.clear(),s=!0),Or(a,function(c,p){return Fs(t,n,i,c,p,o,s)}),xn(t,i,!1),o&&t.u&&St("Patches").N(n,o,t.u,t.s)}return n.o}function Fs(t,e,o,n,i,a,s){if(It(i)){var c=bn(t,i,a&&e&&e.i!==3&&!Vr(e.R,n)?a.concat(n):void 0);if(Gs(o,n,c),!It(c))return;t.m=!1}else s&&o.add(i);if(pt(i)&&!_i(i)){if(!t.h.D&&t._<1)return;bn(t,i),e&&e.A.l||xn(t,i)}}function xn(t,e,o){o===void 0&&(o=!1),!t.l&&t.h.D&&t.m&&Ni(e,o)}function Oi(t,e){var o=t[ee];return(o?Wt(o):t)[e]}function Ms(t,e){if(e in t)for(var o=Object.getPrototypeOf(t);o;){var n=Object.getOwnPropertyDescriptor(o,e);if(n)return n;o=Object.getPrototypeOf(o)}}function Gt(t){t.P||(t.P=!0,t.l&&Gt(t.l))}function Ci(t){t.o||(t.o=Ii(t.t))}function wi(t,e,o){var n=Ti(e)?St("MapSet").F(e,o):Li(e)?St("MapSet").T(e,o):t.O?function(i,a){var s=Array.isArray(i),c={i:s?1:0,A:a?a.A:Ei(),P:!1,I:!1,R:{},l:a,t:i,k:null,o:null,j:null,C:!1},p=c,u=Ao;s&&(p=[c],u=Co);var m=Proxy.revocable(p,u),y=m.revoke,b=m.proxy;return c.k=b,c.j=y,b}(e,o):St("ES5").J(e,o);return(o?o.A:Ei()).p.push(n),n}function iu(t){return It(t)||it(22,t),function e(o){if(!pt(o))return o;var n,i=o[ee],a=Kr(o);if(i){if(!i.P&&(i.i<4||!St("ES5").K(i)))return i.t;i.I=!0,n=Us(o,a),i.I=!1}else n=Us(o,a);return Or(n,function(s,c){i&&tu(i.t,s)===c||Gs(n,s,e(c))}),a===3?new Set(n):n}(t)}function Us(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return Ii(t)}function js(){function t(s,c){var p=a[s];return p?p.enumerable=c:a[s]=p={configurable:!0,enumerable:c,get:function(){var u=this[ee];return Ao.get(u,s)},set:function(u){var m=this[ee];Ao.set(m,s,u)}},p}function e(s){for(var c=s.length-1;c>=0;c--){var p=s[c][ee];if(!p.P)switch(p.i){case 5:n(p)&&Gt(p);break;case 4:o(p)&&Gt(p)}}}function o(s){for(var c=s.t,p=s.k,u=jr(p),m=u.length-1;m>=0;m--){var y=u[m];if(y!==ee){var b=c[y];if(b===void 0&&!Vr(c,y))return!0;var v=p[y],S=v&&v[ee];if(S?S.t!==b:!Vs(v,b))return!0}}var E=!!c[ee];return u.length!==jr(c).length+(E?0:1)}function n(s){var c=s.k;if(c.length!==s.t.length)return!0;var p=Object.getOwnPropertyDescriptor(c,c.length-1);if(p&&!p.get)return!0;for(var u=0;u<c.length;u++)if(!c.hasOwnProperty(u))return!0;return!1}function i(s){s.g&&it(3,JSON.stringify(Wt(s)))}var a={};ou("ES5",{J:function(s,c){var p=Array.isArray(s),u=function(y,b){if(y){for(var v=Array(b.length),S=0;S<b.length;S++)Object.defineProperty(v,""+S,t(S,!0));return v}var E=Zs(b);delete E[ee];for(var _=jr(E),I=0;I<_.length;I++){var N=_[I];E[N]=t(N,y||!!E[N].enumerable)}return Object.create(Object.getPrototypeOf(b),E)}(p,s),m={i:p?5:4,A:c?c.A:Ei(),P:!1,I:!1,R:{},l:c,t:s,k:u,o:null,g:!1,C:!1};return Object.defineProperty(u,ee,{value:m,writable:!0}),u},S:function(s,c,p){p?It(c)&&c[ee].A===s&&e(s.p):(s.u&&function u(m){if(m&&typeof m=="object"){var y=m[ee];if(y){var b=y.t,v=y.k,S=y.R,E=y.i;if(E===4)Or(v,function(U){U!==ee&&(b[U]!==void 0||Vr(b,U)?S[U]||u(v[U]):(S[U]=!0,Gt(y)))}),Or(b,function(U){v[U]!==void 0||Vr(v,U)||(S[U]=!1,Gt(y))});else if(E===5){if(n(y)&&(Gt(y),S.length=!0),v.length<b.length)for(var _=v.length;_<b.length;_++)S[_]=!1;else for(var I=b.length;I<v.length;I++)S[I]=!0;for(var N=Math.min(v.length,b.length),$=0;$<N;$++)v.hasOwnProperty($)||(S[$]=!0),S[$]===void 0&&u(v[$])}}}}(s.p[0]),e(s.p))},K:function(s){return s.i===4?o(s):n(s)}})}var zs,Eo,ki=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",au=typeof Map<"u",su=typeof Set<"u",Hs=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",Ks=ki?Symbol.for("immer-nothing"):((zs={})["immer-nothing"]=!0,zs),Ws=ki?Symbol.for("immer-draftable"):"__$immer_draftable",ee=ki?Symbol.for("immer-state"):"__$immer_state";var lu=""+Object.prototype.constructor,jr=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,Zs=Object.getOwnPropertyDescriptors||function(t){var e={};return jr(t).forEach(function(o){e[o]=Object.getOwnPropertyDescriptor(t,o)}),e},Ri={},Ao={get:function(t,e){if(e===ee)return t;var o=Wt(t);if(!Vr(o,e))return function(i,a,s){var c,p=Ms(a,s);return p?"value"in p?p.value:(c=p.get)===null||c===void 0?void 0:c.call(i.k):void 0}(t,o,e);var n=o[e];return t.I||!pt(n)?n:n===Oi(t.t,e)?(Ci(t),t.o[e]=wi(t.A.h,n,t)):n},has:function(t,e){return e in Wt(t)},ownKeys:function(t){return Reflect.ownKeys(Wt(t))},set:function(t,e,o){var n=Ms(Wt(t),e);if(n?.set)return n.set.call(t.k,o),!0;if(!t.P){var i=Oi(Wt(t),e),a=i?.[ee];if(a&&a.t===o)return t.o[e]=o,t.R[e]=!1,!0;if(Vs(o,i)&&(o!==void 0||Vr(t.t,e)))return!0;Ci(t),Gt(t)}return t.o[e]===o&&(o!==void 0||e in t.o)||Number.isNaN(o)&&Number.isNaN(t.o[e])||(t.o[e]=o,t.R[e]=!0),!0},deleteProperty:function(t,e){return Oi(t.t,e)!==void 0||e in t.t?(t.R[e]=!1,Ci(t),Gt(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var o=Wt(t),n=Reflect.getOwnPropertyDescriptor(o,e);return n&&{writable:!0,configurable:t.i!==1||e!=="length",enumerable:n.enumerable,value:o[e]}},defineProperty:function(){it(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){it(12)}},Co={};Or(Ao,function(t,e){Co[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}}),Co.deleteProperty=function(t,e){return Co.set.call(this,t,e,void 0)},Co.set=function(t,e,o){return Ao.set.call(this,t[0],e,o,t[0])};var cu=function(){function t(o){var n=this;this.O=Hs,this.D=!0,this.produce=function(i,a,s){if(typeof i=="function"&&typeof a!="function"){var c=a;a=i;var p=n;return function(E){var _=this;E===void 0&&(E=c);for(var I=arguments.length,N=Array(I>1?I-1:0),$=1;$<I;$++)N[$-1]=arguments[$];return p.produce(E,function(U){var z;return(z=a).call.apply(z,[_,U].concat(N))})}}var u;if(typeof a!="function"&&it(6),s!==void 0&&typeof s!="function"&&it(7),pt(i)){var m=Bs(n),y=wi(n,i,void 0),b=!0;try{u=a(y),b=!1}finally{b?gn(m):Ai(m)}return typeof Promise<"u"&&u instanceof Promise?u.then(function(E){return vi(m,s),Si(E,m)},function(E){throw gn(m),E}):(vi(m,s),Si(u,m))}if(!i||typeof i!="object"){if((u=a(i))===void 0&&(u=i),u===Ks&&(u=void 0),n.D&&Ni(u,!0),s){var v=[],S=[];St("Patches").M(i,u,v,S),s(v,S)}return u}it(21,i)},this.produceWithPatches=function(i,a){if(typeof i=="function")return function(u){for(var m=arguments.length,y=Array(m>1?m-1:0),b=1;b<m;b++)y[b-1]=arguments[b];return n.produceWithPatches(u,function(v){return i.apply(void 0,[v].concat(y))})};var s,c,p=n.produce(i,a,function(u,m){s=u,c=m});return typeof Promise<"u"&&p instanceof Promise?p.then(function(u){return[u,s,c]}):[p,s,c]},typeof o?.useProxies=="boolean"&&this.setUseProxies(o.useProxies),typeof o?.autoFreeze=="boolean"&&this.setAutoFreeze(o.autoFreeze)}var e=t.prototype;return e.createDraft=function(o){pt(o)||it(8),It(o)&&(o=iu(o));var n=Bs(this),i=wi(this,o,void 0);return i[ee].C=!0,Ai(n),i},e.finishDraft=function(o,n){var i=o&&o[ee],a=i.A;return vi(a,n),Si(void 0,a)},e.setAutoFreeze=function(o){this.D=o},e.setUseProxies=function(o){o&&!Hs&&it(20),this.O=o},e.applyPatches=function(o,n){var i;for(i=n.length-1;i>=0;i--){var a=n[i];if(a.path.length===0&&a.op==="replace"){o=a.value;break}}i>-1&&(n=n.slice(i+1));var s=St("Patches").$;return It(o)?s(o,n):this.produce(o,function(c){return s(c,n)})},t}(),qe=new cu,du=qe.produce,yy=qe.produceWithPatches.bind(qe),my=qe.setAutoFreeze.bind(qe),gy=qe.setUseProxies.bind(qe),by=qe.applyPatches.bind(qe),xy=qe.createDraft.bind(qe),vy=qe.finishDraft.bind(qe),vn=du;function Cr(t){"@babel/helpers - typeof";return Cr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Cr(t)}function qs(t,e){if(Cr(t)!="object"||!t)return t;var o=t[Symbol.toPrimitive];if(o!==void 0){var n=o.call(t,e||"default");if(Cr(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ys(t){var e=qs(t,"string");return Cr(e)=="symbol"?e:e+""}function Qs(t,e,o){return(e=Ys(e))in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}function Xs(t,e){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),o.push.apply(o,n)}return o}function Pi(t){for(var e=1;e<arguments.length;e++){var o=arguments[e]!=null?arguments[e]:{};e%2?Xs(Object(o),!0).forEach(function(n){Qs(t,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):Xs(Object(o)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(o,n))})}return t}function Te(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}var Js=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),Di=function(){return Math.random().toString(36).substring(7).split("").join(".")},Sn={INIT:"@@redux/INIT"+Di(),REPLACE:"@@redux/REPLACE"+Di(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Di()}};function pu(t){if(typeof t!="object"||t===null)return!1;for(var e=t;Object.getPrototypeOf(e)!==null;)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}function $i(t,e,o){var n;if(typeof e=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(Te(0));if(typeof e=="function"&&typeof o>"u"&&(o=e,e=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(Te(1));return o($i)(t,e)}if(typeof t!="function")throw new Error(Te(2));var i=t,a=e,s=[],c=s,p=!1;function u(){c===s&&(c=s.slice())}function m(){if(p)throw new Error(Te(3));return a}function y(E){if(typeof E!="function")throw new Error(Te(4));if(p)throw new Error(Te(5));var _=!0;return u(),c.push(E),function(){if(_){if(p)throw new Error(Te(6));_=!1,u();var N=c.indexOf(E);c.splice(N,1),s=null}}}function b(E){if(!pu(E))throw new Error(Te(7));if(typeof E.type>"u")throw new Error(Te(8));if(p)throw new Error(Te(9));try{p=!0,a=i(a,E)}finally{p=!1}for(var _=s=c,I=0;I<_.length;I++){var N=_[I];N()}return E}function v(E){if(typeof E!="function")throw new Error(Te(10));i=E,b({type:Sn.REPLACE})}function S(){var E,_=y;return E={subscribe:function(N){if(typeof N!="object"||N===null)throw new Error(Te(11));function $(){N.next&&N.next(m())}$();var U=_($);return{unsubscribe:U}}},E[Js]=function(){return this},E}return b({type:Sn.INIT}),n={dispatch:b,subscribe:y,getState:m,replaceReducer:v},n[Js]=S,n}function uu(t){Object.keys(t).forEach(function(e){var o=t[e],n=o(void 0,{type:Sn.INIT});if(typeof n>"u")throw new Error(Te(12));if(typeof o(void 0,{type:Sn.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Te(13))})}function el(t){for(var e=Object.keys(t),o={},n=0;n<e.length;n++){var i=e[n];typeof t[i]=="function"&&(o[i]=t[i])}var a=Object.keys(o),s,c;try{uu(o)}catch(p){c=p}return function(u,m){if(u===void 0&&(u={}),c)throw c;if(0)var y;for(var b=!1,v={},S=0;S<a.length;S++){var E=a[S],_=o[E],I=u[E],N=_(I,m);if(typeof N>"u"){var $=m&&m.type;throw new Error(Te(14))}v[E]=N,b=b||N!==I}return b=b||a.length!==Object.keys(u).length,b?v:u}}function Zr(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return e.length===0?function(n){return n}:e.length===1?e[0]:e.reduce(function(n,i){return function(){return n(i.apply(void 0,arguments))}})}function tl(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return function(n){return function(){var i=n.apply(void 0,arguments),a=function(){throw new Error(Te(15))},s={getState:i.getState,dispatch:function(){return a.apply(void 0,arguments)}},c=e.map(function(p){return p(s)});return a=Zr.apply(void 0,c)(i.dispatch),Pi(Pi({},i),{},{dispatch:a})}}}function rl(t){var e=function(n){var i=n.dispatch,a=n.getState;return function(s){return function(c){return typeof c=="function"?c(i,a,t):s(c)}}};return e}var ol=rl();ol.withExtraArgument=rl;var Bi=ol;var ll=function(){var t=function(e,o){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(n[a]=i[a])},t(e,o)};return function(e,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");t(e,o);function n(){this.constructor=e}e.prototype=o===null?Object.create(o):(n.prototype=o.prototype,new n)}}(),fu=function(t,e){var o={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,s;return s={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function c(u){return function(m){return p([u,m])}}function p(u){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,i=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(a=o.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){o.label=u[1];break}if(u[0]===6&&o.label<a[1]){o.label=a[1],a=u;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(u);break}a[2]&&o.ops.pop(),o.trys.pop();continue}u=e.call(t,o)}catch(m){u=[6,m],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},qr=function(t,e){for(var o=0,n=e.length,i=t.length;o<n;o++,i++)t[i]=e[o];return t},hu=Object.defineProperty,yu=Object.defineProperties,mu=Object.getOwnPropertyDescriptors,nl=Object.getOwnPropertySymbols,gu=Object.prototype.hasOwnProperty,bu=Object.prototype.propertyIsEnumerable,il=function(t,e,o){return e in t?hu(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o},Vt=function(t,e){for(var o in e||(e={}))gu.call(e,o)&&il(t,o,e[o]);if(nl)for(var n=0,i=nl(e);n<i.length;n++){var o=i[n];bu.call(e,o)&&il(t,o,e[o])}return t},Fi=function(t,e){return yu(t,mu(e))},xu=function(t,e,o){return new Promise(function(n,i){var a=function(p){try{c(o.next(p))}catch(u){i(u)}},s=function(p){try{c(o.throw(p))}catch(u){i(u)}},c=function(p){return p.done?n(p.value):Promise.resolve(p.value).then(a,s)};c((o=o.apply(t,e)).next())})};var vu=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Zr:Zr.apply(null,arguments)},Fy=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}};function Su(t){if(typeof t!="object"||t===null)return!1;var e=Object.getPrototypeOf(t);if(e===null)return!0;for(var o=e;Object.getPrototypeOf(o)!==null;)o=Object.getPrototypeOf(o);return e===o}var Ou=function(t){ll(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return t.prototype.concat.apply(this,o)},e.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(e.bind.apply(e,qr([void 0],o[0].concat(this)))):new(e.bind.apply(e,qr([void 0],o.concat(this))))},e}(Array),Cu=function(t){ll(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return t.prototype.concat.apply(this,o)},e.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(e.bind.apply(e,qr([void 0],o[0].concat(this)))):new(e.bind.apply(e,qr([void 0],o.concat(this))))},e}(Array);function zi(t){return pt(t)?vn(t,function(){}):t}function Eu(t){return typeof t=="boolean"}function Au(){return function(e){return wu(e)}}function wu(t){t===void 0&&(t={});var e=t.thunk,o=e===void 0?!0:e,n=t.immutableCheck,i=n===void 0?!0:n,a=t.serializableCheck,s=a===void 0?!0:a,c=new Ou;if(o&&(Eu(o)?c.push(Bi):c.push(Bi.withExtraArgument(o.extraArgument))),0){if(i)var p;if(s)var u}return c}var Mi=!0;function cl(t){var e=Au(),o=t||{},n=o.reducer,i=n===void 0?void 0:n,a=o.middleware,s=a===void 0?e():a,c=o.devTools,p=c===void 0?!0:c,u=o.preloadedState,m=u===void 0?void 0:u,y=o.enhancers,b=y===void 0?void 0:y,v;if(typeof i=="function")v=i;else if(Su(i))v=el(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 S=s;if(typeof S=="function"&&(S=S(e),!Mi&&!Array.isArray(S)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!Mi&&S.some(function(U){return typeof U!="function"}))throw new Error("each middleware provided to configureStore must be a function");var E=tl.apply(void 0,S),_=Zr;p&&(_=vu(Vt({trace:!Mi},typeof p=="object"&&p)));var I=new Cu(E),N=I;Array.isArray(b)?N=qr([E],b):typeof b=="function"&&(N=b(I));var $=_.apply(void 0,N);return $i(v,m,$)}function jt(t,e){function o(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];if(e){var a=e.apply(void 0,n);if(!a)throw new Error("prepareAction did not return an object");return Vt(Vt({type:t,payload:a.payload},"meta"in a&&{meta:a.meta}),"error"in a&&{error:a.error})}return{type:t,payload:n[0]}}return o.toString=function(){return""+t},o.type=t,o.match=function(n){return n.type===t},o}function dl(t){var e={},o=[],n,i={addCase:function(a,s){var c=typeof a=="string"?a:a.type;if(c in e)throw new Error("addCase cannot be called with two reducers for the same action type");return e[c]=s,i},addMatcher:function(a,s){return o.push({matcher:a,reducer:s}),i},addDefaultCase:function(a){return n=a,i}};return t(i),[e,o,n]}function Ru(t){return typeof t=="function"}function Tu(t,e,o,n){o===void 0&&(o=[]);var i=typeof e=="function"?dl(e):[e,o,n],a=i[0],s=i[1],c=i[2],p;if(Ru(t))p=function(){return zi(t())};else{var u=zi(t);p=function(){return u}}function m(y,b){y===void 0&&(y=p());var v=qr([a[b.type]],s.filter(function(S){var E=S.matcher;return E(b)}).map(function(S){var E=S.reducer;return E}));return v.filter(function(S){return!!S}).length===0&&(v=[c]),v.reduce(function(S,E){if(E)if(It(S)){var _=S,I=E(_,b);return I===void 0?S:I}else{if(pt(S))return vn(S,function(N){return E(N,b)});var I=E(S,b);if(I===void 0){if(S===null)return S;throw Error("A case reducer on a non-draftable value must not return undefined")}return I}return S},y)}return m.getInitialState=p,m}function Lu(t,e){return t+"/"+e}function pl(t){var e=t.name;if(!e)throw new Error("`name` is a required option for createSlice");typeof process<"u";var o=typeof t.initialState=="function"?t.initialState:zi(t.initialState),n=t.reducers||{},i=Object.keys(n),a={},s={},c={};i.forEach(function(m){var y=n[m],b=Lu(e,m),v,S;"reducer"in y?(v=y.reducer,S=y.prepare):v=y,a[m]=v,s[b]=v,c[m]=S?jt(b,S):jt(b)});function p(){var m=typeof t.extraReducers=="function"?dl(t.extraReducers):[t.extraReducers],y=m[0],b=y===void 0?{}:y,v=m[1],S=v===void 0?[]:v,E=m[2],_=E===void 0?void 0:E,I=Vt(Vt({},b),s);return Tu(o,function(N){for(var $ in I)N.addCase($,I[$]);for(var U=0,z=S;U<z.length;U++){var Me=z[U];N.addMatcher(Me.matcher,Me.reducer)}_&&N.addDefaultCase(_)})}var u;return{name:e,reducer:function(m,y){return u||(u=p()),u(m,y)},actions:c,caseReducers:a,getInitialState:function(){return u||(u=p()),u.getInitialState()}}}var Iu="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Nu=function(t){t===void 0&&(t=21);for(var e="",o=t;o--;)e+=Iu[Math.random()*64|0];return e},_u=["name","message","stack","code"],Ui=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),al=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),ku=function(t){if(typeof t=="object"&&t!==null){for(var e={},o=0,n=_u;o<n.length;o++){var i=n[o];typeof t[i]=="string"&&(e[i]=t[i])}return e}return{message:String(t)}},Hy=function(){function t(e,o,n){var i=jt(e+"/fulfilled",function(m,y,b,v){return{payload:m,meta:Fi(Vt({},v||{}),{arg:b,requestId:y,requestStatus:"fulfilled"})}}),a=jt(e+"/pending",function(m,y,b){return{payload:void 0,meta:Fi(Vt({},b||{}),{arg:y,requestId:m,requestStatus:"pending"})}}),s=jt(e+"/rejected",function(m,y,b,v,S){return{payload:v,error:(n&&n.serializeError||ku)(m||"Rejected"),meta:Fi(Vt({},S||{}),{arg:b,requestId:y,rejectedWithValue:!!v,requestStatus:"rejected",aborted:m?.name==="AbortError",condition:m?.name==="ConditionError"})}}),c=!1,p=typeof AbortController<"u"?AbortController:function(){function m(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return m.prototype.abort=function(){},m}();function u(m){return function(y,b,v){var S=n?.idGenerator?n.idGenerator(m):Nu(),E=new p,_,I=!1;function N(U){_=U,E.abort()}var $=function(){return xu(this,null,function(){var U,z,Me,xt,ke,vt,ve;return fu(this,function(g){switch(g.label){case 0:return g.trys.push([0,4,,5]),xt=(U=n?.condition)==null?void 0:U.call(n,m,{getState:b,extra:v}),Du(xt)?[4,xt]:[3,2];case 1:xt=g.sent(),g.label=2;case 2:if(xt===!1||E.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return I=!0,ke=new Promise(function(x,P){return E.signal.addEventListener("abort",function(){return P({name:"AbortError",message:_||"Aborted"})})}),y(a(S,m,(z=n?.getPendingMeta)==null?void 0:z.call(n,{requestId:S,arg:m},{getState:b,extra:v}))),[4,Promise.race([ke,Promise.resolve(o(m,{dispatch:y,getState:b,extra:v,requestId:S,signal:E.signal,abort:N,rejectWithValue:function(x,P){return new Ui(x,P)},fulfillWithValue:function(x,P){return new al(x,P)}})).then(function(x){if(x instanceof Ui)throw x;return x instanceof al?i(x.payload,S,m,x.meta):i(x,S,m)})])];case 3:return Me=g.sent(),[3,5];case 4:return vt=g.sent(),Me=vt instanceof Ui?s(null,S,m,vt.payload,vt.meta):s(vt,S,m),[3,5];case 5:return ve=n&&!n.dispatchConditionRejection&&s.match(Me)&&Me.meta.condition,ve||y(Me),[2,Me]}})})}();return Object.assign($,{abort:N,requestId:S,arg:m,unwrap:function(){return $.then(Pu)}})}}return Object.assign(u,{pending:a,rejected:s,fulfilled:i,typePrefix:e})}return t.withTypes=function(){return t},t}();function Pu(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function Du(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var ul="listener",fl="completed",hl="cancelled",Wy="task-"+hl,Gy="task-"+fl,Vy=ul+"-"+hl,jy=ul+"-"+fl;var Hi="listenerMiddleware";var Ky=jt(Hi+"/add"),Zy=jt(Hi+"/removeAll"),qy=jt(Hi+"/remove");var sl,Yy=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(t){return(sl||(sl=Promise.resolve())).then(t).catch(function(e){return setTimeout(function(){throw e},0)})},$u=function(t){return function(e){setTimeout(e,t)}},Qy=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:$u(10);js();var Bu=pn(Symbol("withEventBus"),function(t,e){return class extends t{constructor(){super(...arguments),this.eventBus=e??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)}}}),On=class extends Bu(Object){};window.ftReduxStores||(window.ftReduxStores={});var yl=class t extends On{static get(e){var o;let n=typeof e=="string"?e:e.name,i=typeof e=="string"?void 0:e,a=window.ftReduxStores[n];if(mn(a))return a;if(i==null)return;let s=pl({...i,reducers:(o=i.reducers)!==null&&o!==void 0?o:{}}),c=cl({reducer:(p,u)=>u.type==="CLEAR_FT_REDUX_STORE"?s.getInitialState():typeof u.type=="string"&&u.type.startsWith("DEFAULT_VALUE_SETTER__")?{...p,...u.overwrites}:s.reducer(p,u)});return window.ftReduxStores[i.name]=new t(s,c,i.eventBus)}constructor(e,o,n){super(),this.reduxSlice=e,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new un;let i=a=>a!=null?JSON.parse(JSON.stringify(a)):a;this.actions=new Proxy(this.reduxSlice.actions,{get:(a,s,c)=>{let p=s,u=a[p];return u?(...m)=>{let y=u(...m.map(i));return this.reduxStore.dispatch(y),y}:m=>{this.setState({[p]:i(m)})}}}),this.eventBus=n??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE"})}setState(e){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(e).join("_"),overwrites:e})}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(e){throw new Error("Not implemented yet.")}subscribe(e){return this.reduxStore.subscribe(e)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}};var Cn=class{static format(e,o,n,i){return window.moment?window.moment(e).locale(o).format(this.getMomentDateFormat(n,i)):this.getIntlDateTime(e,o,n,i)}static getMomentDateFormat(e,o){return e?o?"lll":"ll":o?"L LT":"L"}static getIntlDateTime(e,o,n,i){let a=typeof e=="string"?new Date(e):e,s=new Intl.DateTimeFormat(o,{dateStyle:n?"medium":"short"}).format(a);if(!i)return s;let c=new Intl.DateTimeFormat(o,{timeStyle:"short"}).format(a);return`${s} ${c}`}};var ml=h(A()),En=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(s=t[c])&&(a=(i<3?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},gl=(0,ml.applyMixinOnce)(Symbol("withDateFormat"),function(t){class e extends t{constructor(...n){super(n),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(T)}dateFormatOptionsChanged(n){return n.has("metadataDescriptors")||n.has("useLongDateFormat")||n.has("useDateTimeFormat")||n.has("uiLocale")}getDateFormatter(n){var i,a;return((a=(i=this.metadataDescriptors.find(c=>c.key===n))===null||i===void 0?void 0:i.date)!==null&&a!==void 0?a:!1)?c=>Cn.format(c,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return En([(0,Wi.property)({type:Boolean})],e.prototype,"useLongDateFormat",void 0),En([(0,Wi.property)({type:Boolean})],e.prototype,"useDateTimeFormat",void 0),En([xi({store:T.name,selector:o=>{var n,i;return(i=(n=o.metadataConfiguration)===null||n===void 0?void 0:n.descriptors)!==null&&i!==void 0?i:[]}})],e.prototype,"metadataDescriptors",void 0),En([xi({store:T.name})],e.prototype,"uiLocale",void 0),e});var Rn=h(A());var An=class extends Re{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetCount(e){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${e}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(e){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${e}`),this.CACHE_DURATION)}isAuthenticated(){let e=T.getState().session;return!!e?.sessionAuthenticated}};var wn=class extends Re{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let e=T.getState().session;return!!e?.sessionAuthenticated}};var Fu="ft-user-assets",Mu={setAssetCount:(t,e)=>{let{userAssetType:o,count:n}=e.payload.assetCount;t.assetCounts.allAsset[o]=n},clearAssetCount:t=>{Object.values(gr).forEach(e=>{t.assetCounts.allAsset[e]=void 0})},setBookmarkCountByMap:(t,e)=>{let o=e.payload.mapId;t.assetCounts.bookmarkByMap[o]=e.payload.count},clearBookmarkCountByMap:t=>{t.assetCounts.bookmarkByMap={}}},Ye=Rn.FtReduxStore.get({name:Fu,reducers:Mu,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(gr).map(t=>[t,void 0])),bookmarkByMap:{}},assetLabels:[]}}),Gi=class{constructor(e=new An,o=new wn){this.assetCountsService=e,this.assetLabelsService=o,this.currentSession=T.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new on,this.savedSearchesService=new sn,T.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:o}=T.getState();(0,Rn.deepEqual)((e=this.currentSession)===null||e===void 0?void 0:e.profile,o?.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),Ye.actions.clearAssetCount(),Ye.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),Ye.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),Ye.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();Ye.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let e=await this.assetLabelsService.getUserAssetLabels();Ye.actions.assetLabels(e)}async loadAssetCount(e){let o=await this.assetCountsService.getUserAssetCount(e);o&&Ye.actions.setAssetCount({assetCount:o})}async loadBookmarkByMapId(e){let o=await this.assetCountsService.getUserBookmarkCountByMap(e);o&&Ye.actions.setBookmarkCountByMap({count:o.count,mapId:e})}async reloadAssetCount(e){this.assetCountsService.clearCache();let o=Object.keys(Ye.getState().assetCounts.bookmarkByMap).length!==0;e===gr.BOOKMARKS&&o&&Ye.actions.clearBookmarkCountByMap(),Ye.getState().assetCounts.allAsset[e]!==void 0&&await this.loadAssetCount(e)}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var e;if(this.bookmarksAreUsed){let o=!((e=this.currentSession)===null||e===void 0)&&e.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;Ye.actions.bookmarks(o)}}},Vi=new Gi;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=Vi);(0,bl.customElement)("ft-app-context")(Y);var Tn=class extends Re{constructor(e){super(!0,e),this.cache.registerFinal("search-configuration",async()=>(await this.awaitApi).getSearchConfiguration())}async launchSearch(e){let o={...e,metadataFilters:this.sortFilters(e.metadataFilters),facets:[...e.facets].sort((n,i)=>n.id.localeCompare(i.id))};return this.cache.get("search-"+this.hash(o),async()=>(await this.awaitApi).search(e),2*60*1e3)}async launchSuggest(e){let o={...e,metadataFilters:this.sortFilters(e.metadataFilters)};return this.cache.get("suggest-"+this.hash(o),async()=>(await this.awaitApi).getSuggestions(e),2*60*1e3)}async getAvailableSearchLocales(){return this.cache.get("available-locales",async()=>(await this.awaitApi).getAvailableSearchLocales())}async getConfiguration(){return this.cache.get("search-configuration")}sortFilters(e){return e.map(o=>o.valueFilter==null?o:{...o,valueFilter:{...o.valueFilter,values:[...o.valueFilter.values].sort((n,i)=>n.localeCompare(i))}}).sort((o,n)=>o.key.localeCompare(n.key))}};var Ro=t=>t.request.virtualField===Ur.TITLE_ONLY&&t.request.scope===zr.DOCUMENTS,Ln=class t extends Event{constructor(){super(t.eventName)}};Ln.eventName="search-context-clear-all-filters";var wo=class t{static build(e,o){return new t(Ha(e.trim()||"context"),o)}constructor(e,o){this.store=e,this.ignoreEmptyQuery=!1,this.openExternalDocumentInNewTab=!1,this.localesDebouncer=new Qe.Debouncer(10),this.searchDebouncer=new Qe.Debouncer(100),this.launchSearch=n=>this.searchDebouncer.run(()=>this.fetchSearchData(n??this.buildSearchRequest(this.store.getState()))),this.buildSearchRequest=n=>({...n.request,facets:this.facetIds.map(i=>({id:i}))}),this.suggestDebouncer=new Qe.Debouncer(300),this.launchSuggest=n=>this.suggestDebouncer.run(()=>this.fetchSuggestData(n??this.buildSuggestRequest(this.store.getState()))),this.buildSuggestRequest=n=>{var i;return{input:n.liveQuery,metadataFilters:n.request.metadataFilters,sort:(i=n.request.sort)!==null&&i!==void 0?i:[],sortId:n.request.sortId,contentLocale:n.request.contentLocale,scope:n.request.scope}},this.service=o??new Tn,this.service.cache.addEventListener("clear-cache",n=>{n.detail.clearedKeys.includes("available-locales")&&this.updateLocales()}),this.searchWatcher=(0,Qe.watch)(e,this.buildSearchRequest,this.launchSearch),this.suggestWatcher=(0,Qe.watch)(e,this.buildSuggestRequest,this.launchSuggest)}async initService(){return this.updateLocales(),this.service.getConfiguration().then(e=>this.store.actions.configuration(e)),this.launchSearch()}setQuery(e){this.store.actions.setRequestQuery(e),this.store.actions.liveQuery(e),this.store.actions.setPageNumber(1)}setContentLocale(e){var o;let n=(o=this.store.getState().locales)!==null&&o!==void 0?o:[],i=this.store.getState().request.contentLocale;if(e!=i){if(n.length>0){let a=s=>n.some(c=>c.lang==s);a(e)||(e=a(i)?i:n[0].lang)}this.store.actions.setRequestContentLocale(e),this.store.actions.setPageNumber(1),this.store.actions.setRequestFilters([])}return e}forceContentLocale(e){this.store.actions.setRequestContentLocale(e)}setPageSize(e){this.store.actions.setPageSize(e)}setPageNumber(e){this.store.actions.setPageNumber(e)}get sortOptions(){var e,o;return(o=(e=this.store.getState().configuration)===null||e===void 0?void 0:e.sortOptions)!==null&&o!==void 0?o:[]}setSort(e){this.store.actions.setRequestSort(e),this.store.actions.setPageNumber(1)}setSortId(e){var o;if(this.store.actions.setPageNumber(1),e==null||this.sortOptions.length==0)return this.store.actions.setRequestSortId(e),e;let n=(o=this.sortOptions.find(i=>i.id==e))!==null&&o!==void 0?o:this.sortOptions[0];return this.store.actions.setRequestSortId(n.id),n.id}setFilters(e){let o=e.filter(n=>!n.valueFilter||n.valueFilter.values.length>0);this.store.actions.setRequestFilters(o),this.store.actions.setPageNumber(1)}setClusterSortCriterion(e){this.store.actions.setRequestClusterSortCriterion(e)}setSearchInDocumentTitlesOnly(e){e?(this.store.actions.setRequestVirtualField(Ur.TITLE_ONLY),this.store.actions.setRequestScope(zr.DOCUMENTS)):(this.store.actions.setRequestVirtualField(Ur.EVERYWHERE),this.store.actions.setRequestScope(zr.DEFAULT))}setVirtualField(e){this.store.actions.setRequestVirtualField(e)}get searchInDocumentTitlesOnly(){return Ro(this.store.getState())}clearAllFilters(){this.setFilters([]),this.store.dispatchEvent(new Ln)}addFacet(e){this.facetIds=[...this.facetIds,e]}replaceFacet(e,o){let n=this.facetIds.filter(i=>i!=e);o&&n.push(o),this.facetIds=n}get facetIds(){var e;let o=this.store.getState().request;return[...new Set([...o.facets.map(n=>n.id),...((e=o.metadataFilters)!==null&&e!==void 0?e:[]).map(n=>n.key)])]}set facetIds(e){let n=[...new Set(e)].map(i=>({id:i}));this.store.actions.setRequestFacets(n)}setFilter(e,o){this.setValueFilter(e,o)}setValueFilter(e,o){let n=this.store.getState().request.metadataFilters,i={key:e,valueFilter:{values:o,negative:!1}},a=[...n.filter(s=>!s.valueFilter),...n.filter(s=>s.valueFilter&&s.key!==i.key),i];this.setFilters(a)}setDateFilter(e,o){let n=this.store.getState().request.metadataFilters,i={key:e,dateFilter:{type:o}},a=[...n.filter(s=>!s.dateFilter),...n.filter(s=>s.dateFilter&&s.key!==i.key),i];this.setFilters(a)}removeDateFilter(e){let o=this.store.getState().request.metadataFilters,n=[...o.filter(i=>!i.dateFilter),...o.filter(i=>i.dateFilter&&i.key!==e)];this.setFilters(n)}setRangeFilter(e,o,n){let i=this.store.getState().request.metadataFilters,a={key:e,rangeFilter:{from:o,to:n}},s=[...i.filter(c=>!c.rangeFilter),...i.filter(c=>c.rangeFilter&&c.key!==a.key),a];this.setFilters(s)}removeRangeFilter(e){let o=this.store.getState().request.metadataFilters,n=[...o.filter(i=>!i.rangeFilter),...o.filter(i=>i.rangeFilter&&i.key!==e)];this.setFilters(n)}setLiveQuery(e){this.store.actions.liveQuery(e)}setRequest(e){this.store.actions.setRequest({...e,facets:this.store.getState().request.facets}),this.store.actions.liveQuery(e.query),this.store.actions.setPageNumber(1)}setScope(e){this.store.actions.setRequestScope(e)}setOtherQueryParams(e){this.store.actions.setOtherQueryParams(e)}setIgnoreEmptyQuery(e){this.ignoreEmptyQuery=e}setOpenExternalDocumentInNewTab(e){this.openExternalDocumentInNewTab=e}updateLocales(){return this.localesDebouncer.run(async()=>this.store.actions.locales((await this.service.getAvailableSearchLocales()).contentLocales))}async fetchSearchData(e){var o,n,i,a;try{if((o=this.cancelableSearch)===null||o===void 0||o.cancel(),this.store.actions.paging(void 0),this.ignoreEmptyQuery&&e.query.length==0)this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0);else{this.cancelableSearch=(0,Qe.cancelable)(this.service.launchSearch(e));let s=await this.cancelableSearch;if(this.store.actions.announcements(s.announcements),s.paging.currentPage<=1)this.store.actions.results(s.results),this.store.actions.facets(s.facets),this.store.actions.spellcheck(s.spellcheck);else{let c=((n=this.store.getState().results)!==null&&n!==void 0?n:[]).concat(s.results);this.store.actions.results(c),this.store.commands.clear(/^focus-result-/),this.store.commands.add({type:`focus-result-${(s.paging.currentPage-1)*((i=e.paging.perPage)!==null&&i!==void 0?i:20)+1}`})}this.store.actions.paging(s.paging)}}catch(s){s instanceof Qe.CanceledPromiseError||(console.error(s),(a=this.errorHandler)===null||a===void 0||a.call(this,s))}}async fetchSuggestData(e){var o;try{(o=this.cancelableSuggest)===null||o===void 0||o.cancel(),this.cancelableSuggest=(0,Qe.cancelable)(this.service.launchSuggest(e));let n=await this.cancelableSuggest;this.store.actions.suggestResults(n.suggestions)}catch(n){!(n instanceof Qe.CanceledPromiseError)&&this.errorHandler&&this.errorHandler(n)}}clear(){this.store.clear()}clearResults(){this.store.actions.paging(void 0),this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0)}};var Uu=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(s=t[c])&&(a=(i<3?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},Ki=class extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}},xl=Symbol("registerInterval"),ji=Symbol("registerAttempts"),zu=40,Hu=(0,In.applyMixinOnce)(Symbol("toFtSearchComponent"),function(t){class e extends t{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[ji]=0,this[xl]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null||this[ji]>zu?window.clearInterval(this[xl]):(this[ji]++,this.dispatchEvent(new Ki))}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return Uu([(0,vl.state)()],e.prototype,"stateManager",void 0),e}),Kt=class extends Hu(In.FtLitElementRedux){};var Ea=h(A());var Vn=h(k()),Le=h(j()),Pd=h(Zt()),ho=h(A());var Nl=h(A());var Ll=h(k()),Ce=h(j()),Il=h(Zt()),To=h(A());var Rl=h(k()),ce=h(A()),Ol=ce.FtCssVariableFactory.extend("--ft-ripple-color","",ce.designSystemVariables.colorContent),O={color:Ol,backgroundColor:ce.FtCssVariableFactory.extend("--ft-ripple-background-color","",Ol),opacityContentOnSurfacePressed:ce.FtCssVariableFactory.external(ce.designSystemVariables.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:ce.FtCssVariableFactory.external(ce.designSystemVariables.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:ce.FtCssVariableFactory.external(ce.designSystemVariables.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:ce.FtCssVariableFactory.external(ce.designSystemVariables.opacityContentOnSurfaceSelected,"Design system"),borderRadius:ce.FtCssVariableFactory.create("--ft-ripple-border-radius","","SIZE","0px")},Cl=ce.FtCssVariableFactory.extend("--ft-ripple-color","",ce.designSystemVariables.colorPrimary),El={color:Cl,backgroundColor:ce.FtCssVariableFactory.extend("--ft-ripple-background-color","",Cl)},Al=ce.FtCssVariableFactory.extend("--ft-ripple-color","",ce.designSystemVariables.colorSecondary),wl={color:Al,backgroundColor:ce.FtCssVariableFactory.extend("--ft-ripple-background-color","",Al)},Tl=Rl.css`
|
|
15
|
+
`}connectedCallback(){super.connectedCallback(),T.addEventListener(br.eventName,this.reloadConfiguration)}disconnectedCallback(){T.addEventListener(br.eventName,this.reloadConfiguration),super.disconnectedCallback()}update(e){var o,n,i,a,s,c,p;super.update(e),e.has("baseUrl")&&(T.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),e.has("apiIntegrationIdentifier")&&T.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("apiIntegrationAppVersion")&&T.actions.apiIntegrationAppVersion(this.apiIntegrationAppVersion),e.has("uiLocale")&&T.actions.uiLocale(this.uiLocale),e.has("metadataConfiguration")&&T.actions.metadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&T.actions.noCustom(this.noCustom),e.has("editorMode")&&T.actions.editorMode(this.editorMode),e.has("noCustomComponent")&&T.actions.noCustomComponent(this.noCustomComponent),e.has("session")&&T.actions.session(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(u=>Wr.addContext(u)),e.has("openExternalDocumentInNewTab")&&T.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&T.actions.navigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&T.actions.forcedOffline(this.forcedOffline),e.has("localesConfiguration")&&(T.actions.defaultLocales((o=this.localesConfiguration)===null||o===void 0?void 0:o.defaultLocales),T.actions.availableUiLocales((i=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&i!==void 0?i:[]),T.actions.searchInAllLanguagesAllowed((s=(a=this.localesConfiguration)===null||a===void 0?void 0:a.allLanguagesAllowed)!==null&&s!==void 0?s:!1)),e.has("authenticationRequired")&&T.actions.authenticationRequired(this.authenticationRequired),e.has("availableContentLocales")&&T.actions.availableContentLocales((p=(c=this.availableContentLocales)===null||c===void 0?void 0:c.contentLocales)!==null&&p!==void 0?p:[]),setTimeout(()=>this.updateIfNeeded())}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.session==null&&this.updateSession(),this.metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration(),this.availableContentLocales==null&&this.updateAvailableContentLocales())}async updateSession(){this.session=await this.cache.get("session",async()=>{let e=await this.apiProvider().getCurrentSession();return e.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.session=void 0},e.idleTimeoutInMillis),e})}async updateMetadataConfiguration(){this.metadataConfiguration=await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration())}async updateLocalesConfiguration(){this.localesConfiguration=await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration())}async updateAvailableContentLocales(){this.availableContentLocales=await this.cache.get("availableContentLocales",()=>Cs(()=>this.apiProvider().getAvailableSearchLocales(),{contentLocales:[]}))}};Y.elementDefinitions={};Y.styles=ms;fe([(0,Oe.property)()],Y.prototype,"baseUrl",void 0);fe([(0,Oe.property)()],Y.prototype,"apiIntegrationIdentifier",void 0);fe([(0,Oe.property)()],Y.prototype,"apiIntegrationAppVersion",void 0);fe([(0,Oe.property)()],Y.prototype,"uiLocale",void 0);fe([(0,dt.jsonProperty)(null)],Y.prototype,"availableUiLocales",void 0);fe([(0,dt.jsonProperty)(null)],Y.prototype,"metadataConfiguration",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"editorMode",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"noCustom",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"openExternalDocumentInNewTab",void 0);fe([(0,Oe.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],Y.prototype,"noCustomComponent",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"withManualResources",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"navigatorOnline",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"forcedOffline",void 0);fe([(0,Oe.property)({type:Object})],Y.prototype,"apiProvider",void 0);fe([(0,Oe.property)({type:Boolean})],Y.prototype,"authenticationRequired",void 0);fe([(0,dt.jsonProperty)([])],Y.prototype,"messageContexts",void 0);fe([(0,dt.jsonProperty)(void 0)],Y.prototype,"session",void 0);fe([(0,Oe.state)()],Y.prototype,"localesConfiguration",void 0);fe([(0,Oe.state)()],Y.prototype,"availableContentLocales",void 0);var Wi=h(j());function Xp(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;let o,n,i;if(Array.isArray(t)){if(o=t.length,o!=e.length)return!1;for(n=o;n--!==0;)if(!dn(t[n],e[n]))return!1;return!0}if(t instanceof Map&&e instanceof Map){if(t.size!==e.size)return!1;for(n of t.entries())if(!e.has(n[0]))return!1;for(n of t.entries())if(!dn(n[1],e.get(n[0])))return!1;return!0}if(t instanceof Set&&e instanceof Set){if(t.size!==e.size)return!1;for(n of t.entries())if(!e.has(n[0]))return!1;return!0}if(t.constructor===RegExp)return t.source===e.source&&t.flags===e.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===e.valueOf();let a=s=>Object.keys(s).filter(c=>s[c]!=null);if(i=a(t),o=i.length,o!==a(e).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(e,i[n]))return!1;for(n=o;n--!==0;){let s=i[n];if(!dn(t[s],e[s]))return!1}return!0}return t!==t&&e!==e||t==null&&e==null}function dn(t,e){try{return Xp(t,e)}catch{return!1}}function vo(t,e){return!dn(t,e)}function pn(t,e){let o=n=>n[t]===!0;return n=>{if(o(n))return n;let i=e(n);return i[t]=!0,i}}var As=h(j(),1);var xi=t=>{let e=t??{};return(o,n)=>{var i;let a={hasChanged:vo,attribute:!1,...e};(0,As.property)(a)(o,n);let s=o.constructor;s.reduxProperties=new Map(s.reduxProperties),s.reduxProperties.set(n,{selector:(i=e.selector)!==null&&i!==void 0?i:c=>c[n],store:e.store})}};var un=class{constructor(){this.queue=[]}add(e,o=!1){o&&this.clear(e.type),this.queue.push(e)}consume(e){let o=this.queue.find(n=>n.type===e);return o&&(this.queue=this.queue.filter(n=>n!==o)),o}clear(e){typeof e=="string"?this.queue=this.queue.filter(o=>o.type!==e):this.queue=this.queue.filter(o=>!e.test(o.type))}};var Gr=h(j(),1);var ws=h(j(),1);function Rs(t,e){let o=()=>JSON.parse(JSON.stringify(t));return(0,ws.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:vo,...e??{}})}var fn=class{constructor(e=0){this.timeout=e,this.callbacks=[]}run(e,o){return this.callbacks=[e],this.debounce(o)}queue(e,o){return this.callbacks.push(e),this.debounce(o)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(e){return this.promise==null&&(this.promise=new Promise((o,n)=>{this.resolvePromise=o,this.rejectPromise=n})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),e??this.timeout),this.promise}async runCallbacks(){var e,o;let n=[...this.callbacks];this.callbacks=[];let i=(e=this.rejectPromise)!==null&&e!==void 0?e:()=>null,a=(o=this.resolvePromise)!==null&&o!==void 0?o:()=>null;this.clearPromise();for(let s of n)try{await s()}catch(c){i(c);return}a(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var Ls=h(k(),1);var hn=globalThis,Jp=hn.ShadowRoot&&(hn.ShadyCSS===void 0||hn.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,ey=Symbol();var Ts=(t,e)=>{if(Jp)t.adoptedStyleSheets=e.map(o=>o instanceof CSSStyleSheet?o:o.styleSheet);else for(let o of e){let n=document.createElement("style"),i=hn.litNonce;i!==void 0&&n.setAttribute("nonce",i),n.textContent=o.cssText,t.appendChild(n)}};var yn=class extends Ls.LitElement{createRenderRoot(){let e=this.constructor;e.elementDefinitions&&!e.registry&&(e.registry=new CustomElementRegistry,Object.entries(e.elementDefinitions).forEach(([i,a])=>e.registry.define(i,a)));let o={...e.shadowRootOptions,customElements:e.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return Ts(n,e.elementStyles),n}};function Is(t,e,...o){var n;let i=t.querySelector(e);for(let a of o)i=(n=i?.shadowRoot)===null||n===void 0?void 0:n.querySelector(a);return i}var So=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(s=t[c])&&(a=(i<3?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},Ps,Ns=Symbol("constructorPrototype"),_s=Symbol("constructorName"),Ds=Symbol("exportpartsDebouncer"),ks=Symbol("dynamicDependenciesLoaded"),Lt=class extends yn{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[Ps]=new fn(5),this[_s]=this.constructor.name,this[Ns]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[_s]&&Object.setPrototypeOf(this,this[Ns])}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 e=this.constructor;e[ks]||(e[ks]=!0,this.importDynamicDependencies())}importDynamicDependencies(){}updated(e){super.updated(e),this.updateComplete.then(()=>{this.contentAvailableCallback(e),this.focusElementToFocus(e),this.applyCustomStylesheet(e),this.scheduleExportpartsUpdate()})}contentAvailableCallback(e){}focusElementToFocus(e){if(e.has("elementToFocus")&&this.elementToFocus!=null){let{element:o,selector:n,shadowPath:i}=this.elementToFocus;if(n!=null){let a=[...i??[],n];o=Is(this.shadowRoot,...a)}o?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||o?.blur(),this.elementToFocus=void 0}}applyCustomStylesheet(e){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(a=>a.remove()),this.useAdoptedStyleSheets){if(e.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((i=this.customStylesheet)!==null&&i!==void 0?i:"")}catch(a){console.error(a,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let a=document.createElement("style");a.classList.add("ft-lit-element--custom-stylesheet"),a.innerHTML=this.customStylesheet,this.shadowRoot.append(a)}}scheduleExportpartsUpdate(){var e,o,n;(!((e=this.exportpartsPrefix)===null||e===void 0)&&e.trim()||(n=(o=this.exportpartsPrefixes)===null||o===void 0?void 0:o.length)!==null&&n!==void 0&&n)&&this[Ds].run(()=>{var i,a;!((i=this.exportpartsPrefix)===null||i===void 0)&&i.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((a=this.exportpartsPrefixes)===null||a===void 0?void 0:a.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})}setExportpartsAttribute(e){var o,n,i,a,s,c;let p=b=>b!=null&&b.trim().length>0,u=e.filter(p).map(b=>b.trim());if(u.length===0){this.removeAttribute("exportparts");return}let m=new Set;for(let b of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let v=(a=(i=b.getAttribute("part"))===null||i===void 0?void 0:i.split(" "))!==null&&a!==void 0?a:[],S=(c=(s=b.getAttribute("exportparts"))===null||s===void 0?void 0:s.split(",").map(E=>E.split(":")[1]))!==null&&c!==void 0?c:[];new Array(...v,...S).filter(p).map(E=>E.trim()).forEach(E=>m.add(E))}if(m.size===0){this.removeAttribute("exportparts");return}let y=[...m.values()].flatMap(b=>u.map(v=>`${b}:${v}--${b}`));this.setAttribute("exportparts",[...this.part,...y].join(", "))}};Ps=Ds;So([(0,Gr.property)()],Lt.prototype,"exportpartsPrefix",void 0);So([Rs([])],Lt.prototype,"exportpartsPrefixes",void 0);So([(0,Gr.property)()],Lt.prototype,"customStylesheet",void 0);So([(0,Gr.property)()],Lt.prototype,"elementToFocus",void 0);So([(0,Gr.state)()],Lt.prototype,"useAdoptedStyleSheets",void 0);function mn(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var Oo=Symbol("internalReduxEventsUnsubscribers"),Ht=Symbol("internalStoresUnsubscribers"),Sr=Symbol("internalStores"),eu=pn(Symbol("withRedux"),function(t){var e,o,n;class i extends t{constructor(){super(...arguments),this[e]=new Map,this[o]=new Map,this[n]=new Map}get reduxConstructor(){return this.constructor}willUpdate(s){super.willUpdate(s),[...this.reduxConstructor.reduxReactiveProperties].some(c=>s.has(c))&&this.updateFromStores()}getUnnamedStore(){if(this[Sr].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Sr].values()][0]}getStore(s){return s==null?this.getUnnamedStore():this[Sr].get(s)}addStore(s,c){var p;c=(p=c??s.name)!==null&&p!==void 0?p:"default-store",this.unsubscribeFromStore(c),this[Sr].set(c,s),this.subscribeToStore(c,s),this.updateFromStores()}removeStore(s){let c=typeof s=="string"?s:s.name;this.unsubscribeFromStore(c),this[Sr].delete(c)}setupStores(){this.unsubscribeFromStores(),this[Sr].forEach((s,c)=>this.subscribeToStore(c,s)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((s,c)=>{let p=this.constructor.getPropertyOptions(c);if(!p?.attribute||!this.hasAttribute(typeof p?.attribute=="string"?p.attribute:c)){let u=this.getStore(s.store);u&&(s.store?this[Ht].has(s.store):this[Ht].size>0)&&(this[c]=s.selector(u.getState(),this))}})}subscribeToStore(s,c){var p;this[Ht].set(s,c.subscribe(()=>this.updateFromStores())),this[Oo].set(s,[]),mn(c)&&c.eventBus&&((p=this.reduxConstructor.reduxEventListeners)===null||p===void 0||p.forEach((u,m)=>{if(typeof this[m]=="function"&&(!u.store||c.name===u.store)){let y=b=>this[m](b);c.addEventListener(u.eventName,y),this[Oo].get(s).push(()=>c.removeEventListener(u.eventName,y))}})),this.onStoreAvailable(s)}unsubscribeFromStores(){this[Ht].forEach((s,c)=>this.unsubscribeFromStore(c))}unsubscribeFromStore(s){var c;this[Ht].has(s)&&this[Ht].get(s)(),this[Ht].delete(s),(c=this[Oo].get(s))===null||c===void 0||c.forEach(p=>p()),this[Oo].delete(s)}onStoreAvailable(s){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return e=Ht,o=Sr,n=Oo,i.reduxProperties=new Map,i.reduxReactiveProperties=new Set,i.reduxEventListeners=new Map,i}),$s=class extends eu(Lt){};function it(t){for(var e=arguments.length,o=Array(e>1?e-1:0),n=1;n<e;n++)o[n-1]=arguments[n];if(0)var i,a;throw Error("[Immer] minified error nr: "+t+(o.length?" "+o.map(function(s){return"'"+s+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function It(t){return!!t&&!!t[ee]}function pt(t){var e;return!!t&&(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)===lu}(t)||Array.isArray(t)||!!t[Ws]||!!(!((e=t.constructor)===null||e===void 0)&&e[Ws])||Ti(t)||Li(t))}function Or(t,e,o){o===void 0&&(o=!1),Kr(t)===0?(o?Object.keys:jr)(t).forEach(function(n){o&&typeof n=="symbol"||e(n,t[n],t)}):t.forEach(function(n,i){return e(i,n,t)})}function Kr(t){var e=t[ee];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:Ti(t)?2:Li(t)?3:0}function Vr(t,e){return Kr(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function tu(t,e){return Kr(t)===2?t.get(e):t[e]}function Gs(t,e,o){var n=Kr(t);n===2?t.set(e,o):n===3?t.add(o):t[e]=o}function Vs(t,e){return t===e?t!==0||1/t==1/e:t!=t&&e!=e}function Ti(t){return au&&t instanceof Map}function Li(t){return su&&t instanceof Set}function Wt(t){return t.o||t.t}function Ii(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=Zs(t);delete e[ee];for(var o=jr(e),n=0;n<o.length;n++){var i=o[n],a=e[i];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(e[i]={configurable:!0,writable:!0,enumerable:a.enumerable,value:t[i]})}return Object.create(Object.getPrototypeOf(t),e)}function Ni(t,e){return e===void 0&&(e=!1),_i(t)||It(t)||!pt(t)||(Kr(t)>1&&(t.set=t.add=t.clear=t.delete=ru),Object.freeze(t),e&&Or(t,function(o,n){return Ni(n,!0)},!0)),t}function ru(){it(2)}function _i(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function St(t){var e=Ri[t];return e||it(18,t),e}function ou(t,e){Ri[t]||(Ri[t]=e)}function Ei(){return Eo}function vi(t,e){e&&(St("Patches"),t.u=[],t.s=[],t.v=e)}function gn(t){Ai(t),t.p.forEach(nu),t.p=null}function Ai(t){t===Eo&&(Eo=t.l)}function Bs(t){return Eo={p:[],l:Eo,h:t,m:!0,_:0}}function nu(t){var e=t[ee];e.i===0||e.i===1?e.j():e.g=!0}function Si(t,e){e._=e.p.length;var o=e.p[0],n=t!==void 0&&t!==o;return e.h.O||St("ES5").S(e,t,n),n?(o[ee].P&&(gn(e),it(4)),pt(t)&&(t=bn(e,t),e.l||xn(e,t)),e.u&&St("Patches").M(o[ee].t,t,e.u,e.s)):t=bn(e,o,[]),gn(e),e.u&&e.v(e.u,e.s),t!==Ks?t:void 0}function bn(t,e,o){if(_i(e))return e;var n=e[ee];if(!n)return Or(e,function(c,p){return Fs(t,n,e,c,p,o)},!0),e;if(n.A!==t)return e;if(!n.P)return xn(t,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=n.i===4||n.i===5?n.o=Ii(n.k):n.o,a=i,s=!1;n.i===3&&(a=new Set(i),i.clear(),s=!0),Or(a,function(c,p){return Fs(t,n,i,c,p,o,s)}),xn(t,i,!1),o&&t.u&&St("Patches").N(n,o,t.u,t.s)}return n.o}function Fs(t,e,o,n,i,a,s){if(It(i)){var c=bn(t,i,a&&e&&e.i!==3&&!Vr(e.R,n)?a.concat(n):void 0);if(Gs(o,n,c),!It(c))return;t.m=!1}else s&&o.add(i);if(pt(i)&&!_i(i)){if(!t.h.D&&t._<1)return;bn(t,i),e&&e.A.l||xn(t,i)}}function xn(t,e,o){o===void 0&&(o=!1),!t.l&&t.h.D&&t.m&&Ni(e,o)}function Oi(t,e){var o=t[ee];return(o?Wt(o):t)[e]}function Ms(t,e){if(e in t)for(var o=Object.getPrototypeOf(t);o;){var n=Object.getOwnPropertyDescriptor(o,e);if(n)return n;o=Object.getPrototypeOf(o)}}function Gt(t){t.P||(t.P=!0,t.l&&Gt(t.l))}function Ci(t){t.o||(t.o=Ii(t.t))}function wi(t,e,o){var n=Ti(e)?St("MapSet").F(e,o):Li(e)?St("MapSet").T(e,o):t.O?function(i,a){var s=Array.isArray(i),c={i:s?1:0,A:a?a.A:Ei(),P:!1,I:!1,R:{},l:a,t:i,k:null,o:null,j:null,C:!1},p=c,u=Ao;s&&(p=[c],u=Co);var m=Proxy.revocable(p,u),y=m.revoke,b=m.proxy;return c.k=b,c.j=y,b}(e,o):St("ES5").J(e,o);return(o?o.A:Ei()).p.push(n),n}function iu(t){return It(t)||it(22,t),function e(o){if(!pt(o))return o;var n,i=o[ee],a=Kr(o);if(i){if(!i.P&&(i.i<4||!St("ES5").K(i)))return i.t;i.I=!0,n=Us(o,a),i.I=!1}else n=Us(o,a);return Or(n,function(s,c){i&&tu(i.t,s)===c||Gs(n,s,e(c))}),a===3?new Set(n):n}(t)}function Us(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return Ii(t)}function js(){function t(s,c){var p=a[s];return p?p.enumerable=c:a[s]=p={configurable:!0,enumerable:c,get:function(){var u=this[ee];return Ao.get(u,s)},set:function(u){var m=this[ee];Ao.set(m,s,u)}},p}function e(s){for(var c=s.length-1;c>=0;c--){var p=s[c][ee];if(!p.P)switch(p.i){case 5:n(p)&&Gt(p);break;case 4:o(p)&&Gt(p)}}}function o(s){for(var c=s.t,p=s.k,u=jr(p),m=u.length-1;m>=0;m--){var y=u[m];if(y!==ee){var b=c[y];if(b===void 0&&!Vr(c,y))return!0;var v=p[y],S=v&&v[ee];if(S?S.t!==b:!Vs(v,b))return!0}}var E=!!c[ee];return u.length!==jr(c).length+(E?0:1)}function n(s){var c=s.k;if(c.length!==s.t.length)return!0;var p=Object.getOwnPropertyDescriptor(c,c.length-1);if(p&&!p.get)return!0;for(var u=0;u<c.length;u++)if(!c.hasOwnProperty(u))return!0;return!1}function i(s){s.g&&it(3,JSON.stringify(Wt(s)))}var a={};ou("ES5",{J:function(s,c){var p=Array.isArray(s),u=function(y,b){if(y){for(var v=Array(b.length),S=0;S<b.length;S++)Object.defineProperty(v,""+S,t(S,!0));return v}var E=Zs(b);delete E[ee];for(var _=jr(E),I=0;I<_.length;I++){var N=_[I];E[N]=t(N,y||!!E[N].enumerable)}return Object.create(Object.getPrototypeOf(b),E)}(p,s),m={i:p?5:4,A:c?c.A:Ei(),P:!1,I:!1,R:{},l:c,t:s,k:u,o:null,g:!1,C:!1};return Object.defineProperty(u,ee,{value:m,writable:!0}),u},S:function(s,c,p){p?It(c)&&c[ee].A===s&&e(s.p):(s.u&&function u(m){if(m&&typeof m=="object"){var y=m[ee];if(y){var b=y.t,v=y.k,S=y.R,E=y.i;if(E===4)Or(v,function(U){U!==ee&&(b[U]!==void 0||Vr(b,U)?S[U]||u(v[U]):(S[U]=!0,Gt(y)))}),Or(b,function(U){v[U]!==void 0||Vr(v,U)||(S[U]=!1,Gt(y))});else if(E===5){if(n(y)&&(Gt(y),S.length=!0),v.length<b.length)for(var _=v.length;_<b.length;_++)S[_]=!1;else for(var I=b.length;I<v.length;I++)S[I]=!0;for(var N=Math.min(v.length,b.length),$=0;$<N;$++)v.hasOwnProperty($)||(S[$]=!0),S[$]===void 0&&u(v[$])}}}}(s.p[0]),e(s.p))},K:function(s){return s.i===4?o(s):n(s)}})}var zs,Eo,ki=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",au=typeof Map<"u",su=typeof Set<"u",Hs=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",Ks=ki?Symbol.for("immer-nothing"):((zs={})["immer-nothing"]=!0,zs),Ws=ki?Symbol.for("immer-draftable"):"__$immer_draftable",ee=ki?Symbol.for("immer-state"):"__$immer_state";var lu=""+Object.prototype.constructor,jr=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,Zs=Object.getOwnPropertyDescriptors||function(t){var e={};return jr(t).forEach(function(o){e[o]=Object.getOwnPropertyDescriptor(t,o)}),e},Ri={},Ao={get:function(t,e){if(e===ee)return t;var o=Wt(t);if(!Vr(o,e))return function(i,a,s){var c,p=Ms(a,s);return p?"value"in p?p.value:(c=p.get)===null||c===void 0?void 0:c.call(i.k):void 0}(t,o,e);var n=o[e];return t.I||!pt(n)?n:n===Oi(t.t,e)?(Ci(t),t.o[e]=wi(t.A.h,n,t)):n},has:function(t,e){return e in Wt(t)},ownKeys:function(t){return Reflect.ownKeys(Wt(t))},set:function(t,e,o){var n=Ms(Wt(t),e);if(n?.set)return n.set.call(t.k,o),!0;if(!t.P){var i=Oi(Wt(t),e),a=i?.[ee];if(a&&a.t===o)return t.o[e]=o,t.R[e]=!1,!0;if(Vs(o,i)&&(o!==void 0||Vr(t.t,e)))return!0;Ci(t),Gt(t)}return t.o[e]===o&&(o!==void 0||e in t.o)||Number.isNaN(o)&&Number.isNaN(t.o[e])||(t.o[e]=o,t.R[e]=!0),!0},deleteProperty:function(t,e){return Oi(t.t,e)!==void 0||e in t.t?(t.R[e]=!1,Ci(t),Gt(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var o=Wt(t),n=Reflect.getOwnPropertyDescriptor(o,e);return n&&{writable:!0,configurable:t.i!==1||e!=="length",enumerable:n.enumerable,value:o[e]}},defineProperty:function(){it(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){it(12)}},Co={};Or(Ao,function(t,e){Co[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}}),Co.deleteProperty=function(t,e){return Co.set.call(this,t,e,void 0)},Co.set=function(t,e,o){return Ao.set.call(this,t[0],e,o,t[0])};var cu=function(){function t(o){var n=this;this.O=Hs,this.D=!0,this.produce=function(i,a,s){if(typeof i=="function"&&typeof a!="function"){var c=a;a=i;var p=n;return function(E){var _=this;E===void 0&&(E=c);for(var I=arguments.length,N=Array(I>1?I-1:0),$=1;$<I;$++)N[$-1]=arguments[$];return p.produce(E,function(U){var z;return(z=a).call.apply(z,[_,U].concat(N))})}}var u;if(typeof a!="function"&&it(6),s!==void 0&&typeof s!="function"&&it(7),pt(i)){var m=Bs(n),y=wi(n,i,void 0),b=!0;try{u=a(y),b=!1}finally{b?gn(m):Ai(m)}return typeof Promise<"u"&&u instanceof Promise?u.then(function(E){return vi(m,s),Si(E,m)},function(E){throw gn(m),E}):(vi(m,s),Si(u,m))}if(!i||typeof i!="object"){if((u=a(i))===void 0&&(u=i),u===Ks&&(u=void 0),n.D&&Ni(u,!0),s){var v=[],S=[];St("Patches").M(i,u,v,S),s(v,S)}return u}it(21,i)},this.produceWithPatches=function(i,a){if(typeof i=="function")return function(u){for(var m=arguments.length,y=Array(m>1?m-1:0),b=1;b<m;b++)y[b-1]=arguments[b];return n.produceWithPatches(u,function(v){return i.apply(void 0,[v].concat(y))})};var s,c,p=n.produce(i,a,function(u,m){s=u,c=m});return typeof Promise<"u"&&p instanceof Promise?p.then(function(u){return[u,s,c]}):[p,s,c]},typeof o?.useProxies=="boolean"&&this.setUseProxies(o.useProxies),typeof o?.autoFreeze=="boolean"&&this.setAutoFreeze(o.autoFreeze)}var e=t.prototype;return e.createDraft=function(o){pt(o)||it(8),It(o)&&(o=iu(o));var n=Bs(this),i=wi(this,o,void 0);return i[ee].C=!0,Ai(n),i},e.finishDraft=function(o,n){var i=o&&o[ee],a=i.A;return vi(a,n),Si(void 0,a)},e.setAutoFreeze=function(o){this.D=o},e.setUseProxies=function(o){o&&!Hs&&it(20),this.O=o},e.applyPatches=function(o,n){var i;for(i=n.length-1;i>=0;i--){var a=n[i];if(a.path.length===0&&a.op==="replace"){o=a.value;break}}i>-1&&(n=n.slice(i+1));var s=St("Patches").$;return It(o)?s(o,n):this.produce(o,function(c){return s(c,n)})},t}(),qe=new cu,du=qe.produce,yy=qe.produceWithPatches.bind(qe),my=qe.setAutoFreeze.bind(qe),gy=qe.setUseProxies.bind(qe),by=qe.applyPatches.bind(qe),xy=qe.createDraft.bind(qe),vy=qe.finishDraft.bind(qe),vn=du;function Cr(t){"@babel/helpers - typeof";return Cr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Cr(t)}function qs(t,e){if(Cr(t)!="object"||!t)return t;var o=t[Symbol.toPrimitive];if(o!==void 0){var n=o.call(t,e||"default");if(Cr(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ys(t){var e=qs(t,"string");return Cr(e)=="symbol"?e:e+""}function Qs(t,e,o){return(e=Ys(e))in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}function Xs(t,e){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),o.push.apply(o,n)}return o}function Pi(t){for(var e=1;e<arguments.length;e++){var o=arguments[e]!=null?arguments[e]:{};e%2?Xs(Object(o),!0).forEach(function(n){Qs(t,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):Xs(Object(o)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(o,n))})}return t}function Te(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}var Js=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),Di=function(){return Math.random().toString(36).substring(7).split("").join(".")},Sn={INIT:"@@redux/INIT"+Di(),REPLACE:"@@redux/REPLACE"+Di(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Di()}};function pu(t){if(typeof t!="object"||t===null)return!1;for(var e=t;Object.getPrototypeOf(e)!==null;)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}function $i(t,e,o){var n;if(typeof e=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(Te(0));if(typeof e=="function"&&typeof o>"u"&&(o=e,e=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(Te(1));return o($i)(t,e)}if(typeof t!="function")throw new Error(Te(2));var i=t,a=e,s=[],c=s,p=!1;function u(){c===s&&(c=s.slice())}function m(){if(p)throw new Error(Te(3));return a}function y(E){if(typeof E!="function")throw new Error(Te(4));if(p)throw new Error(Te(5));var _=!0;return u(),c.push(E),function(){if(_){if(p)throw new Error(Te(6));_=!1,u();var N=c.indexOf(E);c.splice(N,1),s=null}}}function b(E){if(!pu(E))throw new Error(Te(7));if(typeof E.type>"u")throw new Error(Te(8));if(p)throw new Error(Te(9));try{p=!0,a=i(a,E)}finally{p=!1}for(var _=s=c,I=0;I<_.length;I++){var N=_[I];N()}return E}function v(E){if(typeof E!="function")throw new Error(Te(10));i=E,b({type:Sn.REPLACE})}function S(){var E,_=y;return E={subscribe:function(N){if(typeof N!="object"||N===null)throw new Error(Te(11));function $(){N.next&&N.next(m())}$();var U=_($);return{unsubscribe:U}}},E[Js]=function(){return this},E}return b({type:Sn.INIT}),n={dispatch:b,subscribe:y,getState:m,replaceReducer:v},n[Js]=S,n}function uu(t){Object.keys(t).forEach(function(e){var o=t[e],n=o(void 0,{type:Sn.INIT});if(typeof n>"u")throw new Error(Te(12));if(typeof o(void 0,{type:Sn.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Te(13))})}function el(t){for(var e=Object.keys(t),o={},n=0;n<e.length;n++){var i=e[n];typeof t[i]=="function"&&(o[i]=t[i])}var a=Object.keys(o),s,c;try{uu(o)}catch(p){c=p}return function(u,m){if(u===void 0&&(u={}),c)throw c;if(0)var y;for(var b=!1,v={},S=0;S<a.length;S++){var E=a[S],_=o[E],I=u[E],N=_(I,m);if(typeof N>"u"){var $=m&&m.type;throw new Error(Te(14))}v[E]=N,b=b||N!==I}return b=b||a.length!==Object.keys(u).length,b?v:u}}function Zr(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return e.length===0?function(n){return n}:e.length===1?e[0]:e.reduce(function(n,i){return function(){return n(i.apply(void 0,arguments))}})}function tl(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return function(n){return function(){var i=n.apply(void 0,arguments),a=function(){throw new Error(Te(15))},s={getState:i.getState,dispatch:function(){return a.apply(void 0,arguments)}},c=e.map(function(p){return p(s)});return a=Zr.apply(void 0,c)(i.dispatch),Pi(Pi({},i),{},{dispatch:a})}}}function rl(t){var e=function(n){var i=n.dispatch,a=n.getState;return function(s){return function(c){return typeof c=="function"?c(i,a,t):s(c)}}};return e}var ol=rl();ol.withExtraArgument=rl;var Bi=ol;var ll=function(){var t=function(e,o){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(n[a]=i[a])},t(e,o)};return function(e,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");t(e,o);function n(){this.constructor=e}e.prototype=o===null?Object.create(o):(n.prototype=o.prototype,new n)}}(),fu=function(t,e){var o={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,s;return s={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function c(u){return function(m){return p([u,m])}}function p(u){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,i=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(a=o.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){o.label=u[1];break}if(u[0]===6&&o.label<a[1]){o.label=a[1],a=u;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(u);break}a[2]&&o.ops.pop(),o.trys.pop();continue}u=e.call(t,o)}catch(m){u=[6,m],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},qr=function(t,e){for(var o=0,n=e.length,i=t.length;o<n;o++,i++)t[i]=e[o];return t},hu=Object.defineProperty,yu=Object.defineProperties,mu=Object.getOwnPropertyDescriptors,nl=Object.getOwnPropertySymbols,gu=Object.prototype.hasOwnProperty,bu=Object.prototype.propertyIsEnumerable,il=function(t,e,o){return e in t?hu(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o},Vt=function(t,e){for(var o in e||(e={}))gu.call(e,o)&&il(t,o,e[o]);if(nl)for(var n=0,i=nl(e);n<i.length;n++){var o=i[n];bu.call(e,o)&&il(t,o,e[o])}return t},Fi=function(t,e){return yu(t,mu(e))},xu=function(t,e,o){return new Promise(function(n,i){var a=function(p){try{c(o.next(p))}catch(u){i(u)}},s=function(p){try{c(o.throw(p))}catch(u){i(u)}},c=function(p){return p.done?n(p.value):Promise.resolve(p.value).then(a,s)};c((o=o.apply(t,e)).next())})};var vu=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Zr:Zr.apply(null,arguments)},Fy=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}};function Su(t){if(typeof t!="object"||t===null)return!1;var e=Object.getPrototypeOf(t);if(e===null)return!0;for(var o=e;Object.getPrototypeOf(o)!==null;)o=Object.getPrototypeOf(o);return e===o}var Ou=function(t){ll(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return t.prototype.concat.apply(this,o)},e.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(e.bind.apply(e,qr([void 0],o[0].concat(this)))):new(e.bind.apply(e,qr([void 0],o.concat(this))))},e}(Array),Cu=function(t){ll(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return t.prototype.concat.apply(this,o)},e.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(e.bind.apply(e,qr([void 0],o[0].concat(this)))):new(e.bind.apply(e,qr([void 0],o.concat(this))))},e}(Array);function zi(t){return pt(t)?vn(t,function(){}):t}function Eu(t){return typeof t=="boolean"}function Au(){return function(e){return wu(e)}}function wu(t){t===void 0&&(t={});var e=t.thunk,o=e===void 0?!0:e,n=t.immutableCheck,i=n===void 0?!0:n,a=t.serializableCheck,s=a===void 0?!0:a,c=new Ou;if(o&&(Eu(o)?c.push(Bi):c.push(Bi.withExtraArgument(o.extraArgument))),0){if(i)var p;if(s)var u}return c}var Mi=!0;function cl(t){var e=Au(),o=t||{},n=o.reducer,i=n===void 0?void 0:n,a=o.middleware,s=a===void 0?e():a,c=o.devTools,p=c===void 0?!0:c,u=o.preloadedState,m=u===void 0?void 0:u,y=o.enhancers,b=y===void 0?void 0:y,v;if(typeof i=="function")v=i;else if(Su(i))v=el(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 S=s;if(typeof S=="function"&&(S=S(e),!Mi&&!Array.isArray(S)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!Mi&&S.some(function(U){return typeof U!="function"}))throw new Error("each middleware provided to configureStore must be a function");var E=tl.apply(void 0,S),_=Zr;p&&(_=vu(Vt({trace:!Mi},typeof p=="object"&&p)));var I=new Cu(E),N=I;Array.isArray(b)?N=qr([E],b):typeof b=="function"&&(N=b(I));var $=_.apply(void 0,N);return $i(v,m,$)}function jt(t,e){function o(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];if(e){var a=e.apply(void 0,n);if(!a)throw new Error("prepareAction did not return an object");return Vt(Vt({type:t,payload:a.payload},"meta"in a&&{meta:a.meta}),"error"in a&&{error:a.error})}return{type:t,payload:n[0]}}return o.toString=function(){return""+t},o.type=t,o.match=function(n){return n.type===t},o}function dl(t){var e={},o=[],n,i={addCase:function(a,s){var c=typeof a=="string"?a:a.type;if(c in e)throw new Error("addCase cannot be called with two reducers for the same action type");return e[c]=s,i},addMatcher:function(a,s){return o.push({matcher:a,reducer:s}),i},addDefaultCase:function(a){return n=a,i}};return t(i),[e,o,n]}function Ru(t){return typeof t=="function"}function Tu(t,e,o,n){o===void 0&&(o=[]);var i=typeof e=="function"?dl(e):[e,o,n],a=i[0],s=i[1],c=i[2],p;if(Ru(t))p=function(){return zi(t())};else{var u=zi(t);p=function(){return u}}function m(y,b){y===void 0&&(y=p());var v=qr([a[b.type]],s.filter(function(S){var E=S.matcher;return E(b)}).map(function(S){var E=S.reducer;return E}));return v.filter(function(S){return!!S}).length===0&&(v=[c]),v.reduce(function(S,E){if(E)if(It(S)){var _=S,I=E(_,b);return I===void 0?S:I}else{if(pt(S))return vn(S,function(N){return E(N,b)});var I=E(S,b);if(I===void 0){if(S===null)return S;throw Error("A case reducer on a non-draftable value must not return undefined")}return I}return S},y)}return m.getInitialState=p,m}function Lu(t,e){return t+"/"+e}function pl(t){var e=t.name;if(!e)throw new Error("`name` is a required option for createSlice");typeof process<"u";var o=typeof t.initialState=="function"?t.initialState:zi(t.initialState),n=t.reducers||{},i=Object.keys(n),a={},s={},c={};i.forEach(function(m){var y=n[m],b=Lu(e,m),v,S;"reducer"in y?(v=y.reducer,S=y.prepare):v=y,a[m]=v,s[b]=v,c[m]=S?jt(b,S):jt(b)});function p(){var m=typeof t.extraReducers=="function"?dl(t.extraReducers):[t.extraReducers],y=m[0],b=y===void 0?{}:y,v=m[1],S=v===void 0?[]:v,E=m[2],_=E===void 0?void 0:E,I=Vt(Vt({},b),s);return Tu(o,function(N){for(var $ in I)N.addCase($,I[$]);for(var U=0,z=S;U<z.length;U++){var Me=z[U];N.addMatcher(Me.matcher,Me.reducer)}_&&N.addDefaultCase(_)})}var u;return{name:e,reducer:function(m,y){return u||(u=p()),u(m,y)},actions:c,caseReducers:a,getInitialState:function(){return u||(u=p()),u.getInitialState()}}}var Iu="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Nu=function(t){t===void 0&&(t=21);for(var e="",o=t;o--;)e+=Iu[Math.random()*64|0];return e},_u=["name","message","stack","code"],Ui=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),al=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),ku=function(t){if(typeof t=="object"&&t!==null){for(var e={},o=0,n=_u;o<n.length;o++){var i=n[o];typeof t[i]=="string"&&(e[i]=t[i])}return e}return{message:String(t)}},Hy=function(){function t(e,o,n){var i=jt(e+"/fulfilled",function(m,y,b,v){return{payload:m,meta:Fi(Vt({},v||{}),{arg:b,requestId:y,requestStatus:"fulfilled"})}}),a=jt(e+"/pending",function(m,y,b){return{payload:void 0,meta:Fi(Vt({},b||{}),{arg:y,requestId:m,requestStatus:"pending"})}}),s=jt(e+"/rejected",function(m,y,b,v,S){return{payload:v,error:(n&&n.serializeError||ku)(m||"Rejected"),meta:Fi(Vt({},S||{}),{arg:b,requestId:y,rejectedWithValue:!!v,requestStatus:"rejected",aborted:m?.name==="AbortError",condition:m?.name==="ConditionError"})}}),c=!1,p=typeof AbortController<"u"?AbortController:function(){function m(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return m.prototype.abort=function(){},m}();function u(m){return function(y,b,v){var S=n?.idGenerator?n.idGenerator(m):Nu(),E=new p,_,I=!1;function N(U){_=U,E.abort()}var $=function(){return xu(this,null,function(){var U,z,Me,xt,ke,vt,ve;return fu(this,function(g){switch(g.label){case 0:return g.trys.push([0,4,,5]),xt=(U=n?.condition)==null?void 0:U.call(n,m,{getState:b,extra:v}),Du(xt)?[4,xt]:[3,2];case 1:xt=g.sent(),g.label=2;case 2:if(xt===!1||E.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return I=!0,ke=new Promise(function(x,P){return E.signal.addEventListener("abort",function(){return P({name:"AbortError",message:_||"Aborted"})})}),y(a(S,m,(z=n?.getPendingMeta)==null?void 0:z.call(n,{requestId:S,arg:m},{getState:b,extra:v}))),[4,Promise.race([ke,Promise.resolve(o(m,{dispatch:y,getState:b,extra:v,requestId:S,signal:E.signal,abort:N,rejectWithValue:function(x,P){return new Ui(x,P)},fulfillWithValue:function(x,P){return new al(x,P)}})).then(function(x){if(x instanceof Ui)throw x;return x instanceof al?i(x.payload,S,m,x.meta):i(x,S,m)})])];case 3:return Me=g.sent(),[3,5];case 4:return vt=g.sent(),Me=vt instanceof Ui?s(null,S,m,vt.payload,vt.meta):s(vt,S,m),[3,5];case 5:return ve=n&&!n.dispatchConditionRejection&&s.match(Me)&&Me.meta.condition,ve||y(Me),[2,Me]}})})}();return Object.assign($,{abort:N,requestId:S,arg:m,unwrap:function(){return $.then(Pu)}})}}return Object.assign(u,{pending:a,rejected:s,fulfilled:i,typePrefix:e})}return t.withTypes=function(){return t},t}();function Pu(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function Du(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var ul="listener",fl="completed",hl="cancelled",Wy="task-"+hl,Gy="task-"+fl,Vy=ul+"-"+hl,jy=ul+"-"+fl;var Hi="listenerMiddleware";var Ky=jt(Hi+"/add"),Zy=jt(Hi+"/removeAll"),qy=jt(Hi+"/remove");var sl,Yy=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(t){return(sl||(sl=Promise.resolve())).then(t).catch(function(e){return setTimeout(function(){throw e},0)})},$u=function(t){return function(e){setTimeout(e,t)}},Qy=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:$u(10);js();var Bu=pn(Symbol("withEventBus"),function(t,e){return class extends t{constructor(){super(...arguments),this.eventBus=e??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)}}}),On=class extends Bu(Object){};window.ftReduxStores||(window.ftReduxStores={});var yl=class t extends On{static get(e){var o;let n=typeof e=="string"?e:e.name,i=typeof e=="string"?void 0:e,a=window.ftReduxStores[n];if(mn(a))return a;if(i==null)return;let s=pl({...i,reducers:(o=i.reducers)!==null&&o!==void 0?o:{}}),c=cl({reducer:(p,u)=>u.type==="CLEAR_FT_REDUX_STORE"?s.getInitialState():typeof u.type=="string"&&u.type.startsWith("DEFAULT_VALUE_SETTER__")?{...p,...u.overwrites}:s.reducer(p,u)});return window.ftReduxStores[i.name]=new t(s,c,i.eventBus)}constructor(e,o,n){super(),this.reduxSlice=e,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new un;let i=a=>a!=null?JSON.parse(JSON.stringify(a)):a;this.actions=new Proxy(this.reduxSlice.actions,{get:(a,s,c)=>{let p=s,u=a[p];return u?(...m)=>{let y=u(...m.map(i));return this.reduxStore.dispatch(y),y}:m=>{this.setState({[p]:i(m)})}}}),this.eventBus=n??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE"})}setState(e){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(e).join("_"),overwrites:e})}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(e){throw new Error("Not implemented yet.")}subscribe(e){return this.reduxStore.subscribe(e)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}};var Cn=class{static format(e,o,n,i){return window.moment?window.moment(e).locale(o).format(this.getMomentDateFormat(n,i)):this.getIntlDateTime(e,o,n,i)}static getMomentDateFormat(e,o){return e?o?"lll":"ll":o?"L LT":"L"}static getIntlDateTime(e,o,n,i){let a=typeof e=="string"?new Date(e):e,s=new Intl.DateTimeFormat(o,{dateStyle:n?"medium":"short"}).format(a);if(!i)return s;let c=new Intl.DateTimeFormat(o,{timeStyle:"short"}).format(a);return`${s} ${c}`}};var ml=h(A()),En=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(s=t[c])&&(a=(i<3?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},gl=(0,ml.applyMixinOnce)(Symbol("withDateFormat"),function(t){class e extends t{constructor(...n){super(n),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(T)}dateFormatOptionsChanged(n){return n.has("metadataDescriptors")||n.has("useLongDateFormat")||n.has("useDateTimeFormat")||n.has("uiLocale")}getDateFormatter(n){var i,a;return((a=(i=this.metadataDescriptors.find(c=>c.key===n))===null||i===void 0?void 0:i.date)!==null&&a!==void 0?a:!1)?c=>Cn.format(c,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return En([(0,Wi.property)({type:Boolean})],e.prototype,"useLongDateFormat",void 0),En([(0,Wi.property)({type:Boolean})],e.prototype,"useDateTimeFormat",void 0),En([xi({store:T.name,selector:o=>{var n,i;return(i=(n=o.metadataConfiguration)===null||n===void 0?void 0:n.descriptors)!==null&&i!==void 0?i:[]}})],e.prototype,"metadataDescriptors",void 0),En([xi({store:T.name})],e.prototype,"uiLocale",void 0),e});var Rn=h(A());var An=class extends Re{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetCount(e){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${e}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(e){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${e}`),this.CACHE_DURATION)}isAuthenticated(){let e=T.getState().session;return!!e?.sessionAuthenticated}};var wn=class extends Re{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let e=T.getState().session;return!!e?.sessionAuthenticated}};var Fu="ft-user-assets",Mu={setAssetCount:(t,e)=>{let{userAssetType:o,count:n}=e.payload.assetCount;t.assetCounts.allAsset[o]=n},clearAssetCount:t=>{Object.values(gr).forEach(e=>{t.assetCounts.allAsset[e]=void 0})},setBookmarkCountByMap:(t,e)=>{let o=e.payload.mapId;t.assetCounts.bookmarkByMap[o]=e.payload.count},clearBookmarkCountByMap:t=>{t.assetCounts.bookmarkByMap={}}},Ye=Rn.FtReduxStore.get({name:Fu,reducers:Mu,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(gr).map(t=>[t,void 0])),bookmarkByMap:{}},assetLabels:[]}}),Gi=class{constructor(e=new An,o=new wn){this.assetCountsService=e,this.assetLabelsService=o,this.currentSession=T.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new on,this.savedSearchesService=new sn,T.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:o}=T.getState();(0,Rn.deepEqual)((e=this.currentSession)===null||e===void 0?void 0:e.profile,o?.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),Ye.actions.clearAssetCount(),Ye.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),Ye.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),Ye.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();Ye.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let e=await this.assetLabelsService.getUserAssetLabels();Ye.actions.assetLabels(e)}async loadAssetCount(e){let o=await this.assetCountsService.getUserAssetCount(e);o&&Ye.actions.setAssetCount({assetCount:o})}async loadBookmarkByMapId(e){let o=await this.assetCountsService.getUserBookmarkCountByMap(e);o&&Ye.actions.setBookmarkCountByMap({count:o.count,mapId:e})}async reloadAssetCount(e){this.assetCountsService.clearCache();let o=Object.keys(Ye.getState().assetCounts.bookmarkByMap).length!==0;e===gr.BOOKMARKS&&o&&Ye.actions.clearBookmarkCountByMap(),Ye.getState().assetCounts.allAsset[e]!==void 0&&await this.loadAssetCount(e)}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var e;if(this.bookmarksAreUsed){let o=!((e=this.currentSession)===null||e===void 0)&&e.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;Ye.actions.bookmarks(o)}}},Vi=new Gi;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=Vi);(0,bl.customElement)("ft-app-context")(Y);var Tn=class extends Re{constructor(e){super(!0,e),this.cache.registerFinal("search-configuration",async()=>(await this.awaitApi).getSearchConfiguration())}async launchSearch(e){let o={...e,metadataFilters:this.sortFilters(e.metadataFilters),facets:[...e.facets].sort((n,i)=>n.id.localeCompare(i.id))};return this.cache.get("search-"+this.hash(o),async()=>(await this.awaitApi).search(e),2*60*1e3)}async launchSuggest(e){let o={...e,metadataFilters:this.sortFilters(e.metadataFilters)};return this.cache.get("suggest-"+this.hash(o),async()=>(await this.awaitApi).getSuggestions(e),2*60*1e3)}async getAvailableSearchLocales(){return this.cache.get("available-locales",async()=>(await this.awaitApi).getAvailableSearchLocales())}async getConfiguration(){return this.cache.get("search-configuration")}sortFilters(e){return e.map(o=>o.valueFilter==null?o:{...o,valueFilter:{...o.valueFilter,values:[...o.valueFilter.values].sort((n,i)=>n.localeCompare(i))}}).sort((o,n)=>o.key.localeCompare(n.key))}};var Ro=t=>t.request.virtualField===Ur.TITLE_ONLY&&t.request.scope===zr.DOCUMENTS,Ln=class t extends Event{constructor(){super(t.eventName)}};Ln.eventName="search-context-clear-all-filters";var wo=class t{static build(e,o){return new t(Ha(e.trim()||"context"),o)}constructor(e,o){this.store=e,this.ignoreEmptyQuery=!1,this.openExternalDocumentInNewTab=!1,this.localesDebouncer=new Qe.Debouncer(10),this.searchDebouncer=new Qe.Debouncer(100),this.launchSearch=n=>this.searchDebouncer.run(()=>this.fetchSearchData(n??this.buildSearchRequest(this.store.getState()))),this.buildSearchRequest=n=>({...n.request,facets:this.facetIds.map(i=>({id:i}))}),this.suggestDebouncer=new Qe.Debouncer(300),this.launchSuggest=n=>this.suggestDebouncer.run(()=>this.fetchSuggestData(n??this.buildSuggestRequest(this.store.getState()))),this.buildSuggestRequest=n=>{var i;return{input:n.liveQuery,metadataFilters:n.request.metadataFilters,sort:(i=n.request.sort)!==null&&i!==void 0?i:[],sortId:n.request.sortId,contentLocale:n.request.contentLocale,scope:n.request.scope}},this.service=o??new Tn,this.service.cache.addEventListener("clear-cache",n=>{n.detail.clearedKeys.includes("available-locales")&&this.updateLocales()}),this.searchWatcher=(0,Qe.watch)(e,this.buildSearchRequest,this.launchSearch),this.suggestWatcher=(0,Qe.watch)(e,this.buildSuggestRequest,this.launchSuggest)}async initService(){return this.updateLocales(),this.service.getConfiguration().then(e=>{this.store.actions.configuration(e),this.setSortId(this.store.getState().request.sortId)}),this.launchSearch()}setQuery(e){this.store.actions.setRequestQuery(e),this.store.actions.liveQuery(e),this.store.actions.setPageNumber(1)}setContentLocale(e){var o;let n=(o=this.store.getState().locales)!==null&&o!==void 0?o:[],i=this.store.getState().request.contentLocale;if(e!=i){if(n.length>0){let a=s=>n.some(c=>c.lang==s);a(e)||(e=a(i)?i:n[0].lang)}this.store.actions.setRequestContentLocale(e),this.store.actions.setPageNumber(1),this.store.actions.setRequestFilters([])}return e}forceContentLocale(e){this.store.actions.setRequestContentLocale(e)}setPageSize(e){this.store.actions.setPageSize(e)}setPageNumber(e){this.store.actions.setPageNumber(e)}get sortOptions(){var e,o;return(o=(e=this.store.getState().configuration)===null||e===void 0?void 0:e.sortOptions)!==null&&o!==void 0?o:[]}setSort(e){this.store.actions.setRequestSort(e),this.store.actions.setPageNumber(1)}setSortId(e){var o;if(this.store.actions.setPageNumber(1),e==null||this.sortOptions.length==0)return this.store.actions.setRequestSortId(e),e;let n=(o=this.sortOptions.find(i=>i.id==e))!==null&&o!==void 0?o:this.sortOptions[0];return this.store.actions.setRequestSortId(n.id),n.id}setFilters(e){let o=e.filter(n=>!n.valueFilter||n.valueFilter.values.length>0);this.store.actions.setRequestFilters(o),this.store.actions.setPageNumber(1)}setClusterSortCriterion(e){this.store.actions.setRequestClusterSortCriterion(e)}setSearchInDocumentTitlesOnly(e){e?(this.store.actions.setRequestVirtualField(Ur.TITLE_ONLY),this.store.actions.setRequestScope(zr.DOCUMENTS)):(this.store.actions.setRequestVirtualField(Ur.EVERYWHERE),this.store.actions.setRequestScope(zr.DEFAULT))}setVirtualField(e){this.store.actions.setRequestVirtualField(e)}get searchInDocumentTitlesOnly(){return Ro(this.store.getState())}clearAllFilters(){this.setFilters([]),this.store.dispatchEvent(new Ln)}addFacet(e){this.facetIds=[...this.facetIds,e]}replaceFacet(e,o){let n=this.facetIds.filter(i=>i!=e);o&&n.push(o),this.facetIds=n}get facetIds(){var e;let o=this.store.getState().request;return[...new Set([...o.facets.map(n=>n.id),...((e=o.metadataFilters)!==null&&e!==void 0?e:[]).map(n=>n.key)])]}set facetIds(e){let n=[...new Set(e)].map(i=>({id:i}));this.store.actions.setRequestFacets(n)}setFilter(e,o){this.setValueFilter(e,o)}setValueFilter(e,o){let n=this.store.getState().request.metadataFilters,i={key:e,valueFilter:{values:o,negative:!1}},a=[...n.filter(s=>!s.valueFilter),...n.filter(s=>s.valueFilter&&s.key!==i.key),i];this.setFilters(a)}setDateFilter(e,o){let n=this.store.getState().request.metadataFilters,i={key:e,dateFilter:{type:o}},a=[...n.filter(s=>!s.dateFilter),...n.filter(s=>s.dateFilter&&s.key!==i.key),i];this.setFilters(a)}removeDateFilter(e){let o=this.store.getState().request.metadataFilters,n=[...o.filter(i=>!i.dateFilter),...o.filter(i=>i.dateFilter&&i.key!==e)];this.setFilters(n)}setRangeFilter(e,o,n){let i=this.store.getState().request.metadataFilters,a={key:e,rangeFilter:{from:o,to:n}},s=[...i.filter(c=>!c.rangeFilter),...i.filter(c=>c.rangeFilter&&c.key!==a.key),a];this.setFilters(s)}removeRangeFilter(e){let o=this.store.getState().request.metadataFilters,n=[...o.filter(i=>!i.rangeFilter),...o.filter(i=>i.rangeFilter&&i.key!==e)];this.setFilters(n)}setLiveQuery(e){this.store.actions.liveQuery(e)}setRequest(e){this.store.actions.setRequest({...e,facets:this.store.getState().request.facets}),this.store.actions.liveQuery(e.query),this.store.actions.setPageNumber(1)}setScope(e){this.store.actions.setRequestScope(e)}setOtherQueryParams(e){this.store.actions.setOtherQueryParams(e)}setIgnoreEmptyQuery(e){this.ignoreEmptyQuery=e}setOpenExternalDocumentInNewTab(e){this.openExternalDocumentInNewTab=e}updateLocales(){return this.localesDebouncer.run(async()=>this.store.actions.locales((await this.service.getAvailableSearchLocales()).contentLocales))}async fetchSearchData(e){var o,n,i,a;try{if((o=this.cancelableSearch)===null||o===void 0||o.cancel(),this.store.actions.paging(void 0),this.ignoreEmptyQuery&&e.query.length==0)this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0);else{this.cancelableSearch=(0,Qe.cancelable)(this.service.launchSearch(e));let s=await this.cancelableSearch;if(this.store.actions.announcements(s.announcements),s.paging.currentPage<=1)this.store.actions.results(s.results),this.store.actions.facets(s.facets),this.store.actions.spellcheck(s.spellcheck);else{let c=((n=this.store.getState().results)!==null&&n!==void 0?n:[]).concat(s.results);this.store.actions.results(c),this.store.commands.clear(/^focus-result-/),this.store.commands.add({type:`focus-result-${(s.paging.currentPage-1)*((i=e.paging.perPage)!==null&&i!==void 0?i:20)+1}`})}this.store.actions.paging(s.paging)}}catch(s){s instanceof Qe.CanceledPromiseError||(console.error(s),(a=this.errorHandler)===null||a===void 0||a.call(this,s))}}async fetchSuggestData(e){var o;try{(o=this.cancelableSuggest)===null||o===void 0||o.cancel(),this.cancelableSuggest=(0,Qe.cancelable)(this.service.launchSuggest(e));let n=await this.cancelableSuggest;this.store.actions.suggestResults(n.suggestions)}catch(n){!(n instanceof Qe.CanceledPromiseError)&&this.errorHandler&&this.errorHandler(n)}}clear(){this.store.clear()}clearResults(){this.store.actions.paging(void 0),this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0)}};var Uu=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(s=t[c])&&(a=(i<3?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},Ki=class extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}},xl=Symbol("registerInterval"),ji=Symbol("registerAttempts"),zu=40,Hu=(0,In.applyMixinOnce)(Symbol("toFtSearchComponent"),function(t){class e extends t{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[ji]=0,this[xl]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null||this[ji]>zu?window.clearInterval(this[xl]):(this[ji]++,this.dispatchEvent(new Ki))}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return Uu([(0,vl.state)()],e.prototype,"stateManager",void 0),e}),Kt=class extends Hu(In.FtLitElementRedux){};var Ea=h(A());var Vn=h(k()),Le=h(j()),Pd=h(Zt()),ho=h(A());var Nl=h(A());var Ll=h(k()),Ce=h(j()),Il=h(Zt()),To=h(A());var Rl=h(k()),ce=h(A()),Ol=ce.FtCssVariableFactory.extend("--ft-ripple-color","",ce.designSystemVariables.colorContent),O={color:Ol,backgroundColor:ce.FtCssVariableFactory.extend("--ft-ripple-background-color","",Ol),opacityContentOnSurfacePressed:ce.FtCssVariableFactory.external(ce.designSystemVariables.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:ce.FtCssVariableFactory.external(ce.designSystemVariables.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:ce.FtCssVariableFactory.external(ce.designSystemVariables.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:ce.FtCssVariableFactory.external(ce.designSystemVariables.opacityContentOnSurfaceSelected,"Design system"),borderRadius:ce.FtCssVariableFactory.create("--ft-ripple-border-radius","","SIZE","0px")},Cl=ce.FtCssVariableFactory.extend("--ft-ripple-color","",ce.designSystemVariables.colorPrimary),El={color:Cl,backgroundColor:ce.FtCssVariableFactory.extend("--ft-ripple-background-color","",Cl)},Al=ce.FtCssVariableFactory.extend("--ft-ripple-color","",ce.designSystemVariables.colorSecondary),wl={color:Al,backgroundColor:ce.FtCssVariableFactory.extend("--ft-ripple-background-color","",Al)},Tl=Rl.css`
|
|
16
16
|
:host {
|
|
17
17
|
display: contents;
|
|
18
18
|
}
|
|
@@ -95,7 +95,7 @@ Also for action icons.`,c.colorGray200),contentGlobalSubtle:o.extend("--ft-conte
|
|
|
95
95
|
`;var sh={setRequest:(t,e)=>{t.request=e.payload},setRequestQuery:(t,e)=>{t.request.query=e.payload},setRequestContentLocale:(t,e)=>{t.request.contentLocale=e.payload},setPageSize:(t,e)=>{var r;let n=+((r=e.payload)!==null&&r!==void 0?r:20);t.request.paging.perPage=isNaN(n)?20:fr(1,n,1e3)},setPageNumber:(t,e)=>{t.request.paging.page=isNaN(e.payload)?1:Math.max(1,e.payload)},setRequestSort:(t,e)=>{t.request.sort=e.payload},setRequestSortId:(t,e)=>{t.request.sortId=e.payload},setRequestFilters:(t,e)=>{t.request.metadataFilters=e.payload},setRequestFacets:(t,e)=>{t.request.facets=e.payload},setRequestVirtualField:(t,e)=>{t.request.virtualField=e.payload},setRequestScope:(t,e)=>{t.request.scope=e.payload},setOtherQueryParams:(t,e)=>{t.request.otherQueryParams=e.payload},setRequestClusterSortCriterion:(t,e)=>{var r;t.request.clusterSortCriterions=(r=e.payload)!==null&&r!==void 0?r:[]}},xd=t=>kt.get({name:"ft-search-"+t,initialState:{request:{query:"",clusterSortCriterions:[],metadataFilters:[],facets:[],sort:[],sortId:void 0,paging:{page:1,perPage:20}},liveQuery:"",paging:void 0,facets:void 0,spellcheck:void 0,locales:[],results:void 0,announcements:void 0,suggestResults:void 0,configuration:void 0},reducers:sh});var vd=L`
|
|
96
96
|
`;var lh="ft-app-info",Rr=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};Rr.eventName="authentication-change";var ch={session:(t,e)=>{De(t.session,e.payload)||(t.session=e.payload,setTimeout(()=>k.dispatchEvent(new Rr(e.payload)),0))}},k=kt.get({name:lh,reducers:ch,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],availableContentLocales:[],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,authenticationRequired:!1}});var Tr=class t{static get(e){let{baseUrl:r,apiIntegrationIdentifier:n}=k.getState(),i=e??n;if(r&&i&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(r,i,!0)}static await(e){return new Promise(r=>{let n=t.get(e);if(n)r(n);else{let i=k.subscribe(()=>{n=t.get(e),n&&(i(),r(n))})}})}};var Un=class{constructor(e){this.overrideApi=e}get api(){var e;return(e=this.overrideApi)!==null&&e!==void 0?e:Tr.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):Tr.await()}};var Pe=class extends Un{constructor(e=!0,r){var n;super(r),this.sortObjectFields=(a,s)=>typeof s!="object"||s==null||Array.isArray(s)?s:Object.fromEntries(Object.entries(s).sort(([l],[d])=>l.localeCompare(d)));let i=this.constructor;i.commonCache=(n=i.commonCache)!==null&&n!==void 0?n:new yt,this.cache=e?i.commonCache:new yt}clearCache(){this.cache.clearAll()}hash(e){return String(Array.from(JSON.stringify(e,this.sortObjectFields)).reduce((r,n)=>0|31*r+n.charCodeAt(0),0))}};var zn=class extends Pe{async listMyBookmarks(){let e=k.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),5*60*1e3):[]}};var $s=class{addCommand(e,r=!1){k.commands.add(e,r)}consumeCommand(e){return k.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new $s;var Sd,ao=class extends CustomEvent{constructor(e){super("ft-i18n-context-loaded",{detail:e})}},dh=Symbol("clearAfterUnitTest"),Hn=class extends Sn(Pe){constructor(e){super(),this.messageContextProvider=e,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[Sd]=()=>{this.defaultMessages={},this.cache=new yt,this.listeners={}},this.currentUiLocale=k.getState().uiLocale,k.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:e}=k.getState();this.currentUiLocale!==e&&(this.currentUiLocale=e,this.cache.clearAll(),this.notifyAll())}addContext(e){let r=e.name.toLowerCase();this.cache.setFinal(r,e),this.notify(r)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(e,r){var n;if(e=e.toLowerCase(),r&&Object.keys(r).length>0){let i={...(n=this.defaultMessages[e])!==null&&n!==void 0?n:{},...r};De(this.defaultMessages[e],i)||(this.defaultMessages[e]=i,await this.notify(e))}return this.fetchContext(e)}resolveContext(e){var r,n;return this.fetchContext(e),(n=(r=this.cache.getNow(e))===null||r===void 0?void 0:r.messages)!==null&&n!==void 0?n:{}}resolveRawMessage(e,r){let n=e.toLowerCase();return this.resolveContext(n)[r]}resolveMessage(e,r,...n){var i;let a=e.toLowerCase(),s=this.resolveContext(a);return new Vo((i=this.defaultMessages[a])!==null&&i!==void 0?i:{},s).resolve(r,...n)}async fetchContext(e){let r=!this.cache.has(e),n;try{n=await this.cache.get(e,()=>this.messageContextProvider(this.currentUiLocale,e)),r&&await this.notify(e)}catch(i){!(i instanceof mt)&&r&&console.error(i)}return n}subscribe(e,r){var n;return e=e.toLowerCase(),this.listeners[e]=(n=this.listeners[e])!==null&&n!==void 0?n:new Set,this.listeners[e].add(r),()=>{var i;return(i=this.listeners[e])===null||i===void 0?void 0:i.delete(r)}}async notifyAll(){let e=Object.keys(this.listeners);document.body.dispatchEvent(new ao({loadedContexts:e})),this.dispatchEvent(new ao({loadedContexts:e})),await Promise.all(e.map(r=>this.notify(r,!1)))}async notify(e,r=!0){r&&(document.body.dispatchEvent(new ao({loadedContexts:[e]})),this.dispatchEvent(new ao({loadedContexts:[e]}))),this.listeners[e]!=null&&await Promise.all([...this.listeners[e].values()].map(n=>vn(0).then(()=>n()).catch(()=>null)))}};Sd=dh;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends Hn{constructor(){super(async(t,e)=>(await this.awaitApi).getFluidTopicsMessageContext(t,e))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends Hn{constructor(){super(async(t,e)=>(await this.awaitApi).getCustomMessageContext(t,e))}});var so=window.FluidTopicsI18nService,Wn=window.FluidTopicsCustomI18nService;var Ds=class{highlightHtml(e,r,n){Wa(e,r,n)}};window.FluidTopicsHighlightHtmlService=new Ds;var Vn=class extends Pe{async listMySearches(){let{session:e}=k.getState();return dd(e,be.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),5*60*1e3):[]}};var Fs=class{isDate(e){var r,n,i,a;return(a=(i=((n=(r=k.getState().metadataConfiguration)===null||r===void 0?void 0:r.descriptors)!==null&&n!==void 0?n:[]).find(l=>l.key===e))===null||i===void 0?void 0:i.date)!==null&&a!==void 0?a:!1}format(e,r){var n,i,a;return Cr.format(e,(n=r?.locale)!==null&&n!==void 0?n:k.getState().uiLocale,(i=r?.longFormat)!==null&&i!==void 0?i:!1,(a=r?.withTime)!==null&&a!==void 0?a:!1)}};window.FluidTopicsDateService=new Fs;var Xo=class{static get(e,r){var n,i;let a=k.getState(),{lang:s,region:l}=(i=(n=a.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&i!==void 0?i:{lang:"en",region:"US"};return new no(a.baseUrl,e??20,a.searchInAllLanguagesAllowed,r??`${s}-${l}`)}};var jn=class extends Pe{async sendDocumentStartDisplayEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.start_display event")}async sendTopicStartDisplayEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send topic.start_display event")}async sendKhubSearchEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send khub.search event")}async sendDocumentSearchEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.search event")}async sendSearchPageSelectEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send search_page.select event")}async sendSearchResultOpenContextMenuEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send search_result.open_context_menu event")}sortEventArrays(e){let r=Object.entries(e).map(([n,i])=>Array.isArray(i)?[n,i.map(a=>typeof a=="object"&&a!=null&&!Array.isArray(a)?this.sortEventArrays(a):a).sort((a,s)=>typeof a=="object"&&a!==null&&"key"in a?a.key.localeCompare(s.key):typeof a=="string"&&typeof s=="string"?a.localeCompare(s):String(a).localeCompare(String(s)))]:typeof i=="object"&&i!==null?[n,this.sortEventArrays(i)]:[n,i]);return Object.fromEntries(r)}sendEvents(e,r){let n="anything not undefined";return this.cache.get("analytics-event-"+this.hash(e),async()=>(await this.awaitApi).sendEvents(e).then(()=>n).catch(i=>(console.info(r),console.debug(i),n)),1e3)}};var Ms=class{urlToSearchRequest(e){return Xo.get().parse(e)}searchRequestToUrl(e){return Xo.get().serialize(e)}};window.FluidTopicsUrlService=new Ms;var Lr=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{currentItem:e}})}};Lr.eventName="change";var Bs=class{itemName(e){return`fluid-topics-history-item-${e}`}get(e){let r=sessionStorage.getItem(this.itemName(e));return r?JSON.parse(r):void 0}set(e,r){sessionStorage.setItem(this.itemName(e),JSON.stringify(r))}},Od=new Bs;var Gn=class t extends At{static build(){return new t(window.history,Od,()=>window.location,!1)}constructor(e,r,n,i){var a,s;super(),this.history=e,this.historyStorage=r,this.windowLocation=n,this.states=[],this.realPushState=e.pushState,this.realReplaceState=e.replaceState,this.initialIndex=(s=(a=e.state)===null||a===void 0?void 0:a.index)!==null&&s!==void 0?s:e.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(i)}setCurrentState(e,r=!1){let n=r&&this.currentIndex===e.index-1;this.currentState={...this.buildCurrentState(),...e},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),De(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,window.location.href]),setTimeout(()=>this.dispatchEvent(new Lr(this.currentItem())),0)}installProxies(){let e=r=>(n,i,[a,s,l])=>{let d=r(),u={...d===this.currentIndex?this.currentState:void 0,...a,index:d,href:typeof l=="string"?l:(l??this.windowLocation()).href};n.apply(i,[u,s,l]),this.setCurrentState(u,!0)};this.history.pushState=new Proxy(this.history.pushState,{apply:e(()=>this.currentIndex+1)}),this.history.replaceState=new Proxy(this.history.replaceState,{apply:e(()=>this.currentIndex)})}initEventListeners(){window.addEventListener("popstate",e=>this.setCurrentState(e.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(e){for(let r=this.history.length-1;r>=0;r--)e?this.states[r]=this.historyStorage.get(r):setTimeout(()=>this.states[r]=this.historyStorage.get(r),this.history.length-r)}updateCurrentState(e){var r;let n={...this.buildCurrentState(),...e,index:this.currentIndex,title:(r=e?.title)!==null&&r!==void 0?r:this.currentState.title};this.setCurrentState(n)}addHistoryChangeListener(e){this.addEventListener(Lr.eventName,e)}removeHistoryChangeListener(e){this.removeEventListener(Lr.eventName,e)}currentItem(){return Io(this.currentState)}back(){let e=this.previousDifferentMajorPosition();e>=0?this.history.go(e-this.currentIndex):this.currentIndex!==this.initialIndex?this.history.go(this.initialIndex-this.currentIndex):this.history.back()}backwardItem(){return Io(this.states[this.previousDifferentMajorPosition()])}previousDifferentMajorPosition(){let e=this.currentIndex>0?this.currentIndex-1:0;for(;e>0&&!this.isDifferentMajorState(e);)e--;return e}forward(){let e=this.nextMajorPosition();e&&e<this.states.length?this.history.go(e-this.currentIndex):this.history.forward()}forwardItem(){let e=this.nextMajorPosition();if(e)return Io(this.states[e])}nextMajorPosition(){let e=this.currentIndex;if(!(e>=this.states.length)){do e++;while(e<this.states.length&&!this.isDifferentMajorState(e));return this.getHigherPositionInTheSameState(e)}}getHigherPositionInTheSameState(e){var r;let n=(r=this.states[e])===null||r===void 0?void 0:r.majorStateId;if(!n)return e;let i=e,a=e+1;for(;this.states.length>a&&!this.isDifferentMajorState(a,n);)this.hasState(a)&&(i=a),a++;return i}buildCurrentState(){var e,r;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(r=(e=this.history.state)===null||e===void 0?void 0:e.title)!==null&&r!==void 0?r:document.title}}hasState(e){return this.states[e]!=null}isDifferentMajorState(e,r){var n;if(!this.hasState(e))return!1;let i=r??this.currentState.majorStateId,a=(n=this.states[e])===null||n===void 0?void 0:n.majorStateId;return a==null||a!=i}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=Gn.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),addHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(t),removeHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(t)});var Cd=k;function Ed(t,e){var r;return Cd.getState().authenticationRequired&&!(!((r=Cd.getState().session)===null||r===void 0)&&r.sessionAuthenticated)?Promise.resolve(e):t()}var xe=function(t,e,r,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,r,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(a=(i<3?s(a):i>3?s(e,r,a):s(e,r))||a);return i>3&&a&&Object.defineProperty(e,r,a),a},ne=class extends H{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.apiIntegrationAppVersion="ft-integration-app-version",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=()=>Tr.get(),this.authenticationRequired=!1,this.messageContexts=[],this.cache=new yt,this.cleanSessionDebouncer=new pe,this.reloadConfiguration=()=>{this.cache.clear("availableContentLocales"),this.updateAvailableContentLocales()}}render(){return T`
|
|
97
97
|
<slot></slot>
|
|
98
|
-
`}connectedCallback(){super.connectedCallback(),k.addEventListener(Rr.eventName,this.reloadConfiguration)}disconnectedCallback(){k.addEventListener(Rr.eventName,this.reloadConfiguration),super.disconnectedCallback()}update(e){var r,n,i,a,s,l,d;super.update(e),e.has("baseUrl")&&(k.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),e.has("apiIntegrationIdentifier")&&k.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("apiIntegrationAppVersion")&&k.actions.apiIntegrationAppVersion(this.apiIntegrationAppVersion),e.has("uiLocale")&&k.actions.uiLocale(this.uiLocale),e.has("metadataConfiguration")&&k.actions.metadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&k.actions.noCustom(this.noCustom),e.has("editorMode")&&k.actions.editorMode(this.editorMode),e.has("noCustomComponent")&&k.actions.noCustomComponent(this.noCustomComponent),e.has("session")&&k.actions.session(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(u=>so.addContext(u)),e.has("openExternalDocumentInNewTab")&&k.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&k.actions.navigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&k.actions.forcedOffline(this.forcedOffline),e.has("localesConfiguration")&&(k.actions.defaultLocales((r=this.localesConfiguration)===null||r===void 0?void 0:r.defaultLocales),k.actions.availableUiLocales((i=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&i!==void 0?i:[]),k.actions.searchInAllLanguagesAllowed((s=(a=this.localesConfiguration)===null||a===void 0?void 0:a.allLanguagesAllowed)!==null&&s!==void 0?s:!1)),e.has("authenticationRequired")&&k.actions.authenticationRequired(this.authenticationRequired),e.has("availableContentLocales")&&k.actions.availableContentLocales((d=(l=this.availableContentLocales)===null||l===void 0?void 0:l.contentLocales)!==null&&d!==void 0?d:[]),setTimeout(()=>this.updateIfNeeded())}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.session==null&&this.updateSession(),this.metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration(),this.availableContentLocales==null&&this.updateAvailableContentLocales())}async updateSession(){this.session=await this.cache.get("session",async()=>{let e=await this.apiProvider().getCurrentSession();return e.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.session=void 0},e.idleTimeoutInMillis),e})}async updateMetadataConfiguration(){this.metadataConfiguration=await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration())}async updateLocalesConfiguration(){this.localesConfiguration=await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration())}async updateAvailableContentLocales(){this.availableContentLocales=await this.cache.get("availableContentLocales",()=>Ed(()=>this.apiProvider().getAvailableSearchLocales(),{contentLocales:[]}))}};ne.elementDefinitions={};ne.styles=vd;xe([m()],ne.prototype,"baseUrl",void 0);xe([m()],ne.prototype,"apiIntegrationIdentifier",void 0);xe([m()],ne.prototype,"apiIntegrationAppVersion",void 0);xe([m()],ne.prototype,"uiLocale",void 0);xe([Oe(null)],ne.prototype,"availableUiLocales",void 0);xe([Oe(null)],ne.prototype,"metadataConfiguration",void 0);xe([m({type:Boolean})],ne.prototype,"editorMode",void 0);xe([m({type:Boolean})],ne.prototype,"noCustom",void 0);xe([m({type:Boolean})],ne.prototype,"openExternalDocumentInNewTab",void 0);xe([m({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],ne.prototype,"noCustomComponent",void 0);xe([m({type:Boolean})],ne.prototype,"withManualResources",void 0);xe([m({type:Boolean})],ne.prototype,"navigatorOnline",void 0);xe([m({type:Boolean})],ne.prototype,"forcedOffline",void 0);xe([m({type:Object})],ne.prototype,"apiProvider",void 0);xe([m({type:Boolean})],ne.prototype,"authenticationRequired",void 0);xe([Oe([])],ne.prototype,"messageContexts",void 0);xe([Oe(void 0)],ne.prototype,"session",void 0);xe([W()],ne.prototype,"localesConfiguration",void 0);xe([W()],ne.prototype,"availableContentLocales",void 0);var Kn=function(t,e,r,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,r,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(a=(i<3?s(a):i>3?s(e,r,a):s(e,r))||a);return i>3&&a&&Object.defineProperty(e,r,a),a},wd=ge(Symbol("withDateFormat"),function(t){class e extends t{constructor(...n){super(n),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(k)}dateFormatOptionsChanged(n){return n.has("metadataDescriptors")||n.has("useLongDateFormat")||n.has("useDateTimeFormat")||n.has("uiLocale")}getDateFormatter(n){var i,a;return((a=(i=this.metadataDescriptors.find(l=>l.key===n))===null||i===void 0?void 0:i.date)!==null&&a!==void 0?a:!1)?l=>Cr.format(l,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return Kn([m({type:Boolean})],e.prototype,"useLongDateFormat",void 0),Kn([m({type:Boolean})],e.prototype,"useDateTimeFormat",void 0),Kn([fe({store:k.name,selector:r=>{var n,i;return(i=(n=r.metadataConfiguration)===null||n===void 0?void 0:n.descriptors)!==null&&i!==void 0?i:[]}})],e.prototype,"metadataDescriptors",void 0),Kn([fe({store:k.name})],e.prototype,"uiLocale",void 0),e});var Zn=class extends Pe{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetCount(e){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${e}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(e){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${e}`),this.CACHE_DURATION)}isAuthenticated(){let e=k.getState().session;return!!e?.sessionAuthenticated}};var qn=class extends Pe{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let e=k.getState().session;return!!e?.sessionAuthenticated}};var ph="ft-user-assets",uh={setAssetCount:(t,e)=>{let{userAssetType:r,count:n}=e.payload.assetCount;t.assetCounts.allAsset[r]=n},clearAssetCount:t=>{Object.values(Or).forEach(e=>{t.assetCounts.allAsset[e]=void 0})},setBookmarkCountByMap:(t,e)=>{let r=e.payload.mapId;t.assetCounts.bookmarkByMap[r]=e.payload.count},clearBookmarkCountByMap:t=>{t.assetCounts.bookmarkByMap={}}},Qe=kt.get({name:ph,reducers:uh,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(Or).map(t=>[t,void 0])),bookmarkByMap:{}},assetLabels:[]}}),Us=class{constructor(e=new Zn,r=new qn){this.assetCountsService=e,this.assetLabelsService=r,this.currentSession=k.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new zn,this.savedSearchesService=new Vn,k.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:r}=k.getState();De((e=this.currentSession)===null||e===void 0?void 0:e.profile,r?.profile)||(this.currentSession=r,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),Qe.actions.clearAssetCount(),Qe.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),Qe.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),Qe.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();Qe.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let e=await this.assetLabelsService.getUserAssetLabels();Qe.actions.assetLabels(e)}async loadAssetCount(e){let r=await this.assetCountsService.getUserAssetCount(e);r&&Qe.actions.setAssetCount({assetCount:r})}async loadBookmarkByMapId(e){let r=await this.assetCountsService.getUserBookmarkCountByMap(e);r&&Qe.actions.setBookmarkCountByMap({count:r.count,mapId:e})}async reloadAssetCount(e){this.assetCountsService.clearCache();let r=Object.keys(Qe.getState().assetCounts.bookmarkByMap).length!==0;e===Or.BOOKMARKS&&r&&Qe.actions.clearBookmarkCountByMap(),Qe.getState().assetCounts.allAsset[e]!==void 0&&await this.loadAssetCount(e)}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var e;if(this.bookmarksAreUsed){let r=!((e=this.currentSession)===null||e===void 0)&&e.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;Qe.actions.bookmarks(r)}}},zs=new Us;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=zs);j("ft-app-context")(ne);var Yn=class extends Pe{constructor(e){super(!0,e),this.cache.registerFinal("search-configuration",async()=>(await this.awaitApi).getSearchConfiguration())}async launchSearch(e){let r={...e,metadataFilters:this.sortFilters(e.metadataFilters),facets:[...e.facets].sort((n,i)=>n.id.localeCompare(i.id))};return this.cache.get("search-"+this.hash(r),async()=>(await this.awaitApi).search(e),2*60*1e3)}async launchSuggest(e){let r={...e,metadataFilters:this.sortFilters(e.metadataFilters)};return this.cache.get("suggest-"+this.hash(r),async()=>(await this.awaitApi).getSuggestions(e),2*60*1e3)}async getAvailableSearchLocales(){return this.cache.get("available-locales",async()=>(await this.awaitApi).getAvailableSearchLocales())}async getConfiguration(){return this.cache.get("search-configuration")}sortFilters(e){return e.map(r=>r.valueFilter==null?r:{...r,valueFilter:{...r.valueFilter,values:[...r.valueFilter.values].sort((n,i)=>n.localeCompare(i))}}).sort((r,n)=>r.key.localeCompare(n.key))}};var en=t=>t.request.virtualField===Sr.TITLE_ONLY&&t.request.scope===oo.DOCUMENTS,Qn=class t extends Event{constructor(){super(t.eventName)}};Qn.eventName="search-context-clear-all-filters";var Jo=class t{static build(e,r){return new t(xd(e.trim()||"context"),r)}constructor(e,r){this.store=e,this.ignoreEmptyQuery=!1,this.openExternalDocumentInNewTab=!1,this.localesDebouncer=new pe(10),this.searchDebouncer=new pe(100),this.launchSearch=n=>this.searchDebouncer.run(()=>this.fetchSearchData(n??this.buildSearchRequest(this.store.getState()))),this.buildSearchRequest=n=>({...n.request,facets:this.facetIds.map(i=>({id:i}))}),this.suggestDebouncer=new pe(300),this.launchSuggest=n=>this.suggestDebouncer.run(()=>this.fetchSuggestData(n??this.buildSuggestRequest(this.store.getState()))),this.buildSuggestRequest=n=>{var i;return{input:n.liveQuery,metadataFilters:n.request.metadataFilters,sort:(i=n.request.sort)!==null&&i!==void 0?i:[],sortId:n.request.sortId,contentLocale:n.request.contentLocale,scope:n.request.scope}},this.service=r??new Yn,this.service.cache.addEventListener("clear-cache",n=>{n.detail.clearedKeys.includes("available-locales")&&this.updateLocales()}),this.searchWatcher=eo(e,this.buildSearchRequest,this.launchSearch),this.suggestWatcher=eo(e,this.buildSuggestRequest,this.launchSuggest)}async initService(){return this.updateLocales(),this.service.getConfiguration().then(e=>this.store.actions.configuration(e)),this.launchSearch()}setQuery(e){this.store.actions.setRequestQuery(e),this.store.actions.liveQuery(e),this.store.actions.setPageNumber(1)}setContentLocale(e){var r;let n=(r=this.store.getState().locales)!==null&&r!==void 0?r:[],i=this.store.getState().request.contentLocale;if(e!=i){if(n.length>0){let a=s=>n.some(l=>l.lang==s);a(e)||(e=a(i)?i:n[0].lang)}this.store.actions.setRequestContentLocale(e),this.store.actions.setPageNumber(1),this.store.actions.setRequestFilters([])}return e}forceContentLocale(e){this.store.actions.setRequestContentLocale(e)}setPageSize(e){this.store.actions.setPageSize(e)}setPageNumber(e){this.store.actions.setPageNumber(e)}get sortOptions(){var e,r;return(r=(e=this.store.getState().configuration)===null||e===void 0?void 0:e.sortOptions)!==null&&r!==void 0?r:[]}setSort(e){this.store.actions.setRequestSort(e),this.store.actions.setPageNumber(1)}setSortId(e){var r;if(this.store.actions.setPageNumber(1),e==null||this.sortOptions.length==0)return this.store.actions.setRequestSortId(e),e;let n=(r=this.sortOptions.find(i=>i.id==e))!==null&&r!==void 0?r:this.sortOptions[0];return this.store.actions.setRequestSortId(n.id),n.id}setFilters(e){let r=e.filter(n=>!n.valueFilter||n.valueFilter.values.length>0);this.store.actions.setRequestFilters(r),this.store.actions.setPageNumber(1)}setClusterSortCriterion(e){this.store.actions.setRequestClusterSortCriterion(e)}setSearchInDocumentTitlesOnly(e){e?(this.store.actions.setRequestVirtualField(Sr.TITLE_ONLY),this.store.actions.setRequestScope(oo.DOCUMENTS)):(this.store.actions.setRequestVirtualField(Sr.EVERYWHERE),this.store.actions.setRequestScope(oo.DEFAULT))}setVirtualField(e){this.store.actions.setRequestVirtualField(e)}get searchInDocumentTitlesOnly(){return en(this.store.getState())}clearAllFilters(){this.setFilters([]),this.store.dispatchEvent(new Qn)}addFacet(e){this.facetIds=[...this.facetIds,e]}replaceFacet(e,r){let n=this.facetIds.filter(i=>i!=e);r&&n.push(r),this.facetIds=n}get facetIds(){var e;let r=this.store.getState().request;return[...new Set([...r.facets.map(n=>n.id),...((e=r.metadataFilters)!==null&&e!==void 0?e:[]).map(n=>n.key)])]}set facetIds(e){let n=[...new Set(e)].map(i=>({id:i}));this.store.actions.setRequestFacets(n)}setFilter(e,r){this.setValueFilter(e,r)}setValueFilter(e,r){let n=this.store.getState().request.metadataFilters,i={key:e,valueFilter:{values:r,negative:!1}},a=[...n.filter(s=>!s.valueFilter),...n.filter(s=>s.valueFilter&&s.key!==i.key),i];this.setFilters(a)}setDateFilter(e,r){let n=this.store.getState().request.metadataFilters,i={key:e,dateFilter:{type:r}},a=[...n.filter(s=>!s.dateFilter),...n.filter(s=>s.dateFilter&&s.key!==i.key),i];this.setFilters(a)}removeDateFilter(e){let r=this.store.getState().request.metadataFilters,n=[...r.filter(i=>!i.dateFilter),...r.filter(i=>i.dateFilter&&i.key!==e)];this.setFilters(n)}setRangeFilter(e,r,n){let i=this.store.getState().request.metadataFilters,a={key:e,rangeFilter:{from:r,to:n}},s=[...i.filter(l=>!l.rangeFilter),...i.filter(l=>l.rangeFilter&&l.key!==a.key),a];this.setFilters(s)}removeRangeFilter(e){let r=this.store.getState().request.metadataFilters,n=[...r.filter(i=>!i.rangeFilter),...r.filter(i=>i.rangeFilter&&i.key!==e)];this.setFilters(n)}setLiveQuery(e){this.store.actions.liveQuery(e)}setRequest(e){this.store.actions.setRequest({...e,facets:this.store.getState().request.facets}),this.store.actions.liveQuery(e.query),this.store.actions.setPageNumber(1)}setScope(e){this.store.actions.setRequestScope(e)}setOtherQueryParams(e){this.store.actions.setOtherQueryParams(e)}setIgnoreEmptyQuery(e){this.ignoreEmptyQuery=e}setOpenExternalDocumentInNewTab(e){this.openExternalDocumentInNewTab=e}updateLocales(){return this.localesDebouncer.run(async()=>this.store.actions.locales((await this.service.getAvailableSearchLocales()).contentLocales))}async fetchSearchData(e){var r,n,i,a;try{if((r=this.cancelableSearch)===null||r===void 0||r.cancel(),this.store.actions.paging(void 0),this.ignoreEmptyQuery&&e.query.length==0)this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0);else{this.cancelableSearch=Ur(this.service.launchSearch(e));let s=await this.cancelableSearch;if(this.store.actions.announcements(s.announcements),s.paging.currentPage<=1)this.store.actions.results(s.results),this.store.actions.facets(s.facets),this.store.actions.spellcheck(s.spellcheck);else{let l=((n=this.store.getState().results)!==null&&n!==void 0?n:[]).concat(s.results);this.store.actions.results(l),this.store.commands.clear(/^focus-result-/),this.store.commands.add({type:`focus-result-${(s.paging.currentPage-1)*((i=e.paging.perPage)!==null&&i!==void 0?i:20)+1}`})}this.store.actions.paging(s.paging)}}catch(s){s instanceof mt||(console.error(s),(a=this.errorHandler)===null||a===void 0||a.call(this,s))}}async fetchSuggestData(e){var r;try{(r=this.cancelableSuggest)===null||r===void 0||r.cancel(),this.cancelableSuggest=Ur(this.service.launchSuggest(e));let n=await this.cancelableSuggest;this.store.actions.suggestResults(n.suggestions)}catch(n){!(n instanceof mt)&&this.errorHandler&&this.errorHandler(n)}}clear(){this.store.clear()}clearResults(){this.store.actions.paging(void 0),this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0)}};var fh=function(t,e,r,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,r,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(a=(i<3?s(a):i>3?s(e,r,a):s(e,r))||a);return i>3&&a&&Object.defineProperty(e,r,a),a},Ws=class extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}},Ad=Symbol("registerInterval"),Hs=Symbol("registerAttempts"),hh=40,mh=ge(Symbol("toFtSearchComponent"),function(t){class e extends t{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[Hs]=0,this[Ad]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null||this[Hs]>hh?window.clearInterval(this[Ad]):(this[Hs]++,this.dispatchEvent(new Ws))}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return fh([W()],e.prototype,"stateManager",void 0),e}),Yt=class extends mh(Nt){};var Rd=o.extend("--ft-ripple-color","",N.colorContent),R={color:Rd,backgroundColor:o.extend("--ft-ripple-background-color","",Rd),opacityContentOnSurfacePressed:o.external(N.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:o.external(N.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:o.external(N.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:o.external(N.opacityContentOnSurfaceSelected,"Design system"),borderRadius:o.create("--ft-ripple-border-radius","","SIZE","0px")},Td=o.extend("--ft-ripple-color","",N.colorPrimary),Ld={color:Td,backgroundColor:o.extend("--ft-ripple-background-color","",Td)},_d=o.extend("--ft-ripple-color","",N.colorSecondary),Id={color:_d,backgroundColor:o.extend("--ft-ripple-background-color","",_d)},Nd=L`
|
|
98
|
+
`}connectedCallback(){super.connectedCallback(),k.addEventListener(Rr.eventName,this.reloadConfiguration)}disconnectedCallback(){k.addEventListener(Rr.eventName,this.reloadConfiguration),super.disconnectedCallback()}update(e){var r,n,i,a,s,l,d;super.update(e),e.has("baseUrl")&&(k.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),e.has("apiIntegrationIdentifier")&&k.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("apiIntegrationAppVersion")&&k.actions.apiIntegrationAppVersion(this.apiIntegrationAppVersion),e.has("uiLocale")&&k.actions.uiLocale(this.uiLocale),e.has("metadataConfiguration")&&k.actions.metadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&k.actions.noCustom(this.noCustom),e.has("editorMode")&&k.actions.editorMode(this.editorMode),e.has("noCustomComponent")&&k.actions.noCustomComponent(this.noCustomComponent),e.has("session")&&k.actions.session(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(u=>so.addContext(u)),e.has("openExternalDocumentInNewTab")&&k.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&k.actions.navigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&k.actions.forcedOffline(this.forcedOffline),e.has("localesConfiguration")&&(k.actions.defaultLocales((r=this.localesConfiguration)===null||r===void 0?void 0:r.defaultLocales),k.actions.availableUiLocales((i=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&i!==void 0?i:[]),k.actions.searchInAllLanguagesAllowed((s=(a=this.localesConfiguration)===null||a===void 0?void 0:a.allLanguagesAllowed)!==null&&s!==void 0?s:!1)),e.has("authenticationRequired")&&k.actions.authenticationRequired(this.authenticationRequired),e.has("availableContentLocales")&&k.actions.availableContentLocales((d=(l=this.availableContentLocales)===null||l===void 0?void 0:l.contentLocales)!==null&&d!==void 0?d:[]),setTimeout(()=>this.updateIfNeeded())}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.session==null&&this.updateSession(),this.metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration(),this.availableContentLocales==null&&this.updateAvailableContentLocales())}async updateSession(){this.session=await this.cache.get("session",async()=>{let e=await this.apiProvider().getCurrentSession();return e.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.session=void 0},e.idleTimeoutInMillis),e})}async updateMetadataConfiguration(){this.metadataConfiguration=await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration())}async updateLocalesConfiguration(){this.localesConfiguration=await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration())}async updateAvailableContentLocales(){this.availableContentLocales=await this.cache.get("availableContentLocales",()=>Ed(()=>this.apiProvider().getAvailableSearchLocales(),{contentLocales:[]}))}};ne.elementDefinitions={};ne.styles=vd;xe([m()],ne.prototype,"baseUrl",void 0);xe([m()],ne.prototype,"apiIntegrationIdentifier",void 0);xe([m()],ne.prototype,"apiIntegrationAppVersion",void 0);xe([m()],ne.prototype,"uiLocale",void 0);xe([Oe(null)],ne.prototype,"availableUiLocales",void 0);xe([Oe(null)],ne.prototype,"metadataConfiguration",void 0);xe([m({type:Boolean})],ne.prototype,"editorMode",void 0);xe([m({type:Boolean})],ne.prototype,"noCustom",void 0);xe([m({type:Boolean})],ne.prototype,"openExternalDocumentInNewTab",void 0);xe([m({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],ne.prototype,"noCustomComponent",void 0);xe([m({type:Boolean})],ne.prototype,"withManualResources",void 0);xe([m({type:Boolean})],ne.prototype,"navigatorOnline",void 0);xe([m({type:Boolean})],ne.prototype,"forcedOffline",void 0);xe([m({type:Object})],ne.prototype,"apiProvider",void 0);xe([m({type:Boolean})],ne.prototype,"authenticationRequired",void 0);xe([Oe([])],ne.prototype,"messageContexts",void 0);xe([Oe(void 0)],ne.prototype,"session",void 0);xe([W()],ne.prototype,"localesConfiguration",void 0);xe([W()],ne.prototype,"availableContentLocales",void 0);var Kn=function(t,e,r,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,r,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(a=(i<3?s(a):i>3?s(e,r,a):s(e,r))||a);return i>3&&a&&Object.defineProperty(e,r,a),a},wd=ge(Symbol("withDateFormat"),function(t){class e extends t{constructor(...n){super(n),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(k)}dateFormatOptionsChanged(n){return n.has("metadataDescriptors")||n.has("useLongDateFormat")||n.has("useDateTimeFormat")||n.has("uiLocale")}getDateFormatter(n){var i,a;return((a=(i=this.metadataDescriptors.find(l=>l.key===n))===null||i===void 0?void 0:i.date)!==null&&a!==void 0?a:!1)?l=>Cr.format(l,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return Kn([m({type:Boolean})],e.prototype,"useLongDateFormat",void 0),Kn([m({type:Boolean})],e.prototype,"useDateTimeFormat",void 0),Kn([fe({store:k.name,selector:r=>{var n,i;return(i=(n=r.metadataConfiguration)===null||n===void 0?void 0:n.descriptors)!==null&&i!==void 0?i:[]}})],e.prototype,"metadataDescriptors",void 0),Kn([fe({store:k.name})],e.prototype,"uiLocale",void 0),e});var Zn=class extends Pe{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetCount(e){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${e}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(e){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${e}`),this.CACHE_DURATION)}isAuthenticated(){let e=k.getState().session;return!!e?.sessionAuthenticated}};var qn=class extends Pe{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let e=k.getState().session;return!!e?.sessionAuthenticated}};var ph="ft-user-assets",uh={setAssetCount:(t,e)=>{let{userAssetType:r,count:n}=e.payload.assetCount;t.assetCounts.allAsset[r]=n},clearAssetCount:t=>{Object.values(Or).forEach(e=>{t.assetCounts.allAsset[e]=void 0})},setBookmarkCountByMap:(t,e)=>{let r=e.payload.mapId;t.assetCounts.bookmarkByMap[r]=e.payload.count},clearBookmarkCountByMap:t=>{t.assetCounts.bookmarkByMap={}}},Qe=kt.get({name:ph,reducers:uh,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(Or).map(t=>[t,void 0])),bookmarkByMap:{}},assetLabels:[]}}),Us=class{constructor(e=new Zn,r=new qn){this.assetCountsService=e,this.assetLabelsService=r,this.currentSession=k.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new zn,this.savedSearchesService=new Vn,k.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:r}=k.getState();De((e=this.currentSession)===null||e===void 0?void 0:e.profile,r?.profile)||(this.currentSession=r,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),Qe.actions.clearAssetCount(),Qe.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),Qe.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),Qe.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();Qe.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let e=await this.assetLabelsService.getUserAssetLabels();Qe.actions.assetLabels(e)}async loadAssetCount(e){let r=await this.assetCountsService.getUserAssetCount(e);r&&Qe.actions.setAssetCount({assetCount:r})}async loadBookmarkByMapId(e){let r=await this.assetCountsService.getUserBookmarkCountByMap(e);r&&Qe.actions.setBookmarkCountByMap({count:r.count,mapId:e})}async reloadAssetCount(e){this.assetCountsService.clearCache();let r=Object.keys(Qe.getState().assetCounts.bookmarkByMap).length!==0;e===Or.BOOKMARKS&&r&&Qe.actions.clearBookmarkCountByMap(),Qe.getState().assetCounts.allAsset[e]!==void 0&&await this.loadAssetCount(e)}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var e;if(this.bookmarksAreUsed){let r=!((e=this.currentSession)===null||e===void 0)&&e.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;Qe.actions.bookmarks(r)}}},zs=new Us;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=zs);j("ft-app-context")(ne);var Yn=class extends Pe{constructor(e){super(!0,e),this.cache.registerFinal("search-configuration",async()=>(await this.awaitApi).getSearchConfiguration())}async launchSearch(e){let r={...e,metadataFilters:this.sortFilters(e.metadataFilters),facets:[...e.facets].sort((n,i)=>n.id.localeCompare(i.id))};return this.cache.get("search-"+this.hash(r),async()=>(await this.awaitApi).search(e),2*60*1e3)}async launchSuggest(e){let r={...e,metadataFilters:this.sortFilters(e.metadataFilters)};return this.cache.get("suggest-"+this.hash(r),async()=>(await this.awaitApi).getSuggestions(e),2*60*1e3)}async getAvailableSearchLocales(){return this.cache.get("available-locales",async()=>(await this.awaitApi).getAvailableSearchLocales())}async getConfiguration(){return this.cache.get("search-configuration")}sortFilters(e){return e.map(r=>r.valueFilter==null?r:{...r,valueFilter:{...r.valueFilter,values:[...r.valueFilter.values].sort((n,i)=>n.localeCompare(i))}}).sort((r,n)=>r.key.localeCompare(n.key))}};var en=t=>t.request.virtualField===Sr.TITLE_ONLY&&t.request.scope===oo.DOCUMENTS,Qn=class t extends Event{constructor(){super(t.eventName)}};Qn.eventName="search-context-clear-all-filters";var Jo=class t{static build(e,r){return new t(xd(e.trim()||"context"),r)}constructor(e,r){this.store=e,this.ignoreEmptyQuery=!1,this.openExternalDocumentInNewTab=!1,this.localesDebouncer=new pe(10),this.searchDebouncer=new pe(100),this.launchSearch=n=>this.searchDebouncer.run(()=>this.fetchSearchData(n??this.buildSearchRequest(this.store.getState()))),this.buildSearchRequest=n=>({...n.request,facets:this.facetIds.map(i=>({id:i}))}),this.suggestDebouncer=new pe(300),this.launchSuggest=n=>this.suggestDebouncer.run(()=>this.fetchSuggestData(n??this.buildSuggestRequest(this.store.getState()))),this.buildSuggestRequest=n=>{var i;return{input:n.liveQuery,metadataFilters:n.request.metadataFilters,sort:(i=n.request.sort)!==null&&i!==void 0?i:[],sortId:n.request.sortId,contentLocale:n.request.contentLocale,scope:n.request.scope}},this.service=r??new Yn,this.service.cache.addEventListener("clear-cache",n=>{n.detail.clearedKeys.includes("available-locales")&&this.updateLocales()}),this.searchWatcher=eo(e,this.buildSearchRequest,this.launchSearch),this.suggestWatcher=eo(e,this.buildSuggestRequest,this.launchSuggest)}async initService(){return this.updateLocales(),this.service.getConfiguration().then(e=>{this.store.actions.configuration(e),this.setSortId(this.store.getState().request.sortId)}),this.launchSearch()}setQuery(e){this.store.actions.setRequestQuery(e),this.store.actions.liveQuery(e),this.store.actions.setPageNumber(1)}setContentLocale(e){var r;let n=(r=this.store.getState().locales)!==null&&r!==void 0?r:[],i=this.store.getState().request.contentLocale;if(e!=i){if(n.length>0){let a=s=>n.some(l=>l.lang==s);a(e)||(e=a(i)?i:n[0].lang)}this.store.actions.setRequestContentLocale(e),this.store.actions.setPageNumber(1),this.store.actions.setRequestFilters([])}return e}forceContentLocale(e){this.store.actions.setRequestContentLocale(e)}setPageSize(e){this.store.actions.setPageSize(e)}setPageNumber(e){this.store.actions.setPageNumber(e)}get sortOptions(){var e,r;return(r=(e=this.store.getState().configuration)===null||e===void 0?void 0:e.sortOptions)!==null&&r!==void 0?r:[]}setSort(e){this.store.actions.setRequestSort(e),this.store.actions.setPageNumber(1)}setSortId(e){var r;if(this.store.actions.setPageNumber(1),e==null||this.sortOptions.length==0)return this.store.actions.setRequestSortId(e),e;let n=(r=this.sortOptions.find(i=>i.id==e))!==null&&r!==void 0?r:this.sortOptions[0];return this.store.actions.setRequestSortId(n.id),n.id}setFilters(e){let r=e.filter(n=>!n.valueFilter||n.valueFilter.values.length>0);this.store.actions.setRequestFilters(r),this.store.actions.setPageNumber(1)}setClusterSortCriterion(e){this.store.actions.setRequestClusterSortCriterion(e)}setSearchInDocumentTitlesOnly(e){e?(this.store.actions.setRequestVirtualField(Sr.TITLE_ONLY),this.store.actions.setRequestScope(oo.DOCUMENTS)):(this.store.actions.setRequestVirtualField(Sr.EVERYWHERE),this.store.actions.setRequestScope(oo.DEFAULT))}setVirtualField(e){this.store.actions.setRequestVirtualField(e)}get searchInDocumentTitlesOnly(){return en(this.store.getState())}clearAllFilters(){this.setFilters([]),this.store.dispatchEvent(new Qn)}addFacet(e){this.facetIds=[...this.facetIds,e]}replaceFacet(e,r){let n=this.facetIds.filter(i=>i!=e);r&&n.push(r),this.facetIds=n}get facetIds(){var e;let r=this.store.getState().request;return[...new Set([...r.facets.map(n=>n.id),...((e=r.metadataFilters)!==null&&e!==void 0?e:[]).map(n=>n.key)])]}set facetIds(e){let n=[...new Set(e)].map(i=>({id:i}));this.store.actions.setRequestFacets(n)}setFilter(e,r){this.setValueFilter(e,r)}setValueFilter(e,r){let n=this.store.getState().request.metadataFilters,i={key:e,valueFilter:{values:r,negative:!1}},a=[...n.filter(s=>!s.valueFilter),...n.filter(s=>s.valueFilter&&s.key!==i.key),i];this.setFilters(a)}setDateFilter(e,r){let n=this.store.getState().request.metadataFilters,i={key:e,dateFilter:{type:r}},a=[...n.filter(s=>!s.dateFilter),...n.filter(s=>s.dateFilter&&s.key!==i.key),i];this.setFilters(a)}removeDateFilter(e){let r=this.store.getState().request.metadataFilters,n=[...r.filter(i=>!i.dateFilter),...r.filter(i=>i.dateFilter&&i.key!==e)];this.setFilters(n)}setRangeFilter(e,r,n){let i=this.store.getState().request.metadataFilters,a={key:e,rangeFilter:{from:r,to:n}},s=[...i.filter(l=>!l.rangeFilter),...i.filter(l=>l.rangeFilter&&l.key!==a.key),a];this.setFilters(s)}removeRangeFilter(e){let r=this.store.getState().request.metadataFilters,n=[...r.filter(i=>!i.rangeFilter),...r.filter(i=>i.rangeFilter&&i.key!==e)];this.setFilters(n)}setLiveQuery(e){this.store.actions.liveQuery(e)}setRequest(e){this.store.actions.setRequest({...e,facets:this.store.getState().request.facets}),this.store.actions.liveQuery(e.query),this.store.actions.setPageNumber(1)}setScope(e){this.store.actions.setRequestScope(e)}setOtherQueryParams(e){this.store.actions.setOtherQueryParams(e)}setIgnoreEmptyQuery(e){this.ignoreEmptyQuery=e}setOpenExternalDocumentInNewTab(e){this.openExternalDocumentInNewTab=e}updateLocales(){return this.localesDebouncer.run(async()=>this.store.actions.locales((await this.service.getAvailableSearchLocales()).contentLocales))}async fetchSearchData(e){var r,n,i,a;try{if((r=this.cancelableSearch)===null||r===void 0||r.cancel(),this.store.actions.paging(void 0),this.ignoreEmptyQuery&&e.query.length==0)this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0);else{this.cancelableSearch=Ur(this.service.launchSearch(e));let s=await this.cancelableSearch;if(this.store.actions.announcements(s.announcements),s.paging.currentPage<=1)this.store.actions.results(s.results),this.store.actions.facets(s.facets),this.store.actions.spellcheck(s.spellcheck);else{let l=((n=this.store.getState().results)!==null&&n!==void 0?n:[]).concat(s.results);this.store.actions.results(l),this.store.commands.clear(/^focus-result-/),this.store.commands.add({type:`focus-result-${(s.paging.currentPage-1)*((i=e.paging.perPage)!==null&&i!==void 0?i:20)+1}`})}this.store.actions.paging(s.paging)}}catch(s){s instanceof mt||(console.error(s),(a=this.errorHandler)===null||a===void 0||a.call(this,s))}}async fetchSuggestData(e){var r;try{(r=this.cancelableSuggest)===null||r===void 0||r.cancel(),this.cancelableSuggest=Ur(this.service.launchSuggest(e));let n=await this.cancelableSuggest;this.store.actions.suggestResults(n.suggestions)}catch(n){!(n instanceof mt)&&this.errorHandler&&this.errorHandler(n)}}clear(){this.store.clear()}clearResults(){this.store.actions.paging(void 0),this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0)}};var fh=function(t,e,r,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,r,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(a=(i<3?s(a):i>3?s(e,r,a):s(e,r))||a);return i>3&&a&&Object.defineProperty(e,r,a),a},Ws=class extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}},Ad=Symbol("registerInterval"),Hs=Symbol("registerAttempts"),hh=40,mh=ge(Symbol("toFtSearchComponent"),function(t){class e extends t{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[Hs]=0,this[Ad]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null||this[Hs]>hh?window.clearInterval(this[Ad]):(this[Hs]++,this.dispatchEvent(new Ws))}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return fh([W()],e.prototype,"stateManager",void 0),e}),Yt=class extends mh(Nt){};var Rd=o.extend("--ft-ripple-color","",N.colorContent),R={color:Rd,backgroundColor:o.extend("--ft-ripple-background-color","",Rd),opacityContentOnSurfacePressed:o.external(N.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:o.external(N.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:o.external(N.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:o.external(N.opacityContentOnSurfaceSelected,"Design system"),borderRadius:o.create("--ft-ripple-border-radius","","SIZE","0px")},Td=o.extend("--ft-ripple-color","",N.colorPrimary),Ld={color:Td,backgroundColor:o.extend("--ft-ripple-background-color","",Td)},_d=o.extend("--ft-ripple-color","",N.colorSecondary),Id={color:_d,backgroundColor:o.extend("--ft-ripple-background-color","",_d)},Nd=L`
|
|
99
99
|
:host {
|
|
100
100
|
display: contents;
|
|
101
101
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluid-topics/ft-search-selected-facets",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.28",
|
|
4
4
|
"description": "List of selected facets in a designed search page context",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Lit"
|
|
@@ -19,13 +19,13 @@
|
|
|
19
19
|
"url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@fluid-topics/ft-chip": "1.3.
|
|
23
|
-
"@fluid-topics/ft-search-context": "1.3.
|
|
24
|
-
"@fluid-topics/ft-search-period-filter": "1.3.
|
|
25
|
-
"@fluid-topics/ft-search-type": "1.3.
|
|
26
|
-
"@fluid-topics/ft-tooltip": "1.3.
|
|
27
|
-
"@fluid-topics/ft-wc-utils": "1.3.
|
|
22
|
+
"@fluid-topics/ft-chip": "1.3.28",
|
|
23
|
+
"@fluid-topics/ft-search-context": "1.3.28",
|
|
24
|
+
"@fluid-topics/ft-search-period-filter": "1.3.28",
|
|
25
|
+
"@fluid-topics/ft-search-type": "1.3.28",
|
|
26
|
+
"@fluid-topics/ft-tooltip": "1.3.28",
|
|
27
|
+
"@fluid-topics/ft-wc-utils": "1.3.28",
|
|
28
28
|
"lit": "3.1.0"
|
|
29
29
|
},
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "face2509aeead24e78a16af4ffd2123ef281dac2"
|
|
31
31
|
}
|