@oiz/stzh-components 3.3.0-beta1 → 3.3.0-beta4
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/{app-globals-c314a0a4.js → app-globals-add1c2c1.js} +2 -2
- package/dist/cjs/{app-globals-c314a0a4.js.map → app-globals-add1c2c1.js.map} +1 -1
- package/dist/cjs/index-92254d32.js +4 -0
- package/dist/cjs/index.cjs.js.map +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/stzh-app-nav.cjs.entry.js +32 -0
- package/dist/cjs/stzh-app-nav.cjs.entry.js.map +1 -0
- package/dist/cjs/stzh-badge_3.cjs.entry.js +38 -17
- package/dist/cjs/stzh-badge_3.cjs.entry.js.map +1 -1
- package/dist/cjs/stzh-components.cjs.js +2 -2
- package/dist/cjs/stzh-datepicker_3.cjs.entry.js +2 -0
- package/dist/cjs/stzh-datepicker_3.cjs.entry.js.map +1 -1
- package/dist/cjs/stzh-header.cjs.entry.js +57 -17
- package/dist/cjs/stzh-header.cjs.entry.js.map +1 -1
- package/dist/cjs/stzh-olmap.cjs.entry.js.map +1 -1
- package/dist/cjs/stzh-pagetitle.cjs.entry.js +1 -1
- package/dist/cjs/stzh-pagetitle.cjs.entry.js.map +1 -1
- package/dist/cjs/stzh-row.cjs.entry.js +1 -1
- package/dist/cjs/stzh-row.cjs.entry.js.map +1 -1
- package/dist/collection/assets/i18n/de.json +3 -0
- package/dist/collection/assets/i18n/en.json +3 -0
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/stzh-app-nav/stzh-app-nav.css +247 -0
- package/dist/collection/components/stzh-app-nav/stzh-app-nav.e2e.js +16 -0
- package/dist/collection/components/stzh-app-nav/stzh-app-nav.e2e.js.map +1 -0
- package/dist/collection/components/stzh-app-nav/stzh-app-nav.js +79 -0
- package/dist/collection/components/stzh-app-nav/stzh-app-nav.js.map +1 -0
- package/dist/collection/components/stzh-app-nav/stzh-app-nav.localization.js +2 -0
- package/dist/collection/components/stzh-app-nav/stzh-app-nav.localization.js.map +1 -0
- package/dist/collection/components/stzh-app-nav/stzh-app-nav.stories.js +68 -0
- package/dist/collection/components/stzh-datepicker/stzh-datepicker.js +2 -0
- package/dist/collection/components/stzh-datepicker/stzh-datepicker.js.map +1 -1
- package/dist/collection/components/stzh-header/stzh-header.css +31 -2
- package/dist/collection/components/stzh-header/stzh-header.js +144 -21
- package/dist/collection/components/stzh-header/stzh-header.js.map +1 -1
- package/dist/collection/components/stzh-header/stzh-header.stories.js +72 -62
- package/dist/collection/components/stzh-icon/stzh-icon.js +38 -17
- package/dist/collection/components/stzh-icon/stzh-icon.js.map +1 -1
- package/dist/collection/components/stzh-olmap/stzh-olmap.js +1 -1
- package/dist/collection/components/stzh-olmap/stzh-olmap.js.map +1 -1
- package/dist/collection/components/stzh-pagetitle/stzh-pagetitle.css +0 -1
- package/dist/collection/components/stzh-row/stzh-row.css +184 -240
- package/dist/collection/index.js.map +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/index2.js.map +1 -1
- package/dist/components/stzh-app-nav.d.ts +11 -0
- package/dist/components/stzh-app-nav.js +8 -0
- package/dist/components/stzh-app-nav.js.map +1 -0
- package/dist/components/stzh-app-nav2.js +64 -0
- package/dist/components/stzh-app-nav2.js.map +1 -0
- package/dist/components/stzh-datepicker2.js +2 -0
- package/dist/components/stzh-datepicker2.js.map +1 -1
- package/dist/components/stzh-header.js +84 -25
- package/dist/components/stzh-header.js.map +1 -1
- package/dist/components/stzh-icon2.js +38 -17
- package/dist/components/stzh-icon2.js.map +1 -1
- package/dist/components/stzh-olmap.js.map +1 -1
- package/dist/components/stzh-pagetitle.js +1 -1
- package/dist/components/stzh-pagetitle.js.map +1 -1
- package/dist/components/stzh-row.js +1 -1
- package/dist/components/stzh-row.js.map +1 -1
- package/dist/esm/{app-globals-b82e4e9d.js → app-globals-7f5414ca.js} +2 -2
- package/dist/esm/{app-globals-b82e4e9d.js.map → app-globals-7f5414ca.js.map} +1 -1
- package/dist/esm/index-e3050b18.js +4 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/loader.js +2 -2
- package/dist/esm/stzh-app-nav.entry.js +28 -0
- package/dist/esm/stzh-app-nav.entry.js.map +1 -0
- package/dist/esm/stzh-badge_3.entry.js +38 -17
- package/dist/esm/stzh-badge_3.entry.js.map +1 -1
- package/dist/esm/stzh-components.js +2 -2
- package/dist/esm/stzh-datepicker_3.entry.js +2 -0
- package/dist/esm/stzh-datepicker_3.entry.js.map +1 -1
- package/dist/esm/stzh-header.entry.js +57 -17
- package/dist/esm/stzh-header.entry.js.map +1 -1
- package/dist/esm/stzh-olmap.entry.js.map +1 -1
- package/dist/esm/stzh-pagetitle.entry.js +1 -1
- package/dist/esm/stzh-pagetitle.entry.js.map +1 -1
- package/dist/esm/stzh-row.entry.js +1 -1
- package/dist/esm/stzh-row.entry.js.map +1 -1
- package/dist/stzh-components/assets/i18n/de.json +3 -0
- package/dist/stzh-components/assets/i18n/en.json +3 -0
- package/dist/stzh-components/index.esm.js.map +1 -1
- package/dist/stzh-components/p-10dc377b.entry.js +2 -0
- package/dist/stzh-components/p-10dc377b.entry.js.map +1 -0
- package/dist/stzh-components/p-487b6e52.entry.js +2 -0
- package/dist/stzh-components/p-487b6e52.entry.js.map +1 -0
- package/dist/stzh-components/p-4f7f4362.entry.js +2 -0
- package/dist/stzh-components/p-4f7f4362.entry.js.map +1 -0
- package/dist/stzh-components/{p-d869745a.js → p-6009632f.js} +2 -2
- package/dist/stzh-components/p-6a1d65ce.entry.js +2 -0
- package/dist/stzh-components/p-6a1d65ce.entry.js.map +1 -0
- package/dist/stzh-components/p-b4f5d152.entry.js.map +1 -1
- package/dist/stzh-components/{p-c9265a65.entry.js → p-f0887c02.entry.js} +2 -2
- package/dist/stzh-components/p-f0887c02.entry.js.map +1 -0
- package/dist/stzh-components/p-f42f6787.entry.js +2 -0
- package/dist/stzh-components/p-f42f6787.entry.js.map +1 -0
- package/dist/stzh-components/stzh-components.esm.js +1 -1
- package/dist/stzh-components/stzh-components.esm.js.map +1 -1
- package/dist/types/components/stzh-app-nav/stzh-app-nav.d.ts +11 -0
- package/dist/types/components/stzh-app-nav/stzh-app-nav.localization.d.ts +4 -0
- package/dist/types/components/stzh-header/stzh-header.d.ts +18 -5
- package/dist/types/components/stzh-icon/stzh-icon.d.ts +3 -1
- package/dist/types/components/stzh-olmap/stzh-olmap.d.ts +1 -1
- package/dist/types/components.d.ts +75 -12
- package/dist/types/index.d.ts +10 -0
- package/dist/vscode-data.json +22 -6
- package/package.json +1 -1
- package/dist/stzh-components/p-6e29bc61.entry.js +0 -2
- package/dist/stzh-components/p-6e29bc61.entry.js.map +0 -1
- package/dist/stzh-components/p-b047262a.entry.js +0 -2
- package/dist/stzh-components/p-b047262a.entry.js.map +0 -1
- package/dist/stzh-components/p-b608bf1a.entry.js +0 -2
- package/dist/stzh-components/p-b608bf1a.entry.js.map +0 -1
- package/dist/stzh-components/p-b62c870a.entry.js +0 -2
- package/dist/stzh-components/p-b62c870a.entry.js.map +0 -1
- package/dist/stzh-components/p-c9265a65.entry.js.map +0 -1
- /package/dist/stzh-components/{p-d869745a.js.map → p-6009632f.js.map} +0 -0
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as e,c as t,e as s,w as a,h,F as i,a as r,g as n}from"./p-c7bfac7a.js";import{h as d}from"./p-d789f265.js";import{m as o}from"./p-10e2901a.js";import{t as l,c}from"./p-ed63ed76.js";import{c as m}from"./p-3d5f9ac0.js";import"./p-9b063923.js";const z=".sc-stzh-header-h{font-family:var(--stzh-font-family-medium);font-weight:var(--stzh-font-weight-medium);font-style:var(--stzh-font-style-medium);color:var(--stzh-base-color);box-sizing:border-box;display:block}[hidden].sc-stzh-header-h{display:none}.sc-stzh-header-h::-moz-selection{color:var(--stzh-selection-color);background-color:var(--stzh-selection-background-color)}.sc-stzh-header-h::selection{color:var(--stzh-selection-color);background-color:var(--stzh-selection-background-color)}.sc-stzh-header-h *.sc-stzh-header,.sc-stzh-header-h *.sc-stzh-header::before,.sc-stzh-header-h *.sc-stzh-header::after{box-sizing:border-box;text-underline-offset:var(--stzh-link-text-underline-offset);text-decoration-thickness:var(--stzh-link-text-decoration-thickness);-webkit-text-decoration-skip-ink:var(--stzh-link-text-decoration-skip-ink);text-decoration-skip-ink:var(--stzh-link-text-decoration-skip-ink)}.sc-stzh-header-h .has-focus.sc-stzh-header{outline:var(--stzh-flyingfocus-color) solid 0.125rem;outline-offset:0.125rem}.sc-stzh-header-h .stzh-fylingfocus-focused.sc-stzh-header{outline-style:none !important}.sc-stzh-header-h .stzh-fylingfocus-focused.sc-stzh-header::-moz-focus-inner{border:0 !important}.sc-stzh-header-h{--logo-width:auto;--logo-height:100%;--logobar-background-color:var(--stzh-header-logobar-background-color)}@media print{.sc-stzh-header-h{display:none}}[logo-type=aoz].sc-stzh-header-h,[logo-type=pkzh].sc-stzh-header-h,[logo-type=uvz].sc-stzh-header-h{--logo-height:1.9375rem}@media screen and (min-width: 900px){[logo-type=aoz].sc-stzh-header-h,[logo-type=pkzh].sc-stzh-header-h,[logo-type=uvz].sc-stzh-header-h{--logo-height:2.1875rem}}@media screen and (min-width: 1600px){[logo-type=aoz].sc-stzh-header-h,[logo-type=pkzh].sc-stzh-header-h,[logo-type=uvz].sc-stzh-header-h{--logo-height:3.3125rem}}[logo-type=vbz].sc-stzh-header-h{--logo-height:1.8125rem}@media screen and (min-width: 900px){[logo-type=vbz].sc-stzh-header-h{--logo-height:3.3125rem}}@media screen and (min-width: 1600px){[logo-type=vbz].sc-stzh-header-h{--logo-height:3.75rem}}.sc-stzh-header-h[logo-type=vbz] .sc-stzh-header-s>[slot=logo]{align-self:center}.sc-stzh-header-h .sc-stzh-header-s>[slot=logo]{width:var(--logo-width);height:var(--logo-height)}.stzh-header.sc-stzh-header{font-size:var(--stzh-font-milli-font-size);line-height:var(--stzh-font-milli-text-line-height);letter-spacing:var(--stzh-font-curve---text-letter-spacing);color:var(--stzh-color-grey90)}.stzh-header__inner.sc-stzh-header,.stzh-header__main.sc-stzh-header{max-width:calc(100vw - var(--stzh-scrollbar-width))}@media screen and (min-width: 600px){.stzh-header__inner.sc-stzh-header{position:relative;z-index:var(--stzh-z-index-header)}}.stzh-header__vhidden.sc-stzh-header{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}.stzh-header__main.sc-stzh-header{display:flex;flex-direction:column;background-color:var(--stzh-color-white)}@media screen and (max-width: 599px){.stzh-header__main.sc-stzh-header{position:relative;z-index:var(--stzh-z-index-header)}}.stzh-header__metabar.sc-stzh-header{background-color:var(--stzh-color-coolgrey10)}.stzh-header__metabar-inner.sc-stzh-header{margin-left:1.25rem;margin-right:1.25rem;display:flex;align-items:center;height:4rem}@media screen and (min-width: 600px){.stzh-header__metabar-inner.sc-stzh-header{margin-left:2rem;margin-right:2rem}}@media screen and (min-width: 900px){.stzh-header__metabar-inner.sc-stzh-header{margin-left:2.5rem;margin-right:2.5rem}}@media screen and (min-width: 1260px){.stzh-header__metabar-inner.sc-stzh-header{margin-left:4rem;margin-right:4rem}}@media screen and (min-width: 1600px){.stzh-header__metabar-inner.sc-stzh-header{margin-left:auto;margin-right:auto;max-width:84.25rem}}@media screen and (min-width: 900px){.stzh-header__metabar-inner.sc-stzh-header{height:4rem}}.stzh-header__burger.sc-stzh-header,.stzh-header__search.sc-stzh-header,.stzh-header__metanav-item.sc-stzh-header{color:var(--stzh-color-grey90);transition:color var(--stzh-base-transition-animation-speed);cursor:pointer}.stzh-header__burger.sc-stzh-header:hover,.stzh-header__search.sc-stzh-header:hover,.stzh-header__metanav-item.sc-stzh-header:hover{color:var(--stzh-color-black)}.stzh-header__burger.sc-stzh-header{font-family:var(--stzh-font-family-heavy);font-weight:var(--stzh-font-weight-heavy);font-style:var(--stzh-font-style-heavy);font-size:var(--stzh-font-milli-font-size);line-height:var(--stzh-font-milli-text-line-height);letter-spacing:var(--stzh-font-curve---text-letter-spacing);display:flex;align-items:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent;border:none;padding:0;margin-right:var(--stzh-space-medium);gap:var(--stzh-space-medium);color:var(--stzh-color-primary70)}@media screen and (min-width: 600px){.stzh-header__burger.sc-stzh-header{margin-right:var(--stzh-space-xxlarge)}}@media screen and (min-width: 900px){.stzh-header__burger.sc-stzh-header{margin-right:var(--stzh-space-xxxxlarge)}}.stzh-header__burger-icon.is-open.sc-stzh-header{display:none}.stzh-header__burger.is-open.sc-stzh-header .stzh-header__burger-icon.is-open.sc-stzh-header{display:inline-flex}.stzh-header__burger.is-open.sc-stzh-header .stzh-header__burger-icon.is-close.sc-stzh-header{display:none}.stzh-header__metabar-search.sc-stzh-header{overflow:hidden;margin-right:var(--stzh-space-medium);transition-property:width;transition-duration:var(--stzh-base-transition-animation-speed);width:2.5rem;max-width:21.5625rem}.stzh-header__metabar-search.sc-stzh-header:focus-within{width:100%}@media screen and (min-width: 600px){.stzh-header__metabar-search.sc-stzh-header{width:6rem;margin-right:var(--stzh-space-xxlarge)}}@media screen and (min-width: 900px){.stzh-header__metabar-search.sc-stzh-header{width:10rem;margin-left:0;margin-right:var(--stzh-space-xxxxlarge)}}.stzh-header__search.sc-stzh-header{position:relative;display:block;width:100%}.stzh-header__search-input.sc-stzh-header{width:100%;max-width:100%;background-color:transparent;color:transparent;font-family:inherit;font-size:inherit;border:none;padding:var(--stzh-space-xsmall);padding-left:0;padding-right:0;height:var(--stzh-form-input-small-height);transition-property:padding-left, padding-right, background-color, color;transition-duration:var(--stzh-base-transition-animation-speed)}@media screen and (min-width: 600px){.stzh-header__search-input.sc-stzh-header{color:var(--stzh-color-secondary60);padding-left:calc(var(--stzh-icon-size) + var(--stzh-space-medium))}}.stzh-header__search-input.sc-stzh-header:focus{color:var(--stzh-color-secondary60);background-color:var(--stzh-color-white);padding-left:calc(var(--stzh-space-medium) + var(--stzh-icon-size) + var(--stzh-space-medium));padding-right:var(--stzh-space-xlarge)}.stzh-header__search-input.sc-stzh-header:-webkit-autofill{-webkit-background-clip:text;background-clip:text}.stzh-header__search-input[type=search].sc-stzh-header::-webkit-search-decoration,.stzh-header__search-input[type=search].sc-stzh-header::-webkit-search-cancel-button,.stzh-header__search-input[type=search].sc-stzh-header::-webkit-search-results-button,.stzh-header__search-input[type=search].sc-stzh-header::-webkit-search-results-decoration{-webkit-appearance:none}.stzh-header__search-input.sc-stzh-header:focus~.stzh-header__search-icon.sc-stzh-header,.stzh-header__search-input.sc-stzh-header:focus~.stzh-header__search-text.sc-stzh-header{transform:translate(var(--stzh-space-medium), -50%)}.stzh-header__search-input.sc-stzh-header:focus~.stzh-header__search-text.sc-stzh-header{color:var(--stzh-color-grey70)}.stzh-header__search-text.sc-stzh-header,.stzh-header__search-icon.sc-stzh-header{position:absolute;top:50%;transform:translate(0, -50%);transition:transform var(--stzh-base-transition-animation-speed)}.stzh-header__search-icon.sc-stzh-header{left:0px}@media screen and (max-width: 599px){.stzh-header__search-icon.sc-stzh-header{transform:translate(0.5rem, -50%)}}.stzh-header__search-text.sc-stzh-header{pointer-events:none;left:calc(var(--stzh-icon-size) + var(--stzh-space-medium))}@media screen and (max-width: 599px){.stzh-header__search-text.sc-stzh-header{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}}.stzh-header__metabar-nav.sc-stzh-header{display:flex;align-items:center;margin-left:auto;gap:var(--stzh-space-medium)}@media screen and (min-width: 600px){.stzh-header__metabar-nav.sc-stzh-header{gap:var(--stzh-space-xlarge)}}@media screen and (min-width: 900px){.stzh-header__metabar-nav.sc-stzh-header{gap:var(--stzh-space-xxlarge)}}.stzh-header__metanav-popover.sc-stzh-header{--width:auto;--min-width:15.875rem}.stzh-header__metanav-popover.is-langnav.sc-stzh-header{--min-width:8.75rem}.stzh-header__metanav-item.sc-stzh-header{display:none;gap:var(--stzh-space-small);align-items:center;justify-content:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent;padding:0;border:none;text-decoration:none;font-size:100%;font-family:inherit;white-space:nowrap;min-width:2.5rem}@media screen and (min-width: 900px){.stzh-header__metanav-item.sc-stzh-header{display:flex}}.stzh-header__metanav-item[aria-expanded=true].sc-stzh-header{color:var(--stzh-color-primary70)}.stzh-header__metanav-item.is-heavy.sc-stzh-header{font-family:var(--stzh-font-family-heavy);font-weight:var(--stzh-font-weight-heavy);font-style:var(--stzh-font-style-heavy)}.stzh-header__metanav-item.is-stay.sc-stzh-header{display:flex}@media screen and (min-width: 900px){.stzh-header__metanav-item.is-popover-mobile.sc-stzh-header{display:none}}.stzh-header__metanav-item.is-popover-desktop.sc-stzh-header{display:none}@media screen and (min-width: 900px){.stzh-header__metanav-item.is-popover-desktop.sc-stzh-header{display:flex}}.stzh-header__metanav-menu-item.is-heavy.sc-stzh-header{font-family:var(--stzh-font-family-heavy);font-weight:var(--stzh-font-weight-heavy);font-style:var(--stzh-font-style-heavy)}.stzh-header__metanav-item-text.sc-stzh-header{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.stzh-header__metanav-item-text.is-vhidden.sc-stzh-header{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}@media screen and (max-width: 599px){.stzh-header__metanav-item-text.has-no-short-label.sc-stzh-header{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}}@media screen and (max-width: 599px){.stzh-header__metanav-item-text-label-long.sc-stzh-header{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}}@media screen and (min-width: 600px){.stzh-header__metanav-item-text-label-short.sc-stzh-header{display:none}}.stzh-header__metanav-icon-wrapper.sc-stzh-header{position:relative;display:flex;align-items:center;justify-content:center}.stzh-header__metanav-icon-badge.sc-stzh-header{position:absolute;top:-0.25rem;right:-0.25rem}.stzh-header__metanav-icon.is-open.sc-stzh-header{display:none}.stzh-header__metanav-item[aria-expanded=true].sc-stzh-header .stzh-header__metanav-icon.is-open.sc-stzh-header{display:inline-flex}.stzh-header__metanav-item[aria-expanded=true].sc-stzh-header .stzh-header__metanav-icon.is-close.sc-stzh-header{display:none}.stzh-header__logobar.sc-stzh-header{display:flex}@media screen and (min-width: 1600px){.stzh-header__logobar.sc-stzh-header{margin-left:auto;margin-right:auto;width:84.25rem}}.stzh-header__logobar-logo.sc-stzh-header{box-sizing:content-box;display:flex;overflow:hidden;flex-shrink:0}.stzh-header__logobar-decoration.sc-stzh-header{background-color:var(--logobar-background-color);flex-grow:1}@media screen and (min-width: 1600px){.stzh-header__logobar-decoration.sc-stzh-header{width:calc((100% - 34.5625rem) + ((100vw - 84.25rem - var(--stzh-scrollbar-width, 0px)) / 2));margin-right:calc((100vw - 84.25rem - var(--stzh-scrollbar-width, 0px)) / -2)}}.stzh-header__logo-link.sc-stzh-header{padding-left:var(--stzh-space-medium);padding-right:var(--stzh-space-medium);padding-top:0.875rem;padding-bottom:0.6875rem;padding-left:1.25rem;display:inline-flex;width:18rem;height:4.125rem;transition:opacity var(--stzh-base-transition-animation-speed)}@media screen and (min-width: 600px){.stzh-header__logo-link.sc-stzh-header{padding-left:var(--stzh-space-large)}}@media screen and (min-width: 900px){.stzh-header__logo-link.sc-stzh-header{padding-left:var(--stzh-space-xlarge)}}@media screen and (min-width: 1260px){.stzh-header__logo-link.sc-stzh-header{padding-left:var(--stzh-space-xxlarge)}}@media screen and (min-width: 600px){.stzh-header__logo-link.sc-stzh-header{padding-right:var(--stzh-space-large)}}@media screen and (min-width: 900px){.stzh-header__logo-link.sc-stzh-header{padding-right:var(--stzh-space-xlarge)}}@media screen and (min-width: 1260px){.stzh-header__logo-link.sc-stzh-header{padding-right:var(--stzh-space-xxlarge)}}@media screen and (min-width: 600px){.stzh-header__logo-link.sc-stzh-header{width:18.75rem;padding-left:2rem}}@media screen and (min-width: 900px){.stzh-header__logo-link.sc-stzh-header{width:24.9375rem;height:5.5rem;padding-top:1.125rem;padding-bottom:1.125rem;padding-left:2.5rem}}@media screen and (min-width: 1260px){.stzh-header__logo-link.sc-stzh-header{width:38.5625rem;height:8.4375rem;padding-top:1.75rem;padding-bottom:1.5rem;padding-left:4rem}}@media screen and (min-width: 1600px){.stzh-header__logo-link.sc-stzh-header{width:34.5625rem;padding-left:0}}.stzh-header__flyout.sc-stzh-header,.stzh-header__flyout-search.sc-stzh-header{font-size:var(--stzh-font-milli-font-size);line-height:var(--stzh-font-milli-text-line-height);letter-spacing:var(--stzh-font-curve---text-letter-spacing);z-index:calc(var(--stzh-z-index-header) - 1);position:fixed;visibility:hidden;top:0;left:0;right:0;bottom:0;width:100dvw;height:100dvh;overflow:auto;transition:visibility var(--stzh-base-transition-animation-speed)}@media (min-height: 580px){.stzh-header__flyout.sc-stzh-header{overflow:hidden}}@media screen and (min-width: 900px){.stzh-header__flyout.sc-stzh-header{overflow:hidden}}.stzh-header__flyout-backdrop.sc-stzh-header{position:absolute;width:100%;height:100%;background-color:var(--stzh-color-black40op);opacity:0;transition:opacity var(--stzh-base-transition-animation-speed)}.stzh-header__menu.sc-stzh-header{position:absolute;width:100%;height:auto;background-color:var(--stzh-color-secondary30);display:grid;grid-template-rows:auto auto;transition-property:opacity, transform;transition-duration:var(--stzh-base-transition-animation-speed);transform:translateX(-100%);opacity:0}@media (min-height: 580px){.stzh-header__menu.sc-stzh-header{height:100%;grid-template-rows:minmax(0, 1fr) auto}}@media screen and (min-width: 900px){.stzh-header__menu.sc-stzh-header{height:100%;grid-template-rows:minmax(0, 1fr) auto}}@media screen and (min-width: 900px){.stzh-header__menu.sc-stzh-header{width:20.9375rem}}@media screen and (min-width: 1260px){.stzh-header__menu.sc-stzh-header{width:23.375rem}}@media screen and (min-width: 1260px){.stzh-header__menu.sc-stzh-header{width:27.4375rem}}@media screen and (min-width: 1600px){.stzh-header__menu.sc-stzh-header{width:calc((27.4375rem - 4rem) + ((100vw - 84.25rem - var(--stzh-scrollbar-width, 0px)) / 2))}}.stzh-header__menu-nav.sc-stzh-header{position:relative;overflow-x:hidden;overflow-y:hidden}@media (min-height: 580px){.stzh-header__menu-nav.sc-stzh-header{overflow-y:auto}}@media screen and (min-width: 900px){.stzh-header__menu-nav.sc-stzh-header{overflow-y:auto;position:static}}.stzh-header__menu-metanav.sc-stzh-header{padding-top:var(--stzh-space-xsmall);padding-bottom:var(--stzh-space-xlarge);background-color:var(--stzh-color-secondary20)}@media screen and (min-width: 900px){.stzh-header__menu-metanav.sc-stzh-header{padding-top:var(--stzh-space-small)}}@media screen and (min-width: 1260px){.stzh-header__menu-metanav.sc-stzh-header{padding-top:var(--stzh-space-medium)}}@media screen and (min-width: 900px){.stzh-header__menu-metanav.sc-stzh-header{padding-bottom:var(--stzh-space-xxlarge)}}@media screen and (min-width: 1260px){.stzh-header__menu-metanav.sc-stzh-header{padding-bottom:var(--stzh-space-xxxlarge)}}@media screen and (min-width: 900px){.stzh-header__menu-metanav.sc-stzh-header{display:none}}.stzh-header__menu-metanav-nav.sc-stzh-header{max-width:23.4375rem}.stzh-header__menu-list.sc-stzh-header,.stzh-header__menu-metanav-list.sc-stzh-header{display:block;list-style:none;padding:0;margin:0}.stzh-header__menu-list.sc-stzh-header,.stzh-header__menu-metanav-list.is-level-2.sc-stzh-header{padding-top:calc(var(--stzh-header-main-height) + var(--stzh-space-xxxlarge));padding-bottom:var(--stzh-space-xxxlarge)}@media screen and (min-width: 900px){.stzh-header__menu-list.sc-stzh-header,.stzh-header__menu-metanav-list.is-level-2.sc-stzh-header{padding-top:calc(var(--stzh-header-main-height) + var(--stzh-space-huge))}}.stzh-header__menu-list.is-level-2.sc-stzh-header,.stzh-header__menu-metanav-list.is-level-2.sc-stzh-header{overflow:auto;background-color:var(--stzh-color-secondary20);visibility:hidden;opacity:0;transform:translateX(100%);position:absolute;z-index:200;top:0;left:0;width:100%;height:100%;transition-property:opacity, visibility, transform;transition-duration:var(--stzh-base-transition-animation-speed)}@media screen and (min-width: 900px){.stzh-header__menu-list.is-level-2.sc-stzh-header,.stzh-header__menu-metanav-list.is-level-2.sc-stzh-header{z-index:initial;width:19.6875rem;transform:none;left:100%;transition-property:opacity, visibility}}@media screen and (min-width: 1260px){.stzh-header__menu-list.is-level-2.sc-stzh-header,.stzh-header__menu-metanav-list.is-level-2.sc-stzh-header{width:20.875rem}}@media screen and (min-width: 1600px){.stzh-header__menu-list.is-level-2.sc-stzh-header,.stzh-header__menu-metanav-list.is-level-2.sc-stzh-header{width:21.5625rem}}.stzh-header__menu-list.is-level-2.sc-stzh-header{height:-webkit-max-content;height:-moz-max-content;height:max-content}@media (min-height: 580px){.stzh-header__menu-list.is-level-2.sc-stzh-header{height:100%}}@media screen and (min-width: 900px){.stzh-header__menu-list.is-level-2.sc-stzh-header{height:100%}}.stzh-header__menu-metanav-list.is-level-2.sc-stzh-header{background-color:var(--stzh-color-secondary30);transform:none;transition-property:opacity, visibility}@media screen and (min-width: 900px){.stzh-header__menu-list.sc-stzh-header:where(:has(>.stzh-header__menu-list-item.sc-stzh-header:hover>.stzh-header__menu-list).sc-stzh-header>.stzh-header__menu-list-item.sc-stzh-header>.stzh-header__menu-list).sc-stzh-header,.stzh-header__menu-list.sc-stzh-header:where(:has(>.stzh-header__menu-list-item.is-open.sc-stzh-header>.stzh-header__menu-list).sc-stzh-header>.stzh-header__menu-list-item.sc-stzh-header>.stzh-header__menu-list).sc-stzh-header{transition-delay:var(--stzh-base-transition-animation-speed)}}@media screen and (min-width: 900px){.stzh-header__menu-list-item.sc-stzh-header:hover>.stzh-header__menu-list.sc-stzh-header,.stzh-header__menu-list-item.is-open.sc-stzh-header>.stzh-header__menu-list.sc-stzh-header{z-index:200;transition-delay:0ms;visibility:visible;opacity:1}}@media screen and (min-width: 900px){.stzh-header__menu-list-item.sc-stzh-header:hover>.stzh-header__menu-item.sc-stzh-header,.stzh-header__menu-list-item.is-open.sc-stzh-header>.stzh-header__menu-item.sc-stzh-header{background-color:var(--stzh-color-secondary40)}}@media screen and (min-width: 900px){.stzh-header__menu-list-item.sc-stzh-header:hover>.stzh-header__menu-item.is-level-2.sc-stzh-header,.stzh-header__menu-list-item.is-open.sc-stzh-header>.stzh-header__menu-item.is-level-2.sc-stzh-header{background-color:var(--stzh-color-secondary10)}}@media screen and (max-width: 899px){.stzh-header__menu-nav.sc-stzh-header:has(.stzh-header__menu-list-item.is-open),.stzh-header__menu.sc-stzh-header:has(.stzh-header__menu-metanav-list-item.is-open) .stzh-header__menu-nav.sc-stzh-header,.stzh-header__menu-list.sc-stzh-header:has(.stzh-header__menu-list-item.is-open),.stzh-header__menu-metanav-list.sc-stzh-header:has(.stzh-header__menu-metanav-list-item.is-open){transition-property:visibility;transition-duration:0ms;transition-delay:var(--stzh-base-transition-animation-speed);visibility:hidden}}@media screen and (max-width: 899px){.stzh-header__menu-list-item.is-open.sc-stzh-header>.sc-stzh-header:where(.stzh-header__menu-list),.stzh-header__menu-metanav-list-item.is-open.sc-stzh-header>.sc-stzh-header:where(.stzh-header__menu-metanav-list){transform:translateX(0);opacity:1;visibility:visible}}.stzh-header__menu-list-item.sc-stzh-header,.stzh-header__menu-metanav-list-item.sc-stzh-header{display:grid}.stzh-header__menu-list-item.is-backlink.sc-stzh-header{display:block}.stzh-header__menu-item.sc-stzh-header,.stzh-header__menu-metanav-item.sc-stzh-header{font-family:var(--stzh-font-family-heavy);font-weight:var(--stzh-font-weight-heavy);font-style:var(--stzh-font-style-heavy);font-size:var(--stzh-font-milli-font-size);line-height:var(--stzh-font-milli-text-line-height);letter-spacing:var(--stzh-font-curve---text-letter-spacing);text-align:left;display:flex;align-items:center;gap:var(--stzh-space-xsmall);-webkit-appearance:none;-moz-appearance:none;appearance:none;border:none;text-decoration:none;background-color:transparent;color:var(--stzh-color-primary70);padding-left:var(--stzh-space-xxxlarge);padding-top:var(--stzh-space-small);padding-bottom:var(--stzh-space-small);padding-right:var(--stzh-space-large);transition-property:color, background-color;transition-duration:var(--stzh-base-transition-animation-speed);cursor:pointer}.stzh-header__menu-item.sc-stzh-header,.stzh-header__menu-metanav-item.is-title.sc-stzh-header{font-size:var(--stzh-font-deci-font-size);line-height:var(--stzh-font-deci-text-line-height);letter-spacing:var(--stzh-font-curve---text-letter-spacing);min-height:3.5rem}@media screen and (min-width: 900px){.stzh-header__menu-item.sc-stzh-header,.stzh-header__menu-metanav-item.is-title.sc-stzh-header{padding-left:2.5rem}}@media screen and (min-width: 1260px){.stzh-header__menu-item.sc-stzh-header,.stzh-header__menu-metanav-item.is-title.sc-stzh-header{padding-left:4rem}}@media screen and (min-width: 1600px){.stzh-header__menu-item.is-level-1.sc-stzh-header{padding-left:calc(((100vw - 84.25rem - var(--stzh-scrollbar-width, 0px)) / 2))}}@media screen and (min-width: 900px){.stzh-header__menu-item.has-items.sc-stzh-header{cursor:default}}.stzh-header__menu-item.is-level-2.sc-stzh-header{font-size:var(--stzh-font-milli-font-size);line-height:var(--stzh-font-milli-text-line-height);letter-spacing:var(--stzh-font-curve---text-letter-spacing);min-height:3rem}@media screen and (min-width: 900px){.stzh-header__menu-item.is-level-2.sc-stzh-header{padding-left:var(--stzh-space-xlarge)}}@media screen and (min-width: 1600px){.stzh-header__menu-item.is-level-2.sc-stzh-header{padding-left:var(--stzh-space-xxlarge)}}.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{font-family:var(--stzh-font-family-medium);font-weight:var(--stzh-font-weight-medium);font-style:var(--stzh-font-style-medium);font-size:var(--stzh-font-micro-font-size);line-height:var(--stzh-font-micro-text-line-height);margin-bottom:var(--stzh-space-medium);padding-top:var(--stzh-space-medium);padding-bottom:var(--stzh-space-small);min-height:none;padding-left:1.25rem;padding-right:1.25rem;gap:var(--stzh-space-xxsmall)}@media screen and (min-width: 600px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{margin-bottom:var(--stzh-space-large)}}@media screen and (min-width: 900px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{margin-bottom:var(--stzh-space-xlarge)}}@media screen and (min-width: 1260px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{margin-bottom:var(--stzh-space-xxlarge)}}@media screen and (min-width: 600px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{padding-top:var(--stzh-space-large)}}@media screen and (min-width: 900px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{padding-top:var(--stzh-space-xlarge)}}@media screen and (min-width: 1260px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{padding-top:var(--stzh-space-xxlarge)}}@media screen and (min-width: 900px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{padding-bottom:var(--stzh-space-medium)}}@media screen and (min-width: 1260px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{padding-bottom:var(--stzh-space-large)}}@media screen and (min-width: 600px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{padding-left:2rem;padding-right:2rem}}@media screen and (min-width: 900px){.stzh-header__menu-item.is-level-2.is-backlink.sc-stzh-header{display:none}}.stzh-header__menu-item.is-level-2.is-main.sc-stzh-header{font-size:var(--stzh-font-centi-font-size);line-height:var(--stzh-font-centi-text-line-height);letter-spacing:var(--stzh-font-curve---text-letter-spacing);margin-bottom:var(--stzh-space-xlarge)}.stzh-header__menu-metanav-item.is-level-1.sc-stzh-header{min-height:2.75rem;padding-top:var(--stzh-space-xsmall);padding-bottom:var(--stzh-space-xsmall)}.stzh-header__menu-metanav-item.is-level-2.sc-stzh-header{min-height:3.5rem;gap:var(--stzh-space-medium);padding-right:var(--stzh-space-xxlarge)}.stzh-header__menu-metanav-item.is-title.sc-stzh-header{font-family:var(--stzh-font-family-heavy);font-weight:var(--stzh-font-weight-heavy);font-style:var(--stzh-font-style-heavy);justify-content:space-between;padding-top:0;padding-bottom:0;padding-right:var(--stzh-space-medium);margin-bottom:var(--stzh-space-xlarge);cursor:default}.stzh-header__menu-metanav-item.is-language.sc-stzh-header{font-family:var(--stzh-font-family-medium);font-weight:var(--stzh-font-weight-medium);font-style:var(--stzh-font-style-medium);justify-content:space-between}.stzh-header__menu-metanav-item.is-action.sc-stzh-header{display:grid;padding-right:var(--stzh-space-xxxlarge);margin-top:var(--stzh-space-xlarge)}.stzh-header__menu-metanav-item.is-hidden.sc-stzh-header{display:none}.stzh-header__menu-metanav-item.is-level-1.sc-stzh-header .stzh-header__menu-metanav-item-icon.sc-stzh-header{--size:var(--stzh-icon-size-small)}.stzh-header__menu-metanav-item-text.sc-stzh-header{display:flex;gap:var(--stzh-space-xsmall)}.stzh-header__menu-metanav-item-text.is-vhidden.sc-stzh-header{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}.stzh-header__menu-metanav-item-counter.sc-stzh-header{font-family:var(--stzh-font-family-medium);font-weight:var(--stzh-font-weight-medium);font-style:var(--stzh-font-style-medium)}.stzh-header--is-search-filled.sc-stzh-header .stzh-header__search-text.sc-stzh-header{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}.stzh-header--hide-logo.sc-stzh-header .stzh-header__logo-link.sc-stzh-header{opacity:0}@media screen and (min-width: 600px){.stzh-header--is-fixed.sc-stzh-header .stzh-header__inner.sc-stzh-header{transform:translateY(-100%);position:fixed;top:0;left:0;right:0;margin-top:calc(var(--stzh-header-logobar-height) / -1)}}@media screen and (max-width: 599px){.stzh-header--is-fixed.sc-stzh-header .stzh-header__main.sc-stzh-header{transform:translateY(-100%);position:fixed;top:0;left:0;right:0;margin-top:calc(var(--stzh-header-logobar-height) / -1)}}@media screen and (min-width: 600px){.stzh-header--is-fixed-transition.sc-stzh-header .stzh-header__inner.sc-stzh-header{transition-property:transform;transition-duration:var(--stzh-base-transition-animation-speed)}}@media screen and (max-width: 599px){.stzh-header--is-fixed-transition.sc-stzh-header .stzh-header__main.sc-stzh-header{transition-property:transform;transition-duration:var(--stzh-base-transition-animation-speed)}}.stzh-header--is-sticky-transition.sc-stzh-header .stzh-header__logobar.sc-stzh-header{transition-property:opacity, visibility;transition-duration:var(--stzh-base-transition-animation-speed)}.stzh-header--is-sticky-transition.sc-stzh-header .stzh-header__inner.sc-stzh-header,.stzh-header--is-sticky-transition.sc-stzh-header .stzh-header__main.sc-stzh-header{transition-property:transform, margin-top;transition-duration:var(--stzh-base-transition-animation-speed)}@media screen and (min-width: 600px){.stzh-header--is-sticky.sc-stzh-header .stzh-header__inner.sc-stzh-header{transform:translateY(0)}}@media screen and (max-width: 599px){.stzh-header--is-sticky.sc-stzh-header .stzh-header__main.sc-stzh-header{transform:translateY(0)}}@media screen and (min-width: 600px) and (max-width: 899px){.stzh-header--is-sticky.sc-stzh-header:where(.stzh-header--has-empty-metabar-mobile) .stzh-header__inner.sc-stzh-header{margin-top:calc((var(--stzh-header-logobar-height) + var(--stzh-header-metabar-height)) / -1)}}@media screen and (max-width: 599px){.stzh-header--is-sticky.sc-stzh-header:where(.stzh-header--has-empty-metabar-mobile) .stzh-header__main.sc-stzh-header{margin-top:calc((var(--stzh-header-logobar-height) + var(--stzh-header-metabar-height)) / -1)}}@media screen and (max-width: 899px){.stzh-header--is-sticky.sc-stzh-header:where(.stzh-header--has-empty-metabar-mobile) .stzh-header__metabar.sc-stzh-header{visibility:hidden}}@media screen and (min-width: 600px){.stzh-header--is-sticky.sc-stzh-header:where(.stzh-header--has-empty-metabar) .stzh-header__inner.sc-stzh-header{margin-top:calc((var(--stzh-header-logobar-height) + var(--stzh-header-metabar-height)) / -1)}}@media screen and (max-width: 599px){.stzh-header--is-sticky.sc-stzh-header:where(.stzh-header--has-empty-metabar) .stzh-header__main.sc-stzh-header{margin-top:calc((var(--stzh-header-logobar-height) + var(--stzh-header-metabar-height)) / -1)}}.stzh-header--is-sticky.sc-stzh-header:where(.stzh-header--has-empty-metabar) .stzh-header__metabar.sc-stzh-header{visibility:hidden}.stzh-header--is-sticky.sc-stzh-header .stzh-header__logobar.sc-stzh-header{visibility:hidden;opacity:0}.stzh-header--sticky-always-full.sc-stzh-header .stzh-header__inner.sc-stzh-header,.stzh-header--sticky-always-full.sc-stzh-header .stzh-header__main.sc-stzh-header{margin-top:0px}.stzh-header--sticky-always-full.sc-stzh-header .stzh-header__logobar.sc-stzh-header{visibility:visible;opacity:1}.stzh-header__flyout-search-main.sc-stzh-header{position:absolute;width:100%;transition-property:opacity, transform;transition-duration:var(--stzh-base-transition-animation-speed);transform:translateY(-6.25rem);opacity:0;margin-top:var(--stzh-header-main-height);overflow:auto}.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__flyout.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__flyout-search.sc-stzh-header{visibility:visible}.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__flyout-backdrop.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__flyout-backdrop.sc-stzh-header{opacity:1}.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__flyout-scrollbar.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__flyout-scrollbar.sc-stzh-header{display:none;z-index:999;position:absolute;top:0;right:0;bottom:0;width:var(--stzh-scrollbar-width);background-color:var(--stzh-color-grey10);border-left:calc(0.5px * var(--stzh-scrollbar-active)) solid var(--stzh-color-grey30)}@media (min-height: 580px){.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__flyout-scrollbar.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__flyout-scrollbar.sc-stzh-header{display:block}}@media screen and (min-width: 900px){.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__flyout-scrollbar.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__flyout-scrollbar.sc-stzh-header{display:block}}.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__menu.sc-stzh-header{opacity:1;transform:translateX(0)}.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__flyout-search-main.sc-stzh-header{opacity:1;transform:translateX(0)}@media screen and (min-width: 600px){.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__inner.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__inner.sc-stzh-header{z-index:var(--stzh-z-index-header);transform:translateY(0);position:fixed;top:0;left:0;right:var(--stzh-scrollbar-width);margin-top:0}}@media screen and (max-width: 599px){.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__main.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__main.sc-stzh-header{z-index:var(--stzh-z-index-header);transform:translateY(0);position:fixed;top:0;left:0;right:var(--stzh-scrollbar-width);margin-top:0}}.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__logobar.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__logobar.sc-stzh-header{opacity:1}.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__logobar.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__logobar.sc-stzh-header,.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__metabar.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__metabar.sc-stzh-header{visibility:visible}.stzh-header--is-flyout-open.sc-stzh-header .stzh-header__logo-link.sc-stzh-header,.stzh-header--is-flyout-search-open.sc-stzh-header .stzh-header__logo-link.sc-stzh-header{opacity:1;transition:none}.stzh-header__search-button--is-hidden.sc-stzh-header{display:none}";const p="stzh-header-open";const _=class{constructor(h){e(this,h);this.stzhMetanavItemClick=t(this,"stzhMetanavItemClick",7);this.stzhMetanavItemChildClick=t(this,"stzhMetanavItemChildClick",7);this.stzhMetanavItemButtonClick=t(this,"stzhMetanavItemButtonClick",7);this.stzhMenuItemClick=t(this,"stzhMenuItemClick",7);this.stzhLanguageChange=t(this,"stzhLanguageChange",7);this.stzhSearchChange=t(this,"stzhSearchChange",7);this.stzhSearchChanged=t(this,"stzhSearchChanged",7);this.lastOpener=null;this.flyoutOpenedByMetanavItem=null;this.handleMenuListFocusout=e=>{const t=!e.currentTarget.contains(e.relatedTarget);if(this.isMedium&&t){this.closeMenuItem(false)}};this.handleBurgerClick=async()=>{if(this.flyoutOpenedByMetanavItem){this.flyoutOpenedByMetanavItem=false;this.closeMetanavItem()}else{this.flyoutSearchOpen=false;this.flyoutOpen=!this.flyoutOpen}const e=this.element.querySelector(".stzh-header__menu-item");if(e){window.setTimeout((()=>{e.focus()}),100)}this.updatePosition()};this.handleSearchButtonClick=async()=>{this.flyoutOpen=false;this.flyoutSearchOpen=!this.flyoutSearchOpen;const e=this.element.querySelector(".stzh-search input[type='search']");if(e){window.setTimeout((()=>{e.focus()}),100)}this.updatePosition()};this.handleBackdropClick=async()=>{this.flyoutOpen=false;this.updatePosition()};this.handleBackdropSearchClick=async()=>{this.flyoutSearchOpen=false;this.updatePosition()};this.handleMetanavItemClick=(e,t)=>{this.stzhMetanavItemClick.emit({component:"stzh-header",item:t,originalEvent:e})};this.handleMetanavItemChildClick=(e,t)=>{this.stzhMetanavItemChildClick.emit({component:"stzh-header",itemChild:t,originalEvent:e})};this.handleMetanavItemButtonClick=(e,t)=>{this.stzhMetanavItemButtonClick.emit({component:"stzh-header",itemButton:t,originalEvent:e})};this.handleMenuItemClick=(e,t)=>{this.flyoutOpen=false;this.stzhMenuItemClick.emit({component:"stzh-header",item:t,originalEvent:e})};this.handleSearchInput=e=>{this.searchValue=this.searchInput.value;this.stzhSearchChange.emit({component:"stzh-header",originalEvent:e,value:this.searchValue})};this.handleSearchChange=e=>{this.searchValue=this.searchInput.value;this.stzhSearchChanged.emit({component:"stzh-header",originalEvent:e,value:this.searchValue})};this.handleLanguageClick=(e,t)=>{if(this.languagePreventUrlchange){e.preventDefault()}this.languageActive=t.value;this.stzhLanguageChange.emit({component:"stzh-header",value:this.languageActive})};this.handleFlyoutResize=()=>{this.resizeMenunavElement()};this.handleResize=()=>{if(this.sticky==="disabled"){return}if(this.debounceResize){window.cancelAnimationFrame(this.debounceResize)}this.debounceResize=requestAnimationFrame((()=>{s((()=>{var e,t,s;this.isMedium=o("medium").matches;this.mainHeight=((e=this.mainElement)===null||e===void 0?void 0:e.offsetHeight)||0;this.metabarHeight=((t=this.metabarElement)===null||t===void 0?void 0:t.offsetHeight)||0;this.logobarHeight=((s=this.logobarElement)===null||s===void 0?void 0:s.offsetHeight)||0;this.headerTop=this.element.offsetTop;this.headerHeight=this.metabarHeight+this.logobarHeight}));a((()=>{document.documentElement.style.setProperty("--stzh-header-height",`${this.headerHeight}px`);document.documentElement.style.setProperty("--stzh-header-main-height",`${this.mainHeight}px`);document.documentElement.style.setProperty("--stzh-header-metabar-height",`${this.metabarHeight}px`);document.documentElement.style.setProperty("--stzh-header-logobar-height",`${this.logobarHeight}px`)}));this.scrollListener()}))};this.localization=undefined;this.href="https://www.stadt-zuerich.ch";this.menuId="anchorNavMain";this.searchId="anchorSearch";this.metanavId="anchorNavMeta";this.languageId="anchorNavLang";this.logoType="default";this.menuItems=[];this.menuBackLabel=undefined;this.metanavItems=[];this.languageActive=undefined;this.languages=[];this.languagePreventUrlchange=false;this.languageStay=false;this.hideMetabar=false;this.searchAction=undefined;this.searchFieldName="q";this.searchValue="";this.sticky="default";this.logoAnalyticsId=undefined;this.hideLogo=false;this.headerHeight=undefined;this.paddingTop=undefined;this.stickyActive=false;this.flyoutOpen=false;this.flyoutSearchOpen=false;this.searchFilled=undefined;this.fixed=false;this.fixedTransition=false;this.currentOpenMenuItem=null;this.currentOpenMetanavItem=null;this.currentOpenLanguage=false}handleKeydown(e){if(e.key==="Escape"){this.flyoutOpen=false;this.flyoutSearchOpen=false}}flyoutCloseClicked(){this.flyoutSearchOpen=false;this.updatePosition()}async flyoutOpenWatcher(e){if(!e){this.currentOpenMenuItem=null;this.currentOpenMetanavItem=null;this.currentOpenLanguage=null;this.flyoutOpenedByMetanavItem=false;document.body.classList.remove(p);this.enableSiblings();if(this.trap){this.trap.deactivate()}}else{document.body.classList.add(p);this.disableSiblings();if(this.trap){this.trap.activate()}}}async fixedWatcher(){this.paddingTop=this.fixed||this.flyoutOpen||this.flyoutSearchOpen?this.headerHeight:0;await this.waitForNextRender();this.fixedTransition=this.fixed||this.flyoutOpen||this.flyoutSearchOpen}stickyWatcher(){this.updatePosition()}async updatePosition(){if(this.flyoutOpen||this.flyoutSearchOpen){return}const e=()=>{this.stickyActive=true;document.documentElement.style.setProperty("--stzh-header-is-stuck","1");document.documentElement.style.setProperty("--stzh-header-is-not-stuck","0")};const t=()=>{document.documentElement.style.setProperty("--stzh-header-is-stuck","0");document.documentElement.style.setProperty("--stzh-header-is-not-stuck","1");this.stickyActive=false};if(this.sticky==="disabled"){t()}else if(this.sticky==="always-full"){e()}else if(this.sticky==="always"){if(this.belowStayStickyPoint){e()}else{t()}}else{if(this.scrollingUp&&this.belowStayStickyPoint){if(!this.stickyActive&&this.belowStartStickyPoint){e()}}else{if(this.stickyActive&&this.belowStayStickyPoint){t()}else{t()}}}}scrollListener(){if(this.sticky==="disabled"){return}s((()=>{this.currentScrollY=window.scrollY;this.scrollingUp=this.lastScrollY&&this.lastScrollY>this.currentScrollY;this.lastScrollY=this.currentScrollY;this.belowStayStickyPoint=this.currentScrollY>this.logobarHeight;this.belowStartStickyPoint=this.currentScrollY>this.headerHeight;this.fixed=this.belowStartStickyPoint||this.scrollingUp&&this.belowStayStickyPoint&&this.stickyActive||this.sticky==="always"&&this.belowStayStickyPoint||this.sticky==="always-full";this.headerOverlap=(this.headerTop-this.currentScrollY)/-1;this.hideLogo=this.sticky!=="always-full"&&this.isMedium&&this.headerOverlap>1}));a((()=>{this.updatePosition()}))}searchValueWatcher(e){this.searchFilled=e!==""}menuItemsWatcher(e){if(typeof e==="string"){this._menuItems=JSON.parse(e)}else{this._menuItems=e}this._menuItems=this._menuItems.map(((e,t)=>Object.assign({id:`submenu-${t}`},e)))}metanavItemsWatcher(e){if(typeof e==="string"){this._metanavItems=JSON.parse(e)}else{this._metanavItems=e}this._metanavItems=this._metanavItems.map(((e,t)=>Object.assign({id:`metanav-submenu-${t}`},e)))}languagesWatcher(e){if(typeof e==="string"){this._languages=JSON.parse(e)}else{this._languages=e}}getSiblings(){if(!this._parentElement){return[]}return Array.from(this._parentElement.children).filter((e=>e!==this.element))}disableSiblings(){this.getSiblings().forEach((e=>{e.setAttribute("aria-hidden","true")}))}enableSiblings(){this.getSiblings().forEach((e=>{e.removeAttribute("aria-hidden")}))}waitForNextRender(){return new Promise((e=>this.renderPromiseResolve=e))}resizeMenunavElement(){if(o("headerMetanavSticky").matches||o("medium").matches||!this.openSubmenuElement){Object.assign(this.menunavElement.style,{height:null})}else{const{height:e}=this.openSubmenuElement.getBoundingClientRect();Object.assign(this.menunavElement.style,{height:`${e}px`})}}async openMenuItem(e,t){this.flyoutOpen=true;this.lastOpener=e.currentTarget;this.openSubmenuElement=this.element.querySelector(`#${t.id}`);this.currentOpenMenuItem=t;await this.waitForNextRender();requestAnimationFrame((()=>{this.menunavElement.scrollTop=0;const e=this.openSubmenuElement&&l(this.openSubmenuElement)[0];e===null||e===void 0?void 0:e.focus();this.resizeMenunavElement()}))}async closeMenuItem(e=true){this.openSubmenuElement=null;this.currentOpenMenuItem=null;await this.waitForNextRender();if(e){requestAnimationFrame((()=>{this.lastOpener.focus();this.lastOpener=null;this.resizeMenunavElement()}))}}async openMetanavItem(e,t){if(!this.flyoutOpen){this.flyoutOpenedByMetanavItem=true;this.flyoutOpen=true}this.lastOpener=e.currentTarget;this.currentOpenMetanavItem=t;await this.waitForNextRender();requestAnimationFrame((()=>{const e=this.element.querySelector(`#${t.id}`);const s=e&&l(e)[0];s===null||s===void 0?void 0:s.focus()}))}async closeMetanavItem(){this.currentOpenMetanavItem=null;if(this.flyoutOpenedByMetanavItem){this.flyoutOpen=false}await this.waitForNextRender();requestAnimationFrame((()=>{this.lastOpener.focus();this.lastOpener=null}))}async openLanguage(e){if(!this.flyoutOpen){this.flyoutOpenedByMetanavItem=true;this.flyoutOpen=true}this.lastOpener=e.currentTarget;this.currentOpenLanguage=true;await this.waitForNextRender();requestAnimationFrame((()=>{const e=this.element.querySelector("#submenu-languages");const t=e&&l(e)[0];t===null||t===void 0?void 0:t.focus()}))}async closeLanguage(){this.currentOpenLanguage=false;if(this.flyoutOpenedByMetanavItem){this.flyoutOpen=false}await this.waitForNextRender();requestAnimationFrame((()=>{this.lastOpener.focus();this.lastOpener=null}))}async componentWillLoad(){this.menuItemsWatcher(this.menuItems);this.metanavItemsWatcher(this.metanavItems);this.languagesWatcher(this.languages);this.searchValueWatcher(this.searchValue);if(!this.localization){this.localization=await window.stzhComponents.utils.fetchTranslations(this.element,"header")}}componentDidRender(){if(this.renderPromiseResolve){this.renderPromiseResolve()}if(this.flyoutElement&&this.flyoutResizeObserver){this.flyoutResizeObserver.observe(this.flyoutElement)}if(this.flyoutSearchElement&&this.flyoutResizeObserver){this.flyoutResizeObserver.observe(this.flyoutSearchElement)}}componentDidLoad(){this.trap=c(this.element,Object.assign(Object.assign({},m()),{initialFocus:false}));this.flyoutResizeObserver=new ResizeObserver(this.handleFlyoutResize);if(this.flyoutElement){this.flyoutResizeObserver.observe(this.flyoutElement)}}connectedCallback(){this._parentElement=this.element.parentElement;this.resizeObserver=new ResizeObserver(this.handleResize);this.resizeObserver.observe(this.element)}disconnectedCallback(){var e,t;this.flyoutOpenWatcher(false);(e=this.resizeObserver)===null||e===void 0?void 0:e.disconnect();(t=this.flyoutResizeObserver)===null||t===void 0?void 0:t.disconnect()}render(){var e,t,s,a,n,o;const l=d(this.element,"metanav-before");const c=d(this.element,"metanav-after");const m={"stzh-header":true,"stzh-header--is-flyout-open":this.flyoutOpen,"stzh-header--is-flyout-search-open":this.flyoutSearchOpen,"stzh-header--is-search-filled":this.searchFilled,"stzh-header--is-fixed":this.fixed,"stzh-header--is-fixed-transition":this.fixedTransition,"stzh-header--is-sticky":this.stickyActive,"stzh-header--is-sticky-transition":this.stickyActive&&this.fixedTransition,"stzh-header--hide-logo":this.hideLogo,"stzh-header--has-empty-metabar-mobile":!l&&!c&&this._metanavItems.filter((e=>e.stay||e.stayAndShowInMobileMenu)).length===0&&this._menuItems.length===0&&(this._languages.length===0||this._languages.length>0&&!this.languageStay)&&!this.searchAction,"stzh-header--has-empty-metabar":!l&&!c&&this._metanavItems.length===0&&this._menuItems.length===0&&this._languages.length===0&&!this.searchAction,[`stzh-header--sticky-${this.sticky}`]:!!this.sticky};const z=this.languageActive||window.stzhComponents.utils.getLocale(this.element);const p=((e=this._languages)===null||e===void 0?void 0:e.find((({value:e})=>e===z)))||((t=this._languages)===null||t===void 0?void 0:t[0])||null;const _=(e,t,s)=>{var a;const i=((a=e.items)===null||a===void 0?void 0:a.length)>0||e.itemButton||!e.href?"button":"a";return h(i,Object.assign({},s,{href:i==="a"&&e.href,target:i==="a"&&e.target,class:Object.assign({"stzh-header__metanav-item":true,"is-heavy":e.important,"is-stay":e.stay||e.stayAndShowInMobileMenu},t||{})}),h("span",{class:{"stzh-header__metanav-item-text":true,"is-vhidden":e.labelHidden,"has-no-short-label":!e.labelShort}},h("span",{class:"stzh-header__metanav-item-text-label-long"},e.label),h("span",{class:"stzh-header__metanav-item-text-label-short","aria-hidden":"true"},e.labelShort)),e.icon&&h("span",{class:"stzh-header__metanav-icon-wrapper"},e.icon&&h("stzh-icon",{class:`stzh-header__metanav-icon ${e.iconOpen?"is-close":""}`,name:e.icon}),e.iconOpen&&h("stzh-icon",{class:"stzh-header__metanav-icon is-open",name:e.iconOpen}),(e.badge||e.badgeEmpty)&&h("stzh-badge",{class:"stzh-header__metanav-icon-badge",label:e.badge,type:typeof e.badgeType==="undefined"?"error":e.badgeType})))};return h(r,null,h("header",{class:m},h("div",{class:"stzh-header__header",style:{paddingTop:`${this.paddingTop}px`}},h("div",{class:"stzh-header__inner"},h("div",{class:"stzh-header__main",ref:e=>this.mainElement=e},h("div",{class:"stzh-header__logobar",ref:e=>this.logobarElement=e},h("div",{class:"stzh-header__logobar-logo"},h("a",{href:this.href,class:"stzh-header__logo-link","s-object-id":this.logoAnalyticsId||"Header Logo"},h("slot",{name:"logo"}))),h("div",{class:"stzh-header__logobar-decoration"})),!this.hideMetabar&&h("div",{class:"stzh-header__metabar",ref:e=>this.metabarElement=e},h("div",{class:"stzh-header__metabar-inner"},h("slot",{name:"menu-before"}),this._menuItems.length>0&&h("button",{id:this.menuId,class:`stzh-header__burger ${this.flyoutOpen&&!this.flyoutOpenedByMetanavItem&&"is-open"}`,onClick:this.handleBurgerClick},h("stzh-icon",{class:"stzh-header__burger-icon is-close",name:"menu"}),h("stzh-icon",{class:"stzh-header__burger-icon is-open",name:"close"}),h("div",{class:"stzh-header__burger-text"},this.localization.menuLabel)),this.searchAction&&!d(this.element,"search")&&h("form",{class:"stzh-header__metabar-search",action:this.searchAction,role:"search"},h("label",{class:"stzh-header__search"},h("input",{id:this.searchId,ref:e=>this.searchInput=e,class:"stzh-header__search-input",type:"search",name:this.searchFieldName,onChange:this.handleSearchChange,onInput:this.handleSearchInput}),h("stzh-icon",{class:"stzh-header__search-icon",name:"search"}),h("div",{class:"stzh-header__search-text"},this.localization.searchLabel))),d(this.element,"search")&&h("stzh-button",{iconPosition:"left",onClick:this.handleSearchButtonClick,variant:"tertiary-plain",size:"small"},h("stzh-icon",{slot:"icon",name:"search",class:this.flyoutSearchOpen?"stzh-header__search-button--is-hidden":""}),h("stzh-icon",{slot:"icon",name:"close",class:this.flyoutSearchOpen?"":"stzh-header__search-button--is-hidden"}),this.localization.searchLabel),h("slot",{name:"menu-after"}),h("div",{class:"stzh-header__metabar-nav",id:this.metanavId},h("slot",{name:"metanav-before"}),this._metanavItems.map((e=>{var t,s;return((t=e.items)===null||t===void 0?void 0:t.length)>0||e.itemButton?h(i,null,_(e,{"is-popover-mobile":true},{"aria-expanded":e===this.currentOpenMetanavItem?"true":"false","aria-controls":e.id,onClick:t=>{if(e===this.currentOpenMetanavItem){this.closeMetanavItem()}else{this.openMetanavItem(t,e)}this.handleMetanavItemClick(t,e)}}),h("stzh-popover",{class:{"stzh-header__metanav-popover":true},placement:"bottom-end",distance:20,variant:e.variant,size:typeof e.size==="undefined"?"large":e.size},_(e,{"is-popover-desktop":true},{onClick:t=>{this.handleMetanavItemClick(t,e)}}),h("div",{slot:"content"},((s=e.items)===null||s===void 0?void 0:s.length)>0&&h("stzh-menu",null,e.items.map((t=>h("stzh-menu-item",{class:{"stzh-header__metanav-menu-item":true,"is-heavy":typeof e.importantSubmenu==="undefined"||e.importantSubmenu},size:typeof e.size==="undefined"?"large":e.size,variant:e.variant,href:t.href,target:t.target,icon:t.icon,counter:t.counter,badge:t.badge,badgeType:t.badgeType,onClick:e=>{this.handleMetanavItemChildClick(e,t)}},t.label))))),e.itemButton&&h("stzh-button",{slot:"action",size:e.itemButton.size,href:e.itemButton.href,target:e.itemButton.target,onClick:t=>{this.handleMetanavItemButtonClick(t,e.itemButton)}},e.itemButton.label))):_(e,{},{onClick:t=>{this.handleMetanavItemClick(t,e)}})})),((s=this._languages)===null||s===void 0?void 0:s.length)>0&&h(i,null,h("h2",{id:this.languageId,class:"stzh-header__vhidden"},this.localization.languageLabel),this._menuItems.length>0&&this.languageStay&&h("button",{class:{"stzh-header__metanav-item":true,"is-popover-mobile":true,"is-stay":this.languageStay},"aria-expanded":this.currentOpenLanguage?"true":"false","aria-controls":"submenu-languages",onClick:e=>{if(this.currentOpenLanguage){this.closeLanguage()}else{this.openLanguage(e)}}},h("span",{class:"stzh-header__metanav-item-text"},p===null||p===void 0?void 0:p.text),h("stzh-icon",{class:"stzh-header__metanav-icon is-close",name:"angle-down"}),h("stzh-icon",{class:"stzh-header__metanav-icon is-open",name:"angle-up"})),h("stzh-popover",{class:"stzh-header__metanav-popover is-langnav",placement:"bottom-end",distance:20},h("button",{class:{"stzh-header__metanav-item":true,"is-popover-desktop":this._menuItems.length>0,"is-stay":this.languageStay}},h("span",{class:"stzh-header__metanav-item-text"},p===null||p===void 0?void 0:p.text),h("stzh-icon",{class:"stzh-header__metanav-icon is-close",name:"angle-down"}),h("stzh-icon",{class:"stzh-header__metanav-icon is-open",name:"angle-up"})),h("div",{slot:"content"},h("stzh-menu",null,this._languages.map((e=>h("stzh-menu-item",{class:"stzh-header__metanav-menu-item",active:(p===null||p===void 0?void 0:p.value)===e.value,href:e.value,onClick:t=>this.handleLanguageClick(t,e)},e.text))))))),h("slot",{name:"metanav-after"}))))))),this._menuItems.length>0&&h("div",{ref:e=>this.flyoutElement=e,class:"stzh-header__flyout"},h("div",{class:"stzh-header__flyout-backdrop",onClick:this.handleBackdropClick}),h("div",{class:"stzh-header__flyout-scrollbar"}),h("div",{class:"stzh-header__menu"},h("nav",{class:"stzh-header__menu-nav",ref:e=>this.menunavElement=e,"aria-label":this.localization.navigationLabel},h("ul",{class:"stzh-header__menu-list is-level-1"},this._menuItems.map((e=>{var t,s;return h("li",{class:{"stzh-header__menu-list-item":true,"is-open":e===this.currentOpenMenuItem}},((t=e.items)===null||t===void 0?void 0:t.length)>0?h("button",{"aria-expanded":e===this.currentOpenMenuItem?"true":"false","aria-controls":e.id,class:"stzh-header__menu-item is-level-1 has-items",onClick:e===this.currentOpenMenuItem?()=>this.closeMenuItem():t=>this.openMenuItem(t,e)},e.label):h("a",{href:e.href,onClick:t=>this.handleMenuItemClick(t,e),class:"stzh-header__menu-item is-level-1"},e.label),((s=e.items)===null||s===void 0?void 0:s.length)>0&&h("ul",{id:e.id,class:"stzh-header__menu-list is-level-2",onFocusout:this.handleMenuListFocusout},h("li",{class:"stzh-header__menu-list-item is-backlink"},h("button",{class:"stzh-header__menu-item is-level-2 is-backlink",onClick:()=>this.closeMenuItem()},h("stzh-icon",{name:"angle-left"}),h("span",null,this.menuBackLabel?this.menuBackLabel:this.localization.menuBackLabel))),h("li",{class:"stzh-header__menu-list-item"},h("a",{href:e.href,onClick:t=>this.handleMenuItemClick(t,e),class:"stzh-header__menu-item is-level-2 is-main"},e.label)),e.items.map((e=>h("li",{class:"stzh-header__menu-list-item"},h("a",{href:e.href,onClick:t=>this.handleMenuItemClick(t,e),class:"stzh-header__menu-item is-level-2"},e.label))))))})))),(((a=this._metanavItems)===null||a===void 0?void 0:a.length)>0||((n=this._languages)===null||n===void 0?void 0:n.length)>0)&&h("div",{class:"stzh-header__menu-metanav"},h("nav",{class:"stzh-header__menu-metanav-nav"},h("ul",{class:"stzh-header__menu-metanav-list is-level-1"},this._metanavItems.map((e=>{var t,s,a;return h("li",{class:{"stzh-header__menu-metanav-list-item":true,"is-open":e===this.currentOpenMetanavItem}},((t=e.items)===null||t===void 0?void 0:t.length)>0?h("button",{"aria-expanded":e===this.currentOpenMetanavItem?"true":"false","aria-controls":e.id,class:{"stzh-header__menu-metanav-item is-level-1":true,"is-hidden":e.stay&&!e.stayAndShowInMobileMenu},onClick:t=>{if(e===this.currentOpenMetanavItem){this.closeMetanavItem()}else{this.openMetanavItem(t,e)}this.handleMetanavItemClick(t,e)}},h("span",{class:{"stzh-header__menu-metanav-item-text":true,"is-vhidden":e.labelHidden}},e.label),e.icon&&h("stzh-icon",{class:"stzh-header__menu-metanav-item-icon",name:e.icon})):h("a",{href:e.href,class:{"stzh-header__menu-metanav-item is-level-1":true,"is-hidden":e.stay&&!e.stayAndShowInMobileMenu},onClick:t=>{this.handleMetanavItemClick(t,e)}},h("span",{class:{"stzh-header__menu-metanav-item-text":true,"is-vhidden":e.labelHidden}},e.label),e.icon&&h("stzh-icon",{class:"stzh-header__menu-metanav-item-icon",name:e.icon})),((s=e.items)===null||s===void 0?void 0:s.length)>0&&h("ul",{id:e.id,class:"stzh-header__menu-metanav-list is-level-2"},h("li",{class:"stzh-header__menu-metanav-list-item"},h("div",{class:"stzh-header__menu-metanav-item is-level-2 is-title"},h("span",null,e.label),h("stzh-button",{class:"stzh-header__menu-metanav-item-icon",variant:"tertiary",icon:"close",iconOnly:true,label:(a=this.localization.closeMetanavMenuLabel)===null||a===void 0?void 0:a.replace(/\{itemLabel\}/gi,e.label),onClick:()=>this.closeMetanavItem()}))),e.items.map((e=>h("li",{class:"stzh-header__menu-metanav-list-item"},h("a",{href:e.href,class:"stzh-header__menu-metanav-item is-level-2"},e.icon&&h("stzh-icon",{class:"stzh-header__menu-metanav-item-icon",name:e.icon}),h("span",{class:"stzh-header__menu-metanav-item-text"},h("span",null,e.label),e.counter&&h("span",{class:"stzh-header__menu-metanav-item-counter"},"(",e.counter,")")))))),e.itemButton&&h("li",{class:"stzh-header__menu-metanav-list-item"},h("div",{class:"stzh-header__menu-metanav-item is-level-2 is-action"},h("stzh-button",{href:e.itemButton.href,target:e.itemButton.target},e.itemButton.label)))))})),((o=this._languages)===null||o===void 0?void 0:o.length)>0&&h("li",{class:{"stzh-header__menu-metanav-list-item":true,"is-open":this.currentOpenLanguage}},h("button",{"aria-expanded":this.currentOpenLanguage?"true":"false","aria-controls":"submenu-languages",class:"stzh-header__menu-metanav-item is-level-1",onClick:e=>this.openLanguage(e)},h("span",null,p===null||p===void 0?void 0:p.text),h("stzh-icon",{class:"stzh-header__menu-metanav-item-icon",name:"angle-down"})),h("ul",{id:"submenu-languages",class:"stzh-header__menu-metanav-list is-level-2"},h("div",{class:"stzh-header__menu-metanav-item is-level-2 is-title"},h("span",null,this.localization.dialogLanguageTitle),h("stzh-button",{class:"stzh-header__menu-metanav-item-icon",variant:"tertiary",icon:"close",iconOnly:true,label:"Sprach-Dialog schliessen",onClick:()=>this.closeLanguage()})),this._languages.map((e=>h("li",{class:"stzh-header__menu-metanav-list-item"},h("a",{class:"stzh-header__menu-metanav-item is-level-2 is-language",href:e.value,onClick:t=>this.handleLanguageClick(t,e)},h("span",null,e.text),(p===null||p===void 0?void 0:p.value)===e.value&&h("stzh-icon",{class:"stzh-header__menu-metanav-item-icon",name:"checkmark"})))))))))))),d(this.element,"search")&&h("div",{ref:e=>this.flyoutSearchElement=e,class:"stzh-header__flyout-search"},h("div",{class:"stzh-header__flyout-backdrop",onClick:this.handleBackdropSearchClick}),h("div",{class:"stzh-header__flyout-scrollbar"}),h("div",{class:"stzh-header__flyout-search-main"},h("slot",{name:"search"})))))}get element(){return n(this)}static get watchers(){return{flyoutOpen:["flyoutOpenWatcher","fixedWatcher"],flyoutSearchOpen:["flyoutOpenWatcher","fixedWatcher"],fixed:["fixedWatcher"],headerHeight:["fixedWatcher"],sticky:["stickyWatcher"],searchValue:["searchValueWatcher"],menuItems:["menuItemsWatcher"],metanavItems:["metanavItemsWatcher"],languages:["languagesWatcher"]}}};_.style=z;export{_ as stzh_header};
|
|
2
|
-
//# sourceMappingURL=p-b608bf1a.entry.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["stzhHeaderCss","CLASS_BODY_OPEN","StzhHeader","this","lastOpener","flyoutOpenedByMetanavItem","handleMenuListFocusout","event","isNextFocusOutOfMenuList","currentTarget","contains","relatedTarget","isMedium","closeMenuItem","handleBurgerClick","async","closeMetanavItem","flyoutSearchOpen","flyoutOpen","element","querySelector","window","setTimeout","focus","updatePosition","handleSearchButtonClick","handleBackdropClick","handleBackdropSearchClick","handleMetanavItemClick","item","stzhMetanavItemClick","emit","component","originalEvent","handleMetanavItemChildClick","itemChild","stzhMetanavItemChildClick","handleMetanavItemButtonClick","itemButton","stzhMetanavItemButtonClick","handleMenuItemClick","stzhMenuItemClick","handleSearchInput","searchValue","searchInput","value","stzhSearchChange","handleSearchChange","stzhSearchChanged","handleLanguageClick","dropdownOption","languagePreventUrlchange","preventDefault","languageActive","stzhLanguageChange","handleFlyoutResize","resizeMenunavElement","handleResize","sticky","debounceResize","cancelAnimationFrame","requestAnimationFrame","readTask","media","matches","mainHeight","_a","mainElement","offsetHeight","metabarHeight","_b","metabarElement","logobarHeight","_c","logobarElement","headerTop","offsetTop","headerHeight","writeTask","document","documentElement","style","setProperty","scrollListener","handleKeydown","key","flyoutCloseClicked","flyoutOpenWatcher","open","currentOpenMenuItem","currentOpenMetanavItem","currentOpenLanguage","body","classList","remove","enableSiblings","trap","deactivate","add","disableSiblings","activate","fixedWatcher","paddingTop","fixed","waitForNextRender","fixedTransition","stickyWatcher","activateSticky","stickyActive","disableSticky","belowStayStickyPoint","scrollingUp","belowStartStickyPoint","currentScrollY","scrollY","lastScrollY","headerOverlap","hideLogo","searchValueWatcher","newValue","searchFilled","menuItemsWatcher","_menuItems","JSON","parse","map","menuItem","index","Object","assign","id","metanavItemsWatcher","_metanavItems","metanavItem","languagesWatcher","_languages","getSiblings","_parentElement","Array","from","children","filter","child","forEach","sibling","setAttribute","removeAttribute","Promise","resolve","renderPromiseResolve","openSubmenuElement","menunavElement","height","getBoundingClientRect","openMenuItem","scrollTop","firstButtonOrLink","tabbable","focusOpener","openMetanavItem","openMetanavSubmenuElement","openLanguage","closeLanguage","componentWillLoad","menuItems","metanavItems","languages","localization","stzhComponents","utils","fetchTranslations","componentDidRender","flyoutElement","flyoutResizeObserver","observe","flyoutSearchElement","componentDidLoad","createFocusTrap","createBaseFocusTrapOptions","initialFocus","ResizeObserver","connectedCallback","parentElement","resizeObserver","disconnectedCallback","disconnect","render","metanavBeforeUsed","hasSlot","metanavAfterUsed","classes","stay","stayAndShowInMobileMenu","length","languageStay","searchAction","activeLanguage","getLocale","activeLanguageOption","find","renderMetanavItemButton","additionalClasses","additionalAttributes","Element","items","href","h","target","class","important","labelHidden","labelShort","label","icon","iconOpen","name","badge","badgeEmpty","type","badgeType","Host","ref","el","logoAnalyticsId","hideMetabar","menuId","onClick","menuLabel","action","role","searchId","searchFieldName","onChange","onInput","searchLabel","iconPosition","variant","size","slot","metanavId","Fragment","e","placement","distance","childItem","importantSubmenu","counter","languageId","languageLabel","text","language","active","navigationLabel","onFocusout","menuBackLabel","_d","_e","iconOnly","closeMetanavMenuLabel","replace","_f","dialogLanguageTitle"],"sources":["src/components/stzh-header/stzh-header.scss?tag=stzh-header&encapsulation=scoped","src/components/stzh-header/stzh-header.tsx"],"sourcesContent":["/**\n * @prop --logo-width: Width of logo\n * @prop --logo-height: Height of logo\n * @prop --logobar-background-color: Background color of logobar\n * @prop --stzh-header-logobar-background-color: **Global**: Background color of logobar\n *\n * @prop --stzh-header-height: **Global**: Height of header (readonly variable on `<html>`)\n * @prop --stzh-header-main-height: **Global**: Height of main header part (readonly variable on `<html>`)\n * @prop --stzh-header-metabar-height: **Global**: Height of metabar header (readonly variable on `<html>`)\n * @prop --stzh-header-logobar-height: **Global**: Height of logobar header (readonly variable on `<html>`)\n * @prop --stzh-header-is-stuck: **Global**: Whether head is currently sticky (readonly variable on `<html>`)\n * @prop --stzh-header-is-not-stuck: **Global**: Whether head is currently not sticky (readonly variable on `<html>`)\n */\n\n:host {\n --logo-width: auto;\n --logo-height: 100%;\n --logobar-background-color: #{$headerLogobarBackgroundColor};\n\n @media print {\n display: none;\n }\n\n &[logo-type=\"aoz\"],\n &[logo-type=\"pkzh\"],\n &[logo-type=\"uvz\"] {\n --logo-height: 31px;\n\n @include mq($from: medium) {\n --logo-height: 35px;\n }\n\n @include mq($from: ultra) {\n --logo-height: 53px;\n }\n }\n\n &[logo-type=\"vbz\"] {\n --logo-height: 29px;\n\n @include mq($from: medium) {\n --logo-height: 53px;\n }\n\n @include mq($from: ultra) {\n --logo-height: 60px;\n }\n }\n\n &[logo-type=\"vbz\"] ::slotted([slot=\"logo\"]) {\n align-self: center;\n }\n\n ::slotted([slot=\"logo\"]) {\n width: var(--logo-width);\n height: var(--logo-height);\n }\n}\n\n\n.stzh-header {\n @include fontSize('milli');\n color: $colorGrey90;\n\n &__inner,\n &__main {\n max-width: calc(100vw - var(--stzh-scrollbar-width));\n // transition-property: box-shadow;\n // transition-duration: $baseTransitionAnimationSpeed;\n }\n\n &__inner {\n @include mq($from: small) {\n position: relative;\n z-index: $zIndexHeader;\n }\n }\n\n &__vhidden {\n @include visuallyhidden;\n }\n\n &__main {\n display: flex;\n flex-direction: column;\n background-color: $colorWhite;\n\n @include mq($to: small) {\n position: relative;\n z-index: $zIndexHeader;\n }\n }\n\n &__metabar {\n background-color: $colorCoolgrey10;\n }\n\n &__metabar-inner {\n @include container;\n display: flex;\n align-items: center;\n height: $headerMetabarHeight;\n\n // @include mq($to: medium) {\n // // overwrite container margin for regular\n // // to be able to use fullwidth of metabar\n // margin: 0 auto;\n // }\n\n @include mq($from: medium) {\n height: $headerMetabarHeightMediumUp;\n }\n }\n\n &__burger,\n &__search,\n &__metanav-item {\n color: $colorGrey90;\n transition: color $baseTransitionAnimationSpeed;\n cursor: pointer;\n\n &:hover {\n color: $colorBlack;\n }\n }\n\n &__burger {\n @include font('heavy');\n @include fontSize('milli');\n display: flex;\n align-items: center;\n appearance: none;\n background-color: transparent;\n border: none;\n padding: 0;\n margin-right: space('medium');\n gap: space('medium');\n color: $colorPrimary70;\n\n @include mq($from: small) {\n margin-right: space('xxlarge');\n }\n\n @include mq($from: medium) {\n margin-right: space('xxxxlarge');\n }\n }\n\n &__burger-icon {\n &.is-open {\n display: none;\n }\n }\n\n &__burger.is-open &__burger-icon.is-open {\n display: inline-flex;\n }\n\n &__burger.is-open &__burger-icon.is-close {\n display: none;\n }\n\n &__metabar-search {\n overflow: hidden; // prevents input from going out in smaller viewports\n margin-right: space('medium');\n transition-property: width;\n transition-duration: $baseTransitionAnimationSpeed;\n width: 40px;\n max-width: 345px;\n\n &:focus-within {\n width: 100%;\n }\n\n @include mq($from: small) {\n width: 96px;\n margin-right: space('xxlarge');\n }\n\n @include mq($from: medium) {\n // flex-shrink: 0; // prevent shrinking when metanav is in way\n width: 160px;\n margin-left: 0;\n margin-right: space('xxxxlarge');\n }\n }\n\n &__search {\n position: relative;\n display: block;\n width: 100%;\n }\n\n &__search-input {\n // width: 96px;\n width: 100%;\n max-width: 100%;\n background-color: transparent;\n color: transparent;\n font-family: inherit;\n font-size: inherit;\n border: none;\n padding: space('xsmall');\n padding-left: 0;\n padding-right: 0;\n height: $formInputHeightSmall;\n transition-property: padding-left, padding-right, background-color, color;\n transition-duration: $baseTransitionAnimationSpeed;\n\n @include mq($from: small) {\n color: $colorSecondary60;\n padding-left: calc(#{iconSize()} + #{space('medium')});\n }\n\n &:focus {\n // width: 345px;\n color: $colorSecondary60;\n background-color: $colorWhite;\n padding-left: calc(#{space('medium')} + #{iconSize()} + #{space('medium')});\n padding-right: space('xlarge');\n }\n\n // prevent ugly autofill background color in chrome\n &:-webkit-autofill {\n background-clip: text;\n }\n\n // hide search clear icon on chrome\n &[type=\"search\"]::-webkit-search-decoration,\n &[type=\"search\"]::-webkit-search-cancel-button,\n &[type=\"search\"]::-webkit-search-results-button,\n &[type=\"search\"]::-webkit-search-results-decoration {\n -webkit-appearance: none;\n }\n }\n\n &__search-input:focus ~ &__search-icon,\n &__search-input:focus ~ &__search-text {\n transform: translate(space('medium'), -50%);\n }\n\n &__search-input:focus ~ &__search-text {\n color: $colorGrey70;\n }\n\n &__search-text,\n &__search-icon {\n position: absolute;\n top: 50%;\n transform: translate(0, -50%);\n transition: transform $baseTransitionAnimationSpeed;\n }\n\n &__search-icon {\n left: 0px;\n\n @include mq($to: small) {\n transform: translate((40px - 24px) / 2, -50%);\n }\n }\n\n &__search-text {\n pointer-events: none;\n left: calc(#{iconSize()} + #{space('medium')});\n\n @include mq($to: small) {\n @include visuallyhidden;\n }\n }\n\n &__metabar-nav {\n display: flex;\n align-items: center;\n margin-left: auto;\n gap: space('medium');\n\n @include mq($from: small) {\n gap: space('xlarge');\n }\n\n @include mq($from: medium) {\n gap: space('xxlarge');\n }\n }\n\n &__metanav-popover {\n --width: auto;\n --min-width: 254px;\n\n &.is-langnav {\n --min-width: 140px;\n }\n }\n\n &__metanav-item {\n display: none;\n gap: space('small');\n align-items: center;\n justify-content: center;\n appearance: none;\n background-color: transparent;\n padding: 0;\n border: none;\n text-decoration: none;\n font-size: 100%;\n font-family: inherit;\n white-space: nowrap;\n min-width: 40px;\n\n @include mq($from: medium) {\n display: flex;\n }\n\n &[aria-expanded=\"true\"] {\n color: $colorPrimary70;\n }\n\n &.is-heavy {\n @include font('heavy');\n }\n\n &.is-stay {\n display: flex;\n }\n\n &.is-popover-mobile {\n @include mq($from: medium) {\n display: none;\n }\n }\n\n &.is-popover-desktop {\n display: none;\n\n @include mq($from: medium) {\n display: flex;\n }\n }\n }\n\n &__metanav-menu-item {\n &.is-heavy {\n @include font('heavy');\n }\n }\n\n &__metanav-item-text {\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n\n &.is-vhidden {\n @include visuallyhidden;\n }\n\n &.has-no-short-label {\n @include mq($to: small) {\n @include visuallyhidden;\n }\n }\n }\n\n &__metanav-item-text-label-long {\n @include mq($to: small) {\n @include visuallyhidden;\n }\n }\n\n &__metanav-item-text-label-short {\n @include mq($from: small) {\n display: none;\n }\n }\n\n &__metanav-icon-wrapper {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n\n &__metanav-icon-badge {\n position: absolute;\n top: -4px;\n right: -4px;\n }\n\n &__metanav-icon {\n &.is-open {\n display: none;\n }\n }\n\n &__metanav-item[aria-expanded=\"true\"] &__metanav-icon.is-open {\n display: inline-flex;\n }\n\n &__metanav-item[aria-expanded=\"true\"] &__metanav-icon.is-close {\n display: none;\n }\n\n // &__metabar-login {\n // display: flex;\n // flex-basis: 50%;\n\n // &:not(:empty) {\n // \t\t@include mq($from: medium) {\n // flex-basis: auto;\n // margin-left: space('small');\n // }\n // }\n // }\n\n // &__metabar-langnav {\n // &:not(:empty) {\n // @include mq($from: medium) {\n // margin-left: space('medium');\n // }\n // }\n // }\n\n &__logobar {\n display: flex;\n\n @include mq($from: ultra) {\n margin-left: auto;\n margin-right: auto;\n width: $containerMaxWidth;\n }\n }\n\n &__logobar-logo {\n box-sizing: content-box;\n display: flex;\n overflow: hidden;\n flex-shrink: 0;\n }\n\n &__logobar-decoration {\n background-color: var(--logobar-background-color);\n flex-grow: 1;\n\n @include mq($from: ultra) {\n width: calc((100% - 553px) + ((100vw - #{$containerMaxWidth} - var(--stzh-scrollbar-width, 0px)) / 2));\n margin-right: calc((100vw - #{$containerMaxWidth} - var(--stzh-scrollbar-width, 0px)) / -2);\n }\n }\n\n &__logo-link {\n @include spaceCurve('padding-left', 'regular');\n @include spaceCurve('padding-right', 'regular');\n padding-top: 14px;\n padding-bottom: 11px;\n padding-left: $containerMargin;\n display: inline-flex;\n width: 288px;\n height: 66px;\n transition: opacity $baseTransitionAnimationSpeed;\n\n @include mq($from: small) {\n width: 300px;\n padding-left: $containerMarginSmall;\n }\n\n @include mq($from: medium) {\n width: 399px;\n height: 88px;\n padding-top: 18px;\n padding-bottom: 18px;\n padding-left: $containerMarginMedium;\n }\n\n @include mq($from: large) {\n width: 617px;\n height: 135px;\n padding-top: 28px;\n padding-bottom: 24px;\n padding-left: $containerMarginLarge;\n }\n\n @include mq($from: ultra) {\n width: 553px;\n padding-left: 0;\n }\n }\n\n &__flyout,\n &__flyout-search {\n @include fontSize('milli');\n z-index: calc(#{$zIndexHeader} - 1);\n position: fixed;\n visibility: hidden;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n width: 100dvw;\n height: 100dvh;\n overflow: auto;\n transition: visibility $baseTransitionAnimationSpeed;\n }\n\n &__flyout {\n @media (min-height: 580px) {\n overflow: hidden;\n }\n\n @include mq($from: medium) {\n overflow: hidden;\n }\n }\n\n &__flyout-backdrop {\n position: absolute;\n width: 100%;\n height: 100%;\n background-color: $colorBlack40op;\n opacity: 0;\n transition: opacity $baseTransitionAnimationSpeed;\n }\n\n &__menu {\n position: absolute;\n width: 100%;\n height: auto;\n background-color: $colorSecondary30;\n display: grid;\n grid-template-rows: auto auto;\n transition-property: opacity, transform;\n transition-duration: $baseTransitionAnimationSpeed;\n transform: translateX(-100%);\n opacity: 0;\n\n @media (min-height: 580px) {\n height: 100%;\n grid-template-rows: minmax(0, 1fr) auto;\n }\n\n @include mq($from: medium) {\n height: 100%;\n grid-template-rows: minmax(0, 1fr) auto;\n }\n\n @include mq($from: medium) {\n width: 335px;\n }\n\n @include mq($from: large) {\n width: 374px;\n }\n\n @include mq($from: large) {\n width: 439px;\n }\n\n @include mq($from: ultra) {\n width: calc((439px - #{$containerMarginLarge}) + ((100vw - #{$containerMaxWidth} - var(--stzh-scrollbar-width, 0px)) / 2))\n }\n }\n\n &__menu-nav {\n position: relative;\n overflow-x: hidden;\n overflow-y: hidden;\n\n @media (min-height: 580px) {\n overflow-y: auto;\n }\n\n @include mq($from: medium) {\n overflow-y: auto;\n position: static;\n }\n }\n\n &__menu-metanav {\n @include spaceCurve('padding-top', 'tiny');\n @include spaceCurve('padding-bottom', 'medium');\n background-color: $colorSecondary20;\n\n @include mq($from: medium) {\n display: none;\n }\n }\n\n &__menu-metanav-nav {\n max-width: 375px;\n }\n\n &__menu-list,\n &__menu-metanav-list {\n display: block;\n list-style: none;\n padding: 0;\n margin: 0;\n }\n\n &__menu-list,\n &__menu-metanav-list.is-level-2 {\n padding-top: calc(var(--stzh-header-main-height) + #{space('xxxlarge')});\n padding-bottom: space('xxxlarge');\n\n @include mq($from: medium) {\n padding-top: calc(var(--stzh-header-main-height) + #{space('huge')});\n }\n }\n\n &__menu-list.is-level-2,\n &__menu-metanav-list.is-level-2 {\n overflow: auto;\n background-color: $colorSecondary20;\n visibility: hidden;\n opacity: 0;\n transform: translateX(100%);\n position: absolute;\n z-index: 200;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n transition-property: opacity, visibility, transform;\n transition-duration: $baseTransitionAnimationSpeed;\n\n @include mq($from: medium) {\n z-index: initial;\n width: 315px;\n transform: none;\n left: 100%;\n // transition-property: opacity, visibility, transform;\n transition-property: opacity, visibility;\n }\n\n @include mq($from: large) {\n width: 334px;\n }\n\n @include mq($from: ultra) {\n width: 345px;\n }\n }\n\n &__menu-list.is-level-2 {\n height: max-content;\n\n @media (min-height: 580px) {\n height: 100%;\n }\n\n @include mq($from: medium) {\n height: 100%;\n }\n }\n\n &__menu-metanav-list.is-level-2 {\n background-color: $colorSecondary30;\n transform: none;\n transition-property: opacity, visibility;\n }\n\n // we add closing transition delay only to menu-list if hovering/focusing of another is currently active\n // to prevent showing background (flickering) when transitioning from one menu-list to another (on the same level)\n &__menu-list:where(:has(> #{&}__menu-list-item:hover > #{&}__menu-list) > #{&}__menu-list-item > #{&}__menu-list),\n &__menu-list:where(:has(> #{&}__menu-list-item.is-open > #{&}__menu-list) > #{&}__menu-list-item > #{&}__menu-list) {\n @include mq($from: medium) {\n transition-delay: $baseTransitionAnimationSpeed;\n }\n }\n\n &__menu-list-item:hover > &__menu-list,\n &__menu-list-item.is-open > &__menu-list {\n @include mq($from: medium) {\n z-index: 200;\n transition-delay: 0ms;\n visibility: visible;\n opacity: 1;\n // transform: translateX(0);\n }\n }\n\n &__menu-list-item:hover > &__menu-item,\n &__menu-list-item.is-open > &__menu-item {\n @include mq($from: medium) {\n background-color: $colorSecondary40;\n }\n\n &.is-level-2 {\n @include mq($from: medium) {\n background-color: $colorSecondary10;\n }\n }\n }\n\n &__menu-nav:has(#{&}__menu-list-item.is-open), // hide menu when any menu-list has been opened\n &__menu:has(#{&}__menu-metanav-list-item.is-open) &__menu-nav, // hide menu when menu metanav menu-list has been opened\n &__menu-list:has(#{&}__menu-list-item.is-open), // hide parent menu-list when sub menu-list has been opened\n &__menu-metanav-list:has(#{&}__menu-metanav-list-item.is-open) { // hide parent metanav menu-list when sub menu-list has been opened\n @include mq($to: medium) {\n transition-property: visibility;\n transition-duration: 0ms;\n transition-delay: $baseTransitionAnimationSpeed;\n visibility: hidden;\n // background-color: red;\n }\n }\n\n // force showing menu-list that is currently open\n &__menu-list-item.is-open > :where(#{&}__menu-list),\n &__menu-metanav-list-item.is-open > :where(#{&}__menu-metanav-list) {\n @include mq($to: medium) {\n transform: translateX(0);\n opacity: 1;\n visibility: visible;\n // background-color: green;\n }\n }\n\n &__menu-list-item,\n &__menu-metanav-list-item {\n display: grid;\n }\n\n &__menu-list-item {\n &.is-backlink {\n display: block;\n }\n }\n\n &__menu-item,\n &__menu-metanav-item {\n @include font('heavy');\n @include fontSize('milli');\n text-align: left;\n display: flex;\n align-items: center;\n gap: space('xsmall');\n appearance: none;\n border: none;\n text-decoration: none;\n background-color: transparent;\n color: $colorPrimary70;\n padding-left: space('xxxlarge');\n padding-top: space('small');\n padding-bottom: space('small');\n padding-right: space('large');\n transition-property: color, background-color;\n transition-duration: $baseTransitionAnimationSpeed;\n cursor: pointer;\n }\n\n &__menu-item,\n &__menu-metanav-item.is-title {\n @include fontSize('deci');\n min-height: 56px;\n\n @include mq($from: medium) {\n padding-left: $containerMarginMedium;\n }\n\n @include mq($from: large) {\n padding-left: $containerMarginLarge;\n }\n }\n\n &__menu-item {\n &.is-level-1 {\n @include mq($from: ultra) {\n padding-left: calc(((100vw - #{$containerMaxWidth} - var(--stzh-scrollbar-width, 0px)) / 2));\n }\n }\n\n &.has-items {\n @include mq($from: medium) {\n cursor: default;\n }\n }\n\n &.is-level-2 {\n @include fontSize('milli');\n min-height: 48px;\n\n @include mq($from: medium) {\n padding-left: space('xlarge');\n }\n\n @include mq($from: ultra) {\n padding-left: space('xxlarge');\n }\n }\n\n &.is-level-2.is-backlink {\n @include font;\n @include fontSize('micro');\n @include spaceCurve('margin-bottom', 'regular');\n @include spaceCurve('padding-top', 'regular');\n @include spaceCurve('padding-bottom', 'small');\n min-height: none;\n padding-left: $containerMargin;\n padding-right: $containerMargin;\n gap: space('xxsmall');\n\n @include mq($from: small) {\n padding-left: $containerMarginSmall;\n padding-right: $containerMarginSmall;\n }\n\n @include mq($from: medium) {\n display: none;\n }\n }\n\n &.is-level-2.is-main {\n @include fontSize('centi');\n margin-bottom: space('xlarge');\n }\n }\n\n &__menu-metanav-item {\n &.is-level-1 {\n min-height: 44px;\n padding-top: space('xsmall');\n padding-bottom: space('xsmall');\n }\n\n &.is-level-2 {\n min-height: 56px;\n gap: space('medium');\n padding-right: space('xxlarge');\n }\n\n &.is-title {\n @include font('heavy');\n justify-content: space-between;\n padding-top: 0;\n padding-bottom: 0;\n padding-right: space('medium');\n margin-bottom: space('xlarge');\n cursor: default;\n }\n\n &.is-language {\n @include font;\n justify-content: space-between;\n }\n\n &.is-action {\n display: grid;\n padding-right: space('xxxlarge');\n margin-top: space('xlarge');\n }\n\n &.is-hidden {\n display: none;\n }\n }\n\n &__menu-metanav-item.is-level-1 &__menu-metanav-item-icon {\n --size: #{iconSize('small')};\n }\n\n &__menu-metanav-item-text {\n display: flex;\n gap: space('xsmall');\n\n &.is-vhidden {\n @include visuallyhidden;\n }\n }\n\n &__menu-metanav-item-counter {\n @include font;\n }\n\n /* Search is filled */\n\n &--is-search-filled &__search-text {\n @include visuallyhidden;\n }\n\n /* Hide logo */\n\n &--hide-logo &__logo-link {\n opacity: 0;\n }\n\n /* Fixed variant (as soon as header is passed) */\n\n &--is-fixed &__inner {\n @include mq($from: small) {\n transform: translateY(-100%);\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n margin-top: calc(var(--stzh-header-logobar-height) / -1);\n }\n }\n\n &--is-fixed &__main {\n @include mq($to: small) {\n transform: translateY(-100%);\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n margin-top: calc(var(--stzh-header-logobar-height) / -1);\n }\n }\n\n &--is-fixed-transition &__inner {\n @include mq($from: small) {\n transition-property: transform;\n transition-duration: $baseTransitionAnimationSpeed;\n }\n }\n\n &--is-fixed-transition &__main {\n @include mq($to: small) {\n transition-property: transform;\n transition-duration: $baseTransitionAnimationSpeed;\n }\n }\n\n /* Sticky (transition) variant */\n\n &--is-sticky-transition &__logobar {\n transition-property: opacity, visibility;\n transition-duration: $baseTransitionAnimationSpeed;\n }\n\n &--is-sticky-transition &__inner,\n &--is-sticky-transition &__main {\n transition-property: transform, margin-top;\n transition-duration: $baseTransitionAnimationSpeed;\n }\n\n &--is-sticky &__inner {\n @include mq($from: small) {\n transform: translateY(0);\n }\n }\n\n &--is-sticky &__main {\n @include mq($to: small) {\n transform: translateY(0);\n }\n }\n\n &--is-sticky:where(#{&}--has-empty-metabar-mobile) &__inner {\n @include mq($from: small, $to: medium) {\n margin-top: calc((var(--stzh-header-logobar-height) + var(--stzh-header-metabar-height)) / -1);\n }\n }\n\n &--is-sticky:where(#{&}--has-empty-metabar-mobile) &__main {\n @include mq($to: small) {\n margin-top: calc((var(--stzh-header-logobar-height) + var(--stzh-header-metabar-height)) / -1);\n }\n }\n\n // &--is-sticky:where(#{&}--has-empty-metabar-mobile) &__inner {\n // \t@include mq($from: small, $to: medium) {\n // box-shadow: none;\n // }\n // }\n\n // &--is-sticky:where(#{&}--has-empty-metabar-mobile) &__main {\n // \t@include mq($to: small) {\n // box-shadow: none;\n // }\n // }\n\n &--is-sticky:where(#{&}--has-empty-metabar-mobile) &__metabar {\n @include mq($to: medium) {\n visibility: hidden;\n }\n }\n\n\n &--is-sticky:where(#{&}--has-empty-metabar) &__inner {\n @include mq($from: small) {\n margin-top: calc((var(--stzh-header-logobar-height) + var(--stzh-header-metabar-height)) / -1);\n }\n }\n\n &--is-sticky:where(#{&}--has-empty-metabar) &__main {\n @include mq($to: small) {\n margin-top: calc((var(--stzh-header-logobar-height) + var(--stzh-header-metabar-height)) / -1);\n }\n }\n\n // &--is-sticky:where(#{&}--has-empty-metabar) &__inner {\n // \t@include mq($from: small) {\n // box-shadow: none;\n // }\n // }\n\n // &--is-sticky:where(#{&}--has-empty-metabar) &__main {\n // \t@include mq($to: small) {\n // box-shadow: none;\n // }\n // }\n\n &--is-sticky:where(#{&}--has-empty-metabar) &__metabar {\n visibility: hidden;\n }\n\n &--is-sticky &__logobar {\n visibility: hidden;\n opacity: 0;\n }\n\n // &--is-sticky:where(#{&}--has-metabar-stay) &__metabar {\n // visibility: visible;\n // }\n\n // &--is-sticky:where(#{&}--has-metabar-stay) &__main {\n // \t@include mq($to: small) {\n // // box-shadow: $boxShadowHeader;\n // margin-top: calc((var(--stzh-header-logobar-height)) / -1);\n // }\n // }\n\n // &--is-sticky:where(#{&}--has-metabar-stay) &__inner {\n // \t@include mq($from: small) {\n // // box-shadow: $boxShadowHeader;\n // margin-top: calc((var(--stzh-header-logobar-height)) / -1);\n // }\n // }\n\n /* Sticky disabled */\n\n // &--sticky-disabled &__main {\n // @include mq($from: medium) {\n // padding-top: $headerMetabarHeightMediumUp;\n // }\n // }\n\n /* Sticky always */\n\n &--sticky-always-full &__inner,\n &--sticky-always-full &__main {\n margin-top: 0px;\n }\n\n &--sticky-always-full &__logobar {\n visibility: visible;\n opacity: 1;\n }\n\n /* Flyout open */\n\n &__flyout-search-main {\n position: absolute;\n width: 100%;\n transition-property: opacity, transform;\n transition-duration: $baseTransitionAnimationSpeed;\n transform: translateY(-100px);\n opacity: 0;\n margin-top: var(--stzh-header-main-height);\n overflow: auto;\n }\n\n &--is-flyout-open &__flyout,\n &--is-flyout-search-open &__flyout-search {\n visibility: visible;\n }\n\n &--is-flyout-open &__flyout-backdrop,\n &--is-flyout-search-open &__flyout-backdrop {\n opacity: 1;\n }\n\n &--is-flyout-open &__flyout-scrollbar,\n &--is-flyout-search-open &__flyout-scrollbar {\n display: none;\n z-index: 999;\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n width: var(--stzh-scrollbar-width);\n background-color: $colorGrey10;\n border-left: calc(0.5px * var(--stzh-scrollbar-active)) solid $colorGrey30;\n\n @media (min-height: 580px) {\n display: block;\n }\n\n @include mq($from: medium) {\n display: block;\n }\n }\n\n &--is-flyout-open &__menu {\n opacity: 1;\n transform: translateX(0);\n }\n\n &--is-flyout-search-open &__flyout-search-main {\n opacity: 1;\n transform: translateX(0);\n }\n\n &--is-flyout-open &__inner,\n &--is-flyout-search-open &__inner {\n @include mq($from: small) {\n z-index: $zIndexHeader;\n transform: translateY(0);\n position: fixed;\n top: 0;\n left: 0;\n right: var(--stzh-scrollbar-width);\n margin-top: 0;\n }\n }\n\n &--is-flyout-open &__main,\n &--is-flyout-search-open &__main {\n @include mq($to: small) {\n z-index: $zIndexHeader;\n transform: translateY(0);\n position: fixed;\n top: 0;\n left: 0;\n right: var(--stzh-scrollbar-width);\n margin-top: 0;\n }\n }\n\n &--is-flyout-open &__logobar,\n &--is-flyout-search-open &__logobar {\n opacity: 1;\n }\n\n &--is-flyout-open &__logobar,\n &--is-flyout-search-open &__logobar,\n &--is-flyout-open &__metabar,\n &--is-flyout-search-open &__metabar {\n visibility: visible;\n }\n\n &--is-flyout-open &__logo-link,\n &--is-flyout-search-open &__logo-link {\n opacity: 1;\n transition: none;\n }\n\n /**\n * Search button.\n */\n &__search-button--is-hidden {\n display: none;\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n Fragment,\n h,\n Host,\n Listen,\n Method,\n Prop,\n readTask,\n State,\n Watch,\n writeTask,\n} from \"@stencil/core\";\n\nimport { hasSlot } from \"../../utils/utils\";\nimport { media } from \"../../utils/media-utils\";\nimport {\n StzhDropdownOption,\n StzhHeaderLanguageChangeEvent,\n StzhHeaderMenuItem,\n StzhHeaderMenuItemClickEvent,\n StzhHeaderMetanavItem,\n StzhHeaderMetanavItemButton,\n StzhHeaderMetanavItemButtonClickEvent,\n StzhHeaderMetanavItemChild,\n StzhHeaderMetanavItemChildClickEvent,\n StzhHeaderMetanavItemClickEvent,\n StzhHeaderSearchChangedEvent,\n StzhHeaderSearchChangeEvent,\n} from \"../../index\";\n\nimport { tabbable } from \"tabbable\";\nimport { createBaseFocusTrapOptions } from \"../../utils/overlay-utils\";\nimport { createFocusTrap, FocusTrap } from \"focus-trap\";\n\nimport { StzhHeaderLocalizedText } from \"./stzh-header.localization\";\n\nconst CLASS_BODY_OPEN = \"stzh-header-open\";\n\n// for flyout a11y see also: https://www.w3.org/WAI/tutorials/menus/flyout/\n\n/**\n * @slot logo - Slot for brand logo\n * @slot menu-before - Slot for custom elements before other menu elements\n * @slot menu-after - Slot for custom elements after other menu elements\n * @slot metanav-before - Slot for custom elements before other metanav elements\n * @slot metanav-after - Slot for custom elements after other metanav elements\n * @slot search - Slot for search element\n */\n@Component({\n tag: \"stzh-header\",\n styleUrl: \"stzh-header.scss\",\n scoped: true,\n})\nexport class StzhHeader {\n /** Translation strings */\n @Prop() localization: StzhHeaderLocalizedText;\n\n /** Portal link (for logo) */\n @Prop() href: string = \"https://www.stadt-zuerich.ch\";\n\n /** Menu element ID */\n @Prop() menuId: string = \"anchorNavMain\";\n\n /** Search element ID */\n @Prop() searchId: string = \"anchorSearch\";\n\n /** Metanav element ID */\n @Prop() metanavId: string = \"anchorNavMeta\";\n\n /** Language element ID */\n @Prop() languageId: string = \"anchorNavLang\";\n\n /**\n * Type of logo (used for setting the correct height).\n * Will enlarge the logo to 100% by default (default logos are using whitespace).\n */\n @Prop({ reflect: true }) logoType: \"default\" | \"vbz\" | \"aoz\" | \"pkzh\" | \"uvz\" = \"default\";\n\n /** Menu navigation items */\n @Prop() menuItems: StzhHeaderMenuItem[] | string = [];\n private _menuItems: StzhHeaderMenuItem[];\n\n /** Overwrite menu back label */\n @Prop() menuBackLabel: string;\n\n /** Meta navigation items */\n @Prop() metanavItems: StzhHeaderMetanavItem[] | string = [];\n private _metanavItems: StzhHeaderMetanavItem[];\n\n /** Current language page path */\n @Prop({ mutable: true }) languageActive: string;\n\n /** Available language (paths) in language switch */\n @Prop() languages: StzhDropdownOption[] | string = [];\n private _languages: StzhDropdownOption[];\n\n /** Prevent url change when language has changed (will only fire `stzhLanguageChange`) */\n @Prop() languagePreventUrlchange: boolean = false;\n\n /** Whether language switch should stay on mobile */\n @Prop() languageStay: boolean = false;\n\n /** Whether language switch should stay on mobile */\n @Prop() hideMetabar: boolean = false;\n\n /** Search form action (if given, searchfield will be shown) */\n @Prop() searchAction: string;\n\n /** Search field name */\n @Prop() searchFieldName: string = \"q\";\n\n /** Search input value */\n @Prop() searchValue: string = \"\";\n\n /** Sticky behaviour */\n @Prop() sticky: \"default\" | \"disabled\" | \"always-full\" | \"always\" = \"default\";\n\n /**\n * For Adobe Analytics.\n * Will be rendered as value of `s-object-id` attribute to the logo link element.\n * Default value is \"Header Logo\".\n */\n @Prop() logoAnalyticsId: string;\n\n @State() hideLogo: boolean = false;\n @State() headerHeight: number;\n @State() paddingTop: number;\n @State() stickyActive: boolean = false;\n @State() flyoutOpen: boolean = false;\n @State() flyoutSearchOpen: boolean = false;\n @State() searchFilled: boolean;\n\n @State() fixed: boolean = false;\n @State() fixedTransition: boolean = false;\n\n @State() currentOpenMenuItem: StzhHeaderMenuItem = null;\n @State() currentOpenMetanavItem: StzhHeaderMetanavItem = null;\n @State() currentOpenLanguage: boolean = false;\n private openSubmenuElement: HTMLElement;\n\n @Element() element: HTMLStzhHeaderElement;\n\n @Listen(\"keydown\", { target: \"document\" })\n handleKeydown(event: KeyboardEvent) {\n if (event.key === \"Escape\") {\n this.flyoutOpen = false;\n this.flyoutSearchOpen = false;\n }\n }\n\n @Listen(\"stzhOverlayCloseClick\")\n flyoutCloseClicked() {\n this.flyoutSearchOpen = false;\n this.updatePosition();\n }\n\n @Watch(\"flyoutOpen\")\n @Watch(\"flyoutSearchOpen\")\n async flyoutOpenWatcher(open: boolean) {\n if (!open) {\n // reset current open menu when flyout was closed\n this.currentOpenMenuItem = null;\n this.currentOpenMetanavItem = null;\n this.currentOpenLanguage = null;\n // reset further flags\n this.flyoutOpenedByMetanavItem = false;\n\n document.body.classList.remove(CLASS_BODY_OPEN);\n this.enableSiblings();\n\n if (this.trap) {\n this.trap.deactivate();\n }\n } else {\n document.body.classList.add(CLASS_BODY_OPEN);\n this.disableSiblings();\n\n if (this.trap) {\n this.trap.activate();\n }\n }\n }\n\n @Watch(\"fixed\")\n @Watch(\"flyoutOpen\")\n @Watch(\"flyoutSearchOpen\")\n @Watch(\"headerHeight\")\n async fixedWatcher() {\n this.paddingTop = this.fixed || this.flyoutOpen || this.flyoutSearchOpen ? this.headerHeight : 0;\n // we don't want to run transitions on applying fixed class (out transition),\n // so we set them in the next render\n await this.waitForNextRender();\n this.fixedTransition = this.fixed || this.flyoutOpen || this.flyoutSearchOpen;\n }\n\n @Watch(\"sticky\")\n stickyWatcher() {\n this.updatePosition();\n }\n\n /** Update position / sticky state of header */\n @Method()\n async updatePosition() {\n if (this.flyoutOpen || this.flyoutSearchOpen) {\n return;\n }\n\n const activateSticky = () => {\n this.stickyActive = true;\n document.documentElement.style.setProperty(\"--stzh-header-is-stuck\", \"1\");\n document.documentElement.style.setProperty(\"--stzh-header-is-not-stuck\", \"0\");\n };\n\n const disableSticky = () => {\n document.documentElement.style.setProperty(\"--stzh-header-is-stuck\", \"0\");\n document.documentElement.style.setProperty(\"--stzh-header-is-not-stuck\", \"1\");\n this.stickyActive = false;\n };\n\n if (this.sticky === \"disabled\") {\n disableSticky();\n } else if (this.sticky === \"always-full\") {\n activateSticky();\n } else if (this.sticky === \"always\") {\n if (this.belowStayStickyPoint) {\n activateSticky();\n } else {\n disableSticky();\n }\n } else {\n if (this.scrollingUp && this.belowStayStickyPoint) {\n if (!this.stickyActive && this.belowStartStickyPoint) {\n activateSticky();\n }\n } else {\n if (this.stickyActive && this.belowStayStickyPoint) {\n disableSticky();\n } else {\n disableSticky();\n }\n }\n }\n }\n\n @Listen(\"scroll\", { target: \"window\" })\n scrollListener() {\n if (this.sticky === \"disabled\") {\n return;\n }\n\n readTask(() => {\n this.currentScrollY = window.scrollY;\n this.scrollingUp = this.lastScrollY && this.lastScrollY > this.currentScrollY;\n this.lastScrollY = this.currentScrollY;\n\n this.belowStayStickyPoint = this.currentScrollY > this.logobarHeight;\n this.belowStartStickyPoint = this.currentScrollY > this.headerHeight;\n\n this.fixed =\n this.belowStartStickyPoint ||\n (this.scrollingUp && this.belowStayStickyPoint && this.stickyActive) ||\n (this.sticky === \"always\" && this.belowStayStickyPoint) ||\n this.sticky === \"always-full\";\n\n this.headerOverlap = (this.headerTop - this.currentScrollY) / -1;\n this.hideLogo = this.sticky !== \"always-full\" && this.isMedium && this.headerOverlap > 1;\n });\n\n writeTask(() => {\n this.updatePosition();\n });\n }\n\n /** Metanav item click event */\n @Event() stzhMetanavItemClick: EventEmitter<StzhHeaderMetanavItemClickEvent>;\n\n /** Metanav item child click event */\n @Event() stzhMetanavItemChildClick: EventEmitter<StzhHeaderMetanavItemChildClickEvent>;\n\n /** Metanav item button click event */\n @Event() stzhMetanavItemButtonClick: EventEmitter<StzhHeaderMetanavItemButtonClickEvent>;\n\n /** Metanav item click event */\n @Event() stzhMenuItemClick: EventEmitter<StzhHeaderMenuItemClickEvent>;\n\n /** Language change event */\n @Event() stzhLanguageChange: EventEmitter<StzhHeaderLanguageChangeEvent>;\n\n /** Search input change event */\n @Event() stzhSearchChange: EventEmitter<StzhHeaderSearchChangeEvent>;\n\n /** Search input changed event */\n @Event() stzhSearchChanged: EventEmitter<StzhHeaderSearchChangedEvent>;\n\n @Watch(\"searchValue\")\n searchValueWatcher(newValue: string) {\n this.searchFilled = newValue !== \"\";\n }\n\n @Watch(\"menuItems\")\n menuItemsWatcher(newValue: StzhHeaderMenuItem[] | string) {\n if (typeof newValue === \"string\") {\n this._menuItems = JSON.parse(newValue);\n } else {\n this._menuItems = newValue;\n }\n\n this._menuItems = this._menuItems.map((menuItem, index) => ({\n id: `submenu-${index}`,\n ...menuItem,\n }));\n }\n\n @Watch(\"metanavItems\")\n metanavItemsWatcher(newValue: StzhHeaderMetanavItem[] | string) {\n if (typeof newValue === \"string\") {\n this._metanavItems = JSON.parse(newValue);\n } else {\n this._metanavItems = newValue;\n }\n\n this._metanavItems = this._metanavItems.map((metanavItem, index) => ({\n id: `metanav-submenu-${index}`,\n ...metanavItem,\n }));\n }\n\n @Watch(\"languages\")\n languagesWatcher(newValue: StzhDropdownOption[] | string) {\n if (typeof newValue === \"string\") {\n this._languages = JSON.parse(newValue);\n } else {\n this._languages = newValue;\n }\n }\n\n private renderPromiseResolve: (value?: unknown) => void;\n\n private currentScrollY: number;\n private lastScrollY: number;\n private headerOverlap: number;\n private scrollingUp: boolean;\n private belowStayStickyPoint: boolean;\n private belowStartStickyPoint: boolean;\n\n private headerTop: number;\n // private innerHeight: number;\n private mainHeight: number;\n private metabarHeight: number;\n private logobarHeight: number;\n\n private isMedium: boolean;\n\n private debounceResize: number;\n private resizeObserver: ResizeObserver;\n private flyoutResizeObserver: ResizeObserver;\n\n // private innerElement: HTMLDivElement;\n private mainElement: HTMLDivElement;\n private logobarElement: HTMLDivElement;\n private metabarElement: HTMLDivElement;\n private menunavElement: HTMLElement;\n private flyoutElement: HTMLElement;\n private flyoutSearchElement: HTMLElement;\n\n private searchInput: HTMLInputElement;\n\n private lastOpener: HTMLButtonElement | null = null;\n private flyoutOpenedByMetanavItem: boolean = null;\n\n private trap: FocusTrap;\n private _parentElement: HTMLElement;\n\n private getSiblings() {\n if (!this._parentElement) {\n return [];\n }\n\n return Array.from(this._parentElement.children).filter(child => child !== this.element);\n }\n\n private disableSiblings() {\n this.getSiblings().forEach(sibling => {\n sibling.setAttribute(\"aria-hidden\", \"true\");\n });\n }\n\n private enableSiblings() {\n this.getSiblings().forEach(sibling => {\n sibling.removeAttribute(\"aria-hidden\");\n });\n }\n\n private waitForNextRender() {\n return new Promise(resolve => (this.renderPromiseResolve = resolve));\n }\n\n private resizeMenunavElement() {\n // reset height when metanav is sticky, or on medium or no submenu element is open\n if (media(\"headerMetanavSticky\").matches || media(\"medium\").matches || !this.openSubmenuElement) {\n Object.assign(this.menunavElement.style, {\n height: null,\n });\n } else {\n const { height } = this.openSubmenuElement.getBoundingClientRect();\n Object.assign(this.menunavElement.style, {\n height: `${height}px`,\n });\n }\n }\n\n private async openMenuItem(event: MouseEvent, menuItem: StzhHeaderMenuItem) {\n this.flyoutOpen = true;\n\n this.lastOpener = event.currentTarget as HTMLButtonElement;\n this.openSubmenuElement = this.element.querySelector(`#${menuItem.id}`) as HTMLElement;\n this.currentOpenMenuItem = menuItem;\n await this.waitForNextRender();\n\n requestAnimationFrame(() => {\n this.menunavElement.scrollTop = 0;\n\n const firstButtonOrLink = this.openSubmenuElement && tabbable(this.openSubmenuElement)[0];\n firstButtonOrLink?.focus();\n\n this.resizeMenunavElement();\n });\n }\n\n private async closeMenuItem(focusOpener: boolean = true) {\n this.openSubmenuElement = null;\n this.currentOpenMenuItem = null;\n await this.waitForNextRender();\n\n if (focusOpener) {\n requestAnimationFrame(() => {\n this.lastOpener.focus();\n this.lastOpener = null;\n\n this.resizeMenunavElement();\n });\n }\n }\n\n private async openMetanavItem(event: MouseEvent, metanavItem: StzhHeaderMetanavItem) {\n if (!this.flyoutOpen) {\n this.flyoutOpenedByMetanavItem = true;\n this.flyoutOpen = true;\n }\n\n this.lastOpener = event.currentTarget as HTMLButtonElement;\n this.currentOpenMetanavItem = metanavItem;\n await this.waitForNextRender();\n\n requestAnimationFrame(() => {\n const openMetanavSubmenuElement = this.element.querySelector(`#${metanavItem.id}`);\n const firstButtonOrLink = openMetanavSubmenuElement && tabbable(openMetanavSubmenuElement)[0];\n firstButtonOrLink?.focus();\n });\n }\n\n private async closeMetanavItem() {\n this.currentOpenMetanavItem = null;\n\n if (this.flyoutOpenedByMetanavItem) {\n this.flyoutOpen = false;\n }\n\n await this.waitForNextRender();\n\n requestAnimationFrame(() => {\n this.lastOpener.focus();\n this.lastOpener = null;\n });\n }\n\n private async openLanguage(event: MouseEvent) {\n if (!this.flyoutOpen) {\n this.flyoutOpenedByMetanavItem = true;\n this.flyoutOpen = true;\n }\n\n this.lastOpener = event.currentTarget as HTMLButtonElement;\n this.currentOpenLanguage = true;\n await this.waitForNextRender();\n\n requestAnimationFrame(() => {\n const openMetanavSubmenuElement = this.element.querySelector(\"#submenu-languages\");\n const firstButtonOrLink = openMetanavSubmenuElement && tabbable(openMetanavSubmenuElement)[0];\n firstButtonOrLink?.focus();\n });\n }\n\n private async closeLanguage() {\n this.currentOpenLanguage = false;\n\n if (this.flyoutOpenedByMetanavItem) {\n this.flyoutOpen = false;\n }\n\n await this.waitForNextRender();\n\n requestAnimationFrame(() => {\n this.lastOpener.focus();\n this.lastOpener = null;\n });\n }\n\n private handleMenuListFocusout = (event: FocusEvent) => {\n const isNextFocusOutOfMenuList = !(event.currentTarget as HTMLElement).contains(event.relatedTarget as HTMLElement);\n\n if (this.isMedium && isNextFocusOutOfMenuList) {\n this.closeMenuItem(false);\n }\n };\n\n private handleBurgerClick = async () => {\n if (this.flyoutOpenedByMetanavItem) {\n this.flyoutOpenedByMetanavItem = false;\n this.closeMetanavItem();\n } else {\n this.flyoutSearchOpen = false;\n this.flyoutOpen = !this.flyoutOpen;\n }\n\n // focus first menu item\n const element = this.element.querySelector(\".stzh-header__menu-item\") as HTMLElement;\n\n if (element) {\n window.setTimeout(() => {\n element.focus();\n }, 100);\n }\n\n this.updatePosition();\n };\n\n private handleSearchButtonClick = async () => {\n this.flyoutOpen = false;\n this.flyoutSearchOpen = !this.flyoutSearchOpen;\n\n // focus first search input\n const element = this.element.querySelector(\".stzh-search input[type='search']\") as HTMLElement;\n\n if (element) {\n window.setTimeout(() => {\n element.focus();\n }, 100);\n }\n this.updatePosition();\n };\n\n private handleBackdropClick = async () => {\n this.flyoutOpen = false;\n this.updatePosition();\n };\n\n private handleBackdropSearchClick = async () => {\n this.flyoutSearchOpen = false;\n this.updatePosition();\n };\n\n private handleMetanavItemClick = (event: MouseEvent, item: StzhHeaderMetanavItem) => {\n this.stzhMetanavItemClick.emit({\n component: \"stzh-header\",\n item,\n originalEvent: event,\n });\n };\n\n private handleMetanavItemChildClick = (event: MouseEvent, itemChild: StzhHeaderMetanavItemChild) => {\n this.stzhMetanavItemChildClick.emit({\n component: \"stzh-header\",\n itemChild: itemChild,\n originalEvent: event,\n });\n };\n\n private handleMetanavItemButtonClick = (event: MouseEvent, itemButton: StzhHeaderMetanavItemButton) => {\n this.stzhMetanavItemButtonClick.emit({\n component: \"stzh-header\",\n itemButton: itemButton,\n originalEvent: event,\n });\n };\n\n private handleMenuItemClick = (event: MouseEvent, item: StzhHeaderMenuItem) => {\n this.flyoutOpen = false;\n this.stzhMenuItemClick.emit({\n component: \"stzh-header\",\n item,\n originalEvent: event,\n });\n };\n\n private handleSearchInput = (event: InputEvent) => {\n this.searchValue = this.searchInput.value;\n\n this.stzhSearchChange.emit({\n component: \"stzh-header\",\n originalEvent: event,\n value: this.searchValue,\n });\n };\n\n private handleSearchChange = (event: InputEvent) => {\n this.searchValue = this.searchInput.value;\n this.stzhSearchChanged.emit({\n component: \"stzh-header\",\n originalEvent: event,\n value: this.searchValue,\n });\n };\n\n private handleLanguageClick = (event: MouseEvent, dropdownOption: StzhDropdownOption) => {\n if (this.languagePreventUrlchange) {\n event.preventDefault();\n }\n this.languageActive = dropdownOption.value;\n\n this.stzhLanguageChange.emit({\n component: \"stzh-header\",\n value: this.languageActive,\n });\n };\n\n private handleFlyoutResize = () => {\n this.resizeMenunavElement();\n };\n\n private handleResize = () => {\n if (this.sticky === \"disabled\") {\n return;\n }\n\n if (this.debounceResize) {\n window.cancelAnimationFrame(this.debounceResize);\n }\n\n this.debounceResize = requestAnimationFrame(() => {\n readTask(() => {\n this.isMedium = media(\"medium\").matches;\n\n this.mainHeight = this.mainElement?.offsetHeight || 0;\n this.metabarHeight = this.metabarElement?.offsetHeight || 0;\n this.logobarHeight = this.logobarElement?.offsetHeight || 0;\n\n this.headerTop = this.element.offsetTop;\n this.headerHeight = this.metabarHeight + this.logobarHeight;\n });\n\n writeTask(() => {\n document.documentElement.style.setProperty(\"--stzh-header-height\", `${this.headerHeight}px`);\n document.documentElement.style.setProperty(\"--stzh-header-main-height\", `${this.mainHeight}px`);\n document.documentElement.style.setProperty(\"--stzh-header-metabar-height\", `${this.metabarHeight}px`);\n document.documentElement.style.setProperty(\"--stzh-header-logobar-height\", `${this.logobarHeight}px`);\n });\n\n this.scrollListener();\n });\n };\n\n async componentWillLoad() {\n this.menuItemsWatcher(this.menuItems);\n this.metanavItemsWatcher(this.metanavItems);\n this.languagesWatcher(this.languages);\n this.searchValueWatcher(this.searchValue);\n\n if (!this.localization) {\n this.localization = await window.stzhComponents.utils.fetchTranslations(this.element, \"header\");\n }\n }\n\n componentDidRender() {\n if (this.renderPromiseResolve) {\n this.renderPromiseResolve();\n }\n\n if (this.flyoutElement && this.flyoutResizeObserver) {\n this.flyoutResizeObserver.observe(this.flyoutElement);\n }\n if (this.flyoutSearchElement && this.flyoutResizeObserver) {\n this.flyoutResizeObserver.observe(this.flyoutSearchElement);\n }\n }\n\n componentDidLoad() {\n this.trap = createFocusTrap(this.element, {\n ...createBaseFocusTrapOptions(),\n initialFocus: false,\n });\n\n this.flyoutResizeObserver = new ResizeObserver(this.handleFlyoutResize);\n if (this.flyoutElement) {\n this.flyoutResizeObserver.observe(this.flyoutElement);\n }\n }\n\n connectedCallback() {\n this._parentElement = this.element.parentElement;\n\n this.resizeObserver = new ResizeObserver(this.handleResize);\n this.resizeObserver.observe(this.element);\n }\n\n disconnectedCallback() {\n this.flyoutOpenWatcher(false);\n this.resizeObserver?.disconnect();\n this.flyoutResizeObserver?.disconnect();\n }\n\n render() {\n const metanavBeforeUsed: boolean = hasSlot(this.element, \"metanav-before\");\n const metanavAfterUsed: boolean = hasSlot(this.element, \"metanav-after\");\n\n const classes = {\n \"stzh-header\": true,\n \"stzh-header--is-flyout-open\": this.flyoutOpen,\n \"stzh-header--is-flyout-search-open\": this.flyoutSearchOpen,\n \"stzh-header--is-search-filled\": this.searchFilled,\n \"stzh-header--is-fixed\": this.fixed,\n \"stzh-header--is-fixed-transition\": this.fixedTransition,\n \"stzh-header--is-sticky\": this.stickyActive,\n \"stzh-header--is-sticky-transition\": this.stickyActive && this.fixedTransition,\n \"stzh-header--hide-logo\": this.hideLogo,\n \"stzh-header--has-empty-metabar-mobile\":\n !metanavBeforeUsed &&\n !metanavAfterUsed &&\n this._metanavItems.filter(item => item.stay || item.stayAndShowInMobileMenu).length === 0 &&\n this._menuItems.length === 0 &&\n (this._languages.length === 0 || (this._languages.length > 0 && !this.languageStay)) &&\n !this.searchAction,\n \"stzh-header--has-empty-metabar\":\n !metanavBeforeUsed &&\n !metanavAfterUsed &&\n this._metanavItems.length === 0 &&\n this._menuItems.length === 0 &&\n this._languages.length === 0 &&\n !this.searchAction,\n [`stzh-header--sticky-${this.sticky}`]: !!this.sticky,\n };\n\n const activeLanguage = this.languageActive || window.stzhComponents.utils.getLocale(this.element);\n const activeLanguageOption =\n this._languages?.find(({ value }) => value === activeLanguage) || this._languages?.[0] || null;\n\n const renderMetanavItemButton = (\n item: StzhHeaderMetanavItem,\n additionalClasses?: { [className: string]: boolean },\n additionalAttributes?: any\n ) => {\n const Element = item.items?.length > 0 || item.itemButton || !item.href ? \"button\" : \"a\";\n\n return (\n <Element\n {...additionalAttributes}\n href={Element === \"a\" && item.href}\n target={Element === \"a\" && item.target}\n class={{\n \"stzh-header__metanav-item\": true,\n \"is-heavy\": item.important,\n \"is-stay\": item.stay || item.stayAndShowInMobileMenu,\n ...(additionalClasses || {}),\n }}\n >\n <span\n class={{\n \"stzh-header__metanav-item-text\": true,\n \"is-vhidden\": item.labelHidden,\n \"has-no-short-label\": !item.labelShort,\n }}\n >\n <span class=\"stzh-header__metanav-item-text-label-long\">{item.label}</span>\n <span class=\"stzh-header__metanav-item-text-label-short\" aria-hidden=\"true\">\n {item.labelShort}\n </span>\n </span>\n {item.icon && (\n <span class=\"stzh-header__metanav-icon-wrapper\">\n {item.icon && (\n <stzh-icon\n class={`stzh-header__metanav-icon ${item.iconOpen ? \"is-close\" : \"\"}`}\n name={item.icon}\n ></stzh-icon>\n )}\n {item.iconOpen && <stzh-icon class=\"stzh-header__metanav-icon is-open\" name={item.iconOpen}></stzh-icon>}\n {(item.badge || item.badgeEmpty) && (\n <stzh-badge\n class=\"stzh-header__metanav-icon-badge\"\n label={item.badge}\n type={typeof item.badgeType === \"undefined\" ? \"error\" : item.badgeType}\n ></stzh-badge>\n )}\n </span>\n )}\n </Element>\n );\n };\n\n return (\n <Host>\n <header class={classes}>\n <div class=\"stzh-header__header\" style={{ paddingTop: `${this.paddingTop}px` }}>\n <div\n class=\"stzh-header__inner\"\n // ref={(el) => (this.innerElement = el as HTMLDivElement)}\n >\n <div class=\"stzh-header__main\" ref={el => (this.mainElement = el as HTMLDivElement)}>\n <div class=\"stzh-header__logobar\" ref={el => (this.logobarElement = el as HTMLDivElement)}>\n <div class=\"stzh-header__logobar-logo\">\n <a\n href={this.href}\n class=\"stzh-header__logo-link\"\n s-object-id={this.logoAnalyticsId || \"Header Logo\"}\n >\n <slot name=\"logo\"></slot>\n </a>\n </div>\n <div class=\"stzh-header__logobar-decoration\"></div>\n </div>\n\n {!this.hideMetabar && (\n <div class=\"stzh-header__metabar\" ref={el => (this.metabarElement = el as HTMLDivElement)}>\n <div class=\"stzh-header__metabar-inner\">\n <slot name=\"menu-before\"></slot>\n\n {this._menuItems.length > 0 && (\n <button\n id={this.menuId}\n class={`stzh-header__burger ${\n this.flyoutOpen && !this.flyoutOpenedByMetanavItem && \"is-open\"\n }`}\n onClick={this.handleBurgerClick}\n >\n <stzh-icon class=\"stzh-header__burger-icon is-close\" name=\"menu\"></stzh-icon>\n <stzh-icon class=\"stzh-header__burger-icon is-open\" name=\"close\"></stzh-icon>\n <div class=\"stzh-header__burger-text\">{this.localization.menuLabel}</div>\n </button>\n )}\n {this.searchAction && !hasSlot(this.element, \"search\") && (\n <form class=\"stzh-header__metabar-search\" action={this.searchAction} role=\"search\">\n <label class=\"stzh-header__search\">\n <input\n id={this.searchId}\n ref={el => (this.searchInput = el as HTMLInputElement)}\n class=\"stzh-header__search-input\"\n type=\"search\"\n name={this.searchFieldName}\n onChange={this.handleSearchChange}\n onInput={this.handleSearchInput}\n ></input>\n <stzh-icon class=\"stzh-header__search-icon\" name=\"search\"></stzh-icon>\n <div class=\"stzh-header__search-text\">{this.localization.searchLabel}</div>\n </label>\n </form>\n )}\n {hasSlot(this.element, \"search\") && (\n <stzh-button\n iconPosition={\"left\"}\n onClick={this.handleSearchButtonClick}\n variant=\"tertiary-plain\"\n size=\"small\"\n >\n <stzh-icon\n slot=\"icon\"\n name=\"search\"\n class={this.flyoutSearchOpen ? \"stzh-header__search-button--is-hidden\" : \"\"}\n ></stzh-icon>\n <stzh-icon\n slot=\"icon\"\n name=\"close\"\n class={this.flyoutSearchOpen ? \"\" : \"stzh-header__search-button--is-hidden\"}\n ></stzh-icon>\n {this.localization.searchLabel}\n </stzh-button>\n )}\n\n <slot name=\"menu-after\"></slot>\n\n <div class=\"stzh-header__metabar-nav\" id={this.metanavId}>\n <slot name=\"metanav-before\"></slot>\n\n {this._metanavItems.map(item =>\n item.items?.length > 0 || item.itemButton ? (\n <Fragment>\n {renderMetanavItemButton(\n item,\n {\n \"is-popover-mobile\": true,\n },\n {\n \"aria-expanded\": item === this.currentOpenMetanavItem ? \"true\" : \"false\",\n \"aria-controls\": item.id,\n onClick: (e: MouseEvent) => {\n if (item === this.currentOpenMetanavItem) {\n this.closeMetanavItem();\n } else {\n this.openMetanavItem(e, item);\n }\n\n this.handleMetanavItemClick(e, item);\n },\n }\n )}\n <stzh-popover\n class={{\n \"stzh-header__metanav-popover\": true,\n }}\n placement=\"bottom-end\"\n distance={20}\n variant={item.variant}\n size={typeof item.size === \"undefined\" ? \"large\" : item.size}\n >\n {renderMetanavItemButton(\n item,\n {\n \"is-popover-desktop\": true,\n },\n {\n onClick: (e: MouseEvent) => {\n this.handleMetanavItemClick(e, item);\n },\n }\n )}\n <div slot=\"content\">\n {item.items?.length > 0 && (\n <stzh-menu>\n {item.items.map(childItem => (\n <stzh-menu-item\n class={{\n \"stzh-header__metanav-menu-item\": true,\n \"is-heavy\":\n typeof item.importantSubmenu === \"undefined\" || item.importantSubmenu,\n }}\n size={typeof item.size === \"undefined\" ? \"large\" : item.size}\n variant={item.variant}\n href={childItem.href}\n target={childItem.target}\n icon={childItem.icon}\n counter={childItem.counter}\n badge={childItem.badge}\n badgeType={childItem.badgeType}\n onClick={(e: MouseEvent) => {this.handleMetanavItemChildClick(e, childItem)}}\n >\n {childItem.label}\n </stzh-menu-item>\n ))}\n </stzh-menu>\n )}\n </div>\n {item.itemButton && (\n <stzh-button\n slot=\"action\"\n size={item.itemButton.size}\n href={item.itemButton.href}\n target={item.itemButton.target}\n onClick={(e: MouseEvent) => {this.handleMetanavItemButtonClick(e, item.itemButton)}}\n >\n {item.itemButton.label}\n </stzh-button>\n )}\n </stzh-popover>\n </Fragment>\n ) : (\n renderMetanavItemButton(\n item,\n {},\n {\n onClick: (e: MouseEvent) => {\n this.handleMetanavItemClick(e, item);\n },\n }\n )\n )\n )}\n\n {this._languages?.length > 0 && (\n <Fragment>\n <h2 id={this.languageId} class=\"stzh-header__vhidden\">\n {this.localization.languageLabel}\n </h2>\n {this._menuItems.length > 0 && this.languageStay && (\n <button\n class={{\n \"stzh-header__metanav-item\": true,\n \"is-popover-mobile\": true,\n \"is-stay\": this.languageStay,\n }}\n aria-expanded={this.currentOpenLanguage ? \"true\" : \"false\"}\n aria-controls=\"submenu-languages\"\n onClick={(e: MouseEvent) => {\n if (this.currentOpenLanguage) {\n this.closeLanguage();\n } else {\n this.openLanguage(e);\n }\n }}\n >\n <span class=\"stzh-header__metanav-item-text\">{activeLanguageOption?.text}</span>\n <stzh-icon class=\"stzh-header__metanav-icon is-close\" name=\"angle-down\"></stzh-icon>\n <stzh-icon class=\"stzh-header__metanav-icon is-open\" name=\"angle-up\"></stzh-icon>\n </button>\n )}\n <stzh-popover\n class=\"stzh-header__metanav-popover is-langnav\"\n placement=\"bottom-end\"\n distance={20}\n >\n <button\n class={{\n \"stzh-header__metanav-item\": true,\n \"is-popover-desktop\": this._menuItems.length > 0,\n \"is-stay\": this.languageStay,\n }}\n >\n <span class=\"stzh-header__metanav-item-text\">{activeLanguageOption?.text}</span>\n <stzh-icon class=\"stzh-header__metanav-icon is-close\" name=\"angle-down\"></stzh-icon>\n <stzh-icon class=\"stzh-header__metanav-icon is-open\" name=\"angle-up\"></stzh-icon>\n </button>\n <div slot=\"content\">\n <stzh-menu>\n {this._languages.map(language => (\n <stzh-menu-item\n class=\"stzh-header__metanav-menu-item\"\n active={activeLanguageOption?.value === language.value}\n href={language.value}\n onClick={event => this.handleLanguageClick(event, language)}\n >\n {language.text}\n </stzh-menu-item>\n ))}\n </stzh-menu>\n </div>\n </stzh-popover>\n </Fragment>\n )}\n\n <slot name=\"metanav-after\"></slot>\n </div>\n </div>\n </div>\n )}\n </div>\n </div>\n </div>\n\n {this._menuItems.length > 0 && (\n <div ref={el => (this.flyoutElement = el as HTMLElement)} class=\"stzh-header__flyout\">\n <div class=\"stzh-header__flyout-backdrop\" onClick={this.handleBackdropClick}></div>\n <div class=\"stzh-header__flyout-scrollbar\"></div>\n <div class=\"stzh-header__menu\">\n <nav\n class=\"stzh-header__menu-nav\"\n ref={el => (this.menunavElement = el as HTMLElement)}\n aria-label={this.localization.navigationLabel}\n >\n <ul class=\"stzh-header__menu-list is-level-1\">\n {this._menuItems.map(item => (\n <li\n class={{\n \"stzh-header__menu-list-item\": true,\n \"is-open\": item === this.currentOpenMenuItem,\n }}\n >\n {item.items?.length > 0 ? (\n <button\n aria-expanded={item === this.currentOpenMenuItem ? \"true\" : \"false\"}\n aria-controls={item.id}\n class=\"stzh-header__menu-item is-level-1 has-items\"\n onClick={\n item === this.currentOpenMenuItem\n ? () => this.closeMenuItem()\n : e => this.openMenuItem(e, item)\n }\n >\n {item.label}\n </button>\n ) : (\n <a\n href={item.href}\n onClick={(e: MouseEvent) => this.handleMenuItemClick(e, item)}\n class=\"stzh-header__menu-item is-level-1\"\n >\n {item.label}\n </a>\n )}\n {item.items?.length > 0 && (\n <ul\n id={item.id}\n class=\"stzh-header__menu-list is-level-2\"\n onFocusout={this.handleMenuListFocusout}\n >\n <li class=\"stzh-header__menu-list-item is-backlink\">\n <button\n class=\"stzh-header__menu-item is-level-2 is-backlink\"\n onClick={() => this.closeMenuItem()}\n >\n <stzh-icon name=\"angle-left\"></stzh-icon>\n <span>{this.menuBackLabel ? this.menuBackLabel : this.localization.menuBackLabel}</span>\n </button>\n </li>\n <li class=\"stzh-header__menu-list-item\">\n <a\n href={item.href}\n onClick={(e: MouseEvent) => this.handleMenuItemClick(e, item)}\n class=\"stzh-header__menu-item is-level-2 is-main\"\n >\n {item.label}\n </a>\n </li>\n {item.items.map(item => (\n <li class=\"stzh-header__menu-list-item\">\n <a\n href={item.href}\n onClick={(e: MouseEvent) => this.handleMenuItemClick(e, item)}\n class=\"stzh-header__menu-item is-level-2\"\n >\n {item.label}\n </a>\n </li>\n ))}\n </ul>\n )}\n </li>\n ))}\n </ul>\n </nav>\n\n {(this._metanavItems?.length > 0 || this._languages?.length > 0) && (\n <div class=\"stzh-header__menu-metanav\">\n <nav class=\"stzh-header__menu-metanav-nav\">\n <ul class=\"stzh-header__menu-metanav-list is-level-1\">\n {this._metanavItems.map(item => (\n <li\n class={{\n \"stzh-header__menu-metanav-list-item\": true,\n \"is-open\": item === this.currentOpenMetanavItem,\n }}\n >\n {item.items?.length > 0 ? (\n <button\n aria-expanded={item === this.currentOpenMetanavItem ? \"true\" : \"false\"}\n aria-controls={item.id}\n class={{\n \"stzh-header__menu-metanav-item is-level-1\": true,\n \"is-hidden\": item.stay && !item.stayAndShowInMobileMenu,\n }}\n onClick={(e: MouseEvent) => {\n if (item === this.currentOpenMetanavItem) {\n this.closeMetanavItem();\n } else {\n this.openMetanavItem(e, item);\n }\n\n this.handleMetanavItemClick(e, item);\n }}\n >\n <span\n class={{\n \"stzh-header__menu-metanav-item-text\": true,\n \"is-vhidden\": item.labelHidden,\n }}\n >\n {item.label}\n </span>\n {item.icon && (\n <stzh-icon class=\"stzh-header__menu-metanav-item-icon\" name={item.icon}></stzh-icon>\n )}\n </button>\n ) : (\n <a\n href={item.href}\n class={{\n \"stzh-header__menu-metanav-item is-level-1\": true,\n \"is-hidden\": item.stay && !item.stayAndShowInMobileMenu,\n }}\n onClick={(e: MouseEvent) => {\n this.handleMetanavItemClick(e, item);\n }}\n >\n <span\n class={{\n \"stzh-header__menu-metanav-item-text\": true,\n \"is-vhidden\": item.labelHidden,\n }}\n >\n {item.label}\n </span>\n {item.icon && (\n <stzh-icon class=\"stzh-header__menu-metanav-item-icon\" name={item.icon}></stzh-icon>\n )}\n </a>\n )}\n {item.items?.length > 0 && (\n <ul id={item.id} class=\"stzh-header__menu-metanav-list is-level-2\">\n <li class=\"stzh-header__menu-metanav-list-item\">\n <div class=\"stzh-header__menu-metanav-item is-level-2 is-title\">\n <span>{item.label}</span>\n <stzh-button\n class=\"stzh-header__menu-metanav-item-icon\"\n variant=\"tertiary\"\n icon=\"close\"\n iconOnly={true}\n label={this.localization.closeMetanavMenuLabel?.replace(\n /\\{itemLabel\\}/gi,\n item.label\n )}\n onClick={() => this.closeMetanavItem()}\n ></stzh-button>\n </div>\n </li>\n {item.items.map(item => (\n <li class=\"stzh-header__menu-metanav-list-item\">\n <a href={item.href} class=\"stzh-header__menu-metanav-item is-level-2\">\n {item.icon && (\n <stzh-icon\n class=\"stzh-header__menu-metanav-item-icon\"\n name={item.icon}\n ></stzh-icon>\n )}\n <span class=\"stzh-header__menu-metanav-item-text\">\n <span>{item.label}</span>\n {item.counter && (\n <span class=\"stzh-header__menu-metanav-item-counter\">({item.counter})</span>\n )}\n </span>\n </a>\n </li>\n ))}\n\n {item.itemButton && (\n <li class=\"stzh-header__menu-metanav-list-item\">\n <div class=\"stzh-header__menu-metanav-item is-level-2 is-action\">\n <stzh-button href={item.itemButton.href} target={item.itemButton.target}>\n {item.itemButton.label}\n </stzh-button>\n </div>\n </li>\n )}\n </ul>\n )}\n </li>\n ))}\n\n {this._languages?.length > 0 && (\n <li\n class={{\n \"stzh-header__menu-metanav-list-item\": true,\n \"is-open\": this.currentOpenLanguage,\n }}\n >\n <button\n aria-expanded={this.currentOpenLanguage ? \"true\" : \"false\"}\n aria-controls=\"submenu-languages\"\n class=\"stzh-header__menu-metanav-item is-level-1\"\n onClick={e => this.openLanguage(e)}\n >\n <span>{activeLanguageOption?.text}</span>\n <stzh-icon class=\"stzh-header__menu-metanav-item-icon\" name=\"angle-down\"></stzh-icon>\n </button>\n <ul id=\"submenu-languages\" class=\"stzh-header__menu-metanav-list is-level-2\">\n <div class=\"stzh-header__menu-metanav-item is-level-2 is-title\">\n <span>{this.localization.dialogLanguageTitle}</span>\n <stzh-button\n class=\"stzh-header__menu-metanav-item-icon\"\n variant=\"tertiary\"\n icon=\"close\"\n iconOnly={true}\n label={\"Sprach-Dialog schliessen\"}\n onClick={() => this.closeLanguage()}\n ></stzh-button>\n </div>\n {this._languages.map(language => (\n <li class=\"stzh-header__menu-metanav-list-item\">\n <a\n class=\"stzh-header__menu-metanav-item is-level-2 is-language\"\n href={language.value}\n onClick={event => this.handleLanguageClick(event, language)}\n >\n <span>{language.text}</span>\n {activeLanguageOption?.value === language.value && (\n <stzh-icon\n class=\"stzh-header__menu-metanav-item-icon\"\n name=\"checkmark\"\n ></stzh-icon>\n )}\n </a>\n </li>\n ))}\n </ul>\n </li>\n )}\n </ul>\n </nav>\n </div>\n )}\n </div>\n </div>\n )}\n\n {hasSlot(this.element, \"search\") && (\n <div ref={el => (this.flyoutSearchElement = el as HTMLElement)} class=\"stzh-header__flyout-search\">\n <div class=\"stzh-header__flyout-backdrop\" onClick={this.handleBackdropSearchClick}></div>\n <div class=\"stzh-header__flyout-scrollbar\"></div>\n <div class=\"stzh-header__flyout-search-main\">\n <slot name=\"search\"></slot>\n </div>\n </div>\n )}\n </header>\n </Host>\n );\n }\n}\n"],"mappings":"0PAAA,MAAMA,EAAgB,y0iCCwCtB,MAAMC,EAAkB,mB,MAiBXC,EAAU,M,obA0TbC,KAAAC,WAAuC,KACvCD,KAAAE,0BAAqC,KA4IrCF,KAAAG,uBAA0BC,IAChC,MAAMC,GAA6BD,EAAME,cAA8BC,SAASH,EAAMI,eAEtF,GAAIR,KAAKS,UAAYJ,EAA0B,CAC7CL,KAAKU,cAAc,M,GAIfV,KAAAW,kBAAoBC,UAC1B,GAAIZ,KAAKE,0BAA2B,CAClCF,KAAKE,0BAA4B,MACjCF,KAAKa,kB,KACA,CACLb,KAAKc,iBAAmB,MACxBd,KAAKe,YAAcf,KAAKe,U,CAI1B,MAAMC,EAAUhB,KAAKgB,QAAQC,cAAc,2BAE3C,GAAID,EAAS,CACXE,OAAOC,YAAW,KAChBH,EAAQI,OAAO,GACd,I,CAGLpB,KAAKqB,gBAAgB,EAGfrB,KAAAsB,wBAA0BV,UA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8BACpEF,EAAA,OAAKE,MAAM,+BAA+BkB,QAAS/N,KAAKwB,4BACxDmL,EAAA,OAAKE,MAAM,kCACXF,EAAA,OAAKE,MAAM,mCACTF,EAAA,QAAMS,KAAK,c"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as t,c as i,h as s,F as r,a as o,g as e}from"./p-c7bfac7a.js";import{a}from"./p-23d404e1.js";import{h}from"./p-d789f265.js";import{S as n}from"./p-fc692303.js";import{c as d}from"./p-9b063923.js";const c=".sc-stzh-datepicker-h{font-family:var(--stzh-font-family-medium);font-weight:var(--stzh-font-weight-medium);font-style:var(--stzh-font-style-medium);color:var(--stzh-base-color);box-sizing:border-box;display:block}[hidden].sc-stzh-datepicker-h{display:none}.sc-stzh-datepicker-h::-moz-selection{color:var(--stzh-selection-color);background-color:var(--stzh-selection-background-color)}.sc-stzh-datepicker-h::selection{color:var(--stzh-selection-color);background-color:var(--stzh-selection-background-color)}.sc-stzh-datepicker-h *.sc-stzh-datepicker,.sc-stzh-datepicker-h *.sc-stzh-datepicker::before,.sc-stzh-datepicker-h *.sc-stzh-datepicker::after{box-sizing:border-box;text-underline-offset:var(--stzh-link-text-underline-offset);text-decoration-thickness:var(--stzh-link-text-decoration-thickness);-webkit-text-decoration-skip-ink:var(--stzh-link-text-decoration-skip-ink);text-decoration-skip-ink:var(--stzh-link-text-decoration-skip-ink)}.sc-stzh-datepicker-h .has-focus.sc-stzh-datepicker{outline:var(--stzh-flyingfocus-color) solid 0.125rem;outline-offset:0.125rem}.sc-stzh-datepicker-h .stzh-fylingfocus-focused.sc-stzh-datepicker{outline-style:none !important}.sc-stzh-datepicker-h .stzh-fylingfocus-focused.sc-stzh-datepicker::-moz-focus-inner{border:0 !important}.sc-stzh-datepicker-h{--calendar-width:var(--stzh-calendar-width);width:100%}[inline].sc-stzh-datepicker-h:not([inline=false]){width:var(--calendar-width)}.stzh-datepicker__popover.sc-stzh-datepicker{--width:auto}.stzh-datepicker__calendar.sc-stzh-datepicker{margin-left:auto;margin-right:auto}.stzh-datepicker__calendar.is-inline.sc-stzh-datepicker{width:100%;margin-left:0px;margin-right:0px}.stzh-datepicker__actions.sc-stzh-datepicker{display:flex;width:var(--calendar-width);margin-left:auto;margin-right:auto}.stzh-datepicker__actions.is-inline.sc-stzh-datepicker{width:100%;margin-left:0px;margin-right:0px}.stzh-datepicker__actions.sc-stzh-datepicker:not(:empty){padding-left:var(--stzh-space-small);padding-right:var(--stzh-space-small)}.stzh-datepicker--has-action.sc-stzh-datepicker .stzh-datepicker__popover.sc-stzh-datepicker{--content-padding:0 0 var(--stzh-space-small) 0}";const l=class{constructor(s){t(this,s);this.stzhChange=i(this,"stzhChange",7);this.handleReset=async()=>{this.value=this.defaultValue};this.onRootFocus=()=>{if(this.input){this.input.focus()}};this.onInputChanged=()=>{const t=this.dateAdapter.parse(this.input.value,"dateInput");if(this.input.value===""||t){const i=this._internalDateAdapter.format(t,"dateInput");if(this.value!==i){this.value=i}else{this.valueWatcher(i)}this.stzhChange.emit({component:"stzh-datepicker",value:this.value,valueAsDate:t})}};this.onCalendarChange=t=>{if(t.detail.component!=="stzh-calendar"){return}this.value=t.detail.valueAsDate&&this._internalDateAdapter.format(t.detail.valueAsDate,"dateInput");this.stzhChange.emit({component:"stzh-datepicker",value:this.value,valueAsDate:t.detail.valueAsDate});if(this.popover){this.popover.hide()}};this.calendarMin="";this.calendarMax="";this.calendarIsDateDisabled=()=>false;this.name="";this.value="";this.calendarValue="";this.inputValue="";this.defaultValue="";this.label="";this.labelHidden=false;this.readonly=false;this.disabled=false;this.description=undefined;this.descriptionLong=undefined;this.error=undefined;this.invalid=false;this.required=false;this.hideOptional=false;this.size="default";this.inline=false;this.dateAdapter=undefined;this.internalDateAdapter="iso";this.localization=undefined;this.buttonLabel=undefined}resetListener(t){if(t.target.contains(this.element)){requestAnimationFrame((()=>{this.handleReset()}))}}createDateFormatters(){if(this.localization){this.dateFormatLong=new Intl.DateTimeFormat(this.localization.$locale,{day:"numeric",month:"long",year:"numeric"})}}valueWatcher(t){if(!this._internalDateAdapter){return}const i=this._internalDateAdapter.parse(t,"dateInput");this.calendarValue=a(i);this.inputValue=this.dateAdapter.format(i,"dateInput");this.updateButtonAccessibleLabel()}dateAdapterWatcher(t){if(!t){this.dateAdapter=window.stzhComponents.utils.createFormatParseAdapter(this.localization.$formats,this.localization.$globals)}}internalDateAdapterWatcher(t){if(t==="iso"||!t){this._internalDateAdapter=window.stzhComponents.utils.createFormatParseAdapter(this.localization.$formatsIso,this.localization.$globals)}else if(t==="legacy"){this._internalDateAdapter=window.stzhComponents.utils.createFormatParseAdapter(this.localization.$formatsLegacy,this.localization.$globals)}else{this._internalDateAdapter=t}}async setDate(t){this.value=this._internalDateAdapter.format(t,"dateInput")}async getPopover(){return this.popover}updateButtonAccessibleLabel(){if(!this.localization){return}try{const t=this._internalDateAdapter.parse(this.value,"dateInput");this.buttonLabel=`${this.label}, ${this.localization.buttonLabel}, ${this.localization.selectedDateMessage} ${this.dateFormatLong.format(t)}`}catch(t){this.buttonLabel=`${this.label}, ${this.localization.buttonLabel}`}}connectedCallback(){this.createDateFormatters()}async componentWillLoad(){if(!this.localization){this.localization=await window.stzhComponents.utils.fetchTranslations(this.element,"datepicker")}this.dateAdapterWatcher(this.dateAdapter);this.internalDateAdapterWatcher(this.internalDateAdapter);this.valueWatcher(this.value);this.defaultValue=this.defaultValue||this.value}render(){const t=h(this.element,"action");const i={"stzh-datepicker":true,"stzh-datepicker--inline":this.inline,"stzh-datepicker--has-action":t};return s(o,{tabindex:this.disabled?null:"-1",onFocus:this.onRootFocus},s("div",{class:i},s("input",{type:"hidden",name:this.name,value:this.value,defaultValue:this.defaultValue}),this.inline&&s(r,null,s("stzh-calendar",{value:this.calendarValue,class:"stzh-datepicker__calendar is-inline",isDateDisabled:this.calendarIsDateDisabled,min:this.calendarMin,max:this.calendarMax,onStzhChange:this.onCalendarChange}),s("div",{class:"stzh-datepicker__actions"},s("slot",{name:"action"}))),!this.inline&&s("stzh-input",{value:this.inputValue,label:this.label,labelHidden:this.labelHidden,ref:t=>this.input=t,noAutocomplete:true,onStzhChanged:this.onInputChanged,readonly:this.readonly,disabled:this.disabled,description:this.description,descriptionLong:this.descriptionLong,error:this.error,invalid:this.invalid,required:this.required,hideOptional:this.hideOptional,size:this.size},s("stzh-popover",{ref:t=>this.popover=t,class:"stzh-datepicker__popover",slot:"button-right",placement:"bottom-end",label:this.label},s("stzh-button",{"icon-only":true,icon:"calendar",size:this.size,disabled:this.disabled,a11yLabel:this.buttonLabel}),s("div",{slot:"content"},s("stzh-calendar",{value:this.calendarValue,class:"stzh-datepicker__calendar is-popover",isDateDisabled:this.calendarIsDateDisabled,min:this.calendarMin,max:this.calendarMax,onStzhChange:this.onCalendarChange}),s("div",{class:"stzh-datepicker__actions"},s("slot",{name:"action"})))))))}get element(){return e(this)}static get watchers(){return{localization:["createDateFormatters"],value:["valueWatcher"],dateAdapter:["dateAdapterWatcher"],internalDateAdapter:["internalDateAdapterWatcher"]}}};l.style=c;const z='.sc-stzh-radio-h{font-family:var(--stzh-font-family-medium);font-weight:var(--stzh-font-weight-medium);font-style:var(--stzh-font-style-medium);color:var(--stzh-base-color);box-sizing:border-box;display:block}[hidden].sc-stzh-radio-h{display:none}.sc-stzh-radio-h::-moz-selection{color:var(--stzh-selection-color);background-color:var(--stzh-selection-background-color)}.sc-stzh-radio-h::selection{color:var(--stzh-selection-color);background-color:var(--stzh-selection-background-color)}.sc-stzh-radio-h *.sc-stzh-radio,.sc-stzh-radio-h *.sc-stzh-radio::before,.sc-stzh-radio-h *.sc-stzh-radio::after{box-sizing:border-box;text-underline-offset:var(--stzh-link-text-underline-offset);text-decoration-thickness:var(--stzh-link-text-decoration-thickness);-webkit-text-decoration-skip-ink:var(--stzh-link-text-decoration-skip-ink);text-decoration-skip-ink:var(--stzh-link-text-decoration-skip-ink)}.sc-stzh-radio-h .has-focus.sc-stzh-radio{outline:var(--stzh-flyingfocus-color) solid 0.125rem;outline-offset:0.125rem}.sc-stzh-radio-h .stzh-fylingfocus-focused.sc-stzh-radio{outline-style:none !important}.sc-stzh-radio-h .stzh-fylingfocus-focused.sc-stzh-radio::-moz-focus-inner{border:0 !important}.sc-stzh-radio-h{display:inline-block}[disabled].sc-stzh-radio-h:not([disabled=false]){--description-color:var(--stzh-color-grey70)}.stzh-radio.sc-stzh-radio{display:grid}.stzh-radio__marker-symbol.sc-stzh-radio{font-family:var(--stzh-font-family-medium);font-weight:var(--stzh-font-weight-medium);font-style:var(--stzh-font-style-medium)}.stzh-radio__marker-text.sc-stzh-radio{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}.stzh-radio__description-wrapper.sc-stzh-radio{display:flex;flex-direction:column-reverse;min-height:var(--description-min-height, var(--stzh-description-min-height, none))}.stzh-radio__error.sc-stzh-radio,.stzh-radio__description.sc-stzh-radio{font-size:var(--stzh-font-nano-font-size);line-height:var(--stzh-font-nano-text-line-height)}.stzh-radio__error.sc-stzh-radio{color:var(--stzh-color-error60)}.stzh-radio__error-list.sc-stzh-radio{list-style:none;margin:0;padding:0}.stzh-radio__description.sc-stzh-radio{display:flex;align-items:flex-start;color:var(--stzh-input-description-color, var(--description-color, var(--stzh-color-coolgrey70)));transition:color var(--stzh-base-transition-animation-speed)}.stzh-radio__description-long.sc-stzh-radio{margin-right:var(--stzh-space-xxsmall);margin-top:0.125rem}@supports (font: -apple-system-body) and (-webkit-appearance: none){.stzh-radio__description-long.sc-stzh-radio{margin-top:0}}.stzh-radio__description-long-popover.sc-stzh-radio{--width:auto;--max-width:27.3125rem}.stzh-radio__description-long-button.sc-stzh-radio{display:flex;justify-content:center;align-items:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;font-family:inherit;padding:0;border:none;background-color:transparent;border-radius:0.5rem;cursor:pointer}.stzh-radio.sc-stzh-radio stzh-icon.stzh-radio__description-long-icon.sc-stzh-radio{--size:var(--stzh-icon-size-xsmall)}.stzh-radio--has-error.sc-stzh-radio .stzh-radio__error.sc-stzh-radio,.stzh-radio--has-description.sc-stzh-radio .stzh-radio__description.sc-stzh-radio{margin-top:var(--stzh-space-xxxsmall)}.stzh-radio__field-wrapper.sc-stzh-radio{font-size:var(--stzh-font-milli-font-size);line-height:var(--stzh-font-milli-text-line-height);letter-spacing:var(--stzh-font-curve---text-letter-spacing);position:relative;display:flex;-webkit-user-select:none;-moz-user-select:none;user-select:none;cursor:pointer}.stzh-radio__input.sc-stzh-radio{position:absolute;top:0;left:0;width:100%;height:100%;margin:0;z-index:-1;opacity:0;pointer-events:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:var(--stzh-form-input-border-radius)}.stzh-radio__mark.sc-stzh-radio{border:0.125rem solid var(--stzh-color-black);background-color:var(--stzh-color-white);width:1.5rem;height:1.5rem;flex-shrink:0;border-radius:50%;display:inline-flex;justify-content:center;align-items:center;transition:border-color var(--stzh-base-transition-animation-speed)}.stzh-radio__mark.sc-stzh-radio::before{content:""}.stzh-radio__check.sc-stzh-radio{background-color:currentColor;color:var(--stzh-color-primary70);width:1rem;height:1rem;border-radius:50%;opacity:0;transition-property:color;transition-duration:var(--stzh-base-transition-animation-speed)}@media (forced-colors: active), (-ms-high-contrast: active){.stzh-radio__check.sc-stzh-radio{background-color:ButtonText}}.stzh-radio__label.sc-stzh-radio{--stzh-base-color:initial;display:inline-block;color:var(--stzh-base-color);transition:color var(--stzh-base-transition-animation-speed);margin-left:var(--stzh-space-small);line-height:1.5rem}.stzh-radio__label.sc-stzh-radio:empty{display:none}.stzh-radio__marker.sc-stzh-radio{font-size:var(--stzh-font-micro-font-size);line-height:var(--stzh-font-micro-text-line-height);margin-left:calc(-0.25em + var(--stzh-space-xsmall))}.stzh-radio.sc-stzh-radio:hover .stzh-radio__label.sc-stzh-radio,.stzh-radio__input.sc-stzh-radio:checked~.stzh-radio__label.sc-stzh-radio{color:var(--stzh-color-primary70)}.stzh-radio__input.sc-stzh-radio:checked:hover~.stzh-radio__label.sc-stzh-radio,.stzh-radio__input.sc-stzh-radio:checked:hover~.stzh-radio__mark.sc-stzh-radio .stzh-radio__check.sc-stzh-radio{color:var(--stzh-color-primary90)}.stzh-radio.sc-stzh-radio:hover .stzh-radio__mark.sc-stzh-radio,.stzh-radio__input.sc-stzh-radio:checked~.stzh-radio__mark.sc-stzh-radio{border-color:var(--stzh-color-primary70)}.stzh-radio__input.sc-stzh-radio:checked:hover~.stzh-radio__mark.sc-stzh-radio{border-color:var(--stzh-color-primary90)}.stzh-radio__input.sc-stzh-radio:checked~.stzh-radio__mark.sc-stzh-radio .stzh-radio__check.sc-stzh-radio{opacity:1}.stzh-radio--is-invalid.sc-stzh-radio .stzh-radio__input.sc-stzh-radio~.stzh-radio__label.sc-stzh-radio,.stzh-radio--is-invalid.sc-stzh-radio .stzh-radio__input.sc-stzh-radio~.stzh-radio__mark.sc-stzh-radio .stzh-radio__check.sc-stzh-radio{color:var(--stzh-color-error60)}.stzh-radio--is-invalid.sc-stzh-radio .stzh-radio__input.sc-stzh-radio~.stzh-radio__mark.sc-stzh-radio{border-color:var(--stzh-color-error60)}.stzh-radio--is-disabled.sc-stzh-radio .stzh-radio__field-wrapper.sc-stzh-radio{cursor:not-allowed}.stzh-radio--is-disabled.sc-stzh-radio .stzh-radio__input.sc-stzh-radio~.stzh-radio__label.sc-stzh-radio{color:var(--stzh-color-grey60)}.stzh-radio--is-disabled.sc-stzh-radio .stzh-radio__input.sc-stzh-radio~.stzh-radio__mark.sc-stzh-radio .stzh-radio__check.sc-stzh-radio{color:var(--stzh-color-grey50)}.stzh-radio--is-disabled.sc-stzh-radio .stzh-radio__input.sc-stzh-radio~.stzh-radio__mark.sc-stzh-radio{border-color:var(--stzh-color-grey50)}.stzh-radio--is-disabled.sc-stzh-radio .stzh-radio__mark.sc-stzh-radio{background-color:var(--stzh-color-grey20)}';let p=0;const u=class{constructor(s){t(this,s);this.stzhChange=i(this,"stzhChange",7);this.stzhFocus=i(this,"stzhFocus",7);this.stzhBlur=i(this,"stzhBlur",7);this.focusedByInput=false;this.handleReset=async()=>{this.checked=this.defaultChecked};this.onInput=t=>{this.checked=this.input.checked;this.stzhChange.emit({component:"stzh-radio",originalEvent:t,value:this.value,checked:this.checked})};this.onRootFocus=()=>{if(!this.focusedByInput){this.input.focus()}this.focusedByInput=false};this.onFocus=t=>{this.focusedByInput=true;const i=new FocusEvent("focus",{view:window,bubbles:false,cancelable:false});this.element.dispatchEvent(i);this.stzhFocus.emit({component:"stzh-radio",originalEvent:t})};this.onBlur=t=>{const i=new FocusEvent("blur",{view:window,bubbles:false,cancelable:false});this.element.dispatchEvent(i);this.stzhBlur.emit({component:"stzh-radio",originalEvent:t})};this.localization=undefined;this.disabled=false;this.name="";this.value="";this.invalid=false;this.required=false;this.hideOptional=false;this.checked=false;this.defaultChecked=undefined;this.label="";this.description=undefined;this.descriptionLong=undefined;this.descriptionLongTitle=undefined;this.error=undefined;this.a11yDescribedby=""}resetListener(t){if(t.target.contains(this.element)){requestAnimationFrame((()=>{this.handleReset()}))}}errorWatcher(t){if(typeof t==="string"){try{this._error=JSON.parse(t)}catch(i){if(t){this._error=[t]}else{this._error=[]}}}else if(t){this._error=t}else{this._error=[]}}async componentWillLoad(){this.inputId=`stzh-radio-${p++}`;this.errorWatcher(this.error);this.defaultChecked=typeof this.defaultChecked==="boolean"?this.defaultChecked:this.checked;if(!this.localization){this.localization=await window.stzhComponents.utils.fetchTranslations(this.element,"radio")}}render(){var t,i;const r=h(this.element,"description")||!!this.description;const e=h(this.element,"description-long")||!!this.descriptionLong;const a=h(this.element,"error")||((t=this._error)===null||t===void 0?void 0:t.length)>0;const d={"stzh-radio":true,"stzh-radio--has-description":r,"stzh-radio--has-description-long":e,"stzh-radio--has-error":a,"stzh-radio--is-required":this.required,"stzh-radio--is-invalid":this.invalid||a,"stzh-radio--is-disabled":this.disabled};return s(o,{"is-invalid":this.invalid||a,tabindex:this.disabled?null:"-1",onFocus:this.onRootFocus},s("div",{class:d},s("label",{class:"stzh-radio__field-wrapper"},s("input",{class:"stzh-radio__input",ref:t=>this.input=t,type:"radio",id:this.inputId,name:this.name,value:this.value,disabled:this.disabled,"aria-describedby":`${this.inputId}-description ${this.a11yDescribedby}`,"aria-required":this.required?"true":"false","aria-invalid":this.invalid?"true":"false",checked:this.checked,defaultChecked:this.defaultChecked,onInput:this.onInput,onFocus:this.onFocus,onBlur:this.onBlur}),s("div",{class:"stzh-radio__mark"},s("div",{class:"stzh-radio__check"})),s("div",{class:"stzh-radio__label"},this.label?this.label:s("slot",null),!this.hideOptional&&s("span",{class:"stzh-radio__marker"},s("span",{class:"stzh-radio__marker-symbol","aria-hidden":"true"},this.required?this.localization.$globals.requiredFieldMarker:this.localization.$globals.optionalFieldMarker),s("span",{class:"stzh-radio__marker-text"},this.required?this.localization.$globals.requiredFieldText:this.localization.$globals.optionalFieldText)))),(((i=this._error)===null||i===void 0?void 0:i.length)>0||this.description)&&s(n,{classPrefix:"stzh-radio",id:`${this.inputId}-description`,error:this._error,description:this.description,descriptionLong:this.descriptionLong,descriptionLongTitle:this.descriptionLongTitle,descriptionLongUsed:e,moreInfoButtonLabel:this.localization.$globals.moreInfoButtonLabel})))}get element(){return e(this)}static get watchers(){return{error:["errorWatcher"]}}};u.style=z;const f=".sc-stzh-radiogroup-h{font-family:var(--stzh-font-family-medium);font-weight:var(--stzh-font-weight-medium);font-style:var(--stzh-font-style-medium);color:var(--stzh-base-color);box-sizing:border-box;display:block}[hidden].sc-stzh-radiogroup-h{display:none}.sc-stzh-radiogroup-h::-moz-selection{color:var(--stzh-selection-color);background-color:var(--stzh-selection-background-color)}.sc-stzh-radiogroup-h::selection{color:var(--stzh-selection-color);background-color:var(--stzh-selection-background-color)}.sc-stzh-radiogroup-h *.sc-stzh-radiogroup,.sc-stzh-radiogroup-h *.sc-stzh-radiogroup::before,.sc-stzh-radiogroup-h *.sc-stzh-radiogroup::after{box-sizing:border-box;text-underline-offset:var(--stzh-link-text-underline-offset);text-decoration-thickness:var(--stzh-link-text-decoration-thickness);-webkit-text-decoration-skip-ink:var(--stzh-link-text-decoration-skip-ink);text-decoration-skip-ink:var(--stzh-link-text-decoration-skip-ink)}.sc-stzh-radiogroup-h .has-focus.sc-stzh-radiogroup{outline:var(--stzh-flyingfocus-color) solid 0.125rem;outline-offset:0.125rem}.sc-stzh-radiogroup-h .stzh-fylingfocus-focused.sc-stzh-radiogroup{outline-style:none !important}.sc-stzh-radiogroup-h .stzh-fylingfocus-focused.sc-stzh-radiogroup::-moz-focus-inner{border:0 !important}[disabled].sc-stzh-radiogroup-h:not([disabled=false]){--description-color:var(--stzh-color-grey70)}.stzh-radiogroup.sc-stzh-radiogroup{margin:0;padding:0;border:none}.stzh-radiogroup__marker-symbol.sc-stzh-radiogroup{font-family:var(--stzh-font-family-medium);font-weight:var(--stzh-font-weight-medium);font-style:var(--stzh-font-style-medium)}.stzh-radiogroup__marker-text.sc-stzh-radiogroup{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}.stzh-radiogroup__description-wrapper.sc-stzh-radiogroup{display:flex;flex-direction:column-reverse;min-height:var(--description-min-height, var(--stzh-description-min-height, none))}.stzh-radiogroup__error.sc-stzh-radiogroup,.stzh-radiogroup__description.sc-stzh-radiogroup{font-size:var(--stzh-font-nano-font-size);line-height:var(--stzh-font-nano-text-line-height)}.stzh-radiogroup__error.sc-stzh-radiogroup{color:var(--stzh-color-error60)}.stzh-radiogroup__error-list.sc-stzh-radiogroup{list-style:none;margin:0;padding:0}.stzh-radiogroup__description.sc-stzh-radiogroup{display:flex;align-items:flex-start;color:var(--stzh-input-description-color, var(--description-color, var(--stzh-color-coolgrey70)));transition:color var(--stzh-base-transition-animation-speed)}.stzh-radiogroup__description-long.sc-stzh-radiogroup{margin-right:var(--stzh-space-xxsmall);margin-top:0.125rem}@supports (font: -apple-system-body) and (-webkit-appearance: none){.stzh-radiogroup__description-long.sc-stzh-radiogroup{margin-top:0}}.stzh-radiogroup__description-long-popover.sc-stzh-radiogroup{--width:auto;--max-width:27.3125rem}.stzh-radiogroup__description-long-button.sc-stzh-radiogroup{display:flex;justify-content:center;align-items:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;font-family:inherit;padding:0;border:none;background-color:transparent;border-radius:0.5rem;cursor:pointer}.stzh-radiogroup.sc-stzh-radiogroup stzh-icon.stzh-radiogroup__description-long-icon.sc-stzh-radiogroup{--size:var(--stzh-icon-size-xsmall)}.stzh-radiogroup--has-error.sc-stzh-radiogroup .stzh-radiogroup__error.sc-stzh-radiogroup,.stzh-radiogroup--has-description.sc-stzh-radiogroup .stzh-radiogroup__description.sc-stzh-radiogroup{margin-top:var(--stzh-space-xxxsmall)}.stzh-radiogroup__fields.sc-stzh-radiogroup{display:flex;align-items:flex-start;flex-direction:column;gap:var(--stzh-space-medium)}.stzh-radiogroup__legend.sc-stzh-radiogroup{font-family:var(--stzh-font-family-heavy);font-weight:var(--stzh-font-weight-heavy);font-style:var(--stzh-font-style-heavy);font-size:var(--stzh-font-micro-font-size);line-height:var(--stzh-font-micro-text-line-height);color:var(--stzh-heading-color);padding:0;margin-bottom:var(--stzh-space-xsmall)}.stzh-radiogroup__marker.sc-stzh-radiogroup{font-size:var(--stzh-font-nano-font-size);line-height:var(--stzh-font-nano-text-line-height);margin-left:calc(-0.25em + var(--stzh-space-xsmall))}.stzh-radiogroup--hide-legend.sc-stzh-radiogroup .stzh-radiogroup__legend.sc-stzh-radiogroup{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}.stzh-radiogroup--direction-horizontal.sc-stzh-radiogroup .stzh-radiogroup__fields.sc-stzh-radiogroup{flex-wrap:wrap;flex-direction:row;row-gap:var(--stzh-space-medium);-moz-column-gap:var(--stzh-space-xxlarge);column-gap:var(--stzh-space-xxlarge)}";const g="stzh-radio, stzh-button[type=radio], stzh-card";let m=0;const _=class{constructor(i){t(this,i);this._preventUpdateProperties=[];this.handleReset=async()=>{this.value=this.defaultValue};this.init=()=>{this.radios=Array.from(this.element.querySelectorAll(g));this.updateRadiosProperty("hide-optional",true);this.updateRadiosProperty("a11y-describedby",`${this.radiogroupId}-description`);this.updateRadiosProperty("invalid",this.invalid||this.errorUsed);this.watchValue(this.value);this.watchName(this.name);this.watchDisabled(this.disabled);this.watchRequired(this.required)};this.localization=undefined;this.disabled=false;this.name=undefined;this.legend=undefined;this.hideLegend=false;this.invalid=false;this.required=false;this.hideOptional=false;this.value="";this.defaultValue="";this.direction="vertical";this.description=undefined;this.descriptionLong=undefined;this.descriptionLongTitle=undefined;this.error=undefined;this.checkedRadio=null;this.preventUpdateProperties=[]}watchName(t){this.updateRadiosProperty("name",t)}watchDisabled(t){this.updateRadiosProperty("disabled",t)}watchRequired(t){this.updateRadiosProperty("required",t)}watchValue(t){this.updateCheckedRadioByValue(t)}errorWatcher(t){if(typeof t==="string"){try{this._error=JSON.parse(t)}catch(i){if(t){this._error=[t]}else{this._error=[]}}}else if(t){this._error=t}else{this._error=[]}}preventUpdatePropertiesWatcher(t){if(typeof t==="string"){this._preventUpdateProperties=JSON.parse(t)}else{this._preventUpdateProperties=t}}resetListener(t){if(t.target.contains(this.element)){requestAnimationFrame((()=>{this.handleReset()}))}}onChange(t){this.value=t.detail.value}updateRadiosProperty(t,i){this.radios.forEach((s=>{if(t==="disabled"){if(!s.disabled){s.disabled=i}}else if(t==="name"||this._preventUpdateProperties.indexOf(t)===-1){s[d(t)]=i}}))}get errorUsed(){var t;return h(this.element,"error")||((t=this._error)===null||t===void 0?void 0:t.length)>0}updateCheckedRadioByValue(t){this.checkedRadio=this.radios.find((i=>i.value===t));if(this.checkedRadio){this.checkedRadio.checked=true}this.uncheckRadios()}uncheckRadios(){this.radios.forEach((t=>{if(!this.checkedRadio||t!==this.checkedRadio){t.checked=false}}))}componentDidLoad(){this.defaultValue=this.defaultValue?this.defaultValue:this.value}async componentWillLoad(){this.radiogroupId=`stzh-radiogroup-${m++}`;this.errorWatcher(this.error);this.preventUpdatePropertiesWatcher(this.preventUpdateProperties);if(!this.localization){this.localization=await window.stzhComponents.utils.fetchTranslations(this.element,"radiogroup")}}componentShouldUpdate(t,i,s){return s!=="checkedRadio"}componentDidRender(){this.init()}connectedCallback(){if(!this.value){this.radios=Array.from(this.element.querySelectorAll(g));const t=this.radios.find((t=>t.checked));if(t){this.value=t.value}}this.observer=new MutationObserver(this.init);this.observer.observe(this.element,{childList:true,subtree:true})}disconnectedCallback(){if(this.observer){this.observer.disconnect()}}render(){var t;const i=h(this.element,"description")||!!this.description;const r=h(this.element,"description-long")||!!this.descriptionLong;const e={"stzh-radiogroup":true,"stzh-radiogroup--has-description":i,"stzh-radiogroup--has-description-long":r,"stzh-radiogroup--has-error":this.errorUsed,"stzh-radiogroup--is-required":this.required,"stzh-radiogroup--is-disabled":this.disabled,"stzh-radiogroup--is-invalid":this.invalid||this.errorUsed,"stzh-radiogroup--hide-legend":this.hideLegend,[`stzh-radiogroup--direction-${this.direction}`]:!!this.direction};return s(o,{"is-invalid":this.invalid||this.errorUsed},s("fieldset",{class:e},this.legend&&s("legend",{class:"stzh-radiogroup__legend"},this.legend,!this.hideOptional&&s("span",{class:"stzh-radiogroup__marker"},s("span",{class:"stzh-radiogroup__marker-symbol","aria-hidden":"true"},this.required?this.localization.$globals.requiredFieldMarker:this.localization.$globals.optionalFieldMarker),s("span",{class:"stzh-radiogroup__marker-text"},this.required?this.localization.$globals.requiredFieldText:this.localization.$globals.optionalFieldText))),s("div",{class:"stzh-radiogroup__fields"},s("slot",null)),(((t=this._error)===null||t===void 0?void 0:t.length)>0||this.description)&&s(n,{classPrefix:"stzh-radiogroup",id:`${this.radiogroupId}-description`,error:this._error,description:this.description,descriptionLong:this.descriptionLong,descriptionLongTitle:this.descriptionLongTitle,descriptionLongUsed:r,moreInfoButtonLabel:this.localization.$globals.moreInfoButtonLabel})))}get element(){return e(this)}static get watchers(){return{name:["watchName"],disabled:["watchDisabled"],required:["watchRequired"],value:["watchValue"],error:["errorWatcher"],preventUpdateProperties:["preventUpdatePropertiesWatcher"]}}};_.style=f;export{l as stzh_datepicker,u as stzh_radio,_ as stzh_radiogroup};
|
|
2
|
-
//# sourceMappingURL=p-b62c870a.entry.js.map
|