@fluid-topics/ft-app-context 1.1.3 → 1.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -12,7 +12,7 @@
12
12
  * subject to an additional IP rights grant found at
13
13
  * http://polymer.github.io/PATENTS.txt
14
14
  */
15
- if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,o=window.customElements.define,r=window.customElements.get,e=window.customElements,n=new WeakMap,i=new WeakMap,a=new WeakMap,c=new WeakMap;let s;window.CustomElementRegistry=class{constructor(){this._definitionsByTag=new Map,this._definitionsByClass=new Map,this._whenDefinedPromises=new Map,this._awaitingUpgrade=new Map}define(t,n){if(t=t.toLowerCase(),void 0!==this._getDefinition(t))throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': the name "${t}" has already been used with this registry`);if(void 0!==this._definitionsByClass.get(n))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const c=n.prototype.attributeChangedCallback,s=new Set(n.observedAttributes||[]);h(n,s,c);const l={elementClass:n,connectedCallback:n.prototype.connectedCallback,disconnectedCallback:n.prototype.disconnectedCallback,adoptedCallback:n.prototype.adoptedCallback,attributeChangedCallback:c,formAssociated:n.formAssociated,formAssociatedCallback:n.prototype.formAssociatedCallback,formDisabledCallback:n.prototype.formDisabledCallback,formResetCallback:n.prototype.formResetCallback,formStateRestoreCallback:n.prototype.formStateRestoreCallback,observedAttributes:s};this._definitionsByTag.set(t,l),this._definitionsByClass.set(n,l);let f=r.call(e,t);f||(f=u(t),o.call(e,t,f)),this===window.customElements&&(a.set(n,l),l.standInClass=f);const d=this._awaitingUpgrade.get(t);if(d){this._awaitingUpgrade.delete(t);for(const t of d)i.delete(t),p(t,l,!0)}const y=this._whenDefinedPromises.get(t);return void 0!==y&&(y.resolve(n),this._whenDefinedPromises.delete(t)),n}upgrade(){b.push(this),e.upgrade.apply(e,arguments),b.pop()}get(t){const o=this._definitionsByTag.get(t);return o?.elementClass}_getDefinition(t){return this._definitionsByTag.get(t)}whenDefined(t){const o=this._getDefinition(t);if(void 0!==o)return Promise.resolve(o.elementClass);let r=this._whenDefinedPromises.get(t);return void 0===r&&(r={},r.promise=new Promise((t=>r.resolve=t)),this._whenDefinedPromises.set(t,r)),r.promise}_upgradeWhenDefined(t,o,r){let e=this._awaitingUpgrade.get(o);e||this._awaitingUpgrade.set(o,e=new Set),r?e.add(t):e.delete(t)}},window.HTMLElement=function(){let o=s;if(o)return s=void 0,o;const r=a.get(this.constructor);if(!r)throw new TypeError("Illegal constructor (custom element class must be registered with global customElements registry to be newable)");return o=Reflect.construct(t,[],r.standInClass),Object.setPrototypeOf(o,this.constructor.prototype),n.set(o,r),o},window.HTMLElement.prototype=t.prototype;const l=t=>t===document||t instanceof ShadowRoot,f=t=>{let o=t.getRootNode();if(!l(o)){const t=b[b.length-1];if(t instanceof CustomElementRegistry)return t;o=t.getRootNode(),l(o)||(o=c.get(o)?.getRootNode()||document)}return o.customElements},u=o=>class{static get formAssociated(){return!0}constructor(){const r=Reflect.construct(t,[],this.constructor);Object.setPrototypeOf(r,HTMLElement.prototype);const e=f(r)||window.customElements,n=e._getDefinition(o);return n?p(r,n):i.set(r,e),r}connectedCallback(){const t=n.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):i.get(this)._upgradeWhenDefined(this,o,!0)}disconnectedCallback(){const t=n.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):i.get(this)._upgradeWhenDefined(this,o,!1)}adoptedCallback(){const t=n.get(this);t?.adoptedCallback?.apply(this,arguments)}formAssociatedCallback(){const t=n.get(this);t&&t.formAssociated&&t?.formAssociatedCallback?.apply(this,arguments)}formDisabledCallback(){const t=n.get(this);t?.formAssociated&&t?.formDisabledCallback?.apply(this,arguments)}formResetCallback(){const t=n.get(this);t?.formAssociated&&t?.formResetCallback?.apply(this,arguments)}formStateRestoreCallback(){const t=n.get(this);t?.formAssociated&&t?.formStateRestoreCallback?.apply(this,arguments)}},h=(t,o,r)=>{if(0===o.size||void 0===r)return;const e=t.prototype.setAttribute;e&&(t.prototype.setAttribute=function(t,n){const i=t.toLowerCase();if(o.has(i)){const t=this.getAttribute(i);e.call(this,i,n),r.call(this,i,t,n)}else e.call(this,i,n)});const n=t.prototype.removeAttribute;n&&(t.prototype.removeAttribute=function(t){const e=t.toLowerCase();if(o.has(e)){const t=this.getAttribute(e);n.call(this,e),r.call(this,e,t,null)}else n.call(this,e)});const i=t.prototype.toggleAttribute;i&&(t.prototype.toggleAttribute=function(t,e){const n=t.toLowerCase();if(o.has(n)){const t=this.getAttribute(n);i.call(this,n,e);const o=this.getAttribute(n);r.call(this,n,t,o)}else i.call(this,n,e)})},d=o=>{const r=Object.getPrototypeOf(o);if(r!==window.HTMLElement)return r===t?Object.setPrototypeOf(o,window.HTMLElement):d(r)},p=(t,o,r=!1)=>{Object.setPrototypeOf(t,o.elementClass.prototype),n.set(t,o),s=t;try{new o.elementClass}catch(t){d(o.elementClass),new o.elementClass}o.attributeChangedCallback&&o.observedAttributes.forEach((r=>{t.hasAttribute(r)&&o.attributeChangedCallback.call(t,r,null,t.getAttribute(r))})),r&&o.connectedCallback&&t.isConnected&&o.connectedCallback.call(t)},y=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const o=y.apply(this,arguments);return t.customElements&&(o.customElements=t.customElements),o};let b=[document];const g=(t,o,r=void 0)=>{const e=(r?Object.getPrototypeOf(r):t.prototype)[o];t.prototype[o]=function(){b.push(this);const t=e.apply(r||this,arguments);return void 0!==t&&c.set(t,this),b.pop(),t}};g(ShadowRoot,"createElement",document),g(ShadowRoot,"importNode",document),g(Element,"insertAdjacentHTML");const m=(t,o)=>{const r=Object.getOwnPropertyDescriptor(t.prototype,o);Object.defineProperty(t.prototype,o,{...r,set(t){b.push(this),r.set.call(this,t),b.pop()}})};if(m(Element,"innerHTML"),m(ShadowRoot,"innerHTML"),Object.defineProperty(window,"customElements",{value:new CustomElementRegistry,configurable:!0,writable:!0}),window.ElementInternals&&window.ElementInternals.prototype.setFormValue){const t=new WeakMap,o=HTMLElement.prototype.attachInternals,r=["setFormValue","setValidity","checkValidity","reportValidity"];HTMLElement.prototype.attachInternals=function(...r){const e=o.call(this,...r);return t.set(e,this),e},r.forEach((o=>{const r=window.ElementInternals.prototype,e=r[o];r[o]=function(...o){const r=t.get(this);if(!0===n.get(r).formAssociated)return e?.call(this,...o);throw new DOMException(`Failed to execute ${e} on 'ElementInternals': The target element is not a form-associated custom element.`)}}));class e extends Array{constructor(t){super(...t),this._elements=t}get value(){return this._elements.find((t=>!0===t.checked))?.value||""}}class i{constructor(t){const o=new Map;t.forEach(((t,r)=>{const e=t.getAttribute("name"),n=o.get(e)||[];this[+r]=t,n.push(t),o.set(e,n)})),this.length=t.length,o.forEach(((t,o)=>{t&&(1===t.length?this[o]=t[0]:this[o]=new e(t))}))}namedItem(t){return this[t]}}const a=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get:function(){const t=a.get.call(this,[]),o=[];for(const r of t){const t=n.get(r);t&&!0!==t.formAssociated||o.push(r)}return new i(o)}})}}try{window.customElements.define("custom-element",null)}catch(No){const t=window.customElements.define;window.customElements.define=(o,r,e)=>{if(null!==r)try{t.bind(window.customElements)(o,r,e)}catch(t){console.info(o,r,e,t)}}}class o extends Error{constructor(t,o,r){super(t),this.canceledPromiseResult=o,this.canceledPromiseError=r}}class r extends Promise{constructor(t){super(((r,e)=>t((t=>{this.isCanceled?e(new o("Promise has been canceled",t)):r(t)}),(t=>{this.isCanceled?e(new o("Promise has been canceled",void 0,t)):e(t)})))),this.isCanceled=!1}cancel(){this.isCanceled=!0}}class e{constructor(){this.loaders={},this.content={},this.clearTimeouts={},this.finalContent=new Set}register(t,o){this.loaders[t]=o,this.finalContent.delete(t)}registerFinal(t,o){this.loaders[t]=o,this.finalContent.add(t)}clearAll(){for(let t in this.content)this.clear(t)}clear(t){this.finalContent.has(t)||this.forceClear(t)}forceClear(t){this.clearClearTimeout(t),this.content[t]instanceof r&&this.content[t].cancel(),delete this.content[t]}clearClearTimeout(t){null!=this.clearTimeouts[t]&&(window.clearTimeout(this.clearTimeouts[t]),delete this.clearTimeouts[t])}set(t,o){this.forceClear(t),this.register(t,(async()=>o)),this.content[t]=o}setFinal(t,o){this.forceClear(t),this.registerFinal(t,(async()=>o)),this.content[t]=o}async get(t,o,e){if(void 0===this.content[t]){if(null==(o=null!=o?o:this.loaders[t]))throw new Error("Unknown cache key "+t);const n=(t=>new r(((o,r)=>t.then(o).catch(r))))(o());return this.content[t]=n,n.then((o=>(this.content[t]=o,null!=e&&(this.clearClearTimeout(t),this.clearTimeouts[t]=window.setTimeout((()=>this.clear(t)),e)),o)))}if(this.content[t]instanceof Error)throw this.content[t];return this.content[t]}isResolvedValue(t){return!(null==t||t instanceof Promise||t instanceof Error)}getNow(t){if(this.isResolvedValue(this.content[t]))return this.content[t]}has(t){return null!=this.content[t]}resolvedKeys(){return Object.keys(this.content).filter((t=>this.isResolvedValue(this.content[t])))}resolvedValues(){return Object.values(this.content).filter((t=>this.isResolvedValue(t)))}keys(){return Object.keys(this.content)}values(){return Object.values(this.content)}}
15
+ if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,o=window.customElements.define,r=window.customElements.get,e=window.customElements,n=new WeakMap,i=new WeakMap,a=new WeakMap,c=new WeakMap;let s;window.CustomElementRegistry=class{constructor(){this._definitionsByTag=new Map,this._definitionsByClass=new Map,this._whenDefinedPromises=new Map,this._awaitingUpgrade=new Map}define(t,n){if(t=t.toLowerCase(),void 0!==this._getDefinition(t))throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': the name "${t}" has already been used with this registry`);if(void 0!==this._definitionsByClass.get(n))throw new DOMException("Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry");const c=n.prototype.attributeChangedCallback,s=new Set(n.observedAttributes||[]);u(n,s,c);const l={elementClass:n,connectedCallback:n.prototype.connectedCallback,disconnectedCallback:n.prototype.disconnectedCallback,adoptedCallback:n.prototype.adoptedCallback,attributeChangedCallback:c,formAssociated:n.formAssociated,formAssociatedCallback:n.prototype.formAssociatedCallback,formDisabledCallback:n.prototype.formDisabledCallback,formResetCallback:n.prototype.formResetCallback,formStateRestoreCallback:n.prototype.formStateRestoreCallback,observedAttributes:s};this._definitionsByTag.set(t,l),this._definitionsByClass.set(n,l);let f=r.call(e,t);f||(f=h(t),o.call(e,t,f)),this===window.customElements&&(a.set(n,l),l.standInClass=f);const d=this._awaitingUpgrade.get(t);if(d){this._awaitingUpgrade.delete(t);for(const t of d)i.delete(t),p(t,l,!0)}const y=this._whenDefinedPromises.get(t);return void 0!==y&&(y.resolve(n),this._whenDefinedPromises.delete(t)),n}upgrade(){b.push(this),e.upgrade.apply(e,arguments),b.pop()}get(t){const o=this._definitionsByTag.get(t);return o?.elementClass}_getDefinition(t){return this._definitionsByTag.get(t)}whenDefined(t){const o=this._getDefinition(t);if(void 0!==o)return Promise.resolve(o.elementClass);let r=this._whenDefinedPromises.get(t);return void 0===r&&(r={},r.promise=new Promise((t=>r.resolve=t)),this._whenDefinedPromises.set(t,r)),r.promise}_upgradeWhenDefined(t,o,r){let e=this._awaitingUpgrade.get(o);e||this._awaitingUpgrade.set(o,e=new Set),r?e.add(t):e.delete(t)}},window.HTMLElement=function(){let o=s;if(o)return s=void 0,o;const r=a.get(this.constructor);if(!r)throw new TypeError("Illegal constructor (custom element class must be registered with global customElements registry to be newable)");return o=Reflect.construct(t,[],r.standInClass),Object.setPrototypeOf(o,this.constructor.prototype),n.set(o,r),o},window.HTMLElement.prototype=t.prototype;const l=t=>t===document||t instanceof ShadowRoot,f=t=>{let o=t.getRootNode();if(!l(o)){const t=b[b.length-1];if(t instanceof CustomElementRegistry)return t;o=t.getRootNode(),l(o)||(o=c.get(o)?.getRootNode()||document)}return o.customElements},h=o=>class{static get formAssociated(){return!0}constructor(){const r=Reflect.construct(t,[],this.constructor);Object.setPrototypeOf(r,HTMLElement.prototype);const e=f(r)||window.customElements,n=e._getDefinition(o);return n?p(r,n):i.set(r,e),r}connectedCallback(){const t=n.get(this);t?t.connectedCallback&&t.connectedCallback.apply(this,arguments):i.get(this)._upgradeWhenDefined(this,o,!0)}disconnectedCallback(){const t=n.get(this);t?t.disconnectedCallback&&t.disconnectedCallback.apply(this,arguments):i.get(this)._upgradeWhenDefined(this,o,!1)}adoptedCallback(){const t=n.get(this);t?.adoptedCallback?.apply(this,arguments)}formAssociatedCallback(){const t=n.get(this);t&&t.formAssociated&&t?.formAssociatedCallback?.apply(this,arguments)}formDisabledCallback(){const t=n.get(this);t?.formAssociated&&t?.formDisabledCallback?.apply(this,arguments)}formResetCallback(){const t=n.get(this);t?.formAssociated&&t?.formResetCallback?.apply(this,arguments)}formStateRestoreCallback(){const t=n.get(this);t?.formAssociated&&t?.formStateRestoreCallback?.apply(this,arguments)}},u=(t,o,r)=>{if(0===o.size||void 0===r)return;const e=t.prototype.setAttribute;e&&(t.prototype.setAttribute=function(t,n){const i=t.toLowerCase();if(o.has(i)){const t=this.getAttribute(i);e.call(this,i,n),r.call(this,i,t,n)}else e.call(this,i,n)});const n=t.prototype.removeAttribute;n&&(t.prototype.removeAttribute=function(t){const e=t.toLowerCase();if(o.has(e)){const t=this.getAttribute(e);n.call(this,e),r.call(this,e,t,null)}else n.call(this,e)});const i=t.prototype.toggleAttribute;i&&(t.prototype.toggleAttribute=function(t,e){const n=t.toLowerCase();if(o.has(n)){const t=this.getAttribute(n);i.call(this,n,e);const o=this.getAttribute(n);r.call(this,n,t,o)}else i.call(this,n,e)})},d=o=>{const r=Object.getPrototypeOf(o);if(r!==window.HTMLElement)return r===t?Object.setPrototypeOf(o,window.HTMLElement):d(r)},p=(t,o,r=!1)=>{Object.setPrototypeOf(t,o.elementClass.prototype),n.set(t,o),s=t;try{new o.elementClass}catch(t){d(o.elementClass),new o.elementClass}o.attributeChangedCallback&&o.observedAttributes.forEach((r=>{t.hasAttribute(r)&&o.attributeChangedCallback.call(t,r,null,t.getAttribute(r))})),r&&o.connectedCallback&&t.isConnected&&o.connectedCallback.call(t)},y=Element.prototype.attachShadow;Element.prototype.attachShadow=function(t){const o=y.apply(this,arguments);return t.customElements&&(o.customElements=t.customElements),o};let b=[document];const g=(t,o,r=void 0)=>{const e=(r?Object.getPrototypeOf(r):t.prototype)[o];t.prototype[o]=function(){b.push(this);const t=e.apply(r||this,arguments);return void 0!==t&&c.set(t,this),b.pop(),t}};g(ShadowRoot,"createElement",document),g(ShadowRoot,"importNode",document),g(Element,"insertAdjacentHTML");const m=(t,o)=>{const r=Object.getOwnPropertyDescriptor(t.prototype,o);Object.defineProperty(t.prototype,o,{...r,set(t){b.push(this),r.set.call(this,t),b.pop()}})};if(m(Element,"innerHTML"),m(ShadowRoot,"innerHTML"),Object.defineProperty(window,"customElements",{value:new CustomElementRegistry,configurable:!0,writable:!0}),window.ElementInternals&&window.ElementInternals.prototype.setFormValue){const t=new WeakMap,o=HTMLElement.prototype.attachInternals,r=["setFormValue","setValidity","checkValidity","reportValidity"];HTMLElement.prototype.attachInternals=function(...r){const e=o.call(this,...r);return t.set(e,this),e},r.forEach((o=>{const r=window.ElementInternals.prototype,e=r[o];r[o]=function(...o){const r=t.get(this);if(!0===n.get(r).formAssociated)return e?.call(this,...o);throw new DOMException(`Failed to execute ${e} on 'ElementInternals': The target element is not a form-associated custom element.`)}}));class e extends Array{constructor(t){super(...t),this._elements=t}get value(){return this._elements.find((t=>!0===t.checked))?.value||""}}class i{constructor(t){const o=new Map;t.forEach(((t,r)=>{const e=t.getAttribute("name"),n=o.get(e)||[];this[+r]=t,n.push(t),o.set(e,n)})),this.length=t.length,o.forEach(((t,o)=>{t&&(1===t.length?this[o]=t[0]:this[o]=new e(t))}))}namedItem(t){return this[t]}}const a=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get:function(){const t=a.get.call(this,[]),o=[];for(const r of t){const t=n.get(r);t&&!0!==t.formAssociated||o.push(r)}return new i(o)}})}}try{window.customElements.define("custom-element",null)}catch(No){const t=window.customElements.define;window.customElements.define=(o,r,e)=>{if(null!==r)try{t.bind(window.customElements)(o,r,e)}catch(t){console.info(o,r,e,t)}}}class o extends Error{constructor(t,o,r){super(t),this.canceledPromiseResult=o,this.canceledPromiseError=r}}class r extends Promise{constructor(t){super(((r,e)=>t((t=>{this.isCanceled?e(new o("Promise has been canceled",t)):r(t)}),(t=>{this.isCanceled?e(new o("Promise has been canceled",void 0,t)):e(t)})))),this.isCanceled=!1}cancel(){this.isCanceled=!0}}class e{constructor(){this.loaders={},this.content={},this.clearTimeouts={},this.finalContent=new Set}register(t,o){this.loaders[t]=o,this.finalContent.delete(t)}registerFinal(t,o){this.loaders[t]=o,this.finalContent.add(t)}clearAll(){for(let t in this.content)this.clear(t)}clear(t){this.finalContent.has(t)||this.forceClear(t)}forceClear(t){this.clearClearTimeout(t),this.content[t]instanceof r&&this.content[t].cancel(),delete this.content[t]}clearClearTimeout(t){null!=this.clearTimeouts[t]&&(window.clearTimeout(this.clearTimeouts[t]),delete this.clearTimeouts[t])}set(t,o){this.forceClear(t),this.register(t,(async()=>o)),this.content[t]=o}setFinal(t,o){this.forceClear(t),this.registerFinal(t,(async()=>o)),this.content[t]=o}async get(t,o,e){if(void 0===this.content[t]){if(null==(o=null!=o?o:this.loaders[t]))throw new Error("Unknown cache key "+t);const n=(t=>new r(((o,r)=>t.then(o).catch(r))))(o());return this.content[t]=n,n.then((o=>(this.content[t]=o,null!=e&&(this.clearClearTimeout(t),this.clearTimeouts[t]=window.setTimeout((()=>this.clear(t)),e)),o)))}if(this.content[t]instanceof Error)throw this.content[t];return this.content[t]}isResolvedValue(t){return!(null==t||t instanceof Promise||t instanceof Error)}getNow(t){if(this.isResolvedValue(this.content[t]))return this.content[t]}has(t){return null!=this.content[t]}resolvedKeys(){return Object.keys(this.content).filter((t=>this.isResolvedValue(this.content[t])))}resolvedValues(){return Object.values(this.content).filter((t=>this.isResolvedValue(t)))}keys(){return Object.keys(this.content)}values(){return Object.values(this.content)}}
16
16
  /**
17
17
  * @license
18
18
  * Copyright 2019 Google LLC
@@ -22,7 +22,7 @@ if(!ShadowRoot.prototype.createElement){const t=window.HTMLElement,o=window.cust
22
22
  * @license
23
23
  * Copyright 2017 Google LLC
24
24
  * SPDX-License-Identifier: BSD-3-Clause
25
- */,{is:f,defineProperty:u,getOwnPropertyDescriptor:h,getOwnPropertyNames:d,getOwnPropertySymbols:p,getPrototypeOf:y}=Object,b=globalThis,g=b.trustedTypes,m=g?g.emptyScript:"",O=b.reactiveElementPolyfillSupport,v=(t,o)=>t,N={toAttribute(t,o){switch(o){case Boolean:t=t?m:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,o){let r=t;switch(o){case Boolean:r=null!==t;break;case Number:r=null===t?null:Number(t);break;case Object:case Array:try{r=JSON.parse(t)}catch(t){r=null}}return r}},w=(t,o)=>!f(t,o),S={attribute:!0,type:String,converter:N,reflect:!1,hasChanged:w};Symbol.metadata??=Symbol("metadata"),b.litPropertyMetadata??=new WeakMap;let C=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,o=S){if(o.state&&(o.attribute=!1),this._$Ei(),this.elementProperties.set(t,o),!o.noAccessor){const r=Symbol(),e=this.getPropertyDescriptor(t,r,o);void 0!==e&&u(this.prototype,t,e)}}static getPropertyDescriptor(t,o,r){const{get:e,set:n}=h(this.prototype,t)??{get(){return this[o]},set(t){this[o]=t}};return{get(){return e?.call(this)},set(o){const i=e?.call(this);n.call(this,o),this.requestUpdate(t,i,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??S}static _$Ei(){if(this.hasOwnProperty(v("elementProperties")))return;const t=y(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(v("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(v("properties"))){const t=this.properties,o=[...d(t),...p(t)];for(const r of o)this.createProperty(r,t[r])}const t=this[Symbol.metadata];if(null!==t){const o=litPropertyMetadata.get(t);if(void 0!==o)for(const[t,r]of o)this.elementProperties.set(t,r)}this._$Eh=new Map;for(const[t,o]of this.elementProperties){const r=this._$Eu(t,o);void 0!==r&&this._$Eh.set(r,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const o=[];if(Array.isArray(t)){const r=new Set(t.flat(1/0).reverse());for(const t of r)o.unshift(l(t))}else void 0!==t&&o.push(l(t));return o}static _$Eu(t,o){const r=o.attribute;return!1===r?void 0:"string"==typeof r?r:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$Eg=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$ES(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)))}addController(t){(this._$E_??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$E_?.delete(t)}_$ES(){const t=new Map,o=this.constructor.elementProperties;for(const r of o.keys())this.hasOwnProperty(r)&&(t.set(r,this[r]),delete this[r]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((t,o)=>{if(i)t.adoptedStyleSheets=o.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const r of o){const o=document.createElement("style"),e=n.litNonce;void 0!==e&&o.setAttribute("nonce",e),o.textContent=r.cssText,t.appendChild(o)}})(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$E_?.forEach((t=>t.hostConnected?.()))}enableUpdating(t){}disconnectedCallback(){this._$E_?.forEach((t=>t.hostDisconnected?.()))}attributeChangedCallback(t,o,r){this._$AK(t,r)}_$EO(t,o){const r=this.constructor.elementProperties.get(t),e=this.constructor._$Eu(t,r);if(void 0!==e&&!0===r.reflect){const n=(void 0!==r.converter?.toAttribute?r.converter:N).toAttribute(o,r.type);this._$Em=t,null==n?this.removeAttribute(e):this.setAttribute(e,n),this._$Em=null}}_$AK(t,o){const r=this.constructor,e=r._$Eh.get(t);if(void 0!==e&&this._$Em!==e){const t=r.getPropertyOptions(e),n="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:N;this._$Em=e,this[e]=n.fromAttribute(o,t.type),this._$Em=null}}requestUpdate(t,o,r,e=!1,n){if(void 0!==t){if(r??=this.constructor.getPropertyOptions(t),!(r.hasChanged??w)(e?n:this[t],o))return;this.C(t,o,r)}!1===this.isUpdatePending&&(this._$Eg=this._$EP())}C(t,o,r){this._$AL.has(t)||this._$AL.set(t,o),!0===r.reflect&&this._$Em!==t&&(this._$Ej??=new Set).add(t)}async _$EP(){this.isUpdatePending=!0;try{await this._$Eg}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,o]of this._$Ep)this[t]=o;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[o,r]of t)!0!==r.wrapped||this._$AL.has(o)||void 0===this[o]||this.C(o,this[o],r)}let t=!1;const o=this._$AL;try{t=this.shouldUpdate(o),t?(this.willUpdate(o),this._$E_?.forEach((t=>t.hostUpdate?.())),this.update(o)):this._$ET()}catch(o){throw t=!1,this._$ET(),o}t&&this._$AE(o)}willUpdate(t){}_$AE(t){this._$E_?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$ET(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$Eg}shouldUpdate(t){return!0}update(t){this._$Ej&&=this._$Ej.forEach((t=>this._$EO(t,this[t]))),this._$ET()}updated(t){}firstUpdated(t){}};C.elementStyles=[],C.shadowRootOptions={mode:"open"},C[v("elementProperties")]=new Map,C[v("finalized")]=new Map,O?.({ReactiveElement:C}),(b.reactiveElementVersions??=[]).push("2.0.2");
25
+ */,{is:f,defineProperty:h,getOwnPropertyDescriptor:u,getOwnPropertyNames:d,getOwnPropertySymbols:p,getPrototypeOf:y}=Object,b=globalThis,g=b.trustedTypes,m=g?g.emptyScript:"",O=b.reactiveElementPolyfillSupport,v=(t,o)=>t,N={toAttribute(t,o){switch(o){case Boolean:t=t?m:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,o){let r=t;switch(o){case Boolean:r=null!==t;break;case Number:r=null===t?null:Number(t);break;case Object:case Array:try{r=JSON.parse(t)}catch(t){r=null}}return r}},w=(t,o)=>!f(t,o),S={attribute:!0,type:String,converter:N,reflect:!1,hasChanged:w};Symbol.metadata??=Symbol("metadata"),b.litPropertyMetadata??=new WeakMap;let C=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,o=S){if(o.state&&(o.attribute=!1),this._$Ei(),this.elementProperties.set(t,o),!o.noAccessor){const r=Symbol(),e=this.getPropertyDescriptor(t,r,o);void 0!==e&&h(this.prototype,t,e)}}static getPropertyDescriptor(t,o,r){const{get:e,set:n}=u(this.prototype,t)??{get(){return this[o]},set(t){this[o]=t}};return{get(){return e?.call(this)},set(o){const i=e?.call(this);n.call(this,o),this.requestUpdate(t,i,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??S}static _$Ei(){if(this.hasOwnProperty(v("elementProperties")))return;const t=y(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(v("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(v("properties"))){const t=this.properties,o=[...d(t),...p(t)];for(const r of o)this.createProperty(r,t[r])}const t=this[Symbol.metadata];if(null!==t){const o=litPropertyMetadata.get(t);if(void 0!==o)for(const[t,r]of o)this.elementProperties.set(t,r)}this._$Eh=new Map;for(const[t,o]of this.elementProperties){const r=this._$Eu(t,o);void 0!==r&&this._$Eh.set(r,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const o=[];if(Array.isArray(t)){const r=new Set(t.flat(1/0).reverse());for(const t of r)o.unshift(l(t))}else void 0!==t&&o.push(l(t));return o}static _$Eu(t,o){const r=o.attribute;return!1===r?void 0:"string"==typeof r?r:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$Eg=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$ES(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)))}addController(t){(this._$E_??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$E_?.delete(t)}_$ES(){const t=new Map,o=this.constructor.elementProperties;for(const r of o.keys())this.hasOwnProperty(r)&&(t.set(r,this[r]),delete this[r]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((t,o)=>{if(i)t.adoptedStyleSheets=o.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const r of o){const o=document.createElement("style"),e=n.litNonce;void 0!==e&&o.setAttribute("nonce",e),o.textContent=r.cssText,t.appendChild(o)}})(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$E_?.forEach((t=>t.hostConnected?.()))}enableUpdating(t){}disconnectedCallback(){this._$E_?.forEach((t=>t.hostDisconnected?.()))}attributeChangedCallback(t,o,r){this._$AK(t,r)}_$EO(t,o){const r=this.constructor.elementProperties.get(t),e=this.constructor._$Eu(t,r);if(void 0!==e&&!0===r.reflect){const n=(void 0!==r.converter?.toAttribute?r.converter:N).toAttribute(o,r.type);this._$Em=t,null==n?this.removeAttribute(e):this.setAttribute(e,n),this._$Em=null}}_$AK(t,o){const r=this.constructor,e=r._$Eh.get(t);if(void 0!==e&&this._$Em!==e){const t=r.getPropertyOptions(e),n="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:N;this._$Em=e,this[e]=n.fromAttribute(o,t.type),this._$Em=null}}requestUpdate(t,o,r,e=!1,n){if(void 0!==t){if(r??=this.constructor.getPropertyOptions(t),!(r.hasChanged??w)(e?n:this[t],o))return;this.C(t,o,r)}!1===this.isUpdatePending&&(this._$Eg=this._$EP())}C(t,o,r){this._$AL.has(t)||this._$AL.set(t,o),!0===r.reflect&&this._$Em!==t&&(this._$Ej??=new Set).add(t)}async _$EP(){this.isUpdatePending=!0;try{await this._$Eg}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,o]of this._$Ep)this[t]=o;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[o,r]of t)!0!==r.wrapped||this._$AL.has(o)||void 0===this[o]||this.C(o,this[o],r)}let t=!1;const o=this._$AL;try{t=this.shouldUpdate(o),t?(this.willUpdate(o),this._$E_?.forEach((t=>t.hostUpdate?.())),this.update(o)):this._$ET()}catch(o){throw t=!1,this._$ET(),o}t&&this._$AE(o)}willUpdate(t){}_$AE(t){this._$E_?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$ET(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$Eg}shouldUpdate(t){return!0}update(t){this._$Ej&&=this._$Ej.forEach((t=>this._$EO(t,this[t]))),this._$ET()}updated(t){}firstUpdated(t){}};C.elementStyles=[],C.shadowRootOptions={mode:"open"},C[v("elementProperties")]=new Map,C[v("finalized")]=new Map,O?.({ReactiveElement:C}),(b.reactiveElementVersions??=[]).push("2.0.2");
26
26
  /**
27
27
  * @license
28
28
  * Copyright 2017 Google LLC
@@ -33,24 +33,24 @@ const E={attribute:!0,type:String,converter:N,reflect:!1,hasChanged:w},x=(t=E,o,
33
33
  * @license
34
34
  * Copyright 2017 Google LLC
35
35
  * SPDX-License-Identifier: BSD-3-Clause
36
- */const W=globalThis,k=W.trustedTypes,K=k?k.createPolicy("lit-html",{createHTML:t=>t}):void 0,A="$lit$",j=`lit$${(Math.random()+"").slice(9)}$`,Z="?"+j,M=`<${Z}>`,F=document,$=()=>F.createComment(""),P=t=>null===t||"object"!=typeof t&&"function"!=typeof t,B=Array.isArray,_="[ \t\n\f\r]",D=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,z=/-->/g,T=/>/g,G=RegExp(`>|${_}(?:([^\\s"'>=/]+)(${_}*=${_}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),H=/'/g,q=/"/g,Y=/^(?:script|style|textarea|title)$/i,V=Symbol.for("lit-noChange"),J=Symbol.for("lit-nothing"),X=new WeakMap,Q=F.createTreeWalker(F,129);function tt(t,o){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==K?K.createHTML(o):o}let ot=class t{constructor({strings:o,_$litType$:r},e){let n;this.parts=[];let i=0,a=0;const c=o.length-1,s=this.parts,[l,f]=((t,o)=>{const r=t.length-1,e=[];let n,i=2===o?"<svg>":"",a=D;for(let o=0;o<r;o++){const r=t[o];let c,s,l=-1,f=0;for(;f<r.length&&(a.lastIndex=f,s=a.exec(r),null!==s);)f=a.lastIndex,a===D?"!--"===s[1]?a=z:void 0!==s[1]?a=T:void 0!==s[2]?(Y.test(s[2])&&(n=RegExp("</"+s[2],"g")),a=G):void 0!==s[3]&&(a=G):a===G?">"===s[0]?(a=n??D,l=-1):void 0===s[1]?l=-2:(l=a.lastIndex-s[2].length,c=s[1],a=void 0===s[3]?G:'"'===s[3]?q:H):a===q||a===H?a=G:a===z||a===T?a=D:(a=G,n=void 0);const u=a===G&&t[o+1].startsWith("/>")?" ":"";i+=a===D?r+M:l>=0?(e.push(c),r.slice(0,l)+A+r.slice(l)+j+u):r+j+(-2===l?o:u)}return[tt(t,i+(t[r]||"<?>")+(2===o?"</svg>":"")),e]})(o,r);if(this.el=t.createElement(l,e),Q.currentNode=this.el.content,2===r){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(n=Q.nextNode())&&s.length<c;){if(1===n.nodeType){if(n.hasAttributes())for(const t of n.getAttributeNames())if(t.endsWith(A)){const o=f[a++],r=n.getAttribute(t).split(j),e=/([.?@])?(.*)/.exec(o);s.push({type:1,index:i,name:e[2],strings:r,ctor:"."===e[1]?it:"?"===e[1]?at:"@"===e[1]?ct:nt}),n.removeAttribute(t)}else t.startsWith(j)&&(s.push({type:6,index:i}),n.removeAttribute(t));if(Y.test(n.tagName)){const t=n.textContent.split(j),o=t.length-1;if(o>0){n.textContent=k?k.emptyScript:"";for(let r=0;r<o;r++)n.append(t[r],$()),Q.nextNode(),s.push({type:2,index:++i});n.append(t[o],$())}}}else if(8===n.nodeType)if(n.data===Z)s.push({type:2,index:i});else{let t=-1;for(;-1!==(t=n.data.indexOf(j,t+1));)s.push({type:7,index:i}),t+=j.length-1}i++}}static createElement(t,o){const r=F.createElement("template");return r.innerHTML=t,r}};function rt(t,o,r=t,e){if(o===V)return o;let n=void 0!==e?r._$Co?.[e]:r._$Cl;const i=P(o)?void 0:o._$litDirective$;return n?.constructor!==i&&(n?._$AO?.(!1),void 0===i?n=void 0:(n=new i(t),n._$AT(t,r,e)),void 0!==e?(r._$Co??=[])[e]=n:r._$Cl=n),void 0!==n&&(o=rt(t,n._$AS(t,o.values),n,e)),o}let et=class t{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,o,r,e){this.type=2,this._$AH=J,this._$AN=void 0,this._$AA=t,this._$AB=o,this._$AM=r,this.options=e,this._$Cv=e?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const o=this._$AM;return void 0!==o&&11===t?.nodeType&&(t=o.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,o=this){t=rt(this,t,o),P(t)?t===J||null==t||""===t?(this._$AH!==J&&this._$AR(),this._$AH=J):t!==this._$AH&&t!==V&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>B(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!==J&&P(this._$AH)?this._$AA.nextSibling.data=t:this.$(F.createTextNode(t)),this._$AH=t}g(t){const{values:o,_$litType$:r}=t,e="number"==typeof r?this._$AC(t):(void 0===r.el&&(r.el=ot.createElement(tt(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===e)this._$AH.p(o);else{const t=new class{constructor(t,o){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=o}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:o},parts:r}=this._$AD,e=(t?.creationScope??F).importNode(o,!0);Q.currentNode=e;let n=Q.nextNode(),i=0,a=0,c=r[0];for(;void 0!==c;){if(i===c.index){let o;2===c.type?o=new et(n,n.nextSibling,this,t):1===c.type?o=new c.ctor(n,c.name,c.strings,this,t):6===c.type&&(o=new st(n,this,t)),this._$AV.push(o),c=r[++a]}i!==c?.index&&(n=Q.nextNode(),i++)}return Q.currentNode=F,e}p(t){let o=0;for(const r of this._$AV)void 0!==r&&(void 0!==r.strings?(r._$AI(t,r,o),o+=r.strings.length-2):r._$AI(t[o])),o++}}(e,this),r=t.u(this.options);t.p(o),this.$(r),this._$AH=t}}_$AC(t){let o=X.get(t.strings);return void 0===o&&X.set(t.strings,o=new ot(t)),o}T(o){B(this._$AH)||(this._$AH=[],this._$AR());const r=this._$AH;let e,n=0;for(const i of o)n===r.length?r.push(e=new t(this.k($()),this.k($()),this,this.options)):e=r[n],e._$AI(i),n++;n<r.length&&(this._$AR(e&&e._$AB.nextSibling,n),r.length=n)}_$AR(t=this._$AA.nextSibling,o){for(this._$AP?.(!1,!0,o);t&&t!==this._$AB;){const o=t.nextSibling;t.remove(),t=o}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}},nt=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,o,r,e,n){this.type=1,this._$AH=J,this._$AN=void 0,this.element=t,this.name=o,this._$AM=e,this.options=n,r.length>2||""!==r[0]||""!==r[1]?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=J}_$AI(t,o=this,r,e){const n=this.strings;let i=!1;if(void 0===n)t=rt(this,t,o,0),i=!P(t)||t!==this._$AH&&t!==V,i&&(this._$AH=t);else{const e=t;let a,c;for(t=n[0],a=0;a<n.length-1;a++)c=rt(this,e[r+a],o,a),c===V&&(c=this._$AH[a]),i||=!P(c)||c!==this._$AH[a],c===J?t=J:t!==J&&(t+=(c??"")+n[a+1]),this._$AH[a]=c}i&&!e&&this.O(t)}O(t){t===J?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},it=class extends nt{constructor(){super(...arguments),this.type=3}O(t){this.element[this.name]=t===J?void 0:t}},at=class extends nt{constructor(){super(...arguments),this.type=4}O(t){this.element.toggleAttribute(this.name,!!t&&t!==J)}},ct=class extends nt{constructor(t,o,r,e,n){super(t,o,r,e,n),this.type=5}_$AI(t,o=this){if((t=rt(this,t,o,0)??J)===V)return;const r=this._$AH,e=t===J&&r!==J||t.capture!==r.capture||t.once!==r.once||t.passive!==r.passive,n=t!==J&&(r===J||e);e&&this.element.removeEventListener(this.name,this,r),n&&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)}},st=class{constructor(t,o,r){this.element=t,this.type=6,this._$AN=void 0,this._$AM=o,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(t){rt(this,t)}};const lt=W.litHtmlPolyfillSupport;lt?.(ot,et),(W.litHtmlVersions??=[]).push("3.1.0");
36
+ */const W=globalThis,k=W.trustedTypes,K=k?k.createPolicy("lit-html",{createHTML:t=>t}):void 0,A="$lit$",j=`lit$${(Math.random()+"").slice(9)}$`,Z="?"+j,M=`<${Z}>`,F=document,$=()=>F.createComment(""),P=t=>null===t||"object"!=typeof t&&"function"!=typeof t,B=Array.isArray,_="[ \t\n\f\r]",D=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,z=/-->/g,T=/>/g,G=RegExp(`>|${_}(?:([^\\s"'>=/]+)(${_}*=${_}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),H=/'/g,q=/"/g,Y=/^(?:script|style|textarea|title)$/i,V=Symbol.for("lit-noChange"),J=Symbol.for("lit-nothing"),X=new WeakMap,Q=F.createTreeWalker(F,129);function tt(t,o){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==K?K.createHTML(o):o}let ot=class t{constructor({strings:o,_$litType$:r},e){let n;this.parts=[];let i=0,a=0;const c=o.length-1,s=this.parts,[l,f]=((t,o)=>{const r=t.length-1,e=[];let n,i=2===o?"<svg>":"",a=D;for(let o=0;o<r;o++){const r=t[o];let c,s,l=-1,f=0;for(;f<r.length&&(a.lastIndex=f,s=a.exec(r),null!==s);)f=a.lastIndex,a===D?"!--"===s[1]?a=z:void 0!==s[1]?a=T:void 0!==s[2]?(Y.test(s[2])&&(n=RegExp("</"+s[2],"g")),a=G):void 0!==s[3]&&(a=G):a===G?">"===s[0]?(a=n??D,l=-1):void 0===s[1]?l=-2:(l=a.lastIndex-s[2].length,c=s[1],a=void 0===s[3]?G:'"'===s[3]?q:H):a===q||a===H?a=G:a===z||a===T?a=D:(a=G,n=void 0);const h=a===G&&t[o+1].startsWith("/>")?" ":"";i+=a===D?r+M:l>=0?(e.push(c),r.slice(0,l)+A+r.slice(l)+j+h):r+j+(-2===l?o:h)}return[tt(t,i+(t[r]||"<?>")+(2===o?"</svg>":"")),e]})(o,r);if(this.el=t.createElement(l,e),Q.currentNode=this.el.content,2===r){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(n=Q.nextNode())&&s.length<c;){if(1===n.nodeType){if(n.hasAttributes())for(const t of n.getAttributeNames())if(t.endsWith(A)){const o=f[a++],r=n.getAttribute(t).split(j),e=/([.?@])?(.*)/.exec(o);s.push({type:1,index:i,name:e[2],strings:r,ctor:"."===e[1]?it:"?"===e[1]?at:"@"===e[1]?ct:nt}),n.removeAttribute(t)}else t.startsWith(j)&&(s.push({type:6,index:i}),n.removeAttribute(t));if(Y.test(n.tagName)){const t=n.textContent.split(j),o=t.length-1;if(o>0){n.textContent=k?k.emptyScript:"";for(let r=0;r<o;r++)n.append(t[r],$()),Q.nextNode(),s.push({type:2,index:++i});n.append(t[o],$())}}}else if(8===n.nodeType)if(n.data===Z)s.push({type:2,index:i});else{let t=-1;for(;-1!==(t=n.data.indexOf(j,t+1));)s.push({type:7,index:i}),t+=j.length-1}i++}}static createElement(t,o){const r=F.createElement("template");return r.innerHTML=t,r}};function rt(t,o,r=t,e){if(o===V)return o;let n=void 0!==e?r._$Co?.[e]:r._$Cl;const i=P(o)?void 0:o._$litDirective$;return n?.constructor!==i&&(n?._$AO?.(!1),void 0===i?n=void 0:(n=new i(t),n._$AT(t,r,e)),void 0!==e?(r._$Co??=[])[e]=n:r._$Cl=n),void 0!==n&&(o=rt(t,n._$AS(t,o.values),n,e)),o}let et=class t{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,o,r,e){this.type=2,this._$AH=J,this._$AN=void 0,this._$AA=t,this._$AB=o,this._$AM=r,this.options=e,this._$Cv=e?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const o=this._$AM;return void 0!==o&&11===t?.nodeType&&(t=o.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,o=this){t=rt(this,t,o),P(t)?t===J||null==t||""===t?(this._$AH!==J&&this._$AR(),this._$AH=J):t!==this._$AH&&t!==V&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>B(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!==J&&P(this._$AH)?this._$AA.nextSibling.data=t:this.$(F.createTextNode(t)),this._$AH=t}g(t){const{values:o,_$litType$:r}=t,e="number"==typeof r?this._$AC(t):(void 0===r.el&&(r.el=ot.createElement(tt(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===e)this._$AH.p(o);else{const t=new class{constructor(t,o){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=o}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:o},parts:r}=this._$AD,e=(t?.creationScope??F).importNode(o,!0);Q.currentNode=e;let n=Q.nextNode(),i=0,a=0,c=r[0];for(;void 0!==c;){if(i===c.index){let o;2===c.type?o=new et(n,n.nextSibling,this,t):1===c.type?o=new c.ctor(n,c.name,c.strings,this,t):6===c.type&&(o=new st(n,this,t)),this._$AV.push(o),c=r[++a]}i!==c?.index&&(n=Q.nextNode(),i++)}return Q.currentNode=F,e}p(t){let o=0;for(const r of this._$AV)void 0!==r&&(void 0!==r.strings?(r._$AI(t,r,o),o+=r.strings.length-2):r._$AI(t[o])),o++}}(e,this),r=t.u(this.options);t.p(o),this.$(r),this._$AH=t}}_$AC(t){let o=X.get(t.strings);return void 0===o&&X.set(t.strings,o=new ot(t)),o}T(o){B(this._$AH)||(this._$AH=[],this._$AR());const r=this._$AH;let e,n=0;for(const i of o)n===r.length?r.push(e=new t(this.k($()),this.k($()),this,this.options)):e=r[n],e._$AI(i),n++;n<r.length&&(this._$AR(e&&e._$AB.nextSibling,n),r.length=n)}_$AR(t=this._$AA.nextSibling,o){for(this._$AP?.(!1,!0,o);t&&t!==this._$AB;){const o=t.nextSibling;t.remove(),t=o}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}},nt=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,o,r,e,n){this.type=1,this._$AH=J,this._$AN=void 0,this.element=t,this.name=o,this._$AM=e,this.options=n,r.length>2||""!==r[0]||""!==r[1]?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=J}_$AI(t,o=this,r,e){const n=this.strings;let i=!1;if(void 0===n)t=rt(this,t,o,0),i=!P(t)||t!==this._$AH&&t!==V,i&&(this._$AH=t);else{const e=t;let a,c;for(t=n[0],a=0;a<n.length-1;a++)c=rt(this,e[r+a],o,a),c===V&&(c=this._$AH[a]),i||=!P(c)||c!==this._$AH[a],c===J?t=J:t!==J&&(t+=(c??"")+n[a+1]),this._$AH[a]=c}i&&!e&&this.O(t)}O(t){t===J?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},it=class extends nt{constructor(){super(...arguments),this.type=3}O(t){this.element[this.name]=t===J?void 0:t}},at=class extends nt{constructor(){super(...arguments),this.type=4}O(t){this.element.toggleAttribute(this.name,!!t&&t!==J)}},ct=class extends nt{constructor(t,o,r,e,n){super(t,o,r,e,n),this.type=5}_$AI(t,o=this){if((t=rt(this,t,o,0)??J)===V)return;const r=this._$AH,e=t===J&&r!==J||t.capture!==r.capture||t.once!==r.once||t.passive!==r.passive,n=t!==J&&(r===J||e);e&&this.element.removeEventListener(this.name,this,r),n&&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)}},st=class{constructor(t,o,r){this.element=t,this.type=6,this._$AN=void 0,this._$AM=o,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(t){rt(this,t)}};const lt=W.litHtmlPolyfillSupport;lt?.(ot,et),(W.litHtmlVersions??=[]).push("3.1.0");
37
37
  /**
38
38
  * @license
39
39
  * Copyright 2019 Google LLC
40
40
  * SPDX-License-Identifier: BSD-3-Clause
41
41
  */
42
- const ft=globalThis,ut=ft.ShadowRoot&&(void 0===ft.ShadyCSS||ft.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,ht=Symbol(),dt=new WeakMap;let pt=class{constructor(t,o,r){if(this._$cssResult$=!0,r!==ht)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=o}get styleSheet(){let t=this.o;const o=this.t;if(ut&&void 0===t){const r=void 0!==o&&1===o.length;r&&(t=dt.get(o)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),r&&dt.set(o,t))}return t}toString(){return this.cssText}};const yt=t=>new pt("string"==typeof t?t:t+"",void 0,ht),bt=(t,...o)=>{const r=1===t.length?t[0]:o.reduce(((o,r,e)=>o+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(r)+t[e+1]),t[0]);return new pt(r,t,ht)},gt=ut?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let o="";for(const r of t.cssRules)o+=r.cssText;return yt(o)})(t):t
42
+ const ft=globalThis,ht=ft.ShadowRoot&&(void 0===ft.ShadyCSS||ft.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,ut=Symbol(),dt=new WeakMap;let pt=class{constructor(t,o,r){if(this._$cssResult$=!0,r!==ut)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=o}get styleSheet(){let t=this.o;const o=this.t;if(ht&&void 0===t){const r=void 0!==o&&1===o.length;r&&(t=dt.get(o)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),r&&dt.set(o,t))}return t}toString(){return this.cssText}};const yt=t=>new pt("string"==typeof t?t:t+"",void 0,ut),bt=(t,...o)=>{const r=1===t.length?t[0]:o.reduce(((o,r,e)=>o+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(r)+t[e+1]),t[0]);return new pt(r,t,ut)},gt=ht?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let o="";for(const r of t.cssRules)o+=r.cssText;return yt(o)})(t):t
43
43
  /**
44
44
  * @license
45
45
  * Copyright 2017 Google LLC
46
46
  * SPDX-License-Identifier: BSD-3-Clause
47
- */,{is:mt,defineProperty:Ot,getOwnPropertyDescriptor:vt,getOwnPropertyNames:Nt,getOwnPropertySymbols:wt,getPrototypeOf:St}=Object,Ct=globalThis,Et=Ct.trustedTypes,xt=Et?Et.emptyScript:"",Rt=Ct.reactiveElementPolyfillSupport,Ut=(t,o)=>t,It={toAttribute(t,o){switch(o){case Boolean:t=t?xt:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,o){let r=t;switch(o){case Boolean:r=null!==t;break;case Number:r=null===t?null:Number(t);break;case Object:case Array:try{r=JSON.parse(t)}catch(t){r=null}}return r}},Lt=(t,o)=>!mt(t,o),Wt={attribute:!0,type:String,converter:It,reflect:!1,hasChanged:Lt};Symbol.metadata??=Symbol("metadata"),Ct.litPropertyMetadata??=new WeakMap;let kt=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,o=Wt){if(o.state&&(o.attribute=!1),this._$Ei(),this.elementProperties.set(t,o),!o.noAccessor){const r=Symbol(),e=this.getPropertyDescriptor(t,r,o);void 0!==e&&Ot(this.prototype,t,e)}}static getPropertyDescriptor(t,o,r){const{get:e,set:n}=vt(this.prototype,t)??{get(){return this[o]},set(t){this[o]=t}};return{get(){return e?.call(this)},set(o){const i=e?.call(this);n.call(this,o),this.requestUpdate(t,i,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??Wt}static _$Ei(){if(this.hasOwnProperty(Ut("elementProperties")))return;const t=St(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(Ut("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(Ut("properties"))){const t=this.properties,o=[...Nt(t),...wt(t)];for(const r of o)this.createProperty(r,t[r])}const t=this[Symbol.metadata];if(null!==t){const o=litPropertyMetadata.get(t);if(void 0!==o)for(const[t,r]of o)this.elementProperties.set(t,r)}this._$Eh=new Map;for(const[t,o]of this.elementProperties){const r=this._$Eu(t,o);void 0!==r&&this._$Eh.set(r,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const o=[];if(Array.isArray(t)){const r=new Set(t.flat(1/0).reverse());for(const t of r)o.unshift(gt(t))}else void 0!==t&&o.push(gt(t));return o}static _$Eu(t,o){const r=o.attribute;return!1===r?void 0:"string"==typeof r?r:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$Eg=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$ES(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)))}addController(t){(this._$E_??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$E_?.delete(t)}_$ES(){const t=new Map,o=this.constructor.elementProperties;for(const r of o.keys())this.hasOwnProperty(r)&&(t.set(r,this[r]),delete this[r]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((t,o)=>{if(ut)t.adoptedStyleSheets=o.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const r of o){const o=document.createElement("style"),e=ft.litNonce;void 0!==e&&o.setAttribute("nonce",e),o.textContent=r.cssText,t.appendChild(o)}})(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$E_?.forEach((t=>t.hostConnected?.()))}enableUpdating(t){}disconnectedCallback(){this._$E_?.forEach((t=>t.hostDisconnected?.()))}attributeChangedCallback(t,o,r){this._$AK(t,r)}_$EO(t,o){const r=this.constructor.elementProperties.get(t),e=this.constructor._$Eu(t,r);if(void 0!==e&&!0===r.reflect){const n=(void 0!==r.converter?.toAttribute?r.converter:It).toAttribute(o,r.type);this._$Em=t,null==n?this.removeAttribute(e):this.setAttribute(e,n),this._$Em=null}}_$AK(t,o){const r=this.constructor,e=r._$Eh.get(t);if(void 0!==e&&this._$Em!==e){const t=r.getPropertyOptions(e),n="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:It;this._$Em=e,this[e]=n.fromAttribute(o,t.type),this._$Em=null}}requestUpdate(t,o,r,e=!1,n){if(void 0!==t){if(r??=this.constructor.getPropertyOptions(t),!(r.hasChanged??Lt)(e?n:this[t],o))return;this.C(t,o,r)}!1===this.isUpdatePending&&(this._$Eg=this._$EP())}C(t,o,r){this._$AL.has(t)||this._$AL.set(t,o),!0===r.reflect&&this._$Em!==t&&(this._$Ej??=new Set).add(t)}async _$EP(){this.isUpdatePending=!0;try{await this._$Eg}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,o]of this._$Ep)this[t]=o;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[o,r]of t)!0!==r.wrapped||this._$AL.has(o)||void 0===this[o]||this.C(o,this[o],r)}let t=!1;const o=this._$AL;try{t=this.shouldUpdate(o),t?(this.willUpdate(o),this._$E_?.forEach((t=>t.hostUpdate?.())),this.update(o)):this._$ET()}catch(o){throw t=!1,this._$ET(),o}t&&this._$AE(o)}willUpdate(t){}_$AE(t){this._$E_?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$ET(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$Eg}shouldUpdate(t){return!0}update(t){this._$Ej&&=this._$Ej.forEach((t=>this._$EO(t,this[t]))),this._$ET()}updated(t){}firstUpdated(t){}};kt.elementStyles=[],kt.shadowRootOptions={mode:"open"},kt[Ut("elementProperties")]=new Map,kt[Ut("finalized")]=new Map,Rt?.({ReactiveElement:kt}),(Ct.reactiveElementVersions??=[]).push("2.0.2");
47
+ */,{is:mt,defineProperty:Ot,getOwnPropertyDescriptor:vt,getOwnPropertyNames:Nt,getOwnPropertySymbols:wt,getPrototypeOf:St}=Object,Ct=globalThis,Et=Ct.trustedTypes,xt=Et?Et.emptyScript:"",Rt=Ct.reactiveElementPolyfillSupport,Ut=(t,o)=>t,It={toAttribute(t,o){switch(o){case Boolean:t=t?xt:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,o){let r=t;switch(o){case Boolean:r=null!==t;break;case Number:r=null===t?null:Number(t);break;case Object:case Array:try{r=JSON.parse(t)}catch(t){r=null}}return r}},Lt=(t,o)=>!mt(t,o),Wt={attribute:!0,type:String,converter:It,reflect:!1,hasChanged:Lt};Symbol.metadata??=Symbol("metadata"),Ct.litPropertyMetadata??=new WeakMap;let kt=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,o=Wt){if(o.state&&(o.attribute=!1),this._$Ei(),this.elementProperties.set(t,o),!o.noAccessor){const r=Symbol(),e=this.getPropertyDescriptor(t,r,o);void 0!==e&&Ot(this.prototype,t,e)}}static getPropertyDescriptor(t,o,r){const{get:e,set:n}=vt(this.prototype,t)??{get(){return this[o]},set(t){this[o]=t}};return{get(){return e?.call(this)},set(o){const i=e?.call(this);n.call(this,o),this.requestUpdate(t,i,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??Wt}static _$Ei(){if(this.hasOwnProperty(Ut("elementProperties")))return;const t=St(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(Ut("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(Ut("properties"))){const t=this.properties,o=[...Nt(t),...wt(t)];for(const r of o)this.createProperty(r,t[r])}const t=this[Symbol.metadata];if(null!==t){const o=litPropertyMetadata.get(t);if(void 0!==o)for(const[t,r]of o)this.elementProperties.set(t,r)}this._$Eh=new Map;for(const[t,o]of this.elementProperties){const r=this._$Eu(t,o);void 0!==r&&this._$Eh.set(r,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const o=[];if(Array.isArray(t)){const r=new Set(t.flat(1/0).reverse());for(const t of r)o.unshift(gt(t))}else void 0!==t&&o.push(gt(t));return o}static _$Eu(t,o){const r=o.attribute;return!1===r?void 0:"string"==typeof r?r:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$Eg=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$ES(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)))}addController(t){(this._$E_??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$E_?.delete(t)}_$ES(){const t=new Map,o=this.constructor.elementProperties;for(const r of o.keys())this.hasOwnProperty(r)&&(t.set(r,this[r]),delete this[r]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((t,o)=>{if(ht)t.adoptedStyleSheets=o.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const r of o){const o=document.createElement("style"),e=ft.litNonce;void 0!==e&&o.setAttribute("nonce",e),o.textContent=r.cssText,t.appendChild(o)}})(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$E_?.forEach((t=>t.hostConnected?.()))}enableUpdating(t){}disconnectedCallback(){this._$E_?.forEach((t=>t.hostDisconnected?.()))}attributeChangedCallback(t,o,r){this._$AK(t,r)}_$EO(t,o){const r=this.constructor.elementProperties.get(t),e=this.constructor._$Eu(t,r);if(void 0!==e&&!0===r.reflect){const n=(void 0!==r.converter?.toAttribute?r.converter:It).toAttribute(o,r.type);this._$Em=t,null==n?this.removeAttribute(e):this.setAttribute(e,n),this._$Em=null}}_$AK(t,o){const r=this.constructor,e=r._$Eh.get(t);if(void 0!==e&&this._$Em!==e){const t=r.getPropertyOptions(e),n="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:It;this._$Em=e,this[e]=n.fromAttribute(o,t.type),this._$Em=null}}requestUpdate(t,o,r,e=!1,n){if(void 0!==t){if(r??=this.constructor.getPropertyOptions(t),!(r.hasChanged??Lt)(e?n:this[t],o))return;this.C(t,o,r)}!1===this.isUpdatePending&&(this._$Eg=this._$EP())}C(t,o,r){this._$AL.has(t)||this._$AL.set(t,o),!0===r.reflect&&this._$Em!==t&&(this._$Ej??=new Set).add(t)}async _$EP(){this.isUpdatePending=!0;try{await this._$Eg}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,o]of this._$Ep)this[t]=o;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[o,r]of t)!0!==r.wrapped||this._$AL.has(o)||void 0===this[o]||this.C(o,this[o],r)}let t=!1;const o=this._$AL;try{t=this.shouldUpdate(o),t?(this.willUpdate(o),this._$E_?.forEach((t=>t.hostUpdate?.())),this.update(o)):this._$ET()}catch(o){throw t=!1,this._$ET(),o}t&&this._$AE(o)}willUpdate(t){}_$AE(t){this._$E_?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$ET(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$Eg}shouldUpdate(t){return!0}update(t){this._$Ej&&=this._$Ej.forEach((t=>this._$EO(t,this[t]))),this._$ET()}updated(t){}firstUpdated(t){}};kt.elementStyles=[],kt.shadowRootOptions={mode:"open"},kt[Ut("elementProperties")]=new Map,kt[Ut("finalized")]=new Map,Rt?.({ReactiveElement:kt}),(Ct.reactiveElementVersions??=[]).push("2.0.2");
48
48
  /**
49
49
  * @license
50
50
  * Copyright 2017 Google LLC
51
51
  * SPDX-License-Identifier: BSD-3-Clause
52
52
  */
53
- const Kt=globalThis,At=Kt.trustedTypes,jt=At?At.createPolicy("lit-html",{createHTML:t=>t}):void 0,Zt="$lit$",Mt=`lit$${(Math.random()+"").slice(9)}$`,Ft="?"+Mt,$t=`<${Ft}>`,Pt=document,Bt=()=>Pt.createComment(""),_t=t=>null===t||"object"!=typeof t&&"function"!=typeof t,Dt=Array.isArray,zt="[ \t\n\f\r]",Tt=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Gt=/-->/g,Ht=/>/g,qt=RegExp(`>|${zt}(?:([^\\s"'>=/]+)(${zt}*=${zt}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),Yt=/'/g,Vt=/"/g,Jt=/^(?:script|style|textarea|title)$/i,Xt=(t=>(o,...r)=>({_$litType$:t,strings:o,values:r}))(1),Qt=Symbol.for("lit-noChange"),to=Symbol.for("lit-nothing"),oo=new WeakMap,ro=Pt.createTreeWalker(Pt,129);function eo(t,o){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==jt?jt.createHTML(o):o}class no{constructor({strings:t,_$litType$:o},r){let e;this.parts=[];let n=0,i=0;const a=t.length-1,c=this.parts,[s,l]=((t,o)=>{const r=t.length-1,e=[];let n,i=2===o?"<svg>":"",a=Tt;for(let o=0;o<r;o++){const r=t[o];let c,s,l=-1,f=0;for(;f<r.length&&(a.lastIndex=f,s=a.exec(r),null!==s);)f=a.lastIndex,a===Tt?"!--"===s[1]?a=Gt:void 0!==s[1]?a=Ht:void 0!==s[2]?(Jt.test(s[2])&&(n=RegExp("</"+s[2],"g")),a=qt):void 0!==s[3]&&(a=qt):a===qt?">"===s[0]?(a=n??Tt,l=-1):void 0===s[1]?l=-2:(l=a.lastIndex-s[2].length,c=s[1],a=void 0===s[3]?qt:'"'===s[3]?Vt:Yt):a===Vt||a===Yt?a=qt:a===Gt||a===Ht?a=Tt:(a=qt,n=void 0);const u=a===qt&&t[o+1].startsWith("/>")?" ":"";i+=a===Tt?r+$t:l>=0?(e.push(c),r.slice(0,l)+Zt+r.slice(l)+Mt+u):r+Mt+(-2===l?o:u)}return[eo(t,i+(t[r]||"<?>")+(2===o?"</svg>":"")),e]})(t,o);if(this.el=no.createElement(s,r),ro.currentNode=this.el.content,2===o){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(e=ro.nextNode())&&c.length<a;){if(1===e.nodeType){if(e.hasAttributes())for(const t of e.getAttributeNames())if(t.endsWith(Zt)){const o=l[i++],r=e.getAttribute(t).split(Mt),a=/([.?@])?(.*)/.exec(o);c.push({type:1,index:n,name:a[2],strings:r,ctor:"."===a[1]?so:"?"===a[1]?lo:"@"===a[1]?fo:co}),e.removeAttribute(t)}else t.startsWith(Mt)&&(c.push({type:6,index:n}),e.removeAttribute(t));if(Jt.test(e.tagName)){const t=e.textContent.split(Mt),o=t.length-1;if(o>0){e.textContent=At?At.emptyScript:"";for(let r=0;r<o;r++)e.append(t[r],Bt()),ro.nextNode(),c.push({type:2,index:++n});e.append(t[o],Bt())}}}else if(8===e.nodeType)if(e.data===Ft)c.push({type:2,index:n});else{let t=-1;for(;-1!==(t=e.data.indexOf(Mt,t+1));)c.push({type:7,index:n}),t+=Mt.length-1}n++}}static createElement(t,o){const r=Pt.createElement("template");return r.innerHTML=t,r}}function io(t,o,r=t,e){if(o===Qt)return o;let n=void 0!==e?r._$Co?.[e]:r._$Cl;const i=_t(o)?void 0:o._$litDirective$;return n?.constructor!==i&&(n?._$AO?.(!1),void 0===i?n=void 0:(n=new i(t),n._$AT(t,r,e)),void 0!==e?(r._$Co??=[])[e]=n:r._$Cl=n),void 0!==n&&(o=io(t,n._$AS(t,o.values),n,e)),o}let ao=class t{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,o,r,e){this.type=2,this._$AH=to,this._$AN=void 0,this._$AA=t,this._$AB=o,this._$AM=r,this.options=e,this._$Cv=e?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const o=this._$AM;return void 0!==o&&11===t?.nodeType&&(t=o.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,o=this){t=io(this,t,o),_t(t)?t===to||null==t||""===t?(this._$AH!==to&&this._$AR(),this._$AH=to):t!==this._$AH&&t!==Qt&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>Dt(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!==to&&_t(this._$AH)?this._$AA.nextSibling.data=t:this.$(Pt.createTextNode(t)),this._$AH=t}g(t){const{values:o,_$litType$:r}=t,e="number"==typeof r?this._$AC(t):(void 0===r.el&&(r.el=no.createElement(eo(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===e)this._$AH.p(o);else{const t=new class{constructor(t,o){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=o}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:o},parts:r}=this._$AD,e=(t?.creationScope??Pt).importNode(o,!0);ro.currentNode=e;let n=ro.nextNode(),i=0,a=0,c=r[0];for(;void 0!==c;){if(i===c.index){let o;2===c.type?o=new ao(n,n.nextSibling,this,t):1===c.type?o=new c.ctor(n,c.name,c.strings,this,t):6===c.type&&(o=new uo(n,this,t)),this._$AV.push(o),c=r[++a]}i!==c?.index&&(n=ro.nextNode(),i++)}return ro.currentNode=Pt,e}p(t){let o=0;for(const r of this._$AV)void 0!==r&&(void 0!==r.strings?(r._$AI(t,r,o),o+=r.strings.length-2):r._$AI(t[o])),o++}}(e,this),r=t.u(this.options);t.p(o),this.$(r),this._$AH=t}}_$AC(t){let o=oo.get(t.strings);return void 0===o&&oo.set(t.strings,o=new no(t)),o}T(o){Dt(this._$AH)||(this._$AH=[],this._$AR());const r=this._$AH;let e,n=0;for(const i of o)n===r.length?r.push(e=new t(this.k(Bt()),this.k(Bt()),this,this.options)):e=r[n],e._$AI(i),n++;n<r.length&&(this._$AR(e&&e._$AB.nextSibling,n),r.length=n)}_$AR(t=this._$AA.nextSibling,o){for(this._$AP?.(!1,!0,o);t&&t!==this._$AB;){const o=t.nextSibling;t.remove(),t=o}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}},co=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,o,r,e,n){this.type=1,this._$AH=to,this._$AN=void 0,this.element=t,this.name=o,this._$AM=e,this.options=n,r.length>2||""!==r[0]||""!==r[1]?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=to}_$AI(t,o=this,r,e){const n=this.strings;let i=!1;if(void 0===n)t=io(this,t,o,0),i=!_t(t)||t!==this._$AH&&t!==Qt,i&&(this._$AH=t);else{const e=t;let a,c;for(t=n[0],a=0;a<n.length-1;a++)c=io(this,e[r+a],o,a),c===Qt&&(c=this._$AH[a]),i||=!_t(c)||c!==this._$AH[a],c===to?t=to:t!==to&&(t+=(c??"")+n[a+1]),this._$AH[a]=c}i&&!e&&this.O(t)}O(t){t===to?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},so=class extends co{constructor(){super(...arguments),this.type=3}O(t){this.element[this.name]=t===to?void 0:t}},lo=class extends co{constructor(){super(...arguments),this.type=4}O(t){this.element.toggleAttribute(this.name,!!t&&t!==to)}},fo=class extends co{constructor(t,o,r,e,n){super(t,o,r,e,n),this.type=5}_$AI(t,o=this){if((t=io(this,t,o,0)??to)===Qt)return;const r=this._$AH,e=t===to&&r!==to||t.capture!==r.capture||t.once!==r.once||t.passive!==r.passive,n=t!==to&&(r===to||e);e&&this.element.removeEventListener(this.name,this,r),n&&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)}},uo=class{constructor(t,o,r){this.element=t,this.type=6,this._$AN=void 0,this._$AM=o,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(t){io(this,t)}};const ho=Kt.litHtmlPolyfillSupport;ho?.(no,ao),(Kt.litHtmlVersions??=[]).push("3.1.0");
53
+ const Kt=globalThis,At=Kt.trustedTypes,jt=At?At.createPolicy("lit-html",{createHTML:t=>t}):void 0,Zt="$lit$",Mt=`lit$${(Math.random()+"").slice(9)}$`,Ft="?"+Mt,$t=`<${Ft}>`,Pt=document,Bt=()=>Pt.createComment(""),_t=t=>null===t||"object"!=typeof t&&"function"!=typeof t,Dt=Array.isArray,zt="[ \t\n\f\r]",Tt=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Gt=/-->/g,Ht=/>/g,qt=RegExp(`>|${zt}(?:([^\\s"'>=/]+)(${zt}*=${zt}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),Yt=/'/g,Vt=/"/g,Jt=/^(?:script|style|textarea|title)$/i,Xt=(t=>(o,...r)=>({_$litType$:t,strings:o,values:r}))(1),Qt=Symbol.for("lit-noChange"),to=Symbol.for("lit-nothing"),oo=new WeakMap,ro=Pt.createTreeWalker(Pt,129);function eo(t,o){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==jt?jt.createHTML(o):o}class no{constructor({strings:t,_$litType$:o},r){let e;this.parts=[];let n=0,i=0;const a=t.length-1,c=this.parts,[s,l]=((t,o)=>{const r=t.length-1,e=[];let n,i=2===o?"<svg>":"",a=Tt;for(let o=0;o<r;o++){const r=t[o];let c,s,l=-1,f=0;for(;f<r.length&&(a.lastIndex=f,s=a.exec(r),null!==s);)f=a.lastIndex,a===Tt?"!--"===s[1]?a=Gt:void 0!==s[1]?a=Ht:void 0!==s[2]?(Jt.test(s[2])&&(n=RegExp("</"+s[2],"g")),a=qt):void 0!==s[3]&&(a=qt):a===qt?">"===s[0]?(a=n??Tt,l=-1):void 0===s[1]?l=-2:(l=a.lastIndex-s[2].length,c=s[1],a=void 0===s[3]?qt:'"'===s[3]?Vt:Yt):a===Vt||a===Yt?a=qt:a===Gt||a===Ht?a=Tt:(a=qt,n=void 0);const h=a===qt&&t[o+1].startsWith("/>")?" ":"";i+=a===Tt?r+$t:l>=0?(e.push(c),r.slice(0,l)+Zt+r.slice(l)+Mt+h):r+Mt+(-2===l?o:h)}return[eo(t,i+(t[r]||"<?>")+(2===o?"</svg>":"")),e]})(t,o);if(this.el=no.createElement(s,r),ro.currentNode=this.el.content,2===o){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(e=ro.nextNode())&&c.length<a;){if(1===e.nodeType){if(e.hasAttributes())for(const t of e.getAttributeNames())if(t.endsWith(Zt)){const o=l[i++],r=e.getAttribute(t).split(Mt),a=/([.?@])?(.*)/.exec(o);c.push({type:1,index:n,name:a[2],strings:r,ctor:"."===a[1]?so:"?"===a[1]?lo:"@"===a[1]?fo:co}),e.removeAttribute(t)}else t.startsWith(Mt)&&(c.push({type:6,index:n}),e.removeAttribute(t));if(Jt.test(e.tagName)){const t=e.textContent.split(Mt),o=t.length-1;if(o>0){e.textContent=At?At.emptyScript:"";for(let r=0;r<o;r++)e.append(t[r],Bt()),ro.nextNode(),c.push({type:2,index:++n});e.append(t[o],Bt())}}}else if(8===e.nodeType)if(e.data===Ft)c.push({type:2,index:n});else{let t=-1;for(;-1!==(t=e.data.indexOf(Mt,t+1));)c.push({type:7,index:n}),t+=Mt.length-1}n++}}static createElement(t,o){const r=Pt.createElement("template");return r.innerHTML=t,r}}function io(t,o,r=t,e){if(o===Qt)return o;let n=void 0!==e?r._$Co?.[e]:r._$Cl;const i=_t(o)?void 0:o._$litDirective$;return n?.constructor!==i&&(n?._$AO?.(!1),void 0===i?n=void 0:(n=new i(t),n._$AT(t,r,e)),void 0!==e?(r._$Co??=[])[e]=n:r._$Cl=n),void 0!==n&&(o=io(t,n._$AS(t,o.values),n,e)),o}let ao=class t{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,o,r,e){this.type=2,this._$AH=to,this._$AN=void 0,this._$AA=t,this._$AB=o,this._$AM=r,this.options=e,this._$Cv=e?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const o=this._$AM;return void 0!==o&&11===t?.nodeType&&(t=o.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,o=this){t=io(this,t,o),_t(t)?t===to||null==t||""===t?(this._$AH!==to&&this._$AR(),this._$AH=to):t!==this._$AH&&t!==Qt&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>Dt(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!==to&&_t(this._$AH)?this._$AA.nextSibling.data=t:this.$(Pt.createTextNode(t)),this._$AH=t}g(t){const{values:o,_$litType$:r}=t,e="number"==typeof r?this._$AC(t):(void 0===r.el&&(r.el=no.createElement(eo(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===e)this._$AH.p(o);else{const t=new class{constructor(t,o){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=o}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:o},parts:r}=this._$AD,e=(t?.creationScope??Pt).importNode(o,!0);ro.currentNode=e;let n=ro.nextNode(),i=0,a=0,c=r[0];for(;void 0!==c;){if(i===c.index){let o;2===c.type?o=new ao(n,n.nextSibling,this,t):1===c.type?o=new c.ctor(n,c.name,c.strings,this,t):6===c.type&&(o=new ho(n,this,t)),this._$AV.push(o),c=r[++a]}i!==c?.index&&(n=ro.nextNode(),i++)}return ro.currentNode=Pt,e}p(t){let o=0;for(const r of this._$AV)void 0!==r&&(void 0!==r.strings?(r._$AI(t,r,o),o+=r.strings.length-2):r._$AI(t[o])),o++}}(e,this),r=t.u(this.options);t.p(o),this.$(r),this._$AH=t}}_$AC(t){let o=oo.get(t.strings);return void 0===o&&oo.set(t.strings,o=new no(t)),o}T(o){Dt(this._$AH)||(this._$AH=[],this._$AR());const r=this._$AH;let e,n=0;for(const i of o)n===r.length?r.push(e=new t(this.k(Bt()),this.k(Bt()),this,this.options)):e=r[n],e._$AI(i),n++;n<r.length&&(this._$AR(e&&e._$AB.nextSibling,n),r.length=n)}_$AR(t=this._$AA.nextSibling,o){for(this._$AP?.(!1,!0,o);t&&t!==this._$AB;){const o=t.nextSibling;t.remove(),t=o}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}},co=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,o,r,e,n){this.type=1,this._$AH=to,this._$AN=void 0,this.element=t,this.name=o,this._$AM=e,this.options=n,r.length>2||""!==r[0]||""!==r[1]?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=to}_$AI(t,o=this,r,e){const n=this.strings;let i=!1;if(void 0===n)t=io(this,t,o,0),i=!_t(t)||t!==this._$AH&&t!==Qt,i&&(this._$AH=t);else{const e=t;let a,c;for(t=n[0],a=0;a<n.length-1;a++)c=io(this,e[r+a],o,a),c===Qt&&(c=this._$AH[a]),i||=!_t(c)||c!==this._$AH[a],c===to?t=to:t!==to&&(t+=(c??"")+n[a+1]),this._$AH[a]=c}i&&!e&&this.O(t)}O(t){t===to?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},so=class extends co{constructor(){super(...arguments),this.type=3}O(t){this.element[this.name]=t===to?void 0:t}},lo=class extends co{constructor(){super(...arguments),this.type=4}O(t){this.element.toggleAttribute(this.name,!!t&&t!==to)}},fo=class extends co{constructor(t,o,r,e,n){super(t,o,r,e,n),this.type=5}_$AI(t,o=this){if((t=io(this,t,o,0)??to)===Qt)return;const r=this._$AH,e=t===to&&r!==to||t.capture!==r.capture||t.once!==r.once||t.passive!==r.passive,n=t!==to&&(r===to||e);e&&this.element.removeEventListener(this.name,this,r),n&&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)}},ho=class{constructor(t,o,r){this.element=t,this.type=6,this._$AN=void 0,this._$AM=o,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(t){io(this,t)}};const uo=Kt.litHtmlPolyfillSupport;uo?.(no,ao),(Kt.litHtmlVersions??=[]).push("3.1.0");
54
54
  /**
55
55
  * @license
56
56
  * Copyright 2017 Google LLC
@@ -98,7 +98,7 @@ const vo=window,No=vo.ShadowRoot&&(void 0===vo.ShadyCSS||vo.ShadyCSS.nativeShado
98
98
  display: inline-block;
99
99
  width: 0;
100
100
  }
101
- `;class Lo{constructor(t,o){this.defaultLabels=t,this.labels=o}resolve(t,...o){var r,e;t=this.resolvePluralKey(t,o);let n=null!==(e=null!==(r=this.labels[t])&&void 0!==r?r:this.defaultLabels[t])&&void 0!==e?e:"";return o.forEach(((t,o)=>n=n.replace(new RegExp(`\\{${o}([^}]*)\\}`,"g"),((o,r)=>this.formatValue(t,r))))),n}resolvePluralKey(t,o){for(let r of o)if("number"==typeof r){const o=`${String(t)}[\\=${r}]`;if(o in this.labels||o in this.defaultLabels)return o}return t}formatValue(t,o){return t instanceof Date?this.formatDate(t,o):null!=t?t:""}formatDate(t,o){const r=r=>(null==o?void 0:o.includes("date"))?t.toLocaleDateString(r):(null==o?void 0:o.includes("time"))?t.toLocaleTimeString(r):t.toLocaleString(r);try{return r(document.documentElement.lang)}catch(t){return r()}}}function Wo(t){for(var o=arguments.length,r=Array(o>1?o-1:0),e=1;e<o;e++)r[e-1]=arguments[e];throw Error("[Immer] minified error nr: "+t+(r.length?" "+r.map((function(t){return"'"+t+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function ko(t){return!!t&&!!t[mr]}function Ko(t){var o;return!!t&&(function(t){if(!t||"object"!=typeof t)return!1;var o=Object.getPrototypeOf(t);if(null===o)return!0;var r=Object.hasOwnProperty.call(o,"constructor")&&o.constructor;return r===Object||"function"==typeof r&&Function.toString.call(r)===Or}(t)||Array.isArray(t)||!!t[gr]||!!(null===(o=t.constructor)||void 0===o?void 0:o[gr])||$o(t)||Po(t))}function Ao(t,o,r){void 0===r&&(r=!1),0===jo(t)?(r?Object.keys:vr)(t).forEach((function(e){r&&"symbol"==typeof e||o(e,t[e],t)})):t.forEach((function(r,e){return o(e,r,t)}))}function jo(t){var o=t[mr];return o?o.i>3?o.i-4:o.i:Array.isArray(t)?1:$o(t)?2:Po(t)?3:0}function Zo(t,o){return 2===jo(t)?t.has(o):Object.prototype.hasOwnProperty.call(t,o)}function Mo(t,o,r){var e=jo(t);2===e?t.set(o,r):3===e?t.add(r):t[o]=r}function Fo(t,o){return t===o?0!==t||1/t==1/o:t!=t&&o!=o}function $o(t){return dr&&t instanceof Map}function Po(t){return pr&&t instanceof Set}function Bo(t){return t.o||t.t}function _o(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var o=Nr(t);delete o[mr];for(var r=vr(o),e=0;e<r.length;e++){var n=r[e],i=o[n];!1===i.writable&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(o[n]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[n]})}return Object.create(Object.getPrototypeOf(t),o)}function Do(t,o){return void 0===o&&(o=!1),To(t)||ko(t)||!Ko(t)||(jo(t)>1&&(t.set=t.add=t.clear=t.delete=zo),Object.freeze(t),o&&Ao(t,(function(t,o){return Do(o,!0)}),!0)),t}function zo(){Wo(2)}function To(t){return null==t||"object"!=typeof t||Object.isFrozen(t)}function Go(t){var o=wr[t];return o||Wo(18,t),o}function Ho(){return ur}function qo(t,o){o&&(Go("Patches"),t.u=[],t.s=[],t.v=o)}function Yo(t){Vo(t),t.p.forEach(Xo),t.p=null}function Vo(t){t===ur&&(ur=t.l)}function Jo(t){return ur={p:[],l:ur,h:t,m:!0,_:0}}function Xo(t){var o=t[mr];0===o.i||1===o.i?o.j():o.g=!0}function Qo(t,o){o._=o.p.length;var r=o.p[0],e=void 0!==t&&t!==r;return o.h.O||Go("ES5").S(o,t,e),e?(r[mr].P&&(Yo(o),Wo(4)),Ko(t)&&(t=tr(o,t),o.l||rr(o,t)),o.u&&Go("Patches").M(r[mr].t,t,o.u,o.s)):t=tr(o,r,[]),Yo(o),o.u&&o.v(o.u,o.s),t!==br?t:void 0}function tr(t,o,r){if(To(o))return o;var e=o[mr];if(!e)return Ao(o,(function(n,i){return or(t,e,o,n,i,r)}),!0),o;if(e.A!==t)return o;if(!e.P)return rr(t,e.t,!0),e.t;if(!e.I){e.I=!0,e.A._--;var n=4===e.i||5===e.i?e.o=_o(e.k):e.o,i=n,a=!1;3===e.i&&(i=new Set(n),n.clear(),a=!0),Ao(i,(function(o,i){return or(t,e,n,o,i,r,a)})),rr(t,n,!1),r&&t.u&&Go("Patches").N(e,r,t.u,t.s)}return e.o}function or(t,o,r,e,n,i,a){if(ko(n)){var c=tr(t,n,i&&o&&3!==o.i&&!Zo(o.R,e)?i.concat(e):void 0);if(Mo(r,e,c),!ko(c))return;t.m=!1}else a&&r.add(n);if(Ko(n)&&!To(n)){if(!t.h.D&&t._<1)return;tr(t,n),o&&o.A.l||rr(t,n)}}function rr(t,o,r){void 0===r&&(r=!1),!t.l&&t.h.D&&t.m&&Do(o,r)}function er(t,o){var r=t[mr];return(r?Bo(r):t)[o]}function nr(t,o){if(o in t)for(var r=Object.getPrototypeOf(t);r;){var e=Object.getOwnPropertyDescriptor(r,o);if(e)return e;r=Object.getPrototypeOf(r)}}function ir(t){t.P||(t.P=!0,t.l&&ir(t.l))}function ar(t){t.o||(t.o=_o(t.t))}function cr(t,o,r){var e=$o(o)?Go("MapSet").F(o,r):Po(o)?Go("MapSet").T(o,r):t.O?function(t,o){var r=Array.isArray(t),e={i:r?1:0,A:o?o.A:Ho(),P:!1,I:!1,R:{},l:o,t,k:null,o:null,j:null,C:!1},n=e,i=Sr;r&&(n=[e],i=Cr);var a=Proxy.revocable(n,i),c=a.revoke,s=a.proxy;return e.k=s,e.j=c,s}(o,r):Go("ES5").J(o,r);return(r?r.A:Ho()).p.push(e),e}function sr(t){return ko(t)||Wo(22,t),function t(o){if(!Ko(o))return o;var r,e=o[mr],n=jo(o);if(e){if(!e.P&&(e.i<4||!Go("ES5").K(e)))return e.t;e.I=!0,r=lr(o,n),e.I=!1}else r=lr(o,n);return Ao(r,(function(o,n){e&&function(t,o){return 2===jo(t)?t.get(o):t[o]}(e.t,o)===n||Mo(r,o,t(n))})),3===n?new Set(r):r}(t)}function lr(t,o){switch(o){case 2:return new Map(t);case 3:return Array.from(t)}return _o(t)}var fr,ur,hr="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),dr="undefined"!=typeof Map,pr="undefined"!=typeof Set,yr="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,br=hr?Symbol.for("immer-nothing"):((fr={})["immer-nothing"]=!0,fr),gr=hr?Symbol.for("immer-draftable"):"__$immer_draftable",mr=hr?Symbol.for("immer-state"):"__$immer_state",Or=""+Object.prototype.constructor,vr="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,Nr=Object.getOwnPropertyDescriptors||function(t){var o={};return vr(t).forEach((function(r){o[r]=Object.getOwnPropertyDescriptor(t,r)})),o},wr={},Sr={get:function(t,o){if(o===mr)return t;var r=Bo(t);if(!Zo(r,o))return function(t,o,r){var e,n=nr(o,r);return n?"value"in n?n.value:null===(e=n.get)||void 0===e?void 0:e.call(t.k):void 0}(t,r,o);var e=r[o];return t.I||!Ko(e)?e:e===er(t.t,o)?(ar(t),t.o[o]=cr(t.A.h,e,t)):e},has:function(t,o){return o in Bo(t)},ownKeys:function(t){return Reflect.ownKeys(Bo(t))},set:function(t,o,r){var e=nr(Bo(t),o);if(null==e?void 0:e.set)return e.set.call(t.k,r),!0;if(!t.P){var n=er(Bo(t),o),i=null==n?void 0:n[mr];if(i&&i.t===r)return t.o[o]=r,t.R[o]=!1,!0;if(Fo(r,n)&&(void 0!==r||Zo(t.t,o)))return!0;ar(t),ir(t)}return t.o[o]===r&&(void 0!==r||o in t.o)||Number.isNaN(r)&&Number.isNaN(t.o[o])||(t.o[o]=r,t.R[o]=!0),!0},deleteProperty:function(t,o){return void 0!==er(t.t,o)||o in t.t?(t.R[o]=!1,ar(t),ir(t)):delete t.R[o],t.o&&delete t.o[o],!0},getOwnPropertyDescriptor:function(t,o){var r=Bo(t),e=Reflect.getOwnPropertyDescriptor(r,o);return e?{writable:!0,configurable:1!==t.i||"length"!==o,enumerable:e.enumerable,value:r[o]}:e},defineProperty:function(){Wo(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){Wo(12)}},Cr={};Ao(Sr,(function(t,o){Cr[t]=function(){return arguments[0]=arguments[0][0],o.apply(this,arguments)}})),Cr.deleteProperty=function(t,o){return Cr.set.call(this,t,o,void 0)},Cr.set=function(t,o,r){return Sr.set.call(this,t[0],o,r,t[0])};var Er=function(){function t(t){var o=this;this.O=yr,this.D=!0,this.produce=function(t,r,e){if("function"==typeof t&&"function"!=typeof r){var n=r;r=t;var i=o;return function(t){var o=this;void 0===t&&(t=n);for(var e=arguments.length,a=Array(e>1?e-1:0),c=1;c<e;c++)a[c-1]=arguments[c];return i.produce(t,(function(t){var e;return(e=r).call.apply(e,[o,t].concat(a))}))}}var a;if("function"!=typeof r&&Wo(6),void 0!==e&&"function"!=typeof e&&Wo(7),Ko(t)){var c=Jo(o),s=cr(o,t,void 0),l=!0;try{a=r(s),l=!1}finally{l?Yo(c):Vo(c)}return"undefined"!=typeof Promise&&a instanceof Promise?a.then((function(t){return qo(c,e),Qo(t,c)}),(function(t){throw Yo(c),t})):(qo(c,e),Qo(a,c))}if(!t||"object"!=typeof t){if(void 0===(a=r(t))&&(a=t),a===br&&(a=void 0),o.D&&Do(a,!0),e){var f=[],u=[];Go("Patches").M(t,a,f,u),e(f,u)}return a}Wo(21,t)},this.produceWithPatches=function(t,r){if("function"==typeof t)return function(r){for(var e=arguments.length,n=Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];return o.produceWithPatches(r,(function(o){return t.apply(void 0,[o].concat(n))}))};var e,n,i=o.produce(t,r,(function(t,o){e=t,n=o}));return"undefined"!=typeof Promise&&i instanceof Promise?i.then((function(t){return[t,e,n]})):[i,e,n]},"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 o=t.prototype;return o.createDraft=function(t){Ko(t)||Wo(8),ko(t)&&(t=sr(t));var o=Jo(this),r=cr(this,t,void 0);return r[mr].C=!0,Vo(o),r},o.finishDraft=function(t,o){var r=(t&&t[mr]).A;return qo(r,o),Qo(void 0,r)},o.setAutoFreeze=function(t){this.D=t},o.setUseProxies=function(t){t&&!yr&&Wo(20),this.O=t},o.applyPatches=function(t,o){var r;for(r=o.length-1;r>=0;r--){var e=o[r];if(0===e.path.length&&"replace"===e.op){t=e.value;break}}r>-1&&(o=o.slice(r+1));var n=Go("Patches").$;return ko(t)?n(t,o):this.produce(t,(function(t){return n(t,o)}))},t}(),xr=new Er,Rr=xr.produce;function Ur(t){return Ur="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},Ur(t)}function Ir(t){var o=function(t,o){if("object"!==Ur(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var e=r.call(t,o||"default");if("object"!==Ur(e))return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===o?String:Number)(t)}(t,"string");return"symbol"===Ur(o)?o:String(o)}function Lr(t,o,r){return(o=Ir(o))in t?Object.defineProperty(t,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[o]=r,t}function Wr(t,o){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var e=Object.getOwnPropertySymbols(t);o&&(e=e.filter((function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable}))),r.push.apply(r,e)}return r}function kr(t){for(var o=1;o<arguments.length;o++){var r=null!=arguments[o]?arguments[o]:{};o%2?Wr(Object(r),!0).forEach((function(o){Lr(t,o,r[o])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Wr(Object(r)).forEach((function(o){Object.defineProperty(t,o,Object.getOwnPropertyDescriptor(r,o))}))}return t}function Kr(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. "}xr.produceWithPatches.bind(xr),xr.setAutoFreeze.bind(xr),xr.setUseProxies.bind(xr),xr.applyPatches.bind(xr),xr.createDraft.bind(xr),xr.finishDraft.bind(xr);var Ar="function"==typeof Symbol&&Symbol.observable||"@@observable",jr=function(){return Math.random().toString(36).substring(7).split("").join(".")},Zr={INIT:"@@redux/INIT"+jr(),REPLACE:"@@redux/REPLACE"+jr(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+jr()}};function Mr(t,o,r){var e;if("function"==typeof o&&"function"==typeof r||"function"==typeof r&&"function"==typeof arguments[3])throw new Error(Kr(0));if("function"==typeof o&&void 0===r&&(r=o,o=void 0),void 0!==r){if("function"!=typeof r)throw new Error(Kr(1));return r(Mr)(t,o)}if("function"!=typeof t)throw new Error(Kr(2));var n=t,i=o,a=[],c=a,s=!1;function l(){c===a&&(c=a.slice())}function f(){if(s)throw new Error(Kr(3));return i}function u(t){if("function"!=typeof t)throw new Error(Kr(4));if(s)throw new Error(Kr(5));var o=!0;return l(),c.push(t),function(){if(o){if(s)throw new Error(Kr(6));o=!1,l();var r=c.indexOf(t);c.splice(r,1),a=null}}}function h(t){if(!function(t){if("object"!=typeof t||null===t)return!1;for(var o=t;null!==Object.getPrototypeOf(o);)o=Object.getPrototypeOf(o);return Object.getPrototypeOf(t)===o}(t))throw new Error(Kr(7));if(void 0===t.type)throw new Error(Kr(8));if(s)throw new Error(Kr(9));try{s=!0,i=n(i,t)}finally{s=!1}for(var o=a=c,r=0;r<o.length;r++){(0,o[r])()}return t}return h({type:Zr.INIT}),(e={dispatch:h,subscribe:u,getState:f,replaceReducer:function(t){if("function"!=typeof t)throw new Error(Kr(10));n=t,h({type:Zr.REPLACE})}})[Ar]=function(){var t,o=u;return(t={subscribe:function(t){if("object"!=typeof t||null===t)throw new Error(Kr(11));function r(){t.next&&t.next(f())}return r(),{unsubscribe:o(r)}}})[Ar]=function(){return this},t},e}function Fr(t){for(var o=Object.keys(t),r={},e=0;e<o.length;e++){var n=o[e];"function"==typeof t[n]&&(r[n]=t[n])}var i,a=Object.keys(r);try{!function(t){Object.keys(t).forEach((function(o){var r=t[o];if(void 0===r(void 0,{type:Zr.INIT}))throw new Error(Kr(12));if(void 0===r(void 0,{type:Zr.PROBE_UNKNOWN_ACTION()}))throw new Error(Kr(13))}))}(r)}catch(t){i=t}return function(t,o){if(void 0===t&&(t={}),i)throw i;for(var e=!1,n={},c=0;c<a.length;c++){var s=a[c],l=r[s],f=t[s],u=l(f,o);if(void 0===u)throw o&&o.type,new Error(Kr(14));n[s]=u,e=e||u!==f}return(e=e||a.length!==Object.keys(t).length)?n:t}}function $r(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return 0===o.length?function(t){return t}:1===o.length?o[0]:o.reduce((function(t,o){return function(){return t(o.apply(void 0,arguments))}}))}function Pr(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return function(t){return function(){var r=t.apply(void 0,arguments),e=function(){throw new Error(Kr(15))},n={getState:r.getState,dispatch:function(){return e.apply(void 0,arguments)}},i=o.map((function(t){return t(n)}));return e=$r.apply(void 0,i)(r.dispatch),kr(kr({},r),{},{dispatch:e})}}}function Br(t){return function(o){var r=o.dispatch,e=o.getState;return function(o){return function(n){return"function"==typeof n?n(r,e,t):o(n)}}}}var _r=Br();_r.withExtraArgument=Br;var Dr,zr=_r,Tr=(Dr=function(t,o){return Dr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,o){t.__proto__=o}||function(t,o){for(var r in o)Object.prototype.hasOwnProperty.call(o,r)&&(t[r]=o[r])},Dr(t,o)},function(t,o){if("function"!=typeof o&&null!==o)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");function r(){this.constructor=t}Dr(t,o),t.prototype=null===o?Object.create(o):(r.prototype=o.prototype,new r)}),Gr=function(t,o){var r,e,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function c(i){return function(c){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,e&&(n=2&i[0]?e.return:i[0]?e.throw||((n=e.return)&&n.call(e),0):e.next)&&!(n=n.call(e,i[1])).done)return n;switch(e=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,e=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=a.trys,(n=n.length>0&&n[n.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=o.call(t,a)}catch(t){i=[6,t],e=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,c])}}},Hr=function(t,o){for(var r=0,e=o.length,n=t.length;r<e;r++,n++)t[n]=o[r];return t},qr=Object.defineProperty,Yr=Object.defineProperties,Vr=Object.getOwnPropertyDescriptors,Jr=Object.getOwnPropertySymbols,Xr=Object.prototype.hasOwnProperty,Qr=Object.prototype.propertyIsEnumerable,te=function(t,o,r){return o in t?qr(t,o,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[o]=r},oe=function(t,o){for(var r in o||(o={}))Xr.call(o,r)&&te(t,r,o[r]);if(Jr)for(var e=0,n=Jr(o);e<n.length;e++){r=n[e];Qr.call(o,r)&&te(t,r,o[r])}return t},re=function(t,o){return Yr(t,Vr(o))},ee="undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(0!==arguments.length)return"object"==typeof arguments[0]?$r:$r.apply(null,arguments)};var ne=function(t){function o(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var n=t.apply(this,r)||this;return Object.setPrototypeOf(n,o.prototype),n}return Tr(o,t),Object.defineProperty(o,Symbol.species,{get:function(){return o},enumerable:!1,configurable:!0}),o.prototype.concat=function(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];return t.prototype.concat.apply(this,o)},o.prototype.prepend=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return 1===t.length&&Array.isArray(t[0])?new(o.bind.apply(o,Hr([void 0],t[0].concat(this)))):new(o.bind.apply(o,Hr([void 0],t.concat(this))))},o}(Array),ie=function(t){function o(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var n=t.apply(this,r)||this;return Object.setPrototypeOf(n,o.prototype),n}return Tr(o,t),Object.defineProperty(o,Symbol.species,{get:function(){return o},enumerable:!1,configurable:!0}),o.prototype.concat=function(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];return t.prototype.concat.apply(this,o)},o.prototype.prepend=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return 1===t.length&&Array.isArray(t[0])?new(o.bind.apply(o,Hr([void 0],t[0].concat(this)))):new(o.bind.apply(o,Hr([void 0],t.concat(this))))},o}(Array);function ae(t){return Ko(t)?Rr(t,(function(){})):t}function ce(){return function(t){return function(t){void 0===t&&(t={});var o=t.thunk,r=void 0===o||o;t.immutableCheck,t.serializableCheck;var e=new ne;r&&(!function(t){return"boolean"==typeof t}(r)?e.push(zr.withExtraArgument(r.extraArgument)):e.push(zr));return e}(t)}}function se(t){var o,r=ce(),e=t||{},n=e.reducer,i=void 0===n?void 0:n,a=e.middleware,c=void 0===a?r():a,s=e.devTools,l=void 0===s||s,f=e.preloadedState,u=void 0===f?void 0:f,h=e.enhancers,d=void 0===h?void 0:h;if("function"==typeof i)o=i;else{if(!function(t){if("object"!=typeof t||null===t)return!1;var o=Object.getPrototypeOf(t);if(null===o)return!0;for(var r=o;null!==Object.getPrototypeOf(r);)r=Object.getPrototypeOf(r);return o===r}(i))throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');o=Fr(i)}var p=c;"function"==typeof p&&(p=p(r));var y=Pr.apply(void 0,p),b=$r;l&&(b=ee(oe({trace:!1},"object"==typeof l&&l)));var g=new ie(y),m=g;return Array.isArray(d)?m=Hr([y],d):"function"==typeof d&&(m=d(g)),Mr(o,u,b.apply(void 0,m))}function le(t,o){function r(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];if(o){var n=o.apply(void 0,r);if(!n)throw new Error("prepareAction did not return an object");return oe(oe({type:t,payload:n.payload},"meta"in n&&{meta:n.meta}),"error"in n&&{error:n.error})}return{type:t,payload:r[0]}}return r.toString=function(){return""+t},r.type=t,r.match=function(o){return o.type===t},r}function fe(t){var o,r={},e=[],n={addCase:function(t,o){var e="string"==typeof t?t:t.type;if(e in r)throw new Error("addCase cannot be called with two reducers for the same action type");return r[e]=o,n},addMatcher:function(t,o){return e.push({matcher:t,reducer:o}),n},addDefaultCase:function(t){return o=t,n}};return t(n),[r,e,o]}function ue(t){var o=t.name;if(!o)throw new Error("`name` is a required option for createSlice");var r,e="function"==typeof t.initialState?t.initialState:ae(t.initialState),n=t.reducers||{},i=Object.keys(n),a={},c={},s={};function l(){var o="function"==typeof t.extraReducers?fe(t.extraReducers):[t.extraReducers],r=o[0],n=void 0===r?{}:r,i=o[1],a=void 0===i?[]:i,s=o[2],l=void 0===s?void 0:s,f=oe(oe({},n),c);return function(t,o,r,e){void 0===r&&(r=[]);var n,i="function"==typeof o?fe(o):[o,r,e],a=i[0],c=i[1],s=i[2];if(function(t){return"function"==typeof t}(t))n=function(){return ae(t())};else{var l=ae(t);n=function(){return l}}function f(t,o){void 0===t&&(t=n());var r=Hr([a[o.type]],c.filter((function(t){return(0,t.matcher)(o)})).map((function(t){return t.reducer})));return 0===r.filter((function(t){return!!t})).length&&(r=[s]),r.reduce((function(t,r){if(r){var e;if(ko(t))return void 0===(e=r(t,o))?t:e;if(Ko(t))return Rr(t,(function(t){return r(t,o)}));if(void 0===(e=r(t,o))){if(null===t)return t;throw Error("A case reducer on a non-draftable value must not return undefined")}return e}return t}),t)}return f.getInitialState=n,f}(e,(function(t){for(var o in f)t.addCase(o,f[o]);for(var r=0,e=a;r<e.length;r++){var n=e[r];t.addMatcher(n.matcher,n.reducer)}l&&t.addDefaultCase(l)}))}return i.forEach((function(t){var r,e,i=n[t],l=o+"/"+t;"reducer"in i?(r=i.reducer,e=i.prepare):r=i,a[t]=r,c[l]=r,s[t]=e?le(l,e):le(l)})),{name:o,reducer:function(t,o){return r||(r=l()),r(t,o)},actions:s,caseReducers:a,getInitialState:function(){return r||(r=l()),r.getInitialState()}}}var he=["name","message","stack","code"],de=function(t,o){this.payload=t,this.meta=o},pe=function(t,o){this.payload=t,this.meta=o},ye=function(t){if("object"==typeof t&&null!==t){for(var o={},r=0,e=he;r<e.length;r++){var n=e[r];"string"==typeof t[n]&&(o[n]=t[n])}return o}return{message:String(t)}};function be(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}!function(){function t(t,o,r){var e=le(t+"/fulfilled",(function(t,o,r,e){return{payload:t,meta:re(oe({},e||{}),{arg:r,requestId:o,requestStatus:"fulfilled"})}})),n=le(t+"/pending",(function(t,o,r){return{payload:void 0,meta:re(oe({},r||{}),{arg:o,requestId:t,requestStatus:"pending"})}})),i=le(t+"/rejected",(function(t,o,e,n,i){return{payload:n,error:(r&&r.serializeError||ye)(t||"Rejected"),meta:re(oe({},i||{}),{arg:e,requestId:o,rejectedWithValue:!!n,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(c,s,l){var f,u=(null==r?void 0:r.idGenerator)?r.idGenerator(t):function(t){void 0===t&&(t=21);for(var o="",r=t;r--;)o+="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW"[64*Math.random()|0];return o}(),h=new a;function d(t){f=t,h.abort()}var p=function(){return a=this,p=null,y=function(){var a,p,y,b,g,m;return Gr(this,(function(O){switch(O.label){case 0:return O.trys.push([0,4,,5]),b=null==(a=null==r?void 0:r.condition)?void 0:a.call(r,t,{getState:s,extra:l}),null===(v=b)||"object"!=typeof v||"function"!=typeof v.then?[3,2]:[4,b];case 1:b=O.sent(),O.label=2;case 2:if(!1===b||h.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return g=new Promise((function(t,o){return h.signal.addEventListener("abort",(function(){return o({name:"AbortError",message:f||"Aborted"})}))})),c(n(u,t,null==(p=null==r?void 0:r.getPendingMeta)?void 0:p.call(r,{requestId:u,arg:t},{getState:s,extra:l}))),[4,Promise.race([g,Promise.resolve(o(t,{dispatch:c,getState:s,extra:l,requestId:u,signal:h.signal,abort:d,rejectWithValue:function(t,o){return new de(t,o)},fulfillWithValue:function(t,o){return new pe(t,o)}})).then((function(o){if(o instanceof de)throw o;return o instanceof pe?e(o.payload,u,t,o.meta):e(o,u,t)}))])];case 3:return y=O.sent(),[3,5];case 4:return m=O.sent(),y=m instanceof de?i(null,u,t,m.payload,m.meta):i(m,u,t),[3,5];case 5:return r&&!r.dispatchConditionRejection&&i.match(y)&&y.meta.condition||c(y),[2,y]}var v}))},new Promise((function(t,o){var r=function(t){try{n(y.next(t))}catch(t){o(t)}},e=function(t){try{n(y.throw(t))}catch(t){o(t)}},n=function(o){return o.done?t(o.value):Promise.resolve(o.value).then(r,e)};n((y=y.apply(a,p)).next())}));var a,p,y}();return Object.assign(p,{abort:d,requestId:u,arg:t,unwrap:function(){return p.then(be)}})}}),{pending:n,rejected:i,fulfilled:e,typePrefix:t})}t.withTypes=function(){return t}}();var ge,me,Oe="listenerMiddleware";le(Oe+"/add"),le(Oe+"/removeAll"),le(Oe+"/remove"),"function"==typeof queueMicrotask&&queueMicrotask.bind("undefined"!=typeof window?window:"undefined"!=typeof global?global:globalThis),function(){function t(t,o){var r=n[t];return r?r.enumerable=o:n[t]=r={configurable:!0,enumerable:o,get:function(){var o=this[mr];return Sr.get(o,t)},set:function(o){var r=this[mr];Sr.set(r,t,o)}},r}function o(t){for(var o=t.length-1;o>=0;o--){var n=t[o][mr];if(!n.P)switch(n.i){case 5:e(n)&&ir(n);break;case 4:r(n)&&ir(n)}}}function r(t){for(var o=t.t,r=t.k,e=vr(r),n=e.length-1;n>=0;n--){var i=e[n];if(i!==mr){var a=o[i];if(void 0===a&&!Zo(o,i))return!0;var c=r[i],s=c&&c[mr];if(s?s.t!==a:!Fo(c,a))return!0}}var l=!!o[mr];return e.length!==vr(o).length+(l?0:1)}function e(t){var o=t.k;if(o.length!==t.t.length)return!0;var r=Object.getOwnPropertyDescriptor(o,o.length-1);if(r&&!r.get)return!0;for(var e=0;e<o.length;e++)if(!o.hasOwnProperty(e))return!0;return!1}var n={};!function(t,o){wr[t]||(wr[t]=o)}("ES5",{J:function(o,r){var e=Array.isArray(o),n=function(o,r){if(o){for(var e=Array(r.length),n=0;n<r.length;n++)Object.defineProperty(e,""+n,t(n,!0));return e}var i=Nr(r);delete i[mr];for(var a=vr(i),c=0;c<a.length;c++){var s=a[c];i[s]=t(s,o||!!i[s].enumerable)}return Object.create(Object.getPrototypeOf(r),i)}(e,o),i={i:e?5:4,A:r?r.A:Ho(),P:!1,I:!1,R:{},l:r,t:o,k:n,o:null,g:!1,C:!1};return Object.defineProperty(n,mr,{value:i,writable:!0}),n},S:function(t,r,n){n?ko(r)&&r[mr].A===t&&o(t.p):(t.u&&function t(o){if(o&&"object"==typeof o){var r=o[mr];if(r){var n=r.t,i=r.k,a=r.R,c=r.i;if(4===c)Ao(i,(function(o){o!==mr&&(void 0!==n[o]||Zo(n,o)?a[o]||t(i[o]):(a[o]=!0,ir(r)))})),Ao(n,(function(t){void 0!==i[t]||Zo(i,t)||(a[t]=!1,ir(r))}));else if(5===c){if(e(r)&&(ir(r),a.length=!0),i.length<n.length)for(var s=i.length;s<n.length;s++)a[s]=!1;else for(var l=n.length;l<i.length;l++)a[l]=!0;for(var f=Math.min(i.length,n.length),u=0;u<f;u++)i.hasOwnProperty(u)||(a[u]=!0),void 0===a[u]&&t(i[u])}}}}(t.p[0]),o(t.p))},K:function(t){return 4===t.i?r(t):e(t)}})}(),window.ftReduxStores||(window.ftReduxStores={});class ve{static get(t){var o;const r="string"==typeof t?t:t.name,e="string"==typeof t?void 0:t,n=window.ftReduxStores[r];if(function(t){var o;return null!==(o=null==t?void 0:t.isFtReduxStore)&&void 0!==o&&o}(n))return n;if(null==e)return;const i=ue({...e,reducers:null!==(o=e.reducers)&&void 0!==o?o:{}}),a=se({reducer:(t,o)=>{var r;switch(o.type){case"CLEAR_FT_REDUX_STORE":return i.getInitialState();case"DEFAULT_STATE_FIELDS_VALUES_SETTER":return{...t,...null!==(r=o.overwrites)&&void 0!==r?r:{}};default:return i.reducer(t,o)}}});return window.ftReduxStores[e.name]=new ve(i,a)}constructor(t,o){this.reduxSlice=t,this.reduxStore=o,this.isFtReduxStore=!0,this.eventBus=document.createElement("event-bus"),this.actions=new Proxy(this.reduxSlice.actions,{get:(t,o,r)=>{const e=o,n=t[e];return n?(...t)=>{const o=n(...t);return this.reduxStore.dispatch(o),o}:t=>{this.setState({[e]: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===(me=null===(ge=window.safari)||void 0===ge?void 0:ge.pushNotification)||void 0===me||me.toString());const Ne=bt`
102
- `,we="ft-app-info",Se=ve.get({name:we,reducers:{setBaseUrl:(t,o)=>{t.baseUrl=o.payload},setApiIntegrationIdentifier:(t,o)=>{t.apiIntegrationIdentifier=o.payload},setUiLocale:(t,o)=>{t.uiLocale=o.payload},setAvailableUiLocales:(t,o)=>{t.availableUiLocales=o.payload},setEditorMode:(t,o)=>{t.editorMode=o.payload},setNoCustom:(t,o)=>{t.noCustom=o.payload},setNoCustomComponent:(t,o)=>{t.noCustomComponent=o.payload},setSession:(t,o)=>{t.session=o.payload}},initialState:{uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],editorMode:!1,noCustom:!1,noCustomComponent:!1}});class Ce{static build(t){const{baseUrl:o,apiIntegrationIdentifier:r}=Se.getState(),e=null!=t?t:r;if(o&&e&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,e,!0)}static get(t){var o;return null!=t?Ce.build(t):null!==(o=Ce.API)&&void 0!==o?o:Ce.API=Ce.build()}static await(t){return new Promise((o=>{let r=Ce.get(t);if(r)o(r);else{const e=Se.subscribe((()=>{r=Ce.get(t),r&&(e(),o(r))}))}}))}}var Ee;const xe=Symbol("clearAfterUnitTest");class Re{constructor(t){this.messageContextProvider=t,this.defaultMessages={},this.cache=new e,this.listeners={},this.currentUiLocale="",this[Ee]=()=>{this.defaultMessages={},this.cache=new e,this.listeners={}},this.currentUiLocale=Se.getState().uiLocale,Se.subscribe((()=>this.clearWhenUiLocaleChanges()))}clearWhenUiLocaleChanges(){const{uiLocale:t}=Se.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){const o=t.name.toLowerCase();this.cache.setFinal(o,t),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,o){var r;if(t=t.toLowerCase(),Object.keys(o).length>0){const e={...null!==(r=this.defaultMessages[t])&&void 0!==r?r:{},...o};I(this.defaultMessages[t],e)||(this.defaultMessages[t]=e,await this.notify(t))}await this.fetchContext(t)}resolveMessage(t,o,...r){var e,n,i;t=t.toLowerCase(),this.fetchContext(t);const a=null!==(n=null===(e=this.cache.getNow(t))||void 0===e?void 0:e.messages)&&void 0!==n?n:{};return new Lo(null!==(i=this.defaultMessages[t])&&void 0!==i?i:{},a).resolve(o,...r)}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,o){var r;return t=t.toLowerCase(),this.listeners[t]=null!==(r=this.listeners[t])&&void 0!==r?r:new Set,this.listeners[t].add(o),()=>{var r;return null===(r=this.listeners[t])||void 0===r?void 0:r.delete(o)}}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=>{return(o=0,new Promise((t=>setTimeout(t,o)))).then((()=>t())).catch((()=>null));var o})))}}Ee=xe,null==window.FluidTopicsI18nService&&(window.FluidTopicsI18nService=new Re((async(t,o)=>(await Ce.await()).getFluidTopicsMessageContext(t,o)))),null==window.FluidTopicsCustomI18nService&&(window.FluidTopicsCustomI18nService=new Re((async(t,o)=>(await Ce.await()).getCustomMessageContext(t,o))));const Ue=window.FluidTopicsI18nService,Ie=window.FluidTopicsCustomI18nService;var Le=function(t,o,r,e){for(var n,i=arguments.length,a=i<3?o:null===e?e=Object.getOwnPropertyDescriptor(o,r):e,c=t.length-1;c>=0;c--)(n=t[c])&&(a=(i<3?n(a):i>3?n(o,r,a):n(o,r))||a);return i>3&&a&&Object.defineProperty(o,r,a),a};class We extends Uo{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.availableUiLocales=[],this.editorMode=!1,this.noCustom=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.messageContexts=[],this.apiProvider=()=>Ce.get(),this.cache=new e,this.cleanSessionDebouncer=new U}render(){return Xt`
101
+ `;class Lo{constructor(t,o){this.defaultLabels=t,this.labels=o}resolve(t,...o){var r,e;t=this.resolvePluralKey(t,o);let n=null!==(e=null!==(r=this.labels[t])&&void 0!==r?r:this.defaultLabels[t])&&void 0!==e?e:"";return o.forEach(((t,o)=>n=n.replace(new RegExp(`\\{${o}([^}]*)\\}`,"g"),((o,r)=>this.formatValue(t,r))))),n}resolvePluralKey(t,o){for(let r of o)if("number"==typeof r){const o=`${String(t)}[\\=${r}]`;if(o in this.labels||o in this.defaultLabels)return o}return t}formatValue(t,o){return t instanceof Date?this.formatDate(t,o):null!=t?t:""}formatDate(t,o){const r=r=>(null==o?void 0:o.includes("date"))?t.toLocaleDateString(r):(null==o?void 0:o.includes("time"))?t.toLocaleTimeString(r):t.toLocaleString(r);try{return r(document.documentElement.lang)}catch(t){return r()}}}class Wo{constructor(){this.stack=[]}add(t,o=!1){o&&(this.stack=this.stack.filter((o=>o.type!==t.type))),this.stack.push(t)}consume(t){const o=this.stack.find((o=>o.type===t));return o&&(this.stack=this.stack.filter((t=>t!==o))),o}}function ko(t){for(var o=arguments.length,r=Array(o>1?o-1:0),e=1;e<o;e++)r[e-1]=arguments[e];throw Error("[Immer] minified error nr: "+t+(r.length?" "+r.map((function(t){return"'"+t+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Ko(t){return!!t&&!!t[Or]}function Ao(t){var o;return!!t&&(function(t){if(!t||"object"!=typeof t)return!1;var o=Object.getPrototypeOf(t);if(null===o)return!0;var r=Object.hasOwnProperty.call(o,"constructor")&&o.constructor;return r===Object||"function"==typeof r&&Function.toString.call(r)===vr}(t)||Array.isArray(t)||!!t[mr]||!!(null===(o=t.constructor)||void 0===o?void 0:o[mr])||Po(t)||Bo(t))}function jo(t,o,r){void 0===r&&(r=!1),0===Zo(t)?(r?Object.keys:Nr)(t).forEach((function(e){r&&"symbol"==typeof e||o(e,t[e],t)})):t.forEach((function(r,e){return o(e,r,t)}))}function Zo(t){var o=t[Or];return o?o.i>3?o.i-4:o.i:Array.isArray(t)?1:Po(t)?2:Bo(t)?3:0}function Mo(t,o){return 2===Zo(t)?t.has(o):Object.prototype.hasOwnProperty.call(t,o)}function Fo(t,o,r){var e=Zo(t);2===e?t.set(o,r):3===e?t.add(r):t[o]=r}function $o(t,o){return t===o?0!==t||1/t==1/o:t!=t&&o!=o}function Po(t){return pr&&t instanceof Map}function Bo(t){return yr&&t instanceof Set}function _o(t){return t.o||t.t}function Do(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var o=wr(t);delete o[Or];for(var r=Nr(o),e=0;e<r.length;e++){var n=r[e],i=o[n];!1===i.writable&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(o[n]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[n]})}return Object.create(Object.getPrototypeOf(t),o)}function zo(t,o){return void 0===o&&(o=!1),Go(t)||Ko(t)||!Ao(t)||(Zo(t)>1&&(t.set=t.add=t.clear=t.delete=To),Object.freeze(t),o&&jo(t,(function(t,o){return zo(o,!0)}),!0)),t}function To(){ko(2)}function Go(t){return null==t||"object"!=typeof t||Object.isFrozen(t)}function Ho(t){var o=Sr[t];return o||ko(18,t),o}function qo(){return ur}function Yo(t,o){o&&(Ho("Patches"),t.u=[],t.s=[],t.v=o)}function Vo(t){Jo(t),t.p.forEach(Qo),t.p=null}function Jo(t){t===ur&&(ur=t.l)}function Xo(t){return ur={p:[],l:ur,h:t,m:!0,_:0}}function Qo(t){var o=t[Or];0===o.i||1===o.i?o.j():o.g=!0}function tr(t,o){o._=o.p.length;var r=o.p[0],e=void 0!==t&&t!==r;return o.h.O||Ho("ES5").S(o,t,e),e?(r[Or].P&&(Vo(o),ko(4)),Ao(t)&&(t=or(o,t),o.l||er(o,t)),o.u&&Ho("Patches").M(r[Or].t,t,o.u,o.s)):t=or(o,r,[]),Vo(o),o.u&&o.v(o.u,o.s),t!==gr?t:void 0}function or(t,o,r){if(Go(o))return o;var e=o[Or];if(!e)return jo(o,(function(n,i){return rr(t,e,o,n,i,r)}),!0),o;if(e.A!==t)return o;if(!e.P)return er(t,e.t,!0),e.t;if(!e.I){e.I=!0,e.A._--;var n=4===e.i||5===e.i?e.o=Do(e.k):e.o,i=n,a=!1;3===e.i&&(i=new Set(n),n.clear(),a=!0),jo(i,(function(o,i){return rr(t,e,n,o,i,r,a)})),er(t,n,!1),r&&t.u&&Ho("Patches").N(e,r,t.u,t.s)}return e.o}function rr(t,o,r,e,n,i,a){if(Ko(n)){var c=or(t,n,i&&o&&3!==o.i&&!Mo(o.R,e)?i.concat(e):void 0);if(Fo(r,e,c),!Ko(c))return;t.m=!1}else a&&r.add(n);if(Ao(n)&&!Go(n)){if(!t.h.D&&t._<1)return;or(t,n),o&&o.A.l||er(t,n)}}function er(t,o,r){void 0===r&&(r=!1),!t.l&&t.h.D&&t.m&&zo(o,r)}function nr(t,o){var r=t[Or];return(r?_o(r):t)[o]}function ir(t,o){if(o in t)for(var r=Object.getPrototypeOf(t);r;){var e=Object.getOwnPropertyDescriptor(r,o);if(e)return e;r=Object.getPrototypeOf(r)}}function ar(t){t.P||(t.P=!0,t.l&&ar(t.l))}function cr(t){t.o||(t.o=Do(t.t))}function sr(t,o,r){var e=Po(o)?Ho("MapSet").F(o,r):Bo(o)?Ho("MapSet").T(o,r):t.O?function(t,o){var r=Array.isArray(t),e={i:r?1:0,A:o?o.A:qo(),P:!1,I:!1,R:{},l:o,t,k:null,o:null,j:null,C:!1},n=e,i=Cr;r&&(n=[e],i=Er);var a=Proxy.revocable(n,i),c=a.revoke,s=a.proxy;return e.k=s,e.j=c,s}(o,r):Ho("ES5").J(o,r);return(r?r.A:qo()).p.push(e),e}function lr(t){return Ko(t)||ko(22,t),function t(o){if(!Ao(o))return o;var r,e=o[Or],n=Zo(o);if(e){if(!e.P&&(e.i<4||!Ho("ES5").K(e)))return e.t;e.I=!0,r=fr(o,n),e.I=!1}else r=fr(o,n);return jo(r,(function(o,n){e&&function(t,o){return 2===Zo(t)?t.get(o):t[o]}(e.t,o)===n||Fo(r,o,t(n))})),3===n?new Set(r):r}(t)}function fr(t,o){switch(o){case 2:return new Map(t);case 3:return Array.from(t)}return Do(t)}var hr,ur,dr="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),pr="undefined"!=typeof Map,yr="undefined"!=typeof Set,br="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,gr=dr?Symbol.for("immer-nothing"):((hr={})["immer-nothing"]=!0,hr),mr=dr?Symbol.for("immer-draftable"):"__$immer_draftable",Or=dr?Symbol.for("immer-state"):"__$immer_state",vr=""+Object.prototype.constructor,Nr="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,wr=Object.getOwnPropertyDescriptors||function(t){var o={};return Nr(t).forEach((function(r){o[r]=Object.getOwnPropertyDescriptor(t,r)})),o},Sr={},Cr={get:function(t,o){if(o===Or)return t;var r=_o(t);if(!Mo(r,o))return function(t,o,r){var e,n=ir(o,r);return n?"value"in n?n.value:null===(e=n.get)||void 0===e?void 0:e.call(t.k):void 0}(t,r,o);var e=r[o];return t.I||!Ao(e)?e:e===nr(t.t,o)?(cr(t),t.o[o]=sr(t.A.h,e,t)):e},has:function(t,o){return o in _o(t)},ownKeys:function(t){return Reflect.ownKeys(_o(t))},set:function(t,o,r){var e=ir(_o(t),o);if(null==e?void 0:e.set)return e.set.call(t.k,r),!0;if(!t.P){var n=nr(_o(t),o),i=null==n?void 0:n[Or];if(i&&i.t===r)return t.o[o]=r,t.R[o]=!1,!0;if($o(r,n)&&(void 0!==r||Mo(t.t,o)))return!0;cr(t),ar(t)}return t.o[o]===r&&(void 0!==r||o in t.o)||Number.isNaN(r)&&Number.isNaN(t.o[o])||(t.o[o]=r,t.R[o]=!0),!0},deleteProperty:function(t,o){return void 0!==nr(t.t,o)||o in t.t?(t.R[o]=!1,cr(t),ar(t)):delete t.R[o],t.o&&delete t.o[o],!0},getOwnPropertyDescriptor:function(t,o){var r=_o(t),e=Reflect.getOwnPropertyDescriptor(r,o);return e?{writable:!0,configurable:1!==t.i||"length"!==o,enumerable:e.enumerable,value:r[o]}:e},defineProperty:function(){ko(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){ko(12)}},Er={};jo(Cr,(function(t,o){Er[t]=function(){return arguments[0]=arguments[0][0],o.apply(this,arguments)}})),Er.deleteProperty=function(t,o){return Er.set.call(this,t,o,void 0)},Er.set=function(t,o,r){return Cr.set.call(this,t[0],o,r,t[0])};var xr=function(){function t(t){var o=this;this.O=br,this.D=!0,this.produce=function(t,r,e){if("function"==typeof t&&"function"!=typeof r){var n=r;r=t;var i=o;return function(t){var o=this;void 0===t&&(t=n);for(var e=arguments.length,a=Array(e>1?e-1:0),c=1;c<e;c++)a[c-1]=arguments[c];return i.produce(t,(function(t){var e;return(e=r).call.apply(e,[o,t].concat(a))}))}}var a;if("function"!=typeof r&&ko(6),void 0!==e&&"function"!=typeof e&&ko(7),Ao(t)){var c=Xo(o),s=sr(o,t,void 0),l=!0;try{a=r(s),l=!1}finally{l?Vo(c):Jo(c)}return"undefined"!=typeof Promise&&a instanceof Promise?a.then((function(t){return Yo(c,e),tr(t,c)}),(function(t){throw Vo(c),t})):(Yo(c,e),tr(a,c))}if(!t||"object"!=typeof t){if(void 0===(a=r(t))&&(a=t),a===gr&&(a=void 0),o.D&&zo(a,!0),e){var f=[],h=[];Ho("Patches").M(t,a,f,h),e(f,h)}return a}ko(21,t)},this.produceWithPatches=function(t,r){if("function"==typeof t)return function(r){for(var e=arguments.length,n=Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];return o.produceWithPatches(r,(function(o){return t.apply(void 0,[o].concat(n))}))};var e,n,i=o.produce(t,r,(function(t,o){e=t,n=o}));return"undefined"!=typeof Promise&&i instanceof Promise?i.then((function(t){return[t,e,n]})):[i,e,n]},"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 o=t.prototype;return o.createDraft=function(t){Ao(t)||ko(8),Ko(t)&&(t=lr(t));var o=Xo(this),r=sr(this,t,void 0);return r[Or].C=!0,Jo(o),r},o.finishDraft=function(t,o){var r=(t&&t[Or]).A;return Yo(r,o),tr(void 0,r)},o.setAutoFreeze=function(t){this.D=t},o.setUseProxies=function(t){t&&!br&&ko(20),this.O=t},o.applyPatches=function(t,o){var r;for(r=o.length-1;r>=0;r--){var e=o[r];if(0===e.path.length&&"replace"===e.op){t=e.value;break}}r>-1&&(o=o.slice(r+1));var n=Ho("Patches").$;return Ko(t)?n(t,o):this.produce(t,(function(t){return n(t,o)}))},t}(),Rr=new xr,Ur=Rr.produce;function Ir(t){return Ir="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},Ir(t)}function Lr(t){var o=function(t,o){if("object"!==Ir(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var e=r.call(t,o||"default");if("object"!==Ir(e))return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===o?String:Number)(t)}(t,"string");return"symbol"===Ir(o)?o:String(o)}function Wr(t,o,r){return(o=Lr(o))in t?Object.defineProperty(t,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[o]=r,t}function kr(t,o){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var e=Object.getOwnPropertySymbols(t);o&&(e=e.filter((function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable}))),r.push.apply(r,e)}return r}function Kr(t){for(var o=1;o<arguments.length;o++){var r=null!=arguments[o]?arguments[o]:{};o%2?kr(Object(r),!0).forEach((function(o){Wr(t,o,r[o])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):kr(Object(r)).forEach((function(o){Object.defineProperty(t,o,Object.getOwnPropertyDescriptor(r,o))}))}return t}function Ar(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. "}Rr.produceWithPatches.bind(Rr),Rr.setAutoFreeze.bind(Rr),Rr.setUseProxies.bind(Rr),Rr.applyPatches.bind(Rr),Rr.createDraft.bind(Rr),Rr.finishDraft.bind(Rr);var jr="function"==typeof Symbol&&Symbol.observable||"@@observable",Zr=function(){return Math.random().toString(36).substring(7).split("").join(".")},Mr={INIT:"@@redux/INIT"+Zr(),REPLACE:"@@redux/REPLACE"+Zr(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Zr()}};function Fr(t,o,r){var e;if("function"==typeof o&&"function"==typeof r||"function"==typeof r&&"function"==typeof arguments[3])throw new Error(Ar(0));if("function"==typeof o&&void 0===r&&(r=o,o=void 0),void 0!==r){if("function"!=typeof r)throw new Error(Ar(1));return r(Fr)(t,o)}if("function"!=typeof t)throw new Error(Ar(2));var n=t,i=o,a=[],c=a,s=!1;function l(){c===a&&(c=a.slice())}function f(){if(s)throw new Error(Ar(3));return i}function h(t){if("function"!=typeof t)throw new Error(Ar(4));if(s)throw new Error(Ar(5));var o=!0;return l(),c.push(t),function(){if(o){if(s)throw new Error(Ar(6));o=!1,l();var r=c.indexOf(t);c.splice(r,1),a=null}}}function u(t){if(!function(t){if("object"!=typeof t||null===t)return!1;for(var o=t;null!==Object.getPrototypeOf(o);)o=Object.getPrototypeOf(o);return Object.getPrototypeOf(t)===o}(t))throw new Error(Ar(7));if(void 0===t.type)throw new Error(Ar(8));if(s)throw new Error(Ar(9));try{s=!0,i=n(i,t)}finally{s=!1}for(var o=a=c,r=0;r<o.length;r++){(0,o[r])()}return t}return u({type:Mr.INIT}),(e={dispatch:u,subscribe:h,getState:f,replaceReducer:function(t){if("function"!=typeof t)throw new Error(Ar(10));n=t,u({type:Mr.REPLACE})}})[jr]=function(){var t,o=h;return(t={subscribe:function(t){if("object"!=typeof t||null===t)throw new Error(Ar(11));function r(){t.next&&t.next(f())}return r(),{unsubscribe:o(r)}}})[jr]=function(){return this},t},e}function $r(t){for(var o=Object.keys(t),r={},e=0;e<o.length;e++){var n=o[e];"function"==typeof t[n]&&(r[n]=t[n])}var i,a=Object.keys(r);try{!function(t){Object.keys(t).forEach((function(o){var r=t[o];if(void 0===r(void 0,{type:Mr.INIT}))throw new Error(Ar(12));if(void 0===r(void 0,{type:Mr.PROBE_UNKNOWN_ACTION()}))throw new Error(Ar(13))}))}(r)}catch(t){i=t}return function(t,o){if(void 0===t&&(t={}),i)throw i;for(var e=!1,n={},c=0;c<a.length;c++){var s=a[c],l=r[s],f=t[s],h=l(f,o);if(void 0===h)throw o&&o.type,new Error(Ar(14));n[s]=h,e=e||h!==f}return(e=e||a.length!==Object.keys(t).length)?n:t}}function Pr(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return 0===o.length?function(t){return t}:1===o.length?o[0]:o.reduce((function(t,o){return function(){return t(o.apply(void 0,arguments))}}))}function Br(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return function(t){return function(){var r=t.apply(void 0,arguments),e=function(){throw new Error(Ar(15))},n={getState:r.getState,dispatch:function(){return e.apply(void 0,arguments)}},i=o.map((function(t){return t(n)}));return e=Pr.apply(void 0,i)(r.dispatch),Kr(Kr({},r),{},{dispatch:e})}}}function _r(t){return function(o){var r=o.dispatch,e=o.getState;return function(o){return function(n){return"function"==typeof n?n(r,e,t):o(n)}}}}var Dr=_r();Dr.withExtraArgument=_r;var zr,Tr=Dr,Gr=(zr=function(t,o){return zr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,o){t.__proto__=o}||function(t,o){for(var r in o)Object.prototype.hasOwnProperty.call(o,r)&&(t[r]=o[r])},zr(t,o)},function(t,o){if("function"!=typeof o&&null!==o)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");function r(){this.constructor=t}zr(t,o),t.prototype=null===o?Object.create(o):(r.prototype=o.prototype,new r)}),Hr=function(t,o){var r,e,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function c(i){return function(c){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,e&&(n=2&i[0]?e.return:i[0]?e.throw||((n=e.return)&&n.call(e),0):e.next)&&!(n=n.call(e,i[1])).done)return n;switch(e=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,e=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=a.trys,(n=n.length>0&&n[n.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=o.call(t,a)}catch(t){i=[6,t],e=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,c])}}},qr=function(t,o){for(var r=0,e=o.length,n=t.length;r<e;r++,n++)t[n]=o[r];return t},Yr=Object.defineProperty,Vr=Object.defineProperties,Jr=Object.getOwnPropertyDescriptors,Xr=Object.getOwnPropertySymbols,Qr=Object.prototype.hasOwnProperty,te=Object.prototype.propertyIsEnumerable,oe=function(t,o,r){return o in t?Yr(t,o,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[o]=r},re=function(t,o){for(var r in o||(o={}))Qr.call(o,r)&&oe(t,r,o[r]);if(Xr)for(var e=0,n=Xr(o);e<n.length;e++){r=n[e];te.call(o,r)&&oe(t,r,o[r])}return t},ee=function(t,o){return Vr(t,Jr(o))},ne="undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(0!==arguments.length)return"object"==typeof arguments[0]?Pr:Pr.apply(null,arguments)};var ie=function(t){function o(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var n=t.apply(this,r)||this;return Object.setPrototypeOf(n,o.prototype),n}return Gr(o,t),Object.defineProperty(o,Symbol.species,{get:function(){return o},enumerable:!1,configurable:!0}),o.prototype.concat=function(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];return t.prototype.concat.apply(this,o)},o.prototype.prepend=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return 1===t.length&&Array.isArray(t[0])?new(o.bind.apply(o,qr([void 0],t[0].concat(this)))):new(o.bind.apply(o,qr([void 0],t.concat(this))))},o}(Array),ae=function(t){function o(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var n=t.apply(this,r)||this;return Object.setPrototypeOf(n,o.prototype),n}return Gr(o,t),Object.defineProperty(o,Symbol.species,{get:function(){return o},enumerable:!1,configurable:!0}),o.prototype.concat=function(){for(var o=[],r=0;r<arguments.length;r++)o[r]=arguments[r];return t.prototype.concat.apply(this,o)},o.prototype.prepend=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return 1===t.length&&Array.isArray(t[0])?new(o.bind.apply(o,qr([void 0],t[0].concat(this)))):new(o.bind.apply(o,qr([void 0],t.concat(this))))},o}(Array);function ce(t){return Ao(t)?Ur(t,(function(){})):t}function se(){return function(t){return function(t){void 0===t&&(t={});var o=t.thunk,r=void 0===o||o;t.immutableCheck,t.serializableCheck;var e=new ie;r&&(!function(t){return"boolean"==typeof t}(r)?e.push(Tr.withExtraArgument(r.extraArgument)):e.push(Tr));return e}(t)}}function le(t){var o,r=se(),e=t||{},n=e.reducer,i=void 0===n?void 0:n,a=e.middleware,c=void 0===a?r():a,s=e.devTools,l=void 0===s||s,f=e.preloadedState,h=void 0===f?void 0:f,u=e.enhancers,d=void 0===u?void 0:u;if("function"==typeof i)o=i;else{if(!function(t){if("object"!=typeof t||null===t)return!1;var o=Object.getPrototypeOf(t);if(null===o)return!0;for(var r=o;null!==Object.getPrototypeOf(r);)r=Object.getPrototypeOf(r);return o===r}(i))throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');o=$r(i)}var p=c;"function"==typeof p&&(p=p(r));var y=Br.apply(void 0,p),b=Pr;l&&(b=ne(re({trace:!1},"object"==typeof l&&l)));var g=new ae(y),m=g;return Array.isArray(d)?m=qr([y],d):"function"==typeof d&&(m=d(g)),Fr(o,h,b.apply(void 0,m))}function fe(t,o){function r(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];if(o){var n=o.apply(void 0,r);if(!n)throw new Error("prepareAction did not return an object");return re(re({type:t,payload:n.payload},"meta"in n&&{meta:n.meta}),"error"in n&&{error:n.error})}return{type:t,payload:r[0]}}return r.toString=function(){return""+t},r.type=t,r.match=function(o){return o.type===t},r}function he(t){var o,r={},e=[],n={addCase:function(t,o){var e="string"==typeof t?t:t.type;if(e in r)throw new Error("addCase cannot be called with two reducers for the same action type");return r[e]=o,n},addMatcher:function(t,o){return e.push({matcher:t,reducer:o}),n},addDefaultCase:function(t){return o=t,n}};return t(n),[r,e,o]}function ue(t){var o=t.name;if(!o)throw new Error("`name` is a required option for createSlice");var r,e="function"==typeof t.initialState?t.initialState:ce(t.initialState),n=t.reducers||{},i=Object.keys(n),a={},c={},s={};function l(){var o="function"==typeof t.extraReducers?he(t.extraReducers):[t.extraReducers],r=o[0],n=void 0===r?{}:r,i=o[1],a=void 0===i?[]:i,s=o[2],l=void 0===s?void 0:s,f=re(re({},n),c);return function(t,o,r,e){void 0===r&&(r=[]);var n,i="function"==typeof o?he(o):[o,r,e],a=i[0],c=i[1],s=i[2];if(function(t){return"function"==typeof t}(t))n=function(){return ce(t())};else{var l=ce(t);n=function(){return l}}function f(t,o){void 0===t&&(t=n());var r=qr([a[o.type]],c.filter((function(t){return(0,t.matcher)(o)})).map((function(t){return t.reducer})));return 0===r.filter((function(t){return!!t})).length&&(r=[s]),r.reduce((function(t,r){if(r){var e;if(Ko(t))return void 0===(e=r(t,o))?t:e;if(Ao(t))return Ur(t,(function(t){return r(t,o)}));if(void 0===(e=r(t,o))){if(null===t)return t;throw Error("A case reducer on a non-draftable value must not return undefined")}return e}return t}),t)}return f.getInitialState=n,f}(e,(function(t){for(var o in f)t.addCase(o,f[o]);for(var r=0,e=a;r<e.length;r++){var n=e[r];t.addMatcher(n.matcher,n.reducer)}l&&t.addDefaultCase(l)}))}return i.forEach((function(t){var r,e,i=n[t],l=o+"/"+t;"reducer"in i?(r=i.reducer,e=i.prepare):r=i,a[t]=r,c[l]=r,s[t]=e?fe(l,e):fe(l)})),{name:o,reducer:function(t,o){return r||(r=l()),r(t,o)},actions:s,caseReducers:a,getInitialState:function(){return r||(r=l()),r.getInitialState()}}}var de=["name","message","stack","code"],pe=function(t,o){this.payload=t,this.meta=o},ye=function(t,o){this.payload=t,this.meta=o},be=function(t){if("object"==typeof t&&null!==t){for(var o={},r=0,e=de;r<e.length;r++){var n=e[r];"string"==typeof t[n]&&(o[n]=t[n])}return o}return{message:String(t)}};function ge(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}!function(){function t(t,o,r){var e=fe(t+"/fulfilled",(function(t,o,r,e){return{payload:t,meta:ee(re({},e||{}),{arg:r,requestId:o,requestStatus:"fulfilled"})}})),n=fe(t+"/pending",(function(t,o,r){return{payload:void 0,meta:ee(re({},r||{}),{arg:o,requestId:t,requestStatus:"pending"})}})),i=fe(t+"/rejected",(function(t,o,e,n,i){return{payload:n,error:(r&&r.serializeError||be)(t||"Rejected"),meta:ee(re({},i||{}),{arg:e,requestId:o,rejectedWithValue:!!n,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(c,s,l){var f,h=(null==r?void 0:r.idGenerator)?r.idGenerator(t):function(t){void 0===t&&(t=21);for(var o="",r=t;r--;)o+="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW"[64*Math.random()|0];return o}(),u=new a;function d(t){f=t,u.abort()}var p=function(){return a=this,p=null,y=function(){var a,p,y,b,g,m;return Hr(this,(function(O){switch(O.label){case 0:return O.trys.push([0,4,,5]),b=null==(a=null==r?void 0:r.condition)?void 0:a.call(r,t,{getState:s,extra:l}),null===(v=b)||"object"!=typeof v||"function"!=typeof v.then?[3,2]:[4,b];case 1:b=O.sent(),O.label=2;case 2:if(!1===b||u.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return g=new Promise((function(t,o){return u.signal.addEventListener("abort",(function(){return o({name:"AbortError",message:f||"Aborted"})}))})),c(n(h,t,null==(p=null==r?void 0:r.getPendingMeta)?void 0:p.call(r,{requestId:h,arg:t},{getState:s,extra:l}))),[4,Promise.race([g,Promise.resolve(o(t,{dispatch:c,getState:s,extra:l,requestId:h,signal:u.signal,abort:d,rejectWithValue:function(t,o){return new pe(t,o)},fulfillWithValue:function(t,o){return new ye(t,o)}})).then((function(o){if(o instanceof pe)throw o;return o instanceof ye?e(o.payload,h,t,o.meta):e(o,h,t)}))])];case 3:return y=O.sent(),[3,5];case 4:return m=O.sent(),y=m instanceof pe?i(null,h,t,m.payload,m.meta):i(m,h,t),[3,5];case 5:return r&&!r.dispatchConditionRejection&&i.match(y)&&y.meta.condition||c(y),[2,y]}var v}))},new Promise((function(t,o){var r=function(t){try{n(y.next(t))}catch(t){o(t)}},e=function(t){try{n(y.throw(t))}catch(t){o(t)}},n=function(o){return o.done?t(o.value):Promise.resolve(o.value).then(r,e)};n((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(ge)}})}}),{pending:n,rejected:i,fulfilled:e,typePrefix:t})}t.withTypes=function(){return t}}();var me,Oe,ve="listenerMiddleware";fe(ve+"/add"),fe(ve+"/removeAll"),fe(ve+"/remove"),"function"==typeof queueMicrotask&&queueMicrotask.bind("undefined"!=typeof window?window:"undefined"!=typeof global?global:globalThis),function(){function t(t,o){var r=n[t];return r?r.enumerable=o:n[t]=r={configurable:!0,enumerable:o,get:function(){var o=this[Or];return Cr.get(o,t)},set:function(o){var r=this[Or];Cr.set(r,t,o)}},r}function o(t){for(var o=t.length-1;o>=0;o--){var n=t[o][Or];if(!n.P)switch(n.i){case 5:e(n)&&ar(n);break;case 4:r(n)&&ar(n)}}}function r(t){for(var o=t.t,r=t.k,e=Nr(r),n=e.length-1;n>=0;n--){var i=e[n];if(i!==Or){var a=o[i];if(void 0===a&&!Mo(o,i))return!0;var c=r[i],s=c&&c[Or];if(s?s.t!==a:!$o(c,a))return!0}}var l=!!o[Or];return e.length!==Nr(o).length+(l?0:1)}function e(t){var o=t.k;if(o.length!==t.t.length)return!0;var r=Object.getOwnPropertyDescriptor(o,o.length-1);if(r&&!r.get)return!0;for(var e=0;e<o.length;e++)if(!o.hasOwnProperty(e))return!0;return!1}var n={};!function(t,o){Sr[t]||(Sr[t]=o)}("ES5",{J:function(o,r){var e=Array.isArray(o),n=function(o,r){if(o){for(var e=Array(r.length),n=0;n<r.length;n++)Object.defineProperty(e,""+n,t(n,!0));return e}var i=wr(r);delete i[Or];for(var a=Nr(i),c=0;c<a.length;c++){var s=a[c];i[s]=t(s,o||!!i[s].enumerable)}return Object.create(Object.getPrototypeOf(r),i)}(e,o),i={i:e?5:4,A:r?r.A:qo(),P:!1,I:!1,R:{},l:r,t:o,k:n,o:null,g:!1,C:!1};return Object.defineProperty(n,Or,{value:i,writable:!0}),n},S:function(t,r,n){n?Ko(r)&&r[Or].A===t&&o(t.p):(t.u&&function t(o){if(o&&"object"==typeof o){var r=o[Or];if(r){var n=r.t,i=r.k,a=r.R,c=r.i;if(4===c)jo(i,(function(o){o!==Or&&(void 0!==n[o]||Mo(n,o)?a[o]||t(i[o]):(a[o]=!0,ar(r)))})),jo(n,(function(t){void 0!==i[t]||Mo(i,t)||(a[t]=!1,ar(r))}));else if(5===c){if(e(r)&&(ar(r),a.length=!0),i.length<n.length)for(var s=i.length;s<n.length;s++)a[s]=!1;else for(var l=n.length;l<i.length;l++)a[l]=!0;for(var f=Math.min(i.length,n.length),h=0;h<f;h++)i.hasOwnProperty(h)||(a[h]=!0),void 0===a[h]&&t(i[h])}}}}(t.p[0]),o(t.p))},K:function(t){return 4===t.i?r(t):e(t)}})}(),window.ftReduxStores||(window.ftReduxStores={});class Ne{static get(t){var o;const r="string"==typeof t?t:t.name,e="string"==typeof t?void 0:t,n=window.ftReduxStores[r];if(function(t){var o;return null!==(o=null==t?void 0:t.isFtReduxStore)&&void 0!==o&&o}(n))return n;if(null==e)return;const i=ue({...e,reducers:null!==(o=e.reducers)&&void 0!==o?o:{}}),a=le({reducer:(t,o)=>{var r;switch(o.type){case"CLEAR_FT_REDUX_STORE":return i.getInitialState();case"DEFAULT_STATE_FIELDS_VALUES_SETTER":return{...t,...null!==(r=o.overwrites)&&void 0!==r?r:{}};default:return i.reducer(t,o)}}});return window.ftReduxStores[e.name]=new Ne(i,a)}constructor(t,o){this.reduxSlice=t,this.reduxStore=o,this.isFtReduxStore=!0,this.eventBus=document.createElement("event-bus"),this.commands=new Wo,this.actions=new Proxy(this.reduxSlice.actions,{get:(t,o,r)=>{const e=o,n=t[e];return n?(...t)=>{const o=n(...t);return this.reduxStore.dispatch(o),o}:t=>{this.setState({[e]: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===(Oe=null===(me=window.safari)||void 0===me?void 0:me.pushNotification)||void 0===Oe||Oe.toString());const we=bt`
102
+ `,Se="ft-app-info",Ce=Ne.get({name:Se,reducers:{setBaseUrl:(t,o)=>{t.baseUrl=o.payload},setApiIntegrationIdentifier:(t,o)=>{t.apiIntegrationIdentifier=o.payload},setUiLocale:(t,o)=>{t.uiLocale=o.payload},setAvailableUiLocales:(t,o)=>{t.availableUiLocales=o.payload},setEditorMode:(t,o)=>{t.editorMode=o.payload},setNoCustom:(t,o)=>{t.noCustom=o.payload},setNoCustomComponent:(t,o)=>{t.noCustomComponent=o.payload},setSession:(t,o)=>{t.session=o.payload}},initialState:{uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],editorMode:!1,noCustom:!1,noCustomComponent:!1}});class Ee{static build(t){const{baseUrl:o,apiIntegrationIdentifier:r}=Ce.getState(),e=null!=t?t:r;if(o&&e&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,e,!0)}static get(t){var o;return null!=t?Ee.build(t):null!==(o=Ee.API)&&void 0!==o?o:Ee.API=Ee.build()}static await(t){return new Promise((o=>{let r=Ee.get(t);if(r)o(r);else{const e=Ce.subscribe((()=>{r=Ee.get(t),r&&(e(),o(r))}))}}))}}var xe;const Re=Symbol("clearAfterUnitTest");class Ue{constructor(t){this.messageContextProvider=t,this.defaultMessages={},this.cache=new e,this.listeners={},this.currentUiLocale="",this[xe]=()=>{this.defaultMessages={},this.cache=new e,this.listeners={}},this.currentUiLocale=Ce.getState().uiLocale,Ce.subscribe((()=>this.clearWhenUiLocaleChanges()))}clearWhenUiLocaleChanges(){const{uiLocale:t}=Ce.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){const o=t.name.toLowerCase();this.cache.setFinal(o,t),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,o){var r;if(t=t.toLowerCase(),Object.keys(o).length>0){const e={...null!==(r=this.defaultMessages[t])&&void 0!==r?r:{},...o};I(this.defaultMessages[t],e)||(this.defaultMessages[t]=e,await this.notify(t))}await this.fetchContext(t)}resolveMessage(t,o,...r){var e,n,i;t=t.toLowerCase(),this.fetchContext(t);const a=null!==(n=null===(e=this.cache.getNow(t))||void 0===e?void 0:e.messages)&&void 0!==n?n:{};return new Lo(null!==(i=this.defaultMessages[t])&&void 0!==i?i:{},a).resolve(o,...r)}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,o){var r;return t=t.toLowerCase(),this.listeners[t]=null!==(r=this.listeners[t])&&void 0!==r?r:new Set,this.listeners[t].add(o),()=>{var r;return null===(r=this.listeners[t])||void 0===r?void 0:r.delete(o)}}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=>{return(o=0,new Promise((t=>setTimeout(t,o)))).then((()=>t())).catch((()=>null));var o})))}}xe=Re,null==window.FluidTopicsI18nService&&(window.FluidTopicsI18nService=new Ue((async(t,o)=>(await Ee.await()).getFluidTopicsMessageContext(t,o)))),null==window.FluidTopicsCustomI18nService&&(window.FluidTopicsCustomI18nService=new Ue((async(t,o)=>(await Ee.await()).getCustomMessageContext(t,o))));const Ie=window.FluidTopicsI18nService,Le=window.FluidTopicsCustomI18nService;var We=function(t,o,r,e){for(var n,i=arguments.length,a=i<3?o:null===e?e=Object.getOwnPropertyDescriptor(o,r):e,c=t.length-1;c>=0;c--)(n=t[c])&&(a=(i<3?n(a):i>3?n(o,r,a):n(o,r))||a);return i>3&&a&&Object.defineProperty(o,r,a),a};class ke extends Uo{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.availableUiLocales=[],this.editorMode=!1,this.noCustom=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.messageContexts=[],this.apiProvider=()=>Ee.get(),this.cache=new e,this.cleanSessionDebouncer=new U}render(){return Xt`
103
103
  <slot></slot>
104
- `}update(t){super.update(t),t.has("baseUrl")&&Se.actions.setBaseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&Se.actions.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&Se.actions.setUiLocale(this.uiLocale),t.has("noCustom")&&Se.actions.setNoCustom(this.noCustom),t.has("editorMode")&&Se.actions.setEditorMode(this.editorMode),t.has("noCustomComponent")&&Se.actions.setNoCustomComponent(this.noCustomComponent),t.has("session")&&Se.actions.setSession(this.session),t.has("availableUiLocales")&&Se.actions.setAvailableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>Ue.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){const t=this.apiProvider();!this.withManualResources&&t&&(null==this.session&&(this.session=await this.cache.get("session",(async()=>{const o=await t.getCurrentSession();return o.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),o.idleTimeoutInMillis),o}))),null==this.availableUiLocales&&(this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>t.getAvailableUiLocales()))))}}We.elementDefinitions={},We.styles=Ne,Le([R()],We.prototype,"baseUrl",void 0),Le([R()],We.prototype,"apiIntegrationIdentifier",void 0),Le([R()],We.prototype,"uiLocale",void 0),Le([L([])],We.prototype,"availableUiLocales",void 0),Le([R({type:Boolean})],We.prototype,"editorMode",void 0),Le([R({type:Boolean})],We.prototype,"noCustom",void 0),Le([R({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],We.prototype,"noCustomComponent",void 0),Le([R({type:Boolean})],We.prototype,"withManualResources",void 0),Le([L([])],We.prototype,"messageContexts",void 0),Le([L(void 0)],We.prototype,"session",void 0),Le([R({type:Object})],We.prototype,"apiProvider",void 0);class ke{async listMySearches(){var t;return(null===(t=Se.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await Ce.await()).listMySearches(Se.getState().session.profile.userId):[]}}const Ke=new e;class Ae{async listMyBookmarks(){return Ke.get("bookmarks",(async()=>(await Ce.await()).listMyBookmarks(Se.getState().session.profile.userId)))}clearCache(){Ke.clear("bookmarks")}}const je="ft-user-assets",Ze=ve.get({name:je,initialState:{savedSearches:void 0,bookmarks:void 0}});const Me=new class{constructor(){this.currentSession=Se.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new Ae,Se.subscribe((()=>this.reloadWhenUserSessionChanges()))}reloadWhenUserSessionChanges(){var t;const{session:o}=Se.getState();I(null===(t=this.currentSession)||void 0===t?void 0:t.profile,null==o?void 0:o.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){Ze.actions.savedSearches(void 0)}clearMyBookmarks(){Ze.actions.bookmarks(void 0)}async reloadMySearches(){const t=new ke,o=await t.listMySearches();Ze.actions.savedSearches(o)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){const o=(null===(t=this.currentSession)||void 0===t?void 0:t.sessionAuthenticated)?await this.bookmarksService.listMyBookmarks():void 0;Ze.actions.bookmarks(o)}}};var Fe;(Fe="ft-app-context",t=>{window.customElements.get(Fe)||window.customElements.define(Fe,t)})(We),t.FluidTopicsApiProvider=Ce,t.FtAppContext=We,t.FtAppContextCssVariables={},t.FtAppInfoStoreName=we,t.FtI18nServiceInternalClass=Re,t.FtUserAssetsStoreName=je,t.clearAfterUnitTest=xe,t.ftAppInfoStore=Se,t.ftCustomI18nService=Ie,t.ftI18nService=Ue,t.ftUserAssetsStore=Ze,t.styles=Ne,t.userAssetsActions=Me}({});
104
+ `}update(t){super.update(t),t.has("baseUrl")&&Ce.actions.setBaseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&Ce.actions.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&Ce.actions.setUiLocale(this.uiLocale),t.has("noCustom")&&Ce.actions.setNoCustom(this.noCustom),t.has("editorMode")&&Ce.actions.setEditorMode(this.editorMode),t.has("noCustomComponent")&&Ce.actions.setNoCustomComponent(this.noCustomComponent),t.has("session")&&Ce.actions.setSession(this.session),t.has("availableUiLocales")&&Ce.actions.setAvailableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>Ie.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){const t=this.apiProvider();!this.withManualResources&&t&&(null==this.session&&(this.session=await this.cache.get("session",(async()=>{const o=await t.getCurrentSession();return o.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),o.idleTimeoutInMillis),o}))),null==this.availableUiLocales&&(this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>t.getAvailableUiLocales()))))}}ke.elementDefinitions={},ke.styles=we,We([R()],ke.prototype,"baseUrl",void 0),We([R()],ke.prototype,"apiIntegrationIdentifier",void 0),We([R()],ke.prototype,"uiLocale",void 0),We([L([])],ke.prototype,"availableUiLocales",void 0),We([R({type:Boolean})],ke.prototype,"editorMode",void 0),We([R({type:Boolean})],ke.prototype,"noCustom",void 0),We([R({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],ke.prototype,"noCustomComponent",void 0),We([R({type:Boolean})],ke.prototype,"withManualResources",void 0),We([L([])],ke.prototype,"messageContexts",void 0),We([L(void 0)],ke.prototype,"session",void 0),We([R({type:Object})],ke.prototype,"apiProvider",void 0);class Ke{async listMySearches(){var t;return(null===(t=Ce.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await Ee.await()).listMySearches(Ce.getState().session.profile.userId):[]}}const Ae=new e;class je{async listMyBookmarks(){return Ae.get("bookmarks",(async()=>(await Ee.await()).listMyBookmarks(Ce.getState().session.profile.userId)))}clearCache(){Ae.clear("bookmarks")}}const Ze="ft-user-assets",Me=Ne.get({name:Ze,initialState:{savedSearches:void 0,bookmarks:void 0}});const Fe=new class{constructor(){this.currentSession=Ce.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new je,Ce.subscribe((()=>this.reloadWhenUserSessionChanges()))}reloadWhenUserSessionChanges(){var t;const{session:o}=Ce.getState();I(null===(t=this.currentSession)||void 0===t?void 0:t.profile,null==o?void 0:o.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks())}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){Me.actions.savedSearches(void 0)}clearMyBookmarks(){Me.actions.bookmarks(void 0)}async reloadMySearches(){const t=new Ke,o=await t.listMySearches();Me.actions.savedSearches(o)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){const o=(null===(t=this.currentSession)||void 0===t?void 0:t.sessionAuthenticated)?await this.bookmarksService.listMyBookmarks():void 0;Me.actions.bookmarks(o)}}};var $e;($e="ft-app-context",t=>{window.customElements.get($e)||window.customElements.define($e,t)})(ke),t.FluidTopicsApiProvider=Ee,t.FtAppContext=ke,t.FtAppContextCssVariables={},t.FtAppInfoStoreName=Se,t.FtI18nServiceInternalClass=Ue,t.FtUserAssetsStoreName=Ze,t.clearAfterUnitTest=Re,t.ftAppInfoStore=Ce,t.ftCustomI18nService=Le,t.ftI18nService=Ie,t.ftUserAssetsStore=Me,t.styles=we,t.userAssetsActions=Fe}({});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluid-topics/ft-app-context",
3
- "version": "1.1.3",
3
+ "version": "1.1.4",
4
4
  "description": "Global application context for Fluid Topics integrations",
5
5
  "keywords": [
6
6
  "Lit"
@@ -19,11 +19,11 @@
19
19
  "url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
20
20
  },
21
21
  "dependencies": {
22
- "@fluid-topics/ft-wc-utils": "1.1.3",
22
+ "@fluid-topics/ft-wc-utils": "1.1.4",
23
23
  "lit": "3.1.0"
24
24
  },
25
25
  "devDependencies": {
26
26
  "@fluid-topics/public-api": "1.0.51"
27
27
  },
28
- "gitHead": "0d44a470e710f185c37e42ee87be4481a3bdf793"
28
+ "gitHead": "b13ddd3359734158be660854f9ffe5fc5880c430"
29
29
  }