@fluid-topics/ft-viewer 2.2.5 → 2.2.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,9 +1,9 @@
1
- "use strict";(()=>{var ih=Object.create;var ll=Object.defineProperty;var rh=Object.getOwnPropertyDescriptor;var nh=Object.getOwnPropertyNames;var oh=Object.getPrototypeOf,sh=Object.prototype.hasOwnProperty;var Qi=(t,e)=>()=>{try{return e||t((e={exports:{}}).exports,e),e.exports}catch(i){throw e=0,i}};var ah=(t,e,i,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of nh(e))!sh.call(t,n)&&n!==i&&ll(t,n,{get:()=>e[n],enumerable:!(r=rh(e,n))||r.enumerable});return t};var c=(t,e,i)=>(i=t!=null?ih(oh(t)):{},ah(e||!t||!t.__esModule?ll(i,"default",{value:t,enumerable:!0}):i,t));var h=Qi((eg,cl)=>{cl.exports=ftGlobals.wcUtils});var U=Qi((tg,dl)=>{dl.exports=ftGlobals.litDecorators});var x=Qi((Cg,hl)=>{hl.exports=ftGlobals.lit});var fr=Qi((fx,xd)=>{xd.exports=ftGlobals.litRepeat});var Ia=Qi((Kx,tu)=>{tu.exports=ftGlobals.litUnsafeHTML});var rt=Qi((oE,Ru)=>{Ru.exports=ftGlobals.litClassMap});var Qf=c(h());var pl=c(h()),fl=c(U());var Kt=class extends Event{constructor(e,i,r,n){super("context-request",{bubbles:!0,composed:!0}),this.context=e,this.contextTarget=i,this.callback=r,this.subscribe=n??!1}};var er=class{constructor(e,i,r,n){if(this.subscribe=!1,this.provided=!1,this.value=void 0,this.t=(o,s)=>{this.unsubscribe&&(this.unsubscribe!==s&&(this.provided=!1,this.unsubscribe()),this.subscribe||this.unsubscribe()),this.value=o,this.host.requestUpdate(),this.provided&&!this.subscribe||(this.provided=!0,this.callback&&this.callback(o,s)),this.unsubscribe=s},this.host=e,i.context!==void 0){let o=i;this.context=o.context,this.callback=o.callback,this.subscribe=o.subscribe??!1}else this.context=i,this.callback=r,this.subscribe=n??!1;this.host.addController(this)}hostConnected(){this.dispatchRequest()}hostDisconnected(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=void 0)}dispatchRequest(){this.host.dispatchEvent(new Kt(this.context,this.host,this.t,this.subscribe))}};var Dn=class{get value(){return this.o}set value(e){this.setValue(e)}setValue(e,i=!1){let r=i||!Object.is(e,this.o);this.o=e,r&&this.updateObservers()}constructor(e){this.subscriptions=new Map,this.updateObservers=()=>{for(let[i,{disposer:r}]of this.subscriptions)i(this.o,r)},e!==void 0&&(this.value=e)}addCallback(e,i,r){if(!r)return void e(this.value);this.subscriptions.has(e)||this.subscriptions.set(e,{disposer:()=>{this.subscriptions.delete(e)},consumerHost:i});let{disposer:n}=this.subscriptions.get(e);e(this.value,n)}clearCallbacks(){this.subscriptions.clear()}};var Vs=class extends Event{constructor(e,i){super("context-provider",{bubbles:!0,composed:!0}),this.context=e,this.contextTarget=i}},tr=class extends Dn{constructor(e,i,r){super(i.context!==void 0?i.initialValue:r),this.onContextRequest=n=>{if(n.context!==this.context)return;let o=n.contextTarget??n.composedPath()[0];o!==this.host&&(n.stopPropagation(),this.addCallback(n.callback,o,n.subscribe))},this.onProviderRequest=n=>{if(n.context!==this.context||(n.contextTarget??n.composedPath()[0])===this.host)return;let o=new Set;for(let[s,{consumerHost:a}]of this.subscriptions)o.has(s)||(o.add(s),a.dispatchEvent(new Kt(this.context,a,s,!0)));n.stopPropagation()},this.host=e,i.context!==void 0?this.context=i.context:this.context=i,this.attachListeners(),this.host.addController?.(this)}attachListeners(){this.host.addEventListener("context-request",this.onContextRequest),this.host.addEventListener("context-provider",this.onProviderRequest)}hostConnected(){this.host.dispatchEvent(new Vs(this.context,this.host))}};var zr=class{constructor(){this.pendingContextRequests=new Map,this.onContextProvider=e=>{let i=this.pendingContextRequests.get(e.context);if(i===void 0)return;this.pendingContextRequests.delete(e.context);let{requests:r}=i;for(let{elementRef:n,callbackRef:o}of r){let s=n.deref(),a=o.deref();s===void 0||a===void 0||s.dispatchEvent(new Kt(e.context,s,a,!0))}},this.onContextRequest=e=>{if(e.subscribe!==!0)return;let i=e.contextTarget??e.composedPath()[0],r=e.callback,n=this.pendingContextRequests.get(e.context);n===void 0&&this.pendingContextRequests.set(e.context,n={callbacks:new WeakMap,requests:[]});let o=n.callbacks.get(i);o===void 0&&n.callbacks.set(i,o=new WeakSet),o.has(r)||(o.add(r),n.requests.push({elementRef:new WeakRef(i),callbackRef:new WeakRef(r)}))}}attach(e){e.addEventListener("context-request",this.onContextRequest),e.addEventListener("context-provider",this.onContextProvider)}detach(e){e.removeEventListener("context-request",this.onContextRequest),e.removeEventListener("context-provider",this.onContextProvider)}};function jr({context:t}){return(e,i)=>{let r=new WeakMap;if(typeof i=="object")return{get(){return e.get.call(this)},set(n){return r.get(this).setValue(n),e.set.call(this,n)},init(n){return r.set(this,new tr(this,{context:t,initialValue:n})),n}};{e.constructor.addInitializer((s=>{r.set(s,new tr(s,{context:t}))}));let n=Object.getOwnPropertyDescriptor(e,i),o;if(n===void 0){let s=new WeakMap;o={get(){return s.get(this)},set(a){r.get(this).setValue(a),s.set(this,a)},configurable:!0,enumerable:!0}}else{let s=n.set;o={...n,set(a){r.get(this).setValue(a),s?.call(this,a)}}}return void Object.defineProperty(e,i,o)}}}function Wr({context:t,subscribe:e}){return(i,r)=>{typeof r=="object"?r.addInitializer((function(){new er(this,{context:t,callback:n=>{i.set.call(this,n)},subscribe:e})})):i.constructor.addInitializer((n=>{new er(n,{context:t,callback:o=>{n[r]=o},subscribe:e})}))}}var lh=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Bs=Symbol("asset-viewer-state-manager"),Nt=(0,pl.applyMixinOnce)(Symbol("toFtAssetViewerComponent"),function(t){class e extends t{willUpdate(r){super.willUpdate(r),r.has("viewerStateManager")&&(this.viewerStateManager?this.addStore(this.viewerStateManager.store,"viewer"):this.removeStore("viewer"))}connectedCallback(){super.connectedCallback(),this.viewerStateManager&&this.addStore(this.viewerStateManager.store,"viewer")}disconnectedCallback(){super.disconnectedCallback(),this.removeStore("viewer")}}return lh([Wr({context:Bs,subscribe:!0}),(0,fl.state)()],e.prototype,"viewerStateManager",void 0),e});var md=c(x()),pr=c(h());var ml=c(h()),ch={setZoom:(t,e)=>{t.contentModifiers.zoom=e.payload},setRotation:(t,e)=>{t.contentModifiers.rotation=e.payload}},In=t=>ml.FtReduxStore.get({name:"ft-viewer-"+t,initialState:{documentId:void 0,unstructuredDocument:void 0,document:void 0,assetId:void 0,origin:void 0,descriptor:void 0,contentModifiers:{zoom:void 0,rotation:0},watermark:void 0,configuration:void 0,documentRating:void 0,assetRating:void 0,relatives:void 0},reducers:ch});var gl=c(h()),ir=class extends gl.FtStateManager{constructor(e){super(),this.store=e}setZoom(e){this.store.actions.setZoom(e)}setRotation(e){this.store.actions.setRotation(e)}};var ca=c(U());var yl=c(U(),1);var Hs=t=>e=>{window.customElements.get(t)||window.customElements.define(t,e)};function vl(t,e){return(0,yl.property)({type:Object,converter:{fromAttribute:i=>{if(i==null)return Kr(t);try{return JSON.parse(i)}catch{return Kr(t)}},toAttribute:i=>JSON.stringify(i)},hasChanged:Gr,...e??{}})}function dh(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;let i,r;if(Array.isArray(t)){if(i=t.length,i!=e.length)return!1;for(r=i;r--!==0;)if(!rr(t[r],e[r]))return!1;return!0}if(t instanceof Map&&e instanceof Map){if(t.size!==e.size)return!1;for(r of t.entries())if(!e.has(r[0]))return!1;for(r of t.entries())if(!rr(r[1],e.get(r[0])))return!1;return!0}if(t instanceof Set&&e instanceof Set){if(t.size!==e.size)return!1;for(r of t.entries())if(!e.has(r[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 n=s=>Object.keys(s).filter(a=>s[a]!=null),o=n(t);if(i=o.length,i!==n(e).length)return!1;for(r=i;r--!==0;)if(!Object.prototype.hasOwnProperty.call(e,o[r]))return!1;for(r=i;r--!==0;){let s=o[r];if(!rr(t[s],e[s]))return!1}return!0}return t!==t&&e!==e||t==null&&e==null}function rr(t,e){try{return dh(t,e)}catch{return!1}}function Gr(t,e){return!rr(t,e)}function Kr(t){return typeof window.structuredClone=="function"?structuredClone(t):t!=null?JSON.parse(JSON.stringify(t)):t}function Mn(t,e){let i=r=>r[t]===!0;return r=>{if(i(r))return r;let n=e(r);return n[t]=!0,n}}var bl=c(U(),1);var zs=t=>{let e=t??{};return(i,r)=>{var n;let o={hasChanged:Gr,attribute:!1,...e};(0,bl.property)(o)(i,r);let s=i.constructor;s.reduxProperties=new Map(s.reduxProperties),s.reduxProperties.set(r,{selector:(n=e.selector)!==null&&n!==void 0?n:(a=>a[r]),store:e.store})}};var Pn=class{constructor(){this.queue=[]}add(e,i=!1){i&&this.clear(e.type),this.queue.push(e)}consume(e){let i=this.queue.find(r=>r.type===e);return i&&(this.queue=this.queue.filter(r=>r!==i)),i}clear(e){typeof e=="string"?this.queue=this.queue.filter(i=>i.type!==e):this.queue=this.queue.filter(i=>!e.test(i.type))}};var _i=c(U(),1);var Nn=class{constructor(e=0){this.timeout=e,this.callbacks=[]}run(e,i){return this.callbacks=[e],this.debounce(i)}queue(e,i){return this.callbacks.push(e),this.debounce(i)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(e){return this.promise==null&&(this.promise=new Promise((i,r)=>{this.resolvePromise=i,this.rejectPromise=r})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),e??this.timeout),this.promise}async runCallbacks(){var e,i;let r=[...this.callbacks];this.callbacks=[];let n=(e=this.rejectPromise)!==null&&e!==void 0?e:(()=>null),o=(i=this.resolvePromise)!==null&&i!==void 0?i:(()=>null);this.clearPromise();for(let s of r)try{await s()}catch(a){n(a);return}o(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var Sl=c(x(),1);var $n=globalThis,uh=$n.ShadowRoot&&($n.ShadyCSS===void 0||$n.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype;var xl=(t,e)=>{if(uh)t.adoptedStyleSheets=e.map(i=>i instanceof CSSStyleSheet?i:i.styleSheet);else for(let i of e){let r=document.createElement("style"),n=$n.litNonce;n!==void 0&&r.setAttribute("nonce",n),r.textContent=i.cssText,t.appendChild(r)}};var Un=class extends Sl.LitElement{get scopedRegistryConstructor(){return this.constructor}createRenderRoot(){let e=this.scopedRegistryConstructor;e.elementDefinitions&&!e.registry&&(e.registry=new CustomElementRegistry,e.defineScopedElements(e.elementDefinitions));let i={...e.shadowRootOptions,customElements:e.registry},r=this.renderOptions.creationScope=this.attachShadow(i);return xl(r,e.elementStyles),r}static canDefineScopedElement(e){return!!this.registry&&!this.registry.get(e)}static defineScopedElements(e){Object.entries(e).forEach(([i,r])=>this.defineScopedElement(i,r))}static defineScopedElement(e,i){Hs(e)(i),this.canDefineScopedElement(e)&&this.registry.define(e,i)}canDefineScopedElement(e){return this.scopedRegistryConstructor.canDefineScopedElement(e)}defineScopedElements(e){this.scopedRegistryConstructor.defineScopedElements(e)}defineScopedElement(e,i){this.scopedRegistryConstructor.defineScopedElement(e,i)}};function wl(t,e,...i){var r;let n=t.querySelector(e);for(let o of i)n=(r=n?.shadowRoot)===null||r===void 0?void 0:r.querySelector(o);return n}var or=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Cl,El=Symbol("constructorPrototype"),_l=Symbol("constructorName"),Tl=Symbol("exportpartsDebouncer"),Al=Symbol("dynamicDependenciesLoaded"),nr=class t extends CustomEvent{constructor(){super(t.eventName,{bubbles:!0})}};nr.eventName="exportparts-updated";var $t=class extends Un{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[Cl]=new Nn(5),this.scheduleExportpartsUpdate=()=>{var e,i,r;(!((e=this.exportpartsPrefix)===null||e===void 0)&&e.trim()||(r=(i=this.exportpartsPrefixes)===null||i===void 0?void 0:i.length)!==null&&r!==void 0&&r)&&this[Tl].run(()=>{var n,o;!((n=this.exportpartsPrefix)===null||n===void 0)&&n.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((o=this.exportpartsPrefixes)===null||o===void 0?void 0:o.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})},this[_l]=this.constructor.name,this[El]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[_l]&&Object.setPrototypeOf(this,this[El])}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(r){this.useAdoptedStyleSheets=!1,console.error("Cannot use adopted stylesheets",r)}let i=this.constructor;i[Al]||(i[Al]=!0,this.importDynamicDependencies()),(e=this.shadowRoot)===null||e===void 0||e.addEventListener(nr.eventName,this.scheduleExportpartsUpdate)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.shadowRoot)===null||e===void 0||e.removeEventListener(nr.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 nr)})}contentAvailableCallback(e){}focusElementToFocus(e){if(e.has("elementToFocus")&&this.elementToFocus!=null){let{element:i,selector:r,shadowPath:n}=this.elementToFocus;if(r!=null){let o=[...n??[],r];i=wl(this.shadowRoot,...o)}i?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||i?.blur(),this.elementToFocus=void 0}}applyCustomStylesheet(e){var i,r,n;if(((r=(i=this.shadowRoot)===null||i===void 0?void 0:i.querySelectorAll(".ft-lit-element--custom-stylesheet"))!==null&&r!==void 0?r:[]).forEach(o=>o.remove()),this.useAdoptedStyleSheets){if(e.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((n=this.customStylesheet)!==null&&n!==void 0?n:"")}catch(o){console.error(o,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let o=document.createElement("style");o.classList.add("ft-lit-element--custom-stylesheet"),o.innerHTML=this.customStylesheet,this.shadowRoot.append(o)}}setExportpartsAttribute(e){var i,r,n,o,s,a;let l=f=>f!=null&&f.trim().length>0,d=e.filter(l).map(f=>f.trim());if(d.length===0){this.exportparts=void 0;return}let u=new Set;for(let f of(r=(i=this.shadowRoot)===null||i===void 0?void 0:i.querySelectorAll("[part],[exportparts]"))!==null&&r!==void 0?r:[]){let y=(o=(n=f.getAttribute("part"))===null||n===void 0?void 0:n.split(" "))!==null&&o!==void 0?o:[],S=(a=(s=f.getAttribute("exportparts"))===null||s===void 0?void 0:s.split(",").map(b=>b.split(":")[1]))!==null&&a!==void 0?a:[],T=[...y,...S].filter(l).map(b=>b.trim());for(let b of T)u.add(b)}if(u.size===0){this.exportparts=void 0;return}let p=[...u.values()].flatMap(f=>d.map(y=>`${f}:${y}--${f}`));this.exportparts=[...this.part,...p].join(", ")}};Cl=Tl;or([(0,_i.property)()],$t.prototype,"exportpartsPrefix",void 0);or([vl([])],$t.prototype,"exportpartsPrefixes",void 0);or([(0,_i.property)({reflect:!0})],$t.prototype,"exportparts",void 0);or([(0,_i.property)()],$t.prototype,"customStylesheet",void 0);or([(0,_i.property)()],$t.prototype,"elementToFocus",void 0);or([(0,_i.state)()],$t.prototype,"useAdoptedStyleSheets",void 0);function Fn(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var qr=Symbol("internalReduxEventsUnsubscribers"),oi=Symbol("internalStoresUnsubscribers"),Ai=Symbol("internalStores"),ph=Mn(Symbol("withRedux"),function(t){var e,i,r;class n extends t{constructor(){super(...arguments),this[e]=new Map,this[i]=new Map,this[r]=new Map}get reduxConstructor(){return this.constructor}willUpdate(s){super.willUpdate(s),[...this.reduxConstructor.reduxReactiveProperties].some(a=>s.has(a))&&this.updateFromStores()}getUnnamedStore(){if(this[Ai].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Ai].values()][0]}getStore(s){return s==null?this.getUnnamedStore():this[Ai].get(s)}addStore(s,a){var l;a=(l=a??s.name)!==null&&l!==void 0?l:"default-store",this.unsubscribeFromStore(a),this[Ai].set(a,s),this.subscribeToStore(a,s),this.updateFromStores()}removeStore(s){let a=typeof s=="string"?s:s.name;this.unsubscribeFromStore(a),this[Ai].delete(a)}setupStores(){this.unsubscribeFromStores(),this[Ai].forEach((s,a)=>this.subscribeToStore(a,s)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((s,a)=>{let l=this.constructor.getPropertyOptions(a);if(!l?.attribute||!this.hasAttribute(typeof l?.attribute=="string"?l.attribute:a)){let d=this.getStore(s.store);d&&(s.store?this[oi].has(s.store):this[oi].size>0)&&(this[a]=s.selector(d.getState(),this))}})}subscribeToStore(s,a){var l;this[oi].set(s,a.subscribe(()=>this.updateFromStores())),this[qr].set(s,[]),Fn(a)&&a.eventBus&&((l=this.reduxConstructor.reduxEventListeners)===null||l===void 0||l.forEach((d,u)=>{if(typeof this[u]=="function"&&(!d.store||a.name===d.store)){let p=f=>this[u](f);a.addEventListener(d.eventName,p),this[qr].get(s).push(()=>a.removeEventListener(d.eventName,p))}})),this.onStoreAvailable(s)}unsubscribeFromStores(){this[oi].forEach((s,a)=>this.unsubscribeFromStore(a))}unsubscribeFromStore(s){var a;this[oi].has(s)&&this[oi].get(s)(),this[oi].delete(s),(a=this[qr].get(s))===null||a===void 0||a.forEach(l=>l()),this[qr].delete(s)}onStoreAvailable(s){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return e=oi,i=Ai,r=qr,n.reduxProperties=new Map,n.reduxReactiveProperties=new Set,n.reduxEventListeners=new Map,n}),Rl=class extends ph($t){};function Te(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 fh=typeof Symbol=="function"&&Symbol.observable||"@@observable",Ol=fh,js=()=>Math.random().toString(36).substring(7).split("").join("."),hh={INIT:`@@redux/INIT${js()}`,REPLACE:`@@redux/REPLACE${js()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${js()}`},Vn=hh;function Bn(t){if(typeof t!="object"||t===null)return!1;let e=t;for(;Object.getPrototypeOf(e)!==null;)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e||Object.getPrototypeOf(t)===null}function Ws(t,e,i){if(typeof t!="function")throw new Error(Te(2));if(typeof e=="function"&&typeof i=="function"||typeof i=="function"&&typeof arguments[3]=="function")throw new Error(Te(0));if(typeof e=="function"&&typeof i>"u"&&(i=e,e=void 0),typeof i<"u"){if(typeof i!="function")throw new Error(Te(1));return i(Ws)(t,e)}let r=t,n=e,o=new Map,s=o,a=0,l=!1;function d(){s===o&&(s=new Map,o.forEach((b,R)=>{s.set(R,b)}))}function u(){if(l)throw new Error(Te(3));return n}function p(b){if(typeof b!="function")throw new Error(Te(4));if(l)throw new Error(Te(5));let R=!0;d();let V=a++;return s.set(V,b),function(){if(R){if(l)throw new Error(Te(6));R=!1,d(),s.delete(V),o=null}}}function f(b){if(!Bn(b))throw new Error(Te(7));if(typeof b.type>"u")throw new Error(Te(8));if(typeof b.type!="string")throw new Error(Te(17));if(l)throw new Error(Te(9));try{l=!0,n=r(n,b)}finally{l=!1}return(o=s).forEach(V=>{V()}),b}function y(b){if(typeof b!="function")throw new Error(Te(10));r=b,f({type:Vn.REPLACE})}function S(){let b=p;return{subscribe(R){if(typeof R!="object"||R===null)throw new Error(Te(11));function V(){let k=R;k.next&&k.next(u())}return V(),{unsubscribe:b(V)}},[Ol](){return this}}}return f({type:Vn.INIT}),{dispatch:f,subscribe:p,getState:u,replaceReducer:y,[Ol]:S}}function mh(t){Object.keys(t).forEach(e=>{let i=t[e];if(typeof i(void 0,{type:Vn.INIT})>"u")throw new Error(Te(12));if(typeof i(void 0,{type:Vn.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Te(13))})}function kl(t){let e=Object.keys(t),i={};for(let s=0;s<e.length;s++){let a=e[s];typeof t[a]=="function"&&(i[a]=t[a])}let r=Object.keys(i),n,o;try{mh(i)}catch(s){o=s}return function(a={},l){if(o)throw o;let d=!1,u={};for(let p=0;p<r.length;p++){let f=r[p],y=i[f],S=a[f],T=y(S,l);if(typeof T>"u"){let b=l&&l.type;throw new Error(Te(14))}u[f]=T,d=d||T!==S}return d=d||r.length!==Object.keys(a).length,d?u:a}}function Yr(...t){return t.length===0?e=>e:t.length===1?t[0]:t.reduce((e,i)=>(...r)=>e(i(...r)))}function Ll(...t){return e=>(i,r)=>{let n=e(i,r),o=()=>{throw new Error(Te(15))},s={getState:n.getState,dispatch:(l,...d)=>o(l,...d)},a=t.map(l=>l(s));return o=Yr(...a)(n.dispatch),{...n,dispatch:o}}}function Dl(t){return Bn(t)&&"type"in t&&typeof t.type=="string"}var Bl=Symbol.for("immer-nothing"),Il=Symbol.for("immer-draftable"),De=Symbol.for("immer-state");function St(t,...e){throw new Error(`[Immer] minified error nr: ${t}. Full error at: https://bit.ly/3cXEKWf`)}var Qe=Object,ar=Qe.getPrototypeOf,Wn="constructor",Xn="prototype",Ys="configurable",Kn="enumerable",zn="writable",Zr="value",Ut=t=>!!t&&!!t[De];function et(t){return t?Hl(t)||Qn(t)||!!t[Il]||!!t[Wn]?.[Il]||eo(t)||to(t):!1}var gh=Qe[Xn][Wn].toString(),Ml=new WeakMap;function Hl(t){if(!t||!ra(t))return!1;let e=ar(t);if(e===null||e===Qe[Xn])return!0;let i=Qe.hasOwnProperty.call(e,Wn)&&e[Wn];if(i===Object)return!0;if(!sr(i))return!1;let r=Ml.get(i);return r===void 0&&(r=Function.toString.call(i),Ml.set(i,r)),r===gh}function Jn(t,e,i=!0){Qr(t)===0?(i?Reflect.ownKeys(t):Qe.keys(t)).forEach(n=>{e(n,t[n],t)}):t.forEach((r,n)=>e(n,r,t))}function Qr(t){let e=t[De];return e?e.type_:Qn(t)?1:eo(t)?2:to(t)?3:0}var Ks=(t,e,i=Qr(t))=>i===2?t.has(e):Qe[Xn].hasOwnProperty.call(t,e),Zs=(t,e,i=Qr(t))=>i===2?t.get(e):t[e],Gn=(t,e,i,r=Qr(t))=>{r===2?t.set(e,i):r===3?t.add(i):t[e]=i};function yh(t,e){return t===e?t!==0||1/t===1/e:t!==t&&e!==e}var Qn=Array.isArray,eo=t=>t instanceof Map,to=t=>t instanceof Set,ra=t=>typeof t=="object",sr=t=>typeof t=="function",Gs=t=>typeof t=="boolean";function vh(t){let e=+t;return Number.isInteger(e)&&String(e)===t}var Gt=t=>t.copy_||t.base_;var na=t=>t.modified_?t.copy_:t.base_;function Xs(t,e){if(eo(t))return new Map(t);if(to(t))return new Set(t);if(Qn(t))return Array[Xn].slice.call(t);let i=Hl(t);if(e===!0||e==="class_only"&&!i){let r=Qe.getOwnPropertyDescriptors(t);delete r[De];let n=Reflect.ownKeys(r);for(let o=0;o<n.length;o++){let s=n[o],a=r[s];a[zn]===!1&&(a[zn]=!0,a[Ys]=!0),(a.get||a.set)&&(r[s]={[Ys]:!0,[zn]:!0,[Kn]:a[Kn],[Zr]:t[s]})}return Qe.create(ar(t),r)}else{let r=ar(t);if(r!==null&&i)return{...t};let n=Qe.create(r);return Qe.assign(n,t)}}function oa(t,e=!1){return io(t)||Ut(t)||!et(t)||(Qr(t)>1&&Qe.defineProperties(t,{set:Hn,add:Hn,clear:Hn,delete:Hn}),Qe.freeze(t),e&&Jn(t,(i,r)=>{oa(r,!0)},!1)),t}function bh(){St(2)}var Hn={[Zr]:bh};function io(t){return t===null||!ra(t)?!0:Qe.isFrozen(t)}var qn="MapSet",Js="Patches",Pl="ArrayMethods",zl={};function Ci(t){let e=zl[t];return e||St(0,t),e}var Nl=t=>!!zl[t];var Xr,jl=()=>Xr,xh=(t,e)=>({drafts_:[],parent_:t,immer_:e,canAutoFreeze_:!0,unfinalizedDrafts_:0,handledSet_:new Set,processedForPatches_:new Set,mapSetPlugin_:Nl(qn)?Ci(qn):void 0,arrayMethodsPlugin_:Nl(Pl)?Ci(Pl):void 0});function $l(t,e){e&&(t.patchPlugin_=Ci(Js),t.patches_=[],t.inversePatches_=[],t.patchListener_=e)}function Qs(t){ea(t),t.drafts_.forEach(Sh),t.drafts_=null}function ea(t){t===Xr&&(Xr=t.parent_)}var Ul=t=>Xr=xh(Xr,t);function Sh(t){let e=t[De];e.type_===0||e.type_===1?e.revoke_():e.revoked_=!0}function Fl(t,e){e.unfinalizedDrafts_=e.drafts_.length;let i=e.drafts_[0];if(t!==void 0&&t!==i){i[De].modified_&&(Qs(e),St(4)),et(t)&&(t=Vl(e,t));let{patchPlugin_:n}=e;n&&n.generateReplacementPatches_(i[De].base_,t,e)}else t=Vl(e,i);return wh(e,t,!0),Qs(e),e.patches_&&e.patchListener_(e.patches_,e.inversePatches_),t!==Bl?t:void 0}function Vl(t,e){if(io(e))return e;let i=e[De];if(!i)return Yn(e,t.handledSet_,t);if(!ro(i,t))return e;if(!i.modified_)return i.base_;if(!i.finalized_){let{callbacks_:r}=i;if(r)for(;r.length>0;)r.pop()(t);Gl(i,t)}return i.copy_}function wh(t,e,i=!1){!t.parent_&&t.immer_.autoFreeze_&&t.canAutoFreeze_&&oa(e,i)}function Wl(t){t.finalized_=!0,t.scope_.unfinalizedDrafts_--}var ro=(t,e)=>t.scope_===e,Eh=[];function Kl(t,e,i,r){let n=Gt(t),o=t.type_;if(r!==void 0&&Zs(n,r,o)===e){Gn(n,r,i,o);return}if(!t.draftLocations_){let a=t.draftLocations_=new Map;Jn(n,(l,d)=>{if(Ut(d)){let u=a.get(d)||[];u.push(l),a.set(d,u)}})}let s=t.draftLocations_.get(e)??Eh;for(let a of s)Gn(n,a,i,o)}function _h(t,e,i){t.callbacks_.push(function(n){let o=e;if(!o||!ro(o,n))return;n.mapSetPlugin_?.fixSetContents(o);let s=na(o);Kl(t,o.draft_??o,s,i),Gl(o,n)})}function Gl(t,e){if(t.modified_&&!t.finalized_&&(t.type_===3||t.type_===1&&t.allIndicesReassigned_||(t.assigned_?.size??0)>0)){let{patchPlugin_:r}=e;if(r){let n=r.getPath(t);n&&r.generatePatches_(t,n,e)}Wl(t)}}function Ah(t,e,i){let{scope_:r}=t;if(Ut(i)){let n=i[De];ro(n,r)&&n.callbacks_.push(function(){jn(t);let s=na(n);Kl(t,i,s,e)})}else et(i)&&t.callbacks_.push(function(){let o=Gt(t);t.type_===3?o.has(i)&&Yn(i,r.handledSet_,r):Zs(o,e,t.type_)===i&&r.drafts_.length>1&&(t.assigned_.get(e)??!1)===!0&&t.copy_&&Yn(Zs(t.copy_,e,t.type_),r.handledSet_,r)})}function Yn(t,e,i){return!i.immer_.autoFreeze_&&i.unfinalizedDrafts_<1||Ut(t)||e.has(t)||!et(t)||io(t)||(e.add(t),Jn(t,(r,n)=>{if(Ut(n)){let o=n[De];if(ro(o,i)){let s=na(o);Gn(t,r,s,t.type_),Wl(o)}}else et(n)&&Yn(n,e,i)})),t}function Ch(t,e){let i=Qn(t),r={type_:i?1:0,scope_:e?e.scope_:jl(),modified_:!1,finalized_:!1,assigned_:void 0,parent_:e,base_:t,draft_:null,copy_:null,revoke_:null,isManual_:!1,callbacks_:void 0},n=r,o=Zn;i&&(n=[r],o=Jr);let{revoke:s,proxy:a}=Proxy.revocable(n,o);return r.draft_=a,r.revoke_=s,[a,r]}var Zn={get(t,e){if(e===De)return t;let i=t.scope_.arrayMethodsPlugin_,r=t.type_===1&&typeof e=="string";if(r&&i?.isArrayOperationMethod(e))return i.createMethodInterceptor(t,e);let n=Gt(t);if(!Ks(n,e,t.type_))return Rh(t,n,e);let o=n[e];if(t.finalized_||!et(o)||r&&t.operationMethod&&i?.isMutatingArrayMethod(t.operationMethod)&&vh(e))return o;if(o===qs(t.base_,e)||Th(t,e,o)){jn(t);let s=t.type_===1?+e:e,a=ia(t.scope_,o,t,s);return t.copy_[s]=a}return o},has(t,e){return e in Gt(t)},ownKeys(t){return Reflect.ownKeys(Gt(t))},set(t,e,i){let r=ql(Gt(t),e);if(r?.set)return r.set.call(t.draft_,i),!0;if(!t.modified_){let n=qs(Gt(t),e),o=n?.[De];if(o&&o.base_===i)return t.copy_[e]=i,t.assigned_.set(e,!1),!0;if(yh(i,n)&&(i!==void 0||Ks(t.base_,e,t.type_)))return!0;jn(t),ta(t)}return t.copy_[e]===i&&(i!==void 0||Ks(t.copy_,e,t.type_))||Number.isNaN(i)&&Number.isNaN(t.copy_[e])||(t.copy_[e]=i,t.assigned_.set(e,!0),Ah(t,e,i)),!0},deleteProperty(t,e){return jn(t),qs(t.base_,e)!==void 0||e in t.base_?(t.assigned_.set(e,!1),ta(t)):t.assigned_.delete(e),t.copy_&&delete t.copy_[e],!0},getOwnPropertyDescriptor(t,e){let i=Gt(t),r=Reflect.getOwnPropertyDescriptor(i,e);return r&&{[zn]:!0,[Ys]:t.type_!==1||e!=="length",[Kn]:r[Kn],[Zr]:i[e]}},defineProperty(){St(11)},getPrototypeOf(t){return ar(t.base_)},setPrototypeOf(){St(12)}},Jr={};for(let t in Zn){let e=Zn[t];Jr[t]=function(){let i=arguments;return i[0]=i[0][0],e.apply(this,i)}}Jr.deleteProperty=function(t,e){return Jr.set.call(this,t,e,void 0)};Jr.set=function(t,e,i){return Zn.set.call(this,t[0],e,i,t[0])};function qs(t,e){let i=t[De];return(i?Gt(i):t)[e]}function Th(t,e,i){return t.type_!==1||!t.allIndicesReassigned_||t.assigned_?.get(e)||!et(i)||i[De]?!1:t.baseRefs_.has(i)}function Rh(t,e,i){let r=ql(e,i);return r?Zr in r?r[Zr]:r.get?.call(t.draft_):void 0}function ql(t,e){if(!(e in t))return;let i=ar(t);for(;i;){let r=Object.getOwnPropertyDescriptor(i,e);if(r)return r;i=ar(i)}}function ta(t){t.modified_||(t.modified_=!0,t.parent_&&ta(t.parent_))}function jn(t){t.copy_||(t.assigned_=new Map,t.copy_=Xs(t.base_,t.scope_.immer_.useStrictShallowCopy_))}var Oh=class{constructor(t){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!1,this.produce=(e,i,r)=>{if(sr(e)&&!sr(i)){let o=i;i=e;let s=this;return function(l=o,...d){return s.produce(l,u=>i.call(this,u,...d))}}sr(i)||St(6),r!==void 0&&!sr(r)&&St(7);let n;if(et(e)){let o=Ul(this),s=ia(o,e,void 0),a=!0;try{n=i(s),a=!1}finally{a?Qs(o):ea(o)}return $l(o,r),Fl(n,o)}else if(!e||!ra(e)){if(n=i(e),n===void 0&&(n=e),n===Bl&&(n=void 0),this.autoFreeze_&&oa(n,!0),r){let o=[],s=[];Ci(Js).generateReplacementPatches_(e,n,{patches_:o,inversePatches_:s}),r(o,s)}return n}else St(1,e)},this.produceWithPatches=(e,i)=>{if(sr(e))return(s,...a)=>this.produceWithPatches(s,l=>e(l,...a));let r,n;return[this.produce(e,i,(s,a)=>{r=s,n=a}),r,n]},Gs(t?.autoFreeze)&&this.setAutoFreeze(t.autoFreeze),Gs(t?.useStrictShallowCopy)&&this.setUseStrictShallowCopy(t.useStrictShallowCopy),Gs(t?.useStrictIteration)&&this.setUseStrictIteration(t.useStrictIteration)}createDraft(t){et(t)||St(8),Ut(t)&&(t=Yl(t));let e=Ul(this),i=ia(e,t,void 0);return i[De].isManual_=!0,ea(e),i}finishDraft(t,e){let i=t&&t[De];(!i||!i.isManual_)&&St(9);let{scope_:r}=i;return $l(r,e),Fl(void 0,r)}setAutoFreeze(t){this.autoFreeze_=t}setUseStrictShallowCopy(t){this.useStrictShallowCopy_=t}setUseStrictIteration(t){this.useStrictIteration_=t}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(t,e){let i;for(i=e.length-1;i>=0;i--){let n=e[i];if(n.path.length===0&&n.op==="replace"){t=n.value;break}}i>-1&&(e=e.slice(i+1));let r=Ci(Js).applyPatches_;return Ut(t)?r(t,e):this.produce(t,n=>r(n,e))}};function ia(t,e,i,r){let[n,o]=eo(e)?Ci(qn).proxyMap_(e,i):to(e)?Ci(qn).proxySet_(e,i):Ch(e,i);return(i?.scope_??jl()).drafts_.push(n),o.callbacks_=i?.callbacks_??[],o.key_=r,i&&r!==void 0?_h(i,o,r):o.callbacks_.push(function(l){l.mapSetPlugin_?.fixSetContents(o);let{patchPlugin_:d}=l;o.modified_&&d&&d.generatePatches_(o,[],l)}),n}function Yl(t){return Ut(t)||St(10,t),Zl(t)}function Zl(t){if(!et(t)||io(t))return t;let e=t[De],i,r=!0;if(e){if(!e.modified_)return e.base_;e.finalized_=!0,i=Xs(t,e.scope_.immer_.useStrictShallowCopy_),r=e.scope_.immer_.shouldUseStrictIteration()}else i=Xs(t,!0);return Jn(i,(n,o)=>{Gn(i,n,Zl(o))},r),e&&(e.finalized_=!1),i}var kh=globalThis.Iterator,ey=typeof kh?.from=="function";var Lh=new Oh,sa=Lh.produce;function Xl(t){return({dispatch:i,getState:r})=>n=>o=>typeof o=="function"?o(i,r,t):n(o)}var Jl=Xl(),Ql=Xl;var Dh=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Yr:Yr.apply(null,arguments)},ay=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}},Ih=t=>t&&typeof t.match=="function";function si(t,e){function i(...r){if(e){let n=e(...r);if(!n)throw new Error(qt(0));return{type:t,payload:n.payload,..."meta"in n&&{meta:n.meta},..."error"in n&&{error:n.error}}}return{type:t,payload:r[0]}}return i.toString=()=>`${t}`,i.type=t,i.match=r=>Dl(r)&&r.type===t,i}var nc=class en extends Array{constructor(...e){super(...e),Object.setPrototypeOf(this,en.prototype)}static get[Symbol.species](){return en}concat(...e){return super.concat.apply(this,e)}prepend(...e){return e.length===1&&Array.isArray(e[0])?new en(...e[0].concat(this)):new en(...e.concat(this))}};function ec(t){return et(t)?sa(t,()=>{}):t}function no(t,e,i){return t.has(e)?t.get(e):t.set(e,i(e)).get(e)}function Mh(t){return typeof t=="boolean"}var Ph=()=>function(e){let{thunk:i=!0,immutableCheck:r=!0,serializableCheck:n=!0,actionCreatorCheck:o=!0}=e??{},s=new nc;return i&&(Mh(i)?s.push(Jl):s.push(Ql(i.extraArgument))),s},Nh="RTK_autoBatch";var tc=t=>e=>{setTimeout(e,t)},$h=(t,e)=>i=>{let r=!1,n=()=>{r||(r=!0,cancelAnimationFrame(o),clearTimeout(s),i())},o=t(n),s=setTimeout(n,e)},Uh=(t={type:"raf"})=>e=>(...i)=>{let r=e(...i),n=!0,o=!1,s=!1,a=new Set,l=t.type==="tick"?queueMicrotask:t.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?$h(window.requestAnimationFrame,100):tc(10):t.type==="callback"?t.queueNotification:tc(t.timeout),d=()=>{s=!1,o&&(o=!1,a.forEach(u=>u()))};return Object.assign({},r,{subscribe(u){let p=()=>n&&u(),f=r.subscribe(p);return a.add(u),()=>{f(),a.delete(u)}},dispatch(u){try{return n=!u?.meta?.[Nh],o=!n,o&&(s||(s=!0,l(d))),r.dispatch(u)}finally{n=!0}}})},Fh=t=>function(i){let{autoBatch:r=!0}=i??{},n=new nc(t);return r&&n.push(Uh(typeof r=="object"?r:void 0)),n};function oc(t){let e=Ph(),{reducer:i=void 0,middleware:r,devTools:n=!0,duplicateMiddlewareCheck:o=!0,preloadedState:s=void 0,enhancers:a=void 0}=t||{},l;if(typeof i=="function")l=i;else if(Bn(i))l=kl(i);else throw new Error(qt(1));let d;typeof r=="function"?d=r(e):d=e();let u=Yr;n&&(u=Dh({trace:!1,...typeof n=="object"&&n}));let p=Ll(...d),f=Fh(p),y=typeof a=="function"?a(f):f(),S=u(...y);return Ws(l,s,S)}function sc(t){let e={},i=[],r,n={addCase(o,s){let a=typeof o=="string"?o:o.type;if(!a)throw new Error(qt(28));if(a in e)throw new Error(qt(29));return e[a]=s,n},addAsyncThunk(o,s){return s.pending&&(e[o.pending.type]=s.pending),s.rejected&&(e[o.rejected.type]=s.rejected),s.fulfilled&&(e[o.fulfilled.type]=s.fulfilled),s.settled&&i.push({matcher:o.settled,reducer:s.settled}),n},addMatcher(o,s){return i.push({matcher:o,reducer:s}),n},addDefaultCase(o){return r=o,n}};return t(n),[e,i,r]}function Vh(t){return typeof t=="function"}function Bh(t,e){let[i,r,n]=sc(e),o;if(Vh(t))o=()=>ec(t());else{let a=ec(t);o=()=>a}function s(a=o(),l){let d=[i[l.type],...r.filter(({matcher:u})=>u(l)).map(({reducer:u})=>u)];return d.filter(u=>!!u).length===0&&(d=[n]),d.reduce((u,p)=>{if(p)if(Ut(u)){let y=p(u,l);return y===void 0?u:y}else{if(et(u))return sa(u,f=>p(f,l));{let f=p(u,l);if(f===void 0){if(u===null)return u;throw Error("A case reducer on a non-draftable value must not return undefined")}return f}}return u},a)}return s.getInitialState=o,s}var Hh=(t,e)=>Ih(t)?t.match(e):t(e);function zh(...t){return e=>t.some(i=>Hh(i,e))}var jh="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Wh=(t=21)=>{let e="",i=t;for(;i--;)e+=jh[Math.random()*64|0];return e},Kh=["name","message","stack","code"],aa=class{constructor(t,e){this.payload=t,this.meta=e}payload;meta;_type},ic=class{constructor(t,e){this.payload=t,this.meta=e}payload;meta;_type},Gh=t=>{if(typeof t=="object"&&t!==null){let e={};for(let i of Kh)typeof t[i]=="string"&&(e[i]=t[i]);return e}return{message:String(t)}},rc="External signal was aborted",qh=(()=>{function t(e,i,r){let n=si(e+"/fulfilled",(l,d,u,p)=>({payload:l,meta:{...p||{},arg:u,requestId:d,requestStatus:"fulfilled"}})),o=si(e+"/pending",(l,d,u)=>({payload:void 0,meta:{...u||{},arg:d,requestId:l,requestStatus:"pending"}})),s=si(e+"/rejected",(l,d,u,p,f)=>({payload:p,error:(r&&r.serializeError||Gh)(l||"Rejected"),meta:{...f||{},arg:u,requestId:d,rejectedWithValue:!!p,requestStatus:"rejected",aborted:l?.name==="AbortError",condition:l?.name==="ConditionError"}}));function a(l,{signal:d}={}){return(u,p,f)=>{let y=r?.idGenerator?r.idGenerator(l):Wh(),S=new AbortController,T,b;function R(w){b=w,S.abort()}d&&(d.aborted?R(rc):d.addEventListener("abort",()=>R(rc),{once:!0}));let V=(async function(){let w;try{let N=r?.condition?.(l,{getState:p,extra:f});if(Zh(N)&&(N=await N),N===!1||S.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};let ae=new Promise((q,le)=>{T=()=>{le({name:"AbortError",message:b||"Aborted"})},S.signal.addEventListener("abort",T,{once:!0})});u(o(y,l,r?.getPendingMeta?.({requestId:y,arg:l},{getState:p,extra:f}))),w=await Promise.race([ae,Promise.resolve(i(l,{dispatch:u,getState:p,extra:f,requestId:y,signal:S.signal,abort:R,rejectWithValue:((q,le)=>new aa(q,le)),fulfillWithValue:((q,le)=>new ic(q,le))})).then(q=>{if(q instanceof aa)throw q;return q instanceof ic?n(q.payload,y,l,q.meta):n(q,y,l)})])}catch(N){w=N instanceof aa?s(null,y,l,N.payload,N.meta):s(N,y,l)}finally{T&&S.signal.removeEventListener("abort",T)}return r&&!r.dispatchConditionRejection&&s.match(w)&&w.meta.condition||u(w),w})();return Object.assign(V,{abort:R,requestId:y,arg:l,unwrap(){return V.then(Yh)}})}}return Object.assign(a,{pending:o,rejected:s,fulfilled:n,settled:zh(s,n),typePrefix:e})}return t.withTypes=()=>t,t})();function Yh(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function Zh(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var ac=Symbol.for("rtk-slice-createasyncthunk"),cy={[ac]:qh};function Xh(t,e){return`${t}/${e}`}function Jh({creators:t}={}){let e=t?.asyncThunk?.[ac];return function(r){let{name:n,reducerPath:o=n}=r;if(!n)throw new Error(qt(11));typeof process<"u";let s=(typeof r.reducers=="function"?r.reducers(em()):r.reducers)||{},a=Object.keys(s),l={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},d={addCase(w,k){let N=typeof w=="string"?w:w.type;if(!N)throw new Error(qt(12));if(N in l.sliceCaseReducersByType)throw new Error(qt(13));return l.sliceCaseReducersByType[N]=k,d},addMatcher(w,k){return l.sliceMatchers.push({matcher:w,reducer:k}),d},exposeAction(w,k){return l.actionCreators[w]=k,d},exposeCaseReducer(w,k){return l.sliceCaseReducersByName[w]=k,d}};a.forEach(w=>{let k=s[w],N={reducerName:w,type:Xh(n,w),createNotation:typeof r.reducers=="function"};im(k)?nm(N,k,d,e):tm(N,k,d)});function u(){let[w={},k=[],N=void 0]=typeof r.extraReducers=="function"?sc(r.extraReducers):[r.extraReducers],ae={...w,...l.sliceCaseReducersByType};return Bh(r.initialState,q=>{for(let le in ae)q.addCase(le,ae[le]);for(let le of l.sliceMatchers)q.addMatcher(le.matcher,le.reducer);for(let le of k)q.addMatcher(le.matcher,le.reducer);N&&q.addDefaultCase(N)})}let p=w=>w,f=new Map,y=new WeakMap,S;function T(w,k){return S||(S=u()),S(w,k)}function b(){return S||(S=u()),S.getInitialState()}function R(w,k=!1){function N(q){let le=q[w];return typeof le>"u"&&k&&(le=no(y,N,b)),le}function ae(q=p){let le=no(f,k,()=>new WeakMap);return no(le,q,()=>{let Hr={};for(let[at,Ei]of Object.entries(r.selectors??{}))Hr[at]=Qh(Ei,q,()=>no(y,q,b),k);return Hr})}return{reducerPath:w,getSelectors:ae,get selectors(){return ae(N)},selectSlice:N}}let V={name:n,reducer:T,actions:l.actionCreators,caseReducers:l.sliceCaseReducersByName,getInitialState:b,...R(o),injectInto(w,{reducerPath:k,...N}={}){let ae=k??o;return w.inject({reducerPath:ae,reducer:T},N),{...V,...R(ae,!0)}}};return V}}function Qh(t,e,i,r){function n(o,...s){let a=e(o);return typeof a>"u"&&r&&(a=i()),t(a,...s)}return n.unwrapped=t,n}var lc=Jh();function em(){function t(e,i){return{_reducerDefinitionType:"asyncThunk",payloadCreator:e,...i}}return t.withTypes=()=>t,{reducer(e){return Object.assign({[e.name](...i){return e(...i)}}[e.name],{_reducerDefinitionType:"reducer"})},preparedReducer(e,i){return{_reducerDefinitionType:"reducerWithPrepare",prepare:e,reducer:i}},asyncThunk:t}}function tm({type:t,reducerName:e,createNotation:i},r,n){let o,s;if("reducer"in r){if(i&&!rm(r))throw new Error(qt(17));o=r.reducer,s=r.prepare}else o=r;n.addCase(t,o).exposeCaseReducer(e,o).exposeAction(e,s?si(t,s):si(t))}function im(t){return t._reducerDefinitionType==="asyncThunk"}function rm(t){return t._reducerDefinitionType==="reducerWithPrepare"}function nm({type:t,reducerName:e},i,r,n){if(!n)throw new Error(qt(18));let{payloadCreator:o,fulfilled:s,pending:a,rejected:l,settled:d,options:u}=i,p=n(t,o,u);r.exposeAction(e,p),s&&r.addCase(p.fulfilled,s),a&&r.addCase(p.pending,a),l&&r.addCase(p.rejected,l),d&&r.addMatcher(p.settled,d),r.exposeCaseReducer(e,{fulfilled:s||oo,pending:a||oo,rejected:l||oo,settled:d||oo})}function oo(){}var cc="listener",dc="completed",uc="cancelled",dy=`task-${uc}`,uy=`task-${dc}`,py=`${cc}-${uc}`,fy=`${cc}-${dc}`;var{assign:pc}=Object;var la="listenerMiddleware";var om=pc(si(`${la}/add`),{withTypes:()=>om}),hy=si(`${la}/removeAll`),sm=pc(si(`${la}/remove`),{withTypes:()=>sm});function qt(t){return`Minified Redux Toolkit error #${t}; visit https://redux-toolkit.js.org/Errors?code=${t} for the full message or use the non-minified dev environment for full errors. `}var am=Mn(Symbol("withEventBus"),function(t,e){return class extends t{constructor(){super(...arguments),this.eventBus=e??document.createElement("span")}addEventListener(i,r,n){this.eventBus.addEventListener(i,r,n)}dispatchEvent(i){return this.eventBus.dispatchEvent(i)}removeEventListener(i,r,n){this.eventBus.removeEventListener(i,r,n)}}}),so=class extends am(Object){};window.ftReduxStores||(window.ftReduxStores={});var fc=class t extends so{static get(e){var i;let r=typeof e=="string"?e:e.name,n=typeof e=="string"?void 0:e,o=window.ftReduxStores[r];if(Fn(o))return o;if(n==null)return;let s=lc({...n,reducers:(i=n.reducers)!==null&&i!==void 0?i:{}}),a=oc({reducer:(l,d)=>{if(d.type==="CLEAR_FT_REDUX_STORE"){let u=Kr(s.getInitialState());for(let p of d.keeping)u[p]=(l??u)[p];return u}else if(typeof d.type=="string"&&d.type.startsWith("DEFAULT_VALUE_SETTER__"))return{...l,...d.overwrites};return s.reducer(l,d)}});return window.ftReduxStores[n.name]=new t(s,a,n.eventBus)}constructor(e,i,r){super(),this.reduxSlice=e,this.reduxStore=i,this.isFtReduxStore=!0,this.commands=new Pn,this.injectInto=(o,s)=>this.reduxSlice.injectInto(o,s),this.selectSlice=o=>this.reduxSlice.selectSlice(o);let n=o=>o!=null?JSON.parse(JSON.stringify(o)):o;this.actions=new Proxy(this.reduxSlice.actions,{get:(o,s,a)=>{let l=s,d=o[l];return d?(...u)=>{let p=d(...u.map(n));return this.reduxStore.dispatch(p),p}:u=>{let p=l,f=this.getState()[p];rr(f,u)||this.setState({[p]:n(u)})}}}),this.eventBus=r??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:[]})}clearKeeping(...e){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:e})}setState(e){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(e).join("_"),overwrites:e})}get dispatch(){throw new Error("Don't use this method, actions are automatically dispatched when called.")}[Symbol.observable](){return this.reduxStore[Symbol.observable]()}getState(){return this.reduxStore.getState()}replaceReducer(e){throw new Error("Not implemented yet.")}subscribe(e){return this.reduxStore.subscribe(e)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}get selectors(){return this.reduxSlice.selectors}get reducerPath(){return this.reduxSlice.reducerPath}getSelectors(){return this.reduxSlice.getSelectors()}};var ao=class{static format(e,i,r,n,o){return window.moment?window.moment(e).locale(i).format(this.getMomentDateFormat(r,n,!!o)):this.getIntlDateTime(e,i,r,n,!!o)}static getMomentDateFormat(e,i,r){return r?"LT":e?i?"lll":"ll":i?"L LT":"L"}static getIntlDateTime(e,i,r,n,o){let s=typeof e=="string"?new Date(e):e,a=new Intl.DateTimeFormat(i,{dateStyle:r?"medium":"short"}).format(s),l=new Intl.DateTimeFormat(i,{timeStyle:"short"}).format(s);return o?l:n?`${a} ${l}`:a}static getTimezoneAsString(){let e=r=>String(Math.floor(r)).padStart(2,"0"),i=new Date().getTimezoneOffset();return`${i<0?"+":"-"}${e(Math.abs(i)/60)}:${e(Math.abs(i)%60)}`}};var lo=c(h()),lm="ft-app-info",wt=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};wt.eventName="authentication-change";var Ti=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};Ti.eventName="ui-locale-changed";var cm={session:(t,e)=>{(0,lo.deepEqual)(t.session,e.payload)||(t.session=e.payload,setTimeout(()=>v.dispatchEvent(new wt(e.payload)),0))}},v=lo.FtReduxStore.get({name:lm,reducers:cm,initialState:{baseUrl:void 0,tenantId:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableContentLocales:[],localesConfiguration:void 0,metadataConfiguration:void 0,privacyPolicyConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,noCustomCode:!1,session:void 0,openExternalDocumentInNewTab:!1,navigatorOnline:!0,forcedOffline:!1,authenticationRequired:!1,stickyFilters:void 0}});var hc=c(h()),co=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},mc=(0,hc.applyMixinOnce)(Symbol("withDateFormat"),function(t){class e extends t{constructor(...r){super(r),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(v)}dateFormatOptionsChanged(r){return r.has("metadataDescriptors")||r.has("useLongDateFormat")||r.has("useDateTimeFormat")||r.has("uiLocale")}getDateFormatter(r){var n,o;return((o=(n=this.metadataDescriptors.find(a=>a.key===r))===null||n===void 0?void 0:n.date)!==null&&o!==void 0?o:!1)?a=>ao.format(a,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return co([(0,ca.property)({type:Boolean})],e.prototype,"useLongDateFormat",void 0),co([(0,ca.property)({type:Boolean})],e.prototype,"useDateTimeFormat",void 0),co([zs({store:v.name,selector:i=>{var r,n;return(n=(r=i.metadataConfiguration)===null||r===void 0?void 0:r.descriptors)!==null&&n!==void 0?n:[]}})],e.prototype,"metadataDescriptors",void 0),co([zs({store:v.name})],e.prototype,"uiLocale",void 0),e});var gc;(function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"})(gc||(gc={}));var yc;(function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"})(yc||(yc={}));var vc;(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"})(vc||(vc={}));var bc;(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"})(bc||(bc={}));var xc;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(xc||(xc={}));var Sc;(function(t){t.VALUE="VALUE",t.DATE="DATE",t.RANGE="RANGE"})(Sc||(Sc={}));var wc;(function(t){t.OFFICIAL="OFFICIAL",t.AI="AI"})(wc||(wc={}));var Ec;(function(t){t.BOOKMARK__CREATE="BOOKMARK__CREATE",t.BOOKMARK__DELETE="BOOKMARK__DELETE",t.CASE_DEFLECTION__START="CASE_DEFLECTION__START",t.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",t.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",t.CHATBOT__RATE="CHATBOT__RATE",t.COLLECTION__CREATE="COLLECTION__CREATE",t.COLLECTION__UPDATE="COLLECTION__UPDATE",t.COLLECTION__DELETE="COLLECTION__DELETE",t.CUSTOM_EVENT__TRIGGER="CUSTOM_EVENT__TRIGGER",t.DOCUMENT__ON_DEMAND_TRANSLATE="DOCUMENT__ON_DEMAND_TRANSLATE",t.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",t.DOCUMENT__PRINT="DOCUMENT__PRINT",t.DOCUMENT__PROCESS="DOCUMENT__PROCESS",t.DOCUMENT__RATE="DOCUMENT__RATE",t.DOCUMENT__SEARCH="DOCUMENT__SEARCH",t.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",t.DOCUMENT__UNRATE="DOCUMENT__UNRATE",t.FEEDBACK__SEND="FEEDBACK__SEND",t.AI__COMPLETED_QUERY="AI__COMPLETED_QUERY",t.AI__RATE="AI__RATE",t.AI_CASE_DEFLECTION__START="AI_CASE_DEFLECTION__START",t.AI_CASE_DEFLECTION__OPEN_TICKET="AI_CASE_DEFLECTION__OPEN_TICKET",t.KHUB__PROCESS="KHUB__PROCESS",t.KHUB__SEARCH="KHUB__SEARCH",t.LABELS__DOWNLOAD="LABELS__DOWNLOAD",t.LINK__SHARE="LINK__SHARE",t.PAGE__DISPLAY="PAGE__DISPLAY",t.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",t.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",t.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",t.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",t.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",t.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",t.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",t.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",t.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",t.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",t.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",t.TOPIC__AI_TRANSLATE="TOPIC__AI_TRANSLATE",t.TOPIC__RATE="TOPIC__RATE",t.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",t.TOPIC__UNRATE="TOPIC__UNRATE",t.USER__LOGIN="USER__LOGIN",t.USER__LOGOUT="USER__LOGOUT",t.HEARTBEAT="HEARTBEAT"})(Ec||(Ec={}));var _c;(function(t){t.STANDARD="STANDARD",t.STRUCTURAL="STRUCTURAL"})(_c||(_c={}));var Ac;(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"})(Ac||(Ac={}));var Cc;(function(t){t.HOMEPAGE="HOMEPAGE",t.CUSTOM="CUSTOM",t.HEADER="HEADER",t.READER="READER",t.TOPIC_TEMPLATE="TOPIC_TEMPLATE",t.SEARCH="SEARCH",t.SEARCH_RESULT="SEARCH_RESULT",t.SEARCH_ANNOUNCEMENT="SEARCH_ANNOUNCEMENT",t.LINK_PREVIEW="LINK_PREVIEW",t.UD_VIEWER="UD_VIEWER",t.ASSET_VIEWER="ASSET_VIEWER"})(Cc||(Cc={}));var Tc;(function(t){t.CLASSIC="CLASSIC",t.CUSTOM="CUSTOM",t.DESIGNER="DESIGNER"})(Tc||(Tc={}));var Rc;(function(t){t.AND="AND",t.OR="OR",t.MONOVALUED="MONOVALUED"})(Rc||(Rc={}));var Oc;(function(t){t.NONE="NONE",t.ALPHABET="ALPHABET",t.VERSION="VERSION"})(Oc||(Oc={}));var _e;(function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"})(_e||(_e={}));var kc;(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"})(kc||(kc={}));var Lc;(function(t){t.OPTIONAL="OPTIONAL",t.MANDATORY="MANDATORY"})(Lc||(Lc={}));var Dc;(function(t){t.ASC="ASC",t.DESC="DESC"})(Dc||(Dc={}));var Ic;(function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"})(Ic||(Ic={}));var Mc;(function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"})(Mc||(Mc={}));var Pc;(function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(Pc||(Pc={}));var uo;(function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"})(uo||(uo={}));var Nc;(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"})(Nc||(Nc={}));var $c;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})($c||($c={}));var Uc;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.HTML_PACKAGE="HTML_PACKAGE",t.HTML_PACKAGE_PAGE="HTML_PACKAGE_PAGE"})(Uc||(Uc={}));var Fc;(function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS",t.ALL_TOPICS="ALL_TOPICS",t.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(Fc||(Fc={}));var Vc;(function(t){t.PLAIN_TEXT="PLAIN_TEXT",t.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",t.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(Vc||(Vc={}));var ie;(function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.GENERATIVE_AI_USER="GENERATIVE_AI_USER",t.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_USER",t.ANNOUNCEMENT_ADMIN="ANNOUNCEMENT_ADMIN",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN"})(ie||(ie={}));var lt;(function(t){t.SEARCHES="SEARCHES",t.BOOKMARKS="BOOKMARKS",t.BOOKS="BOOKS",t.COLLECTIONS="COLLECTIONS"})(lt||(lt={}));var Bc;(function(t){t.UNAUTHENTICATED="UNAUTHENTICATED",t.USER_INCOMPLETE="USER_INCOMPLETE",t.MFA_REQUIRED="MFA_REQUIRED",t.AUTHENTICATED="AUTHENTICATED"})(Bc||(Bc={}));var Hc;(function(t){t.UNREACHABLE="UNREACHABLE",t.UNAUTHORIZED="UNAUTHORIZED",t.FORBIDDEN="FORBIDDEN",t.INCOMPATIBLE="INCOMPATIBLE",t.FAILED="FAILED",t.OK="OK"})(Hc||(Hc={}));var zc;(function(t){t.VALID="VALID",t.INVALID="INVALID"})(zc||(zc={}));var jc;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SUMMARY="SUMMARY",t.SEMANTIC_SEARCH="SEMANTIC_SEARCH",t.CHATBOT_INSTRUCTIONS="CHATBOT_INSTRUCTIONS",t.DOCUMENTATION="DOCUMENTATION",t.OTHER="OTHER"})(jc||(jc={}));var Wc;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SLOW="SLOW",t.OTHER="OTHER"})(Wc||(Wc={}));var Kc;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(Kc||(Kc={}));var Gc;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(Gc||(Gc={}));var qc;(function(t){t.TEXT="TEXT",t.HTML="HTML"})(qc||(qc={}));var Yc;(function(t){t.IN_PROGRESS="IN_PROGRESS",t.ERROR="ERROR",t.DONE="DONE"})(Yc||(Yc={}));var Zc;(function(t){t.HTML="HTML",t.MARKDOWN="MARKDOWN"})(Zc||(Zc={}));var Xc;(function(t){t.SOURCES="SOURCES",t.ENRICH_AND_CLEAN="ENRICH_AND_CLEAN",t.VOCABULARIES="VOCABULARIES",t.METADATA="METADATA",t.PRETTY_URL="PRETTY_URL",t.ACCESS_RULE="ACCESS_RULE",t.DESIGNED_PAGES="DESIGNED_PAGES",t.THEME_STUDIO="THEME_STUDIO",t.PORTAL_GENERAL="PORTAL_GENERAL",t.ASSETS="ASSETS",t.CODE_LIBRARY="CODE_LIBRARY",t.THEME="THEME",t.CONTENT_STYLES="CONTENT_STYLES",t.HOMEPAGE="HOMEPAGE",t.CLASSIC_SEARCH_PAGE="CLASSIC_SEARCH_PAGE",t.CLASSIC_READER_PAGE="CLASSIC_READER_PAGE",t.PORTAL_METADATA="PORTAL_METADATA",t.LANGUAGES="LANGUAGES",t.PRINT_TEMPLATES="PRINT_TEMPLATES",t.OFFLINE="OFFLINE",t.CUSTOM_JS="CUSTOM_JS",t.CONFIDENTIALITY="CONFIDENTIALITY",t.NOTIFICATIONS="NOTIFICATIONS"})(Xc||(Xc={}));var po;(function(t){t.MAP="MAP",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT"})(po||(po={}));var dm={[ie.PERSONAL_BOOK_SHARE_USER]:[ie.PERSONAL_BOOK_USER],[ie.HTML_EXPORT_USER]:[ie.PERSONAL_BOOK_USER],[ie.PDF_EXPORT_USER]:[ie.PERSONAL_BOOK_USER],[ie.KHUB_ADMIN]:[ie.CONTENT_PUBLISHER],[ie.ADMIN]:[ie.KHUB_ADMIN,ie.USERS_ADMIN,ie.PORTAL_ADMIN,ie.BEHAVIOR_DATA_USER],[ie.GENERATIVE_AI_EXPORT_USER]:[ie.GENERATIVE_AI_USER]};function Jc(t,e){return t===e||(dm[t]??[]).some(i=>Jc(i,e))}function tn(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(r=>Jc(r,e))}var yo=c(h());var da=c(h());var Ft=class t{static get(e){let{baseUrl:i,apiIntegrationIdentifier:r}=v.getState(),n=e??r;if(i&&n&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(i,n,!0)}static await(e){return new Promise(i=>{let r=t.get(e);if(r)i(r);else{let n=v.subscribe(()=>{r=t.get(e),r&&(n(),i(r))})}})}};var lr=class{constructor(e){this.overrideApi=e}get api(){var e;return(e=this.overrideApi)!==null&&e!==void 0?e:Ft.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):Ft.await()}};var Re=class extends lr{constructor(e=!0,i){var r;super(i),this.sortObjectFields=(o,s)=>typeof s!="object"||s==null||Array.isArray(s)?s:Object.fromEntries(Object.entries(s).sort(([a],[l])=>a.localeCompare(l)));let n=this.constructor;n.commonCache=(r=n.commonCache)!==null&&r!==void 0?r:new da.CacheRegistry,this.cache=e?n.commonCache:new da.CacheRegistry}clearCache(){this.cache.clearAll()}hash(e){return String(Array.from(JSON.stringify(e,this.sortObjectFields)).reduce((i,r)=>0|31*i+r.charCodeAt(0),0))}};var fo=class extends Re{async listMySearches(){let{session:e}=v.getState();return tn(e,ie.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),300*1e3):[]}};var ho=class extends Re{async listMyBookmarks(){let e=v.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),300*1e3):[]}};var mo=class extends Re{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetCount(e){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${e}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(e){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${e}`),this.CACHE_DURATION)}isAuthenticated(){let e=v.getState().session;return!!e?.sessionAuthenticated}};var go=class extends Re{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let e=v.getState().session;return!!e?.sessionAuthenticated}};var um="ft-user-assets",pm={setAssetCount:(t,e)=>{let{userAssetType:i,count:r}=e.payload.assetCount;t.assetCounts.allAsset[i]=r},clearAssetCount:t=>{Object.values(lt).forEach(e=>{t.assetCounts.allAsset[e]=void 0})},setBookmarkCountByMap:(t,e)=>{let i=e.payload.mapId;t.assetCounts.bookmarkByMap[i]=e.payload.count},clearBookmarkCountByMap:t=>{t.assetCounts.bookmarkByMap={}},addAsset:(t,e)=>{let{assetType:i,mapId:r,asset:n}=e.payload;pa(t,i,[...ua(t,i),n]),Qc(t,i,1,r),ed(t,n)},editAsset:(t,e)=>{let{assetType:i,asset:r}=e.payload;pa(t,i,ua(t,i).map(n=>n.id===r.id?r:n)),ed(t,r)},removeAsset:(t,e)=>{let{assetType:i,mapId:r,assetId:n}=e.payload;pa(t,i,ua(t,i).filter(o=>o.id!==n)),Qc(t,i,-1,r)}},td={[lt.SEARCHES]:"savedSearches",[lt.BOOKMARKS]:"bookmarks",[lt.BOOKS]:void 0,[lt.COLLECTIONS]:void 0},ua=(t,e)=>{var i;let r=td[e];return r?(i=t[r])!==null&&i!==void 0?i:[]:[]},pa=(t,e,i)=>{let r=td[e];r&&(t[r]=i)},Qc=(t,e,i,r)=>{let n=t.assetCounts.allAsset[e];if(n!==void 0&&(t.assetCounts.allAsset[e]=Math.max(0,n+i),e===lt.BOOKMARKS&&r)){let o=t.assetCounts.bookmarkByMap[r];t.assetCounts.bookmarkByMap[r]=Math.max(0,o+i)}},ed=(t,e)=>{let i=t.assetLabels.map(n=>n.title),r=e.labels.filter(n=>!i.includes(n)).map(n=>({title:n}));t.assetLabels.push(...r)},$e=yo.FtReduxStore.get({name:um,reducers:pm,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(lt).map(t=>[t,void 0])),bookmarkByMap:{}},assetLabels:[]}}),fa=class{constructor(e=new mo,i=new go){this.assetCountsService=e,this.assetLabelsService=i,this.currentSession=v.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new ho,this.savedSearchesService=new fo,v.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:i}=v.getState();(0,yo.deepEqual)((e=this.currentSession)===null||e===void 0?void 0:e.profile,i?.profile)||(this.currentSession=i,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),$e.actions.clearAssetCount(),$e.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),$e.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),$e.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();$e.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let e=await this.assetLabelsService.getUserAssetLabels();$e.actions.assetLabels(e)}async loadAssetCount(e){let i=await this.assetCountsService.getUserAssetCount(e);i&&$e.getState().assetCounts.allAsset[e]!==i.count&&$e.actions.setAssetCount({assetCount:i})}async loadBookmarkByMapId(e){let i=await this.assetCountsService.getUserBookmarkCountByMap(e);i&&$e.getState().assetCounts.bookmarkByMap[e]!==i.count&&$e.actions.setBookmarkCountByMap({count:i.count,mapId:e})}async reloadAssetCount(e){this.assetCountsService.clearCache();let i=Object.keys($e.getState().assetCounts.bookmarkByMap).length!==0;e===lt.BOOKMARKS&&i&&$e.actions.clearBookmarkCountByMap(),$e.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 i=!((e=this.currentSession)===null||e===void 0)&&e.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;$e.actions.bookmarks(i)}}},fm=new fa;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=fm);var ha=class{addCommand(e,i=!1){v.commands.add(e,i)}consumeCommand(e){return v.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new ha;var ct=c(h());var id,cr=class extends CustomEvent{constructor(e){super("ft-i18n-context-loaded",{detail:e})}},hm=Symbol("clearAfterUnitTest"),vo=class extends(0,ct.withEventBus)(Re){constructor(e){super(),this.messageContextProvider=e,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[id]=()=>{this.defaultMessages={},this.cache=new ct.CacheRegistry,this.listeners={}},this.currentUiLocale=v.getState().uiLocale,v.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:e}=v.getState();this.currentUiLocale!==e&&(this.currentUiLocale=e,this.cache.clearAll(),this.notifyAll())}addContext(e){let i=e.name.toLowerCase();this.cache.setFinal(i,e),this.notify(i)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(e,i){var r;if(e=e.toLowerCase(),i&&Object.keys(i).length>0){let n={...(r=this.defaultMessages[e])!==null&&r!==void 0?r:{},...i};(0,ct.deepEqual)(this.defaultMessages[e],n)||(this.defaultMessages[e]=n,await this.notify(e))}return this.fetchContext(e)}resolveContext(e){var i,r;return this.fetchContext(e),(r=(i=this.cache.getNow(e))===null||i===void 0?void 0:i.messages)!==null&&r!==void 0?r:{}}resolveRawMessage(e,i){let r=e.toLowerCase();return this.resolveContext(r)[i]}resolveMessage(e,i,...r){var n;let o=e.toLowerCase(),s=this.resolveContext(o);return new ct.ParametrizedLabelResolver((n=this.defaultMessages[o])!==null&&n!==void 0?n:{},s).resolve(i,...r)}async fetchContext(e){let i=!this.cache.has(e),r;try{r=await this.cache.get(e,()=>this.messageContextProvider(this.currentUiLocale,e)),i&&await this.notify(e)}catch(n){!(n instanceof ct.CanceledPromiseError)&&i&&console.error(n)}return r}subscribe(e,i){var r;return e=e.toLowerCase(),this.listeners[e]=(r=this.listeners[e])!==null&&r!==void 0?r:new Set,this.listeners[e].add(i),()=>{var n;return(n=this.listeners[e])===null||n===void 0?void 0:n.delete(i)}}async notifyAll(){let e=Object.keys(this.listeners);document.body.dispatchEvent(new cr({loadedContexts:e})),this.dispatchEvent(new cr({loadedContexts:e})),await Promise.all(e.map(i=>this.notify(i,!1)))}async notify(e,i=!0){i&&(document.body.dispatchEvent(new cr({loadedContexts:[e]})),this.dispatchEvent(new cr({loadedContexts:[e]}))),this.listeners[e]!=null&&await Promise.all([...this.listeners[e].values()].map(r=>(0,ct.delay)(0).then(()=>r()).catch(()=>null)))}};id=hm;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends vo{constructor(){super(async(t,e)=>(await this.awaitApi).getFluidTopicsMessageContext(t,e))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends vo{constructor(){super(async(t,e)=>(await this.awaitApi).getCustomMessageContext(t,e))}});var dr=window.FluidTopicsI18nService,bo=window.FluidTopicsCustomI18nService;var rd=c(h()),ma=class{highlightHtml(e,i,r){(0,rd.highlightHtml)(e,i,r)}};window.FluidTopicsHighlightHtmlService=new ma;var nd=c(h());var ga=class{isDate(e){var i,r,n,o;return(o=(n=((r=(i=v.getState().metadataConfiguration)===null||i===void 0?void 0:i.descriptors)!==null&&r!==void 0?r:[]).find(a=>a.key===e))===null||n===void 0?void 0:n.date)!==null&&o!==void 0?o:!1}format(e,i){var r,n,o,s;if(e==null)return"";try{return nd.DateFormatter.format(e,(r=i?.locale)!==null&&r!==void 0?r:v.getState().uiLocale,(n=i?.longFormat)!==null&&n!==void 0?n:!1,(o=i?.withTime)!==null&&o!==void 0?o:!1,(s=i?.onlyTime)!==null&&s!==void 0?s:!1)}catch(a){throw console.error(`Date ${JSON.stringify(e)} is not valid`,a),a}}};window.FluidTopicsDateService=new ga;var od=c(h());var rn=class{static get(e,i){var r,n,o,s;let a=v.getState(),{lang:l,region:d}=(o=(n=(r=a.localesConfiguration)===null||r===void 0?void 0:r.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&o!==void 0?o:{lang:"en",region:"US"};return new od.SearchPlaceConverter(a.baseUrl,e??20,(s=a.localesConfiguration)===null||s===void 0?void 0:s.allLanguagesAllowed,i??`${l}-${d}`)}};var ya=class{urlToSearchRequest(e){return rn.get().parse(e)}searchRequestToUrl(e){return rn.get().serialize(e)}};window.FluidTopicsUrlService=new ya;var Yt=c(h());var Ri=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{nextLocation:e}})}};Ri.eventName="before-location-change";var Oi=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{currentItem:e}})}};Oi.eventName="change";var va=class{itemName(e){return`fluid-topics-history-item-${e}`}get(e){let i=sessionStorage.getItem(this.itemName(e));return i?JSON.parse(i):void 0}set(e,i){sessionStorage.setItem(this.itemName(e),JSON.stringify(i))}},sd=new va;var xo=class t extends Yt.WithEventBus{static build(){return new t(window.history,sd,()=>window.location,!1)}constructor(e,i,r,n){var o,s;super(),this.history=e,this.historyStorage=i,this.windowLocation=r,this.states=[],this.realPushState=e.pushState,this.realReplaceState=e.replaceState,this.initialIndex=(s=(o=e.state)===null||o===void 0?void 0:o.index)!==null&&s!==void 0?s:e.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(n)}setCurrentState(e,i=!1){let r=i&&this.currentIndex===e.index-1;this.currentState={...this.buildCurrentState(),...e},this.currentIndex=this.currentState.index,this.states[this.currentIndex]=this.currentState,r&&(this.states=this.states.slice(0,this.currentIndex+1)),this.historyStorage.set(this.currentIndex,this.currentState),(0,Yt.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,this.windowLocation().href]),setTimeout(()=>this.dispatchEvent(new Oi(this.currentItem())),0)}installProxies(){let e=i=>(r,n,[o,s,a])=>{let l=new Ri(new URL(typeof a=="string"?a:(a??this.windowLocation()).href,window.location.origin));this.dispatchEvent(l);let d=i(),u={...d===this.currentIndex?this.currentState:void 0,...o,index:d,href:l.detail.nextLocation.href};r.apply(n,[u,s,u.href]),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 i=this.history.length-1;i>=0;i--)e?this.states[i]=this.historyStorage.get(i):setTimeout(()=>this.states[i]=this.historyStorage.get(i),this.history.length-i)}updateCurrentState(e){var i;let r={...this.buildCurrentState(),...e,index:this.currentIndex,title:(i=e?.title)!==null&&i!==void 0?i:this.currentState.title};this.setCurrentState(r)}addBeforeLocationChangeListener(e){this.addEventListener(Ri.eventName,e)}removeBeforeLocationChangeListener(e){this.removeEventListener(Ri.eventName,e)}addHistoryChangeListener(e){this.addEventListener(Oi.eventName,e)}removeHistoryChangeListener(e){this.removeEventListener(Oi.eventName,e)}currentItem(){return(0,Yt.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,Yt.deepCopy)(this.states[this.previousDifferentMajorPosition()])}backwardItemMatching(e){let i=this.states.filter(r=>!!r).filter(r=>r.index<this.currentIndex).reverse();return(0,Yt.deepCopy)(i.find(r=>e(r)))}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,Yt.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 i;let r=(i=this.states[e])===null||i===void 0?void 0:i.majorStateId;if(!r)return e;let n=e,o=e+1;for(;this.states.length>o&&!this.isDifferentMajorState(o,r);)this.hasState(o)&&(n=o),o++;return n}buildCurrentState(){var e,i;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(i=(e=this.history.state)===null||e===void 0?void 0:e.title)!==null&&i!==void 0?i:document.title}}hasState(e){return this.states[e]!=null}isDifferentMajorState(e,i){var r;if(!this.hasState(e))return!1;let n=i??this.currentState.majorStateId,o=(r=this.states[e])===null||r===void 0?void 0:r.majorStateId;return o==null||o!=n}};window.FluidTopicsInternalHistoryService==null&&(window.FluidTopicsInternalHistoryService=xo.build(),window.FluidTopicsHistoryService={currentItem:()=>window.FluidTopicsInternalHistoryService.currentItem(),back:()=>window.FluidTopicsInternalHistoryService.back(),forward:()=>window.FluidTopicsInternalHistoryService.forward(),backwardItem:()=>window.FluidTopicsInternalHistoryService.backwardItem(),forwardItem:()=>window.FluidTopicsInternalHistoryService.forwardItem(),backwardItemMatching:t=>window.FluidTopicsInternalHistoryService.backwardItemMatching(t),addHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(t),removeHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(t),addBeforeLocationChangeListener:t=>window.FluidTopicsInternalHistoryService.addBeforeLocationChangeListener(t),removeBeforeLocationChangeListener:t=>window.FluidTopicsInternalHistoryService.removeBeforeLocationChangeListener(t)});var So=class{constructor(){this.storeListeners=[]}store(e,i){if(this.isAuthenticated())return;let r=JSON.stringify(i);window.localStorage.setItem(e,r),window.dispatchEvent(new StorageEvent("storage",{key:e,newValue:r,storageArea:window.localStorage}))}get(e){var i,r;if(!this.isAuthenticated())return(r=JSON.parse((i=window.localStorage.getItem(e))!==null&&i!==void 0?i:"null"))!==null&&r!==void 0?r:void 0}addStoreListener(e,i){let r=n=>{n.key===e()&&!this.isAuthenticated()&&i()};this.storeListeners.push(r),window.addEventListener("storage",r)}clearStoreListeners(){this.storeListeners.forEach(e=>window.removeEventListener("storage",e)),this.storeListeners.length=0}isAuthenticated(){let e=v.getState().session;return!!e?.sessionAuthenticated}};var ad=c(x());var ld=ad.css`
2
- `;var dd=c(x()),Ue=c(U()),Li=c(h());var ki=c(h());function cd(t,e){let{authenticationRequired:i,session:r}=v.getState();return i&&!r?.sessionAuthenticated?Promise.resolve(e):t()}var wo=class extends lr{async updateUiLocale(e){return(await this.awaitApi).updateUiLocale(e)}};var ba=class t extends ki.FtStateManager{static build(e){return new t(v,e)}constructor(e,i){super(),this.store=e,this.cache=new ki.CacheRegistry,this.withManualResources=!0,this.userLocaleService=new wo,this.cleanSessionDebouncer=new ki.Debouncer,this.reloadConfiguration=()=>{var r;(r=this.cache)===null||r===void 0||r.clear("availableContentLocales"),this.updateAvailableContentLocales()},this.reloadDebouncer=new ki.Debouncer(500),this.apiProvider=i??(()=>Ft.get())}setWithManualResources(e){this.withManualResources=e,this.updateIfNeeded()}addListeners(){this.store.addEventListener(wt.eventName,this.reloadConfiguration)}removeListeners(){this.store.removeEventListener(wt.eventName,this.reloadConfiguration)}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.store.getState().session==null&&this.updateSession(),this.store.getState().metadataConfiguration==null&&this.updateMetadataConfiguration()),this.store.getState().localesConfiguration==null&&this.updateLocalesConfiguration(),(this.store.getState().availableContentLocales==null||this.store.getState().availableContentLocales.length==0)&&this.updateAvailableContentLocales())}async updateSession(){let e=await this.cache.get("session",async()=>{let i=await this.apiProvider().getCurrentSession();return i.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.setSession(void 0)},i.idleTimeoutInMillis),i});this.setSession(e)}async updateMetadataConfiguration(){this.setMetadataConfiguration(await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration()))}async updateLocalesConfiguration(){this.setLocalesConfiguration(await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration()))}async updateAvailableContentLocales(){var e;let i=await this.cache.get("availableContentLocales",()=>cd(()=>this.apiProvider().getAvailableSearchLocales(),{contentLocales:[]}));this.setAvailableContentLocales((e=i.contentLocales)!==null&&e!==void 0?e:[])}setStickyFilters(e){this.store.actions.stickyFilters(e)}setBaseUrl(e){this.store.actions.baseUrl(e),window.fluidTopicsBaseUrl=e}setTenantId(e){this.store.actions.tenantId(e)}setApiIntegrationIdentifier(e){this.store.actions.apiIntegrationIdentifier(e)}setApiIntegrationAppVersion(e){this.store.actions.apiIntegrationAppVersion(e)}setUiLocale(e){this.store.actions.uiLocale(e)}setLocalesConfiguration(e){this.store.actions.localesConfiguration(e),setTimeout(()=>this.updateIfNeeded())}setAvailableContentLocales(e){this.store.actions.availableContentLocales(e),setTimeout(()=>this.updateIfNeeded())}stopReloadDebouncer(){this.reloadDebouncer.cancel()}requestUiLocaleUpdate(e,i){this.userLocaleService.updateUiLocale({uiLocale:e,contentLocale:i}).then(r=>{r.uiLocaleChanged&&(this.reloadDebouncer.run(()=>window.location.reload()),this.store.dispatchEvent(new Ti(r)))}).catch(()=>{})}setMetadataConfiguration(e){this.store.actions.metadataConfiguration(e),setTimeout(()=>this.updateIfNeeded())}setNoCustom(e){this.store.actions.noCustom(e)}setEditorMode(e){this.store.actions.editorMode(e)}setNoCustomComponent(e){this.store.actions.noCustomComponent(e)}setNoCustomCode(e){this.store.actions.noCustomCode(e)}setSession(e){this.store.actions.session(e),setTimeout(()=>this.updateIfNeeded())}setOpenExternalDocumentInNewTab(e){this.store.actions.openExternalDocumentInNewTab(e)}setNavigatorOnline(e){this.store.actions.navigatorOnline(e)}setForcedOffline(e){this.store.actions.forcedOffline(e)}setAuthenticationRequired(e){this.store.actions.authenticationRequired(e)}},ur=ba.build();var Ae=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},X=class extends Li.FtLitElementRedux{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.apiIntegrationAppVersion="ft-integration-app-version",this.uiLocale="en-US",this.editorMode=!1,this.noCustom=!1,this.openExternalDocumentInNewTab=!1,this.noCustomComponent=!1,this.noCustomCode=!1,this.withManualResources=!1,this.navigatorOnline=!1,this.forcedOffline=!1,this.authenticationRequired=!1,this.messageContexts=[],this.stateManager=ur,this.contextRoot=new zr}render(){return dd.html`
1
+ "use strict";(()=>{var ih=Object.create;var ll=Object.defineProperty;var rh=Object.getOwnPropertyDescriptor;var nh=Object.getOwnPropertyNames;var oh=Object.getPrototypeOf,sh=Object.prototype.hasOwnProperty;var rr=(t,e)=>()=>{try{return e||t((e={exports:{}}).exports,e),e.exports}catch(i){throw e=0,i}};var ah=(t,e,i,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of nh(e))!sh.call(t,n)&&n!==i&&ll(t,n,{get:()=>e[n],enumerable:!(r=rh(e,n))||r.enumerable});return t};var c=(t,e,i)=>(i=t!=null?ih(oh(t)):{},ah(e||!t||!t.__esModule?ll(i,"default",{value:t,enumerable:!0}):i,t));var h=rr((eg,cl)=>{cl.exports=ftGlobals.wcUtils});var U=rr((tg,dl)=>{dl.exports=ftGlobals.litDecorators});var S=rr((Cg,hl)=>{hl.exports=ftGlobals.lit});var yr=rr((fb,bd)=>{bd.exports=ftGlobals.litRepeat});var Ia=rr((Kb,tu)=>{tu.exports=ftGlobals.litUnsafeHTML});var ot=rr((oE,Ru)=>{Ru.exports=ftGlobals.litClassMap});var Qf=c(h());var pl=c(h()),fl=c(U());var Kt=class extends Event{constructor(e,i,r,n){super("context-request",{bubbles:!0,composed:!0}),this.context=e,this.contextTarget=i,this.callback=r,this.subscribe=n??!1}};var nr=class{constructor(e,i,r,n){if(this.subscribe=!1,this.provided=!1,this.value=void 0,this.t=(o,s)=>{this.unsubscribe&&(this.unsubscribe!==s&&(this.provided=!1,this.unsubscribe()),this.subscribe||this.unsubscribe()),this.value=o,this.host.requestUpdate(),this.provided&&!this.subscribe||(this.provided=!0,this.callback&&this.callback(o,s)),this.unsubscribe=s},this.host=e,i.context!==void 0){let o=i;this.context=o.context,this.callback=o.callback,this.subscribe=o.subscribe??!1}else this.context=i,this.callback=r,this.subscribe=n??!1;this.host.addController(this)}hostConnected(){this.dispatchRequest()}hostDisconnected(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=void 0)}dispatchRequest(){this.host.dispatchEvent(new Kt(this.context,this.host,this.t,this.subscribe))}};var Ln=class{get value(){return this.o}set value(e){this.setValue(e)}setValue(e,i=!1){let r=i||!Object.is(e,this.o);this.o=e,r&&this.updateObservers()}constructor(e){this.subscriptions=new Map,this.updateObservers=()=>{for(let[i,{disposer:r}]of this.subscriptions)i(this.o,r)},e!==void 0&&(this.value=e)}addCallback(e,i,r){if(!r)return void e(this.value);this.subscriptions.has(e)||this.subscriptions.set(e,{disposer:()=>{this.subscriptions.delete(e)},consumerHost:i});let{disposer:n}=this.subscriptions.get(e);e(this.value,n)}clearCallbacks(){this.subscriptions.clear()}};var Vs=class extends Event{constructor(e,i){super("context-provider",{bubbles:!0,composed:!0}),this.context=e,this.contextTarget=i}},or=class extends Ln{constructor(e,i,r){super(i.context!==void 0?i.initialValue:r),this.onContextRequest=n=>{if(n.context!==this.context)return;let o=n.contextTarget??n.composedPath()[0];o!==this.host&&(n.stopPropagation(),this.addCallback(n.callback,o,n.subscribe))},this.onProviderRequest=n=>{if(n.context!==this.context||(n.contextTarget??n.composedPath()[0])===this.host)return;let o=new Set;for(let[s,{consumerHost:a}]of this.subscriptions)o.has(s)||(o.add(s),a.dispatchEvent(new Kt(this.context,a,s,!0)));n.stopPropagation()},this.host=e,i.context!==void 0?this.context=i.context:this.context=i,this.attachListeners(),this.host.addController?.(this)}attachListeners(){this.host.addEventListener("context-request",this.onContextRequest),this.host.addEventListener("context-provider",this.onProviderRequest)}hostConnected(){this.host.dispatchEvent(new Vs(this.context,this.host))}};var zr=class{constructor(){this.pendingContextRequests=new Map,this.onContextProvider=e=>{let i=this.pendingContextRequests.get(e.context);if(i===void 0)return;this.pendingContextRequests.delete(e.context);let{requests:r}=i;for(let{elementRef:n,callbackRef:o}of r){let s=n.deref(),a=o.deref();s===void 0||a===void 0||s.dispatchEvent(new Kt(e.context,s,a,!0))}},this.onContextRequest=e=>{if(e.subscribe!==!0)return;let i=e.contextTarget??e.composedPath()[0],r=e.callback,n=this.pendingContextRequests.get(e.context);n===void 0&&this.pendingContextRequests.set(e.context,n={callbacks:new WeakMap,requests:[]});let o=n.callbacks.get(i);o===void 0&&n.callbacks.set(i,o=new WeakSet),o.has(r)||(o.add(r),n.requests.push({elementRef:new WeakRef(i),callbackRef:new WeakRef(r)}))}}attach(e){e.addEventListener("context-request",this.onContextRequest),e.addEventListener("context-provider",this.onContextProvider)}detach(e){e.removeEventListener("context-request",this.onContextRequest),e.removeEventListener("context-provider",this.onContextProvider)}};function jr({context:t}){return(e,i)=>{let r=new WeakMap;if(typeof i=="object")return{get(){return e.get.call(this)},set(n){return r.get(this).setValue(n),e.set.call(this,n)},init(n){return r.set(this,new or(this,{context:t,initialValue:n})),n}};{e.constructor.addInitializer((s=>{r.set(s,new or(s,{context:t}))}));let n=Object.getOwnPropertyDescriptor(e,i),o;if(n===void 0){let s=new WeakMap;o={get(){return s.get(this)},set(a){r.get(this).setValue(a),s.set(this,a)},configurable:!0,enumerable:!0}}else{let s=n.set;o={...n,set(a){r.get(this).setValue(a),s?.call(this,a)}}}return void Object.defineProperty(e,i,o)}}}function Wr({context:t,subscribe:e}){return(i,r)=>{typeof r=="object"?r.addInitializer((function(){new nr(this,{context:t,callback:n=>{i.set.call(this,n)},subscribe:e})})):i.constructor.addInitializer((n=>{new nr(n,{context:t,callback:o=>{n[r]=o},subscribe:e})}))}}var lh=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Bs=Symbol("asset-viewer-state-manager"),Nt=(0,pl.applyMixinOnce)(Symbol("toFtAssetViewerComponent"),function(t){class e extends t{willUpdate(r){super.willUpdate(r),r.has("viewerStateManager")&&(this.viewerStateManager?this.addStore(this.viewerStateManager.store,"viewer"):this.removeStore("viewer"))}connectedCallback(){super.connectedCallback(),this.viewerStateManager&&this.addStore(this.viewerStateManager.store,"viewer")}disconnectedCallback(){super.disconnectedCallback(),this.removeStore("viewer")}}return lh([Wr({context:Bs,subscribe:!0}),(0,fl.state)()],e.prototype,"viewerStateManager",void 0),e});var md=c(S()),gr=c(h());var ml=c(h()),ch={setZoom:(t,e)=>{t.contentModifiers.zoom=e.payload},setRotation:(t,e)=>{t.contentModifiers.rotation=e.payload}},In=t=>ml.FtReduxStore.get({name:"ft-viewer-"+t,initialState:{documentId:void 0,unstructuredDocument:void 0,document:void 0,assetId:void 0,origin:void 0,descriptor:void 0,contentModifiers:{zoom:void 0,rotation:0},watermark:void 0,configuration:void 0,documentRating:void 0,assetRating:void 0,relatives:void 0},reducers:ch});var gl=c(h()),sr=class extends gl.FtStateManager{constructor(e){super(),this.store=e}setZoom(e){this.store.actions.setZoom(e)}setRotation(e){this.store.actions.setRotation(e)}};var ca=c(U());var yl=c(U(),1);var Hs=t=>e=>{window.customElements.get(t)||window.customElements.define(t,e)};function vl(t,e){return(0,yl.property)({type:Object,converter:{fromAttribute:i=>{if(i==null)return Kr(t);try{return JSON.parse(i)}catch{return Kr(t)}},toAttribute:i=>JSON.stringify(i)},hasChanged:Gr,...e??{}})}function dh(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;let i,r;if(Array.isArray(t)){if(i=t.length,i!=e.length)return!1;for(r=i;r--!==0;)if(!ar(t[r],e[r]))return!1;return!0}if(t instanceof Map&&e instanceof Map){if(t.size!==e.size)return!1;for(r of t.entries())if(!e.has(r[0]))return!1;for(r of t.entries())if(!ar(r[1],e.get(r[0])))return!1;return!0}if(t instanceof Set&&e instanceof Set){if(t.size!==e.size)return!1;for(r of t.entries())if(!e.has(r[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 n=s=>Object.keys(s).filter(a=>s[a]!=null),o=n(t);if(i=o.length,i!==n(e).length)return!1;for(r=i;r--!==0;)if(!Object.prototype.hasOwnProperty.call(e,o[r]))return!1;for(r=i;r--!==0;){let s=o[r];if(!ar(t[s],e[s]))return!1}return!0}return t!==t&&e!==e||t==null&&e==null}function ar(t,e){try{return dh(t,e)}catch{return!1}}function Gr(t,e){return!ar(t,e)}function Kr(t){return typeof window.structuredClone=="function"?structuredClone(t):t!=null?JSON.parse(JSON.stringify(t)):t}function Mn(t,e){let i=r=>r[t]===!0;return r=>{if(i(r))return r;let n=e(r);return n[t]=!0,n}}var xl=c(U(),1);var zs=t=>{let e=t??{};return(i,r)=>{var n;let o={hasChanged:Gr,attribute:!1,...e};(0,xl.property)(o)(i,r);let s=i.constructor;s.reduxProperties=new Map(s.reduxProperties),s.reduxProperties.set(r,{selector:(n=e.selector)!==null&&n!==void 0?n:(a=>a[r]),store:e.store})}};var Pn=class{constructor(){this.queue=[]}add(e,i=!1){i&&this.clear(e.type),this.queue.push(e)}consume(e){let i=this.queue.find(r=>r.type===e);return i&&(this.queue=this.queue.filter(r=>r!==i)),i}clear(e){typeof e=="string"?this.queue=this.queue.filter(i=>i.type!==e):this.queue=this.queue.filter(i=>!e.test(i.type))}};var _i=c(U(),1);var Nn=class{constructor(e=0){this.timeout=e,this.callbacks=[]}run(e,i){return this.callbacks=[e],this.debounce(i)}queue(e,i){return this.callbacks.push(e),this.debounce(i)}cancel(){this.clearTimeout(),this.resolvePromise&&this.resolvePromise(!1),this.clearPromise()}debounce(e){return this.promise==null&&(this.promise=new Promise((i,r)=>{this.resolvePromise=i,this.rejectPromise=r})),this.clearTimeout(),this._debounce=window.setTimeout(()=>this.runCallbacks(),e??this.timeout),this.promise}async runCallbacks(){var e,i;let r=[...this.callbacks];this.callbacks=[];let n=(e=this.rejectPromise)!==null&&e!==void 0?e:(()=>null),o=(i=this.resolvePromise)!==null&&i!==void 0?i:(()=>null);this.clearPromise();for(let s of r)try{await s()}catch(a){n(a);return}o(!0)}clearTimeout(){this._debounce!=null&&window.clearTimeout(this._debounce)}clearPromise(){this.promise=void 0,this.resolvePromise=void 0,this.rejectPromise=void 0}};var Sl=c(S(),1);var $n=globalThis,uh=$n.ShadowRoot&&($n.ShadyCSS===void 0||$n.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype;var bl=(t,e)=>{if(uh)t.adoptedStyleSheets=e.map(i=>i instanceof CSSStyleSheet?i:i.styleSheet);else for(let i of e){let r=document.createElement("style"),n=$n.litNonce;n!==void 0&&r.setAttribute("nonce",n),r.textContent=i.cssText,t.appendChild(r)}};var Un=class extends Sl.LitElement{get scopedRegistryConstructor(){return this.constructor}createRenderRoot(){let e=this.scopedRegistryConstructor;e.elementDefinitions&&!e.registry&&(e.registry=new CustomElementRegistry,e.defineScopedElements(e.elementDefinitions));let i={...e.shadowRootOptions,customElements:e.registry},r=this.renderOptions.creationScope=this.attachShadow(i);return bl(r,e.elementStyles),r}static canDefineScopedElement(e){return!!this.registry&&!this.registry.get(e)}static defineScopedElements(e){Object.entries(e).forEach(([i,r])=>this.defineScopedElement(i,r))}static defineScopedElement(e,i){Hs(e)(i),this.canDefineScopedElement(e)&&this.registry.define(e,i)}canDefineScopedElement(e){return this.scopedRegistryConstructor.canDefineScopedElement(e)}defineScopedElements(e){this.scopedRegistryConstructor.defineScopedElements(e)}defineScopedElement(e,i){this.scopedRegistryConstructor.defineScopedElement(e,i)}};function wl(t,e,...i){var r;let n=t.querySelector(e);for(let o of i)n=(r=n?.shadowRoot)===null||r===void 0?void 0:r.querySelector(o);return n}var cr=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Cl,El=Symbol("constructorPrototype"),_l=Symbol("constructorName"),Tl=Symbol("exportpartsDebouncer"),Al=Symbol("dynamicDependenciesLoaded"),lr=class t extends CustomEvent{constructor(){super(t.eventName,{bubbles:!0})}};lr.eventName="exportparts-updated";var $t=class extends Un{constructor(){super(),this.useAdoptedStyleSheets=!0,this.adoptedCustomStyleSheet=new CSSStyleSheet,this[Cl]=new Nn(5),this.scheduleExportpartsUpdate=()=>{var e,i,r;(!((e=this.exportpartsPrefix)===null||e===void 0)&&e.trim()||(r=(i=this.exportpartsPrefixes)===null||i===void 0?void 0:i.length)!==null&&r!==void 0&&r)&&this[Tl].run(()=>{var n,o;!((n=this.exportpartsPrefix)===null||n===void 0)&&n.trim()?this.setExportpartsAttribute([this.exportpartsPrefix]):this.exportpartsPrefixes!=null&&((o=this.exportpartsPrefixes)===null||o===void 0?void 0:o.length)>0&&this.setExportpartsAttribute(this.exportpartsPrefixes)})},this[_l]=this.constructor.name,this[El]=this.constructor.prototype}adoptedCallback(){this.constructor.name!==this[_l]&&Object.setPrototypeOf(this,this[El])}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(r){this.useAdoptedStyleSheets=!1,console.error("Cannot use adopted stylesheets",r)}let i=this.constructor;i[Al]||(i[Al]=!0,this.importDynamicDependencies()),(e=this.shadowRoot)===null||e===void 0||e.addEventListener(lr.eventName,this.scheduleExportpartsUpdate)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.shadowRoot)===null||e===void 0||e.removeEventListener(lr.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 lr)})}contentAvailableCallback(e){}focusElementToFocus(e){if(e.has("elementToFocus")&&this.elementToFocus!=null){let{element:i,selector:r,shadowPath:n}=this.elementToFocus;if(r!=null){let o=[...n??[],r];i=wl(this.shadowRoot,...o)}i?.focus(),window.FluidTopicsA11yHints.isKeyboardNavigation||i?.blur(),this.elementToFocus=void 0}}applyCustomStylesheet(e){var i,r,n;if(((r=(i=this.shadowRoot)===null||i===void 0?void 0:i.querySelectorAll(".ft-lit-element--custom-stylesheet"))!==null&&r!==void 0?r:[]).forEach(o=>o.remove()),this.useAdoptedStyleSheets){if(e.has("customStylesheet"))try{this.adoptedCustomStyleSheet.replaceSync((n=this.customStylesheet)!==null&&n!==void 0?n:"")}catch(o){console.error(o,this.customStylesheet),this.useAdoptedStyleSheets=!1}}else if(this.customStylesheet){let o=document.createElement("style");o.classList.add("ft-lit-element--custom-stylesheet"),o.innerHTML=this.customStylesheet,this.shadowRoot.append(o)}}setExportpartsAttribute(e){var i,r,n,o,s,a;let l=f=>f!=null&&f.trim().length>0,d=e.filter(l).map(f=>f.trim());if(d.length===0){this.exportparts=void 0;return}let u=new Set;for(let f of(r=(i=this.shadowRoot)===null||i===void 0?void 0:i.querySelectorAll("[part],[exportparts]"))!==null&&r!==void 0?r:[]){let y=(o=(n=f.getAttribute("part"))===null||n===void 0?void 0:n.split(" "))!==null&&o!==void 0?o:[],w=(a=(s=f.getAttribute("exportparts"))===null||s===void 0?void 0:s.split(",").map(b=>b.split(":")[1]))!==null&&a!==void 0?a:[],T=[...y,...w].filter(l).map(b=>b.trim());for(let b of T)u.add(b)}if(u.size===0){this.exportparts=void 0;return}let p=[...u.values()].flatMap(f=>d.map(y=>`${f}:${y}--${f}`));this.exportparts=[...this.part,...p].join(", ")}};Cl=Tl;cr([(0,_i.property)()],$t.prototype,"exportpartsPrefix",void 0);cr([vl([])],$t.prototype,"exportpartsPrefixes",void 0);cr([(0,_i.property)({reflect:!0})],$t.prototype,"exportparts",void 0);cr([(0,_i.property)()],$t.prototype,"customStylesheet",void 0);cr([(0,_i.property)()],$t.prototype,"elementToFocus",void 0);cr([(0,_i.state)()],$t.prototype,"useAdoptedStyleSheets",void 0);function Fn(t){var e;return(e=t?.isFtReduxStore)!==null&&e!==void 0?e:!1}var qr=Symbol("internalReduxEventsUnsubscribers"),ai=Symbol("internalStoresUnsubscribers"),Ai=Symbol("internalStores"),ph=Mn(Symbol("withRedux"),function(t){var e,i,r;class n extends t{constructor(){super(...arguments),this[e]=new Map,this[i]=new Map,this[r]=new Map}get reduxConstructor(){return this.constructor}willUpdate(s){super.willUpdate(s),[...this.reduxConstructor.reduxReactiveProperties].some(a=>s.has(a))&&this.updateFromStores()}getUnnamedStore(){if(this[Ai].size>1)throw new Error("Cannot resolve unnamed store when multiple stores are configured.");return[...this[Ai].values()][0]}getStore(s){return s==null?this.getUnnamedStore():this[Ai].get(s)}addStore(s,a){var l;a=(l=a??s.name)!==null&&l!==void 0?l:"default-store",this.unsubscribeFromStore(a),this[Ai].set(a,s),this.subscribeToStore(a,s),this.updateFromStores()}removeStore(s){let a=typeof s=="string"?s:s.name;this.unsubscribeFromStore(a),this[Ai].delete(a)}setupStores(){this.unsubscribeFromStores(),this[Ai].forEach((s,a)=>this.subscribeToStore(a,s)),this.updateFromStores()}updateFromStores(){this.reduxConstructor.reduxProperties.forEach((s,a)=>{let l=this.constructor.getPropertyOptions(a);if(!l?.attribute||!this.hasAttribute(typeof l?.attribute=="string"?l.attribute:a)){let d=this.getStore(s.store);d&&(s.store?this[ai].has(s.store):this[ai].size>0)&&(this[a]=s.selector(d.getState(),this))}})}subscribeToStore(s,a){var l;this[ai].set(s,a.subscribe(()=>this.updateFromStores())),this[qr].set(s,[]),Fn(a)&&a.eventBus&&((l=this.reduxConstructor.reduxEventListeners)===null||l===void 0||l.forEach((d,u)=>{if(typeof this[u]=="function"&&(!d.store||a.name===d.store)){let p=f=>this[u](f);a.addEventListener(d.eventName,p),this[qr].get(s).push(()=>a.removeEventListener(d.eventName,p))}})),this.onStoreAvailable(s)}unsubscribeFromStores(){this[ai].forEach((s,a)=>this.unsubscribeFromStore(a))}unsubscribeFromStore(s){var a;this[ai].has(s)&&this[ai].get(s)(),this[ai].delete(s),(a=this[qr].get(s))===null||a===void 0||a.forEach(l=>l()),this[qr].delete(s)}onStoreAvailable(s){}connectedCallback(){super.connectedCallback(),this.setupStores()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeFromStores()}}return e=ai,i=Ai,r=qr,n.reduxProperties=new Map,n.reduxReactiveProperties=new Set,n.reduxEventListeners=new Map,n}),Rl=class extends ph($t){};function Te(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 fh=typeof Symbol=="function"&&Symbol.observable||"@@observable",Ol=fh,js=()=>Math.random().toString(36).substring(7).split("").join("."),hh={INIT:`@@redux/INIT${js()}`,REPLACE:`@@redux/REPLACE${js()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${js()}`},Vn=hh;function Bn(t){if(typeof t!="object"||t===null)return!1;let e=t;for(;Object.getPrototypeOf(e)!==null;)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e||Object.getPrototypeOf(t)===null}function Ws(t,e,i){if(typeof t!="function")throw new Error(Te(2));if(typeof e=="function"&&typeof i=="function"||typeof i=="function"&&typeof arguments[3]=="function")throw new Error(Te(0));if(typeof e=="function"&&typeof i>"u"&&(i=e,e=void 0),typeof i<"u"){if(typeof i!="function")throw new Error(Te(1));return i(Ws)(t,e)}let r=t,n=e,o=new Map,s=o,a=0,l=!1;function d(){s===o&&(s=new Map,o.forEach((b,R)=>{s.set(R,b)}))}function u(){if(l)throw new Error(Te(3));return n}function p(b){if(typeof b!="function")throw new Error(Te(4));if(l)throw new Error(Te(5));let R=!0;d();let V=a++;return s.set(V,b),function(){if(R){if(l)throw new Error(Te(6));R=!1,d(),s.delete(V),o=null}}}function f(b){if(!Bn(b))throw new Error(Te(7));if(typeof b.type>"u")throw new Error(Te(8));if(typeof b.type!="string")throw new Error(Te(17));if(l)throw new Error(Te(9));try{l=!0,n=r(n,b)}finally{l=!1}return(o=s).forEach(V=>{V()}),b}function y(b){if(typeof b!="function")throw new Error(Te(10));r=b,f({type:Vn.REPLACE})}function w(){let b=p;return{subscribe(R){if(typeof R!="object"||R===null)throw new Error(Te(11));function V(){let k=R;k.next&&k.next(u())}return V(),{unsubscribe:b(V)}},[Ol](){return this}}}return f({type:Vn.INIT}),{dispatch:f,subscribe:p,getState:u,replaceReducer:y,[Ol]:w}}function mh(t){Object.keys(t).forEach(e=>{let i=t[e];if(typeof i(void 0,{type:Vn.INIT})>"u")throw new Error(Te(12));if(typeof i(void 0,{type:Vn.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Te(13))})}function kl(t){let e=Object.keys(t),i={};for(let s=0;s<e.length;s++){let a=e[s];typeof t[a]=="function"&&(i[a]=t[a])}let r=Object.keys(i),n,o;try{mh(i)}catch(s){o=s}return function(a={},l){if(o)throw o;let d=!1,u={};for(let p=0;p<r.length;p++){let f=r[p],y=i[f],w=a[f],T=y(w,l);if(typeof T>"u"){let b=l&&l.type;throw new Error(Te(14))}u[f]=T,d=d||T!==w}return d=d||r.length!==Object.keys(a).length,d?u:a}}function Yr(...t){return t.length===0?e=>e:t.length===1?t[0]:t.reduce((e,i)=>(...r)=>e(i(...r)))}function Dl(...t){return e=>(i,r)=>{let n=e(i,r),o=()=>{throw new Error(Te(15))},s={getState:n.getState,dispatch:(l,...d)=>o(l,...d)},a=t.map(l=>l(s));return o=Yr(...a)(n.dispatch),{...n,dispatch:o}}}function Ll(t){return Bn(t)&&"type"in t&&typeof t.type=="string"}var Bl=Symbol.for("immer-nothing"),Il=Symbol.for("immer-draftable"),Le=Symbol.for("immer-state");function St(t,...e){throw new Error(`[Immer] minified error nr: ${t}. Full error at: https://bit.ly/3cXEKWf`)}var et=Object,ur=et.getPrototypeOf,Wn="constructor",Xn="prototype",Ys="configurable",Kn="enumerable",zn="writable",Zr="value",Ut=t=>!!t&&!!t[Le];function tt(t){return t?Hl(t)||Qn(t)||!!t[Il]||!!t[Wn]?.[Il]||eo(t)||to(t):!1}var gh=et[Xn][Wn].toString(),Ml=new WeakMap;function Hl(t){if(!t||!ra(t))return!1;let e=ur(t);if(e===null||e===et[Xn])return!0;let i=et.hasOwnProperty.call(e,Wn)&&e[Wn];if(i===Object)return!0;if(!dr(i))return!1;let r=Ml.get(i);return r===void 0&&(r=Function.toString.call(i),Ml.set(i,r)),r===gh}function Jn(t,e,i=!0){Qr(t)===0?(i?Reflect.ownKeys(t):et.keys(t)).forEach(n=>{e(n,t[n],t)}):t.forEach((r,n)=>e(n,r,t))}function Qr(t){let e=t[Le];return e?e.type_:Qn(t)?1:eo(t)?2:to(t)?3:0}var Ks=(t,e,i=Qr(t))=>i===2?t.has(e):et[Xn].hasOwnProperty.call(t,e),Zs=(t,e,i=Qr(t))=>i===2?t.get(e):t[e],Gn=(t,e,i,r=Qr(t))=>{r===2?t.set(e,i):r===3?t.add(i):t[e]=i};function yh(t,e){return t===e?t!==0||1/t===1/e:t!==t&&e!==e}var Qn=Array.isArray,eo=t=>t instanceof Map,to=t=>t instanceof Set,ra=t=>typeof t=="object",dr=t=>typeof t=="function",Gs=t=>typeof t=="boolean";function vh(t){let e=+t;return Number.isInteger(e)&&String(e)===t}var Gt=t=>t.copy_||t.base_;var na=t=>t.modified_?t.copy_:t.base_;function Xs(t,e){if(eo(t))return new Map(t);if(to(t))return new Set(t);if(Qn(t))return Array[Xn].slice.call(t);let i=Hl(t);if(e===!0||e==="class_only"&&!i){let r=et.getOwnPropertyDescriptors(t);delete r[Le];let n=Reflect.ownKeys(r);for(let o=0;o<n.length;o++){let s=n[o],a=r[s];a[zn]===!1&&(a[zn]=!0,a[Ys]=!0),(a.get||a.set)&&(r[s]={[Ys]:!0,[zn]:!0,[Kn]:a[Kn],[Zr]:t[s]})}return et.create(ur(t),r)}else{let r=ur(t);if(r!==null&&i)return{...t};let n=et.create(r);return et.assign(n,t)}}function oa(t,e=!1){return io(t)||Ut(t)||!tt(t)||(Qr(t)>1&&et.defineProperties(t,{set:Hn,add:Hn,clear:Hn,delete:Hn}),et.freeze(t),e&&Jn(t,(i,r)=>{oa(r,!0)},!1)),t}function xh(){St(2)}var Hn={[Zr]:xh};function io(t){return t===null||!ra(t)?!0:et.isFrozen(t)}var qn="MapSet",Js="Patches",Pl="ArrayMethods",zl={};function Ci(t){let e=zl[t];return e||St(0,t),e}var Nl=t=>!!zl[t];var Xr,jl=()=>Xr,bh=(t,e)=>({drafts_:[],parent_:t,immer_:e,canAutoFreeze_:!0,unfinalizedDrafts_:0,handledSet_:new Set,processedForPatches_:new Set,mapSetPlugin_:Nl(qn)?Ci(qn):void 0,arrayMethodsPlugin_:Nl(Pl)?Ci(Pl):void 0});function $l(t,e){e&&(t.patchPlugin_=Ci(Js),t.patches_=[],t.inversePatches_=[],t.patchListener_=e)}function Qs(t){ea(t),t.drafts_.forEach(Sh),t.drafts_=null}function ea(t){t===Xr&&(Xr=t.parent_)}var Ul=t=>Xr=bh(Xr,t);function Sh(t){let e=t[Le];e.type_===0||e.type_===1?e.revoke_():e.revoked_=!0}function Fl(t,e){e.unfinalizedDrafts_=e.drafts_.length;let i=e.drafts_[0];if(t!==void 0&&t!==i){i[Le].modified_&&(Qs(e),St(4)),tt(t)&&(t=Vl(e,t));let{patchPlugin_:n}=e;n&&n.generateReplacementPatches_(i[Le].base_,t,e)}else t=Vl(e,i);return wh(e,t,!0),Qs(e),e.patches_&&e.patchListener_(e.patches_,e.inversePatches_),t!==Bl?t:void 0}function Vl(t,e){if(io(e))return e;let i=e[Le];if(!i)return Yn(e,t.handledSet_,t);if(!ro(i,t))return e;if(!i.modified_)return i.base_;if(!i.finalized_){let{callbacks_:r}=i;if(r)for(;r.length>0;)r.pop()(t);Gl(i,t)}return i.copy_}function wh(t,e,i=!1){!t.parent_&&t.immer_.autoFreeze_&&t.canAutoFreeze_&&oa(e,i)}function Wl(t){t.finalized_=!0,t.scope_.unfinalizedDrafts_--}var ro=(t,e)=>t.scope_===e,Eh=[];function Kl(t,e,i,r){let n=Gt(t),o=t.type_;if(r!==void 0&&Zs(n,r,o)===e){Gn(n,r,i,o);return}if(!t.draftLocations_){let a=t.draftLocations_=new Map;Jn(n,(l,d)=>{if(Ut(d)){let u=a.get(d)||[];u.push(l),a.set(d,u)}})}let s=t.draftLocations_.get(e)??Eh;for(let a of s)Gn(n,a,i,o)}function _h(t,e,i){t.callbacks_.push(function(n){let o=e;if(!o||!ro(o,n))return;n.mapSetPlugin_?.fixSetContents(o);let s=na(o);Kl(t,o.draft_??o,s,i),Gl(o,n)})}function Gl(t,e){if(t.modified_&&!t.finalized_&&(t.type_===3||t.type_===1&&t.allIndicesReassigned_||(t.assigned_?.size??0)>0)){let{patchPlugin_:r}=e;if(r){let n=r.getPath(t);n&&r.generatePatches_(t,n,e)}Wl(t)}}function Ah(t,e,i){let{scope_:r}=t;if(Ut(i)){let n=i[Le];ro(n,r)&&n.callbacks_.push(function(){jn(t);let s=na(n);Kl(t,i,s,e)})}else tt(i)&&t.callbacks_.push(function(){let o=Gt(t);t.type_===3?o.has(i)&&Yn(i,r.handledSet_,r):Zs(o,e,t.type_)===i&&r.drafts_.length>1&&(t.assigned_.get(e)??!1)===!0&&t.copy_&&Yn(Zs(t.copy_,e,t.type_),r.handledSet_,r)})}function Yn(t,e,i){return!i.immer_.autoFreeze_&&i.unfinalizedDrafts_<1||Ut(t)||e.has(t)||!tt(t)||io(t)||(e.add(t),Jn(t,(r,n)=>{if(Ut(n)){let o=n[Le];if(ro(o,i)){let s=na(o);Gn(t,r,s,t.type_),Wl(o)}}else tt(n)&&Yn(n,e,i)})),t}function Ch(t,e){let i=Qn(t),r={type_:i?1:0,scope_:e?e.scope_:jl(),modified_:!1,finalized_:!1,assigned_:void 0,parent_:e,base_:t,draft_:null,copy_:null,revoke_:null,isManual_:!1,callbacks_:void 0},n=r,o=Zn;i&&(n=[r],o=Jr);let{revoke:s,proxy:a}=Proxy.revocable(n,o);return r.draft_=a,r.revoke_=s,[a,r]}var Zn={get(t,e){if(e===Le)return t;let i=t.scope_.arrayMethodsPlugin_,r=t.type_===1&&typeof e=="string";if(r&&i?.isArrayOperationMethod(e))return i.createMethodInterceptor(t,e);let n=Gt(t);if(!Ks(n,e,t.type_))return Rh(t,n,e);let o=n[e];if(t.finalized_||!tt(o)||r&&t.operationMethod&&i?.isMutatingArrayMethod(t.operationMethod)&&vh(e))return o;if(o===qs(t.base_,e)||Th(t,e,o)){jn(t);let s=t.type_===1?+e:e,a=ia(t.scope_,o,t,s);return t.copy_[s]=a}return o},has(t,e){return e in Gt(t)},ownKeys(t){return Reflect.ownKeys(Gt(t))},set(t,e,i){let r=ql(Gt(t),e);if(r?.set)return r.set.call(t.draft_,i),!0;if(!t.modified_){let n=qs(Gt(t),e),o=n?.[Le];if(o&&o.base_===i)return t.copy_[e]=i,t.assigned_.set(e,!1),!0;if(yh(i,n)&&(i!==void 0||Ks(t.base_,e,t.type_)))return!0;jn(t),ta(t)}return t.copy_[e]===i&&(i!==void 0||Ks(t.copy_,e,t.type_))||Number.isNaN(i)&&Number.isNaN(t.copy_[e])||(t.copy_[e]=i,t.assigned_.set(e,!0),Ah(t,e,i)),!0},deleteProperty(t,e){return jn(t),qs(t.base_,e)!==void 0||e in t.base_?(t.assigned_.set(e,!1),ta(t)):t.assigned_.delete(e),t.copy_&&delete t.copy_[e],!0},getOwnPropertyDescriptor(t,e){let i=Gt(t),r=Reflect.getOwnPropertyDescriptor(i,e);return r&&{[zn]:!0,[Ys]:t.type_!==1||e!=="length",[Kn]:r[Kn],[Zr]:i[e]}},defineProperty(){St(11)},getPrototypeOf(t){return ur(t.base_)},setPrototypeOf(){St(12)}},Jr={};for(let t in Zn){let e=Zn[t];Jr[t]=function(){let i=arguments;return i[0]=i[0][0],e.apply(this,i)}}Jr.deleteProperty=function(t,e){return Jr.set.call(this,t,e,void 0)};Jr.set=function(t,e,i){return Zn.set.call(this,t[0],e,i,t[0])};function qs(t,e){let i=t[Le];return(i?Gt(i):t)[e]}function Th(t,e,i){return t.type_!==1||!t.allIndicesReassigned_||t.assigned_?.get(e)||!tt(i)||i[Le]?!1:t.baseRefs_.has(i)}function Rh(t,e,i){let r=ql(e,i);return r?Zr in r?r[Zr]:r.get?.call(t.draft_):void 0}function ql(t,e){if(!(e in t))return;let i=ur(t);for(;i;){let r=Object.getOwnPropertyDescriptor(i,e);if(r)return r;i=ur(i)}}function ta(t){t.modified_||(t.modified_=!0,t.parent_&&ta(t.parent_))}function jn(t){t.copy_||(t.assigned_=new Map,t.copy_=Xs(t.base_,t.scope_.immer_.useStrictShallowCopy_))}var Oh=class{constructor(t){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!1,this.produce=(e,i,r)=>{if(dr(e)&&!dr(i)){let o=i;i=e;let s=this;return function(l=o,...d){return s.produce(l,u=>i.call(this,u,...d))}}dr(i)||St(6),r!==void 0&&!dr(r)&&St(7);let n;if(tt(e)){let o=Ul(this),s=ia(o,e,void 0),a=!0;try{n=i(s),a=!1}finally{a?Qs(o):ea(o)}return $l(o,r),Fl(n,o)}else if(!e||!ra(e)){if(n=i(e),n===void 0&&(n=e),n===Bl&&(n=void 0),this.autoFreeze_&&oa(n,!0),r){let o=[],s=[];Ci(Js).generateReplacementPatches_(e,n,{patches_:o,inversePatches_:s}),r(o,s)}return n}else St(1,e)},this.produceWithPatches=(e,i)=>{if(dr(e))return(s,...a)=>this.produceWithPatches(s,l=>e(l,...a));let r,n;return[this.produce(e,i,(s,a)=>{r=s,n=a}),r,n]},Gs(t?.autoFreeze)&&this.setAutoFreeze(t.autoFreeze),Gs(t?.useStrictShallowCopy)&&this.setUseStrictShallowCopy(t.useStrictShallowCopy),Gs(t?.useStrictIteration)&&this.setUseStrictIteration(t.useStrictIteration)}createDraft(t){tt(t)||St(8),Ut(t)&&(t=Yl(t));let e=Ul(this),i=ia(e,t,void 0);return i[Le].isManual_=!0,ea(e),i}finishDraft(t,e){let i=t&&t[Le];(!i||!i.isManual_)&&St(9);let{scope_:r}=i;return $l(r,e),Fl(void 0,r)}setAutoFreeze(t){this.autoFreeze_=t}setUseStrictShallowCopy(t){this.useStrictShallowCopy_=t}setUseStrictIteration(t){this.useStrictIteration_=t}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(t,e){let i;for(i=e.length-1;i>=0;i--){let n=e[i];if(n.path.length===0&&n.op==="replace"){t=n.value;break}}i>-1&&(e=e.slice(i+1));let r=Ci(Js).applyPatches_;return Ut(t)?r(t,e):this.produce(t,n=>r(n,e))}};function ia(t,e,i,r){let[n,o]=eo(e)?Ci(qn).proxyMap_(e,i):to(e)?Ci(qn).proxySet_(e,i):Ch(e,i);return(i?.scope_??jl()).drafts_.push(n),o.callbacks_=i?.callbacks_??[],o.key_=r,i&&r!==void 0?_h(i,o,r):o.callbacks_.push(function(l){l.mapSetPlugin_?.fixSetContents(o);let{patchPlugin_:d}=l;o.modified_&&d&&d.generatePatches_(o,[],l)}),n}function Yl(t){return Ut(t)||St(10,t),Zl(t)}function Zl(t){if(!tt(t)||io(t))return t;let e=t[Le],i,r=!0;if(e){if(!e.modified_)return e.base_;e.finalized_=!0,i=Xs(t,e.scope_.immer_.useStrictShallowCopy_),r=e.scope_.immer_.shouldUseStrictIteration()}else i=Xs(t,!0);return Jn(i,(n,o)=>{Gn(i,n,Zl(o))},r),e&&(e.finalized_=!1),i}var kh=globalThis.Iterator,ey=typeof kh?.from=="function";var Dh=new Oh,sa=Dh.produce;function Xl(t){return({dispatch:i,getState:r})=>n=>o=>typeof o=="function"?o(i,r,t):n(o)}var Jl=Xl(),Ql=Xl;var Lh=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Yr:Yr.apply(null,arguments)},ay=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(t){return t}},Ih=t=>t&&typeof t.match=="function";function li(t,e){function i(...r){if(e){let n=e(...r);if(!n)throw new Error(qt(0));return{type:t,payload:n.payload,..."meta"in n&&{meta:n.meta},..."error"in n&&{error:n.error}}}return{type:t,payload:r[0]}}return i.toString=()=>`${t}`,i.type=t,i.match=r=>Ll(r)&&r.type===t,i}var nc=class en extends Array{constructor(...e){super(...e),Object.setPrototypeOf(this,en.prototype)}static get[Symbol.species](){return en}concat(...e){return super.concat.apply(this,e)}prepend(...e){return e.length===1&&Array.isArray(e[0])?new en(...e[0].concat(this)):new en(...e.concat(this))}};function ec(t){return tt(t)?sa(t,()=>{}):t}function no(t,e,i){return t.has(e)?t.get(e):t.set(e,i(e)).get(e)}function Mh(t){return typeof t=="boolean"}var Ph=()=>function(e){let{thunk:i=!0,immutableCheck:r=!0,serializableCheck:n=!0,actionCreatorCheck:o=!0}=e??{},s=new nc;return i&&(Mh(i)?s.push(Jl):s.push(Ql(i.extraArgument))),s},Nh="RTK_autoBatch";var tc=t=>e=>{setTimeout(e,t)},$h=(t,e)=>i=>{let r=!1,n=()=>{r||(r=!0,cancelAnimationFrame(o),clearTimeout(s),i())},o=t(n),s=setTimeout(n,e)},Uh=(t={type:"raf"})=>e=>(...i)=>{let r=e(...i),n=!0,o=!1,s=!1,a=new Set,l=t.type==="tick"?queueMicrotask:t.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?$h(window.requestAnimationFrame,100):tc(10):t.type==="callback"?t.queueNotification:tc(t.timeout),d=()=>{s=!1,o&&(o=!1,a.forEach(u=>u()))};return Object.assign({},r,{subscribe(u){let p=()=>n&&u(),f=r.subscribe(p);return a.add(u),()=>{f(),a.delete(u)}},dispatch(u){try{return n=!u?.meta?.[Nh],o=!n,o&&(s||(s=!0,l(d))),r.dispatch(u)}finally{n=!0}}})},Fh=t=>function(i){let{autoBatch:r=!0}=i??{},n=new nc(t);return r&&n.push(Uh(typeof r=="object"?r:void 0)),n};function oc(t){let e=Ph(),{reducer:i=void 0,middleware:r,devTools:n=!0,duplicateMiddlewareCheck:o=!0,preloadedState:s=void 0,enhancers:a=void 0}=t||{},l;if(typeof i=="function")l=i;else if(Bn(i))l=kl(i);else throw new Error(qt(1));let d;typeof r=="function"?d=r(e):d=e();let u=Yr;n&&(u=Lh({trace:!1,...typeof n=="object"&&n}));let p=Dl(...d),f=Fh(p),y=typeof a=="function"?a(f):f(),w=u(...y);return Ws(l,s,w)}function sc(t){let e={},i=[],r,n={addCase(o,s){let a=typeof o=="string"?o:o.type;if(!a)throw new Error(qt(28));if(a in e)throw new Error(qt(29));return e[a]=s,n},addAsyncThunk(o,s){return s.pending&&(e[o.pending.type]=s.pending),s.rejected&&(e[o.rejected.type]=s.rejected),s.fulfilled&&(e[o.fulfilled.type]=s.fulfilled),s.settled&&i.push({matcher:o.settled,reducer:s.settled}),n},addMatcher(o,s){return i.push({matcher:o,reducer:s}),n},addDefaultCase(o){return r=o,n}};return t(n),[e,i,r]}function Vh(t){return typeof t=="function"}function Bh(t,e){let[i,r,n]=sc(e),o;if(Vh(t))o=()=>ec(t());else{let a=ec(t);o=()=>a}function s(a=o(),l){let d=[i[l.type],...r.filter(({matcher:u})=>u(l)).map(({reducer:u})=>u)];return d.filter(u=>!!u).length===0&&(d=[n]),d.reduce((u,p)=>{if(p)if(Ut(u)){let y=p(u,l);return y===void 0?u:y}else{if(tt(u))return sa(u,f=>p(f,l));{let f=p(u,l);if(f===void 0){if(u===null)return u;throw Error("A case reducer on a non-draftable value must not return undefined")}return f}}return u},a)}return s.getInitialState=o,s}var Hh=(t,e)=>Ih(t)?t.match(e):t(e);function zh(...t){return e=>t.some(i=>Hh(i,e))}var jh="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Wh=(t=21)=>{let e="",i=t;for(;i--;)e+=jh[Math.random()*64|0];return e},Kh=["name","message","stack","code"],aa=class{constructor(t,e){this.payload=t,this.meta=e}payload;meta;_type},ic=class{constructor(t,e){this.payload=t,this.meta=e}payload;meta;_type},Gh=t=>{if(typeof t=="object"&&t!==null){let e={};for(let i of Kh)typeof t[i]=="string"&&(e[i]=t[i]);return e}return{message:String(t)}},rc="External signal was aborted",qh=(()=>{function t(e,i,r){let n=li(e+"/fulfilled",(l,d,u,p)=>({payload:l,meta:{...p||{},arg:u,requestId:d,requestStatus:"fulfilled"}})),o=li(e+"/pending",(l,d,u)=>({payload:void 0,meta:{...u||{},arg:d,requestId:l,requestStatus:"pending"}})),s=li(e+"/rejected",(l,d,u,p,f)=>({payload:p,error:(r&&r.serializeError||Gh)(l||"Rejected"),meta:{...f||{},arg:u,requestId:d,rejectedWithValue:!!p,requestStatus:"rejected",aborted:l?.name==="AbortError",condition:l?.name==="ConditionError"}}));function a(l,{signal:d}={}){return(u,p,f)=>{let y=r?.idGenerator?r.idGenerator(l):Wh(),w=new AbortController,T,b;function R(E){b=E,w.abort()}d&&(d.aborted?R(rc):d.addEventListener("abort",()=>R(rc),{once:!0}));let V=(async function(){let E;try{let N=r?.condition?.(l,{getState:p,extra:f});if(Zh(N)&&(N=await N),N===!1||w.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};let ae=new Promise((q,le)=>{T=()=>{le({name:"AbortError",message:b||"Aborted"})},w.signal.addEventListener("abort",T,{once:!0})});u(o(y,l,r?.getPendingMeta?.({requestId:y,arg:l},{getState:p,extra:f}))),E=await Promise.race([ae,Promise.resolve(i(l,{dispatch:u,getState:p,extra:f,requestId:y,signal:w.signal,abort:R,rejectWithValue:((q,le)=>new aa(q,le)),fulfillWithValue:((q,le)=>new ic(q,le))})).then(q=>{if(q instanceof aa)throw q;return q instanceof ic?n(q.payload,y,l,q.meta):n(q,y,l)})])}catch(N){E=N instanceof aa?s(null,y,l,N.payload,N.meta):s(N,y,l)}finally{T&&w.signal.removeEventListener("abort",T)}return r&&!r.dispatchConditionRejection&&s.match(E)&&E.meta.condition||u(E),E})();return Object.assign(V,{abort:R,requestId:y,arg:l,unwrap(){return V.then(Yh)}})}}return Object.assign(a,{pending:o,rejected:s,fulfilled:n,settled:zh(s,n),typePrefix:e})}return t.withTypes=()=>t,t})();function Yh(t){if(t.meta&&t.meta.rejectedWithValue)throw t.payload;if(t.error)throw t.error;return t.payload}function Zh(t){return t!==null&&typeof t=="object"&&typeof t.then=="function"}var ac=Symbol.for("rtk-slice-createasyncthunk"),cy={[ac]:qh};function Xh(t,e){return`${t}/${e}`}function Jh({creators:t}={}){let e=t?.asyncThunk?.[ac];return function(r){let{name:n,reducerPath:o=n}=r;if(!n)throw new Error(qt(11));typeof process<"u";let s=(typeof r.reducers=="function"?r.reducers(em()):r.reducers)||{},a=Object.keys(s),l={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},d={addCase(E,k){let N=typeof E=="string"?E:E.type;if(!N)throw new Error(qt(12));if(N in l.sliceCaseReducersByType)throw new Error(qt(13));return l.sliceCaseReducersByType[N]=k,d},addMatcher(E,k){return l.sliceMatchers.push({matcher:E,reducer:k}),d},exposeAction(E,k){return l.actionCreators[E]=k,d},exposeCaseReducer(E,k){return l.sliceCaseReducersByName[E]=k,d}};a.forEach(E=>{let k=s[E],N={reducerName:E,type:Xh(n,E),createNotation:typeof r.reducers=="function"};im(k)?nm(N,k,d,e):tm(N,k,d)});function u(){let[E={},k=[],N=void 0]=typeof r.extraReducers=="function"?sc(r.extraReducers):[r.extraReducers],ae={...E,...l.sliceCaseReducersByType};return Bh(r.initialState,q=>{for(let le in ae)q.addCase(le,ae[le]);for(let le of l.sliceMatchers)q.addMatcher(le.matcher,le.reducer);for(let le of k)q.addMatcher(le.matcher,le.reducer);N&&q.addDefaultCase(N)})}let p=E=>E,f=new Map,y=new WeakMap,w;function T(E,k){return w||(w=u()),w(E,k)}function b(){return w||(w=u()),w.getInitialState()}function R(E,k=!1){function N(q){let le=q[E];return typeof le>"u"&&k&&(le=no(y,N,b)),le}function ae(q=p){let le=no(f,k,()=>new WeakMap);return no(le,q,()=>{let Hr={};for(let[ct,Ei]of Object.entries(r.selectors??{}))Hr[ct]=Qh(Ei,q,()=>no(y,q,b),k);return Hr})}return{reducerPath:E,getSelectors:ae,get selectors(){return ae(N)},selectSlice:N}}let V={name:n,reducer:T,actions:l.actionCreators,caseReducers:l.sliceCaseReducersByName,getInitialState:b,...R(o),injectInto(E,{reducerPath:k,...N}={}){let ae=k??o;return E.inject({reducerPath:ae,reducer:T},N),{...V,...R(ae,!0)}}};return V}}function Qh(t,e,i,r){function n(o,...s){let a=e(o);return typeof a>"u"&&r&&(a=i()),t(a,...s)}return n.unwrapped=t,n}var lc=Jh();function em(){function t(e,i){return{_reducerDefinitionType:"asyncThunk",payloadCreator:e,...i}}return t.withTypes=()=>t,{reducer(e){return Object.assign({[e.name](...i){return e(...i)}}[e.name],{_reducerDefinitionType:"reducer"})},preparedReducer(e,i){return{_reducerDefinitionType:"reducerWithPrepare",prepare:e,reducer:i}},asyncThunk:t}}function tm({type:t,reducerName:e,createNotation:i},r,n){let o,s;if("reducer"in r){if(i&&!rm(r))throw new Error(qt(17));o=r.reducer,s=r.prepare}else o=r;n.addCase(t,o).exposeCaseReducer(e,o).exposeAction(e,s?li(t,s):li(t))}function im(t){return t._reducerDefinitionType==="asyncThunk"}function rm(t){return t._reducerDefinitionType==="reducerWithPrepare"}function nm({type:t,reducerName:e},i,r,n){if(!n)throw new Error(qt(18));let{payloadCreator:o,fulfilled:s,pending:a,rejected:l,settled:d,options:u}=i,p=n(t,o,u);r.exposeAction(e,p),s&&r.addCase(p.fulfilled,s),a&&r.addCase(p.pending,a),l&&r.addCase(p.rejected,l),d&&r.addMatcher(p.settled,d),r.exposeCaseReducer(e,{fulfilled:s||oo,pending:a||oo,rejected:l||oo,settled:d||oo})}function oo(){}var cc="listener",dc="completed",uc="cancelled",dy=`task-${uc}`,uy=`task-${dc}`,py=`${cc}-${uc}`,fy=`${cc}-${dc}`;var{assign:pc}=Object;var la="listenerMiddleware";var om=pc(li(`${la}/add`),{withTypes:()=>om}),hy=li(`${la}/removeAll`),sm=pc(li(`${la}/remove`),{withTypes:()=>sm});function qt(t){return`Minified Redux Toolkit error #${t}; visit https://redux-toolkit.js.org/Errors?code=${t} for the full message or use the non-minified dev environment for full errors. `}var am=Mn(Symbol("withEventBus"),function(t,e){return class extends t{constructor(){super(...arguments),this.eventBus=e??document.createElement("span")}addEventListener(i,r,n){this.eventBus.addEventListener(i,r,n)}dispatchEvent(i){return this.eventBus.dispatchEvent(i)}removeEventListener(i,r,n){this.eventBus.removeEventListener(i,r,n)}}}),so=class extends am(Object){};window.ftReduxStores||(window.ftReduxStores={});var fc=class t extends so{static get(e){var i;let r=typeof e=="string"?e:e.name,n=typeof e=="string"?void 0:e,o=window.ftReduxStores[r];if(Fn(o))return o;if(n==null)return;let s=lc({...n,reducers:(i=n.reducers)!==null&&i!==void 0?i:{}}),a=oc({reducer:(l,d)=>{if(d.type==="CLEAR_FT_REDUX_STORE"){let u=Kr(s.getInitialState());for(let p of d.keeping)u[p]=(l??u)[p];return u}else if(typeof d.type=="string"&&d.type.startsWith("DEFAULT_VALUE_SETTER__"))return{...l,...d.overwrites};return s.reducer(l,d)}});return window.ftReduxStores[n.name]=new t(s,a,n.eventBus)}constructor(e,i,r){super(),this.reduxSlice=e,this.reduxStore=i,this.isFtReduxStore=!0,this.commands=new Pn,this.injectInto=(o,s)=>this.reduxSlice.injectInto(o,s),this.selectSlice=o=>this.reduxSlice.selectSlice(o);let n=o=>o!=null?JSON.parse(JSON.stringify(o)):o;this.actions=new Proxy(this.reduxSlice.actions,{get:(o,s,a)=>{let l=s,d=o[l];return d?(...u)=>{let p=d(...u.map(n));return this.reduxStore.dispatch(p),p}:u=>{let p=l,f=this.getState()[p];ar(f,u)||this.setState({[p]:n(u)})}}}),this.eventBus=r??this.eventBus}clear(){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:[]})}clearKeeping(...e){this.reduxStore.dispatch({type:"CLEAR_FT_REDUX_STORE",keeping:e})}setState(e){this.reduxStore.dispatch({type:"DEFAULT_VALUE_SETTER__"+Object.keys(e).join("_"),overwrites:e})}get dispatch(){throw new Error("Don't use this method, actions are automatically dispatched when called.")}[Symbol.observable](){return this.reduxStore[Symbol.observable]()}getState(){return this.reduxStore.getState()}replaceReducer(e){throw new Error("Not implemented yet.")}subscribe(e){return this.reduxStore.subscribe(e)}get name(){return this.reduxSlice.name}get reducer(){return this.reduxSlice.reducer}get caseReducers(){return this.reduxSlice.caseReducers}getInitialState(){return this.reduxSlice.getInitialState()}get selectors(){return this.reduxSlice.selectors}get reducerPath(){return this.reduxSlice.reducerPath}getSelectors(){return this.reduxSlice.getSelectors()}};var ao=class{static format(e,i,r,n,o){return window.moment?window.moment(e).locale(i).format(this.getMomentDateFormat(r,n,!!o)):this.getIntlDateTime(e,i,r,n,!!o)}static getMomentDateFormat(e,i,r){return r?"LT":e?i?"lll":"ll":i?"L LT":"L"}static getIntlDateTime(e,i,r,n,o){let s=typeof e=="string"?new Date(e):e,a=new Intl.DateTimeFormat(i,{dateStyle:r?"medium":"short"}).format(s),l=new Intl.DateTimeFormat(i,{timeStyle:"short"}).format(s);return o?l:n?`${a} ${l}`:a}static getTimezoneAsString(){let e=r=>String(Math.floor(r)).padStart(2,"0"),i=new Date().getTimezoneOffset();return`${i<0?"+":"-"}${e(Math.abs(i)/60)}:${e(Math.abs(i)%60)}`}};var lo=c(h()),lm="ft-app-info",wt=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};wt.eventName="authentication-change";var Ti=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:e})}};Ti.eventName="ui-locale-changed";var cm={session:(t,e)=>{(0,lo.deepEqual)(t.session,e.payload)||(t.session=e.payload,setTimeout(()=>x.dispatchEvent(new wt(e.payload)),0))}},x=lo.FtReduxStore.get({name:lm,reducers:cm,initialState:{baseUrl:void 0,tenantId:void 0,apiIntegrationIdentifier:void 0,apiIntegrationAppVersion:void 0,uiLocale:document.documentElement.lang||"en-US",availableContentLocales:[],localesConfiguration:void 0,metadataConfiguration:void 0,privacyPolicyConfiguration:void 0,editorMode:!1,noCustom:!1,noCustomComponent:!1,noCustomCode:!1,session:void 0,openExternalDocumentInNewTab:!1,navigatorOnline:!0,forcedOffline:!1,authenticationRequired:!1,stickyFilters:void 0}});var hc=c(h()),co=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},mc=(0,hc.applyMixinOnce)(Symbol("withDateFormat"),function(t){class e extends t{constructor(...r){super(r),this.useLongDateFormat=!1,this.useDateTimeFormat=!1,this.metadataDescriptors=[],this.uiLocale="en-US",this.addStore(x)}dateFormatOptionsChanged(r){return r.has("metadataDescriptors")||r.has("useLongDateFormat")||r.has("useDateTimeFormat")||r.has("uiLocale")}getDateFormatter(r){var n,o;return((o=(n=this.metadataDescriptors.find(a=>a.key===r))===null||n===void 0?void 0:n.date)!==null&&o!==void 0?o:!1)?a=>ao.format(a,this.uiLocale,this.useLongDateFormat,this.useDateTimeFormat):void 0}}return co([(0,ca.property)({type:Boolean})],e.prototype,"useLongDateFormat",void 0),co([(0,ca.property)({type:Boolean})],e.prototype,"useDateTimeFormat",void 0),co([zs({store:x.name,selector:i=>{var r,n;return(n=(r=i.metadataConfiguration)===null||r===void 0?void 0:r.descriptors)!==null&&n!==void 0?n:[]}})],e.prototype,"metadataDescriptors",void 0),co([zs({store:x.name})],e.prototype,"uiLocale",void 0),e});var gc;(function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"})(gc||(gc={}));var yc;(function(t){t.OFFICIAL="OFFICIAL",t.PERSONAL="PERSONAL",t.SHARED="SHARED"})(yc||(yc={}));var vc;(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"})(vc||(vc={}));var xc;(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"})(xc||(xc={}));var bc;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})(bc||(bc={}));var Sc;(function(t){t.VALUE="VALUE",t.DATE="DATE",t.RANGE="RANGE"})(Sc||(Sc={}));var wc;(function(t){t.OFFICIAL="OFFICIAL",t.AI="AI"})(wc||(wc={}));var Ec;(function(t){t.BOOKMARK__CREATE="BOOKMARK__CREATE",t.BOOKMARK__DELETE="BOOKMARK__DELETE",t.CASE_DEFLECTION__START="CASE_DEFLECTION__START",t.CASE_DEFLECTION__OPEN_TICKET="CASE_DEFLECTION__OPEN_TICKET",t.CASE_DEFLECTION__RATE="CASE_DEFLECTION__RATE",t.CHATBOT__RATE="CHATBOT__RATE",t.COLLECTION__CREATE="COLLECTION__CREATE",t.COLLECTION__UPDATE="COLLECTION__UPDATE",t.COLLECTION__DELETE="COLLECTION__DELETE",t.CUSTOM_EVENT__TRIGGER="CUSTOM_EVENT__TRIGGER",t.DOCUMENT__ON_DEMAND_TRANSLATE="DOCUMENT__ON_DEMAND_TRANSLATE",t.DOCUMENT__DOWNLOAD="DOCUMENT__DOWNLOAD",t.DOCUMENT__PRINT="DOCUMENT__PRINT",t.DOCUMENT__PROCESS="DOCUMENT__PROCESS",t.DOCUMENT__RATE="DOCUMENT__RATE",t.DOCUMENT__SEARCH="DOCUMENT__SEARCH",t.DOCUMENT__START_DISPLAY="DOCUMENT__START_DISPLAY",t.DOCUMENT__UNRATE="DOCUMENT__UNRATE",t.FEEDBACK__SEND="FEEDBACK__SEND",t.AI__COMPLETED_QUERY="AI__COMPLETED_QUERY",t.AI__RATE="AI__RATE",t.AI_CASE_DEFLECTION__START="AI_CASE_DEFLECTION__START",t.AI_CASE_DEFLECTION__OPEN_TICKET="AI_CASE_DEFLECTION__OPEN_TICKET",t.KHUB__PROCESS="KHUB__PROCESS",t.KHUB__SEARCH="KHUB__SEARCH",t.LABELS__DOWNLOAD="LABELS__DOWNLOAD",t.LINK__SHARE="LINK__SHARE",t.PAGE__DISPLAY="PAGE__DISPLAY",t.PERSONAL_BOOK__CREATE="PERSONAL_BOOK__CREATE",t.PERSONAL_BOOK__DELETE="PERSONAL_BOOK__DELETE",t.PERSONAL_BOOK__UPDATE="PERSONAL_BOOK__UPDATE",t.PERSONAL_TOPIC__CREATE="PERSONAL_TOPIC__CREATE",t.PERSONAL_TOPIC__UPDATE="PERSONAL_TOPIC__UPDATE",t.PERSONAL_TOPIC__DELETE="PERSONAL_TOPIC__DELETE",t.SAVED_SEARCH__CREATE="SAVED_SEARCH__CREATE",t.SAVED_SEARCH__DELETE="SAVED_SEARCH__DELETE",t.SAVED_SEARCH__UPDATE="SAVED_SEARCH__UPDATE",t.SEARCH_PAGE__SELECT="SEARCH_PAGE__SELECT",t.SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU="SEARCH_RESULT__OPEN_BROWSER_CONTEXT_MENU",t.TOPIC__AI_TRANSLATE="TOPIC__AI_TRANSLATE",t.TOPIC__RATE="TOPIC__RATE",t.TOPIC__START_DISPLAY="TOPIC__START_DISPLAY",t.TOPIC__UNRATE="TOPIC__UNRATE",t.USER__LOGIN="USER__LOGIN",t.USER__LOGOUT="USER__LOGOUT",t.HEARTBEAT="HEARTBEAT"})(Ec||(Ec={}));var _c;(function(t){t.STANDARD="STANDARD",t.STRUCTURAL="STRUCTURAL"})(_c||(_c={}));var Ac;(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"})(Ac||(Ac={}));var Cc;(function(t){t.HOMEPAGE="HOMEPAGE",t.CUSTOM="CUSTOM",t.HEADER="HEADER",t.READER="READER",t.TOPIC_TEMPLATE="TOPIC_TEMPLATE",t.SEARCH="SEARCH",t.SEARCH_RESULT="SEARCH_RESULT",t.SEARCH_ANNOUNCEMENT="SEARCH_ANNOUNCEMENT",t.LINK_PREVIEW="LINK_PREVIEW",t.UD_VIEWER="UD_VIEWER",t.ASSET_VIEWER="ASSET_VIEWER"})(Cc||(Cc={}));var Tc;(function(t){t.CLASSIC="CLASSIC",t.CUSTOM="CUSTOM",t.DESIGNER="DESIGNER"})(Tc||(Tc={}));var Rc;(function(t){t.AND="AND",t.OR="OR",t.MONOVALUED="MONOVALUED"})(Rc||(Rc={}));var Oc;(function(t){t.NONE="NONE",t.ALPHABET="ALPHABET",t.VERSION="VERSION"})(Oc||(Oc={}));var _e;(function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"})(_e||(_e={}));var kc;(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"})(kc||(kc={}));var Dc;(function(t){t.OPTIONAL="OPTIONAL",t.MANDATORY="MANDATORY"})(Dc||(Dc={}));var Lc;(function(t){t.ASC="ASC",t.DESC="DESC"})(Lc||(Lc={}));var Ic;(function(t){t.ALPHA="ALPHA",t.NATURAL="NATURAL"})(Ic||(Ic={}));var Mc;(function(t){t.EVERYWHERE="EVERYWHERE",t.TITLE_ONLY="TITLE_ONLY",t.NONE="NONE"})(Mc||(Mc={}));var Pc;(function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK",t.SHARED_BOOK="SHARED_BOOK",t.HTML_PACKAGE="HTML_PACKAGE"})(Pc||(Pc={}));var uo;(function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"})(uo||(uo={}));var Nc;(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"})(Nc||(Nc={}));var $c;(function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_QUARTER="LAST_QUARTER",t.LAST_YEAR="LAST_YEAR"})($c||($c={}));var Uc;(function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.HTML_PACKAGE="HTML_PACKAGE",t.HTML_PACKAGE_PAGE="HTML_PACKAGE_PAGE"})(Uc||(Uc={}));var Fc;(function(t){t.DEFAULT="DEFAULT",t.DOCUMENTS="DOCUMENTS",t.ALL_TOPICS="ALL_TOPICS",t.TOPICS_AND_UNSTRUCTURED_DOCUMENTS="TOPICS_AND_UNSTRUCTURED_DOCUMENTS"})(Fc||(Fc={}));var Vc;(function(t){t.PLAIN_TEXT="PLAIN_TEXT",t.LOCALIZED_OFFICIAL="LOCALIZED_OFFICIAL",t.LOCALIZED_CUSTOM="LOCALIZED_CUSTOM"})(Vc||(Vc={}));var ie;(function(t){t.PERSONAL_BOOK_USER="PERSONAL_BOOK_USER",t.PERSONAL_BOOK_SHARE_USER="PERSONAL_BOOK_SHARE_USER",t.HTML_EXPORT_USER="HTML_EXPORT_USER",t.PDF_EXPORT_USER="PDF_EXPORT_USER",t.SAVED_SEARCH_USER="SAVED_SEARCH_USER",t.COLLECTION_USER="COLLECTION_USER",t.OFFLINE_USER="OFFLINE_USER",t.ANALYTICS_USER="ANALYTICS_USER",t.BETA_USER="BETA_USER",t.DEBUG_USER="DEBUG_USER",t.PRINT_USER="PRINT_USER",t.RATING_USER="RATING_USER",t.FEEDBACK_USER="FEEDBACK_USER",t.GENERATIVE_AI_USER="GENERATIVE_AI_USER",t.GENERATIVE_AI_EXPORT_USER="GENERATIVE_AI_EXPORT_USER",t.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.BEHAVIOR_DATA_USER="BEHAVIOR_DATA_USER",t.ANNOUNCEMENT_ADMIN="ANNOUNCEMENT_ADMIN",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN"})(ie||(ie={}));var dt;(function(t){t.SEARCHES="SEARCHES",t.BOOKMARKS="BOOKMARKS",t.BOOKS="BOOKS",t.COLLECTIONS="COLLECTIONS"})(dt||(dt={}));var Bc;(function(t){t.UNAUTHENTICATED="UNAUTHENTICATED",t.USER_INCOMPLETE="USER_INCOMPLETE",t.MFA_REQUIRED="MFA_REQUIRED",t.AUTHENTICATED="AUTHENTICATED"})(Bc||(Bc={}));var Hc;(function(t){t.UNREACHABLE="UNREACHABLE",t.UNAUTHORIZED="UNAUTHORIZED",t.FORBIDDEN="FORBIDDEN",t.INCOMPATIBLE="INCOMPATIBLE",t.FAILED="FAILED",t.OK="OK"})(Hc||(Hc={}));var zc;(function(t){t.VALID="VALID",t.INVALID="INVALID"})(zc||(zc={}));var jc;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SUMMARY="SUMMARY",t.SEMANTIC_SEARCH="SEMANTIC_SEARCH",t.CHATBOT_INSTRUCTIONS="CHATBOT_INSTRUCTIONS",t.DOCUMENTATION="DOCUMENTATION",t.OTHER="OTHER"})(jc||(jc={}));var Wc;(function(t){t.INACCURATE="INACCURATE",t.INCOMPLETE="INCOMPLETE",t.OFF_TOPIC="OFF_TOPIC",t.IRRELEVANT_SOURCES="IRRELEVANT_SOURCES",t.SLOW="SLOW",t.OTHER="OTHER"})(Wc||(Wc={}));var Kc;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(Kc||(Kc={}));var Gc;(function(t){t.JSON="JSON",t.TEXT="TEXT"})(Gc||(Gc={}));var qc;(function(t){t.TEXT="TEXT",t.HTML="HTML"})(qc||(qc={}));var Yc;(function(t){t.IN_PROGRESS="IN_PROGRESS",t.ERROR="ERROR",t.DONE="DONE"})(Yc||(Yc={}));var Zc;(function(t){t.HTML="HTML",t.MARKDOWN="MARKDOWN"})(Zc||(Zc={}));var Xc;(function(t){t.SOURCES="SOURCES",t.ENRICH_AND_CLEAN="ENRICH_AND_CLEAN",t.VOCABULARIES="VOCABULARIES",t.METADATA="METADATA",t.PRETTY_URL="PRETTY_URL",t.ACCESS_RULE="ACCESS_RULE",t.DESIGNED_PAGES="DESIGNED_PAGES",t.THEME_STUDIO="THEME_STUDIO",t.PORTAL_GENERAL="PORTAL_GENERAL",t.ASSETS="ASSETS",t.CODE_LIBRARY="CODE_LIBRARY",t.THEME="THEME",t.CONTENT_STYLES="CONTENT_STYLES",t.HOMEPAGE="HOMEPAGE",t.CLASSIC_SEARCH_PAGE="CLASSIC_SEARCH_PAGE",t.CLASSIC_READER_PAGE="CLASSIC_READER_PAGE",t.PORTAL_METADATA="PORTAL_METADATA",t.LANGUAGES="LANGUAGES",t.PRINT_TEMPLATES="PRINT_TEMPLATES",t.OFFLINE="OFFLINE",t.CUSTOM_JS="CUSTOM_JS",t.CONFIDENTIALITY="CONFIDENTIALITY",t.NOTIFICATIONS="NOTIFICATIONS"})(Xc||(Xc={}));var po;(function(t){t.MAP="MAP",t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT"})(po||(po={}));var dm={[ie.PERSONAL_BOOK_SHARE_USER]:[ie.PERSONAL_BOOK_USER],[ie.HTML_EXPORT_USER]:[ie.PERSONAL_BOOK_USER],[ie.PDF_EXPORT_USER]:[ie.PERSONAL_BOOK_USER],[ie.KHUB_ADMIN]:[ie.CONTENT_PUBLISHER],[ie.ADMIN]:[ie.KHUB_ADMIN,ie.USERS_ADMIN,ie.PORTAL_ADMIN,ie.BEHAVIOR_DATA_USER],[ie.GENERATIVE_AI_EXPORT_USER]:[ie.GENERATIVE_AI_USER]};function Jc(t,e){return t===e||(dm[t]??[]).some(i=>Jc(i,e))}function tn(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(r=>Jc(r,e))}var yo=c(h());var da=c(h());var Ft=class t{static get(e){let{baseUrl:i,apiIntegrationIdentifier:r}=x.getState(),n=e??r;if(i&&n&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(i,n,!0)}static await(e){return new Promise(i=>{let r=t.get(e);if(r)i(r);else{let n=x.subscribe(()=>{r=t.get(e),r&&(n(),i(r))})}})}};var pr=class{constructor(e){this.overrideApi=e}get api(){var e;return(e=this.overrideApi)!==null&&e!==void 0?e:Ft.get()}get awaitApi(){return this.overrideApi?Promise.resolve(this.overrideApi):Ft.await()}};var Re=class extends pr{constructor(e=!0,i){var r;super(i),this.sortObjectFields=(o,s)=>typeof s!="object"||s==null||Array.isArray(s)?s:Object.fromEntries(Object.entries(s).sort(([a],[l])=>a.localeCompare(l)));let n=this.constructor;n.commonCache=(r=n.commonCache)!==null&&r!==void 0?r:new da.CacheRegistry,this.cache=e?n.commonCache:new da.CacheRegistry}clearCache(){this.cache.clearAll()}hash(e){return String(Array.from(JSON.stringify(e,this.sortObjectFields)).reduce((i,r)=>0|31*i+r.charCodeAt(0),0))}};var fo=class extends Re{async listMySearches(){let{session:e}=x.getState();return tn(e,ie.SAVED_SEARCH_USER)?this.cache.get("my-searches",async()=>(await this.awaitApi).listMySearches(e.profile.userId),300*1e3):[]}};var ho=class extends Re{async listMyBookmarks(){let e=x.getState().session;return e?.sessionAuthenticated?this.cache.get("my-bookmarks",async()=>(await this.awaitApi).listMyBookmarks(e.profile.userId),300*1e3):[]}};var mo=class extends Re{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetCount(e){if(this.isAuthenticated())return this.cache.get(`user-asset-count-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/${e}`),this.CACHE_DURATION)}async getUserBookmarkCountByMap(e){if(this.isAuthenticated())return this.cache.get(`user-bookmark-count-by-map-${e}`,async()=>(await this.awaitApi).get(`/internal/api/webapp/user/assets/count/BOOKMARKS/${e}`),this.CACHE_DURATION)}isAuthenticated(){let e=x.getState().session;return!!e?.sessionAuthenticated}};var go=class extends Re{constructor(){super(...arguments),this.CACHE_DURATION=180*1e3}async getUserAssetLabels(){return this.isAuthenticated()?this.cache.get("user-asset-labels",async()=>(await this.awaitApi).get("/internal/api/webapp/user/assets/labels"),this.CACHE_DURATION):[]}isAuthenticated(){let e=x.getState().session;return!!e?.sessionAuthenticated}};var um="ft-user-assets",pm={setAssetCount:(t,e)=>{let{userAssetType:i,count:r}=e.payload.assetCount;t.assetCounts.allAsset[i]=r},clearAssetCount:t=>{Object.values(dt).forEach(e=>{t.assetCounts.allAsset[e]=void 0})},setBookmarkCountByMap:(t,e)=>{let i=e.payload.mapId;t.assetCounts.bookmarkByMap[i]=e.payload.count},clearBookmarkCountByMap:t=>{t.assetCounts.bookmarkByMap={}},addAsset:(t,e)=>{let{assetType:i,mapId:r,asset:n}=e.payload;pa(t,i,[...ua(t,i),n]),Qc(t,i,1,r),ed(t,n)},editAsset:(t,e)=>{let{assetType:i,asset:r}=e.payload;pa(t,i,ua(t,i).map(n=>n.id===r.id?r:n)),ed(t,r)},removeAsset:(t,e)=>{let{assetType:i,mapId:r,assetId:n}=e.payload;pa(t,i,ua(t,i).filter(o=>o.id!==n)),Qc(t,i,-1,r)}},td={[dt.SEARCHES]:"savedSearches",[dt.BOOKMARKS]:"bookmarks",[dt.BOOKS]:void 0,[dt.COLLECTIONS]:void 0},ua=(t,e)=>{var i;let r=td[e];return r?(i=t[r])!==null&&i!==void 0?i:[]:[]},pa=(t,e,i)=>{let r=td[e];r&&(t[r]=i)},Qc=(t,e,i,r)=>{let n=t.assetCounts.allAsset[e];if(n!==void 0&&(t.assetCounts.allAsset[e]=Math.max(0,n+i),e===dt.BOOKMARKS&&r)){let o=t.assetCounts.bookmarkByMap[r];t.assetCounts.bookmarkByMap[r]=Math.max(0,o+i)}},ed=(t,e)=>{let i=t.assetLabels.map(n=>n.title),r=e.labels.filter(n=>!i.includes(n)).map(n=>({title:n}));t.assetLabels.push(...r)},Ue=yo.FtReduxStore.get({name:um,reducers:pm,initialState:{savedSearches:void 0,bookmarks:void 0,assetCounts:{allAsset:Object.fromEntries(Object.values(dt).map(t=>[t,void 0])),bookmarkByMap:{}},assetLabels:[]}}),fa=class{constructor(e=new mo,i=new go){this.assetCountsService=e,this.assetLabelsService=i,this.currentSession=x.getState().session,this.bookmarksAreUsed=!1,this.bookmarksService=new ho,this.savedSearchesService=new fo,x.subscribe(()=>this.reloadWhenUserSessionChanges())}reloadWhenUserSessionChanges(){var e;let{session:i}=x.getState();(0,yo.deepEqual)((e=this.currentSession)===null||e===void 0?void 0:e.profile,i?.profile)||(this.currentSession=i,this.clearMySearches(),this.reloadBookmarks(),this.clearUserAssetCounts(),this.reloadAssetLabels())}clearUserAssetCounts(){this.assetCountsService.clearCache(),Ue.actions.clearAssetCount(),Ue.actions.clearBookmarkCountByMap()}clear(){this.clearMySearches(),this.clearMyBookmarks()}clearMySearches(){this.savedSearchesService.clearCache(),Ue.actions.savedSearches(void 0)}clearMyBookmarks(){this.bookmarksService.clearCache(),Ue.actions.bookmarks(void 0)}async reloadMySearches(){this.savedSearchesService.clearCache();let e=await this.savedSearchesService.listMySearches();Ue.actions.savedSearches(e)}async reloadBookmarks(){this.bookmarksService.clearCache(),await this.updateBookmarksIfUsed()}async reloadAssetLabels(){this.assetLabelsService.clearCache();let e=await this.assetLabelsService.getUserAssetLabels();Ue.actions.assetLabels(e)}async loadAssetCount(e){let i=await this.assetCountsService.getUserAssetCount(e);i&&Ue.getState().assetCounts.allAsset[e]!==i.count&&Ue.actions.setAssetCount({assetCount:i})}async loadBookmarkByMapId(e){let i=await this.assetCountsService.getUserBookmarkCountByMap(e);i&&Ue.getState().assetCounts.bookmarkByMap[e]!==i.count&&Ue.actions.setBookmarkCountByMap({count:i.count,mapId:e})}async reloadAssetCount(e){this.assetCountsService.clearCache();let i=Object.keys(Ue.getState().assetCounts.bookmarkByMap).length!==0;e===dt.BOOKMARKS&&i&&Ue.actions.clearBookmarkCountByMap(),Ue.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 i=!((e=this.currentSession)===null||e===void 0)&&e.sessionAuthenticated?await this.bookmarksService.listMyBookmarks():void 0;Ue.actions.bookmarks(i)}}},fm=new fa;window.FluidTopicsUserAssetsActions==null&&(window.FluidTopicsUserAssetsActions=fm);var ha=class{addCommand(e,i=!1){x.commands.add(e,i)}consumeCommand(e){return x.commands.consume(e)}};window.FluidTopicsAppInfoStoreService=new ha;var ut=c(h());var id,fr=class extends CustomEvent{constructor(e){super("ft-i18n-context-loaded",{detail:e})}},hm=Symbol("clearAfterUnitTest"),vo=class extends(0,ut.withEventBus)(Re){constructor(e){super(),this.messageContextProvider=e,this.defaultMessages={},this.listeners={},this.currentUiLocale="",this[id]=()=>{this.defaultMessages={},this.cache=new ut.CacheRegistry,this.listeners={}},this.currentUiLocale=x.getState().uiLocale,x.subscribe(()=>this.clearWhenUiLocaleChanges())}clearWhenUiLocaleChanges(){let{uiLocale:e}=x.getState();this.currentUiLocale!==e&&(this.currentUiLocale=e,this.cache.clearAll(),this.notifyAll())}addContext(e){let i=e.name.toLowerCase();this.cache.setFinal(i,e),this.notify(i)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(e,i){var r;if(e=e.toLowerCase(),i&&Object.keys(i).length>0){let n={...(r=this.defaultMessages[e])!==null&&r!==void 0?r:{},...i};(0,ut.deepEqual)(this.defaultMessages[e],n)||(this.defaultMessages[e]=n,await this.notify(e))}return this.fetchContext(e)}resolveContext(e){var i,r;return this.fetchContext(e),(r=(i=this.cache.getNow(e))===null||i===void 0?void 0:i.messages)!==null&&r!==void 0?r:{}}resolveRawMessage(e,i){let r=e.toLowerCase();return this.resolveContext(r)[i]}resolveMessage(e,i,...r){var n;let o=e.toLowerCase(),s=this.resolveContext(o);return new ut.ParametrizedLabelResolver((n=this.defaultMessages[o])!==null&&n!==void 0?n:{},s).resolve(i,...r)}async fetchContext(e){let i=!this.cache.has(e),r;try{r=await this.cache.get(e,()=>this.messageContextProvider(this.currentUiLocale,e)),i&&await this.notify(e)}catch(n){!(n instanceof ut.CanceledPromiseError)&&i&&console.error(n)}return r}subscribe(e,i){var r;return e=e.toLowerCase(),this.listeners[e]=(r=this.listeners[e])!==null&&r!==void 0?r:new Set,this.listeners[e].add(i),()=>{var n;return(n=this.listeners[e])===null||n===void 0?void 0:n.delete(i)}}async notifyAll(){let e=Object.keys(this.listeners);document.body.dispatchEvent(new fr({loadedContexts:e})),this.dispatchEvent(new fr({loadedContexts:e})),await Promise.all(e.map(i=>this.notify(i,!1)))}async notify(e,i=!0){i&&(document.body.dispatchEvent(new fr({loadedContexts:[e]})),this.dispatchEvent(new fr({loadedContexts:[e]}))),this.listeners[e]!=null&&await Promise.all([...this.listeners[e].values()].map(r=>(0,ut.delay)(0).then(()=>r()).catch(()=>null)))}};id=hm;window.FluidTopicsI18nService==null&&(window.FluidTopicsI18nService=new class extends vo{constructor(){super(async(t,e)=>(await this.awaitApi).getFluidTopicsMessageContext(t,e))}});window.FluidTopicsCustomI18nService==null&&(window.FluidTopicsCustomI18nService=new class extends vo{constructor(){super(async(t,e)=>(await this.awaitApi).getCustomMessageContext(t,e))}});var hr=window.FluidTopicsI18nService,xo=window.FluidTopicsCustomI18nService;var rd=c(h()),ma=class{highlightHtml(e,i,r){(0,rd.highlightHtml)(e,i,r)}};window.FluidTopicsHighlightHtmlService=new ma;var nd=c(h());var ga=class{isDate(e){var i,r,n,o;return(o=(n=((r=(i=x.getState().metadataConfiguration)===null||i===void 0?void 0:i.descriptors)!==null&&r!==void 0?r:[]).find(a=>a.key===e))===null||n===void 0?void 0:n.date)!==null&&o!==void 0?o:!1}format(e,i){var r,n,o,s;if(e==null)return"";try{return nd.DateFormatter.format(e,(r=i?.locale)!==null&&r!==void 0?r:x.getState().uiLocale,(n=i?.longFormat)!==null&&n!==void 0?n:!1,(o=i?.withTime)!==null&&o!==void 0?o:!1,(s=i?.onlyTime)!==null&&s!==void 0?s:!1)}catch(a){throw console.error(`Date ${JSON.stringify(e)} is not valid`,a),a}}};window.FluidTopicsDateService=new ga;var od=c(h());var rn=class{static get(e,i){var r,n,o,s;let a=x.getState(),{lang:l,region:d}=(o=(n=(r=a.localesConfiguration)===null||r===void 0?void 0:r.defaultLocales)===null||n===void 0?void 0:n.defaultContentLocale)!==null&&o!==void 0?o:{lang:"en",region:"US"};return new od.SearchPlaceConverter(a.baseUrl,e??20,(s=a.localesConfiguration)===null||s===void 0?void 0:s.allLanguagesAllowed,i??`${l}-${d}`)}};var ya=class{urlToSearchRequest(e){return rn.get().parse(e)}searchRequestToUrl(e){return rn.get().serialize(e)}};window.FluidTopicsUrlService=new ya;var Yt=c(h());var Ri=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{nextLocation:e}})}};Ri.eventName="before-location-change";var Oi=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:{currentItem:e}})}};Oi.eventName="change";var va=class{itemName(e){return`fluid-topics-history-item-${e}`}get(e){let i=sessionStorage.getItem(this.itemName(e));return i?JSON.parse(i):void 0}set(e,i){sessionStorage.setItem(this.itemName(e),JSON.stringify(i))}},sd=new va;var bo=class t extends Yt.WithEventBus{static build(){return new t(window.history,sd,()=>window.location,!1)}constructor(e,i,r,n){var o,s;super(),this.history=e,this.historyStorage=i,this.windowLocation=r,this.states=[],this.realPushState=e.pushState,this.realReplaceState=e.replaceState,this.initialIndex=(s=(o=e.state)===null||o===void 0?void 0:o.index)!==null&&s!==void 0?s:e.length-1,this.currentIndex=this.initialIndex,this.setCurrentState(this.buildCurrentState()),this.installProxies(),this.initEventListeners(),this.initData(n)}setCurrentState(e,i=!1){let r=i&&this.currentIndex===e.index-1;this.currentState={...this.buildCurrentState(),...e},this.currentIndex=this.currentState.index,this.states[this.currentIndex]=this.currentState,r&&(this.states=this.states.slice(0,this.currentIndex+1)),this.historyStorage.set(this.currentIndex,this.currentState),(0,Yt.deepEqual)(this.currentState,this.history.state)||this.realReplaceState.apply(this.history,[this.currentState,this.currentState.title,this.windowLocation().href]),setTimeout(()=>this.dispatchEvent(new Oi(this.currentItem())),0)}installProxies(){let e=i=>(r,n,[o,s,a])=>{let l=new Ri(new URL(typeof a=="string"?a:(a??this.windowLocation()).href,window.location.origin));this.dispatchEvent(l);let d=i(),u={...d===this.currentIndex?this.currentState:void 0,...o,index:d,href:l.detail.nextLocation.href};r.apply(n,[u,s,u.href]),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 i=this.history.length-1;i>=0;i--)e?this.states[i]=this.historyStorage.get(i):setTimeout(()=>this.states[i]=this.historyStorage.get(i),this.history.length-i)}updateCurrentState(e){var i;let r={...this.buildCurrentState(),...e,index:this.currentIndex,title:(i=e?.title)!==null&&i!==void 0?i:this.currentState.title};this.setCurrentState(r)}addBeforeLocationChangeListener(e){this.addEventListener(Ri.eventName,e)}removeBeforeLocationChangeListener(e){this.removeEventListener(Ri.eventName,e)}addHistoryChangeListener(e){this.addEventListener(Oi.eventName,e)}removeHistoryChangeListener(e){this.removeEventListener(Oi.eventName,e)}currentItem(){return(0,Yt.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,Yt.deepCopy)(this.states[this.previousDifferentMajorPosition()])}backwardItemMatching(e){let i=this.states.filter(r=>!!r).filter(r=>r.index<this.currentIndex).reverse();return(0,Yt.deepCopy)(i.find(r=>e(r)))}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,Yt.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 i;let r=(i=this.states[e])===null||i===void 0?void 0:i.majorStateId;if(!r)return e;let n=e,o=e+1;for(;this.states.length>o&&!this.isDifferentMajorState(o,r);)this.hasState(o)&&(n=o),o++;return n}buildCurrentState(){var e,i;return{...this.history.state,index:this.currentIndex,href:this.windowLocation().href,title:(i=(e=this.history.state)===null||e===void 0?void 0:e.title)!==null&&i!==void 0?i:document.title}}hasState(e){return this.states[e]!=null}isDifferentMajorState(e,i){var r;if(!this.hasState(e))return!1;let n=i??this.currentState.majorStateId,o=(r=this.states[e])===null||r===void 0?void 0:r.majorStateId;return o==null||o!=n}};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(),backwardItemMatching:t=>window.FluidTopicsInternalHistoryService.backwardItemMatching(t),addHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.addHistoryChangeListener(t),removeHistoryChangeListener:t=>window.FluidTopicsInternalHistoryService.removeHistoryChangeListener(t),addBeforeLocationChangeListener:t=>window.FluidTopicsInternalHistoryService.addBeforeLocationChangeListener(t),removeBeforeLocationChangeListener:t=>window.FluidTopicsInternalHistoryService.removeBeforeLocationChangeListener(t)});var So=class{constructor(){this.storeListeners=[]}store(e,i){if(this.isAuthenticated())return;let r=JSON.stringify(i);window.localStorage.setItem(e,r),window.dispatchEvent(new StorageEvent("storage",{key:e,newValue:r,storageArea:window.localStorage}))}get(e){var i,r;if(!this.isAuthenticated())return(r=JSON.parse((i=window.localStorage.getItem(e))!==null&&i!==void 0?i:"null"))!==null&&r!==void 0?r:void 0}addStoreListener(e,i){let r=n=>{n.key===e()&&!this.isAuthenticated()&&i()};this.storeListeners.push(r),window.addEventListener("storage",r)}clearStoreListeners(){this.storeListeners.forEach(e=>window.removeEventListener("storage",e)),this.storeListeners.length=0}isAuthenticated(){let e=x.getState().session;return!!e?.sessionAuthenticated}};var ad=c(S());var ld=ad.css`
2
+ `;var dd=c(S()),Fe=c(U()),Di=c(h());var ki=c(h());function cd(t,e){let{authenticationRequired:i,session:r}=x.getState();return i&&!r?.sessionAuthenticated?Promise.resolve(e):t()}var wo=class extends pr{async updateUiLocale(e){return(await this.awaitApi).updateUiLocale(e)}};var xa=class t extends ki.FtStateManager{static build(e){return new t(x,e)}constructor(e,i){super(),this.store=e,this.cache=new ki.CacheRegistry,this.withManualResources=!0,this.userLocaleService=new wo,this.cleanSessionDebouncer=new ki.Debouncer,this.reloadConfiguration=()=>{var r;(r=this.cache)===null||r===void 0||r.clear("availableContentLocales"),this.updateAvailableContentLocales()},this.reloadDebouncer=new ki.Debouncer(500),this.apiProvider=i??(()=>Ft.get())}setWithManualResources(e){this.withManualResources=e,this.updateIfNeeded()}addListeners(){this.store.addEventListener(wt.eventName,this.reloadConfiguration)}removeListeners(){this.store.removeEventListener(wt.eventName,this.reloadConfiguration)}async updateIfNeeded(){this.apiProvider()&&(this.withManualResources||(this.store.getState().session==null&&this.updateSession(),this.store.getState().metadataConfiguration==null&&this.updateMetadataConfiguration()),this.store.getState().localesConfiguration==null&&this.updateLocalesConfiguration(),(this.store.getState().availableContentLocales==null||this.store.getState().availableContentLocales.length==0)&&this.updateAvailableContentLocales())}async updateSession(){let e=await this.cache.get("session",async()=>{let i=await this.apiProvider().getCurrentSession();return i.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run(()=>{this.cache.clear("session"),this.setSession(void 0)},i.idleTimeoutInMillis),i});this.setSession(e)}async updateMetadataConfiguration(){this.setMetadataConfiguration(await this.cache.get("metadataConfiguration",()=>this.apiProvider().getMetadataConfiguration()))}async updateLocalesConfiguration(){this.setLocalesConfiguration(await this.cache.get("localesConfiguration",()=>this.apiProvider().getLocalesConfiguration()))}async updateAvailableContentLocales(){var e;let i=await this.cache.get("availableContentLocales",()=>cd(()=>this.apiProvider().getAvailableSearchLocales(),{contentLocales:[]}));this.setAvailableContentLocales((e=i.contentLocales)!==null&&e!==void 0?e:[])}setStickyFilters(e){this.store.actions.stickyFilters(e)}setBaseUrl(e){this.store.actions.baseUrl(e),window.fluidTopicsBaseUrl=e}setTenantId(e){this.store.actions.tenantId(e)}setApiIntegrationIdentifier(e){this.store.actions.apiIntegrationIdentifier(e)}setApiIntegrationAppVersion(e){this.store.actions.apiIntegrationAppVersion(e)}setUiLocale(e){this.store.actions.uiLocale(e)}setLocalesConfiguration(e){this.store.actions.localesConfiguration(e),setTimeout(()=>this.updateIfNeeded())}setAvailableContentLocales(e){this.store.actions.availableContentLocales(e),setTimeout(()=>this.updateIfNeeded())}stopReloadDebouncer(){this.reloadDebouncer.cancel()}requestUiLocaleUpdate(e,i){this.userLocaleService.updateUiLocale({uiLocale:e,contentLocale:i}).then(r=>{r.uiLocaleChanged&&(this.reloadDebouncer.run(()=>window.location.reload()),this.store.dispatchEvent(new Ti(r)))}).catch(()=>{})}setMetadataConfiguration(e){this.store.actions.metadataConfiguration(e),setTimeout(()=>this.updateIfNeeded())}setNoCustom(e){this.store.actions.noCustom(e)}setEditorMode(e){this.store.actions.editorMode(e)}setNoCustomComponent(e){this.store.actions.noCustomComponent(e)}setNoCustomCode(e){this.store.actions.noCustomCode(e)}setSession(e){this.store.actions.session(e),setTimeout(()=>this.updateIfNeeded())}setOpenExternalDocumentInNewTab(e){this.store.actions.openExternalDocumentInNewTab(e)}setNavigatorOnline(e){this.store.actions.navigatorOnline(e)}setForcedOffline(e){this.store.actions.forcedOffline(e)}setAuthenticationRequired(e){this.store.actions.authenticationRequired(e)}},mr=xa.build();var Ae=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},X=class extends Di.FtLitElementRedux{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.apiIntegrationAppVersion="ft-integration-app-version",this.uiLocale="en-US",this.editorMode=!1,this.noCustom=!1,this.openExternalDocumentInNewTab=!1,this.noCustomComponent=!1,this.noCustomCode=!1,this.withManualResources=!1,this.navigatorOnline=!1,this.forcedOffline=!1,this.authenticationRequired=!1,this.messageContexts=[],this.stateManager=mr,this.contextRoot=new zr}render(){return dd.html`
3
3
  <slot></slot>
4
- `}connectedCallback(){super.connectedCallback(),this.stateManager.addListeners(),this.contextRoot.attach(document.body)}disconnectedCallback(){super.disconnectedCallback(),this.stateManager.removeListeners(),this.contextRoot.detach(document.body)}update(e){var i;super.update(e),e.has("baseUrl")&&this.stateManager.setBaseUrl(this.baseUrl),e.has("tenantId")&&this.stateManager.setTenantId(this.tenantId),e.has("apiIntegrationIdentifier")&&this.stateManager.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("apiIntegrationAppVersion")&&this.stateManager.setApiIntegrationAppVersion(this.apiIntegrationAppVersion),e.has("uiLocale")&&this.stateManager.setUiLocale(this.uiLocale),e.has("metadataConfiguration")&&this.stateManager.setMetadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&this.stateManager.setNoCustom(this.noCustom),e.has("editorMode")&&this.stateManager.setEditorMode(this.editorMode),e.has("noCustomComponent")&&this.stateManager.setNoCustomComponent(this.noCustomComponent),e.has("noCustomCode")&&this.stateManager.setNoCustomCode(this.noCustomCode),e.has("session")&&this.stateManager.setSession(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(r=>dr.addContext(r)),e.has("openExternalDocumentInNewTab")&&this.stateManager.setOpenExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&this.stateManager.setNavigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&this.stateManager.setForcedOffline(this.forcedOffline),e.has("authenticationRequired")&&this.stateManager.setAuthenticationRequired(this.authenticationRequired),e.has("withManualResources")&&((i=this.stateManager)===null||i===void 0||i.setWithManualResources(this.withManualResources)),setTimeout(()=>this.stateManager.updateIfNeeded())}};X.elementDefinitions={};X.styles=ld;Ae([(0,Ue.property)()],X.prototype,"baseUrl",void 0);Ae([(0,Ue.property)()],X.prototype,"tenantId",void 0);Ae([(0,Ue.property)()],X.prototype,"apiIntegrationIdentifier",void 0);Ae([(0,Ue.property)()],X.prototype,"apiIntegrationAppVersion",void 0);Ae([(0,Ue.property)()],X.prototype,"uiLocale",void 0);Ae([(0,Li.jsonProperty)(null)],X.prototype,"availableUiLocales",void 0);Ae([(0,Li.jsonProperty)(null)],X.prototype,"metadataConfiguration",void 0);Ae([(0,Ue.property)({type:Boolean})],X.prototype,"editorMode",void 0);Ae([(0,Ue.property)({type:Boolean})],X.prototype,"noCustom",void 0);Ae([(0,Ue.property)({type:Boolean})],X.prototype,"openExternalDocumentInNewTab",void 0);Ae([(0,Ue.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],X.prototype,"noCustomComponent",void 0);Ae([(0,Ue.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],X.prototype,"noCustomCode",void 0);Ae([(0,Ue.property)({type:Boolean})],X.prototype,"withManualResources",void 0);Ae([(0,Ue.property)({type:Boolean})],X.prototype,"navigatorOnline",void 0);Ae([(0,Ue.property)({type:Boolean})],X.prototype,"forcedOffline",void 0);Ae([(0,Ue.property)({type:Boolean})],X.prototype,"authenticationRequired",void 0);Ae([(0,Li.jsonProperty)([])],X.prototype,"messageContexts",void 0);Ae([(0,Li.jsonProperty)(void 0)],X.prototype,"session",void 0);var pd=c(h());var ud={"ft-app-context":X};(0,pd.customElements)(ud);var hd=c(h()),ai;(function(t){t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.MAP_ATTACHMENT="MAP_ATTACHMENT",t.UD_ATTACHMENT="UD_ATTACHMENT",t.RESOURCE="RESOURCE"})(ai||(ai={}));var fd;(function(t){t.FIT_TO_CONTAINER="fit-to-container",t.ZOOM_REAL_SIZE="zoom-real-size",t.ZOOM_IN="zoom-in",t.ZOOM_OUT="zoom-out",t.ROTATE_LEFT="rotate-left",t.ROTATE_RIGHT="rotate-right"})(fd||(fd={}));var Di=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:(0,hd.deepCopy)(e),composed:!0,bubbles:!0})}};Di.eventName="ft-viewer-loaded";var Eo=class extends Re{getAsset(e,i,r){let n={[ai.MAP_ATTACHMENT]:()=>this.api.getMapAttachment(e,i),[ai.UD_ATTACHMENT]:()=>this.api.getUdAttachment(e,i),[ai.RESOURCE]:()=>this.api.getMapResource(e,i)};return this.cache.get(i,n[r])}};var _o=class t extends ir{static build(e){return new t(In(e),new Eo)}constructor(e,i){super(e),this.store=e,this.service=i}async load(){let{documentId:e,assetId:i,origin:r}=this.store.getState();if(e&&i&&r){let n=await this.service.getAsset(e,i,r);this.store.actions.document(n.holder),this.store.actions.descriptor({id:n.id,portalUrl:n.portalUrl,filename:n.filename,fingerprint:n.fingerprint,displayName:n.displayName,alt:n.displayName,mimeType:n.mimeType,size:n.size,viewableInCurrentBrowser:n.viewableInCurrentBrowser,contentUrl:n.contentUrl}),this.store.actions.watermark(n.watermark)}}clear(){this.store.clearKeeping("documentId","assetId","origin")}reload(){return this.clear(),this.load()}async init(e,i,r){return this.store.actions.documentId(e),this.store.actions.assetId(i),this.store.actions.origin(r),await this.reload(),this.store.getState()}};var Ao=c(U());var nn=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Zt=class extends pr.FtLitElementRedux{constructor(){super(...arguments),this.viewerStateManager=_o.build(this.id||(0,pr.randomId)(6))}render(){return md.html`
4
+ `}connectedCallback(){super.connectedCallback(),this.stateManager.addListeners(),this.contextRoot.attach(document.body)}disconnectedCallback(){super.disconnectedCallback(),this.stateManager.removeListeners(),this.contextRoot.detach(document.body)}update(e){var i;super.update(e),e.has("baseUrl")&&this.stateManager.setBaseUrl(this.baseUrl),e.has("tenantId")&&this.stateManager.setTenantId(this.tenantId),e.has("apiIntegrationIdentifier")&&this.stateManager.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),e.has("apiIntegrationAppVersion")&&this.stateManager.setApiIntegrationAppVersion(this.apiIntegrationAppVersion),e.has("uiLocale")&&this.stateManager.setUiLocale(this.uiLocale),e.has("metadataConfiguration")&&this.stateManager.setMetadataConfiguration(this.metadataConfiguration),e.has("noCustom")&&this.stateManager.setNoCustom(this.noCustom),e.has("editorMode")&&this.stateManager.setEditorMode(this.editorMode),e.has("noCustomComponent")&&this.stateManager.setNoCustomComponent(this.noCustomComponent),e.has("noCustomCode")&&this.stateManager.setNoCustomCode(this.noCustomCode),e.has("session")&&this.stateManager.setSession(this.session),e.has("messageContexts")&&this.messageContexts!=null&&this.messageContexts.forEach(r=>hr.addContext(r)),e.has("openExternalDocumentInNewTab")&&this.stateManager.setOpenExternalDocumentInNewTab(this.openExternalDocumentInNewTab),e.has("navigatorOnline")&&this.stateManager.setNavigatorOnline(this.navigatorOnline),e.has("forcedOffline")&&this.stateManager.setForcedOffline(this.forcedOffline),e.has("authenticationRequired")&&this.stateManager.setAuthenticationRequired(this.authenticationRequired),e.has("withManualResources")&&((i=this.stateManager)===null||i===void 0||i.setWithManualResources(this.withManualResources)),setTimeout(()=>this.stateManager.updateIfNeeded())}};X.elementDefinitions={};X.styles=ld;Ae([(0,Fe.property)()],X.prototype,"baseUrl",void 0);Ae([(0,Fe.property)()],X.prototype,"tenantId",void 0);Ae([(0,Fe.property)()],X.prototype,"apiIntegrationIdentifier",void 0);Ae([(0,Fe.property)()],X.prototype,"apiIntegrationAppVersion",void 0);Ae([(0,Fe.property)()],X.prototype,"uiLocale",void 0);Ae([(0,Di.jsonProperty)(null)],X.prototype,"availableUiLocales",void 0);Ae([(0,Di.jsonProperty)(null)],X.prototype,"metadataConfiguration",void 0);Ae([(0,Fe.property)({type:Boolean})],X.prototype,"editorMode",void 0);Ae([(0,Fe.property)({type:Boolean})],X.prototype,"noCustom",void 0);Ae([(0,Fe.property)({type:Boolean})],X.prototype,"openExternalDocumentInNewTab",void 0);Ae([(0,Fe.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],X.prototype,"noCustomComponent",void 0);Ae([(0,Fe.property)({converter:{fromAttribute(t){return t==="false"?!1:t==="true"||(t??!1)}}})],X.prototype,"noCustomCode",void 0);Ae([(0,Fe.property)({type:Boolean})],X.prototype,"withManualResources",void 0);Ae([(0,Fe.property)({type:Boolean})],X.prototype,"navigatorOnline",void 0);Ae([(0,Fe.property)({type:Boolean})],X.prototype,"forcedOffline",void 0);Ae([(0,Fe.property)({type:Boolean})],X.prototype,"authenticationRequired",void 0);Ae([(0,Di.jsonProperty)([])],X.prototype,"messageContexts",void 0);Ae([(0,Di.jsonProperty)(void 0)],X.prototype,"session",void 0);var pd=c(h());var ud={"ft-app-context":X};(0,pd.customElements)(ud);var hd=c(h()),ci;(function(t){t.UNSTRUCTURED_DOCUMENT="UNSTRUCTURED_DOCUMENT",t.MAP_ATTACHMENT="MAP_ATTACHMENT",t.UD_ATTACHMENT="UD_ATTACHMENT",t.RESOURCE="RESOURCE"})(ci||(ci={}));var fd;(function(t){t.FIT_TO_CONTAINER="fit-to-container",t.ZOOM_REAL_SIZE="zoom-real-size",t.ZOOM_IN="zoom-in",t.ZOOM_OUT="zoom-out",t.ROTATE_LEFT="rotate-left",t.ROTATE_RIGHT="rotate-right"})(fd||(fd={}));var Li=class t extends CustomEvent{constructor(e){super(t.eventName,{detail:(0,hd.deepCopy)(e),composed:!0,bubbles:!0})}};Li.eventName="ft-viewer-loaded";var Eo=class extends Re{getAsset(e,i,r){let n={[ci.MAP_ATTACHMENT]:()=>this.api.getMapAttachment(e,i),[ci.UD_ATTACHMENT]:()=>this.api.getUdAttachment(e,i),[ci.RESOURCE]:()=>this.api.getMapResource(e,i)};return this.cache.get(i,n[r])}};var _o=class t extends sr{static build(e){return new t(In(e),new Eo)}constructor(e,i){super(e),this.store=e,this.service=i}async load(){let{documentId:e,assetId:i,origin:r}=this.store.getState();if(e&&i&&r){let n=await this.service.getAsset(e,i,r);this.store.actions.document(n.holder),this.store.actions.descriptor({id:n.id,portalUrl:n.portalUrl,filename:n.filename,fingerprint:n.fingerprint,displayName:n.displayName,alt:n.displayName,mimeType:n.mimeType,size:n.size,viewableInCurrentBrowser:n.viewableInCurrentBrowser,contentUrl:n.contentUrl}),this.store.actions.watermark(n.watermark)}}clear(){this.store.clearKeeping("documentId","assetId","origin")}reload(){return this.clear(),this.load()}async init(e,i,r){return this.store.actions.documentId(e),this.store.actions.assetId(i),this.store.actions.origin(r),await this.reload(),this.store.getState()}};var Ao=c(U());var nn=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Zt=class extends gr.FtLitElementRedux{constructor(){super(...arguments),this.viewerStateManager=_o.build(this.id||(0,gr.randomId)(6))}render(){return md.html`
5
5
  <slot></slot>
6
- `}willUpdate(e){super.willUpdate(e),(e.has("documentId")||e.has("assetId")||e.has("origin"))&&this.initStateManager()}async initStateManager(){let e=await this.viewerStateManager.init(this.documentId,this.assetId,this.origin);this.documentId&&this.assetId&&this.origin&&this.dispatchEvent(new Di(e))}connectedCallback(){super.connectedCallback(),this.addStore(v)}onAuthenticationChange(){this.viewerStateManager.reload()}};nn([(0,Ao.property)()],Zt.prototype,"documentId",void 0);nn([(0,Ao.property)()],Zt.prototype,"assetId",void 0);nn([(0,Ao.property)()],Zt.prototype,"origin",void 0);nn([jr({context:Bs})],Zt.prototype,"viewerStateManager",void 0);nn([(0,pr.reduxEventListener)({eventName:wt.eventName})],Zt.prototype,"onAuthenticationChange",null);var gd=c(h()),We=class extends gd.FtLitElementRedux{};var _t=c(x()),$i=c(h()),At=c(U());var yd=c(x()),vd=c(h()),mm={position:vd.FtCssVariableFactory.create("--ft-content-watermark-position","Position property of the watermark container","POSITION","sticky")},bd=yd.css`
6
+ `}willUpdate(e){super.willUpdate(e),(e.has("documentId")||e.has("assetId")||e.has("origin"))&&this.initStateManager()}async initStateManager(){let e=await this.viewerStateManager.init(this.documentId,this.assetId,this.origin);this.documentId&&this.assetId&&this.origin&&this.dispatchEvent(new Li(e))}connectedCallback(){super.connectedCallback(),this.addStore(x)}onAuthenticationChange(){this.viewerStateManager.reload()}};nn([(0,Ao.property)()],Zt.prototype,"documentId",void 0);nn([(0,Ao.property)()],Zt.prototype,"assetId",void 0);nn([(0,Ao.property)()],Zt.prototype,"origin",void 0);nn([jr({context:Bs})],Zt.prototype,"viewerStateManager",void 0);nn([(0,gr.reduxEventListener)({eventName:wt.eventName})],Zt.prototype,"onAuthenticationChange",null);var gd=c(h()),We=class extends gd.FtLitElementRedux{};var _t=c(S()),Bi=c(h()),At=c(U());var yd=c(S()),vd=c(h()),mm={position:vd.FtCssVariableFactory.create("--ft-content-watermark-position","Position property of the watermark container","POSITION","sticky")},xd=yd.css`
7
7
  :host {
8
8
  position: absolute;
9
9
  top: 0;
@@ -22,112 +22,122 @@
22
22
  .ft-watermark {
23
23
  z-index: 79;
24
24
  }
25
- `;var xr=c(x()),Ni=c(U());var Xd=c(fr()),Jd=c(h());var Ca=globalThis,Sd=t=>t,Co=Ca.trustedTypes,wd=Co?Co.createPolicy("lit-html",{createHTML:t=>t}):void 0,Rd="$lit$",li=`lit$${Math.random().toFixed(9).slice(2)}$`,Od="?"+li,gm=`<${Od}>`,Pi=document,To=()=>Pi.createComment(""),sn=t=>t===null||typeof t!="object"&&typeof t!="function",Ta=Array.isArray,ym=t=>Ta(t)||typeof t?.[Symbol.iterator]=="function",xa=`[
26
- \f\r]`,on=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Ed=/-->/g,_d=/>/g,Ii=RegExp(`>|${xa}(?:([^\\s"'>=/]+)(${xa}*=${xa}*(?:[^
27
- \f\r"'\`<>=]|("|')|))|$)`,"g"),Ad=/'/g,Cd=/"/g,kd=/^(?:script|style|textarea|title)$/i,Ra=t=>(e,...i)=>({_$litType$:t,strings:e,values:i}),Ld=Ra(1),Dd=Ra(2),Id=Ra(3),an=Symbol.for("lit-noChange"),he=Symbol.for("lit-nothing"),Td=new WeakMap,Mi=Pi.createTreeWalker(Pi,129);function Md(t,e){if(!Ta(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return wd!==void 0?wd.createHTML(e):e}var vm=(t,e)=>{let i=t.length-1,r=[],n,o=e===2?"<svg>":e===3?"<math>":"",s=on;for(let a=0;a<i;a++){let l=t[a],d,u,p=-1,f=0;for(;f<l.length&&(s.lastIndex=f,u=s.exec(l),u!==null);)f=s.lastIndex,s===on?u[1]==="!--"?s=Ed:u[1]!==void 0?s=_d:u[2]!==void 0?(kd.test(u[2])&&(n=RegExp("</"+u[2],"g")),s=Ii):u[3]!==void 0&&(s=Ii):s===Ii?u[0]===">"?(s=n??on,p=-1):u[1]===void 0?p=-2:(p=s.lastIndex-u[2].length,d=u[1],s=u[3]===void 0?Ii:u[3]==='"'?Cd:Ad):s===Cd||s===Ad?s=Ii:s===Ed||s===_d?s=on:(s=Ii,n=void 0);let y=s===Ii&&t[a+1].startsWith("/>")?" ":"";o+=s===on?l+gm:p>=0?(r.push(d),l.slice(0,p)+Rd+l.slice(p)+li+y):l+li+(p===-2?a:y)}return[Md(t,o+(t[i]||"<?>")+(e===2?"</svg>":e===3?"</math>":"")),r]},ln=class t{constructor({strings:e,_$litType$:i},r){let n;this.parts=[];let o=0,s=0,a=e.length-1,l=this.parts,[d,u]=vm(e,i);if(this.el=t.createElement(d,r),Mi.currentNode=this.el.content,i===2||i===3){let p=this.el.content.firstChild;p.replaceWith(...p.childNodes)}for(;(n=Mi.nextNode())!==null&&l.length<a;){if(n.nodeType===1){if(n.hasAttributes())for(let p of n.getAttributeNames())if(p.endsWith(Rd)){let f=u[s++],y=n.getAttribute(p).split(li),S=/([.?@])?(.*)/.exec(f);l.push({type:1,index:o,name:S[2],strings:y,ctor:S[1]==="."?wa:S[1]==="?"?Ea:S[1]==="@"?_a:mr}),n.removeAttribute(p)}else p.startsWith(li)&&(l.push({type:6,index:o}),n.removeAttribute(p));if(kd.test(n.tagName)){let p=n.textContent.split(li),f=p.length-1;if(f>0){n.textContent=Co?Co.emptyScript:"";for(let y=0;y<f;y++)n.append(p[y],To()),Mi.nextNode(),l.push({type:2,index:++o});n.append(p[f],To())}}}else if(n.nodeType===8)if(n.data===Od)l.push({type:2,index:o});else{let p=-1;for(;(p=n.data.indexOf(li,p+1))!==-1;)l.push({type:7,index:o}),p+=li.length-1}o++}}static createElement(e,i){let r=Pi.createElement("template");return r.innerHTML=e,r}};function hr(t,e,i=t,r){if(e===an)return e;let n=r!==void 0?i._$Co?.[r]:i._$Cl,o=sn(e)?void 0:e._$litDirective$;return n?.constructor!==o&&(n?._$AO?.(!1),o===void 0?n=void 0:(n=new o(t),n._$AT(t,i,r)),r!==void 0?(i._$Co??=[])[r]=n:i._$Cl=n),n!==void 0&&(e=hr(t,n._$AS(t,e.values),n,r)),e}var Sa=class{constructor(e,i){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){let{el:{content:i},parts:r}=this._$AD,n=(e?.creationScope??Pi).importNode(i,!0);Mi.currentNode=n;let o=Mi.nextNode(),s=0,a=0,l=r[0];for(;l!==void 0;){if(s===l.index){let d;l.type===2?d=new Ro(o,o.nextSibling,this,e):l.type===1?d=new l.ctor(o,l.name,l.strings,this,e):l.type===6&&(d=new Aa(o,this,e)),this._$AV.push(d),l=r[++a]}s!==l?.index&&(o=Mi.nextNode(),s++)}return Mi.currentNode=Pi,n}p(e){let i=0;for(let r of this._$AV)r!==void 0&&(r.strings!==void 0?(r._$AI(e,r,i),i+=r.strings.length-2):r._$AI(e[i])),i++}},Ro=class t{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(e,i,r,n){this.type=2,this._$AH=he,this._$AN=void 0,this._$AA=e,this._$AB=i,this._$AM=r,this.options=n,this._$Cv=n?.isConnected??!0}get parentNode(){let e=this._$AA.parentNode,i=this._$AM;return i!==void 0&&e?.nodeType===11&&(e=i.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,i=this){e=hr(this,e,i),sn(e)?e===he||e==null||e===""?(this._$AH!==he&&this._$AR(),this._$AH=he):e!==this._$AH&&e!==an&&this._(e):e._$litType$!==void 0?this.$(e):e.nodeType!==void 0?this.T(e):ym(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==he&&sn(this._$AH)?this._$AA.nextSibling.data=e:this.T(Pi.createTextNode(e)),this._$AH=e}$(e){let{values:i,_$litType$:r}=e,n=typeof r=="number"?this._$AC(e):(r.el===void 0&&(r.el=ln.createElement(Md(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===n)this._$AH.p(i);else{let o=new Sa(n,this),s=o.u(this.options);o.p(i),this.T(s),this._$AH=o}}_$AC(e){let i=Td.get(e.strings);return i===void 0&&Td.set(e.strings,i=new ln(e)),i}k(e){Ta(this._$AH)||(this._$AH=[],this._$AR());let i=this._$AH,r,n=0;for(let o of e)n===i.length?i.push(r=new t(this.O(To()),this.O(To()),this,this.options)):r=i[n],r._$AI(o),n++;n<i.length&&(this._$AR(r&&r._$AB.nextSibling,n),i.length=n)}_$AR(e=this._$AA.nextSibling,i){for(this._$AP?.(!1,!0,i);e!==this._$AB;){let r=Sd(e).nextSibling;Sd(e).remove(),e=r}}setConnected(e){this._$AM===void 0&&(this._$Cv=e,this._$AP?.(e))}},mr=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,i,r,n,o){this.type=1,this._$AH=he,this._$AN=void 0,this.element=e,this.name=i,this._$AM=n,this.options=o,r.length>2||r[0]!==""||r[1]!==""?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=he}_$AI(e,i=this,r,n){let o=this.strings,s=!1;if(o===void 0)e=hr(this,e,i,0),s=!sn(e)||e!==this._$AH&&e!==an,s&&(this._$AH=e);else{let a=e,l,d;for(e=o[0],l=0;l<o.length-1;l++)d=hr(this,a[r+l],i,l),d===an&&(d=this._$AH[l]),s||=!sn(d)||d!==this._$AH[l],d===he?e=he:e!==he&&(e+=(d??"")+o[l+1]),this._$AH[l]=d}s&&!n&&this.j(e)}j(e){e===he?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,e??"")}},wa=class extends mr{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===he?void 0:e}},Ea=class extends mr{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==he)}},_a=class extends mr{constructor(e,i,r,n,o){super(e,i,r,n,o),this.type=5}_$AI(e,i=this){if((e=hr(this,e,i,0)??he)===an)return;let r=this._$AH,n=e===he&&r!==he||e.capture!==r.capture||e.once!==r.once||e.passive!==r.passive,o=e!==he&&(r===he||n);n&&this.element.removeEventListener(this.name,this,r),o&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,e):this._$AH.handleEvent(e)}},Aa=class{constructor(e,i,r){this.element=e,this.type=6,this._$AN=void 0,this._$AM=i,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(e){hr(this,e)}};var bm=Ca.litHtmlPolyfillSupport;bm?.(ln,Ro),(Ca.litHtmlVersions??=[]).push("3.3.3");var Nd=Symbol.for(""),xm=t=>{if(t?.r===Nd)return t?._$litStatic$},Oa=t=>({_$litStatic$:t,r:Nd});var Pd=new Map,ka=t=>(e,...i)=>{let r=i.length,n,o,s=[],a=[],l,d=0,u=!1;for(;d<r;){for(l=e[d];d<r&&(o=i[d],(n=xm(o))!==void 0);)l+=n+e[++d],u=!0;d!==r&&a.push(o),s.push(l),d++}if(d===r&&s.push(e[r]),u){let p=s.join("$$lit$$");(e=Pd.get(p))===void 0&&(s.raw=s,Pd.set(p,e=s)),i=a}return t(e,...i)},La=ka(Ld),gx=ka(Dd),yx=ka(Id);var Da=c(U()),qd=c(h());var H;(function(t){t.title="title",t.title_dense="title-dense",t.subtitle1="subtitle1",t.subtitle2="subtitle2",t.body1="body1",t.body2="body2",t.caption="caption",t.breadcrumb="breadcrumb",t.overline="overline",t.button="button"})(H||(H={}));var pt=c(x()),g=c(h()),$d=g.FtCssVariableFactory.extend("--ft-typography-font-family","",g.designSystemVariables.titleFont),Xt=g.FtCssVariableFactory.extend("--ft-typography-font-family","",g.designSystemVariables.contentFont),E={fontFamily:Xt,fontSize:g.FtCssVariableFactory.create("--ft-typography-font-size","","SIZE","16px"),fontWeight:g.FtCssVariableFactory.create("--ft-typography-font-weight","","UNKNOWN","normal"),letterSpacing:g.FtCssVariableFactory.create("--ft-typography-letter-spacing","","SIZE","0.496px"),lineHeight:g.FtCssVariableFactory.create("--ft-typography-line-height","","NUMBER","1.5"),textTransform:g.FtCssVariableFactory.create("--ft-typography-text-transform","","UNKNOWN","inherit")},ci={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-title-font-family","",$d),fontSize:g.FtCssVariableFactory.extend("--ft-typography-title-font-size","",E.fontSize,"20px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-title-font-weight","",E.fontWeight,"normal"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-title-letter-spacing","",E.letterSpacing,"0.15px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-title-line-height","",E.lineHeight,"1.2"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-title-text-transform","",E.textTransform,"inherit")},di={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-title-dense-font-family","",$d),fontSize:g.FtCssVariableFactory.extend("--ft-typography-title-dense-font-size","",E.fontSize,"14px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-title-dense-font-weight","",E.fontWeight,"normal"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-title-dense-letter-spacing","",E.letterSpacing,"0.105px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-title-dense-line-height","",E.lineHeight,"1.7"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-title-dense-text-transform","",E.textTransform,"inherit")},gr={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-family","",Xt),fontSize:g.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-size","",E.fontSize,"16px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-weight","",E.fontWeight,"600"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-subtitle1-letter-spacing","",E.letterSpacing,"0.144px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-subtitle1-line-height","",E.lineHeight,"1.5"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-subtitle1-text-transform","",E.textTransform,"inherit")},yr={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-family","",Xt),fontSize:g.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-size","",E.fontSize,"14px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-weight","",E.fontWeight,"normal"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-subtitle2-letter-spacing","",E.letterSpacing,"0.098px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-subtitle2-line-height","",E.lineHeight,"1.7"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-subtitle2-text-transform","",E.textTransform,"inherit")},dt={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-body1-font-family","",Xt),fontSize:g.FtCssVariableFactory.extend("--ft-typography-body1-font-size","",E.fontSize,"16px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-body1-font-weight","",E.fontWeight,"normal"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-body1-letter-spacing","",E.letterSpacing,"0.496px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-body1-line-height","",E.lineHeight,"1.5"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-body1-text-transform","",E.textTransform,"inherit")},ut={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-body2-font-family","",Xt),fontSize:g.FtCssVariableFactory.extend("--ft-typography-body2-font-size","",E.fontSize,"14px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-body2-font-weight","",E.fontWeight,"normal"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-body2-letter-spacing","",E.letterSpacing,"0.252px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-body2-line-height","",E.lineHeight,"1.4"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-body2-text-transform","",E.textTransform,"inherit")},tt={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-caption-font-family","",Xt),fontSize:g.FtCssVariableFactory.extend("--ft-typography-caption-font-size","",E.fontSize,"12px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-caption-font-weight","",E.fontWeight,"normal"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-caption-letter-spacing","",E.letterSpacing,"0.396px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-caption-line-height","",E.lineHeight,"1.33"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-caption-text-transform","",E.textTransform,"inherit")},vr={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-family","",Xt),fontSize:g.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-size","",E.fontSize,"10px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-weight","",E.fontWeight,"normal"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-breadcrumb-letter-spacing","",E.letterSpacing,"0.33px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-breadcrumb-line-height","",E.lineHeight,"1.6"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-breadcrumb-text-transform","",E.textTransform,"inherit")},br={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-overline-font-family","",Xt),fontSize:g.FtCssVariableFactory.extend("--ft-typography-overline-font-size","",E.fontSize,"10px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-overline-font-weight","",E.fontWeight,"normal"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-overline-letter-spacing","",E.letterSpacing,"1.5px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-overline-line-height","",E.lineHeight,"1.6"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-overline-text-transform","",E.textTransform,"uppercase")},Fe={fontFamily:g.FtCssVariableFactory.extend("--ft-typography-button-font-family","",Xt),fontSize:g.FtCssVariableFactory.extend("--ft-typography-button-font-size","",E.fontSize,"14px"),fontWeight:g.FtCssVariableFactory.extend("--ft-typography-button-font-weight","",E.fontWeight,"600"),letterSpacing:g.FtCssVariableFactory.extend("--ft-typography-button-letter-spacing","",E.letterSpacing,"1.246px"),lineHeight:g.FtCssVariableFactory.extend("--ft-typography-button-line-height","",E.lineHeight,"1.15"),textTransform:g.FtCssVariableFactory.extend("--ft-typography-button-text-transform","",E.textTransform,"uppercase")},Ud=pt.css`
25
+ `;var br=c(S()),Vi=c(U());var Xd=c(yr()),Jd=c(h());var Ca=globalThis,Sd=t=>t,Co=Ca.trustedTypes,wd=Co?Co.createPolicy("lit-html",{createHTML:t=>t}):void 0,Rd="$lit$",di=`lit$${Math.random().toFixed(9).slice(2)}$`,Od="?"+di,gm=`<${Od}>`,Pi=document,To=()=>Pi.createComment(""),sn=t=>t===null||typeof t!="object"&&typeof t!="function",Ta=Array.isArray,ym=t=>Ta(t)||typeof t?.[Symbol.iterator]=="function",ba=`[
26
+ \f\r]`,on=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Ed=/-->/g,_d=/>/g,Ii=RegExp(`>|${ba}(?:([^\\s"'>=/]+)(${ba}*=${ba}*(?:[^
27
+ \f\r"'\`<>=]|("|')|))|$)`,"g"),Ad=/'/g,Cd=/"/g,kd=/^(?:script|style|textarea|title)$/i,Ra=t=>(e,...i)=>({_$litType$:t,strings:e,values:i}),Dd=Ra(1),Ld=Ra(2),Id=Ra(3),an=Symbol.for("lit-noChange"),he=Symbol.for("lit-nothing"),Td=new WeakMap,Mi=Pi.createTreeWalker(Pi,129);function Md(t,e){if(!Ta(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return wd!==void 0?wd.createHTML(e):e}var vm=(t,e)=>{let i=t.length-1,r=[],n,o=e===2?"<svg>":e===3?"<math>":"",s=on;for(let a=0;a<i;a++){let l=t[a],d,u,p=-1,f=0;for(;f<l.length&&(s.lastIndex=f,u=s.exec(l),u!==null);)f=s.lastIndex,s===on?u[1]==="!--"?s=Ed:u[1]!==void 0?s=_d:u[2]!==void 0?(kd.test(u[2])&&(n=RegExp("</"+u[2],"g")),s=Ii):u[3]!==void 0&&(s=Ii):s===Ii?u[0]===">"?(s=n??on,p=-1):u[1]===void 0?p=-2:(p=s.lastIndex-u[2].length,d=u[1],s=u[3]===void 0?Ii:u[3]==='"'?Cd:Ad):s===Cd||s===Ad?s=Ii:s===Ed||s===_d?s=on:(s=Ii,n=void 0);let y=s===Ii&&t[a+1].startsWith("/>")?" ":"";o+=s===on?l+gm:p>=0?(r.push(d),l.slice(0,p)+Rd+l.slice(p)+di+y):l+di+(p===-2?a:y)}return[Md(t,o+(t[i]||"<?>")+(e===2?"</svg>":e===3?"</math>":"")),r]},ln=class t{constructor({strings:e,_$litType$:i},r){let n;this.parts=[];let o=0,s=0,a=e.length-1,l=this.parts,[d,u]=vm(e,i);if(this.el=t.createElement(d,r),Mi.currentNode=this.el.content,i===2||i===3){let p=this.el.content.firstChild;p.replaceWith(...p.childNodes)}for(;(n=Mi.nextNode())!==null&&l.length<a;){if(n.nodeType===1){if(n.hasAttributes())for(let p of n.getAttributeNames())if(p.endsWith(Rd)){let f=u[s++],y=n.getAttribute(p).split(di),w=/([.?@])?(.*)/.exec(f);l.push({type:1,index:o,name:w[2],strings:y,ctor:w[1]==="."?wa:w[1]==="?"?Ea:w[1]==="@"?_a:xr}),n.removeAttribute(p)}else p.startsWith(di)&&(l.push({type:6,index:o}),n.removeAttribute(p));if(kd.test(n.tagName)){let p=n.textContent.split(di),f=p.length-1;if(f>0){n.textContent=Co?Co.emptyScript:"";for(let y=0;y<f;y++)n.append(p[y],To()),Mi.nextNode(),l.push({type:2,index:++o});n.append(p[f],To())}}}else if(n.nodeType===8)if(n.data===Od)l.push({type:2,index:o});else{let p=-1;for(;(p=n.data.indexOf(di,p+1))!==-1;)l.push({type:7,index:o}),p+=di.length-1}o++}}static createElement(e,i){let r=Pi.createElement("template");return r.innerHTML=e,r}};function vr(t,e,i=t,r){if(e===an)return e;let n=r!==void 0?i._$Co?.[r]:i._$Cl,o=sn(e)?void 0:e._$litDirective$;return n?.constructor!==o&&(n?._$AO?.(!1),o===void 0?n=void 0:(n=new o(t),n._$AT(t,i,r)),r!==void 0?(i._$Co??=[])[r]=n:i._$Cl=n),n!==void 0&&(e=vr(t,n._$AS(t,e.values),n,r)),e}var Sa=class{constructor(e,i){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){let{el:{content:i},parts:r}=this._$AD,n=(e?.creationScope??Pi).importNode(i,!0);Mi.currentNode=n;let o=Mi.nextNode(),s=0,a=0,l=r[0];for(;l!==void 0;){if(s===l.index){let d;l.type===2?d=new Ro(o,o.nextSibling,this,e):l.type===1?d=new l.ctor(o,l.name,l.strings,this,e):l.type===6&&(d=new Aa(o,this,e)),this._$AV.push(d),l=r[++a]}s!==l?.index&&(o=Mi.nextNode(),s++)}return Mi.currentNode=Pi,n}p(e){let i=0;for(let r of this._$AV)r!==void 0&&(r.strings!==void 0?(r._$AI(e,r,i),i+=r.strings.length-2):r._$AI(e[i])),i++}},Ro=class t{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(e,i,r,n){this.type=2,this._$AH=he,this._$AN=void 0,this._$AA=e,this._$AB=i,this._$AM=r,this.options=n,this._$Cv=n?.isConnected??!0}get parentNode(){let e=this._$AA.parentNode,i=this._$AM;return i!==void 0&&e?.nodeType===11&&(e=i.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,i=this){e=vr(this,e,i),sn(e)?e===he||e==null||e===""?(this._$AH!==he&&this._$AR(),this._$AH=he):e!==this._$AH&&e!==an&&this._(e):e._$litType$!==void 0?this.$(e):e.nodeType!==void 0?this.T(e):ym(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==he&&sn(this._$AH)?this._$AA.nextSibling.data=e:this.T(Pi.createTextNode(e)),this._$AH=e}$(e){let{values:i,_$litType$:r}=e,n=typeof r=="number"?this._$AC(e):(r.el===void 0&&(r.el=ln.createElement(Md(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===n)this._$AH.p(i);else{let o=new Sa(n,this),s=o.u(this.options);o.p(i),this.T(s),this._$AH=o}}_$AC(e){let i=Td.get(e.strings);return i===void 0&&Td.set(e.strings,i=new ln(e)),i}k(e){Ta(this._$AH)||(this._$AH=[],this._$AR());let i=this._$AH,r,n=0;for(let o of e)n===i.length?i.push(r=new t(this.O(To()),this.O(To()),this,this.options)):r=i[n],r._$AI(o),n++;n<i.length&&(this._$AR(r&&r._$AB.nextSibling,n),i.length=n)}_$AR(e=this._$AA.nextSibling,i){for(this._$AP?.(!1,!0,i);e!==this._$AB;){let r=Sd(e).nextSibling;Sd(e).remove(),e=r}}setConnected(e){this._$AM===void 0&&(this._$Cv=e,this._$AP?.(e))}},xr=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,i,r,n,o){this.type=1,this._$AH=he,this._$AN=void 0,this.element=e,this.name=i,this._$AM=n,this.options=o,r.length>2||r[0]!==""||r[1]!==""?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=he}_$AI(e,i=this,r,n){let o=this.strings,s=!1;if(o===void 0)e=vr(this,e,i,0),s=!sn(e)||e!==this._$AH&&e!==an,s&&(this._$AH=e);else{let a=e,l,d;for(e=o[0],l=0;l<o.length-1;l++)d=vr(this,a[r+l],i,l),d===an&&(d=this._$AH[l]),s||=!sn(d)||d!==this._$AH[l],d===he?e=he:e!==he&&(e+=(d??"")+o[l+1]),this._$AH[l]=d}s&&!n&&this.j(e)}j(e){e===he?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,e??"")}},wa=class extends xr{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===he?void 0:e}},Ea=class extends xr{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==he)}},_a=class extends xr{constructor(e,i,r,n,o){super(e,i,r,n,o),this.type=5}_$AI(e,i=this){if((e=vr(this,e,i,0)??he)===an)return;let r=this._$AH,n=e===he&&r!==he||e.capture!==r.capture||e.once!==r.once||e.passive!==r.passive,o=e!==he&&(r===he||n);n&&this.element.removeEventListener(this.name,this,r),o&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,e):this._$AH.handleEvent(e)}},Aa=class{constructor(e,i,r){this.element=e,this.type=6,this._$AN=void 0,this._$AM=i,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(e){vr(this,e)}};var xm=Ca.litHtmlPolyfillSupport;xm?.(ln,Ro),(Ca.litHtmlVersions??=[]).push("3.3.3");var Nd=Symbol.for(""),bm=t=>{if(t?.r===Nd)return t?._$litStatic$},Oa=t=>({_$litStatic$:t,r:Nd});var Pd=new Map,ka=t=>(e,...i)=>{let r=i.length,n,o,s=[],a=[],l,d=0,u=!1;for(;d<r;){for(l=e[d];d<r&&(o=i[d],(n=bm(o))!==void 0);)l+=n+e[++d],u=!0;d!==r&&a.push(o),s.push(l),d++}if(d===r&&s.push(e[r]),u){let p=s.join("$$lit$$");(e=Pd.get(p))===void 0&&(s.raw=s,Pd.set(p,e=s)),i=a}return t(e,...i)},Da=ka(Dd),gb=ka(Ld),yb=ka(Id);var La=c(U()),qd=c(h());var H;(function(t){t.title="title",t.title_dense="title-dense",t.subtitle1="subtitle1",t.subtitle2="subtitle2",t.body1="body1",t.body2="body2",t.caption="caption",t.breadcrumb="breadcrumb",t.overline="overline",t.button="button"})(H||(H={}));var pt=c(S()),m=c(h()),$d=m.FtCssVariableFactory.extend("--ft-typography-font-family","",m.designSystemVariables.titleFont),Qt=m.FtCssVariableFactory.extend("--ft-typography-font-family","",m.designSystemVariables.contentFont),v={fontFamily:Qt,fontSize:m.FtCssVariableFactory.create("--ft-typography-font-size","","SIZE","16px"),fontWeight:m.FtCssVariableFactory.create("--ft-typography-font-weight","","UNKNOWN","normal"),letterSpacing:m.FtCssVariableFactory.create("--ft-typography-letter-spacing","","SIZE","0.496px"),lineHeight:m.FtCssVariableFactory.create("--ft-typography-line-height","","NUMBER","1.5"),textTransform:m.FtCssVariableFactory.create("--ft-typography-text-transform","","UNKNOWN","inherit"),textDecoration:m.FtCssVariableFactory.create("--ft-typography-text-decoration","","UNKNOWN","inherit")},Xt={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-title-font-family","",$d),fontSize:m.FtCssVariableFactory.extend("--ft-typography-title-font-size","",v.fontSize,"20px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-title-font-weight","",v.fontWeight,"normal"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-title-letter-spacing","",v.letterSpacing,"0.15px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-title-line-height","",v.lineHeight,"1.2"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-title-text-transform","",v.textTransform,"inherit"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-title-text-decoration","",v.textDecoration,"inherit")},Jt={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-title-dense-font-family","",$d),fontSize:m.FtCssVariableFactory.extend("--ft-typography-title-dense-font-size","",v.fontSize,"14px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-title-dense-font-weight","",v.fontWeight,"normal"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-title-dense-letter-spacing","",v.letterSpacing,"0.105px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-title-dense-line-height","",v.lineHeight,"1.7"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-title-dense-text-transform","",v.textTransform,"inherit"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-title-dense-text-decoration","",v.textDecoration,"inherit")},Ni={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-family","",Qt),fontSize:m.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-size","",v.fontSize,"16px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-weight","",v.fontWeight,"600"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-subtitle1-letter-spacing","",v.letterSpacing,"0.144px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-subtitle1-line-height","",v.lineHeight,"1.5"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-subtitle1-text-transform","",v.textTransform,"inherit"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-subtitle1-text-decoration","",v.textDecoration,"inherit")},$i={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-family","",Qt),fontSize:m.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-size","",v.fontSize,"14px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-weight","",v.fontWeight,"normal"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-subtitle2-letter-spacing","",v.letterSpacing,"0.098px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-subtitle2-line-height","",v.lineHeight,"1.7"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-subtitle2-text-transform","",v.textTransform,"inherit"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-subtitle2-text-decoration","",v.textDecoration,"inherit")},it={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-body1-font-family","",Qt),fontSize:m.FtCssVariableFactory.extend("--ft-typography-body1-font-size","",v.fontSize,"16px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-body1-font-weight","",v.fontWeight,"normal"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-body1-letter-spacing","",v.letterSpacing,"0.496px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-body1-line-height","",v.lineHeight,"1.5"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-body1-text-transform","",v.textTransform,"inherit"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-body1-text-decoration","",v.textDecoration,"inherit")},rt={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-body2-font-family","",Qt),fontSize:m.FtCssVariableFactory.extend("--ft-typography-body2-font-size","",v.fontSize,"14px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-body2-font-weight","",v.fontWeight,"normal"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-body2-letter-spacing","",v.letterSpacing,"0.252px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-body2-line-height","",v.lineHeight,"1.4"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-body2-text-transform","",v.textTransform,"inherit"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-body2-text-decoration","",v.textDecoration,"inherit")},Ke={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-caption-font-family","",Qt),fontSize:m.FtCssVariableFactory.extend("--ft-typography-caption-font-size","",v.fontSize,"12px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-caption-font-weight","",v.fontWeight,"normal"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-caption-letter-spacing","",v.letterSpacing,"0.396px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-caption-line-height","",v.lineHeight,"1.33"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-caption-text-transform","",v.textTransform,"inherit"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-caption-text-decoration","",v.textDecoration,"inherit")},Ui={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-family","",Qt),fontSize:m.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-size","",v.fontSize,"10px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-weight","",v.fontWeight,"normal"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-breadcrumb-letter-spacing","",v.letterSpacing,"0.33px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-breadcrumb-line-height","",v.lineHeight,"1.6"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-breadcrumb-text-transform","",v.textTransform,"inherit"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-breadcrumb-text-decoration","",v.textDecoration,"inherit")},Fi={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-overline-font-family","",Qt),fontSize:m.FtCssVariableFactory.extend("--ft-typography-overline-font-size","",v.fontSize,"10px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-overline-font-weight","",v.fontWeight,"normal"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-overline-letter-spacing","",v.letterSpacing,"1.5px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-overline-line-height","",v.lineHeight,"1.6"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-overline-text-transform","",v.textTransform,"uppercase"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-overline-text-decoration","",v.textDecoration,"inherit")},Ie={fontFamily:m.FtCssVariableFactory.extend("--ft-typography-button-font-family","",Qt),fontSize:m.FtCssVariableFactory.extend("--ft-typography-button-font-size","",v.fontSize,"14px"),fontWeight:m.FtCssVariableFactory.extend("--ft-typography-button-font-weight","",v.fontWeight,"600"),letterSpacing:m.FtCssVariableFactory.extend("--ft-typography-button-letter-spacing","",v.letterSpacing,"1.246px"),lineHeight:m.FtCssVariableFactory.extend("--ft-typography-button-line-height","",v.lineHeight,"1.15"),textTransform:m.FtCssVariableFactory.extend("--ft-typography-button-text-transform","",v.textTransform,"uppercase"),textDecoration:m.FtCssVariableFactory.extend("--ft-typography-button-text-decoration","",v.textDecoration,"inherit")},Ud=pt.css`
28
28
  .ft-typography--title {
29
- font-family: ${ci.fontFamily};
30
- font-size: ${ci.fontSize};
31
- font-weight: ${ci.fontWeight};
32
- letter-spacing: ${ci.letterSpacing};
33
- line-height: ${ci.lineHeight};
34
- text-transform: ${ci.textTransform};
29
+ font-family: ${Xt.fontFamily};
30
+ font-size: ${Xt.fontSize};
31
+ font-weight: ${Xt.fontWeight};
32
+ letter-spacing: ${Xt.letterSpacing};
33
+ line-height: ${Xt.lineHeight};
34
+ text-transform: ${Xt.textTransform};
35
+ text-decoration: ${Xt.textDecoration};
35
36
  }
36
37
  `,Fd=pt.css`
37
38
  .ft-typography--title-dense {
38
- font-family: ${di.fontFamily};
39
- font-size: ${di.fontSize};
40
- font-weight: ${di.fontWeight};
41
- letter-spacing: ${di.letterSpacing};
42
- line-height: ${di.lineHeight};
43
- text-transform: ${di.textTransform};
39
+ font-family: ${Jt.fontFamily};
40
+ font-size: ${Jt.fontSize};
41
+ font-weight: ${Jt.fontWeight};
42
+ letter-spacing: ${Jt.letterSpacing};
43
+ line-height: ${Jt.lineHeight};
44
+ text-transform: ${Jt.textTransform};
45
+ text-decoration: ${Jt.textDecoration};
44
46
  }
45
47
  `,Vd=pt.css`
46
48
  .ft-typography--subtitle1 {
47
- font-family: ${gr.fontFamily};
48
- font-size: ${gr.fontSize};
49
- font-weight: ${gr.fontWeight};
50
- letter-spacing: ${gr.letterSpacing};
51
- line-height: ${gr.lineHeight};
52
- text-transform: ${gr.textTransform};
49
+ font-family: ${Ni.fontFamily};
50
+ font-size: ${Ni.fontSize};
51
+ font-weight: ${Ni.fontWeight};
52
+ letter-spacing: ${Ni.letterSpacing};
53
+ line-height: ${Ni.lineHeight};
54
+ text-transform: ${Ni.textTransform};
55
+ text-decoration: ${Ni.textDecoration};
53
56
  }
54
57
  `,Bd=pt.css`
55
58
  .ft-typography--subtitle2 {
56
- font-family: ${yr.fontFamily};
57
- font-size: ${yr.fontSize};
58
- font-weight: ${yr.fontWeight};
59
- letter-spacing: ${yr.letterSpacing};
60
- line-height: ${yr.lineHeight};
61
- text-transform: ${yr.textTransform};
59
+ font-family: ${$i.fontFamily};
60
+ font-size: ${$i.fontSize};
61
+ font-weight: ${$i.fontWeight};
62
+ letter-spacing: ${$i.letterSpacing};
63
+ line-height: ${$i.lineHeight};
64
+ text-transform: ${$i.textTransform};
65
+ text-decoration: ${$i.textDecoration};
62
66
  }
63
67
 
64
68
  `,ui=pt.css`
65
69
  .ft-typography--body1 {
66
- font-family: ${dt.fontFamily};
67
- font-size: ${dt.fontSize};
68
- font-weight: ${dt.fontWeight};
69
- letter-spacing: ${dt.letterSpacing};
70
- line-height: ${dt.lineHeight};
71
- text-transform: ${dt.textTransform};
70
+ font-family: ${it.fontFamily};
71
+ font-size: ${it.fontSize};
72
+ font-weight: ${it.fontWeight};
73
+ letter-spacing: ${it.letterSpacing};
74
+ line-height: ${it.lineHeight};
75
+ text-transform: ${it.textTransform};
76
+ text-decoration: ${it.textDecoration};
72
77
  }
73
78
  `,Hd=pt.css`
74
79
  .ft-typography--body2 {
75
- font-family: ${ut.fontFamily};
76
- font-size: ${ut.fontSize};
77
- font-weight: ${ut.fontWeight};
78
- letter-spacing: ${ut.letterSpacing};
79
- line-height: ${ut.lineHeight};
80
- text-transform: ${ut.textTransform};
80
+ font-family: ${rt.fontFamily};
81
+ font-size: ${rt.fontSize};
82
+ font-weight: ${rt.fontWeight};
83
+ letter-spacing: ${rt.letterSpacing};
84
+ line-height: ${rt.lineHeight};
85
+ text-transform: ${rt.textTransform};
86
+ text-decoration: ${rt.textDecoration};
81
87
  }
82
88
  `,Oo=pt.css`
83
89
  .ft-typography--caption {
84
- font-family: ${tt.fontFamily};
85
- font-size: ${tt.fontSize};
86
- font-weight: ${tt.fontWeight};
87
- letter-spacing: ${tt.letterSpacing};
88
- line-height: ${tt.lineHeight};
89
- text-transform: ${tt.textTransform};
90
+ font-family: ${Ke.fontFamily};
91
+ font-size: ${Ke.fontSize};
92
+ font-weight: ${Ke.fontWeight};
93
+ letter-spacing: ${Ke.letterSpacing};
94
+ line-height: ${Ke.lineHeight};
95
+ text-transform: ${Ke.textTransform};
96
+ text-decoration: ${Ke.textDecoration};
90
97
  }
91
98
  `,zd=pt.css`
92
99
  .ft-typography--breadcrumb {
93
- font-family: ${vr.fontFamily};
94
- font-size: ${vr.fontSize};
95
- font-weight: ${vr.fontWeight};
96
- letter-spacing: ${vr.letterSpacing};
97
- line-height: ${vr.lineHeight};
98
- text-transform: ${vr.textTransform};
100
+ font-family: ${Ui.fontFamily};
101
+ font-size: ${Ui.fontSize};
102
+ font-weight: ${Ui.fontWeight};
103
+ letter-spacing: ${Ui.letterSpacing};
104
+ line-height: ${Ui.lineHeight};
105
+ text-transform: ${Ui.textTransform};
106
+ text-decoration: ${Ui.textDecoration};
99
107
  }
100
108
  `,jd=pt.css`
101
109
  .ft-typography--overline {
102
- font-family: ${br.fontFamily};
103
- font-size: ${br.fontSize};
104
- font-weight: ${br.fontWeight};
105
- letter-spacing: ${br.letterSpacing};
106
- line-height: ${br.lineHeight};
107
- text-transform: ${br.textTransform};
110
+ font-family: ${Fi.fontFamily};
111
+ font-size: ${Fi.fontSize};
112
+ font-weight: ${Fi.fontWeight};
113
+ letter-spacing: ${Fi.letterSpacing};
114
+ line-height: ${Fi.lineHeight};
115
+ text-transform: ${Fi.textTransform};
116
+ text-decoration: ${Fi.textDecoration};
108
117
  }
109
118
  `,Wd=pt.css`
110
119
  .ft-typography--button {
111
- font-family: ${Fe.fontFamily};
112
- font-size: ${Fe.fontSize};
113
- font-weight: ${Fe.fontWeight};
114
- letter-spacing: ${Fe.letterSpacing};
115
- line-height: ${Fe.lineHeight};
116
- text-transform: ${Fe.textTransform};
120
+ font-family: ${Ie.fontFamily};
121
+ font-size: ${Ie.fontSize};
122
+ font-weight: ${Ie.fontWeight};
123
+ letter-spacing: ${Ie.letterSpacing};
124
+ line-height: ${Ie.lineHeight};
125
+ text-transform: ${Ie.textTransform};
126
+ text-decoration: ${Ie.textDecoration};
117
127
  }
118
128
  `,Kd=pt.css`
119
129
  .ft-typography {
120
130
  vertical-align: inherit;
121
131
  }
122
- `;var Gd=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},F=class extends qd.FtLitElement{constructor(){super(...arguments),this.variant=H.body1}render(){return this.element?La`
132
+ `;var Gd=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},F=class extends qd.FtLitElement{constructor(){super(...arguments),this.variant=H.body1}render(){return this.element?Da`
123
133
  <${Oa(this.element)}
124
134
  part="text"
125
135
  class="ft-typography ft-typography--${this.variant}">
126
136
  <slot></slot>
127
137
  </${Oa(this.element)}>
128
- `:La`
138
+ `:Da`
129
139
  <slot part="text" class="ft-typography ft-typography--${this.variant}"></slot>
130
- `}};F.styles=[Ud,Fd,Vd,Bd,ui,Hd,Oo,zd,jd,Wd,Kd];Gd([(0,Da.property)()],F.prototype,"element",void 0);Gd([(0,Da.property)()],F.prototype,"variant",void 0);var Zd=c(h());var Yd={"ft-typography":F};(0,Zd.customElements)(Yd);var ko=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Et=class extends Jd.FtLitElement{constructor(){super(...arguments),this.height=0,this.resizeObserver=new ResizeObserver(([e])=>{this.height=Math.min(e.contentRect.height,e.contentRect.width)})}render(){var e,i,r;return this.watermark?xr.html`
140
+ `}};F.styles=[Ud,Fd,Vd,Bd,ui,Hd,Oo,zd,jd,Wd,Kd];Gd([(0,La.property)()],F.prototype,"element",void 0);Gd([(0,La.property)()],F.prototype,"variant",void 0);var Zd=c(h());var Yd={"ft-typography":F};(0,Zd.customElements)(Yd);var ko=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Et=class extends Jd.FtLitElement{constructor(){super(...arguments),this.height=0,this.resizeObserver=new ResizeObserver(([e])=>{this.height=Math.min(e.contentRect.height,e.contentRect.width)})}render(){var e,i,r;return this.watermark?br.html`
131
141
  <style>
132
142
  .ft-watermark {
133
143
  height: ${this.height}px;
@@ -142,11 +152,11 @@
142
152
  transform="rotate(-45)"
143
153
  fill="${(e=this.watermark)===null||e===void 0?void 0:e.color}"
144
154
  fill-opacity="${(i=this.watermark)===null||i===void 0?void 0:i.opacity}%">
145
- ${(0,Xd.repeat)(((r=this.watermark)===null||r===void 0?void 0:r.text)||[],n=>xr.svg`<tspan x="0" dy="1.2em">${n}</tspan>`)}
155
+ ${(0,Xd.repeat)(((r=this.watermark)===null||r===void 0?void 0:r.text)||[],n=>br.svg`<tspan x="0" dy="1.2em">${n}</tspan>`)}
146
156
  </text>
147
157
  </svg>
148
158
  </div>
149
- `:xr.nothing}updated(e){if(super.updated(e),e.has("watermark")&&this.watermark){let i=this.svg.getBBox({stroke:!0});this.svg.setAttribute("viewBox",i.x+" "+i.y+" "+i.width+" "+i.height)}e.has("heightReference")&&this.heightReference&&(this.resizeObserver.disconnect(),this.resizeObserver.observe(this.heightReference))}disconnectedCallback(){super.disconnectedCallback(),this.resizeObserver.disconnect()}};Et.styles=[bd,ui];ko([(0,Ni.query)(".ft-watermark")],Et.prototype,"svg",void 0);ko([(0,Ni.property)({attribute:!1})],Et.prototype,"watermark",void 0);ko([(0,Ni.property)({attribute:!1})],Et.prototype,"heightReference",void 0);ko([(0,Ni.state)()],Et.prototype,"height",void 0);var eu=c(h());var Qd={"ft-content-watermark":Et};(0,eu.customElements)(Qd);var iu=c(Ia()),it=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ce=class extends(0,$i.withConditionalVisibility)(We){constructor(){super(...arguments),this.viewerType="none",this.inlineSvgAllowed=!1}render(){return _t.html`
159
+ `:br.nothing}updated(e){if(super.updated(e),e.has("watermark")&&this.watermark){let i=this.svg.getBBox({stroke:!0});this.svg.setAttribute("viewBox",i.x+" "+i.y+" "+i.width+" "+i.height)}e.has("heightReference")&&this.heightReference&&(this.resizeObserver.disconnect(),this.resizeObserver.observe(this.heightReference))}disconnectedCallback(){super.disconnectedCallback(),this.resizeObserver.disconnect()}};Et.styles=[xd,ui];ko([(0,Vi.query)(".ft-watermark")],Et.prototype,"svg",void 0);ko([(0,Vi.property)({attribute:!1})],Et.prototype,"watermark",void 0);ko([(0,Vi.property)({attribute:!1})],Et.prototype,"heightReference",void 0);ko([(0,Vi.state)()],Et.prototype,"height",void 0);var eu=c(h());var Qd={"ft-content-watermark":Et};(0,eu.customElements)(Qd);var iu=c(Ia()),nt=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ce=class extends(0,Bi.withConditionalVisibility)(We){constructor(){super(...arguments),this.viewerType="none",this.inlineSvgAllowed=!1}render(){return _t.html`
150
160
  ${this.renderContent()}
151
161
  <ft-content-watermark part="watermark"
152
162
  .watermark=${this.watermark}
@@ -215,23 +225,23 @@
215
225
  max-height: 100%;
216
226
  border: none;
217
227
  }
218
- `;it([(0,$i.redux)({store:"viewer"})],ce.prototype,"descriptor",void 0);it([(0,At.state)()],ce.prototype,"viewerType",void 0);it([(0,At.state)()],ce.prototype,"inlineSvgAllowed",void 0);it([(0,$i.redux)({store:"viewer",selector:({contentModifiers:t})=>t.zoom})],ce.prototype,"zoom",void 0);it([(0,$i.redux)({store:"viewer",selector:({contentModifiers:t})=>t.rotation})],ce.prototype,"rotation",void 0);it([(0,$i.redux)({store:"viewer"})],ce.prototype,"watermark",void 0);it([(0,At.query)("img")],ce.prototype,"image",void 0);it([(0,At.query)("svg")],ce.prototype,"svg",void 0);it([(0,At.query)(".image-viewer")],ce.prototype,"imageViewer",void 0);it([(0,At.query)(".image-container")],ce.prototype,"imageContainer",void 0);it([(0,At.state)()],ce.prototype,"imageHeight",void 0);it([(0,At.state)()],ce.prototype,"imageWidth",void 0);it([(0,At.state)()],ce.prototype,"svgContent",void 0);var Lo=class extends Nt(ce){};var ru=c(h()),Sr=c(x());var Sm=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Jt=class extends We{render(){return this.filename?Sr.html`
228
+ `;nt([(0,Bi.redux)({store:"viewer"})],ce.prototype,"descriptor",void 0);nt([(0,At.state)()],ce.prototype,"viewerType",void 0);nt([(0,At.state)()],ce.prototype,"inlineSvgAllowed",void 0);nt([(0,Bi.redux)({store:"viewer",selector:({contentModifiers:t})=>t.zoom})],ce.prototype,"zoom",void 0);nt([(0,Bi.redux)({store:"viewer",selector:({contentModifiers:t})=>t.rotation})],ce.prototype,"rotation",void 0);nt([(0,Bi.redux)({store:"viewer"})],ce.prototype,"watermark",void 0);nt([(0,At.query)("img")],ce.prototype,"image",void 0);nt([(0,At.query)("svg")],ce.prototype,"svg",void 0);nt([(0,At.query)(".image-viewer")],ce.prototype,"imageViewer",void 0);nt([(0,At.query)(".image-container")],ce.prototype,"imageContainer",void 0);nt([(0,At.state)()],ce.prototype,"imageHeight",void 0);nt([(0,At.state)()],ce.prototype,"imageWidth",void 0);nt([(0,At.state)()],ce.prototype,"svgContent",void 0);var Do=class extends Nt(ce){};var ru=c(h()),Sr=c(S());var Sm=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ei=class extends We{render(){return this.filename?Sr.html`
219
229
  <ft-typography variant="${H.body1}" part="filename">
220
230
  ${this.filename}
221
231
  </ft-typography>
222
- `:Sr.nothing}};Jt.elementDefinitions={"ft-typography":F};Jt.styles=Sr.css`
232
+ `:Sr.nothing}};ei.elementDefinitions={"ft-typography":F};ei.styles=Sr.css`
223
233
  [part="filename"]::part(text) {
224
234
  margin: unset;
225
235
  }
226
- `;Sm([(0,ru.redux)({store:"viewer",selector:({descriptor:t})=>t?.filename})],Jt.prototype,"filename",void 0);var Do=class extends Nt(Jt){};var nu=c(h()),wr=c(x());var wm=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Ui=class extends We{render(){return this.displayName?wr.html`
236
+ `;Sm([(0,ru.redux)({store:"viewer",selector:({descriptor:t})=>t?.filename})],ei.prototype,"filename",void 0);var Lo=class extends Nt(ei){};var nu=c(h()),wr=c(S());var wm=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Hi=class extends We{render(){return this.displayName?wr.html`
227
237
  <ft-typography variant="${H.title}" part="display-name" element="h2">
228
238
  ${this.displayName}
229
239
  </ft-typography>
230
- `:wr.nothing}};Ui.elementDefinitions={"ft-typography":F};Ui.styles=wr.css`
240
+ `:wr.nothing}};Hi.elementDefinitions={"ft-typography":F};Hi.styles=wr.css`
231
241
  [part="display-name"]::part(text) {
232
242
  margin: unset;
233
243
  }
234
- `;wm([(0,nu.redux)({store:"viewer",selector:({descriptor:t})=>t?.displayName})],Ui.prototype,"displayName",void 0);var Io=class extends Nt(Ui){};var un=c(h()),Po=c(x());var ou=c(x()),Ct=c(h()),me={size:Ct.FtCssVariableFactory.create("--ft-icon-font-size","","SIZE","24px"),fluidTopicsFontFamily:Ct.FtCssVariableFactory.extend("--ft-icon-fluid-topics-font-family","",Ct.FtCssVariableFactory.create("--ft-icon-font-family","","UNKNOWN","ft-icons")),fileFormatFontFamily:Ct.FtCssVariableFactory.extend("--ft-icon-file-format-font-family","",Ct.FtCssVariableFactory.create("--ft-icon-font-family","","UNKNOWN","ft-mime")),materialFontFamily:Ct.FtCssVariableFactory.extend("--ft-icon-material-font-family","",Ct.FtCssVariableFactory.create("--ft-icon-font-family","","UNKNOWN","Material Icons")),verticalAlign:Ct.FtCssVariableFactory.create("--ft-icon-vertical-align","","UNKNOWN","unset")},su=[ou.css`
244
+ `;wm([(0,nu.redux)({store:"viewer",selector:({descriptor:t})=>t?.displayName})],Hi.prototype,"displayName",void 0);var Io=class extends Nt(Hi){};var un=c(h()),Po=c(S());var ou=c(S()),Ct=c(h()),me={size:Ct.FtCssVariableFactory.create("--ft-icon-font-size","","SIZE","24px"),fluidTopicsFontFamily:Ct.FtCssVariableFactory.extend("--ft-icon-fluid-topics-font-family","",Ct.FtCssVariableFactory.create("--ft-icon-font-family","","UNKNOWN","ft-icons")),fileFormatFontFamily:Ct.FtCssVariableFactory.extend("--ft-icon-file-format-font-family","",Ct.FtCssVariableFactory.create("--ft-icon-font-family","","UNKNOWN","ft-mime")),materialFontFamily:Ct.FtCssVariableFactory.extend("--ft-icon-material-font-family","",Ct.FtCssVariableFactory.create("--ft-icon-font-family","","UNKNOWN","Material Icons")),verticalAlign:Ct.FtCssVariableFactory.create("--ft-icon-vertical-align","","UNKNOWN","unset")},su=[ou.css`
235
245
  :host, i.ft-icon {
236
246
  display: inline-flex;
237
247
  align-items: center;
@@ -279,31 +289,31 @@
279
289
  .ft-icon--material {
280
290
  font-family: ${me.materialFontFamily}, "Material Icons", sans-serif;
281
291
  }
282
- `,Ct.noTextSelect];var Ie;(function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"})(Ie||(Ie={}));var cn=c(x()),pi=c(U()),au=c(h()),lu=c(Ia());var Fi;(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.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.CIRCLE_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;",t.TOPICS_SOLID="&#xe9ba;",t.PHOTO_FILM="&#xe9bb;",t.HYPHEN_SOLID="&#xe9bc;",t.CROSSHAIRS="&#xe9bd;",t.PERSON_CHALKBOARD="&#xe9be;",t.CIRCLE_ARROW_DOWN_SLASH="&#xe9bf;",t.BOOK_OPEN_COVER="&#xe9c0;",t.LIGHTBULB="&#xe9c1;",t.MESSAGE_BOT_AGENTIC_SOLID="&#xe9c2;",t.CHART_LINE_USER="&#xe9c3;",t.SERVER_CIRCLE_ARROW_DOWN="&#xe9c4;",t.EYE="&#xf06e;",t.SHARE="&#xe80f1;"})(Fi||(Fi={}));var m;(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;"})(m||(m={}));var Ma=new Map([...["abw"].map(t=>[t,m.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,m.AUDIO]),...["avi"].map(t=>[t,m.AVI]),...["chm","xhs"].map(t=>[t,m.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,m.CODE]),...["csv"].map(t=>[t,m.CSV]),...["dita","ditamap","ditaval"].map(t=>[t,m.DITA]),...["epub"].map(t=>[t,m.EPUB]),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map(t=>[t,m.EXCEL]),...["flac"].map(t=>[t,m.FLAC]),...["gif"].map(t=>[t,m.GIF]),...["gzip","x-gzip","giz","gz","tgz"].map(t=>[t,m.GZIP]),...["html","htm","xhtml"].map(t=>[t,m.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,m.IMAGE]),...["jpeg","jpg","jpe"].map(t=>[t,m.JPEG]),...["json"].map(t=>[t,m.JSON]),...["m4a","m4p"].map(t=>[t,m.M4A]),...["mov","qt"].map(t=>[t,m.MOV]),...["mp3"].map(t=>[t,m.MP3]),...["mp4","m4v"].map(t=>[t,m.MP4]),...["ogg","oga"].map(t=>[t,m.OGG]),...["pdf","ps"].map(t=>[t,m.PDF]),...["png"].map(t=>[t,m.PNG]),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map(t=>[t,m.POWERPOINT]),...["rar"].map(t=>[t,m.RAR]),...["stp"].map(t=>[t,m.STP]),...["txt","rtf","md","mdown"].map(t=>[t,m.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,m.VIDEO]),...["wav"].map(t=>[t,m.WAV]),...["wma"].map(t=>[t,m.WMA]),...["doc","dot","docx","docm","dotx","dotm","docb"].map(t=>[t,m.WORD]),...["xml","xsl","rdf"].map(t=>[t,m.XML]),...["yaml","yml","x-yaml"].map(t=>[t,m.YAML]),...["zip"].map(t=>[t,m.ZIP])]),Em=new Map([["application/msword","application/doc"],["application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/docx"],["application/vnd.openxmlformats-officedocument.wordprocessingml.template","application/dotx"],["application/vnd.ms-word.document.macroEnabled.12","application/docm"],["application/vnd.ms-word.template.macroEnabled.12","application/dotm"],["application/vnd.ms-excel","application/xls"],["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/xlsx"],["application/vnd.openxmlformats-officedocument.spreadsheetml.template","application/xltx"],["application/vnd.ms-excel.sheet.macroEnabled.12","application/xlsm"],["application/vnd.ms-excel.template.macroEnabled.12","application/xltm"],["application/vnd.ms-excel.addin.macroEnabled.12","application/xlam"],["application/vnd.ms-excel.sheet.binary.macroEnabled.12","application/xlsb"],["application/vnd.ms-powerpoint","application/ppt"],["application/vnd.openxmlformats-officedocument.presentationml.presentation","application/pptx"],["application/vnd.openxmlformats-officedocument.presentationml.template","application/potx"],["application/vnd.openxmlformats-officedocument.presentationml.slideshow","application/ppsx"],["application/vnd.ms-powerpoint.addin.macroEnabled.12","application/ppam"],["application/vnd.ms-powerpoint.presentation.macroEnabled.12","application/pptm"],["application/vnd.ms-powerpoint.template.macroEnabled.12","application/potm"],["application/vnd.ms-powerpoint.slideshow.macroEnabled.12","application/ppsm"],["application/vnd.ms-access","application/mdb"]]);function Mo(t,e){var i,r,n,o;t=(t??"").toLowerCase(),e=(e??"").toLowerCase();let[s,a]=(((i=Em.get(t))!==null&&i!==void 0?i:t)+"/").split("/");return(o=(n=(r=Ma.get(a))!==null&&r!==void 0?r:Ma.get(e))!==null&&n!==void 0?n:Ma.get(s))!==null&&o!==void 0?o:m.UNKNOWN}var Pa={[m.ABW]:"#91ABC6",[m.AUDIO]:"#1795E3",[m.AVI]:"#E63324",[m.CHM]:"#71C3EB",[m.CODE]:"#71C3EB",[m.CSV]:"#1F7345",[m.DITA]:"#71C3EB",[m.EPUB]:"#85B926",[m.EXCEL]:"#1F7345",[m.FLAC]:"#1795E3",[m.GIF]:"#59B031",[m.GZIP]:"#F8AB36",[m.HTML]:"#71C3EB",[m.IMAGE]:"#59B031",[m.JPEG]:"#59B031",[m.JSON]:"#71C3EB",[m.M4A]:"#1795E3",[m.MOV]:"#E63324",[m.MP3]:"#1795E3",[m.MP4]:"#E63324",[m.OGG]:"#1795E3",[m.PDF]:"#E44948",[m.PNG]:"#59B031",[m.POWERPOINT]:"#B54A2B",[m.RAR]:"#F8AB36",[m.STP]:"#3764B1",[m.TEXT]:"#3162AB",[m.UNKNOWN]:"#999999",[m.VIDEO]:"#E63324",[m.WAV]:"#1795E3",[m.WMA]:"#1795E3",[m.WORD]:"#3162AB",[m.XML]:"#71C3EB",[m.YAML]:"#71C3EB",[m.ZIP]:"#F8AB36"};var dn=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},z=class extends au.FtLitElement{constructor(){super(...arguments),this.ariaHidden="true",this.resolvedIcon=cn.nothing}render(){let e=this.variant&&Object.values(Ie).includes(this.variant)?this.variant:Ie.fluid_topics,i=e!==Ie.material||!!this.value;return cn.html`
292
+ `,Ct.noTextSelect];var Me;(function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"})(Me||(Me={}));var cn=c(S()),pi=c(U()),au=c(h()),lu=c(Ia());var zi;(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.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.CIRCLE_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;",t.TOPICS_SOLID="&#xe9ba;",t.PHOTO_FILM="&#xe9bb;",t.HYPHEN_SOLID="&#xe9bc;",t.CROSSHAIRS="&#xe9bd;",t.PERSON_CHALKBOARD="&#xe9be;",t.CIRCLE_ARROW_DOWN_SLASH="&#xe9bf;",t.BOOK_OPEN_COVER="&#xe9c0;",t.LIGHTBULB="&#xe9c1;",t.MESSAGE_BOT_AGENTIC_SOLID="&#xe9c2;",t.CHART_LINE_USER="&#xe9c3;",t.SERVER_CIRCLE_ARROW_DOWN="&#xe9c4;",t.EYE="&#xf06e;",t.SHARE="&#xe80f1;"})(zi||(zi={}));var g;(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;"})(g||(g={}));var Ma=new Map([...["abw"].map(t=>[t,g.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,g.AUDIO]),...["avi"].map(t=>[t,g.AVI]),...["chm","xhs"].map(t=>[t,g.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,g.CODE]),...["csv"].map(t=>[t,g.CSV]),...["dita","ditamap","ditaval"].map(t=>[t,g.DITA]),...["epub"].map(t=>[t,g.EPUB]),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map(t=>[t,g.EXCEL]),...["flac"].map(t=>[t,g.FLAC]),...["gif"].map(t=>[t,g.GIF]),...["gzip","x-gzip","giz","gz","tgz"].map(t=>[t,g.GZIP]),...["html","htm","xhtml"].map(t=>[t,g.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,g.IMAGE]),...["jpeg","jpg","jpe"].map(t=>[t,g.JPEG]),...["json"].map(t=>[t,g.JSON]),...["m4a","m4p"].map(t=>[t,g.M4A]),...["mov","qt"].map(t=>[t,g.MOV]),...["mp3"].map(t=>[t,g.MP3]),...["mp4","m4v"].map(t=>[t,g.MP4]),...["ogg","oga"].map(t=>[t,g.OGG]),...["pdf","ps"].map(t=>[t,g.PDF]),...["png"].map(t=>[t,g.PNG]),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map(t=>[t,g.POWERPOINT]),...["rar"].map(t=>[t,g.RAR]),...["stp"].map(t=>[t,g.STP]),...["txt","rtf","md","mdown"].map(t=>[t,g.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,g.VIDEO]),...["wav"].map(t=>[t,g.WAV]),...["wma"].map(t=>[t,g.WMA]),...["doc","dot","docx","docm","dotx","dotm","docb"].map(t=>[t,g.WORD]),...["xml","xsl","rdf"].map(t=>[t,g.XML]),...["yaml","yml","x-yaml"].map(t=>[t,g.YAML]),...["zip"].map(t=>[t,g.ZIP])]),Em=new Map([["application/msword","application/doc"],["application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/docx"],["application/vnd.openxmlformats-officedocument.wordprocessingml.template","application/dotx"],["application/vnd.ms-word.document.macroEnabled.12","application/docm"],["application/vnd.ms-word.template.macroEnabled.12","application/dotm"],["application/vnd.ms-excel","application/xls"],["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/xlsx"],["application/vnd.openxmlformats-officedocument.spreadsheetml.template","application/xltx"],["application/vnd.ms-excel.sheet.macroEnabled.12","application/xlsm"],["application/vnd.ms-excel.template.macroEnabled.12","application/xltm"],["application/vnd.ms-excel.addin.macroEnabled.12","application/xlam"],["application/vnd.ms-excel.sheet.binary.macroEnabled.12","application/xlsb"],["application/vnd.ms-powerpoint","application/ppt"],["application/vnd.openxmlformats-officedocument.presentationml.presentation","application/pptx"],["application/vnd.openxmlformats-officedocument.presentationml.template","application/potx"],["application/vnd.openxmlformats-officedocument.presentationml.slideshow","application/ppsx"],["application/vnd.ms-powerpoint.addin.macroEnabled.12","application/ppam"],["application/vnd.ms-powerpoint.presentation.macroEnabled.12","application/pptm"],["application/vnd.ms-powerpoint.template.macroEnabled.12","application/potm"],["application/vnd.ms-powerpoint.slideshow.macroEnabled.12","application/ppsm"],["application/vnd.ms-access","application/mdb"]]);function Mo(t,e){var i,r,n,o;t=(t??"").toLowerCase(),e=(e??"").toLowerCase();let[s,a]=(((i=Em.get(t))!==null&&i!==void 0?i:t)+"/").split("/");return(o=(n=(r=Ma.get(a))!==null&&r!==void 0?r:Ma.get(e))!==null&&n!==void 0?n:Ma.get(s))!==null&&o!==void 0?o:g.UNKNOWN}var Pa={[g.ABW]:"#91ABC6",[g.AUDIO]:"#1795E3",[g.AVI]:"#E63324",[g.CHM]:"#71C3EB",[g.CODE]:"#71C3EB",[g.CSV]:"#1F7345",[g.DITA]:"#71C3EB",[g.EPUB]:"#85B926",[g.EXCEL]:"#1F7345",[g.FLAC]:"#1795E3",[g.GIF]:"#59B031",[g.GZIP]:"#F8AB36",[g.HTML]:"#71C3EB",[g.IMAGE]:"#59B031",[g.JPEG]:"#59B031",[g.JSON]:"#71C3EB",[g.M4A]:"#1795E3",[g.MOV]:"#E63324",[g.MP3]:"#1795E3",[g.MP4]:"#E63324",[g.OGG]:"#1795E3",[g.PDF]:"#E44948",[g.PNG]:"#59B031",[g.POWERPOINT]:"#B54A2B",[g.RAR]:"#F8AB36",[g.STP]:"#3764B1",[g.TEXT]:"#3162AB",[g.UNKNOWN]:"#999999",[g.VIDEO]:"#E63324",[g.WAV]:"#1795E3",[g.WMA]:"#1795E3",[g.WORD]:"#3162AB",[g.XML]:"#71C3EB",[g.YAML]:"#71C3EB",[g.ZIP]:"#F8AB36"};var dn=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},z=class extends au.FtLitElement{constructor(){super(...arguments),this.ariaHidden="true",this.resolvedIcon=cn.nothing}render(){let e=this.variant&&Object.values(Me).includes(this.variant)?this.variant:Me.fluid_topics,i=e!==Me.material||!!this.value;return cn.html`
283
293
  <i class="ft-icon ft-icon--${e} ft-no-text-select" part="icon icon-${e}">
284
294
  ${(0,lu.unsafeHTML)(this.resolvedIcon)}
285
295
  <slot ?hidden=${i}></slot>
286
296
  </i>
287
- `}getTextContent(){var e,i;return(i=(e=this.slottedContent)===null||e===void 0?void 0:e.assignedNodes().map(r=>r.textContent).join("").trim())!==null&&i!==void 0?i:""}update(e){super.update(e),["value","variant"].some(i=>e.has(i))&&this.resolveIcon()}resolveIcon(){var e,i;let r=this.value||this.getTextContent();switch(this.variant){case Ie.file_format:this.resolvedIcon=(e=m[r.replace("-","_").toUpperCase()])!==null&&e!==void 0?e:r;break;case Ie.material:this.resolvedIcon=this.value||cn.nothing;break;default:this.resolvedIcon=(i=Fi[r.replace("-","_").toUpperCase()])!==null&&i!==void 0?i:r;break}}firstUpdated(e){super.firstUpdated(e),setTimeout(()=>this.resolveIcon())}};z.elementDefinitions={};z.styles=su;dn([(0,pi.property)()],z.prototype,"variant",void 0);dn([(0,pi.property)()],z.prototype,"value",void 0);dn([(0,pi.property)({reflect:!0,attribute:"aria-hidden"})],z.prototype,"ariaHidden",void 0);dn([(0,pi.state)()],z.prototype,"resolvedIcon",void 0);dn([(0,pi.query)("slot")],z.prototype,"slottedContent",void 0);var du=c(h());var cu={"ft-icon":z};(0,du.customElements)(cu);var uu=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Qt=class extends We{render(){var e,i;return this.mimeType?Po.html`
297
+ `}getTextContent(){var e,i;return(i=(e=this.slottedContent)===null||e===void 0?void 0:e.assignedNodes().map(r=>r.textContent).join("").trim())!==null&&i!==void 0?i:""}update(e){super.update(e),["value","variant"].some(i=>e.has(i))&&this.resolveIcon()}resolveIcon(){var e,i;let r=this.value||this.getTextContent();switch(this.variant){case Me.file_format:this.resolvedIcon=(e=g[r.replace("-","_").toUpperCase()])!==null&&e!==void 0?e:r;break;case Me.material:this.resolvedIcon=this.value||cn.nothing;break;default:this.resolvedIcon=(i=zi[r.replace("-","_").toUpperCase()])!==null&&i!==void 0?i:r;break}}firstUpdated(e){super.firstUpdated(e),setTimeout(()=>this.resolveIcon())}};z.elementDefinitions={};z.styles=su;dn([(0,pi.property)()],z.prototype,"variant",void 0);dn([(0,pi.property)()],z.prototype,"value",void 0);dn([(0,pi.property)({reflect:!0,attribute:"aria-hidden"})],z.prototype,"ariaHidden",void 0);dn([(0,pi.state)()],z.prototype,"resolvedIcon",void 0);dn([(0,pi.query)("slot")],z.prototype,"slottedContent",void 0);var du=c(h());var cu={"ft-icon":z};(0,du.customElements)(cu);var uu=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ti=class extends We{render(){var e,i;return this.mimeType?Po.html`
288
298
  <ft-icon part="icon"
289
- variant="${Ie.file_format}"
299
+ variant="${Me.file_format}"
290
300
  value="${Mo(this.mimeType,(0,un.last)((i=(e=this.filename)===null||e===void 0?void 0:e.split("."))!==null&&i!==void 0?i:[]))}"></ft-icon>
291
- `:Po.nothing}};Qt.elementDefinitions={"ft-icon":z};uu([(0,un.redux)({store:"viewer",selector:({descriptor:t})=>t?.mimeType})],Qt.prototype,"mimeType",void 0);uu([(0,un.redux)({store:"viewer",selector:({descriptor:t})=>t?.filename})],Qt.prototype,"filename",void 0);var No=class extends Nt(Qt){};var pu=c(h()),Er=c(x());var _m=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ei=class extends We{render(){return this.documentTitle?Er.html`
301
+ `:Po.nothing}};ti.elementDefinitions={"ft-icon":z};uu([(0,un.redux)({store:"viewer",selector:({descriptor:t})=>t?.mimeType})],ti.prototype,"mimeType",void 0);uu([(0,un.redux)({store:"viewer",selector:({descriptor:t})=>t?.filename})],ti.prototype,"filename",void 0);var No=class extends Nt(ti){};var pu=c(h()),Er=c(S());var _m=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ii=class extends We{render(){return this.documentTitle?Er.html`
292
302
  <ft-typography variant="${H.title}" part="title" element="h1">
293
303
  ${this.documentTitle}
294
304
  </ft-typography>
295
- `:Er.nothing}};ei.elementDefinitions={"ft-typography":F};ei.styles=Er.css`
305
+ `:Er.nothing}};ii.elementDefinitions={"ft-typography":F};ii.styles=Er.css`
296
306
  [part="title"]::part(text) {
297
307
  margin: unset;
298
308
  }
299
- `;_m([(0,pu.redux)({store:"viewer",selector:({document:t})=>t?.title})],ei.prototype,"documentTitle",void 0);var $o=class extends Nt(ei){};var mu=c(x()),gu=c(U());var Bi=c(h());var fu;(function(t){t.RATING="RATING"})(fu||(fu={}));var fi;(function(t){t.udAttachmentsUpdate="ud-attachments-update",t.udRatingUpdate="ud-rating-update",t.clusteringHelperCreated="clustering-helper-created"})(fi||(fi={}));var hi;(function(t){t.FEEDBACK="FEEDBACK",t.RATING="RATING"})(hi||(hi={}));var Uo=class extends Re{getDocument(e){return this.cache.get(e,()=>this.api.getUnstructuredDocument(e))}getAttachments(e){return this.cache.get(`${e}-attachments`,()=>this.api.getUdAttachments(e))}getAttachmentDownloadLink(e,i){return this.makeAbsolute(`${this.api.endpoints.khub.documents.documentId(e).attachments.attachmentId(i).content}?download=true&locationValue=viewer`)}makeAbsolute(e){return this.api.makeAbsolute(e)}async awaitMakeAbsolute(e){return(await this.awaitApi).makeAbsolute(e)}async getDocumentRating(e){return(await this.api.getDocumentRating(e)).publication}async rateDocument(e,i,r){return this.api.rateDocument(e,i,r)}async unrateDocument(e){return this.api.unrateDocument(e)}async sendDocumentFeedback(e,i,r){return this.api.sendDocumentFeedback(e,i,r)}isFeatureAccessible(e,{session:i}){switch(e){case hi.FEEDBACK:return tn(i??[],ie.FEEDBACK_USER);case hi.RATING:return tn(i??[],ie.RATING_USER);default:return!1}}getConfiguration(){return this.cache.get("configuration",()=>this.api.getViewerConfiguration())}clearConfiguration(){this.cache.clear("configuration")}fetchRelativesForDocument(e,i){let r={query:"",paging:{page:1,perPage:-1},scope:"DOCUMENTS",metadataFilters:[{key:e,valueFilter:{negative:!1,values:i}}],sort:[],facets:[]};return this.api.search(r)}getRelativesForDocument(e,i){return this.cache.get("document-relatives-"+e+"-"+i.join("-"),()=>this.fetchRelativesForDocument(e,i))}};var Vi=c(h());var Fo=class t extends ir{static build(e){return new t(In(e),new Uo)}constructor(e,i,r){super(e),this.store=e,this.service=i,this.clusteringHelperProvider=r,this.metadataForSwitchToRelatives=new Set,e.actions.origin(ai.UNSTRUCTURED_DOCUMENT)}async load(){var e,i;let{documentId:r}=this.store.getState();if(r){let[n]=await Promise.all([this.service.getDocument(r),this.loadConfiguration()]);this.store.actions.unstructuredDocument(n),this.store.actions.document({type:po.UNSTRUCTURED_DOCUMENT,id:n.id,lang:(e=n.lang)!==null&&e!==void 0?e:"en-US",title:n.title,metadata:n.metadata,portalUrl:n.viewerUrl});let o=await this.service.awaitMakeAbsolute(n.contentApiEndpoint);this.store.actions.descriptor({id:n.id,portalUrl:n.viewerUrl,filename:n.filename,fingerprint:n.lastEdition,displayName:n.title,alt:(i=n.description)!==null&&i!==void 0?i:n.title,mimeType:n.mimeType,size:0,viewableInCurrentBrowser:n.viewableInCurrentBrowser,contentUrl:o}),this.store.actions.watermark(n.watermark),this.fetchMapRating(),this.metadataForSwitchToRelatives.size>0&&this.fetchRelatives()}return this.store.getState()}async fetchMapRating(){var e;let{documentId:i}=this.store.getState();i&&this.store.actions.documentRating(await((e=this.service)===null||e===void 0?void 0:e.getDocumentRating(i)))}clear(){this.store.clearKeeping("documentId","origin")}reload(){var e;return this.clear(),(e=this.service)===null||e===void 0||e.clearConfiguration(),this.load()}setDocumentId(e){return this.store.actions.documentId(e),this.reload()}async loadConfiguration(){var e;return(e=this.service)===null||e===void 0?void 0:e.getConfiguration().then(i=>this.store.actions.configuration(i))}async fetchRelatives(){var e,i;let r=(e=this.store.getState().document)===null||e===void 0?void 0:e.metadata.filter(n=>{var o;return n.key==((o=this.store.getState().configuration)===null||o===void 0?void 0:o.relativePivotMetadata)}).flatMap(n=>n.values);if(r!==void 0&&r.length>0){let n=await((i=this.service)===null||i===void 0?void 0:i.getRelativesForDocument(this.store.getState().configuration.relativePivotMetadata,r)),o=n?.results.flatMap(s=>s.entries);this.store.actions.relatives(o)}this.updateClusteringHelper()}updateClusteringHelper(){this.clusteringHelper=this.createClusteringHelper(),this.clusteringHelper&&this.store.dispatchEvent(new Event(fi.clusteringHelperCreated))}createClusteringHelper(){var e,i;if(this.clusteringHelperProvider)return this.clusteringHelperProvider();let r=this.store.getState().relatives;if(r){let n=r.find(s=>(0,Vi.accessResultId)(s)==this.store.getState().documentId),o=(i=(e=v.getState().metadataConfiguration)===null||e===void 0?void 0:e.descriptors)!==null&&i!==void 0?i:[];return new Vi.ClusteringHelper(r,n,this.metadataForSwitchToRelatives,o)}}registerMetadataForSwitchToRelatives(e){this.metadataForSwitchToRelatives.add(e),this.store.getState().relatives==null?this.fetchRelatives():this.updateClusteringHelper()}unregisterMetadataForSwitchToRelatives(e){this.metadataForSwitchToRelatives.delete(e),this.updateClusteringHelper()}async getRelativeDocumentUrlForLocale(e){var i;this.store.getState().relatives==null&&await this.fetchRelatives();let r=Vi.ClusteringHelper.findResultWithMetadataValue((i=this.store.getState().relatives)!==null&&i!==void 0?i:[],"ft:locale",e);return(0,Vi.accessResultUrl)(r)}};var Vo=c(h()),Na=c(U());var hu=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},$a=Symbol("ud-viewer-state-manager"),Ke=(0,Vo.applyMixinOnce)(Symbol("toFtUdViewerComponent"),function(t){class e extends t{constructor(){super(...arguments),this.neededUdvRequests=[]}get service(){var r;return(r=this.viewerStateManager)===null||r===void 0?void 0:r.service}willUpdate(r){var n,o,s;super.willUpdate(r),r.has("viewerStateManager")&&(this.unregisterFromUdvStateManager(r.get("viewerStateManager")),this.registerToUdvStateManager(this.viewerStateManager)),r.has("neededUdvRequests")&&((n=this.viewerStateManager)===null||n===void 0||n.unregisterComponent(this,(o=r.get("neededUdvRequests"))!==null&&o!==void 0?o:[]),(s=this.viewerStateManager)===null||s===void 0||s.registerComponent(this,this.neededUdvRequests))}setUdvStateManager(r){this.clearStateManager(),this.viewerStateManager=r,this.addStore(r.store,"viewer")}clearStateManager(){this.viewerStateManager&&(this.removeStore("viewer"),this.viewerStateManager=void 0)}registerToUdvStateManager(r){r&&(r.registerComponent(this,this.neededUdvRequests),this.addStore(r.store,"viewer"))}unregisterFromUdvStateManager(r){r&&(r.unregisterComponent(this,this.neededUdvRequests),this.removeStore("viewer"))}connectedCallback(){super.connectedCallback(),this.registerToUdvStateManager(this.viewerStateManager)}disconnectedCallback(){super.disconnectedCallback(),this.unregisterFromUdvStateManager(this.viewerStateManager)}}return hu([Wr({context:$a,subscribe:!0}),(0,Na.state)()],e.prototype,"viewerStateManager",void 0),hu([(0,Na.state)({hasChanged:Vo.hasChanged})],e.prototype,"neededUdvRequests",void 0),e});var Bo=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},mi=class extends Bi.FtLitElementRedux{constructor(){super(...arguments),this.viewerStateManager=Fo.build(this.id||(0,Bi.randomId)(6))}render(){return mu.html`
309
+ `;_m([(0,pu.redux)({store:"viewer",selector:({document:t})=>t?.title})],ii.prototype,"documentTitle",void 0);var $o=class extends Nt(ii){};var mu=c(S()),gu=c(U());var Wi=c(h());var fu;(function(t){t.RATING="RATING"})(fu||(fu={}));var fi;(function(t){t.udAttachmentsUpdate="ud-attachments-update",t.udRatingUpdate="ud-rating-update",t.clusteringHelperCreated="clustering-helper-created"})(fi||(fi={}));var hi;(function(t){t.FEEDBACK="FEEDBACK",t.RATING="RATING"})(hi||(hi={}));var Uo=class extends Re{getDocument(e){return this.cache.get(e,()=>this.api.getUnstructuredDocument(e))}getAttachments(e){return this.cache.get(`${e}-attachments`,()=>this.api.getUdAttachments(e))}getAttachmentDownloadLink(e,i){return this.makeAbsolute(`${this.api.endpoints.khub.documents.documentId(e).attachments.attachmentId(i).content}?download=true&locationValue=viewer`)}makeAbsolute(e){return this.api.makeAbsolute(e)}async awaitMakeAbsolute(e){return(await this.awaitApi).makeAbsolute(e)}async getDocumentRating(e){return(await this.api.getDocumentRating(e)).publication}async rateDocument(e,i,r){return this.api.rateDocument(e,i,r)}async unrateDocument(e){return this.api.unrateDocument(e)}async sendDocumentFeedback(e,i,r){return this.api.sendDocumentFeedback(e,i,r)}isFeatureAccessible(e,{session:i}){switch(e){case hi.FEEDBACK:return tn(i??[],ie.FEEDBACK_USER);case hi.RATING:return tn(i??[],ie.RATING_USER);default:return!1}}getConfiguration(){return this.cache.get("configuration",()=>this.api.getViewerConfiguration())}clearConfiguration(){this.cache.clear("configuration")}fetchRelativesForDocument(e,i){let r={query:"",paging:{page:1,perPage:-1},scope:"DOCUMENTS",metadataFilters:[{key:e,valueFilter:{negative:!1,values:i}}],sort:[],facets:[]};return this.api.search(r)}getRelativesForDocument(e,i){return this.cache.get("document-relatives-"+e+"-"+i.join("-"),()=>this.fetchRelativesForDocument(e,i))}};var ji=c(h());var Fo=class t extends sr{static build(e){return new t(In(e),new Uo)}constructor(e,i,r){super(e),this.store=e,this.service=i,this.clusteringHelperProvider=r,this.metadataForSwitchToRelatives=new Set,e.actions.origin(ci.UNSTRUCTURED_DOCUMENT)}async load(){var e,i;let{documentId:r}=this.store.getState();if(r){let[n]=await Promise.all([this.service.getDocument(r),this.loadConfiguration()]);this.store.actions.unstructuredDocument(n),this.store.actions.document({type:po.UNSTRUCTURED_DOCUMENT,id:n.id,lang:(e=n.lang)!==null&&e!==void 0?e:"en-US",title:n.title,metadata:n.metadata,portalUrl:n.viewerUrl});let o=await this.service.awaitMakeAbsolute(n.contentApiEndpoint);this.store.actions.descriptor({id:n.id,portalUrl:n.viewerUrl,filename:n.filename,fingerprint:n.lastEdition,displayName:n.title,alt:(i=n.description)!==null&&i!==void 0?i:n.title,mimeType:n.mimeType,size:0,viewableInCurrentBrowser:n.viewableInCurrentBrowser,contentUrl:o}),this.store.actions.watermark(n.watermark),this.fetchMapRating(),this.metadataForSwitchToRelatives.size>0&&this.fetchRelatives()}return this.store.getState()}async fetchMapRating(){var e;let{documentId:i}=this.store.getState();i&&this.store.actions.documentRating(await((e=this.service)===null||e===void 0?void 0:e.getDocumentRating(i)))}clear(){this.store.clearKeeping("documentId","origin")}reload(){var e;return this.clear(),(e=this.service)===null||e===void 0||e.clearConfiguration(),this.load()}setDocumentId(e){return this.store.actions.documentId(e),this.reload()}async loadConfiguration(){var e;return(e=this.service)===null||e===void 0?void 0:e.getConfiguration().then(i=>this.store.actions.configuration(i))}async fetchRelatives(){var e,i;let r=(e=this.store.getState().document)===null||e===void 0?void 0:e.metadata.filter(n=>{var o;return n.key==((o=this.store.getState().configuration)===null||o===void 0?void 0:o.relativePivotMetadata)}).flatMap(n=>n.values);if(r!==void 0&&r.length>0){let n=await((i=this.service)===null||i===void 0?void 0:i.getRelativesForDocument(this.store.getState().configuration.relativePivotMetadata,r)),o=n?.results.flatMap(s=>s.entries);this.store.actions.relatives(o)}this.updateClusteringHelper()}updateClusteringHelper(){this.clusteringHelper=this.createClusteringHelper(),this.clusteringHelper&&this.store.dispatchEvent(new Event(fi.clusteringHelperCreated))}createClusteringHelper(){var e,i;if(this.clusteringHelperProvider)return this.clusteringHelperProvider();let r=this.store.getState().relatives;if(r){let n=r.find(s=>(0,ji.accessResultId)(s)==this.store.getState().documentId),o=(i=(e=x.getState().metadataConfiguration)===null||e===void 0?void 0:e.descriptors)!==null&&i!==void 0?i:[];return new ji.ClusteringHelper(r,n,this.metadataForSwitchToRelatives,o)}}registerMetadataForSwitchToRelatives(e){this.metadataForSwitchToRelatives.add(e),this.store.getState().relatives==null?this.fetchRelatives():this.updateClusteringHelper()}unregisterMetadataForSwitchToRelatives(e){this.metadataForSwitchToRelatives.delete(e),this.updateClusteringHelper()}async getRelativeDocumentUrlForLocale(e){var i;this.store.getState().relatives==null&&await this.fetchRelatives();let r=ji.ClusteringHelper.findResultWithMetadataValue((i=this.store.getState().relatives)!==null&&i!==void 0?i:[],"ft:locale",e);return(0,ji.accessResultUrl)(r)}};var Vo=c(h()),Na=c(U());var hu=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},$a=Symbol("ud-viewer-state-manager"),Ge=(0,Vo.applyMixinOnce)(Symbol("toFtUdViewerComponent"),function(t){class e extends t{constructor(){super(...arguments),this.neededUdvRequests=[]}get service(){var r;return(r=this.viewerStateManager)===null||r===void 0?void 0:r.service}willUpdate(r){var n,o,s;super.willUpdate(r),r.has("viewerStateManager")&&(this.unregisterFromUdvStateManager(r.get("viewerStateManager")),this.registerToUdvStateManager(this.viewerStateManager)),r.has("neededUdvRequests")&&((n=this.viewerStateManager)===null||n===void 0||n.unregisterComponent(this,(o=r.get("neededUdvRequests"))!==null&&o!==void 0?o:[]),(s=this.viewerStateManager)===null||s===void 0||s.registerComponent(this,this.neededUdvRequests))}setUdvStateManager(r){this.clearStateManager(),this.viewerStateManager=r,this.addStore(r.store,"viewer")}clearStateManager(){this.viewerStateManager&&(this.removeStore("viewer"),this.viewerStateManager=void 0)}registerToUdvStateManager(r){r&&(r.registerComponent(this,this.neededUdvRequests),this.addStore(r.store,"viewer"))}unregisterFromUdvStateManager(r){r&&(r.unregisterComponent(this,this.neededUdvRequests),this.removeStore("viewer"))}connectedCallback(){super.connectedCallback(),this.registerToUdvStateManager(this.viewerStateManager)}disconnectedCallback(){super.disconnectedCallback(),this.unregisterFromUdvStateManager(this.viewerStateManager)}}return hu([Wr({context:$a,subscribe:!0}),(0,Na.state)()],e.prototype,"viewerStateManager",void 0),hu([(0,Na.state)({hasChanged:Vo.hasChanged})],e.prototype,"neededUdvRequests",void 0),e});var Bo=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},mi=class extends Wi.FtLitElementRedux{constructor(){super(...arguments),this.viewerStateManager=Fo.build(this.id||(0,Wi.randomId)(6))}render(){return mu.html`
300
310
  <slot></slot>
301
- `}willUpdate(e){super.willUpdate(e),e.has("documentId")&&this.initStateManager()}async initStateManager(){let e=await this.viewerStateManager.setDocumentId(this.documentId);this.documentId&&this.dispatchEvent(new Di(e))}connectedCallback(){super.connectedCallback(),this.addStore(v)}onAuthenticationChange(){this.viewerStateManager.reload()}async reactToUiLocaleChanged(e){var i;if(!((i=v.getState().localesConfiguration)===null||i===void 0)&&i.uiLanguageSetsReaderLanguage){ur===null||ur===void 0||ur.stopReloadDebouncer();let r=await this.viewerStateManager.getRelativeDocumentUrlForLocale(e.detail.uiLocale);r?window.location.assign(r):window.location.reload()}}};Bo([(0,gu.property)()],mi.prototype,"documentId",void 0);Bo([jr({context:$a})],mi.prototype,"viewerStateManager",void 0);Bo([(0,Bi.reduxEventListener)({eventName:wt.eventName})],mi.prototype,"onAuthenticationChange",null);Bo([(0,Bi.reduxEventListener)({store:v.name,eventName:Ti.eventName})],mi.prototype,"reactToUiLocaleChanged",null);var Ho=class extends Ke(ce){};var zo=class extends Ke(Jt){};var jo=class extends Ke(ei){};var Wo=class extends Ke(Qt){};var rs=c(h());var ft=class t{static build(e){return new t(e)}static buildCustom(e){return new t(e,!0)}static fromGwt(e){return new t(e)}get service(){return this.custom?bo:dr}constructor(e,i=!1){this.name=e,this.custom=i,this.properties=new Proxy({},{get:(r,n)=>{let o=n;return s=>({context:this.name,key:o,custom:this.custom,args:typeof s=="function"?void 0:s,argsProvider:typeof s=="function"?s:void 0})}}),this.messages=new Proxy({},{get:(r,n)=>(...o)=>this.service.resolveMessage(this.name,n,...o)}),this.rawMessages=new Proxy({},{get:(r,n)=>this.service.resolveRawMessage(this.name,n)}),this.keys=new Proxy({},{get:(r,n)=>()=>n}),this.attributes=new Proxy({},{get:(r,n)=>()=>({context:this.name,key:n,message:this.service.resolveRawMessage(this.name,n)})})}};var Ar=c(h());var yu=c(U());var Ua=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[i,r]=e.split(".");return{context:i,key:r,custom:i!=="officialContext",message:""}}return{message:e}}}toAttribute(e){if(e!=null)return JSON.stringify(e)}isI18nKey(e){return e.match(/^[\w-]+\.[\w-]+$/)}},_r=new Ua;var Am=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},fn=Symbol("i18nAttributes"),vu=Symbol("i18nListAttributes"),hn=Symbol("i18nProperties"),Ko=Symbol("i18nContexts"),pn=Symbol("i18nUnsubs"),ht=(0,Ar.applyMixinOnce)(Symbol("withI18n"),function(t){var e,i;class r extends t{constructor(){super(...arguments),this.useCustomMessageContexts=!1,this[e]=new Map,this[i]=new Map}getI18nService(o){return o??this.useCustomMessageContexts?bo:dr}i18n(o){let{context:s,key:a,message:l}=o,{custom:d,args:u,argsProvider:p}=o;if(s&&a){this.hasI18nContext(s)||this.addI18nContext(s,void 0,d);let f=u??(p?p(this):[]);return this.getI18nService(d).resolveMessage(s,a,...f)}return l}async awaitI18n(o){let{context:s,custom:a}=o;return s&&await this.getI18nService(a).prepareContext(s),this.i18n(o)}customI18n(o,s){if(_r.isI18nKey(o)){let[a,l]=o.split(".");return this.i18n({custom:!0,context:a,key:l,...s})||o}return o}firstUpdated(o){super.firstUpdated(o),this.updateI18nAttributes(()=>!0),this.updateI18nProperties(()=>!0)}update(o){super.update(o),this.updateI18nAttributes((s,a,l)=>o.has(a)||typeof s.argsProvider=="function"),this.updateI18nProperties(s=>typeof s.argsProvider=="function")}onI18nUpdate(o){this.updateI18nAttributes((s,a,l)=>{var d;return((d=l?.context)===null||d===void 0?void 0:d.toLowerCase())===o}),this.updateI18nProperties(s=>s.context.toLowerCase()===o),this.requestUpdate()}updateI18nAttributes(o){var s,a;let l=this,d=(u,p,f)=>f?.context&&f.key&&o(u,p,f)?{...f,message:this.i18n({context:f.context,key:f.key,custom:f.custom,...u})}:f;(s=this[fn])===null||s===void 0||s.forEach((u,p)=>l[p]=d(u,p,l[p])),(a=this[vu])===null||a===void 0||a.forEach((u,p)=>{var f;return l[p]=(f=l[p])===null||f===void 0?void 0:f.map(y=>d(u,p,y))})}updateI18nProperties(o){var s;(s=this[hn])===null||s===void 0||s.forEach((a,l)=>{o(a,l)&&(this[l]=this.i18n(a))})}addI18nMessages(o,s,a){console.warn('Deprecated usage of method "addI18nMessages", use "addI18nContext" instead.'),this.addI18nContext(o,s,a)}addI18nContext(o,s,a){let l=(typeof o=="string"?o:o.name).toLowerCase();a=typeof o=="string"?a:o.custom,this[Ko].set(l,{isCustomContext:a}),this[pn].has(l)||this[pn].set(l,this.getI18nService(a).subscribe(l,()=>this.onI18nUpdate(l))),this.getI18nService(a).prepareContext(l,s)}hasI18nContext(o){return this[Ko].has(o.toLowerCase())}connectedCallback(){super.connectedCallback(),this[Ko].forEach((o,s)=>this.addI18nContext(s,void 0,o.isCustomContext))}disconnectedCallback(){super.disconnectedCallback(),this[pn].forEach(o=>o()),this[pn].clear()}}return e=Ko,i=pn,Am([(0,yu.property)({type:Boolean})],r.prototype,"useCustomMessageContexts",void 0),r}),Go=class extends ht(Ar.FtLitElement){},qo=class extends ht(Ar.FtLitElementRedux){};var Yo=(t,e)=>(i,r)=>{var n,o;i.constructor.createProperty(r,e??{attribute:!1,type:String});let s={...t,key:(n=t.key)!==null&&n!==void 0?n:r};i[hn]=(o=i[hn])!==null&&o!==void 0?o:new Map,i[hn].set(r,s)};var bu=c(x());var xu=bu.css`
302
- `;var Zo=c(x()),Tr=c(U()),Xo=c(h());var Cr=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},mt=class extends qo{constructor(){super(),this.editorMode=!1,this.editorMessage="Select a context and a label key.",this.addStore(v)}render(){return!this.key||!this.context?this.editorMode?this.editorMessage:Zo.nothing:Zo.html`
311
+ `}willUpdate(e){super.willUpdate(e),e.has("documentId")&&this.initStateManager()}async initStateManager(){let e=await this.viewerStateManager.setDocumentId(this.documentId);this.documentId&&this.dispatchEvent(new Li(e))}connectedCallback(){super.connectedCallback(),this.addStore(x)}onAuthenticationChange(){this.viewerStateManager.reload()}async reactToUiLocaleChanged(e){var i;if(!((i=x.getState().localesConfiguration)===null||i===void 0)&&i.uiLanguageSetsReaderLanguage){mr===null||mr===void 0||mr.stopReloadDebouncer();let r=await this.viewerStateManager.getRelativeDocumentUrlForLocale(e.detail.uiLocale);r?window.location.assign(r):window.location.reload()}}};Bo([(0,gu.property)()],mi.prototype,"documentId",void 0);Bo([jr({context:$a})],mi.prototype,"viewerStateManager",void 0);Bo([(0,Wi.reduxEventListener)({eventName:wt.eventName})],mi.prototype,"onAuthenticationChange",null);Bo([(0,Wi.reduxEventListener)({store:x.name,eventName:Ti.eventName})],mi.prototype,"reactToUiLocaleChanged",null);var Ho=class extends Ge(ce){};var zo=class extends Ge(ei){};var jo=class extends Ge(ii){};var Wo=class extends Ge(ti){};var rs=c(h());var ft=class t{static build(e){return new t(e)}static buildCustom(e){return new t(e,!0)}static fromGwt(e){return new t(e)}get service(){return this.custom?xo:hr}constructor(e,i=!1){this.name=e,this.custom=i,this.properties=new Proxy({},{get:(r,n)=>{let o=n;return s=>({context:this.name,key:o,custom:this.custom,args:typeof s=="function"?void 0:s,argsProvider:typeof s=="function"?s:void 0})}}),this.messages=new Proxy({},{get:(r,n)=>(...o)=>this.service.resolveMessage(this.name,n,...o)}),this.rawMessages=new Proxy({},{get:(r,n)=>this.service.resolveRawMessage(this.name,n)}),this.keys=new Proxy({},{get:(r,n)=>()=>n}),this.attributes=new Proxy({},{get:(r,n)=>()=>({context:this.name,key:n,message:this.service.resolveRawMessage(this.name,n)})})}};var Ar=c(h());var yu=c(U());var Ua=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[i,r]=e.split(".");return{context:i,key:r,custom:i!=="officialContext",message:""}}return{message:e}}}toAttribute(e){if(e!=null)return JSON.stringify(e)}isI18nKey(e){return e.match(/^[\w-]+\.[\w-]+$/)}},_r=new Ua;var Am=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},fn=Symbol("i18nAttributes"),vu=Symbol("i18nListAttributes"),hn=Symbol("i18nProperties"),Ko=Symbol("i18nContexts"),pn=Symbol("i18nUnsubs"),ht=(0,Ar.applyMixinOnce)(Symbol("withI18n"),function(t){var e,i;class r extends t{constructor(){super(...arguments),this.useCustomMessageContexts=!1,this[e]=new Map,this[i]=new Map}getI18nService(o){return o??this.useCustomMessageContexts?xo:hr}i18n(o){let{context:s,key:a,message:l}=o,{custom:d,args:u,argsProvider:p}=o;if(s&&a){this.hasI18nContext(s)||this.addI18nContext(s,void 0,d);let f=u??(p?p(this):[]);return this.getI18nService(d).resolveMessage(s,a,...f)}return l}async awaitI18n(o){let{context:s,custom:a}=o;return s&&await this.getI18nService(a).prepareContext(s),this.i18n(o)}customI18n(o,s){if(_r.isI18nKey(o)){let[a,l]=o.split(".");return this.i18n({custom:!0,context:a,key:l,...s})||o}return o}firstUpdated(o){super.firstUpdated(o),this.updateI18nAttributes(()=>!0),this.updateI18nProperties(()=>!0)}update(o){super.update(o),this.updateI18nAttributes((s,a,l)=>o.has(a)||typeof s.argsProvider=="function"),this.updateI18nProperties(s=>typeof s.argsProvider=="function")}onI18nUpdate(o){this.updateI18nAttributes((s,a,l)=>{var d;return((d=l?.context)===null||d===void 0?void 0:d.toLowerCase())===o}),this.updateI18nProperties(s=>s.context.toLowerCase()===o),this.requestUpdate()}updateI18nAttributes(o){var s,a;let l=this,d=(u,p,f)=>f?.context&&f.key&&o(u,p,f)?{...f,message:this.i18n({context:f.context,key:f.key,custom:f.custom,...u})}:f;(s=this[fn])===null||s===void 0||s.forEach((u,p)=>l[p]=d(u,p,l[p])),(a=this[vu])===null||a===void 0||a.forEach((u,p)=>{var f;return l[p]=(f=l[p])===null||f===void 0?void 0:f.map(y=>d(u,p,y))})}updateI18nProperties(o){var s;(s=this[hn])===null||s===void 0||s.forEach((a,l)=>{o(a,l)&&(this[l]=this.i18n(a))})}addI18nMessages(o,s,a){console.warn('Deprecated usage of method "addI18nMessages", use "addI18nContext" instead.'),this.addI18nContext(o,s,a)}addI18nContext(o,s,a){let l=(typeof o=="string"?o:o.name).toLowerCase();a=typeof o=="string"?a:o.custom,this[Ko].set(l,{isCustomContext:a}),this[pn].has(l)||this[pn].set(l,this.getI18nService(a).subscribe(l,()=>this.onI18nUpdate(l))),this.getI18nService(a).prepareContext(l,s)}hasI18nContext(o){return this[Ko].has(o.toLowerCase())}connectedCallback(){super.connectedCallback(),this[Ko].forEach((o,s)=>this.addI18nContext(s,void 0,o.isCustomContext))}disconnectedCallback(){super.disconnectedCallback(),this[pn].forEach(o=>o()),this[pn].clear()}}return e=Ko,i=pn,Am([(0,yu.property)({type:Boolean})],r.prototype,"useCustomMessageContexts",void 0),r}),Go=class extends ht(Ar.FtLitElement){},qo=class extends ht(Ar.FtLitElementRedux){};var Yo=(t,e)=>(i,r)=>{var n,o;i.constructor.createProperty(r,e??{attribute:!1,type:String});let s={...t,key:(n=t.key)!==null&&n!==void 0?n:r};i[hn]=(o=i[hn])!==null&&o!==void 0?o:new Map,i[hn].set(r,s)};var xu=c(S());var bu=xu.css`
312
+ `;var Zo=c(S()),Tr=c(U()),Xo=c(h());var Cr=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},mt=class extends qo{constructor(){super(),this.editorMode=!1,this.editorMessage="Select a context and a label key.",this.addStore(x)}render(){return!this.key||!this.context?this.editorMode?this.editorMessage:Zo.nothing:Zo.html`
303
313
  <span class="ft-i18n">
304
314
  ${this.i18n({context:this.context,key:this.key,args:Array.isArray(this.args)?this.args:[]})}
305
315
  </span>
306
- `}update(e){var i;super.update(e),["context","key","defaultMessage"].some(r=>e.has(r))&&this.context&&this.key&&this.addI18nContext(this.context,{[this.key]:(i=this.defaultMessage)!==null&&i!==void 0?i:""})}};mt.elementDefinitions={};mt.styles=xu;Cr([(0,Xo.redux)()],mt.prototype,"editorMode",void 0);Cr([(0,Tr.property)()],mt.prototype,"context",void 0);Cr([(0,Tr.property)()],mt.prototype,"key",void 0);Cr([(0,Xo.jsonProperty)([])],mt.prototype,"args",void 0);Cr([(0,Tr.property)()],mt.prototype,"defaultMessage",void 0);Cr([(0,Tr.state)()],mt.prototype,"editorMessage",void 0);var wu=c(h());var Su={"ft-i18n":mt};(0,wu.customElements)(Su);var ve=c(h()),Eu={itemsGap:ve.FtCssVariableFactory.create("--ft-reader-attachments-items-gap","","SIZE","8px"),itemPadding:ve.FtCssVariableFactory.create("--ft-reader-attachments-item-padding","","SIZE","8px"),itemBorderWidth:ve.FtCssVariableFactory.create("--ft-reader-attachments-item-border-width","","SIZE","1px"),itemBorderColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-border-color","",ve.designSystemVariables.colorOutline),itemBorderRadius:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-border-radius","",ve.designSystemVariables.borderRadiusS),itemBackgroundColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-background-color","",ve.designSystemVariables.colorSurface),itemTextColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-text-color","",ve.designSystemVariables.colorOnSurfaceMedium),itemHoverBackgroundColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-hover-background-color","",ve.designSystemVariables.colorPrimary),itemHoverTextColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-hover-text-color","",ve.designSystemVariables.colorOnSurfaceHigh),fileFormatIconSize:ve.FtCssVariableFactory.create("--ft-reader-attachments-file-format-icon-size","","SIZE","30px"),downloadIconSize:ve.FtCssVariableFactory.create("--ft-reader-attachments-down-icon-size","","SIZE","20px")};var is=c(h());var Qo=c(h()),Cu=c(U());var Jo;(function(t){t.clusteringHelperCreated="clustering-helper-created",t.mapAttachmentsUpdate="map-attachments-update",t.visibleTopicChange="visible-topic-change",t.requestedTopicNotFound="requested-topic-not-found"})(Jo||(Jo={}));var _u;(function(t){t.FEEDBACK="FEEDBACK",t.RATING="RATING",t.PRINT="PRINT",t.BOOKMARK="BOOKMARK",t.COLLECTIONS="COLLECTIONS",t.PERSONAL_BOOKS="PERSONAL_BOOKS"})(_u||(_u={}));var Cm=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Va=class extends Event{constructor(){super("register-ft-reader-component",{bubbles:!0,composed:!0})}},Fa=Symbol("registerInterval"),Ba=(0,Qo.applyMixinOnce)(Symbol("toFtReaderComponent"),function(t){var e;class i extends t{constructor(){super(...arguments),this[e]=0}setReaderStateManager(n){this.clearStateManager(),this.stateManager=n,this.addStore(n.store,"reader")}clearStateManager(){this.stateManager&&(this.removeStore("reader"),this.stateManager=void 0)}get service(){var n;return(n=this.stateManager)===null||n===void 0?void 0:n.service}connectedCallback(){super.connectedCallback(),this[Fa]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null?window.clearInterval(this[Fa]):this.dispatchEvent(new Va)}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return e=Fa,Cm([(0,Cu.state)()],i.prototype,"stateManager",void 0),i}),Au=class extends Ba(Qo.FtLitElementRedux){};var Ha=ft.build("designedReaderAttachments"),Tu={download:"Download \u201C{0}\u201D"};var Hi=c(x()),Rr=c(U()),Or=c(h()),Vu=c(fr());var Bu=c(rt());var Nu=c(x()),Oe=c(U()),$u=c(rt()),mn=c(h());var Mu=c(x()),ge=c(h()),Ou=ge.FtCssVariableFactory.extend("--ft-ripple-color","",ge.designSystemVariables.colorContent),G={color:Ou,backgroundColor:ge.FtCssVariableFactory.extend("--ft-ripple-background-color","",Ou),opacityContentOnSurfacePressed:ge.FtCssVariableFactory.external(ge.designSystemVariables.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:ge.FtCssVariableFactory.external(ge.designSystemVariables.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:ge.FtCssVariableFactory.external(ge.designSystemVariables.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:ge.FtCssVariableFactory.external(ge.designSystemVariables.opacityContentOnSurfaceSelected,"Design system"),borderRadius:ge.FtCssVariableFactory.create("--ft-ripple-border-radius","","SIZE","0px")},ku=ge.FtCssVariableFactory.extend("--ft-ripple-color","",ge.designSystemVariables.colorPrimary),Lu={color:ku,backgroundColor:ge.FtCssVariableFactory.extend("--ft-ripple-background-color","",ku)},Du=ge.FtCssVariableFactory.extend("--ft-ripple-color","",ge.designSystemVariables.colorSecondary),Iu={color:Du,backgroundColor:ge.FtCssVariableFactory.extend("--ft-ripple-background-color","",Du)},Pu=Mu.css`
316
+ `}update(e){var i;super.update(e),["context","key","defaultMessage"].some(r=>e.has(r))&&this.context&&this.key&&this.addI18nContext(this.context,{[this.key]:(i=this.defaultMessage)!==null&&i!==void 0?i:""})}};mt.elementDefinitions={};mt.styles=bu;Cr([(0,Xo.redux)()],mt.prototype,"editorMode",void 0);Cr([(0,Tr.property)()],mt.prototype,"context",void 0);Cr([(0,Tr.property)()],mt.prototype,"key",void 0);Cr([(0,Xo.jsonProperty)([])],mt.prototype,"args",void 0);Cr([(0,Tr.property)()],mt.prototype,"defaultMessage",void 0);Cr([(0,Tr.state)()],mt.prototype,"editorMessage",void 0);var wu=c(h());var Su={"ft-i18n":mt};(0,wu.customElements)(Su);var ve=c(h()),Eu={itemsGap:ve.FtCssVariableFactory.create("--ft-reader-attachments-items-gap","","SIZE","8px"),itemPadding:ve.FtCssVariableFactory.create("--ft-reader-attachments-item-padding","","SIZE","8px"),itemBorderWidth:ve.FtCssVariableFactory.create("--ft-reader-attachments-item-border-width","","SIZE","1px"),itemBorderColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-border-color","",ve.designSystemVariables.colorOutline),itemBorderRadius:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-border-radius","",ve.designSystemVariables.borderRadiusS),itemBackgroundColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-background-color","",ve.designSystemVariables.colorSurface),itemTextColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-text-color","",ve.designSystemVariables.colorOnSurfaceMedium),itemHoverBackgroundColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-hover-background-color","",ve.designSystemVariables.colorPrimary),itemHoverTextColor:ve.FtCssVariableFactory.extend("--ft-reader-attachments-item-hover-text-color","",ve.designSystemVariables.colorOnSurfaceHigh),fileFormatIconSize:ve.FtCssVariableFactory.create("--ft-reader-attachments-file-format-icon-size","","SIZE","30px"),downloadIconSize:ve.FtCssVariableFactory.create("--ft-reader-attachments-down-icon-size","","SIZE","20px")};var is=c(h());var Qo=c(h()),Cu=c(U());var Jo;(function(t){t.clusteringHelperCreated="clustering-helper-created",t.mapAttachmentsUpdate="map-attachments-update",t.visibleTopicChange="visible-topic-change",t.requestedTopicNotFound="requested-topic-not-found"})(Jo||(Jo={}));var _u;(function(t){t.FEEDBACK="FEEDBACK",t.RATING="RATING",t.PRINT="PRINT",t.BOOKMARK="BOOKMARK",t.COLLECTIONS="COLLECTIONS",t.PERSONAL_BOOKS="PERSONAL_BOOKS"})(_u||(_u={}));var Cm=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Va=class extends Event{constructor(){super("register-ft-reader-component",{bubbles:!0,composed:!0})}},Fa=Symbol("registerInterval"),Ba=(0,Qo.applyMixinOnce)(Symbol("toFtReaderComponent"),function(t){var e;class i extends t{constructor(){super(...arguments),this[e]=0}setReaderStateManager(n){this.clearStateManager(),this.stateManager=n,this.addStore(n.store,"reader")}clearStateManager(){this.stateManager&&(this.removeStore("reader"),this.stateManager=void 0)}get service(){var n;return(n=this.stateManager)===null||n===void 0?void 0:n.service}connectedCallback(){super.connectedCallback(),this[Fa]=window.setInterval(()=>this.tryToRegisterToContext(),50)}tryToRegisterToContext(){this.stateManager!=null?window.clearInterval(this[Fa]):this.dispatchEvent(new Va)}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return e=Fa,Cm([(0,Cu.state)()],i.prototype,"stateManager",void 0),i}),Au=class extends Ba(Qo.FtLitElementRedux){};var Ha=ft.build("designedReaderAttachments"),Tu={download:"Download \u201C{0}\u201D"};var Ki=c(S()),Rr=c(U()),Or=c(h()),Vu=c(yr());var Bu=c(ot());var Nu=c(S()),Oe=c(U()),$u=c(ot()),mn=c(h());var Mu=c(S()),ge=c(h()),Ou=ge.FtCssVariableFactory.extend("--ft-ripple-color","",ge.designSystemVariables.colorContent),G={color:Ou,backgroundColor:ge.FtCssVariableFactory.extend("--ft-ripple-background-color","",Ou),opacityContentOnSurfacePressed:ge.FtCssVariableFactory.external(ge.designSystemVariables.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:ge.FtCssVariableFactory.external(ge.designSystemVariables.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:ge.FtCssVariableFactory.external(ge.designSystemVariables.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:ge.FtCssVariableFactory.external(ge.designSystemVariables.opacityContentOnSurfaceSelected,"Design system"),borderRadius:ge.FtCssVariableFactory.create("--ft-ripple-border-radius","","SIZE","0px")},ku=ge.FtCssVariableFactory.extend("--ft-ripple-color","",ge.designSystemVariables.colorPrimary),Du={color:ku,backgroundColor:ge.FtCssVariableFactory.extend("--ft-ripple-background-color","",ku)},Lu=ge.FtCssVariableFactory.extend("--ft-ripple-color","",ge.designSystemVariables.colorSecondary),Iu={color:Lu,backgroundColor:ge.FtCssVariableFactory.extend("--ft-ripple-background-color","",Lu)},Pu=Mu.css`
307
317
  :host {
308
318
  display: contents;
309
319
  }
@@ -366,11 +376,11 @@
366
376
  }
367
377
 
368
378
  .ft-ripple.ft-ripple--primary .ft-ripple--background {
369
- background-color: ${Lu.backgroundColor};
379
+ background-color: ${Du.backgroundColor};
370
380
  }
371
381
 
372
382
  .ft-ripple.ft-ripple--primary .ft-ripple--effect {
373
- background-color: ${Lu.color};
383
+ background-color: ${Du.color};
374
384
  }
375
385
 
376
386
  .ft-ripple .ft-ripple--background {
@@ -415,7 +425,7 @@
415
425
  opacity: ${G.opacityContentOnSurfacePressed};
416
426
  transform: translate(-50%, -50%) scale(1);
417
427
  }
418
- `;var Ge=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},M=class extends mn.FtLitElement{constructor(){super(...arguments),this.primary=!1,this.secondary=!1,this.unbounded=!1,this.activated=!1,this.selected=!1,this.disabled=!1,this.hovered=!1,this.focused=!1,this.pressed=!1,this.rippling=!1,this.originX=0,this.originY=0,this.debouncer=new mn.Debouncer(1e3),this.onTransitionStart=e=>{e.propertyName==="transform"&&(this.rippling=this.pressed,this.debouncer.run(()=>this.rippling=!1))},this.onTransitionEnd=e=>{e.propertyName==="transform"&&(this.rippling=!1)},this.setupDebouncer=new mn.Debouncer(10),this.moveRipple=e=>{var i,r;let{x:n,y:o}=this.getCoordinates(e),s=(r=(i=this.ripple)===null||i===void 0?void 0:i.getBoundingClientRect())!==null&&r!==void 0?r:{x:0,y:0,width:0,height:0};this.originX=Math.round(n!=null?n-s.x:s.width/2),this.originY=Math.round(o!=null?o-s.y:s.height/2)},this.startPress=e=>{this.moveRipple(e),this.pressed=!this.isIgnored(e)},this.endPress=()=>{this.pressed=!1},this.startHover=e=>{this.hovered=!this.isIgnored(e)},this.endHover=()=>{this.hovered=!1},this.startFocus=e=>{this.focused=this.isFocusVisible(e?.target)&&!this.isIgnored(e)},this.endFocus=()=>{this.focused=!1}}render(){let e={"ft-ripple":!0,"ft-ripple--primary":this.primary,"ft-ripple--secondary":this.secondary,"ft-ripple--unbounded":this.unbounded,"ft-ripple--selected":(this.selected||this.activated)&&!this.disabled,"ft-ripple--pressed":(this.pressed||this.rippling)&&!this.disabled,"ft-ripple--hovered":this.hovered&&!this.disabled,"ft-ripple--focused":this.focused&&!this.disabled};return Nu.html`
428
+ `;var qe=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},M=class extends mn.FtLitElement{constructor(){super(...arguments),this.primary=!1,this.secondary=!1,this.unbounded=!1,this.activated=!1,this.selected=!1,this.disabled=!1,this.hovered=!1,this.focused=!1,this.pressed=!1,this.rippling=!1,this.originX=0,this.originY=0,this.debouncer=new mn.Debouncer(1e3),this.onTransitionStart=e=>{e.propertyName==="transform"&&(this.rippling=this.pressed,this.debouncer.run(()=>this.rippling=!1))},this.onTransitionEnd=e=>{e.propertyName==="transform"&&(this.rippling=!1)},this.setupDebouncer=new mn.Debouncer(10),this.moveRipple=e=>{var i,r;let{x:n,y:o}=this.getCoordinates(e),s=(r=(i=this.ripple)===null||i===void 0?void 0:i.getBoundingClientRect())!==null&&r!==void 0?r:{x:0,y:0,width:0,height:0};this.originX=Math.round(n!=null?n-s.x:s.width/2),this.originY=Math.round(o!=null?o-s.y:s.height/2)},this.startPress=e=>{this.moveRipple(e),this.pressed=!this.isIgnored(e)},this.endPress=()=>{this.pressed=!1},this.startHover=e=>{this.hovered=!this.isIgnored(e)},this.endHover=()=>{this.hovered=!1},this.startFocus=e=>{this.focused=this.isFocusVisible(e?.target)&&!this.isIgnored(e)},this.endFocus=()=>{this.focused=!1}}render(){let e={"ft-ripple":!0,"ft-ripple--primary":this.primary,"ft-ripple--secondary":this.secondary,"ft-ripple--unbounded":this.unbounded,"ft-ripple--selected":(this.selected||this.activated)&&!this.disabled,"ft-ripple--pressed":(this.pressed||this.rippling)&&!this.disabled,"ft-ripple--hovered":this.hovered&&!this.disabled,"ft-ripple--focused":this.focused&&!this.disabled};return Nu.html`
419
429
  <style>
420
430
  .ft-ripple .ft-ripple--effect {
421
431
  left: ${this.originX}px;
@@ -426,9 +436,9 @@
426
436
  <div class="ft-ripple--background"></div>
427
437
  <div class="ft-ripple--effect"></div>
428
438
  </div>
429
- `}contentAvailableCallback(e){super.contentAvailableCallback(e),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}update(e){var i,r;super.update(e),e.has("disabled")&&(this.disabled?(this.endRipple(),(i=this.target)===null||i===void 0||i.removeAttribute("data-is-ft-ripple-target")):(r=this.target)===null||r===void 0||r.setAttribute("data-is-ft-ripple-target","true"))}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}connectedCallback(){super.connectedCallback(),this.setupDebouncer.run(()=>this.defaultSetup())}defaultSetup(){var e,i;let r=(e=this.shadowRoot)===null||e===void 0?void 0:e.host.parentElement;r&&this.setupFor((i=this.target)!==null&&i!==void 0?i:r)}forceFocusUpdate(){var e;!((e=this.target)===null||e===void 0)&&e.matches(":focus-within")?this.startFocus():this.endFocus()}setupFor(e){if(this.setupDebouncer.cancel(),this.target===e)return;this.onDisconnect&&this.onDisconnect(),this.target=e,e.setAttribute("data-is-ft-ripple-target","true");let i=(...a)=>l=>{a.forEach(d=>window.addEventListener(d,this.endPress,{once:!0})),this.startPress(l)},r=i("mouseup","contextmenu"),n=i("touchend","touchcancel"),o=a=>{["Enter"," "].includes(a.key)&&i("keyup")(a)},s={passive:!0};e.addEventListener("mouseover",this.startHover,s),e.addEventListener("mousemove",this.moveRipple,s),e.addEventListener("mouseleave",this.endHover,s),e.addEventListener("mousedown",r,s),e.addEventListener("touchstart",n,s),e.addEventListener("touchmove",this.moveRipple,s),e.addEventListener("keydown",o,s),e.addEventListener("focus",this.startFocus,s),e.addEventListener("blur",this.endFocus,s),e.addEventListener("focusin",this.startFocus,s),e.addEventListener("focusout",this.endFocus,s),this.onDisconnect=()=>{e.removeAttribute("data-is-ft-ripple-target"),e.removeEventListener("mouseover",this.startHover,s),e.removeEventListener("mousemove",this.moveRipple,s),e.removeEventListener("mouseleave",this.endHover,s),e.removeEventListener("mousedown",r,s),e.removeEventListener("touchstart",n,s),e.removeEventListener("touchmove",this.moveRipple,s),e.removeEventListener("keydown",o,s),e.removeEventListener("focus",this.startFocus,s),e.removeEventListener("blur",this.endFocus,s),e.removeEventListener("focusin",this.startFocus,s),e.removeEventListener("focusout",this.endFocus,s),this.onDisconnect=void 0,this.target=void 0}}getCoordinates(e){let i=e,r=e,n,o;return i.x!=null?{x:n,y:o}=i:r.touches!=null&&(n=r.touches[0].clientX,o=r.touches[0].clientY),{x:n,y:o}}isFocusVisible(e){return e instanceof HTMLElement?e.matches(":focus-visible"):!0}isIgnored(e){if(this.disabled)return!0;if(e!=null)for(let i of e.composedPath()){if(i===this.target)break;if("hasAttribute"in i&&i.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.endRipple()}};M.elementDefinitions={};M.styles=Pu;Ge([(0,Oe.property)({type:Boolean})],M.prototype,"primary",void 0);Ge([(0,Oe.property)({type:Boolean})],M.prototype,"secondary",void 0);Ge([(0,Oe.property)({type:Boolean})],M.prototype,"unbounded",void 0);Ge([(0,Oe.property)({type:Boolean})],M.prototype,"activated",void 0);Ge([(0,Oe.property)({type:Boolean})],M.prototype,"selected",void 0);Ge([(0,Oe.property)({type:Boolean})],M.prototype,"disabled",void 0);Ge([(0,Oe.state)()],M.prototype,"hovered",void 0);Ge([(0,Oe.state)()],M.prototype,"focused",void 0);Ge([(0,Oe.state)()],M.prototype,"pressed",void 0);Ge([(0,Oe.state)()],M.prototype,"rippling",void 0);Ge([(0,Oe.state)()],M.prototype,"originX",void 0);Ge([(0,Oe.state)()],M.prototype,"originY",void 0);Ge([(0,Oe.query)(".ft-ripple")],M.prototype,"ripple",void 0);Ge([(0,Oe.query)(".ft-ripple--effect")],M.prototype,"rippleEffect",void 0);var Fu=c(h());var Uu={"ft-ripple":M};(0,Fu.customElements)(Uu);var es=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Tm={"attachment-viewed":{label:"Opening attachment",defaultEventName:"attachment-open",defaultComponentId:"ft-reader-attachments"},"attachment-downloaded":{label:"Downloading attachment",defaultEventName:"attachment-download",defaultComponentId:"ft-reader-attachments"}},Tt=class extends(0,Or.withAnalytics)(Or.FtLitElementRedux,Tm){constructor(){super(...arguments),this.hideFileFormatIcon=!1,this.hideFilename=!1,this.hideDownloadIcon=!1}render(){if(this.canRender()){let e={"hide-file-format-icon":this.hideFileFormatIcon,"hide-filename":this.hideFilename,"hide-download-icon":this.hideDownloadIcon};return Hi.html`
439
+ `}contentAvailableCallback(e){super.contentAvailableCallback(e),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}update(e){var i,r;super.update(e),e.has("disabled")&&(this.disabled?(this.endRipple(),(i=this.target)===null||i===void 0||i.removeAttribute("data-is-ft-ripple-target")):(r=this.target)===null||r===void 0||r.setAttribute("data-is-ft-ripple-target","true"))}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}connectedCallback(){super.connectedCallback(),this.setupDebouncer.run(()=>this.defaultSetup())}defaultSetup(){var e,i;let r=(e=this.shadowRoot)===null||e===void 0?void 0:e.host.parentElement;r&&this.setupFor((i=this.target)!==null&&i!==void 0?i:r)}forceFocusUpdate(){var e;!((e=this.target)===null||e===void 0)&&e.matches(":focus-within")?this.startFocus():this.endFocus()}setupFor(e){if(this.setupDebouncer.cancel(),this.target===e)return;this.onDisconnect&&this.onDisconnect(),this.target=e,e.setAttribute("data-is-ft-ripple-target","true");let i=(...a)=>l=>{a.forEach(d=>window.addEventListener(d,this.endPress,{once:!0})),this.startPress(l)},r=i("mouseup","contextmenu"),n=i("touchend","touchcancel"),o=a=>{["Enter"," "].includes(a.key)&&i("keyup")(a)},s={passive:!0};e.addEventListener("mouseover",this.startHover,s),e.addEventListener("mousemove",this.moveRipple,s),e.addEventListener("mouseleave",this.endHover,s),e.addEventListener("mousedown",r,s),e.addEventListener("touchstart",n,s),e.addEventListener("touchmove",this.moveRipple,s),e.addEventListener("keydown",o,s),e.addEventListener("focus",this.startFocus,s),e.addEventListener("blur",this.endFocus,s),e.addEventListener("focusin",this.startFocus,s),e.addEventListener("focusout",this.endFocus,s),this.onDisconnect=()=>{e.removeAttribute("data-is-ft-ripple-target"),e.removeEventListener("mouseover",this.startHover,s),e.removeEventListener("mousemove",this.moveRipple,s),e.removeEventListener("mouseleave",this.endHover,s),e.removeEventListener("mousedown",r,s),e.removeEventListener("touchstart",n,s),e.removeEventListener("touchmove",this.moveRipple,s),e.removeEventListener("keydown",o,s),e.removeEventListener("focus",this.startFocus,s),e.removeEventListener("blur",this.endFocus,s),e.removeEventListener("focusin",this.startFocus,s),e.removeEventListener("focusout",this.endFocus,s),this.onDisconnect=void 0,this.target=void 0}}getCoordinates(e){let i=e,r=e,n,o;return i.x!=null?{x:n,y:o}=i:r.touches!=null&&(n=r.touches[0].clientX,o=r.touches[0].clientY),{x:n,y:o}}isFocusVisible(e){return e instanceof HTMLElement?e.matches(":focus-visible"):!0}isIgnored(e){if(this.disabled)return!0;if(e!=null)for(let i of e.composedPath()){if(i===this.target)break;if("hasAttribute"in i&&i.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.endRipple()}};M.elementDefinitions={};M.styles=Pu;qe([(0,Oe.property)({type:Boolean})],M.prototype,"primary",void 0);qe([(0,Oe.property)({type:Boolean})],M.prototype,"secondary",void 0);qe([(0,Oe.property)({type:Boolean})],M.prototype,"unbounded",void 0);qe([(0,Oe.property)({type:Boolean})],M.prototype,"activated",void 0);qe([(0,Oe.property)({type:Boolean})],M.prototype,"selected",void 0);qe([(0,Oe.property)({type:Boolean})],M.prototype,"disabled",void 0);qe([(0,Oe.state)()],M.prototype,"hovered",void 0);qe([(0,Oe.state)()],M.prototype,"focused",void 0);qe([(0,Oe.state)()],M.prototype,"pressed",void 0);qe([(0,Oe.state)()],M.prototype,"rippling",void 0);qe([(0,Oe.state)()],M.prototype,"originX",void 0);qe([(0,Oe.state)()],M.prototype,"originY",void 0);qe([(0,Oe.query)(".ft-ripple")],M.prototype,"ripple",void 0);qe([(0,Oe.query)(".ft-ripple--effect")],M.prototype,"rippleEffect",void 0);var Fu=c(h());var Uu={"ft-ripple":M};(0,Fu.customElements)(Uu);var es=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Tm={"attachment-viewed":{label:"Opening attachment",defaultEventName:"attachment-open",defaultComponentId:"ft-reader-attachments"},"attachment-downloaded":{label:"Downloading attachment",defaultEventName:"attachment-download",defaultComponentId:"ft-reader-attachments"}},Tt=class extends(0,Or.withAnalytics)(Or.FtLitElementRedux,Tm){constructor(){super(...arguments),this.hideFileFormatIcon=!1,this.hideFilename=!1,this.hideDownloadIcon=!1}render(){if(this.canRender()){let e={"hide-file-format-icon":this.hideFileFormatIcon,"hide-filename":this.hideFilename,"hide-download-icon":this.hideDownloadIcon};return Ki.html`
430
440
  <div part="container" class="${(0,Bu.classMap)(e)}">
431
- ${(0,Vu.repeat)(this.attachments,i=>i.id,i=>{var r;let n=Mo(i.mimeType,(0,Or.last)(i.file.split(".")));return Hi.html`
441
+ ${(0,Vu.repeat)(this.attachments,i=>i.id,i=>{var r;let n=Mo(i.mimeType,(0,Or.last)(i.file.split(".")));return Ki.html`
432
442
  <div part="attachment">
433
443
  <a part="viewer-link" href="${this.getAttachmentViewerLink(i)}"
434
444
  aria-label="${this.getAttachmentAriaLabel(i)}"
@@ -437,10 +447,10 @@
437
447
  <ft-icon part="file-format-icon"
438
448
  variant="file-format"
439
449
  value="${n}"
440
- style="color: ${(r=Pa[n])!==null&&r!==void 0?r:Pa[m.UNKNOWN]}"></ft-icon>
450
+ style="color: ${(r=Pa[n])!==null&&r!==void 0?r:Pa[g.UNKNOWN]}"></ft-icon>
441
451
  <ft-typography part="name" variant="${H.body2}">${i.name}</ft-typography>
442
452
  </a>
443
- ${i.externalLink?Hi.nothing:Hi.html`
453
+ ${i.externalLink?Ki.nothing:Ki.html`
444
454
  <a part="download-link"
445
455
  target="_blank"
446
456
  href="${this.getAttachmentDownloadLink(i)}"
@@ -453,7 +463,7 @@
453
463
  </div>
454
464
  `})}
455
465
  </div>
456
- `}return Hi.nothing}getAttachmentAriaLabel(e){var i;let r=e.name,n=e.file;if(r===n)return n;let o=(i=n.includes(".")?n.split(".").pop():e.mimeType)!==null&&i!==void 0?i:"";return r+" "+o}canRender(){var e,i;return((i=(e=this.attachments)===null||e===void 0?void 0:e.length)!==null&&i!==void 0?i:0)>0}getAttachmentDownloadLink(e){throw new Error("Not implemented")}getAttachmentDownloadLinkAriaLabel(e){throw new Error("Not implemented")}getAttachmentViewerLink(e){throw new Error("Not implemented")}};Tt.elementDefinitions={"ft-icon":z,"ft-ripple":M,"ft-typography":F};es([(0,Rr.property)({type:Boolean})],Tt.prototype,"hideFileFormatIcon",void 0);es([(0,Rr.property)({type:Boolean})],Tt.prototype,"hideFilename",void 0);es([(0,Rr.property)({type:Boolean})],Tt.prototype,"hideDownloadIcon",void 0);es([(0,Rr.state)()],Tt.prototype,"attachments",void 0);var Hu=c(x()),gn=c(h());function ts(t){return Hu.css`
466
+ `}return Ki.nothing}getAttachmentAriaLabel(e){var i;let r=e.name,n=e.file;if(r===n)return n;let o=(i=n.includes(".")?n.split(".").pop():e.mimeType)!==null&&i!==void 0?i:"";return r+" "+o}canRender(){var e,i;return((i=(e=this.attachments)===null||e===void 0?void 0:e.length)!==null&&i!==void 0?i:0)>0}getAttachmentDownloadLink(e){throw new Error("Not implemented")}getAttachmentDownloadLinkAriaLabel(e){throw new Error("Not implemented")}getAttachmentViewerLink(e){throw new Error("Not implemented")}};Tt.elementDefinitions={"ft-icon":z,"ft-ripple":M,"ft-typography":F};es([(0,Rr.property)({type:Boolean})],Tt.prototype,"hideFileFormatIcon",void 0);es([(0,Rr.property)({type:Boolean})],Tt.prototype,"hideFilename",void 0);es([(0,Rr.property)({type:Boolean})],Tt.prototype,"hideDownloadIcon",void 0);es([(0,Rr.state)()],Tt.prototype,"attachments",void 0);var Hu=c(S()),gn=c(h());function ts(t){return Hu.css`
457
467
  [part="container"] {
458
468
  display: flex;
459
469
  flex-direction: column;
@@ -520,7 +530,7 @@
520
530
  .hide-download-icon [part="download-link"] {
521
531
  display: none;
522
532
  }
523
- `}var zu=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},zi=class extends Ba(ht(Tt)){constructor(){super(),this.addI18nContext(Ha,Tu)}update(e){super.update(e),e.has("map")&&this.updateAttachments()}updateAttachments(){var e;this.map?(e=this.service)===null||e===void 0||e.getAttachments().then(i=>this.attachments=i):this.attachments=void 0}getAttachmentDownloadLink(e){var i,r;return(r=(i=this.service)===null||i===void 0?void 0:i.getAttachmentDownloadLink(e.id))!==null&&r!==void 0?r:""}getAttachmentDownloadLinkAriaLabel(e){return Ha.messages.download(this.getAttachmentAriaLabel(e))}getAttachmentViewerLink(e){var i,r;return e.externalLink?e.viewerUrl:(i=this.service)===null||i===void 0?void 0:i.makeAbsolute((r=e.viewerUrl)!==null&&r!==void 0?r:"")}};zi.styles=ts(Eu);zu([(0,is.redux)({store:"reader"})],zi.prototype,"map",void 0);zu([(0,is.reduxEventListener)({eventName:Jo.mapAttachmentsUpdate})],zi.prototype,"updateAttachments",null);var Wu=c(h());var ju={"ft-reader-attachments":zi};(0,Wu.customElements)(ju);var be=c(h()),Ku={itemsGap:be.FtCssVariableFactory.create("--ft-ud-viewer-attachments-items-gap","","SIZE","8px"),itemPadding:be.FtCssVariableFactory.create("--ft-ud-viewer-attachments-item-padding","","SIZE","8px"),itemBorderWidth:be.FtCssVariableFactory.create("--ft-ud-viewer-attachments-item-border-width","","SIZE","1px"),itemBorderColor:be.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-border-color","",be.designSystemVariables.colorOutline),itemBorderRadius:be.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-border-radius","",be.designSystemVariables.borderRadiusS),itemBackgroundColor:be.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-background-color","",be.designSystemVariables.colorSurface),itemTextColor:be.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-text-color","",be.designSystemVariables.colorOnSurfaceMedium),itemHoverBackgroundColor:be.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-hover-background-color","",be.designSystemVariables.colorPrimary),itemHoverTextColor:be.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-hover-text-color","",be.designSystemVariables.colorOnSurfaceHigh),fileFormatIconSize:be.FtCssVariableFactory.create("--ft-ud-viewer-attachments-file-format-icon-size","","SIZE","30px"),downloadIconSize:be.FtCssVariableFactory.create("--ft-ud-viewer-attachments-down-icon-size","","SIZE","20px")};var kr=ft.build("designedUdViewer"),Gu={download:"Download {0}",itemWithNoValueForSwitchToRelatives:"No value"};var qu=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ji=class extends Ke(ht(Tt)){constructor(){super(),this.addI18nContext(kr,Gu)}update(e){super.update(e),e.has("document")&&this.updateAttachments()}updateAttachments(){var e;this.document?(e=this.service)===null||e===void 0||e.getAttachments(this.document.id).then(i=>this.attachments=i):this.attachments=void 0}canRender(){return!!this.document&&super.canRender()}getAttachmentDownloadLink(e){var i,r;return(r=(i=this.service)===null||i===void 0?void 0:i.getAttachmentDownloadLink(this.document.id,e.id))!==null&&r!==void 0?r:""}getAttachmentDownloadLinkAriaLabel(e){return kr.messages.download(this.getAttachmentAriaLabel(e))}getAttachmentViewerLink(e){var i,r;return e.externalLink?e.viewerUrl:(i=this.service)===null||i===void 0?void 0:i.makeAbsolute((r=e.viewerUrl)!==null&&r!==void 0?r:"")}};ji.styles=ts(Ku);qu([(0,rs.redux)({store:"viewer"})],ji.prototype,"document",void 0);qu([(0,rs.reduxEventListener)({eventName:fi.udAttachmentsUpdate})],ji.prototype,"updateAttachments",null);var Cf=c(x()),Mt=c(U()),Ze=c(h());var ns=class extends CustomEvent{constructor(e){super("ft-ud-viewer-feedback",{composed:!0,bubbles:!0,detail:e})}},os=class extends CustomEvent{constructor(){super("ft-viewer-mailer-ud-feedback",{composed:!0,bubbles:!0})}};var Ht=c(h());var Cp=c(x()),yt=c(U()),gt=c(h());var Yu=c(x()),gi=c(h()),yn={distance:gi.FtCssVariableFactory.create("--ft-tooltip-distance","","SIZE","4px"),color:gi.FtCssVariableFactory.create("--ft-tooltip-color","","COLOR","#FFFFFF"),backgroundColor:gi.FtCssVariableFactory.create("--ft-tooltip-background-color","","COLOR","#666666"),borderRadiusS:gi.FtCssVariableFactory.extend("--ft-tooltip-border-radius","",gi.designSystemVariables.borderRadiusS),maxWidth:gi.FtCssVariableFactory.create("--ft-tooltip-max-width","","SIZE","150px")},Zu=Yu.css`
533
+ `}var zu=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Gi=class extends Ba(ht(Tt)){constructor(){super(),this.addI18nContext(Ha,Tu)}update(e){super.update(e),e.has("map")&&this.updateAttachments()}updateAttachments(){var e;this.map?(e=this.service)===null||e===void 0||e.getAttachments().then(i=>this.attachments=i):this.attachments=void 0}getAttachmentDownloadLink(e){var i,r;return(r=(i=this.service)===null||i===void 0?void 0:i.getAttachmentDownloadLink(e.id))!==null&&r!==void 0?r:""}getAttachmentDownloadLinkAriaLabel(e){return Ha.messages.download(this.getAttachmentAriaLabel(e))}getAttachmentViewerLink(e){var i,r;return e.externalLink?e.viewerUrl:(i=this.service)===null||i===void 0?void 0:i.makeAbsolute((r=e.viewerUrl)!==null&&r!==void 0?r:"")}};Gi.styles=ts(Eu);zu([(0,is.redux)({store:"reader"})],Gi.prototype,"map",void 0);zu([(0,is.reduxEventListener)({eventName:Jo.mapAttachmentsUpdate})],Gi.prototype,"updateAttachments",null);var Wu=c(h());var ju={"ft-reader-attachments":Gi};(0,Wu.customElements)(ju);var xe=c(h()),Ku={itemsGap:xe.FtCssVariableFactory.create("--ft-ud-viewer-attachments-items-gap","","SIZE","8px"),itemPadding:xe.FtCssVariableFactory.create("--ft-ud-viewer-attachments-item-padding","","SIZE","8px"),itemBorderWidth:xe.FtCssVariableFactory.create("--ft-ud-viewer-attachments-item-border-width","","SIZE","1px"),itemBorderColor:xe.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-border-color","",xe.designSystemVariables.colorOutline),itemBorderRadius:xe.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-border-radius","",xe.designSystemVariables.borderRadiusS),itemBackgroundColor:xe.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-background-color","",xe.designSystemVariables.colorSurface),itemTextColor:xe.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-text-color","",xe.designSystemVariables.colorOnSurfaceMedium),itemHoverBackgroundColor:xe.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-hover-background-color","",xe.designSystemVariables.colorPrimary),itemHoverTextColor:xe.FtCssVariableFactory.extend("--ft-ud-viewer-attachments-item-hover-text-color","",xe.designSystemVariables.colorOnSurfaceHigh),fileFormatIconSize:xe.FtCssVariableFactory.create("--ft-ud-viewer-attachments-file-format-icon-size","","SIZE","30px"),downloadIconSize:xe.FtCssVariableFactory.create("--ft-ud-viewer-attachments-down-icon-size","","SIZE","20px")};var kr=ft.build("designedUdViewer"),Gu={download:"Download {0}",itemWithNoValueForSwitchToRelatives:"No value"};var qu=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},qi=class extends Ge(ht(Tt)){constructor(){super(),this.addI18nContext(kr,Gu)}update(e){super.update(e),e.has("document")&&this.updateAttachments()}updateAttachments(){var e;this.document?(e=this.service)===null||e===void 0||e.getAttachments(this.document.id).then(i=>this.attachments=i):this.attachments=void 0}canRender(){return!!this.document&&super.canRender()}getAttachmentDownloadLink(e){var i,r;return(r=(i=this.service)===null||i===void 0?void 0:i.getAttachmentDownloadLink(this.document.id,e.id))!==null&&r!==void 0?r:""}getAttachmentDownloadLinkAriaLabel(e){return kr.messages.download(this.getAttachmentAriaLabel(e))}getAttachmentViewerLink(e){var i,r;return e.externalLink?e.viewerUrl:(i=this.service)===null||i===void 0?void 0:i.makeAbsolute((r=e.viewerUrl)!==null&&r!==void 0?r:"")}};qi.styles=ts(Ku);qu([(0,rs.redux)({store:"viewer"})],qi.prototype,"document",void 0);qu([(0,rs.reduxEventListener)({eventName:fi.udAttachmentsUpdate})],qi.prototype,"updateAttachments",null);var Cf=c(S()),Mt=c(U()),Xe=c(h());var ns=class extends CustomEvent{constructor(e){super("ft-ud-viewer-feedback",{composed:!0,bubbles:!0,detail:e})}},os=class extends CustomEvent{constructor(){super("ft-viewer-mailer-ud-feedback",{composed:!0,bubbles:!0})}};var Ht=c(h());var Cp=c(S()),yt=c(U()),gt=c(h());var Yu=c(S()),gi=c(h()),yn={distance:gi.FtCssVariableFactory.create("--ft-tooltip-distance","","SIZE","4px"),color:gi.FtCssVariableFactory.create("--ft-tooltip-color","","COLOR","#FFFFFF"),backgroundColor:gi.FtCssVariableFactory.create("--ft-tooltip-background-color","","COLOR","#666666"),borderRadiusS:gi.FtCssVariableFactory.extend("--ft-tooltip-border-radius","",gi.designSystemVariables.borderRadiusS),maxWidth:gi.FtCssVariableFactory.create("--ft-tooltip-max-width","","SIZE","150px")},Zu=Yu.css`
524
534
  .ft-tooltip--container {
525
535
  display: block;
526
536
  }
@@ -551,7 +561,7 @@
551
561
  position: relative;
552
562
  word-break: break-word;
553
563
  }
554
- `;var Ju=["top","right","bottom","left"],Xu=["start","end"],ja=Ju.reduce((t,e)=>t.concat(e,e+"-"+Xu[0],e+"-"+Xu[1]),[]),vn=Math.min,yi=Math.max,bn=Math.round;var Vt=t=>({x:t,y:t}),Rm={left:"right",right:"left",bottom:"top",top:"bottom"};function Qu(t,e,i){return yi(t,vn(e,i))}function ss(t,e){return typeof t=="function"?t(e):t}function xn(t){return t.split("-")[0]}function vi(t){return t.split("-")[1]}function Wa(t){return t==="x"?"y":"x"}function Ka(t){return t==="y"?"height":"width"}function as(t){let e=t[0];return e==="t"||e==="b"?"y":"x"}function Ga(t){return Wa(as(t))}function ep(t,e,i){i===void 0&&(i=!1);let r=vi(t),n=Ga(t),o=Ka(n),s=n==="x"?r===(i?"end":"start")?"right":"left":r==="start"?"bottom":"top";return e.reference[o]>e.floating[o]&&(s=za(s)),[s,za(s)]}function tp(t){return t.includes("start")?t.replace("start","end"):t.replace("end","start")}function za(t){let e=xn(t);return Rm[e]+t.slice(e.length)}function Om(t){var e,i,r,n;return{top:(e=t.top)!=null?e:0,right:(i=t.right)!=null?i:0,bottom:(r=t.bottom)!=null?r:0,left:(n=t.left)!=null?n:0}}function ip(t){return typeof t!="number"?Om(t):{top:t,right:t,bottom:t,left:t}}function Wi(t){let{x:e,y:i,width:r,height:n}=t;return{width:r,height:n,top:i,left:e,right:e+r,bottom:i+n,x:e,y:i}}function rp(t,e,i){let{reference:r,floating:n}=t,o=as(e),s=Ga(e),a=Ka(s),l=xn(e),d=o==="y",u=r.x+r.width/2-n.width/2,p=r.y+r.height/2-n.height/2,f=r[a]/2-n[a]/2,y;switch(l){case"top":y={x:u,y:r.y-n.height};break;case"bottom":y={x:u,y:r.y+r.height};break;case"right":y={x:r.x+r.width,y:p};break;case"left":y={x:r.x-n.width,y:p};break;default:y={x:r.x,y:r.y}}let S=vi(e);return S&&(y[s]+=f*(S==="end"?1:-1)*(i&&d?-1:1)),y}async function np(t,e){var i;e===void 0&&(e={});let{x:r,y:n,platform:o,rects:s,elements:a,strategy:l}=t,{boundary:d="clippingAncestors",rootBoundary:u="viewport",elementContext:p="floating",altBoundary:f=!1,padding:y=0}=ss(e,t),S=ip(y),b=a[f?p==="floating"?"reference":"floating":p],R=Wi(await o.getClippingRect({element:(i=await(o.isElement==null?void 0:o.isElement(b)))==null||i?b:b.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(a.floating)),boundary:d,rootBoundary:u,strategy:l})),V=p==="floating"?{x:r,y:n,width:s.floating.width,height:s.floating.height}:s.reference,w=await(o.getOffsetParent==null?void 0:o.getOffsetParent(a.floating)),k=await(o.isElement==null?void 0:o.isElement(w))&&await(o.getScale==null?void 0:o.getScale(w))||{x:1,y:1},N=Wi(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:V,offsetParent:w,strategy:l}):V);return{top:(R.top-N.top+S.top)/k.y,bottom:(N.bottom-R.bottom+S.bottom)/k.y,left:(R.left-N.left+S.left)/k.x,right:(N.right-R.right+S.right)/k.x}}var km=50,op=async(t,e,i)=>{let{placement:r="bottom",strategy:n="absolute",middleware:o=[],platform:s}=i,a=s.detectOverflow?s:{...s,detectOverflow:np},l=await(s.isRTL==null?void 0:s.isRTL(e)),d=await s.getElementRects({reference:t,floating:e,strategy:n}),{x:u,y:p}=rp(d,r,l),f=r,y=0,S={};for(let T=0;T<o.length;T++){let b=o[T];if(!b)continue;let{name:R,fn:V}=b,{x:w,y:k,data:N,reset:ae}=await V({x:u,y:p,initialPlacement:r,placement:f,strategy:n,middlewareData:S,rects:d,platform:a,elements:{reference:t,floating:e}});u=w??u,p=k??p,S[R]={...S[R],...N},ae&&y<km&&(y++,typeof ae=="object"&&(ae.placement&&(f=ae.placement),ae.rects&&(d=ae.rects===!0?await s.getElementRects({reference:t,floating:e,strategy:n}):ae.rects),{x:u,y:p}=rp(d,f,l)),T=-1)}return{x:u,y:p,placement:f,strategy:n,middlewareData:S}};function Lm(t,e,i){return(t?[...i.filter(n=>vi(n)===t),...i.filter(n=>vi(n)!==t)]:i.filter(n=>xn(n)===n)).filter(n=>t?vi(n)===t||(e?tp(n)!==n:!1):!0)}var sp=function(t){return t===void 0&&(t={}),{name:"autoPlacement",options:t,async fn(e){var i,r,n;let{rects:o,middlewareData:s,placement:a,platform:l,elements:d}=e,{crossAxis:u=!1,alignment:p,allowedPlacements:f=ja,autoAlignment:y=!0,...S}=ss(t,e),T=p!==void 0||f===ja?Lm(p||null,y,f):f,b=((i=s.autoPlacement)==null?void 0:i.index)||0,R=T[b];if(R==null)return{};if(a!==R)return{reset:{placement:T[0]}};let V=await l.detectOverflow(e,S),w=ep(R,o,await(l.isRTL==null?void 0:l.isRTL(d.floating))),k=[V[xn(R)],V[w[0]],V[w[1]]],N=[...((r=s.autoPlacement)==null?void 0:r.overflows)||[],{placement:R,overflows:k}],ae=T[b+1];if(ae)return{data:{index:b+1,overflows:N},reset:{placement:ae}};let q=N.map(at=>{let Ei=vi(at.placement);return[at.placement,Ei&&u?at.overflows.slice(0,2).reduce((eh,th)=>eh+th,0):at.overflows[0],at.overflows]}).sort((at,Ei)=>at[1]-Ei[1]),Hr=((n=q.filter(at=>at[2].slice(0,vi(at[0])?2:3).every(Ei=>Ei<=0))[0])==null?void 0:n[0])||q[0][0];return Hr!==a?{data:{index:b+1,overflows:N},reset:{placement:Hr}}:{}}}};var ap=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){let{x:i,y:r,placement:n,platform:o}=e,{mainAxis:s=!0,crossAxis:a=!1,limiter:l={fn:V=>{let{x:w,y:k}=V;return{x:w,y:k}}},...d}=ss(t,e),u={x:i,y:r},p=await o.detectOverflow(e,d),f=as(n),y=Wa(f),S=u[y],T=u[f],b=(V,w)=>Qu(w+p[V==="y"?"top":"left"],w,w-p[V==="y"?"bottom":"right"]);s&&(S=b(y,S)),a&&(T=b(f,T));let R=l.fn({...e,[y]:S,[f]:T});return{...R,data:{x:R.x-i,y:R.y-r,enabled:{[y]:s,[f]:a}}}}}};function cs(){return typeof window<"u"}function Gi(t){return cp(t)?(t.nodeName||"").toLowerCase():"#document"}function qe(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function ti(t){var e;return(e=(cp(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function cp(t){return cs()?t instanceof Node||t instanceof qe(t).Node:!1}function Rt(t){return cs()?t instanceof Element||t instanceof qe(t).Element:!1}function ii(t){return cs()?t instanceof HTMLElement||t instanceof qe(t).HTMLElement:!1}function lp(t){return!cs()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof qe(t).ShadowRoot}function Sn(t){let{overflow:e,overflowX:i,overflowY:r,display:n}=Ot(t);return/auto|scroll|overlay|hidden|clip/.test(e+r+i)&&n!=="inline"&&n!=="contents"}function dp(t){return/^(table|td|th)$/.test(Gi(t))}function wn(t){try{if(t.matches(":popover-open"))return!0}catch{}try{return t.matches(":modal")}catch{return!1}}var Dm=/transform|translate|scale|rotate|perspective|filter/,Im=/paint|layout|strict|content/,Ki=t=>!!t&&t!=="none",qa;function Lr(t){let e=Rt(t)?Ot(t):t;return Ki(e.transform)||Ki(e.translate)||Ki(e.scale)||Ki(e.rotate)||Ki(e.perspective)||!ds()&&(Ki(e.backdropFilter)||Ki(e.filter))||Dm.test(e.willChange||"")||Im.test(e.contain||"")}function up(t){let e=bi(t);for(;ii(e)&&!Dr(e);){if(Lr(e))return e;if(wn(e))return null;e=bi(e)}return null}function ds(){return qa==null&&(qa=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),qa}function Dr(t){return/^(html|body|#document)$/.test(Gi(t))}function Ot(t){return qe(t).getComputedStyle(t)}function En(t){return Rt(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function bi(t){if(Gi(t)==="html")return t;let e=t.assignedSlot||t.parentNode||lp(t)&&t.host||ti(t);return lp(e)?e.host:e}function pp(t){let e=bi(t);return Dr(e)?(t.ownerDocument||t).body:ii(e)&&Sn(e)?e:pp(e)}function ls(t,e,i){var r;e===void 0&&(e=[]),i===void 0&&(i=!0);let n=pp(t),o=n===((r=t.ownerDocument)==null?void 0:r.body),s=qe(n);if(o){let a=us(s);return e.concat(s,s.visualViewport||[],Sn(n)?n:[],a&&i?ls(a):[])}else return e.concat(n,ls(n,[],i))}function us(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function mp(t){let e=Ot(t),i=parseFloat(e.width)||0,r=parseFloat(e.height)||0,n=ii(t),o=n?t.offsetWidth:i,s=n?t.offsetHeight:r,a=bn(i)!==o||bn(r)!==s;return a&&(i=o,r=s),{width:i,height:r,$:a}}function gp(t){return Rt(t)?t:t.contextElement}function Ir(t){let e=gp(t);if(!ii(e))return Vt(1);let i=e.getBoundingClientRect(),{width:r,height:n,$:o}=mp(e),s=(o?bn(i.width):i.width)/r,a=(o?bn(i.height):i.height)/n;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var Mm=Vt(0);function yp(t){let e=qe(t);return!ds()||!e.visualViewport?Mm:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function Pm(t,e,i){return e===void 0&&(e=!1),!!i&&e&&i===qe(t)}function _n(t,e,i,r){e===void 0&&(e=!1),i===void 0&&(i=!1);let n=t.getBoundingClientRect(),o=gp(t),s=Vt(1);e&&(r?Rt(r)&&(s=Ir(r)):s=Ir(t));let a=Pm(o,i,r)?yp(o):Vt(0),l=(n.left+a.x)/s.x,d=(n.top+a.y)/s.y,u=n.width/s.x,p=n.height/s.y;if(o&&r){let f=qe(o),y=Rt(r)?qe(r):r,S=f,T=us(S);for(;T&&y!==S;){let b=Ir(T),R=T.getBoundingClientRect(),V=Ot(T),w=R.left+(T.clientLeft+parseFloat(V.paddingLeft))*b.x,k=R.top+(T.clientTop+parseFloat(V.paddingTop))*b.y;l*=b.x,d*=b.y,u*=b.x,p*=b.y,l+=w,d+=k,S=qe(T),T=us(S)}}return Wi({width:u,height:p,x:l,y:d})}function ps(t,e){let i=En(t).scrollLeft;return e?e.left+i:_n(ti(t)).left+i}function vp(t,e){let i=t.getBoundingClientRect(),r=i.left+e.scrollLeft-ps(t,i),n=i.top+e.scrollTop;return{x:r,y:n}}function Nm(t){let{elements:e,rect:i,offsetParent:r,strategy:n}=t,o=n==="fixed",s=ti(r),a=e?wn(e.floating):!1;if(r===s||a&&o)return i;let l={scrollLeft:0,scrollTop:0},d=Vt(1),u=Vt(0),p=ii(r);if((p||!o)&&((Gi(r)!=="body"||Sn(s))&&(l=En(r)),p)){let y=_n(r);d=Ir(r),u.x=y.x+r.clientLeft,u.y=y.y+r.clientTop}let f=s&&!p&&!o?vp(s,l):Vt(0);return{width:i.width*d.x,height:i.height*d.y,x:i.x*d.x-l.scrollLeft*d.x+u.x+f.x,y:i.y*d.y-l.scrollTop*d.y+u.y+f.y}}function $m(t){return t.getClientRects?Array.from(t.getClientRects()):[]}function Um(t){let e=En(t),i=t.ownerDocument.body,r=yi(t.scrollWidth,t.clientWidth,i.scrollWidth,i.clientWidth),n=yi(t.scrollHeight,t.clientHeight,i.scrollHeight,i.clientHeight),o=-e.scrollLeft+ps(t),s=-e.scrollTop;return Ot(i).direction==="rtl"&&(o+=yi(t.clientWidth,i.clientWidth)-r),{width:r,height:n,x:o,y:s}}var Fm=25;function Vm(t,e,i){i===void 0&&(i="viewport");let r=i==="layoutViewport",n=qe(t),o=ti(t),s=n.visualViewport,a=o.clientWidth,l=o.clientHeight,d=0,u=0;if(s){let f=!ds()||e==="fixed";r?f||(d=-s.offsetLeft,u=-s.offsetTop):(a=s.width,l=s.height,f&&(d=s.offsetLeft,u=s.offsetTop))}if(ps(o)<=0){let f=o.ownerDocument,y=f.body,S=getComputedStyle(y),T=f.compatMode==="CSS1Compat"&&parseFloat(S.marginLeft)+parseFloat(S.marginRight)||0,b=Math.abs(o.clientWidth-y.clientWidth-T),R=getComputedStyle(o).scrollbarGutter==="stable both-edges"?b/2:b;R<=Fm&&(a-=R)}return{width:a,height:l,x:d,y:u}}function Bm(t,e){let i=_n(t,!0,e==="fixed"),r=i.top+t.clientTop,n=i.left+t.clientLeft,o=Ir(t),s=t.clientWidth*o.x,a=t.clientHeight*o.y,l=n*o.x,d=r*o.y;return{width:s,height:a,x:l,y:d}}function fp(t,e,i){let r;if(e==="viewport"||e==="layoutViewport")r=Vm(t,i,e);else if(e==="document")r=Um(ti(t));else if(Rt(e))r=Bm(e,i);else{let n=yp(t);r={x:e.x-n.x,y:e.y-n.y,width:e.width,height:e.height}}return Wi(r)}function Hm(t,e){let i=e.get(t);if(i)return i;let r=ls(t,[],!1).filter(a=>Rt(a)&&Gi(a)!=="body"),n=null,o=Ot(t).position==="fixed",s=o?bi(t):t;for(;Rt(s)&&!Dr(s);){let a=Ot(s),l=Lr(s),d=n?n.position:o?"fixed":"";!l&&(d==="fixed"||d==="absolute"&&a.position==="static")?r=r.filter(p=>p!==s):n=a,s=bi(s)}return e.set(t,r),r}function zm(t){let{element:e,boundary:i,rootBoundary:r,strategy:n}=t,s=[...i==="clippingAncestors"?wn(e)?[]:Hm(e,this._c):[].concat(i),r],a=fp(e,s[0],n),l=a.top,d=a.right,u=a.bottom,p=a.left;for(let f=1;f<s.length;f++){let y=fp(e,s[f],n);l=yi(y.top,l),d=vn(y.right,d),u=vn(y.bottom,u),p=yi(y.left,p)}return{width:d-p,height:u-l,x:p,y:l}}function jm(t){let{width:e,height:i}=mp(t);return{width:e,height:i}}function Wm(t,e,i){let r=ii(e),n=ti(e),o=i==="fixed",s=_n(t,!0,o,e),a={scrollLeft:0,scrollTop:0},l=Vt(0);if((r||!o)&&((Gi(e)!=="body"||Sn(n))&&(a=En(e)),r)){let f=_n(e,!0,o,e);l.x=f.x+e.clientLeft,l.y=f.y+e.clientTop}!r&&n&&(l.x=ps(n));let d=n&&!r&&!o?vp(n,a):Vt(0),u=s.left+a.scrollLeft-l.x-d.x,p=s.top+a.scrollTop-l.y-d.y;return{x:u,y:p,width:s.width,height:s.height}}function Ya(t){return Ot(t).position==="static"}function hp(t,e){if(!ii(t)||Ot(t).position==="fixed")return null;if(e)return e(t);let i=t.offsetParent;return ti(t)===i&&(i=i.ownerDocument.body),i}function bp(t,e){let i=qe(t);if(wn(t))return i;if(!ii(t)){let n=bi(t);for(;n&&!Dr(n);){if(Rt(n)&&!Ya(n))return n;n=bi(n)}return i}let r=hp(t,e);for(;r&&dp(r)&&Ya(r);)r=hp(r,e);return r&&Dr(r)&&Ya(r)&&!Lr(r)?i:r||up(t)||i}var Km=async function(t){let e=this.getOffsetParent||bp,i=this.getDimensions,r=await i(t.floating);return{reference:Wm(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Gm(t){return Ot(t).direction==="rtl"}var fs={convertOffsetParentRelativeRectToViewportRelativeRect:Nm,getDocumentElement:ti,getClippingRect:zm,getOffsetParent:bp,getElementRects:Km,getClientRects:$m,getDimensions:jm,getScale:Ir,isElement:Rt,isRTL:Gm};var xp=sp,Sp=ap;var wp=(t,e,i)=>{let r=new Map,n=i??{},o={...fs,...n.platform,_c:r};return op(t,e,{...n,platform:o})};function Ep(t){return qm(t)}function Za(t){return t.assignedSlot?t.assignedSlot:t.parentNode instanceof ShadowRoot?t.parentNode.host:t.parentNode}function qm(t){for(let e=t;e;e=Za(e))if(e instanceof Element&&getComputedStyle(e).display==="none")return null;for(let e=Za(t);e;e=Za(e)){if(!(e instanceof Element))continue;let i=getComputedStyle(e);if(i.display!=="contents"&&(i.position!=="static"||Lr(i)||e.tagName==="BODY"))return e}return null}async function hs(t,e,i){let r;return typeof i=="object"?r=i:r={placement:i},wp(t,e,{strategy:r.strategy,platform:{...fs,getOffsetParent:n=>fs.getOffsetParent(n,Ep)},middleware:[Sp({crossAxis:!0}),xp({allowedPlacements:[r.placement]})]})}var _p=c(h());var Xa=class{fromAttribute(e){if(!e)return[];try{let i=JSON.parse(e);return Array.isArray(i)?i.map(r=>typeof r=="string"?_r.fromAttribute(r):r):[]}catch{return[]}}toAttribute(e){if(e!=null)return JSON.stringify(e)}},Ym=new Xa;var Ap=(t,e)=>(i,r)=>{var n;i.constructor.createProperty(r,{type:Object,hasChanged:_p.hasChanged,converter:_r,...e}),i[fn]=(n=i[fn])!==null&&n!==void 0?n:new Map,i[fn].set(r,t??{})};var kt=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},re=class extends Go{constructor(){super(...arguments),this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.ignoreMatchingElements=[],this.visible=!1,this.validPositions=new Set(["top","bottom","left","right"]),this.hideDebounce=new gt.Debouncer,this.revealDebouncer=new gt.Debouncer,this.onTouch=e=>{this.isIgnored(e)||(this.show(),setTimeout(()=>window.addEventListener("touchstart",i=>{i.composedPath().includes(this.container)||this.onOut(i)},{once:!0}),100))},this.onHover=e=>{this.isIgnored(e)?this.matchesIgnored(e)&&this.hide():this.show()},this.onFocusIn=e=>{!this.isIgnored(e)&&window.FluidTopicsA11yHints.isKeyboardNavigation&&window.FluidTopicsA11yHints.lastPressedKey==="Tab"&&this.show()},this.onOut=e=>{this.isIgnored(e)||(this.revealDebouncer.cancel(),this.hide())},this.onClick=e=>{this.isIgnored(e)||(this.revealDebouncer.cancel(),this.hide())}}get validPosition(){return this.validPositions.has(this.position)?this.position:"bottom"}render(){var e,i;return Cp.html`
564
+ `;var Ju=["top","right","bottom","left"],Xu=["start","end"],ja=Ju.reduce((t,e)=>t.concat(e,e+"-"+Xu[0],e+"-"+Xu[1]),[]),vn=Math.min,yi=Math.max,xn=Math.round;var Vt=t=>({x:t,y:t}),Rm={left:"right",right:"left",bottom:"top",top:"bottom"};function Qu(t,e,i){return yi(t,vn(e,i))}function ss(t,e){return typeof t=="function"?t(e):t}function bn(t){return t.split("-")[0]}function vi(t){return t.split("-")[1]}function Wa(t){return t==="x"?"y":"x"}function Ka(t){return t==="y"?"height":"width"}function as(t){let e=t[0];return e==="t"||e==="b"?"y":"x"}function Ga(t){return Wa(as(t))}function ep(t,e,i){i===void 0&&(i=!1);let r=vi(t),n=Ga(t),o=Ka(n),s=n==="x"?r===(i?"end":"start")?"right":"left":r==="start"?"bottom":"top";return e.reference[o]>e.floating[o]&&(s=za(s)),[s,za(s)]}function tp(t){return t.includes("start")?t.replace("start","end"):t.replace("end","start")}function za(t){let e=bn(t);return Rm[e]+t.slice(e.length)}function Om(t){var e,i,r,n;return{top:(e=t.top)!=null?e:0,right:(i=t.right)!=null?i:0,bottom:(r=t.bottom)!=null?r:0,left:(n=t.left)!=null?n:0}}function ip(t){return typeof t!="number"?Om(t):{top:t,right:t,bottom:t,left:t}}function Yi(t){let{x:e,y:i,width:r,height:n}=t;return{width:r,height:n,top:i,left:e,right:e+r,bottom:i+n,x:e,y:i}}function rp(t,e,i){let{reference:r,floating:n}=t,o=as(e),s=Ga(e),a=Ka(s),l=bn(e),d=o==="y",u=r.x+r.width/2-n.width/2,p=r.y+r.height/2-n.height/2,f=r[a]/2-n[a]/2,y;switch(l){case"top":y={x:u,y:r.y-n.height};break;case"bottom":y={x:u,y:r.y+r.height};break;case"right":y={x:r.x+r.width,y:p};break;case"left":y={x:r.x-n.width,y:p};break;default:y={x:r.x,y:r.y}}let w=vi(e);return w&&(y[s]+=f*(w==="end"?1:-1)*(i&&d?-1:1)),y}async function np(t,e){var i;e===void 0&&(e={});let{x:r,y:n,platform:o,rects:s,elements:a,strategy:l}=t,{boundary:d="clippingAncestors",rootBoundary:u="viewport",elementContext:p="floating",altBoundary:f=!1,padding:y=0}=ss(e,t),w=ip(y),b=a[f?p==="floating"?"reference":"floating":p],R=Yi(await o.getClippingRect({element:(i=await(o.isElement==null?void 0:o.isElement(b)))==null||i?b:b.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(a.floating)),boundary:d,rootBoundary:u,strategy:l})),V=p==="floating"?{x:r,y:n,width:s.floating.width,height:s.floating.height}:s.reference,E=await(o.getOffsetParent==null?void 0:o.getOffsetParent(a.floating)),k=await(o.isElement==null?void 0:o.isElement(E))&&await(o.getScale==null?void 0:o.getScale(E))||{x:1,y:1},N=Yi(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:V,offsetParent:E,strategy:l}):V);return{top:(R.top-N.top+w.top)/k.y,bottom:(N.bottom-R.bottom+w.bottom)/k.y,left:(R.left-N.left+w.left)/k.x,right:(N.right-R.right+w.right)/k.x}}var km=50,op=async(t,e,i)=>{let{placement:r="bottom",strategy:n="absolute",middleware:o=[],platform:s}=i,a=s.detectOverflow?s:{...s,detectOverflow:np},l=await(s.isRTL==null?void 0:s.isRTL(e)),d=await s.getElementRects({reference:t,floating:e,strategy:n}),{x:u,y:p}=rp(d,r,l),f=r,y=0,w={};for(let T=0;T<o.length;T++){let b=o[T];if(!b)continue;let{name:R,fn:V}=b,{x:E,y:k,data:N,reset:ae}=await V({x:u,y:p,initialPlacement:r,placement:f,strategy:n,middlewareData:w,rects:d,platform:a,elements:{reference:t,floating:e}});u=E??u,p=k??p,w[R]={...w[R],...N},ae&&y<km&&(y++,typeof ae=="object"&&(ae.placement&&(f=ae.placement),ae.rects&&(d=ae.rects===!0?await s.getElementRects({reference:t,floating:e,strategy:n}):ae.rects),{x:u,y:p}=rp(d,f,l)),T=-1)}return{x:u,y:p,placement:f,strategy:n,middlewareData:w}};function Dm(t,e,i){return(t?[...i.filter(n=>vi(n)===t),...i.filter(n=>vi(n)!==t)]:i.filter(n=>bn(n)===n)).filter(n=>t?vi(n)===t||(e?tp(n)!==n:!1):!0)}var sp=function(t){return t===void 0&&(t={}),{name:"autoPlacement",options:t,async fn(e){var i,r,n;let{rects:o,middlewareData:s,placement:a,platform:l,elements:d}=e,{crossAxis:u=!1,alignment:p,allowedPlacements:f=ja,autoAlignment:y=!0,...w}=ss(t,e),T=p!==void 0||f===ja?Dm(p||null,y,f):f,b=((i=s.autoPlacement)==null?void 0:i.index)||0,R=T[b];if(R==null)return{};if(a!==R)return{reset:{placement:T[0]}};let V=await l.detectOverflow(e,w),E=ep(R,o,await(l.isRTL==null?void 0:l.isRTL(d.floating))),k=[V[bn(R)],V[E[0]],V[E[1]]],N=[...((r=s.autoPlacement)==null?void 0:r.overflows)||[],{placement:R,overflows:k}],ae=T[b+1];if(ae)return{data:{index:b+1,overflows:N},reset:{placement:ae}};let q=N.map(ct=>{let Ei=vi(ct.placement);return[ct.placement,Ei&&u?ct.overflows.slice(0,2).reduce((eh,th)=>eh+th,0):ct.overflows[0],ct.overflows]}).sort((ct,Ei)=>ct[1]-Ei[1]),Hr=((n=q.filter(ct=>ct[2].slice(0,vi(ct[0])?2:3).every(Ei=>Ei<=0))[0])==null?void 0:n[0])||q[0][0];return Hr!==a?{data:{index:b+1,overflows:N},reset:{placement:Hr}}:{}}}};var ap=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){let{x:i,y:r,placement:n,platform:o}=e,{mainAxis:s=!0,crossAxis:a=!1,limiter:l={fn:V=>{let{x:E,y:k}=V;return{x:E,y:k}}},...d}=ss(t,e),u={x:i,y:r},p=await o.detectOverflow(e,d),f=as(n),y=Wa(f),w=u[y],T=u[f],b=(V,E)=>Qu(E+p[V==="y"?"top":"left"],E,E-p[V==="y"?"bottom":"right"]);s&&(w=b(y,w)),a&&(T=b(f,T));let R=l.fn({...e,[y]:w,[f]:T});return{...R,data:{x:R.x-i,y:R.y-r,enabled:{[y]:s,[f]:a}}}}}};function cs(){return typeof window<"u"}function Xi(t){return cp(t)?(t.nodeName||"").toLowerCase():"#document"}function Ye(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function ri(t){var e;return(e=(cp(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function cp(t){return cs()?t instanceof Node||t instanceof Ye(t).Node:!1}function Rt(t){return cs()?t instanceof Element||t instanceof Ye(t).Element:!1}function ni(t){return cs()?t instanceof HTMLElement||t instanceof Ye(t).HTMLElement:!1}function lp(t){return!cs()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof Ye(t).ShadowRoot}function Sn(t){let{overflow:e,overflowX:i,overflowY:r,display:n}=Ot(t);return/auto|scroll|overlay|hidden|clip/.test(e+r+i)&&n!=="inline"&&n!=="contents"}function dp(t){return/^(table|td|th)$/.test(Xi(t))}function wn(t){try{if(t.matches(":popover-open"))return!0}catch{}try{return t.matches(":modal")}catch{return!1}}var Lm=/transform|translate|scale|rotate|perspective|filter/,Im=/paint|layout|strict|content/,Zi=t=>!!t&&t!=="none",qa;function Dr(t){let e=Rt(t)?Ot(t):t;return Zi(e.transform)||Zi(e.translate)||Zi(e.scale)||Zi(e.rotate)||Zi(e.perspective)||!ds()&&(Zi(e.backdropFilter)||Zi(e.filter))||Lm.test(e.willChange||"")||Im.test(e.contain||"")}function up(t){let e=xi(t);for(;ni(e)&&!Lr(e);){if(Dr(e))return e;if(wn(e))return null;e=xi(e)}return null}function ds(){return qa==null&&(qa=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),qa}function Lr(t){return/^(html|body|#document)$/.test(Xi(t))}function Ot(t){return Ye(t).getComputedStyle(t)}function En(t){return Rt(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function xi(t){if(Xi(t)==="html")return t;let e=t.assignedSlot||t.parentNode||lp(t)&&t.host||ri(t);return lp(e)?e.host:e}function pp(t){let e=xi(t);return Lr(e)?(t.ownerDocument||t).body:ni(e)&&Sn(e)?e:pp(e)}function ls(t,e,i){var r;e===void 0&&(e=[]),i===void 0&&(i=!0);let n=pp(t),o=n===((r=t.ownerDocument)==null?void 0:r.body),s=Ye(n);if(o){let a=us(s);return e.concat(s,s.visualViewport||[],Sn(n)?n:[],a&&i?ls(a):[])}else return e.concat(n,ls(n,[],i))}function us(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function mp(t){let e=Ot(t),i=parseFloat(e.width)||0,r=parseFloat(e.height)||0,n=ni(t),o=n?t.offsetWidth:i,s=n?t.offsetHeight:r,a=xn(i)!==o||xn(r)!==s;return a&&(i=o,r=s),{width:i,height:r,$:a}}function gp(t){return Rt(t)?t:t.contextElement}function Ir(t){let e=gp(t);if(!ni(e))return Vt(1);let i=e.getBoundingClientRect(),{width:r,height:n,$:o}=mp(e),s=(o?xn(i.width):i.width)/r,a=(o?xn(i.height):i.height)/n;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var Mm=Vt(0);function yp(t){let e=Ye(t);return!ds()||!e.visualViewport?Mm:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function Pm(t,e,i){return e===void 0&&(e=!1),!!i&&e&&i===Ye(t)}function _n(t,e,i,r){e===void 0&&(e=!1),i===void 0&&(i=!1);let n=t.getBoundingClientRect(),o=gp(t),s=Vt(1);e&&(r?Rt(r)&&(s=Ir(r)):s=Ir(t));let a=Pm(o,i,r)?yp(o):Vt(0),l=(n.left+a.x)/s.x,d=(n.top+a.y)/s.y,u=n.width/s.x,p=n.height/s.y;if(o&&r){let f=Ye(o),y=Rt(r)?Ye(r):r,w=f,T=us(w);for(;T&&y!==w;){let b=Ir(T),R=T.getBoundingClientRect(),V=Ot(T),E=R.left+(T.clientLeft+parseFloat(V.paddingLeft))*b.x,k=R.top+(T.clientTop+parseFloat(V.paddingTop))*b.y;l*=b.x,d*=b.y,u*=b.x,p*=b.y,l+=E,d+=k,w=Ye(T),T=us(w)}}return Yi({width:u,height:p,x:l,y:d})}function ps(t,e){let i=En(t).scrollLeft;return e?e.left+i:_n(ri(t)).left+i}function vp(t,e){let i=t.getBoundingClientRect(),r=i.left+e.scrollLeft-ps(t,i),n=i.top+e.scrollTop;return{x:r,y:n}}function Nm(t){let{elements:e,rect:i,offsetParent:r,strategy:n}=t,o=n==="fixed",s=ri(r),a=e?wn(e.floating):!1;if(r===s||a&&o)return i;let l={scrollLeft:0,scrollTop:0},d=Vt(1),u=Vt(0),p=ni(r);if((p||!o)&&((Xi(r)!=="body"||Sn(s))&&(l=En(r)),p)){let y=_n(r);d=Ir(r),u.x=y.x+r.clientLeft,u.y=y.y+r.clientTop}let f=s&&!p&&!o?vp(s,l):Vt(0);return{width:i.width*d.x,height:i.height*d.y,x:i.x*d.x-l.scrollLeft*d.x+u.x+f.x,y:i.y*d.y-l.scrollTop*d.y+u.y+f.y}}function $m(t){return t.getClientRects?Array.from(t.getClientRects()):[]}function Um(t){let e=En(t),i=t.ownerDocument.body,r=yi(t.scrollWidth,t.clientWidth,i.scrollWidth,i.clientWidth),n=yi(t.scrollHeight,t.clientHeight,i.scrollHeight,i.clientHeight),o=-e.scrollLeft+ps(t),s=-e.scrollTop;return Ot(i).direction==="rtl"&&(o+=yi(t.clientWidth,i.clientWidth)-r),{width:r,height:n,x:o,y:s}}var Fm=25;function Vm(t,e,i){i===void 0&&(i="viewport");let r=i==="layoutViewport",n=Ye(t),o=ri(t),s=n.visualViewport,a=o.clientWidth,l=o.clientHeight,d=0,u=0;if(s){let f=!ds()||e==="fixed";r?f||(d=-s.offsetLeft,u=-s.offsetTop):(a=s.width,l=s.height,f&&(d=s.offsetLeft,u=s.offsetTop))}if(ps(o)<=0){let f=o.ownerDocument,y=f.body,w=getComputedStyle(y),T=f.compatMode==="CSS1Compat"&&parseFloat(w.marginLeft)+parseFloat(w.marginRight)||0,b=Math.abs(o.clientWidth-y.clientWidth-T),R=getComputedStyle(o).scrollbarGutter==="stable both-edges"?b/2:b;R<=Fm&&(a-=R)}return{width:a,height:l,x:d,y:u}}function Bm(t,e){let i=_n(t,!0,e==="fixed"),r=i.top+t.clientTop,n=i.left+t.clientLeft,o=Ir(t),s=t.clientWidth*o.x,a=t.clientHeight*o.y,l=n*o.x,d=r*o.y;return{width:s,height:a,x:l,y:d}}function fp(t,e,i){let r;if(e==="viewport"||e==="layoutViewport")r=Vm(t,i,e);else if(e==="document")r=Um(ri(t));else if(Rt(e))r=Bm(e,i);else{let n=yp(t);r={x:e.x-n.x,y:e.y-n.y,width:e.width,height:e.height}}return Yi(r)}function Hm(t,e){let i=e.get(t);if(i)return i;let r=ls(t,[],!1).filter(a=>Rt(a)&&Xi(a)!=="body"),n=null,o=Ot(t).position==="fixed",s=o?xi(t):t;for(;Rt(s)&&!Lr(s);){let a=Ot(s),l=Dr(s),d=n?n.position:o?"fixed":"";!l&&(d==="fixed"||d==="absolute"&&a.position==="static")?r=r.filter(p=>p!==s):n=a,s=xi(s)}return e.set(t,r),r}function zm(t){let{element:e,boundary:i,rootBoundary:r,strategy:n}=t,s=[...i==="clippingAncestors"?wn(e)?[]:Hm(e,this._c):[].concat(i),r],a=fp(e,s[0],n),l=a.top,d=a.right,u=a.bottom,p=a.left;for(let f=1;f<s.length;f++){let y=fp(e,s[f],n);l=yi(y.top,l),d=vn(y.right,d),u=vn(y.bottom,u),p=yi(y.left,p)}return{width:d-p,height:u-l,x:p,y:l}}function jm(t){let{width:e,height:i}=mp(t);return{width:e,height:i}}function Wm(t,e,i){let r=ni(e),n=ri(e),o=i==="fixed",s=_n(t,!0,o,e),a={scrollLeft:0,scrollTop:0},l=Vt(0);if((r||!o)&&((Xi(e)!=="body"||Sn(n))&&(a=En(e)),r)){let f=_n(e,!0,o,e);l.x=f.x+e.clientLeft,l.y=f.y+e.clientTop}!r&&n&&(l.x=ps(n));let d=n&&!r&&!o?vp(n,a):Vt(0),u=s.left+a.scrollLeft-l.x-d.x,p=s.top+a.scrollTop-l.y-d.y;return{x:u,y:p,width:s.width,height:s.height}}function Ya(t){return Ot(t).position==="static"}function hp(t,e){if(!ni(t)||Ot(t).position==="fixed")return null;if(e)return e(t);let i=t.offsetParent;return ri(t)===i&&(i=i.ownerDocument.body),i}function xp(t,e){let i=Ye(t);if(wn(t))return i;if(!ni(t)){let n=xi(t);for(;n&&!Lr(n);){if(Rt(n)&&!Ya(n))return n;n=xi(n)}return i}let r=hp(t,e);for(;r&&dp(r)&&Ya(r);)r=hp(r,e);return r&&Lr(r)&&Ya(r)&&!Dr(r)?i:r||up(t)||i}var Km=async function(t){let e=this.getOffsetParent||xp,i=this.getDimensions,r=await i(t.floating);return{reference:Wm(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Gm(t){return Ot(t).direction==="rtl"}var fs={convertOffsetParentRelativeRectToViewportRelativeRect:Nm,getDocumentElement:ri,getClippingRect:zm,getOffsetParent:xp,getElementRects:Km,getClientRects:$m,getDimensions:jm,getScale:Ir,isElement:Rt,isRTL:Gm};var bp=sp,Sp=ap;var wp=(t,e,i)=>{let r=new Map,n=i??{},o={...fs,...n.platform,_c:r};return op(t,e,{...n,platform:o})};function Ep(t){return qm(t)}function Za(t){return t.assignedSlot?t.assignedSlot:t.parentNode instanceof ShadowRoot?t.parentNode.host:t.parentNode}function qm(t){for(let e=t;e;e=Za(e))if(e instanceof Element&&getComputedStyle(e).display==="none")return null;for(let e=Za(t);e;e=Za(e)){if(!(e instanceof Element))continue;let i=getComputedStyle(e);if(i.display!=="contents"&&(i.position!=="static"||Dr(i)||e.tagName==="BODY"))return e}return null}async function hs(t,e,i){let r;return typeof i=="object"?r=i:r={placement:i},wp(t,e,{strategy:r.strategy,platform:{...fs,getOffsetParent:n=>fs.getOffsetParent(n,Ep)},middleware:[Sp({crossAxis:!0}),bp({allowedPlacements:[r.placement]})]})}var _p=c(h());var Xa=class{fromAttribute(e){if(!e)return[];try{let i=JSON.parse(e);return Array.isArray(i)?i.map(r=>typeof r=="string"?_r.fromAttribute(r):r):[]}catch{return[]}}toAttribute(e){if(e!=null)return JSON.stringify(e)}},Ym=new Xa;var Ap=(t,e)=>(i,r)=>{var n;i.constructor.createProperty(r,{type:Object,hasChanged:_p.hasChanged,converter:_r,...e}),i[fn]=(n=i[fn])!==null&&n!==void 0?n:new Map,i[fn].set(r,t??{})};var kt=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},re=class extends Go{constructor(){super(...arguments),this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.ignoreMatchingElements=[],this.visible=!1,this.validPositions=new Set(["top","bottom","left","right"]),this.hideDebounce=new gt.Debouncer,this.revealDebouncer=new gt.Debouncer,this.onTouch=e=>{this.isIgnored(e)||(this.show(),setTimeout(()=>window.addEventListener("touchstart",i=>{i.composedPath().includes(this.container)||this.onOut(i)},{once:!0}),100))},this.onHover=e=>{this.isIgnored(e)?this.matchesIgnored(e)&&this.hide():this.show()},this.onFocusIn=e=>{!this.isIgnored(e)&&window.FluidTopicsA11yHints.isKeyboardNavigation&&window.FluidTopicsA11yHints.lastPressedKey==="Tab"&&this.show()},this.onOut=e=>{this.isIgnored(e)||(this.revealDebouncer.cancel(),this.hide())},this.onClick=e=>{this.isIgnored(e)||(this.revealDebouncer.cancel(),this.hide())}}get validPosition(){return this.validPositions.has(this.position)?this.position:"bottom"}render(){var e,i;return Cp.html`
555
565
  <div part="container"
556
566
  class="ft-tooltip--container ${this.inline?"ft-tooltip--inline":""}">
557
567
  <slot part="slot"></slot>
@@ -566,7 +576,7 @@
566
576
  </div>
567
577
  </div>
568
578
  </div>
569
- `}setupFor(e){this.eventsTarget!==e&&(this.removeHandlers(),this.eventsTarget=e,this.eventsTarget.addEventListener("mouseover",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("mouseover",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){var i,r;e.has("visible")&&(this.visible?(this.resetTooltipContent(),(i=this.tooltip)===null||i===void 0||i.showPopover()):(r=this.tooltip)===null||r===void 0||r.hidePopover()),super.updated(e)}contentAvailableCallback(e){super.contentAvailableCallback(e),["visible","text"].some(i=>e.has(i))&&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,i){let r=this.manual;this.manual=!0;let n=this.text;this.text={message:e},await this.show(i),this.text=n,this.manual=r}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(i=>i.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&&hs(this.slottedElement,this.tooltip,{placement:this.position,strategy:"fixed"}).then(({x:e,y:i})=>{this.tooltip&&(this.tooltip.style.transform=`translate(${e}px,${i}px)`)}),this.revealDebouncer.run(()=>{this.tooltipContent&&(this.tooltipContent.style.transition=`top ${gt.designSystemVariables.transitionDuration}, left ${gt.designSystemVariables.transitionDuration}`,this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")},this.manual?0:this.delay)}matchesIgnored(e){return(0,gt.eventPathContainsMatchingElement)(e,this.ignoreMatchingElements,this.eventsTarget)}isIgnored(e){return this.manual||this.matchesIgnored(e)}};re.elementDefinitions={"ft-typography":F};re.styles=Zu;kt([Ap()],re.prototype,"text",void 0);kt([(0,yt.property)({type:Boolean})],re.prototype,"manual",void 0);kt([(0,yt.property)({type:Boolean})],re.prototype,"inline",void 0);kt([(0,gt.numberProperty)()],re.prototype,"delay",void 0);kt([(0,yt.property)()],re.prototype,"position",void 0);kt([(0,gt.jsonProperty)([])],re.prototype,"ignoreMatchingElements",void 0);kt([(0,yt.queryAssignedNodes)()],re.prototype,"slotNodes",void 0);kt([(0,yt.query)(".ft-tooltip--container")],re.prototype,"container",void 0);kt([(0,yt.query)(".ft-tooltip")],re.prototype,"tooltip",void 0);kt([(0,yt.query)(".ft-tooltip--content")],re.prototype,"tooltipContent",void 0);kt([(0,yt.state)()],re.prototype,"visible",void 0);var Rp=c(h());var Tp={"ft-tooltip":re};(0,Rp.customElements)(Tp);var Op=c(x()),An=c(h()),qi={color:An.FtCssVariableFactory.extend("--ft-loader-color","",An.designSystemVariables.colorPrimary),size:An.FtCssVariableFactory.create("--ft-loader-size","","SIZE","80px")},kp=Op.css`
579
+ `}setupFor(e){this.eventsTarget!==e&&(this.removeHandlers(),this.eventsTarget=e,this.eventsTarget.addEventListener("mouseover",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("mouseover",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){var i,r;e.has("visible")&&(this.visible?(this.resetTooltipContent(),(i=this.tooltip)===null||i===void 0||i.showPopover()):(r=this.tooltip)===null||r===void 0||r.hidePopover()),super.updated(e)}contentAvailableCallback(e){super.contentAvailableCallback(e),["visible","text"].some(i=>e.has(i))&&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,i){let r=this.manual;this.manual=!0;let n=this.text;this.text={message:e},await this.show(i),this.text=n,this.manual=r}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(i=>i.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&&hs(this.slottedElement,this.tooltip,{placement:this.position,strategy:"fixed"}).then(({x:e,y:i})=>{this.tooltip&&(this.tooltip.style.transform=`translate(${e}px,${i}px)`)}),this.revealDebouncer.run(()=>{this.tooltipContent&&(this.tooltipContent.style.transition=`top ${gt.designSystemVariables.transitionDuration}, left ${gt.designSystemVariables.transitionDuration}`,this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")},this.manual?0:this.delay)}matchesIgnored(e){return(0,gt.eventPathContainsMatchingElement)(e,this.ignoreMatchingElements,this.eventsTarget)}isIgnored(e){return this.manual||this.matchesIgnored(e)}};re.elementDefinitions={"ft-typography":F};re.styles=Zu;kt([Ap()],re.prototype,"text",void 0);kt([(0,yt.property)({type:Boolean})],re.prototype,"manual",void 0);kt([(0,yt.property)({type:Boolean})],re.prototype,"inline",void 0);kt([(0,gt.numberProperty)()],re.prototype,"delay",void 0);kt([(0,yt.property)()],re.prototype,"position",void 0);kt([(0,gt.jsonProperty)([])],re.prototype,"ignoreMatchingElements",void 0);kt([(0,yt.queryAssignedNodes)()],re.prototype,"slotNodes",void 0);kt([(0,yt.query)(".ft-tooltip--container")],re.prototype,"container",void 0);kt([(0,yt.query)(".ft-tooltip")],re.prototype,"tooltip",void 0);kt([(0,yt.query)(".ft-tooltip--content")],re.prototype,"tooltipContent",void 0);kt([(0,yt.state)()],re.prototype,"visible",void 0);var Rp=c(h());var Tp={"ft-tooltip":re};(0,Rp.customElements)(Tp);var Op=c(S()),An=c(h()),Ji={color:An.FtCssVariableFactory.extend("--ft-loader-color","",An.designSystemVariables.colorPrimary),size:An.FtCssVariableFactory.create("--ft-loader-size","","SIZE","80px")},kp=Op.css`
570
580
  :host {
571
581
  line-height: 0;
572
582
  }
@@ -575,8 +585,8 @@
575
585
  display: inline-block;
576
586
  position: relative;
577
587
 
578
- width: ${qi.size};
579
- height: ${qi.size};
588
+ width: ${Ji.size};
589
+ height: ${Ji.size};
580
590
  }
581
591
 
582
592
  .ft-loader div {
@@ -585,7 +595,7 @@
585
595
  width: 25%;
586
596
  height: 25%;
587
597
  border-radius: 50%;
588
- background: ${qi.color};
598
+ background: ${Ji.color};
589
599
  animation-timing-function: cubic-bezier(0, 1, 1, 0);
590
600
  }
591
601
 
@@ -632,17 +642,17 @@
632
642
  transform: translate(0, 0);
633
643
  }
634
644
  100% {
635
- transform: translate(calc(0.35 * ${qi.size}), 0);
645
+ transform: translate(calc(0.35 * ${Ji.size}), 0);
636
646
  }
637
647
  }
638
- `;var Lp=c(x()),Dp=c(h());var Yi=class extends Dp.FtLitElement{render(){return Lp.html`
648
+ `;var Dp=c(S()),Lp=c(h());var Qi=class extends Lp.FtLitElement{render(){return Dp.html`
639
649
  <div class="ft-loader">
640
650
  <div></div>
641
651
  <div></div>
642
652
  <div></div>
643
653
  <div></div>
644
654
  </div>
645
- `}};Yi.styles=kp;var Mp=c(h());var Ip={"ft-loader":Yi};(0,Mp.customElements)(Ip);var xi=c(x()),ms=c(rt()),W=c(U());var Lt=t=>t??he;var $p=c(x()),O=c(h());var Pp=O.FtCssVariableFactory.extend("--ft-button-color","",O.designSystemVariables.colorPrimary),B={backgroundColor:O.FtCssVariableFactory.extend("--ft-button-background-color","",O.designSystemVariables.colorSurface),borderRadius:O.FtCssVariableFactory.extend("--ft-button-border-radius","",O.designSystemVariables.borderRadiusL),color:Pp,fontSize:O.FtCssVariableFactory.extend("--ft-button-font-size","",Fe.fontSize),iconSize:O.FtCssVariableFactory.create("--ft-button-icon-size","","SIZE","24px"),rippleColor:O.FtCssVariableFactory.extend("--ft-button-ripple-color","",Pp),verticalPadding:O.FtCssVariableFactory.create("--ft-button-vertical-padding","","SIZE","6px"),horizontalPadding:O.FtCssVariableFactory.create("--ft-button-horizontal-padding","","SIZE","8px"),iconPadding:O.FtCssVariableFactory.create("--ft-button-icon-padding","","SIZE","8px"),opacityDisabled:O.FtCssVariableFactory.external(O.designSystemVariables.colorOpacityDisabled,"Design system")},Np=O.FtCssVariableFactory.extend("--ft-button-primary-color","",O.FtCssVariableFactory.extend("--ft-button-color","",O.designSystemVariables.colorOnPrimary)),Ja={backgroundColor:O.FtCssVariableFactory.extend("--ft-button-primary-background-color","",O.FtCssVariableFactory.extend("--ft-button-background-color","",O.designSystemVariables.colorPrimary)),color:Np,rippleColor:O.FtCssVariableFactory.extend("--ft-button-primary-ripple-color","",Np)},Bt={borderRadius:O.FtCssVariableFactory.extend("--ft-button-dense-border-radius","",O.FtCssVariableFactory.extend("--ft-button-border-radius","",O.designSystemVariables.borderRadiusM)),verticalPadding:O.FtCssVariableFactory.create("--ft-button-dense-vertical-padding","","SIZE","2px"),horizontalPadding:O.FtCssVariableFactory.create("--ft-button-dense-horizontal-padding","","SIZE","4px"),iconPadding:O.FtCssVariableFactory.create("--ft-button-dense-icon-padding","","SIZE","4px")},Up=$p.css`
655
+ `}};Qi.styles=kp;var Mp=c(h());var Ip={"ft-loader":Qi};(0,Mp.customElements)(Ip);var bi=c(S()),ms=c(ot()),W=c(U());var Dt=t=>t??he;var $p=c(S()),O=c(h());var Pp=O.FtCssVariableFactory.extend("--ft-button-color","",O.designSystemVariables.colorPrimary),B={backgroundColor:O.FtCssVariableFactory.extend("--ft-button-background-color","",O.designSystemVariables.colorSurface),borderRadius:O.FtCssVariableFactory.extend("--ft-button-border-radius","",O.designSystemVariables.borderRadiusL),color:Pp,fontSize:O.FtCssVariableFactory.extend("--ft-button-font-size","",Ie.fontSize),iconSize:O.FtCssVariableFactory.create("--ft-button-icon-size","","SIZE","24px"),rippleColor:O.FtCssVariableFactory.extend("--ft-button-ripple-color","",Pp),verticalPadding:O.FtCssVariableFactory.create("--ft-button-vertical-padding","","SIZE","6px"),horizontalPadding:O.FtCssVariableFactory.create("--ft-button-horizontal-padding","","SIZE","8px"),iconPadding:O.FtCssVariableFactory.create("--ft-button-icon-padding","","SIZE","8px"),opacityDisabled:O.FtCssVariableFactory.external(O.designSystemVariables.colorOpacityDisabled,"Design system")},Np=O.FtCssVariableFactory.extend("--ft-button-primary-color","",O.FtCssVariableFactory.extend("--ft-button-color","",O.designSystemVariables.colorOnPrimary)),Ja={backgroundColor:O.FtCssVariableFactory.extend("--ft-button-primary-background-color","",O.FtCssVariableFactory.extend("--ft-button-background-color","",O.designSystemVariables.colorPrimary)),color:Np,rippleColor:O.FtCssVariableFactory.extend("--ft-button-primary-ripple-color","",Np)},Bt={borderRadius:O.FtCssVariableFactory.extend("--ft-button-dense-border-radius","",O.FtCssVariableFactory.extend("--ft-button-border-radius","",O.designSystemVariables.borderRadiusM)),verticalPadding:O.FtCssVariableFactory.create("--ft-button-dense-vertical-padding","","SIZE","2px"),horizontalPadding:O.FtCssVariableFactory.create("--ft-button-dense-horizontal-padding","","SIZE","4px"),iconPadding:O.FtCssVariableFactory.create("--ft-button-dense-icon-padding","","SIZE","4px")},Up=$p.css`
646
656
  :host {
647
657
  display: inline-block;
648
658
  max-width: 100%;
@@ -744,8 +754,8 @@
744
754
  text-overflow: ellipsis;
745
755
  display: block;
746
756
  margin: 0 ${B.iconPadding};
747
- ${(0,O.setVariable)(Fe.fontSize,"1em")};
748
- ${(0,O.setVariable)(Fe.lineHeight,"var(--button-internal-line-height)")};
757
+ ${(0,O.setVariable)(Ie.fontSize,"1em")};
758
+ ${(0,O.setVariable)(Ie.lineHeight,"var(--button-internal-line-height)")};
749
759
  }
750
760
 
751
761
  .ft-button--dense .ft-button--label {
@@ -776,10 +786,10 @@
776
786
  }
777
787
 
778
788
  ft-loader {
779
- ${(0,O.setVariable)(qi.size,B.iconSize)};
780
- ${(0,O.setVariable)(qi.color,"var(--button-internal-color)")};
789
+ ${(0,O.setVariable)(Ji.size,B.iconSize)};
790
+ ${(0,O.setVariable)(Ji.color,"var(--button-internal-color)")};
781
791
  }
782
- `;var Y=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},L=class t extends(0,Ht.toFtFormComponent)(Ht.FtLitElement){get buttonClasses(){return{"ft-button":!0,"ft-button--primary":this.primary,"ft-button--outlined":this.outlined,"ft-button--dense":this.dense,"ft-button--round":this.round,"ft-button--trailing-icon":this.trailingIcon,"ft-button--loading":this.trailingIcon,"ft-no-text-select":!0}}constructor(){super(),this.primary=!1,this.outlined=!1,this.dense=!1,this.round=!1,this.disabled=!1,this.icon=void 0,this.trailingIcon=!1,this.type="button",this.href=void 0,this.target=void 0,this.loading=!1,this.ariaLabel=null,this.ariaHasPopup=null,this.ariaPressed=null,this.tooltipPosition="bottom",this.hideTooltip=!1,this.forceTooltip=!1,this.activated=!1,this.hasTextContent=!1,this.addEventListener("click",e=>{var i;this.isDisabled()?(e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation()):this.type=="submit"&&((i=this.form)===null||i===void 0||i.requestSubmit())})}render(){var e,i,r;let n={"ft-button--label":!0,"ft-safari-ellipsis-fix":Ht.isSafari,"ft-button--label-no-text":!this.hasTextContent},o=xi.html`
792
+ `;var Y=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},D=class t extends(0,Ht.toFtFormComponent)(Ht.FtLitElement){get buttonClasses(){return{"ft-button":!0,"ft-button--primary":this.primary,"ft-button--outlined":this.outlined,"ft-button--dense":this.dense,"ft-button--round":this.round,"ft-button--trailing-icon":this.trailingIcon,"ft-button--loading":this.trailingIcon,"ft-no-text-select":!0}}constructor(){super(),this.primary=!1,this.outlined=!1,this.dense=!1,this.round=!1,this.disabled=!1,this.icon=void 0,this.trailingIcon=!1,this.type="button",this.href=void 0,this.target=void 0,this.loading=!1,this.ariaLabel=null,this.ariaHasPopup=null,this.ariaPressed=null,this.tooltipPosition="bottom",this.hideTooltip=!1,this.forceTooltip=!1,this.activated=!1,this.hasTextContent=!1,this.addEventListener("click",e=>{var i;this.isDisabled()?(e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation()):this.type=="submit"&&((i=this.form)===null||i===void 0||i.requestSubmit())})}render(){var e,i,r;let n={"ft-button--label":!0,"ft-safari-ellipsis-fix":Ht.isSafari,"ft-button--label-no-text":!this.hasTextContent},o=bi.html`
783
793
  <ft-ripple part="ripple"
784
794
  ?disabled=${this.isDisabled()}
785
795
  ?activated=${this.activated}
@@ -791,36 +801,36 @@
791
801
  <slot></slot>
792
802
  </ft-typography>
793
803
  ${this.resolveIcon()}
794
- `,s=this.href!=null&&this.href.trim().length>0?this.href:void 0;return this.addTooltipIfNeeded(s?xi.html`
804
+ `,s=this.href!=null&&this.href.trim().length>0?this.href:void 0;return this.addTooltipIfNeeded(s?bi.html`
795
805
  <a href="${s}"
796
806
  target="${(e=this.target)!==null&&e!==void 0?e:"_self"}"
797
807
  part="button"
798
808
  class="${(0,ms.classMap)(this.buttonClasses)}"
799
- aria-label="${Lt((i=this.ariaLabel)!==null&&i!==void 0?i:this.label)}"
809
+ aria-label="${Dt((i=this.ariaLabel)!==null&&i!==void 0?i:this.label)}"
800
810
  ?disabled=${this.isDisabled()}>
801
811
  ${o}
802
812
  </a>
803
- `:xi.html`
813
+ `:bi.html`
804
814
  <button part="button"
805
815
  class="${(0,ms.classMap)(this.buttonClasses)}"
806
- aria-label="${Lt((r=this.ariaLabel)!==null&&r!==void 0?r:this.label)}"
807
- aria-haspopup="${Lt(this.ariaHasPopup)}"
808
- aria-pressed="${Lt(this.ariaPressed)}"
816
+ aria-label="${Dt((r=this.ariaLabel)!==null&&r!==void 0?r:this.label)}"
817
+ aria-haspopup="${Dt(this.ariaHasPopup)}"
818
+ aria-pressed="${Dt(this.ariaPressed)}"
809
819
  ?disabled=${this.isDisabled()}>
810
820
  ${o}
811
821
  </button>
812
- `)}addTooltipIfNeeded(e){return this.label&&this.label.trim().length>0&&(this.forceTooltip||!this.hasTextContent&&!this.hideTooltip)?xi.html`
822
+ `)}addTooltipIfNeeded(e){return this.label&&this.label.trim().length>0&&(this.forceTooltip||!this.hasTextContent&&!this.hideTooltip)?bi.html`
813
823
  <ft-tooltip part="tooltip"
814
824
  text="${this.label}"
815
825
  position="${this.tooltipPosition}">
816
826
  ${e}
817
827
  </ft-tooltip>
818
- `:e}resolveIcon(){return this.loading?xi.html`
819
- <ft-loader part="loader icon"></ft-loader> `:this.icon?xi.html`
828
+ `:e}resolveIcon(){return this.loading?bi.html`
829
+ <ft-loader part="loader icon"></ft-loader> `:this.icon?bi.html`
820
830
  <ft-icon part="icon" .variant=${this.iconVariant} .value=${this.icon}></ft-icon>
821
- `:xi.html`
831
+ `:bi.html`
822
832
  <slot part="icon" name="icon"></slot>
823
- `}focus(){var e;(e=this.button)===null||e===void 0||e.focus()}showTooltip(){var e;(e=this.tooltip)===null||e===void 0||e.show()}showTemporaryTooltip(e,i){var r;return(r=this.tooltip)===null||r===void 0?void 0:r.showTemporaryText(e,i)}setTooltipManual(e){this.tooltip&&(this.tooltip.manual=e)}click(){var e;(e=this.button)===null||e===void 0||e.click()}isDisabled(){return this.disabled||this.loading}contentAvailableCallback(e){super.contentAvailableCallback(e),this.labelContainer&&t.labelsObserver.observe(this.labelContainer)}disconnectedCallback(){super.disconnectedCallback(),this.labelContainer&&t.labelsObserver.unobserve(this.labelContainer)}};L.elementDefinitions={"ft-ripple":M,"ft-tooltip":re,"ft-icon":z,"ft-loader":Yi,"ft-typography":F};L.styles=[Ht.safariEllipsisFix,Up,Ht.noTextSelect];L.labelsObserver=new IntersectionObserver(t=>{for(let e of t){let i=e.target.getRootNode();i.host?i.host.hasTextContent=e.boundingClientRect.width>0:L.labelsObserver.unobserve(e.target)}});Y([(0,W.property)({type:Boolean})],L.prototype,"primary",void 0);Y([(0,W.property)({type:Boolean})],L.prototype,"outlined",void 0);Y([(0,W.property)({type:Boolean})],L.prototype,"dense",void 0);Y([(0,W.property)({type:Boolean})],L.prototype,"round",void 0);Y([(0,W.property)({type:Boolean})],L.prototype,"disabled",void 0);Y([(0,W.property)()],L.prototype,"icon",void 0);Y([(0,W.property)()],L.prototype,"iconVariant",void 0);Y([(0,W.property)({type:Boolean})],L.prototype,"trailingIcon",void 0);Y([(0,W.property)()],L.prototype,"label",void 0);Y([(0,W.property)()],L.prototype,"type",void 0);Y([(0,W.property)()],L.prototype,"href",void 0);Y([(0,W.property)()],L.prototype,"target",void 0);Y([(0,W.property)({type:Boolean})],L.prototype,"loading",void 0);Y([(0,W.property)({attribute:"aria-label"})],L.prototype,"ariaLabel",void 0);Y([(0,W.property)()],L.prototype,"ariaHasPopup",void 0);Y([(0,W.property)({attribute:"aria-pressed"})],L.prototype,"ariaPressed",void 0);Y([(0,W.property)()],L.prototype,"tooltipPosition",void 0);Y([(0,W.property)({type:Boolean})],L.prototype,"hideTooltip",void 0);Y([(0,W.property)({type:Boolean})],L.prototype,"forceTooltip",void 0);Y([(0,W.property)({type:Boolean})],L.prototype,"activated",void 0);Y([(0,W.query)(".ft-button")],L.prototype,"button",void 0);Y([(0,W.query)(".ft-button--label")],L.prototype,"labelContainer",void 0);Y([(0,W.state)()],L.prototype,"hasTextContent",void 0);Y([(0,W.query)(".ft-button--label slot")],L.prototype,"slottedContent",void 0);Y([(0,W.query)("[part=tooltip]")],L.prototype,"tooltip",void 0);var Vp=c(h());var Fp={"ft-button":L};(0,Vp.customElements)(Fp);var gs=c(x()),zt=c(U()),jp=c(rt()),ri=c(h());var Mr=c(x()),Ye=c(U()),Pr=c(h());var zp=c(rt());var Bp=c(x()),Ve=c(h());var oe=c(h());var se={textColor:oe.FtCssVariableFactory.extend("--ft-switch-text-color","",oe.designSystemVariables.colorOnSurfaceHigh),backgroundColor:oe.FtCssVariableFactory.extend("--ft-switch-background-color","",oe.designSystemVariables.colorSurface),selectedTextColor:oe.FtCssVariableFactory.extend("--ft-switch-selected-text-color","",oe.designSystemVariables.colorPrimary),selectedBackgroundColor:oe.FtCssVariableFactory.extend("--ft-switch-selected-background-color","",oe.designSystemVariables.colorPrimary),borderColor:oe.FtCssVariableFactory.extend("--ft-switch-border-color","",oe.designSystemVariables.colorOutline),borderRadius:oe.FtCssVariableFactory.extend("--ft-switch-border-radius","",oe.designSystemVariables.borderRadiusL),fontSize:oe.FtCssVariableFactory.extend("--ft-switch-font-size","",Fe.fontSize),iconSize:oe.FtCssVariableFactory.create("--ft-switch-icon-size","","SIZE","24px"),iconColor:oe.FtCssVariableFactory.extend("--ft-switch-text-color","",oe.designSystemVariables.colorOnSurfaceMedium),rippleColor:oe.FtCssVariableFactory.extend("--ft-switch-ripple-color","",oe.designSystemVariables.colorPrimary),outlineColor:oe.FtCssVariableFactory.extend("--ft-switch-outline-color","",oe.designSystemVariables.colorPrimary)};var xe={borderRadiusLeft:Ve.FtCssVariableFactory.extend("--ft-switch-option-border-radius-left","",Ve.designSystemVariables.borderRadiusL),borderRadiusRight:Ve.FtCssVariableFactory.extend("--ft-switch-option-border-radius-right","",Ve.designSystemVariables.borderRadiusL),borderWidthLeft:Ve.FtCssVariableFactory.create("--ft-switch-option-border-width-left","","SIZE","1px"),borderWidthRight:Ve.FtCssVariableFactory.create("--ft-switch-option-border-width-right","","SIZE","1px"),borderWidthVertical:Ve.FtCssVariableFactory.create("--ft-switch-option-border-width-vertical","","SIZE","1px")},Hp=Bp.css`
833
+ `}focus(){var e;(e=this.button)===null||e===void 0||e.focus()}showTooltip(){var e;(e=this.tooltip)===null||e===void 0||e.show()}showTemporaryTooltip(e,i){var r;return(r=this.tooltip)===null||r===void 0?void 0:r.showTemporaryText(e,i)}setTooltipManual(e){this.tooltip&&(this.tooltip.manual=e)}click(){var e;(e=this.button)===null||e===void 0||e.click()}isDisabled(){return this.disabled||this.loading}contentAvailableCallback(e){super.contentAvailableCallback(e),this.labelContainer&&t.labelsObserver.observe(this.labelContainer)}disconnectedCallback(){super.disconnectedCallback(),this.labelContainer&&t.labelsObserver.unobserve(this.labelContainer)}};D.elementDefinitions={"ft-ripple":M,"ft-tooltip":re,"ft-icon":z,"ft-loader":Qi,"ft-typography":F};D.styles=[Ht.safariEllipsisFix,Up,Ht.noTextSelect];D.labelsObserver=new IntersectionObserver(t=>{for(let e of t){let i=e.target.getRootNode();i.host?i.host.hasTextContent=e.boundingClientRect.width>0:D.labelsObserver.unobserve(e.target)}});Y([(0,W.property)({type:Boolean})],D.prototype,"primary",void 0);Y([(0,W.property)({type:Boolean})],D.prototype,"outlined",void 0);Y([(0,W.property)({type:Boolean})],D.prototype,"dense",void 0);Y([(0,W.property)({type:Boolean})],D.prototype,"round",void 0);Y([(0,W.property)({type:Boolean})],D.prototype,"disabled",void 0);Y([(0,W.property)()],D.prototype,"icon",void 0);Y([(0,W.property)()],D.prototype,"iconVariant",void 0);Y([(0,W.property)({type:Boolean})],D.prototype,"trailingIcon",void 0);Y([(0,W.property)()],D.prototype,"label",void 0);Y([(0,W.property)()],D.prototype,"type",void 0);Y([(0,W.property)()],D.prototype,"href",void 0);Y([(0,W.property)()],D.prototype,"target",void 0);Y([(0,W.property)({type:Boolean})],D.prototype,"loading",void 0);Y([(0,W.property)({attribute:"aria-label"})],D.prototype,"ariaLabel",void 0);Y([(0,W.property)()],D.prototype,"ariaHasPopup",void 0);Y([(0,W.property)({attribute:"aria-pressed"})],D.prototype,"ariaPressed",void 0);Y([(0,W.property)()],D.prototype,"tooltipPosition",void 0);Y([(0,W.property)({type:Boolean})],D.prototype,"hideTooltip",void 0);Y([(0,W.property)({type:Boolean})],D.prototype,"forceTooltip",void 0);Y([(0,W.property)({type:Boolean})],D.prototype,"activated",void 0);Y([(0,W.query)(".ft-button")],D.prototype,"button",void 0);Y([(0,W.query)(".ft-button--label")],D.prototype,"labelContainer",void 0);Y([(0,W.state)()],D.prototype,"hasTextContent",void 0);Y([(0,W.query)(".ft-button--label slot")],D.prototype,"slottedContent",void 0);Y([(0,W.query)("[part=tooltip]")],D.prototype,"tooltip",void 0);var Vp=c(h());var Fp={"ft-button":D};(0,Vp.customElements)(Fp);var gs=c(S()),zt=c(U()),jp=c(ot()),oi=c(h());var Mr=c(S()),Ze=c(U()),Pr=c(h());var zp=c(ot());var Bp=c(S()),Ve=c(h());var oe=c(h());var se={textColor:oe.FtCssVariableFactory.extend("--ft-switch-text-color","",oe.designSystemVariables.colorOnSurfaceHigh),backgroundColor:oe.FtCssVariableFactory.extend("--ft-switch-background-color","",oe.designSystemVariables.colorSurface),selectedTextColor:oe.FtCssVariableFactory.extend("--ft-switch-selected-text-color","",oe.designSystemVariables.colorPrimary),selectedBackgroundColor:oe.FtCssVariableFactory.extend("--ft-switch-selected-background-color","",oe.designSystemVariables.colorPrimary),borderColor:oe.FtCssVariableFactory.extend("--ft-switch-border-color","",oe.designSystemVariables.colorOutline),borderRadius:oe.FtCssVariableFactory.extend("--ft-switch-border-radius","",oe.designSystemVariables.borderRadiusL),fontSize:oe.FtCssVariableFactory.extend("--ft-switch-font-size","",Ie.fontSize),iconSize:oe.FtCssVariableFactory.create("--ft-switch-icon-size","","SIZE","24px"),iconColor:oe.FtCssVariableFactory.extend("--ft-switch-text-color","",oe.designSystemVariables.colorOnSurfaceMedium),rippleColor:oe.FtCssVariableFactory.extend("--ft-switch-ripple-color","",oe.designSystemVariables.colorPrimary),outlineColor:oe.FtCssVariableFactory.extend("--ft-switch-outline-color","",oe.designSystemVariables.colorPrimary)};var be={borderRadiusLeft:Ve.FtCssVariableFactory.extend("--ft-switch-option-border-radius-left","",Ve.designSystemVariables.borderRadiusL),borderRadiusRight:Ve.FtCssVariableFactory.extend("--ft-switch-option-border-radius-right","",Ve.designSystemVariables.borderRadiusL),borderWidthLeft:Ve.FtCssVariableFactory.create("--ft-switch-option-border-width-left","","SIZE","1px"),borderWidthRight:Ve.FtCssVariableFactory.create("--ft-switch-option-border-width-right","","SIZE","1px"),borderWidthVertical:Ve.FtCssVariableFactory.create("--ft-switch-option-border-width-vertical","","SIZE","1px")},Hp=Bp.css`
824
834
  .ft-switch-option {
825
835
  position: relative;
826
836
  display: inline-block;
@@ -839,8 +849,8 @@
839
849
 
840
850
  border-style: solid;
841
851
  border-color: ${se.borderColor};
842
- border-width: ${xe.borderWidthVertical} ${xe.borderWidthRight} ${xe.borderWidthVertical} ${xe.borderWidthLeft};
843
- border-radius: ${xe.borderRadiusLeft} ${xe.borderRadiusRight} ${xe.borderRadiusRight} ${xe.borderRadiusLeft};
852
+ border-width: ${be.borderWidthVertical} ${be.borderWidthRight} ${be.borderWidthVertical} ${be.borderWidthLeft};
853
+ border-radius: ${be.borderRadiusLeft} ${be.borderRadiusRight} ${be.borderRadiusRight} ${be.borderRadiusLeft};
844
854
  display: flex;
845
855
  align-items: center;
846
856
  justify-content: center;
@@ -857,7 +867,7 @@
857
867
 
858
868
  .ft-switch-option--selected .ft-switch-option--content:before {
859
869
  background-color: ${se.selectedBackgroundColor};
860
- border-radius: ${xe.borderRadiusLeft} ${xe.borderRadiusRight} ${xe.borderRadiusRight} ${xe.borderRadiusLeft};
870
+ border-radius: ${be.borderRadiusLeft} ${be.borderRadiusRight} ${be.borderRadiusRight} ${be.borderRadiusLeft};
861
871
  position: absolute;
862
872
  inset: 0;
863
873
  content: "";
@@ -872,8 +882,8 @@
872
882
  text-overflow: ellipsis;
873
883
  display: block;
874
884
  margin: 0 8px;
875
- ${(0,Ve.setVariable)(Fe.fontSize,se.fontSize)};
876
- ${(0,Ve.setVariable)(Fe.lineHeight,"var(--switch-option-internal-content-height)")}
885
+ ${(0,Ve.setVariable)(Ie.fontSize,se.fontSize)};
886
+ ${(0,Ve.setVariable)(Ie.lineHeight,"var(--switch-option-internal-content-height)")}
877
887
  }
878
888
 
879
889
  .ft-switch-option--selected .ft-switch-option--label {
@@ -908,7 +918,7 @@
908
918
  .ft-switch-option--selected ft-icon {
909
919
  color: ${se.selectedTextColor};
910
920
  }
911
- `;var Dt=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Qa=class extends CustomEvent{constructor(e){super("option-change-by-user",{detail:e,bubbles:!0,composed:!0})}},el=class extends CustomEvent{constructor(e){super("option-change",{detail:e,bubbles:!0,composed:!0})}},de=class extends Pr.FtLitElement{constructor(){super(...arguments),this.value="",this.label="",this.tooltipPosition="bottom",this.selected=!1,this.trailingIcon=!1,this.unselectable=!1,this.isFocused=!1}focus(){this.input.focus()}update(e){super.update(e),e.has("selected")&&this.dispatchEvent(new el(this.selected))}render(){let e={"ft-switch-option":!0,"ft-switch-option--trailing-icon":this.trailingIcon,"ft-switch-option--selected":this.selected,"ft-switch-option--focused":this.isFocused};return this.addTooltip(Mr.html`
921
+ `;var Lt=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Qa=class extends CustomEvent{constructor(e){super("option-change-by-user",{detail:e,bubbles:!0,composed:!0})}},el=class extends CustomEvent{constructor(e){super("option-change",{detail:e,bubbles:!0,composed:!0})}},de=class extends Pr.FtLitElement{constructor(){super(...arguments),this.value="",this.label="",this.tooltipPosition="bottom",this.selected=!1,this.trailingIcon=!1,this.unselectable=!1,this.isFocused=!1}focus(){this.input.focus()}update(e){super.update(e),e.has("selected")&&this.dispatchEvent(new el(this.selected))}render(){let e={"ft-switch-option":!0,"ft-switch-option--trailing-icon":this.trailingIcon,"ft-switch-option--selected":this.selected,"ft-switch-option--focused":this.isFocused};return this.addTooltip(Mr.html`
912
922
  <label part="label" for="input" class="${(0,zp.classMap)(e)}"
913
923
  @click=${this.onChange}>
914
924
  <div class="ft-switch-option--content">
@@ -932,7 +942,7 @@
932
942
  </ft-tooltip>
933
943
  `}connectedCallback(){super.connectedCallback(),this.addEventListener("focusout",this.onFocusout)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("focusout",this.onFocusout)}onFocusout(){this.isFocused=!1}onChange(){this.selected=this.unselectable?!this.selected:!0,this.dispatchEvent(new Qa(this.selected))}getLabel(){return this.label||this.getTextContent()}resolveIcon(){return this.icon?Mr.html`
934
944
  <ft-icon part="icon" .variant=${this.iconVariant} .value=${this.icon}></ft-icon>
935
- `:Mr.nothing}getTextContent(){var e,i;return(i=(e=this.slottedContent)===null||e===void 0?void 0:e.assignedNodes().map(r=>r.textContent).join("").trim())!==null&&i!==void 0?i:""}hasTextContent(){return this.getTextContent().length>0}onSlotchange(){this.requestUpdate()}};de.elementDefinitions={"ft-ripple":M,"ft-typography":F,"ft-tooltip":re,"ft-icon":z};de.styles=[Pr.safariEllipsisFix,Hp];Dt([(0,Ye.property)()],de.prototype,"value",void 0);Dt([(0,Ye.property)()],de.prototype,"icon",void 0);Dt([(0,Ye.property)()],de.prototype,"iconVariant",void 0);Dt([(0,Ye.property)()],de.prototype,"label",void 0);Dt([(0,Ye.property)()],de.prototype,"tooltipPosition",void 0);Dt([(0,Ye.property)({type:Boolean,reflect:!0})],de.prototype,"selected",void 0);Dt([(0,Ye.property)({type:Boolean})],de.prototype,"trailingIcon",void 0);Dt([(0,Ye.property)({type:Boolean})],de.prototype,"unselectable",void 0);Dt([(0,Ye.query)(".ft-switch-option--content slot")],de.prototype,"slottedContent",void 0);Dt([(0,Ye.query)(".ft-switch-option--input")],de.prototype,"input",void 0);Dt([(0,Ye.state)()],de.prototype,"isFocused",void 0);var Zi=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},tl=class extends CustomEvent{constructor(e){super("change",{detail:e})}},Be=class extends ri.FtLitElement{constructor(){super(...arguments),this.dense=!1,this.unselectable=!1,this.displayFocusWhenUsingKeyboard=!1,this.options=[]}get value(){var e;return(e=this.selectedOption)===null||e===void 0?void 0:e.value}update(e){super.update(e),e.has("selectedOption")&&this.updateOptions(),e.has("unselectable")&&this.options.forEach(i=>i.unselectable=this.unselectable)}render(){let e={"ft-switch":!0,"ft-switch--dense":this.dense};return gs.html`
945
+ `:Mr.nothing}getTextContent(){var e,i;return(i=(e=this.slottedContent)===null||e===void 0?void 0:e.assignedNodes().map(r=>r.textContent).join("").trim())!==null&&i!==void 0?i:""}hasTextContent(){return this.getTextContent().length>0}onSlotchange(){this.requestUpdate()}};de.elementDefinitions={"ft-ripple":M,"ft-typography":F,"ft-tooltip":re,"ft-icon":z};de.styles=[Pr.safariEllipsisFix,Hp];Lt([(0,Ze.property)()],de.prototype,"value",void 0);Lt([(0,Ze.property)()],de.prototype,"icon",void 0);Lt([(0,Ze.property)()],de.prototype,"iconVariant",void 0);Lt([(0,Ze.property)()],de.prototype,"label",void 0);Lt([(0,Ze.property)()],de.prototype,"tooltipPosition",void 0);Lt([(0,Ze.property)({type:Boolean,reflect:!0})],de.prototype,"selected",void 0);Lt([(0,Ze.property)({type:Boolean})],de.prototype,"trailingIcon",void 0);Lt([(0,Ze.property)({type:Boolean})],de.prototype,"unselectable",void 0);Lt([(0,Ze.query)(".ft-switch-option--content slot")],de.prototype,"slottedContent",void 0);Lt([(0,Ze.query)(".ft-switch-option--input")],de.prototype,"input",void 0);Lt([(0,Ze.state)()],de.prototype,"isFocused",void 0);var er=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},tl=class extends CustomEvent{constructor(e){super("change",{detail:e})}},Be=class extends oi.FtLitElement{constructor(){super(...arguments),this.dense=!1,this.unselectable=!1,this.displayFocusWhenUsingKeyboard=!1,this.options=[]}get value(){var e;return(e=this.selectedOption)===null||e===void 0?void 0:e.value}update(e){super.update(e),e.has("selectedOption")&&this.updateOptions(),e.has("unselectable")&&this.options.forEach(i=>i.unselectable=this.unselectable)}render(){let e={"ft-switch":!0,"ft-switch--dense":this.dense};return gs.html`
936
946
  <div @keydown=${this.onKeyDown} tabindex="-1" class="${(0,jp.classMap)(e)}" role="radiogroup" aria-label="${this.label}">
937
947
  <slot @slotchange=${this.onSlotchange}
938
948
  @option-change=${this.onOptionChangeByScript}
@@ -955,25 +965,25 @@
955
965
  }
956
966
 
957
967
  .ft-switch slot::slotted(ft-switch-option) {
958
- ${(0,ri.setVariable)(xe.borderRadiusLeft,"0")};
959
- ${(0,ri.setVariable)(xe.borderRadiusRight,"0")};
960
- ${(0,ri.setVariable)(xe.borderWidthLeft,"0")};
968
+ ${(0,oi.setVariable)(be.borderRadiusLeft,"0")};
969
+ ${(0,oi.setVariable)(be.borderRadiusRight,"0")};
970
+ ${(0,oi.setVariable)(be.borderWidthLeft,"0")};
961
971
  }
962
972
 
963
973
  .ft-switch slot::slotted(ft-switch-option:first-child) {
964
- ${(0,ri.setVariable)(xe.borderRadiusLeft,se.borderRadius)};
965
- ${(0,ri.setVariable)(xe.borderWidthLeft,"1px")};
974
+ ${(0,oi.setVariable)(be.borderRadiusLeft,se.borderRadius)};
975
+ ${(0,oi.setVariable)(be.borderWidthLeft,"1px")};
966
976
  }
967
977
 
968
978
  .ft-switch slot::slotted(ft-switch-option:last-child) {
969
- ${(0,ri.setVariable)(xe.borderRadiusRight,se.borderRadius)};
979
+ ${(0,oi.setVariable)(be.borderRadiusRight,se.borderRadius)};
970
980
  }
971
981
 
972
982
  .ft-switch--dense slot::slotted(ft-switch-option) {
973
983
  --switch-internal-vertical-padding: 2px;
974
984
  --switch-internal-horizontal-padding: 4px;
975
985
  }
976
- `;Zi([(0,zt.property)({type:Boolean})],Be.prototype,"dense",void 0);Zi([(0,zt.property)({type:Boolean})],Be.prototype,"unselectable",void 0);Zi([(0,zt.property)()],Be.prototype,"label",void 0);Zi([(0,zt.query)(".ft-switch slot")],Be.prototype,"slottedContent",void 0);Zi([(0,zt.state)()],Be.prototype,"selectedOption",void 0);Zi([(0,zt.state)()],Be.prototype,"displayFocusWhenUsingKeyboard",void 0);Zi([(0,zt.query)(".ft-switch")],Be.prototype,"ftSwitchDiv",void 0);var Kp=c(h());var Wp={"ft-switch":Be,"ft-switch-option":de};(0,Kp.customElements)(Wp);var ni=c(h()),Gp=c(x());function ys(t){return Gp.css`
986
+ `;er([(0,zt.property)({type:Boolean})],Be.prototype,"dense",void 0);er([(0,zt.property)({type:Boolean})],Be.prototype,"unselectable",void 0);er([(0,zt.property)()],Be.prototype,"label",void 0);er([(0,zt.query)(".ft-switch slot")],Be.prototype,"slottedContent",void 0);er([(0,zt.state)()],Be.prototype,"selectedOption",void 0);er([(0,zt.state)()],Be.prototype,"displayFocusWhenUsingKeyboard",void 0);er([(0,zt.query)(".ft-switch")],Be.prototype,"ftSwitchDiv",void 0);var Kp=c(h());var Wp={"ft-switch":Be,"ft-switch-option":de};(0,Kp.customElements)(Wp);var si=c(h()),Gp=c(S());function ys(t){return Gp.css`
977
987
  [part="container"] {
978
988
  box-sizing: border-box;
979
989
  display: flex;
@@ -986,7 +996,7 @@
986
996
  flex-direction: row;
987
997
  align-items: center;
988
998
  margin-left: -6px;
989
- ${(0,ni.setVariable)(B.backgroundColor,t.starsBackgroundColor)}
999
+ ${(0,si.setVariable)(B.backgroundColor,t.starsBackgroundColor)}
990
1000
  }
991
1001
 
992
1002
  [part="rating-container"],
@@ -1000,14 +1010,14 @@
1000
1010
  }
1001
1011
 
1002
1012
  [part="rating-container"] {
1003
- ${(0,ni.setVariable)(B.color,t.emptyRatingColor)};
1004
- ${(0,ni.setVariable)(B.rippleColor,t.filledRatingColor)};
1005
- ${(0,ni.setVariable)(se.textColor,t.emptyRatingColor)};
1006
- ${(0,ni.setVariable)(se.selectedTextColor,t.filledRatingColor)};
1013
+ ${(0,si.setVariable)(B.color,t.emptyRatingColor)};
1014
+ ${(0,si.setVariable)(B.rippleColor,t.filledRatingColor)};
1015
+ ${(0,si.setVariable)(se.textColor,t.emptyRatingColor)};
1016
+ ${(0,si.setVariable)(se.selectedTextColor,t.filledRatingColor)};
1007
1017
  }
1008
1018
 
1009
1019
  [part="rating-container"] .rating-stars--active {
1010
- ${(0,ni.setVariable)(B.color,t.filledRatingColor)};
1020
+ ${(0,si.setVariable)(B.color,t.filledRatingColor)};
1011
1021
  }
1012
1022
 
1013
1023
  [part="feedback-container"] {
@@ -1025,14 +1035,14 @@
1025
1035
 
1026
1036
  [part="send-feedback"],
1027
1037
  [part="send-feedback-link"] {
1028
- ${(0,ni.setVariable)(B.color,t.sendFeedbackColor)};
1029
- ${(0,ni.setVariable)(B.backgroundColor,t.sendFeedbackBackgroundColor)};
1038
+ ${(0,si.setVariable)(B.color,t.sendFeedbackColor)};
1039
+ ${(0,si.setVariable)(B.backgroundColor,t.sendFeedbackBackgroundColor)};
1030
1040
  }
1031
1041
 
1032
1042
  [part="buttons-container"] {
1033
1043
  align-self: flex-end;
1034
1044
  }
1035
- `}var ke=c(h());var vs={feedbackInputMinWidth:ke.FtCssVariableFactory.create("--ft-viewer-feedback-input-min-width","","SIZE","300px"),ratedDateColor:ke.FtCssVariableFactory.external(ke.designSystemVariables.colorOnSurfaceMedium,"Design system"),sendFeedbackColor:ke.FtCssVariableFactory.extend("--ft-viewer-feedback-send-feedback-color","",ke.designSystemVariables.colorOnPrimary),sendFeedbackBackgroundColor:ke.FtCssVariableFactory.extend("--ft-viewer-feedback-send-feedback-background-color","",ke.designSystemVariables.colorPrimary),filledRatingColor:ke.FtCssVariableFactory.extend("--ft-viewer-feedback-filled-rating-color","",ke.designSystemVariables.colorPrimary),emptyRatingColor:ke.FtCssVariableFactory.extend("--ft-viewer-feedback-empty-rating-color","",ke.designSystemVariables.colorOnSurfaceMedium),mainTitleFontSize:ke.FtCssVariableFactory.external(ci.fontSize,"Typography"),sectionTitleFontSize:ke.FtCssVariableFactory.external(di.fontSize,"Typography"),starsBackgroundColor:ke.FtCssVariableFactory.create("--ft-viewer-feedback-stars-background-color","","COLOR",ke.designSystemVariables.colorSurface)};var ue=c(x()),pe=c(U()),$r=c(h());var Zp=c(x()),j=c(h());var qp=c(x()),Z=c(h());var A={fontSize:Z.FtCssVariableFactory.create("--ft-input-label-font-size","","SIZE","14px"),raisedFontSize:Z.FtCssVariableFactory.create("--ft-input-label-raised-font-size","","SIZE","11px"),raisedZIndex:Z.FtCssVariableFactory.create("--ft-input-label-outlined-raised-z-index","","NUMBER","2"),verticalSpacing:Z.FtCssVariableFactory.create("--ft-input-label-vertical-spacing","","SIZE","4px"),horizontalSpacing:Z.FtCssVariableFactory.create("--ft-input-label-horizontal-spacing","","SIZE","12px"),labelMaxWidth:Z.FtCssVariableFactory.create("--ft-input-label-max-width","","SIZE","100%"),borderColor:Z.FtCssVariableFactory.extend("--ft-input-label-border-color","",Z.designSystemVariables.colorOutline),textColor:Z.FtCssVariableFactory.extend("--ft-input-label-text-color","",Z.designSystemVariables.colorOnSurfaceMedium),disabledTextColor:Z.FtCssVariableFactory.extend("--ft-input-label-disabled-text-color","",Z.designSystemVariables.colorOnSurfaceDisabled),backgroundColor:Z.FtCssVariableFactory.extend("--ft-input-label-background-color","",Z.designSystemVariables.colorSurface),borderRadius:Z.FtCssVariableFactory.extend("--ft-input-label-border-radius","",Z.designSystemVariables.borderRadiusS),colorError:Z.FtCssVariableFactory.external(Z.designSystemVariables.colorError,"Design system")},Yp=qp.css`
1045
+ `}var ke=c(h());var vs={feedbackInputMinWidth:ke.FtCssVariableFactory.create("--ft-viewer-feedback-input-min-width","","SIZE","300px"),ratedDateColor:ke.FtCssVariableFactory.external(ke.designSystemVariables.colorOnSurfaceMedium,"Design system"),sendFeedbackColor:ke.FtCssVariableFactory.extend("--ft-viewer-feedback-send-feedback-color","",ke.designSystemVariables.colorOnPrimary),sendFeedbackBackgroundColor:ke.FtCssVariableFactory.extend("--ft-viewer-feedback-send-feedback-background-color","",ke.designSystemVariables.colorPrimary),filledRatingColor:ke.FtCssVariableFactory.extend("--ft-viewer-feedback-filled-rating-color","",ke.designSystemVariables.colorPrimary),emptyRatingColor:ke.FtCssVariableFactory.extend("--ft-viewer-feedback-empty-rating-color","",ke.designSystemVariables.colorOnSurfaceMedium),mainTitleFontSize:ke.FtCssVariableFactory.external(Xt.fontSize,"Typography"),sectionTitleFontSize:ke.FtCssVariableFactory.external(Jt.fontSize,"Typography"),starsBackgroundColor:ke.FtCssVariableFactory.create("--ft-viewer-feedback-stars-background-color","","COLOR",ke.designSystemVariables.colorSurface)};var ue=c(S()),pe=c(U()),$r=c(h());var Zp=c(S()),j=c(h());var qp=c(S()),Z=c(h());var A={fontSize:Z.FtCssVariableFactory.create("--ft-input-label-font-size","","SIZE","14px"),raisedFontSize:Z.FtCssVariableFactory.create("--ft-input-label-raised-font-size","","SIZE","11px"),raisedZIndex:Z.FtCssVariableFactory.create("--ft-input-label-outlined-raised-z-index","","NUMBER","2"),verticalSpacing:Z.FtCssVariableFactory.create("--ft-input-label-vertical-spacing","","SIZE","4px"),horizontalSpacing:Z.FtCssVariableFactory.create("--ft-input-label-horizontal-spacing","","SIZE","12px"),labelMaxWidth:Z.FtCssVariableFactory.create("--ft-input-label-max-width","","SIZE","100%"),borderColor:Z.FtCssVariableFactory.extend("--ft-input-label-border-color","",Z.designSystemVariables.colorOutline),textColor:Z.FtCssVariableFactory.extend("--ft-input-label-text-color","",Z.designSystemVariables.colorOnSurfaceMedium),disabledTextColor:Z.FtCssVariableFactory.extend("--ft-input-label-disabled-text-color","",Z.designSystemVariables.colorOnSurfaceDisabled),backgroundColor:Z.FtCssVariableFactory.extend("--ft-input-label-background-color","",Z.designSystemVariables.colorSurface),borderRadius:Z.FtCssVariableFactory.extend("--ft-input-label-border-radius","",Z.designSystemVariables.borderRadiusS),colorError:Z.FtCssVariableFactory.external(Z.designSystemVariables.colorError,"Design system")},Yp=qp.css`
1036
1046
  .ft-input-label {
1037
1047
  position: absolute;
1038
1048
  inset: 0;
@@ -1083,8 +1093,8 @@
1083
1093
  transition: font-size 250ms, line-height 250ms, color 250ms;
1084
1094
  max-width: calc(${A.labelMaxWidth} - 2 * (${A.horizontalSpacing} - 4px)); /* -2px on spacing for label padding */
1085
1095
  text-overflow: ellipsis;
1086
- ${(0,Z.setVariable)(tt.fontSize,A.fontSize)};
1087
- ${(0,Z.setVariable)(tt.lineHeight,A.fontSize)};
1096
+ ${(0,Z.setVariable)(Ke.fontSize,A.fontSize)};
1097
+ ${(0,Z.setVariable)(Ke.lineHeight,A.fontSize)};
1088
1098
  }
1089
1099
 
1090
1100
  .ft-input-label--in-error .ft-input-label--text {
@@ -1104,7 +1114,7 @@
1104
1114
 
1105
1115
  .ft-input-label--floating-text {
1106
1116
  position: absolute;
1107
- top: calc(50% - ${tt.lineHeight} / 2);
1117
+ top: calc(50% - ${Ke.lineHeight} / 2);
1108
1118
  transition: top 250ms;
1109
1119
  overflow: hidden;
1110
1120
  white-space: nowrap;
@@ -1116,8 +1126,8 @@
1116
1126
  }
1117
1127
 
1118
1128
  .ft-input-label--raised .ft-input-label--text {
1119
- ${(0,Z.setVariable)(tt.fontSize,A.raisedFontSize)};
1120
- ${(0,Z.setVariable)(tt.lineHeight,A.raisedFontSize)};
1129
+ ${(0,Z.setVariable)(Ke.fontSize,A.raisedFontSize)};
1130
+ ${(0,Z.setVariable)(Ke.lineHeight,A.raisedFontSize)};
1121
1131
  }
1122
1132
 
1123
1133
  .ft-input-label--raised .ft-input-label--floating-text {
@@ -1148,7 +1158,7 @@
1148
1158
  z-index: ${A.raisedZIndex};
1149
1159
  background-color: ${A.backgroundColor};
1150
1160
  border-radius: ${A.borderRadius};
1151
- top: calc((${tt.lineHeight} / -2) + 2px);
1161
+ top: calc((${Ke.lineHeight} / -2) + 2px);
1152
1162
  }
1153
1163
 
1154
1164
  .ft-input-label--outlined.ft-input-label--raised .ft-input-label--text {
@@ -1200,8 +1210,8 @@
1200
1210
  align-self: stretch;
1201
1211
  resize: none;
1202
1212
 
1203
- ${(0,j.setVariable)(dt.fontSize,K.fontSize)};
1204
- ${(0,j.setVariable)(dt.lineHeight,K.fontSize)};
1213
+ ${(0,j.setVariable)(it.fontSize,K.fontSize)};
1214
+ ${(0,j.setVariable)(it.lineHeight,K.fontSize)};
1205
1215
  color: ${K.colorOnSurface};
1206
1216
 
1207
1217
  padding: 0 ${K.horizontalSpacing};
@@ -1254,7 +1264,7 @@
1254
1264
  position: absolute;
1255
1265
  bottom: 0;
1256
1266
  }
1257
- `;var Es=c(x()),It=c(U()),df=c(rt()),Wt=c(h());var xs=c(x()),nt=c(U()),Ss=c(h());var Qp=c(x()),Nr=c(h()),Jp={colorOutline:Nr.FtCssVariableFactory.external(Nr.designSystemVariables.colorOutline,"Design system"),colorOnSurfaceMedium:Nr.FtCssVariableFactory.external(Nr.designSystemVariables.colorOnSurfaceMedium,"Design system")},ef=Qp.css`
1267
+ `;var Es=c(S()),It=c(U()),df=c(ot()),Wt=c(h());var bs=c(S()),st=c(U()),Ss=c(h());var Qp=c(S()),Nr=c(h()),Jp={colorOutline:Nr.FtCssVariableFactory.external(Nr.designSystemVariables.colorOutline,"Design system"),colorOnSurfaceMedium:Nr.FtCssVariableFactory.external(Nr.designSystemVariables.colorOnSurfaceMedium,"Design system")},ef=Qp.css`
1258
1268
  :host {
1259
1269
  display: block;
1260
1270
  }
@@ -1273,10 +1283,10 @@
1273
1283
  [role="button"][aria-pressed="true"] ft-icon{
1274
1284
  color: ${Jp.colorOnSurfaceMedium};
1275
1285
  }
1276
- `;var jt=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},bs=class extends CustomEvent{constructor(e,i){super("resize",{detail:{width:e,height:i}})}},Ce=class extends Ss.FtLitElement{constructor(){super(...arguments),this.initialWidth=0,this.initialHeight=0,this.icon="drag_handle",this.iconVariant=Ie.material,this.cursor="nwse-resize",this.ariaLabel="",this.dragging=!1,this.isAriaPressed=!1,this.fixedWidth=0,this.fixedHeight=0,this.startX=0,this.startY=0,this.doDragFromMouse=e=>this.doDrag(e.clientX,e.clientY),this.doDragFromTouch=e=>this.doDrag(e.touches[0].clientX,e.touches[0].clientY),this.stopDrag=()=>{this.dragging=!1,document.removeEventListener("mousemove",this.doDragFromMouse,!1),document.removeEventListener("mouseup",this.stopDrag,!1),document.removeEventListener("touchmove",this.doDragFromTouch,!1),document.removeEventListener("touchend",this.stopDrag,!1),document.removeEventListener("touchcancel",this.stopDrag,!1)}}render(){return xs.html`
1286
+ `;var jt=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},xs=class extends CustomEvent{constructor(e,i){super("resize",{detail:{width:e,height:i}})}},Ce=class extends Ss.FtLitElement{constructor(){super(...arguments),this.initialWidth=0,this.initialHeight=0,this.icon="drag_handle",this.iconVariant=Me.material,this.cursor="nwse-resize",this.ariaLabel="",this.dragging=!1,this.isAriaPressed=!1,this.fixedWidth=0,this.fixedHeight=0,this.startX=0,this.startY=0,this.doDragFromMouse=e=>this.doDrag(e.clientX,e.clientY),this.doDragFromTouch=e=>this.doDrag(e.touches[0].clientX,e.touches[0].clientY),this.stopDrag=()=>{this.dragging=!1,document.removeEventListener("mousemove",this.doDragFromMouse,!1),document.removeEventListener("mouseup",this.stopDrag,!1),document.removeEventListener("touchmove",this.doDragFromTouch,!1),document.removeEventListener("touchend",this.stopDrag,!1),document.removeEventListener("touchcancel",this.stopDrag,!1)}}render(){return bs.html`
1277
1287
  <style>
1278
1288
  .ft-resizer {
1279
- cursor: ${(0,xs.unsafeCSS)(this.cursor)}
1289
+ cursor: ${(0,bs.unsafeCSS)(this.cursor)}
1280
1290
  }
1281
1291
  </style>
1282
1292
  <div class="ft-resizer ft-no-text-select ${this.dragging?"ft-resizer--dragging":""}"
@@ -1288,7 +1298,7 @@
1288
1298
  @keydown=${this.initKeydownPress}>
1289
1299
  <ft-icon .variant=${this.iconVariant} .value=${this.icon} focusable="false" aria-hidden="true"></ft-icon>
1290
1300
  </div>
1291
- `}initDragFromMouse(e){e.detail>0&&this.initDrag(e.clientX,e.clientY)}initDragFromTouch(e){e.preventDefault(),e.stopPropagation(),this.initDrag(e.touches[0].clientX,e.touches[0].clientY)}initKeydownPress(e){let i=e.key;["Enter"," ","Escape","ArrowLeft","ArrowRight","ArrowUp","ArrowDown"].includes(i)&&(e.preventDefault(),e.stopPropagation()),this.fixedWidth=this.initialWidth,this.fixedHeight=this.initialHeight;let n=e.currentTarget;i==="Enter"||i===" "?(this.isAriaPressed=!this.isAriaPressed,n.setAttribute("aria-pressed",this.isAriaPressed.toString())):i==="Escape"&&(this.isAriaPressed=!1,n.setAttribute("aria-pressed",this.isAriaPressed.toString())),this.isAriaPressed&&(i==="ArrowLeft"?this.fixedWidth-=10:i==="ArrowRight"?this.fixedWidth+=10:i==="ArrowUp"?this.fixedHeight-=10:i==="ArrowDown"&&(this.fixedHeight+=10),["ArrowLeft","ArrowRight","ArrowUp","ArrowDown"].includes(i)&&this.dispatchEvent(new bs(this.fixedWidth,this.fixedHeight)))}initDrag(e,i){this.dragging=!0,this.startX=e,this.startY=i,this.fixedWidth=this.initialWidth,this.fixedHeight=this.initialHeight,this.installDocumentEventListeners()}installDocumentEventListeners(){document.addEventListener("mousemove",this.doDragFromMouse,!1),document.addEventListener("mouseup",this.stopDrag,!1),document.addEventListener("touchmove",this.doDragFromTouch,!1),document.addEventListener("touchend",this.stopDrag,!1),document.addEventListener("touchcancel",this.stopDrag,!1)}doDrag(e,i){let r=this.fixedWidth+e-this.startX,n=this.fixedHeight+i-this.startY;this.dispatchEvent(new bs(r,n))}};Ce.elementDefinitions={"ft-icon":z};Ce.styles=[Ss.noTextSelect,ef];jt([(0,nt.property)({type:Number})],Ce.prototype,"initialWidth",void 0);jt([(0,nt.property)({type:Number})],Ce.prototype,"initialHeight",void 0);jt([(0,nt.property)()],Ce.prototype,"icon",void 0);jt([(0,nt.property)()],Ce.prototype,"iconVariant",void 0);jt([(0,nt.property)()],Ce.prototype,"cursor",void 0);jt([(0,nt.property)()],Ce.prototype,"ariaLabel",void 0);jt([(0,nt.state)()],Ce.prototype,"dragging",void 0);jt([(0,nt.state)()],Ce.prototype,"isAriaPressed",void 0);jt([(0,nt.eventOptions)({passive:!0})],Ce.prototype,"initDragFromMouse",null);jt([(0,nt.eventOptions)({passive:!0})],Ce.prototype,"initDragFromTouch",null);var rf=c(h());var tf={"ft-resizer":Ce};(0,rf.customElements)(tf);var ws=c(U());var il=c(x()),rl=c(U());function nf(t,e,i){return t?e(t):i?.(t)}var sf=c(rt()),af=c(h()),of=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Xi=class extends af.FtLitElement{constructor(){super(...arguments),this.text="",this.raised=!1}get inputLabelClasses(){return{}}render(){return il.html`
1301
+ `}initDragFromMouse(e){e.detail>0&&this.initDrag(e.clientX,e.clientY)}initDragFromTouch(e){e.preventDefault(),e.stopPropagation(),this.initDrag(e.touches[0].clientX,e.touches[0].clientY)}initKeydownPress(e){let i=e.key;["Enter"," ","Escape","ArrowLeft","ArrowRight","ArrowUp","ArrowDown"].includes(i)&&(e.preventDefault(),e.stopPropagation()),this.fixedWidth=this.initialWidth,this.fixedHeight=this.initialHeight;let n=e.currentTarget;i==="Enter"||i===" "?(this.isAriaPressed=!this.isAriaPressed,n.setAttribute("aria-pressed",this.isAriaPressed.toString())):i==="Escape"&&(this.isAriaPressed=!1,n.setAttribute("aria-pressed",this.isAriaPressed.toString())),this.isAriaPressed&&(i==="ArrowLeft"?this.fixedWidth-=10:i==="ArrowRight"?this.fixedWidth+=10:i==="ArrowUp"?this.fixedHeight-=10:i==="ArrowDown"&&(this.fixedHeight+=10),["ArrowLeft","ArrowRight","ArrowUp","ArrowDown"].includes(i)&&this.dispatchEvent(new xs(this.fixedWidth,this.fixedHeight)))}initDrag(e,i){this.dragging=!0,this.startX=e,this.startY=i,this.fixedWidth=this.initialWidth,this.fixedHeight=this.initialHeight,this.installDocumentEventListeners()}installDocumentEventListeners(){document.addEventListener("mousemove",this.doDragFromMouse,!1),document.addEventListener("mouseup",this.stopDrag,!1),document.addEventListener("touchmove",this.doDragFromTouch,!1),document.addEventListener("touchend",this.stopDrag,!1),document.addEventListener("touchcancel",this.stopDrag,!1)}doDrag(e,i){let r=this.fixedWidth+e-this.startX,n=this.fixedHeight+i-this.startY;this.dispatchEvent(new xs(r,n))}};Ce.elementDefinitions={"ft-icon":z};Ce.styles=[Ss.noTextSelect,ef];jt([(0,st.property)({type:Number})],Ce.prototype,"initialWidth",void 0);jt([(0,st.property)({type:Number})],Ce.prototype,"initialHeight",void 0);jt([(0,st.property)()],Ce.prototype,"icon",void 0);jt([(0,st.property)()],Ce.prototype,"iconVariant",void 0);jt([(0,st.property)()],Ce.prototype,"cursor",void 0);jt([(0,st.property)()],Ce.prototype,"ariaLabel",void 0);jt([(0,st.state)()],Ce.prototype,"dragging",void 0);jt([(0,st.state)()],Ce.prototype,"isAriaPressed",void 0);jt([(0,st.eventOptions)({passive:!0})],Ce.prototype,"initDragFromMouse",null);jt([(0,st.eventOptions)({passive:!0})],Ce.prototype,"initDragFromTouch",null);var rf=c(h());var tf={"ft-resizer":Ce};(0,rf.customElements)(tf);var ws=c(U());var il=c(S()),rl=c(U());function nf(t,e,i){return t?e(t):i?.(t)}var sf=c(ot()),af=c(h()),of=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},tr=class extends af.FtLitElement{constructor(){super(...arguments),this.text="",this.raised=!1}get inputLabelClasses(){return{}}render(){return il.html`
1292
1302
  <div class="${(0,sf.classMap)(this.inputLabelClasses)}">
1293
1303
  ${nf(this.text,()=>il.html`
1294
1304
  <div class="ft-input-label--text ft-typography--caption">
@@ -1297,7 +1307,7 @@
1297
1307
  </div>
1298
1308
  `)}
1299
1309
  </div>
1300
- `}};Xi.elementDefinitions={};of([(0,rl.property)({type:String})],Xi.prototype,"text",void 0);of([(0,rl.property)({type:Boolean})],Xi.prototype,"raised",void 0);var nl=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ot=class extends Xi{constructor(){super(...arguments),this.outlined=!1,this.error=!1,this.disabled=!1}get inputLabelClasses(){return{"ft-input-label":!0,"ft-input-label--raised":this.raised,"ft-input-label--outlined":this.outlined,"ft-input-label--disabled":this.disabled,"ft-input-label--in-error":this.error}}};ot.elementDefinitions={};ot.styles=[Oo,Yp];nl([(0,ws.property)({type:Boolean})],ot.prototype,"outlined",void 0);nl([(0,ws.property)({type:Boolean})],ot.prototype,"error",void 0);nl([(0,ws.property)({type:Boolean})],ot.prototype,"disabled",void 0);var cf=c(h());var lf={"ft-input-label":ot};(0,cf.customElements)(lf);var vt=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ye=class extends(0,Wt.toFtFormComponent)(Wt.FtLitElement){constructor(){super(...arguments),this.label="",this.value="",this.helper="",this.outlined=!1,this.disabled=!1,this.error=!1,this.height=50,this.focused=!1}render(){let e={"ft-text-area":!0,"ft-text-area--filled":!this.outlined,"ft-text-area--outlined":this.outlined,"ft-text-area--disabled":this.disabled,"ft-text-area--has-value":!!this.value,"ft-text-area--no-label":!this.label,"ft-text-area--in-error":this.error};return Es.html`
1310
+ `}};tr.elementDefinitions={};of([(0,rl.property)({type:String})],tr.prototype,"text",void 0);of([(0,rl.property)({type:Boolean})],tr.prototype,"raised",void 0);var nl=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},at=class extends tr{constructor(){super(...arguments),this.outlined=!1,this.error=!1,this.disabled=!1}get inputLabelClasses(){return{"ft-input-label":!0,"ft-input-label--raised":this.raised,"ft-input-label--outlined":this.outlined,"ft-input-label--disabled":this.disabled,"ft-input-label--in-error":this.error}}};at.elementDefinitions={};at.styles=[Oo,Yp];nl([(0,ws.property)({type:Boolean})],at.prototype,"outlined",void 0);nl([(0,ws.property)({type:Boolean})],at.prototype,"error",void 0);nl([(0,ws.property)({type:Boolean})],at.prototype,"disabled",void 0);var cf=c(h());var lf={"ft-input-label":at};(0,cf.customElements)(lf);var vt=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ye=class extends(0,Wt.toFtFormComponent)(Wt.FtLitElement){constructor(){super(...arguments),this.label="",this.value="",this.helper="",this.outlined=!1,this.disabled=!1,this.error=!1,this.height=50,this.focused=!1}render(){let e={"ft-text-area":!0,"ft-text-area--filled":!this.outlined,"ft-text-area--outlined":this.outlined,"ft-text-area--disabled":this.disabled,"ft-text-area--has-value":!!this.value,"ft-text-area--no-label":!this.label,"ft-text-area--in-error":this.error};return Es.html`
1301
1311
  <style>
1302
1312
  .ft-text-area--main-panel {
1303
1313
  height: calc(4 * ${K.verticalSpacing} + ${K.labelSize} + ${K.fontSize} + ${this.height}px);
@@ -1342,7 +1352,7 @@
1342
1352
  ${this.helper}
1343
1353
  </ft-typography>`:void 0}
1344
1354
  </div>
1345
- `}setValue(e,i=!1){this.value=e,this.setFormValue(e),i&&(this.dispatchEvent(new CustomEvent("live-change",{detail:this.value})),this.dispatchEvent(new CustomEvent("change",{detail:this.value})))}onKeyDown(e){(e.key==="Enter"||e.key===" ")&&e.stopPropagation()}updateValueFromInputField(){var e;this.value=((e=this.textarea)===null||e===void 0?void 0:e.value)||"",this.setFormValue(this.value),this.dispatchEvent(new CustomEvent("change",{detail:this.value}))}liveUpdateValueFromInputField(){var e;this.value=((e=this.textarea)===null||e===void 0?void 0:e.value)||"",this.setFormValue(this.value),this.dispatchEvent(new CustomEvent("live-change",{detail:this.value}))}onResize(e){e.detail.height>=50&&(!this.maxHeight||this.maxHeight>0&&e.detail.height<this.maxHeight)&&(this.height=e.detail.height)}};ye.elementDefinitions={"ft-input-label":ot,"ft-resizer":Ce,"ft-ripple":M,"ft-typography":F};ye.styles=[ui,Xp];vt([(0,It.property)({type:String})],ye.prototype,"label",void 0);vt([(0,It.property)({reflect:!0})],ye.prototype,"value",void 0);vt([(0,It.property)({type:String})],ye.prototype,"helper",void 0);vt([(0,It.property)({type:Boolean})],ye.prototype,"outlined",void 0);vt([(0,It.property)({type:Boolean})],ye.prototype,"disabled",void 0);vt([(0,It.property)({type:Boolean})],ye.prototype,"error",void 0);vt([(0,Wt.numberProperty)({reflect:!0})],ye.prototype,"height",void 0);vt([(0,Wt.numberProperty)()],ye.prototype,"maxHeight",void 0);vt([(0,It.query)("textarea")],ye.prototype,"textarea",void 0);vt([(0,It.state)()],ye.prototype,"focused",void 0);vt([(0,Wt.ignoreComposingEvents)()],ye.prototype,"onKeyDown",null);vt([(0,Wt.ignoreComposingEvents)()],ye.prototype,"liveUpdateValueFromInputField",null);var pf=c(h());var uf={"ft-text-area":ye};(0,pf.customElements)(uf);var _f=c(fr());var J=ft.build("integratedFeedbackComponent"),ff={starsRating:"{0} stars","starsRating[\\=1]":"1 star",like:"Like",dislike:"Dislike",dichotomousYes:"Yes",dichotomousNo:"No",notRated:"Not rated",ratedNow:"Rated now",ratedToday:"Rated today",ratedOn:"Rated on {0, date}",feedbackInputLabel:"How can we improve it?",feedbackfromEmail:"Your email",feedbackfromEmailInvalid:"Please enter a valid email address",okButton:"Send feedback",cancelButton:"Cancel",moreOptionsButton:"More options",feedbackSuccess:"Feedback successfully sent. Thank you!",feedbackFailure:"Failed to send feedback. Please try again later.",ratingSuccess:"Rating successfully sent. Thank you!",ratingFailure:"Failed to send rating. Please try again later.",mapFeedbackMainTitle:"Send feedback",mapRatingSectionTitle:"Rate this document",mapDichotomousRatingSectionTitle:"Did it solve your problem?",mapFeedbackSectionTitle:"Write your review",topicFeedbackMainTitle:"Send feedback",topicRatingSectionTitle:"Rate this content",topicDichotomousRatingSectionTitle:"Did this content solve your problem?",topicFeedbackSectionTitle:"Write your review",viewerFeedbackMainTitle:"Send feedback",viewerRatingSectionTitle:"Rate this content",viewerDichotomousRatingSectionTitle:"Did this content solve your problem?",viewerFeedbackSectionTitle:"Write your review"};var _s=class extends CustomEvent{constructor(e){super("live-change",{detail:e})}},As=class extends CustomEvent{constructor(e){super("change",{detail:e})}},Cs=class extends CustomEvent{constructor(e){super("invalid",{detail:e})}};var hf=c(x()),C=c(h());var D={fontSize:C.FtCssVariableFactory.create("--ft-text-field-font-size","","SIZE","14px"),labelSize:C.FtCssVariableFactory.create("--ft-text-field-label-size","","SIZE","11px"),verticalSpacing:C.FtCssVariableFactory.create("--ft-text-field-vertical-spacing","","SIZE","4px"),horizontalSpacing:C.FtCssVariableFactory.create("--ft-text-field-horizontal-spacing","","SIZE","16px"),helperColor:C.FtCssVariableFactory.extend("--ft-text-field-helper-color","",C.designSystemVariables.colorOnSurfaceMedium),colorPrimary:C.FtCssVariableFactory.external(C.designSystemVariables.colorPrimary,"Design system"),colorOnSurface:C.FtCssVariableFactory.external(C.designSystemVariables.colorOnSurface,"Design system"),colorOnSurfaceDisabled:C.FtCssVariableFactory.external(C.designSystemVariables.colorOnSurfaceDisabled,"Design system"),borderRadiusS:C.FtCssVariableFactory.external(C.designSystemVariables.borderRadiusS,"Design system"),colorError:C.FtCssVariableFactory.external(C.designSystemVariables.colorError,"Design system"),prefixColor:C.FtCssVariableFactory.extend("--ft-text-field-prefix-color","",C.designSystemVariables.colorOnSurfaceMedium),iconColor:C.FtCssVariableFactory.extend("--ft-text-field-icon-color","",C.designSystemVariables.colorOnSurfaceMedium),floatingZIndex:C.FtCssVariableFactory.create("--ft-text-field-floating-components-z-index","","NUMBER","3"),backgroundColor:C.FtCssVariableFactory.extend("--ft-text-field-background-color","",C.designSystemVariables.colorSurface),colorOutline:C.FtCssVariableFactory.external(C.designSystemVariables.colorOutline,"Design system"),elevation02:C.FtCssVariableFactory.external(C.designSystemVariables.elevation02,"Design system"),suggestSize:C.FtCssVariableFactory.create("--ft-text-field-suggest-size","","SIZE","300px")},mf=hf.css`
1355
+ `}setValue(e,i=!1){this.value=e,this.setFormValue(e),i&&(this.dispatchEvent(new CustomEvent("live-change",{detail:this.value})),this.dispatchEvent(new CustomEvent("change",{detail:this.value})))}onKeyDown(e){(e.key==="Enter"||e.key===" ")&&e.stopPropagation()}updateValueFromInputField(){var e;this.value=((e=this.textarea)===null||e===void 0?void 0:e.value)||"",this.setFormValue(this.value),this.dispatchEvent(new CustomEvent("change",{detail:this.value}))}liveUpdateValueFromInputField(){var e;this.value=((e=this.textarea)===null||e===void 0?void 0:e.value)||"",this.setFormValue(this.value),this.dispatchEvent(new CustomEvent("live-change",{detail:this.value}))}onResize(e){e.detail.height>=50&&(!this.maxHeight||this.maxHeight>0&&e.detail.height<this.maxHeight)&&(this.height=e.detail.height)}};ye.elementDefinitions={"ft-input-label":at,"ft-resizer":Ce,"ft-ripple":M,"ft-typography":F};ye.styles=[ui,Xp];vt([(0,It.property)({type:String})],ye.prototype,"label",void 0);vt([(0,It.property)({reflect:!0})],ye.prototype,"value",void 0);vt([(0,It.property)({type:String})],ye.prototype,"helper",void 0);vt([(0,It.property)({type:Boolean})],ye.prototype,"outlined",void 0);vt([(0,It.property)({type:Boolean})],ye.prototype,"disabled",void 0);vt([(0,It.property)({type:Boolean})],ye.prototype,"error",void 0);vt([(0,Wt.numberProperty)({reflect:!0})],ye.prototype,"height",void 0);vt([(0,Wt.numberProperty)()],ye.prototype,"maxHeight",void 0);vt([(0,It.query)("textarea")],ye.prototype,"textarea",void 0);vt([(0,It.state)()],ye.prototype,"focused",void 0);vt([(0,Wt.ignoreComposingEvents)()],ye.prototype,"onKeyDown",null);vt([(0,Wt.ignoreComposingEvents)()],ye.prototype,"liveUpdateValueFromInputField",null);var pf=c(h());var uf={"ft-text-area":ye};(0,pf.customElements)(uf);var _f=c(yr());var J=ft.build("integratedFeedbackComponent"),ff={starsRating:"{0} stars","starsRating[\\=1]":"1 star",like:"Like",dislike:"Dislike",dichotomousYes:"Yes",dichotomousNo:"No",notRated:"Not rated",ratedNow:"Rated now",ratedToday:"Rated today",ratedOn:"Rated on {0, date}",feedbackInputLabel:"How can we improve it?",feedbackfromEmail:"Your email",feedbackfromEmailInvalid:"Please enter a valid email address",okButton:"Send feedback",cancelButton:"Cancel",moreOptionsButton:"More options",feedbackSuccess:"Feedback successfully sent. Thank you!",feedbackFailure:"Failed to send feedback. Please try again later.",ratingSuccess:"Rating successfully sent. Thank you!",ratingFailure:"Failed to send rating. Please try again later.",mapFeedbackMainTitle:"Send feedback",mapRatingSectionTitle:"Rate this document",mapDichotomousRatingSectionTitle:"Did it solve your problem?",mapFeedbackSectionTitle:"Write your review",topicFeedbackMainTitle:"Send feedback",topicRatingSectionTitle:"Rate this content",topicDichotomousRatingSectionTitle:"Did this content solve your problem?",topicFeedbackSectionTitle:"Write your review",viewerFeedbackMainTitle:"Send feedback",viewerRatingSectionTitle:"Rate this content",viewerDichotomousRatingSectionTitle:"Did this content solve your problem?",viewerFeedbackSectionTitle:"Write your review"};var _s=class extends CustomEvent{constructor(e){super("live-change",{detail:e})}},As=class extends CustomEvent{constructor(e){super("change",{detail:e})}},Cs=class extends CustomEvent{constructor(e){super("invalid",{detail:e})}};var hf=c(S()),C=c(h());var L={fontSize:C.FtCssVariableFactory.create("--ft-text-field-font-size","","SIZE","14px"),labelSize:C.FtCssVariableFactory.create("--ft-text-field-label-size","","SIZE","11px"),verticalSpacing:C.FtCssVariableFactory.create("--ft-text-field-vertical-spacing","","SIZE","4px"),horizontalSpacing:C.FtCssVariableFactory.create("--ft-text-field-horizontal-spacing","","SIZE","16px"),helperColor:C.FtCssVariableFactory.extend("--ft-text-field-helper-color","",C.designSystemVariables.colorOnSurfaceMedium),colorPrimary:C.FtCssVariableFactory.external(C.designSystemVariables.colorPrimary,"Design system"),colorOnSurface:C.FtCssVariableFactory.external(C.designSystemVariables.colorOnSurface,"Design system"),colorOnSurfaceDisabled:C.FtCssVariableFactory.external(C.designSystemVariables.colorOnSurfaceDisabled,"Design system"),borderRadiusS:C.FtCssVariableFactory.external(C.designSystemVariables.borderRadiusS,"Design system"),colorError:C.FtCssVariableFactory.external(C.designSystemVariables.colorError,"Design system"),prefixColor:C.FtCssVariableFactory.extend("--ft-text-field-prefix-color","",C.designSystemVariables.colorOnSurfaceMedium),iconColor:C.FtCssVariableFactory.extend("--ft-text-field-icon-color","",C.designSystemVariables.colorOnSurfaceMedium),floatingZIndex:C.FtCssVariableFactory.create("--ft-text-field-floating-components-z-index","","NUMBER","3"),backgroundColor:C.FtCssVariableFactory.extend("--ft-text-field-background-color","",C.designSystemVariables.colorSurface),colorOutline:C.FtCssVariableFactory.external(C.designSystemVariables.colorOutline,"Design system"),elevation02:C.FtCssVariableFactory.external(C.designSystemVariables.elevation02,"Design system"),suggestSize:C.FtCssVariableFactory.create("--ft-text-field-suggest-size","","SIZE","300px")},mf=hf.css`
1346
1356
  *:focus {
1347
1357
  outline: none;
1348
1358
  }
@@ -1352,21 +1362,21 @@
1352
1362
  flex-direction: column;
1353
1363
  align-items: stretch;
1354
1364
  position: relative;
1355
- --text-field-internal-suggest-size: ${D.suggestSize};
1365
+ --text-field-internal-suggest-size: ${L.suggestSize};
1356
1366
  }
1357
1367
 
1358
1368
  ft-input-label {
1359
- ${(0,C.setVariable)(A.fontSize,D.fontSize)};
1360
- ${(0,C.setVariable)(A.raisedFontSize,D.labelSize)};
1361
- ${(0,C.setVariable)(A.verticalSpacing,D.verticalSpacing)};
1362
- ${(0,C.setVariable)(A.horizontalSpacing,D.horizontalSpacing)};
1363
- ${(0,C.setVariable)(A.backgroundColor,D.backgroundColor)};
1369
+ ${(0,C.setVariable)(A.fontSize,L.fontSize)};
1370
+ ${(0,C.setVariable)(A.raisedFontSize,L.labelSize)};
1371
+ ${(0,C.setVariable)(A.verticalSpacing,L.verticalSpacing)};
1372
+ ${(0,C.setVariable)(A.horizontalSpacing,L.horizontalSpacing)};
1373
+ ${(0,C.setVariable)(A.backgroundColor,L.backgroundColor)};
1364
1374
  }
1365
1375
 
1366
1376
  .ft-text-field--main-panel {
1367
1377
  position: relative;
1368
1378
  display: flex;
1369
- height: calc(4 * ${D.verticalSpacing} + ${D.labelSize} + ${D.fontSize});
1379
+ height: calc(4 * ${L.verticalSpacing} + ${L.labelSize} + ${L.fontSize});
1370
1380
  }
1371
1381
 
1372
1382
  .ft-text-field--input-panel {
@@ -1375,10 +1385,10 @@
1375
1385
  display: flex;
1376
1386
  align-items: center;
1377
1387
  overflow: hidden;
1378
- padding: 0 ${D.horizontalSpacing};
1388
+ padding: 0 ${L.horizontalSpacing};
1379
1389
 
1380
- ${(0,C.setVariable)(dt.fontSize,D.fontSize)};
1381
- ${(0,C.setVariable)(dt.lineHeight,D.fontSize)};
1390
+ ${(0,C.setVariable)(it.fontSize,L.fontSize)};
1391
+ ${(0,C.setVariable)(it.lineHeight,L.fontSize)};
1382
1392
  }
1383
1393
 
1384
1394
  .ft-text-field--input-panel ft-ripple {
@@ -1388,11 +1398,11 @@
1388
1398
 
1389
1399
  .ft-text-field--filled.ft-text-field--with-label .ft-text-field--input-panel {
1390
1400
  align-items: flex-end;
1391
- padding: 0 ${D.horizontalSpacing} ${D.verticalSpacing} ${D.horizontalSpacing};
1401
+ padding: 0 ${L.horizontalSpacing} ${L.verticalSpacing} ${L.horizontalSpacing};
1392
1402
  }
1393
1403
 
1394
1404
  .ft-text-field--prefix {
1395
- color: ${D.prefixColor};
1405
+ color: ${L.prefixColor};
1396
1406
  margin-right: 2px;
1397
1407
  flex-shrink: 1;
1398
1408
  overflow: hidden;
@@ -1411,22 +1421,22 @@
1411
1421
  flex-shrink: 1;
1412
1422
  min-width: 0; /* flex sets this to auto an prevents input from shrinking properly */
1413
1423
 
1414
- color: ${D.colorOnSurface};
1415
- padding: calc(2 * ${D.verticalSpacing}) 0;
1424
+ color: ${L.colorOnSurface};
1425
+ padding: calc(2 * ${L.verticalSpacing}) 0;
1416
1426
  border: none;
1417
1427
  background: none;
1418
1428
 
1419
1429
  &:-webkit-autofill,
1420
1430
  &:-webkit-autofill:hover,
1421
1431
  &:-webkit-autofill:focus {
1422
- -webkit-text-fill-color: ${D.colorOnSurface};
1432
+ -webkit-text-fill-color: ${L.colorOnSurface};
1423
1433
  transition: background-color 50000000s ease-in-out 100000s;
1424
1434
  }
1425
1435
  }
1426
1436
 
1427
1437
  .ft-text-field--filled.ft-text-field--with-label .ft-text-field--input {
1428
1438
  padding-bottom: 0;
1429
- padding-top: calc(${D.labelSize} + 2 * ${D.verticalSpacing});
1439
+ padding-top: calc(${L.labelSize} + 2 * ${L.verticalSpacing});
1430
1440
  }
1431
1441
 
1432
1442
  .ft-text-field--input::-webkit-calendar-picker-indicator,
@@ -1435,37 +1445,37 @@
1435
1445
  }
1436
1446
 
1437
1447
  .ft-text-field--disabled .ft-text-field--input {
1438
- color: ${D.colorOnSurfaceDisabled};
1448
+ color: ${L.colorOnSurfaceDisabled};
1439
1449
  }
1440
1450
 
1441
1451
  .ft-text-field:not(.ft-text-field--disabled):focus-within ft-input-label {
1442
- ${(0,C.setVariable)(A.borderColor,D.colorPrimary)};
1443
- ${(0,C.setVariable)(A.textColor,D.colorPrimary)};
1452
+ ${(0,C.setVariable)(A.borderColor,L.colorPrimary)};
1453
+ ${(0,C.setVariable)(A.textColor,L.colorPrimary)};
1444
1454
  }
1445
1455
 
1446
1456
  .ft-text-field--filled .ft-text-field--input-panel {
1447
- border-radius: ${D.borderRadiusS} ${D.borderRadiusS} 0 0;
1457
+ border-radius: ${L.borderRadiusS} ${L.borderRadiusS} 0 0;
1448
1458
  }
1449
1459
 
1450
1460
  .ft-text-field--outlined .ft-text-field--input-panel {
1451
- border-radius: ${D.borderRadiusS};
1461
+ border-radius: ${L.borderRadiusS};
1452
1462
  }
1453
1463
 
1454
1464
  .ft-text-field--helper-text {
1455
- padding: 0 12px 0 ${D.horizontalSpacing};
1456
- color: ${D.helperColor};
1465
+ padding: 0 12px 0 ${L.horizontalSpacing};
1466
+ color: ${L.helperColor};
1457
1467
  }
1458
1468
 
1459
1469
  .ft-text-field--in-error .ft-text-field--input,
1460
1470
  .ft-text-field--in-error .ft-text-field--helper-text,
1461
1471
  .ft-text-field--in-error .ft-text-field--prefix {
1462
- color: ${D.colorError};
1472
+ color: ${L.colorError};
1463
1473
  }
1464
1474
 
1465
1475
  .ft-text-field--icon {
1466
1476
  align-self: center;
1467
1477
  margin-left: 8px;
1468
- color: ${D.iconColor};
1478
+ color: ${L.iconColor};
1469
1479
  }
1470
1480
 
1471
1481
  .ft-text-field--container {
@@ -1476,11 +1486,11 @@
1476
1486
  display: none;
1477
1487
  flex-direction: column;
1478
1488
  position: absolute;
1479
- z-index: ${D.floatingZIndex};
1480
- background: ${D.backgroundColor};
1481
- border: 1px solid ${D.colorOutline};
1482
- border-radius: 0 0 ${D.borderRadiusS} ${D.borderRadiusS};
1483
- box-shadow: ${D.elevation02};
1489
+ z-index: ${L.floatingZIndex};
1490
+ background: ${L.backgroundColor};
1491
+ border: 1px solid ${L.colorOutline};
1492
+ border-radius: 0 0 ${L.borderRadiusS} ${L.borderRadiusS};
1493
+ box-shadow: ${L.elevation02};
1484
1494
  outline: none;
1485
1495
  max-height: var(--text-field-internal-suggest-size);
1486
1496
  overflow-y: auto;
@@ -1501,7 +1511,7 @@
1501
1511
  .ft-text-field--with-password ft-icon:hover {
1502
1512
  cursor: pointer;
1503
1513
  }
1504
- `;var Se=c(x()),P=c(U()),xf=c(fr()),Sf=c(rt());var He=c(h());var vf=c(h()),Cn=c(x()),Ji=c(U());var gf=c(x());var yf=gf.css`
1514
+ `;var Se=c(S()),P=c(U()),bf=c(yr()),Sf=c(ot());var He=c(h());var vf=c(h()),Cn=c(S()),ir=c(U());var gf=c(S());var yf=gf.css`
1505
1515
  .ft-text-field-suggestion {
1506
1516
  position: relative;
1507
1517
  padding: 8px 16px;
@@ -1531,14 +1541,14 @@
1531
1541
  }
1532
1542
 
1533
1543
  .ft-text-field-suggestion--helper-text {
1534
- color: ${D.helperColor};
1544
+ color: ${L.helperColor};
1535
1545
  }
1536
1546
 
1537
1547
  slot {
1538
1548
  pointer-events: none;
1539
1549
  }
1540
- `;var bf=c(rt()),Ts=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ol=class extends CustomEvent{constructor(e){super("suggestion-selected",{detail:e,bubbles:!0,composed:!0})}},bt=class extends vf.FtLitElement{render(){let e={"ft-text-field-suggestion":!0,"ft-text-field-suggestion--with-helper":!!this.helper};return Cn.html`
1541
- <div class="${(0,bf.classMap)(e)}"
1550
+ `;var xf=c(ot()),Ts=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ol=class extends CustomEvent{constructor(e){super("suggestion-selected",{detail:e,bubbles:!0,composed:!0})}},xt=class extends vf.FtLitElement{render(){let e={"ft-text-field-suggestion":!0,"ft-text-field-suggestion--with-helper":!!this.helper};return Cn.html`
1551
+ <div class="${(0,xf.classMap)(e)}"
1542
1552
  tabindex="-1"
1543
1553
  @keydown=${this.onKeyDown}
1544
1554
  @click=${this.confirmSuggestion}>
@@ -1553,7 +1563,7 @@
1553
1563
  <slot></slot>
1554
1564
  </ft-typography>
1555
1565
  </div>
1556
- `}focus(e){var i;(i=this.container)===null||i===void 0||i.focus(e)}click(){var e;(e=this.container)===null||e===void 0||e.click()}confirmSuggestion(){this.dispatchEvent(new ol(this.getValue()))}getValue(){return this.value||this.getTextContent()}getTextContent(){return this.assignedNodes.map(e=>e.textContent).join("").trim()}onKeyDown(e){["Enter"," "].includes(e.key)&&(e.preventDefault(),e.stopPropagation(),this.confirmSuggestion())}};bt.elementDefinitions={"ft-ripple":M,"ft-typography":F,"ft-icon":z};bt.styles=yf;Ts([(0,Ji.property)()],bt.prototype,"value",void 0);Ts([(0,Ji.property)()],bt.prototype,"helper",void 0);Ts([(0,Ji.query)(".ft-text-field-suggestion")],bt.prototype,"container",void 0);Ts([(0,Ji.queryAssignedNodes)()],bt.prototype,"assignedNodes",void 0);var $=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},_=class extends(0,He.toFtFormComponent)(He.FtLitElement){constructor(){super(...arguments),this._value="",this.dispatchedValue="",this.outlined=!1,this.disabled=!1,this.error=!1,this.fixedMenuPosition=!1,this.prefix=null,this.passwordHiddenIcon=Fi.EYE_SLASH,this.passwordRevealedIcon=Fi.EYE,this.filterSuggestions=!1,this.password=!1,this.hideCurrentValueSuggestion=!1,this.focused=!1,this.inputValid=!0,this.hidePassword=!0,this.hideSuggestions=!1,this.visibleSuggestions=[],this.providedSuggestions=[]}get value(){return this._value||""}set value(e){this.setInternalValue(e||""),this.dispatchedValue=e||""}setInternalValue(e){let i=this._value;this._value=e||"",this.setFormValue(this._value),this.requestUpdate("value",i)}focus(){var e;(e=this.input)===null||e===void 0||e.focus()}blur(){var e;(e=this.input)===null||e===void 0||e.blur()}render(){var e;let i={"ft-text-field":!0,"ft-text-field--filled":!this.outlined,"ft-text-field--outlined":this.outlined,"ft-text-field--disabled":this.disabled,"ft-text-field--has-value":!!this.value,"ft-text-field--with-label":!!this.label,"ft-text-field--in-error":!this.inputValid||this.error,"ft-text-field--fixed":this.fixedMenuPosition,"ft-text-field--with-prefix":!!this.prefix,"ft-text-field--hide-suggestions":!this.suggestionsShouldBeDisplayed(),"ft-text-field--raised-label":this.focused||this.value!="","ft-text-field--with-icon":!!this.icon,"ft-text-field--with-password":this.isPasswordField()},r=this.suggestionsProvider&&this.value&&this.value!=""&&!this.providedSuggestions.map(a=>a.label).includes(this.value),o=!this.suggestionsProvider&&this.filterSuggestions&&this.value&&this.value!=""||r,s=this.inputValid?this.helper:(e=this.input)===null||e===void 0?void 0:e.validationMessage;return Se.html`
1566
+ `}focus(e){var i;(i=this.container)===null||i===void 0||i.focus(e)}click(){var e;(e=this.container)===null||e===void 0||e.click()}confirmSuggestion(){this.dispatchEvent(new ol(this.getValue()))}getValue(){return this.value||this.getTextContent()}getTextContent(){return this.assignedNodes.map(e=>e.textContent).join("").trim()}onKeyDown(e){["Enter"," "].includes(e.key)&&(e.preventDefault(),e.stopPropagation(),this.confirmSuggestion())}};xt.elementDefinitions={"ft-ripple":M,"ft-typography":F,"ft-icon":z};xt.styles=yf;Ts([(0,ir.property)()],xt.prototype,"value",void 0);Ts([(0,ir.property)()],xt.prototype,"helper",void 0);Ts([(0,ir.query)(".ft-text-field-suggestion")],xt.prototype,"container",void 0);Ts([(0,ir.queryAssignedNodes)()],xt.prototype,"assignedNodes",void 0);var $=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},_=class extends(0,He.toFtFormComponent)(He.FtLitElement){constructor(){super(...arguments),this._value="",this.dispatchedValue="",this.outlined=!1,this.disabled=!1,this.error=!1,this.fixedMenuPosition=!1,this.prefix=null,this.passwordHiddenIcon=zi.EYE_SLASH,this.passwordRevealedIcon=zi.EYE,this.filterSuggestions=!1,this.password=!1,this.hideCurrentValueSuggestion=!1,this.focused=!1,this.inputValid=!0,this.hidePassword=!0,this.hideSuggestions=!1,this.visibleSuggestions=[],this.providedSuggestions=[]}get value(){return this._value||""}set value(e){this.setInternalValue(e||""),this.dispatchedValue=e||""}setInternalValue(e){let i=this._value;this._value=e||"",this.setFormValue(this._value),this.requestUpdate("value",i)}focus(){var e;(e=this.input)===null||e===void 0||e.focus()}blur(){var e;(e=this.input)===null||e===void 0||e.blur()}render(){var e;let i={"ft-text-field":!0,"ft-text-field--filled":!this.outlined,"ft-text-field--outlined":this.outlined,"ft-text-field--disabled":this.disabled,"ft-text-field--has-value":!!this.value,"ft-text-field--with-label":!!this.label,"ft-text-field--in-error":!this.inputValid||this.error,"ft-text-field--fixed":this.fixedMenuPosition,"ft-text-field--with-prefix":!!this.prefix,"ft-text-field--hide-suggestions":!this.suggestionsShouldBeDisplayed(),"ft-text-field--raised-label":this.focused||this.value!="","ft-text-field--with-icon":!!this.icon,"ft-text-field--with-password":this.isPasswordField()},r=this.suggestionsProvider&&this.value&&this.value!=""&&!this.providedSuggestions.map(a=>a.label).includes(this.value),o=!this.suggestionsProvider&&this.filterSuggestions&&this.value&&this.value!=""||r,s=this.inputValid?this.helper:(e=this.input)===null||e===void 0?void 0:e.validationMessage;return Se.html`
1557
1567
  <div class="${(0,Sf.classMap)(i)}">
1558
1568
  <div class="ft-text-field--main-panel"
1559
1569
  @keydown=${this.handleKeyboardNavigation}
@@ -1573,12 +1583,12 @@
1573
1583
  </ft-typography>
1574
1584
  `:Se.nothing}
1575
1585
  <input type="${this.resolveInputType()}"
1576
- name="${Lt(this.name)}"
1577
- maxlength="${Lt(this.maxLength||void 0)}"
1586
+ name="${Dt(this.name)}"
1587
+ maxlength="${Dt(this.maxLength||void 0)}"
1578
1588
  aria-label="${this.label}"
1579
- aria-describedby="${Lt(this.helper?"helper":void 0)}"
1589
+ aria-describedby="${Dt(this.helper?"helper":void 0)}"
1580
1590
  aria-invalid="${this.error}"
1581
- autocomplete="${Lt(this.autocomplete)}"
1591
+ autocomplete="${Dt(this.autocomplete)}"
1582
1592
  class="ft-typography--body1 ft-text-field--input"
1583
1593
  part="input"
1584
1594
  ?disabled=${this.disabled}
@@ -1611,7 +1621,7 @@
1611
1621
  `:Se.nothing}
1612
1622
  </div>
1613
1623
  `}resolveInputType(){var e;return this.isPasswordField()?this.hidePassword?"password":"text":(e=this.type)!==null&&e!==void 0?e:"text"}renderSuggestions(){return this.suggestionsProvider?Se.html`
1614
- ${(0,xf.repeat)(this.providedSuggestions,e=>Se.html`
1624
+ ${(0,bf.repeat)(this.providedSuggestions,e=>Se.html`
1615
1625
  <ft-text-field-suggestion part="suggestion" value="${e.value}" @click=${i=>this.onSuggestionClick(i,e.clickHandler)}>
1616
1626
  ${e.icon?Se.html`
1617
1627
  <ft-icon .value=${e.icon}></ft-icon>
@@ -1631,7 +1641,7 @@
1631
1641
  .variant=${this.iconVariant}
1632
1642
  .value=${this.icon}
1633
1643
  @click=${()=>{var e;return(e=this.input)===null||e===void 0?void 0:e.focus()}}></ft-icon>
1634
- `:Se.nothing}update(e){super.update(e),(e.has("value")||e.has("filterSuggestions")||e.has("suggestionsProvider"))&&this.updateSuggestions(),e.has("value")&&e.get("value")!=null&&(this.hideSuggestions=!1),e.has("dispatchedValue")&&e.get("dispatchedValue")!=null&&(this.hideSuggestions=!0)}async updateSuggestions(){var e;if(this.suggestionsProvider){(e=this.cancelableSuggest)===null||e===void 0||e.cancel();let i=this.suggestionsProvider(this.value);i instanceof Promise?(this.cancelableSuggest=(0,He.cancelable)(i),this.providedSuggestions=await this.cancelableSuggest):(this.cancelableSuggest=void 0,this.providedSuggestions=i)}else this.filterSuggestionsIfNeeded()}filterSuggestionsIfNeeded(){this.filterSuggestions?(this.slottedSuggestions.forEach(e=>e.hidden=!e.getValue().toLowerCase().includes(this.value.toLowerCase())),this.visibleSuggestions=this.slottedSuggestions.filter(e=>!e.hidden)):this.visibleSuggestions=this.slottedSuggestions,this.newValueSuggestion&&(this.visibleSuggestions=[...this.visibleSuggestions,this.newValueSuggestion]),this.hideSuggestions=this.visibleSuggestions.length<=0}contentAvailableCallback(e){super.contentAvailableCallback(e),e.has("focused")&&!this.hideSuggestions&&this.visibleSuggestions.length>0&&this.setSuggestionPosition(),e.has("value")&&this.suggestionsProvider&&(this.visibleSuggestions=[...this.providedSuggestionsInDom]),e.has("autocomplete")&&this.setupWatchAutofill(),this.suggestionsShouldBeDisplayed()&&this.setSuggestionPosition()}setupWatchAutofill(){var e;this.clearWatchAutofill(),((e=this.autocomplete)!==null&&e!==void 0?e:"off")!=="off"&&(this.watchAutofillInterval=setInterval(()=>{var i,r,n;!((i=this.input)===null||i===void 0)&&i.matches(":autofill")&&this.dispatchedValue!==((r=this.input)===null||r===void 0?void 0:r.value)&&this.setValue((n=this.input)===null||n===void 0?void 0:n.value,!0)},200))}clearWatchAutofill(){this.watchAutofillInterval&&clearInterval(this.watchAutofillInterval)}connectedCallback(){super.connectedCallback(),this.setupWatchAutofill()}disconnectedCallback(){super.disconnectedCallback(),this.clearWatchAutofill()}setValue(e,i=!1){var r,n;this.value!==e&&(this.inputValid=!0,this.setInternalValue(e),this.dispatchEvent(new _s(e))),i&&this.dispatchedValue!==e&&(this.inputValid=(n=(r=this.input)===null||r===void 0?void 0:r.checkValidity())!==null&&n!==void 0?n:!0,this.inputValid?(this.dispatchedValue=e,this.dispatchEvent(new As(e))):this.dispatchEvent(new Cs(this.input.validationMessage)))}handleInput(e){var i;let r=((i=this.input)===null||i===void 0?void 0:i.value)||"";this.setValue(r,e.key=="Escape"||e.key=="Enter")}catchComposingEvents(e){}handleClick(){this.hideSuggestions=!1}handleKeyboardNavigation(e){var i;if(e.key==="ArrowDown"||e.key==="ArrowUp"){e.preventDefault(),e.stopPropagation(),this.hideSuggestions=!1;let r=this.visibleSuggestions.findIndex(o=>o.matches(":focus-within")),n;e.key==="ArrowDown"?n=r<this.visibleSuggestions.length-1?r+1:0:n=r>0?r-1:this.visibleSuggestions.length-1,(i=this.visibleSuggestions[n])===null||i===void 0||i.focus()}(e.key=="Escape"||e.key=="Enter")&&(this.hideSuggestions=!0)}onSuggestionSelected(e){var i;this.setValue(e.detail,!0),(i=this.input)===null||i===void 0||i.focus(),setTimeout(()=>this.hideSuggestions=!0,0)}onFocus(){this.focused=!0,this.hideSuggestions=!1}onMainPanelBlur(){var e,i;!((e=this.mainPanel)===null||e===void 0)&&e.matches(":focus-within")||(this.focused=!1,this.setValue(((i=this.input)===null||i===void 0?void 0:i.value)||"",!0))}togglePasswordVisibility(){this.hidePassword=!this.hidePassword}isPasswordField(){return this.password||this.type==="password"}setSuggestionPosition(){this.suggestionsContainer.style.width=this.mainPanel.getBoundingClientRect().width+"px";let e=["bottom","top"];(0,He.computeOffsetAutoPosition)(this.mainPanel,this.suggestionsContainer,"bottom",e,"fixed","--text-field-internal-suggest-size",0).then(({x:i,y:r})=>{this.suggestionsContainer.style.left=`${i}px`,this.suggestionsContainer.style.top=`${r}px`})}suggestionsShouldBeDisplayed(){return!this.hideSuggestions&&(this.visibleSuggestions.length||this.providedSuggestions.length)}};_.elementDefinitions={"ft-input-label":ot,"ft-ripple":M,"ft-typography":F,"ft-icon":z,"ft-text-field-suggestion":bt};_.styles=[ui,He.noTextInputDefaultClearButton,mf];$([(0,P.property)()],_.prototype,"label",void 0);$([(0,P.property)({noAccessor:!0})],_.prototype,"value",null);$([(0,P.state)()],_.prototype,"dispatchedValue",void 0);$([(0,P.property)()],_.prototype,"helper",void 0);$([(0,P.property)()],_.prototype,"suggestionsHelper",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"outlined",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"disabled",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"error",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"fixedMenuPosition",void 0);$([(0,P.property)()],_.prototype,"prefix",void 0);$([(0,P.property)()],_.prototype,"icon",void 0);$([(0,P.property)()],_.prototype,"name",void 0);$([(0,P.property)()],_.prototype,"type",void 0);$([(0,P.property)()],_.prototype,"passwordHiddenIcon",void 0);$([(0,P.property)()],_.prototype,"passwordRevealedIcon",void 0);$([(0,P.property)()],_.prototype,"iconVariant",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"filterSuggestions",void 0);$([(0,He.numberProperty)()],_.prototype,"maxLength",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"password",void 0);$([(0,P.property)({type:String})],_.prototype,"autocomplete",void 0);$([(0,P.property)({attribute:!1})],_.prototype,"suggestionsProvider",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"hideCurrentValueSuggestion",void 0);$([(0,P.state)()],_.prototype,"focused",void 0);$([(0,P.state)()],_.prototype,"inputValid",void 0);$([(0,P.state)()],_.prototype,"hidePassword",void 0);$([(0,P.state)()],_.prototype,"hideSuggestions",void 0);$([(0,P.state)()],_.prototype,"visibleSuggestions",void 0);$([(0,P.state)()],_.prototype,"providedSuggestions",void 0);$([(0,P.query)(".ft-text-field--main-panel")],_.prototype,"mainPanel",void 0);$([(0,P.query)(".ft-text-field--input")],_.prototype,"input",void 0);$([(0,P.query)(".ft-text-field-suggestion--new-value")],_.prototype,"newValueSuggestion",void 0);$([(0,P.query)(".ft-text-field--suggestions")],_.prototype,"suggestionsContainer",void 0);$([(0,P.queryAll)("ft-text-field-suggestion")],_.prototype,"providedSuggestionsInDom",void 0);$([(0,P.queryAssignedElements)({selector:"ft-text-field-suggestion"})],_.prototype,"slottedSuggestions",void 0);$([(0,He.ignoreComposingEvents)()],_.prototype,"handleInput",null);$([(0,He.ignoreComposingEvents)()],_.prototype,"catchComposingEvents",null);var Ef=c(h());var wf={"ft-text-field":_,"ft-text-field-suggestion":bt};(0,Ef.customElements)(wf);var Rs=class extends CustomEvent{constructor(e){super("send-feedback",{detail:e})}};var we=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Q=class extends ht($r.FtLitElementRedux){constructor(){super(),this.hideTitle=!1,this.withMoreOptionsButton=!1,this.emptyStarIcon="STAR",this.filledStarIcon="STAR_PLAIN",this.emptyLikeIcon="THUMBS_UP",this.filledLikeIcon="THUMBS_UP_PLAIN",this.emptyDislikeIcon="THUMBS_DOWN",this.filledDislikeIcon="THUMBS_DOWN_PLAIN",this.canAccessFeedback=!1,this.canRateThisContent=!1,this.from="",this.feedbackMessage="",this.addI18nContext(J,ff),this.addStore(v)}get configuredRatingType(){var e,i;return(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.type)!==null&&i!==void 0?i:_e.NO_RATING}get ratingTypeOfDoneRatingOfThisContent(){var e,i,r;return(r=(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.rating)===null||i===void 0?void 0:i.type)!==null&&r!==void 0?r:_e.NO_RATING}get ratingValue(){var e,i,r;return(r=(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.rating)===null||i===void 0?void 0:i.value)!==null&&r!==void 0?r:-1}get ratingDate(){var e,i;let r=(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.rating)===null||i===void 0?void 0:i.date;return typeof r=="string"?(0,$r.parseDate)(r):r}render(){return!this.canAccessFeedback&&!this.canRateThisContent?ue.nothing:ue.html`
1644
+ `:Se.nothing}update(e){super.update(e),(e.has("value")||e.has("filterSuggestions")||e.has("suggestionsProvider"))&&this.updateSuggestions(),e.has("value")&&e.get("value")!=null&&(this.hideSuggestions=!1),e.has("dispatchedValue")&&e.get("dispatchedValue")!=null&&(this.hideSuggestions=!0)}async updateSuggestions(){var e;if(this.suggestionsProvider){(e=this.cancelableSuggest)===null||e===void 0||e.cancel();let i=this.suggestionsProvider(this.value);i instanceof Promise?(this.cancelableSuggest=(0,He.cancelable)(i),this.providedSuggestions=await this.cancelableSuggest):(this.cancelableSuggest=void 0,this.providedSuggestions=i)}else this.filterSuggestionsIfNeeded()}filterSuggestionsIfNeeded(){this.filterSuggestions?(this.slottedSuggestions.forEach(e=>e.hidden=!e.getValue().toLowerCase().includes(this.value.toLowerCase())),this.visibleSuggestions=this.slottedSuggestions.filter(e=>!e.hidden)):this.visibleSuggestions=this.slottedSuggestions,this.newValueSuggestion&&(this.visibleSuggestions=[...this.visibleSuggestions,this.newValueSuggestion]),this.hideSuggestions=this.visibleSuggestions.length<=0}contentAvailableCallback(e){super.contentAvailableCallback(e),e.has("focused")&&!this.hideSuggestions&&this.visibleSuggestions.length>0&&this.setSuggestionPosition(),e.has("value")&&this.suggestionsProvider&&(this.visibleSuggestions=[...this.providedSuggestionsInDom]),e.has("autocomplete")&&this.setupWatchAutofill(),this.suggestionsShouldBeDisplayed()&&this.setSuggestionPosition()}setupWatchAutofill(){var e;this.clearWatchAutofill(),((e=this.autocomplete)!==null&&e!==void 0?e:"off")!=="off"&&(this.watchAutofillInterval=setInterval(()=>{var i,r,n;!((i=this.input)===null||i===void 0)&&i.matches(":autofill")&&this.dispatchedValue!==((r=this.input)===null||r===void 0?void 0:r.value)&&this.setValue((n=this.input)===null||n===void 0?void 0:n.value,!0)},200))}clearWatchAutofill(){this.watchAutofillInterval&&clearInterval(this.watchAutofillInterval)}connectedCallback(){super.connectedCallback(),this.setupWatchAutofill()}disconnectedCallback(){super.disconnectedCallback(),this.clearWatchAutofill()}setValue(e,i=!1){var r,n;this.value!==e&&(this.inputValid=!0,this.setInternalValue(e),this.dispatchEvent(new _s(e))),i&&this.dispatchedValue!==e&&(this.inputValid=(n=(r=this.input)===null||r===void 0?void 0:r.checkValidity())!==null&&n!==void 0?n:!0,this.inputValid?(this.dispatchedValue=e,this.dispatchEvent(new As(e))):this.dispatchEvent(new Cs(this.input.validationMessage)))}handleInput(e){var i;let r=((i=this.input)===null||i===void 0?void 0:i.value)||"";this.setValue(r,e.key=="Escape"||e.key=="Enter")}catchComposingEvents(e){}handleClick(){this.hideSuggestions=!1}handleKeyboardNavigation(e){var i;if(e.key==="ArrowDown"||e.key==="ArrowUp"){e.preventDefault(),e.stopPropagation(),this.hideSuggestions=!1;let r=this.visibleSuggestions.findIndex(o=>o.matches(":focus-within")),n;e.key==="ArrowDown"?n=r<this.visibleSuggestions.length-1?r+1:0:n=r>0?r-1:this.visibleSuggestions.length-1,(i=this.visibleSuggestions[n])===null||i===void 0||i.focus()}(e.key=="Escape"||e.key=="Enter")&&(this.hideSuggestions=!0)}onSuggestionSelected(e){var i;this.setValue(e.detail,!0),(i=this.input)===null||i===void 0||i.focus(),setTimeout(()=>this.hideSuggestions=!0,0)}onFocus(){this.focused=!0,this.hideSuggestions=!1}onMainPanelBlur(){var e,i;!((e=this.mainPanel)===null||e===void 0)&&e.matches(":focus-within")||(this.focused=!1,this.setValue(((i=this.input)===null||i===void 0?void 0:i.value)||"",!0))}togglePasswordVisibility(){this.hidePassword=!this.hidePassword}isPasswordField(){return this.password||this.type==="password"}setSuggestionPosition(){this.suggestionsContainer.style.width=this.mainPanel.getBoundingClientRect().width+"px";let e=["bottom","top"];(0,He.computeOffsetAutoPosition)(this.mainPanel,this.suggestionsContainer,"bottom",e,"fixed","--text-field-internal-suggest-size",0).then(({x:i,y:r})=>{this.suggestionsContainer.style.left=`${i}px`,this.suggestionsContainer.style.top=`${r}px`})}suggestionsShouldBeDisplayed(){return!this.hideSuggestions&&(this.visibleSuggestions.length||this.providedSuggestions.length)}};_.elementDefinitions={"ft-input-label":at,"ft-ripple":M,"ft-typography":F,"ft-icon":z,"ft-text-field-suggestion":xt};_.styles=[ui,He.noTextInputDefaultClearButton,mf];$([(0,P.property)()],_.prototype,"label",void 0);$([(0,P.property)({noAccessor:!0})],_.prototype,"value",null);$([(0,P.state)()],_.prototype,"dispatchedValue",void 0);$([(0,P.property)()],_.prototype,"helper",void 0);$([(0,P.property)()],_.prototype,"suggestionsHelper",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"outlined",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"disabled",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"error",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"fixedMenuPosition",void 0);$([(0,P.property)()],_.prototype,"prefix",void 0);$([(0,P.property)()],_.prototype,"icon",void 0);$([(0,P.property)()],_.prototype,"name",void 0);$([(0,P.property)()],_.prototype,"type",void 0);$([(0,P.property)()],_.prototype,"passwordHiddenIcon",void 0);$([(0,P.property)()],_.prototype,"passwordRevealedIcon",void 0);$([(0,P.property)()],_.prototype,"iconVariant",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"filterSuggestions",void 0);$([(0,He.numberProperty)()],_.prototype,"maxLength",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"password",void 0);$([(0,P.property)({type:String})],_.prototype,"autocomplete",void 0);$([(0,P.property)({attribute:!1})],_.prototype,"suggestionsProvider",void 0);$([(0,P.property)({type:Boolean})],_.prototype,"hideCurrentValueSuggestion",void 0);$([(0,P.state)()],_.prototype,"focused",void 0);$([(0,P.state)()],_.prototype,"inputValid",void 0);$([(0,P.state)()],_.prototype,"hidePassword",void 0);$([(0,P.state)()],_.prototype,"hideSuggestions",void 0);$([(0,P.state)()],_.prototype,"visibleSuggestions",void 0);$([(0,P.state)()],_.prototype,"providedSuggestions",void 0);$([(0,P.query)(".ft-text-field--main-panel")],_.prototype,"mainPanel",void 0);$([(0,P.query)(".ft-text-field--input")],_.prototype,"input",void 0);$([(0,P.query)(".ft-text-field-suggestion--new-value")],_.prototype,"newValueSuggestion",void 0);$([(0,P.query)(".ft-text-field--suggestions")],_.prototype,"suggestionsContainer",void 0);$([(0,P.queryAll)("ft-text-field-suggestion")],_.prototype,"providedSuggestionsInDom",void 0);$([(0,P.queryAssignedElements)({selector:"ft-text-field-suggestion"})],_.prototype,"slottedSuggestions",void 0);$([(0,He.ignoreComposingEvents)()],_.prototype,"handleInput",null);$([(0,He.ignoreComposingEvents)()],_.prototype,"catchComposingEvents",null);var Ef=c(h());var wf={"ft-text-field":_,"ft-text-field-suggestion":xt};(0,Ef.customElements)(wf);var Rs=class extends CustomEvent{constructor(e){super("send-feedback",{detail:e})}};var we=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Q=class extends ht($r.FtLitElementRedux){constructor(){super(),this.hideTitle=!1,this.withMoreOptionsButton=!1,this.emptyStarIcon="STAR",this.filledStarIcon="STAR_PLAIN",this.emptyLikeIcon="THUMBS_UP",this.filledLikeIcon="THUMBS_UP_PLAIN",this.emptyDislikeIcon="THUMBS_DOWN",this.filledDislikeIcon="THUMBS_DOWN_PLAIN",this.canAccessFeedback=!1,this.canRateThisContent=!1,this.from="",this.feedbackMessage="",this.addI18nContext(J,ff),this.addStore(x)}get configuredRatingType(){var e,i;return(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.type)!==null&&i!==void 0?i:_e.NO_RATING}get ratingTypeOfDoneRatingOfThisContent(){var e,i,r;return(r=(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.rating)===null||i===void 0?void 0:i.type)!==null&&r!==void 0?r:_e.NO_RATING}get ratingValue(){var e,i,r;return(r=(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.rating)===null||i===void 0?void 0:i.value)!==null&&r!==void 0?r:-1}get ratingDate(){var e,i;let r=(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.rating)===null||i===void 0?void 0:i.date;return typeof r=="string"?(0,$r.parseDate)(r):r}render(){return!this.canAccessFeedback&&!this.canRateThisContent?ue.nothing:ue.html`
1635
1645
  <div part="container">
1636
1646
  ${this.hideTitle?ue.nothing:ue.html`
1637
1647
  <ft-typography variant="${H.title}" part="main-title">
@@ -1740,7 +1750,7 @@
1740
1750
  ${a}
1741
1751
  </div>
1742
1752
  </form>
1743
- `}return ue.nothing}onFormSubmitEvent(e,i){e.preventDefault(),i?this.onMailerFeedbackSent():this.sendFeedback()}validFromEmail(){var e,i,r;let n=/^[a-zA-Z0-9_+&*-]+(?:\.[a-zA-Z0-9_+&*-]+)*@(?:[a-zA-Z0-9-]+\.)+[a-zA-Z]{2,}$/;return!(((i=(e=this.session)===null||e===void 0?void 0:e.profile)===null||i===void 0?void 0:i.userId)==null&&(!((r=this.configuration)===null||r===void 0)&&r.mailsSentByFluidTopicsForUnauthenticatedUsers))||n.test(this.from)}sendFeedback(){var e;this.dispatchEvent(new Rs({message:this.feedbackInput.value,...((e=this.configuration)===null||e===void 0?void 0:e.mailsSentByFluidTopicsForUnauthenticatedUsers)&&{from:this.from}}))}onMailerFeedbackSent(){this.dispatchEvent(new CustomEvent("mailer-feedback"))}onOpenMoreDetails(){this.dispatchEvent(new CustomEvent("open-more-options"))}clearFeedbackInput(){setTimeout(()=>this.feedbackInput.setValue("",!0),0)}};Q.elementDefinitions={"ft-button":L,"ft-typography":F,"ft-switch":Be,"ft-switch-option":de,"ft-text-area":ye,"ft-text-field":_};we([(0,pe.property)({type:Boolean})],Q.prototype,"hideTitle",void 0);we([(0,pe.property)({type:Boolean})],Q.prototype,"withMoreOptionsButton",void 0);we([(0,pe.property)()],Q.prototype,"iconVariant",void 0);we([(0,pe.property)()],Q.prototype,"emptyStarIcon",void 0);we([(0,pe.property)()],Q.prototype,"filledStarIcon",void 0);we([(0,pe.property)()],Q.prototype,"emptyLikeIcon",void 0);we([(0,pe.property)()],Q.prototype,"filledLikeIcon",void 0);we([(0,pe.property)()],Q.prototype,"emptyDislikeIcon",void 0);we([(0,pe.property)()],Q.prototype,"filledDislikeIcon",void 0);we([(0,pe.property)({type:Boolean})],Q.prototype,"canAccessFeedback",void 0);we([(0,pe.property)({type:Boolean})],Q.prototype,"canRateThisContent",void 0);we([(0,pe.property)({attribute:!1})],Q.prototype,"i18nProperties",void 0);we([(0,pe.property)({attribute:!1})],Q.prototype,"ratingSummary",void 0);we([(0,pe.property)()],Q.prototype,"configuration",void 0);we([(0,pe.property)()],Q.prototype,"feedbackMailLinkBuilder",void 0);we([(0,$r.redux)({store:v.name})],Q.prototype,"session",void 0);we([(0,pe.query)("[part='feedback-input']")],Q.prototype,"feedbackInput",void 0);we([(0,pe.state)()],Q.prototype,"from",void 0);we([(0,pe.state)()],Q.prototype,"feedbackMessage",void 0);var Tn=class extends Q{};Tn.styles=ys(vs);var sl=ft.build("inDesignerFeedbackComponent"),Af={feedbackAndRatingDisabledInEditor:"Feedback and ratings performed here are not taken into account."};var Os=ft.fromGwt("server");var ks=class{constructor(){this.subject="",this.url="",this.subjectMetadata="",this.bodyMetadata="",this.isAuthenticated=!1}update(e,i,r,n,o){var s;this.subject=e,this.url=i,this.configuration=n,this.isAuthenticated=o,this.subjectMetadata=this.filterMetadata(r,n.subjectMetadataIds).map(a=>"["+a.values[a.values.length-1]+"]").join(""),this.bodyMetadata=this.filterMetadata(r,(s=n.bodyMetadataIds)!==null&&s!==void 0?s:[]).map(a=>"["+a.values.join(", ")+"]").join(" ")}filterMetadata(e,i){return i.map(r=>e.find(n=>n.key===r)).filter(r=>r!=null&&r.values.length>0)}shouldUseMailer(){var e,i;let r=this.isAuthenticated&&!(!((e=this.configuration)===null||e===void 0)&&e.mailsSentByFluidTopics),n=!this.isAuthenticated&&!(!((i=this.configuration)===null||i===void 0)&&i.mailsSentByFluidTopicsForUnauthenticatedUsers);return r||n}build(e){var i;if(e!=null&&e.length===0||!this.shouldUseMailer())return;let r=encodeURIComponent(this.subject+" "+this.subjectMetadata),n=encodeURIComponent(`
1753
+ `}return ue.nothing}onFormSubmitEvent(e,i){e.preventDefault(),i?this.onMailerFeedbackSent():this.sendFeedback()}validFromEmail(){var e,i,r;let n=/^[a-zA-Z0-9_+&*-]+(?:\.[a-zA-Z0-9_+&*-]+)*@(?:[a-zA-Z0-9-]+\.)+[a-zA-Z]{2,}$/;return!(((i=(e=this.session)===null||e===void 0?void 0:e.profile)===null||i===void 0?void 0:i.userId)==null&&(!((r=this.configuration)===null||r===void 0)&&r.mailsSentByFluidTopicsForUnauthenticatedUsers))||n.test(this.from)}sendFeedback(){var e;this.dispatchEvent(new Rs({message:this.feedbackInput.value,...((e=this.configuration)===null||e===void 0?void 0:e.mailsSentByFluidTopicsForUnauthenticatedUsers)&&{from:this.from}}))}onMailerFeedbackSent(){this.dispatchEvent(new CustomEvent("mailer-feedback"))}onOpenMoreDetails(){this.dispatchEvent(new CustomEvent("open-more-options"))}clearFeedbackInput(){setTimeout(()=>this.feedbackInput.setValue("",!0),0)}};Q.elementDefinitions={"ft-button":D,"ft-typography":F,"ft-switch":Be,"ft-switch-option":de,"ft-text-area":ye,"ft-text-field":_};we([(0,pe.property)({type:Boolean})],Q.prototype,"hideTitle",void 0);we([(0,pe.property)({type:Boolean})],Q.prototype,"withMoreOptionsButton",void 0);we([(0,pe.property)()],Q.prototype,"iconVariant",void 0);we([(0,pe.property)()],Q.prototype,"emptyStarIcon",void 0);we([(0,pe.property)()],Q.prototype,"filledStarIcon",void 0);we([(0,pe.property)()],Q.prototype,"emptyLikeIcon",void 0);we([(0,pe.property)()],Q.prototype,"filledLikeIcon",void 0);we([(0,pe.property)()],Q.prototype,"emptyDislikeIcon",void 0);we([(0,pe.property)()],Q.prototype,"filledDislikeIcon",void 0);we([(0,pe.property)({type:Boolean})],Q.prototype,"canAccessFeedback",void 0);we([(0,pe.property)({type:Boolean})],Q.prototype,"canRateThisContent",void 0);we([(0,pe.property)({attribute:!1})],Q.prototype,"i18nProperties",void 0);we([(0,pe.property)({attribute:!1})],Q.prototype,"ratingSummary",void 0);we([(0,pe.property)()],Q.prototype,"configuration",void 0);we([(0,pe.property)()],Q.prototype,"feedbackMailLinkBuilder",void 0);we([(0,$r.redux)({store:x.name})],Q.prototype,"session",void 0);we([(0,pe.query)("[part='feedback-input']")],Q.prototype,"feedbackInput",void 0);we([(0,pe.state)()],Q.prototype,"from",void 0);we([(0,pe.state)()],Q.prototype,"feedbackMessage",void 0);var Tn=class extends Q{};Tn.styles=ys(vs);var sl=ft.build("inDesignerFeedbackComponent"),Af={feedbackAndRatingDisabledInEditor:"Feedback and ratings performed here are not taken into account."};var Os=ft.fromGwt("server");var ks=class{constructor(){this.subject="",this.url="",this.subjectMetadata="",this.bodyMetadata="",this.isAuthenticated=!1}update(e,i,r,n,o){var s;this.subject=e,this.url=i,this.configuration=n,this.isAuthenticated=o,this.subjectMetadata=this.filterMetadata(r,n.subjectMetadataIds).map(a=>"["+a.values[a.values.length-1]+"]").join(""),this.bodyMetadata=this.filterMetadata(r,(s=n.bodyMetadataIds)!==null&&s!==void 0?s:[]).map(a=>"["+a.values.join(", ")+"]").join(" ")}filterMetadata(e,i){return i.map(r=>e.find(n=>n.key===r)).filter(r=>r!=null&&r.values.length>0)}shouldUseMailer(){var e,i;let r=this.isAuthenticated&&!(!((e=this.configuration)===null||e===void 0)&&e.mailsSentByFluidTopics),n=!this.isAuthenticated&&!(!((i=this.configuration)===null||i===void 0)&&i.mailsSentByFluidTopicsForUnauthenticatedUsers);return r||n}build(e){var i;if(e!=null&&e.length===0||!this.shouldUseMailer())return;let r=encodeURIComponent(this.subject+" "+this.subjectMetadata),n=encodeURIComponent(`
1744
1754
  ${this.bodyMetadata}
1745
1755
  ${this.url}
1746
1756
  _________________________________________________________________
@@ -1748,7 +1758,7 @@ _________________________________________________________________
1748
1758
  ${e??""}
1749
1759
 
1750
1760
  _________________________________________________________________
1751
- ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configuration)===null||i===void 0?void 0:i.recipients.join(",")}?subject=${r}&body=${n}`}};var Me=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ee=class extends Ke(ht(We)){get canAccessFeedback(){var e;return(e=this.service)===null||e===void 0?void 0:e.isFeatureAccessible(hi.FEEDBACK,{session:this.session})}get canRateThisContent(){var e;return((e=this.service)===null||e===void 0?void 0:e.isFeatureAccessible(hi.RATING,{session:this.session}))&&this.configuredRatingType!=_e.NO_RATING}get configuredRatingType(){var e,i;return(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.type)!==null&&i!==void 0?i:_e.NO_RATING}constructor(e=new So){super(),this.guestStorage=e,this.editorMode=!1,this.hideTitle=!1,this.iconVariant=Ie.fluid_topics,this.emptyStarIcon="STAR",this.filledStarIcon="STAR_PLAIN",this.emptyLikeIcon="THUMBS_UP",this.filledLikeIcon="THUMBS_UP_PLAIN",this.emptyDislikeIcon="THUMBS_DOWN",this.filledDislikeIcon="THUMBS_DOWN_PLAIN",this.feedbackLinkBuilder=new ks,this.i18nProperties={feedbackMainTitle:J.properties.viewerFeedbackMainTitle(),ratingSectionTitle:J.properties.viewerRatingSectionTitle(),dichotomousRatingSectionTitle:J.properties.viewerDichotomousRatingSectionTitle(),feedbackSectionTitle:J.properties.viewerFeedbackSectionTitle()},this.loadGuestRating=()=>{let i=this.guestStorage.get(this.guestRatingKey());i&&(this.ratingSummary=i)},this.guestRatingKey=()=>{var i;return"ft-viewer-document-feedback-guest-rating-"+((i=this.document)===null||i===void 0?void 0:i.id)},this.sendRatingDebouncer=new Ze.Debouncer(500),this.addStore(v)}render(){return Cf.html`
1761
+ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configuration)===null||i===void 0?void 0:i.recipients.join(",")}?subject=${r}&body=${n}`}};var Pe=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},ee=class extends Ge(ht(We)){get canAccessFeedback(){var e;return(e=this.service)===null||e===void 0?void 0:e.isFeatureAccessible(hi.FEEDBACK,{session:this.session})}get canRateThisContent(){var e;return((e=this.service)===null||e===void 0?void 0:e.isFeatureAccessible(hi.RATING,{session:this.session}))&&this.configuredRatingType!=_e.NO_RATING}get configuredRatingType(){var e,i;return(i=(e=this.ratingSummary)===null||e===void 0?void 0:e.type)!==null&&i!==void 0?i:_e.NO_RATING}constructor(e=new So){super(),this.guestStorage=e,this.editorMode=!1,this.hideTitle=!1,this.iconVariant=Me.fluid_topics,this.emptyStarIcon="STAR",this.filledStarIcon="STAR_PLAIN",this.emptyLikeIcon="THUMBS_UP",this.filledLikeIcon="THUMBS_UP_PLAIN",this.emptyDislikeIcon="THUMBS_DOWN",this.filledDislikeIcon="THUMBS_DOWN_PLAIN",this.feedbackLinkBuilder=new ks,this.i18nProperties={feedbackMainTitle:J.properties.viewerFeedbackMainTitle(),ratingSectionTitle:J.properties.viewerRatingSectionTitle(),dichotomousRatingSectionTitle:J.properties.viewerDichotomousRatingSectionTitle(),feedbackSectionTitle:J.properties.viewerFeedbackSectionTitle()},this.loadGuestRating=()=>{let i=this.guestStorage.get(this.guestRatingKey());i&&(this.ratingSummary=i)},this.guestRatingKey=()=>{var i;return"ft-viewer-document-feedback-guest-rating-"+((i=this.document)===null||i===void 0?void 0:i.id)},this.sendRatingDebouncer=new Xe.Debouncer(500),this.addStore(x)}render(){return Cf.html`
1752
1762
  <ft-viewer-feedback
1753
1763
  ?hideTitle=${this.hideTitle}
1754
1764
  iconVariant="${this.iconVariant}"
@@ -1769,7 +1779,7 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1769
1779
  @mailer-feedback=${this.onMailerFeedbackSent}
1770
1780
  @open-more-options=${this.openMoreOptions}
1771
1781
  ></ft-viewer-feedback>
1772
- `}willUpdate(e){var i,r,n;super.willUpdate(e),e.has("editorMode")&&this.editorMode&&this.addI18nContext(sl,Af),["document","configuration","user","mailSubject"].some(o=>e.has(o))&&this.document&&this.configuration&&this.feedbackLinkBuilder.update(this.mailSubject,(i=this.document.prettyUrl)!==null&&i!==void 0?i:"",this.document.metadata,this.configuration,((n=(r=this.session)===null||r===void 0?void 0:r.profile)===null||n===void 0?void 0:n.userId)!=null),["session","document"].some(o=>e.has(o))&&this.session&&this.document&&this.loadGuestRating()}connectedCallback(){super.connectedCallback(),this.guestStorage.addStoreListener(this.guestRatingKey,this.loadGuestRating)}disconnectedCallback(){super.disconnectedCallback(),this.guestStorage.clearStoreListeners()}rate(e){this.ratingSummary&&(this.ratingSummary={...this.ratingSummary,rating:e.detail==null?void 0:{type:this.ratingSummary.type,value:e.detail,date:new Date}},this.guestStorage.store(this.guestRatingKey(),this.ratingSummary),this.sendRatingDebouncer.run(()=>this.sendRating(e.detail)))}async sendRating(e){var i,r,n;if(!this.editorMode&&this.ratingSummary)try{e==null?await((i=this.service)===null||i===void 0?void 0:i.unrateDocument(this.document.id)):await((r=this.service)===null||r===void 0?void 0:r.rateDocument(this.document.id,(n=this.ratingSummary)===null||n===void 0?void 0:n.type,e))}catch{this.dispatchEvent(new Ze.FtNotificationEvent({type:"error",message:J.messages.ratingFailure()}))}}async sendFeedback(e){var i;try{this.editorMode?this.dispatchEvent(new Ze.FtNotificationEvent({type:"info",message:sl.messages.feedbackAndRatingDisabledInEditor()})):(await((i=this.service)===null||i===void 0?void 0:i.sendDocumentFeedback(this.document.id,e.detail.message,e.detail.from)),this.dispatchEvent(new Ze.FtNotificationEvent({type:"info",message:J.messages.feedbackSuccess()}))),this.viewerFeedback.clearFeedbackInput()}catch{this.dispatchEvent(new Ze.FtNotificationEvent({type:"error",message:J.messages.feedbackFailure()}))}}onMailerFeedbackSent(){this.dispatchEvent(new os)}openMoreOptions(){var e,i;this.dispatchEvent(new ns({documentId:this.document.id,documentTitle:this.displayName||"",ratingType:((e=this.ratingSummary)===null||e===void 0?void 0:e.type)||_e.NO_RATING,ratingValue:(i=this.ratingSummary)===null||i===void 0?void 0:i.rating}))}};ee.styles=ys(vs);ee.elementDefinitions={"ft-viewer-feedback":Tn};ee.storedRatingIfAuthenticated=(t,e)=>{var i,r;return!((i=e.session)===null||i===void 0)&&i.sessionAuthenticated?t.documentRating:(r=e.ratingSummary)!==null&&r!==void 0?r:t.documentRating};Me([(0,Ze.redux)({store:v.name})],ee.prototype,"session",void 0);Me([(0,Ze.redux)({store:"viewer"})],ee.prototype,"document",void 0);Me([(0,Ze.redux)({store:v.name})],ee.prototype,"editorMode",void 0);Me([(0,Ze.redux)({store:"viewer",selector:t=>{var e;return(e=t.configuration)===null||e===void 0?void 0:e.feedback}})],ee.prototype,"configuration",void 0);Me([(0,Ze.redux)({store:"viewer",selector:ee.storedRatingIfAuthenticated})],ee.prototype,"ratingSummary",void 0);Me([(0,Mt.property)({type:Boolean})],ee.prototype,"hideTitle",void 0);Me([(0,Mt.property)()],ee.prototype,"iconVariant",void 0);Me([(0,Mt.property)()],ee.prototype,"emptyStarIcon",void 0);Me([(0,Mt.property)()],ee.prototype,"filledStarIcon",void 0);Me([(0,Mt.property)()],ee.prototype,"emptyLikeIcon",void 0);Me([(0,Mt.property)()],ee.prototype,"filledLikeIcon",void 0);Me([(0,Mt.property)()],ee.prototype,"emptyDislikeIcon",void 0);Me([(0,Mt.property)()],ee.prototype,"filledDislikeIcon",void 0);Me([(0,Mt.query)("ft-viewer-feedback")],ee.prototype,"viewerFeedback",void 0);Me([Yo(Os.properties["mail.file_feedback.subject"](t=>{var e,i;return[((e=t.document)===null||e===void 0?void 0:e.title)||"Document",((i=t.document)===null||i===void 0?void 0:i.filename)||"Filename"]}))],ee.prototype,"mailSubject",void 0);Me([(0,Ze.redux)({store:"viewer",selector:({descriptor:t})=>t?.displayName})],ee.prototype,"displayName",void 0);var Tf=c(h());var Ls=class extends Ke(Tf.FtLitElementRedux){};var xt=c(h()),Pt=c(U());var Rf=c(x());var Of=Rf.css`
1782
+ `}willUpdate(e){var i,r,n;super.willUpdate(e),e.has("editorMode")&&this.editorMode&&this.addI18nContext(sl,Af),["document","configuration","user","mailSubject"].some(o=>e.has(o))&&this.document&&this.configuration&&this.feedbackLinkBuilder.update(this.mailSubject,(i=this.document.prettyUrl)!==null&&i!==void 0?i:"",this.document.metadata,this.configuration,((n=(r=this.session)===null||r===void 0?void 0:r.profile)===null||n===void 0?void 0:n.userId)!=null),["session","document"].some(o=>e.has(o))&&this.session&&this.document&&this.loadGuestRating()}connectedCallback(){super.connectedCallback(),this.guestStorage.addStoreListener(this.guestRatingKey,this.loadGuestRating)}disconnectedCallback(){super.disconnectedCallback(),this.guestStorage.clearStoreListeners()}rate(e){this.ratingSummary&&(this.ratingSummary={...this.ratingSummary,rating:e.detail==null?void 0:{type:this.ratingSummary.type,value:e.detail,date:new Date}},this.guestStorage.store(this.guestRatingKey(),this.ratingSummary),this.sendRatingDebouncer.run(()=>this.sendRating(e.detail)))}async sendRating(e){var i,r,n;if(!this.editorMode&&this.ratingSummary)try{e==null?await((i=this.service)===null||i===void 0?void 0:i.unrateDocument(this.document.id)):await((r=this.service)===null||r===void 0?void 0:r.rateDocument(this.document.id,(n=this.ratingSummary)===null||n===void 0?void 0:n.type,e))}catch{this.dispatchEvent(new Xe.FtNotificationEvent({type:"error",message:J.messages.ratingFailure()}))}}async sendFeedback(e){var i;try{this.editorMode?this.dispatchEvent(new Xe.FtNotificationEvent({type:"info",message:sl.messages.feedbackAndRatingDisabledInEditor()})):(await((i=this.service)===null||i===void 0?void 0:i.sendDocumentFeedback(this.document.id,e.detail.message,e.detail.from)),this.dispatchEvent(new Xe.FtNotificationEvent({type:"info",message:J.messages.feedbackSuccess()}))),this.viewerFeedback.clearFeedbackInput()}catch{this.dispatchEvent(new Xe.FtNotificationEvent({type:"error",message:J.messages.feedbackFailure()}))}}onMailerFeedbackSent(){this.dispatchEvent(new os)}openMoreOptions(){var e,i;this.dispatchEvent(new ns({documentId:this.document.id,documentTitle:this.displayName||"",ratingType:((e=this.ratingSummary)===null||e===void 0?void 0:e.type)||_e.NO_RATING,ratingValue:(i=this.ratingSummary)===null||i===void 0?void 0:i.rating}))}};ee.styles=ys(vs);ee.elementDefinitions={"ft-viewer-feedback":Tn};ee.storedRatingIfAuthenticated=(t,e)=>{var i,r;return!((i=e.session)===null||i===void 0)&&i.sessionAuthenticated?t.documentRating:(r=e.ratingSummary)!==null&&r!==void 0?r:t.documentRating};Pe([(0,Xe.redux)({store:x.name})],ee.prototype,"session",void 0);Pe([(0,Xe.redux)({store:"viewer"})],ee.prototype,"document",void 0);Pe([(0,Xe.redux)({store:x.name})],ee.prototype,"editorMode",void 0);Pe([(0,Xe.redux)({store:"viewer",selector:t=>{var e;return(e=t.configuration)===null||e===void 0?void 0:e.feedback}})],ee.prototype,"configuration",void 0);Pe([(0,Xe.redux)({store:"viewer",selector:ee.storedRatingIfAuthenticated})],ee.prototype,"ratingSummary",void 0);Pe([(0,Mt.property)({type:Boolean})],ee.prototype,"hideTitle",void 0);Pe([(0,Mt.property)()],ee.prototype,"iconVariant",void 0);Pe([(0,Mt.property)()],ee.prototype,"emptyStarIcon",void 0);Pe([(0,Mt.property)()],ee.prototype,"filledStarIcon",void 0);Pe([(0,Mt.property)()],ee.prototype,"emptyLikeIcon",void 0);Pe([(0,Mt.property)()],ee.prototype,"filledLikeIcon",void 0);Pe([(0,Mt.property)()],ee.prototype,"emptyDislikeIcon",void 0);Pe([(0,Mt.property)()],ee.prototype,"filledDislikeIcon",void 0);Pe([(0,Mt.query)("ft-viewer-feedback")],ee.prototype,"viewerFeedback",void 0);Pe([Yo(Os.properties["mail.file_feedback.subject"](t=>{var e,i;return[((e=t.document)===null||e===void 0?void 0:e.title)||"Document",((i=t.document)===null||i===void 0?void 0:i.filename)||"Filename"]}))],ee.prototype,"mailSubject",void 0);Pe([(0,Xe.redux)({store:"viewer",selector:({descriptor:t})=>t?.displayName})],ee.prototype,"displayName",void 0);var Tf=c(h());var Ds=class extends Ge(Tf.FtLitElementRedux){};var bt=c(h()),Pt=c(U());var Rf=c(S());var Of=Rf.css`
1773
1783
  :host {
1774
1784
  display: inline-block;
1775
1785
  }
@@ -1789,7 +1799,7 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1789
1799
  all: unset;
1790
1800
  position: relative;
1791
1801
  }
1792
- `;var Ds=c(x()),Le=c(U()),Mf=c(rt()),Ur=c(h());var Rn=c(x()),I=c(h());var kf=I.FtCssVariableFactory.extend("--ft-chip-color","",I.designSystemVariables.colorOnSurface),Xe={backgroundColor:I.FtCssVariableFactory.extend("--ft-chip-background-color","",I.designSystemVariables.colorSurface),color:kf,fontSize:I.FtCssVariableFactory.extend("--ft-chip-font-size","",ut.fontSize),fontWeight:I.FtCssVariableFactory.extend("--ft-chip-font-weight","",ut.fontWeight),iconSize:I.FtCssVariableFactory.create("--ft-chip-icon-size","","SIZE","18px"),borderRadius:I.FtCssVariableFactory.create("--ft-chip-border-radius","","SIZE",""),rippleColor:I.FtCssVariableFactory.extend("--ft-chip-ripple-color","",kf),horizontalPadding:I.FtCssVariableFactory.create("--ft-chip-horizontal-padding","","SIZE","6px"),verticalPadding:I.FtCssVariableFactory.create("--ft-chip-vertical-padding","","SIZE","6px"),borderColor:I.FtCssVariableFactory.extend("--ft-chip-border-color","",I.designSystemVariables.colorOutline),opacityDisabled:I.FtCssVariableFactory.external(I.designSystemVariables.colorOpacityDisabled,"Design system")},Lf=I.FtCssVariableFactory.extend("--ft-chip-highlighted-color","",I.FtCssVariableFactory.extend("--ft-chip-color","",I.designSystemVariables.colorOnPrimary)),al={backgroundColor:I.FtCssVariableFactory.extend("--ft-chip-highlighted-background-color","",I.FtCssVariableFactory.extend("--ft-chip-background-color","",I.designSystemVariables.colorPrimary)),color:Lf,rippleColor:I.FtCssVariableFactory.extend("--ft-chip-highlighted-ripple-color","",Lf)},Df={horizontalPadding:I.FtCssVariableFactory.create("--ft-chip-dense-horizontal-padding","","SIZE","4px"),verticalPadding:I.FtCssVariableFactory.create("--ft-chip-dense-vertical-padding","","SIZE","4px")},If=[I.noTextSelect,Rn.css`
1802
+ `;var Ls=c(S()),De=c(U()),Mf=c(ot()),Ur=c(h());var Rn=c(S()),I=c(h());var kf=I.FtCssVariableFactory.extend("--ft-chip-color","",I.designSystemVariables.colorOnSurface),Je={backgroundColor:I.FtCssVariableFactory.extend("--ft-chip-background-color","",I.designSystemVariables.colorSurface),color:kf,fontSize:I.FtCssVariableFactory.extend("--ft-chip-font-size","",rt.fontSize),fontWeight:I.FtCssVariableFactory.extend("--ft-chip-font-weight","",rt.fontWeight),iconSize:I.FtCssVariableFactory.create("--ft-chip-icon-size","","SIZE","18px"),borderRadius:I.FtCssVariableFactory.create("--ft-chip-border-radius","","SIZE",""),rippleColor:I.FtCssVariableFactory.extend("--ft-chip-ripple-color","",kf),horizontalPadding:I.FtCssVariableFactory.create("--ft-chip-horizontal-padding","","SIZE","6px"),verticalPadding:I.FtCssVariableFactory.create("--ft-chip-vertical-padding","","SIZE","6px"),borderColor:I.FtCssVariableFactory.extend("--ft-chip-border-color","",I.designSystemVariables.colorOutline),opacityDisabled:I.FtCssVariableFactory.external(I.designSystemVariables.colorOpacityDisabled,"Design system")},Df=I.FtCssVariableFactory.extend("--ft-chip-highlighted-color","",I.FtCssVariableFactory.extend("--ft-chip-color","",I.designSystemVariables.colorOnPrimary)),al={backgroundColor:I.FtCssVariableFactory.extend("--ft-chip-highlighted-background-color","",I.FtCssVariableFactory.extend("--ft-chip-background-color","",I.designSystemVariables.colorPrimary)),color:Df,rippleColor:I.FtCssVariableFactory.extend("--ft-chip-highlighted-ripple-color","",Df)},Lf={horizontalPadding:I.FtCssVariableFactory.create("--ft-chip-dense-horizontal-padding","","SIZE","4px"),verticalPadding:I.FtCssVariableFactory.create("--ft-chip-dense-vertical-padding","","SIZE","4px")},If=[I.noTextSelect,Rn.css`
1793
1803
  :host {
1794
1804
  display: inline-block;
1795
1805
  max-width: 100%;
@@ -1805,21 +1815,21 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1805
1815
  box-sizing: border-box;
1806
1816
  pointer-events: auto;
1807
1817
 
1808
- --chip-internal-font-size: ${Xe.fontSize};
1809
- --chip-internal-font-weight: ${Xe.fontWeight};
1818
+ --chip-internal-font-size: ${Je.fontSize};
1819
+ --chip-internal-font-weight: ${Je.fontWeight};
1810
1820
  --chip-internal-line-height: max(20px, calc(var(--chip-internal-font-size) + 2px));
1811
- ${(0,I.setVariable)(me.size,Xe.iconSize)};
1812
- --chip-internal-vertical-padding: ${Xe.verticalPadding};
1813
- --chip-internal-horizontal-padding: ${Xe.horizontalPadding};
1821
+ ${(0,I.setVariable)(me.size,Je.iconSize)};
1822
+ --chip-internal-vertical-padding: ${Je.verticalPadding};
1823
+ --chip-internal-horizontal-padding: ${Je.horizontalPadding};
1814
1824
  --chip-internal-icon-padding: 3px;
1815
- --chip-internal-content-height: max(var(--chip-internal-line-height), ${Xe.iconSize});
1825
+ --chip-internal-content-height: max(var(--chip-internal-line-height), ${Je.iconSize});
1816
1826
 
1817
- border: 1px solid ${Xe.borderColor};
1818
- color: ${Xe.color};
1819
- ${(0,I.setVariable)(G.color,Xe.rippleColor)};
1820
- border-radius: var(${(0,Rn.unsafeCSS)(Xe.borderRadius.name)}, calc(var(--chip-internal-content-height) / 2 + var(--chip-internal-vertical-padding)));
1827
+ border: 1px solid ${Je.borderColor};
1828
+ color: ${Je.color};
1829
+ ${(0,I.setVariable)(G.color,Je.rippleColor)};
1830
+ border-radius: var(${(0,Rn.unsafeCSS)(Je.borderRadius.name)}, calc(var(--chip-internal-content-height) / 2 + var(--chip-internal-vertical-padding)));
1821
1831
  padding: calc(var(--chip-internal-vertical-padding) - 1px) calc(var(--chip-internal-horizontal-padding) - 1px);
1822
- background-color: ${Xe.backgroundColor};
1832
+ background-color: ${Je.backgroundColor};
1823
1833
  line-height: var(--chip-internal-content-height);
1824
1834
  }
1825
1835
 
@@ -1829,20 +1839,20 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1829
1839
 
1830
1840
  .ft-chip--dense {
1831
1841
  --chip-internal-icon-padding: 3px;
1832
- --chip-internal-vertical-padding: ${Df.verticalPadding};
1833
- --chip-internal-horizontal-padding: ${Df.horizontalPadding};
1842
+ --chip-internal-vertical-padding: ${Lf.verticalPadding};
1843
+ --chip-internal-horizontal-padding: ${Lf.horizontalPadding};
1834
1844
  --chip-internal-line-height: max(16px, calc(var(--chip-internal-font-size) + 2px));
1835
1845
  }
1836
1846
 
1837
1847
  .ft-chip--no-content {
1838
- --chip-internal-horizontal-padding: ${Xe.horizontalPadding.get(Rn.css`var(--chip-internal-vertical-padding)`)};
1848
+ --chip-internal-horizontal-padding: ${Je.horizontalPadding.get(Rn.css`var(--chip-internal-vertical-padding)`)};
1839
1849
  }
1840
1850
 
1841
1851
  .ft-chip--disabled {
1842
1852
  cursor: default;
1843
1853
  pointer-events: none;
1844
1854
  filter: grayscale(1);
1845
- opacity: ${Xe.opacityDisabled};
1855
+ opacity: ${Je.opacityDisabled};
1846
1856
  }
1847
1857
 
1848
1858
  .ft-chip--highlighted {
@@ -1881,7 +1891,7 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1881
1891
  }
1882
1892
 
1883
1893
  .ft-chip--icon-button {
1884
- ${(0,I.setVariable)(B.iconSize,Xe.iconSize)};
1894
+ ${(0,I.setVariable)(B.iconSize,Je.iconSize)};
1885
1895
  ${(0,I.setVariable)(B.horizontalPadding,"var(--chip-internal-icon-padding)")};
1886
1896
  ${(0,I.setVariable)(B.verticalPadding,"var(--chip-internal-icon-padding)")};
1887
1897
  margin: calc((-1) * var(--chip-internal-icon-padding));
@@ -1891,9 +1901,9 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1891
1901
  vertical-align: bottom;
1892
1902
  display: block;
1893
1903
  margin: 0 var(--chip-internal-horizontal-padding);
1894
- ${(0,I.setVariable)(ut.fontSize,"var(--chip-internal-font-size)")};
1895
- ${(0,I.setVariable)(ut.fontWeight,"var(--chip-internal-font-weight)")};
1896
- ${(0,I.setVariable)(ut.lineHeight,"var(--chip-internal-content-height)")};
1904
+ ${(0,I.setVariable)(rt.fontSize,"var(--chip-internal-font-size)")};
1905
+ ${(0,I.setVariable)(rt.fontWeight,"var(--chip-internal-font-weight)")};
1906
+ ${(0,I.setVariable)(rt.lineHeight,"var(--chip-internal-content-height)")};
1897
1907
  }
1898
1908
 
1899
1909
  .ft-chip--safari-fix .ft-chip--label {
@@ -1929,7 +1939,7 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1929
1939
  .ft-chip:not(.ft-chip--trailing-icon) .ft-chip--icon-button {
1930
1940
  order: -1;
1931
1941
  }
1932
- `];var ze=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Is=class extends CustomEvent{constructor(){super("icon-click")}},ne=class extends Ur.FtLitElement{constructor(){super(...arguments),this.highlighted=!1,this.removable=!1,this.disabled=!1,this.clickable=!1,this.iconClickable=!1,this.dense=!1,this.multiLine=!1,this.label="",this.iconLabel="",this.hideIconTooltip=!1,this.icon=void 0,this.trailingIcon=!1}render(){var e;let i={"ft-chip":!0,"ft-chip--highlighted":this.highlighted,"ft-chip--disabled":this.disabled,"ft-chip--clickable":this.interactionsOnChip,"ft-chip--trailing-icon":this.trailingIcon||this.removable,"ft-chip--no-content":!this.hasTextContent(),"ft-chip--dense":this.dense,"ft-chip--multi-line":this.multiLine,"ft-chip--safari-fix":Ur.isSafari};return Ds.html`
1942
+ `];var ze=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Is=class extends CustomEvent{constructor(){super("icon-click")}},ne=class extends Ur.FtLitElement{constructor(){super(...arguments),this.highlighted=!1,this.removable=!1,this.disabled=!1,this.clickable=!1,this.iconClickable=!1,this.dense=!1,this.multiLine=!1,this.label="",this.iconLabel="",this.hideIconTooltip=!1,this.icon=void 0,this.trailingIcon=!1}render(){var e;let i={"ft-chip":!0,"ft-chip--highlighted":this.highlighted,"ft-chip--disabled":this.disabled,"ft-chip--clickable":this.interactionsOnChip,"ft-chip--trailing-icon":this.trailingIcon||this.removable,"ft-chip--no-content":!this.hasTextContent(),"ft-chip--dense":this.dense,"ft-chip--multi-line":this.multiLine,"ft-chip--safari-fix":Ur.isSafari};return Ls.html`
1933
1943
  <div class="${(0,Mf.classMap)(i)}"
1934
1944
  aria-label="${this.getLabel()}"
1935
1945
  tabindex="${this.interactionsOnChip?0:-1}"
@@ -1941,7 +1951,7 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1941
1951
  </ft-typography>
1942
1952
  ${this.internalIcon?this.renderIcon():null}
1943
1953
  </div>
1944
- `}get interactionsOnChip(){return this.clickable&&!this.disabled}get interactionsOnIcon(){return(this.iconClickable||this.removable)&&!this.disabled}renderIcon(){return this.interactionsOnIcon?Ds.html`
1954
+ `}get interactionsOnChip(){return this.clickable&&!this.disabled}get interactionsOnIcon(){return(this.iconClickable||this.removable)&&!this.disabled}renderIcon(){return this.interactionsOnIcon?Ls.html`
1945
1955
  <ft-button round
1946
1956
  class="ft-chip--icon-button"
1947
1957
  @click=${this.onIconClick}
@@ -1952,11 +1962,11 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1952
1962
  part="icon-button"
1953
1963
  ?hideTooltip=${this.hideIconTooltip}
1954
1964
  ></ft-button>
1955
- `:Ds.html`
1965
+ `:Ls.html`
1956
1966
  <div class="ft-chip--icon-container ft-no-text-select" part="icon-container">
1957
1967
  <ft-icon .variant=${this.iconVariant} .value=${this.internalIcon} part="icon"></ft-icon>
1958
1968
  </div>
1959
- `}onKeyUp(e){this.interactionsOnChip&&["Enter"," "].includes(e.key)&&e.target.click()}onIconKeyUp(e){this.interactionsOnIcon&&["Enter"," "].includes(e.key)&&(e.stopPropagation(),this.dispatchEvent(new Is))}onIconClick(e){this.interactionsOnIcon&&(e.stopPropagation(),this.dispatchEvent(new Is))}getLabel(){return this.label||this.getTextContent()}getTextContent(){return(0,Ur.unslotText)(this.slottedContent).trim()}hasTextContent(){return this.getTextContent().length>0}onSlotchange(){this.requestUpdate()}get internalIcon(){return this.icon||(this.removable?"close":void 0)}};ne.elementDefinitions={"ft-ripple":M,"ft-typography":F,"ft-icon":z,"ft-button":L};ne.styles=If;ze([(0,Le.property)({type:Boolean})],ne.prototype,"highlighted",void 0);ze([(0,Le.property)({type:Boolean})],ne.prototype,"removable",void 0);ze([(0,Le.property)({type:Boolean})],ne.prototype,"disabled",void 0);ze([(0,Le.property)({type:Boolean})],ne.prototype,"clickable",void 0);ze([(0,Le.property)({type:Boolean})],ne.prototype,"iconClickable",void 0);ze([(0,Le.property)({type:Boolean})],ne.prototype,"dense",void 0);ze([(0,Le.property)({type:Boolean})],ne.prototype,"multiLine",void 0);ze([(0,Le.property)()],ne.prototype,"label",void 0);ze([(0,Le.property)()],ne.prototype,"iconLabel",void 0);ze([(0,Le.property)({type:Boolean})],ne.prototype,"hideIconTooltip",void 0);ze([(0,Le.property)()],ne.prototype,"icon",void 0);ze([(0,Le.property)()],ne.prototype,"iconVariant",void 0);ze([(0,Le.property)({type:Boolean})],ne.prototype,"trailingIcon",void 0);ze([(0,Le.property)()],ne.prototype,"typographyVariant",void 0);ze([(0,Le.query)("ft-typography slot")],ne.prototype,"slottedContent",void 0);var Nf=c(h());var Pf={"ft-chip":ne};(0,Nf.customElements)(Pf);var Hf=c(x()),Ee=c(U()),Br=c(h());var zf=c(rt());var On=c(x()),Vr=c(U()),Ns=c(h());var $f=c(x()),Ms=c(h()),Zm={iconColor:Ms.FtCssVariableFactory.extend("--ft-floating-menu-icon-color","",Ms.designSystemVariables.colorOnSurfaceMedium)},Uf=$f.css`
1969
+ `}onKeyUp(e){this.interactionsOnChip&&["Enter"," "].includes(e.key)&&e.target.click()}onIconKeyUp(e){this.interactionsOnIcon&&["Enter"," "].includes(e.key)&&(e.stopPropagation(),this.dispatchEvent(new Is))}onIconClick(e){this.interactionsOnIcon&&(e.stopPropagation(),this.dispatchEvent(new Is))}getLabel(){return this.label||this.getTextContent()}getTextContent(){return(0,Ur.unslotText)(this.slottedContent).trim()}hasTextContent(){return this.getTextContent().length>0}onSlotchange(){this.requestUpdate()}get internalIcon(){return this.icon||(this.removable?"close":void 0)}};ne.elementDefinitions={"ft-ripple":M,"ft-typography":F,"ft-icon":z,"ft-button":D};ne.styles=If;ze([(0,De.property)({type:Boolean})],ne.prototype,"highlighted",void 0);ze([(0,De.property)({type:Boolean})],ne.prototype,"removable",void 0);ze([(0,De.property)({type:Boolean})],ne.prototype,"disabled",void 0);ze([(0,De.property)({type:Boolean})],ne.prototype,"clickable",void 0);ze([(0,De.property)({type:Boolean})],ne.prototype,"iconClickable",void 0);ze([(0,De.property)({type:Boolean})],ne.prototype,"dense",void 0);ze([(0,De.property)({type:Boolean})],ne.prototype,"multiLine",void 0);ze([(0,De.property)()],ne.prototype,"label",void 0);ze([(0,De.property)()],ne.prototype,"iconLabel",void 0);ze([(0,De.property)({type:Boolean})],ne.prototype,"hideIconTooltip",void 0);ze([(0,De.property)()],ne.prototype,"icon",void 0);ze([(0,De.property)()],ne.prototype,"iconVariant",void 0);ze([(0,De.property)({type:Boolean})],ne.prototype,"trailingIcon",void 0);ze([(0,De.property)()],ne.prototype,"typographyVariant",void 0);ze([(0,De.query)("ft-typography slot")],ne.prototype,"slottedContent",void 0);var Nf=c(h());var Pf={"ft-chip":ne};(0,Nf.customElements)(Pf);var Hf=c(S()),Ee=c(U()),Br=c(h());var zf=c(ot());var On=c(S()),Vr=c(U()),Ns=c(h());var $f=c(S()),Ms=c(h()),Zm={iconColor:Ms.FtCssVariableFactory.extend("--ft-floating-menu-icon-color","",Ms.designSystemVariables.colorOnSurfaceMedium)},Uf=$f.css`
1960
1970
  .ft-floating-menu-item {
1961
1971
  cursor: pointer;
1962
1972
  display: flex;
@@ -1991,7 +2001,7 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
1991
2001
  word-break: break-word;
1992
2002
  hyphens: auto;
1993
2003
  }
1994
- `;var Ff=c(rt()),Fr=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Ps=class extends CustomEvent{constructor(e){super("ft-floating-menu-item-select",{detail:e,bubbles:!0,composed:!0})}},Pe=class extends Ns.FtLitElement{constructor(){super(...arguments),this.value="",this.notFocusable=!1,this.disabled=!1}get floatingClasses(){return{"ft-floating-menu-item":!0,"ft-floating-menu-item--disabled":this.disabled}}render(){return On.html`
2004
+ `;var Ff=c(ot()),Fr=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},Ps=class extends CustomEvent{constructor(e){super("ft-floating-menu-item-select",{detail:e,bubbles:!0,composed:!0})}},Ne=class extends Ns.FtLitElement{constructor(){super(...arguments),this.value="",this.notFocusable=!1,this.disabled=!1}get floatingClasses(){return{"ft-floating-menu-item":!0,"ft-floating-menu-item--disabled":this.disabled}}render(){return On.html`
1995
2005
  <div class="${(0,Ff.classMap)(this.floatingClasses)}"
1996
2006
  tabindex="${this.notFocusable||this.disabled?"-1":"0"}"
1997
2007
  aria-disabled="${this.disabled}"
@@ -2007,7 +2017,7 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
2007
2017
  <slot></slot>
2008
2018
  </ft-typography>
2009
2019
  </div>
2010
- `}onClick(e){this.disabled?(e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation()):this.dispatchEvent(new Ps(this.value))}onKeyDown(e){(e.key=="Enter"||e.key==" ")&&(e.preventDefault(),this.dispatchEvent(new Ps(this.value)))}};Pe.elementDefinitions={"ft-icon":z,"ft-ripple":M,"ft-typography":F};Pe.styles=Uf;Fr([(0,Vr.property)()],Pe.prototype,"iconVariant",void 0);Fr([(0,Vr.property)()],Pe.prototype,"icon",void 0);Fr([(0,Vr.property)()],Pe.prototype,"value",void 0);Fr([(0,Vr.property)({type:Boolean})],Pe.prototype,"notFocusable",void 0);Fr([(0,Vr.property)({type:Boolean})],Pe.prototype,"disabled",void 0);Fr([(0,Ns.ignoreComposingEvents)()],Pe.prototype,"onKeyDown",null);var Vf=c(x()),st=c(h()),Si={zIndex:st.FtCssVariableFactory.create("--ft-floating-menu-z-index","","NUMBER","8"),maxWidth:st.FtCssVariableFactory.create("--ft-floating-menu-max-width","","SIZE","300px"),maxHeight:st.FtCssVariableFactory.create("--ft-floating-menu-max-height","","SIZE","500px"),textColor:st.FtCssVariableFactory.extend("--ft-floating-menu-text-color","",st.designSystemVariables.colorOnSurfaceHigh),colorSurface:st.FtCssVariableFactory.external(st.designSystemVariables.colorSurface,"Design system"),menuElevation:st.FtCssVariableFactory.external(st.designSystemVariables.elevation02,"Design system"),borderRadiusS:st.FtCssVariableFactory.external(st.designSystemVariables.borderRadiusS,"Design system")},Bf=Vf.css`
2020
+ `}onClick(e){this.disabled?(e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation()):this.dispatchEvent(new Ps(this.value))}onKeyDown(e){(e.key=="Enter"||e.key==" ")&&(e.preventDefault(),this.dispatchEvent(new Ps(this.value)))}};Ne.elementDefinitions={"ft-icon":z,"ft-ripple":M,"ft-typography":F};Ne.styles=Uf;Fr([(0,Vr.property)()],Ne.prototype,"iconVariant",void 0);Fr([(0,Vr.property)()],Ne.prototype,"icon",void 0);Fr([(0,Vr.property)()],Ne.prototype,"value",void 0);Fr([(0,Vr.property)({type:Boolean})],Ne.prototype,"notFocusable",void 0);Fr([(0,Vr.property)({type:Boolean})],Ne.prototype,"disabled",void 0);Fr([(0,Ns.ignoreComposingEvents)()],Ne.prototype,"onKeyDown",null);var Vf=c(S()),lt=c(h()),Si={zIndex:lt.FtCssVariableFactory.create("--ft-floating-menu-z-index","","NUMBER","8"),maxWidth:lt.FtCssVariableFactory.create("--ft-floating-menu-max-width","","SIZE","300px"),maxHeight:lt.FtCssVariableFactory.create("--ft-floating-menu-max-height","","SIZE","500px"),textColor:lt.FtCssVariableFactory.extend("--ft-floating-menu-text-color","",lt.designSystemVariables.colorOnSurfaceHigh),colorSurface:lt.FtCssVariableFactory.external(lt.designSystemVariables.colorSurface,"Design system"),menuElevation:lt.FtCssVariableFactory.external(lt.designSystemVariables.elevation02,"Design system"),borderRadiusS:lt.FtCssVariableFactory.external(lt.designSystemVariables.borderRadiusS,"Design system")},Bf=Vf.css`
2011
2021
  .ft-floating-menu {
2012
2022
  color: ${Si.textColor};
2013
2023
  display: contents;
@@ -2038,7 +2048,7 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
2038
2048
  .ft-floating-menu--open .ft-floating-menu--options {
2039
2049
  display: block;
2040
2050
  }
2041
- `;var Ne=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},$s=class extends CustomEvent{constructor(e){super("change",{detail:{open:e}})}};var Us=class extends CustomEvent{constructor(e){super("select",{detail:e})}},te=class extends Br.FtLitElement{constructor(){super(...arguments),this.horizontalAlignment="left",this.verticalAlignment="bottom",this.closeMenuMatchers=[],this.primary=!1,this.icon="SHORTCUT_MENU",this.iconVariant=Ie.fluid_topics,this.disabled=!1,this.menuOpen=!1,this.forceMenuOpen=!1,this.hideOptionsOnClickOutside=e=>{this.menuOpen=this.menuOpen&&e.composedPath().includes(this.container)}}updated(e){super.updated(e),e.has("menuOpen")&&this.dispatchEvent(new $s(this.menuOpen))}render(){let e={"ft-floating-menu":!0,"ft-floating-menu--open":this.forceMenuOpen||this.menuOpen,["ft-floating-menu--"+this.horizontalAlignment.toLowerCase()]:!0,["ft-floating-menu--"+this.verticalAlignment.toLowerCase()]:!0};return Hf.html`
2051
+ `;var $e=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},$s=class extends CustomEvent{constructor(e){super("change",{detail:{open:e}})}};var Us=class extends CustomEvent{constructor(e){super("select",{detail:e})}},te=class extends Br.FtLitElement{constructor(){super(...arguments),this.horizontalAlignment="left",this.verticalAlignment="bottom",this.closeMenuMatchers=[],this.primary=!1,this.icon="SHORTCUT_MENU",this.iconVariant=Me.fluid_topics,this.disabled=!1,this.menuOpen=!1,this.forceMenuOpen=!1,this.hideOptionsOnClickOutside=e=>{this.menuOpen=this.menuOpen&&e.composedPath().includes(this.container)}}updated(e){super.updated(e),e.has("menuOpen")&&this.dispatchEvent(new $s(this.menuOpen))}render(){let e={"ft-floating-menu":!0,"ft-floating-menu--open":this.forceMenuOpen||this.menuOpen,["ft-floating-menu--"+this.horizontalAlignment.toLowerCase()]:!0,["ft-floating-menu--"+this.verticalAlignment.toLowerCase()]:!0};return Hf.html`
2042
2052
  <div part="container" class="${(0,zf.classMap)(e)}" @keydown=${this.onKeyDown}>
2043
2053
  <slot name="toggle"
2044
2054
  part="toggle"
@@ -2069,7 +2079,7 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
2069
2079
  </div>
2070
2080
  </div>
2071
2081
  </div>
2072
- `}toggleMenu(){this.menuOpen=!this.menuOpen}openMenu(){this.menuOpen=!0}closeMenu(){this.menuOpen=!1}onCloseEvent(e){e.stopPropagation(),this.closeMenu()}onItemSelect(e){e.stopPropagation(),this.dispatchEvent(new Us(e.detail)),this.closeMenu()}onContentClick(e){(0,Br.eventPathContainsMatchingElement)(e,this.closeMenuMatchers,this)&&this.closeMenu()}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.hideOptionsOnClickOutside)}contentAvailableCallback(e){super.contentAvailableCallback(e),e.has("menuOpen")&&(this.menuOpen?(this.menuWrapper.classList.remove("ft-floating-menu--wrapper-positioned"),this.positionMenuWrapper(),document.addEventListener("click",this.hideOptionsOnClickOutside)):document.removeEventListener("click",this.hideOptionsOnClickOutside))}async positionMenuWrapper(){this.menuWrapper.style.left="",this.menuWrapper.style.top="";let e=this.customToggle.length>0?this.customToggle[0]:this.actionButton,{x:i,y:r}=await hs(e,this.menuWrapper,this.convertPlacement());this.menuWrapper.style.left=`${i}px`,this.menuWrapper.style.top=`${r}px`,this.menuWrapper.classList.add("ft-floating-menu--wrapper-positioned")}convertPlacement(){switch(this.horizontalAlignment){case"left":return this.verticalAlignment+"-start";case"right":return this.verticalAlignment+"-end";case"center":return this.verticalAlignment}}onKeyDown(e){e.key=="Escape"&&(this.closeMenu(),e.stopPropagation())}};te.elementDefinitions={"ft-floating-menu-item":Pe,"ft-button":L};te.styles=Bf;Ne([(0,Ee.property)()],te.prototype,"horizontalAlignment",void 0);Ne([(0,Ee.property)()],te.prototype,"verticalAlignment",void 0);Ne([(0,Br.jsonProperty)([])],te.prototype,"closeMenuMatchers",void 0);Ne([(0,Ee.property)({type:Boolean})],te.prototype,"primary",void 0);Ne([(0,Ee.property)()],te.prototype,"label",void 0);Ne([(0,Ee.property)()],te.prototype,"tooltipPosition",void 0);Ne([(0,Ee.property)()],te.prototype,"icon",void 0);Ne([(0,Ee.property)()],te.prototype,"iconVariant",void 0);Ne([(0,Ee.property)()],te.prototype,"text",void 0);Ne([(0,Ee.property)({type:Boolean})],te.prototype,"disabled",void 0);Ne([(0,Ee.state)()],te.prototype,"menuOpen",void 0);Ne([(0,Ee.state)()],te.prototype,"forceMenuOpen",void 0);Ne([(0,Ee.query)(".ft-floating-menu")],te.prototype,"container",void 0);Ne([(0,Ee.query)(".ft-floating-menu--wrapper")],te.prototype,"menuWrapper",void 0);Ne([(0,Ee.query)("#actions-button")],te.prototype,"actionButton",void 0);Ne([(0,Ee.queryAssignedElements)({slot:"toggle"})],te.prototype,"customToggle",void 0);var jf=c(x()),Fs=c(h()),Xm={color:Fs.FtCssVariableFactory.extend("--ft-floating-menu-label-color","",Fs.designSystemVariables.colorOnSurfaceMedium)},Wf=jf.css`
2082
+ `}toggleMenu(){this.menuOpen=!this.menuOpen}openMenu(){this.menuOpen=!0}closeMenu(){this.menuOpen=!1}onCloseEvent(e){e.stopPropagation(),this.closeMenu()}onItemSelect(e){e.stopPropagation(),this.dispatchEvent(new Us(e.detail)),this.closeMenu()}onContentClick(e){(0,Br.eventPathContainsMatchingElement)(e,this.closeMenuMatchers,this)&&this.closeMenu()}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.hideOptionsOnClickOutside)}contentAvailableCallback(e){super.contentAvailableCallback(e),e.has("menuOpen")&&(this.menuOpen?(this.menuWrapper.classList.remove("ft-floating-menu--wrapper-positioned"),this.positionMenuWrapper(),document.addEventListener("click",this.hideOptionsOnClickOutside)):document.removeEventListener("click",this.hideOptionsOnClickOutside))}async positionMenuWrapper(){this.menuWrapper.style.left="",this.menuWrapper.style.top="";let e=this.customToggle.length>0?this.customToggle[0]:this.actionButton,{x:i,y:r}=await hs(e,this.menuWrapper,this.convertPlacement());this.menuWrapper.style.left=`${i}px`,this.menuWrapper.style.top=`${r}px`,this.menuWrapper.classList.add("ft-floating-menu--wrapper-positioned")}convertPlacement(){switch(this.horizontalAlignment){case"left":return this.verticalAlignment+"-start";case"right":return this.verticalAlignment+"-end";case"center":return this.verticalAlignment}}onKeyDown(e){e.key=="Escape"&&(this.closeMenu(),e.stopPropagation())}};te.elementDefinitions={"ft-floating-menu-item":Ne,"ft-button":D};te.styles=Bf;$e([(0,Ee.property)()],te.prototype,"horizontalAlignment",void 0);$e([(0,Ee.property)()],te.prototype,"verticalAlignment",void 0);$e([(0,Br.jsonProperty)([])],te.prototype,"closeMenuMatchers",void 0);$e([(0,Ee.property)({type:Boolean})],te.prototype,"primary",void 0);$e([(0,Ee.property)()],te.prototype,"label",void 0);$e([(0,Ee.property)()],te.prototype,"tooltipPosition",void 0);$e([(0,Ee.property)()],te.prototype,"icon",void 0);$e([(0,Ee.property)()],te.prototype,"iconVariant",void 0);$e([(0,Ee.property)()],te.prototype,"text",void 0);$e([(0,Ee.property)({type:Boolean})],te.prototype,"disabled",void 0);$e([(0,Ee.state)()],te.prototype,"menuOpen",void 0);$e([(0,Ee.state)()],te.prototype,"forceMenuOpen",void 0);$e([(0,Ee.query)(".ft-floating-menu")],te.prototype,"container",void 0);$e([(0,Ee.query)(".ft-floating-menu--wrapper")],te.prototype,"menuWrapper",void 0);$e([(0,Ee.query)("#actions-button")],te.prototype,"actionButton",void 0);$e([(0,Ee.queryAssignedElements)({slot:"toggle"})],te.prototype,"customToggle",void 0);var jf=c(S()),Fs=c(h()),Xm={color:Fs.FtCssVariableFactory.extend("--ft-floating-menu-label-color","",Fs.designSystemVariables.colorOnSurfaceMedium)},Wf=jf.css`
2073
2083
  .ft-floating-menu-label {
2074
2084
  padding: 4px 8px;
2075
2085
  }
@@ -2082,22 +2092,22 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
2082
2092
  overflow: hidden;
2083
2093
  color: ${Xm.color}
2084
2094
  }
2085
- `;var Kf=c(x()),Gf=c(h());var wi=class extends Gf.FtLitElement{render(){return Kf.html`
2095
+ `;var Kf=c(S()),Gf=c(h());var wi=class extends Gf.FtLitElement{render(){return Kf.html`
2086
2096
  <div class="ft-floating-menu-label">
2087
2097
  <ft-typography variant="${H.caption}">
2088
2098
  <slot></slot>
2089
2099
  </ft-typography>
2090
2100
  </div>
2091
- `}};wi.elementDefinitions={"ft-typography":F};wi.styles=Wf;var Yf=c(h());var qf={"ft-floating-menu":te,"ft-floating-menu-item":Pe,"ft-floating-menu-label":wi};(0,Yf.customElements)(qf);var Je=c(x()),Xf=c(fr());var kn=c(h());function Jm(t){var e;return((e=(0,kn.accessResult)(t))===null||e===void 0?void 0:e.openMode)===uo.EXTERNAL}function Zf(t){return Jm(t)?(0,kn.accessResult)(t).originUrl:(0,kn.accessResultUrl)(t)}var Ln=class{constructor(e){this.contentLocales=e}localize(e){var i,r;return e?.key!=="ft:locale"?e:{...e,displayValue:(i=this.findLocaleValue(e))!==null&&i!==void 0?i:e.displayValue,displayTooltipValue:(r=this.findLocaleValue(e))!==null&&r!==void 0?r:e.displayTooltipValue}}findLocaleValue(e){var i;return(i=this.contentLocales.find(r=>r.lang===e.value))===null||i===void 0?void 0:i.label}};var je=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},fe=class extends mc(ht(Ls)){get metadataValue(){return this.flatMetadata?this.flatMetadata.displayValue:this.editorMode?this.key?`no value for ${this.key}`:"no metadata selected":this.noValueMessage}get metadataLabel(){var e,i,r,n,o,s;return this.metadata?this.metadata.label:(s=(n=(r=(i=(e=this.viewerStateManager)===null||e===void 0?void 0:e.clusteringHelper)===null||i===void 0?void 0:i.getMetadataDescriptor(this.key))===null||r===void 0?void 0:r.label)!==null&&n!==void 0?n:(o=this.relatives.find(a=>a.metadata.value))===null||o===void 0?void 0:o.metadata.label)!==null&&s!==void 0?s:this.key}setUdvStateManager(e){super.setUdvStateManager(e),this.key&&this.useForSwitchingToRelatives&&e.registerMetadataForSwitchToRelatives(this.key)}constructor(){super(),this.multiLine=!1,this.useForSwitchingToRelatives=!1,this.displayLabel=!1,this.hierarchicalValueTruncatingLevel=3,this.forceTooltip=!1,this.editorMode=!1,this.translateValues=!1,this.relatives=[],this.noValueMessage="No value",this.addI18nContext(kr)}willUpdate(e){var i,r,n,o,s;super.willUpdate(e),e.has("key")&&this.useForSwitchingToRelatives&&(e.get("key")&&((i=this.viewerStateManager)===null||i===void 0||i.unregisterMetadataForSwitchToRelatives(e.get("key"))),this.key&&((r=this.viewerStateManager)===null||r===void 0||r.registerMetadataForSwitchToRelatives(this.key))),e.has("useForSwitchingToRelatives")&&this.key&&(this.useForSwitchingToRelatives?(n=this.viewerStateManager)===null||n===void 0||n.registerMetadataForSwitchToRelatives(this.key):(o=this.viewerStateManager)===null||o===void 0||o.unregisterMetadataForSwitchToRelatives(this.key)),(e.has("translateValues")||e.has("metadata")||e.has("hierarchicalValueTruncatingLevel")||e.has("availableContentLocales")||this.dateFormatOptionsChanged(e))&&(this.flatMetadata=this.metadata?xt.ClusteringHelper.flattenMetadata(this.metadata,this.hierarchicalValueTruncatingLevel,this.getDateFormatter(this.metadata.key)):void 0,this.translateValues&&(this.flatMetadata=new Ln((s=this.availableContentLocales)!==null&&s!==void 0?s:[]).localize(this.flatMetadata)))}updateRelatives(){var e,i,r,n;this.useForSwitchingToRelatives&&this.key?this.relatives=(n=(i=(e=this.viewerStateManager)===null||e===void 0?void 0:e.clusteringHelper)===null||i===void 0?void 0:i.computeClustersItemsForMetadata(this.key,((r=this.document)===null||r===void 0?void 0:r.lang)||"en",this.noValueMessage,this.hierarchicalValueTruncatingLevel,this.getDateFormatter(this.key)))!==null&&n!==void 0?n:[]:this.relatives=[]}render(){return Je.html`
2101
+ `}};wi.elementDefinitions={"ft-typography":F};wi.styles=Wf;var Yf=c(h());var qf={"ft-floating-menu":te,"ft-floating-menu-item":Ne,"ft-floating-menu-label":wi};(0,Yf.customElements)(qf);var Qe=c(S()),Xf=c(yr());var kn=c(h());function Jm(t){var e;return((e=(0,kn.accessResult)(t))===null||e===void 0?void 0:e.openMode)===uo.EXTERNAL}function Zf(t){return Jm(t)?(0,kn.accessResult)(t).originUrl:(0,kn.accessResultUrl)(t)}var Dn=class{constructor(e){this.contentLocales=e}localize(e){var i,r;return e?.key!=="ft:locale"?e:{...e,displayValue:(i=this.findLocaleValue(e))!==null&&i!==void 0?i:e.displayValue,displayTooltipValue:(r=this.findLocaleValue(e))!==null&&r!==void 0?r:e.displayTooltipValue}}findLocaleValue(e){var i;return(i=this.contentLocales.find(r=>r.lang===e.value))===null||i===void 0?void 0:i.label}};var je=function(t,e,i,r){var n=arguments.length,o=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(o=(n<3?s(o):n>3?s(e,i,o):s(e,i))||o);return n>3&&o&&Object.defineProperty(e,i,o),o},fe=class extends mc(ht(Ds)){get metadataValue(){return this.flatMetadata?this.flatMetadata.displayValue:this.editorMode?this.key?`no value for ${this.key}`:"no metadata selected":this.noValueMessage}get metadataLabel(){var e,i,r,n,o,s;return this.metadata?this.metadata.label:(s=(n=(r=(i=(e=this.viewerStateManager)===null||e===void 0?void 0:e.clusteringHelper)===null||i===void 0?void 0:i.getMetadataDescriptor(this.key))===null||r===void 0?void 0:r.label)!==null&&n!==void 0?n:(o=this.relatives.find(a=>a.metadata.value))===null||o===void 0?void 0:o.metadata.label)!==null&&s!==void 0?s:this.key}setUdvStateManager(e){super.setUdvStateManager(e),this.key&&this.useForSwitchingToRelatives&&e.registerMetadataForSwitchToRelatives(this.key)}constructor(){super(),this.multiLine=!1,this.useForSwitchingToRelatives=!1,this.displayLabel=!1,this.hierarchicalValueTruncatingLevel=3,this.forceTooltip=!1,this.editorMode=!1,this.translateValues=!1,this.relatives=[],this.noValueMessage="No value",this.addI18nContext(kr)}willUpdate(e){var i,r,n,o,s;super.willUpdate(e),e.has("key")&&this.useForSwitchingToRelatives&&(e.get("key")&&((i=this.viewerStateManager)===null||i===void 0||i.unregisterMetadataForSwitchToRelatives(e.get("key"))),this.key&&((r=this.viewerStateManager)===null||r===void 0||r.registerMetadataForSwitchToRelatives(this.key))),e.has("useForSwitchingToRelatives")&&this.key&&(this.useForSwitchingToRelatives?(n=this.viewerStateManager)===null||n===void 0||n.registerMetadataForSwitchToRelatives(this.key):(o=this.viewerStateManager)===null||o===void 0||o.unregisterMetadataForSwitchToRelatives(this.key)),(e.has("translateValues")||e.has("metadata")||e.has("hierarchicalValueTruncatingLevel")||e.has("availableContentLocales")||this.dateFormatOptionsChanged(e))&&(this.flatMetadata=this.metadata?bt.ClusteringHelper.flattenMetadata(this.metadata,this.hierarchicalValueTruncatingLevel,this.getDateFormatter(this.metadata.key)):void 0,this.translateValues&&(this.flatMetadata=new Dn((s=this.availableContentLocales)!==null&&s!==void 0?s:[]).localize(this.flatMetadata)))}updateRelatives(){var e,i,r,n;this.useForSwitchingToRelatives&&this.key?this.relatives=(n=(i=(e=this.viewerStateManager)===null||e===void 0?void 0:e.clusteringHelper)===null||i===void 0?void 0:i.computeClustersItemsForMetadata(this.key,((r=this.document)===null||r===void 0?void 0:r.lang)||"en",this.noValueMessage,this.hierarchicalValueTruncatingLevel,this.getDateFormatter(this.key)))!==null&&n!==void 0?n:[]:this.relatives=[]}render(){return Qe.html`
2092
2102
  ${this.useForSwitchingToRelatives&&this.relatives.length>0?this.renderSwitchToRelatives():this.renderChip()}
2093
2103
  ${this.hideIfEmpty()}
2094
- `}hideIfEmpty(){let e=this.flatMetadata==null&&(this.useForSwitchingToRelatives?this.relatives.length===0:!0);return!this.editorMode&&e?Je.html`
2104
+ `}hideIfEmpty(){let e=this.flatMetadata==null&&(this.useForSwitchingToRelatives?this.relatives.length===0:!0);return!this.editorMode&&e?Qe.html`
2095
2105
  <style>
2096
2106
  :host {
2097
2107
  display: none !important;
2098
2108
  }
2099
2109
  </style>
2100
- `:Je.nothing}renderSwitchToRelatives(){return Je.html`
2110
+ `:Qe.nothing}renderSwitchToRelatives(){return Qe.html`
2101
2111
  <div part="floating-menu-container" class="ft-ud-viewer-metadata--container">
2102
2112
  <ft-floating-menu part="floating-menu" text="Toggle collapsible" trailingIcon>
2103
2113
  ${this.renderChip(!0)}
@@ -2105,19 +2115,19 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
2105
2115
  ${(0,Xf.repeat)(this.relatives,e=>e.metadata.value,e=>this.renderRelativeItem(e.result,e.metadata))}
2106
2116
  </ft-floating-menu>
2107
2117
  </div>
2108
- `}renderRelativeItem(e,i){var r,n;let o=this.translateValues&&(n=new Ln((r=this.availableContentLocales)!==null&&r!==void 0?r:[]).localize(i))!==null&&n!==void 0?n:i,s=Zf(e);return Je.html`
2118
+ `}renderRelativeItem(e,i){var r,n;let o=this.translateValues&&(n=new Dn((r=this.availableContentLocales)!==null&&r!==void 0?r:[]).localize(i))!==null&&n!==void 0?n:i,s=Zf(e);return Qe.html`
2109
2119
  <a part="relative-item-link"
2110
2120
  href="${s}" >
2111
2121
  <ft-ripple part="relative-item-ripple"></ft-ripple>
2112
2122
  <ft-floating-menu-item part="relative-item" value="${o.value}" notFocusable>
2113
- ${o.value==null||o.value===o.displayValue?o.displayValue:Je.html`
2123
+ ${o.value==null||o.value===o.displayValue?o.displayValue:Qe.html`
2114
2124
  <ft-tooltip part="relative-item-tooltip" text="${o.value}">
2115
2125
  ${o.displayValue}
2116
2126
  </ft-tooltip>
2117
2127
  `}
2118
2128
  </ft-floating-menu-item>
2119
2129
  </a>
2120
- `}renderChip(e=!1){var i,r,n,o,s,a;let l=!this.forceTooltip&&this.displayLabel&&((i=this.flatMetadata)===null||i===void 0?void 0:i.displayTooltipValue)==((r=this.flatMetadata)===null||r===void 0?void 0:r.displayValue),d=`${this.metadataLabel}: ${(o=(n=this.flatMetadata)===null||n===void 0?void 0:n.displayTooltipValue)!==null&&o!==void 0?o:this.noValueMessage}`,u=Je.html`
2130
+ `}renderChip(e=!1){var i,r,n,o,s,a;let l=!this.forceTooltip&&this.displayLabel&&((i=this.flatMetadata)===null||i===void 0?void 0:i.displayTooltipValue)==((r=this.flatMetadata)===null||r===void 0?void 0:r.displayValue),d=`${this.metadataLabel}: ${(o=(n=this.flatMetadata)===null||n===void 0?void 0:n.displayTooltipValue)!==null&&o!==void 0?o:this.noValueMessage}`,u=Qe.html`
2121
2131
  <ft-chip part="chip"
2122
2132
  exportpartsPrefix="chip"
2123
2133
  label="${d}"
@@ -2125,20 +2135,20 @@ ${Os.messages["mail.feedback.disclaimer"]()}`);return`mailto:${(i=this.configura
2125
2135
  trailingIcon icon="${e?"thin_arrow":""}"
2126
2136
  ?clickable=${e}
2127
2137
  ?multiLine=${this.multiLine}>
2128
- ${this.displayLabel?Je.html`
2138
+ ${this.displayLabel?Qe.html`
2129
2139
  <span part="label">${(a=(s=this.metadata)===null||s===void 0?void 0:s.label)!==null&&a!==void 0?a:this.key}: </span>
2130
- `:Je.nothing}
2131
- ${this.metadataValue.length===0?Je.nothing:Je.html`
2140
+ `:Qe.nothing}
2141
+ ${this.metadataValue.length===0?Qe.nothing:Qe.html`
2132
2142
  <span part="values">${this.metadataValue}</span>
2133
2143
  `}
2134
- </ft-chip>`;return l?u:Je.html`
2144
+ </ft-chip>`;return l?u:Qe.html`
2135
2145
  <ft-tooltip part="tooltip"
2136
2146
  slot="${e?"toggle":""}"
2137
2147
  class="${this.multiLine?"ft-ud-viewer-metadata-multi-line":""}"
2138
2148
  text="${d}">
2139
2149
  ${u}
2140
2150
  </ft-tooltip>
2141
- `}};fe.elementDefinitions={"ft-chip":ne,"ft-floating-menu":te,"ft-floating-menu-item":Pe,"ft-floating-menu-label":wi,"ft-ripple":M,"ft-tooltip":re};fe.styles=Of;je([(0,Pt.property)(),(0,xt.reduxReactive)()],fe.prototype,"key",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"multiLine",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"useForSwitchingToRelatives",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"displayLabel",void 0);je([(0,xt.numberProperty)()],fe.prototype,"hierarchicalValueTruncatingLevel",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"forceTooltip",void 0);je([(0,Pt.property)({attribute:!1})],fe.prototype,"editorMode",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"translateValues",void 0);je([(0,xt.redux)({store:"viewer",selector:(t,e)=>{var i,r;return(r=(i=t.document)===null||i===void 0?void 0:i.metadata)===null||r===void 0?void 0:r.find(n=>n.key===e.key)}})],fe.prototype,"metadata",void 0);je([(0,Pt.state)()],fe.prototype,"flatMetadata",void 0);je([(0,xt.redux)({store:"viewer"})],fe.prototype,"document",void 0);je([(0,Pt.state)()],fe.prototype,"relatives",void 0);je([(0,xt.redux)({store:v.name})],fe.prototype,"availableContentLocales",void 0);je([Yo(kr.properties.itemWithNoValueForSwitchToRelatives())],fe.prototype,"noValueMessage",void 0);je([(0,xt.reduxEventListener)({eventName:fi.clusteringHelperCreated})],fe.prototype,"updateRelatives",null);var Jf={"ft-asset-viewer-content":Lo,"ft-asset-viewer-context":Zt,"ft-asset-viewer-document-title":$o,"ft-asset-viewer-filename":Do,"ft-asset-viewer-mime-type-icon":No,"ft-asset-viewer-title":Io,"ft-ud-viewer-attachments":ji,"ft-ud-viewer-content":Ho,"ft-ud-viewer-context":mi,"ft-ud-viewer-filename":zo,"ft-ud-viewer-metadata":fe,"ft-ud-viewer-mime-type-icon":Wo,"ft-ud-viewer-title":jo,"ft-ud-viewer-feedback":ee};(0,Qf.customElements)(Jf);})();
2151
+ `}};fe.elementDefinitions={"ft-chip":ne,"ft-floating-menu":te,"ft-floating-menu-item":Ne,"ft-floating-menu-label":wi,"ft-ripple":M,"ft-tooltip":re};fe.styles=Of;je([(0,Pt.property)(),(0,bt.reduxReactive)()],fe.prototype,"key",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"multiLine",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"useForSwitchingToRelatives",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"displayLabel",void 0);je([(0,bt.numberProperty)()],fe.prototype,"hierarchicalValueTruncatingLevel",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"forceTooltip",void 0);je([(0,Pt.property)({attribute:!1})],fe.prototype,"editorMode",void 0);je([(0,Pt.property)({type:Boolean})],fe.prototype,"translateValues",void 0);je([(0,bt.redux)({store:"viewer",selector:(t,e)=>{var i,r;return(r=(i=t.document)===null||i===void 0?void 0:i.metadata)===null||r===void 0?void 0:r.find(n=>n.key===e.key)}})],fe.prototype,"metadata",void 0);je([(0,Pt.state)()],fe.prototype,"flatMetadata",void 0);je([(0,bt.redux)({store:"viewer"})],fe.prototype,"document",void 0);je([(0,Pt.state)()],fe.prototype,"relatives",void 0);je([(0,bt.redux)({store:x.name})],fe.prototype,"availableContentLocales",void 0);je([Yo(kr.properties.itemWithNoValueForSwitchToRelatives())],fe.prototype,"noValueMessage",void 0);je([(0,bt.reduxEventListener)({eventName:fi.clusteringHelperCreated})],fe.prototype,"updateRelatives",null);var Jf={"ft-asset-viewer-content":Do,"ft-asset-viewer-context":Zt,"ft-asset-viewer-document-title":$o,"ft-asset-viewer-filename":Lo,"ft-asset-viewer-mime-type-icon":No,"ft-asset-viewer-title":Io,"ft-ud-viewer-attachments":qi,"ft-ud-viewer-content":Ho,"ft-ud-viewer-context":mi,"ft-ud-viewer-filename":zo,"ft-ud-viewer-metadata":fe,"ft-ud-viewer-mime-type-icon":Wo,"ft-ud-viewer-title":jo,"ft-ud-viewer-feedback":ee};(0,Qf.customElements)(Jf);})();
2142
2152
  /*! Bundled license information:
2143
2153
 
2144
2154
  @lit/context/lib/context-request-event.js: