@fluid-topics/ft-reader-search-in-document 1.2.24 → 1.2.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1159,7 +1159,7 @@ Also for action icons.`,c.colorGray200),contentGlobalSubtle:r.extend("--ft-conte
1159
1159
  `});var _d,kd,za=f(()=>{"use strict";_d=b(B()),kd=_d.css`
1160
1160
  `});var Xo,Lh,Ga,Ph,D,Fe=f(()=>{"use strict";Xo=b(N()),Lh="ft-app-info",Ga=class extends CustomEvent{constructor(e){super("authentication-change",{detail:e})}},Ph={session:(t,e)=>{(0,Xo.deepEqual)(t.session,e.payload)||(t.session=e.payload,setTimeout(()=>D.dispatchEvent(new Ga(e.payload)),0))}},D=Xo.FtReduxStore.get({name:Lh,reducers:Ph,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],defaultLocales:void 0,searchInAllLanguagesAllowed:!1,metadataConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,session:void 0,openExternalDocumentInNewTab:!1,navigatorOnline:!0,forcedOffline:!1}})});var er,Qo=f(()=>{"use strict";Fe();er=class t{static get(e){let{baseUrl:o,apiIntegrationIdentifier:n}=D.getState(),a=e??n;if(o&&a&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,a,!0)}static await(e){return new Promise(o=>{let n=t.get(e);if(n)o(n);else{let a=D.subscribe(()=>{n=t.get(e),n&&(a(),o(n))})}})}}});var ja,et,no=f(()=>{"use strict";ja=b(N());Qo();et=class{constructor(e=!0,o){var n;this.overrideApi=o;let a=this.constructor;a.commonCache=(n=a.commonCache)!==null&&n!==void 0?n:new ja.CacheRegistry,this.cache=e?a.commonCache:new ja.CacheRegistry}get api(){var e;return(e=this.overrideApi)!==null&&e!==void 0?e:er.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):er.await()}clearCache(){this.cache.clearAll()}}});var It,Dd,Th,Jo,tr,Bd,Va=f(()=>{"use strict";Fe();It=b(N());no();Th=Symbol("clearAfterUnitTest"),Jo=class extends et{constructor(e){super(),this.messageContextProvider=e,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[Dd]=()=>{this.defaultMessages={},this.cache=new It.CacheRegistry,this.listeners={}},this.currentUiLocale=D.getState().uiLocale,D.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:e}=D.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(),Object.keys(o).length>0){let a={...(n=this.defaultMessages[e])!==null&&n!==void 0?n:{},...o};(0,It.deepEqual)(this.defaultMessages[e],a)||(this.defaultMessages[e]=a,await this.notify(e))}await 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 a;let i=e.toLowerCase(),s=this.resolveContext(i);return new It.ParametrizedLabelResolver((a=this.defaultMessages[i])!==null&&a!==void 0?a:{},s).resolve(o,...n)}async fetchContext(e){if(!this.cache.has(e))try{await this.cache.get(e,()=>this.messageContextProvider(this.currentUiLocale,e)),await this.notify(e)}catch(o){console.error(o)}}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 a;return(a=this.listeners[e])===null||a===void 0?void 0:a.delete(o)}}async notifyAll(){await Promise.all(Object.keys(this.listeners).map(e=>this.notify(e)))}async notify(e){this.listeners[e]!=null&&await Promise.all([...this.listeners[e].values()].map(o=>(0,It.delay)(0).then(()=>o()).catch(()=>null)))}};Dd=Th;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends Jo{constructor(){super(async(t,e)=>(await this.awaitApi).getFluidTopicsMessageContext(t,e))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends Jo{constructor(){super(async(t,e)=>(await this.awaitApi).getCustomMessageContext(t,e))}});tr=window.FluidTopicsI18nService,Bd=window.FluidTopicsCustomI18nService});var Md,Ie,Ve,be,ie,Ka=f(()=>{"use strict";Md=b(B()),Ie=b(X()),Ve=b(N());za();Fe();Va();Qo();be=function(t,e,o,n){var a=arguments.length,i=a<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,o,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(i=(a<3?s(i):a>3?s(e,o,i):s(e,o))||i);return a>3&&i&&Object.defineProperty(e,o,i),i},ie=class extends Ve.FtLitElement{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.editorMode=!1,this.noCustom=!1,this.openExternalDocumentInNewTab=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.navigatorOnline=!1,this.forcedOffline=!1,this.apiProvider=()=>er.get(),this.messageContexts=[],this.cache=new Ve.CacheRegistry,this.cleanSessionDebouncer=new Ve.Debouncer}render(){return Md.html`
1161
1161
  <slot></slot>
1162
- `}update(e){var o,n,a,i,s;super.update(e),e.has("baseUrl")&&(D.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),e.has("apiIntegrationIdentifier")&&D.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("uiLocale")&&D.actions.uiLocale(this.uiLocale),e.has("metadataConfiguration")&&D.actions.metadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&D.actions.noCustom(this.noCustom),e.has("editorMode")&&D.actions.editorMode(this.editorMode),e.has("noCustomComponent")&&D.actions.noCustomComponent(this.noCustomComponent),e.has("session")&&D.actions.session(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(l=>tr.addContext(l)),e.has("openExternalDocumentInNewTab")&&D.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&D.actions.navigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&D.actions.forcedOffline(this.forcedOffline),e.has("localesConfiguration")&&(D.actions.defaultLocales((o=this.localesConfiguration)===null||o===void 0?void 0:o.defaultLocales),D.actions.availableUiLocales((a=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&a!==void 0?a:[]),D.actions.searchInAllLanguagesAllowed((s=(i=this.localesConfiguration)===null||i===void 0?void 0:i.allLanguagesAllowed)!==null&&s!==void 0?s:!1)),setTimeout(()=>this.updateIfNeeded())}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.session==null&&this.updateSession(),this.metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration())}async updateSession(){this.session=await this.cache.get("session",async()=>{let 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())}};ie.elementDefinitions={};ie.styles=kd;be([(0,Ie.property)()],ie.prototype,"baseUrl",void 0);be([(0,Ie.property)()],ie.prototype,"apiIntegrationIdentifier",void 0);be([(0,Ie.property)()],ie.prototype,"uiLocale",void 0);be([(0,Ve.jsonProperty)(null)],ie.prototype,"availableUiLocales",void 0);be([(0,Ve.jsonProperty)(null)],ie.prototype,"metadataConfiguration",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"editorMode",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"noCustom",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"openExternalDocumentInNewTab",void 0);be([(0,Ie.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],ie.prototype,"noCustomComponent",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"withManualResources",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"navigatorOnline",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"forcedOffline",void 0);be([(0,Ie.property)({type:Object})],ie.prototype,"apiProvider",void 0);be([(0,Ve.jsonProperty)([])],ie.prototype,"messageContexts",void 0);be([(0,Ve.jsonProperty)(void 0)],ie.prototype,"session",void 0);be([(0,Ie.state)()],ie.prototype,"localesConfiguration",void 0)});function _h(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;var o,n,a;if(Array.isArray(t)){if(o=t.length,o!=e.length)return!1;for(n=o;n--!==0;)if(!en(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(!en(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();if(a=Object.keys(t),o=a.length,o!==Object.keys(e).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(e,a[n]))return!1;for(n=o;n--!==0;){var i=a[n];if(!en(t[i],e[i]))return!1}return!0}return t!==t&&e!==e}function en(t,e){try{return _h(t,e)}catch{return!1}}function tn(t,e){return!en(t,e)}var rn=f(()=>{"use strict"});var kh,$d=f(()=>{"use strict";rn();kh=b(X(),1)});var on,Za=f(()=>{"use strict";on=class{constructor(){this.queue=[]}add(e,o=!1){o&&(this.queue=this.queue.filter(n=>n.type!==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}}});function Fd(t,e){let o=()=>JSON.parse(JSON.stringify(t));return(0,Ud.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:tn,...e??{}})}var Ud,Wd=f(()=>{"use strict";Ud=b(X(),1);rn()});var nn,Hd=f(()=>{"use strict";nn=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 a=(e=this.rejectPromise)!==null&&e!==void 0?e:()=>null,i=(o=this.resolvePromise)!==null&&o!==void 0?o:()=>null;this.clearPromise();for(let s of n)try{await s()}catch(l){a(l);return}i(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}}});var an,Dh,_S,zd,Gd=f(()=>{an=window,Dh=an.ShadowRoot&&(an.ShadyCSS===void 0||an.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,_S=Symbol(),zd=(t,e)=>{Dh?t.adoptedStyleSheets=e.map(o=>o instanceof CSSStyleSheet?o:o.styleSheet):e.forEach(o=>{let n=document.createElement("style"),a=an.litNonce;a!==void 0&&n.setAttribute("nonce",a),n.textContent=o.cssText,t.appendChild(n)})}});var jd,sn,Vd=f(()=>{"use strict";jd=b(B(),1);Gd();sn=class extends jd.LitElement{createRenderRoot(){let e=this.constructor;e.elementDefinitions&&!e.registry&&(e.registry=new CustomElementRegistry,Object.entries(e.elementDefinitions).forEach(([a,i])=>e.registry.define(a,i)));let o={...e.shadowRootOptions,customElements:e.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return zd(n,e.elementStyles),n}}});var ao,cn,Yd,Kd,Zd,Xd,qd,Lt,Qd=f(()=>{"use strict";ao=b(X(),1);Wd();Hd();Vd();cn=function(t,e,o,n){var a=arguments.length,i=a<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,o,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(i=(a<3?s(i):a>3?s(e,o,i):s(e,o))||i);return a>3&&i&&Object.defineProperty(e,o,i),i},Kd=Symbol("constructorPrototype"),Zd=Symbol("constructorName"),Xd=Symbol("exportpartsDebouncer"),qd=Symbol("dynamicDependenciesLoaded"),Lt=class extends sn{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[Yd]=new nn(5),this[Zd]=this.constructor.name,this[Kd]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[Zd]&&Object.setPrototypeOf(this,this[Kd])}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[qd]||(e[qd]=!0,this.importDynamicDependencies())}importDynamicDependencies(){}updated(e){super.updated(e),this.updateComplete.then(()=>{this.contentAvailableCallback(e),this.applyCustomStylesheet(e),this.scheduleExportpartsUpdate()})}contentAvailableCallback(e){}applyCustomStylesheet(e){var o,n,a;if(((n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))!==null&&n!==void 0?n:[]).forEach(i=>i.remove()),this.useAdoptedStyleSheets){if(e.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((a=this.customStylesheet)!==null&&a!==void 0?a:"")}catch(i){console.error(i,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let i=document.createElement("style");i.classList.add("ft-lit-element--custom-stylesheet"),i.innerHTML=this.customStylesheet,this.shadowRoot.append(i)}}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[Xd].run(()=>{var a,i;!((a=this.exportpartsPrefix)===null||a===void 0)&&a.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((i=this.exportpartsPrefixes)===null||i===void 0?void 0:i.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})}setExportpartsAttribute(e){var o,n,a,i,s,l;let p=x=>x!=null&&x.trim().length>0,u=e.filter(p).map(x=>x.trim());if(u.length===0){this.removeAttribute("exportparts");return}let m=new Set;for(let x of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let O=(i=(a=x.getAttribute("part"))===null||a===void 0?void 0:a.split(" "))!==null&&i!==void 0?i:[],S=(l=(s=x.getAttribute("exportparts"))===null||s===void 0?void 0:s.split(",").map(C=>C.split(":")[1]))!==null&&l!==void 0?l:[];new Array(...O,...S).filter(p).map(C=>C.trim()).forEach(C=>m.add(C))}if(m.size===0){this.removeAttribute("exportparts");return}let y=[...m.values()].flatMap(x=>u.map(O=>`${x}:${O}--${x}`));this.setAttribute("exportparts",[...this.part,...y].join(", "))}};Yd=Xd;cn([(0,ao.property)()],Lt.prototype,"exportpartsPrefix",void 0);cn([Fd([])],Lt.prototype,"exportpartsPrefixes",void 0);cn([(0,ao.property)()],Lt.prototype,"customStylesheet",void 0);cn([(0,ao.state)()],Lt.prototype,"useAdoptedStyleSheets",void 0)});function io(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var ln=f(()=>{"use strict"});var Jd,eu,tu,so,Pt,rr,co,ru=f(()=>{"use strict";Qd();ln();so=Symbol("internalReduxEventsUnsubscribers"),Pt=Symbol("internalStoresUnsubscribers"),rr=Symbol("internalStores"),co=class extends Lt{constructor(){super(...arguments),this[Jd]=new Map,this[eu]=new Map,this[tu]=new Map}get reduxConstructor(){return this.constructor}update(e){super.update(e),[...this.reduxConstructor.reduxReactiveProperties].some(o=>e.has(o))&&this.updateFromStores()}getUnnamedStore(){if(this[rr].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[rr].values()][0]}getStore(e){return e==null?this.getUnnamedStore():this[rr].get(e)}addStore(e,o){var n;o=(n=o??(io(e)?e.name:void 0))!==null&&n!==void 0?n:"default-store",this.unsubscribeFromStore(o),this[rr].set(o,e),this.subscribeToStore(o,e),this.updateFromStores()}removeStore(e){let o=typeof e=="string"?e:e.name;this.unsubscribeFromStore(o),this[rr].delete(o)}setupStores(){this.unsubscribeFromStores(),this[rr].forEach((e,o)=>this.subscribeToStore(o,e)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((e,o)=>{let n=this.constructor.getPropertyOptions(o);if(!n?.attribute||!this.hasAttribute(typeof n?.attribute=="string"?n.attribute:o)){let a=this.getStore(e.store);a&&(e.store?this[Pt].has(e.store):this[Pt].size>0)&&(this[o]=e.selector(a.getState(),this))}})}subscribeToStore(e,o){var n;this[Pt].set(e,o.subscribe(()=>this.updateFromStores())),this[so].set(e,[]),io(o)&&o.eventBus&&((n=this.reduxConstructor.reduxEventListeners)===null||n===void 0||n.forEach((a,i)=>{if(typeof this[i]=="function"&&(!a.store||o.name===a.store)){let s=l=>this[i](l);o.addEventListener(a.eventName,s),this[so].get(e).push(()=>o.removeEventListener(a.eventName,s))}})),this.onStoreAvailable(e)}unsubscribeFromStores(){this[Pt].forEach((e,o)=>this.unsubscribeFromStore(o))}unsubscribeFromStore(e){var o;this[Pt].has(e)&&this[Pt].get(e)(),this[Pt].delete(e),(o=this[so].get(e))===null||o===void 0||o.forEach(n=>n()),this[so].delete(e)}onStoreAvailable(e){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}};Jd=Pt,eu=rr,tu=so;co.reduxProperties=new Map;co.reduxReactiveProperties=new Set;co.reduxEventListeners=new Map});function We(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 a,i;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 ft(t){return!!t&&!!t[te]}function Ke(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 a=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return a===Object||typeof a=="function"&&Function.toString.call(a)===zh}(t)||Array.isArray(t)||!!t[lu]||!!(!((e=t.constructor)===null||e===void 0)&&e[lu])||oi(t)||ni(t))}function or(t,e,o){o===void 0&&(o=!1),wr(t)===0?(o?Object.keys:Er)(t).forEach(function(n){o&&typeof n=="symbol"||e(n,t[n],t)}):t.forEach(function(n,a){return e(a,n,t)})}function wr(t){var e=t[te];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:oi(t)?2:ni(t)?3:0}function Cr(t,e){return wr(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function Bh(t,e){return wr(t)===2?t.get(e):t[e]}function du(t,e,o){var n=wr(t);n===2?t.set(e,o):n===3?t.add(o):t[e]=o}function uu(t,e){return t===e?t!==0||1/t==1/e:t!=t&&e!=e}function oi(t){return Wh&&t instanceof Map}function ni(t){return Hh&&t instanceof Set}function Tt(t){return t.o||t.t}function ai(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=hu(t);delete e[te];for(var o=Er(e),n=0;n<o.length;n++){var a=o[n],i=e[a];i.writable===!1&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(e[a]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[a]})}return Object.create(Object.getPrototypeOf(t),e)}function ii(t,e){return e===void 0&&(e=!1),si(t)||ft(t)||!Ke(t)||(wr(t)>1&&(t.set=t.add=t.clear=t.delete=Mh),Object.freeze(t),e&&or(t,function(o,n){return ii(n,!0)},!0)),t}function Mh(){We(2)}function si(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function tt(t){var e=ri[t];return e||We(18,t),e}function $h(t,e){ri[t]||(ri[t]=e)}function Ja(){return uo}function qa(t,e){e&&(tt("Patches"),t.u=[],t.s=[],t.v=e)}function dn(t){ei(t),t.p.forEach(Uh),t.p=null}function ei(t){t===uo&&(uo=t.l)}function ou(t){return uo={p:[],l:uo,h:t,m:!0,_:0}}function Uh(t){var e=t[te];e.i===0||e.i===1?e.j():e.g=!0}function Ya(t,e){e._=e.p.length;var o=e.p[0],n=t!==void 0&&t!==o;return e.h.O||tt("ES5").S(e,t,n),n?(o[te].P&&(dn(e),We(4)),Ke(t)&&(t=un(e,t),e.l||pn(e,t)),e.u&&tt("Patches").M(o[te].t,t,e.u,e.s)):t=un(e,o,[]),dn(e),e.u&&e.v(e.u,e.s),t!==fu?t:void 0}function un(t,e,o){if(si(e))return e;var n=e[te];if(!n)return or(e,function(l,p){return nu(t,n,e,l,p,o)},!0),e;if(n.A!==t)return e;if(!n.P)return pn(t,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var a=n.i===4||n.i===5?n.o=ai(n.k):n.o,i=a,s=!1;n.i===3&&(i=new Set(a),a.clear(),s=!0),or(i,function(l,p){return nu(t,n,a,l,p,o,s)}),pn(t,a,!1),o&&t.u&&tt("Patches").N(n,o,t.u,t.s)}return n.o}function nu(t,e,o,n,a,i,s){if(ft(a)){var l=un(t,a,i&&e&&e.i!==3&&!Cr(e.R,n)?i.concat(n):void 0);if(du(o,n,l),!ft(l))return;t.m=!1}else s&&o.add(a);if(Ke(a)&&!si(a)){if(!t.h.D&&t._<1)return;un(t,a),e&&e.A.l||pn(t,a)}}function pn(t,e,o){o===void 0&&(o=!1),!t.l&&t.h.D&&t.m&&ii(e,o)}function Xa(t,e){var o=t[te];return(o?Tt(o):t)[e]}function au(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 _t(t){t.P||(t.P=!0,t.l&&_t(t.l))}function Qa(t){t.o||(t.o=ai(t.t))}function ti(t,e,o){var n=oi(e)?tt("MapSet").F(e,o):ni(e)?tt("MapSet").T(e,o):t.O?function(a,i){var s=Array.isArray(a),l={i:s?1:0,A:i?i.A:Ja(),P:!1,I:!1,R:{},l:i,t:a,k:null,o:null,j:null,C:!1},p=l,u=po;s&&(p=[l],u=lo);var m=Proxy.revocable(p,u),y=m.revoke,x=m.proxy;return l.k=x,l.j=y,x}(e,o):tt("ES5").J(e,o);return(o?o.A:Ja()).p.push(n),n}function Fh(t){return ft(t)||We(22,t),function e(o){if(!Ke(o))return o;var n,a=o[te],i=wr(o);if(a){if(!a.P&&(a.i<4||!tt("ES5").K(a)))return a.t;a.I=!0,n=iu(o,i),a.I=!1}else n=iu(o,i);return or(n,function(s,l){a&&Bh(a.t,s)===l||du(n,s,e(l))}),i===3?new Set(n):n}(t)}function iu(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return ai(t)}function pu(){function t(s,l){var p=i[s];return p?p.enumerable=l:i[s]=p={configurable:!0,enumerable:l,get:function(){var u=this[te];return po.get(u,s)},set:function(u){var m=this[te];po.set(m,s,u)}},p}function e(s){for(var l=s.length-1;l>=0;l--){var p=s[l][te];if(!p.P)switch(p.i){case 5:n(p)&&_t(p);break;case 4:o(p)&&_t(p)}}}function o(s){for(var l=s.t,p=s.k,u=Er(p),m=u.length-1;m>=0;m--){var y=u[m];if(y!==te){var x=l[y];if(x===void 0&&!Cr(l,y))return!0;var O=p[y],S=O&&O[te];if(S?S.t!==x:!uu(O,x))return!0}}var C=!!l[te];return u.length!==Er(l).length+(C?0:1)}function n(s){var l=s.k;if(l.length!==s.t.length)return!0;var p=Object.getOwnPropertyDescriptor(l,l.length-1);if(p&&!p.get)return!0;for(var u=0;u<l.length;u++)if(!l.hasOwnProperty(u))return!0;return!1}function a(s){s.g&&We(3,JSON.stringify(Tt(s)))}var i={};$h("ES5",{J:function(s,l){var p=Array.isArray(s),u=function(y,x){if(y){for(var O=Array(x.length),S=0;S<x.length;S++)Object.defineProperty(O,""+S,t(S,!0));return O}var C=hu(x);delete C[te];for(var P=Er(C),I=0;I<P.length;I++){var L=P[I];C[L]=t(L,y||!!C[L].enumerable)}return Object.create(Object.getPrototypeOf(x),C)}(p,s),m={i:p?5:4,A:l?l.A:Ja(),P:!1,I:!1,R:{},l,t:s,k:u,o:null,g:!1,C:!1};return Object.defineProperty(u,te,{value:m,writable:!0}),u},S:function(s,l,p){p?ft(l)&&l[te].A===s&&e(s.p):(s.u&&function u(m){if(m&&typeof m=="object"){var y=m[te];if(y){var x=y.t,O=y.k,S=y.R,C=y.i;if(C===4)or(O,function(U){U!==te&&(x[U]!==void 0||Cr(x,U)?S[U]||u(O[U]):(S[U]=!0,_t(y)))}),or(x,function(U){O[U]!==void 0||Cr(O,U)||(S[U]=!1,_t(y))});else if(C===5){if(n(y)&&(_t(y),S.length=!0),O.length<x.length)for(var P=O.length;P<x.length;P++)S[P]=!1;else for(var I=x.length;I<O.length;I++)S[I]=!0;for(var L=Math.min(O.length,x.length),M=0;M<L;M++)O.hasOwnProperty(M)||(S[M]=!0),S[M]===void 0&&u(O[M])}}}}(s.p[0]),e(s.p))},K:function(s){return s.i===4?o(s):n(s)}})}var su,uo,ci,Wh,Hh,cu,fu,lu,te,zh,Er,hu,ri,po,lo,Gh,ke,jh,jS,VS,KS,ZS,qS,YS,fn,hn=f(()=>{ci=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",Wh=typeof Map<"u",Hh=typeof Set<"u",cu=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",fu=ci?Symbol.for("immer-nothing"):((su={})["immer-nothing"]=!0,su),lu=ci?Symbol.for("immer-draftable"):"__$immer_draftable",te=ci?Symbol.for("immer-state"):"__$immer_state",zh=""+Object.prototype.constructor,Er=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,hu=Object.getOwnPropertyDescriptors||function(t){var e={};return Er(t).forEach(function(o){e[o]=Object.getOwnPropertyDescriptor(t,o)}),e},ri={},po={get:function(t,e){if(e===te)return t;var o=Tt(t);if(!Cr(o,e))return function(a,i,s){var l,p=au(i,s);return p?"value"in p?p.value:(l=p.get)===null||l===void 0?void 0:l.call(a.k):void 0}(t,o,e);var n=o[e];return t.I||!Ke(n)?n:n===Xa(t.t,e)?(Qa(t),t.o[e]=ti(t.A.h,n,t)):n},has:function(t,e){return e in Tt(t)},ownKeys:function(t){return Reflect.ownKeys(Tt(t))},set:function(t,e,o){var n=au(Tt(t),e);if(n?.set)return n.set.call(t.k,o),!0;if(!t.P){var a=Xa(Tt(t),e),i=a?.[te];if(i&&i.t===o)return t.o[e]=o,t.R[e]=!1,!0;if(uu(o,a)&&(o!==void 0||Cr(t.t,e)))return!0;Qa(t),_t(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 Xa(t.t,e)!==void 0||e in t.t?(t.R[e]=!1,Qa(t),_t(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var o=Tt(t),n=Reflect.getOwnPropertyDescriptor(o,e);return n&&{writable:!0,configurable:t.i!==1||e!=="length",enumerable:n.enumerable,value:o[e]}},defineProperty:function(){We(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){We(12)}},lo={};or(po,function(t,e){lo[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}}),lo.deleteProperty=function(t,e){return lo.set.call(this,t,e,void 0)},lo.set=function(t,e,o){return po.set.call(this,t[0],e,o,t[0])};Gh=function(){function t(o){var n=this;this.O=cu,this.D=!0,this.produce=function(a,i,s){if(typeof a=="function"&&typeof i!="function"){var l=i;i=a;var p=n;return function(C){var P=this;C===void 0&&(C=l);for(var I=arguments.length,L=Array(I>1?I-1:0),M=1;M<I;M++)L[M-1]=arguments[M];return p.produce(C,function(U){var F;return(F=i).call.apply(F,[P,U].concat(L))})}}var u;if(typeof i!="function"&&We(6),s!==void 0&&typeof s!="function"&&We(7),Ke(a)){var m=ou(n),y=ti(n,a,void 0),x=!0;try{u=i(y),x=!1}finally{x?dn(m):ei(m)}return typeof Promise<"u"&&u instanceof Promise?u.then(function(C){return qa(m,s),Ya(C,m)},function(C){throw dn(m),C}):(qa(m,s),Ya(u,m))}if(!a||typeof a!="object"){if((u=i(a))===void 0&&(u=a),u===fu&&(u=void 0),n.D&&ii(u,!0),s){var O=[],S=[];tt("Patches").M(a,u,O,S),s(O,S)}return u}We(21,a)},this.produceWithPatches=function(a,i){if(typeof a=="function")return function(u){for(var m=arguments.length,y=Array(m>1?m-1:0),x=1;x<m;x++)y[x-1]=arguments[x];return n.produceWithPatches(u,function(O){return a.apply(void 0,[O].concat(y))})};var s,l,p=n.produce(a,i,function(u,m){s=u,l=m});return typeof Promise<"u"&&p instanceof Promise?p.then(function(u){return[u,s,l]}):[p,s,l]},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){Ke(o)||We(8),ft(o)&&(o=Fh(o));var n=ou(this),a=ti(this,o,void 0);return a[te].C=!0,ei(n),a},e.finishDraft=function(o,n){var a=o&&o[te],i=a.A;return qa(i,n),Ya(void 0,i)},e.setAutoFreeze=function(o){this.D=o},e.setUseProxies=function(o){o&&!cu&&We(20),this.O=o},e.applyPatches=function(o,n){var a;for(a=n.length-1;a>=0;a--){var i=n[a];if(i.path.length===0&&i.op==="replace"){o=i.value;break}}a>-1&&(n=n.slice(a+1));var s=tt("Patches").$;return ft(o)?s(o,n):this.produce(o,function(l){return s(l,n)})},t}(),ke=new Gh,jh=ke.produce,jS=ke.produceWithPatches.bind(ke),VS=ke.setAutoFreeze.bind(ke),KS=ke.setUseProxies.bind(ke),ZS=ke.applyPatches.bind(ke),qS=ke.createDraft.bind(ke),YS=ke.finishDraft.bind(ke),fn=jh});function kt(t){"@babel/helpers - typeof";return kt=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},kt(t)}var li=f(()=>{});function di(t,e){if(kt(t)!=="object"||t===null)return t;var o=t[Symbol.toPrimitive];if(o!==void 0){var n=o.call(t,e||"default");if(kt(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var yu=f(()=>{li()});function ui(t){var e=di(t,"string");return kt(e)==="symbol"?e:String(e)}var mu=f(()=>{li();yu()});function pi(t,e,o){return e=ui(e),e in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}var gu=f(()=>{mu()});function bu(t,e){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(t,a).enumerable})),o.push.apply(o,n)}return o}function yn(t){for(var e=1;e<arguments.length;e++){var o=arguments[e]!=null?arguments[e]:{};e%2?bu(Object(o),!0).forEach(function(n){pi(t,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):bu(Object(o)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(o,n))})}return t}var xu=f(()=>{gu()});function xe(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. "}function Vh(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 hi(t,e,o){var n;if(typeof e=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(xe(0));if(typeof e=="function"&&typeof o>"u"&&(o=e,e=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(xe(1));return o(hi)(t,e)}if(typeof t!="function")throw new Error(xe(2));var a=t,i=e,s=[],l=s,p=!1;function u(){l===s&&(l=s.slice())}function m(){if(p)throw new Error(xe(3));return i}function y(C){if(typeof C!="function")throw new Error(xe(4));if(p)throw new Error(xe(5));var P=!0;return u(),l.push(C),function(){if(P){if(p)throw new Error(xe(6));P=!1,u();var L=l.indexOf(C);l.splice(L,1),s=null}}}function x(C){if(!Vh(C))throw new Error(xe(7));if(typeof C.type>"u")throw new Error(xe(8));if(p)throw new Error(xe(9));try{p=!0,i=a(i,C)}finally{p=!1}for(var P=s=l,I=0;I<P.length;I++){var L=P[I];L()}return C}function O(C){if(typeof C!="function")throw new Error(xe(10));a=C,x({type:mn.REPLACE})}function S(){var C,P=y;return C={subscribe:function(L){if(typeof L!="object"||L===null)throw new Error(xe(11));function M(){L.next&&L.next(m())}M();var U=P(M);return{unsubscribe:U}}},C[vu]=function(){return this},C}return x({type:mn.INIT}),n={dispatch:x,subscribe:y,getState:m,replaceReducer:O},n[vu]=S,n}function Kh(t){Object.keys(t).forEach(function(e){var o=t[e],n=o(void 0,{type:mn.INIT});if(typeof n>"u")throw new Error(xe(12));if(typeof o(void 0,{type:mn.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(xe(13))})}function Su(t){for(var e=Object.keys(t),o={},n=0;n<e.length;n++){var a=e[n];typeof t[a]=="function"&&(o[a]=t[a])}var i=Object.keys(o),s,l;try{Kh(o)}catch(p){l=p}return function(u,m){if(u===void 0&&(u={}),l)throw l;if(0)var y;for(var x=!1,O={},S=0;S<i.length;S++){var C=i[S],P=o[C],I=u[C],L=P(I,m);if(typeof L>"u"){var M=m&&m.type;throw new Error(xe(14))}O[C]=L,x=x||L!==I}return x=x||i.length!==Object.keys(u).length,x?O:u}}function Ar(){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,a){return function(){return n(a.apply(void 0,arguments))}})}function Ou(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return function(n){return function(){var a=n.apply(void 0,arguments),i=function(){throw new Error(xe(15))},s={getState:a.getState,dispatch:function(){return i.apply(void 0,arguments)}},l=e.map(function(p){return p(s)});return i=Ar.apply(void 0,l)(a.dispatch),yn(yn({},a),{},{dispatch:i})}}}var vu,fi,mn,gn=f(()=>{xu();vu=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),fi=function(){return Math.random().toString(36).substring(7).split("").join(".")},mn={INIT:"@@redux/INIT"+fi(),REPLACE:"@@redux/REPLACE"+fi(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+fi()}}});function Cu(t){var e=function(n){var a=n.dispatch,i=n.getState;return function(s){return function(l){return typeof l=="function"?l(a,i,t):s(l)}}};return e}var Eu,yi,wu=f(()=>{Eu=Cu();Eu.withExtraArgument=Cu;yi=Eu});function ry(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}function xi(t){return Ke(t)?fn(t,function(){}):t}function ay(t){return typeof t=="boolean"}function iy(){return function(e){return sy(e)}}function sy(t){t===void 0&&(t={});var e=t.thunk,o=e===void 0?!0:e,n=t.immutableCheck,a=n===void 0?!0:n,i=t.serializableCheck,s=i===void 0?!0:i,l=new oy;if(o&&(ay(o)?l.push(yi):l.push(yi.withExtraArgument(o.extraArgument))),0){if(a)var p;if(s)var u}return l}function Pu(t){var e=iy(),o=t||{},n=o.reducer,a=n===void 0?void 0:n,i=o.middleware,s=i===void 0?e():i,l=o.devTools,p=l===void 0?!0:l,u=o.preloadedState,m=u===void 0?void 0:u,y=o.enhancers,x=y===void 0?void 0:y,O;if(typeof a=="function")O=a;else if(ry(a))O=Su(a);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),!gi&&!Array.isArray(S)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!gi&&S.some(function(U){return typeof U!="function"}))throw new Error("each middleware provided to configureStore must be a function");var C=Ou.apply(void 0,S),P=Ar;p&&(P=ty(Dt({trace:!gi},typeof p=="object"&&p)));var I=new ny(C),L=I;Array.isArray(x)?L=Rr([C],x):typeof x=="function"&&(L=x(I));var M=P.apply(void 0,L);return hi(O,m,M)}function Bt(t,e){function o(){for(var n=[],a=0;a<arguments.length;a++)n[a]=arguments[a];if(e){var i=e.apply(void 0,n);if(!i)throw new Error("prepareAction did not return an object");return Dt(Dt({type:t,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.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 Tu(t){var e={},o=[],n,a={addCase:function(i,s){var l=typeof i=="string"?i:i.type;if(l in e)throw new Error("addCase cannot be called with two reducers for the same action type");return e[l]=s,a},addMatcher:function(i,s){return o.push({matcher:i,reducer:s}),a},addDefaultCase:function(i){return n=i,a}};return t(a),[e,o,n]}function cy(t){return typeof t=="function"}function ly(t,e,o,n){o===void 0&&(o=[]);var a=typeof e=="function"?Tu(e):[e,o,n],i=a[0],s=a[1],l=a[2],p;if(cy(t))p=function(){return xi(t())};else{var u=xi(t);p=function(){return u}}function m(y,x){y===void 0&&(y=p());var O=Rr([i[x.type]],s.filter(function(S){var C=S.matcher;return C(x)}).map(function(S){var C=S.reducer;return C}));return O.filter(function(S){return!!S}).length===0&&(O=[l]),O.reduce(function(S,C){if(C)if(ft(S)){var P=S,I=C(P,x);return I===void 0?S:I}else{if(Ke(S))return fn(S,function(L){return C(L,x)});var I=C(S,x);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 dy(t,e){return t+"/"+e}function _u(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:xi(t.initialState),n=t.reducers||{},a=Object.keys(n),i={},s={},l={};a.forEach(function(m){var y=n[m],x=dy(e,m),O,S;"reducer"in y?(O=y.reducer,S=y.prepare):O=y,i[m]=O,s[x]=O,l[m]=S?Bt(x,S):Bt(x)});function p(){var m=typeof t.extraReducers=="function"?Tu(t.extraReducers):[t.extraReducers],y=m[0],x=y===void 0?{}:y,O=m[1],S=O===void 0?[]:O,C=m[2],P=C===void 0?void 0:C,I=Dt(Dt({},x),s);return ly(o,function(L){for(var M in I)L.addCase(M,I[M]);for(var U=0,F=S;U<F.length;U++){var Ee=F[U];L.addMatcher(Ee.matcher,Ee.reducer)}P&&L.addDefaultCase(P)})}var u;return{name:e,reducer:function(m,y){return u||(u=p()),u(m,y)},actions:l,caseReducers:i,getInitialState:function(){return u||(u=p()),u.getInitialState()}}}function yy(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function my(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var Lu,Zh,Rr,qh,Yh,Xh,Au,Qh,Jh,Ru,Dt,mi,ey,ty,hO,oy,ny,gi,uy,py,fy,bi,Nu,hy,bO,ku,Du,Bu,xO,vO,SO,OO,vi,CO,EO,wO,Iu,AO,gy,RO,Mu=f(()=>{hn();gn();gn();gn();wu();hn();hn();Lu=function(){var t=function(e,o){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,a){n.__proto__=a}||function(n,a){for(var i in a)Object.prototype.hasOwnProperty.call(a,i)&&(n[i]=a[i])},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)}}(),Zh=function(t,e){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,a,i,s;return s={next:l(0),throw:l(1),return:l(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(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,a&&(i=u[0]&2?a.return:u[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,u[1])).done)return i;switch(a=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,a=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=e.call(t,o)}catch(m){u=[6,m],a=0}finally{n=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Rr=function(t,e){for(var o=0,n=e.length,a=t.length;o<n;o++,a++)t[a]=e[o];return t},qh=Object.defineProperty,Yh=Object.defineProperties,Xh=Object.getOwnPropertyDescriptors,Au=Object.getOwnPropertySymbols,Qh=Object.prototype.hasOwnProperty,Jh=Object.prototype.propertyIsEnumerable,Ru=function(t,e,o){return e in t?qh(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o},Dt=function(t,e){for(var o in e||(e={}))Qh.call(e,o)&&Ru(t,o,e[o]);if(Au)for(var n=0,a=Au(e);n<a.length;n++){var o=a[n];Jh.call(e,o)&&Ru(t,o,e[o])}return t},mi=function(t,e){return Yh(t,Xh(e))},ey=function(t,e,o){return new Promise(function(n,a){var i=function(p){try{l(o.next(p))}catch(u){a(u)}},s=function(p){try{l(o.throw(p))}catch(u){a(u)}},l=function(p){return p.done?n(p.value):Promise.resolve(p.value).then(i,s)};l((o=o.apply(t,e)).next())})},ty=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Ar:Ar.apply(null,arguments)},hO=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}};oy=function(t){Lu(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=t.apply(this,o)||this;return Object.setPrototypeOf(a,e.prototype),a}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,Rr([void 0],o[0].concat(this)))):new(e.bind.apply(e,Rr([void 0],o.concat(this))))},e}(Array),ny=function(t){Lu(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=t.apply(this,o)||this;return Object.setPrototypeOf(a,e.prototype),a}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,Rr([void 0],o[0].concat(this)))):new(e.bind.apply(e,Rr([void 0],o.concat(this))))},e}(Array);gi=!0;uy="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",py=function(t){t===void 0&&(t=21);for(var e="",o=t;o--;)e+=uy[Math.random()*64|0];return e},fy=["name","message","stack","code"],bi=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),Nu=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),hy=function(t){if(typeof t=="object"&&t!==null){for(var e={},o=0,n=fy;o<n.length;o++){var a=n[o];typeof t[a]=="string"&&(e[a]=t[a])}return e}return{message:String(t)}},bO=function(){function t(e,o,n){var a=Bt(e+"/fulfilled",function(m,y,x,O){return{payload:m,meta:mi(Dt({},O||{}),{arg:x,requestId:y,requestStatus:"fulfilled"})}}),i=Bt(e+"/pending",function(m,y,x){return{payload:void 0,meta:mi(Dt({},x||{}),{arg:y,requestId:m,requestStatus:"pending"})}}),s=Bt(e+"/rejected",function(m,y,x,O,S){return{payload:O,error:(n&&n.serializeError||hy)(m||"Rejected"),meta:mi(Dt({},S||{}),{arg:x,requestId:y,rejectedWithValue:!!O,requestStatus:"rejected",aborted:m?.name==="AbortError",condition:m?.name==="ConditionError"})}}),l=!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,x,O){var S=n?.idGenerator?n.idGenerator(m):py(),C=new p,P,I=!1;function L(U){P=U,C.abort()}var M=function(){return ey(this,null,function(){var U,F,Ee,qe,Oe,Ye,fe;return Zh(this,function(g){switch(g.label){case 0:return g.trys.push([0,4,,5]),qe=(U=n?.condition)==null?void 0:U.call(n,m,{getState:x,extra:O}),my(qe)?[4,qe]:[3,2];case 1:qe=g.sent(),g.label=2;case 2:if(qe===!1||C.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return I=!0,Oe=new Promise(function(v,k){return C.signal.addEventListener("abort",function(){return k({name:"AbortError",message:P||"Aborted"})})}),y(i(S,m,(F=n?.getPendingMeta)==null?void 0:F.call(n,{requestId:S,arg:m},{getState:x,extra:O}))),[4,Promise.race([Oe,Promise.resolve(o(m,{dispatch:y,getState:x,extra:O,requestId:S,signal:C.signal,abort:L,rejectWithValue:function(v,k){return new bi(v,k)},fulfillWithValue:function(v,k){return new Nu(v,k)}})).then(function(v){if(v instanceof bi)throw v;return v instanceof Nu?a(v.payload,S,m,v.meta):a(v,S,m)})])];case 3:return Ee=g.sent(),[3,5];case 4:return Ye=g.sent(),Ee=Ye instanceof bi?s(null,S,m,Ye.payload,Ye.meta):s(Ye,S,m),[3,5];case 5:return fe=n&&!n.dispatchConditionRejection&&s.match(Ee)&&Ee.meta.condition,fe||y(Ee),[2,Ee]}})})}();return Object.assign(M,{abort:L,requestId:S,arg:m,unwrap:function(){return M.then(yy)}})}}return Object.assign(u,{pending:i,rejected:s,fulfilled:a,typePrefix:e})}return t.withTypes=function(){return t},t}();ku="listener",Du="completed",Bu="cancelled",xO="task-"+Bu,vO="task-"+Du,SO=ku+"-"+Bu,OO=ku+"-"+Du,vi="listenerMiddleware",CO=Bt(vi+"/add"),EO=Bt(vi+"/removeAll"),wO=Bt(vi+"/remove"),AO=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(t){return(Iu||(Iu=Promise.resolve())).then(t).catch(function(e){return setTimeout(function(){throw e},0)})},gy=function(t){return function(e){setTimeout(e,t)}},RO=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:gy(10);pu()});function by(t,e){return class extends t{constructor(){super(...arguments),this.eventBus=e??document.createElement("span")}addEventListener(o,n,a){this.eventBus.addEventListener(o,n,a)}dispatchEvent(o){return this.eventBus.dispatchEvent(o)}removeEventListener(o,n,a){this.eventBus.removeEventListener(o,n,a)}}}var bn,$u=f(()=>{"use strict";bn=class extends by(Object){}});var Uu,Fu=f(()=>{"use strict";Mu();ln();Za();$u();window.ftReduxStores||(window.ftReduxStores={});Uu=class t extends bn{static get(e){var o;let n=typeof e=="string"?e:e.name,a=typeof e=="string"?void 0:e,i=window.ftReduxStores[n];if(io(i))return i;if(a==null)return;let s=_u({...a,reducers:(o=a.reducers)!==null&&o!==void 0?o:{}}),l=Pu({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[a.name]=new t(s,l)}constructor(e,o){super(),this.reduxSlice=e,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new on;let n=a=>a!=null?JSON.parse(JSON.stringify(a)):a;this.actions=new Proxy(this.reduxSlice.actions,{get:(a,i,s)=>{let l=i,p=a[l];return p?(...u)=>{let m=p(...u.map(n));return this.reduxStore.dispatch(m),m}:u=>{this.setState({[l]:n(u)})}}})}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 Wu=f(()=>{"use strict";rn()});var Hu=f(()=>{"use strict";$d();Za();ru();Fu();ln();Wu()});var zu=f(()=>{"use strict"});var xy,Gu=f(()=>{"use strict";xy=b(X());Hu();zu();Fe()});var xn,Si=f(()=>{"use strict";Fe();no();xn=class extends et{async listMySearches(){let e=D.getState().session;return e?.sessionAuthenticated?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),5*60*1e3):[]}}});var vn,Oi=f(()=>{"use strict";Fe();no();vn=class extends et{async listMyBookmarks(){let e=D.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),5*60*1e3):[]}}});var On,vy,Sn,Ci,ju,Ei=f(()=>{"use strict";On=b(N());Si();Oi();Fe();vy="ft-user-assets",Sn=On.FtReduxStore.get({name:vy,initialState:{savedSearches:void 0,bookmarks:void 0}}),Ci=class{constructor(){this.currentSession=D.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new vn,this.savedSearchesService=new xn,D.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:o}=D.getState();(0,On.deepEqual)((e=this.currentSession)===null||e===void 0?void 0:e.profile,o?.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),Sn.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),Sn.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();Sn.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}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;Sn.actions.bookmarks(o)}}},ju=new Ci});var wi,Vu=f(()=>{"use strict";Fe();wi=class{addCommand(e,o=!1){D.commands.add(e,o)}consumeCommand(e){return D.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new wi});var Ku,Ai,Zu=f(()=>{"use strict";Ku=b(N()),Ai=class{highlightHtml(e,o,n){(0,Ku.highlightHtml)(e,o,n)}};window.FluidTopicsHighlightHtmlService=new Ai});var qu,Ri,Yu=f(()=>{"use strict";qu=b(N());Fe();Ri=class{isDate(e){var o,n,a,i;return(i=(a=((n=(o=D.getState().metadataConfiguration)===null||o===void 0?void 0:o.descriptors)!==null&&n!==void 0?n:[]).find(l=>l.key===e))===null||a===void 0?void 0:a.date)!==null&&i!==void 0?i:!1}format(e,o){var n,a,i;return qu.DateFormatter.format(e,(n=o?.locale)!==null&&n!==void 0?n:D.getState().uiLocale,(a=o?.longFormat)!==null&&a!==void 0?a:!1,(i=o?.withTime)!==null&&i!==void 0?i:!1)}};window.FluidTopicsDateService=new Ri});var Xu,Nr,Qu=f(()=>{"use strict";Xu=b(N());Fe();Nr=class{static get(e,o){var n,a,i,s;let l=D.getState(),{lang:p,region:u}=(a=(n=l.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&a!==void 0?a:{lang:"en",region:"US"};return new Xu.SearchPlaceConverter(l.baseUrl,(s=(i=window.FluidTopicsClientConfiguration)===null||i===void 0?void 0:i.predefinedSorts)!==null&&s!==void 0?s:{},e??20,l.searchInAllLanguagesAllowed,o??`${p}-${u}`)}}});var Ju=f(()=>{"use strict";Oi();Qo();Vu();Va();no();Zu();Si();Yu();Qu()});var ep=f(()=>{"use strict"});var tp,Mt=f(()=>{"use strict";tp=b(N());Ka();Gu();Fe();Ei();Ju();za();ep();Ka();(0,tp.customElement)("ft-app-context")(ie)});function He(t){var e,o;class n extends t{constructor(){super(...arguments),this.useCustomMessageContexts=!1,this[e]=new Map,this[o]=new Map}get i18nService(){return this.useCustomMessageContexts?Bd:tr}i18n(i,s,...l){var p;if(typeof i=="string")return this.i18nService.resolveMessage(i,s,...l);let u=(p=i.args)!==null&&p!==void 0?p:i.argsProvider?i.argsProvider(this):[];return this.i18nService.resolveMessage(i.context,i.key,...u)}onI18nUpdate(i){var s,l,p;(s=this[Ni])===null||s===void 0||s.forEach((u,m)=>{let y=this.getI18nAttributeValue(m);y&&(this[m]=this.getI18nAttributeMessage(y,u,i))}),(l=this[Ii])===null||l===void 0||l.forEach((u,m)=>{let y=this.getI18nListAttributeValues(m);this[m]=y?.map(x=>this.getI18nAttributeMessage(x,u,i))}),(p=this[Cn])===null||p===void 0||p.forEach((u,m)=>{u.context.toLowerCase()===i.toLowerCase()&&(this[m]=this.i18n(u))}),setTimeout(()=>this.requestUpdate(),0)}buildI18nAttributeMessage(i,s){return{...i,message:this.i18n({context:i.context,key:i.key,...s})}}getI18nAttributeMessage(i,s,l){var p;let u=!l||((p=i.context)===null||p===void 0?void 0:p.toLowerCase())===l.toLowerCase();return i.context&&i.key&&u?this.buildI18nAttributeMessage(i,s):i}update(i){var s,l,p;super.update(i),(s=this[Ni])===null||s===void 0||s.forEach((u,m)=>{let y=this.getI18nAttributeValue(m);y?.context&&y.key&&(i.has(m)||u.argsProvider!=null)&&(this.addI18nContextIfNeeded(y,i,m),this[m]=this.getI18nAttributeMessage(y,u))}),(l=this[Ii])===null||l===void 0||l.forEach((u,m)=>{let y=this.getI18nListAttributeValues(m);(i.has(m)||u.argsProvider!=null)&&(this[m]=y?.map(x=>(this.addI18nContextIfNeeded(x,i,m),this.getI18nAttributeMessage(x,u))))}),(p=this[Cn])===null||p===void 0||p.forEach((u,m)=>{u.argsProvider!=null&&(this[m]=this.i18n(u))})}getI18nAttributeValue(i){return this[i]}getI18nListAttributeValues(i){return this[i]}addI18nContextIfNeeded(i,s,l){i.context&&i.key&&s.has(l)&&this.addI18nContext(i.context)}addI18nMessagesAndSubscribe(i,s){i=i.toLowerCase(),this[fo].has(i)||this[fo].set(i,this.i18nService.subscribe(i,()=>this.onI18nUpdate(i))),this.i18nService.prepareContext(i,s??{}),this.onI18nUpdate(i)}connectedCallback(){var i,s,l,p,u,m;super.connectedCallback(),new Set([...(s=(i=this[Cn])===null||i===void 0?void 0:i.values())!==null&&s!==void 0?s:[],...[...(p=(l=this[Ni])===null||l===void 0?void 0:l.keys())!==null&&p!==void 0?p:[]].map(y=>this.getI18nAttributeValue(y)),...[...(m=(u=this[Ii])===null||u===void 0?void 0:u.keys())!==null&&m!==void 0?m:[]].flatMap(y=>this.getI18nListAttributeValues(y))].map(y=>y?.context)).forEach(y=>y&&this.addI18nMessages(y)),this[Li].forEach((y,x)=>{this.addI18nMessages(x,y)})}addI18nMessages(i,s){this[Li].set(i,s??{}),this.addI18nMessagesAndSubscribe(i,s)}addI18nContext(i,s){this.addI18nMessages(typeof i=="string"?i:i.name,s)}disconnectedCallback(){super.disconnectedCallback(),this[fo].forEach(i=>i()),this[fo].clear()}}return e=Li,o=fo,Sy([(0,op.property)({type:Boolean})],n.prototype,"useCustomMessageContexts",void 0),n}var wn,op,Sy,Ni,Ii,Cn,Li,fo,rp,En,An=f(()=>{"use strict";wn=b(N());Mt();op=b(X()),Sy=function(t,e,o,n){var a=arguments.length,i=a<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,o,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(i=(a<3?s(i):a>3?s(e,o,i):s(e,o))||i);return a>3&&i&&Object.defineProperty(e,o,i),i},Ni=Symbol("i18nAttributes"),Ii=Symbol("i18nListAttributes"),Cn=Symbol("i18nProperties"),Li=Symbol("i18nManualContexts"),fo=Symbol("i18nUnsubs");rp=class extends He(wn.FtLitElement){},En=class extends He(wn.FtLitElementRedux){}});var Rn,Nn,In,ho,Ze,Pi=f(()=>{"use strict";Rn=b(B()),Nn=b(X()),In=b(N());Ha();An();Mt();ho=function(t,e,o,n){var a=arguments.length,i=a<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,o,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(i=(a<3?s(i):a>3?s(e,o,i):s(e,o))||i);return a>3&&i&&Object.defineProperty(e,o,i),i},Ze=class extends En{constructor(){super(),this.editorMode=!1,this.addStore(D)}render(){return!this.key||!this.context?this.editorMode?"Select a context and a label key.":Rn.nothing:Rn.html`
1162
+ `}update(e){var o,n,a,i,s;super.update(e),e.has("baseUrl")&&(D.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),e.has("apiIntegrationIdentifier")&&D.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("uiLocale")&&D.actions.uiLocale(this.uiLocale),e.has("metadataConfiguration")&&D.actions.metadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&D.actions.noCustom(this.noCustom),e.has("editorMode")&&D.actions.editorMode(this.editorMode),e.has("noCustomComponent")&&D.actions.noCustomComponent(this.noCustomComponent),e.has("session")&&D.actions.session(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(l=>tr.addContext(l)),e.has("openExternalDocumentInNewTab")&&D.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&D.actions.navigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&D.actions.forcedOffline(this.forcedOffline),e.has("localesConfiguration")&&(D.actions.defaultLocales((o=this.localesConfiguration)===null||o===void 0?void 0:o.defaultLocales),D.actions.availableUiLocales((a=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&a!==void 0?a:[]),D.actions.searchInAllLanguagesAllowed((s=(i=this.localesConfiguration)===null||i===void 0?void 0:i.allLanguagesAllowed)!==null&&s!==void 0?s:!1)),setTimeout(()=>this.updateIfNeeded())}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.session==null&&this.updateSession(),this.metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration())}async updateSession(){this.session=await this.cache.get("session",async()=>{let 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())}};ie.elementDefinitions={};ie.styles=kd;be([(0,Ie.property)()],ie.prototype,"baseUrl",void 0);be([(0,Ie.property)()],ie.prototype,"apiIntegrationIdentifier",void 0);be([(0,Ie.property)()],ie.prototype,"uiLocale",void 0);be([(0,Ve.jsonProperty)(null)],ie.prototype,"availableUiLocales",void 0);be([(0,Ve.jsonProperty)(null)],ie.prototype,"metadataConfiguration",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"editorMode",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"noCustom",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"openExternalDocumentInNewTab",void 0);be([(0,Ie.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],ie.prototype,"noCustomComponent",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"withManualResources",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"navigatorOnline",void 0);be([(0,Ie.property)({type:Boolean})],ie.prototype,"forcedOffline",void 0);be([(0,Ie.property)({type:Object})],ie.prototype,"apiProvider",void 0);be([(0,Ve.jsonProperty)([])],ie.prototype,"messageContexts",void 0);be([(0,Ve.jsonProperty)(void 0)],ie.prototype,"session",void 0);be([(0,Ie.state)()],ie.prototype,"localesConfiguration",void 0)});function _h(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;var o,n,a;if(Array.isArray(t)){if(o=t.length,o!=e.length)return!1;for(n=o;n--!==0;)if(!en(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(!en(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 i=s=>Object.keys(s).filter(l=>s[l]!=null);if(a=i(t),o=a.length,o!==i(e).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(e,a[n]))return!1;for(n=o;n--!==0;){let s=a[n];if(!en(t[s],e[s]))return!1}return!0}return t!==t&&e!==e||t==null&&e==null}function en(t,e){try{return _h(t,e)}catch{return!1}}function tn(t,e){return!en(t,e)}var rn=f(()=>{"use strict"});var kh,$d=f(()=>{"use strict";rn();kh=b(X(),1)});var on,Za=f(()=>{"use strict";on=class{constructor(){this.queue=[]}add(e,o=!1){o&&(this.queue=this.queue.filter(n=>n.type!==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}}});function Fd(t,e){let o=()=>JSON.parse(JSON.stringify(t));return(0,Ud.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:tn,...e??{}})}var Ud,Wd=f(()=>{"use strict";Ud=b(X(),1);rn()});var nn,Hd=f(()=>{"use strict";nn=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 a=(e=this.rejectPromise)!==null&&e!==void 0?e:()=>null,i=(o=this.resolvePromise)!==null&&o!==void 0?o:()=>null;this.clearPromise();for(let s of n)try{await s()}catch(l){a(l);return}i(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}}});var an,Dh,_S,zd,Gd=f(()=>{an=window,Dh=an.ShadowRoot&&(an.ShadyCSS===void 0||an.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,_S=Symbol(),zd=(t,e)=>{Dh?t.adoptedStyleSheets=e.map(o=>o instanceof CSSStyleSheet?o:o.styleSheet):e.forEach(o=>{let n=document.createElement("style"),a=an.litNonce;a!==void 0&&n.setAttribute("nonce",a),n.textContent=o.cssText,t.appendChild(n)})}});var jd,sn,Vd=f(()=>{"use strict";jd=b(B(),1);Gd();sn=class extends jd.LitElement{createRenderRoot(){let e=this.constructor;e.elementDefinitions&&!e.registry&&(e.registry=new CustomElementRegistry,Object.entries(e.elementDefinitions).forEach(([a,i])=>e.registry.define(a,i)));let o={...e.shadowRootOptions,customElements:e.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return zd(n,e.elementStyles),n}}});var ao,cn,Yd,Kd,Zd,Xd,qd,Lt,Qd=f(()=>{"use strict";ao=b(X(),1);Wd();Hd();Vd();cn=function(t,e,o,n){var a=arguments.length,i=a<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,o,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(i=(a<3?s(i):a>3?s(e,o,i):s(e,o))||i);return a>3&&i&&Object.defineProperty(e,o,i),i},Kd=Symbol("constructorPrototype"),Zd=Symbol("constructorName"),Xd=Symbol("exportpartsDebouncer"),qd=Symbol("dynamicDependenciesLoaded"),Lt=class extends sn{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[Yd]=new nn(5),this[Zd]=this.constructor.name,this[Kd]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[Zd]&&Object.setPrototypeOf(this,this[Kd])}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[qd]||(e[qd]=!0,this.importDynamicDependencies())}importDynamicDependencies(){}updated(e){super.updated(e),this.updateComplete.then(()=>{this.contentAvailableCallback(e),this.applyCustomStylesheet(e),this.scheduleExportpartsUpdate()})}contentAvailableCallback(e){}applyCustomStylesheet(e){var o,n,a;if(((n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))!==null&&n!==void 0?n:[]).forEach(i=>i.remove()),this.useAdoptedStyleSheets){if(e.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((a=this.customStylesheet)!==null&&a!==void 0?a:"")}catch(i){console.error(i,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let i=document.createElement("style");i.classList.add("ft-lit-element--custom-stylesheet"),i.innerHTML=this.customStylesheet,this.shadowRoot.append(i)}}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[Xd].run(()=>{var a,i;!((a=this.exportpartsPrefix)===null||a===void 0)&&a.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((i=this.exportpartsPrefixes)===null||i===void 0?void 0:i.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})}setExportpartsAttribute(e){var o,n,a,i,s,l;let p=x=>x!=null&&x.trim().length>0,u=e.filter(p).map(x=>x.trim());if(u.length===0){this.removeAttribute("exportparts");return}let m=new Set;for(let x of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let O=(i=(a=x.getAttribute("part"))===null||a===void 0?void 0:a.split(" "))!==null&&i!==void 0?i:[],S=(l=(s=x.getAttribute("exportparts"))===null||s===void 0?void 0:s.split(",").map(C=>C.split(":")[1]))!==null&&l!==void 0?l:[];new Array(...O,...S).filter(p).map(C=>C.trim()).forEach(C=>m.add(C))}if(m.size===0){this.removeAttribute("exportparts");return}let y=[...m.values()].flatMap(x=>u.map(O=>`${x}:${O}--${x}`));this.setAttribute("exportparts",[...this.part,...y].join(", "))}};Yd=Xd;cn([(0,ao.property)()],Lt.prototype,"exportpartsPrefix",void 0);cn([Fd([])],Lt.prototype,"exportpartsPrefixes",void 0);cn([(0,ao.property)()],Lt.prototype,"customStylesheet",void 0);cn([(0,ao.state)()],Lt.prototype,"useAdoptedStyleSheets",void 0)});function io(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var ln=f(()=>{"use strict"});var Jd,eu,tu,so,Pt,rr,co,ru=f(()=>{"use strict";Qd();ln();so=Symbol("internalReduxEventsUnsubscribers"),Pt=Symbol("internalStoresUnsubscribers"),rr=Symbol("internalStores"),co=class extends Lt{constructor(){super(...arguments),this[Jd]=new Map,this[eu]=new Map,this[tu]=new Map}get reduxConstructor(){return this.constructor}update(e){super.update(e),[...this.reduxConstructor.reduxReactiveProperties].some(o=>e.has(o))&&this.updateFromStores()}getUnnamedStore(){if(this[rr].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[rr].values()][0]}getStore(e){return e==null?this.getUnnamedStore():this[rr].get(e)}addStore(e,o){var n;o=(n=o??(io(e)?e.name:void 0))!==null&&n!==void 0?n:"default-store",this.unsubscribeFromStore(o),this[rr].set(o,e),this.subscribeToStore(o,e),this.updateFromStores()}removeStore(e){let o=typeof e=="string"?e:e.name;this.unsubscribeFromStore(o),this[rr].delete(o)}setupStores(){this.unsubscribeFromStores(),this[rr].forEach((e,o)=>this.subscribeToStore(o,e)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((e,o)=>{let n=this.constructor.getPropertyOptions(o);if(!n?.attribute||!this.hasAttribute(typeof n?.attribute=="string"?n.attribute:o)){let a=this.getStore(e.store);a&&(e.store?this[Pt].has(e.store):this[Pt].size>0)&&(this[o]=e.selector(a.getState(),this))}})}subscribeToStore(e,o){var n;this[Pt].set(e,o.subscribe(()=>this.updateFromStores())),this[so].set(e,[]),io(o)&&o.eventBus&&((n=this.reduxConstructor.reduxEventListeners)===null||n===void 0||n.forEach((a,i)=>{if(typeof this[i]=="function"&&(!a.store||o.name===a.store)){let s=l=>this[i](l);o.addEventListener(a.eventName,s),this[so].get(e).push(()=>o.removeEventListener(a.eventName,s))}})),this.onStoreAvailable(e)}unsubscribeFromStores(){this[Pt].forEach((e,o)=>this.unsubscribeFromStore(o))}unsubscribeFromStore(e){var o;this[Pt].has(e)&&this[Pt].get(e)(),this[Pt].delete(e),(o=this[so].get(e))===null||o===void 0||o.forEach(n=>n()),this[so].delete(e)}onStoreAvailable(e){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}};Jd=Pt,eu=rr,tu=so;co.reduxProperties=new Map;co.reduxReactiveProperties=new Set;co.reduxEventListeners=new Map});function We(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 a,i;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 ft(t){return!!t&&!!t[te]}function Ke(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 a=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return a===Object||typeof a=="function"&&Function.toString.call(a)===zh}(t)||Array.isArray(t)||!!t[lu]||!!(!((e=t.constructor)===null||e===void 0)&&e[lu])||oi(t)||ni(t))}function or(t,e,o){o===void 0&&(o=!1),wr(t)===0?(o?Object.keys:Er)(t).forEach(function(n){o&&typeof n=="symbol"||e(n,t[n],t)}):t.forEach(function(n,a){return e(a,n,t)})}function wr(t){var e=t[te];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:oi(t)?2:ni(t)?3:0}function Cr(t,e){return wr(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function Bh(t,e){return wr(t)===2?t.get(e):t[e]}function du(t,e,o){var n=wr(t);n===2?t.set(e,o):n===3?t.add(o):t[e]=o}function uu(t,e){return t===e?t!==0||1/t==1/e:t!=t&&e!=e}function oi(t){return Wh&&t instanceof Map}function ni(t){return Hh&&t instanceof Set}function Tt(t){return t.o||t.t}function ai(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=hu(t);delete e[te];for(var o=Er(e),n=0;n<o.length;n++){var a=o[n],i=e[a];i.writable===!1&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(e[a]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[a]})}return Object.create(Object.getPrototypeOf(t),e)}function ii(t,e){return e===void 0&&(e=!1),si(t)||ft(t)||!Ke(t)||(wr(t)>1&&(t.set=t.add=t.clear=t.delete=Mh),Object.freeze(t),e&&or(t,function(o,n){return ii(n,!0)},!0)),t}function Mh(){We(2)}function si(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function tt(t){var e=ri[t];return e||We(18,t),e}function $h(t,e){ri[t]||(ri[t]=e)}function Ja(){return uo}function qa(t,e){e&&(tt("Patches"),t.u=[],t.s=[],t.v=e)}function dn(t){ei(t),t.p.forEach(Uh),t.p=null}function ei(t){t===uo&&(uo=t.l)}function ou(t){return uo={p:[],l:uo,h:t,m:!0,_:0}}function Uh(t){var e=t[te];e.i===0||e.i===1?e.j():e.g=!0}function Ya(t,e){e._=e.p.length;var o=e.p[0],n=t!==void 0&&t!==o;return e.h.O||tt("ES5").S(e,t,n),n?(o[te].P&&(dn(e),We(4)),Ke(t)&&(t=un(e,t),e.l||pn(e,t)),e.u&&tt("Patches").M(o[te].t,t,e.u,e.s)):t=un(e,o,[]),dn(e),e.u&&e.v(e.u,e.s),t!==fu?t:void 0}function un(t,e,o){if(si(e))return e;var n=e[te];if(!n)return or(e,function(l,p){return nu(t,n,e,l,p,o)},!0),e;if(n.A!==t)return e;if(!n.P)return pn(t,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var a=n.i===4||n.i===5?n.o=ai(n.k):n.o,i=a,s=!1;n.i===3&&(i=new Set(a),a.clear(),s=!0),or(i,function(l,p){return nu(t,n,a,l,p,o,s)}),pn(t,a,!1),o&&t.u&&tt("Patches").N(n,o,t.u,t.s)}return n.o}function nu(t,e,o,n,a,i,s){if(ft(a)){var l=un(t,a,i&&e&&e.i!==3&&!Cr(e.R,n)?i.concat(n):void 0);if(du(o,n,l),!ft(l))return;t.m=!1}else s&&o.add(a);if(Ke(a)&&!si(a)){if(!t.h.D&&t._<1)return;un(t,a),e&&e.A.l||pn(t,a)}}function pn(t,e,o){o===void 0&&(o=!1),!t.l&&t.h.D&&t.m&&ii(e,o)}function Xa(t,e){var o=t[te];return(o?Tt(o):t)[e]}function au(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 _t(t){t.P||(t.P=!0,t.l&&_t(t.l))}function Qa(t){t.o||(t.o=ai(t.t))}function ti(t,e,o){var n=oi(e)?tt("MapSet").F(e,o):ni(e)?tt("MapSet").T(e,o):t.O?function(a,i){var s=Array.isArray(a),l={i:s?1:0,A:i?i.A:Ja(),P:!1,I:!1,R:{},l:i,t:a,k:null,o:null,j:null,C:!1},p=l,u=po;s&&(p=[l],u=lo);var m=Proxy.revocable(p,u),y=m.revoke,x=m.proxy;return l.k=x,l.j=y,x}(e,o):tt("ES5").J(e,o);return(o?o.A:Ja()).p.push(n),n}function Fh(t){return ft(t)||We(22,t),function e(o){if(!Ke(o))return o;var n,a=o[te],i=wr(o);if(a){if(!a.P&&(a.i<4||!tt("ES5").K(a)))return a.t;a.I=!0,n=iu(o,i),a.I=!1}else n=iu(o,i);return or(n,function(s,l){a&&Bh(a.t,s)===l||du(n,s,e(l))}),i===3?new Set(n):n}(t)}function iu(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return ai(t)}function pu(){function t(s,l){var p=i[s];return p?p.enumerable=l:i[s]=p={configurable:!0,enumerable:l,get:function(){var u=this[te];return po.get(u,s)},set:function(u){var m=this[te];po.set(m,s,u)}},p}function e(s){for(var l=s.length-1;l>=0;l--){var p=s[l][te];if(!p.P)switch(p.i){case 5:n(p)&&_t(p);break;case 4:o(p)&&_t(p)}}}function o(s){for(var l=s.t,p=s.k,u=Er(p),m=u.length-1;m>=0;m--){var y=u[m];if(y!==te){var x=l[y];if(x===void 0&&!Cr(l,y))return!0;var O=p[y],S=O&&O[te];if(S?S.t!==x:!uu(O,x))return!0}}var C=!!l[te];return u.length!==Er(l).length+(C?0:1)}function n(s){var l=s.k;if(l.length!==s.t.length)return!0;var p=Object.getOwnPropertyDescriptor(l,l.length-1);if(p&&!p.get)return!0;for(var u=0;u<l.length;u++)if(!l.hasOwnProperty(u))return!0;return!1}function a(s){s.g&&We(3,JSON.stringify(Tt(s)))}var i={};$h("ES5",{J:function(s,l){var p=Array.isArray(s),u=function(y,x){if(y){for(var O=Array(x.length),S=0;S<x.length;S++)Object.defineProperty(O,""+S,t(S,!0));return O}var C=hu(x);delete C[te];for(var P=Er(C),I=0;I<P.length;I++){var L=P[I];C[L]=t(L,y||!!C[L].enumerable)}return Object.create(Object.getPrototypeOf(x),C)}(p,s),m={i:p?5:4,A:l?l.A:Ja(),P:!1,I:!1,R:{},l,t:s,k:u,o:null,g:!1,C:!1};return Object.defineProperty(u,te,{value:m,writable:!0}),u},S:function(s,l,p){p?ft(l)&&l[te].A===s&&e(s.p):(s.u&&function u(m){if(m&&typeof m=="object"){var y=m[te];if(y){var x=y.t,O=y.k,S=y.R,C=y.i;if(C===4)or(O,function(U){U!==te&&(x[U]!==void 0||Cr(x,U)?S[U]||u(O[U]):(S[U]=!0,_t(y)))}),or(x,function(U){O[U]!==void 0||Cr(O,U)||(S[U]=!1,_t(y))});else if(C===5){if(n(y)&&(_t(y),S.length=!0),O.length<x.length)for(var P=O.length;P<x.length;P++)S[P]=!1;else for(var I=x.length;I<O.length;I++)S[I]=!0;for(var L=Math.min(O.length,x.length),M=0;M<L;M++)O.hasOwnProperty(M)||(S[M]=!0),S[M]===void 0&&u(O[M])}}}}(s.p[0]),e(s.p))},K:function(s){return s.i===4?o(s):n(s)}})}var su,uo,ci,Wh,Hh,cu,fu,lu,te,zh,Er,hu,ri,po,lo,Gh,ke,jh,jS,VS,KS,ZS,qS,YS,fn,hn=f(()=>{ci=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",Wh=typeof Map<"u",Hh=typeof Set<"u",cu=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",fu=ci?Symbol.for("immer-nothing"):((su={})["immer-nothing"]=!0,su),lu=ci?Symbol.for("immer-draftable"):"__$immer_draftable",te=ci?Symbol.for("immer-state"):"__$immer_state",zh=""+Object.prototype.constructor,Er=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,hu=Object.getOwnPropertyDescriptors||function(t){var e={};return Er(t).forEach(function(o){e[o]=Object.getOwnPropertyDescriptor(t,o)}),e},ri={},po={get:function(t,e){if(e===te)return t;var o=Tt(t);if(!Cr(o,e))return function(a,i,s){var l,p=au(i,s);return p?"value"in p?p.value:(l=p.get)===null||l===void 0?void 0:l.call(a.k):void 0}(t,o,e);var n=o[e];return t.I||!Ke(n)?n:n===Xa(t.t,e)?(Qa(t),t.o[e]=ti(t.A.h,n,t)):n},has:function(t,e){return e in Tt(t)},ownKeys:function(t){return Reflect.ownKeys(Tt(t))},set:function(t,e,o){var n=au(Tt(t),e);if(n?.set)return n.set.call(t.k,o),!0;if(!t.P){var a=Xa(Tt(t),e),i=a?.[te];if(i&&i.t===o)return t.o[e]=o,t.R[e]=!1,!0;if(uu(o,a)&&(o!==void 0||Cr(t.t,e)))return!0;Qa(t),_t(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 Xa(t.t,e)!==void 0||e in t.t?(t.R[e]=!1,Qa(t),_t(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var o=Tt(t),n=Reflect.getOwnPropertyDescriptor(o,e);return n&&{writable:!0,configurable:t.i!==1||e!=="length",enumerable:n.enumerable,value:o[e]}},defineProperty:function(){We(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){We(12)}},lo={};or(po,function(t,e){lo[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}}),lo.deleteProperty=function(t,e){return lo.set.call(this,t,e,void 0)},lo.set=function(t,e,o){return po.set.call(this,t[0],e,o,t[0])};Gh=function(){function t(o){var n=this;this.O=cu,this.D=!0,this.produce=function(a,i,s){if(typeof a=="function"&&typeof i!="function"){var l=i;i=a;var p=n;return function(C){var P=this;C===void 0&&(C=l);for(var I=arguments.length,L=Array(I>1?I-1:0),M=1;M<I;M++)L[M-1]=arguments[M];return p.produce(C,function(U){var F;return(F=i).call.apply(F,[P,U].concat(L))})}}var u;if(typeof i!="function"&&We(6),s!==void 0&&typeof s!="function"&&We(7),Ke(a)){var m=ou(n),y=ti(n,a,void 0),x=!0;try{u=i(y),x=!1}finally{x?dn(m):ei(m)}return typeof Promise<"u"&&u instanceof Promise?u.then(function(C){return qa(m,s),Ya(C,m)},function(C){throw dn(m),C}):(qa(m,s),Ya(u,m))}if(!a||typeof a!="object"){if((u=i(a))===void 0&&(u=a),u===fu&&(u=void 0),n.D&&ii(u,!0),s){var O=[],S=[];tt("Patches").M(a,u,O,S),s(O,S)}return u}We(21,a)},this.produceWithPatches=function(a,i){if(typeof a=="function")return function(u){for(var m=arguments.length,y=Array(m>1?m-1:0),x=1;x<m;x++)y[x-1]=arguments[x];return n.produceWithPatches(u,function(O){return a.apply(void 0,[O].concat(y))})};var s,l,p=n.produce(a,i,function(u,m){s=u,l=m});return typeof Promise<"u"&&p instanceof Promise?p.then(function(u){return[u,s,l]}):[p,s,l]},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){Ke(o)||We(8),ft(o)&&(o=Fh(o));var n=ou(this),a=ti(this,o,void 0);return a[te].C=!0,ei(n),a},e.finishDraft=function(o,n){var a=o&&o[te],i=a.A;return qa(i,n),Ya(void 0,i)},e.setAutoFreeze=function(o){this.D=o},e.setUseProxies=function(o){o&&!cu&&We(20),this.O=o},e.applyPatches=function(o,n){var a;for(a=n.length-1;a>=0;a--){var i=n[a];if(i.path.length===0&&i.op==="replace"){o=i.value;break}}a>-1&&(n=n.slice(a+1));var s=tt("Patches").$;return ft(o)?s(o,n):this.produce(o,function(l){return s(l,n)})},t}(),ke=new Gh,jh=ke.produce,jS=ke.produceWithPatches.bind(ke),VS=ke.setAutoFreeze.bind(ke),KS=ke.setUseProxies.bind(ke),ZS=ke.applyPatches.bind(ke),qS=ke.createDraft.bind(ke),YS=ke.finishDraft.bind(ke),fn=jh});function kt(t){"@babel/helpers - typeof";return kt=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},kt(t)}var li=f(()=>{});function di(t,e){if(kt(t)!=="object"||t===null)return t;var o=t[Symbol.toPrimitive];if(o!==void 0){var n=o.call(t,e||"default");if(kt(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var yu=f(()=>{li()});function ui(t){var e=di(t,"string");return kt(e)==="symbol"?e:String(e)}var mu=f(()=>{li();yu()});function pi(t,e,o){return e=ui(e),e in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}var gu=f(()=>{mu()});function bu(t,e){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(t,a).enumerable})),o.push.apply(o,n)}return o}function yn(t){for(var e=1;e<arguments.length;e++){var o=arguments[e]!=null?arguments[e]:{};e%2?bu(Object(o),!0).forEach(function(n){pi(t,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):bu(Object(o)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(o,n))})}return t}var xu=f(()=>{gu()});function xe(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. "}function Vh(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 hi(t,e,o){var n;if(typeof e=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(xe(0));if(typeof e=="function"&&typeof o>"u"&&(o=e,e=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(xe(1));return o(hi)(t,e)}if(typeof t!="function")throw new Error(xe(2));var a=t,i=e,s=[],l=s,p=!1;function u(){l===s&&(l=s.slice())}function m(){if(p)throw new Error(xe(3));return i}function y(C){if(typeof C!="function")throw new Error(xe(4));if(p)throw new Error(xe(5));var P=!0;return u(),l.push(C),function(){if(P){if(p)throw new Error(xe(6));P=!1,u();var L=l.indexOf(C);l.splice(L,1),s=null}}}function x(C){if(!Vh(C))throw new Error(xe(7));if(typeof C.type>"u")throw new Error(xe(8));if(p)throw new Error(xe(9));try{p=!0,i=a(i,C)}finally{p=!1}for(var P=s=l,I=0;I<P.length;I++){var L=P[I];L()}return C}function O(C){if(typeof C!="function")throw new Error(xe(10));a=C,x({type:mn.REPLACE})}function S(){var C,P=y;return C={subscribe:function(L){if(typeof L!="object"||L===null)throw new Error(xe(11));function M(){L.next&&L.next(m())}M();var U=P(M);return{unsubscribe:U}}},C[vu]=function(){return this},C}return x({type:mn.INIT}),n={dispatch:x,subscribe:y,getState:m,replaceReducer:O},n[vu]=S,n}function Kh(t){Object.keys(t).forEach(function(e){var o=t[e],n=o(void 0,{type:mn.INIT});if(typeof n>"u")throw new Error(xe(12));if(typeof o(void 0,{type:mn.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(xe(13))})}function Su(t){for(var e=Object.keys(t),o={},n=0;n<e.length;n++){var a=e[n];typeof t[a]=="function"&&(o[a]=t[a])}var i=Object.keys(o),s,l;try{Kh(o)}catch(p){l=p}return function(u,m){if(u===void 0&&(u={}),l)throw l;if(0)var y;for(var x=!1,O={},S=0;S<i.length;S++){var C=i[S],P=o[C],I=u[C],L=P(I,m);if(typeof L>"u"){var M=m&&m.type;throw new Error(xe(14))}O[C]=L,x=x||L!==I}return x=x||i.length!==Object.keys(u).length,x?O:u}}function Ar(){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,a){return function(){return n(a.apply(void 0,arguments))}})}function Ou(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return function(n){return function(){var a=n.apply(void 0,arguments),i=function(){throw new Error(xe(15))},s={getState:a.getState,dispatch:function(){return i.apply(void 0,arguments)}},l=e.map(function(p){return p(s)});return i=Ar.apply(void 0,l)(a.dispatch),yn(yn({},a),{},{dispatch:i})}}}var vu,fi,mn,gn=f(()=>{xu();vu=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),fi=function(){return Math.random().toString(36).substring(7).split("").join(".")},mn={INIT:"@@redux/INIT"+fi(),REPLACE:"@@redux/REPLACE"+fi(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+fi()}}});function Cu(t){var e=function(n){var a=n.dispatch,i=n.getState;return function(s){return function(l){return typeof l=="function"?l(a,i,t):s(l)}}};return e}var Eu,yi,wu=f(()=>{Eu=Cu();Eu.withExtraArgument=Cu;yi=Eu});function ry(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}function xi(t){return Ke(t)?fn(t,function(){}):t}function ay(t){return typeof t=="boolean"}function iy(){return function(e){return sy(e)}}function sy(t){t===void 0&&(t={});var e=t.thunk,o=e===void 0?!0:e,n=t.immutableCheck,a=n===void 0?!0:n,i=t.serializableCheck,s=i===void 0?!0:i,l=new oy;if(o&&(ay(o)?l.push(yi):l.push(yi.withExtraArgument(o.extraArgument))),0){if(a)var p;if(s)var u}return l}function Pu(t){var e=iy(),o=t||{},n=o.reducer,a=n===void 0?void 0:n,i=o.middleware,s=i===void 0?e():i,l=o.devTools,p=l===void 0?!0:l,u=o.preloadedState,m=u===void 0?void 0:u,y=o.enhancers,x=y===void 0?void 0:y,O;if(typeof a=="function")O=a;else if(ry(a))O=Su(a);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),!gi&&!Array.isArray(S)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!gi&&S.some(function(U){return typeof U!="function"}))throw new Error("each middleware provided to configureStore must be a function");var C=Ou.apply(void 0,S),P=Ar;p&&(P=ty(Dt({trace:!gi},typeof p=="object"&&p)));var I=new ny(C),L=I;Array.isArray(x)?L=Rr([C],x):typeof x=="function"&&(L=x(I));var M=P.apply(void 0,L);return hi(O,m,M)}function Bt(t,e){function o(){for(var n=[],a=0;a<arguments.length;a++)n[a]=arguments[a];if(e){var i=e.apply(void 0,n);if(!i)throw new Error("prepareAction did not return an object");return Dt(Dt({type:t,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.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 Tu(t){var e={},o=[],n,a={addCase:function(i,s){var l=typeof i=="string"?i:i.type;if(l in e)throw new Error("addCase cannot be called with two reducers for the same action type");return e[l]=s,a},addMatcher:function(i,s){return o.push({matcher:i,reducer:s}),a},addDefaultCase:function(i){return n=i,a}};return t(a),[e,o,n]}function cy(t){return typeof t=="function"}function ly(t,e,o,n){o===void 0&&(o=[]);var a=typeof e=="function"?Tu(e):[e,o,n],i=a[0],s=a[1],l=a[2],p;if(cy(t))p=function(){return xi(t())};else{var u=xi(t);p=function(){return u}}function m(y,x){y===void 0&&(y=p());var O=Rr([i[x.type]],s.filter(function(S){var C=S.matcher;return C(x)}).map(function(S){var C=S.reducer;return C}));return O.filter(function(S){return!!S}).length===0&&(O=[l]),O.reduce(function(S,C){if(C)if(ft(S)){var P=S,I=C(P,x);return I===void 0?S:I}else{if(Ke(S))return fn(S,function(L){return C(L,x)});var I=C(S,x);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 dy(t,e){return t+"/"+e}function _u(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:xi(t.initialState),n=t.reducers||{},a=Object.keys(n),i={},s={},l={};a.forEach(function(m){var y=n[m],x=dy(e,m),O,S;"reducer"in y?(O=y.reducer,S=y.prepare):O=y,i[m]=O,s[x]=O,l[m]=S?Bt(x,S):Bt(x)});function p(){var m=typeof t.extraReducers=="function"?Tu(t.extraReducers):[t.extraReducers],y=m[0],x=y===void 0?{}:y,O=m[1],S=O===void 0?[]:O,C=m[2],P=C===void 0?void 0:C,I=Dt(Dt({},x),s);return ly(o,function(L){for(var M in I)L.addCase(M,I[M]);for(var U=0,F=S;U<F.length;U++){var Ee=F[U];L.addMatcher(Ee.matcher,Ee.reducer)}P&&L.addDefaultCase(P)})}var u;return{name:e,reducer:function(m,y){return u||(u=p()),u(m,y)},actions:l,caseReducers:i,getInitialState:function(){return u||(u=p()),u.getInitialState()}}}function yy(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function my(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var Lu,Zh,Rr,qh,Yh,Xh,Au,Qh,Jh,Ru,Dt,mi,ey,ty,hO,oy,ny,gi,uy,py,fy,bi,Nu,hy,bO,ku,Du,Bu,xO,vO,SO,OO,vi,CO,EO,wO,Iu,AO,gy,RO,Mu=f(()=>{hn();gn();gn();gn();wu();hn();hn();Lu=function(){var t=function(e,o){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,a){n.__proto__=a}||function(n,a){for(var i in a)Object.prototype.hasOwnProperty.call(a,i)&&(n[i]=a[i])},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)}}(),Zh=function(t,e){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,a,i,s;return s={next:l(0),throw:l(1),return:l(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(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,a&&(i=u[0]&2?a.return:u[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,u[1])).done)return i;switch(a=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,a=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=e.call(t,o)}catch(m){u=[6,m],a=0}finally{n=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Rr=function(t,e){for(var o=0,n=e.length,a=t.length;o<n;o++,a++)t[a]=e[o];return t},qh=Object.defineProperty,Yh=Object.defineProperties,Xh=Object.getOwnPropertyDescriptors,Au=Object.getOwnPropertySymbols,Qh=Object.prototype.hasOwnProperty,Jh=Object.prototype.propertyIsEnumerable,Ru=function(t,e,o){return e in t?qh(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o},Dt=function(t,e){for(var o in e||(e={}))Qh.call(e,o)&&Ru(t,o,e[o]);if(Au)for(var n=0,a=Au(e);n<a.length;n++){var o=a[n];Jh.call(e,o)&&Ru(t,o,e[o])}return t},mi=function(t,e){return Yh(t,Xh(e))},ey=function(t,e,o){return new Promise(function(n,a){var i=function(p){try{l(o.next(p))}catch(u){a(u)}},s=function(p){try{l(o.throw(p))}catch(u){a(u)}},l=function(p){return p.done?n(p.value):Promise.resolve(p.value).then(i,s)};l((o=o.apply(t,e)).next())})},ty=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Ar:Ar.apply(null,arguments)},hO=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}};oy=function(t){Lu(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=t.apply(this,o)||this;return Object.setPrototypeOf(a,e.prototype),a}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,Rr([void 0],o[0].concat(this)))):new(e.bind.apply(e,Rr([void 0],o.concat(this))))},e}(Array),ny=function(t){Lu(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=t.apply(this,o)||this;return Object.setPrototypeOf(a,e.prototype),a}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,Rr([void 0],o[0].concat(this)))):new(e.bind.apply(e,Rr([void 0],o.concat(this))))},e}(Array);gi=!0;uy="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",py=function(t){t===void 0&&(t=21);for(var e="",o=t;o--;)e+=uy[Math.random()*64|0];return e},fy=["name","message","stack","code"],bi=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),Nu=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),hy=function(t){if(typeof t=="object"&&t!==null){for(var e={},o=0,n=fy;o<n.length;o++){var a=n[o];typeof t[a]=="string"&&(e[a]=t[a])}return e}return{message:String(t)}},bO=function(){function t(e,o,n){var a=Bt(e+"/fulfilled",function(m,y,x,O){return{payload:m,meta:mi(Dt({},O||{}),{arg:x,requestId:y,requestStatus:"fulfilled"})}}),i=Bt(e+"/pending",function(m,y,x){return{payload:void 0,meta:mi(Dt({},x||{}),{arg:y,requestId:m,requestStatus:"pending"})}}),s=Bt(e+"/rejected",function(m,y,x,O,S){return{payload:O,error:(n&&n.serializeError||hy)(m||"Rejected"),meta:mi(Dt({},S||{}),{arg:x,requestId:y,rejectedWithValue:!!O,requestStatus:"rejected",aborted:m?.name==="AbortError",condition:m?.name==="ConditionError"})}}),l=!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,x,O){var S=n?.idGenerator?n.idGenerator(m):py(),C=new p,P,I=!1;function L(U){P=U,C.abort()}var M=function(){return ey(this,null,function(){var U,F,Ee,qe,Oe,Ye,fe;return Zh(this,function(g){switch(g.label){case 0:return g.trys.push([0,4,,5]),qe=(U=n?.condition)==null?void 0:U.call(n,m,{getState:x,extra:O}),my(qe)?[4,qe]:[3,2];case 1:qe=g.sent(),g.label=2;case 2:if(qe===!1||C.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return I=!0,Oe=new Promise(function(v,k){return C.signal.addEventListener("abort",function(){return k({name:"AbortError",message:P||"Aborted"})})}),y(i(S,m,(F=n?.getPendingMeta)==null?void 0:F.call(n,{requestId:S,arg:m},{getState:x,extra:O}))),[4,Promise.race([Oe,Promise.resolve(o(m,{dispatch:y,getState:x,extra:O,requestId:S,signal:C.signal,abort:L,rejectWithValue:function(v,k){return new bi(v,k)},fulfillWithValue:function(v,k){return new Nu(v,k)}})).then(function(v){if(v instanceof bi)throw v;return v instanceof Nu?a(v.payload,S,m,v.meta):a(v,S,m)})])];case 3:return Ee=g.sent(),[3,5];case 4:return Ye=g.sent(),Ee=Ye instanceof bi?s(null,S,m,Ye.payload,Ye.meta):s(Ye,S,m),[3,5];case 5:return fe=n&&!n.dispatchConditionRejection&&s.match(Ee)&&Ee.meta.condition,fe||y(Ee),[2,Ee]}})})}();return Object.assign(M,{abort:L,requestId:S,arg:m,unwrap:function(){return M.then(yy)}})}}return Object.assign(u,{pending:i,rejected:s,fulfilled:a,typePrefix:e})}return t.withTypes=function(){return t},t}();ku="listener",Du="completed",Bu="cancelled",xO="task-"+Bu,vO="task-"+Du,SO=ku+"-"+Bu,OO=ku+"-"+Du,vi="listenerMiddleware",CO=Bt(vi+"/add"),EO=Bt(vi+"/removeAll"),wO=Bt(vi+"/remove"),AO=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(t){return(Iu||(Iu=Promise.resolve())).then(t).catch(function(e){return setTimeout(function(){throw e},0)})},gy=function(t){return function(e){setTimeout(e,t)}},RO=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:gy(10);pu()});function by(t,e){return class extends t{constructor(){super(...arguments),this.eventBus=e??document.createElement("span")}addEventListener(o,n,a){this.eventBus.addEventListener(o,n,a)}dispatchEvent(o){return this.eventBus.dispatchEvent(o)}removeEventListener(o,n,a){this.eventBus.removeEventListener(o,n,a)}}}var bn,$u=f(()=>{"use strict";bn=class extends by(Object){}});var Uu,Fu=f(()=>{"use strict";Mu();ln();Za();$u();window.ftReduxStores||(window.ftReduxStores={});Uu=class t extends bn{static get(e){var o;let n=typeof e=="string"?e:e.name,a=typeof e=="string"?void 0:e,i=window.ftReduxStores[n];if(io(i))return i;if(a==null)return;let s=_u({...a,reducers:(o=a.reducers)!==null&&o!==void 0?o:{}}),l=Pu({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[a.name]=new t(s,l)}constructor(e,o){super(),this.reduxSlice=e,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new on;let n=a=>a!=null?JSON.parse(JSON.stringify(a)):a;this.actions=new Proxy(this.reduxSlice.actions,{get:(a,i,s)=>{let l=i,p=a[l];return p?(...u)=>{let m=p(...u.map(n));return this.reduxStore.dispatch(m),m}:u=>{this.setState({[l]:n(u)})}}})}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 Wu=f(()=>{"use strict";rn()});var Hu=f(()=>{"use strict";$d();Za();ru();Fu();ln();Wu()});var zu=f(()=>{"use strict"});var xy,Gu=f(()=>{"use strict";xy=b(X());Hu();zu();Fe()});var xn,Si=f(()=>{"use strict";Fe();no();xn=class extends et{async listMySearches(){let e=D.getState().session;return e?.sessionAuthenticated?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),5*60*1e3):[]}}});var vn,Oi=f(()=>{"use strict";Fe();no();vn=class extends et{async listMyBookmarks(){let e=D.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),5*60*1e3):[]}}});var On,vy,Sn,Ci,ju,Ei=f(()=>{"use strict";On=b(N());Si();Oi();Fe();vy="ft-user-assets",Sn=On.FtReduxStore.get({name:vy,initialState:{savedSearches:void 0,bookmarks:void 0}}),Ci=class{constructor(){this.currentSession=D.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new vn,this.savedSearchesService=new xn,D.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:o}=D.getState();(0,On.deepEqual)((e=this.currentSession)===null||e===void 0?void 0:e.profile,o?.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),Sn.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),Sn.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();Sn.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}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;Sn.actions.bookmarks(o)}}},ju=new Ci});var wi,Vu=f(()=>{"use strict";Fe();wi=class{addCommand(e,o=!1){D.commands.add(e,o)}consumeCommand(e){return D.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new wi});var Ku,Ai,Zu=f(()=>{"use strict";Ku=b(N()),Ai=class{highlightHtml(e,o,n){(0,Ku.highlightHtml)(e,o,n)}};window.FluidTopicsHighlightHtmlService=new Ai});var qu,Ri,Yu=f(()=>{"use strict";qu=b(N());Fe();Ri=class{isDate(e){var o,n,a,i;return(i=(a=((n=(o=D.getState().metadataConfiguration)===null||o===void 0?void 0:o.descriptors)!==null&&n!==void 0?n:[]).find(l=>l.key===e))===null||a===void 0?void 0:a.date)!==null&&i!==void 0?i:!1}format(e,o){var n,a,i;return qu.DateFormatter.format(e,(n=o?.locale)!==null&&n!==void 0?n:D.getState().uiLocale,(a=o?.longFormat)!==null&&a!==void 0?a:!1,(i=o?.withTime)!==null&&i!==void 0?i:!1)}};window.FluidTopicsDateService=new Ri});var Xu,Nr,Qu=f(()=>{"use strict";Xu=b(N());Fe();Nr=class{static get(e,o){var n,a,i,s;let l=D.getState(),{lang:p,region:u}=(a=(n=l.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&a!==void 0?a:{lang:"en",region:"US"};return new Xu.SearchPlaceConverter(l.baseUrl,(s=(i=window.FluidTopicsClientConfiguration)===null||i===void 0?void 0:i.predefinedSorts)!==null&&s!==void 0?s:{},e??20,l.searchInAllLanguagesAllowed,o??`${p}-${u}`)}}});var Ju=f(()=>{"use strict";Oi();Qo();Vu();Va();no();Zu();Si();Yu();Qu()});var ep=f(()=>{"use strict"});var tp,Mt=f(()=>{"use strict";tp=b(N());Ka();Gu();Fe();Ei();Ju();za();ep();Ka();(0,tp.customElement)("ft-app-context")(ie)});function He(t){var e,o;class n extends t{constructor(){super(...arguments),this.useCustomMessageContexts=!1,this[e]=new Map,this[o]=new Map}get i18nService(){return this.useCustomMessageContexts?Bd:tr}i18n(i,s,...l){var p;if(typeof i=="string")return this.i18nService.resolveMessage(i,s,...l);let u=(p=i.args)!==null&&p!==void 0?p:i.argsProvider?i.argsProvider(this):[];return this.i18nService.resolveMessage(i.context,i.key,...u)}onI18nUpdate(i){var s,l,p;(s=this[Ni])===null||s===void 0||s.forEach((u,m)=>{let y=this.getI18nAttributeValue(m);y&&(this[m]=this.getI18nAttributeMessage(y,u,i))}),(l=this[Ii])===null||l===void 0||l.forEach((u,m)=>{let y=this.getI18nListAttributeValues(m);this[m]=y?.map(x=>this.getI18nAttributeMessage(x,u,i))}),(p=this[Cn])===null||p===void 0||p.forEach((u,m)=>{u.context.toLowerCase()===i.toLowerCase()&&(this[m]=this.i18n(u))}),setTimeout(()=>this.requestUpdate(),0)}buildI18nAttributeMessage(i,s){return{...i,message:this.i18n({context:i.context,key:i.key,...s})}}getI18nAttributeMessage(i,s,l){var p;let u=!l||((p=i.context)===null||p===void 0?void 0:p.toLowerCase())===l.toLowerCase();return i.context&&i.key&&u?this.buildI18nAttributeMessage(i,s):i}update(i){var s,l,p;super.update(i),(s=this[Ni])===null||s===void 0||s.forEach((u,m)=>{let y=this.getI18nAttributeValue(m);y?.context&&y.key&&(i.has(m)||u.argsProvider!=null)&&(this.addI18nContextIfNeeded(y,i,m),this[m]=this.getI18nAttributeMessage(y,u))}),(l=this[Ii])===null||l===void 0||l.forEach((u,m)=>{let y=this.getI18nListAttributeValues(m);(i.has(m)||u.argsProvider!=null)&&(this[m]=y?.map(x=>(this.addI18nContextIfNeeded(x,i,m),this.getI18nAttributeMessage(x,u))))}),(p=this[Cn])===null||p===void 0||p.forEach((u,m)=>{u.argsProvider!=null&&(this[m]=this.i18n(u))})}getI18nAttributeValue(i){return this[i]}getI18nListAttributeValues(i){return this[i]}addI18nContextIfNeeded(i,s,l){i.context&&i.key&&s.has(l)&&this.addI18nContext(i.context)}addI18nMessagesAndSubscribe(i,s){i=i.toLowerCase(),this[fo].has(i)||this[fo].set(i,this.i18nService.subscribe(i,()=>this.onI18nUpdate(i))),this.i18nService.prepareContext(i,s??{}),this.onI18nUpdate(i)}connectedCallback(){var i,s,l,p,u,m;super.connectedCallback(),new Set([...(s=(i=this[Cn])===null||i===void 0?void 0:i.values())!==null&&s!==void 0?s:[],...[...(p=(l=this[Ni])===null||l===void 0?void 0:l.keys())!==null&&p!==void 0?p:[]].map(y=>this.getI18nAttributeValue(y)),...[...(m=(u=this[Ii])===null||u===void 0?void 0:u.keys())!==null&&m!==void 0?m:[]].flatMap(y=>this.getI18nListAttributeValues(y))].map(y=>y?.context)).forEach(y=>y&&this.addI18nMessages(y)),this[Li].forEach((y,x)=>{this.addI18nMessages(x,y)})}addI18nMessages(i,s){this[Li].set(i,s??{}),this.addI18nMessagesAndSubscribe(i,s)}addI18nContext(i,s){this.addI18nMessages(typeof i=="string"?i:i.name,s)}disconnectedCallback(){super.disconnectedCallback(),this[fo].forEach(i=>i()),this[fo].clear()}}return e=Li,o=fo,Sy([(0,op.property)({type:Boolean})],n.prototype,"useCustomMessageContexts",void 0),n}var wn,op,Sy,Ni,Ii,Cn,Li,fo,rp,En,An=f(()=>{"use strict";wn=b(N());Mt();op=b(X()),Sy=function(t,e,o,n){var a=arguments.length,i=a<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,o,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(i=(a<3?s(i):a>3?s(e,o,i):s(e,o))||i);return a>3&&i&&Object.defineProperty(e,o,i),i},Ni=Symbol("i18nAttributes"),Ii=Symbol("i18nListAttributes"),Cn=Symbol("i18nProperties"),Li=Symbol("i18nManualContexts"),fo=Symbol("i18nUnsubs");rp=class extends He(wn.FtLitElement){},En=class extends He(wn.FtLitElementRedux){}});var Rn,Nn,In,ho,Ze,Pi=f(()=>{"use strict";Rn=b(B()),Nn=b(X()),In=b(N());Ha();An();Mt();ho=function(t,e,o,n){var a=arguments.length,i=a<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,o,n);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(i=(a<3?s(i):a>3?s(e,o,i):s(e,o))||i);return a>3&&i&&Object.defineProperty(e,o,i),i},Ze=class extends En{constructor(){super(),this.editorMode=!1,this.addStore(D)}render(){return!this.key||!this.context?this.editorMode?"Select a context and a label key.":Rn.nothing:Rn.html`
1163
1163
  <span class="ft-i18n">
1164
1164
  ${this.i18n(this.context,this.key,...Array.isArray(this.args)?this.args:[])}
1165
1165
  </span>