@mattilsynet/design 2.2.26 → 2.2.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/mtds/app/app-observer.js +1 -1
- package/mtds/app/app-toggle.js +16 -4
- package/mtds/app/app-toggle.js.map +1 -1
- package/mtds/app/app-toggle2.js +4 -16
- package/mtds/app/app-toggle2.js.map +1 -1
- package/mtds/app/app.js +1 -1
- package/mtds/atlas/atlas-element.js +2 -2
- package/mtds/atlas/atlas-element.js.map +1 -1
- package/mtds/atlas.iife.js +1 -1
- package/mtds/button/button.d.ts +2 -0
- package/mtds/button/button.js.map +1 -1
- package/mtds/button/button.stories.d.ts +1 -0
- package/mtds/chart/chart-element.js +1 -1
- package/mtds/chart/chart-element.js.map +1 -1
- package/mtds/field/field-observer.js +7 -5
- package/mtds/field/field-observer.js.map +1 -1
- package/mtds/field/field.d.ts +8 -0
- package/mtds/field/field.js +19 -8
- package/mtds/field/field.js.map +1 -1
- package/mtds/fieldset/fieldset.d.ts +14 -2
- package/mtds/fieldset/fieldset.js +15 -2
- package/mtds/fieldset/fieldset.js.map +1 -1
- package/mtds/fieldset/fieldset.stories.d.ts +1 -0
- package/mtds/index.iife.js +9 -9
- package/mtds/input/input.js +19 -3
- package/mtds/input/input.js.map +1 -1
- package/mtds/package.json.js +1 -1
- package/mtds/react.js +2 -1
- package/mtds/styles.css +69 -64
- package/mtds/togglegroup/togglegroup.d.ts +3 -8
- package/mtds/togglegroup/togglegroup.js +7 -2
- package/mtds/togglegroup/togglegroup.js.map +1 -1
- package/package.json +7 -7
|
@@ -2,7 +2,7 @@ import { jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import clsx from "clsx";
|
|
3
3
|
import { forwardRef } from "react";
|
|
4
4
|
import styles from "../styles.module.css.js";
|
|
5
|
-
const
|
|
5
|
+
const FieldsetComp = forwardRef(
|
|
6
6
|
function Fieldset2({ className, ...rest }, ref) {
|
|
7
7
|
return /* @__PURE__ */ jsx(
|
|
8
8
|
"fieldset",
|
|
@@ -14,7 +14,20 @@ const Fieldset = forwardRef(
|
|
|
14
14
|
);
|
|
15
15
|
}
|
|
16
16
|
);
|
|
17
|
+
const FieldsetLegend = forwardRef(
|
|
18
|
+
function FieldsetLegend2(rest, ref) {
|
|
19
|
+
return /* @__PURE__ */ jsx("legend", { suppressHydrationWarning: true, ref, ...rest });
|
|
20
|
+
}
|
|
21
|
+
);
|
|
22
|
+
const FieldsetDescription = forwardRef(function FieldsetDescription2(rest, ref) {
|
|
23
|
+
return /* @__PURE__ */ jsx("p", { suppressHydrationWarning: true, ref, ...rest });
|
|
24
|
+
});
|
|
25
|
+
const Fieldset = Object.assign(FieldsetComp, {
|
|
26
|
+
Legend: FieldsetLegend,
|
|
27
|
+
Description: FieldsetDescription
|
|
28
|
+
});
|
|
17
29
|
export {
|
|
18
|
-
Fieldset
|
|
30
|
+
Fieldset,
|
|
31
|
+
FieldsetComp
|
|
19
32
|
};
|
|
20
33
|
//# sourceMappingURL=fieldset.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fieldset.js","sources":["../../designsystem/fieldset/fieldset.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { forwardRef } from \"react\";\nimport styles from \"../styles.module.css\";\n\nexport type FieldsetProps = React.ComponentPropsWithoutRef<\"fieldset\"
|
|
1
|
+
{"version":3,"file":"fieldset.js","sources":["../../designsystem/fieldset/fieldset.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { forwardRef } from \"react\";\nimport styles from \"../styles.module.css\";\n\nexport type FieldsetProps = React.ComponentPropsWithoutRef<\"fieldset\"> & {\n\t\"data-validation\"?: \"form\";\n};\n\nexport const FieldsetComp = forwardRef<HTMLFieldSetElement, FieldsetProps>(\n\tfunction Fieldset({ className, ...rest }, ref) {\n\t\treturn (\n\t\t\t<fieldset\n\t\t\t\tclassName={clsx(styles.fieldset, className)}\n\t\t\t\tref={ref}\n\t\t\t\t{...rest}\n\t\t\t/>\n\t\t);\n\t},\n);\n\nexport type FieldsetLegendProps = React.ComponentPropsWithoutRef<\"legend\">;\nconst FieldsetLegend = forwardRef<HTMLLegendElement, FieldsetLegendProps>(\n\tfunction FieldsetLegend(rest, ref) {\n\t\treturn <legend suppressHydrationWarning ref={ref} {...rest} />;\n\t},\n);\n\nexport type FieldsetDescriptionProps = React.ComponentPropsWithoutRef<\"p\">;\nconst FieldsetDescription = forwardRef<\n\tHTMLParagraphElement,\n\tFieldsetDescriptionProps\n>(function FieldsetDescription(rest, ref) {\n\treturn <p suppressHydrationWarning ref={ref} {...rest} />;\n});\n\nexport const Fieldset = Object.assign(FieldsetComp, {\n\tLegend: FieldsetLegend,\n\tDescription: FieldsetDescription,\n});\n"],"names":["Fieldset","FieldsetLegend","FieldsetDescription"],"mappings":";;;;AAQO,MAAM,eAAe;AAAA,EAC3B,SAASA,UAAS,EAAE,WAAW,GAAG,KAAA,GAAQ,KAAK;AAC9C,WACC;AAAA,MAAC;AAAA,MAAA;AAAA,QACA,WAAW,KAAK,OAAO,UAAU,SAAS;AAAA,QAC1C;AAAA,QACC,GAAG;AAAA,MAAA;AAAA,IAAA;AAAA,EAGP;AACD;AAGA,MAAM,iBAAiB;AAAA,EACtB,SAASC,gBAAe,MAAM,KAAK;AAClC,+BAAQ,UAAA,EAAO,0BAAwB,MAAC,KAAW,GAAG,MAAM;AAAA,EAC7D;AACD;AAGA,MAAM,sBAAsB,WAG1B,SAASC,qBAAoB,MAAM,KAAK;AACzC,6BAAQ,KAAA,EAAE,0BAAwB,MAAC,KAAW,GAAG,MAAM;AACxD,CAAC;AAEM,MAAM,WAAW,OAAO,OAAO,cAAc;AAAA,EACnD,QAAQ;AAAA,EACR,aAAa;AACd,CAAC;"}
|
package/mtds/index.iife.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
var mtds=function(C){"use strict";var
|
|
1
|
+
var mtds=function(C){"use strict";var cs=Object.defineProperty,sn=Object.getOwnPropertySymbols,ds=Object.prototype.hasOwnProperty,us=Object.prototype.propertyIsEnumerable,an=(t,e,n)=>e in t?cs(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,fs=(t,e)=>{for(var n in e||(e={}))ds.call(e,n)&&an(t,n,e[n]);if(sn)for(var n of sn(e))us.call(e,n)&&an(t,n,e[n]);return t},wt=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",rn=wt&&/android/i.test(navigator.userAgent),ps=wt&&/firefox/i.test(navigator.userAgent),ms=wt&&/iPad|iPhone|iPod/.test(navigator.userAgent),ln;wt&&/^Mac/i.test(((ln=navigator.userAgentData)==null?void 0:ln.platform)||navigator.platform);var hs="outline: 1px dotted; outline: 5px auto Highlight; outline: 5px auto -webkit-focus-ring-color",gs=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 cn=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Dt=(t,...e)=>cn("add",t,e),bs=(t,...e)=>cn("remove",t,e),Nt=new WeakMap,he=(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)}},vs=t=>{const e="key"in t&&(t.key===" "||t.key==="Enter");return e&&t.preventDefault(),e&&t.target instanceof HTMLElement&&t.target.click(),e},ys=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},_s=0,dn=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++_s).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},ws={define:(t,e)=>!wt||window.customElements.get(t)||window.customElements.define(t,e)},xs=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,Es=0,ge=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}${Es++%2?" ":""}`)},un=(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}))},be=!1,ve=t=>(t?.type==="mouseup"&&(be=!1),t?.type==="mousedown"&&(be=!0,Dt(document,"mouseup",ve,{once:!0})),be),Ss=`: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) { ${ms} }`,fn="beforeinput,blur,focus,click,input,keydown,mousedown",pn={once:!0,passive:!0},Bt="false",Ss=fs&&!rn,$s=rn||ps,mn="".repeat(5),hn="deleteContentBackward",Ts="insertText",Ft={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 hs{constructor(){super(),this._item="",this._speak="",this._texts=us({},Ft),this._value="",this.shadowRoot||this.attachShadow({mode:"open"}).append(Ht("slot"),Ht("style",Es))}static get observedAttributes(){return Object.keys(Ft).map(t=>`data-sr-${t}`)}connectedCallback(){this._root=vs(this),Dt(this,fn,this,!0),he(this,{attributeFilter:["value","id"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),setTimeout(Ut,0,this),setTimeout(Vt,0,this)}attributeChangedCallback(t,e,n){const o=t.split("data-sr-")[1];Ft[o]&&(this._texts[o]=n||Ft[o])}disconnectedCallback(){he(this,!1),gs(this,fn,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;we(this)||(t.type==="beforeinput"&&(this._value=e?.value||""),t.type==="blur"&&ks(this),t.type==="click"&&Ls(this,t),t.type==="focus"&&Cs(this,t),t.type==="input"&&Is(this,t),t.type==="keydown"&&Os(this,t),t.type==="mousedown"&&ve(t),t.type==="mutation"&&Ut(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())||""},_e=t=>t instanceof HTMLDataElement,we=({control:t})=>t?.disabled||t?.readOnly||!1,Ut=(t,e)=>{var n;const{_focus:o,_texts:i,items:s,control:a,list:r,multiple:c}=t;if(!a||!r)return;const l=ws(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:y}of e?.detail||[]){for(const w of b)_e(w)&&p.unshift(w);for(const w of y)_e(w)&&p.push(w)}const m=c?p.length===1:p[0]===o;if(o&&m){const b=x(a,"aria-expanded"),y=x(a,"inputmode"),w=_e(o)?a:o,E=!p[0].isConnected;t._speak=`${i[E?"removed":"added"]} ${ot(p[0])}, `,($s||o===a)&&ge(t._speak),a!==w&&(x(a,"aria-expanded",null),x(a,"inputmode","none"),u=" ",a.focus()),setTimeout(()=>{var R;x(a,"aria-expanded",b),x(a,"inputmode",E?"none":y),(R=w?.focus)==null||R.call(w),x(a,"inputmode",y),t._speak="",Ss?Dt(t,"blur",()=>Ut(t),pn):setTimeout(Ut,100,t)},100)}let h=0;const g=t.querySelector("select"),_=we(t)?"":`${i.remove}, `;for(const b of s){const y=g?.options[h],w=ot(b),E=b.value||w,R=`${t._speak}${w}, ${_}${++h} ${i.of} ${s.length}`;x(b,"role","button"),x(b,"value",E),x(b,"tabindex","-1"),x(b,"aria-label",R),y?Object.assign(y,{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(h))b.remove();!c&&h>1&&console.warn("u-combobox: Multiple <data> found in single mode."),x(r,"aria-multiselectable",`${c}`),x(a,"list",dn(r)),x(a,"aria-label",`${t._speak}${u}${mn}`),r.hasAttribute("popover")&&(x(a,"popovertarget",dn(r)),x(r,"popover","manual"));const v=ot(s[0]);v!==t._item&&Vt(t),t._item=v,gn(t),bn(t),(n=he(t))==null||n.takeRecords()},gn=t=>{var e;t.clear&&x(t.clear,"role","button"),t.clear&&(t.clear.hidden=!((e=t.control)!=null&&e.value)||we(t))},bn=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)}},Vt=t=>{const{multiple:e,control:n,items:o}=t,i=ot(o[0]);!e&&n&&i!==n.value&&un(n,i,i?Ts:hn)},xe=(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(m=>(x(m,"label")||ot(m)).trim().toLowerCase()===d);const p={bubbles:!0,cancelable:!0,detail:u};if(t.dispatchEvent(new CustomEvent("comboboxbeforematch",p))||(u=[...i].find(m=>m.selected)),e)return bn(t),u?mt(t,u,!1):s&&l?mt(t,{value:l},!1):(!c&&!l&&r[0]?mt(t,r[0]):Vt(t),ge(o.invalid));for(const m of i)m.selected=m===u},mt=(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 Vt(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))}},Cs=(t,{target:e})=>{e instanceof HTMLElement&&(t._focus=e),ge()},ks=t=>ve()||setTimeout(As,0,t),As=t=>{var e;!t._focus||t.contains((e=t._root)==null?void 0:e.activeElement)||(t.multiple||xe(t),t._focus=void 0)},Ls=(t,e)=>{const{clientX:n,clientY:o,target:i}=e,{clear:s,control:a,items:r}=t;if(s?.contains(i))return a&&un(a,"",hn),a?.focus();for(const c of r){const{top:l,right:d,bottom:u,left:p}=c.getBoundingClientRect();if(c.contains(i))return mt(t,c);if(o>=l&&o<=u&&n>=p&&n<=d)return c.focus()}i===t&&a?.focus()},Is=(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 mt(t,c,s)}else s||xe(t,!1);gn(t)},Os=(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=0,o.focus(),Dt(o,"blur",()=>x(o,"tabindex",null),pn)),!(!l&&bs(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)),xe(t)}else if(a==="Backspace"&&!d){if(e.preventDefault(),!r&&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()}};_s.define("u-combobox",ye);var Ee=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",Ms=Ee&&/android/i.test(navigator.userAgent),vn;Ee&&/^Mac/i.test(((vn=navigator.userAgentData)==null?void 0:vn.platform)||navigator.platform);var Rs=`${Ms?"data":"aria"}-labelledby`,Se=":host(:not([hidden])) { display: block }",qt=typeof HTMLElement>"u"?class{}:HTMLElement;function L(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)},Ps=(t,...e)=>yn("add",t,e),Ds=(t,...e)=>yn("remove",t,e),Gt=(t,e)=>t.shadowRoot||t.attachShadow({mode:"open"}).append(En("slot"),En("style",e)),Wt=new WeakMap,_n=(t,e)=>{if(e===void 0)return Wt.get(t);try{Wt.get(t).disconnect(),Wt.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),Wt.set(t,n)}},Ns=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},Hs=0,xn=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++Hs).toString(32)}`),t.id):"",En=(t,e,n)=>{const o=document.createElement(t);return e&&(o.textContent=e),o},zt={define:(t,e)=>!Ee||window.customElements.get(t)||window.customElements.define(t,e)},Bs=Se,Fs=Se,Us=Se,Vs=':host(:not([hidden])) { display: inline-block; cursor: pointer }:host([aria-disabled="true"]) { cursor: default }',Xt="aria-controls",ht="aria-selected",Sn=class extends qt{constructor(){super(),Gt(this,Bs)}get tabList(){return jt("u-tablist",this)[0]||null}get selectedIndex(){return Kt(this.tabs)}set selectedIndex(t){Ce(this.tabs[t])}get tabs(){return jt("u-tab",this)}get panels(){return jt("u-tabpanel",this)}},$n=class extends qt{constructor(){super(),Gt(this,Fs)}connectedCallback(){L(this,"role","tablist"),Ps(this,"click,keydown",this),_n(this,{childList:!0}),this.tabs.length&&this.handleEvent()}disconnectedCallback(){Ds(this,"click,keydown",this),_n(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"&&Ce(n[o]),t.type==="keydown"&&!Ns(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){Ce(this.tabs[t])}},$e=!1,Tn=class extends qt{static get observedAttributes(){return["id",ht,Xt]}constructor(){super(),Gt(this,Vs)}connectedCallback(){L(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=jt("u-tabpanel",this.tabsElement||this),n=Te(this,e[t.indexOf(this)]);n&&L(n,Rs,xn(this)),t.forEach((o,i)=>{const s=Te(o,e[i]);o.tabIndex=o===this?0:-1,L(o,ht,`${o===this}`),L(o,Xt,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 L(this,ht)==="true"}set selected(t){L(this,ht,`${!!t}`)}get index(){const t=this.tabList;return t?[...t.querySelectorAll("u-tab")].indexOf(this):0}get panel(){return Te(this)}},Cn=class extends qt{static get observedAttributes(){return["hidden"]}constructor(){super(),Gt(this,Us)}connectedCallback(){L(this,"role","tabpanel"),this.hidden=Kt(this.tabs)===-1,this.attributeChangedCallback()}attributeChangedCallback(){const t=this.hidden;L(this,"aria-hidden",`${t}`),L(this,"tabindex",t||qs(this.firstChild)?null:"0")}get tabsElement(){return this.closest("u-tabs")}get tabs(){const t=`u-tab[${Xt}="${this.id}"]`;return wn(this).querySelectorAll(t)}},jt=(t,e)=>e.querySelectorAll(`${t}:not(:scope u-tabpanel ${t})`),Te=(t,e)=>{const n=L(t,Xt)||xn(e),o=wn(t).getElementById(n);return o?.nodeName==="U-TABPANEL"?o:null},Kt=t=>[...t].findIndex(e=>L(e,ht)==="true"),Ce=t=>t&&L(t,"aria-disabled")!=="true"&&L(t,"aria-selected","true"),qs=t=>t instanceof Element&&!t.matches(':disabled,[tabindex^="-"]')&&t.matches('[contenteditable],[controls],[href],[tabindex],input:not([type="hidden"]),select,textarea,button,summary,iframe');zt.define("u-tabs",Sn),zt.define("u-tablist",$n),zt.define("u-tab",Tn),zt.define("u-tabpanel",Cn);const Gs="2.2.26",kn="_alert_mdphy_1 _ds-alert_5rpuv_3",An="_app_mdphy_1",Ln="_sticky_mdphy_1",In="_avatar_mdphy_1 _ds-avatar_5rpuv_1",On="_badge_mdphy_1",Mn="_breadcrumbs_mdphy_1 _ds-breadcrumbs_5rpuv_5",Rn="_button_mdphy_1 _ds-button_5rpuv_1",Pn="_card_mdphy_1",Dn="_group_mdphy_1",Nn="_chip_mdphy_1 _ds-chip_5rpuv_5",Hn="_details_mdphy_1 _ds-details_5rpuv_3",Bn="_dialog_mdphy_1 _ds-dialog_5rpuv_5",Fn="__drawer_mdphy_1",Un="_divider_mdphy_1",Vn="_errorsummary_mdphy_1 _ds-error-summary_5rpuv_5",qn="__errorsummary_mdphy_1",Gn="_field_mdphy_1 _ds-field_5rpuv_1",Wn="__datalist_mdphy_1",zn="_affixes_mdphy_1 _ds-field-affixes_5rpuv_3",Xn="_fieldset_mdphy_1 _ds-fieldset_5rpuv_3",jn="_fileupload_mdphy_1",Kn="_helptext_mdphy_1 _ds-focus_5rpuv_1",Yn="_input_mdphy_1 _ds-input_5rpuv_1",Qn="_law_mdphy_1",Jn="_grid_mdphy_1",Zn="_flex_mdphy_1",to="_link_mdphy_1",eo="_logo_mdphy_1",no="_pagination_mdphy_1 _ds-pagination_5rpuv_5",oo="_popover_mdphy_1",io="_progress_mdphy_1",so="__indeterminate_mdphy_1",ao="_skeleton_mdphy_1 _ds-skeleton_5rpuv_5",ro="__skeleton_mdphy_1",lo="_spinner_mdphy_1",co="_steps_mdphy_1",uo="_table_mdphy_1 _ds-table_5rpuv_5",fo="__scrollShadow_mdphy_1",po="_tabs_mdphy_1 _ds-tabs_5rpuv_5",mo="__scrollMask_mdphy_1",ho="_tag_mdphy_1 _ds-tag_5rpuv_5",go="_toast_mdphy_1",bo="__toastClose_mdphy_1",vo="__toastOpen_mdphy_1",yo="__toastTimeout_mdphy_1",_o="_togglegroup_mdphy_1",wo="__tooltip_mdphy_1",xo="_heading_mdphy_1 _ds-heading_5rpuv_1",Eo="_ingress_mdphy_1",So="_muted_mdphy_1",$o="_info_mdphy_1",To="_prose_mdphy_1",Co="_validation_mdphy_1 _ds-validation-message_5rpuv_1",ko="_body_mdphy_173",Ao="__checked_mdphy_1",$={alert:kn,app:An,sticky:Ln,avatar:In,badge:On,breadcrumbs:Mn,button:Rn,card:Pn,group:Dn,chip:Nn,details:Hn,dialog:Bn,_drawer:Fn,divider:Un,errorsummary:Vn,_errorsummary:qn,field:Gn,_datalist:Wn,affixes:zn,fieldset:Xn,fileupload:jn,helptext:Kn,input:Yn,law:Qn,grid:Jn,flex:Zn,link:to,logo:eo,pagination:no,popover:oo,progress:io,_indeterminate:so,skeleton:ao,_skeleton:ro,spinner:lo,steps:co,table:uo,_scrollShadow:fo,tabs:po,_scrollMask:mo,tag:ho,toast:go,_toastClose:bo,_toastOpen:vo,_toastTimeout:yo,togglegroup:_o,_tooltip:wo,heading:xo,ingress:Eo,muted:So,info:$o,prose:To,validation:Co,body:ko,_checked:Ao},Ws=Object.freeze(Object.defineProperty({__proto__:null,_checked:Ao,_datalist:Wn,_drawer:Fn,_errorsummary:qn,_indeterminate:so,_scrollMask:mo,_scrollShadow:fo,_skeleton:ro,_toastClose:bo,_toastOpen:vo,_toastTimeout:yo,_tooltip:wo,affixes:zn,alert:kn,app:An,avatar:In,badge:On,body:ko,breadcrumbs:Mn,button:Rn,card:Pn,chip:Nn,default:$,details:Hn,dialog:Bn,divider:Un,errorsummary:Vn,field:Gn,fieldset:Xn,fileupload:jn,flex:Zn,grid:Jn,group:Dn,heading:xo,helptext:Kn,info:$o,ingress:Eo,input:Yn,law:Qn,link:to,logo:eo,muted:So,pagination:no,popover:oo,progress:io,prose:To,skeleton:ao,spinner:lo,steps:co,sticky:Ln,table:uo,tabs:po,tag:ho,toast:go,togglegroup:_o,validation:Co},Symbol.toStringTag,{value:"Module"})),gt=Math.min,P=Math.max,Yt=Math.round,Qt=Math.floor,q=t=>({x:t,y:t}),zs={left:"right",right:"left",bottom:"top",top:"bottom"},Xs={start:"end",end:"start"};function Lo(t,e,n){return P(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 Io(t){return t==="x"?"y":"x"}function Oo(t){return t==="y"?"height":"width"}const js=new Set(["top","bottom"]);function Q(t){return js.has(it(t))?"y":"x"}function Mo(t){return Io(Q(t))}function Ks(t,e,n){n===void 0&&(n=!1);const o=Zt(t),i=Mo(t),s=Oo(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 Ys(t){const e=te(t);return[ke(t),e,ke(e)]}function ke(t){return t.replace(/start|end/g,e=>Xs[e])}const Ro=["left","right"],Po=["right","left"],Qs=["top","bottom"],Js=["bottom","top"];function Zs(t,e,n){switch(t){case"top":case"bottom":return n?e?Po:Ro:e?Ro:Po;case"left":case"right":return e?Qs:Js;default:return[]}}function ta(t,e,n,o){const i=Zt(t);let s=Zs(it(t),n==="start",o);return i&&(s=s.map(a=>a+"-"+i),e&&(s=s.concat(s.map(ke)))),s}function te(t){return t.replace(/left|right|bottom|top/g,e=>zs[e])}function ea(t){return{top:0,right:0,bottom:0,left:0,...t}}function na(t){return typeof t!="number"?ea(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 Do(t,e,n){let{reference:o,floating:i}=t;const s=Q(e),a=Mo(e),r=Oo(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 m;switch(c){case"top":m={x:d,y:o.y-i.height};break;case"bottom":m={x:d,y:o.y+o.height};break;case"right":m={x:o.x+o.width,y:u};break;case"left":m={x:o.x-i.width,y:u};break;default:m={x:o.x,y:o.y}}switch(Zt(e)){case"start":m[a]-=p*(n&&l?-1:1);break;case"end":m[a]+=p*(n&&l?-1:1);break}return m}const oa=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}=Do(l,o,c),p=o,m={},h=0;for(let g=0;g<r.length;g++){const{name:_,fn:v}=r[g],{x:b,y,data:w,reset:E}=await v({x:d,y:u,initialPlacement:o,placement:p,strategy:i,middlewareData:m,rects:l,platform:a,elements:{reference:t,floating:e}});d=b??d,u=y??u,m={...m,[_]:{...m[_],...w}},E&&h<=50&&(h++,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}=Do(l,p,c)),g=-1)}return{x:d,y:u,placement:p,strategy:i,middlewareData:m}};async function Ae(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:m=0}=Jt(e,t),h=na(m),_=r[p?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(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,y=await(s.getOffsetParent==null?void 0:s.getOffsetParent(r.floating)),w=await(s.isElement==null?void 0:s.isElement(y))?await(s.getScale==null?void 0:s.getScale(y))||{x:1,y:1}:{x:1,y:1},E=ee(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:r,rect:b,offsetParent:y,strategy:c}):b);return{top:(v.top-E.top+h.top)/w.y,bottom:(E.bottom-v.bottom+h.bottom)/w.y,left:(v.left-E.left+h.left)/w.x,right:(E.right-v.right+h.right)/w.x}}const ia=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:m="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:g=!0,..._}=Jt(t,e);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const v=it(i),b=Q(r),y=it(r)===r,w=await(c.isRTL==null?void 0:c.isRTL(l.floating)),E=p||(y||!g?[te(r)]:Ys(r)),R=h!=="none";!p&&R&&E.push(...ta(r,g,h,w));const z=[r,...E],dt=await Ae(e,_),ut=[];let Y=((o=s.flip)==null?void 0:o.overflows)||[];if(d&&ut.push(dt[v]),u){const ft=Ks(i,a,w);ut.push(dt[ft[0]],dt[ft[1]])}if(Y=[...Y,{placement:i,overflows:ut}],!ut.every(ft=>ft<=0)){var Ot,Mt;const ft=(((Ot=s.flip)==null?void 0:Ot.index)||0)+1,on=z[ft];if(on&&(!(u==="alignment"?b!==Q(on):!1)||Y.every(V=>Q(V.placement)===b?V.overflows[0]>0:!0)))return{data:{index:ft,overflows:Y},reset:{placement:on}};let Pt=(Mt=Y.filter(pt=>pt.overflows[0]<=0).sort((pt,V)=>pt.overflows[1]-V.overflows[1])[0])==null?void 0:Mt.placement;if(!Pt)switch(m){case"bestFit":{var Rt;const pt=(Rt=Y.filter(V=>{if(R){const et=Q(V.placement);return et===b||et==="y"}return!0}).map(V=>[V.placement,V.overflows.filter(et=>et>0).reduce((et,rc)=>et+rc,0)]).sort((V,et)=>V[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{}}}},sa=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:_=>{let{x:v,y:b}=_;return{x:v,y:b}}},...c}=Jt(t,e),l={x:n,y:o},d=await Ae(e,c),u=Q(it(i)),p=Io(u);let m=l[p],h=l[u];if(s){const _=p==="y"?"top":"left",v=p==="y"?"bottom":"right",b=m+d[_],y=m-d[v];m=Lo(b,m,y)}if(a){const _=u==="y"?"top":"left",v=u==="y"?"bottom":"right",b=h+d[_],y=h-d[v];h=Lo(b,h,y)}const g=r.fn({...e,[p]:m,[u]:h});return{...g,data:{x:g.x-n,y:g.y-o,enabled:{[p]:s,[u]:a}}}}}},aa=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 Ae(e,l),u=it(i),p=Zt(i),m=Q(i)==="y",{width:h,height:g}=s.floating;let _,v;u==="top"||u==="bottom"?(_=u,v=p===(await(a.isRTL==null?void 0:a.isRTL(r.floating))?"start":"end")?"left":"right"):(v=u,_=p==="end"?"top":"bottom");const b=g-d.top-d.bottom,y=h-d.left-d.right,w=gt(g-d[_],b),E=gt(h-d[v],y),R=!e.middlewareData.shift;let z=w,dt=E;if((n=e.middlewareData.shift)!=null&&n.enabled.x&&(dt=y),(o=e.middlewareData.shift)!=null&&o.enabled.y&&(z=b),R&&!p){const Y=P(d.left,0),Ot=P(d.right,0),Mt=P(d.top,0),Rt=P(d.bottom,0);m?dt=h-2*(Y!==0||Ot!==0?Y+Ot:P(d.left,d.right)):z=g-2*(Mt!==0||Rt!==0?Mt+Rt:P(d.top,d.bottom))}await c({...e,availableWidth:dt,availableHeight:z});const ut=await a.getDimensions(r.floating);return h!==ut.width||g!==ut.height?{reset:{rects:!0}}:{}}}};function ne(){return typeof window<"u"}function bt(t){return No(t)?(t.nodeName||"").toLowerCase():"#document"}function D(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function G(t){var e;return(e=(No(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function No(t){return ne()?t instanceof Node||t instanceof D(t).Node:!1}function H(t){return ne()?t instanceof Element||t instanceof D(t).Element:!1}function W(t){return ne()?t instanceof HTMLElement||t instanceof D(t).HTMLElement:!1}function Ho(t){return!ne()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof D(t).ShadowRoot}const ra=new Set(["inline","contents"]);function xt(t){const{overflow:e,overflowX:n,overflowY:o,display:i}=B(t);return/auto|scroll|overlay|hidden|clip/.test(e+o+n)&&!ra.has(i)}const la=new Set(["table","td","th"]);function ca(t){return la.has(bt(t))}const da=[":popover-open",":modal"];function oe(t){return da.some(e=>{try{return t.matches(e)}catch{return!1}})}const ua=["transform","translate","scale","rotate","perspective"],fa=["transform","translate","scale","rotate","perspective","filter"],pa=["paint","layout","strict","content"];function Le(t){const e=Ie(),n=H(t)?B(t):t;return ua.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)||fa.some(o=>(n.willChange||"").includes(o))||pa.some(o=>(n.contain||"").includes(o))}function ma(t){let e=J(t);for(;W(e)&&!vt(e);){if(Le(e))return e;if(oe(e))return null;e=J(e)}return null}function Ie(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const ha=new Set(["html","body","#document"]);function vt(t){return ha.has(bt(t))}function B(t){return D(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||Ho(t)&&t.host||G(t);return Ho(e)?e.host:e}function Bo(t){const e=J(t);return vt(e)?t.ownerDocument?t.ownerDocument.body:t.body:W(e)&&xt(e)?e:Bo(e)}function Et(t,e,n){var o;e===void 0&&(e=[]),n===void 0&&(n=!0);const i=Bo(t),s=i===((o=t.ownerDocument)==null?void 0:o.body),a=D(i);if(s){const r=Oe(a);return e.concat(a,a.visualViewport||[],xt(i)?i:[],r&&n?Et(r):[])}return e.concat(i,Et(i,[],n))}function Oe(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function Fo(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=Yt(n)!==s||Yt(o)!==a;return r&&(n=s,o=a),{width:n,height:o,$:r}}function Me(t){return H(t)?t:t.contextElement}function yt(t){const e=Me(t);if(!W(e))return q(1);const n=e.getBoundingClientRect(),{width:o,height:i,$:s}=Fo(e);let a=(s?Yt(n.width):n.width)/o,r=(s?Yt(n.height):n.height)/i;return(!a||!Number.isFinite(a))&&(a=1),(!r||!Number.isFinite(r))&&(r=1),{x:a,y:r}}const ga=q(0);function Uo(t){const e=D(t);return!Ie()||!e.visualViewport?ga:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function ba(t,e,n){return e===void 0&&(e=!1),!n||e&&n!==D(t)?!1:e}function st(t,e,n,o){e===void 0&&(e=!1),n===void 0&&(n=!1);const i=t.getBoundingClientRect(),s=Me(t);let a=q(1);e&&(o?H(o)&&(a=yt(o)):a=yt(t));const r=ba(s,n,o)?Uo(s):q(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=D(s),m=o&&H(o)?D(o):o;let h=p,g=Oe(h);for(;g&&o&&m!==h;){const _=yt(g),v=g.getBoundingClientRect(),b=B(g),y=v.left+(g.clientLeft+parseFloat(b.paddingLeft))*_.x,w=v.top+(g.clientTop+parseFloat(b.paddingTop))*_.y;c*=_.x,l*=_.y,d*=_.x,u*=_.y,c+=y,l+=w,h=D(g),g=Oe(h)}}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(G(t)).left+n}function Vo(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 va(t){let{elements:e,rect:n,offsetParent:o,strategy:i}=t;const s=i==="fixed",a=G(o),r=e?oe(e.floating):!1;if(o===a||r&&s)return n;let c={scrollLeft:0,scrollTop:0},l=q(1);const d=q(0),u=W(o);if((u||!u&&!s)&&((bt(o)!=="body"||xt(a))&&(c=ie(o)),W(o))){const m=st(o);l=yt(o),d.x=m.x+o.clientLeft,d.y=m.y+o.clientTop}const p=a&&!u&&!s?Vo(a,c):q(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 ya(t){return Array.from(t.getClientRects())}function _a(t){const e=G(t),n=ie(t),o=t.ownerDocument.body,i=P(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),s=P(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight);let a=-n.scrollLeft+se(t);const r=-n.scrollTop;return B(o).direction==="rtl"&&(a+=P(e.clientWidth,o.clientWidth)-i),{width:i,height:s,x:a,y:r}}const qo=25;function wa(t,e){const n=D(t),o=G(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=Ie();(!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),m=d.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,h=Math.abs(o.clientWidth-u.clientWidth-m);h<=qo&&(s-=h)}else l<=qo&&(s+=l);return{width:s,height:a,x:r,y:c}}const xa=new Set(["absolute","fixed"]);function Ea(t,e){const n=st(t,!0,e==="fixed"),o=n.top+t.clientTop,i=n.left+t.clientLeft,s=W(t)?yt(t):q(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 Go(t,e,n){let o;if(e==="viewport")o=wa(t,n);else if(e==="document")o=_a(G(t));else if(H(e))o=Ea(e,n);else{const i=Uo(t);o={x:e.x-i.x,y:e.y-i.y,width:e.width,height:e.height}}return ee(o)}function Wo(t,e){const n=J(t);return n===e||!H(n)||vt(n)?!1:B(n).position==="fixed"||Wo(n,e)}function Sa(t,e){const n=e.get(t);if(n)return n;let o=Et(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=Le(a);!c&&r.position==="fixed"&&(i=null),(s?!c&&!i:!c&&r.position==="static"&&!!i&&xa.has(i.position)||xt(a)&&!c&&Wo(t,a))?o=o.filter(d=>d!==a):i=r,a=J(a)}return e.set(t,o),o}function $a(t){let{element:e,boundary:n,rootBoundary:o,strategy:i}=t;const a=[...n==="clippingAncestors"?oe(e)?[]:Sa(e,this._c):[].concat(n),o],r=a[0],c=a.reduce((l,d)=>{const u=Go(e,d,i);return l.top=P(u.top,l.top),l.right=gt(u.right,l.right),l.bottom=gt(u.bottom,l.bottom),l.left=P(u.left,l.left),l},Go(e,r,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function Ta(t){const{width:e,height:n}=Fo(t);return{width:e,height:n}}function Ca(t,e,n){const o=W(e),i=G(e),s=n==="fixed",a=st(t,!0,s,e);let r={scrollLeft:0,scrollTop:0};const c=q(0);function l(){c.x=se(i)}if(o||!o&&!s)if((bt(e)!=="body"||xt(i))&&(r=ie(e)),o){const m=st(e,!0,s,e);c.x=m.x+e.clientLeft,c.y=m.y+e.clientTop}else i&&l();s&&!o&&i&&l();const d=i&&!o&&!s?Vo(i,r):q(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 Re(t){return B(t).position==="static"}function zo(t,e){if(!W(t)||B(t).position==="fixed")return null;if(e)return e(t);let n=t.offsetParent;return G(t)===n&&(n=n.ownerDocument.body),n}function Xo(t,e){const n=D(t);if(oe(t))return n;if(!W(t)){let i=J(t);for(;i&&!vt(i);){if(H(i)&&!Re(i))return i;i=J(i)}return n}let o=zo(t,e);for(;o&&ca(o)&&Re(o);)o=zo(o,e);return o&&vt(o)&&Re(o)&&!Le(o)?n:o||ma(t)||n}const ka=async function(t){const e=this.getOffsetParent||Xo,n=this.getDimensions,o=await n(t.floating);return{reference:Ca(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function Aa(t){return B(t).direction==="rtl"}const La={convertOffsetParentRelativeRectToViewportRelativeRect:va,getDocumentElement:G,getClippingRect:$a,getOffsetParent:Xo,getElementRects:ka,getClientRects:ya,getDimensions:Ta,getScale:yt,isElement:H,isRTL:Aa};function jo(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function Ia(t,e){let n=null,o;const i=G(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:m}=l;if(r||e(),!p||!m)return;const h=Qt(u),g=Qt(i.clientWidth-(d+p)),_=Qt(i.clientHeight-(u+m)),v=Qt(d),y={rootMargin:-h+"px "+-g+"px "+-_+"px "+-v+"px",threshold:P(0,gt(1,c))||1};let w=!0;function E(R){const z=R[0].intersectionRatio;if(z!==c){if(!w)return a();z?a(!1,z):o=setTimeout(()=>{a(!1,1e-7)},1e3)}z===1&&!jo(l,t.getBoundingClientRect())&&a(),w=!1}try{n=new IntersectionObserver(E,{...y,root:i.ownerDocument})}catch{n=new IntersectionObserver(E,y)}n.observe(t)}return a(!0),s}function Oa(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=Me(t),d=i||s?[...l?Et(l):[],...Et(e)]:[];d.forEach(v=>{i&&v.addEventListener("scroll",n,{passive:!0}),s&&v.addEventListener("resize",n)});const u=l&&r?Ia(l,n):null;let p=-1,m=null;a&&(m=new ResizeObserver(v=>{let[b]=v;b&&b.target===l&&m&&(m.unobserve(e),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var y;(y=m)==null||y.observe(e)})),n()}),l&&!c&&m.observe(l),m.observe(e));let h,g=c?st(t):null;c&&_();function _(){const v=st(t);g&&!jo(g,v)&&n(),g=v,h=requestAnimationFrame(_)}return n(),()=>{var v;d.forEach(b=>{i&&b.removeEventListener("scroll",n),s&&b.removeEventListener("resize",n)}),u?.(),(v=m)==null||v.disconnect(),m=null,c&&cancelAnimationFrame(h)}}const Ko=sa,Yo=ia,Ma=aa,Ra=(t,e,n)=>{const o=new Map,i={platform:La,...n},s={...i.platform,_c:o};return oa(t,e,{...i,platform:s})};function Qo(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=Qo(t[e]))&&(o&&(o+=" "),o+=n)}else for(n in t)t[n]&&(o&&(o+=" "),o+=n);return o}function Pa(){for(var t,e,n=0,o="",i=arguments.length;n<i;n++)(t=arguments[n])&&(e=Qo(t))&&(o&&(o+=" "),o+=e);return o}const I={capture:!0,passive:!0},O=()=>typeof window<"u"&&typeof document<"u";function Da(t,e){let n;return function(...o){clearTimeout(n),n=setTimeout(()=>t.apply(this,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 Na=0;const Ha=`${Date.now().toString(36)}${Math.random().toString(36).slice(2,5)}`;function ae(t){return t.id||(t.id=`${Ha}${++Na}`),t.id}const Jo=(t,e,[...n])=>{for(const o of n[0].split(","))n[0]=o,e[`${t}EventListener`](...n)},T=(t,...e)=>(Jo("add",t,e),()=>Zo(t,...e)),Zo=(t,...e)=>Jo("remove",t,e),N=t=>{if(!O()||!window.requestAnimationFrame)return;window._mtdsCleanups||(window._mtdsCleanups=new Map);const e=()=>requestAnimationFrame(()=>{const n=String(t).replace(/(\n|\s)/g,"");window._mtdsCleanups?.get(n)?.map(o=>o()),window._mtdsCleanups?.set(n,t())});document.readyState==="complete"?e():T(window,"load",e)},Pe=new WeakMap,Ba=`.${$.dialog.split(" ")[0]}`;function at(t,e,{contain:n,middleware:o,placement:i,...s}={}){if(Pe.get(t)?.(),Pe.delete(t),e){const a=t.closest(Ba)?.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";Pe.set(t,Oa(e,t,()=>{if(!t.isConnected||!e.isConnected||t.hidden)return at(t,!1);Ra(e,t,{...s,placement:i||d,middleware:[Yo({padding:l}),Ko(),...n?[Ma({padding:l,apply:n})]:[],...o||[]]}).then(({x:u,y:p})=>{t.style.left=`${u}px`,t.style.top=`${p}px`})}))}}function Z(t,e){let n=0;const o=Array.isArray(e)||typeof e=="string"?{attr:e}:e,i=()=>setTimeout(s,o?.delay??200),s=()=>{if(!O())return r();t(a),a.takeRecords(),n=0},a=new MutationObserver(()=>{n||(n=requestAnimationFrame(i))}),r=()=>{try{a.disconnect()}catch{}};return a.observe(o?.root||document.documentElement,{attributeFilter:[].concat(o.attr),attributes:!0,childList:!0,subtree:!0}),t(a),r}function Fa(t,e){const n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()}const De=t=>t instanceof HTMLElement&&"validity"in t&&!(t instanceof HTMLButtonElement),k=(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},Ua=typeof HTMLElement>"u"?class{}:HTMLElement,Va=(t,e)=>!O()||window.customElements.get(t)||window.customElements.define(t,e),qa=`.${$.breadcrumbs.split(" ")[0]}`,Ga=`.${$.card.split(" ")[0]}`,ti=`.${$.chip.split(" ")[0]}`,Wa=`.${$.helptext.split(" ")[0]}`,za=`.${$.pagination.split(" ")[0]}`,Xa='summary,u-summary,a,button,[role="tab"],[role="button"]',ja="click,toggle,submit,change",Ne="mattilsynet.matomo.cloud",Ka=["setCustomUrl","setDocumentTitle","setReferrerUrl"],F="mtds-analytics-banner",Ya="https://www.mattilsynet.no/om-mattilsynet/personvernerklaering/informasjonskapsler";function ei(t,e={}){if(O()){if(window._paq||(window._paq=[],window._paq.push(["HeatmapSessionRecording::disable"]),window._paq.push(["enableLinkTracking"]),window._paq.push(["setTrackerUrl",`https://${Ne}/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"&&Qa();const a=s?`https://cdn.matomo.cloud/${Ne}/container_${s}.js`:`https://cdn.matomo.cloud/${Ne}/matomo.js`;document.querySelector(`script[src="${a}"]`)||document.head.append(k("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 if(t==="matomo"){const n=e;Ka.includes(n?.[0])&&typeof n[1]!="string"&&(n[1]=`${n[1]??""}`),window._paq.push(n)}}}}function Qa(){if(document.getElementById(F)||window.localStorage.getItem(F))return;document.body.insertAdjacentHTML("afterbegin",`<dialog id="${F}" data-analytics="ignore"><style>
|
|
8
|
+
::slotted(data:focus) { ${hs} }`,fn="beforeinput,blur,focus,click,input,keydown,mousedown",pn={once:!0,passive:!0},Bt="false",$s=ps&&!rn,Ts=rn||ms,mn="".repeat(5),hn="deleteContentBackward",Cs="insertText",Ft={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 gs{constructor(){super(),this._item="",this._speak="",this._texts=fs({},Ft),this._value="",this.shadowRoot||this.attachShadow({mode:"open"}).append(Ht("slot"),Ht("style",Ss))}static get observedAttributes(){return Object.keys(Ft).map(t=>`data-sr-${t}`)}connectedCallback(){this._root=ys(this),Dt(this,fn,this,!0),he(this,{attributeFilter:["value","id"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),setTimeout(Ut,0,this),setTimeout(qt,0,this)}attributeChangedCallback(t,e,n){const o=t.split("data-sr-")[1];Ft[o]&&(this._texts[o]=n||Ft[o])}disconnectedCallback(){he(this,!1),bs(this,fn,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;we(this)||(t.type==="beforeinput"&&(this._value=e?.value||""),t.type==="blur"&&As(this),t.type==="click"&&Is(this,t),t.type==="focus"&&ks(this,t),t.type==="input"&&Os(this,t),t.type==="keydown"&&Ms(this,t),t.type==="mousedown"&&ve(t),t.type==="mutation"&&Ut(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())||""},_e=t=>t instanceof HTMLDataElement,we=({control:t})=>t?.disabled||t?.readOnly||!1,Ut=(t,e)=>{var n;const{_focus:o,_texts:i,items:s,control:a,list:r,multiple:l}=t;if(!a||!r)return;const c=xs(a),d=c.endsWith(mn)?x(a,"data-label"):c;x(a,"data-label",d);let u=`${d}${l?`, ${s.length?i.found.replace("%d",`${s.length}`):i.empty}`:""}`;const p=[];for(const{addedNodes:b,removedNodes:y}of e?.detail||[]){for(const w of b)_e(w)&&p.unshift(w);for(const w of y)_e(w)&&p.push(w)}const m=l?p.length===1:p[0]===o;if(o&&m){const b=x(a,"aria-expanded"),y=x(a,"inputmode"),w=_e(o)?a:o,E=!p[0].isConnected;t._speak=`${i[E?"removed":"added"]} ${ot(p[0])}, `,(Ts||o===a)&&ge(t._speak),a!==w&&(x(a,"aria-expanded",null),x(a,"inputmode","none"),u=" ",a.focus()),setTimeout(()=>{var R;x(a,"aria-expanded",b),x(a,"inputmode",E?"none":y),(R=w?.focus)==null||R.call(w),x(a,"inputmode",y),t._speak="",$s?Dt(t,"blur",()=>Ut(t),pn):setTimeout(Ut,100,t)},100)}let h=0;const g=t.querySelector("select"),_=we(t)?"":`${i.remove}, `;for(const b of s){const y=g?.options[h],w=ot(b),E=b.value||w,R=`${t._speak}${w}, ${_}${++h} ${i.of} ${s.length}`;x(b,"role","button"),x(b,"value",E),x(b,"tabindex","-1"),x(b,"aria-label",R),y?Object.assign(y,{textContent:w,value:E}):g?.appendChild(new Option(w,E,!0,!0))}g&&x(g,"multiple",l?"":null);for(const b of[...g?.options||[]].slice(h))b.remove();!l&&h>1&&console.warn("u-combobox: Multiple <data> found in single mode."),x(r,"aria-multiselectable",`${l}`),x(a,"list",dn(r)),x(a,"aria-label",`${t._speak}${u}${mn}`),r.hasAttribute("popover")&&(x(a,"popovertarget",dn(r)),x(r,"popover","manual"));const v=ot(s[0]);v!==t._item&&qt(t),t._item=v,gn(t),bn(t),(n=he(t))==null||n.takeRecords()},gn=t=>{var e;t.clear&&x(t.clear,"role","button"),t.clear&&(t.clear.hidden=!((e=t.control)!=null&&e.value)||we(t))},bn=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)}},qt=t=>{const{multiple:e,control:n,items:o}=t,i=ot(o[0]);!e&&n&&i!==n.value&&un(n,i,i?Cs:hn)},xe=(t,e=!0)=>{var n;const{_texts:o,options:i=[],creatable:s,control:a,items:r,multiple:l}=t,c=((n=a?.value)==null?void 0:n.trim())||"",d=c.toLowerCase()||null;let u=[...i].find(m=>(x(m,"label")||ot(m)).trim().toLowerCase()===d);const p={bubbles:!0,cancelable:!0,detail:u};if(t.dispatchEvent(new CustomEvent("comboboxbeforematch",p))||(u=[...i].find(m=>m.selected)),e)return bn(t),u?mt(t,u,!1):s&&c?mt(t,{value:c},!1):(!l&&!c&&r[0]?mt(t,r[0]):qt(t),ge(o.invalid));for(const m of i)m.selected=m===u},mt=(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),l={bubbles:!0,cancelable:!0,detail:r||a};if(r&&!n)return qt(t);if(t.dispatchEvent(new CustomEvent("comboboxbeforeselect",l))){if(!s)for(const d of[...i])d.remove();r?r.remove():o?.insertAdjacentElement("beforebegin",a),t.dispatchEvent(new CustomEvent("comboboxafterselect",l))}},ks=(t,{target:e})=>{e instanceof HTMLElement&&(t._focus=e),ge()},As=t=>ve()||setTimeout(Ls,0,t),Ls=t=>{var e;!t._focus||t.contains((e=t._root)==null?void 0:e.activeElement)||(t.multiple||xe(t),t._focus=void 0)},Is=(t,e)=>{const{clientX:n,clientY:o,target:i}=e,{clear:s,control:a,items:r}=t;if(s?.contains(i))return a&&un(a,"",hn),a?.focus();for(const l of r){const{top:c,right:d,bottom:u,left:p}=l.getBoundingClientRect();if(l.contains(i))return mt(t,l);if(o>=c&&o<=u&&n>=p&&n<=d)return l.focus()}i===t&&a?.focus()},Os=(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 l of o)if(l.value&&l.value===a)return mt(t,l,s)}else s||xe(t,!1);gn(t)},Ms=(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:l}=e,c=i&&i===l,d=c&&i?.selectionEnd;let u=c?s.length:[...s].indexOf(l);if(c&&a==="Tab"&&o&&!o.hidden&&(e.preventDefault(),o.tabIndex=0,o.focus(),Dt(o,"blur",()=>x(o,"tabindex",null),pn)),!(!c&&vs(e)||u===-1)){if(a==="ArrowRight"&&!c)u+=1;else if(a==="ArrowLeft"&&!d)u-=1;else if(a==="Enter"&&c){const p=x(i,"form");return x(i,"form","#"),requestAnimationFrame(()=>x(i,"form",p)),xe(t)}else if(a==="Backspace"&&!d){if(e.preventDefault(),!r&&s[u])return mt(t,s[u]);c&&(u-=1)}else return c||i?.focus();e.preventDefault(),(n=s[Math.max(0,u)]||i)==null||n.focus()}};ws.define("u-combobox",ye);var Ee=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",Rs=Ee&&/android/i.test(navigator.userAgent),vn;Ee&&/^Mac/i.test(((vn=navigator.userAgentData)==null?void 0:vn.platform)||navigator.platform);var Ps=`${Rs?"data":"aria"}-labelledby`,Se=":host(:not([hidden])) { display: block }",Vt=typeof HTMLElement>"u"?class{}:HTMLElement;function L(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)},Ds=(t,...e)=>yn("add",t,e),Ns=(t,...e)=>yn("remove",t,e),Gt=(t,e)=>t.shadowRoot||t.attachShadow({mode:"open"}).append(En("slot"),En("style",e)),Wt=new WeakMap,_n=(t,e)=>{if(e===void 0)return Wt.get(t);try{Wt.get(t).disconnect(),Wt.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),Wt.set(t,n)}},Hs=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},Bs=0,xn=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++Bs).toString(32)}`),t.id):"",En=(t,e,n)=>{const o=document.createElement(t);return e&&(o.textContent=e),o},zt={define:(t,e)=>!Ee||window.customElements.get(t)||window.customElements.define(t,e)},Fs=Se,Us=Se,qs=Se,Vs=':host(:not([hidden])) { display: inline-block; cursor: pointer }:host([aria-disabled="true"]) { cursor: default }',Xt="aria-controls",ht="aria-selected",Sn=class extends Vt{constructor(){super(),Gt(this,Fs)}get tabList(){return jt("u-tablist",this)[0]||null}get selectedIndex(){return Kt(this.tabs)}set selectedIndex(t){Ce(this.tabs[t])}get tabs(){return jt("u-tab",this)}get panels(){return jt("u-tabpanel",this)}},$n=class extends Vt{constructor(){super(),Gt(this,Us)}connectedCallback(){L(this,"role","tablist"),Ds(this,"click,keydown",this),_n(this,{childList:!0}),this.tabs.length&&this.handleEvent()}disconnectedCallback(){Ns(this,"click,keydown",this),_n(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"&&Ce(n[o]),t.type==="keydown"&&!Hs(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){Ce(this.tabs[t])}},$e=!1,Tn=class extends Vt{static get observedAttributes(){return["id",ht,Xt]}constructor(){super(),Gt(this,Vs)}connectedCallback(){L(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=jt("u-tabpanel",this.tabsElement||this),n=Te(this,e[t.indexOf(this)]);n&&L(n,Ps,xn(this)),t.forEach((o,i)=>{const s=Te(o,e[i]);o.tabIndex=o===this?0:-1,L(o,ht,`${o===this}`),L(o,Xt,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 L(this,ht)==="true"}set selected(t){L(this,ht,`${!!t}`)}get index(){const t=this.tabList;return t?[...t.querySelectorAll("u-tab")].indexOf(this):0}get panel(){return Te(this)}},Cn=class extends Vt{static get observedAttributes(){return["hidden"]}constructor(){super(),Gt(this,qs)}connectedCallback(){L(this,"role","tabpanel"),this.hidden=Kt(this.tabs)===-1,this.attributeChangedCallback()}attributeChangedCallback(){const t=this.hidden;L(this,"aria-hidden",`${t}`),L(this,"tabindex",t||Gs(this.firstChild)?null:"0")}get tabsElement(){return this.closest("u-tabs")}get tabs(){const t=`u-tab[${Xt}="${this.id}"]`;return wn(this).querySelectorAll(t)}},jt=(t,e)=>e.querySelectorAll(`${t}:not(:scope u-tabpanel ${t})`),Te=(t,e)=>{const n=L(t,Xt)||xn(e),o=wn(t).getElementById(n);return o?.nodeName==="U-TABPANEL"?o:null},Kt=t=>[...t].findIndex(e=>L(e,ht)==="true"),Ce=t=>t&&L(t,"aria-disabled")!=="true"&&L(t,"aria-selected","true"),Gs=t=>t instanceof Element&&!t.matches(':disabled,[tabindex^="-"]')&&t.matches('[contenteditable],[controls],[href],[tabindex],input:not([type="hidden"]),select,textarea,button,summary,iframe');zt.define("u-tabs",Sn),zt.define("u-tablist",$n),zt.define("u-tab",Tn),zt.define("u-tabpanel",Cn);const Ws="2.2.28",kn="_alert_mdphy_1 _ds-alert_5rpuv_3",An="_app_mdphy_1",Ln="_sticky_mdphy_1",In="_avatar_mdphy_1 _ds-avatar_5rpuv_1",On="_badge_mdphy_1",Mn="_breadcrumbs_mdphy_1 _ds-breadcrumbs_5rpuv_5",Rn="_button_mdphy_1 _ds-button_5rpuv_1",Pn="_card_mdphy_1",Dn="_group_mdphy_1",Nn="_chip_mdphy_1 _ds-chip_5rpuv_5",Hn="_details_mdphy_1 _ds-details_5rpuv_3",Bn="_dialog_mdphy_1 _ds-dialog_5rpuv_5",Fn="__drawer_mdphy_1",Un="_divider_mdphy_1",qn="_errorsummary_mdphy_1 _ds-error-summary_5rpuv_5",Vn="__errorsummary_mdphy_1",Gn="_field_mdphy_1 _ds-field_5rpuv_1",Wn="__datalist_mdphy_1",zn="_affixes_mdphy_1 _ds-field-affixes_5rpuv_3",Xn="_fieldset_mdphy_1 _ds-fieldset_5rpuv_3",jn="_fileupload_mdphy_1",Kn="_helptext_mdphy_1 _ds-focus_5rpuv_1",Yn="_input_mdphy_1 _ds-input_5rpuv_1",Qn="_law_mdphy_1",Jn="_grid_mdphy_1",Zn="_flex_mdphy_1",to="_link_mdphy_1",eo="_logo_mdphy_1",no="_pagination_mdphy_1 _ds-pagination_5rpuv_5",oo="_popover_mdphy_1",io="_progress_mdphy_1",so="__indeterminate_mdphy_1",ao="_skeleton_mdphy_1 _ds-skeleton_5rpuv_5",ro="__skeleton_mdphy_1",lo="_spinner_mdphy_1",co="_steps_mdphy_1",uo="_table_mdphy_1 _ds-table_5rpuv_5",fo="__scrollShadow_mdphy_1",po="_tabs_mdphy_1 _ds-tabs_5rpuv_5",mo="__scrollMask_mdphy_1",ho="_tag_mdphy_1 _ds-tag_5rpuv_5",go="_toast_mdphy_1",bo="__toastClose_mdphy_1",vo="__toastOpen_mdphy_1",yo="__toastTimeout_mdphy_1",_o="_togglegroup_mdphy_1",wo="__tooltip_mdphy_1",xo="_heading_mdphy_1 _ds-heading_5rpuv_1",Eo="_ingress_mdphy_1",So="_muted_mdphy_1",$o="_info_mdphy_1",To="_prose_mdphy_1",Co="_validation_mdphy_1 _ds-validation-message_5rpuv_1",ko="_body_mdphy_173",Ao="__checked_mdphy_1",$={alert:kn,app:An,sticky:Ln,avatar:In,badge:On,breadcrumbs:Mn,button:Rn,card:Pn,group:Dn,chip:Nn,details:Hn,dialog:Bn,_drawer:Fn,divider:Un,errorsummary:qn,_errorsummary:Vn,field:Gn,_datalist:Wn,affixes:zn,fieldset:Xn,fileupload:jn,helptext:Kn,input:Yn,law:Qn,grid:Jn,flex:Zn,link:to,logo:eo,pagination:no,popover:oo,progress:io,_indeterminate:so,skeleton:ao,_skeleton:ro,spinner:lo,steps:co,table:uo,_scrollShadow:fo,tabs:po,_scrollMask:mo,tag:ho,toast:go,_toastClose:bo,_toastOpen:vo,_toastTimeout:yo,togglegroup:_o,_tooltip:wo,heading:xo,ingress:Eo,muted:So,info:$o,prose:To,validation:Co,body:ko,_checked:Ao},zs=Object.freeze(Object.defineProperty({__proto__:null,_checked:Ao,_datalist:Wn,_drawer:Fn,_errorsummary:Vn,_indeterminate:so,_scrollMask:mo,_scrollShadow:fo,_skeleton:ro,_toastClose:bo,_toastOpen:vo,_toastTimeout:yo,_tooltip:wo,affixes:zn,alert:kn,app:An,avatar:In,badge:On,body:ko,breadcrumbs:Mn,button:Rn,card:Pn,chip:Nn,default:$,details:Hn,dialog:Bn,divider:Un,errorsummary:qn,field:Gn,fieldset:Xn,fileupload:jn,flex:Zn,grid:Jn,group:Dn,heading:xo,helptext:Kn,info:$o,ingress:Eo,input:Yn,law:Qn,link:to,logo:eo,muted:So,pagination:no,popover:oo,progress:io,prose:To,skeleton:ao,spinner:lo,steps:co,sticky:Ln,table:uo,tabs:po,tag:ho,toast:go,togglegroup:_o,validation:Co},Symbol.toStringTag,{value:"Module"})),gt=Math.min,P=Math.max,Yt=Math.round,Qt=Math.floor,V=t=>({x:t,y:t}),Xs={left:"right",right:"left",bottom:"top",top:"bottom"},js={start:"end",end:"start"};function Lo(t,e,n){return P(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 Io(t){return t==="x"?"y":"x"}function Oo(t){return t==="y"?"height":"width"}const Ks=new Set(["top","bottom"]);function Q(t){return Ks.has(it(t))?"y":"x"}function Mo(t){return Io(Q(t))}function Ys(t,e,n){n===void 0&&(n=!1);const o=Zt(t),i=Mo(t),s=Oo(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[ke(t),e,ke(e)]}function ke(t){return t.replace(/start|end/g,e=>js[e])}const Ro=["left","right"],Po=["right","left"],Js=["top","bottom"],Zs=["bottom","top"];function ta(t,e,n){switch(t){case"top":case"bottom":return n?e?Po:Ro:e?Ro:Po;case"left":case"right":return e?Js:Zs;default:return[]}}function ea(t,e,n,o){const i=Zt(t);let s=ta(it(t),n==="start",o);return i&&(s=s.map(a=>a+"-"+i),e&&(s=s.concat(s.map(ke)))),s}function te(t){return t.replace(/left|right|bottom|top/g,e=>Xs[e])}function na(t){return{top:0,right:0,bottom:0,left:0,...t}}function oa(t){return typeof t!="number"?na(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 Do(t,e,n){let{reference:o,floating:i}=t;const s=Q(e),a=Mo(e),r=Oo(a),l=it(e),c=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 m;switch(l){case"top":m={x:d,y:o.y-i.height};break;case"bottom":m={x:d,y:o.y+o.height};break;case"right":m={x:o.x+o.width,y:u};break;case"left":m={x:o.x-i.width,y:u};break;default:m={x:o.x,y:o.y}}switch(Zt(e)){case"start":m[a]-=p*(n&&c?-1:1);break;case"end":m[a]+=p*(n&&c?-1:1);break}return m}const ia=async(t,e,n)=>{const{placement:o="bottom",strategy:i="absolute",middleware:s=[],platform:a}=n,r=s.filter(Boolean),l=await(a.isRTL==null?void 0:a.isRTL(e));let c=await a.getElementRects({reference:t,floating:e,strategy:i}),{x:d,y:u}=Do(c,o,l),p=o,m={},h=0;for(let g=0;g<r.length;g++){const{name:_,fn:v}=r[g],{x:b,y,data:w,reset:E}=await v({x:d,y:u,initialPlacement:o,placement:p,strategy:i,middlewareData:m,rects:c,platform:a,elements:{reference:t,floating:e}});d=b??d,u=y??u,m={...m,[_]:{...m[_],...w}},E&&h<=50&&(h++,typeof E=="object"&&(E.placement&&(p=E.placement),E.rects&&(c=E.rects===!0?await a.getElementRects({reference:t,floating:e,strategy:i}):E.rects),{x:d,y:u}=Do(c,p,l)),g=-1)}return{x:d,y:u,placement:p,strategy:i,middlewareData:m}};async function Ae(t,e){var n;e===void 0&&(e={});const{x:o,y:i,platform:s,rects:a,elements:r,strategy:l}=t,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:p=!1,padding:m=0}=Jt(e,t),h=oa(m),_=r[p?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(r.floating)),boundary:c,rootBoundary:d,strategy:l})),b=u==="floating"?{x:o,y:i,width:a.floating.width,height:a.floating.height}:a.reference,y=await(s.getOffsetParent==null?void 0:s.getOffsetParent(r.floating)),w=await(s.isElement==null?void 0:s.isElement(y))?await(s.getScale==null?void 0:s.getScale(y))||{x:1,y:1}:{x:1,y:1},E=ee(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:r,rect:b,offsetParent:y,strategy:l}):b);return{top:(v.top-E.top+h.top)/w.y,bottom:(E.bottom-v.bottom+h.bottom)/w.y,left:(v.left-E.left+h.left)/w.x,right:(E.right-v.right+h.right)/w.x}}const sa=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:l,elements:c}=e,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:p,fallbackStrategy:m="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:g=!0,..._}=Jt(t,e);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const v=it(i),b=Q(r),y=it(r)===r,w=await(l.isRTL==null?void 0:l.isRTL(c.floating)),E=p||(y||!g?[te(r)]:Qs(r)),R=h!=="none";!p&&R&&E.push(...ea(r,g,h,w));const z=[r,...E],dt=await Ae(e,_),ut=[];let Y=((o=s.flip)==null?void 0:o.overflows)||[];if(d&&ut.push(dt[v]),u){const ft=Ys(i,a,w);ut.push(dt[ft[0]],dt[ft[1]])}if(Y=[...Y,{placement:i,overflows:ut}],!ut.every(ft=>ft<=0)){var Ot,Mt;const ft=(((Ot=s.flip)==null?void 0:Ot.index)||0)+1,on=z[ft];if(on&&(!(u==="alignment"?b!==Q(on):!1)||Y.every(q=>Q(q.placement)===b?q.overflows[0]>0:!0)))return{data:{index:ft,overflows:Y},reset:{placement:on}};let Pt=(Mt=Y.filter(pt=>pt.overflows[0]<=0).sort((pt,q)=>pt.overflows[1]-q.overflows[1])[0])==null?void 0:Mt.placement;if(!Pt)switch(m){case"bestFit":{var Rt;const pt=(Rt=Y.filter(q=>{if(R){const et=Q(q.placement);return et===b||et==="y"}return!0}).map(q=>[q.placement,q.overflows.filter(et=>et>0).reduce((et,rc)=>et+rc,0)]).sort((q,et)=>q[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{}}}},aa=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:_=>{let{x:v,y:b}=_;return{x:v,y:b}}},...l}=Jt(t,e),c={x:n,y:o},d=await Ae(e,l),u=Q(it(i)),p=Io(u);let m=c[p],h=c[u];if(s){const _=p==="y"?"top":"left",v=p==="y"?"bottom":"right",b=m+d[_],y=m-d[v];m=Lo(b,m,y)}if(a){const _=u==="y"?"top":"left",v=u==="y"?"bottom":"right",b=h+d[_],y=h-d[v];h=Lo(b,h,y)}const g=r.fn({...e,[p]:m,[u]:h});return{...g,data:{x:g.x-n,y:g.y-o,enabled:{[p]:s,[u]:a}}}}}},ra=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:l=()=>{},...c}=Jt(t,e),d=await Ae(e,c),u=it(i),p=Zt(i),m=Q(i)==="y",{width:h,height:g}=s.floating;let _,v;u==="top"||u==="bottom"?(_=u,v=p===(await(a.isRTL==null?void 0:a.isRTL(r.floating))?"start":"end")?"left":"right"):(v=u,_=p==="end"?"top":"bottom");const b=g-d.top-d.bottom,y=h-d.left-d.right,w=gt(g-d[_],b),E=gt(h-d[v],y),R=!e.middlewareData.shift;let z=w,dt=E;if((n=e.middlewareData.shift)!=null&&n.enabled.x&&(dt=y),(o=e.middlewareData.shift)!=null&&o.enabled.y&&(z=b),R&&!p){const Y=P(d.left,0),Ot=P(d.right,0),Mt=P(d.top,0),Rt=P(d.bottom,0);m?dt=h-2*(Y!==0||Ot!==0?Y+Ot:P(d.left,d.right)):z=g-2*(Mt!==0||Rt!==0?Mt+Rt:P(d.top,d.bottom))}await l({...e,availableWidth:dt,availableHeight:z});const ut=await a.getDimensions(r.floating);return h!==ut.width||g!==ut.height?{reset:{rects:!0}}:{}}}};function ne(){return typeof window<"u"}function bt(t){return No(t)?(t.nodeName||"").toLowerCase():"#document"}function D(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function G(t){var e;return(e=(No(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function No(t){return ne()?t instanceof Node||t instanceof D(t).Node:!1}function H(t){return ne()?t instanceof Element||t instanceof D(t).Element:!1}function W(t){return ne()?t instanceof HTMLElement||t instanceof D(t).HTMLElement:!1}function Ho(t){return!ne()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof D(t).ShadowRoot}const la=new Set(["inline","contents"]);function xt(t){const{overflow:e,overflowX:n,overflowY:o,display:i}=B(t);return/auto|scroll|overlay|hidden|clip/.test(e+o+n)&&!la.has(i)}const ca=new Set(["table","td","th"]);function da(t){return ca.has(bt(t))}const ua=[":popover-open",":modal"];function oe(t){return ua.some(e=>{try{return t.matches(e)}catch{return!1}})}const fa=["transform","translate","scale","rotate","perspective"],pa=["transform","translate","scale","rotate","perspective","filter"],ma=["paint","layout","strict","content"];function Le(t){const e=Ie(),n=H(t)?B(t):t;return fa.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)||pa.some(o=>(n.willChange||"").includes(o))||ma.some(o=>(n.contain||"").includes(o))}function ha(t){let e=J(t);for(;W(e)&&!vt(e);){if(Le(e))return e;if(oe(e))return null;e=J(e)}return null}function Ie(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const ga=new Set(["html","body","#document"]);function vt(t){return ga.has(bt(t))}function B(t){return D(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||Ho(t)&&t.host||G(t);return Ho(e)?e.host:e}function Bo(t){const e=J(t);return vt(e)?t.ownerDocument?t.ownerDocument.body:t.body:W(e)&&xt(e)?e:Bo(e)}function Et(t,e,n){var o;e===void 0&&(e=[]),n===void 0&&(n=!0);const i=Bo(t),s=i===((o=t.ownerDocument)==null?void 0:o.body),a=D(i);if(s){const r=Oe(a);return e.concat(a,a.visualViewport||[],xt(i)?i:[],r&&n?Et(r):[])}return e.concat(i,Et(i,[],n))}function Oe(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function Fo(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=Yt(n)!==s||Yt(o)!==a;return r&&(n=s,o=a),{width:n,height:o,$:r}}function Me(t){return H(t)?t:t.contextElement}function yt(t){const e=Me(t);if(!W(e))return V(1);const n=e.getBoundingClientRect(),{width:o,height:i,$:s}=Fo(e);let a=(s?Yt(n.width):n.width)/o,r=(s?Yt(n.height):n.height)/i;return(!a||!Number.isFinite(a))&&(a=1),(!r||!Number.isFinite(r))&&(r=1),{x:a,y:r}}const ba=V(0);function Uo(t){const e=D(t);return!Ie()||!e.visualViewport?ba:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function va(t,e,n){return e===void 0&&(e=!1),!n||e&&n!==D(t)?!1:e}function st(t,e,n,o){e===void 0&&(e=!1),n===void 0&&(n=!1);const i=t.getBoundingClientRect(),s=Me(t);let a=V(1);e&&(o?H(o)&&(a=yt(o)):a=yt(t));const r=va(s,n,o)?Uo(s):V(0);let l=(i.left+r.x)/a.x,c=(i.top+r.y)/a.y,d=i.width/a.x,u=i.height/a.y;if(s){const p=D(s),m=o&&H(o)?D(o):o;let h=p,g=Oe(h);for(;g&&o&&m!==h;){const _=yt(g),v=g.getBoundingClientRect(),b=B(g),y=v.left+(g.clientLeft+parseFloat(b.paddingLeft))*_.x,w=v.top+(g.clientTop+parseFloat(b.paddingTop))*_.y;l*=_.x,c*=_.y,d*=_.x,u*=_.y,l+=y,c+=w,h=D(g),g=Oe(h)}}return ee({width:d,height:u,x:l,y:c})}function se(t,e){const n=ie(t).scrollLeft;return e?e.left+n:st(G(t)).left+n}function qo(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 ya(t){let{elements:e,rect:n,offsetParent:o,strategy:i}=t;const s=i==="fixed",a=G(o),r=e?oe(e.floating):!1;if(o===a||r&&s)return n;let l={scrollLeft:0,scrollTop:0},c=V(1);const d=V(0),u=W(o);if((u||!u&&!s)&&((bt(o)!=="body"||xt(a))&&(l=ie(o)),W(o))){const m=st(o);c=yt(o),d.x=m.x+o.clientLeft,d.y=m.y+o.clientTop}const p=a&&!u&&!s?qo(a,l):V(0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+d.x+p.x,y:n.y*c.y-l.scrollTop*c.y+d.y+p.y}}function _a(t){return Array.from(t.getClientRects())}function wa(t){const e=G(t),n=ie(t),o=t.ownerDocument.body,i=P(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),s=P(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight);let a=-n.scrollLeft+se(t);const r=-n.scrollTop;return B(o).direction==="rtl"&&(a+=P(e.clientWidth,o.clientWidth)-i),{width:i,height:s,x:a,y:r}}const Vo=25;function xa(t,e){const n=D(t),o=G(t),i=n.visualViewport;let s=o.clientWidth,a=o.clientHeight,r=0,l=0;if(i){s=i.width,a=i.height;const d=Ie();(!d||d&&e==="fixed")&&(r=i.offsetLeft,l=i.offsetTop)}const c=se(o);if(c<=0){const d=o.ownerDocument,u=d.body,p=getComputedStyle(u),m=d.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,h=Math.abs(o.clientWidth-u.clientWidth-m);h<=Vo&&(s-=h)}else c<=Vo&&(s+=c);return{width:s,height:a,x:r,y:l}}const Ea=new Set(["absolute","fixed"]);function Sa(t,e){const n=st(t,!0,e==="fixed"),o=n.top+t.clientTop,i=n.left+t.clientLeft,s=W(t)?yt(t):V(1),a=t.clientWidth*s.x,r=t.clientHeight*s.y,l=i*s.x,c=o*s.y;return{width:a,height:r,x:l,y:c}}function Go(t,e,n){let o;if(e==="viewport")o=xa(t,n);else if(e==="document")o=wa(G(t));else if(H(e))o=Sa(e,n);else{const i=Uo(t);o={x:e.x-i.x,y:e.y-i.y,width:e.width,height:e.height}}return ee(o)}function Wo(t,e){const n=J(t);return n===e||!H(n)||vt(n)?!1:B(n).position==="fixed"||Wo(n,e)}function $a(t,e){const n=e.get(t);if(n)return n;let o=Et(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),l=Le(a);!l&&r.position==="fixed"&&(i=null),(s?!l&&!i:!l&&r.position==="static"&&!!i&&Ea.has(i.position)||xt(a)&&!l&&Wo(t,a))?o=o.filter(d=>d!==a):i=r,a=J(a)}return e.set(t,o),o}function Ta(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],l=a.reduce((c,d)=>{const u=Go(e,d,i);return c.top=P(u.top,c.top),c.right=gt(u.right,c.right),c.bottom=gt(u.bottom,c.bottom),c.left=P(u.left,c.left),c},Go(e,r,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Ca(t){const{width:e,height:n}=Fo(t);return{width:e,height:n}}function ka(t,e,n){const o=W(e),i=G(e),s=n==="fixed",a=st(t,!0,s,e);let r={scrollLeft:0,scrollTop:0};const l=V(0);function c(){l.x=se(i)}if(o||!o&&!s)if((bt(e)!=="body"||xt(i))&&(r=ie(e)),o){const m=st(e,!0,s,e);l.x=m.x+e.clientLeft,l.y=m.y+e.clientTop}else i&&c();s&&!o&&i&&c();const d=i&&!o&&!s?qo(i,r):V(0),u=a.left+r.scrollLeft-l.x-d.x,p=a.top+r.scrollTop-l.y-d.y;return{x:u,y:p,width:a.width,height:a.height}}function Re(t){return B(t).position==="static"}function zo(t,e){if(!W(t)||B(t).position==="fixed")return null;if(e)return e(t);let n=t.offsetParent;return G(t)===n&&(n=n.ownerDocument.body),n}function Xo(t,e){const n=D(t);if(oe(t))return n;if(!W(t)){let i=J(t);for(;i&&!vt(i);){if(H(i)&&!Re(i))return i;i=J(i)}return n}let o=zo(t,e);for(;o&&da(o)&&Re(o);)o=zo(o,e);return o&&vt(o)&&Re(o)&&!Le(o)?n:o||ha(t)||n}const Aa=async function(t){const e=this.getOffsetParent||Xo,n=this.getDimensions,o=await n(t.floating);return{reference:ka(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function La(t){return B(t).direction==="rtl"}const Ia={convertOffsetParentRelativeRectToViewportRelativeRect:ya,getDocumentElement:G,getClippingRect:Ta,getOffsetParent:Xo,getElementRects:Aa,getClientRects:_a,getDimensions:Ca,getScale:yt,isElement:H,isRTL:La};function jo(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function Oa(t,e){let n=null,o;const i=G(t);function s(){var r;clearTimeout(o),(r=n)==null||r.disconnect(),n=null}function a(r,l){r===void 0&&(r=!1),l===void 0&&(l=1),s();const c=t.getBoundingClientRect(),{left:d,top:u,width:p,height:m}=c;if(r||e(),!p||!m)return;const h=Qt(u),g=Qt(i.clientWidth-(d+p)),_=Qt(i.clientHeight-(u+m)),v=Qt(d),y={rootMargin:-h+"px "+-g+"px "+-_+"px "+-v+"px",threshold:P(0,gt(1,l))||1};let w=!0;function E(R){const z=R[0].intersectionRatio;if(z!==l){if(!w)return a();z?a(!1,z):o=setTimeout(()=>{a(!1,1e-7)},1e3)}z===1&&!jo(c,t.getBoundingClientRect())&&a(),w=!1}try{n=new IntersectionObserver(E,{...y,root:i.ownerDocument})}catch{n=new IntersectionObserver(E,y)}n.observe(t)}return a(!0),s}function Ma(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:l=!1}=o,c=Me(t),d=i||s?[...c?Et(c):[],...Et(e)]:[];d.forEach(v=>{i&&v.addEventListener("scroll",n,{passive:!0}),s&&v.addEventListener("resize",n)});const u=c&&r?Oa(c,n):null;let p=-1,m=null;a&&(m=new ResizeObserver(v=>{let[b]=v;b&&b.target===c&&m&&(m.unobserve(e),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var y;(y=m)==null||y.observe(e)})),n()}),c&&!l&&m.observe(c),m.observe(e));let h,g=l?st(t):null;l&&_();function _(){const v=st(t);g&&!jo(g,v)&&n(),g=v,h=requestAnimationFrame(_)}return n(),()=>{var v;d.forEach(b=>{i&&b.removeEventListener("scroll",n),s&&b.removeEventListener("resize",n)}),u?.(),(v=m)==null||v.disconnect(),m=null,l&&cancelAnimationFrame(h)}}const Ko=aa,Yo=sa,Ra=ra,Pa=(t,e,n)=>{const o=new Map,i={platform:Ia,...n},s={...i.platform,_c:o};return ia(t,e,{...i,platform:s})};function Qo(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=Qo(t[e]))&&(o&&(o+=" "),o+=n)}else for(n in t)t[n]&&(o&&(o+=" "),o+=n);return o}function Da(){for(var t,e,n=0,o="",i=arguments.length;n<i;n++)(t=arguments[n])&&(e=Qo(t))&&(o&&(o+=" "),o+=e);return o}const I={capture:!0,passive:!0},O=()=>typeof window<"u"&&typeof document<"u";function Na(t,e){let n;return function(...o){clearTimeout(n),n=setTimeout(()=>t.apply(this,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 Ha=0;const Ba=`${Date.now().toString(36)}${Math.random().toString(36).slice(2,5)}`;function ae(t){return t.id||(t.id=`${Ba}${++Ha}`),t.id}const Jo=(t,e,[...n])=>{for(const o of n[0].split(","))n[0]=o,e[`${t}EventListener`](...n)},T=(t,...e)=>(Jo("add",t,e),()=>Zo(t,...e)),Zo=(t,...e)=>Jo("remove",t,e),N=t=>{if(!O()||!window.requestAnimationFrame)return;window._mtdsCleanups||(window._mtdsCleanups=new Map);const e=()=>requestAnimationFrame(()=>{const n=String(t).replace(/(\n|\s)/g,"");window._mtdsCleanups?.get(n)?.map(o=>o()),window._mtdsCleanups?.set(n,t())});document.readyState==="complete"?e():T(window,"load",e)},Pe=new WeakMap,Fa=`.${$.dialog.split(" ")[0]}`;function at(t,e,{contain:n,middleware:o,placement:i,...s}={}){if(Pe.get(t)?.(),Pe.delete(t),e){const a=t.closest(Fa)?.querySelector(":scope > footer"),r=Number(f(t,"data-inset"))||20,c={bottom:(a?.clientHeight||0)+r,left:r,right:r,top:r},d=f(t,"data-position")??"bottom";Pe.set(t,Ma(e,t,()=>{if(!t.isConnected||!e.isConnected||t.hidden)return at(t,!1);Pa(e,t,{...s,placement:i||d,middleware:[Yo({padding:c}),Ko(),...n?[Ra({padding:c,apply:n})]:[],...o||[]]}).then(({x:u,y:p})=>{t.style.left=`${u}px`,t.style.top=`${p}px`})}))}}function Z(t,e){let n=0;const o=Array.isArray(e)||typeof e=="string"?{attr:e}:e,i=()=>setTimeout(s,o?.delay??200),s=()=>{if(!O())return r();t(a),a.takeRecords(),n=0},a=new MutationObserver(()=>{n||(n=requestAnimationFrame(i))}),r=()=>{try{a.disconnect()}catch{}};return a.observe(o?.root||document.documentElement,{attributeFilter:[].concat(o.attr),attributes:!0,childList:!0,subtree:!0}),t(a),r}function Ua(t,e){const n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()}const De=t=>t instanceof HTMLElement&&"validity"in t&&!(t instanceof HTMLButtonElement),k=(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},qa=typeof HTMLElement>"u"?class{}:HTMLElement,Va=(t,e)=>!O()||window.customElements.get(t)||window.customElements.define(t,e),Ga=`.${$.breadcrumbs.split(" ")[0]}`,Wa=`.${$.card.split(" ")[0]}`,ti=`.${$.chip.split(" ")[0]}`,za=`.${$.helptext.split(" ")[0]}`,Xa=`.${$.pagination.split(" ")[0]}`,ja='summary,u-summary,a,button,[role="tab"],[role="button"]',Ka="click,toggle,submit,change",Ne="mattilsynet.matomo.cloud",Ya=["setCustomUrl","setDocumentTitle","setReferrerUrl"],F="mtds-analytics-banner",Qa="https://www.mattilsynet.no/om-mattilsynet/personvernerklaering/informasjonskapsler";function ei(t,e={}){if(O()){if(window._paq||(window._paq=[],window._paq.push(["HeatmapSessionRecording::disable"]),window._paq.push(["enableLinkTracking"]),window._paq.push(["setTrackerUrl",`https://${Ne}/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"&&Ja();const a=s?`https://cdn.matomo.cloud/${Ne}/container_${s}.js`:`https://cdn.matomo.cloud/${Ne}/matomo.js`;document.querySelector(`script[src="${a}"]`)||document.head.append(k("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(l=>l!==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 if(t==="matomo"){const n=e;Ya.includes(n?.[0])&&typeof n[1]!="string"&&(n[1]=`${n[1]??""}`),window._paq.push(n)}}}}function Ja(){if(document.getElementById(F)||window.localStorage.getItem(F))return;document.body.insertAdjacentHTML("afterbegin",`<dialog id="${F}" data-analytics="ignore"><style>
|
|
9
9
|
#${F}[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
|
#${F} 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
|
#${F} button:focus-visible { outline: 2px solid }
|
|
@@ -13,9 +13,9 @@ var mtds=function(C){"use strict";var ls=Object.defineProperty,sn=Object.getOwnP
|
|
|
13
13
|
#${F} button:active { background: #054449; scale: .9 }
|
|
14
14
|
#${F} p { margin: 0 .25em }
|
|
15
15
|
</style>
|
|
16
|
-
<p>Vi bruker <a href="${
|
|
16
|
+
<p>Vi bruker <a href="${Qa}" target="_blank">informasjonskapsler</a> for å forbedre brukeropplevelsen.</p>
|
|
17
17
|
<form method="dialog" data-analytics="ignore"><button type="submit" aria-label="OK">×</button></form>
|
|
18
|
-
</dialog>`);const e=document.getElementById(F),n=()=>window.localStorage.setItem(F,"seen");e.addEventListener("close",n,{once:!0}),e.show()}function
|
|
18
|
+
</dialog>`);const e=document.getElementById(F),n=()=>window.localStorage.setItem(F,"seen");e.addEventListener("close",n,{once:!0}),e.show()}function Za(t){window._mtdsTracking?.enabled&&setTimeout(tr,0,t)}function tr({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)||or(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)||St(r?.querySelector("legend"))||St(n?.labels?.[0])}else if(f(n,"role")==="tab")i="Tab",o="navigate";else if(f(n,"popovertarget")){if(!er(n)?.matches(":popover-open"))return;i=n.closest(za)?"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=nr(n,"--mtds-tooltip-position")==="none";i="Sidebar",o=a?"expand":"minimize",s=a&&f(n,"data-tooltip")||St(n)}else if(n.closest(Ga))i="Breadcrumbs",o="navigate";else if(n.closest(Xa))i="Pagintation",o="navigate";else if(n.closest(Wa))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"}else n.nodeName.startsWith("MTDS-ATLAS-")&&(i="Map Marker",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 St=t=>t?.textContent?.trim()||"",ni=t=>t&&f(t,"aria-label")||"",er=t=>document.getElementById(f(t,"popovertarget")||""),nr=(t,e)=>window.getComputedStyle(t).getPropertyValue(e)?.trim(),or=t=>{const e=St(t),n=St(t.querySelector("h1,h2,h3,h4,h5,h6"));return e.startsWith(n)&&n||e.slice(0,100).trim()};N(()=>[T(document,Ka,Za,I)]),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=$.app.split(" ")[0],ir=$.sticky.split(" ")[0],sr='[data-command="toggle-app-expanded"]',He=`.${oi} > dialog,.${oi} dialog ~ main`,ii=O()?document.getElementsByClassName(ir):[],si=t=>{document.startViewTransition?document.startViewTransition(t):t()},ai=t=>si(()=>window.mtdsToggleAppExpanded?.(t));function ar({target:t,defaultPrevented:e}){const n=t?.closest?.("a");if(n?.closest("dialog")&&n?.closest(He))return ri();if(e||!(t instanceof HTMLButtonElement)||!t.matches(sr))return;getComputedStyle(t).position==="sticky"?ai():si(()=>{const i=document.querySelector(He);i?.setAttribute("data-closedby","any"),i?.showModal()})}function ri(){document.querySelector(He)?.close()}let Be=0,_t,X=0,Fe=0,re=0,Ue=!1,qe=0,rt=0;function rr(){if(!ii?.length)return;const t=ii[0],e=window.scrollY,n=e<rt;rt=e,n!==_t&&(Be=(t.parentElement?.getBoundingClientRect().top||0)+rt,_t=n,Fe=t.offsetHeight,re=t.getBoundingClientRect().top+rt,Ue=t.offsetHeight<=window.innerHeight,qe=window.innerHeight),!(X===-1&&Ue)&&(X!==-1&&(Ue||_t&&rt<=re)?(t.style.setProperty("--pos","sticky"),t.style.setProperty("--top","0px"),X=-1):X===-1&&!_t?(t.style.setProperty("--pos","relative"),t.style.setProperty("--top",`${Math.max(0,rt-Be)}px`),X=0):X!==1&&!_t&&rt+qe>=re+Fe?(t.style.setProperty("--pos","sticky"),t.style.setProperty("--top",`${qe-Fe}px`),X=1):X===1&&_t&&(t.style.setProperty("--pos","relative"),t.style.setProperty("--top",`${re-Be}px`),X=0))}N(()=>[T(document,"click",ar,I),T(window,"resize",Na(ri,100),I),T(window,"scroll",rr,I)]);const lr=/<[^>]+\bid="([^"]+)[^>]+>/gi,li=/\([^)]{1,4}\).{1,9}\d+\/\d+/i,cr=/<(h\d|[^>]+role="heading")[^>]*>(.*?)<\/?(h\d|br|div)/i,dr=/kapittel-\d+-ledd-\d+/,ur=/<button[^>]+>.*?<\/button>/g,fr=/►m\d+/i,le=/<[^>]+>/g,pr=/<dt([^>]*class="([^"]+)")?[^>]*>(.*?)<\/dt><dd[^>]*>(.*?)<\/dd>/gis,mr=/<(\/?)(article|footer|section)/gi,hr=/(src|href)="([^"]+)"/gi,gr=/(<li[^>]*)>\s*<div([^>]*>)|<\/div>(<\/li>)/gi,br=/(<li[^>]+data-name="([^"]+)[^>]+>)(\s*<(ul|ol|div)[^>]+>)/gis,vr=/(<[^>]+class="[^"]*\bnumberedLegalP\b[^>]+>\s*)(\d+\.)(.*?)(?=<\/?(ul|ol|div)|$)/gis,ci="https://lovdata.no/",yr={legacyid:{label:"Datokode",value:""},titleshort:{label:"Korttittel",value:""},title:{label:"Tittel",value:""},url:{label:"Url",value:""}},Ve=t=>Array.from(Array.isArray(t)?t:[t],e=>e instanceof HTMLButtonElement?e.value:e),_r=t=>Array.from(t?.querySelectorAll('button[aria-checked="true"]')||[],e=>e.value),wr=(t,e)=>{const n=Ve(t);e?.querySelectorAll("button").forEach(o=>{n.includes(o.value)&&f(o,"aria-checked",`${f(o,"aria-checked")!=="true"}`)})},xr=(t,e)=>{const n=Ve(t);e?.querySelectorAll("button").forEach(o=>{f(o,"aria-checked",`${n.includes(o.value)||!1}`)})},Er=(t,e)=>{const n=di(e);return Ve(t).map(o=>$r(o,n)).filter(o=>!!o)},Sr=t=>{const e=t.slice(0,t.indexOf("</dl>")),n={...yr};for(const o of e.matchAll(pr)){const i=o[2].replace(/-/g,"").toLowerCase();n[i]={label:o[3],value:o[4]}}return n},di=t=>t.includes("<main")?(t.split(/<\/?main[^>]*>/)[1]||"").replace(mr,"<$1div").replace(gr,"$1$2$3").replace(hr,(e,n,o)=>`${n}="${o.includes(":")?"":ci}${o}" ${n==="href"?'rel="noopener noreferrer" target="_blank"':""}`).replace(vr,(e,n,o,i)=>`${n}<span class="data-originalId">${o}</span><div class="legalP" id="${lt("id",n)}-ledd-0">${i}</div>`).replace(br,(e,n,o,i)=>`${n}<span class="data-originalId">${o}</span>${i}`).replace(lr,(e,n,o,i)=>{const s=ui(e,n,o,i);return`${e}${s?`<button type="button" role="checkbox" aria-label="${s}" value="${n}"></button>`:""}`}):t,$r=(t,e)=>{const n=dr.test(t),o=t.split("-").map((r,l,c)=>l%2?Tr(c.slice(0,l+1).join("-"),e,n):null).filter(r=>!!r);if(!o.length)return null;const i=o.filter(({url:r})=>r).pop()?.url||"",s=o.filter(r=>r.className==="section"&&li.test(r.label)),a=o.slice(o.indexOf(s.pop()||o[0])).map(r=>r.label).join(", ");return{...o.slice(-1)[0],path:o,label:a,url:i}},Tr=(t,e,n)=>{const o=e.lastIndexOf("<",e.indexOf(` id="${t}"`)),i=e.slice(o,e.indexOf(">",o)+1),s=lt("class",i),a=lt("data-lovdata-url",i),r=ui(i,t,o,e);return{id:t,className:s,html:Cr(t,e),url:a?`${ci}${a}`:"",label:!n&&s==="section"&&r?.match(li)?.[0]||r}},lt=(t,e)=>{const n=` ${t.toLowerCase()}="`,o=e.toLowerCase().indexOf(n),i=o+n.length;return o===-1?"":e.slice(i,e.indexOf('"',i))},Cr=(t,e)=>{const n=e.lastIndexOf("<",e.indexOf(` id="${t}"`)),o=e.length;let i=n+1,s=0;for(;i&&i<o;)if(i=e.indexOf("<",i)+1,e[i]!=="/")s++;else if(--s<0)break;const a=e.indexOf(">",i)+1;return i?e.slice(n,a).replace(ur,""):""},ui=(t,e,n,o)=>kr[lt("class",t)]?.(t,e,n,o)||"",kr={numberedLegalP:t=>`nr. ${lt("data-numerator",t)}.`,section:(t,e,n,o)=>o.slice(n).match(cr)?.[2]?.replace(le,"")?.replace(fr,"").trim()||"",legalArticle:(t,e,n,o)=>{const i=o.indexOf(">",o.indexOf("legalArticleValue",n));return o.slice(i+1,o.indexOf("</span>",i)).replace(le,"").replace("Artikkel","artikkel")},legalP:(t,e)=>{const[n,o,i,s]=e.split("-").reverse();return`avsnitt ${(o==="nummer"?1:Number(n))+(s==="nummer"?1:0)}`},listArticle:(t,e,n,o)=>{const i=e.split("-"),s=` id="${i.slice(0,-2).join("-")}"`,a=o.lastIndexOf(s,n),r=o.slice(o.indexOf("<ol",a),n),l=lt("data-name",t)||"-",c=lt("type",r)||"-";let d="punkt";return c==="1"&&(d="tall"),c==="a"&&(d="bokstav"),c==="i"&&(d="romtertall"),`${d} ${l==="-"?i.pop():l.replace(le,"")}`},marginIdArticle:(t,e,n,o)=>{const i=o.indexOf(">",o.indexOf("data-marginOriginalId",n));return`nr. ${o.slice(i+1,o.indexOf("</span>",i)).replace(le,"")}`}},Ar=(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,l)=>l+i);return n>4&&i>1&&a.splice(0,2,1,0),n>3&&s<e&&a.splice(-2,2,0,e),a},Lr=({current:t=1,total:e=10,show:n=7})=>({prev:t>1?t-1:0,next:t<e?t+1:0,pages:Ar(t,e,n).map((o,i)=>({current:o===t&&"page",key:`key-${o}-${i}`,page:o}))});function A(t,e={}){const n=document.getElementById(e.id||"")||k("dialog");return f(n,"aria-busy",e.busy?"true":null),f(n,"class",Da($.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",Ir,{once:!0}),document.body.appendChild(n),n.id}function Ir({animationName:t,target:e}){t===$._toastClose&&e.remove()}A.success=(t,e)=>A(t,{color:"success",...e}),A.danger=(t,e)=>A(t,{color:"danger",...e}),A.info=(t,e)=>A(t,{color:"info",...e}),A.warning=(t,e)=>A(t,{color:"warning",...e}),A.neutral=(t,e)=>A(t,{color:"neutral",...e}),A.promise=async function(e,n){const{loading:o,success:i,error:s,...a}=n,r=A(o,{busy:!0,...a});try{const l=await e();return A.success(i,{id:r,busy:!1}),l}catch(l){throw A.danger(s,{id:r,busy:!1}),l}};const Or=$.breadcrumbs.split(" ")[0],fi=O()?document.getElementsByClassName(Or):[];function Mr(){if(fi)for(const t of fi)t.querySelectorAll("a").forEach((e,n,{length:o})=>{f(e,"aria-current",n===o-1?"page":null)})}N(()=>[Z(Mr,"class")]);const Rr=`/* NOTE: Using --mtds- not --mtds- since we're inside shadow dom */
|
|
19
19
|
:host(:not([hidden])) { display: grid; gap: var(--mtds-6) }
|
|
20
20
|
[data-event] { cursor: pointer } /* Used to forward clicks from Chart ShaowDOM to relevant cell in child table */
|
|
21
21
|
|
|
@@ -182,17 +182,17 @@ var mtds=function(C){"use strict";var ls=Object.defineProperty,sn=Object.getOwnP
|
|
|
182
182
|
vertical-align: middle;
|
|
183
183
|
width: var(--mtds-5);
|
|
184
184
|
}
|
|
185
|
-
`,Rr=[.1,.2,.25,.5,1];function Pr(t,{aspect:e,type:n}){const i=n==="stacked",s=t[0].reduce((h,g,_)=>{const v=t.map(y=>y[_].number),b=v.reduce((y,w)=>y+w,0);return Math.max(h,...i?[b]:v)},0),a=s/10,r=10**`${Math.round(a)}`.length,c=a/r,l=(Rr.find(h=>h>c)||1)*r,d=Math.ceil(s/l)*l,u=k("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(k("div",{class:"axisSteps"})),m=u.appendChild(k("div",{class:"axisGroups"}));return Array.from({length:d/l+1},(h,g)=>Dr(l*g)).reverse().map(h=>p.append(k("div",{class:"axisStep","data-label":h}))),{total:d,groups:m,axis:u}}const Dr=new Intl.NumberFormat().format;function Nr(t){return t[0].slice(1).map(({value:e,event:n},o)=>{const i=k("div",{class:"axisGroup","data-label":e}),s=i.appendChild(k("div",{class:"axisGroupContent"}));return t.slice(1).map(a=>a[o+1]).map(({tooltip:a,style:r,number:c})=>s.appendChild(k("div",{"aria-label":a,"data-event":n,class:"bar",role:"img",style:`${r}; --value: ${c}`,tabindex:"0"}))),i})}function Hr(t,{total:e,type:n,variant:o}){const i=Number.parseFloat(n||"0")||0,s=k("div",{class:"axisGroup"});return t.slice(1).forEach(([,...a])=>{const r=k("div",{class:"lineContainer",role:"list",style:a[0].style}),c=Br(a.map(({number:u},p,{length:m})=>[100/(m-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:m})=>{const h=k("div",{role:"listitem"});h.appendChild(k("div",{"aria-label":p,"data-event":m,tabindex:"0",class:"linePoint",role:"img",style:`--value: ${u}`})),r.append(h)}),r.appendChild(l).append(d),s.append(r)}),s}const Br=(t,e)=>t.map(([n,o],i,s)=>i?Fr(i,s,e):`M${n},${o}`).join(" "),pi=([t,e],[n,o])=>[t+n,e+o],mi=([t,e],[n,o])=>[t-n,e-o],hi=(t,[e,n])=>[t*e,t*n],Fr=(t,e,n)=>{const o=e[t-1],i=e[t],[s,a]=pi(o,hi(n,mi(i,e[t-2]||o))),[r,c]=pi(i,hi(n,mi(o,e[t+1]||i)));return`C ${s},${a} ${r},${c} ${i[0]},${i[1]}`};function Ur(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"),m=i/r;i+=l;const h=Math.min(i/r,.99999),g=h-m>.5?1:0,_=2*Math.PI*(m-.25),v=2*Math.PI*(h-.25),b=Math.cos(_),y=Math.sin(_),w=Math.cos(v),E=Math.sin(v),R=`M ${s+a*b} ${s+a*y} L ${s+s*b} ${s+s*y} 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*y}`;f(p,"aria-label",c),f(p,"data-event",d),f(p,"style",u),f(p,"d",R),f(p,"role","img"),f(p,"tabindex","0"),o.appendChild(p)}),o}const gi="click,keydown,mousemove,mouseout",bi="mtds-chart-tooltip",tt=O()?document.getElementById(bi)||k("div",{"aria-hidden":"true",class:$._tooltip,hidden:"",id:bi}):null;class Vr extends Ua{#t;#e;static get observedAttributes(){return["data-variant","data-aspect"]}constructor(){super(),this.attachShadow({mode:"open"})}connectedCallback(){this.#e=Fa(()=>this.handleResize(),this),this.#t=Z(()=>this.attributeChangedCallback(),{attr:"data-tooltip",root:this}),this.attributeChangedCallback(),T(this,gi,this)}disconnectedCallback(){tt&&(tt.hidden=!0),Zo(this,gi,this),this.#e?.(),this.#t?.(),this.#t=this.#e=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=Wr(this.querySelector("table")),s=k("style",{},Mr),a=k("div",{"aria-hidden":"hidden",class:"legends",role:"group"});i.slice(1).forEach(([{value:d,style:u}])=>{a.appendChild(k("div",{class:"legend",style:u},d))});const{axis:r,groups:c,total:l}=Pr(i,{aspect:o,type:n});(e==="column"||e==="bar")&&c.append(...Nr(i)),(e==="line"||e==="area")&&c.append(Hr(i,{total:l,variant:e,type:n})),(e==="doughnut"||e==="pie")&&this.shadowRoot?.append(Ur(i,{aspect:o,variant:e})),this.shadowRoot?.append(r,a,s)}handleEvent(e){e.type==="click"||e.type==="keydown"?qr(e,this):Gr(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 qr(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 vi="";function Gr(t){if(!tt)return;tt?.isConnected||document.body.append(tt);const e=t.composedPath()[0],n=e instanceof Element&&e.getAttribute("aria-label")||"";n&&(tt.style.transform=`translate(${t.pageX}px, ${t.pageY}px)`),n!==vi&&(n&&(tt.textContent=n),vi=n,tt.hidden=!n)}const $t=t=>t?.textContent?.trim()||"",Wr=t=>Array.from(t?.rows||[],(e,n)=>Array.from(e.cells,(o,i)=>{const s=$t(e.cells[0]),a=$t(t?.rows[0].cells[i]),r=`${s}: ${$t(o)}${a?` (${a})`:""}`;return{number:i&&n&&Number.parseFloat($t(o))||0,event:o.querySelector("a,button")&&`${n}-${i}`,style:`--color: var(--mtdsc-chart-color-${n}, var(--mtdsc-chart-color-base))`,value:$t(o),tooltip:f(o,"data-tooltip")||r}}));Va("mtds-chart",Vr);const zr=$.dialog.split(" ")[0],yi=O()?document.getElementsByClassName(zr):[];function Xr(){for(const t of yi)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()))}let Ge=!1;const jr=(t,{clientX:e=0,clientY:n=0})=>{const{top:o,right:i,bottom:s,left:a}=t.getBoundingClientRect();return o<=n&&n<=s&&a<=e&&e<=i};function Kr(t){const e=t.target?.closest?.("dialog");Ge=!!e&&jr(e,t)}function Yr({target:t}){for(const e of yi)e.open&&(e!==t&&e.contains(t)?t?.closest?.('[data-command="close"]'):!Ge&&f(e,"data-closedby")==="any")&&e.close();Ge=!1}N(()=>[T(document,"click",Yr,I),T(document,"pointerdown",Kr,I),Z(Xr,"open")]);function Qr(t){if(t.animationName!==$._errorsummary)return;const e=t.target?.firstElementChild;e instanceof HTMLHeadingElement&&(f(e,"tabindex","-1"),e.focus())}N(()=>[T(document,"animationend",Qr,I)]);var Jr=Object.defineProperty,_i=Object.getOwnPropertySymbols,Zr=Object.prototype.hasOwnProperty,tl=Object.prototype.propertyIsEnumerable,wi=(t,e,n)=>e in t?Jr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,el=(t,e)=>{for(var n in e||(e={}))Zr.call(e,n)&&wi(t,n,e[n]);if(_i)for(var n of _i(e))tl.call(e,n)&&wi(t,n,e[n]);return t},Tt=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",ce=Tt&&/android/i.test(navigator.userAgent),We=Tt&&/iPad|iPhone|iPod/.test(navigator.userAgent),xi;Tt&&/^Mac/i.test(((xi=navigator.userAgentData)==null?void 0:xi.platform)||navigator.platform);var nl=`${ce?"data":"aria"}-labelledby`,ol=":host(:not([hidden])) { display: block }",il="outline: 1px dotted; outline: 5px auto Highlight; outline: 5px auto -webkit-focus-ring-color",Ei=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 Si=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Ct=(t,...e)=>Si("add",t,e),de=(t,...e)=>Si("remove",t,e),sl=(t,e)=>t.shadowRoot||t.attachShadow({mode:"open"}).append(je("slot"),je("style",e)),ue=new WeakMap,ze=(t,e)=>{if(e===void 0)return ue.get(t);try{ue.get(t).disconnect(),ue.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),ue.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},al=0,Xe=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++al).toString(32)}`),t.id):"",je=(t,e,n)=>{const o=document.createElement(t);return e&&(o.textContent=e),o},Ti={define:(t,e)=>!Tt||window.customElements.get(t)||window.customElements.define(t,e)},ct,rl=0,Ci=t=>{ct||(ct=je("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}${rl++%2?" ":""}`)},ll=(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,Ye=t=>(t?.type==="mouseup"&&(Ke=!1),t?.type==="mousedown"&&(Ke=!0,Ct(document,"mouseup",Ye,{once:!0})),Ke),Qe="disabled",kt="selected",cl=class extends Ei{static get observedAttributes(){return[Qe,kt]}connectedCallback(){We||(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[kt]}set defaultSelected(t){this[kt]=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,kt)!==null}set selected(t){S(this,kt,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)}};Ti.define("u-option",cl);var dl=`${ol}
|
|
185
|
+
`,Pr=[.1,.2,.25,.5,1];function Dr(t,{aspect:e,type:n}){const i=n==="stacked",s=t[0].reduce((h,g,_)=>{const v=t.map(y=>y[_].number),b=v.reduce((y,w)=>y+w,0);return Math.max(h,...i?[b]:v)},0),a=s/10,r=10**`${Math.round(a)}`.length,l=a/r,c=(Pr.find(h=>h>l)||1)*r,d=Math.ceil(s/c)*c,u=k("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(k("div",{class:"axisSteps"})),m=u.appendChild(k("div",{class:"axisGroups"}));return Array.from({length:d/c+1},(h,g)=>Nr(c*g)).reverse().map(h=>p.append(k("div",{class:"axisStep","data-label":h}))),{total:d,groups:m,axis:u}}const Nr=new Intl.NumberFormat().format;function Hr(t){return t[0].slice(1).map(({value:e,event:n},o)=>{const i=k("div",{class:"axisGroup","data-label":e}),s=i.appendChild(k("div",{class:"axisGroupContent"}));return t.slice(1).map(a=>a[o+1]).map(({tooltip:a,style:r,number:l})=>s.appendChild(k("div",{"aria-label":a,"data-event":n,class:"bar",role:"img",style:`${r}; --value: ${l}`,tabindex:"0"}))),i})}function Br(t,{total:e,type:n,variant:o}){const i=Number.parseFloat(n||"0")||0,s=k("div",{class:"axisGroup"});return t.slice(1).forEach(([,...a])=>{const r=k("div",{class:"lineContainer",role:"list",style:a[0].style}),l=Fr(a.map(({number:u},p,{length:m})=>[100/(m-1)*p,100-u/e*100]),i/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 d=document.createElementNS("http://www.w3.org/2000/svg","path");if(f(d,"class","line"),f(d,"d",l),f(d,"fill","none"),f(d,"stroke","currentColor"),o==="area"){const u=d.cloneNode(!0);f(u,"d",`M-100,100 L${l.slice(1)}L200,100`),f(u,"class","lineShade"),c.append(u)}a.forEach(({number:u,tooltip:p,event:m})=>{const h=k("div",{role:"listitem"});h.appendChild(k("div",{"aria-label":p,"data-event":m,tabindex:"0",class:"linePoint",role:"img",style:`--value: ${u}`})),r.append(h)}),r.appendChild(c).append(d),s.append(r)}),s}const Fr=(t,e)=>t.map(([n,o],i,s)=>i?Ur(i,s,e):`M${n},${o}`).join(" "),pi=([t,e],[n,o])=>[t+n,e+o],mi=([t,e],[n,o])=>[t-n,e-o],hi=(t,[e,n])=>[t*e,t*n],Ur=(t,e,n)=>{const o=e[t-1],i=e[t],[s,a]=pi(o,hi(n,mi(i,e[t-2]||o))),[r,l]=pi(i,hi(n,mi(o,e[t+1]||i)));return`C ${s},${a} ${r},${l} ${i[0]},${i[1]}`};function qr(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((l,[,c])=>l+c.number,0);return t.slice(1).forEach(([,{tooltip:l,number:c,event:d,style:u}])=>{if(!c)return;const p=document.createElementNS("http://www.w3.org/2000/svg","path"),m=i/r;i+=c;const h=Math.min(i/r,.99999),g=h-m>.5?1:0,_=2*Math.PI*(m-.25),v=2*Math.PI*(h-.25),b=Math.cos(_),y=Math.sin(_),w=Math.cos(v),E=Math.sin(v),R=`M ${s+a*b} ${s+a*y} L ${s+s*b} ${s+s*y} 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*y}`;f(p,"aria-label",l),f(p,"data-event",d),f(p,"style",u),f(p,"d",R),f(p,"role","img"),f(p,"tabindex","0"),o.appendChild(p)}),o}const gi="click,keydown,mousemove,mouseout",bi="mtds-chart-tooltip",tt=O()?document.getElementById(bi)||k("div",{"aria-hidden":"true",class:$._tooltip,hidden:"",id:bi}):null;class Vr extends qa{#t;#e;static get observedAttributes(){return["data-variant","data-aspect"]}constructor(){super(),this.attachShadow({mode:"open"})}connectedCallback(){this.#e=Ua(()=>this.handleResize(),this),this.#t=Z(()=>this.attributeChangedCallback(),{attr:"data-tooltip",root:this}),this.attributeChangedCallback(),T(this,gi,this)}disconnectedCallback(){tt&&(tt.hidden=!0),Zo(this,gi,this),this.#e?.(),this.#t?.(),this.#t=this.#e=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=zr(this.querySelector("table")),s=k("style",{},Rr),a=k("div",{"aria-hidden":"hidden",class:"legends",role:"group"});i.slice(1).forEach(([{value:d,style:u}])=>{a.appendChild(k("div",{class:"legend",style:u},d))});const{axis:r,groups:l,total:c}=Dr(i,{aspect:o,type:n});(e==="column"||e==="bar")&&l.append(...Hr(i)),(e==="line"||e==="area")&&l.append(Br(i,{total:c,variant:e,type:n})),(e==="doughnut"||e==="pie")&&this.shadowRoot?.append(qr(i,{aspect:o,variant:e})),this.shadowRoot?.append(r,a,s)}handleEvent(e){e.type==="click"||e.type==="keydown"?Gr(e,this):Wr(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 Gr(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 vi="";function Wr(t){if(!tt)return;tt?.isConnected||document.body.append(tt);const e=t.composedPath()[0],n=e instanceof Element&&e.getAttribute("aria-label")||"";n&&(tt.style.transform=`translate(${t.clientX}px, ${t.clientY}px)`),n!==vi&&(n&&(tt.textContent=n),vi=n,tt.hidden=!n)}const $t=t=>t?.textContent?.trim()||"",zr=t=>Array.from(t?.rows||[],(e,n)=>Array.from(e.cells,(o,i)=>{const s=$t(e.cells[0]),a=$t(t?.rows[0].cells[i]),r=`${s}: ${$t(o)}${a?` (${a})`:""}`;return{number:i&&n&&Number.parseFloat($t(o))||0,event:o.querySelector("a,button")&&`${n}-${i}`,style:`--color: var(--mtdsc-chart-color-${n}, var(--mtdsc-chart-color-base))`,value:$t(o),tooltip:f(o,"data-tooltip")||r}}));Va("mtds-chart",Vr);const Xr=$.dialog.split(" ")[0],yi=O()?document.getElementsByClassName(Xr):[];function jr(){for(const t of yi)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()))}let Ge=!1;const Kr=(t,{clientX:e=0,clientY:n=0})=>{const{top:o,right:i,bottom:s,left:a}=t.getBoundingClientRect();return o<=n&&n<=s&&a<=e&&e<=i};function Yr(t){const e=t.target?.closest?.("dialog");Ge=!!e&&Kr(e,t)}function Qr({target:t}){for(const e of yi)e.open&&(e!==t&&e.contains(t)?t?.closest?.('[data-command="close"]'):!Ge&&f(e,"data-closedby")==="any")&&e.close();Ge=!1}N(()=>[T(document,"click",Qr,I),T(document,"pointerdown",Yr,I),Z(jr,"open")]);function Jr(t){if(t.animationName!==$._errorsummary)return;const e=t.target?.firstElementChild;e instanceof HTMLHeadingElement&&(f(e,"tabindex","-1"),e.focus())}N(()=>[T(document,"animationend",Jr,I)]);var Zr=Object.defineProperty,_i=Object.getOwnPropertySymbols,tl=Object.prototype.hasOwnProperty,el=Object.prototype.propertyIsEnumerable,wi=(t,e,n)=>e in t?Zr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,nl=(t,e)=>{for(var n in e||(e={}))tl.call(e,n)&&wi(t,n,e[n]);if(_i)for(var n of _i(e))el.call(e,n)&&wi(t,n,e[n]);return t},Tt=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",ce=Tt&&/android/i.test(navigator.userAgent),We=Tt&&/iPad|iPhone|iPod/.test(navigator.userAgent),xi;Tt&&/^Mac/i.test(((xi=navigator.userAgentData)==null?void 0:xi.platform)||navigator.platform);var ol=`${ce?"data":"aria"}-labelledby`,il=":host(:not([hidden])) { display: block }",sl="outline: 1px dotted; outline: 5px auto Highlight; outline: 5px auto -webkit-focus-ring-color",Ei=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 Si=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Ct=(t,...e)=>Si("add",t,e),de=(t,...e)=>Si("remove",t,e),al=(t,e)=>t.shadowRoot||t.attachShadow({mode:"open"}).append(je("slot"),je("style",e)),ue=new WeakMap,ze=(t,e)=>{if(e===void 0)return ue.get(t);try{ue.get(t).disconnect(),ue.delete(t)}catch{}if(e){const n=new MutationObserver(o=>t.handleEvent({type:"mutation",detail:o}));n.observe(t,e),ue.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},rl=0,Xe=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++rl).toString(32)}`),t.id):"",je=(t,e,n)=>{const o=document.createElement(t);return e&&(o.textContent=e),o},Ti={define:(t,e)=>!Tt||window.customElements.get(t)||window.customElements.define(t,e)},ct,ll=0,Ci=t=>{ct||(ct=je("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}${ll++%2?" ":""}`)},cl=(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,Ye=t=>(t?.type==="mouseup"&&(Ke=!1),t?.type==="mousedown"&&(Ke=!0,Ct(document,"mouseup",Ye,{once:!0})),Ke),Qe="disabled",kt="selected",dl=class extends Ei{static get observedAttributes(){return[Qe,kt]}connectedCallback(){We||(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[kt]}set defaultSelected(t){this[kt]=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,kt)!==null}set selected(t){S(this,kt,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)}};Ti.define("u-option",dl);var ul=`${il}
|
|
186
186
|
::slotted(u-option) { display: block; cursor: pointer }
|
|
187
|
-
::slotted(u-option:focus) { ${
|
|
187
|
+
::slotted(u-option:focus) { ${sl} }
|
|
188
188
|
::slotted(u-option[aria-hidden="true"]),
|
|
189
189
|
::slotted(u-option[disabled]),
|
|
190
|
-
::slotted(u-option[hidden]) { display: none !important }`,ki,Ai=0,ul=We||ce,Li="click,focusout,input,keydown,mousedown,mouseup",Ii="focus,focusin,blur,focusout",fe={singular:"%d hit",plural:"%d hits"},Oi=class extends Ei{constructor(){super(),this._texts=el({},fe),this._value="",sl(this,dl)}static get observedAttributes(){return["id",...Object.keys(fe).map(t=>`data-sr-${t}`)]}connectedCallback(){this.hidden=!0,this._root=$i(this),S(this,"role","listbox"),S(this,"tabindex","-1"),Ct(this._root,"focusin",this),Ct(this._root,"focus",this,!0),ze(this,{attributeFilter:["disabled","hidden","label","value"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),setTimeout(()=>this.attributeChangedCallback())}disconnectedCallback(){de(this._root||this,"focus",this,!0),de(this._root||this,"focusin",this),ze(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(fe[o])this._texts[o]=n||fe[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"&&ml(this,t),(n==="focus"||n==="focusin")&&fl(this,t),(n==="blur"||n==="focusout")&&pl(this,t),n==="keydown"&&hl(this,t),n==="mousedown"&&this.contains(e)&&Ye(t),(n==="mutation"||n==="input")&&(clearTimeout(Ai),Ai=setTimeout(Pi,0,this,t)))}get options(){return this.getElementsByTagName("u-option")}},Mi=t=>t?.disabled||t?.readOnly||!1,At=(t,e)=>{var n,o,i;if(t.hidden!==e)return;t.hidden=Mi(t?._input)||!e,(n=ze(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&&Pi(t)},Je=t=>{t._input&&(de(t._input||t,Ii,t),de(t._root||t,Li,t),At(t,!1),t._input=void 0)},Ze=(t,e,n=!1)=>{t.popover&&S(e,"popovertarget",Xe(t)),Ct(e,Ii,t,!0),S(e,"aria-autocomplete","list"),S(e,"aria-controls",Xe(t)),S(e,"aria-expanded",`${!ul||n}`),S(e,"autocomplete","off"),S(e,"role",Mi(e)?null:"combobox")},fl=(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,nl,Xe((n=t._input.labels)==null?void 0:n[0])),Ct(t._root||t,Li,t),At(t,S(t._input,"inputmode")!=="none"),Ci())},pl=(t,e)=>{!ce&&!Ye()&&t._input&&setTimeout(Ri,0,t),e.target===t._input&&e.isTrusted&&e.stopImmediatePropagation()},Ri=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))},ml=(t,{target:e})=>{var n;if(!t._input||t._input===e)return At(t,!0);for(const o of t.options)if(o.contains(e))return S(t,"aria-multiselectable")!=="true"&&((n=t._input)==null||n.focus(),At(t,!1)),ll(t._input,o.value);ce&&Ri(t)},hl=(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(),At(t,!l);const d=[...t.options].filter(m=>S(m,"aria-hidden")!=="true"&&m.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 m of d)m.tabIndex=-1;d[p]&&e.preventDefault(),(n=d[p]||t._input)==null||n.focus(),!d[p]&&o==="ArrowUp"&&setTimeout(()=>{var m;return(m=t._input)==null?void 0:m.setSelectionRange(999,999)})},Pi=(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(ki),e?.type==="input"&&a!==t._value&&(ki=setTimeout(()=>{const u=`${!d&&t.innerText.trim()||`${n[d===1?"singular":"plural"]}`.replace("%d",`${d}`)}`;!t.hidden&&o?.activeElement===i&&Ci(u),t._value=a},1e3)),We&&l.map((u,p)=>S(u,"title",`${p+1}/${d}`))};Tt&&Object.defineProperty(HTMLInputElement.prototype,"list",{configurable:!0,enumerable:!0,get(){return $i(this).getElementById(S(this,"list")||"")}}),Ti.define("u-datalist",Oi);const Di=$.field.split(" ")[0],Ni=$.validation.split(" "),gl=Ni[0],bl=O()?document.getElementsByClassName(Di):[];function Hi(t){let e=null;for(const n of bl)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:De(l)&&!l.hidden?r=l:l.hasAttribute("data-description")?i.push(l):l.classList.contains(gl)?(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){const l=a?.control;if((t||l?.validity.customError)&&f(n,"data-validation")==="form"){c=l?.getAttribute("aria-required")==="true"?!!a?.items.length:r.validity.valid,!e&&!c&&(e=r);for(const u of s)f(u,"hidden",c?"":null);l?.setCustomValidity(c?"":"Invalid")}for(const u of o)u.htmlFor=ae(r);vl(a),Fi(r),Bi(r),f(r,"aria-describedby",i.map(ae).join(" ")),f(r,"aria-invalid",`${!c}`)}}return t&&e?.focus(),e}function Bi(t){t instanceof HTMLTextAreaElement&&(t.style.setProperty("--mtds-textarea-height","auto"),t.style.setProperty("--mtds-textarea-height",`${t.scrollHeight}px`))}const U=(t,e)=>t.getPropertyValue(`--mtds-text-${e}`)?.slice(1,-1)||"";function vl(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",U(o,"combobox-added")),f(t,"data-sr-empty",U(o,"combobox-empty")),f(t,"data-sr-found",U(o,"combobox-found")),f(t,"data-sr-invalid",U(o,"combobox-invalid")),f(t,"data-sr-of",U(o,"combobox-of")),f(t,"data-sr-remove",U(o,"combobox-remove")),f(t,"data-sr-removed",U(o,"combobox-removed")),f(n,"data-sr-plural",U(o,"datalist-plural")),f(n,"data-sr-singular",U(o,"datalist-singular"))}n&&e&&!n.hasAttribute("popover")&&(f(n,"popover","manual"),f(e,"popovertarget",ae(n)))}function Fi(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=U(a,"count-over"),c=U(a,"count-under");if(s!==i){f(e,"aria-live",i?"polite":"off");for(const l of Ni)e.classList.toggle(l,i)}e.textContent=(i?r:c).replace("%d",`${Math.abs(o)}`)}}function yl({target:t,newState:e}){if(t instanceof Oi){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 _l(t){De(t.target)&&(Fi(t.target),Bi(t.target))}function wl(t){const e=t.target?.closest?.(`.${Di}`);t.type==="invalid"&&e&&t.preventDefault(),Hi(!0)&&t.preventDefault()}N(()=>[Z(()=>Hi(),"class"),T(document,"input",_l,I),T(document,"toggle",yl,I),T(document,"invalid,submit",wl,!0)]);const xl=$.fieldset.split(" ")[0],El=$.validation.split(" ")[0],Ui="aria-describedby",Sl="aria-invalid",$l=O()?document.getElementsByClassName(xl):[];function Tl(){setTimeout(()=>{for(const t of $l)if(t.isConnected){const e=[];let n=null,o=!0;for(const i of t.getElementsByTagName("*"))i.classList.contains(El)?(o=f(i,"data-color")==="success"||!i.clientHeight,n=ae(i)):De(i)&&e.push(i);for(const i of e){const s=f(i,Ui)?.replace(n||"#","");f(i,Ui,`${n||""} ${s||""}`.trim()),f(i,Sl,`${!o}`)}}})}N(()=>[Z(Tl,"class")]);const Cl=$.logo.split(" ")[0],kl=O()?document.getElementsByClassName(Cl):[];function Al(){const t=kl[0],e=t?.firstElementChild;if(e instanceof SVGSVGElement){for(const r of document.head.querySelectorAll("link[rel~='icon']"))r.setAttribute("rel","disabled");const n=t?.hasAttribute("data-env"),o=window.getComputedStyle(e),i=o.getPropertyValue("color"),s=o.getPropertyValue("--mtdsc-logo-background"),a=e.outerHTML.replace(/\n+/g," ").replace(/(fill|width|height|xmlns)="[^"]+"/gi,"").replace("<svg",`<svg width="40" height="40" fill="${i}"`);document.head.appendChild(k("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(()=>[Z(Al,"class")]);const Lt=$.popover.split(" ")[0],It="popovertarget",Ll=O()?document.getElementsByClassName(Lt):[];function Il({target:t,newState:e}){if(t instanceof HTMLElement&&t.classList.contains(Lt)){const n=document.querySelector(`[${It}="${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 Ol({target:t,newState:e}){e==="open"&&t instanceof HTMLElement&&t.classList.contains(Lt)&&f(t,"popover")!=="manual"&&f(t,"popover","manual")}function Ml(t){const e=t.target?.closest?.("a,button"),n=e&&f(e,It),o=n?document.getElementById(n):e?.closest(`.${Lt}`);for(const i of Ll)o!==i&&!i.contains(t.target)&&i.hasAttribute("popover")&&i.hidePopover();if(o?.classList.contains(Lt)&&e){const i=f(e,`${It}action`),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`)}}}function Rl(t){if(t.key==="Escape"&&t.target instanceof Element){const e=t.target.closest(`[popover],[${It}]`),n=e&&document.getElementById(f(e,It)||e.id);n instanceof HTMLElement&&n.hidePopover(),n&&t.preventDefault?.()}}N(()=>[T(document,"click",Ml),T(document,"toggle",Il,I),T(document,"beforetoggle",Ol,I),T(document,"keydown",Rl)]);const Pl=$.table.split(" ")[0],Dl='a,button,label,input,select,textarea,[role="button"]',Nl=O()?document.getElementsByClassName(Pl):[];function Hl(){for(const t of Nl){const e=Array.from(t.tHead?.rows[0]?.cells||[],n=>n.innerText.trim());for(const n of t.tBodies)for(const o of n.rows)for(const i of o.cells)f(i,"data-th",e[i.cellIndex]||":empty")}}function Bl({target:t}){if(!(t instanceof Element))return;const n=t.closest("tr")?.querySelector('[data-command="row"]');n&&!t.closest(Dl)&&n.click?.()}N(()=>[T(document,"click",Bl),Z(Hl,"class")]);const Vi=$.toast.split(" ")[0],pe="data-sort";function Fl({animationName:t,target:e}){const n=e;if(t===$._toastTimeout&&n.close(),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(`.${Vi}[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 Ul({target:t,clientX:e,clientY:n}){if(t instanceof HTMLDialogElement&&t.classList.contains(Vi)&&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(()=>[T(document,"animationstart",Fl),T(document,"click",Ul)]);const Vl=`.${$.togglegroup.split(" ")[0]}`;function ql(t){const{key:e,target:n}=t,o=n instanceof HTMLInputElement&&n.closest(Vl);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(()=>[T(document,"keydown",ql)]);const qi="Escape",Gl=300,Gi="mtds-tooltip",j=O()?document.getElementById(Gi)||k("div",{class:$._tooltip,id:Gi,popover:"manual"}):null;let Wi=null,zi=Number.NEGATIVE_INFINITY,Xi=0;function tn({target:t,type:e,key:n}){if(e==="keydown"&&n!==qi)return;const o=zi+Gl-Date.now();clearTimeout(Xi),Xi=setTimeout(Wl,Math.max(o,0),n===qi?null:t)}function Wl(t){if(zi=Date.now(),!j||t===j)return;j?.isConnected||document.body.append(j);let e=t?.closest?.("[data-tooltip]")||null;if(e===Wi)return;const n=e&&f(e,"data-tooltip")||"",o=e&&f(e,"data-tooltip-position")||window.getComputedStyle(e||document.body).getPropertyValue("--mtds-tooltip-position")?.trim()||"top";(!n||n==="false"||n==="true"||o==="none")&&(e=null),e&&(j.textContent=n),at(j,!1),Wi=e,j.hidePopover(),j.togglePopover(!!e),at(j,e||!1,{strategy:"fixed",placement:o,middleware:[Yo(),Ko({padding:10})]})}function zl(){document.querySelectorAll("[data-tooltip]").forEach(t=>{const e=!t?.textContent?.trim(),n=f(t,"data-tooltip");f(t,`aria-${e?"label":"description"}`,n)})}N(()=>[T(document,"blur,focus,mouseout,mouseover",tn,I),T(window,"keydown",tn,I),T(window,"blur",tn,I),Z(zl,"data-tooltip")]);var ji=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",Ki;ji&&/^Mac/i.test(((Ki=navigator.userAgentData)==null?void 0:Ki.platform)||navigator.platform);var Xl=":host(:not([hidden])) { display: block }",Yi=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 Qi=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Ji=(t,...e)=>Qi("add",t,e),Zi=(t,...e)=>Qi("remove",t,e),jl=t=>{const e="key"in t&&(t.key===" "||t.key==="Enter");return e&&t.preventDefault(),e&&t.target instanceof HTMLElement&&t.target.click(),e},Kl=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},en=(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},ts={define:(t,e)=>!ji||window.customElements.get(t)||window.customElements.define(t,e)},Yl=`${Xl}
|
|
190
|
+
::slotted(u-option[hidden]) { display: none !important }`,ki,Ai=0,fl=We||ce,Li="click,focusout,input,keydown,mousedown,mouseup",Ii="focus,focusin,blur,focusout",fe={singular:"%d hit",plural:"%d hits"},Oi=class extends Ei{constructor(){super(),this._texts=nl({},fe),this._value="",al(this,ul)}static get observedAttributes(){return["id",...Object.keys(fe).map(t=>`data-sr-${t}`)]}connectedCallback(){this.hidden=!0,this._root=$i(this),S(this,"role","listbox"),S(this,"tabindex","-1"),Ct(this._root,"focusin",this),Ct(this._root,"focus",this,!0),ze(this,{attributeFilter:["disabled","hidden","label","value"],attributes:!0,characterData:!0,childList:!0,subtree:!0}),setTimeout(()=>this.attributeChangedCallback())}disconnectedCallback(){de(this._root||this,"focus",this,!0),de(this._root||this,"focusin",this),ze(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(fe[o])this._texts[o]=n||fe[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"&&hl(this,t),(n==="focus"||n==="focusin")&&pl(this,t),(n==="blur"||n==="focusout")&&ml(this,t),n==="keydown"&&gl(this,t),n==="mousedown"&&this.contains(e)&&Ye(t),(n==="mutation"||n==="input")&&(clearTimeout(Ai),Ai=setTimeout(Pi,0,this,t)))}get options(){return this.getElementsByTagName("u-option")}},Mi=t=>t?.disabled||t?.readOnly||!1,At=(t,e)=>{var n,o,i;if(t.hidden!==e)return;t.hidden=Mi(t?._input)||!e,(n=ze(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&&Pi(t)},Je=t=>{t._input&&(de(t._input||t,Ii,t),de(t._root||t,Li,t),At(t,!1),t._input=void 0)},Ze=(t,e,n=!1)=>{t.popover&&S(e,"popovertarget",Xe(t)),Ct(e,Ii,t,!0),S(e,"aria-autocomplete","list"),S(e,"aria-controls",Xe(t)),S(e,"aria-expanded",`${!fl||n}`),S(e,"autocomplete","off"),S(e,"role",Mi(e)?null:"combobox")},pl=(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,ol,Xe((n=t._input.labels)==null?void 0:n[0])),Ct(t._root||t,Li,t),At(t,S(t._input,"inputmode")!=="none"),Ci())},ml=(t,e)=>{!ce&&!Ye()&&t._input&&setTimeout(Ri,0,t),e.target===t._input&&e.isTrusted&&e.stopImmediatePropagation()},Ri=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))},hl=(t,{target:e})=>{var n;if(!t._input||t._input===e)return At(t,!0);for(const o of t.options)if(o.contains(e))return S(t,"aria-multiselectable")!=="true"&&((n=t._input)==null||n.focus(),At(t,!1)),cl(t._input,o.value);ce&&Ri(t)},gl=(t,e)=>{var n;const{key:o,target:i,altKey:s,ctrlKey:a,shiftKey:r,metaKey:l}=e,c=o==="Escape"||o==="Esc";if(s||a||l||r||o==="Tab")return;c&&!t.hidden&&e?.preventDefault(),At(t,!c);const d=[...t.options].filter(m=>S(m,"aria-hidden")!=="true"&&m.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 m of d)m.tabIndex=-1;d[p]&&e.preventDefault(),(n=d[p]||t._input)==null||n.focus(),!d[p]&&o==="ArrowUp"&&setTimeout(()=>{var m;return(m=t._input)==null?void 0:m.setSelectionRange(999,999)})},Pi=(t,e)=>{const{_texts:n,_root:o,_input:i,options:s}=t,a=i?.value.toLowerCase().trim()||"",r=!t.hasAttribute("data-nofilter"),l=[],c=[];for(const u of s)(u.disabled||u.hidden||r&&!u.label.toLowerCase().includes(a)?l:c).push(u);for(const u of l)S(u,"aria-hidden","true");for(const u of c)S(u,"aria-hidden","false");const d=c.length;clearTimeout(ki),e?.type==="input"&&a!==t._value&&(ki=setTimeout(()=>{const u=`${!d&&t.innerText.trim()||`${n[d===1?"singular":"plural"]}`.replace("%d",`${d}`)}`;!t.hidden&&o?.activeElement===i&&Ci(u),t._value=a},1e3)),We&&c.map((u,p)=>S(u,"title",`${p+1}/${d}`))};Tt&&Object.defineProperty(HTMLInputElement.prototype,"list",{configurable:!0,enumerable:!0,get(){return $i(this).getElementById(S(this,"list")||"")}}),Ti.define("u-datalist",Oi);const Di=$.field.split(" ")[0],Ni=$.validation.split(" "),Hi=Ni[0],bl=O()?document.getElementsByClassName(Di):[];function Bi(t){let e=null;for(const n of bl)if(n.isConnected){const o=[],i=[];let s=null,a=null,r=!0;for(const l of n.getElementsByTagName("*"))l instanceof HTMLLabelElement?o.push(l):l instanceof ye?s=l:De(l)&&!l.hidden?a=l:l.hasAttribute("data-description")?i.push(l):l.classList.contains(Hi)?(r=f(l,"data-color")==="success"||!l.clientHeight,i.unshift(l)):l instanceof HTMLParagraphElement&&(i.some(c=>c.contains(l))||i.push(l));if(a){const l=s?.control,c=(t||l?.validity.customError)&&a.closest('[data-validation="form"]');if(c){r=l?.getAttribute("aria-required")==="true"?!!s?.items.length:a.validity.valid,!e&&!r&&(e=a),l?.setCustomValidity(r?"":"Invalid");const d=!c.querySelector(":invalid");c.querySelectorAll(`:scope > .${Hi}`).forEach(u=>{f(u,"hidden",d?"":null)})}for(const d of o)d.htmlFor=ae(a);vl(s),Ui(a),Fi(a),f(a,"aria-describedby",i.map(ae).join(" ")),f(a,"aria-invalid",`${!r}`)}}return t&&e?.focus(),e}function Fi(t){t instanceof HTMLTextAreaElement&&(t.style.setProperty("--mtds-textarea-height","auto"),t.style.setProperty("--mtds-textarea-height",`${t.scrollHeight}px`))}const U=(t,e)=>t.getPropertyValue(`--mtds-text-${e}`)?.slice(1,-1)||"";function vl(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",U(o,"combobox-added")),f(t,"data-sr-empty",U(o,"combobox-empty")),f(t,"data-sr-found",U(o,"combobox-found")),f(t,"data-sr-invalid",U(o,"combobox-invalid")),f(t,"data-sr-of",U(o,"combobox-of")),f(t,"data-sr-remove",U(o,"combobox-remove")),f(t,"data-sr-removed",U(o,"combobox-removed")),f(n,"data-sr-plural",U(o,"datalist-plural")),f(n,"data-sr-singular",U(o,"datalist-singular"))}n&&e&&!n.hasAttribute("popover")&&(f(n,"popover","manual"),f(e,"popovertarget",ae(n)))}function Ui(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=U(a,"count-over"),l=U(a,"count-under");if(s!==i){f(e,"aria-live",i?"polite":"off");for(const c of Ni)e.classList.toggle(c,i)}e.textContent=(i?r:l).replace("%d",`${Math.abs(o)}`)}}function yl({target:t,newState:e}){if(t instanceof Oi){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 _l(t){De(t.target)&&(Ui(t.target),Fi(t.target))}function wl(t){const e=t.target?.closest?.(`.${Di}`);t.type==="invalid"&&e&&t.preventDefault(),Bi(!0)&&t.preventDefault()}N(()=>[Z(()=>Bi(),"class"),T(document,"input",_l,I),T(document,"toggle",yl,I),T(document,"invalid,submit",wl,!0)]);const xl=$.fieldset.split(" ")[0],El=$.validation.split(" ")[0],qi="aria-describedby",Sl="aria-invalid",$l=O()?document.getElementsByClassName(xl):[];function Tl(){setTimeout(()=>{for(const t of $l)if(t.isConnected){const e=[];let n=null,o=!0;for(const i of t.getElementsByTagName("*"))i.classList.contains(El)?(o=f(i,"data-color")==="success"||!i.clientHeight,n=ae(i)):De(i)&&e.push(i);for(const i of e){const s=f(i,qi)?.replace(n||"#","");f(i,qi,`${n||""} ${s||""}`.trim()),f(i,Sl,`${!o}`)}}})}N(()=>[Z(Tl,"class")]);const Cl=$.logo.split(" ")[0],kl=O()?document.getElementsByClassName(Cl):[];function Al(){const t=kl[0],e=t?.firstElementChild;if(e instanceof SVGSVGElement){for(const r of document.head.querySelectorAll("link[rel~='icon']"))r.setAttribute("rel","disabled");const n=t?.hasAttribute("data-env"),o=window.getComputedStyle(e),i=o.getPropertyValue("color"),s=o.getPropertyValue("--mtdsc-logo-background"),a=e.outerHTML.replace(/\n+/g," ").replace(/(fill|width|height|xmlns)="[^"]+"/gi,"").replace("<svg",`<svg width="40" height="40" fill="${i}"`);document.head.appendChild(k("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(()=>[Z(Al,"class")]);const Lt=$.popover.split(" ")[0],It="popovertarget",Ll=O()?document.getElementsByClassName(Lt):[];function Il({target:t,newState:e}){if(t instanceof HTMLElement&&t.classList.contains(Lt)){const n=document.querySelector(`[${It}="${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 Ol({target:t,newState:e}){e==="open"&&t instanceof HTMLElement&&t.classList.contains(Lt)&&f(t,"popover")!=="manual"&&f(t,"popover","manual")}function Ml(t){const e=t.target?.closest?.("a,button"),n=e&&f(e,It),o=n?document.getElementById(n):e?.closest(`.${Lt}`);for(const i of Ll)o!==i&&!i.contains(t.target)&&i.hasAttribute("popover")&&i.hidePopover();if(o?.classList.contains(Lt)&&e){const i=f(e,`${It}action`),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`)}}}function Rl(t){if(t.key==="Escape"&&t.target instanceof Element){const e=t.target.closest(`[popover],[${It}]`),n=e&&document.getElementById(f(e,It)||e.id);n instanceof HTMLElement&&n.hidePopover(),n&&t.preventDefault?.()}}N(()=>[T(document,"click",Ml),T(document,"toggle",Il,I),T(document,"beforetoggle",Ol,I),T(document,"keydown",Rl)]);const Pl=$.table.split(" ")[0],Dl='a,button,label,input,select,textarea,[role="button"]',Nl=O()?document.getElementsByClassName(Pl):[];function Hl(){for(const t of Nl){const e=Array.from(t.tHead?.rows[0]?.cells||[],n=>n.innerText.trim());for(const n of t.tBodies)for(const o of n.rows)for(const i of o.cells)f(i,"data-th",e[i.cellIndex]||":empty")}}function Bl({target:t}){if(!(t instanceof Element))return;const n=t.closest("tr")?.querySelector('[data-command="row"]');n&&!t.closest(Dl)&&n.click?.()}N(()=>[T(document,"click",Bl),Z(Hl,"class")]);const Vi=$.toast.split(" ")[0],pe="data-sort";function Fl({animationName:t,target:e}){const n=e;if(t===$._toastTimeout&&n.close(),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(`.${Vi}[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 Ul({target:t,clientX:e,clientY:n}){if(t instanceof HTMLDialogElement&&t.classList.contains(Vi)&&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),l=o.right-Number.parseInt(i.paddingRight,10),c=l-Number.parseInt(s.width,10);a<=n&&n<=r&&c<=e&&e<=l&&t.close()}}N(()=>[T(document,"animationstart",Fl),T(document,"click",Ul)]);const ql=`.${$.togglegroup.split(" ")[0]}`;function Vl(t){const{key:e,target:n}=t,o=n instanceof HTMLInputElement&&n.closest(ql);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(()=>[T(document,"keydown",Vl)]);const Gi="Escape",Gl=300,Wi="mtds-tooltip",j=O()?document.getElementById(Wi)||k("div",{class:$._tooltip,id:Wi,popover:"manual"}):null;let zi=null,Xi=Number.NEGATIVE_INFINITY,ji=0;function tn({target:t,type:e,key:n}){if(e==="keydown"&&n!==Gi)return;const o=Xi+Gl-Date.now();clearTimeout(ji),ji=setTimeout(Wl,Math.max(o,0),n===Gi?null:t)}function Wl(t){if(Xi=Date.now(),!j||t===j)return;j?.isConnected||document.body.append(j);let e=t?.closest?.("[data-tooltip]")||null;if(e===zi)return;const n=e&&f(e,"data-tooltip")||"",o=e&&f(e,"data-tooltip-position")||window.getComputedStyle(e||document.body).getPropertyValue("--mtds-tooltip-position")?.trim()||"top";(!n||n==="false"||n==="true"||o==="none")&&(e=null),e&&(j.textContent=n),at(j,!1),zi=e,j.hidePopover(),j.togglePopover(!!e),at(j,e||!1,{strategy:"fixed",placement:o,middleware:[Yo(),Ko({padding:10})]})}function zl(){document.querySelectorAll("[data-tooltip]").forEach(t=>{const e=!t?.textContent?.trim(),n=f(t,"data-tooltip");f(t,`aria-${e?"label":"description"}`,n)})}N(()=>[T(document,"blur,focus,mouseout,mouseover",tn,I),T(window,"keydown",tn,I),T(window,"blur",tn,I),Z(zl,"data-tooltip")]);var Ki=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",Yi;Ki&&/^Mac/i.test(((Yi=navigator.userAgentData)==null?void 0:Yi.platform)||navigator.platform);var Xl=":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 Ji=(t,e,n)=>{for(const o of n[0].split(","))n[0]=o,Element.prototype[`${t}EventListener`].apply(e,n)},Zi=(t,...e)=>Ji("add",t,e),ts=(t,...e)=>Ji("remove",t,e),jl=t=>{const e="key"in t&&(t.key===" "||t.key==="Enter");return e&&t.preventDefault(),e&&t.target instanceof HTMLElement&&t.target.click(),e},Kl=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},en=(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},es={define:(t,e)=>!Ki||window.customElements.get(t)||window.customElements.define(t,e)},Yl=`${Xl}
|
|
191
191
|
::slotted(u-summary) { cursor: pointer; display: block }
|
|
192
192
|
::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 }
|
|
193
193
|
::slotted(u-summary[aria-expanded="true"])::before { rotate: 90deg }
|
|
194
|
-
:host > [part="details-content"]:not([hidden=""]) { display: block }`,Ql=class extends
|
|
194
|
+
:host > [part="details-content"]:not([hidden=""]) { display: block }`,Ql=class extends Qi{constructor(){super(),this._content=null,this.shadowRoot||this.attachShadow({mode:"open"}).append(en("slot",null,{name:"summary"}),en("slot",null,{part:"details-content"}),en("style",Yl))}static get observedAttributes(){return["open"]}connectedCallback(){var t;this._content=(t=this.shadowRoot)==null?void 0:t.children[1],K(this,"role","group"),Zi(this._content,"beforematch",this),Zi(this,"click,keydown",this),this.attributeChangedCallback()}disconnectedCallback(){this._content&&ts(this._content,"beforematch",this),ts(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=Kl(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"&&jl(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)}},Jl=class extends Qi{connectedCallback(){K(this,"role","button"),this.slot="summary",this.tabIndex=0}};es.define("u-details",Ql),es.define("u-summary",Jl);var me=typeof window<"u"&&typeof window.document<"u"&&typeof window.navigator<"u",ns=me&&/firefox/i.test(navigator.userAgent),Zl=me&&/iPad|iPhone|iPod/.test(navigator.userAgent),os;me&&/^Mac/i.test(((os=navigator.userAgentData)==null?void 0:os.platform)||navigator.platform);var tc=typeof HTMLElement>"u"?class{}:HTMLElement;function M(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 ec=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},nc=0,oc=t=>t?(t.id||(t.id=`:${t.nodeName.toLowerCase()}${(++nc).toString(32)}`),t.id):"",is=(t,e,n)=>{const o=document.createElement(t);if(e&&(o.textContent=e),n)for(const[i,s]of Object.entries(n))M(o,i,s);return o},ic={define:(t,e)=>!me||window.customElements.get(t)||window.customElements.define(t,e)},sc=t=>{var e;const n=M(t,"aria-label")||"";return[...(((e=M(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)},ac=`:host(:not([hidden])) { box-sizing: border-box; border: 1px solid; display: inline-block; height: .5em; width: 10em; overflow: hidden }
|
|
195
195
|
:host::before { content: ''; display: block; height: 100%; background: currentColor; width: var(--percentage, 0%); transition: width .2s }
|
|
196
196
|
:host(:not([value])) { background: linear-gradient(90deg,currentColor 25%, transparent 50%, currentColor 75%) 50%/400% }
|
|
197
197
|
@media (prefers-reduced-motion: no-preference) { :host { animation: indeterminate 2s linear infinite } }
|
|
198
|
-
@keyframes indeterminate { from { background-position-x: 100% } to { background-position-x: 0 } }`,nn=!1,
|
|
198
|
+
@keyframes indeterminate { from { background-position-x: 100% } to { background-position-x: 0 } }`,nn=!1,ss=class extends tc{static get observedAttributes(){return["aria-label","aria-labelledby","value","max"]}constructor(){super(),this.shadowRoot||this.attachShadow({mode:"open"}).append(is("slot",null,{hidden:""}),is("style",ac))}connectedCallback(){this.attributeChangedCallback()}attributeChangedCallback(){if(nn)return;nn=!0;const t=Zl||ns,e=Math.max(0,Math.round(this.position*100));this.style.setProperty("--percentage",`${e}%`);let n=sc(this);if(t&&(n=`${n.replace(/\d+%$/,"")} ${e}%`),ns)for(const o of this.labels)M(o,"aria-label",n);M(this,"aria-busy",`${this.position===-1}`),M(this,"aria-label",n.trim()),M(this,"aria-labelledby",null),M(this,"aria-valuemax","100"),M(this,"aria-valuemin","0"),M(this,"aria-valuenow",`${e}`),M(this,"role",t?"img":"progressbar"),nn=!1}get labels(){const t=this.closest("label:not([for])"),e=oc(this);return t&&(t.htmlFor=e),ec(this).querySelectorAll(`label[for="${e}"]`)}get position(){return this.value===null?-1:Math.min(this.value/this.max,1)}get value(){return rs(this,"value")}set value(t){ls(this,"value",t)}get max(){return rs(this,"max")||1}set max(t){ls(this,"max",t)}};ss.formAssociated=!0;var as=t=>!Number.isNaN(Number.parseFloat(`${t}`))&&Number.isFinite(Number(t)),rs=(t,e)=>{const n=M(t,e);return as(n)?Math.max(0,Number.parseFloat(n)):null},ls=(t,e,n)=>{if(n===null||as(n))M(t,e,`${n}`);else throw new Error(`Failed to set non-numeric '${M}': '${n}'`)};return ic.define("u-progress",ss),C.UHTMLComboboxElement=ye,C.UHTMLTabElement=Tn,C.UHTMLTabListElement=$n,C.UHTMLTabPanelElement=Cn,C.UHTMLTabsElement=Sn,C.analytics=ei,C.fixLawHtml=di,C.getLawChecked=_r,C.pagination=Lr,C.parseLawIds=Er,C.parseLawMeta=Sr,C.setLawChecked=xr,C.styles=zs,C.toast=A,C.toggleAppExpanded=ai,C.toggleLawChecked=wr,C.version=Ws,Object.defineProperty(C,Symbol.toStringTag,{value:"Module"}),C}({});
|
package/mtds/input/input.js
CHANGED
|
@@ -6,8 +6,8 @@ const Input = forwardRef(function Input2({ className, type = "text", ...rest },
|
|
|
6
6
|
return /* @__PURE__ */ jsx(
|
|
7
7
|
"input",
|
|
8
8
|
{
|
|
9
|
-
suppressHydrationWarning: true,
|
|
10
9
|
className: clsx(styles.input, className),
|
|
10
|
+
suppressHydrationWarning: true,
|
|
11
11
|
type,
|
|
12
12
|
ref,
|
|
13
13
|
...rest
|
|
@@ -16,12 +16,28 @@ const Input = forwardRef(function Input2({ className, type = "text", ...rest },
|
|
|
16
16
|
});
|
|
17
17
|
const Select = forwardRef(
|
|
18
18
|
function Select2({ className, ...rest }, ref) {
|
|
19
|
-
return /* @__PURE__ */ jsx(
|
|
19
|
+
return /* @__PURE__ */ jsx(
|
|
20
|
+
"select",
|
|
21
|
+
{
|
|
22
|
+
className: clsx(styles.input, className),
|
|
23
|
+
suppressHydrationWarning: true,
|
|
24
|
+
ref,
|
|
25
|
+
...rest
|
|
26
|
+
}
|
|
27
|
+
);
|
|
20
28
|
}
|
|
21
29
|
);
|
|
22
30
|
const Textarea = forwardRef(
|
|
23
31
|
function Textarea2({ className, ...rest }, ref) {
|
|
24
|
-
return /* @__PURE__ */ jsx(
|
|
32
|
+
return /* @__PURE__ */ jsx(
|
|
33
|
+
"textarea",
|
|
34
|
+
{
|
|
35
|
+
className: clsx(styles.input, className),
|
|
36
|
+
suppressHydrationWarning: true,
|
|
37
|
+
ref,
|
|
38
|
+
...rest
|
|
39
|
+
}
|
|
40
|
+
);
|
|
25
41
|
}
|
|
26
42
|
);
|
|
27
43
|
export {
|
package/mtds/input/input.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"input.js","sources":["../../designsystem/input/input.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { forwardRef } from \"react\";\nimport styles from \"../styles.module.css\";\n\nexport type InputProps = React.ComponentPropsWithoutRef<\"input\">;\nexport const Input = forwardRef<HTMLInputElement, InputProps>(function Input(\n\t{ className, type = \"text\", ...rest },\n\tref,\n) {\n\treturn (\n\t\t<input\n\t\t\tsuppressHydrationWarning // Prevent hydration mismatch for SSR
|
|
1
|
+
{"version":3,"file":"input.js","sources":["../../designsystem/input/input.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { forwardRef } from \"react\";\nimport styles from \"../styles.module.css\";\n\nexport type InputProps = React.ComponentPropsWithoutRef<\"input\">;\nexport const Input = forwardRef<HTMLInputElement, InputProps>(function Input(\n\t{ className, type = \"text\", ...rest },\n\tref,\n) {\n\treturn (\n\t\t<input\n\t\t\tclassName={clsx(styles.input, className)}\n\t\t\tsuppressHydrationWarning // Prevent hydration mismatch for SSR caused by field-observer.ts\n\t\t\ttype={type}\n\t\t\tref={ref}\n\t\t\t{...rest}\n\t\t/>\n\t);\n});\n\nexport type SelectProps = React.ComponentPropsWithoutRef<\"select\">;\nexport const Select = forwardRef<HTMLSelectElement, SelectProps>(\n\tfunction Select({ className, ...rest }, ref) {\n\t\treturn (\n\t\t\t<select\n\t\t\t\tclassName={clsx(styles.input, className)}\n\t\t\t\tsuppressHydrationWarning // Prevent hydration mismatch for SSR caused by field-observer.ts\n\t\t\t\tref={ref}\n\t\t\t\t{...rest}\n\t\t\t/>\n\t\t);\n\t},\n);\n\nexport type TextareaProps = React.ComponentPropsWithoutRef<\"textarea\">;\nexport const Textarea = forwardRef<HTMLTextAreaElement, TextareaProps>(\n\tfunction Textarea({ className, ...rest }, ref) {\n\t\treturn (\n\t\t\t<textarea\n\t\t\t\tclassName={clsx(styles.input, className)}\n\t\t\t\tsuppressHydrationWarning // Prevent hydration mismatch for SSR caused by field-observer.ts\n\t\t\t\tref={ref}\n\t\t\t\t{...rest}\n\t\t\t/>\n\t\t);\n\t},\n);\n"],"names":["Input","Select","Textarea"],"mappings":";;;;AAKO,MAAM,QAAQ,WAAyC,SAASA,OACtE,EAAE,WAAW,OAAO,QAAQ,GAAG,KAAA,GAC/B,KACC;AACD,SACC;AAAA,IAAC;AAAA,IAAA;AAAA,MACA,WAAW,KAAK,OAAO,OAAO,SAAS;AAAA,MACvC,0BAAwB;AAAA,MACxB;AAAA,MACA;AAAA,MACC,GAAG;AAAA,IAAA;AAAA,EAAA;AAGP,CAAC;AAGM,MAAM,SAAS;AAAA,EACrB,SAASC,QAAO,EAAE,WAAW,GAAG,KAAA,GAAQ,KAAK;AAC5C,WACC;AAAA,MAAC;AAAA,MAAA;AAAA,QACA,WAAW,KAAK,OAAO,OAAO,SAAS;AAAA,QACvC,0BAAwB;AAAA,QACxB;AAAA,QACC,GAAG;AAAA,MAAA;AAAA,IAAA;AAAA,EAGP;AACD;AAGO,MAAM,WAAW;AAAA,EACvB,SAASC,UAAS,EAAE,WAAW,GAAG,KAAA,GAAQ,KAAK;AAC9C,WACC;AAAA,MAAC;AAAA,MAAA;AAAA,QACA,WAAW,KAAK,OAAO,OAAO,SAAS;AAAA,QACvC,0BAAwB;AAAA,QACxB;AAAA,QACC,GAAG;AAAA,MAAA;AAAA,IAAA;AAAA,EAGP;AACD;"}
|