scb-wc-test 0.1.310 → 0.1.312

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import{a as v,n as a,r as b,i as S,x as h,t as m}from"../../vendor/vendor.js";import"../scb-icon-button/scb-icon-button.js";import"../scb-button/scb-button.js";import"../../vendor/vendor-material.js";import"../../vendor/preload-helper.js";(function(){try{var t=typeof globalThis<"u"?globalThis:window;if(!t.__scb_ce_guard_installed__){t.__scb_ce_guard_installed__=!0;var l=customElements.define.bind(customElements);customElements.define=function(s,i,r){try{customElements.get(s)||l(s,i,r)}catch(n){var c=String(n||"");if(c.indexOf("already been used")===-1&&c.indexOf("NotSupportedError")===-1)throw n}}}}catch{}})();var y=Object.defineProperty,w=Object.getOwnPropertyDescriptor,g=t=>{throw TypeError(t)},o=(t,l,s,i)=>{for(var r=i>1?void 0:i?w(l,s):l,c=t.length-1,n;c>=0;c--)(n=t[c])&&(r=(i?n(l,s,r):n(r))||r);return i&&r&&y(l,s,r),r},z=(t,l,s)=>l.has(t)||g("Cannot "+s),_=(t,l,s)=>l.has(t)?g("Cannot add the same private member more than once"):l instanceof WeakSet?l.add(t):l.set(t,s),p=(t,l,s)=>(z(t,l,"access private method"),s),d,f,u;let e=class extends S{constructor(){super(...arguments),_(this,d),this.variant="standard",this.width="100%",this.showScrollbar=!1,this.rightScrollButtonLabel="Scrolla höger",this.leftScrollButtonLabel="Scrolla vänster",this.spacing=void 0,this.spacingTop=void 0,this.spacingBottom=void 0,this.spacingLeft=void 0,this.spacingRight=void 0,this.contentFlex=!1,this.internalGap="",this._canScrollLeft=!1,this._canScrollRight=!1,this.updateScrollButtons=()=>{const t=this.scrollerEl||this.shadowRoot?.querySelector(".scb-horizontal-scroller");if(!t){this._canScrollLeft&&(this._canScrollLeft=!1),this._canScrollRight&&(this._canScrollRight=!1),this.removeAttribute("data-scroll-left"),this.removeAttribute("data-scroll-right");return}const l=t.scrollLeft>0,s=t.scrollLeft+t.clientWidth<t.scrollWidth-1;this._canScrollLeft!==l&&(this._canScrollLeft=l),this._canScrollRight!==s&&(this._canScrollRight=s),l?this.setAttribute("data-scroll-left",""):this.removeAttribute("data-scroll-left"),s?this.setAttribute("data-scroll-right",""):this.removeAttribute("data-scroll-right")},this.lastScrollLeft=0,this.isScrolling=!1,this.scrollEndTimeout=null,this.scrollerEl=null,this.slotEl=null,this.sizeObserver=null,this.resizeRaf=null,this.handleScroll=()=>{const t=this.shadowRoot?.querySelector(".scb-horizontal-scroller");t&&(this.updateScrollButtons(),this.dispatchCustomEventWithAlias("scb-scroll",{scrollLeft:t.scrollLeft}),this.isScrolling||(this.isScrolling=!0,this.dispatchCustomEventWithAlias("scb-scroll-start",{scrollLeft:t.scrollLeft})),clearTimeout(this.scrollEndTimeout),this.scrollEndTimeout=setTimeout(()=>{this.isScrolling=!1,this.dispatchCustomEventWithAlias("scb-scroll-end",{scrollLeft:t.scrollLeft})},120),t.scrollLeft>this.lastScrollLeft?this.dispatchCustomEventWithAlias("scb-scroll-right",{scrollLeft:t.scrollLeft}):t.scrollLeft<this.lastScrollLeft&&this.dispatchCustomEventWithAlias("scb-scroll-left",{scrollLeft:t.scrollLeft}),this.lastScrollLeft=t.scrollLeft)},this.handleWheel=t=>{const l=this.scrollerEl||this.shadowRoot?.querySelector(".scb-horizontal-scroller");if(!l||t.deltaY===0)return;const s=l.scrollLeft,i=s>0,r=s+l.clientWidth<l.scrollWidth-1;!i&&!r||(l.scrollLeft+=t.deltaY,l.scrollLeft!==s&&t.preventDefault())}}doScrollBy(t){const l=this.shadowRoot?.querySelector(".scb-horizontal-scroller");l&&l.scrollBy({left:t,behavior:"smooth"})}connectedCallback(){super.connectedCallback(),this.style.setProperty("--scb-horizontal-scroller-width",this.width)}disconnectedCallback(){super.disconnectedCallback(),this.scrollerEl&&(this.scrollerEl.removeEventListener("scroll",this.handleScroll),this.scrollerEl.removeEventListener("wheel",this.handleWheel)),this.sizeObserver&&(this.sizeObserver.disconnect(),this.sizeObserver=null),this.resizeRaf!==null&&(cancelAnimationFrame(this.resizeRaf),this.resizeRaf=null),this.scrollEndTimeout&&(clearTimeout(this.scrollEndTimeout),this.scrollEndTimeout=null),this.scrollerEl=null,this.slotEl=null}dispatchCustomEvent(t,l={}){this.dispatchEvent(new CustomEvent(t,{detail:l,bubbles:!0,composed:!0}))}dispatchCustomEventWithAlias(t,l={}){if(this.dispatchCustomEvent(t,l),t.includes("-")){const s=t.replace(/-/g,"");this.dispatchCustomEvent(s,l)}}firstUpdated(){this.scrollerEl=this.shadowRoot?.querySelector(".scb-horizontal-scroller"),this.slotEl=this.shadowRoot?.querySelector("slot");const t=this.shadowRoot?.querySelector(".scroll-shadow-left"),l=this.shadowRoot?.querySelector(".scroll-shadow-right");this.scrollerEl&&(this.scrollerEl.addEventListener("scroll",this.handleScroll),this.scrollerEl.addEventListener("wheel",this.handleWheel,{passive:!1}));const s=()=>{if(this.slotEl&&t&&l){const c=this.slotEl.getBoundingClientRect();t.style.height=`${c.height}px`,l.style.height=`${c.height}px`}},i=()=>{s(),this.updateScrollButtons()},r=()=>{this.resizeRaf===null&&(this.resizeRaf=requestAnimationFrame(()=>{this.resizeRaf=null,i()}))};requestAnimationFrame(()=>{i()}),this.slotEl&&this.slotEl.addEventListener("slotchange",()=>{r()}),this.sizeObserver=new ResizeObserver(()=>{r()}),this.scrollerEl&&this.sizeObserver.observe(this.scrollerEl),this.slotEl&&this.sizeObserver.observe(this.slotEl),p(this,d,f).call(this),p(this,d,u).call(this)}updated(t){t.has("width")&&this.style.setProperty("--scb-horizontal-scroller-width",this.width),(t.has("spacing")||t.has("spacingTop")||t.has("spacingBottom")||t.has("spacingLeft")||t.has("spacingRight"))&&p(this,d,f).call(this),(t.has("internalGap")||t.has("contentFlex"))&&p(this,d,u).call(this)}mapSpacingToken(t){if(!t)return;const l=String(t).trim();if(l)return/^\d+$/.test(l)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(l,10)))})`:l}render(){const t=this.variant,l=this._canScrollLeft||this._canScrollRight;switch(t){case"inline":return h`
1
+ import{a as v,n as a,r as b,i as S,x as h,t as m}from"../../vendor/vendor.js";import"../scb-icon-button/scb-icon-button.js";import"../scb-button/scb-button.js";import"../../vendor/vendor-material.js";import"../../vendor/preload-helper.js";(function(){try{var t=typeof globalThis<"u"?globalThis:window;if(!t.__scb_ce_guard_installed__){t.__scb_ce_guard_installed__=!0;var l=customElements.define.bind(customElements);customElements.define=function(s,i,r){try{customElements.get(s)||l(s,i,r)}catch(n){var c=String(n||"");if(c.indexOf("already been used")===-1&&c.indexOf("NotSupportedError")===-1)throw n}}}}catch{}})();var y=Object.defineProperty,w=Object.getOwnPropertyDescriptor,g=t=>{throw TypeError(t)},o=(t,l,s,i)=>{for(var r=i>1?void 0:i?w(l,s):l,c=t.length-1,n;c>=0;c--)(n=t[c])&&(r=(i?n(l,s,r):n(r))||r);return i&&r&&y(l,s,r),r},z=(t,l,s)=>l.has(t)||g("Cannot "+s),_=(t,l,s)=>l.has(t)?g("Cannot add the same private member more than once"):l instanceof WeakSet?l.add(t):l.set(t,s),p=(t,l,s)=>(z(t,l,"access private method"),s),d,f,u;let e=class extends S{constructor(){super(...arguments),_(this,d),this.variant="standard",this.width="100%",this.showScrollbar=!1,this.rightScrollButtonLabel="Scrolla höger",this.leftScrollButtonLabel="Scrolla vänster",this.spacing=void 0,this.spacingTop=void 0,this.spacingBottom=void 0,this.spacingLeft=void 0,this.spacingRight=void 0,this.contentFlex=!1,this.internalGap="",this._canScrollLeft=!1,this._canScrollRight=!1,this.updateScrollButtons=()=>{const t=this.scrollerEl||this.shadowRoot?.querySelector(".scb-horizontal-scroller");if(!t){this._canScrollLeft&&(this._canScrollLeft=!1),this._canScrollRight&&(this._canScrollRight=!1),this.removeAttribute("data-scroll-left"),this.removeAttribute("data-scroll-right");return}const l=t.scrollLeft>0,s=t.scrollLeft+t.clientWidth<t.scrollWidth-1;this._canScrollLeft!==l&&(this._canScrollLeft=l),this._canScrollRight!==s&&(this._canScrollRight=s),l?this.setAttribute("data-scroll-left",""):this.removeAttribute("data-scroll-left"),s?this.setAttribute("data-scroll-right",""):this.removeAttribute("data-scroll-right")},this.lastScrollLeft=0,this.isScrolling=!1,this.scrollEndTimeout=null,this.scrollerEl=null,this.slotEl=null,this.sizeObserver=null,this.resizeRaf=null,this.handleScroll=()=>{const t=this.shadowRoot?.querySelector(".scb-horizontal-scroller");t&&(this.updateScrollButtons(),this.dispatchCustomEventWithAlias("scb-scroll",{scrollLeft:t.scrollLeft}),this.isScrolling||(this.isScrolling=!0,this.dispatchCustomEventWithAlias("scb-scroll-start",{scrollLeft:t.scrollLeft})),clearTimeout(this.scrollEndTimeout),this.scrollEndTimeout=setTimeout(()=>{this.isScrolling=!1,this.dispatchCustomEventWithAlias("scb-scroll-end",{scrollLeft:t.scrollLeft})},120),t.scrollLeft>this.lastScrollLeft?this.dispatchCustomEventWithAlias("scb-scroll-right",{scrollLeft:t.scrollLeft}):t.scrollLeft<this.lastScrollLeft&&this.dispatchCustomEventWithAlias("scb-scroll-left",{scrollLeft:t.scrollLeft}),this.lastScrollLeft=t.scrollLeft)},this.handleWheel=t=>{const l=this.scrollerEl||this.shadowRoot?.querySelector(".scb-horizontal-scroller");if(!l||t.deltaY===0)return;const s=l.scrollLeft,i=s>0,r=s+l.clientWidth<l.scrollWidth-1;!i&&!r||(l.scrollLeft+=t.deltaY,l.scrollLeft!==s&&t.preventDefault())}}getScrollStep(){const t=this.scrollerEl||this.shadowRoot?.querySelector(".scb-horizontal-scroller");return t?Math.max(Math.round(t.clientWidth*.8),120):200}doScrollBy(t){const l=this.shadowRoot?.querySelector(".scb-horizontal-scroller");l&&l.scrollBy({left:t,behavior:"smooth"})}connectedCallback(){super.connectedCallback(),this.style.setProperty("--scb-horizontal-scroller-width",this.width)}disconnectedCallback(){super.disconnectedCallback(),this.scrollerEl&&(this.scrollerEl.removeEventListener("scroll",this.handleScroll),this.scrollerEl.removeEventListener("wheel",this.handleWheel)),this.sizeObserver&&(this.sizeObserver.disconnect(),this.sizeObserver=null),this.resizeRaf!==null&&(cancelAnimationFrame(this.resizeRaf),this.resizeRaf=null),this.scrollEndTimeout&&(clearTimeout(this.scrollEndTimeout),this.scrollEndTimeout=null),this.scrollerEl=null,this.slotEl=null}dispatchCustomEvent(t,l={}){this.dispatchEvent(new CustomEvent(t,{detail:l,bubbles:!0,composed:!0}))}dispatchCustomEventWithAlias(t,l={}){if(this.dispatchCustomEvent(t,l),t.includes("-")){const s=t.replace(/-/g,"");this.dispatchCustomEvent(s,l)}}firstUpdated(){this.scrollerEl=this.shadowRoot?.querySelector(".scb-horizontal-scroller"),this.slotEl=this.shadowRoot?.querySelector("slot");const t=this.shadowRoot?.querySelector(".scroll-shadow-left"),l=this.shadowRoot?.querySelector(".scroll-shadow-right");this.scrollerEl&&(this.scrollerEl.addEventListener("scroll",this.handleScroll),this.scrollerEl.addEventListener("wheel",this.handleWheel,{passive:!1}));const s=()=>{if(this.slotEl&&t&&l){const c=this.slotEl.getBoundingClientRect();t.style.height=`${c.height}px`,l.style.height=`${c.height}px`}},i=()=>{s(),this.updateScrollButtons()},r=()=>{this.resizeRaf===null&&(this.resizeRaf=requestAnimationFrame(()=>{this.resizeRaf=null,i()}))};requestAnimationFrame(()=>{i()}),this.slotEl&&this.slotEl.addEventListener("slotchange",()=>{r()}),this.sizeObserver=new ResizeObserver(()=>{r()}),this.scrollerEl&&this.sizeObserver.observe(this.scrollerEl),this.slotEl&&this.sizeObserver.observe(this.slotEl),p(this,d,f).call(this),p(this,d,u).call(this)}updated(t){t.has("width")&&this.style.setProperty("--scb-horizontal-scroller-width",this.width),(t.has("spacing")||t.has("spacingTop")||t.has("spacingBottom")||t.has("spacingLeft")||t.has("spacingRight"))&&p(this,d,f).call(this),(t.has("internalGap")||t.has("contentFlex"))&&p(this,d,u).call(this)}mapSpacingToken(t){if(!t)return;const l=String(t).trim();if(l)return/^\d+$/.test(l)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(l,10)))})`:l}render(){const t=this.variant,l=this._canScrollLeft||this._canScrollRight;switch(t){case"inline":return h`
2
2
  <div class="scb-horizontal-scroller ${l?"canScroll":""}" tabindex="0">
3
3
  ${this.variant!="inline"?h`<div class="scroll-shadow-left"></div>`:""}
4
4
  <slot></slot>
@@ -14,7 +14,7 @@ import{a as v,n as a,r as b,i as S,x as h,t as m}from"../../vendor/vendor.js";im
14
14
  label="${this.leftScrollButtonLabel}"
15
15
  aria-label="Scrolla vänster"
16
16
  icon="chevron_left"
17
- @click="${()=>this.doScrollBy(-100)}"
17
+ @click="${()=>this.doScrollBy(-this.getScrollStep())}"
18
18
  ></scb-button>
19
19
  `:""}
20
20
 
@@ -26,7 +26,7 @@ import{a as v,n as a,r as b,i as S,x as h,t as m}from"../../vendor/vendor.js";im
26
26
  aria-label="Scrolla höger"
27
27
  icon="chevron_right"
28
28
  trailing-icon
29
- @click="${()=>this.doScrollBy(100)}"
29
+ @click="${()=>this.doScrollBy(this.getScrollStep())}"
30
30
  ></scb-button>
31
31
  `:""}
32
32
  </div>
@@ -38,7 +38,7 @@ import{a as v,n as a,r as b,i as S,x as h,t as m}from"../../vendor/vendor.js";im
38
38
  icon="chevron_left"
39
39
  aria-label="Scrolla vänster"
40
40
  variant="filled-tonal"
41
- @click="${()=>this.doScrollBy(-100)}"
41
+ @click="${()=>this.doScrollBy(-this.getScrollStep())}"
42
42
  ></scb-icon-button>
43
43
  `:""}
44
44
  <div class="scroll-shadow-left"></div>
@@ -53,7 +53,7 @@ import{a as v,n as a,r as b,i as S,x as h,t as m}from"../../vendor/vendor.js";im
53
53
  icon="chevron_right"
54
54
  aria-label="Scrolla höger"
55
55
  variant="filled-tonal"
56
- @click="${()=>this.doScrollBy(100)}"
56
+ @click="${()=>this.doScrollBy(this.getScrollStep())}"
57
57
  ></scb-icon-button>
58
58
  `:""}
59
59
  `}}};d=new WeakSet;f=function(){const t=this.mapSpacingToken(this.spacing),l=this.mapSpacingToken(this.spacingTop),s=this.mapSpacingToken(this.spacingBottom),i=this.mapSpacingToken(this.spacingLeft),r=this.mapSpacingToken(this.spacingRight),c=l??t,n=s??t;c?this.style.setProperty("--scb-horizontal-scroller-spacing-block-start",c):this.style.removeProperty("--scb-horizontal-scroller-spacing-block-start"),n?this.style.setProperty("--scb-horizontal-scroller-spacing-block-end",n):this.style.removeProperty("--scb-horizontal-scroller-spacing-block-end"),i?this.style.setProperty("--scb-horizontal-scroller-spacing-inline-start",i):this.style.removeProperty("--scb-horizontal-scroller-spacing-inline-start"),r?this.style.setProperty("--scb-horizontal-scroller-spacing-inline-end",r):this.style.removeProperty("--scb-horizontal-scroller-spacing-inline-end")};u=function(){const t=this.mapSpacingToken(this.internalGap);this.contentFlex&&t?this.style.setProperty("--scb-horizontal-scroller-internal-gap",t):this.style.removeProperty("--scb-horizontal-scroller-internal-gap")};e.styles=v`
@@ -1,4 +1,4 @@
1
- import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../vendor/vendor.js";import"../scb-chip/scb-chip.js";import"../scb-segmented-button/scb-segmented-button.js";import"../scb-segmented-button/scb-segmented-item.js";import"../scb-accordion/scb-accordion.js";import"../scb-divider/scb-divider.js";import"../scb-horizontal-scroller/scb-horizontal-scroller.js";import"../scb-icon-button/scb-icon-button.js";import{a as ft,g as ut,b as mt}from"./scb-viz-series-differentiation-registry.js";import"../../vendor/preload-helper.js";import"../../vendor/vendor-material.js";import"../scb-accordion/scb-accordion-item.js";import"../scb-button/scb-button.js";(function(){try{var t=typeof globalThis<"u"?globalThis:window;if(!t.__scb_ce_guard_installed__){t.__scb_ce_guard_installed__=!0;var e=customElements.define.bind(customElements);customElements.define=function(i,n,s){try{customElements.get(i)||e(i,n,s)}catch(a){var o=String(a||"");if(o.indexOf("already been used")===-1&&o.indexOf("NotSupportedError")===-1)throw a}}}}catch{}})();var bt=Object.defineProperty,vt=Object.getOwnPropertyDescriptor,U=t=>{throw TypeError(t)},u=(t,e,i,n)=>{for(var s=n>1?void 0:n?vt(e,i):e,o=t.length-1,a;o>=0;o--)(a=t[o])&&(s=(n?a(e,i,s):a(s))||s);return n&&s&&bt(e,i,s),s},yt=(t,e,i)=>e.has(t)||U("Cannot "+i),_t=(t,e,i)=>e.has(t)?U("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,i),c=(t,e,i)=>(yt(t,e,"access private method"),i),l,L,F,I,M,A,j,K,D,N,k,J,Y,Z,$,E,v,Q,X,tt,et,it,st,nt,at,O,rt,T,R,ot,lt,q,B,H,x,V;const ct=`<svg version="1.1" id="Lager_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
1
+ import{a as ht,n as m,r as P,i as dt,x as f,k as W,l as pt,t as gt}from"../../vendor/vendor.js";import"../scb-chip/scb-chip.js";import"../scb-segmented-button/scb-segmented-button.js";import"../scb-segmented-button/scb-segmented-item.js";import"../scb-accordion/scb-accordion.js";import"../scb-divider/scb-divider.js";import"../scb-horizontal-scroller/scb-horizontal-scroller.js";import"../scb-icon-button/scb-icon-button.js";import{a as ft,g as ut,b as mt}from"./scb-viz-series-differentiation-registry.js";import"../../vendor/preload-helper.js";import"../../vendor/vendor-material.js";import"../scb-accordion/scb-accordion-item.js";import"../scb-button/scb-button.js";(function(){try{var t=typeof globalThis<"u"?globalThis:window;if(!t.__scb_ce_guard_installed__){t.__scb_ce_guard_installed__=!0;var e=customElements.define.bind(customElements);customElements.define=function(i,a,s){try{customElements.get(i)||e(i,a,s)}catch(n){var r=String(n||"");if(r.indexOf("already been used")===-1&&r.indexOf("NotSupportedError")===-1)throw n}}}}catch{}})();var bt=Object.defineProperty,vt=Object.getOwnPropertyDescriptor,U=t=>{throw TypeError(t)},u=(t,e,i,a)=>{for(var s=a>1?void 0:a?vt(e,i):e,r=t.length-1,n;r>=0;r--)(n=t[r])&&(s=(a?n(e,i,s):n(s))||s);return a&&s&&bt(e,i,s),s},yt=(t,e,i)=>e.has(t)||U("Cannot "+i),_t=(t,e,i)=>e.has(t)?U("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,i),c=(t,e,i)=>(yt(t,e,"access private method"),i),l,L,F,N,M,A,I,K,D,j,k,J,X,Y,$,E,v,Z,Q,tt,et,it,st,at,nt,O,rt,T,R,ot,lt,q,B,H,x,V;const ct=`<svg version="1.1" id="Lager_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
2
2
  viewBox="0 0 727.3 87.3" style="enable-background:new 0 0 727.3 87.3;" xml:space="preserve" fill="currentColor">
3
3
  <style type="text/css">
4
4
  .st0{clip-path:url(#SVGID_00000118375311472882578510000008414848687067442345_);}
@@ -113,7 +113,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
113
113
  <path d="M688.2,24.4h5.8v6h-5.8V24.4z M688.2,36.6h5.8v30.1h-5.8V36.6z"/>
114
114
  <path d="M701.8,24.4h5.8v26.3h0.1l11.2-14.1h7l-10,11.7l11.4,18.3H720l-7.7-14l-4.6,5.4v8.7h-5.8V24.4H701.8z"/>
115
115
  </svg>
116
- `;let f=class extends dt{constructor(){super(...arguments),_t(this,l),this.variant="Standard",this.selectedChip="Diagram",this.title="",this.subtitle="",this.description="",this.comment="",this.source="",this.footnote="",this.lang="sv",this.imageHref="",this.officialStatistics=!1,this.disableToggle=!1,this.contentMaxWidth="",this.containerMaxWidth="",this.contentHeight="",this.toggleHeightMode="stable",this._actionsMenuOpen=!1,this._seriesDifferentiationEnabled=!1,this._seriesDifferentiationSnapshots=new WeakMap,this._diagramReflowFrame=0,this._chartConfigSyncFrame=0,this.spacing=void 0,this.spacingTop=void 0,this.spacingBottom=void 0,this.spacingLeft=void 0,this.spacingRight=void 0,this._onDocumentPointerDown=t=>{if(!this._actionsMenuOpen)return;const e=t.composedPath(),i=this.shadowRoot?.querySelector(".actions-menu");i&&e.includes(i)||this._closeActionsMenu()},this._onDocumentKeyDown=t=>{this._actionsMenuOpen&&t.key==="Escape"&&(t.preventDefault(),this._closeActionsMenu(),this._focusMenuButton())},this._onPrintClick=async()=>{this._closeActionsMenu(),await c(this,l,it).call(this)},this._onDownloadPngClick=async()=>{this._canExportRaster()&&(this._closeActionsMenu(),await c(this,l,E).call(this,"png"))},this._onDownloadJpgClick=async()=>{this._canExportRaster()&&(this._closeActionsMenu(),await c(this,l,E).call(this,"jpeg"))},this._onDownloadCsvClick=()=>{this._canExportCsv()&&(this._closeActionsMenu(),c(this,l,st).call(this))},this._onToggleSeriesDifferentiationClick=()=>{this._seriesDifferentiationEnabled=!this._seriesDifferentiationEnabled,this._closeActionsMenu(),c(this,l,$).call(this)}}get descriptionLabel(){return this.lang==="en"?"Description of the chart":"Beskrivning av diagrammet"}get moreAboutStatsLabel(){return this.lang==="en"?"More about the statistics":"Mer om statistiken"}get commentLabel(){return this.lang==="en"?"Comments":"Kommentar"}get sourceLabel(){return this.lang==="en"?"Source":"Källa"}get footnoteLabel(){return this.lang==="en"?"Footnotes":"Fotnot"}get officialStatisticsLabel(){return this.lang==="en"?"Official statistics of Sweden":"Sveriges officiella statistik"}get officialStatisticsTitle(){return this.lang==="en"?"Part of Official statistics of Sweden":"Tillhör Sveriges officiella statistik"}get officialStatisticsAlt(){return this.lang==="en"?"Read more about Official statistics of Sweden":"Läs mer om Sveriges officiella statistik"}get actionsMenuLabel(){return this.lang==="en"?"Open menu":"Öppna meny"}get printLabel(){return this.lang==="en"?"Print":"Skriv ut"}get downloadPngLabel(){return this.lang==="en"?"Download PNG":"Ladda ner PNG"}get downloadJpgLabel(){return this.lang==="en"?"Download JPG":"Ladda ner JPG"}get downloadCsvLabel(){return this.lang==="en"?"Download CSV":"Ladda ner CSV"}get enableSeriesDifferentiationLabel(){return this.lang==="en"?"Show symbols and patterns":"Visa symboler och mönster"}get disableSeriesDifferentiationLabel(){return this.lang==="en"?"Hide symbols and patterns":"Dölj symboler och mönster"}_getImageAltText(){return[this.title,this.subtitle,this.description].map(e=>typeof e=="string"?e.trim():"").filter(Boolean).join(". ")||(this.lang==="en"?"Image figure":"Bildfigur")}connectedCallback(){super.connectedCallback(),document.addEventListener("pointerdown",this._onDocumentPointerDown,!0),document.addEventListener("keydown",this._onDocumentKeyDown)}firstUpdated(t){this._readTableDataFromSlot(),c(this,l,H).call(this),c(this,l,V).call(this),c(this,l,D).call(this),this._syncChipClass(),c(this,l,L).call(this),c(this,l,M).call(this)}updated(t){super.updated(t),(t.has("selectedChip")||t.has("variant"))&&(this._syncChipClass(),this._closeActionsMenu()),t.has("selectedChip")&&this._dispatchSelectedChipChanged(),(t.has("spacing")||t.has("spacingTop")||t.has("spacingBottom")||t.has("spacingLeft")||t.has("spacingRight"))&&c(this,l,H).call(this),t.has("containerMaxWidth")&&c(this,l,V).call(this),t.has("variant")&&c(this,l,L).call(this),(t.has("contentMaxWidth")||t.has("contentHeight")||t.has("toggleHeightMode")||t.has("variant"))&&c(this,l,D).call(this),(t.has("selectedChip")||t.has("variant")||t.has("contentMaxWidth")||t.has("contentHeight")||t.has("toggleHeightMode"))&&c(this,l,M).call(this),(t.has("selectedChip")||t.has("variant"))&&this._seriesDifferentiationEnabled&&requestAnimationFrame(()=>{c(this,l,$).call(this)}),(t.has("valueFormat")||t.has("timeFormat")||t.has("yAxisSettings")||t.has("selectedChip")||t.has("variant"))&&c(this,l,k).call(this)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("pointerdown",this._onDocumentPointerDown,!0),document.removeEventListener("keydown",this._onDocumentKeyDown),c(this,l,F).call(this),c(this,l,I).call(this),c(this,l,N).call(this)}_onTableSlotChange(t){const e=t.target;e&&(this._readTableDataFromSlot(e),this.requestUpdate())}_onDiagramSlotChange(){c(this,l,D).call(this),c(this,l,M).call(this),c(this,l,k).call(this),this._seriesDifferentiationEnabled&&requestAnimationFrame(()=>{c(this,l,$).call(this)}),this.requestUpdate()}_normalizeRenderableCell(t){return t&&typeof t=="object"&&"html"in t&&"text"in t?{html:typeof t.html=="string"?t.html:"",text:typeof t.text=="string"?t.text:""}:{html:"",text:t==null?"":String(t)}}_readTableDataFromSlot(t){const e=t||this.shadowRoot?.querySelector('slot[name="table"]');if(!e)return;const i=e.assignedElements({flatten:!0}),n=[];i.forEach(d=>{if(d.tagName==="TABLE"){n.push(d);return}d.querySelectorAll("table").forEach(y=>n.push(y))});const s=n[0];if(!s){this._slottedTableData=void 0;return}const o=[],a=[],r=[],h=d=>d?(d.textContent??"").replace(/\s+/g," ").trim():"",p=d=>d?{html:(d.innerHTML??"").trim(),text:h(d)}:{html:"",text:""},b=s.querySelector("thead tr");b&&Array.from(b.querySelectorAll("th, td")).forEach(y=>o.push(p(y)));const _=Array.from(s.querySelectorAll("tbody tr")),w=_.length>0?_:Array.from(s.querySelectorAll("tr")).filter(d=>d.closest("thead")===null);if(w.forEach(d=>{const y=Array.from(d.querySelectorAll("th, td"));if(y.length===0)return;const z=y[0].tagName==="TH"&&d.closest("thead")===null&&d.closest("tfoot")===null;r.push(z);const S=[];y.forEach(C=>S.push(p(C))),a.push(S)}),!b&&a.length>0){const d=a[0],y=w[0],z=Array.from(y?.querySelectorAll("th, td")??[]);z.length>0&&z.every(C=>C.tagName==="TH")&&y?.closest("tbody")===null&&(o.splice(0,o.length,...d),a.shift(),r.shift())}this._slottedTableData={headers:o.length>0?o:void 0,rows:a,rowHeaderRows:r.length>0?r:void 0}}_inferTableAlignments(t){const e=Math.max(t.headers?.length??0,...t.rows.map(s=>s.length)),i=s=>{if(s==null)return!1;if(typeof s=="number")return!0;const o=String(s).replace(/[\u00A0\u202F\s]+/g,"").trim();return o?/^-?\d+(?:[.,]\d+)?$/.test(o):!1},n=[];for(let s=0;s<e;s+=1){if(s===0){n.push("left");continue}const o=t.rows.map(r=>this._normalizeRenderableCell(r[s]).text).filter(r=>r!==""&&r!==null&&r!==void 0),a=o.length>0&&o.every(i);n.push(a?"right":"left")}return n}_getResolvedContentMaxWidth(){return this.contentMaxWidth?.trim()||""}_getResolvedDiagramHeight(){return this.contentHeight?.trim()||""}_getResolvedToggleHeightMode(){return this.toggleHeightMode==="auto"?"auto":"stable"}_getResolvedStandardContentHeight(){return this._getResolvedDiagramHeight()||"420px"}_getResolvedTableData(){return this.tableData??this._slottedTableData}_getDiagramAssignedElements(){const t=this.shadowRoot?.querySelector('slot[name="diagram"]');return t?t.assignedElements({flatten:!0}):[]}_findExportableVisualElement(t){for(const e of t){if(e instanceof SVGSVGElement||e instanceof HTMLCanvasElement||e instanceof HTMLImageElement)return e;const i=e.querySelector("svg, canvas, img");if(i instanceof SVGSVGElement||i instanceof HTMLCanvasElement||i instanceof HTMLImageElement)return i}return null}_getExportableVisualElement(){if(this.variant==="Table")return null;if(this.variant==="Image"){const t=this.shadowRoot?.querySelector(".image-content img");return t instanceof HTMLImageElement?t:null}return this._findExportableVisualElement(this._getDiagramAssignedElements())}_getDefaultValueFormat(){return{type:"number",scale:"auto",decimals:0}}_normalizeValueFormat(t){const e=this._getDefaultValueFormat(),i=t&&typeof t=="object"?t:{},n=["number","currency","percent"].includes(String(i.type))?String(i.type):e.type,s=["auto","raw","thousands","millions","billions"].includes(String(i.scale))?String(i.scale):e.scale,o=Number.isFinite(Number(i.decimals))?Math.max(0,Math.min(20,Number(i.decimals))):e.decimals;return{type:n,scale:s,decimals:o}}_normalizeTimeFormat(t){const e={mode:"raw",display:"raw"},i=t&&typeof t=="object"?t:{},n=["raw","year","monthCode","quarterCode","weekCode","tertialCode"];let s=typeof i.mode=="string"?i.mode:e.mode,o=typeof i.display=="string"?i.display:e.display;n.includes(s)||(s=e.mode);const a={raw:["raw"],year:["raw","year"],monthCode:["raw","iso-month","short-month","long-month"],quarterCode:["raw","quarter-compact","quarter-short","quarter-long"],weekCode:["raw","week-compact","week-long"],tertialCode:["raw","tertial-compact","tertial-short","tertial-long"]};return a[s].includes(o)||(o=a[s][0]),s==="raw"&&(o="raw"),{mode:s,display:o}}_normalizeYAxisSettings(t){const e=t&&typeof t=="object"?t:{},i=Number.isFinite(Number(e.referenceLineValue))?Number(e.referenceLineValue):null;return{startAtZero:!!e.startAtZero,referenceLineEnabled:!!e.referenceLineEnabled&&Number.isFinite(i),referenceLineValue:i,referenceLineLabel:typeof e.referenceLineLabel=="string"?e.referenceLineLabel:""}}_getShortMonthNames(){return["jan","feb","mar","apr","maj","jun","jul","aug","sep","okt","nov","dec"]}_getLongMonthNames(){return["januari","februari","mars","april","maj","juni","juli","augusti","september","oktober","november","december"]}_formatCategoryTimeLabel(t,e){if(!t||e.mode==="raw"||e.display==="raw")return null;if(e.mode==="year"){const i=/^\s*(\d{4})\s*$/.exec(t);return i?i[1]:null}if(e.mode==="monthCode"){const i=/^\s*(\d{4})M(0?[1-9]|1[0-2])\s*$/i.exec(t);if(!i)return null;const n=Number(i[2])-1,s=i[1],o=String(n+1).padStart(2,"0");return e.display==="iso-month"?`${s}-${o}`:e.display==="short-month"?`${this._getShortMonthNames()[n]} ${s}`:e.display==="long-month"?`${this._getLongMonthNames()[n]} ${s}`:t}if(e.mode==="quarterCode"){const i=/^\s*(\d{4})(?:K(V)?|Q)(0?[1-4])\s*$/i.exec(t);if(!i)return null;const n=Number(i[3]),s=i[1],o=["första","andra","tredje","fjärde"];return e.display==="quarter-compact"?`${s} K${n}`:e.display==="quarter-short"?`kv ${n} ${s}`:e.display==="quarter-long"?`${o[n-1]} kvartalet ${s}`:t}if(e.mode==="weekCode"){const i=/^\s*(\d{4})(?:V|W)(0?[1-9]|[1-4][0-9]|5[0-3])\s*$/i.exec(t);if(!i)return null;const n=Number(i[2]),s=i[1];return e.display==="week-compact"?`${s} v. ${n}`:e.display==="week-long"?`vecka ${n} ${s}`:t}if(e.mode==="tertialCode"){const i=/^\s*(\d{4})T(0?[1-3])\s*$/i.exec(t);if(!i)return null;const n=Number(i[2]),s=i[1],o=["första","andra","tredje"];return e.display==="tertial-compact"?`${s} T${n}`:e.display==="tertial-short"?`tertial ${n} ${s}`:e.display==="tertial-long"?`${o[n-1]} tertialet ${s}`:t}return null}_formatLocalizedNumber(t,e){return new Intl.NumberFormat(this.lang==="en"?"en-GB":"sv-SE",{minimumFractionDigits:e,maximumFractionDigits:e}).format(t)}_formatValueForDisplay(t,e,i){if(!Number.isFinite(t))return null;const n={raw:1,thousands:1e3,millions:1e6,billions:1e9},s={raw:"",thousands:this.lang==="en"?"k":"t",millions:this.lang==="en"?"M":"mn",billions:this.lang==="en"?"B":"md"};let o=e.scale;if(o==="auto"){const p=Math.abs(t);p>=1e9?o="billions":p>=1e6?o="millions":p>=1e3?o="thousands":o="raw"}const a=t/(n[o]||1);let r=this._formatLocalizedNumber(a,e.decimals);e.type==="percent"?r=`${r} %`:e.type==="currency"&&(r=i?`${r} kr`:r);const h=s[o]||"";return h&&(r=`${r} ${h}`),r}_isCategoryAxis(t){return t?.categories?.length>0||t?.options?.type==="category"}_applyTimeFormatToLiveChart(t){const e=this._normalizeTimeFormat(this.timeFormat);if(e.mode==="raw"||e.display==="raw")return;const i=this._formatCategoryTimeLabel.bind(this);[...t?.xAxis||[],...t?.yAxis||[]].forEach(n=>{if(!this._isCategoryAxis(n))return;const s=n.options?.labels&&typeof n.options.labels=="object"?{...n.options.labels}:{},o=typeof s.formatter=="function"?s.formatter:null;s.formatter=function(){let a="";if(this?.axis&&Array.isArray(this.axis.categories)&&typeof this.pos=="number"){const h=this.axis.categories[this.pos];typeof h<"u"&&h!==null&&(a=String(h))}else typeof this?.value<"u"&&this.value!==null&&(a=String(this.value));const r=i(a,e);return r!==null?r:o?o.call(this):a},delete s.format,n.update({labels:s},!1)})}_applyValueFormatToLiveChart(t){const e=this._normalizeValueFormat(this.valueFormat),i=this._formatValueForDisplay.bind(this);t.update({tooltip:{...t.options?.tooltip||{},valueDecimals:e.decimals,formatter:function(){const n=Array.isArray(this.points)&&this.points.length?this.points:[this.point||this];let s="";const o=[];return typeof this.x<"u"&&this.x!==null?s=`<span>${String(this.x)}</span><br/>`:typeof this.key<"u"&&this.key!==null&&(s=`<span>${String(this.key)}</span><br/>`),n.forEach(a=>{const r=a?.point||a,h=Number.isFinite(a?.y)?a.y:r?.y,p=i(h,e,!0);if(p===null)return;const b=r?.name||r?.series?.name||"";o.push(`${b?`${String(b)}: `:""}<b>${p}</b><br/>`)}),s+o.join("")}},plotOptions:{...t.options?.plotOptions||{},series:{...t.options?.plotOptions?.series||{},dataLabels:{...t.options?.plotOptions?.series?.dataLabels||{},formatter:function(){const n=Number.isFinite(this?.y)?this.y:this?.point?.y;return i(n,e,e.type==="percent")??null}}}}},!1,!1,!1),(t?.yAxis||[]).forEach(n=>{const s=n.options?.labels&&typeof n.options.labels=="object"?{...n.options.labels}:{},o=typeof s.formatter=="function"?s.formatter:null,a=!(n.options?.title&&typeof n.options.title.text=="string"&&n.options.title.text.trim());s.formatter=function(){const r=i(this?.value,e,a);return r!==null?r:o?o.call(this):this?.value},(e.type==="percent"||e.scale!=="auto")&&delete s.format,n.update({labels:s},!1)})}_applyYAxisSettingsToLiveChart(t){const e=this._normalizeYAxisSettings(this.yAxisSettings),i=t?.yAxis||[];i.length&&i.forEach((n,s)=>{const o=n.options&&typeof n.options=="object"?n.options:{},a={},r=typeof o.min<"u"&&o.min!==null&&o.min!=="";s===0&&e.startAtZero&&!r&&(a.min=0);const h=Array.isArray(o.plotLines)?o.plotLines.filter(p=>p?.id!=="scb-viz-reference-line"):[];s===0&&e.referenceLineEnabled&&Number.isFinite(e.referenceLineValue)&&h.push({id:"scb-viz-reference-line",className:"scb-axis-plotline scb-viz-reference-line",value:e.referenceLineValue,label:e.referenceLineLabel?{text:e.referenceLineLabel,className:"scb-viz-reference-line-label"}:void 0}),h.length?a.plotLines=h:Array.isArray(o.plotLines)&&(a.plotLines=[]),n.update(a,!1)})}_getCurrentHighchartsChart(){if(this._getCurrentPrintableView()!=="diagram")return;const t=c(this,l,j).call(this,this._getDiagramAssignedElements());return t===void 0?void 0:window.Highcharts?.charts?.[t]}_getSeriesDifferentiationGroup(t,e){const i=String(t?.type||t?.options?.type||e?.options?.chart?.type||"").trim().toLowerCase();return["line","spline","scatter"].includes(i)?"line":["area","areaspline"].includes(i)?"area":["column","bar"].includes(i)?"fill":["pie","variablepie"].includes(i)?"point-fill":null}_shouldShowSeriesDifferentiationAction(){if(this._getCurrentPrintableView()!=="diagram")return!1;const t=this._getCurrentHighchartsChart();return!t?.series?.length||!this._isHighchartsStyledMode(t)?!1:t.series.some(e=>this._getSeriesDifferentiationGroup(e,t)!==null)}_getSeriesDifferentiationSnapshotStore(t){let e=this._seriesDifferentiationSnapshots.get(t);return e||(e=new Map,this._seriesDifferentiationSnapshots.set(t,e)),e}_cloneSeriesOptionValue(t){return Array.isArray(t)?t.map(e=>this._cloneSeriesOptionValue(e)):t&&typeof t=="object"?Object.fromEntries(Object.entries(t).map(([e,i])=>[e,this._cloneSeriesOptionValue(i)])):t}_captureSeriesDifferentiationSnapshot(t){const e=this._cloneSeriesOptionValue(t?.options?.marker);return{marker:e&&Object.keys(e).length>0?e:{enabled:!1}}}_getHighchartsSvgElement(t){const e=t?.element??t;return e instanceof SVGElement?e:null}_isHighchartsStyledMode(t){return!!(t?.styledMode||t?.renderer?.styledMode||t?.options?.chart?.styledMode)}_getHighchartsSvgRoot(t){if(t?.container instanceof SVGSVGElement)return t.container;const e=t?.renderTo?.querySelector("svg")??t?.container?.querySelector?.("svg");return e instanceof SVGSVGElement?e:null}_getHighchartsColorClassName(t,e){const i=this._getHighchartsSvgElement(t);return Array.from(i?.classList??[]).find(s=>/^highcharts-color-\d+$/.test(s))??`highcharts-color-${e}`}_setSeriesDifferentiationMetadata(t,e){const i=this._getHighchartsSvgElement(t);i&&(i.setAttribute("data-scb-viz-role",e.role),e.dashStyle?i.setAttribute("data-scb-viz-dash-style",e.dashStyle):i.removeAttribute("data-scb-viz-dash-style"),e.patternKind?i.setAttribute("data-scb-viz-pattern-kind",e.patternKind):i.removeAttribute("data-scb-viz-pattern-kind"))}_clearSeriesDifferentiationMetadata(t){const e=this._getHighchartsSvgElement(t);e&&(e.removeAttribute("data-scb-viz-role"),e.removeAttribute("data-scb-viz-dash-style"),e.removeAttribute("data-scb-viz-pattern-kind"))}_setSeriesDifferentiationColorClass(t,e){const i=this._getHighchartsSvgElement(t);if(!i||!e)return;const n=Array.from(i.classList).find(s=>/^highcharts-color-\d+$/.test(s));n!==e&&(n&&(i.classList.remove(n),i.setAttribute("data-scb-viz-prev-color-class",n)),i.classList.add(e),i.setAttribute("data-scb-viz-added-color-class",e))}_clearSeriesDifferentiationColorClass(t){const e=this._getHighchartsSvgElement(t);if(!e)return;const i=e.getAttribute("data-scb-viz-added-color-class"),n=e.getAttribute("data-scb-viz-prev-color-class");i&&(e.classList.remove(i),e.removeAttribute("data-scb-viz-added-color-class")),n&&(e.classList.add(n),e.removeAttribute("data-scb-viz-prev-color-class"))}_getLegendSeriesDifferentiationTargets(t){const e=[],i=[],n=this._getHighchartsSvgElement(t?.legendItem?.group),s=(a,r)=>{const h=this._getHighchartsSvgElement(r);!h||a.includes(h)||a.push(h)};if(s(e,t?.legendLine),s(e,t?.legendItem?.line),s(i,t?.legendSymbol),s(i,t?.legendItem?.symbol),s(i,t?.legendArea),s(i,t?.legendItem?.area),n){const a=n.querySelector(".highcharts-graph, .highcharts-legend-graph, line, path");a&&s(e,a),n.querySelectorAll("rect, circle, .highcharts-point, .highcharts-area, .highcharts-legend-symbol, path").forEach(r=>{s(i,r)})}const o=i.filter(a=>!e.includes(a));return{graphTargets:e,fillTargets:o}}_ensureStyledModeSeriesPattern(t,e,i){const n=this._getHighchartsSvgRoot(t);if(!n)return;const s="http://www.w3.org/2000/svg";let o=n.querySelector("defs");o instanceof SVGDefsElement||(o=document.createElementNS(s,"defs"),n.insertBefore(o,n.firstChild));const a=`scb-viz-pattern-${e}-${i}`;if(o.querySelector(`#${a}`))return;const r=document.createElementNS(s,"pattern");r.setAttribute("id",a),r.setAttribute("patternUnits","userSpaceOnUse"),r.setAttribute("width","10"),r.setAttribute("height","10"),r.classList.add(e);const h=document.createElementNS(s,"rect");h.setAttribute("x","0"),h.setAttribute("y","0"),h.setAttribute("width","10"),h.setAttribute("height","10"),h.setAttribute("class","scb-viz-highcharts-pattern__background"),r.appendChild(h),ft(r,s,i),o.appendChild(r)}_applyStyledModeSeriesDifferentiation(t){const e=this._getHighchartsSvgRoot(t);if(!e)return;e.classList.add("scb-viz-series-differentiation-enabled");const i=ut(),n=this._getSeriesDifferentiationSnapshotStore(t);t.series?.forEach((s,o)=>{const a=this._getSeriesDifferentiationGroup(s,t);if(!a)return;const r=String(s?.index??o);n.has(r)||n.set(r,this._captureSeriesDifferentiationSnapshot(s));const{dashStyle:h,markerSymbol:p,patternKind:b}=mt(o),_=this._getHighchartsColorClassName(s?.graph??s?.area??s?.group,o),w=this._getLegendSeriesDifferentiationTargets(s);this._setSeriesDifferentiationMetadata(s?.graph,{role:"graph",dashStyle:h}),a==="area"&&(this._setSeriesDifferentiationMetadata(s?.area,{role:"area",patternKind:b}),this._setSeriesDifferentiationColorClass(s?.area,_),this._ensureStyledModeSeriesPattern(t,_,b)),a==="fill"&&(s.points?.forEach(d=>{this._setSeriesDifferentiationMetadata(d?.graphic,{role:"fill",patternKind:b}),this._setSeriesDifferentiationColorClass(d?.graphic,_)}),this._ensureStyledModeSeriesPattern(t,_,b)),a==="point-fill"&&s.points?.forEach((d,y)=>{const z=i[y%i.length],S=this._getHighchartsColorClassName(d?.graphic??d?.legendSymbol??d?.legendItem?.symbol??d?.legendItem?.group,y),C=this._getLegendSeriesDifferentiationTargets(d);this._setSeriesDifferentiationMetadata(d?.graphic,{role:"fill",patternKind:z}),this._setSeriesDifferentiationColorClass(d?.graphic,S),this._ensureStyledModeSeriesPattern(t,S,z),C.fillTargets.forEach(G=>{this._setSeriesDifferentiationMetadata(G,{role:"legend-fill",patternKind:z}),this._setSeriesDifferentiationColorClass(G,S)})}),(a==="line"||a==="area")&&w.graphTargets.forEach(d=>{this._setSeriesDifferentiationMetadata(d,{role:"legend-symbol",dashStyle:h})}),(a==="area"||a==="fill")&&w.fillTargets.forEach(d=>{this._setSeriesDifferentiationMetadata(d,{role:"legend-fill",patternKind:b}),this._setSeriesDifferentiationColorClass(d,_)}),(a==="line"||a==="area")&&s.update({marker:{enabled:!0,symbol:p}},!1)}),t.redraw(!1)}_restoreStyledModeSeriesDifferentiation(t){this._getHighchartsSvgRoot(t)?.classList.remove("scb-viz-series-differentiation-enabled");const i=this._getSeriesDifferentiationSnapshotStore(t);t.series?.forEach((n,s)=>{const o=this._getSeriesDifferentiationGroup(n,t);if(!o)return;const a=this._getLegendSeriesDifferentiationTargets(n);if(this._clearSeriesDifferentiationMetadata(n?.graph),this._clearSeriesDifferentiationMetadata(n?.area),this._clearSeriesDifferentiationColorClass(n?.area),n.points?.forEach(r=>{const h=this._getLegendSeriesDifferentiationTargets(r);this._clearSeriesDifferentiationMetadata(r?.graphic),this._clearSeriesDifferentiationColorClass(r?.graphic),h.graphTargets.forEach(p=>{this._clearSeriesDifferentiationMetadata(p)}),h.fillTargets.forEach(p=>{this._clearSeriesDifferentiationMetadata(p),this._clearSeriesDifferentiationColorClass(p)})}),a.graphTargets.forEach(r=>{this._clearSeriesDifferentiationMetadata(r)}),a.fillTargets.forEach(r=>{this._clearSeriesDifferentiationMetadata(r),this._clearSeriesDifferentiationColorClass(r)}),o==="line"||o==="area"){const r=i.get(String(n?.index??s));n.update({marker:this._cloneSeriesOptionValue(r?.marker)},!1)}}),t.redraw(!1)}_canExportRaster(){return this._getExportableVisualElement()!==null}_canExportCsv(){return!!this._getResolvedTableData()?.rows?.length}_getExportBaseFileName(){const t=this.lang==="en"?"visualization":"visualisering";return(this.title||t).normalize("NFD").replace(/[\u0300-\u036f]/g,"").toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")||t}_buildExportFileName(t){const e=t==="csv"?this.lang==="en"?"-table":"-tabell":"";return`${this._getExportBaseFileName()}${e}.${t}`}_renderActionsMenu(){const t=this._getCurrentPrintableView(),e=this._canExportRaster(),i=this._canExportCsv(),n=e&&(t==="diagram"||t==="image"),s=i&&t==="table",o=this._shouldShowSeriesDifferentiationAction();return g`
116
+ `;let g=class extends dt{constructor(){super(...arguments),_t(this,l),this.variant="Standard",this.selectedChip="Diagram",this.title="",this.subtitle="",this.description="",this.comment="",this.source="",this.footnote="",this.lang="sv",this.imageHref="",this.officialStatistics=!1,this.disableToggle=!1,this.contentMaxWidth="",this.containerMaxWidth="",this.contentHeight="",this.toggleHeightMode="stable",this._actionsMenuOpen=!1,this._seriesDifferentiationEnabled=!1,this._seriesDifferentiationSnapshots=new WeakMap,this._diagramReflowFrame=0,this._chartConfigSyncFrame=0,this.spacing=void 0,this.spacingTop=void 0,this.spacingBottom=void 0,this.spacingLeft=void 0,this.spacingRight=void 0,this._onDocumentPointerDown=t=>{if(!this._actionsMenuOpen)return;const e=t.composedPath(),i=this.shadowRoot?.querySelector(".actions-menu");i&&e.includes(i)||this._closeActionsMenu()},this._onDocumentKeyDown=t=>{this._actionsMenuOpen&&t.key==="Escape"&&(t.preventDefault(),this._closeActionsMenu(),this._focusMenuButton())},this._onPrintClick=async()=>{this._closeActionsMenu(),await c(this,l,it).call(this)},this._onDownloadPngClick=async()=>{this._canExportRaster()&&(this._closeActionsMenu(),await c(this,l,E).call(this,"png"))},this._onDownloadJpgClick=async()=>{this._canExportRaster()&&(this._closeActionsMenu(),await c(this,l,E).call(this,"jpeg"))},this._onDownloadCsvClick=()=>{this._canExportCsv()&&(this._closeActionsMenu(),c(this,l,st).call(this))},this._onToggleSeriesDifferentiationClick=()=>{this._seriesDifferentiationEnabled=!this._seriesDifferentiationEnabled,this._closeActionsMenu(),c(this,l,$).call(this)}}get descriptionLabel(){return this.lang==="en"?"Description of the chart":"Beskrivning av diagrammet"}get moreAboutStatsLabel(){return this.lang==="en"?"More about the statistics":"Mer om statistiken"}get commentLabel(){return this.lang==="en"?"Comments":"Kommentar"}get sourceLabel(){return this.lang==="en"?"Source":"Källa"}get footnoteLabel(){return this.lang==="en"?"Footnotes":"Fotnot"}get officialStatisticsLabel(){return this.lang==="en"?"Official statistics of Sweden":"Sveriges officiella statistik"}get officialStatisticsTitle(){return this.lang==="en"?"Part of Official statistics of Sweden":"Tillhör Sveriges officiella statistik"}get officialStatisticsAlt(){return this.lang==="en"?"Read more about Official statistics of Sweden":"Läs mer om Sveriges officiella statistik"}get actionsMenuLabel(){return this.lang==="en"?"Open menu":"Öppna meny"}get printLabel(){return this.lang==="en"?"Print":"Skriv ut"}get downloadPngLabel(){return this.lang==="en"?"Download PNG":"Ladda ner PNG"}get downloadJpgLabel(){return this.lang==="en"?"Download JPG":"Ladda ner JPG"}get downloadCsvLabel(){return this.lang==="en"?"Download CSV":"Ladda ner CSV"}get enableSeriesDifferentiationLabel(){return this.lang==="en"?"Show symbols and patterns":"Visa symboler och mönster"}get disableSeriesDifferentiationLabel(){return this.lang==="en"?"Hide symbols and patterns":"Dölj symboler och mönster"}_getImageAltText(){return[this.title,this.subtitle,this.description].map(e=>typeof e=="string"?e.trim():"").filter(Boolean).join(". ")||(this.lang==="en"?"Image figure":"Bildfigur")}connectedCallback(){super.connectedCallback(),document.addEventListener("pointerdown",this._onDocumentPointerDown,!0),document.addEventListener("keydown",this._onDocumentKeyDown)}firstUpdated(t){this._readTableDataFromSlot(),c(this,l,H).call(this),c(this,l,V).call(this),c(this,l,D).call(this),this._syncChipClass(),c(this,l,L).call(this),c(this,l,M).call(this)}updated(t){super.updated(t),(t.has("selectedChip")||t.has("variant"))&&(this._syncChipClass(),this._closeActionsMenu()),t.has("selectedChip")&&this._dispatchSelectedChipChanged(),(t.has("spacing")||t.has("spacingTop")||t.has("spacingBottom")||t.has("spacingLeft")||t.has("spacingRight"))&&c(this,l,H).call(this),t.has("containerMaxWidth")&&c(this,l,V).call(this),t.has("variant")&&c(this,l,L).call(this),(t.has("contentMaxWidth")||t.has("contentHeight")||t.has("toggleHeightMode")||t.has("variant"))&&c(this,l,D).call(this),(t.has("selectedChip")||t.has("variant")||t.has("contentMaxWidth")||t.has("contentHeight")||t.has("toggleHeightMode"))&&c(this,l,M).call(this),(t.has("selectedChip")||t.has("variant"))&&this._seriesDifferentiationEnabled&&requestAnimationFrame(()=>{c(this,l,$).call(this)}),(t.has("valueFormat")||t.has("timeFormat")||t.has("yAxisSettings")||t.has("selectedChip")||t.has("variant"))&&c(this,l,k).call(this)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("pointerdown",this._onDocumentPointerDown,!0),document.removeEventListener("keydown",this._onDocumentKeyDown),c(this,l,F).call(this),c(this,l,N).call(this),c(this,l,j).call(this)}_onTableSlotChange(t){const e=t.target;e&&(this._readTableDataFromSlot(e),this.requestUpdate())}_onDiagramSlotChange(){c(this,l,D).call(this),c(this,l,M).call(this),c(this,l,k).call(this),this._seriesDifferentiationEnabled&&requestAnimationFrame(()=>{c(this,l,$).call(this)}),this.requestUpdate()}_normalizeRenderableCell(t){return t&&typeof t=="object"&&"html"in t&&"text"in t?{html:typeof t.html=="string"?t.html:"",text:typeof t.text=="string"?t.text:""}:{html:"",text:t==null?"":String(t)}}_readTableDataFromSlot(t){const e=t||this.shadowRoot?.querySelector('slot[name="table"]');if(!e)return;const i=e.assignedElements({flatten:!0}),a=[];i.forEach(p=>{if(p.tagName==="TABLE"){a.push(p);return}p.querySelectorAll("table").forEach(y=>a.push(y))});const s=a[0];if(!s){this._slottedTableData=void 0;return}const r=[],n=[],o=[],h=p=>p?(p.textContent??"").replace(/\s+/g," ").trim():"",d=p=>p?{html:(p.innerHTML??"").trim(),text:h(p)}:{html:"",text:""},b=s.querySelector("thead tr");b&&Array.from(b.querySelectorAll("th, td")).forEach(y=>r.push(d(y)));const _=Array.from(s.querySelectorAll("tbody tr")),w=_.length>0?_:Array.from(s.querySelectorAll("tr")).filter(p=>p.closest("thead")===null);if(w.forEach(p=>{const y=Array.from(p.querySelectorAll("th, td"));if(y.length===0)return;const z=y[0].tagName==="TH"&&p.closest("thead")===null&&p.closest("tfoot")===null;o.push(z);const S=[];y.forEach(C=>S.push(d(C))),n.push(S)}),!b&&n.length>0){const p=n[0],y=w[0],z=Array.from(y?.querySelectorAll("th, td")??[]);z.length>0&&z.every(C=>C.tagName==="TH")&&y?.closest("tbody")===null&&(r.splice(0,r.length,...p),n.shift(),o.shift())}this._slottedTableData={headers:r.length>0?r:void 0,rows:n,rowHeaderRows:o.length>0?o:void 0}}_inferTableAlignments(t){const e=Math.max(t.headers?.length??0,...t.rows.map(s=>s.length)),i=s=>{if(s==null)return!1;if(typeof s=="number")return!0;const r=String(s).replace(/[\u00A0\u202F\s]+/g,"").trim();return r?/^-?\d+(?:[.,]\d+)?$/.test(r):!1},a=[];for(let s=0;s<e;s+=1){if(s===0){a.push("left");continue}const r=t.rows.map(o=>this._normalizeRenderableCell(o[s]).text).filter(o=>o!==""&&o!==null&&o!==void 0),n=r.length>0&&r.every(i);a.push(n?"right":"left")}return a}_getResolvedContentMaxWidth(){return this.contentMaxWidth?.trim()||""}_getResolvedDiagramHeight(){return this.contentHeight?.trim()||""}_getResolvedDiagramScrollerWidth(){return this._getResolvedContentMaxWidth()||"720px"}_getResolvedToggleHeightMode(){return this.toggleHeightMode==="auto"?"auto":"stable"}_getResolvedStandardContentHeight(){return this._getResolvedDiagramHeight()||"600px"}_getResolvedTableData(){return this.tableData??this._slottedTableData}_getDiagramAssignedElements(){const t=this.shadowRoot?.querySelector('slot[name="diagram"]');return t?t.assignedElements({flatten:!0}):[]}_findExportableVisualElement(t){for(const e of t){if(e instanceof SVGSVGElement||e instanceof HTMLCanvasElement||e instanceof HTMLImageElement)return e;const i=e.querySelector("svg, canvas, img");if(i instanceof SVGSVGElement||i instanceof HTMLCanvasElement||i instanceof HTMLImageElement)return i}return null}_getExportableVisualElement(){if(this.variant==="Table")return null;if(this.variant==="Image"){const t=this.shadowRoot?.querySelector(".image-content img");return t instanceof HTMLImageElement?t:null}return this._findExportableVisualElement(this._getDiagramAssignedElements())}_getDefaultValueFormat(){return{type:"number",scale:"auto",decimals:0}}_normalizeValueFormat(t){const e=this._getDefaultValueFormat(),i=t&&typeof t=="object"?t:{},a=["number","currency","percent"].includes(String(i.type))?String(i.type):e.type,s=["auto","raw","thousands","millions","billions"].includes(String(i.scale))?String(i.scale):e.scale,r=Number.isFinite(Number(i.decimals))?Math.max(0,Math.min(20,Number(i.decimals))):e.decimals;return{type:a,scale:s,decimals:r}}_normalizeTimeFormat(t){const e={mode:"raw",display:"raw"},i=t&&typeof t=="object"?t:{},a=["raw","year","monthCode","quarterCode","weekCode","tertialCode"];let s=typeof i.mode=="string"?i.mode:e.mode,r=typeof i.display=="string"?i.display:e.display;a.includes(s)||(s=e.mode);const n={raw:["raw"],year:["raw","year"],monthCode:["raw","iso-month","short-month","long-month"],quarterCode:["raw","quarter-compact","quarter-short","quarter-long"],weekCode:["raw","week-compact","week-long"],tertialCode:["raw","tertial-compact","tertial-short","tertial-long"]};return n[s].includes(r)||(r=n[s][0]),s==="raw"&&(r="raw"),{mode:s,display:r}}_normalizeYAxisSettings(t){const e=t&&typeof t=="object"?t:{},i=Number.isFinite(Number(e.referenceLineValue))?Number(e.referenceLineValue):null;return{startAtZero:!!e.startAtZero,referenceLineEnabled:!!e.referenceLineEnabled&&Number.isFinite(i),referenceLineValue:i,referenceLineLabel:typeof e.referenceLineLabel=="string"?e.referenceLineLabel:""}}_getShortMonthNames(){return["jan","feb","mar","apr","maj","jun","jul","aug","sep","okt","nov","dec"]}_getLongMonthNames(){return["januari","februari","mars","april","maj","juni","juli","augusti","september","oktober","november","december"]}_formatCategoryTimeLabel(t,e){if(!t||e.mode==="raw"||e.display==="raw")return null;if(e.mode==="year"){const i=/^\s*(\d{4})\s*$/.exec(t);return i?i[1]:null}if(e.mode==="monthCode"){const i=/^\s*(\d{4})M(0?[1-9]|1[0-2])\s*$/i.exec(t);if(!i)return null;const a=Number(i[2])-1,s=i[1],r=String(a+1).padStart(2,"0");return e.display==="iso-month"?`${s}-${r}`:e.display==="short-month"?`${this._getShortMonthNames()[a]} ${s}`:e.display==="long-month"?`${this._getLongMonthNames()[a]} ${s}`:t}if(e.mode==="quarterCode"){const i=/^\s*(\d{4})(?:K(V)?|Q)(0?[1-4])\s*$/i.exec(t);if(!i)return null;const a=Number(i[3]),s=i[1],r=["första","andra","tredje","fjärde"];return e.display==="quarter-compact"?`${s} K${a}`:e.display==="quarter-short"?`kv ${a} ${s}`:e.display==="quarter-long"?`${r[a-1]} kvartalet ${s}`:t}if(e.mode==="weekCode"){const i=/^\s*(\d{4})(?:V|W)(0?[1-9]|[1-4][0-9]|5[0-3])\s*$/i.exec(t);if(!i)return null;const a=Number(i[2]),s=i[1];return e.display==="week-compact"?`${s} v. ${a}`:e.display==="week-long"?`vecka ${a} ${s}`:t}if(e.mode==="tertialCode"){const i=/^\s*(\d{4})T(0?[1-3])\s*$/i.exec(t);if(!i)return null;const a=Number(i[2]),s=i[1],r=["första","andra","tredje"];return e.display==="tertial-compact"?`${s} T${a}`:e.display==="tertial-short"?`tertial ${a} ${s}`:e.display==="tertial-long"?`${r[a-1]} tertialet ${s}`:t}return null}_formatLocalizedNumber(t,e){return new Intl.NumberFormat(this.lang==="en"?"en-GB":"sv-SE",{minimumFractionDigits:e,maximumFractionDigits:e}).format(t)}_formatValueForDisplay(t,e,i){if(!Number.isFinite(t))return null;const a={raw:1,thousands:1e3,millions:1e6,billions:1e9},s={raw:"",thousands:this.lang==="en"?"k":"t",millions:this.lang==="en"?"M":"mn",billions:this.lang==="en"?"B":"md"};let r=e.scale;if(r==="auto"){const d=Math.abs(t);d>=1e9?r="billions":d>=1e6?r="millions":d>=1e3?r="thousands":r="raw"}const n=t/(a[r]||1);let o=this._formatLocalizedNumber(n,e.decimals);e.type==="percent"?o=`${o} %`:e.type==="currency"&&(o=i?`${o} kr`:o);const h=s[r]||"";return h&&(o=`${o} ${h}`),o}_isCategoryAxis(t){return t?.categories?.length>0||t?.options?.type==="category"}_getTooltipXAxisLabel(t,e){const i=t?.point||t,a=i?.series?.xAxis||t?.series?.xAxis;let s="";if(a&&Array.isArray(a.categories)){const r=Number.isFinite(i?.x)?Number(i.x):Number.isFinite(t?.x)?Number(t.x):null;if(r!==null){const n=a.categories[r];typeof n<"u"&&n!==null&&(s=String(n))}}return!s&&typeof i?.category=="string"&&i.category.trim()&&Number.isNaN(Number(i.category))&&(s=i.category),!s&&typeof t?.key=="string"&&t.key.trim()&&Number.isNaN(Number(t.key))&&(s=t.key),!s&&typeof t?.x=="string"&&t.x.trim()&&Number.isNaN(Number(t.x))&&(s=t.x),s?this._formatCategoryTimeLabel(s,e)??s:""}_applyTimeFormatToLiveChart(t){const e=this._normalizeTimeFormat(this.timeFormat);if(e.mode==="raw"||e.display==="raw")return;const i=this._formatCategoryTimeLabel.bind(this);[...t?.xAxis||[],...t?.yAxis||[]].forEach(a=>{if(!this._isCategoryAxis(a))return;const s=a.options?.labels&&typeof a.options.labels=="object"?{...a.options.labels}:{},r=typeof s.formatter=="function"?s.formatter:null;s.formatter=function(){let n="";if(this?.axis&&Array.isArray(this.axis.categories)&&typeof this.pos=="number"){const h=this.axis.categories[this.pos];typeof h<"u"&&h!==null&&(n=String(h))}else typeof this?.value<"u"&&this.value!==null&&(n=String(this.value));const o=i(n,e);return o!==null?o:r?r.call(this):n},delete s.format,a.update({labels:s},!1)})}_applyValueFormatToLiveChart(t){const e=this._normalizeValueFormat(this.valueFormat),i=this._normalizeTimeFormat(this.timeFormat),a=this._formatValueForDisplay.bind(this),s=this._getTooltipXAxisLabel.bind(this);t.update({tooltip:{...t.options?.tooltip||{},valueDecimals:e.decimals,formatter:function(){const r=Array.isArray(this.points)&&this.points.length?this.points:[this.point||this],n=s(this,i),o=[];return r.forEach(h=>{const d=h?.point||h,b=Number.isFinite(h?.y)?h.y:d?.y,_=a(b,e,!0);if(_===null)return;const w=d?.name||d?.series?.name||"";o.push(`${w?`${String(w)}: `:""}<b>${_}</b><br/>`)}),`${n?`<span>${String(n)}</span><br/>`:""}${o.join("")}`}},plotOptions:{...t.options?.plotOptions||{},series:{...t.options?.plotOptions?.series||{},dataLabels:{...t.options?.plotOptions?.series?.dataLabels||{},formatter:function(){const r=Number.isFinite(this?.y)?this.y:this?.point?.y;return a(r,e,e.type==="percent")??null}}}}},!1,!1,!1),(t?.yAxis||[]).forEach(r=>{const n=r.options?.labels&&typeof r.options.labels=="object"?{...r.options.labels}:{},o=typeof n.formatter=="function"?n.formatter:null,h=!(r.options?.title&&typeof r.options.title.text=="string"&&r.options.title.text.trim());n.formatter=function(){const d=a(this?.value,e,h);return d!==null?d:o?o.call(this):this?.value},(e.type==="percent"||e.scale!=="auto")&&delete n.format,r.update({labels:n},!1)})}_applyYAxisSettingsToLiveChart(t){const e=this._normalizeYAxisSettings(this.yAxisSettings),i=t?.yAxis||[];i.length&&i.forEach((a,s)=>{const r=a.options&&typeof a.options=="object"?a.options:{},n={},o=typeof r.min<"u"&&r.min!==null&&r.min!=="";s===0&&e.startAtZero&&!o&&(n.min=0);const h=Array.isArray(r.plotLines)?r.plotLines.filter(d=>d?.id!=="scb-viz-reference-line"):[];s===0&&e.referenceLineEnabled&&Number.isFinite(e.referenceLineValue)&&h.push({id:"scb-viz-reference-line",className:"scb-axis-plotline scb-viz-reference-line",value:e.referenceLineValue,label:e.referenceLineLabel?{text:e.referenceLineLabel,className:"scb-viz-reference-line-label"}:void 0}),h.length?n.plotLines=h:Array.isArray(r.plotLines)&&(n.plotLines=[]),a.update(n,!1)})}_getCurrentHighchartsChart(){if(this._getCurrentPrintableView()!=="diagram")return;const t=c(this,l,I).call(this,this._getDiagramAssignedElements());return t===void 0?void 0:window.Highcharts?.charts?.[t]}_getSeriesDifferentiationGroup(t,e){const i=String(t?.type||t?.options?.type||e?.options?.chart?.type||"").trim().toLowerCase();return["line","spline","scatter"].includes(i)?"line":["area","areaspline"].includes(i)?"area":["column","bar"].includes(i)?"fill":["pie","variablepie"].includes(i)?"point-fill":null}_shouldShowSeriesDifferentiationAction(){if(this._getCurrentPrintableView()!=="diagram")return!1;const t=this._getCurrentHighchartsChart();return!t?.series?.length||!this._isHighchartsStyledMode(t)?!1:t.series.some(e=>this._getSeriesDifferentiationGroup(e,t)!==null)}_getSeriesDifferentiationSnapshotStore(t){let e=this._seriesDifferentiationSnapshots.get(t);return e||(e=new Map,this._seriesDifferentiationSnapshots.set(t,e)),e}_cloneSeriesOptionValue(t){return Array.isArray(t)?t.map(e=>this._cloneSeriesOptionValue(e)):t&&typeof t=="object"?Object.fromEntries(Object.entries(t).map(([e,i])=>[e,this._cloneSeriesOptionValue(i)])):t}_captureSeriesDifferentiationSnapshot(t){const e=this._cloneSeriesOptionValue(t?.options?.marker);return{marker:e&&Object.keys(e).length>0?e:{enabled:!1}}}_getHighchartsSvgElement(t){const e=t?.element??t;return e instanceof SVGElement?e:null}_isHighchartsStyledMode(t){return!!(t?.styledMode||t?.renderer?.styledMode||t?.options?.chart?.styledMode)}_getHighchartsSvgRoot(t){if(t?.container instanceof SVGSVGElement)return t.container;const e=t?.renderTo?.querySelector("svg")??t?.container?.querySelector?.("svg");return e instanceof SVGSVGElement?e:null}_getHighchartsColorClassName(t,e){const i=this._getHighchartsSvgElement(t);return Array.from(i?.classList??[]).find(s=>/^highcharts-color-\d+$/.test(s))??`highcharts-color-${e}`}_setSeriesDifferentiationMetadata(t,e){const i=this._getHighchartsSvgElement(t);i&&(i.setAttribute("data-scb-viz-role",e.role),e.dashStyle?i.setAttribute("data-scb-viz-dash-style",e.dashStyle):i.removeAttribute("data-scb-viz-dash-style"),e.patternKind?i.setAttribute("data-scb-viz-pattern-kind",e.patternKind):i.removeAttribute("data-scb-viz-pattern-kind"))}_clearSeriesDifferentiationMetadata(t){const e=this._getHighchartsSvgElement(t);e&&(e.removeAttribute("data-scb-viz-role"),e.removeAttribute("data-scb-viz-dash-style"),e.removeAttribute("data-scb-viz-pattern-kind"))}_setSeriesDifferentiationColorClass(t,e){const i=this._getHighchartsSvgElement(t);if(!i||!e)return;const a=Array.from(i.classList).find(s=>/^highcharts-color-\d+$/.test(s));a!==e&&(a&&(i.classList.remove(a),i.setAttribute("data-scb-viz-prev-color-class",a)),i.classList.add(e),i.setAttribute("data-scb-viz-added-color-class",e))}_clearSeriesDifferentiationColorClass(t){const e=this._getHighchartsSvgElement(t);if(!e)return;const i=e.getAttribute("data-scb-viz-added-color-class"),a=e.getAttribute("data-scb-viz-prev-color-class");i&&(e.classList.remove(i),e.removeAttribute("data-scb-viz-added-color-class")),a&&(e.classList.add(a),e.removeAttribute("data-scb-viz-prev-color-class"))}_getLegendSeriesDifferentiationTargets(t){const e=[],i=[],a=this._getHighchartsSvgElement(t?.legendItem?.group),s=(n,o)=>{const h=this._getHighchartsSvgElement(o);!h||n.includes(h)||n.push(h)};if(s(e,t?.legendLine),s(e,t?.legendItem?.line),s(i,t?.legendSymbol),s(i,t?.legendItem?.symbol),s(i,t?.legendArea),s(i,t?.legendItem?.area),a){const n=a.querySelector(".highcharts-graph, .highcharts-legend-graph, line, path");n&&s(e,n),a.querySelectorAll("rect, circle, .highcharts-point, .highcharts-area, .highcharts-legend-symbol, path").forEach(o=>{s(i,o)})}const r=i.filter(n=>!e.includes(n));return{graphTargets:e,fillTargets:r}}_ensureStyledModeSeriesPattern(t,e,i){const a=this._getHighchartsSvgRoot(t);if(!a)return;const s="http://www.w3.org/2000/svg";let r=a.querySelector("defs");r instanceof SVGDefsElement||(r=document.createElementNS(s,"defs"),a.insertBefore(r,a.firstChild));const n=`scb-viz-pattern-${e}-${i}`;if(r.querySelector(`#${n}`))return;const o=document.createElementNS(s,"pattern");o.setAttribute("id",n),o.setAttribute("patternUnits","userSpaceOnUse"),o.setAttribute("width","10"),o.setAttribute("height","10"),o.classList.add(e);const h=document.createElementNS(s,"rect");h.setAttribute("x","0"),h.setAttribute("y","0"),h.setAttribute("width","10"),h.setAttribute("height","10"),h.setAttribute("class","scb-viz-highcharts-pattern__background"),o.appendChild(h),ft(o,s,i),r.appendChild(o)}_applyStyledModeSeriesDifferentiation(t){const e=this._getHighchartsSvgRoot(t);if(!e)return;e.classList.add("scb-viz-series-differentiation-enabled");const i=ut(),a=this._getSeriesDifferentiationSnapshotStore(t);t.series?.forEach((s,r)=>{const n=this._getSeriesDifferentiationGroup(s,t);if(!n)return;const o=String(s?.index??r);a.has(o)||a.set(o,this._captureSeriesDifferentiationSnapshot(s));const{dashStyle:h,markerSymbol:d,patternKind:b}=mt(r),_=this._getHighchartsColorClassName(s?.graph??s?.area??s?.group,r),w=this._getLegendSeriesDifferentiationTargets(s);this._setSeriesDifferentiationMetadata(s?.graph,{role:"graph",dashStyle:h}),n==="area"&&(this._setSeriesDifferentiationMetadata(s?.area,{role:"area",patternKind:b}),this._setSeriesDifferentiationColorClass(s?.area,_),this._ensureStyledModeSeriesPattern(t,_,b)),n==="fill"&&(s.points?.forEach(p=>{this._setSeriesDifferentiationMetadata(p?.graphic,{role:"fill",patternKind:b}),this._setSeriesDifferentiationColorClass(p?.graphic,_)}),this._ensureStyledModeSeriesPattern(t,_,b)),n==="point-fill"&&s.points?.forEach((p,y)=>{const z=i[y%i.length],S=this._getHighchartsColorClassName(p?.graphic??p?.legendSymbol??p?.legendItem?.symbol??p?.legendItem?.group,y),C=this._getLegendSeriesDifferentiationTargets(p);this._setSeriesDifferentiationMetadata(p?.graphic,{role:"fill",patternKind:z}),this._setSeriesDifferentiationColorClass(p?.graphic,S),this._ensureStyledModeSeriesPattern(t,S,z),C.fillTargets.forEach(G=>{this._setSeriesDifferentiationMetadata(G,{role:"legend-fill",patternKind:z}),this._setSeriesDifferentiationColorClass(G,S)})}),(n==="line"||n==="area")&&w.graphTargets.forEach(p=>{this._setSeriesDifferentiationMetadata(p,{role:"legend-symbol",dashStyle:h})}),(n==="area"||n==="fill")&&w.fillTargets.forEach(p=>{this._setSeriesDifferentiationMetadata(p,{role:"legend-fill",patternKind:b}),this._setSeriesDifferentiationColorClass(p,_)}),(n==="line"||n==="area")&&s.update({marker:{enabled:!0,symbol:d}},!1)}),t.redraw(!1)}_restoreStyledModeSeriesDifferentiation(t){this._getHighchartsSvgRoot(t)?.classList.remove("scb-viz-series-differentiation-enabled");const i=this._getSeriesDifferentiationSnapshotStore(t);t.series?.forEach((a,s)=>{const r=this._getSeriesDifferentiationGroup(a,t);if(!r)return;const n=this._getLegendSeriesDifferentiationTargets(a);if(this._clearSeriesDifferentiationMetadata(a?.graph),this._clearSeriesDifferentiationMetadata(a?.area),this._clearSeriesDifferentiationColorClass(a?.area),a.points?.forEach(o=>{const h=this._getLegendSeriesDifferentiationTargets(o);this._clearSeriesDifferentiationMetadata(o?.graphic),this._clearSeriesDifferentiationColorClass(o?.graphic),h.graphTargets.forEach(d=>{this._clearSeriesDifferentiationMetadata(d)}),h.fillTargets.forEach(d=>{this._clearSeriesDifferentiationMetadata(d),this._clearSeriesDifferentiationColorClass(d)})}),n.graphTargets.forEach(o=>{this._clearSeriesDifferentiationMetadata(o)}),n.fillTargets.forEach(o=>{this._clearSeriesDifferentiationMetadata(o),this._clearSeriesDifferentiationColorClass(o)}),r==="line"||r==="area"){const o=i.get(String(a?.index??s));a.update({marker:this._cloneSeriesOptionValue(o?.marker)},!1)}}),t.redraw(!1)}_canExportRaster(){return this._getExportableVisualElement()!==null}_canExportCsv(){return!!this._getResolvedTableData()?.rows?.length}_getExportBaseFileName(){const t=this.lang==="en"?"visualization":"visualisering";return(this.title||t).normalize("NFD").replace(/[\u0300-\u036f]/g,"").toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")||t}_buildExportFileName(t){const e=t==="csv"?this.lang==="en"?"-table":"-tabell":"";return`${this._getExportBaseFileName()}${e}.${t}`}_renderActionsMenu(){const t=this._getCurrentPrintableView(),e=this._canExportRaster(),i=this._canExportCsv(),a=e&&(t==="diagram"||t==="image"),s=i&&t==="table",r=this._shouldShowSeriesDifferentiationAction();return f`
117
117
  <div class="actions-menu">
118
118
  <scb-icon-button
119
119
  icon="more_vert"
@@ -125,7 +125,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
125
125
  aria-label=${this.actionsMenuLabel}
126
126
  aria-haspopup="menu"
127
127
  aria-expanded=${this._actionsMenuOpen?"true":"false"}
128
- @click=${a=>this._toggleActionsMenu(a)}
128
+ @click=${n=>this._toggleActionsMenu(n)}
129
129
  ></scb-icon-button>
130
130
  <div
131
131
  class=${`actions-menu-panel ${this._actionsMenuOpen?"actions-menu-panel--open":""}`}
@@ -144,7 +144,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
144
144
  <span class="actions-menu-item-label">${this.printLabel}</span>
145
145
  </button>
146
146
  </li>
147
- ${n?g`
147
+ ${a?f`
148
148
  <li>
149
149
  <button
150
150
  type="button"
@@ -168,7 +168,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
168
168
  </button>
169
169
  </li>
170
170
  `:""}
171
- ${s?g`
171
+ ${s?f`
172
172
  <li>
173
173
  <button
174
174
  type="button"
@@ -181,7 +181,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
181
181
  </button>
182
182
  </li>
183
183
  `:""}
184
- ${o?g`
184
+ ${r?f`
185
185
  <li>
186
186
  <button
187
187
  type="button"
@@ -200,9 +200,9 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
200
200
  </ul>
201
201
  </div>
202
202
  </div>
203
- `}_renderActions(){return g`
203
+ `}_renderActions(){return f`
204
204
  <div class="actions-row">
205
- ${this.variant==="Standard"&&!this.disableToggle?g`
205
+ ${this.variant==="Standard"&&!this.disableToggle?f`
206
206
  <div class="flipp-wrapper">
207
207
  <scb-segmented-button
208
208
  .value=${this.selectedChip||""}
@@ -220,58 +220,58 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
220
220
  ></scb-segmented-item>
221
221
  </scb-segmented-button>
222
222
  </div>
223
- `:g`<div></div>`}
223
+ `:f`<div></div>`}
224
224
  ${this._renderActionsMenu()}
225
225
  </div>
226
- `}_renderHeader(t=!1){const e=g`
226
+ `}_renderHeader(t=!1){const e=f`
227
227
  <div class="header">
228
- ${this.title?g` <div class="label" role="heading" aria-level="2">${this.title}</div> `:""}
229
- ${this.subtitle?g` <div class="sub-label">${this.subtitle}</div> `:""}
228
+ ${this.title?f` <div class="label" role="heading" aria-level="2">${this.title}</div> `:""}
229
+ ${this.subtitle?f` <div class="sub-label">${this.subtitle}</div> `:""}
230
230
  </div>
231
- `;return t?g`
231
+ `;return t?f`
232
232
  <div class="header-row">
233
233
  ${e}
234
234
  ${this._renderActionsMenu()}
235
235
  </div>
236
- `:e}_renderTable(){const t=this.tableData??this._slottedTableData;if(!t||!t.rows||t.rows.length===0)return null;const e=this._inferTableAlignments(t),i=Math.max(t.headers?.length??0,...t.rows.map(r=>r.length)),n=(t.headers??[]).map(r=>this._normalizeRenderableCell(r)),s=t.rows.map(r=>{const h=r.map(p=>this._normalizeRenderableCell(p));for(;h.length<i;)h.push({html:"",text:""});return h}),o=t.rowHeaderRows??[],a=[this.title,this.subtitle].map(r=>typeof r=="string"?r.trim():"").filter(Boolean).join(". ");return g`
236
+ `:e}_renderTable(){const t=this.tableData??this._slottedTableData;if(!t||!t.rows||t.rows.length===0)return null;const e=this._inferTableAlignments(t),i=Math.max(t.headers?.length??0,...t.rows.map(o=>o.length)),a=(t.headers??[]).map(o=>this._normalizeRenderableCell(o)),s=t.rows.map(o=>{const h=o.map(d=>this._normalizeRenderableCell(d));for(;h.length<i;)h.push({html:"",text:""});return h}),r=t.rowHeaderRows??[],n=[this.title,this.subtitle].map(o=>typeof o=="string"?o.trim():"").filter(Boolean).join(". ");return f`
237
237
  <table class="scb-viz-table" part="table">
238
- ${a?g`<caption class="visually-hidden">${a}</caption>`:""}
239
- ${n.length>0?g`
238
+ ${n?f`<caption class="visually-hidden">${n}</caption>`:""}
239
+ ${a.length>0?f`
240
240
  <thead>
241
241
  <tr>
242
- ${n.map((r,h)=>{const p=e[h]==="right"?"align-right":"align-left";return g`<th scope="col" class=${p}>${r.html?W(r.html):r.text}</th>`})}
242
+ ${a.map((o,h)=>{const d=e[h]==="right"?"align-right":"align-left";return f`<th scope="col" class=${d}>${o.html?W(o.html):o.text}</th>`})}
243
243
  </tr>
244
244
  </thead>
245
245
  `:""}
246
246
  <tbody>
247
- ${s.map((r,h)=>{const p=o[h]===!0;return g`
247
+ ${s.map((o,h)=>{const d=r[h]===!0;return f`
248
248
  <tr>
249
- ${r.map((b,_)=>{const w=e[_]==="right"?"align-right":"align-left",d=b.html?W(b.html):b.text;return _===0&&p?g`<th scope="row" class=${w}>${d}</th>`:g`<td class=${w}>${d}</td>`})}
249
+ ${o.map((b,_)=>{const w=e[_]==="right"?"align-right":"align-left",p=b.html?W(b.html):b.text;return _===0&&d?f`<th scope="row" class=${w}>${p}</th>`:f`<td class=${w}>${p}</td>`})}
250
250
  </tr>
251
251
  `})}
252
252
  </tbody>
253
253
  </table>
254
- `}_hasMoreAboutStats(){return!!(this.comment||this.source||this.footnote||this.officialStatistics)}_renderMoreAboutStatsContent(){return g`
254
+ `}_hasMoreAboutStats(){return!!(this.comment||this.source||this.footnote||this.officialStatistics)}_renderMoreAboutStatsContent(){return f`
255
255
  <div class="more-about-stats-content">
256
- ${this.comment?g`
256
+ ${this.comment?f`
257
257
  <div class="section">
258
258
  <div class="secondary-label" role="heading" aria-level="3">${this.commentLabel}</div>
259
259
  <div class="body-text">${this.comment}</div>
260
260
  </div>
261
261
  `:""}
262
- ${this.source?g`
262
+ ${this.source?f`
263
263
  <div class="section">
264
264
  <div class="secondary-label" role="heading" aria-level="3">${this.sourceLabel}</div>
265
265
  <div class="body-text">${this.source}</div>
266
266
  </div>
267
267
  `:""}
268
- ${this.footnote?g`
268
+ ${this.footnote?f`
269
269
  <div class="section">
270
270
  <div class="secondary-label" role="heading" aria-level="3">${this.footnoteLabel}</div>
271
271
  <div class="body-text">${this.footnote}</div>
272
272
  </div>
273
273
  `:""}
274
- ${this.officialStatistics?g`
274
+ ${this.officialStatistics?f`
275
275
  <a
276
276
  class="sos-logotype-link"
277
277
  href="https://www.scb.se/sos"
@@ -286,7 +286,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
286
286
  </a>
287
287
  `:""}
288
288
  </div>
289
- `}_renderMoreAboutStatsScreen(){return this._hasMoreAboutStats()?g`
289
+ `}_renderMoreAboutStatsScreen(){return this._hasMoreAboutStats()?f`
290
290
  <div class="footer-statistics-screen">
291
291
  <scb-divider></scb-divider>
292
292
  <scb-accordion>
@@ -295,16 +295,16 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
295
295
  </scb-accordion-item>
296
296
  </scb-accordion>
297
297
  </div>
298
- `:""}_renderMoreAboutStatsPrint(){return this._hasMoreAboutStats()?g`
298
+ `:""}_renderMoreAboutStatsPrint(){return this._hasMoreAboutStats()?f`
299
299
  <div class="footer-statistics-print print-more-about-stats">
300
300
  <div class="secondary-label print-more-about-stats-heading" role="heading" aria-level="3">
301
301
  ${this.moreAboutStatsLabel}
302
302
  </div>
303
303
  ${this._renderMoreAboutStatsContent()}
304
304
  </div>
305
- `:""}_renderFooter(){return g`
305
+ `:""}_renderFooter(){return f`
306
306
  <div class="footer">
307
- ${this.description?g`
307
+ ${this.description?f`
308
308
  <div class="description section">
309
309
  <div class="secondary-label" role="heading" aria-level="3">${this.descriptionLabel}</div>
310
310
  <div class="body-text">${this.description}</div>
@@ -313,7 +313,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
313
313
  ${this._renderMoreAboutStatsScreen()}
314
314
  ${this._renderMoreAboutStatsPrint()}
315
315
  </div>
316
- `}render(){switch(this.variant){case"Table":return g`
316
+ `}render(){switch(this.variant){case"Table":return f`
317
317
  <div part="container" class="viz-container">
318
318
  ${this._renderHeader(!0)}
319
319
  <div class="content">
@@ -334,7 +334,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
334
334
  ></slot>
335
335
  <slot></slot>
336
336
  </div>
337
- `;case"Image":return g`
337
+ `;case"Image":return f`
338
338
  <div part="container" class="viz-container">
339
339
  ${this._renderHeader(!0)}
340
340
  <div
@@ -351,7 +351,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
351
351
  ></slot>
352
352
  <slot></slot>
353
353
  </div>
354
- `;default:return g`
354
+ `;default:return f`
355
355
  <div part="container" class="viz-container">
356
356
  ${this._renderHeader()}
357
357
  ${this._renderActions()}
@@ -362,26 +362,19 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
362
362
  <div
363
363
  class=${`standard-content-panel standard-content-panel--diagram ${this.selectedChip==="Diagram"?"standard-content-panel--active":""}`}
364
364
  >
365
- ${this._getResolvedContentMaxWidth()?g`
366
- <scb-horizontal-scroller
367
- width=${this._getResolvedContentMaxWidth()}
368
- class="standard-diagram-scroller"
369
- variant="inline"
370
- >
371
- <div
372
- class="diagram-content"
373
- style=${`--scb-viz-content-max-width: ${this._getResolvedContentMaxWidth()};`}
374
- >
375
- <slot name="diagram" @slotchange=${this._onDiagramSlotChange}></slot>
376
- </div>
377
- </scb-horizontal-scroller>
378
- `:g`
379
- <div class="standard-diagram-scroller">
380
- <div class="diagram-content">
381
- <slot name="diagram" @slotchange=${this._onDiagramSlotChange}></slot>
382
- </div>
383
- </div>
384
- `}
365
+ <scb-horizontal-scroller
366
+ width=${this._getResolvedDiagramScrollerWidth()}
367
+ class="standard-diagram-scroller"
368
+ variant="inline"
369
+ show-scrollbar
370
+ >
371
+ <div
372
+ class="diagram-content"
373
+ style=${this._getResolvedContentMaxWidth()?`--scb-viz-content-max-width: ${this._getResolvedContentMaxWidth()};`:""}
374
+ >
375
+ <slot name="diagram" @slotchange=${this._onDiagramSlotChange}></slot>
376
+ </div>
377
+ </scb-horizontal-scroller>
385
378
  </div>
386
379
  <div
387
380
  class=${`standard-content-panel standard-content-panel--table ${this.selectedChip==="Table"?"standard-content-panel--active":""}`}
@@ -407,7 +400,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
407
400
  ></slot>
408
401
  <slot></slot>
409
402
  </div>
410
- `}}_syncChipClass(){const t=this.variant==="Standard";this.classList.toggle("chip-diagram",t&&this.selectedChip==="Diagram"),this.classList.toggle("chip-table",t&&this.selectedChip==="Table")}_dispatchSelectedChipChanged(){const t={selectedChip:this.selectedChip};this.dispatchEvent(new CustomEvent("selected-chip-changed",{detail:t,bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("selectedchipchanged",{detail:t,bubbles:!0,composed:!0}))}_onSegmentedChange(t){const e=t.detail?.value;this.selectedChip===e?this.selectedChip=null:this.selectedChip=e}_toggleActionsMenu(t){t.stopPropagation(),this._actionsMenuOpen=!this._actionsMenuOpen,this._actionsMenuOpen&&requestAnimationFrame(()=>{this._focusFirstMenuItem()})}_closeActionsMenu(){this._actionsMenuOpen=!1}_focusMenuButton(){this.shadowRoot?.querySelector(".actions-menu scb-icon-button")?.focus()}_focusFirstMenuItem(){this.shadowRoot?.querySelector(".actions-menu-item")?.focus()}_getCurrentPrintableView(){return this.variant==="Table"?"table":this.variant==="Image"?"image":this.selectedChip==="Table"?"table":"diagram"}};l=new WeakSet;L=function(){if(c(this,l,F).call(this),typeof ResizeObserver>"u")return;const t=this.shadowRoot?.querySelector(".diagram-content");t&&(this._diagramResizeObserver=new ResizeObserver(()=>{c(this,l,M).call(this)}),this._diagramResizeObserver.observe(this),this._diagramResizeObserver.observe(t))};F=function(){this._diagramResizeObserver?.disconnect(),this._diagramResizeObserver=void 0};I=function(){this._diagramReflowFrame&&(cancelAnimationFrame(this._diagramReflowFrame),this._diagramReflowFrame=0)};M=function(){this.variant!=="Standard"||this.selectedChip!=="Diagram"||(c(this,l,I).call(this),this._diagramReflowFrame=requestAnimationFrame(()=>{this._diagramReflowFrame=requestAnimationFrame(()=>{this._diagramReflowFrame=0,c(this,l,K).call(this)})}))};A=function(t){const e=t?.getAttribute("data-highcharts-chart");if(!e)return;const i=Number.parseInt(e,10);return Number.isNaN(i)?void 0:i};j=function(t){for(const e of t){const i=c(this,l,A).call(this,e);if(i!==void 0)return i;const n=e.querySelector("[data-highcharts-chart]"),s=c(this,l,A).call(this,n);if(s!==void 0)return s}};K=function(){if(this.variant!=="Standard"||this.selectedChip!=="Diagram")return;const t=this.shadowRoot?.querySelector('slot[name="diagram"]');if(!t)return;const e=t.assignedElements({flatten:!0});if(e.length===0)return;const i=c(this,l,j).call(this,e);if(i===void 0)return;const s=window.Highcharts?.charts?.[i];s&&(s.setSize?.(null,null,!1),s.reflow?.(),this._seriesDifferentiationEnabled&&c(this,l,$).call(this))};D=function(){const t=this.variant==="Standard"?this._getResolvedDiagramHeight():"",e=this.variant==="Standard"&&this._getResolvedToggleHeightMode()==="stable"?this._getResolvedStandardContentHeight():"";this.variant==="Standard"?this.style.setProperty("--scb-viz-diagram-min-height",t||"420px"):this.style.removeProperty("--scb-viz-diagram-min-height"),t?(this.style.setProperty("--scb-viz-diagram-height",t),this.style.setProperty("--scb-viz-diagram-overflow","hidden")):(this.style.removeProperty("--scb-viz-diagram-height"),this.style.removeProperty("--scb-viz-diagram-overflow")),e?this.style.setProperty("--scb-viz-standard-content-height",e):this.style.removeProperty("--scb-viz-standard-content-height")};N=function(){this._chartConfigSyncFrame&&(cancelAnimationFrame(this._chartConfigSyncFrame),this._chartConfigSyncFrame=0)};k=function(){c(this,l,N).call(this),this._chartConfigSyncFrame=requestAnimationFrame(()=>{this._chartConfigSyncFrame=requestAnimationFrame(()=>{this._chartConfigSyncFrame=0,c(this,l,J).call(this)})})};J=function(){const t=this._getCurrentHighchartsChart();if(!t)return;let e=!1;typeof this.timeFormat<"u"&&(this._applyTimeFormatToLiveChart(t),e=!0),typeof this.valueFormat<"u"&&(this._applyValueFormatToLiveChart(t),e=!0),typeof this.yAxisSettings<"u"&&(this._applyYAxisSettingsToLiveChart(t),e=!0),e&&t.redraw(!1)};Y=function(t){this._isHighchartsStyledMode(t)&&this._applyStyledModeSeriesDifferentiation(t)};Z=function(t){this._isHighchartsStyledMode(t)&&this._restoreStyledModeSeriesDifferentiation(t)};$=function(){const t=this._getCurrentHighchartsChart();if(t){if(this._seriesDifferentiationEnabled){c(this,l,Y).call(this,t);return}c(this,l,Z).call(this,t)}};E=async function(t){const e=this._getExportableVisualElement();if(!e)return;const i=await c(this,l,nt).call(this,e,t);i&&c(this,l,B).call(this,i,this._buildExportFileName(t==="jpeg"?"jpg":"png"))};v=function(t){return String(t??"").replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")};Q=function(t){const e=this._inferTableAlignments(t),i=Math.max(t.headers?.length??0,...t.rows.map(h=>h.length)),n=(t.headers??[]).map(h=>this._normalizeRenderableCell(h)),s=t.rows.map(h=>{const p=h.map(b=>this._normalizeRenderableCell(b));for(;p.length<i;)p.push({html:"",text:""});return p}),o=t.rowHeaderRows??[],a=n.length?`<thead><tr>${n.map((h,p)=>`<th scope="col" class="${e[p]==="right"?"align-right":"align-left"}">${h.html||c(this,l,v).call(this,h.text)}</th>`).join("")}</tr></thead>`:"",r=`<tbody>${s.map((h,p)=>{const b=o[p]===!0;return`<tr>${h.map((w,d)=>{const y=e[d]==="right"?"align-right":"align-left",z=w.html||c(this,l,v).call(this,w.text);return d===0&&b?`<th scope="row" class="${y}">${z}</th>`:`<td class="${y}">${z}</td>`}).join("")}</tr>`}).join("")}</tbody>`;return`<table class="scb-viz-print-table">${a}${r}</table>`};X=function(){const t=[];if(this.description&&t.push(`
403
+ `}}_syncChipClass(){const t=this.variant==="Standard";this.classList.toggle("chip-diagram",t&&this.selectedChip==="Diagram"),this.classList.toggle("chip-table",t&&this.selectedChip==="Table")}_dispatchSelectedChipChanged(){const t={selectedChip:this.selectedChip};this.dispatchEvent(new CustomEvent("selected-chip-changed",{detail:t,bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("selectedchipchanged",{detail:t,bubbles:!0,composed:!0}))}_onSegmentedChange(t){const e=t.detail?.value;this.selectedChip===e?this.selectedChip=null:this.selectedChip=e}_toggleActionsMenu(t){t.stopPropagation(),this._actionsMenuOpen=!this._actionsMenuOpen,this._actionsMenuOpen&&requestAnimationFrame(()=>{this._focusFirstMenuItem()})}_closeActionsMenu(){this._actionsMenuOpen=!1}_focusMenuButton(){this.shadowRoot?.querySelector(".actions-menu scb-icon-button")?.focus()}_focusFirstMenuItem(){this.shadowRoot?.querySelector(".actions-menu-item")?.focus()}_getCurrentPrintableView(){return this.variant==="Table"?"table":this.variant==="Image"?"image":this.selectedChip==="Table"?"table":"diagram"}};l=new WeakSet;L=function(){if(c(this,l,F).call(this),typeof ResizeObserver>"u")return;const t=this.shadowRoot?.querySelector(".diagram-content");t&&(this._diagramResizeObserver=new ResizeObserver(()=>{c(this,l,M).call(this)}),this._diagramResizeObserver.observe(this),this._diagramResizeObserver.observe(t))};F=function(){this._diagramResizeObserver?.disconnect(),this._diagramResizeObserver=void 0};N=function(){this._diagramReflowFrame&&(cancelAnimationFrame(this._diagramReflowFrame),this._diagramReflowFrame=0)};M=function(){this.variant!=="Standard"||this.selectedChip!=="Diagram"||(c(this,l,N).call(this),this._diagramReflowFrame=requestAnimationFrame(()=>{this._diagramReflowFrame=requestAnimationFrame(()=>{this._diagramReflowFrame=0,c(this,l,K).call(this)})}))};A=function(t){const e=t?.getAttribute("data-highcharts-chart");if(!e)return;const i=Number.parseInt(e,10);return Number.isNaN(i)?void 0:i};I=function(t){for(const e of t){const i=c(this,l,A).call(this,e);if(i!==void 0)return i;const a=e.querySelector("[data-highcharts-chart]"),s=c(this,l,A).call(this,a);if(s!==void 0)return s}};K=function(){if(this.variant!=="Standard"||this.selectedChip!=="Diagram")return;const t=this.shadowRoot?.querySelector('slot[name="diagram"]');if(!t)return;const e=t.assignedElements({flatten:!0});if(e.length===0)return;const i=c(this,l,I).call(this,e);if(i===void 0)return;const s=window.Highcharts?.charts?.[i];s&&(s.setSize?.(null,null,!1),s.reflow?.(),this._seriesDifferentiationEnabled&&c(this,l,$).call(this))};D=function(){const t=this.variant==="Standard"?this._getResolvedDiagramHeight():"",e=this.variant==="Standard"&&this._getResolvedToggleHeightMode()==="stable"?this._getResolvedStandardContentHeight():"";this.variant==="Standard"?this.style.setProperty("--scb-viz-diagram-min-height",t||"600px"):this.style.removeProperty("--scb-viz-diagram-min-height"),t?(this.style.setProperty("--scb-viz-diagram-height",t),this.style.setProperty("--scb-viz-diagram-overflow","hidden")):(this.style.removeProperty("--scb-viz-diagram-height"),this.style.removeProperty("--scb-viz-diagram-overflow")),e?this.style.setProperty("--scb-viz-standard-content-height",e):this.style.removeProperty("--scb-viz-standard-content-height")};j=function(){this._chartConfigSyncFrame&&(cancelAnimationFrame(this._chartConfigSyncFrame),this._chartConfigSyncFrame=0)};k=function(){c(this,l,j).call(this),this._chartConfigSyncFrame=requestAnimationFrame(()=>{this._chartConfigSyncFrame=requestAnimationFrame(()=>{this._chartConfigSyncFrame=0,c(this,l,J).call(this)})})};J=function(){const t=this._getCurrentHighchartsChart();if(!t)return;let e=!1;typeof this.timeFormat<"u"&&(this._applyTimeFormatToLiveChart(t),e=!0),typeof this.valueFormat<"u"&&(this._applyValueFormatToLiveChart(t),e=!0),typeof this.yAxisSettings<"u"&&(this._applyYAxisSettingsToLiveChart(t),e=!0),e&&t.redraw(!1)};X=function(t){this._isHighchartsStyledMode(t)&&this._applyStyledModeSeriesDifferentiation(t)};Y=function(t){this._isHighchartsStyledMode(t)&&this._restoreStyledModeSeriesDifferentiation(t)};$=function(){const t=this._getCurrentHighchartsChart();if(t){if(this._seriesDifferentiationEnabled){c(this,l,X).call(this,t);return}c(this,l,Y).call(this,t)}};E=async function(t){const e=this._getExportableVisualElement();if(!e)return;const i=await c(this,l,at).call(this,e,t);i&&c(this,l,B).call(this,i,this._buildExportFileName(t==="jpeg"?"jpg":"png"))};v=function(t){return String(t??"").replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")};Z=function(t){const e=this._inferTableAlignments(t),i=Math.max(t.headers?.length??0,...t.rows.map(h=>h.length)),a=(t.headers??[]).map(h=>this._normalizeRenderableCell(h)),s=t.rows.map(h=>{const d=h.map(b=>this._normalizeRenderableCell(b));for(;d.length<i;)d.push({html:"",text:""});return d}),r=t.rowHeaderRows??[],n=a.length?`<thead><tr>${a.map((h,d)=>`<th scope="col" class="${e[d]==="right"?"align-right":"align-left"}">${h.html||c(this,l,v).call(this,h.text)}</th>`).join("")}</tr></thead>`:"",o=`<tbody>${s.map((h,d)=>{const b=r[d]===!0;return`<tr>${h.map((w,p)=>{const y=e[p]==="right"?"align-right":"align-left",z=w.html||c(this,l,v).call(this,w.text);return p===0&&b?`<th scope="row" class="${y}">${z}</th>`:`<td class="${y}">${z}</td>`}).join("")}</tr>`}).join("")}</tbody>`;return`<table class="scb-viz-print-table">${n}${o}</table>`};Q=function(){const t=[];if(this.description&&t.push(`
411
404
  <section class="print-section">
412
405
  <h2>${c(this,l,v).call(this,this.descriptionLabel)}</h2>
413
406
  <div>${c(this,l,v).call(this,this.description)}</div>
@@ -481,11 +474,11 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
481
474
  ${this.subtitle?`<div class="viz-subtitle">${c(this,l,v).call(this,this.subtitle)}</div>`:""}
482
475
  </header>
483
476
  <div class="viz-content">${t}</div>
484
- ${c(this,l,X).call(this)}
477
+ ${c(this,l,Q).call(this)}
485
478
  </article>
486
479
  </body>
487
- </html>`};et=async function(t){const e=document.createElement("iframe");e.setAttribute("aria-hidden","true"),e.style.position="fixed",e.style.right="0",e.style.bottom="0",e.style.width="0",e.style.height="0",e.style.border="0",e.style.visibility="hidden",document.body.appendChild(e);const i=()=>{e.remove()},n=e.contentDocument,s=e.contentWindow;if(!n||!s){i();return}n.open(),n.write(t),n.close();const o=Array.from(n.images||[]);await Promise.all(o.map(r=>r.complete?Promise.resolve():new Promise(h=>{r.addEventListener("load",()=>h(null),{once:!0}),r.addEventListener("error",()=>h(null),{once:!0})})));const a=()=>{s.removeEventListener("afterprint",a),i()};s.addEventListener("afterprint",a,{once:!0}),setTimeout(()=>{s.focus(),s.print(),setTimeout(i,1e3)},50)};it=async function(){const t=this._getCurrentPrintableView();let e="";if(t==="table"){const i=this._getResolvedTableData();if(!i?.rows?.length)return;e=c(this,l,Q).call(this,i)}else if(t==="image"){const i=this.shadowRoot?.querySelector(".image-content img"),n=i?.currentSrc||i?.src||this.imageHref;if(!n)return;e=`<img class="viz-image" src="${c(this,l,v).call(this,n)}" alt="${c(this,l,v).call(this,this._getImageAltText())}">`}else{const i=this._getExportableVisualElement();if(!i)return;const n=await c(this,l,at).call(this,i,"png");if(!n)return;e=`<img class="viz-chart-image" src="${n}" alt="${c(this,l,v).call(this,this._getImageAltText())}">`}await c(this,l,et).call(this,c(this,l,tt).call(this,e))};st=function(){const t=this._getResolvedTableData();if(!t?.rows?.length)return;const e=this.lang==="en"?",":";",i=[];t.headers?.length&&i.push(t.headers.map(a=>this._normalizeRenderableCell(a).text)),t.rows.forEach(a=>{i.push(a.map(r=>this._normalizeRenderableCell(r).text))});const n=a=>`"${String(a??"").replace(/\r?\n/g," ").replace(/"/g,'""')}"`,s=`\uFEFF${i.map(a=>a.map(n).join(e)).join(`\r
488
- `)}`,o=new Blob([s],{type:"text/csv;charset=utf-8;"});c(this,l,B).call(this,o,this._buildExportFileName("csv"))};nt=async function(t,e){const i=await c(this,l,O).call(this,t);return i?c(this,l,lt).call(this,i,e==="jpeg"?"image/jpeg":"image/png",e==="jpeg"?.92:void 0):null};at=async function(t,e){const i=await c(this,l,O).call(this,t);return i?i.toDataURL(e==="jpeg"?"image/jpeg":"image/png",e==="jpeg"?.92:void 0):null};O=async function(t){if(t instanceof HTMLCanvasElement){const a=t.width||Math.round(t.getBoundingClientRect().width),r=t.height||Math.round(t.getBoundingClientRect().height);if(!a||!r)return null;const h=document.createElement("canvas");h.width=a,h.height=r;const p=h.getContext("2d");return p?(p.fillStyle=c(this,l,q).call(this),p.fillRect(0,0,a,r),p.drawImage(t,0,0,a,r),h):null}if(t instanceof HTMLImageElement){const a=t.naturalWidth||t.width,r=t.naturalHeight||t.height;return!a||!r?null:c(this,l,R).call(this,t.currentSrc||t.src,a,r)}const{width:e,height:i,serialized:n}=c(this,l,rt).call(this,t);if(!e||!i||!n)return null;const s=new Blob([n],{type:"image/svg+xml;charset=utf-8"}),o=URL.createObjectURL(s);try{return await c(this,l,R).call(this,o,e,i)}finally{URL.revokeObjectURL(o)}};rt=function(t){const e=t.cloneNode(!0),i=t.getBoundingClientRect(),n=t.viewBox?.baseVal,s=Math.round(n?.width||i.width||Number(t.getAttribute("width"))||0),o=Math.round(n?.height||i.height||Number(t.getAttribute("height"))||0);return e.setAttribute("xmlns","http://www.w3.org/2000/svg"),e.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),!e.getAttribute("width")&&s&&e.setAttribute("width",String(s)),!e.getAttribute("height")&&o&&e.setAttribute("height",String(o)),!e.getAttribute("viewBox")&&s&&o&&e.setAttribute("viewBox",`0 0 ${s} ${o}`),c(this,l,T).call(this,t,e),e.querySelectorAll(".highcharts-tooltip, .highcharts-contextmenu, .highcharts-a11y-proxy-container, .highcharts-a11y-dummy-point").forEach(a=>a.remove()),{width:s,height:o,serialized:new XMLSerializer().serializeToString(e)}};T=function(t,e){const i=getComputedStyle(t);let n="";for(let a=0;a<i.length;a+=1){const r=i[a],h=i.getPropertyValue(r);h&&(n+=`${r}:${h};`)}n&&e.setAttribute("style",n);const s=Array.from(t.children),o=Array.from(e.children);for(let a=0;a<s.length;a+=1){const r=s[a],h=o[a];r&&h&&c(this,l,T).call(this,r,h)}};R=async function(t,e,i){const n=Math.max(1,Math.min(2,window.devicePixelRatio||1)),s=Math.max(1,Math.round(e)),o=Math.max(1,Math.round(i)),a=document.createElement("canvas");a.width=Math.max(1,Math.round(s*n)),a.height=Math.max(1,Math.round(o*n));const r=a.getContext("2d");if(!r)return null;const h=await c(this,l,ot).call(this,t);return h?(r.scale(n,n),r.fillStyle=c(this,l,q).call(this),r.fillRect(0,0,s,o),r.drawImage(h,0,0,s,o),a):null};ot=function(t){return new Promise(e=>{const i=new Image;i.crossOrigin="anonymous",i.onload=()=>e(i),i.onerror=()=>e(null),i.src=t})};lt=function(t,e,i){return new Promise(n=>{t.toBlob(s=>n(s),e,i)})};q=function(){const t=this.shadowRoot?.querySelector(".viz-container"),e=getComputedStyle(t??this).backgroundColor;return e&&e!=="rgba(0, 0, 0, 0)"?e:"#ffffff"};B=function(t,e){const i=URL.createObjectURL(t),n=document.createElement("a");n.href=i,n.download=e,document.body.appendChild(n),n.click(),n.remove(),setTimeout(()=>URL.revokeObjectURL(i),0)};H=function(){const t=c(this,l,x).call(this,this.spacing),e=c(this,l,x).call(this,this.spacingTop)??t,i=c(this,l,x).call(this,this.spacingBottom)??t,n=c(this,l,x).call(this,this.spacingLeft),s=c(this,l,x).call(this,this.spacingRight);e?this.style.setProperty("--scb-viz-spacing-block-start",e):this.style.removeProperty("--scb-viz-spacing-block-start"),i?this.style.setProperty("--scb-viz-spacing-block-end",i):this.style.removeProperty("--scb-viz-spacing-block-end"),n?this.style.setProperty("--scb-viz-spacing-inline-start",n):this.style.removeProperty("--scb-viz-spacing-inline-start"),s?this.style.setProperty("--scb-viz-spacing-inline-end",s):this.style.removeProperty("--scb-viz-spacing-inline-end")};x=function(t){if(!t)return;const e=String(t).trim();if(e)return/^\d+$/.test(e)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(e,10)))})`:e};V=function(){const t=this.containerMaxWidth?.trim();t?this.style.setProperty("--scb-viz-container-max-width",t):this.style.removeProperty("--scb-viz-container-max-width")};f.styles=ht`
480
+ </html>`};et=async function(t){const e=document.createElement("iframe");e.setAttribute("aria-hidden","true"),e.style.position="fixed",e.style.right="0",e.style.bottom="0",e.style.width="0",e.style.height="0",e.style.border="0",e.style.visibility="hidden",document.body.appendChild(e);const i=()=>{e.remove()},a=e.contentDocument,s=e.contentWindow;if(!a||!s){i();return}a.open(),a.write(t),a.close();const r=Array.from(a.images||[]);await Promise.all(r.map(o=>o.complete?Promise.resolve():new Promise(h=>{o.addEventListener("load",()=>h(null),{once:!0}),o.addEventListener("error",()=>h(null),{once:!0})})));const n=()=>{s.removeEventListener("afterprint",n),i()};s.addEventListener("afterprint",n,{once:!0}),setTimeout(()=>{s.focus(),s.print(),setTimeout(i,1e3)},50)};it=async function(){const t=this._getCurrentPrintableView();let e="";if(t==="table"){const i=this._getResolvedTableData();if(!i?.rows?.length)return;e=c(this,l,Z).call(this,i)}else if(t==="image"){const i=this.shadowRoot?.querySelector(".image-content img"),a=i?.currentSrc||i?.src||this.imageHref;if(!a)return;e=`<img class="viz-image" src="${c(this,l,v).call(this,a)}" alt="${c(this,l,v).call(this,this._getImageAltText())}">`}else{const i=this._getExportableVisualElement();if(!i)return;const a=await c(this,l,nt).call(this,i,"png");if(!a)return;e=`<img class="viz-chart-image" src="${a}" alt="${c(this,l,v).call(this,this._getImageAltText())}">`}await c(this,l,et).call(this,c(this,l,tt).call(this,e))};st=function(){const t=this._getResolvedTableData();if(!t?.rows?.length)return;const e=this.lang==="en"?",":";",i=[];t.headers?.length&&i.push(t.headers.map(n=>this._normalizeRenderableCell(n).text)),t.rows.forEach(n=>{i.push(n.map(o=>this._normalizeRenderableCell(o).text))});const a=n=>`"${String(n??"").replace(/\r?\n/g," ").replace(/"/g,'""')}"`,s=`\uFEFF${i.map(n=>n.map(a).join(e)).join(`\r
481
+ `)}`,r=new Blob([s],{type:"text/csv;charset=utf-8;"});c(this,l,B).call(this,r,this._buildExportFileName("csv"))};at=async function(t,e){const i=await c(this,l,O).call(this,t);return i?c(this,l,lt).call(this,i,e==="jpeg"?"image/jpeg":"image/png",e==="jpeg"?.92:void 0):null};nt=async function(t,e){const i=await c(this,l,O).call(this,t);return i?i.toDataURL(e==="jpeg"?"image/jpeg":"image/png",e==="jpeg"?.92:void 0):null};O=async function(t){if(t instanceof HTMLCanvasElement){const n=t.width||Math.round(t.getBoundingClientRect().width),o=t.height||Math.round(t.getBoundingClientRect().height);if(!n||!o)return null;const h=document.createElement("canvas");h.width=n,h.height=o;const d=h.getContext("2d");return d?(d.fillStyle=c(this,l,q).call(this),d.fillRect(0,0,n,o),d.drawImage(t,0,0,n,o),h):null}if(t instanceof HTMLImageElement){const n=t.naturalWidth||t.width,o=t.naturalHeight||t.height;return!n||!o?null:c(this,l,R).call(this,t.currentSrc||t.src,n,o)}const{width:e,height:i,serialized:a}=c(this,l,rt).call(this,t);if(!e||!i||!a)return null;const s=new Blob([a],{type:"image/svg+xml;charset=utf-8"}),r=URL.createObjectURL(s);try{return await c(this,l,R).call(this,r,e,i)}finally{URL.revokeObjectURL(r)}};rt=function(t){const e=t.cloneNode(!0),i=t.getBoundingClientRect(),a=t.viewBox?.baseVal,s=Math.round(a?.width||i.width||Number(t.getAttribute("width"))||0),r=Math.round(a?.height||i.height||Number(t.getAttribute("height"))||0);return e.setAttribute("xmlns","http://www.w3.org/2000/svg"),e.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),!e.getAttribute("width")&&s&&e.setAttribute("width",String(s)),!e.getAttribute("height")&&r&&e.setAttribute("height",String(r)),!e.getAttribute("viewBox")&&s&&r&&e.setAttribute("viewBox",`0 0 ${s} ${r}`),c(this,l,T).call(this,t,e),e.querySelectorAll(".highcharts-tooltip, .highcharts-contextmenu, .highcharts-a11y-proxy-container, .highcharts-a11y-dummy-point").forEach(n=>n.remove()),{width:s,height:r,serialized:new XMLSerializer().serializeToString(e)}};T=function(t,e){const i=getComputedStyle(t);let a="";for(let n=0;n<i.length;n+=1){const o=i[n],h=i.getPropertyValue(o);h&&(a+=`${o}:${h};`)}a&&e.setAttribute("style",a);const s=Array.from(t.children),r=Array.from(e.children);for(let n=0;n<s.length;n+=1){const o=s[n],h=r[n];o&&h&&c(this,l,T).call(this,o,h)}};R=async function(t,e,i){const a=Math.max(1,Math.min(2,window.devicePixelRatio||1)),s=Math.max(1,Math.round(e)),r=Math.max(1,Math.round(i)),n=document.createElement("canvas");n.width=Math.max(1,Math.round(s*a)),n.height=Math.max(1,Math.round(r*a));const o=n.getContext("2d");if(!o)return null;const h=await c(this,l,ot).call(this,t);return h?(o.scale(a,a),o.fillStyle=c(this,l,q).call(this),o.fillRect(0,0,s,r),o.drawImage(h,0,0,s,r),n):null};ot=function(t){return new Promise(e=>{const i=new Image;i.crossOrigin="anonymous",i.onload=()=>e(i),i.onerror=()=>e(null),i.src=t})};lt=function(t,e,i){return new Promise(a=>{t.toBlob(s=>a(s),e,i)})};q=function(){const t=this.shadowRoot?.querySelector(".viz-container"),e=getComputedStyle(t??this).backgroundColor;return e&&e!=="rgba(0, 0, 0, 0)"?e:"#ffffff"};B=function(t,e){const i=URL.createObjectURL(t),a=document.createElement("a");a.href=i,a.download=e,document.body.appendChild(a),a.click(),a.remove(),setTimeout(()=>URL.revokeObjectURL(i),0)};H=function(){const t=c(this,l,x).call(this,this.spacing),e=c(this,l,x).call(this,this.spacingTop)??t,i=c(this,l,x).call(this,this.spacingBottom)??t,a=c(this,l,x).call(this,this.spacingLeft),s=c(this,l,x).call(this,this.spacingRight);e?this.style.setProperty("--scb-viz-spacing-block-start",e):this.style.removeProperty("--scb-viz-spacing-block-start"),i?this.style.setProperty("--scb-viz-spacing-block-end",i):this.style.removeProperty("--scb-viz-spacing-block-end"),a?this.style.setProperty("--scb-viz-spacing-inline-start",a):this.style.removeProperty("--scb-viz-spacing-inline-start"),s?this.style.setProperty("--scb-viz-spacing-inline-end",s):this.style.removeProperty("--scb-viz-spacing-inline-end")};x=function(t){if(!t)return;const e=String(t).trim();if(e)return/^\d+$/.test(e)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(e,10)))})`:e};V=function(){const t=this.containerMaxWidth?.trim();t?this.style.setProperty("--scb-viz-container-max-width",t):this.style.removeProperty("--scb-viz-container-max-width")};g.styles=ht`
489
482
  :host {
490
483
  display: block;
491
484
  box-sizing: border-box;
@@ -855,7 +848,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
855
848
  .diagram-content {
856
849
  width: 100%;
857
850
  max-width: var(--scb-viz-content-max-width, 100%);
858
- min-height: var(--scb-viz-diagram-min-height, 420px);
851
+ min-height: var(--scb-viz-diagram-min-height, 600px);
859
852
  height: var(--scb-viz-diagram-height, auto);
860
853
  overflow: var(--scb-viz-diagram-overflow, visible);
861
854
  }
@@ -865,7 +858,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
865
858
  width: 100%;
866
859
  max-width: 100%;
867
860
  min-width: 0;
868
- min-height: var(--scb-viz-diagram-min-height, 420px);
861
+ min-height: var(--scb-viz-diagram-min-height, 600px);
869
862
  height: var(--scb-viz-diagram-height, auto);
870
863
  overflow: var(--scb-viz-diagram-overflow, visible);
871
864
  }
@@ -877,7 +870,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
877
870
  }
878
871
 
879
872
  .standard-content-shell--stable {
880
- min-height: var(--scb-viz-standard-content-height, var(--scb-viz-diagram-min-height, 420px));
873
+ min-height: var(--scb-viz-standard-content-height, var(--scb-viz-diagram-min-height, 600px));
881
874
  }
882
875
 
883
876
  .standard-content-panel {
@@ -904,7 +897,7 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
904
897
  }
905
898
 
906
899
  .standard-content-shell--stable .standard-content-panel--table.standard-content-panel--active {
907
- height: var(--scb-viz-standard-content-height, var(--scb-viz-diagram-min-height, 420px));
900
+ height: var(--scb-viz-standard-content-height, var(--scb-viz-diagram-min-height, 600px));
908
901
  min-height: 0;
909
902
  overflow: hidden;
910
903
  }
@@ -1116,4 +1109,4 @@ import{a as ht,n as m,r as P,i as dt,x as g,k as W,l as pt,t as gt}from"../../ve
1116
1109
  width: calc(100% / var(--scb-viz-print-scale, 1));
1117
1110
  }
1118
1111
  }
1119
- `;u([m({type:String,reflect:!0})],f.prototype,"variant",2);u([m({type:String,reflect:!0,attribute:"selected-chip"})],f.prototype,"selectedChip",2);u([m({type:String,reflect:!0})],f.prototype,"title",2);u([m({type:String,reflect:!0})],f.prototype,"subtitle",2);u([m({type:String,reflect:!0})],f.prototype,"description",2);u([m({type:String,reflect:!0})],f.prototype,"comment",2);u([m({type:String,reflect:!0})],f.prototype,"source",2);u([m({type:String,reflect:!0})],f.prototype,"footnote",2);u([m({type:String,reflect:!0,attribute:"lang"})],f.prototype,"lang",2);u([m({type:String,reflect:!0,attribute:"image-href"})],f.prototype,"imageHref",2);u([m({type:Boolean,reflect:!0,attribute:"official-statistics"})],f.prototype,"officialStatistics",2);u([m({type:Boolean,reflect:!0,attribute:"disable-toggle"})],f.prototype,"disableToggle",2);u([m({type:String,attribute:"content-max-width"})],f.prototype,"contentMaxWidth",2);u([m({type:String,attribute:"container-max-width"})],f.prototype,"containerMaxWidth",2);u([m({type:String,attribute:"content-height"})],f.prototype,"contentHeight",2);u([m({type:String,reflect:!0,attribute:"toggle-height-mode"})],f.prototype,"toggleHeightMode",2);u([m({attribute:!1})],f.prototype,"tableData",2);u([m({attribute:!1})],f.prototype,"valueFormat",2);u([m({attribute:!1})],f.prototype,"timeFormat",2);u([m({attribute:!1})],f.prototype,"yAxisSettings",2);u([P()],f.prototype,"_slottedTableData",2);u([P()],f.prototype,"_actionsMenuOpen",2);u([P()],f.prototype,"_seriesDifferentiationEnabled",2);u([m({type:String,reflect:!0})],f.prototype,"spacing",2);u([m({type:String,attribute:"spacing-top",reflect:!0})],f.prototype,"spacingTop",2);u([m({type:String,attribute:"spacing-bottom",reflect:!0})],f.prototype,"spacingBottom",2);u([m({type:String,attribute:"spacing-left",reflect:!0})],f.prototype,"spacingLeft",2);u([m({type:String,attribute:"spacing-right",reflect:!0})],f.prototype,"spacingRight",2);f=u([gt("scb-viz")],f);
1112
+ `;u([m({type:String,reflect:!0})],g.prototype,"variant",2);u([m({type:String,reflect:!0,attribute:"selected-chip"})],g.prototype,"selectedChip",2);u([m({type:String,reflect:!0})],g.prototype,"title",2);u([m({type:String,reflect:!0})],g.prototype,"subtitle",2);u([m({type:String,reflect:!0})],g.prototype,"description",2);u([m({type:String,reflect:!0})],g.prototype,"comment",2);u([m({type:String,reflect:!0})],g.prototype,"source",2);u([m({type:String,reflect:!0})],g.prototype,"footnote",2);u([m({type:String,reflect:!0,attribute:"lang"})],g.prototype,"lang",2);u([m({type:String,reflect:!0,attribute:"image-href"})],g.prototype,"imageHref",2);u([m({type:Boolean,reflect:!0,attribute:"official-statistics"})],g.prototype,"officialStatistics",2);u([m({type:Boolean,reflect:!0,attribute:"disable-toggle"})],g.prototype,"disableToggle",2);u([m({type:String,attribute:"content-max-width"})],g.prototype,"contentMaxWidth",2);u([m({type:String,attribute:"container-max-width"})],g.prototype,"containerMaxWidth",2);u([m({type:String,attribute:"content-height"})],g.prototype,"contentHeight",2);u([m({type:String,reflect:!0,attribute:"toggle-height-mode"})],g.prototype,"toggleHeightMode",2);u([m({attribute:!1})],g.prototype,"tableData",2);u([m({attribute:!1})],g.prototype,"valueFormat",2);u([m({attribute:!1})],g.prototype,"timeFormat",2);u([m({attribute:!1})],g.prototype,"yAxisSettings",2);u([P()],g.prototype,"_slottedTableData",2);u([P()],g.prototype,"_actionsMenuOpen",2);u([P()],g.prototype,"_seriesDifferentiationEnabled",2);u([m({type:String,reflect:!0})],g.prototype,"spacing",2);u([m({type:String,attribute:"spacing-top",reflect:!0})],g.prototype,"spacingTop",2);u([m({type:String,attribute:"spacing-bottom",reflect:!0})],g.prototype,"spacingBottom",2);u([m({type:String,attribute:"spacing-left",reflect:!0})],g.prototype,"spacingLeft",2);u([m({type:String,attribute:"spacing-right",reflect:!0})],g.prototype,"spacingRight",2);g=u([gt("scb-viz")],g);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "scb-wc-test",
3
- "version": "0.1.310",
3
+ "version": "0.1.312",
4
4
  "type": "module",
5
5
  "main": "index.js",
6
6
  "module": "index.js",
@@ -390,5 +390,5 @@
390
390
  },
391
391
  "./mvc/*": "./mvc/*"
392
392
  },
393
- "buildHash": "DBE9079A841527D06721E262F0AA235EB2C2827D4D99FE9275E9CB934BA89ED5"
393
+ "buildHash": "C4BF30B40B1B462DE0031F8C63B0E010271517006995DDC0524A75B5CFD21925"
394
394
  }
@@ -24,6 +24,7 @@ export declare class ScbHorizontalScroller extends LitElement {
24
24
  private _canScrollLeft;
25
25
  private _canScrollRight;
26
26
  static styles: import('lit').CSSResult;
27
+ private getScrollStep;
27
28
  private doScrollBy;
28
29
  private updateScrollButtons;
29
30
  connectedCallback(): void;