@fluid-topics/ft-reader-topic-content 1.1.21 → 1.1.22
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.
|
@@ -9,7 +9,7 @@ export declare class FtReaderTopicContent extends FtReaderTopicComponent impleme
|
|
|
9
9
|
private content?;
|
|
10
10
|
private error?;
|
|
11
11
|
private searchInDocumentQuery?;
|
|
12
|
-
contentPreprocessor: (content: string) => string;
|
|
12
|
+
contentPreprocessor: (content: string) => Promise<string> | string;
|
|
13
13
|
onContentAvailable: (container: HTMLElement, shadowRoot: ShadowRoot) => void;
|
|
14
14
|
private topicContainer?;
|
|
15
15
|
protected render(): import("lit").TemplateResult<1>;
|
|
@@ -51,11 +51,11 @@ class FtReaderTopicContent extends FtReaderTopicComponent {
|
|
|
51
51
|
this.error = undefined;
|
|
52
52
|
this.content = undefined;
|
|
53
53
|
if (this.map && this.tocNode) {
|
|
54
|
-
(_a = this.service) === null || _a === void 0 ? void 0 : _a.getTopicContent(this.tocNode).then(content => this.content
|
|
54
|
+
(_a = this.service) === null || _a === void 0 ? void 0 : _a.getTopicContent(this.tocNode).then(content => this.contentPreprocessor(content || "<div class=\"empty-topic\"></div>")).then(content => this.content = content).catch(e => this.error = e);
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
57
|
contentAvailableCallback(props) {
|
|
58
|
-
var _a, _b, _c, _d, _e, _f;
|
|
58
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
59
59
|
super.contentAvailableCallback(props);
|
|
60
60
|
if (!this.disableContextInteractions && ((_a = this.scrollTarget) === null || _a === void 0 ? void 0 : _a.section) && ((_b = this.tocNode) === null || _b === void 0 ? void 0 : _b.tocId) && ((_c = this.tocNode) === null || _c === void 0 ? void 0 : _c.tocId) === this.scrollTarget.tocId && this.content) {
|
|
61
61
|
const target = (_e = (_d = this.shadowRoot) === null || _d === void 0 ? void 0 : _d.querySelector(`[id="${this.scrollTarget.section}"], [name="${this.scrollTarget.section}"]`)) !== null && _e !== void 0 ? _e : this;
|
|
@@ -66,6 +66,9 @@ class FtReaderTopicContent extends FtReaderTopicComponent {
|
|
|
66
66
|
this.onContentAvailable(this.topicContainer, this.shadowRoot);
|
|
67
67
|
this.moveSvgInShadowRoot();
|
|
68
68
|
}
|
|
69
|
+
if ((props.has("content") && this.content) || (props.has("error") && this.error)) {
|
|
70
|
+
performance.mark("fluid_topics__reader_topic_displayed__" + ((_g = this.tocNode) === null || _g === void 0 ? void 0 : _g.tocId));
|
|
71
|
+
}
|
|
69
72
|
}
|
|
70
73
|
moveSvgInShadowRoot() {
|
|
71
74
|
this.shadowRoot.querySelectorAll(".ft-svg-container").forEach(svgContainer => {
|
|
@@ -98,7 +101,7 @@ class FtReaderTopicContent extends FtReaderTopicComponent {
|
|
|
98
101
|
const customClasses = (_b = (_a = this.map) === null || _a === void 0 ? void 0 : _a.contentStyles.customCssClasses.join(" ")) !== null && _b !== void 0 ? _b : "";
|
|
99
102
|
return html `
|
|
100
103
|
<div class="depth-${(_c = this.tocNode) === null || _c === void 0 ? void 0 : _c.depth} content-locale-${(_d = this.map) === null || _d === void 0 ? void 0 : _d.lang} ${customClasses}">
|
|
101
|
-
${this.content != null ? unsafeHTML(`${this.
|
|
104
|
+
${this.content != null ? unsafeHTML(`${this.content}`) : nothing}
|
|
102
105
|
</div>
|
|
103
106
|
`;
|
|
104
107
|
}
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
`,$=i.css`
|
|
73
73
|
`,M=e.FtReduxStore.get({name:"ft-app-info",reducers:{},initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],metadataConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,session:void 0}});class U{static build(t){const{baseUrl:e,apiIntegrationIdentifier:i}=M.getState(),s=null!=t?t:i;if(e&&s&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(e,s,!0)}static get(t){var e;return null!=t?U.build(t):null!==(e=U.API)&&void 0!==e?e:U.API=U.build()}static await(t){return new Promise((e=>{let i=U.get(t);if(i)e(i);else{const s=M.subscribe((()=>{i=U.get(t),i&&(s(),e(i))}))}}))}}var N;const T=Symbol("clearAfterUnitTest");class A{constructor(t){this.messageContextProvider=t,this.defaultMessages={},this.cache=new e.CacheRegistry,this.listeners={},this.currentUiLocale="",this[N]=()=>{this.defaultMessages={},this.cache=new e.CacheRegistry,this.listeners={}},this.currentUiLocale=M.getState().uiLocale,M.subscribe((()=>this.clearWhenUiLocaleChanges()))}clearWhenUiLocaleChanges(){const{uiLocale:t}=M.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){const e=t.name.toLowerCase();this.cache.setFinal(e,t),this.notify(e)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,i){var s;if(t=t.toLowerCase(),Object.keys(i).length>0){const o={...null!==(s=this.defaultMessages[t])&&void 0!==s?s:{},...i};e.deepEqual(this.defaultMessages[t],o)||(this.defaultMessages[t]=o,await this.notify(t))}await this.fetchContext(t)}resolveMessage(t,i,...s){var o,n,a;t=t.toLowerCase(),this.fetchContext(t);const r=null!==(n=null===(o=this.cache.getNow(t))||void 0===o?void 0:o.messages)&&void 0!==n?n:{};return new e.ParametrizedLabelResolver(null!==(a=this.defaultMessages[t])&&void 0!==a?a:{},r).resolve(i,...s)}async fetchContext(t){if(!this.cache.has(t))try{await this.cache.get(t,(()=>this.messageContextProvider(this.currentUiLocale,t))),await this.notify(t)}catch(t){console.error(t)}}subscribe(t,e){var i;return t=t.toLowerCase(),this.listeners[t]=null!==(i=this.listeners[t])&&void 0!==i?i:new Set,this.listeners[t].add(e),()=>{var i;return null===(i=this.listeners[t])||void 0===i?void 0:i.delete(e)}}async notifyAll(){await Promise.all(Object.keys(this.listeners).map((t=>this.notify(t))))}async notify(t){null!=this.listeners[t]&&await Promise.all([...this.listeners[t].values()].map((t=>e.delay(0).then((()=>t())).catch((()=>null)))))}}N=T,null==window.FluidTopicsI18nService&&(window.FluidTopicsI18nService=new A((async(t,e)=>(await U.await()).getFluidTopicsMessageContext(t,e)))),null==window.FluidTopicsCustomI18nService&&(window.FluidTopicsCustomI18nService=new A((async(t,e)=>(await U.await()).getCustomMessageContext(t,e))));const L=window.FluidTopicsI18nService,B=window.FluidTopicsCustomI18nService;var z=function(t,e,i,s){for(var o,n=arguments.length,a=n<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,r=t.length-1;r>=0;r--)(o=t[r])&&(a=(n<3?o(a):n>3?o(e,i,a):o(e,i))||a);return n>3&&a&&Object.defineProperty(e,i,a),a};class P extends e.FtLitElement{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.editorMode=!1,this.noCustom=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.messageContexts=[],this.apiProvider=()=>U.get(),this.cache=new e.CacheRegistry,this.cleanSessionDebouncer=new e.Debouncer}render(){return i.html`
|
|
74
74
|
<slot></slot>
|
|
75
|
-
`}update(t){super.update(t),t.has("baseUrl")&&M.actions.baseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&M.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&M.actions.uiLocale(this.uiLocale),t.has("metadataConfiguration")&&M.actions.metadataConfiguration(this.metadataConfiguration),t.has("noCustom")&&M.actions.noCustom(this.noCustom),t.has("editorMode")&&M.actions.editorMode(this.editorMode),t.has("noCustomComponent")&&M.actions.noCustomComponent(this.noCustomComponent),t.has("session")&&M.actions.session(this.session),t.has("availableUiLocales")&&M.actions.availableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>L.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){!this.withManualResources&&this.apiProvider()&&(null==this.session&&this.updateSession(),null==this.availableUiLocales&&this.updateUiLocales(),null==this.metadataConfiguration&&this.updateMetadataConfiguration())}async updateSession(){this.session=await this.cache.get("session",(async()=>{const t=await this.apiProvider().getCurrentSession();return t.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),t.idleTimeoutInMillis),t}))}async updateUiLocales(){this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>this.apiProvider().getAvailableUiLocales()))}async updateMetadataConfiguration(){this.metadataConfiguration=await this.cache.get("metadataConfiguration",(()=>this.apiProvider().getMetadataConfiguration()))}}P.elementDefinitions={},P.styles=$,z([s.property()],P.prototype,"baseUrl",void 0),z([s.property()],P.prototype,"apiIntegrationIdentifier",void 0),z([s.property()],P.prototype,"uiLocale",void 0),z([e.jsonProperty(null)],P.prototype,"availableUiLocales",void 0),z([e.jsonProperty(null)],P.prototype,"metadataConfiguration",void 0),z([s.property({type:Boolean})],P.prototype,"editorMode",void 0),z([s.property({type:Boolean})],P.prototype,"noCustom",void 0),z([s.property({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],P.prototype,"noCustomComponent",void 0),z([s.property({type:Boolean})],P.prototype,"withManualResources",void 0),z([e.jsonProperty([])],P.prototype,"messageContexts",void 0),z([e.jsonProperty(void 0)],P.prototype,"session",void 0),z([s.property({type:Object})],P.prototype,"apiProvider",void 0);class R{async listMySearches(){var t;return(null===(t=M.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await U.await()).listMySearches(M.getState().session.profile.userId):[]}}const
|
|
75
|
+
`}update(t){super.update(t),t.has("baseUrl")&&M.actions.baseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&M.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&M.actions.uiLocale(this.uiLocale),t.has("metadataConfiguration")&&M.actions.metadataConfiguration(this.metadataConfiguration),t.has("noCustom")&&M.actions.noCustom(this.noCustom),t.has("editorMode")&&M.actions.editorMode(this.editorMode),t.has("noCustomComponent")&&M.actions.noCustomComponent(this.noCustomComponent),t.has("session")&&M.actions.session(this.session),t.has("availableUiLocales")&&M.actions.availableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>L.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){!this.withManualResources&&this.apiProvider()&&(null==this.session&&this.updateSession(),null==this.availableUiLocales&&this.updateUiLocales(),null==this.metadataConfiguration&&this.updateMetadataConfiguration())}async updateSession(){this.session=await this.cache.get("session",(async()=>{const t=await this.apiProvider().getCurrentSession();return t.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),t.idleTimeoutInMillis),t}))}async updateUiLocales(){this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>this.apiProvider().getAvailableUiLocales()))}async updateMetadataConfiguration(){this.metadataConfiguration=await this.cache.get("metadataConfiguration",(()=>this.apiProvider().getMetadataConfiguration()))}}P.elementDefinitions={},P.styles=$,z([s.property()],P.prototype,"baseUrl",void 0),z([s.property()],P.prototype,"apiIntegrationIdentifier",void 0),z([s.property()],P.prototype,"uiLocale",void 0),z([e.jsonProperty(null)],P.prototype,"availableUiLocales",void 0),z([e.jsonProperty(null)],P.prototype,"metadataConfiguration",void 0),z([s.property({type:Boolean})],P.prototype,"editorMode",void 0),z([s.property({type:Boolean})],P.prototype,"noCustom",void 0),z([s.property({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],P.prototype,"noCustomComponent",void 0),z([s.property({type:Boolean})],P.prototype,"withManualResources",void 0),z([e.jsonProperty([])],P.prototype,"messageContexts",void 0),z([e.jsonProperty(void 0)],P.prototype,"session",void 0),z([s.property({type:Object})],P.prototype,"apiProvider",void 0);class R{async listMySearches(){var t;return(null===(t=M.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await U.await()).listMySearches(M.getState().session.profile.userId):[]}}const _=new e.CacheRegistry;class E{async listMyBookmarks(){return _.get("bookmarks",(async()=>(await U.await()).listMyBookmarks(M.getState().session.profile.userId)))}clearCache(){_.clear("bookmarks")}}const K=e.FtReduxStore.get({name:"ft-user-assets",initialState:{savedSearches:void 0,bookmarks:void 0}});new class{constructor(){this.currentSession=M.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new E,M.subscribe((()=>this.reloadWhenUserSessionChanges()))}reloadWhenUserSessionChanges(){var t;const{session:i}=M.getState();e.deepEqual(null===(t=this.currentSession)||void 0===t?void 0:t.profile,null==i?void 0:i.profile)||(this.currentSession=i,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){K.actions.savedSearches(void 0)}clearMyBookmarks(){K.actions.bookmarks(void 0)}async reloadMySearches(){const t=new R,e=await t.listMySearches();K.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){const e=(null===(t=this.currentSession)||void 0===t?void 0:t.sessionAuthenticated)?await this.bookmarksService.listMyBookmarks():void 0;K.actions.bookmarks(e)}}},e.customElement("ft-app-context")(P);var G=function(t,e,i,s){for(var o,n=arguments.length,a=n<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,r=t.length-1;r>=0;r--)(o=t[r])&&(a=(n<3?o(a):n>3?o(e,i,a):o(e,i))||a);return n>3&&a&&Object.defineProperty(e,i,a),a};const W=Symbol("i18nProperties"),D=Symbol("i18nUnsubs");function q(t){var e;class i extends t{constructor(){super(...arguments),this.useCustomMessageContexts=!1,this[e]=new Map}get i18nService(){return this.useCustomMessageContexts?B:L}i18n(t,e,...i){var s;if("string"==typeof t)return this.i18nService.resolveMessage(t,e,...i);const o=null!==(s=t.args)&&void 0!==s?s:t.argsProvider?t.argsProvider(this):[];return this.i18nService.resolveMessage(t.context,t.key,...o)}onI18nUpdate(t){var e;null===(e=this[W])||void 0===e||e.forEach(((e,i)=>{e.context.toLowerCase()===t.toLowerCase()&&(this[i]=this.i18n(e))})),setTimeout((()=>this.requestUpdate()),0)}update(t){var e;super.update(t),null===(e=this[W])||void 0===e||e.forEach(((t,e)=>{null!=t.argsProvider&&(this[e]=this.i18n(t))}))}connectedCallback(){super.connectedCallback(),null!=this[W]&&new Set([...this[W].values()].map((t=>t.context))).forEach((t=>this.addI18nMessages(t)))}addI18nMessages(t,e){t=t.toLowerCase(),this[D].has(t)||this[D].set(t,this.i18nService.subscribe(t,(()=>this.onI18nUpdate(t)))),this.i18nService.prepareContext(t,null!=e?e:{})}addI18nContext(t,e){this.addI18nMessages(t.name,e)}disconnectedCallback(){super.disconnectedCallback(),this[D].forEach((t=>t())),this[D].clear()}}return e=D,G([s.property({type:Boolean})],i.prototype,"useCustomMessageContexts",void 0),i}class F extends(q(e.FtLitElement)){}class Q extends(q(e.FtLitElementRedux)){}var Z=function(t,e,i,s){for(var o,n=arguments.length,a=n<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,r=t.length-1;r>=0;r--)(o=t[r])&&(a=(n<3?o(a):n>3?o(e,i,a):o(e,i))||a);return n>3&&a&&Object.defineProperty(e,i,a),a};class H extends Q{constructor(){super(),this.editorMode=!1,this.addStore(M)}render(){return this.key&&this.context?i.html`
|
|
76
76
|
<span class="ft-i18n">
|
|
77
77
|
${this.i18n(this.context,this.key,...Array.isArray(this.args)?this.args:[])}
|
|
78
78
|
</span>
|
|
@@ -85,7 +85,7 @@
|
|
|
85
85
|
</section>
|
|
86
86
|
`:i.html`
|
|
87
87
|
<section class="topic-loading"></section>
|
|
88
|
-
`}update(t){super.update(t),(t.has("map")||t.has("tocNode"))&&this.updateContent()}updated(t){super.updated(t),this.updateComplete.then((()=>e.waitFor((()=>this.topicContainer)))).then((t=>e.highlightHtml(t,this.searchInDocumentQuery)))}updateContent(){var t;this.error=void 0,this.content=void 0,this.map&&this.tocNode&&(null===(t=this.service)||void 0===t||t.getTopicContent(this.tocNode).then((t=>this.
|
|
88
|
+
`}update(t){super.update(t),(t.has("map")||t.has("tocNode"))&&this.updateContent()}updated(t){super.updated(t),this.updateComplete.then((()=>e.waitFor((()=>this.topicContainer)))).then((t=>e.highlightHtml(t,this.searchInDocumentQuery)))}updateContent(){var t;this.error=void 0,this.content=void 0,this.map&&this.tocNode&&(null===(t=this.service)||void 0===t||t.getTopicContent(this.tocNode).then((t=>this.contentPreprocessor(t||'<div class="empty-topic"></div>'))).then((t=>this.content=t)).catch((t=>this.error=t)))}contentAvailableCallback(t){var e,i,s,o,n,a,r;if(super.contentAvailableCallback(t),!this.disableContextInteractions&&(null===(e=this.scrollTarget)||void 0===e?void 0:e.section)&&(null===(i=this.tocNode)||void 0===i?void 0:i.tocId)&&(null===(s=this.tocNode)||void 0===s?void 0:s.tocId)===this.scrollTarget.tocId&&this.content){(null!==(n=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelector(`[id="${this.scrollTarget.section}"], [name="${this.scrollTarget.section}"]`))&&void 0!==n?n:this).scrollIntoView({block:"start"}),null===(a=this.stateManager)||void 0===a||a.scrollDone()}this.topicContainer&&(this.onContentAvailable(this.topicContainer,this.shadowRoot),this.moveSvgInShadowRoot()),(t.has("content")&&this.content||t.has("error")&&this.error)&&performance.mark("fluid_topics__reader_topic_displayed__"+(null===(r=this.tocNode)||void 0===r?void 0:r.tocId))}moveSvgInShadowRoot(){this.shadowRoot.querySelectorAll(".ft-svg-container").forEach((t=>{if(!t.shadowRoot){var e=t.innerHTML;t.innerHTML="";var i=t.attachShadow({mode:"open"}),s=document.createRange().createContextualFragment(e),o=document.importNode(s,!0);i.append(o)}}))}onStoreAvailable(){super.onStoreAvailable(),this.updateContent()}renderTopicContent(){var t,e,s,n;if(this.error)return i.html`
|
|
89
89
|
<div class="topic-on-error">
|
|
90
90
|
<ft-icon>WARNING</ft-icon>
|
|
91
91
|
<div>
|
|
@@ -94,6 +94,6 @@
|
|
|
94
94
|
</div>
|
|
95
95
|
`;const a=null!==(e=null===(t=this.map)||void 0===t?void 0:t.contentStyles.customCssClasses.join(" "))&&void 0!==e?e:"";return i.html`
|
|
96
96
|
<div class="depth-${null===(s=this.tocNode)||void 0===s?void 0:s.depth} content-locale-${null===(n=this.map)||void 0===n?void 0:n.lang} ${a}">
|
|
97
|
-
${null!=this.content?o.unsafeHTML(`${this.
|
|
97
|
+
${null!=this.content?o.unsafeHTML(`${this.content}`):i.nothing}
|
|
98
98
|
</div>
|
|
99
99
|
`}is404Error(){return 404===this.error.status}}Y.styles=[a,e.highlightHtmlStyles],X([e.redux()],Y.prototype,"map",void 0),X([e.redux()],Y.prototype,"scrollTarget",void 0),X([s.state()],Y.prototype,"content",void 0),X([s.state()],Y.prototype,"error",void 0),X([e.redux({selector:(t,e)=>e.disableContextInteractions?"":t.searchInDocumentQuery})],Y.prototype,"searchInDocumentQuery",void 0),X([s.property({attribute:!1})],Y.prototype,"contentPreprocessor",void 0),X([s.property({attribute:!1})],Y.prototype,"onContentAvailable",void 0),X([s.query("section.topic")],Y.prototype,"topicContainer",void 0),e.customElement("ft-reader-topic-content")(Y),t.FtReaderTopicContent=Y,t.FtReaderTopicContentCssVariables=n,t.styles=a}({},ftGlobals.wcUtils,ftGlobals.lit,ftGlobals.litDecorators,ftGlobals.litUnsafeHTML);
|
|
@@ -48,7 +48,7 @@ const E={attribute:!0,type:String,converter:w,reflect:!1,hasChanged:N},R=(t=E,e,
|
|
|
48
48
|
* @license
|
|
49
49
|
* Copyright 2017 Google LLC
|
|
50
50
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
51
|
-
*/const M=globalThis,Z=M.trustedTypes,P=Z?Z.createPolicy("lit-html",{createHTML:t=>t}):void 0,F="$lit$",B=`lit$${(Math.random()+"").slice(9)}$`,T="?"+B,
|
|
51
|
+
*/const M=globalThis,Z=M.trustedTypes,P=Z?Z.createPolicy("lit-html",{createHTML:t=>t}):void 0,F="$lit$",B=`lit$${(Math.random()+"").slice(9)}$`,T="?"+B,_=`<${T}>`,D=document,z=()=>D.createComment(""),G=t=>null===t||"object"!=typeof t&&"function"!=typeof t,H=Array.isArray,q="[ \t\n\f\r]",J=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Y=/-->/g,V=/>/g,X=RegExp(`>|${q}(?:([^\\s"'>=/]+)(${q}*=${q}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),Q=/'/g,tt=/"/g,et=/^(?:script|style|textarea|title)$/i,ot=Symbol.for("lit-noChange"),rt=Symbol.for("lit-nothing"),it=new WeakMap,nt=D.createTreeWalker(D,129);function at(t,e){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==P?P.createHTML(e):e}let st=class t{constructor({strings:e,_$litType$:o},r){let i;this.parts=[];let n=0,a=0;const s=e.length-1,c=this.parts,[l,f]=((t,e)=>{const o=t.length-1,r=[];let i,n=2===e?"<svg>":"",a=J;for(let e=0;e<o;e++){const o=t[e];let s,c,l=-1,f=0;for(;f<o.length&&(a.lastIndex=f,c=a.exec(o),null!==c);)f=a.lastIndex,a===J?"!--"===c[1]?a=Y:void 0!==c[1]?a=V:void 0!==c[2]?(et.test(c[2])&&(i=RegExp("</"+c[2],"g")),a=X):void 0!==c[3]&&(a=X):a===X?">"===c[0]?(a=i??J,l=-1):void 0===c[1]?l=-2:(l=a.lastIndex-c[2].length,s=c[1],a=void 0===c[3]?X:'"'===c[3]?tt:Q):a===tt||a===Q?a=X:a===Y||a===V?a=J:(a=X,i=void 0);const h=a===X&&t[e+1].startsWith("/>")?" ":"";n+=a===J?o+_:l>=0?(r.push(s),o.slice(0,l)+F+o.slice(l)+B+h):o+B+(-2===l?e:h)}return[at(t,n+(t[o]||"<?>")+(2===e?"</svg>":"")),r]})(e,o);if(this.el=t.createElement(l,r),nt.currentNode=this.el.content,2===o){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(i=nt.nextNode())&&c.length<s;){if(1===i.nodeType){if(i.hasAttributes())for(const t of i.getAttributeNames())if(t.endsWith(F)){const e=f[a++],o=i.getAttribute(t).split(B),r=/([.?@])?(.*)/.exec(e);c.push({type:1,index:n,name:r[2],strings:o,ctor:"."===r[1]?ht:"?"===r[1]?ut:"@"===r[1]?dt:ft}),i.removeAttribute(t)}else t.startsWith(B)&&(c.push({type:6,index:n}),i.removeAttribute(t));if(et.test(i.tagName)){const t=i.textContent.split(B),e=t.length-1;if(e>0){i.textContent=Z?Z.emptyScript:"";for(let o=0;o<e;o++)i.append(t[o],z()),nt.nextNode(),c.push({type:2,index:++n});i.append(t[e],z())}}}else if(8===i.nodeType)if(i.data===T)c.push({type:2,index:n});else{let t=-1;for(;-1!==(t=i.data.indexOf(B,t+1));)c.push({type:7,index:n}),t+=B.length-1}n++}}static createElement(t,e){const o=D.createElement("template");return o.innerHTML=t,o}};function ct(t,e,o=t,r){if(e===ot)return e;let i=void 0!==r?o._$Co?.[r]:o._$Cl;const n=G(e)?void 0:e._$litDirective$;return i?.constructor!==n&&(i?._$AO?.(!1),void 0===n?i=void 0:(i=new n(t),i._$AT(t,o,r)),void 0!==r?(o._$Co??=[])[r]=i:o._$Cl=i),void 0!==i&&(e=ct(t,i._$AS(t,e.values),i,r)),e}let lt=class t{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,o,r){this.type=2,this._$AH=rt,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=o,this.options=r,this._$Cv=r?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t?.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=ct(this,t,e),G(t)?t===rt||null==t||""===t?(this._$AH!==rt&&this._$AR(),this._$AH=rt):t!==this._$AH&&t!==ot&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>H(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==rt&&G(this._$AH)?this._$AA.nextSibling.data=t:this.$(D.createTextNode(t)),this._$AH=t}g(t){const{values:e,_$litType$:o}=t,r="number"==typeof o?this._$AC(t):(void 0===o.el&&(o.el=st.createElement(at(o.h,o.h[0]),this.options)),o);if(this._$AH?._$AD===r)this._$AH.p(e);else{const t=new class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:o}=this._$AD,r=(t?.creationScope??D).importNode(e,!0);nt.currentNode=r;let i=nt.nextNode(),n=0,a=0,s=o[0];for(;void 0!==s;){if(n===s.index){let e;2===s.type?e=new lt(i,i.nextSibling,this,t):1===s.type?e=new s.ctor(i,s.name,s.strings,this,t):6===s.type&&(e=new pt(i,this,t)),this._$AV.push(e),s=o[++a]}n!==s?.index&&(i=nt.nextNode(),n++)}return nt.currentNode=D,r}p(t){let e=0;for(const o of this._$AV)void 0!==o&&(void 0!==o.strings?(o._$AI(t,o,e),e+=o.strings.length-2):o._$AI(t[e])),e++}}(r,this),o=t.u(this.options);t.p(e),this.$(o),this._$AH=t}}_$AC(t){let e=it.get(t.strings);return void 0===e&&it.set(t.strings,e=new st(t)),e}T(e){H(this._$AH)||(this._$AH=[],this._$AR());const o=this._$AH;let r,i=0;for(const n of e)i===o.length?o.push(r=new t(this.k(z()),this.k(z()),this,this.options)):r=o[i],r._$AI(n),i++;i<o.length&&(this._$AR(r&&r._$AB.nextSibling,i),o.length=i)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t&&t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}},ft=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,o,r,i){this.type=1,this._$AH=rt,this._$AN=void 0,this.element=t,this.name=e,this._$AM=r,this.options=i,o.length>2||""!==o[0]||""!==o[1]?(this._$AH=Array(o.length-1).fill(new String),this.strings=o):this._$AH=rt}_$AI(t,e=this,o,r){const i=this.strings;let n=!1;if(void 0===i)t=ct(this,t,e,0),n=!G(t)||t!==this._$AH&&t!==ot,n&&(this._$AH=t);else{const r=t;let a,s;for(t=i[0],a=0;a<i.length-1;a++)s=ct(this,r[o+a],e,a),s===ot&&(s=this._$AH[a]),n||=!G(s)||s!==this._$AH[a],s===rt?t=rt:t!==rt&&(t+=(s??"")+i[a+1]),this._$AH[a]=s}n&&!r&&this.O(t)}O(t){t===rt?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},ht=class extends ft{constructor(){super(...arguments),this.type=3}O(t){this.element[this.name]=t===rt?void 0:t}},ut=class extends ft{constructor(){super(...arguments),this.type=4}O(t){this.element.toggleAttribute(this.name,!!t&&t!==rt)}},dt=class extends ft{constructor(t,e,o,r,i){super(t,e,o,r,i),this.type=5}_$AI(t,e=this){if((t=ct(this,t,e,0)??rt)===ot)return;const o=this._$AH,r=t===rt&&o!==rt||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,i=t!==rt&&(o===rt||r);r&&this.element.removeEventListener(this.name,this,o),i&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},pt=class{constructor(t,e,o){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=o}get _$AU(){return this._$AM._$AU}_$AI(t){ct(this,t)}};const yt=M.litHtmlPolyfillSupport;yt?.(st,lt),(M.litHtmlVersions??=[]).push("3.1.0");
|
|
52
52
|
/**
|
|
53
53
|
* @license
|
|
54
54
|
* Copyright 2019 Google LLC
|
|
@@ -65,7 +65,7 @@ const gt=globalThis,bt=gt.ShadowRoot&&(void 0===gt.ShadyCSS||gt.ShadyCSS.nativeS
|
|
|
65
65
|
* Copyright 2017 Google LLC
|
|
66
66
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
67
67
|
*/
|
|
68
|
-
const Pt=globalThis,Ft=Pt.trustedTypes,Bt=Ft?Ft.createPolicy("lit-html",{createHTML:t=>t}):void 0,Tt="$lit$",
|
|
68
|
+
const Pt=globalThis,Ft=Pt.trustedTypes,Bt=Ft?Ft.createPolicy("lit-html",{createHTML:t=>t}):void 0,Tt="$lit$",_t=`lit$${(Math.random()+"").slice(9)}$`,Dt="?"+_t,zt=`<${Dt}>`,Gt=document,Ht=()=>Gt.createComment(""),qt=t=>null===t||"object"!=typeof t&&"function"!=typeof t,Jt=Array.isArray,Yt="[ \t\n\f\r]",Vt=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Xt=/-->/g,Qt=/>/g,te=RegExp(`>|${Yt}(?:([^\\s"'>=/]+)(${Yt}*=${Yt}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),ee=/'/g,oe=/"/g,re=/^(?:script|style|textarea|title)$/i,ie=(t=>(e,...o)=>({_$litType$:t,strings:e,values:o}))(1),ne=Symbol.for("lit-noChange"),ae=Symbol.for("lit-nothing"),se=new WeakMap,ce=Gt.createTreeWalker(Gt,129);function le(t,e){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==Bt?Bt.createHTML(e):e}class fe{constructor({strings:t,_$litType$:e},o){let r;this.parts=[];let i=0,n=0;const a=t.length-1,s=this.parts,[c,l]=((t,e)=>{const o=t.length-1,r=[];let i,n=2===e?"<svg>":"",a=Vt;for(let e=0;e<o;e++){const o=t[e];let s,c,l=-1,f=0;for(;f<o.length&&(a.lastIndex=f,c=a.exec(o),null!==c);)f=a.lastIndex,a===Vt?"!--"===c[1]?a=Xt:void 0!==c[1]?a=Qt:void 0!==c[2]?(re.test(c[2])&&(i=RegExp("</"+c[2],"g")),a=te):void 0!==c[3]&&(a=te):a===te?">"===c[0]?(a=i??Vt,l=-1):void 0===c[1]?l=-2:(l=a.lastIndex-c[2].length,s=c[1],a=void 0===c[3]?te:'"'===c[3]?oe:ee):a===oe||a===ee?a=te:a===Xt||a===Qt?a=Vt:(a=te,i=void 0);const h=a===te&&t[e+1].startsWith("/>")?" ":"";n+=a===Vt?o+zt:l>=0?(r.push(s),o.slice(0,l)+Tt+o.slice(l)+_t+h):o+_t+(-2===l?e:h)}return[le(t,n+(t[o]||"<?>")+(2===e?"</svg>":"")),r]})(t,e);if(this.el=fe.createElement(c,o),ce.currentNode=this.el.content,2===e){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(r=ce.nextNode())&&s.length<a;){if(1===r.nodeType){if(r.hasAttributes())for(const t of r.getAttributeNames())if(t.endsWith(Tt)){const e=l[n++],o=r.getAttribute(t).split(_t),a=/([.?@])?(.*)/.exec(e);s.push({type:1,index:i,name:a[2],strings:o,ctor:"."===a[1]?pe:"?"===a[1]?ye:"@"===a[1]?ge:de}),r.removeAttribute(t)}else t.startsWith(_t)&&(s.push({type:6,index:i}),r.removeAttribute(t));if(re.test(r.tagName)){const t=r.textContent.split(_t),e=t.length-1;if(e>0){r.textContent=Ft?Ft.emptyScript:"";for(let o=0;o<e;o++)r.append(t[o],Ht()),ce.nextNode(),s.push({type:2,index:++i});r.append(t[e],Ht())}}}else if(8===r.nodeType)if(r.data===Dt)s.push({type:2,index:i});else{let t=-1;for(;-1!==(t=r.data.indexOf(_t,t+1));)s.push({type:7,index:i}),t+=_t.length-1}i++}}static createElement(t,e){const o=Gt.createElement("template");return o.innerHTML=t,o}}function he(t,e,o=t,r){if(e===ne)return e;let i=void 0!==r?o._$Co?.[r]:o._$Cl;const n=qt(e)?void 0:e._$litDirective$;return i?.constructor!==n&&(i?._$AO?.(!1),void 0===n?i=void 0:(i=new n(t),i._$AT(t,o,r)),void 0!==r?(o._$Co??=[])[r]=i:o._$Cl=i),void 0!==i&&(e=he(t,i._$AS(t,e.values),i,r)),e}let ue=class t{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,o,r){this.type=2,this._$AH=ae,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=o,this.options=r,this._$Cv=r?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t?.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=he(this,t,e),qt(t)?t===ae||null==t||""===t?(this._$AH!==ae&&this._$AR(),this._$AH=ae):t!==this._$AH&&t!==ne&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>Jt(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==ae&&qt(this._$AH)?this._$AA.nextSibling.data=t:this.$(Gt.createTextNode(t)),this._$AH=t}g(t){const{values:e,_$litType$:o}=t,r="number"==typeof o?this._$AC(t):(void 0===o.el&&(o.el=fe.createElement(le(o.h,o.h[0]),this.options)),o);if(this._$AH?._$AD===r)this._$AH.p(e);else{const t=new class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:o}=this._$AD,r=(t?.creationScope??Gt).importNode(e,!0);ce.currentNode=r;let i=ce.nextNode(),n=0,a=0,s=o[0];for(;void 0!==s;){if(n===s.index){let e;2===s.type?e=new ue(i,i.nextSibling,this,t):1===s.type?e=new s.ctor(i,s.name,s.strings,this,t):6===s.type&&(e=new be(i,this,t)),this._$AV.push(e),s=o[++a]}n!==s?.index&&(i=ce.nextNode(),n++)}return ce.currentNode=Gt,r}p(t){let e=0;for(const o of this._$AV)void 0!==o&&(void 0!==o.strings?(o._$AI(t,o,e),e+=o.strings.length-2):o._$AI(t[e])),e++}}(r,this),o=t.u(this.options);t.p(e),this.$(o),this._$AH=t}}_$AC(t){let e=se.get(t.strings);return void 0===e&&se.set(t.strings,e=new fe(t)),e}T(e){Jt(this._$AH)||(this._$AH=[],this._$AR());const o=this._$AH;let r,i=0;for(const n of e)i===o.length?o.push(r=new t(this.k(Ht()),this.k(Ht()),this,this.options)):r=o[i],r._$AI(n),i++;i<o.length&&(this._$AR(r&&r._$AB.nextSibling,i),o.length=i)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t&&t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}},de=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,o,r,i){this.type=1,this._$AH=ae,this._$AN=void 0,this.element=t,this.name=e,this._$AM=r,this.options=i,o.length>2||""!==o[0]||""!==o[1]?(this._$AH=Array(o.length-1).fill(new String),this.strings=o):this._$AH=ae}_$AI(t,e=this,o,r){const i=this.strings;let n=!1;if(void 0===i)t=he(this,t,e,0),n=!qt(t)||t!==this._$AH&&t!==ne,n&&(this._$AH=t);else{const r=t;let a,s;for(t=i[0],a=0;a<i.length-1;a++)s=he(this,r[o+a],e,a),s===ne&&(s=this._$AH[a]),n||=!qt(s)||s!==this._$AH[a],s===ae?t=ae:t!==ae&&(t+=(s??"")+i[a+1]),this._$AH[a]=s}n&&!r&&this.O(t)}O(t){t===ae?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},pe=class extends de{constructor(){super(...arguments),this.type=3}O(t){this.element[this.name]=t===ae?void 0:t}},ye=class extends de{constructor(){super(...arguments),this.type=4}O(t){this.element.toggleAttribute(this.name,!!t&&t!==ae)}},ge=class extends de{constructor(t,e,o,r,i){super(t,e,o,r,i),this.type=5}_$AI(t,e=this){if((t=he(this,t,e,0)??ae)===ne)return;const o=this._$AH,r=t===ae&&o!==ae||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,i=t!==ae&&(o===ae||r);r&&this.element.removeEventListener(this.name,this,o),i&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},be=class{constructor(t,e,o){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=o}get _$AU(){return this._$AM._$AU}_$AI(t){he(this,t)}};const me=Pt.litHtmlPolyfillSupport;me?.(fe,ue),(Pt.litHtmlVersions??=[]).push("3.1.0");
|
|
69
69
|
/**
|
|
70
70
|
* @license
|
|
71
71
|
* Copyright 2017 Google LLC
|
|
@@ -112,7 +112,7 @@ let ve=class extends Zt{constructor(){super(...arguments),this.renderOptions={ho
|
|
|
112
112
|
display: inline-block;
|
|
113
113
|
width: 0;
|
|
114
114
|
}
|
|
115
|
-
`;class Fe{constructor(t,e){this.defaultLabels=t,this.labels=e}resolve(t,...e){var o,r;t=this.resolvePluralKey(t,e);let i=null!==(r=null!==(o=this.labels[t])&&void 0!==o?o:this.defaultLabels[t])&&void 0!==r?r:"";return e.forEach(((t,e)=>i=i.replace(new RegExp(`\\{${e}([^}]*)\\}`,"g"),((e,o)=>this.formatValue(t,o))))),i}resolvePluralKey(t,e){for(let o of e)if("number"==typeof o){const e=`${String(t)}[\\=${o}]`;if(e in this.labels||e in this.defaultLabels)return e}return t}formatValue(t,e){return t instanceof Date?this.formatDate(t,e):null!=t?t:""}formatDate(t,e){const o=o=>(null==e?void 0:e.includes("date"))?t.toLocaleDateString(o):(null==e?void 0:e.includes("time"))?t.toLocaleTimeString(o):t.toLocaleString(o);try{return o(document.documentElement.lang)}catch(t){return o()}}}const Be=t=>{const e=null!=t?t:{};return(t,o)=>{var r;const i={hasChanged:(t,e)=>!K(t,e),attribute:!1,...e};U(i)(t,o);const n=t.constructor;n.reduxProperties=new Map(n.reduxProperties),n.reduxProperties.set(o,{selector:null!==(r=e.selector)&&void 0!==r?r:t=>t[o],store:e.store})}};class Te{constructor(){this.queue=[]}add(t,e=!1){e&&(this.queue=this.queue.filter((e=>e.type!==t.type))),this.queue.push(t)}consume(t){const e=this.queue.find((e=>e.type===t));return e&&(this.queue=this.queue.filter((t=>t!==e))),e}}function De(t){var e;return null!==(e=null==t?void 0:t.isFtReduxStore)&&void 0!==e&&e}var _e,ze,Ge;const He=Symbol("internalReduxEventsUnsubscribers"),qe=Symbol("internalStoresUnsubscribers"),Je=Symbol("internalStores");class Ye extends Ke{constructor(){super(...arguments),this[_e]=new Map,this[ze]=new Map,this[Ge]=[]}get reduxConstructor(){return this.constructor}update(t){super.update(t),[...this.reduxConstructor.reduxReactiveProperties].some((e=>t.has(e)))&&this.updateFromStores()}getUnnamedStore(){if(this[Je].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Je].values()][0]}getStore(t){return null==t?this.getUnnamedStore():this[Je].get(t)}addStore(t,e){var o;e=null!==(o=null!=e?e:De(t)?t.name:void 0)&&void 0!==o?o:"default-store",this.unsubscribeFromStore(e),this.setupStore(e,t)}removeStore(t){const e="string"==typeof t?t:t.name;this.unsubscribeFromStore(e),this[Je].delete(e)}setupStore(t,e){this[Je].set(t,e),this.subscribeToStore(t,e),this.updateFromStores()}setupStores(){this.unsubscribeFromStores(),this[Je].forEach(((t,e)=>this.subscribeToStore(e,t))),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach(((t,e)=>{const o=this.constructor.getPropertyOptions(e);if(!(null==o?void 0:o.attribute)||!this.hasAttribute("string"==typeof(null==o?void 0:o.attribute)?o.attribute:e)){const o=this.getStore(t.store);o&&(t.store?this[qe].has(t.store):this[qe].size>0)&&(this[e]=t.selector(o.getState(),this))}}))}subscribeToStore(t,e){var o;this[qe].set(t,e.subscribe((()=>this.updateFromStores()))),De(e)&&e.eventBus&&(null===(o=this.reduxConstructor.reduxEventListeners)||void 0===o||o.forEach(((t,o)=>{if("function"==typeof this[o]&&(!t.store||e.name===t.store)){const r=t=>this[o](t);e.eventBus.addEventListener(t.eventName,r),this[He].push((()=>e.eventBus.removeEventListener(t.eventName,r)))}}))),this.onStoreAvailable(t)}unsubscribeFromStores(){this[qe].forEach(((t,e)=>this.unsubscribeFromStore(e))),this[He].forEach((t=>t())),this[He]=[]}unsubscribeFromStore(t){this[qe].has(t)&&this[qe].get(t)(),this[qe].delete(t)}onStoreAvailable(t){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}function Ve(t){for(var e=arguments.length,o=Array(e>1?e-1:0),r=1;r<e;r++)o[r-1]=arguments[r];throw Error("[Immer] minified error nr: "+t+(o.length?" "+o.map((function(t){return"'"+t+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Xe(t){return!!t&&!!t[Po]}function Qe(t){var e;return!!t&&(function(t){if(!t||"object"!=typeof t)return!1;var e=Object.getPrototypeOf(t);if(null===e)return!0;var o=Object.hasOwnProperty.call(e,"constructor")&&e.constructor;return o===Object||"function"==typeof o&&Function.toString.call(o)===Fo}(t)||Array.isArray(t)||!!t[Zo]||!!(null===(e=t.constructor)||void 0===e?void 0:e[Zo])||no(t)||ao(t))}function to(t,e,o){void 0===o&&(o=!1),0===eo(t)?(o?Object.keys:Bo)(t).forEach((function(r){o&&"symbol"==typeof r||e(r,t[r],t)})):t.forEach((function(o,r){return e(r,o,t)}))}function eo(t){var e=t[Po];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:no(t)?2:ao(t)?3:0}function oo(t,e){return 2===eo(t)?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function ro(t,e,o){var r=eo(t);2===r?t.set(e,o):3===r?t.add(o):t[e]=o}function io(t,e){return t===e?0!==t||1/t==1/e:t!=t&&e!=e}function no(t){return Ko&&t instanceof Map}function ao(t){return jo&&t instanceof Set}function so(t){return t.o||t.t}function co(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=To(t);delete e[Po];for(var o=Bo(e),r=0;r<o.length;r++){var i=o[r],n=e[i];!1===n.writable&&(n.writable=!0,n.configurable=!0),(n.get||n.set)&&(e[i]={configurable:!0,writable:!0,enumerable:n.enumerable,value:t[i]})}return Object.create(Object.getPrototypeOf(t),e)}function lo(t,e){return void 0===e&&(e=!1),ho(t)||Xe(t)||!Qe(t)||(eo(t)>1&&(t.set=t.add=t.clear=t.delete=fo),Object.freeze(t),e&&to(t,(function(t,e){return lo(e,!0)}),!0)),t}function fo(){Ve(2)}function ho(t){return null==t||"object"!=typeof t||Object.isFrozen(t)}function uo(t){var e=Do[t];return e||Ve(18,t),e}function po(){return Wo}function yo(t,e){e&&(uo("Patches"),t.u=[],t.s=[],t.v=e)}function go(t){bo(t),t.p.forEach(vo),t.p=null}function bo(t){t===Wo&&(Wo=t.l)}function mo(t){return Wo={p:[],l:Wo,h:t,m:!0,_:0}}function vo(t){var e=t[Po];0===e.i||1===e.i?e.j():e.g=!0}function Oo(t,e){e._=e.p.length;var o=e.p[0],r=void 0!==t&&t!==o;return e.h.O||uo("ES5").S(e,t,r),r?(o[Po].P&&(go(e),Ve(4)),Qe(t)&&(t=xo(e,t),e.l||No(e,t)),e.u&&uo("Patches").M(o[Po].t,t,e.u,e.s)):t=xo(e,o,[]),go(e),e.u&&e.v(e.u,e.s),t!==Mo?t:void 0}function xo(t,e,o){if(ho(e))return e;var r=e[Po];if(!r)return to(e,(function(i,n){return wo(t,r,e,i,n,o)}),!0),e;if(r.A!==t)return e;if(!r.P)return No(t,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var i=4===r.i||5===r.i?r.o=co(r.k):r.o,n=i,a=!1;3===r.i&&(n=new Set(i),i.clear(),a=!0),to(n,(function(e,n){return wo(t,r,i,e,n,o,a)})),No(t,i,!1),o&&t.u&&uo("Patches").N(r,o,t.u,t.s)}return r.o}function wo(t,e,o,r,i,n,a){if(Xe(i)){var s=xo(t,i,n&&e&&3!==e.i&&!oo(e.R,r)?n.concat(r):void 0);if(ro(o,r,s),!Xe(s))return;t.m=!1}else a&&o.add(i);if(Qe(i)&&!ho(i)){if(!t.h.D&&t._<1)return;xo(t,i),e&&e.A.l||No(t,i)}}function No(t,e,o){void 0===o&&(o=!1),!t.l&&t.h.D&&t.m&&lo(e,o)}function So(t,e){var o=t[Po];return(o?so(o):t)[e]}function Co(t,e){if(e in t)for(var o=Object.getPrototypeOf(t);o;){var r=Object.getOwnPropertyDescriptor(o,e);if(r)return r;o=Object.getPrototypeOf(o)}}function Eo(t){t.P||(t.P=!0,t.l&&Eo(t.l))}function Ro(t){t.o||(t.o=co(t.t))}function Uo(t,e,o){var r=no(e)?uo("MapSet").F(e,o):ao(e)?uo("MapSet").T(e,o):t.O?function(t,e){var o=Array.isArray(t),r={i:o?1:0,A:e?e.A:po(),P:!1,I:!1,R:{},l:e,t,k:null,o:null,j:null,C:!1},i=r,n=_o;o&&(i=[r],n=zo);var a=Proxy.revocable(i,n),s=a.revoke,c=a.proxy;return r.k=c,r.j=s,c}(e,o):uo("ES5").J(e,o);return(o?o.A:po()).p.push(r),r}function Io(t){return Xe(t)||Ve(22,t),function t(e){if(!Qe(e))return e;var o,r=e[Po],i=eo(e);if(r){if(!r.P&&(r.i<4||!uo("ES5").K(r)))return r.t;r.I=!0,o=ko(e,i),r.I=!1}else o=ko(e,i);return to(o,(function(e,i){r&&function(t,e){return 2===eo(t)?t.get(e):t[e]}(r.t,e)===i||ro(o,e,t(i))})),3===i?new Set(o):o}(t)}function ko(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return co(t)}_e=qe,ze=Je,Ge=He,Ye.reduxProperties=new Map,Ye.reduxReactiveProperties=new Set,Ye.reduxEventListeners=new Map;var Lo,Wo,Ao="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),Ko="undefined"!=typeof Map,jo="undefined"!=typeof Set,$o="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,Mo=Ao?Symbol.for("immer-nothing"):((Lo={})["immer-nothing"]=!0,Lo),Zo=Ao?Symbol.for("immer-draftable"):"__$immer_draftable",Po=Ao?Symbol.for("immer-state"):"__$immer_state",Fo=""+Object.prototype.constructor,Bo="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,To=Object.getOwnPropertyDescriptors||function(t){var e={};return Bo(t).forEach((function(o){e[o]=Object.getOwnPropertyDescriptor(t,o)})),e},Do={},_o={get:function(t,e){if(e===Po)return t;var o=so(t);if(!oo(o,e))return function(t,e,o){var r,i=Co(e,o);return i?"value"in i?i.value:null===(r=i.get)||void 0===r?void 0:r.call(t.k):void 0}(t,o,e);var r=o[e];return t.I||!Qe(r)?r:r===So(t.t,e)?(Ro(t),t.o[e]=Uo(t.A.h,r,t)):r},has:function(t,e){return e in so(t)},ownKeys:function(t){return Reflect.ownKeys(so(t))},set:function(t,e,o){var r=Co(so(t),e);if(null==r?void 0:r.set)return r.set.call(t.k,o),!0;if(!t.P){var i=So(so(t),e),n=null==i?void 0:i[Po];if(n&&n.t===o)return t.o[e]=o,t.R[e]=!1,!0;if(io(o,i)&&(void 0!==o||oo(t.t,e)))return!0;Ro(t),Eo(t)}return t.o[e]===o&&(void 0!==o||e in t.o)||Number.isNaN(o)&&Number.isNaN(t.o[e])||(t.o[e]=o,t.R[e]=!0),!0},deleteProperty:function(t,e){return void 0!==So(t.t,e)||e in t.t?(t.R[e]=!1,Ro(t),Eo(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var o=so(t),r=Reflect.getOwnPropertyDescriptor(o,e);return r?{writable:!0,configurable:1!==t.i||"length"!==e,enumerable:r.enumerable,value:o[e]}:r},defineProperty:function(){Ve(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){Ve(12)}},zo={};to(_o,(function(t,e){zo[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}})),zo.deleteProperty=function(t,e){return zo.set.call(this,t,e,void 0)},zo.set=function(t,e,o){return _o.set.call(this,t[0],e,o,t[0])};var Go=function(){function t(t){var e=this;this.O=$o,this.D=!0,this.produce=function(t,o,r){if("function"==typeof t&&"function"!=typeof o){var i=o;o=t;var n=e;return function(t){var e=this;void 0===t&&(t=i);for(var r=arguments.length,a=Array(r>1?r-1:0),s=1;s<r;s++)a[s-1]=arguments[s];return n.produce(t,(function(t){var r;return(r=o).call.apply(r,[e,t].concat(a))}))}}var a;if("function"!=typeof o&&Ve(6),void 0!==r&&"function"!=typeof r&&Ve(7),Qe(t)){var s=mo(e),c=Uo(e,t,void 0),l=!0;try{a=o(c),l=!1}finally{l?go(s):bo(s)}return"undefined"!=typeof Promise&&a instanceof Promise?a.then((function(t){return yo(s,r),Oo(t,s)}),(function(t){throw go(s),t})):(yo(s,r),Oo(a,s))}if(!t||"object"!=typeof t){if(void 0===(a=o(t))&&(a=t),a===Mo&&(a=void 0),e.D&&lo(a,!0),r){var f=[],h=[];uo("Patches").M(t,a,f,h),r(f,h)}return a}Ve(21,t)},this.produceWithPatches=function(t,o){if("function"==typeof t)return function(o){for(var r=arguments.length,i=Array(r>1?r-1:0),n=1;n<r;n++)i[n-1]=arguments[n];return e.produceWithPatches(o,(function(e){return t.apply(void 0,[e].concat(i))}))};var r,i,n=e.produce(t,o,(function(t,e){r=t,i=e}));return"undefined"!=typeof Promise&&n instanceof Promise?n.then((function(t){return[t,r,i]})):[n,r,i]},"boolean"==typeof(null==t?void 0:t.useProxies)&&this.setUseProxies(t.useProxies),"boolean"==typeof(null==t?void 0:t.autoFreeze)&&this.setAutoFreeze(t.autoFreeze)}var e=t.prototype;return e.createDraft=function(t){Qe(t)||Ve(8),Xe(t)&&(t=Io(t));var e=mo(this),o=Uo(this,t,void 0);return o[Po].C=!0,bo(e),o},e.finishDraft=function(t,e){var o=(t&&t[Po]).A;return yo(o,e),Oo(void 0,o)},e.setAutoFreeze=function(t){this.D=t},e.setUseProxies=function(t){t&&!$o&&Ve(20),this.O=t},e.applyPatches=function(t,e){var o;for(o=e.length-1;o>=0;o--){var r=e[o];if(0===r.path.length&&"replace"===r.op){t=r.value;break}}o>-1&&(e=e.slice(o+1));var i=uo("Patches").$;return Xe(t)?i(t,e):this.produce(t,(function(t){return i(t,e)}))},t}(),Ho=new Go,qo=Ho.produce;function Jo(t){return Jo="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Jo(t)}function Yo(t){var e=function(t,e){if("object"!==Jo(t)||null===t)return t;var o=t[Symbol.toPrimitive];if(void 0!==o){var r=o.call(t,e||"default");if("object"!==Jo(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"===Jo(e)?e:String(e)}function Vo(t,e,o){return(e=Yo(e))in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}function Xo(t,e){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),o.push.apply(o,r)}return o}function Qo(t){for(var e=1;e<arguments.length;e++){var o=null!=arguments[e]?arguments[e]:{};e%2?Xo(Object(o),!0).forEach((function(e){Vo(t,e,o[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):Xo(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}function tr(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. "}Ho.produceWithPatches.bind(Ho),Ho.setAutoFreeze.bind(Ho),Ho.setUseProxies.bind(Ho),Ho.applyPatches.bind(Ho),Ho.createDraft.bind(Ho),Ho.finishDraft.bind(Ho);var er="function"==typeof Symbol&&Symbol.observable||"@@observable",or=function(){return Math.random().toString(36).substring(7).split("").join(".")},rr={INIT:"@@redux/INIT"+or(),REPLACE:"@@redux/REPLACE"+or(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+or()}};function ir(t,e,o){var r;if("function"==typeof e&&"function"==typeof o||"function"==typeof o&&"function"==typeof arguments[3])throw new Error(tr(0));if("function"==typeof e&&void 0===o&&(o=e,e=void 0),void 0!==o){if("function"!=typeof o)throw new Error(tr(1));return o(ir)(t,e)}if("function"!=typeof t)throw new Error(tr(2));var i=t,n=e,a=[],s=a,c=!1;function l(){s===a&&(s=a.slice())}function f(){if(c)throw new Error(tr(3));return n}function h(t){if("function"!=typeof t)throw new Error(tr(4));if(c)throw new Error(tr(5));var e=!0;return l(),s.push(t),function(){if(e){if(c)throw new Error(tr(6));e=!1,l();var o=s.indexOf(t);s.splice(o,1),a=null}}}function u(t){if(!function(t){if("object"!=typeof t||null===t)return!1;for(var e=t;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}(t))throw new Error(tr(7));if(void 0===t.type)throw new Error(tr(8));if(c)throw new Error(tr(9));try{c=!0,n=i(n,t)}finally{c=!1}for(var e=a=s,o=0;o<e.length;o++){(0,e[o])()}return t}return u({type:rr.INIT}),(r={dispatch:u,subscribe:h,getState:f,replaceReducer:function(t){if("function"!=typeof t)throw new Error(tr(10));i=t,u({type:rr.REPLACE})}})[er]=function(){var t,e=h;return(t={subscribe:function(t){if("object"!=typeof t||null===t)throw new Error(tr(11));function o(){t.next&&t.next(f())}return o(),{unsubscribe:e(o)}}})[er]=function(){return this},t},r}function nr(t){for(var e=Object.keys(t),o={},r=0;r<e.length;r++){var i=e[r];"function"==typeof t[i]&&(o[i]=t[i])}var n,a=Object.keys(o);try{!function(t){Object.keys(t).forEach((function(e){var o=t[e];if(void 0===o(void 0,{type:rr.INIT}))throw new Error(tr(12));if(void 0===o(void 0,{type:rr.PROBE_UNKNOWN_ACTION()}))throw new Error(tr(13))}))}(o)}catch(t){n=t}return function(t,e){if(void 0===t&&(t={}),n)throw n;for(var r=!1,i={},s=0;s<a.length;s++){var c=a[s],l=o[c],f=t[c],h=l(f,e);if(void 0===h)throw e&&e.type,new Error(tr(14));i[c]=h,r=r||h!==f}return(r=r||a.length!==Object.keys(t).length)?i:t}}function ar(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return 0===e.length?function(t){return t}:1===e.length?e[0]:e.reduce((function(t,e){return function(){return t(e.apply(void 0,arguments))}}))}function sr(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return function(t){return function(){var o=t.apply(void 0,arguments),r=function(){throw new Error(tr(15))},i={getState:o.getState,dispatch:function(){return r.apply(void 0,arguments)}},n=e.map((function(t){return t(i)}));return r=ar.apply(void 0,n)(o.dispatch),Qo(Qo({},o),{},{dispatch:r})}}}function cr(t){return function(e){var o=e.dispatch,r=e.getState;return function(e){return function(i){return"function"==typeof i?i(o,r,t):e(i)}}}}var lr=cr();lr.withExtraArgument=cr;var fr,hr=lr,ur=(fr=function(t,e){return fr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])},fr(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}fr(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),dr=function(t,e){var o,r,i,n,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return n={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(n[Symbol.iterator]=function(){return this}),n;function s(n){return function(s){return function(n){if(o)throw new TypeError("Generator is already executing.");for(;a;)try{if(o=1,r&&(i=2&n[0]?r.return:n[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,n[1])).done)return i;switch(r=0,i&&(n=[2&n[0],i.value]),n[0]){case 0:case 1:i=n;break;case 4:return a.label++,{value:n[1],done:!1};case 5:a.label++,r=n[1],n=[0];continue;case 7:n=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==n[0]&&2!==n[0])){a=0;continue}if(3===n[0]&&(!i||n[1]>i[0]&&n[1]<i[3])){a.label=n[1];break}if(6===n[0]&&a.label<i[1]){a.label=i[1],i=n;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(n);break}i[2]&&a.ops.pop(),a.trys.pop();continue}n=e.call(t,a)}catch(t){n=[6,t],r=0}finally{o=i=0}if(5&n[0])throw n[1];return{value:n[0]?n[1]:void 0,done:!0}}([n,s])}}},pr=function(t,e){for(var o=0,r=e.length,i=t.length;o<r;o++,i++)t[i]=e[o];return t},yr=Object.defineProperty,gr=Object.defineProperties,br=Object.getOwnPropertyDescriptors,mr=Object.getOwnPropertySymbols,vr=Object.prototype.hasOwnProperty,Or=Object.prototype.propertyIsEnumerable,xr=function(t,e,o){return e in t?yr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o},wr=function(t,e){for(var o in e||(e={}))vr.call(e,o)&&xr(t,o,e[o]);if(mr)for(var r=0,i=mr(e);r<i.length;r++){o=i[r];Or.call(e,o)&&xr(t,o,e[o])}return t},Nr=function(t,e){return gr(t,br(e))},Sr="undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(0!==arguments.length)return"object"==typeof arguments[0]?ar:ar.apply(null,arguments)};var Cr=function(t){function e(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return ur(e,t),Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var e=[],o=0;o<arguments.length;o++)e[o]=arguments[o];return t.prototype.concat.apply(this,e)},e.prototype.prepend=function(){for(var t=[],o=0;o<arguments.length;o++)t[o]=arguments[o];return 1===t.length&&Array.isArray(t[0])?new(e.bind.apply(e,pr([void 0],t[0].concat(this)))):new(e.bind.apply(e,pr([void 0],t.concat(this))))},e}(Array),Er=function(t){function e(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return ur(e,t),Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var e=[],o=0;o<arguments.length;o++)e[o]=arguments[o];return t.prototype.concat.apply(this,e)},e.prototype.prepend=function(){for(var t=[],o=0;o<arguments.length;o++)t[o]=arguments[o];return 1===t.length&&Array.isArray(t[0])?new(e.bind.apply(e,pr([void 0],t[0].concat(this)))):new(e.bind.apply(e,pr([void 0],t.concat(this))))},e}(Array);function Rr(t){return Qe(t)?qo(t,(function(){})):t}function Ur(){return function(t){return function(t){void 0===t&&(t={});var e=t.thunk,o=void 0===e||e;t.immutableCheck,t.serializableCheck;var r=new Cr;o&&(!function(t){return"boolean"==typeof t}(o)?r.push(hr.withExtraArgument(o.extraArgument)):r.push(hr));return r}(t)}}function Ir(t){var e,o=Ur(),r=t||{},i=r.reducer,n=void 0===i?void 0:i,a=r.middleware,s=void 0===a?o():a,c=r.devTools,l=void 0===c||c,f=r.preloadedState,h=void 0===f?void 0:f,u=r.enhancers,d=void 0===u?void 0:u;if("function"==typeof n)e=n;else{if(!function(t){if("object"!=typeof t||null===t)return!1;var e=Object.getPrototypeOf(t);if(null===e)return!0;for(var o=e;null!==Object.getPrototypeOf(o);)o=Object.getPrototypeOf(o);return e===o}(n))throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');e=nr(n)}var p=s;"function"==typeof p&&(p=p(o));var y=sr.apply(void 0,p),g=ar;l&&(g=Sr(wr({trace:!1},"object"==typeof l&&l)));var b=new Er(y),m=b;return Array.isArray(d)?m=pr([y],d):"function"==typeof d&&(m=d(b)),ir(e,h,g.apply(void 0,m))}function kr(t,e){function o(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];if(e){var i=e.apply(void 0,o);if(!i)throw new Error("prepareAction did not return an object");return wr(wr({type:t,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:t,payload:o[0]}}return o.toString=function(){return""+t},o.type=t,o.match=function(e){return e.type===t},o}function Lr(t){var e,o={},r=[],i={addCase:function(t,e){var r="string"==typeof t?t:t.type;if(r in o)throw new Error("addCase cannot be called with two reducers for the same action type");return o[r]=e,i},addMatcher:function(t,e){return r.push({matcher:t,reducer:e}),i},addDefaultCase:function(t){return e=t,i}};return t(i),[o,r,e]}function Wr(t){var e=t.name;if(!e)throw new Error("`name` is a required option for createSlice");var o,r="function"==typeof t.initialState?t.initialState:Rr(t.initialState),i=t.reducers||{},n=Object.keys(i),a={},s={},c={};function l(){var e="function"==typeof t.extraReducers?Lr(t.extraReducers):[t.extraReducers],o=e[0],i=void 0===o?{}:o,n=e[1],a=void 0===n?[]:n,c=e[2],l=void 0===c?void 0:c,f=wr(wr({},i),s);return function(t,e,o,r){void 0===o&&(o=[]);var i,n="function"==typeof e?Lr(e):[e,o,r],a=n[0],s=n[1],c=n[2];if(function(t){return"function"==typeof t}(t))i=function(){return Rr(t())};else{var l=Rr(t);i=function(){return l}}function f(t,e){void 0===t&&(t=i());var o=pr([a[e.type]],s.filter((function(t){return(0,t.matcher)(e)})).map((function(t){return t.reducer})));return 0===o.filter((function(t){return!!t})).length&&(o=[c]),o.reduce((function(t,o){if(o){var r;if(Xe(t))return void 0===(r=o(t,e))?t:r;if(Qe(t))return qo(t,(function(t){return o(t,e)}));if(void 0===(r=o(t,e))){if(null===t)return t;throw Error("A case reducer on a non-draftable value must not return undefined")}return r}return t}),t)}return f.getInitialState=i,f}(r,(function(t){for(var e in f)t.addCase(e,f[e]);for(var o=0,r=a;o<r.length;o++){var i=r[o];t.addMatcher(i.matcher,i.reducer)}l&&t.addDefaultCase(l)}))}return n.forEach((function(t){var o,r,n=i[t],l=e+"/"+t;"reducer"in n?(o=n.reducer,r=n.prepare):o=n,a[t]=o,s[l]=o,c[t]=r?kr(l,r):kr(l)})),{name:e,reducer:function(t,e){return o||(o=l()),o(t,e)},actions:c,caseReducers:a,getInitialState:function(){return o||(o=l()),o.getInitialState()}}}var Ar=["name","message","stack","code"],Kr=function(t,e){this.payload=t,this.meta=e},jr=function(t,e){this.payload=t,this.meta=e},$r=function(t){if("object"==typeof t&&null!==t){for(var e={},o=0,r=Ar;o<r.length;o++){var i=r[o];"string"==typeof t[i]&&(e[i]=t[i])}return e}return{message:String(t)}};function Mr(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}!function(){function t(t,e,o){var r=kr(t+"/fulfilled",(function(t,e,o,r){return{payload:t,meta:Nr(wr({},r||{}),{arg:o,requestId:e,requestStatus:"fulfilled"})}})),i=kr(t+"/pending",(function(t,e,o){return{payload:void 0,meta:Nr(wr({},o||{}),{arg:e,requestId:t,requestStatus:"pending"})}})),n=kr(t+"/rejected",(function(t,e,r,i,n){return{payload:i,error:(o&&o.serializeError||$r)(t||"Rejected"),meta:Nr(wr({},n||{}),{arg:r,requestId:e,rejectedWithValue:!!i,requestStatus:"rejected",aborted:"AbortError"===(null==t?void 0:t.name),condition:"ConditionError"===(null==t?void 0:t.name)})}})),a="undefined"!=typeof AbortController?AbortController:function(){function t(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return t.prototype.abort=function(){},t}();return Object.assign((function(t){return function(s,c,l){var f,h=(null==o?void 0:o.idGenerator)?o.idGenerator(t):function(t){void 0===t&&(t=21);for(var e="",o=t;o--;)e+="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW"[64*Math.random()|0];return e}(),u=new a;function d(t){f=t,u.abort()}var p=function(){return a=this,p=null,y=function(){var a,p,y,g,b,m;return dr(this,(function(v){switch(v.label){case 0:return v.trys.push([0,4,,5]),g=null==(a=null==o?void 0:o.condition)?void 0:a.call(o,t,{getState:c,extra:l}),null===(O=g)||"object"!=typeof O||"function"!=typeof O.then?[3,2]:[4,g];case 1:g=v.sent(),v.label=2;case 2:if(!1===g||u.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return b=new Promise((function(t,e){return u.signal.addEventListener("abort",(function(){return e({name:"AbortError",message:f||"Aborted"})}))})),s(i(h,t,null==(p=null==o?void 0:o.getPendingMeta)?void 0:p.call(o,{requestId:h,arg:t},{getState:c,extra:l}))),[4,Promise.race([b,Promise.resolve(e(t,{dispatch:s,getState:c,extra:l,requestId:h,signal:u.signal,abort:d,rejectWithValue:function(t,e){return new Kr(t,e)},fulfillWithValue:function(t,e){return new jr(t,e)}})).then((function(e){if(e instanceof Kr)throw e;return e instanceof jr?r(e.payload,h,t,e.meta):r(e,h,t)}))])];case 3:return y=v.sent(),[3,5];case 4:return m=v.sent(),y=m instanceof Kr?n(null,h,t,m.payload,m.meta):n(m,h,t),[3,5];case 5:return o&&!o.dispatchConditionRejection&&n.match(y)&&y.meta.condition||s(y),[2,y]}var O}))},new Promise((function(t,e){var o=function(t){try{i(y.next(t))}catch(t){e(t)}},r=function(t){try{i(y.throw(t))}catch(t){e(t)}},i=function(e){return e.done?t(e.value):Promise.resolve(e.value).then(o,r)};i((y=y.apply(a,p)).next())}));var a,p,y}();return Object.assign(p,{abort:d,requestId:h,arg:t,unwrap:function(){return p.then(Mr)}})}}),{pending:i,rejected:n,fulfilled:r,typePrefix:t})}t.withTypes=function(){return t}}();var Zr,Pr,Fr="listenerMiddleware";kr(Fr+"/add"),kr(Fr+"/removeAll"),kr(Fr+"/remove"),"function"==typeof queueMicrotask&&queueMicrotask.bind("undefined"!=typeof window?window:"undefined"!=typeof global?global:globalThis),function(){function t(t,e){var o=i[t];return o?o.enumerable=e:i[t]=o={configurable:!0,enumerable:e,get:function(){var e=this[Po];return _o.get(e,t)},set:function(e){var o=this[Po];_o.set(o,t,e)}},o}function e(t){for(var e=t.length-1;e>=0;e--){var i=t[e][Po];if(!i.P)switch(i.i){case 5:r(i)&&Eo(i);break;case 4:o(i)&&Eo(i)}}}function o(t){for(var e=t.t,o=t.k,r=Bo(o),i=r.length-1;i>=0;i--){var n=r[i];if(n!==Po){var a=e[n];if(void 0===a&&!oo(e,n))return!0;var s=o[n],c=s&&s[Po];if(c?c.t!==a:!io(s,a))return!0}}var l=!!e[Po];return r.length!==Bo(e).length+(l?0:1)}function r(t){var e=t.k;if(e.length!==t.t.length)return!0;var o=Object.getOwnPropertyDescriptor(e,e.length-1);if(o&&!o.get)return!0;for(var r=0;r<e.length;r++)if(!e.hasOwnProperty(r))return!0;return!1}var i={};!function(t,e){Do[t]||(Do[t]=e)}("ES5",{J:function(e,o){var r=Array.isArray(e),i=function(e,o){if(e){for(var r=Array(o.length),i=0;i<o.length;i++)Object.defineProperty(r,""+i,t(i,!0));return r}var n=To(o);delete n[Po];for(var a=Bo(n),s=0;s<a.length;s++){var c=a[s];n[c]=t(c,e||!!n[c].enumerable)}return Object.create(Object.getPrototypeOf(o),n)}(r,e),n={i:r?5:4,A:o?o.A:po(),P:!1,I:!1,R:{},l:o,t:e,k:i,o:null,g:!1,C:!1};return Object.defineProperty(i,Po,{value:n,writable:!0}),i},S:function(t,o,i){i?Xe(o)&&o[Po].A===t&&e(t.p):(t.u&&function t(e){if(e&&"object"==typeof e){var o=e[Po];if(o){var i=o.t,n=o.k,a=o.R,s=o.i;if(4===s)to(n,(function(e){e!==Po&&(void 0!==i[e]||oo(i,e)?a[e]||t(n[e]):(a[e]=!0,Eo(o)))})),to(i,(function(t){void 0!==n[t]||oo(n,t)||(a[t]=!1,Eo(o))}));else if(5===s){if(r(o)&&(Eo(o),a.length=!0),n.length<i.length)for(var c=n.length;c<i.length;c++)a[c]=!1;else for(var l=i.length;l<n.length;l++)a[l]=!0;for(var f=Math.min(n.length,i.length),h=0;h<f;h++)n.hasOwnProperty(h)||(a[h]=!0),void 0===a[h]&&t(n[h])}}}}(t.p[0]),e(t.p))},K:function(t){return 4===t.i?o(t):r(t)}})}(),window.ftReduxStores||(window.ftReduxStores={});class Br{static get(t){var e;const o="string"==typeof t?t:t.name,r="string"==typeof t?void 0:t,i=window.ftReduxStores[o];if(De(i))return i;if(null==r)return;const n=Wr({...r,reducers:null!==(e=r.reducers)&&void 0!==e?e:{}}),a=Ir({reducer:(t,e)=>{var o;switch(e.type){case"CLEAR_FT_REDUX_STORE":return n.getInitialState();case"DEFAULT_STATE_FIELDS_VALUES_SETTER":return{...t,...null!==(o=e.overwrites)&&void 0!==o?o:{}};default:return n.reducer(t,e)}}});return window.ftReduxStores[r.name]=new Br(n,a)}constructor(t,e){this.reduxSlice=t,this.reduxStore=e,this.isFtReduxStore=!0,this.eventBus=document.createElement("event-bus"),this.commands=new Te,this.actions=new Proxy(this.reduxSlice.actions,{get:(t,e,o)=>{const r=e,i=t[r];return i?(...t)=>{const e=i(...t);return this.reduxStore.dispatch(e),e}:t=>{this.setState({[r]:t})}}})}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE"})}setState(t){this.reduxStore.dispatch({type:"DEFAULT_STATE_FIELDS_VALUES_SETTER",overwrites:t})}get dispatch(){throw new Error("Don't use this method, actions are automatically dispatched when called.")}[Symbol.observable](){return this.reduxStore[Symbol.observable]()}getState(){return this.reduxStore.getState()}replaceReducer(t){throw new Error("Not implemented yet.")}subscribe(t){return this.reduxStore.subscribe(t)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}}navigator.vendor&&navigator.vendor.match(/apple/i)||(null===(Pr=null===(Zr=window.safari)||void 0===Zr?void 0:Zr.pushNotification)||void 0===Pr||Pr.toString());const Tr={colorError:we.external(Ce.colorError,"Design system"),fontFamily:we.external(Ce.contentFont,"Design system")},Dr=wt`
|
|
115
|
+
`;class Fe{constructor(t,e){this.defaultLabels=t,this.labels=e}resolve(t,...e){var o,r;t=this.resolvePluralKey(t,e);let i=null!==(r=null!==(o=this.labels[t])&&void 0!==o?o:this.defaultLabels[t])&&void 0!==r?r:"";return e.forEach(((t,e)=>i=i.replace(new RegExp(`\\{${e}([^}]*)\\}`,"g"),((e,o)=>this.formatValue(t,o))))),i}resolvePluralKey(t,e){for(let o of e)if("number"==typeof o){const e=`${String(t)}[\\=${o}]`;if(e in this.labels||e in this.defaultLabels)return e}return t}formatValue(t,e){return t instanceof Date?this.formatDate(t,e):null!=t?t:""}formatDate(t,e){const o=o=>(null==e?void 0:e.includes("date"))?t.toLocaleDateString(o):(null==e?void 0:e.includes("time"))?t.toLocaleTimeString(o):t.toLocaleString(o);try{return o(document.documentElement.lang)}catch(t){return o()}}}const Be=t=>{const e=null!=t?t:{};return(t,o)=>{var r;const i={hasChanged:(t,e)=>!K(t,e),attribute:!1,...e};U(i)(t,o);const n=t.constructor;n.reduxProperties=new Map(n.reduxProperties),n.reduxProperties.set(o,{selector:null!==(r=e.selector)&&void 0!==r?r:t=>t[o],store:e.store})}};class Te{constructor(){this.queue=[]}add(t,e=!1){e&&(this.queue=this.queue.filter((e=>e.type!==t.type))),this.queue.push(t)}consume(t){const e=this.queue.find((e=>e.type===t));return e&&(this.queue=this.queue.filter((t=>t!==e))),e}}function _e(t){var e;return null!==(e=null==t?void 0:t.isFtReduxStore)&&void 0!==e&&e}var De,ze,Ge;const He=Symbol("internalReduxEventsUnsubscribers"),qe=Symbol("internalStoresUnsubscribers"),Je=Symbol("internalStores");class Ye extends Ke{constructor(){super(...arguments),this[De]=new Map,this[ze]=new Map,this[Ge]=[]}get reduxConstructor(){return this.constructor}update(t){super.update(t),[...this.reduxConstructor.reduxReactiveProperties].some((e=>t.has(e)))&&this.updateFromStores()}getUnnamedStore(){if(this[Je].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Je].values()][0]}getStore(t){return null==t?this.getUnnamedStore():this[Je].get(t)}addStore(t,e){var o;e=null!==(o=null!=e?e:_e(t)?t.name:void 0)&&void 0!==o?o:"default-store",this.unsubscribeFromStore(e),this.setupStore(e,t)}removeStore(t){const e="string"==typeof t?t:t.name;this.unsubscribeFromStore(e),this[Je].delete(e)}setupStore(t,e){this[Je].set(t,e),this.subscribeToStore(t,e),this.updateFromStores()}setupStores(){this.unsubscribeFromStores(),this[Je].forEach(((t,e)=>this.subscribeToStore(e,t))),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach(((t,e)=>{const o=this.constructor.getPropertyOptions(e);if(!(null==o?void 0:o.attribute)||!this.hasAttribute("string"==typeof(null==o?void 0:o.attribute)?o.attribute:e)){const o=this.getStore(t.store);o&&(t.store?this[qe].has(t.store):this[qe].size>0)&&(this[e]=t.selector(o.getState(),this))}}))}subscribeToStore(t,e){var o;this[qe].set(t,e.subscribe((()=>this.updateFromStores()))),_e(e)&&e.eventBus&&(null===(o=this.reduxConstructor.reduxEventListeners)||void 0===o||o.forEach(((t,o)=>{if("function"==typeof this[o]&&(!t.store||e.name===t.store)){const r=t=>this[o](t);e.eventBus.addEventListener(t.eventName,r),this[He].push((()=>e.eventBus.removeEventListener(t.eventName,r)))}}))),this.onStoreAvailable(t)}unsubscribeFromStores(){this[qe].forEach(((t,e)=>this.unsubscribeFromStore(e))),this[He].forEach((t=>t())),this[He]=[]}unsubscribeFromStore(t){this[qe].has(t)&&this[qe].get(t)(),this[qe].delete(t)}onStoreAvailable(t){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}function Ve(t){for(var e=arguments.length,o=Array(e>1?e-1:0),r=1;r<e;r++)o[r-1]=arguments[r];throw Error("[Immer] minified error nr: "+t+(o.length?" "+o.map((function(t){return"'"+t+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Xe(t){return!!t&&!!t[Po]}function Qe(t){var e;return!!t&&(function(t){if(!t||"object"!=typeof t)return!1;var e=Object.getPrototypeOf(t);if(null===e)return!0;var o=Object.hasOwnProperty.call(e,"constructor")&&e.constructor;return o===Object||"function"==typeof o&&Function.toString.call(o)===Fo}(t)||Array.isArray(t)||!!t[Zo]||!!(null===(e=t.constructor)||void 0===e?void 0:e[Zo])||no(t)||ao(t))}function to(t,e,o){void 0===o&&(o=!1),0===eo(t)?(o?Object.keys:Bo)(t).forEach((function(r){o&&"symbol"==typeof r||e(r,t[r],t)})):t.forEach((function(o,r){return e(r,o,t)}))}function eo(t){var e=t[Po];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:no(t)?2:ao(t)?3:0}function oo(t,e){return 2===eo(t)?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function ro(t,e,o){var r=eo(t);2===r?t.set(e,o):3===r?t.add(o):t[e]=o}function io(t,e){return t===e?0!==t||1/t==1/e:t!=t&&e!=e}function no(t){return Ko&&t instanceof Map}function ao(t){return jo&&t instanceof Set}function so(t){return t.o||t.t}function co(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=To(t);delete e[Po];for(var o=Bo(e),r=0;r<o.length;r++){var i=o[r],n=e[i];!1===n.writable&&(n.writable=!0,n.configurable=!0),(n.get||n.set)&&(e[i]={configurable:!0,writable:!0,enumerable:n.enumerable,value:t[i]})}return Object.create(Object.getPrototypeOf(t),e)}function lo(t,e){return void 0===e&&(e=!1),ho(t)||Xe(t)||!Qe(t)||(eo(t)>1&&(t.set=t.add=t.clear=t.delete=fo),Object.freeze(t),e&&to(t,(function(t,e){return lo(e,!0)}),!0)),t}function fo(){Ve(2)}function ho(t){return null==t||"object"!=typeof t||Object.isFrozen(t)}function uo(t){var e=_o[t];return e||Ve(18,t),e}function po(){return Wo}function yo(t,e){e&&(uo("Patches"),t.u=[],t.s=[],t.v=e)}function go(t){bo(t),t.p.forEach(vo),t.p=null}function bo(t){t===Wo&&(Wo=t.l)}function mo(t){return Wo={p:[],l:Wo,h:t,m:!0,_:0}}function vo(t){var e=t[Po];0===e.i||1===e.i?e.j():e.g=!0}function Oo(t,e){e._=e.p.length;var o=e.p[0],r=void 0!==t&&t!==o;return e.h.O||uo("ES5").S(e,t,r),r?(o[Po].P&&(go(e),Ve(4)),Qe(t)&&(t=xo(e,t),e.l||No(e,t)),e.u&&uo("Patches").M(o[Po].t,t,e.u,e.s)):t=xo(e,o,[]),go(e),e.u&&e.v(e.u,e.s),t!==Mo?t:void 0}function xo(t,e,o){if(ho(e))return e;var r=e[Po];if(!r)return to(e,(function(i,n){return wo(t,r,e,i,n,o)}),!0),e;if(r.A!==t)return e;if(!r.P)return No(t,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var i=4===r.i||5===r.i?r.o=co(r.k):r.o,n=i,a=!1;3===r.i&&(n=new Set(i),i.clear(),a=!0),to(n,(function(e,n){return wo(t,r,i,e,n,o,a)})),No(t,i,!1),o&&t.u&&uo("Patches").N(r,o,t.u,t.s)}return r.o}function wo(t,e,o,r,i,n,a){if(Xe(i)){var s=xo(t,i,n&&e&&3!==e.i&&!oo(e.R,r)?n.concat(r):void 0);if(ro(o,r,s),!Xe(s))return;t.m=!1}else a&&o.add(i);if(Qe(i)&&!ho(i)){if(!t.h.D&&t._<1)return;xo(t,i),e&&e.A.l||No(t,i)}}function No(t,e,o){void 0===o&&(o=!1),!t.l&&t.h.D&&t.m&&lo(e,o)}function So(t,e){var o=t[Po];return(o?so(o):t)[e]}function Co(t,e){if(e in t)for(var o=Object.getPrototypeOf(t);o;){var r=Object.getOwnPropertyDescriptor(o,e);if(r)return r;o=Object.getPrototypeOf(o)}}function Eo(t){t.P||(t.P=!0,t.l&&Eo(t.l))}function Ro(t){t.o||(t.o=co(t.t))}function Uo(t,e,o){var r=no(e)?uo("MapSet").F(e,o):ao(e)?uo("MapSet").T(e,o):t.O?function(t,e){var o=Array.isArray(t),r={i:o?1:0,A:e?e.A:po(),P:!1,I:!1,R:{},l:e,t,k:null,o:null,j:null,C:!1},i=r,n=Do;o&&(i=[r],n=zo);var a=Proxy.revocable(i,n),s=a.revoke,c=a.proxy;return r.k=c,r.j=s,c}(e,o):uo("ES5").J(e,o);return(o?o.A:po()).p.push(r),r}function Io(t){return Xe(t)||Ve(22,t),function t(e){if(!Qe(e))return e;var o,r=e[Po],i=eo(e);if(r){if(!r.P&&(r.i<4||!uo("ES5").K(r)))return r.t;r.I=!0,o=ko(e,i),r.I=!1}else o=ko(e,i);return to(o,(function(e,i){r&&function(t,e){return 2===eo(t)?t.get(e):t[e]}(r.t,e)===i||ro(o,e,t(i))})),3===i?new Set(o):o}(t)}function ko(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return co(t)}De=qe,ze=Je,Ge=He,Ye.reduxProperties=new Map,Ye.reduxReactiveProperties=new Set,Ye.reduxEventListeners=new Map;var Lo,Wo,Ao="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),Ko="undefined"!=typeof Map,jo="undefined"!=typeof Set,$o="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,Mo=Ao?Symbol.for("immer-nothing"):((Lo={})["immer-nothing"]=!0,Lo),Zo=Ao?Symbol.for("immer-draftable"):"__$immer_draftable",Po=Ao?Symbol.for("immer-state"):"__$immer_state",Fo=""+Object.prototype.constructor,Bo="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,To=Object.getOwnPropertyDescriptors||function(t){var e={};return Bo(t).forEach((function(o){e[o]=Object.getOwnPropertyDescriptor(t,o)})),e},_o={},Do={get:function(t,e){if(e===Po)return t;var o=so(t);if(!oo(o,e))return function(t,e,o){var r,i=Co(e,o);return i?"value"in i?i.value:null===(r=i.get)||void 0===r?void 0:r.call(t.k):void 0}(t,o,e);var r=o[e];return t.I||!Qe(r)?r:r===So(t.t,e)?(Ro(t),t.o[e]=Uo(t.A.h,r,t)):r},has:function(t,e){return e in so(t)},ownKeys:function(t){return Reflect.ownKeys(so(t))},set:function(t,e,o){var r=Co(so(t),e);if(null==r?void 0:r.set)return r.set.call(t.k,o),!0;if(!t.P){var i=So(so(t),e),n=null==i?void 0:i[Po];if(n&&n.t===o)return t.o[e]=o,t.R[e]=!1,!0;if(io(o,i)&&(void 0!==o||oo(t.t,e)))return!0;Ro(t),Eo(t)}return t.o[e]===o&&(void 0!==o||e in t.o)||Number.isNaN(o)&&Number.isNaN(t.o[e])||(t.o[e]=o,t.R[e]=!0),!0},deleteProperty:function(t,e){return void 0!==So(t.t,e)||e in t.t?(t.R[e]=!1,Ro(t),Eo(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var o=so(t),r=Reflect.getOwnPropertyDescriptor(o,e);return r?{writable:!0,configurable:1!==t.i||"length"!==e,enumerable:r.enumerable,value:o[e]}:r},defineProperty:function(){Ve(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){Ve(12)}},zo={};to(Do,(function(t,e){zo[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}})),zo.deleteProperty=function(t,e){return zo.set.call(this,t,e,void 0)},zo.set=function(t,e,o){return Do.set.call(this,t[0],e,o,t[0])};var Go=function(){function t(t){var e=this;this.O=$o,this.D=!0,this.produce=function(t,o,r){if("function"==typeof t&&"function"!=typeof o){var i=o;o=t;var n=e;return function(t){var e=this;void 0===t&&(t=i);for(var r=arguments.length,a=Array(r>1?r-1:0),s=1;s<r;s++)a[s-1]=arguments[s];return n.produce(t,(function(t){var r;return(r=o).call.apply(r,[e,t].concat(a))}))}}var a;if("function"!=typeof o&&Ve(6),void 0!==r&&"function"!=typeof r&&Ve(7),Qe(t)){var s=mo(e),c=Uo(e,t,void 0),l=!0;try{a=o(c),l=!1}finally{l?go(s):bo(s)}return"undefined"!=typeof Promise&&a instanceof Promise?a.then((function(t){return yo(s,r),Oo(t,s)}),(function(t){throw go(s),t})):(yo(s,r),Oo(a,s))}if(!t||"object"!=typeof t){if(void 0===(a=o(t))&&(a=t),a===Mo&&(a=void 0),e.D&&lo(a,!0),r){var f=[],h=[];uo("Patches").M(t,a,f,h),r(f,h)}return a}Ve(21,t)},this.produceWithPatches=function(t,o){if("function"==typeof t)return function(o){for(var r=arguments.length,i=Array(r>1?r-1:0),n=1;n<r;n++)i[n-1]=arguments[n];return e.produceWithPatches(o,(function(e){return t.apply(void 0,[e].concat(i))}))};var r,i,n=e.produce(t,o,(function(t,e){r=t,i=e}));return"undefined"!=typeof Promise&&n instanceof Promise?n.then((function(t){return[t,r,i]})):[n,r,i]},"boolean"==typeof(null==t?void 0:t.useProxies)&&this.setUseProxies(t.useProxies),"boolean"==typeof(null==t?void 0:t.autoFreeze)&&this.setAutoFreeze(t.autoFreeze)}var e=t.prototype;return e.createDraft=function(t){Qe(t)||Ve(8),Xe(t)&&(t=Io(t));var e=mo(this),o=Uo(this,t,void 0);return o[Po].C=!0,bo(e),o},e.finishDraft=function(t,e){var o=(t&&t[Po]).A;return yo(o,e),Oo(void 0,o)},e.setAutoFreeze=function(t){this.D=t},e.setUseProxies=function(t){t&&!$o&&Ve(20),this.O=t},e.applyPatches=function(t,e){var o;for(o=e.length-1;o>=0;o--){var r=e[o];if(0===r.path.length&&"replace"===r.op){t=r.value;break}}o>-1&&(e=e.slice(o+1));var i=uo("Patches").$;return Xe(t)?i(t,e):this.produce(t,(function(t){return i(t,e)}))},t}(),Ho=new Go,qo=Ho.produce;function Jo(t){return Jo="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Jo(t)}function Yo(t){var e=function(t,e){if("object"!==Jo(t)||null===t)return t;var o=t[Symbol.toPrimitive];if(void 0!==o){var r=o.call(t,e||"default");if("object"!==Jo(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"===Jo(e)?e:String(e)}function Vo(t,e,o){return(e=Yo(e))in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}function Xo(t,e){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),o.push.apply(o,r)}return o}function Qo(t){for(var e=1;e<arguments.length;e++){var o=null!=arguments[e]?arguments[e]:{};e%2?Xo(Object(o),!0).forEach((function(e){Vo(t,e,o[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):Xo(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}function tr(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. "}Ho.produceWithPatches.bind(Ho),Ho.setAutoFreeze.bind(Ho),Ho.setUseProxies.bind(Ho),Ho.applyPatches.bind(Ho),Ho.createDraft.bind(Ho),Ho.finishDraft.bind(Ho);var er="function"==typeof Symbol&&Symbol.observable||"@@observable",or=function(){return Math.random().toString(36).substring(7).split("").join(".")},rr={INIT:"@@redux/INIT"+or(),REPLACE:"@@redux/REPLACE"+or(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+or()}};function ir(t,e,o){var r;if("function"==typeof e&&"function"==typeof o||"function"==typeof o&&"function"==typeof arguments[3])throw new Error(tr(0));if("function"==typeof e&&void 0===o&&(o=e,e=void 0),void 0!==o){if("function"!=typeof o)throw new Error(tr(1));return o(ir)(t,e)}if("function"!=typeof t)throw new Error(tr(2));var i=t,n=e,a=[],s=a,c=!1;function l(){s===a&&(s=a.slice())}function f(){if(c)throw new Error(tr(3));return n}function h(t){if("function"!=typeof t)throw new Error(tr(4));if(c)throw new Error(tr(5));var e=!0;return l(),s.push(t),function(){if(e){if(c)throw new Error(tr(6));e=!1,l();var o=s.indexOf(t);s.splice(o,1),a=null}}}function u(t){if(!function(t){if("object"!=typeof t||null===t)return!1;for(var e=t;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}(t))throw new Error(tr(7));if(void 0===t.type)throw new Error(tr(8));if(c)throw new Error(tr(9));try{c=!0,n=i(n,t)}finally{c=!1}for(var e=a=s,o=0;o<e.length;o++){(0,e[o])()}return t}return u({type:rr.INIT}),(r={dispatch:u,subscribe:h,getState:f,replaceReducer:function(t){if("function"!=typeof t)throw new Error(tr(10));i=t,u({type:rr.REPLACE})}})[er]=function(){var t,e=h;return(t={subscribe:function(t){if("object"!=typeof t||null===t)throw new Error(tr(11));function o(){t.next&&t.next(f())}return o(),{unsubscribe:e(o)}}})[er]=function(){return this},t},r}function nr(t){for(var e=Object.keys(t),o={},r=0;r<e.length;r++){var i=e[r];"function"==typeof t[i]&&(o[i]=t[i])}var n,a=Object.keys(o);try{!function(t){Object.keys(t).forEach((function(e){var o=t[e];if(void 0===o(void 0,{type:rr.INIT}))throw new Error(tr(12));if(void 0===o(void 0,{type:rr.PROBE_UNKNOWN_ACTION()}))throw new Error(tr(13))}))}(o)}catch(t){n=t}return function(t,e){if(void 0===t&&(t={}),n)throw n;for(var r=!1,i={},s=0;s<a.length;s++){var c=a[s],l=o[c],f=t[c],h=l(f,e);if(void 0===h)throw e&&e.type,new Error(tr(14));i[c]=h,r=r||h!==f}return(r=r||a.length!==Object.keys(t).length)?i:t}}function ar(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return 0===e.length?function(t){return t}:1===e.length?e[0]:e.reduce((function(t,e){return function(){return t(e.apply(void 0,arguments))}}))}function sr(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return function(t){return function(){var o=t.apply(void 0,arguments),r=function(){throw new Error(tr(15))},i={getState:o.getState,dispatch:function(){return r.apply(void 0,arguments)}},n=e.map((function(t){return t(i)}));return r=ar.apply(void 0,n)(o.dispatch),Qo(Qo({},o),{},{dispatch:r})}}}function cr(t){return function(e){var o=e.dispatch,r=e.getState;return function(e){return function(i){return"function"==typeof i?i(o,r,t):e(i)}}}}var lr=cr();lr.withExtraArgument=cr;var fr,hr=lr,ur=(fr=function(t,e){return fr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])},fr(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}fr(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),dr=function(t,e){var o,r,i,n,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return n={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(n[Symbol.iterator]=function(){return this}),n;function s(n){return function(s){return function(n){if(o)throw new TypeError("Generator is already executing.");for(;a;)try{if(o=1,r&&(i=2&n[0]?r.return:n[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,n[1])).done)return i;switch(r=0,i&&(n=[2&n[0],i.value]),n[0]){case 0:case 1:i=n;break;case 4:return a.label++,{value:n[1],done:!1};case 5:a.label++,r=n[1],n=[0];continue;case 7:n=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==n[0]&&2!==n[0])){a=0;continue}if(3===n[0]&&(!i||n[1]>i[0]&&n[1]<i[3])){a.label=n[1];break}if(6===n[0]&&a.label<i[1]){a.label=i[1],i=n;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(n);break}i[2]&&a.ops.pop(),a.trys.pop();continue}n=e.call(t,a)}catch(t){n=[6,t],r=0}finally{o=i=0}if(5&n[0])throw n[1];return{value:n[0]?n[1]:void 0,done:!0}}([n,s])}}},pr=function(t,e){for(var o=0,r=e.length,i=t.length;o<r;o++,i++)t[i]=e[o];return t},yr=Object.defineProperty,gr=Object.defineProperties,br=Object.getOwnPropertyDescriptors,mr=Object.getOwnPropertySymbols,vr=Object.prototype.hasOwnProperty,Or=Object.prototype.propertyIsEnumerable,xr=function(t,e,o){return e in t?yr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o},wr=function(t,e){for(var o in e||(e={}))vr.call(e,o)&&xr(t,o,e[o]);if(mr)for(var r=0,i=mr(e);r<i.length;r++){o=i[r];Or.call(e,o)&&xr(t,o,e[o])}return t},Nr=function(t,e){return gr(t,br(e))},Sr="undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(0!==arguments.length)return"object"==typeof arguments[0]?ar:ar.apply(null,arguments)};var Cr=function(t){function e(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return ur(e,t),Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var e=[],o=0;o<arguments.length;o++)e[o]=arguments[o];return t.prototype.concat.apply(this,e)},e.prototype.prepend=function(){for(var t=[],o=0;o<arguments.length;o++)t[o]=arguments[o];return 1===t.length&&Array.isArray(t[0])?new(e.bind.apply(e,pr([void 0],t[0].concat(this)))):new(e.bind.apply(e,pr([void 0],t.concat(this))))},e}(Array),Er=function(t){function e(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return ur(e,t),Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var e=[],o=0;o<arguments.length;o++)e[o]=arguments[o];return t.prototype.concat.apply(this,e)},e.prototype.prepend=function(){for(var t=[],o=0;o<arguments.length;o++)t[o]=arguments[o];return 1===t.length&&Array.isArray(t[0])?new(e.bind.apply(e,pr([void 0],t[0].concat(this)))):new(e.bind.apply(e,pr([void 0],t.concat(this))))},e}(Array);function Rr(t){return Qe(t)?qo(t,(function(){})):t}function Ur(){return function(t){return function(t){void 0===t&&(t={});var e=t.thunk,o=void 0===e||e;t.immutableCheck,t.serializableCheck;var r=new Cr;o&&(!function(t){return"boolean"==typeof t}(o)?r.push(hr.withExtraArgument(o.extraArgument)):r.push(hr));return r}(t)}}function Ir(t){var e,o=Ur(),r=t||{},i=r.reducer,n=void 0===i?void 0:i,a=r.middleware,s=void 0===a?o():a,c=r.devTools,l=void 0===c||c,f=r.preloadedState,h=void 0===f?void 0:f,u=r.enhancers,d=void 0===u?void 0:u;if("function"==typeof n)e=n;else{if(!function(t){if("object"!=typeof t||null===t)return!1;var e=Object.getPrototypeOf(t);if(null===e)return!0;for(var o=e;null!==Object.getPrototypeOf(o);)o=Object.getPrototypeOf(o);return e===o}(n))throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');e=nr(n)}var p=s;"function"==typeof p&&(p=p(o));var y=sr.apply(void 0,p),g=ar;l&&(g=Sr(wr({trace:!1},"object"==typeof l&&l)));var b=new Er(y),m=b;return Array.isArray(d)?m=pr([y],d):"function"==typeof d&&(m=d(b)),ir(e,h,g.apply(void 0,m))}function kr(t,e){function o(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];if(e){var i=e.apply(void 0,o);if(!i)throw new Error("prepareAction did not return an object");return wr(wr({type:t,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:t,payload:o[0]}}return o.toString=function(){return""+t},o.type=t,o.match=function(e){return e.type===t},o}function Lr(t){var e,o={},r=[],i={addCase:function(t,e){var r="string"==typeof t?t:t.type;if(r in o)throw new Error("addCase cannot be called with two reducers for the same action type");return o[r]=e,i},addMatcher:function(t,e){return r.push({matcher:t,reducer:e}),i},addDefaultCase:function(t){return e=t,i}};return t(i),[o,r,e]}function Wr(t){var e=t.name;if(!e)throw new Error("`name` is a required option for createSlice");var o,r="function"==typeof t.initialState?t.initialState:Rr(t.initialState),i=t.reducers||{},n=Object.keys(i),a={},s={},c={};function l(){var e="function"==typeof t.extraReducers?Lr(t.extraReducers):[t.extraReducers],o=e[0],i=void 0===o?{}:o,n=e[1],a=void 0===n?[]:n,c=e[2],l=void 0===c?void 0:c,f=wr(wr({},i),s);return function(t,e,o,r){void 0===o&&(o=[]);var i,n="function"==typeof e?Lr(e):[e,o,r],a=n[0],s=n[1],c=n[2];if(function(t){return"function"==typeof t}(t))i=function(){return Rr(t())};else{var l=Rr(t);i=function(){return l}}function f(t,e){void 0===t&&(t=i());var o=pr([a[e.type]],s.filter((function(t){return(0,t.matcher)(e)})).map((function(t){return t.reducer})));return 0===o.filter((function(t){return!!t})).length&&(o=[c]),o.reduce((function(t,o){if(o){var r;if(Xe(t))return void 0===(r=o(t,e))?t:r;if(Qe(t))return qo(t,(function(t){return o(t,e)}));if(void 0===(r=o(t,e))){if(null===t)return t;throw Error("A case reducer on a non-draftable value must not return undefined")}return r}return t}),t)}return f.getInitialState=i,f}(r,(function(t){for(var e in f)t.addCase(e,f[e]);for(var o=0,r=a;o<r.length;o++){var i=r[o];t.addMatcher(i.matcher,i.reducer)}l&&t.addDefaultCase(l)}))}return n.forEach((function(t){var o,r,n=i[t],l=e+"/"+t;"reducer"in n?(o=n.reducer,r=n.prepare):o=n,a[t]=o,s[l]=o,c[t]=r?kr(l,r):kr(l)})),{name:e,reducer:function(t,e){return o||(o=l()),o(t,e)},actions:c,caseReducers:a,getInitialState:function(){return o||(o=l()),o.getInitialState()}}}var Ar=["name","message","stack","code"],Kr=function(t,e){this.payload=t,this.meta=e},jr=function(t,e){this.payload=t,this.meta=e},$r=function(t){if("object"==typeof t&&null!==t){for(var e={},o=0,r=Ar;o<r.length;o++){var i=r[o];"string"==typeof t[i]&&(e[i]=t[i])}return e}return{message:String(t)}};function Mr(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}!function(){function t(t,e,o){var r=kr(t+"/fulfilled",(function(t,e,o,r){return{payload:t,meta:Nr(wr({},r||{}),{arg:o,requestId:e,requestStatus:"fulfilled"})}})),i=kr(t+"/pending",(function(t,e,o){return{payload:void 0,meta:Nr(wr({},o||{}),{arg:e,requestId:t,requestStatus:"pending"})}})),n=kr(t+"/rejected",(function(t,e,r,i,n){return{payload:i,error:(o&&o.serializeError||$r)(t||"Rejected"),meta:Nr(wr({},n||{}),{arg:r,requestId:e,rejectedWithValue:!!i,requestStatus:"rejected",aborted:"AbortError"===(null==t?void 0:t.name),condition:"ConditionError"===(null==t?void 0:t.name)})}})),a="undefined"!=typeof AbortController?AbortController:function(){function t(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return t.prototype.abort=function(){},t}();return Object.assign((function(t){return function(s,c,l){var f,h=(null==o?void 0:o.idGenerator)?o.idGenerator(t):function(t){void 0===t&&(t=21);for(var e="",o=t;o--;)e+="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW"[64*Math.random()|0];return e}(),u=new a;function d(t){f=t,u.abort()}var p=function(){return a=this,p=null,y=function(){var a,p,y,g,b,m;return dr(this,(function(v){switch(v.label){case 0:return v.trys.push([0,4,,5]),g=null==(a=null==o?void 0:o.condition)?void 0:a.call(o,t,{getState:c,extra:l}),null===(O=g)||"object"!=typeof O||"function"!=typeof O.then?[3,2]:[4,g];case 1:g=v.sent(),v.label=2;case 2:if(!1===g||u.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return b=new Promise((function(t,e){return u.signal.addEventListener("abort",(function(){return e({name:"AbortError",message:f||"Aborted"})}))})),s(i(h,t,null==(p=null==o?void 0:o.getPendingMeta)?void 0:p.call(o,{requestId:h,arg:t},{getState:c,extra:l}))),[4,Promise.race([b,Promise.resolve(e(t,{dispatch:s,getState:c,extra:l,requestId:h,signal:u.signal,abort:d,rejectWithValue:function(t,e){return new Kr(t,e)},fulfillWithValue:function(t,e){return new jr(t,e)}})).then((function(e){if(e instanceof Kr)throw e;return e instanceof jr?r(e.payload,h,t,e.meta):r(e,h,t)}))])];case 3:return y=v.sent(),[3,5];case 4:return m=v.sent(),y=m instanceof Kr?n(null,h,t,m.payload,m.meta):n(m,h,t),[3,5];case 5:return o&&!o.dispatchConditionRejection&&n.match(y)&&y.meta.condition||s(y),[2,y]}var O}))},new Promise((function(t,e){var o=function(t){try{i(y.next(t))}catch(t){e(t)}},r=function(t){try{i(y.throw(t))}catch(t){e(t)}},i=function(e){return e.done?t(e.value):Promise.resolve(e.value).then(o,r)};i((y=y.apply(a,p)).next())}));var a,p,y}();return Object.assign(p,{abort:d,requestId:h,arg:t,unwrap:function(){return p.then(Mr)}})}}),{pending:i,rejected:n,fulfilled:r,typePrefix:t})}t.withTypes=function(){return t}}();var Zr,Pr,Fr="listenerMiddleware";kr(Fr+"/add"),kr(Fr+"/removeAll"),kr(Fr+"/remove"),"function"==typeof queueMicrotask&&queueMicrotask.bind("undefined"!=typeof window?window:"undefined"!=typeof global?global:globalThis),function(){function t(t,e){var o=i[t];return o?o.enumerable=e:i[t]=o={configurable:!0,enumerable:e,get:function(){var e=this[Po];return Do.get(e,t)},set:function(e){var o=this[Po];Do.set(o,t,e)}},o}function e(t){for(var e=t.length-1;e>=0;e--){var i=t[e][Po];if(!i.P)switch(i.i){case 5:r(i)&&Eo(i);break;case 4:o(i)&&Eo(i)}}}function o(t){for(var e=t.t,o=t.k,r=Bo(o),i=r.length-1;i>=0;i--){var n=r[i];if(n!==Po){var a=e[n];if(void 0===a&&!oo(e,n))return!0;var s=o[n],c=s&&s[Po];if(c?c.t!==a:!io(s,a))return!0}}var l=!!e[Po];return r.length!==Bo(e).length+(l?0:1)}function r(t){var e=t.k;if(e.length!==t.t.length)return!0;var o=Object.getOwnPropertyDescriptor(e,e.length-1);if(o&&!o.get)return!0;for(var r=0;r<e.length;r++)if(!e.hasOwnProperty(r))return!0;return!1}var i={};!function(t,e){_o[t]||(_o[t]=e)}("ES5",{J:function(e,o){var r=Array.isArray(e),i=function(e,o){if(e){for(var r=Array(o.length),i=0;i<o.length;i++)Object.defineProperty(r,""+i,t(i,!0));return r}var n=To(o);delete n[Po];for(var a=Bo(n),s=0;s<a.length;s++){var c=a[s];n[c]=t(c,e||!!n[c].enumerable)}return Object.create(Object.getPrototypeOf(o),n)}(r,e),n={i:r?5:4,A:o?o.A:po(),P:!1,I:!1,R:{},l:o,t:e,k:i,o:null,g:!1,C:!1};return Object.defineProperty(i,Po,{value:n,writable:!0}),i},S:function(t,o,i){i?Xe(o)&&o[Po].A===t&&e(t.p):(t.u&&function t(e){if(e&&"object"==typeof e){var o=e[Po];if(o){var i=o.t,n=o.k,a=o.R,s=o.i;if(4===s)to(n,(function(e){e!==Po&&(void 0!==i[e]||oo(i,e)?a[e]||t(n[e]):(a[e]=!0,Eo(o)))})),to(i,(function(t){void 0!==n[t]||oo(n,t)||(a[t]=!1,Eo(o))}));else if(5===s){if(r(o)&&(Eo(o),a.length=!0),n.length<i.length)for(var c=n.length;c<i.length;c++)a[c]=!1;else for(var l=i.length;l<n.length;l++)a[l]=!0;for(var f=Math.min(n.length,i.length),h=0;h<f;h++)n.hasOwnProperty(h)||(a[h]=!0),void 0===a[h]&&t(n[h])}}}}(t.p[0]),e(t.p))},K:function(t){return 4===t.i?o(t):r(t)}})}(),window.ftReduxStores||(window.ftReduxStores={});class Br{static get(t){var e;const o="string"==typeof t?t:t.name,r="string"==typeof t?void 0:t,i=window.ftReduxStores[o];if(_e(i))return i;if(null==r)return;const n=Wr({...r,reducers:null!==(e=r.reducers)&&void 0!==e?e:{}}),a=Ir({reducer:(t,e)=>{var o;switch(e.type){case"CLEAR_FT_REDUX_STORE":return n.getInitialState();case"DEFAULT_STATE_FIELDS_VALUES_SETTER":return{...t,...null!==(o=e.overwrites)&&void 0!==o?o:{}};default:return n.reducer(t,e)}}});return window.ftReduxStores[r.name]=new Br(n,a)}constructor(t,e){this.reduxSlice=t,this.reduxStore=e,this.isFtReduxStore=!0,this.eventBus=document.createElement("event-bus"),this.commands=new Te,this.actions=new Proxy(this.reduxSlice.actions,{get:(t,e,o)=>{const r=e,i=t[r];return i?(...t)=>{const e=i(...t);return this.reduxStore.dispatch(e),e}:t=>{this.setState({[r]:t})}}})}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE"})}setState(t){this.reduxStore.dispatch({type:"DEFAULT_STATE_FIELDS_VALUES_SETTER",overwrites:t})}get dispatch(){throw new Error("Don't use this method, actions are automatically dispatched when called.")}[Symbol.observable](){return this.reduxStore[Symbol.observable]()}getState(){return this.reduxStore.getState()}replaceReducer(t){throw new Error("Not implemented yet.")}subscribe(t){return this.reduxStore.subscribe(t)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}}navigator.vendor&&navigator.vendor.match(/apple/i)||(null===(Pr=null===(Zr=window.safari)||void 0===Zr?void 0:Zr.pushNotification)||void 0===Pr||Pr.toString());const Tr={colorError:we.external(Ce.colorError,"Design system"),fontFamily:we.external(Ce.contentFont,"Design system")},_r=wt`
|
|
116
116
|
.topic {
|
|
117
117
|
font-family: ${Tr.fontFamily};
|
|
118
118
|
overflow-x: auto;
|
|
@@ -129,7 +129,7 @@ let ve=class extends Zt{constructor(){super(...arguments),this.renderOptions={ho
|
|
|
129
129
|
.topic-loading {
|
|
130
130
|
height: 100vh;
|
|
131
131
|
}
|
|
132
|
-
`;var
|
|
132
|
+
`;var Dr;!function(t){t.FEEDBACK="FEEDBACK",t.RATING="RATING",t.PRINT="PRINT",t.BOOKMARK="BOOKMARK",t.COLLECTIONS="COLLECTIONS",t.PERSONAL_BOOKS="PERSONAL_BOOKS"}(Dr||(Dr={}));var zr=function(t,e,o,r){for(var i,n=arguments.length,a=n<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,o):r,s=t.length-1;s>=0;s--)(i=t[s])&&(a=(n<3?i(a):n>3?i(e,o,a):i(e,o))||a);return n>3&&a&&Object.defineProperty(e,o,a),a};class Gr extends Event{constructor(){super("register-ft-reader-component",{bubbles:!0,composed:!0})}}const Hr=Symbol("registerInterval");class qr extends(function(t){var e;class o extends t{constructor(){super(...arguments),this[e]=0}setReaderStateManager(t){this.clearStateManager(),this.stateManager=t,this.addStore(t.store,"reader")}clearStateManager(){this.stateManager&&(this.removeStore("reader"),this.stateManager=void 0)}get service(){var t;return null===(t=this.stateManager)||void 0===t?void 0:t.service}connectedCallback(){super.connectedCallback(),this[Hr]=window.setInterval((()=>this.tryToRegisterToContext()),50)}tryToRegisterToContext(){null!=this.stateManager?window.clearInterval(this[Hr]):this.dispatchEvent(new Gr)}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return e=Hr,zr([I()],o.prototype,"stateManager",void 0),o}(Ye)){}var Jr=function(t,e,o,r){for(var i,n=arguments.length,a=n<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,o):r,s=t.length-1;s>=0;s--)(i=t[s])&&(a=(n<3?i(a):n>3?i(e,o,a):i(e,o))||a);return n>3&&a&&Object.defineProperty(e,o,a),a};class Yr extends Event{constructor(){super("register-ft-reader-topic-component",{bubbles:!0,composed:!0})}}const Vr=Symbol("registerInterval");class Xr extends(function(t){var e;class o extends t{constructor(){super(...arguments),this.disableContextInteractions=!1,this[e]=0}connectedCallback(){super.connectedCallback(),this[Vr]=window.setInterval((()=>this.tryToRegisterToTopicContext()),50)}tryToRegisterToTopicContext(){null!=this.tocNode?window.clearInterval(this[Vr]):this.dispatchEvent(new Yr)}disconnectedCallback(){super.disconnectedCallback(),this.tocNode=void 0}}return e=Vr,Jr([I()],o.prototype,"tocNode",void 0),Jr([I()],o.prototype,"disableContextInteractions",void 0),o}(qr)){}
|
|
133
133
|
/**
|
|
134
134
|
* @license
|
|
135
135
|
* Copyright 2017 Google LLC
|
|
@@ -209,7 +209,7 @@ let ve=class extends Zt{constructor(){super(...arguments),this.renderOptions={ho
|
|
|
209
209
|
</section>
|
|
210
210
|
`:ie`
|
|
211
211
|
<section class="topic-loading"></section>
|
|
212
|
-
`}update(t){super.update(t),(t.has("map")||t.has("tocNode"))&&this.updateContent()}updated(t){super.updated(t),this.updateComplete.then((()=>A((()=>this.topicContainer)))).then((t=>function(t,e){var o;let r=t.getAttribute("data-highlight-html-query");if((null!=r?r:"")!==(null!=e?e:"")){const r=new $e(t);r.unmark(Pe),e&&e.trim()&&(r.mark(e.replace(/"[^"]+"/g,""),{...Pe,separateWordSearch:!0}),(null!==(o=e.match(/"[^"]+"/g))&&void 0!==o?o:[]).forEach((t=>r.mark(t.replace(/"/g,""),{...Pe,separateWordSearch:!1}))))}t.setAttribute("data-highlight-html-query",null!=e?e:"")}(t,this.searchInDocumentQuery)))}updateContent(){var t;this.error=void 0,this.content=void 0,this.map&&this.tocNode&&(null===(t=this.service)||void 0===t||t.getTopicContent(this.tocNode).then((t=>this.
|
|
212
|
+
`}update(t){super.update(t),(t.has("map")||t.has("tocNode"))&&this.updateContent()}updated(t){super.updated(t),this.updateComplete.then((()=>A((()=>this.topicContainer)))).then((t=>function(t,e){var o;let r=t.getAttribute("data-highlight-html-query");if((null!=r?r:"")!==(null!=e?e:"")){const r=new $e(t);r.unmark(Pe),e&&e.trim()&&(r.mark(e.replace(/"[^"]+"/g,""),{...Pe,separateWordSearch:!0}),(null!==(o=e.match(/"[^"]+"/g))&&void 0!==o?o:[]).forEach((t=>r.mark(t.replace(/"/g,""),{...Pe,separateWordSearch:!1}))))}t.setAttribute("data-highlight-html-query",null!=e?e:"")}(t,this.searchInDocumentQuery)))}updateContent(){var t;this.error=void 0,this.content=void 0,this.map&&this.tocNode&&(null===(t=this.service)||void 0===t||t.getTopicContent(this.tocNode).then((t=>this.contentPreprocessor(t||'<div class="empty-topic"></div>'))).then((t=>this.content=t)).catch((t=>this.error=t)))}contentAvailableCallback(t){var e,o,r,i,n,a,s;if(super.contentAvailableCallback(t),!this.disableContextInteractions&&(null===(e=this.scrollTarget)||void 0===e?void 0:e.section)&&(null===(o=this.tocNode)||void 0===o?void 0:o.tocId)&&(null===(r=this.tocNode)||void 0===r?void 0:r.tocId)===this.scrollTarget.tocId&&this.content){(null!==(n=null===(i=this.shadowRoot)||void 0===i?void 0:i.querySelector(`[id="${this.scrollTarget.section}"], [name="${this.scrollTarget.section}"]`))&&void 0!==n?n:this).scrollIntoView({block:"start"}),null===(a=this.stateManager)||void 0===a||a.scrollDone()}this.topicContainer&&(this.onContentAvailable(this.topicContainer,this.shadowRoot),this.moveSvgInShadowRoot()),(t.has("content")&&this.content||t.has("error")&&this.error)&&performance.mark("fluid_topics__reader_topic_displayed__"+(null===(s=this.tocNode)||void 0===s?void 0:s.tocId))}moveSvgInShadowRoot(){this.shadowRoot.querySelectorAll(".ft-svg-container").forEach((t=>{if(!t.shadowRoot){var e=t.innerHTML;t.innerHTML="";var o=t.attachShadow({mode:"open"}),r=document.createRange().createContextualFragment(e),i=document.importNode(r,!0);o.append(i)}}))}onStoreAvailable(){super.onStoreAvailable(),this.updateContent()}renderTopicContent(){var t,e,o,r;if(this.error)return ie`
|
|
213
213
|
<div class="topic-on-error">
|
|
214
214
|
<ft-icon>WARNING</ft-icon>
|
|
215
215
|
<div>
|
|
@@ -218,6 +218,6 @@ let ve=class extends Zt{constructor(){super(...arguments),this.renderOptions={ho
|
|
|
218
218
|
</div>
|
|
219
219
|
`;const i=null!==(e=null===(t=this.map)||void 0===t?void 0:t.contentStyles.customCssClasses.join(" "))&&void 0!==e?e:"";return ie`
|
|
220
220
|
<div class="depth-${null===(o=this.tocNode)||void 0===o?void 0:o.depth} content-locale-${null===(r=this.map)||void 0===r?void 0:r.lang} ${i}">
|
|
221
|
-
${null!=this.content?oi(`${this.
|
|
221
|
+
${null!=this.content?oi(`${this.content}`):ae}
|
|
222
222
|
</div>
|
|
223
|
-
`}is404Error(){return 404===this.error.status}}Fi.styles=[
|
|
223
|
+
`}is404Error(){return 404===this.error.status}}Fi.styles=[_r,Ze],Pi([Be()],Fi.prototype,"map",void 0),Pi([Be()],Fi.prototype,"scrollTarget",void 0),Pi([I()],Fi.prototype,"content",void 0),Pi([I()],Fi.prototype,"error",void 0),Pi([Be({selector:(t,e)=>e.disableContextInteractions?"":t.searchInDocumentQuery})],Fi.prototype,"searchInDocumentQuery",void 0),Pi([U({attribute:!1})],Fi.prototype,"contentPreprocessor",void 0),Pi([U({attribute:!1})],Fi.prototype,"onContentAvailable",void 0),Pi([L("section.topic")],Fi.prototype,"topicContainer",void 0),j("ft-reader-topic-content")(Fi),t.FtReaderTopicContent=Fi,t.FtReaderTopicContentCssVariables=Tr,t.styles=_r}({});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluid-topics/ft-reader-topic-content",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.22",
|
|
4
4
|
"description": "Content of a topic in integrated reader.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Lit"
|
|
@@ -19,14 +19,14 @@
|
|
|
19
19
|
"url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@fluid-topics/ft-chip": "1.1.
|
|
23
|
-
"@fluid-topics/ft-i18n": "1.1.
|
|
24
|
-
"@fluid-topics/ft-reader-context": "1.1.
|
|
25
|
-
"@fluid-topics/ft-reader-topic-context": "1.1.
|
|
26
|
-
"@fluid-topics/ft-tooltip": "1.1.
|
|
27
|
-
"@fluid-topics/ft-wc-utils": "1.1.
|
|
22
|
+
"@fluid-topics/ft-chip": "1.1.22",
|
|
23
|
+
"@fluid-topics/ft-i18n": "1.1.22",
|
|
24
|
+
"@fluid-topics/ft-reader-context": "1.1.22",
|
|
25
|
+
"@fluid-topics/ft-reader-topic-context": "1.1.22",
|
|
26
|
+
"@fluid-topics/ft-tooltip": "1.1.22",
|
|
27
|
+
"@fluid-topics/ft-wc-utils": "1.1.22",
|
|
28
28
|
"@fluid-topics/public-api": "1.0.55",
|
|
29
29
|
"lit": "3.1.0"
|
|
30
30
|
},
|
|
31
|
-
"gitHead": "
|
|
31
|
+
"gitHead": "89c8b3562faee77c5ae79180f255aa9021f4d229"
|
|
32
32
|
}
|