@fluid-topics/ft-search-saved-searches 1.0.44 → 1.0.45

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.
@@ -318,7 +318,7 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
318
318
  `,Ti=e.css`
319
319
  `,Bi=i.FtReduxStore.get({name:"ft-app-info",reducers:{setBaseUrl:(t,i)=>{t.baseUrl=i.payload},setApiIntegrationIdentifier:(t,i)=>{t.apiIntegrationIdentifier=i.payload},setUiLocale:(t,i)=>{t.uiLocale=i.payload},setAvailableUiLocales:(t,i)=>{t.availableUiLocales=i.payload},setEditorMode:(t,i)=>{t.editorMode=i.payload},setNoCustom:(t,i)=>{t.noCustom=i.payload},setNoCustomComponent:(t,i)=>{t.noCustomComponent=i.payload},setSession:(t,i)=>{t.session=i.payload}},initialState:{uiLocale:document.documentElement.lang||"en-US",availableUiLocales:[],editorMode:!1,noCustom:!1,noCustomComponent:!1}});class Ii{static build(t){const{baseUrl:i,apiIntegrationIdentifier:e}=Bi.getState(),o=null!=t?t:e;if(i&&o&&window.fluidtopics)return new window.fluidtopics.FluidTopicsApi(i,o,!0)}static get(t){var i;return null!=t?Ii.build(t):null!==(i=Ii.API)&&void 0!==i?i:Ii.API=Ii.build()}static await(t){return new Promise((i=>{let e=Ii.get(t);if(e)i(e);else{const o=Bi.subscribe((()=>{e=Ii.get(t),e&&(o(),i(e))}))}}))}}var Ri;const zi=Symbol("clearAfterUnitTest");class Ui{constructor(t){this.messageContextProvider=t,this.defaultMessages={},this.cache=new i.CacheRegistry,this.listeners={},this.currentUiLocale="",this[Ri]=()=>{this.defaultMessages={},this.cache=new i.CacheRegistry,this.listeners={}},this.currentUiLocale=Bi.getState().uiLocale,Bi.subscribe((()=>this.clearWhenUiLocaleChanges()))}clearWhenUiLocaleChanges(){const{uiLocale:t}=Bi.getState();this.currentUiLocale!==t&&(this.currentUiLocale=t,this.cache.clearAll(),this.notifyAll())}addContext(t){const i=t.name.toLowerCase();this.cache.setFinal(i,t),this.notify(i)}getAllContexts(){return this.cache.resolvedValues()}async prepareContext(t,e){var o;if(t=t.toLowerCase(),Object.keys(e).length>0){const n={...null!==(o=this.defaultMessages[t])&&void 0!==o?o:{},...e};i.deepEqual(this.defaultMessages[t],n)||(this.defaultMessages[t]=n,await this.notify(t))}await this.fetchContext(t)}resolveMessage(t,e,...o){var n,r,s;t=t.toLowerCase(),this.fetchContext(t);const a=null!==(r=null===(n=this.cache.getNow(t))||void 0===n?void 0:n.messages)&&void 0!==r?r:{};return new i.ParametrizedLabelResolver(null!==(s=this.defaultMessages[t])&&void 0!==s?s:{},a).resolve(e,...o)}async fetchContext(t){if(!this.cache.has(t))try{await this.cache.get(t,(()=>this.messageContextProvider(this.currentUiLocale,t))),await this.notify(t)}catch(t){console.error(t)}}subscribe(t,i){var e;return t=t.toLowerCase(),this.listeners[t]=null!==(e=this.listeners[t])&&void 0!==e?e:new Set,this.listeners[t].add(i),()=>{var e;return null===(e=this.listeners[t])||void 0===e?void 0:e.delete(i)}}async notifyAll(){await Promise.all(Object.keys(this.listeners).map((t=>this.notify(t))))}async notify(t){null!=this.listeners[t]&&await Promise.all([...this.listeners[t].values()].map((t=>i.delay(0).then((()=>t())).catch((()=>null)))))}}Ri=zi,null==window.FluidTopicsI18nService&&(window.FluidTopicsI18nService=new Ui((async(t,i)=>(await Ii.await()).getFluidTopicsMessageContext(t,i)))),null==window.FluidTopicsCustomI18nService&&(window.FluidTopicsCustomI18nService=new Ui((async(t,i)=>(await Ii.await()).getCustomMessageContext(t,i))));const Ni=window.FluidTopicsI18nService,ji=window.FluidTopicsCustomI18nService;var _i=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Li extends i.FtLitElement{constructor(){super(...arguments),this.apiIntegrationIdentifier="ft-integration",this.uiLocale="en-US",this.availableUiLocales=[],this.editorMode=!1,this.noCustom=!1,this.noCustomComponent=!1,this.withManualResources=!1,this.messageContexts=[],this.apiProvider=()=>Ii.get(),this.cache=new i.CacheRegistry,this.cleanSessionDebouncer=new i.Debouncer}render(){return e.html`
320
320
  <slot></slot>
321
- `}updated(t){super.updated(t),t.has("baseUrl")&&Bi.actions.setBaseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&Bi.actions.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&Bi.actions.setUiLocale(this.uiLocale),t.has("noCustom")&&Bi.actions.setNoCustom(this.noCustom),t.has("editorMode")&&Bi.actions.setEditorMode(this.editorMode),t.has("noCustomComponent")&&Bi.actions.setNoCustomComponent(this.noCustomComponent),t.has("session")&&Bi.actions.setSession(this.session),t.has("availableUiLocales")&&Bi.actions.setAvailableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>Ni.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){const t=this.apiProvider();!this.withManualResources&&t&&(null==this.session&&(this.session=await this.cache.get("session",(async()=>{const i=await t.getCurrentSession();return i.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),i.idleTimeoutInMillis),i}))),null==this.availableUiLocales&&(this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>t.getAvailableUiLocales()))))}}Li.elementDefinitions={},Li.styles=Ti,_i([o.property()],Li.prototype,"baseUrl",void 0),_i([o.property()],Li.prototype,"apiIntegrationIdentifier",void 0),_i([o.property()],Li.prototype,"uiLocale",void 0),_i([i.jsonProperty([])],Li.prototype,"availableUiLocales",void 0),_i([o.property({type:Boolean})],Li.prototype,"editorMode",void 0),_i([o.property({type:Boolean})],Li.prototype,"noCustom",void 0),_i([o.property({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],Li.prototype,"noCustomComponent",void 0),_i([o.property({type:Boolean})],Li.prototype,"withManualResources",void 0),_i([i.jsonProperty([])],Li.prototype,"messageContexts",void 0),_i([i.jsonProperty(void 0)],Li.prototype,"session",void 0),_i([o.property({type:Object})],Li.prototype,"apiProvider",void 0),i.customElement("ft-app-context")(Li);var Di=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Pi extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}}const Mi=Symbol("registerInterval");class Fi extends(function(t){var i;class e extends t{constructor(){super(...arguments),this[i]=0}setSearchStateManager(t){this.clearStateManager(),this.stateManager=t,this.addStore(t.store,"search")}clearStateManager(){this.stateManager&&(this.removeStore(this.stateManager.store),this.stateManager=void 0)}connectedCallback(){super.connectedCallback(),this[Mi]=window.setInterval((()=>this.tryToRegisterToContext()),50)}tryToRegisterToContext(){null!=this.stateManager?window.clearInterval(this[Mi]):this.dispatchEvent(new Pi)}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return i=Mi,Di([o.state()],e.prototype,"stateManager",void 0),e}(i.FtLitElementRedux)){}var Hi,Zi;!function(t){t.THUMBS_DOWN="&#xe94d;",t.THUMBS_DOWN_PLAIN="&#xe94e;",t.THUMBS_UP="&#xe94f;",t.THUMBS_UP_PLAIN="&#xe950;",t.STAR="&#xe94c;",t.STAR_PLAIN="&#xe900;",t.DESKTOP="&#xe95e;",t.TABLET_LANDSCAPE="&#xe95f;",t.TABLET_PORTRAIT="&#xe960;",t.MOBILE_LANDSCAPE="&#xe961;",t.MOBILE_PORTRAIT="&#xe962;",t.ARROW_RIGHT_TO_LINE="&#xe95d;",t.THIN_ARROW_UP="&#xe95c;",t.CONTEXTUAL="&#xe95b;",t.CHART_SIMPLE="&#xe968;",t.BARS_PROGRESS="&#xe969;",t.LINE_CHART="&#xe96c;",t.STACKED_CHART="&#xe96d;",t.BOOK_OPEN_GEAR="&#xe96a;",t.BOOK_OPEN_GEAR_SLASH="&#xe96b;",t.DIAGRAM_SUNBURST="&#xe963;",t.DIAGRAM_SANKEY="&#xe964;",t.UNSTRUCTURED_DOC="&#xe95a;",t.RESET="&#xe958;",t.THIN_ARROW_LEFT="&#xe956;",t.THIN_ARROW_RIGHT="&#xe957;",t.MY_COLLECTIONS="&#xe955;",t.OFFLINE_SETTINGS="&#xe954;",t.MY_LIBRARY="&#xe959;",t.RATE_PLAIN="&#xe952;",t.RATE="&#xe953;",t.FEEDBACK_PLAIN="&#xe951;",t.PAUSE="&#xe949;",t.PLAY="&#xe94a;",t.RELATIVES_PLAIN="&#xe947;",t.RELATIVES="&#xe948;",t.SHORTCUT_MENU="&#xe946;",t.PRINT="&#xe944;",t.DEFAULT_ROLES="&#xe945;",t.ACCOUNT_SETTINGS="&#xe943;",t.ONLINE="&#xe941;",t.OFFLINE="&#xe816;",t.UPLOAD="&#xe940;",t.BOOK_PLAIN="&#xe93f;",t.SYNC="&#xe93d;",t.SHARED_PBK="&#xe931;",t.COLLECTIONS="&#xe92a;",t.SEARCH_IN_PUBLICATION="&#xe92f;",t.BOOKS="&#xe806;",t.LOCKER="&#xe93b;",t.ARROW_DOWN="&#xe92b;",t.ARROW_LEFT="&#xe92c;",t.ARROW_RIGHT="&#xe92d;",t.ARROW_UP="&#xe92e;",t.SAVE="&#xe93a;",t.MAILS_AND_NOTIFICATIONS="&#xe939;",t.DOT="&#xe936;",t.MINUS="&#xe937;",t.PLUS="&#xe938;",t.FILTERS="&#xe935;",t.STRIPE_ARROW_RIGHT="&#xe934;",t.STRIPE_ARROW_LEFT="&#xe933;",t.ATTACHMENTS="&#xe932;",t.ADD_BOOKMARK="&#xe804;",t.BOOKMARK="&#xe805;",t.EXPORT="&#xe80f;",t.MENU="&#xe807;",t.TAG="&#xe93e;",t.TAG_PLAIN="&#xe942;",t.COPY_TO_CLIPBOARD="&#xe930;",t.COLUMNS="&#xe928;",t.ARTICLE="&#xe927;",t.CLOSE_PLAIN="&#xe925;",t.CHECK_PLAIN="&#xe926;",t.LOGOUT="&#xe923;",t.SIGN_IN="&#xe922;",t.THIN_ARROW="&#xe921;",t.TRIANGLE_BOTTOM="&#xe91d;",t.TRIANGLE_LEFT="&#xe91e;",t.TRIANGLE_RIGHT="&#xe91f;",t.TRIANGLE_TOP="&#xe920;",t.FACET_HAS_DESCENDANT="&#xe91c;",t.MINUS_PLAIN="&#xe91a;",t.PLUS_PLAIN="&#xe91b;",t.INFO="&#xe919;",t.ICON_EXPAND="&#xe917;",t.ICON_COLLAPSE="&#xe918;",t.ADD_TO_PBK="&#xe800;",t.ALERT="&#xe801;",t.ADD_ALERT="&#xe802;",t.BACK_TO_SEARCH="&#xe803;",t.DOWNLOAD="&#xe808;",t.EDIT="&#xe809;",t.FEEDBACK="&#xe80a;",t.MODIFY_PBK="&#xe80c;",t.SCHEDULED="&#xe80d;",t.SEARCH="&#xe80e;",t.SHARE="&#xe80f1;",t.TOC="&#xe810;",t.WRITE_UGC="&#xe811;",t.TRASH="&#xe812;",t.EXTLINK="&#xe814;",t.CALENDAR="&#xe815;",t.BOOK="&#xe817;",t.DOWNLOAD_PLAIN="&#xe818;",t.CHECK="&#xe819;",t.TOPICS="&#xe901;",t.EYE="&#xf06e;",t.EYE_SLASH="&#xe970;",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_THEME="&#xe911;",t.WARNING="&#xe913;",t.CONTEXT="&#xe914;",t.SEARCH_HOME="&#xe915;",t.STEPS="&#xe916;",t.HOME="&#xe80b;",t.TRANSLATE="&#xe924;",t.USER="&#xe813;",t.ADMIN="&#xe90f;",t.ANALYTICS="&#xe929;",t.ADMIN_KHUB="&#xe910;",t.ADMIN_USERS="&#xe912;",t.ADMIN_INTEGRATION="&#xe93c;",t.ADMIN_PORTAL="&#xe94b;",t.COMMENT_QUESTION="&#xe965;",t.COMMENT_QUESTION_PLAIN="&#xe966;",t.MESSAGE_BOT="&#xe967;",t.PIP="&#xe973;",t.PIP_WIDE="&#xe974;",t.EXPAND_WIDE="&#xe972;",t.X_MARK="&#xe971;"}(Hi||(Hi={})),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;"}(Zi||(Zi={})),new Map([...["abw"].map((t=>[t,Zi.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,Zi.AUDIO])),...["avi"].map((t=>[t,Zi.AVI])),...["chm","xhs"].map((t=>[t,Zi.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,Zi.CODE])),...["csv"].map((t=>[t,Zi.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,Zi.DITA])),...["epub"].map((t=>[t,Zi.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,Zi.EXCEL])),...["flac"].map((t=>[t,Zi.FLAC])),...["gif"].map((t=>[t,Zi.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,Zi.GZIP])),...["html","htm","xhtml"].map((t=>[t,Zi.HTML])),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf"].map((t=>[t,Zi.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,Zi.JPEG])),...["json"].map((t=>[t,Zi.JSON])),...["m4a","m4p"].map((t=>[t,Zi.M4A])),...["mov","qt"].map((t=>[t,Zi.MOV])),...["mp3"].map((t=>[t,Zi.MP3])),...["mp4","m4v"].map((t=>[t,Zi.MP4])),...["ogg","oga"].map((t=>[t,Zi.OGG])),...["pdf","ps"].map((t=>[t,Zi.PDF])),...["png"].map((t=>[t,Zi.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,Zi.POWERPOINT])),...["rar"].map((t=>[t,Zi.RAR])),...["stp"].map((t=>[t,Zi.STP])),...["txt","rtf","md","mdown"].map((t=>[t,Zi.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,Zi.VIDEO])),...["wav"].map((t=>[t,Zi.WAV])),...["wma"].map((t=>[t,Zi.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,Zi.WORD])),...["xml","xsl","rdf"].map((t=>[t,Zi.XML])),...["yaml","yml","x-yaml"].map((t=>[t,Zi.YAML])),...["zip"].map((t=>[t,Zi.ZIP]))]);const Ki={size:i.FtCssVariableFactory.create("--ft-icon-font-size","SIZE","24px"),fluidTopicsFontFamily:i.FtCssVariableFactory.extend("--ft-icon-fluid-topics-font-family",i.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","ft-icons")),fileFormatFontFamily:i.FtCssVariableFactory.extend("--ft-icon-file-format-font-family",i.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","ft-mime")),materialFontFamily:i.FtCssVariableFactory.extend("--ft-icon-material-font-family",i.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","Material Icons")),verticalAlign:i.FtCssVariableFactory.create("--ft-icon-vertical-align","UNKNOWN","unset")},Wi=e.css`
321
+ `}updated(t){super.updated(t),t.has("baseUrl")&&Bi.actions.setBaseUrl(this.baseUrl),t.has("apiIntegrationIdentifier")&&Bi.actions.setApiIntegrationIdentifier(this.apiIntegrationIdentifier),t.has("uiLocale")&&Bi.actions.setUiLocale(this.uiLocale),t.has("noCustom")&&Bi.actions.setNoCustom(this.noCustom),t.has("editorMode")&&Bi.actions.setEditorMode(this.editorMode),t.has("noCustomComponent")&&Bi.actions.setNoCustomComponent(this.noCustomComponent),t.has("session")&&Bi.actions.setSession(this.session),t.has("availableUiLocales")&&Bi.actions.setAvailableUiLocales(Array.isArray(this.availableUiLocales)?this.availableUiLocales:[]),t.has("messageContexts")&&null!=this.messageContexts&&this.messageContexts.forEach((t=>Ni.addContext(t))),setTimeout((()=>this.updateIfNeeded()))}async updateIfNeeded(){const t=this.apiProvider();!this.withManualResources&&t&&(null==this.session&&(this.session=await this.cache.get("session",(async()=>{const i=await t.getCurrentSession();return i.idleTimeoutInMillis>0&&this.cleanSessionDebouncer.run((()=>{this.cache.clear("session"),this.session=void 0}),i.idleTimeoutInMillis),i}))),null==this.availableUiLocales&&(this.availableUiLocales=await this.cache.get("availableUiLocales",(()=>t.getAvailableUiLocales()))))}}Li.elementDefinitions={},Li.styles=Ti,_i([o.property()],Li.prototype,"baseUrl",void 0),_i([o.property()],Li.prototype,"apiIntegrationIdentifier",void 0),_i([o.property()],Li.prototype,"uiLocale",void 0),_i([i.jsonProperty([])],Li.prototype,"availableUiLocales",void 0),_i([o.property({type:Boolean})],Li.prototype,"editorMode",void 0),_i([o.property({type:Boolean})],Li.prototype,"noCustom",void 0),_i([o.property({converter:{fromAttribute:t=>"false"!==t&&("true"===t||null!=t&&t)}})],Li.prototype,"noCustomComponent",void 0),_i([o.property({type:Boolean})],Li.prototype,"withManualResources",void 0),_i([i.jsonProperty([])],Li.prototype,"messageContexts",void 0),_i([i.jsonProperty(void 0)],Li.prototype,"session",void 0),_i([o.property({type:Object})],Li.prototype,"apiProvider",void 0),i.customElement("ft-app-context")(Li);class Di extends Event{constructor(){super(Di.eventName)}}Di.eventName="search-context-clear-all-filters";var Pi=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Mi extends Event{constructor(){super("register-ft-search-component",{bubbles:!0,composed:!0})}}const Fi=Symbol("registerInterval");class Hi extends(function(t){var i;class e extends t{constructor(){super(...arguments),this[i]=0}setSearchStateManager(t){this.clearStateManager(),this.stateManager=t,this.addStore(t.store,"search")}clearStateManager(){this.stateManager&&(this.removeStore(this.stateManager.store),this.stateManager=void 0)}connectedCallback(){super.connectedCallback(),this[Fi]=window.setInterval((()=>this.tryToRegisterToContext()),50)}tryToRegisterToContext(){null!=this.stateManager?window.clearInterval(this[Fi]):this.dispatchEvent(new Mi)}disconnectedCallback(){super.disconnectedCallback(),this.clearStateManager()}}return i=Fi,Pi([o.state()],e.prototype,"stateManager",void 0),e}(i.FtLitElementRedux)){}var Zi,Ki;!function(t){t.THUMBS_DOWN="&#xe94d;",t.THUMBS_DOWN_PLAIN="&#xe94e;",t.THUMBS_UP="&#xe94f;",t.THUMBS_UP_PLAIN="&#xe950;",t.STAR="&#xe94c;",t.STAR_PLAIN="&#xe900;",t.DESKTOP="&#xe95e;",t.TABLET_LANDSCAPE="&#xe95f;",t.TABLET_PORTRAIT="&#xe960;",t.MOBILE_LANDSCAPE="&#xe961;",t.MOBILE_PORTRAIT="&#xe962;",t.ARROW_RIGHT_TO_LINE="&#xe95d;",t.THIN_ARROW_UP="&#xe95c;",t.CONTEXTUAL="&#xe95b;",t.CHART_SIMPLE="&#xe968;",t.BARS_PROGRESS="&#xe969;",t.LINE_CHART="&#xe96c;",t.STACKED_CHART="&#xe96d;",t.BOOK_OPEN_GEAR="&#xe96a;",t.BOOK_OPEN_GEAR_SLASH="&#xe96b;",t.DIAGRAM_SUNBURST="&#xe963;",t.DIAGRAM_SANKEY="&#xe964;",t.UNSTRUCTURED_DOC="&#xe95a;",t.RESET="&#xe958;",t.THIN_ARROW_LEFT="&#xe956;",t.THIN_ARROW_RIGHT="&#xe957;",t.MY_COLLECTIONS="&#xe955;",t.OFFLINE_SETTINGS="&#xe954;",t.MY_LIBRARY="&#xe959;",t.RATE_PLAIN="&#xe952;",t.RATE="&#xe953;",t.FEEDBACK_PLAIN="&#xe951;",t.PAUSE="&#xe949;",t.PLAY="&#xe94a;",t.RELATIVES_PLAIN="&#xe947;",t.RELATIVES="&#xe948;",t.SHORTCUT_MENU="&#xe946;",t.PRINT="&#xe944;",t.DEFAULT_ROLES="&#xe945;",t.ACCOUNT_SETTINGS="&#xe943;",t.ONLINE="&#xe941;",t.OFFLINE="&#xe816;",t.UPLOAD="&#xe940;",t.BOOK_PLAIN="&#xe93f;",t.SYNC="&#xe93d;",t.SHARED_PBK="&#xe931;",t.COLLECTIONS="&#xe92a;",t.SEARCH_IN_PUBLICATION="&#xe92f;",t.BOOKS="&#xe806;",t.LOCKER="&#xe93b;",t.ARROW_DOWN="&#xe92b;",t.ARROW_LEFT="&#xe92c;",t.ARROW_RIGHT="&#xe92d;",t.ARROW_UP="&#xe92e;",t.SAVE="&#xe93a;",t.MAILS_AND_NOTIFICATIONS="&#xe939;",t.DOT="&#xe936;",t.MINUS="&#xe937;",t.PLUS="&#xe938;",t.FILTERS="&#xe935;",t.STRIPE_ARROW_RIGHT="&#xe934;",t.STRIPE_ARROW_LEFT="&#xe933;",t.ATTACHMENTS="&#xe932;",t.ADD_BOOKMARK="&#xe804;",t.BOOKMARK="&#xe805;",t.EXPORT="&#xe80f;",t.MENU="&#xe807;",t.TAG="&#xe93e;",t.TAG_PLAIN="&#xe942;",t.COPY_TO_CLIPBOARD="&#xe930;",t.COLUMNS="&#xe928;",t.ARTICLE="&#xe927;",t.CLOSE_PLAIN="&#xe925;",t.CHECK_PLAIN="&#xe926;",t.LOGOUT="&#xe923;",t.SIGN_IN="&#xe922;",t.THIN_ARROW="&#xe921;",t.TRIANGLE_BOTTOM="&#xe91d;",t.TRIANGLE_LEFT="&#xe91e;",t.TRIANGLE_RIGHT="&#xe91f;",t.TRIANGLE_TOP="&#xe920;",t.FACET_HAS_DESCENDANT="&#xe91c;",t.MINUS_PLAIN="&#xe91a;",t.PLUS_PLAIN="&#xe91b;",t.INFO="&#xe919;",t.ICON_EXPAND="&#xe917;",t.ICON_COLLAPSE="&#xe918;",t.ADD_TO_PBK="&#xe800;",t.ALERT="&#xe801;",t.ADD_ALERT="&#xe802;",t.BACK_TO_SEARCH="&#xe803;",t.DOWNLOAD="&#xe808;",t.EDIT="&#xe809;",t.FEEDBACK="&#xe80a;",t.MODIFY_PBK="&#xe80c;",t.SCHEDULED="&#xe80d;",t.SEARCH="&#xe80e;",t.SHARE="&#xe80f1;",t.TOC="&#xe810;",t.WRITE_UGC="&#xe811;",t.TRASH="&#xe812;",t.EXTLINK="&#xe814;",t.CALENDAR="&#xe815;",t.BOOK="&#xe817;",t.DOWNLOAD_PLAIN="&#xe818;",t.CHECK="&#xe819;",t.TOPICS="&#xe901;",t.EYE="&#xf06e;",t.EYE_SLASH="&#xe970;",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_THEME="&#xe911;",t.WARNING="&#xe913;",t.CONTEXT="&#xe914;",t.SEARCH_HOME="&#xe915;",t.STEPS="&#xe916;",t.HOME="&#xe80b;",t.TRANSLATE="&#xe924;",t.USER="&#xe813;",t.ADMIN="&#xe90f;",t.ANALYTICS="&#xe929;",t.ADMIN_KHUB="&#xe910;",t.ADMIN_USERS="&#xe912;",t.ADMIN_INTEGRATION="&#xe93c;",t.ADMIN_PORTAL="&#xe94b;",t.COMMENT_QUESTION="&#xe965;",t.COMMENT_QUESTION_PLAIN="&#xe966;",t.MESSAGE_BOT="&#xe967;",t.PIP="&#xe973;",t.PIP_WIDE="&#xe974;",t.EXPAND_WIDE="&#xe972;",t.X_MARK="&#xe971;"}(Zi||(Zi={})),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;"}(Ki||(Ki={})),new Map([...["abw"].map((t=>[t,Ki.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,Ki.AUDIO])),...["avi"].map((t=>[t,Ki.AVI])),...["chm","xhs"].map((t=>[t,Ki.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,Ki.CODE])),...["csv"].map((t=>[t,Ki.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,Ki.DITA])),...["epub"].map((t=>[t,Ki.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,Ki.EXCEL])),...["flac"].map((t=>[t,Ki.FLAC])),...["gif"].map((t=>[t,Ki.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,Ki.GZIP])),...["html","htm","xhtml"].map((t=>[t,Ki.HTML])),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf"].map((t=>[t,Ki.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,Ki.JPEG])),...["json"].map((t=>[t,Ki.JSON])),...["m4a","m4p"].map((t=>[t,Ki.M4A])),...["mov","qt"].map((t=>[t,Ki.MOV])),...["mp3"].map((t=>[t,Ki.MP3])),...["mp4","m4v"].map((t=>[t,Ki.MP4])),...["ogg","oga"].map((t=>[t,Ki.OGG])),...["pdf","ps"].map((t=>[t,Ki.PDF])),...["png"].map((t=>[t,Ki.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,Ki.POWERPOINT])),...["rar"].map((t=>[t,Ki.RAR])),...["stp"].map((t=>[t,Ki.STP])),...["txt","rtf","md","mdown"].map((t=>[t,Ki.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,Ki.VIDEO])),...["wav"].map((t=>[t,Ki.WAV])),...["wma"].map((t=>[t,Ki.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,Ki.WORD])),...["xml","xsl","rdf"].map((t=>[t,Ki.XML])),...["yaml","yml","x-yaml"].map((t=>[t,Ki.YAML])),...["zip"].map((t=>[t,Ki.ZIP]))]);const Wi={size:i.FtCssVariableFactory.create("--ft-icon-font-size","SIZE","24px"),fluidTopicsFontFamily:i.FtCssVariableFactory.extend("--ft-icon-fluid-topics-font-family",i.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","ft-icons")),fileFormatFontFamily:i.FtCssVariableFactory.extend("--ft-icon-file-format-font-family",i.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","ft-mime")),materialFontFamily:i.FtCssVariableFactory.extend("--ft-icon-material-font-family",i.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","Material Icons")),verticalAlign:i.FtCssVariableFactory.create("--ft-icon-vertical-align","UNKNOWN","unset")},Gi=e.css`
322
322
  :host, i.ft-icon {
323
323
  display: inline-flex;
324
324
  align-items: center;
@@ -327,14 +327,14 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
327
327
  }
328
328
 
329
329
  :host {
330
- width: ${Ki.size};
331
- height: ${Ki.size};
330
+ width: ${Wi.size};
331
+ height: ${Wi.size};
332
332
  }
333
333
 
334
334
  i.ft-icon {
335
335
  width: 100%;
336
336
  height: 100%;
337
- font-size: ${Ki.size};
337
+ font-size: ${Wi.size};
338
338
  line-height: 1;
339
339
  font-weight: normal;
340
340
  text-transform: none;
@@ -345,33 +345,33 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
345
345
  text-rendering: auto;
346
346
  -webkit-font-smoothing: antialiased;
347
347
  -moz-osx-font-smoothing: grayscale;
348
- vertical-align: ${Ki.verticalAlign};
348
+ vertical-align: ${Wi.verticalAlign};
349
349
  }
350
350
 
351
351
  i.ft-icon.ft-icon--fluid-topics {
352
- font-family: ${Ki.fluidTopicsFontFamily}, ft-icons, fticons, sans-serif;
352
+ font-family: ${Wi.fluidTopicsFontFamily}, ft-icons, fticons, sans-serif;
353
353
 
354
354
  /* Ugly fix because font is broken */
355
- font-size: calc(0.75 * ${Ki.size});
356
- line-height: ${Ki.size};
355
+ font-size: calc(0.75 * ${Wi.size});
356
+ line-height: ${Wi.size};
357
357
  position: relative;
358
358
  top: -4%;
359
359
  justify-content: center;
360
360
  }
361
361
 
362
362
  .ft-icon--file-format {
363
- font-family: ${Ki.fileFormatFontFamily}, ft-mime, sans-serif;
363
+ font-family: ${Wi.fileFormatFontFamily}, ft-mime, sans-serif;
364
364
  }
365
365
 
366
366
  .ft-icon--material {
367
- font-family: ${Ki.materialFontFamily}, "Material Icons", sans-serif;
367
+ font-family: ${Wi.materialFontFamily}, "Material Icons", sans-serif;
368
368
  }
369
- `;var Gi;!function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(Gi||(Gi={}));var qi=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Yi extends i.FtLitElement{constructor(){super(...arguments),this.resolvedIcon=e.nothing}render(){const t=this.variant&&Object.values(Gi).includes(this.variant)?this.variant:Gi.fluid_topics,i=t!==Gi.material||!!this.value;return e.html`
369
+ `;var qi;!function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(qi||(qi={}));var Yi=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Vi extends i.FtLitElement{constructor(){super(...arguments),this.resolvedIcon=e.nothing}render(){const t=this.variant&&Object.values(qi).includes(this.variant)?this.variant:qi.fluid_topics,i=t!==qi.material||!!this.value;return e.html`
370
370
  <i class="ft-icon ft-icon--${t}" part="icon icon-${t}">
371
371
  ${r.unsafeHTML(this.resolvedIcon)}
372
372
  <slot ?hidden=${i}></slot>
373
373
  </i>
374
- `}get textContent(){var t,i;return null!==(i=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==i?i:""}update(t){super.update(t),["value","variant"].some((i=>t.has(i)))&&this.resolveIcon()}resolveIcon(){var t,i;let o=this.value||this.textContent;switch(this.variant){case Gi.file_format:this.resolvedIcon=null!==(t=Zi[o.replace("-","_").toUpperCase()])&&void 0!==t?t:o;break;case Gi.material:this.resolvedIcon=this.value||e.nothing;break;default:this.resolvedIcon=null!==(i=Hi[o.replace("-","_").toUpperCase()])&&void 0!==i?i:o}}firstUpdated(t){super.firstUpdated(t),setTimeout((()=>this.resolveIcon()))}}Yi.elementDefinitions={},Yi.styles=Wi,qi([o.property()],Yi.prototype,"variant",void 0),qi([o.property()],Yi.prototype,"value",void 0),qi([o.state()],Yi.prototype,"resolvedIcon",void 0),qi([o.query("slot")],Yi.prototype,"slottedContent",void 0),i.customElement("ft-icon")(Yi);const Vi=i.FtCssVariableFactory.create("--ft-tooltip-distance","SIZE","4px"),Xi=i.FtCssVariableFactory.create("--ft-tooltip-color","COLOR","#FFFFFF"),Ji=i.FtCssVariableFactory.create("--ft-tooltip-background-color","COLOR","#666666"),Qi=i.FtCssVariableFactory.create("--ft-tooltip-z-index","NUMBER","1"),te=i.FtCssVariableFactory.external(i.designSystemVariables.borderRadiusS,"Design system"),ie=i.FtCssVariableFactory.create("--ft-tooltip-max-width","SIZE","150px"),ee=e.css`
374
+ `}get textContent(){var t,i;return null!==(i=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==i?i:""}update(t){super.update(t),["value","variant"].some((i=>t.has(i)))&&this.resolveIcon()}resolveIcon(){var t,i;let o=this.value||this.textContent;switch(this.variant){case qi.file_format:this.resolvedIcon=null!==(t=Ki[o.replace("-","_").toUpperCase()])&&void 0!==t?t:o;break;case qi.material:this.resolvedIcon=this.value||e.nothing;break;default:this.resolvedIcon=null!==(i=Zi[o.replace("-","_").toUpperCase()])&&void 0!==i?i:o}}firstUpdated(t){super.firstUpdated(t),setTimeout((()=>this.resolveIcon()))}}Vi.elementDefinitions={},Vi.styles=Gi,Yi([o.property()],Vi.prototype,"variant",void 0),Yi([o.property()],Vi.prototype,"value",void 0),Yi([o.state()],Vi.prototype,"resolvedIcon",void 0),Yi([o.query("slot")],Vi.prototype,"slottedContent",void 0),i.customElement("ft-icon")(Vi);const Xi=i.FtCssVariableFactory.create("--ft-tooltip-distance","SIZE","4px"),Ji=i.FtCssVariableFactory.create("--ft-tooltip-color","COLOR","#FFFFFF"),Qi=i.FtCssVariableFactory.create("--ft-tooltip-background-color","COLOR","#666666"),te=i.FtCssVariableFactory.create("--ft-tooltip-z-index","NUMBER","1"),ie=i.FtCssVariableFactory.external(i.designSystemVariables.borderRadiusS,"Design system"),ee=i.FtCssVariableFactory.create("--ft-tooltip-max-width","SIZE","150px"),oe=e.css`
375
375
  .ft-tooltip--container {
376
376
  display: block;
377
377
  position: relative;
@@ -387,23 +387,23 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
387
387
  box-sizing: border-box;
388
388
  overflow: hidden;
389
389
  width: max-content;
390
- max-width: ${ie};
390
+ max-width: ${ee};
391
391
  text-align: center;
392
- padding: ${Vi};
393
- z-index: ${Qi};
392
+ padding: ${Xi};
393
+ z-index: ${te};
394
394
  }
395
395
 
396
396
  .ft-tooltip--content {
397
397
  padding: 4px 8px;
398
- border-radius: ${te};
399
- background-color: ${Ji};
400
- color: ${Xi};
398
+ border-radius: ${ie};
399
+ background-color: ${Qi};
400
+ color: ${Ji};
401
401
  top: -500px;
402
402
  left: -500px;
403
403
  position: relative;
404
404
  word-break: break-word;
405
405
  }
406
- `;var oe=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class ne extends i.FtLitElement{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.validPositions=new Set(["top","bottom","left","right"]),this.hideDebounce=new i.Debouncer,this.revealDebouncer=new i.Debouncer}get validPosition(){return this.validPositions.has(this.position)?this.position:"bottom"}render(){return e.html`
406
+ `;var ne=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class re extends i.FtLitElement{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.validPositions=new Set(["top","bottom","left","right"]),this.hideDebounce=new i.Debouncer,this.revealDebouncer=new i.Debouncer}get validPosition(){return this.validPositions.has(this.position)?this.position:"bottom"}render(){return e.html`
407
407
  <div part="container"
408
408
  class="ft-tooltip--container ${this.inline?"ft-tooltip--inline":""}"
409
409
  @mouseenter=${this.onHover}
@@ -421,7 +421,7 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
421
421
  </div>
422
422
  </div>
423
423
  </div>
424
- `}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((i=>t.has(i)))&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.validPosition){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const i=t.getBoundingClientRect(),e=(i.height-this.tooltip.clientHeight)/2,o=(i.width-this.tooltip.clientWidth)/2;let n=0,r=0;switch(this.validPosition){case"top":r=-this.tooltip.clientHeight,n=o;break;case"bottom":r=i.height,n=o;break;case"left":r=e,n=-this.tooltip.clientWidth;break;case"right":r=e,n=i.width}i.left+n+this.tooltip.clientWidth>window.innerWidth&&(n=window.innerWidth-this.tooltip.clientWidth-i.left),i.left+n<0&&(n=4-i.left);const s=this.tooltip.style;s.left=n+"px",s.top=r+"px",s.maxWidth=`max(${i.width}px, ${ie})`}this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}}ne.elementDefinitions={"ft-typography":bi},ne.styles=ee,oe([o.property()],ne.prototype,"text",void 0),oe([o.property({type:Boolean})],ne.prototype,"manual",void 0),oe([o.property({type:Boolean})],ne.prototype,"inline",void 0),oe([o.property({type:Number})],ne.prototype,"delay",void 0),oe([o.property()],ne.prototype,"position",void 0),oe([o.queryAssignedNodes("",!0)],ne.prototype,"slotNodes",void 0),oe([o.query(".ft-tooltip--container")],ne.prototype,"container",void 0),oe([o.query("slot")],ne.prototype,"target",void 0),oe([o.query(".ft-tooltip")],ne.prototype,"tooltip",void 0),oe([o.query(".ft-tooltip--content")],ne.prototype,"tooltipContent",void 0),oe([o.state()],ne.prototype,"visible",void 0),i.customElement("ft-tooltip")(ne);const re={color:i.FtCssVariableFactory.extend("--ft-loader-color",i.designSystemVariables.colorPrimary),size:i.FtCssVariableFactory.create("--ft-loader-size","SIZE","80px")},se=e.css`
424
+ `}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((i=>t.has(i)))&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.validPosition){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const i=t.getBoundingClientRect(),e=(i.height-this.tooltip.clientHeight)/2,o=(i.width-this.tooltip.clientWidth)/2;let n=0,r=0;switch(this.validPosition){case"top":r=-this.tooltip.clientHeight,n=o;break;case"bottom":r=i.height,n=o;break;case"left":r=e,n=-this.tooltip.clientWidth;break;case"right":r=e,n=i.width}i.left+n+this.tooltip.clientWidth>window.innerWidth&&(n=window.innerWidth-this.tooltip.clientWidth-i.left),i.left+n<0&&(n=4-i.left);const s=this.tooltip.style;s.left=n+"px",s.top=r+"px",s.maxWidth=`max(${i.width}px, ${ee})`}this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}}re.elementDefinitions={"ft-typography":bi},re.styles=oe,ne([o.property()],re.prototype,"text",void 0),ne([o.property({type:Boolean})],re.prototype,"manual",void 0),ne([o.property({type:Boolean})],re.prototype,"inline",void 0),ne([o.property({type:Number})],re.prototype,"delay",void 0),ne([o.property()],re.prototype,"position",void 0),ne([o.queryAssignedNodes("",!0)],re.prototype,"slotNodes",void 0),ne([o.query(".ft-tooltip--container")],re.prototype,"container",void 0),ne([o.query("slot")],re.prototype,"target",void 0),ne([o.query(".ft-tooltip")],re.prototype,"tooltip",void 0),ne([o.query(".ft-tooltip--content")],re.prototype,"tooltipContent",void 0),ne([o.state()],re.prototype,"visible",void 0),i.customElement("ft-tooltip")(re);const se={color:i.FtCssVariableFactory.extend("--ft-loader-color",i.designSystemVariables.colorPrimary),size:i.FtCssVariableFactory.create("--ft-loader-size","SIZE","80px")},ae=e.css`
425
425
  :host {
426
426
  line-height: 0;
427
427
  }
@@ -430,8 +430,8 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
430
430
  display: inline-block;
431
431
  position: relative;
432
432
 
433
- width: ${re.size};
434
- height: ${re.size};
433
+ width: ${se.size};
434
+ height: ${se.size};
435
435
  }
436
436
 
437
437
  .ft-loader div {
@@ -440,7 +440,7 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
440
440
  width: 25%;
441
441
  height: 25%;
442
442
  border-radius: 50%;
443
- background: ${re.color};
443
+ background: ${se.color};
444
444
  animation-timing-function: cubic-bezier(0, 1, 1, 0);
445
445
  }
446
446
 
@@ -487,17 +487,17 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
487
487
  transform: translate(0, 0);
488
488
  }
489
489
  100% {
490
- transform: translate(calc(0.35 * ${re.size}), 0);
490
+ transform: translate(calc(0.35 * ${se.size}), 0);
491
491
  }
492
492
  }
493
- `;class ae extends i.FtLitElement{render(){return e.html`
493
+ `;class le extends i.FtLitElement{render(){return e.html`
494
494
  <div class="ft-loader">
495
495
  <div></div>
496
496
  <div></div>
497
497
  <div></div>
498
498
  <div></div>
499
499
  </div>
500
- `}}ae.styles=se,i.customElement("ft-loader")(ae);const le=i.FtCssVariableFactory.extend("--ft-button-color",i.designSystemVariables.colorPrimary),he={backgroundColor:i.FtCssVariableFactory.extend("--ft-button-background-color",i.designSystemVariables.colorSurface),borderRadius:i.FtCssVariableFactory.extend("--ft-button-border-radius",i.designSystemVariables.borderRadiusL),color:le,fontSize:i.FtCssVariableFactory.extend("--ft-button-font-size",ri.fontSize),iconSize:i.FtCssVariableFactory.create("--ft-button-icon-size","SIZE","24px"),rippleColor:i.FtCssVariableFactory.extend("--ft-button-ripple-color",le),verticalPadding:i.FtCssVariableFactory.create("--ft-button-vertical-padding","SIZE","6px"),horizontalPadding:i.FtCssVariableFactory.create("--ft-button-horizontal-padding","SIZE","8px"),iconPadding:i.FtCssVariableFactory.create("--ft-button-icon-padding","SIZE","8px"),opacityDisabled:i.FtCssVariableFactory.external(i.designSystemVariables.colorOpacityDisabled,"Design system")},ce=i.FtCssVariableFactory.extend("--ft-button-primary-color",i.FtCssVariableFactory.extend("--ft-button-color",i.designSystemVariables.colorOnPrimary)),pe={backgroundColor:i.FtCssVariableFactory.extend("--ft-button-primary-background-color",i.FtCssVariableFactory.extend("--ft-button-background-color",i.designSystemVariables.colorPrimary)),color:ce,rippleColor:i.FtCssVariableFactory.extend("--ft-button-primary-ripple-color",ce)},de=i.FtCssVariableFactory.extend("--ft-button-dense-border-radius",i.FtCssVariableFactory.extend("--ft-button-border-radius",i.designSystemVariables.borderRadiusM)),fe=i.FtCssVariableFactory.create("--ft-button-dense-vertical-padding","SIZE","2px"),ue=i.FtCssVariableFactory.create("--ft-button-dense-horizontal-padding","SIZE","4px"),ve=i.FtCssVariableFactory.create("--ft-button-dense-icon-padding","SIZE","4px"),ge=[e.css`
500
+ `}}le.styles=ae,i.customElement("ft-loader")(le);const he=i.FtCssVariableFactory.extend("--ft-button-color",i.designSystemVariables.colorPrimary),ce={backgroundColor:i.FtCssVariableFactory.extend("--ft-button-background-color",i.designSystemVariables.colorSurface),borderRadius:i.FtCssVariableFactory.extend("--ft-button-border-radius",i.designSystemVariables.borderRadiusL),color:he,fontSize:i.FtCssVariableFactory.extend("--ft-button-font-size",ri.fontSize),iconSize:i.FtCssVariableFactory.create("--ft-button-icon-size","SIZE","24px"),rippleColor:i.FtCssVariableFactory.extend("--ft-button-ripple-color",he),verticalPadding:i.FtCssVariableFactory.create("--ft-button-vertical-padding","SIZE","6px"),horizontalPadding:i.FtCssVariableFactory.create("--ft-button-horizontal-padding","SIZE","8px"),iconPadding:i.FtCssVariableFactory.create("--ft-button-icon-padding","SIZE","8px"),opacityDisabled:i.FtCssVariableFactory.external(i.designSystemVariables.colorOpacityDisabled,"Design system")},pe=i.FtCssVariableFactory.extend("--ft-button-primary-color",i.FtCssVariableFactory.extend("--ft-button-color",i.designSystemVariables.colorOnPrimary)),de={backgroundColor:i.FtCssVariableFactory.extend("--ft-button-primary-background-color",i.FtCssVariableFactory.extend("--ft-button-background-color",i.designSystemVariables.colorPrimary)),color:pe,rippleColor:i.FtCssVariableFactory.extend("--ft-button-primary-ripple-color",pe)},fe=i.FtCssVariableFactory.extend("--ft-button-dense-border-radius",i.FtCssVariableFactory.extend("--ft-button-border-radius",i.designSystemVariables.borderRadiusM)),ue=i.FtCssVariableFactory.create("--ft-button-dense-vertical-padding","SIZE","2px"),ve=i.FtCssVariableFactory.create("--ft-button-dense-horizontal-padding","SIZE","4px"),ge=i.FtCssVariableFactory.create("--ft-button-dense-icon-padding","SIZE","4px"),ye=[e.css`
501
501
  :host {
502
502
  display: inline-block;
503
503
  max-width: 100%;
@@ -508,7 +508,7 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
508
508
  box-shadow: 0px 0px 0px transparent;
509
509
  border: 0px solid transparent;
510
510
  text-shadow: 0px 0px 0px transparent;
511
- font-size: ${he.fontSize};
511
+ font-size: ${ce.fontSize};
512
512
  }
513
513
 
514
514
  button:hover {
@@ -537,31 +537,31 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
537
537
  border: none;
538
538
  pointer-events: auto;
539
539
 
540
- --ft-button-internal-line-height: max(calc(${he.fontSize} + 2px), ${he.iconSize});
541
- --ft-button-internal-color: ${he.color};
542
- ${i.setVariable(Ki.size,he.iconSize)};
543
- ${i.setVariable(l.color,he.rippleColor)};
540
+ --ft-button-internal-line-height: max(calc(${ce.fontSize} + 2px), ${ce.iconSize});
541
+ --ft-button-internal-color: ${ce.color};
542
+ ${i.setVariable(Wi.size,ce.iconSize)};
543
+ ${i.setVariable(l.color,ce.rippleColor)};
544
544
 
545
- border-radius: ${he.borderRadius};
546
- padding: ${he.verticalPadding} ${he.horizontalPadding};
547
- background-color: ${he.backgroundColor};
545
+ border-radius: ${ce.borderRadius};
546
+ padding: ${ce.verticalPadding} ${ce.horizontalPadding};
547
+ background-color: ${ce.backgroundColor};
548
548
  color: var(--ft-button-internal-color);
549
549
  -webkit-mask-image: radial-gradient(white, black);
550
550
  }
551
551
 
552
552
  .ft-button.ft-button--outlined {
553
553
  border: 1px solid var(--ft-button-internal-color);
554
- padding: calc(${he.verticalPadding} - 1px) calc(${he.horizontalPadding} - 1px);
554
+ padding: calc(${ce.verticalPadding} - 1px) calc(${ce.horizontalPadding} - 1px);
555
555
  }
556
556
 
557
557
  .ft-button.ft-button--dense {
558
- padding: ${fe} ${ue};
559
- border-radius: ${de};
560
- gap: ${ve};
558
+ padding: ${ue} ${ve};
559
+ border-radius: ${fe};
560
+ gap: ${ge};
561
561
  }
562
562
 
563
563
  .ft-button.ft-button--dense.ft-button--outlined {
564
- padding: calc(${fe} - 1px) calc(${ue} - 1px);
564
+ padding: calc(${ue} - 1px) calc(${ve} - 1px);
565
565
  }
566
566
 
567
567
  .ft-button:not([disabled]):hover {
@@ -569,22 +569,22 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
569
569
  }
570
570
 
571
571
  .ft-button--round {
572
- border-radius: calc(var(--ft-button-internal-line-height) / 2 + ${he.verticalPadding});
572
+ border-radius: calc(var(--ft-button-internal-line-height) / 2 + ${ce.verticalPadding});
573
573
  }
574
574
 
575
575
  .ft-button--round.ft-button--dense {
576
- border-radius: calc(var(--ft-button-internal-line-height) / 2 + ${fe});
576
+ border-radius: calc(var(--ft-button-internal-line-height) / 2 + ${ue});
577
577
  }
578
578
 
579
579
  .ft-button[disabled] {
580
580
  filter: grayscale(1);
581
- opacity: ${he.opacityDisabled};
581
+ opacity: ${ce.opacityDisabled};
582
582
  }
583
583
 
584
584
  .ft-button.ft-button--primary {
585
- background-color: ${pe.backgroundColor};
586
- --ft-button-internal-color: ${pe.color};
587
- ${i.setVariable(l.color,pe.rippleColor)};
585
+ background-color: ${de.backgroundColor};
586
+ --ft-button-internal-color: ${de.color};
587
+ ${i.setVariable(l.color,de.rippleColor)};
588
588
  }
589
589
 
590
590
  .ft-button:focus {
@@ -597,13 +597,13 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
597
597
  white-space: nowrap;
598
598
  text-overflow: ellipsis;
599
599
  display: block;
600
- margin: 0 ${he.iconPadding};
600
+ margin: 0 ${ce.iconPadding};
601
601
  ${i.setVariable(ri.fontSize,"1em")};
602
602
  ${i.setVariable(ri.lineHeight,"var(--ft-button-internal-line-height)")};
603
603
  }
604
604
 
605
605
  .ft-button--dense .ft-button--label {
606
- margin: 0 ${ve};
606
+ margin: 0 ${ge};
607
607
  }
608
608
 
609
609
  .ft-button--label[hidden] {
@@ -616,13 +616,13 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
616
616
  }
617
617
 
618
618
  .ft-button--label[hidden] + ft-icon {
619
- margin: 0 calc(${he.horizontalPadding} * -1);
620
- padding: 0 ${he.verticalPadding};
619
+ margin: 0 calc(${ce.horizontalPadding} * -1);
620
+ padding: 0 ${ce.verticalPadding};
621
621
  }
622
622
 
623
623
  .ft-button--dense .ft-button--label[hidden] + ft-icon {
624
- margin: 0 calc(${ue} * -1);
625
- padding: 0 ${fe};
624
+ margin: 0 calc(${ve} * -1);
625
+ padding: 0 ${ue};
626
626
  }
627
627
 
628
628
  .ft-button:not(.ft-button--trailing-icon) ft-icon,
@@ -631,10 +631,10 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
631
631
  }
632
632
 
633
633
  ft-loader {
634
- ${i.setVariable(re.size,he.iconSize)};
635
- ${i.setVariable(re.color,"var(--ft-button-internal-color)")};
634
+ ${i.setVariable(se.size,ce.iconSize)};
635
+ ${i.setVariable(se.color,"var(--ft-button-internal-color)")};
636
636
  }
637
- `,i.noTextSelect];var ye=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class be extends i.FtLitElement{constructor(){super(...arguments),this.role="button",this.primary=!1,this.outlined=!1,this.disabled=!1,this.dense=!1,this.round=!1,this.label="",this.icon=void 0,this.trailingIcon=!1,this.loading=!1,this.tooltipPosition="bottom",this.hideTooltip=!1,this.forceTooltip=!1,this.onclick=t=>{this.isDisabled()&&(t.preventDefault(),t.stopPropagation(),t.stopImmediatePropagation())}}render(){const t={"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};return this.addTooltipIfNeeded(e.html`
637
+ `,i.noTextSelect];var be=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class xe extends i.FtLitElement{constructor(){super(...arguments),this.role="button",this.primary=!1,this.outlined=!1,this.disabled=!1,this.dense=!1,this.round=!1,this.label="",this.icon=void 0,this.trailingIcon=!1,this.loading=!1,this.tooltipPosition="bottom",this.hideTooltip=!1,this.forceTooltip=!1,this.onclick=t=>{this.isDisabled()&&(t.preventDefault(),t.stopPropagation(),t.stopImmediatePropagation())}}render(){const t={"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};return this.addTooltipIfNeeded(e.html`
638
638
  <button part="button"
639
639
  class="${n.classMap(t)}"
640
640
  aria-label="${this.getLabel()}"
@@ -657,12 +657,12 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
657
657
  </ft-tooltip>
658
658
  `:t}resolveIcon(){return this.loading?e.html`
659
659
  <ft-loader part="loader icon"></ft-loader> `:this.icon?e.html`
660
- <ft-icon part="icon" .variant="${this.iconVariant}" .value="${this.icon}"></ft-icon> `:e.nothing}focus(){var t;null===(t=this.button)||void 0===t||t.focus()}getLabel(){return this.label||this.textContent}get textContent(){return this.unslotText(this.slottedContent).trim()}unslotText(t){return t instanceof HTMLSlotElement?t.assignedNodes().map((t=>this.unslotText(t))).join(""):(null==t?void 0:t.textContent)||""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}isDisabled(){return this.disabled||this.loading}}be.elementDefinitions={"ft-ripple":b,"ft-tooltip":ne,"ft-typography":bi,"ft-icon":Yi,"ft-loader":ae},be.styles=[i.safariEllipsisFix,ge],ye([o.property({type:String,reflect:!0})],be.prototype,"role",void 0),ye([o.property({type:Boolean})],be.prototype,"primary",void 0),ye([o.property({type:Boolean})],be.prototype,"outlined",void 0),ye([o.property({type:Boolean})],be.prototype,"disabled",void 0),ye([o.property({type:Boolean})],be.prototype,"dense",void 0),ye([o.property({type:Boolean})],be.prototype,"round",void 0),ye([o.property()],be.prototype,"label",void 0),ye([o.property()],be.prototype,"icon",void 0),ye([o.property()],be.prototype,"iconVariant",void 0),ye([o.property({type:Boolean})],be.prototype,"trailingIcon",void 0),ye([o.property({type:Boolean})],be.prototype,"loading",void 0),ye([o.property()],be.prototype,"tooltipPosition",void 0),ye([o.property({type:Boolean})],be.prototype,"hideTooltip",void 0),ye([o.property({type:Boolean})],be.prototype,"forceTooltip",void 0),ye([o.query(".ft-button")],be.prototype,"button",void 0),ye([o.query(".ft-button--label slot")],be.prototype,"slottedContent",void 0),i.customElement("ft-button")(be);const xe=e.css`
661
- `;var me=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};const $e=Symbol("i18nProperties"),we=Symbol("i18nUnsubs");function Se(t){var i;class e extends t{constructor(){super(...arguments),this.useCustomMessageContexts=!1,this[i]=new Map}get i18nService(){return this.useCustomMessageContexts?ji:Ni}i18n(t,i,...e){var o;if("string"==typeof t)return this.i18nService.resolveMessage(t,i,...e);const n=null!==(o=t.args)&&void 0!==o?o:t.argsProvider?t.argsProvider(this):[];return this.i18nService.resolveMessage(t.context,t.key,...n)}onI18nUpdate(t){var i;null===(i=this[$e])||void 0===i||i.forEach(((i,e)=>{i.context.toLowerCase()===t.toLowerCase()&&(this[e]=this.i18n(i))})),setTimeout((()=>this.requestUpdate()),0)}updated(t){var i;super.updated(t),null===(i=this[$e])||void 0===i||i.forEach(((t,i)=>{null!=t.argsProvider&&(this[i]=this.i18n(t))}))}connectedCallback(){super.connectedCallback(),null!=this[$e]&&new Set([...this[$e].values()].map((t=>t.context))).forEach((t=>this.addI18nMessages(t)))}addI18nMessages(t,i){t=t.toLowerCase(),this[we].has(t)||this[we].set(t,this.i18nService.subscribe(t,(()=>this.onI18nUpdate(t)))),this.i18nService.prepareContext(t,null!=i?i:{})}addI18nContext(t,i){this.addI18nMessages(t.name,i)}disconnectedCallback(){super.disconnectedCallback(),this[we].forEach((t=>t())),this[we].clear()}}return i=we,me([o.property({type:Boolean})],e.prototype,"useCustomMessageContexts",void 0),e}class ke extends(Se(i.FtLitElement)){}class Ee extends(Se(i.FtLitElementRedux)){}var Oe=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Ce extends Ee{constructor(){super(),this.editorMode=!1,this.addStore(Bi)}render(){return this.key&&this.context?e.html`
660
+ <ft-icon part="icon" .variant="${this.iconVariant}" .value="${this.icon}"></ft-icon> `:e.nothing}focus(){var t;null===(t=this.button)||void 0===t||t.focus()}getLabel(){return this.label||this.textContent}get textContent(){return this.unslotText(this.slottedContent).trim()}unslotText(t){return t instanceof HTMLSlotElement?t.assignedNodes().map((t=>this.unslotText(t))).join(""):(null==t?void 0:t.textContent)||""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}isDisabled(){return this.disabled||this.loading}}xe.elementDefinitions={"ft-ripple":b,"ft-tooltip":re,"ft-typography":bi,"ft-icon":Vi,"ft-loader":le},xe.styles=[i.safariEllipsisFix,ye],be([o.property({type:String,reflect:!0})],xe.prototype,"role",void 0),be([o.property({type:Boolean})],xe.prototype,"primary",void 0),be([o.property({type:Boolean})],xe.prototype,"outlined",void 0),be([o.property({type:Boolean})],xe.prototype,"disabled",void 0),be([o.property({type:Boolean})],xe.prototype,"dense",void 0),be([o.property({type:Boolean})],xe.prototype,"round",void 0),be([o.property()],xe.prototype,"label",void 0),be([o.property()],xe.prototype,"icon",void 0),be([o.property()],xe.prototype,"iconVariant",void 0),be([o.property({type:Boolean})],xe.prototype,"trailingIcon",void 0),be([o.property({type:Boolean})],xe.prototype,"loading",void 0),be([o.property()],xe.prototype,"tooltipPosition",void 0),be([o.property({type:Boolean})],xe.prototype,"hideTooltip",void 0),be([o.property({type:Boolean})],xe.prototype,"forceTooltip",void 0),be([o.query(".ft-button")],xe.prototype,"button",void 0),be([o.query(".ft-button--label slot")],xe.prototype,"slottedContent",void 0),i.customElement("ft-button")(xe);const me=e.css`
661
+ `;var $e=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};const we=Symbol("i18nProperties"),Se=Symbol("i18nUnsubs");function ke(t){var i;class e extends t{constructor(){super(...arguments),this.useCustomMessageContexts=!1,this[i]=new Map}get i18nService(){return this.useCustomMessageContexts?ji:Ni}i18n(t,i,...e){var o;if("string"==typeof t)return this.i18nService.resolveMessage(t,i,...e);const n=null!==(o=t.args)&&void 0!==o?o:t.argsProvider?t.argsProvider(this):[];return this.i18nService.resolveMessage(t.context,t.key,...n)}onI18nUpdate(t){var i;null===(i=this[we])||void 0===i||i.forEach(((i,e)=>{i.context.toLowerCase()===t.toLowerCase()&&(this[e]=this.i18n(i))})),setTimeout((()=>this.requestUpdate()),0)}updated(t){var i;super.updated(t),null===(i=this[we])||void 0===i||i.forEach(((t,i)=>{null!=t.argsProvider&&(this[i]=this.i18n(t))}))}connectedCallback(){super.connectedCallback(),null!=this[we]&&new Set([...this[we].values()].map((t=>t.context))).forEach((t=>this.addI18nMessages(t)))}addI18nMessages(t,i){t=t.toLowerCase(),this[Se].has(t)||this[Se].set(t,this.i18nService.subscribe(t,(()=>this.onI18nUpdate(t)))),this.i18nService.prepareContext(t,null!=i?i:{})}addI18nContext(t,i){this.addI18nMessages(t.name,i)}disconnectedCallback(){super.disconnectedCallback(),this[Se].forEach((t=>t())),this[Se].clear()}}return i=Se,$e([o.property({type:Boolean})],e.prototype,"useCustomMessageContexts",void 0),e}class Ee extends(ke(i.FtLitElement)){}class Oe extends(ke(i.FtLitElementRedux)){}var Ce=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Ae extends Oe{constructor(){super(),this.editorMode=!1,this.addStore(Bi)}render(){return this.key&&this.context?e.html`
662
662
  <span class="ft-i18n">
663
663
  ${this.i18n(this.context,this.key,...Array.isArray(this.args)?this.args:[])}
664
664
  </span>
665
- `:this.editorMode?"Select a context and a label key.":e.nothing}update(t){super.update(t),this.context&&this.key&&this.defaultMessage&&this.addI18nMessages(this.context,{[this.key]:this.defaultMessage})}}Ce.elementDefinitions={},Ce.styles=xe,Oe([i.redux()],Ce.prototype,"editorMode",void 0),Oe([o.property()],Ce.prototype,"context",void 0),Oe([o.property()],Ce.prototype,"key",void 0),Oe([i.jsonProperty([])],Ce.prototype,"args",void 0),Oe([o.property()],Ce.prototype,"defaultMessage",void 0);class Ae{static build(t){return new Ae(t)}static fromGwt(t){return new Ae(t)}constructor(t){this.name=t,this.properties=new Proxy({},{get:(t,i)=>{const e=i;return t=>({context:this.name,key:e,args:"function"==typeof t?void 0:t,argsProvider:"function"==typeof t?t:void 0})}}),this.messages=new Proxy({},{get:(t,i)=>(...t)=>Ni.resolveMessage(this.name,i,...t)})}}i.customElement("ft-i18n")(Ce);const Te=Ae.build("savedSearchesComponent"),Be={displaySavedSearchesHere:"Display saved searches here.",missingRole:"Saved search unavailable: missing role {0}.",keywords:"Keywords",language:"Language",sort:"Sort",period:"Period",relevance:"Relevance",lastUpdate:"Last update",lastWeek:"Less than one week",lastMonth:"Less than one month",lastYear:"Less than one year",customPeriod:"Custom period",search:"Search"},Ie=i.FtCssVariableFactory.extend("--ft-chip-color",i.designSystemVariables.colorOnSurface),Re={backgroundColor:i.FtCssVariableFactory.extend("--ft-chip-background-color",i.designSystemVariables.colorSurface),color:Ie,fontSize:i.FtCssVariableFactory.extend("--ft-chip-font-size",Pt.fontSize),iconSize:i.FtCssVariableFactory.create("--ft-chip-icon-size","SIZE","18px"),rippleColor:i.FtCssVariableFactory.extend("--ft-chip-ripple-color",Ie),horizontalPadding:i.FtCssVariableFactory.create("--ft-chip-horizontal-padding","SIZE","6px"),verticalPadding:i.FtCssVariableFactory.create("--ft-chip-vertical-padding","SIZE","6px"),colorOutline:i.FtCssVariableFactory.external(i.designSystemVariables.colorOutline,"Design system"),opacityDisabled:i.FtCssVariableFactory.external(i.designSystemVariables.colorOpacityDisabled,"Design system")},ze=i.FtCssVariableFactory.extend("--ft-chip-highlighted-color",i.FtCssVariableFactory.extend("--ft-chip-color",i.designSystemVariables.colorOnPrimary)),Ue={backgroundColor:i.FtCssVariableFactory.extend("--ft-chip-highlighted-background-color",i.FtCssVariableFactory.extend("--ft-chip-background-color",i.designSystemVariables.colorPrimary)),color:ze,rippleColor:i.FtCssVariableFactory.extend("--ft-chip-highlighted-ripple-color",ze)},Ne=i.FtCssVariableFactory.create("--ft-chip-dense-horizontal-padding","SIZE","4px"),je=i.FtCssVariableFactory.create("--ft-chip-dense-vertical-padding","SIZE","4px"),_e=[i.noTextSelect,e.css`
665
+ `:this.editorMode?"Select a context and a label key.":e.nothing}update(t){super.update(t),this.context&&this.key&&this.defaultMessage&&this.addI18nMessages(this.context,{[this.key]:this.defaultMessage})}}Ae.elementDefinitions={},Ae.styles=me,Ce([i.redux()],Ae.prototype,"editorMode",void 0),Ce([o.property()],Ae.prototype,"context",void 0),Ce([o.property()],Ae.prototype,"key",void 0),Ce([i.jsonProperty([])],Ae.prototype,"args",void 0),Ce([o.property()],Ae.prototype,"defaultMessage",void 0);class Te{static build(t){return new Te(t)}static fromGwt(t){return new Te(t)}constructor(t){this.name=t,this.properties=new Proxy({},{get:(t,i)=>{const e=i;return t=>({context:this.name,key:e,args:"function"==typeof t?void 0:t,argsProvider:"function"==typeof t?t:void 0})}}),this.messages=new Proxy({},{get:(t,i)=>(...t)=>Ni.resolveMessage(this.name,i,...t)})}}i.customElement("ft-i18n")(Ae);const Be=Te.build("savedSearchesComponent"),Ie={displaySavedSearchesHere:"Display saved searches here.",missingRole:"Saved search unavailable: missing role {0}.",keywords:"Keywords",language:"Language",sort:"Sort",period:"Period",relevance:"Relevance",lastUpdate:"Last update",lastWeek:"Less than one week",lastMonth:"Less than one month",lastYear:"Less than one year",customPeriod:"Custom period",search:"Search"},Re=i.FtCssVariableFactory.extend("--ft-chip-color",i.designSystemVariables.colorOnSurface),ze={backgroundColor:i.FtCssVariableFactory.extend("--ft-chip-background-color",i.designSystemVariables.colorSurface),color:Re,fontSize:i.FtCssVariableFactory.extend("--ft-chip-font-size",Pt.fontSize),iconSize:i.FtCssVariableFactory.create("--ft-chip-icon-size","SIZE","18px"),rippleColor:i.FtCssVariableFactory.extend("--ft-chip-ripple-color",Re),horizontalPadding:i.FtCssVariableFactory.create("--ft-chip-horizontal-padding","SIZE","6px"),verticalPadding:i.FtCssVariableFactory.create("--ft-chip-vertical-padding","SIZE","6px"),colorOutline:i.FtCssVariableFactory.external(i.designSystemVariables.colorOutline,"Design system"),opacityDisabled:i.FtCssVariableFactory.external(i.designSystemVariables.colorOpacityDisabled,"Design system")},Ue=i.FtCssVariableFactory.extend("--ft-chip-highlighted-color",i.FtCssVariableFactory.extend("--ft-chip-color",i.designSystemVariables.colorOnPrimary)),Ne={backgroundColor:i.FtCssVariableFactory.extend("--ft-chip-highlighted-background-color",i.FtCssVariableFactory.extend("--ft-chip-background-color",i.designSystemVariables.colorPrimary)),color:Ue,rippleColor:i.FtCssVariableFactory.extend("--ft-chip-highlighted-ripple-color",Ue)},je=i.FtCssVariableFactory.create("--ft-chip-dense-horizontal-padding","SIZE","4px"),_e=i.FtCssVariableFactory.create("--ft-chip-dense-vertical-padding","SIZE","4px"),Le=[i.noTextSelect,e.css`
666
666
  :host {
667
667
  display: inline-block;
668
668
  max-width: 100%;
@@ -678,20 +678,20 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
678
678
  box-sizing: border-box;
679
679
  pointer-events: auto;
680
680
 
681
- --ft-chip-internal-font-size: ${Re.fontSize};
681
+ --ft-chip-internal-font-size: ${ze.fontSize};
682
682
  --ft-chip-internal-line-height: max(20px, calc(var(--ft-chip-internal-font-size) + 2px));
683
- ${i.setVariable(Ki.size,Re.iconSize)};
684
- --ft-chip-internal-vertical-padding: ${Re.verticalPadding};
685
- --ft-chip-internal-horizontal-padding: ${Re.horizontalPadding};
683
+ ${i.setVariable(Wi.size,ze.iconSize)};
684
+ --ft-chip-internal-vertical-padding: ${ze.verticalPadding};
685
+ --ft-chip-internal-horizontal-padding: ${ze.horizontalPadding};
686
686
  --ft-chip-internal-icon-padding: 3px;
687
- --ft-chip-internal-content-height: max(var(--ft-chip-internal-line-height), ${Re.iconSize});
687
+ --ft-chip-internal-content-height: max(var(--ft-chip-internal-line-height), ${ze.iconSize});
688
688
 
689
- border: 1px solid ${Re.colorOutline};
690
- color: ${Re.color};
691
- ${i.setVariable(l.color,Re.rippleColor)};
689
+ border: 1px solid ${ze.colorOutline};
690
+ color: ${ze.color};
691
+ ${i.setVariable(l.color,ze.rippleColor)};
692
692
  border-radius: calc(var(--ft-chip-internal-content-height) / 2 + var(--ft-chip-internal-vertical-padding));
693
693
  padding: calc(var(--ft-chip-internal-vertical-padding) - 1px) calc(var(--ft-chip-internal-horizontal-padding) - 1px);
694
- background-color: ${Re.backgroundColor};
694
+ background-color: ${ze.backgroundColor};
695
695
  line-height: var(--ft-chip-internal-content-height);
696
696
  }
697
697
 
@@ -701,8 +701,8 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
701
701
 
702
702
  .ft-chip--dense {
703
703
  --ft-chip-internal-icon-padding: 3px;
704
- --ft-chip-internal-vertical-padding: ${je};
705
- --ft-chip-internal-horizontal-padding: ${Ne};
704
+ --ft-chip-internal-vertical-padding: ${_e};
705
+ --ft-chip-internal-horizontal-padding: ${je};
706
706
  --ft-chip-internal-line-height: max(16px, calc(var(--ft-chip-internal-font-size) + 2px));
707
707
  }
708
708
 
@@ -714,15 +714,15 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
714
714
  cursor: default;
715
715
  pointer-events: none;
716
716
  filter: grayscale(1);
717
- opacity: ${Re.opacityDisabled};
717
+ opacity: ${ze.opacityDisabled};
718
718
  }
719
719
 
720
720
  .ft-chip--highlighted {
721
721
  border: none;
722
722
  padding: var(--ft-chip-internal-vertical-padding) var(--ft-chip-internal-horizontal-padding);
723
- background-color: ${Ue.backgroundColor};
724
- ${i.setVariable(l.color,Ue.rippleColor)};
725
- color: ${Ue.color};
723
+ background-color: ${Ne.backgroundColor};
724
+ ${i.setVariable(l.color,Ne.rippleColor)};
725
+ color: ${Ne.color};
726
726
  }
727
727
 
728
728
  .ft-chip--clickable {
@@ -752,9 +752,9 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
752
752
  }
753
753
 
754
754
  .ft-chip--icon-button {
755
- ${i.setVariable(he.iconSize,Re.iconSize)};
756
- ${i.setVariable(he.horizontalPadding,"var(--ft-chip-internal-icon-padding)")};
757
- ${i.setVariable(he.verticalPadding,"var(--ft-chip-internal-icon-padding)")};
755
+ ${i.setVariable(ce.iconSize,ze.iconSize)};
756
+ ${i.setVariable(ce.horizontalPadding,"var(--ft-chip-internal-icon-padding)")};
757
+ ${i.setVariable(ce.verticalPadding,"var(--ft-chip-internal-icon-padding)")};
758
758
  margin: calc((-1) * var(--ft-chip-internal-icon-padding));
759
759
  }
760
760
 
@@ -799,7 +799,7 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
799
799
  .ft-chip:not(.ft-chip--trailing-icon) .ft-chip--icon-button {
800
800
  order: -1;
801
801
  }
802
- `];var Le=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class De extends CustomEvent{constructor(){super("icon-click")}}class Pe extends i.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.icon=void 0,this.trailingIcon=!1}render(){const t={"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":i.isSafari};return e.html`
802
+ `];var De=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Pe extends CustomEvent{constructor(){super("icon-click")}}class Me extends i.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.icon=void 0,this.trailingIcon=!1}render(){const t={"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":i.isSafari};return e.html`
803
803
  <div class="${n.classMap(t)}"
804
804
  aria-label="${this.getLabel()}"
805
805
  tabindex="${this.interactionsOnChip?0:-1}"
@@ -822,7 +822,7 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
822
822
  <div class="ft-chip--icon-container ft-no-text-select">
823
823
  <ft-icon .variant=${this.iconVariant} .value="${this.internalIcon}"></ft-icon>
824
824
  </div>
825
- `}onKeyUp(t){this.interactionsOnChip&&["Enter"," "].includes(t.key)&&t.target.click()}onIconKeyUp(t){this.interactionsOnIcon&&["Enter"," "].includes(t.key)&&(t.stopPropagation(),this.dispatchEvent(new De))}onIconClick(t){this.interactionsOnIcon&&(t.stopPropagation(),this.dispatchEvent(new De))}getLabel(){return this.label||this.textContent}get textContent(){var t,i;return null!==(i=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==i?i:""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}get internalIcon(){return this.icon||(this.removable?"close":void 0)}}Pe.elementDefinitions={"ft-ripple":b,"ft-typography":bi,"ft-icon":Yi,"ft-button":be},Pe.styles=_e,Le([o.property({type:Boolean})],Pe.prototype,"highlighted",void 0),Le([o.property({type:Boolean})],Pe.prototype,"removable",void 0),Le([o.property({type:Boolean})],Pe.prototype,"disabled",void 0),Le([o.property({type:Boolean})],Pe.prototype,"clickable",void 0),Le([o.property({type:Boolean})],Pe.prototype,"iconClickable",void 0),Le([o.property({type:Boolean})],Pe.prototype,"dense",void 0),Le([o.property({type:Boolean})],Pe.prototype,"multiLine",void 0),Le([o.property()],Pe.prototype,"label",void 0),Le([o.property()],Pe.prototype,"iconLabel",void 0),Le([o.property()],Pe.prototype,"icon",void 0),Le([o.property()],Pe.prototype,"iconVariant",void 0),Le([o.property({type:Boolean})],Pe.prototype,"trailingIcon",void 0),Le([o.query("ft-typography slot")],Pe.prototype,"slottedContent",void 0),i.customElement("ft-chip")(Pe);var Me,Fe,He,Ze,Ke,We,Ge,qe,Ye,Ve=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Xe extends(Se(Fi)){constructor(){super(),this.showDescription=!1,this.showSearchFilters=!1,this.showSearchButton=!1,this.showAlertStatus=!1,this.selected=!1,this.addI18nContext(Te,Be)}render(){var t;return e.html`
825
+ `}onKeyUp(t){this.interactionsOnChip&&["Enter"," "].includes(t.key)&&t.target.click()}onIconKeyUp(t){this.interactionsOnIcon&&["Enter"," "].includes(t.key)&&(t.stopPropagation(),this.dispatchEvent(new Pe))}onIconClick(t){this.interactionsOnIcon&&(t.stopPropagation(),this.dispatchEvent(new Pe))}getLabel(){return this.label||this.textContent}get textContent(){var t,i;return null!==(i=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==i?i:""}hasTextContent(){return this.textContent.length>0}onSlotchange(){this.requestUpdate()}get internalIcon(){return this.icon||(this.removable?"close":void 0)}}Me.elementDefinitions={"ft-ripple":b,"ft-typography":bi,"ft-icon":Vi,"ft-button":xe},Me.styles=Le,De([o.property({type:Boolean})],Me.prototype,"highlighted",void 0),De([o.property({type:Boolean})],Me.prototype,"removable",void 0),De([o.property({type:Boolean})],Me.prototype,"disabled",void 0),De([o.property({type:Boolean})],Me.prototype,"clickable",void 0),De([o.property({type:Boolean})],Me.prototype,"iconClickable",void 0),De([o.property({type:Boolean})],Me.prototype,"dense",void 0),De([o.property({type:Boolean})],Me.prototype,"multiLine",void 0),De([o.property()],Me.prototype,"label",void 0),De([o.property()],Me.prototype,"iconLabel",void 0),De([o.property()],Me.prototype,"icon",void 0),De([o.property()],Me.prototype,"iconVariant",void 0),De([o.property({type:Boolean})],Me.prototype,"trailingIcon",void 0),De([o.query("ft-typography slot")],Me.prototype,"slottedContent",void 0),i.customElement("ft-chip")(Me);var Fe,He,Ze,Ke,We,Ge,qe,Ye,Ve,Xe=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class Je extends(ke(Hi)){constructor(){super(),this.showDescription=!1,this.showSearchFilters=!1,this.showSearchButton=!1,this.showAlertStatus=!1,this.selected=!1,this.addI18nContext(Be,Ie)}render(){var t;return e.html`
826
826
  <ft-card title="${null===(t=this.search)||void 0===t?void 0:t.title}" clickable ?selected="${this.selected}">
827
827
  ${this.renderAlertStatus()}
828
828
  <div id="container">
@@ -831,13 +831,13 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
831
831
  ${this.renderSearchButton()}
832
832
  </div>
833
833
  </ft-card>
834
- `}renderDescription(){var t;return this.showDescription?e.html`<div id="description" class="content">${null===(t=this.search)||void 0===t?void 0:t.description}</div>`:e.nothing}renderSearchButton(){return this.showSearchButton?e.html`<div id="searchButton" class="content"><ft-button id="search" icon="search">${Te.messages.search()}</ft-button></div>`:e.nothing}renderAlertStatus(){var t;return this.showAlertStatus&&(null===(t=this.search)||void 0===t?void 0:t.alert)?e.html`<ft-icon id="alertStatus" slot="header">alert</ft-icon>`:e.nothing}renderSearchFilters(){var t,i,o,n,r,s,a,l,h,c,p,d,f,u;return this.showSearchFilters?e.html`<div id="searchFilters" class="content">
835
- ${null!==(i=null===(t=this.search)||void 0===t?void 0:t.searchRequest.query.length)&&void 0!==i&&i?this.renderMetadata(Te.messages.keywords(),null===(o=this.search)||void 0===o?void 0:o.searchRequest.query,!0):e.nothing}
834
+ `}renderDescription(){var t;return this.showDescription?e.html`<div id="description" class="content">${null===(t=this.search)||void 0===t?void 0:t.description}</div>`:e.nothing}renderSearchButton(){return this.showSearchButton?e.html`<div id="searchButton" class="content"><ft-button id="search" icon="search">${Be.messages.search()}</ft-button></div>`:e.nothing}renderAlertStatus(){var t;return this.showAlertStatus&&(null===(t=this.search)||void 0===t?void 0:t.alert)?e.html`<ft-icon id="alertStatus" slot="header">alert</ft-icon>`:e.nothing}renderSearchFilters(){var t,i,o,n,r,s,a,l,h,c,p,d,f,u;return this.showSearchFilters?e.html`<div id="searchFilters" class="content">
835
+ ${null!==(i=null===(t=this.search)||void 0===t?void 0:t.searchRequest.query.length)&&void 0!==i&&i?this.renderMetadata(Be.messages.keywords(),null===(o=this.search)||void 0===o?void 0:o.searchRequest.query,!0):e.nothing}
836
836
  ${null===(n=this.search)||void 0===n?void 0:n.searchRequest.filters.map((t=>this.renderMetadata(t.label,t.values)))}
837
- ${null!==(a=null===(s=null===(r=this.search)||void 0===r?void 0:r.searchRequest.contentLocale)||void 0===s?void 0:s.length)&&void 0!==a&&a?this.renderMetadata(Te.messages.language(),null===(l=this.search)||void 0===l?void 0:l.searchRequest.contentLocale,!0):e.nothing}
838
- ${null!==(p=null===(c=null===(h=this.search)||void 0===h?void 0:h.searchRequest.sort[0])||void 0===c?void 0:c.key.length)&&void 0!==p&&p?this.renderMetadata(Te.messages.sort(),this.mapSortKey(null===(d=this.search)||void 0===d?void 0:d.searchRequest.sort[0].key),!0):e.nothing}
839
- ${(null===(f=this.search)||void 0===f?void 0:f.searchRequest.periodFilter)?this.renderMetadata(Te.messages.period(),this.mapPeriodFilter(null===(u=this.search)||void 0===u?void 0:u.searchRequest.periodFilter),!0):e.nothing}
840
- </div>`:e.nothing}renderMetadata(t,i,o=!1){return e.html`<ft-chip dense ?highlighted=${o}><span class="metadata-label">${t}</span><span class="metadata-values">${Array.isArray(i)?i.join(", "):i}</span></ft-chip>`}mapSortKey(t){switch(t){case"afs:relevance":return Te.messages.relevance();case"ft:lastEdition":return Te.messages.lastUpdate();default:return t}}mapPeriodFilter(t){switch(t.periodType){case"LAST_WEEK":return Te.messages.lastWeek();case"LAST_MONTH":return Te.messages.lastMonth();case"LAST_YEAR":return Te.messages.lastYear();case"CUSTOM":return Te.messages.customPeriod();default:return"--"}}}Xe.elementDefinitions={"ft-icon":Yi,"ft-card":Oi,"ft-chip":Pe,"ft-button":be},Xe.styles=e.css`
837
+ ${null!==(a=null===(s=null===(r=this.search)||void 0===r?void 0:r.searchRequest.contentLocale)||void 0===s?void 0:s.length)&&void 0!==a&&a?this.renderMetadata(Be.messages.language(),null===(l=this.search)||void 0===l?void 0:l.searchRequest.contentLocale,!0):e.nothing}
838
+ ${null!==(p=null===(c=null===(h=this.search)||void 0===h?void 0:h.searchRequest.sort[0])||void 0===c?void 0:c.key.length)&&void 0!==p&&p?this.renderMetadata(Be.messages.sort(),this.mapSortKey(null===(d=this.search)||void 0===d?void 0:d.searchRequest.sort[0].key),!0):e.nothing}
839
+ ${(null===(f=this.search)||void 0===f?void 0:f.searchRequest.periodFilter)?this.renderMetadata(Be.messages.period(),this.mapPeriodFilter(null===(u=this.search)||void 0===u?void 0:u.searchRequest.periodFilter),!0):e.nothing}
840
+ </div>`:e.nothing}renderMetadata(t,i,o=!1){return e.html`<ft-chip dense ?highlighted=${o}><span class="metadata-label">${t}</span><span class="metadata-values">${Array.isArray(i)?i.join(", "):i}</span></ft-chip>`}mapSortKey(t){switch(t){case"afs:relevance":return Be.messages.relevance();case"ft:lastEdition":return Be.messages.lastUpdate();default:return t}}mapPeriodFilter(t){switch(t.periodType){case"LAST_WEEK":return Be.messages.lastWeek();case"LAST_MONTH":return Be.messages.lastMonth();case"LAST_YEAR":return Be.messages.lastYear();case"CUSTOM":return Be.messages.customPeriod();default:return"--"}}}Je.elementDefinitions={"ft-icon":Vi,"ft-card":Oi,"ft-chip":Me,"ft-button":xe},Je.styles=e.css`
841
841
  ft-card {
842
842
  ${i.setVariable(xi.outlineStyle,Ci.inactiveSearchBorderStyle)};
843
843
  ${i.setVariable(xi.outlineWidth,Ci.inactiveSearchBorderWidth)};
@@ -855,11 +855,11 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
855
855
  }
856
856
 
857
857
  #search {
858
- ${i.setVariable(he.color,Ci.inactiveButtonTextColor)};
858
+ ${i.setVariable(ce.color,Ci.inactiveButtonTextColor)};
859
859
  }
860
860
 
861
861
  ft-card[selected] #search {
862
- ${i.setVariable(he.color,Ci.activeButtonTextColor)};
862
+ ${i.setVariable(ce.color,Ci.activeButtonTextColor)};
863
863
  }
864
864
 
865
865
  #searchFilters {
@@ -890,9 +890,9 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
890
890
  #alertStatus {
891
891
  color: ${Ci.color};
892
892
  }
893
- `,Ve([o.property()],Xe.prototype,"search",void 0),Ve([o.property({type:Boolean})],Xe.prototype,"showDescription",void 0),Ve([o.property({type:Boolean})],Xe.prototype,"showSearchFilters",void 0),Ve([o.property({type:Boolean})],Xe.prototype,"showSearchButton",void 0),Ve([o.property({type:Boolean})],Xe.prototype,"showAlertStatus",void 0),Ve([o.property({type:Boolean})],Xe.prototype,"selected",void 0),function(t){!function(i){var e={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch(t){return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};if(e.arrayBuffer)var o=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],n=ArrayBuffer.isView||function(t){return t&&o.indexOf(Object.prototype.toString.call(t))>-1};function r(t){if("string"!=typeof t&&(t=String(t)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(t))throw new TypeError("Invalid character in header field name");return t.toLowerCase()}function s(t){return"string"!=typeof t&&(t=String(t)),t}function a(t){var i={next:function(){var i=t.shift();return{done:void 0===i,value:i}}};return e.iterable&&(i[Symbol.iterator]=function(){return i}),i}function l(t){this.map={},t instanceof l?t.forEach((function(t,i){this.append(i,t)}),this):Array.isArray(t)?t.forEach((function(t){this.append(t[0],t[1])}),this):t&&Object.getOwnPropertyNames(t).forEach((function(i){this.append(i,t[i])}),this)}function h(t){if(t.bodyUsed)return Promise.reject(new TypeError("Already read"));t.bodyUsed=!0}function c(t){return new Promise((function(i,e){t.onload=function(){i(t.result)},t.onerror=function(){e(t.error)}}))}function p(t){var i=new FileReader,e=c(i);return i.readAsArrayBuffer(t),e}function d(t){if(t.slice)return t.slice(0);var i=new Uint8Array(t.byteLength);return i.set(new Uint8Array(t)),i.buffer}function f(){return this.bodyUsed=!1,this._initBody=function(t){var i;this._bodyInit=t,t?"string"==typeof t?this._bodyText=t:e.blob&&Blob.prototype.isPrototypeOf(t)?this._bodyBlob=t:e.formData&&FormData.prototype.isPrototypeOf(t)?this._bodyFormData=t:e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)?this._bodyText=t.toString():e.arrayBuffer&&e.blob&&((i=t)&&DataView.prototype.isPrototypeOf(i))?(this._bodyArrayBuffer=d(t.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):e.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(t)||n(t))?this._bodyArrayBuffer=d(t):this._bodyText=t=Object.prototype.toString.call(t):this._bodyText="",this.headers.get("content-type")||("string"==typeof t?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},e.blob&&(this.blob=function(){var t=h(this);if(t)return t;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?h(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(p)}),this.text=function(){var t,i,e,o=h(this);if(o)return o;if(this._bodyBlob)return t=this._bodyBlob,i=new FileReader,e=c(i),i.readAsText(t),e;if(this._bodyArrayBuffer)return Promise.resolve(function(t){for(var i=new Uint8Array(t),e=new Array(i.length),o=0;o<i.length;o++)e[o]=String.fromCharCode(i[o]);return e.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},e.formData&&(this.formData=function(){return this.text().then(g)}),this.json=function(){return this.text().then(JSON.parse)},this}l.prototype.append=function(t,i){t=r(t),i=s(i);var e=this.map[t];this.map[t]=e?e+", "+i:i},l.prototype.delete=function(t){delete this.map[r(t)]},l.prototype.get=function(t){return t=r(t),this.has(t)?this.map[t]:null},l.prototype.has=function(t){return this.map.hasOwnProperty(r(t))},l.prototype.set=function(t,i){this.map[r(t)]=s(i)},l.prototype.forEach=function(t,i){for(var e in this.map)this.map.hasOwnProperty(e)&&t.call(i,this.map[e],e,this)},l.prototype.keys=function(){var t=[];return this.forEach((function(i,e){t.push(e)})),a(t)},l.prototype.values=function(){var t=[];return this.forEach((function(i){t.push(i)})),a(t)},l.prototype.entries=function(){var t=[];return this.forEach((function(i,e){t.push([e,i])})),a(t)},e.iterable&&(l.prototype[Symbol.iterator]=l.prototype.entries);var u=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function v(t,i){var e,o,n=(i=i||{}).body;if(t instanceof v){if(t.bodyUsed)throw new TypeError("Already read");this.url=t.url,this.credentials=t.credentials,i.headers||(this.headers=new l(t.headers)),this.method=t.method,this.mode=t.mode,this.signal=t.signal,n||null==t._bodyInit||(n=t._bodyInit,t.bodyUsed=!0)}else this.url=String(t);if(this.credentials=i.credentials||this.credentials||"same-origin",!i.headers&&this.headers||(this.headers=new l(i.headers)),this.method=(e=i.method||this.method||"GET",o=e.toUpperCase(),u.indexOf(o)>-1?o:e),this.mode=i.mode||this.mode||null,this.signal=i.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&n)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(n)}function g(t){var i=new FormData;return t.trim().split("&").forEach((function(t){if(t){var e=t.split("="),o=e.shift().replace(/\+/g," "),n=e.join("=").replace(/\+/g," ");i.append(decodeURIComponent(o),decodeURIComponent(n))}})),i}function y(t,i){i||(i={}),this.type="default",this.status=void 0===i.status?200:i.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in i?i.statusText:"OK",this.headers=new l(i.headers),this.url=i.url||"",this._initBody(t)}v.prototype.clone=function(){return new v(this,{body:this._bodyInit})},f.call(v.prototype),f.call(y.prototype),y.prototype.clone=function(){return new y(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new l(this.headers),url:this.url})},y.error=function(){var t=new y(null,{status:0,statusText:""});return t.type="error",t};var b=[301,302,303,307,308];y.redirect=function(t,i){if(-1===b.indexOf(i))throw new RangeError("Invalid status code");return new y(null,{status:i,headers:{location:t}})},i.DOMException=t.DOMException;try{new i.DOMException}catch(t){i.DOMException=function(t,i){this.message=t,this.name=i;var e=Error(t);this.stack=e.stack},i.DOMException.prototype=Object.create(Error.prototype),i.DOMException.prototype.constructor=i.DOMException}function x(t,o){return new Promise((function(n,r){var s=new v(t,o);if(s.signal&&s.signal.aborted)return r(new i.DOMException("Aborted","AbortError"));var a=new XMLHttpRequest;function h(){a.abort()}a.onload=function(){var t,i,e={status:a.status,statusText:a.statusText,headers:(t=a.getAllResponseHeaders()||"",i=new l,t.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(t){var e=t.split(":"),o=e.shift().trim();if(o){var n=e.join(":").trim();i.append(o,n)}})),i)};e.url="responseURL"in a?a.responseURL:e.headers.get("X-Request-URL");var o="response"in a?a.response:a.responseText;n(new y(o,e))},a.onerror=function(){r(new TypeError("Network request failed"))},a.ontimeout=function(){r(new TypeError("Network request failed"))},a.onabort=function(){r(new i.DOMException("Aborted","AbortError"))},a.open(s.method,s.url,!0),"include"===s.credentials?a.withCredentials=!0:"omit"===s.credentials&&(a.withCredentials=!1),"responseType"in a&&e.blob&&(a.responseType="blob"),s.headers.forEach((function(t,i){a.setRequestHeader(i,t)})),s.signal&&(s.signal.addEventListener("abort",h),a.onreadystatechange=function(){4===a.readyState&&s.signal.removeEventListener("abort",h)}),a.send(void 0===s._bodyInit?null:s._bodyInit)}))}x.polyfill=!0,t.fetch||(t.fetch=x,t.Headers=l,t.Request=v,t.Response=y),i.Headers=l,i.Request=v,i.Response=y,i.fetch=x,Object.defineProperty(i,"t",{value:!0})}({})}("undefined"!=typeof self?self:void 0),function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"}(Me||(Me={})),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"}(Fe||(Fe={})),function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"}(He||(He={})),function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"}(Ze||(Ze={})),function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK"}(Ke||(Ke={})),function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"}(We||(We={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK"}(Ge||(Ge={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC"}(qe||(qe={})),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.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN",t.DEVELOPER="DEVELOPER"}(Ye||(Ye={})),Ye.PERSONAL_BOOK_SHARE_USER,Ye.PERSONAL_BOOK_USER,Ye.HTML_EXPORT_USER,Ye.PERSONAL_BOOK_USER,Ye.PDF_EXPORT_USER,Ye.PERSONAL_BOOK_USER,Ye.KHUB_ADMIN,Ye.CONTENT_PUBLISHER,Ye.ADMIN,Ye.KHUB_ADMIN,Ye.USERS_ADMIN,Ye.PORTAL_ADMIN,Ye.DEVELOPER,Ye.BETA_USER,Ye.DEBUG_USER;class Je{async listMySearches(){var t;return(null===(t=Bi.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await Ii.await()).listMySearches(Bi.getState().session.profile.userId):[]}}const Qe=i.FtReduxStore.get({name:"ft-user-assets",reducers:{setSavedSearches:(t,i)=>{t.savedSearches=i.payload}},initialState:{savedSearches:void 0}});const to=new class{clear(){this.clearMySearches()}clearMySearches(){Qe.actions.setSavedSearches(void 0)}async reloadMySearches(){const t=new Je,i=await t.listMySearches();Qe.actions.setSavedSearches(i)}};var io=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class eo extends(Se(Fi)){constructor(){super(),this.showDescription=!1,this.showSearchFilters=!1,this.showSearchButton=!1,this.showAlertStatus=!1,this.editorMode=!1,this.requiredRole=Ye.SAVED_SEARCH_USER,this.addStore(Bi),this.addStore(Qe),this.addI18nContext(Te,Be)}render(){var t;return this.editorMode&&!this.userHasRights?e.html`
894
- <ft-typography>${Te.messages.missingRole(this.requiredRole)}</ft-typography>`:this.editorMode&&this.isEmpty?e.html`
895
- <ft-typography>${Te.messages.displaySavedSearchesHere()}</ft-typography>`:this.userHasRights&&!this.isEmpty?e.html`
893
+ `,Xe([o.property()],Je.prototype,"search",void 0),Xe([o.property({type:Boolean})],Je.prototype,"showDescription",void 0),Xe([o.property({type:Boolean})],Je.prototype,"showSearchFilters",void 0),Xe([o.property({type:Boolean})],Je.prototype,"showSearchButton",void 0),Xe([o.property({type:Boolean})],Je.prototype,"showAlertStatus",void 0),Xe([o.property({type:Boolean})],Je.prototype,"selected",void 0),function(t){!function(i){var e={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch(t){return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};if(e.arrayBuffer)var o=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],n=ArrayBuffer.isView||function(t){return t&&o.indexOf(Object.prototype.toString.call(t))>-1};function r(t){if("string"!=typeof t&&(t=String(t)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(t))throw new TypeError("Invalid character in header field name");return t.toLowerCase()}function s(t){return"string"!=typeof t&&(t=String(t)),t}function a(t){var i={next:function(){var i=t.shift();return{done:void 0===i,value:i}}};return e.iterable&&(i[Symbol.iterator]=function(){return i}),i}function l(t){this.map={},t instanceof l?t.forEach((function(t,i){this.append(i,t)}),this):Array.isArray(t)?t.forEach((function(t){this.append(t[0],t[1])}),this):t&&Object.getOwnPropertyNames(t).forEach((function(i){this.append(i,t[i])}),this)}function h(t){if(t.bodyUsed)return Promise.reject(new TypeError("Already read"));t.bodyUsed=!0}function c(t){return new Promise((function(i,e){t.onload=function(){i(t.result)},t.onerror=function(){e(t.error)}}))}function p(t){var i=new FileReader,e=c(i);return i.readAsArrayBuffer(t),e}function d(t){if(t.slice)return t.slice(0);var i=new Uint8Array(t.byteLength);return i.set(new Uint8Array(t)),i.buffer}function f(){return this.bodyUsed=!1,this._initBody=function(t){var i;this._bodyInit=t,t?"string"==typeof t?this._bodyText=t:e.blob&&Blob.prototype.isPrototypeOf(t)?this._bodyBlob=t:e.formData&&FormData.prototype.isPrototypeOf(t)?this._bodyFormData=t:e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)?this._bodyText=t.toString():e.arrayBuffer&&e.blob&&((i=t)&&DataView.prototype.isPrototypeOf(i))?(this._bodyArrayBuffer=d(t.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):e.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(t)||n(t))?this._bodyArrayBuffer=d(t):this._bodyText=t=Object.prototype.toString.call(t):this._bodyText="",this.headers.get("content-type")||("string"==typeof t?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},e.blob&&(this.blob=function(){var t=h(this);if(t)return t;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?h(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(p)}),this.text=function(){var t,i,e,o=h(this);if(o)return o;if(this._bodyBlob)return t=this._bodyBlob,i=new FileReader,e=c(i),i.readAsText(t),e;if(this._bodyArrayBuffer)return Promise.resolve(function(t){for(var i=new Uint8Array(t),e=new Array(i.length),o=0;o<i.length;o++)e[o]=String.fromCharCode(i[o]);return e.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},e.formData&&(this.formData=function(){return this.text().then(g)}),this.json=function(){return this.text().then(JSON.parse)},this}l.prototype.append=function(t,i){t=r(t),i=s(i);var e=this.map[t];this.map[t]=e?e+", "+i:i},l.prototype.delete=function(t){delete this.map[r(t)]},l.prototype.get=function(t){return t=r(t),this.has(t)?this.map[t]:null},l.prototype.has=function(t){return this.map.hasOwnProperty(r(t))},l.prototype.set=function(t,i){this.map[r(t)]=s(i)},l.prototype.forEach=function(t,i){for(var e in this.map)this.map.hasOwnProperty(e)&&t.call(i,this.map[e],e,this)},l.prototype.keys=function(){var t=[];return this.forEach((function(i,e){t.push(e)})),a(t)},l.prototype.values=function(){var t=[];return this.forEach((function(i){t.push(i)})),a(t)},l.prototype.entries=function(){var t=[];return this.forEach((function(i,e){t.push([e,i])})),a(t)},e.iterable&&(l.prototype[Symbol.iterator]=l.prototype.entries);var u=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function v(t,i){var e,o,n=(i=i||{}).body;if(t instanceof v){if(t.bodyUsed)throw new TypeError("Already read");this.url=t.url,this.credentials=t.credentials,i.headers||(this.headers=new l(t.headers)),this.method=t.method,this.mode=t.mode,this.signal=t.signal,n||null==t._bodyInit||(n=t._bodyInit,t.bodyUsed=!0)}else this.url=String(t);if(this.credentials=i.credentials||this.credentials||"same-origin",!i.headers&&this.headers||(this.headers=new l(i.headers)),this.method=(e=i.method||this.method||"GET",o=e.toUpperCase(),u.indexOf(o)>-1?o:e),this.mode=i.mode||this.mode||null,this.signal=i.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&n)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(n)}function g(t){var i=new FormData;return t.trim().split("&").forEach((function(t){if(t){var e=t.split("="),o=e.shift().replace(/\+/g," "),n=e.join("=").replace(/\+/g," ");i.append(decodeURIComponent(o),decodeURIComponent(n))}})),i}function y(t,i){i||(i={}),this.type="default",this.status=void 0===i.status?200:i.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in i?i.statusText:"OK",this.headers=new l(i.headers),this.url=i.url||"",this._initBody(t)}v.prototype.clone=function(){return new v(this,{body:this._bodyInit})},f.call(v.prototype),f.call(y.prototype),y.prototype.clone=function(){return new y(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new l(this.headers),url:this.url})},y.error=function(){var t=new y(null,{status:0,statusText:""});return t.type="error",t};var b=[301,302,303,307,308];y.redirect=function(t,i){if(-1===b.indexOf(i))throw new RangeError("Invalid status code");return new y(null,{status:i,headers:{location:t}})},i.DOMException=t.DOMException;try{new i.DOMException}catch(t){i.DOMException=function(t,i){this.message=t,this.name=i;var e=Error(t);this.stack=e.stack},i.DOMException.prototype=Object.create(Error.prototype),i.DOMException.prototype.constructor=i.DOMException}function x(t,o){return new Promise((function(n,r){var s=new v(t,o);if(s.signal&&s.signal.aborted)return r(new i.DOMException("Aborted","AbortError"));var a=new XMLHttpRequest;function h(){a.abort()}a.onload=function(){var t,i,e={status:a.status,statusText:a.statusText,headers:(t=a.getAllResponseHeaders()||"",i=new l,t.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(t){var e=t.split(":"),o=e.shift().trim();if(o){var n=e.join(":").trim();i.append(o,n)}})),i)};e.url="responseURL"in a?a.responseURL:e.headers.get("X-Request-URL");var o="response"in a?a.response:a.responseText;n(new y(o,e))},a.onerror=function(){r(new TypeError("Network request failed"))},a.ontimeout=function(){r(new TypeError("Network request failed"))},a.onabort=function(){r(new i.DOMException("Aborted","AbortError"))},a.open(s.method,s.url,!0),"include"===s.credentials?a.withCredentials=!0:"omit"===s.credentials&&(a.withCredentials=!1),"responseType"in a&&e.blob&&(a.responseType="blob"),s.headers.forEach((function(t,i){a.setRequestHeader(i,t)})),s.signal&&(s.signal.addEventListener("abort",h),a.onreadystatechange=function(){4===a.readyState&&s.signal.removeEventListener("abort",h)}),a.send(void 0===s._bodyInit?null:s._bodyInit)}))}x.polyfill=!0,t.fetch||(t.fetch=x,t.Headers=l,t.Request=v,t.Response=y),i.Headers=l,i.Request=v,i.Response=y,i.fetch=x,Object.defineProperty(i,"t",{value:!0})}({})}("undefined"!=typeof self?self:void 0),function(t){t.black="black",t.green="green",t.blue="blue",t.purple="purple",t.red="red",t.orange="orange",t.yellow="yellow"}(Fe||(Fe={})),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"}(He||(He={})),function(t){t.STARS="STARS",t.LIKE="LIKE",t.DICHOTOMOUS="DICHOTOMOUS",t.NO_RATING="NO_RATING"}(Ze||(Ze={})),function(t){t.LAST_WEEK="LAST_WEEK",t.LAST_MONTH="LAST_MONTH",t.LAST_YEAR="LAST_YEAR",t.CUSTOM="CUSTOM"}(Ke||(Ke={})),function(t){t.ARTICLE="ARTICLE",t.BOOK="BOOK"}(We||(We={})),function(t){t.FLUIDTOPICS="FLUIDTOPICS",t.EXTERNAL="EXTERNAL"}(Ge||(Ge={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC",t.PERSONAL_BOOK="PERSONAL_BOOK",t.SHARED_BOOK="SHARED_BOOK"}(qe||(qe={})),function(t){t.MAP="MAP",t.DOCUMENT="DOCUMENT",t.TOPIC="TOPIC"}(Ye||(Ye={})),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.CONTENT_PUBLISHER="CONTENT_PUBLISHER",t.KHUB_ADMIN="KHUB_ADMIN",t.USERS_ADMIN="USERS_ADMIN",t.PORTAL_ADMIN="PORTAL_ADMIN",t.ADMIN="ADMIN",t.DEVELOPER="DEVELOPER"}(Ve||(Ve={})),Ve.PERSONAL_BOOK_SHARE_USER,Ve.PERSONAL_BOOK_USER,Ve.HTML_EXPORT_USER,Ve.PERSONAL_BOOK_USER,Ve.PDF_EXPORT_USER,Ve.PERSONAL_BOOK_USER,Ve.KHUB_ADMIN,Ve.CONTENT_PUBLISHER,Ve.ADMIN,Ve.KHUB_ADMIN,Ve.USERS_ADMIN,Ve.PORTAL_ADMIN,Ve.DEVELOPER,Ve.BETA_USER,Ve.DEBUG_USER;class Qe{async listMySearches(){var t;return(null===(t=Bi.getState().session)||void 0===t?void 0:t.sessionAuthenticated)?(await Ii.await()).listMySearches(Bi.getState().session.profile.userId):[]}}const to=i.FtReduxStore.get({name:"ft-user-assets",reducers:{setSavedSearches:(t,i)=>{t.savedSearches=i.payload}},initialState:{savedSearches:void 0}});const io=new class{clear(){this.clearMySearches()}clearMySearches(){to.actions.setSavedSearches(void 0)}async reloadMySearches(){const t=new Qe,i=await t.listMySearches();to.actions.setSavedSearches(i)}};var eo=function(t,i,e,o){for(var n,r=arguments.length,s=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,a=t.length-1;a>=0;a--)(n=t[a])&&(s=(r<3?n(s):r>3?n(i,e,s):n(i,e))||s);return r>3&&s&&Object.defineProperty(i,e,s),s};class oo extends(ke(Hi)){constructor(){super(),this.showDescription=!1,this.showSearchFilters=!1,this.showSearchButton=!1,this.showAlertStatus=!1,this.editorMode=!1,this.requiredRole=Ve.SAVED_SEARCH_USER,this.addStore(Bi),this.addStore(to),this.addI18nContext(Be,Ie)}render(){var t;return this.editorMode&&!this.userHasRights?e.html`
894
+ <ft-typography>${Be.messages.missingRole(this.requiredRole)}</ft-typography>`:this.editorMode&&this.isEmpty?e.html`
895
+ <ft-typography>${Be.messages.displaySavedSearchesHere()}</ft-typography>`:this.userHasRights&&!this.isEmpty?e.html`
896
896
  <div id="container">
897
897
  ${s.repeat(null!==(t=this.savedSearches)&&void 0!==t?t:[],(t=>t.id),(t=>e.html`
898
898
  <ft-search-saved-search
@@ -911,4 +911,4 @@ const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void
911
911
  display: none !important;
912
912
  }
913
913
  </style>
914
- `}get userHasRights(){var t;return!!(null===(t=this.user)||void 0===t?void 0:t.roles.includes(this.requiredRole))}get isEmpty(){var t;return 0==(null!==(t=this.savedSearches)&&void 0!==t?t:[]).length}isSelected(t){var e;const o=null===(e=this.stateManager)||void 0===e?void 0:e.store.getState().request;return null!=o&&i.deepEqual(o.query,t.query)&&i.deepEqual([...o.filters],[...t.filters].map(this.mapSearchFilter))&&i.deepEqual([...o.sort].map(this.mapFtSearchSortCriterion),[...t.sort].map(this.mapFtSearchSortCriterion))&&i.deepEqual(o.contentLocale,t.contentLocale)&&i.deepEqual(o.periodFilter,t.periodFilter)}mapFtSearchSortCriterion(t){return{...t}}toFtSearchRequest(t){return null==this.stateManager?void 0:{...this.stateManager.store.getState().request,periodFilter:t.periodFilter,query:t.query,filters:t.filters.map(this.mapSearchFilter),sort:t.sort,contentLocale:t.contentLocale}}mapSearchFilter(t){return{key:t.key,values:t.values,negative:t.negative}}connectedCallback(){super.connectedCallback(),to.reloadMySearches()}setSearch(t){var i;const e=this.toFtSearchRequest(t);null!=e&&(null===(i=this.stateManager)||void 0===i||i.setRequest(e))}update(t){super.update(t),(t.has("user")||t.has("savedSearches"))&&null==this.savedSearches&&to.reloadMySearches()}}eo.styles=Ai,eo.elementDefinitions={"ft-search-saved-search":Xe,"ft-typography":bi},io([o.property({type:Boolean})],eo.prototype,"showDescription",void 0),io([o.property({type:Boolean})],eo.prototype,"showSearchFilters",void 0),io([o.property({type:Boolean})],eo.prototype,"showSearchButton",void 0),io([o.property({type:Boolean})],eo.prototype,"showAlertStatus",void 0),io([i.redux({store:Qe.name})],eo.prototype,"savedSearches",void 0),io([i.redux({store:Bi.name,selector:t=>{var i;return null===(i=t.session)||void 0===i?void 0:i.profile}})],eo.prototype,"user",void 0),io([i.redux({store:"search"})],eo.prototype,"request",void 0),io([i.redux({store:Bi.name})],eo.prototype,"editorMode",void 0),i.customElement("ft-search-saved-searches")(eo),t.FtSearchSavedSearches=eo,t.FtSearchSavedSearchesCssVariables=Ci,t.styles=Ai}({},ftGlobals.wcUtils,ftGlobals.lit,ftGlobals.litDecorators,ftGlobals.litClassMap,ftGlobals.litUnsafeHTML,ftGlobals.litRepeat);
914
+ `}get userHasRights(){var t;return!!(null===(t=this.user)||void 0===t?void 0:t.roles.includes(this.requiredRole))}get isEmpty(){var t;return 0==(null!==(t=this.savedSearches)&&void 0!==t?t:[]).length}isSelected(t){var e;const o=null===(e=this.stateManager)||void 0===e?void 0:e.store.getState().request;return null!=o&&i.deepEqual(o.query,t.query)&&i.deepEqual([...o.filters],[...t.filters].map(this.mapSearchFilter))&&i.deepEqual([...o.sort].map(this.mapFtSearchSortCriterion),[...t.sort].map(this.mapFtSearchSortCriterion))&&i.deepEqual(o.contentLocale,t.contentLocale)&&i.deepEqual(o.periodFilter,t.periodFilter)}mapFtSearchSortCriterion(t){return{...t}}toFtSearchRequest(t){return null==this.stateManager?void 0:{...this.stateManager.store.getState().request,periodFilter:t.periodFilter,query:t.query,filters:t.filters.map(this.mapSearchFilter),sort:t.sort,contentLocale:t.contentLocale}}mapSearchFilter(t){return{key:t.key,values:t.values,negative:t.negative}}connectedCallback(){super.connectedCallback(),io.reloadMySearches()}setSearch(t){var i;const e=this.toFtSearchRequest(t);null!=e&&(null===(i=this.stateManager)||void 0===i||i.setRequest(e))}update(t){super.update(t),(t.has("user")||t.has("savedSearches"))&&null==this.savedSearches&&io.reloadMySearches()}}oo.styles=Ai,oo.elementDefinitions={"ft-search-saved-search":Je,"ft-typography":bi},eo([o.property({type:Boolean})],oo.prototype,"showDescription",void 0),eo([o.property({type:Boolean})],oo.prototype,"showSearchFilters",void 0),eo([o.property({type:Boolean})],oo.prototype,"showSearchButton",void 0),eo([o.property({type:Boolean})],oo.prototype,"showAlertStatus",void 0),eo([i.redux({store:to.name})],oo.prototype,"savedSearches",void 0),eo([i.redux({store:Bi.name,selector:t=>{var i;return null===(i=t.session)||void 0===i?void 0:i.profile}})],oo.prototype,"user",void 0),eo([i.redux({store:"search"})],oo.prototype,"request",void 0),eo([i.redux({store:Bi.name})],oo.prototype,"editorMode",void 0),i.customElement("ft-search-saved-searches")(oo),t.FtSearchSavedSearches=oo,t.FtSearchSavedSearchesCssVariables=Ci,t.styles=Ai}({},ftGlobals.wcUtils,ftGlobals.lit,ftGlobals.litDecorators,ftGlobals.litClassMap,ftGlobals.litUnsafeHTML,ftGlobals.litRepeat);