scb-wc 0.1.77 → 0.1.78
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/icons.json +178 -178
- package/mvc/components/scb-button/scb-button.js +1 -1
- package/mvc/components/scb-grid/scb-grid-item.js +1 -1
- package/mvc/components/scb-grid/scb-grid.js +1 -1
- package/mvc/components/scb-header/scb-header.js +88 -62
- package/mvc/components/scb-icon-button/scb-icon-button.js +1 -1
- package/mvc/components/scb-skeleton/scb-skeleton.js +1 -1
- package/mvc/scb-logo.svg +20 -20
- package/mvc/scb.svg +13 -13
- package/package.json +2 -2
- package/scb-components/scb-header/scb-header.d.ts +5 -0
- package/scb-header/scb-header.js +82 -20
- package/scb-wc.bundle.js +221 -195
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["../../vendor/md-focus-ring.js","../../vendor/rolldown-runtime.js","../../vendor/vendor.js","../../vendor/attachable-controller.js","../../vendor/vendor-lit.js","../scb-drawer/scb-drawer.js","../../vendor/decorate.js","../scb-divider/scb-divider.js","../../vendor/assertClassBrand.js","../scb-menu/scb-menu.js","../scb-menu/scb-menu-item.js","../../vendor/preload-helper.js","../scb-chevron/scb-chevron.js","../scb-menu/scb-menu-section.js","../scb-menu/scb-sub-menu.js","../scb-search/scb-search.js","../../vendor/icon.js","../../vendor/ripple.js","../scb-
|
|
2
|
-
import{_ as M,b as
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["../../vendor/md-focus-ring.js","../../vendor/rolldown-runtime.js","../../vendor/vendor.js","../../vendor/attachable-controller.js","../../vendor/vendor-lit.js","../scb-drawer/scb-drawer.js","../../vendor/decorate.js","../scb-divider/scb-divider.js","../../vendor/assertClassBrand.js","../scb-menu/scb-menu.js","../scb-menu/scb-menu-item.js","../../vendor/preload-helper.js","../scb-chevron/scb-chevron.js","../scb-menu/scb-menu-section.js","../scb-menu/scb-sub-menu.js","../scb-search/scb-search.js","../../vendor/icon.js","../../vendor/ripple.js","../scb-button/scb-button.js","../../vendor/elevation.js","../../vendor/delegate.js","../../vendor/form-submitter.js","../../vendor/element-internals.js","../../vendor/form-label-activation.js","../scb-icon-button/scb-icon-button.js","../scb-skeleton/scb-skeleton.js","../scb-grid/scb-grid.js","../scb-grid/scb-grid-item.js","../scb-grid/scb-stack.js","../scb-dropdown/scb-dropdown.js","../scb-options-menu/scb-options-menu.js","../scb-options-menu/scb-options-menu-item.js","../scb-options-menu/scb-options-sub-menu.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{_ as M,b as P,g as D,h,m as k,v,y as b}from"../../vendor/vendor.js";import"../../vendor/vendor-lit.js";import{t as c}from"../../vendor/decorate.js";import{t as S}from"../../vendor/preload-helper.js";(function(){try{var m=typeof globalThis<"u"?globalThis:window;if(!m.__scb_ce_guard_installed__){m.__scb_ce_guard_installed__=!0;var e=customElements.define.bind(customElements);customElements.define=function(t,r,s){try{customElements.get(t)||e(t,r,s)}catch(a){var i=String(a||"");if(i.indexOf("already been used")===-1&&i.indexOf("NotSupportedError")===-1)throw a}}}}catch{}})();var C,z,I=0,R=()=>{if(typeof window>"u"||typeof document>"u"||!("customElements"in window)||document.head.querySelector("style[data-scb-header-pre-upgrade]"))return;const m=document.createElement("style");m.setAttribute("data-scb-header-pre-upgrade",""),m.textContent=`
|
|
3
3
|
scb-header:not(:defined),
|
|
4
4
|
scb-header[data-upgrading] {
|
|
5
5
|
display: block;
|
|
@@ -50,23 +50,23 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
50
50
|
);
|
|
51
51
|
}
|
|
52
52
|
}
|
|
53
|
-
`,document.head.appendChild(b);const e=n=>{const u=String(n??"").trim();if(u)return/^\d+$/.test(u)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(u,10)))})`:u},t=n=>{const u=String(n??"").trim();if(!u)return!1;try{const p=JSON.parse(u);return Array.isArray(p)&&p.length>0}catch{return!1}},r=n=>n!=null&&!/^(false|0|off|no)$/i.test(n.trim()),s=n=>{for(const u of Array.from(n.children)){const p=u.tagName.toLowerCase();if(p==="scb-header-tab"||p==="scb-dropdown")return!0}return!1},i=n=>{s(n)||t(n.getAttribute("tabs"))||r(n.getAttribute("reserve-tabs"))||r(n.getAttribute("layout-pending"))?n.setAttribute("data-pre-has-tabs",""):n.removeAttribute("data-pre-has-tabs");const u=e(n.getAttribute("spacing")),p=e(n.getAttribute("spacing-top"))??u,v=e(n.getAttribute("spacing-bottom"))??u;p?n.style.setProperty("--scb-header-spacing-block-start",p):n.style.removeProperty("--scb-header-spacing-block-start"),v?n.style.setProperty("--scb-header-spacing-block-end",v):n.style.removeProperty("--scb-header-spacing-block-end");const _=(n.getAttribute("logo-width")??"").trim();_?n.style.setProperty("--scb-header-pre-logo-w",_):n.style.removeProperty("--scb-header-pre-logo-w");const w=(n.getAttribute("logo-height")??"").trim();w?n.style.setProperty("--scb-header-pre-logo-img-h",w):n.style.removeProperty("--scb-header-pre-logo-img-h");const c=(n.getAttribute("search-height")??"").trim();c?n.style.setProperty("--scb-header-pre-control-size",c):n.style.removeProperty("--scb-header-pre-control-size")};document.querySelectorAll("scb-header").forEach(i);const d=new MutationObserver(n=>{for(const u of n){if(u.type==="attributes"){const p=u.target;p instanceof HTMLElement&&p.tagName.toLowerCase()==="scb-header"&&i(p);continue}if(u.type==="childList"){const p=[...Array.from(u.addedNodes),...Array.from(u.removedNodes)];for(const v of p){if(!(v instanceof HTMLElement))continue;if(v.tagName.toLowerCase()==="scb-header"){i(v);continue}const _=v.closest?.("scb-header");_&&i(_)}}}});d.observe(document.documentElement,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["tabs","spacing","spacing-top","spacing-bottom","logo-width","logo-height","logo-aspect-ratio","logo-alt","logotype-text","search-height","reserve-tabs","layout-pending"]}),customElements.whenDefined("scb-header").then(()=>{d.disconnect()})};L();var z={fromAttribute:b=>b==null?!0:!/^(false|0|off|no)$/i.test(b),toAttribute:b=>String(!!b)},C={fromAttribute:b=>b==null?!1:!/^(false|0|off|no)$/i.test(b),toAttribute:b=>b?"":null},R={fromAttribute:b=>b==="small"||b==="large"?b:"medium",toAttribute:b=>{const e=String(b??"");return e==="small"||e==="large"?e:null}},o=(A=class extends M{constructor(){super(),this.maxWidth="1440px",this.size="medium",this.logoText="",this.logotypeText="",this.logoAlt="",this.logoHref="/",this.logoSrc="",this.logoWidth="",this.logoHeight="",this.logoAspectRatio="",this.logoInvertDm=!1,this.banner=!1,this.tabs=[],this.activeTab=null,this.reserveTabs=!1,this.layoutPending=!1,this.utilityItems=[],this.searchButtonLabel="Sök",this.menuButtonLabel="Meny",this.deferDrawer=!1,this.showDrawer=!0,this.alwaysShowMenuButton=!1,this.showSearch=!0,this.includeUtilityInMenu=!1,this.drawerOverlay=!0,this.searchText="",this._drawerId="main-drawer",this._menuExpanded=!1,this._searchId="header-search",this._drawerReady=!1,this._mobileSearchOpen=!1,this._initialUpgradeComplete=!1,this._slotNavItems=[],this._slotUtils=[],this._slotMenu=[],this._measureScheduled=!1,this._scheduleMeasure=()=>{this.layoutPending||this._measureScheduled||(this._measureScheduled=!0,requestAnimationFrame(()=>{this._measureScheduled=!1,this._measure()}))},this._onWindowResize=()=>{window.innerWidth>=this.BP_SM&&this._mobileSearchOpen&&this._setMobileSearchOpen(!1),this._scheduleMeasure()},this._onMenuSelect=t=>{const r=t.detail;this.dispatchEvent(new CustomEvent("scb-menu-select",{detail:r,bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("scbmenuselect",{detail:r,bubbles:!0,composed:!0}));const s=r?.item,i=typeof r?.href=="string"?r.href:typeof r?.itemHref=="string"?r.itemHref:typeof r?.item_href=="string"?r.item_href:"",a=s?s.getAttribute("item-href")??s.getAttribute("href")??"":"";String(i||a||"").trim()&&this._closeDrawerNow()},this._collapsed=!1,this._unlockAtWidth=0,this._hideLogoText=!1,this._logoTextUnlockAt=0,this._slotWatchers=[],this._harvestPending=!1,this._harvest=(t={})=>{const r=Array.from(this.children),s=[],i=[],a=[];let d=-1,n=!1;const u=c=>({label:c.getAttribute("label")??"",href:c.getAttribute("href")??void 0,icon:c.getAttribute("icon")??void 0}),p=c=>{c.hasAttribute("role")&&c.removeAttribute("role"),c.getAttribute("aria-hidden")!=="true"&&c.setAttribute("aria-hidden","true")};for(const c of r){const x=c.tagName.toLowerCase();if(x==="scb-header-tab"){const f=c.getAttribute("label")??"",g=c.getAttribute("href"),k=g&&g.trim()!==""?g:void 0;(c.hasAttribute("selected")||c.getAttribute("selected")==="true"||c.getAttribute("active")==="true"||c.getAttribute("aria-current")==="page")&&d===-1&&(d=s.length),s.push({kind:"tab",label:f,href:k});continue}if(x==="scb-badge"){const f=c.querySelector("scb-dropdown");if(f){n=!0;const g=f.getAttribute("label")??"";(f.hasAttribute("selected")||f.getAttribute("selected")==="true"||f.getAttribute("active")==="true"||f.getAttribute("aria-current")==="page")&&d===-1&&(d=s.length);const k=`scb-header-tab-${s.length}`;c.getAttribute("slot")!==k&&c.setAttribute("slot",k),f.hasAttribute("slot")&&f.removeAttribute("slot"),f.hasAttribute("as-tab")||f.setAttribute("as-tab",""),s.push({kind:"dropdown",slotName:k,label:g});continue}}if(x==="scb-dropdown"){n=!0;const f=c.getAttribute("label")??"";(c.hasAttribute("selected")||c.getAttribute("selected")==="true"||c.getAttribute("active")==="true"||c.getAttribute("aria-current")==="page")&&d===-1&&(d=s.length);const g=`scb-header-tab-${s.length}`;c.getAttribute("slot")!==g&&c.setAttribute("slot",g),c.hasAttribute("as-tab")||c.setAttribute("as-tab",""),s.push({kind:"dropdown",slotName:g,label:f});continue}if(x==="scb-header-utility"){p(c),i.push({label:c.getAttribute("label")??"",href:c.getAttribute("href")??"#",target:c.getAttribute("target")??void 0});continue}if(x==="scb-header-menu-group"){const f={label:c.getAttribute("label")??"",icon:c.getAttribute("icon")??void 0,children:[]};c.querySelectorAll("scb-header-menu-item").forEach(g=>f.children.push(u(g))),a.push(f);continue}x==="scb-header-menu-item"&&a.push(u(c))}const v=!this._sameNavItems(this._slotNavItems,s),_=!this._sameUtilityItems(this._slotUtils,i),w=!this._sameMenuNodes(this._slotMenu,a);v&&(this._slotNavItems=s),_&&(this._slotUtils=i),w&&(this._slotMenu=a),n&&this._ensureDropdownReady(),!this.hasAttribute("active-tab")&&d>=0&&this.activeTab!==d&&(this.activeTab=d),(t.scheduleMeasure??!0)&&queueMicrotask(()=>{this.updateComplete.then(()=>{this._scheduleMeasure()})})},this._measure=()=>{if(this.layoutPending)return;const t=this._top,r=this._logoGroup;if(!t||!r)return;const s=window.innerWidth,i=t.clientWidth,a=this._overflows(this._util),d=this._tabsOverflows(),n=s<this.BP_MD||a||d;this._collapsed?!n&&i>=this._unlockAtWidth&&this._setCollapsed(!1):n&&(this._unlockAtWidth=i+this._HYST,this._setCollapsed(!0));let u=!1;if(this.showSearch&&s>=this.BP_SM&&s<this.BP_MD&&this._searchWrap){const v=getComputedStyle(this._searchWrap),_=Math.max(this._num(v.minWidth,this._tokenPx("--scb-header-search-min",250)),this._tokenPx("--scb-header-search-min",250)),w=this._num(getComputedStyle(t).gap,this._tokenPx("--spacing-7",24)),c=this.showDrawer&&(this.alwaysShowMenuButton||s<this.BP_MD||this._collapsed)?this._menuBtn?.getBoundingClientRect().width||this._tokenPx("--icon-size-extra-extra-large",48):0;u=r.getBoundingClientRect().width+w+_+w+c+8>i+.5}this._setHideSearch(u);let p=!1;if(this.showDrawer&&(this.alwaysShowMenuButton||s<this.BP_MD||this._collapsed)&&!this._visible(this._util)&&!this._visible(this._searchWrap)){const v=this._num(getComputedStyle(t).gap,this._tokenPx("--spacing-7",24)),_=this._menuBtn?.getBoundingClientRect().width||this._tokenPx("--icon-size-extra-extra-large",48),w=(this._logoGroup?.getBoundingClientRect().width||0)+v+_;this._hideLogoText?p=!(i>=this._logoTextUnlockAt):w>i+.5&&(p=!0,this._logoTextUnlockAt=i+this._HYST)}else p=!1,this._logoTextUnlockAt=0;this._setHideLogoText(p)},this._onGlobalFocusRingKeydown=t=>{t.key==="Tab"&&(this.toggleAttribute("data-keyboard-focus",!0),this._ensureFocusRingReady())},this._onGlobalFocusRingPointerDown=()=>{this.removeAttribute("data-keyboard-focus")},this._onLocalFocusIn=t=>{const r=t.composedPath()[0];r instanceof HTMLElement&&r.matches(":focus-visible")&&this._ensureFocusRingReady()},this._onDrawerOpened=()=>{this._menuExpanded=!0,this._syncMenuBtnAria(),this.dispatchEvent(new CustomEvent("drawer-open",{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("draweropen",{bubbles:!0,composed:!0}))},this._onDrawerClosed=()=>{this._menuExpanded=!1,this._syncMenuBtnAria(),this.dispatchEvent(new CustomEvent("drawer-close",{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("drawerclose",{bubbles:!0,composed:!0}))},this._onMenuClick=async t=>{this.showDrawer&&(this._setMobileSearchOpen(!1),this.dispatchEvent(new CustomEvent("menu-click",{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("menuclick",{bubbles:!0,composed:!0})),!this._drawerReady&&(t.stopPropagation(),await this._ensureDrawerReady(),await this.updateComplete,this._openDrawerNow()))},this._onMobileSearchToggle=()=>{const t=!this._mobileSearchOpen;this._setMobileSearchOpen(t),t&&this.updateComplete.then(()=>{this.renderRoot.querySelector(".mobile-search-panel .header-search-input")?.focus?.()})},this._onTabClick=t=>{const r=t.currentTarget;if(!r)return;const s=r.tagName.toLowerCase()==="a";if(s&&(t.defaultPrevented||t.button!==0||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey))return;const i=r.getAttribute("data-index"),a=i!=null?Number(i):0,d=this._getNavItems()[a];if(d?.kind==="dropdown")return;this.activeTab=a;const n=d?.kind==="tab"?d.href??"":"",u=new CustomEvent("tab-change",{detail:{index:a,href:n},bubbles:!0,composed:!0,cancelable:!0}),p=new CustomEvent("tabchange",{detail:{index:a,href:n},bubbles:!0,composed:!0,cancelable:!0});!(this.dispatchEvent(u)&&this.dispatchEvent(p))&&s&&t.preventDefault()},this._onDropdownTabActivate=t=>{const r=t.detail?.dataIndex,s=typeof r=="number"?r:typeof r=="string"?Number(r):this._readTabIndexFromEvent(t);if(s==null||!Number.isFinite(s))return;const i=this._getNavItems();s<0||s>=i.length||i[s]?.kind==="dropdown"&&(this.activeTab=s,this.dispatchEvent(new CustomEvent("tab-change",{detail:{index:s,href:""},bubbles:!0,composed:!0,cancelable:!0})),this.dispatchEvent(new CustomEvent("tabchange",{detail:{index:s,href:""},bubbles:!0,composed:!0,cancelable:!0})))},this._onTabsKeydown=t=>{const r=t.key;if(r!=="ArrowLeft"&&r!=="ArrowRight"&&r!=="Home"&&r!=="End")return;const s=this._getNavItems();if(!s.length)return;const i=this._readTabIndexFromEvent(t);if(i==null)return;let a=Math.max(0,Math.min(s.length-1,i));r==="ArrowRight"?a=(a+1)%s.length:r==="ArrowLeft"?a=(a-1+s.length)%s.length:r==="Home"?a=0:r==="End"&&(a=s.length-1),t.preventDefault(),this._focusTabAtIndex(a)},this._onNativeSearchInput=t=>{const r=t.currentTarget;this._emitSearchInput(r?.value??"")},this._onNativeSearchSubmit=t=>{t.preventDefault();const r=t.currentTarget?.querySelector(".header-search-input");this._emitSearchChange(r?.value??"")},this._onSearchClear=()=>{this.searchText="",this.dispatchEvent(new CustomEvent("search-text-change",{detail:{value:""},bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("searchtextchange",{detail:{value:""},bubbles:!0,composed:!0}))},this._onNativeSearchClear=t=>{t.preventDefault(),this._onSearchClear(),this.updateComplete.then(()=>{const r=t.currentTarget?.closest("form")?.querySelector(".header-search-input");r&&(r.value=""),r?.focus()})};const e=++I;this._drawerId=`scb-header-drawer-${e}`,this._searchId=`scb-header-search-${e}`}requestLayout(){this.layoutPending||(this.setAttribute("data-layout-settling",""),this.updateComplete.then(()=>{this.isConnected&&(this._measure(),this.removeAttribute("data-layout-settling"))}))}get _HYST(){return this._tokenPx("--spacing-11",64)}get BP_SM(){return this._tokenPx("--bp-sm",T.BP_SM_DEFAULT)}get BP_MD(){return this._tokenPx("--bp-md",T.BP_MD_DEFAULT)}_scheduleHarvest(){this._harvestPending||(this._harvestPending=!0,queueMicrotask(()=>{this._harvestPending=!1,this._harvest()}))}get _top(){return this.renderRoot.querySelector(".top-row")}get _util(){return this.renderRoot.querySelector(".utility")}get _logoGroup(){return this.renderRoot.querySelector(".logo-wrap")||this.renderRoot.querySelector(".logo-group")}get _searchWrap(){return this.renderRoot.querySelector(".search")}get _menuBtn(){return this.renderRoot.querySelector(".menu-trigger")}get _tabsNav(){return this.renderRoot.querySelector(".tabs-nav")}_attachSlotObservers(){this._slotMo?.disconnect(),this._slotWatchers.forEach(i=>i.disconnect()),this._slotWatchers=[];const e=["label","href","icon","target","selected","aria-current","active","role"],t=i=>{const a=new MutationObserver(d=>{this._scheduleHarvest()});this._slotWatchers.push(a),a.observe(i,{attributes:!0,attributeFilter:e})},r=()=>{this._slotWatchers.forEach(a=>a.disconnect()),this._slotWatchers=[];const i=Array.from(this.children);for(const a of i){const d=a.tagName.toLowerCase();if((d==="scb-header-tab"||d==="scb-dropdown"||d==="scb-header-utility"||d==="scb-header-menu-item"||d==="scb-header-menu-group"||d==="scb-badge")&&t(a),d==="scb-badge"){const n=a,u=new MutationObserver(v=>{r(),this._scheduleHarvest()});this._slotWatchers.push(u),u.observe(n,{childList:!0});const p=n.querySelector("scb-dropdown");p&&t(p);continue}if(d==="scb-header-menu-group"){const n=a,u=new MutationObserver(p=>{r(),this._scheduleHarvest()});this._slotWatchers.push(u),u.observe(n,{childList:!0,subtree:!0}),n.querySelectorAll("scb-header-menu-item").forEach(p=>t(p))}}},s=new MutationObserver(i=>{let a=!1;for(const d of i)if(d.type==="childList"){a=!0;break}a&&r(),this._scheduleHarvest()});this._slotMo=s,s.observe(this,{childList:!0}),r()}_sameNavItems(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r+=1){const s=e[r],i=t[r];if(!s||!i||s.kind!==i.kind||s.label!==i.label)return!1;if(s.kind==="tab"&&i.kind==="tab"){if((s.href??"")!==(i.href??""))return!1}else if(s.kind==="dropdown"&&i.kind==="dropdown"&&s.slotName!==i.slotName)return!1}return!0}_sameUtilityItems(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r+=1){const s=e[r],i=t[r];if(!s||!i||s.label!==i.label||s.href!==i.href||(s.target??"")!==(i.target??""))return!1}return!0}_sameMenuNodes(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r+=1){const s=e[r],i=t[r];if(!s||!i||s.label!==i.label||(s.href??"")!==(i.href??"")||(s.icon??"")!==(i.icon??"")||!this._sameMenuNodes(s.children??[],i.children??[]))return!1}return!0}_setCollapsed(e){this._collapsed!==e&&(this._collapsed=e,e?this.setAttribute("data-collapsed",""):this.removeAttribute("data-collapsed"))}_setHideSearch(e){e?this.setAttribute("data-hide-search",""):this.removeAttribute("data-hide-search")}_setHideLogoText(e){this._hideLogoText!==e&&(this._hideLogoText=e,e?this.setAttribute("data-hide-logo-text",""):this.removeAttribute("data-hide-logo-text"))}_setMobileSearchOpen(e){this._mobileSearchOpen!==e&&(this._mobileSearchOpen=e,this.toggleAttribute("data-mobile-search-open",e))}_num(e,t){const r=Number.parseFloat(String(e??"").trim());return Number.isFinite(r)?r:t}_tokenPx(e,t){const r=getComputedStyle(this);return this._num(r.getPropertyValue(e),t)}_visible(e){return e?getComputedStyle(e).display!=="none":!1}_overflows(e){return!e||!this._visible(e)?!1:e.scrollWidth>e.clientWidth+1}_tabsOverflows(){const e=this._tabsNav;if(!e||!this._visible(e))return!1;const t=Array.from(e.querySelectorAll(".tab-wrap"));if(t.length===0)return!1;const r=e.getBoundingClientRect();let s=r.left;for(const i of t){const a=i.getBoundingClientRect();a.width<=0||a.right>s&&(s=a.right)}return s-r.left>r.width+1}connectedCallback(){super.connectedCallback(),window.addEventListener("keydown",this._onGlobalFocusRingKeydown,!0),window.addEventListener("pointerdown",this._onGlobalFocusRingPointerDown,!0),this._initialUpgradeComplete||this.setAttribute("data-upgrading",""),this._harvest({scheduleMeasure:!1}),this._attachSlotObservers()}_finishInitialUpgrade(){this._initialUpgradeComplete||(this._initialUpgradeComplete=!0,requestAnimationFrame(()=>{this.isConnected&&(this._measure(),this.removeAttribute("data-upgrading"))}))}firstUpdated(){this._syncLandmarkAttributes(),this.renderRoot.addEventListener("focusin",this._onLocalFocusIn),this.showDrawer&&!this.deferDrawer&&this._ensureDrawerReady(),this.updateComplete.then(()=>{this._harvest({scheduleMeasure:!1}),this._attachSlotObservers(),this._syncDropdownTabs(),this._finishInitialUpgrade()});const e=this._top;e&&(this._ro=new ResizeObserver(()=>this._scheduleMeasure()),this._ro.observe(e)),window.addEventListener("resize",this._onWindowResize,{passive:!0})}updated(e){e.has("searchMax")&&this.style.setProperty("--scb-header-search-max",this.searchMax??"380px"),e.has("searchMin")&&this.style.setProperty("--scb-header-search-min",this.searchMin??"250px"),e.has("searchHeight")&&(this.searchHeight&&this.searchHeight.trim()?this.style.setProperty("--scb-search-height",this.searchHeight.trim()):this.style.removeProperty("--scb-search-height")),(e.has("logoWidth")||e.has("logoHeight")||e.has("logoAspectRatio"))&&this._applyLogoSizing(),(e.has("spacing")||e.has("spacingTop")||e.has("spacingBottom"))&&this._applySpacing(),(e.has("banner")||e.has("bannerLabel"))&&this._syncLandmarkAttributes(),(e.has("utilityItems")||e.has("tabs")||e.has("logoText")||e.has("logotypeText")||e.has("logoSrc")||e.has("logoWidth")||e.has("logoHeight")||e.has("logoAspectRatio")||e.has("activeTab")||e.has("_slotNavItems")||e.has("_slotUtils")||e.has("_slotMenu")||e.has("showDrawer")||e.has("alwaysShowMenuButton")||e.has("showSearch")||e.has("layoutPending")||e.has("searchMax")||e.has("searchMin")||e.has("size"))&&this.updateComplete.then(()=>{this._scheduleMeasure()}),(e.has("showDrawer")||e.has("deferDrawer"))&&this.showDrawer&&!this.deferDrawer&&this._ensureDrawerReady(),e.has("showSearch")&&!this.showSearch&&this._setMobileSearchOpen(!1),e.has("layoutPending")&&!this.layoutPending&&this.requestLayout(),(e.has("activeTab")||e.has("_slotNavItems")||e.has("tabs")||e.has("size"))&&this.updateComplete.then(()=>{this._syncDropdownTabs()})}disconnectedCallback(){this._ro?.disconnect(),this._slotMo?.disconnect(),this._slotWatchers.forEach(e=>e.disconnect()),this._slotWatchers=[],this.renderRoot.removeEventListener("focusin",this._onLocalFocusIn),window.removeEventListener("keydown",this._onGlobalFocusRingKeydown,!0),window.removeEventListener("pointerdown",this._onGlobalFocusRingPointerDown,!0),window.removeEventListener("resize",this._onWindowResize),super.disconnectedCallback()}_mapSpacingToken(e){if(!e)return;const t=String(e).trim();if(t)return/^\d+$/.test(t)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(t,10)))})`:t}_applySpacing(){const e=this._mapSpacingToken(this.spacing),t=this._mapSpacingToken(this.spacingTop)??e,r=this._mapSpacingToken(this.spacingBottom)??e;t?this.style.setProperty("--scb-header-spacing-block-start",t):this.style.removeProperty("--scb-header-spacing-block-start"),r?this.style.setProperty("--scb-header-spacing-block-end",r):this.style.removeProperty("--scb-header-spacing-block-end")}_syncLandmarkAttributes(){const e=this.renderRoot.querySelector(".header-landmark");if(!e)return;if(!this.banner){e.removeAttribute("role"),e.removeAttribute("aria-label");return}e.setAttribute("role","banner");const t=(this.bannerLabel??"").trim();t?e.setAttribute("aria-label",t):e.removeAttribute("aria-label")}_applyLogoSizing(){const e=(this.logoWidth??"").trim(),t=(this.logoHeight??"").trim(),r=(this.logoAspectRatio??"").trim();e?this.style.setProperty("--scb-header-logo-img-w",e):this.style.removeProperty("--scb-header-logo-img-w"),t?this.style.setProperty("--scb-header-logo-img-h",t):e?this.style.setProperty("--scb-header-logo-img-h","auto"):this.style.removeProperty("--scb-header-logo-img-h"),r?this.style.setProperty("--scb-header-logo-img-aspect-ratio",r):this.style.removeProperty("--scb-header-logo-img-aspect-ratio")}_closeDrawerNow(){const e=this.renderRoot.querySelector(`#${this._drawerId}`);e&&(e.open=!1)}_openDrawerNow(){const e=this.renderRoot.querySelector(`#${this._drawerId}`);e&&(e.open=!0)}_ensureFocusRingReady(){customElements.get("md-focus-ring")||(this._focusRingImportPromise??(this._focusRingImportPromise=$(()=>import("../../vendor/md-focus-ring.js").then(e=>e.t).then(()=>{}),__vite__mapDeps([0,1,2,3,4]),import.meta.url)),this._focusRingImportPromise)}async _ensureDrawerReady(){this._drawerReady||(this._drawerImportPromise??(this._drawerImportPromise=Promise.all([$(()=>import("../scb-drawer/scb-drawer.js"),__vite__mapDeps([5,6,2,4,7,8]),import.meta.url),$(()=>import("../scb-menu/scb-menu.js"),__vite__mapDeps([9,8,6,2,4,7,10,11,12,13,14]),import.meta.url),$(()=>import("../scb-search/scb-search.js"),__vite__mapDeps([15,6,11,2,0,1,3,4,16,17]),import.meta.url)]).then(()=>{})),await this._drawerImportPromise,this._drawerReady=!0)}async _ensureDropdownReady(){customElements.get("scb-dropdown")||(this._dropdownImportPromise??(this._dropdownImportPromise=$(()=>import("../scb-dropdown/scb-dropdown.js").then(()=>{}),__vite__mapDeps([18,6,2,19,8,20,4,0,1,3,16,21,22,23,24,17,12,25,26,7,27]),import.meta.url)),await this._dropdownImportPromise)}_syncMenuBtnAria(){this.renderRoot.querySelectorAll(".menu-trigger").forEach(e=>{e.setAttribute("aria-expanded",String(this._menuExpanded))})}_getNavItems(){return this._slotNavItems.length?this._slotNavItems:(this.tabs??[]).map(e=>({kind:"tab",...e}))}_getDropdownForSlot(e){const t=this.querySelector(`[slot="${e}"]`);return t?t.tagName.toLowerCase()==="scb-dropdown"?t:t.querySelector("scb-dropdown"):null}_syncDropdownTabs(){this._getNavItems().forEach((e,t)=>{if(e.kind!=="dropdown")return;const r=this._getDropdownForSlot(e.slotName);if(!r)return;const s=String(t);r.getAttribute("data-index")!==s&&r.setAttribute("data-index",s),r.hasAttribute("as-tab")||r.setAttribute("as-tab","");const i=this.size,a=r;a?.size!==i&&(a.size=i),t===this.activeTab?r.getAttribute("aria-current")!=="page"&&r.setAttribute("aria-current","page"):r.hasAttribute("aria-current")&&r.removeAttribute("aria-current")})}_readTabIndexFromEvent(e){const t=e.composedPath?e.composedPath():[];for(const r of t){if(!(r instanceof HTMLElement))continue;const s=r.getAttribute("data-index");if(s==null)continue;const i=Number(s);if(Number.isFinite(i))return i}return null}_focusTabAtIndex(e){const t=this._getNavItems()[e];if(t){if(t.kind==="dropdown"){this._getDropdownForSlot(t.slotName)?.focus?.();return}this.renderRoot.querySelector(`.tab-link[data-index="${e}"]`)?.focus?.()}}_renderMenuNodes(e){return!e||e.length===0?m``:m`${e.map(t=>this._renderMenuNode(t))}`}_renderMenuNode(e){const t=Array.isArray(e.children)&&e.children.length>0,r=(e.href??"").trim(),s=(e.icon??"").trim(),i=t?m`
|
|
53
|
+
`,document.head.appendChild(m);const e=n=>{const u=String(n??"").trim();if(u)return/^\d+$/.test(u)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(u,10)))})`:u},t=n=>{const u=String(n??"").trim();if(!u)return!1;try{const p=JSON.parse(u);return Array.isArray(p)&&p.length>0}catch{return!1}},r=n=>n!=null&&!/^(false|0|off|no)$/i.test(n.trim()),s=n=>{for(const u of Array.from(n.children)){const p=u.tagName.toLowerCase();if(p==="scb-header-tab"||p==="scb-dropdown")return!0}return!1},i=n=>{s(n)||t(n.getAttribute("tabs"))||r(n.getAttribute("reserve-tabs"))||r(n.getAttribute("layout-pending"))?n.setAttribute("data-pre-has-tabs",""):n.removeAttribute("data-pre-has-tabs");const u=e(n.getAttribute("spacing")),p=e(n.getAttribute("spacing-top"))??u,y=e(n.getAttribute("spacing-bottom"))??u;p?n.style.setProperty("--scb-header-spacing-block-start",p):n.style.removeProperty("--scb-header-spacing-block-start"),y?n.style.setProperty("--scb-header-spacing-block-end",y):n.style.removeProperty("--scb-header-spacing-block-end");const _=(n.getAttribute("logo-width")??"").trim();_?n.style.setProperty("--scb-header-pre-logo-w",_):n.style.removeProperty("--scb-header-pre-logo-w");const x=(n.getAttribute("logo-height")??"").trim();x?n.style.setProperty("--scb-header-pre-logo-img-h",x):n.style.removeProperty("--scb-header-pre-logo-img-h");const l=(n.getAttribute("search-height")??"").trim();l?n.style.setProperty("--scb-header-pre-control-size",l):n.style.removeProperty("--scb-header-pre-control-size")};document.querySelectorAll("scb-header").forEach(i);const d=new MutationObserver(n=>{for(const u of n){if(u.type==="attributes"){const p=u.target;p instanceof HTMLElement&&p.tagName.toLowerCase()==="scb-header"&&i(p);continue}if(u.type==="childList"){const p=[...Array.from(u.addedNodes),...Array.from(u.removedNodes)];for(const y of p){if(!(y instanceof HTMLElement))continue;if(y.tagName.toLowerCase()==="scb-header"){i(y);continue}const _=y.closest?.("scb-header");_&&i(_)}}}});d.observe(document.documentElement,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["tabs","spacing","spacing-top","spacing-bottom","logo-width","logo-height","logo-aspect-ratio","logo-alt","logotype-text","search-height","reserve-tabs","layout-pending"]}),customElements.whenDefined("scb-header").then(()=>{d.disconnect()})};R();var E={fromAttribute:m=>m==null?!0:!/^(false|0|off|no)$/i.test(m),toAttribute:m=>String(!!m)},$={fromAttribute:m=>m==null?!1:!/^(false|0|off|no)$/i.test(m),toAttribute:m=>m?"":null},L={fromAttribute:m=>m==="small"||m==="large"?m:"medium",toAttribute:m=>{const e=String(m??"");return e==="small"||e==="large"?e:null}},o=(C=class extends M{constructor(){super(),this.maxWidth="1440px",this.size="medium",this.logoText="",this.logotypeText="",this.logoAlt="",this.logoHref="/",this.logoSrc="",this.logoWidth="",this.logoHeight="",this.logoAspectRatio="",this.logoInvertDm=!1,this.banner=!1,this.tabs=[],this.activeTab=null,this.reserveTabs=!1,this.layoutPending=!1,this.utilityItems=[],this.searchButtonLabel="Sök",this.menuButtonLabel="Meny",this.deferDrawer=!1,this.showDrawer=!0,this.alwaysShowMenuButton=!1,this.showSearch=!0,this.includeUtilityInMenu=!1,this.drawerOverlay=!0,this.searchText="",this._drawerId="main-drawer",this._menuExpanded=!1,this._searchId="header-search",this._drawerReady=!1,this._mobileSearchOpen=!1,this._initialUpgradeComplete=!1,this._slotNavItems=[],this._slotUtils=[],this._slotMenu=[],this._measureScheduled=!1,this._scheduleMeasure=()=>{this.layoutPending||this._measureScheduled||(this._measureScheduled=!0,requestAnimationFrame(()=>{this._measureScheduled=!1,this._measure()}))},this._onWindowResize=()=>{window.innerWidth>=this.BP_SM&&this._mobileSearchOpen&&this._setMobileSearchOpen(!1),this._scheduleMeasure()},this._onMenuSelect=t=>{const r=t.detail;this.dispatchEvent(new CustomEvent("scb-menu-select",{detail:r,bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("scbmenuselect",{detail:r,bubbles:!0,composed:!0}));const s=r?.item,i=typeof r?.href=="string"?r.href:typeof r?.itemHref=="string"?r.itemHref:typeof r?.item_href=="string"?r.item_href:"",a=s?s.getAttribute("item-href")??s.getAttribute("href")??"":"";String(i||a||"").trim()&&this._closeDrawerNow()},this._collapsed=!1,this._unlockAtWidth=0,this._hideLogoText=!1,this._logoTextUnlockAt=0,this._slotWatchers=[],this._harvestPending=!1,this._harvest=(t={})=>{const r=Array.from(this.children),s=[],i=[],a=[];let d=-1,n=!1;const u=l=>({label:l.getAttribute("label")??"",href:l.getAttribute("href")??void 0,icon:l.getAttribute("icon")??void 0}),p=l=>{l.hasAttribute("role")&&l.removeAttribute("role"),l.hasAttribute("hidden")||l.setAttribute("hidden",""),l.getAttribute("aria-hidden")!=="true"&&l.setAttribute("aria-hidden","true")};for(const l of r){const A=l.tagName.toLowerCase();if(this._isDrawerCloseNode(l)){this._syncDrawerCloseNode(l);continue}if(A==="scb-header-tab"){p(l);const g=l.getAttribute("label")??"",w=l.getAttribute("href"),f=w&&w.trim()!==""?w:void 0;(l.hasAttribute("selected")||l.getAttribute("selected")==="true"||l.getAttribute("active")==="true"||l.getAttribute("aria-current")==="page")&&d===-1&&(d=s.length),s.push({kind:"tab",label:g,href:f});continue}if(A==="scb-badge"){const g=l.querySelector("scb-dropdown");if(g){n=!0;const w=g.getAttribute("label")??"";(g.hasAttribute("selected")||g.getAttribute("selected")==="true"||g.getAttribute("active")==="true"||g.getAttribute("aria-current")==="page")&&d===-1&&(d=s.length);const f=`scb-header-tab-${s.length}`;l.getAttribute("slot")!==f&&l.setAttribute("slot",f),g.hasAttribute("slot")&&g.removeAttribute("slot"),g.hasAttribute("as-tab")||g.setAttribute("as-tab",""),s.push({kind:"dropdown",slotName:f,label:w});continue}}if(A==="scb-dropdown"){n=!0;const g=l.getAttribute("label")??"";(l.hasAttribute("selected")||l.getAttribute("selected")==="true"||l.getAttribute("active")==="true"||l.getAttribute("aria-current")==="page")&&d===-1&&(d=s.length);const w=`scb-header-tab-${s.length}`;l.getAttribute("slot")!==w&&l.setAttribute("slot",w),l.hasAttribute("as-tab")||l.setAttribute("as-tab",""),s.push({kind:"dropdown",slotName:w,label:g});continue}if(A==="scb-header-utility"){p(l),i.push({label:l.getAttribute("label")??"",href:l.getAttribute("href")??"#",target:l.getAttribute("target")??void 0});continue}if(A==="scb-header-menu-group"){p(l);const g={label:l.getAttribute("label")??"",icon:l.getAttribute("icon")??void 0,children:[]};l.querySelectorAll("scb-header-menu-item").forEach(w=>g.children.push(u(w))),a.push(g);continue}if(A==="scb-header-menu-item"){p(l),a.push(u(l));continue}l.hasAttribute("slot")||p(l)}const y=!this._sameNavItems(this._slotNavItems,s),_=!this._sameUtilityItems(this._slotUtils,i),x=!this._sameMenuNodes(this._slotMenu,a);y&&(this._slotNavItems=s),_&&(this._slotUtils=i),x&&(this._slotMenu=a),n&&this._ensureDropdownReady(),!this.hasAttribute("active-tab")&&d>=0&&this.activeTab!==d&&(this.activeTab=d),(t.scheduleMeasure??!0)&&queueMicrotask(()=>{this.updateComplete.then(()=>{this._scheduleMeasure()})})},this._measure=()=>{if(this.layoutPending)return;const t=this._top,r=this._logoGroup;if(!t||!r)return;const s=window.innerWidth,i=t.clientWidth,a=this._overflows(this._util),d=this._tabsOverflows(),n=s<this.BP_MD||a||d;this._collapsed?!n&&i>=this._unlockAtWidth&&this._setCollapsed(!1):n&&(this._unlockAtWidth=i+this._HYST,this._setCollapsed(!0));let u=!1;if(this.showSearch&&s>=this.BP_SM&&s<this.BP_MD&&this._searchWrap){const y=getComputedStyle(this._searchWrap),_=Math.max(this._num(y.minWidth,this._tokenPx("--scb-header-search-min",250)),this._tokenPx("--scb-header-search-min",250)),x=this._num(getComputedStyle(t).gap,this._tokenPx("--spacing-7",24)),l=this.showDrawer&&(this.alwaysShowMenuButton||s<this.BP_MD||this._collapsed)?this._menuBtn?.getBoundingClientRect().width||this._tokenPx("--icon-size-extra-extra-large",48):0;u=r.getBoundingClientRect().width+x+_+x+l+8>i+.5}this._setHideSearch(u);let p=!1;if(this.showDrawer&&(this.alwaysShowMenuButton||s<this.BP_MD||this._collapsed)&&!this._visible(this._util)&&!this._visible(this._searchWrap)){const y=this._num(getComputedStyle(t).gap,this._tokenPx("--spacing-7",24)),_=this._menuBtn?.getBoundingClientRect().width||this._tokenPx("--icon-size-extra-extra-large",48),x=(this._logoGroup?.getBoundingClientRect().width||0)+y+_;this._hideLogoText?p=!(i>=this._logoTextUnlockAt):x>i+.5&&(p=!0,this._logoTextUnlockAt=i+this._HYST)}else p=!1,this._logoTextUnlockAt=0;this._setHideLogoText(p)},this._onGlobalFocusRingKeydown=t=>{t.key==="Tab"&&(this.toggleAttribute("data-keyboard-focus",!0),this._ensureFocusRingReady())},this._onGlobalFocusRingPointerDown=()=>{this.removeAttribute("data-keyboard-focus")},this._onLocalFocusIn=t=>{const r=t.composedPath()[0];r instanceof HTMLElement&&r.matches(":focus-visible")&&this._ensureFocusRingReady()},this._onDrawerOpened=()=>{this._menuExpanded=!0,this._syncMenuBtnAria(),this.dispatchEvent(new CustomEvent("drawer-open",{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("draweropen",{bubbles:!0,composed:!0}))},this._onDrawerClosed=()=>{this._menuExpanded=!1,this._syncMenuBtnAria(),this.dispatchEvent(new CustomEvent("drawer-close",{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("drawerclose",{bubbles:!0,composed:!0}))},this._onMenuClick=async t=>{this.showDrawer&&(this._setMobileSearchOpen(!1),this.dispatchEvent(new CustomEvent("menu-click",{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("menuclick",{bubbles:!0,composed:!0})),!this._drawerReady&&(t.stopPropagation(),await this._ensureDrawerReady(),await this.updateComplete,this._openDrawerNow()))},this._onMobileSearchToggle=()=>{const t=!this._mobileSearchOpen;this._setMobileSearchOpen(t),t&&this.updateComplete.then(()=>{this.renderRoot.querySelector(".mobile-search-panel .header-search-input")?.focus?.()})},this._onTabClick=t=>{const r=t.currentTarget;if(!r)return;const s=r.tagName.toLowerCase()==="a";if(s&&(t.defaultPrevented||t.button!==0||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey))return;const i=r.getAttribute("data-index"),a=i!=null?Number(i):0,d=this._getNavItems()[a];if(d?.kind==="dropdown")return;this.activeTab=a;const n=d?.kind==="tab"?d.href??"":"",u=new CustomEvent("tab-change",{detail:{index:a,href:n},bubbles:!0,composed:!0,cancelable:!0}),p=new CustomEvent("tabchange",{detail:{index:a,href:n},bubbles:!0,composed:!0,cancelable:!0});!(this.dispatchEvent(u)&&this.dispatchEvent(p))&&s&&t.preventDefault()},this._onDropdownTabActivate=t=>{const r=t.detail?.dataIndex,s=typeof r=="number"?r:typeof r=="string"?Number(r):this._readTabIndexFromEvent(t);if(s==null||!Number.isFinite(s))return;const i=this._getNavItems();s<0||s>=i.length||i[s]?.kind==="dropdown"&&(this.activeTab=s,this.dispatchEvent(new CustomEvent("tab-change",{detail:{index:s,href:""},bubbles:!0,composed:!0,cancelable:!0})),this.dispatchEvent(new CustomEvent("tabchange",{detail:{index:s,href:""},bubbles:!0,composed:!0,cancelable:!0})))},this._onTabsKeydown=t=>{const r=t.key;if(r!=="ArrowLeft"&&r!=="ArrowRight"&&r!=="Home"&&r!=="End")return;const s=this._getNavItems();if(!s.length)return;const i=this._readTabIndexFromEvent(t);if(i==null)return;let a=Math.max(0,Math.min(s.length-1,i));r==="ArrowRight"?a=(a+1)%s.length:r==="ArrowLeft"?a=(a-1+s.length)%s.length:r==="Home"?a=0:r==="End"&&(a=s.length-1),t.preventDefault(),this._focusTabAtIndex(a)},this._onNativeSearchInput=t=>{const r=t.currentTarget;this._emitSearchInput(r?.value??"")},this._onNativeSearchSubmit=t=>{t.preventDefault();const r=t.currentTarget?.querySelector(".header-search-input");this._emitSearchChange(r?.value??"")},this._onSearchClear=()=>{this.searchText="",this.dispatchEvent(new CustomEvent("search-text-change",{detail:{value:""},bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("searchtextchange",{detail:{value:""},bubbles:!0,composed:!0}))},this._onNativeSearchClear=t=>{t.preventDefault(),this._onSearchClear(),this.updateComplete.then(()=>{const r=t.currentTarget?.closest("form")?.querySelector(".header-search-input");r&&(r.value=""),r?.focus()})};const e=++I;this._drawerId=`scb-header-drawer-${e}`,this._searchId=`scb-header-search-${e}`}requestLayout(){this.layoutPending||(this.setAttribute("data-layout-settling",""),this.updateComplete.then(()=>{this.isConnected&&(this._measure(),this.removeAttribute("data-layout-settling"))}))}get _HYST(){return this._tokenPx("--spacing-11",64)}get BP_SM(){return this._tokenPx("--bp-sm",z.BP_SM_DEFAULT)}get BP_MD(){return this._tokenPx("--bp-md",z.BP_MD_DEFAULT)}_scheduleHarvest(){this._harvestPending||(this._harvestPending=!0,queueMicrotask(()=>{this._harvestPending=!1,this._harvest()}))}get _top(){return this.renderRoot.querySelector(".top-row")}get _util(){return this.renderRoot.querySelector(".utility")}get _logoGroup(){return this.renderRoot.querySelector(".logo-wrap")||this.renderRoot.querySelector(".logo-group")}get _searchWrap(){return this.renderRoot.querySelector(".search")}get _menuBtn(){return this.renderRoot.querySelector(".menu-trigger")}get _tabsNav(){return this.renderRoot.querySelector(".tabs-nav")}_attachSlotObservers(){this._slotMo?.disconnect(),this._slotWatchers.forEach(i=>i.disconnect()),this._slotWatchers=[];const e=["label","href","icon","target","selected","aria-current","active","role"],t=i=>{const a=new MutationObserver(d=>{this._scheduleHarvest()});this._slotWatchers.push(a),a.observe(i,{attributes:!0,attributeFilter:e})},r=()=>{this._slotWatchers.forEach(a=>a.disconnect()),this._slotWatchers=[];const i=Array.from(this.children);for(const a of i){const d=a.tagName.toLowerCase();if((d==="scb-header-tab"||d==="scb-dropdown"||d==="scb-header-utility"||d==="scb-header-menu-item"||d==="scb-header-menu-group"||d==="scb-badge")&&t(a),d==="scb-badge"){const n=a,u=new MutationObserver(y=>{r(),this._scheduleHarvest()});this._slotWatchers.push(u),u.observe(n,{childList:!0});const p=n.querySelector("scb-dropdown");p&&t(p);continue}if(d==="scb-header-menu-group"){const n=a,u=new MutationObserver(p=>{r(),this._scheduleHarvest()});this._slotWatchers.push(u),u.observe(n,{childList:!0,subtree:!0}),n.querySelectorAll("scb-header-menu-item").forEach(p=>t(p))}}},s=new MutationObserver(i=>{let a=!1;for(const d of i)if(d.type==="childList"){a=!0;break}a&&r(),this._scheduleHarvest()});this._slotMo=s,s.observe(this,{childList:!0}),r()}_sameNavItems(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r+=1){const s=e[r],i=t[r];if(!s||!i||s.kind!==i.kind||s.label!==i.label)return!1;if(s.kind==="tab"&&i.kind==="tab"){if((s.href??"")!==(i.href??""))return!1}else if(s.kind==="dropdown"&&i.kind==="dropdown"&&s.slotName!==i.slotName)return!1}return!0}_sameUtilityItems(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r+=1){const s=e[r],i=t[r];if(!s||!i||s.label!==i.label||s.href!==i.href||(s.target??"")!==(i.target??""))return!1}return!0}_sameMenuNodes(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r+=1){const s=e[r],i=t[r];if(!s||!i||s.label!==i.label||(s.href??"")!==(i.href??"")||(s.icon??"")!==(i.icon??"")||!this._sameMenuNodes(s.children??[],i.children??[]))return!1}return!0}_isDrawerCloseNode(e){const t=e.tagName.toLowerCase(),r=e.getAttribute("slot");if(r==="drawer-close")return!0;if(r||t!=="scb-icon-button")return!1;const s=(e.getAttribute("icon")??"").trim().toLowerCase(),i=(e.getAttribute("aria-label")??"").trim().toLowerCase();return s==="close"||i.includes("stäng")||i.includes("close")}_syncDrawerCloseNode(e){e.getAttribute("slot")!=="drawer-close"&&e.setAttribute("slot","drawer-close"),e.setAttribute("data-drawer-close",this._drawerId),e.setAttribute("aria-controls",this._drawerId),this._drawerReady?(e.removeAttribute("hidden"),e.removeAttribute("aria-hidden")):(e.hasAttribute("hidden")||e.setAttribute("hidden",""),e.getAttribute("aria-hidden")!=="true"&&e.setAttribute("aria-hidden","true"))}_syncDrawerCloseNodes(){for(const e of Array.from(this.children))this._isDrawerCloseNode(e)&&this._syncDrawerCloseNode(e)}_setCollapsed(e){this._collapsed!==e&&(this._collapsed=e,e?this.setAttribute("data-collapsed",""):this.removeAttribute("data-collapsed"))}_setHideSearch(e){e?this.setAttribute("data-hide-search",""):this.removeAttribute("data-hide-search")}_setHideLogoText(e){this._hideLogoText!==e&&(this._hideLogoText=e,e?this.setAttribute("data-hide-logo-text",""):this.removeAttribute("data-hide-logo-text"))}_setMobileSearchOpen(e){this._mobileSearchOpen!==e&&(this._mobileSearchOpen=e,this.toggleAttribute("data-mobile-search-open",e))}_num(e,t){const r=Number.parseFloat(String(e??"").trim());return Number.isFinite(r)?r:t}_tokenPx(e,t){const r=getComputedStyle(this);return this._num(r.getPropertyValue(e),t)}_visible(e){return e?getComputedStyle(e).display!=="none":!1}_overflows(e){return!e||!this._visible(e)?!1:e.scrollWidth>e.clientWidth+1}_tabsOverflows(){const e=this._tabsNav;if(!e||!this._visible(e))return!1;const t=Array.from(e.querySelectorAll(".tab-wrap"));if(t.length===0)return!1;const r=e.getBoundingClientRect();let s=r.left;for(const i of t){const a=i.getBoundingClientRect();a.width<=0||a.right>s&&(s=a.right)}return s-r.left>r.width+1}connectedCallback(){super.connectedCallback(),window.addEventListener("keydown",this._onGlobalFocusRingKeydown,!0),window.addEventListener("pointerdown",this._onGlobalFocusRingPointerDown,!0),this._initialUpgradeComplete||this.setAttribute("data-upgrading",""),this._harvest({scheduleMeasure:!1}),this._attachSlotObservers()}_finishInitialUpgrade(){this._initialUpgradeComplete||(this._initialUpgradeComplete=!0,requestAnimationFrame(()=>{this.isConnected&&(this._measure(),this.removeAttribute("data-upgrading"))}))}firstUpdated(){this._syncLandmarkAttributes(),this.renderRoot.addEventListener("focusin",this._onLocalFocusIn),this.showDrawer&&!this.deferDrawer&&this._ensureDrawerReady(),this.updateComplete.then(()=>{this._harvest({scheduleMeasure:!1}),this._attachSlotObservers(),this._syncDropdownTabs(),this._finishInitialUpgrade()});const e=this._top;e&&(this._ro=new ResizeObserver(()=>this._scheduleMeasure()),this._ro.observe(e)),window.addEventListener("resize",this._onWindowResize,{passive:!0})}updated(e){e.has("searchMax")&&this.style.setProperty("--scb-header-search-max",this.searchMax??"380px"),e.has("searchMin")&&this.style.setProperty("--scb-header-search-min",this.searchMin??"250px"),e.has("searchHeight")&&(this.searchHeight&&this.searchHeight.trim()?this.style.setProperty("--scb-search-height",this.searchHeight.trim()):this.style.removeProperty("--scb-search-height")),(e.has("logoWidth")||e.has("logoHeight")||e.has("logoAspectRatio"))&&this._applyLogoSizing(),(e.has("spacing")||e.has("spacingTop")||e.has("spacingBottom"))&&this._applySpacing(),(e.has("banner")||e.has("bannerLabel"))&&this._syncLandmarkAttributes(),(e.has("utilityItems")||e.has("tabs")||e.has("logoText")||e.has("logotypeText")||e.has("logoSrc")||e.has("logoWidth")||e.has("logoHeight")||e.has("logoAspectRatio")||e.has("activeTab")||e.has("_slotNavItems")||e.has("_slotUtils")||e.has("_slotMenu")||e.has("showDrawer")||e.has("alwaysShowMenuButton")||e.has("showSearch")||e.has("layoutPending")||e.has("searchMax")||e.has("searchMin")||e.has("size"))&&this.updateComplete.then(()=>{this._scheduleMeasure()}),(e.has("showDrawer")||e.has("deferDrawer"))&&this.showDrawer&&!this.deferDrawer&&this._ensureDrawerReady(),e.has("showSearch")&&!this.showSearch&&this._setMobileSearchOpen(!1),e.has("layoutPending")&&!this.layoutPending&&this.requestLayout(),(e.has("activeTab")||e.has("_slotNavItems")||e.has("tabs")||e.has("size"))&&this.updateComplete.then(()=>{this._syncDropdownTabs()})}disconnectedCallback(){this._ro?.disconnect(),this._slotMo?.disconnect(),this._slotWatchers.forEach(e=>e.disconnect()),this._slotWatchers=[],this.renderRoot.removeEventListener("focusin",this._onLocalFocusIn),window.removeEventListener("keydown",this._onGlobalFocusRingKeydown,!0),window.removeEventListener("pointerdown",this._onGlobalFocusRingPointerDown,!0),window.removeEventListener("resize",this._onWindowResize),super.disconnectedCallback()}_mapSpacingToken(e){if(!e)return;const t=String(e).trim();if(t)return/^\d+$/.test(t)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(t,10)))})`:t}_applySpacing(){const e=this._mapSpacingToken(this.spacing),t=this._mapSpacingToken(this.spacingTop)??e,r=this._mapSpacingToken(this.spacingBottom)??e;t?this.style.setProperty("--scb-header-spacing-block-start",t):this.style.removeProperty("--scb-header-spacing-block-start"),r?this.style.setProperty("--scb-header-spacing-block-end",r):this.style.removeProperty("--scb-header-spacing-block-end")}_syncLandmarkAttributes(){const e=this.renderRoot.querySelector(".header-landmark");if(!e)return;if(!this.banner){e.removeAttribute("role"),e.removeAttribute("aria-label");return}e.setAttribute("role","banner");const t=(this.bannerLabel??"").trim();t?e.setAttribute("aria-label",t):e.removeAttribute("aria-label")}_applyLogoSizing(){const e=(this.logoWidth??"").trim(),t=(this.logoHeight??"").trim(),r=(this.logoAspectRatio??"").trim();e?this.style.setProperty("--scb-header-logo-img-w",e):this.style.removeProperty("--scb-header-logo-img-w"),t?this.style.setProperty("--scb-header-logo-img-h",t):e?this.style.setProperty("--scb-header-logo-img-h","auto"):this.style.removeProperty("--scb-header-logo-img-h"),r?this.style.setProperty("--scb-header-logo-img-aspect-ratio",r):this.style.removeProperty("--scb-header-logo-img-aspect-ratio")}_closeDrawerNow(){const e=this.renderRoot.querySelector(`#${this._drawerId}`);e&&(e.open=!1)}_openDrawerNow(){const e=this.renderRoot.querySelector(`#${this._drawerId}`);e&&(e.open=!0)}_ensureFocusRingReady(){customElements.get("md-focus-ring")||(this._focusRingImportPromise??(this._focusRingImportPromise=S(()=>import("../../vendor/md-focus-ring.js").then(e=>e.t).then(()=>{}),__vite__mapDeps([0,1,2,3,4]),import.meta.url)),this._focusRingImportPromise)}async _ensureDrawerReady(){this._drawerReady||(this._drawerImportPromise??(this._drawerImportPromise=Promise.all([S(()=>import("../scb-drawer/scb-drawer.js"),__vite__mapDeps([5,6,2,4,7,8]),import.meta.url),S(()=>import("../scb-menu/scb-menu.js"),__vite__mapDeps([9,8,6,2,4,7,10,11,12,13,14]),import.meta.url),S(()=>import("../scb-search/scb-search.js"),__vite__mapDeps([15,6,11,2,0,1,3,4,16,17]),import.meta.url),this._ensureDrawerSlotComponentsReady()]).then(()=>{})),await this._drawerImportPromise,this._drawerReady=!0,this._syncDrawerCloseNodes())}_drawerSlotContains(e){return[...this.querySelectorAll('[slot="drawer-menu"], [slot="drawer-close"]')].some(t=>t.matches(e)||!!t.querySelector(e))}async _ensureDrawerSlotComponentsReady(){this.querySelector('[slot="drawer-menu"], [slot="drawer-close"]')&&await Promise.all([this._drawerSlotContains("scb-button")?S(()=>import("../scb-button/scb-button.js"),__vite__mapDeps([18,8,6,2,19,4,0,1,3,16,20,21,22,23,17]),import.meta.url):Promise.resolve(),this._drawerSlotContains("scb-icon-button")?S(()=>import("../scb-icon-button/scb-icon-button.js"),__vite__mapDeps([24,8,6,11,2,16,1,4]),import.meta.url):Promise.resolve(),this._drawerSlotContains("scb-skeleton")?S(()=>import("../scb-skeleton/scb-skeleton.js"),__vite__mapDeps([25,6,2,4]),import.meta.url):Promise.resolve(),this._drawerSlotContains("scb-grid")?S(()=>import("../scb-grid/scb-grid.js"),__vite__mapDeps([26,8,6,2,4,27,28]),import.meta.url):Promise.resolve(),this._drawerSlotContains("scb-grid-item")?S(()=>import("../scb-grid/scb-grid-item.js"),__vite__mapDeps([27,8,6,2,4]),import.meta.url):Promise.resolve()])}async _ensureDropdownReady(){customElements.get("scb-dropdown")||(this._dropdownImportPromise??(this._dropdownImportPromise=S(()=>import("../scb-dropdown/scb-dropdown.js").then(()=>{}),__vite__mapDeps([29,6,2,18,8,19,4,0,1,3,16,20,21,22,23,17,12,30,31,7,32]),import.meta.url)),await this._dropdownImportPromise)}_syncMenuBtnAria(){this.renderRoot.querySelectorAll(".menu-trigger").forEach(e=>{e.setAttribute("aria-expanded",String(this._menuExpanded))})}_getNavItems(){return this._slotNavItems.length?this._slotNavItems:(this.tabs??[]).map(e=>({kind:"tab",...e}))}_getDropdownForSlot(e){const t=this.querySelector(`[slot="${e}"]`);return t?t.tagName.toLowerCase()==="scb-dropdown"?t:t.querySelector("scb-dropdown"):null}_syncDropdownTabs(){this._getNavItems().forEach((e,t)=>{if(e.kind!=="dropdown")return;const r=this._getDropdownForSlot(e.slotName);if(!r)return;const s=String(t);r.getAttribute("data-index")!==s&&r.setAttribute("data-index",s),r.hasAttribute("as-tab")||r.setAttribute("as-tab","");const i=this.size,a=r;a?.size!==i&&(a.size=i),t===this.activeTab?r.getAttribute("aria-current")!=="page"&&r.setAttribute("aria-current","page"):r.hasAttribute("aria-current")&&r.removeAttribute("aria-current")})}_readTabIndexFromEvent(e){const t=e.composedPath?e.composedPath():[];for(const r of t){if(!(r instanceof HTMLElement))continue;const s=r.getAttribute("data-index");if(s==null)continue;const i=Number(s);if(Number.isFinite(i))return i}return null}_focusTabAtIndex(e){const t=this._getNavItems()[e];if(t){if(t.kind==="dropdown"){this._getDropdownForSlot(t.slotName)?.focus?.();return}this.renderRoot.querySelector(`.tab-link[data-index="${e}"]`)?.focus?.()}}_renderMenuNodes(e){return!e||e.length===0?b``:b`${e.map(t=>this._renderMenuNode(t))}`}_renderMenuNode(e){const t=Array.isArray(e.children)&&e.children.length>0,r=(e.href??"").trim(),s=(e.icon??"").trim(),i=t?b`
|
|
54
54
|
<scb-sub-menu label=${e.label}>
|
|
55
55
|
${e.children.map(a=>this._renderMenuNode(a))}
|
|
56
56
|
</scb-sub-menu>
|
|
57
|
-
`:
|
|
57
|
+
`:v;return s&&r?b`
|
|
58
58
|
<scb-menu-item label=${e.label} ?selected=${!1} leading-icon=${s} item-href=${r}>
|
|
59
59
|
${i}
|
|
60
60
|
</scb-menu-item>
|
|
61
|
-
`:s?
|
|
61
|
+
`:s?b`
|
|
62
62
|
<scb-menu-item label=${e.label} ?selected=${!1} leading-icon=${s}>
|
|
63
63
|
${i}
|
|
64
64
|
</scb-menu-item>
|
|
65
|
-
`:r?
|
|
65
|
+
`:r?b`
|
|
66
66
|
<scb-menu-item label=${e.label} ?selected=${!1} item-href=${r}>
|
|
67
67
|
${i}
|
|
68
68
|
</scb-menu-item>
|
|
69
|
-
`:
|
|
69
|
+
`:b`<scb-menu-item label=${e.label} ?selected=${!1}>${i}</scb-menu-item>`}_syncFlags(e,t){this.toggleAttribute("data-no-utility",e),this.toggleAttribute("data-no-search",t)}_emitSearchInput(e){this.searchText=e,this.dispatchEvent(new CustomEvent("search-input",{detail:{value:this.searchText},bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("searchinput",{detail:{value:this.searchText},bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("search-text-change",{detail:{value:this.searchText},bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("searchtextchange",{detail:{value:this.searchText},bubbles:!0,composed:!0}))}_emitSearchChange(e,t){this.searchText=e,this.dispatchEvent(new CustomEvent("search-change",{detail:{value:this.searchText,active:t},bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("searchchange",{detail:{value:this.searchText,active:t},bubbles:!0,composed:!0}))}_renderMenuButton(e="",t=!1){const r=e?`menu-trigger ${e}`:"menu-trigger",s=(this.menuButtonLabel??"").trim()||"Meny",i=this._menuExpanded?"true":"false";return t?b`
|
|
70
70
|
<button
|
|
71
71
|
type="button"
|
|
72
72
|
class=${`${r} header-icon-button`}
|
|
@@ -80,7 +80,7 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
80
80
|
<span class="header-symbol" aria-hidden="true">menu</span>
|
|
81
81
|
<md-focus-ring aria-hidden="true"></md-focus-ring>
|
|
82
82
|
</button>
|
|
83
|
-
`:
|
|
83
|
+
`:b`
|
|
84
84
|
<button
|
|
85
85
|
type="button"
|
|
86
86
|
class=${`${r} header-text-button`}
|
|
@@ -94,7 +94,7 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
94
94
|
<span class="header-symbol" aria-hidden="true">menu</span>
|
|
95
95
|
<md-focus-ring aria-hidden="true"></md-focus-ring>
|
|
96
96
|
</button>
|
|
97
|
-
`}_renderSearchForm(e,t,r=!0,s=!1){const i=this.searchPlaceholder??"",a=i.trim()||e,d=(this.searchText??"").length>0;return
|
|
97
|
+
`}_renderSearchForm(e,t,r=!0,s=!1){const i=this.searchPlaceholder??"",a=i.trim()||e,d=(this.searchText??"").length>0;return b`
|
|
98
98
|
<form
|
|
99
99
|
class=${s?"header-search header-search--mobile":"header-search"}
|
|
100
100
|
style=${t}
|
|
@@ -105,11 +105,11 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
105
105
|
<span class="header-search-icon header-symbol" aria-hidden="true">search</span>
|
|
106
106
|
<span class="sr-only">${a}</span>
|
|
107
107
|
<input
|
|
108
|
-
id=${s?
|
|
108
|
+
id=${s?v:this._searchId}
|
|
109
109
|
class="header-search-input"
|
|
110
110
|
type="search"
|
|
111
111
|
.value=${this.searchText}
|
|
112
|
-
placeholder=${i||
|
|
112
|
+
placeholder=${i||v}
|
|
113
113
|
aria-label=${a}
|
|
114
114
|
@input=${this._onNativeSearchInput}
|
|
115
115
|
/>
|
|
@@ -125,14 +125,14 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
125
125
|
<md-focus-ring aria-hidden="true"></md-focus-ring>
|
|
126
126
|
</button>
|
|
127
127
|
</label>
|
|
128
|
-
${r?
|
|
128
|
+
${r?b`
|
|
129
129
|
<button type="submit" class="search-submit">
|
|
130
130
|
${e}
|
|
131
131
|
<md-focus-ring aria-hidden="true"></md-focus-ring>
|
|
132
132
|
</button>
|
|
133
|
-
`:
|
|
133
|
+
`:v}
|
|
134
134
|
</form>
|
|
135
|
-
`}render(){const e=this._getNavItems(),t=this._slotUtils.length?this._slotUtils:this.utilityItems,r=this._slotMenu.length?this._slotMenu:this.menuData??[],s=this.logoText||this.logotypeText,i=this.logoAlt||s||"Gå till startsidan",a=this.querySelector('[slot="drawer-menu"]')!==null;this._syncFlags(t.length===0,!this.showSearch);const
|
|
135
|
+
`}render(){const e=this._getNavItems(),t=this._slotUtils.length?this._slotUtils:this.utilityItems,r=this._slotMenu.length?this._slotMenu:this.menuData??[],s=this.logoText||this.logotypeText,i=this.logoAlt||s||"Gå till startsidan",a=this.querySelector('[slot="drawer-menu"]')!==null,d=this.querySelector('[slot="drawer-close"]')!==null;this._syncFlags(t.length===0,!this.showSearch);const n=this.searchHeight&&this.searchHeight.trim()?`--scb-search-height:${this.searchHeight.trim()}`:"",u=e.length>0||this.reserveTabs||this.layoutPending,p=(this.reserveTabs||this.layoutPending)&&(this.layoutPending||e.length===0),y=this.showDrawer&&(!this.deferDrawer||this._drawerReady),_=typeof window<"u"&&window.innerWidth>=this.BP_MD,x=this.showDrawer&&(_?this.alwaysShowMenuButton||this._collapsed:!0),l=x&&!_,A=x&&_,g=(this.searchButtonLabel??"").trim()||"Sök",w=this.showSearch&&!this._mobileSearchOpen;return b`
|
|
136
136
|
<slot
|
|
137
137
|
id="data-slot"
|
|
138
138
|
@slotchange=${()=>{this._harvest(),this._attachSlotObservers()}}
|
|
@@ -160,42 +160,42 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
160
160
|
|
|
161
161
|
<div class="actions">
|
|
162
162
|
<nav class="utility" aria-label="Funktionslänkar">
|
|
163
|
-
${t.map(
|
|
163
|
+
${t.map(f=>b`
|
|
164
164
|
<a
|
|
165
165
|
class="utility-link"
|
|
166
|
-
href=${
|
|
167
|
-
target=${
|
|
168
|
-
rel=${
|
|
166
|
+
href=${f.href}
|
|
167
|
+
target=${f.target||v}
|
|
168
|
+
rel=${f.target==="_blank"?"noopener noreferrer":v}
|
|
169
169
|
>
|
|
170
|
-
${
|
|
170
|
+
${f.label}
|
|
171
171
|
<md-focus-ring aria-hidden="true"></md-focus-ring>
|
|
172
172
|
</a>
|
|
173
173
|
`)}
|
|
174
174
|
</nav>
|
|
175
175
|
|
|
176
|
-
${this.showSearch?
|
|
177
|
-
<div class="search" style=${
|
|
178
|
-
${this._renderSearchForm(
|
|
176
|
+
${this.showSearch?b`
|
|
177
|
+
<div class="search" style=${n}>
|
|
178
|
+
${this._renderSearchForm(g,n)}
|
|
179
179
|
</div>
|
|
180
|
-
`:
|
|
181
|
-
${
|
|
180
|
+
`:v}
|
|
181
|
+
${w?b`
|
|
182
182
|
<button
|
|
183
183
|
type="button"
|
|
184
184
|
class="mobile-search-trigger header-icon-button"
|
|
185
|
-
aria-label=${
|
|
186
|
-
title=${
|
|
185
|
+
aria-label=${g}
|
|
186
|
+
title=${g}
|
|
187
187
|
@click=${this._onMobileSearchToggle}
|
|
188
188
|
>
|
|
189
189
|
<span class="header-symbol" aria-hidden="true">search</span>
|
|
190
190
|
<md-focus-ring aria-hidden="true"></md-focus-ring>
|
|
191
191
|
</button>
|
|
192
|
-
`:
|
|
193
|
-
${
|
|
192
|
+
`:v}
|
|
193
|
+
${l?this._renderMenuButton("",!0):v}
|
|
194
194
|
</div>
|
|
195
195
|
|
|
196
|
-
${this.showSearch&&this._mobileSearchOpen?
|
|
197
|
-
<div class="mobile-search-panel" style=${
|
|
198
|
-
${this._renderSearchForm(
|
|
196
|
+
${this.showSearch&&this._mobileSearchOpen?b`
|
|
197
|
+
<div class="mobile-search-panel" style=${n}>
|
|
198
|
+
${this._renderSearchForm(g,n,!1,!0)}
|
|
199
199
|
<button
|
|
200
200
|
type="button"
|
|
201
201
|
class="mobile-search-close header-icon-button"
|
|
@@ -207,20 +207,20 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
207
207
|
<md-focus-ring aria-hidden="true"></md-focus-ring>
|
|
208
208
|
</button>
|
|
209
209
|
</div>
|
|
210
|
-
`:
|
|
210
|
+
`:v}
|
|
211
211
|
|
|
212
212
|
</div>
|
|
213
213
|
</div>
|
|
214
214
|
|
|
215
215
|
<div class="header-grid-item">
|
|
216
|
-
<div class=${
|
|
217
|
-
${
|
|
216
|
+
<div class=${u||A?"tabs-row":"tabs-row tabs-row--empty"}>
|
|
217
|
+
${u?p?b`
|
|
218
218
|
<div class="tabs-inset">
|
|
219
219
|
<div class="tabs-nav tabs-nav--skeleton" aria-hidden="true">
|
|
220
220
|
${this._renderTabSkeletons()}
|
|
221
221
|
</div>
|
|
222
222
|
</div>
|
|
223
|
-
`:e.length?
|
|
223
|
+
`:e.length?b`
|
|
224
224
|
<div class="tabs-inset">
|
|
225
225
|
<nav
|
|
226
226
|
class="tabs-nav"
|
|
@@ -228,49 +228,49 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
228
228
|
@keydown=${this._onTabsKeydown}
|
|
229
229
|
@scb-dropdown-tab-activate=${this._onDropdownTabActivate}
|
|
230
230
|
>
|
|
231
|
-
${e.map((
|
|
231
|
+
${e.map((f,T)=>f.kind==="dropdown"?b`
|
|
232
232
|
<div class="tab-wrap">
|
|
233
|
-
<slot name=${
|
|
233
|
+
<slot name=${f.slotName}></slot>
|
|
234
234
|
</div>
|
|
235
|
-
`:
|
|
235
|
+
`:f.href?b`
|
|
236
236
|
<div class="tab-wrap">
|
|
237
237
|
<a
|
|
238
238
|
class="tab-link"
|
|
239
|
-
href=${
|
|
240
|
-
data-index=${
|
|
241
|
-
aria-current=${
|
|
239
|
+
href=${f.href}
|
|
240
|
+
data-index=${T}
|
|
241
|
+
aria-current=${T===this.activeTab?"page":"false"}
|
|
242
242
|
@click=${this._onTabClick}
|
|
243
243
|
>
|
|
244
|
-
${
|
|
244
|
+
${f.label}
|
|
245
245
|
</a>
|
|
246
246
|
<md-focus-ring aria-hidden="true"></md-focus-ring>
|
|
247
247
|
</div>
|
|
248
|
-
`:
|
|
248
|
+
`:b`
|
|
249
249
|
<div class="tab-wrap">
|
|
250
250
|
<button
|
|
251
251
|
type="button"
|
|
252
252
|
class="tab-link"
|
|
253
|
-
data-index=${
|
|
254
|
-
aria-current=${
|
|
253
|
+
data-index=${T}
|
|
254
|
+
aria-current=${T===this.activeTab?"page":"false"}
|
|
255
255
|
@click=${this._onTabClick}
|
|
256
256
|
>
|
|
257
|
-
${
|
|
257
|
+
${f.label}
|
|
258
258
|
</button>
|
|
259
259
|
<md-focus-ring aria-hidden="true"></md-focus-ring>
|
|
260
260
|
</div>
|
|
261
261
|
`)}
|
|
262
262
|
</nav>
|
|
263
263
|
</div>
|
|
264
|
-
`:
|
|
264
|
+
`:v:v}
|
|
265
265
|
|
|
266
|
-
${
|
|
266
|
+
${A?this._renderMenuButton("menu-trigger--tabs-right"):v}
|
|
267
267
|
</div>
|
|
268
268
|
</div>
|
|
269
269
|
</div>
|
|
270
270
|
<div class="divider" role="presentation"></div>
|
|
271
271
|
</div>
|
|
272
272
|
|
|
273
|
-
${
|
|
273
|
+
${y?b`
|
|
274
274
|
<scb-drawer
|
|
275
275
|
id=${this._drawerId}
|
|
276
276
|
floating
|
|
@@ -283,9 +283,18 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
283
283
|
@scb-drawer-closed=${this._onDrawerClosed}
|
|
284
284
|
@scb-menu-select=${this._onMenuSelect}
|
|
285
285
|
>
|
|
286
|
-
|
|
286
|
+
${d?b`
|
|
287
|
+
<div class="drawer-close">
|
|
288
|
+
<slot
|
|
289
|
+
name="drawer-close"
|
|
290
|
+
@slotchange=${this._ensureDrawerSlotComponentsReady}
|
|
291
|
+
></slot>
|
|
292
|
+
</div>
|
|
293
|
+
`:v}
|
|
294
|
+
|
|
295
|
+
<slot name="drawer-menu" @slotchange=${this._ensureDrawerSlotComponentsReady}></slot>
|
|
287
296
|
|
|
288
|
-
${a?
|
|
297
|
+
${a?v:b`
|
|
289
298
|
<scb-menu
|
|
290
299
|
.label=${this.menuLabel??""}
|
|
291
300
|
.subLabel=${this.menuSubLabel??""}
|
|
@@ -295,28 +304,28 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
295
304
|
.supportingText=${this.menuSearchPlaceholder??""}
|
|
296
305
|
></scb-search>
|
|
297
306
|
|
|
298
|
-
${this.menuSectionLabel?
|
|
307
|
+
${this.menuSectionLabel?b`
|
|
299
308
|
<scb-menu-section
|
|
300
309
|
.label=${this.menuSectionLabel}
|
|
301
310
|
></scb-menu-section>
|
|
302
|
-
`:
|
|
311
|
+
`:v}
|
|
303
312
|
|
|
304
313
|
${this._renderMenuNodes(r)}
|
|
305
314
|
|
|
306
|
-
${this.includeUtilityInMenu&&(t?.length??0)>0?
|
|
315
|
+
${this.includeUtilityInMenu&&(t?.length??0)>0?b`
|
|
307
316
|
<scb-menu-section label=''></scb-menu-section>
|
|
308
|
-
${t.map(
|
|
317
|
+
${t.map(f=>b`
|
|
309
318
|
<scb-menu-item
|
|
310
|
-
label=${
|
|
311
|
-
item-href=${
|
|
319
|
+
label=${f.label}
|
|
320
|
+
item-href=${f.href}
|
|
312
321
|
></scb-menu-item>
|
|
313
322
|
`)}
|
|
314
|
-
`:
|
|
323
|
+
`:v}
|
|
315
324
|
</scb-menu>
|
|
316
325
|
`}
|
|
317
326
|
</scb-drawer>
|
|
318
|
-
`:
|
|
319
|
-
`}_renderTabSkeletons(){const e=["96px","72px","88px","64px"],t=(this.reserveTabsWidths??"").split(/[\s,]+/).map(a=>a.trim()).filter(Boolean).map(a=>/^\d+(?:\.\d+)?$/.test(a)?`${a}px`:a),r=t.length>0?t:e,s=Number(this.reserveTabsCount),i=Number.isFinite(s)&&s>0?Math.floor(s):t.length>0?t.length:e.length;return
|
|
327
|
+
`:v}
|
|
328
|
+
`}_renderTabSkeletons(){const e=["96px","72px","88px","64px"],t=(this.reserveTabsWidths??"").split(/[\s,]+/).map(a=>a.trim()).filter(Boolean).map(a=>/^\d+(?:\.\d+)?$/.test(a)?`${a}px`:a),r=t.length>0?t:e,s=Number(this.reserveTabsCount),i=Number.isFinite(s)&&s>0?Math.floor(s):t.length>0?t.length:e.length;return b`${Array.from({length:i},(a,d)=>r[d%r.length]).map(a=>b`<span class="tab-skeleton" style=${`inline-size:${a}`}></span>`)}`}_renderLogo(){const e=(this.logoSrc??"").trim();return e?b`<img class="logo" src=${e} alt="" aria-hidden="true" />`:b`
|
|
320
329
|
<svg
|
|
321
330
|
class="logo"
|
|
322
331
|
viewBox="0 0 48 54"
|
|
@@ -350,7 +359,7 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
350
359
|
</clipPath>
|
|
351
360
|
</defs>
|
|
352
361
|
</svg>
|
|
353
|
-
`}},
|
|
362
|
+
`}},z=C,C._JSON_ARRAY={fromAttribute:m=>{if(m==null||m==="")return[];try{const e=JSON.parse(m);return Array.isArray(e)?e:[]}catch{return[]}},toAttribute:m=>m==null?null:JSON.stringify(m)},C.BP_SM_DEFAULT=600,C.BP_MD_DEFAULT=840,C.styles=P`
|
|
354
363
|
:host {
|
|
355
364
|
display: block;
|
|
356
365
|
margin-block-start: var(--scb-header-spacing-block-start, 0);
|
|
@@ -1142,6 +1151,23 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
1142
1151
|
border: 0;
|
|
1143
1152
|
}
|
|
1144
1153
|
|
|
1154
|
+
.drawer-close {
|
|
1155
|
+
box-sizing: border-box;
|
|
1156
|
+
display: flex;
|
|
1157
|
+
justify-content: flex-end;
|
|
1158
|
+
padding-block-start: var(--spacing-4, 12px);
|
|
1159
|
+
padding-inline: var(--spacing-4, 12px);
|
|
1160
|
+
background: var(--md-sys-color-surface-container-lowest);
|
|
1161
|
+
}
|
|
1162
|
+
|
|
1163
|
+
.drawer-close[hidden] {
|
|
1164
|
+
display: none;
|
|
1165
|
+
}
|
|
1166
|
+
|
|
1167
|
+
.drawer-close ::slotted(*) {
|
|
1168
|
+
flex: 0 0 auto;
|
|
1169
|
+
}
|
|
1170
|
+
|
|
1145
1171
|
.divider {
|
|
1146
1172
|
border-bottom: var(--stroke-border, 1px) solid
|
|
1147
1173
|
var(--md-sys-color-outline-variant, #e0e0e0);
|
|
@@ -1152,4 +1178,4 @@ import{_ as M,b as E,g as P,h,m as S,v as y,y as m}from"../../vendor/vendor.js";
|
|
|
1152
1178
|
:host([data-hide-logo-text]) .logo-text {
|
|
1153
1179
|
display: none;
|
|
1154
1180
|
}
|
|
1155
|
-
`,
|
|
1181
|
+
`,C);c([h({type:String,attribute:"max-width"})],o.prototype,"maxWidth",void 0);c([h({type:String,reflect:!0})],o.prototype,"spacing",void 0);c([h({type:String,attribute:"spacing-top",reflect:!0})],o.prototype,"spacingTop",void 0);c([h({type:String,attribute:"spacing-bottom",reflect:!0})],o.prototype,"spacingBottom",void 0);c([h({type:String,reflect:!0,converter:L})],o.prototype,"size",void 0);c([h({type:String,attribute:"logo-text"})],o.prototype,"logoText",void 0);c([h({type:String,attribute:"logotype-text"})],o.prototype,"logotypeText",void 0);c([h({type:String,attribute:"logo-alt"})],o.prototype,"logoAlt",void 0);c([h({type:String,attribute:"logo-href"})],o.prototype,"logoHref",void 0);c([h({type:String,attribute:"logo-src"})],o.prototype,"logoSrc",void 0);c([h({type:String,attribute:"logo-width"})],o.prototype,"logoWidth",void 0);c([h({type:String,attribute:"logo-height"})],o.prototype,"logoHeight",void 0);c([h({type:String,attribute:"logo-aspect-ratio"})],o.prototype,"logoAspectRatio",void 0);c([h({type:Boolean,attribute:"logo-invert-dm",reflect:!0,converter:$})],o.prototype,"logoInvertDm",void 0);c([h({type:Boolean,reflect:!0})],o.prototype,"banner",void 0);c([h({type:String,attribute:"banner-label"})],o.prototype,"bannerLabel",void 0);c([h({type:Array,attribute:"tabs",converter:o._JSON_ARRAY})],o.prototype,"tabs",void 0);c([h({type:Number,attribute:"active-tab"})],o.prototype,"activeTab",void 0);c([h({type:Boolean,attribute:"reserve-tabs",reflect:!0,converter:$})],o.prototype,"reserveTabs",void 0);c([h({type:Number,attribute:"reserve-tabs-count"})],o.prototype,"reserveTabsCount",void 0);c([h({type:String,attribute:"reserve-tabs-widths"})],o.prototype,"reserveTabsWidths",void 0);c([h({type:Boolean,attribute:"layout-pending",reflect:!0,converter:$})],o.prototype,"layoutPending",void 0);c([h({type:Array,attribute:"utility-items",converter:o._JSON_ARRAY})],o.prototype,"utilityItems",void 0);c([h({type:String,attribute:"search-placeholder"})],o.prototype,"searchPlaceholder",void 0);c([h({type:String,attribute:"search-button-label"})],o.prototype,"searchButtonLabel",void 0);c([h({type:String,attribute:"menu-label"})],o.prototype,"menuLabel",void 0);c([h({type:String,attribute:"menu-button-label"})],o.prototype,"menuButtonLabel",void 0);c([h({type:String,attribute:"menu-sub-label"})],o.prototype,"menuSubLabel",void 0);c([h({type:String,attribute:"menu-section-label"})],o.prototype,"menuSectionLabel",void 0);c([h({type:String,attribute:"menu-search-placeholder"})],o.prototype,"menuSearchPlaceholder",void 0);c([h({type:Array,attribute:"menu-data",converter:o._JSON_ARRAY})],o.prototype,"menuData",void 0);c([h({type:Boolean,attribute:"defer-drawer",reflect:!0,converter:$})],o.prototype,"deferDrawer",void 0);c([h({type:Boolean,attribute:"show-drawer",reflect:!0,converter:E})],o.prototype,"showDrawer",void 0);c([h({type:Boolean,attribute:"always-show-menu-button",reflect:!0,converter:$})],o.prototype,"alwaysShowMenuButton",void 0);c([h({type:Boolean,attribute:"show-search",reflect:!0,converter:E})],o.prototype,"showSearch",void 0);c([h({type:Boolean,attribute:"include-utility-in-menu",reflect:!0,converter:$})],o.prototype,"includeUtilityInMenu",void 0);c([h({type:Boolean,attribute:"drawer-overlay",reflect:!0,converter:E})],o.prototype,"drawerOverlay",void 0);c([h({type:String,attribute:"search-max"})],o.prototype,"searchMax",void 0);c([h({type:String,attribute:"search-min"})],o.prototype,"searchMin",void 0);c([h({type:String,attribute:"search-height"})],o.prototype,"searchHeight",void 0);c([h({type:String,attribute:"search-text",reflect:!0})],o.prototype,"searchText",void 0);c([k()],o.prototype,"_drawerId",void 0);c([k()],o.prototype,"_menuExpanded",void 0);c([k()],o.prototype,"_searchId",void 0);c([k()],o.prototype,"_drawerReady",void 0);c([k()],o.prototype,"_mobileSearchOpen",void 0);c([k()],o.prototype,"_slotNavItems",void 0);c([k()],o.prototype,"_slotUtils",void 0);c([k()],o.prototype,"_slotMenu",void 0);c([k()],o.prototype,"_collapsed",void 0);c([k()],o.prototype,"_hideLogoText",void 0);o=z=c([D("scb-header")],o);
|
|
@@ -168,4 +168,4 @@ import{_ as m,b as _,g as v,h as s,v as i,y as r}from"../../vendor/vendor.js";im
|
|
|
168
168
|
md-filled-tonal-icon-button::part(button) {
|
|
169
169
|
border-radius: var(--scb-icon-button-shape-radius) !important;
|
|
170
170
|
}
|
|
171
|
-
`,p);function f(){const l=this.mapSpacingToken(this.spacing),t=this.mapSpacingToken(this.spacingTop)??l,e=this.mapSpacingToken(this.spacingBottom)??l,a=this.mapSpacingToken(this.spacingLeft),c=this.mapSpacingToken(this.spacingRight);t?this.style.setProperty("--scb-icon-button-spacing-block-start",t):this.style.removeProperty("--scb-icon-button-spacing-block-start"),e?this.style.setProperty("--scb-icon-button-spacing-block-end",e):this.style.removeProperty("--scb-icon-button-spacing-block-end"),a?this.style.setProperty("--scb-icon-button-spacing-inline-start",a):this.style.removeProperty("--scb-icon-button-spacing-inline-start"),c?this.style.setProperty("--scb-icon-button-spacing-inline-end",c):this.style.removeProperty("--scb-icon-button-spacing-inline-end")}o([s({type:String})],n.prototype,"icon",void 0);o([s({type:Boolean,reflect:!0})],n.prototype,"filled",null);o([s({type:Boolean,attribute:"icon-filled",reflect:!0})],n.prototype,"iconFilled",null);o([s({type:String,attribute:"aria-label"})],n.prototype,"ariaLabel",void 0);o([s({type:String})],n.prototype,"variant",void 0);o([s({type:String,reflect:!0})],n.prototype,"size",void 0);o([s({type:String,reflect:!0})],n.prototype,"shape",void 0);o([s({type:Boolean,reflect:!0})],n.prototype,"toggle",void 0);o([s({type:Boolean,reflect:!0})],n.prototype,"selected",void 0);o([s({type:String})],n.prototype,"toggleofficon",void 0);o([s({type:String})],n.prototype,"toggleonicon",void 0);o([s({type:Boolean,reflect:!0})],n.prototype,"disabled",void 0);o([s({type:String,reflect:!0})],n.prototype,"spacing",void 0);o([s({type:String,attribute:"spacing-top",reflect:!0})],n.prototype,"spacingTop",void 0);o([s({type:String,attribute:"spacing-bottom",reflect:!0})],n.prototype,"spacingBottom",void 0);o([s({type:String,attribute:"spacing-left",reflect:!0})],n.prototype,"spacingLeft",void 0);o([s({type:String,attribute:"spacing-right",reflect:!0})],n.prototype,"spacingRight",void 0);o([s({type:String})],n.prototype,"href",void 0);o([s({type:String})],n.prototype,"target",void 0);o([s({type:String})],n.prototype,"rel",void 0);n=o([v("scb-icon-button")],n);
|
|
171
|
+
`,p);function f(){const l=this.mapSpacingToken(this.spacing),t=this.mapSpacingToken(this.spacingTop)??l,e=this.mapSpacingToken(this.spacingBottom)??l,a=this.mapSpacingToken(this.spacingLeft),c=this.mapSpacingToken(this.spacingRight);t?this.style.setProperty("--scb-icon-button-spacing-block-start",t):this.style.removeProperty("--scb-icon-button-spacing-block-start"),e?this.style.setProperty("--scb-icon-button-spacing-block-end",e):this.style.removeProperty("--scb-icon-button-spacing-block-end"),a?this.style.setProperty("--scb-icon-button-spacing-inline-start",a):this.style.removeProperty("--scb-icon-button-spacing-inline-start"),c?this.style.setProperty("--scb-icon-button-spacing-inline-end",c):this.style.removeProperty("--scb-icon-button-spacing-inline-end")}o([s({type:String})],n.prototype,"icon",void 0);o([s({type:Boolean,reflect:!0})],n.prototype,"filled",null);o([s({type:Boolean,attribute:"icon-filled",reflect:!0})],n.prototype,"iconFilled",null);o([s({type:String,attribute:"aria-label"})],n.prototype,"ariaLabel",void 0);o([s({type:String})],n.prototype,"variant",void 0);o([s({type:String,reflect:!0})],n.prototype,"size",void 0);o([s({type:String,reflect:!0})],n.prototype,"shape",void 0);o([s({type:Boolean,reflect:!0})],n.prototype,"toggle",void 0);o([s({type:Boolean,reflect:!0})],n.prototype,"selected",void 0);o([s({type:String})],n.prototype,"toggleofficon",void 0);o([s({type:String})],n.prototype,"toggleonicon",void 0);o([s({type:Boolean,reflect:!0})],n.prototype,"disabled",void 0);o([s({type:String,reflect:!0})],n.prototype,"spacing",void 0);o([s({type:String,attribute:"spacing-top",reflect:!0})],n.prototype,"spacingTop",void 0);o([s({type:String,attribute:"spacing-bottom",reflect:!0})],n.prototype,"spacingBottom",void 0);o([s({type:String,attribute:"spacing-left",reflect:!0})],n.prototype,"spacingLeft",void 0);o([s({type:String,attribute:"spacing-right",reflect:!0})],n.prototype,"spacingRight",void 0);o([s({type:String})],n.prototype,"href",void 0);o([s({type:String})],n.prototype,"target",void 0);o([s({type:String})],n.prototype,"rel",void 0);n=o([v("scb-icon-button")],n);export{n as ScbIconButton};
|
|
@@ -35,4 +35,4 @@ import{_ as d,b as g,g as h,h as r,y as b}from"../../vendor/vendor.js";import"..
|
|
|
35
35
|
background-position: -200% 0;
|
|
36
36
|
}
|
|
37
37
|
}
|
|
38
|
-
`,c);s([r({type:String})],i.prototype,"variant",void 0);s([r({type:String})],i.prototype,"width",void 0);s([r({type:String})],i.prototype,"height",void 0);s([r({type:String,attribute:"border-size"})],i.prototype,"borderSize",void 0);s([r({type:String,reflect:!0})],i.prototype,"spacing",void 0);s([r({type:String,attribute:"spacing-top",reflect:!0})],i.prototype,"spacingTop",void 0);s([r({type:String,attribute:"spacing-bottom",reflect:!0})],i.prototype,"spacingBottom",void 0);s([r({type:String,attribute:"spacing-left",reflect:!0})],i.prototype,"spacingLeft",void 0);s([r({type:String,attribute:"spacing-right",reflect:!0})],i.prototype,"spacingRight",void 0);i=s([h("scb-skeleton")],i);
|
|
38
|
+
`,c);s([r({type:String})],i.prototype,"variant",void 0);s([r({type:String})],i.prototype,"width",void 0);s([r({type:String})],i.prototype,"height",void 0);s([r({type:String,attribute:"border-size"})],i.prototype,"borderSize",void 0);s([r({type:String,reflect:!0})],i.prototype,"spacing",void 0);s([r({type:String,attribute:"spacing-top",reflect:!0})],i.prototype,"spacingTop",void 0);s([r({type:String,attribute:"spacing-bottom",reflect:!0})],i.prototype,"spacingBottom",void 0);s([r({type:String,attribute:"spacing-left",reflect:!0})],i.prototype,"spacingLeft",void 0);s([r({type:String,attribute:"spacing-right",reflect:!0})],i.prototype,"spacingRight",void 0);i=s([h("scb-skeleton")],i);export{i as ScbSkeleton};
|
package/mvc/scb-logo.svg
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
-
<svg viewBox="-0.0002 -0.0066 1344.9076 377.9532" xmlns="http://www.w3.org/2000/svg">
|
|
3
|
-
<defs>
|
|
4
|
-
<style type="text/css">
|
|
5
|
-
g {
|
|
6
|
-
fill: #100f0d;
|
|
7
|
-
}
|
|
8
|
-
g:target {
|
|
9
|
-
fill: #fff;
|
|
10
|
-
}
|
|
11
|
-
</style>
|
|
12
|
-
</defs>
|
|
13
|
-
<g transform="matrix(1.3333330154418945, 0, 0, -1.3333330154418945, 0, 377.9466552734375)" id="g10">
|
|
14
|
-
<g transform="scale(0.1)" id="inverted">
|
|
15
|
-
<path id="path14" d="m 1346.6,2515.59 c 0,48.24 -39.11,87.31 -87.4,87.31 -48.29,0 -87.4,-39.07 -87.4,-87.31 V 312.898 c 0,-48.339 39.11,-87.5 87.4,-87.5 48.29,0 87.4,39.161 87.4,87.5 V 1106.8 c 0,5.77 4.79,10.45 10.51,10.45 h 287.22 c 5.76,0 10.5,-4.68 10.5,-10.45 V 305.969 C 1654.83,137.02 1477.67,0 1259.2,0 1040.63,0 863.523,137.02 863.523,305.969 V 2528.77 c 0,168.86 177.107,305.88 395.677,305.88 218.47,0 395.63,-137.02 395.63,-305.88 V 1738.1 c 0,-5.86 -4.74,-10.45 -10.5,-10.45 h -287.22 c -5.72,0 -10.51,4.59 -10.51,10.45 v 777.49"/>
|
|
16
|
-
<path id="path16" d="M 10.4414,2265.38 C -8.01563,2136.85 -1.52734,1926.1 26.1172,1807.73 56.4922,1678.71 231.645,1417.96 310.555,1296.86 389.566,1175.85 494.949,1049.49 493.375,880.922 V 477.18 c 0,-48.25 -39.109,-87.41 -87.406,-87.41 -48.145,0 -87.254,39.16 -87.254,87.41 v 618.79 c 0,5.76 -4.785,10.55 -10.645,10.55 H 20.9453 c -5.8711,0 -10.5039,-4.79 -10.5039,-10.55 V 458.719 c 0,-168.957 177.1056,-305.969 395.5276,-305.969 218.574,0 395.683,137.012 395.683,305.969 v 422.203 c -1.324,289.568 -80.332,331.748 -182.867,505.398 -73.445,124.71 -254.121,381.95 -284.398,510.97 -27.735,118.36 -26.516,255.39 -15.672,379.9 0,48.25 39.109,87.41 87.254,87.41 48.297,0 87.406,-39.16 87.406,-87.41 v -550.32 c 0,-5.77 4.746,-10.45 10.645,-10.45 h 287.085 c 5.911,0 10.547,4.68 10.547,10.45 v 538.51 c 0,169.06 -177.109,305.97 -395.683,305.97 -218.422,0 -395.5276,-136.91 -395.5276,-305.97"/>
|
|
17
|
-
<path id="path18" d="m 1726.57,2547.82 h 440.8 c 182.04,0 329.61,-147.57 329.61,-329.52 v -462.24 c 0,-129.59 -84.97,-238.98 -202.16,-276.48 v -6.24 c 117.19,-37.4 202.16,-146.89 202.16,-276.58 V 491.148 c 0,-160.367 -130.2,-290.457 -290.45,-290.457 l -479.96,-0.293 c -5.91,0 -10.6,4.793 -10.6,10.454 V 2537.37 c 0,5.66 4.69,10.45 10.6,10.45 m 308.27,-229.22 c -5.97,0 -10.65,-4.78 -10.65,-10.55 v -729.33 c 0,-5.97 4.68,-10.65 10.65,-10.65 h 43.36 c 58.01,0 105.08,47.16 105.08,105.18 v 540.18 c 0,58 -47.07,105.17 -105.08,105.17 z m 0,-982.29 c -5.97,0 -10.65,-4.69 -10.65,-10.45 V 430.59 c 0,-5.86 4.68,-10.649 10.65,-10.649 h 51.85 c 58.12,0 105.09,47.18 105.09,105.188 v 706.011 c 0,58.19 -46.97,105.17 -105.09,105.17 h -51.85"/>
|
|
18
|
-
</g>
|
|
19
|
-
</g>
|
|
20
|
-
<text style="fill: rgb(1, 1, 1); font-family: Roboto; font-size: 139.2px; font-weight: 500; stroke: rgb(0, 0, 0); white-space: pre;" x="455.182" y="234.25">Designsystem</text>
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<svg viewBox="-0.0002 -0.0066 1344.9076 377.9532" xmlns="http://www.w3.org/2000/svg">
|
|
3
|
+
<defs>
|
|
4
|
+
<style type="text/css">
|
|
5
|
+
g {
|
|
6
|
+
fill: #100f0d;
|
|
7
|
+
}
|
|
8
|
+
g:target {
|
|
9
|
+
fill: #fff;
|
|
10
|
+
}
|
|
11
|
+
</style>
|
|
12
|
+
</defs>
|
|
13
|
+
<g transform="matrix(1.3333330154418945, 0, 0, -1.3333330154418945, 0, 377.9466552734375)" id="g10">
|
|
14
|
+
<g transform="scale(0.1)" id="inverted">
|
|
15
|
+
<path id="path14" d="m 1346.6,2515.59 c 0,48.24 -39.11,87.31 -87.4,87.31 -48.29,0 -87.4,-39.07 -87.4,-87.31 V 312.898 c 0,-48.339 39.11,-87.5 87.4,-87.5 48.29,0 87.4,39.161 87.4,87.5 V 1106.8 c 0,5.77 4.79,10.45 10.51,10.45 h 287.22 c 5.76,0 10.5,-4.68 10.5,-10.45 V 305.969 C 1654.83,137.02 1477.67,0 1259.2,0 1040.63,0 863.523,137.02 863.523,305.969 V 2528.77 c 0,168.86 177.107,305.88 395.677,305.88 218.47,0 395.63,-137.02 395.63,-305.88 V 1738.1 c 0,-5.86 -4.74,-10.45 -10.5,-10.45 h -287.22 c -5.72,0 -10.51,4.59 -10.51,10.45 v 777.49"/>
|
|
16
|
+
<path id="path16" d="M 10.4414,2265.38 C -8.01563,2136.85 -1.52734,1926.1 26.1172,1807.73 56.4922,1678.71 231.645,1417.96 310.555,1296.86 389.566,1175.85 494.949,1049.49 493.375,880.922 V 477.18 c 0,-48.25 -39.109,-87.41 -87.406,-87.41 -48.145,0 -87.254,39.16 -87.254,87.41 v 618.79 c 0,5.76 -4.785,10.55 -10.645,10.55 H 20.9453 c -5.8711,0 -10.5039,-4.79 -10.5039,-10.55 V 458.719 c 0,-168.957 177.1056,-305.969 395.5276,-305.969 218.574,0 395.683,137.012 395.683,305.969 v 422.203 c -1.324,289.568 -80.332,331.748 -182.867,505.398 -73.445,124.71 -254.121,381.95 -284.398,510.97 -27.735,118.36 -26.516,255.39 -15.672,379.9 0,48.25 39.109,87.41 87.254,87.41 48.297,0 87.406,-39.16 87.406,-87.41 v -550.32 c 0,-5.77 4.746,-10.45 10.645,-10.45 h 287.085 c 5.911,0 10.547,4.68 10.547,10.45 v 538.51 c 0,169.06 -177.109,305.97 -395.683,305.97 -218.422,0 -395.5276,-136.91 -395.5276,-305.97"/>
|
|
17
|
+
<path id="path18" d="m 1726.57,2547.82 h 440.8 c 182.04,0 329.61,-147.57 329.61,-329.52 v -462.24 c 0,-129.59 -84.97,-238.98 -202.16,-276.48 v -6.24 c 117.19,-37.4 202.16,-146.89 202.16,-276.58 V 491.148 c 0,-160.367 -130.2,-290.457 -290.45,-290.457 l -479.96,-0.293 c -5.91,0 -10.6,4.793 -10.6,10.454 V 2537.37 c 0,5.66 4.69,10.45 10.6,10.45 m 308.27,-229.22 c -5.97,0 -10.65,-4.78 -10.65,-10.55 v -729.33 c 0,-5.97 4.68,-10.65 10.65,-10.65 h 43.36 c 58.01,0 105.08,47.16 105.08,105.18 v 540.18 c 0,58 -47.07,105.17 -105.08,105.17 z m 0,-982.29 c -5.97,0 -10.65,-4.69 -10.65,-10.45 V 430.59 c 0,-5.86 4.68,-10.649 10.65,-10.649 h 51.85 c 58.12,0 105.09,47.18 105.09,105.188 v 706.011 c 0,58.19 -46.97,105.17 -105.09,105.17 h -51.85"/>
|
|
18
|
+
</g>
|
|
19
|
+
</g>
|
|
20
|
+
<text style="fill: rgb(1, 1, 1); font-family: Roboto; font-size: 139.2px; font-weight: 500; stroke: rgb(0, 0, 0); white-space: pre;" x="455.182" y="234.25">Designsystem</text>
|
|
21
21
|
</svg>
|
package/mvc/scb.svg
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
<svg
|
|
2
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
3
|
-
xmlns:xlink="http://www.w3.org/1999/xlink"
|
|
4
|
-
aria-hidden="true"
|
|
5
|
-
role="img"
|
|
6
|
-
width="48"
|
|
7
|
-
height="48"
|
|
8
|
-
preserveAspectRatio="xMidYMid meet"
|
|
9
|
-
viewBox="0 0 1300 1300"
|
|
10
|
-
>
|
|
11
|
-
<path d="M539.3,128.2c0-19.3-15.7-35-35-35c-19.3,0-35,15.6-35,35v882.1c0,19.4,15.7,35,35,35c19.3,0,35-15.7,35-35V692.4 c0-2.3,1.9-4.2,4.2-4.2h115c2.3,0,4.2,1.9,4.2,4.2v320.7c0,67.7-71,122.5-158.4,122.5c-87.5,0-158.5-54.9-158.5-122.5V122.9 c0-67.6,70.9-122.5,158.5-122.5c87.5,0,158.4,54.9,158.4,122.5v316.6c0,2.3-1.9,4.2-4.2,4.2h-115c-2.3,0-4.2-1.8-4.2-4.2V128.2z" />
|
|
12
|
-
<path d="M4.2,228.4c-7.4,51.5-4.8,135.9,6.3,183.3c12.2,51.7,82.3,156.1,113.9,204.6c31.6,48.5,73.8,99.1,73.2,166.6v161.7 c0,19.3-15.7,35-35,35c-19.3,0-34.9-15.7-34.9-35V696.7c0-2.3-1.9-4.2-4.3-4.2H8.4c-2.4,0-4.2,1.9-4.2,4.2v255.2 c0,67.7,70.9,122.5,158.4,122.5c87.5,0,158.5-54.9,158.5-122.5V782.8c-0.5-116-32.2-132.9-73.2-202.4 c-29.4-49.9-101.8-153-113.9-204.6c-11.1-47.4-10.6-102.3-6.3-152.1c0-19.3,15.7-35,34.9-35c19.3,0,35,15.7,35,35V444 c0,2.3,1.9,4.2,4.3,4.2h115c2.4,0,4.2-1.9,4.2-4.2V228.4c0-67.7-70.9-122.5-158.5-122.5C75.1,105.8,4.2,160.7,4.2,228.4" />
|
|
13
|
-
<path d="M814.9,600.4c-2.4,0-4.3,1.9-4.3,4.2v358.5c0,2.3,1.9,4.3,4.3,4.3h20.8c23.3,0,42.1-18.9,42.1-42.1V642.6 c0-23.3-18.8-42.1-42.1-42.1H814.9z M814.9,207.1c-2.4,0-4.3,1.9-4.3,4.2v292.1c0,2.4,1.9,4.3,4.3,4.3h17.4 c23.2,0,42.1-18.9,42.1-42.1V249.2c0-23.2-18.9-42.1-42.1-42.1H814.9z M691.5,115.3H868c72.9,0,132,59.1,132,132v185.1 c0,51.9-34,95.7-81,110.7v2.5c46.9,15,81,58.8,81,110.8v282.6c0,64.2-52.1,116.3-116.3,116.3l-192.2,0.1c-2.4,0-4.2-1.9-4.2-4.2 V119.4C687.2,117.2,689.1,115.3,691.5,115.3" />
|
|
1
|
+
<svg
|
|
2
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
3
|
+
xmlns:xlink="http://www.w3.org/1999/xlink"
|
|
4
|
+
aria-hidden="true"
|
|
5
|
+
role="img"
|
|
6
|
+
width="48"
|
|
7
|
+
height="48"
|
|
8
|
+
preserveAspectRatio="xMidYMid meet"
|
|
9
|
+
viewBox="0 0 1300 1300"
|
|
10
|
+
>
|
|
11
|
+
<path d="M539.3,128.2c0-19.3-15.7-35-35-35c-19.3,0-35,15.6-35,35v882.1c0,19.4,15.7,35,35,35c19.3,0,35-15.7,35-35V692.4 c0-2.3,1.9-4.2,4.2-4.2h115c2.3,0,4.2,1.9,4.2,4.2v320.7c0,67.7-71,122.5-158.4,122.5c-87.5,0-158.5-54.9-158.5-122.5V122.9 c0-67.6,70.9-122.5,158.5-122.5c87.5,0,158.4,54.9,158.4,122.5v316.6c0,2.3-1.9,4.2-4.2,4.2h-115c-2.3,0-4.2-1.8-4.2-4.2V128.2z" />
|
|
12
|
+
<path d="M4.2,228.4c-7.4,51.5-4.8,135.9,6.3,183.3c12.2,51.7,82.3,156.1,113.9,204.6c31.6,48.5,73.8,99.1,73.2,166.6v161.7 c0,19.3-15.7,35-35,35c-19.3,0-34.9-15.7-34.9-35V696.7c0-2.3-1.9-4.2-4.3-4.2H8.4c-2.4,0-4.2,1.9-4.2,4.2v255.2 c0,67.7,70.9,122.5,158.4,122.5c87.5,0,158.5-54.9,158.5-122.5V782.8c-0.5-116-32.2-132.9-73.2-202.4 c-29.4-49.9-101.8-153-113.9-204.6c-11.1-47.4-10.6-102.3-6.3-152.1c0-19.3,15.7-35,34.9-35c19.3,0,35,15.7,35,35V444 c0,2.3,1.9,4.2,4.3,4.2h115c2.4,0,4.2-1.9,4.2-4.2V228.4c0-67.7-70.9-122.5-158.5-122.5C75.1,105.8,4.2,160.7,4.2,228.4" />
|
|
13
|
+
<path d="M814.9,600.4c-2.4,0-4.3,1.9-4.3,4.2v358.5c0,2.3,1.9,4.3,4.3,4.3h20.8c23.3,0,42.1-18.9,42.1-42.1V642.6 c0-23.3-18.8-42.1-42.1-42.1H814.9z M814.9,207.1c-2.4,0-4.3,1.9-4.3,4.2v292.1c0,2.4,1.9,4.3,4.3,4.3h17.4 c23.2,0,42.1-18.9,42.1-42.1V249.2c0-23.2-18.9-42.1-42.1-42.1H814.9z M691.5,115.3H868c72.9,0,132,59.1,132,132v185.1 c0,51.9-34,95.7-81,110.7v2.5c46.9,15,81,58.8,81,110.8v282.6c0,64.2-52.1,116.3-116.3,116.3l-192.2,0.1c-2.4,0-4.2-1.9-4.2-4.2 V119.4C687.2,117.2,689.1,115.3,691.5,115.3" />
|
|
14
14
|
</svg>
|