@fluid-topics/ft-search-context 2.1.12 → 2.1.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";(()=>{var ys=Object.create;var fr=Object.defineProperty;var gs=Object.getOwnPropertyDescriptor;var Ss=Object.getOwnPropertyNames;var Es=Object.getPrototypeOf,bs=Object.prototype.hasOwnProperty;var Ot=(t,e)=>()=>{try{return e||t((e={exports:{}}).exports,e),e.exports}catch(r){throw e=0,r}};var As=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of Ss(e))!bs.call(t,s)&&s!==r&&fr(t,s,{get:()=>e[s],enumerable:!(n=gs(e,s))||n.enumerable});return t};var E=(t,e,r)=>(r=t!=null?ys(Es(t)):{},As(e||!t||!t.__esModule?fr(r,"default",{value:t,enumerable:!0}):r,t));var w=Ot((xi,mr)=>{mr.exports=ftGlobals.wcUtils});var fe=Ot((Oi,vr)=>{vr.exports=ftGlobals.lit});var Y=Ot((Ti,yr)=>{yr.exports=ftGlobals.litDecorators});var vs=E(w());var fs=E(fe()),G=E(Y()),D=E(w());var gr=E(fe());var Sr=gr.css`
|
|
2
|
-
`;var we=E(w()),lr=E(Y());var ke;(function(t){t.CLUSTERED_SEARCH="CLUSTERED_SEARCH"})(ke||(ke={}));var R=E(w());var Er=E(w()),Cs={setRequest:(t,e)=>{t.request=e.payload}},br=t=>Er.FtReduxStore.get({name:"ft-search-"+t,initialState:{request:{query:"",clusterSortCriterions:[],metadataFilters:[],facets:[],sort:[],sortId:void 0,paging:{page:1,perPage:20},keywordMatch:void 0},liveQuery:"",recentQueries:[],paging:void 0,facets:void 0,spellcheck:void 0,locales:[],results:void 0,announcements:void 0,suggestResults:void 0,configuration:void 0},reducers:Cs});var Ar;(function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"})(Ar||(Ar={}));var Cr;(function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"})(Cr||(Cr={}));var xr;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(xr||(xr={}));var X;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(X||(X={}));var Or;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(Or||(Or={}));var Tr;(function(t){t.VALUE="VALUE",t.DATE="DATE",t.RANGE="RANGE"})(Tr||(Tr={}));var wr;(function(t){t.OFFICIAL="OFFICIAL",t.AI="AI"})(wr||(wr={}));var ne;(function(t){t.BOOKMARK__CREATE="BOOKMARK__CREATE",t.BOOKMARK__DELETE="BOOKMARK__DELETE",t.CASE_DEFLECTION__START="CASE_DEFLECTION__START",t.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",t.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",t.CHATBOT__RATE="CHATBOT__RATE",t.COLLECTION__CREATE="COLLECTION__CREATE",t.COLLECTION__UPDATE="COLLECTION__UPDATE",t.COLLECTION__DELETE="COLLECTION__DELETE",t.CUSTOM_EVENT__TRIGGER="CUSTOM_EVENT__TRIGGER",t.DOCUMENT__ON_DEMAND_TRANSLATE="DOCUMENT__ON_DEMAND_TRANSLATE",t.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",t.DOCUMENT__PRINT="DOCUMENT__PRINT",t.DOCUMENT__PROCESS="DOCUMENT__PROCESS",t.DOCUMENT__RATE="DOCUMENT__RATE",t.DOCUMENT__SEARCH="DOCUMENT__SEARCH",t.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",t.DOCUMENT__UNRATE="DOCUMENT__UNRATE",t.FEEDBACK__SEND="FEEDBACK__SEND",t.AI__COMPLETED_QUERY="AI__COMPLETED_QUERY",t.AI__RATE="AI__RATE",t.AI_CASE_DEFLECTION__START="AI_CASE_DEFLECTION__START",t.AI_CASE_DEFLECTION__OPEN_TICKET="AI_CASE_DEFLECTION__OPEN_TICKET",t.KHUB__PROCESS="KHUB__PROCESS",t.KHUB__SEARCH="KHUB__SEARCH",t.LABELS__DOWNLOAD="LABELS__DOWNLOAD",t.LINK__SHARE="LINK__SHARE",t.PAGE__DISPLAY="PAGE__DISPLAY",t.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",t.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",t.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",t.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",t.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",t.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",t.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",t.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",t.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",t.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",t.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",t.TOPIC__AI_TRANSLATE="TOPIC__AI_TRANSLATE",t.TOPIC__RATE="TOPIC__RATE",t.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",t.TOPIC__UNRATE="TOPIC__UNRATE",t.USER__LOGIN="USER__LOGIN",t.USER__LOGOUT="USER__LOGOUT",t.HEARTBEAT="HEARTBEAT"})(ne||(ne={}));var Rr;(function(t){t.STANDARD="STANDARD",t.STRUCTURAL="STRUCTURAL"})(Rr||(Rr={}));var _r;(function(t){t.THIRD_PARTY="THIRD_PARTY",t.OFF_THE_GRID="OFF_THE_GRID",t.CONTENT_PACKAGER="CONTENT_PACKAGER",t.PAGES="PAGES",t.DESIGNED_READER="DESIGNED_READER"})(_r||(_r={}));var Ir;(function(t){t.HOMEPAGE="HOMEPAGE",t.CUSTOM="CUSTOM",t.HEADER="HEADER",t.READER="READER",t.TOPIC_TEMPLATE="TOPIC_TEMPLATE",t.SEARCH="SEARCH",t.SEARCH_RESULT="SEARCH_RESULT",t.SEARCH_ANNOUNCEMENT="SEARCH_ANNOUNCEMENT",t.LINK_PREVIEW="LINK_PREVIEW",t.UD_VIEWER="UD_VIEWER",t.ASSET_VIEWER="ASSET_VIEWER"})(Ir||(Ir={}));var kr;(function(t){t.CLASSIC="CLASSIC",t.CUSTOM="CUSTOM",t.DESIGNER="DESIGNER"})(kr||(kr={}));var Lr;(function(t){t.AND="AND",t.OR="OR",t.MONOVALUED="MONOVALUED"})(Lr||(Lr={}));var Mr;(function(t){t.NONE="NONE",t.ALPHABET="ALPHABET",t.VERSION="VERSION"})(Mr||(Mr={}));var Dr;(function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"})(Dr||(Dr={}));var Pr;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"})(Pr||(Pr={}));var Ke;(function(t){t.OPTIONAL="OPTIONAL",t.MANDATORY="MANDATORY"})(Ke||(Ke={}));var Nr;(function(t){t.ASC="ASC",t.DESC="DESC"})(Nr||(Nr={}));var Ur;(function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"})(Ur||(Ur={}));var me;(function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"})(me||(me={}));var Fr;(function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(Fr||(Fr={}));var jr;(function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"})(jr||(jr={}));var Br;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(Br||(Br={}));var qr;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(qr||(qr={}));var H;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.HTML_PACKAGE="HTML_PACKAGE",t.HTML_PACKAGE_PAGE="HTML_PACKAGE_PAGE"})(H||(H={}));var ve;(function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS",t.ALL_TOPICS="ALL_TOPICS",t.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(ve||(ve={}));var Hr;(function(t){t.PLAIN_TEXT="PLAIN_TEXT",t.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",t.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(Hr||(Hr={}));var T;(function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.GENERATIVE_AI_USER="GENERATIVE_AI_USER",t.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_USER",t.ANNOUNCEMENT_ADMIN="ANNOUNCEMENT_ADMIN",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN"})(T||(T={}));var U;(function(t){t.SEARCHES="SEARCHES",t.BOOKMARKS="BOOKMARKS",t.BOOKS="BOOKS",t.COLLECTIONS="COLLECTIONS"})(U||(U={}));var Vr;(function(t){t.UNAUTHENTICATED="UNAUTHENTICATED",t.USER_INCOMPLETE="USER_INCOMPLETE",t.MFA_REQUIRED="MFA_REQUIRED",t.AUTHENTICATED="AUTHENTICATED"})(Vr||(Vr={}));var Kr;(function(t){t.UNREACHABLE="UNREACHABLE",t.UNAUTHORIZED="UNAUTHORIZED",t.FORBIDDEN="FORBIDDEN",t.INCOMPATIBLE="INCOMPATIBLE",t.FAILED="FAILED",t.OK="OK"})(Kr||(Kr={}));var Gr;(function(t){t.VALID="VALID",t.INVALID="INVALID"})(Gr||(Gr={}));var $r;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SUMMARY="SUMMARY",t.SEMANTIC_SEARCH="SEMANTIC_SEARCH",t.CHATBOT_INSTRUCTIONS="CHATBOT_INSTRUCTIONS",t.DOCUMENTATION="DOCUMENTATION",t.OTHER="OTHER"})($r||($r={}));var zr;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SLOW="SLOW",t.OTHER="OTHER"})(zr||(zr={}));var Wr;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(Wr||(Wr={}));var Qr;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(Qr||(Qr={}));var Yr;(function(t){t.TEXT="TEXT",t.HTML="HTML"})(Yr||(Yr={}));var Xr;(function(t){t.IN_PROGRESS="IN_PROGRESS",t.ERROR="ERROR",t.DONE="DONE"})(Xr||(Xr={}));var Jr;(function(t){t.HTML="HTML",t.MARKDOWN="MARKDOWN"})(Jr||(Jr={}));var Zr;(function(t){t.SOURCES="SOURCES",t.ENRICH_AND_CLEAN="ENRICH_AND_CLEAN",t.VOCABULARIES="VOCABULARIES",t.METADATA="METADATA",t.PRETTY_URL="PRETTY_URL",t.ACCESS_RULE="ACCESS_RULE",t.DESIGNED_PAGES="DESIGNED_PAGES",t.THEME_STUDIO="THEME_STUDIO",t.PORTAL_GENERAL="PORTAL_GENERAL",t.ASSETS="ASSETS",t.CODE_LIBRARY="CODE_LIBRARY",t.THEME="THEME",t.CONTENT_STYLES="CONTENT_STYLES",t.HOMEPAGE="HOMEPAGE",t.CLASSIC_SEARCH_PAGE="CLASSIC_SEARCH_PAGE",t.CLASSIC_READER_PAGE="CLASSIC_READER_PAGE",t.PORTAL_METADATA="PORTAL_METADATA",t.LANGUAGES="LANGUAGES",t.PRINT_TEMPLATES="PRINT_TEMPLATES",t.OFFLINE="OFFLINE",t.CUSTOM_JS="CUSTOM_JS",t.CONFIDENTIALITY="CONFIDENTIALITY",t.NOTIFICATIONS="NOTIFICATIONS"})(Zr||(Zr={}));var en;(function(t){t.MAP="MAP",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT"})(en||(en={}));var xs={[T.PERSONAL_BOOK_SHARE_USER]:[T.PERSONAL_BOOK_USER],[T.HTML_EXPORT_USER]:[T.PERSONAL_BOOK_USER],[T.PDF_EXPORT_USER]:[T.PERSONAL_BOOK_USER],[T.KHUB_ADMIN]:[T.CONTENT_PUBLISHER],[T.ADMIN]:[T.KHUB_ADMIN,T.USERS_ADMIN,T.PORTAL_ADMIN,T.BEHAVIOR_DATA_USER],[T.GENERATIVE_AI_EXPORT_USER]:[T.GENERATIVE_AI_USER]};function tn(t,e){return t===e||(xs[t]??[]).some(r=>tn(r,e))}function rn(t,e){return t==null?!1:(Array.isArray(t)?t:Array.isArray(t.roles)?t.roles:Array.isArray(t.profile?.roles)?t.profile.roles:[]).some(n=>tn(n,e))}var Xt=E(Y());var nn=E(Y(),1);var Tt=t=>e=>{window.customElements.get(t)||window.customElements.define(t,e)};function sn(t,e){return(0,nn.property)({type:Object,converter:{fromAttribute:r=>{if(r==null)return Le(t);try{return JSON.parse(r)}catch{return Le(t)}},toAttribute:r=>JSON.stringify(r)},hasChanged:Me,...e??{}})}function Os(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;let r,n;if(Array.isArray(t)){if(r=t.length,r!=e.length)return!1;for(n=r;n--!==0;)if(!Ge(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(!Ge(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 s=a=>Object.keys(a).filter(o=>a[o]!=null),i=s(t);if(r=i.length,r!==s(e).length)return!1;for(n=r;n--!==0;)if(!Object.prototype.hasOwnProperty.call(e,i[n]))return!1;for(n=r;n--!==0;){let a=i[n];if(!Ge(t[a],e[a]))return!1}return!0}return t!==t&&e!==e||t==null&&e==null}function Ge(t,e){try{return Os(t,e)}catch{return!1}}function Me(t,e){return!Ge(t,e)}function Le(t){return typeof window.structuredClone=="function"?structuredClone(t):t!=null?JSON.parse(JSON.stringify(t)):t}function $e(t,e){let r=n=>n[t]===!0;return n=>{if(r(n))return n;let s=e(n);return s[t]=!0,s}}var an=E(Y(),1);var wt=t=>{let e=t??{};return(r,n)=>{var s;let i={hasChanged:Me,attribute:!1,...e};(0,an.property)(i)(r,n);let a=r.constructor;a.reduxProperties=new Map(a.reduxProperties),a.reduxProperties.set(n,{selector:(s=e.selector)!==null&&s!==void 0?s:(o=>o[n]),store:e.store})}};var ze=class{constructor(){this.queue=[]}add(e,r=!1){r&&this.clear(e.type),this.queue.push(e)}consume(e){let r=this.queue.find(n=>n.type===e);return r&&(this.queue=this.queue.filter(n=>n!==r)),r}clear(e){typeof e=="string"?this.queue=this.queue.filter(r=>r.type!==e):this.queue=this.queue.filter(r=>!e.test(r.type))}};var se=E(Y(),1);var We=class{constructor(e=0){this.timeout=e,this.callbacks=[]}run(e,r){return this.callbacks=[e],this.debounce(r)}queue(e,r){return this.callbacks.push(e),this.debounce(r)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(e){return this.promise==null&&(this.promise=new Promise((r,n)=>{this.resolvePromise=r,this.rejectPromise=n})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),e??this.timeout),this.promise}async runCallbacks(){var e,r;let n=[...this.callbacks];this.callbacks=[];let s=(e=this.rejectPromise)!==null&&e!==void 0?e:(()=>null),i=(r=this.resolvePromise)!==null&&r!==void 0?r:(()=>null);this.clearPromise();for(let a of n)try{await a()}catch(o){s(o);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 un=E(fe(),1);var Qe=globalThis,Ts=Qe.ShadowRoot&&(Qe.ShadyCSS===void 0||Qe.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype;var on=(t,e)=>{if(Ts)t.adoptedStyleSheets=e.map((r=>r instanceof CSSStyleSheet?r:r.styleSheet));else for(let r of e){let n=document.createElement("style"),s=Qe.litNonce;s!==void 0&&n.setAttribute("nonce",s),n.textContent=r.cssText,t.appendChild(n)}};var Ye=class extends un.LitElement{get scopedRegistryConstructor(){return this.constructor}createRenderRoot(){let e=this.scopedRegistryConstructor;e.elementDefinitions&&!e.registry&&(e.registry=new CustomElementRegistry,e.defineScopedElements(e.elementDefinitions));let r={...e.shadowRootOptions,customElements:e.registry},n=this.renderOptions.creationScope=this.attachShadow(r);return on(n,e.elementStyles),n}static canDefineScopedElement(e){return!!this.registry&&!this.registry.get(e)}static defineScopedElements(e){Object.entries(e).forEach(([r,n])=>this.defineScopedElement(r,n))}static defineScopedElement(e,r){Tt(e)(r),this.canDefineScopedElement(e)&&this.registry.define(e,r)}canDefineScopedElement(e){return this.scopedRegistryConstructor.canDefineScopedElement(e)}defineScopedElements(e){this.scopedRegistryConstructor.defineScopedElements(e)}defineScopedElement(e,r){this.scopedRegistryConstructor.defineScopedElement(e,r)}};function cn(t,e,...r){var n;let s=t.querySelector(e);for(let i of r)s=(n=s?.shadowRoot)===null||n===void 0?void 0:n.querySelector(i);return s}var ge=function(t,e,r,n){var s=arguments.length,i=s<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,n);else for(var o=t.length-1;o>=0;o--)(a=t[o])&&(i=(s<3?a(i):s>3?a(e,r,i):a(e,r))||i);return s>3&&i&&Object.defineProperty(e,r,i),i},pn,ln=Symbol("constructorPrototype"),dn=Symbol("constructorName"),fn=Symbol("exportpartsDebouncer"),hn=Symbol("dynamicDependenciesLoaded"),ye=class t extends CustomEvent{constructor(){super(t.eventName,{bubbles:!0})}};ye.eventName="exportparts-updated";var V=class extends Ye{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[pn]=new We(5),this.scheduleExportpartsUpdate=()=>{var e,r,n;(!((e=this.exportpartsPrefix)===null||e===void 0)&&e.trim()||(n=(r=this.exportpartsPrefixes)===null||r===void 0?void 0:r.length)!==null&&n!==void 0&&n)&&this[fn].run(()=>{var s,i;!((s=this.exportpartsPrefix)===null||s===void 0)&&s.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((i=this.exportpartsPrefixes)===null||i===void 0?void 0:i.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})},this[dn]=this.constructor.name,this[ln]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[dn]&&Object.setPrototypeOf(this,this[ln])}connectedCallback(){var e;super.connectedCallback();try{this.shadowRoot&&!this.shadowRoot.adoptedStyleSheets.includes(this.adoptedCustomStyleSheet)&&(this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,this.adoptedCustomStyleSheet]),this.useAdoptedStyleSheets=!0}catch(n){this.useAdoptedStyleSheets=!1,console.error("Cannot use adopted stylesheets",n)}let r=this.constructor;r[hn]||(r[hn]=!0,this.importDynamicDependencies()),(e=this.shadowRoot)===null||e===void 0||e.addEventListener(ye.eventName,this.scheduleExportpartsUpdate)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.shadowRoot)===null||e===void 0||e.removeEventListener(ye.eventName,this.scheduleExportpartsUpdate)}importDynamicDependencies(){}updated(e){super.updated(e),this.updateComplete.then(()=>{this.contentAvailableCallback(e),this.focusElementToFocus(e),this.applyCustomStylesheet(e),this.scheduleExportpartsUpdate(),e.has("exportparts")&&this.dispatchEvent(new ye)})}contentAvailableCallback(e){}focusElementToFocus(e){if(e.has("elementToFocus")&&this.elementToFocus!=null){let{element:r,selector:n,shadowPath:s}=this.elementToFocus;if(n!=null){let i=[...s??[],n];r=cn(this.shadowRoot,...i)}r?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||r?.blur(),this.elementToFocus=void 0}}applyCustomStylesheet(e){var r,n,s;if(((n=(r=this.shadowRoot)===null||r===void 0?void 0:r.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((s=this.customStylesheet)!==null&&s!==void 0?s:"")}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)}}setExportpartsAttribute(e){var r,n,s,i,a,o;let c=d=>d!=null&&d.trim().length>0,u=e.filter(c).map(d=>d.trim());if(u.length===0){this.exportparts=void 0;return}let l=new Set;for(let d of(n=(r=this.shadowRoot)===null||r===void 0?void 0:r.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let m=(i=(s=d.getAttribute("part"))===null||s===void 0?void 0:s.split(" "))!==null&&i!==void 0?i:[],p=(o=(a=d.getAttribute("exportparts"))===null||a===void 0?void 0:a.split(",").map(y=>y.split(":")[1]))!==null&&o!==void 0?o:[],f=[...m,...p].filter(c).map(y=>y.trim());for(let y of f)l.add(y)}if(l.size===0){this.exportparts=void 0;return}let h=[...l.values()].flatMap(d=>u.map(m=>`${d}:${m}--${d}`));this.exportparts=[...this.part,...h].join(", ")}};pn=fn;ge([(0,se.property)()],V.prototype,"exportpartsPrefix",void 0);ge([sn([])],V.prototype,"exportpartsPrefixes",void 0);ge([(0,se.property)({reflect:!0})],V.prototype,"exportparts",void 0);ge([(0,se.property)()],V.prototype,"customStylesheet",void 0);ge([(0,se.property)()],V.prototype,"elementToFocus",void 0);ge([(0,se.state)()],V.prototype,"useAdoptedStyleSheets",void 0);function Xe(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var De=Symbol("internalReduxEventsUnsubscribers"),J=Symbol("internalStoresUnsubscribers"),ie=Symbol("internalStores"),ws=$e(Symbol("withRedux"),function(t){var e,r,n;class s extends t{constructor(){super(...arguments),this[e]=new Map,this[r]=new Map,this[n]=new Map}get reduxConstructor(){return this.constructor}willUpdate(a){super.willUpdate(a),[...this.reduxConstructor.reduxReactiveProperties].some(o=>a.has(o))&&this.updateFromStores()}getUnnamedStore(){if(this[ie].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[ie].values()][0]}getStore(a){return a==null?this.getUnnamedStore():this[ie].get(a)}addStore(a,o){var c;o=(c=o??a.name)!==null&&c!==void 0?c:"default-store",this.unsubscribeFromStore(o),this[ie].set(o,a),this.subscribeToStore(o,a),this.updateFromStores()}removeStore(a){let o=typeof a=="string"?a:a.name;this.unsubscribeFromStore(o),this[ie].delete(o)}setupStores(){this.unsubscribeFromStores(),this[ie].forEach((a,o)=>this.subscribeToStore(o,a)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((a,o)=>{let c=this.constructor.getPropertyOptions(o);if(!c?.attribute||!this.hasAttribute(typeof c?.attribute=="string"?c.attribute:o)){let u=this.getStore(a.store);u&&(a.store?this[J].has(a.store):this[J].size>0)&&(this[o]=a.selector(u.getState(),this))}})}subscribeToStore(a,o){var c;this[J].set(a,o.subscribe(()=>this.updateFromStores())),this[De].set(a,[]),Xe(o)&&o.eventBus&&((c=this.reduxConstructor.reduxEventListeners)===null||c===void 0||c.forEach((u,l)=>{if(typeof this[l]=="function"&&(!u.store||o.name===u.store)){let h=d=>this[l](d);o.addEventListener(u.eventName,h),this[De].get(a).push(()=>o.removeEventListener(u.eventName,h))}})),this.onStoreAvailable(a)}unsubscribeFromStores(){this[J].forEach((a,o)=>this.unsubscribeFromStore(o))}unsubscribeFromStore(a){var o;this[J].has(a)&&this[J].get(a)(),this[J].delete(a),(o=this[De].get(a))===null||o===void 0||o.forEach(c=>c()),this[De].delete(a)}onStoreAvailable(a){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return e=J,r=ie,n=De,s.reduxProperties=new Map,s.reduxReactiveProperties=new Set,s.reduxEventListeners=new Map,s}),mn=class extends ws(V){};function F(t){for(var e=arguments.length,r=Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];if(0)var s,i;throw Error("[Immer] minified error nr: "+t+(r.length?" "+r.map((function(a){return"'"+a+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function z(t){return!!t&&!!t[C]}function q(t){var e;return!!t&&((function(r){if(!r||typeof r!="object")return!1;var n=Object.getPrototypeOf(r);if(n===null)return!0;var s=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return s===Object||typeof s=="function"&&Function.toString.call(s)===Ps})(t)||Array.isArray(t)||!!t[An]||!!(!((e=t.constructor)===null||e===void 0)&&e[An])||Nt(t)||Ut(t))}function ae(t,e,r){r===void 0&&(r=!1),be(t)===0?(r?Object.keys:Ee)(t).forEach((function(n){r&&typeof n=="symbol"||e(n,t[n],t)})):t.forEach((function(n,s){return e(s,n,t)}))}function be(t){var e=t[C];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:Nt(t)?2:Ut(t)?3:0}function Se(t,e){return be(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function Rs(t,e){return be(t)===2?t.get(e):t[e]}function Cn(t,e,r){var n=be(t);n===2?t.set(e,r):n===3?t.add(r):t[e]=r}function xn(t,e){return t===e?t!==0||1/t==1/e:t!=t&&e!=e}function Nt(t){return Ms&&t instanceof Map}function Ut(t){return Ds&&t instanceof Set}function Z(t){return t.o||t.t}function Ft(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=wn(t);delete e[C];for(var r=Ee(e),n=0;n<r.length;n++){var s=r[n],i=e[s];i.writable===!1&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(e[s]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[s]})}return Object.create(Object.getPrototypeOf(t),e)}function jt(t,e){return e===void 0&&(e=!1),Bt(t)||z(t)||!q(t)||(be(t)>1&&(t.set=t.add=t.clear=t.delete=_s),Object.freeze(t),e&&ae(t,(function(r,n){return jt(n,!0)}),!0)),t}function _s(){F(2)}function Bt(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function K(t){var e=Pt[t];return e||F(18,t),e}function Is(t,e){Pt[t]||(Pt[t]=e)}function Lt(){return Ne}function Rt(t,e){e&&(K("Patches"),t.u=[],t.s=[],t.v=e)}function Je(t){Mt(t),t.p.forEach(ks),t.p=null}function Mt(t){t===Ne&&(Ne=t.l)}function vn(t){return Ne={p:[],l:Ne,h:t,m:!0,_:0}}function ks(t){var e=t[C];e.i===0||e.i===1?e.j():e.g=!0}function _t(t,e){e._=e.p.length;var r=e.p[0],n=t!==void 0&&t!==r;return e.h.O||K("ES5").S(e,t,n),n?(r[C].P&&(Je(e),F(4)),q(t)&&(t=Ze(e,t),e.l||et(e,t)),e.u&&K("Patches").M(r[C].t,t,e.u,e.s)):t=Ze(e,r,[]),Je(e),e.u&&e.v(e.u,e.s),t!==Tn?t:void 0}function Ze(t,e,r){if(Bt(e))return e;var n=e[C];if(!n)return ae(e,(function(o,c){return yn(t,n,e,o,c,r)}),!0),e;if(n.A!==t)return e;if(!n.P)return et(t,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var s=n.i===4||n.i===5?n.o=Ft(n.k):n.o,i=s,a=!1;n.i===3&&(i=new Set(s),s.clear(),a=!0),ae(i,(function(o,c){return yn(t,n,s,o,c,r,a)})),et(t,s,!1),r&&t.u&&K("Patches").N(n,r,t.u,t.s)}return n.o}function yn(t,e,r,n,s,i,a){if(z(s)){var o=Ze(t,s,i&&e&&e.i!==3&&!Se(e.R,n)?i.concat(n):void 0);if(Cn(r,n,o),!z(o))return;t.m=!1}else a&&r.add(s);if(q(s)&&!Bt(s)){if(!t.h.D&&t._<1)return;Ze(t,s),e&&e.A.l||et(t,s)}}function et(t,e,r){r===void 0&&(r=!1),!t.l&&t.h.D&&t.m&&jt(e,r)}function It(t,e){var r=t[C];return(r?Z(r):t)[e]}function gn(t,e){if(e in t)for(var r=Object.getPrototypeOf(t);r;){var n=Object.getOwnPropertyDescriptor(r,e);if(n)return n;r=Object.getPrototypeOf(r)}}function ee(t){t.P||(t.P=!0,t.l&&ee(t.l))}function kt(t){t.o||(t.o=Ft(t.t))}function Dt(t,e,r){var n=Nt(e)?K("MapSet").F(e,r):Ut(e)?K("MapSet").T(e,r):t.O?(function(s,i){var a=Array.isArray(s),o={i:a?1:0,A:i?i.A:Lt(),P:!1,I:!1,R:{},l:i,t:s,k:null,o:null,j:null,C:!1},c=o,u=Ue;a&&(c=[o],u=Pe);var l=Proxy.revocable(c,u),h=l.revoke,d=l.proxy;return o.k=d,o.j=h,d})(e,r):K("ES5").J(e,r);return(r?r.A:Lt()).p.push(n),n}function Ls(t){return z(t)||F(22,t),(function e(r){if(!q(r))return r;var n,s=r[C],i=be(r);if(s){if(!s.P&&(s.i<4||!K("ES5").K(s)))return s.t;s.I=!0,n=Sn(r,i),s.I=!1}else n=Sn(r,i);return ae(n,(function(a,o){s&&Rs(s.t,a)===o||Cn(n,a,e(o))})),i===3?new Set(n):n})(t)}function Sn(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return Ft(t)}function On(){function t(a,o){var c=i[a];return c?c.enumerable=o:i[a]=c={configurable:!0,enumerable:o,get:function(){var u=this[C];return Ue.get(u,a)},set:function(u){var l=this[C];Ue.set(l,a,u)}},c}function e(a){for(var o=a.length-1;o>=0;o--){var c=a[o][C];if(!c.P)switch(c.i){case 5:n(c)&&ee(c);break;case 4:r(c)&&ee(c)}}}function r(a){for(var o=a.t,c=a.k,u=Ee(c),l=u.length-1;l>=0;l--){var h=u[l];if(h!==C){var d=o[h];if(d===void 0&&!Se(o,h))return!0;var m=c[h],p=m&&m[C];if(p?p.t!==d:!xn(m,d))return!0}}var f=!!o[C];return u.length!==Ee(o).length+(f?0:1)}function n(a){var o=a.k;if(o.length!==a.t.length)return!0;var c=Object.getOwnPropertyDescriptor(o,o.length-1);if(c&&!c.get)return!0;for(var u=0;u<o.length;u++)if(!o.hasOwnProperty(u))return!0;return!1}function s(a){a.g&&F(3,JSON.stringify(Z(a)))}var i={};Is("ES5",{J:function(a,o){var c=Array.isArray(a),u=(function(h,d){if(h){for(var m=Array(d.length),p=0;p<d.length;p++)Object.defineProperty(m,""+p,t(p,!0));return m}var f=wn(d);delete f[C];for(var y=Ee(f),g=0;g<y.length;g++){var S=y[g];f[S]=t(S,h||!!f[S].enumerable)}return Object.create(Object.getPrototypeOf(d),f)})(c,a),l={i:c?5:4,A:o?o.A:Lt(),P:!1,I:!1,R:{},l:o,t:a,k:u,o:null,g:!1,C:!1};return Object.defineProperty(u,C,{value:l,writable:!0}),u},S:function(a,o,c){c?z(o)&&o[C].A===a&&e(a.p):(a.u&&(function u(l){if(l&&typeof l=="object"){var h=l[C];if(h){var d=h.t,m=h.k,p=h.R,f=h.i;if(f===4)ae(m,(function(b){b!==C&&(d[b]!==void 0||Se(d,b)?p[b]||u(m[b]):(p[b]=!0,ee(h)))})),ae(d,(function(b){m[b]!==void 0||Se(m,b)||(p[b]=!1,ee(h))}));else if(f===5){if(n(h)&&(ee(h),p.length=!0),m.length<d.length)for(var y=m.length;y<d.length;y++)p[y]=!1;else for(var g=d.length;g<m.length;g++)p[g]=!0;for(var S=Math.min(m.length,d.length),x=0;x<S;x++)m.hasOwnProperty(x)||(p[x]=!0),p[x]===void 0&&u(m[x])}}}})(a.p[0]),e(a.p))},K:function(a){return a.i===4?r(a):n(a)}})}var En,Ne,qt=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",Ms=typeof Map<"u",Ds=typeof Set<"u",bn=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",Tn=qt?Symbol.for("immer-nothing"):((En={})["immer-nothing"]=!0,En),An=qt?Symbol.for("immer-draftable"):"__$immer_draftable",C=qt?Symbol.for("immer-state"):"__$immer_state";var Ps=""+Object.prototype.constructor,Ee=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,wn=Object.getOwnPropertyDescriptors||function(t){var e={};return Ee(t).forEach((function(r){e[r]=Object.getOwnPropertyDescriptor(t,r)})),e},Pt={},Ue={get:function(t,e){if(e===C)return t;var r=Z(t);if(!Se(r,e))return(function(s,i,a){var o,c=gn(i,a);return c?"value"in c?c.value:(o=c.get)===null||o===void 0?void 0:o.call(s.k):void 0})(t,r,e);var n=r[e];return t.I||!q(n)?n:n===It(t.t,e)?(kt(t),t.o[e]=Dt(t.A.h,n,t)):n},has:function(t,e){return e in Z(t)},ownKeys:function(t){return Reflect.ownKeys(Z(t))},set:function(t,e,r){var n=gn(Z(t),e);if(n?.set)return n.set.call(t.k,r),!0;if(!t.P){var s=It(Z(t),e),i=s?.[C];if(i&&i.t===r)return t.o[e]=r,t.R[e]=!1,!0;if(xn(r,s)&&(r!==void 0||Se(t.t,e)))return!0;kt(t),ee(t)}return t.o[e]===r&&(r!==void 0||e in t.o)||Number.isNaN(r)&&Number.isNaN(t.o[e])||(t.o[e]=r,t.R[e]=!0),!0},deleteProperty:function(t,e){return It(t.t,e)!==void 0||e in t.t?(t.R[e]=!1,kt(t),ee(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var r=Z(t),n=Reflect.getOwnPropertyDescriptor(r,e);return n&&{writable:!0,configurable:t.i!==1||e!=="length",enumerable:n.enumerable,value:r[e]}},defineProperty:function(){F(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){F(12)}},Pe={};ae(Ue,(function(t,e){Pe[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}})),Pe.deleteProperty=function(t,e){return Pe.set.call(this,t,e,void 0)},Pe.set=function(t,e,r){return Ue.set.call(this,t[0],e,r,t[0])};var Ns=(function(){function t(r){var n=this;this.O=bn,this.D=!0,this.produce=function(s,i,a){if(typeof s=="function"&&typeof i!="function"){var o=i;i=s;var c=n;return function(f){var y=this;f===void 0&&(f=o);for(var g=arguments.length,S=Array(g>1?g-1:0),x=1;x<g;x++)S[x-1]=arguments[x];return c.produce(f,(function(b){var Q;return(Q=i).call.apply(Q,[y,b].concat(S))}))}}var u;if(typeof i!="function"&&F(6),a!==void 0&&typeof a!="function"&&F(7),q(s)){var l=vn(n),h=Dt(n,s,void 0),d=!0;try{u=i(h),d=!1}finally{d?Je(l):Mt(l)}return typeof Promise<"u"&&u instanceof Promise?u.then((function(f){return Rt(l,a),_t(f,l)}),(function(f){throw Je(l),f})):(Rt(l,a),_t(u,l))}if(!s||typeof s!="object"){if((u=i(s))===void 0&&(u=s),u===Tn&&(u=void 0),n.D&&jt(u,!0),a){var m=[],p=[];K("Patches").M(s,u,m,p),a(m,p)}return u}F(21,s)},this.produceWithPatches=function(s,i){if(typeof s=="function")return function(u){for(var l=arguments.length,h=Array(l>1?l-1:0),d=1;d<l;d++)h[d-1]=arguments[d];return n.produceWithPatches(u,(function(m){return s.apply(void 0,[m].concat(h))}))};var a,o,c=n.produce(s,i,(function(u,l){a=u,o=l}));return typeof Promise<"u"&&c instanceof Promise?c.then((function(u){return[u,a,o]})):[c,a,o]},typeof r?.useProxies=="boolean"&&this.setUseProxies(r.useProxies),typeof r?.autoFreeze=="boolean"&&this.setAutoFreeze(r.autoFreeze)}var e=t.prototype;return e.createDraft=function(r){q(r)||F(8),z(r)&&(r=Ls(r));var n=vn(this),s=Dt(this,r,void 0);return s[C].C=!0,Mt(n),s},e.finishDraft=function(r,n){var s=r&&r[C],i=s.A;return Rt(i,n),_t(void 0,i)},e.setAutoFreeze=function(r){this.D=r},e.setUseProxies=function(r){r&&!bn&&F(20),this.O=r},e.applyPatches=function(r,n){var s;for(s=n.length-1;s>=0;s--){var i=n[s];if(i.path.length===0&&i.op==="replace"){r=i.value;break}}s>-1&&(n=n.slice(s+1));var a=K("Patches").$;return z(r)?a(r,n):this.produce(r,(function(o){return a(o,n)}))},t})(),P=new Ns,Us=P.produce,va=P.produceWithPatches.bind(P),ya=P.setAutoFreeze.bind(P),ga=P.setUseProxies.bind(P),Sa=P.applyPatches.bind(P),Ea=P.createDraft.bind(P),ba=P.finishDraft.bind(P),tt=Us;function oe(t){"@babel/helpers - typeof";return oe=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},oe(t)}function Rn(t,e){if(oe(t)!="object"||!t)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var n=r.call(t,e||"default");if(oe(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function _n(t){var e=Rn(t,"string");return oe(e)=="symbol"?e:e+""}function In(t,e,r){return(e=_n(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function kn(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),r.push.apply(r,n)}return r}function Ht(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?kn(Object(r),!0).forEach(function(n){In(t,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):kn(Object(r)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(r,n))})}return t}function I(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}var Ln=(function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"})(),Vt=function(){return Math.random().toString(36).substring(7).split("").join(".")},rt={INIT:"@@redux/INIT"+Vt(),REPLACE:"@@redux/REPLACE"+Vt(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Vt()}};function Fs(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 Kt(t,e,r){var n;if(typeof e=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(I(0));if(typeof e=="function"&&typeof r>"u"&&(r=e,e=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(I(1));return r(Kt)(t,e)}if(typeof t!="function")throw new Error(I(2));var s=t,i=e,a=[],o=a,c=!1;function u(){o===a&&(o=a.slice())}function l(){if(c)throw new Error(I(3));return i}function h(f){if(typeof f!="function")throw new Error(I(4));if(c)throw new Error(I(5));var y=!0;return u(),o.push(f),function(){if(y){if(c)throw new Error(I(6));y=!1,u();var S=o.indexOf(f);o.splice(S,1),a=null}}}function d(f){if(!Fs(f))throw new Error(I(7));if(typeof f.type>"u")throw new Error(I(8));if(c)throw new Error(I(9));try{c=!0,i=s(i,f)}finally{c=!1}for(var y=a=o,g=0;g<y.length;g++){var S=y[g];S()}return f}function m(f){if(typeof f!="function")throw new Error(I(10));s=f,d({type:rt.REPLACE})}function p(){var f,y=h;return f={subscribe:function(S){if(typeof S!="object"||S===null)throw new Error(I(11));function x(){S.next&&S.next(l())}x();var b=y(x);return{unsubscribe:b}}},f[Ln]=function(){return this},f}return d({type:rt.INIT}),n={dispatch:d,subscribe:h,getState:l,replaceReducer:m},n[Ln]=p,n}function js(t){Object.keys(t).forEach(function(e){var r=t[e],n=r(void 0,{type:rt.INIT});if(typeof n>"u")throw new Error(I(12));if(typeof r(void 0,{type:rt.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(I(13))})}function Mn(t){for(var e=Object.keys(t),r={},n=0;n<e.length;n++){var s=e[n];typeof t[s]=="function"&&(r[s]=t[s])}var i=Object.keys(r),a,o;try{js(r)}catch(c){o=c}return function(u,l){if(u===void 0&&(u={}),o)throw o;if(0)var h;for(var d=!1,m={},p=0;p<i.length;p++){var f=i[p],y=r[f],g=u[f],S=y(g,l);if(typeof S>"u"){var x=l&&l.type;throw new Error(I(14))}m[f]=S,d=d||S!==g}return d=d||i.length!==Object.keys(u).length,d?m:u}}function Ae(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return e.length===0?function(n){return n}:e.length===1?e[0]:e.reduce(function(n,s){return function(){return n(s.apply(void 0,arguments))}})}function Dn(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return function(n){return function(){var s=n.apply(void 0,arguments),i=function(){throw new Error(I(15))},a={getState:s.getState,dispatch:function(){return i.apply(void 0,arguments)}},o=e.map(function(c){return c(a)});return i=Ae.apply(void 0,o)(s.dispatch),Ht(Ht({},s),{},{dispatch:i})}}}function Pn(t){var e=function(n){var s=n.dispatch,i=n.getState;return function(a){return function(o){return typeof o=="function"?o(s,i,t):a(o)}}};return e}var Nn=Pn();Nn.withExtraArgument=Pn;var Gt=Nn;var qn=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Bs=function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:o(0),throw:o(1),return:o(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function o(u){return function(l){return c([u,l])}}function c(u){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,s&&(i=u[0]&2?s.return:u[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,u[1])).done)return i;switch(s=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,s=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){r.label=u[1];break}if(u[0]===6&&r.label<i[1]){r.label=i[1],i=u;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(u);break}i[2]&&r.ops.pop(),r.trys.pop();continue}u=e.call(t,r)}catch(l){u=[6,l],s=0}finally{n=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Ce=function(t,e){for(var r=0,n=e.length,s=t.length;r<n;r++,s++)t[s]=e[r];return t},qs=Object.defineProperty,Hs=Object.defineProperties,Vs=Object.getOwnPropertyDescriptors,Un=Object.getOwnPropertySymbols,Ks=Object.prototype.hasOwnProperty,Gs=Object.prototype.propertyIsEnumerable,Fn=function(t,e,r){return e in t?qs(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r},te=function(t,e){for(var r in e||(e={}))Ks.call(e,r)&&Fn(t,r,e[r]);if(Un)for(var n=0,s=Un(e);n<s.length;n++){var r=s[n];Gs.call(e,r)&&Fn(t,r,e[r])}return t},$t=function(t,e){return Hs(t,Vs(e))},$s=function(t,e,r){return new Promise(function(n,s){var i=function(c){try{o(r.next(c))}catch(u){s(u)}},a=function(c){try{o(r.throw(c))}catch(u){s(u)}},o=function(c){return c.done?n(c.value):Promise.resolve(c.value).then(i,a)};o((r=r.apply(t,e)).next())})};var zs=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Ae:Ae.apply(null,arguments)},ja=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}};function Ws(t){if(typeof t!="object"||t===null)return!1;var e=Object.getPrototypeOf(t);if(e===null)return!0;for(var r=e;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return e===r}function re(t,e){function r(){for(var n=[],s=0;s<arguments.length;s++)n[s]=arguments[s];if(e){var i=e.apply(void 0,n);if(!i)throw new Error("prepareAction did not return an object");return te(te({type:t,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:t,payload:n[0]}}return r.toString=function(){return""+t},r.type=t,r.match=function(n){return n.type===t},r}var Qs=(function(t){qn(e,t);function e(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];var s=t.apply(this,r)||this;return Object.setPrototypeOf(s,e.prototype),s}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.prototype.concat.apply(this,r)},e.prototype.prepend=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return r.length===1&&Array.isArray(r[0])?new(e.bind.apply(e,Ce([void 0],r[0].concat(this)))):new(e.bind.apply(e,Ce([void 0],r.concat(this))))},e})(Array),Ys=(function(t){qn(e,t);function e(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];var s=t.apply(this,r)||this;return Object.setPrototypeOf(s,e.prototype),s}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.prototype.concat.apply(this,r)},e.prototype.prepend=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return r.length===1&&Array.isArray(r[0])?new(e.bind.apply(e,Ce([void 0],r[0].concat(this)))):new(e.bind.apply(e,Ce([void 0],r.concat(this))))},e})(Array);function Qt(t){return q(t)?tt(t,function(){}):t}function Xs(t){return typeof t=="boolean"}function Js(){return function(e){return Zs(e)}}function Zs(t){t===void 0&&(t={});var e=t.thunk,r=e===void 0?!0:e,n=t.immutableCheck,s=n===void 0?!0:n,i=t.serializableCheck,a=i===void 0?!0:i,o=t.actionCreatorCheck,c=o===void 0?!0:o,u=new Qs;if(r&&(Xs(r)?u.push(Gt):u.push(Gt.withExtraArgument(r.extraArgument))),0){if(s)var l;if(a)var h;if(c)var d}return u}var zt=!0;function Hn(t){var e=Js(),r=t||{},n=r.reducer,s=n===void 0?void 0:n,i=r.middleware,a=i===void 0?e():i,o=r.devTools,c=o===void 0?!0:o,u=r.preloadedState,l=u===void 0?void 0:u,h=r.enhancers,d=h===void 0?void 0:h,m;if(typeof s=="function")m=s;else if(Ws(s))m=Mn(s);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 p=a;if(typeof p=="function"&&(p=p(e),!zt&&!Array.isArray(p)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!zt&&p.some(function(b){return typeof b!="function"}))throw new Error("each middleware provided to configureStore must be a function");var f=Dn.apply(void 0,p),y=Ae;c&&(y=zs(te({trace:!zt},typeof c=="object"&&c)));var g=new Ys(f),S=g;Array.isArray(d)?S=Ce([f],d):typeof d=="function"&&(S=d(g));var x=y.apply(void 0,S);return Kt(m,l,x)}function Vn(t){var e={},r=[],n,s={addCase:function(i,a){var o=typeof i=="string"?i:i.type;if(!o)throw new Error("`builder.addCase` cannot be called with an empty action type");if(o in e)throw new Error("`builder.addCase` cannot be called with two reducers for the same action type");return e[o]=a,s},addMatcher:function(i,a){return r.push({matcher:i,reducer:a}),s},addDefaultCase:function(i){return n=i,s}};return t(s),[e,r,n]}function ei(t){return typeof t=="function"}function ti(t,e,r,n){r===void 0&&(r=[]);var s=typeof e=="function"?Vn(e):[e,r,n],i=s[0],a=s[1],o=s[2],c;if(ei(t))c=function(){return Qt(t())};else{var u=Qt(t);c=function(){return u}}function l(h,d){h===void 0&&(h=c());var m=Ce([i[d.type]],a.filter(function(p){var f=p.matcher;return f(d)}).map(function(p){var f=p.reducer;return f}));return m.filter(function(p){return!!p}).length===0&&(m=[o]),m.reduce(function(p,f){if(f)if(z(p)){var y=p,g=f(y,d);return g===void 0?p:g}else{if(q(p))return tt(p,function(S){return f(S,d)});var g=f(p,d);if(g===void 0){if(p===null)return p;throw Error("A case reducer on a non-draftable value must not return undefined")}return g}return p},h)}return l.getInitialState=c,l}function ri(t,e){return t+"/"+e}function Kn(t){var e=t.name;if(!e)throw new Error("`name` is a required option for createSlice");typeof process<"u";var r=typeof t.initialState=="function"?t.initialState:Qt(t.initialState),n=t.reducers||{},s=Object.keys(n),i={},a={},o={};s.forEach(function(l){var h=n[l],d=ri(e,l),m,p;"reducer"in h?(m=h.reducer,p=h.prepare):m=h,i[l]=m,a[d]=m,o[l]=p?re(d,p):re(d)});function c(){var l=typeof t.extraReducers=="function"?Vn(t.extraReducers):[t.extraReducers],h=l[0],d=h===void 0?{}:h,m=l[1],p=m===void 0?[]:m,f=l[2],y=f===void 0?void 0:f,g=te(te({},d),a);return ti(r,function(S){for(var x in g)S.addCase(x,g[x]);for(var b=0,Q=p;b<Q.length;b++){var $=Q[b];S.addMatcher($.matcher,$.reducer)}y&&S.addDefaultCase(y)})}var u;return{name:e,reducer:function(l,h){return u||(u=c()),u(l,h)},actions:o,caseReducers:i,getInitialState:function(){return u||(u=c()),u.getInitialState()}}}var ni="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",si=function(t){t===void 0&&(t=21);for(var e="",r=t;r--;)e+=ni[Math.random()*64|0];return e},ii=["name","message","stack","code"],Wt=(function(){function t(e,r){this.payload=e,this.meta=r}return t})(),jn=(function(){function t(e,r){this.payload=e,this.meta=r}return t})(),ai=function(t){if(typeof t=="object"&&t!==null){for(var e={},r=0,n=ii;r<n.length;r++){var s=n[r];typeof t[s]=="string"&&(e[s]=t[s])}return e}return{message:String(t)}},Va=(function(){function t(e,r,n){var s=re(e+"/fulfilled",function(l,h,d,m){return{payload:l,meta:$t(te({},m||{}),{arg:d,requestId:h,requestStatus:"fulfilled"})}}),i=re(e+"/pending",function(l,h,d){return{payload:void 0,meta:$t(te({},d||{}),{arg:h,requestId:l,requestStatus:"pending"})}}),a=re(e+"/rejected",function(l,h,d,m,p){return{payload:m,error:(n&&n.serializeError||ai)(l||"Rejected"),meta:$t(te({},p||{}),{arg:d,requestId:h,rejectedWithValue:!!m,requestStatus:"rejected",aborted:l?.name==="AbortError",condition:l?.name==="ConditionError"})}}),o=!1,c=typeof AbortController<"u"?AbortController:(function(){function l(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return l.prototype.abort=function(){},l})();function u(l){return function(h,d,m){var p=n?.idGenerator?n.idGenerator(l):si(),f=new c,y,g=!1;function S(b){y=b,f.abort()}var x=(function(){return $s(this,null,function(){var b,Q,$,Re,hr,_e,pr;return Bs(this,function(pe){switch(pe.label){case 0:return pe.trys.push([0,4,,5]),Re=(b=n?.condition)==null?void 0:b.call(n,l,{getState:d,extra:m}),ui(Re)?[4,Re]:[3,2];case 1:Re=pe.sent(),pe.label=2;case 2:if(Re===!1||f.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return g=!0,hr=new Promise(function(B,Ie){return f.signal.addEventListener("abort",function(){return Ie({name:"AbortError",message:y||"Aborted"})})}),h(i(p,l,(Q=n?.getPendingMeta)==null?void 0:Q.call(n,{requestId:p,arg:l},{getState:d,extra:m}))),[4,Promise.race([hr,Promise.resolve(r(l,{dispatch:h,getState:d,extra:m,requestId:p,signal:f.signal,abort:S,rejectWithValue:function(B,Ie){return new Wt(B,Ie)},fulfillWithValue:function(B,Ie){return new jn(B,Ie)}})).then(function(B){if(B instanceof Wt)throw B;return B instanceof jn?s(B.payload,p,l,B.meta):s(B,p,l)})])];case 3:return $=pe.sent(),[3,5];case 4:return _e=pe.sent(),$=_e instanceof Wt?a(null,p,l,_e.payload,_e.meta):a(_e,p,l),[3,5];case 5:return pr=n&&!n.dispatchConditionRejection&&a.match($)&&$.meta.condition,pr||h($),[2,$]}})})})();return Object.assign(x,{abort:S,requestId:p,arg:l,unwrap:function(){return x.then(oi)}})}}return Object.assign(u,{pending:i,rejected:a,fulfilled:s,typePrefix:e})}return t.withTypes=function(){return t},t})();function oi(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function ui(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var Gn="listener",$n="completed",zn="cancelled",Ka="task-"+zn,Ga="task-"+$n,$a=Gn+"-"+zn,za=Gn+"-"+$n;var Yt="listenerMiddleware";var Wa=re(Yt+"/add"),Qa=re(Yt+"/removeAll"),Ya=re(Yt+"/remove");var Bn,Xa=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(t){return(Bn||(Bn=Promise.resolve())).then(t).catch(function(e){return setTimeout(function(){throw e},0)})},ci=function(t){return function(e){setTimeout(e,t)}},Ja=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:ci(10);On();var li=$e(Symbol("withEventBus"),function(t,e){return class extends t{constructor(){super(...arguments),this.eventBus=e??document.createElement("span")}addEventListener(r,n,s){this.eventBus.addEventListener(r,n,s)}dispatchEvent(r){return this.eventBus.dispatchEvent(r)}removeEventListener(r,n,s){this.eventBus.removeEventListener(r,n,s)}}}),nt=class extends li(Object){};window.ftReduxStores||(window.ftReduxStores={});var Wn=class t extends nt{static get(e){var r;let n=typeof e=="string"?e:e.name,s=typeof e=="string"?void 0:e,i=window.ftReduxStores[n];if(Xe(i))return i;if(s==null)return;let a=Kn({...s,reducers:(r=s.reducers)!==null&&r!==void 0?r:{}}),o=Hn({reducer:(c,u)=>{if(u.type==="CLEAR_FT_REDUX_STORE"){let l=Le(a.getInitialState());for(let h of u.keeping)l[h]=(c??l)[h];return l}else if(typeof u.type=="string"&&u.type.startsWith("DEFAULT_VALUE_SETTER__"))return{...c,...u.overwrites};return a.reducer(c,u)}});return window.ftReduxStores[s.name]=new t(a,o,s.eventBus)}constructor(e,r,n){super(),this.reduxSlice=e,this.reduxStore=r,this.isFtReduxStore=!0,this.commands=new ze;let s=i=>i!=null?JSON.parse(JSON.stringify(i)):i;this.actions=new Proxy(this.reduxSlice.actions,{get:(i,a,o)=>{let c=a,u=i[c];return u?(...l)=>{let h=u(...l.map(s));return this.reduxStore.dispatch(h),h}:l=>{this.setState({[c]:s(l)})}}}),this.eventBus=n??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:[]})}clearKeeping(...e){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:e})}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 st=class{static format(e,r,n,s,i){return window.moment?window.moment(e).locale(r).format(this.getMomentDateFormat(n,s,!!i)):this.getIntlDateTime(e,r,n,s,!!i)}static getMomentDateFormat(e,r,n){return n?"LT":e?r?"lll":"ll":r?"L LT":"L"}static getIntlDateTime(e,r,n,s,i){let a=typeof e=="string"?new Date(e):e,o=new Intl.DateTimeFormat(r,{dateStyle:n?"medium":"short"}).format(a),c=new Intl.DateTimeFormat(r,{timeStyle:"short"}).format(a);return i?c:s?`${o} ${c}`:o}static getTimezoneAsString(){let e=n=>String(Math.floor(n)).padStart(2,"0"),r=new Date().getTimezoneOffset();return`${r<0?"+":"-"}${e(Math.abs(r)/60)}:${e(Math.abs(r)%60)}`}};var it=E(w()),di="ft-app-info",xe=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};xe.eventName="authentication-change";var Fe=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};Fe.eventName="ui-locale-changed";var hi={session:(t,e)=>{(0,it.deepEqual)(t.session,e.payload)||(t.session=e.payload,setTimeout(()=>v.dispatchEvent(new xe(e.payload)),0))}},v=it.FtReduxStore.get({name:di,reducers:hi,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],availableContentLocales:[],defaultLocales:void 0,searchInAllLanguagesAllowed:!1,searchLanguageSetsUiLanguage:!1,uiLanguageSetsSearchLanguage:!1,uiLanguageSetsReaderLanguage:!1,metadataConfiguration:void 0,privacyPolicyConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,session:void 0,openExternalDocumentInNewTab:!1,navigatorOnline:!0,forcedOffline:!1,authenticationRequired:!1}});var Qn=E(w()),at=function(t,e,r,n){var s=arguments.length,i=s<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,n);else for(var o=t.length-1;o>=0;o--)(a=t[o])&&(i=(s<3?a(i):s>3?a(e,r,i):a(e,r))||i);return s>3&&i&&Object.defineProperty(e,r,i),i},wo=(0,Qn.applyMixinOnce)(Symbol("withDateFormat"),function(t){class e extends t{constructor(...n){super(n),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(v)}dateFormatOptionsChanged(n){return n.has("metadataDescriptors")||n.has("useLongDateFormat")||n.has("useDateTimeFormat")||n.has("uiLocale")}getDateFormatter(n){var s,i;return((i=(s=this.metadataDescriptors.find(o=>o.key===n))===null||s===void 0?void 0:s.date)!==null&&i!==void 0?i:!1)?o=>st.format(o,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return at([(0,Xt.property)({type:Boolean})],e.prototype,"useLongDateFormat",void 0),at([(0,Xt.property)({type:Boolean})],e.prototype,"useDateTimeFormat",void 0),at([wt({store:v.name,selector:r=>{var n,s;return(s=(n=r.metadataConfiguration)===null||n===void 0?void 0:n.descriptors)!==null&&s!==void 0?s:[]}})],e.prototype,"metadataDescriptors",void 0),at([wt({store:v.name})],e.prototype,"uiLocale",void 0),e});var dt=E(w());var Jt=E(w());var ue=class t{static get(e){let{baseUrl:r,apiIntegrationIdentifier:n}=v.getState(),s=e??n;if(r&&s&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(r,s,!0)}static await(e){return new Promise(r=>{let n=t.get(e);if(n)r(n);else{let s=v.subscribe(()=>{n=t.get(e),n&&(s(),r(n))})}})}};var Oe=class{constructor(e){this.overrideApi=e}get api(){var e;return(e=this.overrideApi)!==null&&e!==void 0?e:ue.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):ue.await()}};var k=class extends Oe{constructor(e=!0,r){var n;super(r),this.sortObjectFields=(i,a)=>typeof a!="object"||a==null||Array.isArray(a)?a:Object.fromEntries(Object.entries(a).sort(([o],[c])=>o.localeCompare(c)));let s=this.constructor;s.commonCache=(n=s.commonCache)!==null&&n!==void 0?n:new Jt.CacheRegistry,this.cache=e?s.commonCache:new Jt.CacheRegistry}clearCache(){this.cache.clearAll()}hash(e){return String(Array.from(JSON.stringify(e,this.sortObjectFields)).reduce((r,n)=>0|31*r+n.charCodeAt(0),0))}};var ot=class extends k{async listMySearches(){let{session:e}=v.getState();return rn(e,T.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),300*1e3):[]}};var ut=class extends k{async listMyBookmarks(){let e=v.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),300*1e3):[]}};var ct=class extends k{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetCount(e){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${e}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(e){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${e}`),this.CACHE_DURATION)}isAuthenticated(){let e=v.getState().session;return!!e?.sessionAuthenticated}};var lt=class extends k{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let e=v.getState().session;return!!e?.sessionAuthenticated}};var pi="ft-user-assets",fi={setAssetCount:(t,e)=>{let{userAssetType:r,count:n}=e.payload.assetCount;t.assetCounts.allAsset[r]=n},clearAssetCount:t=>{Object.values(U).forEach(e=>{t.assetCounts.allAsset[e]=void 0})},setBookmarkCountByMap:(t,e)=>{let r=e.payload.mapId;t.assetCounts.bookmarkByMap[r]=e.payload.count},clearBookmarkCountByMap:t=>{t.assetCounts.bookmarkByMap={}},addAsset:(t,e)=>{let{assetType:r,mapId:n,asset:s}=e.payload;er(t,r,[...Zt(t,r),s]),Yn(t,r,1,n),Xn(t,s)},editAsset:(t,e)=>{let{assetType:r,asset:n}=e.payload;er(t,r,Zt(t,r).map(s=>s.id===n.id?n:s)),Xn(t,n)},removeAsset:(t,e)=>{let{assetType:r,mapId:n,assetId:s}=e.payload;er(t,r,Zt(t,r).filter(i=>i.id!==s)),Yn(t,r,-1,n)}},Jn={[U.SEARCHES]:"savedSearches",[U.BOOKMARKS]:"bookmarks",[U.BOOKS]:void 0,[U.COLLECTIONS]:void 0},Zt=(t,e)=>{var r;let n=Jn[e];return n?(r=t[n])!==null&&r!==void 0?r:[]:[]},er=(t,e,r)=>{let n=Jn[e];n&&(t[n]=r)},Yn=(t,e,r,n)=>{let s=t.assetCounts.allAsset[e];if(s!==void 0&&(t.assetCounts.allAsset[e]=Math.max(0,s+r),e===U.BOOKMARKS&&n)){let i=t.assetCounts.bookmarkByMap[n];t.assetCounts.bookmarkByMap[n]=Math.max(0,i+r)}},Xn=(t,e)=>{let r=t.assetLabels.map(s=>s.title),n=e.labels.filter(s=>!r.includes(s)).map(s=>({title:s}));t.assetLabels.push(...n)},M=dt.FtReduxStore.get({name:pi,reducers:fi,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(U).map(t=>[t,void 0])),bookmarkByMap:{}},assetLabels:[]}}),tr=class{constructor(e=new ct,r=new lt){this.assetCountsService=e,this.assetLabelsService=r,this.currentSession=v.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new ut,this.savedSearchesService=new ot,v.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:r}=v.getState();(0,dt.deepEqual)((e=this.currentSession)===null||e===void 0?void 0:e.profile,r?.profile)||(this.currentSession=r,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),M.actions.clearAssetCount(),M.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),M.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),M.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();M.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let e=await this.assetLabelsService.getUserAssetLabels();M.actions.assetLabels(e)}async loadAssetCount(e){let r=await this.assetCountsService.getUserAssetCount(e);r&&M.getState().assetCounts.allAsset[e]!==r.count&&M.actions.setAssetCount({assetCount:r})}async loadBookmarkByMapId(e){let r=await this.assetCountsService.getUserBookmarkCountByMap(e);r&&M.getState().assetCounts.bookmarkByMap[e]!==r.count&&M.actions.setBookmarkCountByMap({count:r.count,mapId:e})}async reloadAssetCount(e){this.assetCountsService.clearCache();let r=Object.keys(M.getState().assetCounts.bookmarkByMap).length!==0;e===U.BOOKMARKS&&r&&M.actions.clearBookmarkCountByMap(),M.getState().assetCounts.allAsset[e]!==void 0&&await this.loadAssetCount(e)}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var e;if(this.bookmarksAreUsed){let r=!((e=this.currentSession)===null||e===void 0)&&e.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;M.actions.bookmarks(r)}}},rr=new tr;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=rr);var nr=class{addCommand(e,r=!1){v.commands.add(e,r)}consumeCommand(e){return v.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new nr;var j=E(w());var Zn,Te=class extends CustomEvent{constructor(e){super("ft-i18n-context-loaded",{detail:e})}},mi=Symbol("clearAfterUnitTest"),ht=class extends(0,j.withEventBus)(k){constructor(e){super(),this.messageContextProvider=e,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[Zn]=()=>{this.defaultMessages={},this.cache=new j.CacheRegistry,this.listeners={}},this.currentUiLocale=v.getState().uiLocale,v.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:e}=v.getState();this.currentUiLocale!==e&&(this.currentUiLocale=e,this.cache.clearAll(),this.notifyAll())}addContext(e){let r=e.name.toLowerCase();this.cache.setFinal(r,e),this.notify(r)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(e,r){var n;if(e=e.toLowerCase(),r&&Object.keys(r).length>0){let s={...(n=this.defaultMessages[e])!==null&&n!==void 0?n:{},...r};(0,j.deepEqual)(this.defaultMessages[e],s)||(this.defaultMessages[e]=s,await this.notify(e))}return this.fetchContext(e)}resolveContext(e){var r,n;return this.fetchContext(e),(n=(r=this.cache.getNow(e))===null||r===void 0?void 0:r.messages)!==null&&n!==void 0?n:{}}resolveRawMessage(e,r){let n=e.toLowerCase();return this.resolveContext(n)[r]}resolveMessage(e,r,...n){var s;let i=e.toLowerCase(),a=this.resolveContext(i);return new j.ParametrizedLabelResolver((s=this.defaultMessages[i])!==null&&s!==void 0?s:{},a).resolve(r,...n)}async fetchContext(e){let r=!this.cache.has(e),n;try{n=await this.cache.get(e,()=>this.messageContextProvider(this.currentUiLocale,e)),r&&await this.notify(e)}catch(s){!(s instanceof j.CanceledPromiseError)&&r&&console.error(s)}return n}subscribe(e,r){var n;return e=e.toLowerCase(),this.listeners[e]=(n=this.listeners[e])!==null&&n!==void 0?n:new Set,this.listeners[e].add(r),()=>{var s;return(s=this.listeners[e])===null||s===void 0?void 0:s.delete(r)}}async notifyAll(){let e=Object.keys(this.listeners);document.body.dispatchEvent(new Te({loadedContexts:e})),this.dispatchEvent(new Te({loadedContexts:e})),await Promise.all(e.map(r=>this.notify(r,!1)))}async notify(e,r=!0){r&&(document.body.dispatchEvent(new Te({loadedContexts:[e]})),this.dispatchEvent(new Te({loadedContexts:[e]}))),this.listeners[e]!=null&&await Promise.all([...this.listeners[e].values()].map(n=>(0,j.delay)(0).then(()=>n()).catch(()=>null)))}};Zn=mi;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends ht{constructor(){super(async(t,e)=>(await this.awaitApi).getFluidTopicsMessageContext(t,e))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends ht{constructor(){super(async(t,e)=>(await this.awaitApi).getCustomMessageContext(t,e))}});var es=window.FluidTopicsI18nService,uu=window.FluidTopicsCustomI18nService;var ts=E(w()),sr=class{highlightHtml(e,r,n){(0,ts.highlightHtml)(e,r,n)}};window.FluidTopicsHighlightHtmlService=new sr;var rs=E(w());var ir=class{isDate(e){var r,n,s,i;return(i=(s=((n=(r=v.getState().metadataConfiguration)===null||r===void 0?void 0:r.descriptors)!==null&&n!==void 0?n:[]).find(o=>o.key===e))===null||s===void 0?void 0:s.date)!==null&&i!==void 0?i:!1}format(e,r){var n,s,i,a;if(e==null)return"";try{return rs.DateFormatter.format(e,(n=r?.locale)!==null&&n!==void 0?n:v.getState().uiLocale,(s=r?.longFormat)!==null&&s!==void 0?s:!1,(i=r?.withTime)!==null&&i!==void 0?i:!1,(a=r?.onlyTime)!==null&&a!==void 0?a:!1)}catch(o){throw console.error(`Date ${JSON.stringify(e)} is not valid`,o),o}}};window.FluidTopicsDateService=new ir;var ns=E(w());var je=class{static get(e,r){var n,s;let i=v.getState(),{lang:a,region:o}=(s=(n=i.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&s!==void 0?s:{lang:"en",region:"US"};return new ns.SearchPlaceConverter(i.baseUrl,e??20,i.searchInAllLanguagesAllowed,r??`${a}-${o}`)}};var pt=class extends k{async sendDocumentStartDisplayEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.start_display event")}async sendTopicStartDisplayEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send topic.start_display event")}async sendKhubSearchEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send khub.search event")}async sendDocumentSearchEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.search event")}async sendSearchPageSelectEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send search_page.select event")}async sendSearchResultOpenContextMenuEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send search_result.open_context_menu event")}async sendDocumentOnDemandTranslateEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.on_demand_translate event")}async sendTopicAiTranslateEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send topic.ai_translate event")}convertMapToAnalyticsDocument(e){let r;switch(e.editorialType){case"BOOK":r="STRUCTURED_DOCUMENT";break;case"SHARED_BOOK":r="SHARED_PERSONAL_BOOK";break;case"ARTICLE":r="RESOURCE";break;case"HTML_PACKAGE":r="HTML_PACKAGE";break;default:throw new TypeError("Unknown editorial type for map : "+e.editorialType)}return{id:e.id,title:e.title,type:r,metadata:e.metadata}}sortEventArrays(e){let r=Object.entries(e).map(([n,s])=>Array.isArray(s)?[n,s.map(i=>typeof i=="object"&&i!=null&&!Array.isArray(i)?this.sortEventArrays(i):i).sort((i,a)=>typeof i=="object"&&i!==null&&"key"in i?i.key.localeCompare(a.key):typeof i=="string"&&typeof a=="string"?i.localeCompare(a):String(i).localeCompare(String(a)))]:typeof s=="object"&&s!==null?[n,this.sortEventArrays(s)]:[n,s]);return Object.fromEntries(r)}sendEvents(e,r){let n="anything not undefined";return this.cache.get("analytics-event-"+this.hash(e),async()=>(await this.awaitApi).sendEvents(e).then(()=>n).catch(s=>(console.info(r),console.debug(s),n)),1e3)}};var ar=class{urlToSearchRequest(e){return je.get().parse(e)}searchRequestToUrl(e){return je.get().serialize(e)}};window.FluidTopicsUrlService=new ar;var W=E(w());var ce=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{currentItem:e}})}};ce.eventName="change";var or=class{itemName(e){return`fluid-topics-history-item-${e}`}get(e){let r=sessionStorage.getItem(this.itemName(e));return r?JSON.parse(r):void 0}set(e,r){sessionStorage.setItem(this.itemName(e),JSON.stringify(r))}},ss=new or;var ft=class t extends W.WithEventBus{static build(){return new t(window.history,ss,()=>window.location,!1)}constructor(e,r,n,s){var i,a;super(),this.history=e,this.historyStorage=r,this.windowLocation=n,this.states=[],this.realPushState=e.pushState,this.realReplaceState=e.replaceState,this.initialIndex=(a=(i=e.state)===null||i===void 0?void 0:i.index)!==null&&a!==void 0?a:e.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(s)}setCurrentState(e,r=!1){let n=r&&this.currentIndex===e.index-1;this.currentState={...this.buildCurrentState(),...e},this.currentIndex=this.currentState.index,this.states[this.currentIndex]=this.currentState,n&&(this.states=this.states.slice(0,this.currentIndex+1)),this.historyStorage.set(this.currentIndex,this.currentState),(0,W.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,window.location.href]),setTimeout(()=>this.dispatchEvent(new ce(this.currentItem())),0)}installProxies(){let e=r=>(n,s,[i,a,o])=>{let c=r(),u={...c===this.currentIndex?this.currentState:void 0,...i,index:c,href:typeof o=="string"?o:(o??this.windowLocation()).href};n.apply(s,[u,a,o]),this.setCurrentState(u,!0)};this.history.pushState=new Proxy(this.history.pushState,{apply:e(()=>this.currentIndex+1)}),this.history.replaceState=new Proxy(this.history.replaceState,{apply:e(()=>this.currentIndex)})}initEventListeners(){window.addEventListener("popstate",e=>this.setCurrentState(e.state)),document.querySelector("title")==null&&document.head.append(document.createElement("title")),new MutationObserver(()=>this.updateCurrentState({title:document.title})).observe(document.querySelector("title"),{subtree:!0,characterData:!0,childList:!0})}initData(e){for(let r=this.history.length-1;r>=0;r--)e?this.states[r]=this.historyStorage.get(r):setTimeout(()=>this.states[r]=this.historyStorage.get(r),this.history.length-r)}updateCurrentState(e){var r;let n={...this.buildCurrentState(),...e,index:this.currentIndex,title:(r=e?.title)!==null&&r!==void 0?r:this.currentState.title};this.setCurrentState(n)}addHistoryChangeListener(e){this.addEventListener(ce.eventName,e)}removeHistoryChangeListener(e){this.removeEventListener(ce.eventName,e)}currentItem(){return(0,W.deepCopy)(this.currentState)}back(){let e=this.previousDifferentMajorPosition();e>=0?this.history.go(e-this.currentIndex):this.currentIndex!==this.initialIndex?this.history.go(this.initialIndex-this.currentIndex):this.history.back()}backwardItem(){return(0,W.deepCopy)(this.states[this.previousDifferentMajorPosition()])}backwardItemMatching(e){let r=this.states.filter(n=>!!n).filter(n=>n.index<this.currentIndex).reverse();return(0,W.deepCopy)(r.find(n=>e(n)))}previousDifferentMajorPosition(){let e=this.currentIndex>0?this.currentIndex-1:0;for(;e>0&&!this.isDifferentMajorState(e);)e--;return e}forward(){let e=this.nextMajorPosition();e&&e<this.states.length?this.history.go(e-this.currentIndex):this.history.forward()}forwardItem(){let e=this.nextMajorPosition();if(e)return(0,W.deepCopy)(this.states[e])}nextMajorPosition(){let e=this.currentIndex;if(!(e>=this.states.length)){do e++;while(e<this.states.length&&!this.isDifferentMajorState(e));return this.getHigherPositionInTheSameState(e)}}getHigherPositionInTheSameState(e){var r;let n=(r=this.states[e])===null||r===void 0?void 0:r.majorStateId;if(!n)return e;let s=e,i=e+1;for(;this.states.length>i&&!this.isDifferentMajorState(i,n);)this.hasState(i)&&(s=i),i++;return s}buildCurrentState(){var e,r;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(r=(e=this.history.state)===null||e===void 0?void 0:e.title)!==null&&r!==void 0?r:document.title}}hasState(e){return this.states[e]!=null}isDifferentMajorState(e,r){var n;if(!this.hasState(e))return!1;let s=r??this.currentState.majorStateId,i=(n=this.states[e])===null||n===void 0?void 0:n.majorStateId;return i==null||i!=s}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=ft.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),backwardItemMatching:t=>window.FluidTopicsInternalHistoryService.backwardItemMatching(t),addHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(t),removeHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(t)});var is=E(fe());var as=is.css`
|
|
2
|
+
`;var we=E(w()),lr=E(Y());var ke;(function(t){t.CLUSTERED_SEARCH="CLUSTERED_SEARCH"})(ke||(ke={}));var R=E(w());var Er=E(w()),Cs={setRequest:(t,e)=>{t.request=e.payload}},br=t=>Er.FtReduxStore.get({name:"ft-search-"+t,initialState:{request:{query:"",clusterSortCriterions:[],metadataFilters:[],facets:[],sort:[],sortId:void 0,paging:{page:1,perPage:20},keywordMatch:void 0},liveQuery:"",recentQueries:[],paging:void 0,facets:void 0,spellcheck:void 0,locales:[],results:void 0,announcements:void 0,suggestResults:void 0,configuration:void 0},reducers:Cs});var Ar;(function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"})(Ar||(Ar={}));var Cr;(function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"})(Cr||(Cr={}));var xr;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(xr||(xr={}));var X;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(X||(X={}));var Or;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(Or||(Or={}));var Tr;(function(t){t.VALUE="VALUE",t.DATE="DATE",t.RANGE="RANGE"})(Tr||(Tr={}));var wr;(function(t){t.OFFICIAL="OFFICIAL",t.AI="AI"})(wr||(wr={}));var ne;(function(t){t.BOOKMARK__CREATE="BOOKMARK__CREATE",t.BOOKMARK__DELETE="BOOKMARK__DELETE",t.CASE_DEFLECTION__START="CASE_DEFLECTION__START",t.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",t.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",t.CHATBOT__RATE="CHATBOT__RATE",t.COLLECTION__CREATE="COLLECTION__CREATE",t.COLLECTION__UPDATE="COLLECTION__UPDATE",t.COLLECTION__DELETE="COLLECTION__DELETE",t.CUSTOM_EVENT__TRIGGER="CUSTOM_EVENT__TRIGGER",t.DOCUMENT__ON_DEMAND_TRANSLATE="DOCUMENT__ON_DEMAND_TRANSLATE",t.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",t.DOCUMENT__PRINT="DOCUMENT__PRINT",t.DOCUMENT__PROCESS="DOCUMENT__PROCESS",t.DOCUMENT__RATE="DOCUMENT__RATE",t.DOCUMENT__SEARCH="DOCUMENT__SEARCH",t.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",t.DOCUMENT__UNRATE="DOCUMENT__UNRATE",t.FEEDBACK__SEND="FEEDBACK__SEND",t.AI__COMPLETED_QUERY="AI__COMPLETED_QUERY",t.AI__RATE="AI__RATE",t.AI_CASE_DEFLECTION__START="AI_CASE_DEFLECTION__START",t.AI_CASE_DEFLECTION__OPEN_TICKET="AI_CASE_DEFLECTION__OPEN_TICKET",t.KHUB__PROCESS="KHUB__PROCESS",t.KHUB__SEARCH="KHUB__SEARCH",t.LABELS__DOWNLOAD="LABELS__DOWNLOAD",t.LINK__SHARE="LINK__SHARE",t.PAGE__DISPLAY="PAGE__DISPLAY",t.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",t.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",t.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",t.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",t.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",t.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",t.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",t.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",t.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",t.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",t.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",t.TOPIC__AI_TRANSLATE="TOPIC__AI_TRANSLATE",t.TOPIC__RATE="TOPIC__RATE",t.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",t.TOPIC__UNRATE="TOPIC__UNRATE",t.USER__LOGIN="USER__LOGIN",t.USER__LOGOUT="USER__LOGOUT",t.HEARTBEAT="HEARTBEAT"})(ne||(ne={}));var Rr;(function(t){t.STANDARD="STANDARD",t.STRUCTURAL="STRUCTURAL"})(Rr||(Rr={}));var _r;(function(t){t.THIRD_PARTY="THIRD_PARTY",t.OFF_THE_GRID="OFF_THE_GRID",t.CONTENT_PACKAGER="CONTENT_PACKAGER",t.PAGES="PAGES",t.DESIGNED_READER="DESIGNED_READER"})(_r||(_r={}));var Ir;(function(t){t.HOMEPAGE="HOMEPAGE",t.CUSTOM="CUSTOM",t.HEADER="HEADER",t.READER="READER",t.TOPIC_TEMPLATE="TOPIC_TEMPLATE",t.SEARCH="SEARCH",t.SEARCH_RESULT="SEARCH_RESULT",t.SEARCH_ANNOUNCEMENT="SEARCH_ANNOUNCEMENT",t.LINK_PREVIEW="LINK_PREVIEW",t.UD_VIEWER="UD_VIEWER",t.ASSET_VIEWER="ASSET_VIEWER"})(Ir||(Ir={}));var kr;(function(t){t.CLASSIC="CLASSIC",t.CUSTOM="CUSTOM",t.DESIGNER="DESIGNER"})(kr||(kr={}));var Lr;(function(t){t.AND="AND",t.OR="OR",t.MONOVALUED="MONOVALUED"})(Lr||(Lr={}));var Mr;(function(t){t.NONE="NONE",t.ALPHABET="ALPHABET",t.VERSION="VERSION"})(Mr||(Mr={}));var Dr;(function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"})(Dr||(Dr={}));var Pr;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"})(Pr||(Pr={}));var Ke;(function(t){t.OPTIONAL="OPTIONAL",t.MANDATORY="MANDATORY"})(Ke||(Ke={}));var Nr;(function(t){t.ASC="ASC",t.DESC="DESC"})(Nr||(Nr={}));var Ur;(function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"})(Ur||(Ur={}));var me;(function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"})(me||(me={}));var Fr;(function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(Fr||(Fr={}));var jr;(function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"})(jr||(jr={}));var Br;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(Br||(Br={}));var qr;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(qr||(qr={}));var H;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.HTML_PACKAGE="HTML_PACKAGE",t.HTML_PACKAGE_PAGE="HTML_PACKAGE_PAGE"})(H||(H={}));var ve;(function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS",t.ALL_TOPICS="ALL_TOPICS",t.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(ve||(ve={}));var Hr;(function(t){t.PLAIN_TEXT="PLAIN_TEXT",t.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",t.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(Hr||(Hr={}));var T;(function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.GENERATIVE_AI_USER="GENERATIVE_AI_USER",t.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_USER",t.ANNOUNCEMENT_ADMIN="ANNOUNCEMENT_ADMIN",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN"})(T||(T={}));var U;(function(t){t.SEARCHES="SEARCHES",t.BOOKMARKS="BOOKMARKS",t.BOOKS="BOOKS",t.COLLECTIONS="COLLECTIONS"})(U||(U={}));var Vr;(function(t){t.UNAUTHENTICATED="UNAUTHENTICATED",t.USER_INCOMPLETE="USER_INCOMPLETE",t.MFA_REQUIRED="MFA_REQUIRED",t.AUTHENTICATED="AUTHENTICATED"})(Vr||(Vr={}));var Kr;(function(t){t.UNREACHABLE="UNREACHABLE",t.UNAUTHORIZED="UNAUTHORIZED",t.FORBIDDEN="FORBIDDEN",t.INCOMPATIBLE="INCOMPATIBLE",t.FAILED="FAILED",t.OK="OK"})(Kr||(Kr={}));var Gr;(function(t){t.VALID="VALID",t.INVALID="INVALID"})(Gr||(Gr={}));var $r;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SUMMARY="SUMMARY",t.SEMANTIC_SEARCH="SEMANTIC_SEARCH",t.CHATBOT_INSTRUCTIONS="CHATBOT_INSTRUCTIONS",t.DOCUMENTATION="DOCUMENTATION",t.OTHER="OTHER"})($r||($r={}));var zr;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SLOW="SLOW",t.OTHER="OTHER"})(zr||(zr={}));var Wr;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(Wr||(Wr={}));var Qr;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(Qr||(Qr={}));var Yr;(function(t){t.TEXT="TEXT",t.HTML="HTML"})(Yr||(Yr={}));var Xr;(function(t){t.IN_PROGRESS="IN_PROGRESS",t.ERROR="ERROR",t.DONE="DONE"})(Xr||(Xr={}));var Jr;(function(t){t.HTML="HTML",t.MARKDOWN="MARKDOWN"})(Jr||(Jr={}));var Zr;(function(t){t.SOURCES="SOURCES",t.ENRICH_AND_CLEAN="ENRICH_AND_CLEAN",t.VOCABULARIES="VOCABULARIES",t.METADATA="METADATA",t.PRETTY_URL="PRETTY_URL",t.ACCESS_RULE="ACCESS_RULE",t.DESIGNED_PAGES="DESIGNED_PAGES",t.THEME_STUDIO="THEME_STUDIO",t.PORTAL_GENERAL="PORTAL_GENERAL",t.ASSETS="ASSETS",t.CODE_LIBRARY="CODE_LIBRARY",t.THEME="THEME",t.CONTENT_STYLES="CONTENT_STYLES",t.HOMEPAGE="HOMEPAGE",t.CLASSIC_SEARCH_PAGE="CLASSIC_SEARCH_PAGE",t.CLASSIC_READER_PAGE="CLASSIC_READER_PAGE",t.PORTAL_METADATA="PORTAL_METADATA",t.LANGUAGES="LANGUAGES",t.PRINT_TEMPLATES="PRINT_TEMPLATES",t.OFFLINE="OFFLINE",t.CUSTOM_JS="CUSTOM_JS",t.CONFIDENTIALITY="CONFIDENTIALITY",t.NOTIFICATIONS="NOTIFICATIONS"})(Zr||(Zr={}));var en;(function(t){t.MAP="MAP",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT"})(en||(en={}));var xs={[T.PERSONAL_BOOK_SHARE_USER]:[T.PERSONAL_BOOK_USER],[T.HTML_EXPORT_USER]:[T.PERSONAL_BOOK_USER],[T.PDF_EXPORT_USER]:[T.PERSONAL_BOOK_USER],[T.KHUB_ADMIN]:[T.CONTENT_PUBLISHER],[T.ADMIN]:[T.KHUB_ADMIN,T.USERS_ADMIN,T.PORTAL_ADMIN,T.BEHAVIOR_DATA_USER],[T.GENERATIVE_AI_EXPORT_USER]:[T.GENERATIVE_AI_USER]};function tn(t,e){return t===e||(xs[t]??[]).some(r=>tn(r,e))}function rn(t,e){return t==null?!1:(Array.isArray(t)?t:Array.isArray(t.roles)?t.roles:Array.isArray(t.profile?.roles)?t.profile.roles:[]).some(n=>tn(n,e))}var Xt=E(Y());var nn=E(Y(),1);var Tt=t=>e=>{window.customElements.get(t)||window.customElements.define(t,e)};function sn(t,e){return(0,nn.property)({type:Object,converter:{fromAttribute:r=>{if(r==null)return Le(t);try{return JSON.parse(r)}catch{return Le(t)}},toAttribute:r=>JSON.stringify(r)},hasChanged:Me,...e??{}})}function Os(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;let r,n;if(Array.isArray(t)){if(r=t.length,r!=e.length)return!1;for(n=r;n--!==0;)if(!Ge(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(!Ge(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 s=a=>Object.keys(a).filter(o=>a[o]!=null),i=s(t);if(r=i.length,r!==s(e).length)return!1;for(n=r;n--!==0;)if(!Object.prototype.hasOwnProperty.call(e,i[n]))return!1;for(n=r;n--!==0;){let a=i[n];if(!Ge(t[a],e[a]))return!1}return!0}return t!==t&&e!==e||t==null&&e==null}function Ge(t,e){try{return Os(t,e)}catch{return!1}}function Me(t,e){return!Ge(t,e)}function Le(t){return typeof window.structuredClone=="function"?structuredClone(t):t!=null?JSON.parse(JSON.stringify(t)):t}function $e(t,e){let r=n=>n[t]===!0;return n=>{if(r(n))return n;let s=e(n);return s[t]=!0,s}}var an=E(Y(),1);var wt=t=>{let e=t??{};return(r,n)=>{var s;let i={hasChanged:Me,attribute:!1,...e};(0,an.property)(i)(r,n);let a=r.constructor;a.reduxProperties=new Map(a.reduxProperties),a.reduxProperties.set(n,{selector:(s=e.selector)!==null&&s!==void 0?s:(o=>o[n]),store:e.store})}};var ze=class{constructor(){this.queue=[]}add(e,r=!1){r&&this.clear(e.type),this.queue.push(e)}consume(e){let r=this.queue.find(n=>n.type===e);return r&&(this.queue=this.queue.filter(n=>n!==r)),r}clear(e){typeof e=="string"?this.queue=this.queue.filter(r=>r.type!==e):this.queue=this.queue.filter(r=>!e.test(r.type))}};var se=E(Y(),1);var We=class{constructor(e=0){this.timeout=e,this.callbacks=[]}run(e,r){return this.callbacks=[e],this.debounce(r)}queue(e,r){return this.callbacks.push(e),this.debounce(r)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(e){return this.promise==null&&(this.promise=new Promise((r,n)=>{this.resolvePromise=r,this.rejectPromise=n})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),e??this.timeout),this.promise}async runCallbacks(){var e,r;let n=[...this.callbacks];this.callbacks=[];let s=(e=this.rejectPromise)!==null&&e!==void 0?e:(()=>null),i=(r=this.resolvePromise)!==null&&r!==void 0?r:(()=>null);this.clearPromise();for(let a of n)try{await a()}catch(o){s(o);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 un=E(fe(),1);var Qe=globalThis,Ts=Qe.ShadowRoot&&(Qe.ShadyCSS===void 0||Qe.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype;var on=(t,e)=>{if(Ts)t.adoptedStyleSheets=e.map(r=>r instanceof CSSStyleSheet?r:r.styleSheet);else for(let r of e){let n=document.createElement("style"),s=Qe.litNonce;s!==void 0&&n.setAttribute("nonce",s),n.textContent=r.cssText,t.appendChild(n)}};var Ye=class extends un.LitElement{get scopedRegistryConstructor(){return this.constructor}createRenderRoot(){let e=this.scopedRegistryConstructor;e.elementDefinitions&&!e.registry&&(e.registry=new CustomElementRegistry,e.defineScopedElements(e.elementDefinitions));let r={...e.shadowRootOptions,customElements:e.registry},n=this.renderOptions.creationScope=this.attachShadow(r);return on(n,e.elementStyles),n}static canDefineScopedElement(e){return!!this.registry&&!this.registry.get(e)}static defineScopedElements(e){Object.entries(e).forEach(([r,n])=>this.defineScopedElement(r,n))}static defineScopedElement(e,r){Tt(e)(r),this.canDefineScopedElement(e)&&this.registry.define(e,r)}canDefineScopedElement(e){return this.scopedRegistryConstructor.canDefineScopedElement(e)}defineScopedElements(e){this.scopedRegistryConstructor.defineScopedElements(e)}defineScopedElement(e,r){this.scopedRegistryConstructor.defineScopedElement(e,r)}};function cn(t,e,...r){var n;let s=t.querySelector(e);for(let i of r)s=(n=s?.shadowRoot)===null||n===void 0?void 0:n.querySelector(i);return s}var ge=function(t,e,r,n){var s=arguments.length,i=s<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,n);else for(var o=t.length-1;o>=0;o--)(a=t[o])&&(i=(s<3?a(i):s>3?a(e,r,i):a(e,r))||i);return s>3&&i&&Object.defineProperty(e,r,i),i},pn,ln=Symbol("constructorPrototype"),dn=Symbol("constructorName"),fn=Symbol("exportpartsDebouncer"),hn=Symbol("dynamicDependenciesLoaded"),ye=class t extends CustomEvent{constructor(){super(t.eventName,{bubbles:!0})}};ye.eventName="exportparts-updated";var V=class extends Ye{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[pn]=new We(5),this.scheduleExportpartsUpdate=()=>{var e,r,n;(!((e=this.exportpartsPrefix)===null||e===void 0)&&e.trim()||(n=(r=this.exportpartsPrefixes)===null||r===void 0?void 0:r.length)!==null&&n!==void 0&&n)&&this[fn].run(()=>{var s,i;!((s=this.exportpartsPrefix)===null||s===void 0)&&s.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((i=this.exportpartsPrefixes)===null||i===void 0?void 0:i.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})},this[dn]=this.constructor.name,this[ln]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[dn]&&Object.setPrototypeOf(this,this[ln])}connectedCallback(){var e;super.connectedCallback();try{this.shadowRoot&&!this.shadowRoot.adoptedStyleSheets.includes(this.adoptedCustomStyleSheet)&&(this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,this.adoptedCustomStyleSheet]),this.useAdoptedStyleSheets=!0}catch(n){this.useAdoptedStyleSheets=!1,console.error("Cannot use adopted stylesheets",n)}let r=this.constructor;r[hn]||(r[hn]=!0,this.importDynamicDependencies()),(e=this.shadowRoot)===null||e===void 0||e.addEventListener(ye.eventName,this.scheduleExportpartsUpdate)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.shadowRoot)===null||e===void 0||e.removeEventListener(ye.eventName,this.scheduleExportpartsUpdate)}importDynamicDependencies(){}updated(e){super.updated(e),this.updateComplete.then(()=>{this.contentAvailableCallback(e),this.focusElementToFocus(e),this.applyCustomStylesheet(e),this.scheduleExportpartsUpdate(),e.has("exportparts")&&this.dispatchEvent(new ye)})}contentAvailableCallback(e){}focusElementToFocus(e){if(e.has("elementToFocus")&&this.elementToFocus!=null){let{element:r,selector:n,shadowPath:s}=this.elementToFocus;if(n!=null){let i=[...s??[],n];r=cn(this.shadowRoot,...i)}r?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||r?.blur(),this.elementToFocus=void 0}}applyCustomStylesheet(e){var r,n,s;if(((n=(r=this.shadowRoot)===null||r===void 0?void 0:r.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((s=this.customStylesheet)!==null&&s!==void 0?s:"")}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)}}setExportpartsAttribute(e){var r,n,s,i,a,o;let c=d=>d!=null&&d.trim().length>0,u=e.filter(c).map(d=>d.trim());if(u.length===0){this.exportparts=void 0;return}let l=new Set;for(let d of(n=(r=this.shadowRoot)===null||r===void 0?void 0:r.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let m=(i=(s=d.getAttribute("part"))===null||s===void 0?void 0:s.split(" "))!==null&&i!==void 0?i:[],p=(o=(a=d.getAttribute("exportparts"))===null||a===void 0?void 0:a.split(",").map(y=>y.split(":")[1]))!==null&&o!==void 0?o:[],f=[...m,...p].filter(c).map(y=>y.trim());for(let y of f)l.add(y)}if(l.size===0){this.exportparts=void 0;return}let h=[...l.values()].flatMap(d=>u.map(m=>`${d}:${m}--${d}`));this.exportparts=[...this.part,...h].join(", ")}};pn=fn;ge([(0,se.property)()],V.prototype,"exportpartsPrefix",void 0);ge([sn([])],V.prototype,"exportpartsPrefixes",void 0);ge([(0,se.property)({reflect:!0})],V.prototype,"exportparts",void 0);ge([(0,se.property)()],V.prototype,"customStylesheet",void 0);ge([(0,se.property)()],V.prototype,"elementToFocus",void 0);ge([(0,se.state)()],V.prototype,"useAdoptedStyleSheets",void 0);function Xe(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var De=Symbol("internalReduxEventsUnsubscribers"),J=Symbol("internalStoresUnsubscribers"),ie=Symbol("internalStores"),ws=$e(Symbol("withRedux"),function(t){var e,r,n;class s extends t{constructor(){super(...arguments),this[e]=new Map,this[r]=new Map,this[n]=new Map}get reduxConstructor(){return this.constructor}willUpdate(a){super.willUpdate(a),[...this.reduxConstructor.reduxReactiveProperties].some(o=>a.has(o))&&this.updateFromStores()}getUnnamedStore(){if(this[ie].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[ie].values()][0]}getStore(a){return a==null?this.getUnnamedStore():this[ie].get(a)}addStore(a,o){var c;o=(c=o??a.name)!==null&&c!==void 0?c:"default-store",this.unsubscribeFromStore(o),this[ie].set(o,a),this.subscribeToStore(o,a),this.updateFromStores()}removeStore(a){let o=typeof a=="string"?a:a.name;this.unsubscribeFromStore(o),this[ie].delete(o)}setupStores(){this.unsubscribeFromStores(),this[ie].forEach((a,o)=>this.subscribeToStore(o,a)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((a,o)=>{let c=this.constructor.getPropertyOptions(o);if(!c?.attribute||!this.hasAttribute(typeof c?.attribute=="string"?c.attribute:o)){let u=this.getStore(a.store);u&&(a.store?this[J].has(a.store):this[J].size>0)&&(this[o]=a.selector(u.getState(),this))}})}subscribeToStore(a,o){var c;this[J].set(a,o.subscribe(()=>this.updateFromStores())),this[De].set(a,[]),Xe(o)&&o.eventBus&&((c=this.reduxConstructor.reduxEventListeners)===null||c===void 0||c.forEach((u,l)=>{if(typeof this[l]=="function"&&(!u.store||o.name===u.store)){let h=d=>this[l](d);o.addEventListener(u.eventName,h),this[De].get(a).push(()=>o.removeEventListener(u.eventName,h))}})),this.onStoreAvailable(a)}unsubscribeFromStores(){this[J].forEach((a,o)=>this.unsubscribeFromStore(o))}unsubscribeFromStore(a){var o;this[J].has(a)&&this[J].get(a)(),this[J].delete(a),(o=this[De].get(a))===null||o===void 0||o.forEach(c=>c()),this[De].delete(a)}onStoreAvailable(a){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return e=J,r=ie,n=De,s.reduxProperties=new Map,s.reduxReactiveProperties=new Set,s.reduxEventListeners=new Map,s}),mn=class extends ws(V){};function F(t){for(var e=arguments.length,r=Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];if(0)var s,i;throw Error("[Immer] minified error nr: "+t+(r.length?" "+r.map((function(a){return"'"+a+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function z(t){return!!t&&!!t[C]}function q(t){var e;return!!t&&((function(r){if(!r||typeof r!="object")return!1;var n=Object.getPrototypeOf(r);if(n===null)return!0;var s=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return s===Object||typeof s=="function"&&Function.toString.call(s)===Ps})(t)||Array.isArray(t)||!!t[An]||!!(!((e=t.constructor)===null||e===void 0)&&e[An])||Nt(t)||Ut(t))}function ae(t,e,r){r===void 0&&(r=!1),be(t)===0?(r?Object.keys:Ee)(t).forEach((function(n){r&&typeof n=="symbol"||e(n,t[n],t)})):t.forEach((function(n,s){return e(s,n,t)}))}function be(t){var e=t[C];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:Nt(t)?2:Ut(t)?3:0}function Se(t,e){return be(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function Rs(t,e){return be(t)===2?t.get(e):t[e]}function Cn(t,e,r){var n=be(t);n===2?t.set(e,r):n===3?t.add(r):t[e]=r}function xn(t,e){return t===e?t!==0||1/t==1/e:t!=t&&e!=e}function Nt(t){return Ms&&t instanceof Map}function Ut(t){return Ds&&t instanceof Set}function Z(t){return t.o||t.t}function Ft(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=wn(t);delete e[C];for(var r=Ee(e),n=0;n<r.length;n++){var s=r[n],i=e[s];i.writable===!1&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(e[s]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[s]})}return Object.create(Object.getPrototypeOf(t),e)}function jt(t,e){return e===void 0&&(e=!1),Bt(t)||z(t)||!q(t)||(be(t)>1&&(t.set=t.add=t.clear=t.delete=_s),Object.freeze(t),e&&ae(t,(function(r,n){return jt(n,!0)}),!0)),t}function _s(){F(2)}function Bt(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function K(t){var e=Pt[t];return e||F(18,t),e}function Is(t,e){Pt[t]||(Pt[t]=e)}function Lt(){return Ne}function Rt(t,e){e&&(K("Patches"),t.u=[],t.s=[],t.v=e)}function Je(t){Mt(t),t.p.forEach(ks),t.p=null}function Mt(t){t===Ne&&(Ne=t.l)}function vn(t){return Ne={p:[],l:Ne,h:t,m:!0,_:0}}function ks(t){var e=t[C];e.i===0||e.i===1?e.j():e.g=!0}function _t(t,e){e._=e.p.length;var r=e.p[0],n=t!==void 0&&t!==r;return e.h.O||K("ES5").S(e,t,n),n?(r[C].P&&(Je(e),F(4)),q(t)&&(t=Ze(e,t),e.l||et(e,t)),e.u&&K("Patches").M(r[C].t,t,e.u,e.s)):t=Ze(e,r,[]),Je(e),e.u&&e.v(e.u,e.s),t!==Tn?t:void 0}function Ze(t,e,r){if(Bt(e))return e;var n=e[C];if(!n)return ae(e,(function(o,c){return yn(t,n,e,o,c,r)}),!0),e;if(n.A!==t)return e;if(!n.P)return et(t,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var s=n.i===4||n.i===5?n.o=Ft(n.k):n.o,i=s,a=!1;n.i===3&&(i=new Set(s),s.clear(),a=!0),ae(i,(function(o,c){return yn(t,n,s,o,c,r,a)})),et(t,s,!1),r&&t.u&&K("Patches").N(n,r,t.u,t.s)}return n.o}function yn(t,e,r,n,s,i,a){if(z(s)){var o=Ze(t,s,i&&e&&e.i!==3&&!Se(e.R,n)?i.concat(n):void 0);if(Cn(r,n,o),!z(o))return;t.m=!1}else a&&r.add(s);if(q(s)&&!Bt(s)){if(!t.h.D&&t._<1)return;Ze(t,s),e&&e.A.l||et(t,s)}}function et(t,e,r){r===void 0&&(r=!1),!t.l&&t.h.D&&t.m&&jt(e,r)}function It(t,e){var r=t[C];return(r?Z(r):t)[e]}function gn(t,e){if(e in t)for(var r=Object.getPrototypeOf(t);r;){var n=Object.getOwnPropertyDescriptor(r,e);if(n)return n;r=Object.getPrototypeOf(r)}}function ee(t){t.P||(t.P=!0,t.l&&ee(t.l))}function kt(t){t.o||(t.o=Ft(t.t))}function Dt(t,e,r){var n=Nt(e)?K("MapSet").F(e,r):Ut(e)?K("MapSet").T(e,r):t.O?(function(s,i){var a=Array.isArray(s),o={i:a?1:0,A:i?i.A:Lt(),P:!1,I:!1,R:{},l:i,t:s,k:null,o:null,j:null,C:!1},c=o,u=Ue;a&&(c=[o],u=Pe);var l=Proxy.revocable(c,u),h=l.revoke,d=l.proxy;return o.k=d,o.j=h,d})(e,r):K("ES5").J(e,r);return(r?r.A:Lt()).p.push(n),n}function Ls(t){return z(t)||F(22,t),(function e(r){if(!q(r))return r;var n,s=r[C],i=be(r);if(s){if(!s.P&&(s.i<4||!K("ES5").K(s)))return s.t;s.I=!0,n=Sn(r,i),s.I=!1}else n=Sn(r,i);return ae(n,(function(a,o){s&&Rs(s.t,a)===o||Cn(n,a,e(o))})),i===3?new Set(n):n})(t)}function Sn(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return Ft(t)}function On(){function t(a,o){var c=i[a];return c?c.enumerable=o:i[a]=c={configurable:!0,enumerable:o,get:function(){var u=this[C];return Ue.get(u,a)},set:function(u){var l=this[C];Ue.set(l,a,u)}},c}function e(a){for(var o=a.length-1;o>=0;o--){var c=a[o][C];if(!c.P)switch(c.i){case 5:n(c)&&ee(c);break;case 4:r(c)&&ee(c)}}}function r(a){for(var o=a.t,c=a.k,u=Ee(c),l=u.length-1;l>=0;l--){var h=u[l];if(h!==C){var d=o[h];if(d===void 0&&!Se(o,h))return!0;var m=c[h],p=m&&m[C];if(p?p.t!==d:!xn(m,d))return!0}}var f=!!o[C];return u.length!==Ee(o).length+(f?0:1)}function n(a){var o=a.k;if(o.length!==a.t.length)return!0;var c=Object.getOwnPropertyDescriptor(o,o.length-1);if(c&&!c.get)return!0;for(var u=0;u<o.length;u++)if(!o.hasOwnProperty(u))return!0;return!1}function s(a){a.g&&F(3,JSON.stringify(Z(a)))}var i={};Is("ES5",{J:function(a,o){var c=Array.isArray(a),u=(function(h,d){if(h){for(var m=Array(d.length),p=0;p<d.length;p++)Object.defineProperty(m,""+p,t(p,!0));return m}var f=wn(d);delete f[C];for(var y=Ee(f),g=0;g<y.length;g++){var S=y[g];f[S]=t(S,h||!!f[S].enumerable)}return Object.create(Object.getPrototypeOf(d),f)})(c,a),l={i:c?5:4,A:o?o.A:Lt(),P:!1,I:!1,R:{},l:o,t:a,k:u,o:null,g:!1,C:!1};return Object.defineProperty(u,C,{value:l,writable:!0}),u},S:function(a,o,c){c?z(o)&&o[C].A===a&&e(a.p):(a.u&&(function u(l){if(l&&typeof l=="object"){var h=l[C];if(h){var d=h.t,m=h.k,p=h.R,f=h.i;if(f===4)ae(m,(function(b){b!==C&&(d[b]!==void 0||Se(d,b)?p[b]||u(m[b]):(p[b]=!0,ee(h)))})),ae(d,(function(b){m[b]!==void 0||Se(m,b)||(p[b]=!1,ee(h))}));else if(f===5){if(n(h)&&(ee(h),p.length=!0),m.length<d.length)for(var y=m.length;y<d.length;y++)p[y]=!1;else for(var g=d.length;g<m.length;g++)p[g]=!0;for(var S=Math.min(m.length,d.length),x=0;x<S;x++)m.hasOwnProperty(x)||(p[x]=!0),p[x]===void 0&&u(m[x])}}}})(a.p[0]),e(a.p))},K:function(a){return a.i===4?r(a):n(a)}})}var En,Ne,qt=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",Ms=typeof Map<"u",Ds=typeof Set<"u",bn=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",Tn=qt?Symbol.for("immer-nothing"):((En={})["immer-nothing"]=!0,En),An=qt?Symbol.for("immer-draftable"):"__$immer_draftable",C=qt?Symbol.for("immer-state"):"__$immer_state";var Ps=""+Object.prototype.constructor,Ee=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,wn=Object.getOwnPropertyDescriptors||function(t){var e={};return Ee(t).forEach((function(r){e[r]=Object.getOwnPropertyDescriptor(t,r)})),e},Pt={},Ue={get:function(t,e){if(e===C)return t;var r=Z(t);if(!Se(r,e))return(function(s,i,a){var o,c=gn(i,a);return c?"value"in c?c.value:(o=c.get)===null||o===void 0?void 0:o.call(s.k):void 0})(t,r,e);var n=r[e];return t.I||!q(n)?n:n===It(t.t,e)?(kt(t),t.o[e]=Dt(t.A.h,n,t)):n},has:function(t,e){return e in Z(t)},ownKeys:function(t){return Reflect.ownKeys(Z(t))},set:function(t,e,r){var n=gn(Z(t),e);if(n?.set)return n.set.call(t.k,r),!0;if(!t.P){var s=It(Z(t),e),i=s?.[C];if(i&&i.t===r)return t.o[e]=r,t.R[e]=!1,!0;if(xn(r,s)&&(r!==void 0||Se(t.t,e)))return!0;kt(t),ee(t)}return t.o[e]===r&&(r!==void 0||e in t.o)||Number.isNaN(r)&&Number.isNaN(t.o[e])||(t.o[e]=r,t.R[e]=!0),!0},deleteProperty:function(t,e){return It(t.t,e)!==void 0||e in t.t?(t.R[e]=!1,kt(t),ee(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var r=Z(t),n=Reflect.getOwnPropertyDescriptor(r,e);return n&&{writable:!0,configurable:t.i!==1||e!=="length",enumerable:n.enumerable,value:r[e]}},defineProperty:function(){F(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){F(12)}},Pe={};ae(Ue,(function(t,e){Pe[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}})),Pe.deleteProperty=function(t,e){return Pe.set.call(this,t,e,void 0)},Pe.set=function(t,e,r){return Ue.set.call(this,t[0],e,r,t[0])};var Ns=(function(){function t(r){var n=this;this.O=bn,this.D=!0,this.produce=function(s,i,a){if(typeof s=="function"&&typeof i!="function"){var o=i;i=s;var c=n;return function(f){var y=this;f===void 0&&(f=o);for(var g=arguments.length,S=Array(g>1?g-1:0),x=1;x<g;x++)S[x-1]=arguments[x];return c.produce(f,(function(b){var Q;return(Q=i).call.apply(Q,[y,b].concat(S))}))}}var u;if(typeof i!="function"&&F(6),a!==void 0&&typeof a!="function"&&F(7),q(s)){var l=vn(n),h=Dt(n,s,void 0),d=!0;try{u=i(h),d=!1}finally{d?Je(l):Mt(l)}return typeof Promise<"u"&&u instanceof Promise?u.then((function(f){return Rt(l,a),_t(f,l)}),(function(f){throw Je(l),f})):(Rt(l,a),_t(u,l))}if(!s||typeof s!="object"){if((u=i(s))===void 0&&(u=s),u===Tn&&(u=void 0),n.D&&jt(u,!0),a){var m=[],p=[];K("Patches").M(s,u,m,p),a(m,p)}return u}F(21,s)},this.produceWithPatches=function(s,i){if(typeof s=="function")return function(u){for(var l=arguments.length,h=Array(l>1?l-1:0),d=1;d<l;d++)h[d-1]=arguments[d];return n.produceWithPatches(u,(function(m){return s.apply(void 0,[m].concat(h))}))};var a,o,c=n.produce(s,i,(function(u,l){a=u,o=l}));return typeof Promise<"u"&&c instanceof Promise?c.then((function(u){return[u,a,o]})):[c,a,o]},typeof r?.useProxies=="boolean"&&this.setUseProxies(r.useProxies),typeof r?.autoFreeze=="boolean"&&this.setAutoFreeze(r.autoFreeze)}var e=t.prototype;return e.createDraft=function(r){q(r)||F(8),z(r)&&(r=Ls(r));var n=vn(this),s=Dt(this,r,void 0);return s[C].C=!0,Mt(n),s},e.finishDraft=function(r,n){var s=r&&r[C],i=s.A;return Rt(i,n),_t(void 0,i)},e.setAutoFreeze=function(r){this.D=r},e.setUseProxies=function(r){r&&!bn&&F(20),this.O=r},e.applyPatches=function(r,n){var s;for(s=n.length-1;s>=0;s--){var i=n[s];if(i.path.length===0&&i.op==="replace"){r=i.value;break}}s>-1&&(n=n.slice(s+1));var a=K("Patches").$;return z(r)?a(r,n):this.produce(r,(function(o){return a(o,n)}))},t})(),P=new Ns,Us=P.produce,va=P.produceWithPatches.bind(P),ya=P.setAutoFreeze.bind(P),ga=P.setUseProxies.bind(P),Sa=P.applyPatches.bind(P),Ea=P.createDraft.bind(P),ba=P.finishDraft.bind(P),tt=Us;function oe(t){"@babel/helpers - typeof";return oe=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},oe(t)}function Rn(t,e){if(oe(t)!="object"||!t)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var n=r.call(t,e||"default");if(oe(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function _n(t){var e=Rn(t,"string");return oe(e)=="symbol"?e:e+""}function In(t,e,r){return(e=_n(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function kn(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),r.push.apply(r,n)}return r}function Ht(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?kn(Object(r),!0).forEach(function(n){In(t,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):kn(Object(r)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(r,n))})}return t}function I(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}var Ln=(function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"})(),Vt=function(){return Math.random().toString(36).substring(7).split("").join(".")},rt={INIT:"@@redux/INIT"+Vt(),REPLACE:"@@redux/REPLACE"+Vt(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Vt()}};function Fs(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 Kt(t,e,r){var n;if(typeof e=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(I(0));if(typeof e=="function"&&typeof r>"u"&&(r=e,e=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(I(1));return r(Kt)(t,e)}if(typeof t!="function")throw new Error(I(2));var s=t,i=e,a=[],o=a,c=!1;function u(){o===a&&(o=a.slice())}function l(){if(c)throw new Error(I(3));return i}function h(f){if(typeof f!="function")throw new Error(I(4));if(c)throw new Error(I(5));var y=!0;return u(),o.push(f),function(){if(y){if(c)throw new Error(I(6));y=!1,u();var S=o.indexOf(f);o.splice(S,1),a=null}}}function d(f){if(!Fs(f))throw new Error(I(7));if(typeof f.type>"u")throw new Error(I(8));if(c)throw new Error(I(9));try{c=!0,i=s(i,f)}finally{c=!1}for(var y=a=o,g=0;g<y.length;g++){var S=y[g];S()}return f}function m(f){if(typeof f!="function")throw new Error(I(10));s=f,d({type:rt.REPLACE})}function p(){var f,y=h;return f={subscribe:function(S){if(typeof S!="object"||S===null)throw new Error(I(11));function x(){S.next&&S.next(l())}x();var b=y(x);return{unsubscribe:b}}},f[Ln]=function(){return this},f}return d({type:rt.INIT}),n={dispatch:d,subscribe:h,getState:l,replaceReducer:m},n[Ln]=p,n}function js(t){Object.keys(t).forEach(function(e){var r=t[e],n=r(void 0,{type:rt.INIT});if(typeof n>"u")throw new Error(I(12));if(typeof r(void 0,{type:rt.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(I(13))})}function Mn(t){for(var e=Object.keys(t),r={},n=0;n<e.length;n++){var s=e[n];typeof t[s]=="function"&&(r[s]=t[s])}var i=Object.keys(r),a,o;try{js(r)}catch(c){o=c}return function(u,l){if(u===void 0&&(u={}),o)throw o;if(0)var h;for(var d=!1,m={},p=0;p<i.length;p++){var f=i[p],y=r[f],g=u[f],S=y(g,l);if(typeof S>"u"){var x=l&&l.type;throw new Error(I(14))}m[f]=S,d=d||S!==g}return d=d||i.length!==Object.keys(u).length,d?m:u}}function Ae(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return e.length===0?function(n){return n}:e.length===1?e[0]:e.reduce(function(n,s){return function(){return n(s.apply(void 0,arguments))}})}function Dn(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return function(n){return function(){var s=n.apply(void 0,arguments),i=function(){throw new Error(I(15))},a={getState:s.getState,dispatch:function(){return i.apply(void 0,arguments)}},o=e.map(function(c){return c(a)});return i=Ae.apply(void 0,o)(s.dispatch),Ht(Ht({},s),{},{dispatch:i})}}}function Pn(t){var e=function(n){var s=n.dispatch,i=n.getState;return function(a){return function(o){return typeof o=="function"?o(s,i,t):a(o)}}};return e}var Nn=Pn();Nn.withExtraArgument=Pn;var Gt=Nn;var qn=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Bs=function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:o(0),throw:o(1),return:o(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function o(u){return function(l){return c([u,l])}}function c(u){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,s&&(i=u[0]&2?s.return:u[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,u[1])).done)return i;switch(s=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,s=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){r.label=u[1];break}if(u[0]===6&&r.label<i[1]){r.label=i[1],i=u;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(u);break}i[2]&&r.ops.pop(),r.trys.pop();continue}u=e.call(t,r)}catch(l){u=[6,l],s=0}finally{n=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Ce=function(t,e){for(var r=0,n=e.length,s=t.length;r<n;r++,s++)t[s]=e[r];return t},qs=Object.defineProperty,Hs=Object.defineProperties,Vs=Object.getOwnPropertyDescriptors,Un=Object.getOwnPropertySymbols,Ks=Object.prototype.hasOwnProperty,Gs=Object.prototype.propertyIsEnumerable,Fn=function(t,e,r){return e in t?qs(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r},te=function(t,e){for(var r in e||(e={}))Ks.call(e,r)&&Fn(t,r,e[r]);if(Un)for(var n=0,s=Un(e);n<s.length;n++){var r=s[n];Gs.call(e,r)&&Fn(t,r,e[r])}return t},$t=function(t,e){return Hs(t,Vs(e))},$s=function(t,e,r){return new Promise(function(n,s){var i=function(c){try{o(r.next(c))}catch(u){s(u)}},a=function(c){try{o(r.throw(c))}catch(u){s(u)}},o=function(c){return c.done?n(c.value):Promise.resolve(c.value).then(i,a)};o((r=r.apply(t,e)).next())})};var zs=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Ae:Ae.apply(null,arguments)},ja=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}};function Ws(t){if(typeof t!="object"||t===null)return!1;var e=Object.getPrototypeOf(t);if(e===null)return!0;for(var r=e;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return e===r}function re(t,e){function r(){for(var n=[],s=0;s<arguments.length;s++)n[s]=arguments[s];if(e){var i=e.apply(void 0,n);if(!i)throw new Error("prepareAction did not return an object");return te(te({type:t,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:t,payload:n[0]}}return r.toString=function(){return""+t},r.type=t,r.match=function(n){return n.type===t},r}var Qs=(function(t){qn(e,t);function e(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];var s=t.apply(this,r)||this;return Object.setPrototypeOf(s,e.prototype),s}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.prototype.concat.apply(this,r)},e.prototype.prepend=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return r.length===1&&Array.isArray(r[0])?new(e.bind.apply(e,Ce([void 0],r[0].concat(this)))):new(e.bind.apply(e,Ce([void 0],r.concat(this))))},e})(Array),Ys=(function(t){qn(e,t);function e(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];var s=t.apply(this,r)||this;return Object.setPrototypeOf(s,e.prototype),s}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.prototype.concat.apply(this,r)},e.prototype.prepend=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return r.length===1&&Array.isArray(r[0])?new(e.bind.apply(e,Ce([void 0],r[0].concat(this)))):new(e.bind.apply(e,Ce([void 0],r.concat(this))))},e})(Array);function Qt(t){return q(t)?tt(t,function(){}):t}function Xs(t){return typeof t=="boolean"}function Js(){return function(e){return Zs(e)}}function Zs(t){t===void 0&&(t={});var e=t.thunk,r=e===void 0?!0:e,n=t.immutableCheck,s=n===void 0?!0:n,i=t.serializableCheck,a=i===void 0?!0:i,o=t.actionCreatorCheck,c=o===void 0?!0:o,u=new Qs;if(r&&(Xs(r)?u.push(Gt):u.push(Gt.withExtraArgument(r.extraArgument))),0){if(s)var l;if(a)var h;if(c)var d}return u}var zt=!0;function Hn(t){var e=Js(),r=t||{},n=r.reducer,s=n===void 0?void 0:n,i=r.middleware,a=i===void 0?e():i,o=r.devTools,c=o===void 0?!0:o,u=r.preloadedState,l=u===void 0?void 0:u,h=r.enhancers,d=h===void 0?void 0:h,m;if(typeof s=="function")m=s;else if(Ws(s))m=Mn(s);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 p=a;if(typeof p=="function"&&(p=p(e),!zt&&!Array.isArray(p)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!zt&&p.some(function(b){return typeof b!="function"}))throw new Error("each middleware provided to configureStore must be a function");var f=Dn.apply(void 0,p),y=Ae;c&&(y=zs(te({trace:!zt},typeof c=="object"&&c)));var g=new Ys(f),S=g;Array.isArray(d)?S=Ce([f],d):typeof d=="function"&&(S=d(g));var x=y.apply(void 0,S);return Kt(m,l,x)}function Vn(t){var e={},r=[],n,s={addCase:function(i,a){var o=typeof i=="string"?i:i.type;if(!o)throw new Error("`builder.addCase` cannot be called with an empty action type");if(o in e)throw new Error("`builder.addCase` cannot be called with two reducers for the same action type");return e[o]=a,s},addMatcher:function(i,a){return r.push({matcher:i,reducer:a}),s},addDefaultCase:function(i){return n=i,s}};return t(s),[e,r,n]}function ei(t){return typeof t=="function"}function ti(t,e,r,n){r===void 0&&(r=[]);var s=typeof e=="function"?Vn(e):[e,r,n],i=s[0],a=s[1],o=s[2],c;if(ei(t))c=function(){return Qt(t())};else{var u=Qt(t);c=function(){return u}}function l(h,d){h===void 0&&(h=c());var m=Ce([i[d.type]],a.filter(function(p){var f=p.matcher;return f(d)}).map(function(p){var f=p.reducer;return f}));return m.filter(function(p){return!!p}).length===0&&(m=[o]),m.reduce(function(p,f){if(f)if(z(p)){var y=p,g=f(y,d);return g===void 0?p:g}else{if(q(p))return tt(p,function(S){return f(S,d)});var g=f(p,d);if(g===void 0){if(p===null)return p;throw Error("A case reducer on a non-draftable value must not return undefined")}return g}return p},h)}return l.getInitialState=c,l}function ri(t,e){return t+"/"+e}function Kn(t){var e=t.name;if(!e)throw new Error("`name` is a required option for createSlice");typeof process<"u";var r=typeof t.initialState=="function"?t.initialState:Qt(t.initialState),n=t.reducers||{},s=Object.keys(n),i={},a={},o={};s.forEach(function(l){var h=n[l],d=ri(e,l),m,p;"reducer"in h?(m=h.reducer,p=h.prepare):m=h,i[l]=m,a[d]=m,o[l]=p?re(d,p):re(d)});function c(){var l=typeof t.extraReducers=="function"?Vn(t.extraReducers):[t.extraReducers],h=l[0],d=h===void 0?{}:h,m=l[1],p=m===void 0?[]:m,f=l[2],y=f===void 0?void 0:f,g=te(te({},d),a);return ti(r,function(S){for(var x in g)S.addCase(x,g[x]);for(var b=0,Q=p;b<Q.length;b++){var $=Q[b];S.addMatcher($.matcher,$.reducer)}y&&S.addDefaultCase(y)})}var u;return{name:e,reducer:function(l,h){return u||(u=c()),u(l,h)},actions:o,caseReducers:i,getInitialState:function(){return u||(u=c()),u.getInitialState()}}}var ni="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",si=function(t){t===void 0&&(t=21);for(var e="",r=t;r--;)e+=ni[Math.random()*64|0];return e},ii=["name","message","stack","code"],Wt=(function(){function t(e,r){this.payload=e,this.meta=r}return t})(),jn=(function(){function t(e,r){this.payload=e,this.meta=r}return t})(),ai=function(t){if(typeof t=="object"&&t!==null){for(var e={},r=0,n=ii;r<n.length;r++){var s=n[r];typeof t[s]=="string"&&(e[s]=t[s])}return e}return{message:String(t)}},Va=(function(){function t(e,r,n){var s=re(e+"/fulfilled",function(l,h,d,m){return{payload:l,meta:$t(te({},m||{}),{arg:d,requestId:h,requestStatus:"fulfilled"})}}),i=re(e+"/pending",function(l,h,d){return{payload:void 0,meta:$t(te({},d||{}),{arg:h,requestId:l,requestStatus:"pending"})}}),a=re(e+"/rejected",function(l,h,d,m,p){return{payload:m,error:(n&&n.serializeError||ai)(l||"Rejected"),meta:$t(te({},p||{}),{arg:d,requestId:h,rejectedWithValue:!!m,requestStatus:"rejected",aborted:l?.name==="AbortError",condition:l?.name==="ConditionError"})}}),o=!1,c=typeof AbortController<"u"?AbortController:(function(){function l(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return l.prototype.abort=function(){},l})();function u(l){return function(h,d,m){var p=n?.idGenerator?n.idGenerator(l):si(),f=new c,y,g=!1;function S(b){y=b,f.abort()}var x=(function(){return $s(this,null,function(){var b,Q,$,Re,hr,_e,pr;return Bs(this,function(pe){switch(pe.label){case 0:return pe.trys.push([0,4,,5]),Re=(b=n?.condition)==null?void 0:b.call(n,l,{getState:d,extra:m}),ui(Re)?[4,Re]:[3,2];case 1:Re=pe.sent(),pe.label=2;case 2:if(Re===!1||f.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return g=!0,hr=new Promise(function(B,Ie){return f.signal.addEventListener("abort",function(){return Ie({name:"AbortError",message:y||"Aborted"})})}),h(i(p,l,(Q=n?.getPendingMeta)==null?void 0:Q.call(n,{requestId:p,arg:l},{getState:d,extra:m}))),[4,Promise.race([hr,Promise.resolve(r(l,{dispatch:h,getState:d,extra:m,requestId:p,signal:f.signal,abort:S,rejectWithValue:function(B,Ie){return new Wt(B,Ie)},fulfillWithValue:function(B,Ie){return new jn(B,Ie)}})).then(function(B){if(B instanceof Wt)throw B;return B instanceof jn?s(B.payload,p,l,B.meta):s(B,p,l)})])];case 3:return $=pe.sent(),[3,5];case 4:return _e=pe.sent(),$=_e instanceof Wt?a(null,p,l,_e.payload,_e.meta):a(_e,p,l),[3,5];case 5:return pr=n&&!n.dispatchConditionRejection&&a.match($)&&$.meta.condition,pr||h($),[2,$]}})})})();return Object.assign(x,{abort:S,requestId:p,arg:l,unwrap:function(){return x.then(oi)}})}}return Object.assign(u,{pending:i,rejected:a,fulfilled:s,typePrefix:e})}return t.withTypes=function(){return t},t})();function oi(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function ui(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var Gn="listener",$n="completed",zn="cancelled",Ka="task-"+zn,Ga="task-"+$n,$a=Gn+"-"+zn,za=Gn+"-"+$n;var Yt="listenerMiddleware";var Wa=re(Yt+"/add"),Qa=re(Yt+"/removeAll"),Ya=re(Yt+"/remove");var Bn,Xa=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(t){return(Bn||(Bn=Promise.resolve())).then(t).catch(function(e){return setTimeout(function(){throw e},0)})},ci=function(t){return function(e){setTimeout(e,t)}},Ja=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:ci(10);On();var li=$e(Symbol("withEventBus"),function(t,e){return class extends t{constructor(){super(...arguments),this.eventBus=e??document.createElement("span")}addEventListener(r,n,s){this.eventBus.addEventListener(r,n,s)}dispatchEvent(r){return this.eventBus.dispatchEvent(r)}removeEventListener(r,n,s){this.eventBus.removeEventListener(r,n,s)}}}),nt=class extends li(Object){};window.ftReduxStores||(window.ftReduxStores={});var Wn=class t extends nt{static get(e){var r;let n=typeof e=="string"?e:e.name,s=typeof e=="string"?void 0:e,i=window.ftReduxStores[n];if(Xe(i))return i;if(s==null)return;let a=Kn({...s,reducers:(r=s.reducers)!==null&&r!==void 0?r:{}}),o=Hn({reducer:(c,u)=>{if(u.type==="CLEAR_FT_REDUX_STORE"){let l=Le(a.getInitialState());for(let h of u.keeping)l[h]=(c??l)[h];return l}else if(typeof u.type=="string"&&u.type.startsWith("DEFAULT_VALUE_SETTER__"))return{...c,...u.overwrites};return a.reducer(c,u)}});return window.ftReduxStores[s.name]=new t(a,o,s.eventBus)}constructor(e,r,n){super(),this.reduxSlice=e,this.reduxStore=r,this.isFtReduxStore=!0,this.commands=new ze;let s=i=>i!=null?JSON.parse(JSON.stringify(i)):i;this.actions=new Proxy(this.reduxSlice.actions,{get:(i,a,o)=>{let c=a,u=i[c];return u?(...l)=>{let h=u(...l.map(s));return this.reduxStore.dispatch(h),h}:l=>{this.setState({[c]:s(l)})}}}),this.eventBus=n??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:[]})}clearKeeping(...e){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:e})}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 st=class{static format(e,r,n,s,i){return window.moment?window.moment(e).locale(r).format(this.getMomentDateFormat(n,s,!!i)):this.getIntlDateTime(e,r,n,s,!!i)}static getMomentDateFormat(e,r,n){return n?"LT":e?r?"lll":"ll":r?"L LT":"L"}static getIntlDateTime(e,r,n,s,i){let a=typeof e=="string"?new Date(e):e,o=new Intl.DateTimeFormat(r,{dateStyle:n?"medium":"short"}).format(a),c=new Intl.DateTimeFormat(r,{timeStyle:"short"}).format(a);return i?c:s?`${o} ${c}`:o}static getTimezoneAsString(){let e=n=>String(Math.floor(n)).padStart(2,"0"),r=new Date().getTimezoneOffset();return`${r<0?"+":"-"}${e(Math.abs(r)/60)}:${e(Math.abs(r)%60)}`}};var it=E(w()),di="ft-app-info",xe=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};xe.eventName="authentication-change";var Fe=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};Fe.eventName="ui-locale-changed";var hi={session:(t,e)=>{(0,it.deepEqual)(t.session,e.payload)||(t.session=e.payload,setTimeout(()=>v.dispatchEvent(new xe(e.payload)),0))}},v=it.FtReduxStore.get({name:di,reducers:hi,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],availableContentLocales:[],defaultLocales:void 0,searchInAllLanguagesAllowed:!1,searchLanguageSetsUiLanguage:!1,uiLanguageSetsSearchLanguage:!1,uiLanguageSetsReaderLanguage:!1,metadataConfiguration:void 0,privacyPolicyConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,session:void 0,openExternalDocumentInNewTab:!1,navigatorOnline:!0,forcedOffline:!1,authenticationRequired:!1}});var Qn=E(w()),at=function(t,e,r,n){var s=arguments.length,i=s<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,n);else for(var o=t.length-1;o>=0;o--)(a=t[o])&&(i=(s<3?a(i):s>3?a(e,r,i):a(e,r))||i);return s>3&&i&&Object.defineProperty(e,r,i),i},wo=(0,Qn.applyMixinOnce)(Symbol("withDateFormat"),function(t){class e extends t{constructor(...n){super(n),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(v)}dateFormatOptionsChanged(n){return n.has("metadataDescriptors")||n.has("useLongDateFormat")||n.has("useDateTimeFormat")||n.has("uiLocale")}getDateFormatter(n){var s,i;return((i=(s=this.metadataDescriptors.find(o=>o.key===n))===null||s===void 0?void 0:s.date)!==null&&i!==void 0?i:!1)?o=>st.format(o,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return at([(0,Xt.property)({type:Boolean})],e.prototype,"useLongDateFormat",void 0),at([(0,Xt.property)({type:Boolean})],e.prototype,"useDateTimeFormat",void 0),at([wt({store:v.name,selector:r=>{var n,s;return(s=(n=r.metadataConfiguration)===null||n===void 0?void 0:n.descriptors)!==null&&s!==void 0?s:[]}})],e.prototype,"metadataDescriptors",void 0),at([wt({store:v.name})],e.prototype,"uiLocale",void 0),e});var dt=E(w());var Jt=E(w());var ue=class t{static get(e){let{baseUrl:r,apiIntegrationIdentifier:n}=v.getState(),s=e??n;if(r&&s&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(r,s,!0)}static await(e){return new Promise(r=>{let n=t.get(e);if(n)r(n);else{let s=v.subscribe(()=>{n=t.get(e),n&&(s(),r(n))})}})}};var Oe=class{constructor(e){this.overrideApi=e}get api(){var e;return(e=this.overrideApi)!==null&&e!==void 0?e:ue.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):ue.await()}};var k=class extends Oe{constructor(e=!0,r){var n;super(r),this.sortObjectFields=(i,a)=>typeof a!="object"||a==null||Array.isArray(a)?a:Object.fromEntries(Object.entries(a).sort(([o],[c])=>o.localeCompare(c)));let s=this.constructor;s.commonCache=(n=s.commonCache)!==null&&n!==void 0?n:new Jt.CacheRegistry,this.cache=e?s.commonCache:new Jt.CacheRegistry}clearCache(){this.cache.clearAll()}hash(e){return String(Array.from(JSON.stringify(e,this.sortObjectFields)).reduce((r,n)=>0|31*r+n.charCodeAt(0),0))}};var ot=class extends k{async listMySearches(){let{session:e}=v.getState();return rn(e,T.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),300*1e3):[]}};var ut=class extends k{async listMyBookmarks(){let e=v.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),300*1e3):[]}};var ct=class extends k{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetCount(e){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${e}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(e){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${e}`),this.CACHE_DURATION)}isAuthenticated(){let e=v.getState().session;return!!e?.sessionAuthenticated}};var lt=class extends k{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let e=v.getState().session;return!!e?.sessionAuthenticated}};var pi="ft-user-assets",fi={setAssetCount:(t,e)=>{let{userAssetType:r,count:n}=e.payload.assetCount;t.assetCounts.allAsset[r]=n},clearAssetCount:t=>{Object.values(U).forEach(e=>{t.assetCounts.allAsset[e]=void 0})},setBookmarkCountByMap:(t,e)=>{let r=e.payload.mapId;t.assetCounts.bookmarkByMap[r]=e.payload.count},clearBookmarkCountByMap:t=>{t.assetCounts.bookmarkByMap={}},addAsset:(t,e)=>{let{assetType:r,mapId:n,asset:s}=e.payload;er(t,r,[...Zt(t,r),s]),Yn(t,r,1,n),Xn(t,s)},editAsset:(t,e)=>{let{assetType:r,asset:n}=e.payload;er(t,r,Zt(t,r).map(s=>s.id===n.id?n:s)),Xn(t,n)},removeAsset:(t,e)=>{let{assetType:r,mapId:n,assetId:s}=e.payload;er(t,r,Zt(t,r).filter(i=>i.id!==s)),Yn(t,r,-1,n)}},Jn={[U.SEARCHES]:"savedSearches",[U.BOOKMARKS]:"bookmarks",[U.BOOKS]:void 0,[U.COLLECTIONS]:void 0},Zt=(t,e)=>{var r;let n=Jn[e];return n?(r=t[n])!==null&&r!==void 0?r:[]:[]},er=(t,e,r)=>{let n=Jn[e];n&&(t[n]=r)},Yn=(t,e,r,n)=>{let s=t.assetCounts.allAsset[e];if(s!==void 0&&(t.assetCounts.allAsset[e]=Math.max(0,s+r),e===U.BOOKMARKS&&n)){let i=t.assetCounts.bookmarkByMap[n];t.assetCounts.bookmarkByMap[n]=Math.max(0,i+r)}},Xn=(t,e)=>{let r=t.assetLabels.map(s=>s.title),n=e.labels.filter(s=>!r.includes(s)).map(s=>({title:s}));t.assetLabels.push(...n)},M=dt.FtReduxStore.get({name:pi,reducers:fi,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(U).map(t=>[t,void 0])),bookmarkByMap:{}},assetLabels:[]}}),tr=class{constructor(e=new ct,r=new lt){this.assetCountsService=e,this.assetLabelsService=r,this.currentSession=v.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new ut,this.savedSearchesService=new ot,v.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:r}=v.getState();(0,dt.deepEqual)((e=this.currentSession)===null||e===void 0?void 0:e.profile,r?.profile)||(this.currentSession=r,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),M.actions.clearAssetCount(),M.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),M.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),M.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();M.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let e=await this.assetLabelsService.getUserAssetLabels();M.actions.assetLabels(e)}async loadAssetCount(e){let r=await this.assetCountsService.getUserAssetCount(e);r&&M.getState().assetCounts.allAsset[e]!==r.count&&M.actions.setAssetCount({assetCount:r})}async loadBookmarkByMapId(e){let r=await this.assetCountsService.getUserBookmarkCountByMap(e);r&&M.getState().assetCounts.bookmarkByMap[e]!==r.count&&M.actions.setBookmarkCountByMap({count:r.count,mapId:e})}async reloadAssetCount(e){this.assetCountsService.clearCache();let r=Object.keys(M.getState().assetCounts.bookmarkByMap).length!==0;e===U.BOOKMARKS&&r&&M.actions.clearBookmarkCountByMap(),M.getState().assetCounts.allAsset[e]!==void 0&&await this.loadAssetCount(e)}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var e;if(this.bookmarksAreUsed){let r=!((e=this.currentSession)===null||e===void 0)&&e.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;M.actions.bookmarks(r)}}},rr=new tr;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=rr);var nr=class{addCommand(e,r=!1){v.commands.add(e,r)}consumeCommand(e){return v.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new nr;var j=E(w());var Zn,Te=class extends CustomEvent{constructor(e){super("ft-i18n-context-loaded",{detail:e})}},mi=Symbol("clearAfterUnitTest"),ht=class extends(0,j.withEventBus)(k){constructor(e){super(),this.messageContextProvider=e,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[Zn]=()=>{this.defaultMessages={},this.cache=new j.CacheRegistry,this.listeners={}},this.currentUiLocale=v.getState().uiLocale,v.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:e}=v.getState();this.currentUiLocale!==e&&(this.currentUiLocale=e,this.cache.clearAll(),this.notifyAll())}addContext(e){let r=e.name.toLowerCase();this.cache.setFinal(r,e),this.notify(r)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(e,r){var n;if(e=e.toLowerCase(),r&&Object.keys(r).length>0){let s={...(n=this.defaultMessages[e])!==null&&n!==void 0?n:{},...r};(0,j.deepEqual)(this.defaultMessages[e],s)||(this.defaultMessages[e]=s,await this.notify(e))}return this.fetchContext(e)}resolveContext(e){var r,n;return this.fetchContext(e),(n=(r=this.cache.getNow(e))===null||r===void 0?void 0:r.messages)!==null&&n!==void 0?n:{}}resolveRawMessage(e,r){let n=e.toLowerCase();return this.resolveContext(n)[r]}resolveMessage(e,r,...n){var s;let i=e.toLowerCase(),a=this.resolveContext(i);return new j.ParametrizedLabelResolver((s=this.defaultMessages[i])!==null&&s!==void 0?s:{},a).resolve(r,...n)}async fetchContext(e){let r=!this.cache.has(e),n;try{n=await this.cache.get(e,()=>this.messageContextProvider(this.currentUiLocale,e)),r&&await this.notify(e)}catch(s){!(s instanceof j.CanceledPromiseError)&&r&&console.error(s)}return n}subscribe(e,r){var n;return e=e.toLowerCase(),this.listeners[e]=(n=this.listeners[e])!==null&&n!==void 0?n:new Set,this.listeners[e].add(r),()=>{var s;return(s=this.listeners[e])===null||s===void 0?void 0:s.delete(r)}}async notifyAll(){let e=Object.keys(this.listeners);document.body.dispatchEvent(new Te({loadedContexts:e})),this.dispatchEvent(new Te({loadedContexts:e})),await Promise.all(e.map(r=>this.notify(r,!1)))}async notify(e,r=!0){r&&(document.body.dispatchEvent(new Te({loadedContexts:[e]})),this.dispatchEvent(new Te({loadedContexts:[e]}))),this.listeners[e]!=null&&await Promise.all([...this.listeners[e].values()].map(n=>(0,j.delay)(0).then(()=>n()).catch(()=>null)))}};Zn=mi;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends ht{constructor(){super(async(t,e)=>(await this.awaitApi).getFluidTopicsMessageContext(t,e))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends ht{constructor(){super(async(t,e)=>(await this.awaitApi).getCustomMessageContext(t,e))}});var es=window.FluidTopicsI18nService,uu=window.FluidTopicsCustomI18nService;var ts=E(w()),sr=class{highlightHtml(e,r,n){(0,ts.highlightHtml)(e,r,n)}};window.FluidTopicsHighlightHtmlService=new sr;var rs=E(w());var ir=class{isDate(e){var r,n,s,i;return(i=(s=((n=(r=v.getState().metadataConfiguration)===null||r===void 0?void 0:r.descriptors)!==null&&n!==void 0?n:[]).find(o=>o.key===e))===null||s===void 0?void 0:s.date)!==null&&i!==void 0?i:!1}format(e,r){var n,s,i,a;if(e==null)return"";try{return rs.DateFormatter.format(e,(n=r?.locale)!==null&&n!==void 0?n:v.getState().uiLocale,(s=r?.longFormat)!==null&&s!==void 0?s:!1,(i=r?.withTime)!==null&&i!==void 0?i:!1,(a=r?.onlyTime)!==null&&a!==void 0?a:!1)}catch(o){throw console.error(`Date ${JSON.stringify(e)} is not valid`,o),o}}};window.FluidTopicsDateService=new ir;var ns=E(w());var je=class{static get(e,r){var n,s;let i=v.getState(),{lang:a,region:o}=(s=(n=i.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&s!==void 0?s:{lang:"en",region:"US"};return new ns.SearchPlaceConverter(i.baseUrl,e??20,i.searchInAllLanguagesAllowed,r??`${a}-${o}`)}};var pt=class extends k{async sendDocumentStartDisplayEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.start_display event")}async sendTopicStartDisplayEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send topic.start_display event")}async sendKhubSearchEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send khub.search event")}async sendDocumentSearchEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.search event")}async sendSearchPageSelectEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send search_page.select event")}async sendSearchResultOpenContextMenuEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send search_result.open_context_menu event")}async sendDocumentOnDemandTranslateEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send document.on_demand_translate event")}async sendTopicAiTranslateEvent(e){return this.sendEvents([this.sortEventArrays(e)],"Failed to send topic.ai_translate event")}convertMapToAnalyticsDocument(e){let r;switch(e.editorialType){case"BOOK":r="STRUCTURED_DOCUMENT";break;case"SHARED_BOOK":r="SHARED_PERSONAL_BOOK";break;case"ARTICLE":r="RESOURCE";break;case"HTML_PACKAGE":r="HTML_PACKAGE";break;default:throw new TypeError("Unknown editorial type for map : "+e.editorialType)}return{id:e.id,title:e.title,type:r,metadata:e.metadata}}sortEventArrays(e){let r=Object.entries(e).map(([n,s])=>Array.isArray(s)?[n,s.map(i=>typeof i=="object"&&i!=null&&!Array.isArray(i)?this.sortEventArrays(i):i).sort((i,a)=>typeof i=="object"&&i!==null&&"key"in i?i.key.localeCompare(a.key):typeof i=="string"&&typeof a=="string"?i.localeCompare(a):String(i).localeCompare(String(a)))]:typeof s=="object"&&s!==null?[n,this.sortEventArrays(s)]:[n,s]);return Object.fromEntries(r)}sendEvents(e,r){let n="anything not undefined";return this.cache.get("analytics-event-"+this.hash(e),async()=>(await this.awaitApi).sendEvents(e).then(()=>n).catch(s=>(console.info(r),console.debug(s),n)),1e3)}};var ar=class{urlToSearchRequest(e){return je.get().parse(e)}searchRequestToUrl(e){return je.get().serialize(e)}};window.FluidTopicsUrlService=new ar;var W=E(w());var ce=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{currentItem:e}})}};ce.eventName="change";var or=class{itemName(e){return`fluid-topics-history-item-${e}`}get(e){let r=sessionStorage.getItem(this.itemName(e));return r?JSON.parse(r):void 0}set(e,r){sessionStorage.setItem(this.itemName(e),JSON.stringify(r))}},ss=new or;var ft=class t extends W.WithEventBus{static build(){return new t(window.history,ss,()=>window.location,!1)}constructor(e,r,n,s){var i,a;super(),this.history=e,this.historyStorage=r,this.windowLocation=n,this.states=[],this.realPushState=e.pushState,this.realReplaceState=e.replaceState,this.initialIndex=(a=(i=e.state)===null||i===void 0?void 0:i.index)!==null&&a!==void 0?a:e.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(s)}setCurrentState(e,r=!1){let n=r&&this.currentIndex===e.index-1;this.currentState={...this.buildCurrentState(),...e},this.currentIndex=this.currentState.index,this.states[this.currentIndex]=this.currentState,n&&(this.states=this.states.slice(0,this.currentIndex+1)),this.historyStorage.set(this.currentIndex,this.currentState),(0,W.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,window.location.href]),setTimeout(()=>this.dispatchEvent(new ce(this.currentItem())),0)}installProxies(){let e=r=>(n,s,[i,a,o])=>{let c=r(),u={...c===this.currentIndex?this.currentState:void 0,...i,index:c,href:typeof o=="string"?o:(o??this.windowLocation()).href};n.apply(s,[u,a,o]),this.setCurrentState(u,!0)};this.history.pushState=new Proxy(this.history.pushState,{apply:e(()=>this.currentIndex+1)}),this.history.replaceState=new Proxy(this.history.replaceState,{apply:e(()=>this.currentIndex)})}initEventListeners(){window.addEventListener("popstate",e=>this.setCurrentState(e.state)),document.querySelector("title")==null&&document.head.append(document.createElement("title")),new MutationObserver(()=>this.updateCurrentState({title:document.title})).observe(document.querySelector("title"),{subtree:!0,characterData:!0,childList:!0})}initData(e){for(let r=this.history.length-1;r>=0;r--)e?this.states[r]=this.historyStorage.get(r):setTimeout(()=>this.states[r]=this.historyStorage.get(r),this.history.length-r)}updateCurrentState(e){var r;let n={...this.buildCurrentState(),...e,index:this.currentIndex,title:(r=e?.title)!==null&&r!==void 0?r:this.currentState.title};this.setCurrentState(n)}addHistoryChangeListener(e){this.addEventListener(ce.eventName,e)}removeHistoryChangeListener(e){this.removeEventListener(ce.eventName,e)}currentItem(){return(0,W.deepCopy)(this.currentState)}back(){let e=this.previousDifferentMajorPosition();e>=0?this.history.go(e-this.currentIndex):this.currentIndex!==this.initialIndex?this.history.go(this.initialIndex-this.currentIndex):this.history.back()}backwardItem(){return(0,W.deepCopy)(this.states[this.previousDifferentMajorPosition()])}backwardItemMatching(e){let r=this.states.filter(n=>!!n).filter(n=>n.index<this.currentIndex).reverse();return(0,W.deepCopy)(r.find(n=>e(n)))}previousDifferentMajorPosition(){let e=this.currentIndex>0?this.currentIndex-1:0;for(;e>0&&!this.isDifferentMajorState(e);)e--;return e}forward(){let e=this.nextMajorPosition();e&&e<this.states.length?this.history.go(e-this.currentIndex):this.history.forward()}forwardItem(){let e=this.nextMajorPosition();if(e)return(0,W.deepCopy)(this.states[e])}nextMajorPosition(){let e=this.currentIndex;if(!(e>=this.states.length)){do e++;while(e<this.states.length&&!this.isDifferentMajorState(e));return this.getHigherPositionInTheSameState(e)}}getHigherPositionInTheSameState(e){var r;let n=(r=this.states[e])===null||r===void 0?void 0:r.majorStateId;if(!n)return e;let s=e,i=e+1;for(;this.states.length>i&&!this.isDifferentMajorState(i,n);)this.hasState(i)&&(s=i),i++;return s}buildCurrentState(){var e,r;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(r=(e=this.history.state)===null||e===void 0?void 0:e.title)!==null&&r!==void 0?r:document.title}}hasState(e){return this.states[e]!=null}isDifferentMajorState(e,r){var n;if(!this.hasState(e))return!1;let s=r??this.currentState.majorStateId,i=(n=this.states[e])===null||n===void 0?void 0:n.majorStateId;return i==null||i!=s}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=ft.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),backwardItemMatching:t=>window.FluidTopicsInternalHistoryService.backwardItemMatching(t),addHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(t),removeHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(t)});var is=E(fe());var as=is.css`
|
|
3
3
|
`;var us=E(fe()),N=E(Y()),he=E(w());var le=E(w());function os(t,e){let{authenticationRequired:r,session:n}=v.getState();return r&&!n?.sessionAuthenticated?Promise.resolve(e):t()}var mt=class extends Oe{async updateUiLocale(e){return(await this.awaitApi).updateUiLocale(e)}};var ur=class t extends le.FtStateManager{static build(e){return new t(v,e)}constructor(e,r){super(),this.store=e,this.cache=new le.CacheRegistry,this.withManualResources=!0,this.localesConfiguration=null,this.userLocaleService=new mt,this.cleanSessionDebouncer=new le.Debouncer,this.reloadDebouncer=new le.Debouncer(500),this.apiProvider=r??(()=>ue.get())}setWithManualResources(e){this.withManualResources=e,this.updateIfNeeded()}async initService(){this.store.addEventListener(xe.eventName,this.reloadConfiguration)}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.store.getState().session==null&&this.updateSession(),this.store.getState().metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration(),(this.store.getState().availableContentLocales==null||this.store.getState().availableContentLocales.length==0)&&this.updateAvailableContentLocales())}async updateSession(){let e=await this.cache.get("session",async()=>{let r=await this.apiProvider().getCurrentSession();return r.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.setSession(void 0)},r.idleTimeoutInMillis),r});this.setSession(e)}async updateMetadataConfiguration(){this.setMetadataConfiguration(await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration()))}async updateLocalesConfiguration(){this.setLocalesConfiguration(await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration()))}async updateAvailableContentLocales(){var e;let r=await this.cache.get("availableContentLocales",()=>os(()=>this.apiProvider().getAvailableSearchLocales(),{contentLocales:[]}));this.setAvailableContentLocales((e=r.contentLocales)!==null&&e!==void 0?e:[])}reloadConfiguration(){var e;(e=this.cache)===null||e===void 0||e.clear("availableContentLocales"),typeof this.updateAvailableContentLocales=="function"&&this.updateAvailableContentLocales()}setBaseUrl(e){this.store.actions.baseUrl(e),window.fluidTopicsBaseUrl=e}setApiIntegrationIdentifier(e){this.store.actions.apiIntegrationIdentifier(e)}setApiIntegrationAppVersion(e){this.store.actions.apiIntegrationAppVersion(e)}setUiLocale(e){this.store.actions.uiLocale(e)}setLocalesConfiguration(e){var r,n,s,i,a;this.localesConfiguration=e,this.store.actions.defaultLocales(this.localesConfiguration.defaultLocales),this.store.actions.availableUiLocales((r=this.localesConfiguration.availableUiLocales)!==null&&r!==void 0?r:[]),this.store.actions.searchInAllLanguagesAllowed((n=this.localesConfiguration.allLanguagesAllowed)!==null&&n!==void 0?n:!1),this.store.actions.searchLanguageSetsUiLanguage((s=this.localesConfiguration.searchLanguageSetsUiLanguage)!==null&&s!==void 0?s:!1),this.store.actions.uiLanguageSetsSearchLanguage((i=this.localesConfiguration.uiLanguageSetsSearchLanguage)!==null&&i!==void 0?i:!1),this.store.actions.uiLanguageSetsReaderLanguage((a=this.localesConfiguration.uiLanguageSetsReaderLanguage)!==null&&a!==void 0?a:!1),setTimeout(()=>this.updateIfNeeded())}setAvailableContentLocales(e){this.store.actions.availableContentLocales(e),setTimeout(()=>this.updateIfNeeded())}stopReloadDebouncer(){this.reloadDebouncer.cancel()}requestUiLocaleUpdate(e){this.userLocaleService.updateUiLocale({uiLocale:e}).then(r=>{r.uiLocaleChanged&&(this.reloadDebouncer.run(()=>window.location.reload()),this.store.dispatchEvent(new Fe(r)))}).catch(()=>{})}setMetadataConfiguration(e){this.store.actions.metadataConfiguration(e),setTimeout(()=>this.updateIfNeeded())}setNoCustom(e){this.store.actions.noCustom(e)}setEditorMode(e){this.store.actions.editorMode(e)}setNoCustomComponent(e){this.store.actions.noCustomComponent(e)}setSession(e){this.store.actions.session(e),setTimeout(()=>this.updateIfNeeded())}setOpenExternalDocumentInNewTab(e){this.store.actions.openExternalDocumentInNewTab(e)}setNavigatorOnline(e){this.store.actions.navigatorOnline(e)}setForcedOffline(e){this.store.actions.forcedOffline(e)}setAuthenticationRequired(e){this.store.actions.authenticationRequired(e)}},Be=ur.build();var de=class extends Event{constructor(e,r,n,s){super("context-request",{bubbles:!0,composed:!0}),this.context=e,this.contextTarget=r,this.callback=n,this.subscribe=s??!1}};var qe=class{constructor(){this.pendingContextRequests=new Map,this.onContextProvider=e=>{let r=this.pendingContextRequests.get(e.context);if(r===void 0)return;this.pendingContextRequests.delete(e.context);let{requests:n}=r;for(let{elementRef:s,callbackRef:i}of n){let a=s.deref(),o=i.deref();a===void 0||o===void 0||a.dispatchEvent(new de(e.context,a,o,!0))}},this.onContextRequest=e=>{if(e.subscribe!==!0)return;let r=e.contextTarget??e.composedPath()[0],n=e.callback,s=this.pendingContextRequests.get(e.context);s===void 0&&this.pendingContextRequests.set(e.context,s={callbacks:new WeakMap,requests:[]});let i=s.callbacks.get(r);i===void 0&&s.callbacks.set(r,i=new WeakSet),i.has(n)||(i.add(n),s.requests.push({elementRef:new WeakRef(r),callbackRef:new WeakRef(n)}))}}attach(e){e.addEventListener("context-request",this.onContextRequest),e.addEventListener("context-provider",this.onContextProvider)}detach(e){e.removeEventListener("context-request",this.onContextRequest),e.removeEventListener("context-provider",this.onContextProvider)}};var L=function(t,e,r,n){var s=arguments.length,i=s<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,n);else for(var o=t.length-1;o>=0;o--)(a=t[o])&&(i=(s<3?a(i):s>3?a(e,r,i):a(e,r))||i);return s>3&&i&&Object.defineProperty(e,r,i),i},O=class extends he.FtLitElementRedux{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.apiIntegrationAppVersion="ft-integration-app-version",this.uiLocale="en-US",this.editorMode=!1,this.noCustom=!1,this.openExternalDocumentInNewTab=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.navigatorOnline=!1,this.forcedOffline=!1,this.authenticationRequired=!1,this.messageContexts=[],this.stateManager=Be,this.contextRoot=new qe}render(){return us.html`
|
|
4
4
|
<slot></slot>
|
|
5
5
|
`}connectedCallback(){super.connectedCallback(),this.stateManager.initService(),this.contextRoot.attach(document.body)}disconnectedCallback(){super.disconnectedCallback(),this.contextRoot.detach(document.body)}update(e){var r;super.update(e),e.has("baseUrl")&&this.stateManager.setBaseUrl(this.baseUrl),e.has("apiIntegrationIdentifier")&&this.stateManager.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("apiIntegrationAppVersion")&&this.stateManager.setApiIntegrationAppVersion(this.apiIntegrationAppVersion),e.has("uiLocale")&&this.stateManager.setUiLocale(this.uiLocale),e.has("metadataConfiguration")&&this.stateManager.setMetadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&this.stateManager.setNoCustom(this.noCustom),e.has("editorMode")&&this.stateManager.setEditorMode(this.editorMode),e.has("noCustomComponent")&&this.stateManager.setNoCustomComponent(this.noCustomComponent),e.has("session")&&this.stateManager.setSession(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(n=>es.addContext(n)),e.has("openExternalDocumentInNewTab")&&this.stateManager.setOpenExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&this.stateManager.setNavigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&this.stateManager.setForcedOffline(this.forcedOffline),e.has("authenticationRequired")&&this.stateManager.setAuthenticationRequired(this.authenticationRequired),e.has("withManualResources")&&((r=this.stateManager)===null||r===void 0||r.setWithManualResources(this.withManualResources)),setTimeout(()=>this.stateManager.updateIfNeeded())}};O.elementDefinitions={};O.styles=as;L([(0,N.property)()],O.prototype,"baseUrl",void 0);L([(0,N.property)()],O.prototype,"apiIntegrationIdentifier",void 0);L([(0,N.property)()],O.prototype,"apiIntegrationAppVersion",void 0);L([(0,N.property)()],O.prototype,"uiLocale",void 0);L([(0,he.jsonProperty)(null)],O.prototype,"availableUiLocales",void 0);L([(0,he.jsonProperty)(null)],O.prototype,"metadataConfiguration",void 0);L([(0,N.property)({type:Boolean})],O.prototype,"editorMode",void 0);L([(0,N.property)({type:Boolean})],O.prototype,"noCustom",void 0);L([(0,N.property)({type:Boolean})],O.prototype,"openExternalDocumentInNewTab",void 0);L([(0,N.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],O.prototype,"noCustomComponent",void 0);L([(0,N.property)({type:Boolean})],O.prototype,"withManualResources",void 0);L([(0,N.property)({type:Boolean})],O.prototype,"navigatorOnline",void 0);L([(0,N.property)({type:Boolean})],O.prototype,"forcedOffline",void 0);L([(0,N.property)({type:Boolean})],O.prototype,"authenticationRequired",void 0);L([(0,he.jsonProperty)([])],O.prototype,"messageContexts",void 0);L([(0,he.jsonProperty)(void 0)],O.prototype,"session",void 0);var ls=E(w());var cs={"ft-app-context":O};(0,ls.customElements)(cs);var vt=class extends k{constructor(e){super(!0,e),this.cache.registerFinal("search-configuration",async()=>(await this.awaitApi).getSearchConfiguration())}async launchSearch(e){let r={...e,metadataFilters:this.sortFilters(e.metadataFilters),facets:[...e.facets].sort((n,s)=>n.id.localeCompare(s.id))};return this.cache.get("search-"+this.hash(r),async()=>(await this.awaitApi).search(e),120*1e3)}async launchSuggest(e){let r={...e,metadataFilters:this.sortFilters(e.metadataFilters)};return this.cache.get("suggest-"+this.hash(r),async()=>(await this.awaitApi).getSuggestions(e),120*1e3)}async getAvailableSearchLocales(){return this.cache.get("available-locales",async()=>(await this.awaitApi).getAvailableSearchLocales())}async getConfiguration(){return this.cache.get("search-configuration")}sortFilters(e){return e.map(r=>r.valueFilter==null?r:{...r,valueFilter:{...r.valueFilter,values:[...r.valueFilter.values].sort((n,s)=>n.localeCompare(s))}}).sort((r,n)=>r.key.localeCompare(n.key))}};var yt=class extends CustomEvent{constructor(e){super("ft-search-load-error",{detail:e})}},gt=class extends CustomEvent{constructor(e){super("ft-search-request-change",{detail:e})}},St=class extends CustomEvent{constructor(e,r,n){super("ft-search-results-change",{detail:{request:e,paging:r,spellcheck:n}})}},He=class t extends Event{constructor(){super(t.eventName)}};He.eventName="search-context-clear-all-filters";var gi=t=>t.request.virtualField===me.TITLE_ONLY&&t.request.scope===ve.DOCUMENTS,Si=t=>t.request.keywordMatch==Ke.MANDATORY,Et="ft-recent-queries",Ei=20,Ve=class t extends R.FtStateManager{static build(e,r){return new t(br(e.trim()||"context"),r)}constructor(e,r){super(),this.store=e,this.ignoreEmptyQuery=!1,this.canUpdateUiLocale=!1,this.openExternalDocumentInNewTab=!1,this.onNewNeededRequest=n=>{n==ke.CLUSTERED_SEARCH&&this.launchSearch(this.buildSearchRequest(this.store.getState()))},this.onStorageEvent=n=>{n.key===Et&&this.loadRecentQueries()},this.localesDebouncer=new R.Debouncer(10),this.searchDebouncer=new R.Debouncer(100),this.launchSearch=n=>this.searchDebouncer.run(()=>this.fetchSearchData(n??this.buildSearchRequest(this.store.getState()))),this.buildSearchRequest=n=>({...n.request,facets:this.facetIds.map(s=>({id:s}))}),this.suggestDebouncer=new R.Debouncer(1e3),this.launchSuggest=n=>this.suggestDebouncer.run(()=>this.fetchSuggestData(n??this.buildSuggestRequest(this.store.getState()))),this.buildSuggestRequest=n=>{var s;return{input:n.liveQuery,metadataFilters:n.request.metadataFilters,sort:(s=n.request.sort)!==null&&s!==void 0?s:[],sortId:n.request.sortId,contentLocale:n.request.contentLocale,scope:n.request.scope,keywordMatch:n.request.keywordMatch}},this.service=r??new vt,this.service.cache.addEventListener("clear-cache",n=>{n.detail.clearedKeys.includes("available-locales")&&this.updateLocales()}),this.searchWatcher=(0,R.watch)(e,this.buildSearchRequest,this.launchSearch),this.suggestWatcher=(0,R.watch)(e,this.buildSuggestRequest,this.launchSuggest)}async initService(){return this.updateLocales(),this.service.getConfiguration().then(e=>{this.store.actions.configuration(e),this.setSortId(this.store.getState().request.sortId)}),this.loadRecentQueries(),this.launchSearch()}addWindowListeners(){window.addEventListener("storage",this.onStorageEvent)}removeWindowListeners(){window.removeEventListener("storage",this.onStorageEvent)}updateSearchRequest(e,r=!1){let n=(0,R.deepCopy)(this.store.getState().request);delete n.changedByConfiguration,this.store.actions.setRequest({...n,paging:{perPage:n.paging.perPage,page:r?1:n.paging.page},...e})}setQuery(e){this.updateSearchRequest({query:e},!0),this.setLiveQuery(e)}setContentLocale(e){var r,n;let s=(r=this.store.getState().locales)!==null&&r!==void 0?r:[],i=this.store.getState().request.contentLocale;if(e!=i){if(s.length>0){let a=o=>s.some(c=>c.lang==o);a(e)||(e=a(i)?i:s[0].lang)}this.updateSearchRequest({contentLocale:e,metadataFilters:[]},!0),this.canUpdateUiLocale&&(!((n=Be.localesConfiguration)===null||n===void 0)&&n.searchLanguageSetsUiLanguage)&&e&&Be.requestUiLocaleUpdate(e)}return e}forceContentLocale(e){this.updateSearchRequest({contentLocale:e})}setPageSize(e){let r=this.store.getState().request;this.updateSearchRequest({paging:{...r.paging,perPage:isNaN(e)?20:(0,R.minmax)(1,e,1e3)}})}setPageNumber(e){let r=this.store.getState().request;this.updateSearchRequest({paging:{...r.paging,page:isNaN(e)?1:Math.max(1,e)}})}get sortOptions(){var e,r;return(r=(e=this.store.getState().configuration)===null||e===void 0?void 0:e.sortOptions)!==null&&r!==void 0?r:[]}setSort(e){this.updateSearchRequest({sort:e},!0)}setSortId(e,r=!1){var n;let s=r?{changedByConfiguration:!0}:{};if(e==null||this.sortOptions.length==0)return this.updateSearchRequest({sortId:e,...s},!0),e;let i=(n=this.sortOptions.find(a=>a.id==e))!==null&&n!==void 0?n:this.sortOptions[0];return this.updateSearchRequest({sortId:i.id,...s},!0),i.id}setFilters(e){let r=e.filter(n=>!n.valueFilter||n.valueFilter.values.length>0);this.updateSearchRequest({metadataFilters:r},!0)}setClusterSortCriterion(e){this.updateSearchRequest({clusterSortCriterions:e})}setSearchInDocumentTitlesOnly(e){e?this.updateSearchRequest({virtualField:me.TITLE_ONLY,scope:ve.DOCUMENTS},!0):this.updateSearchRequest({virtualField:me.EVERYWHERE,scope:ve.DEFAULT},!0)}setKeywordMatch(e){this.updateSearchRequest({keywordMatch:e},!0)}setVirtualField(e){this.updateSearchRequest({virtualField:e},!0)}get searchInDocumentTitlesOnly(){return gi(this.store.getState())}get keywordMatch(){return Si(this.store.getState())}clearAllFilters(){this.setFilters([]),this.store.dispatchEvent(new He)}addFacet(e){this.facetIds=[...this.facetIds,e]}replaceFacet(e,r){let n=this.facetIds.filter(s=>s!=e);r&&n.push(r),this.facetIds=n}get facetIds(){var e;let r=this.store.getState().request;return[...new Set([...r.facets.map(n=>n.id),...((e=r.metadataFilters)!==null&&e!==void 0?e:[]).map(n=>n.key)])]}set facetIds(e){let n=[...new Set(e)].map(s=>({id:s}));this.updateSearchRequest({facets:n})}setFilter(e,r){this.setValueFilter(e,r)}setValueFilter(e,r){let n=this.store.getState().request.metadataFilters,s={key:e,valueFilter:{values:r,negative:!1}},i=[...n.filter(a=>!a.valueFilter),...n.filter(a=>a.valueFilter&&a.key!==s.key),s];this.setFilters(i)}setDateFilter(e,r){let n=this.store.getState().request.metadataFilters,s={key:e,dateFilter:{type:r}},i=[...n.filter(a=>!a.dateFilter),...n.filter(a=>a.dateFilter&&a.key!==s.key),s];this.setFilters(i)}removeDateFilter(e){let r=this.store.getState().request.metadataFilters,n=[...r.filter(s=>!s.dateFilter),...r.filter(s=>s.dateFilter&&s.key!==e)];this.setFilters(n)}setRangeFilter(e,r,n){let s=this.store.getState().request.metadataFilters,i={key:e,rangeFilter:{from:r,to:n}},a=[...s.filter(o=>!o.rangeFilter),...s.filter(o=>o.rangeFilter&&o.key!==i.key),i];this.setFilters(a)}removeRangeFilter(e){let r=this.store.getState().request.metadataFilters,n=[...r.filter(s=>!s.rangeFilter),...r.filter(s=>s.rangeFilter&&s.key!==e)];this.setFilters(n)}setLiveQuery(e){this.store.actions.liveQuery(e)}setRequest(e){this.updateSearchRequest({...e,facets:this.store.getState().request.facets},!0),this.setLiveQuery(e.query)}setScope(e){this.updateSearchRequest({scope:e})}setOtherQueryParams(e){this.updateSearchRequest({otherQueryParams:e})}setIgnoreEmptyQuery(e){this.ignoreEmptyQuery=e}setOpenExternalDocumentInNewTab(e){this.openExternalDocumentInNewTab=e}setCanUpdateUiLocale(e){this.canUpdateUiLocale=e}loadRecentQueries(){var e;this.store.actions.recentQueries(JSON.parse((e=window.localStorage.getItem(Et))!==null&&e!==void 0?e:"[]"))}addRecentQuery(e){if(e=e.trim(),e.length===0)return;let r=e.toLowerCase(),n=this.store.getState().recentQueries.filter(s=>s.toLowerCase()!==r).slice(0,Ei-1);n.unshift(e),this.setRecentQueries(n)}removeRecentQuery(e){let r=e.trim().toLowerCase(),n=this.store.getState().recentQueries,s=n.filter(i=>i.toLowerCase()!==r);n.length!==s.length&&this.setRecentQueries(s)}setRecentQueries(e){let r=JSON.stringify(e);window.localStorage.setItem(Et,r),window.dispatchEvent(new StorageEvent("storage",{key:Et,newValue:r,storageArea:window.localStorage,url:window.location.href}))}updateLocales(){return this.localesDebouncer.run(async()=>this.store.actions.locales((await this.service.getAvailableSearchLocales()).contentLocales))}async fetchSearchData(e){var r,n,s,i,a;if((r=this.cancelableSearch)===null||r===void 0||r.cancel(),!!this.isRequestNeeded(ke.CLUSTERED_SEARCH))try{if(this.store.actions.paging(void 0),this.ignoreEmptyQuery&&e.query.length==0)this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0);else{!((n=this.store.getState().results)===null||n===void 0)&&n.length||this.store.actions.results(void 0),this.cancelableSearch=(0,R.cancelable)(this.service.launchSearch(e));let o=await this.cancelableSearch;if(this.store.actions.announcements(o.announcements),o.paging.currentPage<=1)this.store.actions.results(o.results),this.store.actions.facets(o.facets),this.store.actions.spellcheck(o.spellcheck);else{let c=((s=this.store.getState().results)!==null&&s!==void 0?s:[]).concat(o.results);this.store.actions.results(c),this.store.commands.clear(/^focus-result-/),this.store.commands.add({type:`focus-result-${(o.paging.currentPage-1)*((i=e.paging.perPage)!==null&&i!==void 0?i:20)+1}`})}this.store.actions.paging(o.paging)}}catch(o){o instanceof R.CanceledPromiseError||(console.error(o),(a=this.errorHandler)===null||a===void 0||a.call(this,o))}}async fetchSuggestData(e){var r;try{if((r=this.cancelableSuggest)===null||r===void 0||r.cancel(),e.input.length<3){this.store.actions.suggestResults([]);return}this.cancelableSuggest=(0,R.cancelable)(this.service.launchSuggest(e));let n=await this.cancelableSuggest;this.store.actions.suggestResults(n.suggestions)}catch(n){!(n instanceof R.CanceledPromiseError)&&this.errorHandler&&this.errorHandler(n)}}clear(){this.store.clear()}clearResults(){this.store.actions.paging(void 0),this.store.actions.results(void 0),this.store.actions.announcements(void 0),this.store.actions.facets(void 0),this.store.actions.spellcheck(void 0)}};var ds=function(t,e,r,n){var s=arguments.length,i=s<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,n);else for(var o=t.length-1;o>=0;o--)(a=t[o])&&(i=(s<3?a(i):s>3?a(e,r,i):a(e,r))||i);return s>3&&i&&Object.defineProperty(e,r,i),i},dr=class extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}},hs=Symbol("registerInterval"),cr=Symbol("registerAttempts"),bi=40,Ai=(0,we.applyMixinOnce)(Symbol("toFtSearchComponent"),function(t){class e extends t{constructor(){super(...arguments),this.neededSearchRequests=[]}willUpdate(n){var s,i,a;super.willUpdate(n),n.has("neededSearchRequests")&&((s=this.stateManager)===null||s===void 0||s.unregisterComponent(this,(i=n.get("neededSearchRequests"))!==null&&i!==void 0?i:[]),(a=this.stateManager)===null||a===void 0||a.registerComponent(this,this.neededSearchRequests))}setSearchStateManager(n){this.clearStateManager(),this.stateManager=n,this.stateManager.registerComponent(this,this.neededSearchRequests),this.addStore(n.store,"search")}clearStateManager(){this.stateManager&&(this.stateManager.unregisterComponent(this,this.neededSearchRequests),this.removeStore(this.stateManager.store),this.stateManager=void 0)}connectedCallback(){super.connectedCallback(),this[cr]=0,this.tryToRegisterToContext(),this[hs]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null||this[cr]>bi?window.clearInterval(this[hs]):(this[cr]++,this.dispatchEvent(new dr))}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return ds([(0,lr.state)()],e.prototype,"stateManager",void 0),ds([(0,lr.state)({hasChanged:we.hasChanged})],e.prototype,"neededSearchRequests",void 0),e}),ps=class extends Ai(we.FtLitElementRedux){};var xt=E(w());function bt(t){return t.filter(e=>e.key==="ft:lastEdition").filter(e=>!e.valueFilter).map(e=>e.dateFilter?e.dateFilter.type:"CUSTOM").shift()}function At(t){var e,r;return t.dateFilter?{key:t.key,type:"DATE",dateValue:t.dateFilter.type}:t.rangeFilter?{key:t.key,type:"RANGE",from:t.rangeFilter.from,to:t.rangeFilter.to}:{key:t.key,values:(e=t.valueFilter)===null||e===void 0?void 0:e.values,negative:(r=t.valueFilter)===null||r===void 0?void 0:r.negative}}var Ct=class{constructor(e,r){this.store=e,this.ignoreEmptyQuery=!1,this.openExternalDocumentInNewTab=!1,this.enableAnalyticsEvents=!0,this.appName=void 0,this.appVersion=void 0,this.document=void 0,this.sendEvent=([n,s])=>{if(!this.canSendEvent()||!n||!s)return;let i=this.store.getState().request;this.document==null?this.sendKhubSearchEvent(i,n,s):this.sendDocumentSearchEvent(i,n,s)},this.eventsService=r??new pt,this.resultsWatcher=(0,xt.watch)(e,n=>[n.results,n.paging],this.sendEvent)}setEnableAnalyticsEvents(e){this.enableAnalyticsEvents=e}setAppName(e){this.appName=e}setAppVersion(e){this.appVersion=e}setDocumentSearch(e){this.document=e}setDocumentSearchFromMap(e){this.setDocumentSearch(this.eventsService.convertMapToAnalyticsDocument(e))}initAppInfo(){let{apiIntegrationIdentifier:e,apiIntegrationAppVersion:r}=v.getState();this.setAppName(e??"unknown"),this.setAppVersion(r??"unknown")}canSendEvent(){if(this.appName==null||this.appVersion==null)return console.debug("ft-search-context.eventManager is not initialized. No events will be sent!"),!1;let{editorMode:e}=v.getState();return this.enableAnalyticsEvents&&!e}sendKhubSearchEvent(e,r,n){let s={offline:!1,appVersion:this.appVersion,appName:this.appName,name:ne.KHUB__SEARCH,searchResponse:{autocorrect:this.store.getState().spellcheck!=null,nbResults:n.totalClustersCount},searchQuery:{terms:e.query,searchType:e.virtualField,lastUpdate:bt(e.metadataFilters),facets:e.metadataFilters.map(i=>At(i))}};this.eventsService.sendKhubSearchEvent(s)}sendDocumentSearchEvent(e,r,n){if(e.metadataFilters.find(i=>{var a;return i.key==="ft:publicationId"&&((a=i.valueFilter)===null||a===void 0?void 0:a.values[0])===this.document.id})!==void 0){let i={offline:!1,appVersion:this.appVersion,appName:this.appName,name:ne.DOCUMENT__SEARCH,searchResponse:{autocorrect:this.store.getState().spellcheck!=null,nbResults:n.totalClustersCount},searchQuery:{terms:e.query},document:this.document};this.eventsService.sendDocumentSearchEvent(i)}}sendResultClickedEvent(e,r){if(!this.canSendEvent())return;let n=this.store.getState().request,s;e.type==H.TOPIC&&(s={tocId:e.topic.tocId,title:e.topic.title});let i={offline:!1,appVersion:this.appVersion,appName:this.appName,name:ne.SEARCH_PAGE__SELECT,searchQuery:{terms:n.query,searchType:n.virtualField,lastUpdate:bt(n.metadataFilters),facets:n.metadataFilters.map(a=>At(a))},searchResult:{rank:r,type:e.type,document:this.convertDocument(e),topic:s},externalLink:this.convertExternalLink(e)};this.eventsService.sendSearchPageSelectEvent(i)}sendResultContextMenuOpenedEvent(e,r){if(!this.canSendEvent())return;let n=this.store.getState().request,s;e.type==H.TOPIC&&(s={tocId:e.topic.tocId,title:e.topic.title});let i={offline:!1,appVersion:this.appVersion,appName:this.appName,name:ne.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU,searchQuery:{terms:n.query,searchType:n.virtualField,lastUpdate:bt(n.metadataFilters),facets:n.metadataFilters.map(a=>At(a))},searchResult:{rank:r,type:e.type,document:this.convertDocument(e),topic:s},externalLink:this.convertExternalLink(e)};this.eventsService.sendSearchResultOpenContextMenuEvent(i)}convertDocument(e){switch(e.type){case H.MAP:return{id:e.map.mapId,title:e.map.title,type:X.STRUCTURED_DOCUMENT,metadata:e.map.metadata};case H.TOPIC:return{id:e.topic.mapId,title:e.topic.mapTitle,type:X.STRUCTURED_DOCUMENT,metadata:e.topic.metadata};case H.DOCUMENT:return{id:e.document.documentId,title:e.document.title,type:X.UNSTRUCTURED_DOCUMENT,metadata:e.document.metadata,mimeType:e.document.mimeType};case H.HTML_PACKAGE:return{id:e.htmlPackage.packageId,title:e.htmlPackage.title,type:X.HTML_PACKAGE,metadata:e.htmlPackage.metadata};case H.HTML_PACKAGE_PAGE:return{id:e.htmlPackagePage.packageId,title:e.htmlPackagePage.title,type:X.HTML_PACKAGE,metadata:e.htmlPackagePage.metadata};default:throw new TypeError("Unknown type "+e.type)}}convertExternalLink(e){var r;return(r=(0,xt.accessResult)(e))===null||r===void 0?void 0:r.originUrl}};var _=function(t,e,r,n){var s=arguments.length,i=s<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,n);else for(var o=t.length-1;o>=0;o--)(a=t[o])&&(i=(s<3?a(i):s>3?a(e,r,i):a(e,r))||i);return s>3&&i&&Object.defineProperty(e,r,i),i},A=class extends D.FtLitElementRedux{get stateManager(){if(this._stateManager==null){let e=this.searchServiceProvider?this.searchServiceProvider():void 0;this._stateManager=Ve.build(this.id||(""+Math.round(Math.random()*999e3)).padStart(6,"0"),e),this._stateManager.errorHandler=r=>this.handleLoadError(r),this.addStore(this.stateManager.store,"search")}return this._stateManager}get eventManager(){return this._eventManager==null&&(this._eventManager=new Ct(this.stateManager.store)),this._eventManager}constructor(){super(),this.query="",this.pageSize=20,this.searchInDocumentTitlesOnly=!1,this.ignoreEmptyQuery=!1,this.openExternalDocumentInNewTab=!1,this.filters=[],this.sort=[],this.otherQueryParams={},this._appIntegrationInfoReady=!1,this.addStore(v)}render(){return fs.html`
|