PageSourceSearch

https://static.naf.no/static/pages-Article-Article.19532e2eee35c64a.js

js naf.no collected 2026-10-02 03:15:54 UTC 16,772 bytes, 12 lines download raw bytes

1"use strict";(self.__LOADABLE_LOADED_CHUNKS__=self.__LOADABLE_LOADED_CHUNKS__||[]).push([[7458],{48353(e,t,i){i.d(t,{A:()=>u});var r=i(11684),l=i(12888),a=i(84204),n=i(25187),s=i(84824),o=i(2422),d=i(69921),c=i(96757);let m=(0,c.A)("nav",{target:"eh2bgj00"})("margin-bottom:",a.YK.space32,";ul{padding-left:0;margin:0;li{list-style-type:none;margin-bottom:",a.YK.space8,";@media (max-width:",a.fi.m,"){margin-bottom:",a.YK.space16,";}&:last-child{margin-bottom:0;}}}@media (max-width:",a.fi.m,"){margin-bottom:",a.YK.space48,";}"),h=(0,c.A)("div",{target:"eh2bgj01"})("display:flex;align-items:center;h3,svg{margin-bottom:",a.YK.space8,";margin-top:0;@media (max-width:",a.fi.m,"){margin-bottom:",a.YK.space16,";}}svg{margin-right:",a.YK.space4,";}"),u=({tagType:e="h2",parentElement:t,title:i})=>{let c=(0,o.Zp)(),u=(0,o.zy)(),[p,g]=(0,l.useState)([]),x=(0,l.useCallback)(()=>{if("u">typeof window&&document){let i=Array.from((t?.current||document).getElementsByTagName(e));g(i=i.filter(e=>{let t=e.textContent?.trim();return e.id&&t&&t.length>0}))}},[t,e]);return((0,l.useEffect)(()=>{x()},[x]),p&&p.length>0)?(0,r.jsxs)(m,{"aria-label":"Innholdsfortegnelse",children:[(0,r.jsxs)(h,{children:[(0,r.jsx)(n.T,{size:a.Pt.m}),(0,r.jsx)(s.EY,{variant:s.J3.Header3,children:i||"I denne artikkelen"})]}),(0,r.jsx)("ul",{children:p.map(e=>{let t=e.innerText;return(0,r.jsx)("li",{children:(0,r.jsx)(d.N,{onClick:t=>{t.stopPropagation(),t.preventDefault(),c(`${u.pathname}#${e.id}`)},href:`${u.pathname}#${e.id}`,text:t,size:"medium"})},`toc-${e.id}`)})})]}):null}},23867(e,t,i){i.r(t),i.d(t,{default:()=>ek});var r=i(11684),l=i(12888),a=i(85587),n=i(84824),s=i(50616),o=i(19315),d=i(2422),c=i(49533),m=i(85191),h=i(78745),u=i(53002),p=i(71385),g=i(83584),x=i(47966),f=i(63807),j=i(96757),b=i(84204),w=i(69921),y=i(14005),v=i(13511);let A=({relatedLink:e})=>{let t=(0,v.YO)(e.referenceComponent)||"";return"link"===e.type&&e.href?e.blank?(0,r.jsx)(k,{children:(0,r.jsx)(w.N,{href:e.href,text:e.title,endIcon:y.h,target:"_blank",rel:"noopener noreferrer"})},`${e.href}-${e.type}`):(0,r.jsx)(k,{children:(0,r.jsx)(w.N,{href:e.href,text:e.title})},`${e.href}-${e.type}`):"internalLink"===e.type?e.referenceComponent&&e.referenceComponent?.type?(0,r.jsx)(k,{children:(0,r.jsx)(w.N,{to:t,text:e.title})},e.referenceComponent.slug):null:null},Y=({relatedLinks:e})=>e&&(0,r.jsx)($,{children:e.map(e=>(0,r.jsx)(A,{relatedLink:e},e?.referenceComponent?.id||e.href))})||null,$=(0,j.A)("ul",{target:"e1q1k8l0"})("padding:0;margin:0;"),k=(0,j.A)("li",{target:"e1q1k8l1"})("padding-bottom:",b.YK.space20,";list-style-type:none;");var C=i(31144),K=i(3487),T=i(53885),z=i(45746),D=i(48353),E=i(49393),L=i(26242),F=i(27674),P=i(82729),S=i(61932),U=i(57413),H=i(23727),q=i(90701);let _=(0,j.A)("div",{target:"ebyn16u0"})("max-width:400px;display:flex;align-items:center;"),R=(0,j.A)("div",{target:"ebyn16u1"})("border-radius:",b.Vq.S,";width:",b.YK.space20,";height:",b.YK.space20,";display:flex;justify-content:center;align-items:center;color:",U.nafColor.signature.black,";background-color:",({$isEligible:e})=>e?H.Tj.secondary["300"]:U.nafColor.signature.yellow,";"),N=(0,j.A)("div",{target:"ebyn16u2"})("display:flex;align-items:center;margin-left:",b.YK.space4,";padding:3px ",b.YK.space4,";border:1px solid ",S.ef.border.default,";border-radius:",b.Vq.M,";"),B=(0,j.A)(n.EY,{shouldForwardProp:q.r,target:"ebyn16u3"})(({$inverted:e})=>e&&(0,P.AH)("color:",U.nafColor.signature.white,";")),M=({labelText:e="NAF-Medlem",isEligible:t=!1,inverted:i=!1,className:l})=>(0,r.jsxs)(_,{className:l,children:[(0,r.jsx)(R,{$isEligible:t,children:t?(0,r.jsx)(L.J,{size:16}):(0,r.jsx)(F.O,{size:16})}),(0,r.jsx)(N,{children:(0,r.jsx)(B,{$inverted:i,variant:n.J3.TagSmall,children:e})})]});var I=i(63771),J=i(48009);let O=(0,j.A)(n.EY,{target:"ep6lswz0"})("margin:0;line-height:normal;@media (max-width:",b.fi.m,"){font-size:1rem;}"),X=(0,j.A)(J.v,{target:"ep6lswz1"})("position:absolute;top:-",b.YK.space24,";left:0;white-space:nowrap;"),W=(0,j.A)("img",{target:"ep6lswz2"})("margin-right:",b.YK.space16,";width:",({$size:e})=>"small"===e?"140px":"160px",";height:",({$size:e})=>"small"===e?"100px":"120px",";border-radius:",b.Vq.S,";"),V=(0,j.A)("div",{target:"ep6lswz3"})("position:relative;z-index:1;"),G=(0,j.A)("div",{target:"ep6lswz4"})("display:flex;flex-direction:column;"),Z=(0,j.A)(n.EY,{target:"ep6lswz5"})("margin-top:",b.YK.space8,";@media (max-width:",b.fi.s,"){display:none;}"),Q=(0,j.A)(d.N_,{shouldForwardProp:q.r,target:"ep6lswz6"})("display:flex;padding:",b.YK.space16,";text-decoration:none;border-radius:",b.Vq.L,";scroll-snap-align:start;scroll-margin-left:16px;scroll-margin-right:16px;",({$layout:e})=>"horizontal"===e?`
2        flex: 0 0 auto;
3        width: clamp(260px, 80vw, 340px);
4        margin-right: ${b.YK.space16};
5        margin-top: ${b.YK.space8};
6      `:`
7        width: 100%;
8        margin-top: ${b.YK.space8};
9        margin-bottom: ${b.YK.space8};
10        box-sizing: border-box;
11      `," ",({$isActive:e})=>e&&`background-color: ${S.ef.background.brand};`," ",({$showBorder:e,$isActive:t,$layout:i})=>e&&!t&&"horizontal"===i&&`border: 1px solid ${U.nafColor.neutral.neutral2};`,"  @media (max-width:",b.fi.m,"){",({$isActive:e})=>!e&&`border: 1px solid ${U.nafColor.neutral.neutral2};`,"}"),ee=(0,l.forwardRef)(({article:e,size:t="small",showBorder:i=!1,layout:l="horizontal"},a)=>{let{getResponsiveImage:s}=(0,I.C)(),o=(0,v.YO)(e),d=s(e.image?.publicId,{quality:"auto:low",focusMethod:e.image?.focus,width:"small"===t?200:250,height:"small"===t?133:167});return(0,r.jsxs)(Q,{$isActive:e.isActive,$showBorder:i,$layout:l,ref:a,to:o,children:[(0,r.jsxs)(V,{children:[e.isActive&&(0,r.jsx)(X,{text:"Du leser n\xe5",color:"secondary"}),(0,r.jsx)(W,{src:d?.toURL()||"",alt:e.image?.alt||e.image?.altText,$size:t}),e.paywallDetails&&(0,r.jsx)(M,{labelText:e?.paywallDetails?.labelText||"For medlemmer",isEligible:e?.paywallDetails?.isAccessibleForUser})]}),(0,r.jsxs)(G,{children:[(0,r.jsx)(O,{variant:n.J3.ArticleTextHeader,children:`Del ${e.step}: ${e.name}`}),"large"===t&&(0,r.jsx)(Z,{children:e.ingress})]})]})});var et=i(71261),ei=i(43251),er=i(59993),el=i(39855);let ea=(0,j.A)(n.EY,{target:"e1i9qlc00"})("margin:0;grid-column:3 / -3;@media (max-width:",b.fi.m,"){grid-column:1 / -1;}"),en=(0,j.A)("div",{target:"e1i9qlc01"})("position:relative;display:flex;align-items:center;grid-column:2 / -2;margin-bottom:",b.YK.space16,";@media (max-width:",b.fi.m,"){grid-column:1 / -1;}:before{@media (max-width:",b.fi.m,"){content:'';position:absolute;top:0;left:0;width:24px;height:100%;z-index:2;}}:after{@media (max-width:",b.fi.m,"){content:'';position:absolute;top:0;right:0;width:24px;height:100%;z-index:2;}}@media (max-width:",b.fi.m,"){margin-left:-",b.YK.space32,";margin-right:-",b.YK.space32,";}"),es=(0,j.A)("div",{target:"e1i9qlc02"})("height:100%;width:100%;overflow-x:scroll;scroll-snap-type:x mandatory;padding-left:",b.YK.space16,";padding-right:",b.YK.space16,";padding-top:",b.YK.space16,";@media (min-width:",b.fi.m,"){margin-left:",b.YK.space48,";margin-right:",b.YK.space48,";}::-webkit-scrollbar{display:none;}-ms-overflow-style:none;scrollbar-width:none;"),eo=(0,j.A)("div",{target:"e1i9qlc03"})("display:flex;width:fit-content;"),ed=(0,j.A)(el.K0,{target:"e1i9qlc04"})("@media (max-width:",b.fi.m,"){display:none;}position:absolute;
11left:0;z-index:3;"),ec=(0,j.A)(el.K0,{target:"e1i9qlc05"})("@media (max-width:",b.fi.m,"){display:none;}position:absolute;right:0;z-index:3;"),em=({direction:e,onClick:t,isDisabled:i})=>"left"===e?(0,r.jsx)(ed,{icon:et.h,color:(0,er.F)("secondary").color,variant:(0,er.F)("secondary").variant,"aria-label":"pil venstre",onClick:t,disabled:i}):(0,r.jsx)(ec,{icon:ei.h,color:(0,er.F)("secondary").color,variant:(0,er.F)("secondary").variant,"aria-label":"pil h\xf8yre",onClick:t,disabled:i}),eh=({articleSeries:{title:e,items:t}})=>{let i,a=(0,l.useRef)(null),s=(0,l.useRef)(null),{isScrolling:o,setIsScrolling:c,scrollPercent:m}=(e=>{let[t,i]=(0,l.useState)(0),[r,a]=(0,l.useState)(!1);return(0,l.useEffect)(()=>{let t,r,l=e.current;if(!l)return;let n=()=>{let e=l.scrollWidth-l.clientWidth;i(e>0?l.scrollLeft/e:0)},s=(...e)=>{r&&cancelAnimationFrame(r),r=requestAnimationFrame(()=>{n(...e)})},o=()=>{s(),clearTimeout(t),t=setTimeout(()=>{a(!1)},150)};return l.addEventListener("scroll",o,{passive:!0}),n(),()=>{l.removeEventListener("scroll",o),clearTimeout(t)}},[e]),{scrollPercent:t,isScrolling:r,setIsScrolling:a}})(a);i=(0,d.zy)(),(0,l.useEffect)(()=>{let e=s.current,t=a.current;e&&t&&t.clientWidth<e.offsetLeft+e.clientWidth&&(t.scrollLeft=e.offsetLeft)},[s,a,i.pathname]);let h=e=>{if(o||!a.current)return;let{scrollLeft:t,scrollWidth:i,clientWidth:r}=a.current,l=Math.ceil(t)>=i-r;if("left"===e&&0===t||"right"===e&&l)return;let n=a.current?.children[0];if(!n||!n.children.length)return;let s=n.children[0],d=parseFloat(window.getComputedStyle(s).marginRight),m=s.offsetWidth+d;c(!0),a.current.scrollBy({left:"left"===e?-m:m,behavior:"smooth"})};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(ea,{variant:n.J3.Header3,children:e}),(0,r.jsxs)(en,{children:[(0,r.jsx)(em,{direction:"left",onClick:()=>h("left"),isDisabled:o||0===m}),(0,r.jsx)(es,{ref:a,children:(0,r.jsx)(eo,{children:t.map(e=>(0,r.jsx)(ee,{article:e,ref:e.isActive?s:null,showBorder:!0,layout:"horizontal"},e.id))})}),(0,r.jsx)(em,{direction:"right",onClick:()=>h("right"),isDisabled:o||1===m})]})]})},eu=(0,j.A)("div",{target:"e11jv7ri0"})("display:flex;flex-direction:column;grid-column:2 / -2;margin-bottom:",b.YK.space32,";@media (max-width:",b.fi.m,"){grid-column:1 / -1;}"),ep=({articleSeries:e})=>{let{items:t}=e,i=t.findIndex(e=>e.isActive),l=-1===i?t:[...t.slice(i),...t.slice(0,i)];return(0,r.jsx)(eu,{children:l.map(e=>(0,r.jsx)(ee,{article:e,size:"large",showBorder:!0,layout:"vertical"},e.id))})};var eg=i(84883),ex=i(89130),ef=i(85918),ej=i(2354);let eb=(0,j.A)("div",{target:"e8u6kdg0"})("display:flex;flex-wrap:wrap;gap:",b.YK.space8,";"),ew=({tags:e,mappedCategories:t,category:i,articleUrl:l})=>{let a=(0,d.Zp)();return(0,r.jsx)(eb,{children:(0,r.jsx)(ej.mu,{children:e.map(e=>{let n=t[e.slug]?.data,s=n?.url||l;if(n?.isGlobalTag&&i){let e=(e=>{if(void 0===e||!e)return"";let t=e?.parent,i=`${e.slug}`;for(;t&&"nafno"!==t.slug&&t;)i=`${t.slug}`,t=t.parent;return i})(i);e&&(s=`/${e}/${n.slug}`)}return(0,r.jsx)(ej.vu,{label:e.name,variant:"outlined",color:"primary",onClick:()=>{a(s)}},`chip-${e.name}`)})})})};var ey=i(21062),ev=i(24365),eA=i(82933),eY=i(55521),e$=i(1074);let ek=({article:e})=>{let t=(0,s.V)(),i=(0,g.T)(),j=(0,d.zy)(),b=(0,u.n)();(0,o.A)(t,"Artikkel");let{name:w,runningHead:y,ingress:v,body:A,id:$,image:k,relatedContent:L,video:F,meta:P,seoConfig:S,tags:U,articleScore:H,relatedLinks:q,category:_,slug:R,metaDisplay:N,type:B,userAccessibility:M,tableOfContents:J,displayFeatureHeader:O,articleSeries:X,openGraphImage:W,routePoints:V,travelMode:G,youtubeVideo:Z,summary:Q}=e,{getProcessedImage:ee}=(0,I.C)(),et=W||k,ei=ee(et?.publicId||et?.public_id,{aspectRatio:"16:9",width:1200,focusMethod:et?.focus})?.toURL(),{mappedCategories:er}=(0,p.A)(e=>e.sitestructure),el=(0,p.A)(e=>e.documents.mappedData[R]?.meta.isUpdating),ea=j&&j.pathname?j.pathname:`${R}`,{mappedCategory:en,mappedParentCategory:es,pageCategory:eo,isHiddenCategory:ed}=((e,t)=>{let{category:i,parent:r,name:l}=e,a=i?.slug?t[i.slug]?.data:null,n=a?.isHiddenCategory,s=!a&&r&&r.category?.slug?t[r.category.slug].data:null,o=a?`${a?.prettyUrl}/${l}`:`${s?.prettyUrl}/${r?.slug}/${l}`;return{mappedCategory:a,mappedParentCategory:s,pageCategory:o,isHiddenCategory:n}}
11)(e,er),{seoDescription:ec,seoTitle:em}=(e=>{let{seoConfig:t,ingress:i,name:r}=e;return{seoDescription:t?.introduction?t.introduction:i,seoTitle:t?.title?t.title:r}})(e),{schemaType:eu,schemaArticleSection:ej,schemaAuthor:eb,schemaUrl:ek}=((e,t,i,r)=>{let{type:l,meta:a,slug:n}=e,s=l===eY.q.nafnoNewsArticle?"NewsArticle":"Article",o=t?.seoConfig?.title||t?.name||i?.seoConfig?.title||i?.name;return{schemaType:s,schemaArticleSection:o,schemaAuthor:a?.editor?.name?{name:a.editor.name,...a.editor.bio&&{bio:a.editor.bio},...a.editor.imageUrl&&{imageUrl:a.editor.imageUrl},...a.editor.slug&&{slug:a.editor.slug}}:"NAF",schemaUrl:r||`/${n}`}})(e,en,es,ea),eC=((e,t)=>{let{id:i,meta:r,name:l,userAccessibility:a}=e;return{page_type:"ArticlePage",pageCategory:t,contentId:i,author:r?.editor?.name,headline:l,publishDate:r?.publishAt,daysSincePublish:(0,eA.G)(new Date,new Date(r?.publishAt)),isPaywall:"Free"!==a.viewType,viewType:a.viewType}})(e,eo),eK=(({articleId:e,dataLayer:t})=>{let i=(0,l.useRef)(null),r=(0,l.useRef)(new Set),a=(0,l.useRef)(!1),n=(0,l.useRef)(!1),s=(0,l.useRef)(null),o=(0,l.useCallback)(()=>{if(!i.current)return;let l=i.current,o=l.getBoundingClientRect().top,d=l.offsetHeight,c=window.innerHeight;if(o<c&&o+d>0){let i=Math.min(Math.max((c-o)/d*100,0),100);[10,25,50,75,100].forEach(l=>{i>=l&&!r.current.has(l)&&(10!==l||a.current?10===l||n.current||(t&&t?.push({event:"scrollTracking",articleId:e,scrollDepth:l,page:window.location.pathname}),r.current.add(l)):(a.current=!0,n.current=!0,s.current=setTimeout(()=>{t&&t?.push({event:"scrollTracking",articleId:e,scrollDepth:l,page:window.location.pathname}),r.current.add(l),n.current=!1,s.current=null},1500)))})}},[e,t]),d=(0,l.useMemo)(()=>(0,ev.throttle)(o,200),[o]);return(0,l.useEffect)(()=>(window.addEventListener("scroll",d),()=>{window.removeEventListener("scroll",d),d.cancel(),s.current&&clearTimeout(s.current)}),[d]),i})({articleId:$,dataLayer:b});return(0,r.jsx)(T.n,{title:w,description:v,url:i,imgUrl:ei,imgWidth:ei?1200:void 0,gtmArgs:eC,isHiddenFromSearch:S?.isHiddenFromSearch,seoDescription:ec,seoTitle:em,internalSearchMetaData:{cardType:ex.Um.Article,imagePublicId:k?.publicId,author:P?.editor?.name,tags:U},backToTopButton:!0,children:(0,r.jsxs)(e$.mO,{children:[(0,r.jsx)(z.A,{id:R,type:eu,title:em,description:ec,imgUrl:ei,url:ek,datePublished:P?.publishAt,dateModified:P?.updatedAt,author:eb,articleSection:ej,isAccessibleForFree:"Free"===M.viewType}),!ed&&!O&&(0,r.jsx)(e$.BW,{children:(0,r.jsx)(e$.iJ,{children:(0,r.jsx)(K.A,{})})}),(0,r.jsx)(E.W,{name:w,image:k||void 0,ingress:v,runningHead:y,displayFeatureHeader:O||!1,video:F||void 0,youtubeVideo:Z,userAccessibility:M,meta:P,metaDisplay:N,isHiddenCategory:ed,documentType:B}),O&&N?.metaPosition!=="bottom"&&(0,r.jsx)(e$.PX,{children:(0,r.jsx)(e$.Av,{children:(0,r.jsx)(eg.e,{meta:P,metaDisplay:N,documentType:B})})}),X&&(0,r.jsx)(e$.PX,{children:(0,r.jsx)(eh,{articleSeries:X})}),Q?.title&&(0,r.jsx)(e$.PX,{children:(0,r.jsx)(e$.Av,{children:(0,r.jsx)(e$.Ac,{children:(0,r.jsx)(m.T,{title:Q.title,content:Q.content&&(0,r.jsx)(x.A,{value:Q.content}),showDisclaimer:Q.showDisclaimer})})})}),V&&(0,r.jsx)(h.A,{routePoints:V,travelMode:G}),J?.enabled&&A&&(0,r.jsx)(e$.PX,{children:(0,r.jsx)(e$.Av,{children:(0,r.jsx)(D.A,{tagType:"h2",title:J?.title,parentElement:eK})})}),q?.links?.length>0&&(0,r.jsx)(e$.PX,{children:(0,r.jsxs)(e$.E8,{children:[(0,r.jsx)(n.EY,{tag:"h3",variant:n.J3.Header3,children:q.header?q.header:"Les ogs\xe5"}),(0,r.jsx)(Y,{relatedLinks:q.links})]})}),!!H?.selectedScore&&(0,r.jsx)(e$.PX,{children:(0,r.jsx)(e$.Av,{children:(0,r.jsxs)(e$.cV,{children:[(0,r.jsx)(n.EY,{tag:"h3",variant:n.J3.Header3,children:"Testresultat"}),(0,r.jsxs)(e$.Pm,{children:[(0,r.jsx)(a.F,{size:24}),(0,r.jsxs)("span",{children:[(0,r.jsxs)("b",{children:[H.selectedScore," poeng"]})," ",!!H.maxScore&&`av ${H.maxScore}`]})]})]})})}),el&&!A?(0,r.jsx)(e$.PX,{children:(0,r.jsx)(e$.Av,{children:(0,r.jsx)(ey.LoaderContent,{})})}):A&&(0,r.jsx)(e$.pk,{ref:eK,children:(0,r.jsx)(x.A,{context:ef.q.Article,value:A,isAccessibleForUser:M.isAccessibleForUser})})||null,X&&(0,r.jsx)(e$.PX,{children:(0,r.jsx)(ep,{articleSeries:X})}),(0,r.jsxs)(e$.PX,{children:[(0,r.jsxs)(e$.Rn,{children:[N?.showAuthorBio&&P?.editor?.bio&&(0,r.jsx)(e$.LY,{children:(0,r.jsx)(c.O,{title:((e,t)=>{if(!t)return e;if(!e)return t;let i=t.charAt(0).toLowerCase()+t.slice(1);return`${e}, ${i}`})(P.editor.name,P.editor.position),body:P.editor.bio,image:P.editor.imageUrl?{src:P.editor.imageUrl,alt:P.editor.name}:void 0,link:P.editor.slug?{text:"Les mer",to:`/artikler?forfatter=${P.editor.slug}`}:void 0})}),N?.metaPosition==="bottom"&&(0,r.jsx)(e$.$6,{children:(0,r.jsx)(eg.e,{meta:P,metaDisplay:N,documentType:B})}),U&&(0,r.jsx)(ew,{tags:U,mappedCategories:er,category:_,articleUrl:ea})]}),L?.length>0&&(0,r.jsxs)(e$.E8,{children:[(0,r.jsx)(e$.ue,{}),(0,r.jsx)(n.EY,{tag:"h2",variant:n.J3.Header3,id:"relatedContent",children:"Les ogs\xe5"}),(0,r.jsx)(f.A,{relatedContent:L})]}),!ed&&!N?.hideForm&&(0,r.jsx)(e$.E8,{children:(0,r.jsx)(C.A,{contentUrl:i})})]})]})})}}}]);
12//# sourceMappingURL=pages-Article-Article.19532e2eee35c64a.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.