@fluid-topics/ft-filter 1.3.49 → 1.3.51

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.
@@ -540,7 +540,7 @@ Also for action icons.`,s.colorGray200),contentGlobalSubtle:r.extend("--ftds-con
540
540
  word-break: break-word;
541
541
  }
542
542
  `;var us=["top","right","bottom","left"],ps=["start","end"],ni=us.reduce((t,e)=>t.concat(e,e+"-"+ps[0],e+"-"+ps[1]),[]),fs=Math.min,hs=Math.max;var kd={left:"right",right:"left",bottom:"top",top:"bottom"},Pd={start:"end",end:"start"};function ii(t,e,o){return hs(t,fs(e,o))}function Co(t,e){return typeof t=="function"?t(e):t}function Ar(t){return t.split("-")[0]}function wt(t){return t.split("-")[1]}function ai(t){return t==="x"?"y":"x"}function si(t){return t==="y"?"height":"width"}function Eo(t){return["top","bottom"].includes(Ar(t))?"y":"x"}function li(t){return ai(Eo(t))}function ys(t,e,o){o===void 0&&(o=!1);let n=wt(t),i=li(t),a=si(i),l=i==="x"?n===(o?"end":"start")?"right":"left":n==="start"?"bottom":"top";return e.reference[a]>e.floating[a]&&(l=oi(l)),[l,oi(l)]}function ms(t){return t.replace(/start|end/g,e=>Pd[e])}function oi(t){return t.replace(/left|right|bottom|top/g,e=>kd[e])}function Dd(t){return{top:0,right:0,bottom:0,left:0,...t}}function gs(t){return typeof t!="number"?Dd(t):{top:t,right:t,bottom:t,left:t}}function qt(t){let{x:e,y:o,width:n,height:i}=t;return{width:n,height:i,top:o,left:e,right:e+n,bottom:o+i,x:e,y:o}}function bs(t,e,o){let{reference:n,floating:i}=t,a=Eo(e),l=li(e),c=si(l),p=Ar(e),u=a==="y",m=n.x+n.width/2-i.width/2,h=n.y+n.height/2-i.height/2,g=n[c]/2-i[c]/2,S;switch(p){case"top":S={x:m,y:n.y-i.height};break;case"bottom":S={x:m,y:n.y+n.height};break;case"right":S={x:n.x+n.width,y:h};break;case"left":S={x:n.x-i.width,y:h};break;default:S={x:n.x,y:n.y}}switch(wt(e)){case"start":S[l]-=g*(o&&u?-1:1);break;case"end":S[l]+=g*(o&&u?-1:1);break}return S}var xs=async(t,e,o)=>{let{placement:n="bottom",strategy:i="absolute",middleware:a=[],platform:l}=o,c=a.filter(Boolean),p=await(l.isRTL==null?void 0:l.isRTL(e)),u=await l.getElementRects({reference:t,floating:e,strategy:i}),{x:m,y:h}=bs(u,n,p),g=n,S={},v=0;for(let E=0;E<c.length;E++){let{name:N,fn:R}=c[E],{x:I,y:P,data:$,reset:U}=await R({x:m,y:h,initialPlacement:n,placement:g,strategy:i,middlewareData:S,rects:u,platform:l,elements:{reference:t,floating:e}});m=I??m,h=P??h,S={...S,[N]:{...S[N],...$}},U&&v<=50&&(v++,typeof U=="object"&&(U.placement&&(g=U.placement),U.rects&&(u=U.rects===!0?await l.getElementRects({reference:t,floating:e,strategy:i}):U.rects),{x:m,y:h}=bs(u,g,p)),E=-1)}return{x:m,y:h,placement:g,strategy:i,middlewareData:S}};async function ci(t,e){var o;e===void 0&&(e={});let{x:n,y:i,platform:a,rects:l,elements:c,strategy:p}=t,{boundary:u="clippingAncestors",rootBoundary:m="viewport",elementContext:h="floating",altBoundary:g=!1,padding:S=0}=Co(e,t),v=gs(S),N=c[g?h==="floating"?"reference":"floating":h],R=qt(await a.getClippingRect({element:(o=await(a.isElement==null?void 0:a.isElement(N)))==null||o?N:N.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(c.floating)),boundary:u,rootBoundary:m,strategy:p})),I=h==="floating"?{x:n,y:i,width:l.floating.width,height:l.floating.height}:l.reference,P=await(a.getOffsetParent==null?void 0:a.getOffsetParent(c.floating)),$=await(a.isElement==null?void 0:a.isElement(P))?await(a.getScale==null?void 0:a.getScale(P))||{x:1,y:1}:{x:1,y:1},U=qt(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:I,offsetParent:P,strategy:p}):I);return{top:(R.top-U.top+v.top)/$.y,bottom:(U.bottom-R.bottom+v.bottom)/$.y,left:(R.left-U.left+v.left)/$.x,right:(U.right-R.right+v.right)/$.x}}function Bd(t,e,o){return(t?[...o.filter(i=>wt(i)===t),...o.filter(i=>wt(i)!==t)]:o.filter(i=>Ar(i)===i)).filter(i=>t?wt(i)===t||(e?ms(i)!==i:!1):!0)}var di=function(t){return t===void 0&&(t={}),{name:"autoPlacement",options:t,async fn(e){var o,n,i;let{rects:a,middlewareData:l,placement:c,platform:p,elements:u}=e,{crossAxis:m=!1,alignment:h,allowedPlacements:g=ni,autoAlignment:S=!0,...v}=Co(t,e),E=h!==void 0||g===ni?Bd(h||null,S,g):g,N=await ci(e,v),R=((o=l.autoPlacement)==null?void 0:o.index)||0,I=E[R];if(I==null)return{};let P=ys(I,a,await(p.isRTL==null?void 0:p.isRTL(u.floating)));if(c!==I)return{reset:{placement:E[0]}};let $=[N[Ar(I)],N[P[0]],N[P[1]]],U=[...((n=l.autoPlacement)==null?void 0:n.overflows)||[],{placement:I,overflows:$}],Re=E[R+1];if(Re)return{data:{index:R+1,overflows:U},reset:{placement:Re}};let rt=U.map(fe=>{let y=wt(fe.placement);return[fe.placement,y&&m?fe.overflows.slice(0,2).reduce((x,k)=>x+k,0):fe.overflows[0],fe.overflows]}).sort((fe,y)=>fe[1]-y[1]),ot=((i=rt.filter(fe=>fe[2].slice(0,wt(fe[0])?2:3).every(y=>y<=0))[0])==null?void 0:i[0])||rt[0][0];return ot!==c?{data:{index:R+1,overflows:U},reset:{placement:ot}}:{}}}};var pi=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){let{x:o,y:n,placement:i}=e,{mainAxis:a=!0,crossAxis:l=!1,limiter:c={fn:N=>{let{x:R,y:I}=N;return{x:R,y:I}}},...p}=Co(t,e),u={x:o,y:n},m=await ci(e,p),h=Eo(Ar(i)),g=ai(h),S=u[g],v=u[h];if(a){let N=g==="y"?"top":"left",R=g==="y"?"bottom":"right",I=S+m[N],P=S-m[R];S=ii(I,S,P)}if(l){let N=h==="y"?"top":"left",R=h==="y"?"bottom":"right",I=v+m[N],P=v-m[R];v=ii(I,v,P)}let E=c.fn({...e,[g]:S,[h]:v});return{...E,data:{x:E.x-o,y:E.y-n,enabled:{[g]:a,[h]:l}}}}}};var ui=Math.min,wr=Math.max,Zr=Math.round;var xt=t=>({x:t,y:t});function vt(t){return Ss(t)?(t.nodeName||"").toLowerCase():"#document"}function Te(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function St(t){var e;return(e=(Ss(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function Ss(t){return t instanceof Node||t instanceof Te(t).Node}function st(t){return t instanceof Element||t instanceof Te(t).Element}function qe(t){return t instanceof HTMLElement||t instanceof Te(t).HTMLElement}function vs(t){return typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof Te(t).ShadowRoot}function Rr(t){let{overflow:e,overflowX:o,overflowY:n,display:i}=_e(t);return/auto|scroll|overlay|hidden|clip/.test(e+n+o)&&!["inline","contents"].includes(i)}function Os(t){return["table","td","th"].includes(vt(t))}function wo(t){let e=Ro(),o=_e(t);return o.transform!=="none"||o.perspective!=="none"||(o.containerType?o.containerType!=="normal":!1)||!e&&(o.backdropFilter?o.backdropFilter!=="none":!1)||!e&&(o.filter?o.filter!=="none":!1)||["transform","perspective","filter"].some(n=>(o.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(o.contain||"").includes(n))}function Cs(t){let e=Yt(t);for(;qe(e)&&!qr(e);){if(wo(e))return e;e=Yt(e)}return null}function Ro(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function qr(t){return["html","body","#document"].includes(vt(t))}function _e(t){return Te(t).getComputedStyle(t)}function Yr(t){return st(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function Yt(t){if(vt(t)==="html")return t;let e=t.assignedSlot||t.parentNode||vs(t)&&t.host||St(t);return vs(e)?e.host:e}function Es(t){let e=Yt(t);return qr(e)?t.ownerDocument?t.ownerDocument.body:t.body:qe(e)&&Rr(e)?e:Es(e)}function Ao(t,e,o){var n;e===void 0&&(e=[]),o===void 0&&(o=!0);let i=Es(t),a=i===((n=t.ownerDocument)==null?void 0:n.body),l=Te(i);return a?e.concat(l,l.visualViewport||[],Rr(i)?i:[],l.frameElement&&o?Ao(l.frameElement):[]):e.concat(i,Ao(i,[],o))}function Rs(t){let e=_e(t),o=parseFloat(e.width)||0,n=parseFloat(e.height)||0,i=qe(t),a=i?t.offsetWidth:o,l=i?t.offsetHeight:n,c=Zr(o)!==a||Zr(n)!==l;return c&&(o=a,n=l),{width:o,height:n,$:c}}function Ls(t){return st(t)?t:t.contextElement}function Lr(t){let e=Ls(t);if(!qe(e))return xt(1);let o=e.getBoundingClientRect(),{width:n,height:i,$:a}=Rs(e),l=(a?Zr(o.width):o.width)/n,c=(a?Zr(o.height):o.height)/i;return(!l||!Number.isFinite(l))&&(l=1),(!c||!Number.isFinite(c))&&(c=1),{x:l,y:c}}var Ud=xt(0);function Ts(t){let e=Te(t);return!Ro()||!e.visualViewport?Ud:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function Fd(t,e,o){return e===void 0&&(e=!1),!o||e&&o!==Te(t)?!1:e}function Xr(t,e,o,n){e===void 0&&(e=!1),o===void 0&&(o=!1);let i=t.getBoundingClientRect(),a=Ls(t),l=xt(1);e&&(n?st(n)&&(l=Lr(n)):l=Lr(t));let c=Fd(a,o,n)?Ts(a):xt(0),p=(i.left+c.x)/l.x,u=(i.top+c.y)/l.y,m=i.width/l.x,h=i.height/l.y;if(a){let g=Te(a),S=n&&st(n)?Te(n):n,v=g.frameElement;for(;v&&n&&S!==g;){let E=Lr(v),N=v.getBoundingClientRect(),R=_e(v),I=N.left+(v.clientLeft+parseFloat(R.paddingLeft))*E.x,P=N.top+(v.clientTop+parseFloat(R.paddingTop))*E.y;p*=E.x,u*=E.y,m*=E.x,h*=E.y,p+=I,u+=P,v=Te(v).frameElement}}return qt({width:m,height:h,x:p,y:u})}function zd(t){let{rect:e,offsetParent:o,strategy:n}=t,i=qe(o),a=St(o);if(o===a)return e;let l={scrollLeft:0,scrollTop:0},c=xt(1),p=xt(0);if((i||!i&&n!=="fixed")&&((vt(o)!=="body"||Rr(a))&&(l=Yr(o)),qe(o))){let u=Xr(o);c=Lr(o),p.x=u.x+o.clientLeft,p.y=u.y+o.clientTop}return{width:e.width*c.x,height:e.height*c.y,x:e.x*c.x-l.scrollLeft*c.x+p.x,y:e.y*c.y-l.scrollTop*c.y+p.y}}function Hd(t){return Array.from(t.getClientRects())}function Ns(t){return Xr(St(t)).left+Yr(t).scrollLeft}function Wd(t){let e=St(t),o=Yr(t),n=t.ownerDocument.body,i=wr(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),a=wr(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight),l=-o.scrollLeft+Ns(t),c=-o.scrollTop;return _e(n).direction==="rtl"&&(l+=wr(e.clientWidth,n.clientWidth)-i),{width:i,height:a,x:l,y:c}}function Gd(t,e){let o=Te(t),n=St(t),i=o.visualViewport,a=n.clientWidth,l=n.clientHeight,c=0,p=0;if(i){a=i.width,l=i.height;let u=Ro();(!u||u&&e==="fixed")&&(c=i.offsetLeft,p=i.offsetTop)}return{width:a,height:l,x:c,y:p}}function jd(t,e){let o=Xr(t,!0,e==="fixed"),n=o.top+t.clientTop,i=o.left+t.clientLeft,a=qe(t)?Lr(t):xt(1),l=t.clientWidth*a.x,c=t.clientHeight*a.y,p=i*a.x,u=n*a.y;return{width:l,height:c,x:p,y:u}}function As(t,e,o){let n;if(e==="viewport")n=Gd(t,o);else if(e==="document")n=Wd(St(t));else if(st(e))n=jd(e,o);else{let i=Ts(t);n={...e,x:e.x-i.x,y:e.y-i.y}}return qt(n)}function Is(t,e){let o=Yt(t);return o===e||!st(o)||qr(o)?!1:_e(o).position==="fixed"||Is(o,e)}function Vd(t,e){let o=e.get(t);if(o)return o;let n=Ao(t,[],!1).filter(c=>st(c)&&vt(c)!=="body"),i=null,a=_e(t).position==="fixed",l=a?Yt(t):t;for(;st(l)&&!qr(l);){let c=_e(l),p=wo(l);!p&&c.position==="fixed"&&(i=null),(a?!p&&!i:!p&&c.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||Rr(l)&&!p&&Is(t,l))?n=n.filter(m=>m!==l):i=c,l=Yt(l)}return e.set(t,n),n}function Kd(t){let{element:e,boundary:o,rootBoundary:n,strategy:i}=t,l=[...o==="clippingAncestors"?Vd(e,this._c):[].concat(o),n],c=l[0],p=l.reduce((u,m)=>{let h=As(e,m,i);return u.top=wr(h.top,u.top),u.right=ui(h.right,u.right),u.bottom=ui(h.bottom,u.bottom),u.left=wr(h.left,u.left),u},As(e,c,i));return{width:p.right-p.left,height:p.bottom-p.top,x:p.left,y:p.top}}function Zd(t){return Rs(t)}function qd(t,e,o){let n=qe(e),i=St(e),a=o==="fixed",l=Xr(t,!0,a,e),c={scrollLeft:0,scrollTop:0},p=xt(0);if(n||!n&&!a)if((vt(e)!=="body"||Rr(i))&&(c=Yr(e)),n){let u=Xr(e,!0,a,e);p.x=u.x+e.clientLeft,p.y=u.y+e.clientTop}else i&&(p.x=Ns(i));return{x:l.left+c.scrollLeft-p.x,y:l.top+c.scrollTop-p.y,width:l.width,height:l.height}}function ws(t,e){return!qe(t)||_e(t).position==="fixed"?null:e?e(t):t.offsetParent}function _s(t,e){let o=Te(t);if(!qe(t))return o;let n=ws(t,e);for(;n&&Os(n)&&_e(n).position==="static";)n=ws(n,e);return n&&(vt(n)==="html"||vt(n)==="body"&&_e(n).position==="static"&&!wo(n))?o:n||Cs(t)||o}var Yd=async function(t){let{reference:e,floating:o,strategy:n}=t,i=this.getOffsetParent||_s,a=this.getDimensions;return{reference:qd(e,await i(o),n),floating:{x:0,y:0,...await a(o)}}};function Xd(t){return _e(t).direction==="rtl"}var Lo={convertOffsetParentRelativeRectToViewportRelativeRect:zd,getDocumentElement:St,getClippingRect:Kd,getOffsetParent:_s,getElementRects:Yd,getClientRects:Hd,getDimensions:Zd,getScale:Lr,isElement:st,isRTL:Xd};var ks=(t,e,o)=>{let n=new Map,i={platform:Lo,...o},a={...i.platform,_c:n};return xs(t,e,{...i,platform:a})};function Ps(t){return Jd(t)}function fi(t){return t.assignedSlot?t.assignedSlot:t.parentNode instanceof ShadowRoot?t.parentNode.host:t.parentNode}function Jd(t){for(let e=t;e;e=fi(e))if(e instanceof Element&&getComputedStyle(e).display==="none")return null;for(let e=fi(t);e;e=fi(e)){if(!(e instanceof Element))continue;let o=getComputedStyle(e);if(o.display!=="contents"&&(o.position!=="static"||o.filter!=="none"||e.tagName==="BODY"))return e}return null}async function Ds(t,e,o){return ks(t,e,{platform:{...Lo,getOffsetParent:n=>Lo.getOffsetParent(n,Ps)},middleware:[pi({crossAxis:!0}),di({allowedPlacements:[o]})]})}var Ur=b(L());var Sc=b(L());var Al=b(M()),me=b(ee()),Ye=b(L());var Bs=b(M());var $s=Bs.css`
543
- `;var To=b(L()),Qd="ft-app-info",Xt=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};Xt.eventName="authentication-change";var ep={session:(t,e)=>{(0,To.deepEqual)(t.session,e.payload)||(t.session=e.payload,setTimeout(()=>_.dispatchEvent(new Xt(e.payload)),0))}},_=To.FtReduxStore.get({name:Qd,reducers:ep,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],availableContentLocales:[],defaultLocales:void 0,searchInAllLanguagesAllowed:!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 hi=b(L());var Jt=class t{static get(e){let{baseUrl:o,apiIntegrationIdentifier:n}=_.getState(),i=e??n;if(o&&i&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,i,!0)}static await(e){return new Promise(o=>{let n=t.get(e);if(n)o(n);else{let i=_.subscribe(()=>{n=t.get(e),n&&(i(),o(n))})}})}};var No=class{constructor(e){this.overrideApi=e}get api(){var e;return(e=this.overrideApi)!==null&&e!==void 0?e:Jt.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):Jt.await()}};var ke=class extends No{constructor(e=!0,o){var n;super(o),this.sortObjectFields=(a,l)=>typeof l!="object"||l==null||Array.isArray(l)?l:Object.fromEntries(Object.entries(l).sort(([c],[p])=>c.localeCompare(p)));let i=this.constructor;i.commonCache=(n=i.commonCache)!==null&&n!==void 0?n:new hi.CacheRegistry,this.cache=e?i.commonCache:new hi.CacheRegistry}clearCache(){this.cache.clearAll()}hash(e){return String(Array.from(JSON.stringify(e,this.sortObjectFields)).reduce((o,n)=>0|31*o+n.charCodeAt(0),0))}};var Io=class extends ke{async listMyBookmarks(){let e=_.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),5*60*1e3):[]}};var yi=class{addCommand(e,o=!1){_.commands.add(e,o)}consumeCommand(e){return _.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new yi;var Fe=b(L());var Ms,Tr=class extends CustomEvent{constructor(e){super("ft-i18n-context-loaded",{detail:e})}},tp=Symbol("clearAfterUnitTest"),_o=class extends(0,Fe.withEventBus)(ke){constructor(e){super(),this.messageContextProvider=e,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[Ms]=()=>{this.defaultMessages={},this.cache=new Fe.CacheRegistry,this.listeners={}},this.currentUiLocale=_.getState().uiLocale,_.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:e}=_.getState();this.currentUiLocale!==e&&(this.currentUiLocale=e,this.cache.clearAll(),this.notifyAll())}addContext(e){let o=e.name.toLowerCase();this.cache.setFinal(o,e),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(e,o){var n;if(e=e.toLowerCase(),o&&Object.keys(o).length>0){let i={...(n=this.defaultMessages[e])!==null&&n!==void 0?n:{},...o};(0,Fe.deepEqual)(this.defaultMessages[e],i)||(this.defaultMessages[e]=i,await this.notify(e))}return this.fetchContext(e)}resolveContext(e){var o,n;return this.fetchContext(e),(n=(o=this.cache.getNow(e))===null||o===void 0?void 0:o.messages)!==null&&n!==void 0?n:{}}resolveRawMessage(e,o){let n=e.toLowerCase();return this.resolveContext(n)[o]}resolveMessage(e,o,...n){var i;let a=e.toLowerCase(),l=this.resolveContext(a);return new Fe.ParametrizedLabelResolver((i=this.defaultMessages[a])!==null&&i!==void 0?i:{},l).resolve(o,...n)}async fetchContext(e){let o=!this.cache.has(e),n;try{n=await this.cache.get(e,()=>this.messageContextProvider(this.currentUiLocale,e)),o&&await this.notify(e)}catch(i){!(i instanceof Fe.CanceledPromiseError)&&o&&console.error(i)}return n}subscribe(e,o){var n;return e=e.toLowerCase(),this.listeners[e]=(n=this.listeners[e])!==null&&n!==void 0?n:new Set,this.listeners[e].add(o),()=>{var i;return(i=this.listeners[e])===null||i===void 0?void 0:i.delete(o)}}async notifyAll(){let e=Object.keys(this.listeners);document.body.dispatchEvent(new Tr({loadedContexts:e})),this.dispatchEvent(new Tr({loadedContexts:e})),await Promise.all(e.map(o=>this.notify(o,!1)))}async notify(e,o=!0){o&&(document.body.dispatchEvent(new Tr({loadedContexts:[e]})),this.dispatchEvent(new Tr({loadedContexts:[e]}))),this.listeners[e]!=null&&await Promise.all([...this.listeners[e].values()].map(n=>(0,Fe.delay)(0).then(()=>n()).catch(()=>null)))}};Ms=tp;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends _o{constructor(){super(async(t,e)=>(await this.awaitApi).getFluidTopicsMessageContext(t,e))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends _o{constructor(){super(async(t,e)=>(await this.awaitApi).getCustomMessageContext(t,e))}});var Jr=window.FluidTopicsI18nService,mi=window.FluidTopicsCustomI18nService;var Us=b(L()),gi=class{highlightHtml(e,o,n){(0,Us.highlightHtml)(e,o,n)}};window.FluidTopicsHighlightHtmlService=new gi;var op=b(zs(),1);var Hs;(function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"})(Hs||(Hs={}));var Ws;(function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"})(Ws||(Ws={}));var Gs;(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"})(Gs||(Gs={}));var js;(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"})(js||(js={}));var Vs;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(Vs||(Vs={}));var Ks;(function(t){t.VALUE="VALUE",t.DATE="DATE",t.RANGE="RANGE"})(Ks||(Ks={}));var Zs;(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__AI_TRANSLATE="DOCUMENT__AI_TRANSLATE",t.DOCUMENT__DISPLAY="DOCUMENT__DISPLAY",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__DISPLAY="TOPIC__DISPLAY",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"})(Zs||(Zs={}));var qs;(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"})(qs||(qs={}));var Ys;(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"})(Ys||(Ys={}));var Xs;(function(t){t.CLASSIC="CLASSIC",t.CUSTOM="CUSTOM",t.DESIGNER="DESIGNER"})(Xs||(Xs={}));var Js;(function(t){t.AND="AND",t.OR="OR",t.MONOVALUED="MONOVALUED"})(Js||(Js={}));var Qs;(function(t){t.NONE="NONE",t.ALPHABET="ALPHABET",t.VERSION="VERSION"})(Qs||(Qs={}));var el;(function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"})(el||(el={}));var tl;(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"})(tl||(tl={}));var rl;(function(t){t.OPTIONAL="OPTIONAL",t.MANDATORY="MANDATORY"})(rl||(rl={}));var ol;(function(t){t.ASC="ASC",t.DESC="DESC"})(ol||(ol={}));var nl;(function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"})(nl||(nl={}));var il;(function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"})(il||(il={}));var al;(function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(al||(al={}));var sl;(function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"})(sl||(sl={}));var ll;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK"})(ll||(ll={}));var cl;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(cl||(cl={}));var dl;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC"})(dl||(dl={}));var pl;(function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS",t.ALL_TOPICS="ALL_TOPICS",t.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(pl||(pl={}));var ul;(function(t){t.PLAIN_TEXT="PLAIN_TEXT",t.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",t.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(ul||(ul={}));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.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_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.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 ze;(function(t){t.SEARCHES="SEARCHES",t.BOOKMARKS="BOOKMARKS",t.BOOKS="BOOKS",t.COLLECTIONS="COLLECTIONS"})(ze||(ze={}));var fl;(function(t){t.VALID="VALID",t.INVALID="INVALID"})(fl||(fl={}));var hl;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(hl||(hl={}));var yl;(function(t){t.USER="USER",t.ASSISTANT="ASSISTANT"})(yl||(yl={}));var ml;(function(t){t.TEXT="TEXT",t.HTML="HTML"})(ml||(ml={}));var gl;(function(t){t.HTML="HTML",t.MARKDOWN="MARKDOWN"})(gl||(gl={}));var rp={[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.GENERATIVE_AI_EXPORT_USER]:[ae.GENERATIVE_AI_USER]};function bl(t,e){return t===e||(rp[t]??[]).some(o=>bl(o,e))}function xl(t,e){return t==null?!1:(Array.isArray(t)?t:Array.isArray(t.roles)?t.roles:Array.isArray(t.profile?.roles)?t.profile.roles:[]).some(n=>bl(n,e))}var Do=class extends ke{async listMySearches(){let{session:e}=_.getState();return xl(e,ae.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),5*60*1e3):[]}};var vl=b(L());var bi=class{isDate(e){var o,n,i,a;return(a=(i=((n=(o=_.getState().metadataConfiguration)===null||o===void 0?void 0:o.descriptors)!==null&&n!==void 0?n:[]).find(c=>c.key===e))===null||i===void 0?void 0:i.date)!==null&&a!==void 0?a:!1}format(e,o){var n,i,a;return vl.DateFormatter.format(e,(n=o?.locale)!==null&&n!==void 0?n:_.getState().uiLocale,(i=o?.longFormat)!==null&&i!==void 0?i:!1,(a=o?.withTime)!==null&&a!==void 0?a:!1)}};window.FluidTopicsDateService=new bi;var Sl=b(L());var Qr=class{static get(e,o){var n,i;let a=_.getState(),{lang:l,region:c}=(i=(n=a.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&i!==void 0?i:{lang:"en",region:"US"};return new Sl.SearchPlaceConverter(a.baseUrl,e??20,a.searchInAllLanguagesAllowed,o??`${l}-${c}`)}};var xi=class{urlToSearchRequest(e){return Qr.get().parse(e)}searchRequestToUrl(e){return Qr.get().serialize(e)}};window.FluidTopicsUrlService=new xi;var Lt=b(L());var Qt=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{currentItem:e}})}};Qt.eventName="change";var vi=class{itemName(e){return`fluid-topics-history-item-${e}`}get(e){let o=sessionStorage.getItem(this.itemName(e));return o?JSON.parse(o):void 0}set(e,o){sessionStorage.setItem(this.itemName(e),JSON.stringify(o))}},Ol=new vi;var Bo=class t extends Lt.WithEventBus{static build(){return new t(window.history,Ol,()=>window.location,!1)}constructor(e,o,n,i){var a,l;super(),this.history=e,this.historyStorage=o,this.windowLocation=n,this.states=[],this.realPushState=e.pushState,this.realReplaceState=e.replaceState,this.initialIndex=(l=(a=e.state)===null||a===void 0?void 0:a.index)!==null&&l!==void 0?l:e.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(i)}setCurrentState(e,o=!1){let n=o&&this.currentIndex===e.index-1;this.currentState={...this.buildCurrentState(),...e},this.currentIndex=this.currentState.index,this.states[this.currentIndex]=this.currentState,n&&(this.states=this.states.slice(0,this.currentIndex+1)),this.historyStorage.set(this.currentIndex,this.currentState),(0,Lt.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,window.location.href]),setTimeout(()=>this.dispatchEvent(new Qt(this.currentItem())),0)}installProxies(){let e=o=>(n,i,[a,l,c])=>{let p=o(),u={...p===this.currentIndex?this.currentState:void 0,...a,index:p,href:typeof c=="string"?c:(c??this.windowLocation()).href};n.apply(i,[u,l,c]),this.setCurrentState(u,!0)};this.history.pushState=new Proxy(this.history.pushState,{apply:e(()=>this.currentIndex+1)}),this.history.replaceState=new Proxy(this.history.replaceState,{apply:e(()=>this.currentIndex)})}initEventListeners(){window.addEventListener("popstate",e=>this.setCurrentState(e.state)),document.querySelector("title")==null&&document.head.append(document.createElement("title")),new MutationObserver(()=>this.updateCurrentState({title:document.title})).observe(document.querySelector("title"),{subtree:!0,characterData:!0,childList:!0})}initData(e){for(let o=this.history.length-1;o>=0;o--)e?this.states[o]=this.historyStorage.get(o):setTimeout(()=>this.states[o]=this.historyStorage.get(o),this.history.length-o)}updateCurrentState(e){var o;let n={...this.buildCurrentState(),...e,index:this.currentIndex,title:(o=e?.title)!==null&&o!==void 0?o:this.currentState.title};this.setCurrentState(n)}addHistoryChangeListener(e){this.addEventListener(Qt.eventName,e)}removeHistoryChangeListener(e){this.removeEventListener(Qt.eventName,e)}currentItem(){return(0,Lt.deepCopy)(this.currentState)}back(){let e=this.previousDifferentMajorPosition();e>=0?this.history.go(e-this.currentIndex):this.currentIndex!==this.initialIndex?this.history.go(this.initialIndex-this.currentIndex):this.history.back()}backwardItem(){return(0,Lt.deepCopy)(this.states[this.previousDifferentMajorPosition()])}previousDifferentMajorPosition(){let e=this.currentIndex>0?this.currentIndex-1:0;for(;e>0&&!this.isDifferentMajorState(e);)e--;return e}forward(){let e=this.nextMajorPosition();e&&e<this.states.length?this.history.go(e-this.currentIndex):this.history.forward()}forwardItem(){let e=this.nextMajorPosition();if(e)return(0,Lt.deepCopy)(this.states[e])}nextMajorPosition(){let e=this.currentIndex;if(!(e>=this.states.length)){do e++;while(e<this.states.length&&!this.isDifferentMajorState(e));return this.getHigherPositionInTheSameState(e)}}getHigherPositionInTheSameState(e){var o;let n=(o=this.states[e])===null||o===void 0?void 0:o.majorStateId;if(!n)return e;let i=e,a=e+1;for(;this.states.length>a&&!this.isDifferentMajorState(a,n);)this.hasState(a)&&(i=a),a++;return i}buildCurrentState(){var e,o;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(o=(e=this.history.state)===null||e===void 0?void 0:e.title)!==null&&o!==void 0?o:document.title}}hasState(e){return this.states[e]!=null}isDifferentMajorState(e,o){var n;if(!this.hasState(e))return!1;let i=o??this.currentState.majorStateId,a=(n=this.states[e])===null||n===void 0?void 0:n.majorStateId;return a==null||a!=i}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=Bo.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),addHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(t),removeHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(t)});var Cl=_;function El(t,e){var o;return Cl.getState().authenticationRequired&&!(!((o=Cl.getState().session)===null||o===void 0)&&o.sessionAuthenticated)?Promise.resolve(e):t()}var se=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(l=t[c])&&(a=(i<3?l(a):i>3?l(e,o,a):l(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},Z=class extends Ye.FtLitElement{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.apiProvider=()=>Jt.get(),this.authenticationRequired=!1,this.messageContexts=[],this.cache=new Ye.CacheRegistry,this.cleanSessionDebouncer=new Ye.Debouncer,this.reloadConfiguration=()=>{this.cache.clear("availableContentLocales"),this.updateAvailableContentLocales()}}render(){return Al.html`
543
+ `;var To=b(L()),Qd="ft-app-info",Xt=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};Xt.eventName="authentication-change";var ep={session:(t,e)=>{(0,To.deepEqual)(t.session,e.payload)||(t.session=e.payload,setTimeout(()=>_.dispatchEvent(new Xt(e.payload)),0))}},_=To.FtReduxStore.get({name:Qd,reducers:ep,initialState:{baseUrl:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],availableContentLocales:[],defaultLocales:void 0,searchInAllLanguagesAllowed:!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 hi=b(L());var Jt=class t{static get(e){let{baseUrl:o,apiIntegrationIdentifier:n}=_.getState(),i=e??n;if(o&&i&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(o,i,!0)}static await(e){return new Promise(o=>{let n=t.get(e);if(n)o(n);else{let i=_.subscribe(()=>{n=t.get(e),n&&(i(),o(n))})}})}};var No=class{constructor(e){this.overrideApi=e}get api(){var e;return(e=this.overrideApi)!==null&&e!==void 0?e:Jt.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):Jt.await()}};var ke=class extends No{constructor(e=!0,o){var n;super(o),this.sortObjectFields=(a,l)=>typeof l!="object"||l==null||Array.isArray(l)?l:Object.fromEntries(Object.entries(l).sort(([c],[p])=>c.localeCompare(p)));let i=this.constructor;i.commonCache=(n=i.commonCache)!==null&&n!==void 0?n:new hi.CacheRegistry,this.cache=e?i.commonCache:new hi.CacheRegistry}clearCache(){this.cache.clearAll()}hash(e){return String(Array.from(JSON.stringify(e,this.sortObjectFields)).reduce((o,n)=>0|31*o+n.charCodeAt(0),0))}};var Io=class extends ke{async listMyBookmarks(){let e=_.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),5*60*1e3):[]}};var yi=class{addCommand(e,o=!1){_.commands.add(e,o)}consumeCommand(e){return _.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new yi;var Fe=b(L());var Ms,Tr=class extends CustomEvent{constructor(e){super("ft-i18n-context-loaded",{detail:e})}},tp=Symbol("clearAfterUnitTest"),_o=class extends(0,Fe.withEventBus)(ke){constructor(e){super(),this.messageContextProvider=e,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[Ms]=()=>{this.defaultMessages={},this.cache=new Fe.CacheRegistry,this.listeners={}},this.currentUiLocale=_.getState().uiLocale,_.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:e}=_.getState();this.currentUiLocale!==e&&(this.currentUiLocale=e,this.cache.clearAll(),this.notifyAll())}addContext(e){let o=e.name.toLowerCase();this.cache.setFinal(o,e),this.notify(o)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(e,o){var n;if(e=e.toLowerCase(),o&&Object.keys(o).length>0){let i={...(n=this.defaultMessages[e])!==null&&n!==void 0?n:{},...o};(0,Fe.deepEqual)(this.defaultMessages[e],i)||(this.defaultMessages[e]=i,await this.notify(e))}return this.fetchContext(e)}resolveContext(e){var o,n;return this.fetchContext(e),(n=(o=this.cache.getNow(e))===null||o===void 0?void 0:o.messages)!==null&&n!==void 0?n:{}}resolveRawMessage(e,o){let n=e.toLowerCase();return this.resolveContext(n)[o]}resolveMessage(e,o,...n){var i;let a=e.toLowerCase(),l=this.resolveContext(a);return new Fe.ParametrizedLabelResolver((i=this.defaultMessages[a])!==null&&i!==void 0?i:{},l).resolve(o,...n)}async fetchContext(e){let o=!this.cache.has(e),n;try{n=await this.cache.get(e,()=>this.messageContextProvider(this.currentUiLocale,e)),o&&await this.notify(e)}catch(i){!(i instanceof Fe.CanceledPromiseError)&&o&&console.error(i)}return n}subscribe(e,o){var n;return e=e.toLowerCase(),this.listeners[e]=(n=this.listeners[e])!==null&&n!==void 0?n:new Set,this.listeners[e].add(o),()=>{var i;return(i=this.listeners[e])===null||i===void 0?void 0:i.delete(o)}}async notifyAll(){let e=Object.keys(this.listeners);document.body.dispatchEvent(new Tr({loadedContexts:e})),this.dispatchEvent(new Tr({loadedContexts:e})),await Promise.all(e.map(o=>this.notify(o,!1)))}async notify(e,o=!0){o&&(document.body.dispatchEvent(new Tr({loadedContexts:[e]})),this.dispatchEvent(new Tr({loadedContexts:[e]}))),this.listeners[e]!=null&&await Promise.all([...this.listeners[e].values()].map(n=>(0,Fe.delay)(0).then(()=>n()).catch(()=>null)))}};Ms=tp;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends _o{constructor(){super(async(t,e)=>(await this.awaitApi).getFluidTopicsMessageContext(t,e))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends _o{constructor(){super(async(t,e)=>(await this.awaitApi).getCustomMessageContext(t,e))}});var Jr=window.FluidTopicsI18nService,mi=window.FluidTopicsCustomI18nService;var Us=b(L()),gi=class{highlightHtml(e,o,n){(0,Us.highlightHtml)(e,o,n)}};window.FluidTopicsHighlightHtmlService=new gi;var op=b(zs(),1);var Hs;(function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"})(Hs||(Hs={}));var Ws;(function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"})(Ws||(Ws={}));var Gs;(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"})(Gs||(Gs={}));var js;(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"})(js||(js={}));var Vs;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(Vs||(Vs={}));var Ks;(function(t){t.VALUE="VALUE",t.DATE="DATE",t.RANGE="RANGE"})(Ks||(Ks={}));var Zs;(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__AI_TRANSLATE="DOCUMENT__AI_TRANSLATE",t.DOCUMENT__DISPLAY="DOCUMENT__DISPLAY",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__DISPLAY="TOPIC__DISPLAY",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"})(Zs||(Zs={}));var qs;(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"})(qs||(qs={}));var Ys;(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"})(Ys||(Ys={}));var Xs;(function(t){t.CLASSIC="CLASSIC",t.CUSTOM="CUSTOM",t.DESIGNER="DESIGNER"})(Xs||(Xs={}));var Js;(function(t){t.AND="AND",t.OR="OR",t.MONOVALUED="MONOVALUED"})(Js||(Js={}));var Qs;(function(t){t.NONE="NONE",t.ALPHABET="ALPHABET",t.VERSION="VERSION"})(Qs||(Qs={}));var el;(function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"})(el||(el={}));var tl;(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"})(tl||(tl={}));var rl;(function(t){t.OPTIONAL="OPTIONAL",t.MANDATORY="MANDATORY"})(rl||(rl={}));var ol;(function(t){t.ASC="ASC",t.DESC="DESC"})(ol||(ol={}));var nl;(function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"})(nl||(nl={}));var il;(function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"})(il||(il={}));var al;(function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(al||(al={}));var sl;(function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"})(sl||(sl={}));var ll;(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"})(ll||(ll={}));var cl;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(cl||(cl={}));var dl;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.HTML_PACKAGE="HTML_PACKAGE",t.HTML_PACKAGE_PAGE="HTML_PACKAGE_PAGE"})(dl||(dl={}));var pl;(function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS",t.ALL_TOPICS="ALL_TOPICS",t.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(pl||(pl={}));var ul;(function(t){t.PLAIN_TEXT="PLAIN_TEXT",t.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",t.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(ul||(ul={}));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.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_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.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 ze;(function(t){t.SEARCHES="SEARCHES",t.BOOKMARKS="BOOKMARKS",t.BOOKS="BOOKS",t.COLLECTIONS="COLLECTIONS"})(ze||(ze={}));var fl;(function(t){t.VALID="VALID",t.INVALID="INVALID"})(fl||(fl={}));var hl;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(hl||(hl={}));var yl;(function(t){t.USER="USER",t.ASSISTANT="ASSISTANT"})(yl||(yl={}));var ml;(function(t){t.TEXT="TEXT",t.HTML="HTML"})(ml||(ml={}));var gl;(function(t){t.HTML="HTML",t.MARKDOWN="MARKDOWN"})(gl||(gl={}));var rp={[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.GENERATIVE_AI_EXPORT_USER]:[ae.GENERATIVE_AI_USER]};function bl(t,e){return t===e||(rp[t]??[]).some(o=>bl(o,e))}function xl(t,e){return t==null?!1:(Array.isArray(t)?t:Array.isArray(t.roles)?t.roles:Array.isArray(t.profile?.roles)?t.profile.roles:[]).some(n=>bl(n,e))}var Do=class extends ke{async listMySearches(){let{session:e}=_.getState();return xl(e,ae.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),5*60*1e3):[]}};var vl=b(L());var bi=class{isDate(e){var o,n,i,a;return(a=(i=((n=(o=_.getState().metadataConfiguration)===null||o===void 0?void 0:o.descriptors)!==null&&n!==void 0?n:[]).find(c=>c.key===e))===null||i===void 0?void 0:i.date)!==null&&a!==void 0?a:!1}format(e,o){var n,i,a;return vl.DateFormatter.format(e,(n=o?.locale)!==null&&n!==void 0?n:_.getState().uiLocale,(i=o?.longFormat)!==null&&i!==void 0?i:!1,(a=o?.withTime)!==null&&a!==void 0?a:!1)}};window.FluidTopicsDateService=new bi;var Sl=b(L());var Qr=class{static get(e,o){var n,i;let a=_.getState(),{lang:l,region:c}=(i=(n=a.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&i!==void 0?i:{lang:"en",region:"US"};return new Sl.SearchPlaceConverter(a.baseUrl,e??20,a.searchInAllLanguagesAllowed,o??`${l}-${c}`)}};var xi=class{urlToSearchRequest(e){return Qr.get().parse(e)}searchRequestToUrl(e){return Qr.get().serialize(e)}};window.FluidTopicsUrlService=new xi;var Lt=b(L());var Qt=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{currentItem:e}})}};Qt.eventName="change";var vi=class{itemName(e){return`fluid-topics-history-item-${e}`}get(e){let o=sessionStorage.getItem(this.itemName(e));return o?JSON.parse(o):void 0}set(e,o){sessionStorage.setItem(this.itemName(e),JSON.stringify(o))}},Ol=new vi;var Bo=class t extends Lt.WithEventBus{static build(){return new t(window.history,Ol,()=>window.location,!1)}constructor(e,o,n,i){var a,l;super(),this.history=e,this.historyStorage=o,this.windowLocation=n,this.states=[],this.realPushState=e.pushState,this.realReplaceState=e.replaceState,this.initialIndex=(l=(a=e.state)===null||a===void 0?void 0:a.index)!==null&&l!==void 0?l:e.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(i)}setCurrentState(e,o=!1){let n=o&&this.currentIndex===e.index-1;this.currentState={...this.buildCurrentState(),...e},this.currentIndex=this.currentState.index,this.states[this.currentIndex]=this.currentState,n&&(this.states=this.states.slice(0,this.currentIndex+1)),this.historyStorage.set(this.currentIndex,this.currentState),(0,Lt.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,window.location.href]),setTimeout(()=>this.dispatchEvent(new Qt(this.currentItem())),0)}installProxies(){let e=o=>(n,i,[a,l,c])=>{let p=o(),u={...p===this.currentIndex?this.currentState:void 0,...a,index:p,href:typeof c=="string"?c:(c??this.windowLocation()).href};n.apply(i,[u,l,c]),this.setCurrentState(u,!0)};this.history.pushState=new Proxy(this.history.pushState,{apply:e(()=>this.currentIndex+1)}),this.history.replaceState=new Proxy(this.history.replaceState,{apply:e(()=>this.currentIndex)})}initEventListeners(){window.addEventListener("popstate",e=>this.setCurrentState(e.state)),document.querySelector("title")==null&&document.head.append(document.createElement("title")),new MutationObserver(()=>this.updateCurrentState({title:document.title})).observe(document.querySelector("title"),{subtree:!0,characterData:!0,childList:!0})}initData(e){for(let o=this.history.length-1;o>=0;o--)e?this.states[o]=this.historyStorage.get(o):setTimeout(()=>this.states[o]=this.historyStorage.get(o),this.history.length-o)}updateCurrentState(e){var o;let n={...this.buildCurrentState(),...e,index:this.currentIndex,title:(o=e?.title)!==null&&o!==void 0?o:this.currentState.title};this.setCurrentState(n)}addHistoryChangeListener(e){this.addEventListener(Qt.eventName,e)}removeHistoryChangeListener(e){this.removeEventListener(Qt.eventName,e)}currentItem(){return(0,Lt.deepCopy)(this.currentState)}back(){let e=this.previousDifferentMajorPosition();e>=0?this.history.go(e-this.currentIndex):this.currentIndex!==this.initialIndex?this.history.go(this.initialIndex-this.currentIndex):this.history.back()}backwardItem(){return(0,Lt.deepCopy)(this.states[this.previousDifferentMajorPosition()])}previousDifferentMajorPosition(){let e=this.currentIndex>0?this.currentIndex-1:0;for(;e>0&&!this.isDifferentMajorState(e);)e--;return e}forward(){let e=this.nextMajorPosition();e&&e<this.states.length?this.history.go(e-this.currentIndex):this.history.forward()}forwardItem(){let e=this.nextMajorPosition();if(e)return(0,Lt.deepCopy)(this.states[e])}nextMajorPosition(){let e=this.currentIndex;if(!(e>=this.states.length)){do e++;while(e<this.states.length&&!this.isDifferentMajorState(e));return this.getHigherPositionInTheSameState(e)}}getHigherPositionInTheSameState(e){var o;let n=(o=this.states[e])===null||o===void 0?void 0:o.majorStateId;if(!n)return e;let i=e,a=e+1;for(;this.states.length>a&&!this.isDifferentMajorState(a,n);)this.hasState(a)&&(i=a),a++;return i}buildCurrentState(){var e,o;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(o=(e=this.history.state)===null||e===void 0?void 0:e.title)!==null&&o!==void 0?o:document.title}}hasState(e){return this.states[e]!=null}isDifferentMajorState(e,o){var n;if(!this.hasState(e))return!1;let i=o??this.currentState.majorStateId,a=(n=this.states[e])===null||n===void 0?void 0:n.majorStateId;return a==null||a!=i}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=Bo.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),addHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(t),removeHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(t)});var Cl=_;function El(t,e){var o;return Cl.getState().authenticationRequired&&!(!((o=Cl.getState().session)===null||o===void 0)&&o.sessionAuthenticated)?Promise.resolve(e):t()}var se=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(l=t[c])&&(a=(i<3?l(a):i>3?l(e,o,a):l(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},Z=class extends Ye.FtLitElement{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.apiProvider=()=>Jt.get(),this.authenticationRequired=!1,this.messageContexts=[],this.cache=new Ye.CacheRegistry,this.cleanSessionDebouncer=new Ye.Debouncer,this.reloadConfiguration=()=>{this.cache.clear("availableContentLocales"),this.updateAvailableContentLocales()}}render(){return Al.html`
544
544
  <slot></slot>
545
545
  `}connectedCallback(){super.connectedCallback(),_.addEventListener(Xt.eventName,this.reloadConfiguration)}disconnectedCallback(){_.addEventListener(Xt.eventName,this.reloadConfiguration),super.disconnectedCallback()}update(e){var o,n,i,a,l,c,p;super.update(e),e.has("baseUrl")&&(_.actions.baseUrl(this.baseUrl),window.fluidTopicsBaseUrl=this.baseUrl),e.has("apiIntegrationIdentifier")&&_.actions.apiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("apiIntegrationAppVersion")&&_.actions.apiIntegrationAppVersion(this.apiIntegrationAppVersion),e.has("uiLocale")&&_.actions.uiLocale(this.uiLocale),e.has("metadataConfiguration")&&_.actions.metadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&_.actions.noCustom(this.noCustom),e.has("editorMode")&&_.actions.editorMode(this.editorMode),e.has("noCustomComponent")&&_.actions.noCustomComponent(this.noCustomComponent),e.has("session")&&_.actions.session(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(u=>Jr.addContext(u)),e.has("openExternalDocumentInNewTab")&&_.actions.openExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&_.actions.navigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&_.actions.forcedOffline(this.forcedOffline),e.has("localesConfiguration")&&(_.actions.defaultLocales((o=this.localesConfiguration)===null||o===void 0?void 0:o.defaultLocales),_.actions.availableUiLocales((i=(n=this.localesConfiguration)===null||n===void 0?void 0:n.availableUiLocales)!==null&&i!==void 0?i:[]),_.actions.searchInAllLanguagesAllowed((l=(a=this.localesConfiguration)===null||a===void 0?void 0:a.allLanguagesAllowed)!==null&&l!==void 0?l:!1)),e.has("authenticationRequired")&&_.actions.authenticationRequired(this.authenticationRequired),e.has("availableContentLocales")&&_.actions.availableContentLocales((p=(c=this.availableContentLocales)===null||c===void 0?void 0:c.contentLocales)!==null&&p!==void 0?p:[]),setTimeout(()=>this.updateIfNeeded())}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.session==null&&this.updateSession(),this.metadataConfiguration==null&&this.updateMetadataConfiguration()),this.localesConfiguration==null&&this.updateLocalesConfiguration(),this.availableContentLocales==null&&this.updateAvailableContentLocales())}async updateSession(){this.session=await this.cache.get("session",async()=>{let e=await this.apiProvider().getCurrentSession();return e.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.session=void 0},e.idleTimeoutInMillis),e})}async updateMetadataConfiguration(){this.metadataConfiguration=await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration())}async updateLocalesConfiguration(){this.localesConfiguration=await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration())}async updateAvailableContentLocales(){this.availableContentLocales=await this.cache.get("availableContentLocales",()=>El(()=>this.apiProvider().getAvailableSearchLocales(),{contentLocales:[]}))}};Z.elementDefinitions={};Z.styles=$s;se([(0,me.property)()],Z.prototype,"baseUrl",void 0);se([(0,me.property)()],Z.prototype,"apiIntegrationIdentifier",void 0);se([(0,me.property)()],Z.prototype,"apiIntegrationAppVersion",void 0);se([(0,me.property)()],Z.prototype,"uiLocale",void 0);se([(0,Ye.jsonProperty)(null)],Z.prototype,"availableUiLocales",void 0);se([(0,Ye.jsonProperty)(null)],Z.prototype,"metadataConfiguration",void 0);se([(0,me.property)({type:Boolean})],Z.prototype,"editorMode",void 0);se([(0,me.property)({type:Boolean})],Z.prototype,"noCustom",void 0);se([(0,me.property)({type:Boolean})],Z.prototype,"openExternalDocumentInNewTab",void 0);se([(0,me.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],Z.prototype,"noCustomComponent",void 0);se([(0,me.property)({type:Boolean})],Z.prototype,"withManualResources",void 0);se([(0,me.property)({type:Boolean})],Z.prototype,"navigatorOnline",void 0);se([(0,me.property)({type:Boolean})],Z.prototype,"forcedOffline",void 0);se([(0,me.property)({type:Object})],Z.prototype,"apiProvider",void 0);se([(0,me.property)({type:Boolean})],Z.prototype,"authenticationRequired",void 0);se([(0,Ye.jsonProperty)([])],Z.prototype,"messageContexts",void 0);se([(0,Ye.jsonProperty)(void 0)],Z.prototype,"session",void 0);se([(0,me.state)()],Z.prototype,"localesConfiguration",void 0);se([(0,me.state)()],Z.prototype,"availableContentLocales",void 0);var ji=b(ee());function np(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;let o,n,i;if(Array.isArray(t)){if(o=t.length,o!=e.length)return!1;for(n=o;n--!==0;)if(!$o(t[n],e[n]))return!1;return!0}if(t instanceof Map&&e instanceof Map){if(t.size!==e.size)return!1;for(n of t.entries())if(!e.has(n[0]))return!1;for(n of t.entries())if(!$o(n[1],e.get(n[0])))return!1;return!0}if(t instanceof Set&&e instanceof Set){if(t.size!==e.size)return!1;for(n of t.entries())if(!e.has(n[0]))return!1;return!0}if(t.constructor===RegExp)return t.source===e.source&&t.flags===e.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===e.valueOf();let a=l=>Object.keys(l).filter(c=>l[c]!=null);if(i=a(t),o=i.length,o!==a(e).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(e,i[n]))return!1;for(n=o;n--!==0;){let l=i[n];if(!$o(t[l],e[l]))return!1}return!0}return t!==t&&e!==e||t==null&&e==null}function $o(t,e){try{return np(t,e)}catch{return!1}}function eo(t,e){return!$o(t,e)}function Mo(t,e){let o=n=>n[t]===!0;return n=>{if(o(n))return n;let i=e(n);return i[t]=!0,i}}var wl=b(ee(),1);var Si=t=>{let e=t??{};return(o,n)=>{var i;let a={hasChanged:eo,attribute:!1,...e};(0,wl.property)(a)(o,n);let l=o.constructor;l.reduxProperties=new Map(l.reduxProperties),l.reduxProperties.set(n,{selector:(i=e.selector)!==null&&i!==void 0?i:c=>c[n],store:e.store})}};var Uo=class{constructor(){this.queue=[]}add(e,o=!1){o&&this.clear(e.type),this.queue.push(e)}consume(e){let o=this.queue.find(n=>n.type===e);return o&&(this.queue=this.queue.filter(n=>n!==o)),o}clear(e){typeof e=="string"?this.queue=this.queue.filter(o=>o.type!==e):this.queue=this.queue.filter(o=>!e.test(o.type))}};var er=b(ee(),1);var Rl=b(ee(),1);function Ll(t,e){let o=()=>JSON.parse(JSON.stringify(t));return(0,Rl.property)({type:Object,converter:{fromAttribute:n=>{if(n==null)return o();try{return JSON.parse(n)}catch{return o()}},toAttribute:n=>JSON.stringify(n)},hasChanged:eo,...e??{}})}var Fo=class{constructor(e=0){this.timeout=e,this.callbacks=[]}run(e,o){return this.callbacks=[e],this.debounce(o)}queue(e,o){return this.callbacks.push(e),this.debounce(o)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(e){return this.promise==null&&(this.promise=new Promise((o,n)=>{this.resolvePromise=o,this.rejectPromise=n})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),e??this.timeout),this.promise}async runCallbacks(){var e,o;let n=[...this.callbacks];this.callbacks=[];let i=(e=this.rejectPromise)!==null&&e!==void 0?e:()=>null,a=(o=this.resolvePromise)!==null&&o!==void 0?o:()=>null;this.clearPromise();for(let l of n)try{await l()}catch(c){i(c);return}a(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var Nl=b(M(),1);var zo=globalThis,ip=zo.ShadowRoot&&(zo.ShadyCSS===void 0||zo.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Dx=Symbol();var Tl=(t,e)=>{if(ip)t.adoptedStyleSheets=e.map(o=>o instanceof CSSStyleSheet?o:o.styleSheet);else for(let o of e){let n=document.createElement("style"),i=zo.litNonce;i!==void 0&&n.setAttribute("nonce",i),n.textContent=o.cssText,t.appendChild(n)}};var Ho=class extends Nl.LitElement{createRenderRoot(){let e=this.constructor;e.elementDefinitions&&!e.registry&&(e.registry=new CustomElementRegistry,Object.entries(e.elementDefinitions).forEach(([i,a])=>e.registry.define(i,a)));let o={...e.shadowRootOptions,customElements:e.registry},n=this.renderOptions.creationScope=this.attachShadow(o);return Tl(n,e.elementStyles),n}};function Il(t,e,...o){var n;let i=t.querySelector(e);for(let a of o)i=(n=i?.shadowRoot)===null||n===void 0?void 0:n.querySelector(a);return i}var _r=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(l=t[c])&&(a=(i<3?l(a):i>3?l(e,o,a):l(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},Dl,_l=Symbol("constructorPrototype"),kl=Symbol("constructorName"),Bl=Symbol("exportpartsDebouncer"),Pl=Symbol("dynamicDependenciesLoaded"),Ir=class t extends CustomEvent{constructor(){super(t.eventName,{bubbles:!0})}};Ir.eventName="exportparts-updated";var lt=class extends Ho{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[Dl]=new Fo(5),this.scheduleExportpartsUpdate=()=>{var e,o,n;(!((e=this.exportpartsPrefix)===null||e===void 0)&&e.trim()||(n=(o=this.exportpartsPrefixes)===null||o===void 0?void 0:o.length)!==null&&n!==void 0&&n)&&this[Bl].run(()=>{var i,a;!((i=this.exportpartsPrefix)===null||i===void 0)&&i.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((a=this.exportpartsPrefixes)===null||a===void 0?void 0:a.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})},this[kl]=this.constructor.name,this[_l]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[kl]&&Object.setPrototypeOf(this,this[_l])}connectedCallback(){var e;super.connectedCallback();try{this.shadowRoot&&!this.shadowRoot.adoptedStyleSheets.includes(this.adoptedCustomStyleSheet)&&(this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,this.adoptedCustomStyleSheet]),this.useAdoptedStyleSheets=!0}catch(n){this.useAdoptedStyleSheets=!1,console.error("Cannot use adopted stylesheets",n)}let o=this.constructor;o[Pl]||(o[Pl]=!0,this.importDynamicDependencies()),(e=this.shadowRoot)===null||e===void 0||e.addEventListener(Ir.eventName,this.scheduleExportpartsUpdate)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.shadowRoot)===null||e===void 0||e.removeEventListener(Ir.eventName,this.scheduleExportpartsUpdate)}importDynamicDependencies(){}updated(e){super.updated(e),this.updateComplete.then(()=>{this.contentAvailableCallback(e),this.focusElementToFocus(e),this.applyCustomStylesheet(e),this.scheduleExportpartsUpdate(),e.has("exportparts")&&this.dispatchEvent(new Ir)})}contentAvailableCallback(e){}focusElementToFocus(e){if(e.has("elementToFocus")&&this.elementToFocus!=null){let{element:o,selector:n,shadowPath:i}=this.elementToFocus;if(n!=null){let a=[...i??[],n];o=Il(this.shadowRoot,...a)}o?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||o?.blur(),this.elementToFocus=void 0}}applyCustomStylesheet(e){var o,n,i;if(((n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll(".ft-lit-element--custom-stylesheet"))!==null&&n!==void 0?n:[]).forEach(a=>a.remove()),this.useAdoptedStyleSheets){if(e.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((i=this.customStylesheet)!==null&&i!==void 0?i:"")}catch(a){console.error(a,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let a=document.createElement("style");a.classList.add("ft-lit-element--custom-stylesheet"),a.innerHTML=this.customStylesheet,this.shadowRoot.append(a)}}setExportpartsAttribute(e){var o,n,i,a,l,c;let p=g=>g!=null&&g.trim().length>0,u=e.filter(p).map(g=>g.trim());if(u.length===0){this.exportparts=void 0;return}let m=new Set;for(let g of(n=(o=this.shadowRoot)===null||o===void 0?void 0:o.querySelectorAll("[part],[exportparts]"))!==null&&n!==void 0?n:[]){let S=(a=(i=g.getAttribute("part"))===null||i===void 0?void 0:i.split(" "))!==null&&a!==void 0?a:[],v=(c=(l=g.getAttribute("exportparts"))===null||l===void 0?void 0:l.split(",").map(N=>N.split(":")[1]))!==null&&c!==void 0?c:[],E=[...S,...v].filter(p).map(N=>N.trim());for(let N of E)m.add(N)}if(m.size===0){this.exportparts=void 0;return}let h=[...m.values()].flatMap(g=>u.map(S=>`${g}:${S}--${g}`));this.exportparts=[...this.part,...h].join(", ")}};Dl=Bl;_r([(0,er.property)()],lt.prototype,"exportpartsPrefix",void 0);_r([Ll([])],lt.prototype,"exportpartsPrefixes",void 0);_r([(0,er.property)({reflect:!0})],lt.prototype,"exportparts",void 0);_r([(0,er.property)()],lt.prototype,"customStylesheet",void 0);_r([(0,er.property)()],lt.prototype,"elementToFocus",void 0);_r([(0,er.state)()],lt.prototype,"useAdoptedStyleSheets",void 0);function Wo(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var to=Symbol("internalReduxEventsUnsubscribers"),Tt=Symbol("internalStoresUnsubscribers"),tr=Symbol("internalStores"),ap=Mo(Symbol("withRedux"),function(t){var e,o,n;class i extends t{constructor(){super(...arguments),this[e]=new Map,this[o]=new Map,this[n]=new Map}get reduxConstructor(){return this.constructor}willUpdate(l){super.willUpdate(l),[...this.reduxConstructor.reduxReactiveProperties].some(c=>l.has(c))&&this.updateFromStores()}getUnnamedStore(){if(this[tr].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[tr].values()][0]}getStore(l){return l==null?this.getUnnamedStore():this[tr].get(l)}addStore(l,c){var p;c=(p=c??l.name)!==null&&p!==void 0?p:"default-store",this.unsubscribeFromStore(c),this[tr].set(c,l),this.subscribeToStore(c,l),this.updateFromStores()}removeStore(l){let c=typeof l=="string"?l:l.name;this.unsubscribeFromStore(c),this[tr].delete(c)}setupStores(){this.unsubscribeFromStores(),this[tr].forEach((l,c)=>this.subscribeToStore(c,l)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((l,c)=>{let p=this.constructor.getPropertyOptions(c);if(!p?.attribute||!this.hasAttribute(typeof p?.attribute=="string"?p.attribute:c)){let u=this.getStore(l.store);u&&(l.store?this[Tt].has(l.store):this[Tt].size>0)&&(this[c]=l.selector(u.getState(),this))}})}subscribeToStore(l,c){var p;this[Tt].set(l,c.subscribe(()=>this.updateFromStores())),this[to].set(l,[]),Wo(c)&&c.eventBus&&((p=this.reduxConstructor.reduxEventListeners)===null||p===void 0||p.forEach((u,m)=>{if(typeof this[m]=="function"&&(!u.store||c.name===u.store)){let h=g=>this[m](g);c.addEventListener(u.eventName,h),this[to].get(l).push(()=>c.removeEventListener(u.eventName,h))}})),this.onStoreAvailable(l)}unsubscribeFromStores(){this[Tt].forEach((l,c)=>this.unsubscribeFromStore(c))}unsubscribeFromStore(l){var c;this[Tt].has(l)&&this[Tt].get(l)(),this[Tt].delete(l),(c=this[to].get(l))===null||c===void 0||c.forEach(p=>p()),this[to].delete(l)}onStoreAvailable(l){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return e=Tt,o=tr,n=to,i.reduxProperties=new Map,i.reduxReactiveProperties=new Set,i.reduxEventListeners=new Map,i}),$l=class extends ap(lt){};function He(t){for(var e=arguments.length,o=Array(e>1?e-1:0),n=1;n<e;n++)o[n-1]=arguments[n];if(0)var i,a;throw Error("[Immer] minified error nr: "+t+(o.length?" "+o.map(function(l){return"'"+l+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Ot(t){return!!t&&!!t[J]}function Xe(t){var e;return!!t&&(function(o){if(!o||typeof o!="object")return!1;var n=Object.getPrototypeOf(o);if(n===null)return!0;var i=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return i===Object||typeof i=="function"&&Function.toString.call(i)===hp}(t)||Array.isArray(t)||!!t[Gl]||!!(!((e=t.constructor)===null||e===void 0)&&e[Gl])||Ni(t)||Ii(t))}function rr(t,e,o){o===void 0&&(o=!1),Dr(t)===0?(o?Object.keys:Pr)(t).forEach(function(n){o&&typeof n=="symbol"||e(n,t[n],t)}):t.forEach(function(n,i){return e(i,n,t)})}function Dr(t){var e=t[J];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:Ni(t)?2:Ii(t)?3:0}function kr(t,e){return Dr(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function sp(t,e){return Dr(t)===2?t.get(e):t[e]}function jl(t,e,o){var n=Dr(t);n===2?t.set(e,o):n===3?t.add(o):t[e]=o}function Vl(t,e){return t===e?t!==0||1/t==1/e:t!=t&&e!=e}function Ni(t){return up&&t instanceof Map}function Ii(t){return fp&&t instanceof Set}function Nt(t){return t.o||t.t}function _i(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=ql(t);delete e[J];for(var o=Pr(e),n=0;n<o.length;n++){var i=o[n],a=e[i];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(e[i]={configurable:!0,writable:!0,enumerable:a.enumerable,value:t[i]})}return Object.create(Object.getPrototypeOf(t),e)}function ki(t,e){return e===void 0&&(e=!1),Pi(t)||Ot(t)||!Xe(t)||(Dr(t)>1&&(t.set=t.add=t.clear=t.delete=lp),Object.freeze(t),e&&rr(t,function(o,n){return ki(n,!0)},!0)),t}function lp(){He(2)}function Pi(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function ct(t){var e=Ti[t];return e||He(18,t),e}function cp(t,e){Ti[t]||(Ti[t]=e)}function wi(){return oo}function Oi(t,e){e&&(ct("Patches"),t.u=[],t.s=[],t.v=e)}function Go(t){Ri(t),t.p.forEach(dp),t.p=null}function Ri(t){t===oo&&(oo=t.l)}function Ml(t){return oo={p:[],l:oo,h:t,m:!0,_:0}}function dp(t){var e=t[J];e.i===0||e.i===1?e.j():e.g=!0}function Ci(t,e){e._=e.p.length;var o=e.p[0],n=t!==void 0&&t!==o;return e.h.O||ct("ES5").S(e,t,n),n?(o[J].P&&(Go(e),He(4)),Xe(t)&&(t=jo(e,t),e.l||Vo(e,t)),e.u&&ct("Patches").M(o[J].t,t,e.u,e.s)):t=jo(e,o,[]),Go(e),e.u&&e.v(e.u,e.s),t!==Zl?t:void 0}function jo(t,e,o){if(Pi(e))return e;var n=e[J];if(!n)return rr(e,function(c,p){return Ul(t,n,e,c,p,o)},!0),e;if(n.A!==t)return e;if(!n.P)return Vo(t,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=n.i===4||n.i===5?n.o=_i(n.k):n.o,a=i,l=!1;n.i===3&&(a=new Set(i),i.clear(),l=!0),rr(a,function(c,p){return Ul(t,n,i,c,p,o,l)}),Vo(t,i,!1),o&&t.u&&ct("Patches").N(n,o,t.u,t.s)}return n.o}function Ul(t,e,o,n,i,a,l){if(Ot(i)){var c=jo(t,i,a&&e&&e.i!==3&&!kr(e.R,n)?a.concat(n):void 0);if(jl(o,n,c),!Ot(c))return;t.m=!1}else l&&o.add(i);if(Xe(i)&&!Pi(i)){if(!t.h.D&&t._<1)return;jo(t,i),e&&e.A.l||Vo(t,i)}}function Vo(t,e,o){o===void 0&&(o=!1),!t.l&&t.h.D&&t.m&&ki(e,o)}function Ei(t,e){var o=t[J];return(o?Nt(o):t)[e]}function Fl(t,e){if(e in t)for(var o=Object.getPrototypeOf(t);o;){var n=Object.getOwnPropertyDescriptor(o,e);if(n)return n;o=Object.getPrototypeOf(o)}}function It(t){t.P||(t.P=!0,t.l&&It(t.l))}function Ai(t){t.o||(t.o=_i(t.t))}function Li(t,e,o){var n=Ni(e)?ct("MapSet").F(e,o):Ii(e)?ct("MapSet").T(e,o):t.O?function(i,a){var l=Array.isArray(i),c={i:l?1:0,A:a?a.A:wi(),P:!1,I:!1,R:{},l:a,t:i,k:null,o:null,j:null,C:!1},p=c,u=no;l&&(p=[c],u=ro);var m=Proxy.revocable(p,u),h=m.revoke,g=m.proxy;return c.k=g,c.j=h,g}(e,o):ct("ES5").J(e,o);return(o?o.A:wi()).p.push(n),n}function pp(t){return Ot(t)||He(22,t),function e(o){if(!Xe(o))return o;var n,i=o[J],a=Dr(o);if(i){if(!i.P&&(i.i<4||!ct("ES5").K(i)))return i.t;i.I=!0,n=zl(o,a),i.I=!1}else n=zl(o,a);return rr(n,function(l,c){i&&sp(i.t,l)===c||jl(n,l,e(c))}),a===3?new Set(n):n}(t)}function zl(t,e){switch(e){case 2:return new Map(t);case 3:return Array.from(t)}return _i(t)}function Kl(){function t(l,c){var p=a[l];return p?p.enumerable=c:a[l]=p={configurable:!0,enumerable:c,get:function(){var u=this[J];return no.get(u,l)},set:function(u){var m=this[J];no.set(m,l,u)}},p}function e(l){for(var c=l.length-1;c>=0;c--){var p=l[c][J];if(!p.P)switch(p.i){case 5:n(p)&&It(p);break;case 4:o(p)&&It(p)}}}function o(l){for(var c=l.t,p=l.k,u=Pr(p),m=u.length-1;m>=0;m--){var h=u[m];if(h!==J){var g=c[h];if(g===void 0&&!kr(c,h))return!0;var S=p[h],v=S&&S[J];if(v?v.t!==g:!Vl(S,g))return!0}}var E=!!c[J];return u.length!==Pr(c).length+(E?0:1)}function n(l){var c=l.k;if(c.length!==l.t.length)return!0;var p=Object.getOwnPropertyDescriptor(c,c.length-1);if(p&&!p.get)return!0;for(var u=0;u<c.length;u++)if(!c.hasOwnProperty(u))return!0;return!1}function i(l){l.g&&He(3,JSON.stringify(Nt(l)))}var a={};cp("ES5",{J:function(l,c){var p=Array.isArray(l),u=function(h,g){if(h){for(var S=Array(g.length),v=0;v<g.length;v++)Object.defineProperty(S,""+v,t(v,!0));return S}var E=ql(g);delete E[J];for(var N=Pr(E),R=0;R<N.length;R++){var I=N[R];E[I]=t(I,h||!!E[I].enumerable)}return Object.create(Object.getPrototypeOf(g),E)}(p,l),m={i:p?5:4,A:c?c.A:wi(),P:!1,I:!1,R:{},l:c,t:l,k:u,o:null,g:!1,C:!1};return Object.defineProperty(u,J,{value:m,writable:!0}),u},S:function(l,c,p){p?Ot(c)&&c[J].A===l&&e(l.p):(l.u&&function u(m){if(m&&typeof m=="object"){var h=m[J];if(h){var g=h.t,S=h.k,v=h.R,E=h.i;if(E===4)rr(S,function($){$!==J&&(g[$]!==void 0||kr(g,$)?v[$]||u(S[$]):(v[$]=!0,It(h)))}),rr(g,function($){S[$]!==void 0||kr(S,$)||(v[$]=!1,It(h))});else if(E===5){if(n(h)&&(It(h),v.length=!0),S.length<g.length)for(var N=S.length;N<g.length;N++)v[N]=!1;else for(var R=g.length;R<S.length;R++)v[R]=!0;for(var I=Math.min(S.length,g.length),P=0;P<I;P++)S.hasOwnProperty(P)||(v[P]=!0),v[P]===void 0&&u(S[P])}}}}(l.p[0]),e(l.p))},K:function(l){return l.i===4?o(l):n(l)}})}var Hl,oo,Di=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",up=typeof Map<"u",fp=typeof Set<"u",Wl=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",Zl=Di?Symbol.for("immer-nothing"):((Hl={})["immer-nothing"]=!0,Hl),Gl=Di?Symbol.for("immer-draftable"):"__$immer_draftable",J=Di?Symbol.for("immer-state"):"__$immer_state";var hp=""+Object.prototype.constructor,Pr=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames,ql=Object.getOwnPropertyDescriptors||function(t){var e={};return Pr(t).forEach(function(o){e[o]=Object.getOwnPropertyDescriptor(t,o)}),e},Ti={},no={get:function(t,e){if(e===J)return t;var o=Nt(t);if(!kr(o,e))return function(i,a,l){var c,p=Fl(a,l);return p?"value"in p?p.value:(c=p.get)===null||c===void 0?void 0:c.call(i.k):void 0}(t,o,e);var n=o[e];return t.I||!Xe(n)?n:n===Ei(t.t,e)?(Ai(t),t.o[e]=Li(t.A.h,n,t)):n},has:function(t,e){return e in Nt(t)},ownKeys:function(t){return Reflect.ownKeys(Nt(t))},set:function(t,e,o){var n=Fl(Nt(t),e);if(n?.set)return n.set.call(t.k,o),!0;if(!t.P){var i=Ei(Nt(t),e),a=i?.[J];if(a&&a.t===o)return t.o[e]=o,t.R[e]=!1,!0;if(Vl(o,i)&&(o!==void 0||kr(t.t,e)))return!0;Ai(t),It(t)}return t.o[e]===o&&(o!==void 0||e in t.o)||Number.isNaN(o)&&Number.isNaN(t.o[e])||(t.o[e]=o,t.R[e]=!0),!0},deleteProperty:function(t,e){return Ei(t.t,e)!==void 0||e in t.t?(t.R[e]=!1,Ai(t),It(t)):delete t.R[e],t.o&&delete t.o[e],!0},getOwnPropertyDescriptor:function(t,e){var o=Nt(t),n=Reflect.getOwnPropertyDescriptor(o,e);return n&&{writable:!0,configurable:t.i!==1||e!=="length",enumerable:n.enumerable,value:o[e]}},defineProperty:function(){He(11)},getPrototypeOf:function(t){return Object.getPrototypeOf(t.t)},setPrototypeOf:function(){He(12)}},ro={};rr(no,function(t,e){ro[t]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}}),ro.deleteProperty=function(t,e){return ro.set.call(this,t,e,void 0)},ro.set=function(t,e,o){return no.set.call(this,t[0],e,o,t[0])};var yp=function(){function t(o){var n=this;this.O=Wl,this.D=!0,this.produce=function(i,a,l){if(typeof i=="function"&&typeof a!="function"){var c=a;a=i;var p=n;return function(E){var N=this;E===void 0&&(E=c);for(var R=arguments.length,I=Array(R>1?R-1:0),P=1;P<R;P++)I[P-1]=arguments[P];return p.produce(E,function($){var U;return(U=a).call.apply(U,[N,$].concat(I))})}}var u;if(typeof a!="function"&&He(6),l!==void 0&&typeof l!="function"&&He(7),Xe(i)){var m=Ml(n),h=Li(n,i,void 0),g=!0;try{u=a(h),g=!1}finally{g?Go(m):Ri(m)}return typeof Promise<"u"&&u instanceof Promise?u.then(function(E){return Oi(m,l),Ci(E,m)},function(E){throw Go(m),E}):(Oi(m,l),Ci(u,m))}if(!i||typeof i!="object"){if((u=a(i))===void 0&&(u=i),u===Zl&&(u=void 0),n.D&&ki(u,!0),l){var S=[],v=[];ct("Patches").M(i,u,S,v),l(S,v)}return u}He(21,i)},this.produceWithPatches=function(i,a){if(typeof i=="function")return function(u){for(var m=arguments.length,h=Array(m>1?m-1:0),g=1;g<m;g++)h[g-1]=arguments[g];return n.produceWithPatches(u,function(S){return i.apply(void 0,[S].concat(h))})};var l,c,p=n.produce(i,a,function(u,m){l=u,c=m});return typeof Promise<"u"&&p instanceof Promise?p.then(function(u){return[u,l,c]}):[p,l,c]},typeof o?.useProxies=="boolean"&&this.setUseProxies(o.useProxies),typeof o?.autoFreeze=="boolean"&&this.setAutoFreeze(o.autoFreeze)}var e=t.prototype;return e.createDraft=function(o){Xe(o)||He(8),Ot(o)&&(o=pp(o));var n=Ml(this),i=Li(this,o,void 0);return i[J].C=!0,Ri(n),i},e.finishDraft=function(o,n){var i=o&&o[J],a=i.A;return Oi(a,n),Ci(void 0,a)},e.setAutoFreeze=function(o){this.D=o},e.setUseProxies=function(o){o&&!Wl&&He(20),this.O=o},e.applyPatches=function(o,n){var i;for(i=n.length-1;i>=0;i--){var a=n[i];if(a.path.length===0&&a.op==="replace"){o=a.value;break}}i>-1&&(n=n.slice(i+1));var l=ct("Patches").$;return Ot(o)?l(o,n):this.produce(o,function(c){return l(c,n)})},t}(),Pe=new yp,mp=Pe.produce,Yx=Pe.produceWithPatches.bind(Pe),Xx=Pe.setAutoFreeze.bind(Pe),Jx=Pe.setUseProxies.bind(Pe),Qx=Pe.applyPatches.bind(Pe),ev=Pe.createDraft.bind(Pe),tv=Pe.finishDraft.bind(Pe),Ko=mp;function or(t){"@babel/helpers - typeof";return or=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},or(t)}function Yl(t,e){if(or(t)!="object"||!t)return t;var o=t[Symbol.toPrimitive];if(o!==void 0){var n=o.call(t,e||"default");if(or(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Xl(t){var e=Yl(t,"string");return or(e)=="symbol"?e:e+""}function Jl(t,e,o){return(e=Xl(e))in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}function Ql(t,e){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),o.push.apply(o,n)}return o}function Bi(t){for(var e=1;e<arguments.length;e++){var o=arguments[e]!=null?arguments[e]:{};e%2?Ql(Object(o),!0).forEach(function(n){Jl(t,n,o[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):Ql(Object(o)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(o,n))})}return t}function ve(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 ec=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),$i=function(){return Math.random().toString(36).substring(7).split("").join(".")},Zo={INIT:"@@redux/INIT"+$i(),REPLACE:"@@redux/REPLACE"+$i(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+$i()}};function gp(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,o){var n;if(typeof e=="function"&&typeof o=="function"||typeof o=="function"&&typeof arguments[3]=="function")throw new Error(ve(0));if(typeof e=="function"&&typeof o>"u"&&(o=e,e=void 0),typeof o<"u"){if(typeof o!="function")throw new Error(ve(1));return o(Mi)(t,e)}if(typeof t!="function")throw new Error(ve(2));var i=t,a=e,l=[],c=l,p=!1;function u(){c===l&&(c=l.slice())}function m(){if(p)throw new Error(ve(3));return a}function h(E){if(typeof E!="function")throw new Error(ve(4));if(p)throw new Error(ve(5));var N=!0;return u(),c.push(E),function(){if(N){if(p)throw new Error(ve(6));N=!1,u();var I=c.indexOf(E);c.splice(I,1),l=null}}}function g(E){if(!gp(E))throw new Error(ve(7));if(typeof E.type>"u")throw new Error(ve(8));if(p)throw new Error(ve(9));try{p=!0,a=i(a,E)}finally{p=!1}for(var N=l=c,R=0;R<N.length;R++){var I=N[R];I()}return E}function S(E){if(typeof E!="function")throw new Error(ve(10));i=E,g({type:Zo.REPLACE})}function v(){var E,N=h;return E={subscribe:function(I){if(typeof I!="object"||I===null)throw new Error(ve(11));function P(){I.next&&I.next(m())}P();var $=N(P);return{unsubscribe:$}}},E[ec]=function(){return this},E}return g({type:Zo.INIT}),n={dispatch:g,subscribe:h,getState:m,replaceReducer:S},n[ec]=v,n}function bp(t){Object.keys(t).forEach(function(e){var o=t[e],n=o(void 0,{type:Zo.INIT});if(typeof n>"u")throw new Error(ve(12));if(typeof o(void 0,{type:Zo.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(ve(13))})}function tc(t){for(var e=Object.keys(t),o={},n=0;n<e.length;n++){var i=e[n];typeof t[i]=="function"&&(o[i]=t[i])}var a=Object.keys(o),l,c;try{bp(o)}catch(p){c=p}return function(u,m){if(u===void 0&&(u={}),c)throw c;if(0)var h;for(var g=!1,S={},v=0;v<a.length;v++){var E=a[v],N=o[E],R=u[E],I=N(R,m);if(typeof I>"u"){var P=m&&m.type;throw new Error(ve(14))}S[E]=I,g=g||I!==R}return g=g||a.length!==Object.keys(u).length,g?S:u}}function Br(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return e.length===0?function(n){return n}:e.length===1?e[0]:e.reduce(function(n,i){return function(){return n(i.apply(void 0,arguments))}})}function rc(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];return function(n){return function(){var i=n.apply(void 0,arguments),a=function(){throw new Error(ve(15))},l={getState:i.getState,dispatch:function(){return a.apply(void 0,arguments)}},c=e.map(function(p){return p(l)});return a=Br.apply(void 0,c)(i.dispatch),Bi(Bi({},i),{},{dispatch:a})}}}function oc(t){var e=function(n){var i=n.dispatch,a=n.getState;return function(l){return function(c){return typeof c=="function"?c(i,a,t):l(c)}}};return e}var nc=oc();nc.withExtraArgument=oc;var Ui=nc;var cc=function(){var t=function(e,o){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(n[a]=i[a])},t(e,o)};return function(e,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");t(e,o);function n(){this.constructor=e}e.prototype=o===null?Object.create(o):(n.prototype=o.prototype,new n)}}(),xp=function(t,e){var o={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,l;return l={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(l[Symbol.iterator]=function(){return this}),l;function c(u){return function(m){return p([u,m])}}function p(u){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,i=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(a=o.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){o.label=u[1];break}if(u[0]===6&&o.label<a[1]){o.label=a[1],a=u;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(u);break}a[2]&&o.ops.pop(),o.trys.pop();continue}u=e.call(t,o)}catch(m){u=[6,m],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},$r=function(t,e){for(var o=0,n=e.length,i=t.length;o<n;o++,i++)t[i]=e[o];return t},vp=Object.defineProperty,Sp=Object.defineProperties,Op=Object.getOwnPropertyDescriptors,ic=Object.getOwnPropertySymbols,Cp=Object.prototype.hasOwnProperty,Ep=Object.prototype.propertyIsEnumerable,ac=function(t,e,o){return e in t?vp(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o},_t=function(t,e){for(var o in e||(e={}))Cp.call(e,o)&&ac(t,o,e[o]);if(ic)for(var n=0,i=ic(e);n<i.length;n++){var o=i[n];Ep.call(e,o)&&ac(t,o,e[o])}return t},Fi=function(t,e){return Sp(t,Op(e))},Ap=function(t,e,o){return new Promise(function(n,i){var a=function(p){try{c(o.next(p))}catch(u){i(u)}},l=function(p){try{c(o.throw(p))}catch(u){i(u)}},c=function(p){return p.done?n(p.value):Promise.resolve(p.value).then(a,l)};c((o=o.apply(t,e)).next())})};var wp=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Br:Br.apply(null,arguments)},xv=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}};function Rp(t){if(typeof t!="object"||t===null)return!1;var e=Object.getPrototypeOf(t);if(e===null)return!0;for(var o=e;Object.getPrototypeOf(o)!==null;)o=Object.getPrototypeOf(o);return e===o}var Lp=function(t){cc(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return t.prototype.concat.apply(this,o)},e.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(e.bind.apply(e,$r([void 0],o[0].concat(this)))):new(e.bind.apply(e,$r([void 0],o.concat(this))))},e}(Array),Tp=function(t){cc(e,t);function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var i=t.apply(this,o)||this;return Object.setPrototypeOf(i,e.prototype),i}return Object.defineProperty(e,Symbol.species,{get:function(){return e},enumerable:!1,configurable:!0}),e.prototype.concat=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return t.prototype.concat.apply(this,o)},e.prototype.prepend=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.length===1&&Array.isArray(o[0])?new(e.bind.apply(e,$r([void 0],o[0].concat(this)))):new(e.bind.apply(e,$r([void 0],o.concat(this))))},e}(Array);function Wi(t){return Xe(t)?Ko(t,function(){}):t}function Np(t){return typeof t=="boolean"}function Ip(){return function(e){return _p(e)}}function _p(t){t===void 0&&(t={});var e=t.thunk,o=e===void 0?!0:e,n=t.immutableCheck,i=n===void 0?!0:n,a=t.serializableCheck,l=a===void 0?!0:a,c=new Lp;if(o&&(Np(o)?c.push(Ui):c.push(Ui.withExtraArgument(o.extraArgument))),0){if(i)var p;if(l)var u}return c}var zi=!0;function dc(t){var e=Ip(),o=t||{},n=o.reducer,i=n===void 0?void 0:n,a=o.middleware,l=a===void 0?e():a,c=o.devTools,p=c===void 0?!0:c,u=o.preloadedState,m=u===void 0?void 0:u,h=o.enhancers,g=h===void 0?void 0:h,S;if(typeof i=="function")S=i;else if(Rp(i))S=tc(i);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 v=l;if(typeof v=="function"&&(v=v(e),!zi&&!Array.isArray(v)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!zi&&v.some(function($){return typeof $!="function"}))throw new Error("each middleware provided to configureStore must be a function");var E=rc.apply(void 0,v),N=Br;p&&(N=wp(_t({trace:!zi},typeof p=="object"&&p)));var R=new Tp(E),I=R;Array.isArray(g)?I=$r([E],g):typeof g=="function"&&(I=g(R));var P=N.apply(void 0,I);return Mi(S,m,P)}function kt(t,e){function o(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];if(e){var a=e.apply(void 0,n);if(!a)throw new Error("prepareAction did not return an object");return _t(_t({type:t,payload:a.payload},"meta"in a&&{meta:a.meta}),"error"in a&&{error:a.error})}return{type:t,payload:n[0]}}return o.toString=function(){return""+t},o.type=t,o.match=function(n){return n.type===t},o}function pc(t){var e={},o=[],n,i={addCase:function(a,l){var c=typeof a=="string"?a:a.type;if(c in e)throw new Error("addCase cannot be called with two reducers for the same action type");return e[c]=l,i},addMatcher:function(a,l){return o.push({matcher:a,reducer:l}),i},addDefaultCase:function(a){return n=a,i}};return t(i),[e,o,n]}function kp(t){return typeof t=="function"}function Pp(t,e,o,n){o===void 0&&(o=[]);var i=typeof e=="function"?pc(e):[e,o,n],a=i[0],l=i[1],c=i[2],p;if(kp(t))p=function(){return Wi(t())};else{var u=Wi(t);p=function(){return u}}function m(h,g){h===void 0&&(h=p());var S=$r([a[g.type]],l.filter(function(v){var E=v.matcher;return E(g)}).map(function(v){var E=v.reducer;return E}));return S.filter(function(v){return!!v}).length===0&&(S=[c]),S.reduce(function(v,E){if(E)if(Ot(v)){var N=v,R=E(N,g);return R===void 0?v:R}else{if(Xe(v))return Ko(v,function(I){return E(I,g)});var R=E(v,g);if(R===void 0){if(v===null)return v;throw Error("A case reducer on a non-draftable value must not return undefined")}return R}return v},h)}return m.getInitialState=p,m}function Dp(t,e){return t+"/"+e}function uc(t){var e=t.name;if(!e)throw new Error("`name` is a required option for createSlice");typeof process<"u";var o=typeof t.initialState=="function"?t.initialState:Wi(t.initialState),n=t.reducers||{},i=Object.keys(n),a={},l={},c={};i.forEach(function(m){var h=n[m],g=Dp(e,m),S,v;"reducer"in h?(S=h.reducer,v=h.prepare):S=h,a[m]=S,l[g]=S,c[m]=v?kt(g,v):kt(g)});function p(){var m=typeof t.extraReducers=="function"?pc(t.extraReducers):[t.extraReducers],h=m[0],g=h===void 0?{}:h,S=m[1],v=S===void 0?[]:S,E=m[2],N=E===void 0?void 0:E,R=_t(_t({},g),l);return Pp(o,function(I){for(var P in R)I.addCase(P,R[P]);for(var $=0,U=v;$<U.length;$++){var Re=U[$];I.addMatcher(Re.matcher,Re.reducer)}N&&I.addDefaultCase(N)})}var u;return{name:e,reducer:function(m,h){return u||(u=p()),u(m,h)},actions:c,caseReducers:a,getInitialState:function(){return u||(u=p()),u.getInitialState()}}}var Bp="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",$p=function(t){t===void 0&&(t=21);for(var e="",o=t;o--;)e+=Bp[Math.random()*64|0];return e},Mp=["name","message","stack","code"],Hi=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),sc=function(){function t(e,o){this.payload=e,this.meta=o}return t}(),Up=function(t){if(typeof t=="object"&&t!==null){for(var e={},o=0,n=Mp;o<n.length;o++){var i=n[o];typeof t[i]=="string"&&(e[i]=t[i])}return e}return{message:String(t)}},Cv=function(){function t(e,o,n){var i=kt(e+"/fulfilled",function(m,h,g,S){return{payload:m,meta:Fi(_t({},S||{}),{arg:g,requestId:h,requestStatus:"fulfilled"})}}),a=kt(e+"/pending",function(m,h,g){return{payload:void 0,meta:Fi(_t({},g||{}),{arg:h,requestId:m,requestStatus:"pending"})}}),l=kt(e+"/rejected",function(m,h,g,S,v){return{payload:S,error:(n&&n.serializeError||Up)(m||"Rejected"),meta:Fi(_t({},v||{}),{arg:g,requestId:h,rejectedWithValue:!!S,requestStatus:"rejected",aborted:m?.name==="AbortError",condition:m?.name==="ConditionError"})}}),c=!1,p=typeof AbortController<"u"?AbortController:function(){function m(){this.signal={aborted:!1,addEventListener:function(){},dispatchEvent:function(){return!1},onabort:function(){},removeEventListener:function(){},reason:void 0,throwIfAborted:function(){}}}return m.prototype.abort=function(){},m}();function u(m){return function(h,g,S){var v=n?.idGenerator?n.idGenerator(m):$p(),E=new p,N,R=!1;function I($){N=$,E.abort()}var P=function(){return Ap(this,null,function(){var $,U,Re,rt,Ce,ot,fe;return xp(this,function(y){switch(y.label){case 0:return y.trys.push([0,4,,5]),rt=($=n?.condition)==null?void 0:$.call(n,m,{getState:g,extra:S}),zp(rt)?[4,rt]:[3,2];case 1:rt=y.sent(),y.label=2;case 2:if(rt===!1||E.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};return R=!0,Ce=new Promise(function(x,k){return E.signal.addEventListener("abort",function(){return k({name:"AbortError",message:N||"Aborted"})})}),h(a(v,m,(U=n?.getPendingMeta)==null?void 0:U.call(n,{requestId:v,arg:m},{getState:g,extra:S}))),[4,Promise.race([Ce,Promise.resolve(o(m,{dispatch:h,getState:g,extra:S,requestId:v,signal:E.signal,abort:I,rejectWithValue:function(x,k){return new Hi(x,k)},fulfillWithValue:function(x,k){return new sc(x,k)}})).then(function(x){if(x instanceof Hi)throw x;return x instanceof sc?i(x.payload,v,m,x.meta):i(x,v,m)})])];case 3:return Re=y.sent(),[3,5];case 4:return ot=y.sent(),Re=ot instanceof Hi?l(null,v,m,ot.payload,ot.meta):l(ot,v,m),[3,5];case 5:return fe=n&&!n.dispatchConditionRejection&&l.match(Re)&&Re.meta.condition,fe||h(Re),[2,Re]}})})}();return Object.assign(P,{abort:I,requestId:v,arg:m,unwrap:function(){return P.then(Fp)}})}}return Object.assign(u,{pending:a,rejected:l,fulfilled:i,typePrefix:e})}return t.withTypes=function(){return t},t}();function Fp(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function zp(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var fc="listener",hc="completed",yc="cancelled",Ev="task-"+yc,Av="task-"+hc,wv=fc+"-"+yc,Rv=fc+"-"+hc;var Gi="listenerMiddleware";var Lv=kt(Gi+"/add"),Tv=kt(Gi+"/removeAll"),Nv=kt(Gi+"/remove");var lc,Iv=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:typeof global<"u"?global:globalThis):function(t){return(lc||(lc=Promise.resolve())).then(t).catch(function(e){return setTimeout(function(){throw e},0)})},Hp=function(t){return function(e){setTimeout(e,t)}},_v=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Hp(10);Kl();var Wp=Mo(Symbol("withEventBus"),function(t,e){return class extends t{constructor(){super(...arguments),this.eventBus=e??document.createElement("span")}addEventListener(o,n,i){this.eventBus.addEventListener(o,n,i)}dispatchEvent(o){return this.eventBus.dispatchEvent(o)}removeEventListener(o,n,i){this.eventBus.removeEventListener(o,n,i)}}}),qo=class extends Wp(Object){};window.ftReduxStores||(window.ftReduxStores={});var mc=class t extends qo{static get(e){var o;let n=typeof e=="string"?e:e.name,i=typeof e=="string"?void 0:e,a=window.ftReduxStores[n];if(Wo(a))return a;if(i==null)return;let l=uc({...i,reducers:(o=i.reducers)!==null&&o!==void 0?o:{}}),c=dc({reducer:(p,u)=>u.type==="CLEAR_FT_REDUX_STORE"?l.getInitialState():typeof u.type=="string"&&u.type.startsWith("DEFAULT_VALUE_SETTER__")?{...p,...u.overwrites}:l.reducer(p,u)});return window.ftReduxStores[i.name]=new t(l,c,i.eventBus)}constructor(e,o,n){super(),this.reduxSlice=e,this.reduxStore=o,this.isFtReduxStore=!0,this.commands=new Uo;let i=a=>a!=null?JSON.parse(JSON.stringify(a)):a;this.actions=new Proxy(this.reduxSlice.actions,{get:(a,l,c)=>{let p=l,u=a[p];return u?(...m)=>{let h=u(...m.map(i));return this.reduxStore.dispatch(h),h}:m=>{this.setState({[p]:i(m)})}}}),this.eventBus=n??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE"})}setState(e){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(e).join("_"),overwrites:e})}get dispatch(){throw new Error("Don't use this method, actions are automatically dispatched when called.")}[Symbol.observable](){return this.reduxStore[Symbol.observable]()}getState(){return this.reduxStore.getState()}replaceReducer(e){throw new Error("Not implemented yet.")}subscribe(e){return this.reduxStore.subscribe(e)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}};var Yo=class{static format(e,o,n,i){return window.moment?window.moment(e).locale(o).format(this.getMomentDateFormat(n,i)):this.getIntlDateTime(e,o,n,i)}static getMomentDateFormat(e,o){return e?o?"lll":"ll":o?"L LT":"L"}static getIntlDateTime(e,o,n,i){let a=typeof e=="string"?new Date(e):e,l=new Intl.DateTimeFormat(o,{dateStyle:n?"medium":"short"}).format(a);if(!i)return l;let c=new Intl.DateTimeFormat(o,{timeStyle:"short"}).format(a);return`${l} ${c}`}static getTimezoneAsString(){let e=n=>String(Math.floor(n)).padStart(2,"0"),o=new Date().getTimezoneOffset();return`${o<0?"+":"-"}${e(Math.abs(o)/60)}:${e(Math.abs(o)%60)}`}};var gc=b(L()),Xo=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(l=t[c])&&(a=(i<3?l(a):i>3?l(e,o,a):l(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},r0=(0,gc.applyMixinOnce)(Symbol("withDateFormat"),function(t){class e extends t{constructor(...n){super(n),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(_)}dateFormatOptionsChanged(n){return n.has("metadataDescriptors")||n.has("useLongDateFormat")||n.has("useDateTimeFormat")||n.has("uiLocale")}getDateFormatter(n){var i,a;return((a=(i=this.metadataDescriptors.find(c=>c.key===n))===null||i===void 0?void 0:i.date)!==null&&a!==void 0?a:!1)?c=>Yo.format(c,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return Xo([(0,ji.property)({type:Boolean})],e.prototype,"useLongDateFormat",void 0),Xo([(0,ji.property)({type:Boolean})],e.prototype,"useDateTimeFormat",void 0),Xo([Si({store:_.name,selector:o=>{var n,i;return(i=(n=o.metadataConfiguration)===null||n===void 0?void 0:n.descriptors)!==null&&i!==void 0?i:[]}})],e.prototype,"metadataDescriptors",void 0),Xo([Si({store:_.name})],e.prototype,"uiLocale",void 0),e});var en=b(L());var Jo=class extends ke{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetCount(e){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${e}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(e){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${e}`),this.CACHE_DURATION)}isAuthenticated(){let e=_.getState().session;return!!e?.sessionAuthenticated}};var Qo=class extends ke{constructor(){super(...arguments),this.CACHE_DURATION=3*60*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let e=_.getState().session;return!!e?.sessionAuthenticated}};var Gp="ft-user-assets",jp={setAssetCount:(t,e)=>{let{userAssetType:o,count:n}=e.payload.assetCount;t.assetCounts.allAsset[o]=n},clearAssetCount:t=>{Object.values(ze).forEach(e=>{t.assetCounts.allAsset[e]=void 0})},setBookmarkCountByMap:(t,e)=>{let o=e.payload.mapId;t.assetCounts.bookmarkByMap[o]=e.payload.count},clearBookmarkCountByMap:t=>{t.assetCounts.bookmarkByMap={}},addAsset:(t,e)=>{let{assetType:o,mapId:n,asset:i}=e.payload;Ki(t,o,[...Vi(t,o),i]),bc(t,o,1,n),xc(t,i)},editAsset:(t,e)=>{let{assetType:o,asset:n}=e.payload;Ki(t,o,Vi(t,o).map(i=>i.id===n.id?n:i)),xc(t,n)},removeAsset:(t,e)=>{let{assetType:o,mapId:n,assetId:i}=e.payload;Ki(t,o,Vi(t,o).filter(a=>a.id!==i)),bc(t,o,-1,n)}},vc={[ze.SEARCHES]:"savedSearches",[ze.BOOKMARKS]:"bookmarks",[ze.BOOKS]:void 0,[ze.COLLECTIONS]:void 0},Vi=(t,e)=>{var o;let n=vc[e];return n?(o=t[n])!==null&&o!==void 0?o:[]:[]},Ki=(t,e,o)=>{let n=vc[e];n&&(t[n]=o)},bc=(t,e,o,n)=>{let i=t.assetCounts.allAsset[e];if(i!==void 0&&(t.assetCounts.allAsset[e]=Math.max(0,i+o),e===ze.BOOKMARKS&&n)){let a=t.assetCounts.bookmarkByMap[n];t.assetCounts.bookmarkByMap[n]=Math.max(0,a+o)}},xc=(t,e)=>{let o=t.assetLabels.map(i=>i.title),n=e.labels.filter(i=>!o.includes(i)).map(i=>({title:i}));t.assetLabels.push(...n)},De=en.FtReduxStore.get({name:Gp,reducers:jp,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(ze).map(t=>[t,void 0])),bookmarkByMap:{}},assetLabels:[]}}),Zi=class{constructor(e=new Jo,o=new Qo){this.assetCountsService=e,this.assetLabelsService=o,this.currentSession=_.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new Io,this.savedSearchesService=new Do,_.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:o}=_.getState();(0,en.deepEqual)((e=this.currentSession)===null||e===void 0?void 0:e.profile,o?.profile)||(this.currentSession=o,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),De.actions.clearAssetCount(),De.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),De.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),De.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();De.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let e=await this.assetLabelsService.getUserAssetLabels();De.actions.assetLabels(e)}async loadAssetCount(e){let o=await this.assetCountsService.getUserAssetCount(e);o&&De.actions.setAssetCount({assetCount:o})}async loadBookmarkByMapId(e){let o=await this.assetCountsService.getUserBookmarkCountByMap(e);o&&De.actions.setBookmarkCountByMap({count:o.count,mapId:e})}async reloadAssetCount(e){this.assetCountsService.clearCache();let o=Object.keys(De.getState().assetCounts.bookmarkByMap).length!==0;e===ze.BOOKMARKS&&o&&De.actions.clearBookmarkCountByMap(),De.getState().assetCounts.allAsset[e]!==void 0&&await this.loadAssetCount(e)}async registerBookmarkComponent(){this.bookmarksAreUsed=!0,await this.updateBookmarksIfUsed()}async updateBookmarksIfUsed(){var e;if(this.bookmarksAreUsed){let o=!((e=this.currentSession)===null||e===void 0)&&e.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;De.actions.bookmarks(o)}}},Vp=new Zi;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=Vp);(0,Sc.customElement)("ft-app-context")(Z);var Oc=b(ee());var qi=class{fromLocalizableLabel(e){return e.type=="PLAIN_TEXT"?{message:e.text}:{key:e.key,custom:e.type=="LOCALIZED_CUSTOM",context:e.context,message:e.key}}fromAttribute(e){if(e!=null)try{return JSON.parse(e)}catch{if(this.isI18nKey(e)){let[n,i]=e.split(".");return{context:n,key:i,custom:!0,message:""}}return{message:e}}}toAttribute(e){if(e!=null)return JSON.stringify(e)}isI18nKey(e){return e.match(/^[\w-]+\.[\w-]+$/)}},Mr=new qi;var Kp=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(l=t[c])&&(a=(i<3?l(a):i>3?l(e,o,a):l(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},ao=Symbol("i18nAttributes"),Cc=Symbol("i18nListAttributes"),Ec=Symbol("i18nProperties"),tn=Symbol("i18nContexts"),io=Symbol("i18nUnsubs"),nn=(0,Ur.applyMixinOnce)(Symbol("withI18n"),function(t){var e,o;class n extends t{constructor(){super(...arguments),this.useCustomMessageContexts=!1,this[e]=new Map,this[o]=new Map}getI18nService(a){return a??this.useCustomMessageContexts?mi:Jr}i18n(a){let{context:l,key:c,message:p}=a,{custom:u,args:m,argsProvider:h}=a;if(l&&c){this.hasI18nContext(l)||this.addI18nContext(l,void 0,u);let g=m??(h?h(this):[]);return this.getI18nService(u).resolveMessage(l,c,...g)}return p}async awaitI18n(a){let{context:l,custom:c}=a;return l&&await this.getI18nService(c).prepareContext(l),this.i18n(a)}customI18n(a,l){if(Mr.isI18nKey(a)){let[c,p]=a.split(".");return this.i18n({custom:!0,context:c,key:p,...l})||a}return a}firstUpdated(a){super.firstUpdated(a),this.updateI18nAttributes(()=>!0),this.updateI18nProperties(()=>!0)}update(a){super.update(a),this.updateI18nAttributes((l,c,p)=>a.has(c)||typeof l.argsProvider=="function"),this.updateI18nProperties(l=>typeof l.argsProvider=="function")}onI18nUpdate(a){this.updateI18nAttributes((l,c,p)=>{var u;return((u=p?.context)===null||u===void 0?void 0:u.toLowerCase())===a}),this.updateI18nProperties(l=>l.context.toLowerCase()===a),this.requestUpdate()}updateI18nAttributes(a){var l,c;let p=this,u=(m,h,g)=>g?.context&&g.key&&a(m,h,g)?{...g,message:this.i18n({context:g.context,key:g.key,custom:g.custom,...m})}:g;(l=this[ao])===null||l===void 0||l.forEach((m,h)=>p[h]=u(m,h,p[h])),(c=this[Cc])===null||c===void 0||c.forEach((m,h)=>{var g;return p[h]=(g=p[h])===null||g===void 0?void 0:g.map(S=>u(m,h,S))})}updateI18nProperties(a){var l;(l=this[Ec])===null||l===void 0||l.forEach((c,p)=>{a(c,p)&&(this[p]=this.i18n(c))})}addI18nMessages(a,l,c){console.warn('Deprecated usage of method "addI18nMessages", use "addI18nContext" instead.'),this.addI18nContext(a,l,c)}addI18nContext(a,l,c){let p=(typeof a=="string"?a:a.name).toLowerCase();c=typeof a=="string"?c:a.custom,this[tn].set(p,{isCustomContext:c}),this[io].has(p)||this[io].set(p,this.getI18nService(c).subscribe(p,()=>this.onI18nUpdate(p))),this.getI18nService(c).prepareContext(p,l)}hasI18nContext(a){return this[tn].has(a.toLowerCase())}connectedCallback(){super.connectedCallback(),this[tn].forEach((a,l)=>this.addI18nContext(l,void 0,a.isCustomContext))}disconnectedCallback(){super.disconnectedCallback(),this[io].forEach(a=>a()),this[io].clear()}}return e=tn,o=io,Kp([(0,Oc.property)({type:Boolean})],n.prototype,"useCustomMessageContexts",void 0),n}),rn=class extends nn(Ur.FtLitElement){},on=class extends nn(Ur.FtLitElementRedux){};var Ac=b(L());var Yi=class{fromAttribute(e){if(!e)return[];try{let o=JSON.parse(e);return Array.isArray(o)?o.map(n=>typeof n=="string"?Mr.fromAttribute(n):n):[]}catch{return[]}}toAttribute(e){if(e!=null)return JSON.stringify(e)}},Zp=new Yi;var wc=(t,e)=>(o,n)=>{var i;o.constructor.createProperty(n,{type:Object,hasChanged:Ac.hasChanged,converter:Mr,...e}),o[ao]=(i=o[ao])!==null&&i!==void 0?i:new Map,o[ao].set(n,t??{})};var Tc=b(L());var an=b(M()),sn=b(ee()),ln=b(L());var Rc=b(M());var Lc=Rc.css`
546
546
  `;var so=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(l=t[c])&&(a=(i<3?l(a):i>3?l(e,o,a):l(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},Je=class extends on{constructor(){super(),this.editorMode=!1,this.addStore(_)}render(){return!this.key||!this.context?this.editorMode?"Select a context and a label key.":an.nothing:an.html`
@@ -562,7 +562,7 @@ Also for action icons.`,s.colorGray200),contentGlobalSubtle:r.extend("--ftds-con
562
562
  </div>
563
563
  </div>
564
564
  </div>
565
- `}setupFor(e){this.eventsTarget!==e&&(this.removeHandlers(),this.eventsTarget=e,this.eventsTarget.addEventListener("mouseenter",this.onHover,{passive:!0}),this.eventsTarget.addEventListener("mouseleave",this.onOut,{passive:!0}),this.eventsTarget.addEventListener("focusin",this.onFocusIn,{passive:!0}),this.eventsTarget.addEventListener("focusout",this.onOut,{passive:!0}),this.eventsTarget.addEventListener("touchstart",this.onTouch,{passive:!0}),this.eventsTarget.addEventListener("click",this.onClick,{passive:!0}))}removeHandlers(){this.eventsTarget&&(this.eventsTarget.removeEventListener("mouseenter",this.onHover),this.eventsTarget.removeEventListener("mouseleave",this.onOut),this.eventsTarget.removeEventListener("focusin",this.onFocusIn),this.eventsTarget.removeEventListener("focusout",this.onOut),this.eventsTarget.removeEventListener("touchstart",this.onTouch),this.eventsTarget.removeEventListener("click",this.onClick),this.eventsTarget=void 0)}defaultSetup(){this.container&&this.setupFor(this.container)}updated(e){e.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(e)}contentAvailableCallback(e){super.contentAvailableCallback(e),["visible","text"].some(o=>e.has(o))&&this.visible&&this.positionTooltip()}connectedCallback(){super.connectedCallback(),this.updateComplete.then(()=>{this.eventsTarget==null&&this.defaultSetup()})}disconnectedCallback(){super.disconnectedCallback(),this.removeHandlers()}async show(e){this.visible=!0,e!=null&&await this.hideDebounce.run(()=>{this.hide()},e)}async showTemporaryText(e,o){let n=this.manual;this.manual=!0;let i=this.text;this.text={message:e},await this.show(o),this.text=i,this.manual=n}hide(){this.visible=!1}toggle(){this.visible=!this.visible}isVisible(){return this.visible}get slottedElement(){var e;return((e=this.slotNodes)!==null&&e!==void 0?e:[]).filter(o=>o.nodeType==Node.ELEMENT_NODE)[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){let e=this.tooltipContent.style;switch(e.transition="none",this.validPosition){case"top":e.top=this.tooltip.clientHeight+"px",e.left="0";break;case"bottom":e.top=-this.tooltip.clientHeight+"px",e.left="0";break;case"left":e.top="0",e.left=this.tooltip.clientWidth+"px";break;case"right":e.top="0",e.left=-this.tooltip.clientWidth+"px";break}}}positionTooltip(){this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",Ds(this.slottedElement,this.tooltip,this.position).then(({x:e,y:o})=>{this.tooltip&&(this.tooltip.style.left=`${e}px`,this.tooltip.style.top=`${o}px`)})),this.revealDebouncer.run(()=>{this.tooltipContent&&(this.tooltipContent.style.transition=`top ${We.designSystemVariables.transitionDuration}, left ${We.designSystemVariables.transitionDuration}`,this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")},this.manual?0:this.delay)}isIgnored(e){return this.manual||(0,We.eventPathContainsMatchingElement)(e,this.ignoreMatchingElements,this.eventsTarget)}};le.elementDefinitions={"ft-typography":re};le.styles=ds;Qe([wc()],le.prototype,"text",void 0);Qe([(0,Ge.property)({type:Boolean})],le.prototype,"manual",void 0);Qe([(0,Ge.property)({type:Boolean})],le.prototype,"inline",void 0);Qe([(0,We.numberProperty)()],le.prototype,"delay",void 0);Qe([(0,Ge.property)()],le.prototype,"position",void 0);Qe([(0,We.jsonProperty)([])],le.prototype,"ignoreMatchingElements",void 0);Qe([(0,Ge.queryAssignedNodes)()],le.prototype,"slotNodes",void 0);Qe([(0,Ge.query)(".ft-tooltip--container")],le.prototype,"container",void 0);Qe([(0,Ge.query)(".ft-tooltip")],le.prototype,"tooltip",void 0);Qe([(0,Ge.query)(".ft-tooltip--content")],le.prototype,"tooltipContent",void 0);Qe([(0,Ge.state)()],le.prototype,"visible",void 0);(0,Ic.customElement)("ft-tooltip")(le);var Bc=b(L());var lo=b(M()),Pt=b(ee()),Pc=b(L()),Dc=b(kc());var cn;(function(t){t.ADD_TO_PBK="&#xe800;",t.ALERT="&#xe801;",t.ADD_ALERT="&#xe802;",t.BACK_TO_SEARCH="&#xe803;",t.ADD_BOOKMARK="&#xe804;",t.BOOKMARK="&#xe805;",t.BOOKS="&#xe806;",t.MENU="&#xe807;",t.DOWNLOAD="&#xe808;",t.EDIT="&#xe809;",t.FEEDBACK="&#xe80a;",t.HOME="&#xe80b;",t.MODIFY_PBK="&#xe80c;",t.SCHEDULED="&#xe80d;",t.SEARCH="&#xe80e;",t.EXPORT="&#xe80f;",t.TOC="&#xe810;",t.WRITE_UGC="&#xe811;",t.TRASH="&#xe812;",t.USER="&#xe813;",t.EXTLINK="&#xe814;",t.CALENDAR="&#xe815;",t.OFFLINE="&#xe816;",t.BOOK="&#xe817;",t.DOWNLOAD_PLAIN="&#xe818;",t.CHECK="&#xe819;",t.STAR_PLAIN="&#xe900;",t.TOPICS="&#xe901;",t.DISC="&#xe902;",t.CIRCLE="&#xe903;",t.SHARED="&#xe904;",t.SORT_UNSORTED="&#xe905;",t.SORT_UP="&#xe906;",t.SORT_DOWN="&#xe907;",t.WORKING="&#xe908;",t.CLOSE="&#xe909;",t.ZOOM_OUT="&#xe90a;",t.ZOOM_IN="&#xe90b;",t.ZOOM_REALSIZE="&#xe90c;",t.ZOOM_FULLSCREEN="&#xe90d;",t.ADMIN_RESTRICTED="&#xe90e;",t.ADMIN="&#xe90f;",t.ADMIN_KHUB="&#xe910;",t.ADMIN_THEME="&#xe911;",t.ADMIN_USERS="&#xe912;",t.WARNING="&#xe913;",t.CONTEXT="&#xe914;",t.SEARCH_HOME="&#xe915;",t.STEPS="&#xe916;",t.ICON_EXPAND="&#xe917;",t.ICON_COLLAPSE="&#xe918;",t.INFO="&#xe919;",t.MINUS_PLAIN="&#xe91a;",t.PLUS_PLAIN="&#xe91b;",t.FACET_HAS_DESCENDANT="&#xe91c;",t.TRIANGLE_BOTTOM="&#xe91d;",t.TRIANGLE_LEFT="&#xe91e;",t.TRIANGLE_RIGHT="&#xe91f;",t.TRIANGLE_TOP="&#xe920;",t.THIN_ARROW="&#xe921;",t.SIGN_IN="&#xe922;",t.LOGOUT="&#xe923;",t.TRANSLATE="&#xe924;",t.CLOSE_PLAIN="&#xe925;",t.CHECK_PLAIN="&#xe926;",t.ARTICLE="&#xe927;",t.COLUMNS="&#xe928;",t.ANALYTICS="&#xe929;",t.COLLECTIONS="&#xe92a;",t.ARROW_DOWN="&#xe92b;",t.ARROW_LEFT="&#xe92c;",t.ARROW_RIGHT="&#xe92d;",t.ARROW_UP="&#xe92e;",t.SEARCH_IN_PUBLICATION="&#xe92f;",t.COPY_TO_CLIPBOARD="&#xe930;",t.SHARED_PBK="&#xe931;",t.ATTACHMENTS="&#xe932;",t.STRIPE_ARROW_LEFT="&#xe933;",t.STRIPE_ARROW_RIGHT="&#xe934;",t.FILTERS="&#xe935;",t.DOT="&#xe936;",t.MINUS="&#xe937;",t.PLUS="&#xe938;",t.MAILS_AND_NOTIFICATIONS="&#xe939;",t.SAVE="&#xe93a;",t.LOCKER="&#xe93b;",t.ADMIN_INTEGRATION="&#xe93c;",t.SYNC="&#xe93d;",t.TAG="&#xe93e;",t.BOOK_PLAIN="&#xe93f;",t.UPLOAD="&#xe940;",t.ONLINE="&#xe941;",t.TAG_PLAIN="&#xe942;",t.ACCOUNT_SETTINGS="&#xe943;",t.PRINT="&#xe944;",t.DEFAULT_ROLES="&#xe945;",t.SHORTCUT_MENU="&#xe946;",t.RELATIVES_PLAIN="&#xe947;",t.RELATIVES="&#xe948;",t.PAUSE="&#xe949;",t.PLAY="&#xe94a;",t.ADMIN_PORTAL="&#xe94b;",t.STAR="&#xe94c;",t.THUMBS_DOWN="&#xe94d;",t.THUMBS_DOWN_PLAIN="&#xe94e;",t.THUMBS_UP="&#xe94f;",t.THUMBS_UP_PLAIN="&#xe950;",t.FEEDBACK_PLAIN="&#xe951;",t.RATE_PLAIN="&#xe952;",t.RATE="&#xe953;",t.OFFLINE_SETTINGS="&#xe954;",t.MY_COLLECTIONS="&#xe955;",t.THIN_ARROW_LEFT="&#xe956;",t.THIN_ARROW_RIGHT="&#xe957;",t.RESET="&#xe958;",t.MY_LIBRARY="&#xe959;",t.UNSTRUCTURED_DOC="&#xe95a;",t.CONTEXTUAL="&#xe95b;",t.THIN_ARROW_UP="&#xe95c;",t.ARROW_RIGHT_TO_LINE="&#xe95d;",t.DESKTOP="&#xe95e;",t.TABLET_LANDSCAPE="&#xe95f;",t.TABLET_PORTRAIT="&#xe960;",t.MOBILE_LANDSCAPE="&#xe961;",t.MOBILE_PORTRAIT="&#xe962;",t.DIAGRAM_SUNBURST="&#xe963;",t.DIAGRAM_SANKEY="&#xe964;",t.COMMENT_QUESTION="&#xe965;",t.COMMENT_QUESTION_PLAIN="&#xe966;",t.MESSAGE_BOT="&#xe967;",t.CHART_SIMPLE="&#xe968;",t.BARS_PROGRESS="&#xe969;",t.BOOK_OPEN_GEAR="&#xe96a;",t.BOOK_OPEN_GEAR_SLASH="&#xe96b;",t.LINE_CHART="&#xe96c;",t.STACKED_CHART="&#xe96d;",t.CHART_BAR_STACKED="&#xe96e;",t.CHART_BAR_GROUPED="&#xe96f;",t.EYE_SLASH="&#xe970;",t.X_MARK="&#xe971;",t.EXPAND_WIDE="&#xe972;",t.PIP="&#xe973;",t.PIP_WIDE="&#xe974;",t.LIFE_RING="&#xe975;",t.GLOBE="&#xe976;",t.PIGGY_BANK="&#xe977;",t.EXTLINK_LIGHT="&#xe978;",t.CLONE="&#xe979;",t.CLONE_LINK_SIMPLE="&#xe97a;",t.CHART_BAR_NORMALIZED="&#xe97b;",t.CONSUMER="&#xe97c;",t.OCTAGON_XMARK="&#xe97d;",t.HOURGLASS_HALF="&#xe97e;",t.CLOCK="&#xe97f;",t.CLOCK_THREE="&#xe97f;",t.CALENDAR_DAY="&#xe980;",t.COMPUTER_MOUSE_MAGNIFYING_GLASS="&#xe981;",t.WAND_MAGIC_SPARKLES="&#xe982;",t.PAPER_PLANE="&#xe983;",t.CIRCLE_STOP="&#xe984;",t.ARROW_ROTATE_RIGHT="&#xe985;",t.ARROWS_ROTATE="&#xe986;",t.ALIGN_RIGHT="&#xe987;",t.FORMAT_CLEAR="&#xe988;",t.ALIGN_CENTER="&#xe989;",t.ALIGN_LEFT="&#xe98a;",t.PALETTE="&#xe98b;",t.BOLD="&#xe98c;",t.ITALIC="&#xe98d;",t.UNDERLINE="&#xe98e;",t.STRIKETHROUGH="&#xe98f;",t.LINK_SIMPLE_SLASH="&#xe990;",t.LINK_SIMPLE="&#xe991;",t.ROUTE="&#xe992;",t.CIRCLE_USER_SLASH="&#xe993;",t.CIRCLE_USER_CHECK="&#xe994;",t.LIST_MAGNIFYING_GLASS="&#xe995;",t.MEDAL="&#xe996;",t.THUMBS_UP_THUMBS_DOWN_SOLID="&#xe997;",t.ARROW_TURN_DOWN_RIGHT="&#xe998;",t.FLASK="&#xe999;",t.LOCK_KEYHOLE_OPEN_SOLID="&#xe99a;",t.HOURGLASS_END="&#xe99b;",t.CIRCLE_QUESTION="&#xe99c;",t.GRIP_LINES_SOLID="&#xe99d;",t.TRANSLATE_SPARKLE_SOLID="&#xe99e;",t.CODE="&#xe99f;",t.ARROW_UP_RIGHT_AND_ARROW_DOWN_LEFT_FROM_CENTER="&#xe9a0;",t.PAPER_PLANE_SLASH="&#xe9a1;",t.COMPRESS="&#xe9a2;",t.EXPAND="&#xe9a3;",t.ARROW_ROTATE_LEFT="&#xe9a4;",t.EYE="&#xf06e;",t.SHARE="&#xe80f1;",t.MOBILE_SMALL="&#xe9a5;",t.SPARKLES="&#xe9a6;",t.HAND_SOLID="&#xe9a7;",t.CLOCK_SOLID="&#xe9a8;",t.CONTEXT_MENU_CURSOR="&#xe9a9;",t.LANGUAGE_SLASH="&#xe9aa;",t.MAGNIFYING_GLASS_FLOPPY_DISK="&#xe9ab;",t.CABINET_FILING_FLOPPY_DISK="&#xe9ac;",t.BOOKMARK_SLASH="&#xe9ad;",t.CIRCLE_PAUSE="&#xe9ae;",t.CIRCLE_PLAY="&#xe9af;",t.CIRCLE_STOP_PLAIN="&#xe9b0;",t.CLOUD_ARROW_DOWN="&#xe9b1;",t.SHARE_NODES="&#xe9b2;",t.BELL="&#xe9b3;",t.BELL_SLASH="&#xe9b4;",t.FILE="&#xe9b5;",t.HAND="&#xe9b6;",t.SQUARE_INFO_SOLID="&#xe9b7;"})(cn||(cn={}));var A;(function(t){t.UNKNOWN="&#xe90a;",t.ABW="&#xe900;",t.AUDIO="&#xe901;",t.AVI="&#xe902;",t.CHM="&#xe904;",t.CODE="&#xe905;",t.CSV="&#xe903;",t.DITA="&#xe906;",t.EPUB="&#xe907;",t.EXCEL="&#xe908;",t.FLAC="&#xe909;",t.GIF="&#xe90b;",t.GZIP="&#xe90c;",t.HTML="&#xe90d;",t.IMAGE="&#xe90e;",t.JPEG="&#xe90f;",t.JSON="&#xe910;",t.M4A="&#xe911;",t.MOV="&#xe912;",t.MP3="&#xe913;",t.MP4="&#xe914;",t.OGG="&#xe915;",t.PDF="&#xe916;",t.PNG="&#xe917;",t.POWERPOINT="&#xe918;",t.RAR="&#xe91a;",t.STP="&#xe91b;",t.TEXT="&#xe91c;",t.VIDEO="&#xe91e;",t.WAV="&#xe91f;",t.WMA="&#xe920;",t.WORD="&#xe921;",t.XML="&#xe922;",t.YAML="&#xe919;",t.ZIP="&#xe923;"})(A||(A={}));var yS=new Map([...["abw"].map(t=>[t,A.ABW]),...["3gp","act","aiff","aac","amr","au","awb","dct","dss","dvf","gsm","iklax","ivs","mmf","mpc","msv","opus","ra","rm","raw","sln","tta","vox","wv"].map(t=>[t,A.AUDIO]),...["avi"].map(t=>[t,A.AVI]),...["chm","xhs"].map(t=>[t,A.CHM]),...["java","py","php","php3","php4","php5","js","javascript","rb","rbw","c","cpp","cxx","h","hh","hpp","hxx","sh","bash","zsh","tcsh","ksh","csh","vb","scala","pl","prl","perl","groovy","ceylon","aspx","jsp","scpt","applescript","bas","bat","lua","jsp","mk","cmake","css","sass","less","m","mm","xcodeproj"].map(t=>[t,A.CODE]),...["csv"].map(t=>[t,A.CSV]),...["dita","ditamap","ditaval"].map(t=>[t,A.DITA]),...["epub"].map(t=>[t,A.EPUB]),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map(t=>[t,A.EXCEL]),...["flac"].map(t=>[t,A.FLAC]),...["gif"].map(t=>[t,A.GIF]),...["gzip","x-gzip","giz","gz","tgz"].map(t=>[t,A.GZIP]),...["html","htm","xhtml"].map(t=>[t,A.HTML]),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf","ico"].map(t=>[t,A.IMAGE]),...["jpeg","jpg","jpe"].map(t=>[t,A.JPEG]),...["json"].map(t=>[t,A.JSON]),...["m4a","m4p"].map(t=>[t,A.M4A]),...["mov","qt"].map(t=>[t,A.MOV]),...["mp3"].map(t=>[t,A.MP3]),...["mp4","m4v"].map(t=>[t,A.MP4]),...["ogg","oga"].map(t=>[t,A.OGG]),...["pdf","ps"].map(t=>[t,A.PDF]),...["png"].map(t=>[t,A.PNG]),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map(t=>[t,A.POWERPOINT]),...["rar"].map(t=>[t,A.RAR]),...["stp"].map(t=>[t,A.STP]),...["txt","rtf","md","mdown"].map(t=>[t,A.TEXT]),...["webm","mkv","flv","vob","ogv","ogg","drc","mng","wmv","yuv","rm","rmvb","asf","mpg","mp2","mpeg","mpe","mpv","m2v","svi","3gp","3g2","mxf","roq","nsv"].map(t=>[t,A.VIDEO]),...["wav"].map(t=>[t,A.WAV]),...["wma"].map(t=>[t,A.WMA]),...["doc","dot","docx","docm","dotx","dotm","docb"].map(t=>[t,A.WORD]),...["xml","xsl","rdf"].map(t=>[t,A.XML]),...["yaml","yml","x-yaml"].map(t=>[t,A.YAML]),...["zip"].map(t=>[t,A.ZIP])]);var mS={[A.ABW]:"#91ABC6",[A.AUDIO]:"#1795E3",[A.AVI]:"#E63324",[A.CHM]:"#71C3EB",[A.CODE]:"#71C3EB",[A.CSV]:"#1F7345",[A.DITA]:"#71C3EB",[A.EPUB]:"#85B926",[A.EXCEL]:"#1F7345",[A.FLAC]:"#1795E3",[A.GIF]:"#59B031",[A.GZIP]:"#F8AB36",[A.HTML]:"#71C3EB",[A.IMAGE]:"#59B031",[A.JPEG]:"#59B031",[A.JSON]:"#71C3EB",[A.M4A]:"#1795E3",[A.MOV]:"#E63324",[A.MP3]:"#1795E3",[A.MP4]:"#E63324",[A.OGG]:"#1795E3",[A.PDF]:"#E44948",[A.PNG]:"#59B031",[A.POWERPOINT]:"#B54A2B",[A.RAR]:"#F8AB36",[A.STP]:"#3764B1",[A.TEXT]:"#3162AB",[A.UNKNOWN]:"#999999",[A.VIDEO]:"#E63324",[A.WAV]:"#1795E3",[A.WMA]:"#1795E3",[A.WORD]:"#3162AB",[A.XML]:"#71C3EB",[A.YAML]:"#71C3EB",[A.ZIP]:"#F8AB36"};var dt;(function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"})(dt||(dt={}));var co=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(l=t[c])&&(a=(i<3?l(a):i>3?l(e,o,a):l(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},we=class extends Pc.FtLitElement{constructor(){super(...arguments),this.ariaHidden="true",this.resolvedIcon=lo.nothing}render(){let e=this.variant&&Object.values(dt).includes(this.variant)?this.variant:dt.fluid_topics,o=e!==dt.material||!!this.value;return lo.html`
565
+ `}setupFor(e){this.eventsTarget!==e&&(this.removeHandlers(),this.eventsTarget=e,this.eventsTarget.addEventListener("mouseenter",this.onHover,{passive:!0}),this.eventsTarget.addEventListener("mouseleave",this.onOut,{passive:!0}),this.eventsTarget.addEventListener("focusin",this.onFocusIn,{passive:!0}),this.eventsTarget.addEventListener("focusout",this.onOut,{passive:!0}),this.eventsTarget.addEventListener("touchstart",this.onTouch,{passive:!0}),this.eventsTarget.addEventListener("click",this.onClick,{passive:!0}))}removeHandlers(){this.eventsTarget&&(this.eventsTarget.removeEventListener("mouseenter",this.onHover),this.eventsTarget.removeEventListener("mouseleave",this.onOut),this.eventsTarget.removeEventListener("focusin",this.onFocusIn),this.eventsTarget.removeEventListener("focusout",this.onOut),this.eventsTarget.removeEventListener("touchstart",this.onTouch),this.eventsTarget.removeEventListener("click",this.onClick),this.eventsTarget=void 0)}defaultSetup(){this.container&&this.setupFor(this.container)}updated(e){e.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(e)}contentAvailableCallback(e){super.contentAvailableCallback(e),["visible","text"].some(o=>e.has(o))&&this.visible&&this.positionTooltip()}connectedCallback(){super.connectedCallback(),this.updateComplete.then(()=>{this.eventsTarget==null&&this.defaultSetup()})}disconnectedCallback(){super.disconnectedCallback(),this.removeHandlers()}async show(e){this.visible=!0,e!=null&&await this.hideDebounce.run(()=>{this.hide()},e)}async showTemporaryText(e,o){let n=this.manual;this.manual=!0;let i=this.text;this.text={message:e},await this.show(o),this.text=i,this.manual=n}hide(){this.visible=!1}toggle(){this.visible=!this.visible}isVisible(){return this.visible}get slottedElement(){var e;return((e=this.slotNodes)!==null&&e!==void 0?e:[]).filter(o=>o.nodeType==Node.ELEMENT_NODE)[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){let e=this.tooltipContent.style;switch(e.transition="none",this.validPosition){case"top":e.top=this.tooltip.clientHeight+"px",e.left="0";break;case"bottom":e.top=-this.tooltip.clientHeight+"px",e.left="0";break;case"left":e.top="0",e.left=this.tooltip.clientWidth+"px";break;case"right":e.top="0",e.left=-this.tooltip.clientWidth+"px";break}}}positionTooltip(){this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",Ds(this.slottedElement,this.tooltip,this.position).then(({x:e,y:o})=>{this.tooltip&&(this.tooltip.style.left=`${e}px`,this.tooltip.style.top=`${o}px`)})),this.revealDebouncer.run(()=>{this.tooltipContent&&(this.tooltipContent.style.transition=`top ${We.designSystemVariables.transitionDuration}, left ${We.designSystemVariables.transitionDuration}`,this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")},this.manual?0:this.delay)}isIgnored(e){return this.manual||(0,We.eventPathContainsMatchingElement)(e,this.ignoreMatchingElements,this.eventsTarget)}};le.elementDefinitions={"ft-typography":re};le.styles=ds;Qe([wc()],le.prototype,"text",void 0);Qe([(0,Ge.property)({type:Boolean})],le.prototype,"manual",void 0);Qe([(0,Ge.property)({type:Boolean})],le.prototype,"inline",void 0);Qe([(0,We.numberProperty)()],le.prototype,"delay",void 0);Qe([(0,Ge.property)()],le.prototype,"position",void 0);Qe([(0,We.jsonProperty)([])],le.prototype,"ignoreMatchingElements",void 0);Qe([(0,Ge.queryAssignedNodes)()],le.prototype,"slotNodes",void 0);Qe([(0,Ge.query)(".ft-tooltip--container")],le.prototype,"container",void 0);Qe([(0,Ge.query)(".ft-tooltip")],le.prototype,"tooltip",void 0);Qe([(0,Ge.query)(".ft-tooltip--content")],le.prototype,"tooltipContent",void 0);Qe([(0,Ge.state)()],le.prototype,"visible",void 0);(0,Ic.customElement)("ft-tooltip")(le);var Bc=b(L());var lo=b(M()),Pt=b(ee()),Pc=b(L()),Dc=b(kc());var cn;(function(t){t.ADD_TO_PBK="&#xe800;",t.ALERT="&#xe801;",t.ADD_ALERT="&#xe802;",t.BACK_TO_SEARCH="&#xe803;",t.ADD_BOOKMARK="&#xe804;",t.BOOKMARK="&#xe805;",t.BOOKS="&#xe806;",t.MENU="&#xe807;",t.DOWNLOAD="&#xe808;",t.EDIT="&#xe809;",t.FEEDBACK="&#xe80a;",t.HOME="&#xe80b;",t.MODIFY_PBK="&#xe80c;",t.SCHEDULED="&#xe80d;",t.SEARCH="&#xe80e;",t.EXPORT="&#xe80f;",t.TOC="&#xe810;",t.WRITE_UGC="&#xe811;",t.TRASH="&#xe812;",t.USER="&#xe813;",t.EXTLINK="&#xe814;",t.CALENDAR="&#xe815;",t.OFFLINE="&#xe816;",t.BOOK="&#xe817;",t.DOWNLOAD_PLAIN="&#xe818;",t.CHECK="&#xe819;",t.STAR_PLAIN="&#xe900;",t.TOPICS="&#xe901;",t.DISC="&#xe902;",t.CIRCLE="&#xe903;",t.SHARED="&#xe904;",t.SORT_UNSORTED="&#xe905;",t.SORT_UP="&#xe906;",t.SORT_DOWN="&#xe907;",t.WORKING="&#xe908;",t.CLOSE="&#xe909;",t.ZOOM_OUT="&#xe90a;",t.ZOOM_IN="&#xe90b;",t.ZOOM_REALSIZE="&#xe90c;",t.ZOOM_FULLSCREEN="&#xe90d;",t.ADMIN_RESTRICTED="&#xe90e;",t.ADMIN="&#xe90f;",t.ADMIN_KHUB="&#xe910;",t.ADMIN_THEME="&#xe911;",t.ADMIN_USERS="&#xe912;",t.WARNING="&#xe913;",t.CONTEXT="&#xe914;",t.SEARCH_HOME="&#xe915;",t.STEPS="&#xe916;",t.ICON_EXPAND="&#xe917;",t.ICON_COLLAPSE="&#xe918;",t.INFO="&#xe919;",t.MINUS_PLAIN="&#xe91a;",t.PLUS_PLAIN="&#xe91b;",t.FACET_HAS_DESCENDANT="&#xe91c;",t.TRIANGLE_BOTTOM="&#xe91d;",t.TRIANGLE_LEFT="&#xe91e;",t.TRIANGLE_RIGHT="&#xe91f;",t.TRIANGLE_TOP="&#xe920;",t.THIN_ARROW="&#xe921;",t.SIGN_IN="&#xe922;",t.LOGOUT="&#xe923;",t.TRANSLATE="&#xe924;",t.CLOSE_PLAIN="&#xe925;",t.CHECK_PLAIN="&#xe926;",t.ARTICLE="&#xe927;",t.COLUMNS="&#xe928;",t.ANALYTICS="&#xe929;",t.COLLECTIONS="&#xe92a;",t.ARROW_DOWN="&#xe92b;",t.ARROW_LEFT="&#xe92c;",t.ARROW_RIGHT="&#xe92d;",t.ARROW_UP="&#xe92e;",t.SEARCH_IN_PUBLICATION="&#xe92f;",t.COPY_TO_CLIPBOARD="&#xe930;",t.SHARED_PBK="&#xe931;",t.ATTACHMENTS="&#xe932;",t.STRIPE_ARROW_LEFT="&#xe933;",t.STRIPE_ARROW_RIGHT="&#xe934;",t.FILTERS="&#xe935;",t.DOT="&#xe936;",t.MINUS="&#xe937;",t.PLUS="&#xe938;",t.MAILS_AND_NOTIFICATIONS="&#xe939;",t.SAVE="&#xe93a;",t.LOCKER="&#xe93b;",t.ADMIN_INTEGRATION="&#xe93c;",t.SYNC="&#xe93d;",t.TAG="&#xe93e;",t.BOOK_PLAIN="&#xe93f;",t.UPLOAD="&#xe940;",t.ONLINE="&#xe941;",t.TAG_PLAIN="&#xe942;",t.ACCOUNT_SETTINGS="&#xe943;",t.PRINT="&#xe944;",t.DEFAULT_ROLES="&#xe945;",t.SHORTCUT_MENU="&#xe946;",t.RELATIVES_PLAIN="&#xe947;",t.RELATIVES="&#xe948;",t.PAUSE="&#xe949;",t.PLAY="&#xe94a;",t.ADMIN_PORTAL="&#xe94b;",t.STAR="&#xe94c;",t.THUMBS_DOWN="&#xe94d;",t.THUMBS_DOWN_PLAIN="&#xe94e;",t.THUMBS_UP="&#xe94f;",t.THUMBS_UP_PLAIN="&#xe950;",t.FEEDBACK_PLAIN="&#xe951;",t.RATE_PLAIN="&#xe952;",t.RATE="&#xe953;",t.OFFLINE_SETTINGS="&#xe954;",t.MY_COLLECTIONS="&#xe955;",t.THIN_ARROW_LEFT="&#xe956;",t.THIN_ARROW_RIGHT="&#xe957;",t.RESET="&#xe958;",t.MY_LIBRARY="&#xe959;",t.UNSTRUCTURED_DOC="&#xe95a;",t.CONTEXTUAL="&#xe95b;",t.THIN_ARROW_UP="&#xe95c;",t.ARROW_RIGHT_TO_LINE="&#xe95d;",t.DESKTOP="&#xe95e;",t.TABLET_LANDSCAPE="&#xe95f;",t.TABLET_PORTRAIT="&#xe960;",t.MOBILE_LANDSCAPE="&#xe961;",t.MOBILE_PORTRAIT="&#xe962;",t.DIAGRAM_SUNBURST="&#xe963;",t.DIAGRAM_SANKEY="&#xe964;",t.COMMENT_QUESTION="&#xe965;",t.COMMENT_QUESTION_PLAIN="&#xe966;",t.MESSAGE_BOT="&#xe967;",t.CHART_SIMPLE="&#xe968;",t.BARS_PROGRESS="&#xe969;",t.BOOK_OPEN_GEAR="&#xe96a;",t.BOOK_OPEN_GEAR_SLASH="&#xe96b;",t.LINE_CHART="&#xe96c;",t.STACKED_CHART="&#xe96d;",t.CHART_BAR_STACKED="&#xe96e;",t.CHART_BAR_GROUPED="&#xe96f;",t.EYE_SLASH="&#xe970;",t.X_MARK="&#xe971;",t.EXPAND_WIDE="&#xe972;",t.PIP="&#xe973;",t.PIP_WIDE="&#xe974;",t.LIFE_RING="&#xe975;",t.GLOBE="&#xe976;",t.PIGGY_BANK="&#xe977;",t.EXTLINK_LIGHT="&#xe978;",t.CLONE="&#xe979;",t.CLONE_LINK_SIMPLE="&#xe97a;",t.CHART_BAR_NORMALIZED="&#xe97b;",t.CONSUMER="&#xe97c;",t.OCTAGON_XMARK="&#xe97d;",t.HOURGLASS_HALF="&#xe97e;",t.CLOCK="&#xe97f;",t.CLOCK_THREE="&#xe97f;",t.CALENDAR_DAY="&#xe980;",t.COMPUTER_MOUSE_MAGNIFYING_GLASS="&#xe981;",t.WAND_MAGIC_SPARKLES="&#xe982;",t.PAPER_PLANE="&#xe983;",t.CIRCLE_STOP="&#xe984;",t.ARROW_ROTATE_RIGHT="&#xe985;",t.ARROWS_ROTATE="&#xe986;",t.ALIGN_RIGHT="&#xe987;",t.FORMAT_CLEAR="&#xe988;",t.ALIGN_CENTER="&#xe989;",t.ALIGN_LEFT="&#xe98a;",t.PALETTE="&#xe98b;",t.BOLD="&#xe98c;",t.ITALIC="&#xe98d;",t.UNDERLINE="&#xe98e;",t.STRIKETHROUGH="&#xe98f;",t.LINK_SIMPLE_SLASH="&#xe990;",t.LINK_SIMPLE="&#xe991;",t.ROUTE="&#xe992;",t.CIRCLE_USER_SLASH="&#xe993;",t.CIRCLE_USER_CHECK="&#xe994;",t.LIST_MAGNIFYING_GLASS="&#xe995;",t.MEDAL="&#xe996;",t.THUMBS_UP_THUMBS_DOWN_SOLID="&#xe997;",t.ARROW_TURN_DOWN_RIGHT="&#xe998;",t.FLASK="&#xe999;",t.LOCK_KEYHOLE_OPEN_SOLID="&#xe99a;",t.HOURGLASS_END="&#xe99b;",t.CIRCLE_QUESTION="&#xe99c;",t.GRIP_LINES_SOLID="&#xe99d;",t.TRANSLATE_SPARKLE_SOLID="&#xe99e;",t.CODE="&#xe99f;",t.ARROW_UP_RIGHT_AND_ARROW_DOWN_LEFT_FROM_CENTER="&#xe9a0;",t.PAPER_PLANE_SLASH="&#xe9a1;",t.COMPRESS="&#xe9a2;",t.EXPAND="&#xe9a3;",t.ARROW_ROTATE_LEFT="&#xe9a4;",t.EYE="&#xf06e;",t.SHARE="&#xe80f1;",t.MOBILE_SMALL="&#xe9a5;",t.SPARKLES="&#xe9a6;",t.HAND_SOLID="&#xe9a7;",t.CLOCK_SOLID="&#xe9a8;",t.CONTEXT_MENU_CURSOR="&#xe9a9;",t.LANGUAGE_SLASH="&#xe9aa;",t.MAGNIFYING_GLASS_FLOPPY_DISK="&#xe9ab;",t.CABINET_FILING_FLOPPY_DISK="&#xe9ac;",t.BOOKMARK_SLASH="&#xe9ad;",t.CIRCLE_PAUSE="&#xe9ae;",t.CIRCLE_PLAY="&#xe9af;",t.CIRCLE_STOP_PLAIN="&#xe9b0;",t.CLOUD_ARROW_DOWN="&#xe9b1;",t.SHARE_NODES="&#xe9b2;",t.BELL="&#xe9b3;",t.BELL_SLASH="&#xe9b4;",t.FILE="&#xe9b5;",t.HAND="&#xe9b6;",t.SQUARE_INFO_SOLID="&#xe9b7;",t.FILE_CODE="&#xe9b8;",t.BOX_CODE="&#xe9b9;"})(cn||(cn={}));var A;(function(t){t.UNKNOWN="&#xe90a;",t.ABW="&#xe900;",t.AUDIO="&#xe901;",t.AVI="&#xe902;",t.CHM="&#xe904;",t.CODE="&#xe905;",t.CSV="&#xe903;",t.DITA="&#xe906;",t.EPUB="&#xe907;",t.EXCEL="&#xe908;",t.FLAC="&#xe909;",t.GIF="&#xe90b;",t.GZIP="&#xe90c;",t.HTML="&#xe90d;",t.IMAGE="&#xe90e;",t.JPEG="&#xe90f;",t.JSON="&#xe910;",t.M4A="&#xe911;",t.MOV="&#xe912;",t.MP3="&#xe913;",t.MP4="&#xe914;",t.OGG="&#xe915;",t.PDF="&#xe916;",t.PNG="&#xe917;",t.POWERPOINT="&#xe918;",t.RAR="&#xe91a;",t.STP="&#xe91b;",t.TEXT="&#xe91c;",t.VIDEO="&#xe91e;",t.WAV="&#xe91f;",t.WMA="&#xe920;",t.WORD="&#xe921;",t.XML="&#xe922;",t.YAML="&#xe919;",t.ZIP="&#xe923;"})(A||(A={}));var yS=new Map([...["abw"].map(t=>[t,A.ABW]),...["3gp","act","aiff","aac","amr","au","awb","dct","dss","dvf","gsm","iklax","ivs","mmf","mpc","msv","opus","ra","rm","raw","sln","tta","vox","wv"].map(t=>[t,A.AUDIO]),...["avi"].map(t=>[t,A.AVI]),...["chm","xhs"].map(t=>[t,A.CHM]),...["java","py","php","php3","php4","php5","js","javascript","rb","rbw","c","cpp","cxx","h","hh","hpp","hxx","sh","bash","zsh","tcsh","ksh","csh","vb","scala","pl","prl","perl","groovy","ceylon","aspx","jsp","scpt","applescript","bas","bat","lua","jsp","mk","cmake","css","sass","less","m","mm","xcodeproj"].map(t=>[t,A.CODE]),...["csv"].map(t=>[t,A.CSV]),...["dita","ditamap","ditaval"].map(t=>[t,A.DITA]),...["epub"].map(t=>[t,A.EPUB]),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map(t=>[t,A.EXCEL]),...["flac"].map(t=>[t,A.FLAC]),...["gif"].map(t=>[t,A.GIF]),...["gzip","x-gzip","giz","gz","tgz"].map(t=>[t,A.GZIP]),...["html","htm","xhtml"].map(t=>[t,A.HTML]),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf","ico"].map(t=>[t,A.IMAGE]),...["jpeg","jpg","jpe"].map(t=>[t,A.JPEG]),...["json"].map(t=>[t,A.JSON]),...["m4a","m4p"].map(t=>[t,A.M4A]),...["mov","qt"].map(t=>[t,A.MOV]),...["mp3"].map(t=>[t,A.MP3]),...["mp4","m4v"].map(t=>[t,A.MP4]),...["ogg","oga"].map(t=>[t,A.OGG]),...["pdf","ps"].map(t=>[t,A.PDF]),...["png"].map(t=>[t,A.PNG]),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map(t=>[t,A.POWERPOINT]),...["rar"].map(t=>[t,A.RAR]),...["stp"].map(t=>[t,A.STP]),...["txt","rtf","md","mdown"].map(t=>[t,A.TEXT]),...["webm","mkv","flv","vob","ogv","ogg","drc","mng","wmv","yuv","rm","rmvb","asf","mpg","mp2","mpeg","mpe","mpv","m2v","svi","3gp","3g2","mxf","roq","nsv"].map(t=>[t,A.VIDEO]),...["wav"].map(t=>[t,A.WAV]),...["wma"].map(t=>[t,A.WMA]),...["doc","dot","docx","docm","dotx","dotm","docb"].map(t=>[t,A.WORD]),...["xml","xsl","rdf"].map(t=>[t,A.XML]),...["yaml","yml","x-yaml"].map(t=>[t,A.YAML]),...["zip"].map(t=>[t,A.ZIP])]);var mS={[A.ABW]:"#91ABC6",[A.AUDIO]:"#1795E3",[A.AVI]:"#E63324",[A.CHM]:"#71C3EB",[A.CODE]:"#71C3EB",[A.CSV]:"#1F7345",[A.DITA]:"#71C3EB",[A.EPUB]:"#85B926",[A.EXCEL]:"#1F7345",[A.FLAC]:"#1795E3",[A.GIF]:"#59B031",[A.GZIP]:"#F8AB36",[A.HTML]:"#71C3EB",[A.IMAGE]:"#59B031",[A.JPEG]:"#59B031",[A.JSON]:"#71C3EB",[A.M4A]:"#1795E3",[A.MOV]:"#E63324",[A.MP3]:"#1795E3",[A.MP4]:"#E63324",[A.OGG]:"#1795E3",[A.PDF]:"#E44948",[A.PNG]:"#59B031",[A.POWERPOINT]:"#B54A2B",[A.RAR]:"#F8AB36",[A.STP]:"#3764B1",[A.TEXT]:"#3162AB",[A.UNKNOWN]:"#999999",[A.VIDEO]:"#E63324",[A.WAV]:"#1795E3",[A.WMA]:"#1795E3",[A.WORD]:"#3162AB",[A.XML]:"#71C3EB",[A.YAML]:"#71C3EB",[A.ZIP]:"#F8AB36"};var dt;(function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"})(dt||(dt={}));var co=function(t,e,o,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,o):n,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(t,e,o,n);else for(var c=t.length-1;c>=0;c--)(l=t[c])&&(a=(i<3?l(a):i>3?l(e,o,a):l(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},we=class extends Pc.FtLitElement{constructor(){super(...arguments),this.ariaHidden="true",this.resolvedIcon=lo.nothing}render(){let e=this.variant&&Object.values(dt).includes(this.variant)?this.variant:dt.fluid_topics,o=e!==dt.material||!!this.value;return lo.html`
566
566
  <i class="ft-icon ft-icon--${e} ft-no-text-select" part="icon icon-${e}">
567
567
  ${(0,Dc.unsafeHTML)(this.resolvedIcon)}
568
568
  <slot ?hidden=${o}></slot>