dibk-design 9.4.0 → 10.0.0
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/README.md +1 -2
- package/dist/dibk-design.css +1 -1
- package/dist/index.cjs.js +4 -15
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +78 -7
- package/dist/index.es.js +1738 -2770
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +4 -15
- package/dist/index.umd.js.map +1 -1
- package/package.json +23 -22
package/dist/index.cjs.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("react"),Be=require("react-router-dom"),gt=require("react-dom");var je={exports:{}},be={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
9
|
+
*/var Ve;function ft(){if(Ve)return be;Ve=1;var e=Symbol.for("react.transitional.element"),s=Symbol.for("react.fragment");function n(a,r,o){var _=null;if(o!==void 0&&(_=""+o),r.key!==void 0&&(_=""+r.key),"key"in r){o={};for(var l in r)l!=="key"&&(o[l]=r[l])}else o=r;return r=o.ref,{$$typeof:e,type:a,key:_,ref:r!==void 0?r:null,props:o}}return be.Fragment=s,be.jsx=n,be.jsxs=n,be}var xe={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,21 +14,10 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
17
|
+
*/var qe;function vt(){return qe||(qe=1,process.env.NODE_ENV!=="production"&&function(){function e(c){if(c==null)return null;if(typeof c=="function")return c.$$typeof===B?null:c.displayName||c.name||null;if(typeof c=="string")return c;switch(c){case b:return"Fragment";case z:return"Profiler";case N:return"StrictMode";case D:return"Suspense";case M:return"SuspenseList";case E:return"Activity"}if(typeof c=="object")switch(typeof c.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),c.$$typeof){case k:return"Portal";case $:return(c.displayName||"Context")+".Provider";case j:return(c._context.displayName||"Context")+".Consumer";case V:var p=c.render;return c=c.displayName,c||(c=p.displayName||p.name||"",c=c!==""?"ForwardRef("+c+")":"ForwardRef"),c;case R:return p=c.displayName||null,p!==null?p:e(c.type)||"Memo";case q:p=c._payload,c=c._init;try{return e(c(p))}catch{}}return null}function s(c){return""+c}function n(c){try{s(c);var p=!1}catch{p=!0}if(p){p=console;var w=p.error,h=typeof Symbol=="function"&&Symbol.toStringTag&&c[Symbol.toStringTag]||c.constructor.name||"Object";return w.call(p,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",h),s(c)}}function a(c){if(c===b)return"<>";if(typeof c=="object"&&c!==null&&c.$$typeof===q)return"<...>";try{var p=e(c);return p?"<"+p+">":"<...>"}catch{return"<...>"}}function r(){var c=U.A;return c===null?null:c.getOwner()}function o(){return Error("react-stack-top-frame")}function _(c){if(W.call(c,"key")){var p=Object.getOwnPropertyDescriptor(c,"key").get;if(p&&p.isReactWarning)return!1}return c.key!==void 0}function l(c,p){function w(){G||(G=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",p))}w.isReactWarning=!0,Object.defineProperty(c,"key",{get:w,configurable:!0})}function u(){var c=e(this.type);return g[c]||(g[c]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),c=this.props.ref,c!==void 0?c:null}function i(c,p,w,h,y,I,J,Q){return w=I.ref,c={$$typeof:x,type:c,key:p,props:I,_owner:y},(w!==void 0?w:null)!==null?Object.defineProperty(c,"ref",{enumerable:!1,get:u}):Object.defineProperty(c,"ref",{enumerable:!1,value:null}),c._store={},Object.defineProperty(c._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(c,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(c,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:J}),Object.defineProperty(c,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:Q}),Object.freeze&&(Object.freeze(c.props),Object.freeze(c)),c}function m(c,p,w,h,y,I,J,Q){var S=p.children;if(S!==void 0)if(h)if(C(S)){for(h=0;h<S.length;h++)f(S[h]);Object.freeze&&Object.freeze(S)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else f(S);if(W.call(p,"key")){S=e(c);var O=Object.keys(p).filter(function(ie){return ie!=="key"});h=0<O.length?"{key: someKey, "+O.join(": ..., ")+": ...}":"{key: someKey}",Z[S+h]||(O=0<O.length?"{"+O.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
|
|
18
18
|
let props = %s;
|
|
19
19
|
<%s {...props} />
|
|
20
20
|
React keys must be passed directly to JSX without using spread:
|
|
21
21
|
let props = %s;
|
|
22
|
-
<%s key={someKey} {...props} />`,V,H,ue,H),ae[H+V]=!0)}if(H=null,T!==void 0&&(n(T),H=""+T),c(E)&&(n(E.key),H=""+E.key),"key"in E){T={};for(var Fe in E)Fe!=="key"&&(T[Fe]=E[Fe])}else T=E;return H&&u(T,typeof p=="function"?p.displayName||p.name||"Unknown":p),l(p,H,J,se,r(),T,ze,Ae)}function m(p){typeof p=="object"&&p!==null&&p.$$typeof===y&&p._store&&(p._store.validated=1)}var h=b,y=Symbol.for("react.transitional.element"),f=Symbol.for("react.portal"),v=Symbol.for("react.fragment"),x=Symbol.for("react.strict_mode"),_=Symbol.for("react.profiler"),C=Symbol.for("react.consumer"),w=Symbol.for("react.context"),$=Symbol.for("react.forward_ref"),L=Symbol.for("react.suspense"),S=Symbol.for("react.suspense_list"),N=Symbol.for("react.memo"),R=Symbol.for("react.lazy"),j=Symbol.for("react.activity"),M=Symbol.for("react.client.reference"),q=h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,X=Object.prototype.hasOwnProperty,I=Array.isArray,B=console.createTask?console.createTask:function(){return null};h={"react-stack-bottom-frame":function(p){return p()}};var k,D={},z=h["react-stack-bottom-frame"].bind(h,s)(),W=B(a(s)),ae={};we.Fragment=v,we.jsx=function(p,E,T,V,se){var J=1e4>q.recentlyCreatedOwnerStacks++;return d(p,E,T,!1,V,se,J?Error("react-stack-top-frame"):z,J?B(a(p)):W)},we.jsxs=function(p,E,T,V,se){var J=1e4>q.recentlyCreatedOwnerStacks++;return d(p,E,T,!0,V,se,J?Error("react-stack-top-frame"):z,J?B(a(p)):W)}}()),we}var lt;function en(){return lt||(lt=1,process.env.NODE_ENV==="production"?Le.exports=Zt():Le.exports=Qt()),Le.exports}var o=en();const P=e=>(e==null?void 0:e.filter(Boolean).join(" "))||"",Et=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),tn=e=>!(e!=null&&e.colors)||!Object.entries(e.colors).length?{}:Object.entries(e.colors).reduce((t,[n,a])=>(n&&a&&(t[`--color-${Et(n)}`]=a),t),{}),nn=e=>!(e!=null&&e.sizes)||!Object.entries(e.sizes).length?{}:Object.entries(e.sizes).reduce((t,[n,a])=>(n&&a&&(t[`--size-${Et(n)}`]=a),t),{}),rn=e=>({...tn(e),...nn(e)}),an=(e,t)=>{if(typeof document>"u")return;const n=document.createElement("style");n.setAttribute("id",e),n.textContent=t;const a=document.getElementById(e);a&&a.remove(),document.head.appendChild(n)},sn=e=>Object.entries(e).map(([t,n])=>`${t}: ${n};`).join(""),ye=e=>{const t=[];return b.Children.forEach(e,n=>{if(b.isValidElement(n)){const a=n;if(a.type===b.Fragment){const r=ye(a.props.children);t.push(...r)}else t.push(b.cloneElement(a,{...a.props}))}else t.push(n)}),t},on=e=>{if(typeof document>"u")return;const t=document.createElement("button");t.style.position="absolute",t.style.opacity="0",e.prepend(t),t.focus(),t.remove()},ln=e=>Array.from(e.querySelectorAll('button, [href], input, [tabindex="0"]')).filter(n=>!!n),kt=e=>{on(e);const t=ln(e),n=t[0],a=t[t.length-1]||n;n&&(n.onkeydown=r=>{r.key==="Tab"&&r.shiftKey&&(r.preventDefault(),a.focus())}),a&&(a.onclick=()=>{n==null||n.focus()},a.onkeydown=r=>{r.key==="Tab"&&!r.shiftKey&&(r.preventDefault(),n==null||n.focus())})},cn="_accordion_kwqaf_67",un="_panel_kwqaf_76",dn="_content_kwqaf_77",hn="_secondary_kwqaf_80",fn="_info_kwqaf_88",mn="_contrast_kwqaf_96",pn="_margin_kwqaf_104",_n="_panelText_kwqaf_138",gn="_panelChevron_kwqaf_144",vn="_expanded_kwqaf_171",yn="_initialized_kwqaf_187",xn="_hide_kwqaf_1",bn="_show_kwqaf_1",K={accordion:cn,default:"_default_kwqaf_73",panel:un,content:dn,secondary:hn,info:fn,contrast:mn,margin:pn,panelText:_n,panelChevron:gn,expanded:vn,initialized:yn,hide:xn,show:bn},wn=({title:e,buttonProps:t,expanded:n,handleToggleExpand:a})=>o.jsxs("button",{...t,className:K.panel,onClick:a,"aria-expanded":n?"true":"false",children:[o.jsx("span",{className:K.panelText,children:e}),o.jsx("span",{className:`${K.panelChevron} ${n?K.expanded:""}`})]}),Cn=({title:e,color:t="default",expanded:n=!1,onToggleExpand:a,buttonProps:r,noMargin:s=!1,initialized:c,children:u,...i})=>{const[l,d]=b.useState(n),[m,h]=b.useState(c),y=()=>{d(!l),h(!0),a&&a()};b.useEffect(()=>{d(n)},[n]);const f=P([K.accordion,t&&K[t],!s&&K.margin,i.className]);return o.jsxs("div",{className:f,...i,children:[o.jsx(wn,{title:e??"",buttonProps:r??{},expanded:l??!1,handleToggleExpand:y}),o.jsx("div",{className:`${K.content} ${m?K.initialized:""} ${l?K.expanded:""}`,children:u})]})};var Ce={},ct;function En(){if(ct)return Ce;ct=1,Object.defineProperty(Ce,"__esModule",{value:!0}),Ce.parse=c,Ce.serialize=l;const e=/^[\u0021-\u003A\u003C\u003E-\u007E]+$/,t=/^[\u0021-\u003A\u003C-\u007E]*$/,n=/^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i,a=/^[\u0020-\u003A\u003D-\u007E]*$/,r=Object.prototype.toString,s=(()=>{const h=function(){};return h.prototype=Object.create(null),h})();function c(h,y){const f=new s,v=h.length;if(v<2)return f;const x=(y==null?void 0:y.decode)||d;let _=0;do{const C=h.indexOf("=",_);if(C===-1)break;const w=h.indexOf(";",_),$=w===-1?v:w;if(C>$){_=h.lastIndexOf(";",C-1)+1;continue}const L=u(h,_,C),S=i(h,C,L),N=h.slice(L,S);if(f[N]===void 0){let R=u(h,C+1,$),j=i(h,$,R);const M=x(h.slice(R,j));f[N]=M}_=$+1}while(_<v);return f}function u(h,y,f){do{const v=h.charCodeAt(y);if(v!==32&&v!==9)return y}while(++y<f);return f}function i(h,y,f){for(;y>f;){const v=h.charCodeAt(--y);if(v!==32&&v!==9)return y+1}return f}function l(h,y,f){const v=(f==null?void 0:f.encode)||encodeURIComponent;if(!e.test(h))throw new TypeError(`argument name is invalid: ${h}`);const x=v(y);if(!t.test(x))throw new TypeError(`argument val is invalid: ${y}`);let _=h+"="+x;if(!f)return _;if(f.maxAge!==void 0){if(!Number.isInteger(f.maxAge))throw new TypeError(`option maxAge is invalid: ${f.maxAge}`);_+="; Max-Age="+f.maxAge}if(f.domain){if(!n.test(f.domain))throw new TypeError(`option domain is invalid: ${f.domain}`);_+="; Domain="+f.domain}if(f.path){if(!a.test(f.path))throw new TypeError(`option path is invalid: ${f.path}`);_+="; Path="+f.path}if(f.expires){if(!m(f.expires)||!Number.isFinite(f.expires.valueOf()))throw new TypeError(`option expires is invalid: ${f.expires}`);_+="; Expires="+f.expires.toUTCString()}if(f.httpOnly&&(_+="; HttpOnly"),f.secure&&(_+="; Secure"),f.partitioned&&(_+="; Partitioned"),f.priority)switch(typeof f.priority=="string"?f.priority.toLowerCase():void 0){case"low":_+="; Priority=Low";break;case"medium":_+="; Priority=Medium";break;case"high":_+="; Priority=High";break;default:throw new TypeError(`option priority is invalid: ${f.priority}`)}if(f.sameSite)switch(typeof f.sameSite=="string"?f.sameSite.toLowerCase():f.sameSite){case!0:case"strict":_+="; SameSite=Strict";break;case"lax":_+="; SameSite=Lax";break;case"none":_+="; SameSite=None";break;default:throw new TypeError(`option sameSite is invalid: ${f.sameSite}`)}return _}function d(h){if(h.indexOf("%")===-1)return h;try{return decodeURIComponent(h)}catch{return h}}function m(h){return r.call(h)==="[object Date]"}return Ce}En();/**
|
|
23
|
-
* react-router v7.6.2
|
|
24
|
-
*
|
|
25
|
-
* Copyright (c) Remix Software Inc.
|
|
26
|
-
*
|
|
27
|
-
* This source code is licensed under the MIT license found in the
|
|
28
|
-
* LICENSE.md file in the root directory of this source tree.
|
|
29
|
-
*
|
|
30
|
-
* @license MIT
|
|
31
|
-
*/function O(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function ee(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Ye({pathname:e="/",search:t="",hash:n=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function Ke(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let a=e.indexOf("?");a>=0&&(t.search=e.substring(a),e=e.substring(0,a)),e&&(t.pathname=e)}return t}function jt(e,t,n="/"){return kn(e,t,n,!1)}function kn(e,t,n,a){let r=typeof t=="string"?Ke(t):t,s=ie(r.pathname||"/",n);if(s==null)return null;let c=Lt(e);jn(c);let u=null;for(let i=0;u==null&&i<c.length;++i){let l=Bn(s);u=Dn(c[i],l,a)}return u}function Lt(e,t=[],n=[],a=""){let r=(s,c,u)=>{let i={relativePath:u===void 0?s.path||"":u,caseSensitive:s.caseSensitive===!0,childrenIndex:c,route:s};i.relativePath.startsWith("/")&&(O(i.relativePath.startsWith(a),`Absolute route path "${i.relativePath}" nested under path "${a}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),i.relativePath=i.relativePath.slice(a.length));let l=Q([a,i.relativePath]),d=n.concat(i);s.children&&s.children.length>0&&(O(s.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${l}".`),Lt(s.children,t,d,l)),!(s.path==null&&!s.index)&&t.push({path:l,score:Mn(l,s.index),routesMeta:d})};return e.forEach((s,c)=>{var u;if(s.path===""||!((u=s.path)!=null&&u.includes("?")))r(s,c);else for(let i of St(s.path))r(s,c,i)}),t}function St(e){let t=e.split("/");if(t.length===0)return[];let[n,...a]=t,r=n.endsWith("?"),s=n.replace(/\?$/,"");if(a.length===0)return r?[s,""]:[s];let c=St(a.join("/")),u=[];return u.push(...c.map(i=>i===""?s:[s,i].join("/"))),r&&u.push(...c),u.map(i=>e.startsWith("/")&&i===""?"/":i)}function jn(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Tn(t.routesMeta.map(a=>a.childrenIndex),n.routesMeta.map(a=>a.childrenIndex)))}var Ln=/^:[\w-]+$/,Sn=3,$n=2,In=1,Nn=10,Rn=-2,ut=e=>e==="*";function Mn(e,t){let n=e.split("/"),a=n.length;return n.some(ut)&&(a+=Rn),t&&(a+=$n),n.filter(r=>!ut(r)).reduce((r,s)=>r+(Ln.test(s)?Sn:s===""?In:Nn),a)}function Tn(e,t){return e.length===t.length&&e.slice(0,-1).every((a,r)=>a===t[r])?e[e.length-1]-t[t.length-1]:0}function Dn(e,t,n=!1){let{routesMeta:a}=e,r={},s="/",c=[];for(let u=0;u<a.length;++u){let i=a[u],l=u===a.length-1,d=s==="/"?t:t.slice(s.length)||"/",m=Te({path:i.relativePath,caseSensitive:i.caseSensitive,end:l},d),h=i.route;if(!m&&l&&n&&!a[a.length-1].route.index&&(m=Te({path:i.relativePath,caseSensitive:i.caseSensitive,end:!1},d)),!m)return null;Object.assign(r,m.params),c.push({params:r,pathname:Q([s,m.pathname]),pathnameBase:On(Q([s,m.pathnameBase])),route:h}),m.pathnameBase!=="/"&&(s=Q([s,m.pathnameBase]))}return c}function Te(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,a]=Pn(e.path,e.caseSensitive,e.end),r=t.match(n);if(!r)return null;let s=r[0],c=s.replace(/(.)\/+$/,"$1"),u=r.slice(1);return{params:a.reduce((l,{paramName:d,isOptional:m},h)=>{if(d==="*"){let f=u[h]||"";c=s.slice(0,s.length-f.length).replace(/(.)\/+$/,"$1")}const y=u[h];return m&&!y?l[d]=void 0:l[d]=(y||"").replace(/%2F/g,"/"),l},{}),pathname:s,pathnameBase:c,pattern:e}}function Pn(e,t=!1,n=!0){ee(e==="*"||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let a=[],r="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(c,u,i)=>(a.push({paramName:u,isOptional:i!=null}),i?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(a.push({paramName:"*"}),r+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?r+="\\/*$":e!==""&&e!=="/"&&(r+="(?:(?=\\/|$))"),[new RegExp(r,t?void 0:"i"),a]}function Bn(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return ee(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function ie(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,a=e.charAt(n);return a&&a!=="/"?null:e.slice(n)||"/"}function zn(e,t="/"){let{pathname:n,search:a="",hash:r=""}=typeof e=="string"?Ke(e):e;return{pathname:n?n.startsWith("/")?n:An(n,t):t,search:Vn(a),hash:Hn(r)}}function An(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(r=>{r===".."?n.length>1&&n.pop():r!=="."&&n.push(r)}),n.length>1?n.join("/"):"/"}function Oe(e,t,n,a){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(a)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Fn(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function $t(e){let t=Fn(e);return t.map((n,a)=>a===t.length-1?n.pathname:n.pathnameBase)}function It(e,t,n,a=!1){let r;typeof e=="string"?r=Ke(e):(r={...e},O(!r.pathname||!r.pathname.includes("?"),Oe("?","pathname","search",r)),O(!r.pathname||!r.pathname.includes("#"),Oe("#","pathname","hash",r)),O(!r.search||!r.search.includes("#"),Oe("#","search","hash",r)));let s=e===""||r.pathname==="",c=s?"/":r.pathname,u;if(c==null)u=n;else{let m=t.length-1;if(!a&&c.startsWith("..")){let h=c.split("/");for(;h[0]==="..";)h.shift(),m-=1;r.pathname=h.join("/")}u=m>=0?t[m]:"/"}let i=zn(r,u),l=c&&c!=="/"&&c.endsWith("/"),d=(s||c===".")&&n.endsWith("/");return!i.pathname.endsWith("/")&&(l||d)&&(i.pathname+="/"),i}var Q=e=>e.join("/").replace(/\/\/+/g,"/"),On=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Vn=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Hn=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function qn(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}var Nt=["POST","PUT","PATCH","DELETE"];new Set(Nt);var Xn=["GET",...Nt];new Set(Xn);var xe=g.createContext(null);xe.displayName="DataRouter";var De=g.createContext(null);De.displayName="DataRouterState";var Rt=g.createContext({isTransitioning:!1});Rt.displayName="ViewTransition";var Wn=g.createContext(new Map);Wn.displayName="Fetchers";var Un=g.createContext(null);Un.displayName="Await";var ne=g.createContext(null);ne.displayName="Navigation";var Ze=g.createContext(null);Ze.displayName="Location";var re=g.createContext({outlet:null,matches:[],isDataRoute:!1});re.displayName="Route";var Qe=g.createContext(null);Qe.displayName="RouteError";function Yn(e,{relative:t}={}){O(Pe(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:a}=g.useContext(ne),{hash:r,pathname:s,search:c}=je(e,{relative:t}),u=s;return n!=="/"&&(u=s==="/"?n:Q([n,s])),a.createHref({pathname:u,search:c,hash:r})}function Pe(){return g.useContext(Ze)!=null}function ce(){return O(Pe(),"useLocation() may be used only in the context of a <Router> component."),g.useContext(Ze).location}var Mt="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Tt(e){g.useContext(ne).static||g.useLayoutEffect(e)}function Jn(){let{isDataRoute:e}=g.useContext(re);return e?lr():Gn()}function Gn(){O(Pe(),"useNavigate() may be used only in the context of a <Router> component.");let e=g.useContext(xe),{basename:t,navigator:n}=g.useContext(ne),{matches:a}=g.useContext(re),{pathname:r}=ce(),s=JSON.stringify($t(a)),c=g.useRef(!1);return Tt(()=>{c.current=!0}),g.useCallback((i,l={})=>{if(ee(c.current,Mt),!c.current)return;if(typeof i=="number"){n.go(i);return}let d=It(i,JSON.parse(s),r,l.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:Q([t,d.pathname])),(l.replace?n.replace:n.push)(d,l.state,l)},[t,n,s,r,e])}g.createContext(null);function je(e,{relative:t}={}){let{matches:n}=g.useContext(re),{pathname:a}=ce(),r=JSON.stringify($t(n));return g.useMemo(()=>It(e,JSON.parse(r),a,t==="path"),[e,r,a,t])}function Kn(e,t,n,a){O(Pe(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:r}=g.useContext(ne),{matches:s}=g.useContext(re),c=s[s.length-1],u=c?c.params:{},i=c?c.pathname:"/",l=c?c.pathnameBase:"/",d=c&&c.route;{let _=d&&d.path||"";Dt(i,!d||_.endsWith("*")||_.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${i}" (under <Route path="${_}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
32
|
-
|
|
33
|
-
Please change the parent <Route path="${_}"> to <Route path="${_==="/"?"*":`${_}/*`}">.`)}let m=ce(),h;h=m;let y=h.pathname||"/",f=y;if(l!=="/"){let _=l.replace(/^\//,"").split("/");f="/"+y.replace(/^\//,"").split("/").slice(_.length).join("/")}let v=jt(e,{pathname:f});return ee(d||v!=null,`No routes matched location "${h.pathname}${h.search}${h.hash}" `),ee(v==null||v[v.length-1].route.element!==void 0||v[v.length-1].route.Component!==void 0||v[v.length-1].route.lazy!==void 0,`Matched leaf route at location "${h.pathname}${h.search}${h.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`),nr(v&&v.map(_=>Object.assign({},_,{params:Object.assign({},u,_.params),pathname:Q([l,r.encodeLocation?r.encodeLocation(_.pathname).pathname:_.pathname]),pathnameBase:_.pathnameBase==="/"?l:Q([l,r.encodeLocation?r.encodeLocation(_.pathnameBase).pathname:_.pathnameBase])})),s,n,a)}function Zn(){let e=ir(),t=qn(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,a="rgba(200,200,200, 0.5)",r={padding:"0.5rem",backgroundColor:a},s={padding:"2px 4px",backgroundColor:a},c=null;return console.error("Error handled by React Router default ErrorBoundary:",e),c=g.createElement(g.Fragment,null,g.createElement("p",null,"💿 Hey developer 👋"),g.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",g.createElement("code",{style:s},"ErrorBoundary")," or"," ",g.createElement("code",{style:s},"errorElement")," prop on your route.")),g.createElement(g.Fragment,null,g.createElement("h2",null,"Unexpected Application Error!"),g.createElement("h3",{style:{fontStyle:"italic"}},t),n?g.createElement("pre",{style:r},n):null,c)}var Qn=g.createElement(Zn,null),er=class extends g.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){console.error("React Router caught the following error during render",e,t)}render(){return this.state.error!==void 0?g.createElement(re.Provider,{value:this.props.routeContext},g.createElement(Qe.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function tr({routeContext:e,match:t,children:n}){let a=g.useContext(xe);return a&&a.static&&a.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(a.staticContext._deepestRenderedBoundaryId=t.route.id),g.createElement(re.Provider,{value:e},n)}function nr(e,t=[],n=null,a=null){if(e==null){if(!n)return null;if(n.errors)e=n.matches;else if(t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let r=e,s=n==null?void 0:n.errors;if(s!=null){let i=r.findIndex(l=>l.route.id&&(s==null?void 0:s[l.route.id])!==void 0);O(i>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(s).join(",")}`),r=r.slice(0,Math.min(r.length,i+1))}let c=!1,u=-1;if(n)for(let i=0;i<r.length;i++){let l=r[i];if((l.route.HydrateFallback||l.route.hydrateFallbackElement)&&(u=i),l.route.id){let{loaderData:d,errors:m}=n,h=l.route.loader&&!d.hasOwnProperty(l.route.id)&&(!m||m[l.route.id]===void 0);if(l.route.lazy||h){c=!0,u>=0?r=r.slice(0,u+1):r=[r[0]];break}}}return r.reduceRight((i,l,d)=>{let m,h=!1,y=null,f=null;n&&(m=s&&l.route.id?s[l.route.id]:void 0,y=l.route.errorElement||Qn,c&&(u<0&&d===0?(Dt("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),h=!0,f=null):u===d&&(h=!0,f=l.route.hydrateFallbackElement||null)));let v=t.concat(r.slice(0,d+1)),x=()=>{let _;return m?_=y:h?_=f:l.route.Component?_=g.createElement(l.route.Component,null):l.route.element?_=l.route.element:_=i,g.createElement(tr,{match:l,routeContext:{outlet:i,matches:v,isDataRoute:n!=null},children:_})};return n&&(l.route.ErrorBoundary||l.route.errorElement||d===0)?g.createElement(er,{location:n.location,revalidation:n.revalidation,component:y,error:m,children:x(),routeContext:{outlet:null,matches:v,isDataRoute:!0}}):x()},null)}function et(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function rr(e){let t=g.useContext(xe);return O(t,et(e)),t}function ar(e){let t=g.useContext(De);return O(t,et(e)),t}function sr(e){let t=g.useContext(re);return O(t,et(e)),t}function tt(e){let t=sr(e),n=t.matches[t.matches.length-1];return O(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function or(){return tt("useRouteId")}function ir(){var a;let e=g.useContext(Qe),t=ar("useRouteError"),n=tt("useRouteError");return e!==void 0?e:(a=t.errors)==null?void 0:a[n]}function lr(){let{router:e}=rr("useNavigate"),t=tt("useNavigate"),n=g.useRef(!1);return Tt(()=>{n.current=!0}),g.useCallback(async(r,s={})=>{ee(n.current,Mt),n.current&&(typeof r=="number"?e.navigate(r):await e.navigate(r,{fromRouteId:t,...s}))},[e,t])}var dt={};function Dt(e,t,n){!t&&!dt[e]&&(dt[e]=!0,ee(!1,n))}g.memo(cr);function cr({routes:e,future:t,state:n}){return Kn(e,void 0,n,t)}var Re="get",Me="application/x-www-form-urlencoded";function Be(e){return e!=null&&typeof e.tagName=="string"}function ur(e){return Be(e)&&e.tagName.toLowerCase()==="button"}function dr(e){return Be(e)&&e.tagName.toLowerCase()==="form"}function hr(e){return Be(e)&&e.tagName.toLowerCase()==="input"}function fr(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function mr(e,t){return e.button===0&&(!t||t==="_self")&&!fr(e)}var Se=null;function pr(){if(Se===null)try{new FormData(document.createElement("form"),0),Se=!1}catch{Se=!0}return Se}var _r=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Ve(e){return e!=null&&!_r.has(e)?(ee(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Me}"`),null):e}function gr(e,t){let n,a,r,s,c;if(dr(e)){let u=e.getAttribute("action");a=u?ie(u,t):null,n=e.getAttribute("method")||Re,r=Ve(e.getAttribute("enctype"))||Me,s=new FormData(e)}else if(ur(e)||hr(e)&&(e.type==="submit"||e.type==="image")){let u=e.form;if(u==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let i=e.getAttribute("formaction")||u.getAttribute("action");if(a=i?ie(i,t):null,n=e.getAttribute("formmethod")||u.getAttribute("method")||Re,r=Ve(e.getAttribute("formenctype"))||Ve(u.getAttribute("enctype"))||Me,s=new FormData(u,e),!pr()){let{name:l,type:d,value:m}=e;if(d==="image"){let h=l?`${l}.`:"";s.append(`${h}x`,"0"),s.append(`${h}y`,"0")}else l&&s.append(l,m)}}else{if(Be(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=Re,a=null,r=Me,c=e}return s&&r==="text/plain"&&(c=s,s=void 0),{action:a,method:n.toLowerCase(),encType:r,formData:s,body:c}}function nt(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}async function vr(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function yr(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}async function xr(e,t,n){let a=await Promise.all(e.map(async r=>{let s=t.routes[r.route.id];if(s){let c=await vr(s,n);return c.links?c.links():[]}return[]}));return Er(a.flat(1).filter(yr).filter(r=>r.rel==="stylesheet"||r.rel==="preload").map(r=>r.rel==="stylesheet"?{...r,rel:"prefetch",as:"style"}:{...r,rel:"prefetch"}))}function ht(e,t,n,a,r,s){let c=(i,l)=>n[l]?i.route.id!==n[l].route.id:!0,u=(i,l)=>{var d;return n[l].pathname!==i.pathname||((d=n[l].route.path)==null?void 0:d.endsWith("*"))&&n[l].params["*"]!==i.params["*"]};return s==="assets"?t.filter((i,l)=>c(i,l)||u(i,l)):s==="data"?t.filter((i,l)=>{var m;let d=a.routes[i.route.id];if(!d||!d.hasLoader)return!1;if(c(i,l)||u(i,l))return!0;if(i.route.shouldRevalidate){let h=i.route.shouldRevalidate({currentUrl:new URL(r.pathname+r.search+r.hash,window.origin),currentParams:((m=n[0])==null?void 0:m.params)||{},nextUrl:new URL(e,window.origin),nextParams:i.params,defaultShouldRevalidate:!0});if(typeof h=="boolean")return h}return!0}):[]}function br(e,t,{includeHydrateFallback:n}={}){return wr(e.map(a=>{let r=t.routes[a.route.id];if(!r)return[];let s=[r.module];return r.clientActionModule&&(s=s.concat(r.clientActionModule)),r.clientLoaderModule&&(s=s.concat(r.clientLoaderModule)),n&&r.hydrateFallbackModule&&(s=s.concat(r.hydrateFallbackModule)),r.imports&&(s=s.concat(r.imports)),s}).flat(1))}function wr(e){return[...new Set(e)]}function Cr(e){let t={},n=Object.keys(e).sort();for(let a of n)t[a]=e[a];return t}function Er(e,t){let n=new Set;return new Set(t),e.reduce((a,r)=>{let s=JSON.stringify(Cr(r));return n.has(s)||(n.add(s),a.push({key:s,link:r})),a},[])}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var kr=new Set([100,101,204,205]);function jr(e,t){let n=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return n.pathname==="/"?n.pathname="_root.data":t&&ie(n.pathname,t)==="/"?n.pathname=`${t.replace(/\/$/,"")}/_root.data`:n.pathname=`${n.pathname.replace(/\/$/,"")}.data`,n}function Pt(){let e=g.useContext(xe);return nt(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function Lr(){let e=g.useContext(De);return nt(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var rt=g.createContext(void 0);rt.displayName="FrameworkContext";function Bt(){let e=g.useContext(rt);return nt(e,"You must render this element inside a <HydratedRouter> element"),e}function Sr(e,t){let n=g.useContext(rt),[a,r]=g.useState(!1),[s,c]=g.useState(!1),{onFocus:u,onBlur:i,onMouseEnter:l,onMouseLeave:d,onTouchStart:m}=t,h=g.useRef(null);g.useEffect(()=>{if(e==="render"&&c(!0),e==="viewport"){let v=_=>{_.forEach(C=>{c(C.isIntersecting)})},x=new IntersectionObserver(v,{threshold:.5});return h.current&&x.observe(h.current),()=>{x.disconnect()}}},[e]),g.useEffect(()=>{if(a){let v=setTimeout(()=>{c(!0)},100);return()=>{clearTimeout(v)}}},[a]);let y=()=>{r(!0)},f=()=>{r(!1),c(!1)};return n?e!=="intent"?[s,h,{}]:[s,h,{onFocus:Ee(u,y),onBlur:Ee(i,f),onMouseEnter:Ee(l,y),onMouseLeave:Ee(d,f),onTouchStart:Ee(m,y)}]:[!1,h,{}]}function Ee(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function $r({page:e,...t}){let{router:n}=Pt(),a=g.useMemo(()=>jt(n.routes,e,n.basename),[n.routes,e,n.basename]);return a?g.createElement(Nr,{page:e,matches:a,...t}):null}function Ir(e){let{manifest:t,routeModules:n}=Bt(),[a,r]=g.useState([]);return g.useEffect(()=>{let s=!1;return xr(e,t,n).then(c=>{s||r(c)}),()=>{s=!0}},[e,t,n]),a}function Nr({page:e,matches:t,...n}){let a=ce(),{manifest:r,routeModules:s}=Bt(),{basename:c}=Pt(),{loaderData:u,matches:i}=Lr(),l=g.useMemo(()=>ht(e,t,i,r,a,"data"),[e,t,i,r,a]),d=g.useMemo(()=>ht(e,t,i,r,a,"assets"),[e,t,i,r,a]),m=g.useMemo(()=>{if(e===a.pathname+a.search+a.hash)return[];let f=new Set,v=!1;if(t.forEach(_=>{var w;let C=r.routes[_.route.id];!C||!C.hasLoader||(!l.some($=>$.route.id===_.route.id)&&_.route.id in u&&((w=s[_.route.id])!=null&&w.shouldRevalidate)||C.hasClientLoader?v=!0:f.add(_.route.id))}),f.size===0)return[];let x=jr(e,c);return v&&f.size>0&&x.searchParams.set("_routes",t.filter(_=>f.has(_.route.id)).map(_=>_.route.id).join(",")),[x.pathname+x.search]},[c,u,a,r,l,t,e,s]),h=g.useMemo(()=>br(d,r),[d,r]),y=Ir(d);return g.createElement(g.Fragment,null,m.map(f=>g.createElement("link",{key:f,rel:"prefetch",as:"fetch",href:f,...n})),h.map(f=>g.createElement("link",{key:f,rel:"modulepreload",href:f,...n})),y.map(({key:f,link:v})=>g.createElement("link",{key:f,...v})))}function Rr(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var zt=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{zt&&(window.__reactRouterVersion="7.6.2")}catch{}var At=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,ke=g.forwardRef(function({onClick:t,discover:n="render",prefetch:a="none",relative:r,reloadDocument:s,replace:c,state:u,target:i,to:l,preventScrollReset:d,viewTransition:m,...h},y){let{basename:f}=g.useContext(ne),v=typeof l=="string"&&At.test(l),x,_=!1;if(typeof l=="string"&&v&&(x=l,zt))try{let j=new URL(window.location.href),M=l.startsWith("//")?new URL(j.protocol+l):new URL(l),q=ie(M.pathname,f);M.origin===j.origin&&q!=null?l=q+M.search+M.hash:_=!0}catch{ee(!1,`<Link to="${l}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let C=Yn(l,{relative:r}),[w,$,L]=Sr(a,h),S=Pr(l,{replace:c,state:u,target:i,preventScrollReset:d,relative:r,viewTransition:m});function N(j){t&&t(j),j.defaultPrevented||S(j)}let R=g.createElement("a",{...h,...L,href:x||C,onClick:_||s?t:N,ref:Rr(y,$),target:i,"data-discover":!v&&n==="render"?"true":void 0});return w&&!v?g.createElement(g.Fragment,null,R,g.createElement($r,{page:C})):R});ke.displayName="Link";var Mr=g.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:a="",end:r=!1,style:s,to:c,viewTransition:u,children:i,...l},d){let m=je(c,{relative:l.relative}),h=ce(),y=g.useContext(De),{navigator:f,basename:v}=g.useContext(ne),x=y!=null&&Or(m)&&u===!0,_=f.encodeLocation?f.encodeLocation(m).pathname:m.pathname,C=h.pathname,w=y&&y.navigation&&y.navigation.location?y.navigation.location.pathname:null;n||(C=C.toLowerCase(),w=w?w.toLowerCase():null,_=_.toLowerCase()),w&&v&&(w=ie(w,v)||w);const $=_!=="/"&&_.endsWith("/")?_.length-1:_.length;let L=C===_||!r&&C.startsWith(_)&&C.charAt($)==="/",S=w!=null&&(w===_||!r&&w.startsWith(_)&&w.charAt(_.length)==="/"),N={isActive:L,isPending:S,isTransitioning:x},R=L?t:void 0,j;typeof a=="function"?j=a(N):j=[a,L?"active":null,S?"pending":null,x?"transitioning":null].filter(Boolean).join(" ");let M=typeof s=="function"?s(N):s;return g.createElement(ke,{...l,"aria-current":R,className:j,ref:d,style:M,to:c,viewTransition:u},typeof i=="function"?i(N):i)});Mr.displayName="NavLink";var Tr=g.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:a,replace:r,state:s,method:c=Re,action:u,onSubmit:i,relative:l,preventScrollReset:d,viewTransition:m,...h},y)=>{let f=Ar(),v=Fr(u,{relative:l}),x=c.toLowerCase()==="get"?"get":"post",_=typeof u=="string"&&At.test(u),C=w=>{if(i&&i(w),w.defaultPrevented)return;w.preventDefault();let $=w.nativeEvent.submitter,L=($==null?void 0:$.getAttribute("formmethod"))||c;f($||w.currentTarget,{fetcherKey:t,method:L,navigate:n,replace:r,state:s,relative:l,preventScrollReset:d,viewTransition:m})};return g.createElement("form",{ref:y,method:x,action:v,onSubmit:a?i:C,...h,"data-discover":!_&&e==="render"?"true":void 0})});Tr.displayName="Form";function Dr(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Ft(e){let t=g.useContext(xe);return O(t,Dr(e)),t}function Pr(e,{target:t,replace:n,state:a,preventScrollReset:r,relative:s,viewTransition:c}={}){let u=Jn(),i=ce(),l=je(e,{relative:s});return g.useCallback(d=>{if(mr(d,t)){d.preventDefault();let m=n!==void 0?n:Ye(i)===Ye(l);u(e,{replace:m,state:a,preventScrollReset:r,relative:s,viewTransition:c})}},[i,u,l,n,a,t,e,r,s,c])}var Br=0,zr=()=>`__${String(++Br)}__`;function Ar(){let{router:e}=Ft("useSubmit"),{basename:t}=g.useContext(ne),n=or();return g.useCallback(async(a,r={})=>{let{action:s,method:c,encType:u,formData:i,body:l}=gr(a,t);if(r.navigate===!1){let d=r.fetcherKey||zr();await e.fetch(d,n,r.action||s,{preventScrollReset:r.preventScrollReset,formData:i,body:l,formMethod:r.method||c,formEncType:r.encType||u,flushSync:r.flushSync})}else await e.navigate(r.action||s,{preventScrollReset:r.preventScrollReset,formData:i,body:l,formMethod:r.method||c,formEncType:r.encType||u,replace:r.replace,state:r.state,fromRouteId:n,flushSync:r.flushSync,viewTransition:r.viewTransition})},[e,t,n])}function Fr(e,{relative:t}={}){let{basename:n}=g.useContext(ne),a=g.useContext(re);O(a,"useFormAction must be used inside a RouteContext");let[r]=a.matches.slice(-1),s={...je(e||".",{relative:t})},c=ce();if(e==null){s.search=c.search;let u=new URLSearchParams(s.search),i=u.getAll("index");if(i.some(d=>d==="")){u.delete("index"),i.filter(m=>m).forEach(m=>u.append("index",m));let d=u.toString();s.search=d?`?${d}`:""}}return(!e||e===".")&&r.route.index&&(s.search=s.search?s.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(s.pathname=s.pathname==="/"?n:Q([n,s.pathname])),Ye(s)}function Or(e,t={}){let n=g.useContext(Rt);O(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:a}=Ft("useViewTransitionState"),r=je(e,{relative:t.relative});if(!n.isTransitioning)return!1;let s=ie(n.currentLocation.pathname,a)||n.currentLocation.pathname,c=ie(n.nextLocation.pathname,a)||n.nextLocation.pathname;return Te(r.pathname,c)!=null||Te(r.pathname,s)!=null}[...kr];const Vr="_button_1jbpj_161",Hr="_noMargin_1jbpj_189",qr="_regular_1jbpj_199",Xr="_small_1jbpj_202",Wr="_primary_1jbpj_213",Ur="_noHover_1jbpj_217",Yr="_secondary_1jbpj_233",Jr="_disabled_1jbpj_252",Gr="_hasErrors_1jbpj_272",Kr="_rounded_1jbpj_278",Zr="_hasArrowLeft_1jbpj_282",Qr="_pushprev_1jbpj_1",ea="_hasArrowRight_1jbpj_320",ta="_pushnext_1jbpj_1",na="_hasIcon_1jbpj_358",ra="_buttonContent_1jbpj_362",F={button:Vr,noMargin:Hr,regular:qr,small:Xr,primary:Wr,noHover:Ur,secondary:Yr,disabled:Jr,hasErrors:Gr,rounded:Kr,hasArrowLeft:Zr,pushprev:Qr,hasArrowRight:ea,pushnext:ta,hasIcon:na,buttonContent:ra},at=({content:e,color:t="primary",size:n="regular",arrow:a="none",disabled:r=!1,inputType:s,defaultChecked:c,hasErrors:u=!1,noHover:i=!1,rounded:l=!1,noMargin:d=!1,href:m,children:h,iconLeft:y,iconRight:f,...v})=>{const x=S=>{switch(S){case"left":return F.hasArrowLeft;case"right":return F.hasArrowRight;default:return""}},_=s==="radio"?c?"primary":"secondary":t,C=P([F.button,F[_],F[n],x(a),i||s==="radio"?F.noHover:null,l&&F.rounded,u&&F.hasErrors,r?F.disabled:null,d?F.noMargin:null,y||f?F.hasIcon:null]),w={"aria-invalid":u||void 0,href:!r&&(m!=null&&m.length)?m:void 0,className:C,...v},$=S=>b.Children.toArray(ye(S)).map(R=>{if(!b.isValidElement(R))return null;const j=R,M=j.type===ke&&typeof j.props=="object"&&j.props!==null&&"to"in j.props;return!r&&M?b.cloneElement(j,{className:C,key:`button-${j.key}`,to:j.props.to},y,o.jsx("span",{className:F.buttonContent,children:j.props.children}),f):b.createElement("button",{...w,key:`button-${j.key}`},y,o.jsx("span",{className:F.buttonContent,children:e||(j.props?j.props.children:null)}),f)});if(s==="button")return o.jsxs("button",{type:"button",...w,children:[y,o.jsx("span",{className:F.buttonContent,children:e||h}),f]});if(s==="radio"){const S={...w};return delete S.href,o.jsxs("label",{className:C,children:[o.jsx("input",{...S,type:"radio"}),y,o.jsx("span",{className:F.buttonContent,children:e}),f]})}if(m!=null&&m.length&&!r){const S={...w};return"type"in S&&delete S.type,o.jsxs("a",{...S,children:[y,o.jsx("span",{className:F.buttonContent,children:e||h}),f]})}return b.isValidElement(h)&&h.type===ke?o.jsx(b.Fragment,{children:$(b.Children.toArray(h))}):o.jsxs("button",{...w,children:[y,o.jsx("span",{className:F.buttonContent,children:e||h}),f]})},aa="_checkBoxIcon_1kc3w_1",sa="_showBox_1kc3w_22",oa="_hasErrors_1kc3w_27",ia="_checked_1kc3w_37",la="_disabled_1kc3w_53",ca="_checkmark_1kc3w_58",de={checkBoxIcon:aa,showBox:sa,hasErrors:oa,checked:ia,disabled:la,checkmark:ca},Je=({size:e="20px",checked:t=!1,disabled:n=!1,showBox:a=!0,hasErrors:r=!1,checkmarkCharacter:s="✔"})=>{const c={height:e,width:e,fontSize:e},u=[de.checkBoxIcon,t&&de.checked,n&&de.disabled,a&&de.showBox,r&&de.hasErrors].filter(Boolean).join(" ");return o.jsx("span",{className:u,style:c,children:o.jsx("span",{"aria-hidden":!0,className:de.checkmark,children:t?s:""})})},te="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32.275'%20height='30.469'%20focusable='false'%3e%3cpath%20fill='%239d2024'%20d='m0%2014.355%202.246-6.933c5.176%201.823%208.936%203.402%2011.28%204.736-.62-5.892-.945-9.944-.977-12.158h7.08c-.098%203.223-.472%207.26-1.123%2012.11%203.353-1.693%207.194-3.256%2011.523-4.688l2.246%206.933c-4.134%201.368-8.186%202.28-12.158%202.735%201.986%201.725%204.785%204.801%208.399%209.228l-5.86%204.15c-1.888-2.57-4.118-6.07-6.69-10.497-2.408%204.59-4.524%208.089-6.347%2010.498l-5.762-4.15c3.776-4.656%206.478-7.732%208.106-9.23-4.2-.813-8.187-1.724-11.963-2.734'/%3e%3c/svg%3e",ua="_checkBoxInput_f1w9m_1",da="_requiredSymbol_f1w9m_6",ha="_contentOnly_f1w9m_13",fa="_disabled_f1w9m_13",ma="_labelText_f1w9m_19",pa="_hasErrors_f1w9m_27",he={checkBoxInput:ua,requiredSymbol:da,contentOnly:ha,disabled:fa,labelText:ma,hasErrors:pa},Ot=({checked:e=!1,disabled:t=!1,required:n=!1,requiredGroup:a=!1,id:r,name:s="",onChange:c,contentOnly:u=!1,hasErrors:i=!1,checkmarkCharacter:l="✔",tabIndex:d=0,children:m,"aria-controls":h,"aria-describedby":y,value:f})=>{const v=[he.checkBoxInput,u&&he.contentOnly,t&&he.disabled,i&&he.hasErrors].filter(Boolean).join(" "),x={checked:e,disabled:t,showBox:!u,hasErrors:u&&i,checkmarkCharacter:l},_={id:r,name:s,type:"checkbox",checked:e,disabled:t,required:n||a,onChange:c,tabIndex:d,"aria-controls":h,"aria-invalid":i?"true":void 0,"aria-describedby":y,value:f};return o.jsxs("label",{htmlFor:r,className:v,children:[u?o.jsx(Je,{...x}):o.jsxs(o.Fragment,{children:[o.jsx(Je,{...x}),o.jsx("input",{..._})]}),o.jsxs("span",{className:he.labelText,children:[m,n&&o.jsx("img",{src:te,alt:"",className:he.requiredSymbol})]})]})},_a="_checkBoxList_1sp8d_1",ga="_requiredSymbol_1sp8d_16",ft={checkBoxList:_a,requiredSymbol:ga},va="_headerContainer_t2si7_1",ya="_header_t2si7_1",xa="_bigHeader_t2si7_16",$e={headerContainer:va,header:ya,"size-1":"_size-1_t2si7_8",bigHeader:xa,"size-2":"_size-2_t2si7_28","size-3":"_size-3_t2si7_36","size-4":"_size-4_t2si7_44","size-5":"_size-5_t2si7_52"},st=({id:e,content:t,size:n=1,big:a,label:r,htmlTag:s,htmlFor:c,children:u})=>{const i=s||`h${n}`,l=P([$e.header,$e[`size-${n}`],a&&$e.bigHeader]),d=r!=null&&r.length&&typeof r=="string"?{"--label":`"${r}"`}:void 0,m=b.createElement(i,{className:l,id:e||void 0,htmlFor:c||void 0,style:d},t!=null&&t.length?t:u);return o.jsx("div",{className:$e.headerContainer,children:m})},Vt=({legend:e,legendSize:t,required:n=!1,compact:a=!1,children:r})=>{const s=c=>ye(c).map(i=>{var l;return b.isValidElement(i)&&((l=i.type)==null?void 0:l.displayName)==="RadioButtonListItem"?b.cloneElement(i,{requiredGroup:n,compact:a,key:`checkboxListItem-${i.key}`}):i});return o.jsxs("fieldset",{className:ft.checkBoxList,children:[!!(e!=null&&e.length)&&o.jsxs("legend",{children:[t?o.jsx(st,{size:t,children:e}):e,n&&o.jsx("img",{src:te,alt:"",className:ft.requiredSymbol})]}),s(b.Children.toArray(r))]})},ba="_checkBoxListItem_jnb8z_1",wa="_contentOnly_jnb8z_26",Ca="_compact_jnb8z_26",Ea="_disabled_jnb8z_41",ka="_checked_jnb8z_44",fe={checkBoxListItem:ba,contentOnly:wa,compact:Ca,disabled:Ea,checked:ka},Ht=({checked:e=!1,disabled:t=!1,required:n=!1,requiredGroup:a=!1,id:r,name:s="",onChange:c,contentOnly:u=!1,compact:i=!1,hasErrors:l=!1,checkmarkCharacter:d="✔","aria-controls":m,"aria-describedby":h,children:y,value:f})=>{const v=P([fe.checkBoxListItem,e&&fe.checked,t&&fe.disabled,i&&fe.compact,u&&fe.contentOnly,l&&fe.hasErrors]),x={onChange:c??(()=>{}),checked:e,disabled:t,required:n,requiredGroup:a,contentOnly:u,hasErrors:l,"aria-controls":m,"aria-describedby":h,id:r,name:s,checkmarkCharacter:d,value:f};return o.jsx("div",{className:v,children:o.jsx(Ot,{...x,children:y})})},ja="_container_f8z49_1",La={container:ja},qt=({maxWidth:e,children:t})=>{const n={"--max-width":e!=null&&e.length?e:void 0};return o.jsx("div",{className:La.container,style:n,children:t})},Sa="_contentBox_1ndvc_1",$a="_link_1ndvc_8",Ia="_content_1ndvc_1",Na="_title_1ndvc_25",Ra="_secondary_1ndvc_28",Ma="_regular_1ndvc_36",Ta="_large_1ndvc_45",me={contentBox:Sa,link:$a,default:"_default_1ndvc_21",content:Ia,title:Na,secondary:Ra,regular:Ma,large:Ta},Da=({title:e=null,titleSize:t="regular",content:n="",children:a,color:r="default",href:s=null})=>{const c=()=>{if(!e)return null;const h=`${me.title} ${me[t]}`;return o.jsx("h2",{className:h,children:e})},u=me[r]||"",i=s?me.link:"",l=`${me.contentBox} ${u} ${i}`.trim(),d=n!=null&&n.length?n:a,m=o.jsxs(o.Fragment,{children:[c(),o.jsx("div",{className:me.content,children:d})]});return s?o.jsx("a",{href:s,className:l,children:m}):o.jsx("div",{className:l,children:m})},Pa="_descriptionDetails_1d1dj_1",Ba="_compact_1d1dj_7",mt={descriptionDetails:Pa,compact:Ba},za=({compact:e=!1,titleWidth:t,children:n})=>o.jsx("dd",{className:P([mt.descriptionDetails,e&&mt.compact]),style:{"--title-width":t||void 0},children:n}),Aa="_descriptionList_w11ua_1",Fa="_compact_w11ua_13",pt={descriptionList:Aa,compact:Fa},Oa=({compact:e=!1,titleWidth:t,children:n})=>{const a=r=>ye(r).map(c=>b.isValidElement(c)?b.cloneElement(c,{compact:e,titleWidth:t,key:`descriptionListItem-${c.key}`}):c);return b.createElement("dl",{className:P([pt.descriptionList,e&&pt.compact]),style:{"--title-width":t||void 0}},a(b.Children.toArray(n)))},Va="_descriptionTerm_uuapd_1",Ha="_compact_uuapd_8",_t={descriptionTerm:Va,compact:Ha},qa=({compact:e=!1,titleWidth:t,children:n})=>o.jsx("dt",{className:P([_t.descriptionTerm,e&&_t.compact]),style:{"--title-width":t||void 0},children:n}),Xa="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='25'%20height='25'%3e%3cpath%20fill='%23072938'%20stroke='%23072938'%20stroke-linecap='round'%20stroke-width='3.23'%20d='m3.97%203.57%2017.44%2018.2m-17.44.01L21.41%203.57'/%3e%3c/svg%3e",Wa="_dialog_pl6ui_19",Ua="_backdrop_pl6ui_34",Ya="_dialogContainer_pl6ui_42",Ja="_modalInVertical_pl6ui_1",Ga="_dialogContent_pl6ui_52",Ka="_noPadding_pl6ui_57",Za="_closeButton_pl6ui_65",Qa="_isSidebar_pl6ui_94",es="_left_pl6ui_117",ts="_modalInHorizontalLeft_pl6ui_1",ns="_right_pl6ui_123",rs="_modalInHorizontalRight_pl6ui_1",Z={dialog:Wa,backdrop:Ua,dialogContainer:Ya,modalInVertical:Ja,dialogContent:Ga,noPadding:Ka,closeButton:Za,isSidebar:Qa,left:es,modalInHorizontalLeft:ts,right:ns,modalInHorizontalRight:rs},as=({maxWidth:e="none",noPadding:t,closeButton:n,onClickOutside:a,modal:r=!0,attachTo:s,hidden:c=!1,children:u})=>{const[i,l]=b.useState(null),d=b.useRef(null),m=b.useCallback(v=>{v&&kt(v)},[]);b.useEffect(()=>{if(c)return;const v=x=>{x.key==="Escape"&&a&&a()};return document.addEventListener("keydown",v,!1),()=>{document.removeEventListener("keydown",v,!1)}},[c,a]),b.useEffect(()=>{if(typeof window>"u")return;const x=(()=>{const C="dibk-design-dialog-root";let w=document.getElementById(C);return w||(w=document.createElement("div"),w.setAttribute("id",C),document.body.appendChild(w)),w})(),_=document.createElement("div");return x.appendChild(_),l(_),()=>{l(null),x.contains(_)&&x.removeChild(_)}},[]),b.useEffect(()=>{if(c||!r)return;const v=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=v}},[c,r]);const h=s&&P([Z.isSidebar,Z[s]]),y={"--max-width":e};if(c||!i)return null;const f=r?{role:"dialog","aria-modal":"true"}:{role:"dialog"};return Gt.createPortal(o.jsxs("div",{className:P([Z.dialog,h]),onClick:a,...f,children:[r&&o.jsx("div",{className:Z.backdrop,"aria-hidden":"true"}),o.jsx("div",{ref:d,className:Z.dialogContainer,style:y,onClick:v=>v.stopPropagation(),children:o.jsxs("div",{ref:m,className:P([Z.dialogContent,t&&Z.noPadding]),children:[n&&o.jsx("button",{type:"button","aria-label":"Lukk dialog",onClick:a,className:P([Z.closeButton,t&&Z.noPadding]),children:o.jsx("img",{src:Xa,alt:""})}),o.jsx("div",{"aria-live":"assertive",children:u})]})})]}),i)},ss="_dragAndDropFileInput_pfifv_1",os="_requiredSymbol_pfifv_1",is="_dragAndDropContainer_pfifv_8",ls="_highlighted_pfifv_25",Ie={dragAndDropFileInput:ss,requiredSymbol:os,dragAndDropContainer:is,highlighted:ls},cs="data:image/svg+xml,%3csvg%20width='20'%20height='20'%20viewBox='0%200%2020%2020'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%20role='presentation'%3e%3cg%20clip-path='url(%23clip0_1089_7422)'%3e%3cmask%20id='mask0_1089_7422'%20maskUnits='userSpaceOnUse'%20x='0'%20y='0'%20width='20'%20height='20'%20style='mask-type:%20alpha;'%3e%3crect%20width='20'%20height='20'%20style='fill:%20white;'%3e%3c/rect%3e%3c/mask%3e%3cg%20mask='url(%23mask0_1089_7422)'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M0%2010C0%204.4775%204.4775%200%2010%200C15.5225%200%2020%204.4775%2020%2010C20%2015.5225%2015.5225%2020%2010%2020C4.4775%2020%200%2015.5225%200%2010ZM11%2014.0766C11%2014.8122%2010.5188%2015.3333%209.83335%2015.3333C9.13335%2015.3333%208.66669%2014.8122%208.66669%2014.0766C8.66669%2013.341%209.13335%2012.8046%209.83335%2012.8046C10.5188%2012.8046%2011%2013.341%2011%2014.0766ZM10.65%2011.9463H8.98752L8.75419%204.66663H10.8834L10.65%2011.9463Z'%20style='fill:%20rgb(219,%200,%200);'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_1089_7422'%3e%3crect%20width='20'%20height='20'%20fill='white'%3e%3c/rect%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",us="_errorMessage_i8u6b_7",ds="_errorSign_i8u6b_19",gt={errorMessage:us,errorSign:ds},ve=({id:e,content:t=""})=>{const n=()=>({id:e!=null&&e.length?e:void 0,className:gt.errorMessage});return(typeof t=="string"?t.trim().length>0:!!t)?o.jsxs("span",{"aria-live":"polite",...n(),children:[o.jsx("img",{src:cs,alt:"",className:gt.errorSign}),t]}):null},hs="_label_18de6_1",fs="_inline_18de6_11",ms="_normalCursor_18de6_14",He={label:hs,inline:fs,normalCursor:ms},le=({inline:e=!1,normalCursor:t=!1,htmlTag:n="label",children:a,id:r,...s})=>{const c=[He.label,e&&He.inline,t&&He.normalCursor].filter(Boolean).join(" "),u={...s,className:c,id:r||void 0};return b.createElement(n,u,a)},ps=({id:e,name:t,onSelectChange:n,onDragAndDropChange:a,label:r="",contentOnly:s=!1,buttonColor:c="primary",buttonContent:u,buttonContentWhenSelectedFile:i,selectedFileName:l,defaultContent:d="",hasErrors:m=!1,errorMessage:h="",required:y=!1,children:f,"data-transaction-name":v})=>{const[x,_]=b.useState(!1),C=b.useRef(null),w=b.useRef(null),$=I=>{I.preventDefault(),I.stopPropagation()},L=(I,B)=>I||B,S=()=>{var I;(I=w.current)==null||I.click()},N=()=>`${e}-errorMessage`,R={id:e,"aria-describedby":m&&(h!=null&&h.toString().length)?N():void 0,"aria-invalid":m?"true":void 0,name:t,required:y},j=l&&i||u,M=b.useCallback(()=>_(!0),[]),q=b.useCallback(()=>_(!1),[]),X=b.useCallback(I=>{var B;$(I),(B=I.dataTransfer)!=null&&B.files&&a(I.dataTransfer.files),_(!1)},[a]);return b.useEffect(()=>{const I=C.current;if(I)return["dragenter","dragover"].forEach(B=>{I.addEventListener(B,M)}),["dragleave","drop"].forEach(B=>{I.addEventListener(B,q)}),["dragenter","dragover","dragleave","drop"].forEach(B=>{I.addEventListener(B,$)}),I.addEventListener("drop",X),()=>{["dragenter","dragover","dragleave","drop"].forEach(B=>{I.removeEventListener(B,$),I.removeEventListener(B,M),I.removeEventListener(B,q)}),I.removeEventListener("drop",X)}},[a]),o.jsxs("div",{className:Ie.dragAndDropFileInput,children:[o.jsxs(le,{htmlFor:e,children:[r,y&&o.jsx("img",{src:te,alt:"",className:Ie.requiredSymbol})]}),o.jsx("div",{children:f}),!s&&o.jsxs("div",{ref:C,className:`${Ie.dragAndDropContainer} ${x?Ie.highlighted:""}`,children:[l?o.jsx("div",{children:o.jsxs("span",{children:[o.jsx("b",{children:"Valgt fil:"})," ",l]})}):o.jsx("div",{children:"Slipp fil her"}),o.jsx("input",{...R,ref:w,type:"file",onChange:n}),u&&o.jsxs(o.Fragment,{children:[o.jsx("div",{children:l?"":"eller klikk på knappen for å velge fil"}),o.jsx(at,{size:"small",inputType:"button",color:c,onClick:S,content:j,hasErrors:m,"data-transaction-name":v})]})]}),s&&o.jsx("span",{children:L(l,d)}),o.jsx(ve,{id:N(),content:h})]})},Xt="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2020%2020'%20role='presentation'%3e%3cpath%20d='M10%200C4.4775%200%200%204.4775%200%2010C0%2015.5225%204.4775%2020%2010%2020C15.5225%2020%2020%2015.5225%2020%2010C20%204.4775%2015.5225%200%2010%200ZM8.30583%2013.3417C8.77583%2011.8508%209.66583%2010.065%209.82333%209.61333C10.0508%208.9575%209.6475%208.66667%208.37333%209.7875L8.09%209.25417C9.54333%207.67333%2012.5358%207.31583%2011.5175%209.765C10.8817%2011.2942%2010.4267%2012.3267%2010.1667%2013.1233C9.7875%2014.2842%2010.745%2013.8133%2011.6825%2012.9475C11.81%2013.1558%2011.8517%2013.2233%2011.9792%2013.4633C9.8975%2015.445%207.58667%2015.62%208.30583%2013.3417ZM12.2575%206.53417C11.8142%206.91167%2011.1575%206.90333%2010.79%206.51583C10.4225%206.12833%2010.4842%205.50917%2010.9267%205.13167C11.37%204.75417%2012.0267%204.76333%2012.3942%205.15C12.76%205.53833%2012.7%206.1575%2012.2575%206.53417Z'%20style='fill:%20rgb(0,%2048,%2069);'%3e%3c/path%3e%3c/svg%3e",_s="_errorBoxContainer_88ulw_7",gs="_messageIn_88ulw_1",vs="_warning_88ulw_14",ys="_error_88ulw_7",xs="_fullScreen_88ulw_22",bs="_errorBox_88ulw_7",ws="_infoSign_88ulw_38",pe={errorBoxContainer:_s,messageIn:gs,warning:vs,error:ys,fullScreen:xs,errorBox:bs,infoSign:ws},Cs=({type:e="warning",fullScreen:t=!1,children:n=""})=>o.jsx("div",{className:P([pe.errorBoxContainer,pe[e],t&&pe.fullScreen]),children:o.jsxs("div",{className:P([pe.errorBox,t&&pe.fullScreen]),children:[o.jsx("img",{src:Xt,alt:"",className:pe.infoSign}),n]})}),Es="_footer_19fad_1",ks={footer:Es},js=({children:e})=>o.jsx("footer",{className:ks.footer,children:o.jsx(qt,{children:e})}),Ls="_infoBox_1mh67_7",Ss="_infoSign_1mh67_15",vt={infoBox:Ls,infoSign:Ss},$s=({children:e=""})=>o.jsxs("div",{className:vt.infoBox,children:[o.jsx("img",{src:Xt,alt:"",className:vt.infoSign}),e]}),Is="_inputField_9tnyr_1",Ns="_noMargin_9tnyr_4",Rs="_requiredSymbol_9tnyr_10",Ms="_file_9tnyr_17",Ts="_input_9tnyr_1",Ds="_hasErrors_9tnyr_50",Ps="_fileInputContainer_9tnyr_62",U={inputField:Is,noMargin:Ns,requiredSymbol:Rs,file:Ms,input:Ts,hasErrors:Ds,fileInputContainer:Ps},Bs=e=>{const t=typeof e=="string"?new Date(e):e;if(Number.isNaN(t.getTime()))return String(e??"");const n=String(t.getDate()).padStart(2,"0"),a=String(t.getMonth()+1).padStart(2,"0"),r=t.getFullYear();return`${n}.${a}.${r}`},yt=e=>{if(e==null||e==="")return;const t=e instanceof Date?e:new Date(e);if(Number.isNaN(t.getTime()))return;const n=t.getFullYear(),a=String(t.getMonth()+1).padStart(2,"0"),r=String(t.getDate()).padStart(2,"0");return`${n}-${a}-${r}`},zs=e=>!e||["text","search","url","email","tel","password","number"].includes(e),As=({id:e,onChange:t=()=>{},onBlur:n,onFocus:a,name:r="",type:s="text",disabled:c=!1,required:u=!1,readOnly:i,width:l,value:d,defaultValue:m,elementKey:h,label:y="",contentOnly:f=!1,buttonColor:v="primary",buttonContent:x,selectedFileName:_,placeholder:C="",defaultContent:w="",min:$,max:L,role:S,"aria-describedby":N,"aria-autocomplete":R,hasErrors:j=!1,errorMessage:M="",noMargin:q=!1})=>{const X=b.useRef(null),I=()=>`${e}-errorMessage`,B=l?{maxWidth:l}:{},k=s==="date"&&!c&&!i,D=()=>{var E;if(!k||!X.current)return;document.activeElement!==X.current&&X.current.focus();const p=X.current;(E=p.showPicker)==null||E.call(p)},z=p=>{D(),a==null||a(p)},W=(()=>{if(s==="file")return{};if(s==="date"){const E=d!==void 0?yt(d):void 0,T=d===void 0&&m!==void 0?yt(m):void 0;return d!==void 0?{value:E??""}:m!==void 0?{defaultValue:T}:{}}const p=E=>E instanceof Date?String(E.getTime()):E;return d!==void 0?{value:p(d)}:m!==void 0?{defaultValue:p(m)}:{}})(),ae={name:r,readOnly:i,disabled:c,required:u,type:s,role:S,id:e,min:$,max:L,onChange:t,onBlur:n,onFocus:z,placeholder:s==="file"?void 0:C,className:j?U.hasErrors:void 0,"aria-describedby":j&&M?I():N,"aria-invalid":j||void 0,"aria-autocomplete":zs(s)?R:void 0,style:B,...W};if(f){const p=d??m??"",E=s==="date"?p?Bs(p):w:String(p??"")||w;return o.jsxs("div",{className:P([U.inputField,U[s],q&&U.noMargin]),children:[o.jsxs(le,{htmlFor:e,children:[y,u&&o.jsx("img",{src:te,alt:"",className:U.requiredSymbol})]}),o.jsx("span",{children:E}),j&&M?o.jsx(ve,{id:I(),content:M}):null]})}return o.jsxs("div",{className:P([U.inputField,U[s],q&&U.noMargin]),children:[o.jsxs(le,{htmlFor:e,children:[y,u&&o.jsx("img",{src:te,alt:"",className:U.requiredSymbol}),s==="file"&&o.jsxs("div",{className:U.fileInputContainer,children:[o.jsx("span",{className:U.input,children:_}),x&&o.jsx(at,{color:v,inputType:"button",onClick:()=>{var p;return(p=X.current)==null?void 0:p.click()},content:x})]})]}),o.jsx("input",{...ae,ref:X},h||e),j&&M?o.jsx(ve,{id:I(),content:M}):null]})},Fs="_lead_176gy_1",Os={lead:Fs},Vs=({id:e,htmlTag:t="p",children:n})=>b.createElement(t,{className:Os.lead,id:e||void 0},n),Hs="_list_16gsl_1",qs="_compact_16gsl_10",xt={list:Hs,compact:qs},Xs=({listStyle:e,compact:t=!1,ordered:n=!1,children:a})=>{const r=i=>ye(i).map(d=>b.isValidElement(d)?b.cloneElement(d,{compact:t,key:`listItem-${d.key}`}):d),s=n?"ol":"ul",c=n?"decimal":"disc";return b.createElement(s,{className:`${xt.list} ${t?xt.compact:""}`,style:{["--listStyle"]:e||c}},r(b.Children.toArray(a)))},Ws="_listItem_33xs0_1",Us="_compact_33xs0_5",bt={listItem:Ws,compact:Us},Ys=({compact:e=!1,children:t})=>{const n=P([bt.listItem,e&&bt.compact]);return o.jsx("li",{className:n,children:t})},Js="_loadingAnimation_hzd5u_1",Gs="_fixed_hzd5u_17",qe={loadingAnimation:Js,fixed:Gs},Ks=({fixed:e=!1,message:t=""})=>{const n=e?`${qe.loadingAnimation} ${qe.fixed}`:qe.loadingAnimation;return o.jsx("div",{className:n,children:t})},Zs="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20version='1.1'%20id='Layer_1'%20x='0px'%20y='0px'%20viewBox='0%200%20340.2%20412.5'%20style='enable-background:new%200%200%20340.2%20412.5;'%20xml:space='preserve'%3e%3cstyle%20type='text/css'%3e%20.st0{fill:%23003045;}%20.st1{fill:%2389BAD6;}%20.st2{fill:%23FFFFFF;}%20%3c/style%3e%3cg%3e%3crect%20x='0'%20y='253.2'%20class='st0'%20width='340.2'%20height='105.8'/%3e%3crect%20x='0'%20class='st1'%20width='340.2'%20height='249.4'/%3e%3cg%3e%3cpolygon%20class='st2'%20points='138.5,189.9%20157,202%20157,118.8%20201.7,147.8%20201.7,106.6%20138.5,65.5%20'/%3e%3cpolygon%20class='st2'%20points='63.3,197.7%2063.3,153.5%20106.3,125.5%20106.3,30.2%2030.2,79.7%2030.2,219.2%20'/%3e%3cpolygon%20class='st2'%20points='208.9,101.9%20208.9,181.7%20238,200.5%20238,40.1%20175.9,80.4%20'/%3e%3cpolygon%20class='st2'%20points='113.4,30.2%20113.4,165.2%20131.4,153.5%20131.4,60.9%20131.4,41.9%20'/%3e%3cpolygon%20class='st2'%20points='259.5,110.2%20245.1,119.6%20245.1,195.9%20259.5,186.5%20309.9,219.2%20309.9,142.6%20'/%3e%3c/g%3e%3cpolygon%20class='st0'%20points='0,362.8%2075.6,412%2075.6,362.8%20'/%3e%3cg%3e%3cg%3e%3cpath%20class='st2'%20d='M30.2,277.5h6.2c7.3,0,11.6,2.9,11.6,11s-5.3,11-11.6,11h-6.2V277.5z%20M36.5,295.7c5.6,0,7.3-2.2,7.3-7.2%20c0-5-1.7-7.5-7.3-7.5h-2v14.6H36.5z'/%3e%3cpath%20class='st2'%20d='M51.9,277.5h4.3v21.9h-4.3V277.5z'/%3e%3cpath%20class='st2'%20d='M65.5,291.2h-0.2v8.2H61v-21.9h6.2c5.1,0,8.6,1.8,8.6,6.5c0,3.7-2.3,6.2-5.8,7l7.5,8.5h-5.1L65.5,291.2z%20M67.2,288.2c2.7,0,4.3-1.3,4.3-3.8c0-2.5-1.6-3.5-4.3-3.5h-1.9v7.4H67.2z'/%3e%3cpath%20class='st2'%20d='M80,277.5h14v3.6h-9.7v5.3h6.5v3.4h-6.5v6H94v3.6H80V277.5z'/%3e%3cpath%20class='st2'%20d='M97.8,277.5h4.3v9.8l8.7-9.8h4.4l-7.9,8.7l8.4,13.2h-4.8l-6.2-10.2l-2.6,2.8v7.4h-4.3V277.5z'/%3e%3cpath%20class='st2'%20d='M122.8,281.1h-6.3v-3.6h16.8v3.6H127v18.3h-4.3V281.1z'/%3e%3cpath%20class='st2'%20d='M134.7,288.4c0-7.6,5.4-11.5,10.8-11.5c6.4,0,10.8,3.9,10.8,11.5c0,7.6-5.4,11.5-10.8,11.5%20C139.1,299.9,134.7,296,134.7,288.4z%20M151.9,288.6c0-5.2-2.5-8-6.5-8c-3.9,0-6.5,2.8-6.5,7.7c0,5.2,2.5,8.1,6.5,8.1%20C149.4,296.3,151.9,293.5,151.9,288.6z'/%3e%3cpath%20class='st2'%20d='M164.4,291.2h-0.2v8.2h-4.3v-21.9h6.2c5.1,0,8.6,1.8,8.6,6.5c0,3.7-2.3,6.2-5.8,7l7.5,8.5h-5.1L164.4,291.2z%20M166.2,288.2c2.7,0,4.3-1.3,4.3-3.8c0-2.5-1.5-3.5-4.3-3.5h-1.9v7.4H166.2z'/%3e%3cpath%20class='st2'%20d='M184.5,279.7l-0.8-2.2h4.4l8.6,21.9h-4.5l-1.7-4.5h-8.1l-1.7,4.5h-4.1L184.5,279.7z%20M183.6,291.7h5.8l-2.3-6%20l-0.6-1.9l-0.6,1.9L183.6,291.7z'/%3e%3cpath%20class='st2'%20d='M201.7,281.1h-6.3v-3.6h16.8v3.6h-6.3v18.3h-4.3V281.1z'/%3e%3cpath%20class='st2'%20d='M215.3,277.5h14v3.6h-9.7v5.3h6.5v3.4h-6.5v6h9.7v3.6h-14V277.5z'/%3e%3cpath%20class='st2'%20d='M237.7,281.1h-6.3v-3.6h16.8v3.6H242v18.3h-4.3V281.1z'/%3e%3c/g%3e%3cg%3e%3cpath%20class='st2'%20d='M30.2,312.9H44v3.6h-9.5v5.5h6.2v3.3h-6.2v9.6h-4.3V312.9z'/%3e%3cpath%20class='st2'%20d='M45.6,323.9c0-7.6,5.4-11.5,10.8-11.5c6.4,0,10.8,3.9,10.8,11.5c0,7.6-5.4,11.5-10.8,11.5%20C50,335.3,45.6,331.4,45.6,323.9z%20M62.8,324c0-5.2-2.5-8-6.5-8c-3.9,0-6.5,2.8-6.5,7.7c0,5.2,2.5,8.1,6.5,8.1%20C60.3,331.7,62.8,328.9,62.8,324z'/%3e%3cpath%20class='st2'%20d='M75.3,326.7h-0.2v8.2h-4.3v-21.9H77c5.1,0,8.6,1.8,8.6,6.5c0,3.7-2.3,6.2-5.8,7l7.5,8.5h-5.1L75.3,326.7z%20M77,323.7c2.7,0,4.3-1.3,4.3-3.8c0-2.5-1.5-3.5-4.3-3.5h-1.9v7.4H77z'/%3e%3cpath%20class='st2'%20d='M97.6,312.9h6.5c6,0,8.5,2,8.5,5.5c0,3-1.7,4.5-4.1,5.1v0.1c2.6,0.5,4.5,1.7,4.5,5.1c0,3.5-2.5,6.2-8.6,6.2%20h-6.7V312.9z%20M104.3,321.9c3.2,0,4.1-1.1,4.1-2.9c0-1.8-1.2-2.6-4.1-2.6h-2.4v5.5H104.3z%20M104.4,331.3c3.2,0,4.3-1.1,4.3-3%20c0-1.9-1.1-3-4.3-3h-2.6v6H104.4z'/%3e%3cpath%20class='st2'%20d='M121.2,325.8l-7.2-12.9h4.7l4.8,9.2l4.9-9.2h4.2l-7.2,12.9v9h-4.3V325.8z'/%3e%3cpath%20class='st2'%20d='M133,323.9c0-7.6,4.8-11.5,10.7-11.5c3.6,0,5.7,1.1,6.9,2.1v4.8c-1.2-1.9-3.2-3.3-6.4-3.3%20c-4.4,0-6.9,2.7-6.9,7.7c0,5,2.4,8.3,6.3,8.3c1,0,2-0.1,2.7-0.4v-6.8h4.3v8.8c-1.5,1-3.9,1.8-7.2,1.8%20C137.3,335.3,133,331.5,133,323.9z'/%3e%3cpath%20class='st2'%20d='M153.8,323.9c0-7.6,4.8-11.5,10.7-11.5c3.6,0,5.7,1.1,6.9,2.1v4.8c-1.2-1.9-3.2-3.3-6.4-3.3%20c-4.4,0-6.9,2.7-6.9,7.7c0,5,2.4,8.3,6.3,8.3c1,0,2-0.1,2.7-0.4v-6.8h4.3v8.8c-1.5,1-3.9,1.8-7.2,1.8%20C158,335.3,153.8,331.5,153.8,323.9z'/%3e%3cpath%20class='st2'%20d='M175.7,312.9h4.3v9.8l8.7-9.8h4.4l-7.9,8.7l8.4,13.2h-4.8l-6.2-10.2l-2.6,2.8v7.4h-4.3V312.9z'/%3e%3cpath%20class='st2'%20d='M193.8,312.9h4.4l5.2,15.4h0.1l5.3-15.4h4.1l-7.9,21.9h-3.5L193.8,312.9z'/%3e%3cpath%20class='st2'%20d='M219.3,315.1l-0.8-2.2h4.4l8.6,21.9h-4.5l-1.7-4.5h-8.1l-1.7,4.5h-4.1L219.3,315.1z%20M218.4,327.1h5.8l-2.3-6%20l-0.6-1.9l-0.6,1.9L218.4,327.1z'/%3e%3cpath%20class='st2'%20d='M234.1,312.9h4.3v18.3h8.2v3.7h-12.4V312.9z'/%3e%3cpath%20class='st2'%20d='M249.7,312.9h4.3v21.9h-4.3V312.9z'/%3e%3cpath%20class='st2'%20d='M263.4,316.5h-6.3v-3.6h16.8v3.6h-6.3v18.3h-4.3V316.5z'/%3e%3cpath%20class='st2'%20d='M277,312.9h14v3.6h-9.7v5.3h6.5v3.4h-6.5v6h9.7v3.6h-14V312.9z'/%3e%3cpath%20class='st2'%20d='M299.4,316.5h-6.3v-3.6h16.8v3.6h-6.3v18.3h-4.3V316.5z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",Qs="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2019.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='14%20337%20406%20110'%20style='enable-background:new%2014%20337%20406%20110;'%20xml:space='preserve'%3e%3cstyle%20type='text/css'%3e%20.st0{display:none;}%20.st1{fill:%23003045;}%20.st2{fill:%2389BAD6;}%20.st3{fill:%23FFFFFF;}%20.st4{display:inline;fill:%23FFFFFF;}%20.st5{display:inline;fill:%23D7D4D1;}%20%3c/style%3e%3cg%20id='skisse__x28_forstørret_x29_'%20class='st0'%3e%3c/g%3e%3cg%20id='logo'%3e%3crect%20id='XMLID_5_'%20x='14'%20y='337'%20class='st1'%20width='640'%20height='110'/%3e%3cg%20id='XMLID_82_'%3e%3crect%20id='XMLID_80_'%20x='14'%20y='337'%20class='st2'%20width='150'%20height='110'/%3e%3cg%20id='XMLID_74_'%3e%3cpolygon%20id='XMLID_79_'%20class='st3'%20points='75.1,420.7%2083.2,426.1%2083.2,389.4%20103,402.2%20103,384%2075.1,365.9%20'/%3e%3cpolygon%20id='XMLID_78_'%20class='st3'%20points='41.9,424.2%2041.9,404.7%2060.9,392.4%2060.9,350.3%2027.3,372.1%2027.3,433.7%20'/%3e%3cpolygon%20id='XMLID_77_'%20class='st3'%20points='106.1,381.9%20106.1,417.1%20118.9,425.4%20118.9,354.7%2091.6,372.5%20'/%3e%3cpolygon%20id='XMLID_76_'%20class='st3'%20points='64,350.3%2064,409.8%2071.9,404.7%2071.9,363.9%2071.9,355.5%20'/%3e%3cpolygon%20id='XMLID_75_'%20class='st3'%20points='128.4,385.6%20122.1,389.7%20122.1,423.4%20128.4,419.3%20150.7,433.7%20150.7,399.9%20'/%3e%3c/g%3e%3c/g%3e%3cg%20id='XMLID_6_'%3e%3crect%20id='XMLID_81_'%20x='164.5'%20y='367.5'%20class='st1'%20width='255.5'%20height='79.5'/%3e%3cg%20id='XMLID_7_'%3e%3cg%20id='XMLID_44_'%3e%3cpath%20id='XMLID_71_'%20class='st3'%20d='M187.3,385.6h4.7c5.5,0,8.7,2.2,8.7,8.2s-4,8.2-8.7,8.2h-4.7V385.6z%20M191.9,399.4%20c4.2,0,5.5-1.6,5.5-5.4c0-3.7-1.3-5.6-5.5-5.6h-1.5v11H191.9z'/%3e%3cpath%20id='XMLID_69_'%20class='st3'%20d='M203.5,385.6h3.2v16.5h-3.2V385.6z'/%3e%3cpath%20id='XMLID_66_'%20class='st3'%20d='M213.7,396h-0.2v6.1h-3.2v-16.5h4.7c3.8,0,6.4,1.4,6.4,4.9c0,2.8-1.7,4.6-4.4,5.2l5.6,6.3%20h-3.8L213.7,396z%20M215,393.7c2,0,3.2-1,3.2-2.9c0-1.9-1.2-2.7-3.2-2.7h-1.5v5.5h1.5V393.7z'/%3e%3cpath%20id='XMLID_64_'%20class='st3'%20d='M224.6,385.6h10.5v2.7h-7.3v4h4.9v2.5h-4.9v4.5h7.3v2.7h-10.5V385.6z'/%3e%3cpath%20id='XMLID_62_'%20class='st3'%20d='M238,385.6h3.2v7.4l6.5-7.3h3.3l-5.9,6.6l6.3,9.9h-3.6l-4.7-7.7l-1.9,2.1v5.5H238V385.6z'/%3e%3cpath%20id='XMLID_60_'%20class='st3'%20d='M256.8,388.4H252v-2.7h12.6v2.7H260v13.7h-3.2V388.4z'/%3e%3cpath%20id='XMLID_57_'%20class='st3'%20d='M265.7,393.9c0-5.7,4-8.6,8.1-8.6c4.8,0,8.1,3,8.1,8.6c0,5.7-4,8.6-8.1,8.6%20C269,402.5,265.7,399.6,265.7,393.9z%20M278.7,394c0-3.9-1.9-6-4.8-6s-4.8,2.1-4.8,5.8c0,3.9,1.9,6.1,4.8,6.1%20C276.7,399.8,278.7,397.7,278.7,394z'/%3e%3cpath%20id='XMLID_54_'%20class='st3'%20d='M288,396h-0.2v6.1h-3.2v-16.5h4.7c3.8,0,6.4,1.4,6.4,4.9c0,2.8-1.7,4.6-4.4,5.2l5.6,6.3%20h-3.8L288,396z%20M289.3,393.7c2,0,3.2-1,3.2-2.9c0-1.9-1.2-2.7-3.2-2.7h-1.5v5.5h1.5V393.7z'/%3e%3cpath%20id='XMLID_51_'%20class='st3'%20d='M303.1,387.3l-0.6-1.7h3.3l6.5,16.5H309l-1.3-3.4h-6.1l-1.3,3.4h-3.1L303.1,387.3z%20M302.5,396.4h4.4l-1.7-4.5l-0.5-1.4l-0.5,1.4L302.5,396.4z'/%3e%3cpath%20id='XMLID_49_'%20class='st3'%20d='M316,388.4h-4.7v-2.7h12.6v2.7h-4.7v13.7H316V388.4z'/%3e%3cpath%20id='XMLID_47_'%20class='st3'%20d='M326.2,385.6h10.5v2.7h-7.3v4h4.9v2.5h-4.9v4.5h7.3v2.7h-10.5V385.6z'/%3e%3cpath%20id='XMLID_45_'%20class='st3'%20d='M343.1,388.4h-4.7v-2.7H351v2.7h-4.7v13.7h-3.2L343.1,388.4L343.1,388.4z'/%3e%3c/g%3e%3cg%20id='XMLID_8_'%3e%3cpath%20id='XMLID_42_'%20class='st3'%20d='M187.3,412.3h10.3v2.7h-7.1v4.1h4.7v2.4h-4.7v7.2h-3.2V412.3z'/%3e%3cpath%20id='XMLID_39_'%20class='st3'%20d='M198.8,420.5c0-5.7,4-8.6,8.1-8.6c4.8,0,8.1,3,8.1,8.6c0,5.7-4,8.6-8.1,8.6%20C202.1,429.1,198.8,426.2,198.8,420.5z%20M211.7,420.6c0-3.9-1.9-6-4.8-6c-2.9,0-4.8,2.1-4.8,5.8c0,3.9,1.9,6.1,4.8,6.1%20C209.8,426.4,211.7,424.3,211.7,420.6z'/%3e%3cpath%20id='XMLID_36_'%20class='st3'%20d='M221.1,422.6h-0.2v6.1h-3.2v-16.4h4.7c3.8,0,6.4,1.4,6.4,4.9c0,2.8-1.7,4.6-4.4,5.2l5.6,6.3%20h-3.8L221.1,422.6z%20M222.4,420.3c2,0,3.2-1,3.2-2.9s-1.2-2.7-3.2-2.7h-1.5v5.5L222.4,420.3L222.4,420.3z'/%3e%3cpath%20id='XMLID_32_'%20class='st3'%20d='M237.8,412.3h4.9c4.5,0,6.4,1.5,6.4,4.1c0,2.3-1.3,3.4-3.1,3.8l0,0c2,0.3,3.3,1.3,3.3,3.9%20s-1.8,4.7-6.5,4.7h-5L237.8,412.3L237.8,412.3z%20M242.8,419c2.4,0,3.1-0.8,3.1-2.2c0-1.4-0.9-2-3.1-2H241v4.2H242.8z%20M243,426.1%20c2.4,0,3.2-0.8,3.2-2.3c0-1.4-0.8-2.3-3.2-2.3h-2v4.5h2V426.1z'/%3e%3cpath%20id='XMLID_30_'%20class='st3'%20d='M255.5,422l-5.4-9.7h3.5l3.6,6.9l3.7-6.9h3.2l-5.4,9.7v6.8h-3.2L255.5,422L255.5,422z'/%3e%3cpath%20id='XMLID_28_'%20class='st3'%20d='M264.5,420.5c0-5.7,3.6-8.6,8-8.6c2.7,0,4.3,0.8,5.2,1.6v3.6c-0.9-1.4-2.4-2.4-4.8-2.4%20c-3.3,0-5.2,2-5.2,5.7s1.8,6.2,4.7,6.2c0.8,0,1.5-0.1,2.1-0.3v-5.1h3.2v6.6c-1.1,0.7-2.9,1.4-5.4,1.4%20C267.7,429.1,264.5,426.3,264.5,420.5z'/%3e%3cpath%20id='XMLID_26_'%20class='st3'%20d='M280,420.5c0-5.7,3.6-8.6,8-8.6c2.7,0,4.3,0.8,5.2,1.6v3.6c-0.9-1.4-2.4-2.4-4.8-2.4%20c-3.3,0-5.2,2-5.2,5.7s1.8,6.2,4.7,6.2c0.8,0,1.5-0.1,2.1-0.3v-5.1h3.2v6.6c-1.1,0.7-2.9,1.4-5.4,1.4%20C283.2,429.1,280,426.3,280,420.5z'/%3e%3cpath%20id='XMLID_24_'%20class='st3'%20d='M296.5,412.3h3.2v7.3l6.5-7.3h3.3l-5.9,6.6l6.3,9.9h-3.6l-4.7-7.7l-1.9,2.1v5.5h-3.2%20L296.5,412.3L296.5,412.3z'/%3e%3cpath%20id='XMLID_22_'%20class='st3'%20d='M310.1,412.3h3.3l3.9,11.5h0.1l4-11.5h3.1l-5.9,16.5H316L310.1,412.3z'/%3e%3cpath%20id='XMLID_19_'%20class='st3'%20d='M329.2,413.9l-0.6-1.7h3.3l6.5,16.5h-3.3l-1.3-3.4h-6.1l-1.3,3.4h-3.1L329.2,413.9z%20M328.6,423h4.4l-1.7-4.5l-0.5-1.4l-0.5,1.4L328.6,423z'/%3e%3cpath%20id='XMLID_17_'%20class='st3'%20d='M340.4,412.3h3.2V426h6.1v2.8h-9.3L340.4,412.3L340.4,412.3z'/%3e%3cpath%20id='XMLID_15_'%20class='st3'%20d='M352.1,412.3h3.2v16.5h-3.2V412.3z'/%3e%3cpath%20id='XMLID_13_'%20class='st3'%20d='M362.3,415h-4.7v-2.7h12.6v2.7h-4.7v13.7h-3.2L362.3,415L362.3,415z'/%3e%3cpath%20id='XMLID_11_'%20class='st3'%20d='M372.6,412.3h10.5v2.7h-7.3v3.9h4.9v2.5h-4.9v4.6h7.3v2.7h-10.5V412.3z'/%3e%3cpath%20id='XMLID_9_'%20class='st3'%20d='M389.4,415h-4.7v-2.7h12.6v2.7h-4.7v13.7h-3.2L389.4,415L389.4,415z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cg%20id='hamburgermeny'%20class='st0'%3e%3crect%20id='XMLID_94_'%20x='578'%20y='386'%20class='st4'%20width='60'%20height='6'/%3e%3crect%20id='XMLID_95_'%20x='578'%20y='423'%20class='st4'%20width='60'%20height='6'/%3e%3crect%20id='XMLID_96_'%20x='578'%20y='405'%20class='st4'%20width='60'%20height='6'/%3e%3c/g%3e%3cg%20id='hamburgermeny__hover'%20class='st0'%3e%3crect%20id='XMLID_97_'%20x='578'%20y='386'%20class='st5'%20width='60'%20height='6'/%3e%3crect%20id='XMLID_93_'%20x='578'%20y='423'%20class='st5'%20width='60'%20height='6'/%3e%3crect%20id='XMLID_91_'%20x='578'%20y='405'%20class='st5'%20width='60'%20height='6'/%3e%3c/g%3e%3c/svg%3e",eo=e=>(e==null?void 0:e.logo)??"",to=e=>(e==null?void 0:e.logoPadding)??"",no=e=>(e==null?void 0:e.appName)??"",ro="_navigationBarContainer_n1cc0_1",ao="_mainContentLink_n1cc0_1",so="_compact_n1cc0_30",oo="_navigationBar_n1cc0_1",io="_preventStacking_n1cc0_63",lo="_logoContainer_n1cc0_82",co="_childElements_n1cc0_91",uo="_menuToggle_n1cc0_97",ho="_hamburgerIcon_n1cc0_125",fo="_active_n1cc0_161",mo="_dropdownContainer_n1cc0_170",po="_dropdown_n1cc0_170",_o="_primaryList_n1cc0_195",go="_secondaryList_n1cc0_196",vo="_line_n1cc0_392",A={navigationBarContainer:ro,mainContentLink:ao,compact:so,navigationBar:oo,preventStacking:io,logoContainer:lo,childElements:co,menuToggle:uo,hamburgerIcon:ho,active:fo,dropdownContainer:mo,dropdown:po,primaryList:_o,secondaryList:go,line:vo},Ge=({listItem:e})=>typeof e=="string"?o.jsx("li",{children:o.jsx("span",{children:e})}):typeof e=="object"?o.jsx("li",{children:o.jsx("a",{href:e.href,children:e.name})}):null,yo=({primaryListItems:e=[],secondaryListItems:t=[],logoLink:n="",logoLinkTitle:a,openLogoLinkInNewTab:r,theme:s,compact:c,mainContentId:u,preventChildElementStacking:i=!1,children:l})=>{const[d,m]=b.useState(!1),h=()=>m(!d),y=L=>({padding:to(L)}),f=(L=e,S=0)=>L.length?o.jsx("ul",{className:A.primaryList,children:L.map((N,R)=>{const j=`${S}-${R}`;return N.listItems?o.jsxs("li",{children:[o.jsx("span",{children:N.name}),f(N.listItems,S+1)]},j):o.jsx(Ge,{listItem:N},j)})}):null,v=()=>t.length?o.jsx("ul",{className:A.secondaryList,children:t.map(L=>o.jsx(Ge,{listItem:L},L.name))}):null,x=(L,S)=>{const N=eo(s),R=no(s),j=L&&S?"":N&&R?`${R} logo`:"DIBK logo",M=N?o.jsx("img",{alt:j,src:N,style:y(s)}):o.jsx("img",{alt:j,src:c?Qs:Zs});return L!=null&&L.length?o.jsx("a",{href:L,title:S,target:r?"_blank":void 0,rel:r?"noopener noreferrer":void 0,children:M}):M},_=e.length>0||t.length>0,C=b.useId(),w=b.useId(),$=b.useId();return o.jsxs("div",{className:P([c&&A.compact,A.navigationBarContainer]),children:[u&&o.jsx("a",{id:C,href:`#${u}`,className:A.mainContentLink,children:o.jsx("span",{id:w,children:"Hopp til hovedinnhold"})}),o.jsxs("div",{className:P([A.navigationBar,i&&A.preventStacking]),children:[o.jsx("div",{className:A.logoContainer,children:x(n,a)}),l&&o.jsx("div",{className:A.childElements,children:l}),_&&o.jsxs("button",{type:"button",className:`${A.menuToggle} ${d?A.active:""}`,onClick:h,"aria-expanded":d?"true":"false","aria-controls":"main-menu-dropdown",children:[!c&&"Meny",o.jsxs("span",{className:A.hamburgerIcon,children:[o.jsx("span",{className:A.line}),o.jsx("span",{className:A.line}),o.jsx("span",{className:A.line})]})]})]}),_&&o.jsx("div",{className:P([A.dropdownContainer,d&&A.active]),children:o.jsxs("div",{id:$,className:A.dropdown,children:[f(),v()]})})]})},xo="_paper_1lgl3_1",bo="_noMargin_1lgl3_6",wo="_noPadding_1lgl3_9",Xe={paper:xo,noMargin:bo,noPadding:wo},Co=({noMargin:e=!1,noPadding:t=!1,children:n})=>{const a=[Xe.paper,e&&Xe.noMargin,t&&Xe.noPadding].filter(Boolean).join(" ");return o.jsx("div",{className:a,children:n})},Eo="_progressBar_t5aid_1",ko="_hasErrors_t5aid_23",wt={progressBar:Eo,hasErrors:ko},jo=({progress:e=0,hasErrors:t=!1})=>o.jsx("div",{className:`${wt.progressBar} ${t?wt.hasErrors:""}`,role:"progressbar","aria-valuenow":e,"aria-valuemin":0,"aria-valuemax":100,style:{"--value":e}}),Lo="_radioButtonIcon_32fe0_1",So="_hasErrors_32fe0_22",$o="_checked_32fe0_32",Io="_disabled_32fe0_48",Ne={radioButtonIcon:Lo,hasErrors:So,checked:$o,disabled:Io},Wt=({size:e="10px",checked:t=!1,disabled:n=!1,hasErrors:a=!1})=>{const r={height:e,width:e},s=[Ne.radioButtonIcon,t&&Ne.checked,n&&Ne.disabled,a&&Ne.hasErrors].filter(Boolean).join(" ");return o.jsx("span",{className:s,style:r})},No="_radioButtonInput_1i7cy_1",Ro="_requiredSymbol_1i7cy_6",Mo="_disabled_1i7cy_13",To="_labelText_1i7cy_19",Do="_hasErrors_1i7cy_27",_e={radioButtonInput:No,requiredSymbol:Ro,disabled:Mo,labelText:To,hasErrors:Do},Ut=({checked:e=!1,disabled:t=!1,required:n=!1,requiredGroup:a=!1,id:r,name:s="",onChange:c,contentOnly:u=!1,hasErrors:i=!1,inputValue:l,tabIndex:d,children:m,"aria-controls":h,"aria-describedby":y})=>{const f=[_e.radioButtonInput,e&&_e.checked,t&&_e.disabled,i&&_e.hasErrors].filter(Boolean).join(" "),v={checked:e,disabled:t,hasErrors:!u&&i},x={id:r,name:s,type:"radio",value:l,checked:e,disabled:t,required:n||a,onChange:c,tabIndex:d??void 0,"aria-controls":h,"aria-invalid":i?"true":void 0,"aria-describedby":y};return o.jsxs("label",{htmlFor:r,className:f,children:[!u&&o.jsxs(o.Fragment,{children:[o.jsx(Wt,{...v}),o.jsx("input",{...x})]}),o.jsxs("span",{className:_e.labelText,children:[m,n&&o.jsx("img",{src:te,alt:"",className:_e.requiredSymbol})]})]})},Po="_radioButtonList_1cyu3_1",Bo="_requiredSymbol_1cyu3_16",Ct={radioButtonList:Po,requiredSymbol:Bo},zo=({legend:e,legendSize:t,required:n=!1,compact:a=!1,children:r})=>{const s=c=>ye(c).map(i=>{var l;return b.isValidElement(i)&&((l=i.type)==null?void 0:l.displayName)==="RadioButtonListItem"?b.cloneElement(i,{requiredGroup:n,compact:a,key:`radioButtonListItem-${i.key}`}):i});return o.jsxs("fieldset",{className:Ct.radioButtonList,children:[!!(e!=null&&e.length)&&o.jsxs("legend",{children:[t?o.jsx(st,{size:t,children:e}):e,n&&o.jsx("img",{src:te,alt:"",className:Ct.requiredSymbol})]}),s(b.Children.toArray(r))]})},Ao="_radioButtonListItem_1ggab_1",Fo="_contentOnly_1ggab_26",Oo="_compact_1ggab_26",Vo="_disabled_1ggab_41",Ho="_checked_1ggab_44",ge={radioButtonListItem:Ao,contentOnly:Fo,compact:Oo,disabled:Vo,checked:Ho},qo=({inputValue:e,checked:t=!1,disabled:n=!1,required:a=!1,requiredGroup:r=!1,name:s="",id:c,onChange:u,contentOnly:i=!1,compact:l=!1,hasErrors:d=!1,"aria-controls":m,"aria-describedby":h,children:y})=>{const f=P([ge.radioButtonListItem,t&&ge.checked,n&&ge.disabled,l&&ge.compact,i&&ge.contentOnly,d&&ge.hasErrors]),v={onChange:u,inputValue:e,checked:t,disabled:n,required:a,requiredGroup:r,contentOnly:i,hasErrors:d,"aria-controls":m,"aria-describedby":h,id:c,name:s};return o.jsx("div",{className:f,children:o.jsx(Ut,{...v,children:y})})},Xo="_select_11vnt_1",Wo="_requiredSymbol_11vnt_1",Uo="_selectContainer_11vnt_8",Yo="_selectListArrow_11vnt_11",Jo="_multipleSelectDropdown_11vnt_40",Go="_multipleSelectElement_11vnt_50",Ko="_hasErrors_11vnt_98",oe={select:Xo,requiredSymbol:Wo,selectContainer:Uo,selectListArrow:Yo,multipleSelectDropdown:Jo,multipleSelectElement:Go,hasErrors:Ko},Zo=e=>{const{id:t,name:n="",required:a=!1,disabled:r=!1,options:s=[],width:c,label:u="",contentOnly:i=!1,keyAsContent:l=!1,placeholder:d="",placeholderValue:m="",defaultContent:h="",role:y,"aria-describedby":f,hasErrors:v=!1,errorMessage:x=""}=e,[_,C]=b.useState(!1),w=b.useRef(null),$=b.useCallback(k=>{k&&kt(k)},[]),L=()=>C(!1);b.useEffect(()=>{const k=z=>{z.key==="Escape"&&L()},D=z=>{w.current&&!w.current.contains(z.target)&&L()};return document.addEventListener("mousedown",D),document.addEventListener("keydown",k),()=>{document.removeEventListener("mousedown",D),document.removeEventListener("keydown",k)}},[]);const S=k=>typeof k=="object"?{key:k.key,value:k.value}:{key:k,value:k},N=k=>{const D=s.map(S).find(z=>z.value===k||z.key===k);return D?D.key??D.value:k},R=k=>Array.isArray(k)?k:k==null?[]:[k],j=()=>e.value!==void 0?R(e.value):e.defaultValue!==void 0?R(e.defaultValue):[],M=()=>{const k=j();return k.length===0?d||h||"":k.map(N).join(", ")},q=k=>{const D=j(),W=D.includes(k)?D.filter(ae=>ae!==k):[...D,k];e.multiple&&e.onChange(W)},X=()=>{const k=j();return s.map(D=>{const{key:z,value:W}=S(D),ae=k.includes(W),p=`${t}-${String(W)}`;return o.jsx(Ht,{id:p,value:W,checked:ae,onChange:()=>q(W),children:z},String(W))})},I=()=>`${t}-errorMessage`;if(i){const k=j(),D=k.length===0?h:l?k.map(N).join(", "):k.join(", ");return o.jsxs("div",{className:oe.select,children:[o.jsx(le,{htmlFor:t,children:u}),o.jsx("span",{children:D})]})}const B=k=>{const D=s.map(S).find(z=>String(z.value)===k);return D?D.value:k};return o.jsxs("div",{className:oe.select,children:[o.jsxs(le,{htmlFor:t,children:[u,a&&o.jsx("img",{src:te,alt:"",className:oe.requiredSymbol})]}),o.jsxs("div",{className:oe.selectContainer,style:c?{maxWidth:c}:void 0,children:[o.jsx("span",{className:oe.selectListArrow}),e.multiple?o.jsxs("div",{ref:w,children:[o.jsx("button",{type:"button",id:t,"aria-haspopup":"listbox","aria-expanded":_,onClick:()=>C(k=>!k),className:oe.multipleSelectElement,disabled:r,children:M()}),_&&o.jsx("div",{ref:$,className:oe.multipleSelectDropdown,role:"listbox","aria-multiselectable":"true","aria-labelledby":t,children:o.jsx(Vt,{compact:!0,children:X()})})]}):o.jsxs("select",{name:n,required:a,disabled:r,onChange:k=>e.onChange(B(k.target.value)),id:t,role:y,className:P([v&&oe.hasErrors]),"aria-describedby":v&&x?I():f,"aria-invalid":v||void 0,style:c?{maxWidth:c}:void 0,...e.value!==void 0?{value:e.value}:e.defaultValue!==void 0?{defaultValue:e.defaultValue}:{},children:[d&&o.jsx("option",{value:m,disabled:!0,children:d}),s.map(k=>{const{key:D,value:z}=S(k);return o.jsx("option",{value:String(z),children:D},String(z))})]})]}),o.jsx(ve,{id:I(),content:x})]})},Qo="_table_19a1d_1",ei="_thButton_19a1d_30",ti="_sortable_19a1d_41",ni="_label_19a1d_51",ri="_sortIndicators_19a1d_55",ai="_sortArrow_19a1d_62",si="_activeArrow_19a1d_65",oi="_evenRow_19a1d_69",ii="_oddRow_19a1d_72",Y={table:Qo,thButton:ei,sortable:ti,label:ni,sortIndicators:ri,sortArrow:ai,activeArrow:si,evenRow:oi,oddRow:ii},li=({columns:e,data:t,caption:n,getRowId:a})=>{const[r,s]=b.useState(null);b.useEffect(()=>{const d=e.find(m=>m.sortable);s(d?{headerKey:d.key,direction:"asc"}:null)},[e]);const c=b.useMemo(()=>{const d=new Map;for(const m of e)d.set(m.key,m);return d},[e]),u=b.useMemo(()=>{if(!r)return t;const d=c.get(r.headerKey);if(!d)return t;const m=d.sortAccessor??d.accessor;if(!m)return t;const h=[...t];return h.sort((y,f)=>{const v=m(y),x=m(f);if(v==null||x==null)return 0;if(typeof v=="number"&&typeof x=="number")return r.direction==="asc"?v-x:x-v;if(v instanceof Date&&x instanceof Date)return r.direction==="asc"?v.getTime()-x.getTime():x.getTime()-v.getTime();const _=String(v),C=String(x);return r.direction==="asc"?_.localeCompare(C,void 0,{numeric:!0}):C.localeCompare(_,void 0,{numeric:!0})}),h},[t,r,c]),i=d=>{s(m=>!m||m.headerKey!==d?{headerKey:d,direction:"asc"}:{headerKey:d,direction:m.direction==="asc"?"desc":"asc"})},l=(d,m)=>{if(m)return(r==null?void 0:r.headerKey)!==d?"none":r.direction==="asc"?"ascending":"descending"};return o.jsxs("table",{className:Y.table,children:[n&&o.jsx("caption",{children:n}),o.jsx("thead",{children:o.jsx("tr",{children:e.map(({key:d,label:m,sortable:h,ariaLabel:y})=>{const f=(r==null?void 0:r.headerKey)===d,v=f&&r.direction==="asc",x=f&&r.direction==="desc";return o.jsx("th",{"aria-sort":l(d,h),children:o.jsxs("button",{type:"button",className:`${Y.thButton} ${h?Y.sortable:""}`,onClick:h?()=>i(d):void 0,disabled:!h,"aria-label":h?`${y??m}: sort ${f&&v?"descending":"ascending"}`:void 0,children:[o.jsx("span",{className:Y.label,children:m}),h&&o.jsxs("span",{className:Y.sortIndicators,"aria-hidden":"true",children:[o.jsx("span",{className:`${Y.sortArrow} ${v?Y.activeArrow:""}`,children:"▲"}),o.jsx("span",{className:`${Y.sortArrow} ${x?Y.activeArrow:""}`,children:"▼"})]})]})},d)})})}),o.jsx("tbody",{children:u.map((d,m)=>o.jsx("tr",{className:m%2===0?Y.evenRow:Y.oddRow,children:e.map(h=>{var y;return o.jsx("td",{children:h.render?h.render(d):String(((y=h.accessor)==null?void 0:y.call(h,d))??"")},h.key)})},a==null?void 0:a(d,m)))})]})},ci=e=>{let t="";const n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",a=n.length;for(let r=0;r<e;r++)t+=n.charAt(Math.floor(Math.random()*a));return t},ui="_textarea_1596u_1",di="_requiredSymbol_1596u_4",hi="_hasErrors_1596u_55",We={textarea:ui,requiredSymbol:di,hasErrors:hi},fi=({id:e,onChange:t,onBlur:n,name:a="",required:r=!1,readOnly:s,disabled:c,width:u,resize:i="both",value:l,defaultValue:d,elementKey:m,rows:h,label:y="",contentOnly:f=!1,placeholder:v="",defaultContent:x="","aria-describedby":_,hasErrors:C=!1,errorMessage:w=""})=>{const $=()=>`${e}-errorMessage`,L=!(l!=null&&l.length)&&(d!=null&&d.length)?d:void 0,S=m||`${e}-${ci(6)}`,N={...u&&{maxWidth:u},...i&&{resize:i}},R={name:a,readOnly:s,disabled:c,required:r,id:e,onChange:t,onBlur:n,value:L?void 0:l,defaultValue:L||void 0,placeholder:v,rows:h?parseInt(h,10):void 0,className:C?We.hasErrors:"","aria-describedby":C&&w?$():_,"aria-invalid":C?"true":void 0,style:N};return o.jsxs("div",{className:We.textarea,children:[o.jsxs(le,{htmlFor:e,children:[y,r&&o.jsx("img",{src:te,alt:"",className:We.requiredSymbol})]}),f?o.jsx("span",{children:l||d||x}):o.jsx("textarea",{...R},S),o.jsx(ve,{id:$(),content:w})]})},mi=({theme:e,children:t})=>{const n=rn(e),a=sn(n);return an("theme-provider",`:root {${a}}`),t},pi="_toggleNavigationButton_1eb2w_1",_i={toggleNavigationButton:pi},gi=({id:e,htmlTag:t="button",showText:n,hideText:a,buttonProps:r={},isOpen:s=!1})=>b.createElement(t,{...r,className:_i.toggleNavigationButton,id:e||void 0},s?a:n),vi="_wizardTopnavItem_5ar16_1",yi="_wizardTopnavItemContent_5ar16_4",xi="_vertical_5ar16_7",bi="_stepNumber_5ar16_24",wi="_stepName_5ar16_36",Ci="_active_5ar16_46",Ei="_finished_5ar16_46",ki="_hasErrors_5ar16_46",ji="_horizontal_5ar16_64",G={wizardTopnavItem:vi,wizardTopnavItemContent:yi,vertical:xi,stepNumber:bi,stepName:wi,active:Ci,finished:Ei,hasErrors:ki,horizontal:ji},Li="data:image/svg+xml,%3csvg%20width='20'%20height='20'%20viewBox='0%200%2020%2020'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%20aria-label='Ferdig'%20style='fill:%20rgb(23,%20121,%2018);'%3e%3cmask%20id='mask0_1089_7430'%20maskUnits='userSpaceOnUse'%20x='0'%20y='0'%20width='20'%20height='20'%20style='mask-type:%20alpha;'%3e%3crect%20width='20'%20height='20'%3e%3c/rect%3e%3c/mask%3e%3cg%20mask='url(%23mask0_1089_7430)'%3e%3cpath%20d='M5.71427%208.57149L3.80951%2010.4762L8.57141%2015.2382L17.1428%206.66672L15.2381%204.76196L8.57141%2011.4286L5.71427%208.57149Z'%3e%3c/path%3e%3c/g%3e%3c/svg%3e",Yt=({step:e,index:t,activeStepId:n,direction:a="vertical"})=>{const r=n===e.id,s=a==="vertical",c=P([G.wizardTopnavItem,r&&G.active,e.finished&&G.finished,e.hasErrors&&G.hasErrors,G[a]]),u=r?"step":void 0,i=()=>o.jsxs(o.Fragment,{children:[o.jsx("span",{className:G.stepNumber,children:t+1}),o.jsx("span",{className:G.stepName,children:e.name}),s&&e.finished&&!r&&o.jsx("img",{src:Li,alt:"",className:G.checkmarkSymbol})]});return e.link&&Object.keys(e.link).length>0?o.jsx("li",{className:c,children:o.jsx(ke,{to:e.link,"aria-current":u,className:G.wizardTopnavItemContent,children:i()})}):o.jsx("li",{className:c,children:o.jsx("span",{"aria-current":u,className:G.wizardTopnavItemContent,children:i()})})},Si="_wizardTopnavContainer_qiy2o_1",$i="_wizardTopnav_qiy2o_1",Ii="_vertical_qiy2o_6",Ni="_horizontal_qiy2o_11",Ue={wizardTopnavContainer:Si,wizardTopnav:$i,vertical:Ii,horizontal:Ni},Ri=({steps:e,activeStepId:t,direction:n="vertical","aria-label":a})=>{const r=Object.keys(e),c=`I dette skjemaet er det totalt ${r.length} steg som du skal gå igjennom`,u=a!=null&&a.length?a:c;return o.jsx("nav",{"aria-label":u,className:P([Ue.wizardTopnavContainer,Ue[n]]),children:o.jsx("ol",{className:Ue.wizardTopnav,children:r.map((i,l)=>o.jsx(Yt,{step:e[i],activeStepId:t,direction:n,index:l},i))})})};exports.Accordion=Cn;exports.Button=at;exports.CheckBoxIcon=Je;exports.CheckBoxInput=Ot;exports.CheckBoxList=Vt;exports.CheckBoxListItem=Ht;exports.Container=qt;exports.ContentBox=Da;exports.DescriptionDetails=za;exports.DescriptionList=Oa;exports.DescriptionTerm=qa;exports.Dialog=as;exports.DragAndDropFileInput=ps;exports.ErrorBox=Cs;exports.ErrorMessage=ve;exports.Footer=js;exports.Header=st;exports.InfoBox=$s;exports.InputField=As;exports.Label=le;exports.Lead=Vs;exports.List=Xs;exports.ListItem=Ys;exports.LoadingAnimation=Ks;exports.NavigationBar=yo;exports.NavigationBarListItem=Ge;exports.Paper=Co;exports.ProgressBar=jo;exports.RadioButtonIcon=Wt;exports.RadioButtonInput=Ut;exports.RadioButtonList=zo;exports.RadioButtonListItem=qo;exports.Select=Zo;exports.Table=li;exports.Textarea=fi;exports.ThemeProvider=mi;exports.ToggleNavigationButton=gi;exports.WizardNavigation=Ri;exports.WizardNavigationStep=Yt;
|
|
22
|
+
<%s key={someKey} {...props} />`,h,S,O,S),Z[S+h]=!0)}if(S=null,w!==void 0&&(n(w),S=""+w),_(p)&&(n(p.key),S=""+p.key),"key"in p){w={};for(var le in p)le!=="key"&&(w[le]=p[le])}else w=p;return S&&l(w,typeof c=="function"?c.displayName||c.name||"Unknown":c),i(c,S,I,y,r(),w,J,Q)}function f(c){typeof c=="object"&&c!==null&&c.$$typeof===x&&c._store&&(c._store.validated=1)}var v=d,x=Symbol.for("react.transitional.element"),k=Symbol.for("react.portal"),b=Symbol.for("react.fragment"),N=Symbol.for("react.strict_mode"),z=Symbol.for("react.profiler"),j=Symbol.for("react.consumer"),$=Symbol.for("react.context"),V=Symbol.for("react.forward_ref"),D=Symbol.for("react.suspense"),M=Symbol.for("react.suspense_list"),R=Symbol.for("react.memo"),q=Symbol.for("react.lazy"),E=Symbol.for("react.activity"),B=Symbol.for("react.client.reference"),U=v.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,W=Object.prototype.hasOwnProperty,C=Array.isArray,A=console.createTask?console.createTask:function(){return null};v={"react-stack-bottom-frame":function(c){return c()}};var G,g={},L=v["react-stack-bottom-frame"].bind(v,o)(),H=A(a(o)),Z={};xe.Fragment=b,xe.jsx=function(c,p,w,h,y){var I=1e4>U.recentlyCreatedOwnerStacks++;return m(c,p,w,!1,h,y,I?Error("react-stack-top-frame"):L,I?A(a(c)):H)},xe.jsxs=function(c,p,w,h,y){var I=1e4>U.recentlyCreatedOwnerStacks++;return m(c,p,w,!0,h,y,I?Error("react-stack-top-frame"):L,I?A(a(c)):H)}}()),xe}var He;function bt(){return He||(He=1,process.env.NODE_ENV==="production"?je.exports=ft():je.exports=vt()),je.exports}var t=bt();const T=e=>(e==null?void 0:e.filter(Boolean).join(" "))||"",st=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),xt=e=>!(e!=null&&e.colors)||!Object.entries(e.colors).length?{}:Object.entries(e.colors).reduce((s,[n,a])=>(n&&a&&(s[`--color-${st(n)}`]=a),s),{}),yt=e=>!(e!=null&&e.sizes)||!Object.entries(e.sizes).length?{}:Object.entries(e.sizes).reduce((s,[n,a])=>(n&&a&&(s[`--size-${st(n)}`]=a),s),{}),jt=e=>({...xt(e),...yt(e)}),wt=(e,s)=>{if(typeof document>"u")return;const n=document.createElement("style");n.setAttribute("id",e),n.textContent=s;const a=document.getElementById(e);a&&a.remove(),document.head.appendChild(n)},kt=e=>Object.entries(e).map(([s,n])=>`${s}: ${n};`).join(""),ve=e=>{const s=[];return d.Children.forEach(e,n=>{if(d.isValidElement(n)){const a=n;if(a.type===d.Fragment){const r=ve(a.props.children);s.push(...r)}else s.push(d.cloneElement(a,{...a.props}))}else s.push(n)}),s},Ct=e=>{if(typeof document>"u")return;const s=document.createElement("button");s.style.position="absolute",s.style.opacity="0",e.prepend(s),s.focus(),s.remove()},Lt=e=>Array.from(e.querySelectorAll('button, [href], input, [tabindex="0"]')).filter(n=>!!n),nt=e=>{Ct(e);const s=Lt(e),n=s[0],a=s[s.length-1]||n;n&&(n.onkeydown=r=>{r.key==="Tab"&&r.shiftKey&&(r.preventDefault(),a.focus())}),a&&(a.onclick=()=>{n==null||n.focus()},a.onkeydown=r=>{r.key==="Tab"&&!r.shiftKey&&(r.preventDefault(),n==null||n.focus())})},It="_accordion_kwqaf_67",Et="_panel_kwqaf_76",Nt="_content_kwqaf_77",$t="_secondary_kwqaf_80",Mt="_info_kwqaf_88",St="_contrast_kwqaf_96",zt="_margin_kwqaf_104",Bt="_panelText_kwqaf_138",Tt="_panelChevron_kwqaf_144",Dt="_expanded_kwqaf_171",At="_initialized_kwqaf_187",Rt="_hide_kwqaf_1",Pt="_show_kwqaf_1",ne={accordion:It,default:"_default_kwqaf_73",panel:Et,content:Nt,secondary:$t,info:Mt,contrast:St,margin:zt,panelText:Bt,panelChevron:Tt,expanded:Dt,initialized:At,hide:Rt,show:Pt},Ft=({title:e,buttonProps:s,expanded:n,handleToggleExpand:a})=>t.jsxs("button",{...s,className:ne.panel,onClick:a,"aria-expanded":n?"true":"false",children:[t.jsx("span",{className:ne.panelText,children:e}),t.jsx("span",{className:`${ne.panelChevron} ${n?ne.expanded:""}`})]}),Vt=({title:e,color:s="default",expanded:n=!1,onToggleExpand:a,buttonProps:r,noMargin:o=!1,initialized:_,children:l,...u})=>{const[i,m]=d.useState(n),[f,v]=d.useState(_),x=()=>{m(!i),v(!0),a&&a()};d.useEffect(()=>{m(n)},[n]);const k=T([ne.accordion,s&&ne[s],!o&&ne.margin,u.className]);return t.jsxs("div",{className:k,...u,children:[t.jsx(Ft,{title:e??"",buttonProps:r??{},expanded:i??!1,handleToggleExpand:x}),t.jsx("div",{className:`${ne.content} ${f?ne.initialized:""} ${i?ne.expanded:""}`,children:l})]})},qt="_button_g3s9z_161",Ht="_noMargin_g3s9z_189",Ot="_regular_g3s9z_199",Xt="_small_g3s9z_202",Yt="_primary_g3s9z_213",Wt="_noHover_g3s9z_217",Zt="_secondary_g3s9z_233",Gt="_ghost_g3s9z_252",Ut="_disabled_g3s9z_271",Jt="_hasErrors_g3s9z_291",Kt="_rounded_g3s9z_297",Qt="_hasArrowLeft_g3s9z_301",es="_pushprev_g3s9z_1",ts="_hasArrowRight_g3s9z_339",ss="_pushnext_g3s9z_1",ns="_hasIcon_g3s9z_377",rs="_buttonContent_g3s9z_381",Y={button:qt,noMargin:Ht,regular:Ot,small:Xt,primary:Yt,noHover:Wt,secondary:Zt,ghost:Gt,disabled:Ut,hasErrors:Jt,rounded:Kt,hasArrowLeft:Qt,pushprev:es,hasArrowRight:ts,pushnext:ss,hasIcon:ns,buttonContent:rs},Ae=({content:e,color:s="primary",size:n="regular",arrow:a="none",disabled:r=!1,inputType:o,defaultChecked:_,hasErrors:l=!1,noHover:u=!1,rounded:i=!1,noMargin:m=!1,href:f,children:v,iconLeft:x,iconRight:k,...b})=>{const N=M=>{switch(M){case"left":return Y.hasArrowLeft;case"right":return Y.hasArrowRight;default:return""}},z=o==="radio"?_?"primary":"secondary":s,j=T([Y.button,Y[z],Y[n],N(a),u||o==="radio"?Y.noHover:null,i&&Y.rounded,l&&Y.hasErrors,r?Y.disabled:null,m?Y.noMargin:null,x||k?Y.hasIcon:null]),$={"aria-invalid":l||void 0,href:!r&&(f!=null&&f.length)?f:void 0,className:j,...b},V=M=>d.Children.toArray(ve(M)).map(q=>{if(!d.isValidElement(q))return null;const E=q,B=E.type===Be.Link&&typeof E.props=="object"&&E.props!==null&&"to"in E.props;return!r&&B?d.cloneElement(E,{className:j,key:`button-${E.key}`,to:E.props.to},x,t.jsx("span",{className:Y.buttonContent,children:E.props.children}),k):d.createElement("button",{...$,key:`button-${E.key}`},x,t.jsx("span",{className:Y.buttonContent,children:e||(E.props?E.props.children:null)}),k)});if(o==="button")return t.jsxs("button",{type:"button",...$,children:[x,t.jsx("span",{className:Y.buttonContent,children:e||v}),k]});if(o==="radio"){const M={...$};return delete M.href,t.jsxs("label",{className:j,children:[t.jsx("input",{...M,type:"radio"}),x,t.jsx("span",{className:Y.buttonContent,children:e}),k]})}if(f!=null&&f.length&&!r){const M={...$};return"type"in M&&delete M.type,t.jsxs("a",{...M,children:[x,t.jsx("span",{className:Y.buttonContent,children:e||v}),k]})}return d.isValidElement(v)&&v.type===Be.Link?t.jsx(d.Fragment,{children:V(d.Children.toArray(v))}):t.jsxs("button",{...$,children:[x,t.jsx("span",{className:Y.buttonContent,children:e||v}),k]})},as="_checkBoxIcon_1kc3w_1",os="_showBox_1kc3w_22",cs="_hasErrors_1kc3w_27",ls="_checked_1kc3w_37",is="_disabled_1kc3w_53",ds="_checkmark_1kc3w_58",ue={checkBoxIcon:as,showBox:os,hasErrors:cs,checked:ls,disabled:is,checkmark:ds},Te=({size:e="20px",checked:s=!1,disabled:n=!1,showBox:a=!0,hasErrors:r=!1,checkmarkCharacter:o="✔"})=>{const _={height:e,width:e,fontSize:e},l=[ue.checkBoxIcon,s&&ue.checked,n&&ue.disabled,a&&ue.showBox,r&&ue.hasErrors].filter(Boolean).join(" ");return t.jsx("span",{className:l,style:_,children:t.jsx("span",{"aria-hidden":!0,className:ue.checkmark,children:s?o:""})})},ce="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32.275'%20height='30.469'%20focusable='false'%3e%3cpath%20fill='%239d2024'%20d='m0%2014.355%202.246-6.933c5.176%201.823%208.936%203.402%2011.28%204.736-.62-5.892-.945-9.944-.977-12.158h7.08c-.098%203.223-.472%207.26-1.123%2012.11%203.353-1.693%207.194-3.256%2011.523-4.688l2.246%206.933c-4.134%201.368-8.186%202.28-12.158%202.735%201.986%201.725%204.785%204.801%208.399%209.228l-5.86%204.15c-1.888-2.57-4.118-6.07-6.69-10.497-2.408%204.59-4.524%208.089-6.347%2010.498l-5.762-4.15c3.776-4.656%206.478-7.732%208.106-9.23-4.2-.813-8.187-1.724-11.963-2.734'/%3e%3c/svg%3e",us="_checkBoxInput_f1w9m_1",_s="_requiredSymbol_f1w9m_6",hs="_contentOnly_f1w9m_13",ms="_disabled_f1w9m_13",ps="_labelText_f1w9m_19",gs="_hasErrors_f1w9m_27",_e={checkBoxInput:us,requiredSymbol:_s,contentOnly:hs,disabled:ms,labelText:ps,hasErrors:gs},Re=({checked:e=!1,disabled:s=!1,required:n=!1,requiredGroup:a=!1,id:r,name:o="",onChange:_,contentOnly:l=!1,hasErrors:u=!1,checkmarkCharacter:i="✔",tabIndex:m=0,children:f,"aria-controls":v,"aria-describedby":x,value:k})=>{const b=[_e.checkBoxInput,l&&_e.contentOnly,s&&_e.disabled,u&&_e.hasErrors].filter(Boolean).join(" "),N={checked:e,disabled:s,showBox:!l,hasErrors:l&&u,checkmarkCharacter:i},z={id:r,name:o,type:"checkbox",checked:e,disabled:s,required:n||a,onChange:_,tabIndex:m,"aria-controls":v,"aria-invalid":u?"true":void 0,"aria-describedby":x,value:k};return t.jsxs("label",{htmlFor:r,className:b,children:[l?t.jsx(Te,{...N}):t.jsxs(t.Fragment,{children:[t.jsx(Te,{...N}),t.jsx("input",{...z})]}),t.jsxs("span",{className:_e.labelText,children:[f,n&&t.jsx("img",{src:ce,alt:"",className:_e.requiredSymbol})]})]})},fs="_checkBoxList_1sp8d_1",vs="_requiredSymbol_1sp8d_16",Oe={checkBoxList:fs,requiredSymbol:vs},bs="_headerContainer_t5psg_1",xs="_header_t5psg_1",ys="_bigHeader_t5psg_16",we={headerContainer:bs,header:xs,"size-1":"_size-1_t5psg_8",bigHeader:ys,"size-2":"_size-2_t5psg_28","size-3":"_size-3_t5psg_36","size-4":"_size-4_t5psg_44","size-5":"_size-5_t5psg_52"},Pe=({id:e,content:s,size:n=1,big:a,label:r,htmlTag:o,htmlFor:_,children:l})=>{const u=o||`h${n}`,i=T([we.header,we[`size-${n}`],a&&we.bigHeader]),m=r!=null&&r.length&&typeof r=="string"?{"--label":`"${r}"`}:void 0,f=d.createElement(u,{className:i,id:e||void 0,htmlFor:_||void 0,style:m},s!=null&&s.length?s:l);return t.jsx("div",{className:we.headerContainer,children:f})},rt=({legend:e,legendSize:s,required:n=!1,compact:a=!1,children:r})=>{const o=_=>ve(_).map(u=>{var i;return d.isValidElement(u)&&((i=u.type)==null?void 0:i.displayName)==="RadioButtonListItem"?d.cloneElement(u,{requiredGroup:n,compact:a,key:`checkboxListItem-${u.key}`}):u});return t.jsxs("fieldset",{className:Oe.checkBoxList,children:[!!(e!=null&&e.length)&&t.jsxs("legend",{children:[s?t.jsx(Pe,{size:s,children:e}):e,n&&t.jsx("img",{src:ce,alt:"",className:Oe.requiredSymbol})]}),o(d.Children.toArray(r))]})},js="_checkBoxListItem_jnb8z_1",ws="_contentOnly_jnb8z_26",ks="_compact_jnb8z_26",Cs="_disabled_jnb8z_41",Ls="_checked_jnb8z_44",he={checkBoxListItem:js,contentOnly:ws,compact:ks,disabled:Cs,checked:Ls},at=({checked:e=!1,disabled:s=!1,required:n=!1,requiredGroup:a=!1,id:r,name:o="",onChange:_,contentOnly:l=!1,compact:u=!1,hasErrors:i=!1,checkmarkCharacter:m="✔","aria-controls":f,"aria-describedby":v,children:x,value:k})=>{const b=T([he.checkBoxListItem,e&&he.checked,s&&he.disabled,u&&he.compact,l&&he.contentOnly,i&&he.hasErrors]),N={onChange:_??(()=>{}),checked:e,disabled:s,required:n,requiredGroup:a,contentOnly:l,hasErrors:i,"aria-controls":f,"aria-describedby":v,id:r,name:o,checkmarkCharacter:m,value:k};return t.jsx("div",{className:b,children:t.jsx(Re,{...N,children:x})})},Is="_container_f8z49_1",Es={container:Is},ot=({maxWidth:e,children:s})=>{const n={"--max-width":e!=null&&e.length?e:void 0};return t.jsx("div",{className:Es.container,style:n,children:s})},Ns="_contentBox_1ndvc_1",$s="_link_1ndvc_8",Ms="_content_1ndvc_1",Ss="_title_1ndvc_25",zs="_secondary_1ndvc_28",Bs="_regular_1ndvc_36",Ts="_large_1ndvc_45",me={contentBox:Ns,link:$s,default:"_default_1ndvc_21",content:Ms,title:Ss,secondary:zs,regular:Bs,large:Ts},Ds=({title:e=null,titleSize:s="regular",content:n="",children:a,color:r="default",href:o=null})=>{const _=()=>{if(!e)return null;const v=`${me.title} ${me[s]}`;return t.jsx("h2",{className:v,children:e})},l=me[r]||"",u=o?me.link:"",i=`${me.contentBox} ${l} ${u}`.trim(),m=n!=null&&n.length?n:a,f=t.jsxs(t.Fragment,{children:[_(),t.jsx("div",{className:me.content,children:m})]});return o?t.jsx("a",{href:o,className:i,children:f}):t.jsx("div",{className:i,children:f})},As="_descriptionDetails_1d1dj_1",Rs="_compact_1d1dj_7",Xe={descriptionDetails:As,compact:Rs},Ps=({compact:e=!1,titleWidth:s,children:n})=>t.jsx("dd",{className:T([Xe.descriptionDetails,e&&Xe.compact]),style:{"--title-width":s||void 0},children:n}),Fs="_descriptionList_w11ua_1",Vs="_compact_w11ua_13",Ye={descriptionList:Fs,compact:Vs},qs=({compact:e=!1,titleWidth:s,children:n})=>{const a=r=>ve(r).map(_=>d.isValidElement(_)?d.cloneElement(_,{compact:e,titleWidth:s,key:`descriptionListItem-${_.key}`}):_);return d.createElement("dl",{className:T([Ye.descriptionList,e&&Ye.compact]),style:{"--title-width":s||void 0}},a(d.Children.toArray(n)))},Hs="_descriptionTerm_uuapd_1",Os="_compact_uuapd_8",We={descriptionTerm:Hs,compact:Os},Xs=({compact:e=!1,titleWidth:s,children:n})=>t.jsx("dt",{className:T([We.descriptionTerm,e&&We.compact]),style:{"--title-width":s||void 0},children:n}),Ys="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='25'%20height='25'%3e%3cpath%20fill='%23072938'%20stroke='%23072938'%20stroke-linecap='round'%20stroke-width='3.23'%20d='m3.97%203.57%2017.44%2018.2m-17.44.01L21.41%203.57'/%3e%3c/svg%3e",Ws="_dialog_pl6ui_19",Zs="_backdrop_pl6ui_34",Gs="_dialogContainer_pl6ui_42",Us="_modalInVertical_pl6ui_1",Js="_dialogContent_pl6ui_52",Ks="_noPadding_pl6ui_57",Qs="_closeButton_pl6ui_65",en="_isSidebar_pl6ui_94",tn="_left_pl6ui_117",sn="_modalInHorizontalLeft_pl6ui_1",nn="_right_pl6ui_123",rn="_modalInHorizontalRight_pl6ui_1",oe={dialog:Ws,backdrop:Zs,dialogContainer:Gs,modalInVertical:Us,dialogContent:Js,noPadding:Ks,closeButton:Qs,isSidebar:en,left:tn,modalInHorizontalLeft:sn,right:nn,modalInHorizontalRight:rn},an=({maxWidth:e="none",noPadding:s,closeButton:n,onClickOutside:a,modal:r=!0,attachTo:o,hidden:_=!1,children:l})=>{const[u,i]=d.useState(null),m=d.useRef(null),f=d.useCallback(b=>{b&&nt(b)},[]);d.useEffect(()=>{if(_)return;const b=N=>{N.key==="Escape"&&a&&a()};return document.addEventListener("keydown",b,!1),()=>{document.removeEventListener("keydown",b,!1)}},[_,a]),d.useEffect(()=>{if(typeof window>"u")return;const N=(()=>{const j="dibk-design-dialog-root";let $=document.getElementById(j);return $||($=document.createElement("div"),$.setAttribute("id",j),document.body.appendChild($)),$})(),z=document.createElement("div");return N.appendChild(z),i(z),()=>{i(null),N.contains(z)&&N.removeChild(z)}},[]),d.useEffect(()=>{if(_||!r)return;const b=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=b}},[_,r]);const v=o&&T([oe.isSidebar,oe[o]]),x={"--max-width":e};if(_||!u)return null;const k=r?{role:"dialog","aria-modal":"true"}:{role:"dialog"};return gt.createPortal(t.jsxs("div",{className:T([oe.dialog,v]),onClick:a,...k,children:[r&&t.jsx("div",{className:oe.backdrop,"aria-hidden":"true"}),t.jsx("div",{ref:m,className:oe.dialogContainer,style:x,onClick:b=>b.stopPropagation(),children:t.jsxs("div",{ref:f,className:T([oe.dialogContent,s&&oe.noPadding]),children:[n&&t.jsx("button",{type:"button","aria-label":"Lukk dialog",onClick:a,className:T([oe.closeButton,s&&oe.noPadding]),children:t.jsx("img",{src:Ys,alt:""})}),t.jsx("div",{"aria-live":"assertive",children:l})]})})]}),u)},on="_dragAndDropFileInput_pfifv_1",cn="_requiredSymbol_pfifv_1",ln="_dragAndDropContainer_pfifv_8",dn="_highlighted_pfifv_25",ke={dragAndDropFileInput:on,requiredSymbol:cn,dragAndDropContainer:ln,highlighted:dn},ct="data:image/svg+xml,%3csvg%20width='24'%20height='28'%20viewBox='0%200%2024%2028'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cellipse%20cx='12.0008'%20cy='20.0008'%20rx='1.2'%20ry='1.2'%20fill='black'/%3e%3cpath%20d='M12.0008%209.19922C12.6635%209.19922%2013.2007%2010.0348%2013.2008%2011.0656C13.2008%2011.2742%2013.1767%2011.4744%2013.1362%2011.6617L12.6008%2016.6656C12.6008%2017.181%2012.3322%2017.5992%2012.0008%2017.5992C11.6694%2017.5992%2011.4008%2017.181%2011.4008%2016.6656L10.8646%2011.6617C10.8241%2011.4745%2010.8008%2011.2741%2010.8008%2011.0656C10.8009%2010.0348%2011.3381%209.19922%2012.0008%209.19922Z'%20fill='black'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M10.833%205.08415C11.3507%204.16987%2012.6456%204.16987%2013.1633%205.08415L22.4834%2021.5413C23.0007%2022.4554%2022.3534%2023.5982%2021.3182%2023.5984H2.67934C1.64389%2023.5984%200.996537%2022.4556%201.51416%2021.5413L10.833%205.08415ZM12.2898%206.28415C12.1603%206.05562%2011.8373%206.0557%2011.7078%206.28415L2.96965%2021.7127C2.84068%2021.9412%203.0027%2022.2268%203.26127%2022.227H20.735C20.9938%2022.227%2021.1559%2021.9413%2021.0266%2021.7127L12.2898%206.28415Z'%20fill='black'/%3e%3c/svg%3e",un="_errorMessage_15d1p_1",_n="_errorSign_15d1p_10",Ze={errorMessage:un,errorSign:_n},fe=({id:e,content:s=""})=>{const n=()=>({id:e!=null&&e.length?e:void 0,className:Ze.errorMessage});return(typeof s=="string"?s.trim().length>0:!!s)?t.jsxs("span",{"aria-live":"polite",...n(),children:[t.jsx("img",{src:ct,alt:"",className:Ze.errorSign}),s]}):null},hn="_label_18de6_1",mn="_inline_18de6_11",pn="_normalCursor_18de6_14",Ne={label:hn,inline:mn,normalCursor:pn},de=({inline:e=!1,normalCursor:s=!1,htmlTag:n="label",children:a,id:r,...o})=>{const _=[Ne.label,e&&Ne.inline,s&&Ne.normalCursor].filter(Boolean).join(" "),l={...o,className:_,id:r||void 0};return d.createElement(n,l,a)},gn=({id:e,name:s,onSelectChange:n,onDragAndDropChange:a,label:r="",contentOnly:o=!1,buttonColor:_="primary",buttonContent:l,buttonContentWhenSelectedFile:u,selectedFileName:i,defaultContent:m="",hasErrors:f=!1,errorMessage:v="",required:x=!1,children:k,"data-transaction-name":b})=>{const[N,z]=d.useState(!1),j=d.useRef(null),$=d.useRef(null),V=C=>{C.preventDefault(),C.stopPropagation()},D=(C,A)=>C||A,M=()=>{var C;(C=$.current)==null||C.click()},R=()=>`${e}-errorMessage`,q={id:e,"aria-describedby":f&&(v!=null&&v.toString().length)?R():void 0,"aria-invalid":f?"true":void 0,name:s,required:x},E=i&&u||l,B=d.useCallback(()=>z(!0),[]),U=d.useCallback(()=>z(!1),[]),W=d.useCallback(C=>{var A;V(C),(A=C.dataTransfer)!=null&&A.files&&a(C.dataTransfer.files),z(!1)},[a]);return d.useEffect(()=>{const C=j.current;if(C)return["dragenter","dragover"].forEach(A=>{C.addEventListener(A,B)}),["dragleave","drop"].forEach(A=>{C.addEventListener(A,U)}),["dragenter","dragover","dragleave","drop"].forEach(A=>{C.addEventListener(A,V)}),C.addEventListener("drop",W),()=>{["dragenter","dragover","dragleave","drop"].forEach(A=>{C.removeEventListener(A,V),C.removeEventListener(A,B),C.removeEventListener(A,U)}),C.removeEventListener("drop",W)}},[a]),t.jsxs("div",{className:ke.dragAndDropFileInput,children:[t.jsxs(de,{htmlFor:e,children:[r,x&&t.jsx("img",{src:ce,alt:"",className:ke.requiredSymbol})]}),t.jsx("div",{children:k}),!o&&t.jsxs("div",{ref:j,className:`${ke.dragAndDropContainer} ${N?ke.highlighted:""}`,children:[i?t.jsx("div",{children:t.jsxs("span",{children:[t.jsx("b",{children:"Valgt fil:"})," ",i]})}):t.jsx("div",{children:"Slipp fil her"}),t.jsx("input",{...q,ref:$,type:"file",onChange:n}),l&&t.jsxs(t.Fragment,{children:[t.jsx("div",{children:i?"":"eller klikk på knappen for å velge fil"}),t.jsx(Ae,{size:"small",inputType:"button",color:_,onClick:M,content:E,hasErrors:f,"data-transaction-name":b})]})]}),o&&t.jsx("span",{children:D(i,m)}),t.jsx(fe,{id:R(),content:v})]})},fn="_box_10r67_7",vn="_messageIn_10r67_1",bn="_fullScreen_10r67_16",xn="_info_10r67_19",yn="_warning_10r67_23",jn="_error_10r67_27",wn="_tip_10r67_31",kn="_inner_10r67_36",Cn="_hasIcon_10r67_52",Ln="_icon_10r67_61",In="_iconImage_10r67_69",En="_content_10r67_75",Nn="_title_10r67_81",$n="_body_10r67_93",te={box:fn,messageIn:vn,fullScreen:bn,info:xn,warning:yn,error:jn,tip:wn,inner:kn,hasIcon:Cn,icon:Ln,iconImage:In,content:En,title:Nn,body:$n},Ge="data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M11.9984%202.39844C17.3004%202.39844%2021.5984%206.6965%2021.5984%2011.9984C21.5984%2017.3004%2017.3004%2021.5984%2011.9984%2021.5984C6.6965%2021.5984%202.39844%2017.3004%202.39844%2011.9984C2.39844%206.6965%206.6965%202.39844%2011.9984%202.39844ZM11.9984%203.59844C7.35925%203.59844%203.59844%207.35925%203.59844%2011.9984C3.59844%2016.6376%207.35925%2020.3984%2011.9984%2020.3984C16.6376%2020.3984%2020.3984%2016.6376%2020.3984%2011.9984C20.3984%207.35925%2016.6376%203.59844%2011.9984%203.59844Z'%20fill='black'/%3e%3cellipse%20cx='12.0203'%20cy='8.37578'%20rx='1.2'%20ry='1.2'%20fill='black'/%3e%3cpath%20d='M13.1563%2011.1562V17.5934H13.1586C13.3618%2017.5934%2013.5266%2017.7583%2013.5266%2017.9613C13.5264%2018.1642%2013.3617%2018.3281%2013.1586%2018.3281L13.1563%2018.327L11.0984%2018.3281V18.3258H10.7551C10.7469%2018.3263%2010.7388%2018.3281%2010.7305%2018.3281C10.5274%2018.3281%2010.3627%2018.1642%2010.3625%2017.9613C10.3625%2017.7591%2010.526%2017.5946%2010.7281%2017.5934H10.9133C10.9133%2017.5934%2010.9906%2017.5875%2011.0609%2017.4938C11.1313%2017.4%2011.0984%2017.2172%2011.0984%2017.2172V12.9C11.0984%2012.9%2011.1266%2012.6293%2011.0047%2012.4781C10.8828%2012.327%2010.7094%2012.327%2010.7094%2012.327H10.3203C9.9969%2012.327%209.73469%2012.0652%209.73438%2011.7422C9.73438%2011.4189%209.99671%2011.1562%2010.3203%2011.1562H13.1563Z'%20fill='black'/%3e%3c/svg%3e",Mn="data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M11.9984%202.39844C17.3004%202.39844%2021.5984%206.6965%2021.5984%2011.9984C21.5984%2017.3004%2017.3004%2021.5984%2011.9984%2021.5984C6.6965%2021.5984%202.39844%2017.3004%202.39844%2011.9984C2.39844%206.6965%206.6965%202.39844%2011.9984%202.39844ZM11.9984%203.59844C7.35925%203.59844%203.59844%207.35925%203.59844%2011.9984C3.59844%2016.6376%207.35925%2020.3984%2011.9984%2020.3984C16.6376%2020.3984%2020.3984%2016.6376%2020.3984%2011.9984C20.3984%207.35925%2016.6376%203.59844%2011.9984%203.59844Z'%20fill='black'/%3e%3ccircle%20cx='12.0008'%20cy='17.45'%20r='1.2'%20fill='black'/%3e%3cpath%20d='M12.0008%205.07422C12.9741%205.07422%2013.7631%206.05478%2013.7633%207.26445C13.7633%207.50925%2013.728%207.74425%2013.6684%207.96406L12.882%2013.8363C12.882%2014.4413%2012.4875%2014.932%2012.0008%2014.932C11.5141%2014.932%2011.1195%2014.4413%2011.1195%2013.8363L10.332%207.96406C10.2725%207.74433%2010.2383%207.50914%2010.2383%207.26445C10.2385%206.05478%2011.0275%205.07422%2012.0008%205.07422Z'%20fill='black'/%3e%3c/svg%3e",lt=({title:e,children:s="",variant:n="info",fullScreen:a=!1,hideIcon:r=!1,icon:o,className:_})=>{const l={info:Ge,warning:Mn,error:ct,tip:Ge},u=o??t.jsx("img",{src:l[n],alt:"",className:te.iconImage}),i=!r&&u;return t.jsx("div",{className:T([te.box,te[n],a&&te.fullScreen,i?te.hasIcon:null,_]),children:t.jsxs("div",{className:te.inner,children:[i?t.jsx("div",{className:te.icon,children:u}):null,t.jsxs("div",{className:te.content,children:[e?t.jsx("div",{className:te.title,children:e}):null,s?t.jsx("div",{className:te.body,children:s}):null]})]})})},Sn=({type:e="warning",children:s="",...n})=>t.jsx(lt,{variant:e,children:s,...n}),zn="_footer_19fad_1",Bn={footer:zn},Tn=({children:e})=>t.jsx("footer",{className:Bn.footer,children:t.jsx(ot,{children:e})}),Dn="_inputField_unu3b_1",An="_noMargin_unu3b_4",Rn="_requiredSymbol_unu3b_10",Pn="_file_unu3b_17",Fn="_input_unu3b_1",Vn="_hasErrors_unu3b_57",qn="_fileInputContainer_unu3b_74",Hn="_visuallyHidden_unu3b_87",K={inputField:Dn,noMargin:An,requiredSymbol:Rn,file:Pn,input:Fn,hasErrors:Vn,fileInputContainer:qn,visuallyHidden:Hn},On=e=>{const s=typeof e=="string"?new Date(e):e;if(Number.isNaN(s.getTime()))return String(e??"");const n=String(s.getDate()).padStart(2,"0"),a=String(s.getMonth()+1).padStart(2,"0"),r=s.getFullYear();return`${n}.${a}.${r}`},Ue=e=>{if(e==null||e==="")return;const s=e instanceof Date?e:new Date(e);if(Number.isNaN(s.getTime()))return;const n=s.getFullYear(),a=String(s.getMonth()+1).padStart(2,"0"),r=String(s.getDate()).padStart(2,"0");return`${n}-${a}-${r}`},Xn=e=>!e||["text","search","url","email","tel","password","number"].includes(e),Yn=({id:e,onChange:s=()=>{},onBlur:n,onFocus:a,name:r="",type:o="text",disabled:_=!1,required:l=!1,readOnly:u,width:i,value:m,defaultValue:f,elementKey:v,label:x="",contentOnly:k=!1,buttonColor:b="primary",buttonContent:N,selectedFileName:z,placeholder:j="",defaultContent:$="",min:V,max:D,role:M,"aria-describedby":R,"aria-autocomplete":q,hasErrors:E=!1,errorMessage:B="",noMargin:U=!1})=>{const W=d.useRef(null),C=()=>`${e}-errorMessage`,A=i?{maxWidth:i}:{},G=o==="date"&&!_&&!u,g=()=>{var w;if(!G||!W.current)return;document.activeElement!==W.current&&W.current.focus();const p=W.current;(w=p.showPicker)==null||w.call(p)},L=p=>{g(),a==null||a(p)},H=(()=>{if(o==="file")return{};if(o==="date"){const w=m!==void 0?Ue(m):void 0,h=m===void 0&&f!==void 0?Ue(f):void 0;return m!==void 0?{value:w??""}:f!==void 0?{defaultValue:h}:{}}const p=w=>w instanceof Date?String(w.getTime()):w;return m!==void 0?{value:p(m)}:f!==void 0?{defaultValue:p(f)}:{}})(),Z=T([E&&K.hasErrors,o==="file"&&K.visuallyHidden]),c={name:r,readOnly:u,disabled:_,required:l,type:o,role:M,id:e,min:V,max:D,onChange:s,onBlur:n,onFocus:L,placeholder:o==="file"?void 0:j,className:Z||void 0,"aria-describedby":E&&B?C():R,"aria-invalid":E||void 0,"aria-autocomplete":Xn(o)?q:void 0,style:A,...H};if(k){const p=m??f??"",w=o==="date"?p?On(p):$:String(p??"")||$;return t.jsxs("div",{className:T([K.inputField,K[o],U&&K.noMargin]),children:[t.jsxs(de,{htmlFor:e,children:[x,l&&t.jsx("img",{src:ce,alt:"",className:K.requiredSymbol})]}),t.jsx("span",{children:w}),E&&B?t.jsx(fe,{id:C(),content:B}):null]})}return t.jsxs("div",{className:T([K.inputField,K[o],U&&K.noMargin]),children:[t.jsxs(de,{htmlFor:e,children:[x,l&&t.jsx("img",{src:ce,alt:"",className:K.requiredSymbol}),o==="file"&&t.jsxs("div",{className:K.fileInputContainer,children:[t.jsx("span",{className:K.input,children:z}),N&&t.jsx(Ae,{color:b,inputType:"button",onClick:()=>{var p;return(p=W.current)==null?void 0:p.click()},content:N})]})]}),t.jsx("input",{...c,ref:W},v||e),E&&B?t.jsx(fe,{id:C(),content:B}):null]})},Wn="_lead_176gy_1",Zn={lead:Wn},Gn=({id:e,htmlTag:s="p",children:n})=>d.createElement(s,{className:Zn.lead,id:e||void 0},n),Un="_list_16gsl_1",Jn="_compact_16gsl_10",Je={list:Un,compact:Jn},Kn=({listStyle:e,compact:s=!1,ordered:n=!1,children:a})=>{const r=u=>ve(u).map(m=>d.isValidElement(m)?d.cloneElement(m,{compact:s,key:`listItem-${m.key}`}):m),o=n?"ol":"ul",_=n?"decimal":"disc";return d.createElement(o,{className:`${Je.list} ${s?Je.compact:""}`,style:{["--listStyle"]:e||_}},r(d.Children.toArray(a)))},Qn="_listItem_33xs0_1",er="_compact_33xs0_5",Ke={listItem:Qn,compact:er},tr=({compact:e=!1,children:s})=>{const n=T([Ke.listItem,e&&Ke.compact]);return t.jsx("li",{className:n,children:s})},sr="_loadingAnimation_hzd5u_1",nr="_fixed_hzd5u_17",$e={loadingAnimation:sr,fixed:nr},rr=({fixed:e=!1,message:s=""})=>{const n=e?`${$e.loadingAnimation} ${$e.fixed}`:$e.loadingAnimation;return t.jsx("div",{className:n,children:s})},ar="_LoadingAnimation2_onmfe_1",or="_dot_onmfe_10",Qe={LoadingAnimation2:ar,dot:or},cr=({ariaLabel:e="Laster inn"})=>{const s=[0,.15,.3];return t.jsx("div",{role:"img","aria-label":e,className:Qe.LoadingAnimation2,children:s.map(n=>t.jsx("span",{className:Qe.dot,style:{animationDelay:`${n}s`}},n))})},lr="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20version='1.1'%20id='Layer_1'%20x='0px'%20y='0px'%20viewBox='0%200%20340.2%20412.5'%20style='enable-background:new%200%200%20340.2%20412.5;'%20xml:space='preserve'%3e%3cstyle%20type='text/css'%3e%20.st0{fill:%23003045;}%20.st1{fill:%2389BAD6;}%20.st2{fill:%23FFFFFF;}%20%3c/style%3e%3cg%3e%3crect%20x='0'%20y='253.2'%20class='st0'%20width='340.2'%20height='105.8'/%3e%3crect%20x='0'%20class='st1'%20width='340.2'%20height='249.4'/%3e%3cg%3e%3cpolygon%20class='st2'%20points='138.5,189.9%20157,202%20157,118.8%20201.7,147.8%20201.7,106.6%20138.5,65.5%20'/%3e%3cpolygon%20class='st2'%20points='63.3,197.7%2063.3,153.5%20106.3,125.5%20106.3,30.2%2030.2,79.7%2030.2,219.2%20'/%3e%3cpolygon%20class='st2'%20points='208.9,101.9%20208.9,181.7%20238,200.5%20238,40.1%20175.9,80.4%20'/%3e%3cpolygon%20class='st2'%20points='113.4,30.2%20113.4,165.2%20131.4,153.5%20131.4,60.9%20131.4,41.9%20'/%3e%3cpolygon%20class='st2'%20points='259.5,110.2%20245.1,119.6%20245.1,195.9%20259.5,186.5%20309.9,219.2%20309.9,142.6%20'/%3e%3c/g%3e%3cpolygon%20class='st0'%20points='0,362.8%2075.6,412%2075.6,362.8%20'/%3e%3cg%3e%3cg%3e%3cpath%20class='st2'%20d='M30.2,277.5h6.2c7.3,0,11.6,2.9,11.6,11s-5.3,11-11.6,11h-6.2V277.5z%20M36.5,295.7c5.6,0,7.3-2.2,7.3-7.2%20c0-5-1.7-7.5-7.3-7.5h-2v14.6H36.5z'/%3e%3cpath%20class='st2'%20d='M51.9,277.5h4.3v21.9h-4.3V277.5z'/%3e%3cpath%20class='st2'%20d='M65.5,291.2h-0.2v8.2H61v-21.9h6.2c5.1,0,8.6,1.8,8.6,6.5c0,3.7-2.3,6.2-5.8,7l7.5,8.5h-5.1L65.5,291.2z%20M67.2,288.2c2.7,0,4.3-1.3,4.3-3.8c0-2.5-1.6-3.5-4.3-3.5h-1.9v7.4H67.2z'/%3e%3cpath%20class='st2'%20d='M80,277.5h14v3.6h-9.7v5.3h6.5v3.4h-6.5v6H94v3.6H80V277.5z'/%3e%3cpath%20class='st2'%20d='M97.8,277.5h4.3v9.8l8.7-9.8h4.4l-7.9,8.7l8.4,13.2h-4.8l-6.2-10.2l-2.6,2.8v7.4h-4.3V277.5z'/%3e%3cpath%20class='st2'%20d='M122.8,281.1h-6.3v-3.6h16.8v3.6H127v18.3h-4.3V281.1z'/%3e%3cpath%20class='st2'%20d='M134.7,288.4c0-7.6,5.4-11.5,10.8-11.5c6.4,0,10.8,3.9,10.8,11.5c0,7.6-5.4,11.5-10.8,11.5%20C139.1,299.9,134.7,296,134.7,288.4z%20M151.9,288.6c0-5.2-2.5-8-6.5-8c-3.9,0-6.5,2.8-6.5,7.7c0,5.2,2.5,8.1,6.5,8.1%20C149.4,296.3,151.9,293.5,151.9,288.6z'/%3e%3cpath%20class='st2'%20d='M164.4,291.2h-0.2v8.2h-4.3v-21.9h6.2c5.1,0,8.6,1.8,8.6,6.5c0,3.7-2.3,6.2-5.8,7l7.5,8.5h-5.1L164.4,291.2z%20M166.2,288.2c2.7,0,4.3-1.3,4.3-3.8c0-2.5-1.5-3.5-4.3-3.5h-1.9v7.4H166.2z'/%3e%3cpath%20class='st2'%20d='M184.5,279.7l-0.8-2.2h4.4l8.6,21.9h-4.5l-1.7-4.5h-8.1l-1.7,4.5h-4.1L184.5,279.7z%20M183.6,291.7h5.8l-2.3-6%20l-0.6-1.9l-0.6,1.9L183.6,291.7z'/%3e%3cpath%20class='st2'%20d='M201.7,281.1h-6.3v-3.6h16.8v3.6h-6.3v18.3h-4.3V281.1z'/%3e%3cpath%20class='st2'%20d='M215.3,277.5h14v3.6h-9.7v5.3h6.5v3.4h-6.5v6h9.7v3.6h-14V277.5z'/%3e%3cpath%20class='st2'%20d='M237.7,281.1h-6.3v-3.6h16.8v3.6H242v18.3h-4.3V281.1z'/%3e%3c/g%3e%3cg%3e%3cpath%20class='st2'%20d='M30.2,312.9H44v3.6h-9.5v5.5h6.2v3.3h-6.2v9.6h-4.3V312.9z'/%3e%3cpath%20class='st2'%20d='M45.6,323.9c0-7.6,5.4-11.5,10.8-11.5c6.4,0,10.8,3.9,10.8,11.5c0,7.6-5.4,11.5-10.8,11.5%20C50,335.3,45.6,331.4,45.6,323.9z%20M62.8,324c0-5.2-2.5-8-6.5-8c-3.9,0-6.5,2.8-6.5,7.7c0,5.2,2.5,8.1,6.5,8.1%20C60.3,331.7,62.8,328.9,62.8,324z'/%3e%3cpath%20class='st2'%20d='M75.3,326.7h-0.2v8.2h-4.3v-21.9H77c5.1,0,8.6,1.8,8.6,6.5c0,3.7-2.3,6.2-5.8,7l7.5,8.5h-5.1L75.3,326.7z%20M77,323.7c2.7,0,4.3-1.3,4.3-3.8c0-2.5-1.5-3.5-4.3-3.5h-1.9v7.4H77z'/%3e%3cpath%20class='st2'%20d='M97.6,312.9h6.5c6,0,8.5,2,8.5,5.5c0,3-1.7,4.5-4.1,5.1v0.1c2.6,0.5,4.5,1.7,4.5,5.1c0,3.5-2.5,6.2-8.6,6.2%20h-6.7V312.9z%20M104.3,321.9c3.2,0,4.1-1.1,4.1-2.9c0-1.8-1.2-2.6-4.1-2.6h-2.4v5.5H104.3z%20M104.4,331.3c3.2,0,4.3-1.1,4.3-3%20c0-1.9-1.1-3-4.3-3h-2.6v6H104.4z'/%3e%3cpath%20class='st2'%20d='M121.2,325.8l-7.2-12.9h4.7l4.8,9.2l4.9-9.2h4.2l-7.2,12.9v9h-4.3V325.8z'/%3e%3cpath%20class='st2'%20d='M133,323.9c0-7.6,4.8-11.5,10.7-11.5c3.6,0,5.7,1.1,6.9,2.1v4.8c-1.2-1.9-3.2-3.3-6.4-3.3%20c-4.4,0-6.9,2.7-6.9,7.7c0,5,2.4,8.3,6.3,8.3c1,0,2-0.1,2.7-0.4v-6.8h4.3v8.8c-1.5,1-3.9,1.8-7.2,1.8%20C137.3,335.3,133,331.5,133,323.9z'/%3e%3cpath%20class='st2'%20d='M153.8,323.9c0-7.6,4.8-11.5,10.7-11.5c3.6,0,5.7,1.1,6.9,2.1v4.8c-1.2-1.9-3.2-3.3-6.4-3.3%20c-4.4,0-6.9,2.7-6.9,7.7c0,5,2.4,8.3,6.3,8.3c1,0,2-0.1,2.7-0.4v-6.8h4.3v8.8c-1.5,1-3.9,1.8-7.2,1.8%20C158,335.3,153.8,331.5,153.8,323.9z'/%3e%3cpath%20class='st2'%20d='M175.7,312.9h4.3v9.8l8.7-9.8h4.4l-7.9,8.7l8.4,13.2h-4.8l-6.2-10.2l-2.6,2.8v7.4h-4.3V312.9z'/%3e%3cpath%20class='st2'%20d='M193.8,312.9h4.4l5.2,15.4h0.1l5.3-15.4h4.1l-7.9,21.9h-3.5L193.8,312.9z'/%3e%3cpath%20class='st2'%20d='M219.3,315.1l-0.8-2.2h4.4l8.6,21.9h-4.5l-1.7-4.5h-8.1l-1.7,4.5h-4.1L219.3,315.1z%20M218.4,327.1h5.8l-2.3-6%20l-0.6-1.9l-0.6,1.9L218.4,327.1z'/%3e%3cpath%20class='st2'%20d='M234.1,312.9h4.3v18.3h8.2v3.7h-12.4V312.9z'/%3e%3cpath%20class='st2'%20d='M249.7,312.9h4.3v21.9h-4.3V312.9z'/%3e%3cpath%20class='st2'%20d='M263.4,316.5h-6.3v-3.6h16.8v3.6h-6.3v18.3h-4.3V316.5z'/%3e%3cpath%20class='st2'%20d='M277,312.9h14v3.6h-9.7v5.3h6.5v3.4h-6.5v6h9.7v3.6h-14V312.9z'/%3e%3cpath%20class='st2'%20d='M299.4,316.5h-6.3v-3.6h16.8v3.6h-6.3v18.3h-4.3V316.5z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",ir="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2019.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='14%20337%20406%20110'%20style='enable-background:new%2014%20337%20406%20110;'%20xml:space='preserve'%3e%3cstyle%20type='text/css'%3e%20.st0{display:none;}%20.st1{fill:%23003045;}%20.st2{fill:%2389BAD6;}%20.st3{fill:%23FFFFFF;}%20.st4{display:inline;fill:%23FFFFFF;}%20.st5{display:inline;fill:%23D7D4D1;}%20%3c/style%3e%3cg%20id='skisse__x28_forstørret_x29_'%20class='st0'%3e%3c/g%3e%3cg%20id='logo'%3e%3crect%20id='XMLID_5_'%20x='14'%20y='337'%20class='st1'%20width='640'%20height='110'/%3e%3cg%20id='XMLID_82_'%3e%3crect%20id='XMLID_80_'%20x='14'%20y='337'%20class='st2'%20width='150'%20height='110'/%3e%3cg%20id='XMLID_74_'%3e%3cpolygon%20id='XMLID_79_'%20class='st3'%20points='75.1,420.7%2083.2,426.1%2083.2,389.4%20103,402.2%20103,384%2075.1,365.9%20'/%3e%3cpolygon%20id='XMLID_78_'%20class='st3'%20points='41.9,424.2%2041.9,404.7%2060.9,392.4%2060.9,350.3%2027.3,372.1%2027.3,433.7%20'/%3e%3cpolygon%20id='XMLID_77_'%20class='st3'%20points='106.1,381.9%20106.1,417.1%20118.9,425.4%20118.9,354.7%2091.6,372.5%20'/%3e%3cpolygon%20id='XMLID_76_'%20class='st3'%20points='64,350.3%2064,409.8%2071.9,404.7%2071.9,363.9%2071.9,355.5%20'/%3e%3cpolygon%20id='XMLID_75_'%20class='st3'%20points='128.4,385.6%20122.1,389.7%20122.1,423.4%20128.4,419.3%20150.7,433.7%20150.7,399.9%20'/%3e%3c/g%3e%3c/g%3e%3cg%20id='XMLID_6_'%3e%3crect%20id='XMLID_81_'%20x='164.5'%20y='367.5'%20class='st1'%20width='255.5'%20height='79.5'/%3e%3cg%20id='XMLID_7_'%3e%3cg%20id='XMLID_44_'%3e%3cpath%20id='XMLID_71_'%20class='st3'%20d='M187.3,385.6h4.7c5.5,0,8.7,2.2,8.7,8.2s-4,8.2-8.7,8.2h-4.7V385.6z%20M191.9,399.4%20c4.2,0,5.5-1.6,5.5-5.4c0-3.7-1.3-5.6-5.5-5.6h-1.5v11H191.9z'/%3e%3cpath%20id='XMLID_69_'%20class='st3'%20d='M203.5,385.6h3.2v16.5h-3.2V385.6z'/%3e%3cpath%20id='XMLID_66_'%20class='st3'%20d='M213.7,396h-0.2v6.1h-3.2v-16.5h4.7c3.8,0,6.4,1.4,6.4,4.9c0,2.8-1.7,4.6-4.4,5.2l5.6,6.3%20h-3.8L213.7,396z%20M215,393.7c2,0,3.2-1,3.2-2.9c0-1.9-1.2-2.7-3.2-2.7h-1.5v5.5h1.5V393.7z'/%3e%3cpath%20id='XMLID_64_'%20class='st3'%20d='M224.6,385.6h10.5v2.7h-7.3v4h4.9v2.5h-4.9v4.5h7.3v2.7h-10.5V385.6z'/%3e%3cpath%20id='XMLID_62_'%20class='st3'%20d='M238,385.6h3.2v7.4l6.5-7.3h3.3l-5.9,6.6l6.3,9.9h-3.6l-4.7-7.7l-1.9,2.1v5.5H238V385.6z'/%3e%3cpath%20id='XMLID_60_'%20class='st3'%20d='M256.8,388.4H252v-2.7h12.6v2.7H260v13.7h-3.2V388.4z'/%3e%3cpath%20id='XMLID_57_'%20class='st3'%20d='M265.7,393.9c0-5.7,4-8.6,8.1-8.6c4.8,0,8.1,3,8.1,8.6c0,5.7-4,8.6-8.1,8.6%20C269,402.5,265.7,399.6,265.7,393.9z%20M278.7,394c0-3.9-1.9-6-4.8-6s-4.8,2.1-4.8,5.8c0,3.9,1.9,6.1,4.8,6.1%20C276.7,399.8,278.7,397.7,278.7,394z'/%3e%3cpath%20id='XMLID_54_'%20class='st3'%20d='M288,396h-0.2v6.1h-3.2v-16.5h4.7c3.8,0,6.4,1.4,6.4,4.9c0,2.8-1.7,4.6-4.4,5.2l5.6,6.3%20h-3.8L288,396z%20M289.3,393.7c2,0,3.2-1,3.2-2.9c0-1.9-1.2-2.7-3.2-2.7h-1.5v5.5h1.5V393.7z'/%3e%3cpath%20id='XMLID_51_'%20class='st3'%20d='M303.1,387.3l-0.6-1.7h3.3l6.5,16.5H309l-1.3-3.4h-6.1l-1.3,3.4h-3.1L303.1,387.3z%20M302.5,396.4h4.4l-1.7-4.5l-0.5-1.4l-0.5,1.4L302.5,396.4z'/%3e%3cpath%20id='XMLID_49_'%20class='st3'%20d='M316,388.4h-4.7v-2.7h12.6v2.7h-4.7v13.7H316V388.4z'/%3e%3cpath%20id='XMLID_47_'%20class='st3'%20d='M326.2,385.6h10.5v2.7h-7.3v4h4.9v2.5h-4.9v4.5h7.3v2.7h-10.5V385.6z'/%3e%3cpath%20id='XMLID_45_'%20class='st3'%20d='M343.1,388.4h-4.7v-2.7H351v2.7h-4.7v13.7h-3.2L343.1,388.4L343.1,388.4z'/%3e%3c/g%3e%3cg%20id='XMLID_8_'%3e%3cpath%20id='XMLID_42_'%20class='st3'%20d='M187.3,412.3h10.3v2.7h-7.1v4.1h4.7v2.4h-4.7v7.2h-3.2V412.3z'/%3e%3cpath%20id='XMLID_39_'%20class='st3'%20d='M198.8,420.5c0-5.7,4-8.6,8.1-8.6c4.8,0,8.1,3,8.1,8.6c0,5.7-4,8.6-8.1,8.6%20C202.1,429.1,198.8,426.2,198.8,420.5z%20M211.7,420.6c0-3.9-1.9-6-4.8-6c-2.9,0-4.8,2.1-4.8,5.8c0,3.9,1.9,6.1,4.8,6.1%20C209.8,426.4,211.7,424.3,211.7,420.6z'/%3e%3cpath%20id='XMLID_36_'%20class='st3'%20d='M221.1,422.6h-0.2v6.1h-3.2v-16.4h4.7c3.8,0,6.4,1.4,6.4,4.9c0,2.8-1.7,4.6-4.4,5.2l5.6,6.3%20h-3.8L221.1,422.6z%20M222.4,420.3c2,0,3.2-1,3.2-2.9s-1.2-2.7-3.2-2.7h-1.5v5.5L222.4,420.3L222.4,420.3z'/%3e%3cpath%20id='XMLID_32_'%20class='st3'%20d='M237.8,412.3h4.9c4.5,0,6.4,1.5,6.4,4.1c0,2.3-1.3,3.4-3.1,3.8l0,0c2,0.3,3.3,1.3,3.3,3.9%20s-1.8,4.7-6.5,4.7h-5L237.8,412.3L237.8,412.3z%20M242.8,419c2.4,0,3.1-0.8,3.1-2.2c0-1.4-0.9-2-3.1-2H241v4.2H242.8z%20M243,426.1%20c2.4,0,3.2-0.8,3.2-2.3c0-1.4-0.8-2.3-3.2-2.3h-2v4.5h2V426.1z'/%3e%3cpath%20id='XMLID_30_'%20class='st3'%20d='M255.5,422l-5.4-9.7h3.5l3.6,6.9l3.7-6.9h3.2l-5.4,9.7v6.8h-3.2L255.5,422L255.5,422z'/%3e%3cpath%20id='XMLID_28_'%20class='st3'%20d='M264.5,420.5c0-5.7,3.6-8.6,8-8.6c2.7,0,4.3,0.8,5.2,1.6v3.6c-0.9-1.4-2.4-2.4-4.8-2.4%20c-3.3,0-5.2,2-5.2,5.7s1.8,6.2,4.7,6.2c0.8,0,1.5-0.1,2.1-0.3v-5.1h3.2v6.6c-1.1,0.7-2.9,1.4-5.4,1.4%20C267.7,429.1,264.5,426.3,264.5,420.5z'/%3e%3cpath%20id='XMLID_26_'%20class='st3'%20d='M280,420.5c0-5.7,3.6-8.6,8-8.6c2.7,0,4.3,0.8,5.2,1.6v3.6c-0.9-1.4-2.4-2.4-4.8-2.4%20c-3.3,0-5.2,2-5.2,5.7s1.8,6.2,4.7,6.2c0.8,0,1.5-0.1,2.1-0.3v-5.1h3.2v6.6c-1.1,0.7-2.9,1.4-5.4,1.4%20C283.2,429.1,280,426.3,280,420.5z'/%3e%3cpath%20id='XMLID_24_'%20class='st3'%20d='M296.5,412.3h3.2v7.3l6.5-7.3h3.3l-5.9,6.6l6.3,9.9h-3.6l-4.7-7.7l-1.9,2.1v5.5h-3.2%20L296.5,412.3L296.5,412.3z'/%3e%3cpath%20id='XMLID_22_'%20class='st3'%20d='M310.1,412.3h3.3l3.9,11.5h0.1l4-11.5h3.1l-5.9,16.5H316L310.1,412.3z'/%3e%3cpath%20id='XMLID_19_'%20class='st3'%20d='M329.2,413.9l-0.6-1.7h3.3l6.5,16.5h-3.3l-1.3-3.4h-6.1l-1.3,3.4h-3.1L329.2,413.9z%20M328.6,423h4.4l-1.7-4.5l-0.5-1.4l-0.5,1.4L328.6,423z'/%3e%3cpath%20id='XMLID_17_'%20class='st3'%20d='M340.4,412.3h3.2V426h6.1v2.8h-9.3L340.4,412.3L340.4,412.3z'/%3e%3cpath%20id='XMLID_15_'%20class='st3'%20d='M352.1,412.3h3.2v16.5h-3.2V412.3z'/%3e%3cpath%20id='XMLID_13_'%20class='st3'%20d='M362.3,415h-4.7v-2.7h12.6v2.7h-4.7v13.7h-3.2L362.3,415L362.3,415z'/%3e%3cpath%20id='XMLID_11_'%20class='st3'%20d='M372.6,412.3h10.5v2.7h-7.3v3.9h4.9v2.5h-4.9v4.6h7.3v2.7h-10.5V412.3z'/%3e%3cpath%20id='XMLID_9_'%20class='st3'%20d='M389.4,415h-4.7v-2.7h12.6v2.7h-4.7v13.7h-3.2L389.4,415L389.4,415z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cg%20id='hamburgermeny'%20class='st0'%3e%3crect%20id='XMLID_94_'%20x='578'%20y='386'%20class='st4'%20width='60'%20height='6'/%3e%3crect%20id='XMLID_95_'%20x='578'%20y='423'%20class='st4'%20width='60'%20height='6'/%3e%3crect%20id='XMLID_96_'%20x='578'%20y='405'%20class='st4'%20width='60'%20height='6'/%3e%3c/g%3e%3cg%20id='hamburgermeny__hover'%20class='st0'%3e%3crect%20id='XMLID_97_'%20x='578'%20y='386'%20class='st5'%20width='60'%20height='6'/%3e%3crect%20id='XMLID_93_'%20x='578'%20y='423'%20class='st5'%20width='60'%20height='6'/%3e%3crect%20id='XMLID_91_'%20x='578'%20y='405'%20class='st5'%20width='60'%20height='6'/%3e%3c/g%3e%3c/svg%3e",dr=e=>(e==null?void 0:e.logo)??"",ur=e=>(e==null?void 0:e.logoPadding)??"",_r=e=>(e==null?void 0:e.appName)??"",hr="_navigationBarContainer_n1cc0_1",mr="_mainContentLink_n1cc0_1",pr="_compact_n1cc0_30",gr="_navigationBar_n1cc0_1",fr="_preventStacking_n1cc0_63",vr="_logoContainer_n1cc0_82",br="_childElements_n1cc0_91",xr="_menuToggle_n1cc0_97",yr="_hamburgerIcon_n1cc0_125",jr="_active_n1cc0_161",wr="_dropdownContainer_n1cc0_170",kr="_dropdown_n1cc0_170",Cr="_primaryList_n1cc0_195",Lr="_secondaryList_n1cc0_196",Ir="_line_n1cc0_392",X={navigationBarContainer:hr,mainContentLink:mr,compact:pr,navigationBar:gr,preventStacking:fr,logoContainer:vr,childElements:br,menuToggle:xr,hamburgerIcon:yr,active:jr,dropdownContainer:wr,dropdown:kr,primaryList:Cr,secondaryList:Lr,line:Ir},De=({listItem:e})=>typeof e=="string"?t.jsx("li",{children:t.jsx("span",{children:e})}):typeof e=="object"?t.jsx("li",{children:t.jsx("a",{href:e.href,children:e.name})}):null,Er=({primaryListItems:e=[],secondaryListItems:s=[],logoLink:n="",logoLinkTitle:a,openLogoLinkInNewTab:r,theme:o,compact:_,mainContentId:l,preventChildElementStacking:u=!1,children:i})=>{const[m,f]=d.useState(!1),v=()=>f(!m),x=D=>({padding:ur(D)}),k=(D=e,M=0)=>D.length?t.jsx("ul",{className:X.primaryList,children:D.map((R,q)=>{const E=`${M}-${q}`;return R.listItems?t.jsxs("li",{children:[t.jsx("span",{children:R.name}),k(R.listItems,M+1)]},E):t.jsx(De,{listItem:R},E)})}):null,b=()=>s.length?t.jsx("ul",{className:X.secondaryList,children:s.map(D=>t.jsx(De,{listItem:D},D.name))}):null,N=(D,M)=>{const R=dr(o),q=_r(o),E=D&&M?"":R&&q?`${q} logo`:"DIBK logo",B=R?t.jsx("img",{alt:E,src:R,style:x(o)}):t.jsx("img",{alt:E,src:_?ir:lr});return D!=null&&D.length?t.jsx("a",{href:D,title:M,target:r?"_blank":void 0,rel:r?"noopener noreferrer":void 0,children:B}):B},z=e.length>0||s.length>0,j=d.useId(),$=d.useId(),V=d.useId();return t.jsxs("div",{className:T([_&&X.compact,X.navigationBarContainer]),children:[l&&t.jsx("a",{id:j,href:`#${l}`,className:X.mainContentLink,children:t.jsx("span",{id:$,children:"Hopp til hovedinnhold"})}),t.jsxs("div",{className:T([X.navigationBar,u&&X.preventStacking]),children:[t.jsx("div",{className:X.logoContainer,children:N(n,a)}),i&&t.jsx("div",{className:X.childElements,children:i}),z&&t.jsxs("button",{type:"button",className:`${X.menuToggle} ${m?X.active:""}`,onClick:v,"aria-expanded":m?"true":"false","aria-controls":"main-menu-dropdown",children:[!_&&"Meny",t.jsxs("span",{className:X.hamburgerIcon,children:[t.jsx("span",{className:X.line}),t.jsx("span",{className:X.line}),t.jsx("span",{className:X.line})]})]})]}),z&&t.jsx("div",{className:T([X.dropdownContainer,m&&X.active]),children:t.jsxs("div",{id:V,className:X.dropdown,children:[k(),b()]})})]})},Nr="_paper_1lgl3_1",$r="_noMargin_1lgl3_6",Mr="_noPadding_1lgl3_9",Me={paper:Nr,noMargin:$r,noPadding:Mr},Sr=({noMargin:e=!1,noPadding:s=!1,children:n})=>{const a=[Me.paper,e&&Me.noMargin,s&&Me.noPadding].filter(Boolean).join(" ");return t.jsx("div",{className:a,children:n})},zr="_progressBar_t5aid_1",Br="_hasErrors_t5aid_23",et={progressBar:zr,hasErrors:Br},Tr=({progress:e=0,hasErrors:s=!1})=>t.jsx("div",{className:`${et.progressBar} ${s?et.hasErrors:""}`,role:"progressbar","aria-valuenow":e,"aria-valuemin":0,"aria-valuemax":100,style:{"--value":e}}),Dr="_radioButtonIcon_32fe0_1",Ar="_hasErrors_32fe0_22",Rr="_checked_32fe0_32",Pr="_disabled_32fe0_48",Ce={radioButtonIcon:Dr,hasErrors:Ar,checked:Rr,disabled:Pr},it=({size:e="10px",checked:s=!1,disabled:n=!1,hasErrors:a=!1})=>{const r={height:e,width:e},o=[Ce.radioButtonIcon,s&&Ce.checked,n&&Ce.disabled,a&&Ce.hasErrors].filter(Boolean).join(" ");return t.jsx("span",{className:o,style:r})},Fr="_radioButtonInput_1i7cy_1",Vr="_requiredSymbol_1i7cy_6",qr="_disabled_1i7cy_13",Hr="_labelText_1i7cy_19",Or="_hasErrors_1i7cy_27",pe={radioButtonInput:Fr,requiredSymbol:Vr,disabled:qr,labelText:Hr,hasErrors:Or},Fe=({checked:e=!1,disabled:s=!1,required:n=!1,requiredGroup:a=!1,id:r,name:o="",onChange:_,contentOnly:l=!1,hasErrors:u=!1,inputValue:i,tabIndex:m,children:f,"aria-controls":v,"aria-describedby":x})=>{const k=[pe.radioButtonInput,e&&pe.checked,s&&pe.disabled,u&&pe.hasErrors].filter(Boolean).join(" "),b={checked:e,disabled:s,hasErrors:!l&&u},N={id:r,name:o,type:"radio",value:i,checked:e,disabled:s,required:n||a,onChange:_,tabIndex:m??void 0,"aria-controls":v,"aria-invalid":u?"true":void 0,"aria-describedby":x};return t.jsxs("label",{htmlFor:r,className:k,children:[!l&&t.jsxs(t.Fragment,{children:[t.jsx(it,{...b}),t.jsx("input",{...N})]}),t.jsxs("span",{className:pe.labelText,children:[f,n&&t.jsx("img",{src:ce,alt:"",className:pe.requiredSymbol})]})]})},Xr="_radioButtonList_1cyu3_1",Yr="_requiredSymbol_1cyu3_16",tt={radioButtonList:Xr,requiredSymbol:Yr},Wr=({legend:e,legendSize:s,required:n=!1,compact:a=!1,children:r})=>{const o=_=>ve(_).map(u=>{var i;return d.isValidElement(u)&&((i=u.type)==null?void 0:i.displayName)==="RadioButtonListItem"?d.cloneElement(u,{requiredGroup:n,compact:a,key:`radioButtonListItem-${u.key}`}):u});return t.jsxs("fieldset",{className:tt.radioButtonList,children:[!!(e!=null&&e.length)&&t.jsxs("legend",{children:[s?t.jsx(Pe,{size:s,children:e}):e,n&&t.jsx("img",{src:ce,alt:"",className:tt.requiredSymbol})]}),o(d.Children.toArray(r))]})},Zr="_radioButtonListItem_1ggab_1",Gr="_contentOnly_1ggab_26",Ur="_compact_1ggab_26",Jr="_disabled_1ggab_41",Kr="_checked_1ggab_44",ge={radioButtonListItem:Zr,contentOnly:Gr,compact:Ur,disabled:Jr,checked:Kr},Qr=({inputValue:e,checked:s=!1,disabled:n=!1,required:a=!1,requiredGroup:r=!1,name:o="",id:_,onChange:l,contentOnly:u=!1,compact:i=!1,hasErrors:m=!1,"aria-controls":f,"aria-describedby":v,children:x})=>{const k=T([ge.radioButtonListItem,s&&ge.checked,n&&ge.disabled,i&&ge.compact,u&&ge.contentOnly,m&&ge.hasErrors]),b={onChange:l,inputValue:e,checked:s,disabled:n,required:a,requiredGroup:r,contentOnly:u,hasErrors:m,"aria-controls":f,"aria-describedby":v,id:_,name:o};return t.jsx("div",{className:k,children:t.jsx(Fe,{...b,children:x})})},ea="_select_vw2qd_1",ta="_requiredSymbol_vw2qd_1",sa="_selectContainer_vw2qd_8",na="_small_vw2qd_11",ra="_selectListArrow_vw2qd_11",aa="_multipleSelectDropdown_vw2qd_50",oa="_multipleSelectElement_vw2qd_60",ca="_hasErrors_vw2qd_115",ee={select:ea,requiredSymbol:ta,selectContainer:sa,small:na,selectListArrow:ra,multipleSelectDropdown:aa,multipleSelectElement:oa,hasErrors:ca},dt=e=>{const{id:s,name:n="",required:a=!1,disabled:r=!1,options:o=[],width:_,label:l="",contentOnly:u=!1,keyAsContent:i=!1,placeholder:m="",placeholderValue:f="",defaultContent:v="",role:x,"aria-describedby":k,hasErrors:b=!1,errorMessage:N="",size:z="medium"}=e,[j,$]=d.useState(!1),V=d.useRef(null),D=d.useCallback(g=>{g&&nt(g)},[]),M=()=>$(!1);d.useEffect(()=>{const g=H=>{H.key==="Escape"&&M()},L=H=>{V.current&&!V.current.contains(H.target)&&M()};return document.addEventListener("mousedown",L),document.addEventListener("keydown",g),()=>{document.removeEventListener("mousedown",L),document.removeEventListener("keydown",g)}},[]);const R=g=>typeof g=="object"?{key:g.key,value:g.value}:{key:g,value:g},q=g=>{const L=o.map(R).find(H=>H.value===g||H.key===g);return L?L.key??L.value:g},E=g=>Array.isArray(g)?g:g==null?[]:[g],B=()=>e.value!==void 0?E(e.value):e.defaultValue!==void 0?E(e.defaultValue):[],U=()=>{const g=B();return g.length===0?m||v||"":g.map(q).join(", ")},W=g=>{const L=B(),Z=L.includes(g)?L.filter(c=>c!==g):[...L,g];e.multiple&&e.onChange(Z)},C=()=>{const g=B();return o.map(L=>{const{key:H,value:Z}=R(L),c=g.includes(Z),p=`${s}-${String(Z)}`;return t.jsx(at,{id:p,value:Z,checked:c,onChange:()=>W(Z),children:H},String(Z))})},A=()=>`${s}-errorMessage`;if(u){const g=B(),L=g.length===0?v:i?g.map(q).join(", "):g.join(", ");return t.jsxs("div",{className:ee.select,children:[t.jsx(de,{htmlFor:s,children:l}),t.jsx("span",{children:L})]})}const G=g=>{const L=o.map(R).find(H=>String(H.value)===g);return L?L.value:g};return t.jsxs("div",{className:ee.select,children:[t.jsxs(de,{htmlFor:s,children:[l,a&&t.jsx("img",{src:ce,alt:"",className:ee.requiredSymbol})]}),t.jsxs("div",{className:T([ee.selectContainer,z==="small"&&ee.small]),style:_?{maxWidth:_}:void 0,children:[t.jsx("span",{className:ee.selectListArrow}),e.multiple?t.jsxs("div",{ref:V,children:[t.jsx("button",{type:"button",id:s,"aria-haspopup":"listbox","aria-expanded":j,onClick:()=>$(g=>!g),className:T([ee.multipleSelectElement,z==="small"&&ee.small]),disabled:r,children:U()}),j&&t.jsx("div",{ref:D,className:ee.multipleSelectDropdown,role:"listbox","aria-multiselectable":"true","aria-labelledby":s,children:t.jsx(rt,{compact:!0,children:C()})})]}):t.jsxs("select",{name:n,required:a,disabled:r,onChange:g=>e.onChange(G(g.target.value)),id:s,role:x,className:T([b&&ee.hasErrors,z==="small"&&ee.small]),"aria-describedby":b&&N?A():k,"aria-invalid":b||void 0,style:_?{maxWidth:_}:void 0,...e.value!==void 0?{value:e.value}:e.defaultValue!==void 0?{defaultValue:e.defaultValue}:{},children:[m&&t.jsx("option",{value:f,disabled:!0,children:m}),o.map(g=>{const{key:L,value:H}=R(g);return t.jsx("option",{value:String(H),children:L},String(H))})]})]}),t.jsx(fe,{id:A(),content:N})]})},la="_wizardTopnavItem_5ar16_1",ia="_wizardTopnavItemContent_5ar16_4",da="_vertical_5ar16_7",ua="_stepNumber_5ar16_24",_a="_stepName_5ar16_36",ha="_active_5ar16_46",ma="_finished_5ar16_46",pa="_hasErrors_5ar16_46",ga="_horizontal_5ar16_64",se={wizardTopnavItem:la,wizardTopnavItemContent:ia,vertical:da,stepNumber:ua,stepName:_a,active:ha,finished:ma,hasErrors:pa,horizontal:ga},fa="data:image/svg+xml,%3csvg%20width='20'%20height='20'%20viewBox='0%200%2020%2020'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%20aria-label='Ferdig'%20style='fill:%20rgb(23,%20121,%2018);'%3e%3cmask%20id='mask0_1089_7430'%20maskUnits='userSpaceOnUse'%20x='0'%20y='0'%20width='20'%20height='20'%20style='mask-type:%20alpha;'%3e%3crect%20width='20'%20height='20'%3e%3c/rect%3e%3c/mask%3e%3cg%20mask='url(%23mask0_1089_7430)'%3e%3cpath%20d='M5.71427%208.57149L3.80951%2010.4762L8.57141%2015.2382L17.1428%206.66672L15.2381%204.76196L8.57141%2011.4286L5.71427%208.57149Z'%3e%3c/path%3e%3c/g%3e%3c/svg%3e",ut=({step:e,index:s,activeStepId:n,direction:a="vertical"})=>{const r=n===e.id,o=a==="vertical",_=T([se.wizardTopnavItem,r&&se.active,e.finished&&se.finished,e.hasErrors&&se.hasErrors,se[a]]),l=r?"step":void 0,u=()=>t.jsxs(t.Fragment,{children:[t.jsx("span",{className:se.stepNumber,children:s+1}),t.jsx("span",{className:se.stepName,children:e.name}),o&&e.finished&&!r&&t.jsx("img",{src:fa,alt:"",className:se.checkmarkSymbol})]});return e.link&&Object.keys(e.link).length>0?t.jsx("li",{className:_,children:t.jsx(Be.Link,{to:e.link,"aria-current":l,className:se.wizardTopnavItemContent,children:u()})}):t.jsx("li",{className:_,children:t.jsx("span",{"aria-current":l,className:se.wizardTopnavItemContent,children:u()})})},va="_table_173le_1",ba="_thButton_173le_30",xa="_sortable_173le_41",ya="_label_173le_51",ja="_sortIndicators_173le_55",wa="_sortArrow_173le_62",ka="_activeArrow_173le_65",Ca="_evenRow_173le_69",La="_oddRow_173le_72",Ia="_selectionHeader_173le_83",Ea="_selectionCell_173le_89",Na="_selectionControl_173le_95",$a="_rowClickable_173le_102",Ma="_srOnly_173le_109",Sa="_pagination_173le_120",za="_paginationControls_173le_127",Ba="_pageSizeSelector_173le_135",Ta="_pageButton_173le_139",Da="_pageInfo_173le_157",P={table:va,thButton:ba,sortable:xa,label:ya,sortIndicators:ja,sortArrow:wa,activeArrow:ka,evenRow:Ca,oddRow:La,selectionHeader:Ia,selectionCell:Ea,selectionControl:Na,rowClickable:$a,srOnly:Ma,pagination:Sa,paginationControls:za,pageSizeSelector:Ba,pageButton:Ta,pageInfo:Da},Aa=({columns:e,data:s,caption:n,getRowId:a,selectionType:r,selectionLabel:o="Velg rad",selectedRowId:_,onSelect:l,selectedRowIds:u,onSelectMany:i,onRowClick:m,pageSize:f,page:v,defaultPage:x=1,onPageChange:k,pageSizeOptions:b,defaultPageSize:N,onPageSizeChange:z})=>{const[j,$]=d.useState(null),V=d.useId(),[D,M]=d.useState(x),[R,q]=d.useState(()=>{if(f===void 0){if(N&&N>0)return N;if(b!=null&&b.length)return b[0]}});d.useEffect(()=>{const h=e.find(y=>y.sortable);$(h?{headerKey:h.key,direction:"asc"}:null)},[e]);const E=d.useMemo(()=>{const h=new Map;for(const y of e)h.set(y.key,y);return h},[e]),B=d.useMemo(()=>{if(!j)return s;const h=E.get(j.headerKey);if(!h)return s;const y=h.sortAccessor??h.accessor;if(!y)return s;const I=[...s];return I.sort((J,Q)=>{const S=y(J),O=y(Q);if(S==null||O==null)return 0;if(typeof S=="number"&&typeof O=="number")return j.direction==="asc"?S-O:O-S;if(S instanceof Date&&O instanceof Date)return j.direction==="asc"?S.getTime()-O.getTime():O.getTime()-S.getTime();const le=String(S),ie=String(O);return j.direction==="asc"?le.localeCompare(ie,void 0,{numeric:!0}):ie.localeCompare(le,void 0,{numeric:!0})}),I},[s,j,E]),U=h=>{$(y=>!y||y.headerKey!==h?{headerKey:h,direction:"asc"}:{headerKey:h,direction:y.direction==="asc"?"desc":"asc"})},W=(h,y)=>{if(y)return(j==null?void 0:j.headerKey)!==h?"none":j.direction==="asc"?"ascending":"descending"},C=(h,y)=>{const I=a==null?void 0:a(h,y);if(I==null||I===""){const J=s.indexOf(h);return J===-1?y:J}return I},A=d.useMemo(()=>r!=="multiple"?new Set:new Set(u??[]),[u,r]),G=d.useMemo(()=>{const h=f??R;return!h||h<=0?B.length||s.length||1:h},[f,R,B.length,s.length]),g=d.useMemo(()=>Math.max(1,Math.ceil(B.length/G)),[B.length,G]),L=d.useMemo(()=>{const h=v??D;return!Number.isFinite(h)||h<1?1:h>g?g:h},[v,D,g]);d.useEffect(()=>{v===void 0&&L>g&&M(g)},[L,g,v]);const H=d.useMemo(()=>{if(G>=B.length)return B;const h=(L-1)*G;return B.slice(h,h+G)},[B,L,G]),Z=h=>{const y=Math.min(Math.max(h,1),g);v!==void 0?k==null||k(y):M(y)},c=h=>{const y=h>0?Math.floor(h):1;f!==void 0?z==null||z(y):(q(y),M(1))},p=g>1,w=!!(b!=null&&b.length);return t.jsxs(t.Fragment,{children:[t.jsxs("table",{className:P.table,children:[n&&t.jsx("caption",{children:n}),t.jsx("thead",{children:t.jsxs("tr",{children:[r&&t.jsx("th",{className:P.selectionHeader,"aria-label":o,children:t.jsx("span",{className:P.srOnly,children:o})}),e.map(({key:h,label:y,sortable:I,ariaLabel:J})=>{const Q=(j==null?void 0:j.headerKey)===h,S=Q&&j.direction==="asc",O=Q&&j.direction==="desc";return t.jsx("th",{"aria-sort":W(h,I),scope:"col",children:I?t.jsxs("button",{type:"button",className:`${P.thButton} ${P.sortable}`,onClick:()=>U(h),"aria-label":`${J??y}: sort ${Q&&S?"descending":"ascending"}`,children:[t.jsx("span",{className:P.label,children:y}),t.jsxs("span",{className:P.sortIndicators,"aria-hidden":"true",children:[t.jsx("span",{className:`${P.sortArrow} ${S?P.activeArrow:""}`,children:"▲"}),t.jsx("span",{className:`${P.sortArrow} ${O?P.activeArrow:""}`,children:"▼"})]})]}):t.jsx("span",{className:P.thButton,children:t.jsx("span",{className:P.label,children:y})})},h)})]})}),t.jsx("tbody",{children:H.map((h,y)=>{const I=C(h,y),J=`${V}-${I}`,Q=r==="single"&&_===I,S=r==="multiple"&&A.has(I),ie=!!m||r==="single"&&!!l||r==="multiple"&&!!i,mt=()=>{if(r==="single")l==null||l(h);else if(r==="multiple"&&i){const F=new Set(A);F.has(I)?F.delete(I):F.add(I);const ae=s.filter((Le,Ie)=>{const Ee=C(Le,Ie);return F.has(Ee)});i(ae)}m==null||m(h)};return t.jsxs("tr",{className:T([y%2===0?P.evenRow:P.oddRow,ie&&P.rowClickable]),onClick:ie?mt:void 0,children:[r==="single"&&t.jsx("td",{className:P.selectionCell,children:t.jsx("button",{type:"button",className:P.selectionControl,onClick:F=>F.stopPropagation(),children:t.jsx(Fe,{id:J,name:V,inputValue:String(I),checked:Q,onChange:F=>{F==null||F.stopPropagation(),l==null||l(h)},"aria-label":o})})}),r==="multiple"&&t.jsx("td",{className:P.selectionCell,children:t.jsx("button",{type:"button",className:P.selectionControl,onClick:F=>F.stopPropagation(),children:t.jsx(Re,{id:J,value:String(I),checked:S,onChange:F=>{if(F==null||F.stopPropagation(),!i)return;const ae=new Set(A);ae.has(I)?ae.delete(I):ae.add(I);const Le=s.filter((Ie,Ee)=>{const pt=C(Ie,Ee);return ae.has(pt)});i(Le)},"aria-label":o})})}),e.map(F=>{var ae;return t.jsx("td",{children:F.render?F.render(h):String(((ae=F.accessor)==null?void 0:ae.call(F,h))??"")},F.key)})]},I)})})]}),(p||w)&&t.jsxs("div",{className:P.paginationControls,children:[w&&t.jsx("div",{className:P.pageSizeSelector,children:t.jsx(dt,{id:`${V}-page-size`,label:"Rader per side",options:b,value:G,onChange:h=>c(Number(h)),width:"120px",size:"small"})}),p&&t.jsxs("div",{className:P.pagination,children:[t.jsx("button",{type:"button",className:P.pageButton,onClick:()=>Z(L-1),disabled:L<=1,"aria-label":"Forrige side",children:"Forrige"}),t.jsxs("span",{className:P.pageInfo,children:["Side ",L," av ",g]}),t.jsx("button",{type:"button",className:P.pageButton,onClick:()=>Z(L+1),disabled:L>=g,"aria-label":"Neste side",children:"Neste"})]})]})]})},Ra="_tabs_r5vii_1",Pa="_tabList_r5vii_5",Fa="_tab_r5vii_1",Va="_active_r5vii_41",qa="_disabled_r5vii_47",Ha="_tabLabel_r5vii_55",Oa="_tabAmount_r5vii_59",Xa="_tabPanels_r5vii_66",Ya="_tabPanel_r5vii_66",Wa="_hidden_r5vii_74",re={tabs:Ra,tabList:Pa,tab:Fa,active:Va,disabled:qa,tabLabel:Ha,tabAmount:Oa,tabPanels:Xa,tabPanel:Ya,hidden:Wa},ye=({children:e,defaultIndex:s=0,onChange:n,className:a})=>{const[r,o]=d.useState(s),_=d.useId(),l=d.useMemo(()=>_.replace(/:/g,""),[_]),u=i=>{o(i),n==null||n(i)};return t.jsx("div",{className:T([re.tabs,a]),children:d.Children.map(e,i=>d.isValidElement(i)?i.type===_t?d.cloneElement(i,{activeIndex:r,setActiveIndex:u,baseId:l}):i.type===ht?d.cloneElement(i,{activeIndex:r,baseId:l}):i:null)})},_t=({children:e,activeIndex:s=0,setActiveIndex:n,baseId:a})=>{const r=d.useMemo(()=>d.Children.toArray(e).filter(l=>d.isValidElement(l)),[e]),o=r.length,_=(l,u)=>{if(!n||o===0)return;let i=u;switch(l.key){case"ArrowRight":l.preventDefault(),i=(u+1)%o;break;case"ArrowLeft":l.preventDefault(),i=(u-1+o)%o;break;case"Home":l.preventDefault(),i=0;break;case"End":l.preventDefault(),i=o-1;break;default:return}n(i)};return t.jsx("div",{className:re.tabList,role:"tablist",children:r.map((l,u)=>{if(!d.isValidElement(l))return null;const i=`${a}-tab-${u}`,m=`${a}-panel-${u}`,f=u===s;return d.cloneElement(l,{tabId:i,panelId:m,isActive:f,onSelect:()=>n==null?void 0:n(u),onKeyDown:v=>_(v,u)})})})},Za=({children:e,amount:s,isActive:n,onSelect:a,onClick:r,onKeyDown:o,tabId:_,panelId:l,className:u,...i})=>{const m=T([re.tab,n&&re.active,i.disabled&&re.disabled,u]),f=x=>{r==null||r(x),!x.defaultPrevented&&(a==null||a())},v=x=>{o==null||o(x)};return t.jsxs("button",{...i,id:_,role:"tab",type:"button","aria-selected":n,"aria-controls":l,className:m,onClick:f,onKeyDown:v,children:[t.jsx("span",{className:re.tabLabel,children:e}),s&&t.jsx("span",{className:re.tabAmount,children:s})]})},ht=({children:e,activeIndex:s=0,baseId:n})=>t.jsx("div",{className:re.tabPanels,children:d.Children.map(e,(a,r)=>{if(!d.isValidElement(a))return null;const o=`${n}-tab-${r}`,_=`${n}-panel-${r}`;return d.cloneElement(a,{isActive:r===s,tabId:o,panelId:_})})}),Ga=({children:e,isActive:s,tabId:n,panelId:a})=>t.jsx("div",{role:"tabpanel",id:a,"aria-labelledby":n,className:T([re.tabPanel,!s&&re.hidden]),hidden:!s,children:e});ye.List=_t;ye.Tab=Za;ye.Panels=ht;ye.Panel=Ga;const Ua=e=>{let s="";const n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",a=n.length;for(let r=0;r<e;r++)s+=n.charAt(Math.floor(Math.random()*a));return s},Ja="_textarea_1596u_1",Ka="_requiredSymbol_1596u_4",Qa="_hasErrors_1596u_55",Se={textarea:Ja,requiredSymbol:Ka,hasErrors:Qa},eo=({id:e,onChange:s,onBlur:n,name:a="",required:r=!1,readOnly:o,disabled:_,width:l,resize:u="both",value:i,defaultValue:m,elementKey:f,rows:v,label:x="",contentOnly:k=!1,placeholder:b="",defaultContent:N="","aria-describedby":z,hasErrors:j=!1,errorMessage:$=""})=>{const V=()=>`${e}-errorMessage`,D=!(i!=null&&i.length)&&(m!=null&&m.length)?m:void 0,M=f||`${e}-${Ua(6)}`,R={...l&&{maxWidth:l},...u&&{resize:u}},q={name:a,readOnly:o,disabled:_,required:r,id:e,onChange:s,onBlur:n,value:D?void 0:i,defaultValue:D||void 0,placeholder:b,rows:v?parseInt(v,10):void 0,className:j?Se.hasErrors:"","aria-describedby":j&&$?V():z,"aria-invalid":j?"true":void 0,style:R};return t.jsxs("div",{className:Se.textarea,children:[t.jsxs(de,{htmlFor:e,children:[x,r&&t.jsx("img",{src:ce,alt:"",className:Se.requiredSymbol})]}),k?t.jsx("span",{children:i||m||N}):t.jsx("textarea",{...q},M),t.jsx(fe,{id:V(),content:$})]})},to=({theme:e,children:s})=>{const n=jt(e),a=kt(n);return wt("theme-provider",`:root {${a}}`),s},so="_toggleNavigationButton_1eb2w_1",no={toggleNavigationButton:so},ro=({id:e,htmlTag:s="button",showText:n,hideText:a,buttonProps:r={},isOpen:o=!1})=>d.createElement(s,{...r,className:no.toggleNavigationButton,id:e||void 0},o?a:n),ao="_wizardTopnavContainer_qiy2o_1",oo="_wizardTopnav_qiy2o_1",co="_vertical_qiy2o_6",lo="_horizontal_qiy2o_11",ze={wizardTopnavContainer:ao,wizardTopnav:oo,vertical:co,horizontal:lo},io=({steps:e,activeStepId:s,direction:n="vertical","aria-label":a})=>{const r=Object.keys(e),_=`I dette skjemaet er det totalt ${r.length} steg som du skal gå igjennom`,l=a!=null&&a.length?a:_;return t.jsx("nav",{"aria-label":l,className:T([ze.wizardTopnavContainer,ze[n]]),children:t.jsx("ol",{className:ze.wizardTopnav,children:r.map((u,i)=>t.jsx(ut,{step:e[u],activeStepId:s,direction:n,index:i},u))})})};exports.Accordion=Vt;exports.Button=Ae;exports.CheckBoxIcon=Te;exports.CheckBoxInput=Re;exports.CheckBoxList=rt;exports.CheckBoxListItem=at;exports.Container=ot;exports.ContentBox=Ds;exports.DescriptionDetails=Ps;exports.DescriptionList=qs;exports.DescriptionTerm=Xs;exports.Dialog=an;exports.DragAndDropFileInput=gn;exports.ErrorBox=Sn;exports.ErrorMessage=fe;exports.Footer=Tn;exports.Header=Pe;exports.InfoBox=lt;exports.InputField=Yn;exports.Label=de;exports.Lead=Gn;exports.List=Kn;exports.ListItem=tr;exports.LoadingAnimation=rr;exports.LoadingAnimation2=cr;exports.NavigationBar=Er;exports.NavigationBarListItem=De;exports.Paper=Sr;exports.ProgressBar=Tr;exports.RadioButtonIcon=it;exports.RadioButtonInput=Fe;exports.RadioButtonList=Wr;exports.RadioButtonListItem=Qr;exports.Select=dt;exports.Table=Aa;exports.Tabs=ye;exports.Textarea=eo;exports.ThemeProvider=to;exports.ToggleNavigationButton=ro;exports.WizardNavigation=io;exports.WizardNavigationStep=ut;
|
|
34
23
|
//# sourceMappingURL=index.cjs.js.map
|