"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9075],{30063:function(e,t,n){n.d(t,{Z:function(){return d}});var r=n(5503),l=n(89489),i=n(44940),a=n(33656);let c=(0,a.j)("flex gap-3 p-5",{variants:{color:{primary:["bg-primary-600"],neutral:["bg-white"],dark:["bg-primary-950"]}},defaultVariants:{color:"primary"}}),o=(0,a.j)("rounded-full p-3",{variants:{color:{primary:["bg-white","text-primary-600"],neutral:["bg-neutral-500","text-white"],dark:["bg-white","text-primary-950"]}},defaultVariants:{color:"primary"}}),s=(0,a.j)("flex flex-col justify-between",{variants:{color:{primary:["text-white"],neutral:["text-neutral-500"],dark:["text-white"]}},defaultVariants:{color:"primary"}});var u=e=>{let{contractType:t,color:n,agreementType:a}=e;return(0,r.BX)(l.xu,{className:c({color:n}),children:[(0,r.tZ)(l.xu,{className:o({color:n}),children:(0,r.tZ)(i.BB,{fontSize:"35px"})}),(0,r.BX)(l.xu,{className:s({color:n}),children:[(0,r.tZ)(l.ZT,{intent:"title",size:"sm",weight:"light",className:"uppercase tracking-wide",children:t}),(0,r.tZ)(l.ZT,{intent:"title",size:"md",children:a})]})]})},d=e=>{let{color:t,agreementType:n,contractType:i,description:a,disabled:c,actionBanner:o,footNote:s,children:d}=e;return(0,r.BX)(l.xu,{className:"flex flex-col border-b border-neutral-500 bg-white",children:[(0,r.tZ)(u,{contractType:i,agreementType:n,color:t}),(0,r.tZ)(l.UQ.Root,{type:"single",collapsible:!0,children:(0,r.tZ)(l.UQ.Item,{label:a,value:"content",className:"px-5",border:!1,disabled:c,children:d})}),s&&(0,r.tZ)(l.ZT,{intent:"body",size:"sm",className:"border-1-neutral-400 mt-2 border-t py-4 px-5 text-neutral-600",children:s}),o]})}},81836:function(e,t,n){n.d(t,{u:function(){return h},d:function(){return v}});var r=n(5503),l=n(89489),i=n(44940),a=n(51473),c=n(33656),o=n(46507),s=n(52983),u=n(16665);let d=e=>{let{open:t,className:n,onOpenChange:i,trigger:a,title:o,content:s,cancelText:d,confirmText:h,onAction:p,confirmColor:f="negative"}=e;return(0,r.BX)(u.fC,{open:t,onOpenChange:i,children:[a?(0,r.tZ)(u.xz,{asChild:!0,children:a}):(0,r.tZ)(u.xz,{}),(0,r.BX)(u.h_,{children:[(0,r.tZ)(u.aV,{className:"fixed inset-0 z-20 bg-black/75",forceMount:!0}),(0,r.tZ)(u.VY,{asChild:!0,children:(0,r.BX)(l.Zb.Root,{className:(0,c.cx)("fixed inset-1/2 z-20 h-screen w-[100vw] max-w-lg translate-x-[-50%] translate-y-[-50%] sm:h-min sm:rounded-2xl",n),rounded:!1,children:[(0,r.tZ)(l.Zb.Header,{children:(0,r.tZ)(u.Dx,{asChild:!0,children:(0,r.tZ)(l.ZT,{intent:"title",children:o})})}),(0,r.tZ)(l.Zb.Content,{children:(0,r.tZ)(u.dk,{asChild:!0,children:(0,r.tZ)(l.ZT,{children:s})})}),(0,r.BX)(l.Zb.Footer,{style:{display:"flex",gap:25,justifyContent:"flex-end"},children:[(0,r.tZ)(u.$j,{asChild:!0,children:(0,r.tZ)(l.zx,{intent:"text",color:"neutral",onClick:()=>p(!1),children:d})}),(0,r.tZ)(u.aU,{asChild:!0,children:(0,r.tZ)(l.zx,{color:f,onClick:()=>p(!0),children:h})})]})]})})]})]})},h=(0,s.forwardRef)(function(e,t){let{className:n,title:u,footer:h,children:p,trigger:f,open:m,defaultOpen:Z,onOpenChange:x,preventClose:b,contentWrapper:y}=e,C=(0,s.useRef)(),v=(0,s.useRef)(!1),[g,w]=(0,s.useState)(()=>m||Z||!1),[B,k]=(0,s.useState)(!1),z=(0,s.useCallback)(()=>{C.current&&C.current.click()},[]);(0,s.useImperativeHandle)(t,()=>({close:z})),(0,s.useEffect)(()=>{void 0!==m&&w(m)},[m]),(0,s.useEffect)(()=>{b?v.current=!0:v.current=!1},[b]);let{t:N}=(0,o.$G)("common");return(0,r.BX)(r.HY,{children:[(0,r.BX)(a.fC,{onOpenChange:e=>{if(!e&&v.current){k(!0);return}x&&x(e),w(e)},open:g,children:[f?(0,r.tZ)(a.xz,{asChild:!0,onClick:()=>w(!0),children:f}):(0,r.tZ)(a.xz,{}),(0,r.tZ)(a.h_,{children:(0,r.tZ)(a.aV,{className:"fixed inset-0 z-20 grid place-content-center overflow-y-auto bg-black/75",children:(0,r.BX)(l.Zb.Root,{as:a.VY,className:(0,c.cx)("max-h-screen w-[100vw] max-w-3xl overflow-y-auto sm:my-4 sm:h-min sm:rounded-2xl",n),rounded:!1,children:[(0,r.BX)(l.Zb.Header,{className:"bg-primary-950 relative flex items-center justify-between",children:[(0,r.tZ)(l.ZT,{as:"h2",color:"white",intent:"title",children:u}),(0,r.tZ)(a.x8,{asChild:!0,children:(0,r.tZ)(l.zx,{intent:"text","aria-label":N("action.close"),startIcon:(0,r.tZ)(i.x8,{}),color:"white",iconSize:"lg",ref:C})})]}),y?(0,r.BX)(y,{children:[(0,r.tZ)(l.Zb.Content,{children:p}),h?(0,r.tZ)(l.Zb.Footer,{children:h(z)}):null]}):(0,r.BX)(r.HY,{children:[(0,r.tZ)(l.Zb.Content,{children:p}),h?(0,r.tZ)(l.Zb.Footer,{children:h(z)}):null]})]})})})]}),b?(0,r.tZ)(d,{open:B,onOpenChange:k,...b,onAction:e=>{e&&C.current&&(v.current=!1,setTimeout(()=>{z()},100))}}):null]})});var p=n(1295),f=n(70525),m=n(74097),Z=n(71865),x=n(65433);let b=e=>(0,Z.pipe)(s.Children.toArray(e),(0,m.filter)(Boolean)),y=e=>{let{hideProgress:t,children:n}=e,{currentStep:i,setSteps:a}=(0,f.v)(),c=(0,s.useMemo)(()=>(0,Z.pipe)(n,b),[n]);(0,s.useEffect)(()=>{a((0,Z.pipe)(c,m.size))},[c,a]);let o=(0,s.useMemo)(()=>(0,Z.pipe)(c,(0,m.lookup)(i),(0,x.alt)(()=>(0,Z.pipe)(c,m.head)),x.toUndefined),[c,i]),u=(0,s.useMemo)(()=>(0,Z.pipe)(c,(0,m.mapWithIndex)(e=>(0,r.tZ)(l.Rg.Item,{nr:e+1,active:i>=e,completed:i>e},e))),[c,i]);return(0,r.tZ)(p.B$,{children:(0,r.BX)(r.HY,{children:[t?null:(0,r.tZ)(l.Rg.Root,{direction:"horizontal",className:"mb-8",children:u}),o]})})},C=e=>{let{hideProgress:t,children:n,...l}=e,{close:i}=(0,f.v)();return(0,r.tZ)(h,{...l,onOpenChange:e=>{e||i()},children:(0,r.tZ)(y,{hideProgress:t,children:n})})},v=e=>{let{onClose:t,...n}=e;return(0,r.tZ)(f.R,{onClose:t,children:(0,r.tZ)(C,{...n})})}},70525:function(e,t,n){n.d(t,{R:function(){return c},v:function(){return a}});var r=n(5503),l=n(52983);let i=(0,l.createContext)({currentStep:0,isOnLastStep:!0,nextStep:()=>{},close:()=>{},steps:0,setSteps:()=>{},prevStep:()=>{}});function a(){return(0,l.useContext)(i)}let c=e=>{let{onClose:t,children:n}=e,[a,c]=(0,l.useState)(()=>0),[o,s]=(0,l.useState)(()=>0),u=(0,l.useCallback)(()=>{t&&t(),c(0)},[t,c]),d=(0,l.useMemo)(()=>a===o-1,[a,o]),h=(0,l.useCallback)(()=>d?u():c(e=>e+1),[d,c,u]),p=(0,l.useCallback)(()=>c(e=>e-1),[c]);return(0,r.tZ)(i.Provider,{value:{currentStep:a,isOnLastStep:d,steps:o,setSteps:s,close:u,nextStep:h,prevStep:p},children:n})}},54306:function(e,t,n){n.d(t,{p:function(){return c}});var r=n(5503),l=n(46507),i=n(15918),a=n(95656);let c=e=>{let{type:t,isOresundPay:n}=e;return(0,r.BX)(l.cC,{i18nKey:"termsOfAgreement",ns:"common",children:[(0,r.tZ)(i.A,{type:t,isOresundPay:n}),(0,r.tZ)(a.w,{type:t})]})}},29867:function(e,t,n){n.d(t,{o:function(){return a},v:function(){return i}});var r=n(71865),l=n(60218);let i={OresundGO:"oresundGo",OresundPendler:"oresundCommuter",Oresund_Business_Pendler:"oresundBusinessCommuter",Oresund_Business:"oresundBusiness",OresundPAY:"oresundPay",OresundPAYBusiness:"oresundPayBusiness",Storebelt:"storebelt",OresundPeriodCard:"oresundPeriodCard"},a=e=>(0,r.pipe)(i,(0,l.lookup)(e))},97296:function(e,t,n){n.d(t,{e:function(){return a}});var r=n(74097),l=n(71865),i=n(94036);let a=()=>function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return e=>(0,l.pipe)(e,i.Yz,(0,r.filter)(e=>{let[n]=e;return t.includes(n)}),(0,r.reduce)({},(e,t)=>{let[n,r]=t;return{...e,[n]:r}}))}},88274:function(e,t,n){n.d(t,{K:function(){return a}});var r=n(5503),l=n(89489),i=n(46507);let a=e=>{let{translationKey:t}=e;return(0,r.tZ)(i.cC,{ns:"common",i18nKey:t,children:(0,r.tZ)(l.ZT,{as:"span",intent:"title",size:"md",weight:"bold"})})}},68653:function(e,t,n){n.d(t,{HQ:function(){return a},IW:function(){return i},lF:function(){return l}});var r=n(99840);let l=e=>"invoice"===e.paymentType,i=e=>{let{startDateTime:t,endDateTime:n,active:l}=e,i=new Date(t),a=new Date(n);return{status:l?"active":"cancelled",date:(0,r.Z)(i,"yyyy-MM-dd"),endDate:(0,r.Z)(a,"yyyy-MM-dd")}},a=e=>({contractNo:e,agreementType:"Storebelt"})}}]);
//# sourceMappingURL=9075-9e3f1a71a7e89d76.js.map