@mattilsynet/design 2.2.9 → 2.11.0-canary

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,11 +1,11 @@
1
- var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnPropertySymbols,os=Object.prototype.hasOwnProperty,is=Object.prototype.propertyIsEnumerable,an=(t,e,n)=>e in t?ns(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,ss=(t,e)=>{for(var n in e||(e={}))os.call(e,n)&&an(t,n,e[n]);if(rn)for(var n of rn(e))is.call(e,n)&&an(t,n,e[n]);return t},xt=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",ln=xt&&/android/i.test(navigator.userAgent),rs=xt&&/firefox/i.test(navigator.userAgent),as=xt&&/iPad|iPhone|iPod/.test(navigator.userAgent),cn;xt&&/^Mac/i.test(((cn=navigator.userAgentData)==null?void 0:cn.platform)||navigator.platform);var ls="outline: 1px dotted; outline: 5px auto Highlight; outline: 5px auto -webkit-focus-ring-color",cs=typeof HTMLElement>"u"?class{}:HTMLElement;function y(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var dn=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Dt=(t,...e)=>dn("add",t,e),ds=(t,...e)=>dn("remove",t,e),Nt=new WeakMap,be=(t,e)=>{if(e===void 0)return Nt.get(t);try{Nt.get(t).disconnect(),Nt.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),Nt.set(t,n)}},us=t=>{const e="key"in t&&(t.key===" "||t.key==="Enter");return e&&t.preventDefault(),e&&t.target instanceof HTMLElement&&t.target.click(),e},fs=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},ps=0,un=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++ps).toString(32)}`),t.id):"",Ht=(t,e,n)=>{const o=document.createElement(t);if(e&&(o.textContent=e),n)for(const[i,s]of Object.entries(n))y(o,i,s);return o},ms={define:(t,e)=>!xt||window.customElements.get(t)||window.customElements.define(t,e)},hs=t=>{var e;const n=y(t,"aria-label")||"";return[...(((e=y(t,"aria-labelledby"))==null?void 0:e.trim().split(/\s+/))||[]).map(i=>document.getElementById(i)),...Array.from(t.labels||[])].reduce((i,s)=>{var r;return i||((r=s?.innerText)==null?void 0:r.trim())||""},n)},nt,bs=0,ge=t=>{nt||(nt=Ht("div"),nt.style.cssText="position:fixed;overflow:hidden;width:1px;white-space:nowrap",y(nt,"aria-live","assertive")),nt.isConnected||document.body.append(nt),t&&(nt.textContent=`${t}${bs++%2?" ":""}`)},fn=(t,e,n="")=>{var o,i;const s={bubbles:!0,composed:!0,data:e,inputType:n},r=HTMLInputElement.prototype;t.dispatchEvent(new InputEvent("beforeinput",s)),(i=(o=Object.getOwnPropertyDescriptor(r,"value"))==null?void 0:o.set)==null||i.call(t,e),t.dispatchEvent(new InputEvent("input",s)),t.dispatchEvent(new Event("change",{bubbles:!0}))},ve=!1,_e=t=>(t?.type==="mouseup"&&(ve=!1),t?.type==="mousedown"&&(ve=!0,Dt(document,"mouseup",_e,{once:!0})),ve),gs=`:host(:not([hidden])) { display: block; -webkit-tap-highlight-color: rgba(0, 0, 0, 0) } /* Must be display block in Safari to allow focus inside */
1
+ var mtds=function(O){"use strict";var os=Object.defineProperty,an=Object.getOwnPropertySymbols,is=Object.prototype.hasOwnProperty,ss=Object.prototype.propertyIsEnumerable,rn=(t,e,n)=>e in t?os(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,as=(t,e)=>{for(var n in e||(e={}))is.call(e,n)&&rn(t,n,e[n]);if(an)for(var n of an(e))ss.call(e,n)&&rn(t,n,e[n]);return t},xt=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",ln=xt&&/android/i.test(navigator.userAgent),rs=xt&&/firefox/i.test(navigator.userAgent),ls=xt&&/iPad|iPhone|iPod/.test(navigator.userAgent),cn;xt&&/^Mac/i.test(((cn=navigator.userAgentData)==null?void 0:cn.platform)||navigator.platform);var cs="outline: 1px dotted; outline: 5px auto Highlight; outline: 5px auto -webkit-focus-ring-color",ds=typeof HTMLElement>"u"?class{}:HTMLElement;function x(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var dn=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Dt=(t,...e)=>dn("add",t,e),us=(t,...e)=>dn("remove",t,e),Nt=new WeakMap,ge=(t,e)=>{if(e===void 0)return Nt.get(t);try{Nt.get(t).disconnect(),Nt.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),Nt.set(t,n)}},fs=t=>{const e="key"in t&&(t.key===" "||t.key==="Enter");return e&&t.preventDefault(),e&&t.target instanceof HTMLElement&&t.target.click(),e},ps=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},hs=0,un=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++hs).toString(32)}`),t.id):"",Ht=(t,e,n)=>{const o=document.createElement(t);if(e&&(o.textContent=e),n)for(const[i,s]of Object.entries(n))x(o,i,s);return o},ms={define:(t,e)=>!xt||window.customElements.get(t)||window.customElements.define(t,e)},gs=t=>{var e;const n=x(t,"aria-label")||"";return[...(((e=x(t,"aria-labelledby"))==null?void 0:e.trim().split(/\s+/))||[]).map(i=>document.getElementById(i)),...Array.from(t.labels||[])].reduce((i,s)=>{var a;return i||((a=s?.innerText)==null?void 0:a.trim())||""},n)},nt,bs=0,be=t=>{nt||(nt=Ht("div"),nt.style.cssText="position:fixed;overflow:hidden;width:1px;white-space:nowrap",x(nt,"aria-live","assertive")),nt.isConnected||document.body.append(nt),t&&(nt.textContent=`${t}${bs++%2?" ":""}`)},fn=(t,e,n="")=>{var o,i;const s={bubbles:!0,composed:!0,data:e,inputType:n},a=HTMLInputElement.prototype;t.dispatchEvent(new InputEvent("beforeinput",s)),(i=(o=Object.getOwnPropertyDescriptor(a,"value"))==null?void 0:o.set)==null||i.call(t,e),t.dispatchEvent(new InputEvent("input",s)),t.dispatchEvent(new Event("change",{bubbles:!0}))},ve=!1,_e=t=>(t?.type==="mouseup"&&(ve=!1),t?.type==="mousedown"&&(ve=!0,Dt(document,"mouseup",_e,{once:!0})),ve),vs=`:host(:not([hidden])) { display: block; -webkit-tap-highlight-color: rgba(0, 0, 0, 0) } /* Must be display block in Safari to allow focus inside */
2
2
  :host(:not([data-multiple])) ::slotted(data),
3
3
  :host([data-multiple="false"]) ::slotted(data) { display: none } /* Hide data if not multiple */
4
4
  ::slotted(input[inputmode="none"]) { outline: none } /* Hide temporary foucs outline flash */
5
5
  ::slotted(del) { text-decoration: none }
6
6
  ::slotted(data:not([hidden])) { display: inline-block; pointer-events: none }
7
7
  ::slotted(data)::after { content: '\\00D7'; content: '\\00D7' / ''; padding-inline: .5ch; pointer-events: auto; cursor: pointer }
8
- ::slotted(data:focus) { ${ls} }`,pn="beforeinput,blur,focus,click,input,keydown,mousedown",mn={once:!0,passive:!0},vs=rs&&!ln,_s=ln||as,hn="​".repeat(5),Bt="false",jt={added:"Added",empty:"No selected",found:"Navigate left to find %d selected",invalid:"Invalid value",of:"of",remove:"Press to remove",removed:"Removed"},ye=class extends cs{constructor(){super(),this._item="",this._speak="",this._texts=ss({},jt),this._value="",this.shadowRoot||this.attachShadow({mode:"open"}).append(Ht("slot"),Ht("style",gs))}static get observedAttributes(){return Object.keys(jt).map(t=>`data-sr-${t}`)}connectedCallback(){this._root=fs(this),Dt(this,pn,this,!0),be(this,{attributeFilter:["value","id"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),setTimeout(Ft,0,this),setTimeout(Ut,0,this)}attributeChangedCallback(t,e,n){const o=t.split("data-sr-")[1];jt[o]&&(this._texts[o]=n||jt[o])}disconnectedCallback(){be(this,!1),ds(this,pn,this,!0),this._items=this._clear=this._focus=this._control=void 0,this._list=this._options=this._root=void 0}handleEvent(t){const e=t.target;xe(this)||(t.type==="beforeinput"&&(this._value=e?.value||""),t.type==="blur"&&ws(this),t.type==="click"&&Es(this,t),t.type==="focus"&&ys(this,t),t.type==="input"&&Ss(this,t),t.type==="keydown"&&Ts(this,t),t.type==="mousedown"&&_e(t),t.type==="mutation"&&Ft(this,t))}get multiple(){var t;return((t=y(this,"data-multiple"))!=null?t:Bt)!==Bt}set multiple(t){y(this,"data-multiple",t?"":null)}get creatable(){var t;return((t=y(this,"data-creatable"))!=null?t:Bt)!==Bt}set creatable(t){y(this,"data-creatable",t?"":null)}get control(){var t;return(t=this._control)!=null&&t.isConnected||(this._control=this.querySelector("input")),this._control}get list(){var t;return(t=this._list)!=null&&t.isConnected||(this._list=this.querySelector("u-datalist,datalist")),this._list}get clear(){var t;return(t=this._clear)!=null&&t.isConnected||(this._clear=this.querySelector("del")),this._clear}get items(){return this._items||(this._items=this.getElementsByTagName("data")),this._items}get options(){var t,e;if(!this._options){const n=((t=this.list)==null?void 0:t.nodeName)==="U-DATALIST"?"u-option":"option";this._options=(e=this.list)==null?void 0:e.getElementsByTagName(n)}return this._options}get values(){return[...this.items].map(({value:t})=>t)}},ot=t=>{var e;return((e=t?.textContent)==null?void 0:e.trim())||""},we=t=>t instanceof HTMLDataElement,xe=({control:t})=>t?.disabled||t?.readOnly||!1,Ft=(t,e)=>{var n;const{_focus:o,_texts:i,items:s,control:r,list:a,multiple:c}=t;if(!r||!a)return;const l=hs(r),d=l.endsWith(hn)?y(r,"data-label"):l;y(r,"data-label",d);let u=`${d}${c?`, ${s.length?i.found.replace("%d",`${s.length}`):i.empty}`:""}`;const m=[];for(const{addedNodes:b,removedNodes:x}of e?.detail||[]){for(const w of b)we(w)&&m.unshift(w);for(const w of x)we(w)&&m.push(w)}const p=c?m.length===1:m[0]===o;if(o&&p){const b=y(r,"aria-expanded"),x=y(r,"inputmode"),w=we(o)?r:o,S=!m[0].isConnected;t._speak=`${i[S?"removed":"added"]} ${ot(m[0])}, `,(_s||o===r)&&ge(t._speak),r!==w&&(y(r,"aria-expanded",null),y(r,"inputmode","none"),u=" ",r.focus()),setTimeout(()=>{var N;y(r,"aria-expanded",b),y(r,"inputmode",S?"none":x),(N=w?.focus)==null||N.call(w),y(r,"inputmode",x),t._speak="",vs?Dt(t,"blur",()=>Ft(t),mn):setTimeout(Ft,100,t)},100)}let g=0;const h=t.querySelector("select"),_=xe(t)?"":`${i.remove}, `;for(const b of s){const x=h?.options[g],w=ot(b),S=b.value||w,N=`${t._speak}${w}, ${_}${++g} ${i.of} ${s.length}`;y(b,"role","button"),y(b,"value",S),y(b,"tabindex","-1"),y(b,"aria-label",N),x?Object.assign(x,{textContent:w,value:S}):h?.appendChild(new Option(w,S,!0,!0))}h&&y(h,"multiple",c?"":null);for(const b of[...h?.options||[]].slice(g))b.remove();!c&&g>1&&console.warn("u-combobox: Multiple <data> found in single mode."),y(a,"aria-multiselectable",`${c}`),y(r,"list",un(a)),y(r,"aria-label",`${t._speak}${u}${hn}`),a.hasAttribute("popover")&&(y(r,"popovertarget",un(a)),y(a,"popover","manual"));const v=ot(s[0]);v!==t._item&&Ut(t),t._item=v,bn(t),gn(t),(n=be(t))==null||n.takeRecords()},bn=t=>{var e;t.clear&&y(t.clear,"role","button"),t.clear&&(t.clear.hidden=!((e=t.control)!=null&&e.value)||xe(t))},gn=t=>{var e;const{_speak:n,options:o=[],values:i}=t;for(const s of o){const r=(e=y(s,"value"))!=null?e:ot(s);y(s,"aria-label",n?`${n}${ot(s)}`:null),y(s,"selected",i.includes(r)?"":null)}},Ut=t=>{const{multiple:e,control:n,items:o}=t,i=ot(o[0]);!e&&n&&i!==n.value&&fn(n,i,i?"insertText":"deleteContent")},Ee=(t,e=!0)=>{var n;const{_texts:o,options:i=[],creatable:s,control:r,items:a,multiple:c}=t,l=((n=r?.value)==null?void 0:n.trim())||"",d=l.toLowerCase()||null;let u=[...i].find(p=>(y(p,"label")||ot(p)).trim().toLowerCase()===d);const m={bubbles:!0,cancelable:!0,detail:u};if(t.dispatchEvent(new CustomEvent("comboboxbeforematch",m))||(u=[...i].find(p=>p.selected)),e)return gn(t),u?mt(t,u,!1):s&&l?mt(t,{value:l},!1):(!c&&!l&&a[0]?mt(t,a[0]):Ut(t),ge(o.invalid));for(const p of i)p.selected=p===u},mt=(t,e,n=!0)=>{const{control:o,items:i,multiple:s}=t,r=Ht("data",e.label||e.value,{value:e.value}),a=[...i].find(d=>d.value===e.value),c={bubbles:!0,cancelable:!0,detail:a||r};if(a&&!n)return Ut(t);if(t.dispatchEvent(new CustomEvent("comboboxbeforeselect",c))){if(!s)for(const d of[...i])d.remove();a?a.remove():o?.insertAdjacentElement("beforebegin",r),t.dispatchEvent(new CustomEvent("comboboxafterselect",c))}},ys=(t,{target:e})=>{e instanceof HTMLElement&&(t._focus=e),ge()},ws=t=>_e()||setTimeout(xs,0,t),xs=t=>{var e;!t._focus||t.contains((e=t._root)==null?void 0:e.activeElement)||(t.multiple||Ee(t),t._focus=void 0)},Es=(t,e)=>{const{clientX:n,clientY:o,target:i}=e,{clear:s,control:r,items:a}=t;if(s?.contains(i))return r&&fn(r,"","deleteContentBackward"),r?.focus();for(const c of a){const{top:l,right:d,bottom:u,left:m}=c.getBoundingClientRect();if(c.contains(i))return mt(t,c);if(o>=l&&o<=u&&n>=m&&n<=d)return c.focus()}i===t&&r?.focus()},Ss=(t,e)=>{var n;const{options:o=[],control:i,multiple:s}=t,r=((n=i?.value)==null?void 0:n.trim())||"";if(e instanceof InputEvent?!e.inputType||e.inputType==="insertReplacementText":!!r){e.stopImmediatePropagation(),i&&(i.value=t._value);for(const c of o)if(c.value&&c.value===r)return mt(t,c,s)}else s||Ee(t,!1);bn(t)},Ts=(t,e)=>{var n;if(e.altKey||e.ctrlKey||e.metaKey||e.shiftKey)return;const{clear:o,control:i,items:s}=t,{key:r,repeat:a,target:c}=e,l=i&&i===c,d=l&&i?.selectionEnd;let u=l?s.length:[...s].indexOf(c);if(l&&r==="Tab"&&o&&!o.hidden&&(e.preventDefault(),o.tabIndex=-1,o.focus(),Dt(o,"blur",()=>y(o,"tabindex",null),mn)),!(!l&&us(e)||u===-1)){if(r==="ArrowRight"&&!l)u+=1;else if(r==="ArrowLeft"&&!d)u-=1;else if(r==="Enter"&&l){const m=y(i,"form");return y(i,"form","#"),requestAnimationFrame(()=>y(i,"form",m)),Ee(t)}else if((r==="Backspace"||r==="Delete")&&!d){if(e.preventDefault(),!a&&s[u])return mt(t,s[u]);l&&(u-=1)}else return l||i?.focus();e.preventDefault(),(n=s[Math.max(0,u)]||i)==null||n.focus()}};ms.define("u-combobox",ye);var Se=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",$s=Se&&/android/i.test(navigator.userAgent),vn;Se&&/^Mac/i.test(((vn=navigator.userAgentData)==null?void 0:vn.platform)||navigator.platform);var Cs=`${$s?"data":"aria"}-labelledby`,Te=":host(:not([hidden])) { display: block }",qt=typeof HTMLElement>"u"?class{}:HTMLElement;function A(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var _n=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},ks=(t,...e)=>_n("add",t,e),As=(t,...e)=>_n("remove",t,e),Vt=(t,e)=>t.shadowRoot||t.attachShadow({mode:"open"}).append(En("slot"),En("style",e)),zt=new WeakMap,yn=(t,e)=>{if(e===void 0)return zt.get(t);try{zt.get(t).disconnect(),zt.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),zt.set(t,n)}},Ls=t=>{const e="key"in t&&(t.key===" "||t.key==="Enter");return e&&t.preventDefault(),e&&t.target instanceof HTMLElement&&t.target.click(),e},wn=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},Is=0,xn=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++Is).toString(32)}`),t.id):"",En=(t,e,n)=>{const o=document.createElement(t);return e&&(o.textContent=e),o},Wt={define:(t,e)=>!Se||window.customElements.get(t)||window.customElements.define(t,e)},Ms=Te,Os=Te,Rs=Te,Ps=':host(:not([hidden])) { display: inline-block; cursor: pointer }:host([aria-disabled="true"]) { cursor: default }',Gt="aria-controls",ht="aria-selected",Sn=class extends qt{constructor(){super(),Vt(this,Ms)}get tabList(){return Yt("u-tablist",this)[0]||null}get selectedIndex(){return Kt(this.tabs)}set selectedIndex(t){ke(this.tabs[t])}get tabs(){return Yt("u-tab",this)}get panels(){return Yt("u-tabpanel",this)}},Tn=class extends qt{constructor(){super(),Vt(this,Os)}connectedCallback(){A(this,"role","tablist"),ks(this,"click,keydown",this),yn(this,{childList:!0}),this.tabs.length&&this.handleEvent()}disconnectedCallback(){As(this,"click,keydown",this),yn(this,!1)}handleEvent(t){if(!t||t.type==="mutation"){const s=this.tabs[Math.max(this.selectedIndex,0)];return s?.setAttribute(ht,"true")}const{key:e}=t,n=[...this.tabs],o=n.findIndex(s=>s.contains(t.target));let i=o;if(!(t.defaultPrevented||o===-1)&&(t.type==="click"&&ke(n[o]),t.type==="keydown"&&!Ls(t))){if(e==="ArrowDown"||e==="ArrowRight")i=(o+1)%n.length;else if(e==="ArrowUp"||e==="ArrowLeft")i=(o||n.length)-1;else if(e==="End")i=n.length-1;else if(e==="Home")i=0;else if(e==="Tab")i=Kt(n);else return;setTimeout(()=>{n[o].tabIndex=-1,n[i].tabIndex=0}),e!=="Tab"&&(t.preventDefault(),n[i].focus())}}get tabsElement(){return this.closest("u-tabs")}get tabs(){return this.querySelectorAll("u-tab")}get selectedIndex(){return Kt(this.tabs)}set selectedIndex(t){ke(this.tabs[t])}},$e=!1,$n=class extends qt{static get observedAttributes(){return["id",ht,Gt]}constructor(){super(),Vt(this,Ps)}connectedCallback(){A(this,"role","tab"),this.tabIndex=this.selected?0:-1}attributeChangedCallback(){if(!$e&&this.selected&&this.tabList){$e=!0;const t=[...this.tabList.querySelectorAll("u-tab")],e=Yt("u-tabpanel",this.tabsElement||this),n=Ce(this,e[t.indexOf(this)]);n&&A(n,Cs,xn(this)),t.forEach((o,i)=>{const s=Ce(o,e[i]);o.tabIndex=o===this?0:-1,A(o,ht,`${o===this}`),A(o,Gt,s?.id||null),s&&(s.hidden=s!==n)}),$e=!1}}get tabsElement(){return this.closest("u-tabs")}get tabList(){const t=this.parentElement;return t?.nodeName==="U-TABLIST"?t:null}get selected(){return A(this,ht)==="true"}set selected(t){A(this,ht,`${!!t}`)}get index(){const t=this.tabList;return t?[...t.querySelectorAll("u-tab")].indexOf(this):0}get panel(){return Ce(this)}},Cn=class extends qt{static get observedAttributes(){return["hidden"]}constructor(){super(),Vt(this,Rs)}connectedCallback(){A(this,"role","tabpanel"),this.hidden=Kt(this.tabs)===-1,this.attributeChangedCallback()}attributeChangedCallback(){const t=this.hidden;A(this,"aria-hidden",`${t}`),A(this,"tabindex",t||Ds(this.firstChild)?null:"0")}get tabsElement(){return this.closest("u-tabs")}get tabs(){const t=`u-tab[${Gt}="${this.id}"]`;return wn(this).querySelectorAll(t)}},Yt=(t,e)=>e.querySelectorAll(`${t}:not(:scope u-tabpanel ${t})`),Ce=(t,e)=>{const n=A(t,Gt)||xn(e),o=wn(t).getElementById(n);return o?.nodeName==="U-TABPANEL"?o:null},Kt=t=>[...t].findIndex(e=>A(e,ht)==="true"),ke=t=>t&&A(t,"aria-disabled")!=="true"&&A(t,"aria-selected","true"),Ds=t=>t instanceof Element&&!t.matches(':disabled,[tabindex^="-"]')&&t.matches('[contenteditable],[controls],[href],[tabindex],input:not([type="hidden"]),select,textarea,button,summary,iframe');Wt.define("u-tabs",Sn),Wt.define("u-tablist",Tn),Wt.define("u-tab",$n),Wt.define("u-tabpanel",Cn);const Ns="2.2.9",kn="_alert_3aj69_1 _ds-alert_14b25_3",An="_app_3aj69_1",Ln="_sticky_3aj69_1",In="_avatar_3aj69_1 _ds-avatar_14b25_1",Mn="_badge_3aj69_1",On="_breadcrumbs_3aj69_1 _ds-breadcrumbs_14b25_5",Rn="_button_3aj69_1 _ds-button_14b25_1",Pn="_card_3aj69_1",Dn="_group_3aj69_1",Nn="_chip_3aj69_1 _ds-chip_14b25_5",Hn="_details_3aj69_1 _ds-details_14b25_3",Bn="_dialog_3aj69_1 _ds-dialog_14b25_5",jn="__drawer_3aj69_1",Fn="_divider_3aj69_1",Un="_errorsummary_3aj69_1 _ds-error-summary_14b25_5",qn="__errorsummary_3aj69_1",Vn="_field_3aj69_1 _ds-field_14b25_1",zn="__datalist_3aj69_1",Wn="_affixes_3aj69_1 _ds-field-affixes_14b25_3",Gn="_fieldset_3aj69_1 _ds-fieldset_14b25_3",Yn="_helptext_3aj69_1 _ds-focus_14b25_1",Kn="_input_3aj69_1 _ds-input_14b25_1",Xn="_grid_3aj69_1",Qn="_flex_3aj69_1",Jn="_link_3aj69_1",Zn="_logo_3aj69_1",to="_pagination_3aj69_1 _ds-pagination_14b25_5",eo="_popover_3aj69_1",no="_progress_3aj69_1",oo="__indeterminate_3aj69_1",io="_skeleton_3aj69_1 _ds-skeleton_14b25_5",so="__skeleton_3aj69_1",ro="_spinner_3aj69_1",ao="_steps_3aj69_1",lo="_table_3aj69_1 _ds-table_14b25_5",co="__scrollShadow_3aj69_1",uo="_tabs_3aj69_1 _ds-tabs_14b25_5",fo="__scrollMask_3aj69_1",po="_tag_3aj69_1 _ds-tag_14b25_5",mo="_toast_3aj69_1",ho="__toastClose_3aj69_1",bo="__toastOpen_3aj69_1",go="__toastTimeout_3aj69_1",vo="_togglegroup_3aj69_1",_o="__tooltip_3aj69_1",yo="_heading_3aj69_1 _ds-heading_14b25_1",wo="_ingress_3aj69_1",xo="_muted_3aj69_1",Eo="_info_3aj69_1",So="_prose_3aj69_1",To="_validation_3aj69_1 _ds-validation-message_14b25_1",$o="_body_3aj69_173",Co="__checked_3aj69_1",T={alert:kn,app:An,sticky:Ln,avatar:In,badge:Mn,breadcrumbs:On,button:Rn,card:Pn,group:Dn,chip:Nn,details:Hn,dialog:Bn,_drawer:jn,divider:Fn,errorsummary:Un,_errorsummary:qn,field:Vn,_datalist:zn,affixes:Wn,fieldset:Gn,helptext:Yn,input:Kn,grid:Xn,flex:Qn,link:Jn,logo:Zn,pagination:to,popover:eo,progress:no,_indeterminate:oo,skeleton:io,_skeleton:so,spinner:ro,steps:ao,table:lo,_scrollShadow:co,tabs:uo,_scrollMask:fo,tag:po,toast:mo,_toastClose:ho,_toastOpen:bo,_toastTimeout:go,togglegroup:vo,_tooltip:_o,heading:yo,ingress:wo,muted:xo,info:Eo,prose:So,validation:To,body:$o,_checked:Co},Hs=Object.freeze(Object.defineProperty({__proto__:null,_checked:Co,_datalist:zn,_drawer:jn,_errorsummary:qn,_indeterminate:oo,_scrollMask:fo,_scrollShadow:co,_skeleton:so,_toastClose:ho,_toastOpen:bo,_toastTimeout:go,_tooltip:_o,affixes:Wn,alert:kn,app:An,avatar:In,badge:Mn,body:$o,breadcrumbs:On,button:Rn,card:Pn,chip:Nn,default:T,details:Hn,dialog:Bn,divider:Fn,errorsummary:Un,field:Vn,fieldset:Gn,flex:Qn,grid:Xn,group:Dn,heading:yo,helptext:Yn,info:Eo,ingress:wo,input:Kn,link:Jn,logo:Zn,muted:xo,pagination:to,popover:eo,progress:no,prose:So,skeleton:io,spinner:ro,steps:ao,sticky:Ln,table:lo,tabs:uo,tag:po,toast:mo,togglegroup:vo,validation:To},Symbol.toStringTag,{value:"Module"})),bt=Math.min,O=Math.max,Xt=Math.round,Qt=Math.floor,V=t=>({x:t,y:t}),Bs={left:"right",right:"left",bottom:"top",top:"bottom"},js={start:"end",end:"start"};function ko(t,e,n){return O(t,bt(e,n))}function Jt(t,e){return typeof t=="function"?t(e):t}function it(t){return t.split("-")[0]}function Zt(t){return t.split("-")[1]}function Ao(t){return t==="x"?"y":"x"}function Lo(t){return t==="y"?"height":"width"}const Fs=new Set(["top","bottom"]);function Q(t){return Fs.has(it(t))?"y":"x"}function Io(t){return Ao(Q(t))}function Us(t,e,n){n===void 0&&(n=!1);const o=Zt(t),i=Io(t),s=Lo(i);let r=i==="x"?o===(n?"end":"start")?"right":"left":o==="start"?"bottom":"top";return e.reference[s]>e.floating[s]&&(r=te(r)),[r,te(r)]}function qs(t){const e=te(t);return[Ae(t),e,Ae(e)]}function Ae(t){return t.replace(/start|end/g,e=>js[e])}const Mo=["left","right"],Oo=["right","left"],Vs=["top","bottom"],zs=["bottom","top"];function Ws(t,e,n){switch(t){case"top":case"bottom":return n?e?Oo:Mo:e?Mo:Oo;case"left":case"right":return e?Vs:zs;default:return[]}}function Gs(t,e,n,o){const i=Zt(t);let s=Ws(it(t),n==="start",o);return i&&(s=s.map(r=>r+"-"+i),e&&(s=s.concat(s.map(Ae)))),s}function te(t){return t.replace(/left|right|bottom|top/g,e=>Bs[e])}function Ys(t){return{top:0,right:0,bottom:0,left:0,...t}}function Ks(t){return typeof t!="number"?Ys(t):{top:t,right:t,bottom:t,left:t}}function ee(t){const{x:e,y:n,width:o,height:i}=t;return{width:o,height:i,top:n,left:e,right:e+o,bottom:n+i,x:e,y:n}}function Ro(t,e,n){let{reference:o,floating:i}=t;const s=Q(e),r=Io(e),a=Lo(r),c=it(e),l=s==="y",d=o.x+o.width/2-i.width/2,u=o.y+o.height/2-i.height/2,m=o[a]/2-i[a]/2;let p;switch(c){case"top":p={x:d,y:o.y-i.height};break;case"bottom":p={x:d,y:o.y+o.height};break;case"right":p={x:o.x+o.width,y:u};break;case"left":p={x:o.x-i.width,y:u};break;default:p={x:o.x,y:o.y}}switch(Zt(e)){case"start":p[r]-=m*(n&&l?-1:1);break;case"end":p[r]+=m*(n&&l?-1:1);break}return p}const Xs=async(t,e,n)=>{const{placement:o="bottom",strategy:i="absolute",middleware:s=[],platform:r}=n,a=s.filter(Boolean),c=await(r.isRTL==null?void 0:r.isRTL(e));let l=await r.getElementRects({reference:t,floating:e,strategy:i}),{x:d,y:u}=Ro(l,o,c),m=o,p={},g=0;for(let h=0;h<a.length;h++){const{name:_,fn:v}=a[h],{x:b,y:x,data:w,reset:S}=await v({x:d,y:u,initialPlacement:o,placement:m,strategy:i,middlewareData:p,rects:l,platform:r,elements:{reference:t,floating:e}});d=b??d,u=x??u,p={...p,[_]:{...p[_],...w}},S&&g<=50&&(g++,typeof S=="object"&&(S.placement&&(m=S.placement),S.rects&&(l=S.rects===!0?await r.getElementRects({reference:t,floating:e,strategy:i}):S.rects),{x:d,y:u}=Ro(l,m,c)),h=-1)}return{x:d,y:u,placement:m,strategy:i,middlewareData:p}};async function Le(t,e){var n;e===void 0&&(e={});const{x:o,y:i,platform:s,rects:r,elements:a,strategy:c}=t,{boundary:l="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:m=!1,padding:p=0}=Jt(e,t),g=Ks(p),_=a[m?u==="floating"?"reference":"floating":u],v=ee(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(_)))==null||n?_:_.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:l,rootBoundary:d,strategy:c})),b=u==="floating"?{x:o,y:i,width:r.floating.width,height:r.floating.height}:r.reference,x=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),w=await(s.isElement==null?void 0:s.isElement(x))?await(s.getScale==null?void 0:s.getScale(x))||{x:1,y:1}:{x:1,y:1},S=ee(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:b,offsetParent:x,strategy:c}):b);return{top:(v.top-S.top+g.top)/w.y,bottom:(S.bottom-v.bottom+g.bottom)/w.y,left:(v.left-S.left+g.left)/w.x,right:(S.right-v.right+g.right)/w.x}}const Qs=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var n,o;const{placement:i,middlewareData:s,rects:r,initialPlacement:a,platform:c,elements:l}=e,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:m,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:h=!0,..._}=Jt(t,e);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const v=it(i),b=Q(a),x=it(a)===a,w=await(c.isRTL==null?void 0:c.isRTL(l.floating)),S=m||(x||!h?[te(a)]:qs(a)),N=g!=="none";!m&&N&&S.push(...Gs(a,h,g,w));const G=[a,...S],dt=await Le(e,_),ut=[];let X=((o=s.flip)==null?void 0:o.overflows)||[];if(d&&ut.push(dt[v]),u){const ft=Us(i,r,w);ut.push(dt[ft[0]],dt[ft[1]])}if(X=[...X,{placement:i,overflows:ut}],!ut.every(ft=>ft<=0)){var Mt,Ot;const ft=(((Mt=s.flip)==null?void 0:Mt.index)||0)+1,sn=G[ft];if(sn&&(!(u==="alignment"?b!==Q(sn):!1)||X.every(q=>Q(q.placement)===b?q.overflows[0]>0:!0)))return{data:{index:ft,overflows:X},reset:{placement:sn}};let Pt=(Ot=X.filter(pt=>pt.overflows[0]<=0).sort((pt,q)=>pt.overflows[1]-q.overflows[1])[0])==null?void 0:Ot.placement;if(!Pt)switch(p){case"bestFit":{var Rt;const pt=(Rt=X.filter(q=>{if(N){const et=Q(q.placement);return et===b||et==="y"}return!0}).map(q=>[q.placement,q.overflows.filter(et=>et>0).reduce((et,wl)=>et+wl,0)]).sort((q,et)=>q[1]-et[1])[0])==null?void 0:Rt[0];pt&&(Pt=pt);break}case"initialPlacement":Pt=a;break}if(i!==Pt)return{reset:{placement:Pt}}}return{}}}},Js=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:o,placement:i}=e,{mainAxis:s=!0,crossAxis:r=!1,limiter:a={fn:_=>{let{x:v,y:b}=_;return{x:v,y:b}}},...c}=Jt(t,e),l={x:n,y:o},d=await Le(e,c),u=Q(it(i)),m=Ao(u);let p=l[m],g=l[u];if(s){const _=m==="y"?"top":"left",v=m==="y"?"bottom":"right",b=p+d[_],x=p-d[v];p=ko(b,p,x)}if(r){const _=u==="y"?"top":"left",v=u==="y"?"bottom":"right",b=g+d[_],x=g-d[v];g=ko(b,g,x)}const h=a.fn({...e,[m]:p,[u]:g});return{...h,data:{x:h.x-n,y:h.y-o,enabled:{[m]:s,[u]:r}}}}}},Zs=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var n,o;const{placement:i,rects:s,platform:r,elements:a}=e,{apply:c=()=>{},...l}=Jt(t,e),d=await Le(e,l),u=it(i),m=Zt(i),p=Q(i)==="y",{width:g,height:h}=s.floating;let _,v;u==="top"||u==="bottom"?(_=u,v=m===(await(r.isRTL==null?void 0:r.isRTL(a.floating))?"start":"end")?"left":"right"):(v=u,_=m==="end"?"top":"bottom");const b=h-d.top-d.bottom,x=g-d.left-d.right,w=bt(h-d[_],b),S=bt(g-d[v],x),N=!e.middlewareData.shift;let G=w,dt=S;if((n=e.middlewareData.shift)!=null&&n.enabled.x&&(dt=x),(o=e.middlewareData.shift)!=null&&o.enabled.y&&(G=b),N&&!m){const X=O(d.left,0),Mt=O(d.right,0),Ot=O(d.top,0),Rt=O(d.bottom,0);p?dt=g-2*(X!==0||Mt!==0?X+Mt:O(d.left,d.right)):G=h-2*(Ot!==0||Rt!==0?Ot+Rt:O(d.top,d.bottom))}await c({...e,availableWidth:dt,availableHeight:G});const ut=await r.getDimensions(a.floating);return g!==ut.width||h!==ut.height?{reset:{rects:!0}}:{}}}};function ne(){return typeof window<"u"}function gt(t){return Po(t)?(t.nodeName||"").toLowerCase():"#document"}function R(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function z(t){var e;return(e=(Po(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function Po(t){return ne()?t instanceof Node||t instanceof R(t).Node:!1}function H(t){return ne()?t instanceof Element||t instanceof R(t).Element:!1}function W(t){return ne()?t instanceof HTMLElement||t instanceof R(t).HTMLElement:!1}function Do(t){return!ne()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof R(t).ShadowRoot}const tr=new Set(["inline","contents"]);function Et(t){const{overflow:e,overflowX:n,overflowY:o,display:i}=B(t);return/auto|scroll|overlay|hidden|clip/.test(e+o+n)&&!tr.has(i)}const er=new Set(["table","td","th"]);function nr(t){return er.has(gt(t))}const or=[":popover-open",":modal"];function oe(t){return or.some(e=>{try{return t.matches(e)}catch{return!1}})}const ir=["transform","translate","scale","rotate","perspective"],sr=["transform","translate","scale","rotate","perspective","filter"],rr=["paint","layout","strict","content"];function Ie(t){const e=Me(),n=H(t)?B(t):t;return ir.some(o=>n[o]?n[o]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!e&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!e&&(n.filter?n.filter!=="none":!1)||sr.some(o=>(n.willChange||"").includes(o))||rr.some(o=>(n.contain||"").includes(o))}function ar(t){let e=J(t);for(;W(e)&&!vt(e);){if(Ie(e))return e;if(oe(e))return null;e=J(e)}return null}function Me(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const lr=new Set(["html","body","#document"]);function vt(t){return lr.has(gt(t))}function B(t){return R(t).getComputedStyle(t)}function ie(t){return H(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function J(t){if(gt(t)==="html")return t;const e=t.assignedSlot||t.parentNode||Do(t)&&t.host||z(t);return Do(e)?e.host:e}function No(t){const e=J(t);return vt(e)?t.ownerDocument?t.ownerDocument.body:t.body:W(e)&&Et(e)?e:No(e)}function St(t,e,n){var o;e===void 0&&(e=[]),n===void 0&&(n=!0);const i=No(t),s=i===((o=t.ownerDocument)==null?void 0:o.body),r=R(i);if(s){const a=Oe(r);return e.concat(r,r.visualViewport||[],Et(i)?i:[],a&&n?St(a):[])}return e.concat(i,St(i,[],n))}function Oe(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function Ho(t){const e=B(t);let n=parseFloat(e.width)||0,o=parseFloat(e.height)||0;const i=W(t),s=i?t.offsetWidth:n,r=i?t.offsetHeight:o,a=Xt(n)!==s||Xt(o)!==r;return a&&(n=s,o=r),{width:n,height:o,$:a}}function Re(t){return H(t)?t:t.contextElement}function _t(t){const e=Re(t);if(!W(e))return V(1);const n=e.getBoundingClientRect(),{width:o,height:i,$:s}=Ho(e);let r=(s?Xt(n.width):n.width)/o,a=(s?Xt(n.height):n.height)/i;return(!r||!Number.isFinite(r))&&(r=1),(!a||!Number.isFinite(a))&&(a=1),{x:r,y:a}}const cr=V(0);function Bo(t){const e=R(t);return!Me()||!e.visualViewport?cr:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function dr(t,e,n){return e===void 0&&(e=!1),!n||e&&n!==R(t)?!1:e}function st(t,e,n,o){e===void 0&&(e=!1),n===void 0&&(n=!1);const i=t.getBoundingClientRect(),s=Re(t);let r=V(1);e&&(o?H(o)&&(r=_t(o)):r=_t(t));const a=dr(s,n,o)?Bo(s):V(0);let c=(i.left+a.x)/r.x,l=(i.top+a.y)/r.y,d=i.width/r.x,u=i.height/r.y;if(s){const m=R(s),p=o&&H(o)?R(o):o;let g=m,h=Oe(g);for(;h&&o&&p!==g;){const _=_t(h),v=h.getBoundingClientRect(),b=B(h),x=v.left+(h.clientLeft+parseFloat(b.paddingLeft))*_.x,w=v.top+(h.clientTop+parseFloat(b.paddingTop))*_.y;c*=_.x,l*=_.y,d*=_.x,u*=_.y,c+=x,l+=w,g=R(h),h=Oe(g)}}return ee({width:d,height:u,x:c,y:l})}function se(t,e){const n=ie(t).scrollLeft;return e?e.left+n:st(z(t)).left+n}function jo(t,e){const n=t.getBoundingClientRect(),o=n.left+e.scrollLeft-se(t,n),i=n.top+e.scrollTop;return{x:o,y:i}}function ur(t){let{elements:e,rect:n,offsetParent:o,strategy:i}=t;const s=i==="fixed",r=z(o),a=e?oe(e.floating):!1;if(o===r||a&&s)return n;let c={scrollLeft:0,scrollTop:0},l=V(1);const d=V(0),u=W(o);if((u||!u&&!s)&&((gt(o)!=="body"||Et(r))&&(c=ie(o)),W(o))){const p=st(o);l=_t(o),d.x=p.x+o.clientLeft,d.y=p.y+o.clientTop}const m=r&&!u&&!s?jo(r,c):V(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+d.x+m.x,y:n.y*l.y-c.scrollTop*l.y+d.y+m.y}}function fr(t){return Array.from(t.getClientRects())}function pr(t){const e=z(t),n=ie(t),o=t.ownerDocument.body,i=O(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),s=O(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight);let r=-n.scrollLeft+se(t);const a=-n.scrollTop;return B(o).direction==="rtl"&&(r+=O(e.clientWidth,o.clientWidth)-i),{width:i,height:s,x:r,y:a}}const Fo=25;function mr(t,e){const n=R(t),o=z(t),i=n.visualViewport;let s=o.clientWidth,r=o.clientHeight,a=0,c=0;if(i){s=i.width,r=i.height;const d=Me();(!d||d&&e==="fixed")&&(a=i.offsetLeft,c=i.offsetTop)}const l=se(o);if(l<=0){const d=o.ownerDocument,u=d.body,m=getComputedStyle(u),p=d.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,g=Math.abs(o.clientWidth-u.clientWidth-p);g<=Fo&&(s-=g)}else l<=Fo&&(s+=l);return{width:s,height:r,x:a,y:c}}const hr=new Set(["absolute","fixed"]);function br(t,e){const n=st(t,!0,e==="fixed"),o=n.top+t.clientTop,i=n.left+t.clientLeft,s=W(t)?_t(t):V(1),r=t.clientWidth*s.x,a=t.clientHeight*s.y,c=i*s.x,l=o*s.y;return{width:r,height:a,x:c,y:l}}function Uo(t,e,n){let o;if(e==="viewport")o=mr(t,n);else if(e==="document")o=pr(z(t));else if(H(e))o=br(e,n);else{const i=Bo(t);o={x:e.x-i.x,y:e.y-i.y,width:e.width,height:e.height}}return ee(o)}function qo(t,e){const n=J(t);return n===e||!H(n)||vt(n)?!1:B(n).position==="fixed"||qo(n,e)}function gr(t,e){const n=e.get(t);if(n)return n;let o=St(t,[],!1).filter(a=>H(a)&&gt(a)!=="body"),i=null;const s=B(t).position==="fixed";let r=s?J(t):t;for(;H(r)&&!vt(r);){const a=B(r),c=Ie(r);!c&&a.position==="fixed"&&(i=null),(s?!c&&!i:!c&&a.position==="static"&&!!i&&hr.has(i.position)||Et(r)&&!c&&qo(t,r))?o=o.filter(d=>d!==r):i=a,r=J(r)}return e.set(t,o),o}function vr(t){let{element:e,boundary:n,rootBoundary:o,strategy:i}=t;const r=[...n==="clippingAncestors"?oe(e)?[]:gr(e,this._c):[].concat(n),o],a=r[0],c=r.reduce((l,d)=>{const u=Uo(e,d,i);return l.top=O(u.top,l.top),l.right=bt(u.right,l.right),l.bottom=bt(u.bottom,l.bottom),l.left=O(u.left,l.left),l},Uo(e,a,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function _r(t){const{width:e,height:n}=Ho(t);return{width:e,height:n}}function yr(t,e,n){const o=W(e),i=z(e),s=n==="fixed",r=st(t,!0,s,e);let a={scrollLeft:0,scrollTop:0};const c=V(0);function l(){c.x=se(i)}if(o||!o&&!s)if((gt(e)!=="body"||Et(i))&&(a=ie(e)),o){const p=st(e,!0,s,e);c.x=p.x+e.clientLeft,c.y=p.y+e.clientTop}else i&&l();s&&!o&&i&&l();const d=i&&!o&&!s?jo(i,a):V(0),u=r.left+a.scrollLeft-c.x-d.x,m=r.top+a.scrollTop-c.y-d.y;return{x:u,y:m,width:r.width,height:r.height}}function Pe(t){return B(t).position==="static"}function Vo(t,e){if(!W(t)||B(t).position==="fixed")return null;if(e)return e(t);let n=t.offsetParent;return z(t)===n&&(n=n.ownerDocument.body),n}function zo(t,e){const n=R(t);if(oe(t))return n;if(!W(t)){let i=J(t);for(;i&&!vt(i);){if(H(i)&&!Pe(i))return i;i=J(i)}return n}let o=Vo(t,e);for(;o&&nr(o)&&Pe(o);)o=Vo(o,e);return o&&vt(o)&&Pe(o)&&!Ie(o)?n:o||ar(t)||n}const wr=async function(t){const e=this.getOffsetParent||zo,n=this.getDimensions,o=await n(t.floating);return{reference:yr(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function xr(t){return B(t).direction==="rtl"}const Er={convertOffsetParentRelativeRectToViewportRelativeRect:ur,getDocumentElement:z,getClippingRect:vr,getOffsetParent:zo,getElementRects:wr,getClientRects:fr,getDimensions:_r,getScale:_t,isElement:H,isRTL:xr};function Wo(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function Sr(t,e){let n=null,o;const i=z(t);function s(){var a;clearTimeout(o),(a=n)==null||a.disconnect(),n=null}function r(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),s();const l=t.getBoundingClientRect(),{left:d,top:u,width:m,height:p}=l;if(a||e(),!m||!p)return;const g=Qt(u),h=Qt(i.clientWidth-(d+m)),_=Qt(i.clientHeight-(u+p)),v=Qt(d),x={rootMargin:-g+"px "+-h+"px "+-_+"px "+-v+"px",threshold:O(0,bt(1,c))||1};let w=!0;function S(N){const G=N[0].intersectionRatio;if(G!==c){if(!w)return r();G?r(!1,G):o=setTimeout(()=>{r(!1,1e-7)},1e3)}G===1&&!Wo(l,t.getBoundingClientRect())&&r(),w=!1}try{n=new IntersectionObserver(S,{...x,root:i.ownerDocument})}catch{n=new IntersectionObserver(S,x)}n.observe(t)}return r(!0),s}function Tr(t,e,n,o){o===void 0&&(o={});const{ancestorScroll:i=!0,ancestorResize:s=!0,elementResize:r=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=o,l=Re(t),d=i||s?[...l?St(l):[],...St(e)]:[];d.forEach(v=>{i&&v.addEventListener("scroll",n,{passive:!0}),s&&v.addEventListener("resize",n)});const u=l&&a?Sr(l,n):null;let m=-1,p=null;r&&(p=new ResizeObserver(v=>{let[b]=v;b&&b.target===l&&p&&(p.unobserve(e),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var x;(x=p)==null||x.observe(e)})),n()}),l&&!c&&p.observe(l),p.observe(e));let g,h=c?st(t):null;c&&_();function _(){const v=st(t);h&&!Wo(h,v)&&n(),h=v,g=requestAnimationFrame(_)}return n(),()=>{var v;d.forEach(b=>{i&&b.removeEventListener("scroll",n),s&&b.removeEventListener("resize",n)}),u?.(),(v=p)==null||v.disconnect(),p=null,c&&cancelAnimationFrame(g)}}const Go=Js,Yo=Qs,$r=Zs,Cr=(t,e,n)=>{const o=new Map,i={platform:Er,...n},s={...i.platform,_c:o};return Xs(t,e,{...i,platform:s})};function Ko(t){var e,n,o="";if(typeof t=="string"||typeof t=="number")o+=t;else if(typeof t=="object")if(Array.isArray(t)){var i=t.length;for(e=0;e<i;e++)t[e]&&(n=Ko(t[e]))&&(o&&(o+=" "),o+=n)}else for(n in t)t[n]&&(o&&(o+=" "),o+=n);return o}function kr(){for(var t,e,n=0,o="",i=arguments.length;n<i;n++)(t=arguments[n])&&(e=Ko(t))&&(o&&(o+=" "),o+=e);return o}const P={capture:!0,passive:!0},rt=typeof window<"u"&&typeof document<"u";function Ar(t,e){let n;return(...o)=>{clearTimeout(n),n=setTimeout(()=>t(...o),e)}}function f(t,e,n){return n===void 0?t.getAttribute(e)??null:(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}let Lr=0;const Ir=`${Date.now().toString(36)}${Math.random().toString(36).slice(2,5)}`;function re(t){return t.id||(t.id=`${Ir}${++Lr}`),t.id}const Xo=(t,e,[...n])=>{for(const o of n[0].split(","))n[0]=o,e[`${t}EventListener`](...n)},$=(t,...e)=>{Tt&&(t===window||t===document)&&Tt.push(()=>Qo(t,...e)),Xo("add",t,e)},Qo=(t,...e)=>Xo("remove",t,e);let Tt=null;const D=t=>{if(!rt||!window.requestAnimationFrame)return;window._mtdsUnbindEvents||(window._mtdsUnbindEvents=new Map);const e=()=>requestAnimationFrame(()=>{const n=String(t).replace(/(\n|\s)/g,"");window._mtdsUnbindEvents?.get(n)?.map(o=>o()),Tt=[],t(),window._mtdsUnbindEvents?.set(n,Tt?.slice(0)),Tt=null});document.readyState==="complete"?e():$(window,"load",e)},De=new WeakMap,Mr=`.${T.dialog.split(" ")[0]}`;function at(t,e,{contain:n,middleware:o,placement:i,...s}={}){if(De.get(t)?.(),De.delete(t),e){const r=t.closest(Mr)?.querySelector(":scope > footer"),a=Number(f(t,"data-inset"))||20,l={bottom:(r?.clientHeight||0)+a,left:a,right:a,top:a},d=f(t,"data-position")??"bottom";De.set(t,Tr(e,t,()=>{if(!t.isConnected||!e.isConnected||t.hidden)return at(t,!1);Cr(e,t,{...s,placement:i||d,middleware:[Yo({padding:l}),Go(),...n?[$r({padding:l,apply:n})]:[],...o||[]]}).then(({x:u,y:m})=>{t.style.left=`${u}px`,t.style.top=`${m}px`})}))}}function Jo(t){let e=0;const n=()=>setTimeout(o,200),o=()=>{t([],i),i.takeRecords(),e=0},i=new MutationObserver(()=>{e||(e=requestAnimationFrame(n))});return i}const Ne=new WeakMap,yt=(t,e,n)=>{if(!rt||!window.requestAnimationFrame)return;const o=t.getElementsByClassName(e),i=Ne.get(t)||[];i.length||(Ne.set(t,i),Jo((s,r)=>{if(t.isConnected&&i?.length)for(const a of i)a();else r?.disconnect(),Ne.delete(t)}).observe(t,{attributeFilter:["class","hidden"],attributes:!0,childList:!0,subtree:!0})),i.push(()=>n(o))},He=t=>t instanceof HTMLElement&&"validity"in t&&!(t instanceof HTMLButtonElement),C=(t,e,n)=>{const o=document.createElement(t);if(n&&(o.textContent=n),e)for(const[i,s]of Object.entries(e))f(o,i,s);return o},Or=typeof HTMLElement>"u"?class{}:HTMLElement,Rr=`.${T.breadcrumbs.split(" ")[0]}`,Pr=`.${T.card.split(" ")[0]}`,Zo=`.${T.chip.split(" ")[0]}`,Dr=`.${T.helptext.split(" ")[0]}`,Nr=`.${T.pagination.split(" ")[0]}`,Hr='summary,u-summary,a,button,[role="tab"],[role="button"]',Br="click,toggle,submit,change",Be="mattilsynet.matomo.cloud",j="mtds-analytics-banner",jr="https://www.mattilsynet.no/om-mattilsynet/personvernerklaering/informasjonskapsler";function ti(t,e={}){if(rt){if(window._paq||(window._paq=[],window._paq.push(["HeatmapSessionRecording::disable"]),window._paq.push(["enableLinkTracking"]),window._paq.push(["setTrackerUrl",`https://${Be}/matomo.php`])),window._mtm||(window._mtm=window._mtm||[],window._mtm.push({"mtm.startTime":Date.now(),event:"mtm.Start"})),t==="init"){window._mtdsTracking={enabled:window.location.hostname!=="localhost",...window._mtdsTracking,...e};const{consent:n,enabled:o,matomoId:i,matomoTagManagerId:s}=window._mtdsTracking;if(i&&window._paq.push(["setSiteId",i]),o){n!=="custom"&&Fr();const r=s?`https://cdn.matomo.cloud/${Be}/container_${s}.js`:`https://cdn.matomo.cloud/${Be}/matomo.js`;document.querySelector(`script[src="${r}"]`)||document.head.append(C("script",{async:"",src:r}))}}if(window._mtdsTracking?.enabled!==!1){if(window._mtdsTracking?.enabled==="debug")return console.info(`analytics("${t}", `,e,")");if(t==="pageview"){const{url:n,title:o}=e;window._paq.push(["setCustomUrl",n||location.href]),window._paq.push(["setDocumentTitle",o||document.title]),window._paq.push(["trackPageView"])}else if(t==="event"){const{category:n,action:o,name:i,value:s}=e,r=["trackEvent",n,o,i,s];let a=location.href;window._paq.push([function(){a=this.getCurrentUrl()}]),window._paq.push(["setCustomUrl",a.split("#")[0]]),window._paq.push(r.filter(c=>c!==void 0)),window._paq.push(["setCustomUrl",a])}else if(t==="search"){const{query:n,category:o=!1,results:i=!1}=e;window._paq.push(["trackSiteSearch",n,o,i])}else t==="matomo"&&window._paq.push(e)}}}function Fr(){if(document.getElementById(j)||window.localStorage.getItem(j))return;document.body.insertAdjacentHTML("afterbegin",`<dialog id="${j}" data-analytics="ignore"><style>
8
+ ::slotted(data:focus) { ${cs} }`,pn="beforeinput,blur,focus,click,input,keydown,mousedown",hn={once:!0,passive:!0},Bt="false",_s=rs&&!ln,ys=ln||ls,mn="​".repeat(5),gn="deleteContentBackward",ws="insertText",jt={added:"Added",empty:"No selected",found:"Navigate left to find %d selected",invalid:"Invalid value",of:"of",remove:"Press to remove",removed:"Removed"},ye=class extends ds{constructor(){super(),this._item="",this._speak="",this._texts=as({},jt),this._value="",this.shadowRoot||this.attachShadow({mode:"open"}).append(Ht("slot"),Ht("style",vs))}static get observedAttributes(){return Object.keys(jt).map(t=>`data-sr-${t}`)}connectedCallback(){this._root=ps(this),Dt(this,pn,this,!0),ge(this,{attributeFilter:["value","id"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),setTimeout(Ft,0,this),setTimeout(Ut,0,this)}attributeChangedCallback(t,e,n){const o=t.split("data-sr-")[1];jt[o]&&(this._texts[o]=n||jt[o])}disconnectedCallback(){ge(this,!1),us(this,pn,this,!0),this._items=this._clear=this._focus=this._control=void 0,this._list=this._options=this._root=void 0}handleEvent(t){const e=t.target;xe(this)||(t.type==="beforeinput"&&(this._value=e?.value||""),t.type==="blur"&&Es(this),t.type==="click"&&Ts(this,t),t.type==="focus"&&xs(this,t),t.type==="input"&&$s(this,t),t.type==="keydown"&&Cs(this,t),t.type==="mousedown"&&_e(t),t.type==="mutation"&&Ft(this,t))}get multiple(){var t;return((t=x(this,"data-multiple"))!=null?t:Bt)!==Bt}set multiple(t){x(this,"data-multiple",t?"":null)}get creatable(){var t;return((t=x(this,"data-creatable"))!=null?t:Bt)!==Bt}set creatable(t){x(this,"data-creatable",t?"":null)}get control(){var t;return(t=this._control)!=null&&t.isConnected||(this._control=this.querySelector("input")),this._control}get list(){var t;return(t=this._list)!=null&&t.isConnected||(this._list=this.querySelector("u-datalist,datalist")),this._list}get clear(){var t;return(t=this._clear)!=null&&t.isConnected||(this._clear=this.querySelector("del")),this._clear}get items(){return this._items||(this._items=this.getElementsByTagName("data")),this._items}get options(){var t,e;if(!this._options){const n=((t=this.list)==null?void 0:t.nodeName)==="U-DATALIST"?"u-option":"option";this._options=(e=this.list)==null?void 0:e.getElementsByTagName(n)}return this._options}get values(){return[...this.items].map(({value:t})=>t)}},ot=t=>{var e;return((e=t?.textContent)==null?void 0:e.trim())||""},we=t=>t instanceof HTMLDataElement,xe=({control:t})=>t?.disabled||t?.readOnly||!1,Ft=(t,e)=>{var n;const{_focus:o,_texts:i,items:s,control:a,list:r,multiple:c}=t;if(!a||!r)return;const l=gs(a),d=l.endsWith(mn)?x(a,"data-label"):l;x(a,"data-label",d);let u=`${d}${c?`, ${s.length?i.found.replace("%d",`${s.length}`):i.empty}`:""}`;const p=[];for(const{addedNodes:b,removedNodes:_}of e?.detail||[]){for(const w of b)we(w)&&p.unshift(w);for(const w of _)we(w)&&p.push(w)}const h=c?p.length===1:p[0]===o;if(o&&h){const b=x(a,"aria-expanded"),_=x(a,"inputmode"),w=we(o)?a:o,E=!p[0].isConnected;t._speak=`${i[E?"removed":"added"]} ${ot(p[0])}, `,(ys||o===a)&&be(t._speak),a!==w&&(x(a,"aria-expanded",null),x(a,"inputmode","none"),u=" ",a.focus()),setTimeout(()=>{var M;x(a,"aria-expanded",b),x(a,"inputmode",E?"none":_),(M=w?.focus)==null||M.call(w),x(a,"inputmode",_),t._speak="",_s?Dt(t,"blur",()=>Ft(t),hn):setTimeout(Ft,100,t)},100)}let m=0;const g=t.querySelector("select"),y=xe(t)?"":`${i.remove}, `;for(const b of s){const _=g?.options[m],w=ot(b),E=b.value||w,M=`${t._speak}${w}, ${y}${++m} ${i.of} ${s.length}`;x(b,"role","button"),x(b,"value",E),x(b,"tabindex","-1"),x(b,"aria-label",M),_?Object.assign(_,{textContent:w,value:E}):g?.appendChild(new Option(w,E,!0,!0))}g&&x(g,"multiple",c?"":null);for(const b of[...g?.options||[]].slice(m))b.remove();!c&&m>1&&console.warn("u-combobox: Multiple <data> found in single mode."),x(r,"aria-multiselectable",`${c}`),x(a,"list",un(r)),x(a,"aria-label",`${t._speak}${u}${mn}`),r.hasAttribute("popover")&&(x(a,"popovertarget",un(r)),x(r,"popover","manual"));const v=ot(s[0]);v!==t._item&&Ut(t),t._item=v,bn(t),vn(t),(n=ge(t))==null||n.takeRecords()},bn=t=>{var e;t.clear&&x(t.clear,"role","button"),t.clear&&(t.clear.hidden=!((e=t.control)!=null&&e.value)||xe(t))},vn=t=>{var e;const{_speak:n,options:o=[],values:i}=t;for(const s of o){const a=(e=x(s,"value"))!=null?e:ot(s);x(s,"aria-label",n?`${n}${ot(s)}`:null),x(s,"selected",i.includes(a)?"":null)}},Ut=t=>{const{multiple:e,control:n,items:o}=t,i=ot(o[0]);!e&&n&&i!==n.value&&fn(n,i,i?ws:gn)},Ee=(t,e=!0)=>{var n;const{_texts:o,options:i=[],creatable:s,control:a,items:r,multiple:c}=t,l=((n=a?.value)==null?void 0:n.trim())||"",d=l.toLowerCase()||null;let u=[...i].find(h=>(x(h,"label")||ot(h)).trim().toLowerCase()===d);const p={bubbles:!0,cancelable:!0,detail:u};if(t.dispatchEvent(new CustomEvent("comboboxbeforematch",p))||(u=[...i].find(h=>h.selected)),e)return vn(t),u?ht(t,u,!1):s&&l?ht(t,{value:l},!1):(!c&&!l&&r[0]?ht(t,r[0]):Ut(t),be(o.invalid));for(const h of i)h.selected=h===u},ht=(t,e,n=!0)=>{const{control:o,items:i,multiple:s}=t,a=Ht("data",e.label||e.value,{value:e.value}),r=[...i].find(d=>d.value===e.value),c={bubbles:!0,cancelable:!0,detail:r||a};if(r&&!n)return Ut(t);if(t.dispatchEvent(new CustomEvent("comboboxbeforeselect",c))){if(!s)for(const d of[...i])d.remove();r?r.remove():o?.insertAdjacentElement("beforebegin",a),t.dispatchEvent(new CustomEvent("comboboxafterselect",c))}},xs=(t,{target:e})=>{e instanceof HTMLElement&&(t._focus=e),be()},Es=t=>_e()||setTimeout(Ss,0,t),Ss=t=>{var e;!t._focus||t.contains((e=t._root)==null?void 0:e.activeElement)||(t.multiple||Ee(t),t._focus=void 0)},Ts=(t,e)=>{const{clientX:n,clientY:o,target:i}=e,{clear:s,control:a,items:r}=t;if(s?.contains(i))return a&&fn(a,"",gn),a?.focus();for(const c of r){const{top:l,right:d,bottom:u,left:p}=c.getBoundingClientRect();if(c.contains(i))return ht(t,c);if(o>=l&&o<=u&&n>=p&&n<=d)return c.focus()}i===t&&a?.focus()},$s=(t,e)=>{var n;const{options:o=[],control:i,multiple:s}=t,a=((n=i?.value)==null?void 0:n.trim())||"";if(e instanceof InputEvent?!e.inputType||e.inputType==="insertReplacementText":!!a){e.stopImmediatePropagation(),i&&(i.value=t._value);for(const c of o)if(c.value&&c.value===a)return ht(t,c,s)}else s||Ee(t,!1);bn(t)},Cs=(t,e)=>{var n;if(e.altKey||e.ctrlKey||e.metaKey||e.shiftKey)return;const{clear:o,control:i,items:s}=t,{key:a,repeat:r,target:c}=e,l=i&&i===c,d=l&&i?.selectionEnd;let u=l?s.length:[...s].indexOf(c);if(l&&a==="Tab"&&o&&!o.hidden&&(e.preventDefault(),o.tabIndex=-1,o.focus(),Dt(o,"blur",()=>x(o,"tabindex",null),hn)),!(!l&&fs(e)||u===-1)){if(a==="ArrowRight"&&!l)u+=1;else if(a==="ArrowLeft"&&!d)u-=1;else if(a==="Enter"&&l){const p=x(i,"form");return x(i,"form","#"),requestAnimationFrame(()=>x(i,"form",p)),Ee(t)}else if((a==="Backspace"||a==="Delete")&&!d){if(e.preventDefault(),!r&&s[u])return ht(t,s[u]);l&&(u-=1)}else return l||i?.focus();e.preventDefault(),(n=s[Math.max(0,u)]||i)==null||n.focus()}};ms.define("u-combobox",ye);var Se=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",ks=Se&&/android/i.test(navigator.userAgent),_n;Se&&/^Mac/i.test(((_n=navigator.userAgentData)==null?void 0:_n.platform)||navigator.platform);var As=`${ks?"data":"aria"}-labelledby`,Te=":host(:not([hidden])) { display: block }",zt=typeof HTMLElement>"u"?class{}:HTMLElement;function A(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var yn=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Ls=(t,...e)=>yn("add",t,e),Is=(t,...e)=>yn("remove",t,e),Vt=(t,e)=>t.shadowRoot||t.attachShadow({mode:"open"}).append(Sn("slot"),Sn("style",e)),qt=new WeakMap,wn=(t,e)=>{if(e===void 0)return qt.get(t);try{qt.get(t).disconnect(),qt.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),qt.set(t,n)}},Ms=t=>{const e="key"in t&&(t.key===" "||t.key==="Enter");return e&&t.preventDefault(),e&&t.target instanceof HTMLElement&&t.target.click(),e},xn=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},Os=0,En=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++Os).toString(32)}`),t.id):"",Sn=(t,e,n)=>{const o=document.createElement(t);return e&&(o.textContent=e),o},Wt={define:(t,e)=>!Se||window.customElements.get(t)||window.customElements.define(t,e)},Rs=Te,Ps=Te,Ds=Te,Ns=':host(:not([hidden])) { display: inline-block; cursor: pointer }:host([aria-disabled="true"]) { cursor: default }',Gt="aria-controls",mt="aria-selected",Tn=class extends zt{constructor(){super(),Vt(this,Rs)}get tabList(){return Yt("u-tablist",this)[0]||null}get selectedIndex(){return Kt(this.tabs)}set selectedIndex(t){ke(this.tabs[t])}get tabs(){return Yt("u-tab",this)}get panels(){return Yt("u-tabpanel",this)}},$n=class extends zt{constructor(){super(),Vt(this,Ps)}connectedCallback(){A(this,"role","tablist"),Ls(this,"click,keydown",this),wn(this,{childList:!0}),this.tabs.length&&this.handleEvent()}disconnectedCallback(){Is(this,"click,keydown",this),wn(this,!1)}handleEvent(t){if(!t||t.type==="mutation"){const s=this.tabs[Math.max(this.selectedIndex,0)];return s?.setAttribute(mt,"true")}const{key:e}=t,n=[...this.tabs],o=n.findIndex(s=>s.contains(t.target));let i=o;if(!(t.defaultPrevented||o===-1)&&(t.type==="click"&&ke(n[o]),t.type==="keydown"&&!Ms(t))){if(e==="ArrowDown"||e==="ArrowRight")i=(o+1)%n.length;else if(e==="ArrowUp"||e==="ArrowLeft")i=(o||n.length)-1;else if(e==="End")i=n.length-1;else if(e==="Home")i=0;else if(e==="Tab")i=Kt(n);else return;setTimeout(()=>{n[o].tabIndex=-1,n[i].tabIndex=0}),e!=="Tab"&&(t.preventDefault(),n[i].focus())}}get tabsElement(){return this.closest("u-tabs")}get tabs(){return this.querySelectorAll("u-tab")}get selectedIndex(){return Kt(this.tabs)}set selectedIndex(t){ke(this.tabs[t])}},$e=!1,Cn=class extends zt{static get observedAttributes(){return["id",mt,Gt]}constructor(){super(),Vt(this,Ns)}connectedCallback(){A(this,"role","tab"),this.tabIndex=this.selected?0:-1}attributeChangedCallback(){if(!$e&&this.selected&&this.tabList){$e=!0;const t=[...this.tabList.querySelectorAll("u-tab")],e=Yt("u-tabpanel",this.tabsElement||this),n=Ce(this,e[t.indexOf(this)]);n&&A(n,As,En(this)),t.forEach((o,i)=>{const s=Ce(o,e[i]);o.tabIndex=o===this?0:-1,A(o,mt,`${o===this}`),A(o,Gt,s?.id||null),s&&(s.hidden=s!==n)}),$e=!1}}get tabsElement(){return this.closest("u-tabs")}get tabList(){const t=this.parentElement;return t?.nodeName==="U-TABLIST"?t:null}get selected(){return A(this,mt)==="true"}set selected(t){A(this,mt,`${!!t}`)}get index(){const t=this.tabList;return t?[...t.querySelectorAll("u-tab")].indexOf(this):0}get panel(){return Ce(this)}},kn=class extends zt{static get observedAttributes(){return["hidden"]}constructor(){super(),Vt(this,Ds)}connectedCallback(){A(this,"role","tabpanel"),this.hidden=Kt(this.tabs)===-1,this.attributeChangedCallback()}attributeChangedCallback(){const t=this.hidden;A(this,"aria-hidden",`${t}`),A(this,"tabindex",t||Hs(this.firstChild)?null:"0")}get tabsElement(){return this.closest("u-tabs")}get tabs(){const t=`u-tab[${Gt}="${this.id}"]`;return xn(this).querySelectorAll(t)}},Yt=(t,e)=>e.querySelectorAll(`${t}:not(:scope u-tabpanel ${t})`),Ce=(t,e)=>{const n=A(t,Gt)||En(e),o=xn(t).getElementById(n);return o?.nodeName==="U-TABPANEL"?o:null},Kt=t=>[...t].findIndex(e=>A(e,mt)==="true"),ke=t=>t&&A(t,"aria-disabled")!=="true"&&A(t,"aria-selected","true"),Hs=t=>t instanceof Element&&!t.matches(':disabled,[tabindex^="-"]')&&t.matches('[contenteditable],[controls],[href],[tabindex],input:not([type="hidden"]),select,textarea,button,summary,iframe');Wt.define("u-tabs",Tn),Wt.define("u-tablist",$n),Wt.define("u-tab",Cn),Wt.define("u-tabpanel",kn);const Bs="2.11.0-canary",An="_alert_3aj69_1 _ds-alert_14b25_3",Ln="_app_3aj69_1",In="_sticky_3aj69_1",Mn="_avatar_3aj69_1 _ds-avatar_14b25_1",On="_badge_3aj69_1",Rn="_breadcrumbs_3aj69_1 _ds-breadcrumbs_14b25_5",Pn="_button_3aj69_1 _ds-button_14b25_1",Dn="_card_3aj69_1",Nn="_group_3aj69_1",Hn="_chip_3aj69_1 _ds-chip_14b25_5",Bn="_details_3aj69_1 _ds-details_14b25_3",jn="_dialog_3aj69_1 _ds-dialog_14b25_5",Fn="__drawer_3aj69_1",Un="_divider_3aj69_1",zn="_errorsummary_3aj69_1 _ds-error-summary_14b25_5",Vn="__errorsummary_3aj69_1",qn="_field_3aj69_1 _ds-field_14b25_1",Wn="__datalist_3aj69_1",Gn="_affixes_3aj69_1 _ds-field-affixes_14b25_3",Yn="_fieldset_3aj69_1 _ds-fieldset_14b25_3",Kn="_helptext_3aj69_1 _ds-focus_14b25_1",Xn="_input_3aj69_1 _ds-input_14b25_1",Qn="_grid_3aj69_1",Jn="_flex_3aj69_1",Zn="_link_3aj69_1",to="_logo_3aj69_1",eo="_pagination_3aj69_1 _ds-pagination_14b25_5",no="_popover_3aj69_1",oo="_progress_3aj69_1",io="__indeterminate_3aj69_1",so="_skeleton_3aj69_1 _ds-skeleton_14b25_5",ao="__skeleton_3aj69_1",ro="_spinner_3aj69_1",lo="_steps_3aj69_1",co="_table_3aj69_1 _ds-table_14b25_5",uo="__scrollShadow_3aj69_1",fo="_tabs_3aj69_1 _ds-tabs_14b25_5",po="__scrollMask_3aj69_1",ho="_tag_3aj69_1 _ds-tag_14b25_5",mo="_toast_3aj69_1",go="__toastClose_3aj69_1",bo="__toastOpen_3aj69_1",vo="__toastTimeout_3aj69_1",_o="_togglegroup_3aj69_1",yo="__tooltip_3aj69_1",wo="_heading_3aj69_1 _ds-heading_14b25_1",xo="_ingress_3aj69_1",Eo="_muted_3aj69_1",So="_info_3aj69_1",To="_prose_3aj69_1",$o="_validation_3aj69_1 _ds-validation-message_14b25_1",Co="_body_3aj69_173",ko="__checked_3aj69_1",T={alert:An,app:Ln,sticky:In,avatar:Mn,badge:On,breadcrumbs:Rn,button:Pn,card:Dn,group:Nn,chip:Hn,details:Bn,dialog:jn,_drawer:Fn,divider:Un,errorsummary:zn,_errorsummary:Vn,field:qn,_datalist:Wn,affixes:Gn,fieldset:Yn,helptext:Kn,input:Xn,grid:Qn,flex:Jn,link:Zn,logo:to,pagination:eo,popover:no,progress:oo,_indeterminate:io,skeleton:so,_skeleton:ao,spinner:ro,steps:lo,table:co,_scrollShadow:uo,tabs:fo,_scrollMask:po,tag:ho,toast:mo,_toastClose:go,_toastOpen:bo,_toastTimeout:vo,togglegroup:_o,_tooltip:yo,heading:wo,ingress:xo,muted:Eo,info:So,prose:To,validation:$o,body:Co,_checked:ko},js=Object.freeze(Object.defineProperty({__proto__:null,_checked:ko,_datalist:Wn,_drawer:Fn,_errorsummary:Vn,_indeterminate:io,_scrollMask:po,_scrollShadow:uo,_skeleton:ao,_toastClose:go,_toastOpen:bo,_toastTimeout:vo,_tooltip:yo,affixes:Gn,alert:An,app:Ln,avatar:Mn,badge:On,body:Co,breadcrumbs:Rn,button:Pn,card:Dn,chip:Hn,default:T,details:Bn,dialog:jn,divider:Un,errorsummary:zn,field:qn,fieldset:Yn,flex:Jn,grid:Qn,group:Nn,heading:wo,helptext:Kn,info:So,ingress:xo,input:Xn,link:Zn,logo:to,muted:Eo,pagination:eo,popover:no,progress:oo,prose:To,skeleton:so,spinner:ro,steps:lo,sticky:In,table:co,tabs:fo,tag:ho,toast:mo,togglegroup:_o,validation:$o},Symbol.toStringTag,{value:"Module"})),gt=Math.min,R=Math.max,Xt=Math.round,Qt=Math.floor,V=t=>({x:t,y:t}),Fs={left:"right",right:"left",bottom:"top",top:"bottom"},Us={start:"end",end:"start"};function Ao(t,e,n){return R(t,gt(e,n))}function Jt(t,e){return typeof t=="function"?t(e):t}function it(t){return t.split("-")[0]}function Zt(t){return t.split("-")[1]}function Lo(t){return t==="x"?"y":"x"}function Io(t){return t==="y"?"height":"width"}const zs=new Set(["top","bottom"]);function Q(t){return zs.has(it(t))?"y":"x"}function Mo(t){return Lo(Q(t))}function Vs(t,e,n){n===void 0&&(n=!1);const o=Zt(t),i=Mo(t),s=Io(i);let a=i==="x"?o===(n?"end":"start")?"right":"left":o==="start"?"bottom":"top";return e.reference[s]>e.floating[s]&&(a=te(a)),[a,te(a)]}function qs(t){const e=te(t);return[Ae(t),e,Ae(e)]}function Ae(t){return t.replace(/start|end/g,e=>Us[e])}const Oo=["left","right"],Ro=["right","left"],Ws=["top","bottom"],Gs=["bottom","top"];function Ys(t,e,n){switch(t){case"top":case"bottom":return n?e?Ro:Oo:e?Oo:Ro;case"left":case"right":return e?Ws:Gs;default:return[]}}function Ks(t,e,n,o){const i=Zt(t);let s=Ys(it(t),n==="start",o);return i&&(s=s.map(a=>a+"-"+i),e&&(s=s.concat(s.map(Ae)))),s}function te(t){return t.replace(/left|right|bottom|top/g,e=>Fs[e])}function Xs(t){return{top:0,right:0,bottom:0,left:0,...t}}function Qs(t){return typeof t!="number"?Xs(t):{top:t,right:t,bottom:t,left:t}}function ee(t){const{x:e,y:n,width:o,height:i}=t;return{width:o,height:i,top:n,left:e,right:e+o,bottom:n+i,x:e,y:n}}function Po(t,e,n){let{reference:o,floating:i}=t;const s=Q(e),a=Mo(e),r=Io(a),c=it(e),l=s==="y",d=o.x+o.width/2-i.width/2,u=o.y+o.height/2-i.height/2,p=o[r]/2-i[r]/2;let h;switch(c){case"top":h={x:d,y:o.y-i.height};break;case"bottom":h={x:d,y:o.y+o.height};break;case"right":h={x:o.x+o.width,y:u};break;case"left":h={x:o.x-i.width,y:u};break;default:h={x:o.x,y:o.y}}switch(Zt(e)){case"start":h[a]-=p*(n&&l?-1:1);break;case"end":h[a]+=p*(n&&l?-1:1);break}return h}const Js=async(t,e,n)=>{const{placement:o="bottom",strategy:i="absolute",middleware:s=[],platform:a}=n,r=s.filter(Boolean),c=await(a.isRTL==null?void 0:a.isRTL(e));let l=await a.getElementRects({reference:t,floating:e,strategy:i}),{x:d,y:u}=Po(l,o,c),p=o,h={},m=0;for(let g=0;g<r.length;g++){const{name:y,fn:v}=r[g],{x:b,y:_,data:w,reset:E}=await v({x:d,y:u,initialPlacement:o,placement:p,strategy:i,middlewareData:h,rects:l,platform:a,elements:{reference:t,floating:e}});d=b??d,u=_??u,h={...h,[y]:{...h[y],...w}},E&&m<=50&&(m++,typeof E=="object"&&(E.placement&&(p=E.placement),E.rects&&(l=E.rects===!0?await a.getElementRects({reference:t,floating:e,strategy:i}):E.rects),{x:d,y:u}=Po(l,p,c)),g=-1)}return{x:d,y:u,placement:p,strategy:i,middlewareData:h}};async function Le(t,e){var n;e===void 0&&(e={});const{x:o,y:i,platform:s,rects:a,elements:r,strategy:c}=t,{boundary:l="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:p=!1,padding:h=0}=Jt(e,t),m=Qs(h),y=r[p?u==="floating"?"reference":"floating":u],v=ee(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(y)))==null||n?y:y.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(r.floating)),boundary:l,rootBoundary:d,strategy:c})),b=u==="floating"?{x:o,y:i,width:a.floating.width,height:a.floating.height}:a.reference,_=await(s.getOffsetParent==null?void 0:s.getOffsetParent(r.floating)),w=await(s.isElement==null?void 0:s.isElement(_))?await(s.getScale==null?void 0:s.getScale(_))||{x:1,y:1}:{x:1,y:1},E=ee(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:r,rect:b,offsetParent:_,strategy:c}):b);return{top:(v.top-E.top+m.top)/w.y,bottom:(E.bottom-v.bottom+m.bottom)/w.y,left:(v.left-E.left+m.left)/w.x,right:(E.right-v.right+m.right)/w.x}}const Zs=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var n,o;const{placement:i,middlewareData:s,rects:a,initialPlacement:r,platform:c,elements:l}=e,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:g=!0,...y}=Jt(t,e);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const v=it(i),b=Q(r),_=it(r)===r,w=await(c.isRTL==null?void 0:c.isRTL(l.floating)),E=p||(_||!g?[te(r)]:qs(r)),M=m!=="none";!p&&M&&E.push(...Ks(r,g,m,w));const G=[r,...E],dt=await Le(e,y),ut=[];let X=((o=s.flip)==null?void 0:o.overflows)||[];if(d&&ut.push(dt[v]),u){const ft=Vs(i,a,w);ut.push(dt[ft[0]],dt[ft[1]])}if(X=[...X,{placement:i,overflows:ut}],!ut.every(ft=>ft<=0)){var Mt,Ot;const ft=(((Mt=s.flip)==null?void 0:Mt.index)||0)+1,sn=G[ft];if(sn&&(!(u==="alignment"?b!==Q(sn):!1)||X.every(z=>Q(z.placement)===b?z.overflows[0]>0:!0)))return{data:{index:ft,overflows:X},reset:{placement:sn}};let Pt=(Ot=X.filter(pt=>pt.overflows[0]<=0).sort((pt,z)=>pt.overflows[1]-z.overflows[1])[0])==null?void 0:Ot.placement;if(!Pt)switch(h){case"bestFit":{var Rt;const pt=(Rt=X.filter(z=>{if(M){const et=Q(z.placement);return et===b||et==="y"}return!0}).map(z=>[z.placement,z.overflows.filter(et=>et>0).reduce((et,Sl)=>et+Sl,0)]).sort((z,et)=>z[1]-et[1])[0])==null?void 0:Rt[0];pt&&(Pt=pt);break}case"initialPlacement":Pt=r;break}if(i!==Pt)return{reset:{placement:Pt}}}return{}}}},ta=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:o,placement:i}=e,{mainAxis:s=!0,crossAxis:a=!1,limiter:r={fn:y=>{let{x:v,y:b}=y;return{x:v,y:b}}},...c}=Jt(t,e),l={x:n,y:o},d=await Le(e,c),u=Q(it(i)),p=Lo(u);let h=l[p],m=l[u];if(s){const y=p==="y"?"top":"left",v=p==="y"?"bottom":"right",b=h+d[y],_=h-d[v];h=Ao(b,h,_)}if(a){const y=u==="y"?"top":"left",v=u==="y"?"bottom":"right",b=m+d[y],_=m-d[v];m=Ao(b,m,_)}const g=r.fn({...e,[p]:h,[u]:m});return{...g,data:{x:g.x-n,y:g.y-o,enabled:{[p]:s,[u]:a}}}}}},ea=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var n,o;const{placement:i,rects:s,platform:a,elements:r}=e,{apply:c=()=>{},...l}=Jt(t,e),d=await Le(e,l),u=it(i),p=Zt(i),h=Q(i)==="y",{width:m,height:g}=s.floating;let y,v;u==="top"||u==="bottom"?(y=u,v=p===(await(a.isRTL==null?void 0:a.isRTL(r.floating))?"start":"end")?"left":"right"):(v=u,y=p==="end"?"top":"bottom");const b=g-d.top-d.bottom,_=m-d.left-d.right,w=gt(g-d[y],b),E=gt(m-d[v],_),M=!e.middlewareData.shift;let G=w,dt=E;if((n=e.middlewareData.shift)!=null&&n.enabled.x&&(dt=_),(o=e.middlewareData.shift)!=null&&o.enabled.y&&(G=b),M&&!p){const X=R(d.left,0),Mt=R(d.right,0),Ot=R(d.top,0),Rt=R(d.bottom,0);h?dt=m-2*(X!==0||Mt!==0?X+Mt:R(d.left,d.right)):G=g-2*(Ot!==0||Rt!==0?Ot+Rt:R(d.top,d.bottom))}await c({...e,availableWidth:dt,availableHeight:G});const ut=await a.getDimensions(r.floating);return m!==ut.width||g!==ut.height?{reset:{rects:!0}}:{}}}};function ne(){return typeof window<"u"}function bt(t){return Do(t)?(t.nodeName||"").toLowerCase():"#document"}function P(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function q(t){var e;return(e=(Do(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function Do(t){return ne()?t instanceof Node||t instanceof P(t).Node:!1}function H(t){return ne()?t instanceof Element||t instanceof P(t).Element:!1}function W(t){return ne()?t instanceof HTMLElement||t instanceof P(t).HTMLElement:!1}function No(t){return!ne()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof P(t).ShadowRoot}const na=new Set(["inline","contents"]);function Et(t){const{overflow:e,overflowX:n,overflowY:o,display:i}=B(t);return/auto|scroll|overlay|hidden|clip/.test(e+o+n)&&!na.has(i)}const oa=new Set(["table","td","th"]);function ia(t){return oa.has(bt(t))}const sa=[":popover-open",":modal"];function oe(t){return sa.some(e=>{try{return t.matches(e)}catch{return!1}})}const aa=["transform","translate","scale","rotate","perspective"],ra=["transform","translate","scale","rotate","perspective","filter"],la=["paint","layout","strict","content"];function Ie(t){const e=Me(),n=H(t)?B(t):t;return aa.some(o=>n[o]?n[o]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!e&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!e&&(n.filter?n.filter!=="none":!1)||ra.some(o=>(n.willChange||"").includes(o))||la.some(o=>(n.contain||"").includes(o))}function ca(t){let e=J(t);for(;W(e)&&!vt(e);){if(Ie(e))return e;if(oe(e))return null;e=J(e)}return null}function Me(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const da=new Set(["html","body","#document"]);function vt(t){return da.has(bt(t))}function B(t){return P(t).getComputedStyle(t)}function ie(t){return H(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function J(t){if(bt(t)==="html")return t;const e=t.assignedSlot||t.parentNode||No(t)&&t.host||q(t);return No(e)?e.host:e}function Ho(t){const e=J(t);return vt(e)?t.ownerDocument?t.ownerDocument.body:t.body:W(e)&&Et(e)?e:Ho(e)}function St(t,e,n){var o;e===void 0&&(e=[]),n===void 0&&(n=!0);const i=Ho(t),s=i===((o=t.ownerDocument)==null?void 0:o.body),a=P(i);if(s){const r=Oe(a);return e.concat(a,a.visualViewport||[],Et(i)?i:[],r&&n?St(r):[])}return e.concat(i,St(i,[],n))}function Oe(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function Bo(t){const e=B(t);let n=parseFloat(e.width)||0,o=parseFloat(e.height)||0;const i=W(t),s=i?t.offsetWidth:n,a=i?t.offsetHeight:o,r=Xt(n)!==s||Xt(o)!==a;return r&&(n=s,o=a),{width:n,height:o,$:r}}function Re(t){return H(t)?t:t.contextElement}function _t(t){const e=Re(t);if(!W(e))return V(1);const n=e.getBoundingClientRect(),{width:o,height:i,$:s}=Bo(e);let a=(s?Xt(n.width):n.width)/o,r=(s?Xt(n.height):n.height)/i;return(!a||!Number.isFinite(a))&&(a=1),(!r||!Number.isFinite(r))&&(r=1),{x:a,y:r}}const ua=V(0);function jo(t){const e=P(t);return!Me()||!e.visualViewport?ua:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function fa(t,e,n){return e===void 0&&(e=!1),!n||e&&n!==P(t)?!1:e}function st(t,e,n,o){e===void 0&&(e=!1),n===void 0&&(n=!1);const i=t.getBoundingClientRect(),s=Re(t);let a=V(1);e&&(o?H(o)&&(a=_t(o)):a=_t(t));const r=fa(s,n,o)?jo(s):V(0);let c=(i.left+r.x)/a.x,l=(i.top+r.y)/a.y,d=i.width/a.x,u=i.height/a.y;if(s){const p=P(s),h=o&&H(o)?P(o):o;let m=p,g=Oe(m);for(;g&&o&&h!==m;){const y=_t(g),v=g.getBoundingClientRect(),b=B(g),_=v.left+(g.clientLeft+parseFloat(b.paddingLeft))*y.x,w=v.top+(g.clientTop+parseFloat(b.paddingTop))*y.y;c*=y.x,l*=y.y,d*=y.x,u*=y.y,c+=_,l+=w,m=P(g),g=Oe(m)}}return ee({width:d,height:u,x:c,y:l})}function se(t,e){const n=ie(t).scrollLeft;return e?e.left+n:st(q(t)).left+n}function Fo(t,e){const n=t.getBoundingClientRect(),o=n.left+e.scrollLeft-se(t,n),i=n.top+e.scrollTop;return{x:o,y:i}}function pa(t){let{elements:e,rect:n,offsetParent:o,strategy:i}=t;const s=i==="fixed",a=q(o),r=e?oe(e.floating):!1;if(o===a||r&&s)return n;let c={scrollLeft:0,scrollTop:0},l=V(1);const d=V(0),u=W(o);if((u||!u&&!s)&&((bt(o)!=="body"||Et(a))&&(c=ie(o)),W(o))){const h=st(o);l=_t(o),d.x=h.x+o.clientLeft,d.y=h.y+o.clientTop}const p=a&&!u&&!s?Fo(a,c):V(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+d.x+p.x,y:n.y*l.y-c.scrollTop*l.y+d.y+p.y}}function ha(t){return Array.from(t.getClientRects())}function ma(t){const e=q(t),n=ie(t),o=t.ownerDocument.body,i=R(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),s=R(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight);let a=-n.scrollLeft+se(t);const r=-n.scrollTop;return B(o).direction==="rtl"&&(a+=R(e.clientWidth,o.clientWidth)-i),{width:i,height:s,x:a,y:r}}const Uo=25;function ga(t,e){const n=P(t),o=q(t),i=n.visualViewport;let s=o.clientWidth,a=o.clientHeight,r=0,c=0;if(i){s=i.width,a=i.height;const d=Me();(!d||d&&e==="fixed")&&(r=i.offsetLeft,c=i.offsetTop)}const l=se(o);if(l<=0){const d=o.ownerDocument,u=d.body,p=getComputedStyle(u),h=d.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,m=Math.abs(o.clientWidth-u.clientWidth-h);m<=Uo&&(s-=m)}else l<=Uo&&(s+=l);return{width:s,height:a,x:r,y:c}}const ba=new Set(["absolute","fixed"]);function va(t,e){const n=st(t,!0,e==="fixed"),o=n.top+t.clientTop,i=n.left+t.clientLeft,s=W(t)?_t(t):V(1),a=t.clientWidth*s.x,r=t.clientHeight*s.y,c=i*s.x,l=o*s.y;return{width:a,height:r,x:c,y:l}}function zo(t,e,n){let o;if(e==="viewport")o=ga(t,n);else if(e==="document")o=ma(q(t));else if(H(e))o=va(e,n);else{const i=jo(t);o={x:e.x-i.x,y:e.y-i.y,width:e.width,height:e.height}}return ee(o)}function Vo(t,e){const n=J(t);return n===e||!H(n)||vt(n)?!1:B(n).position==="fixed"||Vo(n,e)}function _a(t,e){const n=e.get(t);if(n)return n;let o=St(t,[],!1).filter(r=>H(r)&&bt(r)!=="body"),i=null;const s=B(t).position==="fixed";let a=s?J(t):t;for(;H(a)&&!vt(a);){const r=B(a),c=Ie(a);!c&&r.position==="fixed"&&(i=null),(s?!c&&!i:!c&&r.position==="static"&&!!i&&ba.has(i.position)||Et(a)&&!c&&Vo(t,a))?o=o.filter(d=>d!==a):i=r,a=J(a)}return e.set(t,o),o}function ya(t){let{element:e,boundary:n,rootBoundary:o,strategy:i}=t;const a=[...n==="clippingAncestors"?oe(e)?[]:_a(e,this._c):[].concat(n),o],r=a[0],c=a.reduce((l,d)=>{const u=zo(e,d,i);return l.top=R(u.top,l.top),l.right=gt(u.right,l.right),l.bottom=gt(u.bottom,l.bottom),l.left=R(u.left,l.left),l},zo(e,r,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function wa(t){const{width:e,height:n}=Bo(t);return{width:e,height:n}}function xa(t,e,n){const o=W(e),i=q(e),s=n==="fixed",a=st(t,!0,s,e);let r={scrollLeft:0,scrollTop:0};const c=V(0);function l(){c.x=se(i)}if(o||!o&&!s)if((bt(e)!=="body"||Et(i))&&(r=ie(e)),o){const h=st(e,!0,s,e);c.x=h.x+e.clientLeft,c.y=h.y+e.clientTop}else i&&l();s&&!o&&i&&l();const d=i&&!o&&!s?Fo(i,r):V(0),u=a.left+r.scrollLeft-c.x-d.x,p=a.top+r.scrollTop-c.y-d.y;return{x:u,y:p,width:a.width,height:a.height}}function Pe(t){return B(t).position==="static"}function qo(t,e){if(!W(t)||B(t).position==="fixed")return null;if(e)return e(t);let n=t.offsetParent;return q(t)===n&&(n=n.ownerDocument.body),n}function Wo(t,e){const n=P(t);if(oe(t))return n;if(!W(t)){let i=J(t);for(;i&&!vt(i);){if(H(i)&&!Pe(i))return i;i=J(i)}return n}let o=qo(t,e);for(;o&&ia(o)&&Pe(o);)o=qo(o,e);return o&&vt(o)&&Pe(o)&&!Ie(o)?n:o||ca(t)||n}const Ea=async function(t){const e=this.getOffsetParent||Wo,n=this.getDimensions,o=await n(t.floating);return{reference:xa(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function Sa(t){return B(t).direction==="rtl"}const Ta={convertOffsetParentRelativeRectToViewportRelativeRect:pa,getDocumentElement:q,getClippingRect:ya,getOffsetParent:Wo,getElementRects:Ea,getClientRects:ha,getDimensions:wa,getScale:_t,isElement:H,isRTL:Sa};function Go(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function $a(t,e){let n=null,o;const i=q(t);function s(){var r;clearTimeout(o),(r=n)==null||r.disconnect(),n=null}function a(r,c){r===void 0&&(r=!1),c===void 0&&(c=1),s();const l=t.getBoundingClientRect(),{left:d,top:u,width:p,height:h}=l;if(r||e(),!p||!h)return;const m=Qt(u),g=Qt(i.clientWidth-(d+p)),y=Qt(i.clientHeight-(u+h)),v=Qt(d),_={rootMargin:-m+"px "+-g+"px "+-y+"px "+-v+"px",threshold:R(0,gt(1,c))||1};let w=!0;function E(M){const G=M[0].intersectionRatio;if(G!==c){if(!w)return a();G?a(!1,G):o=setTimeout(()=>{a(!1,1e-7)},1e3)}G===1&&!Go(l,t.getBoundingClientRect())&&a(),w=!1}try{n=new IntersectionObserver(E,{..._,root:i.ownerDocument})}catch{n=new IntersectionObserver(E,_)}n.observe(t)}return a(!0),s}function Ca(t,e,n,o){o===void 0&&(o={});const{ancestorScroll:i=!0,ancestorResize:s=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:r=typeof IntersectionObserver=="function",animationFrame:c=!1}=o,l=Re(t),d=i||s?[...l?St(l):[],...St(e)]:[];d.forEach(v=>{i&&v.addEventListener("scroll",n,{passive:!0}),s&&v.addEventListener("resize",n)});const u=l&&r?$a(l,n):null;let p=-1,h=null;a&&(h=new ResizeObserver(v=>{let[b]=v;b&&b.target===l&&h&&(h.unobserve(e),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var _;(_=h)==null||_.observe(e)})),n()}),l&&!c&&h.observe(l),h.observe(e));let m,g=c?st(t):null;c&&y();function y(){const v=st(t);g&&!Go(g,v)&&n(),g=v,m=requestAnimationFrame(y)}return n(),()=>{var v;d.forEach(b=>{i&&b.removeEventListener("scroll",n),s&&b.removeEventListener("resize",n)}),u?.(),(v=h)==null||v.disconnect(),h=null,c&&cancelAnimationFrame(m)}}const Yo=ta,Ko=Zs,ka=ea,Aa=(t,e,n)=>{const o=new Map,i={platform:Ta,...n},s={...i.platform,_c:o};return Js(t,e,{...i,platform:s})};function Xo(t){var e,n,o="";if(typeof t=="string"||typeof t=="number")o+=t;else if(typeof t=="object")if(Array.isArray(t)){var i=t.length;for(e=0;e<i;e++)t[e]&&(n=Xo(t[e]))&&(o&&(o+=" "),o+=n)}else for(n in t)t[n]&&(o&&(o+=" "),o+=n);return o}function La(){for(var t,e,n=0,o="",i=arguments.length;n<i;n++)(t=arguments[n])&&(e=Xo(t))&&(o&&(o+=" "),o+=e);return o}const D={capture:!0,passive:!0},at=typeof window<"u"&&typeof document<"u";function Ia(t,e){let n;return(...o)=>{clearTimeout(n),n=setTimeout(()=>t(...o),e)}}function f(t,e,n){return n===void 0?t.getAttribute(e)??null:(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}let Ma=0;const Oa=`${Date.now().toString(36)}${Math.random().toString(36).slice(2,5)}`;function ae(t){return t.id||(t.id=`${Oa}${++Ma}`),t.id}const Qo=(t,e,[...n])=>{for(const o of n[0].split(","))n[0]=o,e[`${t}EventListener`](...n)},$=(t,...e)=>{Tt&&(t===window||t===document)&&Tt.push(()=>Jo(t,...e)),Qo("add",t,e)},Jo=(t,...e)=>Qo("remove",t,e);let Tt=null;const N=t=>{if(!at||!window.requestAnimationFrame)return;window._mtdsUnbindEvents||(window._mtdsUnbindEvents=new Map);const e=()=>requestAnimationFrame(()=>{const n=String(t).replace(/(\n|\s)/g,"");window._mtdsUnbindEvents?.get(n)?.map(o=>o()),Tt=[],t(),window._mtdsUnbindEvents?.set(n,Tt?.slice(0)),Tt=null});document.readyState==="complete"?e():$(window,"load",e)},De=new WeakMap,Ra=`.${T.dialog.split(" ")[0]}`;function rt(t,e,{contain:n,middleware:o,placement:i,...s}={}){if(De.get(t)?.(),De.delete(t),e){const a=t.closest(Ra)?.querySelector(":scope > footer"),r=Number(f(t,"data-inset"))||20,l={bottom:(a?.clientHeight||0)+r,left:r,right:r,top:r},d=f(t,"data-position")??"bottom";De.set(t,Ca(e,t,()=>{if(!t.isConnected||!e.isConnected||t.hidden)return rt(t,!1);Aa(e,t,{...s,placement:i||d,middleware:[Ko({padding:l}),Yo(),...n?[ka({padding:l,apply:n})]:[],...o||[]]}).then(({x:u,y:p})=>{t.style.left=`${u}px`,t.style.top=`${p}px`})}))}}function Zo(t){let e=0;const n=()=>setTimeout(o,200),o=()=>{t([],i),i.takeRecords(),e=0},i=new MutationObserver(()=>{e||(e=requestAnimationFrame(n))});return i}const Ne=new WeakMap,yt=(t,e,n)=>{if(!at||!window.requestAnimationFrame)return;const o=t.getElementsByClassName(e),i=Ne.get(t)||[];i.length||(Ne.set(t,i),Zo((s,a)=>{if(t.isConnected&&i?.length)for(const r of i)r();else a?.disconnect(),Ne.delete(t)}).observe(t,{attributeFilter:["class","hidden"],attributes:!0,childList:!0,subtree:!0})),i.push(()=>n(o))},He=t=>t instanceof HTMLElement&&"validity"in t&&!(t instanceof HTMLButtonElement),C=(t,e,n)=>{const o=document.createElement(t);if(n&&(o.textContent=n),e)for(const[i,s]of Object.entries(e))f(o,i,s);return o},Pa=typeof HTMLElement>"u"?class{}:HTMLElement,Da=`.${T.breadcrumbs.split(" ")[0]}`,Na=`.${T.card.split(" ")[0]}`,ti=`.${T.chip.split(" ")[0]}`,Ha=`.${T.helptext.split(" ")[0]}`,Ba=`.${T.pagination.split(" ")[0]}`,ja='summary,u-summary,a,button,[role="tab"],[role="button"]',Fa="click,toggle,submit,change",Be="mattilsynet.matomo.cloud",j="mtds-analytics-banner",Ua="https://www.mattilsynet.no/om-mattilsynet/personvernerklaering/informasjonskapsler";function ei(t,e={}){if(at){if(window._paq||(window._paq=[],window._paq.push(["HeatmapSessionRecording::disable"]),window._paq.push(["enableLinkTracking"]),window._paq.push(["setTrackerUrl",`https://${Be}/matomo.php`])),window._mtm||(window._mtm=window._mtm||[],window._mtm.push({"mtm.startTime":Date.now(),event:"mtm.Start"})),t==="init"){window._mtdsTracking={enabled:window.location.hostname!=="localhost",...window._mtdsTracking,...e};const{consent:n,enabled:o,matomoId:i,matomoTagManagerId:s}=window._mtdsTracking;if(i&&window._paq.push(["setSiteId",i]),o){n!=="custom"&&za();const a=s?`https://cdn.matomo.cloud/${Be}/container_${s}.js`:`https://cdn.matomo.cloud/${Be}/matomo.js`;document.querySelector(`script[src="${a}"]`)||document.head.append(C("script",{async:"",src:a}))}}if(window._mtdsTracking?.enabled!==!1){if(window._mtdsTracking?.enabled==="debug")return console.info(`analytics("${t}", `,e,")");if(t==="pageview"){const{url:n,title:o}=e;window._paq.push(["setCustomUrl",n||location.href]),window._paq.push(["setDocumentTitle",o||document.title]),window._paq.push(["trackPageView"])}else if(t==="event"){const{category:n,action:o,name:i,value:s}=e,a=["trackEvent",n,o,i,s];let r=location.href;window._paq.push([function(){r=this.getCurrentUrl()}]),window._paq.push(["setCustomUrl",r.split("#")[0]]),window._paq.push(a.filter(c=>c!==void 0)),window._paq.push(["setCustomUrl",r])}else if(t==="search"){const{query:n,category:o=!1,results:i=!1}=e;window._paq.push(["trackSiteSearch",n,o,i])}else t==="matomo"&&window._paq.push(e)}}}function za(){if(document.getElementById(j)||window.localStorage.getItem(j))return;document.body.insertAdjacentHTML("afterbegin",`<dialog id="${j}" data-analytics="ignore"><style>
9
9
  #${j}[open] { box-sizing: border-box; display: flex; align-items: center; background: #116e6b; border-radius: .5em; border: 0; box-shadow: 0 .25em .5em rgba(0,0,0,.3); color: #fff; font-size: .875em; inset: auto auto 1em 1em; max-width: calc(100vw - 2em); outline: 0; padding: .5em; position: fixed; z-index: 99999 }
10
10
  #${j} button { all: unset; box-sizing: border-box; cursor: pointer; display: flex; width: 1.5em; height: 1.5em; font: 300 1.5em/1.35 sans-serif; border-radius: .25em; place-content: center; transition: .2s; transition-property: background, scale }
11
11
  #${j} button:focus-visible { outline: 2px solid }
@@ -13,9 +13,9 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
13
13
  #${j} button:active { background: #054449; scale: .9 }
14
14
  #${j} p { margin: 0 .25em }
15
15
  </style>
16
- <p>Vi bruker <a href="${jr}" target="_blank">informasjonskapsler</a> for å forbedre brukeropplevelsen.</p>
16
+ <p>Vi bruker <a href="${Ua}" target="_blank">informasjonskapsler</a> for å forbedre brukeropplevelsen.</p>
17
17
  <form method="dialog" data-analytics="ignore"><button type="submit" aria-label="OK">&times;</button></form>
18
- </dialog>`);const e=document.getElementById(j),n=()=>window.localStorage.setItem(j,"seen");e.addEventListener("close",n,{once:!0}),e.show()}function Ur(t){window._mtdsTracking?.enabled&&setTimeout(qr,0,t)}function qr({type:t,target:e}){const n=t==="click"?e?.closest?.(Hr):e;if(!(n instanceof Element)||n.closest('[data-analytics="ignore"]'))return;let o="click",i="Button",s=ei(n)||Wr(n)||f(n,"data-tooltip")||"";if(t==="submit")i="Form",o="submit",s=s||document.title;else if(t==="toggle"){if(!n.matches("dialog:modal"))return;i="Dialog",o="open"}else if(t==="change"){const r=f(n,"type"),a=r==="checkbox"||r==="radio"?n.closest("fieldset"):null;i=n.closest(Zo)?"Chip":"Form",o="change",s=ei(a||n)||$t(a?.querySelector("legend"))||$t(n?.labels?.[0])}else if(f(n,"role")==="tab")i="Tab",o="navigate";else if(f(n,"popovertarget")){if(!Vr(n)?.matches(":popover-open"))return;i=n.closest(Dr)?"HelpText":"Popover",o="open"}else if(n.nodeName.endsWith("SUMMARY")){if(!n.parentElement.open)return;i="Details",o="open"}else if(f(n,"data-command")==="toggle-app-expanded"){const r=zr(n,"--mtds-tooltip-position")==="none";i="Sidebar",o=r?"expand":"minimize",s=r&&f(n,"data-tooltip")||$t(n)}else if(n.closest(Rr))i="Breadcrumbs",o="navigate";else if(n.closest(Nr))i="Pagintation",o="navigate";else if(n.closest(Pr))i="Card",o=n instanceof HTMLAnchorElement?"navigate":"click";else if(n.closest(Zo))i="Chip",o=n.hasAttribute("data-removable")?"remove":"click";else if(n.closest("th[aria-sort]"))i="Table",o="sort";else if(n instanceof HTMLAnchorElement)i="Link",o=n.protocol==="mailto:"?"email":"navigate",n.hasAttribute("download")?o="download":n.hash&&n.href.startsWith(location.href.split("#")[0])&&(o="anchor");else if(n.hasAttribute("aria-expanded")){if(f(n,"aria-expanded")!=="true")return;i="Expand",o="open"}ti("event",{category:f(n,"data-analytics-category")??i,action:f(n,"data-analytics-action")??o,name:f(n,"data-analytics-name")??s})}const $t=t=>t?.textContent?.trim()||"",ei=t=>t&&f(t,"aria-label")||"",Vr=t=>document.getElementById(f(t,"popovertarget")||""),zr=(t,e)=>window.getComputedStyle(t).getPropertyValue(e)?.trim(),Wr=t=>{const e=$t(t),n=$t(t.querySelector("h1,h2,h3,h4,h5,h6"));return e.startsWith(n)&&n||e.slice(0,100).trim()};D(()=>$(document,Br,Ur,P)),typeof window<"u"&&window.CSSStyleSheet&&document.adoptedStyleSheets&&(()=>{const t="--mtds-app-expanded",e=new CSSStyleSheet,n=()=>!window.localStorage.getItem(t)?.includes("false");document.adoptedStyleSheets.push(e),window.mtdsToggleAppExpanded=o=>{try{const i=o??!n();e.replaceSync?.(`:root { ${t}: var(${t}--${i})}`),window.localStorage.setItem(t,i)}catch{}},window.mtdsToggleAppExpanded(n())})();const ni=T.app.split(" ")[0],Gr=T.sticky.split(" ")[0],Yr='[data-command="toggle-app-expanded"]',je=`.${ni} > dialog,.${ni} dialog ~ main`,oi=t=>{document.startViewTransition?document.startViewTransition(t):t()},ii=t=>oi(()=>window.mtdsToggleAppExpanded?.(t));function Kr({target:t,defaultPrevented:e}){const n=t?.closest?.("a");if(n?.closest("dialog")&&n?.closest(je))return si();if(e||!(t instanceof HTMLButtonElement)||!t.matches(Yr))return;getComputedStyle(t).position==="sticky"?ii():oi(()=>{const i=document.querySelector(je);i?.setAttribute("data-closedby","any"),i?.showModal()})}function si(){document.querySelector(je)?.close()}let Fe=0,wt,Y=0,L,Ue=0,ae=0,qe=!1,Ve=0,lt=0;function Xr([t]){L=t,ri()}function ri(){if(!L?.isConnected)return;const t=window.scrollY,e=t<lt;lt=t,e!==wt&&(Fe=(L.parentElement?.getBoundingClientRect().top||0)+lt,wt=e,Ue=L.offsetHeight,ae=L.getBoundingClientRect().top+lt,qe=L.offsetHeight<=window.innerHeight,Ve=window.innerHeight),!(Y===-1&&qe)&&(Y!==-1&&(qe||wt&&lt<=ae)?(L.style.setProperty("--pos","sticky"),L.style.setProperty("--top","0px"),Y=-1):Y===-1&&!wt?(L.style.setProperty("--pos","relative"),L.style.setProperty("--top",`${Math.max(0,lt-Fe)}px`),Y=0):Y!==1&&!wt&&lt+Ve>=ae+Ue?(L.style.setProperty("--pos","sticky"),L.style.setProperty("--top",`${Ve-Ue}px`),Y=1):Y===1&&wt&&(L.style.setProperty("--pos","relative"),L.style.setProperty("--top",`${ae-Fe}px`),Y=0))}D(()=>{yt(document.documentElement,Gr,Xr),$(document,"click",Kr,P),$(window,"resize",Ar(si,100),P),$(window,"scroll",ri,P)});const Qr=(t,e,n=Number.POSITIVE_INFINITY)=>{const o=(n-1)/2,i=Math.max(Math.min(t-Math.floor(o),e-n+1),1),s=Math.min(Math.max(t+Math.ceil(o),n),e),r=Array.from({length:s+1-i},(a,c)=>c+i);return n>4&&i>1&&r.splice(0,2,1,0),n>3&&s<e&&r.splice(-2,2,0,e),r},Jr=({current:t=1,total:e=10,show:n=7})=>({prev:t>1?t-1:0,next:t<e?t+1:0,pages:Qr(t,e,n).map((o,i)=>({current:o===t&&"page",key:`key-${o}-${i}`,page:o}))});function k(t,e={}){const n=document.getElementById(e.id||"")||C("dialog");return f(n,"aria-busy",e.busy?"true":null),f(n,"class",kr(T.toast,e.className)),f(n,"data-closedby",e.closedby||null),f(n,"data-color",e.color||null),f(n,"data-icon",`${e.icon??""}`||null),f(n,"data-timeout",`${e.timeout??""}`||null),f(n,"id",e.id||`${Date.now()}`),f(n,"open",e.open===!1?null:""),n.innerHTML=t,n.addEventListener("animationend",Zr,{once:!0}),document.body.appendChild(n),n.id}function Zr({animationName:t,target:e}){t===T._toastClose&&e.remove()}k.success=(t,e)=>k(t,{color:"success",...e}),k.danger=(t,e)=>k(t,{color:"danger",...e}),k.info=(t,e)=>k(t,{color:"info",...e}),k.warning=(t,e)=>k(t,{color:"warning",...e}),k.neutral=(t,e)=>k(t,{color:"neutral",...e}),k.promise=async function(e,n){const{loading:o,success:i,error:s,...r}=n,a=k(o,{busy:!0,...r});try{const c=await e();return k.success(i,{id:a,busy:!1}),c}catch(c){throw k.danger(s,{id:a,busy:!1}),c}};const ta=T.breadcrumbs.split(" ")[0];function ea(t){for(const e of t)e.querySelectorAll("li a").forEach((n,o,{length:i})=>{f(n,"aria-current",o===i-1?"page":null)})}D(()=>yt(document.documentElement,ta,ea));const na=`:host(:not([hidden])) {
18
+ </dialog>`);const e=document.getElementById(j),n=()=>window.localStorage.setItem(j,"seen");e.addEventListener("close",n,{once:!0}),e.show()}function Va(t){window._mtdsTracking?.enabled&&setTimeout(qa,0,t)}function qa({type:t,target:e}){const n=t==="click"?e?.closest?.(ja):e;if(!(n instanceof Element)||n.closest('[data-analytics="ignore"]'))return;let o="click",i="Button",s=ni(n)||Ya(n)||f(n,"data-tooltip")||"";if(t==="submit")i="Form",o="submit",s=s||document.title;else if(t==="toggle"){if(!n.matches("dialog:modal"))return;i="Dialog",o="open"}else if(t==="change"){const a=f(n,"type"),r=a==="checkbox"||a==="radio"?n.closest("fieldset"):null;i=n.closest(ti)?"Chip":"Form",o="change",s=ni(r||n)||$t(r?.querySelector("legend"))||$t(n?.labels?.[0])}else if(f(n,"role")==="tab")i="Tab",o="navigate";else if(f(n,"popovertarget")){if(!Wa(n)?.matches(":popover-open"))return;i=n.closest(Ha)?"HelpText":"Popover",o="open"}else if(n.nodeName.endsWith("SUMMARY")){if(!n.parentElement.open)return;i="Details",o="open"}else if(f(n,"data-command")==="toggle-app-expanded"){const a=Ga(n,"--mtds-tooltip-position")==="none";i="Sidebar",o=a?"expand":"minimize",s=a&&f(n,"data-tooltip")||$t(n)}else if(n.closest(Da))i="Breadcrumbs",o="navigate";else if(n.closest(Ba))i="Pagintation",o="navigate";else if(n.closest(Na))i="Card",o=n instanceof HTMLAnchorElement?"navigate":"click";else if(n.closest(ti))i="Chip",o=n.hasAttribute("data-removable")?"remove":"click";else if(n.closest("th[aria-sort]"))i="Table",o="sort";else if(n instanceof HTMLAnchorElement)i="Link",o=n.protocol==="mailto:"?"email":"navigate",n.hasAttribute("download")?o="download":n.hash&&n.href.startsWith(location.href.split("#")[0])&&(o="anchor");else if(n.hasAttribute("aria-expanded")){if(f(n,"aria-expanded")!=="true")return;i="Expand",o="open"}ei("event",{category:f(n,"data-analytics-category")??i,action:f(n,"data-analytics-action")??o,name:f(n,"data-analytics-name")??s})}const $t=t=>t?.textContent?.trim()||"",ni=t=>t&&f(t,"aria-label")||"",Wa=t=>document.getElementById(f(t,"popovertarget")||""),Ga=(t,e)=>window.getComputedStyle(t).getPropertyValue(e)?.trim(),Ya=t=>{const e=$t(t),n=$t(t.querySelector("h1,h2,h3,h4,h5,h6"));return e.startsWith(n)&&n||e.slice(0,100).trim()};N(()=>$(document,Fa,Va,D)),typeof window<"u"&&window.CSSStyleSheet&&document.adoptedStyleSheets&&(()=>{const t="--mtds-app-expanded",e=new CSSStyleSheet,n=()=>!window.localStorage.getItem(t)?.includes("false");document.adoptedStyleSheets.push(e),window.mtdsToggleAppExpanded=o=>{try{const i=o??!n();e.replaceSync?.(`:root { ${t}: var(${t}--${i})}`),window.localStorage.setItem(t,i)}catch{}},window.mtdsToggleAppExpanded(n())})();const oi=T.app.split(" ")[0],Ka=T.sticky.split(" ")[0],Xa='[data-command="toggle-app-expanded"]',je=`.${oi} > dialog,.${oi} dialog ~ main`,ii=t=>{document.startViewTransition?document.startViewTransition(t):t()},si=t=>ii(()=>window.mtdsToggleAppExpanded?.(t));function Qa({target:t,defaultPrevented:e}){const n=t?.closest?.("a");if(n?.closest("dialog")&&n?.closest(je))return ai();if(e||!(t instanceof HTMLButtonElement)||!t.matches(Xa))return;getComputedStyle(t).position==="sticky"?si():ii(()=>{const i=document.querySelector(je);i?.setAttribute("data-closedby","any"),i?.showModal()})}function ai(){document.querySelector(je)?.close()}let Fe=0,wt,Y=0,L,Ue=0,re=0,ze=!1,Ve=0,lt=0;function Ja([t]){L=t,ri()}function ri(){if(!L?.isConnected)return;const t=window.scrollY,e=t<lt;lt=t,e!==wt&&(Fe=(L.parentElement?.getBoundingClientRect().top||0)+lt,wt=e,Ue=L.offsetHeight,re=L.getBoundingClientRect().top+lt,ze=L.offsetHeight<=window.innerHeight,Ve=window.innerHeight),!(Y===-1&&ze)&&(Y!==-1&&(ze||wt&&lt<=re)?(L.style.setProperty("--pos","sticky"),L.style.setProperty("--top","0px"),Y=-1):Y===-1&&!wt?(L.style.setProperty("--pos","relative"),L.style.setProperty("--top",`${Math.max(0,lt-Fe)}px`),Y=0):Y!==1&&!wt&&lt+Ve>=re+Ue?(L.style.setProperty("--pos","sticky"),L.style.setProperty("--top",`${Ve-Ue}px`),Y=1):Y===1&&wt&&(L.style.setProperty("--pos","relative"),L.style.setProperty("--top",`${re-Fe}px`),Y=0))}N(()=>{yt(document.documentElement,Ka,Ja),$(document,"click",Qa,D),$(window,"resize",Ia(ai,100),D),$(window,"scroll",ri,D)});const Za=(t,e,n=Number.POSITIVE_INFINITY)=>{const o=(n-1)/2,i=Math.max(Math.min(t-Math.floor(o),e-n+1),1),s=Math.min(Math.max(t+Math.ceil(o),n),e),a=Array.from({length:s+1-i},(r,c)=>c+i);return n>4&&i>1&&a.splice(0,2,1,0),n>3&&s<e&&a.splice(-2,2,0,e),a},tr=({current:t=1,total:e=10,show:n=7})=>({prev:t>1?t-1:0,next:t<e?t+1:0,pages:Za(t,e,n).map((o,i)=>({current:o===t&&"page",key:`key-${o}-${i}`,page:o}))});function k(t,e={}){const n=document.getElementById(e.id||"")||C("dialog");return f(n,"aria-busy",e.busy?"true":null),f(n,"class",La(T.toast,e.className)),f(n,"data-closedby",e.closedby||null),f(n,"data-color",e.color||null),f(n,"data-icon",`${e.icon??""}`||null),f(n,"data-timeout",`${e.timeout??""}`||null),f(n,"id",e.id||`${Date.now()}`),f(n,"open",e.open===!1?null:""),n.innerHTML=t,n.addEventListener("animationend",er,{once:!0}),document.body.appendChild(n),n.id}function er({animationName:t,target:e}){t===T._toastClose&&e.remove()}k.success=(t,e)=>k(t,{color:"success",...e}),k.danger=(t,e)=>k(t,{color:"danger",...e}),k.info=(t,e)=>k(t,{color:"info",...e}),k.warning=(t,e)=>k(t,{color:"warning",...e}),k.neutral=(t,e)=>k(t,{color:"neutral",...e}),k.promise=async function(e,n){const{loading:o,success:i,error:s,...a}=n,r=k(o,{busy:!0,...a});try{const c=await e();return k.success(i,{id:r,busy:!1}),c}catch(c){throw k.danger(s,{id:r,busy:!1}),c}};const nr=T.breadcrumbs.split(" ")[0];function or(t){for(const e of t)e.querySelectorAll("li a").forEach((n,o,{length:i})=>{f(n,"aria-current",o===i-1?"page":null)})}N(()=>yt(document.documentElement,nr,or));const ir=`:host(:not([hidden])) {
19
19
  display: grid;
20
20
  gap: var(--ds-size-6);
21
21
  }
@@ -49,7 +49,6 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
49
49
 
50
50
  .axis {
51
51
  font-size: var(--ds-body-sm-font-size);
52
- aspect-ratio: var(--mtdsc-chart-aspect);
53
52
  display: grid;
54
53
  gap: var(--mtdsc-chart-axis-gap);
55
54
  grid-template-columns: fit-content(7em) 1fr;
@@ -60,12 +59,15 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
60
59
  }
61
60
 
62
61
  .axis::before {
62
+ border-bottom-left-radius: var(--mtdsc-chart-axis-edge-radius);
63
+ border-color: var(--mtdsc-chart-axis-edge-color);
64
+ border-style: solid;
65
+ border-width: 0 0 var(--mtdsc-chart-axis-edge-width)
66
+ var(--mtdsc-chart-axis-edge-width);
63
67
  content: "";
64
68
  grid-area: chart;
65
- border-style: solid;
66
- border-width: 0 0 var(--ds-border-width-default)
67
- var(--ds-border-width-default);
68
- border-bottom-left-radius: var(--ds-border-radius-lg);
69
+ pointer-events: none;
70
+ z-index: 2;
69
71
  }
70
72
 
71
73
  .axisSteps,
@@ -76,12 +78,19 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
76
78
  display: grid;
77
79
  position: relative; /* Help .lineContainer positioning */
78
80
  }
79
-
80
81
  .axisGroups {
81
- gap: var(--mtdsc-chart-axis-gap);
82
+ --gap: max(
83
+ 1px,
84
+ clamp(
85
+ .5%,
86
+ calc(10% / var(--bars) * var(--groups)),
87
+ var(--mtdsc-chart-axis-gap)
88
+ )
89
+ );
90
+ gap: var(--mtdsc-chart-axis-gap) var(--gap);
82
91
  grid-area: chart / chart / x-axis / chart;
92
+ grid-auto-columns: 1fr;
83
93
  grid-template-rows: subgrid;
84
- grid-auto-columns: minmax(0, 1fr);
85
94
  padding: 0 var(--mtdsc-chart-axis-gap);
86
95
  text-align: center;
87
96
  }
@@ -91,16 +100,34 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
91
100
  }
92
101
  .axisGroup::after {
93
102
  content: attr(data-label);
103
+ direction: ltr; /* Prevent inherited rtl */
104
+ min-width: 0; /* Allow word-wrapping */
105
+ }
106
+ :host(:not([data-variant|="bar"])) {
107
+ .axisGroup::after {
108
+ justify-self: center;
109
+ text-align: start;
110
+ writing-mode: vertical-rl;
111
+ /* If wanting 45deg text: */
112
+ /* justify-self: center;
113
+ rotate: 45deg;
114
+ text-align: end;
115
+ writing-mode: sideways-lr;
116
+ transform-origin: 50% 0; */
117
+ }
94
118
  }
95
119
  .axisSteps {
96
- grid-auto-rows: 1fr;
120
+ align-items: end;
121
+ aspect-ratio: var(--mtdsc-chart-aspect);
97
122
  grid-area: chart / y-axis / chart / chart;
123
+ grid-auto-rows: 1fr;
98
124
  grid-template: 1px / subgrid;
99
125
  }
100
126
  .axisStep {
127
+ align-items: start;
101
128
  grid-column: inherit;
102
129
  grid-template-columns: inherit;
103
- place-content: end start;
130
+ height: 1px;
104
131
  text-align: right;
105
132
  }
106
133
  .axisStep::after {
@@ -109,64 +136,91 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
109
136
  }
110
137
  .axisStep::before {
111
138
  content: attr(data-label);
112
- translate: 0 50%;
139
+ translate: 0 -50%;
113
140
  }
114
141
  .axisStep[data-label="0"]::after {
115
142
  opacity: 0; /* Hide 0 line as it overlapps with .axis::before */
116
143
  }
117
144
 
118
- :host([data-variant|="column"]) .axisSteps,
119
- :host([data-variant|="column"]) .axisGroup {
145
+ /* Reduce amount of steps if small space */
146
+ :host(:not([data-variant|="bar"]))
147
+ .axisStepsYHalf
148
+ .axisStep:nth-last-child(even) {
149
+ display: none;
150
+ }
151
+ :host(:not([data-variant|="bar"]))
152
+ .axisStepsYHalf
153
+ .axisSteps:has(.axisStep:nth-last-child(even):first-child) {
154
+ grid-template-rows: 0.5fr;
155
+ }
156
+
157
+ :host([data-variant|="bar"]) .axisStepsXHalf .axisStep:nth-last-child(even) {
158
+ display: none;
159
+ }
160
+ :host([data-variant|="bar"])
161
+ .axisStepsXHalf
162
+ .axisSteps:has(.axisStep:nth-last-child(even):first-child) {
163
+ grid-template-columns: 0.5fr;
164
+ }
165
+
166
+ :host([data-variant|="bar"]) .axisSteps,
167
+ :host([data-variant|="bar"]) .axisGroup {
120
168
  direction: rtl; /* Reverse orders */
121
169
  }
122
- :host([data-variant|="column"]) .axisSteps > *,
123
- :host([data-variant|="column"]) .axisGroup > * {
170
+ :host([data-variant|="bar"]) .axisSteps > *,
171
+ :host([data-variant|="bar"]) .axisGroup > * {
124
172
  direction: ltr;
125
173
  }
126
- :host([data-variant|="column"]) .axisGroups {
174
+ :host([data-variant|="bar"]) .axisGroups {
175
+ aspect-ratio: var(--mtdsc-chart-aspect);
176
+ gap: 1% var(--mtdsc-chart-axis-gap);
127
177
  grid-area: chart / y-axis / chart / chart;
128
178
  grid-template: none / subgrid;
129
179
  padding: var(--mtdsc-chart-axis-gap) 0;
130
180
  row-gap: var(--mtdsc-chart-axis-gap);
131
181
  text-align: right;
132
182
  }
133
- :host([data-variant|="column"]) .axisGroup::after {
183
+ :host([data-variant|="bar"]) .axisGroup::after {
134
184
  align-self: center; /* Since text-align does not work vertically */
135
185
  }
136
- :host([data-variant|="column"]) .axisGroup {
186
+ :host([data-variant|="bar"]) .axisGroup {
137
187
  grid-column: inherit;
138
188
  grid-row: auto;
139
189
  }
140
- :host([data-variant|="column"]) .axisSteps {
141
- grid-auto-columns: 1fr;
190
+ :host([data-variant|="bar"]) .axisSteps {
191
+ align-items: stretch;
192
+ aspect-ratio: auto;
142
193
  grid-area: chart / chart / x-axis / chart;
194
+ grid-auto-columns: 1fr;
143
195
  grid-template: subgrid / 1px;
144
196
  }
145
- :host([data-variant|="column"]) .axisStep {
197
+ :host([data-variant|="bar"]) .axisStep {
198
+ align-items: stretch;
146
199
  grid-row: inherit;
147
200
  grid-column: auto;
148
201
  grid-template-rows: inherit;
149
202
  grid-template-columns: none;
203
+ text-align: center;
150
204
  }
151
- :host([data-variant|="column"]) .axisStep::after {
205
+ :host([data-variant|="bar"]) .axisStep::after {
152
206
  order: -1;
153
207
  border-left: var(--mtdsc-chart-axis-border);
154
208
  border-bottom: 0;
155
209
  }
156
- :host([data-variant|="column"]) .axisStep::before {
210
+ :host([data-variant|="bar"]) .axisStep::before {
157
211
  translate: -50% 0;
158
212
  }
159
213
 
160
214
  .axisGroupContent {
161
215
  display: flex;
162
216
  }
163
- :host([data-variant="bar-stacked"]) .axisGroupContent {
217
+ :host([data-variant="column-stacked"]) .axisGroupContent {
164
218
  flex-direction: column-reverse;
165
219
  }
166
- :host([data-variant="column"]) .axisGroupContent {
220
+ :host([data-variant="bar"]) .axisGroupContent {
167
221
  flex-direction: column;
168
222
  }
169
- :host([data-variant="column-stacked"]) .axisGroupContent {
223
+ :host([data-variant="bar-stacked"]) .axisGroupContent {
170
224
  flex-direction: row;
171
225
  }
172
226
 
@@ -188,7 +242,7 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
188
242
  z-index: 2; /* z-index to place on top when outlined */
189
243
  }
190
244
 
191
- :host([data-variant|="column"]) .bar {
245
+ :host([data-variant|="bar"]) .bar {
192
246
  border-radius: 0 var(--ds-border-radius-sm) var(--ds-border-radius-sm) 0;
193
247
  width: var(--size);
194
248
  height: 100%;
@@ -198,22 +252,22 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
198
252
  /* Prevent double border - using margin to see border around bars */
199
253
  /* Prevent double border - using border to avoid affecting size */
200
254
  :host(:not([data-variant])) .bar + .bar,
201
- :host([data-variant="bar"]) .bar + .bar {
255
+ :host([data-variant="column"]) .bar + .bar {
202
256
  margin-left: -1px;
203
257
  }
204
- :host([data-variant="bar-stacked"]) .bar:not(:last-child) {
258
+ :host([data-variant="column-stacked"]) .bar:not(:last-child) {
205
259
  border-radius: 0;
206
260
  }
207
- :host([data-variant="bar-stacked"]) .bar + .bar {
261
+ :host([data-variant="column-stacked"]) .bar + .bar {
208
262
  border-bottom: none;
209
263
  }
210
- :host([data-variant="column"]) .bar + .bar {
264
+ :host([data-variant="bar"]) .bar + .bar {
211
265
  margin-top: -1px;
212
266
  }
213
- :host([data-variant="column-stacked"]) .bar:not(:last-child) {
267
+ :host([data-variant="bar-stacked"]) .bar:not(:last-child) {
214
268
  border-radius: 0;
215
269
  }
216
- :host([data-variant="column-stacked"]) .bar + .bar {
270
+ :host([data-variant="bar-stacked"]) .bar + .bar {
217
271
  border-left: none;
218
272
  }
219
273
 
@@ -259,19 +313,19 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
259
313
  mask: linear-gradient(to bottom, black, transparent);
260
314
  }
261
315
 
316
+ /* Ensure more contrast for line colors */
262
317
  .line,
263
318
  .linePoint,
264
319
  :host:has(.linePoint) .legend::before {
265
- filter: brightness(0.8) saturate(2); /* Ensure more contrast for line colors */
320
+ filter: var(--_mtdsc-chart-line-filter);
266
321
  }
267
322
 
268
323
  .linePoint {
269
- --size: var(--ds-size-3);
270
- background-color: var(--color);
324
+ --size: var(--ds-size-2);
325
+ background: var(--color);
271
326
  border-radius: var(--ds-border-radius-full);
272
327
  border: var(--mtdsc-chart-border-width) solid var(--mtdsc-chart-border-color);
273
328
  box-sizing: border-box;
274
- filter: brightness(0.8) saturate(2);
275
329
  height: var(--size);
276
330
  margin: calc(var(--size) / -2);
277
331
  padding: 0;
@@ -288,10 +342,17 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
288
342
  }
289
343
  .linePoint::before {
290
344
  content: "";
291
- inset: calc(var(--ds-size-2) * -1); /* Increase click surface */
345
+ inset: calc(var(--ds-size-3) * -1); /* Increase click surface */
292
346
  position: absolute;
293
347
  }
294
348
 
349
+ :host([data-dots="false"]) .linePoint,
350
+ :host([data-dots="hidden"]) .linePoint,
351
+ :host([data-dots="none"]) .linePoint {
352
+ background: none;
353
+ border: none;
354
+ }
355
+
295
356
  .legends {
296
357
  align-items: center;
297
358
  display: flex;
@@ -315,17 +376,23 @@ var mtds=function(M){"use strict";var ns=Object.defineProperty,rn=Object.getOwnP
315
376
  vertical-align: middle;
316
377
  width: var(--ds-size-5);
317
378
  }
318
- `;function oa(t,{type:e}){const n=e==="stacked",o=t[0].reduce((d,u,m)=>{const p=t.map(h=>h[m].number),g=p.reduce((h,_)=>h+_,0);return Math.max(d,...n?[g]:p)},0),i=10**(`${~~o}`.length-1),s=o/i<5?i/2:i,r=Math.ceil(o/s)*s,a=C("div",{class:"axisGroups"}),c=C("div");c.classList.add("axisSteps"),c.append(...Array.from({length:r/s+1},(d,u)=>ia(s*u)).reverse().map(d=>C("div",{class:"axisStep","data-label":d})));const l=C("div",{"aria-label":t[0][0].value||null,class:"axis",role:"figure"});return l.style.setProperty("--groups",`${t.length-1}`),l.style.setProperty("--total",`${r}`),l.append(c,a),{total:r,groups:a,axis:l}}const ia=new Intl.NumberFormat().format;function sa(t){return t[0].slice(1).map(({value:e,event:n},o)=>{const i=C("div",{class:"axisGroup","data-label":e}),s=i.appendChild(C("div",{class:"axisGroupContent"}));return t.slice(1).map(r=>r[o+1]).map(({tooltip:r,style:a,number:c})=>s.appendChild(C("div",{"aria-label":r,"data-event":n,class:"bar",role:"img",style:`${a}; --value: ${c}`,tabindex:"0"}))),i})}function ra(t,{total:e,variant:n}){const i=C("div",{class:"axisGroup"});return t.slice(1).forEach(([,...s])=>{const r=C("div",{class:"lineContainer",role:"list",style:s[0].style}),a=aa(s.map(({number:d},u,{length:m})=>[100/(m-1)*u,100-d/e*100]),0/100),c=document.createElementNS("http://www.w3.org/2000/svg","svg");f(c,"aria-hidden","true"),f(c,"preserveAspectRatio","none"),f(c,"viewBox","0 0 100 100");const l=document.createElementNS("http://www.w3.org/2000/svg","path");if(f(l,"class","line"),f(l,"d",a),f(l,"fill","none"),f(l,"stroke","currentColor"),n==="area"){const d=l.cloneNode(!0);f(d,"d",`M-100,100 L${a.slice(1)}L200,100`),f(d,"class","lineShade"),c.append(d)}s.forEach(({number:d,tooltip:u,event:m})=>{const p=C("div",{role:"listitem"});p.appendChild(C("div",{"aria-label":u,"data-event":m,tabindex:"0",class:"linePoint",role:"img",style:`--value: ${d}`})),r.append(p)}),r.appendChild(c).append(l),i.append(r)}),i}const aa=(t,e)=>t.map(([n,o],i,s)=>i?la(i,s,e):`M${n},${o}`).join(" "),ai=([t,e],[n,o])=>[t+n,e+o],li=([t,e],[n,o])=>[t-n,e-o],ci=(t,[e,n])=>[t*e,t*n],la=(t,e,n)=>{const o=e[t-1],i=e[t],[s,r]=ai(o,ci(n,li(i,e[t-2]||o))),[a,c]=ai(i,ci(n,li(o,e[t+1]||i)));return`C ${s},${r} ${a},${c} ${i[0]},${i[1]}`};function ca(t,{variant:e}){const n=document.createElementNS("http://www.w3.org/2000/svg","svg");f(n,"class","pie"),f(n,"viewBox","0 0 100 100");let o=0;const i=50,s=e==="doughnut"?25:0,r=t.slice(1).reduce((a,[,c])=>a+c.number,0);return t.slice(1).forEach(([,{tooltip:a,number:c,event:l,style:d}])=>{if(!c)return;const u=document.createElementNS("http://www.w3.org/2000/svg","path"),m=o/r;o+=c;const p=Math.min(o/r,.99999),g=p-m>.5?1:0,h=2*Math.PI*(m-.25),_=2*Math.PI*(p-.25),v=Math.cos(h),b=Math.sin(h),x=Math.cos(_),w=Math.sin(_),S=`M ${i+s*v} ${i+s*b} L ${i+i*v} ${i+i*b} A ${i} ${i} 0 ${g} 1 ${i+i*x} ${i+i*w} L ${i+s*x} ${i+s*w} A ${s} ${s} 0 ${g} 0 ${i+s*v} ${i+s*b}`;f(u,"aria-label",a),f(u,"data-event",l),f(u,"style",d),f(u,"d",S),f(u,"role","img"),f(u,"tabindex","0"),n.appendChild(u)}),n}const di="click,keydown,mousemove,mouseout",ui="mtds-chart-tooltip",Z=rt?document.getElementById(ui)||C("div",{class:T._tooltip,id:ui,hidden:""}):null;class da extends Or{_observer;static get observedAttributes(){return["data-variant"]}constructor(){super(),this.attachShadow({mode:"open"})}connectedCallback(){this._observer=new MutationObserver(this.attributeChangedCallback.bind(this)),this._observer.observe(this,{attributeFilter:["data-tooltip"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),this.attributeChangedCallback(),$(this,di,this)}disconnectedCallback(){Z&&(Z.hidden=!0),Qo(this,di,this),this._observer?.disconnect(),this._observer=void 0}attributeChangedCallback(){Array.from(this.shadowRoot?.children||[]).map(l=>l.remove());const e=pa(this.querySelector("table")),[n,o]=(f(this,"data-variant")||"bar").split("-"),i=C("style",{},na),s=C("div",{class:"legends"});e.slice(1).forEach(([{value:l,style:d}])=>{s.appendChild(C("div",{class:"legend",style:d},l))});const{axis:r,groups:a,total:c}=oa(e,{type:o});(n==="bar"||n==="column")&&a.append(...sa(e)),(n==="line"||n==="area")&&a.append(ra(e,{total:c,variant:n})),(n==="doughnut"||n==="pie")&&this.shadowRoot?.append(ca(e,{variant:n})),this.shadowRoot?.append(i,r,s)}handleEvent(e){e.type==="click"||e.type==="keydown"?ua(e,this):fa(e)}}function ua(t,e){if(t instanceof KeyboardEvent&&t.key!=="Enter")return;const n=t.composedPath()[0],o=e.querySelector("table"),[i,s]=n instanceof Element&&f(n,"data-event")?.split("-").map(Number)||[];o?.rows[i]?.cells[s]?.querySelector("a,button")?.click?.()}let fi="";function fa(t){if(!Z)return;Z?.isConnected||document.body.append(Z);const e=t.composedPath()[0],n=e instanceof Element&&e.getAttribute("aria-label")||"";n&&(Z.style.transform=`translate(${t.pageX}px, ${t.pageY}px)`),n!==fi&&(n&&(Z.textContent=n),fi=n,Z.hidden=!n)}const Ct=t=>t?.textContent?.trim()||"",pa=t=>Array.from(t?.rows||[],(e,n)=>Array.from(e.cells,(o,i)=>{const s=Ct(e.cells[0]),r=Ct(t?.rows[0].cells[i]),a=`${s}: ${Ct(o)}${r?` (${r})`:""}`;return{number:i&&n&&Number.parseFloat(Ct(o))||0,event:o.querySelector("a,button")&&`${n}-${i}`,style:`--color: var(--mtdsc-chart-color-${n}, var(--mtdsc-chart-color-base))`,value:Ct(o),tooltip:f(o,"data-tooltip")||a}}));rt&&!window.customElements.get("mtds-chart")&&window.customElements.define("mtds-chart",da);const ma=T.dialog.split(" ")[0],pi=rt?document.getElementsByClassName(ma):[],ha=()=>{for(const t of pi)t.isConnected&&t.showModal&&t.close&&(t.matches('[open]:not([data-modal="false"]):not(:modal)')?(f(t,"open",null),t.showModal()):t.matches(":modal:not([open])")&&(f(t,"open",""),t.close()))},ba=({clientX:t,clientY:e,target:n})=>{for(const s of pi)if(s.open&&f(s,"data-closedby")==="any"){const{top:r,right:a,bottom:c,left:l}=s.getBoundingClientRect();if(!(r<=e&&e<=c&&l<=t&&t<=a))return s.close()}const o=n?.closest?.("dialog");o&&n?.closest?.('[data-command="close"]')&&o.close()};D(()=>{$(document,"click",ba,P),Jo(ha).observe(document.documentElement,{attributeFilter:["open"],attributes:!0,childList:!0,subtree:!0})});function ga(t){if(t.animationName!==T._errorsummary)return;const e=t.target?.firstElementChild;e instanceof HTMLHeadingElement&&(f(e,"tabindex","-1"),e.focus())}D(()=>$(document,"animationend",ga,P));var va=Object.defineProperty,mi=Object.getOwnPropertySymbols,_a=Object.prototype.hasOwnProperty,ya=Object.prototype.propertyIsEnumerable,hi=(t,e,n)=>e in t?va(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,wa=(t,e)=>{for(var n in e||(e={}))_a.call(e,n)&&hi(t,n,e[n]);if(mi)for(var n of mi(e))ya.call(e,n)&&hi(t,n,e[n]);return t},kt=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",le=kt&&/android/i.test(navigator.userAgent),ze=kt&&/iPad|iPhone|iPod/.test(navigator.userAgent),bi;kt&&/^Mac/i.test(((bi=navigator.userAgentData)==null?void 0:bi.platform)||navigator.platform);var xa=`${le?"data":"aria"}-labelledby`,Ea=":host(:not([hidden])) { display: block }",Sa="outline: 1px dotted; outline: 5px auto Highlight; outline: 5px auto -webkit-focus-ring-color",gi=typeof HTMLElement>"u"?class{}:HTMLElement;function E(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var vi=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},At=(t,...e)=>vi("add",t,e),ce=(t,...e)=>vi("remove",t,e),Ta=(t,e)=>t.shadowRoot||t.attachShadow({mode:"open"}).append(Ye("slot"),Ye("style",e)),de=new WeakMap,We=(t,e)=>{if(e===void 0)return de.get(t);try{de.get(t).disconnect(),de.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),de.set(t,n)}},_i=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},$a=0,Ge=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++$a).toString(32)}`),t.id):"",Ye=(t,e,n)=>{const o=document.createElement(t);return e&&(o.textContent=e),o},yi={define:(t,e)=>!kt||window.customElements.get(t)||window.customElements.define(t,e)},ct,Ca=0,wi=t=>{ct||(ct=Ye("div"),ct.style.cssText="position:fixed;overflow:hidden;width:1px;white-space:nowrap",E(ct,"aria-live","assertive")),ct.isConnected||document.body.append(ct),t&&(ct.textContent=`${t}${Ca++%2?" ":""}`)},ka=(t,e,n="")=>{var o,i;const s={bubbles:!0,composed:!0,data:e,inputType:n},r=HTMLInputElement.prototype;t.dispatchEvent(new InputEvent("beforeinput",s)),(i=(o=Object.getOwnPropertyDescriptor(r,"value"))==null?void 0:o.set)==null||i.call(t,e),t.dispatchEvent(new InputEvent("input",s)),t.dispatchEvent(new Event("change",{bubbles:!0}))},Ke=!1,Xe=t=>(t?.type==="mouseup"&&(Ke=!1),t?.type==="mousedown"&&(Ke=!0,At(document,"mouseup",Xe,{once:!0})),Ke),Qe="disabled",Lt="selected",Aa=class extends gi{static get observedAttributes(){return[Qe,Lt]}connectedCallback(){ze||(this.tabIndex=-1),this.hasAttribute("role")||E(this,"role","option"),this.attributeChangedCallback()}attributeChangedCallback(){E(this,"aria-disabled",`${this.disabled}`),E(this,"aria-selected",`${this.selected}`)}get defaultSelected(){return this[Lt]}set defaultSelected(t){this[Lt]=t}get disabled(){return E(this,Qe)!==null}set disabled(t){E(this,Qe,t?"":null)}get form(){return this.closest("form")}get index(){var t;return[...((t=this.parentElement)==null?void 0:t.options)||[this]].indexOf(this)}get label(){var t;return(t=E(this,"label"))!=null?t:this.text}set label(t){E(this,"label",t)}get selected(){return E(this,Lt)!==null}set selected(t){E(this,Lt,t?"":null)}get text(){var t;return((t=this.textContent)==null?void 0:t.trim())||""}set text(t){this.textContent=t}get value(){var t;return(t=E(this,"value"))!=null?t:this.text}set value(t){E(this,"value",t)}};yi.define("u-option",Aa);var La=`${Ea}
379
+
380
+ :host([data-legend="false"]) .legends,
381
+ :host([data-legend="hidden"]) .legends,
382
+ :host([data-legend="none"]) .legends {
383
+ display: none;
384
+ }
385
+ `,sr=[.1,.2,.25,.5,1];function ar(t,{aspect:e,type:n}){const i=n==="stacked",s=t[0].reduce((m,g,y)=>{const v=t.map(_=>_[y].number),b=v.reduce((_,w)=>_+w,0);return Math.max(m,...i?[b]:v)},0),a=s/10,r=10**`${Math.round(a)}`.length,c=a/r,l=(sr.find(m=>m>c)||1)*r,d=Math.ceil(s/l)*l,u=C("div",{"aria-label":t[0][0].value||null,class:"axis",role:"figure",style:`${e?`--mtdsc-chart-aspect: ${e};`:""} --bars: ${t[0]?.length-1}; --groups: ${t.length-1}; --total: ${d}`}),p=u.appendChild(C("div",{class:"axisSteps"})),h=u.appendChild(C("div",{class:"axisGroups"}));return Array.from({length:d/l+1},(m,g)=>rr(l*g)).reverse().map(m=>p.append(C("div",{class:"axisStep","data-label":m}))),{total:d,groups:h,axis:u}}const rr=new Intl.NumberFormat().format;function lr(t){return t[0].slice(1).map(({value:e,event:n},o)=>{const i=C("div",{class:"axisGroup","data-label":e}),s=i.appendChild(C("div",{class:"axisGroupContent"}));return t.slice(1).map(a=>a[o+1]).map(({tooltip:a,style:r,number:c})=>s.appendChild(C("div",{"aria-label":a,"data-event":n,class:"bar",role:"img",style:`${r}; --value: ${c}`,tabindex:"0"}))),i})}function cr(t,{total:e,type:n,variant:o}){const i=Number.parseFloat(n||"0")||0,s=C("div",{class:"axisGroup"});return t.slice(1).forEach(([,...a])=>{const r=C("div",{class:"lineContainer",role:"list",style:a[0].style}),c=dr(a.map(({number:u},p,{length:h})=>[100/(h-1)*p,100-u/e*100]),i/100),l=document.createElementNS("http://www.w3.org/2000/svg","svg");f(l,"aria-hidden","true"),f(l,"preserveAspectRatio","none"),f(l,"viewBox","0 0 100 100");const d=document.createElementNS("http://www.w3.org/2000/svg","path");if(f(d,"class","line"),f(d,"d",c),f(d,"fill","none"),f(d,"stroke","currentColor"),o==="area"){const u=d.cloneNode(!0);f(u,"d",`M-100,100 L${c.slice(1)}L200,100`),f(u,"class","lineShade"),l.append(u)}a.forEach(({number:u,tooltip:p,event:h})=>{const m=C("div",{role:"listitem"});m.appendChild(C("div",{"aria-label":p,"data-event":h,tabindex:"0",class:"linePoint",role:"img",style:`--value: ${u}`})),r.append(m)}),r.appendChild(l).append(d),s.append(r)}),s}const dr=(t,e)=>t.map(([n,o],i,s)=>i?ur(i,s,e):`M${n},${o}`).join(" "),li=([t,e],[n,o])=>[t+n,e+o],ci=([t,e],[n,o])=>[t-n,e-o],di=(t,[e,n])=>[t*e,t*n],ur=(t,e,n)=>{const o=e[t-1],i=e[t],[s,a]=li(o,di(n,ci(i,e[t-2]||o))),[r,c]=li(i,di(n,ci(o,e[t+1]||i)));return`C ${s},${a} ${r},${c} ${i[0]},${i[1]}`};function fr(t,{aspect:e,variant:n}){const o=document.createElementNS("http://www.w3.org/2000/svg","svg");e&&o.style.setProperty("--mtdsc-chart-aspect",e),f(o,"class","pie"),f(o,"viewBox","0 0 100 100");let i=0;const s=50,a=n==="doughnut"?25:0,r=t.slice(1).reduce((c,[,l])=>c+l.number,0);return t.slice(1).forEach(([,{tooltip:c,number:l,event:d,style:u}])=>{if(!l)return;const p=document.createElementNS("http://www.w3.org/2000/svg","path"),h=i/r;i+=l;const m=Math.min(i/r,.99999),g=m-h>.5?1:0,y=2*Math.PI*(h-.25),v=2*Math.PI*(m-.25),b=Math.cos(y),_=Math.sin(y),w=Math.cos(v),E=Math.sin(v),M=`M ${s+a*b} ${s+a*_} L ${s+s*b} ${s+s*_} A ${s} ${s} 0 ${g} 1 ${s+s*w} ${s+s*E} L ${s+a*w} ${s+a*E} A ${a} ${a} 0 ${g} 0 ${s+a*b} ${s+a*_}`;f(p,"aria-label",c),f(p,"data-event",d),f(p,"style",u),f(p,"d",M),f(p,"role","img"),f(p,"tabindex","0"),o.appendChild(p)}),o}const ui="click,keydown,mousemove,mouseout",fi="mtds-chart-tooltip",Z=at?document.getElementById(fi)||C("div",{"aria-hidden":"true",class:T._tooltip,hidden:"",id:fi}):null;class pr extends Pa{_observer;_resize;static get observedAttributes(){return["data-variant","data-aspect"]}constructor(){super(),this.attachShadow({mode:"open"})}connectedCallback(){this._resize=new ResizeObserver(this.handleResize.bind(this)),this._resize.observe(this),this._observer=new MutationObserver(this.attributeChangedCallback.bind(this)),this._observer.observe(this,{attributeFilter:["data-tooltip"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),this.attributeChangedCallback(),$(this,ui,this)}disconnectedCallback(){Z&&(Z.hidden=!0),Jo(this,ui,this),this._resize?.disconnect(),this._observer?.disconnect(),this._observer=this._resize=void 0}attributeChangedCallback(){Array.from(this.shadowRoot?.children||[]).map(d=>d.remove());const[e,n]=(f(this,"data-variant")||"column").split("-"),o=f(this,"data-aspect")||void 0,i=gr(this.querySelector("table")),s=C("style",{},ir),a=C("div",{"aria-hidden":"hidden",class:"legends",role:"group"});i.slice(1).forEach(([{value:d,style:u}])=>{a.appendChild(C("div",{class:"legend",style:u},d))});const{axis:r,groups:c,total:l}=ar(i,{aspect:o,type:n});(e==="column"||e==="bar")&&c.append(...lr(i)),(e==="line"||e==="area")&&c.append(cr(i,{total:l,variant:e,type:n})),(e==="doughnut"||e==="pie")&&this.shadowRoot?.append(fr(i,{aspect:o,variant:e})),this.shadowRoot?.append(r,a,s)}handleEvent(e){e.type==="click"||e.type==="keydown"?hr(e,this):mr(e)}handleResize(){const e=this.shadowRoot?.firstElementChild,n=e?.firstElementChild;e?.classList.toggle("axisStepsYHalf",(n?.offsetHeight||0)<400),e?.classList.toggle("axisStepsXHalf",(n?.offsetWidth||0)<500)}}function hr(t,e){if(t instanceof KeyboardEvent&&t.key!=="Enter")return;const n=t.composedPath()[0],o=e.querySelector("table"),[i,s]=n instanceof Element&&f(n,"data-event")?.split("-").map(Number)||[];o?.rows[i]?.cells[s]?.querySelector("a,button")?.click?.()}let pi="";function mr(t){if(!Z)return;Z?.isConnected||document.body.append(Z);const e=t.composedPath()[0],n=e instanceof Element&&e.getAttribute("aria-label")||"";n&&(Z.style.transform=`translate(${t.pageX}px, ${t.pageY}px)`),n!==pi&&(n&&(Z.textContent=n),pi=n,Z.hidden=!n)}const Ct=t=>t?.textContent?.trim()||"",gr=t=>Array.from(t?.rows||[],(e,n)=>Array.from(e.cells,(o,i)=>{const s=Ct(e.cells[0]),a=Ct(t?.rows[0].cells[i]),r=`${s}: ${Ct(o)}${a?` (${a})`:""}`;return{number:i&&n&&Number.parseFloat(Ct(o))||0,event:o.querySelector("a,button")&&`${n}-${i}`,style:`--color: var(--mtdsc-chart-color-${n}, var(--mtdsc-chart-color-base))`,value:Ct(o),tooltip:f(o,"data-tooltip")||r}}));at&&!window.customElements.get("mtds-chart")&&window.customElements.define("mtds-chart",pr);const br=T.dialog.split(" ")[0],hi=at?document.getElementsByClassName(br):[],vr=()=>{for(const t of hi)t.isConnected&&t.showModal&&t.close&&(t.matches('[open]:not([data-modal="false"]):not(:modal)')?(f(t,"open",null),t.showModal()):t.matches(":modal:not([open])")&&(f(t,"open",""),t.close()))},_r=({clientX:t,clientY:e,target:n})=>{for(const s of hi)if(s.open&&f(s,"data-closedby")==="any"){const{top:a,right:r,bottom:c,left:l}=s.getBoundingClientRect();if(!(a<=e&&e<=c&&l<=t&&t<=r))return s.close()}const o=n?.closest?.("dialog");o&&n?.closest?.('[data-command="close"]')&&o.close()};N(()=>{$(document,"click",_r,D),Zo(vr).observe(document.documentElement,{attributeFilter:["open"],attributes:!0,childList:!0,subtree:!0})});function yr(t){if(t.animationName!==T._errorsummary)return;const e=t.target?.firstElementChild;e instanceof HTMLHeadingElement&&(f(e,"tabindex","-1"),e.focus())}N(()=>$(document,"animationend",yr,D));var wr=Object.defineProperty,mi=Object.getOwnPropertySymbols,xr=Object.prototype.hasOwnProperty,Er=Object.prototype.propertyIsEnumerable,gi=(t,e,n)=>e in t?wr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Sr=(t,e)=>{for(var n in e||(e={}))xr.call(e,n)&&gi(t,n,e[n]);if(mi)for(var n of mi(e))Er.call(e,n)&&gi(t,n,e[n]);return t},kt=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",le=kt&&/android/i.test(navigator.userAgent),qe=kt&&/iPad|iPhone|iPod/.test(navigator.userAgent),bi;kt&&/^Mac/i.test(((bi=navigator.userAgentData)==null?void 0:bi.platform)||navigator.platform);var Tr=`${le?"data":"aria"}-labelledby`,$r=":host(:not([hidden])) { display: block }",Cr="outline: 1px dotted; outline: 5px auto Highlight; outline: 5px auto -webkit-focus-ring-color",vi=typeof HTMLElement>"u"?class{}:HTMLElement;function S(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var _i=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},At=(t,...e)=>_i("add",t,e),ce=(t,...e)=>_i("remove",t,e),kr=(t,e)=>t.shadowRoot||t.attachShadow({mode:"open"}).append(Ye("slot"),Ye("style",e)),de=new WeakMap,We=(t,e)=>{if(e===void 0)return de.get(t);try{de.get(t).disconnect(),de.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),de.set(t,n)}},yi=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},Ar=0,Ge=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++Ar).toString(32)}`),t.id):"",Ye=(t,e,n)=>{const o=document.createElement(t);return e&&(o.textContent=e),o},wi={define:(t,e)=>!kt||window.customElements.get(t)||window.customElements.define(t,e)},ct,Lr=0,xi=t=>{ct||(ct=Ye("div"),ct.style.cssText="position:fixed;overflow:hidden;width:1px;white-space:nowrap",S(ct,"aria-live","assertive")),ct.isConnected||document.body.append(ct),t&&(ct.textContent=`${t}${Lr++%2?" ":""}`)},Ir=(t,e,n="")=>{var o,i;const s={bubbles:!0,composed:!0,data:e,inputType:n},a=HTMLInputElement.prototype;t.dispatchEvent(new InputEvent("beforeinput",s)),(i=(o=Object.getOwnPropertyDescriptor(a,"value"))==null?void 0:o.set)==null||i.call(t,e),t.dispatchEvent(new InputEvent("input",s)),t.dispatchEvent(new Event("change",{bubbles:!0}))},Ke=!1,Xe=t=>(t?.type==="mouseup"&&(Ke=!1),t?.type==="mousedown"&&(Ke=!0,At(document,"mouseup",Xe,{once:!0})),Ke),Qe="disabled",Lt="selected",Mr=class extends vi{static get observedAttributes(){return[Qe,Lt]}connectedCallback(){qe||(this.tabIndex=-1),this.hasAttribute("role")||S(this,"role","option"),this.attributeChangedCallback()}attributeChangedCallback(){S(this,"aria-disabled",`${this.disabled}`),S(this,"aria-selected",`${this.selected}`)}get defaultSelected(){return this[Lt]}set defaultSelected(t){this[Lt]=t}get disabled(){return S(this,Qe)!==null}set disabled(t){S(this,Qe,t?"":null)}get form(){return this.closest("form")}get index(){var t;return[...((t=this.parentElement)==null?void 0:t.options)||[this]].indexOf(this)}get label(){var t;return(t=S(this,"label"))!=null?t:this.text}set label(t){S(this,"label",t)}get selected(){return S(this,Lt)!==null}set selected(t){S(this,Lt,t?"":null)}get text(){var t;return((t=this.textContent)==null?void 0:t.trim())||""}set text(t){this.textContent=t}get value(){var t;return(t=S(this,"value"))!=null?t:this.text}set value(t){S(this,"value",t)}};wi.define("u-option",Mr);var Or=`${$r}
319
386
  ::slotted(u-option) { display: block; cursor: pointer }
320
- ::slotted(u-option:focus) { ${Sa} }
387
+ ::slotted(u-option:focus) { ${Cr} }
321
388
  ::slotted(u-option[aria-hidden="true"]),
322
389
  ::slotted(u-option[disabled]),
323
- ::slotted(u-option[hidden]) { display: none !important }`,xi,Ei=0,Ia=ze||le,Si="click,focusout,input,keydown,mousedown,mouseup",Ti="focus,focusin,blur,focusout",ue={singular:"%d hit",plural:"%d hits"},$i=class extends gi{constructor(){super(),this._texts=wa({},ue),this._value="",Ta(this,La)}static get observedAttributes(){return["id",...Object.keys(ue).map(t=>`data-sr-${t}`)]}connectedCallback(){this.hidden=!0,this._root=_i(this),E(this,"role","listbox"),E(this,"tabindex","-1"),At(this._root,"focusin",this),At(this._root,"focus",this,!0),We(this,{attributeFilter:["disabled","hidden","label","value"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),setTimeout(()=>this.attributeChangedCallback())}disconnectedCallback(){ce(this._root||this,"focus",this,!0),ce(this._root||this,"focusin",this),We(this,!1),Je(this),this._root=void 0}attributeChangedCallback(t,e,n){const o=t?.split("data-sr-")[1],i=`input[list="${this.id}"]`;if(ue[o])this._texts[o]=n||ue[o];else if(this._root){this._input&&Ze(this,this._input);for(const s of this._root.querySelectorAll(i))Ze(this,s)}}handleEvent(t){const{target:e,type:n}=t;t.defaultPrevented||(n==="click"&&Ra(this,t),(n==="focus"||n==="focusin")&&Ma(this,t),(n==="blur"||n==="focusout")&&Oa(this,t),n==="keydown"&&Pa(this,t),n==="mousedown"&&this.contains(e)&&Xe(t),(n==="mutation"||n==="input")&&(clearTimeout(Ei),Ei=setTimeout(Ai,0,this,t)))}get options(){return this.getElementsByTagName("u-option")}},Ci=t=>t?.disabled||t?.readOnly||!1,It=(t,e)=>{var n,o,i;if(t.hidden!==e)return;t.hidden=Ci(t?._input)||!e,(n=We(t))==null||n.takeRecords();const s=t.isConnected&&t.popover&&((o=t._input)==null?void 0:o.isConnected)&&((i=t._input)==null?void 0:i.popoverTargetElement)===t;t._input&&Ze(t,t._input,e),s&&E(t,"popover","manual"),s&&t.togglePopover(e),e&&Ai(t)},Je=t=>{t._input&&(ce(t._input||t,Ti,t),ce(t._root||t,Si,t),It(t,!1),t._input=void 0)},Ze=(t,e,n=!1)=>{t.popover&&E(e,"popovertarget",Ge(t)),At(e,Ti,t,!0),E(e,"aria-autocomplete","list"),E(e,"aria-controls",Ge(t)),E(e,"aria-expanded",`${!Ia||n}`),E(e,"autocomplete","off"),E(e,"role",Ci(e)?null:"combobox")},Ma=(t,e)=>{var n;const o=e.target instanceof HTMLInputElement;o&&e.isTrusted&&e.stopImmediatePropagation(),t._input!==e.target&&o&&e.target.list===t&&(t._input&&Je(t),t._input=e.target,t._input.dispatchEvent(new FocusEvent("focus")),t._input.dispatchEvent(new FocusEvent("focusin",{bubbles:!0})),E(t,xa,Ge((n=t._input.labels)==null?void 0:n[0])),At(t._root||t,Si,t),It(t,E(t._input,"inputmode")!=="none"),wi())},Oa=(t,e)=>{!le&&!Xe()&&t._input&&setTimeout(ki,0,t),e.target===t._input&&e.isTrusted&&e.stopImmediatePropagation()},ki=t=>{var e;const n=((e=t._root)==null?void 0:e.activeElement)||null,o=t._input;o&&o!==n&&!t.contains(n)&&(o.dispatchEvent(new FocusEvent("blur",{relatedTarget:n})),o.dispatchEvent(new FocusEvent("focusout",{bubbles:!0,relatedTarget:n})),Je(t))},Ra=(t,{target:e})=>{var n;if(!t._input||t._input===e)return It(t,!0);for(const o of t.options)if(o.contains(e))return E(t,"aria-multiselectable")!=="true"&&((n=t._input)==null||n.focus(),It(t,!1)),ka(t._input,o.value);le&&ki(t)},Pa=(t,e)=>{var n;const{key:o,target:i,altKey:s,ctrlKey:r,shiftKey:a,metaKey:c}=e,l=o==="Escape"||o==="Esc";if(s||r||c||a||o==="Tab")return;l&&!t.hidden&&e?.preventDefault(),It(t,!l);const d=[...t.options].filter(p=>E(p,"aria-hidden")!=="true"&&p.offsetHeight),u=d.indexOf(i);let m=-1;if(o==="ArrowDown"&&(m=(u+1)%d.length),o==="ArrowUp"&&(m=(~u?u:d.length)-1),~u&&((o==="Home"||o==="PageUp")&&(m=0),(o==="End"||o==="PageDown")&&(m=d.length-1),o==="Enter"))return d[u].click(),e.preventDefault();if(d[m])for(const p of d)p.tabIndex=-1;d[m]&&e.preventDefault(),(n=d[m]||t._input)==null||n.focus(),!d[m]&&o==="ArrowUp"&&setTimeout(()=>{var p;return(p=t._input)==null?void 0:p.setSelectionRange(999,999)})},Ai=(t,e)=>{const{_texts:n,_root:o,_input:i,options:s}=t,r=i?.value.toLowerCase().trim()||"",a=!t.hasAttribute("data-nofilter"),c=[],l=[];for(const u of s)(u.disabled||u.hidden||a&&!u.label.toLowerCase().includes(r)?c:l).push(u);for(const u of c)E(u,"aria-hidden","true");for(const u of l)E(u,"aria-hidden","false");const d=l.length;clearTimeout(xi),e?.type==="input"&&r!==t._value&&(xi=setTimeout(()=>{const u=`${!d&&t.innerText.trim()||`${n[d===1?"singular":"plural"]}`.replace("%d",`${d}`)}`;!t.hidden&&o?.activeElement===i&&wi(u),t._value=r},1e3)),ze&&l.map((u,m)=>E(u,"title",`${m+1}/${d}`))};kt&&Object.defineProperty(HTMLInputElement.prototype,"list",{configurable:!0,enumerable:!0,get(){return _i(this).getElementById(E(this,"list")||"")}}),yi.define("u-datalist",$i);const tn=T.field.split(" ")[0],Li=T.validation.split(" "),Da=Li[0],F=(t,e)=>t.getPropertyValue(`--mtds-text-${e}`)?.slice(1,-1)||"";function Ii(t,e){for(const n of t)if(n.isConnected){const o=[],i=[],s=[];let r=null,a=null,c=!0;for(const l of n.getElementsByTagName("*"))l instanceof HTMLLabelElement?o.push(l):l instanceof ye?r=l:He(l)&&!l.hidden?a=l:l.hasAttribute("data-description")?i.push(l):l.classList.contains(Da)?(c=f(l,"data-color")==="success"||!l.clientHeight,s.push(l),i.unshift(l)):l instanceof HTMLParagraphElement&&(i.some(d=>d.contains(l))||i.push(l));if(a){for(const l of o)l.htmlFor=re(a);if(e&&f(n,"data-validation")==="form"){c=a.matches(":valid");for(const l of s)f(l,"hidden",c?"":null)}Na(r),Oi(a),Mi(a),f(a,"aria-describedby",i.map(re).join(" ")||null),f(a,"aria-invalid",`${!c}`)}}}function Mi(t){t instanceof HTMLTextAreaElement&&(t.style.setProperty("--mtds-textarea-height","auto"),t.style.setProperty("--mtds-textarea-height",`${t.scrollHeight}px`))}function Na(t){const{control:e,list:n}=t||{};if(t&&n&&!t.hasAttribute("data-sr-added")){const o=window.getComputedStyle(t);f(t,"data-sr-added",F(o,"combobox-added")),f(t,"data-sr-empty",F(o,"combobox-empty")),f(t,"data-sr-found",F(o,"combobox-found")),f(t,"data-sr-invalid",F(o,"combobox-invalid")),f(t,"data-sr-of",F(o,"combobox-of")),f(t,"data-sr-remove",F(o,"combobox-remove")),f(t,"data-sr-removed",F(o,"combobox-removed")),f(n,"data-sr-plural",F(o,"datalist-plural")),f(n,"data-sr-singular",F(o,"datalist-singular"))}n&&e&&!n.hasAttribute("popover")&&(f(n,"popover","manual"),f(e,"popovertarget",re(n)))}function Oi(t){const e=t?.nextElementSibling,n=e&&f(e,"data-count");if(e&&n){const o=Number(n)-t.value.length,i=o<0,s=f(e,"aria-live")==="polite",r=window.getComputedStyle(e||t),a=F(r,"count-over"),c=F(r,"count-under");if(s!==i){f(e,"aria-live",i?"polite":"off");for(const l of Li)e.classList.toggle(l,i)}e.textContent=(i?a:c).replace("%d",`${Math.abs(o)}`)}}function Ha({target:t,newState:e}){if(t instanceof $i){const o=t.getRootNode()?.querySelector(`[popovertarget="${t.id}"]`);e==="closed"?at(t,!1):o&&at(t,o,{contain({availableHeight:i}){t.style.width=`${o.clientWidth}px`,t.style.maxHeight=`${Math.max(50,i)}px`}})}}function Ba(t){He(t.target)&&(Oi(t.target),Mi(t.target))}function ja(t){const e=t.target?.closest?.(`.${tn}`);t.type==="invalid"&&e&&t.preventDefault(),Ii(document.getElementsByClassName(tn),!0)}D(()=>{yt(document.documentElement,tn,Ii),$(document,"input",Ba,P),$(document,"invalid,submit",ja,!0),$(document,"toggle",Ha,P)});const Fa=T.fieldset.split(" ")[0],Ua=T.validation.split(" ")[0],Ri="aria-describedby",qa="aria-invalid";function Va(t){setTimeout(()=>{for(const e of t)if(e.isConnected){const n=[];let o=null,i=!0;for(const s of e.getElementsByTagName("*"))s.classList.contains(Ua)?(i=f(s,"data-color")==="success"||!s.clientHeight,o=re(s)):He(s)&&n.push(s);for(const s of n){const r=f(s,Ri)?.replace(o||"#","");f(s,Ri,`${o||""} ${r||""}`.trim()),f(s,qa,`${!i}`)}}})}D(()=>yt(document.documentElement,Fa,Va));const za=T.logo.split(" ")[0];function Wa([t]){if(t?.isConnected&&t?.firstElementChild instanceof SVGSVGElement){for(const a of document.head.querySelectorAll("link[rel~='icon']"))a.setAttribute("rel","disabled");const e=t.firstElementChild,n=t?.hasAttribute("data-env"),o=window.getComputedStyle(e),i=o.getPropertyValue("color"),s=o.getPropertyValue("--mtds-logo-color"),r=e.outerHTML.replace(/\n+/g," ").replace(/(fill|width|height|xmlns)="[^"]+"/gi,"").replace("<svg",`<svg width="40" height="40" fill="${i}"`);document.head.appendChild(C("link",{href:`data:image/svg+xml,${encodeURIComponent(`<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 55 55'><rect fill='${n?"none":s}' width='51' height='51' x='2' y='2' stroke='${i}' stroke-dasharray='0.09 6.38' stroke-linecap='round' stroke-opacity='${n?.6:0}' stroke-width='2.3' rx='25.5'/><g transform="translate(7.5 7.5)">${r}</g></svg>`)}`,rel:"icon"}))}}D(()=>yt(document.documentElement,za,Wa));const fe=T.popover.split(" ")[0],Pi="_mtds-popover-auto";function Ga({target:t,newState:e}){if(t instanceof HTMLElement&&t.classList.contains(fe)){const n=document.querySelector(`[popovertarget="${t.id}"]`);e==="closed"?at(t,!1):n&&at(t,n,{contain:f(t,"data-overscroll")==="contain"&&(({availableHeight:o})=>{t.style.maxHeight=`${Math.max(50,o)}px`})})}}function Ya({target:t,newState:e}){e==="open"&&t instanceof HTMLElement&&t.classList.contains(fe)&&f(t,"popover")!=="manual"&&(t.classList.add(Pi),f(t,"popover","manual"))}function Ka(t){const e=t.target?.closest?.("a,button"),n=e&&f(e,"popovertarget"),o=n?document.getElementById(n):e?.closest(`.${fe}`);for(const i of document.getElementsByClassName(Pi))!i.contains(t.target)&&o!==i&&i.hidePopover();if(o?.classList.contains(fe)&&e){const i=f(e,"popovertargetaction"),s=i==="show"||(i==="hide"?!1:void 0);if(e instanceof HTMLButtonElement&&!i&&o.contains(e))return;if(o instanceof HTMLElement&&o.isConnected){if(t.preventDefault(),o.hasAttribute("popover"))return o.togglePopover(s);console.error(`Element "${o.id}" is missing "popover" attribute`)}}}D(()=>{$(document,"click",Ka),$(document,"toggle",Ga,P),$(document,"beforetoggle",Ya,P)});const Xa=T.table.split(" ")[0],Qa='a,button,label,input,select,textarea,[role="button"]';function Ja(t){for(const e of t){const n=Array.from(e.tHead?.rows[0]?.cells||[],o=>o.innerText.trim());for(const o of e.tBodies)for(const i of o.rows)for(const s of i.cells)f(s,"data-th",n[s.cellIndex]||":empty")}}function Za({target:t}){if(!(t instanceof Element))return;const n=t.closest("tr")?.querySelector('[data-command="row"]');n&&!t.closest(Qa)&&n.click?.()}D(()=>{yt(document.documentElement,Xa,Ja),$(document,"click",Za)});const Di=T.toast.split(" ")[0],pe="data-sort";function tl({animationName:t,target:e}){const n=e;if(t===T._toastTimeout&&n.close(),t!==T._toastOpen)return;const o=Number(f(n,"data-timeout"));n.style.setProperty("--mtdsc-toast-timeout",o?`${o}ms`:null),n.hasAttribute(pe)||f(n,pe,`${Date.now()}`),f(n,"tabindex","0"),[...document.querySelectorAll(`.${Di}[open]`)].sort((i,s)=>Number(f(s,pe))-Number(f(i,pe))).reduce((i,s)=>(s.style.translate=`0 ${s===e?0:i}px`,i+s.offsetHeight+5),0)}function el({target:t,clientX:e,clientY:n}){if(t instanceof HTMLDialogElement&&t.classList.contains(Di)&&f(t,"data-closedby")!=="none"){const o=t.getBoundingClientRect(),i=window.getComputedStyle(t),s=window.getComputedStyle(t,"::after"),r=o.top+Number.parseInt(i.paddingTop,10),a=r+Number.parseInt(s.height,10),c=o.right-Number.parseInt(i.paddingRight,10),l=c-Number.parseInt(s.width,10);r<=n&&n<=a&&l<=e&&e<=c&&t.close()}}D(()=>{$(document,"animationstart",tl),$(document,"click",el)});const nl=`.${T.togglegroup.split(" ")[0]}`;function ol(t){const{key:e,target:n}=t,o=n instanceof HTMLInputElement&&n.closest(nl);if(o&&(e==="Enter"&&n.click(),e?.startsWith("Arrow"))){t.preventDefault();const i=o.getElementsByTagName("input"),s=[...i].indexOf(n),r=e.match(/Arrow(Right|Down)/)?1:-1;i[(i.length+s+r)%i.length]?.focus()}}D(()=>$(document,"keydown",ol));const Ni="aria-describedby",Hi="Escape",me="aria-labelledby",il="--mtds-tooltip-position",sl=300,Bi="mtds-tooltip",U=rt?document.getElementById(Bi)||C("div",{class:T._tooltip,id:Bi,popover:"manual"}):null;let tt=null,ji=Number.NEGATIVE_INFINITY,Fi=0;function en({target:t,type:e,key:n}){if(e==="keydown"&&n!==Hi)return;const o=ji+sl-Date.now();clearTimeout(Fi),Fi=setTimeout(rl,Math.max(o,0),n===Hi?null:t)}function rl(t){if(ji=Date.now(),!U||t===U)return;U?.isConnected||document.body.append(U);let e=t?.closest?.("[data-tooltip]")||null;if(e===tt)return;const n=e&&f(e,"data-tooltip")||"",o=e&&f(e,"data-tooltip-position")||window.getComputedStyle(e||document.body).getPropertyValue(il)?.trim()||"top";(!n||n==="false"||n==="true"||o==="none")&&(e=null),e&&(U.textContent=n);const s=tt&&f(tt,me)===U?.id,r=(e instanceof HTMLElement?e.innerText:e?.textContent)?.trim()||e?.hasAttribute(me)||e?.hasAttribute("aria-label");tt?.removeAttribute(s?me:Ni),at(U,!1),tt=e,tt&&f(tt,r?Ni:me,U?.id),tt?.isConnected&&U.hidePopover(),U.togglePopover(!!e),at(U,e||!1,{placement:o,middleware:[Yo(),Go({padding:10})]})}D(()=>{$(document,"blur,focus,mouseout,mouseover",en,P),$(window,"keydown",en,P),$(window,"blur",en,P)});var Ui=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",qi;Ui&&/^Mac/i.test(((qi=navigator.userAgentData)==null?void 0:qi.platform)||navigator.platform);var al=":host(:not([hidden])) { display: block }",Vi=typeof HTMLElement>"u"?class{}:HTMLElement;function K(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var zi=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Wi=(t,...e)=>zi("add",t,e),Gi=(t,...e)=>zi("remove",t,e),ll=t=>{const e="key"in t&&(t.key===" "||t.key==="Enter");return e&&t.preventDefault(),e&&t.target instanceof HTMLElement&&t.target.click(),e},cl=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},nn=(t,e,n)=>{const o=document.createElement(t);if(e&&(o.textContent=e),n)for(const[i,s]of Object.entries(n))K(o,i,s);return o},Yi={define:(t,e)=>!Ui||window.customElements.get(t)||window.customElements.define(t,e)},dl=`${al}
390
+ ::slotted(u-option[hidden]) { display: none !important }`,Ei,Si=0,Rr=qe||le,Ti="click,focusout,input,keydown,mousedown,mouseup",$i="focus,focusin,blur,focusout",ue={singular:"%d hit",plural:"%d hits"},Ci=class extends vi{constructor(){super(),this._texts=Sr({},ue),this._value="",kr(this,Or)}static get observedAttributes(){return["id",...Object.keys(ue).map(t=>`data-sr-${t}`)]}connectedCallback(){this.hidden=!0,this._root=yi(this),S(this,"role","listbox"),S(this,"tabindex","-1"),At(this._root,"focusin",this),At(this._root,"focus",this,!0),We(this,{attributeFilter:["disabled","hidden","label","value"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),setTimeout(()=>this.attributeChangedCallback())}disconnectedCallback(){ce(this._root||this,"focus",this,!0),ce(this._root||this,"focusin",this),We(this,!1),Je(this),this._root=void 0}attributeChangedCallback(t,e,n){const o=t?.split("data-sr-")[1],i=`input[list="${this.id}"]`;if(ue[o])this._texts[o]=n||ue[o];else if(this._root){this._input&&Ze(this,this._input);for(const s of this._root.querySelectorAll(i))Ze(this,s)}}handleEvent(t){const{target:e,type:n}=t;t.defaultPrevented||(n==="click"&&Nr(this,t),(n==="focus"||n==="focusin")&&Pr(this,t),(n==="blur"||n==="focusout")&&Dr(this,t),n==="keydown"&&Hr(this,t),n==="mousedown"&&this.contains(e)&&Xe(t),(n==="mutation"||n==="input")&&(clearTimeout(Si),Si=setTimeout(Li,0,this,t)))}get options(){return this.getElementsByTagName("u-option")}},ki=t=>t?.disabled||t?.readOnly||!1,It=(t,e)=>{var n,o,i;if(t.hidden!==e)return;t.hidden=ki(t?._input)||!e,(n=We(t))==null||n.takeRecords();const s=t.isConnected&&t.popover&&((o=t._input)==null?void 0:o.isConnected)&&((i=t._input)==null?void 0:i.popoverTargetElement)===t;t._input&&Ze(t,t._input,e),s&&S(t,"popover","manual"),s&&t.togglePopover(e),e&&Li(t)},Je=t=>{t._input&&(ce(t._input||t,$i,t),ce(t._root||t,Ti,t),It(t,!1),t._input=void 0)},Ze=(t,e,n=!1)=>{t.popover&&S(e,"popovertarget",Ge(t)),At(e,$i,t,!0),S(e,"aria-autocomplete","list"),S(e,"aria-controls",Ge(t)),S(e,"aria-expanded",`${!Rr||n}`),S(e,"autocomplete","off"),S(e,"role",ki(e)?null:"combobox")},Pr=(t,e)=>{var n;const o=e.target instanceof HTMLInputElement;o&&e.isTrusted&&e.stopImmediatePropagation(),t._input!==e.target&&o&&e.target.list===t&&(t._input&&Je(t),t._input=e.target,t._input.dispatchEvent(new FocusEvent("focus")),t._input.dispatchEvent(new FocusEvent("focusin",{bubbles:!0})),S(t,Tr,Ge((n=t._input.labels)==null?void 0:n[0])),At(t._root||t,Ti,t),It(t,S(t._input,"inputmode")!=="none"),xi())},Dr=(t,e)=>{!le&&!Xe()&&t._input&&setTimeout(Ai,0,t),e.target===t._input&&e.isTrusted&&e.stopImmediatePropagation()},Ai=t=>{var e;const n=((e=t._root)==null?void 0:e.activeElement)||null,o=t._input;o&&o!==n&&!t.contains(n)&&(o.dispatchEvent(new FocusEvent("blur",{relatedTarget:n})),o.dispatchEvent(new FocusEvent("focusout",{bubbles:!0,relatedTarget:n})),Je(t))},Nr=(t,{target:e})=>{var n;if(!t._input||t._input===e)return It(t,!0);for(const o of t.options)if(o.contains(e))return S(t,"aria-multiselectable")!=="true"&&((n=t._input)==null||n.focus(),It(t,!1)),Ir(t._input,o.value);le&&Ai(t)},Hr=(t,e)=>{var n;const{key:o,target:i,altKey:s,ctrlKey:a,shiftKey:r,metaKey:c}=e,l=o==="Escape"||o==="Esc";if(s||a||c||r||o==="Tab")return;l&&!t.hidden&&e?.preventDefault(),It(t,!l);const d=[...t.options].filter(h=>S(h,"aria-hidden")!=="true"&&h.offsetHeight),u=d.indexOf(i);let p=-1;if(o==="ArrowDown"&&(p=(u+1)%d.length),o==="ArrowUp"&&(p=(~u?u:d.length)-1),~u&&((o==="Home"||o==="PageUp")&&(p=0),(o==="End"||o==="PageDown")&&(p=d.length-1),o==="Enter"))return d[u].click(),e.preventDefault();if(d[p])for(const h of d)h.tabIndex=-1;d[p]&&e.preventDefault(),(n=d[p]||t._input)==null||n.focus(),!d[p]&&o==="ArrowUp"&&setTimeout(()=>{var h;return(h=t._input)==null?void 0:h.setSelectionRange(999,999)})},Li=(t,e)=>{const{_texts:n,_root:o,_input:i,options:s}=t,a=i?.value.toLowerCase().trim()||"",r=!t.hasAttribute("data-nofilter"),c=[],l=[];for(const u of s)(u.disabled||u.hidden||r&&!u.label.toLowerCase().includes(a)?c:l).push(u);for(const u of c)S(u,"aria-hidden","true");for(const u of l)S(u,"aria-hidden","false");const d=l.length;clearTimeout(Ei),e?.type==="input"&&a!==t._value&&(Ei=setTimeout(()=>{const u=`${!d&&t.innerText.trim()||`${n[d===1?"singular":"plural"]}`.replace("%d",`${d}`)}`;!t.hidden&&o?.activeElement===i&&xi(u),t._value=a},1e3)),qe&&l.map((u,p)=>S(u,"title",`${p+1}/${d}`))};kt&&Object.defineProperty(HTMLInputElement.prototype,"list",{configurable:!0,enumerable:!0,get(){return yi(this).getElementById(S(this,"list")||"")}}),wi.define("u-datalist",Ci);const tn=T.field.split(" ")[0],Ii=T.validation.split(" "),Br=Ii[0],F=(t,e)=>t.getPropertyValue(`--mtds-text-${e}`)?.slice(1,-1)||"";function Mi(t,e){for(const n of t)if(n.isConnected){const o=[],i=[],s=[];let a=null,r=null,c=!0;for(const l of n.getElementsByTagName("*"))l instanceof HTMLLabelElement?o.push(l):l instanceof ye?a=l:He(l)&&!l.hidden?r=l:l.hasAttribute("data-description")?i.push(l):l.classList.contains(Br)?(c=f(l,"data-color")==="success"||!l.clientHeight,s.push(l),i.unshift(l)):l instanceof HTMLParagraphElement&&(i.some(d=>d.contains(l))||i.push(l));if(r){for(const l of o)l.htmlFor=ae(r);if(e&&f(n,"data-validation")==="form"){c=r.matches(":valid");for(const l of s)f(l,"hidden",c?"":null)}jr(a),Ri(r),Oi(r),f(r,"aria-describedby",i.map(ae).join(" ")||null),f(r,"aria-invalid",`${!c}`)}}}function Oi(t){t instanceof HTMLTextAreaElement&&(t.style.setProperty("--mtds-textarea-height","auto"),t.style.setProperty("--mtds-textarea-height",`${t.scrollHeight}px`))}function jr(t){const{control:e,list:n}=t||{};if(t&&n&&!t.hasAttribute("data-sr-added")){const o=window.getComputedStyle(t);f(t,"data-sr-added",F(o,"combobox-added")),f(t,"data-sr-empty",F(o,"combobox-empty")),f(t,"data-sr-found",F(o,"combobox-found")),f(t,"data-sr-invalid",F(o,"combobox-invalid")),f(t,"data-sr-of",F(o,"combobox-of")),f(t,"data-sr-remove",F(o,"combobox-remove")),f(t,"data-sr-removed",F(o,"combobox-removed")),f(n,"data-sr-plural",F(o,"datalist-plural")),f(n,"data-sr-singular",F(o,"datalist-singular"))}n&&e&&!n.hasAttribute("popover")&&(f(n,"popover","manual"),f(e,"popovertarget",ae(n)))}function Ri(t){const e=t?.nextElementSibling,n=e&&f(e,"data-count");if(e&&n){const o=Number(n)-t.value.length,i=o<0,s=f(e,"aria-live")==="polite",a=window.getComputedStyle(e||t),r=F(a,"count-over"),c=F(a,"count-under");if(s!==i){f(e,"aria-live",i?"polite":"off");for(const l of Ii)e.classList.toggle(l,i)}e.textContent=(i?r:c).replace("%d",`${Math.abs(o)}`)}}function Fr({target:t,newState:e}){if(t instanceof Ci){const o=t.getRootNode()?.querySelector(`[popovertarget="${t.id}"]`);e==="closed"?rt(t,!1):o&&rt(t,o,{contain({availableHeight:i}){t.style.width=`${o.clientWidth}px`,t.style.maxHeight=`${Math.max(50,i)}px`}})}}function Ur(t){He(t.target)&&(Ri(t.target),Oi(t.target))}function zr(t){const e=t.target?.closest?.(`.${tn}`);t.type==="invalid"&&e&&t.preventDefault(),Mi(document.getElementsByClassName(tn),!0)}N(()=>{yt(document.documentElement,tn,Mi),$(document,"input",Ur,D),$(document,"invalid,submit",zr,!0),$(document,"toggle",Fr,D)});const Vr=T.fieldset.split(" ")[0],qr=T.validation.split(" ")[0],Pi="aria-describedby",Wr="aria-invalid";function Gr(t){setTimeout(()=>{for(const e of t)if(e.isConnected){const n=[];let o=null,i=!0;for(const s of e.getElementsByTagName("*"))s.classList.contains(qr)?(i=f(s,"data-color")==="success"||!s.clientHeight,o=ae(s)):He(s)&&n.push(s);for(const s of n){const a=f(s,Pi)?.replace(o||"#","");f(s,Pi,`${o||""} ${a||""}`.trim()),f(s,Wr,`${!i}`)}}})}N(()=>yt(document.documentElement,Vr,Gr));const Yr=T.logo.split(" ")[0];function Kr([t]){if(t?.isConnected&&t?.firstElementChild instanceof SVGSVGElement){for(const r of document.head.querySelectorAll("link[rel~='icon']"))r.setAttribute("rel","disabled");const e=t.firstElementChild,n=t?.hasAttribute("data-env"),o=window.getComputedStyle(e),i=o.getPropertyValue("color"),s=o.getPropertyValue("--mtds-logo-color"),a=e.outerHTML.replace(/\n+/g," ").replace(/(fill|width|height|xmlns)="[^"]+"/gi,"").replace("<svg",`<svg width="40" height="40" fill="${i}"`);document.head.appendChild(C("link",{href:`data:image/svg+xml,${encodeURIComponent(`<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 55 55'><rect fill='${n?"none":s}' width='51' height='51' x='2' y='2' stroke='${i}' stroke-dasharray='0.09 6.38' stroke-linecap='round' stroke-opacity='${n?.6:0}' stroke-width='2.3' rx='25.5'/><g transform="translate(7.5 7.5)">${a}</g></svg>`)}`,rel:"icon"}))}}N(()=>yt(document.documentElement,Yr,Kr));const fe=T.popover.split(" ")[0],Di="_mtds-popover-auto";function Xr({target:t,newState:e}){if(t instanceof HTMLElement&&t.classList.contains(fe)){const n=document.querySelector(`[popovertarget="${t.id}"]`);e==="closed"?rt(t,!1):n&&rt(t,n,{contain:f(t,"data-overscroll")==="contain"&&(({availableHeight:o})=>{t.style.maxHeight=`${Math.max(50,o)}px`})})}}function Qr({target:t,newState:e}){e==="open"&&t instanceof HTMLElement&&t.classList.contains(fe)&&f(t,"popover")!=="manual"&&(t.classList.add(Di),f(t,"popover","manual"))}function Jr(t){const e=t.target?.closest?.("a,button"),n=e&&f(e,"popovertarget"),o=n?document.getElementById(n):e?.closest(`.${fe}`);for(const i of document.getElementsByClassName(Di))!i.contains(t.target)&&o!==i&&i.hidePopover();if(o?.classList.contains(fe)&&e){const i=f(e,"popovertargetaction"),s=i==="show"||(i==="hide"?!1:void 0),a=e instanceof HTMLButtonElement;if(a&&!i&&o.contains(e))return;if(o instanceof HTMLElement&&o.isConnected){if(a&&n)return;if(o.hasAttribute("popover"))return o.togglePopover(s);console.error(`Element "${o.id}" is missing "popover" attribute`)}}}N(()=>{$(document,"click",Jr),$(document,"toggle",Xr,D),$(document,"beforetoggle",Qr,D)});const Zr=T.table.split(" ")[0],tl='a,button,label,input,select,textarea,[role="button"]';function el(t){for(const e of t){const n=Array.from(e.tHead?.rows[0]?.cells||[],o=>o.innerText.trim());for(const o of e.tBodies)for(const i of o.rows)for(const s of i.cells)f(s,"data-th",n[s.cellIndex]||":empty")}}function nl({target:t}){if(!(t instanceof Element))return;const n=t.closest("tr")?.querySelector('[data-command="row"]');n&&!t.closest(tl)&&n.click?.()}N(()=>{yt(document.documentElement,Zr,el),$(document,"click",nl)});const Ni=T.toast.split(" ")[0],pe="data-sort";function ol({animationName:t,target:e}){const n=e;if(t===T._toastTimeout&&n.close(),t!==T._toastOpen)return;const o=Number(f(n,"data-timeout"));n.style.setProperty("--mtdsc-toast-timeout",o?`${o}ms`:null),n.hasAttribute(pe)||f(n,pe,`${Date.now()}`),f(n,"tabindex","0"),[...document.querySelectorAll(`.${Ni}[open]`)].sort((i,s)=>Number(f(s,pe))-Number(f(i,pe))).reduce((i,s)=>(s.style.translate=`0 ${s===e?0:i}px`,i+s.offsetHeight+5),0)}function il({target:t,clientX:e,clientY:n}){if(t instanceof HTMLDialogElement&&t.classList.contains(Ni)&&f(t,"data-closedby")!=="none"){const o=t.getBoundingClientRect(),i=window.getComputedStyle(t),s=window.getComputedStyle(t,"::after"),a=o.top+Number.parseInt(i.paddingTop,10),r=a+Number.parseInt(s.height,10),c=o.right-Number.parseInt(i.paddingRight,10),l=c-Number.parseInt(s.width,10);a<=n&&n<=r&&l<=e&&e<=c&&t.close()}}N(()=>{$(document,"animationstart",ol),$(document,"click",il)});const sl=`.${T.togglegroup.split(" ")[0]}`;function al(t){const{key:e,target:n}=t,o=n instanceof HTMLInputElement&&n.closest(sl);if(o&&(e==="Enter"&&n.click(),e?.startsWith("Arrow"))){t.preventDefault();const i=o.getElementsByTagName("input"),s=[...i].indexOf(n),a=e.match(/Arrow(Right|Down)/)?1:-1;i[(i.length+s+a)%i.length]?.focus()}}N(()=>$(document,"keydown",al));const Hi="aria-describedby",Bi="Escape",he="aria-labelledby",rl="--mtds-tooltip-position",ll=300,ji="mtds-tooltip",U=at?document.getElementById(ji)||C("div",{class:T._tooltip,id:ji,popover:"manual"}):null;let tt=null,Fi=Number.NEGATIVE_INFINITY,Ui=0;function en({target:t,type:e,key:n}){if(e==="keydown"&&n!==Bi)return;const o=Fi+ll-Date.now();clearTimeout(Ui),Ui=setTimeout(cl,Math.max(o,0),n===Bi?null:t)}function cl(t){if(Fi=Date.now(),!U||t===U)return;U?.isConnected||document.body.append(U);let e=t?.closest?.("[data-tooltip]")||null;if(e===tt)return;const n=e&&f(e,"data-tooltip")||"",o=e&&f(e,"data-tooltip-position")||window.getComputedStyle(e||document.body).getPropertyValue(rl)?.trim()||"top";(!n||n==="false"||n==="true"||o==="none")&&(e=null),e&&(U.textContent=n);const s=tt&&f(tt,he)===U?.id,a=(e instanceof HTMLElement?e.innerText:e?.textContent)?.trim()||e?.hasAttribute(he)||e?.hasAttribute("aria-label");tt?.removeAttribute(s?he:Hi),rt(U,!1),tt=e,tt&&f(tt,a?Hi:he,U?.id),tt?.isConnected&&U.hidePopover(),U.togglePopover(!!e),rt(U,e||!1,{placement:o,middleware:[Ko(),Yo({padding:10})]})}N(()=>{$(document,"blur,focus,mouseout,mouseover",en,D),$(window,"keydown",en,D),$(window,"blur",en,D)});var zi=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",Vi;zi&&/^Mac/i.test(((Vi=navigator.userAgentData)==null?void 0:Vi.platform)||navigator.platform);var dl=":host(:not([hidden])) { display: block }",qi=typeof HTMLElement>"u"?class{}:HTMLElement;function K(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var Wi=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Gi=(t,...e)=>Wi("add",t,e),Yi=(t,...e)=>Wi("remove",t,e),ul=t=>{const e="key"in t&&(t.key===" "||t.key==="Enter");return e&&t.preventDefault(),e&&t.target instanceof HTMLElement&&t.target.click(),e},fl=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},nn=(t,e,n)=>{const o=document.createElement(t);if(e&&(o.textContent=e),n)for(const[i,s]of Object.entries(n))K(o,i,s);return o},Ki={define:(t,e)=>!zi||window.customElements.get(t)||window.customElements.define(t,e)},pl=`${dl}
324
391
  ::slotted(u-summary) { cursor: pointer; display: block }
325
392
  ::slotted(u-summary)::before { content: ''; display: inline-block; vertical-align: middle; margin-inline: .05em .3125em; border-block: .3125em solid transparent; border-inline-start: .5em solid }
326
393
  ::slotted(u-summary[aria-expanded="true"])::before { rotate: 90deg }
327
- :host > [part="details-content"]:not([hidden=""]) { display: block }`,ul=class extends Vi{constructor(){super(),this._content=null,this.shadowRoot||this.attachShadow({mode:"open"}).append(nn("slot",null,{name:"summary"}),nn("slot",null,{part:"details-content"}),nn("style",dl))}static get observedAttributes(){return["open"]}connectedCallback(){var t;this._content=(t=this.shadowRoot)==null?void 0:t.children[1],K(this,"role","group"),Wi(this._content,"beforematch",this),Wi(this,"click,keydown",this),this.attributeChangedCallback()}disconnectedCallback(){this._content&&Gi(this._content,"beforematch",this),Gi(this,"click,keydown",this),this._content=null}attributeChangedCallback(t,e,n){const o="onbeforematch"in this?"until-found":!0,i=this.open;for(const s of this.children)s.nodeName==="U-SUMMARY"&&K(s,"aria-expanded",`${i}`);if(this._content&&(K(this._content,"aria-hidden",`${!i}`),K(this._content,"tabindex",i?null:"-1"),this._content.hidden=i?!1:o),i&&this.name){const s=cl(this).querySelectorAll(`${this.nodeName}[name="${this.name}"]`);for(const r of s)r!==this&&(r.open=!1)}t==="open"&&e===null!=(n===null)&&this.dispatchEvent(new Event("toggle"))}handleEvent(t){const e=this.querySelector(":scope > u-summary"),n=e?.contains(t.target);t.defaultPrevented||(t.type==="beforematch"&&(this.open=!0),n&&t.type==="keydown"&&ll(t),n&&t.type==="click"&&(this.open=!this.open))}get open(){return this.hasAttribute("open")}set open(t){K(this,"open",t?"":null)}get name(){return K(this,"name")||""}set name(t){K(this,"name",t)}},fl=class extends Vi{connectedCallback(){K(this,"role","button"),this.slot="summary",this.tabIndex=0}};Yi.define("u-details",ul),Yi.define("u-summary",fl);var he=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",Ki=he&&/firefox/i.test(navigator.userAgent),pl=he&&/iPad|iPhone|iPod/.test(navigator.userAgent),Xi;he&&/^Mac/i.test(((Xi=navigator.userAgentData)==null?void 0:Xi.platform)||navigator.platform);var ml=typeof HTMLElement>"u"?class{}:HTMLElement;function I(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var hl=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},bl=0,gl=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++bl).toString(32)}`),t.id):"",Qi=(t,e,n)=>{const o=document.createElement(t);if(e&&(o.textContent=e),n)for(const[i,s]of Object.entries(n))I(o,i,s);return o},vl={define:(t,e)=>!he||window.customElements.get(t)||window.customElements.define(t,e)},_l=t=>{var e;const n=I(t,"aria-label")||"";return[...(((e=I(t,"aria-labelledby"))==null?void 0:e.trim().split(/\s+/))||[]).map(i=>document.getElementById(i)),...Array.from(t.labels||[])].reduce((i,s)=>{var r;return i||((r=s?.innerText)==null?void 0:r.trim())||""},n)},yl=`:host(:not([hidden])) { box-sizing: border-box; border: 1px solid; display: inline-block; height: .5em; width: 10em; overflow: hidden }
394
+ :host > [part="details-content"]:not([hidden=""]) { display: block }`,hl=class extends qi{constructor(){super(),this._content=null,this.shadowRoot||this.attachShadow({mode:"open"}).append(nn("slot",null,{name:"summary"}),nn("slot",null,{part:"details-content"}),nn("style",pl))}static get observedAttributes(){return["open"]}connectedCallback(){var t;this._content=(t=this.shadowRoot)==null?void 0:t.children[1],K(this,"role","group"),Gi(this._content,"beforematch",this),Gi(this,"click,keydown",this),this.attributeChangedCallback()}disconnectedCallback(){this._content&&Yi(this._content,"beforematch",this),Yi(this,"click,keydown",this),this._content=null}attributeChangedCallback(t,e,n){const o="onbeforematch"in this?"until-found":!0,i=this.open;for(const s of this.children)s.nodeName==="U-SUMMARY"&&K(s,"aria-expanded",`${i}`);if(this._content&&(K(this._content,"aria-hidden",`${!i}`),K(this._content,"tabindex",i?null:"-1"),this._content.hidden=i?!1:o),i&&this.name){const s=fl(this).querySelectorAll(`${this.nodeName}[name="${this.name}"]`);for(const a of s)a!==this&&(a.open=!1)}t==="open"&&e===null!=(n===null)&&this.dispatchEvent(new Event("toggle"))}handleEvent(t){const e=this.querySelector(":scope > u-summary"),n=e?.contains(t.target);t.defaultPrevented||(t.type==="beforematch"&&(this.open=!0),n&&t.type==="keydown"&&ul(t),n&&t.type==="click"&&(this.open=!this.open))}get open(){return this.hasAttribute("open")}set open(t){K(this,"open",t?"":null)}get name(){return K(this,"name")||""}set name(t){K(this,"name",t)}},ml=class extends qi{connectedCallback(){K(this,"role","button"),this.slot="summary",this.tabIndex=0}};Ki.define("u-details",hl),Ki.define("u-summary",ml);var me=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",Xi=me&&/firefox/i.test(navigator.userAgent),gl=me&&/iPad|iPhone|iPod/.test(navigator.userAgent),Qi;me&&/^Mac/i.test(((Qi=navigator.userAgentData)==null?void 0:Qi.platform)||navigator.platform);var bl=typeof HTMLElement>"u"?class{}:HTMLElement;function I(t,e,n){return n===void 0?t.getAttribute(e):(n===null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n),null)}var vl=t=>{var e;const n=((e=t.getRootNode)==null?void 0:e.call(t))||t.ownerDocument;return n instanceof Document||n instanceof ShadowRoot?n:document},_l=0,yl=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++_l).toString(32)}`),t.id):"",Ji=(t,e,n)=>{const o=document.createElement(t);if(e&&(o.textContent=e),n)for(const[i,s]of Object.entries(n))I(o,i,s);return o},wl={define:(t,e)=>!me||window.customElements.get(t)||window.customElements.define(t,e)},xl=t=>{var e;const n=I(t,"aria-label")||"";return[...(((e=I(t,"aria-labelledby"))==null?void 0:e.trim().split(/\s+/))||[]).map(i=>document.getElementById(i)),...Array.from(t.labels||[])].reduce((i,s)=>{var a;return i||((a=s?.innerText)==null?void 0:a.trim())||""},n)},El=`:host(:not([hidden])) { box-sizing: border-box; border: 1px solid; display: inline-block; height: .5em; width: 10em; overflow: hidden }
328
395
  :host::before { content: ''; display: block; height: 100%; background: currentColor; width: var(--percentage, 0%); transition: width .2s }
329
396
  :host(:not([value])) { background: linear-gradient(90deg,currentColor 25%, transparent 50%, currentColor 75%) 50%/400% }
330
397
  @media (prefers-reduced-motion: no-preference) { :host { animation: indeterminate 2s linear infinite } }
331
- @keyframes indeterminate { from { background-position-x: 100% } to { background-position-x: 0 } }`,on=!1,Ji=class extends ml{static get observedAttributes(){return["aria-label","aria-labelledby","value","max"]}constructor(){super(),this.shadowRoot||this.attachShadow({mode:"open"}).append(Qi("slot",null,{hidden:""}),Qi("style",yl))}connectedCallback(){this.attributeChangedCallback()}attributeChangedCallback(){if(on)return;on=!0;const t=pl||Ki,e=Math.max(0,Math.round(this.position*100));this.style.setProperty("--percentage",`${e}%`);let n=_l(this);if(t&&(n=`${n.replace(/\d+%$/,"")} ${e}%`),Ki)for(const o of this.labels)I(o,"aria-label",n);I(this,"aria-busy",`${this.position===-1}`),I(this,"aria-label",n.trim()),I(this,"aria-labelledby",null),I(this,"aria-valuemax","100"),I(this,"aria-valuemin","0"),I(this,"aria-valuenow",`${e}`),I(this,"role",t?"img":"progressbar"),on=!1}get labels(){const t=this.closest("label:not([for])"),e=gl(this);return t&&(t.htmlFor=e),hl(this).querySelectorAll(`label[for="${e}"]`)}get position(){return this.value===null?-1:Math.min(this.value/this.max,1)}get value(){return ts(this,"value")}set value(t){es(this,"value",t)}get max(){return ts(this,"max")||1}set max(t){es(this,"max",t)}};Ji.formAssociated=!0;var Zi=t=>!Number.isNaN(Number.parseFloat(`${t}`))&&Number.isFinite(Number(t)),ts=(t,e)=>{const n=I(t,e);return Zi(n)?Math.max(0,Number.parseFloat(n)):null},es=(t,e,n)=>{if(n===null||Zi(n))I(t,e,`${n}`);else throw new Error(`Failed to set non-numeric '${I}': '${n}'`)};return vl.define("u-progress",Ji),M.UHTMLComboboxElement=ye,M.UHTMLTabElement=$n,M.UHTMLTabListElement=Tn,M.UHTMLTabPanelElement=Cn,M.UHTMLTabsElement=Sn,M.analytics=ti,M.pagination=Jr,M.styles=Hs,M.toast=k,M.toggleAppExpanded=ii,M.version=Ns,Object.defineProperty(M,Symbol.toStringTag,{value:"Module"}),M}({});
398
+ @keyframes indeterminate { from { background-position-x: 100% } to { background-position-x: 0 } }`,on=!1,Zi=class extends bl{static get observedAttributes(){return["aria-label","aria-labelledby","value","max"]}constructor(){super(),this.shadowRoot||this.attachShadow({mode:"open"}).append(Ji("slot",null,{hidden:""}),Ji("style",El))}connectedCallback(){this.attributeChangedCallback()}attributeChangedCallback(){if(on)return;on=!0;const t=gl||Xi,e=Math.max(0,Math.round(this.position*100));this.style.setProperty("--percentage",`${e}%`);let n=xl(this);if(t&&(n=`${n.replace(/\d+%$/,"")} ${e}%`),Xi)for(const o of this.labels)I(o,"aria-label",n);I(this,"aria-busy",`${this.position===-1}`),I(this,"aria-label",n.trim()),I(this,"aria-labelledby",null),I(this,"aria-valuemax","100"),I(this,"aria-valuemin","0"),I(this,"aria-valuenow",`${e}`),I(this,"role",t?"img":"progressbar"),on=!1}get labels(){const t=this.closest("label:not([for])"),e=yl(this);return t&&(t.htmlFor=e),vl(this).querySelectorAll(`label[for="${e}"]`)}get position(){return this.value===null?-1:Math.min(this.value/this.max,1)}get value(){return es(this,"value")}set value(t){ns(this,"value",t)}get max(){return es(this,"max")||1}set max(t){ns(this,"max",t)}};Zi.formAssociated=!0;var ts=t=>!Number.isNaN(Number.parseFloat(`${t}`))&&Number.isFinite(Number(t)),es=(t,e)=>{const n=I(t,e);return ts(n)?Math.max(0,Number.parseFloat(n)):null},ns=(t,e,n)=>{if(n===null||ts(n))I(t,e,`${n}`);else throw new Error(`Failed to set non-numeric '${I}': '${n}'`)};return wl.define("u-progress",Zi),O.UHTMLComboboxElement=ye,O.UHTMLTabElement=Cn,O.UHTMLTabListElement=$n,O.UHTMLTabPanelElement=kn,O.UHTMLTabsElement=Tn,O.analytics=ei,O.pagination=tr,O.styles=js,O.toast=k,O.toggleAppExpanded=si,O.version=Bs,Object.defineProperty(O,Symbol.toStringTag,{value:"Module"}),O}({});