@fluid-topics/ftds-chip 2.1.5 → 2.1.6

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.
@@ -1397,7 +1397,7 @@ If it declares any Font Awesome CSS pseudo-elements, they will not be rendered a
1397
1397
  position: relative;
1398
1398
  word-break: break-word;
1399
1399
  }
1400
- `;var yl=["top","right","bottom","left"],gl=["start","end"],ra=yl.reduce((e,t)=>e.concat(t,t+"-"+gl[0],t+"-"+gl[1]),[]),Pr=Math.min,at=Math.max,Dr=Math.round;var _e=e=>({x:e,y:e}),Iu={left:"right",right:"left",bottom:"top",top:"bottom"};function oa(e,t,o){return at(e,Pr(t,o))}function xo(e,t){return typeof e=="function"?e(t):e}function or(e){return e.split("-")[0]}function it(e){return e.split("-")[1]}function na(e){return e==="x"?"y":"x"}function aa(e){return e==="y"?"height":"width"}function So(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function ia(e){return na(So(e))}function bl(e,t,o){o===void 0&&(o=!1);let n=it(e),a=ia(e),i=aa(a),s=a==="x"?n===(o?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=ta(s)),[s,ta(s)]}function vl(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}function ta(e){let t=or(e);return Iu[t]+e.slice(t.length)}function Tu(e){return{top:0,right:0,bottom:0,left:0,...e}}function xl(e){return typeof e!="number"?Tu(e):{top:e,right:e,bottom:e,left:e}}function Lt(e){let{x:t,y:o,width:n,height:a}=e;return{width:n,height:a,top:o,left:t,right:t+n,bottom:o+a,x:t,y:o}}function Sl(e,t,o){let{reference:n,floating:a}=e,i=So(t),s=ia(t),l=aa(s),u=or(t),p=i==="y",m=n.x+n.width/2-a.width/2,g=n.y+n.height/2-a.height/2,y=n[l]/2-a[l]/2,v;switch(u){case"top":v={x:m,y:n.y-a.height};break;case"bottom":v={x:m,y:n.y+n.height};break;case"right":v={x:n.x+n.width,y:g};break;case"left":v={x:n.x-a.width,y:g};break;default:v={x:n.x,y:n.y}}switch(it(t)){case"start":v[s]-=y*(o&&p?-1:1);break;case"end":v[s]+=y*(o&&p?-1:1);break}return v}async function Cl(e,t){var o;t===void 0&&(t={});let{x:n,y:a,platform:i,rects:s,elements:l,strategy:u}=e,{boundary:p="clippingAncestors",rootBoundary:m="viewport",elementContext:g="floating",altBoundary:y=!1,padding:v=0}=xo(t,e),x=xl(v),O=l[y?g==="floating"?"reference":"floating":g],A=Lt(await i.getClippingRect({element:(o=await(i.isElement==null?void 0:i.isElement(O)))==null||o?O:O.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(l.floating)),boundary:p,rootBoundary:m,strategy:u})),N=g==="floating"?{x:n,y:a,width:s.floating.width,height:s.floating.height}:s.reference,M=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l.floating)),z=await(i.isElement==null?void 0:i.isElement(M))?await(i.getScale==null?void 0:i.getScale(M))||{x:1,y:1}:{x:1,y:1},B=Lt(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:N,offsetParent:M,strategy:u}):N);return{top:(A.top-B.top+x.top)/z.y,bottom:(B.bottom-A.bottom+x.bottom)/z.y,left:(A.left-B.left+x.left)/z.x,right:(B.right-A.right+x.right)/z.x}}var Pu=50,El=async(e,t,o)=>{let{placement:n="bottom",strategy:a="absolute",middleware:i=[],platform:s}=o,l=s.detectOverflow?s:{...s,detectOverflow:Cl},u=await(s.isRTL==null?void 0:s.isRTL(t)),p=await s.getElementRects({reference:e,floating:t,strategy:a}),{x:m,y:g}=Sl(p,n,u),y=n,v=0,x={};for(let S=0;S<i.length;S++){let O=i[S];if(!O)continue;let{name:A,fn:N}=O,{x:M,y:z,data:B,reset:H}=await N({x:m,y:g,initialPlacement:n,placement:y,strategy:a,middlewareData:x,rects:p,platform:l,elements:{reference:e,floating:t}});m=M??m,g=z??g,x[A]={...x[A],...B},H&&v<Pu&&(v++,typeof H=="object"&&(H.placement&&(y=H.placement),H.rects&&(p=H.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:a}):H.rects),{x:m,y:g}=Sl(p,y,u)),S=-1)}return{x:m,y:g,placement:y,strategy:a,middlewareData:x}};function Du(e,t,o){return(e?[...o.filter(a=>it(a)===e),...o.filter(a=>it(a)!==e)]:o.filter(a=>or(a)===a)).filter(a=>e?it(a)===e||(t?vl(a)!==a:!1):!0)}var Ll=function(e){return e===void 0&&(e={}),{name:"autoPlacement",options:e,async fn(t){var o,n,a;let{rects:i,middlewareData:s,placement:l,platform:u,elements:p}=t,{crossAxis:m=!1,alignment:g,allowedPlacements:y=ra,autoAlignment:v=!0,...x}=xo(e,t),S=g!==void 0||y===ra?Du(g||null,v,y):y,O=await u.detectOverflow(t,x),A=((o=s.autoPlacement)==null?void 0:o.index)||0,N=S[A];if(N==null)return{};let M=bl(N,i,await(u.isRTL==null?void 0:u.isRTL(p.floating)));if(l!==N)return{reset:{placement:S[0]}};let z=[O[or(N)],O[M[0]],O[M[1]]],B=[...((n=s.autoPlacement)==null?void 0:n.overflows)||[],{placement:N,overflows:z}],H=S[A+1];if(H)return{data:{index:A+1,overflows:B},reset:{placement:H}};let Ie=B.map(le=>{let me=it(le.placement);return[le.placement,me&&m?le.overflows.slice(0,2).reduce((de,gt)=>de+gt,0):le.overflows[0],le.overflows]}).sort((le,me)=>le[1]-me[1]),Te=((a=Ie.filter(le=>le[2].slice(0,it(le[0])?2:3).every(me=>me<=0))[0])==null?void 0:a[0])||Ie[0][0];return Te!==l?{data:{index:A+1,overflows:B},reset:{placement:Te}}:{}}}};var Al=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:o,y:n,placement:a,platform:i}=t,{mainAxis:s=!0,crossAxis:l=!1,limiter:u={fn:A=>{let{x:N,y:M}=A;return{x:N,y:M}}},...p}=xo(e,t),m={x:o,y:n},g=await i.detectOverflow(t,p),y=So(or(a)),v=na(y),x=m[v],S=m[y];if(s){let A=v==="y"?"top":"left",N=v==="y"?"bottom":"right",M=x+g[A],z=x-g[N];x=oa(M,x,z)}if(l){let A=y==="y"?"top":"left",N=y==="y"?"bottom":"right",M=S+g[A],z=S-g[N];S=oa(M,S,z)}let O=u.fn({...t,[v]:x,[y]:S});return{...O,data:{x:O.x-o,y:O.y-n,enabled:{[v]:s,[y]:l}}}}}};function Eo(){return typeof window<"u"}function Ot(e){return Rl(e)?(e.nodeName||"").toLowerCase():"#document"}function se(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ue(e){var t;return(t=(Rl(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Rl(e){return Eo()?e instanceof Node||e instanceof se(e).Node:!1}function be(e){return Eo()?e instanceof Element||e instanceof se(e).Element:!1}function Be(e){return Eo()?e instanceof HTMLElement||e instanceof se(e).HTMLElement:!1}function Ol(e){return!Eo()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof se(e).ShadowRoot}function nr(e){let{overflow:t,overflowX:o,overflowY:n,display:a}=ve(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+o)&&a!=="inline"&&a!=="contents"}function wl(e){return/^(table|td|th)$/.test(Ot(e))}function Ur(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var Uu=/transform|translate|scale|rotate|perspective|filter/,Bu=/paint|layout|strict|content/,At=e=>!!e&&e!=="none",sa;function ar(e){let t=be(e)?ve(e):e;return At(t.transform)||At(t.translate)||At(t.scale)||At(t.rotate)||At(t.perspective)||!Lo()&&(At(t.backdropFilter)||At(t.filter))||Uu.test(t.willChange||"")||Bu.test(t.contain||"")}function Nl(e){let t=qe(e);for(;Be(t)&&!Rt(t);){if(ar(t))return t;if(Ur(t))return null;t=qe(t)}return null}function Lo(){return sa==null&&(sa=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),sa}function Rt(e){return/^(html|body|#document)$/.test(Ot(e))}function ve(e){return se(e).getComputedStyle(e)}function Br(e){return be(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function qe(e){if(Ot(e)==="html")return e;let t=e.assignedSlot||e.parentNode||Ol(e)&&e.host||Ue(e);return Ol(t)?t.host:t}function _l(e){let t=qe(e);return Rt(t)?e.ownerDocument?e.ownerDocument.body:e.body:Be(t)&&nr(t)?t:_l(t)}function Co(e,t,o){var n;t===void 0&&(t=[]),o===void 0&&(o=!0);let a=_l(e),i=a===((n=e.ownerDocument)==null?void 0:n.body),s=se(a);if(i){let l=Ao(s);return t.concat(s,s.visualViewport||[],nr(a)?a:[],l&&o?Co(l):[])}else return t.concat(a,Co(a,[],o))}function Ao(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Il(e){let t=ve(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,a=Be(e),i=a?e.offsetWidth:o,s=a?e.offsetHeight:n,l=Dr(o)!==i||Dr(n)!==s;return l&&(o=i,n=s),{width:o,height:n,$:l}}function Tl(e){return be(e)?e:e.contextElement}function ir(e){let t=Tl(e);if(!Be(t))return _e(1);let o=t.getBoundingClientRect(),{width:n,height:a,$:i}=Il(t),s=(i?Dr(o.width):o.width)/n,l=(i?Dr(o.height):o.height)/a;return(!s||!Number.isFinite(s))&&(s=1),(!l||!Number.isFinite(l))&&(l=1),{x:s,y:l}}var Fu=_e(0);function Pl(e){let t=se(e);return!Lo()||!t.visualViewport?Fu:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Gu(e,t,o){return t===void 0&&(t=!1),!o||t&&o!==se(e)?!1:t}function Fr(e,t,o,n){t===void 0&&(t=!1),o===void 0&&(o=!1);let a=e.getBoundingClientRect(),i=Tl(e),s=_e(1);t&&(n?be(n)&&(s=ir(n)):s=ir(e));let l=Gu(i,o,n)?Pl(i):_e(0),u=(a.left+l.x)/s.x,p=(a.top+l.y)/s.y,m=a.width/s.x,g=a.height/s.y;if(i){let y=se(i),v=n&&be(n)?se(n):n,x=y,S=Ao(x);for(;S&&n&&v!==x;){let O=ir(S),A=S.getBoundingClientRect(),N=ve(S),M=A.left+(S.clientLeft+parseFloat(N.paddingLeft))*O.x,z=A.top+(S.clientTop+parseFloat(N.paddingTop))*O.y;u*=O.x,p*=O.y,m*=O.x,g*=O.y,u+=M,p+=z,x=se(S),S=Ao(x)}}return Lt({width:m,height:g,x:u,y:p})}function Oo(e,t){let o=Br(e).scrollLeft;return t?t.left+o:Fr(Ue(e)).left+o}function Dl(e,t){let o=e.getBoundingClientRect(),n=o.left+t.scrollLeft-Oo(e,o),a=o.top+t.scrollTop;return{x:n,y:a}}function Hu(e){let{elements:t,rect:o,offsetParent:n,strategy:a}=e,i=a==="fixed",s=Ue(n),l=t?Ur(t.floating):!1;if(n===s||l&&i)return o;let u={scrollLeft:0,scrollTop:0},p=_e(1),m=_e(0),g=Be(n);if((g||!g&&!i)&&((Ot(n)!=="body"||nr(s))&&(u=Br(n)),g)){let v=Fr(n);p=ir(n),m.x=v.x+n.clientLeft,m.y=v.y+n.clientTop}let y=s&&!g&&!i?Dl(s,u):_e(0);return{width:o.width*p.x,height:o.height*p.y,x:o.x*p.x-u.scrollLeft*p.x+m.x+y.x,y:o.y*p.y-u.scrollTop*p.y+m.y+y.y}}function $u(e){return Array.from(e.getClientRects())}function Wu(e){let t=Ue(e),o=Br(e),n=e.ownerDocument.body,a=at(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),i=at(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight),s=-o.scrollLeft+Oo(e),l=-o.scrollTop;return ve(n).direction==="rtl"&&(s+=at(t.clientWidth,n.clientWidth)-a),{width:a,height:i,x:s,y:l}}var Ml=25;function ju(e,t){let o=se(e),n=Ue(e),a=o.visualViewport,i=n.clientWidth,s=n.clientHeight,l=0,u=0;if(a){i=a.width,s=a.height;let m=Lo();(!m||m&&t==="fixed")&&(l=a.offsetLeft,u=a.offsetTop)}let p=Oo(n);if(p<=0){let m=n.ownerDocument,g=m.body,y=getComputedStyle(g),v=m.compatMode==="CSS1Compat"&&parseFloat(y.marginLeft)+parseFloat(y.marginRight)||0,x=Math.abs(n.clientWidth-g.clientWidth-v);x<=Ml&&(i-=x)}else p<=Ml&&(i+=p);return{width:i,height:s,x:l,y:u}}function Vu(e,t){let o=Fr(e,!0,t==="fixed"),n=o.top+e.clientTop,a=o.left+e.clientLeft,i=Be(e)?ir(e):_e(1),s=e.clientWidth*i.x,l=e.clientHeight*i.y,u=a*i.x,p=n*i.y;return{width:s,height:l,x:u,y:p}}function kl(e,t,o){let n;if(t==="viewport")n=ju(e,o);else if(t==="document")n=Wu(Ue(e));else if(be(t))n=Vu(t,o);else{let a=Pl(e);n={x:t.x-a.x,y:t.y-a.y,width:t.width,height:t.height}}return Lt(n)}function Ul(e,t){let o=qe(e);return o===t||!be(o)||Rt(o)?!1:ve(o).position==="fixed"||Ul(o,t)}function Ku(e,t){let o=t.get(e);if(o)return o;let n=Co(e,[],!1).filter(l=>be(l)&&Ot(l)!=="body"),a=null,i=ve(e).position==="fixed",s=i?qe(e):e;for(;be(s)&&!Rt(s);){let l=ve(s),u=ar(s);!u&&l.position==="fixed"&&(a=null),(i?!u&&!a:!u&&l.position==="static"&&!!a&&(a.position==="absolute"||a.position==="fixed")||nr(s)&&!u&&Ul(e,s))?n=n.filter(m=>m!==s):a=l,s=qe(s)}return t.set(e,n),n}function Zu(e){let{element:t,boundary:o,rootBoundary:n,strategy:a}=e,s=[...o==="clippingAncestors"?Ur(t)?[]:Ku(t,this._c):[].concat(o),n],l=kl(t,s[0],a),u=l.top,p=l.right,m=l.bottom,g=l.left;for(let y=1;y<s.length;y++){let v=kl(t,s[y],a);u=at(v.top,u),p=Pr(v.right,p),m=Pr(v.bottom,m),g=at(v.left,g)}return{width:p-g,height:m-u,x:g,y:u}}function qu(e){let{width:t,height:o}=Il(e);return{width:t,height:o}}function Yu(e,t,o){let n=Be(t),a=Ue(t),i=o==="fixed",s=Fr(e,!0,i,t),l={scrollLeft:0,scrollTop:0},u=_e(0);function p(){u.x=Oo(a)}if(n||!n&&!i)if((Ot(t)!=="body"||nr(a))&&(l=Br(t)),n){let v=Fr(t,!0,i,t);u.x=v.x+t.clientLeft,u.y=v.y+t.clientTop}else a&&p();i&&!n&&a&&p();let m=a&&!n&&!i?Dl(a,l):_e(0),g=s.left+l.scrollLeft-u.x-m.x,y=s.top+l.scrollTop-u.y-m.y;return{x:g,y,width:s.width,height:s.height}}function ca(e){return ve(e).position==="static"}function zl(e,t){if(!Be(e)||ve(e).position==="fixed")return null;if(t)return t(e);let o=e.offsetParent;return Ue(e)===o&&(o=o.ownerDocument.body),o}function Bl(e,t){let o=se(e);if(Ur(e))return o;if(!Be(e)){let a=qe(e);for(;a&&!Rt(a);){if(be(a)&&!ca(a))return a;a=qe(a)}return o}let n=zl(e,t);for(;n&&wl(n)&&ca(n);)n=zl(n,t);return n&&Rt(n)&&ca(n)&&!ar(n)?o:n||Nl(e)||o}var Xu=async function(e){let t=this.getOffsetParent||Bl,o=this.getDimensions,n=await o(e.floating);return{reference:Yu(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function Qu(e){return ve(e).direction==="rtl"}var Ro={convertOffsetParentRelativeRectToViewportRelativeRect:Hu,getDocumentElement:Ue,getClippingRect:Zu,getOffsetParent:Bl,getElementRects:Xu,getClientRects:$u,getDimensions:qu,getScale:ir,isElement:be,isRTL:Qu};var Fl=Ll,Gl=Al;var Hl=(e,t,o)=>{let n=new Map,a={platform:Ro,...o},i={...a.platform,_c:n};return El(e,t,{...a,platform:i})};function $l(e){return Ju(e)}function la(e){return e.assignedSlot?e.assignedSlot:e.parentNode instanceof ShadowRoot?e.parentNode.host:e.parentNode}function Ju(e){for(let t=e;t;t=la(t))if(t instanceof Element&&getComputedStyle(t).display==="none")return null;for(let t=la(e);t;t=la(t)){if(!(t instanceof Element))continue;let o=getComputedStyle(t);if(o.display!=="contents"&&(o.position!=="static"||ar(o)||t.tagName==="BODY"))return t}return null}async function Wl(e,t,o){let n;return typeof o=="object"?n=o:n={placement:o},Hl(e,t,{strategy:n.strategy,platform:{...Ro,getOffsetParent:a=>Ro.getOffsetParent(a,$l)},middleware:[Gl({crossAxis:!0}),Fl({allowedPlacements:[n.placement]})]})}var br=L(P());var Ta=L(oe());var jl=L(oe(),1);var da=e=>t=>{window.customElements.get(e)||window.customElements.define(e,t)};function Vl(e,t){return(0,jl.property)({type:Object,converter:{fromAttribute:o=>{if(o==null)return Gr(e);try{return JSON.parse(o)}catch{return Gr(e)}},toAttribute:o=>JSON.stringify(o)},hasChanged:Hr,...t??{}})}function ef(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;let o,n;if(Array.isArray(e)){if(o=e.length,o!=t.length)return!1;for(n=o;n--!==0;)if(!wo(e[n],t[n]))return!1;return!0}if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(n of e.entries())if(!t.has(n[0]))return!1;for(n of e.entries())if(!wo(n[1],t.get(n[0])))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(n of e.entries())if(!t.has(n[0]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();let a=s=>Object.keys(s).filter(l=>s[l]!=null),i=a(e);if(o=i.length,o!==a(t).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[n]))return!1;for(n=o;n--!==0;){let s=i[n];if(!wo(e[s],t[s]))return!1}return!0}return e!==e&&t!==t||e==null&&t==null}function wo(e,t){try{return ef(e,t)}catch{return!1}}function Hr(e,t){return!wo(e,t)}function Gr(e){return typeof window.structuredClone=="function"?structuredClone(e):e!=null?JSON.parse(JSON.stringify(e)):e}function No(e,t){let o=n=>n[e]===!0;return n=>{if(o(n))return n;let a=t(n);return a[e]=!0,a}}var Kl=L(oe(),1);var ua=e=>{let t=e??{};return(o,n)=>{var a;let i={hasChanged:Hr,attribute:!1,...t};(0,Kl.property)(i)(o,n);let s=o.constructor;s.reduxProperties=new Map(s.reduxProperties),s.reduxProperties.set(n,{selector:(a=t.selector)!==null&&a!==void 0?a:(l=>l[n]),store:t.store})}};var _o=class{constructor(){this.queue=[]}add(t,o=!1){o&&this.clear(t.type),this.queue.push(t)}consume(t){let o=this.queue.find(n=>n.type===t);return o&&(this.queue=this.queue.filter(n=>n!==o)),o}clear(t){typeof t=="string"?this.queue=this.queue.filter(o=>o.type!==t):this.queue=this.queue.filter(o=>!t.test(o.type))}};var wt=L(oe(),1);var Mo=class{constructor(t=0){this.timeout=t,this.callbacks=[]}run(t,o){return this.callbacks=[t],this.debounce(o)}queue(t,o){return this.callbacks.push(t),this.debounce(o)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(t){return this.promise==null&&(this.promise=new Promise((o,n)=>{this.resolvePromise=o,this.rejectPromise=n})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),t??this.timeout),this.promise}async runCallbacks(){var t,o;let n=[...this.callbacks];this.callbacks=[];let a=(t=this.rejectPromise)!==null&&t!==void 0?t:(()=>null),i=(o=this.resolvePromise)!==null&&o!==void 0?o:(()=>null);this.clearPromise();for(let s of n)try{await s()}catch(l){a(l);return}i(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var ql=L(K(),1);var ko=globalThis,tf=ko.ShadowRoot&&(ko.ShadyCSS===void 0||ko.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype;var Zl=(e,t)=>{if(tf)e.adoptedStyleSheets=t.map((o=>o instanceof CSSStyleSheet?o:o.styleSheet));else for(let o of t){let n=document.createElement("style"),a=ko.litNonce;a!==void 0&&n.setAttribute("nonce",a),n.textContent=o.cssText,e.appendChild(n)}};var zo=class extends ql.LitElement{get scopedRegistryConstructor(){return this.constructor}createRenderRoot(){let t=this.scopedRegistryConstructor;t.elementDefinitions&&!t.registry&&(t.registry=new CustomElementRegistry,t.defineScopedElements(t.elementDefinitions));let o={...t.shadowRootOptions,customElements:t.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return Zl(n,t.elementStyles),n}static canDefineScopedElement(t){return!!this.registry&&!this.registry.get(t)}static defineScopedElements(t){Object.entries(t).forEach(([o,n])=>this.defineScopedElement(o,n))}static defineScopedElement(t,o){da(t)(o),this.canDefineScopedElement(t)&&this.registry.define(t,o)}canDefineScopedElement(t){return this.scopedRegistryConstructor.canDefineScopedElement(t)}defineScopedElements(t){this.scopedRegistryConstructor.defineScopedElements(t)}defineScopedElement(t,o){this.scopedRegistryConstructor.defineScopedElement(t,o)}};function Yl(e,t,...o){var n;let a=e.querySelector(t);for(let i of o)a=(n=a?.shadowRoot)===null||n===void 0?void 0:n.querySelector(i);return a}var cr=function(e,t,o,n){var a=arguments.length,i=a<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(e,t,o,n);else for(var l=e.length-1;l>=0;l--)(s=e[l])&&(i=(a<3?s(i):a>3?s(t,o,i):s(t,o))||i);return a>3&&i&&Object.defineProperty(t,o,i),i},e2,Xl=Symbol("constructorPrototype"),Ql=Symbol("constructorName"),t2=Symbol("exportpartsDebouncer"),Jl=Symbol("dynamicDependenciesLoaded"),sr=class e extends CustomEvent{constructor(){super(e.eventName,{bubbles:!0})}};sr.eventName="exportparts-updated";var Fe=class extends zo{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[e2]=new Mo(5),this.scheduleExportpartsUpdate=()=>{var t,o,n;(!((t=this.exportpartsPrefix)===null||t===void 0)&&t.trim()||(n=(o=this.exportpartsPrefixes)===null||o===void 0?void 0:o.length)!==null&&n!==void 0&&n)&&this[t2].run(()=>{var a,i;!((a=this.exportpartsPrefix)===null||a===void 0)&&a.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((i=this.exportpartsPrefixes)===null||i===void 0?void 0:i.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})},this[Ql]=this.constructor.name,this[Xl]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[Ql]&&Object.setPrototypeOf(this,this[Xl])}connectedCallback(){var t;super.connectedCallback();try{this.shadowRoot&&!this.shadowRoot.adoptedStyleSheets.includes(this.adoptedCustomStyleSheet)&&(this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,this.adoptedCustomStyleSheet]),this.useAdoptedStyleSheets=!0}catch(n){this.useAdoptedStyleSheets=!1,console.error("Cannot use adopted stylesheets",n)}let o=this.constructor;o[Jl]||(o[Jl]=!0,this.importDynamicDependencies()),(t=this.shadowRoot)===null||t===void 0||t.addEventListener(sr.eventName,this.scheduleExportpartsUpdate)}disconnectedCallback(){var t;super.disconnectedCallback(),(t=this.shadowRoot)===null||t===void 0||t.removeEventListener(sr.eventName,this.scheduleExportpartsUpdate)}importDynamicDependencies(){}updated(t){super.updated(t),this.updateComplete.then(()=>{this.contentAvailableCallback(t),this.focusElementToFocus(t),this.applyCustomStylesheet(t),this.scheduleExportpartsUpdate(),t.has("exportparts")&&this.dispatchEvent(new sr)})}contentAvailableCallback(t){}focusElementToFocus(t){if(t.has("elementToFocus")&&this.elementToFocus!=null){let{element:o,selector:n,shadowPath:a}=this.elementToFocus;if(n!=null){let i=[...a??[],n];o=Yl(this.shadowRoot,...i)}o?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||o?.blur(),this.elementToFocus=void 0}}applyCustomStylesheet(t){var o,n,a;if(((n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))!==null&&n!==void 0?n:[]).forEach(i=>i.remove()),this.useAdoptedStyleSheets){if(t.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((a=this.customStylesheet)!==null&&a!==void 0?a:"")}catch(i){console.error(i,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let i=document.createElement("style");i.classList.add("ft-lit-element--custom-stylesheet"),i.innerHTML=this.customStylesheet,this.shadowRoot.append(i)}}setExportpartsAttribute(t){var o,n,a,i,s,l;let u=y=>y!=null&&y.trim().length>0,p=t.filter(u).map(y=>y.trim());if(p.length===0){this.exportparts=void 0;return}let m=new Set;for(let y of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let v=(i=(a=y.getAttribute("part"))===null||a===void 0?void 0:a.split(" "))!==null&&i!==void 0?i:[],x=(l=(s=y.getAttribute("exportparts"))===null||s===void 0?void 0:s.split(",").map(O=>O.split(":")[1]))!==null&&l!==void 0?l:[],S=[...v,...x].filter(u).map(O=>O.trim());for(let O of S)m.add(O)}if(m.size===0){this.exportparts=void 0;return}let g=[...m.values()].flatMap(y=>p.map(v=>`${y}:${v}--${y}`));this.exportparts=[...this.part,...g].join(", ")}};e2=t2;cr([(0,wt.property)()],Fe.prototype,"exportpartsPrefix",void 0);cr([Vl([])],Fe.prototype,"exportpartsPrefixes",void 0);cr([(0,wt.property)({reflect:!0})],Fe.prototype,"exportparts",void 0);cr([(0,wt.property)()],Fe.prototype,"customStylesheet",void 0);cr([(0,wt.property)()],Fe.prototype,"elementToFocus",void 0);cr([(0,wt.state)()],Fe.prototype,"useAdoptedStyleSheets",void 0);function Io(e){var t;return(t=e?.isFtReduxStore)!==null&&t!==void 0?t:!1}var $r=Symbol("internalReduxEventsUnsubscribers"),st=Symbol("internalStoresUnsubscribers"),Nt=Symbol("internalStores"),rf=No(Symbol("withRedux"),function(e){var t,o,n;class a extends e{constructor(){super(...arguments),this[t]=new Map,this[o]=new Map,this[n]=new Map}get reduxConstructor(){return this.constructor}willUpdate(s){super.willUpdate(s),[...this.reduxConstructor.reduxReactiveProperties].some(l=>s.has(l))&&this.updateFromStores()}getUnnamedStore(){if(this[Nt].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Nt].values()][0]}getStore(s){return s==null?this.getUnnamedStore():this[Nt].get(s)}addStore(s,l){var u;l=(u=l??s.name)!==null&&u!==void 0?u:"default-store",this.unsubscribeFromStore(l),this[Nt].set(l,s),this.subscribeToStore(l,s),this.updateFromStores()}removeStore(s){let l=typeof s=="string"?s:s.name;this.unsubscribeFromStore(l),this[Nt].delete(l)}setupStores(){this.unsubscribeFromStores(),this[Nt].forEach((s,l)=>this.subscribeToStore(l,s)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((s,l)=>{let u=this.constructor.getPropertyOptions(l);if(!u?.attribute||!this.hasAttribute(typeof u?.attribute=="string"?u.attribute:l)){let p=this.getStore(s.store);p&&(s.store?this[st].has(s.store):this[st].size>0)&&(this[l]=s.selector(p.getState(),this))}})}subscribeToStore(s,l){var u;this[st].set(s,l.subscribe(()=>this.updateFromStores())),this[$r].set(s,[]),Io(l)&&l.eventBus&&((u=this.reduxConstructor.reduxEventListeners)===null||u===void 0||u.forEach((p,m)=>{if(typeof this[m]=="function"&&(!p.store||l.name===p.store)){let g=y=>this[m](y);l.addEventListener(p.eventName,g),this[$r].get(s).push(()=>l.removeEventListener(p.eventName,g))}})),this.onStoreAvailable(s)}unsubscribeFromStores(){this[st].forEach((s,l)=>this.unsubscribeFromStore(l))}unsubscribeFromStore(s){var l;this[st].has(s)&&this[st].get(s)(),this[st].delete(s),(l=this[$r].get(s))===null||l===void 0||l.forEach(u=>u()),this[$r].delete(s)}onStoreAvailable(s){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return t=st,o=Nt,n=$r,a.reduxProperties=new Map,a.reduxReactiveProperties=new Set,a.reduxEventListeners=new Map,a}),r2=class extends rf(Fe){};function xe(e){for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;n<t;n++)o[n-1]=arguments[n];if(0)var a,i;throw Error("[Immer] minified error nr: "+e+(o.length?" "+o.map((function(s){return"'"+s+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Ye(e){return!!e&&!!e[$]}function Me(e){var t;return!!e&&((function(o){if(!o||typeof o!="object")return!1;var n=Object.getPrototypeOf(o);if(n===null)return!0;var a=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return a===Object||typeof a=="function"&&Function.toString.call(a)===uf})(e)||Array.isArray(e)||!!e[l2]||!!(!((t=e.constructor)===null||t===void 0)&&t[l2])||xa(e)||Sa(e))}function _t(e,t,o){o===void 0&&(o=!1),ur(e)===0?(o?Object.keys:dr)(e).forEach((function(n){o&&typeof n=="symbol"||t(n,e[n],e)})):e.forEach((function(n,a){return t(a,n,e)}))}function ur(e){var t=e[$];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:xa(e)?2:Sa(e)?3:0}function lr(e,t){return ur(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function of(e,t){return ur(e)===2?e.get(t):e[t]}function d2(e,t,o){var n=ur(e);n===2?e.set(t,o):n===3?e.add(o):e[t]=o}function u2(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function xa(e){return lf&&e instanceof Map}function Sa(e){return df&&e instanceof Set}function ct(e){return e.o||e.t}function Ca(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=h2(e);delete t[$];for(var o=dr(t),n=0;n<o.length;n++){var a=o[n],i=t[a];i.writable===!1&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(t[a]={configurable:!0,writable:!0,enumerable:i.enumerable,value:e[a]})}return Object.create(Object.getPrototypeOf(e),t)}function Ea(e,t){return t===void 0&&(t=!1),La(e)||Ye(e)||!Me(e)||(ur(e)>1&&(e.set=e.add=e.clear=e.delete=nf),Object.freeze(e),t&&_t(e,(function(o,n){return Ea(n,!0)}),!0)),e}function nf(){xe(2)}function La(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Ge(e){var t=va[e];return t||xe(18,e),t}function af(e,t){va[e]||(va[e]=t)}function ga(){return jr}function fa(e,t){t&&(Ge("Patches"),e.u=[],e.s=[],e.v=t)}function To(e){ya(e),e.p.forEach(sf),e.p=null}function ya(e){e===jr&&(jr=e.l)}function o2(e){return jr={p:[],l:jr,h:e,m:!0,_:0}}function sf(e){var t=e[$];t.i===0||t.i===1?t.j():t.g=!0}function pa(e,t){t._=t.p.length;var o=t.p[0],n=e!==void 0&&e!==o;return t.h.O||Ge("ES5").S(t,e,n),n?(o[$].P&&(To(t),xe(4)),Me(e)&&(e=Po(t,e),t.l||Do(t,e)),t.u&&Ge("Patches").M(o[$].t,e,t.u,t.s)):e=Po(t,o,[]),To(t),t.u&&t.v(t.u,t.s),e!==p2?e:void 0}function Po(e,t,o){if(La(t))return t;var n=t[$];if(!n)return _t(t,(function(l,u){return n2(e,n,t,l,u,o)}),!0),t;if(n.A!==e)return t;if(!n.P)return Do(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var a=n.i===4||n.i===5?n.o=Ca(n.k):n.o,i=a,s=!1;n.i===3&&(i=new Set(a),a.clear(),s=!0),_t(i,(function(l,u){return n2(e,n,a,l,u,o,s)})),Do(e,a,!1),o&&e.u&&Ge("Patches").N(n,o,e.u,e.s)}return n.o}function n2(e,t,o,n,a,i,s){if(Ye(a)){var l=Po(e,a,i&&t&&t.i!==3&&!lr(t.R,n)?i.concat(n):void 0);if(d2(o,n,l),!Ye(l))return;e.m=!1}else s&&o.add(a);if(Me(a)&&!La(a)){if(!e.h.D&&e._<1)return;Po(e,a),t&&t.A.l||Do(e,a)}}function Do(e,t,o){o===void 0&&(o=!1),!e.l&&e.h.D&&e.m&&Ea(t,o)}function ha(e,t){var o=e[$];return(o?ct(o):e)[t]}function a2(e,t){if(t in e)for(var o=Object.getPrototypeOf(e);o;){var n=Object.getOwnPropertyDescriptor(o,t);if(n)return n;o=Object.getPrototypeOf(o)}}function lt(e){e.P||(e.P=!0,e.l&&lt(e.l))}function ma(e){e.o||(e.o=Ca(e.t))}function ba(e,t,o){var n=xa(t)?Ge("MapSet").F(t,o):Sa(t)?Ge("MapSet").T(t,o):e.O?(function(a,i){var s=Array.isArray(a),l={i:s?1:0,A:i?i.A:ga(),P:!1,I:!1,R:{},l:i,t:a,k:null,o:null,j:null,C:!1},u=l,p=Vr;s&&(u=[l],p=Wr);var m=Proxy.revocable(u,p),g=m.revoke,y=m.proxy;return l.k=y,l.j=g,y})(t,o):Ge("ES5").J(t,o);return(o?o.A:ga()).p.push(n),n}function cf(e){return Ye(e)||xe(22,e),(function t(o){if(!Me(o))return o;var n,a=o[$],i=ur(o);if(a){if(!a.P&&(a.i<4||!Ge("ES5").K(a)))return a.t;a.I=!0,n=i2(o,i),a.I=!1}else n=i2(o,i);return _t(n,(function(s,l){a&&of(a.t,s)===l||d2(n,s,t(l))})),i===3?new Set(n):n})(e)}function i2(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return Ca(e)}function f2(){function e(s,l){var u=i[s];return u?u.enumerable=l:i[s]=u={configurable:!0,enumerable:l,get:function(){var p=this[$];return Vr.get(p,s)},set:function(p){var m=this[$];Vr.set(m,s,p)}},u}function t(s){for(var l=s.length-1;l>=0;l--){var u=s[l][$];if(!u.P)switch(u.i){case 5:n(u)&&lt(u);break;case 4:o(u)&&lt(u)}}}function o(s){for(var l=s.t,u=s.k,p=dr(u),m=p.length-1;m>=0;m--){var g=p[m];if(g!==$){var y=l[g];if(y===void 0&&!lr(l,g))return!0;var v=u[g],x=v&&v[$];if(x?x.t!==y:!u2(v,y))return!0}}var S=!!l[$];return p.length!==dr(l).length+(S?0:1)}function n(s){var l=s.k;if(l.length!==s.t.length)return!0;var u=Object.getOwnPropertyDescriptor(l,l.length-1);if(u&&!u.get)return!0;for(var p=0;p<l.length;p++)if(!l.hasOwnProperty(p))return!0;return!1}function a(s){s.g&&xe(3,JSON.stringify(ct(s)))}var i={};af("ES5",{J:function(s,l){var u=Array.isArray(s),p=(function(g,y){if(g){for(var v=Array(y.length),x=0;x<y.length;x++)Object.defineProperty(v,""+x,e(x,!0));return v}var S=h2(y);delete S[$];for(var O=dr(S),A=0;A<O.length;A++){var N=O[A];S[N]=e(N,g||!!S[N].enumerable)}return Object.create(Object.getPrototypeOf(y),S)})(u,s),m={i:u?5:4,A:l?l.A:ga(),P:!1,I:!1,R:{},l,t:s,k:p,o:null,g:!1,C:!1};return Object.defineProperty(p,$,{value:m,writable:!0}),p},S:function(s,l,u){u?Ye(l)&&l[$].A===s&&t(s.p):(s.u&&(function p(m){if(m&&typeof m=="object"){var g=m[$];if(g){var y=g.t,v=g.k,x=g.R,S=g.i;if(S===4)_t(v,(function(z){z!==$&&(y[z]!==void 0||lr(y,z)?x[z]||p(v[z]):(x[z]=!0,lt(g)))})),_t(y,(function(z){v[z]!==void 0||lr(v,z)||(x[z]=!1,lt(g))}));else if(S===5){if(n(g)&&(lt(g),x.length=!0),v.length<y.length)for(var O=v.length;O<y.length;O++)x[O]=!1;else for(var A=y.length;A<v.length;A++)x[A]=!0;for(var N=Math.min(v.length,y.length),M=0;M<N;M++)v.hasOwnProperty(M)||(x[M]=!0),x[M]===void 0&&p(v[M])}}}})(s.p[0]),t(s.p))},K:function(s){return s.i===4?o(s):n(s)}})}var s2,jr,Aa=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",lf=typeof Map<"u",df=typeof Set<"u",c2=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",p2=Aa?Symbol.for("immer-nothing"):((s2={})["immer-nothing"]=!0,s2),l2=Aa?Symbol.for("immer-draftable"):"__$immer_draftable",$=Aa?Symbol.for("immer-state"):"__$immer_state";var uf=""+Object.prototype.constructor,dr=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,h2=Object.getOwnPropertyDescriptors||function(e){var t={};return dr(e).forEach((function(o){t[o]=Object.getOwnPropertyDescriptor(e,o)})),t},va={},Vr={get:function(e,t){if(t===$)return e;var o=ct(e);if(!lr(o,t))return(function(a,i,s){var l,u=a2(i,s);return u?"value"in u?u.value:(l=u.get)===null||l===void 0?void 0:l.call(a.k):void 0})(e,o,t);var n=o[t];return e.I||!Me(n)?n:n===ha(e.t,t)?(ma(e),e.o[t]=ba(e.A.h,n,e)):n},has:function(e,t){return t in ct(e)},ownKeys:function(e){return Reflect.ownKeys(ct(e))},set:function(e,t,o){var n=a2(ct(e),t);if(n?.set)return n.set.call(e.k,o),!0;if(!e.P){var a=ha(ct(e),t),i=a?.[$];if(i&&i.t===o)return e.o[t]=o,e.R[t]=!1,!0;if(u2(o,a)&&(o!==void 0||lr(e.t,t)))return!0;ma(e),lt(e)}return e.o[t]===o&&(o!==void 0||t in e.o)||Number.isNaN(o)&&Number.isNaN(e.o[t])||(e.o[t]=o,e.R[t]=!0),!0},deleteProperty:function(e,t){return ha(e.t,t)!==void 0||t in e.t?(e.R[t]=!1,ma(e),lt(e)):delete e.R[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var o=ct(e),n=Reflect.getOwnPropertyDescriptor(o,t);return n&&{writable:!0,configurable:e.i!==1||t!=="length",enumerable:n.enumerable,value:o[t]}},defineProperty:function(){xe(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){xe(12)}},Wr={};_t(Vr,(function(e,t){Wr[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),Wr.deleteProperty=function(e,t){return Wr.set.call(this,e,t,void 0)},Wr.set=function(e,t,o){return Vr.set.call(this,e[0],t,o,e[0])};var ff=(function(){function e(o){var n=this;this.O=c2,this.D=!0,this.produce=function(a,i,s){if(typeof a=="function"&&typeof i!="function"){var l=i;i=a;var u=n;return function(S){var O=this;S===void 0&&(S=l);for(var A=arguments.length,N=Array(A>1?A-1:0),M=1;M<A;M++)N[M-1]=arguments[M];return u.produce(S,(function(z){var B;return(B=i).call.apply(B,[O,z].concat(N))}))}}var p;if(typeof i!="function"&&xe(6),s!==void 0&&typeof s!="function"&&xe(7),Me(a)){var m=o2(n),g=ba(n,a,void 0),y=!0;try{p=i(g),y=!1}finally{y?To(m):ya(m)}return typeof Promise<"u"&&p instanceof Promise?p.then((function(S){return fa(m,s),pa(S,m)}),(function(S){throw To(m),S})):(fa(m,s),pa(p,m))}if(!a||typeof a!="object"){if((p=i(a))===void 0&&(p=a),p===p2&&(p=void 0),n.D&&Ea(p,!0),s){var v=[],x=[];Ge("Patches").M(a,p,v,x),s(v,x)}return p}xe(21,a)},this.produceWithPatches=function(a,i){if(typeof a=="function")return function(p){for(var m=arguments.length,g=Array(m>1?m-1:0),y=1;y<m;y++)g[y-1]=arguments[y];return n.produceWithPatches(p,(function(v){return a.apply(void 0,[v].concat(g))}))};var s,l,u=n.produce(a,i,(function(p,m){s=p,l=m}));return typeof Promise<"u"&&u instanceof Promise?u.then((function(p){return[p,s,l]})):[u,s,l]},typeof o?.useProxies=="boolean"&&this.setUseProxies(o.useProxies),typeof o?.autoFreeze=="boolean"&&this.setAutoFreeze(o.autoFreeze)}var t=e.prototype;return t.createDraft=function(o){Me(o)||xe(8),Ye(o)&&(o=cf(o));var n=o2(this),a=ba(this,o,void 0);return a[$].C=!0,ya(n),a},t.finishDraft=function(o,n){var a=o&&o[$],i=a.A;return fa(i,n),pa(void 0,i)},t.setAutoFreeze=function(o){this.D=o},t.setUseProxies=function(o){o&&!c2&&xe(20),this.O=o},t.applyPatches=function(o,n){var a;for(a=n.length-1;a>=0;a--){var i=n[a];if(i.path.length===0&&i.op==="replace"){o=i.value;break}}a>-1&&(n=n.slice(a+1));var s=Ge("Patches").$;return Ye(o)?s(o,n):this.produce(o,(function(l){return s(l,n)}))},e})(),fe=new ff,pf=fe.produce,nm=fe.produceWithPatches.bind(fe),am=fe.setAutoFreeze.bind(fe),im=fe.setUseProxies.bind(fe),sm=fe.applyPatches.bind(fe),cm=fe.createDraft.bind(fe),lm=fe.finishDraft.bind(fe),Uo=pf;function Mt(e){"@babel/helpers - typeof";return Mt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Mt(e)}function m2(e,t){if(Mt(e)!="object"||!e)return e;var o=e[Symbol.toPrimitive];if(o!==void 0){var n=o.call(e,t||"default");if(Mt(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function g2(e){var t=m2(e,"string");return Mt(t)=="symbol"?t:t+""}function y2(e,t,o){return(t=g2(t))in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function b2(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),o.push.apply(o,n)}return o}function Oa(e){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?b2(Object(o),!0).forEach(function(n){y2(e,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):b2(Object(o)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(o,n))})}return e}function te(e){return"Minified Redux error #"+e+"; visit https://redux.js.org/Errors?code="+e+" for the full message or use the non-minified dev environment for full errors. "}var v2=(function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"})(),Ra=function(){return Math.random().toString(36).substring(7).split("").join(".")},Bo={INIT:"@@redux/INIT"+Ra(),REPLACE:"@@redux/REPLACE"+Ra(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Ra()}};function hf(e){if(typeof e!="object"||e===null)return!1;for(var t=e;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function wa(e,t,o){var n;if(typeof t=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(te(0));if(typeof t=="function"&&typeof o>"u"&&(o=t,t=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(te(1));return o(wa)(e,t)}if(typeof e!="function")throw new Error(te(2));var a=e,i=t,s=[],l=s,u=!1;function p(){l===s&&(l=s.slice())}function m(){if(u)throw new Error(te(3));return i}function g(S){if(typeof S!="function")throw new Error(te(4));if(u)throw new Error(te(5));var O=!0;return p(),l.push(S),function(){if(O){if(u)throw new Error(te(6));O=!1,p();var N=l.indexOf(S);l.splice(N,1),s=null}}}function y(S){if(!hf(S))throw new Error(te(7));if(typeof S.type>"u")throw new Error(te(8));if(u)throw new Error(te(9));try{u=!0,i=a(i,S)}finally{u=!1}for(var O=s=l,A=0;A<O.length;A++){var N=O[A];N()}return S}function v(S){if(typeof S!="function")throw new Error(te(10));a=S,y({type:Bo.REPLACE})}function x(){var S,O=g;return S={subscribe:function(N){if(typeof N!="object"||N===null)throw new Error(te(11));function M(){N.next&&N.next(m())}M();var z=O(M);return{unsubscribe:z}}},S[v2]=function(){return this},S}return y({type:Bo.INIT}),n={dispatch:y,subscribe:g,getState:m,replaceReducer:v},n[v2]=x,n}function mf(e){Object.keys(e).forEach(function(t){var o=e[t],n=o(void 0,{type:Bo.INIT});if(typeof n>"u")throw new Error(te(12));if(typeof o(void 0,{type:Bo.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(te(13))})}function x2(e){for(var t=Object.keys(e),o={},n=0;n<t.length;n++){var a=t[n];typeof e[a]=="function"&&(o[a]=e[a])}var i=Object.keys(o),s,l;try{mf(o)}catch(u){l=u}return function(p,m){if(p===void 0&&(p={}),l)throw l;if(0)var g;for(var y=!1,v={},x=0;x<i.length;x++){var S=i[x],O=o[S],A=p[S],N=O(A,m);if(typeof N>"u"){var M=m&&m.type;throw new Error(te(14))}v[S]=N,y=y||N!==A}return y=y||i.length!==Object.keys(p).length,y?v:p}}function fr(){for(var e=arguments.length,t=new Array(e),o=0;o<e;o++)t[o]=arguments[o];return t.length===0?function(n){return n}:t.length===1?t[0]:t.reduce(function(n,a){return function(){return n(a.apply(void 0,arguments))}})}function S2(){for(var e=arguments.length,t=new Array(e),o=0;o<e;o++)t[o]=arguments[o];return function(n){return function(){var a=n.apply(void 0,arguments),i=function(){throw new Error(te(15))},s={getState:a.getState,dispatch:function(){return i.apply(void 0,arguments)}},l=t.map(function(u){return u(s)});return i=fr.apply(void 0,l)(a.dispatch),Oa(Oa({},a),{},{dispatch:i})}}}function C2(e){var t=function(n){var a=n.dispatch,i=n.getState;return function(s){return function(l){return typeof l=="function"?l(a,i,e):s(l)}}};return t}var E2=C2();E2.withExtraArgument=C2;var Na=E2;var w2=(function(){var e=function(t,o){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,a){n.__proto__=a}||function(n,a){for(var i in a)Object.prototype.hasOwnProperty.call(a,i)&&(n[i]=a[i])},e(t,o)};return function(t,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");e(t,o);function n(){this.constructor=t}t.prototype=o===null?Object.create(o):(n.prototype=o.prototype,new n)}})(),gf=function(e,t){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,a,i,s;return s={next:l(0),throw:l(1),return:l(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(p){return function(m){return u([p,m])}}function u(p){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,a&&(i=p[0]&2?a.return:p[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,p[1])).done)return i;switch(a=0,i&&(p=[p[0]&2,i.value]),p[0]){case 0:case 1:i=p;break;case 4:return o.label++,{value:p[1],done:!1};case 5:o.label++,a=p[1],p=[0];continue;case 7:p=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(p[0]===6||p[0]===2)){o=0;continue}if(p[0]===3&&(!i||p[1]>i[0]&&p[1]<i[3])){o.label=p[1];break}if(p[0]===6&&o.label<i[1]){o.label=i[1],i=p;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(p);break}i[2]&&o.ops.pop(),o.trys.pop();continue}p=t.call(e,o)}catch(m){p=[6,m],a=0}finally{n=i=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},pr=function(e,t){for(var o=0,n=t.length,a=e.length;o<n;o++,a++)e[a]=t[o];return e},yf=Object.defineProperty,bf=Object.defineProperties,vf=Object.getOwnPropertyDescriptors,L2=Object.getOwnPropertySymbols,xf=Object.prototype.hasOwnProperty,Sf=Object.prototype.propertyIsEnumerable,A2=function(e,t,o){return t in e?yf(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o},dt=function(e,t){for(var o in t||(t={}))xf.call(t,o)&&A2(e,o,t[o]);if(L2)for(var n=0,a=L2(t);n<a.length;n++){var o=a[n];Sf.call(t,o)&&A2(e,o,t[o])}return e},_a=function(e,t){return bf(e,vf(t))},Cf=function(e,t,o){return new Promise(function(n,a){var i=function(u){try{l(o.next(u))}catch(p){a(p)}},s=function(u){try{l(o.throw(u))}catch(p){a(p)}},l=function(u){return u.done?n(u.value):Promise.resolve(u.value).then(i,s)};l((o=o.apply(e,t)).next())})};var Ef=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?fr:fr.apply(null,arguments)},Rm=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(e){return e}};function Lf(e){if(typeof e!="object"||e===null)return!1;var t=Object.getPrototypeOf(e);if(t===null)return!0;for(var o=t;Object.getPrototypeOf(o)!==null;)o=Object.getPrototypeOf(o);return t===o}function ut(e,t){function o(){for(var n=[],a=0;a<arguments.length;a++)n[a]=arguments[a];if(t){var i=t.apply(void 0,n);if(!i)throw new Error("prepareAction did not return an object");return dt(dt({type:e,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:e,payload:n[0]}}return o.toString=function(){return""+e},o.type=e,o.match=function(n){return n.type===e},o}var Af=(function(e){w2(t,e);function t(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=e.apply(this,o)||this;return Object.setPrototypeOf(a,t.prototype),a}return Object.defineProperty(t,Symbol.species,{get:function(){return t},enumerable:!1,configurable:!0}),t.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return e.prototype.concat.apply(this,o)},t.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(t.bind.apply(t,pr([void 0],o[0].concat(this)))):new(t.bind.apply(t,pr([void 0],o.concat(this))))},t})(Array),Of=(function(e){w2(t,e);function t(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=e.apply(this,o)||this;return Object.setPrototypeOf(a,t.prototype),a}return Object.defineProperty(t,Symbol.species,{get:function(){return t},enumerable:!1,configurable:!0}),t.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return e.prototype.concat.apply(this,o)},t.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(t.bind.apply(t,pr([void 0],o[0].concat(this)))):new(t.bind.apply(t,pr([void 0],o.concat(this))))},t})(Array);function za(e){return Me(e)?Uo(e,function(){}):e}function Rf(e){return typeof e=="boolean"}function wf(){return function(t){return Nf(t)}}function Nf(e){e===void 0&&(e={});var t=e.thunk,o=t===void 0?!0:t,n=e.immutableCheck,a=n===void 0?!0:n,i=e.serializableCheck,s=i===void 0?!0:i,l=e.actionCreatorCheck,u=l===void 0?!0:l,p=new Af;if(o&&(Rf(o)?p.push(Na):p.push(Na.withExtraArgument(o.extraArgument))),0){if(a)var m;if(s)var g;if(u)var y}return p}var Ma=!0;function N2(e){var t=wf(),o=e||{},n=o.reducer,a=n===void 0?void 0:n,i=o.middleware,s=i===void 0?t():i,l=o.devTools,u=l===void 0?!0:l,p=o.preloadedState,m=p===void 0?void 0:p,g=o.enhancers,y=g===void 0?void 0:g,v;if(typeof a=="function")v=a;else if(Lf(a))v=x2(a);else throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');var x=s;if(typeof x=="function"&&(x=x(t),!Ma&&!Array.isArray(x)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!Ma&&x.some(function(z){return typeof z!="function"}))throw new Error("each middleware provided to configureStore must be a function");var S=S2.apply(void 0,x),O=fr;u&&(O=Ef(dt({trace:!Ma},typeof u=="object"&&u)));var A=new Of(S),N=A;Array.isArray(y)?N=pr([S],y):typeof y=="function"&&(N=y(A));var M=O.apply(void 0,N);return wa(v,m,M)}function _2(e){var t={},o=[],n,a={addCase:function(i,s){var l=typeof i=="string"?i:i.type;if(!l)throw new Error("`builder.addCase` cannot be called with an empty action type");if(l in t)throw new Error("`builder.addCase` cannot be called with two reducers for the same action type");return t[l]=s,a},addMatcher:function(i,s){return o.push({matcher:i,reducer:s}),a},addDefaultCase:function(i){return n=i,a}};return e(a),[t,o,n]}function _f(e){return typeof e=="function"}function Mf(e,t,o,n){o===void 0&&(o=[]);var a=typeof t=="function"?_2(t):[t,o,n],i=a[0],s=a[1],l=a[2],u;if(_f(e))u=function(){return za(e())};else{var p=za(e);u=function(){return p}}function m(g,y){g===void 0&&(g=u());var v=pr([i[y.type]],s.filter(function(x){var S=x.matcher;return S(y)}).map(function(x){var S=x.reducer;return S}));return v.filter(function(x){return!!x}).length===0&&(v=[l]),v.reduce(function(x,S){if(S)if(Ye(x)){var O=x,A=S(O,y);return A===void 0?x:A}else{if(Me(x))return Uo(x,function(N){return S(N,y)});var A=S(x,y);if(A===void 0){if(x===null)return x;throw Error("A case reducer on a non-draftable value must not return undefined")}return A}return x},g)}return m.getInitialState=u,m}function kf(e,t){return e+"/"+t}function M2(e){var t=e.name;if(!t)throw new Error("`name` is a required option for createSlice");typeof process<"u";var o=typeof e.initialState=="function"?e.initialState:za(e.initialState),n=e.reducers||{},a=Object.keys(n),i={},s={},l={};a.forEach(function(m){var g=n[m],y=kf(t,m),v,x;"reducer"in g?(v=g.reducer,x=g.prepare):v=g,i[m]=v,s[y]=v,l[m]=x?ut(y,x):ut(y)});function u(){var m=typeof e.extraReducers=="function"?_2(e.extraReducers):[e.extraReducers],g=m[0],y=g===void 0?{}:g,v=m[1],x=v===void 0?[]:v,S=m[2],O=S===void 0?void 0:S,A=dt(dt({},y),s);return Mf(o,function(N){for(var M in A)N.addCase(M,A[M]);for(var z=0,B=x;z<B.length;z++){var H=B[z];N.addMatcher(H.matcher,H.reducer)}O&&N.addDefaultCase(O)})}var p;return{name:t,reducer:function(m,g){return p||(p=u()),p(m,g)},actions:l,caseReducers:i,getInitialState:function(){return p||(p=u()),p.getInitialState()}}}var zf="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",If=function(e){e===void 0&&(e=21);for(var t="",o=e;o--;)t+=zf[Math.random()*64|0];return t},Tf=["name","message","stack","code"],ka=(function(){function e(t,o){this.payload=t,this.meta=o}return e})(),O2=(function(){function e(t,o){this.payload=t,this.meta=o}return e})(),Pf=function(e){if(typeof e=="object"&&e!==null){for(var t={},o=0,n=Tf;o<n.length;o++){var a=n[o];typeof e[a]=="string"&&(t[a]=e[a])}return t}return{message:String(e)}},Mm=(function(){function e(t,o,n){var a=ut(t+"/fulfilled",function(m,g,y,v){return{payload:m,meta:_a(dt({},v||{}),{arg:y,requestId:g,requestStatus:"fulfilled"})}}),i=ut(t+"/pending",function(m,g,y){return{payload:void 0,meta:_a(dt({},y||{}),{arg:g,requestId:m,requestStatus:"pending"})}}),s=ut(t+"/rejected",function(m,g,y,v,x){return{payload:v,error:(n&&n.serializeError||Pf)(m||"Rejected"),meta:_a(dt({},x||{}),{arg:y,requestId:g,rejectedWithValue:!!v,requestStatus:"rejected",aborted:m?.name==="AbortError",condition:m?.name==="ConditionError"})}}),l=!1,u=typeof AbortController<"u"?AbortController:(function(){function m(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return m.prototype.abort=function(){},m})();function p(m){return function(g,y,v){var x=n?.idGenerator?n.idGenerator(m):If(),S=new u,O,A=!1;function N(z){O=z,S.abort()}var M=(function(){return Cf(this,null,function(){var z,B,H,Ie,mt,Te,le;return gf(this,function(me){switch(me.label){case 0:return me.trys.push([0,4,,5]),Ie=(z=n?.condition)==null?void 0:z.call(n,m,{getState:y,extra:v}),Uf(Ie)?[4,Ie]:[3,2];case 1:Ie=me.sent(),me.label=2;case 2:if(Ie===!1||S.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return A=!0,mt=new Promise(function(de,gt){return S.signal.addEventListener("abort",function(){return gt({name:"AbortError",message:O||"Aborted"})})}),g(i(x,m,(B=n?.getPendingMeta)==null?void 0:B.call(n,{requestId:x,arg:m},{getState:y,extra:v}))),[4,Promise.race([mt,Promise.resolve(o(m,{dispatch:g,getState:y,extra:v,requestId:x,signal:S.signal,abort:N,rejectWithValue:function(de,gt){return new ka(de,gt)},fulfillWithValue:function(de,gt){return new O2(de,gt)}})).then(function(de){if(de instanceof ka)throw de;return de instanceof O2?a(de.payload,x,m,de.meta):a(de,x,m)})])];case 3:return H=me.sent(),[3,5];case 4:return Te=me.sent(),H=Te instanceof ka?s(null,x,m,Te.payload,Te.meta):s(Te,x,m),[3,5];case 5:return le=n&&!n.dispatchConditionRejection&&s.match(H)&&H.meta.condition,le||g(H),[2,H]}})})})();return Object.assign(M,{abort:N,requestId:x,arg:m,unwrap:function(){return M.then(Df)}})}}return Object.assign(p,{pending:i,rejected:s,fulfilled:a,typePrefix:t})}return e.withTypes=function(){return e},e})();function Df(e){if(e.meta&&e.meta.rejectedWithValue)throw e.payload;if(e.error)throw e.error;return e.payload}function Uf(e){return e!==null&&typeof e=="object"&&typeof e.then=="function"}var k2="listener",z2="completed",I2="cancelled",km="task-"+I2,zm="task-"+z2,Im=k2+"-"+I2,Tm=k2+"-"+z2;var Ia="listenerMiddleware";var Pm=ut(Ia+"/add"),Dm=ut(Ia+"/removeAll"),Um=ut(Ia+"/remove");var R2,Bm=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(e){return(R2||(R2=Promise.resolve())).then(e).catch(function(t){return setTimeout(function(){throw t},0)})},Bf=function(e){return function(t){setTimeout(t,e)}},Fm=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Bf(10);f2();var Ff=No(Symbol("withEventBus"),function(e,t){return class extends e{constructor(){super(...arguments),this.eventBus=t??document.createElement("span")}addEventListener(o,n,a){this.eventBus.addEventListener(o,n,a)}dispatchEvent(o){return this.eventBus.dispatchEvent(o)}removeEventListener(o,n,a){this.eventBus.removeEventListener(o,n,a)}}}),Fo=class extends Ff(Object){};window.ftReduxStores||(window.ftReduxStores={});var T2=class e extends Fo{static get(t){var o;let n=typeof t=="string"?t:t.name,a=typeof t=="string"?void 0:t,i=window.ftReduxStores[n];if(Io(i))return i;if(a==null)return;let s=M2({...a,reducers:(o=a.reducers)!==null&&o!==void 0?o:{}}),l=N2({reducer:(u,p)=>{if(p.type==="CLEAR_FT_REDUX_STORE"){let m=Gr(s.getInitialState());for(let g of p.keeping)m[g]=(u??m)[g];return m}else if(typeof p.type=="string"&&p.type.startsWith("DEFAULT_VALUE_SETTER__"))return{...u,...p.overwrites};return s.reducer(u,p)}});return window.ftReduxStores[a.name]=new e(s,l,a.eventBus)}constructor(t,o,n){super(),this.reduxSlice=t,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new _o;let a=i=>i!=null?JSON.parse(JSON.stringify(i)):i;this.actions=new Proxy(this.reduxSlice.actions,{get:(i,s,l)=>{let u=s,p=i[u];return p?(...m)=>{let g=p(...m.map(a));return this.reduxStore.dispatch(g),g}:m=>{this.setState({[u]:a(m)})}}}),this.eventBus=n??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:[]})}clearKeeping(...t){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:t})}setState(t){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(t).join("_"),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()}};var Go=class{static format(t,o,n,a,i){return window.moment?window.moment(t).locale(o).format(this.getMomentDateFormat(n,a,!!i)):this.getIntlDateTime(t,o,n,a,!!i)}static getMomentDateFormat(t,o,n){return n?"LT":t?o?"lll":"ll":o?"L LT":"L"}static getIntlDateTime(t,o,n,a,i){let s=typeof t=="string"?new Date(t):t,l=new Intl.DateTimeFormat(o,{dateStyle:n?"medium":"short"}).format(s),u=new Intl.DateTimeFormat(o,{timeStyle:"short"}).format(s);return i?u:a?`${l} ${u}`:l}static getTimezoneAsString(){let t=n=>String(Math.floor(n)).padStart(2,"0"),o=new Date().getTimezoneOffset();return`${o<0?"+":"-"}${t(Math.abs(o)/60)}:${t(Math.abs(o)%60)}`}};var Ho=L(P()),Gf="ft-app-info",hr=class e extends CustomEvent{constructor(t){super(e.eventName,{detail:t})}};hr.eventName="authentication-change";var Kr=class e extends CustomEvent{constructor(t){super(e.eventName,{detail:t})}};Kr.eventName="ui-locale-changed";var Hf={session:(e,t)=>{(0,Ho.deepEqual)(e.session,t.payload)||(e.session=t.payload,setTimeout(()=>D.dispatchEvent(new hr(t.payload)),0))}},D=Ho.FtReduxStore.get({name:Gf,reducers:Hf,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],availableContentLocales:[],defaultLocales:void 0,searchInAllLanguagesAllowed:!1,searchLanguageSetsUiLanguage:!1,uiLanguageSetsSearchLanguage:!1,uiLanguageSetsReaderLanguage:!1,metadataConfiguration:void 0,privacyPolicyConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,session:void 0,openExternalDocumentInNewTab:!1,navigatorOnline:!0,forcedOffline:!1,authenticationRequired:!1}});var P2=L(P()),$o=function(e,t,o,n){var a=arguments.length,i=a<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(e,t,o,n);else for(var l=e.length-1;l>=0;l--)(s=e[l])&&(i=(a<3?s(i):a>3?s(t,o,i):s(t,o))||i);return a>3&&i&&Object.defineProperty(t,o,i),i},h9=(0,P2.applyMixinOnce)(Symbol("withDateFormat"),function(e){class t extends e{constructor(...n){super(n),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(D)}dateFormatOptionsChanged(n){return n.has("metadataDescriptors")||n.has("useLongDateFormat")||n.has("useDateTimeFormat")||n.has("uiLocale")}getDateFormatter(n){var a,i;return((i=(a=this.metadataDescriptors.find(l=>l.key===n))===null||a===void 0?void 0:a.date)!==null&&i!==void 0?i:!1)?l=>Go.format(l,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return $o([(0,Ta.property)({type:Boolean})],t.prototype,"useLongDateFormat",void 0),$o([(0,Ta.property)({type:Boolean})],t.prototype,"useDateTimeFormat",void 0),$o([ua({store:D.name,selector:o=>{var n,a;return(a=(n=o.metadataConfiguration)===null||n===void 0?void 0:n.descriptors)!==null&&a!==void 0?a:[]}})],t.prototype,"metadataDescriptors",void 0),$o([ua({store:D.name})],t.prototype,"uiLocale",void 0),t});var D2;(function(e){e.black="black",e.green="green",e.blue="blue",e.purple="purple",e.red="red",e.orange="orange",e.yellow="yellow"})(D2||(D2={}));var U2;(function(e){e.OFFICIAL="OFFICIAL",e.PERSONAL="PERSONAL",e.SHARED="SHARED"})(U2||(U2={}));var B2;(function(e){e.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",e.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",e.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",e.PERSONAL_BOOK="PERSONAL_BOOK",e.ATTACHMENT="ATTACHMENT",e.RESOURCE="RESOURCE",e.HTML_PACKAGE="HTML_PACKAGE"})(B2||(B2={}));var F2;(function(e){e.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",e.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",e.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",e.PERSONAL_BOOK="PERSONAL_BOOK",e.ATTACHMENT="ATTACHMENT",e.RESOURCE="RESOURCE",e.HTML_PACKAGE="HTML_PACKAGE"})(F2||(F2={}));var G2;(function(e){e.LAST_WEEK="LAST_WEEK",e.LAST_MONTH="LAST_MONTH",e.LAST_QUARTER="LAST_QUARTER",e.LAST_YEAR="LAST_YEAR"})(G2||(G2={}));var H2;(function(e){e.VALUE="VALUE",e.DATE="DATE",e.RANGE="RANGE"})(H2||(H2={}));var $2;(function(e){e.OFFICIAL="OFFICIAL",e.AI="AI"})($2||($2={}));var W2;(function(e){e.BOOKMARK__CREATE="BOOKMARK__CREATE",e.BOOKMARK__DELETE="BOOKMARK__DELETE",e.CASE_DEFLECTION__START="CASE_DEFLECTION__START",e.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",e.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",e.CHATBOT__RATE="CHATBOT__RATE",e.COLLECTION__CREATE="COLLECTION__CREATE",e.COLLECTION__UPDATE="COLLECTION__UPDATE",e.COLLECTION__DELETE="COLLECTION__DELETE",e.CUSTOM_EVENT__TRIGGER="CUSTOM_EVENT__TRIGGER",e.DOCUMENT__ON_DEMAND_TRANSLATE="DOCUMENT__ON_DEMAND_TRANSLATE",e.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",e.DOCUMENT__PRINT="DOCUMENT__PRINT",e.DOCUMENT__PROCESS="DOCUMENT__PROCESS",e.DOCUMENT__RATE="DOCUMENT__RATE",e.DOCUMENT__SEARCH="DOCUMENT__SEARCH",e.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",e.DOCUMENT__UNRATE="DOCUMENT__UNRATE",e.FEEDBACK__SEND="FEEDBACK__SEND",e.AI__COMPLETED_QUERY="AI__COMPLETED_QUERY",e.AI__RATE="AI__RATE",e.AI_CASE_DEFLECTION__START="AI_CASE_DEFLECTION__START",e.AI_CASE_DEFLECTION__OPEN_TICKET="AI_CASE_DEFLECTION__OPEN_TICKET",e.KHUB__PROCESS="KHUB__PROCESS",e.KHUB__SEARCH="KHUB__SEARCH",e.LABELS__DOWNLOAD="LABELS__DOWNLOAD",e.LINK__SHARE="LINK__SHARE",e.PAGE__DISPLAY="PAGE__DISPLAY",e.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",e.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",e.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",e.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",e.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",e.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",e.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",e.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",e.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",e.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",e.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",e.TOPIC__AI_TRANSLATE="TOPIC__AI_TRANSLATE",e.TOPIC__RATE="TOPIC__RATE",e.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",e.TOPIC__UNRATE="TOPIC__UNRATE",e.USER__LOGIN="USER__LOGIN",e.USER__LOGOUT="USER__LOGOUT",e.HEARTBEAT="HEARTBEAT"})(W2||(W2={}));var j2;(function(e){e.STANDARD="STANDARD",e.STRUCTURAL="STRUCTURAL"})(j2||(j2={}));var V2;(function(e){e.THIRD_PARTY="THIRD_PARTY",e.OFF_THE_GRID="OFF_THE_GRID",e.CONTENT_PACKAGER="CONTENT_PACKAGER",e.PAGES="PAGES",e.DESIGNED_READER="DESIGNED_READER"})(V2||(V2={}));var K2;(function(e){e.HOMEPAGE="HOMEPAGE",e.CUSTOM="CUSTOM",e.HEADER="HEADER",e.READER="READER",e.TOPIC_TEMPLATE="TOPIC_TEMPLATE",e.SEARCH="SEARCH",e.SEARCH_RESULT="SEARCH_RESULT",e.SEARCH_ANNOUNCEMENT="SEARCH_ANNOUNCEMENT",e.LINK_PREVIEW="LINK_PREVIEW",e.UD_VIEWER="UD_VIEWER",e.ASSET_VIEWER="ASSET_VIEWER"})(K2||(K2={}));var Z2;(function(e){e.CLASSIC="CLASSIC",e.CUSTOM="CUSTOM",e.DESIGNER="DESIGNER"})(Z2||(Z2={}));var q2;(function(e){e.AND="AND",e.OR="OR",e.MONOVALUED="MONOVALUED"})(q2||(q2={}));var Y2;(function(e){e.NONE="NONE",e.ALPHABET="ALPHABET",e.VERSION="VERSION"})(Y2||(Y2={}));var X2;(function(e){e.STARS="STARS",e.LIKE="LIKE",e.DICHOTOMOUS="DICHOTOMOUS",e.NO_RATING="NO_RATING"})(X2||(X2={}));var Q2;(function(e){e.LAST_WEEK="LAST_WEEK",e.LAST_MONTH="LAST_MONTH",e.LAST_QUARTER="LAST_QUARTER",e.LAST_YEAR="LAST_YEAR",e.CUSTOM="CUSTOM"})(Q2||(Q2={}));var J2;(function(e){e.OPTIONAL="OPTIONAL",e.MANDATORY="MANDATORY"})(J2||(J2={}));var e1;(function(e){e.ASC="ASC",e.DESC="DESC"})(e1||(e1={}));var t1;(function(e){e.ALPHA="ALPHA",e.NATURAL="NATURAL"})(t1||(t1={}));var r1;(function(e){e.EVERYWHERE="EVERYWHERE",e.TITLE_ONLY="TITLE_ONLY",e.NONE="NONE"})(r1||(r1={}));var o1;(function(e){e.ARTICLE="ARTICLE",e.BOOK="BOOK",e.SHARED_BOOK="SHARED_BOOK",e.HTML_PACKAGE="HTML_PACKAGE"})(o1||(o1={}));var n1;(function(e){e.FLUIDTOPICS="FLUIDTOPICS",e.EXTERNAL="EXTERNAL"})(n1||(n1={}));var a1;(function(e){e.MAP="MAP",e.DOCUMENT="DOCUMENT",e.TOPIC="TOPIC",e.PERSONAL_BOOK="PERSONAL_BOOK",e.SHARED_BOOK="SHARED_BOOK",e.HTML_PACKAGE="HTML_PACKAGE"})(a1||(a1={}));var i1;(function(e){e.LAST_WEEK="LAST_WEEK",e.LAST_MONTH="LAST_MONTH",e.LAST_QUARTER="LAST_QUARTER",e.LAST_YEAR="LAST_YEAR"})(i1||(i1={}));var s1;(function(e){e.MAP="MAP",e.DOCUMENT="DOCUMENT",e.TOPIC="TOPIC",e.HTML_PACKAGE="HTML_PACKAGE",e.HTML_PACKAGE_PAGE="HTML_PACKAGE_PAGE"})(s1||(s1={}));var c1;(function(e){e.DEFAULT="DEFAULT",e.DOCUMENTS="DOCUMENTS",e.ALL_TOPICS="ALL_TOPICS",e.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(c1||(c1={}));var l1;(function(e){e.PLAIN_TEXT="PLAIN_TEXT",e.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",e.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(l1||(l1={}));var X;(function(e){e.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",e.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",e.HTML_EXPORT_USER="HTML_EXPORT_USER",e.PDF_EXPORT_USER="PDF_EXPORT_USER",e.SAVED_SEARCH_USER="SAVED_SEARCH_USER",e.COLLECTION_USER="COLLECTION_USER",e.OFFLINE_USER="OFFLINE_USER",e.ANALYTICS_USER="ANALYTICS_USER",e.BETA_USER="BETA_USER",e.DEBUG_USER="DEBUG_USER",e.PRINT_USER="PRINT_USER",e.RATING_USER="RATING_USER",e.FEEDBACK_USER="FEEDBACK_USER",e.GENERATIVE_AI_USER="GENERATIVE_AI_USER",e.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",e.CONTENT_PUBLISHER="CONTENT_PUBLISHER",e.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_USER",e.ANNOUNCEMENT_ADMIN="ANNOUNCEMENT_ADMIN",e.KHUB_ADMIN="KHUB_ADMIN",e.USERS_ADMIN="USERS_ADMIN",e.PORTAL_ADMIN="PORTAL_ADMIN",e.ADMIN="ADMIN"})(X||(X={}));var Se;(function(e){e.SEARCHES="SEARCHES",e.BOOKMARKS="BOOKMARKS",e.BOOKS="BOOKS",e.COLLECTIONS="COLLECTIONS"})(Se||(Se={}));var d1;(function(e){e.UNAUTHENTICATED="UNAUTHENTICATED",e.USER_INCOMPLETE="USER_INCOMPLETE",e.MFA_REQUIRED="MFA_REQUIRED",e.AUTHENTICATED="AUTHENTICATED"})(d1||(d1={}));var u1;(function(e){e.UNREACHABLE="UNREACHABLE",e.UNAUTHORIZED="UNAUTHORIZED",e.FORBIDDEN="FORBIDDEN",e.INCOMPATIBLE="INCOMPATIBLE",e.FAILED="FAILED",e.OK="OK"})(u1||(u1={}));var f1;(function(e){e.VALID="VALID",e.INVALID="INVALID"})(f1||(f1={}));var p1;(function(e){e.INACCURATE="INACCURATE",e.INCOMPLETE="INCOMPLETE",e.OFF_TOPIC="OFF_TOPIC",e.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",e.SUMMARY="SUMMARY",e.SEMANTIC_SEARCH="SEMANTIC_SEARCH",e.CHATBOT_INSTRUCTIONS="CHATBOT_INSTRUCTIONS",e.OTHER="OTHER"})(p1||(p1={}));var h1;(function(e){e.INACCURATE="INACCURATE",e.INCOMPLETE="INCOMPLETE",e.OFF_TOPIC="OFF_TOPIC",e.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",e.SLOW="SLOW",e.OTHER="OTHER"})(h1||(h1={}));var m1;(function(e){e.JSON="JSON",e.TEXT="TEXT"})(m1||(m1={}));var g1;(function(e){e.JSON="JSON",e.TEXT="TEXT"})(g1||(g1={}));var y1;(function(e){e.TEXT="TEXT",e.HTML="HTML"})(y1||(y1={}));var b1;(function(e){e.IN_PROGRESS="IN_PROGRESS",e.ERROR="ERROR",e.DONE="DONE"})(b1||(b1={}));var v1;(function(e){e.HTML="HTML",e.MARKDOWN="MARKDOWN"})(v1||(v1={}));var x1;(function(e){e.SOURCES="SOURCES",e.ENRICH_AND_CLEAN="ENRICH_AND_CLEAN",e.VOCABULARIES="VOCABULARIES",e.METADATA="METADATA",e.PRETTY_URL="PRETTY_URL",e.ACCESS_RULE="ACCESS_RULE",e.DESIGNED_PAGES="DESIGNED_PAGES",e.THEME_STUDIO="THEME_STUDIO",e.PORTAL_GENERAL="PORTAL_GENERAL",e.ASSETS="ASSETS",e.CODE_LIBRARY="CODE_LIBRARY",e.THEME="THEME",e.CONTENT_STYLES="CONTENT_STYLES",e.HOMEPAGE="HOMEPAGE",e.CLASSIC_SEARCH_PAGE="CLASSIC_SEARCH_PAGE",e.CLASSIC_READER_PAGE="CLASSIC_READER_PAGE",e.PORTAL_METADATA="PORTAL_METADATA",e.LANGUAGES="LANGUAGES",e.PRINT_TEMPLATES="PRINT_TEMPLATES",e.OFFLINE="OFFLINE",e.CUSTOM_JS="CUSTOM_JS",e.CONFIDENTIALITY="CONFIDENTIALITY",e.NOTIFICATIONS="NOTIFICATIONS"})(x1||(x1={}));var S1;(function(e){e.MAP="MAP",e.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT"})(S1||(S1={}));var $f={[X.PERSONAL_BOOK_SHARE_USER]:[X.PERSONAL_BOOK_USER],[X.HTML_EXPORT_USER]:[X.PERSONAL_BOOK_USER],[X.PDF_EXPORT_USER]:[X.PERSONAL_BOOK_USER],[X.KHUB_ADMIN]:[X.CONTENT_PUBLISHER],[X.ADMIN]:[X.KHUB_ADMIN,X.USERS_ADMIN,X.PORTAL_ADMIN,X.BEHAVIOR_DATA_USER],[X.GENERATIVE_AI_EXPORT_USER]:[X.GENERATIVE_AI_USER]};function C1(e,t){return e===t||($f[e]??[]).some(o=>C1(o,t))}function E1(e,t){return e==null?!1:(Array.isArray(e)?e:Array.isArray(e.roles)?e.roles:Array.isArray(e.profile?.roles)?e.profile.roles:[]).some(n=>C1(n,t))}var Zo=L(P());var Pa=L(P());var kt=class e{static get(t){let{baseUrl:o,apiIntegrationIdentifier:n}=D.getState(),a=t??n;if(o&&a&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,a,!0)}static await(t){return new Promise(o=>{let n=e.get(t);if(n)o(n);else{let a=D.subscribe(()=>{n=e.get(t),n&&(a(),o(n))})}})}};var mr=class{constructor(t){this.overrideApi=t}get api(){var t;return(t=this.overrideApi)!==null&&t!==void 0?t:kt.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):kt.await()}};var pe=class extends mr{constructor(t=!0,o){var n;super(o),this.sortObjectFields=(i,s)=>typeof s!="object"||s==null||Array.isArray(s)?s:Object.fromEntries(Object.entries(s).sort(([l],[u])=>l.localeCompare(u)));let a=this.constructor;a.commonCache=(n=a.commonCache)!==null&&n!==void 0?n:new Pa.CacheRegistry,this.cache=t?a.commonCache:new Pa.CacheRegistry}clearCache(){this.cache.clearAll()}hash(t){return String(Array.from(JSON.stringify(t,this.sortObjectFields)).reduce((o,n)=>0|31*o+n.charCodeAt(0),0))}};var Wo=class extends pe{async listMySearches(){let{session:t}=D.getState();return E1(t,X.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(t.profile.userId),300*1e3):[]}};var jo=class extends pe{async listMyBookmarks(){let t=D.getState().session;return t?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(t.profile.userId),300*1e3):[]}};var Vo=class extends pe{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetCount(t){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${t}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${t}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(t){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${t}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${t}`),this.CACHE_DURATION)}isAuthenticated(){let t=D.getState().session;return!!t?.sessionAuthenticated}};var Ko=class extends pe{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let t=D.getState().session;return!!t?.sessionAuthenticated}};var Wf="ft-user-assets",jf={setAssetCount:(e,t)=>{let{userAssetType:o,count:n}=t.payload.assetCount;e.assetCounts.allAsset[o]=n},clearAssetCount:e=>{Object.values(Se).forEach(t=>{e.assetCounts.allAsset[t]=void 0})},setBookmarkCountByMap:(e,t)=>{let o=t.payload.mapId;e.assetCounts.bookmarkByMap[o]=t.payload.count},clearBookmarkCountByMap:e=>{e.assetCounts.bookmarkByMap={}},addAsset:(e,t)=>{let{assetType:o,mapId:n,asset:a}=t.payload;Ua(e,o,[...Da(e,o),a]),L1(e,o,1,n),A1(e,a)},editAsset:(e,t)=>{let{assetType:o,asset:n}=t.payload;Ua(e,o,Da(e,o).map(a=>a.id===n.id?n:a)),A1(e,n)},removeAsset:(e,t)=>{let{assetType:o,mapId:n,assetId:a}=t.payload;Ua(e,o,Da(e,o).filter(i=>i.id!==a)),L1(e,o,-1,n)}},O1={[Se.SEARCHES]:"savedSearches",[Se.BOOKMARKS]:"bookmarks",[Se.BOOKS]:void 0,[Se.COLLECTIONS]:void 0},Da=(e,t)=>{var o;let n=O1[t];return n?(o=e[n])!==null&&o!==void 0?o:[]:[]},Ua=(e,t,o)=>{let n=O1[t];n&&(e[n]=o)},L1=(e,t,o,n)=>{let a=e.assetCounts.allAsset[t];if(a!==void 0&&(e.assetCounts.allAsset[t]=Math.max(0,a+o),t===Se.BOOKMARKS&&n)){let i=e.assetCounts.bookmarkByMap[n];e.assetCounts.bookmarkByMap[n]=Math.max(0,i+o)}},A1=(e,t)=>{let o=e.assetLabels.map(a=>a.title),n=t.labels.filter(a=>!o.includes(a)).map(a=>({title:a}));e.assetLabels.push(...n)},ne=Zo.FtReduxStore.get({name:Wf,reducers:jf,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(Se).map(e=>[e,void 0])),bookmarkByMap:{}},assetLabels:[]}}),Ba=class{constructor(t=new Vo,o=new Ko){this.assetCountsService=t,this.assetLabelsService=o,this.currentSession=D.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new jo,this.savedSearchesService=new Wo,D.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var t;let{session:o}=D.getState();(0,Zo.deepEqual)((t=this.currentSession)===null||t===void 0?void 0:t.profile,o?.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),ne.actions.clearAssetCount(),ne.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),ne.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),ne.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let t=await this.savedSearchesService.listMySearches();ne.actions.savedSearches(t)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let t=await this.assetLabelsService.getUserAssetLabels();ne.actions.assetLabels(t)}async loadAssetCount(t){let o=await this.assetCountsService.getUserAssetCount(t);o&&ne.getState().assetCounts.allAsset[t]!==o.count&&ne.actions.setAssetCount({assetCount:o})}async loadBookmarkByMapId(t){let o=await this.assetCountsService.getUserBookmarkCountByMap(t);o&&ne.getState().assetCounts.bookmarkByMap[t]!==o.count&&ne.actions.setBookmarkCountByMap({count:o.count,mapId:t})}async reloadAssetCount(t){this.assetCountsService.clearCache();let o=Object.keys(ne.getState().assetCounts.bookmarkByMap).length!==0;t===Se.BOOKMARKS&&o&&ne.actions.clearBookmarkCountByMap(),ne.getState().assetCounts.allAsset[t]!==void 0&&await this.loadAssetCount(t)}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){let o=!((t=this.currentSession)===null||t===void 0)&&t.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;ne.actions.bookmarks(o)}}},Vf=new Ba;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=Vf);var Fa=class{addCommand(t,o=!1){D.commands.add(t,o)}consumeCommand(t){return D.commands.consume(t)}};window.FluidTopicsAppInfoStoreService=new Fa;var Ce=L(P());var R1,gr=class extends CustomEvent{constructor(t){super("ft-i18n-context-loaded",{detail:t})}},Kf=Symbol("clearAfterUnitTest"),qo=class extends(0,Ce.withEventBus)(pe){constructor(t){super(),this.messageContextProvider=t,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[R1]=()=>{this.defaultMessages={},this.cache=new Ce.CacheRegistry,this.listeners={}},this.currentUiLocale=D.getState().uiLocale,D.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:t}=D.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){let o=t.name.toLowerCase();this.cache.setFinal(o,t),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,o){var n;if(t=t.toLowerCase(),o&&Object.keys(o).length>0){let a={...(n=this.defaultMessages[t])!==null&&n!==void 0?n:{},...o};(0,Ce.deepEqual)(this.defaultMessages[t],a)||(this.defaultMessages[t]=a,await this.notify(t))}return this.fetchContext(t)}resolveContext(t){var o,n;return this.fetchContext(t),(n=(o=this.cache.getNow(t))===null||o===void 0?void 0:o.messages)!==null&&n!==void 0?n:{}}resolveRawMessage(t,o){let n=t.toLowerCase();return this.resolveContext(n)[o]}resolveMessage(t,o,...n){var a;let i=t.toLowerCase(),s=this.resolveContext(i);return new Ce.ParametrizedLabelResolver((a=this.defaultMessages[i])!==null&&a!==void 0?a:{},s).resolve(o,...n)}async fetchContext(t){let o=!this.cache.has(t),n;try{n=await this.cache.get(t,()=>this.messageContextProvider(this.currentUiLocale,t)),o&&await this.notify(t)}catch(a){!(a instanceof Ce.CanceledPromiseError)&&o&&console.error(a)}return n}subscribe(t,o){var n;return t=t.toLowerCase(),this.listeners[t]=(n=this.listeners[t])!==null&&n!==void 0?n:new Set,this.listeners[t].add(o),()=>{var a;return(a=this.listeners[t])===null||a===void 0?void 0:a.delete(o)}}async notifyAll(){let t=Object.keys(this.listeners);document.body.dispatchEvent(new gr({loadedContexts:t})),this.dispatchEvent(new gr({loadedContexts:t})),await Promise.all(t.map(o=>this.notify(o,!1)))}async notify(t,o=!0){o&&(document.body.dispatchEvent(new gr({loadedContexts:[t]})),this.dispatchEvent(new gr({loadedContexts:[t]}))),this.listeners[t]!=null&&await Promise.all([...this.listeners[t].values()].map(n=>(0,Ce.delay)(0).then(()=>n()).catch(()=>null)))}};R1=Kf;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends qo{constructor(){super(async(e,t)=>(await this.awaitApi).getFluidTopicsMessageContext(e,t))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends qo{constructor(){super(async(e,t)=>(await this.awaitApi).getCustomMessageContext(e,t))}});var Zr=window.FluidTopicsI18nService,Ga=window.FluidTopicsCustomI18nService;var w1=L(P()),Ha=class{highlightHtml(t,o,n){(0,w1.highlightHtml)(t,o,n)}};window.FluidTopicsHighlightHtmlService=new Ha;var N1=L(P());var $a=class{isDate(t){var o,n,a,i;return(i=(a=((n=(o=D.getState().metadataConfiguration)===null||o===void 0?void 0:o.descriptors)!==null&&n!==void 0?n:[]).find(l=>l.key===t))===null||a===void 0?void 0:a.date)!==null&&i!==void 0?i:!1}format(t,o){var n,a,i,s;if(t==null)return"";try{return N1.DateFormatter.format(t,(n=o?.locale)!==null&&n!==void 0?n:D.getState().uiLocale,(a=o?.longFormat)!==null&&a!==void 0?a:!1,(i=o?.withTime)!==null&&i!==void 0?i:!1,(s=o?.onlyTime)!==null&&s!==void 0?s:!1)}catch(l){throw console.error(`Date ${JSON.stringify(t)} is not valid`,l),l}}};window.FluidTopicsDateService=new $a;var _1=L(P());var qr=class{static get(t,o){var n,a;let i=D.getState(),{lang:s,region:l}=(a=(n=i.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&a!==void 0?a:{lang:"en",region:"US"};return new _1.SearchPlaceConverter(i.baseUrl,t??20,i.searchInAllLanguagesAllowed,o??`${s}-${l}`)}};var Wa=class{urlToSearchRequest(t){return qr.get().parse(t)}searchRequestToUrl(t){return qr.get().serialize(t)}};window.FluidTopicsUrlService=new Wa;var Xe=L(P());var zt=class e extends CustomEvent{constructor(t){super(e.eventName,{detail:{currentItem:t}})}};zt.eventName="change";var ja=class{itemName(t){return`fluid-topics-history-item-${t}`}get(t){let o=sessionStorage.getItem(this.itemName(t));return o?JSON.parse(o):void 0}set(t,o){sessionStorage.setItem(this.itemName(t),JSON.stringify(o))}},M1=new ja;var Yo=class e extends Xe.WithEventBus{static build(){return new e(window.history,M1,()=>window.location,!1)}constructor(t,o,n,a){var i,s;super(),this.history=t,this.historyStorage=o,this.windowLocation=n,this.states=[],this.realPushState=t.pushState,this.realReplaceState=t.replaceState,this.initialIndex=(s=(i=t.state)===null||i===void 0?void 0:i.index)!==null&&s!==void 0?s:t.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(a)}setCurrentState(t,o=!1){let n=o&&this.currentIndex===t.index-1;this.currentState={...this.buildCurrentState(),...t},this.currentIndex=this.currentState.index,this.states[this.currentIndex]=this.currentState,n&&(this.states=this.states.slice(0,this.currentIndex+1)),this.historyStorage.set(this.currentIndex,this.currentState),(0,Xe.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,window.location.href]),setTimeout(()=>this.dispatchEvent(new zt(this.currentItem())),0)}installProxies(){let t=o=>(n,a,[i,s,l])=>{let u=o(),p={...u===this.currentIndex?this.currentState:void 0,...i,index:u,href:typeof l=="string"?l:(l??this.windowLocation()).href};n.apply(a,[p,s,l]),this.setCurrentState(p,!0)};this.history.pushState=new Proxy(this.history.pushState,{apply:t(()=>this.currentIndex+1)}),this.history.replaceState=new Proxy(this.history.replaceState,{apply:t(()=>this.currentIndex)})}initEventListeners(){window.addEventListener("popstate",t=>this.setCurrentState(t.state)),document.querySelector("title")==null&&document.head.append(document.createElement("title")),new MutationObserver(()=>this.updateCurrentState({title:document.title})).observe(document.querySelector("title"),{subtree:!0,characterData:!0,childList:!0})}initData(t){for(let o=this.history.length-1;o>=0;o--)t?this.states[o]=this.historyStorage.get(o):setTimeout(()=>this.states[o]=this.historyStorage.get(o),this.history.length-o)}updateCurrentState(t){var o;let n={...this.buildCurrentState(),...t,index:this.currentIndex,title:(o=t?.title)!==null&&o!==void 0?o:this.currentState.title};this.setCurrentState(n)}addHistoryChangeListener(t){this.addEventListener(zt.eventName,t)}removeHistoryChangeListener(t){this.removeEventListener(zt.eventName,t)}currentItem(){return(0,Xe.deepCopy)(this.currentState)}back(){let t=this.previousDifferentMajorPosition();t>=0?this.history.go(t-this.currentIndex):this.currentIndex!==this.initialIndex?this.history.go(this.initialIndex-this.currentIndex):this.history.back()}backwardItem(){return(0,Xe.deepCopy)(this.states[this.previousDifferentMajorPosition()])}backwardItemMatching(t){let o=this.states.filter(n=>!!n).filter(n=>n.index<this.currentIndex).reverse();return(0,Xe.deepCopy)(o.find(n=>t(n)))}previousDifferentMajorPosition(){let t=this.currentIndex>0?this.currentIndex-1:0;for(;t>0&&!this.isDifferentMajorState(t);)t--;return t}forward(){let t=this.nextMajorPosition();t&&t<this.states.length?this.history.go(t-this.currentIndex):this.history.forward()}forwardItem(){let t=this.nextMajorPosition();if(t)return(0,Xe.deepCopy)(this.states[t])}nextMajorPosition(){let t=this.currentIndex;if(!(t>=this.states.length)){do t++;while(t<this.states.length&&!this.isDifferentMajorState(t));return this.getHigherPositionInTheSameState(t)}}getHigherPositionInTheSameState(t){var o;let n=(o=this.states[t])===null||o===void 0?void 0:o.majorStateId;if(!n)return t;let a=t,i=t+1;for(;this.states.length>i&&!this.isDifferentMajorState(i,n);)this.hasState(i)&&(a=i),i++;return a}buildCurrentState(){var t,o;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(o=(t=this.history.state)===null||t===void 0?void 0:t.title)!==null&&o!==void 0?o:document.title}}hasState(t){return this.states[t]!=null}isDifferentMajorState(t,o){var n;if(!this.hasState(t))return!1;let a=o??this.currentState.majorStateId,i=(n=this.states[t])===null||n===void 0?void 0:n.majorStateId;return i==null||i!=a}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=Yo.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),backwardItemMatching:e=>window.FluidTopicsInternalHistoryService.backwardItemMatching(e),addHistoryChangeListener:e=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(e),removeHistoryChangeListener:e=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(e)});var k1=L(K());var z1=k1.css`
1400
+ `;var yl=["top","right","bottom","left"],gl=["start","end"],ra=yl.reduce((e,t)=>e.concat(t,t+"-"+gl[0],t+"-"+gl[1]),[]),Pr=Math.min,at=Math.max,Dr=Math.round;var _e=e=>({x:e,y:e}),Iu={left:"right",right:"left",bottom:"top",top:"bottom"};function oa(e,t,o){return at(e,Pr(t,o))}function xo(e,t){return typeof e=="function"?e(t):e}function or(e){return e.split("-")[0]}function it(e){return e.split("-")[1]}function na(e){return e==="x"?"y":"x"}function aa(e){return e==="y"?"height":"width"}function So(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function ia(e){return na(So(e))}function bl(e,t,o){o===void 0&&(o=!1);let n=it(e),a=ia(e),i=aa(a),s=a==="x"?n===(o?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=ta(s)),[s,ta(s)]}function vl(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}function ta(e){let t=or(e);return Iu[t]+e.slice(t.length)}function Tu(e){return{top:0,right:0,bottom:0,left:0,...e}}function xl(e){return typeof e!="number"?Tu(e):{top:e,right:e,bottom:e,left:e}}function Lt(e){let{x:t,y:o,width:n,height:a}=e;return{width:n,height:a,top:o,left:t,right:t+n,bottom:o+a,x:t,y:o}}function Sl(e,t,o){let{reference:n,floating:a}=e,i=So(t),s=ia(t),l=aa(s),u=or(t),p=i==="y",m=n.x+n.width/2-a.width/2,g=n.y+n.height/2-a.height/2,y=n[l]/2-a[l]/2,v;switch(u){case"top":v={x:m,y:n.y-a.height};break;case"bottom":v={x:m,y:n.y+n.height};break;case"right":v={x:n.x+n.width,y:g};break;case"left":v={x:n.x-a.width,y:g};break;default:v={x:n.x,y:n.y}}switch(it(t)){case"start":v[s]-=y*(o&&p?-1:1);break;case"end":v[s]+=y*(o&&p?-1:1);break}return v}async function Cl(e,t){var o;t===void 0&&(t={});let{x:n,y:a,platform:i,rects:s,elements:l,strategy:u}=e,{boundary:p="clippingAncestors",rootBoundary:m="viewport",elementContext:g="floating",altBoundary:y=!1,padding:v=0}=xo(t,e),x=xl(v),O=l[y?g==="floating"?"reference":"floating":g],A=Lt(await i.getClippingRect({element:(o=await(i.isElement==null?void 0:i.isElement(O)))==null||o?O:O.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(l.floating)),boundary:p,rootBoundary:m,strategy:u})),N=g==="floating"?{x:n,y:a,width:s.floating.width,height:s.floating.height}:s.reference,M=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l.floating)),z=await(i.isElement==null?void 0:i.isElement(M))?await(i.getScale==null?void 0:i.getScale(M))||{x:1,y:1}:{x:1,y:1},B=Lt(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:N,offsetParent:M,strategy:u}):N);return{top:(A.top-B.top+x.top)/z.y,bottom:(B.bottom-A.bottom+x.bottom)/z.y,left:(A.left-B.left+x.left)/z.x,right:(B.right-A.right+x.right)/z.x}}var Pu=50,El=async(e,t,o)=>{let{placement:n="bottom",strategy:a="absolute",middleware:i=[],platform:s}=o,l=s.detectOverflow?s:{...s,detectOverflow:Cl},u=await(s.isRTL==null?void 0:s.isRTL(t)),p=await s.getElementRects({reference:e,floating:t,strategy:a}),{x:m,y:g}=Sl(p,n,u),y=n,v=0,x={};for(let S=0;S<i.length;S++){let O=i[S];if(!O)continue;let{name:A,fn:N}=O,{x:M,y:z,data:B,reset:H}=await N({x:m,y:g,initialPlacement:n,placement:y,strategy:a,middlewareData:x,rects:p,platform:l,elements:{reference:e,floating:t}});m=M??m,g=z??g,x[A]={...x[A],...B},H&&v<Pu&&(v++,typeof H=="object"&&(H.placement&&(y=H.placement),H.rects&&(p=H.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:a}):H.rects),{x:m,y:g}=Sl(p,y,u)),S=-1)}return{x:m,y:g,placement:y,strategy:a,middlewareData:x}};function Du(e,t,o){return(e?[...o.filter(a=>it(a)===e),...o.filter(a=>it(a)!==e)]:o.filter(a=>or(a)===a)).filter(a=>e?it(a)===e||(t?vl(a)!==a:!1):!0)}var Ll=function(e){return e===void 0&&(e={}),{name:"autoPlacement",options:e,async fn(t){var o,n,a;let{rects:i,middlewareData:s,placement:l,platform:u,elements:p}=t,{crossAxis:m=!1,alignment:g,allowedPlacements:y=ra,autoAlignment:v=!0,...x}=xo(e,t),S=g!==void 0||y===ra?Du(g||null,v,y):y,O=await u.detectOverflow(t,x),A=((o=s.autoPlacement)==null?void 0:o.index)||0,N=S[A];if(N==null)return{};let M=bl(N,i,await(u.isRTL==null?void 0:u.isRTL(p.floating)));if(l!==N)return{reset:{placement:S[0]}};let z=[O[or(N)],O[M[0]],O[M[1]]],B=[...((n=s.autoPlacement)==null?void 0:n.overflows)||[],{placement:N,overflows:z}],H=S[A+1];if(H)return{data:{index:A+1,overflows:B},reset:{placement:H}};let Ie=B.map(le=>{let me=it(le.placement);return[le.placement,me&&m?le.overflows.slice(0,2).reduce((de,gt)=>de+gt,0):le.overflows[0],le.overflows]}).sort((le,me)=>le[1]-me[1]),Te=((a=Ie.filter(le=>le[2].slice(0,it(le[0])?2:3).every(me=>me<=0))[0])==null?void 0:a[0])||Ie[0][0];return Te!==l?{data:{index:A+1,overflows:B},reset:{placement:Te}}:{}}}};var Al=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:o,y:n,placement:a,platform:i}=t,{mainAxis:s=!0,crossAxis:l=!1,limiter:u={fn:A=>{let{x:N,y:M}=A;return{x:N,y:M}}},...p}=xo(e,t),m={x:o,y:n},g=await i.detectOverflow(t,p),y=So(or(a)),v=na(y),x=m[v],S=m[y];if(s){let A=v==="y"?"top":"left",N=v==="y"?"bottom":"right",M=x+g[A],z=x-g[N];x=oa(M,x,z)}if(l){let A=y==="y"?"top":"left",N=y==="y"?"bottom":"right",M=S+g[A],z=S-g[N];S=oa(M,S,z)}let O=u.fn({...t,[v]:x,[y]:S});return{...O,data:{x:O.x-o,y:O.y-n,enabled:{[v]:s,[y]:l}}}}}};function Eo(){return typeof window<"u"}function Ot(e){return Rl(e)?(e.nodeName||"").toLowerCase():"#document"}function se(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ue(e){var t;return(t=(Rl(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Rl(e){return Eo()?e instanceof Node||e instanceof se(e).Node:!1}function be(e){return Eo()?e instanceof Element||e instanceof se(e).Element:!1}function Be(e){return Eo()?e instanceof HTMLElement||e instanceof se(e).HTMLElement:!1}function Ol(e){return!Eo()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof se(e).ShadowRoot}function nr(e){let{overflow:t,overflowX:o,overflowY:n,display:a}=ve(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+o)&&a!=="inline"&&a!=="contents"}function wl(e){return/^(table|td|th)$/.test(Ot(e))}function Ur(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var Uu=/transform|translate|scale|rotate|perspective|filter/,Bu=/paint|layout|strict|content/,At=e=>!!e&&e!=="none",sa;function ar(e){let t=be(e)?ve(e):e;return At(t.transform)||At(t.translate)||At(t.scale)||At(t.rotate)||At(t.perspective)||!Lo()&&(At(t.backdropFilter)||At(t.filter))||Uu.test(t.willChange||"")||Bu.test(t.contain||"")}function Nl(e){let t=qe(e);for(;Be(t)&&!Rt(t);){if(ar(t))return t;if(Ur(t))return null;t=qe(t)}return null}function Lo(){return sa==null&&(sa=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),sa}function Rt(e){return/^(html|body|#document)$/.test(Ot(e))}function ve(e){return se(e).getComputedStyle(e)}function Br(e){return be(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function qe(e){if(Ot(e)==="html")return e;let t=e.assignedSlot||e.parentNode||Ol(e)&&e.host||Ue(e);return Ol(t)?t.host:t}function _l(e){let t=qe(e);return Rt(t)?e.ownerDocument?e.ownerDocument.body:e.body:Be(t)&&nr(t)?t:_l(t)}function Co(e,t,o){var n;t===void 0&&(t=[]),o===void 0&&(o=!0);let a=_l(e),i=a===((n=e.ownerDocument)==null?void 0:n.body),s=se(a);if(i){let l=Ao(s);return t.concat(s,s.visualViewport||[],nr(a)?a:[],l&&o?Co(l):[])}else return t.concat(a,Co(a,[],o))}function Ao(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Il(e){let t=ve(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,a=Be(e),i=a?e.offsetWidth:o,s=a?e.offsetHeight:n,l=Dr(o)!==i||Dr(n)!==s;return l&&(o=i,n=s),{width:o,height:n,$:l}}function Tl(e){return be(e)?e:e.contextElement}function ir(e){let t=Tl(e);if(!Be(t))return _e(1);let o=t.getBoundingClientRect(),{width:n,height:a,$:i}=Il(t),s=(i?Dr(o.width):o.width)/n,l=(i?Dr(o.height):o.height)/a;return(!s||!Number.isFinite(s))&&(s=1),(!l||!Number.isFinite(l))&&(l=1),{x:s,y:l}}var Fu=_e(0);function Pl(e){let t=se(e);return!Lo()||!t.visualViewport?Fu:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Gu(e,t,o){return t===void 0&&(t=!1),!o||t&&o!==se(e)?!1:t}function Fr(e,t,o,n){t===void 0&&(t=!1),o===void 0&&(o=!1);let a=e.getBoundingClientRect(),i=Tl(e),s=_e(1);t&&(n?be(n)&&(s=ir(n)):s=ir(e));let l=Gu(i,o,n)?Pl(i):_e(0),u=(a.left+l.x)/s.x,p=(a.top+l.y)/s.y,m=a.width/s.x,g=a.height/s.y;if(i){let y=se(i),v=n&&be(n)?se(n):n,x=y,S=Ao(x);for(;S&&n&&v!==x;){let O=ir(S),A=S.getBoundingClientRect(),N=ve(S),M=A.left+(S.clientLeft+parseFloat(N.paddingLeft))*O.x,z=A.top+(S.clientTop+parseFloat(N.paddingTop))*O.y;u*=O.x,p*=O.y,m*=O.x,g*=O.y,u+=M,p+=z,x=se(S),S=Ao(x)}}return Lt({width:m,height:g,x:u,y:p})}function Oo(e,t){let o=Br(e).scrollLeft;return t?t.left+o:Fr(Ue(e)).left+o}function Dl(e,t){let o=e.getBoundingClientRect(),n=o.left+t.scrollLeft-Oo(e,o),a=o.top+t.scrollTop;return{x:n,y:a}}function Hu(e){let{elements:t,rect:o,offsetParent:n,strategy:a}=e,i=a==="fixed",s=Ue(n),l=t?Ur(t.floating):!1;if(n===s||l&&i)return o;let u={scrollLeft:0,scrollTop:0},p=_e(1),m=_e(0),g=Be(n);if((g||!g&&!i)&&((Ot(n)!=="body"||nr(s))&&(u=Br(n)),g)){let v=Fr(n);p=ir(n),m.x=v.x+n.clientLeft,m.y=v.y+n.clientTop}let y=s&&!g&&!i?Dl(s,u):_e(0);return{width:o.width*p.x,height:o.height*p.y,x:o.x*p.x-u.scrollLeft*p.x+m.x+y.x,y:o.y*p.y-u.scrollTop*p.y+m.y+y.y}}function $u(e){return Array.from(e.getClientRects())}function Wu(e){let t=Ue(e),o=Br(e),n=e.ownerDocument.body,a=at(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),i=at(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight),s=-o.scrollLeft+Oo(e),l=-o.scrollTop;return ve(n).direction==="rtl"&&(s+=at(t.clientWidth,n.clientWidth)-a),{width:a,height:i,x:s,y:l}}var Ml=25;function ju(e,t){let o=se(e),n=Ue(e),a=o.visualViewport,i=n.clientWidth,s=n.clientHeight,l=0,u=0;if(a){i=a.width,s=a.height;let m=Lo();(!m||m&&t==="fixed")&&(l=a.offsetLeft,u=a.offsetTop)}let p=Oo(n);if(p<=0){let m=n.ownerDocument,g=m.body,y=getComputedStyle(g),v=m.compatMode==="CSS1Compat"&&parseFloat(y.marginLeft)+parseFloat(y.marginRight)||0,x=Math.abs(n.clientWidth-g.clientWidth-v);x<=Ml&&(i-=x)}else p<=Ml&&(i+=p);return{width:i,height:s,x:l,y:u}}function Vu(e,t){let o=Fr(e,!0,t==="fixed"),n=o.top+e.clientTop,a=o.left+e.clientLeft,i=Be(e)?ir(e):_e(1),s=e.clientWidth*i.x,l=e.clientHeight*i.y,u=a*i.x,p=n*i.y;return{width:s,height:l,x:u,y:p}}function kl(e,t,o){let n;if(t==="viewport")n=ju(e,o);else if(t==="document")n=Wu(Ue(e));else if(be(t))n=Vu(t,o);else{let a=Pl(e);n={x:t.x-a.x,y:t.y-a.y,width:t.width,height:t.height}}return Lt(n)}function Ul(e,t){let o=qe(e);return o===t||!be(o)||Rt(o)?!1:ve(o).position==="fixed"||Ul(o,t)}function Ku(e,t){let o=t.get(e);if(o)return o;let n=Co(e,[],!1).filter(l=>be(l)&&Ot(l)!=="body"),a=null,i=ve(e).position==="fixed",s=i?qe(e):e;for(;be(s)&&!Rt(s);){let l=ve(s),u=ar(s);!u&&l.position==="fixed"&&(a=null),(i?!u&&!a:!u&&l.position==="static"&&!!a&&(a.position==="absolute"||a.position==="fixed")||nr(s)&&!u&&Ul(e,s))?n=n.filter(m=>m!==s):a=l,s=qe(s)}return t.set(e,n),n}function Zu(e){let{element:t,boundary:o,rootBoundary:n,strategy:a}=e,s=[...o==="clippingAncestors"?Ur(t)?[]:Ku(t,this._c):[].concat(o),n],l=kl(t,s[0],a),u=l.top,p=l.right,m=l.bottom,g=l.left;for(let y=1;y<s.length;y++){let v=kl(t,s[y],a);u=at(v.top,u),p=Pr(v.right,p),m=Pr(v.bottom,m),g=at(v.left,g)}return{width:p-g,height:m-u,x:g,y:u}}function qu(e){let{width:t,height:o}=Il(e);return{width:t,height:o}}function Yu(e,t,o){let n=Be(t),a=Ue(t),i=o==="fixed",s=Fr(e,!0,i,t),l={scrollLeft:0,scrollTop:0},u=_e(0);function p(){u.x=Oo(a)}if(n||!n&&!i)if((Ot(t)!=="body"||nr(a))&&(l=Br(t)),n){let v=Fr(t,!0,i,t);u.x=v.x+t.clientLeft,u.y=v.y+t.clientTop}else a&&p();i&&!n&&a&&p();let m=a&&!n&&!i?Dl(a,l):_e(0),g=s.left+l.scrollLeft-u.x-m.x,y=s.top+l.scrollTop-u.y-m.y;return{x:g,y,width:s.width,height:s.height}}function ca(e){return ve(e).position==="static"}function zl(e,t){if(!Be(e)||ve(e).position==="fixed")return null;if(t)return t(e);let o=e.offsetParent;return Ue(e)===o&&(o=o.ownerDocument.body),o}function Bl(e,t){let o=se(e);if(Ur(e))return o;if(!Be(e)){let a=qe(e);for(;a&&!Rt(a);){if(be(a)&&!ca(a))return a;a=qe(a)}return o}let n=zl(e,t);for(;n&&wl(n)&&ca(n);)n=zl(n,t);return n&&Rt(n)&&ca(n)&&!ar(n)?o:n||Nl(e)||o}var Xu=async function(e){let t=this.getOffsetParent||Bl,o=this.getDimensions,n=await o(e.floating);return{reference:Yu(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function Qu(e){return ve(e).direction==="rtl"}var Ro={convertOffsetParentRelativeRectToViewportRelativeRect:Hu,getDocumentElement:Ue,getClippingRect:Zu,getOffsetParent:Bl,getElementRects:Xu,getClientRects:$u,getDimensions:qu,getScale:ir,isElement:be,isRTL:Qu};var Fl=Ll,Gl=Al;var Hl=(e,t,o)=>{let n=new Map,a={platform:Ro,...o},i={...a.platform,_c:n};return El(e,t,{...a,platform:i})};function $l(e){return Ju(e)}function la(e){return e.assignedSlot?e.assignedSlot:e.parentNode instanceof ShadowRoot?e.parentNode.host:e.parentNode}function Ju(e){for(let t=e;t;t=la(t))if(t instanceof Element&&getComputedStyle(t).display==="none")return null;for(let t=la(e);t;t=la(t)){if(!(t instanceof Element))continue;let o=getComputedStyle(t);if(o.display!=="contents"&&(o.position!=="static"||ar(o)||t.tagName==="BODY"))return t}return null}async function Wl(e,t,o){let n;return typeof o=="object"?n=o:n={placement:o},Hl(e,t,{strategy:n.strategy,platform:{...Ro,getOffsetParent:a=>Ro.getOffsetParent(a,$l)},middleware:[Gl({crossAxis:!0}),Fl({allowedPlacements:[n.placement]})]})}var br=L(P());var Ta=L(oe());var jl=L(oe(),1);var da=e=>t=>{window.customElements.get(e)||window.customElements.define(e,t)};function Vl(e,t){return(0,jl.property)({type:Object,converter:{fromAttribute:o=>{if(o==null)return Gr(e);try{return JSON.parse(o)}catch{return Gr(e)}},toAttribute:o=>JSON.stringify(o)},hasChanged:Hr,...t??{}})}function ef(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;let o,n;if(Array.isArray(e)){if(o=e.length,o!=t.length)return!1;for(n=o;n--!==0;)if(!wo(e[n],t[n]))return!1;return!0}if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(n of e.entries())if(!t.has(n[0]))return!1;for(n of e.entries())if(!wo(n[1],t.get(n[0])))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(n of e.entries())if(!t.has(n[0]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();let a=s=>Object.keys(s).filter(l=>s[l]!=null),i=a(e);if(o=i.length,o!==a(t).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[n]))return!1;for(n=o;n--!==0;){let s=i[n];if(!wo(e[s],t[s]))return!1}return!0}return e!==e&&t!==t||e==null&&t==null}function wo(e,t){try{return ef(e,t)}catch{return!1}}function Hr(e,t){return!wo(e,t)}function Gr(e){return typeof window.structuredClone=="function"?structuredClone(e):e!=null?JSON.parse(JSON.stringify(e)):e}function No(e,t){let o=n=>n[e]===!0;return n=>{if(o(n))return n;let a=t(n);return a[e]=!0,a}}var Kl=L(oe(),1);var ua=e=>{let t=e??{};return(o,n)=>{var a;let i={hasChanged:Hr,attribute:!1,...t};(0,Kl.property)(i)(o,n);let s=o.constructor;s.reduxProperties=new Map(s.reduxProperties),s.reduxProperties.set(n,{selector:(a=t.selector)!==null&&a!==void 0?a:(l=>l[n]),store:t.store})}};var _o=class{constructor(){this.queue=[]}add(t,o=!1){o&&this.clear(t.type),this.queue.push(t)}consume(t){let o=this.queue.find(n=>n.type===t);return o&&(this.queue=this.queue.filter(n=>n!==o)),o}clear(t){typeof t=="string"?this.queue=this.queue.filter(o=>o.type!==t):this.queue=this.queue.filter(o=>!t.test(o.type))}};var wt=L(oe(),1);var Mo=class{constructor(t=0){this.timeout=t,this.callbacks=[]}run(t,o){return this.callbacks=[t],this.debounce(o)}queue(t,o){return this.callbacks.push(t),this.debounce(o)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(t){return this.promise==null&&(this.promise=new Promise((o,n)=>{this.resolvePromise=o,this.rejectPromise=n})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),t??this.timeout),this.promise}async runCallbacks(){var t,o;let n=[...this.callbacks];this.callbacks=[];let a=(t=this.rejectPromise)!==null&&t!==void 0?t:(()=>null),i=(o=this.resolvePromise)!==null&&o!==void 0?o:(()=>null);this.clearPromise();for(let s of n)try{await s()}catch(l){a(l);return}i(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var ql=L(K(),1);var ko=globalThis,tf=ko.ShadowRoot&&(ko.ShadyCSS===void 0||ko.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype;var Zl=(e,t)=>{if(tf)e.adoptedStyleSheets=t.map((o=>o instanceof CSSStyleSheet?o:o.styleSheet));else for(let o of t){let n=document.createElement("style"),a=ko.litNonce;a!==void 0&&n.setAttribute("nonce",a),n.textContent=o.cssText,e.appendChild(n)}};var zo=class extends ql.LitElement{get scopedRegistryConstructor(){return this.constructor}createRenderRoot(){let t=this.scopedRegistryConstructor;t.elementDefinitions&&!t.registry&&(t.registry=new CustomElementRegistry,t.defineScopedElements(t.elementDefinitions));let o={...t.shadowRootOptions,customElements:t.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return Zl(n,t.elementStyles),n}static canDefineScopedElement(t){return!!this.registry&&!this.registry.get(t)}static defineScopedElements(t){Object.entries(t).forEach(([o,n])=>this.defineScopedElement(o,n))}static defineScopedElement(t,o){da(t)(o),this.canDefineScopedElement(t)&&this.registry.define(t,o)}canDefineScopedElement(t){return this.scopedRegistryConstructor.canDefineScopedElement(t)}defineScopedElements(t){this.scopedRegistryConstructor.defineScopedElements(t)}defineScopedElement(t,o){this.scopedRegistryConstructor.defineScopedElement(t,o)}};function Yl(e,t,...o){var n;let a=e.querySelector(t);for(let i of o)a=(n=a?.shadowRoot)===null||n===void 0?void 0:n.querySelector(i);return a}var cr=function(e,t,o,n){var a=arguments.length,i=a<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(e,t,o,n);else for(var l=e.length-1;l>=0;l--)(s=e[l])&&(i=(a<3?s(i):a>3?s(t,o,i):s(t,o))||i);return a>3&&i&&Object.defineProperty(t,o,i),i},e2,Xl=Symbol("constructorPrototype"),Ql=Symbol("constructorName"),t2=Symbol("exportpartsDebouncer"),Jl=Symbol("dynamicDependenciesLoaded"),sr=class e extends CustomEvent{constructor(){super(e.eventName,{bubbles:!0})}};sr.eventName="exportparts-updated";var Fe=class extends zo{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[e2]=new Mo(5),this.scheduleExportpartsUpdate=()=>{var t,o,n;(!((t=this.exportpartsPrefix)===null||t===void 0)&&t.trim()||(n=(o=this.exportpartsPrefixes)===null||o===void 0?void 0:o.length)!==null&&n!==void 0&&n)&&this[t2].run(()=>{var a,i;!((a=this.exportpartsPrefix)===null||a===void 0)&&a.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((i=this.exportpartsPrefixes)===null||i===void 0?void 0:i.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})},this[Ql]=this.constructor.name,this[Xl]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[Ql]&&Object.setPrototypeOf(this,this[Xl])}connectedCallback(){var t;super.connectedCallback();try{this.shadowRoot&&!this.shadowRoot.adoptedStyleSheets.includes(this.adoptedCustomStyleSheet)&&(this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,this.adoptedCustomStyleSheet]),this.useAdoptedStyleSheets=!0}catch(n){this.useAdoptedStyleSheets=!1,console.error("Cannot use adopted stylesheets",n)}let o=this.constructor;o[Jl]||(o[Jl]=!0,this.importDynamicDependencies()),(t=this.shadowRoot)===null||t===void 0||t.addEventListener(sr.eventName,this.scheduleExportpartsUpdate)}disconnectedCallback(){var t;super.disconnectedCallback(),(t=this.shadowRoot)===null||t===void 0||t.removeEventListener(sr.eventName,this.scheduleExportpartsUpdate)}importDynamicDependencies(){}updated(t){super.updated(t),this.updateComplete.then(()=>{this.contentAvailableCallback(t),this.focusElementToFocus(t),this.applyCustomStylesheet(t),this.scheduleExportpartsUpdate(),t.has("exportparts")&&this.dispatchEvent(new sr)})}contentAvailableCallback(t){}focusElementToFocus(t){if(t.has("elementToFocus")&&this.elementToFocus!=null){let{element:o,selector:n,shadowPath:a}=this.elementToFocus;if(n!=null){let i=[...a??[],n];o=Yl(this.shadowRoot,...i)}o?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||o?.blur(),this.elementToFocus=void 0}}applyCustomStylesheet(t){var o,n,a;if(((n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))!==null&&n!==void 0?n:[]).forEach(i=>i.remove()),this.useAdoptedStyleSheets){if(t.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((a=this.customStylesheet)!==null&&a!==void 0?a:"")}catch(i){console.error(i,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let i=document.createElement("style");i.classList.add("ft-lit-element--custom-stylesheet"),i.innerHTML=this.customStylesheet,this.shadowRoot.append(i)}}setExportpartsAttribute(t){var o,n,a,i,s,l;let u=y=>y!=null&&y.trim().length>0,p=t.filter(u).map(y=>y.trim());if(p.length===0){this.exportparts=void 0;return}let m=new Set;for(let y of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let v=(i=(a=y.getAttribute("part"))===null||a===void 0?void 0:a.split(" "))!==null&&i!==void 0?i:[],x=(l=(s=y.getAttribute("exportparts"))===null||s===void 0?void 0:s.split(",").map(O=>O.split(":")[1]))!==null&&l!==void 0?l:[],S=[...v,...x].filter(u).map(O=>O.trim());for(let O of S)m.add(O)}if(m.size===0){this.exportparts=void 0;return}let g=[...m.values()].flatMap(y=>p.map(v=>`${y}:${v}--${y}`));this.exportparts=[...this.part,...g].join(", ")}};e2=t2;cr([(0,wt.property)()],Fe.prototype,"exportpartsPrefix",void 0);cr([Vl([])],Fe.prototype,"exportpartsPrefixes",void 0);cr([(0,wt.property)({reflect:!0})],Fe.prototype,"exportparts",void 0);cr([(0,wt.property)()],Fe.prototype,"customStylesheet",void 0);cr([(0,wt.property)()],Fe.prototype,"elementToFocus",void 0);cr([(0,wt.state)()],Fe.prototype,"useAdoptedStyleSheets",void 0);function Io(e){var t;return(t=e?.isFtReduxStore)!==null&&t!==void 0?t:!1}var $r=Symbol("internalReduxEventsUnsubscribers"),st=Symbol("internalStoresUnsubscribers"),Nt=Symbol("internalStores"),rf=No(Symbol("withRedux"),function(e){var t,o,n;class a extends e{constructor(){super(...arguments),this[t]=new Map,this[o]=new Map,this[n]=new Map}get reduxConstructor(){return this.constructor}willUpdate(s){super.willUpdate(s),[...this.reduxConstructor.reduxReactiveProperties].some(l=>s.has(l))&&this.updateFromStores()}getUnnamedStore(){if(this[Nt].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Nt].values()][0]}getStore(s){return s==null?this.getUnnamedStore():this[Nt].get(s)}addStore(s,l){var u;l=(u=l??s.name)!==null&&u!==void 0?u:"default-store",this.unsubscribeFromStore(l),this[Nt].set(l,s),this.subscribeToStore(l,s),this.updateFromStores()}removeStore(s){let l=typeof s=="string"?s:s.name;this.unsubscribeFromStore(l),this[Nt].delete(l)}setupStores(){this.unsubscribeFromStores(),this[Nt].forEach((s,l)=>this.subscribeToStore(l,s)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((s,l)=>{let u=this.constructor.getPropertyOptions(l);if(!u?.attribute||!this.hasAttribute(typeof u?.attribute=="string"?u.attribute:l)){let p=this.getStore(s.store);p&&(s.store?this[st].has(s.store):this[st].size>0)&&(this[l]=s.selector(p.getState(),this))}})}subscribeToStore(s,l){var u;this[st].set(s,l.subscribe(()=>this.updateFromStores())),this[$r].set(s,[]),Io(l)&&l.eventBus&&((u=this.reduxConstructor.reduxEventListeners)===null||u===void 0||u.forEach((p,m)=>{if(typeof this[m]=="function"&&(!p.store||l.name===p.store)){let g=y=>this[m](y);l.addEventListener(p.eventName,g),this[$r].get(s).push(()=>l.removeEventListener(p.eventName,g))}})),this.onStoreAvailable(s)}unsubscribeFromStores(){this[st].forEach((s,l)=>this.unsubscribeFromStore(l))}unsubscribeFromStore(s){var l;this[st].has(s)&&this[st].get(s)(),this[st].delete(s),(l=this[$r].get(s))===null||l===void 0||l.forEach(u=>u()),this[$r].delete(s)}onStoreAvailable(s){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return t=st,o=Nt,n=$r,a.reduxProperties=new Map,a.reduxReactiveProperties=new Set,a.reduxEventListeners=new Map,a}),r2=class extends rf(Fe){};function xe(e){for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;n<t;n++)o[n-1]=arguments[n];if(0)var a,i;throw Error("[Immer] minified error nr: "+e+(o.length?" "+o.map((function(s){return"'"+s+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Ye(e){return!!e&&!!e[$]}function Me(e){var t;return!!e&&((function(o){if(!o||typeof o!="object")return!1;var n=Object.getPrototypeOf(o);if(n===null)return!0;var a=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return a===Object||typeof a=="function"&&Function.toString.call(a)===uf})(e)||Array.isArray(e)||!!e[l2]||!!(!((t=e.constructor)===null||t===void 0)&&t[l2])||xa(e)||Sa(e))}function _t(e,t,o){o===void 0&&(o=!1),ur(e)===0?(o?Object.keys:dr)(e).forEach((function(n){o&&typeof n=="symbol"||t(n,e[n],e)})):e.forEach((function(n,a){return t(a,n,e)}))}function ur(e){var t=e[$];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:xa(e)?2:Sa(e)?3:0}function lr(e,t){return ur(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function of(e,t){return ur(e)===2?e.get(t):e[t]}function d2(e,t,o){var n=ur(e);n===2?e.set(t,o):n===3?e.add(o):e[t]=o}function u2(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function xa(e){return lf&&e instanceof Map}function Sa(e){return df&&e instanceof Set}function ct(e){return e.o||e.t}function Ca(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=h2(e);delete t[$];for(var o=dr(t),n=0;n<o.length;n++){var a=o[n],i=t[a];i.writable===!1&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(t[a]={configurable:!0,writable:!0,enumerable:i.enumerable,value:e[a]})}return Object.create(Object.getPrototypeOf(e),t)}function Ea(e,t){return t===void 0&&(t=!1),La(e)||Ye(e)||!Me(e)||(ur(e)>1&&(e.set=e.add=e.clear=e.delete=nf),Object.freeze(e),t&&_t(e,(function(o,n){return Ea(n,!0)}),!0)),e}function nf(){xe(2)}function La(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Ge(e){var t=va[e];return t||xe(18,e),t}function af(e,t){va[e]||(va[e]=t)}function ga(){return jr}function fa(e,t){t&&(Ge("Patches"),e.u=[],e.s=[],e.v=t)}function To(e){ya(e),e.p.forEach(sf),e.p=null}function ya(e){e===jr&&(jr=e.l)}function o2(e){return jr={p:[],l:jr,h:e,m:!0,_:0}}function sf(e){var t=e[$];t.i===0||t.i===1?t.j():t.g=!0}function pa(e,t){t._=t.p.length;var o=t.p[0],n=e!==void 0&&e!==o;return t.h.O||Ge("ES5").S(t,e,n),n?(o[$].P&&(To(t),xe(4)),Me(e)&&(e=Po(t,e),t.l||Do(t,e)),t.u&&Ge("Patches").M(o[$].t,e,t.u,t.s)):e=Po(t,o,[]),To(t),t.u&&t.v(t.u,t.s),e!==p2?e:void 0}function Po(e,t,o){if(La(t))return t;var n=t[$];if(!n)return _t(t,(function(l,u){return n2(e,n,t,l,u,o)}),!0),t;if(n.A!==e)return t;if(!n.P)return Do(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var a=n.i===4||n.i===5?n.o=Ca(n.k):n.o,i=a,s=!1;n.i===3&&(i=new Set(a),a.clear(),s=!0),_t(i,(function(l,u){return n2(e,n,a,l,u,o,s)})),Do(e,a,!1),o&&e.u&&Ge("Patches").N(n,o,e.u,e.s)}return n.o}function n2(e,t,o,n,a,i,s){if(Ye(a)){var l=Po(e,a,i&&t&&t.i!==3&&!lr(t.R,n)?i.concat(n):void 0);if(d2(o,n,l),!Ye(l))return;e.m=!1}else s&&o.add(a);if(Me(a)&&!La(a)){if(!e.h.D&&e._<1)return;Po(e,a),t&&t.A.l||Do(e,a)}}function Do(e,t,o){o===void 0&&(o=!1),!e.l&&e.h.D&&e.m&&Ea(t,o)}function ha(e,t){var o=e[$];return(o?ct(o):e)[t]}function a2(e,t){if(t in e)for(var o=Object.getPrototypeOf(e);o;){var n=Object.getOwnPropertyDescriptor(o,t);if(n)return n;o=Object.getPrototypeOf(o)}}function lt(e){e.P||(e.P=!0,e.l&&lt(e.l))}function ma(e){e.o||(e.o=Ca(e.t))}function ba(e,t,o){var n=xa(t)?Ge("MapSet").F(t,o):Sa(t)?Ge("MapSet").T(t,o):e.O?(function(a,i){var s=Array.isArray(a),l={i:s?1:0,A:i?i.A:ga(),P:!1,I:!1,R:{},l:i,t:a,k:null,o:null,j:null,C:!1},u=l,p=Vr;s&&(u=[l],p=Wr);var m=Proxy.revocable(u,p),g=m.revoke,y=m.proxy;return l.k=y,l.j=g,y})(t,o):Ge("ES5").J(t,o);return(o?o.A:ga()).p.push(n),n}function cf(e){return Ye(e)||xe(22,e),(function t(o){if(!Me(o))return o;var n,a=o[$],i=ur(o);if(a){if(!a.P&&(a.i<4||!Ge("ES5").K(a)))return a.t;a.I=!0,n=i2(o,i),a.I=!1}else n=i2(o,i);return _t(n,(function(s,l){a&&of(a.t,s)===l||d2(n,s,t(l))})),i===3?new Set(n):n})(e)}function i2(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return Ca(e)}function f2(){function e(s,l){var u=i[s];return u?u.enumerable=l:i[s]=u={configurable:!0,enumerable:l,get:function(){var p=this[$];return Vr.get(p,s)},set:function(p){var m=this[$];Vr.set(m,s,p)}},u}function t(s){for(var l=s.length-1;l>=0;l--){var u=s[l][$];if(!u.P)switch(u.i){case 5:n(u)&&lt(u);break;case 4:o(u)&&lt(u)}}}function o(s){for(var l=s.t,u=s.k,p=dr(u),m=p.length-1;m>=0;m--){var g=p[m];if(g!==$){var y=l[g];if(y===void 0&&!lr(l,g))return!0;var v=u[g],x=v&&v[$];if(x?x.t!==y:!u2(v,y))return!0}}var S=!!l[$];return p.length!==dr(l).length+(S?0:1)}function n(s){var l=s.k;if(l.length!==s.t.length)return!0;var u=Object.getOwnPropertyDescriptor(l,l.length-1);if(u&&!u.get)return!0;for(var p=0;p<l.length;p++)if(!l.hasOwnProperty(p))return!0;return!1}function a(s){s.g&&xe(3,JSON.stringify(ct(s)))}var i={};af("ES5",{J:function(s,l){var u=Array.isArray(s),p=(function(g,y){if(g){for(var v=Array(y.length),x=0;x<y.length;x++)Object.defineProperty(v,""+x,e(x,!0));return v}var S=h2(y);delete S[$];for(var O=dr(S),A=0;A<O.length;A++){var N=O[A];S[N]=e(N,g||!!S[N].enumerable)}return Object.create(Object.getPrototypeOf(y),S)})(u,s),m={i:u?5:4,A:l?l.A:ga(),P:!1,I:!1,R:{},l,t:s,k:p,o:null,g:!1,C:!1};return Object.defineProperty(p,$,{value:m,writable:!0}),p},S:function(s,l,u){u?Ye(l)&&l[$].A===s&&t(s.p):(s.u&&(function p(m){if(m&&typeof m=="object"){var g=m[$];if(g){var y=g.t,v=g.k,x=g.R,S=g.i;if(S===4)_t(v,(function(z){z!==$&&(y[z]!==void 0||lr(y,z)?x[z]||p(v[z]):(x[z]=!0,lt(g)))})),_t(y,(function(z){v[z]!==void 0||lr(v,z)||(x[z]=!1,lt(g))}));else if(S===5){if(n(g)&&(lt(g),x.length=!0),v.length<y.length)for(var O=v.length;O<y.length;O++)x[O]=!1;else for(var A=y.length;A<v.length;A++)x[A]=!0;for(var N=Math.min(v.length,y.length),M=0;M<N;M++)v.hasOwnProperty(M)||(x[M]=!0),x[M]===void 0&&p(v[M])}}}})(s.p[0]),t(s.p))},K:function(s){return s.i===4?o(s):n(s)}})}var s2,jr,Aa=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",lf=typeof Map<"u",df=typeof Set<"u",c2=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",p2=Aa?Symbol.for("immer-nothing"):((s2={})["immer-nothing"]=!0,s2),l2=Aa?Symbol.for("immer-draftable"):"__$immer_draftable",$=Aa?Symbol.for("immer-state"):"__$immer_state";var uf=""+Object.prototype.constructor,dr=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,h2=Object.getOwnPropertyDescriptors||function(e){var t={};return dr(e).forEach((function(o){t[o]=Object.getOwnPropertyDescriptor(e,o)})),t},va={},Vr={get:function(e,t){if(t===$)return e;var o=ct(e);if(!lr(o,t))return(function(a,i,s){var l,u=a2(i,s);return u?"value"in u?u.value:(l=u.get)===null||l===void 0?void 0:l.call(a.k):void 0})(e,o,t);var n=o[t];return e.I||!Me(n)?n:n===ha(e.t,t)?(ma(e),e.o[t]=ba(e.A.h,n,e)):n},has:function(e,t){return t in ct(e)},ownKeys:function(e){return Reflect.ownKeys(ct(e))},set:function(e,t,o){var n=a2(ct(e),t);if(n?.set)return n.set.call(e.k,o),!0;if(!e.P){var a=ha(ct(e),t),i=a?.[$];if(i&&i.t===o)return e.o[t]=o,e.R[t]=!1,!0;if(u2(o,a)&&(o!==void 0||lr(e.t,t)))return!0;ma(e),lt(e)}return e.o[t]===o&&(o!==void 0||t in e.o)||Number.isNaN(o)&&Number.isNaN(e.o[t])||(e.o[t]=o,e.R[t]=!0),!0},deleteProperty:function(e,t){return ha(e.t,t)!==void 0||t in e.t?(e.R[t]=!1,ma(e),lt(e)):delete e.R[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var o=ct(e),n=Reflect.getOwnPropertyDescriptor(o,t);return n&&{writable:!0,configurable:e.i!==1||t!=="length",enumerable:n.enumerable,value:o[t]}},defineProperty:function(){xe(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){xe(12)}},Wr={};_t(Vr,(function(e,t){Wr[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),Wr.deleteProperty=function(e,t){return Wr.set.call(this,e,t,void 0)},Wr.set=function(e,t,o){return Vr.set.call(this,e[0],t,o,e[0])};var ff=(function(){function e(o){var n=this;this.O=c2,this.D=!0,this.produce=function(a,i,s){if(typeof a=="function"&&typeof i!="function"){var l=i;i=a;var u=n;return function(S){var O=this;S===void 0&&(S=l);for(var A=arguments.length,N=Array(A>1?A-1:0),M=1;M<A;M++)N[M-1]=arguments[M];return u.produce(S,(function(z){var B;return(B=i).call.apply(B,[O,z].concat(N))}))}}var p;if(typeof i!="function"&&xe(6),s!==void 0&&typeof s!="function"&&xe(7),Me(a)){var m=o2(n),g=ba(n,a,void 0),y=!0;try{p=i(g),y=!1}finally{y?To(m):ya(m)}return typeof Promise<"u"&&p instanceof Promise?p.then((function(S){return fa(m,s),pa(S,m)}),(function(S){throw To(m),S})):(fa(m,s),pa(p,m))}if(!a||typeof a!="object"){if((p=i(a))===void 0&&(p=a),p===p2&&(p=void 0),n.D&&Ea(p,!0),s){var v=[],x=[];Ge("Patches").M(a,p,v,x),s(v,x)}return p}xe(21,a)},this.produceWithPatches=function(a,i){if(typeof a=="function")return function(p){for(var m=arguments.length,g=Array(m>1?m-1:0),y=1;y<m;y++)g[y-1]=arguments[y];return n.produceWithPatches(p,(function(v){return a.apply(void 0,[v].concat(g))}))};var s,l,u=n.produce(a,i,(function(p,m){s=p,l=m}));return typeof Promise<"u"&&u instanceof Promise?u.then((function(p){return[p,s,l]})):[u,s,l]},typeof o?.useProxies=="boolean"&&this.setUseProxies(o.useProxies),typeof o?.autoFreeze=="boolean"&&this.setAutoFreeze(o.autoFreeze)}var t=e.prototype;return t.createDraft=function(o){Me(o)||xe(8),Ye(o)&&(o=cf(o));var n=o2(this),a=ba(this,o,void 0);return a[$].C=!0,ya(n),a},t.finishDraft=function(o,n){var a=o&&o[$],i=a.A;return fa(i,n),pa(void 0,i)},t.setAutoFreeze=function(o){this.D=o},t.setUseProxies=function(o){o&&!c2&&xe(20),this.O=o},t.applyPatches=function(o,n){var a;for(a=n.length-1;a>=0;a--){var i=n[a];if(i.path.length===0&&i.op==="replace"){o=i.value;break}}a>-1&&(n=n.slice(a+1));var s=Ge("Patches").$;return Ye(o)?s(o,n):this.produce(o,(function(l){return s(l,n)}))},e})(),fe=new ff,pf=fe.produce,nm=fe.produceWithPatches.bind(fe),am=fe.setAutoFreeze.bind(fe),im=fe.setUseProxies.bind(fe),sm=fe.applyPatches.bind(fe),cm=fe.createDraft.bind(fe),lm=fe.finishDraft.bind(fe),Uo=pf;function Mt(e){"@babel/helpers - typeof";return Mt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Mt(e)}function m2(e,t){if(Mt(e)!="object"||!e)return e;var o=e[Symbol.toPrimitive];if(o!==void 0){var n=o.call(e,t||"default");if(Mt(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function g2(e){var t=m2(e,"string");return Mt(t)=="symbol"?t:t+""}function y2(e,t,o){return(t=g2(t))in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function b2(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),o.push.apply(o,n)}return o}function Oa(e){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?b2(Object(o),!0).forEach(function(n){y2(e,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):b2(Object(o)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(o,n))})}return e}function te(e){return"Minified Redux error #"+e+"; visit https://redux.js.org/Errors?code="+e+" for the full message or use the non-minified dev environment for full errors. "}var v2=(function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"})(),Ra=function(){return Math.random().toString(36).substring(7).split("").join(".")},Bo={INIT:"@@redux/INIT"+Ra(),REPLACE:"@@redux/REPLACE"+Ra(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Ra()}};function hf(e){if(typeof e!="object"||e===null)return!1;for(var t=e;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function wa(e,t,o){var n;if(typeof t=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(te(0));if(typeof t=="function"&&typeof o>"u"&&(o=t,t=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(te(1));return o(wa)(e,t)}if(typeof e!="function")throw new Error(te(2));var a=e,i=t,s=[],l=s,u=!1;function p(){l===s&&(l=s.slice())}function m(){if(u)throw new Error(te(3));return i}function g(S){if(typeof S!="function")throw new Error(te(4));if(u)throw new Error(te(5));var O=!0;return p(),l.push(S),function(){if(O){if(u)throw new Error(te(6));O=!1,p();var N=l.indexOf(S);l.splice(N,1),s=null}}}function y(S){if(!hf(S))throw new Error(te(7));if(typeof S.type>"u")throw new Error(te(8));if(u)throw new Error(te(9));try{u=!0,i=a(i,S)}finally{u=!1}for(var O=s=l,A=0;A<O.length;A++){var N=O[A];N()}return S}function v(S){if(typeof S!="function")throw new Error(te(10));a=S,y({type:Bo.REPLACE})}function x(){var S,O=g;return S={subscribe:function(N){if(typeof N!="object"||N===null)throw new Error(te(11));function M(){N.next&&N.next(m())}M();var z=O(M);return{unsubscribe:z}}},S[v2]=function(){return this},S}return y({type:Bo.INIT}),n={dispatch:y,subscribe:g,getState:m,replaceReducer:v},n[v2]=x,n}function mf(e){Object.keys(e).forEach(function(t){var o=e[t],n=o(void 0,{type:Bo.INIT});if(typeof n>"u")throw new Error(te(12));if(typeof o(void 0,{type:Bo.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(te(13))})}function x2(e){for(var t=Object.keys(e),o={},n=0;n<t.length;n++){var a=t[n];typeof e[a]=="function"&&(o[a]=e[a])}var i=Object.keys(o),s,l;try{mf(o)}catch(u){l=u}return function(p,m){if(p===void 0&&(p={}),l)throw l;if(0)var g;for(var y=!1,v={},x=0;x<i.length;x++){var S=i[x],O=o[S],A=p[S],N=O(A,m);if(typeof N>"u"){var M=m&&m.type;throw new Error(te(14))}v[S]=N,y=y||N!==A}return y=y||i.length!==Object.keys(p).length,y?v:p}}function fr(){for(var e=arguments.length,t=new Array(e),o=0;o<e;o++)t[o]=arguments[o];return t.length===0?function(n){return n}:t.length===1?t[0]:t.reduce(function(n,a){return function(){return n(a.apply(void 0,arguments))}})}function S2(){for(var e=arguments.length,t=new Array(e),o=0;o<e;o++)t[o]=arguments[o];return function(n){return function(){var a=n.apply(void 0,arguments),i=function(){throw new Error(te(15))},s={getState:a.getState,dispatch:function(){return i.apply(void 0,arguments)}},l=t.map(function(u){return u(s)});return i=fr.apply(void 0,l)(a.dispatch),Oa(Oa({},a),{},{dispatch:i})}}}function C2(e){var t=function(n){var a=n.dispatch,i=n.getState;return function(s){return function(l){return typeof l=="function"?l(a,i,e):s(l)}}};return t}var E2=C2();E2.withExtraArgument=C2;var Na=E2;var w2=(function(){var e=function(t,o){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,a){n.__proto__=a}||function(n,a){for(var i in a)Object.prototype.hasOwnProperty.call(a,i)&&(n[i]=a[i])},e(t,o)};return function(t,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");e(t,o);function n(){this.constructor=t}t.prototype=o===null?Object.create(o):(n.prototype=o.prototype,new n)}})(),gf=function(e,t){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,a,i,s;return s={next:l(0),throw:l(1),return:l(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(p){return function(m){return u([p,m])}}function u(p){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,a&&(i=p[0]&2?a.return:p[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,p[1])).done)return i;switch(a=0,i&&(p=[p[0]&2,i.value]),p[0]){case 0:case 1:i=p;break;case 4:return o.label++,{value:p[1],done:!1};case 5:o.label++,a=p[1],p=[0];continue;case 7:p=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(p[0]===6||p[0]===2)){o=0;continue}if(p[0]===3&&(!i||p[1]>i[0]&&p[1]<i[3])){o.label=p[1];break}if(p[0]===6&&o.label<i[1]){o.label=i[1],i=p;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(p);break}i[2]&&o.ops.pop(),o.trys.pop();continue}p=t.call(e,o)}catch(m){p=[6,m],a=0}finally{n=i=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},pr=function(e,t){for(var o=0,n=t.length,a=e.length;o<n;o++,a++)e[a]=t[o];return e},yf=Object.defineProperty,bf=Object.defineProperties,vf=Object.getOwnPropertyDescriptors,L2=Object.getOwnPropertySymbols,xf=Object.prototype.hasOwnProperty,Sf=Object.prototype.propertyIsEnumerable,A2=function(e,t,o){return t in e?yf(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o},dt=function(e,t){for(var o in t||(t={}))xf.call(t,o)&&A2(e,o,t[o]);if(L2)for(var n=0,a=L2(t);n<a.length;n++){var o=a[n];Sf.call(t,o)&&A2(e,o,t[o])}return e},_a=function(e,t){return bf(e,vf(t))},Cf=function(e,t,o){return new Promise(function(n,a){var i=function(u){try{l(o.next(u))}catch(p){a(p)}},s=function(u){try{l(o.throw(u))}catch(p){a(p)}},l=function(u){return u.done?n(u.value):Promise.resolve(u.value).then(i,s)};l((o=o.apply(e,t)).next())})};var Ef=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?fr:fr.apply(null,arguments)},Rm=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(e){return e}};function Lf(e){if(typeof e!="object"||e===null)return!1;var t=Object.getPrototypeOf(e);if(t===null)return!0;for(var o=t;Object.getPrototypeOf(o)!==null;)o=Object.getPrototypeOf(o);return t===o}function ut(e,t){function o(){for(var n=[],a=0;a<arguments.length;a++)n[a]=arguments[a];if(t){var i=t.apply(void 0,n);if(!i)throw new Error("prepareAction did not return an object");return dt(dt({type:e,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:e,payload:n[0]}}return o.toString=function(){return""+e},o.type=e,o.match=function(n){return n.type===e},o}var Af=(function(e){w2(t,e);function t(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=e.apply(this,o)||this;return Object.setPrototypeOf(a,t.prototype),a}return Object.defineProperty(t,Symbol.species,{get:function(){return t},enumerable:!1,configurable:!0}),t.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return e.prototype.concat.apply(this,o)},t.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(t.bind.apply(t,pr([void 0],o[0].concat(this)))):new(t.bind.apply(t,pr([void 0],o.concat(this))))},t})(Array),Of=(function(e){w2(t,e);function t(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=e.apply(this,o)||this;return Object.setPrototypeOf(a,t.prototype),a}return Object.defineProperty(t,Symbol.species,{get:function(){return t},enumerable:!1,configurable:!0}),t.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return e.prototype.concat.apply(this,o)},t.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(t.bind.apply(t,pr([void 0],o[0].concat(this)))):new(t.bind.apply(t,pr([void 0],o.concat(this))))},t})(Array);function za(e){return Me(e)?Uo(e,function(){}):e}function Rf(e){return typeof e=="boolean"}function wf(){return function(t){return Nf(t)}}function Nf(e){e===void 0&&(e={});var t=e.thunk,o=t===void 0?!0:t,n=e.immutableCheck,a=n===void 0?!0:n,i=e.serializableCheck,s=i===void 0?!0:i,l=e.actionCreatorCheck,u=l===void 0?!0:l,p=new Af;if(o&&(Rf(o)?p.push(Na):p.push(Na.withExtraArgument(o.extraArgument))),0){if(a)var m;if(s)var g;if(u)var y}return p}var Ma=!0;function N2(e){var t=wf(),o=e||{},n=o.reducer,a=n===void 0?void 0:n,i=o.middleware,s=i===void 0?t():i,l=o.devTools,u=l===void 0?!0:l,p=o.preloadedState,m=p===void 0?void 0:p,g=o.enhancers,y=g===void 0?void 0:g,v;if(typeof a=="function")v=a;else if(Lf(a))v=x2(a);else throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');var x=s;if(typeof x=="function"&&(x=x(t),!Ma&&!Array.isArray(x)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!Ma&&x.some(function(z){return typeof z!="function"}))throw new Error("each middleware provided to configureStore must be a function");var S=S2.apply(void 0,x),O=fr;u&&(O=Ef(dt({trace:!Ma},typeof u=="object"&&u)));var A=new Of(S),N=A;Array.isArray(y)?N=pr([S],y):typeof y=="function"&&(N=y(A));var M=O.apply(void 0,N);return wa(v,m,M)}function _2(e){var t={},o=[],n,a={addCase:function(i,s){var l=typeof i=="string"?i:i.type;if(!l)throw new Error("`builder.addCase` cannot be called with an empty action type");if(l in t)throw new Error("`builder.addCase` cannot be called with two reducers for the same action type");return t[l]=s,a},addMatcher:function(i,s){return o.push({matcher:i,reducer:s}),a},addDefaultCase:function(i){return n=i,a}};return e(a),[t,o,n]}function _f(e){return typeof e=="function"}function Mf(e,t,o,n){o===void 0&&(o=[]);var a=typeof t=="function"?_2(t):[t,o,n],i=a[0],s=a[1],l=a[2],u;if(_f(e))u=function(){return za(e())};else{var p=za(e);u=function(){return p}}function m(g,y){g===void 0&&(g=u());var v=pr([i[y.type]],s.filter(function(x){var S=x.matcher;return S(y)}).map(function(x){var S=x.reducer;return S}));return v.filter(function(x){return!!x}).length===0&&(v=[l]),v.reduce(function(x,S){if(S)if(Ye(x)){var O=x,A=S(O,y);return A===void 0?x:A}else{if(Me(x))return Uo(x,function(N){return S(N,y)});var A=S(x,y);if(A===void 0){if(x===null)return x;throw Error("A case reducer on a non-draftable value must not return undefined")}return A}return x},g)}return m.getInitialState=u,m}function kf(e,t){return e+"/"+t}function M2(e){var t=e.name;if(!t)throw new Error("`name` is a required option for createSlice");typeof process<"u";var o=typeof e.initialState=="function"?e.initialState:za(e.initialState),n=e.reducers||{},a=Object.keys(n),i={},s={},l={};a.forEach(function(m){var g=n[m],y=kf(t,m),v,x;"reducer"in g?(v=g.reducer,x=g.prepare):v=g,i[m]=v,s[y]=v,l[m]=x?ut(y,x):ut(y)});function u(){var m=typeof e.extraReducers=="function"?_2(e.extraReducers):[e.extraReducers],g=m[0],y=g===void 0?{}:g,v=m[1],x=v===void 0?[]:v,S=m[2],O=S===void 0?void 0:S,A=dt(dt({},y),s);return Mf(o,function(N){for(var M in A)N.addCase(M,A[M]);for(var z=0,B=x;z<B.length;z++){var H=B[z];N.addMatcher(H.matcher,H.reducer)}O&&N.addDefaultCase(O)})}var p;return{name:t,reducer:function(m,g){return p||(p=u()),p(m,g)},actions:l,caseReducers:i,getInitialState:function(){return p||(p=u()),p.getInitialState()}}}var zf="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",If=function(e){e===void 0&&(e=21);for(var t="",o=e;o--;)t+=zf[Math.random()*64|0];return t},Tf=["name","message","stack","code"],ka=(function(){function e(t,o){this.payload=t,this.meta=o}return e})(),O2=(function(){function e(t,o){this.payload=t,this.meta=o}return e})(),Pf=function(e){if(typeof e=="object"&&e!==null){for(var t={},o=0,n=Tf;o<n.length;o++){var a=n[o];typeof e[a]=="string"&&(t[a]=e[a])}return t}return{message:String(e)}},Mm=(function(){function e(t,o,n){var a=ut(t+"/fulfilled",function(m,g,y,v){return{payload:m,meta:_a(dt({},v||{}),{arg:y,requestId:g,requestStatus:"fulfilled"})}}),i=ut(t+"/pending",function(m,g,y){return{payload:void 0,meta:_a(dt({},y||{}),{arg:g,requestId:m,requestStatus:"pending"})}}),s=ut(t+"/rejected",function(m,g,y,v,x){return{payload:v,error:(n&&n.serializeError||Pf)(m||"Rejected"),meta:_a(dt({},x||{}),{arg:y,requestId:g,rejectedWithValue:!!v,requestStatus:"rejected",aborted:m?.name==="AbortError",condition:m?.name==="ConditionError"})}}),l=!1,u=typeof AbortController<"u"?AbortController:(function(){function m(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return m.prototype.abort=function(){},m})();function p(m){return function(g,y,v){var x=n?.idGenerator?n.idGenerator(m):If(),S=new u,O,A=!1;function N(z){O=z,S.abort()}var M=(function(){return Cf(this,null,function(){var z,B,H,Ie,mt,Te,le;return gf(this,function(me){switch(me.label){case 0:return me.trys.push([0,4,,5]),Ie=(z=n?.condition)==null?void 0:z.call(n,m,{getState:y,extra:v}),Uf(Ie)?[4,Ie]:[3,2];case 1:Ie=me.sent(),me.label=2;case 2:if(Ie===!1||S.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return A=!0,mt=new Promise(function(de,gt){return S.signal.addEventListener("abort",function(){return gt({name:"AbortError",message:O||"Aborted"})})}),g(i(x,m,(B=n?.getPendingMeta)==null?void 0:B.call(n,{requestId:x,arg:m},{getState:y,extra:v}))),[4,Promise.race([mt,Promise.resolve(o(m,{dispatch:g,getState:y,extra:v,requestId:x,signal:S.signal,abort:N,rejectWithValue:function(de,gt){return new ka(de,gt)},fulfillWithValue:function(de,gt){return new O2(de,gt)}})).then(function(de){if(de instanceof ka)throw de;return de instanceof O2?a(de.payload,x,m,de.meta):a(de,x,m)})])];case 3:return H=me.sent(),[3,5];case 4:return Te=me.sent(),H=Te instanceof ka?s(null,x,m,Te.payload,Te.meta):s(Te,x,m),[3,5];case 5:return le=n&&!n.dispatchConditionRejection&&s.match(H)&&H.meta.condition,le||g(H),[2,H]}})})})();return Object.assign(M,{abort:N,requestId:x,arg:m,unwrap:function(){return M.then(Df)}})}}return Object.assign(p,{pending:i,rejected:s,fulfilled:a,typePrefix:t})}return e.withTypes=function(){return e},e})();function Df(e){if(e.meta&&e.meta.rejectedWithValue)throw e.payload;if(e.error)throw e.error;return e.payload}function Uf(e){return e!==null&&typeof e=="object"&&typeof e.then=="function"}var k2="listener",z2="completed",I2="cancelled",km="task-"+I2,zm="task-"+z2,Im=k2+"-"+I2,Tm=k2+"-"+z2;var Ia="listenerMiddleware";var Pm=ut(Ia+"/add"),Dm=ut(Ia+"/removeAll"),Um=ut(Ia+"/remove");var R2,Bm=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(e){return(R2||(R2=Promise.resolve())).then(e).catch(function(t){return setTimeout(function(){throw t},0)})},Bf=function(e){return function(t){setTimeout(t,e)}},Fm=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Bf(10);f2();var Ff=No(Symbol("withEventBus"),function(e,t){return class extends e{constructor(){super(...arguments),this.eventBus=t??document.createElement("span")}addEventListener(o,n,a){this.eventBus.addEventListener(o,n,a)}dispatchEvent(o){return this.eventBus.dispatchEvent(o)}removeEventListener(o,n,a){this.eventBus.removeEventListener(o,n,a)}}}),Fo=class extends Ff(Object){};window.ftReduxStores||(window.ftReduxStores={});var T2=class e extends Fo{static get(t){var o;let n=typeof t=="string"?t:t.name,a=typeof t=="string"?void 0:t,i=window.ftReduxStores[n];if(Io(i))return i;if(a==null)return;let s=M2({...a,reducers:(o=a.reducers)!==null&&o!==void 0?o:{}}),l=N2({reducer:(u,p)=>{if(p.type==="CLEAR_FT_REDUX_STORE"){let m=Gr(s.getInitialState());for(let g of p.keeping)m[g]=(u??m)[g];return m}else if(typeof p.type=="string"&&p.type.startsWith("DEFAULT_VALUE_SETTER__"))return{...u,...p.overwrites};return s.reducer(u,p)}});return window.ftReduxStores[a.name]=new e(s,l,a.eventBus)}constructor(t,o,n){super(),this.reduxSlice=t,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new _o;let a=i=>i!=null?JSON.parse(JSON.stringify(i)):i;this.actions=new Proxy(this.reduxSlice.actions,{get:(i,s,l)=>{let u=s,p=i[u];return p?(...m)=>{let g=p(...m.map(a));return this.reduxStore.dispatch(g),g}:m=>{this.setState({[u]:a(m)})}}}),this.eventBus=n??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:[]})}clearKeeping(...t){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:t})}setState(t){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(t).join("_"),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()}};var Go=class{static format(t,o,n,a,i){return window.moment?window.moment(t).locale(o).format(this.getMomentDateFormat(n,a,!!i)):this.getIntlDateTime(t,o,n,a,!!i)}static getMomentDateFormat(t,o,n){return n?"LT":t?o?"lll":"ll":o?"L LT":"L"}static getIntlDateTime(t,o,n,a,i){let s=typeof t=="string"?new Date(t):t,l=new Intl.DateTimeFormat(o,{dateStyle:n?"medium":"short"}).format(s),u=new Intl.DateTimeFormat(o,{timeStyle:"short"}).format(s);return i?u:a?`${l} ${u}`:l}static getTimezoneAsString(){let t=n=>String(Math.floor(n)).padStart(2,"0"),o=new Date().getTimezoneOffset();return`${o<0?"+":"-"}${t(Math.abs(o)/60)}:${t(Math.abs(o)%60)}`}};var Ho=L(P()),Gf="ft-app-info",hr=class e extends CustomEvent{constructor(t){super(e.eventName,{detail:t})}};hr.eventName="authentication-change";var Kr=class e extends CustomEvent{constructor(t){super(e.eventName,{detail:t})}};Kr.eventName="ui-locale-changed";var Hf={session:(e,t)=>{(0,Ho.deepEqual)(e.session,t.payload)||(e.session=t.payload,setTimeout(()=>D.dispatchEvent(new hr(t.payload)),0))}},D=Ho.FtReduxStore.get({name:Gf,reducers:Hf,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],availableContentLocales:[],defaultLocales:void 0,searchInAllLanguagesAllowed:!1,searchLanguageSetsUiLanguage:!1,uiLanguageSetsSearchLanguage:!1,uiLanguageSetsReaderLanguage:!1,metadataConfiguration:void 0,privacyPolicyConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,session:void 0,openExternalDocumentInNewTab:!1,navigatorOnline:!0,forcedOffline:!1,authenticationRequired:!1}});var P2=L(P()),$o=function(e,t,o,n){var a=arguments.length,i=a<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(e,t,o,n);else for(var l=e.length-1;l>=0;l--)(s=e[l])&&(i=(a<3?s(i):a>3?s(t,o,i):s(t,o))||i);return a>3&&i&&Object.defineProperty(t,o,i),i},h9=(0,P2.applyMixinOnce)(Symbol("withDateFormat"),function(e){class t extends e{constructor(...n){super(n),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(D)}dateFormatOptionsChanged(n){return n.has("metadataDescriptors")||n.has("useLongDateFormat")||n.has("useDateTimeFormat")||n.has("uiLocale")}getDateFormatter(n){var a,i;return((i=(a=this.metadataDescriptors.find(l=>l.key===n))===null||a===void 0?void 0:a.date)!==null&&i!==void 0?i:!1)?l=>Go.format(l,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return $o([(0,Ta.property)({type:Boolean})],t.prototype,"useLongDateFormat",void 0),$o([(0,Ta.property)({type:Boolean})],t.prototype,"useDateTimeFormat",void 0),$o([ua({store:D.name,selector:o=>{var n,a;return(a=(n=o.metadataConfiguration)===null||n===void 0?void 0:n.descriptors)!==null&&a!==void 0?a:[]}})],t.prototype,"metadataDescriptors",void 0),$o([ua({store:D.name})],t.prototype,"uiLocale",void 0),t});var D2;(function(e){e.black="black",e.green="green",e.blue="blue",e.purple="purple",e.red="red",e.orange="orange",e.yellow="yellow"})(D2||(D2={}));var U2;(function(e){e.OFFICIAL="OFFICIAL",e.PERSONAL="PERSONAL",e.SHARED="SHARED"})(U2||(U2={}));var B2;(function(e){e.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",e.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",e.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",e.PERSONAL_BOOK="PERSONAL_BOOK",e.ATTACHMENT="ATTACHMENT",e.RESOURCE="RESOURCE",e.HTML_PACKAGE="HTML_PACKAGE"})(B2||(B2={}));var F2;(function(e){e.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",e.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",e.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",e.PERSONAL_BOOK="PERSONAL_BOOK",e.ATTACHMENT="ATTACHMENT",e.RESOURCE="RESOURCE",e.HTML_PACKAGE="HTML_PACKAGE"})(F2||(F2={}));var G2;(function(e){e.LAST_WEEK="LAST_WEEK",e.LAST_MONTH="LAST_MONTH",e.LAST_QUARTER="LAST_QUARTER",e.LAST_YEAR="LAST_YEAR"})(G2||(G2={}));var H2;(function(e){e.VALUE="VALUE",e.DATE="DATE",e.RANGE="RANGE"})(H2||(H2={}));var $2;(function(e){e.OFFICIAL="OFFICIAL",e.AI="AI"})($2||($2={}));var W2;(function(e){e.BOOKMARK__CREATE="BOOKMARK__CREATE",e.BOOKMARK__DELETE="BOOKMARK__DELETE",e.CASE_DEFLECTION__START="CASE_DEFLECTION__START",e.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",e.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",e.CHATBOT__RATE="CHATBOT__RATE",e.COLLECTION__CREATE="COLLECTION__CREATE",e.COLLECTION__UPDATE="COLLECTION__UPDATE",e.COLLECTION__DELETE="COLLECTION__DELETE",e.CUSTOM_EVENT__TRIGGER="CUSTOM_EVENT__TRIGGER",e.DOCUMENT__ON_DEMAND_TRANSLATE="DOCUMENT__ON_DEMAND_TRANSLATE",e.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",e.DOCUMENT__PRINT="DOCUMENT__PRINT",e.DOCUMENT__PROCESS="DOCUMENT__PROCESS",e.DOCUMENT__RATE="DOCUMENT__RATE",e.DOCUMENT__SEARCH="DOCUMENT__SEARCH",e.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",e.DOCUMENT__UNRATE="DOCUMENT__UNRATE",e.FEEDBACK__SEND="FEEDBACK__SEND",e.AI__COMPLETED_QUERY="AI__COMPLETED_QUERY",e.AI__RATE="AI__RATE",e.AI_CASE_DEFLECTION__START="AI_CASE_DEFLECTION__START",e.AI_CASE_DEFLECTION__OPEN_TICKET="AI_CASE_DEFLECTION__OPEN_TICKET",e.KHUB__PROCESS="KHUB__PROCESS",e.KHUB__SEARCH="KHUB__SEARCH",e.LABELS__DOWNLOAD="LABELS__DOWNLOAD",e.LINK__SHARE="LINK__SHARE",e.PAGE__DISPLAY="PAGE__DISPLAY",e.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",e.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",e.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",e.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",e.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",e.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",e.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",e.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",e.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",e.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",e.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",e.TOPIC__AI_TRANSLATE="TOPIC__AI_TRANSLATE",e.TOPIC__RATE="TOPIC__RATE",e.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",e.TOPIC__UNRATE="TOPIC__UNRATE",e.USER__LOGIN="USER__LOGIN",e.USER__LOGOUT="USER__LOGOUT",e.HEARTBEAT="HEARTBEAT"})(W2||(W2={}));var j2;(function(e){e.STANDARD="STANDARD",e.STRUCTURAL="STRUCTURAL"})(j2||(j2={}));var V2;(function(e){e.THIRD_PARTY="THIRD_PARTY",e.OFF_THE_GRID="OFF_THE_GRID",e.CONTENT_PACKAGER="CONTENT_PACKAGER",e.PAGES="PAGES",e.DESIGNED_READER="DESIGNED_READER"})(V2||(V2={}));var K2;(function(e){e.HOMEPAGE="HOMEPAGE",e.CUSTOM="CUSTOM",e.HEADER="HEADER",e.READER="READER",e.TOPIC_TEMPLATE="TOPIC_TEMPLATE",e.SEARCH="SEARCH",e.SEARCH_RESULT="SEARCH_RESULT",e.SEARCH_ANNOUNCEMENT="SEARCH_ANNOUNCEMENT",e.LINK_PREVIEW="LINK_PREVIEW",e.UD_VIEWER="UD_VIEWER",e.ASSET_VIEWER="ASSET_VIEWER"})(K2||(K2={}));var Z2;(function(e){e.CLASSIC="CLASSIC",e.CUSTOM="CUSTOM",e.DESIGNER="DESIGNER"})(Z2||(Z2={}));var q2;(function(e){e.AND="AND",e.OR="OR",e.MONOVALUED="MONOVALUED"})(q2||(q2={}));var Y2;(function(e){e.NONE="NONE",e.ALPHABET="ALPHABET",e.VERSION="VERSION"})(Y2||(Y2={}));var X2;(function(e){e.STARS="STARS",e.LIKE="LIKE",e.DICHOTOMOUS="DICHOTOMOUS",e.NO_RATING="NO_RATING"})(X2||(X2={}));var Q2;(function(e){e.LAST_WEEK="LAST_WEEK",e.LAST_MONTH="LAST_MONTH",e.LAST_QUARTER="LAST_QUARTER",e.LAST_YEAR="LAST_YEAR",e.CUSTOM="CUSTOM"})(Q2||(Q2={}));var J2;(function(e){e.OPTIONAL="OPTIONAL",e.MANDATORY="MANDATORY"})(J2||(J2={}));var e1;(function(e){e.ASC="ASC",e.DESC="DESC"})(e1||(e1={}));var t1;(function(e){e.ALPHA="ALPHA",e.NATURAL="NATURAL"})(t1||(t1={}));var r1;(function(e){e.EVERYWHERE="EVERYWHERE",e.TITLE_ONLY="TITLE_ONLY",e.NONE="NONE"})(r1||(r1={}));var o1;(function(e){e.ARTICLE="ARTICLE",e.BOOK="BOOK",e.SHARED_BOOK="SHARED_BOOK",e.HTML_PACKAGE="HTML_PACKAGE"})(o1||(o1={}));var n1;(function(e){e.FLUIDTOPICS="FLUIDTOPICS",e.EXTERNAL="EXTERNAL"})(n1||(n1={}));var a1;(function(e){e.MAP="MAP",e.DOCUMENT="DOCUMENT",e.TOPIC="TOPIC",e.PERSONAL_BOOK="PERSONAL_BOOK",e.SHARED_BOOK="SHARED_BOOK",e.HTML_PACKAGE="HTML_PACKAGE"})(a1||(a1={}));var i1;(function(e){e.LAST_WEEK="LAST_WEEK",e.LAST_MONTH="LAST_MONTH",e.LAST_QUARTER="LAST_QUARTER",e.LAST_YEAR="LAST_YEAR"})(i1||(i1={}));var s1;(function(e){e.MAP="MAP",e.DOCUMENT="DOCUMENT",e.TOPIC="TOPIC",e.HTML_PACKAGE="HTML_PACKAGE",e.HTML_PACKAGE_PAGE="HTML_PACKAGE_PAGE"})(s1||(s1={}));var c1;(function(e){e.DEFAULT="DEFAULT",e.DOCUMENTS="DOCUMENTS",e.ALL_TOPICS="ALL_TOPICS",e.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(c1||(c1={}));var l1;(function(e){e.PLAIN_TEXT="PLAIN_TEXT",e.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",e.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(l1||(l1={}));var X;(function(e){e.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",e.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",e.HTML_EXPORT_USER="HTML_EXPORT_USER",e.PDF_EXPORT_USER="PDF_EXPORT_USER",e.SAVED_SEARCH_USER="SAVED_SEARCH_USER",e.COLLECTION_USER="COLLECTION_USER",e.OFFLINE_USER="OFFLINE_USER",e.ANALYTICS_USER="ANALYTICS_USER",e.BETA_USER="BETA_USER",e.DEBUG_USER="DEBUG_USER",e.PRINT_USER="PRINT_USER",e.RATING_USER="RATING_USER",e.FEEDBACK_USER="FEEDBACK_USER",e.GENERATIVE_AI_USER="GENERATIVE_AI_USER",e.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",e.CONTENT_PUBLISHER="CONTENT_PUBLISHER",e.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_USER",e.ANNOUNCEMENT_ADMIN="ANNOUNCEMENT_ADMIN",e.KHUB_ADMIN="KHUB_ADMIN",e.USERS_ADMIN="USERS_ADMIN",e.PORTAL_ADMIN="PORTAL_ADMIN",e.ADMIN="ADMIN"})(X||(X={}));var Se;(function(e){e.SEARCHES="SEARCHES",e.BOOKMARKS="BOOKMARKS",e.BOOKS="BOOKS",e.COLLECTIONS="COLLECTIONS"})(Se||(Se={}));var d1;(function(e){e.UNAUTHENTICATED="UNAUTHENTICATED",e.USER_INCOMPLETE="USER_INCOMPLETE",e.MFA_REQUIRED="MFA_REQUIRED",e.AUTHENTICATED="AUTHENTICATED"})(d1||(d1={}));var u1;(function(e){e.UNREACHABLE="UNREACHABLE",e.UNAUTHORIZED="UNAUTHORIZED",e.FORBIDDEN="FORBIDDEN",e.INCOMPATIBLE="INCOMPATIBLE",e.FAILED="FAILED",e.OK="OK"})(u1||(u1={}));var f1;(function(e){e.VALID="VALID",e.INVALID="INVALID"})(f1||(f1={}));var p1;(function(e){e.INACCURATE="INACCURATE",e.INCOMPLETE="INCOMPLETE",e.OFF_TOPIC="OFF_TOPIC",e.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",e.SUMMARY="SUMMARY",e.SEMANTIC_SEARCH="SEMANTIC_SEARCH",e.CHATBOT_INSTRUCTIONS="CHATBOT_INSTRUCTIONS",e.DOCUMENTATION="DOCUMENTATION",e.OTHER="OTHER"})(p1||(p1={}));var h1;(function(e){e.INACCURATE="INACCURATE",e.INCOMPLETE="INCOMPLETE",e.OFF_TOPIC="OFF_TOPIC",e.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",e.SLOW="SLOW",e.OTHER="OTHER"})(h1||(h1={}));var m1;(function(e){e.JSON="JSON",e.TEXT="TEXT"})(m1||(m1={}));var g1;(function(e){e.JSON="JSON",e.TEXT="TEXT"})(g1||(g1={}));var y1;(function(e){e.TEXT="TEXT",e.HTML="HTML"})(y1||(y1={}));var b1;(function(e){e.IN_PROGRESS="IN_PROGRESS",e.ERROR="ERROR",e.DONE="DONE"})(b1||(b1={}));var v1;(function(e){e.HTML="HTML",e.MARKDOWN="MARKDOWN"})(v1||(v1={}));var x1;(function(e){e.SOURCES="SOURCES",e.ENRICH_AND_CLEAN="ENRICH_AND_CLEAN",e.VOCABULARIES="VOCABULARIES",e.METADATA="METADATA",e.PRETTY_URL="PRETTY_URL",e.ACCESS_RULE="ACCESS_RULE",e.DESIGNED_PAGES="DESIGNED_PAGES",e.THEME_STUDIO="THEME_STUDIO",e.PORTAL_GENERAL="PORTAL_GENERAL",e.ASSETS="ASSETS",e.CODE_LIBRARY="CODE_LIBRARY",e.THEME="THEME",e.CONTENT_STYLES="CONTENT_STYLES",e.HOMEPAGE="HOMEPAGE",e.CLASSIC_SEARCH_PAGE="CLASSIC_SEARCH_PAGE",e.CLASSIC_READER_PAGE="CLASSIC_READER_PAGE",e.PORTAL_METADATA="PORTAL_METADATA",e.LANGUAGES="LANGUAGES",e.PRINT_TEMPLATES="PRINT_TEMPLATES",e.OFFLINE="OFFLINE",e.CUSTOM_JS="CUSTOM_JS",e.CONFIDENTIALITY="CONFIDENTIALITY",e.NOTIFICATIONS="NOTIFICATIONS"})(x1||(x1={}));var S1;(function(e){e.MAP="MAP",e.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT"})(S1||(S1={}));var $f={[X.PERSONAL_BOOK_SHARE_USER]:[X.PERSONAL_BOOK_USER],[X.HTML_EXPORT_USER]:[X.PERSONAL_BOOK_USER],[X.PDF_EXPORT_USER]:[X.PERSONAL_BOOK_USER],[X.KHUB_ADMIN]:[X.CONTENT_PUBLISHER],[X.ADMIN]:[X.KHUB_ADMIN,X.USERS_ADMIN,X.PORTAL_ADMIN,X.BEHAVIOR_DATA_USER],[X.GENERATIVE_AI_EXPORT_USER]:[X.GENERATIVE_AI_USER]};function C1(e,t){return e===t||($f[e]??[]).some(o=>C1(o,t))}function E1(e,t){return e==null?!1:(Array.isArray(e)?e:Array.isArray(e.roles)?e.roles:Array.isArray(e.profile?.roles)?e.profile.roles:[]).some(n=>C1(n,t))}var Zo=L(P());var Pa=L(P());var kt=class e{static get(t){let{baseUrl:o,apiIntegrationIdentifier:n}=D.getState(),a=t??n;if(o&&a&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,a,!0)}static await(t){return new Promise(o=>{let n=e.get(t);if(n)o(n);else{let a=D.subscribe(()=>{n=e.get(t),n&&(a(),o(n))})}})}};var mr=class{constructor(t){this.overrideApi=t}get api(){var t;return(t=this.overrideApi)!==null&&t!==void 0?t:kt.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):kt.await()}};var pe=class extends mr{constructor(t=!0,o){var n;super(o),this.sortObjectFields=(i,s)=>typeof s!="object"||s==null||Array.isArray(s)?s:Object.fromEntries(Object.entries(s).sort(([l],[u])=>l.localeCompare(u)));let a=this.constructor;a.commonCache=(n=a.commonCache)!==null&&n!==void 0?n:new Pa.CacheRegistry,this.cache=t?a.commonCache:new Pa.CacheRegistry}clearCache(){this.cache.clearAll()}hash(t){return String(Array.from(JSON.stringify(t,this.sortObjectFields)).reduce((o,n)=>0|31*o+n.charCodeAt(0),0))}};var Wo=class extends pe{async listMySearches(){let{session:t}=D.getState();return E1(t,X.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(t.profile.userId),300*1e3):[]}};var jo=class extends pe{async listMyBookmarks(){let t=D.getState().session;return t?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(t.profile.userId),300*1e3):[]}};var Vo=class extends pe{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetCount(t){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${t}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${t}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(t){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${t}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${t}`),this.CACHE_DURATION)}isAuthenticated(){let t=D.getState().session;return!!t?.sessionAuthenticated}};var Ko=class extends pe{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let t=D.getState().session;return!!t?.sessionAuthenticated}};var Wf="ft-user-assets",jf={setAssetCount:(e,t)=>{let{userAssetType:o,count:n}=t.payload.assetCount;e.assetCounts.allAsset[o]=n},clearAssetCount:e=>{Object.values(Se).forEach(t=>{e.assetCounts.allAsset[t]=void 0})},setBookmarkCountByMap:(e,t)=>{let o=t.payload.mapId;e.assetCounts.bookmarkByMap[o]=t.payload.count},clearBookmarkCountByMap:e=>{e.assetCounts.bookmarkByMap={}},addAsset:(e,t)=>{let{assetType:o,mapId:n,asset:a}=t.payload;Ua(e,o,[...Da(e,o),a]),L1(e,o,1,n),A1(e,a)},editAsset:(e,t)=>{let{assetType:o,asset:n}=t.payload;Ua(e,o,Da(e,o).map(a=>a.id===n.id?n:a)),A1(e,n)},removeAsset:(e,t)=>{let{assetType:o,mapId:n,assetId:a}=t.payload;Ua(e,o,Da(e,o).filter(i=>i.id!==a)),L1(e,o,-1,n)}},O1={[Se.SEARCHES]:"savedSearches",[Se.BOOKMARKS]:"bookmarks",[Se.BOOKS]:void 0,[Se.COLLECTIONS]:void 0},Da=(e,t)=>{var o;let n=O1[t];return n?(o=e[n])!==null&&o!==void 0?o:[]:[]},Ua=(e,t,o)=>{let n=O1[t];n&&(e[n]=o)},L1=(e,t,o,n)=>{let a=e.assetCounts.allAsset[t];if(a!==void 0&&(e.assetCounts.allAsset[t]=Math.max(0,a+o),t===Se.BOOKMARKS&&n)){let i=e.assetCounts.bookmarkByMap[n];e.assetCounts.bookmarkByMap[n]=Math.max(0,i+o)}},A1=(e,t)=>{let o=e.assetLabels.map(a=>a.title),n=t.labels.filter(a=>!o.includes(a)).map(a=>({title:a}));e.assetLabels.push(...n)},ne=Zo.FtReduxStore.get({name:Wf,reducers:jf,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(Se).map(e=>[e,void 0])),bookmarkByMap:{}},assetLabels:[]}}),Ba=class{constructor(t=new Vo,o=new Ko){this.assetCountsService=t,this.assetLabelsService=o,this.currentSession=D.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new jo,this.savedSearchesService=new Wo,D.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var t;let{session:o}=D.getState();(0,Zo.deepEqual)((t=this.currentSession)===null||t===void 0?void 0:t.profile,o?.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),ne.actions.clearAssetCount(),ne.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),ne.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),ne.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let t=await this.savedSearchesService.listMySearches();ne.actions.savedSearches(t)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let t=await this.assetLabelsService.getUserAssetLabels();ne.actions.assetLabels(t)}async loadAssetCount(t){let o=await this.assetCountsService.getUserAssetCount(t);o&&ne.getState().assetCounts.allAsset[t]!==o.count&&ne.actions.setAssetCount({assetCount:o})}async loadBookmarkByMapId(t){let o=await this.assetCountsService.getUserBookmarkCountByMap(t);o&&ne.getState().assetCounts.bookmarkByMap[t]!==o.count&&ne.actions.setBookmarkCountByMap({count:o.count,mapId:t})}async reloadAssetCount(t){this.assetCountsService.clearCache();let o=Object.keys(ne.getState().assetCounts.bookmarkByMap).length!==0;t===Se.BOOKMARKS&&o&&ne.actions.clearBookmarkCountByMap(),ne.getState().assetCounts.allAsset[t]!==void 0&&await this.loadAssetCount(t)}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var t;if(this.bookmarksAreUsed){let o=!((t=this.currentSession)===null||t===void 0)&&t.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;ne.actions.bookmarks(o)}}},Vf=new Ba;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=Vf);var Fa=class{addCommand(t,o=!1){D.commands.add(t,o)}consumeCommand(t){return D.commands.consume(t)}};window.FluidTopicsAppInfoStoreService=new Fa;var Ce=L(P());var R1,gr=class extends CustomEvent{constructor(t){super("ft-i18n-context-loaded",{detail:t})}},Kf=Symbol("clearAfterUnitTest"),qo=class extends(0,Ce.withEventBus)(pe){constructor(t){super(),this.messageContextProvider=t,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[R1]=()=>{this.defaultMessages={},this.cache=new Ce.CacheRegistry,this.listeners={}},this.currentUiLocale=D.getState().uiLocale,D.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:t}=D.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){let o=t.name.toLowerCase();this.cache.setFinal(o,t),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,o){var n;if(t=t.toLowerCase(),o&&Object.keys(o).length>0){let a={...(n=this.defaultMessages[t])!==null&&n!==void 0?n:{},...o};(0,Ce.deepEqual)(this.defaultMessages[t],a)||(this.defaultMessages[t]=a,await this.notify(t))}return this.fetchContext(t)}resolveContext(t){var o,n;return this.fetchContext(t),(n=(o=this.cache.getNow(t))===null||o===void 0?void 0:o.messages)!==null&&n!==void 0?n:{}}resolveRawMessage(t,o){let n=t.toLowerCase();return this.resolveContext(n)[o]}resolveMessage(t,o,...n){var a;let i=t.toLowerCase(),s=this.resolveContext(i);return new Ce.ParametrizedLabelResolver((a=this.defaultMessages[i])!==null&&a!==void 0?a:{},s).resolve(o,...n)}async fetchContext(t){let o=!this.cache.has(t),n;try{n=await this.cache.get(t,()=>this.messageContextProvider(this.currentUiLocale,t)),o&&await this.notify(t)}catch(a){!(a instanceof Ce.CanceledPromiseError)&&o&&console.error(a)}return n}subscribe(t,o){var n;return t=t.toLowerCase(),this.listeners[t]=(n=this.listeners[t])!==null&&n!==void 0?n:new Set,this.listeners[t].add(o),()=>{var a;return(a=this.listeners[t])===null||a===void 0?void 0:a.delete(o)}}async notifyAll(){let t=Object.keys(this.listeners);document.body.dispatchEvent(new gr({loadedContexts:t})),this.dispatchEvent(new gr({loadedContexts:t})),await Promise.all(t.map(o=>this.notify(o,!1)))}async notify(t,o=!0){o&&(document.body.dispatchEvent(new gr({loadedContexts:[t]})),this.dispatchEvent(new gr({loadedContexts:[t]}))),this.listeners[t]!=null&&await Promise.all([...this.listeners[t].values()].map(n=>(0,Ce.delay)(0).then(()=>n()).catch(()=>null)))}};R1=Kf;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends qo{constructor(){super(async(e,t)=>(await this.awaitApi).getFluidTopicsMessageContext(e,t))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends qo{constructor(){super(async(e,t)=>(await this.awaitApi).getCustomMessageContext(e,t))}});var Zr=window.FluidTopicsI18nService,Ga=window.FluidTopicsCustomI18nService;var w1=L(P()),Ha=class{highlightHtml(t,o,n){(0,w1.highlightHtml)(t,o,n)}};window.FluidTopicsHighlightHtmlService=new Ha;var N1=L(P());var $a=class{isDate(t){var o,n,a,i;return(i=(a=((n=(o=D.getState().metadataConfiguration)===null||o===void 0?void 0:o.descriptors)!==null&&n!==void 0?n:[]).find(l=>l.key===t))===null||a===void 0?void 0:a.date)!==null&&i!==void 0?i:!1}format(t,o){var n,a,i,s;if(t==null)return"";try{return N1.DateFormatter.format(t,(n=o?.locale)!==null&&n!==void 0?n:D.getState().uiLocale,(a=o?.longFormat)!==null&&a!==void 0?a:!1,(i=o?.withTime)!==null&&i!==void 0?i:!1,(s=o?.onlyTime)!==null&&s!==void 0?s:!1)}catch(l){throw console.error(`Date ${JSON.stringify(t)} is not valid`,l),l}}};window.FluidTopicsDateService=new $a;var _1=L(P());var qr=class{static get(t,o){var n,a;let i=D.getState(),{lang:s,region:l}=(a=(n=i.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&a!==void 0?a:{lang:"en",region:"US"};return new _1.SearchPlaceConverter(i.baseUrl,t??20,i.searchInAllLanguagesAllowed,o??`${s}-${l}`)}};var Wa=class{urlToSearchRequest(t){return qr.get().parse(t)}searchRequestToUrl(t){return qr.get().serialize(t)}};window.FluidTopicsUrlService=new Wa;var Xe=L(P());var zt=class e extends CustomEvent{constructor(t){super(e.eventName,{detail:{currentItem:t}})}};zt.eventName="change";var ja=class{itemName(t){return`fluid-topics-history-item-${t}`}get(t){let o=sessionStorage.getItem(this.itemName(t));return o?JSON.parse(o):void 0}set(t,o){sessionStorage.setItem(this.itemName(t),JSON.stringify(o))}},M1=new ja;var Yo=class e extends Xe.WithEventBus{static build(){return new e(window.history,M1,()=>window.location,!1)}constructor(t,o,n,a){var i,s;super(),this.history=t,this.historyStorage=o,this.windowLocation=n,this.states=[],this.realPushState=t.pushState,this.realReplaceState=t.replaceState,this.initialIndex=(s=(i=t.state)===null||i===void 0?void 0:i.index)!==null&&s!==void 0?s:t.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(a)}setCurrentState(t,o=!1){let n=o&&this.currentIndex===t.index-1;this.currentState={...this.buildCurrentState(),...t},this.currentIndex=this.currentState.index,this.states[this.currentIndex]=this.currentState,n&&(this.states=this.states.slice(0,this.currentIndex+1)),this.historyStorage.set(this.currentIndex,this.currentState),(0,Xe.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,window.location.href]),setTimeout(()=>this.dispatchEvent(new zt(this.currentItem())),0)}installProxies(){let t=o=>(n,a,[i,s,l])=>{let u=o(),p={...u===this.currentIndex?this.currentState:void 0,...i,index:u,href:typeof l=="string"?l:(l??this.windowLocation()).href};n.apply(a,[p,s,l]),this.setCurrentState(p,!0)};this.history.pushState=new Proxy(this.history.pushState,{apply:t(()=>this.currentIndex+1)}),this.history.replaceState=new Proxy(this.history.replaceState,{apply:t(()=>this.currentIndex)})}initEventListeners(){window.addEventListener("popstate",t=>this.setCurrentState(t.state)),document.querySelector("title")==null&&document.head.append(document.createElement("title")),new MutationObserver(()=>this.updateCurrentState({title:document.title})).observe(document.querySelector("title"),{subtree:!0,characterData:!0,childList:!0})}initData(t){for(let o=this.history.length-1;o>=0;o--)t?this.states[o]=this.historyStorage.get(o):setTimeout(()=>this.states[o]=this.historyStorage.get(o),this.history.length-o)}updateCurrentState(t){var o;let n={...this.buildCurrentState(),...t,index:this.currentIndex,title:(o=t?.title)!==null&&o!==void 0?o:this.currentState.title};this.setCurrentState(n)}addHistoryChangeListener(t){this.addEventListener(zt.eventName,t)}removeHistoryChangeListener(t){this.removeEventListener(zt.eventName,t)}currentItem(){return(0,Xe.deepCopy)(this.currentState)}back(){let t=this.previousDifferentMajorPosition();t>=0?this.history.go(t-this.currentIndex):this.currentIndex!==this.initialIndex?this.history.go(this.initialIndex-this.currentIndex):this.history.back()}backwardItem(){return(0,Xe.deepCopy)(this.states[this.previousDifferentMajorPosition()])}backwardItemMatching(t){let o=this.states.filter(n=>!!n).filter(n=>n.index<this.currentIndex).reverse();return(0,Xe.deepCopy)(o.find(n=>t(n)))}previousDifferentMajorPosition(){let t=this.currentIndex>0?this.currentIndex-1:0;for(;t>0&&!this.isDifferentMajorState(t);)t--;return t}forward(){let t=this.nextMajorPosition();t&&t<this.states.length?this.history.go(t-this.currentIndex):this.history.forward()}forwardItem(){let t=this.nextMajorPosition();if(t)return(0,Xe.deepCopy)(this.states[t])}nextMajorPosition(){let t=this.currentIndex;if(!(t>=this.states.length)){do t++;while(t<this.states.length&&!this.isDifferentMajorState(t));return this.getHigherPositionInTheSameState(t)}}getHigherPositionInTheSameState(t){var o;let n=(o=this.states[t])===null||o===void 0?void 0:o.majorStateId;if(!n)return t;let a=t,i=t+1;for(;this.states.length>i&&!this.isDifferentMajorState(i,n);)this.hasState(i)&&(a=i),i++;return a}buildCurrentState(){var t,o;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(o=(t=this.history.state)===null||t===void 0?void 0:t.title)!==null&&o!==void 0?o:document.title}}hasState(t){return this.states[t]!=null}isDifferentMajorState(t,o){var n;if(!this.hasState(t))return!1;let a=o??this.currentState.majorStateId,i=(n=this.states[t])===null||n===void 0?void 0:n.majorStateId;return i==null||i!=a}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=Yo.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),backwardItemMatching:e=>window.FluidTopicsInternalHistoryService.backwardItemMatching(e),addHistoryChangeListener:e=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(e),removeHistoryChangeListener:e=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(e)});var k1=L(K());var z1=k1.css`
1401
1401
  `;var P1=L(K()),he=L(oe()),Pt=L(P());var It=L(P());function I1(e,t){let{authenticationRequired:o,session:n}=D.getState();return o&&!n?.sessionAuthenticated?Promise.resolve(t):e()}var Xo=class extends mr{async updateUiLocale(t){return(await this.awaitApi).updateUiLocale(t)}};var Va=class e extends It.FtStateManager{static build(t){return new e(D,t)}constructor(t,o){super(),this.store=t,this.cache=new It.CacheRegistry,this.withManualResources=!0,this.localesConfiguration=null,this.userLocaleService=new Xo,this.cleanSessionDebouncer=new It.Debouncer,this.reloadDebouncer=new It.Debouncer(500),this.apiProvider=o??(()=>kt.get())}setWithManualResources(t){this.withManualResources=t,this.updateIfNeeded()}async initService(){this.store.addEventListener(hr.eventName,this.reloadConfiguration)}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.store.getState().session==null&&this.updateSession(),this.store.getState().metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration(),(this.store.getState().availableContentLocales==null||this.store.getState().availableContentLocales.length==0)&&this.updateAvailableContentLocales())}async updateSession(){let t=await this.cache.get("session",async()=>{let o=await this.apiProvider().getCurrentSession();return o.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.setSession(void 0)},o.idleTimeoutInMillis),o});this.setSession(t)}async updateMetadataConfiguration(){this.setMetadataConfiguration(await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration()))}async updateLocalesConfiguration(){this.setLocalesConfiguration(await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration()))}async updateAvailableContentLocales(){var t;let o=await this.cache.get("availableContentLocales",()=>I1(()=>this.apiProvider().getAvailableSearchLocales(),{contentLocales:[]}));this.setAvailableContentLocales((t=o.contentLocales)!==null&&t!==void 0?t:[])}reloadConfiguration(){var t;(t=this.cache)===null||t===void 0||t.clear("availableContentLocales"),typeof this.updateAvailableContentLocales=="function"&&this.updateAvailableContentLocales()}setBaseUrl(t){this.store.actions.baseUrl(t),window.fluidTopicsBaseUrl=t}setApiIntegrationIdentifier(t){this.store.actions.apiIntegrationIdentifier(t)}setApiIntegrationAppVersion(t){this.store.actions.apiIntegrationAppVersion(t)}setUiLocale(t){this.store.actions.uiLocale(t)}setLocalesConfiguration(t){var o,n,a,i,s;this.localesConfiguration=t,this.store.actions.defaultLocales(this.localesConfiguration.defaultLocales),this.store.actions.availableUiLocales((o=this.localesConfiguration.availableUiLocales)!==null&&o!==void 0?o:[]),this.store.actions.searchInAllLanguagesAllowed((n=this.localesConfiguration.allLanguagesAllowed)!==null&&n!==void 0?n:!1),this.store.actions.searchLanguageSetsUiLanguage((a=this.localesConfiguration.searchLanguageSetsUiLanguage)!==null&&a!==void 0?a:!1),this.store.actions.uiLanguageSetsSearchLanguage((i=this.localesConfiguration.uiLanguageSetsSearchLanguage)!==null&&i!==void 0?i:!1),this.store.actions.uiLanguageSetsReaderLanguage((s=this.localesConfiguration.uiLanguageSetsReaderLanguage)!==null&&s!==void 0?s:!1),setTimeout(()=>this.updateIfNeeded())}setAvailableContentLocales(t){this.store.actions.availableContentLocales(t),setTimeout(()=>this.updateIfNeeded())}stopReloadDebouncer(){this.reloadDebouncer.cancel()}requestUiLocaleUpdate(t){this.userLocaleService.updateUiLocale({uiLocale:t}).then(o=>{o.uiLocaleChanged&&(this.reloadDebouncer.run(()=>window.location.reload()),this.store.dispatchEvent(new Kr(o)))}).catch(()=>{})}setMetadataConfiguration(t){this.store.actions.metadataConfiguration(t),setTimeout(()=>this.updateIfNeeded())}setNoCustom(t){this.store.actions.noCustom(t)}setEditorMode(t){this.store.actions.editorMode(t)}setNoCustomComponent(t){this.store.actions.noCustomComponent(t)}setSession(t){this.store.actions.session(t),setTimeout(()=>this.updateIfNeeded())}setOpenExternalDocumentInNewTab(t){this.store.actions.openExternalDocumentInNewTab(t)}setNavigatorOnline(t){this.store.actions.navigatorOnline(t)}setForcedOffline(t){this.store.actions.forcedOffline(t)}setAuthenticationRequired(t){this.store.actions.authenticationRequired(t)}},T1=Va.build();var Tt=class extends Event{constructor(t,o,n,a){super("context-request",{bubbles:!0,composed:!0}),this.context=t,this.contextTarget=o,this.callback=n,this.subscribe=a??!1}};var Yr=class{constructor(){this.pendingContextRequests=new Map,this.onContextProvider=t=>{let o=this.pendingContextRequests.get(t.context);if(o===void 0)return;this.pendingContextRequests.delete(t.context);let{requests:n}=o;for(let{elementRef:a,callbackRef:i}of n){let s=a.deref(),l=i.deref();s===void 0||l===void 0||s.dispatchEvent(new Tt(t.context,s,l,!0))}},this.onContextRequest=t=>{if(t.subscribe!==!0)return;let o=t.contextTarget??t.composedPath()[0],n=t.callback,a=this.pendingContextRequests.get(t.context);a===void 0&&this.pendingContextRequests.set(t.context,a={callbacks:new WeakMap,requests:[]});let i=a.callbacks.get(o);i===void 0&&a.callbacks.set(o,i=new WeakSet),i.has(n)||(i.add(n),a.requests.push({elementRef:new WeakRef(o),callbackRef:new WeakRef(n)}))}}attach(t){t.addEventListener("context-request",this.onContextRequest),t.addEventListener("context-provider",this.onContextProvider)}detach(t){t.removeEventListener("context-request",this.onContextRequest),t.removeEventListener("context-provider",this.onContextProvider)}};var re=function(e,t,o,n){var a=arguments.length,i=a<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(e,t,o,n);else for(var l=e.length-1;l>=0;l--)(s=e[l])&&(i=(a<3?s(i):a>3?s(t,o,i):s(t,o))||i);return a>3&&i&&Object.defineProperty(t,o,i),i},V=class extends Pt.FtLitElementRedux{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.apiIntegrationAppVersion="ft-integration-app-version",this.uiLocale="en-US",this.editorMode=!1,this.noCustom=!1,this.openExternalDocumentInNewTab=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.navigatorOnline=!1,this.forcedOffline=!1,this.authenticationRequired=!1,this.messageContexts=[],this.stateManager=T1,this.contextRoot=new Yr}render(){return P1.html`
1402
1402
  <slot></slot>
1403
1403
  `}connectedCallback(){super.connectedCallback(),this.stateManager.initService(),this.contextRoot.attach(document.body)}disconnectedCallback(){super.disconnectedCallback(),this.contextRoot.detach(document.body)}update(t){var o;super.update(t),t.has("baseUrl")&&this.stateManager.setBaseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&this.stateManager.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("apiIntegrationAppVersion")&&this.stateManager.setApiIntegrationAppVersion(this.apiIntegrationAppVersion),t.has("uiLocale")&&this.stateManager.setUiLocale(this.uiLocale),t.has("metadataConfiguration")&&this.stateManager.setMetadataConfiguration(this.metadataConfiguration),t.has("noCustom")&&this.stateManager.setNoCustom(this.noCustom),t.has("editorMode")&&this.stateManager.setEditorMode(this.editorMode),t.has("noCustomComponent")&&this.stateManager.setNoCustomComponent(this.noCustomComponent),t.has("session")&&this.stateManager.setSession(this.session),t.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(n=>Zr.addContext(n)),t.has("openExternalDocumentInNewTab")&&this.stateManager.setOpenExternalDocumentInNewTab(this.openExternalDocumentInNewTab),t.has("navigatorOnline")&&this.stateManager.setNavigatorOnline(this.navigatorOnline),t.has("forcedOffline")&&this.stateManager.setForcedOffline(this.forcedOffline),t.has("authenticationRequired")&&this.stateManager.setAuthenticationRequired(this.authenticationRequired),t.has("withManualResources")&&((o=this.stateManager)===null||o===void 0||o.setWithManualResources(this.withManualResources)),setTimeout(()=>this.stateManager.updateIfNeeded())}};V.elementDefinitions={};V.styles=z1;re([(0,he.property)()],V.prototype,"baseUrl",void 0);re([(0,he.property)()],V.prototype,"apiIntegrationIdentifier",void 0);re([(0,he.property)()],V.prototype,"apiIntegrationAppVersion",void 0);re([(0,he.property)()],V.prototype,"uiLocale",void 0);re([(0,Pt.jsonProperty)(null)],V.prototype,"availableUiLocales",void 0);re([(0,Pt.jsonProperty)(null)],V.prototype,"metadataConfiguration",void 0);re([(0,he.property)({type:Boolean})],V.prototype,"editorMode",void 0);re([(0,he.property)({type:Boolean})],V.prototype,"noCustom",void 0);re([(0,he.property)({type:Boolean})],V.prototype,"openExternalDocumentInNewTab",void 0);re([(0,he.property)({converter:{fromAttribute(e){return e==="false"?!1:e==="true"||(e??!1)}}})],V.prototype,"noCustomComponent",void 0);re([(0,he.property)({type:Boolean})],V.prototype,"withManualResources",void 0);re([(0,he.property)({type:Boolean})],V.prototype,"navigatorOnline",void 0);re([(0,he.property)({type:Boolean})],V.prototype,"forcedOffline",void 0);re([(0,he.property)({type:Boolean})],V.prototype,"authenticationRequired",void 0);re([(0,Pt.jsonProperty)([])],V.prototype,"messageContexts",void 0);re([(0,Pt.jsonProperty)(void 0)],V.prototype,"session",void 0);var U1=L(P());var D1={"ft-app-context":V};(0,U1.customElements)(D1);var B1=L(oe());var Ka=class{fromLocalizableLabel(t){return t.type=="PLAIN_TEXT"?{message:t.text}:{key:t.key,custom:t.type=="LOCALIZED_CUSTOM",context:t.context,message:t.key}}fromAttribute(t){if(t!=null)try{return JSON.parse(t)}catch{if(this.isI18nKey(t)){let[o,n]=t.split(".");return{context:o,key:n,custom:o!=="officialContext",message:""}}return{message:t}}}toAttribute(t){if(t!=null)return JSON.stringify(t)}isI18nKey(t){return t.match(/^[\w-]+\.[\w-]+$/)}},yr=new Ka;var Yf=function(e,t,o,n){var a=arguments.length,i=a<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,o):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(e,t,o,n);else for(var l=e.length-1;l>=0;l--)(s=e[l])&&(i=(a<3?s(i):a>3?s(t,o,i):s(t,o))||i);return a>3&&i&&Object.defineProperty(t,o,i),i},Qr=Symbol("i18nAttributes"),F1=Symbol("i18nListAttributes"),G1=Symbol("i18nProperties"),Qo=Symbol("i18nContexts"),Xr=Symbol("i18nUnsubs"),H1=(0,br.applyMixinOnce)(Symbol("withI18n"),function(e){var t,o;class n extends e{constructor(){super(...arguments),this.useCustomMessageContexts=!1,this[t]=new Map,this[o]=new Map}getI18nService(i){return i??this.useCustomMessageContexts?Ga:Zr}i18n(i){let{context:s,key:l,message:u}=i,{custom:p,args:m,argsProvider:g}=i;if(s&&l){this.hasI18nContext(s)||this.addI18nContext(s,void 0,p);let y=m??(g?g(this):[]);return this.getI18nService(p).resolveMessage(s,l,...y)}return u}async awaitI18n(i){let{context:s,custom:l}=i;return s&&await this.getI18nService(l).prepareContext(s),this.i18n(i)}customI18n(i,s){if(yr.isI18nKey(i)){let[l,u]=i.split(".");return this.i18n({custom:!0,context:l,key:u,...s})||i}return i}firstUpdated(i){super.firstUpdated(i),this.updateI18nAttributes(()=>!0),this.updateI18nProperties(()=>!0)}update(i){super.update(i),this.updateI18nAttributes((s,l,u)=>i.has(l)||typeof s.argsProvider=="function"),this.updateI18nProperties(s=>typeof s.argsProvider=="function")}onI18nUpdate(i){this.updateI18nAttributes((s,l,u)=>{var p;return((p=u?.context)===null||p===void 0?void 0:p.toLowerCase())===i}),this.updateI18nProperties(s=>s.context.toLowerCase()===i),this.requestUpdate()}updateI18nAttributes(i){var s,l;let u=this,p=(m,g,y)=>y?.context&&y.key&&i(m,g,y)?{...y,message:this.i18n({context:y.context,key:y.key,custom:y.custom,...m})}:y;(s=this[Qr])===null||s===void 0||s.forEach((m,g)=>u[g]=p(m,g,u[g])),(l=this[F1])===null||l===void 0||l.forEach((m,g)=>{var y;return u[g]=(y=u[g])===null||y===void 0?void 0:y.map(v=>p(m,g,v))})}updateI18nProperties(i){var s;(s=this[G1])===null||s===void 0||s.forEach((l,u)=>{i(l,u)&&(this[u]=this.i18n(l))})}addI18nMessages(i,s,l){console.warn('Deprecated usage of method "addI18nMessages", use "addI18nContext" instead.'),this.addI18nContext(i,s,l)}addI18nContext(i,s,l){let u=(typeof i=="string"?i:i.name).toLowerCase();l=typeof i=="string"?l:i.custom,this[Qo].set(u,{isCustomContext:l}),this[Xr].has(u)||this[Xr].set(u,this.getI18nService(l).subscribe(u,()=>this.onI18nUpdate(u))),this.getI18nService(l).prepareContext(u,s)}hasI18nContext(i){return this[Qo].has(i.toLowerCase())}connectedCallback(){super.connectedCallback(),this[Qo].forEach((i,s)=>this.addI18nContext(s,void 0,i.isCustomContext))}disconnectedCallback(){super.disconnectedCallback(),this[Xr].forEach(i=>i()),this[Xr].clear()}}return t=Qo,o=Xr,Yf([(0,B1.property)({type:Boolean})],n.prototype,"useCustomMessageContexts",void 0),n}),Jo=class extends H1(br.FtLitElement){},en=class extends H1(br.FtLitElementRedux){};var $1=L(P());var Za=class{fromAttribute(t){if(!t)return[];try{let o=JSON.parse(t);return Array.isArray(o)?o.map(n=>typeof n=="string"?yr.fromAttribute(n):n):[]}catch{return[]}}toAttribute(t){if(t!=null)return JSON.stringify(t)}},Xf=new Za;var W1=(e,t)=>(o,n)=>{var a;o.constructor.createProperty(n,{type:Object,hasChanged:$1.hasChanged,converter:yr,...t}),o[Qr]=(a=o[Qr])!==null&&a!==void 0?a:new Map,o[Qr].set(n,e??{})};var j1=L(K());var V1=j1.css`
@@ -44,7 +44,7 @@ Also for action icons.`,l.colorGray200),contentGlobalSubtle:n.extend("--ftds-con
44
44
  input::-webkit-search-results-decoration {
45
45
  display: none;
46
46
  }
47
- `;var yl={};var hi={};W(hi,{ParametrizedLabelResolver:()=>po});var po=class t{constructor(e,r){this.defaultLabels=e,this.labels=r}resolve(e,...r){var o,a;e=this.resolvePluralKey(e,r);let i=(a=(o=this.labels[e])!==null&&o!==void 0?o:this.defaultLabels[e])!==null&&a!==void 0?a:"";return t.replaceParameters(i,...r)}static replaceParameters(e,...r){return r.forEach((o,a)=>e=e.replace(new RegExp(`\\{${a}([^}]*)\\}`,"g"),(i,s)=>t.formatValue(o,s))),e}resolvePluralKey(e,r){for(let o of r)if(typeof o=="number"){let a=`${String(e)}[\\=${o}]`;if(a in this.labels||a in this.defaultLabels)return a}return e}static formatValue(e,r){return e instanceof Date?t.formatDate(e,r):e??""}static formatDate(e,r){let o=a=>r?.includes("date")?e.toLocaleDateString(a):r?.includes("time")?e.toLocaleTimeString(a):e.toLocaleString(a);try{return o(document.documentElement.lang)}catch{return o()}}};var Ui={};W(Ui,{FtCommandQueue:()=>ho,FtLitElementRedux:()=>Ht,FtReduxStore:()=>jt,FtStateManager:()=>vo,ReduxWatcher:()=>fn,clearAllStores:()=>ef,isFtReduxStore:()=>mr,redux:()=>hr,reduxEventListener:()=>yu,reduxReactive:()=>gu,watch:()=>tf,withRedux:()=>bl});var gu=()=>(t,e)=>{var r;let o=t.constructor;o.reduxReactiveProperties=new Set(o.reduxReactiveProperties),(r=o.reduxReactiveProperties)===null||r===void 0||r.add(e)},hr=t=>{let e=t??{};return(r,o)=>{var a;let i={hasChanged:ot,attribute:!1,...e};L(i)(r,o);let s=r.constructor;s.reduxProperties=new Map(s.reduxProperties),s.reduxProperties.set(o,{selector:(a=e.selector)!==null&&a!==void 0?a:(c=>c[o]),store:e.store})}},yu=t=>(e,r)=>{let o=e.constructor;o.reduxEventListeners=new Map(o.reduxEventListeners),o.reduxEventListeners.set(r,t)};var ho=class{constructor(){this.queue=[]}add(e,r=!1){r&&this.clear(e.type),this.queue.push(e)}consume(e){let r=this.queue.find(o=>o.type===e);return r&&(this.queue=this.queue.filter(o=>o!==r)),r}clear(e){typeof e=="string"?this.queue=this.queue.filter(r=>r.type!==e):this.queue=this.queue.filter(r=>!e.test(r.type))}};function mr(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var mo=Symbol("internalReduxEventsUnsubscribers"),yt=Symbol("internalStoresUnsubscribers"),Bt=Symbol("internalStores"),bl=de(Symbol("withRedux"),function(t){var e,r,o;class a extends t{constructor(){super(...arguments),this[e]=new Map,this[r]=new Map,this[o]=new Map}get reduxConstructor(){return this.constructor}willUpdate(s){super.willUpdate(s),[...this.reduxConstructor.reduxReactiveProperties].some(c=>s.has(c))&&this.updateFromStores()}getUnnamedStore(){if(this[Bt].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Bt].values()][0]}getStore(s){return s==null?this.getUnnamedStore():this[Bt].get(s)}addStore(s,c){var d;c=(d=c??s.name)!==null&&d!==void 0?d:"default-store",this.unsubscribeFromStore(c),this[Bt].set(c,s),this.subscribeToStore(c,s),this.updateFromStores()}removeStore(s){let c=typeof s=="string"?s:s.name;this.unsubscribeFromStore(c),this[Bt].delete(c)}setupStores(){this.unsubscribeFromStores(),this[Bt].forEach((s,c)=>this.subscribeToStore(c,s)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((s,c)=>{let d=this.constructor.getPropertyOptions(c);if(!d?.attribute||!this.hasAttribute(typeof d?.attribute=="string"?d.attribute:c)){let u=this.getStore(s.store);u&&(s.store?this[yt].has(s.store):this[yt].size>0)&&(this[c]=s.selector(u.getState(),this))}})}subscribeToStore(s,c){var d;this[yt].set(s,c.subscribe(()=>this.updateFromStores())),this[mo].set(s,[]),mr(c)&&c.eventBus&&((d=this.reduxConstructor.reduxEventListeners)===null||d===void 0||d.forEach((u,m)=>{if(typeof this[m]=="function"&&(!u.store||c.name===u.store)){let h=y=>this[m](y);c.addEventListener(u.eventName,h),this[mo].get(s).push(()=>c.removeEventListener(u.eventName,h))}})),this.onStoreAvailable(s)}unsubscribeFromStores(){this[yt].forEach((s,c)=>this.unsubscribeFromStore(c))}unsubscribeFromStore(s){var c;this[yt].has(s)&&this[yt].get(s)(),this[yt].delete(s),(c=this[mo].get(s))===null||c===void 0||c.forEach(d=>d()),this[mo].delete(s)}onStoreAvailable(s){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return e=yt,r=Bt,o=mo,a.reduxProperties=new Map,a.reduxReactiveProperties=new Set,a.reduxEventListeners=new Map,a}),Ht=class extends bl(q){};function Ie(t){for(var e=arguments.length,r=Array(e>1?e-1:0),o=1;o<e;o++)r[o-1]=arguments[o];if(0)var a,i;throw Error("[Immer] minified error nr: "+t+(r.length?" "+r.map((function(s){return"'"+s+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function st(t){return!!t&&!!t[J]}function $e(t){var e;return!!t&&((function(r){if(!r||typeof r!="object")return!1;var o=Object.getPrototypeOf(r);if(o===null)return!0;var a=Object.hasOwnProperty.call(o,"constructor")&&o.constructor;return a===Object||typeof a=="function"&&Function.toString.call(a)===Lu})(t)||Array.isArray(t)||!!t[Ll]||!!(!((e=t.constructor)===null||e===void 0)&&e[Ll])||Ei(t)||Ai(t))}function Gt(t,e,r){r===void 0&&(r=!1),br(t)===0?(r?Object.keys:yr)(t).forEach((function(o){r&&typeof o=="symbol"||e(o,t[o],t)})):t.forEach((function(o,a){return e(a,o,t)}))}function br(t){var e=t[J];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:Ei(t)?2:Ai(t)?3:0}function gr(t,e){return br(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function bu(t,e){return br(t)===2?t.get(e):t[e]}function Ol(t,e,r){var o=br(t);o===2?t.set(e,r):o===3?t.add(r):t[e]=r}function Rl(t,e){return t===e?t!==0||1/t==1/e:t!=t&&e!=e}function Ei(t){return Eu&&t instanceof Map}function Ai(t){return Au&&t instanceof Set}function bt(t){return t.o||t.t}function Li(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=Nl(t);delete e[J];for(var r=yr(e),o=0;o<r.length;o++){var a=r[o],i=e[a];i.writable===!1&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(e[a]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[a]})}return Object.create(Object.getPrototypeOf(t),e)}function Oi(t,e){return e===void 0&&(e=!1),Ri(t)||st(t)||!$e(t)||(br(t)>1&&(t.set=t.add=t.clear=t.delete=vu),Object.freeze(t),e&&Gt(t,(function(r,o){return Oi(o,!0)}),!0)),t}function vu(){Ie(2)}function Ri(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function Qe(t){var e=Ci[t];return e||Ie(18,t),e}function xu(t,e){Ci[t]||(Ci[t]=e)}function vi(){return yo}function mi(t,e){e&&(Qe("Patches"),t.u=[],t.s=[],t.v=e)}function sn(t){xi(t),t.p.forEach(Su),t.p=null}function xi(t){t===yo&&(yo=t.l)}function vl(t){return yo={p:[],l:yo,h:t,m:!0,_:0}}function Su(t){var e=t[J];e.i===0||e.i===1?e.j():e.g=!0}function gi(t,e){e._=e.p.length;var r=e.p[0],o=t!==void 0&&t!==r;return e.h.O||Qe("ES5").S(e,t,o),o?(r[J].P&&(sn(e),Ie(4)),$e(t)&&(t=cn(e,t),e.l||ln(e,t)),e.u&&Qe("Patches").M(r[J].t,t,e.u,e.s)):t=cn(e,r,[]),sn(e),e.u&&e.v(e.u,e.s),t!==_l?t:void 0}function cn(t,e,r){if(Ri(e))return e;var o=e[J];if(!o)return Gt(e,(function(c,d){return xl(t,o,e,c,d,r)}),!0),e;if(o.A!==t)return e;if(!o.P)return ln(t,o.t,!0),o.t;if(!o.I){o.I=!0,o.A._--;var a=o.i===4||o.i===5?o.o=Li(o.k):o.o,i=a,s=!1;o.i===3&&(i=new Set(a),a.clear(),s=!0),Gt(i,(function(c,d){return xl(t,o,a,c,d,r,s)})),ln(t,a,!1),r&&t.u&&Qe("Patches").N(o,r,t.u,t.s)}return o.o}function xl(t,e,r,o,a,i,s){if(st(a)){var c=cn(t,a,i&&e&&e.i!==3&&!gr(e.R,o)?i.concat(o):void 0);if(Ol(r,o,c),!st(c))return;t.m=!1}else s&&r.add(a);if($e(a)&&!Ri(a)){if(!t.h.D&&t._<1)return;cn(t,a),e&&e.A.l||ln(t,a)}}function ln(t,e,r){r===void 0&&(r=!1),!t.l&&t.h.D&&t.m&&Oi(e,r)}function yi(t,e){var r=t[J];return(r?bt(r):t)[e]}function Sl(t,e){if(e in t)for(var r=Object.getPrototypeOf(t);r;){var o=Object.getOwnPropertyDescriptor(r,e);if(o)return o;r=Object.getPrototypeOf(r)}}function vt(t){t.P||(t.P=!0,t.l&&vt(t.l))}function bi(t){t.o||(t.o=Li(t.t))}function Si(t,e,r){var o=Ei(e)?Qe("MapSet").F(e,r):Ai(e)?Qe("MapSet").T(e,r):t.O?(function(a,i){var s=Array.isArray(a),c={i:s?1:0,A:i?i.A:vi(),P:!1,I:!1,R:{},l:i,t:a,k:null,o:null,j:null,C:!1},d=c,u=bo;s&&(d=[c],u=go);var m=Proxy.revocable(d,u),h=m.revoke,y=m.proxy;return c.k=y,c.j=h,y})(e,r):Qe("ES5").J(e,r);return(r?r.A:vi()).p.push(o),o}function Cu(t){return st(t)||Ie(22,t),(function e(r){if(!$e(r))return r;var o,a=r[J],i=br(r);if(a){if(!a.P&&(a.i<4||!Qe("ES5").K(a)))return a.t;a.I=!0,o=Cl(r,i),a.I=!1}else o=Cl(r,i);return Gt(o,(function(s,c){a&&bu(a.t,s)===c||Ol(o,s,e(c))})),i===3?new Set(o):o})(t)}function Cl(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return Li(t)}function wl(){function t(s,c){var d=i[s];return d?d.enumerable=c:i[s]=d={configurable:!0,enumerable:c,get:function(){var u=this[J];return bo.get(u,s)},set:function(u){var m=this[J];bo.set(m,s,u)}},d}function e(s){for(var c=s.length-1;c>=0;c--){var d=s[c][J];if(!d.P)switch(d.i){case 5:o(d)&&vt(d);break;case 4:r(d)&&vt(d)}}}function r(s){for(var c=s.t,d=s.k,u=yr(d),m=u.length-1;m>=0;m--){var h=u[m];if(h!==J){var y=c[h];if(y===void 0&&!gr(c,h))return!0;var b=d[h],x=b&&b[J];if(x?x.t!==y:!Rl(b,y))return!0}}var C=!!c[J];return u.length!==yr(c).length+(C?0:1)}function o(s){var c=s.k;if(c.length!==s.t.length)return!0;var d=Object.getOwnPropertyDescriptor(c,c.length-1);if(d&&!d.get)return!0;for(var u=0;u<c.length;u++)if(!c.hasOwnProperty(u))return!0;return!1}function a(s){s.g&&Ie(3,JSON.stringify(bt(s)))}var i={};xu("ES5",{J:function(s,c){var d=Array.isArray(s),u=(function(h,y){if(h){for(var b=Array(y.length),x=0;x<y.length;x++)Object.defineProperty(b,""+x,t(x,!0));return b}var C=Nl(y);delete C[J];for(var O=yr(C),w=0;w<O.length;w++){var N=O[w];C[N]=t(N,h||!!C[N].enumerable)}return Object.create(Object.getPrototypeOf(y),C)})(d,s),m={i:d?5:4,A:c?c.A:vi(),P:!1,I:!1,R:{},l:c,t:s,k:u,o:null,g:!1,C:!1};return Object.defineProperty(u,J,{value:m,writable:!0}),u},S:function(s,c,d){d?st(c)&&c[J].A===s&&e(s.p):(s.u&&(function u(m){if(m&&typeof m=="object"){var h=m[J];if(h){var y=h.t,b=h.k,x=h.R,C=h.i;if(C===4)Gt(b,(function(S){S!==J&&(y[S]!==void 0||gr(y,S)?x[S]||u(b[S]):(x[S]=!0,vt(h)))})),Gt(y,(function(S){b[S]!==void 0||gr(b,S)||(x[S]=!1,vt(h))}));else if(C===5){if(o(h)&&(vt(h),x.length=!0),b.length<y.length)for(var O=b.length;O<y.length;O++)x[O]=!1;else for(var w=y.length;w<b.length;w++)x[w]=!0;for(var N=Math.min(b.length,y.length),E=0;E<N;E++)b.hasOwnProperty(E)||(x[E]=!0),x[E]===void 0&&u(b[E])}}}})(s.p[0]),e(s.p))},K:function(s){return s.i===4?r(s):o(s)}})}var El,yo,wi=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",Eu=typeof Map<"u",Au=typeof Set<"u",Al=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",_l=wi?Symbol.for("immer-nothing"):((El={})["immer-nothing"]=!0,El),Ll=wi?Symbol.for("immer-draftable"):"__$immer_draftable",J=wi?Symbol.for("immer-state"):"__$immer_state";var Lu=""+Object.prototype.constructor,yr=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,Nl=Object.getOwnPropertyDescriptors||function(t){var e={};return yr(t).forEach((function(r){e[r]=Object.getOwnPropertyDescriptor(t,r)})),e},Ci={},bo={get:function(t,e){if(e===J)return t;var r=bt(t);if(!gr(r,e))return(function(a,i,s){var c,d=Sl(i,s);return d?"value"in d?d.value:(c=d.get)===null||c===void 0?void 0:c.call(a.k):void 0})(t,r,e);var o=r[e];return t.I||!$e(o)?o:o===yi(t.t,e)?(bi(t),t.o[e]=Si(t.A.h,o,t)):o},has:function(t,e){return e in bt(t)},ownKeys:function(t){return Reflect.ownKeys(bt(t))},set:function(t,e,r){var o=Sl(bt(t),e);if(o?.set)return o.set.call(t.k,r),!0;if(!t.P){var a=yi(bt(t),e),i=a?.[J];if(i&&i.t===r)return t.o[e]=r,t.R[e]=!1,!0;if(Rl(r,a)&&(r!==void 0||gr(t.t,e)))return!0;bi(t),vt(t)}return t.o[e]===r&&(r!==void 0||e in t.o)||Number.isNaN(r)&&Number.isNaN(t.o[e])||(t.o[e]=r,t.R[e]=!0),!0},deleteProperty:function(t,e){return yi(t.t,e)!==void 0||e in t.t?(t.R[e]=!1,bi(t),vt(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var r=bt(t),o=Reflect.getOwnPropertyDescriptor(r,e);return o&&{writable:!0,configurable:t.i!==1||e!=="length",enumerable:o.enumerable,value:r[e]}},defineProperty:function(){Ie(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){Ie(12)}},go={};Gt(bo,(function(t,e){go[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}})),go.deleteProperty=function(t,e){return go.set.call(this,t,e,void 0)},go.set=function(t,e,r){return bo.set.call(this,t[0],e,r,t[0])};var Ou=(function(){function t(r){var o=this;this.O=Al,this.D=!0,this.produce=function(a,i,s){if(typeof a=="function"&&typeof i!="function"){var c=i;i=a;var d=o;return function(C){var O=this;C===void 0&&(C=c);for(var w=arguments.length,N=Array(w>1?w-1:0),E=1;E<w;E++)N[E-1]=arguments[E];return d.produce(C,(function(S){var A;return(A=i).call.apply(A,[O,S].concat(N))}))}}var u;if(typeof i!="function"&&Ie(6),s!==void 0&&typeof s!="function"&&Ie(7),$e(a)){var m=vl(o),h=Si(o,a,void 0),y=!0;try{u=i(h),y=!1}finally{y?sn(m):xi(m)}return typeof Promise<"u"&&u instanceof Promise?u.then((function(C){return mi(m,s),gi(C,m)}),(function(C){throw sn(m),C})):(mi(m,s),gi(u,m))}if(!a||typeof a!="object"){if((u=i(a))===void 0&&(u=a),u===_l&&(u=void 0),o.D&&Oi(u,!0),s){var b=[],x=[];Qe("Patches").M(a,u,b,x),s(b,x)}return u}Ie(21,a)},this.produceWithPatches=function(a,i){if(typeof a=="function")return function(u){for(var m=arguments.length,h=Array(m>1?m-1:0),y=1;y<m;y++)h[y-1]=arguments[y];return o.produceWithPatches(u,(function(b){return a.apply(void 0,[b].concat(h))}))};var s,c,d=o.produce(a,i,(function(u,m){s=u,c=m}));return typeof Promise<"u"&&d instanceof Promise?d.then((function(u){return[u,s,c]})):[d,s,c]},typeof r?.useProxies=="boolean"&&this.setUseProxies(r.useProxies),typeof r?.autoFreeze=="boolean"&&this.setAutoFreeze(r.autoFreeze)}var e=t.prototype;return e.createDraft=function(r){$e(r)||Ie(8),st(r)&&(r=Cu(r));var o=vl(this),a=Si(this,r,void 0);return a[J].C=!0,xi(o),a},e.finishDraft=function(r,o){var a=r&&r[J],i=a.A;return mi(i,o),gi(void 0,i)},e.setAutoFreeze=function(r){this.D=r},e.setUseProxies=function(r){r&&!Al&&Ie(20),this.O=r},e.applyPatches=function(r,o){var a;for(a=o.length-1;a>=0;a--){var i=o[a];if(i.path.length===0&&i.op==="replace"){r=i.value;break}}a>-1&&(o=o.slice(a+1));var s=Qe("Patches").$;return st(r)?s(r,o):this.produce(r,(function(c){return s(c,o)}))},t})(),Re=new Ou,Ru=Re.produce,Ig=Re.produceWithPatches.bind(Re),Pg=Re.setAutoFreeze.bind(Re),zg=Re.setUseProxies.bind(Re),Dg=Re.applyPatches.bind(Re),Ug=Re.createDraft.bind(Re),Fg=Re.finishDraft.bind(Re),dn=Ru;function Wt(t){"@babel/helpers - typeof";return Wt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Wt(t)}function Ml(t,e){if(Wt(t)!="object"||!t)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var o=r.call(t,e||"default");if(Wt(o)!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Tl(t){var e=Ml(t,"string");return Wt(e)=="symbol"?e:e+""}function kl(t,e,r){return(e=Tl(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Il(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter(function(a){return Object.getOwnPropertyDescriptor(t,a).enumerable})),r.push.apply(r,o)}return r}function _i(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?Il(Object(r),!0).forEach(function(o){kl(t,o,r[o])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Il(Object(r)).forEach(function(o){Object.defineProperty(t,o,Object.getOwnPropertyDescriptor(r,o))})}return t}function pe(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}var Pl=(function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"})(),Ni=function(){return Math.random().toString(36).substring(7).split("").join(".")},un={INIT:"@@redux/INIT"+Ni(),REPLACE:"@@redux/REPLACE"+Ni(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Ni()}};function wu(t){if(typeof t!="object"||t===null)return!1;for(var e=t;Object.getPrototypeOf(e)!==null;)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}function Mi(t,e,r){var o;if(typeof e=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(pe(0));if(typeof e=="function"&&typeof r>"u"&&(r=e,e=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(pe(1));return r(Mi)(t,e)}if(typeof t!="function")throw new Error(pe(2));var a=t,i=e,s=[],c=s,d=!1;function u(){c===s&&(c=s.slice())}function m(){if(d)throw new Error(pe(3));return i}function h(C){if(typeof C!="function")throw new Error(pe(4));if(d)throw new Error(pe(5));var O=!0;return u(),c.push(C),function(){if(O){if(d)throw new Error(pe(6));O=!1,u();var N=c.indexOf(C);c.splice(N,1),s=null}}}function y(C){if(!wu(C))throw new Error(pe(7));if(typeof C.type>"u")throw new Error(pe(8));if(d)throw new Error(pe(9));try{d=!0,i=a(i,C)}finally{d=!1}for(var O=s=c,w=0;w<O.length;w++){var N=O[w];N()}return C}function b(C){if(typeof C!="function")throw new Error(pe(10));a=C,y({type:un.REPLACE})}function x(){var C,O=h;return C={subscribe:function(N){if(typeof N!="object"||N===null)throw new Error(pe(11));function E(){N.next&&N.next(m())}E();var S=O(E);return{unsubscribe:S}}},C[Pl]=function(){return this},C}return y({type:un.INIT}),o={dispatch:y,subscribe:h,getState:m,replaceReducer:b},o[Pl]=x,o}function _u(t){Object.keys(t).forEach(function(e){var r=t[e],o=r(void 0,{type:un.INIT});if(typeof o>"u")throw new Error(pe(12));if(typeof r(void 0,{type:un.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(pe(13))})}function zl(t){for(var e=Object.keys(t),r={},o=0;o<e.length;o++){var a=e[o];typeof t[a]=="function"&&(r[a]=t[a])}var i=Object.keys(r),s,c;try{_u(r)}catch(d){c=d}return function(u,m){if(u===void 0&&(u={}),c)throw c;if(0)var h;for(var y=!1,b={},x=0;x<i.length;x++){var C=i[x],O=r[C],w=u[C],N=O(w,m);if(typeof N>"u"){var E=m&&m.type;throw new Error(pe(14))}b[C]=N,y=y||N!==w}return y=y||i.length!==Object.keys(u).length,y?b:u}}function vr(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return e.length===0?function(o){return o}:e.length===1?e[0]:e.reduce(function(o,a){return function(){return o(a.apply(void 0,arguments))}})}function Dl(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return function(o){return function(){var a=o.apply(void 0,arguments),i=function(){throw new Error(pe(15))},s={getState:a.getState,dispatch:function(){return i.apply(void 0,arguments)}},c=e.map(function(d){return d(s)});return i=vr.apply(void 0,c)(a.dispatch),_i(_i({},a),{},{dispatch:i})}}}function Ul(t){var e=function(o){var a=o.dispatch,i=o.getState;return function(s){return function(c){return typeof c=="function"?c(a,i,t):s(c)}}};return e}var Fl=Ul();Fl.withExtraArgument=Ul;var Ti=Fl;var Wl=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,a){o.__proto__=a}||function(o,a){for(var i in a)Object.prototype.hasOwnProperty.call(a,i)&&(o[i]=a[i])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function o(){this.constructor=e}e.prototype=r===null?Object.create(r):(o.prototype=r.prototype,new o)}})(),Nu=function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},o,a,i,s;return s={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function c(u){return function(m){return d([u,m])}}function d(u){if(o)throw new TypeError("Generator is already executing.");for(;r;)try{if(o=1,a&&(i=u[0]&2?a.return:u[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,u[1])).done)return i;switch(a=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,a=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){r.label=u[1];break}if(u[0]===6&&r.label<i[1]){r.label=i[1],i=u;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(u);break}i[2]&&r.ops.pop(),r.trys.pop();continue}u=e.call(t,r)}catch(m){u=[6,m],a=0}finally{o=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},xr=function(t,e){for(var r=0,o=e.length,a=t.length;r<o;r++,a++)t[a]=e[r];return t},Mu=Object.defineProperty,Tu=Object.defineProperties,ku=Object.getOwnPropertyDescriptors,$l=Object.getOwnPropertySymbols,Iu=Object.prototype.hasOwnProperty,Pu=Object.prototype.propertyIsEnumerable,Bl=function(t,e,r){return e in t?Mu(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r},xt=function(t,e){for(var r in e||(e={}))Iu.call(e,r)&&Bl(t,r,e[r]);if($l)for(var o=0,a=$l(e);o<a.length;o++){var r=a[o];Pu.call(e,r)&&Bl(t,r,e[r])}return t},ki=function(t,e){return Tu(t,ku(e))},zu=function(t,e,r){return new Promise(function(o,a){var i=function(d){try{c(r.next(d))}catch(u){a(u)}},s=function(d){try{c(r.throw(d))}catch(u){a(u)}},c=function(d){return d.done?o(d.value):Promise.resolve(d.value).then(i,s)};c((r=r.apply(t,e)).next())})};var Du=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?vr:vr.apply(null,arguments)},oy=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}};function Uu(t){if(typeof t!="object"||t===null)return!1;var e=Object.getPrototypeOf(t);if(e===null)return!0;for(var r=e;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return e===r}function St(t,e){function r(){for(var o=[],a=0;a<arguments.length;a++)o[a]=arguments[a];if(e){var i=e.apply(void 0,o);if(!i)throw new Error("prepareAction did not return an object");return xt(xt({type:t,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:t,payload:o[0]}}return r.toString=function(){return""+t},r.type=t,r.match=function(o){return o.type===t},r}var Fu=(function(t){Wl(e,t);function e(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var a=t.apply(this,r)||this;return Object.setPrototypeOf(a,e.prototype),a}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return t.prototype.concat.apply(this,r)},e.prototype.prepend=function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return r.length===1&&Array.isArray(r[0])?new(e.bind.apply(e,xr([void 0],r[0].concat(this)))):new(e.bind.apply(e,xr([void 0],r.concat(this))))},e})(Array),$u=(function(t){Wl(e,t);function e(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var a=t.apply(this,r)||this;return Object.setPrototypeOf(a,e.prototype),a}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return t.prototype.concat.apply(this,r)},e.prototype.prepend=function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return r.length===1&&Array.isArray(r[0])?new(e.bind.apply(e,xr([void 0],r[0].concat(this)))):new(e.bind.apply(e,xr([void 0],r.concat(this))))},e})(Array);function zi(t){return $e(t)?dn(t,function(){}):t}function Bu(t){return typeof t=="boolean"}function Hu(){return function(e){return Gu(e)}}function Gu(t){t===void 0&&(t={});var e=t.thunk,r=e===void 0?!0:e,o=t.immutableCheck,a=o===void 0?!0:o,i=t.serializableCheck,s=i===void 0?!0:i,c=t.actionCreatorCheck,d=c===void 0?!0:c,u=new Fu;if(r&&(Bu(r)?u.push(Ti):u.push(Ti.withExtraArgument(r.extraArgument))),0){if(a)var m;if(s)var h;if(d)var y}return u}var Ii=!0;function jl(t){var e=Hu(),r=t||{},o=r.reducer,a=o===void 0?void 0:o,i=r.middleware,s=i===void 0?e():i,c=r.devTools,d=c===void 0?!0:c,u=r.preloadedState,m=u===void 0?void 0:u,h=r.enhancers,y=h===void 0?void 0:h,b;if(typeof a=="function")b=a;else if(Uu(a))b=zl(a);else throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');var x=s;if(typeof x=="function"&&(x=x(e),!Ii&&!Array.isArray(x)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!Ii&&x.some(function(S){return typeof S!="function"}))throw new Error("each middleware provided to configureStore must be a function");var C=Dl.apply(void 0,x),O=vr;d&&(O=Du(xt({trace:!Ii},typeof d=="object"&&d)));var w=new $u(C),N=w;Array.isArray(y)?N=xr([C],y):typeof y=="function"&&(N=y(w));var E=O.apply(void 0,N);return Mi(b,m,E)}function Vl(t){var e={},r=[],o,a={addCase:function(i,s){var c=typeof i=="string"?i:i.type;if(!c)throw new Error("`builder.addCase` cannot be called with an empty action type");if(c in e)throw new Error("`builder.addCase` cannot be called with two reducers for the same action type");return e[c]=s,a},addMatcher:function(i,s){return r.push({matcher:i,reducer:s}),a},addDefaultCase:function(i){return o=i,a}};return t(a),[e,r,o]}function Wu(t){return typeof t=="function"}function ju(t,e,r,o){r===void 0&&(r=[]);var a=typeof e=="function"?Vl(e):[e,r,o],i=a[0],s=a[1],c=a[2],d;if(Wu(t))d=function(){return zi(t())};else{var u=zi(t);d=function(){return u}}function m(h,y){h===void 0&&(h=d());var b=xr([i[y.type]],s.filter(function(x){var C=x.matcher;return C(y)}).map(function(x){var C=x.reducer;return C}));return b.filter(function(x){return!!x}).length===0&&(b=[c]),b.reduce(function(x,C){if(C)if(st(x)){var O=x,w=C(O,y);return w===void 0?x:w}else{if($e(x))return dn(x,function(N){return C(N,y)});var w=C(x,y);if(w===void 0){if(x===null)return x;throw Error("A case reducer on a non-draftable value must not return undefined")}return w}return x},h)}return m.getInitialState=d,m}function Vu(t,e){return t+"/"+e}function Kl(t){var e=t.name;if(!e)throw new Error("`name` is a required option for createSlice");typeof process<"u";var r=typeof t.initialState=="function"?t.initialState:zi(t.initialState),o=t.reducers||{},a=Object.keys(o),i={},s={},c={};a.forEach(function(m){var h=o[m],y=Vu(e,m),b,x;"reducer"in h?(b=h.reducer,x=h.prepare):b=h,i[m]=b,s[y]=b,c[m]=x?St(y,x):St(y)});function d(){var m=typeof t.extraReducers=="function"?Vl(t.extraReducers):[t.extraReducers],h=m[0],y=h===void 0?{}:h,b=m[1],x=b===void 0?[]:b,C=m[2],O=C===void 0?void 0:C,w=xt(xt({},y),s);return ju(r,function(N){for(var E in w)N.addCase(E,w[E]);for(var S=0,A=x;S<A.length;S++){var T=A[S];N.addMatcher(T.matcher,T.reducer)}O&&N.addDefaultCase(O)})}var u;return{name:e,reducer:function(m,h){return u||(u=d()),u(m,h)},actions:c,caseReducers:i,getInitialState:function(){return u||(u=d()),u.getInitialState()}}}var Ku="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Zu=function(t){t===void 0&&(t=21);for(var e="",r=t;r--;)e+=Ku[Math.random()*64|0];return e},qu=["name","message","stack","code"],Pi=(function(){function t(e,r){this.payload=e,this.meta=r}return t})(),Hl=(function(){function t(e,r){this.payload=e,this.meta=r}return t})(),Yu=function(t){if(typeof t=="object"&&t!==null){for(var e={},r=0,o=qu;r<o.length;r++){var a=o[r];typeof t[a]=="string"&&(e[a]=t[a])}return e}return{message:String(t)}},sy=(function(){function t(e,r,o){var a=St(e+"/fulfilled",function(m,h,y,b){return{payload:m,meta:ki(xt({},b||{}),{arg:y,requestId:h,requestStatus:"fulfilled"})}}),i=St(e+"/pending",function(m,h,y){return{payload:void 0,meta:ki(xt({},y||{}),{arg:h,requestId:m,requestStatus:"pending"})}}),s=St(e+"/rejected",function(m,h,y,b,x){return{payload:b,error:(o&&o.serializeError||Yu)(m||"Rejected"),meta:ki(xt({},x||{}),{arg:y,requestId:h,rejectedWithValue:!!b,requestStatus:"rejected",aborted:m?.name==="AbortError",condition:m?.name==="ConditionError"})}}),c=!1,d=typeof AbortController<"u"?AbortController:(function(){function m(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return m.prototype.abort=function(){},m})();function u(m){return function(h,y,b){var x=o?.idGenerator?o.idGenerator(m):Zu(),C=new d,O,w=!1;function N(S){O=S,C.abort()}var E=(function(){return zu(this,null,function(){var S,A,T,$,X,G,I;return Nu(this,function(U){switch(U.label){case 0:return U.trys.push([0,4,,5]),$=(S=o?.condition)==null?void 0:S.call(o,m,{getState:y,extra:b}),Ju($)?[4,$]:[3,2];case 1:$=U.sent(),U.label=2;case 2:if($===!1||C.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return w=!0,X=new Promise(function(j,ie){return C.signal.addEventListener("abort",function(){return ie({name:"AbortError",message:O||"Aborted"})})}),h(i(x,m,(A=o?.getPendingMeta)==null?void 0:A.call(o,{requestId:x,arg:m},{getState:y,extra:b}))),[4,Promise.race([X,Promise.resolve(r(m,{dispatch:h,getState:y,extra:b,requestId:x,signal:C.signal,abort:N,rejectWithValue:function(j,ie){return new Pi(j,ie)},fulfillWithValue:function(j,ie){return new Hl(j,ie)}})).then(function(j){if(j instanceof Pi)throw j;return j instanceof Hl?a(j.payload,x,m,j.meta):a(j,x,m)})])];case 3:return T=U.sent(),[3,5];case 4:return G=U.sent(),T=G instanceof Pi?s(null,x,m,G.payload,G.meta):s(G,x,m),[3,5];case 5:return I=o&&!o.dispatchConditionRejection&&s.match(T)&&T.meta.condition,I||h(T),[2,T]}})})})();return Object.assign(E,{abort:N,requestId:x,arg:m,unwrap:function(){return E.then(Xu)}})}}return Object.assign(u,{pending:i,rejected:s,fulfilled:a,typePrefix:e})}return t.withTypes=function(){return t},t})();function Xu(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function Ju(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var Zl="listener",ql="completed",Yl="cancelled",cy="task-"+Yl,ly="task-"+ql,dy=Zl+"-"+Yl,uy=Zl+"-"+ql;var Di="listenerMiddleware";var fy=St(Di+"/add"),py=St(Di+"/removeAll"),hy=St(Di+"/remove");var Gl,my=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(t){return(Gl||(Gl=Promise.resolve())).then(t).catch(function(e){return setTimeout(function(){throw e},0)})},Qu=function(t){return function(e){setTimeout(e,t)}},gy=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Qu(10);wl();window.ftReduxStores||(window.ftReduxStores={});var jt=class t extends nt{static get(e){var r;let o=typeof e=="string"?e:e.name,a=typeof e=="string"?void 0:e,i=window.ftReduxStores[o];if(mr(i))return i;if(a==null)return;let s=Kl({...a,reducers:(r=a.reducers)!==null&&r!==void 0?r:{}}),c=jl({reducer:(d,u)=>{if(u.type==="CLEAR_FT_REDUX_STORE"){let m=Ue(s.getInitialState());for(let h of u.keeping)m[h]=(d??m)[h];return m}else if(typeof u.type=="string"&&u.type.startsWith("DEFAULT_VALUE_SETTER__"))return{...d,...u.overwrites};return s.reducer(d,u)}});return window.ftReduxStores[a.name]=new t(s,c,a.eventBus)}constructor(e,r,o){super(),this.reduxSlice=e,this.reduxStore=r,this.isFtReduxStore=!0,this.commands=new ho;let a=i=>i!=null?JSON.parse(JSON.stringify(i)):i;this.actions=new Proxy(this.reduxSlice.actions,{get:(i,s,c)=>{let d=s,u=i[d];return u?(...m)=>{let h=u(...m.map(a));return this.reduxStore.dispatch(h),h}:m=>{this.setState({[d]:a(m)})}}}),this.eventBus=o??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:[]})}clearKeeping(...e){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:e})}setState(e){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(e).join("_"),overwrites:e})}get dispatch(){throw new Error("Don't use this method, actions are automatically dispatched when called.")}[Symbol.observable](){return this.reduxStore[Symbol.observable]()}getState(){return this.reduxStore.getState()}replaceReducer(e){throw new Error("Not implemented yet.")}subscribe(e){return this.reduxStore.subscribe(e)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}};function ef(){var t;for(let e of Object.values((t=window.ftReduxStores)!==null&&t!==void 0?t:{}))mr(e)&&e.clear()}var fn=class{constructor(e,r,o){this.store=e,this.valueSelector=r,this.callback=o}watch(){return this.stop(),this.lastValue=this.valueSelector(this.store.getState()),this.unsubscribe=this.store.subscribe(()=>{let e=this.store.getState(),r=this.valueSelector(e);ot(this.lastValue,r)&&(this.callback(r,e),this.lastValue=r)}),this}stop(){return this.unsubscribe!=null&&(this.unsubscribe(),this.unsubscribe=void 0),this.lastValue=void 0,this}};function tf(t,e,r){return new fn(t,e,r).watch()}var vo=class{constructor(){this.requestConsumers=new Map}getOrCreateRequestConsumers(e){var r;return(r=this.requestConsumers.get(e))!==null&&r!==void 0?r:this.requestConsumers.set(e,new Set).get(e)}registerComponent(e,r){for(let o of r)this.getOrCreateRequestConsumers(o).add(e).size==1&&this.onNewNeededRequest(o)}unregisterComponent(e,r){for(let o of r)this.getOrCreateRequestConsumers(o).delete(e)}isRequestNeeded(e){return this.getOrCreateRequestConsumers(e).size>0}};var Bi={};W(Bi,{scrollHelper:()=>rf});var Fi,pn=new Map,$i=class{lock(e,r){if(r){let o=pn.get(r);if(o==null||o===e)return pn.set(r,e),r}}release(e,r){r&&pn.get(r)===e&&pn.delete(r)}findFirstScrollableParent(e){var r;let o,a;for(let i of ua(e)){let s=i,c=this.elementCanScroll(s);if(c&&s.clientHeight&&s.clientHeight<s.scrollHeight){o=s;break}else c&&a==null&&(a=s)}return(r=o??a)!==null&&r!==void 0?r:document.body}elementCanScroll(e){try{return["auto","scroll"].includes(getComputedStyle(e).overflowY)&&!["contents"].includes(getComputedStyle(e).display)}catch{return!1}}getAbsoluteScrollOffset(e,r){var o,a;let i=0;for(;r&&r.offsetParent!==e.offsetParent;)i+=(o=r.offsetTop)!==null&&o!==void 0?o:0,r=r.offsetParent;return i+((a=r?.offsetTop)!==null&&a!==void 0?a:0)-e.offsetTop}computeTopOffsetRatio(e,r){if(typeof e=="number")return e;switch(e){case"end":return 1;case"center":return .5;case"nearest":return r;default:return 0}}scrollIntoViewIfPossible(e,r){let o=this.findFirstScrollableParent(e);if(e&&this.lock(this,o)){let a=this.getAbsoluteScrollOffset(o,e),i=a-o.clientHeight+e.clientHeight,s=a,c=kt(0,(s-o.scrollTop)/(s-i),1),d=this.computeTopOffsetRatio(r?.position,c)*(i-s)+s;o.scrollTo({behavior:r?.behavior,top:d})}else console.warn("Could not scroll element into view because the scrollable parent is already locked",e,o);this.release(this,o)}};window.FluidTopicsScrollHelper=(Fi=window.FluidTopicsScrollHelper)!==null&&Fi!==void 0?Fi:new $i;var rf=window.FluidTopicsScrollHelper;var Gi={};W(Gi,{SearchPlaceConverter:()=>Er,SearchPlaceQueryParams:()=>H,isSearchPlaceQueryParams:()=>U1,serializeRequest:()=>af});var Xl;(function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"})(Xl||(Xl={}));var Jl;(function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"})(Jl||(Jl={}));var Ql;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(Ql||(Ql={}));var e1;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(e1||(e1={}));var t1;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(t1||(t1={}));var r1;(function(t){t.VALUE="VALUE",t.DATE="DATE",t.RANGE="RANGE"})(r1||(r1={}));var o1;(function(t){t.OFFICIAL="OFFICIAL",t.AI="AI"})(o1||(o1={}));var n1;(function(t){t.BOOKMARK__CREATE="BOOKMARK__CREATE",t.BOOKMARK__DELETE="BOOKMARK__DELETE",t.CASE_DEFLECTION__START="CASE_DEFLECTION__START",t.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",t.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",t.CHATBOT__RATE="CHATBOT__RATE",t.COLLECTION__CREATE="COLLECTION__CREATE",t.COLLECTION__UPDATE="COLLECTION__UPDATE",t.COLLECTION__DELETE="COLLECTION__DELETE",t.CUSTOM_EVENT__TRIGGER="CUSTOM_EVENT__TRIGGER",t.DOCUMENT__ON_DEMAND_TRANSLATE="DOCUMENT__ON_DEMAND_TRANSLATE",t.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",t.DOCUMENT__PRINT="DOCUMENT__PRINT",t.DOCUMENT__PROCESS="DOCUMENT__PROCESS",t.DOCUMENT__RATE="DOCUMENT__RATE",t.DOCUMENT__SEARCH="DOCUMENT__SEARCH",t.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",t.DOCUMENT__UNRATE="DOCUMENT__UNRATE",t.FEEDBACK__SEND="FEEDBACK__SEND",t.AI__COMPLETED_QUERY="AI__COMPLETED_QUERY",t.AI__RATE="AI__RATE",t.AI_CASE_DEFLECTION__START="AI_CASE_DEFLECTION__START",t.AI_CASE_DEFLECTION__OPEN_TICKET="AI_CASE_DEFLECTION__OPEN_TICKET",t.KHUB__PROCESS="KHUB__PROCESS",t.KHUB__SEARCH="KHUB__SEARCH",t.LABELS__DOWNLOAD="LABELS__DOWNLOAD",t.LINK__SHARE="LINK__SHARE",t.PAGE__DISPLAY="PAGE__DISPLAY",t.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",t.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",t.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",t.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",t.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",t.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",t.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",t.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",t.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",t.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",t.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",t.TOPIC__AI_TRANSLATE="TOPIC__AI_TRANSLATE",t.TOPIC__RATE="TOPIC__RATE",t.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",t.TOPIC__UNRATE="TOPIC__UNRATE",t.USER__LOGIN="USER__LOGIN",t.USER__LOGOUT="USER__LOGOUT",t.HEARTBEAT="HEARTBEAT"})(n1||(n1={}));var a1;(function(t){t.STANDARD="STANDARD",t.STRUCTURAL="STRUCTURAL"})(a1||(a1={}));var i1;(function(t){t.THIRD_PARTY="THIRD_PARTY",t.OFF_THE_GRID="OFF_THE_GRID",t.CONTENT_PACKAGER="CONTENT_PACKAGER",t.PAGES="PAGES",t.DESIGNED_READER="DESIGNED_READER"})(i1||(i1={}));var s1;(function(t){t.HOMEPAGE="HOMEPAGE",t.CUSTOM="CUSTOM",t.HEADER="HEADER",t.READER="READER",t.TOPIC_TEMPLATE="TOPIC_TEMPLATE",t.SEARCH="SEARCH",t.SEARCH_RESULT="SEARCH_RESULT",t.SEARCH_ANNOUNCEMENT="SEARCH_ANNOUNCEMENT",t.LINK_PREVIEW="LINK_PREVIEW",t.UD_VIEWER="UD_VIEWER",t.ASSET_VIEWER="ASSET_VIEWER"})(s1||(s1={}));var c1;(function(t){t.CLASSIC="CLASSIC",t.CUSTOM="CUSTOM",t.DESIGNER="DESIGNER"})(c1||(c1={}));var l1;(function(t){t.AND="AND",t.OR="OR",t.MONOVALUED="MONOVALUED"})(l1||(l1={}));var d1;(function(t){t.NONE="NONE",t.ALPHABET="ALPHABET",t.VERSION="VERSION"})(d1||(d1={}));var u1;(function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"})(u1||(u1={}));var f1;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"})(f1||(f1={}));var Sr;(function(t){t.OPTIONAL="OPTIONAL",t.MANDATORY="MANDATORY"})(Sr||(Sr={}));var p1;(function(t){t.ASC="ASC",t.DESC="DESC"})(p1||(p1={}));var h1;(function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"})(h1||(h1={}));var Hi;(function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"})(Hi||(Hi={}));var C1=t=>Object.keys(Hi).includes(t);var m1;(function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(m1||(m1={}));var g1;(function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"})(g1||(g1={}));var y1;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(y1||(y1={}));var Cr;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(Cr||(Cr={}));var E1=t=>Object.keys(Cr).includes(t);var b1;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.HTML_PACKAGE="HTML_PACKAGE",t.HTML_PACKAGE_PAGE="HTML_PACKAGE_PAGE"})(b1||(b1={}));var v1;(function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS",t.ALL_TOPICS="ALL_TOPICS",t.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(v1||(v1={}));var x1;(function(t){t.PLAIN_TEXT="PLAIN_TEXT",t.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",t.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(x1||(x1={}));var ae;(function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.GENERATIVE_AI_USER="GENERATIVE_AI_USER",t.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_USER",t.ANNOUNCEMENT_ADMIN="ANNOUNCEMENT_ADMIN",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN"})(ae||(ae={}));var Pe;(function(t){t.SEARCHES="SEARCHES",t.BOOKMARKS="BOOKMARKS",t.BOOKS="BOOKS",t.COLLECTIONS="COLLECTIONS"})(Pe||(Pe={}));var S1;(function(t){t.UNAUTHENTICATED="UNAUTHENTICATED",t.USER_INCOMPLETE="USER_INCOMPLETE",t.MFA_REQUIRED="MFA_REQUIRED",t.AUTHENTICATED="AUTHENTICATED"})(S1||(S1={}));var A1;(function(t){t.UNREACHABLE="UNREACHABLE",t.UNAUTHORIZED="UNAUTHORIZED",t.FORBIDDEN="FORBIDDEN",t.INCOMPATIBLE="INCOMPATIBLE",t.FAILED="FAILED",t.OK="OK"})(A1||(A1={}));var L1;(function(t){t.VALID="VALID",t.INVALID="INVALID"})(L1||(L1={}));var O1;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SUMMARY="SUMMARY",t.SEMANTIC_SEARCH="SEMANTIC_SEARCH",t.CHATBOT_INSTRUCTIONS="CHATBOT_INSTRUCTIONS",t.OTHER="OTHER"})(O1||(O1={}));var R1;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SLOW="SLOW",t.OTHER="OTHER"})(R1||(R1={}));var w1;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(w1||(w1={}));var _1;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(_1||(_1={}));var N1;(function(t){t.TEXT="TEXT",t.HTML="HTML"})(N1||(N1={}));var M1;(function(t){t.IN_PROGRESS="IN_PROGRESS",t.ERROR="ERROR",t.DONE="DONE"})(M1||(M1={}));var T1;(function(t){t.HTML="HTML",t.MARKDOWN="MARKDOWN"})(T1||(T1={}));var k1;(function(t){t.SOURCES="SOURCES",t.ENRICH_AND_CLEAN="ENRICH_AND_CLEAN",t.VOCABULARIES="VOCABULARIES",t.METADATA="METADATA",t.PRETTY_URL="PRETTY_URL",t.ACCESS_RULE="ACCESS_RULE",t.DESIGNED_PAGES="DESIGNED_PAGES",t.THEME_STUDIO="THEME_STUDIO",t.PORTAL_GENERAL="PORTAL_GENERAL",t.ASSETS="ASSETS",t.CODE_LIBRARY="CODE_LIBRARY",t.THEME="THEME",t.CONTENT_STYLES="CONTENT_STYLES",t.HOMEPAGE="HOMEPAGE",t.CLASSIC_SEARCH_PAGE="CLASSIC_SEARCH_PAGE",t.CLASSIC_READER_PAGE="CLASSIC_READER_PAGE",t.PORTAL_METADATA="PORTAL_METADATA",t.LANGUAGES="LANGUAGES",t.PRINT_TEMPLATES="PRINT_TEMPLATES",t.OFFLINE="OFFLINE",t.CUSTOM_JS="CUSTOM_JS",t.CONFIDENTIALITY="CONFIDENTIALITY",t.NOTIFICATIONS="NOTIFICATIONS"})(k1||(k1={}));var I1;(function(t){t.MAP="MAP",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT"})(I1||(I1={}));var of={[ae.PERSONAL_BOOK_SHARE_USER]:[ae.PERSONAL_BOOK_USER],[ae.HTML_EXPORT_USER]:[ae.PERSONAL_BOOK_USER],[ae.PDF_EXPORT_USER]:[ae.PERSONAL_BOOK_USER],[ae.KHUB_ADMIN]:[ae.CONTENT_PUBLISHER],[ae.ADMIN]:[ae.KHUB_ADMIN,ae.USERS_ADMIN,ae.PORTAL_ADMIN,ae.BEHAVIOR_DATA_USER],[ae.GENERATIVE_AI_EXPORT_USER]:[ae.GENERATIVE_AI_USER]};function P1(t,e){return t===e||(of[t]??[]).some(r=>P1(r,e))}function z1(t,e){return t==null?!1:(Array.isArray(t)?t:Array.isArray(t.roles)?t.roles:Array.isArray(t.profile?.roles)?t.profile.roles:[]).some(o=>P1(o,e))}function nf(t){return`"${t}"`}function D1(t){return t.startsWith('"')&&t.endsWith('"')?t.replace(/(^"+)|("+$)/g,""):t}function af(t,e){return new Er(t).serialize(e)}var H;(function(t){t.LOCALE="content-lang",t.QUERY="query",t.SCOPE="scope",t.FILTERS="filters",t.VIRTUAL_FIELD="virtual-field",t.PERIOD="period",t.VALUE_FILTERS="value-filters",t.DATE_FILTERS="date-filters",t.RANGE_FILTERS="range-filters",t.SORT="sort",t.PER_PAGE="per-page",t.KEYWORD_MATCH="keyword-match"})(H||(H={}));var sf=new Set(Object.values(H));function U1(t){return sf.has(t)}var Er=class{constructor(e,r=20,o=!1,a="en-US"){this.baseUrl=e,this.defaultPerPage=r,this.allLanguagesAllowed=o,this.defaultContentLocale=a,this.scopeMapping={documents:"DOCUMENTS",topics:"ALL_TOPICS"},this.filtersEscapeMapping=[["*","\\*","[ft-escaped-star-character]"],["~","\\\\~","[ft-escaped-tilde-character]"],["_","\\\\\\\\_","[ft-escaped-underscore-character]"]]}serialize(e,r){return this.serializeToCurrentPageIfPossible(e,r??"/search")}serializeToCurrentPageIfPossible(e,r){let o=r==null||r.trim().length===0,a=new URL(o?window.location.href:`${this.baseUrl.replace(/\/+$/,"")}${r}`);return a.search=this.toURLSearchParams(e),a.toString()}toURLSearchParams(e,r=!1){var o,a,i,s,c,d,u,m,h,y,b;let x=new URLSearchParams;e.contentLocale?(!r||e.contentLocale!==this.defaultContentLocale)&&x.append(H.LOCALE,e.contentLocale):x.append(H.LOCALE,this.allLanguagesAllowed?"all":this.defaultContentLocale),((o=e.query)===null||o===void 0?void 0:o.length)>0&&x.append(H.QUERY,e.query);let C=(i=(a=e.metadataFilters)===null||a===void 0?void 0:a.filter(S=>S.valueFilter&&!S.valueFilter.negative))!==null&&i!==void 0?i:[];if(C.length>0){let S=C.map(A=>{var T,$;let X=(($=(T=A.valueFilter)===null||T===void 0?void 0:T.values)!==null&&$!==void 0?$:[]).map(G=>this.escapeFilters(G)).map(G=>nf(D1(G))).join("_");return`${A.key}~${X}`}).join("*");x.append(H.VALUE_FILTERS,S)}let O=(c=(s=e.metadataFilters)===null||s===void 0?void 0:s.filter(S=>S.dateFilter))!==null&&c!==void 0?c:[];if(O.length>0){let S=O.map(A=>{var T;return`${A.key}~${(T=A.dateFilter)===null||T===void 0?void 0:T.type.toLowerCase()}`}).join("*");x.append(H.DATE_FILTERS,S)}let w=(u=(d=e.metadataFilters)===null||d===void 0?void 0:d.filter(S=>S.rangeFilter))!==null&&u!==void 0?u:[];if(w.length>0){let S=w.map(A=>{var T,$;return`${A.key}~${(T=A.rangeFilter)===null||T===void 0?void 0:T.from}_${($=A.rangeFilter)===null||$===void 0?void 0:$.to}`}).join("*");x.append(H.RANGE_FILTERS,S)}e.virtualField&&e.virtualField!=="EVERYWHERE"&&x.append(H.VIRTUAL_FIELD,e.virtualField.toLowerCase()),e.scope&&e.scope!=="DEFAULT"&&x.append(H.SCOPE,e.scope.toLowerCase()),e.sortId!=null&&x.append(H.SORT,e.sortId),!((m=e.paging)===null||m===void 0)&&m.perPage&&((y=(h=e.paging)===null||h===void 0?void 0:h.perPage)!==null&&y!==void 0?y:this.defaultPerPage)!=this.defaultPerPage&&x.append(H.PER_PAGE,String(e.paging.perPage)),e.keywordMatch!=null&&x.append(H.KEYWORD_MATCH,e.keywordMatch.toLowerCase());let N=(b=e.otherQueryParams)!==null&&b!==void 0?b:{};for(let S in N)x.append(S,N[S]);let E=new Array;return x.forEach((S,A)=>{E.push(this.encodeQueryString(A)+"="+this.encodeQueryString(S))}),encodeURI(E.join("&")).replace(/#/g,"%23")}encodeQueryString(e){return encodeURIComponent(e).replace(/%20/g,"+")}parse(e){var r;let o=e.split("?"),a=this.fromURLSearchParams(o.slice(1).join("?")),i=o[0].split("/search/")[1];return i==null?a:{...a,scope:(r=this.scopeMapping[i])!==null&&r!==void 0?r:a.scope}}fromURLSearchParams(e){var r,o,a,i,s,c;try{e=decodeURI(e).replace(/%23/g,"#")}catch(w){console.warn("Could not decode search request query params, fallback on raw value",w)}let d=new URLSearchParams(e),u=d.get(H.LOCALE)==="all"?void 0:d.get(H.LOCALE),m=((r=d.get(H.VIRTUAL_FIELD))!==null&&r!==void 0?r:"EVERYWHERE").toUpperCase(),h=(o=d.get(H.SORT))===null||o===void 0?void 0:o.toLowerCase(),y=(a=d.get(H.SCOPE))!==null&&a!==void 0?a:"default",b=+((i=d.get(H.PER_PAGE))!==null&&i!==void 0?i:this.defaultPerPage),x=d.get(H.KEYWORD_MATCH),C=x?x.toUpperCase()===Sr.MANDATORY?Sr.MANDATORY:Sr.OPTIONAL:void 0,O={};for(let w of d.keys())U1(w)||(O[w]=d.get(w));return{contentLocale:u??(this.allLanguagesAllowed?void 0:this.defaultContentLocale),query:(s=d.get(H.QUERY))!==null&&s!==void 0?s:"",scope:(c=this.scopeMapping[y])!==null&&c!==void 0?c:"DEFAULT",virtualField:C1(m)?m:"EVERYWHERE",sortId:h,metadataFilters:this.parseCompatFilters(d),facets:[],paging:{page:1,perPage:kt(1,isNaN(b)?this.defaultPerPage:b,1e3)},keywordMatch:C,otherQueryParams:O}}parseCompatFilters(e){var r,o,a,i,s,c;let d=[];return e.has(H.FILTERS)&&(d=this.parseValueFilters((r=e.get(H.FILTERS))!==null&&r!==void 0?r:"")),(o=e.has(H.PERIOD))!==null&&o!==void 0&&o&&(d=[...d,...this.parseLegacyPeriodFilter(((a=e.get(H.PERIOD))!==null&&a!==void 0?a:"").toUpperCase())]),[...d,...this.parseValueFilters((i=e.get(H.VALUE_FILTERS))!==null&&i!==void 0?i:""),...this.parseDateFilters((s=e.get(H.DATE_FILTERS))!==null&&s!==void 0?s:""),...this.parseRangeFilters((c=e.get(H.RANGE_FILTERS))!==null&&c!==void 0?c:"")]}splitUnknownFilter(e){return this.superEscapeFilters(e).split("*").map(r=>r.split("~"))}parseValueFilters(e){return e.length===0?[]:this.splitUnknownFilter(e).map(r=>({key:r[0],valueFilter:{values:r[1].split("_").map(D1).map(o=>this.unescapeFilterValue(o)),negative:!1}}))}parseDateFilters(e){return e.length===0?[]:this.splitUnknownFilter(e).map(r=>({key:r[0],dateFilter:{type:Cr[r[1].toUpperCase()]}}))}parseRangeFilters(e){return e.length===0?[]:this.splitUnknownFilter(e).map(r=>({key:r[0],rangeFilter:{from:r[1].split("_")[0],to:r[1].split("_")[1]}}))}escapeFilters(e){for(let[r,o,a]of this.filtersEscapeMapping)e=e.replaceAll(r,o);return e}superEscapeFilters(e){for(let[r,o,a]of this.filtersEscapeMapping)e=e.replaceAll(o,a);return e}unescapeFilterValue(e){for(let[r,o,a]of this.filtersEscapeMapping)e=e.replaceAll(a,r);return e}parseLegacyPeriodFilter(e){if(E1(e))return[{key:"ft:lastEdition",dateFilter:{type:Cr[e]}}];if(e.startsWith("CUSTOM_")){let[r,o,a]=e.split("_");return[{key:"ft:lastEdition",rangeFilter:{from:o,to:a}}]}return[]}static clearSearchParamsInUrl(e){let r=new URL(e);return[H.LOCALE,H.FILTERS,H.VALUE_FILTERS,H.DATE_FILTERS,H.RANGE_FILTERS].forEach(a=>{r.searchParams.delete(a)}),r.toString()}static updateLocaleParamInUrl(e,r){let o=new URL(e);return o.searchParams.delete(H.LOCALE),r!==void 0&&o.searchParams.append(H.LOCALE,r),o.toString()}};var Vi={};W(Vi,{toFtFormComponent:()=>ji});var Wi=Symbol("elementInternals"),ji=de(Symbol("toFtFormComponent"),function(t){class e extends t{static get formAssociated(){return!0}get form(){return this[Wi].form}constructor(...o){super(o),this[Wi]=this.attachInternals()}setFormValue(o){this[Wi].setFormValue(o)}}return e});var Ki={};W(Ki,{DateFormatter:()=>Vt});var Vt=class{static format(e,r,o,a,i){return window.moment?window.moment(e).locale(r).format(this.getMomentDateFormat(o,a,!!i)):this.getIntlDateTime(e,r,o,a,!!i)}static getMomentDateFormat(e,r,o){return o?"LT":e?r?"lll":"ll":r?"L LT":"L"}static getIntlDateTime(e,r,o,a,i){let s=typeof e=="string"?new Date(e):e,c=new Intl.DateTimeFormat(r,{dateStyle:o?"medium":"short"}).format(s),d=new Intl.DateTimeFormat(r,{timeStyle:"short"}).format(s);return i?d:a?`${c} ${d}`:c}static getTimezoneAsString(){let e=o=>String(Math.floor(o)).padStart(2,"0"),r=new Date().getTimezoneOffset();return`${r<0?"+":"-"}${e(Math.abs(r)/60)}:${e(Math.abs(r)%60)}`}};var qi={};W(qi,{ALL_KEYS_VALUE:()=>Zi,SameWindowStorageEvent:()=>Ar});var Zi="__all__",Ar=class extends CustomEvent{constructor(e,r,o){super("same-window-storage",{detail:{key:e,oldValue:r,newValue:o}})}keyMatch(e){return this.detail.key.includes(e)||this.detail.key==Zi}};Storage.prototype.setItem=new Proxy(Storage.prototype.setItem,{apply(t,e,r){let o=e.getItem(r[0]);Reflect.apply(t,e,r),window.dispatchEvent(new Ar(r[0],o,r[1]))}});Storage.prototype.removeItem=new Proxy(Storage.prototype.removeItem,{apply(t,e,r){let o=e.getItem(r[0]);Reflect.apply(t,e,r),window.dispatchEvent(new Ar(r[0],o))}});Storage.prototype.clear=new Proxy(Storage.prototype.clear,{apply(t,e,r){Reflect.apply(t,e,r),window.dispatchEvent(new Ar(Zi))}});var Xi={};W(Xi,{FocusMainContentEvent:()=>Yi});var Yi=class extends Event{constructor(){super("ft-focus-main-content",{composed:!0,bubbles:!0})}};var F1={};window.FluidTopicsA11yHints={isKeyboardNavigation:!1,lastPressedKey:""};function cf(t){(t.key==="Enter"||t.key===" "||t.key==="Tab")&&(window.FluidTopicsA11yHints.isKeyboardNavigation=!0),window.FluidTopicsA11yHints.lastPressedKey=t.key}function lf(t){window.FluidTopicsA11yHints.isKeyboardNavigation=t.detail==0}document.addEventListener("keydown",cf);document.addEventListener("click",lf);var $1=z`
47
+ `;var yl={};var hi={};W(hi,{ParametrizedLabelResolver:()=>po});var po=class t{constructor(e,r){this.defaultLabels=e,this.labels=r}resolve(e,...r){var o,a;e=this.resolvePluralKey(e,r);let i=(a=(o=this.labels[e])!==null&&o!==void 0?o:this.defaultLabels[e])!==null&&a!==void 0?a:"";return t.replaceParameters(i,...r)}static replaceParameters(e,...r){return r.forEach((o,a)=>e=e.replace(new RegExp(`\\{${a}([^}]*)\\}`,"g"),(i,s)=>t.formatValue(o,s))),e}resolvePluralKey(e,r){for(let o of r)if(typeof o=="number"){let a=`${String(e)}[\\=${o}]`;if(a in this.labels||a in this.defaultLabels)return a}return e}static formatValue(e,r){return e instanceof Date?t.formatDate(e,r):e??""}static formatDate(e,r){let o=a=>r?.includes("date")?e.toLocaleDateString(a):r?.includes("time")?e.toLocaleTimeString(a):e.toLocaleString(a);try{return o(document.documentElement.lang)}catch{return o()}}};var Ui={};W(Ui,{FtCommandQueue:()=>ho,FtLitElementRedux:()=>Ht,FtReduxStore:()=>jt,FtStateManager:()=>vo,ReduxWatcher:()=>fn,clearAllStores:()=>ef,isFtReduxStore:()=>mr,redux:()=>hr,reduxEventListener:()=>yu,reduxReactive:()=>gu,watch:()=>tf,withRedux:()=>bl});var gu=()=>(t,e)=>{var r;let o=t.constructor;o.reduxReactiveProperties=new Set(o.reduxReactiveProperties),(r=o.reduxReactiveProperties)===null||r===void 0||r.add(e)},hr=t=>{let e=t??{};return(r,o)=>{var a;let i={hasChanged:ot,attribute:!1,...e};L(i)(r,o);let s=r.constructor;s.reduxProperties=new Map(s.reduxProperties),s.reduxProperties.set(o,{selector:(a=e.selector)!==null&&a!==void 0?a:(c=>c[o]),store:e.store})}},yu=t=>(e,r)=>{let o=e.constructor;o.reduxEventListeners=new Map(o.reduxEventListeners),o.reduxEventListeners.set(r,t)};var ho=class{constructor(){this.queue=[]}add(e,r=!1){r&&this.clear(e.type),this.queue.push(e)}consume(e){let r=this.queue.find(o=>o.type===e);return r&&(this.queue=this.queue.filter(o=>o!==r)),r}clear(e){typeof e=="string"?this.queue=this.queue.filter(r=>r.type!==e):this.queue=this.queue.filter(r=>!e.test(r.type))}};function mr(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var mo=Symbol("internalReduxEventsUnsubscribers"),yt=Symbol("internalStoresUnsubscribers"),Bt=Symbol("internalStores"),bl=de(Symbol("withRedux"),function(t){var e,r,o;class a extends t{constructor(){super(...arguments),this[e]=new Map,this[r]=new Map,this[o]=new Map}get reduxConstructor(){return this.constructor}willUpdate(s){super.willUpdate(s),[...this.reduxConstructor.reduxReactiveProperties].some(c=>s.has(c))&&this.updateFromStores()}getUnnamedStore(){if(this[Bt].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Bt].values()][0]}getStore(s){return s==null?this.getUnnamedStore():this[Bt].get(s)}addStore(s,c){var d;c=(d=c??s.name)!==null&&d!==void 0?d:"default-store",this.unsubscribeFromStore(c),this[Bt].set(c,s),this.subscribeToStore(c,s),this.updateFromStores()}removeStore(s){let c=typeof s=="string"?s:s.name;this.unsubscribeFromStore(c),this[Bt].delete(c)}setupStores(){this.unsubscribeFromStores(),this[Bt].forEach((s,c)=>this.subscribeToStore(c,s)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((s,c)=>{let d=this.constructor.getPropertyOptions(c);if(!d?.attribute||!this.hasAttribute(typeof d?.attribute=="string"?d.attribute:c)){let u=this.getStore(s.store);u&&(s.store?this[yt].has(s.store):this[yt].size>0)&&(this[c]=s.selector(u.getState(),this))}})}subscribeToStore(s,c){var d;this[yt].set(s,c.subscribe(()=>this.updateFromStores())),this[mo].set(s,[]),mr(c)&&c.eventBus&&((d=this.reduxConstructor.reduxEventListeners)===null||d===void 0||d.forEach((u,m)=>{if(typeof this[m]=="function"&&(!u.store||c.name===u.store)){let h=y=>this[m](y);c.addEventListener(u.eventName,h),this[mo].get(s).push(()=>c.removeEventListener(u.eventName,h))}})),this.onStoreAvailable(s)}unsubscribeFromStores(){this[yt].forEach((s,c)=>this.unsubscribeFromStore(c))}unsubscribeFromStore(s){var c;this[yt].has(s)&&this[yt].get(s)(),this[yt].delete(s),(c=this[mo].get(s))===null||c===void 0||c.forEach(d=>d()),this[mo].delete(s)}onStoreAvailable(s){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return e=yt,r=Bt,o=mo,a.reduxProperties=new Map,a.reduxReactiveProperties=new Set,a.reduxEventListeners=new Map,a}),Ht=class extends bl(q){};function Ie(t){for(var e=arguments.length,r=Array(e>1?e-1:0),o=1;o<e;o++)r[o-1]=arguments[o];if(0)var a,i;throw Error("[Immer] minified error nr: "+t+(r.length?" "+r.map((function(s){return"'"+s+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function st(t){return!!t&&!!t[J]}function $e(t){var e;return!!t&&((function(r){if(!r||typeof r!="object")return!1;var o=Object.getPrototypeOf(r);if(o===null)return!0;var a=Object.hasOwnProperty.call(o,"constructor")&&o.constructor;return a===Object||typeof a=="function"&&Function.toString.call(a)===Lu})(t)||Array.isArray(t)||!!t[Ll]||!!(!((e=t.constructor)===null||e===void 0)&&e[Ll])||Ei(t)||Ai(t))}function Gt(t,e,r){r===void 0&&(r=!1),br(t)===0?(r?Object.keys:yr)(t).forEach((function(o){r&&typeof o=="symbol"||e(o,t[o],t)})):t.forEach((function(o,a){return e(a,o,t)}))}function br(t){var e=t[J];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:Ei(t)?2:Ai(t)?3:0}function gr(t,e){return br(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function bu(t,e){return br(t)===2?t.get(e):t[e]}function Ol(t,e,r){var o=br(t);o===2?t.set(e,r):o===3?t.add(r):t[e]=r}function Rl(t,e){return t===e?t!==0||1/t==1/e:t!=t&&e!=e}function Ei(t){return Eu&&t instanceof Map}function Ai(t){return Au&&t instanceof Set}function bt(t){return t.o||t.t}function Li(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=Nl(t);delete e[J];for(var r=yr(e),o=0;o<r.length;o++){var a=r[o],i=e[a];i.writable===!1&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(e[a]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[a]})}return Object.create(Object.getPrototypeOf(t),e)}function Oi(t,e){return e===void 0&&(e=!1),Ri(t)||st(t)||!$e(t)||(br(t)>1&&(t.set=t.add=t.clear=t.delete=vu),Object.freeze(t),e&&Gt(t,(function(r,o){return Oi(o,!0)}),!0)),t}function vu(){Ie(2)}function Ri(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function Qe(t){var e=Ci[t];return e||Ie(18,t),e}function xu(t,e){Ci[t]||(Ci[t]=e)}function vi(){return yo}function mi(t,e){e&&(Qe("Patches"),t.u=[],t.s=[],t.v=e)}function sn(t){xi(t),t.p.forEach(Su),t.p=null}function xi(t){t===yo&&(yo=t.l)}function vl(t){return yo={p:[],l:yo,h:t,m:!0,_:0}}function Su(t){var e=t[J];e.i===0||e.i===1?e.j():e.g=!0}function gi(t,e){e._=e.p.length;var r=e.p[0],o=t!==void 0&&t!==r;return e.h.O||Qe("ES5").S(e,t,o),o?(r[J].P&&(sn(e),Ie(4)),$e(t)&&(t=cn(e,t),e.l||ln(e,t)),e.u&&Qe("Patches").M(r[J].t,t,e.u,e.s)):t=cn(e,r,[]),sn(e),e.u&&e.v(e.u,e.s),t!==_l?t:void 0}function cn(t,e,r){if(Ri(e))return e;var o=e[J];if(!o)return Gt(e,(function(c,d){return xl(t,o,e,c,d,r)}),!0),e;if(o.A!==t)return e;if(!o.P)return ln(t,o.t,!0),o.t;if(!o.I){o.I=!0,o.A._--;var a=o.i===4||o.i===5?o.o=Li(o.k):o.o,i=a,s=!1;o.i===3&&(i=new Set(a),a.clear(),s=!0),Gt(i,(function(c,d){return xl(t,o,a,c,d,r,s)})),ln(t,a,!1),r&&t.u&&Qe("Patches").N(o,r,t.u,t.s)}return o.o}function xl(t,e,r,o,a,i,s){if(st(a)){var c=cn(t,a,i&&e&&e.i!==3&&!gr(e.R,o)?i.concat(o):void 0);if(Ol(r,o,c),!st(c))return;t.m=!1}else s&&r.add(a);if($e(a)&&!Ri(a)){if(!t.h.D&&t._<1)return;cn(t,a),e&&e.A.l||ln(t,a)}}function ln(t,e,r){r===void 0&&(r=!1),!t.l&&t.h.D&&t.m&&Oi(e,r)}function yi(t,e){var r=t[J];return(r?bt(r):t)[e]}function Sl(t,e){if(e in t)for(var r=Object.getPrototypeOf(t);r;){var o=Object.getOwnPropertyDescriptor(r,e);if(o)return o;r=Object.getPrototypeOf(r)}}function vt(t){t.P||(t.P=!0,t.l&&vt(t.l))}function bi(t){t.o||(t.o=Li(t.t))}function Si(t,e,r){var o=Ei(e)?Qe("MapSet").F(e,r):Ai(e)?Qe("MapSet").T(e,r):t.O?(function(a,i){var s=Array.isArray(a),c={i:s?1:0,A:i?i.A:vi(),P:!1,I:!1,R:{},l:i,t:a,k:null,o:null,j:null,C:!1},d=c,u=bo;s&&(d=[c],u=go);var m=Proxy.revocable(d,u),h=m.revoke,y=m.proxy;return c.k=y,c.j=h,y})(e,r):Qe("ES5").J(e,r);return(r?r.A:vi()).p.push(o),o}function Cu(t){return st(t)||Ie(22,t),(function e(r){if(!$e(r))return r;var o,a=r[J],i=br(r);if(a){if(!a.P&&(a.i<4||!Qe("ES5").K(a)))return a.t;a.I=!0,o=Cl(r,i),a.I=!1}else o=Cl(r,i);return Gt(o,(function(s,c){a&&bu(a.t,s)===c||Ol(o,s,e(c))})),i===3?new Set(o):o})(t)}function Cl(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return Li(t)}function wl(){function t(s,c){var d=i[s];return d?d.enumerable=c:i[s]=d={configurable:!0,enumerable:c,get:function(){var u=this[J];return bo.get(u,s)},set:function(u){var m=this[J];bo.set(m,s,u)}},d}function e(s){for(var c=s.length-1;c>=0;c--){var d=s[c][J];if(!d.P)switch(d.i){case 5:o(d)&&vt(d);break;case 4:r(d)&&vt(d)}}}function r(s){for(var c=s.t,d=s.k,u=yr(d),m=u.length-1;m>=0;m--){var h=u[m];if(h!==J){var y=c[h];if(y===void 0&&!gr(c,h))return!0;var b=d[h],x=b&&b[J];if(x?x.t!==y:!Rl(b,y))return!0}}var C=!!c[J];return u.length!==yr(c).length+(C?0:1)}function o(s){var c=s.k;if(c.length!==s.t.length)return!0;var d=Object.getOwnPropertyDescriptor(c,c.length-1);if(d&&!d.get)return!0;for(var u=0;u<c.length;u++)if(!c.hasOwnProperty(u))return!0;return!1}function a(s){s.g&&Ie(3,JSON.stringify(bt(s)))}var i={};xu("ES5",{J:function(s,c){var d=Array.isArray(s),u=(function(h,y){if(h){for(var b=Array(y.length),x=0;x<y.length;x++)Object.defineProperty(b,""+x,t(x,!0));return b}var C=Nl(y);delete C[J];for(var O=yr(C),w=0;w<O.length;w++){var N=O[w];C[N]=t(N,h||!!C[N].enumerable)}return Object.create(Object.getPrototypeOf(y),C)})(d,s),m={i:d?5:4,A:c?c.A:vi(),P:!1,I:!1,R:{},l:c,t:s,k:u,o:null,g:!1,C:!1};return Object.defineProperty(u,J,{value:m,writable:!0}),u},S:function(s,c,d){d?st(c)&&c[J].A===s&&e(s.p):(s.u&&(function u(m){if(m&&typeof m=="object"){var h=m[J];if(h){var y=h.t,b=h.k,x=h.R,C=h.i;if(C===4)Gt(b,(function(S){S!==J&&(y[S]!==void 0||gr(y,S)?x[S]||u(b[S]):(x[S]=!0,vt(h)))})),Gt(y,(function(S){b[S]!==void 0||gr(b,S)||(x[S]=!1,vt(h))}));else if(C===5){if(o(h)&&(vt(h),x.length=!0),b.length<y.length)for(var O=b.length;O<y.length;O++)x[O]=!1;else for(var w=y.length;w<b.length;w++)x[w]=!0;for(var N=Math.min(b.length,y.length),E=0;E<N;E++)b.hasOwnProperty(E)||(x[E]=!0),x[E]===void 0&&u(b[E])}}}})(s.p[0]),e(s.p))},K:function(s){return s.i===4?r(s):o(s)}})}var El,yo,wi=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",Eu=typeof Map<"u",Au=typeof Set<"u",Al=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",_l=wi?Symbol.for("immer-nothing"):((El={})["immer-nothing"]=!0,El),Ll=wi?Symbol.for("immer-draftable"):"__$immer_draftable",J=wi?Symbol.for("immer-state"):"__$immer_state";var Lu=""+Object.prototype.constructor,yr=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,Nl=Object.getOwnPropertyDescriptors||function(t){var e={};return yr(t).forEach((function(r){e[r]=Object.getOwnPropertyDescriptor(t,r)})),e},Ci={},bo={get:function(t,e){if(e===J)return t;var r=bt(t);if(!gr(r,e))return(function(a,i,s){var c,d=Sl(i,s);return d?"value"in d?d.value:(c=d.get)===null||c===void 0?void 0:c.call(a.k):void 0})(t,r,e);var o=r[e];return t.I||!$e(o)?o:o===yi(t.t,e)?(bi(t),t.o[e]=Si(t.A.h,o,t)):o},has:function(t,e){return e in bt(t)},ownKeys:function(t){return Reflect.ownKeys(bt(t))},set:function(t,e,r){var o=Sl(bt(t),e);if(o?.set)return o.set.call(t.k,r),!0;if(!t.P){var a=yi(bt(t),e),i=a?.[J];if(i&&i.t===r)return t.o[e]=r,t.R[e]=!1,!0;if(Rl(r,a)&&(r!==void 0||gr(t.t,e)))return!0;bi(t),vt(t)}return t.o[e]===r&&(r!==void 0||e in t.o)||Number.isNaN(r)&&Number.isNaN(t.o[e])||(t.o[e]=r,t.R[e]=!0),!0},deleteProperty:function(t,e){return yi(t.t,e)!==void 0||e in t.t?(t.R[e]=!1,bi(t),vt(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var r=bt(t),o=Reflect.getOwnPropertyDescriptor(r,e);return o&&{writable:!0,configurable:t.i!==1||e!=="length",enumerable:o.enumerable,value:r[e]}},defineProperty:function(){Ie(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){Ie(12)}},go={};Gt(bo,(function(t,e){go[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}})),go.deleteProperty=function(t,e){return go.set.call(this,t,e,void 0)},go.set=function(t,e,r){return bo.set.call(this,t[0],e,r,t[0])};var Ou=(function(){function t(r){var o=this;this.O=Al,this.D=!0,this.produce=function(a,i,s){if(typeof a=="function"&&typeof i!="function"){var c=i;i=a;var d=o;return function(C){var O=this;C===void 0&&(C=c);for(var w=arguments.length,N=Array(w>1?w-1:0),E=1;E<w;E++)N[E-1]=arguments[E];return d.produce(C,(function(S){var A;return(A=i).call.apply(A,[O,S].concat(N))}))}}var u;if(typeof i!="function"&&Ie(6),s!==void 0&&typeof s!="function"&&Ie(7),$e(a)){var m=vl(o),h=Si(o,a,void 0),y=!0;try{u=i(h),y=!1}finally{y?sn(m):xi(m)}return typeof Promise<"u"&&u instanceof Promise?u.then((function(C){return mi(m,s),gi(C,m)}),(function(C){throw sn(m),C})):(mi(m,s),gi(u,m))}if(!a||typeof a!="object"){if((u=i(a))===void 0&&(u=a),u===_l&&(u=void 0),o.D&&Oi(u,!0),s){var b=[],x=[];Qe("Patches").M(a,u,b,x),s(b,x)}return u}Ie(21,a)},this.produceWithPatches=function(a,i){if(typeof a=="function")return function(u){for(var m=arguments.length,h=Array(m>1?m-1:0),y=1;y<m;y++)h[y-1]=arguments[y];return o.produceWithPatches(u,(function(b){return a.apply(void 0,[b].concat(h))}))};var s,c,d=o.produce(a,i,(function(u,m){s=u,c=m}));return typeof Promise<"u"&&d instanceof Promise?d.then((function(u){return[u,s,c]})):[d,s,c]},typeof r?.useProxies=="boolean"&&this.setUseProxies(r.useProxies),typeof r?.autoFreeze=="boolean"&&this.setAutoFreeze(r.autoFreeze)}var e=t.prototype;return e.createDraft=function(r){$e(r)||Ie(8),st(r)&&(r=Cu(r));var o=vl(this),a=Si(this,r,void 0);return a[J].C=!0,xi(o),a},e.finishDraft=function(r,o){var a=r&&r[J],i=a.A;return mi(i,o),gi(void 0,i)},e.setAutoFreeze=function(r){this.D=r},e.setUseProxies=function(r){r&&!Al&&Ie(20),this.O=r},e.applyPatches=function(r,o){var a;for(a=o.length-1;a>=0;a--){var i=o[a];if(i.path.length===0&&i.op==="replace"){r=i.value;break}}a>-1&&(o=o.slice(a+1));var s=Qe("Patches").$;return st(r)?s(r,o):this.produce(r,(function(c){return s(c,o)}))},t})(),Re=new Ou,Ru=Re.produce,Ig=Re.produceWithPatches.bind(Re),Pg=Re.setAutoFreeze.bind(Re),zg=Re.setUseProxies.bind(Re),Dg=Re.applyPatches.bind(Re),Ug=Re.createDraft.bind(Re),Fg=Re.finishDraft.bind(Re),dn=Ru;function Wt(t){"@babel/helpers - typeof";return Wt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Wt(t)}function Ml(t,e){if(Wt(t)!="object"||!t)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var o=r.call(t,e||"default");if(Wt(o)!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Tl(t){var e=Ml(t,"string");return Wt(e)=="symbol"?e:e+""}function kl(t,e,r){return(e=Tl(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Il(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter(function(a){return Object.getOwnPropertyDescriptor(t,a).enumerable})),r.push.apply(r,o)}return r}function _i(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?Il(Object(r),!0).forEach(function(o){kl(t,o,r[o])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Il(Object(r)).forEach(function(o){Object.defineProperty(t,o,Object.getOwnPropertyDescriptor(r,o))})}return t}function pe(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}var Pl=(function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"})(),Ni=function(){return Math.random().toString(36).substring(7).split("").join(".")},un={INIT:"@@redux/INIT"+Ni(),REPLACE:"@@redux/REPLACE"+Ni(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+Ni()}};function wu(t){if(typeof t!="object"||t===null)return!1;for(var e=t;Object.getPrototypeOf(e)!==null;)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}function Mi(t,e,r){var o;if(typeof e=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(pe(0));if(typeof e=="function"&&typeof r>"u"&&(r=e,e=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(pe(1));return r(Mi)(t,e)}if(typeof t!="function")throw new Error(pe(2));var a=t,i=e,s=[],c=s,d=!1;function u(){c===s&&(c=s.slice())}function m(){if(d)throw new Error(pe(3));return i}function h(C){if(typeof C!="function")throw new Error(pe(4));if(d)throw new Error(pe(5));var O=!0;return u(),c.push(C),function(){if(O){if(d)throw new Error(pe(6));O=!1,u();var N=c.indexOf(C);c.splice(N,1),s=null}}}function y(C){if(!wu(C))throw new Error(pe(7));if(typeof C.type>"u")throw new Error(pe(8));if(d)throw new Error(pe(9));try{d=!0,i=a(i,C)}finally{d=!1}for(var O=s=c,w=0;w<O.length;w++){var N=O[w];N()}return C}function b(C){if(typeof C!="function")throw new Error(pe(10));a=C,y({type:un.REPLACE})}function x(){var C,O=h;return C={subscribe:function(N){if(typeof N!="object"||N===null)throw new Error(pe(11));function E(){N.next&&N.next(m())}E();var S=O(E);return{unsubscribe:S}}},C[Pl]=function(){return this},C}return y({type:un.INIT}),o={dispatch:y,subscribe:h,getState:m,replaceReducer:b},o[Pl]=x,o}function _u(t){Object.keys(t).forEach(function(e){var r=t[e],o=r(void 0,{type:un.INIT});if(typeof o>"u")throw new Error(pe(12));if(typeof r(void 0,{type:un.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(pe(13))})}function zl(t){for(var e=Object.keys(t),r={},o=0;o<e.length;o++){var a=e[o];typeof t[a]=="function"&&(r[a]=t[a])}var i=Object.keys(r),s,c;try{_u(r)}catch(d){c=d}return function(u,m){if(u===void 0&&(u={}),c)throw c;if(0)var h;for(var y=!1,b={},x=0;x<i.length;x++){var C=i[x],O=r[C],w=u[C],N=O(w,m);if(typeof N>"u"){var E=m&&m.type;throw new Error(pe(14))}b[C]=N,y=y||N!==w}return y=y||i.length!==Object.keys(u).length,y?b:u}}function vr(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return e.length===0?function(o){return o}:e.length===1?e[0]:e.reduce(function(o,a){return function(){return o(a.apply(void 0,arguments))}})}function Dl(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return function(o){return function(){var a=o.apply(void 0,arguments),i=function(){throw new Error(pe(15))},s={getState:a.getState,dispatch:function(){return i.apply(void 0,arguments)}},c=e.map(function(d){return d(s)});return i=vr.apply(void 0,c)(a.dispatch),_i(_i({},a),{},{dispatch:i})}}}function Ul(t){var e=function(o){var a=o.dispatch,i=o.getState;return function(s){return function(c){return typeof c=="function"?c(a,i,t):s(c)}}};return e}var Fl=Ul();Fl.withExtraArgument=Ul;var Ti=Fl;var Wl=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,a){o.__proto__=a}||function(o,a){for(var i in a)Object.prototype.hasOwnProperty.call(a,i)&&(o[i]=a[i])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function o(){this.constructor=e}e.prototype=r===null?Object.create(r):(o.prototype=r.prototype,new o)}})(),Nu=function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},o,a,i,s;return s={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function c(u){return function(m){return d([u,m])}}function d(u){if(o)throw new TypeError("Generator is already executing.");for(;r;)try{if(o=1,a&&(i=u[0]&2?a.return:u[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,u[1])).done)return i;switch(a=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,a=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){r.label=u[1];break}if(u[0]===6&&r.label<i[1]){r.label=i[1],i=u;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(u);break}i[2]&&r.ops.pop(),r.trys.pop();continue}u=e.call(t,r)}catch(m){u=[6,m],a=0}finally{o=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},xr=function(t,e){for(var r=0,o=e.length,a=t.length;r<o;r++,a++)t[a]=e[r];return t},Mu=Object.defineProperty,Tu=Object.defineProperties,ku=Object.getOwnPropertyDescriptors,$l=Object.getOwnPropertySymbols,Iu=Object.prototype.hasOwnProperty,Pu=Object.prototype.propertyIsEnumerable,Bl=function(t,e,r){return e in t?Mu(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r},xt=function(t,e){for(var r in e||(e={}))Iu.call(e,r)&&Bl(t,r,e[r]);if($l)for(var o=0,a=$l(e);o<a.length;o++){var r=a[o];Pu.call(e,r)&&Bl(t,r,e[r])}return t},ki=function(t,e){return Tu(t,ku(e))},zu=function(t,e,r){return new Promise(function(o,a){var i=function(d){try{c(r.next(d))}catch(u){a(u)}},s=function(d){try{c(r.throw(d))}catch(u){a(u)}},c=function(d){return d.done?o(d.value):Promise.resolve(d.value).then(i,s)};c((r=r.apply(t,e)).next())})};var Du=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?vr:vr.apply(null,arguments)},oy=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}};function Uu(t){if(typeof t!="object"||t===null)return!1;var e=Object.getPrototypeOf(t);if(e===null)return!0;for(var r=e;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return e===r}function St(t,e){function r(){for(var o=[],a=0;a<arguments.length;a++)o[a]=arguments[a];if(e){var i=e.apply(void 0,o);if(!i)throw new Error("prepareAction did not return an object");return xt(xt({type:t,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:t,payload:o[0]}}return r.toString=function(){return""+t},r.type=t,r.match=function(o){return o.type===t},r}var Fu=(function(t){Wl(e,t);function e(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var a=t.apply(this,r)||this;return Object.setPrototypeOf(a,e.prototype),a}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return t.prototype.concat.apply(this,r)},e.prototype.prepend=function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return r.length===1&&Array.isArray(r[0])?new(e.bind.apply(e,xr([void 0],r[0].concat(this)))):new(e.bind.apply(e,xr([void 0],r.concat(this))))},e})(Array),$u=(function(t){Wl(e,t);function e(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var a=t.apply(this,r)||this;return Object.setPrototypeOf(a,e.prototype),a}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return t.prototype.concat.apply(this,r)},e.prototype.prepend=function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return r.length===1&&Array.isArray(r[0])?new(e.bind.apply(e,xr([void 0],r[0].concat(this)))):new(e.bind.apply(e,xr([void 0],r.concat(this))))},e})(Array);function zi(t){return $e(t)?dn(t,function(){}):t}function Bu(t){return typeof t=="boolean"}function Hu(){return function(e){return Gu(e)}}function Gu(t){t===void 0&&(t={});var e=t.thunk,r=e===void 0?!0:e,o=t.immutableCheck,a=o===void 0?!0:o,i=t.serializableCheck,s=i===void 0?!0:i,c=t.actionCreatorCheck,d=c===void 0?!0:c,u=new Fu;if(r&&(Bu(r)?u.push(Ti):u.push(Ti.withExtraArgument(r.extraArgument))),0){if(a)var m;if(s)var h;if(d)var y}return u}var Ii=!0;function jl(t){var e=Hu(),r=t||{},o=r.reducer,a=o===void 0?void 0:o,i=r.middleware,s=i===void 0?e():i,c=r.devTools,d=c===void 0?!0:c,u=r.preloadedState,m=u===void 0?void 0:u,h=r.enhancers,y=h===void 0?void 0:h,b;if(typeof a=="function")b=a;else if(Uu(a))b=zl(a);else throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');var x=s;if(typeof x=="function"&&(x=x(e),!Ii&&!Array.isArray(x)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!Ii&&x.some(function(S){return typeof S!="function"}))throw new Error("each middleware provided to configureStore must be a function");var C=Dl.apply(void 0,x),O=vr;d&&(O=Du(xt({trace:!Ii},typeof d=="object"&&d)));var w=new $u(C),N=w;Array.isArray(y)?N=xr([C],y):typeof y=="function"&&(N=y(w));var E=O.apply(void 0,N);return Mi(b,m,E)}function Vl(t){var e={},r=[],o,a={addCase:function(i,s){var c=typeof i=="string"?i:i.type;if(!c)throw new Error("`builder.addCase` cannot be called with an empty action type");if(c in e)throw new Error("`builder.addCase` cannot be called with two reducers for the same action type");return e[c]=s,a},addMatcher:function(i,s){return r.push({matcher:i,reducer:s}),a},addDefaultCase:function(i){return o=i,a}};return t(a),[e,r,o]}function Wu(t){return typeof t=="function"}function ju(t,e,r,o){r===void 0&&(r=[]);var a=typeof e=="function"?Vl(e):[e,r,o],i=a[0],s=a[1],c=a[2],d;if(Wu(t))d=function(){return zi(t())};else{var u=zi(t);d=function(){return u}}function m(h,y){h===void 0&&(h=d());var b=xr([i[y.type]],s.filter(function(x){var C=x.matcher;return C(y)}).map(function(x){var C=x.reducer;return C}));return b.filter(function(x){return!!x}).length===0&&(b=[c]),b.reduce(function(x,C){if(C)if(st(x)){var O=x,w=C(O,y);return w===void 0?x:w}else{if($e(x))return dn(x,function(N){return C(N,y)});var w=C(x,y);if(w===void 0){if(x===null)return x;throw Error("A case reducer on a non-draftable value must not return undefined")}return w}return x},h)}return m.getInitialState=d,m}function Vu(t,e){return t+"/"+e}function Kl(t){var e=t.name;if(!e)throw new Error("`name` is a required option for createSlice");typeof process<"u";var r=typeof t.initialState=="function"?t.initialState:zi(t.initialState),o=t.reducers||{},a=Object.keys(o),i={},s={},c={};a.forEach(function(m){var h=o[m],y=Vu(e,m),b,x;"reducer"in h?(b=h.reducer,x=h.prepare):b=h,i[m]=b,s[y]=b,c[m]=x?St(y,x):St(y)});function d(){var m=typeof t.extraReducers=="function"?Vl(t.extraReducers):[t.extraReducers],h=m[0],y=h===void 0?{}:h,b=m[1],x=b===void 0?[]:b,C=m[2],O=C===void 0?void 0:C,w=xt(xt({},y),s);return ju(r,function(N){for(var E in w)N.addCase(E,w[E]);for(var S=0,A=x;S<A.length;S++){var T=A[S];N.addMatcher(T.matcher,T.reducer)}O&&N.addDefaultCase(O)})}var u;return{name:e,reducer:function(m,h){return u||(u=d()),u(m,h)},actions:c,caseReducers:i,getInitialState:function(){return u||(u=d()),u.getInitialState()}}}var Ku="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Zu=function(t){t===void 0&&(t=21);for(var e="",r=t;r--;)e+=Ku[Math.random()*64|0];return e},qu=["name","message","stack","code"],Pi=(function(){function t(e,r){this.payload=e,this.meta=r}return t})(),Hl=(function(){function t(e,r){this.payload=e,this.meta=r}return t})(),Yu=function(t){if(typeof t=="object"&&t!==null){for(var e={},r=0,o=qu;r<o.length;r++){var a=o[r];typeof t[a]=="string"&&(e[a]=t[a])}return e}return{message:String(t)}},sy=(function(){function t(e,r,o){var a=St(e+"/fulfilled",function(m,h,y,b){return{payload:m,meta:ki(xt({},b||{}),{arg:y,requestId:h,requestStatus:"fulfilled"})}}),i=St(e+"/pending",function(m,h,y){return{payload:void 0,meta:ki(xt({},y||{}),{arg:h,requestId:m,requestStatus:"pending"})}}),s=St(e+"/rejected",function(m,h,y,b,x){return{payload:b,error:(o&&o.serializeError||Yu)(m||"Rejected"),meta:ki(xt({},x||{}),{arg:y,requestId:h,rejectedWithValue:!!b,requestStatus:"rejected",aborted:m?.name==="AbortError",condition:m?.name==="ConditionError"})}}),c=!1,d=typeof AbortController<"u"?AbortController:(function(){function m(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return m.prototype.abort=function(){},m})();function u(m){return function(h,y,b){var x=o?.idGenerator?o.idGenerator(m):Zu(),C=new d,O,w=!1;function N(S){O=S,C.abort()}var E=(function(){return zu(this,null,function(){var S,A,T,$,X,G,I;return Nu(this,function(U){switch(U.label){case 0:return U.trys.push([0,4,,5]),$=(S=o?.condition)==null?void 0:S.call(o,m,{getState:y,extra:b}),Ju($)?[4,$]:[3,2];case 1:$=U.sent(),U.label=2;case 2:if($===!1||C.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return w=!0,X=new Promise(function(j,ie){return C.signal.addEventListener("abort",function(){return ie({name:"AbortError",message:O||"Aborted"})})}),h(i(x,m,(A=o?.getPendingMeta)==null?void 0:A.call(o,{requestId:x,arg:m},{getState:y,extra:b}))),[4,Promise.race([X,Promise.resolve(r(m,{dispatch:h,getState:y,extra:b,requestId:x,signal:C.signal,abort:N,rejectWithValue:function(j,ie){return new Pi(j,ie)},fulfillWithValue:function(j,ie){return new Hl(j,ie)}})).then(function(j){if(j instanceof Pi)throw j;return j instanceof Hl?a(j.payload,x,m,j.meta):a(j,x,m)})])];case 3:return T=U.sent(),[3,5];case 4:return G=U.sent(),T=G instanceof Pi?s(null,x,m,G.payload,G.meta):s(G,x,m),[3,5];case 5:return I=o&&!o.dispatchConditionRejection&&s.match(T)&&T.meta.condition,I||h(T),[2,T]}})})})();return Object.assign(E,{abort:N,requestId:x,arg:m,unwrap:function(){return E.then(Xu)}})}}return Object.assign(u,{pending:i,rejected:s,fulfilled:a,typePrefix:e})}return t.withTypes=function(){return t},t})();function Xu(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function Ju(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var Zl="listener",ql="completed",Yl="cancelled",cy="task-"+Yl,ly="task-"+ql,dy=Zl+"-"+Yl,uy=Zl+"-"+ql;var Di="listenerMiddleware";var fy=St(Di+"/add"),py=St(Di+"/removeAll"),hy=St(Di+"/remove");var Gl,my=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(t){return(Gl||(Gl=Promise.resolve())).then(t).catch(function(e){return setTimeout(function(){throw e},0)})},Qu=function(t){return function(e){setTimeout(e,t)}},gy=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Qu(10);wl();window.ftReduxStores||(window.ftReduxStores={});var jt=class t extends nt{static get(e){var r;let o=typeof e=="string"?e:e.name,a=typeof e=="string"?void 0:e,i=window.ftReduxStores[o];if(mr(i))return i;if(a==null)return;let s=Kl({...a,reducers:(r=a.reducers)!==null&&r!==void 0?r:{}}),c=jl({reducer:(d,u)=>{if(u.type==="CLEAR_FT_REDUX_STORE"){let m=Ue(s.getInitialState());for(let h of u.keeping)m[h]=(d??m)[h];return m}else if(typeof u.type=="string"&&u.type.startsWith("DEFAULT_VALUE_SETTER__"))return{...d,...u.overwrites};return s.reducer(d,u)}});return window.ftReduxStores[a.name]=new t(s,c,a.eventBus)}constructor(e,r,o){super(),this.reduxSlice=e,this.reduxStore=r,this.isFtReduxStore=!0,this.commands=new ho;let a=i=>i!=null?JSON.parse(JSON.stringify(i)):i;this.actions=new Proxy(this.reduxSlice.actions,{get:(i,s,c)=>{let d=s,u=i[d];return u?(...m)=>{let h=u(...m.map(a));return this.reduxStore.dispatch(h),h}:m=>{this.setState({[d]:a(m)})}}}),this.eventBus=o??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:[]})}clearKeeping(...e){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:e})}setState(e){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(e).join("_"),overwrites:e})}get dispatch(){throw new Error("Don't use this method, actions are automatically dispatched when called.")}[Symbol.observable](){return this.reduxStore[Symbol.observable]()}getState(){return this.reduxStore.getState()}replaceReducer(e){throw new Error("Not implemented yet.")}subscribe(e){return this.reduxStore.subscribe(e)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}};function ef(){var t;for(let e of Object.values((t=window.ftReduxStores)!==null&&t!==void 0?t:{}))mr(e)&&e.clear()}var fn=class{constructor(e,r,o){this.store=e,this.valueSelector=r,this.callback=o}watch(){return this.stop(),this.lastValue=this.valueSelector(this.store.getState()),this.unsubscribe=this.store.subscribe(()=>{let e=this.store.getState(),r=this.valueSelector(e);ot(this.lastValue,r)&&(this.callback(r,e),this.lastValue=r)}),this}stop(){return this.unsubscribe!=null&&(this.unsubscribe(),this.unsubscribe=void 0),this.lastValue=void 0,this}};function tf(t,e,r){return new fn(t,e,r).watch()}var vo=class{constructor(){this.requestConsumers=new Map}getOrCreateRequestConsumers(e){var r;return(r=this.requestConsumers.get(e))!==null&&r!==void 0?r:this.requestConsumers.set(e,new Set).get(e)}registerComponent(e,r){for(let o of r)this.getOrCreateRequestConsumers(o).add(e).size==1&&this.onNewNeededRequest(o)}unregisterComponent(e,r){for(let o of r)this.getOrCreateRequestConsumers(o).delete(e)}isRequestNeeded(e){return this.getOrCreateRequestConsumers(e).size>0}};var Bi={};W(Bi,{scrollHelper:()=>rf});var Fi,pn=new Map,$i=class{lock(e,r){if(r){let o=pn.get(r);if(o==null||o===e)return pn.set(r,e),r}}release(e,r){r&&pn.get(r)===e&&pn.delete(r)}findFirstScrollableParent(e){var r;let o,a;for(let i of ua(e)){let s=i,c=this.elementCanScroll(s);if(c&&s.clientHeight&&s.clientHeight<s.scrollHeight){o=s;break}else c&&a==null&&(a=s)}return(r=o??a)!==null&&r!==void 0?r:document.body}elementCanScroll(e){try{return["auto","scroll"].includes(getComputedStyle(e).overflowY)&&!["contents"].includes(getComputedStyle(e).display)}catch{return!1}}getAbsoluteScrollOffset(e,r){var o,a;let i=0;for(;r&&r.offsetParent!==e.offsetParent;)i+=(o=r.offsetTop)!==null&&o!==void 0?o:0,r=r.offsetParent;return i+((a=r?.offsetTop)!==null&&a!==void 0?a:0)-e.offsetTop}computeTopOffsetRatio(e,r){if(typeof e=="number")return e;switch(e){case"end":return 1;case"center":return .5;case"nearest":return r;default:return 0}}scrollIntoViewIfPossible(e,r){let o=this.findFirstScrollableParent(e);if(e&&this.lock(this,o)){let a=this.getAbsoluteScrollOffset(o,e),i=a-o.clientHeight+e.clientHeight,s=a,c=kt(0,(s-o.scrollTop)/(s-i),1),d=this.computeTopOffsetRatio(r?.position,c)*(i-s)+s;o.scrollTo({behavior:r?.behavior,top:d})}else console.warn("Could not scroll element into view because the scrollable parent is already locked",e,o);this.release(this,o)}};window.FluidTopicsScrollHelper=(Fi=window.FluidTopicsScrollHelper)!==null&&Fi!==void 0?Fi:new $i;var rf=window.FluidTopicsScrollHelper;var Gi={};W(Gi,{SearchPlaceConverter:()=>Er,SearchPlaceQueryParams:()=>H,isSearchPlaceQueryParams:()=>U1,serializeRequest:()=>af});var Xl;(function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"})(Xl||(Xl={}));var Jl;(function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"})(Jl||(Jl={}));var Ql;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(Ql||(Ql={}));var e1;(function(t){t.STRUCTURED_DOCUMENT="STRUCTURED_DOCUMENT",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.SHARED_PERSONAL_BOOK="SHARED_PERSONAL_BOOK",t.PERSONAL_BOOK="PERSONAL_BOOK",t.ATTACHMENT="ATTACHMENT",t.RESOURCE="RESOURCE",t.HTML_PACKAGE="HTML_PACKAGE"})(e1||(e1={}));var t1;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(t1||(t1={}));var r1;(function(t){t.VALUE="VALUE",t.DATE="DATE",t.RANGE="RANGE"})(r1||(r1={}));var o1;(function(t){t.OFFICIAL="OFFICIAL",t.AI="AI"})(o1||(o1={}));var n1;(function(t){t.BOOKMARK__CREATE="BOOKMARK__CREATE",t.BOOKMARK__DELETE="BOOKMARK__DELETE",t.CASE_DEFLECTION__START="CASE_DEFLECTION__START",t.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",t.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",t.CHATBOT__RATE="CHATBOT__RATE",t.COLLECTION__CREATE="COLLECTION__CREATE",t.COLLECTION__UPDATE="COLLECTION__UPDATE",t.COLLECTION__DELETE="COLLECTION__DELETE",t.CUSTOM_EVENT__TRIGGER="CUSTOM_EVENT__TRIGGER",t.DOCUMENT__ON_DEMAND_TRANSLATE="DOCUMENT__ON_DEMAND_TRANSLATE",t.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",t.DOCUMENT__PRINT="DOCUMENT__PRINT",t.DOCUMENT__PROCESS="DOCUMENT__PROCESS",t.DOCUMENT__RATE="DOCUMENT__RATE",t.DOCUMENT__SEARCH="DOCUMENT__SEARCH",t.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",t.DOCUMENT__UNRATE="DOCUMENT__UNRATE",t.FEEDBACK__SEND="FEEDBACK__SEND",t.AI__COMPLETED_QUERY="AI__COMPLETED_QUERY",t.AI__RATE="AI__RATE",t.AI_CASE_DEFLECTION__START="AI_CASE_DEFLECTION__START",t.AI_CASE_DEFLECTION__OPEN_TICKET="AI_CASE_DEFLECTION__OPEN_TICKET",t.KHUB__PROCESS="KHUB__PROCESS",t.KHUB__SEARCH="KHUB__SEARCH",t.LABELS__DOWNLOAD="LABELS__DOWNLOAD",t.LINK__SHARE="LINK__SHARE",t.PAGE__DISPLAY="PAGE__DISPLAY",t.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",t.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",t.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",t.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",t.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",t.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",t.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",t.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",t.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",t.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",t.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",t.TOPIC__AI_TRANSLATE="TOPIC__AI_TRANSLATE",t.TOPIC__RATE="TOPIC__RATE",t.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",t.TOPIC__UNRATE="TOPIC__UNRATE",t.USER__LOGIN="USER__LOGIN",t.USER__LOGOUT="USER__LOGOUT",t.HEARTBEAT="HEARTBEAT"})(n1||(n1={}));var a1;(function(t){t.STANDARD="STANDARD",t.STRUCTURAL="STRUCTURAL"})(a1||(a1={}));var i1;(function(t){t.THIRD_PARTY="THIRD_PARTY",t.OFF_THE_GRID="OFF_THE_GRID",t.CONTENT_PACKAGER="CONTENT_PACKAGER",t.PAGES="PAGES",t.DESIGNED_READER="DESIGNED_READER"})(i1||(i1={}));var s1;(function(t){t.HOMEPAGE="HOMEPAGE",t.CUSTOM="CUSTOM",t.HEADER="HEADER",t.READER="READER",t.TOPIC_TEMPLATE="TOPIC_TEMPLATE",t.SEARCH="SEARCH",t.SEARCH_RESULT="SEARCH_RESULT",t.SEARCH_ANNOUNCEMENT="SEARCH_ANNOUNCEMENT",t.LINK_PREVIEW="LINK_PREVIEW",t.UD_VIEWER="UD_VIEWER",t.ASSET_VIEWER="ASSET_VIEWER"})(s1||(s1={}));var c1;(function(t){t.CLASSIC="CLASSIC",t.CUSTOM="CUSTOM",t.DESIGNER="DESIGNER"})(c1||(c1={}));var l1;(function(t){t.AND="AND",t.OR="OR",t.MONOVALUED="MONOVALUED"})(l1||(l1={}));var d1;(function(t){t.NONE="NONE",t.ALPHABET="ALPHABET",t.VERSION="VERSION"})(d1||(d1={}));var u1;(function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"})(u1||(u1={}));var f1;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"})(f1||(f1={}));var Sr;(function(t){t.OPTIONAL="OPTIONAL",t.MANDATORY="MANDATORY"})(Sr||(Sr={}));var p1;(function(t){t.ASC="ASC",t.DESC="DESC"})(p1||(p1={}));var h1;(function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"})(h1||(h1={}));var Hi;(function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"})(Hi||(Hi={}));var C1=t=>Object.keys(Hi).includes(t);var m1;(function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(m1||(m1={}));var g1;(function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"})(g1||(g1={}));var y1;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(y1||(y1={}));var Cr;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(Cr||(Cr={}));var E1=t=>Object.keys(Cr).includes(t);var b1;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.HTML_PACKAGE="HTML_PACKAGE",t.HTML_PACKAGE_PAGE="HTML_PACKAGE_PAGE"})(b1||(b1={}));var v1;(function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS",t.ALL_TOPICS="ALL_TOPICS",t.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(v1||(v1={}));var x1;(function(t){t.PLAIN_TEXT="PLAIN_TEXT",t.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",t.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(x1||(x1={}));var ae;(function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.GENERATIVE_AI_USER="GENERATIVE_AI_USER",t.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_USER",t.ANNOUNCEMENT_ADMIN="ANNOUNCEMENT_ADMIN",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN"})(ae||(ae={}));var Pe;(function(t){t.SEARCHES="SEARCHES",t.BOOKMARKS="BOOKMARKS",t.BOOKS="BOOKS",t.COLLECTIONS="COLLECTIONS"})(Pe||(Pe={}));var S1;(function(t){t.UNAUTHENTICATED="UNAUTHENTICATED",t.USER_INCOMPLETE="USER_INCOMPLETE",t.MFA_REQUIRED="MFA_REQUIRED",t.AUTHENTICATED="AUTHENTICATED"})(S1||(S1={}));var A1;(function(t){t.UNREACHABLE="UNREACHABLE",t.UNAUTHORIZED="UNAUTHORIZED",t.FORBIDDEN="FORBIDDEN",t.INCOMPATIBLE="INCOMPATIBLE",t.FAILED="FAILED",t.OK="OK"})(A1||(A1={}));var L1;(function(t){t.VALID="VALID",t.INVALID="INVALID"})(L1||(L1={}));var O1;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SUMMARY="SUMMARY",t.SEMANTIC_SEARCH="SEMANTIC_SEARCH",t.CHATBOT_INSTRUCTIONS="CHATBOT_INSTRUCTIONS",t.DOCUMENTATION="DOCUMENTATION",t.OTHER="OTHER"})(O1||(O1={}));var R1;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SLOW="SLOW",t.OTHER="OTHER"})(R1||(R1={}));var w1;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(w1||(w1={}));var _1;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(_1||(_1={}));var N1;(function(t){t.TEXT="TEXT",t.HTML="HTML"})(N1||(N1={}));var M1;(function(t){t.IN_PROGRESS="IN_PROGRESS",t.ERROR="ERROR",t.DONE="DONE"})(M1||(M1={}));var T1;(function(t){t.HTML="HTML",t.MARKDOWN="MARKDOWN"})(T1||(T1={}));var k1;(function(t){t.SOURCES="SOURCES",t.ENRICH_AND_CLEAN="ENRICH_AND_CLEAN",t.VOCABULARIES="VOCABULARIES",t.METADATA="METADATA",t.PRETTY_URL="PRETTY_URL",t.ACCESS_RULE="ACCESS_RULE",t.DESIGNED_PAGES="DESIGNED_PAGES",t.THEME_STUDIO="THEME_STUDIO",t.PORTAL_GENERAL="PORTAL_GENERAL",t.ASSETS="ASSETS",t.CODE_LIBRARY="CODE_LIBRARY",t.THEME="THEME",t.CONTENT_STYLES="CONTENT_STYLES",t.HOMEPAGE="HOMEPAGE",t.CLASSIC_SEARCH_PAGE="CLASSIC_SEARCH_PAGE",t.CLASSIC_READER_PAGE="CLASSIC_READER_PAGE",t.PORTAL_METADATA="PORTAL_METADATA",t.LANGUAGES="LANGUAGES",t.PRINT_TEMPLATES="PRINT_TEMPLATES",t.OFFLINE="OFFLINE",t.CUSTOM_JS="CUSTOM_JS",t.CONFIDENTIALITY="CONFIDENTIALITY",t.NOTIFICATIONS="NOTIFICATIONS"})(k1||(k1={}));var I1;(function(t){t.MAP="MAP",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT"})(I1||(I1={}));var of={[ae.PERSONAL_BOOK_SHARE_USER]:[ae.PERSONAL_BOOK_USER],[ae.HTML_EXPORT_USER]:[ae.PERSONAL_BOOK_USER],[ae.PDF_EXPORT_USER]:[ae.PERSONAL_BOOK_USER],[ae.KHUB_ADMIN]:[ae.CONTENT_PUBLISHER],[ae.ADMIN]:[ae.KHUB_ADMIN,ae.USERS_ADMIN,ae.PORTAL_ADMIN,ae.BEHAVIOR_DATA_USER],[ae.GENERATIVE_AI_EXPORT_USER]:[ae.GENERATIVE_AI_USER]};function P1(t,e){return t===e||(of[t]??[]).some(r=>P1(r,e))}function z1(t,e){return t==null?!1:(Array.isArray(t)?t:Array.isArray(t.roles)?t.roles:Array.isArray(t.profile?.roles)?t.profile.roles:[]).some(o=>P1(o,e))}function nf(t){return`"${t}"`}function D1(t){return t.startsWith('"')&&t.endsWith('"')?t.replace(/(^"+)|("+$)/g,""):t}function af(t,e){return new Er(t).serialize(e)}var H;(function(t){t.LOCALE="content-lang",t.QUERY="query",t.SCOPE="scope",t.FILTERS="filters",t.VIRTUAL_FIELD="virtual-field",t.PERIOD="period",t.VALUE_FILTERS="value-filters",t.DATE_FILTERS="date-filters",t.RANGE_FILTERS="range-filters",t.SORT="sort",t.PER_PAGE="per-page",t.KEYWORD_MATCH="keyword-match"})(H||(H={}));var sf=new Set(Object.values(H));function U1(t){return sf.has(t)}var Er=class{constructor(e,r=20,o=!1,a="en-US"){this.baseUrl=e,this.defaultPerPage=r,this.allLanguagesAllowed=o,this.defaultContentLocale=a,this.scopeMapping={documents:"DOCUMENTS",topics:"ALL_TOPICS"},this.filtersEscapeMapping=[["*","\\*","[ft-escaped-star-character]"],["~","\\\\~","[ft-escaped-tilde-character]"],["_","\\\\\\\\_","[ft-escaped-underscore-character]"]]}serialize(e,r){return this.serializeToCurrentPageIfPossible(e,r??"/search")}serializeToCurrentPageIfPossible(e,r){let o=r==null||r.trim().length===0,a=new URL(o?window.location.href:`${this.baseUrl.replace(/\/+$/,"")}${r}`);return a.search=this.toURLSearchParams(e),a.toString()}toURLSearchParams(e,r=!1){var o,a,i,s,c,d,u,m,h,y,b;let x=new URLSearchParams;e.contentLocale?(!r||e.contentLocale!==this.defaultContentLocale)&&x.append(H.LOCALE,e.contentLocale):x.append(H.LOCALE,this.allLanguagesAllowed?"all":this.defaultContentLocale),((o=e.query)===null||o===void 0?void 0:o.length)>0&&x.append(H.QUERY,e.query);let C=(i=(a=e.metadataFilters)===null||a===void 0?void 0:a.filter(S=>S.valueFilter&&!S.valueFilter.negative))!==null&&i!==void 0?i:[];if(C.length>0){let S=C.map(A=>{var T,$;let X=(($=(T=A.valueFilter)===null||T===void 0?void 0:T.values)!==null&&$!==void 0?$:[]).map(G=>this.escapeFilters(G)).map(G=>nf(D1(G))).join("_");return`${A.key}~${X}`}).join("*");x.append(H.VALUE_FILTERS,S)}let O=(c=(s=e.metadataFilters)===null||s===void 0?void 0:s.filter(S=>S.dateFilter))!==null&&c!==void 0?c:[];if(O.length>0){let S=O.map(A=>{var T;return`${A.key}~${(T=A.dateFilter)===null||T===void 0?void 0:T.type.toLowerCase()}`}).join("*");x.append(H.DATE_FILTERS,S)}let w=(u=(d=e.metadataFilters)===null||d===void 0?void 0:d.filter(S=>S.rangeFilter))!==null&&u!==void 0?u:[];if(w.length>0){let S=w.map(A=>{var T,$;return`${A.key}~${(T=A.rangeFilter)===null||T===void 0?void 0:T.from}_${($=A.rangeFilter)===null||$===void 0?void 0:$.to}`}).join("*");x.append(H.RANGE_FILTERS,S)}e.virtualField&&e.virtualField!=="EVERYWHERE"&&x.append(H.VIRTUAL_FIELD,e.virtualField.toLowerCase()),e.scope&&e.scope!=="DEFAULT"&&x.append(H.SCOPE,e.scope.toLowerCase()),e.sortId!=null&&x.append(H.SORT,e.sortId),!((m=e.paging)===null||m===void 0)&&m.perPage&&((y=(h=e.paging)===null||h===void 0?void 0:h.perPage)!==null&&y!==void 0?y:this.defaultPerPage)!=this.defaultPerPage&&x.append(H.PER_PAGE,String(e.paging.perPage)),e.keywordMatch!=null&&x.append(H.KEYWORD_MATCH,e.keywordMatch.toLowerCase());let N=(b=e.otherQueryParams)!==null&&b!==void 0?b:{};for(let S in N)x.append(S,N[S]);let E=new Array;return x.forEach((S,A)=>{E.push(this.encodeQueryString(A)+"="+this.encodeQueryString(S))}),encodeURI(E.join("&")).replace(/#/g,"%23")}encodeQueryString(e){return encodeURIComponent(e).replace(/%20/g,"+")}parse(e){var r;let o=e.split("?"),a=this.fromURLSearchParams(o.slice(1).join("?")),i=o[0].split("/search/")[1];return i==null?a:{...a,scope:(r=this.scopeMapping[i])!==null&&r!==void 0?r:a.scope}}fromURLSearchParams(e){var r,o,a,i,s,c;try{e=decodeURI(e).replace(/%23/g,"#")}catch(w){console.warn("Could not decode search request query params, fallback on raw value",w)}let d=new URLSearchParams(e),u=d.get(H.LOCALE)==="all"?void 0:d.get(H.LOCALE),m=((r=d.get(H.VIRTUAL_FIELD))!==null&&r!==void 0?r:"EVERYWHERE").toUpperCase(),h=(o=d.get(H.SORT))===null||o===void 0?void 0:o.toLowerCase(),y=(a=d.get(H.SCOPE))!==null&&a!==void 0?a:"default",b=+((i=d.get(H.PER_PAGE))!==null&&i!==void 0?i:this.defaultPerPage),x=d.get(H.KEYWORD_MATCH),C=x?x.toUpperCase()===Sr.MANDATORY?Sr.MANDATORY:Sr.OPTIONAL:void 0,O={};for(let w of d.keys())U1(w)||(O[w]=d.get(w));return{contentLocale:u??(this.allLanguagesAllowed?void 0:this.defaultContentLocale),query:(s=d.get(H.QUERY))!==null&&s!==void 0?s:"",scope:(c=this.scopeMapping[y])!==null&&c!==void 0?c:"DEFAULT",virtualField:C1(m)?m:"EVERYWHERE",sortId:h,metadataFilters:this.parseCompatFilters(d),facets:[],paging:{page:1,perPage:kt(1,isNaN(b)?this.defaultPerPage:b,1e3)},keywordMatch:C,otherQueryParams:O}}parseCompatFilters(e){var r,o,a,i,s,c;let d=[];return e.has(H.FILTERS)&&(d=this.parseValueFilters((r=e.get(H.FILTERS))!==null&&r!==void 0?r:"")),(o=e.has(H.PERIOD))!==null&&o!==void 0&&o&&(d=[...d,...this.parseLegacyPeriodFilter(((a=e.get(H.PERIOD))!==null&&a!==void 0?a:"").toUpperCase())]),[...d,...this.parseValueFilters((i=e.get(H.VALUE_FILTERS))!==null&&i!==void 0?i:""),...this.parseDateFilters((s=e.get(H.DATE_FILTERS))!==null&&s!==void 0?s:""),...this.parseRangeFilters((c=e.get(H.RANGE_FILTERS))!==null&&c!==void 0?c:"")]}splitUnknownFilter(e){return this.superEscapeFilters(e).split("*").map(r=>r.split("~"))}parseValueFilters(e){return e.length===0?[]:this.splitUnknownFilter(e).map(r=>({key:r[0],valueFilter:{values:r[1].split("_").map(D1).map(o=>this.unescapeFilterValue(o)),negative:!1}}))}parseDateFilters(e){return e.length===0?[]:this.splitUnknownFilter(e).map(r=>({key:r[0],dateFilter:{type:Cr[r[1].toUpperCase()]}}))}parseRangeFilters(e){return e.length===0?[]:this.splitUnknownFilter(e).map(r=>({key:r[0],rangeFilter:{from:r[1].split("_")[0],to:r[1].split("_")[1]}}))}escapeFilters(e){for(let[r,o,a]of this.filtersEscapeMapping)e=e.replaceAll(r,o);return e}superEscapeFilters(e){for(let[r,o,a]of this.filtersEscapeMapping)e=e.replaceAll(o,a);return e}unescapeFilterValue(e){for(let[r,o,a]of this.filtersEscapeMapping)e=e.replaceAll(a,r);return e}parseLegacyPeriodFilter(e){if(E1(e))return[{key:"ft:lastEdition",dateFilter:{type:Cr[e]}}];if(e.startsWith("CUSTOM_")){let[r,o,a]=e.split("_");return[{key:"ft:lastEdition",rangeFilter:{from:o,to:a}}]}return[]}static clearSearchParamsInUrl(e){let r=new URL(e);return[H.LOCALE,H.FILTERS,H.VALUE_FILTERS,H.DATE_FILTERS,H.RANGE_FILTERS].forEach(a=>{r.searchParams.delete(a)}),r.toString()}static updateLocaleParamInUrl(e,r){let o=new URL(e);return o.searchParams.delete(H.LOCALE),r!==void 0&&o.searchParams.append(H.LOCALE,r),o.toString()}};var Vi={};W(Vi,{toFtFormComponent:()=>ji});var Wi=Symbol("elementInternals"),ji=de(Symbol("toFtFormComponent"),function(t){class e extends t{static get formAssociated(){return!0}get form(){return this[Wi].form}constructor(...o){super(o),this[Wi]=this.attachInternals()}setFormValue(o){this[Wi].setFormValue(o)}}return e});var Ki={};W(Ki,{DateFormatter:()=>Vt});var Vt=class{static format(e,r,o,a,i){return window.moment?window.moment(e).locale(r).format(this.getMomentDateFormat(o,a,!!i)):this.getIntlDateTime(e,r,o,a,!!i)}static getMomentDateFormat(e,r,o){return o?"LT":e?r?"lll":"ll":r?"L LT":"L"}static getIntlDateTime(e,r,o,a,i){let s=typeof e=="string"?new Date(e):e,c=new Intl.DateTimeFormat(r,{dateStyle:o?"medium":"short"}).format(s),d=new Intl.DateTimeFormat(r,{timeStyle:"short"}).format(s);return i?d:a?`${c} ${d}`:c}static getTimezoneAsString(){let e=o=>String(Math.floor(o)).padStart(2,"0"),r=new Date().getTimezoneOffset();return`${r<0?"+":"-"}${e(Math.abs(r)/60)}:${e(Math.abs(r)%60)}`}};var qi={};W(qi,{ALL_KEYS_VALUE:()=>Zi,SameWindowStorageEvent:()=>Ar});var Zi="__all__",Ar=class extends CustomEvent{constructor(e,r,o){super("same-window-storage",{detail:{key:e,oldValue:r,newValue:o}})}keyMatch(e){return this.detail.key.includes(e)||this.detail.key==Zi}};Storage.prototype.setItem=new Proxy(Storage.prototype.setItem,{apply(t,e,r){let o=e.getItem(r[0]);Reflect.apply(t,e,r),window.dispatchEvent(new Ar(r[0],o,r[1]))}});Storage.prototype.removeItem=new Proxy(Storage.prototype.removeItem,{apply(t,e,r){let o=e.getItem(r[0]);Reflect.apply(t,e,r),window.dispatchEvent(new Ar(r[0],o))}});Storage.prototype.clear=new Proxy(Storage.prototype.clear,{apply(t,e,r){Reflect.apply(t,e,r),window.dispatchEvent(new Ar(Zi))}});var Xi={};W(Xi,{FocusMainContentEvent:()=>Yi});var Yi=class extends Event{constructor(){super("ft-focus-main-content",{composed:!0,bubbles:!0})}};var F1={};window.FluidTopicsA11yHints={isKeyboardNavigation:!1,lastPressedKey:""};function cf(t){(t.key==="Enter"||t.key===" "||t.key==="Tab")&&(window.FluidTopicsA11yHints.isKeyboardNavigation=!0),window.FluidTopicsA11yHints.lastPressedKey=t.key}function lf(t){window.FluidTopicsA11yHints.isKeyboardNavigation=t.detail==0}document.addEventListener("keydown",cf);document.addEventListener("click",lf);var $1=z`
48
48
  .sr-only {
49
49
  position:absolute;
50
50
  left:-10000px;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluid-topics/ftds-chip",
3
- "version": "2.1.5",
3
+ "version": "2.1.6",
4
4
  "description": "The design system chip component",
5
5
  "keywords": [
6
6
  "Lit"
@@ -20,14 +20,14 @@
20
20
  },
21
21
  "dependencies": {
22
22
  "@fluid-topics/design-system-variables": "3.5.0",
23
- "@fluid-topics/ft-wc-utils": "2.1.5",
24
- "@fluid-topics/ftds-button": "2.1.5",
25
- "@fluid-topics/ftds-icon": "2.1.5",
26
- "@fluid-topics/ftds-typography": "2.1.5",
23
+ "@fluid-topics/ft-wc-utils": "2.1.6",
24
+ "@fluid-topics/ftds-button": "2.1.6",
25
+ "@fluid-topics/ftds-icon": "2.1.6",
26
+ "@fluid-topics/ftds-typography": "2.1.6",
27
27
  "lit": "3.1.0"
28
28
  },
29
29
  "devDependencies": {
30
- "@fluid-topics/ft-wc-test-utils": "2.1.5"
30
+ "@fluid-topics/ft-wc-test-utils": "2.1.6"
31
31
  },
32
- "gitHead": "cea42544a196f1f784982f8a666a27c534578779"
32
+ "gitHead": "70ba8e6b58f0f1c74a92965f3b7dbf3db605698e"
33
33
  }