@siemens/ix 1.1.0 → 1.2.0-beta.0
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.
- package/dist/cjs/index-40761405.js +178 -1
- package/dist/cjs/index.cjs.js +3 -3
- package/dist/cjs/ix-animated-tab_2.cjs.entry.js +1 -1
- package/dist/cjs/ix-application-header.cjs.entry.js +2 -2
- package/dist/cjs/ix-category-filter.cjs.entry.js +1 -1
- package/dist/cjs/ix-date-picker_2.cjs.entry.js +1 -1
- package/dist/cjs/ix-drawer.cjs.entry.js +3 -1
- package/dist/cjs/ix-event-list_2.cjs.entry.js +4 -4
- package/dist/cjs/ix-icon.cjs.entry.js +4 -4
- package/dist/cjs/ix-map-navigation_2.cjs.entry.js +5 -5
- package/dist/cjs/ix-menu_9.cjs.entry.js +2 -2
- package/dist/cjs/ix-modal_2.cjs.entry.js +2 -2
- package/dist/cjs/ix-select_2.cjs.entry.js +45 -22
- package/dist/cjs/ix-tab-item.cjs.entry.js +12 -2
- package/dist/cjs/ix-tabs.cjs.entry.js +2 -2
- package/dist/cjs/ix-toast_2.cjs.entry.js +2 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{modal-42934387.js → modal-2112fb71.js} +1 -1
- package/dist/cjs/{rwd.util-482d41d4.js → rwd.util-2326824e.js} +2 -2
- package/dist/cjs/siemens-ix.cjs.js +1 -1
- package/dist/cjs/{typed-event-8f5a32a2.js → typed-event-5030cc6a.js} +3 -3
- package/dist/collection/components/animated-tabs/animated-tabs.js +3 -3
- package/dist/collection/components/application-header/application-header.css +1 -0
- package/dist/collection/components/application-header/application-header.js +1 -1
- package/dist/collection/components/blind/blind.js +1 -1
- package/dist/collection/components/breadcrumb/breadcrumb.js +1 -1
- package/dist/collection/components/category-filter/category-filter.js +3 -3
- package/dist/collection/components/chip/chip.js +1 -1
- package/dist/collection/components/date-picker/date-picker.js +3 -3
- package/dist/collection/components/drawer/drawer.js +4 -2
- package/dist/collection/components/dropdown/dropdown.js +3 -3
- package/dist/collection/components/dropdown-item/dropdown-item.js +1 -1
- package/dist/collection/components/event-list/event-list.css +0 -3
- package/dist/collection/components/event-list-item/event-list-item.css +2 -3
- package/dist/collection/components/event-list-item/event-list-item.js +2 -2
- package/dist/collection/components/expanding-search/expanding-search.js +1 -1
- package/dist/collection/components/filter-chip/filter-chip.js +1 -1
- package/dist/collection/components/group/group.js +1 -1
- package/dist/collection/components/group-item/group-item.js +1 -1
- package/dist/collection/components/icon/icon.js +4 -4
- package/dist/collection/components/icon-button/icon-button.js +1 -1
- package/dist/collection/components/map-navigation/map-navigation.css +1 -19
- package/dist/collection/components/map-navigation/map-navigation.js +5 -5
- package/dist/collection/components/map-navigation-overlay/map-navigation-overlay.js +1 -1
- package/dist/collection/components/menu-avatar/menu-avatar.css +1 -1
- package/dist/collection/components/menu-avatar/menu-avatar.js +1 -1
- package/dist/collection/components/menu-avatar-item/menu-avatar-item.js +1 -1
- package/dist/collection/components/menu-item/menu-item.js +1 -1
- package/dist/collection/components/message-bar/message-bar.js +1 -1
- package/dist/collection/components/select/select.js +48 -24
- package/dist/collection/components/select-item/select-item.js +1 -1
- package/dist/collection/components/split-button/split-button.js +3 -3
- package/dist/collection/components/split-button-item/split-button-item.js +1 -1
- package/dist/collection/components/tab-item/tab-item.js +12 -2
- package/dist/collection/components/tabs/tabs.js +2 -2
- package/dist/collection/components/time-picker/time-picker.js +2 -2
- package/dist/collection/components/toast/toast.js +2 -2
- package/dist/collection/components/toggle/toggle.js +2 -2
- package/dist/collection/components/tree/tree.js +1 -1
- package/dist/collection/components/utils/rwd.util.js +2 -2
- package/dist/collection/components/utils/typed-event.js +3 -3
- package/dist/collection/components/workflow-step/workflow-step.js +1 -1
- package/dist/components/application-header.js +2 -2
- package/dist/components/date-picker.js +1 -1
- package/dist/components/icon.js +4 -4
- package/dist/components/ix-drawer.js +3 -1
- package/dist/components/ix-event-list-item.js +2 -2
- package/dist/components/ix-event-list.js +1 -1
- package/dist/components/ix-map-navigation.js +11 -5
- package/dist/components/ix-menu-avatar.js +1 -1
- package/dist/components/ix-select.js +47 -23
- package/dist/components/map-navigation-overlay.js +1 -1
- package/dist/components/rwd.util.js +2 -2
- package/dist/components/tab-item.js +12 -2
- package/dist/components/tabs.js +2 -2
- package/dist/components/toast.js +1 -1
- package/dist/components/typed-event.js +3 -3
- package/dist/esm/index-b22287de.js +178 -1
- package/dist/esm/index.js +3 -3
- package/dist/esm/ix-animated-tab_2.entry.js +1 -1
- package/dist/esm/ix-application-header.entry.js +2 -2
- package/dist/esm/ix-category-filter.entry.js +1 -1
- package/dist/esm/ix-date-picker_2.entry.js +1 -1
- package/dist/esm/ix-drawer.entry.js +3 -1
- package/dist/esm/ix-event-list_2.entry.js +4 -4
- package/dist/esm/ix-icon.entry.js +4 -4
- package/dist/esm/ix-map-navigation_2.entry.js +5 -5
- package/dist/esm/ix-menu_9.entry.js +2 -2
- package/dist/esm/ix-modal_2.entry.js +2 -2
- package/dist/esm/ix-select_2.entry.js +45 -22
- package/dist/esm/ix-tab-item.entry.js +12 -2
- package/dist/esm/ix-tabs.entry.js +2 -2
- package/dist/esm/ix-toast_2.entry.js +2 -2
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{modal-f1e45879.js → modal-309a156f.js} +1 -1
- package/dist/esm/{rwd.util-33a69d24.js → rwd.util-4a61a4b8.js} +2 -2
- package/dist/esm/siemens-ix.js +1 -1
- package/dist/esm/{typed-event-dd6c83dd.js → typed-event-ab58c27e.js} +3 -3
- package/dist/siemens-ix/index.esm.js +1 -1
- package/dist/siemens-ix/p-0e3aab52.entry.js +1 -0
- package/dist/siemens-ix/p-25fda9f7.entry.js +1 -0
- package/dist/siemens-ix/{p-003b58b3.js → p-2f07c86a.js} +1 -1
- package/dist/siemens-ix/{p-8c5948e2.entry.js → p-41e42413.entry.js} +1 -1
- package/dist/siemens-ix/{p-6f625f0e.js → p-4944ad0b.js} +0 -0
- package/dist/siemens-ix/{p-a4ed41f9.entry.js → p-6e8a38c4.entry.js} +1 -1
- package/dist/siemens-ix/p-74e15a57.entry.js +1 -0
- package/dist/siemens-ix/{p-fca4a226.entry.js → p-8ee057c1.entry.js} +1 -1
- package/dist/siemens-ix/p-a8b6454f.entry.js +1 -0
- package/dist/siemens-ix/{p-9cc43bf2.entry.js → p-abd3b0f8.entry.js} +1 -1
- package/dist/siemens-ix/p-b50dc630.entry.js +1 -0
- package/dist/siemens-ix/{p-0bf04780.js → p-c8cc3bb3.js} +0 -0
- package/dist/siemens-ix/siemens-ix.css +44 -31
- package/dist/siemens-ix/siemens-ix.esm.js +1 -1
- package/dist/types/components/animated-tabs/animated-tabs.d.ts +1 -1
- package/dist/types/components/category-filter/category-filter.d.ts +2 -2
- package/dist/types/components/date-picker/date-picker.d.ts +2 -2
- package/dist/types/components/dropdown/dropdown.d.ts +1 -1
- package/dist/types/components/event-list-item/event-list-item.d.ts +1 -1
- package/dist/types/components/icon-button/icon-button.d.ts +1 -1
- package/dist/types/components/map-navigation/map-navigation.d.ts +2 -2
- package/dist/types/components/menu-item/menu-item.d.ts +1 -1
- package/dist/types/components/select/select.d.ts +8 -5
- package/dist/types/components/split-button/split-button.d.ts +1 -1
- package/dist/types/components/time-picker/time-picker.d.ts +1 -1
- package/dist/types/components/toggle/toggle.d.ts +1 -1
- package/dist/types/components.d.ts +21 -35
- package/package.json +2 -2
- package/scss/components/_button-group.scss +2 -0
- package/scss/components/_buttons.scss +5 -0
- package/scss/components/_checkboxes.scss +19 -16
- package/scss/components/_radiobuttons.scss +12 -12
- package/src/components/animated-tabs/readme.md +4 -5
- package/src/components/category-filter/readme.md +13 -14
- package/src/components/date-picker/readme.md +2 -2
- package/src/components/dropdown/readme.md +11 -11
- package/src/components/event-list-item/readme.md +7 -7
- package/src/components/icon-button/readme.md +1 -1
- package/src/components/map-navigation/readme.md +2 -2
- package/src/components/menu-item/readme.md +8 -8
- package/src/components/split-button/readme.md +11 -11
- package/src/components/time-picker/readme.md +12 -12
- package/src/components/toggle/readme.md +10 -10
- package/dist/siemens-ix/p-0419f23d.entry.js +0 -1
- package/dist/siemens-ix/p-1686ce8c.entry.js +0 -1
- package/dist/siemens-ix/p-a2e33741.entry.js +0 -1
- package/dist/siemens-ix/p-a3760331.entry.js +0 -1
- package/dist/siemens-ix/p-ca8a41ea.entry.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,c as i,h as t,H as a,g as n}from"./p-5c038d1d.js";import{a as o}from"./p-810b5232.js";const s=class{constructor(t){e(this,t),this.navigationToggled=i(this,"navigationToggled",7),this.contextMenuClick=i(this,"contextMenuClick",7),this.applicationName=void 0,this.navigationTitle=void 0,this.hideContextMenu=!0,this.isSidebarOpen=!0}get menu(){return this.hostElement.querySelector("ix-menu")}get menuOverlay(){return this.hostElement.querySelector("ix-menu-overlay")}get mapNavMenu(){return this.hostElement.querySelector(".map-nav-menu")}get sidebar(){return this.hostElement.querySelector(".map-nav-sidebar")}get overlay(){return this.hostElement.querySelector("#overlay")}componentDidRender(){this.appendMenu(),this.closeOverlay()}appendMenu(){this.hostElement.querySelector("#menu-placeholder").appendChild(this.menu),this.menu.addEventListener("mapExpandChange",(e=>{const i=!e.detail;this.toggleSidebar(i),this.menu.toggleMapExpand(i)})),this.menu.enableMapExpand=!0}toggleSidebar(e){this.isSidebarOpen=void 0!==e?e:!this.isSidebarOpen,e?this.openSidebar():this.closeSidebar(),this.navigationToggled.emit(this.isSidebarOpen)}closeSidebar(){o({targets:this.sidebar,duration:s.defaultTime,marginLeft:[0,"-29.75rem"],opacity:[1,0],easing:"easeInSine",complete:()=>{this.sidebar.classList.add("d-none")}})}openSidebar(){o({targets:this.sidebar,duration:s.defaultTime,marginLeft:["-29.75rem",0],opacity:[0,1],easing:"easeOutSine",begin:()=>{this.sidebar.classList.remove("d-none")}})}async openOverlay(e,i,t,a){o({targets:this.overlay,duration:s.slowTime,backdropFilter:[0,"blur(1rem)"],translateX:["-4rem",0],opacity:[0,1],easing:"easeOutSine",begin:()=>{this.overlay.classList.remove("d-none")}});const n=document.createElement("ix-map-navigation-overlay");n.setAttribute("color",a),n.setAttribute("name",e),n.setAttribute("icon",t),n.addEventListener("closeClick",(()=>this.closeOverlay())),n.appendChild(i),this.overlay.appendChild(n)}async closeOverlay(){o({targets:this.overlay,duration:s.slowTime,backdropFilter:["blur(1rem)",0],translateX:[0,"-4rem"],opacity:[1,0],easing:"easeInSine",complete:()=>{var e;this.overlay&&(null===(e=this.overlay.firstChild)||void 0===e||e.remove(),this.overlay.classList.add("d-none"))}})}render(){return t(a,null,t("div",{id:"menu-placeholder"}),t("div",{class:"map-nav"},t("div",{class:"map-nav-sidebar"},t("div",{class:"map-nav-header"},t("ix-application-header",{name:this.applicationName,class:"map-nav-header-brand"},t("slot",{name:"logo"}))),t("div",{class:"map-nav-sidebar-content"},t("div",{class:"map-nav-sidebar-static-content"},t("div",{class:"map-nav-title"},this.navigationTitle),this.hideContextMenu?"":t("ix-icon-button",{icon:"context-menu",ghost:!0,size:"24",variant:"Secondary",onClick:()=>this.contextMenuClick.emit()})),t("div",{class:"map-nav-sidebar-user-content"},t("slot",{name:"sidebar-content"})))),t("div",{class:"content"},t("div",{class:"map-nav-header-content bg-2"},t("slot",{name:"content-header"})),t("main",null,t("slot",null)))))}get hostElement(){return n(this)}};s.defaultTime=150,s.slowTime=500,s.style=".sc-ix-map-navigation-h{display:flex;position:relative;width:100%;height:100%}.sc-ix-map-navigation-h .map-nav.sc-ix-map-navigation{display:flex;margin-left:4rem;position:relative;height:100%;flex-grow:1;overflow:hidden}.sc-ix-map-navigation-h .map-nav-sidebar.sc-ix-map-navigation{display:flex;flex-direction:column;align-items:center;width:29.75rem;max-width:29.75rem;min-width:29.75rem;height:100%;left:4rem;background-color:var(--theme-map-navigation--background);-webkit-border-end:0.125rem solid var(--theme-map-navigation-separator--background);border-inline-end:0.125rem solid var(--theme-map-navigation-separator--background);z-index:99}.sc-ix-map-navigation-h .map-nav-sidebar-content.sc-ix-map-navigation{align-items:center;position:relative;overflow:auto;height:100%;width:100%}.sc-ix-map-navigation-h .map-nav-sidebar-content.sc-ix-map-navigation .map-nav-sidebar-static-content.sc-ix-map-navigation{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:700;line-height:1.455em;color:var(--theme-color-std-text);display:flex;justify-content:space-between;margin-top:0.437rem;margin-bottom:0.812rem;margin-left:1rem;margin-right:1rem}.sc-ix-map-navigation-h .map-nav-header.sc-ix-map-navigation{display:flex;position:relative;align-items:center;height:3.5rem;min-height:3.5rem;width:100%}.sc-ix-map-navigation-h .map-nav-header.sc-ix-map-navigation .map-nav-header-brand.sc-ix-map-navigation{background-color:var(--theme-map-navigation-background);display:flex;align-items:center;height:100%;width:100%;padding:0 1rem;--theme-app-header-logo--color:var(--theme-color-std-text)}.sc-ix-map-navigation-h .map-nav-header.sc-ix-map-navigation .map-nav-header-brand.sc-ix-map-navigation button.sc-ix-map-navigation{margin-left:1rem}.sc-ix-map-navigation-h .map-nav-header-content.sc-ix-map-navigation{display:flex;height:3.5rem;align-items:center;overflow:hidden;padding:0 1rem}.sc-ix-map-navigation-h .map-nav-header-content.sc-ix-map-navigation:empty{height:0}.sc-ix-map-navigation-h .map-nav-title.sc-ix-map-navigation{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:700;line-height:1.455em;color:var(--theme-color-std-text);display:flex;align-items:center;flex-grow:1}.sc-ix-map-navigation-h .content.sc-ix-map-navigation{display:block;flex-grow:1;position:relative;height:100%;overflow:hidden;z-index:calc(var(--theme-z-index-sticky) - 1)}";const r=class{constructor(t){e(this,t),this.closeClick=i(this,"closeClick",7),this.name=void 0,this.icon=void 0,this.color=void 0}componentWillLoad(){o({targets:this.hostElement,duration:r.slowTime,backdropFilter:[0,"blur(1rem)"],translateX:["-4rem",0],opacity:[0,1],easing:"easeOutSine",begin:()=>{this.hostElement.classList.remove("d-none")}})}closeOverlay(){o({targets:this.hostElement,duration:r.slowTime,backdropFilter:["blur(1rem)",0],translateX:[0,"-4rem"],opacity:[1,0],easing:"easeInSine",complete:()=>{this.closeClick.emit(),this.hostElement.classList.add("d-none")}})}render(){return t(a,null,t("div",{class:"overlay-header"},t("div",{class:{"color-indicator":!0,"d-none":"undefined"===this.color||void 0===this.color},style:{"background-color":this.color?`var(--theme-${this.color})`:""}}),t("div",{class:"overlay-header-content"},t("ix-icon",{size:"32",name:this.icon}),t("span",{class:"overlay-header-title",title:this.name},this.name)),t("ix-icon-button",{class:"overlay-close",invisible:!0,icon:"close",size:"24",onClick:()=>this.closeOverlay()})),t("slot",null))}get hostElement(){return n(this)}};r.slowTime=500,r.style=".text-xs.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.625rem;font-weight:400;line-height:1.4em;color:var(--theme-color-std-text)}.text-s.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption-single.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1em;color:var(--theme-color-std-text)}.text-default.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-single.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.143em;color:var(--theme-color-std-text)}.text-default-title.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-title-single.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.143em;color:var(--theme-color-std-text)}.text-l.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-single.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.25em;color:var(--theme-color-std-text)}.text-l-title.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-title-single.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.25em;color:var(--theme-color-std-text)}.text-h2.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:700;line-height:1.455em;color:var(--theme-color-std-text)}.text-xl.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:400;line-height:1.091em;color:var(--theme-color-std-text)}a.sc-ix-map-navigation-overlay{color:var(--theme-color-primary)}.sc-ix-map-navigation-overlay-h{position:absolute;width:100%;height:100%;z-index:2;top:0;background-color:var(--theme-overlay--background)}.sc-ix-map-navigation-overlay-h .overlay-header.sc-ix-map-navigation-overlay{display:flex;position:relative;justify-content:flex-start;align-items:center;height:3.5rem;background-color:var(--theme-overlay-header--background)}.sc-ix-map-navigation-overlay-h .overlay-header-content.sc-ix-map-navigation-overlay{display:flex;align-items:center;min-width:0}.sc-ix-map-navigation-overlay-h .overlay-header-content.sc-ix-map-navigation-overlay ix-icon.sc-ix-map-navigation-overlay{margin-left:1rem;color:var(--theme-overlay-header--color)}.sc-ix-map-navigation-overlay-h .overlay-header-content.sc-ix-map-navigation-overlay .overlay-header-title.sc-ix-map-navigation-overlay{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:700;line-height:1.455em;color:var(--theme-color-std-text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--theme-overlay-header--color);margin-left:1rem}.sc-ix-map-navigation-overlay-h .color-indicator.sc-ix-map-navigation-overlay{display:inline-block;position:relative;width:0.5rem;height:100%;background-color:var(--theme-color-neutral)}.sc-ix-map-navigation-overlay-h .overlay-close.sc-ix-map-navigation-overlay{margin-left:auto;margin-right:1rem}";export{s as ix_map_navigation,r as ix_map_navigation_overlay}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,h as o,H as t,g as i}from"./p-5c038d1d.js";const r=class{constructor(o){e(this,o),this.name=void 0}componentDidLoad(){this.attachSiemensLogoIfLoaded()}async attachSiemensLogoIfLoaded(){await window.customElements.whenDefined("ix-siemens-logo");const e=document.createElement("ix-siemens-logo");this.host.querySelector('[slot="logo"]')||this.host.shadowRoot.querySelector(".logo").appendChild(e)}render(){return o(t,null,o("div",{class:"logo"},o("slot",{name:"logo"})),o("div",{class:"name"},this.name),o("slot",null))}get host(){return i(this)}};r.style=":host{display:flex;align-items:center;position:relative;width:100%;height:2.75rem;padding-left:1rem;color:var(--theme-app-header-logo--color);background-color:var(--theme-app-header--background);border-bottom:var(--theme-app-header--border-width) solid var(--theme-app-header--border-color)}:host .name{margin-left:2.5rem;margin-right:2.5rem}:host .logo{display:inline-flex;align-items:center;position:relative;height:32px;overflow:hidden;line-height:0rem}";export{r as ix_application_header}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as i,h as o,g as t,H as s,c as a}from"./p-5c038d1d.js";import{T as d}from"./p-
|
|
1
|
+
import{r as i,h as o,g as t,H as s,c as a}from"./p-5c038d1d.js";import{T as d}from"./p-4944ad0b.js";import{a as l}from"./p-810b5232.js";import{A as e}from"./p-bdd294d2.js";const m=class{constructor(o){i(this,o)}async showModal(i){const o=new d,t=new d,s=document.createElement("ix-modal");let{title:a,content:l}=i,e=function(i,o){var t={};for(var s in i)Object.prototype.hasOwnProperty.call(i,s)&&o.indexOf(s)<0&&(t[s]=i[s]);if(null!=i&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(s=Object.getOwnPropertySymbols(i);a<s.length;a++)o.indexOf(s[a])<0&&Object.prototype.propertyIsEnumerable.call(i,s[a])&&(t[s[a]]=i[s[a]])}return t}(i,["title","content"]);if(Object.assign(s,Object.assign({headerTitle:a},e)),"string"==typeof l){const i=document.createElement("template");l=l.trim(),i.innerHTML=l,s.appendChild(i.content.firstChild)}else s.appendChild(l);return this.hostElement.appendChild(s),s.addEventListener("closed",(i=>{this.hostElement.removeChild(s),o.emit(i.detail)})),s.addEventListener("dismissed",(i=>{this.hostElement.removeChild(s),t.emit(i.detail)})),{onClose:o,onDismiss:t}}render(){return o(s,null)}get hostElement(){return t(this)}};m.style=".sc-ix-modal-container-h{position:absolute;top:0;left:0;z-index:9999}";const n=class{constructor(o){i(this,o),this.closed=a(this,"closed",7),this.dismissed=a(this,"dismissed",7),this.onKeydown=this.handleKeydown.bind(this),this.animation=!0,this.ariaDescribedBy=void 0,this.ariaLabelledBy="modal-title",this.backdrop=!0,this.backdropClass=void 0,this.beforeDismiss=void 0,this.centered=!1,this.content=void 0,this.keyboard=!0,this.icon=void 0,this.iconColor="color-std-text",this.modalDialogClass=void 0,this.scrollable=!0,this.size="sm",this.headerTitle=void 0,this.windowClass=void 0}get modal(){return this.hostElement.querySelector(".modal")}get modalDialog(){return this.modal.querySelector(".modal-dialog")}get modalContent(){return this.modalDialog.querySelector(".modal-content")}get modalBackdrop(){return this.hostElement.querySelector(".backdrop")}slideDown(i){l({targets:i,duration:this.animation?e.mediumTime:0,opacity:[0,1],translateY:["-100%",0],easing:"easeOutSine"})}slideUp(i,o){l({targets:i,duration:this.animation?e.mediumTime:0,opacity:[1,0],translateY:[0,"-100%"],easing:"easeInSine",complete:()=>{o&&o()}})}componentDidLoad(){"static"===this.backdrop&&this.modalBackdrop.addEventListener("click",this.dismiss.bind(this)),this.backdropClass&&this.modalBackdrop.classList.add(this.backdropClass),this.modalDialogClass&&this.modalDialog.classList.add(this.modalDialogClass),this.windowClass&&this.modal.classList.add(this.windowClass),this.keyboard&&window.addEventListener("keydown",this.onKeydown),this.slideDown(this.modalContent)}handleKeydown(i){"Escape"===i.key&&this.dismiss(i.key)}disconnectedCallback(){window.removeEventListener("keydown",this.onKeydown)}async dismiss(i){this.beforeDismiss?!1!==await this.beforeDismiss(i)&&this.slideUp(this.modalContent,(()=>this.dismissed.emit(i))):this.slideUp(this.modalContent,(()=>this.dismissed.emit(i)))}async close(i){this.slideUp(this.modalContent,(()=>this.closed.emit(i)))}render(){return o(s,null,o("div",{class:{animation:this.animation,modal:!0,backdrop:"static"===this.backdrop||this.backdrop,"align-items-center":this.centered,scrollable:this.scrollable},"aria-describedby":this.ariaDescribedBy,"aria-labelledby":this.ariaLabelledBy},o("div",{class:{"modal-dialog":!0,"modal-sm":"sm"===this.size,"modal-lg":"lg"===this.size,"modal-xl":"xl"===this.size}},o("div",{class:"modal-content"},void 0===this.icon||""===this.icon?"":o("div",{class:"state-icon-container"},o("ix-icon",{name:this.icon,size:"32",color:this.iconColor})),o("div",{class:"slot-container"},o("slot",null))))))}get hostElement(){return t(this)}};n.style=".sc-ix-modal-h{position:relative;width:100vw;height:100vh}.sc-ix-modal-h .modal.sc-ix-modal{display:flex}.sc-ix-modal-h .modal.animation.sc-ix-modal{animation:modal-fade 300ms ease-in-out}.sc-ix-modal-h .modal.backdrop.sc-ix-modal{background-color:var(--theme-color-lightbox);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);transition:none}.sc-ix-modal-h .modal.backdrop.animation.sc-ix-modal{transition:-webkit-backdrop-filter 0ms ease-in-out;transition:backdrop-filter 0ms ease-in-out;transition:backdrop-filter 0ms ease-in-out, -webkit-backdrop-filter 0ms ease-in-out}.sc-ix-modal-h .modal.sc-ix-modal .modal-dialog.sc-ix-modal{flex-grow:1}.sc-ix-modal-h .modal.scrollable.sc-ix-modal .modal-content.sc-ix-modal{max-height:100%}.sc-ix-modal-h .modal.scrollable.sc-ix-modal .modal-content.sc-ix-modal .modal-body.sc-ix-modal{overflow-y:auto}.sc-ix-modal-h .modal.sc-ix-modal .modal-content.sc-ix-modal{box-shadow:var(--theme-modal--box-shadow);flex-direction:row;background-color:var(--theme-modal--background);border:var(--modal--border-thickness) solid var(--theme-modal--border-color);padding:1.5rem}.sc-ix-modal-h .modal.sc-ix-modal .modal-content.sc-ix-modal .state-icon-container.sc-ix-modal{-webkit-margin-end:1rem;margin-inline-end:1rem}.sc-ix-modal-h .modal.sc-ix-modal .modal-content.sc-ix-modal .slot-container.sc-ix-modal{flex-grow:1}@media (min-width: 576px){.sc-ix-modal-h .modal.sc-ix-modal .modal-dialog.sc-ix-modal:not(.modal-dialog-centered){margin:2.5rem auto}}@media (max-width: 575.98px){.sc-ix-modal-h .modal.sc-ix-modal .modal-dialog.sc-ix-modal{height:100%;margin:0}.sc-ix-modal-h .modal.sc-ix-modal .modal-dialog.sc-ix-modal .modal-content.sc-ix-modal{height:100%;border-radius:0}}@keyframes modal-fade{from{opacity:0%}to{opacity:100%}}@keyframes slide-down{from{top:-100%}to{top:32px}}";export{m as M,n as a}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as e,h as i,H as s,g as n,f as o}from"./p-5c038d1d.js";import{a}from"./p-0bf04780.js";class r{constructor(t,e,i){this.hostElement=t,this.popoverElement=e,this.outsideCallback=i}outside(t){var e;(null===(e=this.hostElement)||void 0===e?void 0:e.contains(t.target))||this.outsideCallback(t)}open(t=256){this.popoverElement.style.transform=`\n translateX(${this.hostElement.offsetLeft+this.hostElement.offsetWidth}px)\n translateY(-${this.hostElement.offsetHeight}px)\n `,this.popoverElement.style.maxWidth=a(t),document.body.addEventListener("click",this.outside.bind(this))}destroy(){document.body.removeEventListener("click",this.outside.bind(this))}}const m=class{constructor(i){t(this,i),this.expandChange=e(this,"expandChange",7),this.mapExpandChange=e(this,"mapExpandChange",7),this.domObserver=new MutationObserver(this.onDomChange.bind(this)),this.isVisible=t=>{var e,i;return"none"!==t.style.display&&"none"!==(null===(i=null===(e=t.parentElement)||void 0===e?void 0:e.parentElement)||void 0===i?void 0:i.style.display)},this.showSettings=!1,this.showAbout=!1,this.enableToggleTheme=!1,this.enableSettings=!0,this.enableMapExpand=!1,this.applicationName=void 0,this.applicationDescription="",this.maxVisibleMenuItems=9,this.i18nLegal="About & legal information",this.i18nSettings="Settings",this.i18nToggleTheme="Toggle theme",this.i18nExpand=" Expand",this.i18nCollapse="Collapse",this.i18nMore="More…",this.expand=!1,this.showMoreItems=!1,this.visibleMenuItems=0,this.countMoreNotifications=0,this.mapExpand=!0,this.activeTab=void 0,this.isMoreTabEmpty=!1}onWindowResize(){this.visibleMenuItems=this.getMaxTabCount()}handleNodeMutation(t){t instanceof HTMLElement&&(t.matches(".tab")&&this.onWindowResize(),t.matches("ix-menu-about")&&this.menu.contains(t)&&this.appendAbout(),t.matches("ix-menu-settings")&&this.menu.contains(t)&&this.appendSettings())}onDomChange(t){t.forEach((t=>{t.addedNodes.forEach(this.handleNodeMutation.bind(this)),t.removedNodes.forEach(this.handleNodeMutation.bind(this))}))}get popoverArea(){return this.hostElement.querySelector("#popover-area")}get overlayContainer(){return this.hostElement.querySelector(".menu-overlay")}get invisibleContainer(){return this.hostElement.querySelector(".menu-overlay-invisible")}get menu(){return this.hostElement.querySelector(".menu")}get menuItems(){return Array.from(this.hostElement.querySelectorAll("ix-menu-item:not(.internal-tab):not(.home-tab):not(.bottom-tab)")).filter(this.isVisible)}get menuBottomItems(){return Array.from(this.hostElement.querySelectorAll("ix-menu-item.bottom-tab:not(.internal-tab):not(.home-tab)")).filter(this.isVisible)}get homeTab(){return this.hostElement.querySelector("ix-menu-item.home-tab")}get moreItemsDropdown(){return this.hostElement.querySelector(".internal-tab ix-dropdown")}get isMoreItemsDropdownEmpty(){return 0===this.hostElement.querySelectorAll(".internal-tab ix-dropdown .appended").length}get moreItemsDropdownItems(){return this.hostElement.querySelectorAll(".internal-tab ix-dropdown ix-menu-item")}get activeMoreTabContainer(){return this.hostElement.querySelector(".active-more-tab")}get activeMoreTab(){return this.hostElement.querySelector(".active-more-tab ix-menu-item")}get aboutPopoverContainer(){return this.hostElement.querySelector(".about-news")}get aboutPopover(){return document.querySelector("ix-menu-about-news")}get aboutTab(){return this.hostElement.querySelector("#aboutAndLegal")}get about(){return this.hostElement.querySelector("ix-menu-about")}get settings(){return this.hostElement.querySelector("ix-menu-settings")}get isSettingsEmpty(){return 0===Array.from(this.hostElement.querySelectorAll("ix-menu-settings-item")).length}get avatarItem(){return this.hostElement.querySelector("ix-menu-avatar")}get tabsContainer(){return this.hostElement.querySelector("#menu-tabs")}showTab(t){return t+1<=this.visibleMenuItems}componentDidLoad(){var t,e,i,s;const n=this.hostElement.querySelector("#more-tab");this.popoverListener=new r(n,this.moreItemsDropdown,(()=>{this.showMoreItems=!1})),null===(t=this.settings)||void 0===t||t.addEventListener("close",(()=>{this.showSettings=!1,this.settings.show=this.showSettings})),null===(e=this.settings)||void 0===e||e.addEventListener("animationend",(()=>{this.showSettings||(this.settings.classList.add("d-none"),this.overlayContainer.classList.add("d-none"))})),null===(i=this.about)||void 0===i||i.addEventListener("close",(()=>{this.showAbout=!1,this.about.show=this.showAbout})),null===(s=this.about)||void 0===s||s.addEventListener("animationend",(()=>{this.showAbout||(this.about.classList.add("d-none"),this.overlayContainer.classList.add("d-none"))})),this.overlayContainer.classList.add("d-none"),this.onWindowResize(),this.domObserver.observe(this.hostElement,{attributes:!1,childList:!0,subtree:!0})}disconnectedCallback(){var t;null===(t=this.popoverListener)||void 0===t||t.destroy()}componentWillRender(){this.appendTabs()}componentDidRender(){this.visibleMenuItems=this.getMaxTabCount(),this.appendFragments()}appendFragments(){this.appendAvatar(),this.appendAbout(),this.appendSettings(),this.appendAboutNewsPopover(),this.isMoreTabEmpty=this.isMoreItemsDropdownEmpty,this.countMoreNotifications=this.getMoreNotificationsCount()}resetActiveTab(){this.activeTab=null}isMenuItemActive(t){return t.active||t.classList.contains("active")}appendTabs(){this.activeTab=null,this.homeTab&&(this.hostElement.querySelector(".tabs-top").appendChild(this.homeTab),this.homeTab.addEventListener("click",this.resetOverlay)),this.menuItems.forEach(((t,e)=>{var i;this.showTab(e)?t.classList.remove("d-none"):(t.classList.add("d-none"),this.isMenuItemActive(t)&&(this.activeTab=t)),null===(i=this.homeTab)||void 0===i||i.classList.remove("d-none"),t.addEventListener("click",this.resetOverlay)}))}appendAvatar(){var t;const e=this.avatarItem;e&&(e.style.marginBottom="1rem",null===(t=this.hostElement.querySelector("#avatar-tab-placeholder"))||void 0===t||t.appendChild(e))}getAboutPopoverVerticalPosition(){const t=this.aboutTab.getBoundingClientRect(),e=window.innerHeight-(t.bottom-t.height/2+6+6);return a(e)}appendAboutNewsPopover(){var t;this.aboutPopover&&(this.aboutPopover.style.bottom=this.getAboutPopoverVerticalPosition(),!(null===(t=this.popoverArea)||void 0===t?void 0:t.contains(this.aboutPopover)))&&(this.aboutPopover.addEventListener("showMore",(()=>{var t;(null===(t=this.aboutPopover)||void 0===t?void 0:t.aboutItemLabel)&&(this.about.activeTabLabel=this.aboutPopover.aboutItemLabel,this.toggleAbout(!0))}).bind(this)),document.body.appendChild(this.aboutPopover))}appendSettings(){this.settings&&this.overlayContainer.appendChild(this.settings)}appendAbout(){this.about&&this.overlayContainer.appendChild(this.about)}getMoreNotificationsCount(){var t;const e=null===(t=this.moreItemsDropdown)||void 0===t?void 0:t.querySelectorAll(".appended");let i=0;return null==e||e.forEach((t=>{t.notifications&&(i+=t.notifications)})),i}getAvailableHeight(){let t=this.hostElement.clientHeight;return t-=60,this.avatarItem&&(t-=56),this.homeTab&&(t-=72),this.showAbout&&(t-=36),this.showSettings&&(t-=36),this.menuBottomItems.length&&(t-=36*this.menuBottomItems.length),this.enableMapExpand&&(t-=36),t-=72,t-=16,t}getMaxTabCount(){const t=this.getAvailableHeight(),e=Math.floor(t/48),i=this.menuItems.length;return 1===i?1:i<this.maxVisibleMenuItems?e>i?i:Math.min(e-2,i):i===this.maxVisibleMenuItems?e<this.maxVisibleMenuItems?e-2:e===this.maxVisibleMenuItems?this.maxVisibleMenuItems-2:Math.min(e,this.maxVisibleMenuItems):e===this.maxVisibleMenuItems?this.maxVisibleMenuItems-2:e>=this.maxVisibleMenuItems?this.maxVisibleMenuItems-1:Math.min(e-2,this.maxVisibleMenuItems)}toggleShowMoreDropdown(){0!==this.moreItemsDropdown.querySelectorAll(".appended").length&&(this.popoverListener.open(),this.showMoreItems=!this.showMoreItems)}async toggleMapExpand(t){this.skipAllOverlayAnimations(),this.mapExpand=void 0!==t?t:!this.mapExpand}skipAllOverlayAnimations(){this.about&&this.skipOverlayAnimationFor(this.about),this.settings&&this.skipOverlayAnimationFor(this.settings)}skipOverlayAnimationFor(t){const e="animate__animated";null==t||t.classList.remove(e),setTimeout((()=>{null==t||t.classList.add(e)}),300)}async toggleMenu(t){this.skipAllOverlayAnimations(),this.expand=void 0!==t?t:!this.expand,this.aboutPopover&&(this.aboutPopover.expanded=this.expand),this.expandChange.emit(this.expand)}async toggleSettings(t){var e;this.showAbout?this.skipAllOverlayAnimations():this.skipOverlayAnimationFor(this.about),null===(e=this.about)||void 0===e||e.classList.add("d-none"),this.resetOverlay(),this.showSettings=t,this.settings.show=this.showSettings,this.settings.classList.remove("d-none"),this.overlayContainer.classList.remove("d-none")}async toggleAbout(t){var e;this.showSettings?this.skipAllOverlayAnimations():this.skipOverlayAnimationFor(this.settings),null===(e=this.settings)||void 0===e||e.classList.add("d-none"),this.resetOverlay(),this.showAbout=t,this.about.show=this.showAbout,this.about.classList.remove("d-none"),this.overlayContainer.classList.remove("d-none")}resetOverlay(){this.showSettings=!1,this.showAbout=!1,this.settings&&(this.settings.show=this.showSettings),this.about&&(this.about.show=this.showAbout)}showMoreButton(){const t=this.menuItems.length;return 1!==t&&(t<this.maxVisibleMenuItems?this.visibleMenuItems<t:t>this.maxVisibleMenuItems?this.visibleMenuItems<this.maxVisibleMenuItems:this.visibleMenuItems<=this.maxVisibleMenuItems-2)}getCollapseText(){return this.mapExpand?this.i18nCollapse:this.i18nExpand}getCollapseIcon(){return this.mapExpand?"double-chevron-left":"double-chevron-right"}isMenuItemClicked(t){return t.composedPath().filter((t=>"more-tab"!==t.id)).filter((t=>"IX-MENU-ITEM"===t.tagName)).some((t=>this.tabsContainer.contains(t)))}render(){return i(s,{class:{expanded:this.expand}},i("div",{class:{menu:!0,expanded:this.expand},onClick:()=>{this.resetActiveTab()}},i("div",{onClick:async()=>this.toggleMenu(),class:{"burger-menu-button":!0,expanded:this.expand}},i("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:"32",height:"32"},i("rect",{class:"line line-1",x:"5",y:"9.5",width:"22",height:"2"}),i("rect",{class:"line line-2",x:"5",y:"15.5",width:"22",height:"2"}),i("rect",{class:"line line-3",x:"5",y:"21.5",width:"22",height:"2"}))),i("div",{id:"avatar-tab-placeholder"}),i("div",{id:"menu-tabs",style:{display:"contents"},onClick:t=>{this.isMenuItemClicked(t)&&this.resetOverlay()}},i("div",{class:"tabs-top"}),i("slot",null),i("div",{class:"active-more-tab"},this.activeTab?i("ix-menu-item",{class:"internal-tab",active:!0,tabIcon:this.activeTab.tabIcon},this.activeTab.innerText):null),i("ix-menu-item",{id:"more-tab",tabIcon:"more-menu",class:{"internal-tab":!0},style:{display:this.showMoreButton()?"block":"none"},title:"Show more",notifications:this.countMoreNotifications,onClick:()=>this.toggleShowMoreDropdown()},this.i18nMore,i("ix-dropdown",{show:this.showMoreItems},this.menuItems.filter(((t,e)=>!this.showTab(e)&&!this.isMenuItemActive(t)&&this.isVisible(t))).map((t=>i("ix-menu-item",{tabIcon:t.tabIcon,active:t.active,class:"internal-tab appended",onClick:()=>t.dispatchEvent(new CustomEvent("click"))},t.innerText)))))),i("div",{class:"bottom-tab-divider"}),this.enableSettings&&!this.isSettingsEmpty?i("ix-menu-item",{id:"settings",class:{"internal-tab":!0,"bottom-tab":!0,active:this.showSettings},tabIcon:"cogwheel",onClick:async()=>this.toggleSettings(!this.showSettings)},this.i18nSettings):null,i("slot",{name:"bottom"}),i("div",{id:"popover-area"}),this.about?i("ix-menu-item",{id:"aboutAndLegal",class:{"internal-tab":!0,"bottom-tab":!0,active:this.showAbout},tabIcon:"info",onClick:async()=>this.toggleAbout(!this.showAbout)},this.i18nLegal):null,this.enableToggleTheme?i("ix-menu-item",{id:"toggleTheme",onClick:()=>(()=>{let t=Array.from(document.body.classList).find((t=>t.includes("theme-")));t||(t="theme-classic-dark");const e=t.endsWith("-dark");let i=t;i=e?t.replace(/-dark$/g,"-light"):t.replace(/-light$/g,"-dark"),document.body.classList.remove(t),document.body.classList.add(i)})(),class:"internal-tab bottom-tab",tabIcon:"bulb"},this.i18nToggleTheme):null,this.enableMapExpand?i("ix-menu-item",{id:"menu-collapse",onClick:()=>this.mapExpandChange.emit(this.mapExpand),class:"internal-tab bottom-tab",tabIcon:`${this.getCollapseIcon()}`},this.getCollapseText()):null),i("div",{class:{"menu-overlay":!0,expanded:this.expand,"d-block":this.showAbout||this.showSettings},style:{opacity:this.showAbout||this.showSettings?"1":"0"}}),i("div",{class:"menu-overlay-invisible"}))}get hostElement(){return n(this)}};m.style="ix-menu{display:flex;flex-direction:row;position:absolute;height:100%;min-height:22.75rem;z-index:var(--theme-z-index-sticky);width:auto}ix-menu .menu{display:flex;flex-direction:column;position:relative;width:4rem;height:100%;-webkit-padding-after:1rem;padding-block-end:1rem;background-color:var(--theme-nav--background);transition:width var(--animate-duration)}ix-menu .menu.expanded{box-shadow:var(--theme-navigation--box-shadow)}ix-menu .menu .burger-menu-button{display:flex;justify-content:center;margin-top:0.75rem;margin-left:0.75rem;margin-bottom:1rem;height:2rem;width:2.5rem;border-radius:0.25rem}ix-menu .menu .burger-menu-button:not(.disabled):not(:disabled).hover,ix-menu .menu .burger-menu-button:not(.disabled):not(:disabled):hover{background-color:var(--theme-ghost--background--hover)}ix-menu .menu .burger-menu-button:not(.disabled):not(:disabled).active,ix-menu .menu .burger-menu-button:not(.disabled):not(:disabled):active{background-color:var(--theme-ghost--background--active)}ix-menu .menu .burger-menu-button svg{display:inline-block;fill:var(--theme-menu-btn--color);position:relative}ix-menu .menu .burger-menu-button svg .line{opacity:1;transform:rotate(0) translateY(0) translateX(0);transition:transform 0.3s ease-in-out, opacity 0.2s ease-in-out}ix-menu .menu .burger-menu-button.expanded svg .line-1{transform:translate(0.6875rem, -0.05rem) rotate(45deg)}ix-menu .menu .burger-menu-button.expanded svg .line-2{opacity:0}ix-menu .menu .burger-menu-button.expanded svg .line-3{transform:translate(-0.75625rem, 0.8125rem) rotate(-45deg)}ix-menu .menu-overlay{display:block;position:absolute;width:calc(100vw - 4rem);height:100%;left:4rem;z-index:-1;-webkit-backdrop-filter:blur(1rem);backdrop-filter:blur(1rem);background-color:var(--theme-sidebar-overlay-blur);transition:all 150ms ease-out}ix-menu .menu-overlay-invisible{display:none}ix-menu .menu.expanded{width:16rem}ix-menu .menu-overlay.expanded{width:calc(100vw - 16rem);left:16rem}ix-menu #avatar-tab-placeholder{max-height:3rem}ix-menu .avatar{margin-bottom:2rem}ix-menu #cui-imprint .cui-imprint-product-name{margin-bottom:1rem}ix-menu #cui-imprint .cui-imprint-product-description{margin-bottom:2rem}ix-menu #cui-imprint .cui-imprint-link-container{display:flex;align-items:center}ix-menu .bottom-tab-divider{margin-top:auto}";const h=class{constructor(i){t(this,i),this.close=e(this,"close",7),this.activeTabLabel=void 0,this.label="About & legal information",this.show=!1,this.labels=[]}get aboutItems(){return Array.from(this.el.querySelectorAll("ix-menu-about-item"))}setTab(t){this.activeTabLabel=t,this.aboutItems.forEach((t=>{t.style.display="none",t.label===this.activeTabLabel&&(t.style.display="block")}))}componentWillLoad(){this.aboutItems.length&&this.setTab(this.activeTabLabel||this.aboutItems[0].label)}componentDidLoad(){o(this.el)}componentWillRender(){this.updateLabels()}updateLabels(){this.labels=this.aboutItems.map((t=>t.label))}watchActiveTabLabel(t){setTimeout((()=>this.setTab(t)))}getSelectedTabIndex(t){const e=this.aboutItems.find((e=>e.label===t));return this.aboutItems.indexOf(e)}getTabItems(){return this.aboutItems.map((({label:t})=>i("ix-tab-item",{class:{active:t===this.activeTabLabel},onClick:()=>this.setTab(t)},t)))}render(){return i(s,{class:{animate__animated:!0,animate__fadeInLeft:this.show,animate__fadeOutLeft:!this.show}},i("div",{class:"about-header"},i("h2",{class:"text-h2"},this.label),i("ix-icon-button",{ghost:!0,size:"24",icon:"close",onClick:t=>this.close.emit(t)})),i("ix-tabs",{selected:this.getSelectedTabIndex(this.activeTabLabel),class:"about-tabs"},this.getTabItems()),i("div",{class:"about-items"},i("slot",null)))}get el(){return n(this)}static get watchers(){return{activeTabLabel:["watchActiveTabLabel"]}}};h.style=".text-xs.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.625rem;font-weight:400;line-height:1.4em;color:var(--theme-color-std-text)}.text-s.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1em;color:var(--theme-color-std-text)}.text-default.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.143em;color:var(--theme-color-std-text)}.text-default-title.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-title-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.143em;color:var(--theme-color-std-text)}.text-l.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.25em;color:var(--theme-color-std-text)}.text-l-title.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-title-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.25em;color:var(--theme-color-std-text)}.text-h2.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:700;line-height:1.455em;color:var(--theme-color-std-text)}.text-xl.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:400;line-height:1.091em;color:var(--theme-color-std-text)}a.sc-ix-menu-about{color:var(--theme-color-primary)}.sc-ix-menu-about-h{display:block;background-color:var(--theme-nav-overlay--background);padding:0.75rem 1rem 1rem 2rem;flex-grow:1;position:absolute;width:100%;height:100%}.sc-ix-menu-about-h .about-header.sc-ix-menu-about{display:flex;justify-content:space-between;flex-direction:row;align-items:center;height:2rem;margin-bottom:0.5rem}.sc-ix-menu-about-h .about-header.sc-ix-menu-about h2.sc-ix-menu-about{color:var(--theme-nav-overlay-header--color);margin-bottom:0}.sc-ix-menu-about-h .about-tabs.sc-ix-menu-about{margin-bottom:1.5rem}.sc-ix-menu-about-h ix-menu-about-item.sc-ix-menu-about{display:none}";const l=class{constructor(e){t(this,e),this.label=void 0}render(){return i(s,null,i("slot",null))}};l.style=".sc-ix-menu-about-item-h{display:block}";const c=class{constructor(i){t(this,i),this.showMore=e(this,"showMore",7),this.closePopover=e(this,"closePopover",7),this.show=!1,this.label=void 0,this.i18nShowMore="Show more",this.aboutItemLabel=void 0,this.offsetBottom=0,this.expanded=!1}render(){return i(s,{class:{expanded:this.expanded,show:!this.show}},i("div",{class:"banner-container"},i("ix-icon",{color:"color-inv-contrast-text",name:"shout",size:"32"}),i("svg",{viewBox:"0 0 48 56",xmlns:"http://www.w3.org/2000/svg"},i("polygon",{points:"0 0 48 0 48 56 24 48 0 56"}))),i("div",{class:"cui-popover-news-header"},i("span",{class:"text-l-title"},this.label)),i("ix-icon-button",{size:"24",icon:"close-small",ghost:!0,onClick:()=>{this.show=!1,this.closePopover.emit()}}),i("slot",null),this.aboutItemLabel?i("div",{class:"cui-popover-news-footer"},i("button",{class:"btn btn-primary",onClick:t=>{this.show=!1,this.showMore.emit(t)}},this.i18nShowMore)):null,i("svg",{id:"arrow",xmlns:"http://www.w3.org/2000/svg",width:"8",height:"12",viewBox:"0 0 8 12"},i("path",{d:"M8 0 L0 6 L8 12"})))}};c.style=".sc-ix-menu-about-news-h{display:block;position:fixed;width:20rem;height:auto;background-color:var(--theme-color-1);border:var(--theme-weak-bdr-1);border-radius:0.25rem;padding:1rem;left:4rem;z-index:10000;transition:left var(--animate-duration);margin-left:0.5rem !important;box-shadow:var(--theme-box-shadow-level-2)}.expanded.sc-ix-menu-about-news-h{left:calc(4rem + 12rem)}.show.sc-ix-menu-about-news-h{display:none}.sc-ix-menu-about-news-h .banner-container.sc-ix-menu-about-news{position:absolute;top:0.0625rem;left:1rem}.sc-ix-menu-about-news-h .banner-container.sc-ix-menu-about-news svg.sc-ix-menu-about-news{position:absolute;height:3.625rem;width:3rem}.sc-ix-menu-about-news-h .banner-container.sc-ix-menu-about-news svg.sc-ix-menu-about-news polygon.sc-ix-menu-about-news{fill:var(--theme-color-primary)}.sc-ix-menu-about-news-h .banner-container.sc-ix-menu-about-news ix-icon.sc-ix-menu-about-news{margin:0.5rem;position:absolute;z-index:1}.sc-ix-menu-about-news-h .cui-popover-news-header.sc-ix-menu-about-news{margin-bottom:2rem;margin-left:4rem;margin-top:-0.25rem}.sc-ix-menu-about-news-h .popover-body.sc-ix-menu-about-news{color:var(--theme-color-std-text)}.sc-ix-menu-about-news-h .cui-popover-news-footer.sc-ix-menu-about-news{display:flex;justify-content:flex-end;margin-top:1rem}.sc-ix-menu-about-news-h #arrow.sc-ix-menu-about-news{bottom:14px;position:relative;left:-10px}.sc-ix-menu-about-news-h ix-icon-button.sc-ix-menu-about-news{top:0.5rem;right:0.5rem;position:absolute}.sc-ix-menu-about-news-h svg#arrow.sc-ix-menu-about-news{position:absolute;left:-0.5rem;bottom:0.4rem}.sc-ix-menu-about-news-h svg#arrow.sc-ix-menu-about-news path.sc-ix-menu-about-news{fill:var(--theme-color-1);stroke:var(--theme-color-weak-bdr-1)}";const u=class{constructor(i){t(this,i),this.logoutClick=e(this,"logoutClick",7),this.displayMenu=void 0,this.top=void 0,this.bottom=void 0,this.i18nLogout="Logout"}toggleMenu(){this.outsideListener.open(),this.displayMenu=!this.displayMenu}componentDidLoad(){this.outsideListener=new r(this.hostElement,this.hostElement.querySelector("ix-dropdown"),(()=>{this.displayMenu=!1}))}disconnectedCallback(){var t;null===(t=this.outsideListener)||void 0===t||t.destroy()}render(){return i(s,null,i("li",{class:"nav-item top-item avatar no-hover",title:this.top},i("svg",{xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"},i("g",{fill:"none","fill-rule":"evenodd"},i("path",{id:"avatar-path-background",d:"M16 0C7.163 0 0 7.163 0 16s7.163 16 16 16 16-7.163\n 16-16c0-4.243-1.686-8.313-4.686-11.314C24.314 1.686 20.244 0 16 0z"}),i("path",{id:"avatar-path-person",d:"M17.897 17.91c3.8-.018 7.358 1.875 9.485 5.046-2.417 3.999-6.734 6.434-11.382\n 6.42-4.648.014-8.965-2.421-11.382-6.42 2.127-3.171 5.685-5.064\n 9.485-5.045h3.794zM15.821 2.129c3.682 0 6.667 2.984 6.667 6.666 0 3.682-2.985\n 6.667-6.667 6.667s-6.667-2.985-6.667-6.667 2.985-6.666 6.667-6.666z"}))),i("div",{class:"avatar-name"},i("span",{class:"text-default-single",title:this.top},this.top),i("span",{class:"text-default-single",title:this.bottom},this.bottom))),i("ix-dropdown",{show:this.displayMenu},i("slot",null),i("ix-menu-avatar-item",{label:this.i18nLogout,icon:"log-out",onClick:t=>{this.logoutClick.emit(t)}})))}get hostElement(){return n(this)}};u.style=".sc-ix-menu-avatar-h{display:block;position:relative;margin-bottom:0.5rem}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar{display:flex;align-items:center;height:2.5rem;max-height:2.5rem;padding-left:0.25rem;margin-left:0.75rem;margin-right:0.75rem;transition:0.15s;border-radius:1.25rem}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar>svg.sc-ix-menu-avatar{height:2rem;width:2rem;min-height:2rem;min-width:2rem}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar #avatar-path-background.sc-ix-menu-avatar{fill:var(--theme-avatar--background)}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar #avatar-path-person.sc-ix-menu-avatar{fill:var(--theme-avatar--person)}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar .avatar-name.sc-ix-menu-avatar{display:flex;flex-direction:column;overflow:hidden;white-space:nowrap;margin-left:1rem;line-height:1.14}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar .avatar-name.sc-ix-menu-avatar .text-default-single.sc-ix-menu-avatar{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar:not(.disabled):not(:disabled):hover{background-color:var(--theme-avatar-btn--background--hover);color:var(--theme-avatar-btn--color--hover)}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar:not(.disabled):not(:disabled):active{background-color:var(--theme-avatar-btn--background--active);color:var(--theme-avatar-btn--color--active)}";const d=class{constructor(i){t(this,i),this.itemClick=e(this,"itemClick",7),this.icon=void 0,this.label=void 0}render(){return i("ix-dropdown-item",{icon:this.icon,label:this.label,onClick:t=>this.itemClick.emit(t)})}get hostElement(){return n(this)}};d.style=".sc-ix-menu-avatar-item-h{display:block}";const b=class{constructor(e){t(this,e),this.home=!1,this.bottom=!1,this.tabIcon="document",this.notifications=void 0,this.active=void 0,this.disabled=void 0,this.title=void 0}get tabLabel(){return this.hostElement.querySelector(".tab-text")}componentDidRender(){const t=this.tabLabel.innerHTML.replace("&","&");this.title!==t&&(this.title=t)}render(){return i(s,{class:{disabled:this.disabled,"home-tab":this.home,"bottom-tab":this.bottom,active:this.active}},i("li",{class:"tab",title:this.title},i("i",{class:`glyph glyph-${this.tabIcon}`},i("div",{class:"notification"},this.notifications?i("div",{class:"pill"},this.notifications):null)),i("span",{class:"tab-text text-default"},i("slot",null))))}get hostElement(){return n(this)}};b.style='ix-menu-item{position:relative;display:block}ix-menu-item .tab{display:flex;position:relative;align-items:center;height:3rem;z-index:500;padding-left:1.25rem}ix-menu-item .tab:not(.selected){cursor:pointer}ix-menu-item .tab:not(.selected):not(.disabled):not(:disabled).hover,ix-menu-item .tab:not(.selected):not(.disabled):not(:disabled):hover{background-color:var(--theme-ghost--background--hover)}ix-menu-item .tab:not(.selected):not(.disabled):not(:disabled).active,ix-menu-item .tab:not(.selected):not(.disabled):not(:disabled):active{background-color:var(--theme-ghost--background--active)}ix-menu-item i.glyph{color:var(--theme-nav-item-primary-icon--color);position:relative}ix-menu-item .tab:focus-visible{outline:none}ix-menu-item:focus-visible{outline:none}ix-menu-item .tab:not(:last-child){margin-bottom:0.5rem}ix-menu-item .notification{display:inline-flex;position:absolute;top:-0.5rem;right:-50%}ix-menu-item .notification .pill{display:inline-flex;justify-content:center;align-items:center;height:1rem;min-width:1rem;position:relative;border-radius:6.25rem;background-color:var(--theme-color-primary);border-radius:6.25rem;font-size:0.75rem;font-weight:bold;line-height:1;font-family:Siemens Sans, Arial, sans-serif;color:var(--theme-color-primary--contrast);padding:0.25rem}ix-menu-item .tab-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--theme-nav-item-primary--color);margin:0 1.25rem;-webkit-user-select:none;-moz-user-select:none;user-select:none}ix-menu-item.active .tab,ix-menu-item.selected .tab{background-color:var(--theme-nav-item-primary--background--selected)}ix-menu-item.active .tab::before,ix-menu-item.selected .tab::before{content:"";background-color:var(--theme-nav-item-primary--border-color--selected);height:3rem;width:0.25rem;left:0;position:absolute}ix-menu-item.active .tab>.glyph,ix-menu-item.selected .tab>.glyph{color:var(--theme-nav-item-primary-icon--color--selected)}ix-menu-item.disabled{color:var(--theme-color-weak-text);pointer-events:none;cursor:default}ix-menu-item.disabled .tab>.glyph{color:var(--theme-color-weak-text)}ix-menu-item.disabled .tab-text{color:var(--theme-color-weak-text)}ix-menu-item.home-tab,ix-menu-item[slot=home]{margin-bottom:1.5rem}ix-menu-item.bottom-tab,ix-menu-item[slot=bottom]{height:2.25rem}ix-menu-item.bottom-tab .tab,ix-menu-item[slot=bottom] .tab{height:2.25rem}ix-menu-item.bottom-tab .tab::before,ix-menu-item[slot=bottom] .tab::before{height:2.25rem}ix-menu-item.bottom-tab.active .tab,ix-menu-item.bottom-tab.selected .tab,ix-menu-item[slot=bottom].active .tab,ix-menu-item[slot=bottom].selected .tab{background-color:var(--theme-color-1)}';const g=class{constructor(i){t(this,i),this.close=e(this,"close",7),this.activeTabLabel=void 0,this.label="Settings",this.show=!1}get settingsItems(){return Array.from(this.el.querySelectorAll("ix-menu-settings-item"))}setTab(t){this.activeTabLabel=t,this.settingsItems.forEach((t=>{t.style.display="none",t.label===this.activeTabLabel&&(t.style.display="block")}))}componentWillLoad(){this.settingsItems.length&&this.setTab(this.activeTabLabel||this.settingsItems[0].label)}componentDidLoad(){o(this.el)}watchActiveTabLabel(t){this.setTab(t)}getTabItems(){return this.settingsItems.map((({label:t})=>i("ix-tab-item",{class:{active:t===this.activeTabLabel},onClick:()=>this.setTab(t)},t)))}render(){return i(s,{class:{animate__animated:!0,animate__fadeInLeft:this.show,animate__fadeOutLeft:!this.show}},i("div",{class:"settings-header"},i("h2",{class:"text-h2"},this.label),i("ix-icon-button",{ghost:!0,size:"24",icon:"close",onClick:t=>this.close.emit(t)})),i("ix-tabs",null,this.getTabItems()),i("slot",null))}get el(){return n(this)}static get watchers(){return{activeTabLabel:["watchActiveTabLabel"]}}};g.style=".text-xs.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.625rem;font-weight:400;line-height:1.4em;color:var(--theme-color-std-text)}.text-s.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1em;color:var(--theme-color-std-text)}.text-default.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.143em;color:var(--theme-color-std-text)}.text-default-title.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-title-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.143em;color:var(--theme-color-std-text)}.text-l.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.25em;color:var(--theme-color-std-text)}.text-l-title.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-title-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.25em;color:var(--theme-color-std-text)}.text-h2.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:700;line-height:1.455em;color:var(--theme-color-std-text)}.text-xl.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:400;line-height:1.091em;color:var(--theme-color-std-text)}a.sc-ix-menu-settings{color:var(--theme-color-primary)}.sc-ix-menu-settings-h{display:block;background-color:var(--theme-nav-overlay--background);padding:0.75rem 1rem 1rem 2rem;flex-grow:1;position:absolute;width:100%;height:100%}.sc-ix-menu-settings-h .settings-header.sc-ix-menu-settings{display:flex;justify-content:space-between;flex-direction:row;align-items:center;height:2rem;margin-bottom:0.5rem}.sc-ix-menu-settings-h .settings-header.sc-ix-menu-settings h2.sc-ix-menu-settings{color:var(--theme-nav-overlay-header--color);margin-bottom:0}.sc-ix-menu-settings-h .settings-tabs.sc-ix-menu-settings{margin-bottom:1.5rem}";const x=class{constructor(e){t(this,e),this.label=void 0}render(){return i(s,null,i("slot",null))}};x.style=".sc-ix-menu-settings-item-h{display:block}";export{m as ix_menu,h as ix_menu_about,l as ix_menu_about_item,c as ix_menu_about_news,u as ix_menu_avatar,d as ix_menu_avatar_item,b as ix_menu_item,g as ix_menu_settings,x as ix_menu_settings_item}
|
|
1
|
+
import{r as t,c as e,h as i,H as s,g as n,f as o}from"./p-5c038d1d.js";import{a}from"./p-c8cc3bb3.js";class r{constructor(t,e,i){this.hostElement=t,this.popoverElement=e,this.outsideCallback=i}outside(t){var e;(null===(e=this.hostElement)||void 0===e?void 0:e.contains(t.target))||this.outsideCallback(t)}open(t=256){this.popoverElement.style.transform=`\n translateX(${this.hostElement.offsetLeft+this.hostElement.offsetWidth}px)\n translateY(-${this.hostElement.offsetHeight}px)\n `,this.popoverElement.style.maxWidth=a(t),document.body.addEventListener("click",this.outside.bind(this))}destroy(){document.body.removeEventListener("click",this.outside.bind(this))}}const m=class{constructor(i){t(this,i),this.expandChange=e(this,"expandChange",7),this.mapExpandChange=e(this,"mapExpandChange",7),this.domObserver=new MutationObserver(this.onDomChange.bind(this)),this.isVisible=t=>{var e,i;return"none"!==t.style.display&&"none"!==(null===(i=null===(e=t.parentElement)||void 0===e?void 0:e.parentElement)||void 0===i?void 0:i.style.display)},this.showSettings=!1,this.showAbout=!1,this.enableToggleTheme=!1,this.enableSettings=!0,this.enableMapExpand=!1,this.applicationName=void 0,this.applicationDescription="",this.maxVisibleMenuItems=9,this.i18nLegal="About & legal information",this.i18nSettings="Settings",this.i18nToggleTheme="Toggle theme",this.i18nExpand=" Expand",this.i18nCollapse="Collapse",this.i18nMore="More…",this.expand=!1,this.showMoreItems=!1,this.visibleMenuItems=0,this.countMoreNotifications=0,this.mapExpand=!0,this.activeTab=void 0,this.isMoreTabEmpty=!1}onWindowResize(){this.visibleMenuItems=this.getMaxTabCount()}handleNodeMutation(t){t instanceof HTMLElement&&(t.matches(".tab")&&this.onWindowResize(),t.matches("ix-menu-about")&&this.menu.contains(t)&&this.appendAbout(),t.matches("ix-menu-settings")&&this.menu.contains(t)&&this.appendSettings())}onDomChange(t){t.forEach((t=>{t.addedNodes.forEach(this.handleNodeMutation.bind(this)),t.removedNodes.forEach(this.handleNodeMutation.bind(this))}))}get popoverArea(){return this.hostElement.querySelector("#popover-area")}get overlayContainer(){return this.hostElement.querySelector(".menu-overlay")}get invisibleContainer(){return this.hostElement.querySelector(".menu-overlay-invisible")}get menu(){return this.hostElement.querySelector(".menu")}get menuItems(){return Array.from(this.hostElement.querySelectorAll("ix-menu-item:not(.internal-tab):not(.home-tab):not(.bottom-tab)")).filter(this.isVisible)}get menuBottomItems(){return Array.from(this.hostElement.querySelectorAll("ix-menu-item.bottom-tab:not(.internal-tab):not(.home-tab)")).filter(this.isVisible)}get homeTab(){return this.hostElement.querySelector("ix-menu-item.home-tab")}get moreItemsDropdown(){return this.hostElement.querySelector(".internal-tab ix-dropdown")}get isMoreItemsDropdownEmpty(){return 0===this.hostElement.querySelectorAll(".internal-tab ix-dropdown .appended").length}get moreItemsDropdownItems(){return this.hostElement.querySelectorAll(".internal-tab ix-dropdown ix-menu-item")}get activeMoreTabContainer(){return this.hostElement.querySelector(".active-more-tab")}get activeMoreTab(){return this.hostElement.querySelector(".active-more-tab ix-menu-item")}get aboutPopoverContainer(){return this.hostElement.querySelector(".about-news")}get aboutPopover(){return document.querySelector("ix-menu-about-news")}get aboutTab(){return this.hostElement.querySelector("#aboutAndLegal")}get about(){return this.hostElement.querySelector("ix-menu-about")}get settings(){return this.hostElement.querySelector("ix-menu-settings")}get isSettingsEmpty(){return 0===Array.from(this.hostElement.querySelectorAll("ix-menu-settings-item")).length}get avatarItem(){return this.hostElement.querySelector("ix-menu-avatar")}get tabsContainer(){return this.hostElement.querySelector("#menu-tabs")}showTab(t){return t+1<=this.visibleMenuItems}componentDidLoad(){var t,e,i,s;const n=this.hostElement.querySelector("#more-tab");this.popoverListener=new r(n,this.moreItemsDropdown,(()=>{this.showMoreItems=!1})),null===(t=this.settings)||void 0===t||t.addEventListener("close",(()=>{this.showSettings=!1,this.settings.show=this.showSettings})),null===(e=this.settings)||void 0===e||e.addEventListener("animationend",(()=>{this.showSettings||(this.settings.classList.add("d-none"),this.overlayContainer.classList.add("d-none"))})),null===(i=this.about)||void 0===i||i.addEventListener("close",(()=>{this.showAbout=!1,this.about.show=this.showAbout})),null===(s=this.about)||void 0===s||s.addEventListener("animationend",(()=>{this.showAbout||(this.about.classList.add("d-none"),this.overlayContainer.classList.add("d-none"))})),this.overlayContainer.classList.add("d-none"),this.onWindowResize(),this.domObserver.observe(this.hostElement,{attributes:!1,childList:!0,subtree:!0})}disconnectedCallback(){var t;null===(t=this.popoverListener)||void 0===t||t.destroy()}componentWillRender(){this.appendTabs()}componentDidRender(){this.visibleMenuItems=this.getMaxTabCount(),this.appendFragments()}appendFragments(){this.appendAvatar(),this.appendAbout(),this.appendSettings(),this.appendAboutNewsPopover(),this.isMoreTabEmpty=this.isMoreItemsDropdownEmpty,this.countMoreNotifications=this.getMoreNotificationsCount()}resetActiveTab(){this.activeTab=null}isMenuItemActive(t){return t.active||t.classList.contains("active")}appendTabs(){this.activeTab=null,this.homeTab&&(this.hostElement.querySelector(".tabs-top").appendChild(this.homeTab),this.homeTab.addEventListener("click",this.resetOverlay)),this.menuItems.forEach(((t,e)=>{var i;this.showTab(e)?t.classList.remove("d-none"):(t.classList.add("d-none"),this.isMenuItemActive(t)&&(this.activeTab=t)),null===(i=this.homeTab)||void 0===i||i.classList.remove("d-none"),t.addEventListener("click",this.resetOverlay)}))}appendAvatar(){var t;const e=this.avatarItem;e&&(e.style.marginBottom="1rem",null===(t=this.hostElement.querySelector("#avatar-tab-placeholder"))||void 0===t||t.appendChild(e))}getAboutPopoverVerticalPosition(){const t=this.aboutTab.getBoundingClientRect(),e=window.innerHeight-(t.bottom-t.height/2+6+6);return a(e)}appendAboutNewsPopover(){var t;this.aboutPopover&&(this.aboutPopover.style.bottom=this.getAboutPopoverVerticalPosition(),!(null===(t=this.popoverArea)||void 0===t?void 0:t.contains(this.aboutPopover)))&&(this.aboutPopover.addEventListener("showMore",(()=>{var t;(null===(t=this.aboutPopover)||void 0===t?void 0:t.aboutItemLabel)&&(this.about.activeTabLabel=this.aboutPopover.aboutItemLabel,this.toggleAbout(!0))}).bind(this)),document.body.appendChild(this.aboutPopover))}appendSettings(){this.settings&&this.overlayContainer.appendChild(this.settings)}appendAbout(){this.about&&this.overlayContainer.appendChild(this.about)}getMoreNotificationsCount(){var t;const e=null===(t=this.moreItemsDropdown)||void 0===t?void 0:t.querySelectorAll(".appended");let i=0;return null==e||e.forEach((t=>{t.notifications&&(i+=t.notifications)})),i}getAvailableHeight(){let t=this.hostElement.clientHeight;return t-=60,this.avatarItem&&(t-=56),this.homeTab&&(t-=72),this.showAbout&&(t-=36),this.showSettings&&(t-=36),this.menuBottomItems.length&&(t-=36*this.menuBottomItems.length),this.enableMapExpand&&(t-=36),t-=72,t-=16,t}getMaxTabCount(){const t=this.getAvailableHeight(),e=Math.floor(t/48),i=this.menuItems.length;return 1===i?1:i<this.maxVisibleMenuItems?e>i?i:Math.min(e-2,i):i===this.maxVisibleMenuItems?e<this.maxVisibleMenuItems?e-2:e===this.maxVisibleMenuItems?this.maxVisibleMenuItems-2:Math.min(e,this.maxVisibleMenuItems):e===this.maxVisibleMenuItems?this.maxVisibleMenuItems-2:e>=this.maxVisibleMenuItems?this.maxVisibleMenuItems-1:Math.min(e-2,this.maxVisibleMenuItems)}toggleShowMoreDropdown(){0!==this.moreItemsDropdown.querySelectorAll(".appended").length&&(this.popoverListener.open(),this.showMoreItems=!this.showMoreItems)}async toggleMapExpand(t){this.skipAllOverlayAnimations(),this.mapExpand=void 0!==t?t:!this.mapExpand}skipAllOverlayAnimations(){this.about&&this.skipOverlayAnimationFor(this.about),this.settings&&this.skipOverlayAnimationFor(this.settings)}skipOverlayAnimationFor(t){const e="animate__animated";null==t||t.classList.remove(e),setTimeout((()=>{null==t||t.classList.add(e)}),300)}async toggleMenu(t){this.skipAllOverlayAnimations(),this.expand=void 0!==t?t:!this.expand,this.aboutPopover&&(this.aboutPopover.expanded=this.expand),this.expandChange.emit(this.expand)}async toggleSettings(t){var e;this.showAbout?this.skipAllOverlayAnimations():this.skipOverlayAnimationFor(this.about),null===(e=this.about)||void 0===e||e.classList.add("d-none"),this.resetOverlay(),this.showSettings=t,this.settings.show=this.showSettings,this.settings.classList.remove("d-none"),this.overlayContainer.classList.remove("d-none")}async toggleAbout(t){var e;this.showSettings?this.skipAllOverlayAnimations():this.skipOverlayAnimationFor(this.settings),null===(e=this.settings)||void 0===e||e.classList.add("d-none"),this.resetOverlay(),this.showAbout=t,this.about.show=this.showAbout,this.about.classList.remove("d-none"),this.overlayContainer.classList.remove("d-none")}resetOverlay(){this.showSettings=!1,this.showAbout=!1,this.settings&&(this.settings.show=this.showSettings),this.about&&(this.about.show=this.showAbout)}showMoreButton(){const t=this.menuItems.length;return 1!==t&&(t<this.maxVisibleMenuItems?this.visibleMenuItems<t:t>this.maxVisibleMenuItems?this.visibleMenuItems<this.maxVisibleMenuItems:this.visibleMenuItems<=this.maxVisibleMenuItems-2)}getCollapseText(){return this.mapExpand?this.i18nCollapse:this.i18nExpand}getCollapseIcon(){return this.mapExpand?"double-chevron-left":"double-chevron-right"}isMenuItemClicked(t){return t.composedPath().filter((t=>"more-tab"!==t.id)).filter((t=>"IX-MENU-ITEM"===t.tagName)).some((t=>this.tabsContainer.contains(t)))}render(){return i(s,{class:{expanded:this.expand}},i("div",{class:{menu:!0,expanded:this.expand},onClick:()=>{this.resetActiveTab()}},i("div",{onClick:async()=>this.toggleMenu(),class:{"burger-menu-button":!0,expanded:this.expand}},i("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:"32",height:"32"},i("rect",{class:"line line-1",x:"5",y:"9.5",width:"22",height:"2"}),i("rect",{class:"line line-2",x:"5",y:"15.5",width:"22",height:"2"}),i("rect",{class:"line line-3",x:"5",y:"21.5",width:"22",height:"2"}))),i("div",{id:"avatar-tab-placeholder"}),i("div",{id:"menu-tabs",style:{display:"contents"},onClick:t=>{this.isMenuItemClicked(t)&&this.resetOverlay()}},i("div",{class:"tabs-top"}),i("slot",null),i("div",{class:"active-more-tab"},this.activeTab?i("ix-menu-item",{class:"internal-tab",active:!0,tabIcon:this.activeTab.tabIcon},this.activeTab.innerText):null),i("ix-menu-item",{id:"more-tab",tabIcon:"more-menu",class:{"internal-tab":!0},style:{display:this.showMoreButton()?"block":"none"},title:"Show more",notifications:this.countMoreNotifications,onClick:()=>this.toggleShowMoreDropdown()},this.i18nMore,i("ix-dropdown",{show:this.showMoreItems},this.menuItems.filter(((t,e)=>!this.showTab(e)&&!this.isMenuItemActive(t)&&this.isVisible(t))).map((t=>i("ix-menu-item",{tabIcon:t.tabIcon,active:t.active,class:"internal-tab appended",onClick:()=>t.dispatchEvent(new CustomEvent("click"))},t.innerText)))))),i("div",{class:"bottom-tab-divider"}),this.enableSettings&&!this.isSettingsEmpty?i("ix-menu-item",{id:"settings",class:{"internal-tab":!0,"bottom-tab":!0,active:this.showSettings},tabIcon:"cogwheel",onClick:async()=>this.toggleSettings(!this.showSettings)},this.i18nSettings):null,i("slot",{name:"bottom"}),i("div",{id:"popover-area"}),this.about?i("ix-menu-item",{id:"aboutAndLegal",class:{"internal-tab":!0,"bottom-tab":!0,active:this.showAbout},tabIcon:"info",onClick:async()=>this.toggleAbout(!this.showAbout)},this.i18nLegal):null,this.enableToggleTheme?i("ix-menu-item",{id:"toggleTheme",onClick:()=>(()=>{let t=Array.from(document.body.classList).find((t=>t.includes("theme-")));t||(t="theme-classic-dark");const e=t.endsWith("-dark");let i=t;i=e?t.replace(/-dark$/g,"-light"):t.replace(/-light$/g,"-dark"),document.body.classList.remove(t),document.body.classList.add(i)})(),class:"internal-tab bottom-tab",tabIcon:"bulb"},this.i18nToggleTheme):null,this.enableMapExpand?i("ix-menu-item",{id:"menu-collapse",onClick:()=>this.mapExpandChange.emit(this.mapExpand),class:"internal-tab bottom-tab",tabIcon:`${this.getCollapseIcon()}`},this.getCollapseText()):null),i("div",{class:{"menu-overlay":!0,expanded:this.expand,"d-block":this.showAbout||this.showSettings},style:{opacity:this.showAbout||this.showSettings?"1":"0"}}),i("div",{class:"menu-overlay-invisible"}))}get hostElement(){return n(this)}};m.style="ix-menu{display:flex;flex-direction:row;position:absolute;height:100%;min-height:22.75rem;z-index:var(--theme-z-index-sticky);width:auto}ix-menu .menu{display:flex;flex-direction:column;position:relative;width:4rem;height:100%;-webkit-padding-after:1rem;padding-block-end:1rem;background-color:var(--theme-nav--background);transition:width var(--animate-duration)}ix-menu .menu.expanded{box-shadow:var(--theme-navigation--box-shadow)}ix-menu .menu .burger-menu-button{display:flex;justify-content:center;margin-top:0.75rem;margin-left:0.75rem;margin-bottom:1rem;height:2rem;width:2.5rem;border-radius:0.25rem}ix-menu .menu .burger-menu-button:not(.disabled):not(:disabled).hover,ix-menu .menu .burger-menu-button:not(.disabled):not(:disabled):hover{background-color:var(--theme-ghost--background--hover)}ix-menu .menu .burger-menu-button:not(.disabled):not(:disabled).active,ix-menu .menu .burger-menu-button:not(.disabled):not(:disabled):active{background-color:var(--theme-ghost--background--active)}ix-menu .menu .burger-menu-button svg{display:inline-block;fill:var(--theme-menu-btn--color);position:relative}ix-menu .menu .burger-menu-button svg .line{opacity:1;transform:rotate(0) translateY(0) translateX(0);transition:transform 0.3s ease-in-out, opacity 0.2s ease-in-out}ix-menu .menu .burger-menu-button.expanded svg .line-1{transform:translate(0.6875rem, -0.05rem) rotate(45deg)}ix-menu .menu .burger-menu-button.expanded svg .line-2{opacity:0}ix-menu .menu .burger-menu-button.expanded svg .line-3{transform:translate(-0.75625rem, 0.8125rem) rotate(-45deg)}ix-menu .menu-overlay{display:block;position:absolute;width:calc(100vw - 4rem);height:100%;left:4rem;z-index:-1;-webkit-backdrop-filter:blur(1rem);backdrop-filter:blur(1rem);background-color:var(--theme-sidebar-overlay-blur);transition:all 150ms ease-out}ix-menu .menu-overlay-invisible{display:none}ix-menu .menu.expanded{width:16rem}ix-menu .menu-overlay.expanded{width:calc(100vw - 16rem);left:16rem}ix-menu #avatar-tab-placeholder{max-height:3rem}ix-menu .avatar{margin-bottom:2rem}ix-menu #cui-imprint .cui-imprint-product-name{margin-bottom:1rem}ix-menu #cui-imprint .cui-imprint-product-description{margin-bottom:2rem}ix-menu #cui-imprint .cui-imprint-link-container{display:flex;align-items:center}ix-menu .bottom-tab-divider{margin-top:auto}";const h=class{constructor(i){t(this,i),this.close=e(this,"close",7),this.activeTabLabel=void 0,this.label="About & legal information",this.show=!1,this.labels=[]}get aboutItems(){return Array.from(this.el.querySelectorAll("ix-menu-about-item"))}setTab(t){this.activeTabLabel=t,this.aboutItems.forEach((t=>{t.style.display="none",t.label===this.activeTabLabel&&(t.style.display="block")}))}componentWillLoad(){this.aboutItems.length&&this.setTab(this.activeTabLabel||this.aboutItems[0].label)}componentDidLoad(){o(this.el)}componentWillRender(){this.updateLabels()}updateLabels(){this.labels=this.aboutItems.map((t=>t.label))}watchActiveTabLabel(t){setTimeout((()=>this.setTab(t)))}getSelectedTabIndex(t){const e=this.aboutItems.find((e=>e.label===t));return this.aboutItems.indexOf(e)}getTabItems(){return this.aboutItems.map((({label:t})=>i("ix-tab-item",{class:{active:t===this.activeTabLabel},onClick:()=>this.setTab(t)},t)))}render(){return i(s,{class:{animate__animated:!0,animate__fadeInLeft:this.show,animate__fadeOutLeft:!this.show}},i("div",{class:"about-header"},i("h2",{class:"text-h2"},this.label),i("ix-icon-button",{ghost:!0,size:"24",icon:"close",onClick:t=>this.close.emit(t)})),i("ix-tabs",{selected:this.getSelectedTabIndex(this.activeTabLabel),class:"about-tabs"},this.getTabItems()),i("div",{class:"about-items"},i("slot",null)))}get el(){return n(this)}static get watchers(){return{activeTabLabel:["watchActiveTabLabel"]}}};h.style=".text-xs.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.625rem;font-weight:400;line-height:1.4em;color:var(--theme-color-std-text)}.text-s.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1em;color:var(--theme-color-std-text)}.text-default.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.143em;color:var(--theme-color-std-text)}.text-default-title.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-title-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.143em;color:var(--theme-color-std-text)}.text-l.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.25em;color:var(--theme-color-std-text)}.text-l-title.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-title-single.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.25em;color:var(--theme-color-std-text)}.text-h2.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:700;line-height:1.455em;color:var(--theme-color-std-text)}.text-xl.sc-ix-menu-about{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:400;line-height:1.091em;color:var(--theme-color-std-text)}a.sc-ix-menu-about{color:var(--theme-color-primary)}.sc-ix-menu-about-h{display:block;background-color:var(--theme-nav-overlay--background);padding:0.75rem 1rem 1rem 2rem;flex-grow:1;position:absolute;width:100%;height:100%}.sc-ix-menu-about-h .about-header.sc-ix-menu-about{display:flex;justify-content:space-between;flex-direction:row;align-items:center;height:2rem;margin-bottom:0.5rem}.sc-ix-menu-about-h .about-header.sc-ix-menu-about h2.sc-ix-menu-about{color:var(--theme-nav-overlay-header--color);margin-bottom:0}.sc-ix-menu-about-h .about-tabs.sc-ix-menu-about{margin-bottom:1.5rem}.sc-ix-menu-about-h ix-menu-about-item.sc-ix-menu-about{display:none}";const l=class{constructor(e){t(this,e),this.label=void 0}render(){return i(s,null,i("slot",null))}};l.style=".sc-ix-menu-about-item-h{display:block}";const c=class{constructor(i){t(this,i),this.showMore=e(this,"showMore",7),this.closePopover=e(this,"closePopover",7),this.show=!1,this.label=void 0,this.i18nShowMore="Show more",this.aboutItemLabel=void 0,this.offsetBottom=0,this.expanded=!1}render(){return i(s,{class:{expanded:this.expanded,show:!this.show}},i("div",{class:"banner-container"},i("ix-icon",{color:"color-inv-contrast-text",name:"shout",size:"32"}),i("svg",{viewBox:"0 0 48 56",xmlns:"http://www.w3.org/2000/svg"},i("polygon",{points:"0 0 48 0 48 56 24 48 0 56"}))),i("div",{class:"cui-popover-news-header"},i("span",{class:"text-l-title"},this.label)),i("ix-icon-button",{size:"24",icon:"close-small",ghost:!0,onClick:()=>{this.show=!1,this.closePopover.emit()}}),i("slot",null),this.aboutItemLabel?i("div",{class:"cui-popover-news-footer"},i("button",{class:"btn btn-primary",onClick:t=>{this.show=!1,this.showMore.emit(t)}},this.i18nShowMore)):null,i("svg",{id:"arrow",xmlns:"http://www.w3.org/2000/svg",width:"8",height:"12",viewBox:"0 0 8 12"},i("path",{d:"M8 0 L0 6 L8 12"})))}};c.style=".sc-ix-menu-about-news-h{display:block;position:fixed;width:20rem;height:auto;background-color:var(--theme-color-1);border:var(--theme-weak-bdr-1);border-radius:0.25rem;padding:1rem;left:4rem;z-index:10000;transition:left var(--animate-duration);margin-left:0.5rem !important;box-shadow:var(--theme-box-shadow-level-2)}.expanded.sc-ix-menu-about-news-h{left:calc(4rem + 12rem)}.show.sc-ix-menu-about-news-h{display:none}.sc-ix-menu-about-news-h .banner-container.sc-ix-menu-about-news{position:absolute;top:0.0625rem;left:1rem}.sc-ix-menu-about-news-h .banner-container.sc-ix-menu-about-news svg.sc-ix-menu-about-news{position:absolute;height:3.625rem;width:3rem}.sc-ix-menu-about-news-h .banner-container.sc-ix-menu-about-news svg.sc-ix-menu-about-news polygon.sc-ix-menu-about-news{fill:var(--theme-color-primary)}.sc-ix-menu-about-news-h .banner-container.sc-ix-menu-about-news ix-icon.sc-ix-menu-about-news{margin:0.5rem;position:absolute;z-index:1}.sc-ix-menu-about-news-h .cui-popover-news-header.sc-ix-menu-about-news{margin-bottom:2rem;margin-left:4rem;margin-top:-0.25rem}.sc-ix-menu-about-news-h .popover-body.sc-ix-menu-about-news{color:var(--theme-color-std-text)}.sc-ix-menu-about-news-h .cui-popover-news-footer.sc-ix-menu-about-news{display:flex;justify-content:flex-end;margin-top:1rem}.sc-ix-menu-about-news-h #arrow.sc-ix-menu-about-news{bottom:14px;position:relative;left:-10px}.sc-ix-menu-about-news-h ix-icon-button.sc-ix-menu-about-news{top:0.5rem;right:0.5rem;position:absolute}.sc-ix-menu-about-news-h svg#arrow.sc-ix-menu-about-news{position:absolute;left:-0.5rem;bottom:0.4rem}.sc-ix-menu-about-news-h svg#arrow.sc-ix-menu-about-news path.sc-ix-menu-about-news{fill:var(--theme-color-1);stroke:var(--theme-color-weak-bdr-1)}";const u=class{constructor(i){t(this,i),this.logoutClick=e(this,"logoutClick",7),this.displayMenu=void 0,this.top=void 0,this.bottom=void 0,this.i18nLogout="Logout"}toggleMenu(){this.outsideListener.open(),this.displayMenu=!this.displayMenu}componentDidLoad(){this.outsideListener=new r(this.hostElement,this.hostElement.querySelector("ix-dropdown"),(()=>{this.displayMenu=!1}))}disconnectedCallback(){var t;null===(t=this.outsideListener)||void 0===t||t.destroy()}render(){return i(s,null,i("li",{class:"nav-item top-item avatar no-hover",title:this.top},i("svg",{xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"},i("g",{fill:"none","fill-rule":"evenodd"},i("path",{id:"avatar-path-background",d:"M16 0C7.163 0 0 7.163 0 16s7.163 16 16 16 16-7.163\n 16-16c0-4.243-1.686-8.313-4.686-11.314C24.314 1.686 20.244 0 16 0z"}),i("path",{id:"avatar-path-person",d:"M17.897 17.91c3.8-.018 7.358 1.875 9.485 5.046-2.417 3.999-6.734 6.434-11.382\n 6.42-4.648.014-8.965-2.421-11.382-6.42 2.127-3.171 5.685-5.064\n 9.485-5.045h3.794zM15.821 2.129c3.682 0 6.667 2.984 6.667 6.666 0 3.682-2.985\n 6.667-6.667 6.667s-6.667-2.985-6.667-6.667 2.985-6.666 6.667-6.666z"}))),i("div",{class:"avatar-name"},i("span",{class:"text-default-single",title:this.top},this.top),i("span",{class:"text-default-single",title:this.bottom},this.bottom))),i("ix-dropdown",{show:this.displayMenu},i("slot",null),i("ix-menu-avatar-item",{label:this.i18nLogout,icon:"log-out",onClick:t=>{this.logoutClick.emit(t)}})))}get hostElement(){return n(this)}};u.style=".sc-ix-menu-avatar-h{display:block;position:relative;margin-bottom:0.5rem}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar{display:flex;align-items:center;height:2.5rem;max-height:2.5rem;padding-left:0.25rem;margin-left:0.75rem;margin-right:0.75rem;transition:0.15s;border-radius:1.25rem}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar>svg.sc-ix-menu-avatar{height:2rem;width:2rem;min-height:2rem;min-width:2rem}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar #avatar-path-background.sc-ix-menu-avatar{fill:var(--theme-avatar--background)}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar #avatar-path-person.sc-ix-menu-avatar{fill:var(--theme-color-4)}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar .avatar-name.sc-ix-menu-avatar{display:flex;flex-direction:column;overflow:hidden;white-space:nowrap;margin-left:1rem;line-height:1.14}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar .avatar-name.sc-ix-menu-avatar .text-default-single.sc-ix-menu-avatar{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar:not(.disabled):not(:disabled):hover{background-color:var(--theme-avatar-btn--background--hover);color:var(--theme-avatar-btn--color--hover)}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-menu-avatar-h .avatar.sc-ix-menu-avatar:not(.disabled):not(:disabled):active{background-color:var(--theme-avatar-btn--background--active);color:var(--theme-avatar-btn--color--active)}";const d=class{constructor(i){t(this,i),this.itemClick=e(this,"itemClick",7),this.icon=void 0,this.label=void 0}render(){return i("ix-dropdown-item",{icon:this.icon,label:this.label,onClick:t=>this.itemClick.emit(t)})}get hostElement(){return n(this)}};d.style=".sc-ix-menu-avatar-item-h{display:block}";const b=class{constructor(e){t(this,e),this.home=!1,this.bottom=!1,this.tabIcon="document",this.notifications=void 0,this.active=void 0,this.disabled=void 0,this.title=void 0}get tabLabel(){return this.hostElement.querySelector(".tab-text")}componentDidRender(){const t=this.tabLabel.innerHTML.replace("&","&");this.title!==t&&(this.title=t)}render(){return i(s,{class:{disabled:this.disabled,"home-tab":this.home,"bottom-tab":this.bottom,active:this.active}},i("li",{class:"tab",title:this.title},i("i",{class:`glyph glyph-${this.tabIcon}`},i("div",{class:"notification"},this.notifications?i("div",{class:"pill"},this.notifications):null)),i("span",{class:"tab-text text-default"},i("slot",null))))}get hostElement(){return n(this)}};b.style='ix-menu-item{position:relative;display:block}ix-menu-item .tab{display:flex;position:relative;align-items:center;height:3rem;z-index:500;padding-left:1.25rem}ix-menu-item .tab:not(.selected){cursor:pointer}ix-menu-item .tab:not(.selected):not(.disabled):not(:disabled).hover,ix-menu-item .tab:not(.selected):not(.disabled):not(:disabled):hover{background-color:var(--theme-ghost--background--hover)}ix-menu-item .tab:not(.selected):not(.disabled):not(:disabled).active,ix-menu-item .tab:not(.selected):not(.disabled):not(:disabled):active{background-color:var(--theme-ghost--background--active)}ix-menu-item i.glyph{color:var(--theme-nav-item-primary-icon--color);position:relative}ix-menu-item .tab:focus-visible{outline:none}ix-menu-item:focus-visible{outline:none}ix-menu-item .tab:not(:last-child){margin-bottom:0.5rem}ix-menu-item .notification{display:inline-flex;position:absolute;top:-0.5rem;right:-50%}ix-menu-item .notification .pill{display:inline-flex;justify-content:center;align-items:center;height:1rem;min-width:1rem;position:relative;border-radius:6.25rem;background-color:var(--theme-color-primary);border-radius:6.25rem;font-size:0.75rem;font-weight:bold;line-height:1;font-family:Siemens Sans, Arial, sans-serif;color:var(--theme-color-primary--contrast);padding:0.25rem}ix-menu-item .tab-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--theme-nav-item-primary--color);margin:0 1.25rem;-webkit-user-select:none;-moz-user-select:none;user-select:none}ix-menu-item.active .tab,ix-menu-item.selected .tab{background-color:var(--theme-nav-item-primary--background--selected)}ix-menu-item.active .tab::before,ix-menu-item.selected .tab::before{content:"";background-color:var(--theme-nav-item-primary--border-color--selected);height:3rem;width:0.25rem;left:0;position:absolute}ix-menu-item.active .tab>.glyph,ix-menu-item.selected .tab>.glyph{color:var(--theme-nav-item-primary-icon--color--selected)}ix-menu-item.disabled{color:var(--theme-color-weak-text);pointer-events:none;cursor:default}ix-menu-item.disabled .tab>.glyph{color:var(--theme-color-weak-text)}ix-menu-item.disabled .tab-text{color:var(--theme-color-weak-text)}ix-menu-item.home-tab,ix-menu-item[slot=home]{margin-bottom:1.5rem}ix-menu-item.bottom-tab,ix-menu-item[slot=bottom]{height:2.25rem}ix-menu-item.bottom-tab .tab,ix-menu-item[slot=bottom] .tab{height:2.25rem}ix-menu-item.bottom-tab .tab::before,ix-menu-item[slot=bottom] .tab::before{height:2.25rem}ix-menu-item.bottom-tab.active .tab,ix-menu-item.bottom-tab.selected .tab,ix-menu-item[slot=bottom].active .tab,ix-menu-item[slot=bottom].selected .tab{background-color:var(--theme-color-1)}';const g=class{constructor(i){t(this,i),this.close=e(this,"close",7),this.activeTabLabel=void 0,this.label="Settings",this.show=!1}get settingsItems(){return Array.from(this.el.querySelectorAll("ix-menu-settings-item"))}setTab(t){this.activeTabLabel=t,this.settingsItems.forEach((t=>{t.style.display="none",t.label===this.activeTabLabel&&(t.style.display="block")}))}componentWillLoad(){this.settingsItems.length&&this.setTab(this.activeTabLabel||this.settingsItems[0].label)}componentDidLoad(){o(this.el)}watchActiveTabLabel(t){this.setTab(t)}getTabItems(){return this.settingsItems.map((({label:t})=>i("ix-tab-item",{class:{active:t===this.activeTabLabel},onClick:()=>this.setTab(t)},t)))}render(){return i(s,{class:{animate__animated:!0,animate__fadeInLeft:this.show,animate__fadeOutLeft:!this.show}},i("div",{class:"settings-header"},i("h2",{class:"text-h2"},this.label),i("ix-icon-button",{ghost:!0,size:"24",icon:"close",onClick:t=>this.close.emit(t)})),i("ix-tabs",null,this.getTabItems()),i("slot",null))}get el(){return n(this)}static get watchers(){return{activeTabLabel:["watchActiveTabLabel"]}}};g.style=".text-xs.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.625rem;font-weight:400;line-height:1.4em;color:var(--theme-color-std-text)}.text-s.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-caption-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1em;color:var(--theme-color-std-text)}.text-default.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.143em;color:var(--theme-color-std-text)}.text-default-title.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.429em;color:var(--theme-color-std-text)}.text-default-title-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:700;line-height:1.143em;color:var(--theme-color-std-text)}.text-l.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:400;line-height:1.25em;color:var(--theme-color-std-text)}.text-l-title.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.5em;color:var(--theme-color-std-text)}.text-l-title-single.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1rem;font-weight:700;line-height:1.25em;color:var(--theme-color-std-text)}.text-h2.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:700;line-height:1.455em;color:var(--theme-color-std-text)}.text-xl.sc-ix-menu-settings{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:1.375rem;font-weight:400;line-height:1.091em;color:var(--theme-color-std-text)}a.sc-ix-menu-settings{color:var(--theme-color-primary)}.sc-ix-menu-settings-h{display:block;background-color:var(--theme-nav-overlay--background);padding:0.75rem 1rem 1rem 2rem;flex-grow:1;position:absolute;width:100%;height:100%}.sc-ix-menu-settings-h .settings-header.sc-ix-menu-settings{display:flex;justify-content:space-between;flex-direction:row;align-items:center;height:2rem;margin-bottom:0.5rem}.sc-ix-menu-settings-h .settings-header.sc-ix-menu-settings h2.sc-ix-menu-settings{color:var(--theme-nav-overlay-header--color);margin-bottom:0}.sc-ix-menu-settings-h .settings-tabs.sc-ix-menu-settings{margin-bottom:1.5rem}";const x=class{constructor(e){t(this,e),this.label=void 0}render(){return i(s,null,i("slot",null))}};x.style=".sc-ix-menu-settings-item-h{display:block}";export{m as ix_menu,h as ix_menu_about,l as ix_menu_about_item,c as ix_menu_about_news,u as ix_menu_avatar,d as ix_menu_avatar_item,b as ix_menu_item,g as ix_menu_settings,x as ix_menu_settings_item}
|
|
File without changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,h as a,H as i,c as e,g as s}from"./p-5c038d1d.js";import{a as n}from"./p-810b5232.js";import{A as o}from"./p-bdd294d2.js";import{c}from"./p-
|
|
1
|
+
import{r as t,h as a,H as i,c as e,g as s}from"./p-5c038d1d.js";import{a as n}from"./p-810b5232.js";import{A as o}from"./p-bdd294d2.js";import{c}from"./p-c8cc3bb3.js";const r=class{constructor(a){t(this,a),this.icon=void 0,this.count=void 0}render(){return a(i,null,a("slot",null))}};r.style=".sc-ix-animated-tab-h{display:block;height:100%;width:100%;position:absolute}";const d=class{constructor(a){t(this,a),this.tabClick=e(this,"tabClick",7),this.easing="easeInOutSine",this.firstRender=!0,this.tabs=void 0,this.activeIndex=void 0,this.disableAnimations=!1,this.selectedIndex=0,this.tabPlacement="top"}onTabSelectionChange(t,a){this.updateTabAnimation(a,t)}onMouseDown(){this.activeIndex=void 0}get animatedTabs(){return Array.from(this.hostElement.querySelectorAll("ix-animated-tab"))}get tabsContainer(){return this.hostElement.querySelector(".tabs-container")}get contentContainer(){return this.hostElement.querySelector(".content-container")}componentWillLoad(){this.tabs=this.animatedTabs}componentDidLoad(){this.onTabSelectionChange(this.selectedIndex,-1),this.observer=new MutationObserver((()=>{this.tabs=this.animatedTabs})),this.observer.observe(this.contentContainer,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["count"]})}disconnectCallback(){var t;null===(t=this.observer)||void 0===t||t.disconnect()}isSelected(t){return this.tabs.indexOf(t)===this.selectedIndex}showTab(t){this.isSelected(t)&&t.classList.remove("d-none")}hideTab(t){this.isSelected(t)||t.classList.add("d-none")}slideOutLeft(t){this.disableAnimations?this.hideTab(t):n({targets:t,duration:o.mediumTime,opacity:[1,0],translateX:[0,"-100%"],easing:this.easing,complete:()=>{this.hideTab(t)}})}slideOutRight(t){this.disableAnimations?this.hideTab(t):n({targets:t,duration:o.mediumTime,opacity:[1,0],translateX:[0,"100%"],easing:this.easing,complete:()=>{this.hideTab(t)}})}slideInLeft(t){if(this.firstRender)return t.classList.remove("d-none"),void(this.firstRender=!1);this.disableAnimations?this.showTab(t):n({targets:t,duration:o.mediumTime,opacity:[0,1],translateX:["-100%",0],easing:this.easing,begin:()=>{this.showTab(t)}})}slideInRight(t){if(this.firstRender)return t.classList.remove("d-none"),void(this.firstRender=!1);this.disableAnimations?this.showTab(t):n({targets:t,duration:o.mediumTime,opacity:[0,1],translateX:["100%",0],easing:this.easing,begin:()=>{this.showTab(t)}})}updateTabAnimation(t,a){var i;null===(i=this.tabs)||void 0===i||i.forEach(((i,e)=>{e===t?e<a?this.slideOutLeft(i):e>a&&this.slideOutRight(i):e===a?e<t?this.slideInLeft(i):e>t&&this.slideInRight(i):i.classList.add("d-none")}))}onTabClick(t){this.selectedIndex=t,this.tabClick.emit(t)}onTabMouseDown(t){this.activeIndex=t}render(){return a(i,{class:{"flex-column-reverse":"bottom"===this.tabPlacement}},a("ul",{class:"tabs-container"},this.animatedTabs.map(((t,i)=>a("li",{class:{bottom:"bottom"===this.tabPlacement},onClick:()=>this.onTabClick(i),onMouseDown:()=>this.onTabMouseDown(i)},a("div",{class:{"tab-container":!0,selected:this.selectedIndex===i}},a("ix-icon",{name:t.icon}),t.count?a("span",{class:{count:!0,bottom:"bottom"===this.tabPlacement}},c(t.count)):"")))),a("div",{class:{"tab-active-underline":!0,bottom:"bottom"===this.tabPlacement},style:{"margin-left":`calc(${this.selectedIndex} * 5rem)`}})),a("div",{class:"content-container"},a("slot",null)))}get hostElement(){return s(this)}static get watchers(){return{selectedIndex:["onTabSelectionChange"]}}};d.style=".sc-ix-animated-tabs-h{--animate-duration:300ms;display:flex;flex-direction:column;align-items:center;height:100%;width:100%;position:relative}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs{display:flex;padding:0;margin:0;position:relative}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs{display:flex;justify-content:center;width:5rem;height:4.5rem;cursor:pointer;padding-top:0.625rem}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.bottom.sc-ix-animated-tabs{padding-top:0.875rem}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs{background:var(--theme-animated-tab-circle--background);border:solid 1px var(--theme-animated-tab-circle--border-color);display:flex;align-items:center;justify-content:center;border-radius:6.25rem;width:3rem;height:3rem;position:relative;transition:150ms}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs ix-icon.sc-ix-animated-tabs{color:var(--theme-animated-tab-icon--color) !important}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs:not(.disabled):not(:disabled):hover{background:var(--theme-animated-tab-circle--background--hover);border-color:var(--theme-animated-tab-circle--border-color--hover)}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs:not(.disabled):not(:disabled):hover ix-icon.sc-ix-animated-tabs{color:var(--theme-animated-tab-icon--color--hover) !important}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs:not(.disabled):not(:disabled):active{background:var(--theme-animated-tab-circle--background--active);border-color:var(--theme-animated-tab-circle--border-color--active)}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs:not(.disabled):not(:disabled):active ix-icon.sc-ix-animated-tabs{color:var(--theme-animated-tab-icon--color--active) !important}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.selected.sc-ix-animated-tabs{background:var(--theme-animated-tab-circle--background--selected);border-color:var(--theme-animated-tab-circle--border-color--selected) !important}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.selected.sc-ix-animated-tabs ix-icon.sc-ix-animated-tabs{color:var(--theme-animated-tab-icon--color--selected) !important}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.selected.sc-ix-animated-tabs .count.sc-ix-animated-tabs{border-color:var(--theme-tab-pill--border-color--selected) !important}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.disabled.sc-ix-animated-tabs ix-icon.sc-ix-animated-tabs,.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs:disabled ix-icon.sc-ix-animated-tabs{color:var(--theme-animated-tab-icon--color--disabled) !important}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs:not(.disabled):not(:disabled):focus-visible{border-color:var(--theme-focus--border-color) !important}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs .count.sc-ix-animated-tabs{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.75rem;font-weight:700;line-height:1em;color:var(--theme-color-std-text);display:flex;align-items:center;height:1rem;position:absolute;background-color:var(--theme-pill-outline--background);bottom:-0.55rem;border:1px solid var(--theme-tab-pill--border-color);border-radius:6.25rem;color:var(--theme-pill-outline--color);padding:0 0.25rem;background:var(--theme-color-1);transition:150ms}.sc-ix-animated-tabs-h ul.sc-ix-animated-tabs li.sc-ix-animated-tabs .tab-container.sc-ix-animated-tabs .count.bottom.sc-ix-animated-tabs{top:-0.55rem}.sc-ix-animated-tabs-h .content-container.sc-ix-animated-tabs{display:flex;flex-direction:row;height:calc(100% - 4.5rem);width:100%;overflow-y:auto;overflow-x:hidden}.sc-ix-animated-tabs-h .tab-active-underline.sc-ix-animated-tabs{background-color:var(--theme-animated-tab-indicator--background--selected);height:0.125rem;width:5rem;margin-top:-0.125rem;transition:150ms;position:absolute;top:4.5rem}.sc-ix-animated-tabs-h .tab-active-underline.bottom.sc-ix-animated-tabs{top:0;margin-top:0}";export{r as ix_animated_tab,d as ix_animated_tabs}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{a as ix_modal,M as ix_modal_container}from"./p-2f07c86a.js";import"./p-5c038d1d.js";import"./p-4944ad0b.js";import"./p-810b5232.js";import"./p-bdd294d2.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as i,h as e,H as s,g as o}from"./p-5c038d1d.js";import{a as r}from"./p-0bf04780.js";import{L as c,I as a}from"./p-0a12b3df.js";const h=class{constructor(e){t(this,e),this.inputChanged=i(this,"inputChanged",7),this.filterChanged=i(this,"filterChanged",7),this.ID_CUSTOM_FILTER_VALUE="CW_CUSTOM_FILTER_VALUE",this.documentClickCallback=this.handleDocumentClick.bind(this),this.hasFocus=void 0,this.showCategorySelection=void 0,this.categoryLogicalOperator=c.EQUAL,this.inputValue=void 0,this.category=void 0,this.filterTokens=[],this.offsetDropdownX=void 0,this.offsetDropdownY=void 0,this.maxHeightDropdown=void 0,this.maxWidthDropdown=void 0,this.initialState=void 0,this.filterState=void 0,this.placeholder=void 0,this.categories=void 0,this.nonSelectableCategories={},this.suggestions=void 0,this.icon="search",this.hideIcon=void 0,this.repeatCategories=!0,this.tmpDisableScrollIntoView=!0,this.labelCategories="Categories",this.i18nPlainText="Filter by text"}watchFilterState(t){this.setFilterState(t)}watchShowCategorySelection(t){t?document.addEventListener("click",this.documentClickCallback):document.removeEventListener("click",this.documentClickCallback)}setDropdownOffset(){const t=this.calculateDropdownHeight();this.maxHeightDropdown=r(t)}componentDidLoad(){var t,i;void 0!==this.initialState?this.setFilterState(this.initialState):void 0!==this.filterState&&this.setFilterState(this.filterState),null===(t=this.hostElement)||void 0===t||t.addEventListener("keydown",this.handleFormElementKeyDown.bind(this)),null===(i=this.formElement)||void 0===i||i.addEventListener("submit",(t=>t.preventDefault())),null!=this.textInput?(this.textInput.addEventListener("click",(()=>this.showCategorySelection=!0)),this.textInput.addEventListener("focusin",(()=>{this.hasFocus=!0})),this.textInput.addEventListener("focusout",(()=>this.hasFocus=!1)),this.textInput.addEventListener("input",(()=>{this.inputValue=this.textInput.value;const t=new a(this.inputValue,this.category);this.inputChanged.emit(t),this.showCategorySelection=!0})),this.textInput.addEventListener("keydown",this.handleInputElementKeyDown.bind(this))):console.warn("Core UI category filter - unable to add event listeners to native input element")}setFilterState(t){this.filterTokens=[];for(const i of t.tokens)this.addToken(i,this.ID_CUSTOM_FILTER_VALUE,this.categoryLogicalOperator,!1);for(const i of t.categories)this.addToken(i.value,i.id,i.operator,!1);this.emitFilterEvent()}handleDocumentClick(t){this.hostElement.contains(t.target)||this.closeDropdown()}closeDropdown(){this.showCategorySelection=!1,this.category=void 0}handleFormElementKeyDown(t){switch(t.code){case"Enter":case"NumpadEnter":if(this.category||document.activeElement.classList.contains("plain-text-suggestion")){const t=document.activeElement.getAttribute("data-id");this.addToken(t,this.category)}else document.activeElement.classList.contains("category-item-id")&&this.selectCategory(document.activeElement.getAttribute("data-id"));t.preventDefault();break;case"ArrowUp":this.focusPreviousItem(),t.preventDefault();break;case"ArrowDown":this.focusNextItem(),t.preventDefault();break;case"Escape":this.closeDropdown()}}focusPreviousItem(){const t=document.activeElement.previousSibling;t instanceof HTMLElement&&t.focus()}focusNextItem(){const t=document.activeElement.nextSibling;t instanceof HTMLElement&&t.focus()}handleInputElementKeyDown(t){var i;switch(t.code){case"ArrowDown":let e=this.hostElement.querySelector(".category-item-"+(this.category?"value":"id"));e instanceof HTMLElement?(e.focus(),t.stopPropagation()):(null===(i=this.suggestions)||void 0===i?void 0:i.length)&&(e=this.hostElement.querySelector(".category-item"),e instanceof HTMLElement&&(e.focus(),t.stopPropagation()));break;case"Backspace":if(""!==this.textInput.value)return;if(this.category)return void(this.category=void 0);const s=this.filterTokens.length;s>0&&this.removeToken(s-1);break;case"Enter":case"NumpadEnter":this.addToken(this.inputValue,this.category),t.preventDefault()}}emitFilterEvent(){const t=this.filterTokens.filter((t=>t.id===this.ID_CUSTOM_FILTER_VALUE)).map((t=>t.value)),i=this.filterTokens.filter((t=>t.id!==this.ID_CUSTOM_FILTER_VALUE));this.filterChanged.emit({tokens:t,categories:i})}addToken(t,i=this.ID_CUSTOM_FILTER_VALUE,e=this.categoryLogicalOperator,s=!0){if(null==t)return;const o=t.trim();""!==o&&(this.filterTokens.find((t=>(null==t?void 0:t.value)===o))||(this.filterTokens=[...this.filterTokens,{id:i,value:o,operator:e}],this.textInput.value="",this.inputValue="",this.categoryLogicalOperator=c.EQUAL,this.isScrollStateDirty=!0,this.textInput.focus(),s&&this.emitFilterEvent(),this.closeDropdown()))}removeToken(t){this.filterTokens=this.filterTokens.filter(((i,e)=>e!==t)),this.emitFilterEvent()}getCategoryIds(){const t=[];for(const i in this.categories)Object.prototype.hasOwnProperty.call(this.categories,i)&&t.push(i);return t}getCategoryLables(){return this.getCategoryIds().map((t=>this.categories[t].label))}selectCategory(t){this.category=t,this.textInput.value="",this.inputValue="",this.textInput.focus()}openCategorySelection(){this.showCategorySelection=!0}resetFilter(){this.closeDropdown(),this.filterTokens=[],this.emitFilterEvent()}calculateDropdownX(){var t;return this.textInput?this.textInput.getBoundingClientRect().x-(null===(t=this.formElement)||void 0===t?void 0:t.getBoundingClientRect().x):0}calculateDropdownY(){return this.textInput?this.hostElement.getBoundingClientRect().height:32}calculateDropdownHeight(t=32){const i=this.hostElement.getBoundingClientRect().top;return window.innerHeight-(i+t)}filterMultiples(t){return!!this.repeatCategories||!this.filterTokens.find((i=>i.id===t))}filterDuplicateTokens(t){return!this.filterTokens.some((i=>i.value===t))}filterByInput(t){return void 0===this.inputValue||""===this.inputValue||-1!==t.toLowerCase().indexOf(this.inputValue.toLowerCase())}toggleCategoryOperator(){switch(this.categoryLogicalOperator){case c.EQUAL:this.categoryLogicalOperator=c.NOT_EQUAL;break;case c.NOT_EQUAL:this.categoryLogicalOperator=c.EQUAL}}getFilterChipLabel(t){var i,e,s;return t.id===this.ID_CUSTOM_FILTER_VALUE?t.value:`${null!==(s=null!==(e=null===(i=this.categories[t.id])||void 0===i?void 0:i.label)&&void 0!==e?e:this.nonSelectableCategories[t.id])&&void 0!==s?s:t.id} ${t.operator===c.EQUAL?"=":"!="} ${t.value}`}componentDidRender(){const t=this.calculateDropdownX(),i=this.calculateDropdownY(),e=r(t),s=r(i),o=this.hostElement.getBoundingClientRect().width-t,c=this.calculateDropdownHeight(i);this.maxWidthDropdown=r(o),this.maxHeightDropdown=r(c),e!==this.offsetDropdownX&&(this.offsetDropdownX=e),s!==this.offsetDropdownY&&(this.offsetDropdownY=s),this.isScrollStateDirty&&(this.tmpDisableScrollIntoView||this.textInput.scrollIntoView(),this.isScrollStateDirty=!1)}render(){var t,i,o,r,a,h;return e(s,null,e("form",{ref:t=>this.formElement=t},e("div",{class:{"form-control":!0,"input-container":!0,focus:this.hasFocus,"no-icon":this.hideIcon}},e("ix-icon",{class:{"d-none":this.hideIcon},name:this.icon,size:"16"}),e("div",{class:"token-container"},e("ul",{class:"list-unstyled"},this.filterTokens.map(((t,i)=>e("li",{class:{animate__animated:!0,animate__fadein:!0}},e("ix-filter-chip",{onCloseClick:()=>this.removeToken(i)},this.getFilterChipLabel(t))))),void 0===this.categories?"":e("li",{class:{"category-preview":!0,"d-none":!this.category}},null===(t=this.categories[this.category])||void 0===t?void 0:t.label),e("input",{class:{"text-input":!0,"hide-placeholder":void 0!==this.category},ref:t=>this.textInput=t,type:"text",placeholder:this.placeholder,onFocus:()=>this.openCategorySelection()}))),e("button",{class:{btn:!0,"btn-invisible-secondary":!0,"btn-oval":!0,"btn-close":!0,"d-none":!this.filterTokens.length&&!this.category},onClick:()=>this.resetFilter(),tabindex:"1"},e("span",{class:"glyph glyph-error glyph-16"})))),e("div",{class:{"category-selection-container":!0,"d-none":!this.showCategorySelection&&void 0===this.category},style:{left:this.offsetDropdownX,top:this.offsetDropdownY,"max-width":this.maxWidthDropdown,"max-height":this.maxHeightDropdown}},e("div",{class:{"d-none":!this.showCategorySelection||void 0!==this.category}},e("div",{class:{"category-item-header":!0,"d-none":0===this.getCategoryLables().filter((t=>this.filterByInput(t))).length}},this.labelCategories),null===(i=this.getCategoryIds())||void 0===i?void 0:i.filter((t=>this.filterByInput(this.categories[t].label))).filter((t=>this.filterMultiples(t))).map((t=>{var i;return e("div",{"data-id":t,title:t,class:"category-item category-item-id",onClick:()=>this.selectCategory(t),tabindex:"0"},null===(i=this.categories[t])||void 0===i?void 0:i.label)}))),e("div",{class:{"d-none":void 0===this.category}},e("button",{class:"btn btn-invisible-secondary btn-icon",onClick:()=>this.toggleCategoryOperator(),tabindex:"-1"},this.categoryLogicalOperator===c.NOT_EQUAL?"=":"!="),void 0===this.categories?"":e("div",{class:"category-item-header"},null===(o=this.categories[this.category])||void 0===o?void 0:o.label),void 0===this.categories?"":null===(r=this.categories[this.category])||void 0===r?void 0:r.options.filter((t=>this.filterByInput(t))).filter((t=>this.filterDuplicateTokens(t))).map((t=>e("div",{"data-id":t,title:t,class:"category-item category-item-value",onClick:()=>this.addToken(t,this.category),tabindex:"0"},`${this.categoryLogicalOperator===c.EQUAL?"=":"!="} ${t}`)))),e("div",{class:{"category-item-header":!0,"d-none":void 0!==this.category||this.getCategoryIds().filter((t=>this.filterByInput(t))).length>0}},this.i18nPlainText),e("div",{class:{"d-none":!(null===(a=this.suggestions)||void 0===a?void 0:a.length)||void 0!==this.category}},null===(h=this.suggestions)||void 0===h?void 0:h.filter((t=>this.filterByInput(t))).filter((t=>this.filterDuplicateTokens(t))).map((t=>e("div",{"data-id":t,class:"category-item plain-text-suggestion",onClick:()=>this.addToken(t),tabindex:"0"},t))))))}get hostElement(){return o(this)}static get watchers(){return{filterState:["watchFilterState"],showCategorySelection:["watchShowCategorySelection"]}}};h.style=".sc-ix-category-filter-h{display:block;position:relative}.sc-ix-category-filter-h .focus.sc-ix-category-filter{border-color:var(--theme-color-primary);box-shadow:0 0 0.25rem 0 var(--theme-color-primary) !important}.sc-ix-category-filter-h .btn-close.sc-ix-category-filter{position:absolute;top:0.25rem;right:0.25rem;min-width:1.5rem;width:1.5rem;height:1.5rem}.sc-ix-category-filter-h .input-container.sc-ix-category-filter{display:flex;height:100%;max-height:3.75rem;padding:1px 1.5rem 1px 2rem}.sc-ix-category-filter-h .input-container.no-icon.sc-ix-category-filter{padding-left:0.25rem}.sc-ix-category-filter-h .token-container.sc-ix-category-filter{flex-grow:1;overflow:hidden}.sc-ix-category-filter-h .text-input.sc-ix-category-filter{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.429em;color:var(--theme-color-std-text);background:transparent;flex-grow:1;height:1.75rem}.sc-ix-category-filter-h .text-input.sc-ix-category-filter,.sc-ix-category-filter-h .text-input.sc-ix-category-filter:hover,.sc-ix-category-filter-h .text-input.sc-ix-category-filter:focus-visible{border:none;outline:none}.sc-ix-category-filter-h .text-input.hide-placeholder.sc-ix-category-filter::-moz-placeholder{opacity:0}.sc-ix-category-filter-h .text-input.hide-placeholder.sc-ix-category-filter::placeholder{opacity:0}.sc-ix-category-filter-h .list-unstyled.sc-ix-category-filter{display:flex;flex-wrap:wrap;list-style:none;padding:0;margin:0;overflow-y:auto}.sc-ix-category-filter-h ix-icon.sc-ix-category-filter{position:absolute;top:0.5rem;left:0.5rem}.sc-ix-category-filter-h ix-filter-chip.sc-ix-category-filter{margin-right:0.5rem}.sc-ix-category-filter-h .category-preview.sc-ix-category-filter{display:flex;align-items:center;height:1.5rem;background-color:var(--theme-bg-3);border-top-left-radius:1rem;border-bottom-left-radius:1rem;padding:0.5rem;margin:2px 0}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter{box-shadow:var(--theme-box-shadow-level-1);background:var(--theme-color-1);position:absolute;top:2rem;overflow-y:auto;min-width:10rem;border:var(--theme-std-bdr-1);border-radius:0.25rem;padding:0.5rem;z-index:1}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item.sc-ix-category-filter,.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item-header.sc-ix-category-filter{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.143em;color:var(--theme-color-std-text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;height:2rem;padding:0.5rem}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item-header.sc-ix-category-filter{color:var(--theme-color-soft-text)}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item-id.sc-ix-category-filter{border-top-left-radius:1rem;border-bottom-left-radius:1rem}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item-value.sc-ix-category-filter{border-top-right-radius:1rem;border-bottom-right-radius:1rem}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item.sc-ix-category-filter{cursor:pointer}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item.sc-ix-category-filter:focus{background-color:var(--theme-generic-bg-active);outline:none}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .plain-text-suggestion.sc-ix-category-filter{border-radius:1rem}.sc-ix-category-filter-h ul.sc-ix-category-filter{height:100%}.sc-ix-category-filter-h ul.sc-ix-category-filter>li.sc-ix-category-filter,.sc-ix-category-filter-h input.sc-ix-category-filter{padding-top:2px;padding-bottom:2px}";export{h as ix_category_filter}
|
|
1
|
+
import{r as t,c as i,h as e,H as s,g as o}from"./p-5c038d1d.js";import{a as r}from"./p-c8cc3bb3.js";import{L as c,I as a}from"./p-0a12b3df.js";const h=class{constructor(e){t(this,e),this.inputChanged=i(this,"inputChanged",7),this.filterChanged=i(this,"filterChanged",7),this.ID_CUSTOM_FILTER_VALUE="CW_CUSTOM_FILTER_VALUE",this.documentClickCallback=this.handleDocumentClick.bind(this),this.hasFocus=void 0,this.showCategorySelection=void 0,this.categoryLogicalOperator=c.EQUAL,this.inputValue=void 0,this.category=void 0,this.filterTokens=[],this.offsetDropdownX=void 0,this.offsetDropdownY=void 0,this.maxHeightDropdown=void 0,this.maxWidthDropdown=void 0,this.initialState=void 0,this.filterState=void 0,this.placeholder=void 0,this.categories=void 0,this.nonSelectableCategories={},this.suggestions=void 0,this.icon="search",this.hideIcon=void 0,this.repeatCategories=!0,this.tmpDisableScrollIntoView=!0,this.labelCategories="Categories",this.i18nPlainText="Filter by text"}watchFilterState(t){this.setFilterState(t)}watchShowCategorySelection(t){t?document.addEventListener("click",this.documentClickCallback):document.removeEventListener("click",this.documentClickCallback)}setDropdownOffset(){const t=this.calculateDropdownHeight();this.maxHeightDropdown=r(t)}componentDidLoad(){var t,i;void 0!==this.initialState?this.setFilterState(this.initialState):void 0!==this.filterState&&this.setFilterState(this.filterState),null===(t=this.hostElement)||void 0===t||t.addEventListener("keydown",this.handleFormElementKeyDown.bind(this)),null===(i=this.formElement)||void 0===i||i.addEventListener("submit",(t=>t.preventDefault())),null!=this.textInput?(this.textInput.addEventListener("click",(()=>this.showCategorySelection=!0)),this.textInput.addEventListener("focusin",(()=>{this.hasFocus=!0})),this.textInput.addEventListener("focusout",(()=>this.hasFocus=!1)),this.textInput.addEventListener("input",(()=>{this.inputValue=this.textInput.value;const t=new a(this.inputValue,this.category);this.inputChanged.emit(t),this.showCategorySelection=!0})),this.textInput.addEventListener("keydown",this.handleInputElementKeyDown.bind(this))):console.warn("Core UI category filter - unable to add event listeners to native input element")}setFilterState(t){this.filterTokens=[];for(const i of t.tokens)this.addToken(i,this.ID_CUSTOM_FILTER_VALUE,this.categoryLogicalOperator,!1);for(const i of t.categories)this.addToken(i.value,i.id,i.operator,!1);this.emitFilterEvent()}handleDocumentClick(t){this.hostElement.contains(t.target)||this.closeDropdown()}closeDropdown(){this.showCategorySelection=!1,this.category=void 0}handleFormElementKeyDown(t){switch(t.code){case"Enter":case"NumpadEnter":if(this.category||document.activeElement.classList.contains("plain-text-suggestion")){const t=document.activeElement.getAttribute("data-id");this.addToken(t,this.category)}else document.activeElement.classList.contains("category-item-id")&&this.selectCategory(document.activeElement.getAttribute("data-id"));t.preventDefault();break;case"ArrowUp":this.focusPreviousItem(),t.preventDefault();break;case"ArrowDown":this.focusNextItem(),t.preventDefault();break;case"Escape":this.closeDropdown()}}focusPreviousItem(){const t=document.activeElement.previousSibling;t instanceof HTMLElement&&t.focus()}focusNextItem(){const t=document.activeElement.nextSibling;t instanceof HTMLElement&&t.focus()}handleInputElementKeyDown(t){var i;switch(t.code){case"ArrowDown":let e=this.hostElement.querySelector(".category-item-"+(this.category?"value":"id"));e instanceof HTMLElement?(e.focus(),t.stopPropagation()):(null===(i=this.suggestions)||void 0===i?void 0:i.length)&&(e=this.hostElement.querySelector(".category-item"),e instanceof HTMLElement&&(e.focus(),t.stopPropagation()));break;case"Backspace":if(""!==this.textInput.value)return;if(this.category)return void(this.category=void 0);const s=this.filterTokens.length;s>0&&this.removeToken(s-1);break;case"Enter":case"NumpadEnter":this.addToken(this.inputValue,this.category),t.preventDefault()}}emitFilterEvent(){const t=this.filterTokens.filter((t=>t.id===this.ID_CUSTOM_FILTER_VALUE)).map((t=>t.value)),i=this.filterTokens.filter((t=>t.id!==this.ID_CUSTOM_FILTER_VALUE));this.filterChanged.emit({tokens:t,categories:i})}addToken(t,i=this.ID_CUSTOM_FILTER_VALUE,e=this.categoryLogicalOperator,s=!0){if(null==t)return;const o=t.trim();""!==o&&(this.filterTokens.find((t=>(null==t?void 0:t.value)===o))||(this.filterTokens=[...this.filterTokens,{id:i,value:o,operator:e}],this.textInput.value="",this.inputValue="",this.categoryLogicalOperator=c.EQUAL,this.isScrollStateDirty=!0,this.textInput.focus(),s&&this.emitFilterEvent(),this.closeDropdown()))}removeToken(t){this.filterTokens=this.filterTokens.filter(((i,e)=>e!==t)),this.emitFilterEvent()}getCategoryIds(){const t=[];for(const i in this.categories)Object.prototype.hasOwnProperty.call(this.categories,i)&&t.push(i);return t}getCategoryLables(){return this.getCategoryIds().map((t=>this.categories[t].label))}selectCategory(t){this.category=t,this.textInput.value="",this.inputValue="",this.textInput.focus()}openCategorySelection(){this.showCategorySelection=!0}resetFilter(){this.closeDropdown(),this.filterTokens=[],this.emitFilterEvent()}calculateDropdownX(){var t;return this.textInput?this.textInput.getBoundingClientRect().x-(null===(t=this.formElement)||void 0===t?void 0:t.getBoundingClientRect().x):0}calculateDropdownY(){return this.textInput?this.hostElement.getBoundingClientRect().height:32}calculateDropdownHeight(t=32){const i=this.hostElement.getBoundingClientRect().top;return window.innerHeight-(i+t)}filterMultiples(t){return!!this.repeatCategories||!this.filterTokens.find((i=>i.id===t))}filterDuplicateTokens(t){return!this.filterTokens.some((i=>i.value===t))}filterByInput(t){return void 0===this.inputValue||""===this.inputValue||-1!==t.toLowerCase().indexOf(this.inputValue.toLowerCase())}toggleCategoryOperator(){switch(this.categoryLogicalOperator){case c.EQUAL:this.categoryLogicalOperator=c.NOT_EQUAL;break;case c.NOT_EQUAL:this.categoryLogicalOperator=c.EQUAL}}getFilterChipLabel(t){var i,e,s;return t.id===this.ID_CUSTOM_FILTER_VALUE?t.value:`${null!==(s=null!==(e=null===(i=this.categories[t.id])||void 0===i?void 0:i.label)&&void 0!==e?e:this.nonSelectableCategories[t.id])&&void 0!==s?s:t.id} ${t.operator===c.EQUAL?"=":"!="} ${t.value}`}componentDidRender(){const t=this.calculateDropdownX(),i=this.calculateDropdownY(),e=r(t),s=r(i),o=this.hostElement.getBoundingClientRect().width-t,c=this.calculateDropdownHeight(i);this.maxWidthDropdown=r(o),this.maxHeightDropdown=r(c),e!==this.offsetDropdownX&&(this.offsetDropdownX=e),s!==this.offsetDropdownY&&(this.offsetDropdownY=s),this.isScrollStateDirty&&(this.tmpDisableScrollIntoView||this.textInput.scrollIntoView(),this.isScrollStateDirty=!1)}render(){var t,i,o,r,a,h;return e(s,null,e("form",{ref:t=>this.formElement=t},e("div",{class:{"form-control":!0,"input-container":!0,focus:this.hasFocus,"no-icon":this.hideIcon}},e("ix-icon",{class:{"d-none":this.hideIcon},name:this.icon,size:"16"}),e("div",{class:"token-container"},e("ul",{class:"list-unstyled"},this.filterTokens.map(((t,i)=>e("li",{class:{animate__animated:!0,animate__fadein:!0}},e("ix-filter-chip",{onCloseClick:()=>this.removeToken(i)},this.getFilterChipLabel(t))))),void 0===this.categories?"":e("li",{class:{"category-preview":!0,"d-none":!this.category}},null===(t=this.categories[this.category])||void 0===t?void 0:t.label),e("input",{class:{"text-input":!0,"hide-placeholder":void 0!==this.category},ref:t=>this.textInput=t,type:"text",placeholder:this.placeholder,onFocus:()=>this.openCategorySelection()}))),e("button",{class:{btn:!0,"btn-invisible-secondary":!0,"btn-oval":!0,"btn-close":!0,"d-none":!this.filterTokens.length&&!this.category},onClick:()=>this.resetFilter(),tabindex:"1"},e("span",{class:"glyph glyph-error glyph-16"})))),e("div",{class:{"category-selection-container":!0,"d-none":!this.showCategorySelection&&void 0===this.category},style:{left:this.offsetDropdownX,top:this.offsetDropdownY,"max-width":this.maxWidthDropdown,"max-height":this.maxHeightDropdown}},e("div",{class:{"d-none":!this.showCategorySelection||void 0!==this.category}},e("div",{class:{"category-item-header":!0,"d-none":0===this.getCategoryLables().filter((t=>this.filterByInput(t))).length}},this.labelCategories),null===(i=this.getCategoryIds())||void 0===i?void 0:i.filter((t=>this.filterByInput(this.categories[t].label))).filter((t=>this.filterMultiples(t))).map((t=>{var i;return e("div",{"data-id":t,title:t,class:"category-item category-item-id",onClick:()=>this.selectCategory(t),tabindex:"0"},null===(i=this.categories[t])||void 0===i?void 0:i.label)}))),e("div",{class:{"d-none":void 0===this.category}},e("button",{class:"btn btn-invisible-secondary btn-icon",onClick:()=>this.toggleCategoryOperator(),tabindex:"-1"},this.categoryLogicalOperator===c.NOT_EQUAL?"=":"!="),void 0===this.categories?"":e("div",{class:"category-item-header"},null===(o=this.categories[this.category])||void 0===o?void 0:o.label),void 0===this.categories?"":null===(r=this.categories[this.category])||void 0===r?void 0:r.options.filter((t=>this.filterByInput(t))).filter((t=>this.filterDuplicateTokens(t))).map((t=>e("div",{"data-id":t,title:t,class:"category-item category-item-value",onClick:()=>this.addToken(t,this.category),tabindex:"0"},`${this.categoryLogicalOperator===c.EQUAL?"=":"!="} ${t}`)))),e("div",{class:{"category-item-header":!0,"d-none":void 0!==this.category||this.getCategoryIds().filter((t=>this.filterByInput(t))).length>0}},this.i18nPlainText),e("div",{class:{"d-none":!(null===(a=this.suggestions)||void 0===a?void 0:a.length)||void 0!==this.category}},null===(h=this.suggestions)||void 0===h?void 0:h.filter((t=>this.filterByInput(t))).filter((t=>this.filterDuplicateTokens(t))).map((t=>e("div",{"data-id":t,class:"category-item plain-text-suggestion",onClick:()=>this.addToken(t),tabindex:"0"},t))))))}get hostElement(){return o(this)}static get watchers(){return{filterState:["watchFilterState"],showCategorySelection:["watchShowCategorySelection"]}}};h.style=".sc-ix-category-filter-h{display:block;position:relative}.sc-ix-category-filter-h .focus.sc-ix-category-filter{border-color:var(--theme-color-primary);box-shadow:0 0 0.25rem 0 var(--theme-color-primary) !important}.sc-ix-category-filter-h .btn-close.sc-ix-category-filter{position:absolute;top:0.25rem;right:0.25rem;min-width:1.5rem;width:1.5rem;height:1.5rem}.sc-ix-category-filter-h .input-container.sc-ix-category-filter{display:flex;height:100%;max-height:3.75rem;padding:1px 1.5rem 1px 2rem}.sc-ix-category-filter-h .input-container.no-icon.sc-ix-category-filter{padding-left:0.25rem}.sc-ix-category-filter-h .token-container.sc-ix-category-filter{flex-grow:1;overflow:hidden}.sc-ix-category-filter-h .text-input.sc-ix-category-filter{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.429em;color:var(--theme-color-std-text);background:transparent;flex-grow:1;height:1.75rem}.sc-ix-category-filter-h .text-input.sc-ix-category-filter,.sc-ix-category-filter-h .text-input.sc-ix-category-filter:hover,.sc-ix-category-filter-h .text-input.sc-ix-category-filter:focus-visible{border:none;outline:none}.sc-ix-category-filter-h .text-input.hide-placeholder.sc-ix-category-filter::-moz-placeholder{opacity:0}.sc-ix-category-filter-h .text-input.hide-placeholder.sc-ix-category-filter::placeholder{opacity:0}.sc-ix-category-filter-h .list-unstyled.sc-ix-category-filter{display:flex;flex-wrap:wrap;list-style:none;padding:0;margin:0;overflow-y:auto}.sc-ix-category-filter-h ix-icon.sc-ix-category-filter{position:absolute;top:0.5rem;left:0.5rem}.sc-ix-category-filter-h ix-filter-chip.sc-ix-category-filter{margin-right:0.5rem}.sc-ix-category-filter-h .category-preview.sc-ix-category-filter{display:flex;align-items:center;height:1.5rem;background-color:var(--theme-bg-3);border-top-left-radius:1rem;border-bottom-left-radius:1rem;padding:0.5rem;margin:2px 0}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter{box-shadow:var(--theme-box-shadow-level-1);background:var(--theme-color-1);position:absolute;top:2rem;overflow-y:auto;min-width:10rem;border:var(--theme-std-bdr-1);border-radius:0.25rem;padding:0.5rem;z-index:1}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item.sc-ix-category-filter,.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item-header.sc-ix-category-filter{-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.143em;color:var(--theme-color-std-text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;height:2rem;padding:0.5rem}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item-header.sc-ix-category-filter{color:var(--theme-color-soft-text)}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item-id.sc-ix-category-filter{border-top-left-radius:1rem;border-bottom-left-radius:1rem}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item-value.sc-ix-category-filter{border-top-right-radius:1rem;border-bottom-right-radius:1rem}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item.sc-ix-category-filter{cursor:pointer}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .category-item.sc-ix-category-filter:focus{background-color:var(--theme-generic-bg-active);outline:none}.sc-ix-category-filter-h .category-selection-container.sc-ix-category-filter .plain-text-suggestion.sc-ix-category-filter{border-radius:1rem}.sc-ix-category-filter-h ul.sc-ix-category-filter{height:100%}.sc-ix-category-filter-h ul.sc-ix-category-filter>li.sc-ix-category-filter,.sc-ix-category-filter-h input.sc-ix-category-filter{padding-top:2px;padding-bottom:2px}";export{h as ix_category_filter}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as e,h as i,H as s,g as c}from"./p-5c038d1d.js";const n=class{constructor(i){t(this,i),this.itemSelectionChange=e(this,"itemSelectionChange",7),this.addItem=e(this,"addItem",7),this.selectedIndices=[],this.allowClear=!1,this.mode="single",this.editable=!1,this.disabled=!1,this.readonly=!1,this.i18nPlaceholder="Select an option",this.i18nPlaceholderEditable="Type of select option",this.i18nSelectListHeader="Please select an option",this.dropdownShow=!1,this.value=void 0,this.dropdownWrapperRef=void 0,this.dropdownAnchor=void 0,this.isDropdownEmpty=!1,this.hasFocus=!1,this.navigationItem=void 0,this.inputFilterText=void 0,this.inputValue=void 0}get items(){return Array.from(this.hostElement.querySelectorAll("ix-select-item"))}get selectedItems(){return this.items.filter((t=>t.selected))}get addItemButton(){return this.hostElement.querySelector(".add-item")}get isSingleMode(){return"single"===this.mode}get isMultipleMode(){return"multiple"===this.mode}watchSelectedIndices(t){t?Array.isArray(t)?this.selectValue([...t]):this.selectValue([t]):this.selectValue([])}onItemClicked(t){this.emitItemClick(t.detail)}watchInputText(t){this.editable&&this.itemExists(t)}emitItemClick(t){this.selectedIndices=this.isMultipleMode&&Array.isArray(this.selectedIndices)?this.selectedIndices.includes(t)?this.selectedIndices.filter((e=>e!==t)):[...this.selectedIndices,t]:[t],this.selectValue(this.selectedIndices),this.itemSelectionChange.emit(this.selectedIndices)}emitAddItem(t){if(""===t.trim())return;const e=document.createElement("ix-select-item");e.value=t,e.label=t,this.addItemRef.appendChild(e),this.clearInput(),this.emitItemClick(t),this.addItem.emit(t)}selectValue(t){var e;this.items.forEach((e=>{e.selected=t.some((t=>t===e.value))})),this.value=this.selectedItems.map((t=>t.label)),this.inputValue=this.isSingleMode&&(null===(e=this.value)||void 0===e?void 0:e.length)?this.value[0]:null}componentWillLoad(){this.selectedIndices&&this.selectValue(Array.isArray(this.selectedIndices)?this.selectedIndices:[this.selectedIndices])}componentDidLoad(){this.labelMutationObserver=new MutationObserver((()=>{this.selectValue(Array.isArray(this.selectedIndices)?this.selectedIndices:[this.selectedIndices])})),this.labelMutationObserver.observe(this.hostElement,{subtree:!0,attributes:!0,attributeFilter:["label"]})}disconnectedCallback(){this.labelMutationObserver&&this.labelMutationObserver.disconnect()}itemExists(t){return this.items.find((e=>e.label===t))}dropdownVisibilityChanged(t){this.dropdownShow=t.detail,t.detail&&(this.inputRef.focus(),this.inputRef.select(),this.navigationItem=this.items[0],this.setHoverEffectForNavigatedSelectItem(),this.removeHiddenFromItems()),this.hasFocus=t.detail}async onKeyDown(t){this.dropdownShow&&("ArrowDown"!==t.code&&"ArrowUp"!==t.code||this.onArrowNavigation(t),"Enter"!==t.code&&"NumpadEnter"!==t.code||await this.onEnterNavigation(),"Escape"===t.code&&(this.dropdownShow=!1))}async onEnterNavigation(){var t,e;this.editable&&!this.itemExists(this.inputFilterText)&&(this.emitAddItem(this.inputFilterText),this.navigationItem=this.items[this.items.length-1]),null===(t=this.navigationItem)||void 0===t||t.onItemClick(),await(null===(e=this.dropdownRef)||void 0===e?void 0:e.updatePosition()),this.isSingleMode&&!this.editable&&(this.dropdownShow=!1)}onArrowNavigation(t){t.stopPropagation(),t.preventDefault();const e=this.items.filter((t=>!t.classList.contains("d-none"))),i=e.indexOf(this.navigationItem);"ArrowDown"===t.code&&i<e.length-1?this.navigationItem=e[i+1]:"ArrowUp"===t.code&&i>0&&(this.navigationItem=e[i-1]),this.setHoverEffectForNavigatedSelectItem()}setHoverEffectForNavigatedSelectItem(){this.items.forEach((t=>{t.hover=t===this.navigationItem}))}filterItemsWithTypeahead(){this.inputFilterText=this.inputRef.value,this.inputFilterText?this.items.forEach((t=>{t.classList.remove("d-none"),t.label.toLowerCase().includes(this.inputFilterText.toLowerCase())||t.classList.add("d-none")})):this.removeHiddenFromItems(),this.isDropdownEmpty=this.items.every((t=>t.classList.contains("d-none")))}removeHiddenFromItems(){this.items.forEach((t=>{t.classList.remove("d-none")}))}clearInput(){this.inputRef.value="",this.inputFilterText=""}clear(){this.clearInput(),this.value=[],this.selectedIndices=[],this.itemSelectionChange.emit(null)}render(){var t,e,c;return i(s,null,i("div",{class:{"form-control":!0,select:!0,focus:this.hasFocus,editable:this.editable,disabled:this.disabled,readonly:this.readonly},ref:t=>{this.dropdownAnchor=t,this.editable||(this.dropdownWrapperRef=t)}},i("div",{class:"input-container"},this.isMultipleMode?i("div",{class:"chips"},null===(t=this.selectedItems)||void 0===t?void 0:t.map((t=>i("ix-filter-chip",{disabled:this.disabled||this.readonly,onCloseClick:e=>{e.preventDefault(),e.stopPropagation(),this.emitItemClick(t.value)}},t.label)))):null,i("div",{class:"trigger"},i("input",{"data-testid":"input",disabled:this.disabled,readOnly:this.readonly,type:"text",class:{"allow-clear":this.allowClear&&!!(null===(e=this.value)||void 0===e?void 0:e.length)},placeholder:this.editable?this.i18nPlaceholderEditable:this.i18nPlaceholder,value:this.inputValue,ref:t=>this.inputRef=t,onInput:()=>this.filterItemsWithTypeahead()}),this.disabled||this.readonly?null:i("div",{class:"chevron-down-container",ref:t=>{this.editable&&(this.dropdownWrapperRef=t)}},i("ix-icon",{class:"chevron",name:"chevron-down-small"})))),this.allowClear&&((null===(c=this.value)||void 0===c?void 0:c.length)||this.inputFilterText)?i("ix-icon-button",{class:"clear",icon:"clear",ghost:!0,oval:!0,size:"24",onClick:t=>{t.preventDefault(),t.stopPropagation(),this.clear()}}):null),i("ix-dropdown",{ref:t=>this.dropdownRef=t,show:this.dropdownShow,style:{width:"100%"},class:{"d-none":this.disabled||this.readonly||this.isDropdownEmpty&&!this.editable},anchor:this.dropdownAnchor,trigger:this.dropdownWrapperRef,onShowChanged:t=>this.dropdownVisibilityChanged(t),placement:"bottom",positioningStrategy:"fixed",adjustDropdownWidthToReferenceWidth:!0},i("div",{class:"select-list-header"},this.i18nSelectListHeader),i("slot",null),i("div",{ref:t=>this.addItemRef=t,class:"d-contents"}),this.itemExists(this.inputFilterText)?"":i("ix-dropdown-item",{"data-testid":"add-item",icon:"plus",class:{"add-item":!0,"d-none":!(this.editable&&this.inputFilterText)},label:this.inputFilterText,onItemClick:t=>{t.preventDefault(),t.stopPropagation(),this.emitAddItem(this.inputFilterText)}})))}get hostElement(){return c(this)}static get watchers(){return{selectedIndices:["watchSelectedIndices"],inputFilterText:["watchInputText"]}}};n.style=".sc-ix-select-h{display:inline-block;position:relative;height:auto;width:100%}.sc-ix-select-h .select.sc-ix-select{position:relative;display:flex;align-items:center;height:auto;background-color:var(--theme-input--background);border:var(--theme-input--border-thickness) solid var(--theme-input--border-color);border-radius:var(--theme-input--border-radius);padding:0 0 0 0.5rem}.sc-ix-select-h .select.sc-ix-select:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-select-h .select.sc-ix-select:not(.disabled):not(:disabled):hover{background-color:var(--theme-input--background--hover);border-color:var(--theme-input--border-color--hover)}.sc-ix-select-h .select.sc-ix-select:focus-within{background-color:var(--theme-input--background--focus);border-color:var(--theme-input--border-color--focus);outline:1px solid #119fff !important;outline-offset:var(--theme-input--focus--outline-offset)}.sc-ix-select-h .trigger.sc-ix-select{display:flex;align-items:center;flex-grow:1;height:100%}.sc-ix-select-h .input-container.sc-ix-select{display:flex;position:relative;align-items:flex-start;height:calc(2rem - 2 * var(--theme-input--border-thickness));width:100%}.sc-ix-select-h .input-container.allow-clear.sc-ix-select{padding-right:3.5rem}.sc-ix-select-h .input-container.sc-ix-select .chips.sc-ix-select{position:relative;display:flex;align-items:center;flex-wrap:wrap;height:100%;max-width:70%;flex-shrink:0;margin:auto}.sc-ix-select-h .input-container.sc-ix-select .chips.sc-ix-select>ix-filter-chip.sc-ix-select{margin:0.1rem}.sc-ix-select-h .input-container.sc-ix-select input.sc-ix-select{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;-webkit-font-smoothing:antialiased;-moz-osx-font-smooting:grayscale;font-family:Siemens Sans, sans-serif;font-size:0.875rem;font-weight:400;line-height:1.429em;color:var(--theme-color-std-text);background:transparent;height:1.75rem;width:100%;-webkit-margin-end:2rem;margin-inline-end:2rem}.sc-ix-select-h .input-container.sc-ix-select input.sc-ix-select,.sc-ix-select-h .input-container.sc-ix-select input.sc-ix-select:hover,.sc-ix-select-h .input-container.sc-ix-select input.sc-ix-select:focus-visible{border:none;outline:none}.sc-ix-select-h .input-container.sc-ix-select input.sc-ix-select::-moz-placeholder{color:var(--theme-input-select-icon--color)}.sc-ix-select-h .input-container.sc-ix-select input.sc-ix-select::placeholder{color:var(--theme-input-select-icon--color)}.sc-ix-select-h .input-container.sc-ix-select input.hide-placeholder.sc-ix-select::-moz-placeholder{opacity:0}.sc-ix-select-h .input-container.sc-ix-select input.hide-placeholder.sc-ix-select::placeholder{opacity:0}.sc-ix-select-h .chevron-down-container.sc-ix-select{display:flex;align-items:center;justify-content:center;width:2rem;min-width:2rem;height:100%}.sc-ix-select-h .editable.sc-ix-select .chevron-down-container.sc-ix-select:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-select-h .editable.sc-ix-select .chevron-down-container.sc-ix-select:not(.disabled):not(:disabled):hover{background-color:var(--theme-btn-invisible-secondary--background--hover)}.sc-ix-select-h .editable.sc-ix-select .chevron-down-container.sc-ix-select:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-select-h .editable.sc-ix-select .chevron-down-container.sc-ix-select:not(.disabled):not(:disabled):active{background-color:var(--theme-btn-invisible-secondary--background--active)}.sc-ix-select-h .clear.sc-ix-select{position:absolute;right:2rem}.sc-ix-select-h .add-item.sc-ix-select{display:flex;justify-content:flex-start;align-items:center;position:relative;width:100%}.sc-ix-select-h .select-list-header.sc-ix-select{display:flex;align-items:center;height:2rem;color:var(--theme-select-list-item-hint--color);margin:0 0.5rem 0 2rem}.sc-ix-select-h ix-dropdown.sc-ix-select{background-color:var(--theme-select-list--background)}";const h=class{constructor(i){t(this,i),this.itemClick=e(this,"itemClick",7),this.label=void 0,this.value=void 0,this.selected=!1,this.hover=!1}async onItemClick(t){null==t||t.preventDefault(),null==t||t.stopPropagation(),this.itemClick.emit(this.value)}componentDidRender(){if(!this.value)throw Error("ix-select-item must have a `value` property")}render(){return i(s,null,i("ix-dropdown-item",{checked:this.selected,hover:this.hover,label:this.label?this.label:this.value,onItemClick:t=>this.onItemClick(t)}))}get hostElement(){return c(this)}};h.style=".sc-ix-select-item-h{display:block}.sc-ix-select-item-h ix-dropdown-item.sc-ix-select-item button.sc-ix-select-item{margin-left:1rem}";export{n as ix_select,h as ix_select_item}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as s,h as o,H as i,g as a}from"./p-5c038d1d.js";import{T as e}from"./p-
|
|
1
|
+
import{r as t,c as s,h as o,H as i,g as a}from"./p-5c038d1d.js";import{T as e}from"./p-4944ad0b.js";const r=class{constructor(o){t(this,o),this.closeToast=s(this,"closeToast",7),this.type="info",this.toastTitle=void 0,this.autoCloseDelay=5e3,this.autoClose=!0,this.icon=void 0,this.iconColor=void 0,this.progress=0,this.isRunning=!0,this.touched=!1}getIcon(){if(this.icon)return o("ix-icon",{name:this.icon,color:this.iconColor,size:"24"});switch(this.type){case"info":return o("ix-icon",{name:"info",size:"24",color:"color-std-text"});case"error":return o("ix-icon",{name:"error",size:"24",color:"color-alarm"});case"success":return o("ix-icon",{name:"success",size:"24",color:"color-success"});case"warning":return o("ix-icon",{name:"warning",size:"24",color:"color-warning"});default:return""}}close(){this.host&&this.host.classList.add("animate__fadeOut"),setTimeout((()=>{this.closeToast.emit()}),250)}render(){let t,s={};const a=["toast-progress-bar"];this.touched?a.push("toast-progress-bar--touched"):(s={animationDuration:`${this.autoCloseDelay}ms`,animationPlayState:this.isRunning?"running":"paused"},a.push("toast-progress-bar--animated"));const e=()=>{t&&(t.style.transform=`scaleX(${this.progress})`)};return o(i,{class:"animate__animated animate__fadeIn"},o("div",{class:"toast-body",onPointerLeave:()=>{this.progress=0,e()},onPointerEnter:()=>{this.isRunning=!1,this.touched=!0,this.progress=1,e()}},this.type||this.icon?o("div",{class:"toast-icon"},this.getIcon()):null,o("div",{class:"toast-content"},this.toastTitle?o("div",{class:"toast-title text-default-title-single"},this.toastTitle):null,o("div",{class:"toast-message text-default"},o("slot",null))),o("div",{class:"toast-close"},o("ix-icon-button",{icon:"close",size:"24",ghost:!0,onClick:()=>this.closeToast.emit()}))),this.autoClose?o("div",{class:a.join(" "),style:s,ref:s=>t=s,onAnimationEnd:()=>this.close(),onTransitionEnd:()=>{0===this.progress&&this.close()}}):null)}get host(){return a(this)}};r.style=".sc-ix-toast-h{display:flex;flex-direction:column;position:relative;min-width:17.5rem;max-width:17.5rem;min-height:3.5rem;pointer-events:all;background-color:var(--theme-toast--background);border:var(--theme-toast--border-thickness) solid var(--theme-toast--border-color);border-radius:var(--theme-toast--border-radius);box-shadow:var(--theme-toast--box-shadow);--animate-duration:300ms}.sc-ix-toast-h .toast-body.sc-ix-toast{display:flex;position:relative;width:100%;flex-grow:1}.sc-ix-toast-h .toast-body.sc-ix-toast .toast-icon.sc-ix-toast{display:flex;align-items:flex-start;margin:1rem}.sc-ix-toast-h .toast-body.sc-ix-toast .toast-content.sc-ix-toast{overflow:hidden;text-overflow:ellipsis;min-width:0;width:100%;max-width:10.25rem;margin-top:calc(\n 1rem + var(--theme-toast--border-thickness)\n );margin-bottom:0.75rem}.sc-ix-toast-h .toast-body.sc-ix-toast .toast-content.sc-ix-toast .toast-message.sc-ix-toast{min-width:0}.sc-ix-toast-h .toast-close.sc-ix-toast{display:flex;position:relative;margin:0.75rem;pointer-events:all}.sc-ix-toast-h .toast-progress-bar.sc-ix-toast{position:absolute;bottom:0;height:0.25rem;width:100%;background-color:var(--theme-toast-timer-value--background);transform-origin:left}.sc-ix-toast-h .toast-progress-bar--animated.sc-ix-toast{animation:trackProgress linear 1 forwards}.sc-ix-toast-h .toast-progress-bar--touched.sc-ix-toast{transition:transform 1s}.sc-ix-toast-h:not(.disabled):not(:disabled){cursor:pointer}.sc-ix-toast-h:not(.disabled):not(:disabled):hover .toast-progress-bar.sc-ix-toast{visibility:hidden;transition:none}@keyframes trackProgress{0%{transform:scaleX(1)}100%{transform:scaleX(0)}}";const n=class{constructor(s){t(this,s),this.containerId="toast-container",this.containerClass="toast-container",this.position="bottom-right"}get hostContainer(){return document.getElementById(this.containerId)}componentDidLoad(){if(!document.getElementById(this.containerId)){const t=document.createElement("div");t.id=this.containerId,t.classList.add(this.containerClass),t.classList.add(`toast-container--${this.position}`),document.body.appendChild(t)}}async showToast(t){const s=document.createElement("ix-toast"),o=new e;function i(t){s.remove(),o.emit(t)}return s.toastTitle=t.title,s.type=t.type,s.autoClose=t.autoClose,s.autoCloseDelay=t.autoCloseDelay,s.icon=t.icon,s.iconColor=t.iconColor,s.addEventListener("closeToast",(t=>{const{detail:s}=t;i(s)})),"string"==typeof t.message?s.innerText=t.message:s.appendChild(t.message),this.hostContainer.appendChild(s),{onClose:o,close:t=>{i(t)}}}render(){return o(i,null)}get host(){return a(this)}};export{r as ix_toast,n as ix_toast_container}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,h as t,H as i,g as s,c as r}from"./p-5c038d1d.js";import{c as o}from"./p-fbe40498.js";import{a as n}from"./p-c8cc3bb3.js";const l=class{constructor(t){e(this,t),this.mutationObserver=o(this.onMutation.bind(this)),this.itemHeight="S",this.compact=!1,this.animated=!0,this.chevron=void 0}componentDidLoad(){if(this.animated&&this.triggerFadeIn(),"number"==typeof this.itemHeight){const e=n(this.itemHeight);this.el.querySelectorAll(".ix-event-list-item").forEach((t=>{t.classList.add("d-flex"),this.setCustomHeight(t,e)}))}this.mutationObserver.observe(this.el,{childList:!0,subtree:!0})}onMutation(e){this.triggerFadeOut().then((()=>{if("number"==typeof this.itemHeight){const t=n(this.itemHeight);e.filter((e=>"childList"===e.type)).forEach((e=>e.addedNodes.forEach((e=>{var i;const s=e;(null===(i=s.classList)||void 0===i?void 0:i.contains("ix-event-list-item"))&&(s.classList.add("d-flex"),this.setCustomHeight(s,t))}))))}this.triggerFadeIn()}))}setCustomHeight(e,t){e.style.height=t,e.style.maxHeight=t}triggerFadeOut(){return this.animated?this.el.querySelector("ul").animate([{opacity:1,easing:"ease-in"},{opacity:0}],{duration:l.fadeOutDuration}).finished:Promise.resolve()}triggerFadeIn(){this.animated&&this.el.querySelectorAll(".ix-event-list-item").forEach(((e,t)=>{const i=80*t;e.animate([{opacity:0},{opacity:0,easing:"ease-out",offset:i/(i+l.fadeInDuration)},{opacity:1}],{duration:l.fadeInDuration+i,iterations:1})}))}render(){return t(i,{class:{"item-size-s":"S"===this.itemHeight,"item-size-l":"L"===this.itemHeight,compact:this.compact,chevron:this.chevron}},t("ul",null,t("slot",null)))}get el(){return s(this)}};l.fadeOutDuration=50,l.fadeInDuration=150,l.style=".sc-ix-event-list-h{display:block;position:relative}ul.sc-ix-event-list{list-style:none;padding:0;margin-bottom:0}.sc-ix-event-list-s>.sc-ix-event-list-h:not(.item-size-s) .ix-event-list-item,.sc-ix-event-list-h:not(.item-size-l) .ix-event-list-item.sc-ix-event-list{display:none}.sc-ix-event-list-h.chevron .sc-ix-event-list-s .ix-event-list-item .chevron-icon{display:initial}.item-size-l .sc-ix-event-list-s .ix-event-list-item{height:6.5rem;max-height:6.5rem}.item-size-l .sc-ix-event-list-s .ix-event-list-item .event-content{height:6.5rem;max-height:6.5rem;white-space:normal}.compact .sc-ix-event-list-s .ix-event-list-item{margin-bottom:0px;border-radius:0px}.compact .sc-ix-event-list-s .ix-event-list-item .indicator{border-top-left-radius:0px;border-bottom-left-radius:0px}.compact .sc-ix-event-list-s .ix-event-list-item .event-list-item-container{border-top-left-radius:0;border-top-right-radius:0;border-bottom-left-radius:0;border-bottom-right-radius:0}.compact.sc-ix-event-list .compact.sc-ix-event-list:not(:last-child) .event-list-item-container.sc-ix-event-list{border-bottom:none}";const d=class{constructor(t){e(this,t),this.itemClick=r(this,"itemClick",7),this.color=void 0,this.selected=void 0,this.disabled=void 0,this.chevron=void 0,this.opacity=1}handleItemClick(){this.itemClick.emit()}render(){return t("div",{class:{"ix-event-list-item":!0,selected:this.selected,disabled:this.disabled}},t("div",{class:"indicator "+(this.color?"":"indicator-empty"),style:{"background-color":this.color?`var(--theme-${this.color})`:"inherit",opacity:`${this.disabled?.4:this.opacity}`}}),t("div",{class:"event-list-item-container"},t("div",{class:"event-content"},t("slot",null)),this.chevron?t("i",{class:"glyph glyph-16 glyph-chevron-right chevron-icon"}):""))}get el(){return s(this)}};d.style=".ix-event-list-item{display:flex;align-items:center;position:relative;height:2.5rem;max-height:2.5rem;border-radius:0.25rem;background-color:var(--theme-event-item--background);overflow:hidden;cursor:pointer;margin-bottom:0.5rem}.ix-event-list-item:not(.disabled):not(:disabled){cursor:pointer}.ix-event-list-item:not(.disabled):not(:disabled):hover{background-color:var(--theme-event-item--background--hover)}.ix-event-list-item:not(.disabled):not(:disabled){cursor:pointer}.ix-event-list-item:not(.disabled):not(:disabled):active{background-color:var(--theme-event-item--background--active)}.ix-event-list-item .indicator{height:100%;width:0.5rem;max-width:0.5rem;min-width:0.5rem;border-top-left-radius:0.25rem;border-bottom-left-radius:0.25rem}.ix-event-list-item .indicator-empty{border:var(--theme-weak-bdr-1);border-right:none}.ix-event-list-item .event-list-item-container{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:flex;flex-grow:1;width:calc(100% - (1rem + 0.5rem));height:100%;border:0.062rem solid;border-color:var(--theme-event-item--border);border-top-left-radius:0;border-top-right-radius:0.25rem;border-bottom-left-radius:0;border-bottom-right-radius:0.25rem;border-left:none;padding-left:1rem}.ix-event-list-item .event-list-item-container:not(.disabled):not(:disabled){cursor:pointer}.ix-event-list-item .event-list-item-container:not(.disabled):not(:disabled):hover{border-color:var(--theme-event-item--border--hover)}.ix-event-list-item .event-list-item-container:not(.disabled):not(:disabled){cursor:pointer}.ix-event-list-item .event-list-item-container:not(.disabled):not(:disabled):active{border-color:var(--theme-event-item--border--active)}.ix-event-list-item.selected:not(:active,.active) .event-list-item-container{background-color:var(--theme-event-item--background--selected);border-color:var(--theme-event-item--border--selected)}.ix-event-list-item[disabled],.ix-event-list-item.disabled{pointer-events:none}.ix-event-list-item[disabled] .event-list-item-container,.ix-event-list-item.disabled .event-list-item-container{background-color:var(--theme-event-item--background--disabled);border-color:var(--theme-event-item--border--disabled)}.ix-event-list-item .chevron-icon{margin-left:auto;margin-right:0.5rem;opacity:0.6;align-self:center}.ix-event-list-item .event-content{display:flex;align-items:center;width:100%;height:100%;overflow:hidden}";export{l as ix_event_list,d as ix_event_list_item}
|
|
File without changes
|