dibk-design 9.0.0 → 9.0.2
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 -0
- package/dist/dibk-design.css +1 -1
- package/dist/index.cjs.js +34 -0
- package/dist/index.cjs.js.map +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.es.js +3196 -0
- package/dist/index.es.js.map +1 -0
- package/dist/index.umd.js +34 -0
- package/dist/index.umd.js.map +1 -0
- package/package.json +30 -24
- package/dist/dibk-design.js +0 -4413
- package/dist/dibk-design.js.map +0 -1
- package/dist/favicon.ico +0 -0
- package/dist/index.html +0 -38
- package/dist/manifest.json +0 -15
- package/dist/robots.txt +0 -3
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const b=require("react");function Gt(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const a=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,a.get?a:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const p=Gt(b);var Le={exports:{}},ge={};/**
|
|
2
|
+
* @license React
|
|
3
|
+
* react-jsx-runtime.production.js
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the MIT license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree.
|
|
9
|
+
*/var it;function Kt(){if(it)return ge;it=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(a,r,s){var c=null;if(s!==void 0&&(c=""+s),r.key!==void 0&&(c=""+r.key),"key"in r){s={};for(var u in r)u!=="key"&&(s[u]=r[u])}else s=r;return r=s.ref,{$$typeof:e,type:a,key:c,ref:r!==void 0?r:null,props:s}}return ge.Fragment=t,ge.jsx=n,ge.jsxs=n,ge}var ve={};/**
|
|
10
|
+
* @license React
|
|
11
|
+
* react-jsx-runtime.development.js
|
|
12
|
+
*
|
|
13
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
14
|
+
*
|
|
15
|
+
* This source code is licensed under the MIT license found in the
|
|
16
|
+
* LICENSE file in the root directory of this source tree.
|
|
17
|
+
*/var lt;function Zt(){return lt||(lt=1,process.env.NODE_ENV!=="production"&&function(){function e(g){if(g==null)return null;if(typeof g=="function")return g.$$typeof===D?null:g.displayName||g.name||null;if(typeof g=="string")return g;switch(g){case v:return"Fragment";case f:return"Profiler";case k:return"StrictMode";case $:return"Suspense";case I:return"SuspenseList";case M:return"Activity"}if(typeof g=="object")switch(typeof g.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),g.$$typeof){case m:return"Portal";case E:return(g.displayName||"Context")+".Provider";case x:return(g._context.displayName||"Context")+".Consumer";case w:var L=g.render;return g=g.displayName,g||(g=L.displayName||L.name||"",g=g!==""?"ForwardRef("+g+")":"ForwardRef"),g;case R:return L=g.displayName||null,L!==null?L:e(g.type)||"Memo";case S:L=g._payload,g=g._init;try{return e(g(L))}catch{}}return null}function t(g){return""+g}function n(g){try{t(g);var L=!1}catch{L=!0}if(L){L=console;var z=L.error,O=typeof Symbol=="function"&&Symbol.toStringTag&&g[Symbol.toStringTag]||g.constructor.name||"Object";return z.call(L,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",O),t(g)}}function a(g){if(g===v)return"<>";if(typeof g=="object"&&g!==null&&g.$$typeof===S)return"<...>";try{var L=e(g);return L?"<"+L+">":"<...>"}catch{return"<...>"}}function r(){var g=V.A;return g===null?null:g.getOwner()}function s(){return Error("react-stack-top-frame")}function c(g){if(H.call(g,"key")){var L=Object.getOwnPropertyDescriptor(g,"key").get;if(L&&L.isReactWarning)return!1}return g.key!==void 0}function u(g,L){function z(){F||(F=!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)",L))}z.isReactWarning=!0,Object.defineProperty(g,"key",{get:z,configurable:!0})}function o(){var g=e(this.type);return N[g]||(N[g]=!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.")),g=this.props.ref,g!==void 0?g:null}function l(g,L,z,O,ee,X,Pe,De){return z=X.ref,g={$$typeof:y,type:g,key:L,props:X,_owner:ee},(z!==void 0?z:null)!==null?Object.defineProperty(g,"ref",{enumerable:!1,get:o}):Object.defineProperty(g,"ref",{enumerable:!1,value:null}),g._store={},Object.defineProperty(g._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(g,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(g,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:Pe}),Object.defineProperty(g,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:De}),Object.freeze&&(Object.freeze(g.props),Object.freeze(g)),g}function d(g,L,z,O,ee,X,Pe,De){var q=L.children;if(q!==void 0)if(O)if(j(q)){for(O=0;O<q.length;O++)_(q[O]);Object.freeze&&Object.freeze(q)}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 _(q);if(H.call(L,"key")){q=e(g);var oe=Object.keys(L).filter(function(Jt){return Jt!=="key"});O=0<oe.length?"{key: someKey, "+oe.join(": ..., ")+": ...}":"{key: someKey}",ot[q+O]||(oe=0<oe.length?"{"+oe.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
|
|
18
|
+
let props = %s;
|
|
19
|
+
<%s {...props} />
|
|
20
|
+
React keys must be passed directly to JSX without using spread:
|
|
21
|
+
let props = %s;
|
|
22
|
+
<%s key={someKey} {...props} />`,O,q,oe,q),ot[q+O]=!0)}if(q=null,z!==void 0&&(n(z),q=""+z),c(L)&&(n(L.key),q=""+L.key),"key"in L){z={};for(var Ae in L)Ae!=="key"&&(z[Ae]=L[Ae])}else z=L;return q&&u(z,typeof g=="function"?g.displayName||g.name||"Unknown":g),l(g,q,X,ee,r(),z,Pe,De)}function _(g){typeof g=="object"&&g!==null&&g.$$typeof===y&&g._store&&(g._store.validated=1)}var h=b,y=Symbol.for("react.transitional.element"),m=Symbol.for("react.portal"),v=Symbol.for("react.fragment"),k=Symbol.for("react.strict_mode"),f=Symbol.for("react.profiler"),x=Symbol.for("react.consumer"),E=Symbol.for("react.context"),w=Symbol.for("react.forward_ref"),$=Symbol.for("react.suspense"),I=Symbol.for("react.suspense_list"),R=Symbol.for("react.memo"),S=Symbol.for("react.lazy"),M=Symbol.for("react.activity"),D=Symbol.for("react.client.reference"),V=h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,H=Object.prototype.hasOwnProperty,j=Array.isArray,C=console.createTask?console.createTask:function(){return null};h={"react-stack-bottom-frame":function(g){return g()}};var F,N={},B=h["react-stack-bottom-frame"].bind(h,s)(),ke=C(a(s)),ot={};ve.Fragment=v,ve.jsx=function(g,L,z,O,ee){var X=1e4>V.recentlyCreatedOwnerStacks++;return d(g,L,z,!1,O,ee,X?Error("react-stack-top-frame"):B,X?C(a(g)):ke)},ve.jsxs=function(g,L,z,O,ee){var X=1e4>V.recentlyCreatedOwnerStacks++;return d(g,L,z,!0,O,ee,X?Error("react-stack-top-frame"):B,X?C(a(g)):ke)}}()),ve}var ct;function Qt(){return ct||(ct=1,process.env.NODE_ENV==="production"?Le.exports=Kt():Le.exports=Zt()),Le.exports}var i=Qt();const T=e=>(e==null?void 0:e.filter(Boolean).join(" "))||"",Ct=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),en=e=>!(e!=null&&e.colors)||!Object.entries(e.colors).length?{}:Object.entries(e.colors).reduce((t,[n,a])=>(n&&a&&(t[`--color-${Ct(n)}`]=a),t),{}),tn=e=>!(e!=null&&e.sizes)||!Object.entries(e.sizes).length?{}:Object.entries(e.sizes).reduce((t,[n,a])=>(n&&a&&(t[`--size-${Ct(n)}`]=a),t),{}),nn=e=>({...en(e),...tn(e)}),rn=(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)},an=e=>Object.entries(e).map(([t,n])=>`${t}: ${n};`).join(""),pe=e=>{const t=[];return b.Children.forEach(e,n=>{if(b.isValidElement(n)){const a=n;if(a.type===b.Fragment){const r=pe(a.props.children);t.push(...r)}else t.push(b.cloneElement(a,{...a.props}))}else t.push(n)}),t},sn=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()},on=e=>Array.from(e.querySelectorAll('button, [href], input, [tabindex="0"]')).filter(n=>!!n),kt=e=>{sn(e);const t=on(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())})},ln="_accordion_kwqaf_67",cn="_panel_kwqaf_76",un="_content_kwqaf_77",dn="_secondary_kwqaf_80",hn="_info_kwqaf_88",mn="_contrast_kwqaf_96",fn="_margin_kwqaf_104",pn="_panelText_kwqaf_138",_n="_panelChevron_kwqaf_144",gn="_expanded_kwqaf_171",vn="_initialized_kwqaf_187",yn="_hide_kwqaf_1",xn="_show_kwqaf_1",W={accordion:ln,default:"_default_kwqaf_73",panel:cn,content:un,secondary:dn,info:hn,contrast:mn,margin:fn,panelText:pn,panelChevron:_n,expanded:gn,initialized:vn,hide:yn,show:xn},bn=({title:e,color:t="default",expanded:n=!1,onToggleExpand:a,buttonProps:r,noMargin:s=!1,initialized:c,children:u,...o})=>{const[l,d]=b.useState(n),[_,h]=b.useState(c),y=()=>{d(!l),h(!0),a&&a()};b.useEffect(()=>{d(n)},[n]);const m=()=>i.jsxs("button",{...r,className:W.panel,onClick:y,"aria-expanded":l?"true":"false",children:[i.jsx("span",{className:W.panelText,children:e}),i.jsx("span",{className:`${W.panelChevron} ${l?W.expanded:""}`})]}),v=T([W.accordion,t&&W[t],!s&&W.margin,o.className]);return i.jsxs("div",{className:v,...o,children:[i.jsx(m,{}),i.jsx("div",{className:`${W.content} ${_?W.initialized:""} ${l?W.expanded:""}`,children:u})]})};var ye={},ut;function wn(){if(ut)return ye;ut=1,Object.defineProperty(ye,"__esModule",{value:!0}),ye.parse=c,ye.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 m=new s,v=h.length;if(v<2)return m;const k=(y==null?void 0:y.decode)||d;let f=0;do{const x=h.indexOf("=",f);if(x===-1)break;const E=h.indexOf(";",f),w=E===-1?v:E;if(x>w){f=h.lastIndexOf(";",x-1)+1;continue}const $=u(h,f,x),I=o(h,x,$),R=h.slice($,I);if(m[R]===void 0){let S=u(h,x+1,w),M=o(h,w,S);const D=k(h.slice(S,M));m[R]=D}f=w+1}while(f<v);return m}function u(h,y,m){do{const v=h.charCodeAt(y);if(v!==32&&v!==9)return y}while(++y<m);return m}function o(h,y,m){for(;y>m;){const v=h.charCodeAt(--y);if(v!==32&&v!==9)return y+1}return m}function l(h,y,m){const v=(m==null?void 0:m.encode)||encodeURIComponent;if(!e.test(h))throw new TypeError(`argument name is invalid: ${h}`);const k=v(y);if(!t.test(k))throw new TypeError(`argument val is invalid: ${y}`);let f=h+"="+k;if(!m)return f;if(m.maxAge!==void 0){if(!Number.isInteger(m.maxAge))throw new TypeError(`option maxAge is invalid: ${m.maxAge}`);f+="; Max-Age="+m.maxAge}if(m.domain){if(!n.test(m.domain))throw new TypeError(`option domain is invalid: ${m.domain}`);f+="; Domain="+m.domain}if(m.path){if(!a.test(m.path))throw new TypeError(`option path is invalid: ${m.path}`);f+="; Path="+m.path}if(m.expires){if(!_(m.expires)||!Number.isFinite(m.expires.valueOf()))throw new TypeError(`option expires is invalid: ${m.expires}`);f+="; Expires="+m.expires.toUTCString()}if(m.httpOnly&&(f+="; HttpOnly"),m.secure&&(f+="; Secure"),m.partitioned&&(f+="; Partitioned"),m.priority)switch(typeof m.priority=="string"?m.priority.toLowerCase():void 0){case"low":f+="; Priority=Low";break;case"medium":f+="; Priority=Medium";break;case"high":f+="; Priority=High";break;default:throw new TypeError(`option priority is invalid: ${m.priority}`)}if(m.sameSite)switch(typeof m.sameSite=="string"?m.sameSite.toLowerCase():m.sameSite){case!0:case"strict":f+="; SameSite=Strict";break;case"lax":f+="; SameSite=Lax";break;case"none":f+="; SameSite=None";break;default:throw new TypeError(`option sameSite is invalid: ${m.sameSite}`)}return f}function d(h){if(h.indexOf("%")===-1)return h;try{return decodeURIComponent(h)}catch{return h}}function _(h){return r.call(h)==="[object Date]"}return ye}wn();/**
|
|
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 A(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function K(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Ue({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 Ge(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 Lt(e,t,n="/"){return En(e,t,n,!1)}function En(e,t,n,a){let r=typeof t=="string"?Ge(t):t,s=ne(r.pathname||"/",n);if(s==null)return null;let c=St(e);Cn(c);let u=null;for(let o=0;u==null&&o<c.length;++o){let l=Tn(s);u=Nn(c[o],l,a)}return u}function St(e,t=[],n=[],a=""){let r=(s,c,u)=>{let o={relativePath:u===void 0?s.path||"":u,caseSensitive:s.caseSensitive===!0,childrenIndex:c,route:s};o.relativePath.startsWith("/")&&(A(o.relativePath.startsWith(a),`Absolute route path "${o.relativePath}" nested under path "${a}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),o.relativePath=o.relativePath.slice(a.length));let l=G([a,o.relativePath]),d=n.concat(o);s.children&&s.children.length>0&&(A(s.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${l}".`),St(s.children,t,d,l)),!(s.path==null&&!s.index)&&t.push({path:l,score:Rn(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 o of jt(s.path))r(s,c,o)}),t}function jt(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=jt(a.join("/")),u=[];return u.push(...c.map(o=>o===""?s:[s,o].join("/"))),r&&u.push(...c),u.map(o=>e.startsWith("/")&&o===""?"/":o)}function Cn(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Mn(t.routesMeta.map(a=>a.childrenIndex),n.routesMeta.map(a=>a.childrenIndex)))}var kn=/^:[\w-]+$/,Ln=3,Sn=2,jn=1,$n=10,In=-2,dt=e=>e==="*";function Rn(e,t){let n=e.split("/"),a=n.length;return n.some(dt)&&(a+=In),t&&(a+=Sn),n.filter(r=>!dt(r)).reduce((r,s)=>r+(kn.test(s)?Ln:s===""?jn:$n),a)}function Mn(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 Nn(e,t,n=!1){let{routesMeta:a}=e,r={},s="/",c=[];for(let u=0;u<a.length;++u){let o=a[u],l=u===a.length-1,d=s==="/"?t:t.slice(s.length)||"/",_=Ne({path:o.relativePath,caseSensitive:o.caseSensitive,end:l},d),h=o.route;if(!_&&l&&n&&!a[a.length-1].route.index&&(_=Ne({path:o.relativePath,caseSensitive:o.caseSensitive,end:!1},d)),!_)return null;Object.assign(r,_.params),c.push({params:r,pathname:G([s,_.pathname]),pathnameBase:An(G([s,_.pathnameBase])),route:h}),_.pathnameBase!=="/"&&(s=G([s,_.pathnameBase]))}return c}function Ne(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,a]=zn(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:_},h)=>{if(d==="*"){let m=u[h]||"";c=s.slice(0,s.length-m.length).replace(/(.)\/+$/,"$1")}const y=u[h];return _&&!y?l[d]=void 0:l[d]=(y||"").replace(/%2F/g,"/"),l},{}),pathname:s,pathnameBase:c,pattern:e}}function zn(e,t=!1,n=!0){K(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,o)=>(a.push({paramName:u,isOptional:o!=null}),o?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(a.push({paramName:"*"}),r+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?r+="\\/*$":e!==""&&e!=="/"&&(r+="(?:(?=\\/|$))"),[new RegExp(r,t?void 0:"i"),a]}function Tn(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return K(!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 ne(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 Bn(e,t="/"){let{pathname:n,search:a="",hash:r=""}=typeof e=="string"?Ge(e):e;return{pathname:n?n.startsWith("/")?n:Pn(n,t):t,search:Fn(a),hash:On(r)}}function Pn(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 Fe(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 Dn(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function $t(e){let t=Dn(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=Ge(e):(r={...e},A(!r.pathname||!r.pathname.includes("?"),Fe("?","pathname","search",r)),A(!r.pathname||!r.pathname.includes("#"),Fe("#","pathname","hash",r)),A(!r.search||!r.search.includes("#"),Fe("#","search","hash",r)));let s=e===""||r.pathname==="",c=s?"/":r.pathname,u;if(c==null)u=n;else{let _=t.length-1;if(!a&&c.startsWith("..")){let h=c.split("/");for(;h[0]==="..";)h.shift(),_-=1;r.pathname=h.join("/")}u=_>=0?t[_]:"/"}let o=Bn(r,u),l=c&&c!=="/"&&c.endsWith("/"),d=(s||c===".")&&n.endsWith("/");return!o.pathname.endsWith("/")&&(l||d)&&(o.pathname+="/"),o}var G=e=>e.join("/").replace(/\/\/+/g,"/"),An=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Fn=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,On=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 Rt=["POST","PUT","PATCH","DELETE"];new Set(Rt);var Vn=["GET",...Rt];new Set(Vn);var _e=p.createContext(null);_e.displayName="DataRouter";var ze=p.createContext(null);ze.displayName="DataRouterState";var Mt=p.createContext({isTransitioning:!1});Mt.displayName="ViewTransition";var Hn=p.createContext(new Map);Hn.displayName="Fetchers";var Xn=p.createContext(null);Xn.displayName="Await";var Z=p.createContext(null);Z.displayName="Navigation";var Ke=p.createContext(null);Ke.displayName="Location";var Q=p.createContext({outlet:null,matches:[],isDataRoute:!1});Q.displayName="Route";var Ze=p.createContext(null);Ze.displayName="RouteError";function Wn(e,{relative:t}={}){A(Te(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:a}=p.useContext(Z),{hash:r,pathname:s,search:c}=Ee(e,{relative:t}),u=s;return n!=="/"&&(u=s==="/"?n:G([n,s])),a.createHref({pathname:u,search:c,hash:r})}function Te(){return p.useContext(Ke)!=null}function se(){return A(Te(),"useLocation() may be used only in the context of a <Router> component."),p.useContext(Ke).location}var Nt="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function zt(e){p.useContext(Z).static||p.useLayoutEffect(e)}function Un(){let{isDataRoute:e}=p.useContext(Q);return e?or():Yn()}function Yn(){A(Te(),"useNavigate() may be used only in the context of a <Router> component.");let e=p.useContext(_e),{basename:t,navigator:n}=p.useContext(Z),{matches:a}=p.useContext(Q),{pathname:r}=se(),s=JSON.stringify($t(a)),c=p.useRef(!1);return zt(()=>{c.current=!0}),p.useCallback((o,l={})=>{if(K(c.current,Nt),!c.current)return;if(typeof o=="number"){n.go(o);return}let d=It(o,JSON.parse(s),r,l.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:G([t,d.pathname])),(l.replace?n.replace:n.push)(d,l.state,l)},[t,n,s,r,e])}p.createContext(null);function Ee(e,{relative:t}={}){let{matches:n}=p.useContext(Q),{pathname:a}=se(),r=JSON.stringify($t(n));return p.useMemo(()=>It(e,JSON.parse(r),a,t==="path"),[e,r,a,t])}function Jn(e,t,n,a){A(Te(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:r}=p.useContext(Z),{matches:s}=p.useContext(Q),c=s[s.length-1],u=c?c.params:{},o=c?c.pathname:"/",l=c?c.pathnameBase:"/",d=c&&c.route;{let f=d&&d.path||"";Tt(o,!d||f.endsWith("*")||f.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${o}" (under <Route path="${f}">) 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="${f}"> to <Route path="${f==="/"?"*":`${f}/*`}">.`)}let _=se(),h;h=_;let y=h.pathname||"/",m=y;if(l!=="/"){let f=l.replace(/^\//,"").split("/");m="/"+y.replace(/^\//,"").split("/").slice(f.length).join("/")}let v=Lt(e,{pathname:m});return K(d||v!=null,`No routes matched location "${h.pathname}${h.search}${h.hash}" `),K(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.`),er(v&&v.map(f=>Object.assign({},f,{params:Object.assign({},u,f.params),pathname:G([l,r.encodeLocation?r.encodeLocation(f.pathname).pathname:f.pathname]),pathnameBase:f.pathnameBase==="/"?l:G([l,r.encodeLocation?r.encodeLocation(f.pathnameBase).pathname:f.pathnameBase])})),s,n,a)}function Gn(){let e=sr(),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=p.createElement(p.Fragment,null,p.createElement("p",null,"💿 Hey developer 👋"),p.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",p.createElement("code",{style:s},"ErrorBoundary")," or"," ",p.createElement("code",{style:s},"errorElement")," prop on your route.")),p.createElement(p.Fragment,null,p.createElement("h2",null,"Unexpected Application Error!"),p.createElement("h3",{style:{fontStyle:"italic"}},t),n?p.createElement("pre",{style:r},n):null,c)}var Kn=p.createElement(Gn,null),Zn=class extends p.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?p.createElement(Q.Provider,{value:this.props.routeContext},p.createElement(Ze.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function Qn({routeContext:e,match:t,children:n}){let a=p.useContext(_e);return a&&a.static&&a.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(a.staticContext._deepestRenderedBoundaryId=t.route.id),p.createElement(Q.Provider,{value:e},n)}function er(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 o=r.findIndex(l=>l.route.id&&(s==null?void 0:s[l.route.id])!==void 0);A(o>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(s).join(",")}`),r=r.slice(0,Math.min(r.length,o+1))}let c=!1,u=-1;if(n)for(let o=0;o<r.length;o++){let l=r[o];if((l.route.HydrateFallback||l.route.hydrateFallbackElement)&&(u=o),l.route.id){let{loaderData:d,errors:_}=n,h=l.route.loader&&!d.hasOwnProperty(l.route.id)&&(!_||_[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((o,l,d)=>{let _,h=!1,y=null,m=null;n&&(_=s&&l.route.id?s[l.route.id]:void 0,y=l.route.errorElement||Kn,c&&(u<0&&d===0?(Tt("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),h=!0,m=null):u===d&&(h=!0,m=l.route.hydrateFallbackElement||null)));let v=t.concat(r.slice(0,d+1)),k=()=>{let f;return _?f=y:h?f=m:l.route.Component?f=p.createElement(l.route.Component,null):l.route.element?f=l.route.element:f=o,p.createElement(Qn,{match:l,routeContext:{outlet:o,matches:v,isDataRoute:n!=null},children:f})};return n&&(l.route.ErrorBoundary||l.route.errorElement||d===0)?p.createElement(Zn,{location:n.location,revalidation:n.revalidation,component:y,error:_,children:k(),routeContext:{outlet:null,matches:v,isDataRoute:!0}}):k()},null)}function Qe(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function tr(e){let t=p.useContext(_e);return A(t,Qe(e)),t}function nr(e){let t=p.useContext(ze);return A(t,Qe(e)),t}function rr(e){let t=p.useContext(Q);return A(t,Qe(e)),t}function et(e){let t=rr(e),n=t.matches[t.matches.length-1];return A(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function ar(){return et("useRouteId")}function sr(){var a;let e=p.useContext(Ze),t=nr("useRouteError"),n=et("useRouteError");return e!==void 0?e:(a=t.errors)==null?void 0:a[n]}function or(){let{router:e}=tr("useNavigate"),t=et("useNavigate"),n=p.useRef(!1);return zt(()=>{n.current=!0}),p.useCallback(async(r,s={})=>{K(n.current,Nt),n.current&&(typeof r=="number"?e.navigate(r):await e.navigate(r,{fromRouteId:t,...s}))},[e,t])}var ht={};function Tt(e,t,n){!t&&!ht[e]&&(ht[e]=!0,K(!1,n))}p.memo(ir);function ir({routes:e,future:t,state:n}){return Jn(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 lr(e){return Be(e)&&e.tagName.toLowerCase()==="button"}function cr(e){return Be(e)&&e.tagName.toLowerCase()==="form"}function ur(e){return Be(e)&&e.tagName.toLowerCase()==="input"}function dr(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function hr(e,t){return e.button===0&&(!t||t==="_self")&&!dr(e)}var Se=null;function mr(){if(Se===null)try{new FormData(document.createElement("form"),0),Se=!1}catch{Se=!0}return Se}var fr=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Oe(e){return e!=null&&!fr.has(e)?(K(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Me}"`),null):e}function pr(e,t){let n,a,r,s,c;if(cr(e)){let u=e.getAttribute("action");a=u?ne(u,t):null,n=e.getAttribute("method")||Re,r=Oe(e.getAttribute("enctype"))||Me,s=new FormData(e)}else if(lr(e)||ur(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 o=e.getAttribute("formaction")||u.getAttribute("action");if(a=o?ne(o,t):null,n=e.getAttribute("formmethod")||u.getAttribute("method")||Re,r=Oe(e.getAttribute("formenctype"))||Oe(u.getAttribute("enctype"))||Me,s=new FormData(u,e),!mr()){let{name:l,type:d,value:_}=e;if(d==="image"){let h=l?`${l}.`:"";s.append(`${h}x`,"0"),s.append(`${h}y`,"0")}else l&&s.append(l,_)}}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 tt(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}async function _r(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 gr(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 vr(e,t,n){let a=await Promise.all(e.map(async r=>{let s=t.routes[r.route.id];if(s){let c=await _r(s,n);return c.links?c.links():[]}return[]}));return wr(a.flat(1).filter(gr).filter(r=>r.rel==="stylesheet"||r.rel==="preload").map(r=>r.rel==="stylesheet"?{...r,rel:"prefetch",as:"style"}:{...r,rel:"prefetch"}))}function mt(e,t,n,a,r,s){let c=(o,l)=>n[l]?o.route.id!==n[l].route.id:!0,u=(o,l)=>{var d;return n[l].pathname!==o.pathname||((d=n[l].route.path)==null?void 0:d.endsWith("*"))&&n[l].params["*"]!==o.params["*"]};return s==="assets"?t.filter((o,l)=>c(o,l)||u(o,l)):s==="data"?t.filter((o,l)=>{var _;let d=a.routes[o.route.id];if(!d||!d.hasLoader)return!1;if(c(o,l)||u(o,l))return!0;if(o.route.shouldRevalidate){let h=o.route.shouldRevalidate({currentUrl:new URL(r.pathname+r.search+r.hash,window.origin),currentParams:((_=n[0])==null?void 0:_.params)||{},nextUrl:new URL(e,window.origin),nextParams:o.params,defaultShouldRevalidate:!0});if(typeof h=="boolean")return h}return!0}):[]}function yr(e,t,{includeHydrateFallback:n}={}){return xr(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 xr(e){return[...new Set(e)]}function br(e){let t={},n=Object.keys(e).sort();for(let a of n)t[a]=e[a];return t}function wr(e,t){let n=new Set;return new Set(t),e.reduce((a,r)=>{let s=JSON.stringify(br(r));return n.has(s)||(n.add(s),a.push({key:s,link:r})),a},[])}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var Er=new Set([100,101,204,205]);function Cr(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&&ne(n.pathname,t)==="/"?n.pathname=`${t.replace(/\/$/,"")}/_root.data`:n.pathname=`${n.pathname.replace(/\/$/,"")}.data`,n}function Bt(){let e=p.useContext(_e);return tt(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function kr(){let e=p.useContext(ze);return tt(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var nt=p.createContext(void 0);nt.displayName="FrameworkContext";function Pt(){let e=p.useContext(nt);return tt(e,"You must render this element inside a <HydratedRouter> element"),e}function Lr(e,t){let n=p.useContext(nt),[a,r]=p.useState(!1),[s,c]=p.useState(!1),{onFocus:u,onBlur:o,onMouseEnter:l,onMouseLeave:d,onTouchStart:_}=t,h=p.useRef(null);p.useEffect(()=>{if(e==="render"&&c(!0),e==="viewport"){let v=f=>{f.forEach(x=>{c(x.isIntersecting)})},k=new IntersectionObserver(v,{threshold:.5});return h.current&&k.observe(h.current),()=>{k.disconnect()}}},[e]),p.useEffect(()=>{if(a){let v=setTimeout(()=>{c(!0)},100);return()=>{clearTimeout(v)}}},[a]);let y=()=>{r(!0)},m=()=>{r(!1),c(!1)};return n?e!=="intent"?[s,h,{}]:[s,h,{onFocus:xe(u,y),onBlur:xe(o,m),onMouseEnter:xe(l,y),onMouseLeave:xe(d,m),onTouchStart:xe(_,y)}]:[!1,h,{}]}function xe(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function Sr({page:e,...t}){let{router:n}=Bt(),a=p.useMemo(()=>Lt(n.routes,e,n.basename),[n.routes,e,n.basename]);return a?p.createElement($r,{page:e,matches:a,...t}):null}function jr(e){let{manifest:t,routeModules:n}=Pt(),[a,r]=p.useState([]);return p.useEffect(()=>{let s=!1;return vr(e,t,n).then(c=>{s||r(c)}),()=>{s=!0}},[e,t,n]),a}function $r({page:e,matches:t,...n}){let a=se(),{manifest:r,routeModules:s}=Pt(),{basename:c}=Bt(),{loaderData:u,matches:o}=kr(),l=p.useMemo(()=>mt(e,t,o,r,a,"data"),[e,t,o,r,a]),d=p.useMemo(()=>mt(e,t,o,r,a,"assets"),[e,t,o,r,a]),_=p.useMemo(()=>{if(e===a.pathname+a.search+a.hash)return[];let m=new Set,v=!1;if(t.forEach(f=>{var E;let x=r.routes[f.route.id];!x||!x.hasLoader||(!l.some(w=>w.route.id===f.route.id)&&f.route.id in u&&((E=s[f.route.id])!=null&&E.shouldRevalidate)||x.hasClientLoader?v=!0:m.add(f.route.id))}),m.size===0)return[];let k=Cr(e,c);return v&&m.size>0&&k.searchParams.set("_routes",t.filter(f=>m.has(f.route.id)).map(f=>f.route.id).join(",")),[k.pathname+k.search]},[c,u,a,r,l,t,e,s]),h=p.useMemo(()=>yr(d,r),[d,r]),y=jr(d);return p.createElement(p.Fragment,null,_.map(m=>p.createElement("link",{key:m,rel:"prefetch",as:"fetch",href:m,...n})),h.map(m=>p.createElement("link",{key:m,rel:"modulepreload",href:m,...n})),y.map(({key:m,link:v})=>p.createElement("link",{key:m,...v})))}function Ir(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var Dt=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{Dt&&(window.__reactRouterVersion="7.6.2")}catch{}var At=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,be=p.forwardRef(function({onClick:t,discover:n="render",prefetch:a="none",relative:r,reloadDocument:s,replace:c,state:u,target:o,to:l,preventScrollReset:d,viewTransition:_,...h},y){let{basename:m}=p.useContext(Z),v=typeof l=="string"&&At.test(l),k,f=!1;if(typeof l=="string"&&v&&(k=l,Dt))try{let M=new URL(window.location.href),D=l.startsWith("//")?new URL(M.protocol+l):new URL(l),V=ne(D.pathname,m);D.origin===M.origin&&V!=null?l=V+D.search+D.hash:f=!0}catch{K(!1,`<Link to="${l}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let x=Wn(l,{relative:r}),[E,w,$]=Lr(a,h),I=zr(l,{replace:c,state:u,target:o,preventScrollReset:d,relative:r,viewTransition:_});function R(M){t&&t(M),M.defaultPrevented||I(M)}let S=p.createElement("a",{...h,...$,href:k||x,onClick:f||s?t:R,ref:Ir(y,w),target:o,"data-discover":!v&&n==="render"?"true":void 0});return E&&!v?p.createElement(p.Fragment,null,S,p.createElement(Sr,{page:x})):S});be.displayName="Link";var Rr=p.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:a="",end:r=!1,style:s,to:c,viewTransition:u,children:o,...l},d){let _=Ee(c,{relative:l.relative}),h=se(),y=p.useContext(ze),{navigator:m,basename:v}=p.useContext(Z),k=y!=null&&Ar(_)&&u===!0,f=m.encodeLocation?m.encodeLocation(_).pathname:_.pathname,x=h.pathname,E=y&&y.navigation&&y.navigation.location?y.navigation.location.pathname:null;n||(x=x.toLowerCase(),E=E?E.toLowerCase():null,f=f.toLowerCase()),E&&v&&(E=ne(E,v)||E);const w=f!=="/"&&f.endsWith("/")?f.length-1:f.length;let $=x===f||!r&&x.startsWith(f)&&x.charAt(w)==="/",I=E!=null&&(E===f||!r&&E.startsWith(f)&&E.charAt(f.length)==="/"),R={isActive:$,isPending:I,isTransitioning:k},S=$?t:void 0,M;typeof a=="function"?M=a(R):M=[a,$?"active":null,I?"pending":null,k?"transitioning":null].filter(Boolean).join(" ");let D=typeof s=="function"?s(R):s;return p.createElement(be,{...l,"aria-current":S,className:M,ref:d,style:D,to:c,viewTransition:u},typeof o=="function"?o(R):o)});Rr.displayName="NavLink";var Mr=p.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:a,replace:r,state:s,method:c=Re,action:u,onSubmit:o,relative:l,preventScrollReset:d,viewTransition:_,...h},y)=>{let m=Pr(),v=Dr(u,{relative:l}),k=c.toLowerCase()==="get"?"get":"post",f=typeof u=="string"&&At.test(u),x=E=>{if(o&&o(E),E.defaultPrevented)return;E.preventDefault();let w=E.nativeEvent.submitter,$=(w==null?void 0:w.getAttribute("formmethod"))||c;m(w||E.currentTarget,{fetcherKey:t,method:$,navigate:n,replace:r,state:s,relative:l,preventScrollReset:d,viewTransition:_})};return p.createElement("form",{ref:y,method:k,action:v,onSubmit:a?o:x,...h,"data-discover":!f&&e==="render"?"true":void 0})});Mr.displayName="Form";function Nr(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=p.useContext(_e);return A(t,Nr(e)),t}function zr(e,{target:t,replace:n,state:a,preventScrollReset:r,relative:s,viewTransition:c}={}){let u=Un(),o=se(),l=Ee(e,{relative:s});return p.useCallback(d=>{if(hr(d,t)){d.preventDefault();let _=n!==void 0?n:Ue(o)===Ue(l);u(e,{replace:_,state:a,preventScrollReset:r,relative:s,viewTransition:c})}},[o,u,l,n,a,t,e,r,s,c])}var Tr=0,Br=()=>`__${String(++Tr)}__`;function Pr(){let{router:e}=Ft("useSubmit"),{basename:t}=p.useContext(Z),n=ar();return p.useCallback(async(a,r={})=>{let{action:s,method:c,encType:u,formData:o,body:l}=pr(a,t);if(r.navigate===!1){let d=r.fetcherKey||Br();await e.fetch(d,n,r.action||s,{preventScrollReset:r.preventScrollReset,formData:o,body:l,formMethod:r.method||c,formEncType:r.encType||u,flushSync:r.flushSync})}else await e.navigate(r.action||s,{preventScrollReset:r.preventScrollReset,formData:o,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 Dr(e,{relative:t}={}){let{basename:n}=p.useContext(Z),a=p.useContext(Q);A(a,"useFormAction must be used inside a RouteContext");let[r]=a.matches.slice(-1),s={...Ee(e||".",{relative:t})},c=se();if(e==null){s.search=c.search;let u=new URLSearchParams(s.search),o=u.getAll("index");if(o.some(d=>d==="")){u.delete("index"),o.filter(_=>_).forEach(_=>u.append("index",_));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:G([n,s.pathname])),Ue(s)}function Ar(e,t={}){let n=p.useContext(Mt);A(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=Ee(e,{relative:t.relative});if(!n.isTransitioning)return!1;let s=ne(n.currentLocation.pathname,a)||n.currentLocation.pathname,c=ne(n.nextLocation.pathname,a)||n.nextLocation.pathname;return Ne(r.pathname,c)!=null||Ne(r.pathname,s)!=null}[...Er];const Fr="_button_w916g_161",Or="_noMargin_w916g_189",qr="_regular_w916g_199",Vr="_small_w916g_202",Hr="_primary_w916g_213",Xr="_noHover_w916g_217",Wr="_secondary_w916g_233",Ur="_disabled_w916g_252",Yr="_hasErrors_w916g_272",Jr="_rounded_w916g_278",Gr="_hasArrowLeft_w916g_282",Kr="_pushprev_w916g_1",Zr="_hasArrowRight_w916g_320",Qr="_pushnext_w916g_1",U={button:Fr,noMargin:Or,regular:qr,small:Vr,primary:Hr,noHover:Xr,secondary:Wr,disabled:Ur,hasErrors:Yr,rounded:Jr,hasArrowLeft:Gr,pushprev:Kr,hasArrowRight:Zr,pushnext:Qr},rt=({content:e,color:t="primary",size:n="regular",arrow:a="none",disabled:r=!1,inputType:s,defaultChecked:c,hasErrors:u=!1,noHover:o=!1,rounded:l=!1,noMargin:d=!1,href:_,children:h,...y})=>{const m=w=>{switch(w){case"left":return U.hasArrowLeft;case"right":return U.hasArrowRight;default:return""}},v=s==="radio"?c?"primary":"secondary":t,k=T([U.button,U[v],U[n],m(a),o||s==="radio"?U.noHover:null,l&&U.rounded,u&&U.hasErrors,r&&U.disabled,d&&U.noMargin]),f={"aria-invalid":u||void 0,href:!r&&(_!=null&&_.length)?_:void 0,className:k,...y},x=w=>b.Children.toArray(pe(w)).map((I,R)=>{if(!b.isValidElement(I))return null;const S=I,M=S.type===be&&typeof S.props=="object"&&S.props!==null&&"to"in S.props;return!r&&M?b.cloneElement(S,{className:k,key:`button-${R}`,to:S.props.to}):b.createElement("button",{...f,key:`button-${R}`},e||S.props&&S.props.children)});if(s==="button")return i.jsx("button",{type:"button",...f,children:e||h});if(s==="radio"){const w={...f};return delete w.href,i.jsxs("label",{className:k,children:[i.jsx("input",{...w,type:"radio"}),e]})}if(_!=null&&_.length&&!r){const w={...f};return"type"in w&&delete w.type,i.jsx("a",{...w,children:e||h})}return b.isValidElement(h)&&h.type===be?i.jsx(b.Fragment,{children:x(b.Children.toArray(h))}):i.jsx("button",{...f,children:e||h})},ea="_checkBoxIcon_1kc3w_1",ta="_showBox_1kc3w_22",na="_hasErrors_1kc3w_27",ra="_checked_1kc3w_37",aa="_disabled_1kc3w_53",sa="_checkmark_1kc3w_58",ie={checkBoxIcon:ea,showBox:ta,hasErrors:na,checked:ra,disabled:aa,checkmark:sa},Ye=({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=[ie.checkBoxIcon,t&&ie.checked,n&&ie.disabled,a&&ie.showBox,r&&ie.hasErrors].filter(Boolean).join(" ");return i.jsx("span",{className:u,style:c,children:i.jsx("span",{"aria-hidden":!0,className:ie.checkmark,children:t?s:""})})},re="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",oa="_checkBoxInput_f1w9m_1",ia="_requiredSymbol_f1w9m_6",la="_contentOnly_f1w9m_13",ca="_disabled_f1w9m_13",ua="_labelText_f1w9m_19",da="_hasErrors_f1w9m_27",le={checkBoxInput:oa,requiredSymbol:ia,contentOnly:la,disabled:ca,labelText:ua,hasErrors:da},Ot=({checked:e=!1,disabled:t=!1,required:n=!1,requiredGroup:a=!1,id:r,name:s="",onChange:c,contentOnly:u=!1,hasErrors:o=!1,checkmarkCharacter:l="✔",tabIndex:d=0,children:_,"aria-controls":h,"aria-describedby":y})=>{const m=[le.checkBoxInput,u&&le.contentOnly,t&&le.disabled,o&&le.hasErrors].filter(Boolean).join(" "),v={checked:e,disabled:t,showBox:!u,hasErrors:u&&o,checkmarkCharacter:l},k={id:r,name:s,type:"checkbox",checked:e,disabled:t,required:n||a,onChange:c,tabIndex:d,"aria-controls":h,"aria-invalid":o?"true":void 0,"aria-describedby":y};return i.jsxs("label",{htmlFor:r,className:m,children:[u?i.jsx(Ye,{...v}):i.jsxs(i.Fragment,{children:[i.jsx(Ye,{...v}),i.jsx("input",{...k})]}),i.jsxs("span",{className:le.labelText,children:[_,n&&i.jsx("img",{src:re,alt:"",className:le.requiredSymbol})]})]})},ha="_checkBoxList_1sp8d_1",ma="_requiredSymbol_1sp8d_16",ft={checkBoxList:ha,requiredSymbol:ma},fa="_headerContainer_t2si7_1",pa="_header_t2si7_1",_a="_bigHeader_t2si7_16",je={headerContainer:fa,header:pa,"size-1":"_size-1_t2si7_8",bigHeader:_a,"size-2":"_size-2_t2si7_28","size-3":"_size-3_t2si7_36","size-4":"_size-4_t2si7_44","size-5":"_size-5_t2si7_52"},at=({id:e,content:t,size:n=1,big:a,label:r,htmlTag:s,htmlFor:c,children:u})=>{const o=s||`h${n}`,l=T([je.header,je[`size-${n}`],a&&je.bigHeader]),d=r!=null&&r.length&&typeof r=="string"?{"--label":`"${r}"`}:void 0,_=b.createElement(o,{className:l,id:e||void 0,htmlFor:c||void 0,style:d},t!=null&&t.length?t:u);return i.jsx("div",{className:je.headerContainer,children:_})},qt=({legend:e,legendSize:t,required:n=!1,compact:a=!1,children:r})=>{const s=c=>pe(c).map((o,l)=>{var d;return b.isValidElement(o)&&((d=o.type)==null?void 0:d.displayName)==="RadioButtonListItem"?b.cloneElement(o,{requiredGroup:n,compact:a,key:`checkboxListItem-${l}`}):o});return i.jsxs("fieldset",{className:ft.checkBoxList,children:[!!(e!=null&&e.length)&&i.jsxs("legend",{children:[t?i.jsx(at,{size:t,children:e}):e,n&&i.jsx("img",{src:re,alt:"",className:ft.requiredSymbol})]}),s(b.Children.toArray(r))]})},ga="_checkBoxListItem_jnb8z_1",va="_contentOnly_jnb8z_26",ya="_compact_jnb8z_26",xa="_disabled_jnb8z_41",ba="_checked_jnb8z_44",ce={checkBoxListItem:ga,contentOnly:va,compact:ya,disabled:xa,checked:ba},Vt=({checked:e=!1,disabled:t=!1,required:n=!1,requiredGroup:a=!1,id:r,name:s="",onChange:c,contentOnly:u=!1,compact:o=!1,hasErrors:l=!1,checkmarkCharacter:d="✔","aria-controls":_,"aria-describedby":h,children:y})=>{const m=T([ce.checkBoxListItem,e&&ce.checked,t&&ce.disabled,o&&ce.compact,u&&ce.contentOnly,l&&ce.hasErrors]),v={onChange:c??(()=>{}),checked:e,disabled:t,required:n,requiredGroup:a,contentOnly:u,hasErrors:l,"aria-controls":_,"aria-describedby":h,id:r,name:s,checkmarkCharacter:d};return i.jsx("div",{className:m,children:i.jsx(Ot,{...v,children:y})})},wa="_container_f8z49_1",Ea={container:wa},Ht=({maxWidth:e,children:t})=>{const n={"--max-width":e!=null&&e.length?e:void 0};return i.jsx("div",{className:Ea.container,style:n,children:t})},Ca="_contentBox_1ndvc_1",ka="_link_1ndvc_8",La="_content_1ndvc_1",Sa="_title_1ndvc_25",ja="_secondary_1ndvc_28",$a="_regular_1ndvc_36",Ia="_large_1ndvc_45",ue={contentBox:Ca,link:ka,default:"_default_1ndvc_21",content:La,title:Sa,secondary:ja,regular:$a,large:Ia},Ra=({title:e=null,titleSize:t="regular",content:n="",children:a,color:r="default",href:s=null})=>{const c=()=>{if(!e)return null;const h=`${ue.title} ${ue[t]}`;return i.jsx("h2",{className:h,children:e})},u=ue[r]||"",o=s?ue.link:"",l=`${ue.contentBox} ${u} ${o}`.trim(),d=n!=null&&n.length?n:a,_=i.jsxs(i.Fragment,{children:[c(),i.jsx("div",{className:ue.content,children:d})]});return s?i.jsx("a",{href:s,className:l,children:_}):i.jsx("div",{className:l,children:_})},Ma="_descriptionDetails_1d1dj_1",Na="_compact_1d1dj_7",pt={descriptionDetails:Ma,compact:Na},za=({compact:e=!1,titleWidth:t,children:n})=>i.jsx("dd",{className:T([pt.descriptionDetails,e&&pt.compact]),style:{"--title-width":t||void 0},children:n}),Ta="_descriptionList_w11ua_1",Ba="_compact_w11ua_13",_t={descriptionList:Ta,compact:Ba},Pa=({compact:e=!1,titleWidth:t,children:n})=>{const a=r=>pe(r).map((c,u)=>b.isValidElement(c)?b.cloneElement(c,{compact:e,titleWidth:t,key:`descriptionListItem-${u}`}):c);return b.createElement("dl",{className:T([_t.descriptionList,e&&_t.compact]),style:{"--title-width":t||void 0}},a(b.Children.toArray(n)))},Da="_descriptionTerm_uuapd_1",Aa="_compact_uuapd_8",gt={descriptionTerm:Da,compact:Aa},Fa=({compact:e=!1,titleWidth:t,children:n})=>i.jsx("dt",{className:T([gt.descriptionTerm,e&>.compact]),style:{"--title-width":t||void 0},children:n}),Oa="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",qa="_dialog_1qsqp_19",Va="_dialogContainer_1qsqp_33",Ha="_dialogContent_1qsqp_38",Xa="_closeButton_1qsqp_45",Wa="_isSidebar_1qsqp_60",Ua="_modalInVertical_1qsqp_1",Ya="_noPadding_1qsqp_74",Ja="_left_1qsqp_113",Ga="_modalInHorizontalLeft_1qsqp_1",Ka="_right_1qsqp_120",Za="_modalInHorizontalRight_1qsqp_1",Qa="_dialogOverlay_1qsqp_128",te={dialog:qa,dialogContainer:Va,dialogContent:Ha,closeButton:Xa,isSidebar:Wa,modalInVertical:Ua,noPadding:Ya,left:Ja,modalInHorizontalLeft:Ga,right:Ka,modalInHorizontalRight:Za,dialogOverlay:Qa},es=({maxWidth:e="none",noPadding:t,closeButton:n,onClickOutside:a,modal:r=!1,attachTo:s,hidden:c=!1,children:u})=>{const o=b.useRef(null),l=b.useRef(null),d=b.useCallback(y=>{y&&kt(y)},[]);b.useEffect(()=>{const y=v=>{v.key==="Escape"&&a&&a()},m=v=>{l.current&&!l.current.contains(v.target)&&a()};return document.addEventListener("mousedown",m),document.addEventListener("keydown",y,!1),()=>{document.removeEventListener("mousedown",m),document.removeEventListener("keydown",y,!1)}},[a]),b.useEffect(()=>{o.current&&(o.current.close(),c||(r?o.current.showModal():o.current.show()))},[c,r]);const _=s&&T([te.isSidebar,te[s]]),h={"--max-width":e};return i.jsx("dialog",{className:T([te.dialog,_]),ref:o,children:i.jsx("div",{ref:l,className:te.dialogContainer,style:h,children:i.jsxs("div",{ref:d,className:T([te.dialogContent,t&&te.noPadding]),children:[n&&i.jsx("button",{"aria-label":"Lukk dialog",onClick:a,className:T([te.closeButton,t&&te.noPadding]),children:i.jsx("img",{src:Oa,alt:""})}),i.jsx("div",{"aria-live":"assertive",role:"dialog",children:u})]})})})},ts="_label_18de6_1",ns="_inline_18de6_11",rs="_normalCursor_18de6_14",qe={label:ts,inline:ns,normalCursor:rs},fe=({inline:e=!1,normalCursor:t=!1,htmlTag:n="label",children:a,id:r,...s})=>{const c=[qe.label,e&&qe.inline,t&&qe.normalCursor].filter(Boolean).join(" "),u={...s,className:c,id:r||void 0};return b.createElement(n,u,a)},as="_dragAndDropFileInput_l98z1_1",ss="_requiredSymbol_l98z1_1",os="_dragAndDropContainer_l98z1_8",is="_highlighted_l98z1_26",$e={dragAndDropFileInput:as,requiredSymbol:ss,dragAndDropContainer:os,highlighted:is},ls="_errorMessage_i8u6b_7",cs="_errorSign_i8u6b_19",vt={errorMessage:ls,errorSign:cs},us="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",Ce=({id:e,content:t=""})=>{const n=()=>({id:e!=null&&e.length?e:void 0,className:vt.errorMessage});return(typeof t=="string"?t.trim().length>0:!!t)?i.jsxs("span",{"aria-live":"polite",...n(),children:[i.jsx("img",{src:us,alt:"",className:vt.errorSign}),t]}):null},ds=({id:e,name:t,onSelectChange:n,onDragAndDropChange:a,label:r="",contentOnly:s=!1,buttonColor:c="primary",buttonContent:u,buttonContentWhenSelectedFile:o,selectedFileName:l,defaultContent:d="",hasErrors:_=!1,errorMessage:h="",required:y=!1,children:m,"data-transaction-name":v})=>{const[k,f]=b.useState(!1),x=b.useRef(null),E=b.useRef(null),w=j=>{j.preventDefault(),j.stopPropagation()},$=(j,C)=>j||C,I=()=>{var j;(j=E.current)==null||j.click()},R=()=>`${e}-errorMessage`,S={id:e,"aria-describedby":_&&(h!=null&&h.toString().length)?R():void 0,"aria-invalid":_?"true":void 0,name:t,required:y},M=l&&o||u,D=b.useCallback(()=>f(!0),[]),V=b.useCallback(()=>f(!1),[]),H=b.useCallback(j=>{var C;w(j),(C=j.dataTransfer)!=null&&C.files&&a(j.dataTransfer.files),f(!1)},[a]);return b.useEffect(()=>{const j=x.current;if(j)return["dragenter","dragover"].forEach(C=>j.addEventListener(C,D)),["dragleave","drop"].forEach(C=>j.addEventListener(C,V)),["dragenter","dragover","dragleave","drop"].forEach(C=>j.addEventListener(C,w)),j.addEventListener("drop",H),()=>{["dragenter","dragover","dragleave","drop"].forEach(C=>{j.removeEventListener(C,w),j.removeEventListener(C,D),j.removeEventListener(C,V)}),j.removeEventListener("drop",H)}},[a]),i.jsxs("div",{className:$e.dragAndDropFileInput,children:[i.jsxs(fe,{htmlFor:e,children:[r,y&&i.jsx("img",{src:re,alt:"",className:$e.requiredSymbol})]}),i.jsx("div",{children:m}),!s&&i.jsxs("div",{ref:x,className:`${$e.dragAndDropContainer} ${k?$e.highlighted:""}`,children:[l?i.jsx("div",{children:i.jsxs("span",{children:[i.jsx("b",{children:"Valgt fil:"})," ",l]})}):i.jsx("div",{children:"Slipp fil her"}),i.jsx("input",{...S,ref:E,type:"file",onChange:n}),u&&i.jsxs(i.Fragment,{children:[i.jsx("div",{children:l?"":"eller klikk på knappen for å velge fil"}),i.jsx(rt,{size:"small",inputType:"button",color:c,onClick:I,content:M,hasErrors:_,"data-transaction-name":v})]})]}),s&&i.jsx("span",{children:$(l,d)}),i.jsx(Ce,{id:R(),content:h})]})},hs="_errorBoxContainer_88ulw_7",ms="_messageIn_88ulw_1",fs="_warning_88ulw_14",ps="_error_88ulw_7",_s="_fullScreen_88ulw_22",gs="_errorBox_88ulw_7",vs="_infoSign_88ulw_38",de={errorBoxContainer:hs,messageIn:ms,warning:fs,error:ps,fullScreen:_s,errorBox:gs,infoSign:vs},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",ys=({type:e="warning",fullScreen:t=!1,children:n=""})=>i.jsx("div",{className:T([de.errorBoxContainer,de[e],t&&de.fullScreen]),children:i.jsxs("div",{className:T([de.errorBox,t&&de.fullScreen]),children:[i.jsx("img",{src:Xt,alt:"",className:de.infoSign}),n]})}),xs="_footer_19fad_1",bs={footer:xs},ws=({children:e})=>i.jsx("footer",{className:bs.footer,children:i.jsx(Ht,{children:e})}),Es="_infoBox_1mh67_7",Cs="_infoSign_1mh67_15",yt={infoBox:Es,infoSign:Cs},ks=({children:e=""})=>i.jsxs("div",{className:yt.infoBox,children:[i.jsx("img",{src:Xt,alt:"",className:yt.infoSign}),e]}),Ls="_inputField_17rmz_1",Ss="_noMargin_17rmz_4",js="_requiredSymbol_17rmz_10",$s="_file_17rmz_17",Is="_input_17rmz_1",Rs="_hasErrors_17rmz_50",Ms="_fileInputContainer_17rmz_62",ae={inputField:Ls,noMargin:Ss,requiredSymbol:js,file:$s,input:Is,hasErrors:Rs,fileInputContainer:Ms},st=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},Ns=({id:e,onChange:t,onBlur:n,name:a="",type:r="text",disabled:s=!1,required:c=!1,readOnly:u,width:o,value:l,defaultValue:d,elementKey:_,label:h="",contentOnly:y=!1,buttonColor:m="primary",buttonContent:v,selectedFileName:k,placeholder:f="",defaultContent:x="",min:E,max:w,role:$,"aria-describedby":I,"aria-autocomplete":R,hasErrors:S=!1,errorMessage:M="",noMargin:D=!1})=>{const V=N=>{const B=new Date(N);return`${String(B.getDate()).padStart(2,"0")}.${String(B.getMonth()+1).padStart(2,"0")}.${B.getFullYear()}`},H=(N,B)=>r==="date"?N?V(N):B:N||B,j=()=>`${e}-errorMessage`,C=o?{maxWidth:o}:{},F={name:a,readOnly:u,disabled:s,required:c,type:r,role:$,id:e,min:E,max:w,onChange:t,onBlur:n,...l!==void 0?{value:l}:d!==void 0?{defaultValue:d}:{},placeholder:f,className:S?ae.hasErrors:void 0,"aria-describedby":S&&M?j():I,"aria-invalid":S?"true":void 0,"aria-autocomplete":R||void 0,style:C};return i.jsxs("div",{className:T([ae.inputField,ae[r],D&&ae.noMargin]),children:[i.jsxs(fe,{htmlFor:e,children:[h,c&&i.jsx("img",{src:re,alt:"",className:ae.requiredSymbol}),r==="file"&&i.jsxs("div",{className:ae.fileInputContainer,children:[i.jsx("span",{className:ae.input,children:k}),v&&i.jsx(rt,{color:m,inputType:"button",onClick:()=>{const N=document==null?void 0:document.getElementById(e);N==null||N.click()},content:v})]})]}),y?i.jsx("span",{children:H(l??d,x)}):i.jsx("input",{...F},_||`${e}-${st(6)}`),i.jsx(Ce,{id:j(),content:M})]})},zs="_lead_176gy_1",Ts={lead:zs},Bs=({id:e,htmlTag:t="p",children:n})=>b.createElement(t,{className:Ts.lead,id:e||void 0},n),Ps="_list_16gsl_1",Ds="_compact_16gsl_10",xt={list:Ps,compact:Ds},As=({listStyle:e,compact:t=!1,ordered:n=!1,children:a})=>{const r=o=>pe(o).map((d,_)=>b.isValidElement(d)?b.cloneElement(d,{compact:t,key:`listItem-${_}`}):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)))},Fs="_listItem_33xs0_1",Os="_compact_33xs0_5",bt={listItem:Fs,compact:Os},qs=({compact:e=!1,children:t})=>{const n=T([bt.listItem,e&&bt.compact]);return i.jsx("li",{className:n,children:t})},Vs="_loadingAnimation_hzd5u_1",Hs="_fixed_hzd5u_17",Ve={loadingAnimation:Vs,fixed:Hs},Xs=({fixed:e=!1,message:t=""})=>{const n=e?`${Ve.loadingAnimation} ${Ve.fixed}`:Ve.loadingAnimation;return i.jsx("div",{className:n,children:t})},Je=({listItem:e})=>typeof e=="string"?i.jsx("li",{children:i.jsx("span",{children:e})}):typeof e=="object"?i.jsx("li",{children:i.jsx("a",{href:e.href,children:e.name})}):null,Ws="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",Us="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",Ys="_navigationBarContainer_n1cc0_1",Js="_mainContentLink_n1cc0_1",Gs="_compact_n1cc0_30",Ks="_navigationBar_n1cc0_1",Zs="_preventStacking_n1cc0_63",Qs="_logoContainer_n1cc0_82",eo="_childElements_n1cc0_91",to="_menuToggle_n1cc0_97",no="_hamburgerIcon_n1cc0_125",ro="_active_n1cc0_161",ao="_dropdownContainer_n1cc0_170",so="_dropdown_n1cc0_170",oo="_primaryList_n1cc0_195",io="_secondaryList_n1cc0_196",lo="_line_n1cc0_392",P={navigationBarContainer:Ys,mainContentLink:Js,compact:Gs,navigationBar:Ks,preventStacking:Zs,logoContainer:Qs,childElements:eo,menuToggle:to,hamburgerIcon:no,active:ro,dropdownContainer:ao,dropdown:so,primaryList:oo,secondaryList:io,line:lo},co=e=>(e==null?void 0:e.logo)??"",uo=e=>(e==null?void 0:e.logoPadding)??"",ho=e=>(e==null?void 0:e.appName)??"",mo=({primaryListItems:e=[],secondaryListItems:t=[],logoLink:n="",logoLinkTitle:a,openLogoLinkInNewTab:r,theme:s,compact:c,mainContentId:u,preventChildElementStacking:o=!1,children:l})=>{const[d,_]=b.useState(!1),h=()=>_(!d),y=x=>({padding:uo(x)}),m=(x=e,E=0)=>x.length?i.jsx("ul",{className:P.primaryList,children:x.map((w,$)=>{const I=`${E}-${$}`;return w.listItems?i.jsxs("li",{children:[i.jsx("span",{children:w.name}),m(w.listItems,E+1)]},I):i.jsx(Je,{listItem:w},I)})}):null,v=()=>t.length?i.jsx("ul",{className:P.secondaryList,children:t.map((x,E)=>i.jsx(Je,{listItem:x},E))}):null,k=(x,E)=>{const w=co(s),$=ho(s),I=x&&E?"":w&&$?`${$} logo`:"DIBK logo",R=w?i.jsx("img",{alt:I,src:w,style:y(s)}):i.jsx("img",{alt:I,src:c?Ws:Us});return x!=null&&x.length?i.jsx("a",{href:x,title:E,target:r?"_blank":void 0,rel:r?"noopener noreferrer":void 0,children:R}):R},f=e.length>0||t.length>0;return i.jsxs("div",{className:T([c&&P.compact,P.navigationBarContainer]),children:[u&&i.jsx("a",{id:"main-content-link",href:`#${u}`,className:P.mainContentLink,children:i.jsx("span",{id:"main-content-link-text",children:"Hopp til hovedinnhold"})}),i.jsxs("div",{className:T([P.navigationBar,o&&P.preventStacking]),children:[i.jsx("div",{className:P.logoContainer,children:k(n,a)}),l&&i.jsx("div",{className:P.childElements,children:l}),f&&i.jsxs("button",{type:"button",className:`${P.menuToggle} ${d?P.active:""}`,onClick:h,"aria-expanded":d?"true":"false","aria-controls":"main-menu-dropdown",children:[!c&&"Meny",i.jsxs("span",{className:P.hamburgerIcon,children:[i.jsx("span",{className:P.line}),i.jsx("span",{className:P.line}),i.jsx("span",{className:P.line})]})]})]}),f&&i.jsx(b.Fragment,{children:i.jsx("div",{className:T([P.dropdownContainer,d&&P.active]),children:i.jsxs("div",{id:"main-menu-dropdown",className:P.dropdown,children:[m(),v()]})})})]})},fo="_paper_1lgl3_1",po="_noMargin_1lgl3_6",_o="_noPadding_1lgl3_9",He={paper:fo,noMargin:po,noPadding:_o},go=({noMargin:e=!1,noPadding:t=!1,children:n})=>{const a=[He.paper,e&&He.noMargin,t&&He.noPadding].filter(Boolean).join(" ");return i.jsx("div",{className:a,children:n})},vo="_progressBar_t5aid_1",yo="_hasErrors_t5aid_23",wt={progressBar:vo,hasErrors:yo},xo=({progress:e=0,hasErrors:t=!1})=>i.jsx("div",{className:`${wt.progressBar} ${t?wt.hasErrors:""}`,role:"progressbar","aria-valuenow":e,"aria-valuemin":0,"aria-valuemax":100,style:{"--value":e}}),bo="_radioButtonIcon_32fe0_1",wo="_hasErrors_32fe0_22",Eo="_checked_32fe0_32",Co="_disabled_32fe0_48",Ie={radioButtonIcon:bo,hasErrors:wo,checked:Eo,disabled:Co},Wt=({size:e="10px",checked:t=!1,disabled:n=!1,hasErrors:a=!1})=>{const r={height:e,width:e},s=[Ie.radioButtonIcon,t&&Ie.checked,n&&Ie.disabled,a&&Ie.hasErrors].filter(Boolean).join(" ");return i.jsx("span",{className:s,style:r})},ko="_radioButtonInput_1i7cy_1",Lo="_requiredSymbol_1i7cy_6",So="_disabled_1i7cy_13",jo="_labelText_1i7cy_19",$o="_hasErrors_1i7cy_27",he={radioButtonInput:ko,requiredSymbol:Lo,disabled:So,labelText:jo,hasErrors:$o},Ut=({checked:e=!1,disabled:t=!1,required:n=!1,requiredGroup:a=!1,id:r,name:s="",onChange:c,contentOnly:u=!1,hasErrors:o=!1,inputValue:l,tabIndex:d,children:_,"aria-controls":h,"aria-describedby":y})=>{const m=[he.radioButtonInput,e&&he.checked,t&&he.disabled,o&&he.hasErrors].filter(Boolean).join(" "),v={checked:e,disabled:t,hasErrors:!u&&o},k={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":o?"true":void 0,"aria-describedby":y};return i.jsxs("label",{htmlFor:r,className:m,children:[!u&&i.jsxs(i.Fragment,{children:[i.jsx(Wt,{...v}),i.jsx("input",{...k})]}),i.jsxs("span",{className:he.labelText,children:[_,n&&i.jsx("img",{src:re,alt:"",className:he.requiredSymbol})]})]})},Io="_radioButtonList_1cyu3_1",Ro="_requiredSymbol_1cyu3_16",Et={radioButtonList:Io,requiredSymbol:Ro},Mo=({legend:e,legendSize:t,required:n=!1,compact:a=!1,children:r})=>{const s=c=>pe(c).map((o,l)=>{var d;return b.isValidElement(o)&&((d=o.type)==null?void 0:d.displayName)==="RadioButtonListItem"?b.cloneElement(o,{requiredGroup:n,compact:a,key:`radioButtonListItem-${l}`}):o});return i.jsxs("fieldset",{className:Et.radioButtonList,children:[!!(e!=null&&e.length)&&i.jsxs("legend",{children:[t?i.jsx(at,{size:t,children:e}):e,n&&i.jsx("img",{src:re,alt:"",className:Et.requiredSymbol})]}),s(b.Children.toArray(r))]})},No="_radioButtonListItem_1ggab_1",zo="_contentOnly_1ggab_26",To="_compact_1ggab_26",Bo="_disabled_1ggab_41",Po="_checked_1ggab_44",me={radioButtonListItem:No,contentOnly:zo,compact:To,disabled:Bo,checked:Po},Do=({inputValue:e,checked:t=!1,disabled:n=!1,required:a=!1,requiredGroup:r=!1,name:s="",id:c,onChange:u,contentOnly:o=!1,compact:l=!1,hasErrors:d=!1,"aria-controls":_,"aria-describedby":h,children:y})=>{const m=T([me.radioButtonListItem,t&&me.checked,n&&me.disabled,l&&me.compact,o&&me.contentOnly,d&&me.hasErrors]),v={onChange:u,inputValue:e,checked:t,disabled:n,required:a,requiredGroup:r,contentOnly:o,hasErrors:d,"aria-controls":_,"aria-describedby":h,id:c,name:s};return i.jsx("div",{className:m,children:i.jsx(Ut,{...v,children:y})})},Ao="_select_18o2z_1",Fo="_requiredSymbol_18o2z_1",Oo="_selectContainer_18o2z_8",qo="_selectListArrow_18o2z_11",Vo="_multipleSelectDropdown_18o2z_40",Ho="_multipleSelectElement_18o2z_52",Xo="_multiple_18o2z_40",Wo="_hasErrors_18o2z_100",J={select:Ao,requiredSymbol:Fo,selectContainer:Oo,selectListArrow:qo,multipleSelectDropdown:Vo,multipleSelectElement:Ho,multiple:Xo,hasErrors:Wo},Uo=({id:e,onChange:t,name:n="",required:a=!1,disabled:r=!1,multiple:s=!1,options:c=[],width:u,value:o,defaultValue:l,label:d="",contentOnly:_=!1,keyAsContent:h=!1,placeholder:y="",placeholderValue:m="",defaultContent:v="",role:k,"aria-describedby":f,hasErrors:x=!1,errorMessage:E=""})=>{const[w,$]=b.useState(!1),I=b.useRef(null);b.useCallback(C=>{C&&kt(C)},[]);const R=()=>$(!1);b.useEffect(()=>{const C=N=>{N.key==="Escape"&&R()},F=N=>{I.current&&!I.current.contains(N.target)&&R()};return document.addEventListener("mousedown",F),document.addEventListener("keydown",C),()=>{document.removeEventListener("mousedown",F),document.removeEventListener("keydown",C)}},[]);const S=(C,F)=>{const N=F.find(B=>typeof B=="object"?B.value===C:B===C);return typeof N=="object"?N.key??N.value:N},M=C=>typeof C=="object"?{key:C.key,value:C.value}:{key:C,value:C},D=()=>{var C;return((C=l||o)==null?void 0:C.map(F=>S(F,c)).join(", "))||null},V=()=>c.map((C,F)=>{const{key:N,value:B}=M(C),ke=(l||o||[]).includes(B);return i.jsx(Vt,{id:`${e}-${F}`,value:B,checked:ke,onChange:()=>t(B),children:N},F)}),H=()=>`${e}-errorMessage`;if(_){const C=l||o||null;return i.jsxs("div",{className:J.select,children:[i.jsx(fe,{htmlFor:e,children:d}),i.jsx("span",{children:C?h?S(C,c):C:v})]})}const j={name:n,multiple:s,required:a,disabled:r,onChange:t,id:e,role:k,className:T([x&&J.hasErrors,s&&J.multiple]),"aria-describedby":x&&E?H():f,"aria-invalid":x||void 0,style:u?{maxWidth:u}:void 0,...l&&!o?{defaultValue:l}:{value:o||""}};return i.jsxs("div",{className:J.select,children:[i.jsxs(fe,{htmlFor:e,children:[d,a&&i.jsx("img",{src:re,alt:"",className:J.requiredSymbol})]}),i.jsxs("div",{className:J.selectContainer,style:u?{maxWidth:u}:void 0,children:[i.jsx("span",{className:J.selectListArrow}),s?i.jsxs("div",{ref:I,children:[i.jsx("div",{onClick:()=>$(!w),className:J.multipleSelectElement,children:D()}),w&&i.jsx("div",{className:J.multipleSelectDropdown,children:i.jsx(qt,{compact:!0,children:V()})})]}):i.jsxs("select",{...j,children:[y&&i.jsx("option",{value:m,disabled:!0,children:y}),c.map((C,F)=>{const{key:N,value:B}=M(C);return i.jsx("option",{value:B,children:N},F)})]},`${e}-${st(6)}`)]}),i.jsx(Ce,{id:H(),content:E})]})},Yo="_table_miy9l_1",we={table:Yo,"captionSide-top":"_captionSide-top_miy9l_14","captionSide-bottom":"_captionSide-bottom_miy9l_18","captionAlign-left":"_captionAlign-left_miy9l_22","captionAlign-center":"_captionAlign-center_miy9l_25","captionAlign-right":"_captionAlign-right_miy9l_28"},Jo=e=>e&&["left","center","right"].includes(e)?we[`captionAlign-${e}`]:we["captionAlign-left"],Go=e=>e&&["top","bottom"].includes(e)?we[`captionSide-${e}`]:we["captionSide-top"],Ko=({captionAlign:e,captionSide:t,children:n})=>{const a=T([we.table,Jo(e),Go(t)]);return i.jsx("table",{className:a,children:n})},Zo="_textarea_1596u_1",Qo="_requiredSymbol_1596u_4",ei="_hasErrors_1596u_55",Xe={textarea:Zo,requiredSymbol:Qo,hasErrors:ei},ti=({id:e,onChange:t,onBlur:n,name:a="",required:r=!1,readOnly:s,disabled:c,width:u,resize:o="both",value:l,defaultValue:d,elementKey:_,rows:h,label:y="",contentOnly:m=!1,placeholder:v="",defaultContent:k="","aria-describedby":f,hasErrors:x=!1,errorMessage:E=""})=>{const w=()=>`${e}-errorMessage`,$=!(l!=null&&l.length)&&(d!=null&&d.length)?d:void 0,I=_||`${e}-${st(6)}`,R={...u&&{maxWidth:u},...o&&{resize:o}},S={name:a,readOnly:s,disabled:c,required:r,id:e,onChange:t,onBlur:n,value:$?void 0:l,defaultValue:$||void 0,placeholder:v,rows:h?parseInt(h,10):void 0,className:x?Xe.hasErrors:"","aria-describedby":x&&E?w():f,"aria-invalid":x?"true":void 0,style:R};return i.jsxs("div",{className:Xe.textarea,children:[i.jsxs(fe,{htmlFor:e,children:[y,r&&i.jsx("img",{src:re,alt:"",className:Xe.requiredSymbol})]}),m?i.jsx("span",{children:l||d||k}):i.jsx("textarea",{...S},I),i.jsx(Ce,{id:w(),content:E})]})},ni=({theme:e,children:t})=>{const n=nn(e),a=an(n);return rn("theme-provider",`:root {${a}}`),t},ri="_toggleNavigationButton_1eb2w_1",ai={toggleNavigationButton:ri},si=({id:e,htmlTag:t="button",showText:n,hideText:a,buttonProps:r={},isOpen:s=!1})=>b.createElement(t,{...r,className:ai.toggleNavigationButton,id:e||void 0},s?a:n),oi="_wizardTopnavItem_5ar16_1",ii="_wizardTopnavItemContent_5ar16_4",li="_vertical_5ar16_7",ci="_stepNumber_5ar16_24",ui="_stepName_5ar16_36",di="_active_5ar16_46",hi="_finished_5ar16_46",mi="_hasErrors_5ar16_46",fi="_horizontal_5ar16_64",Y={wizardTopnavItem:oi,wizardTopnavItemContent:ii,vertical:li,stepNumber:ci,stepName:ui,active:di,finished:hi,hasErrors:mi,horizontal:fi},pi="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=T([Y.wizardTopnavItem,r&&Y.active,e.finished&&Y.finished,e.hasErrors&&Y.hasErrors,Y[a]]),u=r?"step":void 0,o=()=>i.jsxs(i.Fragment,{children:[i.jsx("span",{className:Y.stepNumber,children:t+1}),i.jsx("span",{className:Y.stepName,children:e.name}),s&&e.finished&&!r&&i.jsx("img",{src:pi,alt:"",className:Y.checkmarkSymbol})]});return e.link&&Object.keys(e.link).length>0?i.jsx("li",{className:c,children:i.jsx(be,{to:e.link,"aria-current":u,className:Y.wizardTopnavItemContent,children:o()})}):i.jsx("li",{className:c,children:i.jsx("span",{"aria-current":u,className:Y.wizardTopnavItemContent,children:o()})})},_i="_wizardTopnavContainer_qiy2o_1",gi="_wizardTopnav_qiy2o_1",vi="_vertical_qiy2o_6",yi="_horizontal_qiy2o_11",We={wizardTopnavContainer:_i,wizardTopnav:gi,vertical:vi,horizontal:yi},xi=({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 i.jsx("nav",{"aria-label":u,className:T([We.wizardTopnavContainer,We[n]]),children:i.jsx("ol",{className:We.wizardTopnav,children:r.map((o,l)=>i.jsx(Yt,{step:e[o],activeStepId:t,direction:n,index:l},o))})})};exports.Accordion=bn;exports.Button=rt;exports.CheckBoxIcon=Ye;exports.CheckBoxInput=Ot;exports.CheckBoxList=qt;exports.CheckBoxListItem=Vt;exports.Container=Ht;exports.ContentBox=Ra;exports.DescriptionDetails=za;exports.DescriptionList=Pa;exports.DescriptionTerm=Fa;exports.Dialog=es;exports.DragAndDropFileInput=ds;exports.ErrorBox=ys;exports.ErrorMessage=Ce;exports.Footer=ws;exports.Header=at;exports.InfoBox=ks;exports.InputField=Ns;exports.Label=fe;exports.Lead=Bs;exports.List=As;exports.ListItem=qs;exports.LoadingAnimation=Xs;exports.NavigationBar=mo;exports.NavigationBarListItem=Je;exports.Paper=go;exports.ProgressBar=xo;exports.RadioButtonIcon=Wt;exports.RadioButtonInput=Ut;exports.RadioButtonList=Mo;exports.RadioButtonListItem=Do;exports.Select=Uo;exports.Table=Ko;exports.Textarea=ti;exports.ThemeProvider=ni;exports.ToggleNavigationButton=si;exports.WizardNavigation=xi;exports.WizardNavigationStep=Yt;
|
|
34
|
+
//# sourceMappingURL=index.cjs.js.map
|